/* Base shell styles — every themed value reads var(--token, <406Blue fallback>) (AC-U1).
   Screen-specific styles land with their slices. */

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  background: var(--pg, #f3f5f9);
  color: var(--ink, #101c33);
  font-family: var(--f-body, 'Figtree', sans-serif);
  font-size: 14px;
  font-weight: 500;
}

h1,
h2,
h3 {
  font-family: var(--f-head, 'Bricolage Grotesque', sans-serif);
  font-weight: var(--w-head, 800);
  text-transform: var(--tt, none);
}

h1 {
  font-size: 24px;
}

/* Watermark (AC-U5): 5% opacity, never intercepts a click; phone 31%/40%,
   desktop app screens 5px under the topbar (top ~56px) at 240px. */
.watermark {
  position: fixed;
  top: 31%;
  left: 50%;
  transform: translateX(-50%);
  width: 40%;
  opacity: 0.05;
  pointer-events: none;
  z-index: 10;
}

@media (min-width: 900px) {
  .watermark {
    top: 56px;
    width: 240px;
  }
}

.app-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px;
}

.card {
  background: var(--card, #ffffff);
  border: var(--bw, 1px) solid var(--line, #ffc820);
  border-radius: var(--r-lg, 24px);
  box-shadow: var(--sh-card, 0 6px 18px rgba(16, 28, 51, 0.07));
  padding: 22px;
}

/* --- Auth screens (login card per o-login: centred card, pill button, footer copy) --- */

.login-page .watermark {
  top: 10%;
}

.login-card {
  max-width: 420px;
  margin: 18vh auto 0;
  padding: 28px;
}

.card-sub {
  color: var(--mut, #5c6b85);
  margin-top: 4px;
}

.stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 16px;
}

.input {
  height: 52px;
  padding: 0 16px;
  font-size: 15px;
  font-family: inherit;
  color: var(--ink, #101c33);
  background: var(--pg, #f3f5f9);
  border: var(--bw, 1px) solid var(--line, #ffc820);
  border-radius: var(--r-sm, 14px);
}

/* A field the rules have closed (a PO code with hours against it, a username) — visibly
   inert, with the reason spelled out beside it rather than left to be guessed. */
.input:disabled {
  color: var(--faint, #93a1b8);
  background: var(--chip-bg, #eef1f6);
  cursor: not-allowed;
}

.field-hint {
  color: var(--mut, #5c6b85);
  font-size: 13px;
  margin-top: 4px;
}

/* A validation message that belongs to one input rather than to the whole form. */
.field-error {
  font-size: 13px;
  margin-top: 4px;
}

.input-code {
  text-align: center;
  letter-spacing: 0.2em;
  font-size: 18px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 22px;
  font-size: 16px;
  font-weight: 700;
  font-family: inherit;
  text-decoration: none;
  border-radius: var(--r-pill, 99px);
  border: var(--bw, 1px) solid var(--line, #ffc820);
  cursor: pointer;
}

.btn-primary {
  background: var(--pri, #2b3379);
  color: var(--pri-fg, #ffffff);
  box-shadow: var(--sh-btn, 0 8px 20px rgba(43, 51, 121, 0.30));
}

.btn-ghost {
  background: var(--card, #ffffff);
  color: var(--chip-fg, #2b3379);
}

.btn-block {
  width: 100%;
}

.form-error {
  background: var(--chip-bg, #e8e9f4);
  color: var(--ink, #101c33);
  border: var(--bw, 1px) solid var(--line, #ffc820);
  border-radius: var(--r-sm, 14px);
  padding: 10px 14px;
  font-weight: 600;
}

.login-foot {
  margin-top: 18px;
  text-align: center;
  color: var(--faint, #93a1b8);
  font-size: 13px;
}

.enroll-qr {
  display: flex;
  justify-content: center;
  margin: 14px 0;
}

.manual-key {
  display: inline-block;
  margin-top: 6px;
  padding: 6px 10px;
  background: var(--pg, #f3f5f9);
  border-radius: var(--r-sm, 14px);
  font-size: 15px;
}

.recovery-codes {
  list-style: none;
  padding: 0;
  margin: 16px 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.recovery-codes code {
  display: block;
  padding: 8px 10px;
  background: var(--pg, #f3f5f9);
  border-radius: var(--r-sm, 14px);
  text-align: center;
}

/* --- Settings --- */

.stack-card {
  margin-top: 14px;
}

.profile-card {
  display: flex;
  align-items: center;
  gap: 14px;
}

.profile-avatar {
  width: 48px;
  height: 48px;
  flex: 0 0 auto;
  border-radius: var(--r-pill, 99px);
  background: var(--pri, #2b3379);
  color: var(--pri-fg, #ffffff);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
}

.chip {
  display: inline-flex;
  align-items: center;
  padding: 3px 12px;
  border-radius: var(--r-pill, 99px);
  background: var(--chip-bg, #e8e9f4);
  color: var(--chip-fg, #2b3379);
  border: var(--bw, 1px) solid var(--line, #ffc820);
  font-size: 12px;
  font-weight: 700;
}

.theme-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 10px;
}

.theme-card {
  min-height: 64px;
  padding: 12px;
  border-radius: var(--r-sm, 14px);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 2px;
  align-items: flex-start;
  font-family: inherit;
}

.theme-card-blue {
  background: #2b3379;
  color: #ffffff;
  border: 1px solid #ffc820;
}

.theme-card-slab {
  background: #ffffff;
  color: #111111;
  border: 2px solid #111111;
}

/* Which skin is live was invisible before — the swatches are the only selection feedback. */
.theme-card[aria-checked="true"] {
  outline: 3px solid var(--acc, #ffc820);
  outline-offset: 2px;
}

.theme-card-name {
  font-weight: 800;
  font-size: 15px;
}

.theme-card-note {
  font-size: 12px;
  opacity: 0.8;
}

.device-list {
  list-style: none;
  padding: 0;
  margin: 8px 0 0;
}

.device-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  border-bottom: 1px solid var(--chip-bg, #e8e9f4);
}

.device-last-seen {
  margin-left: auto;
  color: var(--mut, #5c6b85);
  font-size: 13px;
}

/* --- Office shell (topbar + 200px sidebar per SPEC §Screens) --- */

.office {
  background: var(--pg, #f3f5f9);
}

a.topbar-user {
  min-height: 44px;
  text-decoration: none;
  cursor: pointer;
}

a.topbar-user:hover,
a.topbar-user:focus-visible {
  border-color: var(--pri, #2b3379);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 28px;
  background: var(--card, #ffffff);
  border-bottom: var(--bw, 1px) solid var(--line, #ffc820);
}

.topbar-title {
  font-family: var(--f-head, 'Bricolage Grotesque', sans-serif);
  font-weight: var(--w-head, 800);
  text-transform: var(--tt, none);
  font-size: 22px;
}

/* Matches the 22px title's line box, so the topbar keeps the height .office-shell and the
   watermark offsets are calculated against (TIMTRK-24). */
.topbar-logo {
  display: block;
  height: 28px;
  width: auto;
}

.office-shell {
  display: flex;
  min-height: calc(100vh - 90px);
}

.sidebar {
  width: 200px;
  flex-shrink: 0;
  padding: 22px 14px;
  background: var(--card, #ffffff);
  border-right: var(--bw, 1px) solid var(--line, #ffc820);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.sidebar-item {
  display: block;
  padding: 10px 16px;
  border-radius: var(--r-pill, 99px);
  color: var(--ink, #101c33);
  text-decoration: none;
  font-weight: 700;
  font-size: 15px;
  border: var(--bw, 1px) solid transparent;
}

.sidebar-item.active {
  background: var(--chip-bg, #e8e9f4);
  color: var(--chip-fg, #2b3379);
  border-color: var(--line, #ffc820);
}

.nav-badge {
  display: inline-flex;
  align-items: center;
  margin-left: 8px;
  padding: 1px 9px;
  border-radius: var(--r-pill, 99px);
  background: var(--danger, #b3261e);
  color: var(--danger-fg, #ffffff);
  font-size: 11px;
  font-weight: 700;
}

.office-main {
  position: relative;
  flex: 1;
  padding: 22px 28px;
  max-width: 1200px;
}

.office-main .watermark {
  position: absolute;
  top: 5px;
  width: 240px;
}

/* --- Tabs, page head, tables (data-table component) --- */

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

.page-head h1 {
  margin: 0;
}

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

.tab-row {
  display: flex;
  gap: 8px;
}

.tab {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 18px;
  border-radius: var(--r-pill, 99px);
  border: var(--bw, 1px) solid var(--line, #ffc820);
  background: var(--card, #ffffff);
  color: var(--chip-fg, #2b3379);
  text-decoration: none;
  font-weight: 700;
  font-size: 14px;
}

.tab.active {
  background: var(--pri, #2b3379);
  color: var(--pri-fg, #ffffff);
}

.btn-accent {
  background: var(--acc, #ffc820);
  color: var(--acc-fg, #101c33);
  box-shadow: var(--sh-btn, 0 8px 20px rgba(43, 51, 121, 0.30));
}

.table-labels {
  display: grid;
  gap: 12px;
  padding: 0 18px 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--mut, #5c6b85);
}

.table-row {
  display: grid;
  gap: 12px;
  align-items: center;
  background: var(--card, #ffffff);
  border: var(--bw, 1px) solid var(--line, #ffc820);
  border-radius: var(--r-sm, 14px);
  padding: 14px 18px;
  margin-bottom: 7px;
  color: var(--ink, #101c33);
  text-decoration: none;
  font-size: 14px;
}

.po-grid {
  grid-template-columns: 70px 1.8fr 1.2fr 0.7fr 1fr 0.9fr;
}

.people-grid {
  grid-template-columns: 1.6fr 0.9fr 1fr 0.8fr 1.4fr;
}

/* TIMTRK-27: the pending device-approval queue. Columns only — every colour, border and radius
   on the row comes from .table-row's tokens, so both skins are already handled. */
.approvals-queue-grid {
  grid-template-columns: 1.4fr 0.8fr 1.1fr 1.1fr 1.2fr 0.9fr 1.3fr;
}

/* Divider between a card's main action and its alternatives (the enrollment method chooser).
   Token-coloured rather than the browser's default rule, which ignores the skin entirely. */
.card-rule {
  border: 0;
  border-top: var(--bw, 1px) solid var(--line, #ffc820);
  margin: 18px 0 14px;
}

.row-closed {
  opacity: 0.55;
}

.cell-code,
.cell-hours,
.cell-strong {
  font-weight: 700;
}

.faint {
  color: var(--faint, #93a1b8);
  font-weight: 500;
}

.chip-solid {
  background: var(--pri, #2b3379);
  color: var(--pri-fg, #ffffff);
}

.chip-accent {
  background: var(--acc, #ffc820);
  color: var(--acc-fg, #101c33);
}

.chip-ghost {
  background: var(--card, #ffffff);
  color: var(--faint, #93a1b8);
}

.chip-danger {
  background: var(--danger, #b3261e);
  color: var(--danger-fg, #ffffff);
  border-color: var(--danger, #b3261e);
}

.budget-bar {
  display: inline-block;
  width: 90px;
  height: 10px;
  vertical-align: middle;
  background: var(--chip-bg, #e8e9f4);
  border: 1px solid var(--line, #ffc820);
  border-radius: var(--r-pill, 99px);
  overflow: hidden;
}

.budget-fill {
  display: block;
  height: 100%;
  background: var(--pri, #2b3379);
}

.budget-bar.over .budget-fill {
  background: var(--acc, #ffc820);
}

.budget-label {
  margin-left: 6px;
}

.table-foot {
  margin-top: 12px;
  font-size: 13px;
}

/* --- Forms & inline actions --- */

.form-card {
  max-width: 560px;
}

.field-label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-weight: 600;
  font-size: 13px;
  color: var(--mut, #5c6b85);
}

.input-area {
  min-height: 90px;
  padding: 12px 16px;
  resize: vertical;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.form-notice {
  background: var(--chip-bg, #e8e9f4);
  border: var(--bw, 1px) solid var(--pri, #2b3379);
  border-radius: var(--r-sm, 14px);
  padding: 10px 14px;
  font-weight: 600;
}

.actions-cell {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.actions-cell form {
  display: inline;
}

.link-btn {
  background: none;
  border: none;
  padding: 0;
  min-height: 44px;
  color: var(--pri, #2b3379);
  font-weight: 700;
  font-size: 14px;
  font-family: inherit;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.device-panel {
  margin: -2px 0 10px;
  padding: 12px 18px;
}

.link-btn-danger {
  color: var(--mut, #5c6b85);
}

/* --- Worker shell (phone-first, bottom nav) --- */

.worker-main {
  max-width: 480px;
  padding-bottom: 96px;
}

.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-around;
  gap: 6px;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  background: var(--card, #ffffff);
  border-top: var(--bw, 1px) solid var(--line, #ffc820);
}

.bottom-nav-item {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 16px;
  border-radius: var(--r-pill, 99px);
  color: var(--mut, #5c6b85);
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
}

.bottom-nav-item.active {
  background: var(--chip-bg, #e8e9f4);
  color: var(--chip-fg, #2b3379);
  border: var(--bw, 1px) solid var(--line, #ffc820);
}

/* Today */

.today-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.today-head h1 {
  font-size: 32px;
  margin: 0;
}

.week-total-chip {
  font-size: 14px;
  padding: 8px 16px;
}

.week-strip {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
  margin: 14px 0;
}

.week-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 8px 2px;
  background: var(--card, #ffffff);
  border: var(--bw, 1px) solid var(--line, #ffc820);
  border-radius: var(--r-sm, 14px);
  font-size: 12px;
}

.week-cell-letter {
  color: var(--faint, #93a1b8);
  font-weight: 700;
}

.week-cell-value {
  font-weight: 700;
}

.week-cell.on {
  background: var(--cell-on, #2b3379);
  color: var(--cell-on-fg, #ffffff);
}

.week-cell.on .week-cell-letter {
  color: inherit;
}

.entry-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  padding: 16px 18px;
  border-radius: var(--r-sm, 14px);
}

.hour-chip {
  font-size: 15px;
  padding: 6px 14px;
}

.entry-breakdown summary {
  cursor: pointer;
  color: var(--pri, #2b3379);
  font-size: 13px;
  font-weight: 700;
  min-height: 44px;
  display: flex;
  align-items: center;
}

.entry-breakdown ul {
  margin: 0;
  padding-left: 18px;
  color: var(--mut, #5c6b85);
  font-size: 13px;
}

.cta-add {
  margin-top: 16px;
  min-height: 56px;
  font-family: var(--f-head, 'Bricolage Grotesque', sans-serif);
  font-size: 17px;
}

.timer-card h2 {
  margin: 6px 0 0;
}

/* Add hours */

.add-head {
  display: flex;
  align-items: baseline;
  gap: 12px;
}

.add-head h1 {
  font-size: 22px;
}

.back-link {
  color: var(--mut, #5c6b85);
  text-decoration: none;
  font-weight: 700;
}

.search-box {
  width: 100%;
  margin-bottom: 6px;
}

.group-label {
  margin: 14px 0 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--mut, #5c6b85);
}

.picker-row {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--card, #ffffff);
  border: var(--bw, 1px) solid var(--line, #ffc820);
  border-radius: var(--r-sm, 14px);
  padding: 12px 16px;
  margin-bottom: 8px;
  cursor: pointer;
}

.picker-row input {
  position: absolute;
  opacity: 0;
}

.picker-body {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.picker-check {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
  background: var(--pri, #2b3379);
  color: var(--pri-fg, #ffffff);
  font-weight: 700;
}

.picker-row:has(input:checked) {
  border: 2px solid var(--pri, #2b3379);
}

.picker-row:has(input:checked) .picker-check {
  display: inline-flex;
}

.stepper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 18px 0 10px;
}

.stepper-btn {
  width: 56px;
  height: 56px;
  font-size: 24px;
  font-weight: 700;
  background: var(--card, #ffffff);
  border: var(--bw, 1px) solid var(--line, #ffc820);
  border-radius: var(--r-sm, 14px);
  cursor: pointer;
  color: var(--ink, #101c33);
}

.stepper-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
}

.stepper-value {
  width: 130px;
  text-align: center;
  font-family: var(--f-head, 'Bricolage Grotesque', sans-serif);
  font-size: 40px;
  font-weight: var(--w-head, 800);
  color: var(--ink, #101c33);
  background: none;
  border: none;
  border-bottom: 2px dotted var(--faint, #93a1b8);
}

.stepper-hint {
  font-size: 12px;
  color: var(--mut, #5c6b85);
  margin-top: 4px;
}

.note-box {
  width: 100%;
  margin: 8px 0 14px;
}

.cta-save {
  min-height: 56px;
  font-family: var(--f-head, 'Bricolage Grotesque', sans-serif);
  font-size: 17px;
  margin-bottom: 8px;
}

.cta-save:disabled,
#timer-cta:disabled {
  opacity: 0.5;
  cursor: default;
}

/* Week */

.week-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.week-head h1 {
  font-size: 24px;
}

.week-pager a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  color: var(--ink, #101c33);
  text-decoration: none;
  font-size: 20px;
}

/* The labelled variant borrows the .tab pill so both skins resolve for free. The gap is what
   keeps two opposite actions reading as two controls — on slab --r-pill drops to 12px and
   abutting pills would fuse back into one bar. Must follow .week-pager a: equal specificity. */
.week-pager-labeled {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.week-pager-labeled a {
  width: auto;
  height: auto;
  min-width: 44px;
  min-height: 44px;
  padding: 0 18px;
  border-radius: var(--r-pill, 99px);
  border: var(--bw, 1px) solid var(--line, #ffc820);
  background: var(--card, #ffffff);
  color: var(--chip-fg, #2b3379);
  font-size: 14px;
  font-weight: 700;
}

.week-banner {
  background: var(--acc, #ffc820);
  color: var(--acc-fg, #101c33);
  border-radius: var(--r-sm, 14px);
  padding: 14px 18px;
  font-weight: 700;
  margin-bottom: 12px;
}

.day-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  margin-bottom: 8px;
  border-radius: var(--r-sm, 14px);
}

.day-row.today {
  border: 2px solid var(--pri, #2b3379);
}

.day-row.empty {
  opacity: 0.6;
}

.day-total {
  font-weight: 800;
  font-size: 17px;
}

.week-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  font-size: 15px;
}

.week-total-row strong {
  font-size: 24px;
  font-family: var(--f-head, 'Bricolage Grotesque', sans-serif);
}

/* --- Calendar board (o-calendar) --- */

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 10px;
}

.calendar-cell {
  min-height: 104px;
  background: var(--card, #ffffff);
  border: var(--bw, 1px) solid var(--line, #ffc820);
  border-radius: var(--r-sm, 14px);
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.calendar-cell.today {
  border: 2px solid var(--pri, #2b3379);
}

.calendar-cell.weekend {
  opacity: 0.6;
}

.calendar-cell-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--mut, #5c6b85);
}

.calendar-chip-form {
  display: block;
}

.calendar-chip {
  display: block;
  width: 100%;
  text-align: left;
  padding: 6px 10px;
  border-radius: var(--r-pill, 99px);
  background: var(--chip-bg, #e8e9f4);
  color: var(--chip-fg, #2b3379);
  border: var(--bw, 1px) solid var(--line, #ffc820);
  font-size: 12px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
}

.calendar-chip.service {
  background: var(--acc, #ffc820);
  color: var(--acc-fg, #101c33);
}

.legend-swatch {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 3px;
  margin: 0 4px 0 10px;
  vertical-align: middle;
}

.legend-job {
  background: var(--chip-bg, #e8e9f4);
  border: 1px solid var(--line, #ffc820);
}

.legend-service {
  background: var(--acc, #ffc820);
}

/* --- Today's job card + schedule (w-today / w-schedule) --- */

.today-job-card .today-job {
  margin-top: 10px;
}

.today-job-card h2 {
  margin: 4px 0 2px;
  font-size: 20px;
}

.today-job .btn {
  margin-top: 10px;
  min-height: 56px;
}

.schedule-row.today-card {
  border: 2px solid var(--acc, #ffc820);
}

/* --- Approvals grid (o-approvals) --- */

.approvals-grid {
  grid-template-columns: 1.4fr repeat(7, 0.55fr) 0.7fr 1fr 1.1fr;
}

.cell-center {
  text-align: center;
}

.day-form {
  display: inline;
}

.day-cell {
  background: none;
  border: none;
  font: inherit;
  padding: 6px 8px;
  min-height: 44px;
  border-radius: var(--r-sm, 14px);
  cursor: pointer;
  color: var(--ink, #101c33);
}

.day-cell:hover {
  background: var(--chip-bg, #e8e9f4);
}

.day-cell.approved {
  background: var(--pri, #2b3379);
  color: var(--pri-fg, #ffffff);
  font-weight: 700;
}

.chip-mini {
  font-size: 10px;
  padding: 1px 8px;
  margin-left: 6px;
}

.banner-submitted {
  background: var(--chip-bg, #e8e9f4);
  color: var(--chip-fg, #2b3379);
  border: var(--bw, 1px) solid var(--line, #ffc820);
}

.banner-approved {
  background: var(--pri, #2b3379);
  color: var(--pri-fg, #ffffff);
}

.day-row.locked {
  border-color: var(--pri, #2b3379);
}

/* --- Reports (o-reports) --- */

.filter-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.filter-select {
  height: 48px;
  min-width: 150px;
}

.summary-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 20px;
}

.summary-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 18px 22px;
}

.summary-card strong {
  font-family: var(--f-head, 'Bricolage Grotesque', sans-serif);
  font-weight: var(--w-head, 800);
  font-size: 30px;
}

.report-grid {
  grid-template-columns: 1.4fr 0.8fr 2fr 0.7fr;
}

.share-bar {
  width: 100%;
  max-width: 260px;
  height: 12px;
}

/* --- Audit screens --- */

.audit-head {
  display: flex;
  align-items: center;
  gap: 12px;
}

.audit-head h1 {
  margin: 0;
}

.audit-grid {
  grid-template-columns: 0.8fr 0.9fr 3fr;
}

.audit-chip {
  font-size: 12px;
  padding: 2px 10px;
}

.tab-disabled {
  opacity: 0.55;
  cursor: default;
}

.pager-row {
  display: flex;
  gap: 16px;
  align-items: center;
  margin-top: 10px;
}

/* TIMTRK-18: per-user permission panel, sharing the device-panel geometry. */
.permission-panel {
    margin: -2px 0 10px;
    padding: 12px 18px;
}

.permission-station {
    margin-bottom: 10px;
}

.permission-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 44px;
    border-bottom: var(--bw, 1px) solid var(--line, #ffc820);
}

.permission-station .permission-row:last-child {
    border-bottom: none;
}

/* TIMTRK-18: friendly crash page — the code is the whole point, so it reads large. */
.error-code-row {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.error-code {
    font-family: var(--tt, monospace);
    font-size: 28px;
    font-weight: 700;
    letter-spacing: 2px;
    padding: 8px 16px;
    border-radius: var(--r-sm, 8px);
    background: var(--chip-bg, #fff6d6);
    color: var(--chip-fg, #1a1a1a);
    border: var(--bw, 1px) solid var(--line, #ffc820);
}

/* TIMTRK-18: diagnostics list + stack trace. */
.diagnostics-grid {
    grid-template-columns: 1fr 0.8fr 1fr 1.6fr 1.2fr;
}

.stack-trace {
    overflow-x: auto;
    white-space: pre;
    font-family: var(--tt, monospace);
    font-size: 12px;
    padding: 12px;
    border-radius: var(--r-sm, 8px);
    background: var(--chip-bg, #fff6d6);
    color: var(--chip-fg, #1a1a1a);
}
