/* El Capitan Cuts | "Barber pole" direction. Tokens and section themes are in tokens.css. */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 72px; overflow-x: clip; scrollbar-gutter: stable; background: var(--ink); }
html:has(dialog[open]) { overflow: hidden; }
body {
  margin: 0; background: var(--ink); color: var(--dk-fg);
  font: 400 var(--fs-body)/1.55 var(--font);
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}
img, video { max-width: 100%; }
h1, h2, h3, p, ul, dl, dd { margin: 0; }
ul { padding: 0; list-style: none; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--s-focus); outline-offset: 3px; }
.muted { color: var(--s-muted); }
.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }

.skip { position: absolute; left: 12px; top: -80px; z-index: 40; background: var(--accent); color: #fff; padding: 12px 16px; border-radius: var(--r); font-weight: 600; text-decoration: none; }
.skip:focus { top: 12px; }

/* themed section surfaces */
.t-dark, .t-light { background: var(--s-bg); color: var(--s-fg); }
dialog.sheet.t-dark { background: transparent; }

/* barber pole stripe: the one decorative signature */
.has-stripe { position: relative; }
.has-stripe::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 10px;
  background: repeating-linear-gradient(135deg, var(--accent) 0 14px, #fff 14px 28px, var(--accent2) 28px 42px, #fff 42px 56px);
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; padding: 0 28px; border-radius: var(--r);
  border: 1px solid transparent; background: var(--s-btn-bg); color: var(--s-btn-fg);
  font: 600 1rem/1 var(--font); text-decoration: none; white-space: nowrap; cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  box-shadow: 0 10px 22px -10px rgba(var(--accent-rgb),.65);
  transition: transform .16s var(--ease-out), background-color .2s, border-color .2s, opacity .2s;
}
.btn:active { transform: scale(.98); }
@media (hover: hover) and (pointer: fine) { .btn:hover { background: var(--s-btn-hover); } .btn-ghost:hover { background: transparent; border-color: var(--s-fg); } }
.btn-sm { min-height: 44px; padding: 0 20px; font-size: .9375rem; }
.btn-lg { min-height: 60px; padding: 0 36px; font-size: 1.0625rem; }
.btn-block { width: 100%; }
.btn-ghost { background: transparent; color: var(--s-fg); border-color: var(--s-line2); box-shadow: none; }
.btn[disabled] { opacity: .4; pointer-events: none; box-shadow: none; }

/* ---------- nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: var(--z-nav);
  padding-top: env(safe-area-inset-top); color: var(--dk-fg);
  border-bottom: 1px solid transparent;
  transition: background-color .3s, border-color .3s;
}
.nav.is-solid { background: rgba(var(--ink-rgb),.9); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); border-color: var(--dk-line); }
.nav-in { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { font-weight: 700; font-size: .8125rem; letter-spacing: .18em; text-decoration: none; margin: 0; }

/* ---------- hero ---------- */
.hero {
  position: relative; isolation: isolate; overflow: clip;
  min-height: 100vh; min-height: 100svh;
  display: flex; align-items: flex-end;
  padding-bottom: calc(40px + env(safe-area-inset-bottom));
}
.hero-media { position: absolute; inset: 0; z-index: -1; background: var(--ink); }
.hero-media video { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero-media::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(180deg, rgba(var(--ink-rgb),.62) 0, rgba(var(--ink-rgb),0) 24%, rgba(var(--ink-rgb),0) 38%, rgba(var(--ink-rgb),.78) 72%, var(--ink) 100%),
    radial-gradient(90% 40% at 0% 100%, rgba(var(--glow-rgb),.28), transparent 70%);
}
.hero-copy { position: relative; }
h1 { font-size: var(--fs-h1); line-height: .98; letter-spacing: -.035em; font-weight: 700; text-wrap: balance; max-width: 12ch; margin-bottom: 14px; }
h1 .accent { color: var(--accent-l); }
.lede { font-size: 1.125rem; color: var(--s-muted); margin-bottom: 28px; }
.hero-copy .btn { width: 100%; }

.vtoggle {
  position: absolute; right: 16px; top: calc(76px + env(safe-area-inset-top)); z-index: 2;
  width: 44px; height: 44px; display: grid; place-items: center; cursor: pointer;
  background: rgba(var(--ink-rgb),.62); border: 1px solid rgba(255,255,255,.28); border-radius: var(--r);
  transition: transform .16s var(--ease-out);
}
.vtoggle:active { transform: scale(.94); }
.vt-icon { width: 14px; height: 14px; display: block; background: linear-gradient(90deg, #fff 0 36%, transparent 36% 64%, #fff 64% 100%); }
.vtoggle[aria-pressed="true"] .vt-icon { background: #fff; clip-path: polygon(10% 0, 100% 50%, 10% 100%); }

@media (min-width: 640px) { .hero-copy .btn { width: auto; } }

@media (min-width: 960px) {
  .hero { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); align-items: center; padding-bottom: 0;
    background: radial-gradient(70% 60% at 8% 100%, rgba(var(--glow-rgb),.22), transparent 70%), var(--ink); }
  .hero-media { position: relative; inset: auto; z-index: 0; grid-column: 2; grid-row: 1; height: 100vh; height: 100svh; }
  .hero-media::after {
    background:
      linear-gradient(90deg, var(--ink) 0, rgba(var(--ink-rgb),0) 42%),
      linear-gradient(180deg, rgba(var(--ink-rgb),.55) 0, rgba(var(--ink-rgb),0) 20%, rgba(var(--ink-rgb),0) 78%, var(--ink) 100%);
  }
  .hero-copy { grid-column: 1; grid-row: 1; z-index: 1; max-width: none; margin: 0; padding-right: 24px; padding-left: max(var(--gutter), calc((100vw - var(--max)) / 2 + var(--gutter))); }
  h1 { font-size: clamp(3.25rem, 5.4vw, 5.5rem); max-width: 9ch; }
  .vtoggle { right: max(16px, calc((100vw - var(--max)) / 2 + var(--gutter))); }
}

@media (prefers-reduced-motion: no-preference) {
  .h-in { opacity: 0; transform: translateY(18px); animation: rise .8s var(--ease-out) forwards; animation-delay: calc(.1s + var(--d, 0) * .1s); }
  @keyframes rise { to { opacity: 1; transform: none; } }
}

/* ---------- sections ---------- */
.section { padding-block: var(--section-y); }
.section.has-stripe { padding-top: calc(var(--section-y) + 10px); }
h2 { font-size: var(--fs-h2); line-height: 1.05; letter-spacing: -.03em; font-weight: 700; text-wrap: balance; margin-bottom: clamp(28px, 4vw, 48px); }

.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease-out), transform .7s var(--ease-out); transition-delay: var(--rd, 0s); }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .js .reveal { opacity: 1; transform: none; transition: none; } }

/* services: a white card lifted off the cool paper */
.services { max-width: 820px; background: var(--s-surface); border-radius: var(--r-lg); box-shadow: var(--shadow-card); padding: 6px 24px; border: 1px solid var(--s-line); }
.services li + li { border-top: 1px solid var(--s-line); }
.svc-row {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 20px; row-gap: 2px; align-items: center;
  padding: 22px 0; text-decoration: none; transition: color .2s;
}
.svc-name { font-size: 1.25rem; font-weight: 500; letter-spacing: -.01em; }
.svc-price { grid-column: 2; grid-row: 1 / span 2; font-size: 1.75rem; font-weight: 700; letter-spacing: -.02em; font-variant-numeric: tabular-nums; color: var(--s-accent); }
.svc-desc { color: var(--s-muted); font-size: .9375rem; }
@media (hover: hover) and (pointer: fine) { .svc-row:hover .svc-name { text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 6px; text-decoration-thickness: 2px; } }

/* gallery on navy */
.gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.g-frame { margin: 0; overflow: hidden; aspect-ratio: 4 / 5; border-radius: var(--r); background: var(--s-surface); }
.g-frame img { width: 100%; height: 100%; object-fit: cover; display: block; }
@media (min-width: 960px) { .gallery { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; } }

/* ---------- booking ---------- */
.book-wrap { display: grid; gap: 32px; }
.book-intro h2 { margin-bottom: 12px; }
.book-intro h2:focus { outline: none; }
.form, .done { min-width: 0; }
.form, .done {
  background: var(--s-surface); border: 1px solid var(--s-line); border-radius: var(--r-lg); box-shadow: var(--shadow-card);
  padding: 22px 18px;
}
.form { display: grid; gap: 22px; }
.group { border: 0; padding: 0; margin: 0; min-width: 0; }
.label, legend { display: block; padding: 0; font-size: .875rem; font-weight: 500; color: var(--s-muted); margin-bottom: 8px; letter-spacing: .01em; }
.opt { color: var(--s-muted2); font-weight: 400; }
.field { min-width: 0; }
.row2 { display: grid; gap: 22px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 560px) { .row2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .form, .done { padding: 30px; } }

.svc-grid { display: grid; gap: 8px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 560px) { .svc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.svc-opt { position: relative; display: block; }
.svc-opt input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
.svc-card {
  display: flex; align-items: center; gap: 12px; min-height: 60px; padding: 12px 16px;
  border: 1px solid var(--s-line2); border-radius: var(--r); background: var(--s-surface2);
  transition: border-color .2s, background-color .2s, box-shadow .2s, transform .16s var(--ease-out);
}
.svc-opt:active .svc-card { transform: scale(.985); }
@media (hover: hover) and (pointer: fine) { .svc-opt:hover .svc-card { border-color: var(--s-fg); } }
.svc-dot { flex: none; width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--s-muted2); background: var(--s-surface); transition: background-color .2s, border-color .2s, box-shadow .2s; }
.svc-card .t { flex: 1; min-width: 0; font-weight: 500; }
.svc-card .p { font-variant-numeric: tabular-nums; color: var(--s-muted); font-weight: 500; }
.svc-opt input:checked + .svc-card { border-color: var(--accent); background: var(--accent-tint); box-shadow: inset 0 0 0 1px var(--accent), var(--shadow-lift); }
.svc-opt input:checked + .svc-card .svc-dot { background: var(--accent); border-color: var(--accent); box-shadow: inset 0 0 0 3px var(--accent-tint); }
.svc-opt input:checked + .svc-card .p { color: var(--accent); font-weight: 700; }
.svc-opt input:focus-visible + .svc-card { outline: 2px solid var(--s-focus); outline-offset: 3px; }

.input, .pick {
  width: 100%; min-height: 54px; padding: 14px 16px;
  background: var(--s-surface2); border: 1px solid var(--s-line2); border-radius: var(--r);
  color: var(--s-fg); font: 400 16px/1.4 var(--font);
  -webkit-appearance: none; appearance: none; transition: border-color .2s, box-shadow .2s, background-color .2s;
}
textarea.input { resize: vertical; min-height: 96px; }
.input::placeholder { color: var(--s-muted2); }
.input:focus, .pick:focus-visible { outline: none; background: var(--s-surface); border-color: var(--s-focus); box-shadow: 0 0 0 3px rgba(var(--focus-rgb),.2); }
.pick { display: flex; align-items: center; justify-content: space-between; gap: 12px; text-align: left; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.pick:active { transform: scale(.99); }
.pick-val.is-empty { color: var(--s-muted2); }
.pick-glyph { flex: none; width: 9px; height: 9px; margin: -4px 4px 0 0; border-right: 2px solid var(--s-muted); border-bottom: 2px solid var(--s-muted); transform: rotate(45deg); font-size: 0; }
[aria-invalid="true"] { border-color: var(--s-error) !important; box-shadow: 0 0 0 1px var(--s-error) !important; }
.svc-grid[aria-invalid="true"] { border: 0 !important; box-shadow: none !important; }
.svc-grid[aria-invalid="true"] .svc-card { border-color: var(--s-error); }

.err { display: none; margin-top: 8px; font-size: .875rem; font-weight: 500; color: var(--s-error); }
.err:not(:empty) { display: block; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.summary { min-height: 1.5em; font-size: .9375rem; color: var(--s-muted); }

.done h3 { font-size: 1.5rem; letter-spacing: -.02em; margin-bottom: 4px; }
.done:focus { outline: none; }
.done-list { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px 20px; margin: 20px 0; }
.done-list dt { color: var(--s-muted); }
.done-list dd { font-weight: 500; }
.done .muted { margin-bottom: 20px; font-size: .9375rem; }

@media (min-width: 960px) {
  .book-wrap { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 72px; align-items: start; }
  .book-intro { position: sticky; top: 96px; }
  .form, .done { grid-column: 2; }
}

/* ---------- footer ---------- */
.footer { padding-top: calc(56px + 10px); }
.foot-in { display: grid; gap: 36px; padding-bottom: 40px; }
.contact { margin: 12px 0 16px; color: var(--s-muted); }
.foot-link { display: inline-block; margin-top: 8px; color: var(--accent-l); font-weight: 600; text-underline-offset: 4px; text-decoration-thickness: 1px; }
.hours { display: grid; grid-template-columns: auto auto; justify-content: start; gap: 8px 28px; font-size: .9375rem; }
.hours dt { color: var(--s-muted); }
.hours dd { font-variant-numeric: tabular-nums; }
.legal { border-top: 1px solid var(--s-line); padding-block: 20px calc(100px + env(safe-area-inset-bottom)); font-size: .875rem; }
@media (min-width: 720px) { .foot-in { grid-template-columns: 1fr 1fr; } }
@media (min-width: 960px) { .legal { padding-bottom: 24px; } }

/* ---------- sticky dock (phones and tablets) ---------- */
.dock {
  position: fixed; left: 16px; right: 16px; bottom: calc(12px + env(safe-area-inset-bottom)); z-index: var(--z-dock);
  display: flex; align-items: center; justify-content: center; min-height: 56px;
  background: var(--s-btn-bg); color: var(--s-btn-fg); border-radius: var(--r); font-weight: 600; text-decoration: none;
  box-shadow: 0 14px 30px -10px rgba(var(--ink-rgb),.6);
  transform: translateY(calc(100% + 28px)); visibility: hidden;
  transition: transform .35s var(--ease-out), visibility 0s .35s;
}
.dock.is-on { transform: none; visibility: visible; transition: transform .35s var(--ease-out), visibility 0s; }
.dock:active { transform: scale(.98); }
@media (min-width: 960px) { .dock { display: none; } }
@media (prefers-reduced-motion: reduce) { .dock, .dock.is-on { transition: none; } }

/* ---------- sheets (calendar + time), dark on every page ---------- */
dialog.sheet {
  border: 0; padding: 0; background: transparent; color: var(--s-fg);
  width: 100%; max-width: none; max-height: none; margin: auto 0 0; overflow: visible;
}
dialog.sheet::backdrop { background: rgba(var(--ink-rgb),.82); }
.sheet-in {
  width: 100%; max-width: 520px; margin-inline: auto; max-height: 92vh; max-height: 92dvh; overflow: auto;
  background: linear-gradient(180deg, var(--ink-3) 0, var(--ink-2) 140px); border: 1px solid var(--s-line2); border-bottom: 0;
  border-radius: var(--r-lg) var(--r-lg) 0 0; box-shadow: var(--shadow-dark);
  padding: 10px 20px calc(20px + env(safe-area-inset-bottom));
}
.sheet-grab { width: 36px; height: 4px; border-radius: 2px; background: var(--s-line2); margin: 0 auto 14px; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.sheet-head h3 { font-size: 1.125rem; font-weight: 700; letter-spacing: -.01em; }
.sheet-head-center { justify-content: center; }
.icon-btn {
  width: 44px; height: 44px; display: grid; place-items: center; cursor: pointer;
  background: rgba(255,255,255,.04); border: 1px solid var(--s-line2); border-radius: var(--r);
  color: var(--s-fg); font: 400 1.5rem/1 var(--font); padding: 0 0 3px;
  transition: transform .12s var(--ease-out), opacity .2s, background-color .2s;
}
.icon-btn:active { transform: scale(.94); }
.icon-btn[disabled] { opacity: .3; pointer-events: none; }
.sheet-note { margin-top: 12px; font-size: .875rem; text-align: center; min-height: 1.4em; }
.sheet-close { margin-top: 12px; }
.sheet-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }

@media (min-width: 640px) {
  dialog.sheet { margin: auto; width: min(92vw, 400px); }
  .sheet-in { border-radius: var(--r-lg); border-bottom: 1px solid var(--s-line2); padding-top: 22px; }
  .sheet-grab { display: none; }
}
@media (prefers-reduced-motion: no-preference) {
  dialog.sheet[open] { animation: sheetUp .26s var(--ease-sheet); }
  dialog.sheet[open]::backdrop { animation: fade .22s ease-out; }
  @keyframes sheetUp { from { transform: translateY(28px); opacity: 0; } to { transform: none; opacity: 1; } }
  @keyframes fade { from { opacity: 0; } to { opacity: 1; } }
  @media (min-width: 640px) { dialog.sheet[open] { animation-name: popIn; } @keyframes popIn { from { transform: scale(.97); opacity: 0; } to { transform: none; opacity: 1; } } }
}

/* calendar */
.cal-dow { display: grid; grid-template-columns: repeat(7, 1fr); text-align: center; color: var(--s-muted2); font-size: .8125rem; margin: 10px 0 4px; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.cal-day {
  min-height: 44px; aspect-ratio: 1; display: grid; place-items: center; cursor: pointer; padding: 0;
  background: transparent; border: 1px solid transparent; border-radius: var(--r); color: var(--s-fg);
  font: 500 1rem var(--font); font-variant-numeric: tabular-nums; -webkit-tap-highlight-color: transparent;
  transition: background-color .15s, transform .12s var(--ease-out);
}
.cal-day:active { transform: scale(.92); }
@media (hover: hover) and (pointer: fine) { .cal-day:hover:not([aria-disabled="true"]):not([aria-pressed="true"]) { background: rgba(255,255,255,.09); } }
.cal-day.is-today { border-color: var(--s-muted2); }
.cal-day[aria-disabled="true"] { color: var(--s-muted2); opacity: .4; cursor: default; }
.cal-day[aria-disabled="true"]:active { transform: none; }
.cal-day[aria-pressed="true"] { background: var(--s-btn-bg); color: var(--s-btn-fg); font-weight: 700; }

/* time wheel */
.wheels { position: relative; display: grid; grid-template-columns: 1.1fr 1fr .9fr; height: 220px; margin-top: 8px; overflow: hidden; border-radius: var(--r); background: var(--ink); border: 1px solid var(--s-line); }
.wheel-band { position: absolute; left: 8px; right: 8px; top: 50%; height: 44px; transform: translateY(-50%); border-radius: 10px; background: rgba(var(--accent-rgb),.34); border: 1px solid rgba(var(--accent-l-rgb),.7); pointer-events: none; }
.wheel {
  position: relative; height: 220px; padding-block: 88px; overflow-y: auto; outline: none;
  scroll-snap-type: y mandatory; overscroll-behavior: contain; touch-action: pan-y; scrollbar-width: none; -webkit-overflow-scrolling: touch;
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 32%, #000 68%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0, #000 32%, #000 68%, transparent 100%);
  cursor: grab; user-select: none; -webkit-user-select: none;
}
.wheel::-webkit-scrollbar { display: none; }
.wheel:focus-visible { box-shadow: inset 0 0 0 2px var(--s-focus); border-radius: var(--r); }
.wheel-item {
  height: 44px; display: flex; align-items: center; justify-content: center; scroll-snap-align: center;
  font-size: 1.375rem; font-weight: 500; font-variant-numeric: tabular-nums; opacity: .15;
  transition: opacity .12s, transform .12s;
}
.wheel-item[data-d="0"] { opacity: 1; font-weight: 700; }
.wheel-item[data-d="1"] { opacity: .55; transform: scale(.94); }
.wheel-item[data-d="2"] { opacity: .3; transform: scale(.88); }
.wheel.is-dragging { cursor: grabbing; scroll-snap-type: none; }

/* ---------- color preview switcher (preview only, hidden when showThemePicker is false) ---------- */
.themer { position: fixed; left: 12px; top: calc(76px + env(safe-area-inset-top)); z-index: var(--z-themer); display: grid; gap: 8px; justify-items: start; }
.themer[hidden], .themer-list[hidden] { display: none; }
.themer-btn {
  display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 16px 0 12px; cursor: pointer;
  background: var(--ink-2); color: var(--dk-fg); border: 1px solid var(--dk-line2); border-radius: var(--r);
  font: 600 .9375rem/1 var(--font); box-shadow: var(--shadow-dark); -webkit-tap-highlight-color: transparent;
  transition: transform .16s var(--ease-out);
}
.themer-btn:active { transform: scale(.97); }
.themer-btn:focus-visible, .themer-opt:focus-visible { outline: 2px solid var(--focus-l); outline-offset: 3px; }
.themer-dot { width: 18px; height: 18px; border-radius: 50%; background: conic-gradient(var(--ink-3) 0 33%, var(--accent) 0 66%, var(--paper) 0); border: 1.5px solid var(--dk-muted2); }
.themer-list { background: var(--ink-2); border: 1px solid var(--dk-line2); border-radius: var(--r); padding: 6px; box-shadow: var(--shadow-dark); display: grid; gap: 2px; min-width: 210px; }
.themer-opt {
  display: flex; align-items: center; gap: 12px; width: 100%; min-height: 44px; padding: 0 12px; cursor: pointer; text-align: left;
  background: transparent; color: var(--dk-fg); border: 0; border-radius: 8px; font: 500 .9375rem/1 var(--font);
}
.themer-opt[aria-pressed="true"] { background: rgba(255,255,255,.1); font-weight: 700; }
.themer-sw { display: inline-flex; flex: none; }
.themer-sw i { width: 16px; height: 22px; display: block; border: 1px solid rgba(255,255,255,.25); margin-left: -1px; }
.themer-sw i:first-child { border-radius: 6px 0 0 6px; margin-left: 0; }
.themer-sw i:last-child { border-radius: 0 6px 6px 0; }
