/* ============================================================
   DESIGN BRIEF — Graze & Go · Bandon, OR
   Niche: Artisan charcuterie (boards, boxes, grazing tables,
          mobile cart catering) · Tier: Demo (Old Growth spec)
   Personality: rustic · honest · unfussy
   Direction: Retro / Hand-crafted — a butcher-paper price card
          from a good deli: dot leaders, stamps, warm cream,
          brick & mustard, zero gloss.
   Fonts: Young Serif (400) / Hanken Grotesk (400/600)
          + Yellowtail (400) script accents, used sparingly
   Palette: paper #F6EDDC · ink #2B2013 · accent #A23E2A
            accent-2 #C09038 · dark #32251A
   Image treatment: warm film (sepia .12, sat .88, contrast 1.05)
          + site-wide grain
   Signature moment: the board menu set like a printed butcher-
          paper price card with dot leaders; towns-served ticker
   Primary action: Build your board (order/contact)
   NOTE: Graze & Go is a FICTIONAL business. This site is a
          design demonstration by Rooted Coast Design.
   ============================================================ */

/* ---------- 2 · TOKENS ---------- */
:root {
  /* Color */
  --paper: #F6EDDC;
  --paper-2: #EFE2C8;
  --ink: #2B2013;
  --ink-soft: #6E5E49;
  --accent: #A23E2A;        /* brick — THE accent */
  --accent-ink: #FBF2E4;
  --accent-2: #C09038;      /* mustard — retro second accent, blocks & marks only */
  --line: #DFCFB0;
  --dark: #32251A;          /* espresso */
  --dark-ink: #F2E8D5;
  --ok: #4C6B47;
  --err: #8E3B2C;

  /* Type */
  --font-display: 'Young Serif', Georgia, serif;
  --font-body: 'Hanken Grotesk', system-ui, sans-serif;
  --font-script: 'Yellowtail', cursive;
  --text-hero: clamp(2.5rem, 1rem + 6.5vw, 5.75rem);
  --text-h2: clamp(1.8rem, 1rem + 3vw, 3rem);
  --text-h3: clamp(1.2rem, 1rem + 1vw, 1.5rem);
  --text-body: 1.0625rem;
  --text-small: 0.875rem;
  --text-eyebrow: 0.8125rem;

  /* Space */
  --s1: 0.5rem; --s2: 1rem; --s3: 1.5rem;
  --s4: 2.5rem; --s5: 4rem; --s6: 6.5rem; --s7: 10rem;

  /* Shape & motion */
  --radius: 4px;
  --radius-lg: 10px;
  --shadow-soft: 0 1px 2px rgba(43, 32, 19, 0.08), 0 6px 18px rgba(43, 32, 19, 0.09);
  --shadow-lift: 0 2px 4px rgba(43, 32, 19, 0.1), 0 14px 34px rgba(43, 32, 19, 0.14);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --speed: 0.45s;

  /* Layout */
  --w-narrow: 42rem;
  --w-mid: 60rem;
  --w-wide: 78rem;
  --header-h: 4.25rem;
}

/* ---------- 3 · RESET / BASE ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; overflow-x: clip; }
body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--text-body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
input, button, textarea, select { font: inherit; color: inherit; }
ul[class], ol[class] { list-style: none; padding: 0; }

/* grain overlay — the whole site smells faintly of butcher paper */
body::after {
  content: ""; position: fixed; inset: 0; pointer-events: none;
  z-index: 999; opacity: 0.06; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

[hidden] { display: none !important; }

::selection { background: var(--accent); color: var(--accent-ink); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.skip-link {
  position: absolute; left: var(--s2); top: -100%;
  background: var(--ink); color: var(--paper);
  padding: 0.6em 1.2em; z-index: 1001; border-radius: var(--radius);
  transition: top 0.2s var(--ease);
}
.skip-link:focus { top: var(--s2); }

/* ---------- 4 · TYPOGRAPHY ---------- */
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.01em;
  text-wrap: balance;
}
h1 { font-size: var(--text-hero); }
h2 { font-size: var(--text-h2); }
h3 { font-size: var(--text-h3); }
p { max-width: 65ch; text-wrap: pretty; }

.eyebrow {
  display: block;
  font-size: var(--text-eyebrow);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--s2);
}
.lede { font-size: 1.2rem; color: var(--ink-soft); }
.script-note {
  font-family: var(--font-script);
  font-size: 1.45rem;
  color: var(--accent);
  letter-spacing: 0.01em;
}
.num { font-variant-numeric: tabular-nums; }

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }

/* ---------- 5 · LAYOUT PRIMITIVES ---------- */
.page-grid {
  display: grid;
  grid-template-columns:
    [full-start] minmax(1.25rem, 1fr)
    [content-start] min(100% - 2.5rem, var(--w-wide)) [content-end]
    minmax(1.25rem, 1fr) [full-end];
}
.page-grid > * { grid-column: content; }
.full-bleed { grid-column: full; }

.section { padding-block: var(--s6); }
.section-tight { padding-block: var(--s5); }
.section-grand { padding-block: var(--s7); }
.section-alt { background: var(--paper-2); }
.section-dark { background: var(--dark); color: var(--dark-ink); }
.section-dark .eyebrow { color: var(--accent-2); }
.section-dark h2, .section-dark h3 { color: var(--dark-ink); }
.section-dark a { color: var(--accent-2); }
.section-dark p { color: var(--dark-ink); }

/* cards keep their paper background inside dark sections —
   so their text must stay ink, not dark-ink */
.section-dark .card h3 { color: var(--ink); }
.section-dark .card p,
.section-dark .card .card-desc { color: var(--ink-soft); }
.section-dark .card li { color: var(--ink); }
.section-dark .card a { color: var(--accent); }

.narrow { max-width: var(--w-narrow); }
.mid { max-width: var(--w-mid); }
.center { margin-inline: auto; text-align: center; }
.center p { margin-inline: auto; }

/* image treatment — one, sitewide */
.treat img { filter: sepia(0.12) saturate(0.88) contrast(1.05); }

/* reveal */
[data-reveal] {
  opacity: 0; translate: 0 24px;
  transition: opacity var(--speed) var(--ease), translate var(--speed) var(--ease);
}
[data-reveal].in { opacity: 1; translate: 0 0; }
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1; translate: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- 6 · COMPONENTS ---------- */

/* Demo attribution strip — every page opens with the studio's name on it */
.demo-strip {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: 0.35em 1.25em;
  background: var(--dark); color: var(--dark-ink);
  font-size: var(--text-small);
  text-align: center;
  padding: 0.55em var(--s3);
  border-bottom: 2px solid var(--accent);
}
.demo-strip a { color: var(--accent-2); text-decoration-thickness: 1px; text-underline-offset: 3px; }
.demo-strip a:hover { text-decoration-thickness: 2px; }
.demo-strip-cta { font-weight: 600; white-space: nowrap; }

/* Header — slightly frosted, per the shop window */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in srgb, var(--paper) 82%, transparent);
  backdrop-filter: blur(9px);
  -webkit-backdrop-filter: blur(9px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; align-items: center; gap: var(--s3);
  min-height: var(--header-h);
  padding-block: 0.5rem;
}
.brand {
  font-family: var(--font-display);
  font-size: 1.35rem;
  color: var(--ink);
  text-decoration: none;
  line-height: 1.1;
  flex-shrink: 0;
}
.brand .amp { font-family: var(--font-script); color: var(--accent); font-size: 1.2em; }
.brand small {
  display: block;
  font-family: var(--font-body);
  font-size: 0.6rem; font-weight: 600;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--ink-soft);
}
.site-nav { margin-left: auto; }
.site-nav ul { display: flex; gap: clamp(0.7rem, 1.4vw, 1.4rem); align-items: center; list-style: none; margin: 0; padding: 0; }
.site-nav a {
  font-size: var(--text-small); font-weight: 600;
  color: var(--ink); text-decoration: none;
  padding: 0.35em 0.1em;
  border-bottom: 2px solid transparent;
  transition: border-color 0.2s var(--ease), color 0.2s var(--ease);
  white-space: nowrap;
}
.site-nav a:hover { border-bottom-color: var(--accent-2); }
.site-nav a[aria-current="page"] { color: var(--accent); border-bottom-color: var(--accent); }

.cart-button {
  position: relative;
  display: inline-flex; align-items: center; gap: 0.5em;
  background: none; border: 1.5px solid var(--ink);
  border-radius: var(--radius);
  padding: 0.5em 0.9em;
  font-size: var(--text-small); font-weight: 600;
  cursor: pointer; flex-shrink: 0;
  transition: background 0.2s var(--ease), color 0.2s var(--ease);
}
.cart-button:hover { background: var(--ink); color: var(--paper); }
.cart-count {
  display: inline-grid; place-items: center;
  min-width: 1.4em; height: 1.4em; padding-inline: 0.25em;
  background: var(--accent); color: var(--accent-ink);
  border-radius: 999px;
  font-size: 0.75rem; font-variant-numeric: tabular-nums;
}

.nav-toggle {
  display: none;
  background: none; border: 1.5px solid var(--ink);
  border-radius: var(--radius);
  padding: 0.5em 0.7em; cursor: pointer;
}
.nav-toggle .bar {
  display: block; width: 1.1rem; height: 2px;
  background: var(--ink); margin-block: 3px;
  transition: translate 0.2s var(--ease), rotate 0.2s var(--ease), opacity 0.2s;
}

@media (max-width: 980px) {
  .nav-toggle { display: block; margin-left: auto; }
  /* header's backdrop-filter was trapping the fixed drawer as a containing block — drop it on mobile */
  .site-header { backdrop-filter: none; -webkit-backdrop-filter: none; background: var(--paper); }
  .site-nav {
    position: fixed; inset: 0; top: var(--header-h);
    margin-left: 0;
    background: var(--dark);
    padding: var(--s4) var(--s3);
    translate: 100% 0;
    visibility: hidden; /* keeps closed drawer out of tab order & kills side-scroll */
    transition: translate 0.35s var(--ease), visibility 0s 0.35s;
    overflow-y: auto;
  }
  .site-nav.open { translate: 0 0; visibility: visible; transition: translate 0.35s var(--ease), visibility 0s 0s; }
  .site-nav ul { flex-direction: column; align-items: flex-start; gap: var(--s2); }
  .site-nav a {
    font-family: var(--font-display);
    font-size: clamp(1.6rem, 6vw, 2.2rem);
    font-weight: 400;
    color: var(--dark-ink);
    border-bottom: none;
  }
  .site-nav a[aria-current="page"] { color: var(--accent-2); }
  .nav-toggle[aria-expanded="true"] .bar:nth-child(1) { translate: 0 5px; rotate: 45deg; }
  .nav-toggle[aria-expanded="true"] .bar:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] .bar:nth-child(3) { translate: 0 -5px; rotate: -45deg; }
}

/* Towns ticker */
.ticker {
  overflow: hidden;
  background: var(--dark); color: var(--dark-ink);
  border-block: 1px solid var(--dark);
  padding-block: 0.45rem;
  white-space: nowrap;
}
.ticker-track {
  display: inline-block;
  animation: ticker 130s linear infinite;
  font-size: var(--text-eyebrow); font-weight: 600;
  letter-spacing: 0.18em; text-transform: uppercase;
}
.ticker-track .dot { color: var(--accent-2); margin-inline: 0.9em; }
@keyframes ticker { from { translate: 0 0; } to { translate: -50% 0; } }
@media (prefers-reduced-motion: reduce) { .ticker-track { animation: none; } }

/* Buttons — The Stamp family */
.btn {
  display: inline-block;
  font-weight: 600; font-size: 1rem;
  padding: 0.85em 1.6em;
  border-radius: var(--radius);
  border: 1.5px solid var(--accent);
  background: var(--accent); color: var(--accent-ink);
  text-decoration: none; cursor: pointer;
  transition: background 0.2s var(--ease), translate 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.btn:hover { background: #8C3323; border-color: #8C3323; translate: 0 -1px; box-shadow: var(--shadow-soft); }
.btn:active { translate: 0 0; box-shadow: none; }
.btn-ghost {
  background: transparent; color: var(--ink);
  border-color: var(--ink);
}
.btn-ghost:hover { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.section-dark .btn-ghost { color: var(--dark-ink); border-color: var(--dark-ink); }
.section-dark .btn-ghost:hover { background: var(--dark-ink); color: var(--dark); }
.btn-small { font-size: var(--text-small); padding: 0.7em 1.2em; }

/* Hero — Overlay Masthead */
.hero { position: relative; display: grid; }
.hero-media { grid-area: 1 / 1; position: relative; min-height: min(78vh, 44rem); }
.hero-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-media::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(43, 32, 19, 0.72) 0%, rgba(43, 32, 19, 0.25) 55%, rgba(43, 32, 19, 0.15) 100%);
}
.hero-panel {
  position: relative; z-index: 2;
  /* Stained-glass panel: warm translucent surface so the grazing board
     shows softly through, with a backdrop blur that keeps text readable. */
  background: linear-gradient(160deg, rgba(246,237,220,0.58), rgba(239,226,200,0.70));
  -webkit-backdrop-filter: blur(16px) saturate(1.18);
  backdrop-filter: blur(16px) saturate(1.18);
  border: 1px solid rgba(255,247,232,0.45);
  border-top: 4px solid var(--accent);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  box-shadow: var(--shadow-lift), inset 0 1px 0 rgba(255,255,255,0.5);
  max-width: 44rem;
  margin-top: var(--s6);
  margin-bottom: -1px;
  padding: var(--s4) clamp(1.25rem, 4vw, var(--s5)) var(--s4) 0;
  padding-left: clamp(1.25rem, 4vw, var(--s5));
}
.hero-panel h1 { margin-bottom: var(--s2); }
.hero-panel .lede { margin-bottom: var(--s3); }
.hero-actions { display: flex; flex-wrap: wrap; gap: var(--s2); align-items: center; }

/* page hero (subpages) — shorter */
.hero-sub .hero-media { min-height: min(48vh, 26rem); }

/* Cards — equal height, buttons pinned to the bottom, rows centered */
.card-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--s3);
  align-items: stretch;
}
.card {
  flex: 1 1 17.5rem;
  min-width: min(17.5rem, 100%);
  max-width: 26rem;
  display: flex; flex-direction: column;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  transition: translate 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.card:hover { translate: 0 -4px; box-shadow: var(--shadow-lift); }
.card-media { position: relative; aspect-ratio: 5 / 4; overflow: hidden; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: scale 0.6s var(--ease); }
.card:hover .card-media img { scale: 1.04; }
.card-tag {
  position: absolute; top: var(--s2); left: var(--s2);
  background: var(--accent-2); color: var(--ink);
  font-size: 0.72rem; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase;
  padding: 0.35em 0.7em; border-radius: var(--radius);
  rotate: -2deg;
}
.card-body { display: flex; flex-direction: column; flex: 1; padding: var(--s3); }
.card-title-row {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: var(--s2); margin-bottom: 0.35rem;
}
.card-price {
  font-family: var(--font-display); font-size: 1.15rem;
  color: var(--accent); white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.card-price small { font-family: var(--font-body); font-size: 0.75rem; color: var(--ink-soft); }
.card-desc { font-size: var(--text-small); color: var(--ink-soft); margin-bottom: var(--s2); }
.card-feats { margin: 0 0 var(--s3); font-size: var(--text-small); }
.card-feats li {
  padding-left: 1.1em; position: relative; margin-bottom: 0.3em;
}
.card-feats li::before {
  content: ""; position: absolute; left: 0; top: 0.55em;
  width: 0.45em; height: 0.45em;
  background: var(--accent-2); border-radius: 999px;
}
.card-body .btn { margin-top: auto; align-self: stretch; text-align: center; }

/* Menu ledger — the signature: butcher-paper price card with dot leaders */
.ledger {
  background: var(--paper);
  border: 1.5px solid var(--ink);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  padding: clamp(1.25rem, 4vw, var(--s4));
  position: relative;
}
.ledger::before {
  content: ""; position: absolute; inset: 8px;
  border: 1px solid var(--line);
  border-radius: calc(var(--radius-lg) - 4px);
  pointer-events: none;
}
.ledger h3 {
  text-align: center;
  padding-bottom: var(--s2); margin-bottom: var(--s2);
  border-bottom: 1px solid var(--line);
}
.ledger-row {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.15em 0.6em;
  padding-block: 0.55em;
}
.ledger-row + .ledger-row { border-top: 1px dashed var(--line); }
.ledger-name { font-weight: 600; flex-shrink: 0; white-space: nowrap; }
.ledger-dots {
  flex: 1; min-width: 2em;
  border-bottom: 2px dotted var(--line);
  translate: 0 -0.3em;
}
.ledger-price {
  font-family: var(--font-display);
  color: var(--accent);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.ledger-note { font-size: var(--text-small); color: var(--ink-soft); }
@media (max-width: 640px) {
  .ledger-name { white-space: normal; }
  .ledger-note { flex-basis: 100%; }
}

/* Demo notes — Rooted Coast callout */
.demo-note {
  background: var(--paper-2);
  border: 1.5px dashed var(--accent);
  border-radius: var(--radius-lg);
  padding: var(--s3);
  max-width: var(--w-narrow);
}
.demo-note .script-note { display: block; margin-bottom: 0.35rem; }
.demo-note p { font-size: var(--text-small); margin-bottom: var(--s2); }
.section-dark .demo-note { background: rgba(246, 237, 220, 0.06); }
.section-dark .demo-note p { color: var(--dark-ink); }

/* studio credit line */
.studio-note {
  font-family: var(--font-script);
  font-size: 1.3rem;
  color: var(--ink-soft);
  margin-top: var(--s3);
}
.studio-note a { color: var(--accent); text-decoration-thickness: 1px; }

/* Steps (how to order) */
.steps { counter-reset: step; display: grid; gap: var(--s3); max-width: var(--w-mid); }
.step {
  counter-increment: step;
  display: grid; grid-template-columns: auto 1fr; gap: var(--s3);
  padding: var(--s3);
  background: var(--paper);
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
}
.step::before {
  content: "0" counter(step);
  font-family: var(--font-display);
  font-size: 2.2rem; line-height: 1;
  color: var(--accent-2);
}
.step h3 { margin-bottom: 0.3rem; }
.step p { font-size: var(--text-small); color: var(--ink-soft); }

/* Reviews — one featured pull-quote, then an editorial quote wall (no card grid) */
.review-feature {
  border-block: 2px solid var(--ink);
  padding: var(--s4) 0;
  margin-bottom: var(--s4);
  max-width: var(--w-mid);
}
.review-feature blockquote {
  font-family: var(--font-display);
  font-size: clamp(1.45rem, 1rem + 1.8vw, 2.15rem);
  line-height: 1.3;
  margin-block: var(--s2);
  text-wrap: balance;
}
.review-feature footer { font-size: var(--text-small); color: var(--ink-soft); font-weight: 600; letter-spacing: 0.04em; }
.review-wall { columns: 2 20rem; column-gap: var(--s4); max-width: var(--w-mid); padding-top: 0.8rem; }
/* comment cards pinned above the deli counter */
.review {
  break-inside: avoid;
  background: var(--paper);
  border: 1.5px solid var(--ink);
  border-radius: var(--radius);
  padding: var(--s3);
  margin-bottom: var(--s3);
  box-shadow: 4px 4px 0 rgba(43, 32, 19, 0.15);
  position: relative;
  rotate: -0.5deg;
}
.review:nth-child(even) { rotate: 0.5deg; }
.review::before {
  content: ""; position: absolute; top: -0.6rem; left: 50%; translate: -50% 0; rotate: -2deg;
  width: 4.5rem; height: 1.15rem;
  background: var(--accent-2); opacity: 0.45;
}
.review::after {
  content: ""; position: absolute; inset: 7px;
  border: 1px dashed var(--line); pointer-events: none;
}
.stars { color: var(--accent-2); letter-spacing: 0.15em; font-size: 0.95rem; margin-bottom: var(--s1); }
.review blockquote { font-size: 1.02rem; margin-bottom: var(--s2); }
.review footer { font-size: var(--text-small); color: var(--ink-soft); font-weight: 600; }

/* FAQ */
.faq { max-width: var(--w-narrow); }
/* FAQ — ruled ledger rows with index numbers, not a stack of boxes */
.faq { counter-reset: q; max-width: var(--w-mid); border-top: 2px solid var(--ink); }
.faq details { border-bottom: 1px dashed var(--line); }
.faq summary {
  cursor: pointer; font-weight: 600;
  font-family: var(--font-display); font-size: 1.15rem;
  padding: var(--s3) 3rem var(--s3) 0;
  list-style: none; position: relative;
}
.faq summary::before {
  counter-increment: q;
  content: counter(q, decimal-leading-zero);
  font-family: var(--font-body); font-size: var(--text-eyebrow); font-weight: 600;
  color: var(--accent); letter-spacing: 0.1em;
  margin-right: var(--s2);
  font-variant-numeric: tabular-nums;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 0.25rem; top: 50%;
  translate: 0 -50%;
  font-family: var(--font-display); font-size: 1.4rem; color: var(--accent);
  transition: rotate 0.25s var(--ease);
}
.faq details[open] summary::after { rotate: 45deg; }
.faq summary:hover { color: var(--accent); }
.faq summary:focus-visible { outline: none; background: var(--paper-2); box-shadow: inset 4px 0 0 var(--accent); }
.faq details > div { padding: 0 0 var(--s3); color: var(--ink-soft); max-width: 62ch; }

/* Gallery */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: var(--s2);
}
.gallery-grid figure { position: relative; overflow: hidden; border-radius: var(--radius-lg); grid-column: span 2; }
.gallery-grid figure.wide { grid-column: span 4; }
.gallery-grid figure img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4 / 3; transition: scale 0.6s var(--ease); }
.gallery-grid figure.wide img { aspect-ratio: 2 / 1; }
.gallery-grid figure:hover img { scale: 1.04; }
.gallery-grid figcaption {
  position: absolute; inset: auto 0 0;
  padding: 1.5rem var(--s2) var(--s2);
  background: linear-gradient(to top, rgba(43, 32, 19, 0.75), transparent);
  color: var(--dark-ink); font-size: var(--text-small);
}
@media (max-width: 720px) {
  .gallery-grid { grid-template-columns: 1fr 1fr; }
  .gallery-grid figure, .gallery-grid figure.wide { grid-column: span 2; }
}

/* Forms */
.form-grid { display: grid; gap: var(--s3); max-width: var(--w-narrow); }
.form-row { display: grid; gap: var(--s3); grid-template-columns: 1fr 1fr; }
@media (max-width: 640px) { .form-row { grid-template-columns: 1fr; } }
.field label {
  display: block; font-weight: 600; font-size: var(--text-small);
  margin-bottom: 0.35rem;
}
.field label .req { color: var(--accent); }
.field input, .field textarea, .field select {
  width: 100%;
  background: var(--paper);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  padding: 0.7em 0.9em;
  font-size: 1rem; /* ≥16px — no iOS zoom */
  transition: border-color 0.2s var(--ease);
}
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; border-color: var(--accent);
}
.field .hint { font-size: 0.8rem; color: var(--ink-soft); margin-top: 0.3rem; }
.form-msg { border-radius: var(--radius); padding: var(--s2) var(--s3); font-weight: 600; }
.form-msg.ok { background: #E7EDE2; color: var(--ok); border: 1px solid var(--ok); }
.form-msg.err { background: #F3E0DA; color: var(--err); border: 1px solid var(--err); }
.hp-field { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

/* Cart drawer */
.cart-scrim {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(43, 32, 19, 0.5);
  opacity: 0; pointer-events: none;
  transition: opacity 0.3s var(--ease);
}
.cart-scrim.show { opacity: 1; pointer-events: auto; }
.cart-drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 201;
  width: min(26rem, 100%);
  /* the drawer IS a cutting board: maple planks + grain streaks */
  background-color: #A97C48;
  background-image:
    repeating-linear-gradient(178deg, rgba(50, 37, 26, 0.07) 0 2px, transparent 2px 9px),
    linear-gradient(90deg, rgba(50, 37, 26, 0.16), rgba(246, 237, 220, 0.10) 22%, rgba(50, 37, 26, 0.05) 60%, rgba(50, 37, 26, 0.14)),
    repeating-linear-gradient(90deg, transparent 0 calc(25% - 1px), rgba(50, 37, 26, 0.28) calc(25% - 1px) 25%);
  border-left: 5px solid #7E5A33; /* board edge */
  border-radius: 1.1rem 0 0 1.1rem;  /* rounded board corners on the leading edge */
  box-shadow: inset 2px 0 0 rgba(246, 237, 220, 0.22), var(--shadow-lift);
  display: flex; flex-direction: column;
  translate: 100% 0;
  visibility: hidden; /* keeps closed drawer out of tab order & kills side-scroll */
  transition: translate 0.35s var(--ease), visibility 0s 0.35s;
}
/* the punched handle hole */
.cart-drawer::before {
  content: ""; position: absolute; top: 1.05rem; left: var(--s3);
  width: 1.35rem; height: 1.35rem; border-radius: 50%;
  background: rgba(43, 32, 19, 0.62);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.45), 0 1px 0 rgba(246, 237, 220, 0.3);
}
.cart-drawer.open { translate: 0 0; visibility: visible; transition: translate 0.35s var(--ease), visibility 0s 0s; }
@media (prefers-reduced-motion: reduce) {
  .cart-drawer, .cart-scrim, .site-nav { transition: none; }
}
.cart-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: var(--s2) var(--s3) var(--s2) calc(var(--s3) + 2.1rem); /* clears the handle hole */
}
.cart-head h2 { font-size: 1.4rem; color: var(--dark); text-shadow: 0 1px 0 rgba(246, 237, 220, 0.25); }
.cart-close {
  background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--radius);
  width: 2.2rem; height: 2.2rem; cursor: pointer;
  font-size: 1.1rem; line-height: 1;
}
.cart-close:hover { background: var(--ink); color: var(--paper); }
/* the order list is a butcher-paper sheet laid on the board */
.cart-drawer .cart-items {
  flex: 1; overflow-y: auto;
  padding: var(--s2) var(--s3);
  margin: 0 var(--s2);
  background: var(--paper);
  border-radius: 2px 2px 0 0;
  box-shadow: 0 3px 14px rgba(43, 32, 19, 0.3);
}
.cart-item {
  display: grid; grid-template-columns: 1fr auto; gap: 0.25rem var(--s2);
  padding-block: var(--s2);
  border-bottom: 1px dashed var(--line);
}
.cart-item-name { font-weight: 600; }
.cart-item-unit { font-size: 0.8rem; color: var(--ink-soft); }
.cart-item-price { font-family: var(--font-display); color: var(--accent); font-variant-numeric: tabular-nums; text-align: right; }
.cart-qty { display: inline-flex; align-items: center; gap: 0.6em; margin-top: 0.3rem; }
.cart-qty button {
  width: 1.7rem; height: 1.7rem;
  border: 1.5px solid var(--line); border-radius: var(--radius);
  background: none; cursor: pointer; line-height: 1;
}
.cart-qty button:hover { border-color: var(--ink); }
.cart-qty .q { min-width: 1.5em; text-align: center; font-variant-numeric: tabular-nums; font-weight: 600; }
.cart-remove {
  background: none; border: none; cursor: pointer;
  font-size: 0.8rem; color: var(--ink-soft);
  text-decoration: underline; text-underline-offset: 2px;
  justify-self: end; padding: 0;
}
.cart-remove:hover { color: var(--err); }
.cart-empty { text-align: center; color: var(--ink-soft); padding: var(--s5) var(--s3); }
.cart-empty .script-note { display: block; margin-bottom: var(--s1); }
.cart-foot {
  padding: var(--s3); border-top: 1.5px dashed var(--line);
  background: var(--paper-2);
  margin: 0 var(--s2) var(--s2);
  border-radius: 0 0 2px 2px;
  box-shadow: 0 3px 14px rgba(43, 32, 19, 0.3);
}
.cart-subtotal {
  display: flex; justify-content: space-between; align-items: baseline;
  font-weight: 600; margin-bottom: var(--s1);
}
.cart-subtotal .num { font-family: var(--font-display); font-size: 1.3rem; color: var(--accent); }
.cart-foot .fine { font-size: 0.8rem; color: var(--ink-soft); margin-bottom: var(--s2); }
.cart-foot .btn { width: 100%; text-align: center; }

/* toast feedback on Add buttons */
.btn[data-added] { background: var(--ok); border-color: var(--ok); }

/* Checkout */
.checkout-grid {
  display: grid; gap: var(--s4);
  grid-template-columns: 1.2fr 1fr;
  align-items: start;
}
@media (max-width: 900px) { .checkout-grid { grid-template-columns: 1fr; } }
.order-summary { position: sticky; top: calc(var(--header-h) + var(--s2)); }
.order-summary .ledger-row .ledger-name { font-weight: 400; }

/* Stat row / trust strip */
.trust-strip {
  display: grid; gap: var(--s3);
  grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
  text-align: center;
}
.trust-strip .stat b {
  display: block; font-family: var(--font-display);
  font-size: 2rem; color: var(--accent);
  font-variant-numeric: tabular-nums;
}
.trust-strip .stat span { font-size: var(--text-small); color: var(--ink-soft); }
.section-dark .trust-strip .stat b { color: var(--accent-2); }
.section-dark .trust-strip .stat span { color: var(--dark-ink); }

/* Split feature (image + text, used sparingly, offset) */
.split { display: grid; gap: var(--s4); grid-template-columns: 5fr 6fr; align-items: center; }
.split.flip { grid-template-columns: 6fr 5fr; }
.split-media { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-lift); rotate: -1deg; }
.split.flip .split-media { rotate: 1deg; }
.split-media img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4 / 3; }
@media (max-width: 800px) { .split, .split.flip { grid-template-columns: 1fr; } }

/* Footer */
.site-footer { background: var(--dark); color: var(--dark-ink); }
.footer-grid {
  display: grid; gap: var(--s4);
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
  padding-block: var(--s5) var(--s4);
}
.site-footer h2 { font-size: 1.3rem; margin-bottom: var(--s2); }
.site-footer .brand { color: var(--dark-ink); font-size: 1.5rem; }
.site-footer p, .site-footer li { font-size: var(--text-small); color: color-mix(in srgb, var(--dark-ink) 82%, transparent); }
.site-footer a { color: var(--dark-ink); }
.site-footer a:hover { color: var(--accent-2); }
.site-footer address { font-style: normal; }
.footer-links li { margin-bottom: 0.4em; }
.footer-fine {
  border-top: 1px solid color-mix(in srgb, var(--dark-ink) 20%, transparent);
  padding-block: var(--s3);
  font-size: 0.8rem;
  color: color-mix(in srgb, var(--dark-ink) 70%, transparent);
}
.footer-fine p { font-size: 0.8rem; max-width: none; }
.footer-bar {
  background: var(--accent); color: var(--accent-ink);
  text-align: center; font-size: var(--text-small); font-weight: 600;
  padding-block: 0.6rem;
}
.footer-bar a { color: var(--accent-ink); }

/* 404 */
.lost { min-height: 60vh; display: grid; place-items: center; text-align: center; }
.lost .script-note { font-size: 2rem; }

/* utilities */
.mt-2 { margin-top: var(--s2); } .mt-3 { margin-top: var(--s3); }
.mt-4 { margin-top: var(--s4); } .mt-5 { margin-top: var(--s5); }
.mb-2 { margin-bottom: var(--s2); } .mb-3 { margin-bottom: var(--s3); }
.mb-4 { margin-bottom: var(--s4); }
.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  clip-path: inset(50%); overflow: hidden; white-space: nowrap;
}

/* ============================================================
   Navbar declutter + elevated mobile drawer — Rooted Coast Design
   The .nav-cta-m (Build/Book buttons) and .nav-contact-m (phone/email)
   are drawer-only; hiding them on desktop clears the overloaded bar and
   removes the phone/email overlap. On mobile they become a proper,
   designed footer inside the drawer.
   ============================================================ */
.nav-cta-m,
.nav-contact-m { display: none; }

@media (max-width: 980px) {
  /* Drawer shell: warm glow + roomier padding */
  .site-nav {
    background:
      radial-gradient(130% 55% at 100% 0%, rgba(192, 144, 56, 0.12), transparent 60%),
      var(--dark);
    padding: var(--s4) var(--s4) var(--s5);
  }
  .site-nav ul { gap: 0; }
  .site-nav > ul > li { width: 100%; }

  /* Page links: hairline separators + generous tap targets */
  .site-nav ul li:not(.nav-cta-m):not(.nav-contact-m) + li:not(.nav-cta-m):not(.nav-contact-m) {
    border-top: 1px solid rgba(242, 239, 230, 0.09);
  }
  .site-nav a:not(.btn) { display: block; width: 100%; padding: 0.55rem 0; }

  /* Staggered entrance as the drawer slides in */
  .site-nav.open li { animation: navIn 0.45s var(--ease) both; }
  .site-nav.open li:nth-child(1)  { animation-delay: 0.04s; }
  .site-nav.open li:nth-child(2)  { animation-delay: 0.08s; }
  .site-nav.open li:nth-child(3)  { animation-delay: 0.12s; }
  .site-nav.open li:nth-child(4)  { animation-delay: 0.16s; }
  .site-nav.open li:nth-child(5)  { animation-delay: 0.20s; }
  .site-nav.open li:nth-child(6)  { animation-delay: 0.24s; }
  .site-nav.open li:nth-child(7)  { animation-delay: 0.28s; }
  .site-nav.open li:nth-child(8)  { animation-delay: 0.32s; }
  .site-nav.open li:nth-child(9)  { animation-delay: 0.36s; }
  .site-nav.open li:nth-child(10) { animation-delay: 0.40s; }
  .site-nav.open li:nth-child(11) { animation-delay: 0.44s; }
  @keyframes navIn { from { opacity: 0; translate: 0 14px; } to { opacity: 1; translate: 0 0; } }
  @media (prefers-reduced-motion: reduce) { .site-nav.open li { animation: none; } }

  /* CTA buttons: full-width, stacked, breathing room above */
  .nav-cta-m { display: block; width: 100%; }
  .nav-cta-m + .nav-cta-m { margin-top: 0.7rem; }
  .site-nav .nav-cta-m:first-of-type { margin-top: var(--s3); }
  .nav-cta-m .btn {
    display: block; width: 100%; text-align: center;
    font-size: 1.05rem; padding: 0.9rem 1rem;
  }
  .nav-cta-m .btn-ghost { border-color: rgba(242, 239, 230, 0.5); color: var(--dark-ink); }

  /* Contact: label + phone + email, cleanly stacked (fixes the overlap) */
  .nav-contact-m {
    display: flex; flex-direction: column; gap: 0.1rem;
    margin-top: var(--s3); padding-top: var(--s3);
    border-top: 1px solid rgba(242, 239, 230, 0.14);
  }
  .nav-contact-m a {
    font-family: var(--font-display); font-weight: 400;
    font-size: 1.5rem; color: var(--dark-ink);
    line-height: 1.2; border-bottom: none;
  }
  .nav-contact-m span { color: rgba(242, 239, 230, 0.66); font-size: 0.95rem; }

  /* Studio signature doubling as a clever credit — the two crafts in
     parallel: the boards are Graze's, the site is ours. */
  .site-nav > ul::after {
    content: "Boards built by hand. Site built by Rooted Coast Design.";
    display: block; width: 100%;
    margin-top: var(--s4);
    font-family: var(--font-script);
    font-size: 1.45rem; line-height: 1.15;
    color: var(--accent-2);
  }
}

/* Mobile homepage hero: give the board photo more presence — a taller media
   area so more of the spread shows above the stained-glass panel. Subpage
   heroes (.hero-sub .hero-media) keep their shorter height via higher specificity. */
@media (max-width: 760px) {
  .hero-media { min-height: min(96vh, 52rem); }
}
