/* E-48 near-miss one-tap. tokens.css rule 1: NO PER-SCREEN COLOUR - this
   file names tokens only. Rule 2: colour never carries meaning alone - a
   chosen kind is inverted fill AND heavier weight AND aria-pressed.
   Targets: --tap is the floor for anything tappable, --tap-primary for the
   one primary action per screen. Wet gloves, 6 AM. */

/* The hidden attribute wins over every display rule below (the DVIR lesson,
   2026-09-25): a hidden control must never quietly appear. */
[hidden] { display: none !important; }

* { box-sizing: border-box; }

body {
  margin: 0;
  padding: var(--sp-2);
  background: var(--c-bg);
  color: var(--c-text);
  font: var(--fw-body) var(--fs-body)/var(--lh-body) var(--font-ui);
}

h1 {
  font-size: var(--fs-head);
  font-weight: var(--fw-head);
  line-height: var(--lh-tight);
  margin: 0 0 var(--sp-2) 0;
  padding-bottom: var(--sp-1);
  border-bottom: var(--bw-rule) solid var(--c-rule);
}

h2, .label {
  font-size: var(--fs-label);
  font-weight: var(--fw-label);
  text-transform: uppercase;
  letter-spacing: var(--ls-caps);
  color: var(--c-text-2);
  margin: var(--sp-3) 0 var(--sp-1) 0;
}

p { margin: 0 0 var(--sp-1) 0; }
.muted { color: var(--c-text-2); }
.big { font-size: var(--fs-head); font-weight: var(--fw-label); }

button,
a.primary {
  display: block;
  width: 100%;
  min-height: var(--tap);
  margin-bottom: var(--tap-gap);
  padding: 12px;
  font-family: var(--font-ui);
  font-size: var(--fs-label);
  font-weight: var(--fw-label);
  text-align: center;
  text-decoration: none;
  border: var(--bw) solid var(--c-border);
  border-radius: var(--radius);
  background: var(--c-bg);
  color: var(--c-text);
}

button.primary,
a.primary {
  min-height: var(--tap-primary);
  border-color: var(--c-accent);
  background: var(--c-accent);
  color: var(--c-on-accent);
  font-weight: var(--fw-head);
}

.choices { margin-bottom: var(--sp-2); }

button.chosen {
  background: var(--c-text);
  color: var(--c-bg);
  border-color: var(--c-text);
  font-weight: var(--fw-head);
}

/* The language pair sits side by side; each is still a full-height target. */
.lang { display: flex; gap: var(--tap-gap); }
.lang button { flex: 1 1 0; }

input, textarea, select {
  display: block;
  width: 100%;
  min-height: var(--tap);
  margin-bottom: var(--sp-2);
  padding: 12px;
  font-family: var(--font-ui);
  font-size: var(--fs-body);
  font-weight: var(--fw-label);
  border: var(--bw) solid var(--c-border);
  border-radius: var(--radius);
  background: var(--c-bg);
  color: var(--c-text);
}

textarea { min-height: calc(var(--tap) * 2); }

label {
  display: block;
  margin-bottom: var(--sp-1);
  font-size: var(--fs-label);
  font-weight: var(--fw-label);
  color: var(--c-text-2);
}

/* A picked witness: his name and B-number on the left, Take off on the
   right - still a full-height target. */
.witness {
  display: flex;
  align-items: center;
  gap: var(--tap-gap);
  margin-bottom: var(--tap-gap);
}
.witness span { flex: 1 1 auto; font-weight: var(--fw-label); }
.witness button { flex: 0 0 auto; width: auto; margin: 0; }

img.photo {
  display: block;
  max-width: 100%;
  margin-bottom: var(--sp-2);
  border: var(--bw) solid var(--c-border);
  border-radius: var(--radius);
}

.alert,
.banner {
  padding: var(--sp-1);
  margin-bottom: var(--sp-2);
  background: var(--c-alert-bg);
  color: var(--c-alert-text);
  font-weight: var(--fw-label);
  border-radius: var(--radius);
}

/* One report on the office list: boxed, never coloured. */
section.report {
  margin-bottom: var(--sp-3);
  padding-bottom: var(--sp-2);
  border-bottom: var(--bw-rule) solid var(--c-rule);
}
section.report .what { font-size: var(--fs-body); font-weight: var(--fw-label); }
section.report .correction { border-left: 8px solid var(--c-border); padding-left: var(--sp-1); }

:focus-visible {
  outline: var(--bw-focus) solid var(--c-accent);
  outline-offset: 2px;
}

button.home {
  min-height: var(--tap);
  font-weight: var(--fw-body);
  color: var(--c-text-2);
}
