/* TOTO Tuấn Tú - Smart Search UI V1 */
#toto-smart-search-v1,
#toto-smart-search-v1 * {
  box-sizing: border-box;
}

#toto-smart-search-v1 {
  position: fixed;
  z-index: 10050;
  display: none;
  overflow: hidden;
  max-height: min(650px, calc(100vh - 90px));
  background: #fff;
  border: 1px solid #e7e3dc;
  border-radius: 12px;
  box-shadow: 0 18px 48px rgba(0,0,0,.16);
  color: #222;
  font-family: Roboto, Arial, sans-serif;
}

.toto-ss-head {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 64px;
  padding: 12px 14px 11px 16px;
  background: #fff;
  border-bottom: 1px solid #eeeae3;
}

.toto-ss-head__text {
  min-width: 0;
  flex: 1;
}

.toto-ss-kicker {
  display: block;
  margin-bottom: 3px;
  color: #a47f36;
  font-size: 9px;
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: 1.25px;
}

.toto-ss-title {
  display: block;
  overflow: hidden;
  color: #222;
  font-size: 15px;
  line-height: 1.45;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.toto-ss-title em {
  color: #a47f36;
  font-style: normal;
}

.toto-ss-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: #f7f5f1;
  color: #777;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.toto-ss-close:hover {
  background: #eee9df;
  color: #222;
}

.toto-ss-body {
  max-height: min(500px, calc(100vh - 190px));
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.toto-ss-item {
  display: flex !important;
  align-items: center;
  gap: 13px;
  width: 100%;
  min-height: 104px;
  padding: 11px 14px !important;
  border-bottom: 1px solid #f0eee9;
  background: #fff;
  color: inherit !important;
  text-decoration: none !important;
  transition: background .15s ease;
}

.toto-ss-item:hover,
.toto-ss-item.is-selected {
  background: #faf8f4;
}

.toto-ss-img {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 82px;
  width: 82px;
  height: 82px;
  overflow: hidden;
  padding: 5px;
  border-radius: 8px;
  background: #fafafa;
}

.toto-ss-img img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.toto-ss-noimg {
  color: #aaa;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .8px;
}

.toto-ss-info {
  display: block;
  flex: 1;
  min-width: 0;
}

.toto-ss-name {
  display: -webkit-box;
  overflow: hidden;
  margin: 0 0 4px;
  color: #222;
  font-size: 14px;
  line-height: 1.45;
  font-weight: 600;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.toto-ss-item:hover .toto-ss-name,
.toto-ss-item.is-selected .toto-ss-name {
  color: #9a742d;
}

.toto-ss-meta {
  display: block;
  overflow: hidden;
  margin-bottom: 5px;
  color: #8b8b8b;
  font-size: 10.5px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.toto-ss-sku {
  font-family: Arial, sans-serif;
}

.toto-ss-prices {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 1px;
}

.toto-ss-prices strong {
  color: #a47f36;
  font-size: 15px;
  line-height: 1.4;
  font-weight: 700;
}

.toto-ss-prices del {
  color: #999;
  font-size: 11.5px;
  line-height: 1.4;
}

.toto-ss-reason {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  max-width: 100%;
  margin-top: 5px;
  padding: 3px 7px;
  overflow: hidden;
  border-radius: 999px;
  background: #f5f0e6;
  color: #866729;
  font-size: 9.5px;
  line-height: 1.3;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.toto-ss-foot {
  background: #faf8f4;
  border-top: 1px solid #eee7da;
}

.toto-ss-view-all {
  display: flex !important;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 45px;
  padding: 10px 14px !important;
  color: #806126 !important;
  font-size: 12px;
  line-height: 1.45;
  text-align: center;
  text-decoration: none !important;
}

.toto-ss-view-all:hover {
  background: #f4efe5;
  color: #6f521e !important;
}

.toto-ss-view-all span {
  font-size: 16px;
}

.toto-ss-loading,
.toto-ss-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 125px;
  padding: 24px 20px;
  color: #777;
  text-align: center;
}

.toto-ss-loading {
  flex-direction: row;
  gap: 10px;
  font-size: 12px;
}

.toto-ss-empty strong {
  margin-bottom: 6px;
  color: #333;
  font-size: 14px;
}

.toto-ss-empty span {
  color: #777;
  font-size: 12px;
  line-height: 1.6;
}

.toto-ss-empty small {
  margin-top: 7px;
  color: #a47f36;
  font-size: 10.5px;
}

.toto-ss-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid #e5dfd2;
  border-top-color: #a47f36;
  border-radius: 50%;
  animation: totoSSSpin .65s linear infinite;
}

@keyframes totoSSSpin {
  to { transform: rotate(360deg); }
}

@media (max-width: 767px) {
  #toto-smart-search-v1 {
    border-radius: 10px;
  }

  .toto-ss-head {
    min-height: 57px;
    padding: 10px 11px 9px 13px;
  }

  .toto-ss-kicker {
    font-size: 8px;
  }

  .toto-ss-title {
    font-size: 13px;
  }

  .toto-ss-item {
    min-height: 91px;
    gap: 10px;
    padding: 9px 10px !important;
  }

  .toto-ss-img {
    flex-basis: 68px;
    width: 68px;
    height: 68px;
  }

  .toto-ss-name {
    font-size: 12.5px;
  }

  .toto-ss-meta {
    font-size: 9.5px;
  }

  .toto-ss-prices strong {
    font-size: 13.5px;
  }

  .toto-ss-prices del {
    font-size: 10.5px;
  }

  .toto-ss-reason {
    font-size: 8.8px;
  }
}
/* =========================================================
   TOTO - TẮT HOÀN TOÀN SMART SEARCH EGA CŨ
   ========================================================= */

#ega-smartsearch-search-suggestion,
.ega-smartsearch-search-suggestion,
.ega-smartsearch-search-wrapper,
.search-overlay {
	display: none !important;
	visibility: hidden !important;
	opacity: 0 !important;
	pointer-events: none !important;
}
/* =========================================================
   TOTO AI SEARCH - SEARCH BAR
   ========================================================= */

.tt-ai-search-bar {
	position: relative !important;
}


/* Badge AI */
.tt-ai-search-badge {
	position: absolute;

	left: 13px;
	top: 50%;

	z-index: 5;

	display: inline-flex;
	align-items: center;
	gap: 4px;

	transform: translateY(-50%);

	padding: 5px 8px;

	border: 1px solid #dfd1b5;
	border-radius: 999px;

	background: #f8f3e9;

	color: #9a742d;

	font-size: 10px;
	line-height: 1;
	font-weight: 700;

	letter-spacing: .6px;

	pointer-events: none;
}


/* Ngôi sao AI */
.tt-ai-search-badge__icon {
	font-size: 12px;
	line-height: 1;
}


/* Chừa khoảng cho badge */
.tt-ai-search-input {
	padding-left: 73px !important;
	padding-right: 55px !important;
}


/* Placeholder */
.tt-ai-search-input::placeholder {
	color: #777 !important;

	font-size: 13px;

	opacity: 1 !important;
}


/* Khi click vào search */
.tt-ai-search-input:focus {
	background: #fff !important;

	box-shadow:
		0 0 0 2px rgba(164,127,54,.12) !important;
}


/* MOBILE */
@media (max-width: 767px) {

	.tt-ai-search-badge {
		left: 8px;

		padding: 4px 6px;

		font-size: 9px;
	}


	.tt-ai-search-input {
		padding-left: 57px !important;
		padding-right: 45px !important;
	}


	.tt-ai-search-input::placeholder {
		font-size: 11px;
	}

}