:root {
  color-scheme: light;
  --cream: #fff8ed;
  --cream-dark: #f8ead6;
  --ink: #493124;
  --subtle: #796250;
  --pink: #db9faa;
  --green: #52876e;
  --yellow: #f7ca80;
  --line: #eedfcc;
  --shadow: 0 12px 34px rgba(67, 48, 32, .12);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--cream); font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; color: var(--ink); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
button,input { font: inherit; }
button { cursor: pointer; }
.wrap { width: min(100% - 32px, 780px); margin-inline: auto; }
.skip-link { position: absolute; left: 12px; top: -120px; z-index: 30; background: white; padding: 12px 16px; }
.skip-link:focus { top: 12px; }
:focus-visible { outline: 3px solid #be653d; outline-offset: 4px; }
h1, h2, h3, p { overflow-wrap: break-word; }
h2 { margin: 4px 0 0; font-weight: 820; font-size: clamp(1.05rem, 3.6vw, 1.5rem); letter-spacing: -.025em; }
.menu-tabs { position: sticky; top: 0; z-index: 10; background: rgba(255, 248, 237, .96); border-block: 1px solid var(--line); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.tabs-inner { padding: 10px 0; display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; }
.tabs-inner::-webkit-scrollbar { display: none; }
.tab { flex: 1 0 auto; white-space: nowrap; display: flex; gap: 8px; align-items: center; justify-content: center; text-decoration: none; padding: 11px 14px; border: 1px solid transparent; border-radius: 99px; color: #795e49; font-weight: 760; font-size: .79rem; transition: background .17s ease, color .17s ease; }
.tab.is-active { background: #4d8368; color: white; box-shadow: 0 2px 8px #3d70562b; }
.tab-number { opacity: .7; font-size: .66rem; letter-spacing: .08em; }
.menu-stack { padding: 12px 0 25px; }
.menu-section { margin: 18px auto 44px; scroll-margin-top: 84px; }
.section-bar { display: flex; justify-content: space-between; align-items: end; gap: 10px; margin: 0 3px 13px; }
.section-kicker { color: var(--green); letter-spacing: .12em; font-weight: 840; font-size: .7rem; }
h2 { margin: 4px 0 0; font-weight: 820; font-size: clamp(1.05rem, 3.6vw, 1.5rem); letter-spacing: -.025em; }
.zoom-link { font-size: .78rem; white-space: nowrap; font-weight: 780; text-decoration: none; background: white; border: 1px solid var(--line); border-radius: 99px; padding: 9px 12px; }
.zoom-link:hover, .owner-link:hover { color: var(--green); }
.menu-image-link { display: block; overflow: hidden; border-radius: 18px; background: #fff; box-shadow: var(--shadow); border: 1px solid #e6d6c7; line-height: 0; }
.menu-image { width: 100%; height: auto; display: block; }
.back-to-top { position: fixed; right: max(14px, calc((100vw - 830px)/2)); bottom: 17px; z-index: 8; display: flex; align-items: center; gap: 6px; padding: 11px 14px; color: white; background: #4b7e65; box-shadow: 0 5px 20px #304d3980; border-radius: 100px; text-decoration: none; font-size: .8rem; font-weight: 800; }
.back-to-top:hover { background: #385e4c; }
/* Owner QR page */
.qr-page { min-height: 100svh; }
.qr-header { padding-top: 27px; padding-bottom: 18px; text-align: center; }
.qr-back { display: inline-block; font-size: .82rem; text-decoration: none; font-weight: 760; padding: 9px 15px; border: 1px solid var(--line); border-radius: 30px; background: white; }
.qr-header h1 { font-size: clamp(2rem, 6vw, 3.1rem); margin: 20px 0 10px; }
.qr-header p { color: var(--subtle); line-height: 1.5; margin: 0 auto; max-width: 440px; }
.qr-workspace { max-width: 690px; padding: 0 0 45px; }
.qr-panel { background: white; padding: 20px; border: 1px solid #eadbcc; border-radius: 18px; box-shadow: 0 5px 20px #523e2812; }
.field-label { display: block; margin-bottom: 9px; font-weight: 780; font-size: .86rem; }
.field-control { display: flex; gap: 8px; }
#menu-url { min-width: 0; flex: 1; padding: 12px 13px; border-radius: 10px; border: 1px solid #cbbcaf; background: #fffdfa; font-size: .9rem; }
.primary-button, .secondary-button { border-radius: 10px; padding: 11px 16px; font-size: .87rem; font-weight: 780; border: 1px solid #3b7359; }
.primary-button { background: #4c856a; color: white; }
.secondary-button { color: var(--ink); background: white; border-color: #d5c1ad; }
.primary-button:hover { background: #37644e; }
.secondary-button:hover { background: #faf1e6; }
.hint { color: var(--subtle); font-size: .78rem; margin: 10px 0 0; line-height: 1.45; }
.form-error { color: #ae283e; font-weight: 730; min-height: 0; margin: 6px 0 0; font-size: .8rem; }
.form-error:empty { display: none; }
.qr-print-card { text-align: center; background: #ffffff; border: 2px dashed #e3d5bf; border-radius: 20px; padding: 30px 15px 25px; margin: 17px auto 0; }
.qr-print-card h2 { font-size: clamp(1.5rem, 5vw, 2.5rem); line-height: 1.2; margin: 8px auto 5px; }
.qr-print-card .print-subtitle { margin: 0; color: var(--subtle); font-weight: 650; }
.qr-art { width: min(100%, 330px); aspect-ratio: 1; margin: 20px auto 6px; display: flex; align-items: center; justify-content: center; }
.qr-art svg { width: 100%; display: block; height: auto; shape-rendering: crispEdges; }
.qr-placeholder { border: 2px dashed #dfcbb7; color: #897262; font-size: .85rem; padding: 28px; border-radius: 10px; line-height: 1.5; }
.qr-destination { font-size: .77rem; max-width: 100%; overflow-wrap: anywhere; color: var(--subtle); }
.qr-tagline { display: inline-flex; background: #f9e6e6; border-radius: 50px; padding: 8px 14px; font-size: .72rem; font-weight: 780; margin: 14px auto 0; }
.qr-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 18px 0 0; }
.qr-actions button { min-width: 128px; }
.qr-actions button:disabled { opacity: .48; cursor: not-allowed; }
.qr-instructions { line-height: 1.6; color: var(--subtle); font-size: .83rem; margin: 16px 9px; text-align: center; }
.qr-instructions strong { color: var(--ink); }
@media(max-width: 580px) {
  .wrap { width: min(100% - 20px, 780px); }
  .tabs-inner { padding-block: 9px; }
  .tab { font-size: .73rem; padding: 10px 12px; }
  .section-bar { align-items: center; margin: 0 4px 11px; }
  .zoom-link { font-size: .7rem; padding: 8px 9px; }
  .menu-image-link { border-radius: 11px; }
  .menu-section { margin: 14px auto 32px; }
  .field-control { flex-direction: column; }
  .field-control button { width: 100%; }
  .qr-panel { padding: 14px; }
  .qr-print-card { padding: 24px 10px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .tab { transition: none; } }
@media print {
  @page { size: A5 portrait; margin: 12mm; }
  body.qr-page { background: white; }
  .qr-header, .qr-panel, .qr-actions, .qr-instructions { display: none !important; }
  .qr-workspace { max-width: none; width: 100%; margin: 0; padding: 0; }
  .qr-print-card { display: block; border: 2px solid #eadac4; padding: 10mm 3mm; margin: 0 auto; border-radius: 13px; break-inside: avoid; }
  .qr-art { width: 85mm; margin: 13mm auto 4mm; }
  .qr-print-card h2 { font-size: 27pt; }
  .qr-destination { font-size: 9pt; }
}
