/* Páginas de rutas de aprendizaje y capítulos (The House of Routing) */
.rt-wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.rt-crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin: 0; padding: 22px 0 0; list-style: none; font-family: var(--font-mono); font-size: 12px; letter-spacing: .08em; color: var(--ink-muted); }
.rt-crumbs li { display: inline-flex; align-items: center; gap: 10px; }
.rt-crumbs li + li::before { content: "›"; color: var(--line-strong); }
.rt-crumbs a { color: var(--ink-muted); text-decoration: none; transition: color 120ms linear; }
.rt-crumbs a:hover, .rt-crumbs a:focus-visible { color: var(--ink); }
.rt-crumbs [aria-current] { color: var(--route-text); }

/* Cabecera de la ruta */
.rt-hero { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 28px; align-items: center; padding: 48px 0 56px; border-bottom: 1px solid var(--line); }
.rt-hex { position: relative; width: 112px; height: 128px; display: grid; place-items: center; color: var(--pilar-tecnologia); }
.rt-hex svg.hx { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.rt-hex svg.hx path { fill: rgba(188, 208, 234, .06); stroke: currentColor; stroke-width: 2; stroke-dasharray: 1; stroke-dashoffset: 1; animation: rt-draw 1.2s var(--ease-route, ease) .2s forwards; }
.rt-hex svg.ic { position: relative; width: 44px; height: 44px; color: var(--ink); }
@keyframes rt-draw { to { stroke-dashoffset: 0; } }
.rt-eyebrow { margin: 0; font-family: var(--font-mono); font-size: 13px; font-weight: 600; letter-spacing: .14em; color: var(--focus); }
.rt-h1 { margin: 8px 0 0; font-family: var(--font-display); font-size: clamp(36px, 5vw, 56px); line-height: 1.05; font-weight: 700; letter-spacing: -.025em; }
.rt-lead { margin: 14px 0 0; max-width: 720px; font-size: 18px; line-height: 30px; color: var(--ink-muted); }
.rt-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-top: 18px; }
.rt-status { position: relative; overflow: hidden; display: inline-flex; align-items: center; gap: 8px; height: 26px; padding: 0 10px; border: 1px solid var(--ok); border-radius: 4px; background: var(--surface-raised); font-family: var(--font-mono); font-size: 11px; font-weight: 700; letter-spacing: .12em; color: var(--ok); white-space: nowrap; }
.rt-status i { position: relative; width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 6px var(--ok); }
.rt-status i::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: var(--ok); animation: rt-halo 2s ease-out infinite; }
@keyframes rt-halo { from { transform: scale(1); opacity: .7; } to { transform: scale(3); opacity: 0; } }
.rt-soon { border-color: var(--warn); color: var(--warn); }
.rt-soon i, .rt-soon i::after { background: var(--warn); box-shadow: 0 0 6px var(--warn); }
.rt-tags { font-family: var(--font-mono); font-size: 12.5px; letter-spacing: .04em; color: var(--ink-muted); }

/* Temas, subtemas y capítulos */
.rt-sec { padding: 56px 0 24px; }
.rt-h2 { margin: 0 0 6px; font-family: var(--font-display); font-size: 30px; line-height: 1.2; font-weight: 700; letter-spacing: -.015em; }
.rt-sub { margin: 0 0 28px; color: var(--ink-muted); font-size: 16px; line-height: 26px; max-width: 760px; }
.rt-topic { border: 1px solid var(--line); border-radius: 10px; background: var(--surface-raised); margin-bottom: 16px; overflow: hidden; }
.rt-topic > summary, .rt-cert > summary { list-style: none; cursor: pointer; }
.rt-topic > summary::-webkit-details-marker, .rt-cert > summary::-webkit-details-marker { display: none; }
.rt-topic > summary { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 16px; align-items: center; padding: 20px 22px; transition: background-color 120ms linear; }
.rt-topic > summary:hover { background: rgba(188, 208, 234, .04); }
.rt-topic > summary:focus-visible, .rt-cert > summary:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.rt-tnum { font-family: var(--font-mono); font-size: 12px; font-weight: 700; letter-spacing: .14em; color: var(--route-text); }
.rt-ttl { display: block; font-family: var(--font-display); font-size: 22px; font-weight: 600; }
.rt-tdesc { display: block; margin-top: 2px; font-size: 14.5px; color: var(--ink-muted); }
.rt-chev { width: 22px; height: 22px; color: var(--ink-muted); transition: transform 200ms var(--ease-out, ease-out); }
details[open] > summary .rt-chev { transform: rotate(180deg); }
.rt-topic-body { padding: 0 22px 22px; }
.rt-topic.is-soon > summary { cursor: default; }
.rt-topic.is-soon .rt-ttl { color: var(--ink-muted); }

.rt-cert { border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.rt-cert > summary { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 16px 18px; }
.rt-cert-k { font-family: var(--font-mono); font-size: 11.5px; font-weight: 700; letter-spacing: .14em; color: var(--premium); }
.rt-cert-t { display: block; margin-top: 2px; font-family: var(--font-display); font-size: 18px; font-weight: 600; }
.rt-cert-body { padding: 0 18px 18px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 300px); gap: 24px; }
.rt-cert-body p { margin: 0 0 12px; font-size: 15px; line-height: 24px; color: var(--ink-muted); }
.rt-domains { margin: 0; padding: 14px 16px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-raised); list-style: none; display: flex; flex-direction: column; gap: 10px; align-self: start; }
.rt-domains-k { font-family: var(--font-mono); font-size: 11px; font-weight: 700; letter-spacing: .14em; color: var(--ink-muted); }
.rt-dom { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 10px; font-size: 13px; }
.rt-dom b { font-variant-numeric: tabular-nums; font-family: var(--font-mono); font-size: 12.5px; color: var(--ink); }
.rt-dom span.bar { grid-column: 1 / -1; height: 4px; border-radius: 2px; background: var(--line); overflow: hidden; }
.rt-dom span.bar::after { content: ""; display: block; height: 100%; width: var(--w); background: var(--pilar-tecnologia); border-radius: 2px; transform-origin: left; animation: rt-bar 1.2s var(--ease-out, ease-out) .3s both; }
.rt-dom.is-here span.bar::after { background: var(--route); box-shadow: 0 0 6px var(--route); }
@keyframes rt-bar { from { transform: scaleX(0); } }

.rt-chapters { grid-column: 1 / -1; margin: 6px 0 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; }
.rt-ch { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 16px; align-items: center; padding: 16px 18px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-raised); color: var(--ink); text-decoration: none; transition: border-color 120ms linear, box-shadow 200ms var(--ease-out, ease-out), translate 200ms var(--ease-out, ease-out); }
a.rt-ch:hover, a.rt-ch:focus-visible { border-color: var(--route); box-shadow: var(--glow-route); outline: none; translate: 0 -2px; }
.rt-ch-n { width: 40px; height: 46px; display: grid; place-items: center; font-family: var(--font-mono); font-size: 15px; font-weight: 700; color: var(--route-text); background: rgba(240, 80, 58, .08); clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%); }
.rt-ch-t { display: block; font-family: var(--font-display); font-size: 17px; font-weight: 600; }
.rt-ch-d { display: block; margin-top: 2px; font-size: 14px; line-height: 21px; color: var(--ink-muted); }
.rt-ch-go { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; font-weight: 600; color: var(--route-text); white-space: nowrap; }
.rt-ch-go svg { width: 16px; height: 16px; transition: translate 200ms var(--ease-out, ease-out); }
a.rt-ch:hover .rt-ch-go svg { translate: 4px 0; }
.rt-ch.is-soon { color: var(--ink-muted); background: transparent; border-style: dashed; }
.rt-ch.is-soon .rt-ch-n { color: var(--ink-muted); background: rgba(188, 208, 234, .06); }

.rt-back { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; margin: 32px 0 72px; border: 1px solid var(--line-strong); border-radius: 4px; font-size: 14px; font-weight: 600; color: var(--ink-muted); text-decoration: none; transition: border-color 120ms linear, color 120ms linear; }
.rt-back:hover, .rt-back:focus-visible { border-color: var(--route); color: var(--ink); outline: none; }

/* Capítulo */
.ch-hero { padding: 40px 0 36px; border-bottom: 1px solid var(--line); }
.ch-hero .rt-h1 { font-size: clamp(34px, 4.6vw, 52px); }
.ch-subtitle { margin: 12px 0 0; max-width: 780px; font-size: 19px; line-height: 30px; color: var(--ink-muted); }
.ch-facts { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 18px; font-family: var(--font-mono); font-size: 12.5px; letter-spacing: .04em; color: var(--ink-muted); }
.ch-facts span { display: inline-flex; align-items: center; gap: 8px; }
.ch-facts span::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--route); }
.ch-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 56px; padding: 40px 0 24px; }
.ch-toc { position: sticky; top: 24px; align-self: start; max-height: calc(100vh - 48px); overflow: auto; }
.ch-toc-k { margin: 0 0 12px; font-family: var(--font-mono); font-size: 11.5px; font-weight: 700; letter-spacing: .14em; color: var(--ink-muted); }
.ch-toc ol { position: relative; margin: 0; padding: 0 0 0 14px; list-style: none; border-left: 2px solid var(--line); display: flex; flex-direction: column; gap: 2px; }
.ch-toc a { position: relative; display: block; padding: 6px 0; font-size: 14px; line-height: 20px; color: var(--ink-muted); text-decoration: none; transition: color 120ms linear; }
.ch-toc a::before { content: ""; position: absolute; left: -20px; top: 50%; width: 8px; height: 8px; margin-top: -4px; border-radius: 50%; background: var(--surface); border: 2px solid var(--line); transition: background-color 200ms, border-color 200ms, box-shadow 200ms; }
.ch-toc a:hover { color: var(--ink); }
.ch-toc a.is-on { color: var(--ink); }
.ch-toc a.is-on::before { background: var(--route); border-color: var(--route); box-shadow: 0 0 8px var(--route); }
.ch-toc .ch-toc-route { position: absolute; left: -2px; top: 0; width: 2px; height: 0; background: var(--route); box-shadow: 0 0 8px rgba(240, 80, 58, .6); transition: height 320ms var(--ease-out, ease-out); }

.ch-article { min-width: 0; max-width: 780px; font-size: 17px; line-height: 29px; }
.ch-sec { scroll-margin-top: 24px; padding-bottom: 28px; }
.ch-sec + .ch-sec { border-top: 1px solid var(--line); padding-top: 36px; }
.ch-article h2 { margin: 0 0 16px; font-family: var(--font-display); font-size: 28px; line-height: 1.22; font-weight: 700; letter-spacing: -.015em; }
.ch-article h3 { margin: 28px 0 10px; font-family: var(--font-display); font-size: 20px; line-height: 1.3; font-weight: 600; }
.ch-article p { margin: 0 0 16px; color: var(--ink); }
.ch-article ul, .ch-article ol { margin: 0 0 16px; padding-left: 22px; }
.ch-article li { margin: 4px 0; }
.ch-article li::marker { color: var(--route-text); }
.ch-article strong { color: var(--ink); font-weight: 600; }
.ch-article em { font-style: italic; }
.ch-article a { color: var(--link); }
.ch-article :not(pre) > code { padding: 1px 6px; border: 1px solid var(--line); border-radius: 4px; background: var(--surface-raised); font-family: var(--font-mono); font-size: .86em; font-variant-ligatures: none; overflow-wrap: anywhere; }
.ch-callout { margin: 8px 0 20px; padding: 18px 20px 6px; border: 1px solid var(--line); border-left: 3px solid var(--route); border-radius: 8px; background: var(--surface-raised); }
.ch-callout-k { display: block; margin-bottom: 8px; font-family: var(--font-mono); font-size: 11.5px; font-weight: 700; letter-spacing: .14em; color: var(--route-text); text-transform: uppercase; }
.ch-note { margin: 4px 0 20px; padding: 14px 18px; border: 1px solid rgba(221, 185, 99, .4); border-radius: 8px; background: rgba(221, 185, 99, .07); font-size: 15.5px; line-height: 26px; }
.ch-note strong { color: var(--premium); }
.ch-fig { margin: 18px 0 6px; padding: 16px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-raised); overflow-x: auto; }
.ch-fig svg { display: block; width: 100%; min-width: 560px; height: auto; }
.ch-cap { margin: 6px 0 20px !important; font-size: 13.5px !important; line-height: 21px !important; color: var(--ink-muted) !important; }
.ch-code { position: relative; margin: 6px 0 20px; padding: 40px 18px 16px; border: 1px solid var(--line); border-radius: 8px; background: #040B15; overflow-x: auto; font-family: var(--font-mono); font-size: 13.5px; line-height: 22px; color: #E6EDF6; font-variant-ligatures: none; tab-size: 2; }
.ch-code::before { content: attr(data-lang); position: absolute; top: 10px; left: 18px; font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--route-text); }
.ch-code code { font: inherit; white-space: pre; }
.ch-code .c { color: #6F87A8; }
.ch-copy { position: absolute; top: 6px; right: 8px; height: 26px; padding: 0 10px; border: 1px solid var(--line); border-radius: 4px; background: transparent; font-family: var(--font-mono); font-size: 11px; font-weight: 600; letter-spacing: .08em; color: var(--ink-muted); cursor: pointer; transition: border-color 120ms linear, color 120ms linear; }
.ch-copy:hover, .ch-copy:focus-visible { border-color: var(--route); color: var(--ink); outline: none; }
.ch-copy.is-done { border-color: var(--ok); color: var(--ok); }
.ch-table-wrap { margin: 8px 0 20px; overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; }
.ch-table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 14.5px; line-height: 22px; }
.ch-table th, .ch-table td { padding: 10px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.ch-table th { font-family: var(--font-mono); font-size: 11.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-muted); background: var(--surface-raised); }
.ch-table tr:last-child td { border-bottom: 0; }
.ch-table th code { text-transform: none; letter-spacing: 0; font-size: 12.5px; }
.ch-table td:first-child { white-space: nowrap; }
.ch-quiz { margin: 0 0 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-raised); }
.ch-quiz summary { cursor: pointer; padding: 14px 18px; font-weight: 600; list-style: none; display: flex; gap: 10px; }
.ch-quiz summary::-webkit-details-marker { display: none; }
.ch-quiz summary span { font-family: var(--font-mono); color: var(--route-text); }
.ch-quiz summary::after { content: "+"; margin-left: auto; font-family: var(--font-mono); color: var(--ink-muted); }
.ch-quiz[open] summary::after { content: "−"; }
.ch-quiz[open] { border-color: rgba(63, 203, 128, .45); }
.ch-quiz p { margin: 0; padding: 0 18px 16px; color: var(--ink-muted); }
.ch-quiz summary:focus-visible { outline: none; box-shadow: var(--focus-ring); border-radius: 8px; }
.ch-takeaways { list-style: none; padding: 0 !important; }
.ch-takeaways li { position: relative; padding-left: 28px; margin: 8px 0; }
.ch-takeaways li::before { content: ""; position: absolute; left: 4px; top: 10px; width: 10px; height: 10px; background: var(--route); clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%); }
.ch-links { list-style: none; padding: 0 !important; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.ch-links li { margin: 0; display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-raised); transition: border-color 120ms linear; }
.ch-links li:hover { border-color: var(--route); }
.ch-links a { font-weight: 600; text-decoration: none; color: var(--ink) !important; }
.ch-links a::after { content: " ↗"; color: var(--route-text); }
.ch-links span { font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .06em; color: var(--ink-muted); }
.ch-credit { margin: 8px 0 0; padding: 16px 18px; border: 1px solid var(--line); border-radius: 8px; font-size: 14px; line-height: 22px; color: var(--ink-muted); }
.ch-credit strong { color: var(--ink); }
.ch-pager { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; margin: 32px 0 72px; }
.ch-pager a, .ch-pager span { display: flex; flex-direction: column; gap: 4px; padding: 16px 18px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); text-decoration: none; transition: border-color 120ms linear, box-shadow 200ms; }
.ch-pager a:hover, .ch-pager a:focus-visible { border-color: var(--route); box-shadow: var(--glow-route); outline: none; }
.ch-pager small { font-family: var(--font-mono); font-size: 11px; font-weight: 700; letter-spacing: .14em; color: var(--ink-muted); }
.ch-pager span { border-style: dashed; color: var(--ink-muted); text-align: right; }
.ch-progress { position: fixed; top: 0; left: 0; z-index: 80; height: 3px; width: 100%; background: var(--route); box-shadow: 0 0 10px var(--route); transform-origin: left; transform: scaleX(0); }

@media (max-width: 960px) {
  .ch-layout { grid-template-columns: 1fr; gap: 8px; }
  .ch-toc { position: static; max-height: none; padding: 16px 18px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-raised); }
  .rt-cert-body { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .rt-hero { grid-template-columns: 1fr; gap: 18px; padding: 32px 0 40px; }
  .rt-hex { width: 84px; height: 96px; }
  .rt-hex svg.ic { width: 34px; height: 34px; }
  .rt-topic > summary { padding: 16px; gap: 12px; }
  .rt-topic-body { padding: 0 14px 16px; }
  .rt-ch { grid-template-columns: auto minmax(0, 1fr); }
  .rt-ch-go { grid-column: 2; }
  .ch-article { font-size: 16.5px; line-height: 28px; }
  .ch-article h2 { font-size: 24px; }
  .ch-pager { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .rt-hex svg.hx path { animation: none; stroke-dashoffset: 0; }
  .rt-status i::after, .rt-dom span.bar::after { animation: none; }
  .ch-toc .ch-toc-route { transition: none; }
}

/* Página de la ruta: consumo directo (tema › certificación › capítulos, sin acordeones) */
.rt-ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.rt-cta { display: inline-flex; align-items: center; gap: 10px; min-height: 46px; padding: 0 20px; border-radius: 4px; background: var(--route); color: var(--on-route); font-size: 15px; font-weight: 700; text-decoration: none; box-shadow: var(--glow-route); transition: filter 120ms linear, translate 200ms var(--ease-out, ease-out); }
.rt-cta svg { width: 18px; height: 18px; transition: translate 200ms var(--ease-out, ease-out); }
.rt-cta:hover, .rt-cta:focus-visible { filter: brightness(1.08); outline: none; }
.rt-cta:hover svg, .rt-cta:focus-visible svg { translate: 4px 0; }
.rt-cta2 { display: inline-flex; align-items: center; min-height: 46px; padding: 0 18px; border: 1px solid var(--line-strong); border-radius: 4px; color: var(--ink); font-size: 15px; font-weight: 600; text-decoration: none; transition: border-color 120ms linear; }
.rt-cta2:hover, .rt-cta2:focus-visible { border-color: var(--route); outline: none; }
.rt-path { scroll-margin-top: 16px; }
.rt-path-h .rt-tnum { margin: 0 0 6px; }
.rt-path-h .rt-sub { margin-bottom: 22px; }
.rt-cert2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 320px); gap: 20px 28px; padding: 24px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-raised); }
.rt-cert2-info p { margin: 0 0 10px; font-size: 15.5px; line-height: 25px; color: var(--ink-muted); }
.rt-cert2-info .rt-cert-k { margin: 0; }
.rt-cert2-info .rt-cert-t { margin: 4px 0 12px; font-size: 21px; line-height: 1.3; }
.rt-cert2 .rt-domains { background: var(--surface); }
.rt-chapters-wrap { grid-column: 1 / -1; padding-top: 8px; border-top: 1px solid var(--line); }
.rt-chapters-k { margin: 10px 0 12px; font-family: var(--font-mono); font-size: 11.5px; font-weight: 700; letter-spacing: .14em; color: var(--ink-muted); }
.rt-cert2 .rt-ch { background: var(--surface); }
.rt-h3 { margin: 0 0 14px; font-family: var(--font-display); font-size: 20px; font-weight: 600; color: var(--ink-muted); }
.rt-soon-list { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; }
.rt-soon-list li { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 14px 16px; border: 1px dashed var(--line-strong); border-radius: 8px; }
.rt-soon-list b { display: block; font-family: var(--font-display); font-size: 16px; font-weight: 600; color: var(--ink-muted); }
.rt-soon-list li > span > span { display: block; font-size: 13.5px; line-height: 20px; color: var(--ink-muted); }
.rt-upcoming { padding-top: 32px; }
@media (max-width: 860px) { .rt-cert2 { grid-template-columns: 1fr; padding: 18px; } }
@media (max-width: 520px) { .rt-soon-list { grid-template-columns: 1fr; } .rt-soon-list li { grid-template-columns: auto minmax(0, 1fr); } .rt-soon-list .rt-status { grid-column: 2; justify-self: start; } }
.rt-back svg { width: 16px; height: 16px; flex: none; }
@media (max-width: 720px) { .rt-ch.is-soon .rt-status { grid-column: 2; justify-self: start; } }
/* Tema como acordeón: el bloque de certificación vive dentro */
.rt-topic > summary .rt-tnum { align-self: start; padding-top: 6px; }
.rt-topic .rt-cert2 { background: var(--surface); }
.rt-topic .rt-cert2 .rt-domains, .rt-topic .rt-cert2 .rt-ch { background: var(--surface-raised); }
@media (max-width: 720px) { .rt-topic > summary { grid-template-columns: minmax(0, 1fr) auto; } .rt-topic > summary .rt-tnum { grid-column: 1 / -1; padding-top: 0; } }

/* Ficha del curso: misma tarjeta que los dominios, sin barra */
.rt-fact { padding: 2px 0; border-bottom: 1px dashed var(--line); }
.rt-fact:last-child { border-bottom: 0; }
.rt-fact b { font-family: var(--font-sans); font-size: 13px; font-weight: 600; text-align: right; }
.rt-topic { scroll-margin-top: 16px; }
.ch-quiz summary span + span { font-family: inherit; color: inherit; min-width: 0; }
.ch-pager a.is-next { text-align: right; align-items: flex-end; }

/* Método AGLE · etiqueta de auto-estudio y notas de estudio */
.ch-study { margin: 4px 0 20px; padding: 12px 18px; border-left: 3px solid var(--route); border-radius: 0 8px 8px 0; background: var(--surface-raised); font-size: 15.5px; line-height: 26px; }
.ch-study strong { color: var(--route-text); }
.ch-agle { margin: 22px 0; padding: 20px 22px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-raised); }
.ch-agle .ch-agle-k { margin: 0 0 12px; font-family: var(--font-mono); font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--route-text); }
.ch-article .ch-agle-l { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 0 0 14px; padding: 0; }
.ch-article .ch-agle-l li { display: flex; flex-direction: column; gap: 2px; margin: 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink-muted); font-size: 13.5px; line-height: 20px; }
.ch-article .ch-agle-l li b { font-family: var(--font-mono); font-size: 22px; line-height: 28px; color: var(--ink-muted); }
.ch-article .ch-agle-l li.is-on { border-color: var(--route); background: rgba(240, 80, 58, .08); color: var(--ink); }
.ch-article .ch-agle-l li.is-on b { color: var(--route-text); }
.ch-agle ul { margin: 8px 0 0; padding-left: 20px; }
@media (max-width: 560px) { .ch-article .ch-agle-l { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Presentaciones del capítulo (visor de diapositivas) */
.ch-deck-k { margin: 0 0 6px; font-family: var(--font-mono); font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--route-text); }
.ch-deck { margin: 18px 0 8px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-raised); overflow: hidden; }
.ch-deck-tabs { display: flex; flex-wrap: wrap; gap: 6px; padding: 10px 10px 0; }
.ch-deck-tab { padding: 8px 14px; border: 1px solid var(--line); border-bottom: 0; border-radius: 8px 8px 0 0; font-size: 14px; font-weight: 600; color: var(--ink-muted); text-decoration: none; background: transparent; cursor: pointer; font-family: inherit; }
.ch-deck-tab:hover { color: var(--ink); }
.ch-deck-tab[aria-selected="true"] { color: var(--ink); background: var(--surface); border-color: var(--line-strong); box-shadow: inset 0 2px 0 var(--route); }
.ch-deck-stage { position: relative; background: #06111F; border-top: 1px solid var(--line-strong); aspect-ratio: 16 / 9; }
.ch-deck-stage img { display: block; width: 100%; height: 100%; object-fit: contain; }
.ch-deck-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px 12px; }
.ch-deck-bar button, .ch-deck-bar a { display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px; border: 1px solid var(--line-strong); border-radius: 6px; background: var(--surface); color: var(--ink); font: 600 14px var(--font-sans); text-decoration: none; cursor: pointer; }
.ch-deck-bar button:hover, .ch-deck-bar a:hover { border-color: var(--route); }
.ch-deck-bar button:focus-visible, .ch-deck-bar a:focus-visible, .ch-deck-tab:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.ch-deck-bar .ch-deck-count { margin: 0 6px; font: 600 13px var(--font-mono); color: var(--ink-muted); font-variant-numeric: tabular-nums; }
.ch-deck-bar .sp { flex: 1; }
.ch-deck:fullscreen { display: flex; flex-direction: column; border-radius: 0; background: #06111F; }
.ch-deck:fullscreen .ch-deck-stage { flex: 1; aspect-ratio: auto; }
@media (max-width: 560px) { .ch-deck-bar .sp { display: none; } .ch-deck-bar .ch-deck-pdf, .ch-deck-bar .ch-deck-dl { flex: 1 1 40%; justify-content: center; } }

/* Método AGLE: índice en acordeón (A, G, L, E) y bandas en el cuerpo del capítulo */
.ch-toc[data-agle] ol { gap: 0; padding-left: 0; border-left: 0; }
.ch-toc-g { border-left: 2px solid var(--line); margin: 0 0 6px; }
.ch-toc-btn { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px; padding: 8px 10px 8px 12px; border: 0; border-radius: 0 8px 8px 0; background: transparent; color: var(--ink); font: 700 12px var(--font-mono); letter-spacing: .1em; text-transform: uppercase; text-align: left; cursor: pointer; }
.ch-toc-btn b { font: 700 18px/1 var(--font-display); letter-spacing: 0; color: var(--route-text); min-width: 18px; }
.ch-toc-btn span { flex: 1; }
.ch-toc-btn::after { content: ""; width: 8px; height: 8px; margin-right: 4px; border-right: 2px solid var(--ink-muted); border-bottom: 2px solid var(--ink-muted); transform: rotate(-45deg); transition: transform 200ms var(--ease-out, ease-out); }
.ch-toc-btn[aria-expanded="true"]::after { transform: rotate(45deg); }
.ch-toc-btn:hover { background: var(--surface-raised); }
.ch-toc-btn:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.ch-toc-btn.has-on { border-left: 2px solid var(--route); margin-left: -2px; }
.ch-toc-sub { list-style: none; margin: 0 0 6px 14px; padding: 0 0 0 14px; border-left: 2px solid var(--line); }
.ch-toc-sub[hidden] { display: none; }
@media (prefers-reduced-motion: reduce) { .ch-toc-btn::after { transition: none; } }
.ch-group { display: flex; align-items: center; gap: 18px; margin: 64px 0 12px; padding: 18px 22px; border: 1px solid var(--line-strong); border-left: 4px solid var(--route); border-radius: 10px; background: var(--surface-raised); scroll-margin-top: 24px; }
.ch-group:first-child { margin-top: 8px; }
.ch-group-l { font: 700 44px/1 var(--font-display); letter-spacing: -.02em; color: var(--route-text); min-width: 36px; text-align: center; }
.ch-group-b { display: flex; flex-direction: column; gap: 2px; }
.ch-group-b small { font: 700 11.5px var(--font-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--ink-muted); }
.ch-group-b strong { font: 700 22px/28px var(--font-display); color: var(--ink); }
.ch-group-b em { font-style: normal; font-size: 15px; color: var(--ink-muted); }

/* Videos de la clase: tarjetas y capa superpuesta */
.ch-vids { list-style: none; margin: 18px 0 8px; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.ch-vids > li { display: flex; }
.ch-vid { display: flex; flex-direction: column; gap: 8px; width: 100%; padding: 16px 18px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-raised); color: var(--ink); text-decoration: none; transition: border-color 160ms, transform 160ms; }
.ch-vid:hover { border-color: var(--route); transform: translateY(-2px); }
.ch-vid:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.ch-vid-k { font: 700 11.5px var(--font-mono); letter-spacing: .12em; text-transform: uppercase; color: var(--route-text); }
.ch-vid strong { font: 600 17px/24px var(--font-display); flex: 1; }
.ch-vid-m { display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--ink-muted); }
.ch-vid-m time { margin-left: auto; font: 600 12.5px var(--font-mono); font-variant-numeric: tabular-nums; }
.ch-vid-play { width: 26px; height: 26px; border-radius: 50%; background: var(--route); position: relative; flex: none; }
.ch-vid-play::after { content: ""; position: absolute; left: 10px; top: 7px; border-left: 9px solid var(--on-route); border-top: 6px solid transparent; border-bottom: 6px solid transparent; }
.ch-vid-ov { position: fixed; inset: 0; z-index: 1000; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 20px; background: rgba(3, 10, 20, .98); }
.ch-vid-ov[hidden] { display: none; }
.ch-vid-top { width: min(1100px, 100%); display: flex; align-items: center; gap: 12px; color: #F1F5FA; }
.ch-vid-top p { margin: 0; flex: 1; font: 600 16px/22px var(--font-sans); }
.ch-vid-top small { display: block; font: 700 11.5px var(--font-mono); letter-spacing: .12em; text-transform: uppercase; color: #F5654F; }
.ch-vid-x { min-height: 44px; padding: 0 18px; border: 1px solid #6B819F; border-radius: 6px; background: #0B1F3A; color: #F1F5FA; font: 600 15px var(--font-sans); cursor: pointer; }
.ch-vid-x:hover { border-color: #F0503A; }
.ch-vid-x:focus-visible { outline: none; box-shadow: 0 0 0 2px #06111F, 0 0 0 4px #8DAEDB; }
.ch-vid-box { position: relative; width: min(1100px, 100%, calc((100vh - 130px) * 16 / 9)); aspect-ratio: 16 / 9; background: #000; border: 1px solid #18396A; border-radius: 8px; overflow: hidden; }
.ch-vid-box iframe, .ch-vid-box > div { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.ch-vid-err { box-sizing: border-box; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: 24px; text-align: center; color: #DFE8F4; font-size: 18px; line-height: 28px; background: #06111F; }
.ch-vid-err a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 20px; border-radius: 6px; background: #D42A20; color: #fff; font-weight: 600; text-decoration: none; }
body.ch-vid-lock { overflow: hidden; }

/* Laboratorios de Packet Tracer: acordeón por laboratorio */
.ch-labs { display: grid; gap: 12px; margin-top: 20px; }
.ch-lab { border: 1px solid var(--line); background: var(--surface-raised); border-radius: var(--radius-md, 6px); }
.ch-lab > summary { list-style: none; cursor: pointer; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 6px 16px; align-items: center; padding: 18px 20px; min-height: 44px; }
.ch-lab > summary::-webkit-details-marker { display: none; }
.ch-lab > summary:hover { background: rgba(188, 208, 234, .04); }
.ch-lab > summary:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.ch-lab[open] { border-color: var(--line-strong); }
.ch-lab-k { font: 700 11.5px var(--font-mono); letter-spacing: .12em; text-transform: uppercase; color: var(--route-text); white-space: nowrap; }
.ch-lab > summary strong { font: 600 17px/1.3 var(--font-display); color: var(--ink); }
.ch-lab-chev { width: 10px; height: 10px; border-right: 2px solid var(--ink-muted); border-bottom: 2px solid var(--ink-muted); transform: rotate(45deg); transition: transform 200ms ease-out; margin: -4px 4px 0 0; }
.ch-lab[open] .ch-lab-chev { transform: rotate(-135deg); margin: 4px 4px 0 0; }
.ch-lab-body { padding: 0 20px 20px; border-top: 1px solid var(--line); }
.ch-lab-body > p { margin: 16px 0; color: var(--ink-muted); }
.ch-lab-dl { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.ch-lab-dl a { display: flex; align-items: center; gap: 14px; min-height: 44px; padding: 12px 14px; border: 1px solid var(--line-strong); border-radius: 4px; color: var(--ink); text-decoration: none; transition: border-color 120ms linear; }
.ch-lab-dl a:hover { border-color: var(--brand); }
.ch-lab-dl a:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.ch-lab-ext { font: 700 13px var(--font-mono); padding: 6px 8px; border-radius: 4px; background: var(--surface); color: var(--route-text); }
.ch-lab-dl small { display: block; font: 400 13px var(--font-sans); color: var(--ink-muted); margin-top: 2px; }
@media (max-width: 560px) { .ch-lab > summary { grid-template-columns: minmax(0, 1fr) auto; } .ch-lab-k { grid-column: 1; } .ch-lab > summary strong { grid-column: 1; } .ch-lab-chev { grid-column: 2; grid-row: 1 / span 2; } }

/* Evaluación del capítulo: 10 pestañas de 10 preguntas (usa el diseño .rx del reto del día) */
.ev { margin-top: 20px; }
.ev-err { padding: 14px 16px; border: 1px solid var(--crit); border-radius: 6px; background: var(--surface-raised); color: var(--crit); }
.ev-total { margin: 0 0 14px; font: 500 13.5px/1.5 var(--font-mono); color: var(--ink-muted); }
.ev-total strong { color: var(--ink); font-weight: 700; }
.ev-tabs { display: flex; gap: 8px; margin: 0 0 14px; padding: 2px 2px 8px; overflow-x: auto; scrollbar-width: thin; }
.ev-tab { flex: 0 0 auto; display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-width: 64px; min-height: 52px; padding: 6px 12px; border: 1px solid var(--line-strong); border-radius: 4px; background: var(--surface); color: var(--ink-muted); cursor: pointer; transition: border-color .2s ease, color .2s ease; }
.ev-tab:hover { border-color: var(--route); color: var(--ink); }
.ev-tab:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.ev-tab-n { font: 700 16px/1 var(--font-display); color: var(--ink); }
.ev-tab-s { font: 600 11.5px/1 var(--font-mono); letter-spacing: .06em; font-variant-numeric: tabular-nums; }
.ev-tab.is-cur { border-color: var(--route); background: var(--surface-raised); box-shadow: var(--glow-route); }
.ev-tab.is-cur .ev-tab-n { color: var(--route-text); }
.ev-tab.is-done .ev-tab-s { color: var(--ok); }
.ev-tab.is-prog .ev-tab-s { color: var(--ink); }
.ev-steps { display: grid; grid-template-columns: repeat(10, 1fr); gap: 4px; margin: 0; padding: 12px 16px 0; list-style: none; }
.ev-step { height: 6px; border-radius: 3px; background: var(--line-strong); }
.ev-step.is-now { background: var(--ink-muted); }
.ev-step.is-ok { background: var(--ok); }
.ev-step.is-bad { background: var(--crit); }
.ev-item .rx-q { outline: none; }
.ev-opts { list-style: none; margin: 4px 0 0; padding: 0; display: grid; gap: 10px; }
.ev-opt { width: 100%; display: flex; align-items: center; gap: 14px; min-height: 52px; padding: 12px 14px; border: 1px solid var(--line-strong); border-radius: 6px; background: var(--surface); color: var(--ink); font: 500 15.5px/1.45 var(--font-sans); text-align: left; cursor: pointer; transition: border-color .2s ease, background-color .2s ease; }
.ev-opt:hover { border-color: var(--route); }
.ev-opt:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.ev-opt-l { flex: 0 0 auto; display: grid; place-items: center; width: 28px; height: 28px; border: 1px solid var(--line-strong); border-radius: 4px; font: 700 13px var(--font-mono); color: var(--route-text); }
.ev-opt-t { flex: 1; min-width: 0; }
.ev-opt-tag { flex: 0 0 auto; font: 700 11px var(--font-mono); font-style: normal; letter-spacing: .1em; text-transform: uppercase; }
.ev-opt[aria-disabled="true"] { cursor: default; }
.ev-opt[aria-disabled="true"]:hover { border-color: var(--line-strong); }
.ev-opt.is-ok { border-color: var(--ok); background: rgba(77, 208, 160, .08); }
.ev-opt.is-ok:hover { border-color: var(--ok); }
.ev-opt.is-ok .ev-opt-l, .ev-opt.is-ok .ev-opt-tag { border-color: var(--ok); color: var(--ok); }
.ev-opt.is-bad, .ev-opt.is-bad:hover { border-color: var(--crit); background: var(--surface-raised); }
.ev-opt.is-bad .ev-opt-l, .ev-opt.is-bad .ev-opt-tag { border-color: var(--crit); color: var(--crit); }
.ev-fb { min-height: 8px; }
.ev-fb p { margin: 14px 0 4px; padding: 12px 14px; border-left: 3px solid var(--ok); border-radius: 0 6px 6px 0; background: rgba(77, 208, 160, .07); font-size: 15px; line-height: 24px; color: var(--ink); animation: rx-in .35s ease-out both; }
.ev-fb p.is-bad { border-left-color: var(--crit); background: var(--surface-raised); }
.ev-fb p strong:first-child { color: var(--ok); }
.ev-fb p.is-bad strong:first-child { color: var(--crit); }
.ev-nav { padding: 12px 0 18px; }
.ev-hits { font: 600 13px var(--font-mono); letter-spacing: .06em; color: var(--ink-muted); }
.ev-next:disabled { cursor: default; color: var(--ink-muted); }
.ev-next:disabled:hover { border-color: var(--line-strong); color: var(--ink-muted); }
.ev-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 40px; padding: 0 14px; border: 1px solid var(--line-strong); border-radius: 4px; background: var(--surface); color: var(--ink); font: 600 14px var(--font-sans); cursor: pointer; transition: border-color .2s ease, color .2s ease; }
.ev-btn:hover { border-color: var(--route); color: var(--route-text); }
.ev-btn:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.ev-res { padding-bottom: 2px; }
.ev-score { margin: 8px 0 0; display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px 18px; outline: none; }
.ev-score-n { font: 700 64px/1 var(--font-display); letter-spacing: -.03em; color: var(--route-text); font-variant-numeric: tabular-nums; }
.ev-score-t { font: 600 14px var(--font-mono); letter-spacing: .06em; color: var(--ink-muted); }
.ev-msg { margin: 16px 0 14px; padding: 12px 14px; border-left: 3px solid var(--ok); border-radius: 0 6px 6px 0; background: rgba(77, 208, 160, .07); font-size: 16px; line-height: 26px; color: var(--ink); }
.ev-msg-warn { border-left-color: var(--warn); background: var(--surface-raised); }
.ev-review { margin: 0 0 6px; }
.ev-miss { margin: 12px 0 0; padding: 0; list-style: none; display: grid; gap: 12px; }
.ev-miss li { padding: 12px 14px; border: 1px solid var(--line); border-left: 3px solid var(--crit); border-radius: 0 6px 6px 0; background: var(--surface-raised); font-size: 14.5px; line-height: 23px; color: var(--ink-muted); }
.ev-miss b { color: var(--ink); }
.ev-miss-a { color: var(--ink); }
.ev-nav-res { padding: 14px 0 4px; flex-wrap: wrap; }
.ev-final { margin: 14px 0 10px; padding: 14px; border: 1px solid var(--line-strong); border-radius: 6px; background: var(--surface); font-size: 15.5px; line-height: 25px; color: var(--ink); }
.ev-final .ev-btn { margin-top: 10px; display: flex; }
.ev .rx-item { padding-bottom: 0; }
@media (max-width: 520px) { .ev-score-n { font-size: 52px; } .ev-opt { font-size: 15px; padding: 11px 12px; } .ev-steps { padding: 10px 14px 0; } .ev-tab { min-width: 58px; } }
@media (prefers-reduced-motion: reduce) { .ev-fb p { animation: none; } .ev-tab, .ev-opt, .ev-btn { transition: none; } }

/* Aviso de idioma de los videos */
.ch-article .ch-vid-note { margin: 4px 0 16px; padding: 12px 16px; border: 1px solid var(--line); border-left: 3px solid var(--route); border-radius: 8px; background: var(--surface-raised); color: var(--ink); font-size: 15px; line-height: 24px; }
.ch-article .ch-vid-note strong { font-weight: 600; }

/* Navegación del capítulo: enlaces de «Lo que vas a ver» y salidas de la lectura */
.ch-callout ol a { color: var(--ink); text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--route) 45%, transparent); text-underline-offset: 3px; transition: color 120ms linear, text-decoration-color 120ms linear; }
.ch-callout ol a:hover, .ch-callout ol a:focus-visible { color: var(--route-text); text-decoration-color: var(--route); outline: none; }
.ch-toc-exits { display: flex; flex-direction: column; gap: 2px; margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.ch-toc .ch-toc-exits a { display: flex; align-items: center; gap: 8px; padding: 6px 0; font-size: 13.5px; font-weight: 600; color: var(--link); }
.ch-toc .ch-toc-exits a::before { display: none; }
.ch-toc .ch-toc-exits a:hover { color: var(--ink); }
.ch-exits { display: flex; flex-wrap: wrap; gap: 10px; margin: -48px 0 72px; }
.ch-exits a, .ch-fab nav a { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 14px; border: 1px solid var(--line-strong, var(--line)); border-radius: 6px; font-size: 14px; font-weight: 600; color: var(--ink); text-decoration: none; transition: border-color 120ms linear; }
.ch-exits a:hover, .ch-exits a:focus-visible, .ch-fab nav a:hover, .ch-fab nav a:focus-visible { border-color: var(--route); outline: none; }
.ch-fab { position: fixed; z-index: 60; left: max(16px, env(safe-area-inset-left, 0px)); bottom: calc(16px + env(safe-area-inset-bottom, 0px)); }
.ch-fab > summary { list-style: none; display: inline-flex; align-items: center; gap: 8px; min-height: 42px; padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; background: color-mix(in srgb, var(--surface-raised) 90%, transparent); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); box-shadow: var(--shadow-lg); font-size: 14px; font-weight: 600; color: var(--ink); cursor: pointer; }
.ch-fab > summary::-webkit-details-marker { display: none; }
.ch-fab > summary:hover, .ch-fab > summary:focus-visible, .ch-fab[open] > summary { border-color: var(--route); outline: none; }
.ch-fab nav { position: absolute; left: 0; bottom: calc(100% + 8px); display: flex; flex-direction: column; gap: 6px; min-width: 230px; padding: 8px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-raised); box-shadow: var(--shadow-lg); }
.ch-fab nav a { border-color: transparent; }
@media (max-width: 720px) { .ch-exits { margin-top: -56px; } .ch-exits a { flex: 1 1 calc(50% - 10px); justify-content: center; } .ch-fab > summary span { display: none; } .ch-fab > summary { padding: 0 12px; } }

/* Acceso directo al video dentro de cada tema (curso Python para todos) */
.ch-vid-inline { margin: -4px 0 16px; }
.ch-article a.ch-vid-chip, .ch-vid-chip { display: inline-flex; align-items: center; gap: 10px; padding: 7px 14px 7px 8px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface-raised); color: var(--ink); font-size: 14px; font-weight: 600; text-decoration: none; transition: border-color 160ms; }
.ch-article a.ch-vid-chip:hover, .ch-vid-chip:hover { border-color: var(--route); }
.ch-vid-chip:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.ch-vid-chip .ch-vid-play { width: 22px; height: 22px; }
.ch-vid-chip span { font-weight: 400; color: var(--ink-muted); }
.ch-vid-chip time { font: 600 12.5px var(--font-mono); font-variant-numeric: tabular-nums; color: var(--ink-muted); }
.ch-vid-chip .ch-vid-play::after { left: 8px; top: 5px; }

/* Academia · página «Rutas de aprendizaje»: tarjeta a la izquierda, explicación a la derecha */
.rl-list { display: flex; flex-direction: column; gap: 28px; margin: 8px 0 32px; }
.rl-row { display: grid; grid-template-columns: minmax(260px, 340px) 1fr; gap: 40px; align-items: center; padding: 28px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface-raised); }
.rl-card .rc-node { width: 100%; }
.rl-info { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.rl-info .rt-eyebrow { margin: 0; }
.rl-name { margin: 0; font: 700 30px/1.15 var(--font-display); letter-spacing: -.01em; }
.rl-name a { color: var(--ink); text-decoration: none; }
.rl-name a:hover { color: var(--route-text); }
.rl-txt { margin: 0; font-size: 17px; line-height: 28px; color: var(--ink-muted); max-width: 62ch; }
.rl-topics { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 8px; padding: 0; }
.rl-topics li { display: inline-flex; align-items: center; gap: 8px; padding: 6px 10px; border: 1px solid var(--line); border-radius: 6px; font-size: 14px; }
.rl-topics b { font: 700 10.5px var(--font-mono); letter-spacing: .1em; text-transform: uppercase; }
.rl-topics li.is-on b { color: var(--ok); }
.rl-topics li.is-soon { color: var(--ink-muted); }
.rl-topics li.is-soon b { color: var(--warn); }
.rl-more { margin: 0 0 56px; font-size: 15px; color: var(--ink-muted); }
@media (max-width: 820px) { .rl-row { grid-template-columns: 1fr; gap: 24px; padding: 20px; } .rl-name { font-size: 26px; } }

/* Academia · tutoriales, cursos, clases maestras y planes de carrera */
.ac-sec { margin: 8px 0 32px; padding: 28px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface-raised); }
.ac-head { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; max-width: 760px; }
.ac-head .rt-eyebrow { margin: 0; }
.ac-h2 { margin: 0; font: 700 28px/1.2 var(--font-display); letter-spacing: -.01em; }
.ac-p { margin: 0; font-size: 17px; line-height: 28px; color: var(--ink-muted); }
.ac-list { margin: 0; padding-left: 20px; font-size: 16px; line-height: 28px; }
.ac-sec .rt-ctas { margin-top: 8px; }
.tu-grid { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.tu-vid { padding: 12px 12px 14px; }
.tu-vid img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 6px; margin-bottom: 4px; }
.cu-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 20px; margin: 8px 0 24px; }
.cu-card, .pc-card { display: flex; flex-direction: column; gap: 10px; padding: 24px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface-raised); transition: border-color 160ms; }
.cu-card:hover { border-color: var(--route); }
.cu-top { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0; font: 700 11px var(--font-mono); letter-spacing: .12em; text-transform: uppercase; }
.cu-code { padding: 3px 7px; border-radius: 4px; background: var(--route); color: var(--on-route); }
.cu-route { color: var(--ink-muted); }
.cu-kind { margin-left: auto; color: var(--route-text); }
.cu-t { margin: 4px 0 0; font: 700 22px/1.25 var(--font-display); }
.cu-t a { color: var(--ink); text-decoration: none; }
.cu-t a:hover { color: var(--route-text); }
.cu-p { margin: 0; font-size: 15.5px; line-height: 25px; color: var(--ink-muted); flex: 1; }
.cu-meta { margin: 0; font: 600 12.5px var(--font-mono); color: var(--ink-muted); }
.cu-ctas { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.pc-card { max-width: 620px; margin: 20px 0; }
.pc-path { display: flex; align-items: center; gap: 8px; margin: 0; font: 700 14px var(--font-mono); letter-spacing: .08em; }
.pc-path span { padding: 5px 9px; border: 1px solid var(--route); border-radius: 6px; color: var(--route-text); }
.pc-path i { font-style: normal; color: var(--ink-muted); }
.pc-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 6px 0 0; }
.pc-facts div { padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; }
.pc-facts dt { font: 700 10.5px var(--font-mono); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-muted); }
.pc-facts dd { margin: 4px 0 0; font-size: 14.5px; font-weight: 600; }
@media (max-width: 640px) { .ac-sec { padding: 20px; } .pc-facts { grid-template-columns: 1fr; } .cu-grid { grid-template-columns: 1fr; } }

/* Rutas de aprendizaje: filtro por ruta y buscador (estilos de blog.css) */
.rl-row[hidden] { display: none; }
.rl-row.is-soon { background: transparent; }
.rl-row.is-soon .rl-card { opacity: .85; }
.rl-soon { margin: 4px 0 0; }
.rl-list .bl-empty { margin: 0; }

/* Academia: elementos filtrados por ruta */
.cu-card[hidden], .pc-card[hidden] { display: none; }
.ac-list-f { margin: 0 0 20px; }
.cu-grid .bl-empty { grid-column: 1 / -1; }
