html:has(body[data-restaurant-theme]) { background: #101616; color-scheme: dark; }
html:has(body[data-restaurant-theme='light']) { background: #fbf6f0; color-scheme: light; }

/* Shared Bambsh palette, sourced from bambshrestaurant.com.au. Other tenants keep their branding. */
body[data-restaurant-theme] {
  color-scheme: dark;
  --restaurant-bg: #101616;
  --restaurant-surface: #19201f;
  --restaurant-card: #202624;
  --restaurant-text: #e5bc96;
  --restaurant-muted: #bca58e;
  --restaurant-accent: #d5a071;
  --restaurant-bronze: #b78253;
  --restaurant-line: rgb(205 151 104 / 38%);
  --restaurant-soft: #302b24;
  --restaurant-glow: rgb(183 130 83 / 16%);
  --restaurant-glass: rgb(25 32 31 / 94%);
  --restaurant-error: #ffb1a5;
  --restaurant-shadow: 0 16px 48px rgb(0 0 0 / 18%);
  --restaurant-button: linear-gradient(135deg, #e5bc96, #d5a071 55%, #c28c5d);
  --ink: var(--restaurant-text);
  --muted: var(--restaurant-muted);
  --line: var(--restaurant-line);
  --paper: var(--restaurant-bg);
  --white: var(--restaurant-surface);
  --blue: var(--restaurant-accent);
  --green: var(--restaurant-accent);
  --lime: var(--restaurant-soft);
  --shadow: var(--restaurant-shadow);
  background: var(--restaurant-bg);
  color: var(--restaurant-text);
  min-height: 100dvh;

  &[data-restaurant-theme='light'] {
    color-scheme: light;
    --restaurant-bg: #fbf6f0;
    --restaurant-surface: #fffcf8;
    --restaurant-card: #fff9f1;
    --restaurant-text: #30271f;
    --restaurant-muted: #74604d;
    --restaurant-accent: #8c522b;
    --restaurant-line: rgb(157 104 60 / 38%);
    --restaurant-soft: #f1dfca;
    --restaurant-glow: rgb(213 160 113 / 24%);
    --restaurant-glass: rgb(255 252 248 / 95%);
    --restaurant-error: #a8332d;
    --restaurant-shadow: 0 16px 48px rgb(90 53 25 / 9%);
  }

}

body.guest-view[data-restaurant-theme] {
  :is(button, a, input, textarea, select):focus-visible {
    outline-color: var(--restaurant-accent);
  }
  ::selection { background: #d5a071; color: #101616; }
  :is(input, select, textarea) {
    background-color: var(--restaurant-surface);
    color: var(--restaurant-text);
    border-color: var(--restaurant-line);
  }
  input::placeholder, textarea::placeholder { color: var(--restaurant-muted); opacity: 1; }
  input[type='checkbox'], input[type='radio'] { accent-color: var(--restaurant-accent); }
  .btn, .iconbtn {
    background: var(--restaurant-surface);
    border-color: var(--restaurant-line);
    color: var(--restaurant-text);
  }
  :is(.btn.primary, .hero-cta, .food-add, .chooser-find) {
    background: var(--restaurant-button);
    border: 1px solid #b78253;
    color: #101616;
    box-shadow: 0 5px 18px rgb(183 130 83 / 15%);
  }
  :is(.btn.primary, .hero-cta, .food-add, .chooser-find):hover {
    background: var(--restaurant-button);
    filter: brightness(1.06);
  }
  .btn:disabled, .food-add:disabled { box-shadow: none; }

  /* Gentle copper washes and fine bronze outlines echo the supplied reference. */
  .guest-menu {
    background:
      radial-gradient(ellipse 80% 480px at 5% 900px, var(--restaurant-glow), transparent),
      radial-gradient(ellipse 70% 800px at 100% 55%, var(--restaurant-glow), transparent),
      var(--restaurant-bg);
  }
  .food-hero { background: #101616; color: #e5bc96; }
  .hero-shade {
    background:
      linear-gradient(0deg, var(--restaurant-bg), transparent 30%),
      linear-gradient(90deg, rgb(16 22 22 / 94%), rgb(16 22 22 / 65%) 45%, rgb(16 22 22 / 12%));
  }
  .food-hero-copy h1 { color: #f7e3cd; }
  .food-hero-copy h1 em, .hero-kicker { color: #e5bc96; }
  .food-hero-copy p { color: #f0dfcd; }
  .restaurant-wordmark, .restaurant-wordmark strong span { color: #e5bc96; }
  .hero-service {
    background: rgb(16 22 22 / 80%);
    color: #e5bc96;
    border-block: 1px solid rgb(205 151 104 / 25%);
  }
  .guest-top-actions { align-items: center; }
  .guest-top-actions .btn, .tracking-table {
    background: rgb(16 22 22 / 80%);
    color: #e5bc96;
    border: 1px solid rgb(205 151 104 / 60%);
    backdrop-filter: blur(12px);
  }
  .guest-top-actions .theme-control {
    min-width: 44px;
    min-height: 44px;
    gap: 8px;
  }
  .guest-top-actions .theme-control:hover { background: #302b24; }
  .tracking-hero .guest-top-actions { flex-wrap: wrap; justify-content: flex-end; }
  .tracking-hero .tracking-table { max-width: none; }
  .guest-nav-wrap {
    background: var(--restaurant-glass);
    border-color: var(--restaurant-line);
  }
  .guest-nav .btn, .carousel-control {
    background: var(--restaurant-surface);
    color: var(--restaurant-text);
    border: 1px solid var(--restaurant-line);
  }
  .guest-nav .btn:hover, .carousel-control:hover {
    background: var(--restaurant-soft);
    color: var(--restaurant-accent);
  }
  .guest-nav .full-menu { background: var(--restaurant-soft); color: var(--restaurant-accent); }
  .guest-nav .nav-search { background: transparent; }
  .food-section { border-color: var(--restaurant-line); }
  .section-kicker, .blue-dot, .section-count { color: var(--restaurant-accent); }
  .section-heading p { color: var(--restaurant-muted); }
  .section-count { border-color: var(--restaurant-line); background: var(--restaurant-soft); }
  .food-card {
    padding: 10px;
    border: 1px solid var(--restaurant-line);
    border-radius: 28px;
    background: linear-gradient(155deg, var(--restaurant-surface) 20%, var(--restaurant-soft));
    box-shadow: inset 0 1px 0 rgb(229 188 150 / 7%);
  }
  .food-art { border-radius: 20px; background: var(--restaurant-card); }
  .food-info { padding: 16px 6px 10px; }
  .food-info h3 { color: var(--restaurant-text); }
  .food-info p { color: var(--restaurant-accent); }
  .food-info p span, .food-info small { color: var(--restaurant-muted); }
  .food-badge {
    background: var(--restaurant-glass);
    color: var(--restaurant-text);
    border: 1px solid var(--restaurant-line);
  }
  .menu-help-actions .menu-help-tile, .chooser-tile {
    border: 1px solid var(--restaurant-line);
    background: radial-gradient(ellipse at bottom right, var(--restaurant-glow), transparent 80%), var(--restaurant-surface);
    color: var(--restaurant-text);
  }
  .menu-help-actions .menu-help-tile:hover { background: var(--restaurant-soft); }
  .menu-help-tile .icon, .chooser-tile-link, .chooser-tile-copy > strong > span { color: var(--restaurant-accent); }
  .menu-help-tile span { font-size: 0.875rem; color: var(--restaurant-muted); }
  .guest-search label { background: var(--restaurant-surface); border-color: var(--restaurant-line); }
  .guest-search input { background: transparent; }
  .guest-menu .text-button, .guest-dialog .text-button { background: transparent; color: var(--restaurant-accent); }
  .menu-note, .menu-end p, .menu-end small { color: var(--restaurant-muted); }
  .guest-footer {
    border-top: 1px solid var(--restaurant-line);
    background: radial-gradient(ellipse at bottom left, var(--restaurant-glow), transparent 65%), var(--restaurant-surface);
    color: var(--restaurant-text);
  }
  .guest-footer :is(.section-kicker, h2 span, .footer-contact a) { color: var(--restaurant-accent); }
  .guest-footer p, .footer-bottom { color: var(--restaurant-muted); }
  .footer-bottom { border-color: var(--restaurant-line); }
  .guest-menu .footer-menu { color: var(--restaurant-text); border-color: var(--restaurant-line); background: transparent; }
  .guest-cart-dock {
    background: var(--restaurant-glass);
    border-color: var(--restaurant-line);
    box-shadow: var(--restaurant-shadow);
  }
  .guest-cart-dock .dock-count { color: var(--restaurant-accent); background: var(--restaurant-soft); }
  .guest-cart-dock small { color: var(--restaurant-muted); }

  /* Sheets, modifiers, seating, cart and checkout inherit the same appearance. */
  .guest-dialog {
    --green: var(--restaurant-accent);
    --line: var(--restaurant-line);
    background: var(--restaurant-surface);
    color: var(--restaurant-text);
    border: 1px solid var(--restaurant-line);
    box-shadow: var(--restaurant-shadow);
  }
  .guest-dialog::backdrop { background: rgb(8 13 12 / 72%); backdrop-filter: blur(5px); }
  .guest-dialog :is(.dialog-head, .dialog-footer) { border-color: var(--restaurant-line); background: var(--restaurant-surface); }
  .guest-dialog :is(input, textarea, select) { border-color: var(--restaurant-line); }
  .guest-dialog .basket { background: transparent; }
  .guest-dialog .quantity button { background: var(--restaurant-soft); color: var(--restaurant-accent); }
  .guest-dialog :is(.alert, .banquet-context, .banquet-requirement, .cart-existing) {
    background: var(--restaurant-soft); border-color: var(--restaurant-line); color: var(--restaurant-text);
  }
  .guest-dialog :is(.form-error, .checkout-error), .chooser-error { color: var(--restaurant-error); }
  .guest-dialog :is(.total-row, .basket-line, .modifier-group, .banquet-portion, .cart-seating-form) { border-color: var(--restaurant-line); }
  .table-confirm-symbol { background: var(--restaurant-soft); color: var(--restaurant-accent); }
  .guest-item-name { color: var(--restaurant-accent); }
  .guest-item-group { border-color: var(--restaurant-line); }
  .checkout-line small, .group-order-intro { color: var(--restaurant-muted); }
  .menu-category-picker .btn { background: var(--restaurant-card); color: var(--restaurant-text); border-color: var(--restaurant-line); }
  .menu-category-picker span { color: var(--restaurant-muted); }
  .product-dialog, .product-intro { background: var(--restaurant-surface); color: var(--restaurant-text); }
  .product-hero-image::after {
    background: linear-gradient(180deg, transparent 40%, var(--restaurant-surface) 100%);
  }
  .product-intro-copy h2 { color: var(--restaurant-text); }
  .product-base-price { color: var(--restaurant-accent); }
  .product-base-price span, .product-description { color: var(--restaurant-muted); }
  .product-close, .chooser-close {
    background: var(--restaurant-glass); color: var(--restaurant-text); border: 1px solid var(--restaurant-line);
  }
  .product-options {
    border-top: 1px solid var(--restaurant-line);
    background: linear-gradient(165deg, var(--restaurant-surface), var(--restaurant-soft));
    color: var(--restaurant-text);
  }
  .product-action-bar .product-submit { box-shadow: 0 6px 25px rgb(16 22 22 / 24%); }
  .product-recommendations { border-color: var(--restaurant-line); }
  .recommendation-heading > span, .product-recommendations > p, .recommendation-card > span:last-child { color: var(--restaurant-muted); }
  .recommendation-rail { scrollbar-color: var(--restaurant-bronze) transparent; }
  .recommendation-card input:checked + .recommendation-image,
  .recommendation-card input:focus-visible + .recommendation-image { outline-color: var(--restaurant-accent); }
  .recommendation-card input:checked + .recommendation-image .recommendation-check { background: #d5a071; color: #101616; }

  /* Help me choose has its own controls and keeps the active guest preference. */
  .guest-dialog.chooser-dialog { --chooser-blue: var(--restaurant-accent); --chooser-cream: var(--restaurant-surface); }
  .chooser-panel { background: var(--restaurant-surface); }
  .chooser-hero::after { background: linear-gradient(0deg, #101616, #10161670 50%, transparent); }
  .chooser-hero h2 { color: #f7e3cd; }
  .chooser-hero-copy > p { color: #e5bc96; }
  .chooser-photo-note, .chooser-question > p, .chooser-choice-face small,
  .chooser-results-head > p, .chooser-result-group > p, .chooser-result-copy p,
  .chooser-footer small, .chooser-tile-copy > span:not(.chooser-eyebrow):not(.chooser-tile-link) { color: var(--restaurant-muted); }
  .chooser-question legend > span, .chooser-stepper button, .chooser-review {
    background: var(--restaurant-soft); color: var(--restaurant-accent); border-color: var(--restaurant-line);
  }
  .chooser-counter, .chooser-choice-face, .chooser-result-card, .chooser-footer {
    background: var(--restaurant-card); color: var(--restaurant-text); border-color: var(--restaurant-line);
  }
  .chooser-dialog .chooser-stepper input { color: var(--restaurant-text); }
  .chooser-stepper button:disabled { background: var(--restaurant-card); color: var(--restaurant-muted); opacity: 0.5; }
  .chooser-choice input:checked + .chooser-choice-face {
    background: var(--restaurant-soft); border-color: var(--restaurant-accent); box-shadow: inset 0 0 0 0.5px var(--restaurant-accent);
  }
  .chooser-choice input:focus-visible + .chooser-choice-face { outline-color: var(--restaurant-accent); }
  .chooser-choice-check, .chooser-result-price, .chooser-result-copy .chooser-minimum, .chooser-results-head h3 > span { color: var(--restaurant-accent); }
  .chooser-results { border-color: var(--restaurant-line); }
  .chooser-note, .chooser-review-note, .chooser-empty { background: var(--restaurant-soft); color: var(--restaurant-muted); }

  /* Order tracking, including automatic refreshes and service notifications. */
  .guest-tracking {
    color-scheme: inherit;
    --tracking-blue: var(--restaurant-accent);
    background: radial-gradient(ellipse at top right, var(--restaurant-glow), transparent 60%), var(--restaurant-bg);
    color: var(--restaurant-text);
  }
  .tracking-hero { background: #101616; }
  .tracking-hero-shade {
    background: linear-gradient(0deg, #101616, #10161655 55%, #101616a0), linear-gradient(90deg, #101616a0, transparent);
  }
  .tracking-hero-copy h1 { color: #f7e3cd; }
  .tracking-hero-copy .hero-kicker { color: #e5bc96; }
  .tracking-hero-copy p { color: #f0dfcd; }
  .tracking-progress, .tracking-receipt {
    background: linear-gradient(145deg, var(--restaurant-surface), var(--restaurant-card));
    border-color: var(--restaurant-line); box-shadow: var(--restaurant-shadow);
  }
  .tracking-status-heading h2, .tracking-dish-copy h3, .tracking-dish > strong,
  .tracking-receipt h2, .tracking-receipt .total-row > strong, .tracking-receipt .total-row.final,
  .tracking-footer > p, .tracking-footer > span strong { color: var(--restaurant-text); }
  .tracking-status-pill, .tracking-eta, .guest-tracking .guest-item-name {
    background: var(--restaurant-soft); color: var(--restaurant-accent); border-color: var(--restaurant-line);
  }
  .tracking-steps > li:not(:last-child)::after { background: var(--restaurant-line); }
  .tracking-steps > li.complete::after { background: var(--restaurant-bronze); }
  .tracking-steps > li > span { background: var(--restaurant-card); color: var(--restaurant-muted); border-color: var(--restaurant-line); }
  .tracking-steps > li > strong { color: var(--restaurant-muted); }
  .tracking-steps > li.complete > span { background: var(--restaurant-soft); color: var(--restaurant-accent); border-color: var(--restaurant-line); }
  .tracking-steps > li.current > span { background: #d5a071; color: #101616; border-color: #d5a071; box-shadow: 0 0 0 5px var(--restaurant-soft); }
  .tracking-steps > li.complete > strong, .tracking-steps > li.current > strong,
  .tracking-eta .icon, .tracking-eta > strong, .tracking-receipt .total-row.final > strong { color: var(--restaurant-accent); }
  .tracking-live-note, .tracking-dishes .section-heading p, .tracking-dish-copy p,
  .tracking-receipt .total-row, .tracking-receipt > p, .tracking-footer { color: var(--restaurant-muted); border-color: var(--restaurant-line); }
  .tracking-live-note i { box-shadow: 0 0 0 3px var(--restaurant-soft); }
  .tracking-live-note .text-button { background: transparent; color: var(--restaurant-accent); text-decoration-color: var(--restaurant-bronze); }
  .guest-tracking .guest-item-group, .tracking-dish, .tracking-receipt .total-row.final { border-color: var(--restaurant-line); }
  .tracking-dish-photo { background: var(--restaurant-card); }
  .tracking-dish-photo > span { background: var(--restaurant-glass); color: var(--restaurant-text); border-color: var(--restaurant-line); }
  .tracking-action-dock { background: var(--restaurant-glass); border-color: var(--restaurant-line); color: var(--restaurant-text); box-shadow: var(--restaurant-shadow); }
  .tracking-dock-summary small { color: var(--restaurant-muted); }
  .tracking-dock-summary strong { color: var(--restaurant-text); }
  .tracking-action-dock > .tracking-call { background: var(--restaurant-soft); color: var(--restaurant-text); border-color: var(--restaurant-line); }
  .tracking-action-dock > .btn.primary { background: var(--restaurant-button); color: #101616; border-color: #b78253; }
  #service-banner, #toast { background: var(--restaurant-surface); color: var(--restaurant-text); border: 1px solid var(--restaurant-line); box-shadow: var(--restaurant-shadow); }
  #service-banner p { color: var(--restaurant-muted); }
  #service-banner .service-banner-icon { background: var(--restaurant-soft); color: var(--restaurant-accent); }
  #toast.error { color: var(--restaurant-error); }

  @media (max-width: 650px) {
    .guest-top-actions { gap: 6px; }
    .guest-top-actions .theme-control { width: 44px; padding: 0; flex-shrink: 0; }
    .theme-control > span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
    .restaurant-wordmark { min-width: 0; }
    .restaurant-wordmark img { width: 112px; }
    .food-card { padding: 7px; border-radius: 23px; }
    .food-art { border-radius: 17px; }
    .food-info { padding: 13px 5px 9px; }
    .menu-help-tile span { font-size: 0.75rem; white-space: normal; line-height: 1.5; }
    .tracking-hero .guest-top { gap: 10px; }
    .tracking-hero .restaurant-wordmark { max-width: 48%; }
    .tracking-hero .guest-top-actions { flex-wrap: nowrap; }
  }
  @media (max-width: 380px) {
    .guest-top { padding-inline: 14px; }
    .restaurant-wordmark strong { font-size: 1.7rem; }
    .guest-top-actions .table-control { padding-inline: 10px; }
    .table-control .icon { display: none; }
    .guest-top-actions .bag-control { padding-inline: 9px; }
    .tracking-hero .tracking-table { padding-inline: 9px; }
  }
}

/* Staff portals use the same copper palette; operational status colours stay distinct. */
body.staff-view[data-restaurant-theme] {
  --status-good-bg: #21372a;
  --status-good-ink: #b2d6b7;
  --status-warn-bg: #3c301c;
  --status-warn-ink: #ebcb8d;
  --status-danger-bg: #402827;
  --status-danger-ink: #f5b3a7;
  --status-hold-bg: #352d3e;
  --status-hold-ink: #d6bce7;
  background: radial-gradient(ellipse at 45% 0, var(--restaurant-glow), transparent 80%), var(--restaurant-bg);

  &[data-restaurant-theme='light'] {
    --status-good-bg: #e7f0e6;
    --status-good-ink: #326644;
    --status-warn-bg: #f7ecd7;
    --status-warn-ink: #7e591e;
    --status-danger-bg: #f8e5df;
    --status-danger-ink: #a44235;
    --status-hold-bg: #eee7f4;
    --status-hold-ink: #77518d;
  }

  :is(button, a, input, textarea, select):focus-visible { outline-color: var(--restaurant-accent); }
  ::selection { background: #d5a071; color: #101616; }
  :is(h1, h2, h3, .detail-line, .pos-product, .pin-keypad button) { color: var(--restaurant-text); }
  :is(input, textarea, select, .search, .pin-login-form select) {
    color: var(--restaurant-text);
    background: var(--restaurant-surface);
    border-color: var(--restaurant-line);
    accent-color: var(--restaurant-accent);
  }
  input::placeholder, textarea::placeholder { color: var(--restaurant-muted); opacity: 1; }
  .shell { background: var(--restaurant-bg); box-shadow: var(--restaurant-shadow); border: 1px solid var(--restaurant-line); }
  .sidebar {
    background: linear-gradient(155deg, #302b24, #19201f 75%);
    color: #e5bc96;
    border-right: 1px solid rgb(205 151 104 / 38%);
  }
  .pos-logo { background: #d5a071; color: #101616; }
  .nav-link { color: #e5bc96; }
  .nav-link.active, .nav-link:hover { background: rgb(213 160 113 / 18%); color: #f7e3cd; }
  .nav-link.active::before { background: #d5a071; }
  .topbar { background: var(--restaurant-glass); border-bottom: 1px solid var(--restaurant-line); gap: 16px; }
  .topbar .theme-control { flex-shrink: 0; min-height: 44px; }
  .pos-heading strong { overflow: hidden; text-overflow: ellipsis; }
  .notification-pill { color: var(--restaurant-text); border-color: var(--restaurant-line); background: var(--restaurant-surface); box-shadow: none; }
  .pos-date, .pos-heading small { color: var(--restaurant-muted); }
  .notification-pill b, .nav-dot { background: #b85c4c; color: #fff; }
  .page-head .eyebrow, .section-kicker { color: var(--restaurant-accent); }
  .btn, .iconbtn {
    background: var(--restaurant-surface); color: var(--restaurant-text);
    border-color: var(--restaurant-line); box-shadow: none;
  }
  :is(.btn.primary, .btn.lime, .tab.active, .kds-filter.active) {
    background: var(--restaurant-button); color: #101616; border-color: #b78253;
  }
  :is(.btn.primary, .btn.lime):hover { background: var(--restaurant-button); filter: brightness(1.06); }
  .btn.soft, .btn.blue { background: var(--restaurant-soft); color: var(--restaurant-accent); }
  .btn.green { background: var(--status-good-bg); color: var(--status-good-ink); }
  .btn.purple { background: var(--status-hold-bg); color: var(--status-hold-ink); }
  .btn.danger { background: var(--status-danger-bg); color: var(--status-danger-ink); }
  :is(.card, .stat, .menu-row, .table-wrap, .order-card, .payment-row, .pos-product, .pos-basket, .kds-ticket) {
    background: linear-gradient(145deg, var(--restaurant-surface), var(--restaurant-card));
    border-color: var(--restaurant-line); color: var(--restaurant-text); box-shadow: var(--restaurant-shadow);
  }
  .stat.highlight { background: linear-gradient(145deg, var(--restaurant-surface), var(--restaurant-soft)); border-color: var(--restaurant-line); }
  .stat-value, .stat.highlight .stat-icon { color: var(--restaurant-accent); }
  .stat-label { color: var(--restaurant-muted); }
  .stat-icon, .avatar, .stat.highlight .stat-icon, .table-number, .qty {
    background: var(--restaurant-soft); color: var(--restaurant-accent);
  }
  .banner-strip, .alert, .summary-tip { background: var(--restaurant-soft); color: var(--restaurant-text); border-color: var(--restaurant-line); }
  .alert.success { background: var(--status-good-bg); color: var(--status-good-ink); }
  .pill, .pill.blue { background: var(--restaurant-soft); color: var(--restaurant-accent); }
  .pill.orange { background: var(--status-warn-bg); color: var(--status-warn-ink); }
  .pill.red { background: var(--status-danger-bg); color: var(--status-danger-ink); }
  .pill.purple { background: var(--status-hold-bg); color: var(--status-hold-ink); }
  .tab { background: var(--restaurant-surface); border-color: var(--restaurant-line); color: var(--restaurant-muted); }
  .list-table th { background: var(--restaurant-card); color: var(--restaurant-muted); }
  .list-table td, .order-bottom, .payment-row > div:nth-child(2) { border-color: var(--restaurant-line); }
  .list-table tbody tr:hover { background: var(--restaurant-soft); }
  .chart-bars > div, .chart-bars .bar { background-color: var(--restaurant-accent); }

  /* Table plan, service calls and payment records. */
  .floor-legend span { color: var(--restaurant-muted); }
  .floor-legend i { box-shadow: 0 0 0 5px var(--restaurant-surface); }
  .available { --table-color: #d5a071; --table-ink: #101616; }
  .occupied { --table-color: var(--restaurant-soft); --table-ink: var(--restaurant-muted); }
  .ready, .leaving-soon { --table-color: #e7b350; --table-ink: #30271f; }
  .billed { --table-color: #82b590; --table-ink: #102519; }
  .calling { --table-color: #cc7869; --table-ink: #1c1511; }
  .floor-plan { background: radial-gradient(ellipse at center, var(--restaurant-glow), transparent), var(--restaurant-bg); }
  .table-top, .chair { background: var(--restaurant-card); border: 1px solid var(--restaurant-line); }
  .floor-table.selected .table-top { box-shadow: 0 0 0 2px var(--restaurant-accent), var(--restaurant-shadow); }
  .floor-table:hover .table-top { box-shadow: 0 0 0 2px var(--restaurant-bronze); }
  .table-time { background: var(--restaurant-soft); color: var(--restaurant-accent); }
  .calling .table-time { background: var(--status-danger-bg); color: var(--status-danger-ink); }
  .table-caption, .floor-dock small { color: var(--restaurant-muted); }
  .floor-dock { background: var(--restaurant-glass); border: 1px solid var(--restaurant-line); box-shadow: var(--restaurant-shadow); }
  .dock-symbol { background: var(--restaurant-soft); color: var(--restaurant-accent); }
  .dock-orders .btn { color: var(--restaurant-accent); border-color: var(--restaurant-line); }
  .service-alert { background: var(--restaurant-surface); border-color: #b85c4c; box-shadow: var(--restaurant-shadow); }
  .call-bell, .order-service-call { background: var(--status-danger-bg); color: var(--status-danger-ink); }
  .order-bottom {
    flex-wrap: wrap;
    background: linear-gradient(145deg, var(--restaurant-card), var(--restaurant-soft));
    border-top: 1px solid var(--restaurant-line);
    color: var(--restaurant-muted);
  }
  .order-note { background: var(--status-warn-bg); color: var(--status-warn-ink); }
  .order-bottom .countdown { max-width: 100%; overflow-wrap: anywhere; }
  .order-bottom small { color: var(--restaurant-muted); }
  .activity-symbol { background: var(--restaurant-soft); color: var(--restaurant-accent); }
  .order-lines, .activity-item { border-color: var(--restaurant-line); }
  .order-bottom strong, .payment-row > div > strong { color: var(--restaurant-accent); }
  .payment-row span, .payment-row small { color: var(--restaurant-muted); }
  .payment-row .payment-state { color: var(--status-warn-ink); }
  .order-card.blue { border-top-color: var(--restaurant-bronze); }

  /* All administration, dish editing, ordering and payment dialogs. */
  #modal { background: var(--restaurant-bg); color: var(--restaurant-text); border-color: var(--restaurant-line); box-shadow: var(--restaurant-shadow); }
  #modal::backdrop { background: rgb(8 13 12 / 72%); }
  .dialog-head, .dialog-footer { background: var(--restaurant-surface); border-color: var(--restaurant-line); }
  :is(.order-detail-items, .order-detail-actions, .ledger, .basket, .modifier-group) {
    background: var(--restaurant-surface); color: var(--restaurant-text); border-color: var(--restaurant-line);
  }
  .detail-line, .total-row.final, .receipt-summary .total-row.final,
  .guest-item-group, .pos-basket-line, .pos-total { border-color: var(--restaurant-line); }
  .detail-line strong, .order-information .total-row > strong,
  .receipt-summary .total-row.final strong, .pos-product span, .pos-total strong { color: var(--restaurant-accent); }
  .order-confirm-hint, .order-detail-items .batch h3, .ledger summary, .guest-item-name,
  .pos-basket > p, .pos-payment-note, .pos-basket-line small { color: var(--restaurant-muted); }
  .pos-basket-line b { color: var(--restaurant-accent); }
  .pos-total { background: var(--restaurant-soft); }
  .receipt-summary { background: var(--restaurant-soft); }
  .quantity button { background: var(--restaurant-soft); color: var(--restaurant-accent); }
  .form-error { color: var(--status-danger-ink); }
  #toast { background: var(--restaurant-surface); color: var(--restaurant-text); border: 1px solid var(--restaurant-line); box-shadow: var(--restaurant-shadow); }
  #toast.error { color: var(--status-danger-ink); }

  /* Active preparation and elapsed times remain easy to read at service distance. */
  .order-bottom .countdown,
  .order-bottom [data-deadline],
  .kds-ticket-status [data-deadline],
  .kds-elapsed > span {
    font-size: clamp(1.5rem, 2vw, 1.875rem);
    font-weight: 800;
    line-height: 1.15;
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.025em;
    color: var(--restaurant-accent);
  }
  .kds-elapsed > span { color: inherit; }
  .kds-ticket-status { align-items: center; flex-wrap: wrap; }
  .kds-ticket.urgent .kds-ticket-status [data-deadline] { color: var(--status-danger-ink); }

  /* Kitchen keeps explicit New / Preparing / On hold / Ready labels. */
  .kitchen-mode { background: radial-gradient(ellipse at top right, var(--restaurant-glow), transparent 80%), var(--restaurant-bg); }
  .kds-toolbar p { color: var(--restaurant-muted); }
  .kds-filter, .kds-counter { background: var(--restaurant-surface); color: var(--restaurant-muted); border: 1px solid var(--restaurant-line); }
  .kds-counter i { background: var(--restaurant-bronze); }
  .kds-counter.processing i { background: #d5a071; }
  .kds-counter.hold i { background: #e7b350; }
  .kds-counter.ready i { background: #82b590; }
  .kds-ticket > header { background: var(--restaurant-soft); color: var(--restaurant-accent); }
  .kds-ticket.processing > header { background: var(--restaurant-button); color: #101616; }
  .kds-ticket.hold > header { background: var(--status-warn-bg); color: var(--status-warn-ink); }
  .kds-ticket.ready > header, .kds-ticket.served > header { background: var(--status-good-bg); color: var(--status-good-ink); }
  .kds-ticket.urgent { border-color: #b85c4c; }
  .kds-ticket.urgent > header, .kds-ticket.urgent .kds-ticket-status { background: var(--status-danger-bg); color: var(--status-danger-ink); }
  .kds-ticket-status { background: var(--restaurant-card); color: var(--restaurant-muted); }
  .kds-item, .kds-ticket footer { border-color: var(--restaurant-line); }
  .kds-item > b { background: var(--restaurant-soft); color: var(--restaurant-accent); }
  .kds-item small, .kds-item small span { color: var(--restaurant-muted); }
  .kds-note, .kds-order-note { background: var(--status-warn-bg); color: var(--status-warn-ink); }

  /* Restaurant sign-in also offers the staff appearance preference. */
  .pin-login-layout, .login-layout, .restaurant-access, .demo-home { background: var(--restaurant-surface); border: 1px solid var(--restaurant-line); box-shadow: var(--restaurant-shadow); }
  .pin-welcome, .login-art { background: var(--restaurant-surface); color: var(--restaurant-text); }
  .pin-login-form, .login-form { background: linear-gradient(145deg, var(--restaurant-surface), var(--restaurant-soft)); }
  .pin-login-form > .theme-control { align-self: flex-end; margin-bottom: 20px; min-height: 44px; }
  .pin-brand, .login-art h1 span, .login-art .eyebrow, .restaurant-access > a:last-child { color: var(--restaurant-accent); }
  .pin-brand > span { background: var(--restaurant-soft); }
  .pin-welcome p, .pin-login-form > p, .login-art p, .login-form > p,
  .department-tabs a, .pin-login-links, .restaurant-access p, .demo-home p { color: var(--restaurant-muted); }
  .welcome-dots i { background: var(--restaurant-line); }
  .welcome-dots i:last-child { background: var(--restaurant-accent); }
  .department-tabs a.active { background: var(--restaurant-soft); color: var(--restaurant-accent); }
  .pin-input { background: transparent; color: var(--restaurant-accent); border-color: var(--restaurant-line); }
  .pin-input::placeholder { color: var(--restaurant-muted); }
  .pin-keypad button { background: var(--restaurant-surface); color: var(--restaurant-text); border: 1px solid var(--restaurant-line); box-shadow: none; }
  .pin-keypad button:active { background: var(--restaurant-soft); color: var(--restaurant-accent); }
  .login-hours-note { background: var(--status-warn-bg); color: var(--status-warn-ink); }
  .brand img { filter: none; }

  @media (max-width: 1100px) {
    .topbar .theme-control { width: 44px; height: 44px; padding: 0; }
    .topbar .theme-control > span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  }
  @media (max-width: 650px) {
    .shell { border: 0; }
    .topbar { gap: 8px; padding-inline: 12px; }
    .topbar .spacer { display: none; }
    .pos-heading { flex: 1; }
    .pos-heading small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .notification-pill, .mobile-menu { flex-shrink: 0; }
    .pin-login-form > .theme-control { margin-bottom: 12px; }
  }
}
