/* Carte: Osteria Lucciola. Firefly trattoria: night blue, candle amber, basil green, cream. */
:root {
  --night: #0D1730;
  --night-2: #15223F;
  --line: #2C3D66;
  --cream: #F5ECDA;
  --muted: #C3CBDE;
  --amber: #F4B045;
  --amber-hi: #FFD27A;
  --basil: #86C685;
  --font-display: "Cormorant Garamond", "Iowan Old Style", Georgia, serif;
  --font-body: Figtree, "Segoe UI", system-ui, sans-serif;
  --wrap: 1120px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 320px;
  font: 400 17px/1.6 var(--font-body);
  color: var(--cream);
  background-color: var(--night);
  background-image:
    radial-gradient(circle at center, rgba(244, 176, 69, .34) 0 1.2px, transparent 1.9px),
    radial-gradient(circle at center, rgba(134, 198, 133, .22) 0 1px, transparent 1.6px);
  background-size: 137px 137px, 211px 211px;
  background-position: 0 0, 60px 90px;
  padding-bottom: calc(76px + env(safe-area-inset-bottom));
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: var(--amber-hi); }
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; line-height: 1.08; margin: 0 0 .5em; color: var(--cream); }
h1 { font-size: clamp(2.5rem, 8vw, 4.4rem); }
h2 { font-size: clamp(2rem, 6vw, 3rem); }
h3 { font-size: 1.7rem; }
p { margin: 0 0 1em; }
em { font-style: italic; color: var(--amber-hi); }
:focus-visible { outline: 3px solid var(--amber-hi); outline-offset: 3px; border-radius: 4px; }
.skip { position: absolute; left: 12px; top: -60px; background: var(--amber); color: var(--night); padding: 10px 16px; border-radius: 8px; font-weight: 700; z-index: 50; text-decoration: none; }
.skip:focus { top: 12px; }
.wrap { width: calc(100% - 32px); max-width: var(--wrap); margin-inline: auto; }
.eyebrow { font-size: .8rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--amber); margin-bottom: .6em; }
.lead { font-size: 1.12rem; color: var(--muted); max-width: 36em; }
section { scroll-margin-top: 16px; }

/* Buttons and tap targets */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 22px; border-radius: 999px; font-weight: 700; text-decoration: none; border: 2px solid transparent; font-size: 1rem; }
.btn-amber { background: var(--amber); color: var(--night); }
.btn-amber:hover { background: var(--amber-hi); }
.btn-ghost { border-color: var(--line); color: var(--cream); }
.btn-ghost:hover { border-color: var(--amber); }

/* Header */
.site-header { position: relative; border-bottom: 1px solid var(--line); background: rgba(13, 23, 48, .92); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 68px; }
.wordmark { display: inline-flex; align-items: center; gap: 10px; color: var(--cream); text-decoration: none; font-family: var(--font-display); font-size: 1.45rem; font-weight: 600; min-height: 44px; }
.mark { width: 30px; height: 30px; }
.mark-glow { fill: rgba(244, 176, 69, .28); }
.mark-core { fill: var(--amber-hi); }
.mark-dot { fill: var(--basil); }
.desktop-nav { display: none; }
.desktop-nav a:not(.btn) { color: var(--cream); text-decoration: none; padding: 0 12px; min-height: 44px; display: inline-flex; align-items: center; font-weight: 600; }
.desktop-nav a[aria-current="page"] { color: var(--amber-hi); box-shadow: inset 0 -3px 0 var(--amber); }
.mobile-nav { position: static; }
.mobile-nav summary { list-style: none; display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border: 1px solid var(--line); border-radius: 999px; cursor: pointer; font-weight: 700; color: var(--cream); }
.mobile-nav summary::-webkit-details-marker { display: none; }
.mobile-nav[open] summary { border-color: var(--amber); }
.mobile-nav nav { position: absolute; right: 16px; top: 62px; width: min(280px, calc(100% - 32px)); z-index: 20; display: grid; background: var(--night-2); border: 1px solid var(--line); border-radius: 16px; padding: 8px; box-shadow: 0 18px 40px rgba(0, 0, 0, .45); }
.mobile-nav nav a { display: flex; align-items: center; min-height: 48px; padding: 0 12px; color: var(--cream); text-decoration: none; font-weight: 600; border-radius: 10px; }
.mobile-nav nav a[aria-current="page"] { color: var(--amber-hi); background: rgba(244, 176, 69, .12); }
.mobile-nav nav a.nav-call { color: var(--amber-hi); }

/* Mobile action bar: never covers content (body keeps bottom padding) */
.action-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: grid; grid-template-columns: repeat(3, 1fr); background: var(--night-2); border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom); }
.action-bar a { display: flex; align-items: center; justify-content: center; min-height: 60px; text-align: center; padding: 6px 4px; color: var(--cream); font-weight: 700; font-size: .95rem; text-decoration: none; }
.action-bar a:first-child, .action-bar a[aria-current] { color: var(--amber-hi); }

/* Hero */
.hero { padding: 36px 0 28px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.hero-art { margin: 0 0 20px; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 18px; border: 1px solid var(--line); }

/* Menu tabs (sticky) */
.menu { padding-bottom: 24px; }
.tabs { position: sticky; top: 0; z-index: 10; display: flex; gap: 8px; overflow-x: auto; white-space: nowrap; scrollbar-width: none; padding: 10px 0; margin: 0 -16px 12px; padding-inline: 16px; background: rgba(13, 23, 48, .97); border-bottom: 1px solid var(--line); -webkit-overflow-scrolling: touch; }
.tabs::-webkit-scrollbar { display: none; }
.tabs:empty { display: none; }
.tab { display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); color: var(--cream); text-decoration: none; font-weight: 700; font-size: .95rem; flex: 0 0 auto; }
.tab[aria-current="true"] { background: var(--amber); border-color: var(--amber); color: var(--night); }

.menu-head h2 { margin-bottom: .2em; }
.key-line { color: var(--muted); font-size: .95rem; }
.allergen-key { margin: 12px 0 20px; }
.allergen-key summary { display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border: 1px solid var(--line); border-radius: 999px; cursor: pointer; font-weight: 700; color: var(--cream); }
.allergen-key[open] summary { border-color: var(--amber); }
.letters-key { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 16px; margin: 14px 0 26px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 14px; background: rgba(21, 34, 63, .6); font-size: .95rem; }
.letters-key div { display: flex; gap: 8px; }
.letters-key dt { font-weight: 700; color: var(--amber-hi); min-width: 2.2em; }
.letters-key dd { margin: 0; color: var(--cream); }

/* Printed-card panels */
.panel { padding: 22px 0 10px; border-top: 2px double var(--line); }
#menu .panel { scroll-margin-top: 80px; }
.panel:first-of-type { border-top: 0; }
.panel-head { margin-bottom: 14px; }
.panel-name { margin-bottom: .1em; }
.panel-note { color: var(--muted); font-size: .95rem; margin: 0; }
.panel-note a { color: var(--amber-hi); }
.dishes, .wines { list-style: none; margin: 0; padding: 0; }
.dish { padding: 14px 0; border-bottom: 1px dashed var(--line); }
.dish-top, .wine-top { display: flex; align-items: baseline; gap: 10px; }
.dish-top { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; }
.dish-top .leader { display: none; }
.dish-name, .wine-name { font-family: var(--font-display); font-size: 1.4rem; font-weight: 600; color: var(--cream); line-height: 1.2; }
.leader { flex: 1 1 16px; min-width: 16px; border-bottom: 2px dotted rgba(244, 176, 69, .6); transform: translateY(-5px); }
.dish-price, .wine-price { font-weight: 700; color: var(--amber-hi); white-space: nowrap; font-size: 1.05rem; }
.dish-desc { margin: 4px 0 0; color: var(--muted); font-size: 1rem; }
.dish-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin: 8px 0 0; font-size: .9rem; }
.tag { display: inline-flex; align-items: center; justify-content: center; min-width: 28px; height: 26px; padding: 0 7px; border-radius: 8px; font-weight: 700; font-size: .85rem; border: 1px solid var(--basil); color: var(--basil); }
.tag-today { border-color: var(--amber); color: var(--amber-hi); background: rgba(244, 176, 69, .14); }
.allergens { color: var(--muted); }
.allergens strong, .allergens span.letters { color: var(--cream); font-weight: 700; letter-spacing: .04em; }
.dish-empty, .wine-empty { color: var(--muted); font-style: italic; padding: 12px 0; list-style: none; }
[data-pl-item]:not(template) ~ [data-pl-empty] { display: none; }

/* Wines */
.wine { padding: 14px 0; border-bottom: 1px dashed var(--line); }
.wine-meta { margin: 2px 0 6px; color: var(--muted); font-size: .95rem; }
.wine-meta .colour { text-transform: capitalize; }
.wine-prices { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 0; font-size: .95rem; }
.wine-prices div { display: flex; gap: 6px; }
.wine-prices dt { color: var(--muted); }
.wine-prices dd { margin: 0; font-weight: 700; color: var(--cream); }
.wine.red .wine-name::before, .wine.white .wine-name::before, .wine.rose .wine-name::before, .wine.sparkling .wine-name::before {
  content: ""; display: inline-block; width: 11px; height: 11px; border-radius: 50%; margin-right: 10px; vertical-align: middle; transform: translateY(-2px);
}
.wine.red .wine-name::before { background: #B8452F; }
.wine.white .wine-name::before { background: #E9D98A; }
.wine.rose .wine-name::before { background: #E88F9C; }
.wine.sparkling .wine-name::before { background: var(--basil); }
.wine-empty { list-style: none; }
.panel-wine .wines { margin-top: 0; }
.panel-wine .wine:last-child { border-bottom: 0; }

/* Shared sections */
.band { padding: 44px 0; border-top: 1px solid var(--line); background: var(--night-2); }
.band h2 { font-size: clamp(1.9rem, 5vw, 2.6rem); }
.band-cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; }
.cols { display: grid; gap: 28px; }
.note-card { border: 1px solid var(--line); border-radius: 16px; padding: 20px; background: rgba(21, 34, 63, .55); }
.note-card h3 { font-size: 1.5rem; }
.pagehead { padding: 40px 0 26px; border-bottom: 1px solid var(--line); }
.pagehead + .menu { padding-top: 32px; }
.allergen-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.allergen-list li { display: grid; grid-template-columns: 56px 1fr; gap: 14px; padding: 12px 0; border-bottom: 1px dashed var(--line); }
.allergen-list .letter { font-weight: 700; color: var(--night); background: var(--amber); border-radius: 10px; display: flex; align-items: center; justify-content: center; min-height: 44px; font-size: 1rem; }
.allergen-list strong { display: block; color: var(--cream); font-size: 1.05rem; }
.allergen-list span { color: var(--muted); font-size: .98rem; }
.steps { padding-left: 1.2em; margin: 0; }
.steps li { margin-bottom: .6em; }

.hours { width: 100%; border-collapse: collapse; margin: 6px 0 0; font-size: 1rem; }
.hours th, .hours td { text-align: left; padding: 10px 8px 10px 0; border-bottom: 1px dashed var(--line); vertical-align: top; }
.hours th { font-weight: 700; color: var(--cream); width: 40%; }
.hours td { color: var(--muted); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); background: var(--night-2); padding: 36px 0 28px; }
.footer-grid { display: grid; gap: 22px; }
.footer-name { font-family: var(--font-display); font-size: 1.6rem; font-weight: 600; margin: 0 0 .3em; color: var(--cream); }
.footer-h { font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; font-weight: 700; color: var(--amber); margin: 0 0 .4em; }
.site-footer p, .site-footer li { margin: 0 0 .5em; color: var(--muted); }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer a { color: var(--cream); display: inline-flex; align-items: center; min-height: 44px; }
.site-footer a { overflow-wrap: anywhere; min-width: 0; max-width: 100%; }
.footer-cta { margin-top: 22px; }
.site-footer a.btn-amber { color: var(--night); }

/* Enquiry form (About, when the form is switched on) */
.form { display: grid; gap: 12px; width: 100%; max-width: 36rem; }
.form h3 { margin: 0; }
.form label { font-weight: 700; color: var(--cream); }
.form input, .form textarea { width: 100%; min-height: 48px; padding: 12px; font: inherit; color: var(--cream); background: var(--night); border: 1px solid var(--muted); border-radius: 8px; }
.form textarea { min-height: 140px; }
.form .btn { justify-self: start; }

/* Table card (print: A6) */
.card-wrap { display: grid; grid-template-columns: minmax(0, 1fr); justify-items: center; gap: 14px; padding: 28px 0 10px; }
.card { width: min(100%, 105mm); aspect-ratio: 105 / 148; background: var(--night); border: 2px solid var(--amber); border-radius: 18px; padding: 26px 22px 20px; display: flex; flex-direction: column; align-items: center; text-align: center; box-shadow: inset 0 0 0 6px var(--night), inset 0 0 0 7px rgba(244, 176, 69, .35); print-color-adjust: exact; -webkit-print-color-adjust: exact; }
.card-kicker { font-size: .72rem; letter-spacing: .18em; text-transform: uppercase; font-weight: 700; color: var(--amber); margin: 0 0 6px; }
.card-name { font-size: 2.4rem; margin: 0 0 6px; line-height: 1; }
.card-scan { font-family: var(--font-display); font-size: 1.6rem; font-style: italic; color: var(--amber-hi); margin: 0 0 12px; }
.card-qr { width: 62%; height: auto; aspect-ratio: 1 / 1; }
.card-foot { margin-top: auto; font-size: .9rem; color: var(--muted); }
.card-foot strong { color: var(--cream); }
.card-foot p { margin: 0 0 4px; }

/* Screen-only note for the table card page */
.print-note { color: var(--muted); font-size: .95rem; max-width: 60ch; margin: 0 auto; text-align: center; }

@media (min-width: 720px) {
  .letters-key { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .cols { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1.2fr 1fr 1fr; }
  .card-wrap { padding-top: 40px; }
}
@media (min-width: 900px) {
  body { padding-bottom: 0; }
  .action-bar { display: none; }
  .panel { padding: 28px 0 14px; }
  .cols.three { grid-template-columns: repeat(3, 1fr); }
  .dishes { display: grid; grid-template-columns: 1fr 1fr; column-gap: 40px; }
  .dishes .dish-empty { grid-column: 1 / -1; }
  .dish:last-child { border-bottom: 0; }
  .wines { display: grid; grid-template-columns: 1fr 1fr; column-gap: 40px; }
  .wine:nth-last-child(-n+2) { border-bottom: 0; }
  .tabs { margin-inline: 0; padding-inline: 0; }
}
@media print {
  @page { size: A6; margin: 0; }
  body { background: var(--night); padding: 0; }
  .skip, .site-header, .site-footer, .action-bar, .print-note, .pagehead, .band, .card-wrap > p { display: none !important; }
  .card-wrap { padding: 0; gap: 0; }
  .card { width: 105mm; height: 148mm; border-radius: 0; border: 0; box-shadow: none; aspect-ratio: auto; }
}
@media (min-width: 1000px) {
  .desktop-nav { display: flex; align-items: center; gap: 2px; }
  .mobile-nav { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
