/* Crew cars: ramp-concrete base, airfield-sign placards for car numbers,
   annunciator-style status lamps. */

:root {
  --bg: #e3e7e5;
  --surface: #ffffff;
  --surface-2: #f2f4f3;
  --ink: #17212b;
  --ink-2: #4b5862;
  --line: #c6cdca;
  --sign: #f7c600;
  --sign-ink: #000000;
  --green: #1f8a3b;
  --amber: #d98a00;
  --red: #c4281c;
  --green-bg: #e2f2e6;
  --amber-bg: #fdf1d8;
  --red-bg: #fbe3e0;
  --focus: #1b6fd1;
  --sign-tint: #fff6cc;
  --amber-text: #8f5400;
  --red-text: #b3241a;
  --line-strong: #b4bcb9;
  --radius: 10px;
  --radius-sm: 6px;
  --font: 'Barlow', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-sign: 'Barlow Semi Condensed', 'Barlow', system-ui, sans-serif;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #10171d;
    --surface: #19232c;
    --surface-2: #212d37;
    --ink: #e7ecee;
    --ink-2: #a3b0b8;
    --line: #34424d;
    --green: #3fbf63;
    --amber: #f2a922;
    --red: #f0574a;
    --green-bg: #173323;
    --amber-bg: #3a2c10;
    --red-bg: #3d1a17;
    --focus: #6aa8f0;
    --sign-tint: #2b2a17;
    --amber-text: #f2b84b;
    --red-text: #ff8a80;
    --line-strong: #4a5965;
    color-scheme: dark;
  }
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.45;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-sign);
  line-height: 1.15;
  margin: 0;
}

h1 {
  font-size: 2rem;
  font-weight: 800;
}

h2 {
  font-size: 1.35rem;
  font-weight: 700;
}

h3 {
  font-size: 1.1rem;
  font-weight: 700;
}

p {
  margin: 0.4em 0;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.wrap {
  max-width: 600px;
  margin: 0 auto;
  padding: 16px 16px 48px;
}

.wrap-wide {
  max-width: 960px;
}

.muted {
  color: var(--ink-2);
}

.small {
  font-size: 0.88rem;
}

.loading,
.empty {
  padding: 32px 16px;
  text-align: center;
  color: var(--ink-2);
}

/* ---------- top bar ---------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  padding-top: max(10px, env(safe-area-inset-top));
  background: var(--ink);
  color: #fff;
}

@media (prefers-color-scheme: dark) {
  .topbar {
    background: #0a0f13;
    border-bottom: 1px solid var(--line);
  }
}

.brand {
  font-family: var(--font-sign);
  font-weight: 800;
  font-size: 1.2rem;
  text-decoration: none;
  letter-spacing: 0.01em;
}

.topnav a {
  color: #fff;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.35);
}

/* ---------- placard: the car number as an airfield sign ---------- */

.placard {
  display: inline-grid;
  place-items: center;
  flex: none;
  min-width: 52px;
  height: 52px;
  padding: 0 8px;
  background: var(--sign);
  color: var(--sign-ink);
  font-family: var(--font-sign);
  font-weight: 800;
  font-size: 1.9rem;
  line-height: 1;
  border-radius: 4px;
  box-shadow:
    inset 0 0 0 3px var(--sign),
    inset 0 0 0 5px var(--sign-ink);
}

.placard-xl {
  min-width: 96px;
  height: 96px;
  font-size: 3.8rem;
  box-shadow:
    inset 0 0 0 5px var(--sign),
    inset 0 0 0 8px var(--sign-ink);
}

/* ---------- status lamp ---------- */

.status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-weight: 600;
  font-size: 0.92rem;
  white-space: nowrap;
}

.lamp {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  background: currentColor;
  box-shadow: 0 0 0 2px var(--surface), 0 0 0 3px currentColor;
}

.status-green {
  color: var(--green);
}

.status-yellow {
  color: var(--amber);
}

.status-red {
  color: var(--red);
}

/* ---------- dashboard ---------- */

.board-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin: 8px 0 18px;
}

.board-summary {
  margin: 0;
  font-family: var(--font-sign);
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--ink-2);
}

.group {
  margin-bottom: 22px;
}

.group h2 {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  font-size: 1.15rem;
  padding: 0 2px 6px;
}

.group h2 .count {
  font-family: var(--font);
  font-weight: 500;
  font-size: 0.9rem;
  color: var(--ink-2);
}

.group-note {
  margin: -2px 2px 8px;
}

.rows {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.car-row + .car-row {
  border-top: 1px solid var(--line);
}

.car-row summary {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  cursor: pointer;
  list-style: none;
}

.car-row summary::-webkit-details-marker {
  display: none;
}

.car-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}

.car-name {
  font-weight: 600;
  font-size: 1.05rem;
}

.car-model {
  font-weight: 400;
  color: var(--ink-2);
}

.car-sub {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 12px;
}

.car-meta {
  color: var(--ink-2);
  font-size: 0.92rem;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

.tag {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--amber-bg);
  color: var(--ink);
}

.tag-red {
  background: var(--red-bg);
}

.tag-green {
  background: var(--green-bg);
}

.chev {
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--ink-2);
  border-bottom: 2px solid var(--ink-2);
  transform: rotate(45deg);
  margin-right: 4px;
  transition: transform 0.15s;
}

details[open] > summary .chev {
  transform: rotate(225deg);
}

.car-detail {
  padding: 0 14px 14px 80px;
}

.car-detail .btn {
  margin-top: 8px;
}

.reasons {
  margin: 4px 0;
  padding: 0;
  list-style: none;
}

.reasons li {
  position: relative;
  padding: 3px 0 3px 18px;
}

.reasons li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 9px;
  height: 9px;
  border-radius: 2px;
}

.r-red::before {
  background: var(--red);
}

.r-yellow::before {
  background: var(--amber);
}

.notes h4 {
  font-size: 0.95rem;
  margin-top: 8px;
}

.empty-locs {
  margin-top: -8px;
}

@media (max-width: 420px) {
  .car-detail {
    padding-left: 14px;
  }
}

/* ---------- car page ---------- */

.car-hero {
  display: flex;
  align-items: center;
  gap: 18px;
  margin: 10px 0 18px;
}

.car-hero h1 {
  font-size: 2.3rem;
}

.car-hero .car-model {
  margin: 0 0 4px;
  font-size: 1.05rem;
}

.briefing {
  display: grid;
  gap: 12px;
  margin-bottom: 18px;
}

.brief-block {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 5px solid var(--amber);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
}

.brief-block .note {
  margin: 6px 0 0;
}

.banner {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  font-weight: 500;
}

.banner-red {
  background: var(--red-bg);
  border: 2px solid var(--red);
}

.squawk-list {
  margin: 6px 0 0;
  padding-left: 1.1em;
}

.squawk-list li {
  margin: 4px 0;
}

.squawk-note {
  display: block;
  font-size: 0.88rem;
  color: var(--ink-2);
}

.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 16px;
}

.lead {
  font-size: 1.1rem;
}

.question {
  font-family: var(--font-sign);
  font-weight: 700;
  font-size: 1.4rem;
  margin-top: 12px;
}

.choice-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 12px 0 8px;
}

.done {
  text-align: left;
}

.done-mark {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--green);
  position: relative;
  margin-bottom: 12px;
}

.done-mark::after {
  content: '';
  position: absolute;
  left: 20px;
  top: 12px;
  width: 14px;
  height: 26px;
  border-right: 5px solid #fff;
  border-bottom: 5px solid #fff;
  transform: rotate(45deg);
}

.done .btn {
  margin-top: 16px;
}

/* ---------- forms ---------- */

.form h2 {
  margin-bottom: 6px;
}

.field {
  display: block;
  margin: 16px 0;
  border: 0;
  padding: 0;
}

.label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
}

.help {
  display: block;
  font-size: 0.88rem;
  color: var(--ink-2);
  margin-top: 5px;
}

input[type='text'],
input:not([type]),
input[type='email'],
input[type='password'],
input[type='number'],
input[type='date'],
select,
textarea {
  width: 100%;
  font: inherit;
  font-size: 1.05rem;
  color: var(--ink);
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 11px 12px;
  min-height: 48px;
}

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

input:focus,
select:focus,
textarea:focus {
  border-color: var(--focus);
  outline: none;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--focus) 25%, transparent);
}

::placeholder {
  color: var(--ink-2);
  opacity: 0.85;
}

.clean-qs {
  margin: 18px 0;
}

.seg {
  border: 0;
  margin: 10px 0;
  padding: 0;
}

.seg legend {
  font-weight: 500;
  padding: 0;
  margin-bottom: 6px;
}

.seg-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.seg label,
.place,
.check {
  position: relative;
  display: flex;
  align-items: center;
  cursor: pointer;
}

.seg input,
.place input {
  position: absolute;
  opacity: 0;
  inset: 0;
  margin: 0;
  cursor: pointer;
}

.seg span,
.place span {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 8px 10px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  font-weight: 600;
  text-align: center;
}

.place span {
  justify-content: flex-start;
  text-align: left;
}

.seg input:checked + span,
.place input:checked + span {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--surface);
}

.seg input[value='0']:checked + span {
  background: var(--amber-bg);
  color: var(--ink);
  border-color: var(--amber);
}

.seg input:focus-visible + span,
.place input:focus-visible + span {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.places {
  display: grid;
  gap: 8px;
}

.places legend {
  margin-bottom: 8px;
}

.other-input {
  margin-top: 2px;
}

.check {
  gap: 12px;
  margin: 16px 0;
  padding: 12px;
  border: 1.5px solid var(--amber);
  background: var(--amber-bg);
  border-radius: var(--radius-sm);
  font-weight: 600;
}

.check input {
  width: 24px;
  height: 24px;
  flex: none;
  accent-color: var(--ink);
}

.hint {
  margin-top: 8px;
  font-size: 0.92rem;
}

.hint summary {
  cursor: pointer;
  color: var(--ink-2);
  text-decoration: underline;
  text-underline-offset: 3px;
  width: fit-content;
}

.hint p {
  margin: 6px 0 0;
  padding: 10px 12px;
  background: var(--surface-2);
  border-radius: var(--radius-sm);
}

.form-error {
  background: var(--red-bg);
  border: 1.5px solid var(--red);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  font-weight: 500;
}

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 10px 18px;
  font: inherit;
  font-weight: 600;
  font-size: 1rem;
  color: var(--ink);
  background: var(--surface);
  border: 1.5px solid var(--ink);
  border-radius: var(--radius-sm);
  text-decoration: none;
  cursor: pointer;
}

.btn-primary {
  background: var(--ink);
  color: var(--surface);
}

.btn-quiet {
  border-color: var(--line);
  background: var(--surface-2);
}

.btn-danger {
  border-color: var(--red);
  color: var(--red);
}

.btn-block {
  display: flex;
  width: 100%;
  margin-top: 10px;
}

.btn-sm {
  min-height: 36px;
  padding: 5px 12px;
  font-size: 0.9rem;
}

.btn:disabled {
  opacity: 0.6;
  cursor: progress;
}

/* ---------- dialog ---------- */

.brief-dialog {
  width: min(560px, calc(100vw - 24px));
  max-height: calc(100dvh - 32px);
  padding: 0;
  border: 0;
  border-radius: var(--radius);
  background: var(--bg);
  color: var(--ink);
}

.brief-dialog::backdrop {
  background: rgba(10, 15, 20, 0.6);
}

.brief-inner {
  display: grid;
  gap: 12px;
  padding: 18px 16px;
}

/* ---------- toast ---------- */

.toast {
  position: fixed;
  left: 50%;
  bottom: max(20px, env(safe-area-inset-bottom));
  transform: translate(-50%, 140%);
  max-width: calc(100vw - 32px);
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  background: var(--ink);
  color: var(--surface);
  font-weight: 500;
  transition: transform 0.2s;
  z-index: 50;
}

.toast.show {
  transform: translate(-50%, 0);
}

.toast-err {
  background: var(--red);
  color: #fff;
}

@media (prefers-reduced-motion: reduce) {
  .toast,
  .chev {
    transition: none;
  }
}

/* ---------- admin ---------- */

.admin-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin: 6px 0 12px;
}

.linklike {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding-bottom: 8px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--line);
  scrollbar-width: thin;
}

.tab {
  flex: none;
  font: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink-2);
  background: transparent;
  border: 1.5px solid transparent;
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  cursor: pointer;
}

.tab.on {
  color: var(--ink);
  background: var(--surface);
  border-color: var(--line);
}

.badge {
  display: inline-grid;
  place-items: center;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  margin-left: 4px;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-size: 0.8rem;
}

.tab-body section {
  margin-bottom: 26px;
}

.tab-body h2 {
  margin-bottom: 8px;
}

.tab-body h2 .count {
  font-family: var(--font);
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--ink-2);
}

.admin-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
  margin-bottom: 10px;
}

.admin-card > summary {
  cursor: pointer;
}

.ac-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 6px;
}

.ac-head .placard {
  min-width: 44px;
  height: 44px;
  font-size: 1.6rem;
}

.sq-text {
  font-size: 1.1rem;
  font-weight: 500;
}

.sq-row + .sq-row {
  border-top: 1px dashed var(--line);
  margin-top: 12px;
  padding-top: 12px;
}

.field.compact {
  margin: 10px 0;
}

.field.compact .label {
  font-size: 0.9rem;
  margin-bottom: 4px;
}

.field.compact input,
.field.compact select,
.field.compact textarea,
.loc-row input {
  min-height: 42px;
  padding: 8px 10px;
  font-size: 1rem;
}

.two {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 0 12px;
}

.check-inline {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 10px 0;
  font-weight: 500;
  cursor: pointer;
}

.check-inline input {
  width: 20px;
  height: 20px;
  flex: none;
  accent-color: var(--ink);
}

.btns {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.disclosures details {
  border-top: 1px solid var(--line);
  padding: 8px 0 0;
  margin-top: 8px;
}

.disclosures summary,
.admin-card details > summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 0.95rem;
}

.inline-form {
  padding-top: 4px;
}

.plain-list {
  list-style: none;
  margin: 6px 0 0;
  padding: 0;
}

.plain-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 0;
  border-top: 1px solid var(--line);
}

.plain-list li:first-child {
  border-top: 0;
}

.loc-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.loc-row input {
  flex: 1 1 220px;
}

.chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 6px;
  margin-bottom: 14px;
}

.chip {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font: inherit;
  font-weight: 600;
  color: var(--ink);
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: 999px;
  padding: 4px 14px 4px 4px;
  cursor: pointer;
}

.chip.on {
  border-color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--ink);
}

.placard-sm {
  min-width: 32px;
  height: 32px;
  font-size: 1.15rem;
  box-shadow:
    inset 0 0 0 2px var(--sign),
    inset 0 0 0 3.5px var(--sign-ink);
  border-radius: 999px;
}

.maint {
  border-left-width: 5px;
}

.maint.st-ok {
  border-left-color: var(--green);
}

.maint.st-soon,
.maint.st-nodata {
  border-left-color: var(--amber);
}

.maint.st-overdue {
  border-left-color: var(--red);
}

.mi-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 12px;
}

.mi-state {
  font-weight: 600;
}

.st-overdue .mi-state {
  color: var(--red);
}

.trip > summary {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.trip-car {
  flex: none;
  font-family: var(--font-sign);
  font-weight: 700;
  min-width: 54px;
}

.trip-main {
  display: flex;
  flex-direction: column;
}

.email-frame {
  display: block;
  width: 100%;
  max-width: 660px;
  height: 720px;
  margin: 10px 0 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: #e3e7e5;
}

.email-text summary {
  cursor: pointer;
  margin-top: 8px;
}

.report {
  white-space: pre-wrap;
  font-family: var(--font);
  font-size: 0.92rem;
  background: var(--surface-2);
  border-radius: var(--radius-sm);
  padding: 12px;
  margin: 10px 0 0;
  max-height: 480px;
  overflow: auto;
}

.banner-amber {
  background: var(--amber-bg);
  border: 1.5px solid var(--amber);
  margin-bottom: 12px;
}

/* ---------- printed cards: 3 x 5 in (288 x 480 px at 96 px/in) ---------- */

.qr-grid {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-top: 16px;
}

.card-pair {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  break-inside: avoid;
}

.vcard {
  --vc-bg: #17212b;
  --vc-accent: #f7c600;
  --vc-text: #e7ecee;
  --vc-sub: #c4ced4;
  --vc-rule: #34424d;
  position: relative;
  width: 288px;
  height: 480px;
  flex: none;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  padding: 20px 18px 17px;
  border-radius: 12px;
  overflow: hidden;
  background: var(--vc-bg);
  color: var(--vc-text);
  font-family: var(--font);
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}

.vcard::before {
  content: '';
  position: absolute;
  inset: 7px;
  border: 1.5px solid var(--vc-accent);
  border-radius: 7px;
  pointer-events: none;
}

.vcard-jump {
  --vc-bg: #c4281c;
  --vc-accent: #ffffff;
  --vc-text: #ffffff;
  --vc-sub: #ffe9e6;
  --vc-rule: #e0786f;
}

.vcard p {
  margin: 0;
}

.vc-row {
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.vc-kicker {
  font-family: var(--font-sign);
  font-weight: 700;
  font-size: 13px;
  line-height: 1;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--vc-accent);
}

.vc-tag {
  display: flex;
  padding: 2.5px;
  border-radius: 4px;
  background: #f7c600;
}

.vc-tag span {
  height: 19px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  padding: 0 6px;
  border: 1.5px solid #000;
  border-radius: 2px;
  font-family: var(--font-sign);
  font-weight: 800;
  font-size: 15px;
  line-height: 1;
  letter-spacing: 0.03em;
  color: #000;
}

.vc-head {
  display: flex;
  flex-direction: column;
  margin: 10px 0 0;
  font-family: var(--font-sign);
  font-weight: 800;
  font-size: 23px;
  line-height: 1.06;
  letter-spacing: -0.005em;
  color: #fff;
  white-space: nowrap;
}

.vc-accent {
  color: var(--vc-accent);
}

.vc-head-xl {
  margin-top: 14px;
  font-size: 34px;
  line-height: 0.98;
  letter-spacing: -0.01em;
}

.vcard .vc-sub {
  margin-top: 6px;
  font-size: 12.5px;
  line-height: 1.3;
  font-weight: 600;
  color: var(--vc-sub);
}

.vcard-jump .vc-sub {
  margin-top: 9px;
  font-size: 14px;
}

.vc-qr {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
}

.vc-qr-tile {
  width: 176px;
  height: 176px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border-radius: 10px;
}

.vc-qr-tile svg {
  display: block;
  width: 174px;
  height: 174px;
}

.vc-url {
  font-size: 12px;
  line-height: 15px;
  font-weight: 500;
  color: #a3b0b8;
  white-space: nowrap;
}

.vc-steps {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-top: 12px;
}

.vc-step {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.vc-step p,
.vc-num li {
  font-size: 13.5px;
  line-height: 1.27;
  font-weight: 500;
  color: var(--vc-text);
  text-wrap: pretty;
}

.vc-pill {
  flex: none;
  width: 36px;
  height: 18px;
  margin-top: 1px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--vc-accent);
  border-radius: 3px;
  font-family: var(--font-sign);
  font-weight: 800;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--vc-accent);
}

.vc-pill-fill {
  background: var(--vc-accent);
  color: #000;
}

.vc-bolt {
  display: block;
  width: 60px;
  height: 44px;
  margin-top: 22px;
  fill: none;
  stroke: #fff;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.vc-bolt .fill {
  fill: #fff;
  stroke-width: 2;
}

.vc-num {
  list-style: none;
  counter-reset: vc;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 16px 0 0;
  padding: 16px 0 0;
  border-top: 1px solid var(--vc-rule);
}

.vc-num li {
  counter-increment: vc;
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 14px;
}

.vc-num li::before {
  content: counter(vc);
  flex: none;
  width: 20px;
  height: 20px;
  margin-top: -1px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #fff;
  color: #c4281c;
  font-family: var(--font-sign);
  font-weight: 800;
  font-size: 13px;
}

.vc-foot {
  margin-top: auto;
  padding-top: 8px;
  border-top: 1px solid var(--vc-rule);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-size: 12px;
  line-height: 15px;
  font-weight: 600;
  color: var(--vc-accent);
  white-space: nowrap;
}

.vc-foot svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- home-screen help ---------- */

.site-foot {
  max-width: 600px;
  margin: 0 auto;
  padding: 8px 16px 40px;
  text-align: center;
}
.link-btn {
  min-height: 44px;
  padding: 8px 4px;
  border: 0;
  background: none;
  color: var(--ink-2);
  font: inherit;
  font-size: 0.9rem;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.link-btn:hover {
  color: var(--ink);
}
.install-dialog h2 {
  outline: none;
  margin: 0;
}
.ih-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  padding: 3px;
  border-radius: var(--radius);
  background: var(--surface-2);
  border: 1px solid var(--line);
}
.ih-switch button {
  min-height: 40px;
  border: 0;
  border-radius: var(--radius-sm);
  background: none;
  color: var(--ink-2);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
.ih-switch button[aria-pressed='true'] {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
}
.ih-steps {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: ih;
  display: grid;
  gap: 10px;
}
.ih-steps li {
  counter-increment: ih;
  position: relative;
  padding: 12px 12px 12px 48px;
  border-radius: var(--radius);
  background: var(--surface);
  line-height: 2.1;
}
.ih-steps li::before {
  content: counter(ih);
  position: absolute;
  left: 12px;
  top: 14px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--sign);
  color: var(--sign-ink);
  font-family: var(--font-sign);
  font-weight: 700;
  line-height: 26px;
  text-align: center;
}
.ih-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  margin: 0 2px;
  vertical-align: middle;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--focus);
}
.ih-word {
  display: inline-block;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--focus);
  font-weight: 600;
  line-height: 1.9;
}
.ih-done {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
}
.ih-done img {
  flex: none;
  border-radius: 9px;
}
.help .ih-btn {
  width: 28px;
  height: 28px;
}
.help .ih-btn svg {
  width: 17px;
  height: 17px;
}

@page {
  size: letter;
  margin: 0.4in;
}

@media print {
  body {
    background: #fff;
  }
  .topbar,
  .no-print,
  .tabs,
  .admin-head,
  #toast {
    display: none !important;
  }
  .wrap {
    max-width: none;
    padding: 0;
  }
  .qr-grid {
    display: block;
    margin: 0;
  }
  .card-pair {
    flex-wrap: nowrap;
    gap: 0.15in;
    margin-bottom: 0.15in;
    page-break-inside: avoid;
    break-inside: avoid;
  }
  .placard {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
}

.rows-empty {
  margin: 0;
  padding: 14px;
  color: var(--ink-2);
  border-style: dashed;
  background: transparent;
}

.admin-card > .field:first-child,
.admin-card > h2:first-child + .field {
  margin-top: 0;
}

/* ---------- car photos, IDs, documents ---------- */

.placard-mid {
  font-size: 1.45rem;
}

.placard-long {
  font-size: 1.05rem;
  letter-spacing: 0.02em;
}

.placard-xl.placard-mid {
  font-size: 2.9rem;
  padding: 0 14px;
}

.placard-xl.placard-long {
  font-size: 1.9rem;
  padding: 0 16px;
}

.placard-sm.placard-mid,
.placard-sm.placard-long {
  font-size: 0.78rem;
  padding: 0 8px;
}

.car-thumb {
  flex: none;
  width: 76px;
  height: 56px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  border: 1px solid var(--line);
}

.car-thumb.thumb-sm {
  width: 60px;
  height: 44px;
}

.car-photo {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: var(--radius);
  margin: 10px 0 0;
  background: var(--surface-2);
}

.car-hero.has-photo {
  margin-top: 12px;
}

.car-ids {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  margin: 0 0 6px;
  color: var(--ink-2);
  font-size: 0.95rem;
}

.car-photo-preview {
  display: block;
  width: 100%;
  max-width: 320px;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: var(--radius-sm);
  margin: 6px 0;
}

.doc-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: -6px 0 16px;
}

.car-detail .doc-links {
  margin: 8px 0;
}

.doc-link {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 6px 14px;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  font-weight: 600;
  font-size: 0.92rem;
  text-decoration: none;
}

.doc-link::before {
  content: '';
  width: 12px;
  height: 15px;
  margin-right: 8px;
  border: 2px solid currentColor;
  border-radius: 2px;
}

.visor-note {
  font-weight: 600;
}

.hint p + p {
  margin-top: 6px;
}

/* VIN check under the car form */
.vin-status {
  min-height: 1.4em;
}
.vin-status.vin-bad {
  color: var(--red);
  font-weight: 500;
}
.vin-status.vin-good {
  color: var(--green);
  font-weight: 500;
}

/* ---------- no car available ---------- */

.missed-cta {
  margin: -6px 0 18px;
}

.missed-form {
  margin-bottom: 22px;
}

.missed-form .places {
  grid-template-columns: 1fr 1fr;
}

.missed-form .places legend,
.missed-form .other-input {
  grid-column: 1 / -1;
}

.missed-form .places + .places {
  margin-top: 6px;
}

/* ---------- reports ---------- */

.chip:not(:has(.placard)) {
  padding: 8px 16px;
}

.rp-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px 16px;
  margin: 14px 0 6px;
}

.rp-range {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 8px 10px;
}

.rp-range [hidden] {
  display: none;
}

.rp-range .field {
  margin: 0;
  min-width: 150px;
}

.rp-range .btn {
  margin-bottom: 2px;
}

.rp-title {
  margin: 14px 0 8px;
}

.rp-title .muted {
  font-weight: 500;
  font-size: 0.9em;
}

.rp-early {
  margin-bottom: 12px;
}

.rp-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 10px;
  margin-bottom: 8px;
}

.rp-tile {
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px 14px;
}

.rp-label {
  font-family: var(--font-sign);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-2);
}

.rp-value {
  font-family: var(--font-sign);
  font-weight: 800;
  font-size: 2rem;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}

.rp-of {
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink-2);
}

.rp-sub {
  font-size: 0.85rem;
  color: var(--ink-2);
}

.rp-section {
  margin-top: 26px;
}

.rp-section h2 {
  margin-bottom: 2px;
}

.rp-section h3 {
  font-size: 1rem;
  margin: 8px 0 6px;
}

.rp-scroll {
  overflow-x: auto;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin-top: 8px;
}

.rp-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.rp-table th,
.rp-table td {
  padding: 8px 12px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--line);
}

.rp-table tbody tr:last-child > * {
  border-bottom: 0;
}

.rp-table thead th {
  font-family: var(--font-sign);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-2);
  white-space: nowrap;
  background: var(--surface-2);
}

.rp-table tbody th {
  font-weight: 600;
}

.rp-table .n {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.rp-table .muted.small {
  display: block;
  font-weight: 400;
  margin-top: 2px;
}

.rp-car {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.rp-bar {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 140px;
}

.rp-bar-track {
  flex: 1;
  height: 8px;
  border-radius: 4px;
  background: var(--surface-2);
  box-shadow: inset 0 0 0 1px var(--line);
  overflow: hidden;
}

.rp-bar-fill {
  display: block;
  height: 100%;
  border-radius: 4px;
  background: var(--ink);
}

.rp-bar-num {
  min-width: 3ch;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.rp-two {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 6px 24px;
}

.rp-tally {
  list-style: none;
  margin: 0;
  padding: 0;
}

.rp-tally li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 6px 0;
  border-bottom: 1px solid var(--line);
}

.rp-tally strong {
  font-variant-numeric: tabular-nums;
}

.rp-details {
  margin-top: 10px;
}

.rp-details > summary {
  cursor: pointer;
  font-weight: 600;
}

.rp-heatmap {
  border-collapse: separate;
  border-spacing: 2px;
  padding: 8px;
  font-size: 0.75rem;
}

.rp-heatmap th {
  font-weight: 600;
  color: var(--ink-2);
  padding: 0 4px;
  text-align: left;
  white-space: nowrap;
}

.rp-heatmap thead th {
  text-align: center;
  font-weight: 500;
}

.rp-heat {
  width: 26px;
  min-width: 26px;
  height: 26px;
  text-align: center;
  border-radius: 4px;
  background: var(--surface-2);
  color: transparent;
  font-variant-numeric: tabular-nums;
}

.rp-heat.on {
  background: color-mix(in srgb, var(--ink) var(--heat), var(--surface));
}

.rp-heat.on:hover {
  color: var(--surface);
  outline: 2px solid var(--focus);
}

.rp-health th {
  width: 70%;
}

.rp-log td:first-child {
  white-space: nowrap;
}

.rp-change td {
  color: var(--ink-2);
}

@media print {
  .rp-scroll {
    overflow: visible;
    border: 0;
  }
  .rp-tile,
  .rp-section {
    break-inside: avoid;
  }
  .rp-bar-fill,
  .rp-heat.on {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  .rp-details:not([open]) {
    display: none;
  }
}

/* ---------- document viewer ---------- */

.doc-viewer {
  width: 100vw;
  max-width: none;
  height: 100dvh;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: #0b1014;
  color: #fff;
}
.doc-viewer[open] {
  display: flex;
  flex-direction: column;
}
.doc-viewer::backdrop {
  background: #0b1014;
}
.dv-open,
.dv-open body {
  overflow: hidden;
}
.dv-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: max(10px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) 10px max(16px, env(safe-area-inset-left));
  background: #0b1014;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}
.dv-title {
  flex: 1;
  min-width: 0;
  margin: 0;
  font-size: 1.05rem;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.dv-close {
  min-height: 44px;
  padding: 8px 20px;
  border: 0;
  border-radius: 999px;
  background: var(--sign);
  color: var(--sign-ink);
  font: inherit;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
}
.dv-close:focus-visible {
  outline: 3px solid #fff;
  outline-offset: 2px;
}
.dv-body {
  flex: 1;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 12px max(12px, env(safe-area-inset-bottom));
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}
.dv-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  cursor: zoom-in;
}
.dv-body.dv-zoom {
  display: block;
}
.dv-body.dv-zoom .dv-img {
  max-width: none;
  max-height: none;
  width: 200%;
  cursor: zoom-out;
}
.dv-pdf {
  width: 100%;
  height: 100%;
  border: 0;
  background: #fff;
  border-radius: var(--radius-sm);
}

/* ---------- board: location on every car ---------- */

.site-foot {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 22px;
}
.site-foot a {
  color: var(--ink-2);
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.board {
  padding-top: 16px;
}

.loc-cards {
  display: grid;
  gap: 12px;
}

.loc-card {
  display: block;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  color: var(--ink);
  text-decoration: none;
}
.loc-card:hover {
  border-color: var(--ink-2);
}
.loc-card:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.lc-where {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 14px 9px;
  background: var(--sign-tint);
  border-bottom: 1px solid var(--line);
  font-family: var(--font-sign);
  font-weight: 800;
  font-size: 1.5rem;
  line-height: 1.1;
}
.pin {
  flex: none;
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.lc-body {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
}
.lc-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}
.lc-name {
  font-weight: 600;
  font-size: 1.08rem;
  line-height: 1.25;
}
.lc-id {
  font-weight: 500;
  font-size: 0.88rem;
  color: var(--ink-2);
}
.lc-reason {
  font-weight: 600;
  font-size: 0.92rem;
}
.lc-yellow {
  color: var(--amber-text);
}
.lc-red {
  color: var(--red-text);
}
.lc-meta {
  font-size: 0.92rem;
  color: var(--ink-2);
}
.lc-main .tag {
  margin-top: 4px;
}
.chev-r {
  flex: none;
  width: 18px;
  height: 18px;
  fill: none;
  stroke: var(--ink-2);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* The status border around a car's photo or placard. */
.ring {
  flex: none;
  display: inline-flex;
  padding: 3px;
  border: 3px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
}
.ring-green {
  border-color: var(--green);
}
.ring-yellow {
  border-color: var(--amber);
}
.ring-red {
  border-color: var(--red);
}
.ring .car-thumb {
  border: 0;
  border-radius: 7px;
}
.ring .placard {
  min-width: 76px;
  height: 56px;
}

.empty-lines {
  margin-top: 12px;
  display: grid;
  gap: 8px;
}
.empty-line {
  margin: 0;
  padding: 12px 14px;
  border: 1.5px dashed var(--line-strong, #b4bcb9);
  border-radius: 12px;
  color: var(--ink-2);
}
.empty-line strong {
  color: var(--ink);
}

.in-use {
  margin-top: 26px;
}
.in-use h2 {
  font-size: 1.3rem;
  margin: 0 0 10px;
}

.missed-link {
  text-align: center;
  margin: 26px 0 0;
}
.missed-link .link-btn {
  color: var(--ink);
  font-weight: 600;
}

.loc-move {
  display: inline-flex;
  gap: 2px;
}
.loc-move .btn {
  min-width: 36px;
  padding-inline: 6px;
}

/* ---------- car page: status border, report button, modals ---------- */

.ring-photo {
  box-sizing: border-box;
  border: 4px solid var(--line);
}
.ring-photo-green {
  border-color: var(--green);
}
.ring-photo-yellow {
  border-color: var(--amber);
}
.ring-photo-red {
  border-color: var(--red);
}
.ring-xl {
  border-radius: 14px;
}
.ring-xl .placard {
  min-width: 96px;
  height: 96px;
}

.id-sign {
  display: inline-flex;
  cursor: default;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}
.id-sign .placard {
  border-radius: 4px;
  height: 30px;
  padding: 0 10px;
}

.report-btn {
  margin: 0 0 16px;
}

.brief-red {
  border-left-color: var(--red);
}

.modal-btns {
  margin-top: 14px;
}
.btn-danger-solid {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
}

/* ---------- Easter eggs ---------- */

.egg-spin {
  animation: egg-spin 1.6s cubic-bezier(0.2, 0.7, 0.3, 1.15);
}
@keyframes egg-spin {
  0% {
    transform: perspective(300px) rotateY(0);
  }
  70% {
    transform: perspective(300px) rotateY(740deg);
  }
  85% {
    transform: perspective(300px) rotateY(705deg);
  }
  100% {
    transform: perspective(300px) rotateY(720deg);
  }
}

.egg-quip {
  display: block;
  font-style: italic;
  font-size: 0.9rem;
  color: var(--ink-2);
  min-height: 0;
}
.egg-quip:empty {
  display: none;
}

.egg-late {
  font-style: italic;
  color: var(--ink-2);
}

.egg-party {
  position: fixed;
  inset: 0;
  z-index: 1000;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: rgba(10, 15, 20, 0.35);
  animation: egg-fade 3.2s ease forwards;
}
.egg-party i {
  position: absolute;
  top: -12px;
  width: 9px;
  height: 14px;
  border-radius: 2px;
  animation-name: egg-fall;
  animation-timing-function: cubic-bezier(0.3, 0.6, 0.6, 1);
  animation-fill-mode: forwards;
}
@keyframes egg-fall {
  to {
    transform: translateY(105vh) rotate(calc(var(--spin) * 720deg));
  }
}
@keyframes egg-fade {
  0%,
  80% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}
.egg-card {
  display: grid;
  gap: 6px;
  text-align: center;
  padding: 22px 26px;
  max-width: 300px;
  background: #17212b;
  color: #fff;
  border: 3px solid var(--sign);
  border-radius: 14px;
  animation: egg-pop 0.4s cubic-bezier(0.2, 0.8, 0.3, 1.3);
}
.egg-card strong {
  font-family: var(--font-sign);
  font-size: 1.7rem;
  color: var(--sign);
}
.egg-small {
  font-size: 0.9rem;
  color: #c4ced4;
}
@keyframes egg-pop {
  from {
    transform: scale(0.6);
    opacity: 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  .egg-card {
    animation: none;
  }
}
.site-foot,
.site-foot .link-btn {
  font-size: 0.95rem;
}

/* ---------- admin accounts ---------- */

.admin-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}
.link-card {
  border: 2px solid var(--focus);
}
.link-card h2 {
  margin-top: 0;
}
.link-row {
  display: flex;
  gap: 8px;
}
.link-row input {
  flex: 1;
  min-width: 0;
  font-size: 0.9rem;
}
.site-foot[hidden],
.site-foot [hidden] {
  display: none;
}

/* One card per location, with a row per car. */
.lc-where {
  margin: 0;
}
.lc-row {
  display: block;
  color: var(--ink);
  text-decoration: none;
}
.lc-row + .lc-row {
  border-top: 1px solid var(--line);
}
.lc-row:hover {
  background: var(--surface-2);
}
.lc-row:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: -3px;
}
.loc-card:hover {
  border-color: var(--line);
}

.expires-form {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 8px 10px;
}
.expires-form .field {
  margin: 0;
}
.expires-form p {
  flex-basis: 100%;
  margin: 0;
}

.mi-foot {
  display: flex;
  justify-content: flex-end;
  margin-top: 8px;
}
.mi-delete {
  color: var(--red-text);
}

.pull-tip {
  position: fixed;
  top: calc(env(safe-area-inset-top, 0px) + 6px);
  left: 50%;
  z-index: 900;
  transform: translate(-50%, 0);
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink-2);
  border: 1px solid var(--line);
  font-size: 0.9rem;
  font-weight: 600;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s;
}
.pull-tip.show {
  opacity: 1;
}
.pull-tip.ready {
  color: var(--ink);
  border-color: var(--sign);
}

.delivery {
  border: 0;
  padding: 0;
  margin: 0 0 12px;
}
.delivery .check-inline {
  display: flex;
  margin: 6px 0;
}

/* ---------- roles ---------- */

.role-key {
  margin: 4px 0 12px;
  padding-left: 18px;
}
.role-key li {
  margin: 2px 0;
}
.tag.role-admin {
  background: var(--sign);
  color: #000;
}
.tag.role-manager {
  background: var(--green-bg);
}
.role-pick select {
  min-height: 36px;
  padding: 4px 8px;
}
.admin [hidden] {
  display: none !important;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.no-miles {
  margin: -6px 0 14px;
}
.no-miles-link {
  font-size: 0.85rem;
  min-height: 32px;
  padding: 4px 0;
}
.no-miles-box {
  margin-top: 6px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--amber-bg);
  font-size: 0.92rem;
}
.no-miles-box p {
  margin: 0 0 8px;
}
