.sales365-ai {
  --s365-red: #980000;
  --s365-dark: #222;
  max-width: 1120px;
  margin: 30px auto;
  padding: 24px;
  background: #fff;
  border: 1px solid #e5e5e5;
  border-radius: 8px;
  box-sizing: border-box;
}

.sales365-ai-header {
  position: relative;
  z-index: 10000;
  width: min(440px, calc(100vw - 24px));
  max-height: min(620px, 75vh);
  overflow-y: auto;
  background: #fff;
  border: 1px solid #ddd;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .18);
  color: #222;
}
.sales365-ai-header__message,
.sales365-ai-header__remaining { margin: 0; padding: 12px 14px; font-size: 13px; line-height: 1.4; }
.sales365-ai-header__message { font-weight: 700; border-bottom: 1px solid #eee; }
.sales365-ai-header__message.is-error { color: #a00; }
.sales365-ai-header__product { display: flex; gap: 10px; padding: 10px 12px; border-bottom: 1px solid #eee; color: #111; text-decoration: none; }
.sales365-ai-header__product:hover { background: #f7f7f7; }
.sales365-ai-header__product img { flex: 0 0 64px; width: 64px; height: 64px; object-fit: cover; }
.sales365-ai-header__details { display: flex; flex: 1; min-width: 0; flex-direction: column; gap: 3px; }
.sales365-ai-header__details strong { font-size: 13px; line-height: 1.3; }
.sales365-ai-header__price { color: #a90000; font-weight: 700; }
.sales365-ai-header__stock { font-size: 12px; }
.sales365-ai-header__stock.is-in-stock { color: #5b9b20; }
.sales365-ai-header__stock.is-out-of-stock { color: #777; }
.sales365-ai-header__corrections { display: flex; flex-wrap: wrap; gap: 7px; padding: 10px 12px; border-bottom: 1px solid #eee; }
.sales365-ai-header__corrections button { padding: 7px 9px; border: 1px solid #b00000; background: #fff; color: #a00000; cursor: pointer; font-weight: 700; }
.sales365-ai-header__remaining { color: #555; text-align: center; }
.sales365-smart-header { position: relative; z-index: 102; clear: both; width: 100%; min-height: 0 !important; height: auto !important; padding: 10px 0 !important; background: #fff; border-top: 1px solid #eee; border-bottom: 1px solid #eee; box-sizing: border-box; }
.sales365-smart-header__container { float: none !important; min-height: 0 !important; height: auto !important; padding-top: 0 !important; padding-bottom: 0 !important; }
.sales365-smart-header__form { position: relative; width: min(532px, 100%); height: 50px; min-height: 0; margin: 0 auto !important; padding: 0 !important; }
.sales365-smart-header .sales365-smart-header__input[type="search"] { display: block; width: 100% !important; height: 50px !important; margin: 0 !important; padding: 0 132px 0 48px !important; border: 1px solid #a90000 !important; border-radius: 9px !important; background: #fff !important; color: #222 !important; font-size: 16px !important; line-height: 50px !important; box-sizing: border-box !important; box-shadow: none !important; }
.sales365-smart-header .sales365-smart-header__input[type="search"]:focus { outline: 2px solid rgba(169, 0, 0, .14) !important; outline-offset: 1px; }
.sales365-smart-header .sales365-smart-header__input[type="search"]::-webkit-search-cancel-button { display: none; }
.sales365-smart-header__search-icon, .sales365-smart-header__submit span { display: block; width: 16px; height: 16px; border: 2.6px solid currentColor; border-radius: 50%; box-sizing: border-box; }
.sales365-smart-header__search-icon::after, .sales365-smart-header__submit span::after { content: ''; position: absolute; width: 8px; height: 2.6px; border-radius: 2px; background: currentColor; transform: rotate(45deg); transform-origin: left center; }
.sales365-smart-header__search-icon { position: absolute; z-index: 2; top: 17px; left: 17px; color: #555; pointer-events: none; }
.sales365-smart-header__search-icon::after { top: 11px; left: 10px; }
.sales365-smart-header__clear, .sales365-smart-header__voice, .sales365-smart-header__submit { position: absolute !important; top: 0 !important; height: 50px !important; margin: 0 !important; border: 0 !important; box-shadow: none !important; cursor: pointer; }
.sales365-smart-header__clear { right: 88px !important; width: 38px !important; padding: 0 !important; background: transparent !important; color: #555 !important; font-size: 28px !important; font-weight: 300 !important; }
.sales365-smart-header__voice { right: 50px !important; width: 38px !important; padding: 0 !important; background: transparent !important; color: #555 !important; }
.sales365-smart-header__voice svg { display: block; width: 22px; height: 22px; margin: auto; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.sales365-smart-header__voice.is-listening { color: #a90000 !important; }
.sales365-smart-header__voice.is-listening::after { content: ''; position: absolute; top: 8px; right: 6px; width: 7px; height: 7px; border-radius: 50%; background: #d00000; animation: sales365-recording-pulse .8s ease-in-out infinite alternate; }
.sales365-smart-header .sales365-smart-header__input.is-listening[type="search"] { background: #fffafa !important; }
@keyframes sales365-recording-pulse { from { opacity: .3; transform: scale(.75); } to { opacity: 1; transform: scale(1.15); } }
.sales365-smart-header__submit { right: 0 !important; width: 50px !important; padding: 0 !important; border-radius: 0 8px 8px 0 !important; background: #a90000 !important; color: #fff !important; }
.sales365-smart-header__submit span { position: relative; margin: auto; }
.sales365-smart-header__submit span::after { top: 11px; left: 10px; }
.sales365-smart-header [hidden] { display: none !important; }
.sales365-smart-header__suggestions { position: absolute; z-index: 10020; top: calc(100% - 10px); left: 50%; width: min(620px, calc(100vw - 24px)); max-height: min(560px, 70vh); overflow-y: auto; transform: translateX(-50%); border: 1px solid #ddd; background: #fff; color: #222; box-shadow: 0 8px 24px rgba(0,0,0,.2); }
.sales365-smart-header__suggestions-title { display: block; padding: 11px 14px; border-bottom: 1px solid #eee; font-size: 14px; }
.sales365-smart-header__message { margin: 0; padding: 12px 14px; border-bottom: 1px solid #eee; font-size: 13px; font-weight: 700; line-height: 1.45; white-space: pre-line; }
.sales365-smart-header__message.is-error { color: #a00000; }
.sales365-smart-header__criteria { display: flex; flex-wrap: wrap; gap: 6px; padding: 10px 14px; border-bottom: 1px solid #eee; }
.sales365-smart-header__criteria span { padding: 4px 8px; border: 1px solid #ddd; border-radius: 999px; background: #f7f7f7; color: #555; font-size: 11px; }
.sales365-smart-header__corrections { display: flex; flex-wrap: wrap; gap: 7px; padding: 10px 14px; border-bottom: 1px solid #eee; }
.sales365-smart-header__corrections button { padding: 7px 9px; border: 1px solid #a90000; background: #fff; color: #a90000; font-weight: 700; cursor: pointer; }
.sales365-smart-header__more, .sales365-smart-header__source { margin: 0; padding: 10px 14px; text-align: center; font-size: 12px; }
.sales365-smart-header__all-results {
  display: block !important;
  width: auto !important;
  min-height: 0 !important;
  height: auto !important;
  margin: 0 !important;
  padding: 9px 14px !important;
  border: 0 !important;
  border-radius: 0 !important;
  outline: 0 !important;
  background: #fff !important;
  box-shadow: none !important;
  color: #222 !important;
  text-align: center;
  text-decoration: none !important;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35 !important;
  transition: color .18s ease;
}
.sales365-smart-header__all-results:hover,
.sales365-smart-header__all-results:focus,
.sales365-smart-header__all-results:active,
.sales365-smart-header__all-results:visited:hover {
  border: 0 !important;
  outline: 0 !important;
  background: #fff !important;
  box-shadow: none !important;
  color: #a90000 !important;
}
.sales365-smart-header__source a { color: #a90000; font-weight: 700; }
.sales365-smart-header__product { display: flex; gap: 12px; padding: 12px 14px; border-bottom: 1px solid #eee; color: #222 !important; text-decoration: none !important; }
.sales365-smart-header__product:hover, .sales365-smart-header__product:focus { background: #f8f8f8; }
.sales365-smart-header__product img { flex: 0 0 82px; width: 82px; height: 82px; object-fit: contain; background: #fafafa; }
.sales365-smart-header__details { display: flex; flex: 1; min-width: 0; flex-direction: column; gap: 2px; line-height: 1.35; }
.sales365-smart-header__details strong { font-size: 14px; }
.sales365-smart-header__brand, .sales365-smart-header__sku, .sales365-smart-header__stock { font-size: 12px; }
.sales365-smart-header__brand, .sales365-smart-header__sku { color: #666; }
.sales365-smart-header__price { margin-top: 3px; color: #a90000; font-weight: 700; }
.sales365-smart-header__stock.is-in-stock { color: #5b921f; }
.sales365-smart-header__stock.is-out-of-stock { color: #777; }
#top #header .menu-item-search-dropdown { display: none !important; }
.sales365-ai [hidden] { display: none !important; }
.sales365-ai h2 { margin: 0 0 6px; color: var(--s365-dark); }
.sales365-ai__intro { margin: 0 0 16px; color: #555; }
.sales365-ai__form { display: flex; gap: 8px; }
.sales365-ai--results-page > .sales365-ai__form { display: none; }
.sales365-ai.sales365-ai--results-page { padding: 0; border: 0; border-radius: 0; background: transparent; }
.sales365-ai__input-wrap { position: relative; flex: 1; min-width: 0; }
.sales365-ai .sales365-ai__input[type="search"] {
  width: 100% !important;
  min-width: 0;
  height: 46px !important;
  margin: 0 !important;
  padding: 0 50px !important;
  border: 1px solid #bbb;
  border-radius: 4px;
  font-size: 16px;
  box-sizing: border-box !important;
}
.sales365-ai .sales365-ai__input[type="search"]:focus { border-color: var(--s365-red); outline: 2px solid rgba(152, 0, 0, .15); }
.sales365-ai .sales365-ai__input[type="search"]::-webkit-search-cancel-button { display: none !important; -webkit-appearance: none !important; }
.sales365-ai .sales365-ai__input[type="search"]::-ms-clear,
.sales365-ai .sales365-ai__input[type="search"]::-ms-reveal { display: none !important; width: 0; height: 0; }
.sales365-ai .sales365-ai__clear,
.sales365-ai .sales365-ai__voice {
  position: absolute !important;
  z-index: 2 !important;
  top: 50% !important;
  width: 36px !important;
  min-width: 36px !important;
  height: 36px !important;
  margin: 0 !important;
  padding: 0 !important;
  transform: translateY(-50%) !important;
  border: 0 !important;
  border-radius: 50% !important;
  background: transparent !important;
  box-shadow: none !important;
  cursor: pointer;
}
.sales365-ai .sales365-ai__clear { right: auto !important; left: 7px !important; color: #416c9f !important; font-size: 24px !important; line-height: 36px !important; }
.sales365-ai .sales365-ai__voice { right: 7px !important; left: auto !important; color: #555 !important; }
.sales365-ai .sales365-ai__voice svg { display: block !important; width: 22px !important; height: 22px !important; margin: 7px !important; fill: none !important; stroke: currentColor !important; stroke-width: 2.4 !important; stroke-linecap: round; stroke-linejoin: round; }
.sales365-ai .sales365-ai__clear:hover,
.sales365-ai .sales365-ai__clear:focus,
.sales365-ai .sales365-ai__voice:hover,
.sales365-ai .sales365-ai__voice:focus { background-color: #f1f1f1 !important; outline: 2px solid rgba(152, 0, 0, .15); }
.sales365-ai .sales365-ai__voice.is-listening { color: var(--s365-red) !important; background-color: #f8dddd !important; animation: sales365-pulse 1s infinite alternate; }
.sales365-ai .sales365-ai__voice.is-listening::after { content: ''; position: absolute; top: 4px; right: 3px; width: 7px; height: 7px; border-radius: 50%; background: #d00000; animation: sales365-recording-pulse .8s ease-in-out infinite alternate; }
.sales365-ai .sales365-ai__input.is-listening[type="search"] { background: #fffafa !important; }
.sales365-ai__suggestions { position: absolute; z-index: 30; top: calc(100% + 4px); left: 0; right: 0; padding: 10px 14px; border: 1px solid #ddd; border-radius: 4px; background: #fff; box-shadow: 0 5px 16px rgba(0, 0, 0, .15); }
.sales365-ai__suggestions-title { display: block; padding: 2px 0 8px; border-bottom: 1px solid #eee; }
.sales365-ai__suggestion { display: block; width: 100%; padding: 8px 0; border: 0; background: transparent; color: #222; text-align: left; cursor: pointer; }
.sales365-ai__suggestion:hover, .sales365-ai__suggestion:focus { color: var(--s365-red); outline: 0; }
@keyframes sales365-pulse { from { opacity: .65; } to { opacity: 1; } }
.sales365-ai__submit, .sales365-ai__view { background: var(--s365-red); color: #fff !important; border: 0; border-radius: 4px; text-decoration: none; }
.sales365-ai__submit { min-width: 120px; padding: 0 18px; font-weight: 700; cursor: pointer; }
.sales365-ai__submit:disabled { opacity: .65; cursor: wait; }
.sales365-ai__status { margin: 16px 0 0; font-weight: 600; white-space: pre-line; }
.sales365-ai__criteria { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; margin-top: 12px; color: #444; }
.sales365-ai__criterion { padding: 5px 9px; border: 1px solid #ddd; border-radius: 999px; background: #f7f7f7; font-size: 13px; }
.sales365-ai__correction { margin: 12px 8px 0 0; padding: 10px 14px; border: 1px solid var(--s365-red); border-radius: 4px; background: #fff; color: var(--s365-red); font-weight: 700; cursor: pointer; }
.sales365-ai__correction:hover, .sales365-ai__correction:focus { background: var(--s365-red); color: #fff; }
.sales365-ai__results { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 16px; padding: 0; list-style: none; }
.sales365-ai__card { display: flex; flex-direction: column; border: 1px solid #e4e4e4; border-radius: 6px; overflow: hidden; background: #fff; }
.sales365-ai__image { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: contain; background: #fafafa; }
.sales365-ai__body { display: flex; flex: 1; flex-direction: column; padding: 14px; }
.sales365-ai__name { margin: 0 0 8px; font-size: 16px; line-height: 1.35; }
.sales365-ai__name a { color: var(--s365-dark); text-decoration: none; }
.sales365-ai__price { margin: 0 0 4px; color: var(--s365-red); font-weight: 700; }
.sales365-ai__online-price { margin: 0 0 7px; color: #650000; font-size: 13px; font-weight: 700; }
.sales365-ai__stock { margin: 0 0 8px; font-size: 13px; }
.sales365-ai__reason { margin: 0 0 14px; line-height: 1.45; }
.sales365-ai__view { align-self: flex-start; margin-top: auto; padding: 9px 12px; }
.sales365-ai__more { display: block; margin: 20px auto 0; padding: 11px 20px; border: 1px solid var(--s365-red); border-radius: 4px; background: #fff; color: var(--s365-red); font-weight: 700; cursor: pointer; }
.sales365-ai__source { margin: 12px 0 0; }
.sales365-ai__source a { color: var(--s365-red); font-weight: 700; }
#top ul.products.sales365-ai__results { display: grid !important; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 16px 0 0 !important; padding: 0 !important; }
#top ul.products.sales365-ai__results::before,
#top ul.products.sales365-ai__results::after { display: none !important; content: none !important; }
#top ul.products.sales365-ai__results li.product.sales365-ai__archive-card { float: none !important; clear: none !important; width: auto !important; margin: 0 !important; padding: 0 0 18px !important; border: 0 !important; text-align: center !important; }
#top .sales365-ai__archive-card .sales365-ai__image-link { display: block !important; color: #222 !important; text-decoration: none !important; }
#top .sales365-ai__archive-card .sales365-ai__image { display: block !important; width: 100% !important; height: auto !important; aspect-ratio: 1 / 1; margin: 0 auto 12px !important; object-fit: contain; background: #fff !important; box-shadow: none !important; }
#top .sales365-ai__archive-card .sales365-ai__name { min-height: 38px; margin: 0 0 7px !important; padding: 0 !important; color: #222 !important; font-size: 14px !important; font-weight: 400 !important; line-height: 1.35 !important; text-align: center !important; text-transform: none !important; }
#top .sales365-ai__archive-card .sales365-ai__image-link:hover .sales365-ai__name { color: var(--s365-red) !important; }
#top .sales365-ai__archive-card .sales365-ai__price { display: block !important; margin: 0 0 10px !important; color: #111 !important; font-size: 14px !important; font-weight: 700 !important; line-height: 1.35 !important; text-align: center !important; }
#top .sales365-ai__archive-card .sales365-ai__online-price { display: inline-block !important; margin: 0 !important; padding: 8px 12px !important; border: 1px solid #ddd !important; border-left: 3px solid var(--s365-red) !important; border-radius: 5px !important; background: #fff !important; color: #650000 !important; font-size: 12px !important; font-weight: 700 !important; line-height: 1.35 !important; }
@media (max-width: 768px) {
  .sales365-smart-header { z-index: 2147482000; padding: 9px 0; }
  .sales365-smart-header__container { width: calc(100% - 24px) !important; }
  .sales365-smart-header__form { width: 100%; height: 46px; }
  .sales365-smart-header .sales365-smart-header__input[type="search"] { height: 46px !important; padding-right: 122px !important; font-size: 14px !important; line-height: 46px !important; }
  .sales365-smart-header__clear, .sales365-smart-header__voice, .sales365-smart-header__submit { height: 46px !important; }
  .sales365-smart-header__clear { right: 84px !important; }
  .sales365-smart-header__voice { right: 46px !important; }
  .sales365-smart-header__submit { width: 46px !important; }
  .sales365-smart-header__search-icon { top: 15px; }
  .sales365-smart-header__suggestions { z-index: 2147483000; top: calc(100% - 9px); max-height: min(55dvh, 440px); }
  .sales365-smart-header__product img { flex-basis: 68px; width: 68px; height: 68px; }
  .sales365-ai { margin: 16px 0; padding: 16px; }
  .sales365-ai.sales365-ai--results-page { padding: 0; }
  .sales365-ai__form { flex-direction: column; }
  .sales365-ai__submit { height: 44px; }
  .sales365-ai__results,
  #top ul.products.sales365-ai__results { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
}
@media (max-width: 420px) {
  .sales365-ai__results,
  #top ul.products.sales365-ai__results { grid-template-columns: 1fr; }
}
