/* Quiet, image-free interface. The existing functional stylesheet remains the base. */
:root {
  color-scheme: light;
  --ink: #fff;
  --ink-raised: #fff;
  --ink-line: #e5e5e7;
  --text: #1d1d1f;
  --text-dim: #6e6e73;
  --text-faint: #85858b;
  --male: #37678e;
  --female: #a65067;
  --signal: #1d1d1f;
  --warning: #94652d;
  --sans: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Yu Gothic", Meiryo, sans-serif;
  --serif: var(--sans);
  --roman: var(--sans);
  --mono: var(--sans);
}

html, body { background: #fff; font-family: var(--sans); }
.grid-bg { display: none; }
.topbar, main, footer { max-width: 1160px; }
:where(a, button, .button, summary):focus-visible,
#fileInput:focus-visible + .button { outline-color: #1d1d1f; outline-offset: 3px; }
a { color: var(--text); text-decoration-color: #b8b8bd; }
a:hover { text-decoration-color: currentColor; }

/* The masthead is deliberately typographic: no photograph, texture or effect. */
.topbar {
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: "mark status" "tag tag" "note note" "jump jump";
  gap: 0 16px;
  padding-top: 30px;
  padding-bottom: 86px;
  border-top: 0;
  border-bottom: 1px solid var(--ink-line);
  background: #fff;
}
.wordmark {
  align-items: center;
  gap: 10px;
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 650;
  line-height: 1.2;
  letter-spacing: -.035em;
}
.mark-dot { margin: 0 .12em; color: #8d8d92; }
.mark-version {
  padding-left: 10px;
  color: var(--text-faint);
  font-family: var(--sans);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0;
}
.status { align-self: center; color: var(--text-dim); font-size: 11px; }
.status-dot { background: #8b8b90; box-shadow: none; }
.topbar .tagline {
  grid-area: tag;
  margin: 108px 0 0;
  color: var(--text);
  font-family: var(--sans);
  font-size: clamp(48px, 6.3vw, 78px);
  font-weight: 650;
  line-height: 1.16;
  letter-spacing: -.06em;
}
.hero-overline {
  display: block;
  margin-bottom: 24px;
  color: var(--text-dim);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: 0;
}
.hero-overline i { font-family: inherit; font-style: normal; font-weight: inherit; }
.header-note {
  margin-top: 23px;
  color: var(--text-dim);
  font-size: 16px;
  line-height: 1.75;
}
.hero-jump {
  grid-area: jump;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  justify-self: start;
  gap: 32px;
  min-height: 48px;
  margin-top: 32px;
  padding: 0 23px;
  border-radius: 999px;
  background: var(--text);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: background .18s ease;
}
.hero-jump:hover { background: #444448; color: #fff; }
.hero-jump span { font-size: 18px; font-weight: 400; line-height: 1; }
.topbar.subpage { padding-bottom: 52px; }
.topbar.subpage .tagline {
  margin-top: 88px;
  font-size: clamp(29px, 4vw, 48px);
  line-height: 1.25;
  letter-spacing: -.045em;
}

/* Functional sections are ruled, not boxed. */
main { padding-top: 0; padding-bottom: 72px; }
.panel {
  border: 0;
  border-bottom: 1px solid var(--ink-line);
  border-radius: 0;
  background: transparent;
  padding: 34px 0 40px;
}
.panel h2 {
  color: var(--text);
  font-family: var(--sans);
  font-size: 22px;
  font-weight: 650;
  letter-spacing: -.035em;
  text-transform: none;
}
.hash, .intake h2::before, .conditions h2::before, .about h2::before { display: none; }
.collapsible { scroll-margin-top: 18px; }
.collapsible-head { min-height: 76px; padding: 22px 0 18px; }
.collapsible:not([open]) > .collapsible-head { padding-bottom: 22px; }
.collapsible-body { padding: 0 0 40px; }
.collapsible-hint { color: var(--text-faint); font-size: 11px; letter-spacing: 0; }
.chevron { border-color: var(--text-dim); }
.counter {
  padding: 5px 10px;
  border: 1px solid var(--ink-line);
  border-radius: 999px;
  background: #f5f5f7;
  color: var(--text-dim);
  font-family: var(--sans);
  font-size: 11px;
}
.counter[data-ready="true"] { border-color: var(--text); color: var(--text); }
.lede { max-width: 65ch; margin-bottom: 23px; color: var(--text-dim); font-size: 13px; line-height: 1.8; }

.slots { gap: 10px; margin-bottom: 22px; }
.slot, .slot[data-required="true"] {
  border: 1px solid #e5e5e7;
  border-radius: 10px;
  background: #f5f5f7;
}
.slot[data-filled="true"] { border-color: #b8b8bd; background: #fff; }
.slot[data-feedback="true"] { border: 2px solid var(--warning); }
.slot-index, .slot-tag { top: 11px; color: var(--text-faint); font-family: var(--sans); font-size: 10px; }
.slot-index { left: 11px; }
.slot-tag { right: 11px; }
.slot[data-required="true"] .slot-tag { color: var(--text-dim); }
.slot-caption { color: var(--text-faint); font-size: 11px; }
.slot[data-filled="true"] .slot-caption { background: rgba(29, 29, 31, .82); }
.slot-remove { border-radius: 50%; background: rgba(29, 29, 31, .86); }
.slot-feedback, .slot-progress { background: rgba(255, 255, 255, .95); }
.slot[data-stage] { border-color: var(--text); }
.slot-spinner { border-color: #d2d2d7; border-top-color: var(--text); }
.slot-progress-label { color: var(--text); }
.slot-progress-bar { background: #e5e5e7; }
.slot-progress-bar i { background: var(--text); }

.actions { gap: 10px; }
.button {
  min-height: 47px;
  padding-inline: 22px;
  border: 1px solid var(--ink-line);
  border-radius: 999px;
  background: #fff;
  color: var(--text);
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0;
}
.button.primary, .button.run { border-color: var(--text); background: var(--text); color: #fff; }
.button.ghost { border-color: transparent; color: var(--text-dim); }
.button.run:disabled { border-color: var(--ink-line); background: #f5f5f7; color: var(--text-faint); }
@media (hover: hover) and (pointer: fine) {
  .button.primary:hover, .button.run:hover:not(:disabled) { border-color: #444448; background: #444448; box-shadow: none; }
  .button.ghost:hover:not(:disabled) { border-color: var(--ink-line); color: var(--text); }
}
.hint { color: var(--text-dim); font-family: var(--sans); font-size: 12px; }
.consent { margin-top: 17px; color: var(--text-faint); font-size: 11px; }

.conditions-list { color: var(--text-dim); font-size: 12px; line-height: 1.75; }
.conditions-list li { padding-block: 13px; border-color: var(--ink-line); }
.conditions-list li::before { top: 14px; color: var(--text-faint); font-family: var(--sans); }
.conditions-list b { color: var(--text); font-weight: 600; }

/* Colour appears only when it carries a result or warning. */
.result { border-top: 1px solid var(--ink-line); }
.glyph, .verdict[data-label="male"] .glyph,
.verdict[data-label="female"] .glyph,
.verdict[data-label="unknown"] .glyph {
  width: 64px;
  height: 64px;
  border: 0;
  border-right: 1px solid var(--ink-line);
  border-radius: 0;
  box-shadow: none;
  text-shadow: none;
  font-family: var(--sans);
  font-size: 40px;
}
.verdict-label { font-family: var(--sans); font-size: clamp(26px, 4vw, 38px); font-weight: 650; letter-spacing: -.04em; }
.meter { height: 6px; border-radius: 999px; background: #e5e5e7; }
.meter span { box-shadow: none; }
.meter-note { font-family: var(--sans); font-size: 11px; }
.image-row { font-family: var(--sans); }
.image-row img { border-radius: 5px; }
.caveat b { color: var(--text); }

.about { padding-top: 48px; padding-bottom: 58px; }
.about h2 { margin-bottom: 24px; }
.about p { color: var(--text-dim); font-size: 13px; line-height: 1.9; }
.about .version-summary {
  padding: 0;
  border: 0;
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.85;
}
.about .about-link { font-family: var(--sans); font-size: 12px; }
.legal .panel { padding: 32px 0 40px; }
.legal h3 { font-family: var(--sans); font-size: 17px; font-weight: 650; }
.legal .route, .legal code { border-radius: 6px; background: #f5f5f7; }
.legal .route, .comparison-current, .comparison-note { border-left-color: var(--text); }
.comparison-good, .comparison-current > :first-child b { color: var(--text); }
footer { padding-top: 22px; color: var(--text-faint); font-family: var(--sans); font-size: 10px; }
footer a { color: var(--text-dim); }

@media (min-width: 700px) {
  :root { --gutter: 34px; }
  .topbar { padding-top: 34px; padding-bottom: 102px; }
  .topbar .tagline { margin-top: 128px; }
  .topbar.subpage .tagline { margin-top: 94px; }
  .slots { gap: 10px; }
  .slot[data-filled="false"] { aspect-ratio: 1; }
  .about { grid-template-columns: 220px minmax(0, 1fr); column-gap: 54px; }
}
@media (min-width: 900px) {
  main:not(.legal) { grid-template-columns: minmax(0, 1fr) 280px; column-gap: 60px; }
  .conditions { padding-left: 30px !important; }
}
@media (max-width: 699px) {
  :root { --gutter: 21px; }
  .topbar { padding-top: 24px; padding-bottom: 65px; }
  .wordmark { font-size: 13px; }
  .mark-version { font-size: 9px; }
  .status { font-size: 10px; }
  .topbar .tagline { margin-top: 81px; font-size: clamp(40px, 11vw, 52px); line-height: 1.21; }
  .hero-overline { margin-bottom: 20px; font-size: 12px; }
  .header-note { margin-top: 19px; font-size: 13px; }
  .hero-jump { margin-top: 26px; }
  .topbar.subpage { padding-bottom: 36px; }
  .topbar.subpage .tagline { margin-top: 67px; font-size: clamp(25px, 7vw, 34px); }
  .panel h2 { font-size: 20px; }
  .collapsible-body { padding-bottom: 32px; }
  .slot[data-filled="false"] { aspect-ratio: 1.25; }
  .about { padding-top: 38px; padding-bottom: 48px; }
}
