@font-face {
  font-family: 'Material Symbols Outlined';
  font-style: normal;
  font-weight: 400;
  font-display: block;
  src: url(../fonts/material-symbols.woff2) format('woff2');
}
@font-face { font-family: 'Manrope'; font-weight: 200 800; font-display: swap; src: url(../fonts/manrope-cyr.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: 'Manrope'; font-weight: 200 800; font-display: swap; src: url(../fonts/manrope-lat.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+20BD, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Unbounded'; font-weight: 200 900; font-display: swap; src: url(../fonts/unbounded-cyr.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: 'Unbounded'; font-weight: 200 900; font-display: swap; src: url(../fonts/unbounded-lat.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+20BD, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
/* Цвета логотипа: чёрное поле, оранжевая «ПИЦЦЕРИЯ» (#F08C2E) и жёлтое кольцо (#F0C24A). */
:root {
  --primary: #F08C2E; --primary2: #F0C24A; --on-primary: #1A1208; --primary-c: #3A2814; --tonal: #2A2418; --on-tonal: #F7F3EA;
  --bg: #12110F; --surface: #1C1A16; --surface-c: #26231C; --field: #0E0D0B; --text: #F7F3EA; --muted: #C4B49A; --outline: #3A3428;
  --error: #FF5C4A; --gold: #F0C24A; --gold-c: #3A3018; --wood: #0E0D0B; --wood2: #16140F; --brand-gold: #F0C24A; --coral: #F08C2E;
  --radius: 16px; --tab-h: 84px; --safe-b: env(safe-area-inset-bottom, 0px); --safe-t: env(safe-area-inset-top, 0px);
  --display: Unbounded, Manrope, system-ui, sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--text); }
body { font: 16px/1.45 Manrope, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; }
a { color: var(--primary2); text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
button:disabled { opacity: .5; cursor: default; }
input, textarea { font: inherit; color: inherit; width: 100%; padding: 12px 14px; border: 1px solid var(--outline); border-radius: 14px; background: var(--field); }
input::placeholder, textarea::placeholder { color: #9A8C78; }
input:focus, textarea:focus { outline: 2px solid var(--primary); border-color: transparent; }
textarea { resize: vertical; }
hr { border: 0; border-top: 1px solid var(--outline); margin: 4px 0; width: 100%; }
.h2 { font: 700 19px/1.25 var(--display); margin: 22px 0 8px; }
.h3 { font: 700 15px/1.3 var(--display); margin: 14px 0 0; }
.display { font-family: var(--display); }

.ms { font-family: 'Material Symbols Outlined'; font-weight: normal; font-style: normal; font-size: 24px; line-height: 1;
  letter-spacing: normal; text-transform: none; display: inline-block; white-space: nowrap; direction: ltr;
  -webkit-font-smoothing: antialiased; font-feature-settings: 'liga'; vertical-align: middle; }
.small-ic { font-size: 16px; }
.accent { color: var(--primary2); }
.quiet { color: var(--muted); }
.small { font-size: 13px; }
.gold { color: var(--gold); margin: 0; }
.error { color: var(--error); margin: 0; }

/* ---------- каркас ---------- */
#splash { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 16px;
  background: var(--bg); color: var(--text); z-index: 100; transition: opacity .35s; }
#splash.hide { opacity: 0; pointer-events: none; }
#splash img { width: 148px; height: 148px; border-radius: 50%; object-fit: cover; animation: pulse 1.2s ease-in-out infinite; }
#splash b { font: 700 20px var(--display); color: var(--gold); }
@keyframes pulse { 50% { transform: scale(.92); } }

.app { max-width: 640px; margin: 0 auto; min-height: 100dvh; background: var(--bg); position: relative; }
.app.has-tabs { padding-bottom: calc(var(--tab-h) + var(--safe-b)); }
.topbar { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 4px; min-height: 60px;
  padding: calc(6px + var(--safe-t)) 8px 6px 16px; background: var(--bg); }
.topbar h1 { font: 700 20px var(--display); margin: 0; flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar .icon-btn:first-child { margin-left: -8px; }
.topbar .actions { display: flex; }
.icon-btn { width: 44px; height: 44px; border-radius: 14px; display: inline-flex; align-items: center; justify-content: center; flex: none; }
.icon-btn:active { background: rgba(255,255,255,.08); }
.content { padding: 4px 16px 24px; }
.content.with-bottom { padding-bottom: 160px; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.row { display: flex; align-items: center; gap: 8px; }
.row.between { justify-content: space-between; }
.row.gap { gap: 8px; }
.grow { flex: 1; min-width: 0; }
.left { text-align: left; }
.center { min-height: 50vh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 32px; gap: 12px; }
.message p { color: var(--muted); max-width: 360px; }
.spinner { width: 36px; height: 36px; border-radius: 50%; border: 3px solid var(--primary-c); border-top-color: var(--primary); animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.tabbar { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 640px; z-index: 20;
  display: flex; background: var(--surface); border-top: 1px solid var(--outline); padding-bottom: var(--safe-b); height: calc(64px + var(--safe-b)); }
.tabbar button { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font-size: 12px; color: var(--muted); }
.tabbar .tab-ic { width: 60px; height: 30px; border-radius: 15px; display: flex; align-items: center; justify-content: center; position: relative; }
.tabbar .on { color: var(--text); font-weight: 600; }
.tabbar .on .tab-ic { background: var(--primary); color: var(--on-primary); }
.tabbar.pill { bottom: calc(12px + var(--safe-b)); width: calc(100% - 32px); max-width: 420px; height: 60px; padding: 0 8px;
  border-radius: 30px; border: 1px solid var(--outline); background: rgba(22,20,16,.92); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 10px 30px rgba(0,0,0,.45); justify-content: space-around; }
.tabbar.pill button { flex: none; width: 72px; }
.tabbar.pill .tab-ic { width: 46px; height: 46px; border-radius: 23px; }
.tabbar.pill .lbl { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.tab-badge { position: absolute; top: 2px; right: 2px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: var(--primary); color: var(--on-primary); font: 700 11px/18px Manrope, sans-serif; font-style: normal; border: 2px solid var(--surface); box-sizing: content-box; }
.on .tab-badge { background: #fff; color: var(--primary); }

/* ---------- кнопки и поля ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 20px;
  border-radius: 14px; background: var(--primary); color: var(--on-primary); font-weight: 700; text-align: center; }
.btn.big { min-height: 54px; border-radius: 16px; font-size: 16px; box-shadow: 0 8px 22px rgba(240,140,46,.32); }
.btn.wide { width: 100%; }
.btn.tonal { background: var(--surface-c); color: var(--on-tonal); box-shadow: none; }
.btn.outline { background: none; color: var(--text); border: 1px solid var(--outline); }
.btn.text { background: none; color: var(--primary2); padding: 0 12px; }
.btn.text.quiet { color: var(--muted); font-weight: 500; }
.btn.danger, .danger { color: var(--error); }
.btn.add { min-height: 38px; padding: 0 14px 0 10px; }
.field { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
.field input, .field textarea { font-size: 16px; color: var(--text); }
.field.bad input, .field.bad textarea { border-color: var(--error); outline-color: var(--error); }
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chips.wrap { flex-wrap: wrap; overflow: visible; }
.chips.sticky { position: sticky; top: calc(60px + var(--safe-t)); z-index: 9; background: var(--bg); padding: 4px 16px 8px; }
.chip { flex: none; height: 36px; padding: 0 14px; border: 0; border-bottom: 2px solid transparent; border-radius: 0; background: transparent;
  color: var(--muted); font-size: 14px; font-weight: 650; white-space: nowrap; }
.chip.on { background: transparent; border-bottom-color: var(--primary); color: var(--text); }
.stepper { display: flex; align-items: center; gap: 4px; }
.stepper b { min-width: 28px; text-align: center; }
.step { width: 32px; height: 32px; border-radius: 10px; background: var(--surface-c); display: inline-flex; align-items: center; justify-content: center; }
.step .ms { font-size: 20px; }
.switch { position: relative; display: inline-block; width: 52px; height: 32px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.switch span { position: absolute; inset: 0; border-radius: 16px; background: var(--surface-c); border: 2px solid var(--outline); transition: .2s; }
.switch span::after { content: ''; position: absolute; left: 4px; top: 4px; width: 20px; height: 20px; border-radius: 50%; background: var(--outline); transition: .2s; }
.switch input:checked + span { background: var(--primary); border-color: var(--primary); }
.switch input:checked + span::after { left: 24px; background: #fff; }

/* ---------- карточки ---------- */
.card { background: var(--surface); border-radius: var(--radius); padding: 14px; display: flex; flex-direction: column; gap: 6px; }
.card.hot { background: var(--surface-c); }
.card.promo { flex-direction: row; align-items: center; gap: 12px; background: linear-gradient(120deg, #3A2A14, var(--surface)); color: var(--text); border: 1px dashed var(--primary); }
.card.promo .ms { color: var(--primary2); }
.card.note { flex-direction: row; gap: 12px; background: var(--surface); font-size: 14px; margin-top: 16px; }
.label { font-size: 13px; color: var(--muted); }
.photo { width: 116px; height: 116px; border-radius: 14px; object-fit: cover; background: #111; flex: none; }
.photo.small { width: 64px; height: 64px; border-radius: 10px; }
.photo.ph { display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #26231C, #3A2A14); color: var(--primary2); }
.cat { scroll-margin-top: calc(110px + var(--safe-t)); }
.btn.grow { white-space: nowrap; }
.product { margin: 0; padding: 14px 0; background: transparent; border-radius: 0; border-bottom: 1px solid var(--outline); gap: 8px; }
.product-top { display: flex; gap: 12px; align-items: flex-start; }
.product .name { font: 650 16px/1.25 var(--display); }
.desc { font-size: 13px; color: var(--muted); margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.size { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 2px; }
.size .row { gap: 6px; }
.cartbar { position: fixed; left: 50%; transform: translateX(-50%); width: calc(100% - 32px); max-width: 608px; z-index: 15;
  bottom: calc(12px + var(--safe-b)); display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px;
  border-radius: 16px; background: #1E1A14; color: var(--text); border: 1px solid var(--primary); box-shadow: 0 10px 28px rgba(0,0,0,.45); }
.has-tabs .cartbar { bottom: calc(84px + var(--safe-b)); }
.cartbar .sum { font: 700 18px var(--display); color: var(--primary2); }
.line { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--outline); }
.sumrow { display: flex; justify-content: space-between; font-size: 14px; }
.sumrow.total { font: 700 16px var(--display); color: var(--text); padding-top: 6px; }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; }
.consent input { width: 22px; height: 22px; padding: 0; margin-top: 1px; accent-color: var(--primary); flex: none; }
.consent.bad input { outline: 2px solid var(--error); }
.consent a { text-decoration: underline; }
.badge { flex: none; padding: 4px 10px; border-radius: 12px; font-size: 12px; font-weight: 600; }
.st-new { background: var(--primary); color: var(--on-primary); }
.st-accepted { background: #6A4520; color: #fff; }
.st-cooking { background: var(--gold-c); color: var(--gold); }
.st-ready { background: var(--gold); color: #1B1205; }
.st-on_way { background: #3A3018; color: #F0D48A; }
.st-done { background: #1F3A2A; color: #A6E3B8; }
.st-cancelled { background: var(--surface-c); color: var(--muted); }
.admin-row { flex-direction: row; }
.admin-row.off > button { opacity: .5; }
.fab { position: fixed; right: max(16px, calc(50% - 304px)); bottom: calc(84px + var(--safe-b) + 16px); z-index: 12;
  display: inline-flex; align-items: center; gap: 6px; height: 56px; padding: 0 20px; border-radius: 16px;
  background: var(--primary); color: var(--on-primary); font-weight: 700; box-shadow: 0 6px 16px rgba(0,0,0,.4); }

/* ---------- главная ---------- */
.home .content { padding-top: calc(14px + var(--safe-t)); }
.hello { display: flex; align-items: center; gap: 12px; }
.hello img { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; background: #111; flex: none; }
.hello b { display: block; font: 700 17px var(--display); }
.hello .quiet { font-size: 13px; display: flex; align-items: center; gap: 6px; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--coral); flex: none; }
.dot.on { background: #7BD88F; }
.search { display: flex; align-items: center; gap: 8px; height: 46px; padding: 0 14px; border-radius: 15px; background: var(--surface); color: var(--muted); width: 100%; text-align: left; }
.sec { display: flex; justify-content: space-between; align-items: baseline; margin: 4px 0 -2px; }
.sec h2 { font: 700 16px var(--display); margin: 0; }
.sec button { color: var(--primary2); font-size: 13px; font-weight: 700; }
.catboard { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.catboard button { display: flex; align-items: center; gap: 8px; min-height: 52px; padding: 10px 12px; text-align: left;
  border: 1px solid var(--outline); border-radius: 14px; background: var(--surface); }
.catboard button > span:not(.ms) { font: 700 11px var(--display); color: var(--primary2); }
.catboard .ms, .catboard svg { color: var(--primary); font-size: 22px; flex: none; }
.catboard b { font: 650 13px/1.2 var(--display); }
.hint { font-size: 13px; color: var(--muted); text-align: center; margin: 0; }
.seller { font-size: 12px; color: var(--muted); text-align: center; display: flex; flex-direction: column; gap: 2px; margin-top: 8px; }

/* ---------- прочее ---------- */
.done-ic { width: 96px; height: 96px; border-radius: 50%; background: var(--primary); color: var(--on-primary); display: flex; align-items: center; justify-content: center; }
.done-ic .ms { font-size: 56px; }
.done { max-width: 420px; margin: 0 auto; }
.doc p, .doc li { font-size: 15px; }
.doc ul { padding-left: 20px; }
.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(84px + var(--safe-b) + 72px); z-index: 50;
  background: #2A2418; color: #fff; padding: 12px 18px; border-radius: 14px; max-width: calc(100% - 32px); font-size: 14px; box-shadow: 0 8px 24px rgba(0,0,0,.4); }
.dialog-bg { position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 40; display: flex; align-items: center; justify-content: center; padding: 16px; }
.dialog { background: var(--bg); border-radius: 24px; padding: 22px; width: 100%; max-width: 380px; max-height: 90dvh; overflow: auto; }
.dialog.wide { max-width: 520px; }
.dialog h3 { margin: 0 0 8px; font: 700 18px var(--display); }
.dialog-actions { display: flex; justify-content: flex-end; gap: 4px; margin-top: 12px; }
.card.work { gap: 8px; }
.card.dim { opacity: .6; }
.kitchen-item { font-size: 20px; font-weight: 600; line-height: 1.3; }

.sanitary-notice { display: flex; align-items: flex-start; gap: 12px; background: #2A2218; color: var(--text); border: 1px solid var(--brand-gold); }
.sanitary-notice > .ms, .sanitary-notice > svg { color: var(--gold); flex: none; margin-top: 2px; }
.sanitary-notice p { margin: 6px 0 0; font-size: 14px; line-height: 1.5; }
.sanitary-setting p { margin: 0; }
.promo-t { display: flex; align-items: center; gap: 12px; }
.card.promo.pic { flex-direction: column; align-items: stretch; padding: 0; gap: 0; overflow: hidden; }
.card.promo.pic img { display: block; width: 100%; max-height: 420px; object-fit: cover; background: #111; }
.card.promo.pic .promo-t { padding: 14px 16px; }
.promo-edit { display: flex; flex-direction: column; gap: 10px; padding: 16px; border-radius: var(--radius); background: var(--surface-c); }
.promo-edit img { display: block; width: 100%; max-height: 260px; object-fit: contain; border-radius: 12px; }
.promo-edit p { margin: 0; }
.line .photo { width: 56px; height: 56px; border-radius: 12px; }

.extras { margin: 8px 0 2px; padding-top: 8px; border-top: 1px solid var(--outline); display: flex; flex-direction: column; gap: 8px; }
.extras .cap { display: flex; justify-content: space-between; align-items: baseline; font: 700 13px var(--display); letter-spacing: .04em; text-transform: uppercase; color: var(--primary2); }
.extras > p { margin: -4px 0 0; color: var(--muted); font-size: 13px; }
.extra { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 14px; border: 1px solid var(--outline); background: var(--bg); }
.extra.on { border-color: var(--primary); background: #2A2114; }
.extra .dot { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; font: 800 10px/1.1 var(--display); text-align: center; flex: none; letter-spacing: .02em; }
.extra .dot.soy { background: #3A2814; color: #F0C24A; }
.extra .dot.ginger { background: #4A3414; color: #F6D48A; }
.extra .dot.wasabi { background: #1C3A28; color: #B7E7C4; }
.extra .dot.ketchup { background: #4A2218; color: #F0A090; }
.extra .dot.cheese { background: #4A3A14; color: #F0D48A; }
.extra .dot.garlic { background: #3A3428; color: #F7F3EA; }
.extra .dot.unagi { background: #3A2414; color: #E8A060; }
.extra .dot.teri { background: #3A2A12; color: #F0C24A; }
.extra .dot.sweet { background: #4A2E28; color: #F0C0B0; }
.extra .dot.mango { background: #4A3010; color: #F0B040; }
.extra b { display: block; font-size: 15px; }
.extra .meta { color: var(--muted); font-size: 12px; }
.extra .stepper { margin-left: auto; }

/* Длинные названия категорий и поля редактора заказа на телефонах. */
.catboard button { min-width: 0; }
.catboard b { min-width: 0; overflow-wrap: anywhere; }
select { width: 100%; min-width: 0; padding: 12px; font: inherit; color: var(--text); background: var(--field); border: 1px solid var(--outline); border-radius: 14px; }
select:focus-visible { outline: 2px solid var(--primary); }
@media (max-width: 360px) {
  .hello b { font-size: 14px; }
  .catboard b { font-size: 12px; }
  .catboard button { padding: 10px 8px; gap: 6px; }
}
