/* ---------- The main home (index.html; owner, 3 December 2026) ----------
   Header with the universal search in the centre and the category megamenu, a plain hero, categories as
   large photos two to a row, most visited, then saving and owners' sections and a fuller glass footer.
   Builds on site.css and chrome.css (the header and footer every page shares). */

/* Hero: the logo and a few lines on what the site is. */
.uni-main { width: 100%; max-width: 80rem; margin: 0 auto; padding: 0 var(--gutter) 2rem; }
.uni-hero { display: flex; flex-direction: column; align-items: center; padding: 2.5rem 0 1rem; text-align: center; }
.uni-mark { display: inline-flex; align-items: center; gap: 0.625rem; color: var(--ink); }
.uni-mark svg { width: 2.5rem; height: 2.5rem; color: var(--mark); }
.uni-mark span { font-family: var(--font-display); font-size: 2.125rem; line-height: 1; letter-spacing: -0.03em; }
.uni-mark b { font-weight: 700; }
.uni-hero h1 { max-width: 20ch; margin-top: 1.25rem; font-family: var(--font-display); font-size: 1.875rem; font-weight: 600; line-height: 1.08; letter-spacing: -0.03em; text-wrap: balance; }
.uni-lead { max-width: 38rem; margin-top: 0.875rem; font-size: 1.0625rem; line-height: 1.55; color: var(--ink-3); text-wrap: pretty; }
.uni-hero .updated { margin-top: 0.75rem; }

.uni-hero { container-type: inline-size; }
@container (max-width: 14rem) {
  .uni-mark { flex-wrap: wrap; justify-content: center; }
  .uni-mark span { font-size: 1.5rem; overflow-wrap: anywhere; }
}

/* Sections */
.uni-sec { margin-top: 2.5rem; }
.uni-h2 { font-family: var(--font-display); font-size: 1.5rem; font-weight: 600; line-height: 1.2; letter-spacing: -0.02em; color: var(--ink); }
.uni-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem 1rem; }
.uni-note { margin-top: 0.25rem; font-size: 0.875rem; color: var(--ink-3); }

/* Categories: large photos, two to a row, as the old guitar-or-bass page. */
.tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.625rem; margin-top: 1rem; }
/* Two to a row, unless very large text leaves each tile too narrow for its name: then one. */
.tiles-wrap { container-type: inline-size; }
@container (max-width: 15rem) {
  .tiles { grid-template-columns: 1fr; }
  .tiles .tile > a, .tiles .tile-in { aspect-ratio: auto; min-height: 12rem; }
}
/* No overflow clipping: with very large text the tile grows rather than cutting the name off. */
.tile { container-type: inline-size; }
.tile > a, .tile-in { position: relative; display: flex; flex-direction: column; justify-content: flex-end; aspect-ratio: 3 / 4; border-radius: 1.25rem; background: #1c1f24; color: #fff; }
.tile > a:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.tile > a:hover img { filter: brightness(1.08); }
.tile-blank { position: absolute; inset: 0; border-radius: inherit; display: grid; place-items: center; background: linear-gradient(160deg, #2b2f36, #15171b); }
.tile-blank svg { width: 38%; height: auto; aspect-ratio: 1; color: rgb(255 255 255 / 0.07); }
.tile .fade { position: absolute; inset: auto 0 0; height: 70%; border-radius: inherit; border-top-left-radius: 0; border-top-right-radius: 0; background: linear-gradient(0deg, rgb(0 0 0 / 0.92), rgb(0 0 0 / 0.65) 45%, transparent); }
.tile-text { position: relative; display: flex; flex-direction: column; align-items: flex-start; padding: 0 0.875rem 0.875rem; }
/* The name scales with the tile (cqi) so the longest, KEYBOARDS, fits; very large text may wrap it. */
.tile-text strong { max-width: 100%; overflow-wrap: anywhere; margin-top: 0.125rem; font-family: var(--font-display); font-size: clamp(1rem, 13cqi, 1.5rem); font-weight: 700; line-height: 1; letter-spacing: 0.02em; text-transform: uppercase; }
.tile-line { margin-top: 0.375rem; font-size: 0.8125rem; line-height: 1.35; color: rgb(255 255 255 / 0.88); }
.tile-text i { display: flex; align-items: center; justify-content: center; width: 2.5rem; height: 2.5rem; margin-top: 0.75rem; border-radius: 0.75rem; background: var(--brand); color: var(--ink); }
.tile-text i .icon { width: 1.25rem; height: 1.25rem; stroke-width: 2.2; }
.tile > a:hover i { background: var(--brand-hover); }

/* Most visited: a row of white cards that scrolls sideways. */
.carousel-nav { display: flex; gap: 0.5rem; }
.carousel-nav[hidden] { display: none; }
.arrow-btn { display: flex; align-items: center; justify-content: center; width: 2.75rem; height: 2.75rem; border: 1px solid var(--glass-line); border-radius: 0.75rem; background: rgb(255 255 255 / 0.8); box-shadow: var(--glass-shadow); color: var(--ink); }
.arrow-btn .icon { width: 1.25rem; height: 1.25rem; stroke-width: 2.2; }
.arrow-btn:disabled { opacity: 0.4; cursor: default; }
.visited { display: flex; gap: 0.75rem; margin: 0.75rem -0.25rem 0; padding: 0.25rem 0.25rem 0.75rem; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: 0.25rem; scrollbar-width: none; }
.visited::-webkit-scrollbar { display: none; }
.visited li { flex: 0 0 78%; scroll-snap-align: start; }
.vcard { position: relative; height: 100%; display: flex; flex-direction: column; overflow: hidden; border-radius: 1.25rem; background: #fff; box-shadow: var(--panel-shadow); }
.vcard:has(.card-link:focus-visible) { outline: 3px solid var(--ink); outline-offset: -3px; }
.vcard .card-link:focus-visible { outline: 0; }
.vstage { height: 10rem; background: linear-gradient(180deg, #f6f6f7, #eceef1); }
.vstage img { width: 100%; height: 100%; padding: 0.75rem 1.5rem; object-fit: contain; filter: drop-shadow(0 10px 12px rgb(28 30 35 / 0.2)); }
.vmeta { padding: 0.75rem 1rem 1rem; }
.vlab { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.375rem; font-size: 0.75rem; font-weight: 700; color: var(--soft-ink); }
.vlab .tag { position: static; }
.vname { margin-top: 0.125rem; font-family: var(--font-display); font-size: 1.125rem; font-weight: 600; line-height: 1.25; }
.vname .code { font-weight: 500; color: var(--soft-ink); }
.vname a::after { content: ""; position: absolute; inset: 0; }
.vvar { margin-top: 0.125rem; font-size: 0.875rem; color: var(--ink-3); }

/* Saving and owners: white glass bands with their buttons. */
.uni-band { display: flex; flex-direction: column; gap: 1rem; padding: 1.5rem 1.25rem; border: 1px solid var(--glass-line); border-radius: 1.5rem; background: rgb(255 255 255 / 0.82); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); box-shadow: var(--glass-shadow); }
.band-text p { max-width: 46rem; margin-top: 0.5rem; line-height: 1.55; color: var(--ink-3); }
.band-actions { display: flex; flex-wrap: wrap; gap: 0.625rem; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; max-width: 100%; min-height: 3rem; padding: 0.375rem 1.25rem; text-align: center; border-radius: 0.875rem; font-weight: 700; transition: background-color 0.15s; }
.btn .icon { width: 1.25rem; height: 1.25rem; stroke-width: 2; }
.btn-main { background: var(--brand); color: var(--ink); }
.btn-main:hover { background: var(--brand-hover); }
.btn-plain { border: 1px solid var(--line-strong); background: #fff; color: var(--ink); }
.btn-plain:hover { background: var(--raised); }

@media (min-width: 36rem) {
  .visited li { flex-basis: calc((100% - 0.75rem) / 2); }
  .tile > a, .tile-in { aspect-ratio: 4 / 5; }
}
@media (min-width: 48rem) {
  .uni-hero { padding: 4rem 0 1.5rem; }
  .uni-mark svg { width: 3rem; height: 3rem; }
  .uni-mark span { font-size: 2.75rem; }
  .uni-hero h1 { font-size: clamp(2.25rem, 1rem + 2.6vw, 3.25rem); }
  .uni-lead { font-size: 1.1875rem; }
  .uni-sec { margin-top: 3.5rem; }
  .uni-h2 { font-size: 1.875rem; }
  .tiles { gap: 1rem; }
  .tile > a, .tile-in { aspect-ratio: 4 / 3; border-radius: 1.5rem; }
  .tile-text { padding: 0 1.5rem 1.5rem; }
    .tile-text strong { font-size: clamp(1.5rem, 11cqi, 2.75rem); }
  .tile-line { font-size: 1rem; }
  .tile-text i { width: 3rem; height: 3rem; margin-top: 1rem; }
  .visited li { flex-basis: calc((100% - 1.5rem) / 3); }
  .vstage { height: 12rem; }
  .uni-band { flex-direction: row; align-items: center; justify-content: space-between; gap: 2rem; padding: 2rem 2.25rem; }
  .band-actions { flex: none; }
}
@media (min-width: 64rem) {
  .visited li { flex-basis: calc((100% - 2.25rem) / 4); }
  .tile-text strong { font-size: clamp(1.5rem, 11cqi, 3.25rem); }
}
@media (prefers-reduced-motion: reduce) {

}
