/* ---------- The header and footer of every page (owner, 3 December 2026: "set the header and footer as the
   header for every page on site"; the MusicGearLab header stays the same in every category) ----------
   Universal search, the category megamenu and quick links, and the glass footer. Builds on site.css. */

.skip { position: absolute; left: 0.75rem; top: -4rem; z-index: 60; padding: 0.75rem 1rem; border-radius: 0.75rem; background: var(--ink); color: #fff; font-weight: 700; }
.skip:focus { top: 0.75rem; }

/* Header (owner, 3 December 2026): the logo, universal search (no background of its own) and icons on #ffffff57,
   then the categories on #ff5f1582 with a thin glass blur, in bold. */
.uni { position: relative; z-index: 30; width: 100%; color: var(--ink); container-type: inline-size; }
.uni-top { position: relative; background: #ffffff57; }
.uni-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "logo tools" "search search"; align-items: center; gap: 0 0.75rem; max-width: 80rem; margin: 0 auto; padding: 0.5rem var(--gutter); }
.uni-logo { grid-area: logo; justify-self: start; }
.uni .tools { grid-area: tools; grid-column: auto; grid-row: auto; gap: 0.25rem; }
.uni .tool { border: 0; background: none; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.uni .tool:hover, .uni .tool[aria-expanded="true"] { background: rgb(255 255 255 / 0.55); }
.menu-btn .i-shut, .menu-btn[aria-expanded="true"] .i-open { display: none; }
.menu-btn[aria-expanded="true"] .i-shut { display: block; }

/* The universal search: a row of its own on phones, opened by the search button. */
.uni-search { grid-area: search; display: none; align-items: stretch; height: 3rem; margin: 0.5rem 0 0.25rem; border: 1px solid var(--line-strong); border-radius: 0.875rem; background: none; }
.uni.search-open .uni-search { display: flex; }
.uni-search:focus-within { border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink); }
.uni-cat { position: relative; display: flex; align-items: center; flex: none; border-right: 1px solid var(--line); }
.uni-cat select { height: 100%; max-width: 8rem; padding: 0 2rem 0 0.875rem; border: 0; border-radius: 0.875rem 0 0 0.875rem; background: transparent; font: inherit; font-size: 0.875rem; font-weight: 600; color: var(--ink); appearance: none; -webkit-appearance: none; cursor: pointer; }
.uni-cat .icon { position: absolute; right: 0.625rem; width: 1rem; height: 1rem; pointer-events: none; }
.uni-search input { flex: 1; min-width: 0; padding: 0 0.875rem; border: 0; background: transparent; font-size: 1rem; outline: 0; }
.uni-search input::placeholder { color: var(--muted); opacity: 1; }
.uni-search button { display: flex; align-items: center; justify-content: center; flex: none; width: 3rem; border-radius: 0 0.8125rem 0.8125rem 0; background: var(--ink); color: #fff; }
.uni-search button .icon { width: 1.25rem; height: 1.25rem; }
.uni-search :focus-visible { outline: 2px solid var(--ink); outline-offset: -4px; }
.uni-search button:focus-visible { outline-color: #fff; }

/* The menu: a drop-down under the bar. Phones: the categories, then the other links at the bottom. */
.menu-drop { position: absolute; top: 100%; left: 0; right: 0; z-index: 40; max-height: calc(100dvh - 4.5rem - var(--bar, 0px)); overflow-y: auto; overscroll-behavior: contain; padding: 0.5rem var(--gutter) 1.25rem; border-bottom: 1px solid var(--line); background: rgb(255 255 255 / 0.8); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); box-shadow: var(--panel-shadow); }
.menu-drop[hidden] { display: none; }
.menu-h { padding: 0.5rem 0 0.25rem; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--soft-ink); }
.menu-cats a, .menu-cats .cat-off { display: flex; align-items: center; min-height: 3rem; font-family: var(--font-display); font-size: 1.375rem; font-weight: 500; letter-spacing: -0.01em; color: var(--ink); }
.menu-cats a[aria-current] { font-weight: 700; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 6px; }
.menu-links { margin-top: 0.75rem; padding-top: 0.5rem; border-top: 1px solid var(--line); }
.menu-links a { display: flex; align-items: center; min-height: 2.75rem; font-size: 1rem; font-weight: 600; color: var(--ink-3); }
.menu-cats a:hover, .menu-links a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 5px; }

/* The categories beneath the bar: a light white overlay with a thin glass blur; desktops only (phones have them in the menu). */
.cats { display: none; border-block: 1px solid rgb(255 255 255 / 0.6); background: #ff5f1582; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.cats-list { display: flex; justify-content: center; gap: 0.25rem; max-width: 80rem; margin: 0 auto; padding: 0.25rem var(--gutter); }
.cats-list a, .cats-list .cat-off { display: flex; align-items: center; height: 2.75rem; padding: 0 0.75rem; border-radius: 0.625rem; font-size: 0.9375rem; font-weight: 700; white-space: nowrap; color: var(--ink); }
.cats-list a:hover { background: rgb(255 255 255 / 0.7); }
.cats-list a[aria-current] { background: var(--ink); color: #fff; }

/* Room for the search in the bar: logo, search, icons on one line. */
@container (min-width: 46rem) {
  .uni-row { grid-template-columns: minmax(max-content, 1fr) minmax(0, 40rem) minmax(max-content, 1fr); grid-template-areas: "logo search tools"; gap: 1.5rem; padding-block: 0.75rem; }
  .uni-search, .uni.search-open .uni-search { display: flex; height: 3.25rem; margin: 0; }
  .uni-cat select { max-width: 11rem; }
  .search-btn { display: none; }
  .wide-only { display: flex; }
  .menu-drop { left: auto; right: max(var(--gutter), calc((100% - 80rem) / 2 + var(--gutter))); width: 22rem; padding-inline: 1.5rem; border: 1px solid var(--line); border-radius: 0 0 1.25rem 1.25rem; }
}
/* Room for every category in a row: the row shows, and the menu keeps only the other links. */
@container (min-width: 72rem) {
  .cats { display: block; }
  .menu-cats { display: none; }
  .menu-links { margin-top: 0; padding-top: 0; border-top: 0; }
}

/* Very large text on a narrow phone: the logo wraps rather than spilling sideways. */
@container (max-width: 14rem) {
  .uni-logo .logo-name { white-space: normal; overflow-wrap: anywhere; }
  .uni-search { flex-wrap: wrap; height: auto; }
  .uni-cat { flex: 1 0 100%; border-right: 0; border-bottom: 1px solid var(--line); }
  .uni-cat select { width: 100%; max-width: none; height: 2.75rem; border-radius: 0.875rem 0.875rem 0 0; }
  .uni-search input { height: 2.75rem; }
  .uni-search button { border-radius: 0 0 0.8125rem 0; }
}

/* The footer: still glass, with more in it on the main home. */
.uni-foot { width: 100%; max-width: 80rem; margin: 1.5rem auto 0; padding: 0 var(--gutter) 1.25rem; }
.uni-foot-in { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.5rem; padding: 1.5rem 1.25rem; border: 1px solid var(--glass-line); border-radius: 1.5rem; background: rgb(255 255 255 / 0.6); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); box-shadow: var(--glass-shadow); }
.foot-brand .logo { padding: 0; }
.foot-brand .logo span { white-space: normal; overflow-wrap: anywhere; }
.foot-brand p:last-child { max-width: 22rem; margin-top: 0.625rem; font-size: 0.875rem; line-height: 1.5; color: var(--ink-3); }
.foot-col h2 { font-size: 0.75rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--soft-ink); }
.foot-col ul { margin-top: 0.375rem; }
.foot-col a, .foot-col button { display: inline-flex; align-items: center; min-height: 2.25rem; font-size: 0.9375rem; color: var(--ink); }
.foot-col a:hover, .foot-col button:hover { text-decoration: underline; text-underline-offset: 3px; }
.foot-copy { margin-top: 1rem; font-size: 0.8125rem; text-align: center; color: var(--ink-3); }

@media (min-width: 36rem) {
  .uni-foot-in { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 48rem) {
  .uni-foot { margin-top: 2.5rem; }
  .uni-foot-in { padding: 2rem 2.25rem; }
}
@media (min-width: 64rem) {
  .uni-foot-in { grid-template-columns: 2fr 1fr 1fr 1fr; }
}

/* A Lab's own pages (Home, Discover, Compare, Saved) at the top of its pages on desktops; phones have the bottom bar.
   No Lab logo (owner, 3 December 2026). */
.lab-bar { display: flex; justify-content: center; width: 100%; max-width: 80rem; margin: 0 auto; padding: 0.5rem 0 0; }
.lab-bar .topnav ul { flex-wrap: wrap; }
@media (min-width: 48rem) {
  .lab-bar { padding: 1.25rem 0 0.75rem; }
}
