:root {
  --bg: #061f33;
  --surface: #0b314c;
  --surface-2: #113b56;
  --surface-3: #174963;
  --text: #ffeedb;
  --muted: #aebcc5;
  --line: rgba(255,238,219,.14);
  --accent: #e7b46a;
  --accent-2: #ffeedb;
  --cream: #ffeedb;
  --danger: #e66b5d;
  --success: #69c99b;
  --radius: 22px;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; min-height: 100%; background: var(--bg); color: var(--text); }
body { overscroll-behavior-y: none; }
button, input, textarea, select { font: inherit; }
button { color: inherit; }
.hidden { display: none !important; }

.app-shell { min-height: 100vh; max-width: 760px; margin: 0 auto; background: var(--bg); }
.topbar {
  height: 76px; padding: max(12px, env(safe-area-inset-top)) 18px 10px;
  display: flex; align-items: center; justify-content: space-between;
  position: sticky; top: 0; z-index: 20;
  background: linear-gradient(180deg, rgba(6,31,51,.98), rgba(6,31,51,.86), transparent);
  backdrop-filter: blur(16px);
}
.brand { display: flex; align-items: center; gap: 11px; }
.brand-mark { width: 42px; height: 42px; border: 2px solid var(--cream); border-radius: 46% / 38%; display: grid; place-items: center; background: transparent; color: var(--cream); font-family: Georgia, serif; font-size: 14px; font-weight: 700; letter-spacing: -.08em; box-shadow: 0 8px 24px rgba(0,0,0,.22); }
.brand-name { font-size: 16px; font-weight: 780; letter-spacing: .13em; }
.brand-subtitle { color: var(--muted); font-size: 12px; margin-top: 2px; }
.profile-button { width: 42px; height: 42px; border: 1px solid var(--line); border-radius: 50%; background: var(--surface); display: grid; place-items: center; font-weight: 800; cursor: pointer; }

.main-content { padding: 4px 16px calc(96px + var(--safe-bottom)); }
.view { display: none; animation: view-in .22s ease both; }
.view.active { display: block; }
@keyframes view-in { from { opacity: 0; transform: translateY(5px); } }

.hero-card { position: relative; aspect-ratio: 1133 / 788; overflow: hidden; border: 1px solid var(--line); border-radius: 28px; background: #072944; box-shadow: 0 22px 50px rgba(0,0,0,.28); }
.hero-image { width: 100%; height: 100%; object-fit: contain; display: block; }
.hero-copy { position: absolute; left: 14px; right: 14px; bottom: 12px; }
.eyebrow, .section-kicker { color: var(--accent-2); font-size: 10px; font-weight: 850; letter-spacing: .18em; }
.hero-copy h1 { margin: 7px 0 7px; max-width: 340px; font-family: Georgia, serif; font-size: clamp(28px, 7vw, 42px); line-height: .98; font-weight: 500; }
.hero-copy p { display: inline-block; margin: 0; padding: 7px 10px; border: 1px solid var(--line); border-radius: 999px; background: rgba(6,31,51,.86); color: var(--cream); font-size: 12px; backdrop-filter: blur(8px); }

.search-wrap { margin: 18px 0 22px; height: 54px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); display: flex; align-items: center; padding: 0 14px; gap: 10px; box-shadow: 0 8px 30px rgba(0,0,0,.15); }
.search-wrap:focus-within { border-color: rgba(231,180,106,.72); box-shadow: 0 0 0 4px rgba(231,180,106,.1); }
.search-icon { color: var(--accent-2); font-size: 26px; line-height: 1; transform: rotate(-15deg); }
.search-input { flex: 1; min-width: 0; border: 0; outline: 0; color: var(--text); background: transparent; font-size: 15px; }
.search-input::placeholder { color: #7890a0; }
.search-clear { width: 30px; height: 30px; border: 0; border-radius: 50%; background: var(--surface-3); font-size: 20px; cursor: pointer; }
.sticky-search { position: sticky; top: 72px; z-index: 12; margin-top: 14px; }

.section-block { margin: 28px 0; }
.section-heading, .page-title-row { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 14px; }
h1, h2 { margin: 0; }
.section-heading h2 { margin-top: 4px; font-size: 23px; font-weight: 760; }
.page-title-row { align-items: center; margin: 12px 2px 4px; }
.page-title-row h1 { margin-top: 4px; font-family: Georgia, serif; font-size: 34px; font-weight: 500; }
.text-button { border: 0; background: transparent; color: var(--accent-2); font-weight: 700; cursor: pointer; }
.count-badge, .admin-badge { border: 1px solid var(--line); border-radius: 999px; padding: 7px 11px; color: var(--muted); background: var(--surface); font-size: 12px; font-weight: 800; }
.admin-badge { color: var(--bg); background: var(--accent-2); border: 0; }

.category-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 10px; }
.category-card { min-height: 112px; border: 1px solid var(--line); border-radius: 21px; background: linear-gradient(145deg, var(--surface-2), var(--surface)); padding: 16px; text-align: left; cursor: pointer; position: relative; overflow: hidden; }
.category-card::after { content: ""; position: absolute; width: 90px; height: 90px; right: -24px; bottom: -36px; border-radius: 50%; background: radial-gradient(circle, rgba(231,180,106,.23), transparent 67%); }
.category-number { display: block; color: var(--accent-2); font-family: Georgia, serif; font-size: 28px; }
.category-card strong { display: block; margin-top: 14px; font-size: 15px; }
.category-card small { display: block; color: var(--muted); margin-top: 3px; }
.quick-section-list { display: flex; flex-wrap: wrap; gap: 8px; }
.quick-section { border: 1px solid var(--line); border-radius: 14px; background: var(--surface); color: var(--text); padding: 10px 12px; text-align: left; cursor: pointer; }
.quick-section strong { display: block; font-size: 12px; }
.quick-section small { display: block; color: var(--muted); margin-top: 3px; font-size: 10px; }
.skeleton-grid::before, .skeleton-grid::after { content: ""; height: 112px; border-radius: 21px; background: linear-gradient(100deg, var(--surface) 25%, var(--surface-2) 45%, var(--surface) 65%); background-size: 200% 100%; animation: shimmer 1.3s infinite; }
@keyframes shimmer { to { background-position-x: -200%; } }

.horizontal-list { display: flex; gap: 10px; overflow-x: auto; padding: 2px 2px 8px; scrollbar-width: none; }
.horizontal-list::-webkit-scrollbar { display: none; }
.mini-card { flex: 0 0 195px; min-height: 120px; border: 1px solid var(--line); border-radius: 20px; background: var(--surface); padding: 15px; text-align: left; cursor: pointer; }
.mini-card .mini-cat { color: var(--accent-2); font-size: 10px; letter-spacing: .08em; text-transform: uppercase; font-weight: 800; }
.mini-card strong { display: block; margin-top: 13px; font-size: 17px; line-height: 1.15; }
.mini-card small { color: var(--muted); display: block; margin-top: 8px; }

.chip-row { display: flex; gap: 8px; overflow-x: auto; padding: 1px 0 13px; scrollbar-width: none; }
.chip-row::-webkit-scrollbar { display: none; }
.chip { flex: 0 0 auto; border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 9px 13px; font-size: 12px; color: var(--muted); cursor: pointer; }
.chip.active { color: var(--bg); background: var(--accent-2); border-color: transparent; font-weight: 800; }
.section-chip-row { margin-top: -4px; padding-bottom: 15px; }
.section-chip-row .chip { background: transparent; border-style: dashed; }
.section-chip-row .chip.active { background: var(--accent); border-style: solid; color: var(--bg); }
.cards-grid { display: grid; grid-template-columns: 1fr; gap: 10px; }
.tech-card { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: center; width: 100%; min-height: 92px; border: 1px solid var(--line); border-radius: 20px; background: var(--surface); padding: 15px 16px; text-align: left; cursor: pointer; }
.tech-card:active, .category-card:active, .mini-card:active { transform: scale(.985); }
.card-category { color: var(--accent-2); font-size: 10px; font-weight: 850; letter-spacing: .09em; text-transform: uppercase; }
.tech-card strong { display: block; margin: 6px 0 5px; font-size: 17px; line-height: 1.18; }
.card-meta { color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 72vw; }
.card-arrow { width: 37px; height: 37px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); color: var(--accent-2); font-size: 24px; }
.empty-state { text-align: center; color: var(--muted); padding: 60px 20px; border: 1px dashed var(--line); border-radius: 22px; }
.empty-state span { display: block; font-size: 36px; margin-bottom: 10px; color: var(--accent-2); }

.bottom-nav { position: fixed; z-index: 30; left: 50%; transform: translateX(-50%); bottom: 0; width: min(760px,100%); display: grid; grid-template-columns: repeat(4,1fr); background: rgba(6,31,51,.95); backdrop-filter: blur(22px); border-top: 1px solid var(--line); padding: 8px 10px calc(8px + var(--safe-bottom)); }
.nav-button { border: 0; background: transparent; color: #718a9b; display: grid; justify-items: center; gap: 2px; cursor: pointer; }
.nav-button span { font-size: 22px; line-height: 1; height: 27px; }
.nav-button small { font-size: 10px; font-weight: 700; }
.nav-button.active { color: var(--accent-2); }

.primary-action-card { width: 100%; border: 0; border-radius: 24px; padding: 18px; background: linear-gradient(135deg, #ffeedb, #e7b46a); color: var(--bg); display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px; text-align: left; margin: 20px 0 12px; cursor: pointer; }
.action-icon { width: 46px; height: 46px; border-radius: 16px; display: grid; place-items: center; background: rgba(255,255,255,.24); font-size: 28px; }
.primary-action-card strong, .primary-action-card small { display: block; }
.primary-action-card strong { font-size: 17px; }
.primary-action-card small { opacity: .72; margin-top: 3px; }
.chevron { font-size: 30px; }
.admin-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.restore-tile { grid-column: 1 / -1; min-height: 112px; border-color: rgba(231,180,106,.35); }
.admin-tile { min-height: 140px; border: 1px solid var(--line); border-radius: 22px; background: var(--surface); padding: 16px; text-align: left; cursor: pointer; }
.tile-icon { width: 42px; height: 42px; border-radius: 15px; display: grid; place-items: center; background: var(--surface-3); color: var(--accent-2); font-size: 23px; margin-bottom: 17px; }
.admin-tile strong, .admin-tile small { display: block; }
.admin-tile small { color: var(--muted); margin-top: 5px; }
.info-card { margin-top: 14px; border-radius: 20px; padding: 17px; background: var(--surface); border: 1px solid var(--line); }
.info-card p { color: var(--muted); line-height: 1.5; margin: 7px 0 0; font-size: 13px; }
.warning-card { border-color: rgba(231,180,106,.3); }

.sheet-dialog, .small-dialog { color: var(--text); border: 0; padding: 0; background: var(--surface); box-shadow: 0 -20px 70px rgba(0,0,0,.55); }
.sheet-dialog { width: min(760px,100%); max-width: none; height: min(91vh,900px); margin: auto auto 0; border-radius: 30px 30px 0 0; overflow: hidden; }
.sheet-dialog::backdrop, .small-dialog::backdrop { background: rgba(0,0,0,.67); backdrop-filter: blur(4px); }
.sheet-dialog[open] { animation: sheet-up .25s ease both; }
@keyframes sheet-up { from { transform: translateY(30px); opacity: .4; } }
.sheet-handle { width: 44px; height: 5px; background: #5f7a8c; border-radius: 99px; margin: 9px auto 1px; }
.dialog-header { min-height: 58px; padding: 8px 16px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.dialog-actions { display: flex; gap: 8px; }
.icon-button { width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 50%; background: var(--surface-2); display: grid; place-items: center; font-size: 22px; cursor: pointer; }
.card-detail { height: calc(100% - 72px); overflow-y: auto; padding: 20px 18px calc(35px + var(--safe-bottom)); }
.detail-category { color: var(--accent-2); font-size: 11px; font-weight: 850; letter-spacing: .14em; text-transform: uppercase; }
.card-detail h1 { font-family: Georgia, serif; font-size: clamp(34px,9vw,54px); font-weight: 500; line-height: 1; margin: 9px 0 10px; }
.detail-section { color: var(--muted); font-size: 13px; }
.service-strip { display: flex; flex-wrap: wrap; gap: 7px; margin: 17px 0 4px; }
.service-pill { padding: 8px 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface-2); color: var(--cream); font-size: 11px; font-weight: 760; letter-spacing: .03em; }
.scale-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 22px 0 6px; }
.scale-toolbar strong { font-size: 13px; }
.scale-buttons { display: flex; gap: 5px; }
.scale-button { min-width: 42px; height: 34px; border: 1px solid var(--line); border-radius: 11px; background: var(--surface); color: var(--muted); font-size: 12px; font-weight: 800; cursor: pointer; }
.scale-button.active { background: var(--accent-2); color: var(--bg); border-color: transparent; }
.ingredient-list { list-style: none; padding: 0; margin: 25px 0; border-top: 1px solid var(--line); }
.ingredient-list li { padding: 13px 1px; border-bottom: 1px solid var(--line); line-height: 1.35; }
.ingredient-copy { min-width: 0; display: flex; justify-content: space-between; gap: 12px; align-items: baseline; padding-top: 3px; }
.ingredient-name { font-weight: 620; }
.ingredient-amount { flex: 0 0 auto; color: var(--accent-2); font-weight: 820; text-align: right; }
.ingredient-list li.checked .ingredient-copy { opacity: .45; text-decoration: line-through; }
.detail-block { margin: 17px 0; border-radius: 18px; background: var(--surface-2); padding: 15px; }
.detail-block h3 { color: var(--accent-2); font-size: 10px; letter-spacing: .13em; text-transform: uppercase; margin: 0 0 8px; }
.detail-block p { white-space: pre-wrap; margin: 0; line-height: 1.52; font-size: 14px; }
.detail-history { padding: 0; overflow: hidden; }
.detail-history summary { padding: 15px; color: var(--accent-2); font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; cursor: pointer; }
.detail-history p { padding: 0 15px 15px; }

.editor-dialog { height: min(91vh,900px); height: min(91dvh,900px); }
.editor-dialog[open] { display: flex; flex-direction: column; }
.editor-dialog > .sheet-handle { flex-shrink: 0; }
.editor-dialog > form { display: flex; flex-direction: column; flex: 1; min-height: 0; overflow: hidden; }
.editor-dialog .editor-header { flex-shrink: 0; }
.editor-dialog .form-scroll { flex: 1; min-height: 0; height: auto; overflow-y: auto; overscroll-behavior-y: contain; }
.editor-header h2 { font-size: 17px; }
.save-button { border: 0; color: var(--bg); background: var(--accent-2); border-radius: 12px; padding: 9px 12px; font-weight: 800; cursor: pointer; }
.form-scroll { height: calc(100% - 70px); overflow-y: auto; padding: 18px 16px calc(45px + var(--safe-bottom)); }
.field-label { display: block; color: var(--muted); font-size: 12px; font-weight: 700; margin-bottom: 15px; }
.field-input { width: 100%; margin-top: 7px; border: 1px solid var(--line); outline: 0; border-radius: 15px; background: #082840; color: var(--text); padding: 13px 14px; font-size: 15px; }
.field-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(231,180,106,.1); }
.textarea { resize: vertical; min-height: 78px; line-height: 1.45; }
.field-help { display: block; margin-top: 6px; font-weight: 400; color: #7890a0; }
.danger-zone { display: grid; gap: 9px; margin-top: 26px; padding-top: 20px; border-top: 1px solid var(--line); }
.secondary-button, .danger-button { width: 100%; border-radius: 15px; padding: 13px 16px; cursor: pointer; font-weight: 750; }
.secondary-button { border: 1px solid var(--line); background: var(--surface-2); color: var(--text); margin-top: 14px; }
.danger-button { border: 1px solid rgba(255,91,91,.3); background: rgba(255,91,91,.08); color: var(--danger); }

.small-dialog { width: min(360px, calc(100% - 32px)); border-radius: 26px; margin: auto; }
.profile-card { padding: 24px; text-align: center; position: relative; }
.dialog-close { position: absolute; right: 13px; top: 13px; }
.profile-avatar { width: 70px; height: 70px; margin: 10px auto 14px; border-radius: 50%; display: grid; place-items: center; background: var(--cream); color: var(--bg); font-family: Georgia, serif; font-size: 34px; }
.profile-card h2 { font-family: Georgia, serif; font-size: 27px; font-weight: 500; }
.profile-card p { color: var(--accent-2); margin: 7px 0; }
.dev-notice { margin-top: 16px; padding: 9px; border-radius: 12px; background: rgba(231,180,106,.14); color: var(--accent-2); font-size: 12px; }

.global-loader { position: fixed; inset: 0; z-index: 100; background: var(--bg); display: grid; place-items: center; transition: opacity .22s; }
.global-loader.hidden { opacity: 0; pointer-events: none; display: grid !important; }
.global-loader span { width: 38px; height: 38px; border: 3px solid var(--surface-3); border-top-color: var(--accent); border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.toast { position: fixed; z-index: 120; left: 50%; bottom: calc(86px + var(--safe-bottom)); transform: translate(-50%,20px); width: min(420px,calc(100% - 32px)); padding: 13px 16px; border-radius: 15px; background: var(--cream); color: var(--bg); font-size: 13px; font-weight: 650; opacity: 0; pointer-events: none; transition: .22s; box-shadow: 0 12px 35px rgba(0,0,0,.35); }
.toast.show { opacity: 1; transform: translate(-50%,0); }
.toast.error { background: #ffdddd; color: #5b1717; }

@media (min-width: 600px) {
  .main-content { padding-left: 24px; padding-right: 24px; }
  .category-grid { grid-template-columns: repeat(2,1fr); }
  .cards-grid { grid-template-columns: repeat(2,1fr); }
  .card-meta { max-width: 270px; }
}
.bottom-nav { grid-template-columns: repeat(3,1fr); }
.bottom-nav.has-admin { grid-template-columns: repeat(4,1fr); }

/* Режим смены, структурные ингредиенты и фото */
.topbar-actions { display: flex; align-items: center; gap: 8px; }
.bar-mode-button { width: 42px; height: 42px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); color: var(--accent-2); font-size: 14px; font-weight: 900; cursor: pointer; }
.bar-mode-button.active { background: var(--accent-2); color: var(--bg); border-color: transparent; }

.mini-card { position: relative; overflow: hidden; display: flex; align-items: flex-end; }
.mini-card.has-photo { padding: 0; min-height: 155px; }
.mini-card > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.mini-card.has-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 10%, rgba(6,31,51,.94) 95%); }
.mini-card-copy { position: relative; z-index: 1; display: block; width: 100%; }
.mini-card.has-photo .mini-card-copy { padding: 15px; }

.tech-card { grid-template-columns: 58px minmax(0,1fr) auto; padding: 12px; }
.tech-card-photo, .tech-card-placeholder { width: 58px; height: 66px; border-radius: 15px; }
.tech-card-photo { object-fit: cover; background: var(--surface-2); }
.tech-card-placeholder { display: grid; place-items: center; background: linear-gradient(145deg, var(--surface-3), var(--surface-2)); color: var(--accent-2); font-family: Georgia, serif; font-size: 24px; }
.tech-card-copy { min-width: 0; }
.skeleton-card { min-height: 92px; grid-template-columns: 1fr; background: linear-gradient(100deg,var(--surface) 25%,var(--surface-2) 45%,var(--surface) 65%); background-size: 200% 100%; animation: shimmer 1.3s infinite; }

.admin-stats { display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; margin: 18px 0 0; }
.admin-stats article { min-height: 92px; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); padding: 14px 12px; }
.admin-stats strong { display: block; color: var(--accent-2); font-family: Georgia, serif; font-size: 28px; font-weight: 500; }
.admin-stats small { display: block; color: var(--muted); margin-top: 5px; line-height: 1.2; }
.admin-manage { margin-top: 24px; }
.compact-heading { margin-bottom: 0; }
.admin-search-results { display: grid; gap: 8px; }
.small-empty { padding: 25px 16px; }
.small-empty span { font-size: 25px; }

.detail-photo-wrap { margin: -4px -2px 22px; height: min(44vh,390px); border-radius: 24px; overflow: hidden; background: var(--surface-2); }
.detail-photo { width: 100%; height: 100%; object-fit: cover; }
.ingredient-list li { display: grid; grid-template-columns: 30px 1fr; gap: 9px; align-items: start; }
.ingredient-list li > .ingredient-number { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); color: var(--accent-2); font-size: 11px; font-weight: 850; }

.photo-editor { margin: 0 0 20px; }
.photo-preview { height: 205px; border-radius: 21px; overflow: hidden; background: var(--surface-2); border: 1px solid var(--line); display: grid; place-items: center; }
.photo-preview img { width: 100%; height: 100%; object-fit: cover; }
.photo-preview.empty-photo { border-style: dashed; color: var(--muted); }
.photo-preview.empty-photo span::before { content: "◫"; display: block; text-align: center; color: var(--accent-2); font-size: 34px; margin-bottom: 7px; }
.photo-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.compact-button { margin-top: 9px; padding: 11px 12px; font-size: 13px; }

.ingredients-editor { margin-bottom: 18px; }
.ingredients-heading { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.inline-add-button { border: 0; border-radius: 11px; padding: 8px 10px; background: rgba(231,180,106,.14); color: var(--accent-2); font-size: 12px; font-weight: 800; cursor: pointer; }
.ingredient-rows { display: grid; gap: 8px; }
.ingredient-row { display: grid; grid-template-columns: 34px minmax(0,1fr) auto; gap: 7px; align-items: center; padding: 7px; border: 1px solid var(--line); border-radius: 15px; background: #082840; transition: opacity .15s, border-color .15s, transform .15s; }
.ingredient-row.dragging { opacity: .55; border-color: var(--accent); transform: scale(.99); }
.drag-handle { height: 42px; border: 0; background: transparent; color: #7890a0; font-size: 18px; cursor: grab; touch-action: none; }
.drag-handle:active { cursor: grabbing; }
.ingredient-input { min-width: 0; width: 100%; height: 42px; border: 0; outline: 0; background: transparent; color: var(--text); font-size: 14px; }
.ingredient-row-actions { display: flex; gap: 3px; }
.ingredient-row-actions button { width: 30px; height: 34px; border: 0; border-radius: 9px; background: var(--surface-2); color: var(--muted); cursor: pointer; }
.ingredient-row-actions .remove-ingredient { color: var(--danger); }

.profile-setting { width: 100%; margin-top: 18px; padding: 14px; border: 1px solid var(--line); border-radius: 17px; background: var(--surface-2); display: flex; justify-content: space-between; align-items: center; text-align: left; cursor: pointer; }
.profile-setting strong, .profile-setting small { display: block; }
.profile-setting small { color: var(--muted); margin-top: 3px; }
.setting-state { color: var(--muted); font-size: 12px; font-weight: 850; }
.setting-state.active { color: var(--accent-2); }

/* Режим смены для быстрой работы за баром */
body.bar-mode .brand-subtitle { display: none; }
body.bar-mode .main-content { padding-left: 10px; padding-right: 10px; }
body.bar-mode .hero-card { display: none; }
body.bar-mode .category-card { min-height: 135px; }
body.bar-mode .category-card strong { font-size: 18px; }
body.bar-mode .search-wrap { height: 64px; }
body.bar-mode .search-input { font-size: 18px; }
body.bar-mode .tech-card { min-height: 116px; grid-template-columns: 72px minmax(0,1fr) 46px; }
body.bar-mode .tech-card-photo, body.bar-mode .tech-card-placeholder { width: 72px; height: 86px; }
body.bar-mode .tech-card strong { font-size: 21px; }
body.bar-mode .card-category { font-size: 11px; }
body.bar-mode .card-meta { font-size: 14px; }
body.bar-mode .card-arrow { width: 44px; height: 44px; }
body.bar-mode .card-detail { padding-left: 15px; padding-right: 15px; }
body.bar-mode .card-detail h1 { font-size: clamp(46px,12vw,72px); }
body.bar-mode .detail-category { font-size: 13px; }
body.bar-mode .detail-section { font-size: 17px; }
body.bar-mode .ingredient-list li { padding: 18px 2px; grid-template-columns: 38px 1fr; gap: 12px; }
body.bar-mode .ingredient-list li { cursor: pointer; }
body.bar-mode .ingredient-list li > .ingredient-number { width: 34px; height: 34px; font-size: 14px; }
body.bar-mode .ingredient-name, body.bar-mode .ingredient-amount { font-size: 21px; line-height: 1.28; }
body.bar-mode .ingredient-list li.checked > .ingredient-number { background: var(--accent-2); color: var(--bg); }
body.bar-mode .detail-block { padding: 19px; }
body.bar-mode .detail-block h3 { font-size: 12px; }
body.bar-mode .detail-block p { font-size: 19px; line-height: 1.52; }
body.bar-mode .icon-button { width: 48px; height: 48px; font-size: 25px; }
body.bar-mode .dialog-header { min-height: 68px; }

@media (max-width: 430px) {
  .ingredient-row { grid-template-columns: 27px minmax(0,1fr); }
  .ingredient-row-actions { grid-column: 2; justify-content: flex-end; margin-top: -3px; }
  .ingredient-row-actions button { width: 38px; }
  .admin-stats { grid-template-columns: 1fr 1fr; }
  .admin-stats article:last-child { grid-column: 1 / -1; }
}
