/* Menu de Natal 2026 · Jardim Gourmet */

@font-face {
  font-family: "Nyght Serif";
  src: url("assets/fonts/NyghtSerif-RegularItalic.woff2") format("woff2");
  font-style: italic; font-weight: 400; font-display: swap;
}
@font-face {
  font-family: "Nyght Serif";
  src: url("assets/fonts/NyghtSerif-Regular.woff2") format("woff2");
  font-style: normal; font-weight: 400; font-display: swap;
}
/* A fonte Santa Natale aparece só em imagens (título da capa e "Feliz Natal"),
   para não baixar 195 KB de fonte no celular. */

:root {
  --bg: #f1f0ec;
  --paper: #f8f7f3;
  --red: #c82624;
  --red-dark: #a51d1b;
  --ink: #1d1b1a;
  --muted: #5d5753;
  --line: #e2ddd6;
  --wa: #1f8f4e;
  --green: #173a29;
  --green-dark: #0f2a1d;
  --radius: 14px;
  --serif: "EB Garamond", Garamond, "Times New Roman", serif;
  --display: "Nyght Serif", "EB Garamond", serif;
  --red-soft: rgba(200, 38, 36, .1);
  --red-ring: rgba(200, 38, 36, .12);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; overflow-x: clip; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.125rem;
  line-height: 1.45;
}
body.has-cart { padding-bottom: 96px; }
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3 { margin: 0; font-weight: 400; }
p { margin: 0; }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--red); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 99; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }

/* ---------- botões ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 26px; border-radius: 999px; border: 0;
  font: 500 1.15rem/1 var(--serif); text-decoration: none; cursor: pointer;
  transition: transform .15s ease, background-color .15s ease;
}
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--red); color: #fff; }
.btn-primary:hover { background: var(--red-dark); }
.btn-ghost { background: transparent; color: var(--red); border: 1.5px solid var(--red); }
.btn-ghost:hover { background: var(--red); color: #fff; }
.btn-wa { width: 100%; background: var(--wa); color: #fff; }
.btn-wa:hover { background: #18773f; }
.btn:disabled { opacity: .45; cursor: not-allowed; }

/* ---------- capa ---------- */
.hero {
  position: relative;
  max-width: 760px; margin: 0 auto;
  padding: 20px 16px 36px;
  text-align: center;
}
.hero-title { margin: 0 auto; width: min(560px, 92%); }
.hero-title img { width: 100%; }
.hero-scene { width: 84%; max-width: 640px; margin: 8px auto 0; }

.spark { position: absolute; pointer-events: none; animation: twinkle 3.6s ease-in-out infinite; }
.s1 { top: 14px; right: 5%; width: 40px; }
.s2 { top: 44px; left: 6%; width: 26px; animation-delay: .8s; }
.s3 { top: 210px; left: 3%; width: 34px; animation-delay: 1.6s; }
.s4 { top: 236px; right: 5%; width: 24px; animation-delay: 2.2s; }
@keyframes twinkle { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .55; transform: scale(.88) rotate(8deg); } }
@media (prefers-reduced-motion: reduce) { .spark { animation: none; } }

.deadline { margin-top: 10px; color: var(--red); }
.deadline-main { font: italic 400 clamp(2rem, 8vw, 2.8rem)/1.1 var(--display); }
.deadline-main strong { font-weight: 400; }
.deadline-count {
  display: inline-block; margin-top: 10px; padding: 6px 14px; border-radius: 999px;
  background: var(--red); color: #fff; font-size: 1rem; letter-spacing: .02em;
}
.deadline-count:empty { display: none; }
.hero-cta {
  margin-top: 16px; background: var(--green);
  text-transform: uppercase; letter-spacing: .06em; font-size: 1.02rem;
}
.hero-cta:hover { background: var(--green-dark); }

.facts {
  list-style: none; margin: 32px auto 0; padding: 0;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px;
}
.facts li {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 14px 10px; display: flex; flex-direction: column; gap: 4px;
}
.fact-k { font: italic 400 1.2rem/1 var(--display); color: var(--red); text-transform: uppercase; }
.fact-v { font-size: 1rem; line-height: 1.25; color: var(--muted); }

/* ---------- títulos de seção ---------- */
.section-title {
  font: italic 400 clamp(1.7rem, 8.2vw, 3.6rem)/1 var(--display);
  color: var(--red); text-align: center; text-transform: uppercase; letter-spacing: -.01em;
  overflow-wrap: anywhere;
}
.divider { width: min(560px, 88%); margin: 0 auto 44px; }

/* ---------- como funciona ---------- */
.how { max-width: 760px; margin: 0 auto; padding: 24px 16px 40px; }
.steps { list-style: none; padding: 0; margin: 26px 0 0; display: grid; gap: 12px; }
.steps li { display: flex; gap: 14px; align-items: flex-start; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.step-n {
  flex: none; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; background: var(--red); color: #fff; font-weight: 700; font-size: 1rem;
}
.steps strong { font-weight: 700; }

/* ---------- barra de categorias ---------- */
.cats {
  position: sticky; top: 0; z-index: 20;
  background: rgba(241, 240, 236, .94);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.cats-inner {
  max-width: 760px; margin: 0 auto; padding: 10px 16px;
  display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none;
}
.cats-inner::-webkit-scrollbar { display: none; }
.cats a {
  flex: none; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--paper); color: var(--ink); text-decoration: none; font-size: 1.02rem;
}
.cats a.on { background: var(--red); border-color: var(--red); color: #fff; }

/* ---------- cardápio ---------- */
.menu { max-width: 760px; margin: 0 auto; padding: 8px 16px 0; outline: none; }
.menu-sec { padding-top: 44px; scroll-margin-top: 56px; }
.dishes { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 14px; }
.dish {
  display: flex; gap: 14px; align-items: center; justify-content: space-between;
  background: var(--paper); border: 1.5px solid var(--line); border-radius: var(--radius);
  padding: 18px 16px; transition: border-color .15s ease, box-shadow .15s ease;
}
.dish.picked { border-color: var(--red); box-shadow: 0 0 0 3px var(--red-ring); }
.dish-text { min-width: 0; }
.dish-name { font: 700 1.12rem/1.2 var(--serif); text-transform: uppercase; letter-spacing: .01em; }
.dish-price { margin-top: 4px; color: var(--red); font-weight: 700; font-size: 1.12rem; }
.dish-price span { font-weight: 400; font-size: .95rem; margin-left: 2px; }
.dish-serves { display: inline-block; margin-top: 6px; padding: 2px 10px; border-radius: 999px; background: var(--red-soft); color: var(--red-dark); font-size: .92rem; }
.dish-desc { margin-top: 6px; color: var(--muted); }
.dish-note { margin-top: 6px; font-size: .95rem; font-style: italic; color: var(--muted); }

.qty { flex: none; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.dish .qty { width: 72px; }
.qty-btn {
  width: 44px; height: 44px; border-radius: 50%; border: 1.5px solid var(--red);
  background: transparent; color: var(--red); font-size: 1.5rem; line-height: 1; cursor: pointer;
  display: grid; place-items: center; padding: 0; font-family: system-ui, sans-serif;
  touch-action: manipulation;
}
.qty-btn.plus { background: var(--green); border-color: var(--green); color: #fff; }
.qty-btn.plus:hover { background: var(--green-dark); }
.qty-btn:disabled { visibility: hidden; }
.qty-val { min-height: 1.3em; font-weight: 700; font-size: 1rem; color: var(--red); white-space: nowrap; }
/* sem itens: só o "+" visível, centralizado */
.dish:not(.picked) .qty { flex-direction: column-reverse; }
.dish:not(.picked) .qty .minus, .dish:not(.picked) .qty-val { display: none; }

/* ---------- informações ---------- */
.info { max-width: 760px; margin: 0 auto; padding: 64px 16px 24px; }
.info-list { margin: 28px 0 0; display: grid; gap: 22px; text-align: center; }
.info-list dt { font: 700 1.12rem/1.2 var(--serif); text-transform: uppercase; letter-spacing: .02em; }
.info-list dd { margin: 6px auto 0; max-width: 560px; color: var(--muted); }
.info-list dd strong { color: var(--ink); }

/* ---------- rodapé ---------- */
.footer {
  max-width: 760px; margin: 0 auto; padding: 32px 16px 56px;
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 14px;
}
.footer-gifts { width: min(360px, 80%); }
.footer-logo { width: 190px; margin-top: 10px; }
.footer-wish { width: min(240px, 70%); margin: 6px 0 4px; }
/* ---------- barra do pedido ---------- */
.cartbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  background: linear-gradient(to top, var(--bg) 70%, transparent);
}
.cartbar[hidden] { display: none; }
.cartbar-btn {
  width: 100%; max-width: 728px; margin: 0 auto; min-height: 60px;
  display: flex; align-items: center; gap: 12px; padding: 0 20px;
  border: 0; border-radius: 999px; background: var(--red); color: #fff; cursor: pointer;
  font: 500 1.12rem/1 var(--serif); box-shadow: 0 8px 24px rgba(120, 20, 20, .28);
  animation: rise .25s ease-out;
}
.cartbar-count { min-width: 28px; height: 28px; padding: 0 6px; border-radius: 999px; background: #fff; color: var(--red); display: grid; place-items: center; font-weight: 700; font-size: 1rem; }
.cartbar-label { flex: 1; text-align: left; }
.cartbar-total { font-weight: 700; }
@keyframes rise { from { transform: translateY(20px); opacity: 0; } }

/* ---------- resumo (diálogo) ---------- */
.cart {
  width: 100%; max-width: 560px; max-height: 92vh; max-height: 92dvh; margin: auto auto 0;
  overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch;
  padding: 0; border: 0; border-radius: 22px 22px 0 0; background: var(--bg); color: var(--ink);
}
@media (min-width: 620px) { .cart { margin: auto; border-radius: 22px; } }
.cart::backdrop { background: rgba(30, 10, 10, .45); }
.cart[open] { animation: sheet .22s ease-out; }
@keyframes sheet { from { transform: translateY(40px); opacity: 0; } }
.cart-inner { padding: 20px 18px calc(20px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 16px; }
.cart-head { display: flex; align-items: center; justify-content: space-between; }
.cart-head h2 { font: italic 400 2.2rem/1 var(--display); color: var(--red); text-transform: uppercase; }
.icon-btn { width: 44px; height: 44px; border: 0; border-radius: 50%; background: var(--paper); font-size: 1.8rem; line-height: 1; cursor: pointer; color: var(--ink); }

.cart-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.cart-list li { display: flex; gap: 12px; justify-content: space-between; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.cl-main { display: flex; flex-direction: column; min-width: 0; }
.cl-name { font-weight: 700; line-height: 1.2; }
.cl-meta { font-size: .95rem; color: var(--muted); }
.cl-side { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; flex: none; }
.qty-sm { flex-direction: row; gap: 6px; }
.qty-sm .qty-btn { width: 34px; height: 34px; font-size: 1.2rem; background: transparent; color: var(--red); }
.qty-sm .qty-val { min-width: 54px; text-align: center; }
.cl-sub { font-weight: 700; font-size: 1rem; }
.cart-empty { color: var(--muted); text-align: center; }
.cart-empty[hidden] { display: none; }

.cart-totals { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; display: grid; gap: 6px; }
.cart-totals .row { display: flex; justify-content: space-between; gap: 12px; }
.cart-totals .sinal { color: var(--red); font-size: 1.15rem; }
.cart-note { font-size: .92rem; color: var(--muted); font-style: italic; }

.field { display: grid; gap: 6px; }
.field span { font-weight: 700; }
.field em { font-weight: 400; color: var(--muted); }
.field input, .field textarea {
  width: 100%; padding: 12px 14px; border-radius: 12px; border: 1.5px solid var(--line);
  background: #fff; font: 400 1.08rem/1.3 var(--serif); color: var(--ink);
}
.field input:focus, .field textarea:focus { border-color: var(--red); outline: none; }
.cart-reminder { font-size: 1rem; color: var(--muted); text-align: center; }
.cart-error { color: var(--red-dark); font-weight: 700; text-align: center; min-height: 0; }
.cart-error:empty { display: none; }
.link-btn { background: none; border: 0; color: var(--muted); text-decoration: underline; font: inherit; font-size: 1rem; cursor: pointer; align-self: center; padding: 6px; }

/* ---------- encomendas encerradas ---------- */
body.closed .qty { display: none; }

/* ---------- telas maiores ---------- */
@media (min-width: 720px) {
  .hero { padding-top: 56px; }
  .hero-scene { width: 100%; margin-top: 20px; }
  .s1 { right: 14%; width: 56px; top: 40px; } .s2 { left: 15%; top: 70px; } .s3 { left: 6%; top: 300px; } .s4 { right: 10%; top: 320px; }
  .dish { padding: 22px 24px; }
  .dish .qty { width: 84px; }
  .steps { grid-template-columns: repeat(3, 1fr); }
  .steps li { flex-direction: column; }
}
@media (max-width: 380px) {
  .facts { grid-template-columns: 1fr; }
  .facts li { flex-direction: row; justify-content: space-between; align-items: baseline; }
}
