@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;0,9..40,800;1,9..40,400&family=IBM+Plex+Sans:wght@400;500;600;700&display=swap');

:root {
  color-scheme: dark;

  --bg: #0a0c10;
  --bg-elevated: #0e1218;
  --surface: #141920;
  --surface-alt: #1a212b;
  --border: #2a3340;
  --border-strong: #3a4556;
  --ink: #eef2f6;
  --ink-soft: #b4becb;
  --muted: #7e8a9a;
  --text: var(--ink);

  --accent: #2dd4c8;
  --accent-hover: #5eead4;
  --accent-ink: #042f2e;
  --accent-soft: rgba(45, 212, 200, 0.12);
  --accent-border: rgba(45, 212, 200, 0.38);

  --success: #3ecf8e;
  --success-soft: rgba(62, 207, 142, 0.12);
  --success-border: rgba(62, 207, 142, 0.34);

  --warning: #e8b84a;
  --warning-soft: rgba(232, 184, 74, 0.12);
  --warning-border: rgba(232, 184, 74, 0.34);

  --danger: #f07178;

  --dept-prewire: #2dd4c8;
  --dept-shade: #5eead4;
  --dept-trim: #e8b84a;
  --dept-final: #c084fc;

  --tooltip-bg: #06080c;

  --radius-lg: 12px;
  --radius: 10px;
  --radius-sm: 7px;
  --shadow-sm: 0 1px 0 rgba(255, 255, 255, 0.03) inset, 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow: 0 1px 0 rgba(255, 255, 255, 0.04) inset, 0 10px 28px rgba(0, 0, 0, 0.45);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  --font: "DM Sans", "IBM Plex Sans", sans-serif;
  --font-meta: "IBM Plex Sans", "DM Sans", sans-serif;
}

* { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  line-height: 1.5;
  font-size: 15px;
  background:
    radial-gradient(1200px 600px at 12% -10%, rgba(45, 212, 200, 0.07), transparent 55%),
    radial-gradient(900px 500px at 100% 0%, rgba(45, 212, 200, 0.05), transparent 50%),
    linear-gradient(180deg, var(--bg-elevated) 0%, var(--bg) 42%, #080a0e 100%);
  background-attachment: fixed;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
  max-width: 100vw;
}

::selection { background: rgba(45, 212, 200, 0.28); }

.container {
  max-width: 820px;
  margin: 0 auto;
  padding: 24px 18px calc(100px + env(safe-area-inset-bottom, 0px));
}

.container.wide { max-width: 1080px; }
.page-plan .topbar-inner { max-width: 1080px; }

.stack { display: flex; flex-direction: column; gap: 12px; }
.stack-sm { display: flex; flex-direction: column; gap: 8px; }
.field { display: flex; flex-direction: column; gap: 6px; margin: 0; }
.field + .field { margin-top: 4px; }

/* ---------- Motion ---------- */

@keyframes rise-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes scale-in {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes check-pop {
  0% { transform: scale(0.85); }
  55% { transform: scale(1.08); }
  100% { transform: scale(1); }
}

@keyframes slide-up {
  from { opacity: 0; transform: translateY(100%); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes soft-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.72; }
}

@keyframes progress-sheen {
  from { background-position: 100% 0; }
  to { background-position: -100% 0; }
}

.reveal { animation: rise-in 0.45s var(--ease) both; }
.reveal-delay-1 { animation-delay: 0.05s; }
.reveal-delay-2 { animation-delay: 0.1s; }
.reveal-delay-3 { animation-delay: 0.15s; }
.reveal-delay-4 { animation-delay: 0.2s; }

.stagger > *:nth-child(1) { animation: rise-in 0.4s var(--ease) both; animation-delay: 0.04s; }
.stagger > *:nth-child(2) { animation: rise-in 0.4s var(--ease) both; animation-delay: 0.09s; }
.stagger > *:nth-child(3) { animation: rise-in 0.4s var(--ease) both; animation-delay: 0.14s; }
.stagger > *:nth-child(4) { animation: rise-in 0.4s var(--ease) both; animation-delay: 0.19s; }
.stagger > *:nth-child(5) { animation: rise-in 0.4s var(--ease) both; animation-delay: 0.24s; }
.stagger > *:nth-child(6) { animation: rise-in 0.4s var(--ease) both; animation-delay: 0.29s; }

/* ---------- Header ---------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(10, 12, 16, 0.82);
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
  border-bottom: 1px solid var(--border);
  padding: 11px 18px;
  padding-top: calc(11px + env(safe-area-inset-top, 0px));
  animation: fade-in 0.35s var(--ease) both;
}

.topbar-inner {
  max-width: 820px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: nowrap;
}

.topbar-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex: 0 0 auto;
  margin-left: auto;
  min-width: 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 800;
  font-size: 15.5px;
  letter-spacing: -0.03em;
  perspective: 500px;
}

.brand .sub {
  display: block;
  margin-top: 1px;
  font-family: var(--font-meta);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

/* Chrome logo — stationary */
.logo3d {
  position: relative;
  width: 38px;
  height: 36px;
  flex-shrink: 0;
}

.logo3d .chrome,
.logo3d .glint {
  position: absolute;
  inset: 0;
  -webkit-mask: url('/img/cyber-logo.svg') center / contain no-repeat;
  mask: url('/img/cyber-logo.svg') center / contain no-repeat;
}

.logo3d .chrome {
  background: linear-gradient(135deg, #ffffff 0%, #b8c2d0 22%, #f4f7fb 42%, #838fa3 60%, #e8eef6 78%, #cbd4e1 100%);
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.55));
}

.logo3d .glint {
  display: none;
}

/* ---------- Page intro ---------- */

.page-hero {
  margin-bottom: 18px;
  animation: rise-in 0.4s var(--ease) both;
}

.page-hero h1 {
  font-size: clamp(26px, 4vw, 32px);
  font-weight: 800;
  letter-spacing: -0.04em;
  margin: 0 0 8px;
}

.page-hero p {
  margin: 0;
  color: var(--muted);
  font-family: var(--font-meta);
  font-size: 14.5px;
  line-height: 1.45;
  max-width: 48ch;
}

.section-picker { margin-bottom: 16px; }

/* ---------- Cards ---------- */

.card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent 28%), var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 18px 20px;
  margin-bottom: 12px;
  animation: rise-in 0.45s var(--ease) both;
}

h1 { font-size: 22px; font-weight: 800; letter-spacing: -0.03em; margin: 0 0 4px; }

h2 {
  font-family: var(--font-meta);
  font-size: 11.5px;
  font-weight: 700;
  margin: 0 0 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.muted { color: var(--muted); font-size: 13.5px; font-family: var(--font-meta); }

.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.spread { justify-content: space-between; }

/* ---------- Forms ---------- */

label.field-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: var(--muted);
  margin: 0 0 7px 1px;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
input[type="number"],
input[type="tel"],
select,
textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  font: inherit;
  color: var(--ink);
  background: var(--surface);
  transition: border-color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}

input[type="text"]::placeholder,
input[type="email"]::placeholder,
input[type="password"]::placeholder,
input[type="search"]::placeholder,
textarea::placeholder { color: #6b6b76; }

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="search"]:focus,
input[type="number"]:focus,
input[type="tel"]:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

select { cursor: pointer; }

/* Chrome paints autofilled fields white, which breaks the dark theme. */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
  -webkit-text-fill-color: var(--ink);
  -webkit-box-shadow: 0 0 0 1000px var(--surface) inset;
  caret-color: var(--ink);
  transition: background-color 9999s ease-in-out 0s;
}

textarea { resize: vertical; min-height: 108px; }

button {
  position: relative;
  isolation: isolate;
  font: inherit;
  font-size: 13.5px;
  font-weight: 600;
  border: none;
  border-radius: var(--radius-sm);
  padding: 10px 16px;
  cursor: pointer;
  background: var(--accent);
  color: var(--accent-ink);
  overflow: hidden;
  transition:
    background 0.2s var(--ease),
    transform 0.18s var(--ease),
    box-shadow 0.22s var(--ease),
    filter 0.2s var(--ease);
}

button::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, 0.35) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform 0.55s var(--ease);
  pointer-events: none;
  z-index: 1;
}

button:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(45, 212, 200, 0.22);
}

button:hover::after { transform: translateX(120%); }

button:active { transform: translateY(1px) scale(0.98); box-shadow: none; }
button:disabled { opacity: 0.45; cursor: not-allowed; transform: none; box-shadow: none; }
button:disabled::after { display: none; }

button.ghost {
  background: var(--surface-alt);
  color: var(--ink-soft);
  border: 1px solid var(--border-strong);
}

button.ghost:hover {
  background: var(--accent-soft);
  border-color: var(--accent-border);
  color: var(--accent);
  box-shadow: none;
}

button.ghost::after,
button.danger-ghost::after,
button.tab::after,
.tab::after,
.choice-chip::after,
.menu-btn::after,
.menu-item::after,
.signoff-bar button::after {
  display: none;
}

button.danger-ghost {
  background: transparent;
  color: #6f6f7a;
  border: none;
  padding: 4px 8px;
  font-size: 17px;
  line-height: 1;
}

button.danger-ghost:hover { color: var(--danger); background: transparent; }

/* ---------- Walk list ---------- */

.walk-link { display: block; text-decoration: none; color: inherit; animation: rise-in 0.4s var(--ease) both; max-width: 100%; }

.walk-link .card {
  margin-bottom: 10px;
  border-left: 3px solid var(--border);
  overflow: hidden;
  min-width: 0;
  max-width: 100%;
  transition: border-color 0.15s var(--ease), transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.walk-link:hover .card {
  transform: translateX(2px);
  box-shadow: var(--shadow);
  border-left-color: var(--accent);
}

.walk-link .card > .row.spread {
  gap: 10px;
  min-width: 0;
}

.walk-link .card strong {
  display: block;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.walk-link .card .row:not(.spread) {
  flex-wrap: wrap;
  justify-content: flex-end;
  max-width: 100%;
}

.walk-link .card[data-dept="prewire"] { border-left-color: var(--dept-prewire); }
.walk-link .card[data-dept="shade"] { border-left-color: var(--dept-shade); }
.walk-link .card[data-dept="trim"] { border-left-color: var(--dept-trim); }
.walk-link .card[data-dept="final"] { border-left-color: var(--dept-final); }

.walk-link:nth-child(1) { animation-delay: 0.03s; }
.walk-link:nth-child(2) { animation-delay: 0.06s; }
.walk-link:nth-child(3) { animation-delay: 0.09s; }
.walk-link:nth-child(4) { animation-delay: 0.12s; }
.walk-link:nth-child(5) { animation-delay: 0.15s; }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.03em;
  padding: 4px 10px;
  border-radius: 6px;
  white-space: nowrap;
  border: 1px solid transparent;
}

.badge.in_progress { background: var(--warning-soft); color: var(--warning); border-color: var(--warning-border); }
.badge.completed { background: var(--success-soft); color: var(--success); border-color: var(--success-border); }
.badge.dept { background: var(--accent-soft); color: var(--accent); border-color: var(--accent-border); }
.badge.dept::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

.badge.dept-prewire { background: rgba(45, 212, 200, 0.14); color: var(--dept-prewire); border-color: rgba(45, 212, 200, 0.38); }
.badge.dept-shade { background: rgba(94, 234, 212, 0.14); color: var(--dept-shade); border-color: rgba(94, 234, 212, 0.38); }
.badge.dept-trim { background: var(--warning-soft); color: var(--dept-trim); border-color: var(--warning-border); }
.badge.dept-final { background: rgba(192, 132, 252, 0.14); color: var(--dept-final); border-color: rgba(192, 132, 252, 0.38); }

.progress-track {
  height: 6px;
  background: var(--surface-alt);
  border-radius: 999px;
  overflow: hidden;
  margin-top: 14px;
}

.progress-fill {
  height: 100%;
  width: 0;
  background:
    linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.25), transparent),
    var(--accent);
  background-size: 200% 100%, 100% 100%;
  border-radius: 999px;
  transition: width 0.55s var(--ease);
  animation: progress-sheen 2.8s var(--ease) infinite;
}

.progress-fill.done {
  background: var(--success);
  animation: none;
}

.progress-row { display: flex; align-items: center; gap: 11px; margin-top: 14px; }
.progress-row .progress-track { flex: 1; margin-top: 0; }

.progress-pct {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  min-width: 34px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.progress-pct.done { color: var(--success); }

.badge.locked {
  background: rgba(148, 163, 184, 0.14);
  color: #94a3b8;
  border-color: rgba(148, 163, 184, 0.34);
}

/* ---------- Presence ---------- */

.presence {
  display: flex;
  gap: 6px;
  flex-wrap: nowrap;
  justify-content: flex-end;
  max-width: 220px;
  overflow: hidden;
}

.presence .chip {
  background: var(--accent-soft);
  border: 1px solid var(--accent-border);
  color: var(--accent);
  font-size: 11.5px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 6px;
  white-space: nowrap;
  animation: scale-in 0.25s var(--ease) both;
}

@media (max-width: 720px) {
  .presence { display: none; }
  .brand > span:last-child { max-width: 42vw; overflow: hidden; }
  .brand .sub { display: none; }

  .container { padding-left: 14px; padding-right: 14px; }

  .card { padding: 16px; }

  .filter-row {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    gap: 10px;
    padding-bottom: 2px;
    scrollbar-width: none;
  }

  .filter-row::-webkit-scrollbar { display: none; }

  .filter-row > .choice-row {
    flex-wrap: nowrap;
    flex-shrink: 0;
  }

  .filter-row > .choice-row + .choice-row::before {
    display: none;
  }

  .choice-row {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 2px;
  }

  .choice-row::-webkit-scrollbar { display: none; }

  .choice-chip { flex-shrink: 0; }

  .tabs {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .tab {
    flex: 1 0 auto;
    min-width: 0;
    padding: 10px 14px;
    font-size: 13px;
  }

  .tab svg { display: none; }

  .page-hero h1 { font-size: 26px; }

  .walk-link:hover .card,
  .walk-link:active .card {
    transform: none;
  }

  .walk-link .card > .row.spread:first-child {
    flex-direction: column;
    align-items: flex-start;
  }

  .walk-link .card > .row.spread:first-child > .row {
    justify-content: flex-start;
    max-width: 100%;
  }

  .walk-footer {
    flex-direction: column;
    align-items: stretch !important;
    gap: 10px;
  }

  .walk-footer .walk-actions {
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .brand > span:last-child {
    max-width: min(42vw, 11rem);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}

/* ---------- Tabs ---------- */

.tabs {
  display: flex;
  gap: 4px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 4px;
  margin-bottom: 16px;
  animation: rise-in 0.4s var(--ease) both;
}

.tab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  background: transparent;
  color: var(--muted);
  border: none;
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s var(--ease), color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}

.tab svg { width: 16px; height: 16px; flex-shrink: 0; }

.tab:hover { color: var(--ink); }

.tab.active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
  transform: translateY(-1px);
}

.tab .tab-badge {
  font-size: 10.5px;
  font-weight: 700;
  background: var(--accent-soft);
  color: var(--accent);
  padding: 1px 6px;
  border-radius: 999px;
}

.tab-panel { animation: fade-in 0.25s var(--ease) both; }

/* ---------- Checklist ---------- */

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 24px 0 6px;
  padding-bottom: 9px;
  border-bottom: 1px solid var(--border);
}

.section-header:first-child { margin-top: 0; }

.section-header .name {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink);
}

.section-header .count {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--muted);
  background: var(--surface-alt);
  border: 1px solid var(--border);
  padding: 2px 9px;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s, border-color 0.2s;
}

.section-header .count.done { color: var(--success); background: var(--success-soft); border-color: var(--success-border); }

.item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 13px 2px;
  border-bottom: 1px solid var(--border);
  animation: rise-in 0.35s var(--ease) both;
  transition: background 0.15s;
}

.item:last-child { border-bottom: none; }
.item:hover { background: var(--surface-alt); margin: 0 -8px; padding-left: 10px; padding-right: 10px; border-radius: 8px; }

.item input[type="checkbox"] {
  width: 19px;
  height: 19px;
  margin-top: 2px;
  accent-color: var(--success);
  cursor: pointer;
  flex-shrink: 0;
}

.item.checked input[type="checkbox"] { animation: check-pop 0.3s var(--ease); }

.item .status-dot {
  width: 19px;
  height: 19px;
  margin-top: 2px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 2px solid var(--border-strong);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: #fff;
  transition: background 0.2s, border-color 0.2s;
}

.item .status-dot.answered { background: var(--success); border-color: var(--success); animation: check-pop 0.3s var(--ease); }

.item .body { flex: 1; min-width: 0; }
.item .text { font-size: 14.5px; font-weight: 500; color: var(--ink); transition: color 0.15s; }
.item.checked .text { color: var(--muted); }
.item .meta { font-size: 11.5px; color: var(--success); font-weight: 600; margin-top: 2px; animation: fade-in 0.25s var(--ease); }

.choice-row { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 9px; }

.choice-chip {
  font-size: 12.5px;
  font-weight: 600;
  padding: 6px 13px;
  border-radius: 7px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--ink-soft);
  cursor: pointer;
  transition: background 0.2s var(--ease), border-color 0.2s var(--ease), color 0.2s var(--ease), transform 0.18s var(--ease), box-shadow 0.2s var(--ease);
}

.choice-chip:hover {
  border-color: var(--accent-border);
  color: var(--accent);
  background: var(--accent-soft);
  transform: translateY(-1px);
}

.choice-chip:active { transform: scale(0.97); }

.choice-chip.selected {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
  box-shadow: 0 6px 16px rgba(45, 212, 200, 0.2);
}

.item .note-input {
  margin-top: 8px;
  font-size: 13px;
  padding: 7px 11px;
  border: 1px solid transparent;
  background: var(--surface-alt);
  border-radius: 7px;
}

.item .note-input:focus { background: var(--surface); border-color: var(--accent); }

.item .note-input.has-note { background: var(--warning-soft); border-color: var(--warning-border); color: var(--warning); }

/* ---------- Sign-off ---------- */

.signoff-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 620px) { .signoff-grid { grid-template-columns: 1fr; } }

.sig-slot {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 15px;
  background: var(--surface-alt);
  transition: border-color 0.25s, background 0.25s;
}

.sig-slot .role-label { font-size: 10.5px; font-weight: 700; letter-spacing: 0.07em; text-transform: uppercase; color: var(--muted); }

.sig-slot.signed { border-color: var(--success-border); background: var(--success-soft); }
.sig-slot.signed .role-label { color: var(--success); }

.sig-slot img {
  max-width: 100%;
  height: 72px;
  object-fit: contain;
  display: block;
  margin-top: 8px;
  background: #fff;
  border-radius: 8px;
  border: 1px solid var(--border);
  padding: 4px 10px;
  animation: scale-in 0.3s var(--ease);
}

canvas.sig-pad {
  width: 100%;
  height: 148px;
  border: 1.5px dashed var(--border-strong);
  border-radius: var(--radius-sm);
  background: #fff;
  touch-action: none;
  cursor: crosshair;
}

.locked-banner {
  background: var(--success-soft);
  border: 1px solid var(--success-border);
  color: var(--success);
  font-weight: 600;
  text-align: center;
  padding: 12px;
  border-radius: var(--radius);
  margin-bottom: 14px;
  animation: rise-in 0.35s var(--ease);
}

/* ---------- Modal ---------- */

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(3px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 40;
  animation: fade-in 0.15s ease;
}

.modal {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  padding: 24px;
  width: 100%;
  max-width: 440px;
  animation: scale-in 0.25s var(--ease);
}

.modal h2 { font-size: 18px; font-weight: 800; letter-spacing: -0.01em; text-transform: none; color: var(--ink); margin-bottom: 6px; }

.hidden { display: none !important; }

pre.slack-preview {
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 13px;
  font-size: 12.5px;
  color: var(--ink-soft);
  white-space: pre-wrap;
  max-height: 320px;
  overflow-y: auto;
  margin: 14px 0 0;
  animation: rise-in 0.3s var(--ease);
}

/* ---------- Plans & AI ---------- */

.ai-notice {
  background: var(--warning-soft);
  border: 1px solid var(--warning-border);
  color: var(--warning);
  font-size: 13px;
  padding: 11px 13px;
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
}

.plans-tools { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 6px; }
@media (max-width: 620px) { .plans-tools { grid-template-columns: 1fr; } }

.plans-tools .tool { border: 1px solid var(--border); border-radius: var(--radius); padding: 15px; background: var(--surface-alt); }

.tool-label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}

label.file-btn {
  display: inline-block;
  font-size: 13.5px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  padding: 10px 15px;
  cursor: pointer;
  background: var(--surface);
  color: var(--ink-soft);
  border: 1px solid var(--border-strong);
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

label.file-btn:hover { background: var(--accent-soft); border-color: var(--accent-border); color: var(--accent); }

.plan-row {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 13px 0;
  border-bottom: 1px solid var(--border);
  animation: rise-in 0.35s var(--ease) both;
}

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

.plan-thumb img { width: 72px; height: 54px; object-fit: cover; border-radius: 8px; border: 1px solid var(--border); display: block; background: #fff; }

.plan-row .body { flex: 1; min-width: 0; }

.plan-title { font-weight: 600; color: var(--ink); text-decoration: none; }
.plan-title:hover { color: var(--accent); }

/* ---------- Plan viewer ---------- */

.plan-stage { position: relative; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: #fff; }
.plan-stage img { width: 100%; display: block; }
#overlay { position: absolute; inset: 0; }

.room-box {
  position: absolute;
  border: 2px solid rgba(45, 212, 200, 0.7);
  background: rgba(45, 212, 200, 0.12);
  border-radius: 4px;
  pointer-events: none;
  animation: fade-in 0.4s var(--ease);
}

.room-box span {
  position: absolute;
  top: -1px;
  left: -1px;
  background: rgba(15, 118, 110, 0.95);
  color: #ecfeff;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 3px 0 6px 0;
  white-space: nowrap;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pin {
  position: absolute;
  transform: translate(-50%, -50%);
  min-width: 26px;
  height: 26px;
  padding: 0 5px;
  border-radius: 7px;
  border: 2px solid #fff;
  color: #fff;
  font-size: 10.5px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: scale-in 0.3s var(--ease) both;
  transition: transform 0.15s var(--ease);
}

.pin:hover { transform: translate(-50%, -50%) scale(1.12); }

.toggle { font-size: 12.5px; font-weight: 600; color: var(--muted); display: flex; align-items: center; gap: 6px; cursor: pointer; }
.toggle input { accent-color: var(--accent); width: 15px; height: 15px; }

.pin-popup {
  position: absolute;
  z-index: 30;
  background: var(--tooltip-bg);
  border: 1px solid var(--border-strong);
  color: #eaeaef;
  border-radius: var(--radius);
  padding: 13px 15px;
  max-width: 320px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
  font-size: 13px;
  animation: scale-in 0.18s var(--ease);
}

.pin-popup .popup-title { font-weight: 700; color: #fff; margin-bottom: 6px; }
.pin-popup ul { margin: 0; padding-left: 18px; }
.pin-popup .popup-source { margin-top: 8px; padding-top: 8px; border-top: 1px solid rgba(255, 255, 255, 0.14); color: #a5a5b0; font-size: 12px; }

.legend-room { padding: 11px 0; border-bottom: 1px solid var(--border); }
.legend-room:last-child { border-bottom: none; }

.legend-room-name { font-size: 12.5px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink); margin-bottom: 7px; }

.legend-pin { display: flex; align-items: flex-start; gap: 10px; padding: 5px 0; }

.legend-dot {
  flex-shrink: 0;
  min-width: 24px;
  height: 24px;
  padding: 0 4px;
  border-radius: 6px;
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid rgba(255, 255, 255, 0.5);
}

/* ---------- Header links & small buttons ---------- */

.nav-link {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-soft);
  text-decoration: none;
  padding: 7px 11px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  transition: all 0.15s var(--ease);
}

.nav-link:hover { color: var(--accent); background: var(--accent-soft); border-color: var(--accent-border); }

.invite-panel {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

.invite-panel select {
  width: 100%;
}

.badge.warn-pill { background: var(--warning-soft); border-color: var(--warning-border); color: var(--warning); cursor: help; }

button.small { font-size: 12px; padding: 6px 11px; }
button.danger-text { color: var(--danger); }
button.danger-text:hover { color: var(--danger); background: rgba(248, 113, 113, 0.12); border-color: rgba(248, 113, 113, 0.4); }

/* ---------- Search, filters & walk actions ---------- */

.list-toolbar {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent 40%), var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
  margin-bottom: 12px;
}

.list-toolbar .choice-row { margin-top: 0; }

.filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  margin-top: 12px;
}

/* Filters are secondary to the department picker above, so they read quieter. */
.filter-row .choice-chip {
  font-size: 12px;
  padding: 5px 11px;
  background: var(--surface-alt);
  border-color: var(--border);
  color: var(--muted);
}

.filter-row .choice-chip:hover {
  background: var(--accent-soft);
  border-color: var(--accent-border);
  color: var(--accent);
}

.filter-row .choice-chip.selected { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }

.filter-row > .choice-row + .choice-row::before {
  content: '';
  align-self: stretch;
  width: 1px;
  background: var(--border);
  margin-right: 6px;
}

.walk-footer { margin-top: 12px; padding-top: 11px; border-top: 1px solid var(--border); }
.walk-actions { gap: 6px; opacity: 0; transition: opacity 0.15s var(--ease); }
.walk-link:hover .walk-actions, .walk-link:focus-within .walk-actions { opacity: 1; }
@media (hover: none) { .walk-actions { opacity: 1; } }

/* ---------- Item photos ---------- */

.photo-strip { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 9px; }

.photo-thumb { position: relative; }

.photo-thumb img {
  width: 58px;
  height: 58px;
  object-fit: cover;
  border-radius: 7px;
  border: 1px solid var(--border-strong);
  background: var(--surface-alt);
  cursor: zoom-in;
  display: block;
  animation: scale-in 0.25s var(--ease);
}

.photo-remove {
  position: absolute;
  top: -5px;
  right: -5px;
  width: 19px;
  height: 19px;
  padding: 0;
  border-radius: 50%;
  background: var(--surface);
  color: var(--muted);
  border: 1px solid var(--border-strong);
  font-size: 13px;
  line-height: 1;
  display: none;
}

.photo-thumb:hover .photo-remove { display: block; }
.photo-remove:hover { background: var(--danger); color: #fff; border-color: var(--danger); }
@media (hover: none) { .photo-remove { display: block; } }

label.photo-add {
  width: 58px;
  height: 58px;
  border: 1.5px dashed var(--border-strong);
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--muted);
  transition: all 0.15s var(--ease);
}

label.photo-add:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }
label.photo-add svg { width: 20px; height: 20px; }
label.photo-add.busy { opacity: 0.5; pointer-events: none; }
label.photo-add.busy svg { animation: pulse-soft 1s ease-in-out infinite; }

@keyframes pulse-soft { 50% { opacity: 0.35; } }

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: rgba(0, 0, 0, 0.88);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px;
  cursor: zoom-out;
  animation: fade-in 0.15s ease;
}

.lightbox img { max-width: 100%; max-height: 100%; border-radius: var(--radius); }

/* ---------- Login ---------- */

.page-login {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  min-height: 100dvh;
  padding: env(safe-area-inset-top, 0px) 0 env(safe-area-inset-bottom, 0px);
}

.login-shell {
  width: 100%;
  max-width: 420px;
  padding: 24px 18px;
}

.login-card {
  position: relative;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent 40%), var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 28px 26px;
  animation: scale-in 0.45s var(--ease) both;
}

.login-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 22px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
  animation: rise-in 0.45s var(--ease) both;
}
.login-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
}

.login-card form.stack > .field:nth-child(1) { animation: rise-in 0.4s var(--ease) both; animation-delay: 0.08s; }
.login-card form.stack > .field:nth-child(2) { animation: rise-in 0.4s var(--ease) both; animation-delay: 0.14s; }
.login-card form.stack > .field:nth-child(3) { animation: rise-in 0.4s var(--ease) both; animation-delay: 0.2s; }
.login-card form.stack > button,
.login-card form.stack > #login-btn,
.login-card form.stack > #change-btn {
  animation: rise-in 0.4s var(--ease) both;
  animation-delay: 0.22s;
}

.login-brand strong {
  display: block;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.04em;
}
.login-brand .sub {
  font-family: var(--font-meta);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.login-card input { background: var(--surface-alt); }

.login-card input:-webkit-autofill,
.login-card input:-webkit-autofill:hover,
.login-card input:-webkit-autofill:focus {
  -webkit-box-shadow: 0 0 0 1000px var(--surface-alt) inset;
}

.login-error { margin-top: 4px; font-size: 13px; font-weight: 600; color: var(--danger); }

#login-form button,
#change-form button {
  width: 100%;
  margin-top: 4px;
  min-height: 44px;
}

/* ---------- Template editor ---------- */

.template-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  padding: 7px 0;
  border-bottom: 1px solid var(--border);
}

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

.template-row input, .template-row select {
  padding: 8px 11px;
  font: inherit;
  font-size: 13px;
  color: var(--ink);
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 7px;
  min-width: 0;
}

.template-row input:focus, .template-row select:focus { outline: none; border-color: var(--accent); background: var(--surface); }

.template-row .template-section { flex: 0 0 140px; color: var(--muted); font-weight: 600; }
.template-row .template-text { flex: 1 1 200px; }
.template-row .template-kind { flex: 0 0 118px; }
.template-row .template-options { flex: 0 0 130px; }
.template-row button { flex: 0 0 auto; margin-left: auto; }

/* ---------- Users, notifications, audit trail ---------- */

.user-form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; }

.user-row {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  padding: 12px 12px;
  margin: 0 -8px;
  border-radius: var(--radius-sm);
  border-bottom: 1px solid var(--border);
  transition: background 0.15s var(--ease);
}

.user-row:hover { background: var(--surface-alt); }
.user-row:last-child { border-bottom: none; }
.user-row.inactive { opacity: 0.55; }
.user-row .body { min-width: 0; }
.user-row .body strong { font-size: 14.5px; }
.user-row .muted { font-size: 12.5px; margin-top: 2px; }

select.small-select {
  font-size: 12px;
  padding: 6px 8px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  max-width: 110px;
}

#session-slot { display: inline-flex; align-items: center; gap: 8px; flex-shrink: 0; }

.alert-bell {
  white-space: nowrap;
  flex-shrink: 0;
}

.alert-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(5, 5, 8, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.alert-backdrop.hidden { display: none; }

.alert-modal {
  width: min(420px, 100%);
  max-height: min(80vh, 560px);
  overflow: auto;
  padding: 16px 16px 12px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
  animation: scale-in 0.18s var(--ease) both;
}

.alert-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.alert-modal-head h2 {
  margin: 0;
  font-size: 18px;
  letter-spacing: -0.02em;
}

.alert-modal-item {
  padding: 14px 0;
  border-top: 1px solid var(--border);
}

.alert-modal-item p {
  margin: 0 0 12px;
  font-size: 14.5px;
  line-height: 1.45;
  color: var(--ink);
}

.alert-modal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

a.button-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

a.button-link:hover { background: var(--accent-hover); }

.notif-wrap { position: relative; }

.notif-panel {
  display: none;
}

.menu-wrap { position: relative; display: inline-flex; flex-shrink: 0; }

.menu-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  color: var(--ink-soft);
  cursor: pointer;
  transition: all 0.15s var(--ease);
}

.menu-btn svg { width: 18px; height: 18px; }

.menu-btn:hover,
.menu-btn[aria-expanded="true"] {
  color: var(--accent);
  background: var(--accent-soft);
  border-color: var(--accent-border);
}

.menu-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 40;
  width: min(250px, calc(100vw - 24px));
  padding: 6px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
  transform-origin: top right;
  animation: scale-in 0.14s var(--ease) both;
}

@media (max-width: 720px) {
  .menu-panel {
    position: fixed;
    top: 58px;
    right: 12px;
    left: auto;
  }
}

.menu-who {
  padding: 9px 11px 11px;
  margin-bottom: 6px;
  border-bottom: 1px solid var(--border);
}

.menu-who strong { display: block; font-size: 13.5px; letter-spacing: -0.01em; }

.menu-who span {
  display: block;
  margin-top: 2px;
  font-size: 11.5px;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.menu-item {
  display: block;
  width: 100%;
  padding: 9px 11px;
  border: 0;
  border-radius: var(--radius-sm);
  background: none;
  color: var(--ink-soft);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
}

.menu-item:hover { background: var(--surface-alt); color: var(--ink); }
.menu-item.danger { color: var(--danger); }
.menu-item.danger:hover { background: rgba(248, 113, 113, 0.12); }

.menu-sep { height: 1px; margin: 6px 0; background: var(--border); }

.signoff-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  display: flex;
  justify-content: center;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px));
  background: rgba(10, 12, 16, 0.94);
  backdrop-filter: blur(14px) saturate(1.15);
  -webkit-backdrop-filter: blur(14px) saturate(1.15);
  border-top: 1px solid var(--border);
  box-shadow: 0 -8px 28px rgba(0, 0, 0, 0.4);
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
  animation: slide-up 0.35s var(--ease) both;
}

.signoff-bar.hidden { display: none; }

.signoff-bar--waiting button {
  opacity: 0.85;
  cursor: default;
  animation: soft-pulse 2.4s ease-in-out infinite;
}

.signoff-bar button {
  width: min(420px, 100%);
  margin: 0;
}

.sign-notify-modal h2 { margin: 0 0 10px; font-size: 18px; }

.sign-notify-actions {
  flex-direction: column;
  align-items: stretch;
}

.sign-notify-actions button,
.sign-notify-actions .button-link {
  width: 100%;
  justify-content: center;
  text-align: center;
}

body.has-signoff-bar .container {
  padding-bottom: calc(88px + env(safe-area-inset-bottom, 0px));
}

body.sig-modal-open {
  overflow: hidden;
}

body.sig-modal-open .signoff-bar {
  display: none;
}

@media (max-width: 720px) {
  .signoff-bar {
    z-index: 1000;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom, 0px));
  }

  .signoff-bar button {
    min-height: 48px;
    font-size: 16px;
  }

  .signoff-bar button:not(:disabled) {
    opacity: 1;
  }

  .sign-notify-modal {
    width: min(400px, calc(100vw - 28px));
    margin: 0 auto;
  }

  .sign-notify-actions button {
    min-height: 48px;
    font-size: 15px;
  }

  .modal-backdrop {
    z-index: 50;
    align-items: flex-end;
    padding: 0;
  }

  .modal-backdrop .modal {
    width: 100%;
    max-width: none;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    max-height: min(92vh, 640px);
    overflow-y: auto;
    padding: 20px 18px calc(18px + env(safe-area-inset-bottom, 0px));
  }

  canvas.sig-pad {
    height: 200px;
  }

  #sign-notify-backdrop {
    z-index: 110;
    padding: 16px;
  }
}

.audit-row { padding: 9px 0; border-bottom: 1px solid var(--border); font-size: 13.5px; }
.audit-row:last-child { border-bottom: none; }

/* ---------- Printable report ---------- */

.report-sheet { padding-top: 26px; }

.report-hint {
  background: var(--accent-soft);
  border: 1px solid var(--accent-border);
  color: var(--accent);
  font-size: 13px;
  padding: 11px 13px;
  border-radius: var(--radius-sm);
  margin-bottom: 20px;
}

.report-head { display: flex; justify-content: space-between; gap: 18px; padding-bottom: 16px; border-bottom: 2px solid var(--border-strong); }
.report-head h1 { font-size: 24px; margin-bottom: 4px; }
.report-stamp { text-align: right; font-size: 13px; font-weight: 700; flex-shrink: 0; }
.report-stamp .muted { font-weight: 500; }

.report-section { margin-top: 26px; }
.report-section h2 { font-size: 13px; font-weight: 800; letter-spacing: 0.07em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.report-section-head { display: flex; justify-content: space-between; align-items: baseline; }

.report-item { display: flex; gap: 11px; padding: 9px 0; border-bottom: 1px solid var(--border); page-break-inside: avoid; }
.report-item:last-child { border-bottom: none; }
.report-mark { color: var(--muted); font-weight: 700; flex-shrink: 0; }
.report-mark.done { color: var(--success); }
.report-item-text { display: flex; flex-wrap: wrap; gap: 8px; align-items: baseline; }
.report-answer { font-size: 12px; font-weight: 700; padding: 2px 9px; border-radius: 6px; background: var(--accent-soft); color: var(--accent); }
.report-byline { font-size: 12px; color: var(--muted); margin-top: 3px; }
.report-note { font-size: 13px; color: var(--warning); margin-top: 4px; }
.report-question { font-size: 14px; padding: 7px 0 7px 13px; border-left: 3px solid var(--warning-border); margin-bottom: 7px; }

.report-photos { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 8px; }
.report-photos img { width: 128px; height: 96px; object-fit: cover; border-radius: 7px; border: 1px solid var(--border); }

.report-sig-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.report-sig-role { font-size: 11px; font-weight: 800; letter-spacing: 0.07em; text-transform: uppercase; color: var(--muted); margin-bottom: 7px; }
.report-sig img { height: 62px; object-fit: contain; display: block; background: #fff; border-radius: 6px; padding: 4px 8px; }
.report-sig-blank { height: 62px; border-bottom: 1.5px dashed var(--border-strong); }
.report-sig-name { font-weight: 700; margin-top: 6px; }

/* Print on white: remap the dark palette rather than restating every rule */
@media print {
  :root {
    color-scheme: light;
    --bg: #fff;
    --surface: #fff;
    --surface-alt: #fff;
    --border: #ccc;
    --border-strong: #999;
    --ink: #000;
    --ink-soft: #222;
    --muted: #555;
    --accent: #333;
    --accent-soft: transparent;
    --accent-border: #999;
    --success: #000;
    --warning: #444;
    --warning-border: #999;
    --shadow: none;
    --shadow-sm: none;
  }
  .no-print { display: none !important; }
  .report-sheet { padding: 0; max-width: none; }
  .report-answer { border: 1px solid var(--border-strong); }
}

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