/* Reality Mirror — standalone.
   The RedAssistance "Sobru" design, in one file: a grey ground, a floating
   header bar, white cards with hairline borders and no shadows, small
   regular-weight headlines, red as the only accent. Nothing here is shared
   with the site's React build; the folder stands on its own. */

@font-face {
  font-family: 'Geist';
  font-style: normal;
  font-weight: 300 600;
  font-display: swap;
  src: url('geist-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Geist';
  font-style: normal;
  font-weight: 300 600;
  font-display: swap;
  src: url('geist-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --ground: #ECECEC;
  --bar: #EFEFEF;
  --card: #FFFFFF;
  --well: #E4E4E4;
  --ink: #000000;
  --muted: rgba(0, 0, 0, .55);
  --subtle: rgba(0, 0, 0, .45);
  --faint: rgba(0, 0, 0, .35);
  --line: rgba(0, 0, 0, .08);
  --line-2: rgba(0, 0, 0, .12);
  --accent: #DB252D;
  --accent-700: #B81720;
  --accent-tint: rgba(219, 37, 45, .055);
  --accent-line: rgba(219, 37, 45, .32);
  --ok: #059669;
  --font: 'Geist', -apple-system, 'Helvetica Neue', Arial, sans-serif;
  --r-sm: 8px;
  --r: 12px;
  --r-lg: 16px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--font);
  font-size: 14.5px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
h1, h2, h3, h4 { margin: 0; font-weight: 400; letter-spacing: -.025em; line-height: 1.14; }
p { margin: 0; }
img { display: block; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 12px; top: 12px; z-index: 90; background: var(--card); padding: 10px 14px; border-radius: var(--r-sm); }

.wrap { max-width: 1024px; margin: 0 auto; padding-inline: 24px; }
@media (max-width: 560px) { .wrap { padding-inline: 16px; } }

/* ---------- header and footer ---------- */
.hdwrap { padding: 8px 8px 0; position: sticky; top: 0; z-index: 60; }
.hd {
  max-width: 1400px; margin: 0 auto; background: var(--bar); border-radius: var(--r-lg); height: 64px;
  display: flex; align-items: center; gap: 24px; padding: 0 20px;
}
.hd .logo img { height: 44px; width: auto; }
.hd-note { margin-left: auto; font-size: 11.5px; letter-spacing: .08em; color: var(--subtle); }
@media (max-width: 720px) { .hd-note { display: none; } }

.ft { background: var(--bar); margin-top: 60px; padding: 22px 0; font-size: 12px; color: var(--subtle); }
.ft .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.ft a { text-decoration: none; }
.ft a:hover { color: var(--ink); }

/* ---------- page scaffolding ---------- */
.rm { padding: 44px 0 20px; }
.rm h1 { font-size: clamp(24px, 2.8vw, 34px); letter-spacing: -.028em; line-height: 1.16; max-width: 22ch; }
.accent { color: var(--accent); }
.sh { margin-bottom: 28px; }
.sh .eb { font-size: 12.5px; letter-spacing: .06em; color: var(--subtle); }
.sh h1 { margin-top: 8px; }
.sh p { margin-top: 12px; font-size: 14.5px; color: var(--muted); max-width: 64ch; }

.rm-progress { margin-bottom: 28px; }
.rm-progress .lbl { font-size: 12.5px; letter-spacing: .06em; color: var(--subtle); }
.rm-progress .bar { display: grid; grid-template-columns: repeat(4, 1fr); gap: 5px; margin-top: 9px; max-width: 420px; }
.rm-progress .bar span { height: 3px; border-radius: 2px; background: var(--line-2); }
.rm-progress .bar span.on { background: var(--accent); }

.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
@media (max-width: 860px) { .grid2 { grid-template-columns: 1fr; } }

.tile { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 20px 20px 18px; }
.tile h4 { font-size: 14px; font-weight: 500; }
.tile > p { margin-top: 9px; font-size: 13px; color: var(--muted); line-height: 1.5; }
.tile .n { font-size: 12.5px; color: var(--accent); margin-bottom: 9px; }
.tile .hint { margin-top: 12px; font-size: 12.5px; color: var(--subtle); }
.wide { margin-top: 18px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px; font-family: var(--font);
  font-weight: 500; font-size: 13.5px; text-decoration: none; border: 0; cursor: pointer;
  padding: 10px 17px; border-radius: var(--r-sm); transition: background .14s, border-color .14s;
}
.btn-a { background: var(--accent); color: #fff; }
.btn-a:hover { background: var(--accent-700); }
.btn-g { background: transparent; color: var(--ink); border: 1px solid var(--line-2); }
.btn-g:hover { border-color: rgba(0, 0, 0, .28); background: rgba(0, 0, 0, .02); }
.btn[disabled] { opacity: .5; cursor: default; }
.actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 26px; }

/* ---------- fields ---------- */
.field { display: block; margin-top: 14px; }
.field .lbl { display: block; font-size: 13px; margin-bottom: 6px; }
.field input, .field select, .field textarea {
  display: block; width: 100%; font: inherit; font-size: 14px; color: var(--ink);
  background: #fff; border: 1px solid var(--line-2); border-radius: var(--r-sm); padding: 10px 12px;
}
.field textarea { resize: vertical; min-height: 78px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.field small { display: block; margin-top: 5px; font-size: 12.5px; color: var(--subtle); }
fieldset { border: 0; margin: 0; padding: 0; }
fieldset[disabled] { opacity: .45; }
legend { font-size: 14px; font-weight: 500; padding: 0; margin-bottom: 10px; }

.checkline { display: grid; grid-template-columns: 18px 1fr; gap: 10px; align-items: start; margin-top: 16px; font-size: 13px; color: var(--muted); cursor: pointer; }
.checkline input { margin: 2px 0 0; accent-color: var(--accent); width: 16px; height: 16px; }

.choices { display: grid; gap: 7px; }
.choice { display: grid; grid-template-columns: 18px 1fr; gap: 10px; align-items: start; padding: 11px 13px; border: 1px solid var(--line); border-radius: var(--r-sm); font-size: 13.5px; cursor: pointer; }
.choice:hover { border-color: var(--line-2); }
.choice input { margin: 1px 0 0; accent-color: var(--accent); width: 16px; height: 16px; }
.choice.on { border-color: var(--accent-line); background: var(--accent-tint); }

/* ---------- the numbers ---------- */
.metric { margin-top: 16px; }
.metric .cap { display: block; font-size: 12.5px; color: var(--subtle); }
.metric .val { display: block; margin-top: 4px; font-size: 30px; letter-spacing: -.03em; line-height: 1.1; }
.metric .val small { font-size: 14px; color: var(--muted); letter-spacing: 0; }
.metric.hot .val { color: var(--accent); }
.row { display: flex; justify-content: space-between; align-items: baseline; gap: 14px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; color: var(--muted); }
.row:last-of-type { border-bottom: 0; }
.row strong { font-weight: 500; color: var(--ink); text-align: right; }

.rm-note { display: block; margin-top: 14px; padding: 11px 13px; background: var(--accent-tint); border-radius: var(--r-sm); font-size: 13px; color: var(--muted); }
.rm-note.plain { background: transparent; border: 1px solid var(--line); }
.good { margin-top: 14px; font-size: 13.5px; color: var(--ok); }
.err { margin-top: 16px; font-size: 13.5px; color: var(--accent); }

.answers { display: grid; grid-template-columns: 1fr 1fr; grid-auto-rows: 1fr; gap: 8px 16px; margin: 0; padding: 0; list-style: none; }
.answers li { display: grid; gap: 3px; align-content: start; padding: 12px 15px; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-sm); }
.answers .k { font-size: 12.5px; color: var(--subtle); }
.answers .v { font-size: 13.5px; }
@media (max-width: 760px) { .answers { grid-template-columns: 1fr; } }

.conds { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 1fr; gap: 8px 16px; margin: 0; padding: 0; list-style: none; }
.conds li { display: grid; grid-template-columns: 30px 1fr; gap: 10px; align-content: start; padding: 13px 15px; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-sm); font-size: 13.5px; }
.conds li b { font-weight: 400; font-size: 12px; color: var(--accent); }
@media (max-width: 960px) { .conds { grid-template-columns: 1fr 1fr; } }
@media (max-width: 620px) { .conds { grid-template-columns: 1fr; } }

.fn { display: grid; grid-template-columns: 30px 1fr; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.fn:last-child { border-bottom: 0; }
.fn b { font-weight: 400; font-size: 12.5px; color: var(--accent); }
.fn h4 { font-size: 14px; font-weight: 500; }
.fn p { margin-top: 5px; font-size: 13px; color: var(--muted); line-height: 1.5; }

details { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-sm); margin-top: 14px; }
details summary { list-style: none; cursor: pointer; padding: 12px 15px; font-size: 13.5px; display: flex; justify-content: space-between; align-items: center; gap: 14px; }
details summary::-webkit-details-marker { display: none; }
details summary::after { content: ""; width: 8px; height: 8px; border-right: 1.5px solid var(--faint); border-bottom: 1.5px solid var(--faint); transform: rotate(45deg); flex: none; margin-top: -4px; }
details[open] summary::after { transform: rotate(-135deg); margin-top: 2px; }
details .body { padding: 0 15px 14px; font-size: 13px; color: var(--muted); line-height: 1.6; }
details .body p + p { margin-top: 9px; }

.foot {
  display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap;
  margin-top: 44px; padding: 13px 16px; background: var(--card);
  border: 1px solid var(--line); border-radius: var(--r-sm); font-size: 12.5px; color: var(--subtle);
}
.foot button { background: none; border: 0; padding: 0; cursor: pointer; font: inherit; font-size: 12.5px; color: var(--accent); }
.foot button:hover { text-decoration: underline; }

/* ---------- the printed summary ---------- */
.print { display: none; }
.print h1 { font-size: 20px; font-weight: 500; }
.print .meta { margin-top: 4px; font-size: 12px; color: var(--subtle); }
.print section { margin-top: 20px; break-inside: avoid; }
.print h2 { font-size: 12px; font-weight: 500; letter-spacing: .07em; text-transform: uppercase; color: var(--subtle); padding-bottom: 5px; border-bottom: 1px solid var(--line); }
.print section > p { margin-top: 9px; font-size: 13px; line-height: 1.55; }
.print .note { color: var(--muted); font-style: italic; }
.print dl { margin: 9px 0 0; display: grid; gap: 5px; }
.print dl > div { display: grid; grid-template-columns: 210px 1fr; gap: 14px; align-items: baseline; break-inside: avoid; }
.print dt { font-size: 12px; color: var(--subtle); }
.print dd { margin: 0; font-size: 13px; line-height: 1.5; }

@media print {
  .hdwrap, .ft, .screen, .skip { display: none !important; }
  .rm { padding: 0; }
  .print { display: block; }
  .print, .print * { color: #000; }
  .print dt, .print .meta, .print h2, .print .note { color: #555; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation: none !important; transition: none !important; }
}
