/* =========================================================
   Vane & Co. Barbers — styles
   Palette: neutral black + barber crimson. 8px spacing grid.
   ========================================================= */

:root {
  color-scheme: dark;

  /* Surfaces (neutral black, layered) */
  --bg: #0a0a0a;
  --panel: #111111;
  --surface: #141414;
  --surface-2: #1c1c1c;
  --header-bg: rgba(17, 17, 17, .88);
  --bar-bg: rgba(10, 10, 10, .92);

  /* Hairlines and fills */
  --line: rgba(255, 255, 255, .09);
  --line-strong: rgba(255, 255, 255, .16);
  --line-hover: rgba(255, 255, 255, .32);
  --line-faint: rgba(255, 255, 255, .05);
  --fill-hover: rgba(255, 255, 255, .04);

  /* Text */
  --text: #f2f0ec;
  --muted: #8f8f8f;

  /* Accent (the only one) */
  --accent: #b3342b;            /* solid fills, thin lines */
  --accent-hover: #c03a30;      /* button hover (white text 4.7:1) */
  --accent-text: #db6156;       /* accent text and focus rings on black (4.75:1 on #1c1c1c) */
  --accent-tint: rgba(179, 52, 43, .16);
  --accent-tint-soft: rgba(179, 52, 43, .10);
  --accent-line: rgba(219, 97, 86, .45);
  --on-accent: #f2f0ec;

  /* Atmosphere */
  --glow: rgba(179, 52, 43, .07);
  --glow-none: rgba(179, 52, 43, 0);
  --shadow: rgba(0, 0, 0, .5);

  /* Image placeholders */
  --ph-from: #141414;
  --ph-mid: #0f0f0f;
  --ph-to: #0a0a0a;
  --ph-sheen: rgba(255, 255, 255, .045);
  --ph-sheen-none: rgba(255, 255, 255, 0);
  --ph-art: var(--text);

  /* Map placeholder */
  --map-bg: #0e0e0e;
  --map-grid: rgba(255, 255, 255, .04);
  --map-road: #f2f0ec;
  --map-vignette: rgba(10, 10, 10, .6);
  --map-vignette-none: rgba(10, 10, 10, 0);

  /* Type */
  --serif: "Cormorant Garamond", "Iowan Old Style", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  /* Spacing (8px grid) */
  --s1: 8px;  --s2: 16px; --s3: 24px; --s4: 32px;
  --s5: 40px; --s6: 48px; --s8: 64px; --s10: 80px; --s12: 96px;

  /* Shape */
  --r-btn: 6px;
  --r-card: 10px;
  --btn-h: 48px;

  /* Layout */
  --panel-w: 380px;
  --header-h: 72px;
  --gutter: 16px;
  --bar-h: 72px;

  --ease: cubic-bezier(.2, .6, .2, 1);
  --t: 180ms;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
h1, h2, h3, p, ul, ol, address { margin: 0; }
ul, ol { padding: 0; list-style: none; }
address { font-style: normal; }
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; }

.nowrap { white-space: nowrap; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- Focus ---------- */
:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--accent-text);
  outline-offset: 3px;
  border-radius: 4px;
}
.btn:focus-visible { border-radius: var(--r-btn); }
main:focus { outline: none; }

.skip-link {
  position: fixed; top: var(--s1); left: var(--s1); z-index: 100;
  padding: 12px var(--s2);
  background: var(--accent); color: var(--on-accent);
  font-weight: 600; font-size: .875rem; border-radius: var(--r-btn);
  transform: translateY(-160%);
  transition: transform var(--t) var(--ease);
}
.skip-link:focus { transform: none; }

/* ---------- Type ---------- */
h1, h2, h3 { font-family: var(--serif); font-weight: 500; color: var(--text); letter-spacing: -.005em; text-wrap: balance; }
h1, h2, h3, .facts__value, .visit__info address, .brand__name { font-variant-numeric: lining-nums; }
h2 {
  font-size: clamp(2.125rem, 1.6rem + 2vw, 2.75rem);
  line-height: 1.08;
}
.eyebrow {
  font-family: var(--sans);
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--accent-text);
  margin-bottom: var(--s2);
}
.eyebrow--muted { color: var(--muted); }
.lead { color: var(--muted); font-size: 1.0625rem; line-height: 1.65; max-width: 34em; }
.body-text { color: var(--muted); max-width: 36em; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  height: var(--btn-h);
  padding: 0 var(--s3);
  border-radius: var(--r-btn);
  border: 1px solid transparent;
  font-family: var(--sans);
  font-size: .9375rem;
  font-weight: 600;
  letter-spacing: .01em;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--t) var(--ease), border-color var(--t) var(--ease), color var(--t) var(--ease);
}
.btn--primary { background: var(--accent); color: var(--on-accent); }
.btn--primary:hover { background: var(--accent-hover); }
.btn--outline { border-color: var(--line-strong); color: var(--text); background: transparent; }
.btn--outline:hover { border-color: var(--line-hover); background: var(--fill-hover); }
.btn--ghost { border-color: var(--line-strong); color: var(--text); }
.btn--ghost:hover { border-color: var(--line-hover); background: var(--fill-hover); }
.btn--sm { padding: 0 var(--s2); }
.btn--block { width: 100%; }

.icon-btn {
  display: inline-grid; place-items: center;
  width: var(--btn-h); height: var(--btn-h);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-btn);
  background: transparent;
  cursor: pointer;
  transition: border-color var(--t) var(--ease), background-color var(--t) var(--ease);
}
.icon-btn:hover { border-color: var(--line-hover); }
.icon { width: 22px; height: 22px; }
.icon--close { display: none; }
.icon-btn[aria-expanded="true"] .icon--open { display: none; }
.icon-btn[aria-expanded="true"] .icon--close { display: block; }

.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: var(--s4); }
.actions--tight { margin-top: var(--s3); }

.link-arrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 500; font-size: .9375rem;
  color: var(--text);
  padding-block: 4px;
  border-bottom: 1px solid var(--line-strong);
  transition: border-color var(--t) var(--ease);
}
.link-arrow svg { width: 18px; height: 18px; color: var(--muted); transition: transform var(--t) var(--ease); }
.link-arrow:hover { border-color: var(--text); }
.link-arrow:hover svg { color: var(--text); }
.link-arrow:hover svg { transform: translateX(3px); }

/* ---------- Brand ---------- */
.brand { display: inline-flex; align-items: center; gap: 14px; color: var(--text); }
.brand__mark { width: 44px; height: 44px; flex: none; color: var(--text); }
.brand__text { display: flex; flex-direction: column; line-height: 1; }
.brand__name {
  font-family: var(--serif); font-weight: 600;
  font-size: 1.375rem; letter-spacing: .14em;
}
.brand__sub {
  margin-top: 6px;
  font-size: .625rem; font-weight: 600; letter-spacing: .42em;
  color: var(--muted);
}
.brand--compact { gap: 10px; }
.brand--compact .brand__mark { width: 36px; height: 36px; }
.brand--compact .brand__name { font-size: 1.125rem; }
.brand--compact .brand__sub { margin-top: 4px; font-size: .5625rem; letter-spacing: .4em; }

/* ---------- Open status ---------- */
.status { display: flex; align-items: flex-start; gap: 12px; font-size: .9375rem; font-weight: 500; color: var(--text); line-height: 1.4; }
.status__dot { width: 7px; height: 7px; margin-top: 7px; border-radius: 50%; background: var(--muted); flex: none; }
.status > span:last-child { display: grid; gap: 2px; }
.status__sub { font-weight: 400; font-size: .875rem; color: var(--muted); }
.status.is-open .status__dot { background: var(--text); box-shadow: 0 0 0 4px var(--fill-hover); }

/* =========================================================
   Mobile / tablet header
   ========================================================= */
.site-header {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: var(--s2);
  height: calc(var(--header-h) + env(safe-area-inset-top));
  padding: env(safe-area-inset-top) calc(var(--gutter) + env(safe-area-inset-right)) 0 calc(var(--gutter) + env(safe-area-inset-left));
  background: var(--header-bg);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.site-header__actions { display: flex; align-items: center; gap: var(--s1); }

.mobile-menu {
  position: absolute; left: 0; right: 0; top: 100%;
  background: var(--panel);
  border-bottom: 1px solid var(--line);
  padding: var(--s1) var(--gutter) var(--s3);
  max-height: calc(100vh - var(--header-h));
  overflow-y: auto;
}
.mobile-menu[hidden] { display: none; }
.mobile-menu__list li + li { border-top: 1px solid var(--line); }
.mobile-menu__list a {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 56px;
  font-family: var(--serif); font-size: 1.5rem; font-weight: 500;
  color: var(--text);
}
.mobile-menu__list a[aria-current="true"] { color: var(--accent-text); }
.mobile-menu__status { margin-top: var(--s2); padding-top: var(--s3); border-top: 1px solid var(--line); }

/* =========================================================
   Desktop side panel
   ========================================================= */
.panel { display: none; }

/* =========================================================
   Content column
   ========================================================= */
.page { position: relative; isolation: isolate; }
.page::before {
  content: "";
  position: absolute; z-index: -1; inset: 0 0 auto 0;
  height: 720px;
  background: radial-gradient(60% 100% at 50% 0%, var(--glow), var(--glow-none) 70%);
  pointer-events: none;
}
.content {
  container-type: inline-size;
  max-width: 860px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.section {
  padding-block: var(--s10);
  border-top: 1px solid var(--line);
  scroll-margin-top: calc(var(--header-h) + env(safe-area-inset-top));
}
.section:first-child { border-top: 0; }
.section__head { margin-bottom: var(--s5); }
.section__head h2 + .lead { margin-top: var(--s2); }

/* ---------- Placeholder imagery ---------- */
.ph {
  position: relative;
  display: grid; place-items: center;
  overflow: hidden;
  border-radius: var(--r-card);
  border: 1px solid var(--line);
  color: var(--ph-art);
  background:
    radial-gradient(80% 70% at 30% 20%, var(--ph-sheen), var(--ph-sheen-none) 70%),
    linear-gradient(160deg, var(--ph-from) 0%, var(--ph-mid) 55%, var(--ph-to) 100%);
  object-fit: cover;
  width: 100%;
}
.ph::after {
  content: "";
  position: absolute; inset: 12px;
  border: 1px solid var(--line-faint);
  border-radius: 6px;
  pointer-events: none;
}
.ph__art { width: 38%; max-width: 200px; height: auto; aspect-ratio: 1; opacity: .18; }
.ph__art--lg { width: 30%; max-width: 240px; }
.ph--wide { aspect-ratio: 4 / 3; }
.ph--portrait { aspect-ratio: 4 / 5; }
.ph--square { aspect-ratio: 1; }
.ph--b { background:
    radial-gradient(70% 60% at 75% 25%, var(--ph-sheen), var(--ph-sheen-none) 70%),
    linear-gradient(200deg, var(--ph-from) 0%, var(--ph-mid) 55%, var(--ph-to) 100%); }
.ph--c { background:
    radial-gradient(70% 60% at 50% 85%, var(--ph-sheen), var(--ph-sheen-none) 70%),
    linear-gradient(180deg, var(--ph-from) 0%, var(--ph-mid) 60%, var(--ph-to) 100%); }

/* ---------- 1. Intro ---------- */
.intro { padding-top: var(--s6); }
.intro__title {
  font-size: clamp(2.5rem, 1.2rem + 5.4vw, 4.75rem);
  line-height: 1.0;
  letter-spacing: -.015em;
  max-width: 11em;
  text-wrap: wrap;
}
.intro__lead { margin-top: var(--s3); }
.intro .ph--wide { margin-top: var(--s6); }

.facts {
  display: grid; grid-template-columns: 1fr;
  margin-top: var(--s4);
  border-top: 1px solid var(--line);
}
.facts li {
  display: flex; align-items: baseline; justify-content: space-between; gap: var(--s2);
  padding-block: var(--s2);
  border-bottom: 1px solid var(--line);
}
.facts__value { font-family: var(--serif); font-size: 1.375rem; font-weight: 600; line-height: 1.2; }
.facts__label { font-size: .8125rem; color: var(--muted); }

/* ---------- 2. Services ---------- */
.menu-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  padding: var(--s1) var(--s3) var(--s2);
}
.menu-group + .menu-group { margin-top: var(--s2); }
.menu-group__title {
  font-family: var(--sans);
  font-size: .75rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase;
  color: var(--muted);
  padding: var(--s3) 0 12px;
  border-bottom: 1px solid var(--line-strong);
}
.menu-item {
  display: grid;
  grid-template-columns: 1fr auto;
  column-gap: var(--s2);
  padding-block: 20px;
  border-bottom: 1px solid var(--line);
}
.menu-group:last-child .menu-item:last-child { border-bottom: 0; }
.menu-item__head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; }
.menu-item__name { font-size: 1.0625rem; font-weight: 500; color: var(--text); }
.menu-item__time { font-size: .8125rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.menu-item__desc { grid-column: 1 / -1; margin-top: 6px; font-size: .9375rem; color: var(--muted); max-width: 34em; }
.menu-item__price {
  font-size: 1.0625rem; font-weight: 600; color: var(--accent-text);
  font-variant-numeric: tabular-nums lining-nums;
  text-align: right;
}
.pill {
  display: inline-flex; align-items: center;
  height: 22px; padding: 0 10px;
  border-radius: 999px;
  background: var(--accent-tint-soft);
  border: 1px solid var(--accent-line);
  color: var(--accent-text);
  font-size: .6875rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
  line-height: 1;
}

/* ---------- 3. Shop ---------- */
.split { display: grid; gap: var(--s5); }
.split > .ph { order: 2; aspect-ratio: 3 / 2; }
.split__body h2 { margin-bottom: var(--s3); }
.standards { margin-top: var(--s4); border-top: 1px solid var(--line); }
.standards li {
  display: flex; align-items: center; gap: var(--s2);
  padding-block: var(--s2);
  border-bottom: 1px solid var(--line);
  font-size: .9375rem; font-weight: 500;
}
.standards__icon { width: 22px; height: 22px; flex: none; color: var(--muted); }

/* ---------- 4. Team ---------- */
.team { display: grid; gap: var(--s2); }
.barber {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: var(--s3);
  align-items: center;
  padding: var(--s2);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
}
.barber .ph { aspect-ratio: 4 / 5; border-radius: 6px; }
.barber .ph::after { inset: 6px; border-radius: 4px; }
.barber .ph__art { width: 64%; opacity: .16; }
.barber__name { font-size: 1.5rem; font-weight: 600; line-height: 1.15; }
.barber__role { margin-top: 2px; font-size: .8125rem; color: var(--muted); }
.barber__spec { margin-top: 12px; font-size: .9375rem; color: var(--text); line-height: 1.5; }
.barber .link-arrow { margin-top: var(--s2); font-size: .875rem; }

/* ---------- 5. Work ---------- */
.work { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-bottom: var(--s4); }
.work .ph__art { width: 44%; opacity: .15; }

/* ---------- 6. Visit ---------- */
.visit { display: grid; gap: var(--s2); }
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  padding: var(--s3);
}
.card__title {
  font-family: var(--sans);
  font-size: .75rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase;
  color: var(--muted);
  margin-bottom: var(--s2);
}
.hours li {
  display: flex; justify-content: space-between; align-items: center; gap: var(--s2);
  min-height: 44px;
  padding: 0 12px;
  margin-inline: -12px;
  border-radius: 6px;
  font-size: .9375rem;
}
.hours li { position: relative; }
.hours li + li::before {
  content: ""; position: absolute; top: 0; left: 12px; right: 12px;
  height: 1px; background: var(--line);
}
.hours li.is-today::before, .hours li.is-today + li::before { display: none; }
.hours__day { display: flex; align-items: center; gap: 10px; color: var(--text); }
.hours__time { color: var(--muted); font-variant-numeric: tabular-nums; }
.hours__closed { color: var(--muted); }
.hours li.is-today { background: var(--surface-2); box-shadow: none; }
.hours li.is-today .hours__day { font-weight: 600; }
.hours li.is-today .hours__time { color: var(--text); }
.hours__tag {
  font-size: .625rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  color: var(--muted);
}

.visit__info address { font-family: var(--serif); font-size: 1.625rem; font-weight: 500; line-height: 1.25; }
.visit__phone { margin-top: 12px; font-size: 1rem; font-variant-numeric: tabular-nums; }
.visit__phone a { border-bottom: 1px solid var(--line-strong); transition: border-color var(--t) var(--ease); }
.visit__phone a:hover { border-color: var(--text); }
.visit__note { margin-top: var(--s2); font-size: .875rem; color: var(--muted); }
.visit__info .actions .btn { flex: 1 1 auto; }

.map {
  position: relative;
  margin-top: var(--s2);
  height: 240px;
  overflow: hidden;
  border-radius: var(--r-card);
  border: 1px solid var(--line);
  color: var(--map-road);
  background-color: var(--map-bg);
  background-image:
    linear-gradient(var(--map-grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--map-grid) 1px, transparent 1px);
  background-size: 32px 32px;
  background-position: -1px -1px;
}
.map::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(60% 80% at 50% 50%, var(--map-vignette-none), var(--map-vignette));
}
.map__roads { position: absolute; inset: 0; width: 100%; height: 100%; }
.map__pin {
  position: absolute; left: 50%; top: 50%; z-index: 1;
  display: flex; flex-direction: column; align-items: center; gap: var(--s1);
  transform: translate(-50%, -100%);
}
.map__pin svg { filter: drop-shadow(0 4px 8px var(--shadow)); }
.map__pin-body { fill: var(--accent); }
.map__pin-dot { fill: var(--bg); }
.map__label {
  padding: 6px 12px;
  background: var(--surface-2);
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  font-size: .8125rem; font-weight: 500;
  white-space: nowrap;
}

/* ---------- 7. Footer ---------- */
.footer {
  border-top: 1px solid var(--line);
  padding: var(--s6) 0 calc(var(--bar-h) + var(--s4) + env(safe-area-inset-bottom));
}
.footer__inner { max-width: 860px; margin: 0 auto; padding: 0 var(--gutter); }
.footer__top { display: flex; flex-direction: column; gap: var(--s3); }
.footer__links { display: flex; flex-wrap: wrap; gap: var(--s1) var(--s3); font-size: .9375rem; }
.footer__links a {
  display: inline-flex; align-items: center; min-height: 44px;
  color: var(--text);
  transition: color var(--t) var(--ease);
}
.footer__links a:hover { color: var(--accent-text); }
.footer__bottom {
  margin-top: var(--s4); padding-top: var(--s3);
  border-top: 1px solid var(--line);
  display: grid; gap: var(--s1);
  font-size: .8125rem; color: var(--muted);
}
.footer__bottom a { color: var(--text); border-bottom: 1px solid var(--line-strong); transition: border-color var(--t) var(--ease); }
.footer__bottom a:hover { border-color: var(--text); }

/* ---------- 8. Mobile action bar ---------- */
.action-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px;
  padding: 12px calc(var(--gutter) + env(safe-area-inset-right)) calc(12px + env(safe-area-inset-bottom)) calc(var(--gutter) + env(safe-area-inset-left));
  background: var(--bar-bg);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  backdrop-filter: saturate(140%) blur(12px);
  border-top: 1px solid var(--line);
}
.action-bar .btn { width: 100%; }

/* ---------- Motion ---------- */
.js .reveal { opacity: 0; transform: translateY(12px); transition: opacity 600ms var(--ease), transform 600ms var(--ease); }
.js .reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0ms !important; animation-duration: 0ms !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* =========================================================
   Container-based layout (adapts to the content column width)
   ========================================================= */
@container (min-width: 560px) {
  .facts { grid-template-columns: repeat(3, 1fr); border-bottom: 1px solid var(--line); }
  .facts li { flex-direction: column; align-items: flex-start; gap: 4px; padding: var(--s3) var(--s3) var(--s3) 0; border-bottom: 0; }
  .facts li + li { padding-left: var(--s3); border-left: 1px solid var(--line); }
  .work { grid-template-columns: repeat(3, 1fr); gap: var(--s2); }
  .menu-card { padding: var(--s1) var(--s4) var(--s2); }
  .menu-item { column-gap: var(--s4); }
  .visit { grid-template-columns: 1fr 1fr; }
  .card { padding: var(--s4); }
  .map { height: 280px; }
  .ph--wide { aspect-ratio: 16 / 9; }
}

@container (min-width: 640px) {
  .split { grid-template-columns: 5fr 6fr; gap: var(--s6); align-items: center; }
  .split > .ph { order: 0; aspect-ratio: 4 / 5; }
  .team { grid-template-columns: repeat(3, 1fr); gap: var(--s2); }
  .barber { grid-template-columns: 1fr; align-items: start; padding: 12px 12px var(--s3); gap: 0; }
  .barber .ph { margin-bottom: var(--s3); }
  .barber .ph__art { width: 44%; }
  .barber__body { padding-inline: 12px; }
}

/* =========================================================
   Viewport breakpoints
   ========================================================= */
@media (min-width: 600px) {
  :root { --gutter: 32px; }
  .footer__top { flex-direction: row; align-items: center; justify-content: space-between; }
}

@media (min-width: 768px) {
  :root { --gutter: 40px; }
  .section { padding-block: var(--s12); }
  .intro { padding-top: var(--s10); }
}

@media (min-width: 1024px) {
  :root { --gutter: 48px; }

  .site-header, .action-bar { display: none; }

  .panel {
    position: fixed; inset: 0 auto 0 0; z-index: 30;
    display: flex; flex-direction: column; justify-content: space-between; gap: var(--s5);
    width: var(--panel-w);
    padding: var(--s6) var(--s5) var(--s5);
    background: var(--panel);
    border-right: 1px solid var(--line);
    overflow-y: auto;
  }
  .panel__tagline {
    margin-top: var(--s4);
    font-family: var(--serif); font-size: 1.5rem; font-weight: 500; line-height: 1.25;
    color: var(--muted);
  }
  .side-nav { margin-top: var(--s6); }
  .side-nav ol { border-top: 1px solid var(--line); }
  .side-nav li { border-bottom: 1px solid var(--line); }
  .side-nav a {
    position: relative;
    display: flex; align-items: center; gap: var(--s2);
    height: 52px;
    padding-inline: 12px;
    margin-inline: -12px;
    font-size: .9375rem; font-weight: 500;
    color: var(--muted);
    transition: color var(--t) var(--ease), padding var(--t) var(--ease), background-color var(--t) var(--ease);
  }
  .side-nav a::before {
    content: ""; position: absolute; left: 12px; top: 50%;
    width: 0; height: 1px; background: var(--accent-text);
    transition: width var(--t) var(--ease);
  }
  .side-nav__num { font-size: .75rem; font-variant-numeric: tabular-nums; letter-spacing: .06em; color: var(--muted); transition: color var(--t) var(--ease); }
  .side-nav a:hover { color: var(--text); background: var(--surface-2); }
  .side-nav a[aria-current="true"] { color: var(--text); padding-left: 40px; background: var(--surface-2); }
  .side-nav a[aria-current="true"]::before { width: 16px; }
  .side-nav a[aria-current="true"] .side-nav__num { color: var(--text); }

  .panel__bottom { display: grid; gap: var(--s2); padding-top: var(--s3); border-top: 1px solid var(--line); }
  .panel__meta { display: grid; gap: 2px; font-size: .875rem; color: var(--muted); }
  .panel__meta a { color: var(--text); font-variant-numeric: tabular-nums; justify-self: start; transition: color var(--t) var(--ease); }
  .panel__meta a:hover { color: var(--accent-text); }
  .panel .btn--primary { margin-top: var(--s1); }

  .page { margin-left: var(--panel-w); }
  .section { scroll-margin-top: 0; }
  .intro { padding-top: var(--s12); }
  .footer { padding-bottom: var(--s6); }
}

@media (min-width: 1024px) and (max-height: 760px) {
  .panel { padding-top: var(--s5); padding-bottom: var(--s4); }
  .panel__tagline { margin-top: var(--s3); font-size: 1.25rem; }
  .side-nav { margin-top: var(--s4); }
  .side-nav a { height: 44px; }
}

@media (min-width: 1280px) {
  :root { --gutter: 64px; }
}
