/* Layout concept: a dark shop at night with a checkered floor, big serif signage and a barber pole that turns as you scroll. */
:root {
  color-scheme: dark;
  --bg: #0F0E0D;
  --surface: #1B1917;
  --raised: #262320;
  --text: #F0EDE6;
  --muted: #B0ABA1;
  --copper: #D08654;
  --on-copper: #120F0C;
  --brass: #D0AA55;
  --line: rgba(240, 237, 230, .2);
  --cream: #EDE8DD;
  --ink: #171411;
  --display: "Instrument Serif", Georgia, "Times New Roman", serif;
  --body: "Hanken Grotesk", "Segoe UI", system-ui, sans-serif;
  --pole: 12px;
  --header: 76px;
  --on-brass: #171411;
  --btn-hover: #DE9765;
  --ok: #79D69E;
  --guard-off: #4A453E;
  --field-line: #77716A;
}
/* Daytime theme: warm paper instead of the night shop */
:root[data-theme="light"] {
  color-scheme: light;
  --bg: #F7F3EB;
  --surface: #EDE6D9;
  --raised: #E2D9C8;
  --text: #171411;
  --muted: #5A534A;
  --copper: #A65A2C;
  --on-copper: #FFFFFF;
  --brass: #86651B;
  --on-brass: #FFFFFF;
  --line: rgba(23, 20, 17, .18);
  --btn-hover: #8F4C23;
  --ok: #2E8A55;
  --guard-off: #CFC6B6;
  --field-line: #8F877C;
}
body, .site-head, .alt, form, .bar { transition: background-color .35s ease, color .35s ease; }

/* Theme toggle */
.theme-toggle { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 6px 12px; border: 1px solid var(--line); border-radius: 99px; background: none; font-size: .875rem; font-weight: 600; cursor: pointer; }
.theme-toggle:hover { border-color: var(--brass); }
.theme-toggle svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.theme-toggle .i-dark { fill: currentColor; stroke: none; }
.theme-toggle svg { display: none; }
[data-theme-mode="auto"] .theme-toggle .i-auto,
[data-theme-mode="light"] .theme-toggle .i-light,
[data-theme-mode="dark"] .theme-toggle .i-dark { display: block; }
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header) + 12px); -webkit-text-size-adjust: 100%; }
body { margin: 0; padding-left: var(--pole); background: var(--bg); color: var(--text); font: 400 1.0625rem/1.6 var(--body); overflow-x: clip; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 30; background: var(--bg); }
h1, h2, h3, p, figure, blockquote { margin: 0; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; text-wrap: balance; }
h2 { font-size: clamp(2.75rem, 6.5vw, 4.5rem); line-height: 1; }
h2 em, h1 em { font-style: italic; color: var(--brass); }
a { color: inherit; }
button, input, select { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--brass); outline-offset: 3px; }
.wrap { width: 100%; max-width: 1160px; margin-inline: auto; padding-left: max(32px, env(safe-area-inset-left, 0px)); padding-right: max(32px, env(safe-area-inset-right, 0px)); }
.band { padding-block: clamp(64px, 9vw, 112px); }
.alt { background: var(--surface); }
.section-head { display: grid; gap: 14px; margin-bottom: clamp(32px, 5vw, 52px); }
.lead { max-width: 52ch; color: var(--muted); }
.checker { background: conic-gradient(var(--raised) 25%, transparent 0 50%, var(--raised) 0 75%, transparent 0) 0 0 / 44px 44px; }

/* Barber pole */
.pole { position: fixed; z-index: 40; inset: 0 auto 0 0; width: var(--pole); overflow: hidden; background: var(--cream); }
.pole i { position: absolute; inset: -90px 0 0; display: block; will-change: transform;
  background: repeating-linear-gradient(135deg, var(--copper) 0 14px, var(--cream) 14px 28px, var(--ink) 28px 42px, var(--cream) 42px 56px); }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 50px; padding: 12px 30px; border: 0; border-radius: 2px; background: var(--copper); color: var(--on-copper); font-weight: 700; text-decoration: none; cursor: pointer; transition: transform .15s ease, background-color .15s ease; }
.btn:hover { transform: translateY(-2px); background: var(--btn-hover); }

/* Header */
.site-head { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: var(--bg); border-bottom: 1px solid var(--line); }
.site-head .wrap { display: flex; align-items: center; justify-content: space-between; gap: 8px 28px; min-height: var(--header); }
.brand { font: italic 400 1.875rem/1 var(--display); text-decoration: none; white-space: nowrap; }
.nav { display: flex; align-items: center; gap: 28px; font-weight: 500; }
.nav a:not(.btn) { text-decoration: none; }
.nav a:not(.btn):hover { text-decoration: underline; text-decoration-color: var(--brass); text-underline-offset: 6px; }
.nav .btn { min-height: 42px; padding: 8px 20px; }

/* Hero */
.hero { position: relative; display: grid; justify-items: start; gap: 26px; padding-block: clamp(44px, 7vw, 84px) 0; }
.status { display: inline-flex; align-items: center; gap: 10px; padding: 6px 16px; border: 1px solid var(--line); border-radius: 99px; font-size: .9375rem; }
.status::before { content: ""; flex: none; width: 9px; height: 9px; border-radius: 50%; background: var(--ok); }
.status.closed::before { background: var(--brass); }
h1 { font-size: clamp(3.25rem, 11.5vw, 8.75rem); line-height: .92; letter-spacing: -.02em; }
h1 em { display: block; }
.hero-text { max-width: 40ch; font-size: 1.1875rem; color: var(--muted); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; }
.actions span { color: var(--muted); }
.stamp { display: grid; place-content: center; width: 136px; height: 136px; border-radius: 50%; background: var(--brass); color: var(--on-brass); text-align: center; transform: rotate(9deg); outline: 2px dashed var(--on-brass); outline-offset: -9px; }
.stamp b { font: 400 2.625rem/1 var(--display); }
.stamp span { font-size: .75rem; font-weight: 700; line-height: 1.2; }
@media (min-width: 1000px) {
  .stamp { position: absolute; right: 0; top: clamp(90px, 10vw, 130px); width: 172px; height: 172px; }
  .stamp b { font-size: 3.5rem; }
  .stamp span { font-size: .875rem; }
}

/* Checkered floor and ticker */
.floor { height: clamp(120px, 22vw, 230px); margin-top: clamp(32px, 5vw, 56px); overflow: hidden; perspective: 520px; perspective-origin: 50% 0; }
.floor::before { content: ""; display: block; width: 140%; height: 300%; margin-left: -20%; background: conic-gradient(var(--ink) 25%, var(--cream) 0 50%, var(--ink) 0 75%, var(--cream) 0) 0 0 / 96px 96px; transform: rotateX(62deg); transform-origin: 50% 0; -webkit-mask-image: linear-gradient(#000 35%, transparent); mask-image: linear-gradient(#000 35%, transparent); }
.ticker { overflow: hidden; padding-block: 16px; border-block: 1px solid var(--line); white-space: nowrap; }
.ticker div { display: inline-flex; width: max-content; font: italic 400 clamp(1.625rem, 4vw, 2.375rem)/1.1 var(--display); animation: tick 36s linear infinite; }
.ticker span { padding-inline: .45em; }
.ticker span:nth-child(even) { color: var(--brass); }
@keyframes tick { to { transform: translateX(-50%); } }

/* Services */
.menu { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(40px, 6vw, 80px); align-items: start; }
.menu-col { display: grid; gap: 44px; min-width: 0; }
.menu-group { display: grid; }
.menu-group h3 { padding-bottom: 10px; border-bottom: 1px solid var(--brass); font-size: 1.125rem; font-family: var(--body); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--brass); }
.svc { display: grid; grid-template-columns: auto minmax(20px, 1fr) auto; align-items: baseline; gap: 2px 12px; width: 100%; padding: 16px 6px; border: 0; border-bottom: 1px solid var(--line); background: none; text-align: left; cursor: pointer; transition: background-color .15s ease; }
.svc:hover { background: var(--surface); }
.svc b { font: 400 1.75rem/1.15 var(--display); }
.svc .dots { border-bottom: 2px dotted var(--line); transform: translateY(-6px); }
.svc .price { font: italic 400 1.75rem/1 var(--display); font-variant-numeric: tabular-nums; }
.svc small { grid-column: 1 / -1; font-size: .9375rem; color: var(--muted); }

/* Shop */
.cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(28px, 4vw, 48px); }
.cols h3 { margin-bottom: 8px; font-size: 2rem; font-style: italic; line-height: 1.1; }
.cols p { color: var(--muted); }

/* Photos */
.photos { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 14px; }
.photos div { display: grid; align-content: end; aspect-ratio: 4 / 5; padding: 16px; border: 1px solid var(--line); color: var(--muted); font-size: .9375rem; }
.photos div:first-child { aspect-ratio: auto; }

/* Fade guide */
.guide-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 72px); align-items: center; }
.head-panel { padding: 20px; border: 1px solid var(--line); border-radius: 2px; background: var(--cream); }
.head-panel svg { display: block; width: 100%; max-width: 420px; height: auto; margin-inline: auto; }
.head-panel text { font: 700 14px var(--body); fill: #171411; }
.guide-info { display: grid; gap: 28px; min-width: 0; }
.tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.tabs button { min-height: 48px; padding: 8px 6px; border: 1px solid var(--line); border-radius: 2px; background: none; font-weight: 600; cursor: pointer; }
.tabs button[aria-pressed="true"] { border-color: var(--brass); background: var(--brass); color: var(--on-brass); }
.ask { display: grid; gap: 8px; min-height: 140px; align-content: start; }
.ask h3 { font-size: 2.25rem; font-style: italic; line-height: 1.1; }
.ask .upkeep { color: var(--muted); font-size: 1rem; }
.scale-title { margin-bottom: 14px; font-size: .8125rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.scale { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 8px; align-items: end; }
.guard { display: grid; gap: 6px; text-align: center; font-size: .8125rem; line-height: 1.25; color: var(--muted); font-variant-numeric: tabular-nums; }
.guard span { display: block; height: calc(var(--mm) * 4px); background: var(--guard-off); transition: background-color .2s ease; }
.guard b { color: var(--text); font-size: .9375rem; }
.guard.on span { background: var(--brass); }

/* Reviews */
.reviews { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(24px, 4vw, 40px); }
.reviews figure { display: grid; gap: 14px; align-content: start; padding-top: 20px; border-top: 2px solid var(--brass); }
.reviews blockquote { font: italic 400 1.875rem/1.15 var(--display); color: var(--muted); }
.reviews figcaption { font-size: .9375rem; color: var(--muted); }

/* Barbers */
.crew { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(24px, 4vw, 40px); }
.barber { display: grid; gap: 6px; align-content: start; padding-top: 16px; border-top: 1px solid var(--line); }
.barber h3 { font-size: 2.25rem; font-style: italic; line-height: 1.1; }
.barber .role { font-weight: 600; color: var(--brass); }
.barber p { color: var(--muted); }
.barber .days { margin-top: 6px; color: var(--text); font-size: .9375rem; font-weight: 600; }

/* Booking */
.book-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 72px); align-items: start; }
.book-copy { display: grid; gap: 16px; }
.book-copy ul { display: grid; gap: 10px; margin: 8px 0 0; padding: 0; list-style: none; color: var(--muted); }
.book-copy li { position: relative; padding-left: 22px; }
.book-copy li::before { content: ""; position: absolute; left: 0; top: .72em; width: 10px; height: 2px; background: var(--brass); }
form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; padding: clamp(20px, 4vw, 36px); border: 1px solid var(--line); border-radius: 2px; background: var(--bg); }
.field { display: grid; gap: 6px; min-width: 0; }
.field.full, fieldset.full, .confirm, form .btn { grid-column: 1 / -1; }
label, legend { font-size: .9375rem; font-weight: 600; }
input[type="text"], input[type="tel"], input[type="date"], select { width: 100%; min-height: 48px; padding: 10px 12px; border: 1px solid var(--field-line); border-radius: 2px; background: var(--surface); }
select option { background: var(--surface); color: var(--text); }
fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
legend { margin-bottom: 8px; padding: 0; }
.slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.slot { position: relative; }
.slot input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: pointer; }
.slot span { display: grid; place-items: center; min-height: 44px; border: 1px solid var(--field-line); border-radius: 2px; font-size: .9375rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.slot input:checked + span { border-color: var(--brass); background: var(--brass); color: var(--on-brass); }
.slot input:focus-visible + span { outline: 3px solid var(--brass); outline-offset: 2px; }
.confirm { padding: 14px 16px; border-left: 3px solid var(--brass); background: var(--surface); }
.confirm b { display: block; }

/* Visit */
.visit-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(32px, 5vw, 64px); align-items: stretch; }
.visit-info { display: grid; gap: 22px; align-content: start; min-width: 0; }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th, td { padding: 11px 8px; border-bottom: 1px solid var(--line); text-align: left; font-weight: 400; }
td { text-align: right; }
tr.today th, tr.today td { background: var(--raised); color: var(--brass); font-weight: 700; }
.address { font-size: 1.125rem; }
.address a { text-decoration-color: var(--brass); text-underline-offset: 4px; }
.phone-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.phone { font: italic 400 1.875rem/1 var(--display); font-variant-numeric: tabular-nums; }
.copy { min-height: 40px; padding: 6px 14px; border: 1px solid var(--line); border-radius: 2px; background: none; font-size: .9375rem; font-weight: 600; cursor: pointer; }
.map { display: grid; place-content: center; justify-items: center; gap: 10px; min-height: 280px; padding: 24px; border: 1px solid var(--line); font: italic 400 2rem/1.1 var(--display); text-align: center; text-decoration: none; transition: border-color .15s ease; }
.map:hover { border-color: var(--brass); }
.map svg { width: 34px; height: 34px; fill: var(--brass); }

/* Closing call to action */
.tiles { height: 56px; background: conic-gradient(var(--ink) 25%, var(--cream) 0 50%, var(--ink) 0 75%, var(--cream) 0) 0 0 / 56px 56px; }
.cta { display: grid; justify-items: start; gap: 28px; }
.cta h2 { font-size: clamp(3rem, 9vw, 6.25rem); line-height: .96; }
footer { padding-block: 28px; border-top: 1px solid var(--line); color: var(--muted); font-size: .9375rem; }
footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 32px; }
.bar { display: none; }

@media (max-width: 900px) {
  .menu, .guide-grid, .book-grid, .visit-grid, .cols, .reviews, .crew { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 680px) {
  :root { --pole: 6px; --header: 92px; }
  html { scroll-padding-top: 16px; }
  .wrap { padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
  .site-head { position: static; }
  .site-head .wrap { flex-direction: column; align-items: flex-start; padding-block: 12px; }
  .nav { width: 100%; justify-content: space-between; gap: 12px; font-size: .9375rem; }
  .nav .btn { display: none; }
  .theme-toggle { min-height: 36px; padding: 6px 10px; }
  .theme-toggle span { display: none; }
  .photos { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .photos div:first-child { grid-column: span 2; aspect-ratio: 16 / 9; }
  .tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .scale { gap: 4px; }
  .guard { font-size: .75rem; }
  form { grid-template-columns: minmax(0, 1fr); }
  .svc b, .svc .price { font-size: 1.5rem; }
  footer { padding-bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }
  .bar { display: block; position: fixed; z-index: 25; left: var(--pole); right: 0; bottom: 0; padding: 12px max(16px, env(safe-area-inset-right, 0px)) calc(12px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); border-top: 1px solid var(--line); background: var(--bg); }
  .bar .btn { display: flex; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .ticker div { animation: none; }
  .btn, .svc, .guard span, .map { transition: none; }
}
