/* ==========================================================
   Pizza Palace — styles
   Palette: cream, tomato red, golden crust, dark espresso
   ========================================================== */
:root {
  --cream: #fbf1df;
  --espresso: #2a1a12;
  --cocoa: #4a3326;
  --tomato: #b3261e;
  --tomato-dark: #8f1d17;
  --crust: #e3a446;
  --cheese: #f4cf63;

  --bg: #ffffff;
  --ink: #23170f;
  --muted: #5e4a3d;
  --card: #ffffff;
  --band: #f7efe3;
  --line: #eadfce;

  --font-display: ui-serif, "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --font-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, "SF Mono", "Cascadia Mono", Menlo, Consolas, monospace;

  --radius: 1.4rem;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --header-h: 4rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #17110d;
    --ink: #f6ece0;
    --muted: #cbb9a8;
    --card: #221913;
    --band: #1d1510;
    --line: #3a2c22;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 1rem); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; cursor: pointer; }
h1, h2, h3 { font-family: var(--font-display); margin: 0; letter-spacing: -0.02em; }
p { margin: 0; }
em { font-style: italic; }
.mono { font-family: var(--font-mono); }
.small { font-size: .75rem; letter-spacing: .08em; }
.center { text-align: center; }

.container { width: 100%; max-width: 72rem; margin-inline: auto; padding-inline: 1rem; }
@media (min-width: 640px) { .container { padding-inline: 1.5rem; } }

.section { padding-block: 5rem; }
@media (min-width: 768px) { .section { padding-block: 7rem; } }
.section-anchor { outline: none; scroll-margin-top: calc(var(--header-h) + 3rem); }
@media (min-width: 768px) { .section-anchor { scroll-margin-top: var(--header-h); } }

:focus-visible { outline: 2px solid var(--tomato); outline-offset: 3px; border-radius: 6px; }

.skip-link {
  position: absolute; left: -999px; top: .75rem; z-index: 100;
  background: var(--cream); color: var(--espresso); padding: .5rem 1rem; border-radius: .5rem;
}
.skip-link:focus { left: .75rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  border-radius: 999px; border: 1px solid transparent;
  font-weight: 600; text-decoration: none; white-space: nowrap;
  transition: background-color .2s, transform .2s var(--ease), box-shadow .2s;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(1px); }
.btn-sm { height: 2.4rem; padding-inline: 1.25rem; font-size: .9rem; }
.btn-lg { height: 3rem; padding-inline: 1.75rem; font-size: 1rem; }
.btn-red { background: var(--tomato); color: #fff; box-shadow: 0 10px 24px -12px var(--tomato); }
.btn-red:hover { background: var(--tomato-dark); }
.btn-ghost { background: transparent; color: var(--espresso); border-color: rgba(42, 26, 18, .25); }
.btn-ghost:hover { background: rgba(42, 26, 18, .06); }
.btn-cream { background: var(--cream); color: var(--espresso); }
.btn-cream:hover { background: #fff; }
.btn-outline-cream { background: transparent; color: var(--cream); border-color: rgba(251, 241, 223, .5); }
.btn-outline-cream:hover { background: rgba(255, 255, 255, .1); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--cream); color: var(--espresso);
  border-bottom: 1px solid transparent;
  transition: background-color .3s, box-shadow .3s, border-color .3s;
}
.site-header.scrolled {
  background: rgba(251, 241, 223, .9);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom-color: rgba(42, 26, 18, .1);
  box-shadow: 0 6px 24px -18px rgba(42, 26, 18, .6);
}
.header-row { display: flex; align-items: center; gap: 1rem; height: var(--header-h); }
.brand { display: flex; align-items: center; gap: .5rem; text-decoration: none; }
.logo-mark { width: 2.25rem; height: 2.25rem; transition: transform .5s var(--ease); }
.logo-mark.sm { width: 1.5rem; height: 1.5rem; }
.brand:hover .logo-mark { transform: rotate(30deg); }
.brand-name { font-family: var(--font-display); font-size: 1.25rem; font-weight: 700; letter-spacing: -0.02em; }
.brand-name em { color: var(--tomato); }

.nav-desktop { display: none; margin-left: auto; }
.nav-desktop ul, .nav-mobile ul { list-style: none; margin: 0; padding: 0; display: flex; gap: .25rem; }
.nav-desktop a {
  position: relative; display: block; padding: .5rem .75rem; border-radius: 999px;
  font-size: .9rem; font-weight: 500; color: var(--cocoa); text-decoration: none;
}
.nav-desktop a::after {
  content: ""; position: absolute; left: .75rem; right: .75rem; bottom: -2px; height: 2px;
  border-radius: 2px; background: var(--tomato);
  transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease);
}
.nav-desktop a:hover, .nav-desktop a[aria-current] { color: var(--espresso); }
.nav-desktop a[aria-current]::after { transform: scaleX(1); }
.header-cta { margin-left: auto; }
@media (min-width: 768px) {
  .nav-desktop { display: block; }
  .header-cta { margin-left: .5rem; }
  .nav-mobile { display: none; }
}
.nav-mobile { border-top: 1px solid rgba(42, 26, 18, .1); overflow-x: auto; scrollbar-width: none; }
.nav-mobile::-webkit-scrollbar { display: none; }
.nav-mobile ul { padding: .375rem .75rem; }
.nav-mobile a { display: block; white-space: nowrap; padding: .25rem .75rem; border-radius: 999px; font-size: .9rem; color: var(--cocoa); text-decoration: none; }
.nav-mobile a[aria-current] { background: var(--espresso); color: var(--cream); }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background-color: var(--cream); color: var(--espresso);
  background-image:
    radial-gradient(circle at 6px 8px, rgba(217, 195, 160, .45) 1.2px, transparent 1.6px),
    radial-gradient(circle at 30px 26px, rgba(217, 195, 160, .45) 1px, transparent 1.4px);
  background-size: 44px 44px;
}
.hero-grid { display: grid; gap: 2.5rem; align-items: center; padding-block: 2.5rem 4rem; }
@media (min-width: 768px) { .hero-grid { grid-template-columns: 1.05fr 1fr; padding-block: 4rem 6rem; } }

.eyebrow-pill {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .25rem .75rem; border-radius: 999px;
  border: 1px solid rgba(42, 26, 18, .15); background: rgba(255, 255, 255, .6);
  font-family: var(--font-mono); font-size: .72rem; letter-spacing: .18em; text-transform: uppercase; color: #5c4434;
}
.dot-live { width: .5rem; height: .5rem; border-radius: 50%; background: #2f7a3a; box-shadow: 0 0 0 0 rgba(47, 122, 58, .5); animation: pulse 2.4s infinite; }

.hero-title {
  margin-top: 1.5rem;
  font-size: clamp(2.9rem, 7.4vw, 5.6rem); line-height: .92; font-weight: 700; letter-spacing: -0.03em;
}
.br-sm { display: none; }
@media (min-width: 640px) { .br-sm { display: inline; } }
.accent-word { position: relative; display: inline-block; font-style: italic; color: var(--tomato); }
.underline { position: absolute; left: 0; bottom: -.5rem; width: 100%; height: .75rem; overflow: visible; }
.underline path {
  fill: none; stroke: var(--crust); stroke-width: 6; stroke-linecap: round;
  stroke-dasharray: 220; stroke-dashoffset: 220; animation: draw .9s .6s var(--ease) forwards;
}
.hero-lead { margin-top: 1.75rem; max-width: 28rem; font-size: 1.125rem; line-height: 1.65; color: var(--cocoa); }
.hero-actions { margin-top: 2rem; display: flex; flex-wrap: wrap; gap: .75rem; }

.intro { opacity: 0; transform: translateY(14px); animation: rise .7s var(--ease) forwards; }
.intro-2 { animation-delay: .08s; }
.intro-3 { animation-delay: .18s; }
.intro-4 { animation-delay: .28s; }

.hero-visual { position: relative; width: 100%; max-width: 460px; margin-inline: auto; }
.steam-wrap { position: absolute; top: -1.5rem; left: 50%; width: 7rem; transform: translateX(-50%); overflow: visible; }
.steam { fill: none; stroke: #c9b08c; stroke-width: 3; stroke-linecap: round; opacity: 0; animation: steam 3.2s ease-in-out infinite; }
.clock-wrap { opacity: 0; animation: spin-in .9s var(--ease) forwards; }
#pizza-clock { width: 100%; height: auto; overflow: visible; filter: drop-shadow(0 30px 40px rgba(90, 40, 20, .25)); }

/* slices + hands */
.slice { transition: transform .7s cubic-bezier(.34, 1.56, .64, 1); }
.minute-hand { transform-box: view-box; transform-origin: 200px 200px; animation: sweep 40s linear infinite; }
.hour-hand { transform-box: view-box; transform-origin: 200px 200px; transition: transform 1s cubic-bezier(.34, 1.4, .64, 1); }
.dial-label { font-family: var(--font-mono); font-size: 12px; letter-spacing: 2px; fill: #5c4434; font-weight: 500; transition: fill .3s; }
.dial-label.on { fill: var(--tomato); font-weight: 700; }

.meal-switch {
  margin-top: 1rem; display: grid; grid-template-columns: repeat(4, 1fr); gap: .375rem;
  padding: .375rem; border-radius: 999px; border: 1px solid rgba(42, 26, 18, .1);
  background: rgba(255, 255, 255, .7); backdrop-filter: blur(6px);
}
.meal-chip {
  border: 0; background: transparent; color: var(--cocoa);
  border-radius: 999px; padding: .5rem .25rem; font-size: .8rem; font-weight: 600;
  transition: background-color .3s, color .3s, box-shadow .3s;
}
@media (min-width: 640px) { .meal-chip { font-size: .9rem; } }
.meal-chip:hover { background: rgba(42, 26, 18, .06); }
.meal-chip[aria-pressed="true"] { background: var(--espresso); color: var(--cream); box-shadow: 0 2px 8px rgba(0, 0, 0, .2); }
.meal-caption { margin-top: .75rem; text-align: center; font-size: .9rem; color: var(--cocoa); }
.text-link { font-weight: 600; color: var(--tomato); text-decoration: none; }
.text-link:hover { text-decoration: underline; text-underline-offset: 4px; }

/* marquee */
.marquee { position: relative; overflow: hidden; background: var(--espresso); color: var(--cream); padding-block: .75rem; }
.marquee-track { display: flex; width: max-content; gap: 2.5rem; white-space: nowrap; font-family: var(--font-display); font-style: italic; font-size: 1.25rem; animation: marquee 38s linear infinite; }
.marquee-track span { display: flex; align-items: center; gap: 2.5rem; }
.marquee-track b { font-style: normal; font-weight: 400; color: var(--crust); }

/* ---------- Shared section heads ---------- */
.eyebrow { font-family: var(--font-mono); font-size: .75rem; letter-spacing: .2em; text-transform: uppercase; color: var(--tomato); }
@media (prefers-color-scheme: dark) { .eyebrow, .section-title .accent { color: #f08a7e; } }
.section-title { margin-top: .75rem; font-size: clamp(2.25rem, 4.5vw, 3rem); font-weight: 700; line-height: 1.08; }
.section-title.narrow { max-width: 40rem; }
.section-title.center { margin-inline: auto; max-width: 36rem; }
.section-title .accent { color: var(--tomato); }

.band { background: var(--band); border-block: 1px solid var(--line); }

/* ---------- Menu ---------- */
.menu-head { display: flex; flex-direction: column; gap: 1.5rem; }
@media (min-width: 768px) { .menu-head { flex-direction: row; align-items: flex-end; justify-content: space-between; } }
.menu-tabs { display: flex; flex-wrap: wrap; gap: .5rem; }
.tab-chip {
  display: inline-flex; align-items: center; gap: .5rem;
  height: 2.4rem; padding-inline: 1rem; border-radius: 999px;
  border: 1px solid var(--line); background: var(--card); color: var(--ink);
  font-size: .9rem; font-weight: 600; transition: background-color .25s, color .25s, border-color .25s;
}
.tab-chip .mono { font-size: .7rem; color: var(--muted); font-weight: 400; }
.tab-chip:hover { border-color: var(--tomato); }
.tab-chip[aria-pressed="true"] { background: var(--tomato); border-color: var(--tomato); color: #fff; }
.tab-chip[aria-pressed="true"] .mono { color: rgba(255, 255, 255, .9); }

.pie-grid { list-style: none; margin: 2.5rem 0 0; padding: 0; display: grid; gap: 1.25rem; }
@media (min-width: 768px) { .pie-grid { grid-template-columns: repeat(3, 1fr); } }
.pie-card {
  display: flex; flex-direction: column; padding: 1.5rem;
  border-radius: var(--radius); border: 1px solid var(--line); background: var(--card);
  opacity: 0; transform: translateY(16px); animation: rise .45s var(--ease) forwards;
  transition: box-shadow .3s;
}
.pie-card:hover { box-shadow: 0 20px 40px -24px rgba(90, 40, 20, .45); }
.pie-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; }
.mini-pie { width: 5rem; height: 5rem; flex-shrink: 0; transition: transform .5s var(--ease); }
.pie-card:hover .mini-pie { transform: rotate(24deg); }
.price { font-family: var(--font-mono); font-size: 1.125rem; font-weight: 600; }
.pie-card h3 { margin-top: 1.25rem; font-size: 1.5rem; font-weight: 700; }
.pie-card p { margin-top: .5rem; flex: 1; color: var(--muted); line-height: 1.6; }
.tag { margin-top: 1rem; display: inline-flex; align-items: center; gap: .375rem; width: fit-content; padding: .125rem .625rem; border-radius: 999px; border: 1px solid var(--line); font-size: .75rem; font-weight: 500; }
.tag i { width: .375rem; height: .375rem; border-radius: 50%; background: #15803d; }
.tag.spicy i { background: #b91c1c; }

/* ---------- Benefits ---------- */
.benefits { margin-top: 3.5rem; display: grid; gap: 2.5rem; }
@media (min-width: 768px) { .benefits { grid-template-columns: repeat(3, 1fr); gap: 2rem; } }
.benefit { position: relative; padding-top: 1.5rem; border-top: 2px solid var(--ink); }
.benefit-num { position: absolute; top: -.85rem; right: 0; padding-inline: .5rem; background: var(--band); font-family: var(--font-mono); font-size: .85rem; color: var(--muted); }
.benefit-icon { display: flex; align-items: center; justify-content: center; width: 3rem; height: 3rem; border-radius: 1rem; background: var(--tomato); }
.benefit-icon svg { width: 1.5rem; height: 1.5rem; fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.benefit h3 { margin-top: 1.25rem; font-size: 1.5rem; font-weight: 700; }
.benefit p { margin-top: .75rem; color: var(--muted); }

/* ---------- How it works ---------- */
.steps { position: relative; list-style: none; margin: 4rem 0 3.5rem; padding: 0; display: grid; gap: 2.5rem; }
@media (min-width: 768px) {
  .steps { grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
  .steps::before, .steps::after {
    content: ""; position: absolute; top: 2rem; left: 12.5%; width: 75%; height: 0;
  }
  .steps::before { border-top: 2px dashed var(--line); }
  .steps::after { border-top: 3px solid var(--crust); transform: scaleX(0); transform-origin: left; transition: transform 1.6s ease-in-out; top: calc(2rem - .5px); }
  .steps.in::after { transform: scaleX(1); }
}
.step { position: relative; z-index: 1; text-align: center; }
.step-dial {
  position: relative; margin-inline: auto; width: 4rem; height: 4rem; border-radius: 50%;
  border: 2px solid var(--ink);
  background: conic-gradient(rgba(227, 164, 70, .4) 0 var(--fill), var(--bg) var(--fill) 100%);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono); font-size: 1.1rem; font-weight: 700;
}
.step h3 { margin-top: 1.25rem; font-size: 1.25rem; font-weight: 700; }
.step p { margin: .5rem auto 0; max-width: 16rem; color: var(--muted); }

/* ---------- FAQ ---------- */
.faq-grid { display: grid; gap: 2.5rem; }
@media (min-width: 768px) { .faq-grid { grid-template-columns: 1fr 1.6fr; } }
.float-slice { display: none; width: 10rem; margin-top: 2.5rem; animation: float 7s ease-in-out infinite; }
@media (min-width: 768px) { .float-slice { display: block; } }
.faq-list { border-radius: var(--radius); border: 1px solid var(--line); background: var(--card); padding-inline: 1.25rem; }
@media (min-width: 640px) { .faq-list { padding-inline: 1.75rem; } }
.faq-item + .faq-item { border-top: 1px solid var(--line); }
.faq-q { margin: 0; font-size: inherit; }
.faq-btn {
  width: 100%; display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem;
  padding: 1.25rem 0; border: 0; background: none; color: var(--ink); text-align: left;
  font-family: var(--font-display); font-size: 1.125rem; font-weight: 600; letter-spacing: -0.01em;
}
.faq-btn[aria-expanded="true"] { color: var(--tomato); }
@media (prefers-color-scheme: dark) { .faq-btn[aria-expanded="true"] { color: #f08a7e; } }
.faq-icon { position: relative; flex-shrink: 0; width: 1.25rem; height: 1.25rem; margin-top: .2rem; }
.faq-icon::before, .faq-icon::after {
  content: ""; position: absolute; left: 50%; top: 50%; width: .875rem; height: 2px; border-radius: 2px;
  background: currentColor; transform: translate(-50%, -50%); transition: transform .3s var(--ease);
}
.faq-icon::after { transform: translate(-50%, -50%) rotate(90deg); }
.faq-btn[aria-expanded="true"] .faq-icon::after { transform: translate(-50%, -50%) rotate(0deg); }
.faq-panel { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .35s var(--ease); }
.faq-panel.open { grid-template-rows: 1fr; }
.faq-panel > div { overflow: hidden; }
.faq-panel p { padding: 0 2rem 1.25rem 0; color: var(--muted); line-height: 1.7; }

/* ---------- CTA + footer ---------- */
.cta { position: relative; overflow: hidden; background: var(--tomato-dark); color: var(--cream); }
.cta-dial { position: absolute; right: -6rem; bottom: -8rem; width: 26rem; opacity: .15; pointer-events: none; animation: sweep 120s linear infinite; }
.cta-row { position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 2rem; padding-block: 5rem; }
@media (min-width: 768px) { .cta-row { flex-direction: row; align-items: center; justify-content: space-between; } }
.cta h2 { max-width: 36rem; font-size: clamp(2.25rem, 4.5vw, 3rem); font-weight: 700; line-height: 1.12; }
.cta h2 em { color: var(--cheese); }
.cta-actions { display: flex; flex-wrap: wrap; gap: .75rem; }
.site-footer { background: var(--espresso); color: #e9dccb; }
.footer-row { display: flex; flex-direction: column; align-items: center; justify-content: space-between; gap: .75rem; padding-block: 1.5rem; font-size: .9rem; }
@media (min-width: 640px) { .footer-row { flex-direction: row; } }
.footer-brand { display: flex; align-items: center; gap: .5rem; font-family: var(--font-display); font-weight: 700; }

/* ---------- Scroll reveal ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s var(--ease) var(--d, 0s), transform .6s var(--ease) var(--d, 0s); }
.reveal.in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

/* ---------- Keyframes ---------- */
@keyframes rise { to { opacity: 1; transform: none; } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes spin-in { from { opacity: 0; transform: scale(.9) rotate(-20deg); } to { opacity: 1; transform: none; } }
@keyframes steam { 0% { transform: translateY(8px); opacity: 0; } 30% { opacity: .7; } 100% { transform: translateY(-26px); opacity: 0; } }
@keyframes sweep { to { transform: rotate(360deg); } }
@keyframes float { 0%, 100% { transform: translateY(0) rotate(-2deg); } 50% { transform: translateY(-8px) rotate(2deg); } }
@keyframes marquee { to { transform: translateX(-50%); } }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(47, 122, 58, .5); } 70% { box-shadow: 0 0 0 8px rgba(47, 122, 58, 0); } 100% { box-shadow: 0 0 0 0 rgba(47, 122, 58, 0); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .marquee-track, .minute-hand, .cta-dial, .float-slice, .steam { animation: none !important; }
  .intro, .clock-wrap, .pie-card { opacity: 1; transform: none; }
  .underline path { stroke-dashoffset: 0; }
}
@media (forced-colors: active) {
  .meal-chip[aria-pressed="true"], .tab-chip[aria-pressed="true"] { outline: 2px solid Highlight; }
}
