/* ── Páginas propias del Disector (hub, combo) y tarjeta promocional de la portada ───────────── */
.toracles-v2.td-page,
.toracles-v2.td-promo { min-height: 0; background: none; }
.td-page { --td-serif: "Instrument Serif", "Toracles Fell", Georgia, serif; --td-mono: "Toracles Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; padding: clamp(18px, 3vw, 32px) clamp(16px, 3vw, 28px) 72px; }
.td-wrap, .td-layout { max-width: 1180px; margin: 0 auto; }
.td-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.td-eyebrow { font: 0.68rem/1.4 var(--td-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold); margin: 0; }
.td-badge { display: inline-block; padding: 3px 8px; border: 1px dashed rgba(205, 176, 122, 0.55); background: rgba(205, 176, 122, 0.08); color: var(--gold); font: 0.62rem var(--td-mono); letter-spacing: 0.15em; text-transform: uppercase; }
.td-crumbs { margin: 0 0 14px; font: 0.68rem var(--td-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.td-crumbs a { color: var(--gold); text-decoration: none; }
.td-crumbs a:hover { text-decoration: underline; }
.td-h1 { margin: 8px 0 12px; font: 400 clamp(2.1rem, 5.2vw, 3.7rem)/1.04 var(--td-serif); color: var(--ivory); }
.td-h1 em { color: var(--gold); font-style: italic; }
.td-h2 { margin: 4px 0 8px; font: 400 clamp(1.6rem, 3vw, 2.1rem)/1.1 var(--td-serif); color: var(--ivory); }
.td-lead { max-width: 40rem; margin: 0 0 6px; color: var(--muted); font-size: 1.12rem; }
.td-lead-sm { font-size: 1rem; }
.td-plus { color: var(--gold); }
.td-pips { display: inline-flex; gap: 3px; align-items: center; }
.td-pip { display: inline-block; width: 10px; height: 10px; border-radius: 50%; border: 1px solid rgba(0, 0, 0, 0.4); }
.td-pip-W { background: #f1e8c8; } .td-pip-U { background: #5b8bc7; } .td-pip-B { background: #6b5a6e; } .td-pip-R { background: #c9564a; } .td-pip-G { background: #5d9b64; }
.td-colorless { font: 0.68rem var(--td-mono); color: var(--muted); letter-spacing: 0.08em; }

/* hub */
.td-hero { display: grid; grid-template-columns: 1.4fr 1fr; gap: 30px; align-items: end; padding: 14px 0 24px; margin-bottom: 22px; border-bottom: 1px solid var(--line); }
.td-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; margin: 0; background: var(--line); border: 1px solid var(--line); }
.td-stats > div { background: var(--surface-2); padding: 14px 16px; }
.td-stats dt { order: 2; font: 0.62rem var(--td-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.td-stats dd { margin: 0 0 4px; font: 400 2rem/1 var(--td-serif); color: var(--gold); }
.td-stats > div { display: flex; flex-direction: column; }
.td-controls { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; margin-bottom: 14px; }
.td-search { flex: 1; min-width: 220px; }
.td-search input { width: 100%; min-height: 44px; padding: 10px 12px; background: #07070a; border: 1px solid var(--line); color: var(--ivory); font: 1rem "Source Serif 4", Georgia, serif; }
.td-search input:focus { border-color: var(--gold); outline: none; }
.td-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.toracles-v2 .td-chip { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 11px; color: var(--text); font-size: 0.66rem; }
.toracles-v2 .td-chip[aria-pressed="true"] { background: var(--gold); border-color: var(--gold); color: var(--bg); }
.td-sort { display: inline-flex; align-items: center; gap: 10px; color: var(--muted); font: 0.66rem var(--td-mono); letter-spacing: 0.12em; text-transform: uppercase; }
.td-sort select { padding: 8px 10px; border: 1px solid var(--line); background: #07070a; color: var(--text); font: inherit; }
.td-range { margin: 0 0 12px; font: 0.68rem var(--td-mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.td-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 0; padding: 0; list-style: none; }
.td-grid > li { margin: 0; padding: 0; display: flex; }
.td-grid > li[hidden] { display: none; }
.toracles-v2 a.td-card { display: flex; flex-direction: column; gap: 9px; width: 100%; min-height: 190px; padding: 16px; background: var(--surface); border: 1px solid var(--line); color: inherit; text-decoration: none; transition: border-color 0.15s, transform 0.15s; }
.toracles-v2 a.td-card:hover, .toracles-v2 a.td-card:focus-visible { border-color: var(--gold); transform: translateY(-2px); }
.td-card-top { display: flex; justify-content: space-between; align-items: center; }
.td-card-title { margin: 0; font: 400 1.35rem/1.2 var(--td-serif); color: var(--ivory); }
.td-card-lead { flex: 1; margin: 0; color: var(--muted); font-style: italic; font-size: 0.95rem; }
.td-card-foot { display: flex; justify-content: space-between; gap: 10px; padding-top: 9px; border-top: 1px solid var(--line); font: 0.64rem var(--td-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.td-card-foot b { color: var(--gold); font-weight: 400; }
.td-pager { display: flex; gap: 6px; justify-content: center; margin: 22px 0; }
.toracles-v2 .td-pager button { min-width: 36px; min-height: 36px; padding: 0 8px; color: var(--text); }
.toracles-v2 .td-pager button[aria-current="page"] { background: var(--gold); border-color: var(--gold); color: var(--bg); }
.toracles-v2 .td-pager button:disabled { opacity: 0.35; cursor: default; }
.td-band { display: grid; grid-template-columns: 1fr 1.3fr; gap: 24px; margin-top: 30px; padding: 22px; border: 1px solid var(--line); background: var(--surface-2); }
.td-band .combo-detector { margin: 0; }
.td-notebook-hub { margin-top: 30px; padding-top: 24px; border-top: 1px solid var(--line); scroll-margin-top: 90px; }
.td-nb-list { margin: 12px 0 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.td-nb-list li { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 10px 14px; border: 1px solid var(--line); background: var(--surface); }
.td-nb-list a { color: var(--ivory); text-decoration: none; }
.td-nb-list a:hover { color: var(--gold); }
.td-nb-list small { font: 0.66rem var(--td-mono); letter-spacing: 0.06em; color: var(--muted); }
.td-nb-empty { color: var(--muted); margin: 12px 0 0; }
.td-nb-empty[hidden] { display: none; }

/* combo: lectura larga */
.td-layout { display: grid; grid-template-columns: 220px minmax(0, 760px); gap: 48px; justify-content: center; }
.td-rail { position: sticky; top: 92px; align-self: start; display: grid; gap: 14px; }
.td-prog { height: 3px; background: var(--line); }
.td-prog i { display: block; height: 100%; width: 0; background: var(--gold); transition: width 0.2s; }
.td-rail ol { margin: 0; padding: 0; list-style: none; border-left: 1px solid var(--line); }
.td-rail li a { display: block; margin-left: -1px; padding: 8px 14px; border-left: 2px solid transparent; color: var(--muted); text-decoration: none; font-size: 0.95rem; }
.td-rail li a:hover { color: var(--ivory); }
.td-rail li a.is-on { border-left-color: var(--gold); color: var(--ivory); }
.td-rail li a span { margin-right: 8px; font: 0.64rem var(--td-mono); letter-spacing: 0.1em; color: var(--gold); }
.td-pick { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 18px; padding: 14px 16px; border: 1px solid var(--line); background: var(--surface-2); }
.td-pick .combo-menu { margin: 0; }
.td-or { font: 0.66rem var(--td-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.td-detect-inline { flex: 1 1 100%; }
.td-detect-inline summary { display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border: 1px solid var(--line); color: var(--ivory); font: 0.72rem var(--td-mono); letter-spacing: 0.12em; text-transform: uppercase; cursor: pointer; }
.td-detect-inline summary:hover { border-color: var(--gold); }
.td-detect-inline[open] summary { border-color: var(--gold); margin-bottom: 12px; }
.td-detect-inline .combo-detector { margin: 0; }
.td-pick .combo-menu[hidden] + .td-or { display: none; }
.td-manifesto { max-width: 38rem; color: var(--muted); font-style: italic; }
.td-meta { margin: 6px 0 0; color: var(--muted); font-size: 0.95rem; }
.td-share { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.td-section { padding-top: 38px; scroll-margin-top: 92px; }
.td-section > h2, .td-notebook > h2 { display: flex; gap: 12px; align-items: baseline; margin: 0 0 14px; font: 400 clamp(1.6rem, 3vw, 2rem)/1.1 var(--td-serif); color: var(--ivory); }
.td-section > h2 span, .td-notebook > h2 span { font: 0.68rem var(--td-mono); letter-spacing: 0.14em; color: var(--gold); }
.td-pieces { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.td-piece { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); overflow: hidden; }
.td-piece img { width: 100%; max-height: 240px; object-fit: cover; object-position: top; border-bottom: 1px solid var(--line); }
.td-piece-body { padding: 14px 16px 16px; display: grid; gap: 6px; }
.td-piece-body h3 { margin: 0; font: 400 1.3rem/1.2 "Source Serif 4", Georgia, serif; color: var(--ivory); }
.td-piece-body p { margin: 0; }
.td-piece-body dl { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; margin: 6px 0 0; font-size: 0.92rem; }
.td-piece-body dt { padding-top: 3px; font: 0.62rem var(--td-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--gold); }
.td-piece-body dd { margin: 0; color: var(--muted); }
.td-steps { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; counter-reset: td; }
.td-step { position: relative; padding: 16px 18px 16px 64px; background: var(--surface); border: 1px solid var(--line); counter-increment: td; }
.td-step::before { content: counter(td); position: absolute; left: 18px; top: 14px; font: 400 1.9rem var(--td-serif); color: var(--gold); }
.td-steps-resp .td-step::before { content: "↯"; font-size: 1.6rem; }
.td-step h3 { margin: 0 0 4px; font: 400 1.5rem/1.15 var(--td-serif); color: var(--ivory); }
.td-step p { margin: 0; }
.td-cond-base { margin: 0 0 12px; padding: 8px 14px; border-left: 2px solid var(--gold); background: rgba(205, 176, 122, 0.05); color: var(--muted); }
.td-cond-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.td-cond { padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); }
.td-cond h3 { margin: 0 0 4px; font: 0.7rem var(--td-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--gold); }
.td-cond p { margin: 0; }
.td-quiz { padding: 4px 0; }
.td-nb-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.td-nb-writer, .td-nb-saved { padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); }
.td-nb-writer h3, .td-nb-saved h3 { margin: 0 0 6px; font: 0.7rem var(--td-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--gold); }
.td-progress { margin-top: 14px; display: grid; gap: 6px; }
.td-progress label { display: flex; gap: 8px; align-items: center; color: var(--text); }
.td-next-list { margin: 0 0 14px; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.toracles-v2 a.td-next { display: block; padding: 14px; background: var(--surface); border: 1px solid var(--line); color: var(--ivory); text-decoration: none; }
.toracles-v2 a.td-next:hover { border-color: var(--gold); }
.td-next small { display: block; margin-bottom: 4px; font: 0.62rem var(--td-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--gold); }

/* tarjeta promocional de la portada */
.td-promo { position: relative; display: grid; grid-template-columns: 1.1fr 0.9fr; gap: clamp(24px, 4vw, 56px); align-items: center; max-width: 1180px; margin: 0 auto; padding: clamp(24px, 4vw, 48px); border: 1px solid var(--line); background: radial-gradient(700px 360px at 85% 20%, rgba(205, 176, 122, 0.14), transparent 70%), linear-gradient(180deg, rgba(19, 19, 24, 0.92), rgba(10, 10, 12, 0.96)); overflow: hidden; }
.td-promo-eyebrow { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; font: 0.7rem var(--td-mono, monospace); letter-spacing: 0.16em; text-transform: uppercase; color: var(--gold); }
.td-dot { width: 8px; height: 8px; background: var(--gold); transform: rotate(45deg); box-shadow: 0 0 12px rgba(205, 176, 122, 0.8); animation: td-pulse 2.4s ease-in-out infinite; }
@keyframes td-pulse { 50% { opacity: 0.35; } }
.td-promo-title { margin: 0 0 14px; font: 400 clamp(2.2rem, 5vw, 3.8rem)/1.02 "Instrument Serif", "Toracles Fell", Georgia, serif; color: var(--ivory); }
.td-promo-title em { color: var(--gold); }
.td-promo-lead { max-width: 34rem; margin: 0 0 18px; color: var(--muted); font-size: 1.15rem; }
.td-promo-points { margin: 0 0 22px; padding: 0; list-style: none; display: grid; gap: 8px; }
.td-promo-points li { position: relative; padding-left: 22px; color: var(--text); }
.td-promo-points li::before { content: ""; position: absolute; left: 3px; top: 0.6em; width: 7px; height: 7px; background: var(--gold); transform: rotate(45deg); }
.td-promo-points b { color: var(--ivory); }
.td-promo-cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.toracles-v2 a.td-btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 0 24px; font: 0.76rem "Toracles Mono", ui-monospace, monospace; letter-spacing: 0.14em; text-transform: uppercase; text-decoration: none; transition: transform 0.15s, background 0.15s, border-color 0.15s; }
.toracles-v2 a.td-btn-primary { background: var(--gold); color: #17120a; font-weight: 700; box-shadow: 0 8px 28px rgba(205, 176, 122, 0.25); }
.toracles-v2 a.td-btn-primary:hover, .toracles-v2 a.td-btn-primary:focus-visible { background: #e2c690; transform: translateY(-2px); }
.toracles-v2 a.td-btn-ghost { border: 1px solid var(--line); color: var(--ivory); }
.toracles-v2 a.td-btn-ghost:hover, .toracles-v2 a.td-btn-ghost:focus-visible { border-color: var(--gold); }
.td-promo-proof { margin: 16px 0 0; color: var(--muted); font: 0.7rem "Toracles Mono", ui-monospace, monospace; letter-spacing: 0.08em; text-transform: uppercase; }
.td-promo-proof b { color: var(--gold); font-weight: 400; }
.td-promo-visual { position: relative; display: grid; gap: 18px; justify-items: center; }
.td-fan { position: relative; width: min(100%, 360px); aspect-ratio: 1 / 1.05; }
.td-fan-card { position: absolute; width: 56%; aspect-ratio: 900 / 1220; border: 1px solid rgba(205, 176, 122, 0.45); background: var(--surface); box-shadow: 0 18px 40px rgba(0, 0, 0, 0.55); overflow: hidden; transition: transform 0.35s ease; }
.td-fan-card img { width: 100%; height: 100%; object-fit: cover; }
.td-fan-1 { left: 0; top: 10%; transform: rotate(-9deg); }
.td-fan-2 { left: 22%; top: 0; transform: rotate(0deg); z-index: 2; }
.td-fan-3 { right: 0; top: 10%; transform: rotate(9deg); }
.td-promo:hover .td-fan-1 { transform: rotate(-14deg) translateX(-8px); }
.td-promo:hover .td-fan-3 { transform: rotate(14deg) translateX(8px); }
.td-promo:hover .td-fan-2 { transform: translateY(-8px); }
.toracles-v2 a.td-teaser { display: grid; gap: 6px; width: min(100%, 380px); padding: 14px 16px; border: 1px solid var(--gold); background: rgba(10, 10, 12, 0.85); color: var(--text); text-decoration: none; transition: transform 0.15s, background 0.15s; }
.toracles-v2 a.td-teaser:hover, .toracles-v2 a.td-teaser:focus-visible { transform: translateY(-2px); background: rgba(205, 176, 122, 0.1); }
.td-teaser-tag { font: 0.62rem "Toracles Mono", ui-monospace, monospace; letter-spacing: 0.16em; text-transform: uppercase; color: var(--gold); }
.td-teaser-q b { color: var(--ivory); }
.td-teaser-go { font: 0.68rem "Toracles Mono", ui-monospace, monospace; letter-spacing: 0.1em; text-transform: uppercase; color: var(--gold); }
@media (prefers-reduced-motion: reduce) { .td-dot { animation: none; } .td-fan-card, .toracles-v2 a.td-card, .toracles-v2 a.td-btn { transition: none; } }

@media (max-width: 900px) {
	.td-hero, .td-band, .td-promo { grid-template-columns: minmax(0, 1fr); }
	.td-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.td-layout { grid-template-columns: minmax(0, 1fr); gap: 20px; }
	.td-rail { position: static; }
	.td-rail ol { display: flex; overflow-x: auto; border-left: 0; border-bottom: 1px solid var(--line); }
	.td-rail li a { white-space: nowrap; margin: 0; border-left: 0; border-bottom: 2px solid transparent; }
	.td-rail li a.is-on { border-bottom-color: var(--gold); }
	.td-nb-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
	.td-grid { grid-template-columns: minmax(0, 1fr); }
	.td-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.td-step { padding-left: 54px; }
	.td-fan { width: min(100%, 300px); }
}
@media print {
	.td-rail, .td-pick, .td-share, .td-detect-inline, .combo-menu { display: none !important; }
	.td-layout { display: block; }
}

/* ── Ajustes de espaciado y jerarquía (el tema reinicia márgenes y fuentes de botones) ───────── */
.td-page .td-badge { margin-bottom: 10px; }
.td-page .td-h1 { margin: 12px 0 14px; font-size: clamp(2rem, 4.4vw, 3.2rem); }
.td-page .td-hero { align-items: center; }
.td-page .td-stats { grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); }
.td-page .td-controls { margin: 4px 0 16px; }
.td-page .td-range { margin: 14px 0 12px; }
.toracles-v2 .td-chip { border-color: rgba(205, 176, 122, 0.4); }
.toracles-v2 .td-share .button, .toracles-v2 .td-pick .td-detect-inline summary { border: 1px solid rgba(205, 176, 122, 0.5); padding: 0 16px; min-height: 44px; display: inline-flex; align-items: center; background: transparent; color: var(--ivory); font: 0.72rem "Toracles Mono", ui-monospace, monospace; letter-spacing: 0.12em; text-transform: uppercase; cursor: pointer; }
.toracles-v2 .td-share .button:hover, .toracles-v2 .td-share .button:focus-visible { border-color: var(--gold); }
.toracles-v2 .td-pick .combo-menu-btn { font: 0.72rem/1 "Toracles Mono", ui-monospace, monospace; letter-spacing: 0.12em; text-transform: uppercase; }
.td-page .td-pick { align-items: center; }
.td-page .td-meta { margin: 12px 0 0; }
.td-page .td-share { margin-top: 16px; }
.td-page .td-manifesto { margin: 10px 0 0; }
.td-page .td-lead { margin-top: 4px; }
.td-promo .td-promo-eyebrow { margin: 0 0 16px; }
.td-promo .td-promo-title { margin: 0 0 18px; }
.td-promo .td-promo-lead { margin: 0 0 22px; }
.td-promo .td-promo-points { margin: 0 0 28px; gap: 10px; }
.td-promo .td-promo-cta { margin: 0; }
.td-promo .td-promo-proof { margin: 18px 0 0; }
.td-promo-visual .td-teaser { margin-top: 6px; }
.td-promo .td-fan { margin-bottom: 4px; }
