@font-face {
  font-family: "Jost*";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/jost-400-book.woff2") format("woff2");
}
@font-face {
  font-family: "Jost*";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/jost-500-medium.woff2") format("woff2");
}
@font-face {
  font-family: "Jost*";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/jost-600-semi.woff2") format("woff2");
}
@font-face {
  font-family: "Fraunces";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("/assets/fonts/Fraunces-VF-latin.woff2") format("woff2");
}

:root {
  color-scheme: dark;
  --bg: #0f1115;
  --surface: #14171e;
  --field: #0b0e13;
  --line: #1f2937;
  --line-2: #2b3340;
  --hair: rgba(255, 255, 255, 0.06);
  --text: #e5e7eb;
  --head: #f9fafb;
  --muted: #9ca3af;
  --soft: #6b7280;
  --accent: #93c5fd;
  --accent-deep: #5b8fd6;
  --ink: #0f1115;
  --warn: #d6a06e;
  --serif: "Fraunces", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --sans: "Jost*", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Consolas, monospace;
}

* {
  box-sizing: border-box;
  min-width: 0;
}

html {
  font-family: var(--sans);
  color: var(--text);
  line-height: 1.6;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(70rem 48rem at 92% -12%, rgba(147, 197, 253, 0.04), transparent 62%),
    var(--bg);
  background-attachment: fixed;
}

a {
  color: var(--accent);
  text-underline-offset: 0.18em;
}

.app {
  width: min(1080px, calc(100vw - 40px));
  margin: 0 auto;
  padding: 28px 0 80px;
}

/* ---------- Masthead ---------- */
.masthead {
  padding: 6px 0 22px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 28px;
}

.home-link {
  display: inline-block;
  margin-bottom: 16px;
  color: var(--soft);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  text-decoration: none;
}
.home-link::before { content: "← "; }
.home-link:hover,
.home-link:focus-visible { color: var(--accent); }

.eyebrow {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.masthead h1 {
  margin: 0;
  max-width: 22ch;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.7rem, 3.2vw, 2.5rem);
  line-height: 1.12;
  letter-spacing: -0.008em;
  color: var(--head);
  font-variation-settings: "opsz" 40, "SOFT" 0, "WONK" 0;
}
.masthead h1 em {
  font-style: italic;
  color: inherit;
}

.lede {
  max-width: 58ch;
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 0.98rem;
}

/* ---------- Calculator grid ---------- */
.calc {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(330px, 0.82fr);
  gap: 48px;
  align-items: start;
}

/* ---------- Inputs (open, hairline-separated) ---------- */
.inputs {
  display: grid;
  gap: 0;
}

.block {
  border: 0;
  margin: 0;
  padding: 30px 0;
  border-top: 1px solid var(--line);
  display: grid;
  gap: 20px;
}
.block:first-of-type {
  padding-top: 4px;
  border-top: 0;
}

.block > legend {
  padding: 0;
  margin: 0 0 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.7rem;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}
.block > legend .num {
  font-family: var(--mono);
  font-size: 0.82rem;
  letter-spacing: 0.05em;
  color: var(--accent);
}

.duo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.proc {
  display: grid;
  gap: 16px;
  align-content: start;
}

.field {
  display: grid;
  gap: 9px;
}
.field-wide { grid-column: 1 / -1; }

.lbl {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 500;
}

select,
input,
textarea {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line-2);
  border-radius: 10px;
  background: var(--field);
  color: var(--text);
  padding: 12px 14px;
  font: inherit;
}
textarea { min-height: 104px; resize: vertical; }

select:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(147, 197, 253, 0.18);
}

.proc-hours {
  margin: 0;
  color: var(--soft);
  font-size: 0.84rem;
  line-height: 1.5;
}

.roles {
  display: grid;
  gap: 10px;
}
.role-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 92px;
  align-items: center;
  gap: 12px;
}
.role-label {
  color: var(--text);
  font-size: 0.95rem;
}

.checks {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px 18px;
  margin: 0;
  display: grid;
  gap: 12px;
}
.checks-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  padding: 0;
  margin-bottom: 2px;
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 500;
}
.checks label {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  color: var(--muted);
  font-size: 0.95rem;
}
.checks input {
  width: 18px;
  min-height: 18px;
  margin-top: 3px;
  flex: 0 0 auto;
}

.help {
  display: inline-flex;
  width: 1.3rem;
  height: 1.3rem;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  background: transparent;
  color: var(--accent);
  font: 600 0.78rem/1 var(--sans);
  cursor: pointer;
}
.help:hover,
.help:focus-visible { border-color: var(--accent); }

.help-tip {
  flex-basis: 100%;
  width: 100%;
  margin-top: 8px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--field);
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: 0;
  text-transform: none;
}

/* ---------- Report ---------- */
.report {
  position: relative;
  align-self: start;
  border: 1px solid var(--line);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(147, 197, 253, 0.05), transparent 30%),
    var(--surface);
  padding: 30px 32px;
  box-shadow: 0 30px 80px -50px #000;
}

.report-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 18px;
  min-height: 340px;
  color: var(--soft);
}
.report-mark {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 3.4rem;
  line-height: 1;
  color: rgba(147, 197, 253, 0.28);
}
.report-empty p { margin: 0; font-size: 1rem; }

.report-body { display: none; }
.report.is-revealed .report-empty { display: none; }
.report.is-revealed .report-body { display: grid; }

.figure {
  padding: 22px 0;
  border-top: 1px solid var(--hair);
  display: grid;
  gap: 8px;
}
.figure:first-child { padding-top: 2px; border-top: 0; }

.cap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  color: var(--soft);
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.num-xl {
  font-family: var(--sans);
  font-weight: 600;
  font-size: clamp(2.2rem, 5vw, 3.1rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
  color: var(--head);
  font-variant-numeric: tabular-nums lining-nums;
}
.num-l {
  font-family: var(--sans);
  font-weight: 600;
  font-size: clamp(1.7rem, 3.6vw, 2.2rem);
  line-height: 1.05;
  letter-spacing: -0.015em;
  color: var(--head);
  font-variant-numeric: tabular-nums lining-nums;
}
.accent { color: var(--accent); }

.range-bar {
  position: relative;
  height: 8px;
  margin: 12px 0 10px;
  border-radius: 999px;
  background: var(--field);
  border: 1px solid var(--line-2);
}
.range-band {
  position: absolute;
  top: -1px;
  bottom: -1px;
  left: 0;
  width: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(147, 197, 253, 0.45), var(--accent));
}
.range-dot {
  position: absolute;
  top: 50%;
  left: 0;
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: var(--head);
  border: 2px solid var(--ink);
  transform: translate(-50%, -50%);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
}

.split {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.5rem;
  color: var(--muted);
  font-size: 0.9rem;
}
.split em { font-style: normal; color: var(--soft); }
.split b { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; }
.split .dot { color: var(--soft); }

.figure-offer .offer-line {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin: 0;
}
.offer-unit { color: var(--muted); font-size: 0.92rem; }

.rate-toggle {
  display: inline-flex;
  width: fit-content;
  margin-top: 4px;
  padding: 3px;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  gap: 2px;
}
.rate-toggle button {
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 7px 15px;
  border-radius: 999px;
  font: 500 0.85rem var(--sans);
  cursor: pointer;
  transition: color 160ms ease, background 160ms ease;
}
.rate-toggle button[aria-pressed="true"] {
  background: var(--accent);
  color: var(--ink);
  font-weight: 600;
}

.offer-text { margin: 4px 0 0; color: var(--muted); font-size: 0.9rem; line-height: 1.5; }
.risk-line { margin: 6px 0 0; color: var(--muted); font-size: 0.88rem; line-height: 1.5; }
.risk-line b { color: var(--text); font-weight: 600; }

/* ---------- Contact ---------- */
.contact {
  display: grid;
  grid-template-columns: 1fr;
  gap: 44px;
  margin-top: 8px;
  padding-top: 44px;
  border-top: 1px solid var(--line);
}
.contact-intro { max-width: 560px; }
.contact h2 {
  margin: 0 0 8px;
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  color: var(--head);
}
.muted { color: var(--muted); margin: 0; }

.direct-contact { display: grid; gap: 10px; margin-top: 20px; }
.contact-line {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 10px 9px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--field);
}
.contact-value {
  flex: 1 1 auto;
  font-family: var(--mono);
  font-size: 0.95rem;
  color: var(--text);
  overflow-wrap: anywhere;
}
.mini-action {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid var(--line-2);
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: color 160ms ease, border-color 160ms ease;
}
.mini-action:hover,
.mini-action:focus-visible { color: var(--accent); border-color: rgba(147, 197, 253, 0.55); }
.mini-action svg { width: 17px; height: 17px; display: block; }
.copy-data {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  width: fit-content;
  margin-top: 14px;
  padding: 11px 18px;
  border: 1px solid var(--line-2);
  border-radius: 10px;
  background: var(--field);
  color: var(--text);
  font: 600 0.95rem var(--sans);
  cursor: pointer;
  transition: color 160ms ease, border-color 160ms ease;
}
.copy-data:hover,
.copy-data:focus-visible { color: var(--accent); border-color: rgba(147, 197, 253, 0.55); }
.copy-data svg { width: 17px; height: 17px; flex: 0 0 auto; }
.copy-hint { margin: 8px 0 0; color: var(--soft); font-size: 0.86rem; line-height: 1.5; max-width: 48ch; }
.copy-status { min-height: 1.1em; margin: 4px 0 0; color: var(--accent); font-size: 0.84rem; }

.contact-form { display: grid; gap: 16px; align-content: start; }
.send-values {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.45;
}
.send-values input { width: 18px; min-height: 18px; margin-top: 2px; flex: 0 0 auto; }
.actions { display: flex; }
.contact-form .actions button {
  min-height: 48px;
  padding: 12px 24px;
  border: 0;
  border-radius: 10px;
  background: var(--accent);
  color: var(--ink);
  font: 600 1rem var(--sans);
  cursor: pointer;
  transition: filter 160ms ease;
}
.contact-form .actions button:hover { filter: brightness(1.06); }
.mail-note { margin: 0; color: var(--soft); font-size: 0.86rem; line-height: 1.5; }

/* ---------- Motion ---------- */
@keyframes riseIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}
.report.is-revealed .figure { animation: riseIn 0.5s ease both; }
.report.is-revealed .figure:nth-child(2) { animation-delay: 0.07s; }
.report.is-revealed .figure:nth-child(3) { animation-delay: 0.14s; }
.report.is-revealed .figure:nth-child(4) { animation-delay: 0.21s; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .calc { grid-template-columns: 1fr; gap: 32px; }
  .contact { grid-template-columns: 1fr; gap: 28px; }
}

@media (max-width: 560px) {
  .app { width: calc(100vw - 28px); padding-top: 18px; }
  .duo { grid-template-columns: 1fr; }
  .role-row { grid-template-columns: minmax(0, 1fr) 80px; }
  .report { padding: 24px 22px; }
}

@media (prefers-reduced-motion: reduce) {
  .report.is-revealed .figure { animation: none; }
  .rate-toggle button,
  .mini-action,
  .contact-form .actions button { transition: none; }
}
