/* ================================================================
   Food Bible — design system
   ================================================================ */

:root {
  --bg: #f4eee3;
  --bg-deep: #ece2d2;
  --surface: #fffdf9;
  --surface-2: #faf4e9;
  --surface-3: #f6edde;
  --ink: #241e18;
  --ink-soft: #4b4137;
  --muted: #7b6e60;
  --line: #e5dac8;
  --line-strong: #d6c8b1;
  --brand: #b4471f;
  --brand-deep: #8d3412;
  --brand-soft: #f8e4d8;
  --gold: #a9781b;
  --gold-soft: #f8eed4;
  --green: #4d6b34;
  --green-soft: #e9f0dc;
  --danger: #a92f25;
  --danger-soft: #fbe5e1;
  --nav: #1d1915;
  --nav-soft: #b7aa9a;
  --nav-line: rgba(255, 255, 255, 0.09);
  --serif: Georgia, "Iowan Old Style", "Palatino Linotype", "Book Antiqua", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --shadow-sm: 0 1px 2px rgba(40, 30, 20, 0.05);
  --shadow-md: 0 14px 34px -18px rgba(40, 30, 20, 0.28);
  --shadow-lg: 0 34px 70px -30px rgba(30, 22, 14, 0.4);
  --radius: 16px;
  --sidebar: 264px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.55;
  background:
    radial-gradient(1100px 620px at 92% -8%, #fdf6e7 0%, rgba(253, 246, 231, 0) 62%),
    radial-gradient(900px 480px at -8% 18%, #efe2cd 0%, rgba(239, 226, 205, 0) 58%),
    var(--bg);
  -webkit-font-smoothing: antialiased;
}

body.modal-open {
  overflow: hidden;
}

/* Every inline icon has a sane default; components override this size. */
.ico {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  display: inline-block;
  vertical-align: middle;
}

h1, h2, h3, h4, p {
  margin: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  color: inherit;
}

img, svg {
  display: block;
}

::selection {
  background: var(--brand-soft);
  color: var(--brand-deep);
}

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
  border-radius: 6px;
}

/* ---------------------------------------------------------------
   Shell
   --------------------------------------------------------------- */

.app-shell {
  min-height: 100vh;
}

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--sidebar);
  z-index: 40;
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 26px 18px 20px;
  color: #f4ede1;
  background:
    radial-gradient(420px 260px at 18% 0%, rgba(214, 157, 80, 0.13), transparent 70%),
    radial-gradient(500px 400px at 100% 100%, rgba(180, 71, 31, 0.14), transparent 66%),
    var(--nav);
  border-right: 1px solid rgba(255, 255, 255, 0.04);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 2px 8px 20px;
  border-bottom: 1px solid var(--nav-line);
}

.brand-mark {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(145deg, #d39a3d, #a96a19);
  color: #21170c;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 8px 20px -10px rgba(211, 154, 61, 0.8);
}

.brand-mark svg {
  width: 23px;
  height: 23px;
}

.brand.brand-has-logo {
  border-bottom-color: var(--nav-line);
}

.brand-logo {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
}

.brand-logo img {
  display: block;
  max-width: 190px;
  max-height: 46px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-text strong {
  font-family: var(--serif);
  font-size: 21px;
  letter-spacing: 0.01em;
  font-weight: 600;
}

.brand-text small {
  color: var(--nav-soft);
  font-size: 10.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-top: 4px;
}

.nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  overflow-y: auto;
  padding: 0 2px;
}

.nav-section {
  margin: 16px 10px 6px;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #8d7f6e;
  font-weight: 600;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 10px 12px;
  border-radius: 11px;
  color: #c9bdac;
  font-size: 14px;
  font-weight: 500;
  transition: background 0.16s ease, color 0.16s ease, transform 0.16s ease;
}

.nav-link .ico {
  width: 18px;
  height: 18px;
  opacity: 0.86;
  flex: 0 0 18px;
}

.nav-link:hover {
  background: rgba(255, 255, 255, 0.055);
  color: #f7f1e6;
}

.nav-link.active {
  background: linear-gradient(90deg, rgba(211, 154, 61, 0.19), rgba(211, 154, 61, 0.045));
  color: #fff8eb;
  box-shadow: inset 2px 0 0 #d39a3d;
}

.nav-link.active .ico {
  color: #e0ac56;
  opacity: 1;
}

.nav-badge {
  margin-left: auto;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--brand);
  color: #fff;
  font-size: 10.5px;
  font-weight: 700;
  display: grid;
  place-items: center;
}

.sidebar-foot {
  padding-top: 16px;
  border-top: 1px solid var(--nav-line);
}

.user-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.avatar {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, #d49a3d, #a86b1b);
  color: #241708;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.02em;
  border: 2px solid rgba(255, 255, 255, 0.18);
}

.avatar-lg {
  width: 60px;
  height: 60px;
  flex-basis: 60px;
  font-size: 20px;
}

.avatar-sm {
  width: 30px;
  height: 30px;
  flex-basis: 30px;
  font-size: 11px;
}

.avatar-green {
  background: linear-gradient(145deg, #8fab6f, #5d7a3a);
  color: #18220e;
}

.avatar-blue {
  background: linear-gradient(145deg, #82a9b3, #48757f);
  color: #102126;
}

.user-meta {
  min-width: 0;
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.user-meta strong {
  font-size: 13px;
  color: #f6efe4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-meta span {
  font-size: 11px;
  color: #9e9282;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 3px;
}

.user-card .logout {
  margin-left: auto;
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #9e9282;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.user-card .logout:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #f6efe4;
}

.guest-card {
  padding: 14px;
  border-radius: 14px;
  background: linear-gradient(160deg, rgba(211, 154, 61, 0.14), rgba(255, 255, 255, 0.03));
  border: 1px solid rgba(211, 154, 61, 0.2);
}

.guest-card p {
  font-size: 12px;
  color: #bdb1a0;
  line-height: 1.5;
  margin-bottom: 11px;
}

.guest-card .btn {
  width: 100%;
  justify-content: center;
  margin-top: 6px;
}

.main-area {
  margin-left: var(--sidebar);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  height: 66px;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 34px;
  background: rgba(244, 238, 227, 0.82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(214, 200, 177, 0.55);
}

.topbar-title {
  font-family: var(--serif);
  font-size: 17px;
  letter-spacing: 0.01em;
  color: var(--ink-soft);
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.topbar-title span {
  color: var(--muted);
  font-family: var(--sans);
  font-size: 12px;
  margin-left: 10px;
  letter-spacing: 0.02em;
}

.topbar-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 10px;
}

.topbar-actions .btn {
  padding: 8px 14px;
  font-size: 13px;
}

.menu-btn {
  display: none !important;
}

.view {
  flex: 1;
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 34px 36px 70px;
}

.scrim {
  display: none;
}

/* ---------------------------------------------------------------
   Typography & primitives
   --------------------------------------------------------------- */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  color: var(--brand);
}

.eyebrow::before {
  content: "";
  width: 18px;
  height: 1px;
  background: currentColor;
  opacity: 0.6;
}

.eyebrow.plain::before {
  display: none;
}

.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 22px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.page-title {
  font-family: var(--serif);
  font-size: clamp(30px, 3.4vw, 42px);
  font-weight: 500;
  letter-spacing: -0.015em;
  line-height: 1.08;
  margin-top: 8px;
}

.page-sub {
  color: var(--muted);
  font-size: 14px;
  max-width: 64ch;
  margin-top: 8px;
}

.page-actions {
  display: flex;
  gap: 9px;
  flex-wrap: wrap;
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12.5px;
  color: var(--muted);
  margin-bottom: 18px;
}

.breadcrumb a:hover {
  color: var(--brand);
}

.breadcrumb .sep {
  opacity: 0.45;
}

.muted {
  color: var(--muted);
}

.small {
  font-size: 12.5px;
}

.serif {
  font-family: var(--serif);
}

.divider {
  height: 1px;
  background: var(--line);
  margin: 22px 0;
}

/* Buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 17px;
  border: 1px solid transparent;
  border-radius: 11px;
  background: transparent;
  color: var(--ink);
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  white-space: nowrap;
}

.btn .ico {
  width: 16px;
  height: 16px;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(0);
}

.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

.btn-primary {
  background: linear-gradient(180deg, #bd4d24, var(--brand));
  color: #fff8f2;
  box-shadow: 0 8px 18px -10px rgba(180, 71, 31, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.btn-primary:hover {
  background: linear-gradient(180deg, #c8572c, #a63e19);
}

.btn-dark {
  background: var(--nav);
  color: #f8f1e5;
}

.btn-dark:hover {
  background: #2b241d;
}

.btn-ghost {
  border-color: var(--line-strong);
  background: rgba(255, 253, 249, 0.6);
  color: var(--ink-soft);
}

.btn-ghost:hover {
  background: var(--surface);
  border-color: #c8b79c;
}

.btn-soft {
  background: var(--brand-soft);
  color: var(--brand-deep);
}

.btn-soft:hover {
  background: #f4d6c5;
}

.btn-danger {
  background: var(--danger);
  color: #fff;
}

.btn-danger:hover {
  background: #91261d;
}

.btn-outline-danger {
  border-color: #e8c2bc;
  color: var(--danger);
  background: var(--surface);
}

.btn-outline-danger:hover {
  background: var(--danger-soft);
}

.btn-sm {
  padding: 7px 12px;
  font-size: 12px;
  border-radius: 9px;
}

.btn-lg {
  padding: 13px 22px;
  font-size: 14.5px;
  border-radius: 12px;
}

.btn-block {
  width: 100%;
}

.btn-link {
  padding: 0;
  background: none;
  border: 0;
  color: var(--brand);
  font-weight: 600;
  cursor: pointer;
}

.icon-btn {
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  color: var(--ink-soft);
  display: inline-grid;
  place-items: center;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
  flex: 0 0 auto;
}

.icon-btn:hover {
  background: var(--surface-2);
  border-color: var(--line-strong);
}

.icon-btn .ico {
  width: 17px;
  height: 17px;
}

.icon-btn.favorited {
  color: var(--brand);
  background: var(--brand-soft);
  border-color: #ecc9b8;
}

.icon-btn.favorited .ico {
  fill: currentColor;
}

/* Pills & chips */

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.pill-brand {
  background: var(--brand-soft);
  border-color: transparent;
  color: var(--brand-deep);
}

.pill-green {
  background: var(--green-soft);
  border-color: transparent;
  color: var(--green);
}

.pill-gold {
  background: var(--gold-soft);
  border-color: transparent;
  color: #7d5a13;
}

.pill-danger {
  background: var(--danger-soft);
  border-color: transparent;
  color: var(--danger);
}

.pill-dark {
  background: var(--ink);
  border-color: transparent;
  color: #f7efe2;
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  flex: 0 0 6px;
}

.role-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 27px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: capitalize;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-soft);
}

.role-pill.manager { background: var(--brand-soft); color: var(--brand-deep); border-color: #eed0c0; }
.role-pill.supervisor { background: var(--gold-soft); color: #7d5a13; border-color: #ebdcb5; }
.role-pill.student { background: var(--green-soft); color: var(--green); border-color: #d9e5c5; }
.role-pill.customer { background: #eef1f3; color: #4f6168; border-color: #dfe5e8; }
.role-pill.head_waiter,
.role-pill.waiter,
.role-pill.runner { background: #e8f0f2; color: #355d66; border-color: #cfe0e4; }
.role-pill.bar_team { background: #eee9f4; color: #5f477c; border-color: #ded2ec; }
.role-pill.kitchen_team { background: var(--green-soft); color: var(--green); border-color: #d9e5c5; }
.role-pill.pending { background: #f2efe9; color: #6d6252; border-color: #d9d0bf; border-style: dashed; }

.optional {
  font-weight: 500;
  color: var(--muted);
  text-transform: none;
  letter-spacing: 0;
}

.team-forms {
  display: grid;
  gap: 16px;
  margin-bottom: 16px;
}

.install-steps {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.install-steps div {
  display: grid;
  gap: 2px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-2, #faf7f1);
}

.install-steps b {
  font-size: 12.5px;
}

.install-steps span {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.45;
}

.pw-wrap {
  position: relative;
}

.pw-wrap .input {
  padding-right: 44px;
}

.pw-toggle {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.pw-toggle:hover {
  background: rgba(29, 25, 21, 0.06);
  color: var(--ink);
}

.pw-toggle.is-revealed {
  color: var(--brand-deep);
}

.pw-toggle svg {
  width: 16px;
  height: 16px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 7px;
  font-size: 10.5px;
  font-weight: 650;
  letter-spacing: 0.02em;
  background: var(--surface-2);
  border: 1px solid var(--line);
  color: var(--ink-soft);
  white-space: nowrap;
}

.chip-danger {
  background: var(--danger-soft);
  border-color: transparent;
  color: var(--danger);
}

.chip-warn {
  background: var(--gold-soft);
  border-color: transparent;
  color: #7d5a13;
}

.chip-green {
  background: var(--green-soft);
  border-color: transparent;
  color: var(--green);
}

.chip-more {
  background: transparent;
  border-style: dashed;
  color: var(--muted);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.badge-published { background: var(--green-soft); color: var(--green); }
.badge-draft { background: var(--gold-soft); color: #7d5a13; }
.badge-neutral { background: #eef1f3; color: #5b6b72; }
.badge-danger { background: var(--danger-soft); color: var(--danger); }

/* Cards & panels */

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 17px 20px;
  border-bottom: 1px solid var(--line);
}

.panel-head h3 {
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 500;
}

.panel-head .sub {
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

.panel-body {
  padding: 20px;
}

/* Forms */

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.field > label,
.field-label {
  font-size: 12px;
  font-weight: 650;
  color: var(--ink-soft);
  letter-spacing: 0.01em;
}

.field .hint {
  font-size: 11.5px;
  color: var(--muted);
  line-height: 1.45;
}

.input,
.select,
.textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: #fffefb;
  color: var(--ink);
  font: inherit;
  font-size: 13.5px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.textarea {
  min-height: 92px;
  resize: vertical;
  line-height: 1.5;
}

.input::placeholder,
.textarea::placeholder {
  color: #a99c8d;
}

.input:focus,
.select:focus,
.textarea:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(180, 71, 31, 0.12);
}

.select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%237b6e60' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 11px center;
  padding-right: 32px;
  cursor: pointer;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.form-grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.form-grid .span-2 {
  grid-column: span 2;
}

.form-section {
  padding: 20px 0;
  border-top: 1px solid var(--line);
}

.form-section:first-child {
  border-top: 0;
  padding-top: 0;
}

.form-section-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 14px;
}

.check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--ink-soft);
  cursor: pointer;
  user-select: none;
}

.check input {
  width: 15px;
  height: 15px;
  accent-color: var(--brand);
  margin: 0;
}

.search-box {
  position: relative;
  flex: 1;
  min-width: 200px;
}

.search-box .ico {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: var(--muted);
  pointer-events: none;
}

.search-box .input {
  padding-left: 36px;
}

.form-error {
  display: none;
  padding: 9px 12px;
  border-radius: 9px;
  background: var(--danger-soft);
  color: var(--danger);
  font-size: 12.5px;
  font-weight: 500;
}

.form-error.show {
  display: block;
}

/* Toasts */

.toasts {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 120;
  display: flex;
  flex-direction: column;
  gap: 9px;
  pointer-events: none;
}

.toast {
  min-width: 240px;
  max-width: 380px;
  padding: 12px 15px 12px 14px;
  border-radius: 11px;
  background: #241e18;
  color: #fbf4e8;
  font-size: 13px;
  line-height: 1.45;
  box-shadow: var(--shadow-lg);
  border-left: 3px solid var(--gold);
  animation: toast-in 0.22s ease both;
  pointer-events: auto;
}

.toast.success { border-left-color: #7fa45c; }
.toast.error { border-left-color: #d4665c; }
.toast.info { border-left-color: #d7a548; }

.toast.out {
  animation: toast-out 0.2s ease both;
}

@keyframes toast-in {
  from { opacity: 0; transform: translateY(10px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes toast-out {
  to { opacity: 0; transform: translateY(8px); }
}

/* Loaders & empty states */

.boot-loader {
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: var(--muted);
  font-size: 13px;
}

.loader-ring {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2px solid var(--line-strong);
  border-top-color: var(--brand);
  animation: spin 0.8s linear infinite;
}

.loading-inline {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 48px;
  color: var(--muted);
  font-size: 13px;
}

.loading-inline .loader-ring {
  width: 20px;
  height: 20px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.skeleton {
  border-radius: 12px;
  background: linear-gradient(100deg, #efe6d7 30%, #f8f1e4 50%, #efe6d7 70%);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
}

@keyframes shimmer {
  to { background-position: -200% 0; }
}

.empty-state {
  padding: 54px 26px;
  text-align: center;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  background: rgba(255, 253, 249, 0.55);
}

.empty-state .empty-icon {
  font-size: 34px;
  margin-bottom: 10px;
}

.empty-state h3 {
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 500;
  margin-bottom: 6px;
}

.empty-state p {
  color: var(--muted);
  font-size: 13px;
  max-width: 46ch;
  margin: 0 auto 16px;
}

/* ---------------------------------------------------------------
   Home
   --------------------------------------------------------------- */

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(320px, 0.88fr);
  gap: 34px;
  padding: 48px 48px 44px;
  border-radius: 26px;
  border: 1px solid #e7d8c1;
  background:
    radial-gradient(600px 340px at 88% 6%, rgba(197, 139, 62, 0.18), transparent 62%),
    radial-gradient(480px 300px at 8% 96%, rgba(180, 71, 31, 0.09), transparent 60%),
    linear-gradient(135deg, #fffcf5 0%, #f8efdf 55%, #f3e4cf 100%);
  overflow: hidden;
  box-shadow: 0 30px 60px -40px rgba(60, 40, 20, 0.35);
}

.hero::after {
  content: "";
  position: absolute;
  right: -80px;
  bottom: -120px;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  border: 1px solid rgba(180, 71, 31, 0.14);
  pointer-events: none;
}

.hero-copy {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
}

.hero h1 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(36px, 4.6vw, 58px);
  line-height: 1.03;
  letter-spacing: -0.025em;
  margin: 16px 0 18px;
  color: #221b14;
}

.hero h1 em {
  font-style: italic;
  color: var(--brand);
}

.hero-copy > p {
  color: #5f5347;
  font-size: 15.5px;
  line-height: 1.6;
  max-width: 52ch;
}

.hero-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 26px;
}

.hero-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid rgba(160, 130, 95, 0.22);
  width: 100%;
}

.hero-trust span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  font-weight: 600;
  color: #6d5e4e;
}

.hero-trust .ico {
  width: 14px;
  height: 14px;
  color: var(--brand);
}

.hero-art {
  position: relative;
  min-height: 330px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-card {
  position: relative;
  width: min(300px, 100%);
  padding: 22px;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid rgba(196, 170, 135, 0.55);
  box-shadow: 0 24px 50px -24px rgba(60, 40, 20, 0.45);
  transform: rotate(-3deg);
  z-index: 2;
}

.hero-card-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 15px;
  border-bottom: 1px dashed var(--line-strong);
}

.hero-card-emoji {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 26px;
  background: linear-gradient(145deg, #fbe8d2, #f2d6b3);
}

.hero-card-head small {
  display: block;
  font-size: 9.5px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
}

.hero-card-head strong {
  display: block;
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 600;
  line-height: 1.2;
  margin-top: 2px;
}

.hero-card-rows {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 14px;
}

.hero-card-row {
  display: flex;
  justify-content: space-between;
  font-size: 11.5px;
  color: var(--muted);
  padding-bottom: 7px;
  border-bottom: 1px solid #f0e8da;
}

.hero-card-row b {
  color: var(--ink-soft);
  font-weight: 650;
}

.hero-mini {
  position: absolute;
  z-index: 3;
  padding: 10px 13px;
  border-radius: 11px;
  background: #241e18;
  color: #fbf4e8;
  font-size: 10.5px;
  font-weight: 650;
  letter-spacing: 0.02em;
  box-shadow: 0 14px 30px -14px rgba(30, 20, 10, 0.55);
  display: flex;
  align-items: center;
  gap: 7px;
}

.hero-mini .ico {
  width: 13px;
  height: 13px;
  color: #e4b05c;
}

.hero-mini.top {
  top: 16px;
  right: 2px;
  transform: rotate(2deg);
}

.hero-mini.bottom {
  bottom: 14px;
  left: 2px;
  transform: rotate(-2deg);
}

.hero-mini.bottom .ico {
  color: #9bbf74;
}

.hero-stamp {
  position: absolute;
  z-index: 1;
  top: 26px;
  left: 0;
  width: 70px;
  height: 70px;
  border-radius: 50%;
  border: 1px dashed #c9a675;
  display: grid;
  place-items: center;
  color: #a07f52;
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-align: center;
  line-height: 1.3;
  font-weight: 700;
  background: rgba(255, 253, 246, 0.7);
  transform: rotate(-12deg);
}

.stat-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 20px 0 46px;
}

.stat {
  padding: 16px 18px;
  border-radius: 13px;
  background: rgba(255, 253, 249, 0.72);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  gap: 13px;
}

.stat-icon {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: var(--surface-2);
  color: var(--brand);
}

.stat-icon .ico {
  width: 17px;
  height: 17px;
}

.stat b {
  display: block;
  font-family: var(--serif);
  font-size: 23px;
  font-weight: 500;
  line-height: 1;
  color: var(--ink);
}

.stat span {
  display: block;
  font-size: 10.5px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
  margin-top: 5px;
}

.section {
  margin-bottom: 50px;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}

.section-head h2 {
  font-family: var(--serif);
  font-size: clamp(24px, 2.4vw, 31px);
  font-weight: 500;
  letter-spacing: -0.015em;
  line-height: 1.15;
  margin-top: 7px;
}

.section-head p {
  color: var(--muted);
  font-size: 13px;
  max-width: 52ch;
  margin-top: 6px;
}

.restaurant-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.restaurant-card {
  position: relative;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
}

.restaurant-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.restaurant-band {
  position: relative;
  height: 104px;
  padding: 18px;
  background:
    radial-gradient(280px 150px at 80% 0%, rgba(255, 255, 255, 0.24), transparent 70%),
    var(--accent, var(--brand));
  overflow: hidden;
}

.restaurant-band::after {
  content: attr(data-cuisine);
  position: absolute;
  right: 16px;
  bottom: 12px;
  font-size: 9.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.82);
  font-weight: 700;
}

.restaurant-emoji {
  position: absolute;
  right: 14px;
  top: -6px;
  font-size: 64px;
  opacity: 0.26;
  filter: grayscale(0.15);
  transform: rotate(8deg);
}

.restaurant-mark {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.28);
  display: grid;
  place-items: center;
  color: #fff;
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 600;
  backdrop-filter: blur(4px);
}

.restaurant-body {
  padding: 18px 20px 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.restaurant-body h3 {
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.2;
}

.restaurant-body .tagline {
  color: var(--muted);
  font-size: 12.5px;
  margin-top: 4px;
}

.restaurant-place {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 11.5px;
  color: var(--muted);
  margin-top: 12px;
}

.restaurant-place .ico {
  width: 13px;
  height: 13px;
  flex: 0 0 13px;
}

.restaurant-meta {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin: 13px 0 16px;
}

.restaurant-body .btn {
  margin-top: auto;
  justify-content: space-between;
}

.role-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.role-card {
  padding: 20px;
  border-radius: 15px;
  background: rgba(255, 253, 249, 0.8);
  border: 1px solid var(--line);
}

.role-card .role-ico {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  margin-bottom: 13px;
  background: var(--brand-soft);
  color: var(--brand);
}

.role-card:nth-child(2) .role-ico { background: var(--green-soft); color: var(--green); }
.role-card:nth-child(3) .role-ico { background: var(--gold-soft); color: #8a6416; }
.role-card:nth-child(4) .role-ico { background: #e9edf0; color: #4f6168; }

.role-card .role-ico .ico {
  width: 18px;
  height: 18px;
}

.role-card h3 {
  font-size: 14px;
  font-weight: 700;
}

.role-card p {
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.55;
  margin-top: 6px;
}

.footer {
  margin-top: 30px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 11.5px;
  color: var(--muted);
}

/* ---------------------------------------------------------------
   Bible
   --------------------------------------------------------------- */

.restaurant-hero {
  position: relative;
  padding: 32px 34px;
  border-radius: 20px;
  color: #fff9f0;
  background:
    radial-gradient(500px 260px at 88% 0%, rgba(255, 255, 255, 0.18), transparent 65%),
    linear-gradient(120deg, var(--accent, var(--brand)), color-mix(in srgb, var(--accent, var(--brand)) 62%, #1d1915));
  overflow: hidden;
  box-shadow: 0 24px 50px -30px color-mix(in srgb, var(--accent, var(--brand)) 70%, transparent);
  margin-bottom: 20px;
}

.restaurant-hero::after {
  content: "";
  position: absolute;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.14);
  right: -70px;
  top: -100px;
}

.restaurant-hero-grid {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.restaurant-hero h1 {
  font-family: var(--serif);
  font-size: clamp(30px, 3.6vw, 44px);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.06;
  margin: 10px 0 8px;
}

.restaurant-hero .tagline {
  color: rgba(255, 248, 238, 0.82);
  font-size: 14px;
  max-width: 62ch;
  line-height: 1.55;
}

.restaurant-hero .hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  color: rgba(255, 250, 242, 0.75);
}

.restaurant-hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 18px;
}

.restaurant-hero-meta .pill {
  background: rgba(255, 255, 255, 0.13);
  border-color: rgba(255, 255, 255, 0.18);
  color: rgba(255, 250, 244, 0.94);
  backdrop-filter: blur(4px);
}

.restaurant-hero .switcher {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 210px;
}

.restaurant-hero .switcher label {
  font-size: 9.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 250, 242, 0.7);
  font-weight: 700;
}

.restaurant-hero .switcher select {
  width: 100%;
  padding: 9px 30px 9px 11px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background-color: rgba(28, 22, 16, 0.28);
  color: #fff8ee;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
}

.restaurant-hero .switcher option {
  color: var(--ink);
  background: var(--surface);
}

.restaurant-hero .switcher-locked {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background-color: rgba(28, 22, 16, 0.28);
  color: #fff8ee;
  font-size: 12.5px;
  font-weight: 600;
}

.restaurant-hero .switcher-locked svg {
  width: 14px;
  height: 14px;
  opacity: 0.75;
}

.toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 13px;
  margin-bottom: 14px;
  border-radius: 14px;
  background: rgba(255, 253, 249, 0.78);
  border: 1px solid var(--line);
}

.toolbar .select {
  width: auto;
  min-width: 150px;
  font-size: 12.5px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.toolbar .check {
  padding: 0 6px;
}

.chip-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  width: 100%;
}

.filter-chip {
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.filter-chip:hover {
  border-color: var(--line-strong);
  background: var(--surface-2);
}

.filter-chip.active {
  background: var(--ink);
  border-color: var(--ink);
  color: #fbf4e8;
}

.filter-chip .count {
  font-size: 10px;
  opacity: 0.55;
  margin-left: 5px;
}

.results-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin: 18px 2px 13px;
  font-size: 12.5px;
  color: var(--muted);
}

.results-line strong {
  color: var(--ink-soft);
}

.dish-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
  gap: 14px;
}

.dish-card {
  display: flex;
  flex-direction: column;
  padding: 18px;
  border-radius: 15px;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
  cursor: pointer;
  position: relative;
}

.dish-card:hover {
  transform: translateY(-3px);
  border-color: #d8c6ab;
  box-shadow: var(--shadow-md);
}

.dish-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.dish-tile {
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 25px;
  background: linear-gradient(145deg, #fbe9d4, #f3d9b9);
  border: 1px solid rgba(196, 160, 116, 0.24);
}

.dish-tile.tone-1 { background: linear-gradient(145deg, #e5efda, #d3e4c1); }
.dish-tile.tone-2 { background: linear-gradient(145deg, #f9e8d0, #f1d5af); }
.dish-tile.tone-3 { background: linear-gradient(145deg, #e6ebf0, #d5dee6); }
.dish-tile.tone-4 { background: linear-gradient(145deg, #f6e2dd, #edd0c8); }
.dish-tile.tone-5 { background: linear-gradient(145deg, #f3ecd4, #e8dcb8); }

.dish-tile.has-photo,
.item-emoji.has-photo,
.fav-tile.has-photo {
  padding: 0;
  overflow: hidden;
  background: var(--surface-2);
}

.dish-tile img,
.item-emoji img,
.fav-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: inherit;
}

.photo-editor {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px;
  border: 1px dashed var(--line-strong);
  border-radius: 12px;
  background: var(--surface-2);
}

.photo-preview {
  width: 68px;
  height: 68px;
  flex: 0 0 68px;
  display: grid;
  place-items: center;
  font-size: 30px;
  border-radius: 12px;
  overflow: hidden;
  background: linear-gradient(145deg, #fbe9d4, #f3d9b9);
  border: 1px solid rgba(196, 160, 116, 0.24);
}

.photo-preview.has-photo { background: var(--surface-2); }
.photo-preview img { width: 100%; height: 100%; object-fit: cover; display: block; }

.logo-preview {
  width: 168px;
  flex: 0 0 168px;
  height: 56px;
  padding: 0;
  background: #f7f2e8;
  overflow: hidden;
}

.logo-preview.has-photo { background: #f7f2e8; }
.logo-preview img { object-fit: contain; }
.logo-preview svg { width: 24px; height: 24px; color: #6b4f27; }

.logo-preview.is-adjustable {
  cursor: grab;
  touch-action: none;
  user-select: none;
}

.logo-preview.is-adjustable:hover { border-color: var(--gold); }
.logo-preview.is-dragging { cursor: grabbing; }

.logo-adjust {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-basis: 100%;
  flex-wrap: wrap;
}

.logo-zoom {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--muted);
}

.logo-zoom input[type="range"] {
  width: 160px;
  accent-color: var(--gold);
}

.logo-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--muted);
  cursor: pointer;
}

.logo-toggle input { accent-color: var(--gold); }

.photo-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.photo-actions .btn { cursor: pointer; }
.photo-editor .hint { flex-basis: 100%; margin: 0; }

.hint-inline {
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
  color: var(--muted);
}

.dish-cat {
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 6px;
}

.dish-card h3 {
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin-top: 12px;
}

.dish-desc {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.5;
  margin-top: 6px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 36px;
}

.dish-allergens {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 13px;
  min-height: 22px;
  align-items: center;
}

.dish-allergens .chip {
  font-size: 9.5px;
  padding: 2px 6px;
}

.dish-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid #f0e8da;
  font-size: 10.5px;
  color: var(--muted);
}

.dish-foot b {
  color: var(--ink-soft);
  font-weight: 650;
}

.dish-warn {
  position: absolute;
  top: 15px;
  right: 15px;
  width: 21px;
  height: 21px;
  border-radius: 50%;
  background: var(--danger-soft);
  color: var(--danger);
  display: grid;
  place-items: center;
}

.dish-warn .ico {
  width: 12px;
  height: 12px;
}

/* ---------------------------------------------------------------
   Item detail
   --------------------------------------------------------------- */

.detail-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 16px;
}

.detail-back:hover {
  color: var(--brand);
}

.detail-back .ico {
  width: 14px;
  height: 14px;
}

.item-hero {
  display: flex;
  gap: 22px;
  align-items: flex-start;
  padding: 26px 28px;
  border-radius: 20px;
  background:
    radial-gradient(600px 240px at 92% 0%, rgba(201, 156, 89, 0.12), transparent 70%),
    var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.item-emoji {
  width: 92px;
  height: 92px;
  flex: 0 0 92px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  font-size: 48px;
  background: linear-gradient(145deg, #fbe9d4, #f2d5b1);
  border: 1px solid rgba(196, 160, 116, 0.3);
}

.item-hero-main {
  flex: 1;
  min-width: 220px;
}

.item-hero-main h1 {
  font-family: var(--serif);
  font-size: clamp(28px, 3.2vw, 40px);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.08;
  margin: 7px 0 8px;
}

.item-hero-main .desc {
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.6;
  max-width: 70ch;
}

.item-hero-meta {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 14px;
}

.item-hero-actions {
  display: flex;
  gap: 7px;
  align-items: flex-start;
  flex-wrap: wrap;
}

.allergen-banner {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 17px;
  border-radius: 12px;
  margin-bottom: 20px;
  font-size: 12.5px;
  line-height: 1.5;
  border: 1px solid transparent;
}

.allergen-banner .ico {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  margin-top: 1px;
}

.allergen-banner strong {
  display: block;
  font-size: 12.5px;
  margin-bottom: 1px;
}

.allergen-banner.danger {
  background: var(--danger-soft);
  border-color: #f0cdc7;
  color: #7f2a21;
}

.allergen-banner.safe {
  background: var(--green-soft);
  border-color: #d8e4c7;
  color: #3c5527;
}

.allergen-banner.info {
  background: var(--gold-soft);
  border-color: #eddfbd;
  color: #6f5214;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(280px, 0.85fr);
  gap: 16px;
  align-items: start;
}

.detail-main,
.detail-side {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.ing-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}

.ing-table th {
  text-align: left;
  padding: 0 12px 9px;
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
  border-bottom: 1px solid var(--line);
}

.ing-table td {
  padding: 11px 12px;
  border-bottom: 1px solid #f0e8da;
  vertical-align: top;
  color: var(--ink-soft);
}

.ing-table tr:last-child td {
  border-bottom: 0;
}

.ing-table td:first-child {
  font-weight: 650;
  color: var(--ink);
}

.ing-table td:last-child {
  width: 32%;
}

.ing-table .note {
  display: block;
  font-size: 10.5px;
  color: var(--muted);
  margin-top: 2px;
  font-weight: 400;
}

.ing-allergens {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
}

.ing-allergens .chip {
  font-size: 9px;
  padding: 1px 5px;
}

.allergen-panel .allergen-group {
  padding: 14px 0;
  border-top: 1px solid #f0e8da;
}

.allergen-panel .allergen-group:first-child {
  padding-top: 0;
  border-top: 0;
}

.allergen-group-label {
  font-size: 9.5px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
  margin-bottom: 8px;
}

.allergen-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.nutrition-kcal {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding-bottom: 13px;
  margin-bottom: 13px;
  border-bottom: 1px dashed var(--line-strong);
}

.nutrition-kcal b {
  font-family: var(--serif);
  font-size: 36px;
  font-weight: 500;
  line-height: 1;
  color: var(--ink);
}

.nutrition-kcal span {
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
}

.nutrition-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px 12px;
}

.nutrition-cell {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 11.5px;
  padding-bottom: 6px;
  border-bottom: 1px solid #f2ebdd;
}

.nutrition-cell span {
  color: var(--muted);
}

.nutrition-cell b {
  font-weight: 650;
  color: var(--ink-soft);
}

.step-list {
  list-style: none;
  counter-reset: step;
  display: flex;
  flex-direction: column;
  gap: 11px;
  padding: 0;
  margin: 0;
}

.step-list li {
  counter-increment: step;
  display: flex;
  gap: 11px;
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--ink-soft);
}

.step-list li::before {
  content: counter(step, decimal-leading-zero);
  flex: 0 0 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--surface-2);
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  font-family: var(--serif);
  font-size: 10px;
  color: var(--brand);
  font-weight: 600;
  margin-top: 1px;
}

.meta-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 12px;
}

.meta-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 9px;
  border-bottom: 1px solid #f2ebdd;
}

.meta-row:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.meta-row span {
  color: var(--muted);
}

.meta-row b {
  font-weight: 600;
  text-align: right;
  color: var(--ink-soft);
}

.cert-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.shelf-note {
  font-size: 12px;
  color: var(--ink-soft);
  line-height: 1.55;
}

.shelf-note + .shelf-note {
  margin-top: 9px;
  padding-top: 9px;
  border-top: 1px dashed var(--line);
}

.shelf-note span {
  display: block;
  color: var(--muted);
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 700;
  margin-bottom: 2px;
}

.print-only {
  display: none;
}

/* ---------------------------------------------------------------
   Auth
   --------------------------------------------------------------- */

.auth-wrap {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: 0;
  max-width: 1000px;
  margin: 20px auto;
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-md);
  background: var(--surface);
}

.auth-art {
  position: relative;
  padding: 42px 38px;
  color: #fbf4e8;
  background:
    radial-gradient(500px 300px at 100% 0%, rgba(211, 154, 61, 0.2), transparent 65%),
    radial-gradient(400px 300px at 0% 100%, rgba(180, 71, 31, 0.3), transparent 65%),
    var(--nav);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 30px;
  overflow: hidden;
}

.auth-art::after {
  content: "";
  position: absolute;
  right: -90px;
  bottom: -90px;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.auth-art .eyebrow {
  color: #d8a958;
}

.auth-art h1 {
  font-family: var(--serif);
  font-size: clamp(28px, 3.2vw, 38px);
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 14px 0;
}

.auth-art p {
  color: #b9ac9b;
  font-size: 13px;
  line-height: 1.65;
  max-width: 36ch;
}

.auth-points {
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  z-index: 1;
}

.auth-point {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 12px;
  color: #cfc3b2;
  line-height: 1.45;
}

.auth-point .ico {
  width: 16px;
  height: 16px;
  color: #d8a958;
  flex: 0 0 16px;
  margin-top: 1px;
}

.auth-art .stamp {
  font-family: var(--serif);
  font-size: 12px;
  color: #8f8271;
  letter-spacing: 0.04em;
  position: relative;
  z-index: 1;
}

.auth-panel {
  padding: 38px 40px;
}

.auth-panel h2 {
  font-family: var(--serif);
  font-size: 27px;
  font-weight: 500;
  letter-spacing: -0.01em;
}

.auth-panel .sub {
  color: var(--muted);
  font-size: 13px;
  margin-top: 5px;
  margin-bottom: 22px;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.auth-form .btn-block {
  margin-top: 4px;
}

.auth-switch {
  margin-top: 18px;
  font-size: 12.5px;
  color: var(--muted);
  text-align: center;
}

.auth-switch a {
  color: var(--brand);
  font-weight: 650;
}

.demo-box {
  margin-top: 20px;
  padding: 13px 14px;
  border-radius: 12px;
  background: var(--surface-2);
  border: 1px dashed var(--line-strong);
}

.demo-box .demo-title {
  font-size: 9.5px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
  margin-bottom: 9px;
}

.demo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5px;
}

.demo-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 9px;
  border-radius: 8px;
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 10.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  text-align: left;
}

.demo-btn:hover {
  border-color: var(--brand);
  color: var(--brand-deep);
}

.demo-btn .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brand);
  flex: 0 0 6px;
}

.demo-btn.student .dot { background: var(--green); }
.demo-btn.supervisor .dot { background: var(--gold); }
.demo-btn.guest .dot { background: #7b8b93; }

.type-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.type-option {
  position: relative;
  display: flex;
  gap: 9px;
  align-items: flex-start;
  padding: 11px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: #fffefb;
  cursor: pointer;
  transition: all 0.15s ease;
}

.type-option:hover {
  border-color: #c8b79c;
}

.type-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.type-option .t-ico {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: var(--surface-2);
  color: var(--muted);
}

.type-option .t-ico .ico {
  width: 15px;
  height: 15px;
}

.type-option b {
  display: block;
  font-size: 12px;
  font-weight: 650;
}

.type-option small {
  display: block;
  font-size: 10.5px;
  color: var(--muted);
  margin-top: 1px;
}

.type-option:has(input:checked) {
  border-color: var(--brand);
  background: var(--brand-soft);
  box-shadow: 0 0 0 2px rgba(180, 71, 31, 0.1);
}

.type-option:has(input:checked) .t-ico {
  background: #fff;
  color: var(--brand);
}

.staff-note {
  display: flex;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 9px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  font-size: 11px;
  line-height: 1.5;
  color: var(--muted);
}

.staff-note .ico {
  width: 14px;
  height: 14px;
  flex: 0 0 14px;
  margin-top: 1px;
  color: var(--gold);
}

/* ---------------------------------------------------------------
   Exams & results
   --------------------------------------------------------------- */

.exam-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 15px;
}

.exam-card {
  display: flex;
  flex-direction: column;
  padding: 22px;
  border-radius: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}

.exam-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.exam-card h3 {
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 500;
  line-height: 1.2;
  margin: 13px 0 7px;
}

.exam-card .desc {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.exam-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 15px 0;
}

.exam-meta .pill {
  font-size: 10.5px;
}

.exam-foot {
  margin-top: auto;
  padding-top: 15px;
  border-top: 1px solid #f0e8da;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.exam-score {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.exam-score b {
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 500;
}

.exam-score span {
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
  margin-top: 2px;
}

.results-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.result-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 18px;
  border-bottom: 1px solid #f0e8da;
  font-size: 12.5px;
  flex-wrap: wrap;
}

.result-row:last-child {
  border-bottom: 0;
}

.result-row .grow {
  flex: 1;
  min-width: 140px;
}

.result-row strong {
  font-weight: 650;
  font-size: 13px;
}

.result-row small {
  display: block;
  font-size: 10.5px;
  color: var(--muted);
  margin-top: 2px;
}

/* Exam runner */

.exam-run {
  max-width: 860px;
  margin: 0 auto;
}

.exam-run-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.exam-run-head h1 {
  font-family: var(--serif);
  font-size: clamp(25px, 2.8vw, 33px);
  font-weight: 500;
  letter-spacing: -0.015em;
  line-height: 1.15;
  margin-top: 6px;
}

.exam-run-head .meta {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 9px;
}

.progress-wrap {
  margin-bottom: 16px;
}

.progress-line {
  display: flex;
  justify-content: space-between;
  font-size: 10.5px;
  color: var(--muted);
  margin-bottom: 6px;
  letter-spacing: 0.04em;
  font-weight: 600;
}

.progress-track {
  height: 6px;
  border-radius: 999px;
  background: #e9dfcf;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), #d18446);
  transition: width 0.3s ease;
}

.question-card {
  padding: 28px;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}

.question-num {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brand);
}

.question-card h2 {
  font-family: var(--serif);
  font-size: clamp(21px, 2.4vw, 26px);
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.01em;
  margin: 8px 0 20px;
}

.option-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.option {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  width: 100%;
  padding: 13px 15px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fffefb;
  text-align: left;
  cursor: pointer;
  font-size: 13.5px;
  color: var(--ink-soft);
  transition: all 0.15s ease;
}

.option:hover {
  border-color: #cbb79a;
  background: var(--surface-2);
}

.option-letter {
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  display: grid;
  place-items: center;
  font-size: 10.5px;
  font-weight: 700;
  color: var(--muted);
  background: #fff;
  transition: all 0.15s ease;
}

.option.selected {
  border-color: var(--brand);
  background: var(--brand-soft);
  color: var(--brand-deep);
  box-shadow: 0 0 0 1px var(--brand);
}

.option.selected .option-letter {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}

.exam-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.q-dots {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  margin: 16px auto 0;
  justify-content: center;
  max-width: 620px;
}

.q-dot {
  width: 27px;
  height: 27px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted);
  font-size: 10.5px;
  font-weight: 650;
  cursor: pointer;
  transition: all 0.15s ease;
}

.q-dot:hover {
  border-color: var(--line-strong);
}

.q-dot.answered {
  background: var(--green-soft);
  border-color: #d3e0bf;
  color: var(--green);
}

.q-dot.current {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff8ee;
}

.exam-side-note {
  margin-top: 16px;
  text-align: center;
  font-size: 11px;
  color: var(--muted);
}

.timer-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 11px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--line);
  font-size: 11.5px;
  font-weight: 650;
  color: var(--ink-soft);
}

.timer-pill .ico {
  width: 13px;
  height: 13px;
  color: var(--brand);
}

/* Result */

.result-hero {
  display: flex;
  align-items: center;
  gap: 30px;
  padding: 32px 34px;
  border-radius: 20px;
  border: 1px solid var(--line);
  background:
    radial-gradient(500px 240px at 90% 0%, rgba(201, 156, 89, 0.13), transparent 70%),
    var(--surface);
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.score-ring {
  position: relative;
  width: 132px;
  height: 132px;
  flex: 0 0 132px;
}

.score-ring svg {
  transform: rotate(-90deg);
}

.score-ring .ring-bg {
  stroke: #eee4d5;
}

.score-ring .ring-val {
  stroke: var(--brand);
  transition: stroke-dashoffset 0.8s ease;
}

.score-ring.pass .ring-val { stroke: var(--green); }

.score-ring-inner {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.score-ring-inner b {
  font-family: var(--serif);
  font-size: 38px;
  font-weight: 500;
}

.score-ring-inner span {
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
  margin-top: 5px;
}

.result-copy {
  flex: 1;
  min-width: 220px;
}

.result-copy h1 {
  font-family: var(--serif);
  font-size: clamp(26px, 3vw, 36px);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 8px 0 6px;
}

.result-copy p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.result-meta {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 13px;
}

.result-note {
  padding: 15px 18px;
  border-radius: 11px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  font-size: 12.5px;
  color: var(--ink-soft);
  margin-bottom: 16px;
}

.result-note b {
  display: block;
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 5px;
}

.answer-review {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.answer-item {
  padding: 16px 18px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface);
}

.answer-item.correct {
  border-left: 3px solid #7c9b58;
}

.answer-item.wrong {
  border-left: 3px solid #cf6c60;
}

.answer-q {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
}

.answer-q .mark {
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  margin-top: 1px;
}

.answer-q .mark .ico {
  width: 12px;
  height: 12px;
}

.answer-item.correct .mark { background: var(--green-soft); color: var(--green); }
.answer-item.wrong .mark { background: var(--danger-soft); color: var(--danger); }

.answer-detail {
  margin-top: 9px;
  padding-left: 30px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 11.5px;
  color: var(--muted);
}

.answer-detail b {
  color: var(--ink-soft);
  font-weight: 600;
}

.answer-explanation {
  margin-top: 8px;
  padding: 9px 11px;
  border-radius: 8px;
  background: var(--surface-2);
  font-size: 11.5px;
  line-height: 1.5;
  color: var(--muted);
}

/* ---------------------------------------------------------------
   Supervision
   --------------------------------------------------------------- */

.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}

.stat-card {
  padding: 17px 18px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}

.stat-card .stat-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.stat-card .stat-label {
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.stat-card b {
  display: block;
  font-family: var(--serif);
  font-size: 30px;
  font-weight: 500;
  line-height: 1;
  margin-top: 9px;
}

.stat-card .stat-sub {
  font-size: 10.5px;
  color: var(--muted);
  margin-top: 5px;
}

.stat-card.live { background: linear-gradient(150deg, #fffaf3, #fdf0e2); border-color: #efd7bd; }
.stat-card.review { background: linear-gradient(150deg, #fffdf5, #fbf3dd); border-color: #ebdfbd; }

.pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #c2562d;
  box-shadow: 0 0 0 0 rgba(194, 86, 45, 0.5);
  animation: pulse 1.8s infinite;
}

@keyframes pulse {
  70% { box-shadow: 0 0 0 8px rgba(194, 86, 45, 0); }
  100% { box-shadow: 0 0 0 0 rgba(194, 86, 45, 0); }
}

.live-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 12px;
}

.live-card {
  padding: 16px 17px;
  border-radius: 13px;
  background: linear-gradient(160deg, #fffdf8, #fdf5e8);
  border: 1px solid #eddcc5;
  box-shadow: var(--shadow-sm);
}

.live-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.live-card-top .pill {
  font-size: 9.5px;
}

.live-card h3 {
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 500;
  margin-top: 11px;
}

.live-card .exam-name {
  font-size: 11.5px;
  color: var(--muted);
  margin-top: 2px;
}

.live-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px dashed var(--line-strong);
  font-size: 10.5px;
  color: var(--muted);
}

.data-table-wrap {
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
  min-width: 640px;
}

.data-table th {
  text-align: left;
  padding: 11px 16px;
  font-size: 9.5px;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
  background: var(--surface-2);
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.data-table td {
  padding: 12px 16px;
  border-bottom: 1px solid #f0e8da;
  vertical-align: middle;
  color: var(--ink-soft);
}

.data-table tbody tr:last-child td {
  border-bottom: 0;
}

.data-table tbody tr:hover {
  background: #fdf9f1;
}

.data-table .cell-main {
  display: flex;
  align-items: center;
  gap: 9px;
}

.data-table .cell-main strong {
  display: block;
  color: var(--ink);
  font-weight: 650;
  font-size: 12.5px;
}

.data-table .cell-main small {
  display: block;
  color: var(--muted);
  font-size: 10.5px;
  margin-top: 1px;
}

.table-actions {
  display: flex;
  gap: 5px;
  justify-content: flex-end;
}

.review-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 16px;
  align-items: start;
}

.roster-card {
  padding: 4px 0;
}

.roster-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 18px;
  border-bottom: 1px solid #f0e8da;
}

.roster-row:last-child {
  border-bottom: 0;
}

.roster-row .grow {
  flex: 1;
  min-width: 0;
}

.roster-row strong {
  display: block;
  font-size: 12.5px;
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.roster-row small {
  display: block;
  font-size: 10px;
  color: var(--muted);
  margin-top: 1px;
}

.roster-score {
  font-family: var(--serif);
  font-size: 19px;
  color: var(--ink-soft);
  text-align: right;
}

.roster-score small {
  display: block;
  font-family: var(--sans);
  font-size: 8.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 0;
}

/* ---------------------------------------------------------------
   Manager console
   --------------------------------------------------------------- */

.tabs {
  display: flex;
  gap: 2px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 22px;
  overflow-x: auto;
  scrollbar-width: none;
}

.tabs::-webkit-scrollbar {
  display: none;
}

.tab {
  padding: 10px 15px 12px;
  color: var(--muted);
  font-size: 12.5px;
  font-weight: 600;
  border-bottom: 2px solid transparent;
  white-space: nowrap;
  margin-bottom: -1px;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.tab:hover {
  color: var(--ink-soft);
}

.tab.active {
  color: var(--brand-deep);
  border-bottom-color: var(--brand);
}

.tab .tab-count {
  display: inline-block;
  margin-left: 5px;
  padding: 1px 5px;
  border-radius: 5px;
  background: var(--surface-2);
  font-size: 9.5px;
  color: var(--muted);
}

.two-col {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.8fr);
  gap: 16px;
  align-items: start;
}

.stat-grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.mini-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.mini-stat {
  padding: 12px;
  border-radius: 10px;
  background: var(--surface-2);
  border: 1px solid var(--line);
}

.mini-stat b {
  display: block;
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 500;
  line-height: 1;
}

.mini-stat span {
  display: block;
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 4px;
  font-weight: 700;
}

.attention-list {
  display: flex;
  flex-direction: column;
}

.attention-row {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 13px 20px;
  border-bottom: 1px solid #f0e8da;
}

.attention-row:last-child {
  border-bottom: 0;
}

.attention-row .a-ico {
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: var(--gold-soft);
  color: #8a6416;
}

.attention-row .a-ico .ico {
  width: 15px;
  height: 15px;
}

.attention-row .grow {
  flex: 1;
  min-width: 0;
}

.attention-row strong {
  display: block;
  font-size: 12.5px;
  font-weight: 650;
}

.attention-row small {
  display: block;
  font-size: 10.5px;
  color: var(--muted);
  margin-top: 1px;
}

.timeline {
  display: flex;
  flex-direction: column;
  padding: 4px 20px 8px;
}

.timeline-row {
  position: relative;
  display: flex;
  gap: 13px;
  padding: 12px 0;
}

.timeline-row:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 27px;
  bottom: -12px;
  width: 1px;
  background: var(--line);
}

.timeline-dot {
  width: 11px;
  height: 11px;
  flex: 0 0 11px;
  border-radius: 50%;
  border: 2px solid var(--surface);
  background: var(--brand);
  box-shadow: 0 0 0 1px var(--line-strong);
  margin-top: 4px;
}

.timeline-content {
  flex: 1;
  min-width: 0;
}

.timeline-content p {
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--ink-soft);
}

.timeline-content small {
  display: block;
  font-size: 10px;
  color: var(--muted);
  margin-top: 3px;
}

.table-card {
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.table-tools {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  flex-wrap: wrap;
  background: rgba(250, 244, 233, 0.4);
}

.table-tools .search-box {
  max-width: 320px;
}

.table-tools .select {
  width: auto;
  min-width: 130px;
  font-size: 12px;
  padding: 8px 30px 8px 11px;
}

.count-label {
  font-size: 11px;
  color: var(--muted);
  margin-left: auto;
  white-space: nowrap;
}

.exam-manage-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 13px;
}

.exam-manage-card {
  padding: 19px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
}

.exam-manage-card h3 {
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 500;
  margin: 11px 0 5px;
  line-height: 1.25;
}

.exam-manage-card .desc {
  font-size: 11.5px;
  color: var(--muted);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.exam-manage-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #f0e8da;
}

.exam-manage-foot .small {
  font-size: 10.5px;
  color: var(--muted);
}

.team-form {
  display: flex;
  gap: 8px;
  align-items: flex-end;
  flex-wrap: wrap;
  padding: 16px;
  border-bottom: 1px solid var(--line);
  background: rgba(250, 244, 233, 0.4);
}

.team-form .field {
  flex: 1;
  min-width: 170px;
}

.team-form .select {
  width: 140px;
}

.settings-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: 16px;
  align-items: start;
}

/* ---------------------------------------------------------------
   Account
   --------------------------------------------------------------- */

.account-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: 16px;
  align-items: start;
}

.profile-card {
  padding: 24px;
  border-radius: var(--radius);
  background:
    radial-gradient(400px 200px at 100% 0%, rgba(211, 154, 61, 0.1), transparent 70%),
    var(--surface);
  border: 1px solid var(--line);
}

.profile-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.profile-head h2 {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 500;
  line-height: 1.2;
}

.profile-head p {
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

.profile-rows {
  display: flex;
  flex-direction: column;
  padding-top: 7px;
}

.profile-row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 0;
  border-bottom: 1px solid #f2ebdd;
  font-size: 12px;
}

.profile-row:last-child {
  border-bottom: 0;
}

.profile-row span {
  color: var(--muted);
}

.profile-row b {
  font-weight: 650;
  text-align: right;
  color: var(--ink-soft);
}

.allergen-pick {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.allergen-pick .chip-check {
  position: relative;
  display: inline-flex;
}

.allergen-pick input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.allergen-pick label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.allergen-pick label:hover {
  border-color: var(--line-strong);
  background: var(--surface-2);
}

.allergen-pick input:checked + label {
  background: var(--brand-soft);
  border-color: #e8c4b1;
  color: var(--brand-deep);
}

.fav-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
}

.fav-card {
  position: relative;
  display: flex;
  gap: 11px;
  padding: 13px;
  border-radius: 11px;
  background: var(--surface);
  border: 1px solid var(--line);
  transition: border-color 0.15s ease;
}

.fav-card:hover {
  border-color: var(--line-strong);
}

.fav-tile {
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  font-size: 20px;
  background: var(--surface-2);
}

.fav-card h4 {
  font-family: var(--serif);
  font-size: 15px;
  font-weight: 500;
  line-height: 1.25;
  padding-right: 20px;
}

.fav-card small {
  display: block;
  font-size: 10px;
  color: var(--muted);
  margin-top: 2px;
}

.fav-remove {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 22px;
  height: 22px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  display: grid;
  place-items: center;
  cursor: pointer;
}

.fav-remove:hover {
  background: var(--danger-soft);
  color: var(--danger);
}

.fav-remove .ico {
  width: 12px;
  height: 12px;
}

/* ---------------------------------------------------------------
   Modal
   --------------------------------------------------------------- */

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  padding: 24px;
  background: rgba(28, 22, 16, 0.48);
  backdrop-filter: blur(5px);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  overflow-y: auto;
  animation: fade-in 0.18s ease both;
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal {
  width: 100%;
  max-width: 560px;
  margin: auto;
  background: var(--surface);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: var(--shadow-lg);
  animation: modal-in 0.22s cubic-bezier(0.2, 0.8, 0.3, 1) both;
  overflow: hidden;
}

@keyframes modal-in {
  from { opacity: 0; transform: translateY(14px) scale(0.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.modal-wide {
  max-width: 940px;
}

.modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 20px 24px 16px;
  border-bottom: 1px solid var(--line);
}

.modal-head h2 {
  font-family: var(--serif);
  font-size: 23px;
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.2;
}

.modal-head p {
  font-size: 12px;
  color: var(--muted);
  margin-top: 4px;
}

.modal-close {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--muted);
  display: grid;
  place-items: center;
  cursor: pointer;
}

.modal-close:hover {
  background: var(--surface-2);
  color: var(--ink);
}

.modal-close .ico {
  width: 14px;
  height: 14px;
}

.modal-body {
  padding: 22px 24px;
  max-height: calc(100vh - 220px);
  overflow-y: auto;
}

.modal-foot {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 15px 24px;
  border-top: 1px solid var(--line);
  background: var(--surface-2);
  flex-wrap: wrap;
}

.modal-foot .spacer {
  margin-right: auto;
}

.modal-note {
  font-size: 11.5px;
  color: var(--muted);
  line-height: 1.5;
}

.ingredient-row {
  display: grid;
  grid-template-columns: minmax(120px, 1.2fr) minmax(70px, 0.5fr) minmax(120px, 1fr) minmax(110px, 0.8fr) 30px;
  gap: 6px;
  align-items: start;
  margin-bottom: 7px;
}

.ingredient-row .input {
  padding: 8px 9px;
  font-size: 12px;
}

.ingredient-row .row-remove {
  width: 30px;
  height: 33px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--muted);
  cursor: pointer;
  display: grid;
  place-items: center;
}

.ingredient-row .row-remove:hover {
  background: var(--danger-soft);
  border-color: #eccbc4;
  color: var(--danger);
}

.ingredient-row .row-remove .ico {
  width: 13px;
  height: 13px;
}

.row-label {
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
  margin-bottom: 3px;
}

.chip-select {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.chip-check {
  position: relative;
}

.chip-check input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.chip-check span {
  display: inline-flex;
  align-items: center;
  padding: 4px 9px;
  border-radius: 7px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-soft);
  font-size: 10.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.13s ease;
  user-select: none;
}

.chip-check span:hover {
  border-color: var(--line-strong);
}

.chip-check input:checked + span {
  background: var(--brand-soft);
  border-color: #e8c4b1;
  color: var(--brand-deep);
}

.chip-check.warn input:checked + span {
  background: var(--gold-soft);
  border-color: #e8d7ac;
  color: #7d5a13;
}

.question-block {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 15px;
  margin-bottom: 10px;
  background: var(--surface-2);
}

.question-block-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.question-block-head .q-label {
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
}

.option-edit-row {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 6px;
}

.option-edit-row input[type="radio"] {
  width: 15px;
  height: 15px;
  accent-color: var(--brand);
  flex: 0 0 15px;
  margin: 0;
}

.option-edit-row .input {
  padding: 7px 9px;
  font-size: 12px;
}

.option-edit-row .opt-tag {
  font-size: 9px;
  color: var(--muted);
  font-weight: 700;
  width: 12px;
  flex: 0 0 12px;
  text-align: center;
}

.review-summary {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 13px 15px;
  border-radius: 10px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  margin-bottom: 14px;
}

.review-summary .rs {
  flex: 1;
  min-width: 90px;
}

.review-summary .rs span {
  display: block;
  font-size: 9px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
}

.review-summary .rs b {
  display: block;
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 500;
  margin-top: 3px;
}

.review-answers {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 340px;
  overflow-y: auto;
  padding-right: 3px;
}

.review-answer {
  padding: 11px 13px;
  border-radius: 9px;
  border: 1px solid var(--line);
  font-size: 12px;
}

.review-answer.correct { border-left: 3px solid #7c9b58; }
.review-answer.wrong { border-left: 3px solid #cf6c60; }
.review-answer.skipped { border-left: 3px solid #cfb267; }

.review-answer .ra-q {
  font-weight: 600;
  color: var(--ink);
  line-height: 1.4;
}

.review-answer .ra-a {
  font-size: 11px;
  color: var(--muted);
  margin-top: 4px;
}

.review-answer .ra-a b {
  color: var(--ink-soft);
  font-weight: 600;
}

.review-answer .ra-a .ok { color: var(--green); }
.review-answer .ra-a .no { color: var(--danger); }

/* ---------------------------------------------------------------
   Errors
   --------------------------------------------------------------- */

.error-page {
  padding: 70px 20px;
  text-align: center;
}

.error-page .big {
  font-family: var(--serif);
  font-size: 72px;
  line-height: 1;
  color: var(--line-strong);
}

.error-page h1 {
  font-family: var(--serif);
  font-size: 28px;
  font-weight: 500;
  margin: 12px 0 6px;
}

.error-page p {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 20px;
}

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

@media (max-width: 1180px) {
  .hero {
    grid-template-columns: 1fr;
    padding: 40px;
  }
  .hero-art {
    display: none;
  }
  .role-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .restaurant-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .detail-grid,
  .review-layout,
  .two-col,
  .settings-grid {
    grid-template-columns: 1fr;
  }
  .account-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 980px) {
  :root {
    --sidebar: 240px;
  }
  .view {
    padding: 26px 24px 60px;
  }
  .topbar {
    padding: 0 24px;
  }
  .stat-strip,
  .stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .auth-wrap {
    grid-template-columns: 1fr;
  }
  .auth-art {
    padding: 30px 32px;
    gap: 18px;
  }
  .auth-art p {
    max-width: none;
  }
  .auth-points {
    display: none;
  }
}

@media (max-width: 860px) {
  .sidebar {
    transform: translateX(-100%);
    transition: transform 0.24s cubic-bezier(0.2, 0.8, 0.3, 1);
    width: 280px;
    box-shadow: var(--shadow-lg);
  }
  body.nav-open .sidebar {
    transform: translateX(0);
  }
  body.nav-open .scrim {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 35;
    background: rgba(28, 22, 16, 0.45);
    backdrop-filter: blur(2px);
  }
  .main-area {
    margin-left: 0;
  }
  .menu-btn {
    display: inline-grid !important;
  }
  .topbar-title span {
    display: none;
  }
  .hero {
    padding: 32px 28px;
  }
  .restaurant-hero {
    padding: 26px;
  }
  .topbar-actions .role-pill {
    display: none;
  }
}

@media (max-width: 720px) {
  .view {
    padding: 20px 16px 54px;
  }
  .topbar {
    height: 58px;
    padding: 0 14px;
  }
  .topbar-title {
    font-size: 15px;
  }
  .hero {
    border-radius: 18px;
    padding: 26px 22px;
  }
  .hero h1 {
    font-size: clamp(31px, 8.5vw, 42px);
  }
  .hero-copy > p {
    font-size: 14px;
  }
  .hero-trust {
    gap: 12px;
  }
  .stat-strip,
  .stat-grid,
  .role-grid {
    grid-template-columns: 1fr 1fr;
  }
  .stat {
    padding: 13px;
    gap: 9px;
  }
  .stat b {
    font-size: 20px;
  }
  .stat-icon {
    width: 30px;
    height: 30px;
    flex-basis: 30px;
  }
  .restaurant-grid,
  .exam-grid,
  .live-grid {
    grid-template-columns: 1fr;
  }
  .page-title {
    font-size: 28px;
  }
  .page-head {
    align-items: flex-start;
  }
  .item-hero {
    padding: 20px;
    gap: 16px;
  }
  .item-emoji {
    width: 68px;
    height: 68px;
    flex-basis: 68px;
    font-size: 36px;
  }
  .item-hero-main h1 {
    font-size: 27px;
  }
  .item-hero-actions {
    width: 100%;
  }
  .toolbar {
    padding: 11px;
  }
  .toolbar .select {
    min-width: 0;
    flex: 1;
  }
  .question-card {
    padding: 20px 18px;
  }
  .result-hero {
    padding: 24px;
    gap: 20px;
  }
  .score-ring {
    width: 104px;
    height: 104px;
    flex-basis: 104px;
  }
  .score-ring-inner b {
    font-size: 30px;
  }
  .auth-panel {
    padding: 28px 22px;
  }
  .auth-art {
    padding: 26px 22px;
  }
  .modal-backdrop {
    padding: 10px;
  }
  .modal-body {
    max-height: calc(100vh - 190px);
    padding: 18px;
  }
  .modal-head,
  .modal-foot {
    padding-left: 18px;
    padding-right: 18px;
  }
  .ingredient-row {
    grid-template-columns: 1fr 1fr 30px;
  }
  .ingredient-row .ing-note-field {
    grid-column: span 2;
  }
  .ingredient-row .ing-allergen-field {
    grid-column: span 2;
  }
  .form-grid,
  .form-grid.three {
    grid-template-columns: 1fr;
  }
  .form-grid .span-2 {
    grid-column: span 1;
  }
  .ing-table td:last-child {
    width: 28%;
  }
  .mini-stats {
    grid-template-columns: repeat(3, 1fr);
  }
  .results-line {
    margin-top: 14px;
  }
}

@media (max-width: 520px) {
  .stat-strip,
  .stat-grid,
  .role-grid {
    grid-template-columns: 1fr;
  }
  .hero-actions .btn {
    width: 100%;
  }
  .demo-grid {
    grid-template-columns: 1fr;
  }
  .type-toggle {
    grid-template-columns: 1fr;
  }
  .topbar-actions .btn-ghost {
    display: none;
  }
  .item-hero-actions .btn {
    flex: 1;
  }
  .q-dots {
    gap: 4px;
  }
  .q-dot {
    width: 23px;
    height: 23px;
    font-size: 9.5px;
  }
  .exam-run-head {
    gap: 8px;
  }
  .team-form .select {
    width: 100%;
  }
  .table-tools .search-box {
    max-width: none;
    width: 100%;
  }
  .modal-foot {
    flex-direction: column-reverse;
    align-items: stretch;
  }
  .modal-foot .btn {
    width: 100%;
  }
  .modal-foot .spacer {
    display: none;
  }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---------------------------------------------------------------
   Print — kitchen spec sheet
   --------------------------------------------------------------- */

@media print {
  body {
    background: #fff;
    font-size: 11pt;
  }
  .sidebar,
  .topbar,
  .scrim,
  .toasts,
  .detail-back,
  .item-hero-actions,
  .allergen-banner.info,
  .footer,
  .modal-backdrop {
    display: none !important;
  }
  .main-area {
    margin-left: 0;
  }
  .view {
    max-width: none;
    padding: 0;
  }
  .item-hero,
  .panel,
  .card,
  .detail-grid {
    box-shadow: none;
    border-color: #bbb;
  }
  .detail-grid {
    display: block;
  }
  .detail-side {
    margin-top: 12px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  .print-only {
    display: block;
    margin-bottom: 10px;
    font-size: 9pt;
    color: #666;
  }
  .panel {
    break-inside: avoid;
  }
}
