/* ---------- Simona Pro (from Ariel's Focus assets) ---------- */
@font-face { font-family: "Simona"; src: url("/fonts/SimonaPro-Regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Simona"; src: url("/fonts/SimonaPro-Medium.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Simona"; src: url("/fonts/SimonaPro-Bold.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Simona"; src: url("/fonts/SimonaPro-Black.woff2") format("woff2"); font-weight: 900; font-style: normal; font-display: swap; }

/* ---------- Tokens ----------
   Colors: Focus palette (src/app/globals.css in Focus) turned into a dark theme.
   Focus "ink" #070533 becomes the ground, the lavender scale becomes text and lines,
   focus-500 #667aff stays the accent, status colors come from Focus priority stars.
   Type: Focus scale — h1 29/35, h2 23/28, body 19/23, small 15/18; weights 900 / 700 / 400.
   Display sizes continue the same ~1.25 step upward (36, 45, 56, 70, 88). */
:root {
  color-scheme: dark;

  --bg: #06052a;            /* Focus ink, a step deeper */
  --bg-2: #070533;          /* Focus ink */
  --surface: #0f0d45;
  --surface-2: #17155a;
  --line: rgb(195 200 235 / 0.14);   /* focus-300 */
  --line-strong: rgb(195 200 235 / 0.28);
  --text: #fbfbfb;          /* focus-000 */
  --text-2: #c3c8eb;        /* focus-300 */
  --text-3: #9e9ba7;        /* focus-off */
  --accent: #667aff;        /* focus-500 */
  --accent-soft: #a2acef;   /* focus-400 */
  --accent-ink: #ffffff;
  --ok: #3fbf8f;
  --warn: #f2b134;
  --bad: #ef5d7a;
  --violet: #a86bf0;

  --fs-small: 15px; --lh-small: 18px;
  --fs-body: 19px;  --lh-body: 23px;
  --fs-h2: 23px;    --lh-h2: 28px;
  --fs-h1: 29px;    --lh-h1: 35px;
  --fs-d1: 36px; --fs-d2: 45px; --fs-d3: 56px; --fs-d4: 70px; --fs-d5: 88px;

  --radius: 20px;           /* Focus radius-card */
  --shadow: 6px 6px 28px 0 rgb(0 0 0 / 0.35);
  --gutter: clamp(16px, 5vw, 64px);
  --ease: cubic-bezier(.2, .7, .2, 1);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--bg); }
body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(900px 600px at 12% -10%, rgb(102 122 255 / 0.22), transparent 60%),
    radial-gradient(700px 500px at 100% 30%, rgb(168 107 240 / 0.10), transparent 60%),
    var(--bg);
  color: var(--text);
  font-family: "Simona", system-ui, sans-serif;
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: clip;
}
::selection { background: var(--accent); color: var(--accent-ink); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.ltr { direction: ltr; unicode-bidi: isolate; }
:focus-visible { outline: 2px solid var(--accent-soft); outline-offset: 3px; border-radius: 6px; }

.skip {
  position: absolute; inset-inline-start: 16px; top: -60px; z-index: 10;
  background: var(--accent); color: var(--accent-ink); padding: 10px 16px; border-radius: 12px;
  font-weight: 700; text-decoration: none; transition: top .2s var(--ease);
}
.skip:focus { top: 12px; }

/* ---------- Header ---------- */
.top {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 24px var(--gutter);
  max-width: 1320px; margin: 0 auto;
}
.logo {
  font-size: var(--fs-h2); line-height: 1; font-weight: 400;
  color: var(--text); text-decoration: none;
}
.logo b { font-weight: 900; color: var(--accent-soft); }
.top-note {
  font-size: var(--fs-small); line-height: var(--lh-small); color: var(--text-2);
  border: 1px solid var(--line); border-radius: 99px; padding: 6px 14px 7px;
}

main { padding: 0 var(--gutter); max-width: 1320px; margin: 0 auto; }

/* ---------- Hero ---------- */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(24px, 4vw, 64px);
  padding: clamp(40px, 8vw, 104px) 0 clamp(40px, 6vw, 72px);
}
.dict {
  display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap;
  justify-content: flex-end;
  margin: 0 0 28px;
  font-size: var(--fs-body); line-height: var(--lh-body); color: var(--text-3);
}
.dict b { color: var(--text); font-weight: 900; font-size: var(--fs-h1); }
.dict i { font-style: normal; letter-spacing: 0.02em; }
.dict em {
  font-style: normal; font-size: var(--fs-small); line-height: var(--lh-small); font-weight: 700;
  color: var(--accent-soft); border: 1px solid rgb(162 172 239 / 0.4); border-radius: 99px; padding: 3px 11px 4px;
}
h1 {
  font-weight: 900;
  font-size: clamp(var(--fs-d2), 7.2vw, var(--fs-d5));
  line-height: 1.04;
  letter-spacing: -0.015em;
  margin: 0 0 28px;
  text-wrap: balance;
}
h1 span {
  display: inline-block;
  background: linear-gradient(100deg, var(--accent-soft), var(--accent) 55%, var(--violet));
  -webkit-background-clip: text; background-clip: text; color: transparent;
  padding-bottom: 0.06em;
}
.lead {
  max-width: 34ch;
  font-size: var(--fs-h2); line-height: var(--lh-h2); font-weight: 400;
  color: var(--text-2);
  margin: 0 0 40px;
}

/* scan form */
.scan {
  display: flex; align-items: center; gap: 8px;
  max-width: 640px;
  background: var(--surface);
  border-radius: 999px;
  padding: 8px;
  box-shadow: inset 0 0 0 1px var(--line-strong), 0 20px 60px -20px rgb(102 122 255 / 0.45);
  transition: box-shadow .25s var(--ease);
}
.scan:focus-within { box-shadow: inset 0 0 0 2px var(--accent), 0 20px 70px -16px rgb(102 122 255 / 0.65); }
.scan-prefix {
  order: 2; /* sits just left of the LTR input text, before the button */
  color: var(--text-3); font-size: var(--fs-body); padding-inline-start: 0; padding-inline-end: 6px;
  user-select: none;
}
.scan input {
  order: 1;
  flex: 1; min-width: 0;
  border: 0; background: transparent; color: var(--text);
  font: 700 var(--fs-body)/var(--lh-body) "Simona", system-ui, sans-serif;
  padding: 14px 18px 14px 0; outline: none; text-align: left;
}
.scan:has(input:not(:placeholder-shown)) .scan-prefix { display: none; }
.scan input::placeholder { color: var(--text-3); font-weight: 400; opacity: 1; }
.scan button {
  order: 3;
  display: inline-flex; align-items: center; gap: 10px;
  border: 0; border-radius: 999px;
  background: var(--accent); color: var(--accent-ink);
  font: 700 var(--fs-body)/var(--lh-body) "Simona", system-ui, sans-serif;
  padding: 14px 24px 15px 20px;
  cursor: pointer; white-space: nowrap;
  transition: background-color .2s ease, transform .2s var(--ease);
}
.scan button svg { transition: transform .2s var(--ease); }
.scan button:hover { background: #7a8bff; }
.scan button:hover svg { transform: translateX(-3px); }
.scan button:active { transform: scale(.97); }
.scan button:disabled { opacity: .55; cursor: progress; }
.hint {
  display: flex; align-items: center; gap: 10px;
  font-size: var(--fs-small); line-height: var(--lh-small); color: var(--text-3);
  margin: 18px 8px 0;
}
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 4px rgb(63 191 143 / 0.18); flex: none; }

/* radar visual */
.radar {
  position: relative; width: 100%; max-width: 460px; aspect-ratio: 1; justify-self: center;
}
.radar-ring {
  position: absolute; border-radius: 50%;
  border: 1px solid var(--line-strong);
}
.r1 { inset: 0; border-color: var(--line); }
.r2 { inset: 17%; }
.r3 { inset: 34%; border-color: rgb(162 172 239 / 0.45); background: radial-gradient(circle, rgb(102 122 255 / 0.18), transparent 70%); }
.radar::before, .radar::after {
  content: ""; position: absolute; background: var(--line);
}
.radar::before { inset: 50% 0 auto; height: 1px; }
.radar::after { inset: 0 auto 0 50%; width: 1px; }
.radar-sweep {
  position: absolute; inset: 0; border-radius: 50%;
  background: conic-gradient(from 0deg, rgb(162 172 239 / 0.5) 0deg, rgb(102 122 255 / 0.18) 30deg, rgb(102 122 255 / 0) 110deg, transparent 360deg);
  -webkit-mask: radial-gradient(circle, #000 69.5%, transparent 70%);
          mask: radial-gradient(circle, #000 69.5%, transparent 70%);
  animation: sweep 6s linear infinite;
}
.radar-core {
  position: absolute; inset: 50% auto auto 50%; transform: translate(-50%, -50%);
  font-weight: 900; font-size: clamp(var(--fs-h1), 4vw, var(--fs-d2)); line-height: 1;
  color: var(--text);
  text-shadow: 0 0 40px rgb(102 122 255 / 0.8);
}
.blip {
  position: absolute; width: 10px; height: 10px; border-radius: 50%;
  background: var(--accent-soft); box-shadow: 0 0 0 6px rgb(162 172 239 / 0.15), 0 0 18px var(--accent);
  animation: blip 6s ease-in-out infinite;
}
.b1 { top: 22%; left: 30%; animation-delay: -1s; }
.b2 { top: 62%; left: 80%; background: var(--ok); box-shadow: 0 0 0 6px rgb(63 191 143 / 0.15), 0 0 18px var(--ok); animation-delay: -3s; }
.b3 { top: 78%; left: 36%; background: var(--warn); box-shadow: 0 0 0 6px rgb(242 177 52 / 0.15), 0 0 18px var(--warn); animation-delay: -4.6s; }
@keyframes sweep { to { transform: rotate(360deg); } }
@keyframes blip { 0%, 100% { opacity: .35; transform: scale(.8); } 45% { opacity: 1; transform: scale(1); } }

/* three "without" chips */
.nots {
  list-style: none; margin: 0 0 clamp(56px, 8vw, 96px); padding: 0;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
.nots li {
  padding: 28px 0 30px; padding-inline-end: 16px;
  font-size: var(--fs-h1); line-height: var(--lh-h1); font-weight: 900;
}
.nots li + li { border-inline-start: 1px solid var(--line); padding-inline-start: clamp(16px, 3vw, 40px); }
.nots span { display: block; font-size: var(--fs-small); line-height: var(--lh-small); font-weight: 700; color: var(--accent-soft); margin-bottom: 6px; }
main:has(#result:not([hidden])) .nots,
main:has(#progress:not([hidden])) .nots { display: none; }

/* ---------- Progress ---------- */
.progress ol {
  list-style: none; padding: 0; margin: 0 0 56px;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px;
  counter-reset: step;
}
.progress li {
  counter-increment: step;
  position: relative;
  padding: 18px 20px 20px;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line);
  color: var(--text-3);
  font-size: var(--fs-small); line-height: var(--lh-small); font-weight: 700;
  overflow: hidden;
  transition: color .3s ease, box-shadow .3s ease;
}
.progress li::before {
  content: "0" counter(step);
  display: block; margin-bottom: 18px;
  font-size: var(--fs-h2); line-height: var(--lh-h2); font-weight: 900; color: var(--text-3);
}
.progress li::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 3px;
  background: var(--accent); transform: scaleX(0); transform-origin: right;
}
.progress li.on { color: var(--text); box-shadow: inset 0 0 0 1px rgb(102 122 255 / 0.6); }
.progress li.on::before { color: var(--accent-soft); }
.progress li.on::after { animation: fill 1.3s linear forwards; }
.progress li.done { color: var(--text-2); }
.progress li.done::before { color: var(--ok); content: "✓"; }
.progress li.done::after { transform: scaleX(1); background: var(--ok); }
@keyframes fill { to { transform: scaleX(.92); } }

/* ---------- Result ---------- */
.result { padding: 8px 0 96px; scroll-margin-top: 24px; }
.verdict {
  --tone: var(--ok);
  position: relative; overflow: hidden;
  border-radius: calc(var(--radius) + 8px);
  padding: clamp(28px, 5vw, 56px);
  background:
    radial-gradient(600px 300px at 0% 0%, color-mix(in srgb, var(--tone) 28%, transparent), transparent 70%),
    linear-gradient(160deg, var(--surface-2), var(--surface));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--tone) 45%, transparent), var(--shadow);
  margin-bottom: 16px;
}
.verdict.partial { --tone: var(--warn); }
.verdict.unsuitable { --tone: var(--accent); }
.verdict-head { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 22px; }
.verdict small { font-size: var(--fs-small); line-height: var(--lh-small); color: var(--text-2); }
.verdict h2 {
  font-size: clamp(var(--fs-d1), 5vw, var(--fs-d3)); line-height: 1.08; font-weight: 900;
  letter-spacing: -0.01em; margin: 0 0 18px; max-width: 18ch; text-wrap: balance;
}
.verdict p { margin: 0; color: var(--text-2); max-width: 56ch; font-size: var(--fs-body); line-height: 1.35; }
.pill {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--tone); color: var(--bg);
  font-size: var(--fs-small); line-height: var(--lh-small); font-weight: 700;
  border-radius: 99px; padding: 6px 14px 7px;
}
.pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.verdict.unsuitable .pill { color: var(--accent-ink); }

.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 16px; }
.grid > .card { grid-column: span 6; }
.grid > .card-speed { grid-column: span 5; }
.grid > .card-speed + .card { grid-column: span 7; }
.card {
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: inset 0 0 0 1px var(--line);
  padding: 26px 28px 28px;
  min-width: 0;
}
.card h3 {
  margin: 0 0 20px;
  font-size: var(--fs-h2); line-height: var(--lh-h2); font-weight: 900;
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
}
.tag {
  font-size: var(--fs-small); line-height: var(--lh-small); font-weight: 700;
  border-radius: 99px; padding: 4px 12px 5px; white-space: nowrap;
  background: color-mix(in srgb, currentColor 14%, transparent);
}
.tag.ok { color: var(--ok); } .tag.warn { color: var(--warn); } .tag.bad { color: var(--bad); } .tag.info { color: var(--accent-soft, #a2acef); }
.card dl {
  margin: 0; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 0 18px;
  font-size: var(--fs-small); line-height: var(--lh-small);
}
.card dt, .card dd { padding: 11px 0; border-top: 1px solid var(--line); }
.card dt { color: var(--text-3); }
.card dd { margin: 0; overflow-wrap: anywhere; font-weight: 700; text-align: left; }
.card dd.ltr { direction: ltr; unicode-bidi: isolate; }
.card-lead { margin: 0 0 14px; font-weight: 700; font-size: var(--fs-body); line-height: var(--lh-body); }
.card ul, .card ol { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; font-size: var(--fs-small); line-height: 1.4; color: var(--text-2); }
.notes li { position: relative; padding-inline-start: 18px; }
.notes li::before { content: ""; position: absolute; inset-inline-start: 0; top: .55em; width: 6px; height: 6px; border-radius: 50%; background: var(--accent-soft); }

.big { display: flex; align-items: baseline; gap: 8px; font-weight: 900; font-size: var(--fs-d4); line-height: 1; letter-spacing: -0.02em; }
.big small { font-size: var(--fs-body); font-weight: 700; color: var(--text-3); letter-spacing: 0; }
.big-label { margin: 10px 0 22px; font-size: var(--fs-small); line-height: var(--lh-small); color: var(--text-3); }

.wide, .grid > .wide { grid-column: 1 / -1; }
.todo h3 { justify-content: flex-start; }
.count {
  display: inline-grid; place-items: center; min-width: 30px; height: 30px; padding: 0 8px;
  border-radius: 99px; background: var(--accent); color: var(--accent-ink);
  font-size: var(--fs-small); font-weight: 700;
}
.todo ol { counter-reset: todo; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: 12px; }
.todo li {
  counter-increment: todo;
  position: relative;
  padding: 16px 18px 17px; padding-inline-start: 58px;
  border-radius: 14px; background: var(--bg-2); box-shadow: inset 0 0 0 1px var(--line);
  color: var(--text); font-size: var(--fs-small); line-height: 1.4;
}
.todo li::before {
  content: counter(todo, decimal-leading-zero);
  position: absolute; inset-inline-start: 18px; top: 15px;
  font-weight: 900; color: var(--warn);
}
.todo li.blk { box-shadow: inset 0 0 0 1px rgb(239 93 122 / 0.5); background: color-mix(in srgb, var(--bad) 9%, var(--bg-2)); }
.todo li.blk::before { color: var(--bad); }

/* CTA + quote */
.cta {
  margin-top: 16px;
  border-radius: calc(var(--radius) + 8px);
  padding: clamp(24px, 4vw, 40px);
  display: flex; gap: 24px; align-items: center; justify-content: space-between; flex-wrap: wrap;
  background: repeating-linear-gradient(-45deg, transparent 0 12px, rgb(195 200 235 / 0.03) 12px 13px), var(--bg-2);
  box-shadow: inset 0 0 0 1px var(--line-strong);
}
.cta strong { display: block; font-size: var(--fs-h1); line-height: var(--lh-h1); font-weight: 900; margin-bottom: 6px; }
.cta span { color: var(--text-2); }
.quote {
  background: radial-gradient(500px 260px at 100% 0%, rgb(102 122 255 / 0.35), transparent 70%), linear-gradient(160deg, var(--surface-2), var(--surface));
  box-shadow: inset 0 0 0 1px rgb(102 122 255 / 0.55), var(--shadow);
  align-items: flex-end;
}
.quote-text { flex: 1 1 300px; }
.quote-text span { display: block; font-size: var(--fs-body); line-height: 1.35; }
.quote-fields { display: flex; gap: 10px; flex-wrap: wrap; flex: 1 1 380px; }
.quote-fields input {
  flex: 1 1 140px; min-width: 0;
  border: 0; background: var(--bg); color: var(--text);
  box-shadow: inset 0 0 0 1px var(--line-strong);
  border-radius: 14px; padding: 15px 16px;
  font: 400 var(--fs-body)/var(--lh-body) "Simona", system-ui, sans-serif;
  outline: none; transition: box-shadow .2s ease;
}
.quote-fields input[dir="ltr"] { text-align: right; }
.quote-fields input::placeholder { color: var(--text-3); opacity: 1; }
.quote-fields input:focus { box-shadow: inset 0 0 0 2px var(--accent); }
.quote-fields button {
  flex: 1 1 100%;
  border: 0; border-radius: 14px; background: var(--accent); color: var(--accent-ink);
  font: 700 var(--fs-body)/var(--lh-body) "Simona", system-ui, sans-serif;
  padding: 15px 22px 16px; cursor: pointer;
  transition: background-color .2s ease, transform .2s var(--ease);
}
.quote-fields button:hover { background: #7a8bff; }
.quote-fields button:active { transform: scale(.98); }
.quote-fields button:disabled { opacity: .55; cursor: progress; }
.error {
  color: var(--bad); font-weight: 700; padding: 18px 22px; border-radius: 14px;
  background: color-mix(in srgb, var(--bad) 10%, transparent); box-shadow: inset 0 0 0 1px rgb(239 93 122 / 0.4);
  margin: 0 0 56px;
}

/* ---------- Footer ---------- */
.foot {
  display: flex; align-items: center; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap;
  max-width: 1320px; margin: 0 auto;
  padding: 32px var(--gutter) calc(32px + env(safe-area-inset-bottom));
  color: var(--text-3); font-size: var(--fs-small); line-height: var(--lh-small);
  border-top: 1px solid var(--line);
}
.logo-sm { font-size: var(--fs-body); }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; }
  .radar { position: absolute; inset-inline-start: -120px; top: -60px; width: 300px; opacity: .35; z-index: -1; pointer-events: none; }
  .radar-core { display: none; }
  .hero { position: relative; isolation: isolate; }
  .grid > .card, .grid > .card-speed, .grid > .card-speed + .card { grid-column: 1 / -1; }
  .progress ol { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .top { padding-top: 18px; padding-bottom: 18px; }
  .top-note { display: none; }
  .hero { padding-top: 28px; }
  .dict { justify-content: flex-end; margin-bottom: 20px; }
  .dict b { font-size: var(--fs-h2); }
  .lead { font-size: var(--fs-body); line-height: 1.3; margin-bottom: 28px; }
  .scan { flex-direction: column; align-items: stretch; border-radius: 24px; padding: 8px; }
  .scan-prefix { display: none; }
  .scan input { order: 1; text-align: center; padding: 14px 8px; }
  .scan button { order: 2; justify-content: center; padding: 15px 20px 16px; border-radius: 18px; }
  .hint { margin-inline: 4px; }
  .nots { grid-template-columns: 1fr; }
  .nots li { display: flex; align-items: baseline; gap: 10px; padding: 16px 0; font-size: var(--fs-h2); line-height: var(--lh-h2); }
  .nots li + li { border-inline-start: 0; border-top: 1px solid var(--line); padding-inline-start: 0; }
  .nots span { display: inline; margin: 0; }
  .card { padding: 22px 20px 22px; }
  .card h3 { font-size: var(--fs-body); line-height: var(--lh-body); }
  .big { font-size: var(--fs-d3); }
  .verdict h2 { font-size: var(--fs-d1); }
  .cta strong { font-size: var(--fs-h2); line-height: var(--lh-h2); }
  .progress ol { grid-template-columns: 1fr; gap: 8px; }
  .progress li { display: flex; align-items: center; gap: 14px; padding: 14px 18px; }
  .progress li::before { margin: 0; font-size: var(--fs-body); min-width: 24px; }
  .foot { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .progress li.on::after { transform: scaleX(.5); }
}
