/* ============================================================
   QI — Páginas internas (legal / formularios)
   Hereda tokens de qi-styles.css
   ============================================================ */

/* ---------- Page hero ---------- */
.page-hero {
  position: relative;
  padding-top: 142px;
  padding-bottom: 54px;
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}
.page-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(700px 360px at 85% 0%, rgba(255,131,0,0.14), transparent 60%),
    radial-gradient(600px 360px at 5% 20%, rgba(253,197,1,0.08), transparent 60%);
  pointer-events: none;
}
.crumbs {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--ink-faint);
  margin-bottom: 26px;
}
.crumbs a { color: var(--ink-dim); transition: color 0.25s; }
.crumbs a:hover { color: var(--gold); }
.crumbs .sep { color: var(--line-strong); }
.page-hero h1 {
  font-size: clamp(2.3rem, 5vw, 3.7rem);
  letter-spacing: -0.025em;
  margin-bottom: 18px;
}
.page-hero .lead { max-width: 64ch; }
.page-meta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 26px;
  padding: 8px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.08em;
  color: var(--ink-dim);
  background: rgba(151,165,255,0.04);
}
.page-meta .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--gold); }

/* ---------- Legal layout (TOC + prose) ---------- */
.legal-wrap {
  display: grid;
  grid-template-columns: 248px 1fr;
  gap: clamp(36px, 5vw, 72px);
  align-items: start;
  padding-block: clamp(56px, 7vw, 92px);
}
.toc {
  position: sticky;
  top: 108px;
}
.toc h4 {
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 16px;
}
.toc ol {
  list-style: none;
  counter-reset: toc;
  display: flex;
  flex-direction: column;
  gap: 2px;
  border-left: 1px solid var(--line);
}
.toc a {
  counter-increment: toc;
  display: block;
  padding: 9px 16px;
  margin-left: -1px;
  border-left: 2px solid transparent;
  font-size: 0.92rem;
  color: var(--ink-dim);
  transition: color 0.25s, border-color 0.25s;
}
.toc a::before {
  content: counter(toc, decimal-leading-zero) "  ";
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-faint);
}
.toc a:hover { color: var(--ink); }
.toc a.active { color: var(--gold); border-left-color: var(--gold); }

.prose { max-width: 74ch; }
.prose section { scroll-margin-top: 100px; }
.prose section + section { margin-top: 48px; }
.prose h2 {
  font-size: clamp(1.4rem, 2.4vw, 1.85rem);
  letter-spacing: -0.02em;
  margin-bottom: 16px;
  display: flex;
  align-items: baseline;
  gap: 14px;
}
.prose h2 .h-num {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--orange);
  flex: none;
}
.prose h3 {
  font-family: var(--font-display);
  font-size: 1.1rem;
  margin: 26px 0 10px;
}
.prose p { color: var(--ink-dim); margin-bottom: 14px; }
.prose ul { color: var(--ink-dim); margin: 4px 0 16px; padding-left: 4px; list-style: none; display: flex; flex-direction: column; gap: 10px; }
.prose ul li { position: relative; padding-left: 26px; }
.prose ul li::before {
  content: "";
  position: absolute;
  left: 4px; top: 10px;
  width: 7px; height: 7px;
  border-radius: 2px;
  background: var(--warm);
}
.prose a { color: var(--gold); border-bottom: 1px solid rgba(253,197,1,0.4); }
.prose strong { color: var(--ink); font-weight: 600; }
.callout {
  margin: 20px 0;
  padding: 20px 22px;
  border-radius: 14px;
  border: 1px solid var(--line-strong);
  background: var(--warm-soft);
  color: var(--ink-dim);
  font-size: 0.95rem;
}
.callout strong { color: var(--ink); }

/* ---------- Reclamaciones form ---------- */
.recl-wrap { padding-block: clamp(48px, 6vw, 80px); }
.recl-card {
  max-width: 920px;
  margin: 0 auto;
  border-radius: var(--radius);
  border: 1px solid var(--line-strong);
  background: linear-gradient(180deg, rgba(10,17,96,0.4), rgba(2,6,58,0.28));
  box-shadow: 0 40px 90px -50px rgba(0,0,0,0.85);
  overflow: hidden;
}
.recl-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  padding: 24px clamp(24px, 4vw, 40px);
  border-bottom: 1px solid var(--line);
  background: rgba(1,4,39,0.4);
}
.recl-top .rt-id {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--ink-dim);
}
.recl-top .rt-id b { color: var(--gold); }
.recl-body { padding: clamp(26px, 4vw, 44px); }

.fieldset { margin-bottom: 40px; }
.fieldset:last-of-type { margin-bottom: 0; }
.fs-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 22px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.fs-num {
  width: 30px; height: 30px; flex: none;
  display: grid; place-items: center;
  border-radius: 9px;
  background: var(--warm);
  color: #1a0a00;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
}
.fs-head h2 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  letter-spacing: -0.01em;
}

/* segmented choice cards */
.seg {
  display: grid;
  gap: 14px;
  margin-bottom: 22px;
}
.seg.cols-2 { grid-template-columns: 1fr 1fr; }
.seg-opt {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 18px 20px 18px 50px;
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  cursor: pointer;
  background: rgba(1,4,39,0.4);
  transition: border-color 0.25s, background 0.25s;
}
.seg-opt input { position: absolute; opacity: 0; }
.seg-opt .mark {
  position: absolute;
  left: 18px; top: 20px;
  width: 20px; height: 20px;
  border-radius: 50%;
  border: 2px solid var(--line-strong);
  transition: border-color 0.25s;
}
.seg-opt .mark::after {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: 50%;
  background: var(--warm);
  transform: scale(0);
  transition: transform 0.2s var(--ease);
}
.seg-opt .opt-title { font-family: var(--font-display); font-weight: 600; font-size: 1.02rem; }
.seg-opt .opt-desc { font-size: 0.86rem; color: var(--ink-faint); line-height: 1.5; }
.seg-opt:hover { border-color: var(--line-strong); background: rgba(151,165,255,0.05); }
.seg-opt:has(input:checked) { border-color: var(--gold); background: rgba(253,197,1,0.06); }
.seg-opt:has(input:checked) .mark { border-color: var(--gold); }
.seg-opt:has(input:checked) .mark::after { transform: scale(1); }

.recl-note {
  margin-top: 6px;
  font-size: 0.82rem;
  color: var(--ink-faint);
  line-height: 1.6;
}
.recl-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-top: 8px;
  padding: 24px clamp(24px, 4vw, 40px);
  border-top: 1px solid var(--line);
  background: rgba(1,4,39,0.4);
}
.recl-foot .form-note { max-width: 46ch; }
.recl-ok {
  display: none;
  align-items: center; gap: 12px;
  width: 100%;
  padding: 18px 20px;
  border-radius: 12px;
  border: 1px solid var(--gold);
  background: rgba(253,197,1,0.08);
  color: var(--ink);
  font-size: 0.95rem;
}
.recl-ok.show { display: flex; }
.recl-ok .tick {
  width: 30px; height: 30px; flex: none;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--warm);
  color: #1a0a00;
}

@media (max-width: 860px) {
  .legal-wrap { grid-template-columns: 1fr; }
  .toc { position: static; margin-bottom: 8px; }
  .toc ol { flex-direction: row; flex-wrap: wrap; border-left: none; gap: 8px; }
  .toc a { border: 1px solid var(--line); border-radius: 999px; padding: 8px 14px; }
  .toc a.active { border-color: var(--gold); }
  .seg.cols-2 { grid-template-columns: 1fr; }
}
