:root {
  --wine: #4a1b26;
  --wine-deep: #3a141d;
  --wine-soft: #5a2331;
  --wine-lift: #6a2c3b;
  --cream: #f3e7d6;
  --cream-soft: #d9c8b4;
  --cream-faint: #a89383;
  --gold: #d4af6a;
  --gold-soft: #e6cd97;
  --ink: #1f0b10;
  --line: rgba(243, 231, 214, .12);
  --line-strong: rgba(243, 231, 214, .24);
  --error: #e8a091;
  --time-good: #7a8f3e;
  --time-medium: #c9a43d;
  --time-bad: #c45a3a;
  --serif: "Instrument Serif", Georgia, serif;
  --sans: "Manrope", "Helvetica Neue", Arial, sans-serif;
  --ease: cubic-bezier(.22, .75, .2, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --shadow: 0 30px 60px -30px rgba(0, 0, 0, .7);
  --topbar-h: 84px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; background: var(--wine); overflow-x: hidden; overflow-x: clip; }

body {
  margin: 0;
  min-height: 100svh;
  background:
    radial-gradient(120% 80% at 50% -10%, var(--wine-soft), transparent 60%),
    radial-gradient(80% 60% at 100% 100%, rgba(212, 175, 106, .07), transparent 60%),
    var(--wine);
  color: var(--cream);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  overflow-x: clip;
  display: flex;
  flex-direction: column;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: .5;
  z-index: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 .95 0 0 0 0 .9 0 0 0 0 .8 0 0 0 .045 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}

main, header, footer { position: relative; z-index: 1; }
main { flex: 1; }

img { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
input, select, textarea { font: inherit; color: var(--cream); }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }

::selection { background: var(--gold); color: var(--ink); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 3px; }

.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; clip: rect(0 0 0 0); overflow: hidden; white-space: nowrap; }

.skip-link { position: fixed; top: -60px; left: 1rem; z-index: 300; background: var(--gold); color: var(--ink); padding: .7rem 1.2rem; border-radius: 4px; text-decoration: none; transition: top .25s var(--ease); }
.skip-link:focus { top: 1rem; }

h1, h2, h3 { font-family: var(--serif); font-weight: 400; line-height: 1.05; margin: 0; letter-spacing: -.01em; }
h1 em, h2 em { font-style: italic; color: var(--gold); }

.eyebrow { font-size: .66rem; letter-spacing: .26em; text-transform: uppercase; color: var(--gold); font-weight: 600; margin: 0 0 .7rem; }

/* ---------- Top bar ---------- */

.topbar {
  position: sticky; top: 0; z-index: 90;
  background: color-mix(in srgb, var(--wine) 82%, transparent);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid transparent;
  transition: border-color .4s var(--ease);
}
.topbar.is-scrolled { border-bottom-color: var(--line); }
.topbar-inner {
  height: var(--topbar-h);
  padding: 0 clamp(1.2rem, 4vw, 3.5rem);
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 1rem;
}

.brand { display: inline-flex; align-items: center; position: relative; z-index: 10; color: var(--cream); justify-self: start; overflow: visible; }
.brand-mark { width: 48px; height: 48px; position: relative; z-index: 1; transition: transform .8s var(--ease), color .3s; }
.brand-name {
  position: absolute; left: 0; top: 0; bottom: 0; z-index: 0;
  display: flex; align-items: center; padding-left: 54px;
  white-space: nowrap; opacity: 0; transform: translateX(-8px); pointer-events: none;
  color: var(--gold); font-family: var(--serif); font-size: 1.1rem; letter-spacing: .02em;
  transition: opacity .4s var(--ease), transform .4s var(--ease);
}
.brand:hover .brand-mark { color: var(--gold); transform: rotate(180deg); }
.brand:hover .brand-name { opacity: 1; transform: translateX(0); }

.nav-center { display: flex; align-items: center; gap: clamp(1.2rem, 2.4vw, 2.2rem); }
.nav-center a, .nav-dropdown-toggle {
  text-decoration: none; font-size: .9rem; font-weight: 500; color: var(--cream-soft);
  display: inline-flex; align-items: center; gap: .35rem; padding: .5rem 0; position: relative; white-space: nowrap;
  transition: color .3s var(--ease);
}
.nav-center a::after, .nav-dropdown-toggle::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: .1rem; height: 1px;
  background: var(--gold); transform: scaleX(0); transform-origin: left; transition: transform .4s var(--ease);
}
.nav-center a:hover, .nav-center a.active, .nav-dropdown-toggle:hover, .nav-dropdown-toggle[aria-expanded="true"], .nav-dropdown.has-active .nav-dropdown-toggle { color: var(--cream); }
.nav-center a:hover::after, .nav-center a.active::after, .nav-dropdown.has-active .nav-dropdown-toggle::after { transform: scaleX(1); }
.nav-dropdown-toggle svg { width: 14px; height: 14px; transition: transform .3s var(--ease); }
.nav-dropdown-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }

.nav-dropdown { position: relative; }
.nav-dropdown-menu {
  position: absolute; top: calc(100% + .4rem); left: -1rem; min-width: 190px;
  background: var(--wine-deep); border: 1px solid var(--line); border-radius: 8px;
  padding: .5rem; display: flex; flex-direction: column; gap: .1rem;
  box-shadow: var(--shadow);
  opacity: 0; transform: translateY(-6px); pointer-events: none; visibility: hidden;
  transition: opacity .3s var(--ease), transform .3s var(--ease), visibility 0s .3s;
}
.nav-dropdown.is-open .nav-dropdown-menu, .nav-dropdown:focus-within .nav-dropdown-menu { opacity: 1; transform: none; pointer-events: auto; visibility: visible; transition-delay: 0s; }
.nav-dropdown-menu a { padding: .6rem .9rem; border-radius: 5px; font-size: .85rem; }
.nav-dropdown-menu a::after { display: none; }
.nav-dropdown-menu a:hover, .nav-dropdown-menu a.active { background: var(--wine-lift); color: var(--gold-soft); }

.nav-right { display: flex; align-items: center; gap: .6rem; justify-self: end; }

.lang-switch { display: inline-flex; align-items: center; gap: .4rem; font-size: .78rem; font-weight: 600; letter-spacing: .06em; color: var(--cream-faint); margin-right: .4rem; }
.lang-switch svg { width: 16px; height: 16px; color: var(--gold); }
.lang-switch button { color: var(--cream-faint); padding: .3rem .15rem; transition: color .3s; }
.lang-switch button.active, .lang-switch button:hover { color: var(--cream); }
.lang-switch button.active { color: var(--gold-soft); }

.icon-button {
  display: inline-grid; place-items: center; position: relative;
  width: 40px; height: 40px; border-radius: 50%; color: var(--cream-soft);
  transition: background .3s var(--ease), color .3s var(--ease), transform .3s var(--ease);
}
.icon-button svg { width: 19px; height: 19px; }
.icon-button:hover, .icon-button[aria-expanded="true"] { background: rgba(243, 231, 214, .08); color: var(--gold-soft); }
.saved-dot { position: absolute; top: 8px; right: 8px; width: 7px; height: 7px; border-radius: 50%; background: var(--gold); }
.menu-toggle { display: none; }

.search-bar { padding: 0 clamp(1.2rem, 4vw, 3.5rem) 1rem; animation: fade-down .35s var(--ease); }
.search-field {
  display: flex; align-items: center; gap: .7rem; max-width: 620px; margin: 0 auto;
  border-bottom: 1px solid var(--line-strong); padding-bottom: .6rem;
}
.search-field svg { width: 18px; height: 18px; color: var(--gold); }
.search-field input { flex: 1; border: 0; background: none; outline: none; font-size: 1.05rem; font-family: var(--serif); color: var(--cream); }
.search-field input::placeholder { color: var(--cream-faint); font-style: italic; }
@keyframes fade-down { from { opacity: 0; transform: translateY(-6px); } }

/* ---------- Buttons ---------- */

.button {
  display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  padding: .9rem 1.6rem; border-radius: 999px; text-decoration: none;
  font-size: .85rem; font-weight: 600; letter-spacing: .03em; white-space: nowrap;
  border: 1px solid transparent; transition: all .35s var(--ease);
}
.button svg { width: 16px; height: 16px; }
.button-gold { background: var(--gold); color: var(--ink); }
.button-gold:hover { background: var(--gold-soft); transform: translateY(-2px); box-shadow: 0 16px 34px -18px rgba(212, 175, 106, .7); }
.button-outline { border-color: var(--line-strong); color: var(--cream); }
.button-outline:hover { border-color: var(--gold); color: var(--gold-soft); }
.button-ghost { background: rgba(243, 231, 214, .08); color: var(--cream); }
.button-ghost:hover { background: rgba(243, 231, 214, .14); }
.button-small { padding: .6rem 1.15rem; font-size: .78rem; }
.button-full { width: 100%; }
.button[disabled] { opacity: .5; cursor: not-allowed; transform: none !important; box-shadow: none !important; }

.text-button, .text-link { color: var(--gold-soft); font-weight: 600; font-size: .85rem; display: inline-flex; align-items: center; gap: .35rem; text-decoration: none; border-bottom: 1px solid transparent; transition: border-color .3s; white-space: nowrap; }
.text-button:hover, .text-link:hover { border-bottom-color: var(--gold-soft); }
.text-danger { color: var(--error); font-weight: 600; font-size: .82rem; }

/* ---------- Views ---------- */

.view { padding: clamp(1.5rem, 3vw, 2.5rem) clamp(1.2rem, 4vw, 3.5rem) 4rem; }

.grid-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 1.5rem; margin-bottom: clamp(1.4rem, 3vw, 2.2rem); }
.grid-heading h1 { font-size: clamp(2rem, 3.4vw, 3rem); }
.grid-count { margin: 0; font-family: var(--serif); font-style: italic; font-size: 1.05rem; color: var(--cream-faint); }

.dish-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 210px), 1fr));
  gap: clamp(1.4rem, 2.6vw, 2.4rem) clamp(1rem, 2vw, 1.8rem);
}

.dish-card { display: flex; flex-direction: column; gap: .75rem; min-width: 0; overflow: hidden; }
.card-open { display: block; width: 100%; text-align: left; border-radius: 10px; }
.card-image-wrap {
  position: relative; aspect-ratio: 1 / 1.22; border-radius: 10px; overflow: hidden;
  background: var(--wine-deep);
  box-shadow: 0 24px 40px -28px rgba(0, 0, 0, .9);
  transition: transform .6s var(--ease-out), box-shadow .6s var(--ease-out);
}
.dish-card:hover .card-image-wrap { transform: translateY(-6px); box-shadow: 0 34px 50px -26px rgba(0, 0, 0, .95); }
.card-image-wrap::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(74, 27, 38, 0) 55%, rgba(74, 27, 38, .45));
  mix-blend-mode: multiply;
}
.dish-image { width: 100%; height: 100%; object-fit: cover; opacity: 0; transform: scale(1.04); transition: opacity .6s var(--ease), transform 1s var(--ease-out); }
.dish-image.is-loaded { opacity: 1; transform: scale(1); }
.dish-card:hover .dish-image.is-loaded { transform: scale(1.05); }

.tag-unmissable {
  position: absolute; top: .55rem; right: .55rem; z-index: 2;
  display: inline-flex; align-items: center; gap: .2rem;
  background: rgba(31, 11, 16, .72); color: var(--gold-soft);
  backdrop-filter: blur(6px); border: 1px solid rgba(212, 175, 106, .4);
  font-size: .5rem; letter-spacing: .16em; text-transform: uppercase; font-weight: 700;
  padding: .22rem .4rem; border-radius: 999px;
}
.tag-unmissable svg { width: 9px; height: 9px; stroke-width: 2.4; }

.save-button {
  position: absolute; left: .6rem; bottom: .6rem; z-index: 2;
  width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(31, 11, 16, .55); color: var(--cream); backdrop-filter: blur(6px);
  opacity: 0; transform: translateY(6px); transition: all .35s var(--ease);
}
.save-button svg { width: 15px; height: 15px; }
.dish-card:hover .save-button, .save-button:focus-visible, .save-button.is-saved { opacity: 1; transform: none; }
.save-button.is-saved { color: var(--gold); }
.save-button.is-saved svg { fill: currentColor; }
.save-button:hover { background: rgba(31, 11, 16, .85); color: var(--gold-soft); }

.card-body { display: flex; flex-direction: column; justify-content: space-between; gap: .35rem; padding: 0 .15rem; min-height: 4.6rem; min-width: 0; }
.card-title { text-align: left; text-decoration: none; font-family: var(--sans); font-size: 1.05rem; font-weight: 600; line-height: 1.35; color: var(--cream); transition: color .3s; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-title:hover { color: var(--gold-soft); }
.card-meta {
  display: flex; align-items: center; justify-content: space-between; gap: .6rem;
  margin-top: auto; padding-top: .55rem; border-top: 1px solid var(--line);
  min-width: 0; flex-wrap: nowrap;
}
.card-rating { display: inline-flex; align-items: center; gap: .25rem; font-size: .72rem; color: var(--cream-faint); font-weight: 500; min-width: 0; max-width: 100%; }
.card-rating svg { width: 10px; height: 10px; color: var(--gold); fill: var(--gold); stroke: none; }
.card-rating-value { font-family: var(--serif); font-size: .9rem; color: var(--gold); line-height: 1; }
.card-rating-label { font-size: .62rem; letter-spacing: .02em; }
.card-rating .dot { margin: 0 .15rem; }
.card-rating .muted { color: var(--cream-faint); font-size: .62rem; }
.score-block {
  display: inline-flex; align-items: center; gap: .15rem;
  background: rgba(212, 175, 106, .08);
  border: 1px solid rgba(212, 175, 106, .45);
  color: var(--gold-soft);
  padding: .22rem .55rem; border-radius: 999px;
  font-size: .55rem; font-weight: 600; letter-spacing: .04em;
  min-width: 0; max-width: 100%;
}
.score-block .score-value {
  font-family: var(--serif); font-size: .95rem; font-weight: 400; line-height: 1; color: var(--gold);
}
.score-block .score-unit { text-transform: uppercase; font-size: .52rem; opacity: .8; }
.score-block .score-dot { opacity: .5; margin: 0 .08rem; }
.score-block .score-label { text-transform: uppercase; font-size: .52rem; opacity: .8; }

.skeleton {
  aspect-ratio: 1 / 1.26; border-radius: 10px;
  background: linear-gradient(100deg, rgba(243, 231, 214, .05) 35%, rgba(243, 231, 214, .11) 50%, rgba(243, 231, 214, .05) 65%);
  background-size: 220% 100%; animation: pulse-shimmer 1.6s ease-in-out infinite;
}
@keyframes pulse-shimmer { 0% { background-position: 120% 0; } 100% { background-position: -120% 0; } }

.grid-sentinel { grid-column: 1 / -1; height: 110px; border-radius: 10px; overflow: hidden; position: relative; }
.sentinel-shimmer { position: absolute; inset: 0; background: linear-gradient(100deg, rgba(243, 231, 214, .05) 35%, rgba(243, 231, 214, .11) 50%, rgba(243, 231, 214, .05) 65%); background-size: 220% 100%; animation: pulse-shimmer 1.6s ease-in-out infinite; }

/* ---------- Detail ---------- */

.detail { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.15fr); gap: clamp(2rem, 4vw, 4rem); align-items: start; max-width: 1380px; margin: 0 auto; }
.detail-back { display: inline-flex; align-items: center; gap: .5rem; font-size: .82rem; color: var(--cream-faint); text-decoration: none; margin-bottom: 1.4rem; transition: color .3s; }
.detail-back:hover { color: var(--gold-soft); }
.detail-back svg { width: 16px; height: 16px; }
.detail-visual { position: sticky; top: calc(var(--topbar-h) + 1.5rem); align-self: start; }
.detail-image-wrap { position: relative; border-radius: 14px; overflow: hidden; background: var(--wine-deep); box-shadow: var(--shadow); height: calc(100svh - var(--topbar-h) - 3rem); }
.detail-image { width: 100%; height: 100%; object-fit: cover; display: block; }
.detail-image-wrap::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(180deg, transparent 55%, rgba(31, 11, 16, .55)); mix-blend-mode: multiply; }
.detail-caption { position: absolute; left: 1.2rem; right: 1.2rem; bottom: 1rem; z-index: 2; display: flex; justify-content: space-between; font-size: .62rem; letter-spacing: .2em; text-transform: uppercase; color: var(--cream); font-weight: 700; text-shadow: 0 1px 4px rgba(0, 0, 0, .7); }
.detail-visual .tag-unmissable { top: 1rem; right: 1rem; }

.detail-content { padding-top: .5rem; }
.detail-title { font-size: clamp(2.4rem, 4.2vw, 3.8rem); margin: .2rem 0 .8rem; }
.detail-meta { display: flex; flex-wrap: wrap; gap: .5rem 1.2rem; font-size: .82rem; color: var(--cream-faint); margin-bottom: 1.4rem; }
.detail-meta span { display: inline-flex; align-items: center; gap: .4rem; }
.detail-meta svg { width: 14px; height: 14px; color: var(--gold); }
.detail-description { font-size: 1.05rem; line-height: 1.75; color: var(--cream-soft); margin: 0 0 2rem; }

.markdown-body { line-height: 1.7; color: var(--cream-soft); }
.markdown-body p { margin: 0 0 1rem; }
.markdown-body h2, .markdown-body h3, .markdown-body h4 { font-family: var(--serif); color: var(--cream); margin: 1.4rem 0 .6rem; }
.markdown-body h2 { font-size: 1.4rem; }
.markdown-body h3 { font-size: 1.2rem; }
.markdown-body h4 { font-size: 1.05rem; }
.markdown-body ul, .markdown-body ol { margin: 0 0 1rem 1.2rem; padding-left: 1.2rem; }
.markdown-body li { margin: .25rem 0; }
.markdown-body a { color: var(--gold-soft); text-decoration: none; border-bottom: 1px solid rgba(212, 175, 106, .35); padding-bottom: 1px; }
.markdown-body a:hover { color: var(--gold); border-bottom-color: var(--gold); }
.markdown-body code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; background: rgba(243, 231, 214, .08); padding: .1rem .35rem; border-radius: 4px; font-size: .9em; }
.markdown-body strong { color: var(--cream); font-weight: 600; }
.markdown-body em { color: var(--cream-faint); }
.venue-info .markdown-body { font-size: .9rem; line-height: 1.65; }

.score-panel {
  display: grid; grid-template-columns: auto 1fr; gap: 1.5rem; align-items: center;
  padding: 1.4rem 1.6rem; border-radius: 12px; background: rgba(31, 11, 16, .35); border: 1px solid var(--line); margin-bottom: 1.6rem;
}
.score-big { display: flex; align-items: baseline; gap: .3rem; }
.score-big strong { font-family: var(--serif); font-size: 3.6rem; line-height: 1; color: var(--gold-soft); font-weight: 400; }
.score-big small { font-size: .78rem; color: var(--cream-faint); }
.score-panel p { margin: 0; font-size: .82rem; color: var(--cream-faint); line-height: 1.6; }
.score-panel .eyebrow { margin-bottom: .3rem; }

.criteria-list { display: flex; flex-direction: column; gap: 1rem; margin-bottom: 2rem; }
.criterion-row { display: grid; gap: .45rem; }
.criterion-heading { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; font-size: .86rem; }
.criterion-heading span small { color: var(--cream-faint); font-size: .72rem; margin-left: .4rem; }
.criterion-heading strong { font-weight: 600; color: var(--cream); }
.criterion-track { height: 3px; background: rgba(243, 231, 214, .12); border-radius: 3px; overflow: hidden; }
.criterion-track span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--gold), var(--gold-soft)); border-radius: 3px; transition: width 1.1s var(--ease-out); }
.criterion-track span.is-visible { width: var(--w); }
.criterion-track span.is-time-good { background: linear-gradient(90deg, var(--time-good), #8f9f55); }
.criterion-track span.is-time-medium { background: linear-gradient(90deg, var(--time-medium), #d9b45a); }
.criterion-track span.is-time-bad { background: linear-gradient(90deg, var(--time-bad), #d96c45); }

.community-panel { border-top: 1px solid var(--line); padding-top: 1.6rem; margin-bottom: 1.6rem; }
.community-heading { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; }
.community-heading h3 { font-size: 1.6rem; }
.community-heading span { display: inline-flex; align-items: center; gap: .35rem; font-size: .8rem; color: var(--cream-faint); }
.community-heading svg { width: 13px; height: 13px; color: var(--gold); fill: var(--gold); stroke: none; }
.rating-stars { display: flex; gap: .2rem; margin: .9rem 0 .5rem; }
.rating-stars button { color: rgba(243, 231, 214, .22); padding: .15rem; transition: transform .25s var(--ease), color .25s; }
.rating-stars button svg { width: 30px; height: 30px; }
.rating-stars button:hover { transform: scale(1.15); color: var(--gold-soft); }
.rating-stars button.selected { color: var(--gold); }
.rating-stars button.selected svg { fill: var(--gold); stroke: var(--gold); }
.form-hint { font-size: .78rem; color: var(--cream-faint); margin: 0 0 1rem; line-height: 1.6; }

.detail-actions { display: flex; gap: .8rem; flex-wrap: wrap; margin-bottom: 2rem; }

.venue-card {
  display: grid; grid-template-columns: 74px 1fr auto; gap: 1.2rem; align-items: start;
  padding: 1.3rem 1.5rem; border-radius: 12px; background: rgba(243, 231, 214, .05); border: 1px solid var(--line);
}
.venue-logo { width: 74px; height: 74px; border-radius: 50%; overflow: hidden; background: var(--cream); display: grid; place-items: center; border: 2px solid rgba(212, 175, 106, .35); }
.venue-logo img { width: 100%; height: 100%; object-fit: cover; }
.venue-monogram { font-family: var(--serif); font-size: 2rem; color: var(--wine); }
.venue-info h3 { font-size: 1.5rem; }
.venue-info p { margin: .3rem 0 .5rem; font-size: .82rem; color: var(--cream-faint); line-height: 1.5; }
.venue-info .venue-meta { font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; color: var(--cream-faint); }
.venue-score { text-align: center; }
.venue-score strong { display: block; font-family: var(--serif); font-size: 2.3rem; line-height: 1; color: var(--gold-soft); font-weight: 400; }
.venue-score span { font-size: .58rem; letter-spacing: .16em; text-transform: uppercase; color: var(--cream-faint); }
.venue-card .button { grid-column: 1 / -1; justify-self: start; }
.venue-actions { grid-column: 1 / -1; display: flex; gap: .6rem; flex-wrap: wrap; }

.venue-branches { margin-top: 1.2rem; padding-top: 1rem; border-top: 1px solid var(--line); }
.branch-list { list-style: none; display: flex; flex-direction: column; gap: .55rem; }
.branch-item { display: flex; flex-wrap: wrap; align-items: baseline; gap: .4rem .7rem; font-size: .82rem; color: var(--cream-faint); }
.branch-name { color: var(--cream); }
.branch-current { color: var(--gold-soft); font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; }
.branch-address { color: var(--cream-faint); }
.branch-atmosphere { width: 100%; font-size: .78rem; font-style: italic; color: var(--cream-soft); line-height: 1.5; }
.branch-maps { color: var(--gold); font-size: .78rem; text-decoration: none; }
.branch-maps:hover { text-decoration: underline; }

.venue-note-date { font-size: .82rem; color: var(--cream-faint); margin: -.2rem 0 1.2rem; }

.related { margin-top: 3.5rem; max-width: 1380px; margin-inline: auto; }
.related h2 { font-size: 1.8rem; margin-bottom: 1.4rem; }

/* ---------- Status / empty art ---------- */

.status-view { min-height: calc(100svh - var(--topbar-h) - 8rem); display: grid; place-items: center; text-align: center; }
.status-inner { max-width: 520px; display: flex; flex-direction: column; align-items: center; }
.status-art { width: clamp(180px, 34vw, 260px); height: auto; margin-bottom: 2rem; color: var(--gold); }
.status-art svg { width: 100%; height: auto; stroke-width: 1.4; }
.status-art .art-mark { stroke-width: 2.2; }
.status-view h2 { font-size: clamp(2rem, 4vw, 3rem); margin-bottom: .9rem; }
.status-view p { color: var(--cream-soft); line-height: 1.7; margin: 0 0 1.8rem; }

.art-canvas .frame { animation: breathe 6s ease-in-out infinite; transform-origin: center; }
.art-canvas .brush { stroke-dasharray: 220; stroke-dashoffset: 220; animation: draw 3.5s var(--ease) forwards .4s; }
.art-door .light { animation: glow 4s ease-in-out infinite; }
.art-kintsugi .crack { stroke: var(--gold-soft); stroke-dasharray: 160; stroke-dashoffset: 160; animation: draw 2.8s var(--ease) forwards .3s; filter: drop-shadow(0 0 6px rgba(212, 175, 106, .6)); }
.art-empty .steam { stroke-dasharray: 6 8; animation: rise 3s linear infinite; opacity: .7; }
.art-empty .steam:nth-child(2) { animation-delay: 1s; }
.art-empty .steam:nth-child(3) { animation-delay: 2s; }
.art-empty .brush-hand { animation: sweep 4s ease-in-out infinite; transform-origin: 70% 90%; }
@keyframes breathe { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.02); } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes glow { 0%, 100% { opacity: .35; } 50% { opacity: .9; } }
@keyframes rise { to { stroke-dashoffset: -28; } }
@keyframes sweep { 0%, 100% { transform: rotate(-6deg); } 50% { transform: rotate(6deg); } }

.grid-empty { grid-column: 1 / -1; }

/* ---------- Profile ---------- */

.page-heading { display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem; flex-wrap: wrap; margin-bottom: 2rem; }
.page-heading h1 { font-size: clamp(2.2rem, 4vw, 3.4rem); margin-bottom: .5rem; }
.page-heading p { margin: 0; color: var(--cream-faint); }
.profile-stats { display: flex; gap: 2.5rem; margin-bottom: 1.8rem; }
.profile-stat strong { display: block; font-family: var(--serif); font-size: 2.6rem; line-height: 1; color: var(--gold-soft); font-weight: 400; }
.profile-stat span { font-size: .68rem; letter-spacing: .16em; text-transform: uppercase; color: var(--cream-faint); }
.tabs { display: flex; gap: 1.6rem; border-bottom: 1px solid var(--line); margin-bottom: 2rem; }
.tabs button { padding: .7rem 0; font-size: .82rem; letter-spacing: .1em; text-transform: uppercase; color: var(--cream-faint); border-bottom: 2px solid transparent; margin-bottom: -1px; transition: color .3s; }
.tabs button.active { color: var(--gold-soft); border-bottom-color: var(--gold); font-weight: 600; }

/* ---------- Footer ---------- */

.site-footer {
  display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
  padding: 1.4rem clamp(1.2rem, 4vw, 3.5rem); border-top: 1px solid var(--line);
  font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--cream-faint);
  padding-left: 5rem;
}
.footer-links { display: flex; gap: 1.4rem; }
.footer-links a, .footer-links .text-button { color: var(--cream-faint); text-decoration: none; font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; font-weight: 500; }
.footer-links a:hover, .footer-links .text-button:hover { color: var(--gold-soft); }

/* ---------- Dialogs ---------- */

dialog { border: 0; padding: 0; background: transparent; max-width: none; max-height: none; color: var(--cream); }
dialog::backdrop { background: rgba(31, 11, 16, .7); backdrop-filter: blur(8px); }
dialog[open] { animation: dialog-in .45s var(--ease-out); }
@keyframes dialog-in { from { opacity: 0; transform: translateY(18px) scale(.98); } }
.dialog { position: fixed; top: 0; right: 0; bottom: var(--kb, 0px); left: 0; margin: auto; background: var(--wine-deep); border: 1px solid var(--line); border-radius: 14px; width: min(460px, calc(100vw - 2rem)); max-height: calc(var(--vv-height, 100dvh) - 2rem); padding: 2.6rem 2.4rem 2.2rem; overflow-y: auto; overscroll-behavior: contain; box-shadow: var(--shadow); }
.info-dialog { width: min(560px, calc(100vw - 2rem)); }
.info-dialog h2 { font-size: 2.2rem; margin-bottom: 1rem; }
.info-dialog p { color: var(--cream-soft); line-height: 1.7; margin: 0 0 1rem; font-size: .92rem; }
.dialog-close { position: absolute; top: .9rem; right: .9rem; }
.dialog-mark { width: 40px; height: 40px; color: var(--gold); margin-bottom: .6rem; }
.auth-dialog h2 { font-size: 2.2rem; margin-bottom: .4rem; }
.dialog-description { color: var(--cream-faint); margin: 0 0 1.5rem; font-size: .9rem; }
.auth-tabs { display: flex; border-bottom: 1px solid var(--line); margin-bottom: 1.5rem; }
.auth-tabs button { flex: 1; padding: .75rem; font-size: .82rem; letter-spacing: .06em; color: var(--cream-faint); border-bottom: 2px solid transparent; margin-bottom: -1px; transition: color .3s, border-color .3s; }
.auth-tabs button.active { color: var(--gold-soft); border-bottom-color: var(--gold); font-weight: 600; }

#auth-form label, .admin-form label { display: flex; flex-direction: column; gap: .4rem; margin-bottom: 1rem; font-size: .76rem; font-weight: 600; letter-spacing: .04em; color: var(--cream-soft); }
#auth-form input, .admin-form input, .admin-form select, .admin-form textarea {
  border: 1px solid var(--line-strong); border-radius: 8px; background: rgba(31, 11, 16, .4);
  padding: .75rem .95rem; font-size: .92rem; font-weight: 400; width: 100%; color: var(--cream);
  transition: border-color .3s, box-shadow .3s;
}
.admin-form select option { background: var(--wine-deep); }
#auth-form input:focus, .admin-form input:focus, .admin-form select:focus, .admin-form textarea:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(212, 175, 106, .18); }
#auth-form input.is-invalid, .admin-form input.is-invalid, .admin-form select.is-invalid, .admin-form textarea.is-invalid { border-color: var(--error); box-shadow: 0 0 0 3px rgba(224, 108, 117, .18); }
#auth-form input.is-invalid:focus, .admin-form input.is-invalid:focus, .admin-form select.is-invalid:focus, .admin-form textarea.is-invalid:focus { border-color: var(--error); box-shadow: 0 0 0 3px rgba(224, 108, 117, .25); }
.form-error { font-size: .82rem; color: var(--error); margin: 0 0 1rem; min-height: 1.2em; font-weight: 500; }
.form-error:not(:empty) { padding: .55rem .9rem; border-radius: 6px; border-left: 3px solid var(--error); background: rgba(224, 108, 117, .1); }
.form-error.is-success { color: var(--gold-soft); border-left-color: var(--gold); background: rgba(212, 175, 106, .1); }
.template-meta { margin: 0 0 1.2rem; }
.template-desc { font-size: .84rem; color: var(--cream-faint); line-height: 1.5; margin: .6rem 0 0; }
.template-vars { margin: 1.2rem 0 .6rem; }
.template-vars-title { font-size: .82rem; font-weight: 600; color: var(--cream-soft); margin: 0 0 .4rem; letter-spacing: .03em; }
.var-pills { display: flex; flex-wrap: wrap; gap: .5rem; }
.var-pill { display: inline-flex; align-items: center; gap: .3rem; padding: .35rem .7rem; border-radius: 999px; border: 1px solid var(--line); background: rgba(31, 11, 16, .35); color: var(--gold-soft); font-size: .78rem; cursor: pointer; transition: background .2s, border-color .2s; }
.var-pill:hover { background: rgba(212, 175, 106, .12); border-color: var(--gold); color: var(--gold); }
.template-help { margin: .4rem 0 .8rem; }
.email-vars-help { list-style: none; padding: 0; margin: 1rem 0 0; display: grid; gap: .7rem; }
.email-vars-help li { display: flex; align-items: center; gap: .7rem; font-size: .9rem; color: var(--cream-soft); }
.email-vars-help code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; background: rgba(31, 11, 16, .5); padding: .2rem .5rem; border-radius: 6px; color: var(--gold-soft); font-size: .82rem; border: 1px solid var(--line); }
.email-preview { margin-top: 1.4rem; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: rgba(31, 11, 16, .25); }
.email-preview-frame { max-width: 100%; overflow: auto; padding: 1rem; }
.auth-privacy { text-align: center; margin-top: 1rem; }
.auth-terms-step { display: block; text-align: left; margin-top: .4rem; width: 100%; }
.auth-terms-step > * { margin: 0 0 1rem; }
.auth-terms-step > *:last-child { margin-bottom: 0; }
.auth-terms-step h3 { font-size: 1.55rem; line-height: 1.15; white-space: normal; overflow-wrap: break-word; word-break: break-word; }
.auth-terms-step .auth-terms-body { font-size: .9rem; line-height: 1.6; color: var(--cream); }
.auth-terms-step .form-hint { text-align: left; }
.auth-terms-step .button-full { display: block; width: 100%; white-space: normal; text-align: center; }
.auth-terms-step .button-full + .button-full { margin-top: 1rem; }
.auth-forgot { text-align: center; margin-top: 1.2rem; }
.auth-forgot .text-button { font-size: .82rem; }

/* ---------- Admin ---------- */

.admin-topbar { display: flex; justify-content: space-between; align-items: flex-end; gap: 1.5rem; flex-wrap: wrap; margin-bottom: 1.8rem; }
.admin-actions { display: flex; gap: .7rem; align-items: center; flex-wrap: wrap; }
.admin-tabs { display: flex; gap: .4rem; flex-wrap: wrap; margin-bottom: 1.8rem; padding: .35rem; border-radius: 999px; background: rgba(31, 11, 16, .35); border: 1px solid var(--line); width: fit-content; }
.admin-tabs button { display: inline-flex; align-items: center; gap: .5rem; padding: .6rem 1.1rem; border-radius: 999px; font-size: .82rem; font-weight: 600; color: var(--cream-faint); transition: all .3s var(--ease); }
.admin-tabs button svg { width: 15px; height: 15px; }
.admin-tabs button:hover { color: var(--cream); }
.admin-tabs button.active { background: var(--gold); color: var(--ink); }

.admin-stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 1rem; margin-bottom: 1.8rem; }
.admin-stat { padding: 1.3rem 1.4rem; border-radius: 12px; background: rgba(243, 231, 214, .05); border: 1px solid var(--line); }
.admin-stat strong { display: block; font-family: var(--serif); font-size: 2.4rem; line-height: 1; color: var(--gold-soft); font-weight: 400; }
.admin-stat span { font-size: .66rem; letter-spacing: .14em; text-transform: uppercase; color: var(--cream-faint); }

.admin-panel { padding: 1.8rem; border-radius: 14px; background: rgba(31, 11, 16, .32); border: 1px solid var(--line); margin-bottom: 1.4rem; }
.panel-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 1.5rem; flex-wrap: wrap; margin-bottom: 1.4rem; }
.panel-heading h2 { font-size: 1.8rem; }
.panel-heading p { margin: .3rem 0 0; font-size: .82rem; color: var(--cream-faint); }

.admin-toolbar { display: flex; gap: 1rem; flex-wrap: wrap; align-items: center; margin-bottom: 1.3rem; }
.admin-toolbar .search-field { flex: 1 1 240px; margin: 0; max-width: none; }
.admin-toolbar select { border: 1px solid var(--line-strong); border-radius: 999px; background: var(--wine-deep); padding: .5rem 1.6rem .5rem .9rem; font-size: .82rem; }
.admin-toolbar .count { font-size: .78rem; color: var(--cream-faint); }

.admin-table-wrap { overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; font-size: .86rem; }
.admin-table th { text-align: left; font-size: .64rem; letter-spacing: .16em; text-transform: uppercase; color: var(--cream-faint); font-weight: 600; padding: .7rem .8rem; border-bottom: 1px solid var(--line-strong); }
.admin-table td { padding: .85rem .8rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
.admin-table tr:last-child td { border-bottom: 0; }
.table-dish { display: flex; align-items: center; gap: .9rem; min-width: 220px; }
.table-dish img, .table-dish .venue-monogram-box { width: 50px; height: 50px; border-radius: 8px; object-fit: cover; flex: none; }
.venue-monogram-box { display: grid; place-items: center; background: var(--cream); color: var(--wine); font-family: var(--serif); font-size: 1.4rem; }
.table-dish strong { display: block; font-weight: 500; }
.table-dish small { color: var(--cream-faint); font-size: .74rem; }
.score-cell { font-family: var(--serif); font-size: 1.3rem; color: var(--gold-soft); }
.status-badge { display: inline-block; font-size: .6rem; letter-spacing: .16em; text-transform: uppercase; font-weight: 700; padding: .35rem .65rem; border-radius: 999px; background: rgba(243, 231, 214, .08); color: var(--cream-soft); }
.status-badge.is-gold { background: rgba(212, 175, 106, .16); color: var(--gold-soft); }
.table-actions { display: flex; gap: .3rem; justify-content: flex-end; }
.table-actions .icon-button { width: 34px; height: 34px; }
.table-actions svg { width: 15px; height: 15px; }

.admin-form .form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 1.3rem; }
.admin-form .form-grid.three-cols { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.field-full { grid-column: 1 / -1; }
.admin-form textarea { min-height: 110px; resize: vertical; }
.form-section-title { font-family: var(--serif); font-size: 1.45rem; margin: 1.6rem 0 .9rem; padding-top: 1.3rem; border-top: 1px solid var(--line); }
.form-section-title:first-child { border-top: 0; padding-top: 0; margin-top: 0; }
.form-actions { display: flex; gap: 1rem; align-items: center; margin-top: 1.5rem; flex-wrap: wrap; }
.check-label { display: inline-flex !important; flex-direction: row !important; align-items: center; gap: .6rem; font-weight: 500 !important; cursor: pointer; }
.check-label input { width: 16px !important; height: 16px; accent-color: var(--gold); padding: 0 !important; }

.upload-field { display: flex; flex-direction: column; gap: .6rem; }
.upload-preview { width: 100%; max-width: 320px; aspect-ratio: 1; border-radius: 12px; overflow: hidden; border: 1px dashed var(--line-strong); background: rgba(31, 11, 16, .3); display: grid; place-items: center; color: var(--cream-faint); font-size: .8rem; }
.upload-preview img { width: 100%; height: 100%; object-fit: cover; }
.upload-preview.is-logo { max-width: 160px; background: var(--cream); }
.upload-field input[type="file"] { font-size: .8rem; color: var(--cream-soft); }
.upload-field input[type="file"]::file-selector-button { font: inherit; border: 1px solid var(--line-strong); background: transparent; color: var(--cream); border-radius: 999px; padding: .45rem 1rem; margin-right: .8rem; cursor: pointer; }

.criteria-input-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1rem; }
.criteria-input-grid label small { display: block; color: var(--cream-faint); font-weight: 400; margin-top: .15rem; }
.criterion-editor { border: 1px solid var(--line); border-radius: 12px; padding: 1.2rem 1.3rem; margin: 0 0 1.2rem; }
.criterion-editor legend { font-family: var(--serif); font-size: 1.25rem; padding: 0 .5rem; color: var(--gold-soft); }
.admin-alert { padding: 1.1rem 1.3rem; border-radius: 12px; background: rgba(212, 175, 106, .1); border: 1px solid rgba(212, 175, 106, .3); font-size: .84rem; color: var(--cream-soft); line-height: 1.6; margin-bottom: 1.5rem; }
.admin-alert strong { display: block; color: var(--gold-soft); margin-bottom: .3rem; }
.admin-empty { padding: 2.5rem 1rem; text-align: center; color: var(--cream-faint); }
.admin-empty h3 { font-size: 1.5rem; margin-bottom: .4rem; color: var(--cream); }

/* ---------- Toast ---------- */

.toast {
  position: fixed; bottom: calc(1.6rem + env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%);
  background: var(--cream); color: var(--ink); padding: .9rem 1.6rem; border-radius: 999px; font-size: .86rem; font-weight: 500;
  box-shadow: var(--shadow); z-index: 300; animation: toast-in .4s var(--ease-out); max-width: calc(100vw - 2rem); text-align: center;
}
.toast.is-error { background: #c9524a; color: var(--cream); }
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, 12px); } }
.noscript-notice { position: fixed; inset: auto 0 0; background: var(--gold); color: var(--ink); padding: 1rem; text-align: center; z-index: 400; font-size: .9rem; }

.scroll-fab {
  position: fixed; right: 1.6rem; bottom: calc(1.6rem + env(safe-area-inset-bottom));
  z-index: 80;
  width: 54px; height: 54px; border-radius: 50%;
  display: inline-grid; place-items: center;
  background: var(--gold); color: var(--ink);
  box-shadow: 0 14px 34px -14px rgba(0, 0, 0, .8);
  transition: transform .35s var(--ease), background .3s, opacity .3s;
}
.scroll-fab[hidden] { display: none !important; }
.scroll-fab svg { width: 26px; height: 26px; stroke-width: 2; }
.scroll-fab:hover { transform: translateY(-3px) scale(1.06); background: var(--gold-soft); }

.music-player {
  position: fixed; left: 1.6rem; bottom: calc(1.6rem + env(safe-area-inset-bottom));
  z-index: 80;
  display: flex; flex-direction: column-reverse; align-items: flex-start;
  gap: .6rem;
  color: var(--cream);
  transition: bottom .2s var(--ease);
}
.music-player[hidden] { display: none !important; }
.music-player.is-empty .music-tab { opacity: .55; }
.music-tab {
  width: 48px; height: 48px; border-radius: 12px;
  display: inline-grid; place-items: center;
  background: rgba(31, 11, 16, .9);
  border: 1px solid var(--line);
  backdrop-filter: blur(12px);
  color: var(--gold);
  box-shadow: 0 14px 34px -14px rgba(0, 0, 0, .8);
  transition: color .25s, background .25s, transform .25s var(--ease);
}
.music-tab:hover { color: var(--gold-soft); background: rgba(51, 18, 27, .95); }
.music-tab svg { width: 22px; height: 22px; }
.music-tab.is-playing { color: var(--gold-soft); border-color: rgba(212, 175, 106, .55); animation: music-pulse 2.2s ease-in-out infinite; }
.music-tab.is-playing svg { animation: music-sway 2.2s ease-in-out infinite; transform-origin: 50% 20%; }
@keyframes music-pulse {
  0%, 100% { box-shadow: 0 14px 34px -14px rgba(0, 0, 0, .8), 0 0 0 0 rgba(212, 175, 106, .35); }
  50% { box-shadow: 0 14px 34px -14px rgba(0, 0, 0, .8), 0 0 0 7px rgba(212, 175, 106, 0); }
}
@keyframes music-sway {
  0%, 100% { transform: rotate(-7deg); }
  50% { transform: rotate(7deg); }
}
.music-body {
  display: none;
  width: 240px; padding: .85rem 1rem;
  border-radius: 16px;
  background: rgba(31, 11, 16, .9);
  border: 1px solid var(--line);
  backdrop-filter: blur(12px);
  box-shadow: 0 14px 34px -14px rgba(0, 0, 0, .8);
}
.music-player.is-open .music-body { display: block; }
.music-track {
  font-size: .78rem; font-weight: 500; color: var(--cream-soft);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  margin-bottom: .7rem; text-align: center;
}
.music-player.is-empty .music-track { color: var(--cream-faint); font-style: italic; }
.music-controls { display: flex; align-items: center; justify-content: center; gap: .15rem; }
.music-button {
  display: inline-grid; place-items: center;
  width: 36px; height: 36px; border-radius: 50%;
  color: var(--cream-soft);
  transition: color .25s, background .25s, transform .25s var(--ease);
}
.music-button:hover:not(:disabled) { color: var(--gold-soft); background: rgba(243, 231, 214, .08); }
.music-button:disabled { color: var(--cream-faint); opacity: .45; cursor: not-allowed; }
.music-button svg { width: 18px; height: 18px; }
#music-play { color: var(--gold); }
#music-play:disabled { color: var(--cream-faint); opacity: .45; }
#music-play svg { width: 22px; height: 22px; }
#music-play.is-playing svg { fill: currentColor; }
.music-progress {
  height: 2px; margin-top: .7rem;
  background: rgba(243, 231, 214, .12); border-radius: 2px; overflow: hidden;
}
.music-progress span { display: block; height: 100%; width: 0; background: var(--gold); border-radius: 2px; transition: width .2s linear; }

.chat-fab {
  position: fixed; right: 1.6rem; bottom: calc(6.8rem + env(safe-area-inset-bottom));
  z-index: 90;
  width: 46px; height: 46px;
  border-radius: 50%;
  background: rgba(31, 11, 16, .78);
  border: 1px solid var(--gold);
  color: var(--gold);
  backdrop-filter: blur(12px);
  display: inline-grid; place-items: center;
  box-shadow: 0 10px 30px -12px rgba(0, 0, 0, .8);
  transition: transform .3s var(--ease), box-shadow .3s, background .3s, color .3s;
}
.chat-fab:hover { transform: scale(1.06); background: rgba(74, 27, 38, .9); box-shadow: 0 14px 36px -10px rgba(0, 0, 0, .85); }
.chat-fab svg { width: 20px; height: 20px; }

.chat-dialog {
  position: fixed;
  left: 50%; top: 50%;
  right: auto; bottom: auto;
  z-index: 200;
  margin: 0;
  width: min(360px, calc(100vw - 2rem));
  max-height: min(520px, calc(100dvh - 2rem));
  border-radius: 18px;
  background: rgba(31, 11, 16, .96);
  border: 1px solid var(--line);
  backdrop-filter: blur(18px);
  color: var(--cream);
  padding: 0;
  overflow: hidden;
  box-shadow: 0 20px 60px -18px rgba(0, 0, 0, .9);
  transform: translate(calc(-50% + var(--dx, 0px)), calc(-50% + var(--dy, 0px)));
}
.chat-dialog[open] {
  display: flex; flex-direction: column;
}
.chat-dialog::backdrop { background: transparent; }

.map-dialog { width: min(900px, calc(100vw - 2rem)); padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.map-header { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .85rem 1rem; border-bottom: 1px solid var(--line); flex: none; }
.map-header h2 { margin: 0; font-size: 1.05rem; color: var(--gold); font-weight: 600; }
.map-header .icon-button { width: 34px; height: 34px; color: var(--cream-soft); }
.map-header .icon-button:hover { color: var(--gold); }
#map-iframe { width: 100%; height: min(55dvh, 500px); border: 0; display: block; flex: 0 1 auto; }
.map-fallback { padding: .8rem 1rem; border-top: 1px solid var(--line); display: flex; justify-content: flex-end; flex: none; }
.map-fallback { padding: .8rem 1rem; border-top: 1px solid var(--line); display: flex; justify-content: flex-end; }
.chat-dialog.is-minimized { width: min(240px, calc(100vw - 2rem)); height: auto; max-height: unset; }
.chat-dialog.is-minimized .chat-messages,
.chat-dialog.is-minimized .chat-form { display: none; }
.chat-dialog.is-minimized .chat-header { border-bottom: none; cursor: pointer; }

.chat-header {
  display: flex; align-items: center; gap: .6rem;
  padding: .85rem 1rem;
  border-bottom: 1px solid var(--line);
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
}
.chat-header h2 { flex: 1; margin: 0; font-size: 1.05rem; color: var(--gold); font-weight: 600; }
.chat-header-actions { display: flex; align-items: center; gap: .15rem; }
.chat-header .icon-button { width: 34px; height: 34px; color: var(--cream-soft); }
.chat-header .icon-button:hover { color: var(--gold); }
.chat-header .icon-button.chat-location.active { color: var(--gold); }
.chat-header .icon-button.chat-location.denied { color: var(--error); }
.chat-header .icon-button.chat-location.unavailable { color: var(--cream-faint); }
.chat-header .icon-button.chat-location.active::after,
.chat-header .icon-button.chat-location.prompt::after {
  content: ''; position: absolute; top: 6px; right: 6px; width: 5px; height: 5px; border-radius: 50%;
}
.chat-header .icon-button.chat-location.active::after { background: var(--gold); }
.chat-header .icon-button.chat-location.prompt::after { background: var(--cream); animation: pulse 1.6s ease-in-out infinite; }
.chat-header .icon-button { position: relative; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
.chat-header:active { cursor: grabbing; }

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 1rem 1.2rem;
  display: flex; flex-direction: column; gap: .8rem;
}
.chat-message {
  max-width: 88%;
  padding: .75rem 1rem;
  border-radius: 14px;
  font-size: .95rem; line-height: 1.55;
  animation: fadeUp .35s var(--ease);
}
.chat-message p { margin: 0; }
.chat-message p + p { margin-top: .5rem; }
.chat-message.user { align-self: flex-end; background: var(--gold-soft); color: var(--wine); }
.chat-message.agent { align-self: flex-start; background: rgba(243, 231, 214, .08); color: var(--cream); }
.chat-message.typing { display: flex; gap: .35rem; align-items: center; }
.chat-dot { width: 6px; height: 6px; background: var(--gold); border-radius: 50%; animation: typing 1.2s infinite; }
.chat-dot:nth-child(2) { animation-delay: .2s; }
.chat-dot:nth-child(3) { animation-delay: .4s; }

.chat-cards { display: grid; gap: .6rem; margin-top: .8rem; }
.chat-card {
  display: flex; align-items: center; gap: .7rem;
  padding: .5rem;
  background: rgba(74, 27, 38, .6);
  border: 1px solid var(--line);
  border-radius: 10px;
  cursor: pointer;
  transition: transform .2s, border-color .2s;
}
.chat-card:hover { border-color: var(--gold); transform: translateY(-2px); }
.chat-card, .chat-card:hover { text-decoration: none; color: var(--cream); }
.chat-card img { width: 48px; height: 48px; object-fit: cover; border-radius: 6px; }
.chat-card span { display: block; }
.chat-card .chat-card-title { font-weight: 600; color: var(--cream); }
.chat-card .chat-card-meta { font-size: .78rem; color: var(--cream-soft); }

.chat-form {
  display: flex; align-items: center; gap: .5rem;
  padding: .8rem 1.2rem 1.2rem;
  border-top: 1px solid var(--line);
}
.chat-input {
  flex: 1;
  padding: .75rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(243, 231, 214, .06);
  color: var(--cream);
  font-size: .95rem;
}
.chat-input::placeholder { color: var(--cream-soft); opacity: .6; }
.chat-input:focus { outline: none; border-color: var(--gold); background: rgba(243, 231, 214, .1); }
.chat-send {
  width: 44px; height: 44px; padding: 0; border-radius: 50%;
  display: inline-grid; place-items: center;
}
.chat-send svg { width: 18px; height: 18px; }

@keyframes typing {
  0%, 80%, 100% { transform: translateY(0); opacity: .4; }
  40% { transform: translateY(-4px); opacity: 1; }
}

/* ---------- View transitions ---------- */

::view-transition-old(root), ::view-transition-new(root) { animation-duration: .45s; animation-timing-function: var(--ease-out); }
::view-transition-old(dish-hero), ::view-transition-new(dish-hero) { animation-duration: .6s; animation-timing-function: var(--ease-out); mix-blend-mode: normal; }
::view-transition-group(dish-hero) { animation-duration: .6s; animation-timing-function: var(--ease-out); }
.view-enter { animation: view-in .5s var(--ease-out); }
@keyframes view-in { from { opacity: 0; transform: translateY(10px); } }

/* ---------- Email preview ---------- */

.email-preview { margin-top: 1.5rem; padding: 1.4rem; border-radius: 14px; background: rgba(31, 11, 16, .32); border: 1px solid var(--line); }
.email-preview-frame { background: var(--cream); color: var(--ink); border-radius: 10px; overflow: hidden; }
.email-preview-frame > div { padding: 1.5rem; }

/* ---------- Responsive ---------- */

@media (max-width: 1080px) {
  .detail { grid-template-columns: 1fr; }
  .detail-visual { position: static; align-self: auto; }
  .detail-image-wrap { display: block; height: auto; aspect-ratio: 4 / 3; max-height: 62vh; }
  .detail-image { width: 100%; height: 100%; max-height: 62vh; object-fit: cover; }
  .venue-card { grid-template-columns: 64px 1fr; }
  .venue-score { grid-column: 2; text-align: left; }
  .venue-score strong { display: inline; margin-right: .5rem; font-size: 1.8rem; }
}

@media (max-width: 860px) {
  :root { --topbar-h: 68px; }
  .topbar-inner { display: flex; justify-content: space-between; align-items: center; height: var(--topbar-h); padding: 0 1rem; gap: .5rem; }
  .brand-mark { width: 40px; height: 40px; }
  .brand { max-width: calc(100vw - 170px); overflow: hidden; }
  .brand-name {
    position: static; display: inline-block; vertical-align: middle;
    opacity: 1; transform: none; padding-left: .45rem; pointer-events: auto;
    font-size: .92rem; max-width: 100%;
    overflow: hidden; text-overflow: ellipsis;
  }
  .nav-center {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    padding: .5rem 1.2rem 1.2rem; background: var(--wine-deep); border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    animation: fade-down .3s var(--ease);
  }
  .nav-center.is-open { display: flex; }
  .nav-center a, .nav-dropdown-toggle { padding: .85rem 0; font-size: 1rem; width: 100%; justify-content: space-between; }
  .nav-center a::after, .nav-dropdown-toggle::after { display: none; }
  .nav-dropdown-menu { position: static; opacity: 1; transform: none; visibility: visible; pointer-events: auto; background: transparent; border: 0; box-shadow: none; padding: 0 0 .4rem 1rem; display: none; }
  .nav-dropdown.is-open .nav-dropdown-menu { display: flex; }
  .nav-right { gap: .1rem; }
  .icon-button { width: 38px; height: 38px; }
  .lang-switch { font-size: .74rem; gap: .3rem; }
  .lang-switch svg { display: none; }
  .menu-toggle { display: inline-grid; }
  .lang-switch { margin-right: 0; }
  .view { padding: 1.4rem 1.1rem calc(10.5rem + env(safe-area-inset-bottom)); }
  .grid-heading { flex-direction: column; align-items: flex-start; gap: .4rem; }
  .dish-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.4rem .9rem; }
  .save-button { opacity: 1; transform: none; }
  .detail-title { font-size: 2.2rem; }
  .score-panel { grid-template-columns: 1fr; gap: .8rem; }
  .dialog { padding: 2.2rem 1.3rem 1.8rem; }
  .admin-form .form-grid, .admin-form .form-grid.three-cols { grid-template-columns: 1fr; }
  .admin-tabs { width: 100%; }
  .site-footer { flex-direction: column; align-items: flex-start; padding-left: 4rem; }
  .footer-links { flex-wrap: wrap; gap: .8rem 1.2rem; }
  .scroll-fab { right: 1rem; bottom: calc(1rem + env(safe-area-inset-bottom)); width: 48px; height: 48px; }
  .scroll-fab svg { width: 22px; height: 22px; }
  .music-player { left: 1rem; bottom: calc(1rem + env(safe-area-inset-bottom)); }
  .music-body { width: min(210px, calc(100vw - 2rem)); padding: .75rem .85rem; }
  .music-button { width: 32px; height: 32px; }
  .chat-fab { right: 1rem; bottom: calc(5.8rem + env(safe-area-inset-bottom)); width: 42px; height: 42px; }
  .chat-fab svg { width: 18px; height: 18px; }
  .chat-dialog {
    left: 0; right: 0; top: auto; bottom: var(--kb, 0px);
    width: auto; max-width: none; margin: 0;
    border-radius: 18px 18px 0 0;
    transform: none;
    max-height: min(75svh, calc(var(--vvh, 100dvh) - 1rem));
    transition: max-height .25s var(--ease);
  }
  .chat-dialog.is-minimized { width: auto; max-height: none; border-radius: 18px 18px 0 0; }
  .chat-form { padding-bottom: calc(1.2rem + env(safe-area-inset-bottom)); }
}

@media (max-width: 420px) {
  .dish-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.2rem .7rem; }
  .card-title { font-size: .86rem; }
  .card-meta { flex-wrap: wrap; gap: .35rem .5rem; }
  .score-block { margin-left: auto; padding: .18rem .4rem; font-size: .48rem; gap: .1rem; }
  .score-block .score-value { font-size: .8rem; }
  .score-block .score-unit, .score-block .score-label { font-size: .45rem; }
  .card-rating { font-size: .65rem; gap: .15rem; }
  .card-rating-value { font-size: .78rem; }
  .card-rating-label { font-size: .55rem; }
  .card-rating svg { width: 9px; height: 9px; }
  .auth-terms-step h3 { font-size: 1.6rem; }
  .auth-terms-step .eyebrow { font-size: .6rem; }
  .check-label { gap: .35rem; }
}

@media (pointer: coarse) {
  .search-field input,
  .chat-input,
  #auth-form input,
  .admin-form input, .admin-form select, .admin-form textarea { font-size: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
}
