/* ═══════════════════════════════════════════════════════════
   éxodo bpo — ARTÍCULO · CINEMÁTICA (experiencia de lectura)
   Carga DESPUÉS de home-cine.css y detalle-cine.css
   ═══════════════════════════════════════════════════════════ */

/* ═ BARRA DE PROGRESO DE LECTURA ═ */
#rprog { position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 12500; pointer-events: none; }
#rprog i {
  position: absolute; inset: 0; display: block;
  background: linear-gradient(90deg, var(--azul), var(--azul-luz));
  transform: scaleX(0); transform-origin: left;
}

/* ═ PORTADA ═ */
.ah {
  min-height: 86vh; min-height: 86svh; position: relative;
  display: flex; align-items: flex-end; overflow: hidden;
  background: var(--ink);
  padding: 140px var(--pad) clamp(56px, 9vh, 110px);
}
.ah::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 90% 60% at 15% 110%, rgba(38, 141, 181, 0.1), transparent 55%),
    radial-gradient(ellipse 140% 110% at 50% 50%, transparent 45%, rgba(7, 7, 8, 0.7) 100%);
}
.ah-in { position: relative; z-index: 2; max-width: 1080px; }
.ah-bc {
  display: flex; align-items: center; gap: 12px; color: var(--mut-d);
  margin-bottom: clamp(20px, 3vh, 32px); opacity: 0; transform: translateY(12px);
}
.ah-bc a { color: var(--mut-d); transition: color 0.3s; }
.ah-bc a:hover { color: var(--fg); }
.ah-bc .cur { color: var(--azul-luz); }
.ah-meta {
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  color: var(--mut-d); margin-bottom: clamp(22px, 3.2vh, 34px);
  opacity: 0; transform: translateY(12px);
}
.ah-cat {
  color: var(--azul-luz); border: 1px solid rgba(38, 141, 181, 0.4);
  border-radius: 100px; padding: 6px 16px;
}
.ah-h {
  font-size: clamp(30px, 4.6vw, 78px); font-weight: 760; letter-spacing: -0.04em;
  line-height: 1.02; margin-bottom: clamp(24px, 3.6vh, 38px); max-width: 1040px;
}
.ah-lead {
  font-size: clamp(15px, 1.45vw, 21px); font-weight: 300; line-height: 1.8;
  color: var(--mut); max-width: 680px; text-wrap: pretty;
  opacity: 0; transform: translateY(14px);
}
.ah-by { display: flex; align-items: center; gap: 14px; margin-top: clamp(24px, 3.5vh, 36px); opacity: 0; transform: translateY(14px); }
.ah-by img { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; }
.ah-by .n { font-size: 13.5px; font-weight: 600; }
.ah-by .r { font-family: 'JetBrains Mono', monospace; font-size: 9.5px; letter-spacing: 0.1em; color: var(--mut-d); margin-top: 3px; }

/* ═ CUERPO DE LECTURA (hueso) ═ */
.aread { background: var(--bone); color: var(--ink); padding: clamp(70px, 10vh, 130px) var(--pad) clamp(90px, 13vh, 170px); }
.aprose { max-width: 760px; margin: 0 auto; counter-reset: sec; }
.aprose p {
  font-size: clamp(16px, 1.3vw, 19px); font-weight: 300; line-height: 1.95;
  color: #44423e; margin-bottom: 26px; text-wrap: pretty;
}
.aprose .lead { font-size: clamp(18px, 1.5vw, 22px); color: #383632; }
.aprose > p:first-child { font-size: clamp(18px, 1.5vw, 22px); color: #383632; }
.aprose > p:first-child::first-letter {
  font-size: 3.1em; font-weight: 760; float: left; line-height: 0.82;
  padding: 0.06em 0.14em 0 0; color: var(--ink);
}
.aprose strong { font-weight: 600; color: var(--ink); }
.aprose a { color: #1d6f91; text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; transition: opacity 0.3s; }
.aprose a:hover { opacity: 0.65; }
.aprose h2 {
  counter-increment: sec;
  font-size: clamp(24px, 2.7vw, 42px); font-weight: 750; letter-spacing: -0.03em;
  line-height: 1.1; margin: clamp(56px, 8vh, 88px) 0 24px; text-wrap: pretty;
}
.aprose h2::before {
  content: counter(sec, decimal-leading-zero);
  display: block; font-family: 'JetBrains Mono', monospace; font-size: 10px;
  letter-spacing: 0.25em; color: #268DB5; margin-bottom: 14px; font-weight: 400;
}
.aprose h3 {
  font-size: clamp(18px, 1.7vw, 25px); font-weight: 700; letter-spacing: -0.02em;
  margin: 44px 0 16px; text-wrap: pretty;
}
.aprose ul, .aprose ol { padding-left: 24px; margin-bottom: 28px; }
.aprose li {
  font-size: clamp(15px, 1.2vw, 17.5px); font-weight: 300; line-height: 1.85;
  color: #44423e; margin-bottom: 13px; padding-left: 6px; text-wrap: pretty;
}
.aprose li::marker { color: #268DB5; font-weight: 600; }
.aprose .callout {
  border-left: 2px solid #268DB5; background: rgba(38, 141, 181, 0.06);
  padding: 24px 30px; margin: 40px 0;
}
.aprose .callout .c-tag {
  font-family: 'JetBrains Mono', monospace; font-size: 9px; letter-spacing: 0.22em;
  text-transform: uppercase; color: #1d6f91; margin-bottom: 12px;
}
.aprose .callout p { font-size: clamp(15px, 1.2vw, 17.5px); margin-bottom: 0; color: #383632; }
.aprose .checklist {
  background: #fff; border: 1px solid rgba(10, 10, 11, 0.1);
  padding: clamp(26px, 3vw, 40px); margin: 40px 0;
}
.aprose .checklist h4 {
  font-family: 'JetBrains Mono', monospace; font-size: 10px; letter-spacing: 0.22em;
  text-transform: uppercase; color: #8d897f; margin-bottom: 22px; font-weight: 500;
}
.aprose .checklist ul { list-style: none; padding-left: 0; margin-bottom: 0; }
.aprose .checklist li { padding-left: 30px; position: relative; }
.aprose .checklist li::before {
  content: '✓'; position: absolute; left: 0; top: 1px;
  color: #268DB5; font-weight: 700; font-size: 14px;
}
.aprose .pull {
  font-size: clamp(21px, 2.4vw, 34px); font-weight: 250; letter-spacing: -0.02em;
  line-height: 1.45; color: var(--ink); border-left: 2px solid #268DB5;
  padding: 10px 0 10px clamp(24px, 3vw, 40px); margin: clamp(44px, 6vh, 64px) 0; text-wrap: pretty;
}
.aprose .sign {
  display: flex; align-items: center; gap: 16px;
  margin-top: clamp(48px, 7vh, 72px); padding-top: 32px;
  border-top: 1px solid rgba(10, 10, 11, 0.14);
}
.aprose .sign img { width: 60px; height: 60px; border-radius: 50%; object-fit: cover; }
.aprose .sign .n { font-size: 15px; font-weight: 700; }
.aprose .sign .r { font-family: 'JetBrains Mono', monospace; font-size: 9.5px; letter-spacing: 0.1em; color: #8d897f; margin-top: 4px; }

/* ═ SIGUIENTE ARTÍCULO (tinta) ═ */
.nextart { background: var(--ink); padding: clamp(90px, 14vh, 180px) var(--pad); text-align: center; overflow: hidden; }
.nxt-label { color: var(--mut-d); margin-bottom: clamp(24px, 3.5vh, 40px); }
.nxt-ti {
  display: block; font-size: clamp(26px, 4.4vw, 72px); font-weight: 760; letter-spacing: -0.04em;
  line-height: 1.05; color: transparent; max-width: 1100px; margin: 0 auto;
  -webkit-text-stroke: 1px rgba(242, 240, 235, 0.42);
  transition: color 0.55s var(--ease), -webkit-text-stroke-color 0.55s;
  text-wrap: pretty;
}
.nextart a:hover .nxt-ti { color: var(--fg); -webkit-text-stroke-color: transparent; }
.nxt-meta { color: var(--mut-d); margin-top: clamp(20px, 3vh, 32px); }
.nxt-meta b { color: var(--azul-luz); font-weight: 500; }

/* ═ RELACIONADOS (tinta-2) ═ */
.related { background: var(--ink-2); padding: clamp(80px, 11vh, 150px) var(--pad); }
.rel-inner { max-width: 1100px; margin: 0 auto; }
.rel-tag {
  font-family: 'JetBrains Mono', monospace; font-size: 10px; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--mut-d); margin-bottom: 20px;
  display: flex; align-items: center; gap: 14px;
}
.rel-tag::before { content: ''; width: 36px; height: 1px; background: currentColor; opacity: 0.5; }
.rel-h { font-size: clamp(24px, 2.8vw, 44px); font-weight: 750; letter-spacing: -0.03em; margin-bottom: clamp(36px, 5vh, 56px); }
.rel-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(16px, 2vw, 28px); }
.rel-card {
  background: var(--panel); border: 1px solid rgba(255, 255, 255, 0.06);
  padding: clamp(24px, 2.6vw, 40px); position: relative; overflow: hidden;
  display: flex; flex-direction: column;
}
.rel-card::before {
  content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 2px;
  background: var(--azul); transform: scaleX(0); transform-origin: left;
  transition: transform 0.6s var(--ease);
}
.rel-card:hover::before { transform: scaleX(1); }
.rel-ct { font-family: 'JetBrains Mono', monospace; font-size: 8.5px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--azul-luz); margin-bottom: 18px; }
.rel-ti { font-size: clamp(17px, 1.7vw, 23px); font-weight: 700; letter-spacing: -0.02em; line-height: 1.25; margin-bottom: 10px; }
.rel-de { font-size: 12.5px; font-weight: 300; line-height: 1.8; color: var(--mut); text-wrap: pretty; }

@media (max-width: 900px) {
  .rel-grid { grid-template-columns: 1fr; }
  .ah { min-height: 72vh; padding-top: 120px; }
}
@media (prefers-reduced-motion: reduce) {
  .ah-bc, .ah-meta, .ah-lead, .ah-by { opacity: 1 !important; transform: none !important; }
}

/* ═ GRILLA DE LECTURA CON ASIDE ═ */
.aread-grid {
  display: grid; grid-template-columns: minmax(0, 740px) minmax(216px, 300px);
  gap: clamp(32px, 4.5vw, 100px); justify-content: center; align-items: start;
  max-width: 1180px; margin: 0 auto;
}
.aread-grid .aprose { max-width: none; margin: 0; }
.as { position: sticky; top: 110px; display: flex; flex-direction: column; gap: clamp(24px, 3.5vh, 40px); }
.as-h {
  font-size: 9px; letter-spacing: 0.22em; color: #a39f97;
  margin-bottom: 18px; display: flex; align-items: center; gap: 12px;
}
.as-h::before { content: ''; width: 26px; height: 1px; background: currentColor; opacity: 0.6; }
.as-art {
  display: block; padding: 16px 0;
  border-top: 1px solid rgba(10, 10, 11, 0.1);
}
.as-art:last-of-type { border-bottom: 1px solid rgba(10, 10, 11, 0.1); }
.as-k { display: block; font-size: 8.5px; letter-spacing: 0.2em; color: #268DB5; margin-bottom: 7px; text-transform: uppercase; }
.as-t {
  display: block; font-size: 14.5px; font-weight: 600; letter-spacing: -0.01em;
  line-height: 1.4; color: var(--ink); transition: opacity 0.3s; text-wrap: pretty;
}
.as-art:hover .as-t { opacity: 0.55; }
.as-cta {
  border-left: 2px solid #268DB5; background: rgba(38, 141, 181, 0.06);
  padding: 22px 24px;
}
.as-cta .as-h { margin-bottom: 14px; }
.as-cta-ti { font-size: 16px; font-weight: 700; letter-spacing: -0.015em; line-height: 1.35; margin-bottom: 8px; color: var(--ink); text-wrap: pretty; }
.as-cta-de { font-size: 12px; font-weight: 300; line-height: 1.75; color: #6e6b65; margin-bottom: 16px; text-wrap: pretty; }
.as-cta-link {
  display: block; font-family: 'JetBrains Mono', monospace; font-size: 10.5px;
  letter-spacing: 0.08em; color: #1d6f91; margin-top: 8px; transition: opacity 0.3s;
}
.as-cta-link:hover { opacity: 0.6; }
@media (max-width: 860px) {
  .aread-grid { grid-template-columns: 1fr; }
  .as { position: static; margin-top: 56px; border-top: 1px solid rgba(10, 10, 11, 0.14); padding-top: 40px; }
}

/* ═ TEMA VERDE — artículo de opinión, registro de diario ═ */
body.theme-verde #rprog i { background: linear-gradient(90deg, #2e8a34, #40AC47); }
body.theme-verde .ah-bc .cur { color: #6fcf76; }
body.theme-verde .ah-cat { color: #6fcf76; border-color: rgba(64, 172, 71, 0.45); }
body.theme-verde .aprose a { color: #2e7a33; }
body.theme-verde .aprose h2::before { color: #2e8a34; }
body.theme-verde .aprose li::marker { color: #2e8a34; }
body.theme-verde .aprose .callout { border-left-color: #2e8a34; background: rgba(64, 172, 71, 0.07); }
body.theme-verde .aprose .callout .c-tag { color: #2e7a33; }
body.theme-verde .aprose .checklist li::before { color: #2e8a34; }
body.theme-verde .aprose .pull { border-left-color: #2e8a34; }
body.theme-verde .as-k { color: #2e8a34; }
body.theme-verde .as-cta { border-left-color: #2e8a34; background: rgba(64, 172, 71, 0.07); }
body.theme-verde .as-cta-link { color: #2e7a33; }
body.theme-verde .nxt-meta b { color: #6fcf76; }
body.theme-verde .rel-ct { color: #6fcf76; }
body.theme-verde .rel-card::before { background: #40AC47; }
body.theme-verde .cta-btn.azul { background: #2e8a34; }
body.theme-verde .cta-btn.azul:hover { box-shadow: 0 24px 70px rgba(64, 172, 71, 0.35); }
body.theme-verde .sd-cta .cta-h em { color: #6fcf76; }

/* registro de diario */
body.theme-verde .ah-h { font-weight: 800; letter-spacing: -0.035em; }
body.theme-verde .ah-by {
  border-top: 1px solid rgba(242, 240, 235, 0.16);
  border-bottom: 1px solid rgba(242, 240, 235, 0.16);
  padding: 16px 0; margin-top: clamp(26px, 4vh, 40px);
}
body.theme-verde .aprose p { text-align: justify; hyphens: auto; -webkit-hyphens: auto; }
body.theme-verde .aprose > p:first-child::first-letter { color: #2e8a34; }
body.theme-verde .aprose .pull {
  text-align: left; border-left: none; padding-left: 0;
  border-top: 2px solid #2e8a34; border-bottom: 1px solid rgba(10, 10, 11, 0.14);
  padding-top: 26px; padding-bottom: 26px; font-weight: 300;
}

/* ═ TEMA TINTA — páginas legales, registro monocromo ═ */
body.theme-tinta #rprog i { background: linear-gradient(90deg, #2a2a2e, #6a6a70); }
body.theme-tinta .ah-bc .cur { color: var(--fg); }
body.theme-tinta .ah-cat { color: var(--fg); border-color: rgba(242, 240, 235, 0.3); }
body.theme-tinta .aprose a { color: var(--ink); }
body.theme-tinta .aprose h2::before { color: #8d897f; }
body.theme-tinta .aprose li::marker { color: var(--ink); }
body.theme-tinta .as-k { color: #8d897f; }
body.theme-tinta .as-cta { border-left-color: var(--ink); background: rgba(10, 10, 11, 0.045); }
body.theme-tinta .as-cta-link { color: var(--ink); }
body.theme-tinta .nxt-meta b { color: var(--fg); }
body.theme-tinta .sd-cta .cta-h em { color: var(--fg); }
body.theme-tinta .cta-btn.azul { background: var(--fg); color: var(--ink); }
body.theme-tinta .cta-btn.azul:hover { box-shadow: 0 24px 70px rgba(242, 240, 235, 0.18); }
body.theme-tinta .ah { min-height: 52vh; min-height: 52svh; padding-top: 150px; padding-bottom: clamp(44px, 7vh, 80px); }
body.theme-tinta .ah-h { font-size: clamp(28px, 4vw, 64px); max-width: 880px; }
body.theme-tinta .aprose > p:first-child { font-size: clamp(16px, 1.3vw, 19px); color: #44423e; }
body.theme-tinta .aprose > p:first-child::first-letter {
  font-size: inherit; font-weight: inherit; float: none; padding: 0; color: inherit;
}

/* índice lateral (legales) */
.as-toc { display: flex; flex-direction: column; }
.as-toc a {
  display: block; padding: 9px 0 9px 18px; position: relative;
  font-size: 12.5px; font-weight: 400; line-height: 1.45; color: #8d897f;
  border-left: 1px solid rgba(10, 10, 11, 0.12); transition: color 0.3s;
}
.as-toc a::before {
  content: ''; position: absolute; left: -1px; top: 0; height: 100%; width: 1px;
  background: var(--ink); transform: scaleY(0); transition: transform 0.35s var(--ease);
}
.as-toc a:hover, .as-toc a.on { color: var(--ink); }
.as-toc a.on::before { transform: scaleY(1); }
