@import url('https://fonts.googleapis.com/css2?family=Domine:wght@500;600;700&family=Rubik:wght@400;500;600;700&display=swap');

/* ╔══════════════════════════════════════════════════════════╗
   ║  OCHOMANOS · TRIAGE NORMATIVO                              ║
   ║  Lead magnet · autodiagnóstico de riesgo para             ║
   ║  profesionales de salud en Colombia.                      ║
   ║  Tokens heredados del design system de OchoManos.         ║
   ╚══════════════════════════════════════════════════════════╝ */

:root {
  --c-bg:        #f4f4f4;
  --c-ink:       #0c0c0c;
  --c-dark:      #171717;
  --c-card:      #ffffff;
  --c-text:      #171717;
  --c-text-sub:  rgba(23, 23, 23, 0.58);
  --c-muted:     #e7e7e7;
  --c-divider:   #e2e2e2;

  --c-amber:     #ffb547;
  --c-amber-ink: #4a3000;
  --c-octavio:   #f47b20;
  --c-lime:      #abc95a;

  /* Niveles de triage */
  --c-verde:     #2a8a3e;  --c-verde-bg:   #e7f6ea;
  --c-amarillo:  #c98a00;  --c-amarillo-bg:#fdf3da;
  --c-rojo:      #df2e34;  --c-rojo-bg:    #fde3e3;

  --radius-card: 20px;
  --radius-pill: 999px;
  --radius-opt:  16px;
  --shadow-sm:   0 4px 24px rgba(0,0,0,0.06);
  --shadow-md:   0 12px 44px rgba(0,0,0,0.10);
  --shadow-lg:   0 24px 70px rgba(0,0,0,0.14);

  --maxw: 660px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Rubik', system-ui, sans-serif;
  color: var(--c-text);
  background:
    radial-gradient(1100px 520px at 50% -8%, #fff6e6 0%, rgba(255,246,230,0) 60%),
    radial-gradient(900px 600px at 110% 110%, #eef4dd 0%, rgba(238,244,221,0) 55%),
    var(--c-bg);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 26px 20px 80px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Topbar ── */
.top {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 22px;
}
.top .logo { height: 22px; width: auto; display: block; }
.top .tag {
  font-size: 11px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--c-text-sub);
  background: #fff; border: 1px solid var(--c-divider);
  padding: 6px 12px; border-radius: var(--radius-pill);
}

/* ── Card base ── */
.card {
  background: var(--c-card);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-md);
  padding: 38px 34px;
  flex: 1;
  display: flex; flex-direction: column;
}

/* ── Steps (transición) ── */
.step { display: none; animation: fade 0.32s ease both; }
.step.active { display: flex; flex-direction: column; flex: 1; }
@keyframes fade {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: none; }
}

/* ══════════════════════ INTRO ══════════════════════ */
.intro { text-align: center; align-items: center; justify-content: center; gap: 0; }
.octavio-hero {
  width: 132px; height: auto;
  filter: drop-shadow(0 16px 24px rgba(244,123,32,0.28));
  animation: float 5s ease-in-out infinite;
  margin-bottom: 8px;
}
@keyframes float { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-9px)} }

.eyebrow {
  font-size: 12px; font-weight: 700; letter-spacing: 0.13em; text-transform: uppercase;
  color: var(--c-octavio); margin-bottom: 14px;
}
h1 {
  font-family: 'Domine', serif; font-weight: 700;
  font-size: clamp(27px, 6vw, 40px); line-height: 1.08;
  color: var(--c-ink); margin-bottom: 16px; letter-spacing: -0.01em;
}
h1 .hl { color: var(--c-octavio); }
.lede {
  font-size: clamp(15px, 2.4vw, 17px); color: var(--c-text-sub);
  max-width: 480px; margin: 0 auto 26px;
}
.meta-row {
  display: flex; gap: 18px; flex-wrap: wrap; justify-content: center;
  margin-bottom: 28px;
}
.meta-row span {
  font-size: 13px; font-weight: 500; color: var(--c-text);
  display: inline-flex; align-items: center; gap: 7px;
}
.meta-row .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--c-lime); }

/* ── Botones ── */
.btn {
  font-family: 'Rubik', sans-serif; font-weight: 600;
  border: none; cursor: pointer; border-radius: var(--radius-pill);
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  transition: transform 0.12s ease, filter 0.15s ease, box-shadow 0.15s ease;
  text-decoration: none;
}
.btn:active { transform: translateY(1px) scale(0.995); }
.btn-lg { font-size: 16px; padding: 15px 30px; }
.btn-amber { background: var(--c-amber); color: var(--c-amber-ink); box-shadow: 0 8px 22px rgba(255,181,71,0.42); }
.btn-amber:hover { filter: brightness(0.97); box-shadow: 0 10px 28px rgba(255,181,71,0.52); }
.btn-dark { background: var(--c-ink); color: #fff; }
.btn-dark:hover { filter: brightness(1.7); }
.btn-ghost { background: transparent; color: var(--c-text-sub); font-weight: 500; }
.btn-ghost:hover { color: var(--c-text); }
.btn[disabled] { opacity: 0.4; cursor: not-allowed; box-shadow: none; }

.fineprint { font-size: 12px; color: var(--c-text-sub); margin-top: 18px; }
.fineprint a { color: var(--c-text); }

/* ══════════════════════ PROGRESO ══════════════════════ */
.pbar-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 8px;
}
.pbar-lbl { font-size: 12px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--c-text-sub); }
.pbar-count { font-size: 12px; font-weight: 600; color: var(--c-octavio); }
.pbar { height: 7px; background: var(--c-muted); border-radius: var(--radius-pill); overflow: hidden; margin-bottom: 30px; }
.pbar-fill { height: 100%; width: 0; background: linear-gradient(90deg, var(--c-amber), var(--c-octavio)); border-radius: inherit; transition: width 0.4s cubic-bezier(0.4,0,0.2,1); }

/* ══════════════════════ PREGUNTA ══════════════════════ */
.q-eje {
  font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--c-octavio); margin-bottom: 10px;
}
.q-text {
  font-family: 'Domine', serif; font-weight: 600;
  font-size: clamp(20px, 3.6vw, 25px); line-height: 1.22; color: var(--c-ink);
  margin-bottom: 8px;
}
.q-help { font-size: 14px; color: var(--c-text-sub); margin-bottom: 24px; }

.opts { display: flex; flex-direction: column; gap: 12px; flex: 1; }
.opt {
  text-align: left; width: 100%;
  background: #fafafa; border: 1.5px solid var(--c-divider);
  border-radius: var(--radius-opt); padding: 17px 19px;
  font-family: 'Rubik', sans-serif; font-size: 16px; font-weight: 500; color: var(--c-text);
  cursor: pointer; transition: all 0.14s ease;
  display: flex; align-items: center; gap: 14px;
}
.opt:hover { border-color: var(--c-octavio); background: #fff; transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.opt .tick {
  width: 22px; height: 22px; border-radius: 50%; flex-shrink: 0;
  border: 2px solid #ccc; display: flex; align-items: center; justify-content: center;
  transition: all 0.14s ease;
}
.opt.sel { border-color: var(--c-octavio); background: #fff7f0; }
.opt.sel .tick { border-color: var(--c-octavio); background: var(--c-octavio); }
.opt.sel .tick::after { content: ''; width: 8px; height: 8px; border-radius: 50%; background: #fff; }

.q-nav { display: flex; align-items: center; justify-content: space-between; margin-top: 26px; }

/* ══════════════════════ FORM (lead) ══════════════════════ */
.form-octavio { width: 78px; margin: 0 auto 14px; display: block; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; font-weight: 600; color: var(--c-text); margin-bottom: 7px; }
.field input, .field select {
  width: 100%; font-family: 'Rubik', sans-serif; font-size: 15px; color: var(--c-text);
  padding: 13px 15px; border: 1.5px solid var(--c-divider); border-radius: 13px; background: #fafafa;
  transition: border-color 0.14s ease, background 0.14s ease;
}
.field input:focus, .field select:focus { outline: none; border-color: var(--c-octavio); background: #fff; }
.field .err { font-size: 12px; color: var(--c-rojo); margin-top: 5px; display: none; }
.field.invalid input, .field.invalid select { border-color: var(--c-rojo); }
.field.invalid .err { display: block; }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: 12.5px; color: var(--c-text-sub); margin: 6px 0 22px; }
.consent input { margin-top: 3px; flex-shrink: 0; }

/* ══════════════════════ RESULTADO ══════════════════════ */
.result-head {
  text-align: center; padding: 30px 22px 26px; border-radius: var(--radius-card);
  margin-bottom: 22px; position: relative; overflow: hidden;
}
.result-head.verde    { background: var(--c-verde-bg); }
.result-head.amarillo { background: var(--c-amarillo-bg); }
.result-head.rojo     { background: var(--c-rojo-bg); }
.result-octavio { width: 96px; margin: 0 auto 6px; display: block; filter: drop-shadow(0 10px 18px rgba(244,123,32,0.25)); }
.result-level {
  font-family: 'Domine', serif; font-weight: 700; font-size: 13px;
  letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 6px;
}
.result-head.verde .result-level    { color: var(--c-verde); }
.result-head.amarillo .result-level { color: var(--c-amarillo); }
.result-head.rojo .result-level     { color: var(--c-rojo); }
.result-title { font-family: 'Domine', serif; font-weight: 700; font-size: clamp(22px,4.5vw,29px); color: var(--c-ink); line-height: 1.12; margin-bottom: 10px; }
.result-sub { font-size: 15px; color: var(--c-text); max-width: 460px; margin: 0 auto; }

.gauge { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 16px 0 2px; }
.gauge-seg { height: 8px; width: 46px; border-radius: var(--radius-pill); background: rgba(0,0,0,0.10); }
.gauge-seg.on.verde    { background: var(--c-verde); }
.gauge-seg.on.amarillo { background: var(--c-amarillo); }
.gauge-seg.on.rojo     { background: var(--c-rojo); }

.section-lbl { font-size: 12px; font-weight: 700; letter-spacing: 0.07em; text-transform: uppercase; color: var(--c-text-sub); margin: 6px 0 14px; }

.finding {
  border: 1px solid var(--c-divider); border-radius: 15px;
  padding: 16px 17px; margin-bottom: 11px; background: #fff;
  display: flex; gap: 13px; align-items: flex-start;
}
.finding .ic {
  width: 30px; height: 30px; border-radius: 9px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 16px;
}
.finding.ok   .ic { background: var(--c-verde-bg); color: var(--c-verde); }
.finding.risk .ic { background: var(--c-rojo-bg); color: var(--c-rojo); }
.finding.warn .ic { background: var(--c-amarillo-bg); color: var(--c-amarillo); }
.finding-body { flex: 1; min-width: 0; }
.finding-title { font-weight: 700; font-size: 15px; color: var(--c-ink); margin-bottom: 3px; }
.finding-desc { font-size: 13.5px; color: var(--c-text-sub); margin-bottom: 7px; }
.finding-norm { font-size: 11.5px; color: var(--c-text-sub); font-weight: 500; background: #f4f4f4; border-radius: 7px; padding: 5px 9px; display: inline-block; }

/* CTA final */
.cta-card {
  margin-top: 22px; border-radius: var(--radius-card); padding: 28px 26px;
  background: linear-gradient(135deg, #1b1b1b, #2a2a2a);
  color: #fff; text-align: center; position: relative; overflow: hidden;
}
.cta-card::after {
  content: ''; position: absolute; right: -40px; bottom: -40px;
  width: 160px; height: 160px; background: radial-gradient(circle, rgba(255,181,71,0.32), transparent 70%);
}
.cta-octavio { width: 64px; margin: 0 auto 12px; display: block; position: relative; z-index: 1; }
.cta-card h3 { font-family: 'Domine', serif; font-weight: 700; font-size: 22px; margin-bottom: 8px; position: relative; z-index: 1; }
.cta-card p { font-size: 14px; opacity: 0.82; max-width: 420px; margin: 0 auto 20px; position: relative; z-index: 1; }
.cta-card .btn { position: relative; z-index: 1; }
.cta-note { font-size: 12px; opacity: 0.6; margin-top: 13px; position: relative; z-index: 1; }

.disclaimer {
  font-size: 11.5px; color: var(--c-text-sub); line-height: 1.6;
  margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--c-divider);
}

/* ── Footer ── */
.foot { text-align: center; font-size: 12px; color: var(--c-text-sub); margin-top: 20px; }
.foot strong { color: var(--c-text); font-weight: 600; }

@media (max-width: 560px) {
  .card { padding: 28px 20px; }
  .meta-row { gap: 12px; }
  .q-nav .btn-lg { padding: 13px 22px; font-size: 15px; }
}
