/* ============ Видео-меню «Тарелка» — экран 1920×1080 ============ */
:root {
  --red: #E3151E;
  --red-deep: #B00C14;
  --yellow: #FFC61A;
  --yellow-hi: #FFE066;
  --cream: #FFF7E3;
  --ink: #2B1708;
  --display: 'Unbounded', 'Arial Black', sans-serif;
  --text: 'Manrope', 'Segoe UI', Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { width: 100%; height: 100%; overflow: hidden; }
body { background: var(--page-bg, #FFC61A); font-family: var(--text); -webkit-font-smoothing: antialiased; cursor: none; }

/* ---------- темы ---------- */
.theme-yellow {
  --bg-1: #FFD84A; --bg-2: #FFBE0B; --page-bg: #FFBE0B;
  --title: var(--red); --title-shadow: #fff; --title-shadow-2: rgba(150, 70, 0, .28);
  --fg: var(--ink); --fg-soft: rgba(43, 23, 8, .62);
  --card: #fff; --card-fg: var(--ink); --card-soft: #7a6552; --card-shadow: 0 14px 30px rgba(140, 70, 0, .22), 0 2px 0 rgba(255,255,255,.6) inset;
  --price-bg: var(--red); --price-fg: #fff;
  --accent: var(--red); --ring: rgba(255, 255, 255, .55); --pattern-op: .16;
  --ticker-bg: var(--red); --ticker-fg: #fff; --ticker-sep: var(--yellow);
  --plate-rim: #fff; --halo: #fff; --glow: rgba(255, 255, 255, .75);
}
.theme-red {
  --bg-1: #EA2029; --bg-2: #A80B13; --page-bg: #A80B13;
  --title: #fff; --title-shadow: var(--yellow); --title-shadow-2: rgba(60, 0, 0, .35);
  --fg: #fff; --fg-soft: rgba(255, 255, 255, .78);
  --card: #fff; --card-fg: var(--ink); --card-soft: #7a6552; --card-shadow: 0 16px 34px rgba(60, 0, 0, .35);
  --price-bg: var(--yellow); --price-fg: var(--ink);
  --accent: var(--yellow); --ring: rgba(255, 214, 90, .45); --pattern-op: .08;
  --ticker-bg: var(--yellow); --ticker-fg: var(--ink); --ticker-sep: var(--red);
  --plate-rim: #fff; --halo: var(--yellow-hi); --glow: rgba(255, 200, 60, .45);
}
.theme-graphite {
  --bg-1: #2A2A33; --bg-2: #121216; --page-bg: #121216;
  --title: var(--yellow); --title-shadow: var(--red); --title-shadow-2: rgba(0, 0, 0, .5);
  --fg: #fff; --fg-soft: rgba(255, 255, 255, .66);
  --card: #24242C; --card-fg: #fff; --card-soft: #b9b3aa; --card-shadow: 0 16px 34px rgba(0, 0, 0, .45), 0 0 0 1px rgba(255, 255, 255, .06) inset;
  --price-bg: var(--yellow); --price-fg: var(--ink);
  --accent: var(--yellow); --ring: rgba(255, 210, 60, .35); --pattern-op: .05;
  --ticker-bg: var(--yellow); --ticker-fg: var(--ink); --ticker-sep: var(--red);
  --plate-rim: #fff; --halo: var(--yellow); --glow: rgba(255, 200, 40, .35);
}

/* ---------- сцена ---------- */
.stage {
  position: absolute; left: 50%; top: 50%; width: 1920px; height: 1080px;
  transform-origin: 50% 50%; overflow: hidden; color: var(--fg);
  background: radial-gradient(ellipse 80% 90% at 30% 45%, var(--bg-1), var(--bg-2));
}

/* фон: треугольники как на стене зала + кольца-светильники */
.bg { position: absolute; inset: 0; pointer-events: none; }
.bg-pattern {
  position: absolute; inset: -120px; opacity: var(--pattern-op);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='104'%3E%3Cg fill='%23fff'%3E%3Cpath d='M0 0h40L20 34z'/%3E%3Cpath d='M60 52h40L80 86z' opacity='.7'/%3E%3Cpath d='M80 0h24L92 20z' opacity='.5'/%3E%3Cpath d='M20 60h18L29 76z' opacity='.6'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 120px 104px;
  animation: drift 90s linear infinite;
}
@keyframes drift { to { transform: translate(120px, 104px); } }

.lamp { position: absolute; border-radius: 50%; border: 10px solid var(--ring); box-shadow: 0 0 60px var(--glow), inset 0 0 40px var(--glow); }
.lamp.l1 { width: 520px; height: 520px; left: -170px; top: -230px; animation: float 16s ease-in-out infinite; }
.lamp.l2 { width: 300px; height: 300px; right: 380px; top: -190px; border-width: 8px; animation: float 13s ease-in-out -4s infinite; }
.lamp.l3 { width: 760px; height: 760px; right: -330px; bottom: -470px; border-width: 12px; opacity: .7; animation: float 19s ease-in-out -8s infinite; }
.lamp.l4 { width: 140px; height: 140px; left: 610px; bottom: 90px; border-width: 6px; opacity: .6; animation: float 11s ease-in-out -2s infinite; }
@keyframes float { 50% { transform: translate(18px, 26px) scale(1.03); } }

/* ---------- шапка ---------- */
.top { position: absolute; left: 56px; right: 56px; top: 34px; height: 150px; display: flex; align-items: center; gap: 40px; }
.brand { display: flex; align-items: center; gap: 16px; flex: none; }
.brand img { width: 104px; height: 104px; filter: drop-shadow(0 8px 14px rgba(0,0,0,.18)); animation: wobble 6s ease-in-out infinite; }
@keyframes wobble { 0%, 100% { transform: rotate(-4deg); } 50% { transform: rotate(5deg) translateY(-4px); } }
.brand b { display: block; font: 900 40px/1 var(--display); letter-spacing: .02em; color: var(--brand-fg, #fff);
  -webkit-text-stroke: 0; padding: 12px 20px 13px; border-radius: 16px; background: var(--red);
  box-shadow: 0 6px 0 var(--red-deep), 0 14px 24px rgba(0,0,0,.2); text-transform: uppercase; }
.theme-red .brand b { background: #fff; color: var(--red); box-shadow: 0 6px 0 #f0c9c9, 0 14px 24px rgba(0,0,0,.25); }
.brand span { display: block; margin-top: 12px; font: 700 15px/1 var(--text); letter-spacing: .22em; text-transform: uppercase; color: var(--fg-soft); padding-left: 4px; }

.title-wrap { flex: 1; min-width: 0; padding-left: 26px; border-left: 4px solid color-mix(in srgb, var(--fg) 18%, transparent); }
.title { font: 900 104px/1 var(--display); text-transform: uppercase; color: var(--title); white-space: nowrap; letter-spacing: -.01em;
  text-shadow: 0 7px 0 var(--title-shadow), 0 18px 30px var(--title-shadow-2); }
.title.long { font-size: 78px; }
.title .ch { display: inline-block; animation: letterIn .7s cubic-bezier(.2, 1.6, .4, 1) both; animation-delay: calc(var(--i) * 45ms); }
.title .ch.sp { width: .35em; }
@keyframes letterIn { from { opacity: 0; transform: translateY(-70px) rotate(-12deg) scale(.6); } }
.title.out .ch { animation: letterOut .35s ease-in both; animation-delay: calc(var(--i) * 20ms); }
@keyframes letterOut { to { opacity: 0; transform: translateY(40px) scale(.8); } }
.subtitle { margin-top: 14px; font: 700 26px/1 var(--text); letter-spacing: .08em; color: var(--fg-soft); text-transform: lowercase; }

.meta { flex: none; text-align: right; }
.clock { font: 800 64px/1 var(--display); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.clock i { font-style: normal; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: .15; } }
.hours { margin-top: 10px; font: 700 20px/1 var(--text); color: var(--fg-soft); letter-spacing: .04em; }
.dots { margin-top: 14px; display: flex; gap: 10px; justify-content: flex-end; height: 14px; }
.dots i { width: 14px; height: 14px; border-radius: 7px; background: color-mix(in srgb, var(--fg) 25%, transparent); transition: width .4s, background .4s; }
.dots i.on { width: 42px; background: var(--accent); }

.progress { position: absolute; left: 0; right: 0; bottom: -18px; height: 5px; border-radius: 3px; background: color-mix(in srgb, var(--fg) 12%, transparent); overflow: hidden; }
.progress i { display: block; height: 100%; width: 100%; background: var(--accent); transform-origin: left; transform: scaleX(0); }
.progress.run i { animation: prog var(--dur, 14s) linear forwards; }
@keyframes prog { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* ---------- тело ---------- */
.body { position: absolute; left: 56px; right: 56px; top: 222px; bottom: 112px; display: flex; gap: 44px; }

/* герой — большая тарелка */
.hero { flex: none; width: 640px; position: relative; display: flex; flex-direction: column; align-items: center; }
.plate-zone { position: relative; width: 430px; height: 430px; flex: none; margin-top: 40px; }
.plate-zone::before { content: ''; position: absolute; inset: -70px; border-radius: 50%; background: radial-gradient(circle, var(--glow), transparent 68%); }
.halo { position: absolute; border-radius: 50%; }
.halo.h1 { inset: -34px; border: 3px solid var(--halo); opacity: .55; }
.halo.h2 { inset: -34px; background: conic-gradient(from 0deg, transparent 0 62%, var(--halo) 96%, transparent 100%);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 9px), #000 calc(100% - 8px));
          mask: radial-gradient(farthest-side, transparent calc(100% - 9px), #000 calc(100% - 8px));
  animation: spin 5.5s linear infinite; }
.halo.h3 { inset: -64px; border: 2px dashed var(--halo); opacity: .35; animation: spin 60s linear infinite reverse; }
.orbit { position: absolute; inset: -64px; }   /* мушку ведёт скрипт (setupOrbit) — маленьким слоем */
.orbit i { position: absolute; left: 50%; top: -9px; width: 18px; height: 18px; margin-left: -9px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 18px var(--accent); }
@keyframes spin { to { transform: rotate(360deg); } }

.plate { position: absolute; inset: 0; border-radius: 50%; background: var(--plate-rim); padding: 22px;
  box-shadow: 0 30px 60px rgba(0,0,0,.28), inset 0 -8px 18px rgba(0,0,0,.08); }
.plate::after { content: ''; position: absolute; inset: 10px; border-radius: 50%; border: 2px solid rgba(0,0,0,.05); pointer-events: none; }
.plate .food { width: 100%; height: 100%; border-radius: 50%; overflow: hidden; }
.plate .food img { width: 100%; height: 100%; object-fit: cover; display: block; animation: breathe 9s ease-in-out infinite; }
@keyframes breathe { 0%, 100% { transform: scale(1.02) rotate(-3deg); } 50% { transform: scale(1.1) rotate(3deg); } }
.plate.in { animation: plateIn 1.1s cubic-bezier(.2, 1.3, .4, 1) both; }
.plate.out { animation: plateOut .55s cubic-bezier(.6, 0, .9, .5) both; }
@keyframes plateIn { from { opacity: 0; transform: translateX(180px) rotate(160deg) scale(.55); } }
@keyframes plateOut { to { opacity: 0; transform: translateX(-160px) rotate(-120deg) scale(.6); } }

.sticker { position: absolute; right: -14px; top: 6px; width: 132px; height: 132px; display: grid; place-items: center; text-align: center;
  font: 900 24px/1 var(--display); color: #fff; text-transform: uppercase; z-index: 3; }
.sticker::before { content: ''; position: absolute; inset: 0; background: var(--red);
  clip-path: polygon(50% 0%, 61% 13%, 78% 7%, 81% 24%, 97% 29%, 90% 45%, 100% 58%, 86% 67%, 88% 85%, 70% 86%, 61% 100%, 50% 90%, 39% 100%, 30% 86%, 12% 85%, 14% 67%, 0% 58%, 10% 45%, 3% 29%, 19% 24%, 22% 7%, 39% 13%);
  animation: spin 24s linear infinite; filter: drop-shadow(0 8px 10px rgba(0,0,0,.25)); }
.theme-red .sticker::before, .theme-graphite .sticker::before { background: var(--yellow); }
.theme-red .sticker, .theme-graphite .sticker { color: var(--ink); }
.sticker span { position: relative; transform: rotate(-12deg); }
.sticker.in { animation: pop .7s .5s cubic-bezier(.2, 1.8, .4, 1) both; }
.sticker.hide { display: none; }
@keyframes pop { from { opacity: 0; transform: scale(.2) rotate(-60deg); } }

/* пар над тарелкой (градиенты, без тяжёлых фильтров — чтобы тянули слабые ТВ-приставки) */
.steam { position: absolute; left: 50%; top: -40px; width: 260px; height: 220px; margin-left: -130px; z-index: 4; pointer-events: none; }
.steam span { position: absolute; bottom: 0; width: 90px; height: 150px; border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(255,255,255,.55), rgba(255,255,255,0) 68%);
  animation: steam 4.2s ease-out infinite; opacity: 0; }
.steam span:nth-child(1) { left: 20px; }
.steam span:nth-child(2) { left: 85px; animation-delay: 1.4s; }
.steam span:nth-child(3) { left: 150px; animation-delay: 2.8s; }
@keyframes steam { 0% { opacity: 0; transform: translateY(80px) scale(.6, .5); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(-120px) scale(1.3, 1.4) skewX(12deg); } }
.no-steam .steam { display: none; }

.hero-info { margin-top: 58px; width: 100%; text-align: center; }
.hero-info > * { animation: rise .7s cubic-bezier(.2, 1, .3, 1) both; }
.hero-info > :nth-child(2) { animation-delay: .08s; }
.hero-info > :nth-child(3) { animation-delay: .16s; }
.hero-info > :nth-child(4) { animation-delay: .24s; }
.hero-info.out > * { animation: sink .35s ease-in both; }
@keyframes rise { from { opacity: 0; transform: translateY(30px); } }
@keyframes sink { to { opacity: 0; transform: translateY(-20px); } }
.hero-name { font: 800 44px/1.1 var(--display); letter-spacing: -.01em; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.hero-desc { margin-top: 12px; font: 600 23px/1.3 var(--text); color: var(--fg-soft); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.hero-price { position: absolute; left: 0; right: 0; top: 426px; text-align: center; z-index: 5; }
.hero-price .price { font-size: 58px; padding: 12px 36px 14px; border-radius: 999px; }
.hero-info .weight { margin-top: 12px; font: 800 22px/1 var(--text); color: var(--fg-soft); letter-spacing: .04em; }

/* ---------- карточки ---------- */
.items { flex: 1; min-width: 0; position: relative; display: grid; gap: 22px 26px;
  grid-template-columns: repeat(var(--cols, 2), minmax(0, 1fr)); grid-template-rows: repeat(var(--rows, 3), minmax(0, 1fr)); }
.card { position: relative; background: var(--card); color: var(--card-fg); border-radius: 34px; box-shadow: var(--card-shadow);
  display: flex; align-items: center; gap: 24px; padding: 18px 26px 18px 18px; min-height: 0;
  animation: cardIn .8s cubic-bezier(.2, 1.2, .35, 1) backwards; animation-delay: calc(var(--i) * 90ms + 150ms); }
@keyframes cardIn { from { opacity: 0; transform: translateY(60px) scale(.92); } }
.card.out { animation: cardOut .45s cubic-bezier(.6, 0, .9, .4) both; animation-delay: calc(var(--i) * 45ms); }
@keyframes cardOut { to { opacity: 0; transform: translateY(-40px) scale(.95); } }

.card .ph { flex: none; width: var(--ph, 176px); height: var(--ph, 176px); border-radius: 50%; background: #fff; padding: 9px;
  box-shadow: 0 12px 22px rgba(0,0,0,.2), 0 0 0 4px color-mix(in srgb, var(--accent) 35%, transparent);
  animation: phIn 1s cubic-bezier(.2, 1.3, .4, 1) backwards; animation-delay: calc(var(--i) * 90ms + 200ms); }
@keyframes phIn { from { transform: rotate(-200deg) scale(.4); } }
.card .ph div { width: 100%; height: 100%; border-radius: 50%; overflow: hidden; animation: bob 6s ease-in-out infinite; animation-delay: calc(var(--i) * -1.1s); }
.card .ph img { width: 100%; height: 100%; object-fit: cover; display: block; }
@keyframes bob { 50% { transform: translateY(-5px) rotate(4deg); } }

.card .txt { flex: 1; min-width: 0; display: flex; flex-direction: column; height: 100%; justify-content: center; }
.card .name { font: 800 var(--name-fs, 31px)/1.12 var(--text); letter-spacing: -.01em; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card .desc { margin-top: 8px; font: 600 19px/1.3 var(--text); color: var(--card-soft); display: -webkit-box; -webkit-line-clamp: var(--desc-lines, 1); -webkit-box-orient: vertical; overflow: hidden; }
.card .row { margin-top: 14px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.card .weight { font: 700 20px/1 var(--text); color: var(--card-soft); white-space: nowrap; }
.tags { display: flex; gap: 8px; flex-wrap: wrap; }
.card .tags { position: absolute; top: -13px; right: 26px; z-index: 2; }
.card .tag { box-shadow: 0 4px 10px rgba(0,0,0,.2); font-size: 15px; padding: 8px 13px 9px; }
.tag { font: 800 14px/1 var(--display); letter-spacing: .06em; text-transform: uppercase; padding: 7px 11px 8px; border-radius: 9px; color: #fff; }
.tag.hit { background: var(--red); }
.tag.new { background: #1f8f4e; }
.tag.spicy { background: #ff6a13; }
.tag.veg { background: #5aa62a; }
.theme-red .hero-info .tag.hit { background: #fff; color: var(--red); }

/* цена */
.price { position: relative; overflow: hidden; display: inline-block; font: 800 var(--price-fs, 40px)/1 var(--display); letter-spacing: -.02em;
  background: var(--price-bg); color: var(--price-fg); padding: 10px 20px 12px; border-radius: 18px; white-space: nowrap;
  box-shadow: 0 6px 0 color-mix(in srgb, var(--price-bg) 70%, #000), 0 10px 18px rgba(0,0,0,.18); }
.price::after { content: ''; position: absolute; top: 0; bottom: 0; left: 0; width: 60%; transform: translate3d(-140%, 0, 0);
  background: linear-gradient(100deg, transparent, rgba(255,255,255,.55), transparent);
  animation: shine 7s ease-in-out infinite;   /* блеск едет через transform (видеокарта), а не через left — это перерисовка на каждом кадре */ animation-delay: calc(var(--i, 0) * .8s + 2s); }
@keyframes shine { 0% { transform: translate3d(-140%, 0, 0); } 18%, 100% { transform: translate3d(240%, 0, 0); } }
.price s { font-size: .55em; opacity: .7; margin-right: 10px; font-weight: 700; vertical-align: middle; }
.flash .price, .price.flash { animation: flash 1.6s ease-in-out 3; }
@keyframes flash { 50% { transform: scale(1.14); box-shadow: 0 0 0 10px color-mix(in srgb, var(--price-bg) 40%, transparent); } }

.items.noanim .card, .items.noanim .card .ph { animation: none; }
.items.noanim .card.flash .price { animation: flash 1.6s ease-in-out 3; }

/* подсветка карточки, которая сейчас в «герое» */
.card.spot { box-shadow: var(--card-shadow), 0 0 0 5px var(--accent); }
.card.spot .ph { animation: none; transform: scale(1.04); transition: transform .5s; }

/* нет в наличии */
.card.sold .ph, .card.sold .name, .card.sold .desc, .card.sold .row { filter: grayscale(1); opacity: .45; }
.card.sold::after { content: 'Закончилось'; position: absolute; right: 22px; top: 50%; transform: translateY(-50%) rotate(-8deg);
  font: 900 26px/1 var(--display); text-transform: uppercase; color: var(--red); border: 4px solid var(--red); border-radius: 12px; padding: 8px 14px; background: rgba(255,255,255,.9); }

/* размеры под количество строк */
.items[data-rows="1"] { --ph: 330px; --name-fs: 46px; --price-fs: 56px; --desc-lines: 3; }
.items[data-rows="2"] { --ph: 250px; --name-fs: 36px; --price-fs: 46px; --desc-lines: 2; }
/* две колонки по два блюда: крупное фото не оставляет места названию и цене */
.items[data-cols="2"][data-rows="2"]:not(.list) { --ph: 196px; --name-fs: 31px; --price-fs: 40px; }
.items[data-rows="3"] { --ph: 178px; --name-fs: 30px; --price-fs: 40px; --desc-lines: 1; }
.items[data-rows="4"] { --ph: 128px; --name-fs: 26px; --price-fs: 34px; --desc-lines: 1; }
.items[data-cols="1"] .card { padding-right: 40px; }
.items[data-cols="2"]:not(.list) .card:last-child:nth-child(odd) { grid-column: span 2; padding-right: 40px; --desc-lines: 1; }
.items[data-cols="1"] { --desc-lines: 2; }

/* ---------- вид «список» ---------- */
.items.list { display: flex; flex-direction: column; gap: 14px; }
.items.list .card { flex: 1; border-radius: 26px; padding: 10px 28px 10px 12px; gap: 22px; }
.items.list .card .ph { --ph: 100px; padding: 6px; }
.items.list .txt { flex-direction: row; align-items: center; gap: 18px; }
.items.list .name { font-size: 34px; -webkit-line-clamp: 1; flex: 0 1 auto; max-width: 600px; }
.items.list .weight { font-size: 22px; }
.items.list[data-rows="7"] .card .ph, .items.list[data-rows="8"] .card .ph { --ph: 66px; padding: 4px; }
.items.list[data-rows="7"] .name, .items.list[data-rows="8"] .name { font-size: 30px; }
.items.list .desc { display: none; }
.items.list .tags { margin: 0; flex: none; }
.items.list .leader { flex: 1; border-bottom: 4px dotted color-mix(in srgb, var(--card-soft) 45%, transparent); transform: translateY(8px); min-width: 30px; }
.items.list .row { margin: 0; gap: 18px; flex: none; }
.items.list .price { --price-fs: 36px; }
.items:not(.list) .leader { display: none; }

.empty { position: absolute; inset: 0; display: grid; place-items: center; font: 800 44px/1.2 var(--display); color: var(--fg-soft); text-align: center; }

/* ---------- бегущая строка ---------- */
.ticker { position: absolute; left: 0; right: 0; bottom: 0; height: 82px; background: var(--ticker-bg); color: var(--ticker-fg); overflow: hidden;
  display: flex; align-items: center; box-shadow: 0 -8px 24px rgba(0,0,0,.14); }
.ticker::before, .ticker::after { content: ''; position: absolute; top: 0; bottom: 0; width: 120px; z-index: 2; }
.ticker::before { left: 0; background: linear-gradient(90deg, var(--ticker-bg), transparent); }
.ticker::after { right: 0; background: linear-gradient(-90deg, var(--ticker-bg), transparent); }
.ticker-track { display: flex; white-space: nowrap; will-change: transform; animation: tick var(--tick-dur, 40s) linear infinite; }
.ticker-track span { font: 700 32px/1 var(--display); letter-spacing: .01em; padding-right: 60px; }
.ticker-track b { color: var(--ticker-sep); font-weight: 900; padding: 0 26px; }
@keyframes tick { to { transform: translateX(-50%); } }

/* ---------- свои картинки: логотип, фон экрана, плакаты ---------- */
.brand img { object-fit: contain; }
.bg-photo { position: absolute; inset: 0; background-size: cover; background-position: center; }
.has-bg .bg-pattern, .has-bg .lamp { display: none; }
.has-bg .bg::after { content: ''; position: absolute; inset: 0; background: linear-gradient(rgba(0,0,0,.28), rgba(0,0,0,.42)); }
.poster { position: absolute; inset: 0; z-index: 30; background: #000; opacity: 0; transition: opacity .7s ease; pointer-events: none; }
.poster.on { opacity: 1; }
.poster img { width: 100%; height: 100%; object-fit: cover; display: block; }
.poster.contain img { object-fit: contain; }

/* ---------- основной вид: фото блюд без круглого ободка, «висят» на белом фоне карточки (класс clean на <html>; ?classic=1 — прежний круглый вид) ---------- */
.clean .card .ph { background: transparent; padding: 0; box-shadow: none; border-radius: 0; }
.clean .card .ph div { border-radius: 0; overflow: visible; animation-name: bobClean; }
.clean .card .ph img { object-fit: contain; }
@keyframes bobClean { 50% { transform: translateY(-5px); } }

/* на тёмном экране карточки тоже белые (фото «висят» на белом), текст тёмный */
.clean .theme-graphite {
  --card: #fff; --card-fg: var(--ink); --card-soft: #7a6552;
  --card-shadow: 0 16px 34px rgba(0, 0, 0, .45);
}

/* ---------- шапка без лишнего (настройки «Что показывать в шапке»): карточки занимают освободившееся место ---------- */
.hide-clock .clock, .hide-hours .hours, .hide-progress .progress { display: none; }
.hide-clock.hide-hours .dots { margin-top: 0; }
.hide-title .title-wrap { display: none; }
.hide-title .meta { margin-left: auto; }
.hide-title .ticker { height: 76px; }


/* свои фото (загруженные в админке) и блюда без фото — в круглой рамке, как раньше: у них редко белый фон, и квадрат смотрелся бы плохо */
.clean .card .ph.ring { background: #fff; padding: 9px; border-radius: 50%;
  box-shadow: 0 12px 22px rgba(0,0,0,.2), 0 0 0 4px rgba(255,255,255,.35); }
.clean .card .ph.ring div { border-radius: 50%; overflow: hidden; }
.clean .card .ph.ring img { object-fit: cover; }

/* ---------- шапка: круглый логотип + белая табличка с названием «Тарелка» (settings.wordmark) ---------- */
.plaque { display: none; }
.has-wordmark .bn { display: none; }
.has-wordmark .brand { gap: 20px; align-items: center; background: #fff; border-radius: 28px; padding: 10px 32px 10px 12px;
  box-shadow: 0 6px 0 rgba(0,0,0,.12), 0 14px 24px rgba(0,0,0,.22); }
.has-wordmark .brand > img.logo { width: 100px; height: 100px; border-radius: 50%; background: transparent; object-fit: cover; filter: none; animation: none; box-shadow: none; }
.has-wordmark .plaque { display: flex; align-items: center; justify-content: center; }
.has-wordmark .plaque img { height: 72px; width: auto; display: block; filter: none; animation: none; }

/* ---------- метка со своим текстом ---------- */
.tag.custom { background: var(--accent, var(--red)); color: #fff; }
.theme-red .tag.custom, .theme-graphite .tag.custom { color: var(--ink); }
.clean .card .tag.custom, .card .tag.custom { background: #7B3FE4; color: #fff; }

/* ---------- две цены у блюда (половинка / целая) ---------- */
.rows2 { margin-top: 8px; display: grid; gap: 8px; }
.rows2 .row { margin-top: 0; }
.rows2 .price { font-size: calc(var(--price-fs, 40px) * .82); }

/* ---------- компактный вид (без названия раздела): карточки до самого верха, шапка — только логотип и название в левом углу ---------- */
.hide-title .top { top: 46px; right: auto; width: 640px; height: 124px; gap: 24px; }
.hide-title .meta { position: fixed; right: 56px; bottom: 92px; margin: 0; }
.hide-title .body { top: 46px; bottom: 124px; }
.hide-title .hero { top: 0; padding-top: 190px; }
.hide-title .plate-zone { margin-top: 26px; }
.hide-title .items[data-rows="3"] { --ph: 200px; --name-fs: 34px; --price-fs: 44px; --desc-lines: 2; }
.hide-title .items[data-cols="2"][data-rows="2"]:not(.list) { --ph: 214px; --name-fs: 34px; --price-fs: 44px; --desc-lines: 2; }
.hide-title .items[data-cols="1"][data-rows="3"] { --ph: 230px; --name-fs: 40px; --price-fs: 52px; --desc-lines: 2; }
.hide-title .card .desc { font-size: 21px; }
.hide-title .card .name { -webkit-line-clamp: 3; }
.hide-title .card.dual { --desc-lines: 1; }
.hide-title .card.dual .name { -webkit-line-clamp: 2; }
.hide-title .card .weight { font-size: 23px; }
.hide-title .hero-price { top: 606px; }

/* цельный логотип (кружок + «Тарелка» + «ресторан быстрого питания») — белый, без рамки, прямо на фоне экрана (settings.lockup) */
.has-lockup .brand > img.logo { display: none; }
.has-lockup .brand { padding: 0; background: none; box-shadow: none; border-radius: 0; }
.has-lockup .plaque img { height: 112px; filter: drop-shadow(0 3px 0 rgba(0,0,0,.20)) drop-shadow(0 8px 14px rgba(0,0,0,.30)); }

/* цена и вес не вылезают за карточку: если тесно — вес уходит на строку выше */
.hide-title .card .row { flex-wrap: wrap; row-gap: 6px; }
.hide-title .card .price { flex: none; }
.hide-title .card .txt { min-width: 0; }
/* самый лёгкий режим: большая тарелка сменяется простым появлением (без вращения и пролёта), метка без «выскакивания» */
@keyframes plainIn { from { opacity: 0; } }
@keyframes plainOut { to { opacity: 0; } }
.minimal .plate.in { animation: plainIn .45s ease both; }
.minimal .plate.out { animation: plainOut .3s ease both; }
.minimal .sticker.in { animation: none; }
.minimal .hero-info { transition-duration: .25s; }

/* ---------- эффекты: каждый включается отдельно (классы fx-<эффект>-<значение> на <html>, их ставит screen.js из настроек) ---------- */
/* фон и украшения */
.fx-bgPattern-static .bg-pattern, .fx-lamps-static .lamp { animation: none; }
.fx-bgPattern-off .bg-pattern, .fx-lamps-off .lamp { display: none; }
.fx-glow-off .lamp { box-shadow: none; }
.fx-glow-off .plate-zone::before { display: none; }
.fx-shadows-off .card, .fx-shadows-off .plate, .fx-shadows-off .ticker, .fx-shadows-off .card .ph, .fx-shadows-off .card .tag { box-shadow: none !important; }
.fx-shadows-off .sticker::before, .fx-shadows-off .plaque img, .fx-shadows-off .brand img { filter: none !important; }
.fx-shadows-off .has-wordmark .brand { box-shadow: none; }
/* большая тарелка */
.fx-orbit-off .orbit { display: none; }
.fx-halo-static .halo { animation: none; }
.fx-halo-off .halo { display: none; }
.fx-steam-off .steam { display: none; }
.fx-breathe-off .plate .food img { animation: none; }
.fx-stickerSpin-off .sticker::before { animation: none; }
.fx-stickerSpin-off .sticker.in { animation: none; }
@keyframes plainIn { from { opacity: 0; } }
@keyframes plainOut { to { opacity: 0; } }
.fx-plateAnim-fade .plate.in { animation: plainIn .45s ease both; }
.fx-plateAnim-fade .plate.out { animation: plainOut .3s ease both; }
.fx-plateAnim-off .plate.in, .fx-plateAnim-off .plate.out { animation: none; }
.fx-plateAnim-off .hero-info, .fx-plateAnim-fade .hero-info { transition-duration: .2s; }
/* карточки */
@keyframes cardInFade { from { opacity: 0; transform: translate3d(0, 36px, 0); } }
.fx-cardsAnim-fade .card:not(.out), .fx-cardsAnim-fade .items.noanim .card:not(.out) { animation: cardInFade .4s ease-out backwards; animation-delay: calc(var(--i) * 80ms + 80ms); }
.fx-cardsAnim-off .card:not(.out), .fx-cardsAnim-off .items.noanim .card:not(.out) { animation: none; }
.fx-photoSpin-off .card .ph { animation: none; }
.fx-photoBob-off .card .ph div { animation: none; }
.fx-priceShine-off .price::after { animation: none; display: none; }
/* шапка */
.fx-logoWobble-off .brand img { animation: none; }
.fx-titleLetters-off .title .ch, .fx-titleLetters-off .title.out .ch { animation: none; }
/* бегущая строка */
.fx-tickerEdges-off .ticker::before, .fx-tickerEdges-off .ticker::after { display: none; }
.fx-lowfps .progress.run i { animation-timing-function: steps(70, end); }
.showcase-canteen .hero-info > *, .showcase-canteen .sticker.in { animation: none; }
.showcase-paused #stage *, .showcase-paused #stage *::before, .showcase-paused #stage *::after { animation-play-state: paused !important; }
