/* Toto — Gen Z pine/brown/gold design system */

:root {
  --pine-deep: #13201a;
  --pine: #253a2f;
  --pine-mid: #2d4638;
  --pine-soft: #3a5746;
  --cream: #e0b95a;
  --cream-warm: #ede3cf;
  --paper: #f7f1e3;
  --brown: #5a3e2b;
  --tan: #a87a4e;
  --gold: #c9a24e;
  --gold-bright: #e0b95a;
  --ink: #0f0f0f;
  --ink-soft: #1a1612;

  --radius-sm: 10px;
  --radius-md: 18px;
  --radius-lg: 28px;
  --radius-xl: 40px;

  --shadow-chunk: 6px 6px 0 var(--ink);
  --shadow-chunk-gold: 6px 6px 0 var(--gold);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  background: var(--pine-deep);
  color: var(--cream);
  font-family: 'Geist', 'Inter', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  max-width: 100vw;
}

.font-display { font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800; letter-spacing: -0.03em; line-height: 0.92; }
.font-serif-italic { font-family: 'DM Serif Display', 'Instrument Serif', serif; font-style: italic; font-weight: 400; letter-spacing: -0.01em; }
.font-mono { font-family: 'JetBrains Mono', monospace; font-size: 0.72rem; letter-spacing: 0.06em; text-transform: uppercase; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 22px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  font-family: 'Geist', sans-serif;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  transition: transform 120ms ease, box-shadow 120ms ease;
  text-decoration: none;
  white-space: nowrap;
}
.btn-primary {
  background: var(--gold);
  color: var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
}
.btn-primary:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--ink); }
.btn-primary:active { transform: translate(2px, 2px); box-shadow: 2px 2px 0 var(--ink); }
.btn-ghost {
  background: transparent;
  color: var(--cream);
  border-color: var(--cream);
}
.btn-ghost:hover { background: var(--cream); color: var(--ink); }
.btn-cream {
  background: var(--cream);
  color: var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
}
.btn-cream:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--ink); }

/* Pill label */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border: 1.5px solid currentColor;
  border-radius: 999px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

/* Sticker card */
.card {
  background: var(--cream);
  color: var(--ink);
  border: 2px solid var(--ink);
  border-radius: var(--radius-md);
  box-shadow: 6px 6px 0 var(--ink);
}

/* Reviews grid — fixed columns so a row never orphans a single card.
   (Was auto-fit, which stranded a lone 5th card with empty space beside it,
   and would 3+1 at some widths.) Degrades 4 → 2 → 1 so 4 cards always wrap
   evenly. align-items:start lets each sticker card keep its natural height
   when a long review is expanded, instead of all stretching to match. */
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  align-items: start;
}
@media (max-width: 1100px) {
  .reviews-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .reviews-grid { grid-template-columns: 1fr; }
}

/* Section helpers */
.section {
  padding: 96px 48px;
  position: relative;
}
@media (max-width: 760px) {
  .section { padding: 64px 20px; }

  /* Booking modal: stack form above order summary */
  .booking-grid {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
  }

  /* FAQ: single column instead of split title/cards */
  .faq-grid {
    grid-template-columns: 1fr !important;
    gap: 32px !important;
  }

  /* Hero grid (toto drop, etc): single column */
  .hero-grid {
    grid-template-columns: 1fr !important;
    gap: 32px !important;
  }

  /* Location section: single column, map below text */
  .location-grid {
    grid-template-columns: 1fr !important;
    gap: 32px !important;
  }

  /* Cap location headline so "downtown toronto. that's it. that's the post." doesn't break one word per line */
  .location-headline {
    font-size: clamp(56px, 14vw, 96px) !important;
    line-height: 0.95 !important;
  }

  /* Stars: force text rendering, not emoji rendering, on iOS */
  .star {
    font-family: 'Geist Mono', 'Courier New', monospace !important;
    font-variant-emoji: text;
    text-rendering: optimizeLegibility;
  }

  /* Pills shrink + wrap at narrow widths */
  .pill {
    font-size: 11px !important;
    padding: 8px 14px !important;
    white-space: normal !important;
    word-break: keep-all;
    max-width: 100%;
    line-height: 1.3;
  }

  /* Hero headline cap — prevent overflow at narrow viewports */
  .hero-headline {
    font-size: clamp(44px, 11vw, 88px) !important;
    line-height: 0.95 !important;
  }

  /* Tier cards: let them shrink to fit, no min-width */
  .tier-card {
    min-width: 0 !important;
    max-width: 100% !important;
  }

  /* Order summary card: don't overflow */
  .order-summary {
    min-width: 0 !important;
    max-width: 100% !important;
  }

  /* Footer: stack columns vertically on mobile */
  .footer-grid {
    grid-template-columns: 1fr !important;
    gap: 32px !important;
  }

  /* Container padding: 16px instead of 4px (was too tight, content felt jammed left) */
  .container {
    padding-left: 16px !important;
    padding-right: 16px !important;
  }

  /* Pricing section tier cards: 2x2 grid on mobile */
  .pricing-tier-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 12px !important;
  }

  /* Booking modal tier cards: 2x2 grid on mobile */
  .booking-tier-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
  }

  /* Booking modal frequency cards: stacked vertically on mobile */
  .booking-frequency-grid {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
  }

  /* Nav: hide section links on mobile, only show logo + book now */
  .nav-links {
    display: none !important;
  }
  /* Tighten the whole nav row on mobile — 48px padding was eating
     half the viewport and pushing the right-side CTAs into a wrap. */
  .nav-container {
    padding: 12px 16px !important;
    gap: 8px !important;
  }
  .nav-cta-row {
    gap: 10px !important;
  }
  .nav-login {
    font-size: 13px !important;
  }
  .nav-book-btn {
    padding: 11px 16px !important;
    font-size: 14px !important;
    box-shadow: 3px 3px 0 var(--ink) !important;
  }

  /* Footer: 2 column grid on mobile (company+support left, follow right) */
  .footer-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 32px !important;
  }

  /* Pricing card prices: cap font-size on mobile so $125/$225 fit in card */
  .tier-price {
    font-size: 48px !important;
  }

  /* Booking step 2 form rows: stack vertically on mobile */
  .booking-form-row {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
  }

  /* Footer: single column on mobile (was 2-col, too cramped) */
  .footer-grid {
    grid-template-columns: 1fr !important;
    gap: 32px !important;
  }

  /* Pricing card blurb: smaller font on mobile so descriptions don't wrap 5+ lines */
  .tier-blurb {
    font-size: 13px !important;
    line-height: 1.4 !important;
  }

  /* Footer: tighter on mobile */
  .footer-grid {
    grid-template-columns: 1fr !important;
    gap: 20px !important;
    text-align: center;
  }
  .footer-grid > div {
    text-align: center;
  }

  /* Pricing card headline: cap font sizes on mobile so "bedroom" and "$225" don't overflow card width */
  .tier-name {
    font-size: 22px !important;
    line-height: 1.05 !important;
  }
  .tier-price {
    font-size: 48px !important;
    line-height: 1 !important;
  }
}

.container {
  max-width: 1240px;
  margin: 0 auto;
}

/* Marquee */
.marquee {
  overflow: hidden;
  border-block: 2px solid var(--ink);
  background: var(--gold);
  color: var(--ink);
}
.marquee-track {
  display: flex;
  gap: 48px;
  white-space: nowrap;
  padding: 14px 0;
  animation: marquee 28s linear infinite;
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -0.01em;
}
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* Grain overlay */
.grain::before {
  content: "";
  position: absolute; inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.08 0 0 0 0 0.06 0 0 0 0 0.04 0 0 0 0.18 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  opacity: 0.35;
  pointer-events: none;
  mix-blend-mode: multiply;
}

/* Wiggle */
@keyframes wiggle {
  0%, 100% { transform: rotate(-2deg); }
  50% { transform: rotate(2deg); }
}
.wiggle { animation: wiggle 2.4s ease-in-out infinite; display: inline-block; }

/* Calendar day hover — CSS-only so touch devices don't trap stale gold-bg state.
   Inline styles in CalendarPicker handle selected/today/past; this only fills in pointer hover. */
@media (hover: hover) {
  .cal-day:not(:disabled):hover { background: var(--cream) !important; }
}

/* Form */
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.field label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
  opacity: 0.7;
}
.field input, .field select, .field textarea {
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: 12px;
  padding: 12px 14px;
  font-family: 'Geist', sans-serif;
  /* 16px is the iOS auto-zoom threshold — anything below and Safari
     zooms the viewport when the field gets focus, which jank-scrolls
     the whole booking form. Keep this at 16px. */
  font-size: 16px;
  line-height: 1.4;
  color: var(--ink);
  transition: box-shadow 120ms ease, transform 120ms ease;
}
.field textarea {
  vertical-align: top;
  font-family: 'Geist', sans-serif;
}
.field textarea::placeholder {
  line-height: 1.4;
  font-family: 'Geist', sans-serif;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  box-shadow: 4px 4px 0 var(--gold);
  transform: translate(-2px, -2px);
}

/* Underlines */
.ul-squiggle {
  background-image: linear-gradient(90deg, var(--gold), var(--gold));
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 100% 14%;
  padding-bottom: 2px;
}

/* Star */
.star {
  color: var(--gold);
  font-size: 18px;
  letter-spacing: 1px;
}

/* Scrollable hider */
html { scroll-behavior: smooth; }

/* Select focus ring helper */
.focus-ring:focus-within { box-shadow: 4px 4px 0 var(--gold); }
