:root {
  --red: #E8180A;
  --red-dark: #B81208;
  --ink: #1C1414;
  --muted: #74625F;
  --cream: #FFF6F2;
  --line: #F1DEDA;
  --card: #FFFFFF;
  --radius: 20px;
  --shadow: 0 10px 30px rgba(120, 20, 10, .10);
  --display: 'Fredoka', 'Nunito', system-ui, sans-serif;
  --body: 'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif;
  color-scheme: light;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--body);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; }
a { color: inherit; }

/* Header */
.top { position: sticky; top: 0; z-index: 40; background: var(--red); box-shadow: 0 2px 14px rgba(0, 0, 0, .15); }
.top-in { max-width: 1120px; margin: 0 auto; padding: 8px 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand-logo { background: #fff; border-radius: 12px; padding: 4px 7px; box-shadow: 0 2px 8px rgba(0, 0, 0, .14); }
.brand-logo img { height: 34px; width: auto; }
.brand-word { font-family: var(--display); font-weight: 700; color: #fff; font-size: 1.25rem; letter-spacing: .3px; white-space: nowrap; }
@media (max-width: 440px) { .brand-word { display: none; } }
.top-right { display: flex; align-items: center; gap: 8px; }
.table-chip { font-family: var(--display); font-weight: 600; font-size: .9rem; color: var(--red); background: #fff; border-radius: 999px; padding: 4px 12px; white-space: nowrap; }
.langs { display: flex; background: rgba(255, 255, 255, .18); border-radius: 12px; padding: 3px; }
.langs button { border: 0; background: transparent; color: #fff; font-family: var(--display); font-weight: 600; font-size: .85rem; padding: 6px 9px; border-radius: 9px; min-width: 38px; }
.langs button[aria-pressed="true"] { background: #fff; color: var(--red); }

/* Hero */
.hero { background: var(--red); color: #fff; text-align: center; padding: 22px 20px 54px; position: relative; overflow: hidden; }
.hero::before { content: ''; position: absolute; inset: 0; background-image: radial-gradient(rgba(255, 255, 255, .16) 2px, transparent 2.5px); background-size: 22px 22px; opacity: .7; }
.hero::after { content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 34px; background: var(--cream); border-radius: 50% 50% 0 0 / 100% 100% 0 0; }
.hero > * { position: relative; }
.hero-logo { width: 132px; height: auto; margin: 0 auto 14px; background: #fff; border-radius: 28px; padding: 14px 20px; box-shadow: 0 10px 24px rgba(0, 0, 0, .22); }
.hero h1 { font-family: var(--display); font-weight: 700; font-size: clamp(1.7rem, 6vw, 2.6rem); line-height: 1.1; }
.hero p { font-weight: 700; opacity: .95; margin-top: 8px; font-size: 1.02rem; }

/* Category chips */
.cats { position: sticky; top: 54px; z-index: 30; background: rgba(255, 246, 242, .94); backdrop-filter: saturate(1.4) blur(8px); -webkit-backdrop-filter: saturate(1.4) blur(8px); border-bottom: 1px solid var(--line); }
.cats-in { max-width: 1120px; margin: 0 auto; display: flex; gap: 8px; overflow-x: auto; padding: 10px 16px; scrollbar-width: none; scroll-snap-type: x proximity; }
.cats-in::-webkit-scrollbar { display: none; }
.chip { flex: 0 0 auto; scroll-snap-align: start; border: 2px solid var(--line); background: #fff; color: var(--ink); border-radius: 999px; padding: 7px 14px; font-family: var(--display); font-weight: 600; font-size: .95rem; white-space: nowrap; transition: background .15s, color .15s, border-color .15s; }
.chip .dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--c, var(--red)); margin-right: 7px; vertical-align: 1px; }
.chip.active { background: var(--c, var(--red)); border-color: var(--c, var(--red)); color: #fff; }
.chip.active .dot { background: #fff; }

/* Menu */
.wrap { max-width: 1120px; margin: 0 auto; padding: 8px 16px 40px; min-height: 50vh; }
.section { padding-top: 22px; scroll-margin-top: 112px; }
.section-head { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.section-head h2 { font-family: var(--display); font-weight: 700; font-size: 1.6rem; color: var(--c, var(--red)); line-height: 1.15; }
.section-head .bar { height: 4px; flex: 1 1 60px; min-width: 40px; border-radius: 4px; background: var(--c, var(--red)); opacity: .25; align-self: center; }
.section-note { font-weight: 800; font-size: .8rem; text-transform: uppercase; letter-spacing: .6px; color: var(--muted); }
.grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 640px) { .grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 980px) { .grid { grid-template-columns: 1fr 1fr 1fr; gap: 16px; } }

.card { display: flex; gap: 12px; background: var(--card); border-radius: var(--radius); padding: 10px; box-shadow: var(--shadow); text-align: left; border: 0; width: 100%; color: inherit; position: relative; transition: transform .15s; }
.card:active { transform: scale(.985); }
.card-img { flex: 0 0 104px; height: 104px; border-radius: 14px; overflow: hidden; background: var(--c, var(--red)); position: relative; }
.card-img img { width: 100%; height: 100%; object-fit: cover; }
.card-img.empty { display: grid; place-items: center; }
.card-img.empty svg { width: 52px; height: 52px; fill: rgba(255, 255, 255, .9); }
.card-body { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 4px; padding: 2px 2px 2px 0; }
.card-title { font-family: var(--display); font-weight: 600; font-size: 1.12rem; line-height: 1.2; }
.card-desc { font-size: .86rem; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.prices { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 4px; }
.price { display: inline-flex; align-items: baseline; gap: 5px; background: #FFF0EC; color: var(--red-dark); border-radius: 10px; padding: 3px 9px; font-weight: 800; font-size: .95rem; }
.price small { font-weight: 800; font-size: .66rem; letter-spacing: .5px; text-transform: uppercase; color: var(--muted); }
.card.soldout { opacity: .55; }
.card.soldout .card-img img { filter: grayscale(1); }
.badge-out { position: absolute; top: 14px; left: 14px; background: #1C1414; color: #fff; font-weight: 800; font-size: .7rem; text-transform: uppercase; letter-spacing: .6px; padding: 3px 8px; border-radius: 8px; }

/* Footer */
.foot { background: #fff; border-top: 1px solid var(--line); padding: 28px 16px calc(28px + env(safe-area-inset-bottom)); text-align: center; }
.foot-note { color: var(--muted); font-weight: 700; margin-bottom: 18px; }
.foot-note b { color: var(--red); }
.foot-grid { max-width: 900px; margin: 0 auto; display: grid; grid-template-columns: 1fr; gap: 10px; }
@media (min-width: 720px) { .foot-grid { grid-template-columns: repeat(3, 1fr); } }
.foot-card { display: flex; align-items: center; gap: 12px; text-align: left; background: var(--cream); border-radius: 16px; padding: 12px 14px; }
.foot-card small { display: block; color: var(--muted); font-weight: 800; font-size: .72rem; text-transform: uppercase; letter-spacing: .5px; }
.foot-card a, .foot-card span { font-weight: 800; text-decoration: none; }
.foot-ic { flex: 0 0 38px; height: 38px; border-radius: 12px; background: var(--red); display: grid; place-items: center; }
.foot-ic svg { width: 20px; height: 20px; fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.socials { display: flex; justify-content: center; gap: 10px; margin: 18px 0 8px; flex-wrap: wrap; }
.socials a { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-weight: 800; color: var(--red); border: 2px solid var(--line); border-radius: 999px; padding: 7px 14px; }
.socials svg { width: 18px; height: 18px; fill: currentColor; }
.made { color: var(--muted); font-size: .82rem; margin-top: 10px; }
.made a { color: var(--muted); }

/* Detail sheet */
.sheet { position: fixed; inset: 0; z-index: 60; display: flex; align-items: flex-end; justify-content: center; }
.sheet[hidden] { display: none; }
.sheet-bg { position: absolute; inset: 0; background: rgba(28, 10, 8, .55); animation: fade .2s ease; }
.sheet-card { position: relative; background: #fff; width: 100%; max-width: 560px; max-height: 92vh; overflow-y: auto; border-radius: 26px 26px 0 0; animation: up .25s ease; padding-bottom: env(safe-area-inset-bottom); }
@media (min-width: 640px) { .sheet { align-items: center; } .sheet-card { border-radius: 26px; } }
.sheet-x { position: absolute; top: 12px; right: 12px; z-index: 2; width: 40px; height: 40px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .92); font-size: 1.6rem; line-height: 1; color: var(--ink); box-shadow: 0 2px 10px rgba(0, 0, 0, .15); }
.sheet-media { background: var(--c, var(--red)); position: relative; }
.sheet-media .slides { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.sheet-media .slides::-webkit-scrollbar { display: none; }
.sheet-media .slides img { flex: 0 0 100%; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; scroll-snap-align: center; }
.sheet-media .empty { aspect-ratio: 16 / 9; display: grid; place-items: center; }
.sheet-media .empty svg { width: 96px; height: 96px; fill: rgba(255, 255, 255, .9); }
.dots { position: absolute; bottom: 10px; left: 0; right: 0; display: flex; justify-content: center; gap: 6px; }
.dots span { width: 8px; height: 8px; border-radius: 50%; background: rgba(255, 255, 255, .55); }
.dots span.on { background: #fff; }
.sheet-body { padding: 18px 20px 24px; }
.sheet-cat { font-weight: 800; font-size: .75rem; text-transform: uppercase; letter-spacing: .7px; color: var(--c, var(--red)); }
.sheet-body h2 { font-family: var(--display); font-weight: 700; font-size: 1.7rem; line-height: 1.15; margin: 4px 0 8px; }
.sheet-body p { color: var(--muted); font-size: 1rem; }
.sheet-prices { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.sheet-prices .price { font-size: 1.15rem; padding: 8px 14px; border-radius: 14px; }
.sheet-prices .price small { font-size: .74rem; }

.loading { display: grid; place-items: center; padding: 80px 0; }
.spinner { width: 42px; height: 42px; border-radius: 50%; border: 4px solid var(--line); border-top-color: var(--red); animation: spin .8s linear infinite; }
.error-box { text-align: center; padding: 60px 20px; color: var(--muted); font-weight: 700; }
.error-box button { margin-top: 14px; border: 0; background: var(--red); color: #fff; border-radius: 12px; padding: 10px 18px; font-weight: 800; }

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes fade { from { opacity: 0; } }
@keyframes up { from { transform: translateY(40px); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }
