:root{--bg:#080d24;--bg-mid:#19264c;--bg-end:#21133f;--surface:#172442;--surface-alt:#121c36;--button-bg:#46376b;--ui-font:system-ui,sans-serif;--display-font:system-ui,sans-serif;font-family:var(--ui-font)}
html{background:var(--bg);scrollbar-color:var(--line) var(--surface)}
body{background:linear-gradient(135deg,var(--bg),var(--bg-mid) 55%,var(--bg-end));background-attachment:fixed;font-family:var(--ui-font);color:var(--ink)}
body::before{content:"";position:fixed;inset:0;pointer-events:none;z-index:-1;background-image:linear-gradient(var(--line) 1px,transparent 1px),linear-gradient(90deg,var(--line) 1px,transparent 1px);background-size:64px 64px;opacity:.13}
.workspace{max-width:1520px}.topbar{padding-top:24px;padding-bottom:24px}.brand{font-family:var(--display-font);letter-spacing:.04em}.brand small{font-family:var(--ui-font);letter-spacing:.12em;color:var(--muted);font-size:11px}.brand-mark{border-radius:14px;background:linear-gradient(135deg,var(--surface),var(--bg-mid));border-color:var(--gold);color:var(--gold);box-shadow:0 0 25px color-mix(in srgb,var(--gold) 15%,transparent);font-size:24px}
.page-heading{align-items:flex-start}.page-heading>div{min-width:0}.page-heading .eyebrow{display:block;font-family:var(--display-font);font-size:10px;letter-spacing:.28em;margin-bottom:10px}.page-heading h1{font-size:clamp(20px,2.2vw,30px);line-height:1.5;letter-spacing:.015em;overflow-wrap:anywhere;color:var(--ink)}
h2,h3,.section-kicker{color:var(--gold)}.card,.stat-card.lavender,.stat-card.blue,.stat-card.peach,.stat-card.mint,dialog{background:linear-gradient(140deg,var(--surface),var(--surface-alt));border-color:var(--line);box-shadow:var(--shadow)}
.stat-card{position:relative;overflow:hidden}.stat-card::after{content:"";position:absolute;left:0;top:20%;height:60%;width:2px;background:linear-gradient(transparent,var(--gold),transparent)}.stat-card p,.cell-title,.workspace td{color:var(--ink)}.stat-icon,.empty-icon,.tab-count{background:var(--bg-mid);color:var(--gold)}.stat-card strong{font-family:var(--display-font)}
input:not([type="checkbox"]):not([type="radio"]),select,textarea,.search-field input:not([type="checkbox"]),.copy-field input{background:var(--bg);color:var(--ink);border-color:var(--line);box-shadow:none}input::placeholder,textarea::placeholder{color:var(--muted)}option,optgroup{background:var(--surface);color:var(--ink)}input:-webkit-autofill{-webkit-text-fill-color:var(--ink);box-shadow:inset 0 0 0 1000px var(--surface)}
.button.primary,.button.line-button{background:linear-gradient(115deg,var(--button-bg),color-mix(in srgb,var(--button-bg) 80%,#243578));color:#fff;border:1px solid color-mix(in srgb,var(--button-bg) 60%,#fff);box-shadow:none}.button.primary:hover:not(:disabled),.button.line-button:hover:not(:disabled){background:var(--button-bg);filter:brightness(1.12)}.button.secondary,.button.quiet,.icon-button,.step-button{background:var(--surface-alt);color:var(--gold);border-color:var(--line)}.button.secondary:hover:not(:disabled),.button.quiet:hover:not(:disabled),.icon-button:hover:not(:disabled){background:var(--bg-mid);color:var(--gold);border-color:var(--gold)}.button.danger{background:#9f3045;color:#fff}
.tabs{background:var(--bg);border-color:var(--line);padding:8px}.tab{color:var(--muted)}.tab:hover{color:var(--gold)}.tab[aria-selected=true]{background:linear-gradient(125deg,var(--surface),var(--bg-mid));color:var(--gold);box-shadow:inset 0 -2px var(--gold)}.customize-steps{grid-template-columns:repeat(6,minmax(0,1fr))}.step-button{border-radius:8px}.step-button[aria-pressed=true]{background:linear-gradient(130deg,var(--surface),var(--bg-mid));border-color:var(--gold);color:var(--gold)}
.workspace thead{background:var(--bg-mid)}.workspace th,.workspace td{border-color:var(--line)}.workspace th{color:var(--gold)}.table-wrap{background:var(--surface-alt);scrollbar-color:var(--line) var(--surface)}.workspace tbody tr:nth-child(even){background:var(--surface)}.workspace tbody tr:hover{background:var(--bg-mid)}.cell-detail,.cell-date,.search-field>span{color:var(--muted)}.row-actions .button.quiet,.row-button{color:var(--gold);background:var(--bg-mid);border-color:var(--line)}
.empty-state,.sort-list li,.management-save,.checkbox-field,.dialog-heading,.dialog-footer{background:var(--surface-alt);border-color:var(--line)}.chat-bubble.incoming{background:linear-gradient(135deg,var(--surface),var(--bg-mid));color:var(--ink);border-color:var(--line)}.toast{background:var(--surface);color:var(--ink);border-color:var(--gold)}.menu-upload{display:flex;flex-wrap:wrap;gap:12px;padding:20px;background:var(--bg);border:1px dashed var(--line);border-radius:12px}.menu-upload label,.menu-upload p{width:100%;margin:0}.menu-upload input{max-width:100%;width:100%;padding:12px}.menu-design-preview{max-width:760px;margin:24px auto 16px;overflow:hidden;border:1px solid var(--line);border-radius:18px;background:var(--bg)}.menu-design-preview svg,.menu-design-preview img{display:block;width:100%;height:auto}.menu-design-preview img:not([src]),.menu-design-preview img[src=""]{display:none}#menuActualPreview{display:block;width:100%;max-width:760px;margin:18px auto;border-radius:18px}.theme-swatches{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin-top:20px}.theme-swatch{min-height:90px;padding:16px;border:1px solid;border-radius:12px;font:inherit;text-align:left;position:relative}.theme-swatch[aria-pressed=true]{outline:2px solid var(--gold);outline-offset:3px}.appearance-fields{max-width:none}.management-save{background:linear-gradient(110deg,var(--surface),var(--bg-mid));border-color:var(--line)}.page-footer{font-size:11px;letter-spacing:.04em}.workspace table{font-variant-numeric:tabular-nums}::selection{background:var(--gold);color:var(--bg)}
[data-tone=light] .badge.neutral,[data-tone=light] .badge.hidden,[data-tone=light] .badge.cancelled{background:#e4e9f2;color:#41516a}[data-tone=light] .badge.available,[data-tone=light] .badge.success,[data-tone=light] .badge.sent{background:#dbf2e7;color:#23634a}[data-tone=light] .badge.pending,[data-tone=light] .badge.booked,[data-tone=light] .badge.warning{background:#fff0cc;color:#725117}[data-tone=light] .badge.sold_out,[data-tone=light] .badge.failed,[data-tone=light] .badge.error{background:#fce0e7;color:#962441}[data-tone=light] .badge.handled{background:#dceafb;color:#274b7a}[data-tone=light] .notice.warning{background:#fff1d7;color:#724d16;border-color:#c7a46a}[data-tone=light] .notice.error,[data-tone=light] .inline-error{background:#fbe8ed;color:#9d2449;border-color:#daa2b3}
@media(max-width:1100px){.customize-steps{grid-template-columns:repeat(3,minmax(0,1fr))}.theme-swatches{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:600px){.customize-steps{grid-template-columns:repeat(2,minmax(0,1fr))}.theme-swatches{grid-template-columns:repeat(2,minmax(0,1fr))}.topbar{padding-top:18px;padding-bottom:18px}.page-heading h1{font-size:21px}.page-heading{gap:14px;flex-direction:column}.page-heading .eyebrow{font-size:9px}.menu-upload{padding:14px}.menu-design-preview{border-radius:10px}.page-footer{gap:10px;flex-wrap:wrap}.stat-card p{font-size:12px}.stat-card strong{font-size:25px}.theme-swatch{font-size:12px;padding:12px;min-height:78px}.appearance-fields{gap:10px}}
.management-save .button.primary{border-color:var(--gold)}.management-save{box-shadow:var(--shadow)}.menu-row{padding:16px;border:1px solid var(--line);border-radius:12px;background:var(--surface-alt)}

/* Keep the existing tab ids and keyboard behavior while presenting a stable side rail. */
.workspace-layout{display:grid;grid-template-columns:minmax(210px,248px) minmax(0,1fr);gap:28px;align-items:start}
.workspace-layout>main{min-width:0;width:100%;max-width:100%}
.workspace-sidebar{position:sticky;top:18px;min-width:0;padding:18px 14px;border:1px solid var(--line);border-radius:16px;background:linear-gradient(145deg,var(--surface),var(--surface-alt));box-shadow:var(--shadow)}
.sidebar-heading{display:grid;gap:2px;padding:0 8px 13px;border-bottom:1px solid var(--line);margin-bottom:12px}
.sidebar-heading .section-kicker{margin:0;font-size:10px;letter-spacing:.18em}
.sidebar-heading strong{font-size:17px;color:var(--ink)}
.workspace-sidebar .tabs-bar{display:flex;flex-direction:column;gap:14px;margin:0;align-items:stretch}
.workspace-sidebar .tabs{display:flex;flex-direction:column;gap:5px;width:100%;padding:0;background:transparent;border:0;overflow:visible}
.workspace-sidebar .tab{width:100%;justify-content:flex-start;min-height:46px;padding:10px 12px;border:1px solid transparent;border-radius:10px;text-align:left;white-space:normal;line-height:1.45;font-size:14px}
.workspace-sidebar .tab[aria-selected=true]{background:linear-gradient(125deg,var(--surface),var(--bg-mid));border-color:var(--gold);box-shadow:inset 3px 0 var(--gold)}
.workspace-sidebar .tab-count{margin-left:auto}
.workspace-sidebar .sync-tools{display:flex;align-items:center;justify-content:space-between;gap:8px;margin:4px 0 0;padding:12px 8px 0;border-top:1px solid var(--line);font-size:11px;line-height:1.4}
.workspace-sidebar .sync-tools #lastUpdated{min-width:0;overflow-wrap:anywhere}
.workspace-sidebar .sync-tools .icon-button{flex:0 0 38px}
.workspace-sidebar #settingsSubnav{display:grid;grid-template-columns:1fr;gap:10px;margin:4px 0 0;padding:12px 0 0;border-top:1px solid var(--line)}
.workspace-sidebar #settingsSubnav .settings-category-group{padding:12px;border-radius:12px;background:var(--bg);gap:9px}
.workspace-sidebar #settingsSubnav .settings-category-label{gap:2px}
.workspace-sidebar #settingsSubnav .settings-category-label strong{font-size:13px}
.workspace-sidebar #settingsSubnav .settings-category-label span{font-size:11px;line-height:1.45}
.workspace-sidebar #settingsSubnav .settings-category-actions,.workspace-sidebar #settingsSubnav .settings-category-shortcuts{gap:6px}
.workspace-sidebar #settingsSubnav .settings-category-actions .step-button,.workspace-sidebar #settingsSubnav .settings-category-shortcuts .button{flex:1 1 100%;min-height:38px;padding:8px 9px;font-size:12px;text-align:left}
.workspace-sidebar #settingsSubnav .settings-category-actions .step-button[aria-pressed=true]{box-shadow:inset 3px 0 var(--gold)}
.workspace-layout main>.page-heading{padding-top:4px}
.workspace-layout main>.stats{margin-top:2px}
#settingsFields{display:flex;flex-wrap:wrap;align-items:flex-start;gap:18px}
#settingsFields>.settings-category{flex:1 1 calc(50% - 9px);min-width:280px;align-self:flex-start}
#settingsFields>.form-footer{flex:1 0 100%;grid-column:auto}
.workspace-layout main .panel.card{min-width:0}
.workspace-layout main .section-heading h2{font-size:22px}
.workspace-layout main .section-heading .muted{font-size:14px}
.workspace-layout main label{font-size:14px}
.workspace-layout main input:not([type=checkbox]):not([type=radio]),.workspace-layout main select,.workspace-layout main textarea{font-size:15px}
.workspace-layout main .workspace td,.workspace-layout main .workspace th{font-size:14px}
.dashboard-panel{display:grid;gap:22px}
.dashboard-grid{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(280px,1fr);gap:16px}
.dashboard-card{min-width:0;padding:20px;border:1px solid var(--line);border-radius:14px;background:var(--surface-alt,var(--surface));display:grid;gap:14px}
.dashboard-card-heading{display:grid;gap:4px;min-width:0}
.dashboard-card-heading strong{font-size:20px;color:var(--ink);overflow-wrap:anywhere}
.dashboard-card p{margin:0;line-height:1.7}
.dashboard-focus{border-color:var(--gold)}
.dashboard-shortcuts{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.dashboard-shortcuts .button{min-height:44px;white-space:normal}
.dashboard-summary{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:10px}
.dashboard-summary>div{display:grid;grid-template-columns:1fr auto;align-items:end;column-gap:8px;padding:14px;border:1px solid var(--line);border-radius:12px;background:var(--bg)}
.dashboard-summary .cell-detail{grid-column:1/-1}
.dashboard-summary strong{font-size:25px;color:var(--ink);line-height:1.2}
.dashboard-summary span:last-child{font-size:12px;color:var(--muted)}
.dashboard-lists{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}
.dashboard-lists>section{min-width:0}
.section-heading.compact{margin-bottom:10px;align-items:center}
.section-heading.compact h3{margin:0;font-size:16px}
.dashboard-list{display:grid;gap:8px}
.dashboard-list-row{display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%;min-width:0;padding:12px 14px;border:1px solid var(--line);border-radius:10px;background:var(--surface-alt,var(--surface));color:var(--ink);text-align:left;cursor:pointer}
.dashboard-list-row:hover{border-color:var(--gold)}
.dashboard-list-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-weight:600}
.dashboard-list-meta{flex:0 0 auto;color:var(--muted);font-size:12px;white-space:nowrap}
.dashboard-event-insights{min-width:0;padding-top:2px}
.dashboard-event-list{display:grid;gap:8px}
.dashboard-event-row{display:grid;grid-template-columns:minmax(0,1fr) minmax(92px,auto) minmax(130px,auto);align-items:center;gap:16px;width:100%;min-width:0;padding:13px 15px;border:1px solid var(--line);border-radius:10px;background:var(--surface-alt,var(--surface));color:var(--ink);text-align:left;cursor:pointer}
.dashboard-event-row:hover{border-color:var(--gold);transform:translateY(-1px)}
.dashboard-event-row-heading,.dashboard-event-row-stat{display:grid;gap:3px;min-width:0}
.dashboard-event-row-stat{text-align:right}
.dashboard-event-row-stat strong{font-size:15px;color:var(--ink);white-space:nowrap}
@media(max-width:1100px){.dashboard-summary{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:900px){.dashboard-grid,.dashboard-lists{grid-template-columns:1fr}.dashboard-summary{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:600px){.dashboard-card{padding:16px}.dashboard-card-heading strong{font-size:18px}.dashboard-shortcuts{grid-template-columns:1fr 1fr}.dashboard-summary>div{padding:12px}.dashboard-summary strong{font-size:22px}.dashboard-list-row{align-items:flex-start;flex-direction:column;gap:4px}.dashboard-list-meta{white-space:normal}}
@media(max-width:600px){.dashboard-event-row{grid-template-columns:minmax(0,1fr) auto;gap:8px 12px}.dashboard-event-row-heading{grid-column:1/-1}.dashboard-event-row-stat{text-align:left}.dashboard-event-row-stat:last-child{text-align:right}}

@media(max-width:900px){
  .workspace-layout{display:flex;flex-direction:column;gap:16px}
  .workspace-sidebar{position:static;width:100%;padding:14px 12px}
  .sidebar-heading{display:flex;align-items:center;justify-content:space-between;padding:0 6px 10px;margin-bottom:10px}
  .sidebar-heading .section-kicker{margin:0}
  .workspace-sidebar .tabs-bar{gap:9px}
  .workspace-sidebar .tabs{flex-direction:row;overflow-x:auto;scrollbar-width:thin;padding:1px 0 5px;overscroll-behavior-x:contain}
  .workspace-sidebar .tab{flex:0 0 auto;width:auto;min-width:132px;min-height:46px;justify-content:center;text-align:center;padding:9px 12px}
  .workspace-sidebar .tab[aria-selected=true]{box-shadow:inset 0 -3px var(--gold)}
  .workspace-sidebar .sync-tools{margin-top:0;padding-top:9px}
  .workspace-sidebar #settingsSubnav{grid-template-columns:repeat(2,minmax(0,1fr));width:100%;padding-top:10px}
  .workspace-sidebar #settingsSubnav .settings-category-group{min-width:0}
  #settingsFields{flex-direction:column;gap:12px}
  #settingsFields>.settings-category{width:100%;min-width:0;flex:1 1 auto}
  #settingsFields>.form-footer{width:100%;flex-basis:auto}
}

@media(max-width:600px){
  .workspace-layout{display:flex;flex-direction:column;gap:16px}
  .workspace-sidebar{position:static;width:100%;padding:12px 10px}
  .sidebar-heading{display:flex;align-items:center;justify-content:space-between;padding:0 6px 9px;margin-bottom:9px}
  .sidebar-heading .section-kicker{margin:0}
  .workspace-sidebar .tabs-bar{gap:9px}
  .workspace-sidebar .tabs{flex-direction:row;overflow-x:auto;scrollbar-width:thin;padding:1px 0 5px;overscroll-behavior-x:contain}
  .workspace-sidebar .tab{flex:0 0 auto;width:auto;min-width:132px;min-height:46px;justify-content:center;text-align:center;padding:9px 12px}
  .workspace-sidebar .tab[aria-selected=true]{box-shadow:inset 0 -3px var(--gold)}
  .workspace-sidebar .sync-tools{margin-top:0;padding-top:9px}
  .workspace-sidebar #settingsSubnav{grid-template-columns:1fr}
  #settingsFields{flex-direction:column;gap:12px}
  #settingsFields>.settings-category{width:100%;min-width:0;flex:1 1 auto}
  #settingsFields>.form-footer{width:100%;flex-basis:auto}

  .topbar{flex-wrap:nowrap;gap:12px}
  .header-actions{display:flex;width:auto;max-width:50%;justify-content:flex-end}
  .header-actions #logoutButton{min-width:64px;min-height:44px}
  .workspace .button,.workspace .icon-button,dialog .button,dialog .icon-button{min-height:44px;max-width:100%;white-space:normal;overflow-wrap:anywhere}
  .workspace .filters>.button{width:auto;min-height:44px;padding:9px 12px;justify-content:center}
  #panel-inventory .filters{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:end}
  #panel-inventory .filters .search-field{grid-column:1/-1}
  #panel-inventory .filters>.button{grid-column:1/-1;justify-self:start}
  .workspace .section-heading>div,.workspace .management-actions>*,.workspace .form-footer>*{min-width:0;max-width:100%}
  .workspace .section-heading .button,.workspace .management-actions .button,dialog .dialog-footer .button{flex-shrink:1}
  .workspace input:not([type=checkbox]):not([type=radio]),.workspace select,.workspace textarea,dialog input:not([type=checkbox]):not([type=radio]),dialog select,dialog textarea{font-size:16px;max-width:100%}
  .workspace input[type=date],.workspace input[type=datetime-local],dialog input[type=date],dialog input[type=datetime-local]{min-width:0;max-width:100%}
  .workspace .field,.workspace .filter-field,dialog .field{min-width:0}
  .workspace .table-wrap{max-width:100%;overscroll-behavior-x:contain;touch-action:pan-x pan-y;-webkit-overflow-scrolling:touch}
  dialog .dialog-heading>div,dialog .dialog-heading h2{min-width:0;overflow-wrap:anywhere}
  dialog .dialog-heading .icon-button{flex:0 0 44px}
  dialog .dialog-footer{flex-wrap:wrap;gap:8px;padding-bottom:max(16px,env(safe-area-inset-bottom))}
  dialog .dialog-footer .button{flex:1 1 120px}
  .workspace .management-actions{row-gap:12px}
  .workspace .management-actions+.management-empty{margin-top:16px}
}

/* Liquid glass treatment for the admin workspace. Keep inventory rows and ticket
   tables on their existing high-contrast surfaces so dense data stays scannable. */
:root{
  --glass-surface:rgba(18,42,70,.68);
  --glass-surface-strong:rgba(10,28,50,.86);
  --glass-border:rgba(215,231,246,.18);
  --glass-highlight:rgba(255,255,255,.11);
  --glass-shadow:0 20px 52px rgba(1,8,20,.28),inset 0 1px 0 var(--glass-highlight);
}

.topbar,
.workspace-sidebar,
.dashboard-panel,
.login-card,
#sessionStatus,
#setupNotice,
#globalError,
#panel-settings,
#panel-orders,
#panel-inventory{
  position:relative;
  border:1px solid var(--glass-border);
  background:linear-gradient(145deg,var(--glass-surface),var(--glass-surface-strong));
  box-shadow:var(--glass-shadow);
  -webkit-backdrop-filter:blur(18px) saturate(125%);
  backdrop-filter:blur(18px) saturate(125%);
}

.topbar{border-radius:18px;padding-left:18px;padding-right:18px;margin-top:18px}
.workspace-sidebar{overflow:hidden}
.workspace-sidebar::before,
.dashboard-panel::before,
.login-card::before,
#panel-settings::before,
#panel-orders::before,
#panel-inventory::before{
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
  border-radius:inherit;
  background:linear-gradient(120deg,rgba(255,255,255,.09),transparent 32%,transparent 70%,rgba(177,211,244,.05));
  opacity:.8;
}

.workspace-sidebar>* ,
.dashboard-panel>* ,
.login-card>* ,
#panel-settings>* ,
#panel-orders>* ,
#panel-inventory>*{position:relative;z-index:1}

.dashboard-card,
.dashboard-summary>div,
.dashboard-list-row{
  border-color:var(--glass-border);
  background:linear-gradient(145deg,rgba(31,67,103,.62),rgba(10,29,51,.72));
  box-shadow:0 10px 26px rgba(1,8,20,.18),inset 0 1px 0 rgba(255,255,255,.08);
  -webkit-backdrop-filter:blur(14px) saturate(118%);
  backdrop-filter:blur(14px) saturate(118%);
}
.dashboard-card.dashboard-focus{border-color:color-mix(in srgb,var(--gold) 65%,var(--glass-border))}
.dashboard-list-row:hover{background:linear-gradient(145deg,rgba(39,81,121,.72),rgba(13,37,63,.8));transform:translateY(-1px)}
.dashboard-list-row{transition:transform .18s ease,background .18s ease,border-color .18s ease}

.workspace-sidebar .tab[aria-selected=true]{background:linear-gradient(120deg,rgba(58,91,128,.76),rgba(20,46,76,.82));box-shadow:inset 3px 0 var(--gold),inset 0 1px 0 rgba(255,255,255,.1),0 6px 18px rgba(1,8,20,.2)}
.workspace-sidebar .tab:hover{background:rgba(35,70,105,.45)}
.workspace-sidebar .sync-tools{border-color:var(--glass-border)}

/* Setting and payment sub-panels inherit the same material without changing
   ticket/inventory row density. */
#panel-settings .settings-category,
#panel-settings #paymentMethodsSection,
#panel-settings .payment-preview,
#panel-settings .management-save,
#panel-orders .notice,
#panel-inventory .inventory-event-context{
  border-color:var(--glass-border);
  background:linear-gradient(145deg,rgba(27,61,94,.6),rgba(9,27,48,.72));
  box-shadow:0 10px 24px rgba(1,8,20,.15),inset 0 1px 0 rgba(255,255,255,.07);
  -webkit-backdrop-filter:blur(12px) saturate(115%);
  backdrop-filter:blur(12px) saturate(115%);
}

@media(max-width:900px){
  .topbar{margin-top:12px;padding-left:14px;padding-right:14px}
  .workspace-sidebar{box-shadow:0 14px 34px rgba(1,8,20,.24),inset 0 1px 0 var(--glass-highlight)}
}

@media(prefers-reduced-motion:reduce){
  .dashboard-list-row{transition:none}
  .dashboard-list-row:hover{transform:none}
}

/* Light workspace themes need a light glass surface. The dark glass layer
   makes the sidebar and header text disappear against pearl/aurora themes. */
html[data-tone="light"]{
  --glass-surface:color-mix(in srgb,var(--surface) 78%,transparent);
  --glass-surface-strong:color-mix(in srgb,var(--surface-alt) 92%,transparent);
  --glass-border:color-mix(in srgb,var(--ink) 20%,transparent);
  --glass-highlight:rgba(255,255,255,.78);
  --glass-shadow:0 18px 44px rgba(38,66,106,.14),inset 0 1px 0 var(--glass-highlight);
}
html[data-tone="light"] .topbar,
html[data-tone="light"] .workspace-sidebar,
html[data-tone="light"] .dashboard-panel,
html[data-tone="light"] .login-card,
html[data-tone="light"] #sessionStatus,
html[data-tone="light"] #setupNotice,
html[data-tone="light"] #globalError,
html[data-tone="light"] #panel-settings,
html[data-tone="light"] #panel-orders,
html[data-tone="light"] #panel-inventory{
  color:var(--ink);
}
html[data-tone="light"] .brand,
html[data-tone="light"] .sidebar-heading strong,
html[data-tone="light"] .workspace-sidebar .tab,
html[data-tone="light"] .workspace-sidebar .sync-tools,
html[data-tone="light"] .workspace-sidebar #settingsSubnav .settings-category-label,
html[data-tone="light"] .workspace-sidebar #settingsSubnav .settings-category-label span{
  color:var(--ink);
}
html[data-tone="light"] .brand small,
html[data-tone="light"] .workspace-sidebar .sync-tools,
html[data-tone="light"] .workspace-sidebar #settingsSubnav .settings-category-label span{
  color:var(--muted);
}
html[data-tone="light"] .workspace-sidebar .tab:hover,
html[data-tone="light"] .workspace-sidebar .tab[aria-selected="true"]{
  color:var(--ink);
}
html[data-tone="light"] .workspace-sidebar .tab[aria-selected="true"]{
  background:color-mix(in srgb,var(--surface) 72%,var(--gold) 28%);
  border-color:var(--gold);
  box-shadow:inset 3px 0 var(--gold),inset 0 1px 0 rgba(255,255,255,.8),0 6px 18px rgba(38,66,106,.12);
}
html[data-tone="light"] .workspace-sidebar .tab-count{
  background:color-mix(in srgb,var(--surface) 68%,var(--gold) 32%);
  color:var(--ink);
}
html[data-tone="light"] .workspace-sidebar #settingsSubnav .settings-category-group{
  background:color-mix(in srgb,var(--surface) 76%,var(--bg) 24%);
  border:1px solid var(--glass-border);
}
html[data-tone="light"] .button.quiet,
html[data-tone="light"] .button.secondary,
html[data-tone="light"] .icon-button,
html[data-tone="light"] .step-button{
  color:var(--ink);
}
html[data-tone="light"] .button.quiet:hover:not(:disabled),
html[data-tone="light"] .button.secondary:hover:not(:disabled),
html[data-tone="light"] .icon-button:hover:not(:disabled),
html[data-tone="light"] .step-button:hover:not(:disabled){
  color:var(--ink);
}

/* The glass layer is dark by default, while light workspace themes provide
   dark text. Give the light themes a translucent white material so text,
   labels, controls, and borders keep clear contrast. */
[data-tone=light]{
  --glass-surface:rgba(255,255,255,.78);
  --glass-surface-strong:rgba(241,247,253,.92);
  --glass-border:rgba(74,108,143,.28);
  --glass-highlight:rgba(255,255,255,.9);
  --glass-shadow:0 20px 52px rgba(54,88,122,.14),inset 0 1px 0 var(--glass-highlight);
}
[data-tone=light] .topbar,
[data-tone=light] .workspace-sidebar,
[data-tone=light] .dashboard-panel,
[data-tone=light] .login-card,
[data-tone=light] #sessionStatus,
[data-tone=light] #setupNotice,
[data-tone=light] #globalError,
[data-tone=light] #panel-settings,
[data-tone=light] #panel-orders,
[data-tone=light] #panel-inventory{
  color:var(--ink);
}
[data-tone=light] .workspace-sidebar .tab[aria-selected=true]{
  background:linear-gradient(120deg,#e7f0f9,#d8e6f4);
  color:#214b70;
  border-color:#6b91b4;
  box-shadow:inset 3px 0 #356b98,inset 0 1px 0 rgba(255,255,255,.95),0 6px 18px rgba(54,88,122,.12);
}
[data-tone=light] .workspace-sidebar .tab:hover{background:rgba(224,237,248,.9);color:#214b70}
[data-tone=light] .dashboard-card,
[data-tone=light] .dashboard-summary>div,
[data-tone=light] .dashboard-list-row{
  background:linear-gradient(145deg,rgba(255,255,255,.86),rgba(234,243,251,.92));
  color:var(--ink);
  box-shadow:0 10px 26px rgba(54,88,122,.1),inset 0 1px 0 rgba(255,255,255,.95);
}
[data-tone=light] .dashboard-list-row:hover{background:linear-gradient(145deg,#ffffff,#e4f0fa)}
[data-tone=light] #panel-settings .settings-category,
[data-tone=light] #panel-settings #paymentMethodsSection,
[data-tone=light] #panel-settings .payment-preview,
[data-tone=light] #panel-settings .management-save,
[data-tone=light] #panel-orders .notice,
[data-tone=light] #panel-inventory .inventory-event-context{
  background:linear-gradient(145deg,rgba(255,255,255,.82),rgba(235,244,251,.94));
  color:var(--ink);
  box-shadow:0 10px 24px rgba(54,88,122,.08),inset 0 1px 0 rgba(255,255,255,.95);
}
[data-tone=light] .workspace-sidebar #settingsSubnav .settings-category-group{
  background:rgba(235,243,250,.88);
  border:1px solid rgba(74,108,143,.18);
}
[data-tone=light] .workspace-sidebar #settingsSubnav .settings-category-actions .step-button,
[data-tone=light] .workspace-sidebar #settingsSubnav .settings-category-shortcuts .button{
  color:#315a7d;
  background:rgba(255,255,255,.72);
  border-color:rgba(74,108,143,.24);
}
[data-tone=light] .workspace-sidebar #settingsSubnav .settings-category-actions .step-button[aria-pressed=true]{
  color:#1f4f78;
  background:#dcebf7;
  border-color:#6b91b4;
}
[data-tone=light] .button.primary,
[data-tone=light] .button.line-button{
  background:linear-gradient(135deg,#205b66,#1e4d70);
  color:#fff;
  border-color:#1b4d63;
}
[data-tone=light] .button.secondary,
[data-tone=light] .button.quiet,
[data-tone=light] .icon-button,
[data-tone=light] .step-button{
  background:#edf5fb;
  color:#234d6d;
  border-color:#90abc0;
}
[data-tone=light] .button.secondary:hover:not(:disabled),
[data-tone=light] .button.quiet:hover:not(:disabled),
[data-tone=light] .icon-button:hover:not(:disabled),
[data-tone=light] .step-button:hover:not(:disabled){
  background:#dcebf7;
  color:#173f5d;
  border-color:#5e88aa;
}
[data-tone=light] button:disabled,
[data-tone=light] input:disabled,
[data-tone=light] select:disabled,
[data-tone=light] textarea:disabled{opacity:.82}
[data-tone=light] .button.primary:disabled,
[data-tone=light] .button.line-button:disabled{
  background:#d7e4ee;
  color:#35526a;
  border-color:#9eb5c7;
}
[data-tone=light] .dashboard-event-row{
  background:rgba(255,255,255,.82);
  color:var(--ink);
  border-color:rgba(74,108,143,.28);
}
[data-tone=light] .dashboard-event-row:hover{background:#e7f2fa}
