/* ==========================================================================
   Design system — tokens, reset, layout, components.
   The :root block below is the single source of truth for the brand: change
   --accent and every component follows. Nothing else needs editing.
   ========================================================================== */

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

/* The UA [hidden] rule loses to .card/.grid/.stack display values, so any
   element toggled via the hidden property must win explicitly. */
[hidden] { display: none !important; }

:root {
  /* Colour — light theme. Override these five and the whole UI follows. */
  --accent: #4f46e5;
  --accent-hover: color-mix(in srgb, var(--accent) 88%, black);
  --accent-soft: color-mix(in srgb, var(--accent) 12%, white);
  --accent-contrast: #ffffff;

  --bg: #f6f7fb;
  --surface: #ffffff;
  --surface-2: #f2f3f8;
  --surface-3: #e9ebf3;
  --border: #e3e6ef;
  --border-strong: #cfd4e2;
  --text: #101322;
  --text-soft: #45506b;
  --muted: #6b7590;

  --success: #0f9d68;
  --success-soft: #e4f7ee;
  --warning: #b7791f;
  --warning-soft: #fdf3e2;
  --danger: #d4443c;
  --danger-soft: #fdeceb;
  --info: #2563eb;
  --info-soft: #e8f0fe;

  /* Type */
  --font-sans: "Inter", "SF Pro Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans SC", sans-serif;
  --font-mono: "JetBrains Mono", "SF Mono", ui-monospace, "Cascadia Code", Menlo, Consolas, monospace;
  --fs-xs: 0.75rem;
  --fs-sm: 0.8125rem;
  --fs-base: 0.9375rem;
  --fs-md: 1.0625rem;
  --fs-lg: 1.3125rem;
  --fs-xl: 1.75rem;
  --fs-2xl: 2.25rem;
  --fs-3xl: 3rem;
  --lh-tight: 1.2;
  --lh-base: 1.6;

  /* Space — 4px scale */
  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px;
  --s-5: 20px; --s-6: 24px; --s-8: 32px; --s-10: 40px;
  --s-12: 48px; --s-16: 64px;

  /* Shape + depth */
  --r-sm: 6px; --r-md: 10px; --r-lg: 14px; --r-xl: 20px; --r-full: 999px;
  --shadow-sm: 0 1px 2px rgb(16 19 34 / 6%), 0 1px 3px rgb(16 19 34 / 4%);
  --shadow-md: 0 4px 12px rgb(16 19 34 / 8%), 0 2px 4px rgb(16 19 34 / 4%);
  --shadow-lg: 0 16px 40px rgb(16 19 34 / 12%), 0 4px 12px rgb(16 19 34 / 5%);
  --ring: 0 0 0 3px color-mix(in srgb, var(--accent) 28%, transparent);
  --sidebar-w: 248px;
  --topbar-h: 60px;
  --ease: cubic-bezier(0.2, 0, 0.13, 1);
}

[data-theme="dark"] {
  --accent-soft: color-mix(in srgb, var(--accent) 22%, #0b0e17);
  --bg: #0b0e17;
  --surface: #121724;
  --surface-2: #171d2c;
  --surface-3: #1e2536;
  --border: #232b3d;
  --border-strong: #313a50;
  --text: #eef1f8;
  --text-soft: #c2c9da;
  --muted: #8b95ac;
  --success: #34d399; --success-soft: #10301f;
  --warning: #fbbf24; --warning-soft: #33260c;
  --danger: #f87171; --danger-soft: #3a1618;
  --info: #60a5fa; --info-soft: #12233d;
  --shadow-sm: 0 1px 2px rgb(0 0 0 / 40%);
  --shadow-md: 0 6px 18px rgb(0 0 0 / 45%);
  --shadow-lg: 0 20px 48px rgb(0 0 0 / 55%);
  color-scheme: dark;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --accent-soft: color-mix(in srgb, var(--accent) 22%, #0b0e17);
    --bg: #0b0e17; --surface: #121724; --surface-2: #171d2c; --surface-3: #1e2536;
    --border: #232b3d; --border-strong: #313a50;
    --text: #eef1f8; --text-soft: #c2c9da; --muted: #8b95ac;
    --success: #34d399; --success-soft: #10301f;
    --warning: #fbbf24; --warning-soft: #33260c;
    --danger: #f87171; --danger-soft: #3a1618;
    --info: #60a5fa; --info-soft: #12233d;
    color-scheme: dark;
  }
}

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--fs-base);
  line-height: var(--lh-base);
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 { margin: 0 0 var(--s-3); line-height: var(--lh-tight); letter-spacing: -0.015em; font-weight: 650; }
h1 { font-size: var(--fs-2xl); }
h2 { font-size: var(--fs-xl); }
h3 { font-size: var(--fs-lg); }
h4 { font-size: var(--fs-md); }
p { margin: 0 0 var(--s-4); color: var(--text-soft); }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 2px; }
small { font-size: var(--fs-sm); }
hr { border: 0; border-top: 1px solid var(--border); margin: var(--s-6) 0; }
img, svg { max-width: 100%; }
code, pre, kbd { font-family: var(--font-mono); font-size: 0.875em; }
code { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 1px 5px; }
pre { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r-md); padding: var(--s-4); overflow: auto; }

:focus-visible { outline: none; box-shadow: var(--ring); border-radius: var(--r-sm); }

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--accent); color: var(--accent-contrast); padding: var(--s-2) var(--s-4);
}
.skip-link:focus { left: var(--s-2); top: var(--s-2); }

/* ---------------------------------------------------------------- shell -- */
.shell { display: grid; grid-template-columns: var(--sidebar-w) 1fr; min-height: 100vh; }

.sidebar {
  position: sticky; top: 0; height: 100vh; overflow-y: auto;
  background: var(--surface); border-right: 1px solid var(--border);
  display: flex; flex-direction: column; padding: var(--s-4) var(--s-3);
  gap: var(--s-2);
}
.brand { display: flex; align-items: center; gap: var(--s-3); padding: var(--s-2) var(--s-3) var(--s-4); font-weight: 700; font-size: var(--fs-md); color: var(--text); letter-spacing: -0.02em; }
.brand:hover { text-decoration: none; }
.brand-mark {
  width: 30px; height: 30px; flex: none; display: block;
  filter: drop-shadow(0 2px 4px rgb(24 16 70 / 0.28));
}
.nav-group { display: flex; flex-direction: column; gap: 2px; }
.nav { display: flex; flex-direction: column; gap: var(--s-1); }
.nav-label { font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); padding: var(--s-3) var(--s-3) var(--s-1); font-weight: 600; }
.nav-item {
  display: flex; align-items: center; gap: var(--s-3); padding: var(--s-2) var(--s-3);
  border-radius: var(--r-md); color: var(--text-soft); font-weight: 500; font-size: var(--fs-base);
  transition: background 120ms var(--ease), color 120ms var(--ease);
}
.nav-item:hover { background: var(--surface-2); color: var(--text); text-decoration: none; }
.nav-item.is-active { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.nav-item .icon { width: 18px; height: 18px; flex: none; opacity: 0.85; }
.sidebar-footer { margin-top: auto; padding-top: var(--s-4); border-top: 1px solid var(--border); }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar {
  height: var(--topbar-h); display: flex; align-items: center; gap: var(--s-4);
  padding: 0 var(--s-6); border-bottom: 1px solid var(--border);
  background: color-mix(in srgb, var(--surface) 82%, transparent);
  backdrop-filter: blur(10px); position: sticky; top: 0; z-index: 20;
}
.topbar .spacer { flex: 1; }
.page { padding: var(--s-8) var(--s-6) var(--s-16); max-width: 1240px; width: 100%; margin: 0 auto; }
.page-header { display: flex; align-items: flex-start; gap: var(--s-4); flex-wrap: wrap; margin-bottom: var(--s-6); }
.page-header .grow { flex: 1; min-width: 240px; }
.page-header h1 { font-size: var(--fs-xl); margin-bottom: var(--s-1); }
.page-header p { margin: 0; color: var(--muted); font-size: var(--fs-sm); }

@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed; inset: 0 auto 0 0; width: min(84vw, var(--sidebar-w)); z-index: 60;
    transform: translateX(-102%); transition: transform 220ms var(--ease); box-shadow: var(--shadow-lg);
  }
  body.nav-open .sidebar { transform: translateX(0); }
  .nav-scrim { position: fixed; inset: 0; background: rgb(6 9 16 / 48%); z-index: 55; opacity: 0; pointer-events: none; transition: opacity 200ms var(--ease); }
  body.nav-open .nav-scrim { opacity: 1; pointer-events: auto; }
  .page { padding: var(--s-6) var(--s-4) var(--s-12); }
  .topbar { padding: 0 var(--s-4); }
}

/* --------------------------------------------------------------- pieces -- */
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm); padding: var(--s-5);
}
.card + .card { margin-top: var(--s-4); }
.card-header { display: flex; align-items: center; gap: var(--s-3); margin-bottom: var(--s-4); }
.card-header h3, .card-header h2 { margin: 0; font-size: var(--fs-md); }
.card-header .actions { margin-left: auto; display: flex; gap: var(--s-2); }
.card-flush { padding: 0; overflow: hidden; }

.grid { display: grid; gap: var(--s-4); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-auto { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
@media (max-width: 1100px) { .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 860px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

.stack { display: flex; flex-direction: column; gap: var(--s-4); }
.row { display: flex; align-items: center; gap: var(--s-3); flex-wrap: wrap; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: var(--s-3); flex-wrap: wrap; }
.mt-0 { margin-top: 0; } .mt-2 { margin-top: var(--s-2); } .mt-4 { margin-top: var(--s-4); } .mt-6 { margin-top: var(--s-6); }
.mb-0 { margin-bottom: 0; } .mb-2 { margin-bottom: var(--s-2); } .mb-4 { margin-bottom: var(--s-4); }
.muted { color: var(--muted); }
.text-sm { font-size: var(--fs-sm); }
.text-xs { font-size: var(--fs-xs); }
.text-right { text-align: right; }
.text-center { text-align: center; }
.mono { font-family: var(--font-mono); }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nowrap { white-space: nowrap; }

/* stats */
.stat { display: flex; flex-direction: column; gap: var(--s-1); }
.stat-label { font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); font-weight: 600; }
.stat-value { font-size: var(--fs-xl); font-weight: 650; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.stat-delta { font-size: var(--fs-xs); font-weight: 600; }
.stat-delta.up { color: var(--success); }
.stat-delta.down { color: var(--danger); }

/* -------------------------------------------------------------- buttons -- */
.btn {
  --btn-bg: var(--surface); --btn-fg: var(--text); --btn-border: var(--border-strong);
  display: inline-flex; align-items: center; justify-content: center; gap: var(--s-2);
  min-height: 38px; padding: 0 var(--s-4); border-radius: var(--r-md);
  border: 1px solid var(--btn-border); background: var(--btn-bg); color: var(--btn-fg);
  font: inherit; font-weight: 600; font-size: var(--fs-sm); cursor: pointer;
  transition: transform 100ms var(--ease), background 120ms var(--ease), border-color 120ms var(--ease), box-shadow 120ms var(--ease);
  text-decoration: none; white-space: nowrap; user-select: none;
}
.btn:hover { background: var(--surface-2); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn[disabled], .btn.is-disabled { opacity: 0.55; pointer-events: none; }
.btn-primary { --btn-bg: var(--accent); --btn-fg: var(--accent-contrast); --btn-border: var(--accent); box-shadow: 0 1px 2px color-mix(in srgb, var(--accent) 40%, transparent); }
.btn-primary:hover { background: var(--accent-hover); }
.btn-soft { --btn-bg: var(--accent-soft); --btn-fg: var(--accent); --btn-border: transparent; }
.btn-soft:hover { background: color-mix(in srgb, var(--accent) 18%, var(--surface)); }
.btn-ghost { --btn-bg: transparent; --btn-border: transparent; }
.btn-ghost:hover { background: var(--surface-2); }
.btn-danger { --btn-bg: var(--danger); --btn-fg: #fff; --btn-border: var(--danger); }
.btn-danger:hover { background: color-mix(in srgb, var(--danger) 88%, black); }
.btn-sm { min-height: 30px; padding: 0 var(--s-3); font-size: var(--fs-xs); border-radius: var(--r-sm); }
.btn-lg { min-height: 46px; padding: 0 var(--s-6); font-size: var(--fs-base); border-radius: var(--r-lg); }
.btn-icon { width: 36px; padding: 0; }
.btn-block { width: 100%; }

.icon-btn {
  display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: var(--r-md);
  border: 1px solid transparent; background: transparent; color: var(--muted); cursor: pointer;
}
.icon-btn:hover { background: var(--surface-2); color: var(--text); }

/* --------------------------------------------------------------- forms -- */
.field { display: flex; flex-direction: column; gap: var(--s-2); margin-bottom: var(--s-4); }
.field > label, .label { font-size: var(--fs-sm); font-weight: 600; color: var(--text-soft); }
.field .hint { font-size: var(--fs-xs); color: var(--muted); }
.hint-inline { margin: 0 0 var(--s-4); font-size: var(--fs-xs); line-height: 1.6; color: var(--muted); }
.hint-inline .badge { margin-left: var(--s-1); }
.field .field-errors { margin: 0; padding-left: var(--s-4); color: var(--danger); font-size: var(--fs-xs); }

.input, .select, .textarea {
  width: 100%; min-height: 40px; padding: var(--s-2) var(--s-3);
  border: 1px solid var(--border-strong); border-radius: var(--r-md);
  background: var(--surface); color: var(--text); font: inherit; font-size: var(--fs-base);
  transition: border-color 120ms var(--ease), box-shadow 120ms var(--ease);
}
.textarea { min-height: 110px; resize: vertical; line-height: 1.55; }
.input::placeholder, .textarea::placeholder { color: var(--muted); }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--accent); box-shadow: var(--ring); }
.input.has-error, .textarea.has-error { border-color: var(--danger); }
.input-sm { min-height: 32px; font-size: var(--fs-sm); }

.input-group { display: flex; gap: var(--s-2); align-items: center; }
.input-group .input { flex: 1; }

.checkbox, .radio { display: flex; align-items: flex-start; gap: var(--s-2); font-size: var(--fs-sm); color: var(--text-soft); }
.checkbox input, .radio input { margin-top: 3px; width: 16px; height: 16px; accent-color: var(--accent); }

.switch { position: relative; display: inline-flex; align-items: center; gap: var(--s-3); cursor: pointer; font-size: var(--fs-sm); }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.switch-track { width: 38px; height: 22px; border-radius: var(--r-full); background: var(--surface-3); border: 1px solid var(--border-strong); position: relative; transition: background 160ms var(--ease); }
.switch-track::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--surface); box-shadow: var(--shadow-sm); transition: transform 160ms var(--ease); }
.switch input:checked + .switch-track { background: var(--accent); border-color: var(--accent); }
.switch input:checked + .switch-track::after { transform: translateX(16px); background: #fff; }
.switch input:focus-visible + .switch-track { box-shadow: var(--ring); }

.search-input { position: relative; }
.search-input .input { padding-left: 34px; }
.search-input svg { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--muted); pointer-events: none; }

/* --------------------------------------------------------------- table -- */
.table-wrap { overflow-x: auto; border-radius: var(--r-lg); border: 1px solid var(--border); background: var(--surface); }
table.table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.table th {
  text-align: left; font-size: var(--fs-xs); font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.05em; color: var(--muted); padding: var(--s-3) var(--s-4);
  border-bottom: 1px solid var(--border); background: var(--surface-2); white-space: nowrap;
}
.table td { padding: var(--s-3) var(--s-4); border-bottom: 1px solid var(--border); vertical-align: middle; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: color-mix(in srgb, var(--surface-2) 60%, transparent); }
.table .num { font-variant-numeric: tabular-nums; text-align: right; }
.table-actions { display: flex; gap: var(--s-1); justify-content: flex-end; }

/* ----------------------------------------------------------- week grid -- */
.week-toolbar {
  display: flex; align-items: center; gap: var(--s-2); flex-wrap: wrap;
  padding: var(--s-2); margin-bottom: var(--s-3);
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--r-lg); box-shadow: var(--shadow-sm);
}
.week-toolbar .range {
  padding: 0 var(--s-2); font-size: var(--fs-sm); font-weight: 600;
  color: var(--text); font-variant-numeric: tabular-nums; white-space: nowrap;
}
.week-toolbar .spacer { flex: 1 1 auto; }
/* The date input is a single control, not a form field: stop it filling the bar. */
.ghost-form { display: flex; align-items: center; gap: var(--s-2); margin: 0; }
.ghost-form .input { width: auto; min-width: 148px; flex: none; }

.week-grid-wrap {
  overflow-x: auto; border-radius: var(--r-lg);
  border: 1px solid var(--border); background: var(--surface);
  box-shadow: var(--shadow-sm);
}
table.week-grid { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.week-grid th {
  position: sticky; top: 0; z-index: 1;
  padding: var(--s-3) var(--s-3) var(--s-2); text-align: left;
  font-size: var(--fs-xs); font-weight: 600; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.04em; white-space: nowrap;
  border-bottom: 1px solid var(--border); background: var(--surface-2);
}
.week-grid td { padding: var(--s-2) var(--s-3); border-bottom: 1px solid var(--border); vertical-align: middle; }
.week-grid tbody tr:last-child td { border-bottom: 0; }
.week-grid tbody tr:hover { background: color-mix(in srgb, var(--surface-2) 55%, transparent); }
.week-grid .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.week-grid .cell-sub { display: block; font-size: 10px; font-weight: 600; color: var(--muted); letter-spacing: 0.01em; }
.week-grid th .cell-sub { text-transform: none; }

/* Name column stays put while the seven days scroll past it. */
.week-grid .employee-col {
  position: sticky; left: 0; z-index: 2;
  min-width: 176px; background: var(--surface); text-align: left;
}
.week-grid th.employee-col { z-index: 3; background: var(--surface-2); }
.week-grid tbody tr:hover .employee-col { background: color-mix(in srgb, var(--surface-2) 55%, var(--surface)); }
.week-grid .employee-name { font-weight: 600; color: var(--text); text-decoration: none; }
.week-grid .employee-name:hover { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.week-grid .employee-code { display: block; font-size: 10px; color: var(--muted); font-variant-numeric: tabular-nums; }
.week-grid .cell-minutes { font-weight: 600; }
.week-grid .cell-open { color: var(--warning); font-weight: 600; }

.week-grid .is-today { color: var(--accent); background: var(--accent-soft); }
.week-grid .day-holiday { background: color-mix(in srgb, var(--warning-soft) 70%, transparent); }
.week-grid th.day-holiday { color: var(--warning); }
.week-grid td.cell-open { background: color-mix(in srgb, var(--warning-soft) 55%, transparent); }
.week-grid tr.is-flagged td { background: color-mix(in srgb, var(--danger-soft) 45%, transparent); }
.week-grid tr.is-flagged .employee-name { color: var(--danger); }
.week-grid tfoot td {
  padding: var(--s-3); border-top: 1px solid var(--border-strong); border-bottom: 0;
  background: var(--surface-2); font-weight: 650; color: var(--text);
}
.week-grid tfoot .employee-col { background: var(--surface-2); }

@media (max-width: 760px) {
  .week-grid .employee-col { min-width: 140px; }
  .week-grid th, .week-grid td { padding: var(--s-2); }
  .week-toolbar .spacer { display: none; }
  .ghost-form { width: 100%; }
  .ghost-form .input { flex: 1; min-width: 0; }
}

/* --------------------------------------------------------------- badges -- */
.badge {
  display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px; border-radius: var(--r-full);
  font-size: var(--fs-xs); font-weight: 600; line-height: 1.7; border: 1px solid transparent;
  background: var(--surface-2); color: var(--text-soft); white-space: nowrap;
}
.badge-dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-success { background: var(--success-soft); color: var(--success); }
.badge-warning { background: var(--warning-soft); color: var(--warning); }
.badge-danger { background: var(--danger-soft); color: var(--danger); }
.badge-info { background: var(--info-soft); color: var(--info); }
.badge-accent { background: var(--accent-soft); color: var(--accent); }
/* Not yet sent for approval: neutral, and visibly provisional. */
.badge-draft { background: var(--surface-3); color: var(--text-soft); border-color: var(--border-strong); border-style: dashed; }

/* --------------------------------------------------------------- alerts -- */
.flash {
  display: flex; align-items: flex-start; gap: var(--s-3); padding: var(--s-3) var(--s-4);
  border-radius: var(--r-md); border: 1px solid var(--border); background: var(--surface);
  font-size: var(--fs-sm); margin-bottom: var(--s-4); animation: slide-in 260ms var(--ease);
}
.flash-success { background: var(--success-soft); border-color: color-mix(in srgb, var(--success) 28%, transparent); color: var(--success); }
.flash-error { background: var(--danger-soft); border-color: color-mix(in srgb, var(--danger) 28%, transparent); color: var(--danger); }
.flash-info { background: var(--info-soft); border-color: color-mix(in srgb, var(--info) 28%, transparent); color: var(--info); }

.alert { padding: var(--s-4); border-radius: var(--r-md); border: 1px solid var(--border); background: var(--surface-2); font-size: var(--fs-sm); }
.alert-warning { background: var(--warning-soft); border-color: color-mix(in srgb, var(--warning) 30%, transparent); }

/* ---------------------------------------------------------------- empty -- */
.empty { text-align: center; padding: var(--s-12) var(--s-4); color: var(--muted); }
.empty-mark {
  width: 52px; height: 52px; border-radius: var(--r-lg); margin: 0 auto var(--s-4);
  display: grid; place-items: center; background: var(--surface-2); border: 1px dashed var(--border-strong); color: var(--muted);
}
.empty h3 { font-size: var(--fs-md); color: var(--text); margin-bottom: var(--s-1); }
.empty p { margin: 0 auto var(--s-4); max-width: 42ch; font-size: var(--fs-sm); }

/* ------------------------------------------------------------ pagination -- */
.pagination { display: flex; align-items: center; gap: var(--s-2); justify-content: space-between; flex-wrap: wrap; margin-top: var(--s-4); }
.pagination .pages { display: flex; gap: var(--s-1); }
.page-link {
  min-width: 34px; height: 34px; display: inline-grid; place-items: center; padding: 0 var(--s-2);
  border-radius: var(--r-sm); border: 1px solid var(--border); background: var(--surface);
  color: var(--text-soft); font-size: var(--fs-sm); font-weight: 500;
}
.page-link:hover { background: var(--surface-2); text-decoration: none; }
.page-link.is-current { background: var(--accent); border-color: var(--accent); color: var(--accent-contrast); font-weight: 700; }

/* ---------------------------------------------------------------- modal -- */
.modal { position: fixed; inset: 0; z-index: 80; display: none; align-items: center; justify-content: center; padding: var(--s-4); }
.modal.is-open { display: flex; }
.modal-backdrop { position: absolute; inset: 0; background: rgb(6 9 16 / 52%); backdrop-filter: blur(2px); }
.modal-panel {
  position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-xl);
  box-shadow: var(--shadow-lg); width: min(560px, 100%); max-height: 88vh; overflow: auto;
  padding: var(--s-6); animation: pop-in 200ms var(--ease);
}
.modal-panel h2 { font-size: var(--fs-lg); }
.modal-close { position: absolute; top: var(--s-3); right: var(--s-3); }

/* -------------------------------------------------------------- dropdown -- */
.dropdown { position: relative; }
.dropdown-menu {
  position: absolute; right: 0; top: calc(100% + 6px); min-width: 190px; z-index: 40;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-md);
  box-shadow: var(--shadow-md); padding: var(--s-1); display: none;
}
.dropdown.is-open .dropdown-menu { display: block; animation: pop-in 140ms var(--ease); }
.dropdown-item {
  display: flex; align-items: center; gap: var(--s-2); padding: var(--s-2) var(--s-3);
  border-radius: var(--r-sm); color: var(--text-soft); font-size: var(--fs-sm); width: 100%;
  background: none; border: 0; text-align: left; cursor: pointer; font-family: inherit;
}
.dropdown-item:hover { background: var(--surface-2); color: var(--text); text-decoration: none; }
.dropdown-sep { height: 1px; background: var(--border); margin: var(--s-1); }

/* ---------------------------------------------------------------- toast -- */
.toasts { position: fixed; right: var(--s-4); bottom: var(--s-4); z-index: 90; display: flex; flex-direction: column; gap: var(--s-2); }
.toast {
  background: var(--surface); border: 1px solid var(--border); border-left: 3px solid var(--accent);
  border-radius: var(--r-md); box-shadow: var(--shadow-md); padding: var(--s-3) var(--s-4);
  font-size: var(--fs-sm); min-width: 240px; animation: slide-in 200ms var(--ease);
}
.toast-success { border-left-color: var(--success); }
.toast-error { border-left-color: var(--danger); }

/* ---------------------------------------------------------------- tabs -- */
.tabs { display: flex; gap: var(--s-1); border-bottom: 1px solid var(--border); margin-bottom: var(--s-5); overflow-x: auto; }
.tab {
  padding: var(--s-2) var(--s-4); border: 0; background: none; color: var(--muted);
  font: inherit; font-size: var(--fs-sm); font-weight: 600; cursor: pointer; border-bottom: 2px solid transparent;
  white-space: nowrap;
}
.tab:hover { color: var(--text); }
.tab.is-active { color: var(--accent); border-bottom-color: var(--accent); }

/* ------------------------------------------------------------- progress -- */
.progress { height: 8px; border-radius: var(--r-full); background: var(--surface-3); overflow: hidden; }
.progress-bar { height: 100%; background: var(--accent); border-radius: inherit; transition: width 400ms var(--ease); }

.avatar {
  width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: var(--accent-soft); color: var(--accent); font-weight: 700; font-size: var(--fs-sm); overflow: hidden;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar-lg { width: 56px; height: 56px; font-size: var(--fs-md); }

/* ---------------------------------------------------------------- auth -- */
.auth-shell { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; }
.auth-aside {
  background:
    radial-gradient(1200px 600px at 10% 0%, color-mix(in srgb, var(--accent) 30%, transparent), transparent 60%),
    linear-gradient(160deg, #0c1020, #131a2f 55%, #0a0d17);
  color: #fff; padding: var(--s-12); display: flex; flex-direction: column; justify-content: space-between;
}
.auth-aside h1 { font-size: var(--fs-3xl); letter-spacing: -0.03em; line-height: 1.1; max-width: 22ch; }
.auth-aside p { color: rgb(255 255 255 / 72%); max-width: 44ch; }
.auth-points { display: flex; flex-direction: column; gap: var(--s-4); margin-top: var(--s-8); }
.auth-point { display: flex; gap: var(--s-3); align-items: flex-start; font-size: var(--fs-sm); color: rgb(255 255 255 / 82%); }
.auth-point .dot { width: 22px; height: 22px; border-radius: 50%; background: rgb(255 255 255 / 12%); display: grid; place-items: center; flex: none; font-size: 11px; }
.auth-main { display: grid; place-items: center; padding: var(--s-8) var(--s-4); background: var(--bg); }
.auth-card { width: min(400px, 100%); }
.auth-card h2 { font-size: var(--fs-xl); margin-bottom: var(--s-1); }
.auth-card .sub { color: var(--muted); font-size: var(--fs-sm); margin-bottom: var(--s-6); }
@media (max-width: 900px) { .auth-shell { grid-template-columns: 1fr; } .auth-aside { display: none; } }

/* ------------------------------------------------------------ installer -- */
.install-shell { min-height: 100vh; display: grid; place-items: center; padding: var(--s-6) var(--s-4); }
.install-panel { width: min(760px, 100%); }
.install-steps { display: flex; gap: var(--s-2); margin-bottom: var(--s-6); flex-wrap: wrap; }
.install-step {
  display: flex; align-items: center; gap: var(--s-2); padding: var(--s-2) var(--s-3);
  border-radius: var(--r-full); font-size: var(--fs-xs); font-weight: 600;
  background: var(--surface-2); color: var(--muted); border: 1px solid var(--border);
}
.install-step.is-done { background: var(--success-soft); color: var(--success); border-color: transparent; }
.install-step.is-current { background: var(--accent-soft); color: var(--accent); border-color: transparent; }
.check-row { display: flex; align-items: center; gap: var(--s-3); padding: var(--s-2) 0; border-bottom: 1px solid var(--border); font-size: var(--fs-sm); }
.check-row:last-child { border-bottom: 0; }
.check-row .ok { color: var(--success); }
.check-row .bad { color: var(--danger); }
.check-row .detail { margin-left: auto; color: var(--muted); font-size: var(--fs-xs); }

/* ------------------------------------------------------------ animation -- */
@keyframes slide-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes pop-in { from { opacity: 0; transform: scale(0.97); } to { opacity: 1; transform: none; } }
@keyframes skeleton { 0% { background-position: 100% 0; } 100% { background-position: -100% 0; } }
.skeleton {
  border-radius: var(--r-sm); height: 14px;
  background: linear-gradient(90deg, var(--surface-2) 25%, var(--surface-3) 37%, var(--surface-2) 63%);
  background-size: 400% 100%; animation: skeleton 1.4s ease infinite;
}
.reveal { animation: slide-in 320ms var(--ease) both; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* ---------------------------------------------------------------- print -- */
@media print {
  .sidebar, .topbar, .no-print, .toasts { display: none !important; }
  .shell { grid-template-columns: 1fr; }
  .page { padding: 0; max-width: none; }
  body { background: #fff; color: #000; }
  .card { border: 1px solid #ddd; box-shadow: none; break-inside: avoid; }
}

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* --------------------------------------------------------------- prose -- */
.prose { font-size: var(--fs-md); line-height: 1.7; color: var(--text-soft); }
.prose > *:first-child { margin-top: 0; }
.prose h1, .prose h2, .prose h3, .prose h4 { color: var(--text); margin: var(--s-8) 0 var(--s-3); }
.prose h2 { font-size: var(--fs-xl); padding-bottom: var(--s-2); border-bottom: 1px solid var(--border); }
.prose h3 { font-size: var(--fs-lg); }
.prose p { margin: 0 0 var(--s-4); }
.prose ul, .prose ol { margin: 0 0 var(--s-4); padding-left: var(--s-6); }
.prose li { margin-bottom: var(--s-1); }
.prose li::marker { color: var(--muted); }
.prose a { text-decoration: underline; text-underline-offset: 2px; }
.prose code { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 1px 5px; font-size: 0.875em; }
.prose pre { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r-md); padding: var(--s-4); overflow-x: auto; margin: 0 0 var(--s-4); }
.prose pre code { background: none; border: 0; padding: 0; font-size: var(--fs-sm); }
.prose blockquote { margin: 0 0 var(--s-4); padding: var(--s-2) var(--s-4); border-left: 3px solid var(--accent); background: var(--accent-soft); border-radius: 0 var(--r-md) var(--r-md) 0; }
.prose blockquote p:last-child { margin-bottom: 0; }
.prose hr { margin: var(--s-6) 0; }
.prose img { border-radius: var(--r-md); border: 1px solid var(--border); }
.prose table { width: 100%; border-collapse: collapse; margin-bottom: var(--s-4); font-size: var(--fs-sm); }
.prose th, .prose td { border: 1px solid var(--border); padding: var(--s-2) var(--s-3); text-align: left; }
.prose th { background: var(--surface-2); }

/* ------------------------------------------------- leave & shift planning -- */
.muted-xs { font-size: var(--fs-xs); color: var(--muted); }
.row-actions { display: flex; gap: var(--s-2); align-items: center; justify-content: flex-end; flex-wrap: wrap; }
.filter-bar { display: flex; gap: var(--s-3); align-items: flex-end; flex-wrap: wrap; }
.filter-bar .grow { flex: 1; min-width: 150px; }
.leave-rules { margin: 0; padding-left: var(--s-5); color: var(--text-soft); font-size: var(--fs-sm); line-height: 1.7; }
.leave-decide { flex-direction: column; align-items: stretch; }
.leave-decide form { display: flex; gap: var(--s-2); }
.leave-reject .input { min-width: 0; flex: 1; }

.calendar-table th, .calendar-table td { padding: var(--s-1) var(--s-1); text-align: center; vertical-align: top; }
.calendar-table .calendar-name { text-align: left; min-width: 140px; position: sticky; left: 0; background: var(--surface); z-index: 1; }
.calendar-day, .calendar-cell { min-width: 34px; }
.calendar-weekday { display: block; font-size: 10px; font-weight: 700; color: var(--muted); }
.calendar-cell.is-weekend, .calendar-day.is-weekend { background: var(--surface-2); }
.calendar-day.is-holiday, .calendar-cell.is-holiday { background: var(--warning-soft); }
.calendar-entry { font-size: 10px; padding: 1px 4px; margin: 1px 0; }
.calendar-legend { display: flex; gap: var(--s-2); align-items: center; flex-wrap: wrap; margin-top: var(--s-3); }

.schedule-toolbar { display: flex; gap: var(--s-2); align-items: center; flex-wrap: wrap; margin-top: var(--s-2); }
.schedule-table th, .schedule-table td { vertical-align: top; }
.schedule-table .schedule-name { text-align: left; min-width: 140px; position: sticky; left: 0; background: var(--surface); z-index: 1; }
.schedule-day, .schedule-cell { min-width: 132px; }
.schedule-weekday { display: block; font-weight: 600; }
.schedule-day.is-weekend, .schedule-cell.is-weekend { background: var(--surface-2); }
.shift-card { border: 1px solid var(--border); border-radius: var(--r-sm); padding: var(--s-1) var(--s-2); margin-bottom: var(--s-1); background: var(--surface); }
.shift-card summary { cursor: pointer; display: flex; flex-direction: column; gap: 1px; list-style: none; }
.shift-card summary::-webkit-details-marker { display: none; }
.shift-time { font-weight: 600; font-size: var(--fs-xs); font-variant-numeric: tabular-nums; }
.shift-form { margin-top: var(--s-2); display: flex; flex-direction: column; gap: var(--s-2); }
.shift-form label { display: flex; flex-direction: column; gap: 2px; font-size: 10px; color: var(--muted); font-weight: 600; }
.shift-form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-1); }
.shift-add summary { cursor: pointer; color: var(--accent); font-weight: 700; padding: var(--s-1); list-style: none; }
.shift-add summary::-webkit-details-marker { display: none; }

/* --------------------------------------------------- timesheet detail -- */
.totals {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
  gap: var(--s-4) var(--s-5); padding: var(--s-5);
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--r-lg); box-shadow: var(--shadow-sm);
}
.totals .stat-value { font-size: var(--fs-lg); }
.totals .stat:last-child { grid-column: span 2; }
.totals .stat:last-child .stat-value { font-size: var(--fs-xl); }
@media (max-width: 700px) { .totals .stat:last-child { grid-column: auto; } }

.shift-list { display: flex; flex-direction: column; gap: var(--s-2); }
.shift {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--s-3);
  padding: var(--s-3) var(--s-4); border: 1px solid var(--border);
  border-radius: var(--r-md); background: var(--surface);
}
.shift + .shift { margin-top: 0; }
.shift.is-open {
  border-color: color-mix(in srgb, var(--warning) 40%, transparent);
  background: color-mix(in srgb, var(--warning-soft) 45%, var(--surface));
}
.shift-times {
  display: flex; align-items: center; gap: var(--s-2);
  font-size: var(--fs-base); font-weight: 650; letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums; color: var(--text);
}
.shift-arrow { color: var(--muted); font-weight: 400; }
.shift-meta { display: flex; align-items: center; gap: var(--s-2); flex-wrap: wrap; margin-top: 2px; font-size: var(--fs-xs); color: var(--muted); }
.shift-meta > span + span::before { content: "·"; margin-right: var(--s-2); color: var(--border-strong); }
.shift-meta .badge + .badge::before, .shift-meta .badge::before { content: none; margin: 0; }
.shift-punches { display: flex; gap: var(--s-1); flex-wrap: wrap; margin-top: var(--s-2); }
.punch-chip {
  display: inline-flex; align-items: center; gap: 5px; padding: 1px var(--s-2);
  border-radius: var(--r-sm); border: 1px solid var(--border);
  background: var(--surface-2); color: var(--text-soft);
  font-size: 11px; font-weight: 600; line-height: 1.8; white-space: nowrap;
}
.punch-chip .mono { color: var(--text); font-size: 11px; }
.punch-chip .late { color: var(--warning); font-weight: 700; cursor: help; }
.shift-adjustment {
  margin: var(--s-2) 0 0; padding-left: var(--s-3);
  border-left: 2px solid color-mix(in srgb, var(--info) 45%, transparent);
  font-size: var(--fs-xs); color: var(--text-soft);
}
.shift-amount {
  display: flex; align-items: flex-start; justify-content: flex-end;
  font-size: var(--fs-md); font-variant-numeric: tabular-nums; color: var(--text);
}
@media (max-width: 620px) {
  .shift { grid-template-columns: 1fr; }
  .shift-amount { justify-content: flex-start; }
}

/* ---------------------------------------------------------------- kiosk --
   Full-screen wall display. Always dark, whatever the console theme is:
   the layout sets data-theme="dark" and this block only adds the surface. */
.kiosk-body {
  min-height: 100vh;
  background:
    radial-gradient(900px 620px at 12% -10%, color-mix(in srgb, var(--accent) 30%, transparent), transparent 70%),
    radial-gradient(760px 520px at 92% 8%, rgb(14 116 144 / 22%), transparent 68%),
    var(--bg);
  background-attachment: fixed;
}
.kiosk {
  min-height: 100vh; display: flex; flex-direction: column; gap: var(--s-6);
  max-width: 1240px; margin: 0 auto; padding: var(--s-6) var(--s-6) var(--s-8);
}
.kiosk .flash { max-width: 560px; margin: 0 auto; width: 100%; }

.kiosk-top { display: flex; align-items: center; gap: var(--s-5); flex-wrap: wrap; }
.kiosk-brand { display: flex; align-items: center; gap: var(--s-3); font-size: var(--fs-lg); font-weight: 700; letter-spacing: -0.02em; }
.kiosk-mark { width: 44px; height: 44px; flex: none; display: block; filter: drop-shadow(0 6px 14px rgb(79 70 229 / 45%)); }
.kiosk-site { display: flex; flex-direction: column; gap: 1px; padding-left: var(--s-5); border-left: 1px solid rgb(255 255 255 / 12%); }
.kiosk-site strong { font-size: var(--fs-base); font-weight: 650; }
.kiosk-clock {
  margin-left: auto; font-size: 2.125rem; font-weight: 650; letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums; color: var(--text);
}
.kiosk-badges { display: flex; align-items: center; gap: var(--s-2); }
.kiosk-badge {
  display: inline-flex; align-items: center; gap: var(--s-2); padding: 6px 12px;
  border-radius: var(--r-full); font-size: var(--fs-xs); font-weight: 650;
  border: 1px solid transparent; white-space: nowrap;
}
.kiosk-badge::before { content: ""; width: 7px; height: 7px; border-radius: var(--r-full); background: currentColor; box-shadow: 0 0 0 3px color-mix(in srgb, currentColor 22%, transparent); }
.kiosk-badge.is-quiet { color: var(--success); background: var(--success-soft); border-color: color-mix(in srgb, var(--success) 30%, transparent); }
.kiosk-badge.is-warn { color: var(--warning); background: var(--warning-soft); border-color: color-mix(in srgb, var(--warning) 32%, transparent); }

.kiosk-grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr); gap: var(--s-5); align-items: start; }
.kiosk-panel {
  background: color-mix(in srgb, var(--surface) 82%, transparent);
  border: 1px solid rgb(255 255 255 / 10%);
  border-radius: var(--r-xl);
  padding: var(--s-8);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(14px);
}
.kiosk-panel + .kiosk-panel { margin-top: 0; }
.kiosk-step-title { font-size: 2.25rem; font-weight: 650; letter-spacing: -0.03em; margin: 0 0 var(--s-2); }
.kiosk-note { display: block; margin: 0; font-size: var(--fs-sm); color: var(--muted); line-height: 1.5; }
.kiosk-side-title { font-size: var(--fs-md); font-weight: 650; margin: 0 0 var(--s-3); letter-spacing: -0.01em; }

.kiosk-display {
  display: flex; align-items: center; justify-content: center; gap: 2px;
  min-height: 112px; margin: var(--s-5) 0 var(--s-4); padding: var(--s-3) var(--s-5);
  border-radius: var(--r-lg);
  background: rgb(0 0 0 / 26%);
  border: 1px solid rgb(255 255 255 / 10%);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 6%), inset 0 -18px 40px rgb(0 0 0 / 22%);
  font-size: 3.25rem; font-weight: 600; letter-spacing: 0.42em; text-indent: 0.42em;
  font-variant-numeric: tabular-nums; color: var(--text);
  transition: color 160ms var(--ease);
}
.kiosk-display.is-name { font-size: 1.75rem; letter-spacing: 0.02em; text-indent: 0; font-weight: 650; }
.kiosk-placeholder { color: var(--muted); opacity: 0.45; }

.kiosk-pad { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-3); }
.kiosk-key {
  min-height: 78px; border-radius: var(--r-lg);
  border: 1px solid rgb(255 255 255 / 12%);
  background: rgb(255 255 255 / 6%);
  color: var(--text); font: inherit; font-size: 1.75rem; font-weight: 600;
  cursor: pointer; transition: background 120ms var(--ease), transform 90ms var(--ease), border-color 120ms var(--ease);
  -webkit-tap-highlight-color: transparent;
}
.kiosk-key:hover { background: rgb(255 255 255 / 11%); border-color: rgb(255 255 255 / 20%); }
.kiosk-key:active { transform: scale(0.97); background: rgb(255 255 255 / 16%); }
.kiosk-key:focus-visible { outline: none; box-shadow: var(--ring); }
.kiosk-key.is-soft { font-size: var(--fs-base); font-weight: 600; color: var(--muted); }

.kiosk-actions { display: flex; flex-wrap: wrap; gap: var(--s-3); margin-top: var(--s-5); }
.kiosk-action {
  min-height: 60px; padding: 0 var(--s-6); border-radius: var(--r-lg);
  font: inherit; font-size: var(--fs-md); font-weight: 650; cursor: pointer;
  border: 1px solid transparent; transition: background 120ms var(--ease), transform 90ms var(--ease), border-color 120ms var(--ease);
  -webkit-tap-highlight-color: transparent;
}
.kiosk-action:active { transform: translateY(1px); }
.kiosk-action:focus-visible { outline: none; box-shadow: var(--ring); }
.kiosk-action.primary { background: var(--accent); color: var(--accent-contrast); box-shadow: 0 8px 22px color-mix(in srgb, var(--accent) 42%, transparent); }
.kiosk-action.primary:hover { background: var(--accent-hover); }
.kiosk-action.secondary { background: rgb(255 255 255 / 7%); color: var(--text); border-color: rgb(255 255 255 / 14%); }
.kiosk-action.secondary:hover { background: rgb(255 255 255 / 12%); }
.kiosk-action.ghost { background: transparent; color: var(--muted); }
.kiosk-action.ghost:hover { background: rgb(255 255 255 / 6%); color: var(--text); }

.kiosk-check { display: flex; flex-direction: column; gap: var(--s-2); width: 100%; margin-bottom: var(--s-2); }
.kiosk-check-label { font-size: var(--fs-xs); font-weight: 650; color: var(--text-soft); text-transform: uppercase; letter-spacing: 0.06em; }
.kiosk-check-input {
  height: 58px; padding: 0 var(--s-4); border-radius: var(--r-lg);
  border: 1px solid rgb(255 255 255 / 16%); background: rgb(0 0 0 / 24%);
  color: var(--text); font: inherit; font-size: 1.5rem; font-weight: 650;
  letter-spacing: 0.5em; text-indent: 0.5em; text-transform: uppercase; text-align: center;
}
.kiosk-check-input:focus { outline: none; border-color: var(--accent); box-shadow: var(--ring); }

.kiosk-status { min-height: 22px; margin: var(--s-4) 0 0; font-size: var(--fs-sm); font-weight: 600; color: var(--muted); }
.kiosk-status[data-tone="success"] { color: var(--success); }
.kiosk-status[data-tone="error"] { color: var(--danger); }

.kiosk-side { font-size: var(--fs-sm); color: var(--text-soft); }
.kiosk-list { list-style: none; margin: 0 0 var(--s-5); padding: 0; display: flex; flex-direction: column; gap: var(--s-3); }
.kiosk-list li { position: relative; padding-left: var(--s-6); line-height: 1.55; }
.kiosk-list li::before {
  content: "✓"; position: absolute; left: 0; top: 0;
  width: 18px; height: 18px; border-radius: var(--r-full);
  display: grid; place-items: center; font-size: 10px; font-weight: 800;
  color: var(--success); background: var(--success-soft);
}
.kiosk-device { display: flex; flex-direction: column; gap: var(--s-2); padding-top: var(--s-4); border-top: 1px solid rgb(255 255 255 / 10%); }
.kiosk-device-input, .kiosk-input {
  height: 48px; padding: 0 var(--s-4); border-radius: var(--r-md);
  border: 1px solid rgb(255 255 255 / 16%); background: rgb(0 0 0 / 24%);
  color: var(--text); font: inherit; font-size: var(--fs-base);
}
.kiosk-device-input:focus, .kiosk-input:focus { outline: none; border-color: var(--accent); box-shadow: var(--ring); }
.kiosk-link { display: inline-block; margin-top: var(--s-4); color: var(--accent); font-weight: 650; }
.kiosk-link:hover { text-decoration: underline; }

.kiosk-upcoming { margin-top: var(--s-5); text-align: left; padding-top: var(--s-4); border-top: 1px solid rgb(255 255 255 / 10%); }
.kiosk-upcoming-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: var(--s-2); }
.kiosk-upcoming-item { display: flex; flex-direction: column; gap: 1px; padding: var(--s-3) var(--s-4); border: 1px solid rgb(255 255 255 / 12%); border-radius: var(--r-md); background: rgb(255 255 255 / 3%); }
.kiosk-upcoming-item strong { font-variant-numeric: tabular-nums; font-size: var(--fs-sm); }

.kiosk-empty { max-width: 560px; margin: 10vh auto; text-align: center; }
.kiosk-empty h1 { font-size: var(--fs-xl); }
.kiosk-empty p { color: var(--muted); margin: 0 0 var(--s-4); }

.kiosk-fallback { max-width: 620px; margin: 0 auto; width: 100%; }
.kiosk-form { display: flex; flex-direction: column; gap: var(--s-4); margin-top: var(--s-4); }
.kiosk-field { display: flex; flex-direction: column; gap: var(--s-2); }
.kiosk-field label { font-size: var(--fs-xs); font-weight: 650; color: var(--text-soft); text-transform: uppercase; letter-spacing: 0.06em; }

.kiosk-foot {
  margin-top: auto; display: flex; justify-content: space-between; align-items: center;
  gap: var(--s-4); flex-wrap: wrap; padding-top: var(--s-4);
  border-top: 1px solid rgb(255 255 255 / 8%);
}
.kiosk-foot .kiosk-note { font-size: var(--fs-xs); }

@media (max-width: 900px) {
  .kiosk { padding: var(--s-4); gap: var(--s-4); }
  .kiosk-grid { grid-template-columns: 1fr; }
  .kiosk-side { display: none; }
  .kiosk-clock { font-size: 1.5rem; }
  .kiosk-panel { padding: var(--s-5); border-radius: var(--r-lg); }
  .kiosk-step-title { font-size: 1.625rem; }
  .kiosk-display { min-height: 88px; font-size: 2.25rem; }
  .kiosk-key { min-height: 66px; font-size: 1.5rem; }
  .kiosk-site { padding-left: var(--s-3); }
  .kiosk-action { flex: 1 1 auto; padding: 0 var(--s-4); }
}
@media (max-width: 560px) {
  .kiosk-brand { font-size: var(--fs-md); gap: var(--s-2); }
  .kiosk-mark { width: 34px; height: 34px; }
  .kiosk-top { gap: var(--s-3); }
  .kiosk-clock { margin-left: 0; width: 100%; font-size: 1.375rem; }
  .kiosk-display { letter-spacing: 0.3em; text-indent: 0.3em; }
}
