.header-search[data-mega-search] { position: relative; }
.mega-search-panel { position: absolute; top: calc(100% + 12px); inset-inline-start: 0; width: min(880px, calc(100vw - 48px)); max-height: min(700px, 78dvh); overflow: auto; background: #fff; border: 1px solid #dce6f0; border-radius: 18px; box-shadow: 0 22px 60px #102b4d30; color: var(--ink); z-index: 80; text-align: start; }
.mega-search-heading { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.mega-search-heading strong { font-size: 14px; }
.header-search .mega-search-heading button { background: #edf3f8; color: #526477; font-size: 23px; width: 32px; height: 32px; }
.mega-search-content { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.4fr); }
.mega-search-content-single { grid-template-columns: minmax(0, 1fr); }
.mega-search-taxonomy { background: #f7f9fc; padding: 8px; border-inline-end: 1px solid var(--line); }
.mega-search-products { padding: 8px; min-width: 0; }
.mega-search-section { margin-bottom: 10px; }
.mega-search-section h3 { font-size: 11px; color: #64758a; font-weight: 700; padding: 10px; }
.mega-search-category { display: flex; flex-direction: column; gap: 2px; padding: 9px 12px; border-radius: 10px; font-size: 13px; }
.mega-search-category > span { font-weight: 700; }
.mega-search-category small, .mega-search-product small { display: block; color: #718197; font-size: 11px; margin-top: 3px; }
.mega-search-category:hover, .mega-search-category:focus-visible, .mega-search-product:hover, .mega-search-product:focus-visible { background: #eaf3fc; color: var(--blue); }
.mega-search-product { display: flex; gap: 12px; align-items: center; padding: 10px; border-radius: 10px; min-width: 0; }
.mega-search-product > span:last-child { min-width: 0; overflow-wrap: anywhere; }
.mega-search-product strong { font-size: 13px; font-weight: 600; }
.mega-search-product img, .mega-search-placeholder { width: 52px; height: 52px; flex: 0 0 52px; object-fit: contain; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.mega-search-placeholder { display: grid; place-items: center; color: var(--accent); font-size: 24px; background: var(--accent-soft); }
.mega-search-status { padding: 16px; color: var(--muted); font-size: 13px; }
.mega-search-status:empty { display: none; }
.mega-search-all { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; color: var(--blue); font-size: 12px; font-weight: 700; border-top: 1px solid var(--line); background: #f7fbff; }
@media (max-width: 767px) {
  .mega-search-panel { width: 100%; max-height: 65dvh; border-radius: 12px; }
  .mega-search-content { grid-template-columns: minmax(0, 1fr); }
  .mega-search-taxonomy { border-inline-end: 0; border-bottom: 1px solid var(--line); }
  .mega-search-taxonomy .mega-search-section { display: flex; flex-wrap: wrap; gap: 4px; }
  .mega-search-taxonomy h3 { width: 100%; }
  .mega-search-category { background: #fff; border: 1px solid var(--line); flex: 1 1 130px; font-size: 12px; }
}
