/* Pizzeria Lupetta – concept site
   Warm, familiar, a little retro: tomato red, bottle green, cream paper, a checked tablecloth,
   a fat old-style serif and handwritten notes.
   Motion style: slow and warm (data-motion="warm"). A pizza turns as the page scrolls. */

@font-face {
  font-family: "Gloock";
  src: url("../fonts/gloock-latin-400-normal.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Caveat";
  src: url("../fonts/caveat-latin-wght-normal.woff2") format("woff2");
  font-weight: 400 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Figtree";
  src: url("../fonts/figtree-latin-wght-normal.woff2") format("woff2");
  font-weight: 300 900; font-style: normal; font-display: swap;
}

:root {
  --tomato: #B8291C;
  --tomato-dark: #8F1E14;
  --green: #24523A;
  --cream: #F6EBD7;
  --paper: #FBF5E8;
  --espresso: #2A1D17;
  --muted: #6B5548;
  --line: #DCCDB2;
  --display: "Gloock", Georgia, "Times New Roman", serif;
  --hand: "Caveat", "Segoe Script", cursive;
  --text: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --pad: 1.25rem;
  --max: 76rem;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--cream); color: var(--espresso);
  font-family: var(--text); font-size: 1.0625rem; line-height: 1.65;
}
img, video { display: block; max-width: 100%; height: auto; }
h1, h2, h3, p, ul, figure, table, address { margin: 0; padding: 0; }
ul { list-style: none; }
address { font-style: normal; }
a { color: inherit; }
main { overflow-x: clip; }
:focus-visible { outline: 3px solid var(--green); outline-offset: 3px; border-radius: 2px; }

.skip { position: absolute; left: -999px; }
.skip:focus { left: 1rem; top: 3rem; background: #fff; padding: .5rem 1rem; z-index: 40; }

.concept-bar {
  background: var(--espresso); color: #fff;
  font-size: .8125rem; line-height: 1.4; text-align: center; padding: .5rem 1rem;
}

/* Top: sits on the hero video */
.stage { position: relative; }
.top {
  position: absolute; left: 0; right: 0; top: 0; z-index: 5; color: #fff;
  display: flex; align-items: center; justify-content: space-between; gap: 1.5rem;
  max-width: var(--max); margin: 0 auto; padding: 1rem var(--pad);
}
.wordmark { font-family: var(--display); font-size: 1.875rem; line-height: 1; text-decoration: none; }
.wordmark small { display: block; font-family: var(--hand); font-size: 1.0625rem; font-weight: 500; margin-top: .125rem; color: #F3D9A8; }
.top-nav { display: none; gap: 2rem; margin-left: auto; }
.top-nav a { text-decoration: none; }
.top-nav a:hover { text-decoration: underline; text-underline-offset: .35em; }
.top :focus-visible, .hero :focus-visible, .pickup :focus-visible, .foot :focus-visible { outline-color: #fff; }

.btn {
  display: inline-block; text-decoration: none; text-align: center;
  background: var(--tomato); color: #fff; font-weight: 700; font-size: 1.0625rem; line-height: 1.2;
  padding: 1rem 1.75rem; border-radius: 999px; border: 2px solid var(--tomato);
  transition: background-color .2s ease, border-color .2s ease, color .2s ease;
}
.btn:hover { background: var(--tomato-dark); border-color: var(--tomato-dark); }
.btn-small { font-size: .9375rem; padding: .75rem 1.25rem; }
.btn-line { background: transparent; border-color: #fff; }
.btn-line:hover { background: #fff; border-color: #fff; color: var(--espresso); }
.btn-cream { background: var(--cream); border-color: var(--cream); color: var(--green); }
.btn-cream:hover { background: #fff; border-color: #fff; }
.link { color: var(--tomato); font-weight: 600; text-underline-offset: .35em; }
.link:hover { color: var(--tomato-dark); }

/* Hero */
.hero {
  position: relative; isolation: isolate; overflow: clip; color: #fff; background: var(--espresso);
  min-height: calc(100vh - 2.875rem); min-height: calc(100svh - 2.875rem); display: grid; align-items: end;
}
.hero-media { position: absolute; inset: 0; z-index: -2; }
.hero-media img, .hero-media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-shade {
  position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(0deg, rgba(34, 20, 14, .95) 0%, rgba(34, 20, 14, .8) 42%, rgba(34, 20, 14, .2) 74%, rgba(34, 20, 14, .6) 100%);
}
.hero-text { width: 100%; max-width: var(--max); margin: 0 auto; padding: 7rem var(--pad) 4.75rem; }
.note { font-family: var(--hand); font-size: 1.75rem; line-height: 1; color: #F3D9A8; transform: rotate(-3deg); transform-origin: left bottom; margin-bottom: .75rem; }
h1 {
  font-family: var(--display); font-weight: 400;
  font-size: clamp(2.625rem, 11vw, 4.5rem); line-height: 1.02; letter-spacing: -.01em; max-width: 11em; text-wrap: balance;
}
.lede { font-size: 1.1875rem; line-height: 1.5; max-width: 30rem; margin-top: 1.25rem; }
.status { margin-top: 1rem; min-height: 1.65em; color: #F3D9A8; }
.status::before { content: ""; display: inline-block; width: .625rem; height: .625rem; border-radius: 50%; margin-right: .5rem; background: currentColor; }
.status.is-open::before { background: #6FCF7F; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1rem; margin-top: 1.5rem; }
.hero-toggle {
  position: absolute; right: var(--pad); bottom: 1.25rem;
  font: inherit; font-size: .8125rem; line-height: 1.3; color: rgba(255, 255, 255, .85); background: none; cursor: pointer;
  border: 1px solid rgba(255, 255, 255, .5); border-radius: 999px; padding: .5rem .875rem; min-height: 2.25rem;
}
.hero-toggle:hover { color: #fff; border-color: #fff; }

/* The tablecloth */
.gingham {
  height: 2.5rem; background-color: #fff;
  background-image:
    linear-gradient(90deg, rgba(184, 41, 28, .55) 50%, transparent 50%),
    linear-gradient(rgba(184, 41, 28, .55) 50%, transparent 50%);
  background-size: 1.25rem 1.25rem;
}

/* Family */
.family { max-width: var(--max); margin: 0 auto; padding: 4.5rem var(--pad); display: grid; gap: 3rem; }
h2 {
  font-family: var(--display); font-weight: 400; color: var(--green);
  font-size: clamp(2.25rem, 8vw, 3.75rem); line-height: 1.04; margin-bottom: 1.25rem; text-wrap: balance;
}
.family-text p { font-size: 1.125rem; max-width: 32rem; }
.family-text p + p { margin-top: 1rem; }
.sign { margin-top: 1.5rem !important; }
.sign span { display: block; font-family: var(--hand); font-size: 2rem; line-height: 1; color: var(--tomato); transform: rotate(-2deg); transform-origin: left; }
.sign svg { display: block; width: 13.75rem; height: .875rem; margin-top: .25rem; fill: none; stroke: var(--tomato); stroke-width: 2.5; stroke-linecap: round; }
/* the underline is drawn when it scrolls into view */
.motion .sign svg path { stroke-dasharray: 230; stroke-dashoffset: 230; transition: stroke-dashoffset 1.2s ease .3s; }
.motion .sign svg.is-in path { stroke-dashoffset: 0; }

.family-photos { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; padding-bottom: 4rem; }
.photo { overflow: hidden; border-radius: .5rem; }
.photo img { width: 100%; height: 100%; object-fit: cover; }
.photo-a { aspect-ratio: 3 / 4; }
.photo-b { aspect-ratio: 3 / 4; margin-top: 3rem; }
.spin {
  position: absolute; left: 50%; bottom: 0; width: 9rem; height: 9rem; margin-left: -4.5rem;
  border-radius: 50%; object-fit: cover; border: .375rem solid var(--cream); box-shadow: 0 12px 30px -12px rgba(42, 29, 23, .6);
}

/* Menu */
.menu { background: var(--paper); padding: 4.5rem var(--pad); border-block: 1px solid var(--line); }
.menu-head, .tabs, .panel { max-width: 46rem; margin-left: auto; margin-right: auto; }
.menu-head { text-align: center; }
.menu-head p { color: var(--muted); max-width: 30rem; margin: 0 auto; }
.tabs { display: flex; gap: .5rem; overflow-x: auto; padding: 1.75rem 0 .5rem; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs [role="tab"] {
  flex: none; font: inherit; font-weight: 600; color: var(--green); background: none; cursor: pointer;
  border: 2px solid var(--green); border-radius: 999px; padding: .625rem 1.125rem; min-height: 2.75rem;
  transition: background-color .2s ease, color .2s ease;
}
.tabs [role="tab"][aria-selected="true"] { background: var(--green); color: #fff; }
.panel-note { font-family: var(--hand); font-size: 1.5rem; color: var(--tomato); margin: 1rem 0 .25rem; transform: rotate(-1.5deg); transform-origin: left; }
.dishes li {
  display: flex; justify-content: space-between; align-items: baseline; gap: 1.5rem;
  padding: 1rem 0; border-bottom: 1px dashed #C9B894;
}
.dishes h3 { font-family: var(--display); font-weight: 400; font-size: 1.375rem; line-height: 1.2; }
.dishes p { color: var(--muted); font-size: 1rem; line-height: 1.5; }
.price { font-weight: 700; color: var(--tomato); white-space: nowrap; font-variant-numeric: tabular-nums; }
.dish-float { border: .5rem solid #fff; border-radius: .25rem; }

/* Pickup */
.pickup { background: var(--green); color: #fff; padding: 4.5rem var(--pad); display: grid; gap: 2.5rem; }
.pickup h2 { color: var(--cream); }
.pickup-text p { max-width: 32rem; }
.phone { font-weight: 700; font-size: 1.25rem; font-variant-numeric: tabular-nums; text-decoration: none; padding: .5rem 0; }
.phone:hover { text-decoration: underline; text-underline-offset: .3em; }
.apps-label { margin-top: 2rem; font-family: var(--hand); font-size: 1.5rem; color: #F3D9A8; }
.apps { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .5rem; }
.apps a {
  display: inline-block; text-decoration: none; font-weight: 600;
  border: 1.5px solid rgba(255, 255, 255, .7); border-radius: 999px; padding: .625rem 1.125rem;
  transition: background-color .2s ease, color .2s ease;
}
.apps a:hover { background: #fff; color: var(--green); }
.pickup-photo { aspect-ratio: 4 / 3; }

/* Visit */
.visit { max-width: var(--max); margin: 0 auto; padding: 4.5rem var(--pad); display: grid; gap: 3rem; }
.visit h2 { font-size: 2.25rem; margin-bottom: 1rem; }
.visit p + p { margin-top: .75rem; }
.visit address { margin-bottom: .75rem; }
.status-inline { margin: 0 0 1rem; color: var(--tomato); }
.status-inline.is-open { color: var(--green); }
.status-inline.is-open::before { background: var(--green); }
.hours { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.hours th, .hours td { text-align: left; font-weight: 400; padding: .5rem 0; border-bottom: 1px dashed #C9B894; vertical-align: top; }
.hours td { text-align: right; }
.hours .is-today th, .hours .is-today td { font-weight: 700; color: var(--tomato); }
.small { font-size: .9375rem; color: var(--muted); margin-top: 1rem; }

/* Footer */
.foot { background: var(--espresso); color: #E8D9C2; text-align: center; padding: 2.5rem var(--pad) 3rem; }
.foot-name { font-family: var(--display); font-size: 2.75rem; line-height: 1; color: #fff; margin-bottom: .5rem; }
.foot a { color: #fff; }

@media (min-width: 720px) {
  .hero-shade {
    background:
      linear-gradient(90deg, rgba(34, 20, 14, .93) 0%, rgba(34, 20, 14, .74) 36%, rgba(34, 20, 14, 0) 72%),
      linear-gradient(0deg, rgba(34, 20, 14, .8) 0%, rgba(34, 20, 14, 0) 38%),
      linear-gradient(180deg, rgba(34, 20, 14, .7) 0%, rgba(34, 20, 14, 0) 22%);
  }
  .tabs { justify-content: center; }
}

@media (min-width: 960px) {
  :root { --pad: 3rem; }
  .top { padding-top: 1.5rem; }
  .wordmark { font-size: 2.25rem; }
  .top-nav { display: flex; }
  .hero-text { padding-top: 9rem; padding-bottom: 5.5rem; }
  h1 { font-size: clamp(3.5rem, 5.6vw, 5.75rem); }
  .note { font-size: 2.25rem; }
  .lede { font-size: 1.3125rem; }
  .hero-toggle { bottom: 2rem; }
  .gingham { height: 3.5rem; background-size: 1.75rem 1.75rem; }
  .family { grid-template-columns: 5fr 6fr; gap: 5rem; align-items: center; padding-top: 7.5rem; padding-bottom: 7.5rem; }
  .family-photos { gap: 1.5rem; padding-bottom: 0; }
  .spin { width: 13rem; height: 13rem; margin-left: -6.5rem; bottom: -3rem; }
  .menu { padding-top: 6.5rem; padding-bottom: 7rem; }
  .dishes li { cursor: default; }
  .pickup { grid-template-columns: 1fr 1fr; gap: 5rem; align-items: center; padding-top: 6.5rem; padding-bottom: 6.5rem; }
  .pickup > * { max-width: 36rem; }
  .pickup-text { justify-self: end; }
  .visit { grid-template-columns: 1.15fr 1fr 1fr; gap: 4rem; padding-top: 6.5rem; padding-bottom: 6.5rem; }
}

/* Concept bar with the button back to Webcrops. Stays at the top of the screen while scrolling. */
html { scroll-padding-top: 3.5rem; }
.concept-bar {
  --bar-bg: var(--espresso); --bar-fg: #fff;
  position: sticky; top: 0; z-index: 50; margin: 0;
  display: flex; align-items: center; justify-content: center; gap: .375rem 1rem;
  background: var(--bar-bg); color: var(--bar-fg); text-align: left; padding: .4375rem 1rem;
}
.concept-bar a { color: inherit; }
.concept-back {
  flex: none; display: inline-flex; align-items: center; gap: .375rem;
  font-weight: 700; font-size: .8125rem; line-height: 1; text-decoration: none; white-space: nowrap;
  border: 1.5px solid var(--bar-fg); border-radius: 999px; padding: .5rem .875rem; min-height: 2rem;
  transition: background-color .15s ease, color .15s ease;
}
.concept-back:hover { background: var(--bar-fg); color: var(--bar-bg) !important; }
.concept-bar :focus-visible { outline: 2px solid var(--bar-fg); outline-offset: 2px; }
@media (max-width: 479px) {
  .concept-bar { justify-content: flex-start; font-size: .75rem; }
}

/* Smart sticky header (assets/js/nav.js): slides away on the way down, comes back on the way up.
   It sits just under the concept bar, and gets a background while it is stuck. */
.top[data-smart-nav] {
   z-index: 45; max-width: none; margin: 0; padding-inline: max(var(--pad), calc((100% - var(--max)) / 2 + var(--pad)));
  transition: transform .28s ease, background-color .28s ease, box-shadow .28s ease;
}
.top.nav-ready { position: fixed; top: var(--bar-h, 0px); }
.top.is-hidden { transform: translateY(-101%); }
.top.is-stuck { background: rgba(42, 29, 23, .9); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);  }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
