:root {
  color-scheme: dark;
  --ink: #0b080a;
  --surface: #151014;
  --surface-2: #1e151b;
  --wine: #6b173d;
  --wine-bright: #a62a61;
  --gold: #d9b66f;
  --gold-soft: #f0ddb2;
  --text: #f8f1eb;
  --muted: #b9a9ae;
  --line: rgba(217, 182, 111, 0.22);
  --success: #55c28b;
  --danger: #e55b6d;
  --warning: #e0a84b;
  --radius: 18px;
  --font-ui: Arial, "Helvetica Neue", source-han-sans-japanese, "Source Han Sans JP", sans-serif;
  font-family: var(--font-ui);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { background: var(--ink); overflow-x: hidden; }
body { margin: 0; min-width: 320px; color: var(--text); background: radial-gradient(circle at 90% 0, rgba(107,23,61,.26), transparent 34rem), radial-gradient(circle at 5% 40%, rgba(217,182,111,.08), transparent 28rem), var(--ink); min-height: 100vh; overflow-x: hidden; }
a { color: var(--gold-soft); }
button, input, select, textarea { font: inherit; }
button, .button-link { min-height: 46px; border-radius: 12px; padding: .7rem 1rem; cursor: pointer; font-weight: 700; transition: transform .16s ease, opacity .16s ease, border-color .16s ease; }
button:hover, .button-link:hover { transform: translateY(-1px); }
button:disabled { opacity: .5; cursor: wait; transform: none; }
.primary { color: #160e08; background: linear-gradient(135deg, #f0d28e, #b98b3e); border: 1px solid #f6dea4; box-shadow: 0 8px 30px rgba(197,147,65,.12); }
.secondary { color: white; background: linear-gradient(135deg, #8c2351, #54142f); border: 1px solid #b74576; }
.ghost { color: var(--gold-soft); background: transparent; border: 1px solid var(--line); }
.danger { color: #ffecef; background: #571a28; border: 1px solid #a83b50; }
.small { min-height: 46px; padding: .45rem .75rem; font-size: .82rem; }
.button-link { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }

.topbar { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 1rem; min-height: 74px; padding: .65rem max(1rem, calc((100vw - 1180px)/2)); background: rgba(11,8,10,.89); border-bottom: 1px solid var(--line); backdrop-filter: blur(18px); }
.brand { display: flex; align-items: center; gap: .85rem; color: var(--text); text-decoration: none; margin-right: auto; min-width: 0; }
.brand-logo { display: block; width: clamp(118px, 13vw, 154px); height: auto; flex: none; }
.brand-subtitle { color: var(--muted); font-size: .7rem; letter-spacing: .04em; white-space: nowrap; }
.user-chip { display: flex; align-items: center; gap: .55rem; font-size: .85rem; }
.user-chip b { padding: .25rem .5rem; border-radius: 999px; background: rgba(107,23,61,.7); color: #f7dce8; font-size: .68rem; letter-spacing: .08em; }

.app-shell { width: min(1180px, calc(100% - 2rem)); margin: 1.5rem auto 4rem; display: grid; gap: 1rem; }
.hero-panel, .panel { border: 1px solid rgba(255,255,255,.72); background: linear-gradient(145deg, rgba(31,22,28,.96), rgba(16,12,15,.96)); border-radius: var(--radius); box-shadow: 0 20px 50px rgba(0,0,0,.18); }
.hero-panel { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: clamp(1.25rem, 3vw, 2.2rem); overflow: hidden; position: relative; }
.hero-panel::after { content: ""; position: absolute; width: 250px; height: 250px; border: 1px solid rgba(217,182,111,.12); border-radius: 50%; right: -80px; top: -130px; box-shadow: 0 0 0 34px rgba(217,182,111,.025), 0 0 0 68px rgba(107,23,61,.035); }
.hero-copy { position: relative; z-index: 1; min-width: 0; }
.hero-panel h1 { font-family: var(--font-ui); font-size: clamp(1.8rem, 4vw, 3rem); font-weight: 500; margin: .25rem 0 .6rem; letter-spacing: .06em; }
#business-date-heading { max-width: 100%; font-size: clamp(1.35rem, 5.5vw, 3rem); letter-spacing: clamp(.02em, .5vw, .06em); white-space: nowrap; }
.business-date-note { margin: -.25rem 0 .55rem; color: var(--muted); font-size: .7rem; letter-spacing: .02em; }
.hero-exception-alert, .hero-attendance-alert, .hero-schedule-alert, .hero-schedule-result-alert, .hero-ticket-overdue-alert { display: inline-flex; align-items: center; gap: .4rem; max-width: 100%; margin: .25rem .35rem .25rem 0; padding: .42rem .65rem; border: 1px solid rgba(224,168,75,.58); border-radius: 12px; color: #fff0c9; background: linear-gradient(135deg, rgba(116,70,12,.62), rgba(74,38,9,.5)); font-size: .76rem; line-height: 1.2; white-space: nowrap; text-decoration: none; }
.hero-exception-alert > span, .hero-attendance-alert > span, .hero-schedule-alert > span, .hero-schedule-result-alert > span, .hero-ticket-overdue-alert > span { color: var(--gold-soft); font-size: .7rem; }
.hero-ticket-overdue-alert { border-color: rgba(229,91,109,.68); background: linear-gradient(135deg, rgba(116,25,41,.68), rgba(70,17,29,.56)); }
.hero-ticket-overdue-alert[hidden] { display: none; }
.hero-ticket-overdue-alert strong span { color: inherit; font-size: inherit; }
.hero-attendance-alert { border-color: rgba(229,91,109,.6); background: linear-gradient(135deg, rgba(105,25,39,.62), rgba(68,19,31,.52)); }
.hero-schedule-alert { border-color: rgba(85,194,139,.5); background: linear-gradient(135deg, rgba(26,94,62,.58), rgba(15,59,42,.5)); }
.hero-schedule-result-alert { border-color: rgba(224,168,75,.58); background: linear-gradient(135deg, rgba(116,70,12,.62), rgba(74,38,9,.5)); }
.status-orb { z-index: 1; width: 116px; height: 116px; padding-bottom: .45rem; border-radius: 50%; display: grid; place-content: center; text-align: center; border: 1px solid var(--gold); background: rgba(11,8,10,.55); flex: none; }
.status-orb span, .status-orb strong { display: block; }
.status-orb span { color: var(--muted); font-size: .72rem; }
.status-orb strong { margin-top: .3rem; color: var(--gold-soft); font-size: .8rem; }
.panel { padding: clamp(1rem, 2.4vw, 1.6rem); min-width: 0; }
.panel h2 { margin: .2rem 0 1rem; font-family: var(--font-ui); font-weight: 500; }
.panel h3 { margin: 0 0 .7rem; color: var(--gold-soft); font-size: 1rem; }
.eyebrow { display: none; }
.subtle, .hint, .privacy-note, .empty { color: var(--muted); }
.hint { font-size: .78rem; }
.privacy-note { text-align: center; font-size: .75rem; margin: 1rem 0 0; }
.grid { display: grid; gap: 1rem; min-width: 0; }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.action-row { display: flex; flex-wrap: wrap; gap: .65rem; }
.action-row > * { flex: 1 1 120px; }
.action-panel .action-row { margin: 1.2rem 0 .7rem; }
.punch { min-height: 62px; font-size: 1rem; }
.inline-status { padding: .65rem .8rem; border-radius: 10px; background: rgba(255,255,255,.035); color: var(--muted); font-size: .82rem; }
.section-heading { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.live-indicator { color: var(--success); font-size: .76rem; padding: .35rem .65rem; border: 1px solid rgba(85,194,139,.3); border-radius: 999px; }
.live-indicator.offline { color: var(--warning); border-color: rgba(224,168,75,.3); }
.sales-summary-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .55rem; margin-bottom: .75rem; }
.sales-summary-item { min-width: 0; padding: .6rem .7rem; border: 1px solid rgba(217,182,111,.2); border-radius: 11px; background: rgba(217,182,111,.035); }
.sales-summary-item span, .sales-summary-item strong { display: block; }
.sales-summary-item span { color: var(--muted); font-size: .7rem; line-height: 1.25; }
.sales-summary-item .money { margin: .15rem 0 0; font-size: clamp(1rem, 3.8vw, 1.3rem); line-height: 1.15; white-space: nowrap; }
.sales-entry-form { grid-template-columns: repeat(2, minmax(0, 1fr)) auto; align-items: end; }
.sales-entry-form button { white-space: nowrap; }
.sales-daily { margin-top: 1rem; border: 1px solid var(--line); border-radius: 14px; background: rgba(5,4,5,.2); }
.sales-daily-summary { display: flex; align-items: center; justify-content: space-between; gap: .75rem; min-height: 58px; padding: .85rem 1rem; color: var(--gold-soft); list-style: none; }
.sales-daily-summary::-webkit-details-marker { display: none; }
.sales-daily-summary::marker { content: ""; }
.sales-daily[open] > .sales-daily-summary > .archive-chevron { transform: rotate(180deg); }
.sales-daily-body { padding: 0 .7rem .7rem; }
.sales-day-body { min-width: 0; padding: 0 1rem 1rem; overflow-wrap: anywhere; }
.sales-day-body .money { margin-bottom: .25rem; }
.sales-day-actions { margin-top: .75rem; }

.record-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 245px), 1fr)); gap: .8rem; min-width: 0; max-width: 100%; }
.record-card { min-width: 0; padding: 1rem; border: 1px solid rgba(255,255,255,.07); border-radius: 14px; background: rgba(255,255,255,.025); overflow-wrap: anywhere; }
.record-card > *, .record-card form, .stack-form, .stack-form label { width: 100%; min-width: 0; max-width: 100%; }
.record-title { display: flex; justify-content: space-between; align-items: flex-start; gap: .7rem; margin-bottom: .75rem; }
.record-card dl { display: grid; gap: .45rem; margin: 0; }
.record-card dl div { display: grid; grid-template-columns: minmax(75px, .7fr) minmax(0, 1.3fr); gap: .7rem; align-items: baseline; }
.record-card dt { color: var(--muted); font-size: .72rem; }
.record-card dd { margin: 0; text-align: right; font-size: .83rem; }
.shift-card { padding: 0; }
.shift-summary { display: flex; align-items: center; justify-content: space-between; gap: .75rem; min-height: 58px; padding: .9rem 1rem; color: var(--text); list-style: none; cursor: pointer; }
.shift-summary > strong { min-width: 0; overflow-wrap: anywhere; }
.shift-summary-meta { display: inline-flex; align-items: center; gap: .55rem; flex: none; }
.shift-summary::-webkit-details-marker { display: none; }
.shift-summary::marker { content: ""; }
.shift-chevron { flex: none; color: var(--gold); transition: transform .16s ease; }
.shift-card[open] .shift-chevron { transform: rotate(180deg); }
.shift-card-body { padding: 1rem; border-top: 1px solid rgba(255,255,255,.08); }
.shift-time { white-space: nowrap; font-variant-numeric: tabular-nums; }
.badge { flex: none; display: inline-flex; padding: .24rem .5rem; border-radius: 999px; border: 1px solid var(--line); color: var(--gold-soft); font-size: .64rem; letter-spacing: .05em; }
.badge.working, .badge.approved, .badge.finalized { color: #baf2d5; border-color: rgba(85,194,139,.35); background: rgba(28,94,62,.25); }
.badge.companion { color: #ffe6a6; border-color: rgba(255,197,82,.55); background: rgba(120,72,8,.38); }
.badge.draft { color: #d9d0d4; border-color: rgba(185,169,174,.35); background: rgba(92,79,84,.22); }
.badge.published { color: #ffe7ad; border-color: rgba(224,168,75,.45); background: rgba(92,62,15,.3); }
.badge.in-service { color: #baf2d5; border-color: rgba(85,194,139,.42); background: rgba(28,94,62,.28); }
.badge.payment-pending { color: #ffe7ad; border-color: rgba(224,168,75,.5); background: rgba(92,62,15,.34); }
.badge.checkout-complete { color: #c9d7ff; border-color: rgba(112,143,218,.42); background: rgba(40,58,105,.28); }
.badge.completed { color: #c9d7ff; border-color: rgba(112,143,218,.42); background: rgba(40,58,105,.28); }
.badge.before { color: #ffe7ad; border-color: rgba(224,168,75,.45); background: rgba(92,62,15,.3); }
.badge.review { color: #ffd8df; border-color: rgba(229,91,109,.55); background: rgba(97,26,40,.4); }
.badge.off { color: #d0c5c9; border-color: rgba(185,169,174,.3); background: rgba(92,79,84,.2); }
.badge.pending { color: #f6dca2; border-color: rgba(224,168,75,.4); }
.badge.returned, .badge.cancelled { color: #ffc1cb; border-color: rgba(229,91,109,.4); }
.current-schedule-summary { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .25rem .7rem; align-items: baseline; margin-bottom: .85rem; padding: .7rem .8rem; border: 1px solid rgba(217,182,111,.22); border-radius: 10px; background: rgba(217,182,111,.04); }
.current-schedule-summary strong { color: var(--gold-soft); }
.current-schedule-summary span { color: var(--text); font-variant-numeric: tabular-nums; white-space: nowrap; }
.current-schedule-summary small { grid-column: 1 / -1; color: var(--muted); overflow-wrap: anywhere; }
.attendance-status-note { margin: .85rem 0 0; }
.money { color: var(--gold-soft); font-family: var(--font-ui); font-size: 1.5rem; margin: .3rem 0; }
.money-small { color: var(--gold-soft); font-weight: 800; }
.plain-list { margin: .7rem 0; padding-left: 1.1rem; color: var(--muted); font-size: .84rem; }
.image-link { display: inline-block; padding: .55rem 0; }
.ticket-review-alert { display: flex; justify-content: space-between; align-items: center; gap: .75rem; padding: 1rem 1.15rem; border: 1px solid rgba(224,168,75,.52); border-radius: 14px; color: #fff0c9; background: linear-gradient(135deg, rgba(116,70,12,.55), rgba(74,38,9,.45)); text-decoration: none; }
.ticket-review-alert span { color: var(--gold-soft); font-size: .82rem; }
.exception-request-card dl { margin-bottom: 1rem; }
.exception-request-card .exception-reason { color: #fff0c9; font-weight: 700; white-space: pre-wrap; }
.ticket-photo { display: grid; gap: .55rem; width: 100%; margin: .7rem 0; color: var(--gold-soft); text-align: center; text-decoration: none; }
.ticket-photo img { display: block; width: 100%; max-height: 420px; object-fit: contain; border: 1px solid var(--line); border-radius: 12px; background: #070506; }
.ticket-photo span { text-decoration: underline; }
.ticket-archive { display: grid; gap: .75rem; min-width: 0; }
.ticket-archive-level, .ticket-archive-entry { min-width: 0; border: 1px solid rgba(255,255,255,.08); border-radius: 14px; background: rgba(255,255,255,.02); }
.ticket-archive-summary { display: flex; align-items: center; justify-content: space-between; gap: .75rem; min-height: 54px; padding: .8rem 1rem; color: var(--gold-soft); list-style: none; cursor: pointer; }
.ticket-archive-summary::-webkit-details-marker { display: none; }
.ticket-archive-summary::marker { content: ""; }
.archive-chevron { flex: none; color: var(--gold); transition: transform .16s ease; }
.ticket-archive-level[open] > .ticket-archive-summary > .archive-chevron, .ticket-archive-entry[open] > .ticket-archive-summary > .archive-chevron { transform: rotate(180deg); }
.ticket-archive-children, .ticket-archive-entry-body { display: grid; gap: .65rem; min-width: 0; padding: 0 .7rem .7rem; }
.ticket-archive-year > .ticket-archive-summary { font-size: 1.05rem; }
.ticket-archive-month { background: rgba(107,23,61,.12); }
.ticket-archive-day { background: rgba(5,4,5,.28); }
.ticket-archive-entry { background: rgba(217,182,111,.035); }
#attendance-history .ticket-archive-children { padding: 0 .2rem .5rem; }
#attendance-history .ticket-archive-summary { padding: .65rem; }
.ticket-archive-ticket { min-width: 0; padding: .9rem; border-top: 1px solid rgba(255,255,255,.08); overflow-wrap: anywhere; }
.ticket-archive-ticket:first-child { border-top: 0; }
.ticket-archive-ticket dl { display: grid; gap: .45rem; margin: 0; }
.ticket-archive-ticket dl div { display: grid; grid-template-columns: minmax(75px,.7fr) minmax(0,1.3fr); gap: .7rem; }
.ticket-archive-ticket dt { color: var(--muted); font-size: .72rem; }
.ticket-archive-ticket dd { margin: 0; text-align: right; font-size: .83rem; overflow-wrap: anywhere; }
.ticket-submission { padding-top: .8rem; margin-top: .8rem; border-top: 1px solid rgba(255,255,255,.08); }
.ticket-submission:first-of-type { margin-top: 0; }
.electronic-ticket-list { display: grid; gap: .6rem; margin-top: 1rem; }
.electronic-ticket-switcher { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: .65rem; width: 100%; margin-bottom: 1rem; }
.electronic-ticket-switcher .ticket-mode-button { width: 100%; min-width: 0; white-space: nowrap; }
.electronic-ticket-link { display: flex; align-items: center; justify-content: space-between; gap: .8rem; min-width: 0; padding: .85rem 1rem; border: 1px solid rgba(255,255,255,.08); border-radius: 12px; color: var(--text); background: rgba(5,4,5,.28); text-decoration: none; }
.electronic-ticket-link > span:first-child { display: grid; gap: .18rem; min-width: 0; }
.electronic-ticket-link small { color: var(--muted); font-size: .72rem; overflow-wrap: anywhere; }
.electronic-ticket-link-side { display: flex; align-items: center; justify-content: flex-end; gap: .55rem; flex-wrap: wrap; text-align: right; }
.electronic-ticket-link-side b { color: var(--gold-soft); white-space: nowrap; }
.electronic-ticket-link-side em { font-style: normal; white-space: nowrap; }
.electronic-sales-lines { display: grid; gap: .45rem; }
.electronic-sales-lines a { display: grid; grid-template-columns: minmax(0,1fr) auto auto; gap: .55rem; align-items: center; min-width: 0; padding: .55rem .65rem; border: 1px solid rgba(255,255,255,.07); border-radius: 9px; color: var(--text); text-decoration: none; }
.electronic-sales-lines a > span { min-width: 0; overflow-wrap: anywhere; }
.electronic-sales-lines a > strong { color: var(--gold-soft); white-space: nowrap; }
.electronic-sales-lines a > em { font-style: normal; }
.electronic-ticket-editor { width: min(1080px, calc(100% - 2rem)); }
.electronic-ticket-heading h1 { margin: .15rem 0; color: var(--gold-soft); font-size: clamp(1.35rem, 4vw, 2rem); font-variant-numeric: tabular-nums; }
.ticket-menu-picker { display: grid; gap: .75rem; margin: 1rem 0; padding: 1rem; border: 1px solid rgba(217,182,111,.24); border-radius: 16px; background: rgba(217,182,111,.04); }
.ticket-menu-tabs-row { display: flex; align-items: center; gap: .6rem; min-width: 0; }
.ticket-menu-tabs { display: flex; flex: 0 1 auto; flex-wrap: wrap; gap: .45rem; min-width: 0; max-width: 100%; padding-bottom: .2rem; }
.ticket-menu-select-hint { flex: none; color: var(--muted); font-size: .72rem; white-space: nowrap; }
.ticket-menu-tab { flex: none; min-height: 40px; padding: .5rem .8rem; border: 1px solid rgba(255,255,255,.12); border-radius: 999px; color: var(--muted); background: rgba(5,4,5,.42); }
.ticket-menu-tab.active { color: #1a1014; border-color: var(--gold); background: var(--gold-soft); }
.ticket-menu-category { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); gap: .55rem; }
.ticket-menu-category[hidden] { display: none; }
.ticket-menu-item { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: .15rem .55rem; min-width: 0; min-height: 62px; padding: .7rem .8rem; border: 1px solid rgba(255,255,255,.1); border-radius: 12px; color: var(--text); background: rgba(5,4,5,.42); text-align: left; }
.ticket-menu-item span { min-width: 0; overflow-wrap: anywhere; }
.ticket-menu-item strong { color: var(--gold-soft); white-space: nowrap; }
.ticket-menu-item small { grid-column: 1 / -1; color: var(--muted); }
.ticket-custom-item-form { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0,2fr) minmax(90px,.7fr) minmax(120px,1fr) auto; gap: .55rem; align-items: end; min-width: 0; }
.ticket-custom-item-form label { min-width: 0; }
.ticket-line-head, .electronic-ticket-line { display: grid; grid-template-columns: minmax(180px, 2fr) minmax(76px,.55fr) minmax(120px,1fr) minmax(100px,.8fr) auto; gap: .55rem; align-items: end; min-width: 0; }
.ticket-line-head { padding: 0 .15rem; color: var(--muted); font-size: .72rem; }
.electronic-ticket-lines { display: grid; gap: .7rem; min-width: 0; }
.electronic-ticket-line { padding: .7rem; border: 1px solid rgba(255,255,255,.08); border-radius: 12px; background: rgba(5,4,5,.25); }
.electronic-ticket-line label > span { display: none; }
.ticket-drink-credit-field { grid-column: 1 / -1; min-width: 0; }
.electronic-ticket-line .ticket-drink-credit-field > span { display: block; }
.ticket-drink-credit-field select { width: 100%; min-width: 0; }
.ticket-line-amount { min-height: 46px; display: flex; align-items: center; justify-content: flex-end; color: var(--gold-soft); font-weight: 800; white-space: nowrap; }
.electronic-ticket-total { display: grid; grid-template-columns: 1fr auto; gap: .2rem 1rem; align-items: baseline; margin-top: .25rem; padding: 1rem; border-block: 1px solid var(--line); }
.electronic-ticket-total > span { color: var(--muted); }
.electronic-ticket-total > strong { color: var(--gold-soft); font-size: clamp(1.55rem, 5vw, 2.25rem); white-space: nowrap; }
.electronic-ticket-total > small { grid-column: 1 / -1; color: var(--muted); text-align: right; }
.ticket-editor-actions { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: .65rem; }
.public-url-result { margin: 0; text-align: center; }
.public-url-result a { display: inline-flex; min-height: 46px; align-items: center; padding: .65rem 1rem; }
.ticket-customer-field { display: grid; gap: .4rem; margin: 1rem 0; }
.ticket-customer-field > span { color: var(--gold-soft); font-size: 1rem; }
.ticket-manager-actions, .ticket-cancel-zone { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid rgba(255,255,255,.08); }
.ticket-manager-actions > button, .ticket-cancel-zone > button { width: 100%; }
.ticket-set-panel { display: grid; gap: .85rem; margin: 1rem 0; padding: 1rem; border: 1px solid rgba(217,182,111,.28); border-radius: 16px; background: rgba(217,182,111,.06); }
.ticket-set-panel h2 { margin: .1rem 0; font-size: 1.15rem; }
.ticket-set-panel label { display: grid; gap: .35rem; }
.ticket-set-charge-fields { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: .65rem; }
.ticket-set-summary { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.ticket-set-countdown { color: var(--gold-soft); font-size: clamp(1.25rem,4vw,1.7rem); white-space: nowrap; }
.ticket-set-countdown.overdue { color: #ffad8f; font-size: clamp(1rem,3.5vw,1.25rem); }
.ticket-set-times { display: grid; gap: .45rem; margin: 0; }
.ticket-set-times > div { display: grid; grid-template-columns: minmax(7rem,.45fr) 1fr; gap: .75rem; }
.ticket-set-times dt { color: var(--muted); }
.ticket-set-times dd { margin: 0; text-align: right; }
.ticket-set-overdue-actions { display: grid; gap: .65rem; padding: .85rem; border: 1px solid rgba(255,173,143,.45); border-radius: 12px; background: rgba(130,49,22,.18); }
.ticket-set-overdue-actions > strong { color: #ffad8f; }
.ticket-set-overdue-actions p { margin: 0; }
.ticket-set-extension-buttons { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: .6rem; }
.system-ticket-line { border-color: rgba(217,182,111,.24); background: rgba(217,182,111,.07); }
.system-ticket-line input[readonly] { color: var(--gold-soft); }
.set-overdue-badge { display: inline-flex; margin-left: .35rem; vertical-align: middle; }
.set-overdue-badge[hidden] { display: none; }

.public-ticket-page { display: grid; min-width: 320px; place-items: start center; background: radial-gradient(circle at 50% 0, rgba(107,23,61,.26), transparent 34rem), #080607; font-size: 18px; }
.public-ticket-shell { width: min(720px, calc(100% - 1.25rem)); padding: clamp(1.25rem,5vw,3rem) 0; }
.public-ticket-logo { display: block; width: min(78%, 360px); height: auto; margin: 0 auto 1.2rem; }
.public-ticket-card { overflow: hidden; border: 1px solid rgba(217,182,111,.35); border-radius: 20px; background: linear-gradient(145deg, rgba(31,22,28,.98), rgba(14,10,13,.98)); box-shadow: 0 24px 80px #0008; }
.public-ticket-card strong { font-weight: 400; }
.public-ticket-title { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; padding: 1rem clamp(1rem,4vw,1.5rem); border-bottom: 1px solid var(--line); }
.public-ticket-title > div { display: grid; gap: .18rem; }
.public-ticket-title span, .public-ticket-title small { color: var(--muted); }
.public-ticket-title span { font-size: 1.08rem; }
.public-ticket-title .public-ticket-customer { color: var(--text); font-size: 1.24rem; line-height: 1.35; }
.public-ticket-title strong { color: var(--gold-soft); font-size: .92rem; font-variant-numeric: tabular-nums; }
.public-ticket-title .public-ticket-used-at { font-size: .8rem; font-variant-numeric: tabular-nums; }
.public-ticket-title > small { flex: none; font-size: .76rem; }
.public-ticket-lines { display: grid; padding: .25rem clamp(1rem,4vw,1.5rem); }
.public-ticket-lines > div { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: .22rem .8rem; align-items: baseline; padding: 1rem 0; border-bottom: 1px solid rgba(255,255,255,.07); }
.public-ticket-lines span { min-width: 0; font-size: 1.08rem; line-height: 1.45; overflow-wrap: anywhere; }
.public-ticket-lines small { grid-column: 1; color: var(--muted); font-size: .9rem; }
.public-ticket-lines strong { grid-column: 2; grid-row: 1 / span 2; color: var(--gold-soft); font-size: 1.08rem; white-space: nowrap; }
.public-ticket-total { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; padding: 1.15rem clamp(1rem,4vw,1.5rem); }
.public-ticket-total span { color: var(--gold-soft); font-size: 1.16rem; }
.public-ticket-total > div { display: grid; gap: .2rem; justify-items: end; }
.public-ticket-total strong { color: var(--gold-soft); font-size: clamp(2rem,8vw,3rem); font-weight: 800; white-space: nowrap; }
.public-ticket-total small { color: var(--muted); font-size: .86rem; white-space: nowrap; }
.public-ticket-card > p { margin: 0; padding: 0 clamp(1rem,4vw,1.5rem) 1.25rem; color: var(--muted); text-align: right; font-size: .82rem; }
.public-ticket-ended { padding: 2rem 1.25rem; text-align: center; }
.public-ticket-ended p { padding: 0; text-align: center; }
.pager { display: flex; align-items: center; justify-content: center; gap: .8rem; margin-top: 1rem; }
.section-back { display: flex; justify-content: flex-start; }
.dashboard-menu { padding-bottom: 1.2rem; }
.menu-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: .75rem; }
.menu-card { position: relative; display: grid; gap: .28rem; min-width: 0; min-height: 82px; padding: 1rem 2.6rem 1rem 1rem; border: 1px solid var(--line); border-radius: 14px; color: var(--text); background: rgba(255,255,255,.025); text-decoration: none; }
.menu-card strong { color: var(--gold-soft); }
.menu-card span { color: var(--muted); font-size: .78rem; }
.menu-card .menu-count { width: max-content; padding: .2rem .48rem; border: 1px solid rgba(224,168,75,.45); border-radius: 999px; color: #ffe8b6; background: rgba(92,62,15,.35); font-size: .7rem; font-style: normal; }
.menu-card b { position: absolute; right: 1rem; top: 50%; color: var(--gold); font-size: 1.5rem; transform: translateY(-50%); }
.schedule-section { padding: 0; }
.schedule-section-summary { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 76px; padding: 1rem clamp(1rem, 2.4vw, 1.6rem); list-style: none; }
.schedule-section-summary::-webkit-details-marker { display: none; }
.schedule-section-summary::marker { content: ""; }
.schedule-section-summary > span:first-child { display: grid; gap: .2rem; }
.schedule-section-summary small { color: var(--gold); font-size: .65rem; font-weight: 800; letter-spacing: .2em; }
.schedule-section-summary strong { color: var(--text); font-family: var(--font-ui); font-size: 1.35rem; font-weight: 500; }
.schedule-section-summary > span:last-child { display: flex; align-items: center; gap: .65rem; color: var(--muted); font-size: .78rem; }
.schedule-section-summary b { color: var(--gold); transition: transform .16s ease; }
.schedule-section[open] > .schedule-section-summary b { transform: rotate(180deg); }
.schedule-section-body { display: grid; gap: 1rem; min-width: 0; padding: 0 clamp(1rem, 2.4vw, 1.6rem) clamp(1rem, 2.4vw, 1.6rem); border-top: 1px solid rgba(255,255,255,.08); }
.schedule-month-header { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: .75rem; align-items: center; padding-top: 1rem; }
.schedule-month-header h2 { margin: 0; text-align: center; }
.schedule-calendar { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: .35rem; min-width: 0; }
.schedule-weekday { padding: .2rem; color: var(--muted); text-align: center; font-size: .72rem; }
.schedule-calendar-day { display: grid; align-content: start; justify-items: start; gap: .28rem; min-width: 0; min-height: 84px; padding: .45rem; border: 1px solid rgba(255,255,255,.08); border-radius: 10px; color: var(--text); background: rgba(255,255,255,.025); font-weight: 500; text-align: left; overflow: hidden; }
.schedule-calendar-day > span { color: var(--muted); font-size: .72rem; font-variant-numeric: tabular-nums; }
.schedule-calendar-day > strong { color: var(--gold-soft); font-size: .72rem; }
.schedule-calendar-day > small { width: 100%; color: var(--text); font-size: .68rem; line-height: 1.35; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.schedule-calendar-day.has-shift { border-color: rgba(105,224,159,.72); background: linear-gradient(145deg, rgba(34,112,74,.58), rgba(18,67,46,.5)); }
.schedule-calendar-day.has-request { border-color: rgba(245,194,91,.76); background: linear-gradient(145deg, rgba(142,91,14,.62), rgba(94,56,8,.52)); }
.schedule-calendar-day.has-shift.has-request { border-color: rgba(245,194,91,.76); background: linear-gradient(145deg, rgba(142,91,14,.62), rgba(94,56,8,.52)); }
.schedule-calendar-day.has-unacknowledged { border-color: rgba(255,148,73,.8); background: linear-gradient(145deg, rgba(159,66,18,.64), rgba(95,38,10,.54)); }
.schedule-calendar-day.has-rejection { border-color: rgba(229,91,109,.72); background: linear-gradient(145deg, rgba(105,25,39,.58), rgba(68,19,31,.5)); }
.schedule-calendar-day.today { outline: 1px solid var(--gold); outline-offset: -2px; }
.schedule-calendar-day.outside { min-height: 84px; border-color: transparent; background: transparent; }
.schedule-calendar-jump { width: 100%; appearance: none; -webkit-appearance: none; font: inherit; cursor: pointer; touch-action: manipulation; }
.schedule-calendar-jump:hover { filter: brightness(1.12); }
.schedule-calendar-jump:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
[data-schedule-card-date] { scroll-margin-top: 1rem; }
.schedule-card-jump-highlight { outline: 2px solid var(--gold); outline-offset: 3px; box-shadow: 0 0 0 6px rgba(217,182,111,.12); }
.calendar-confirmed-label { color: var(--success) !important; }
.calendar-pending-label { color: #f0c266 !important; }
.calendar-unacknowledged-label { color: #ffc28e !important; }
.calendar-rejected-label { color: #ffd7dd !important; }
.schedule-legend { display: flex; flex-wrap: wrap; gap: .45rem; align-items: center; }
.schedule-status { display: inline-flex; align-items: center; width: max-content; padding: .2rem .48rem; border: 1px solid var(--line); border-radius: 999px; font-size: .66rem; font-weight: 700; white-space: nowrap; }
.schedule-status.confirmed, .schedule-status.approved { color: #bdf2d5; border-color: rgba(85,194,139,.45); background: rgba(36,107,72,.28); }
.schedule-status.pending { color: #ffe7ad; border-color: rgba(224,168,75,.48); background: rgba(116,70,12,.32); }
.schedule-status.unacknowledged { color: #ffd0a8; border-color: rgba(255,148,73,.55); background: rgba(137,55,15,.34); }
.schedule-status.rejected { color: #ffd7dd; border-color: rgba(229,91,109,.48); background: rgba(105,25,39,.32); }
.schedule-status.cancelled { color: var(--muted); border-color: rgba(185,169,174,.3); background: rgba(185,169,174,.08); }
.schedule-roster-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: .6rem; }
.schedule-roster-day { min-width: 0; padding: 0; border: 1px solid rgba(255,255,255,.08); border-radius: 10px; background: rgba(5,4,5,.22); }
.schedule-roster-day-summary { display: flex; align-items: center; justify-content: space-between; gap: .75rem; min-height: 48px; padding: .7rem .75rem; list-style: none; }
.schedule-roster-day-summary::-webkit-details-marker { display: none; }
.schedule-roster-day-summary::marker { content: ""; }
.schedule-roster-day-summary strong { color: var(--text); }
.schedule-roster-day-summary b { color: var(--gold); font-size: .8rem; transition: transform .16s ease; }
.schedule-roster-day[open] > .schedule-roster-day-summary b { transform: rotate(180deg); }
.schedule-roster-day > div { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .2rem .45rem; align-items: center; padding: .55rem .75rem; border-top: 1px solid rgba(255,255,255,.07); }
.schedule-roster-day > div > span:first-child { min-width: 0; overflow-wrap: anywhere; }
.schedule-roster-day > div > small { grid-column: 1 / -1; color: var(--muted); }
.schedule-request-review-card { display: grid; gap: .7rem; }
.schedule-result-review-card, .schedule-result-confirmations { display: grid; gap: .7rem; }
.schedule-result-confirmations { border-color: rgba(224,168,75,.48); background: rgba(116,70,12,.14); }
.schedule-result-item > button { justify-self: start; }
.schedule-acknowledgement { display: inline-flex; width: max-content; max-width: 100%; padding: .25rem .5rem; border-radius: 999px; font-size: .7rem; font-weight: 700; }
.schedule-acknowledgement.confirmed { color: #bdf2d5; background: rgba(36,107,72,.28); }
.schedule-acknowledgement.pending { color: #ffe7ad; background: rgba(116,70,12,.32); }
.cast-schedule-panel { display: grid; gap: 1rem; }
.schedule-management { align-items: start; }
.schedule-list { display: grid; gap: .6rem; }
.schedule-list-item { display: grid; gap: .35rem; min-width: 0; padding: .75rem; border: 1px solid rgba(255,255,255,.08); border-radius: 10px; background: rgba(5,4,5,.22); }
.schedule-list-item > span { color: var(--gold-soft); font-variant-numeric: tabular-nums; }
.schedule-list-item > small { color: var(--muted); overflow-wrap: anywhere; }
.guest-reservation-panel { display: grid; gap: 1rem; }
.guest-reservation-summary-card { display: grid; gap: .8rem; }
.guest-reservation-summary-heading h2, .guest-reservation-summary-heading p { margin: 0; }
.guest-reservation-summary-heading .button-link { flex: none; }
.guest-reservation-summary-list { display: grid; gap: .45rem; }
.guest-reservation-summary-item { display: grid; grid-template-columns: minmax(92px, auto) minmax(0, 1fr) auto auto; align-items: center; gap: .65rem; min-width: 0; padding: .72rem .8rem; border: 1px solid rgba(199,159,75,.25); border-radius: 10px; color: var(--text); background: rgba(199,159,75,.055); text-decoration: none; }
.guest-reservation-summary-item time { color: var(--gold-soft); font-size: .82rem; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.guest-reservation-summary-item > span { display: flex; align-items: baseline; gap: .5rem; min-width: 0; }
.guest-reservation-summary-item > span strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.guest-reservation-summary-item > span small { color: var(--muted); white-space: nowrap; }
.guest-reservation-summary-item > b { color: var(--gold-soft); font-size: .78rem; white-space: nowrap; }
.guest-reservation-summary-item > em { color: var(--gold); font-style: normal; }
.guest-reservation-heading { display: flex; align-items: end; justify-content: space-between; gap: 1rem; }
.guest-reservation-heading h2, .guest-reservation-heading p, .guest-week-header h3, .guest-week-header p, .guest-reservation-form-card h3, .guest-reservation-form-card p { margin: 0; }
.guest-calendar { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: .35rem; min-width: 0; }
.guest-calendar-weekday { padding: .25rem; color: var(--muted); font-size: .72rem; text-align: center; }
.guest-calendar-day { display: grid; align-content: start; gap: .25rem; min-width: 0; min-height: 88px; padding: .48rem; border: 1px solid rgba(255,255,255,.08); border-radius: 10px; color: var(--text); background: rgba(255,255,255,.025); text-decoration: none; overflow: hidden; }
.guest-calendar-day > span { color: var(--muted); font-size: .72rem; font-variant-numeric: tabular-nums; }
.guest-calendar-day > strong { color: var(--gold-soft); font-size: .7rem; }
.guest-calendar-day > small { min-width: 0; overflow: hidden; color: var(--text); font-size: .66rem; text-overflow: ellipsis; white-space: nowrap; }
.guest-calendar-day.has-reservations { border-color: rgba(199,159,75,.62); background: linear-gradient(145deg, rgba(111,76,22,.48), rgba(52,37,18,.42)); }
.guest-calendar-day.today { outline: 1px solid var(--gold); outline-offset: -2px; }
.guest-calendar-day.selected { box-shadow: 0 0 0 2px rgba(245,214,143,.92); }
.guest-calendar-day.outside { min-height: 88px; border-color: transparent; background: transparent; }
.guest-calendar-day:hover { filter: brightness(1.12); }
.guest-calendar-day:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.guest-week-section { display: grid; gap: .8rem; padding-top: .25rem; scroll-margin-top: 1rem; }
.guest-week-header { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: .65rem; }
.guest-week-header > div { min-width: 0; text-align: center; }
.guest-timeline-hint { margin: 0; text-align: center; }
.guest-week-timeline-scroll { width: 100%; max-height: min(72vh, 740px); border: 1px solid rgba(217,182,111,.22); border-radius: 14px; background: rgba(5,4,5,.3); overflow: auto; overscroll-behavior: contain; scrollbar-gutter: stable; }
.guest-week-timeline { --guest-hour-height: 52px; min-width: 870px; }
.guest-week-timeline-header, .guest-week-timeline-body { display: grid; grid-template-columns: 66px repeat(7, minmax(112px, 1fr)); }
.guest-week-timeline-header { position: sticky; top: 0; z-index: 6; min-height: 66px; border-bottom: 1px solid rgba(217,182,111,.3); background: rgba(16,12,15,.98); box-shadow: 0 8px 18px rgba(0,0,0,.18); }
.guest-week-time-corner { position: sticky; left: 0; z-index: 8; display: grid; place-items: center; border-right: 1px solid rgba(255,255,255,.1); color: var(--muted); background: rgba(16,12,15,.99); font-size: .68rem; }
.guest-week-day-heading { display: grid; align-content: center; justify-items: center; gap: .08rem; min-width: 0; padding: .4rem .2rem; border-right: 1px solid rgba(255,255,255,.08); color: var(--text); text-decoration: none; }
.guest-week-day-heading > span { color: var(--muted); font-size: .68rem; }
.guest-week-day-heading > strong { color: var(--gold-soft); font-size: .88rem; font-variant-numeric: tabular-nums; }
.guest-week-day-heading > small { color: var(--gold); font-size: .62rem; }
.guest-week-day-heading.today { background: rgba(107,23,61,.26); }
.guest-week-day-heading.selected { box-shadow: inset 0 -3px var(--gold); }
.guest-week-timeline-body { height: calc(var(--guest-hour-height) * 24); }
.guest-week-hours { position: sticky; left: 0; z-index: 4; background: rgba(16,12,15,.98); box-shadow: 6px 0 12px rgba(0,0,0,.12); }
.guest-week-hours > div { position: relative; height: var(--guest-hour-height); border-right: 1px solid rgba(255,255,255,.1); border-bottom: 1px solid rgba(255,255,255,.09); }
.guest-week-hours span { position: absolute; top: -.55em; right: .45rem; color: var(--muted); font-size: .62rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
.guest-week-day-column { position: relative; height: 100%; border-right: 1px solid rgba(255,255,255,.08); background: repeating-linear-gradient(to bottom, transparent 0, transparent calc(var(--guest-hour-height) * .5 - 1px), rgba(255,255,255,.035) calc(var(--guest-hour-height) * .5 - 1px), rgba(255,255,255,.035) calc(var(--guest-hour-height) * .5), transparent calc(var(--guest-hour-height) * .5), transparent calc(var(--guest-hour-height) - 1px), rgba(255,255,255,.09) calc(var(--guest-hour-height) - 1px), rgba(255,255,255,.09) var(--guest-hour-height)); }
.guest-week-day-column.today { background-color: rgba(107,23,61,.08); }
.guest-week-day-column.selected { box-shadow: inset 0 0 0 1px rgba(217,182,111,.26); }
.guest-week-time-grid { position: absolute; inset: 0; z-index: 1; width: 100%; min-height: 0; padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; cursor: crosshair; }
.guest-week-time-grid:hover { transform: none; background: rgba(217,182,111,.045); }
.guest-current-time-line { position: absolute; left: 0; right: 0; z-index: 5; height: 2px; border-radius: 999px; background: #fff; box-shadow: 0 0 7px rgba(255,255,255,.78); pointer-events: none; }
.guest-current-time-line::before { content: ""; position: absolute; left: -4px; top: 50%; width: 8px; height: 8px; border-radius: 50%; background: #fff; box-shadow: 0 0 7px rgba(255,255,255,.82); transform: translateY(-50%); }
.guest-week-event { position: absolute; z-index: 2; min-height: 34px; border: 1px solid rgba(240,210,142,.68); border-radius: 7px; background: linear-gradient(145deg, rgba(125,29,70,.97), rgba(80,18,45,.98)); box-shadow: 0 4px 12px rgba(0,0,0,.24); overflow: hidden; }
.guest-week-event-content { display: grid; align-content: start; gap: .08rem; width: 100%; height: 100%; min-height: 0; padding: .28rem .38rem; border: 0; border-radius: 0; color: white; background: transparent; box-shadow: none; text-align: left; overflow: hidden; }
.guest-week-event-edit:hover { transform: none; background: rgba(255,255,255,.06); }
.guest-week-event-content strong, .guest-week-event-content time, .guest-week-event-content span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.guest-week-event-content strong { font-size: .7rem; }
.guest-week-event-content time { font-size: .62rem; font-variant-numeric: tabular-nums; }
.guest-week-event-content span { color: #f3dfe8; font-size: .58rem; }
.guest-week-event-content .guest-week-event-assignee { overflow: visible; color: #fff; line-height: 1.1; text-overflow: clip; white-space: nowrap; }
.guest-reservation-detail-dialog { width: min(calc(100% - 1.5rem), 430px); max-width: 430px; max-height: min(82vh, 620px); padding: 0; border: 1px solid rgba(240,210,142,.7); border-radius: 18px; color: var(--text); background: transparent; box-shadow: 0 28px 90px #000c; overflow: auto; }
.guest-reservation-detail-dialog::backdrop { background: rgba(5,3,4,.7); backdrop-filter: blur(3px); }
.guest-reservation-detail-card { position: relative; padding: 1.15rem; border-radius: 17px; background: linear-gradient(145deg, rgba(96,23,54,.99), rgba(28,15,22,.99)); animation: guest-reservation-detail-pop .2s cubic-bezier(.2,.85,.3,1.2); }
.guest-reservation-detail-close { position: absolute; top: .7rem; right: .7rem; display: grid; place-items: center; width: 36px; min-height: 36px; padding: 0; border: 1px solid rgba(255,255,255,.3); border-radius: 50%; color: #fff; background: rgba(21,9,14,.76); font-size: 1.25rem; line-height: 1; }
.guest-reservation-detail-kicker { margin: 0 3rem .25rem 0; color: var(--gold-soft); font-size: .7rem; font-weight: 700; letter-spacing: .08em; }
.guest-reservation-detail-card h3 { margin: 0 3rem .9rem 0; color: #fff; font-size: 1.25rem; overflow-wrap: anywhere; }
.guest-reservation-detail-card dl { display: grid; gap: 0; margin: 0; border-top: 1px solid rgba(255,255,255,.13); }
.guest-reservation-detail-card dl > div { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: .65rem; padding: .72rem 0; border-bottom: 1px solid rgba(255,255,255,.1); }
.guest-reservation-detail-card dt { color: #d7bcc7; font-size: .78rem; }
.guest-reservation-detail-card dd { margin: 0; color: #fff; font-weight: 700; overflow-wrap: anywhere; }
.guest-reservation-detail-actions { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: .65rem; margin-top: 1rem; }
.guest-reservation-detail-actions > button:only-child { grid-column: 1 / -1; }
@keyframes guest-reservation-detail-pop { from { opacity: 0; transform: scale(.84); } to { opacity: 1; transform: scale(1); } }
.guest-reservation-form-card { display: grid; grid-template-columns: minmax(150px, .42fr) minmax(0, 1fr); align-items: start; gap: 1rem; }
.guest-reservation-form-card form { margin: 0; }
.owner-zone { border-color: rgba(255,255,255,.72); }
.menu-settings-grid { align-items: start; }
.menu-item-list { display: grid; gap: .65rem; min-width: 0; }
.menu-item-list > h3 { margin-top: 0; }
.menu-item-card { min-width: 0; border: 1px solid rgba(255,255,255,.08); border-radius: 12px; background: rgba(5,4,5,.28); }
.menu-item-card > summary { display: grid; grid-template-columns: minmax(0,1fr) auto auto; gap: .6rem; align-items: center; min-height: 58px; padding: .7rem .8rem; list-style: none; }
.menu-item-card > summary::-webkit-details-marker { display: none; }
.menu-item-card > summary::marker { content: ""; }
.menu-item-card > summary > span:first-child { display: grid; gap: .14rem; min-width: 0; }
.menu-item-card > summary strong { min-width: 0; overflow-wrap: anywhere; }
.menu-item-card > summary small { color: var(--muted); }
.menu-item-card > summary > b { color: var(--gold); transition: transform .16s ease; }
.menu-item-card[open] > summary > b { transform: rotate(180deg); }
.menu-item-update-form { padding: .8rem; border-top: 1px solid rgba(255,255,255,.08); }
.staff-settings-grid { margin-top: 1rem; }
.staff-settings-grid .record-card { display: grid; gap: .8rem; align-content: start; }
.staff-directory { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin-top: 1rem; }
.staff-directory-group { min-width: 0; padding: 1rem; border: 1px solid rgba(255,255,255,.07); border-radius: 14px; background: rgba(255,255,255,.025); }
.staff-name-list { display: grid; gap: .55rem; }
.staff-name-link { display: flex; align-items: center; justify-content: space-between; gap: .75rem; min-width: 0; min-height: 58px; padding: .75rem .85rem; border: 1px solid var(--line); border-radius: 12px; color: var(--text); background: rgba(5,4,5,.3); text-decoration: none; }
.staff-name-link span { display: grid; gap: .2rem; min-width: 0; }
.staff-name-link strong { overflow-wrap: anywhere; }
.staff-name-link small { color: var(--muted); }
.staff-name-link b { flex: none; color: var(--gold); font-size: 1.5rem; }
details { max-width: 100%; overflow: hidden; }
summary { cursor: pointer; color: var(--gold-soft); overflow-wrap: anywhere; }

.stack-form { display: grid; gap: .85rem; }
.stack-form.compact { gap: .65rem; }
.stack-form label, fieldset { display: grid; gap: .35rem; color: var(--gold-soft); font-size: .8rem; }
fieldset { width: 100%; min-width: 0; max-width: 100%; margin: 0; padding: .75rem; border: 1px solid var(--line); border-radius: 12px; }
legend { padding: 0 .35rem; }
input, select, textarea { width: 100%; min-width: 0; max-width: 100%; min-height: 46px; padding: .7rem .8rem; font-size: 1rem; color: var(--text); background: rgba(5,4,5,.55); border: 1px solid rgba(255,255,255,.13); border-radius: 10px; outline: none; }
input[type="date"], input[type="month"], input[type="time"] { display: block; width: 100%; min-width: 0; max-width: 100%; inline-size: 100%; min-inline-size: 0; max-inline-size: 100%; -webkit-appearance: none; appearance: none; }
input[type="date"]::-webkit-date-and-time-value, input[type="month"]::-webkit-date-and-time-value, input[type="time"]::-webkit-date-and-time-value { min-width: 0; text-align: left; }
input:focus, select:focus, textarea:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(217,182,111,.1); }
.password-field { position: relative; display: block; width: 100%; min-width: 0; }
.password-field input { padding-right: 3.35rem; }
.password-visibility-toggle { position: absolute; top: 50%; right: .3rem; display: grid; width: 42px; min-width: 42px; min-height: 38px; padding: 0; place-items: center; color: var(--gold-soft); background: rgba(22,15,19,.9); border: 1px solid rgba(217,182,111,.28); border-radius: 8px; transform: translateY(-50%); }
.password-visibility-toggle:hover { transform: translateY(-50%); border-color: rgba(217,182,111,.58); }
.password-visibility-toggle:focus-visible { outline: 2px solid var(--gold); outline-offset: 1px; }
.password-visibility-toggle svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.password-visibility-toggle .password-visibility-slash { display: none; }
.password-visibility-toggle.is-visible .password-visibility-slash { display: block; }
textarea { min-height: 80px; resize: vertical; }
input[type="file"] { padding: .55rem; }
input[type="checkbox"] { width: 20px; min-height: 20px; accent-color: var(--wine-bright); }
.check { grid-template-columns: auto 1fr; align-items: center; }
.quantity-row { grid-template-columns: 1fr 76px; align-items: center; }
.inline-form { display: grid; grid-template-columns: 70px 1fr auto; gap: .45rem; margin-top: .8rem; }
.inline-form input { min-height: 38px; padding: .45rem .55rem; }
.form-stack { display: grid; gap: .8rem; }
.form-stack > form { padding: 1rem; border: 1px solid rgba(255,255,255,.06); border-radius: 14px; }
.staff-card-section { min-width: 0; max-width: 100%; padding-top: .85rem; border-top: 1px solid rgba(255,255,255,.08); }
.settings-details, .integrated-history, .technical-details { width: 100%; margin-top: .85rem; border: 1px solid rgba(217,182,111,.2); border-radius: 12px; background: rgba(5,4,5,.22); }
.settings-details > summary, .integrated-history > summary, .technical-details > summary { padding: .85rem 1rem; font-weight: 700; list-style-position: inside; }
.staff-setting-details { margin-top: 0; }
.staff-setting-details > summary { display: flex; align-items: center; justify-content: space-between; gap: .75rem; min-height: 54px; list-style: none; }
.staff-setting-details > summary::-webkit-details-marker { display: none; }
.staff-setting-details > summary::marker { content: ""; }
.staff-setting-details > summary b { flex: none; color: var(--gold); transition: transform .16s ease; }
.staff-setting-details[open] > summary b { transform: rotate(180deg); }
.staff-setting-details .staff-card-section { padding-top: 0; border-top: 0; }
.settings-details-body { display: grid; gap: .8rem; min-width: 0; padding: 0 1rem 1rem; }
.history-stack { gap: 1.2rem; }
.technical-details dl { padding: 0 1rem 1rem; }
.report-result { display: grid; gap: 1rem; max-width: 100%; margin-top: 1rem; padding: 1rem; border: 1px solid rgba(217,182,111,.18); border-radius: 12px; background: rgba(5,4,5,.3); color: var(--text); }
.report-summary-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 150px), 1fr)); gap: .65rem; }
.report-metric { min-width: 0; padding: .75rem; border: 1px solid rgba(217,182,111,.18); border-radius: 10px; background: rgba(217,182,111,.035); }
.report-metric span, .report-metric strong { display: block; }
.report-metric span { color: var(--muted); font-size: .72rem; }
.report-metric strong { margin-top: .25rem; color: var(--gold-soft); overflow-wrap: anywhere; }
.report-table-wrap { max-width: 100%; overflow-x: auto; border: 1px solid rgba(255,255,255,.08); border-radius: 10px; }
.report-table { width: 100%; min-width: 660px; border-collapse: collapse; font-size: .8rem; }
.report-table th, .report-table td { padding: .7rem; border-bottom: 1px solid rgba(255,255,255,.07); text-align: left; white-space: nowrap; }
.report-table th { color: var(--gold-soft); background: rgba(217,182,111,.06); }
.report-table tbody tr:last-child td { border-bottom: 0; }
.audit-diff { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; margin-top: .6rem; }
.audit-diff pre { max-width: 100%; overflow-wrap: anywhere; white-space: pre-wrap; padding: .65rem; border-radius: 8px; background: rgba(5,4,5,.55); color: var(--muted); }
.audit-change-list { margin: 0; padding-left: 1rem; text-align: left; }
.audit-change-list li + li { margin-top: .25rem; }

.alert { padding: .85rem 1rem; border-radius: 12px; border: 1px solid; }
.alert.error { color: #ffd8df; border-color: rgba(229,91,109,.42); background: rgba(97,26,40,.35); }
.alert.warning { color: #ffe8b6; border-color: rgba(224,168,75,.42); background: rgba(92,62,15,.35); }
.alert.success { color: #cef5df; border-color: rgba(85,194,139,.42); background: rgba(28,94,62,.3); }
.exception-actual-time { display: grid; gap: .45rem; margin: 1rem 0; color: var(--gold-soft); font-size: .82rem; }
.confirm-dialog { width: min(calc(100% - 1.5rem), 520px); max-width: 520px; padding: 0; border: 1px solid var(--line); border-radius: 18px; color: var(--text); background: #171115; box-shadow: 0 28px 90px #000b; }
.confirm-dialog::backdrop { background: rgba(5,3,4,.78); backdrop-filter: blur(4px); }
.confirm-dialog-card { padding: clamp(1rem, 4vw, 1.5rem); }
.confirm-dialog-card h2 { margin: .35rem 0 .7rem; font-family: var(--font-ui); font-weight: 500; }
.confirm-dialog-actions { display: grid; gap: .65rem; margin-top: 1.2rem; }
.confirm-dialog-actions > * { width: 100%; }
.toast { position: fixed; z-index: 30; left: 50%; top: 84px; transform: translate(-50%, -20px); width: min(92vw, 520px); padding: .8rem 1rem; border-radius: 12px; background: #21151b; border: 1px solid var(--line); opacity: 0; pointer-events: none; transition: .2s ease; box-shadow: 0 15px 50px #0008; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.success { border-color: rgba(85,194,139,.45); }
.toast.error { border-color: rgba(229,91,109,.55); }

.auth-page { display: grid; place-items: center; padding: 1rem; }
.auth-shell { width: min(100%, 460px); }
.auth-card { padding: clamp(1.35rem, 5vw, 2.15rem); background: linear-gradient(145deg, rgba(32,22,29,.98), rgba(12,9,11,.98)); border: 1px solid var(--line); border-radius: 24px; box-shadow: 0 28px 80px rgba(0,0,0,.45); }
.auth-card.wide { width: min(100%, 520px); }
.auth-logo { display: block; width: min(100%, 340px); height: auto; margin: -.3rem auto .45rem; }
.auth-logo.compact { width: min(100%, 280px); margin-bottom: .7rem; }
.auth-service-name { margin: 0; color: var(--gold-soft); text-align: center; font-size: .86rem; font-weight: 700; letter-spacing: .12em; }
.auth-card h1 { margin: .35rem 0 .2rem; text-align: center; font-family: var(--font-ui); font-weight: 500; letter-spacing: .12em; }
.auth-card > .eyebrow, .auth-card > .subtle { text-align: center; }
.auth-card .stack-form { margin-top: 1.4rem; }
.qr { display: block; width: 220px; max-width: 100%; height: auto; margin: 1rem auto; padding: 8px; background: white; border-radius: 12px; }
.totp-secret { display: block; margin-top: .5rem; padding: .7rem; word-break: break-all; color: var(--gold-soft); }
footer { padding: 2rem 1rem 3rem; text-align: center; color: #77696f; font-size: .68rem; letter-spacing: .08em; }

@media (max-width: 720px) {
  .topbar { gap: .55rem; }
  .brand-subtitle, .user-chip span { display: none; }
  .app-shell { width: min(100% - 1rem, 1180px); margin-top: .5rem; }
  .grid.two { grid-template-columns: 1fr; }
  .menu-grid { grid-template-columns: minmax(0, 1fr); }
  .record-grid, .staff-settings-grid { grid-template-columns: minmax(0, 1fr); }
  .sales-entry-form { grid-template-columns: minmax(0, 1fr); }
  .sales-entry-form button { width: 100%; }
  .staff-directory { grid-template-columns: minmax(0, 1fr); }
  .schedule-calendar { gap: .22rem; }
  .schedule-calendar-day, .schedule-calendar-day.outside { min-height: 56px; padding: .28rem .2rem; border-radius: 8px; }
  .schedule-calendar-day > span { font-size: .68rem; }
  .schedule-calendar-day > strong { max-width: 100%; font-size: .62rem; line-height: 1.15; letter-spacing: -.03em; white-space: nowrap; }
  .calendar-unacknowledged-label { font-size: .52rem !important; line-height: 1.22 !important; white-space: normal !important; }
  .calendar-unacknowledged-label > span { display: block; white-space: nowrap; }
  .schedule-calendar-day > small { display: none; }
  .guest-reservation-heading { display: grid; gap: .35rem; }
  .guest-reservation-summary-heading { display: grid; gap: .65rem; }
  .guest-reservation-summary-heading .button-link { width: 100%; }
  .guest-reservation-summary-item { grid-template-columns: minmax(76px, auto) minmax(0, 1fr) auto; gap: .4rem; padding: .62rem; }
  .guest-reservation-summary-item > b { grid-column: 2 / -1; white-space: normal; }
  .guest-reservation-summary-item > em { grid-column: 3; grid-row: 1; }
  .guest-calendar { gap: .22rem; }
  .guest-calendar-day, .guest-calendar-day.outside { min-height: 56px; padding: .28rem .2rem; border-radius: 8px; }
  .guest-calendar-day > span { font-size: .68rem; }
  .guest-calendar-day > strong { font-size: .62rem; line-height: 1.1; white-space: nowrap; }
  .guest-calendar-day > small { display: none; }
  .guest-week-header { gap: .3rem; }
  .guest-week-header .button-link { min-height: 42px; padding-inline: .48rem; }
  .guest-week-header h3 { font-size: .92rem; }
  .guest-timeline-hint { text-align: left; }
  .guest-week-timeline-scroll { max-height: 68vh; }
  .guest-week-timeline { --guest-hour-height: 48px; min-width: 936px; }
  .guest-week-timeline-header, .guest-week-timeline-body { grid-template-columns: 60px repeat(7, minmax(124px, 1fr)); }
  .guest-week-time-corner { font-size: .62rem; }
  .guest-week-day-heading > strong { font-size: .8rem; }
  .guest-week-hours span { right: .35rem; font-size: .58rem; }
  .guest-week-event-content .guest-week-event-assignee { font-size: .56rem; letter-spacing: -.02em; }
  .guest-reservation-detail-dialog { width: min(calc(100% - 1rem), 430px); }
  .guest-reservation-detail-card { padding: 1rem; }
  .guest-reservation-detail-card dl > div { grid-template-columns: 68px minmax(0, 1fr); gap: .5rem; }
  .guest-reservation-detail-actions { grid-template-columns: minmax(0, 1fr); }
  .guest-reservation-form-card { grid-template-columns: minmax(0, 1fr); }
  .record-card, .record-card form, .record-card label { width: 100%; min-width: 0; max-width: 100%; }
  .ticket-archive-ticket dl div { grid-template-columns: minmax(0, 1fr); gap: .15rem; }
  .ticket-archive-ticket dd { text-align: left; }
  .audit-diff { grid-template-columns: 1fr; }
  .hero-panel { align-items: flex-start; }
  .status-orb { width: 86px; height: 86px; }
  .inline-form { grid-template-columns: 64px 1fr; }
  .inline-form button { grid-column: 1 / -1; }
  .ticket-review-alert { align-items: flex-start; flex-direction: column; }
  .hero-exception-alert, .hero-attendance-alert, .hero-schedule-alert, .hero-schedule-result-alert, .hero-ticket-overdue-alert { align-items: center; flex-direction: row; padding: .38rem .55rem; font-size: .7rem; }
  .ticket-line-head { display: none; }
  .electronic-ticket-line { grid-template-columns: minmax(0,1fr) minmax(0,1fr); align-items: end; }
  .electronic-ticket-line label:first-child { grid-column: 1 / -1; }
  .ticket-custom-item-form { grid-template-columns: minmax(0,1fr) minmax(0,1fr); }
  .ticket-custom-item-form label:first-child, .ticket-custom-item-form button { grid-column: 1 / -1; }
  .electronic-ticket-line label > span { display: block; }
  .ticket-line-amount { justify-content: flex-start; }
  .electronic-ticket-line .remove-ticket-line { justify-self: stretch; }
}

@media (max-width: 390px) {
  .topbar { padding-inline: .5rem; }
  .brand-logo { width: 112px; }
  .topbar form button { padding-inline: .55rem; }
  .hero-panel { display: block; }
  #business-date-heading { font-size: clamp(1.2rem, 6vw, 1.45rem); }
  .status-orb { width: auto; height: auto; border-radius: 10px; margin-top: .8rem; padding: .6rem; }
  .record-card dl div { grid-template-columns: minmax(0, 1fr); gap: .15rem; }
  .record-card dd { text-align: left; overflow-wrap: anywhere; }
  .section-heading { align-items: flex-start; }
  .schedule-section-summary > span:last-child { font-size: 0; }
  .schedule-section-summary > span:last-child b { font-size: 1rem; }
  .schedule-month-header { gap: .35rem; }
  .schedule-month-header .button-link { min-height: 42px; padding-inline: .55rem; }
  .schedule-month-header h2 { font-size: 1.05rem; }
  .record-card { padding: .8rem; }
  .pager, .section-heading { flex-wrap: wrap; }
  .electronic-ticket-switcher { gap: .45rem; }
  .electronic-ticket-switcher .ticket-mode-button { padding-inline: .45rem; font-size: .82rem; }
  .electronic-ticket-link { align-items: flex-start; flex-direction: column; }
  .electronic-ticket-link-side { width: 100%; justify-content: space-between; text-align: left; }
  .ticket-editor-actions { grid-template-columns: minmax(0,1fr); }
  .ticket-set-summary { align-items: flex-start; flex-direction: column; }
  .ticket-set-charge-fields { grid-template-columns: minmax(0,1fr); }
  .ticket-set-times > div { grid-template-columns: minmax(0,1fr); gap: .12rem; }
  .ticket-set-times dd { text-align: left; }
  .ticket-set-extension-buttons { grid-template-columns: minmax(0,1fr); }
  .electronic-sales-lines a { grid-template-columns: minmax(0,1fr) auto; }
  .electronic-sales-lines a > em { grid-column: 1 / -1; justify-self: start; }
}
