/* =========================================================
   Dcontenido · diagnóstico (usa los tokens de styles.css)
   ========================================================= */
.dx-body {
  min-height: 100vh; min-height: 100svh;
  background:
    radial-gradient(55% 40% at 100% 0%, rgba(93,147,206,.16), transparent 70%),
    radial-gradient(55% 40% at 0% 100%, rgba(234,111,139,.14), transparent 70%),
    var(--paper);
  display: flex; flex-direction: column;
}
.dx-bg { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.dx-pill-1 { width: 180px; top: 14%; left: -40px; rotate: -30deg; opacity: .7; }
.dx-pill-2 { width: 120px; bottom: 10%; right: -20px; rotate: 60deg; height: 20px; opacity: .5; }
.dx-bgring { top: auto; bottom: 18%; left: 6%; right: auto; opacity: .8; }

/* barra superior */
.dx-top {
  position: sticky; top: 0; z-index: 5;
  display: grid; grid-template-columns: 44px 1fr auto auto; align-items: center; gap: 14px;
  width: 100%; max-width: 620px; margin: 0 auto; padding: 16px 20px;
}
.dx-back {
  width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: #fff;
  font-size: 18px; cursor: pointer; transition: transform .3s var(--ease), background .3s;
}
.dx-back:hover { transform: translateX(-3px); background: var(--paper-2); }
.dx-back[hidden] { visibility: hidden; display: block; }
.dx-progress { display: flex; gap: 6px; justify-content: center; }
.dx-progress[hidden] { visibility: hidden; display: flex; }
.dx-progress span { height: 8px; width: 8px; border-radius: 8px; background: rgba(105,79,155,.2); transition: width .5s var(--ease), background .5s; }
.dx-progress span.done { background: var(--magenta); }
.dx-progress span.on { width: 32px; background: var(--grad); }
.dx-count { font-size: 12px; color: var(--muted); grid-column: 3; grid-row: 1; }
.dx-count[hidden] { display: block; visibility: hidden; }
.dx-logo { grid-column: 4; grid-row: 1; justify-self: end; }
.dx-logo img { height: 20px; width: auto; }

/* pantalla */
.dx-main { position: relative; z-index: 1; flex: 1; display: flex; }
.dx-screen { width: 100%; max-width: 560px; margin: 0 auto; padding: 12px 20px 48px; display: flex; flex-direction: column; justify-content: center; }
.dx-screen > * { width: 100%; }

.dx-intro { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 18px; padding: 40px 0; }
.dx-badge { font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--violet); padding: 7px 14px; border-radius: 999px; background: #fff; border: 1px solid var(--line); }
.dx-hero { font-family: var(--font-display); font-weight: 900; font-size: clamp(40px, 10vw, 64px); line-height: .98; letter-spacing: -0.035em; }
.dx-intro .btn { width: 100%; max-width: 360px; justify-content: center; margin-top: 12px; }
.dx-note { font-size: 13px; color: var(--muted); }
.center { text-align: center; }

.dx-q, .dx-result { display: flex; flex-direction: column; gap: 14px; }
.dx-title { font-family: var(--font-display); font-weight: 900; font-size: clamp(30px, 7vw, 42px); line-height: 1.05; letter-spacing: -0.025em; }
.dx-title:focus { outline: none; }
.dx-sub { color: var(--muted); margin-top: -4px; }
.dx-options { display: flex; flex-direction: column; gap: 10px; margin: 14px 0 10px; }

.dx-opt {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 17px 18px; border-radius: 18px; background: #fff; border: 1.5px solid var(--line);
  font: inherit; font-weight: 500; color: var(--ink); text-align: left; cursor: pointer;
  transition: border-color .3s, box-shadow .3s, transform .3s var(--ease);
}
.dx-opt:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -18px rgba(30,24,56,.35); }
.dx-opt.is-on { border-color: transparent; background: linear-gradient(#fff, #fff) padding-box, var(--grad-diag) border-box; box-shadow: 0 14px 30px -18px rgba(181,104,166,.6); }
.dx-opt small { display: block; font-size: 13px; color: var(--muted); font-weight: 400; }
.dx-opt-title { display: block; }
.dx-opt-side { display: flex; align-items: center; gap: 10px; flex: none; }
.dx-tick {
  width: 24px; height: 24px; border-radius: 50%; border: 1.5px solid var(--line);
  display: grid; place-items: center; color: transparent; transition: background .3s, color .3s, border-color .3s;
}
.dx-tick.is-square { border-radius: 8px; }
.dx-opt.is-on .dx-tick { background: var(--grad-diag); border-color: transparent; color: #fff; }
.dx-info {
  width: 24px; height: 24px; border-radius: 50%; background: var(--paper-2); color: var(--violet);
  display: grid; place-items: center; font-size: 12px; font-weight: 700; font-style: italic; font-family: Georgia, serif;
}
.dx-info:hover { background: var(--violet); color: #fff; }
.dx-info-text { margin: 6px 10px 0; padding: 12px 14px; border-radius: 14px; background: var(--paper-2); font-size: 13px; color: var(--muted); }

.dx-continue { width: 100%; justify-content: center; margin-top: 8px; }
.dx-continue:disabled { opacity: .35; cursor: not-allowed; }
.dx-continue:disabled::before { transform: translateY(101%) !important; }
.dx-skip { background: none; border: 0; font: inherit; font-size: 14px; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; padding: 8px; }

/* resultado */
.dx-card { background: #fff; border: 1px solid var(--line); border-radius: 24px; padding: 22px; }
.dx-kicker { font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--magenta); margin-bottom: 10px; }
.dx-kicker-out { margin: 8px 4px -4px; }
.dx-score { display: flex; flex-direction: column; align-items: center; padding: 28px; margin: 10px 0; box-shadow: 0 30px 60px -35px rgba(181,104,166,.55); }
.dx-ring { position: relative; width: 170px; height: 170px; margin: 6px 0 14px; }
.dx-ring svg { width: 100%; height: 100%; rotate: -90deg; }
.dx-ring-bg { fill: none; stroke: var(--paper-2); stroke-width: 9; }
.dx-ring-fg { fill: none; stroke: url(#dxGrad); stroke-width: 9; stroke-linecap: round; }
.dx-ring-num { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.dx-ring-num strong { font-family: var(--font-display); font-weight: 900; font-size: 52px; line-height: 1; }
.dx-ring-num span { font-size: 13px; color: var(--muted); }
.dx-score-label { display: flex; align-items: center; gap: 8px; font-weight: 600; }
.dx-score-label i { width: 12px; height: 12px; border-radius: 50%; }

.dx-msg { padding: 14px 16px; border-radius: 18px; background: var(--paper-2); font-size: 14px; }
.dx-list li, .dx-phase li { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; font-size: 14px; }
.dx-list li span, .dx-phase li span { color: var(--muted); }
.dx-list li strong { text-align: right; font-weight: 600; }
.dx-list li small { display: block; color: var(--muted); font-weight: 400; font-size: 12px; }
.dx-phases { display: flex; flex-direction: column; gap: 8px; }
.dx-phase { border-radius: 18px; border: 1px solid var(--line); background: rgba(255,255,255,.6); padding: 14px 16px; }
.dx-phase.is-first { border-color: transparent; background: linear-gradient(#fff, #fff) padding-box, var(--grad-diag) border-box; border-width: 1.5px; border-style: solid; }
.dx-phase-head { display: flex; justify-content: space-between; align-items: center; font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.dx-phase.is-first .dx-phase-head span { color: var(--magenta); }
.dx-phase-head em { font-style: normal; font-size: 10px; padding: 3px 8px; border-radius: 999px; background: var(--paper-2); color: var(--violet); }
.dx-phase-sub { text-align: right; font-size: 12px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 6px; margin-top: 4px; }
.dx-total { text-align: center; box-shadow: 0 30px 60px -35px rgba(105,79,155,.55); }
.dx-total-num { font-family: var(--font-display); font-weight: 900; font-size: clamp(34px, 9vw, 46px); line-height: 1.05; letter-spacing: -0.02em; }
.dx-total-alt { font-size: 14px; color: var(--muted); margin-bottom: 8px; }
.dx-suggest p:not(.dx-kicker) { font-size: 14px; }

/* contacto */
.dx-field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); }
.dx-field input, .dx-field select {
  font: inherit; font-size: 16px; font-weight: 400; color: var(--ink);
  background: #fff; border: 1.5px solid var(--line); border-radius: 16px; padding: 14px 16px;
  transition: border-color .3s;
}
.dx-field input:focus, .dx-field select:focus { outline: none; border-color: var(--magenta); }
.dx-field input.invalid { border-color: var(--pink); background: #fff6f7; }
.dx-phone { display: grid; grid-template-columns: 110px 1fr; gap: 8px; }
.dx-error { font-size: 14px; color: var(--pink); text-align: center; min-height: 1.4em; }
.dx-error a { color: var(--violet); font-weight: 600; text-decoration: underline; }

/* enviado */
.dx-done-icon { width: 72px; height: 72px; border-radius: 50%; display: grid; place-items: center; background: var(--grad-diag); color: #fff; }
.dx-done-icon svg { width: 32px; height: 32px; }
.dx-done-actions { display: flex; flex-direction: column; gap: 10px; width: 100%; max-width: 360px; margin-top: 10px; }
.dx-done-actions .btn { justify-content: center; }

@media (max-width: 560px) {
  .dx-count { display: none !important; }
  .dx-logo img { height: 16px; }
  .dx-bgring { display: none; }
}
