/* Quaerion Index — camada editorial e analítica. */
.idx-page { --idx-panel: rgba(9, 9, 13, .88); --idx-purple-2: #9b87ff; }
.idx-page section { overflow: clip; }
.idx-page .container { max-width: 1360px; }

.idx-hero { padding: clamp(4.5rem, 9vw, 8rem) 0 3.5rem; }
.idx-hero::after { content:""; position:absolute; width:min(760px,76vw); aspect-ratio:1; right:-24%; top:-42%; border-radius:50%; background:radial-gradient(circle,rgba(123,97,255,.2),transparent 66%); filter:blur(8px); pointer-events:none; }
.idx-hero-grid { display:grid; gap:2rem; align-items:end; }
.idx-hero-copy { max-width:900px; }
.idx-live { display:inline-flex; align-items:center; gap:.55rem; margin-bottom:1.1rem; padding:.45rem .72rem; border:1px solid rgba(167,139,250,.28); border-radius:999px; color:#d9d1ff; background:rgba(123,97,255,.08); font:500 .68rem/1 var(--font-mono); letter-spacing:.08em; text-transform:uppercase; }
.idx-live::before { content:""; width:.48rem; height:.48rem; border-radius:50%; background:#a78bfa; box-shadow:0 0 0 5px rgba(167,139,250,.1),0 0 18px rgba(167,139,250,.8); }
.idx-hero h1 { max-width:14ch; font-size:clamp(3rem,7vw,6.6rem); line-height:.94; letter-spacing:-.055em; }
.idx-hero .lede { max-width:790px; margin-top:1.5rem; font-size:clamp(1.08rem,2vw,1.32rem); color:var(--text-75); line-height:1.62; }
.idx-actions { display:flex; flex-wrap:wrap; gap:.65rem; margin-top:1.7rem; }
.idx-action { display:inline-flex; align-items:center; justify-content:center; min-height:44px; padding:.72rem 1rem; border:1px solid var(--border-15); border-radius:8px; background:var(--glass-5); color:var(--text-75); font:500 .75rem/1 var(--font-mono); cursor:pointer; transition:.2s; }
.idx-action:hover,.idx-action:focus-visible { color:#fff; border-color:rgba(167,139,250,.55); background:rgba(123,97,255,.1); outline:none; }
.idx-action.primary { background:#f5f3ff; color:#0a0810; border-color:#f5f3ff; }
.idx-action.primary:hover { background:#dcd4ff; color:#0a0810; }
.idx-action[disabled] { opacity:.45; cursor:progress; }

.idx-hero-metrics { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); border:1px solid var(--border-10); border-radius:18px; background:linear-gradient(145deg,rgba(255,255,255,.055),rgba(255,255,255,.018)); overflow:hidden; }
.idx-hero-metric { min-width:0; padding:1.25rem; border-right:1px solid var(--border-10); border-bottom:1px solid var(--border-10); }
.idx-hero-metric:nth-child(2n) { border-right:0; }
.idx-hero-metric:nth-last-child(-n+2) { border-bottom:0; }
.idx-hero-metric strong { display:block; font:600 clamp(1.75rem,4vw,2.8rem)/1 var(--font-display); letter-spacing:-.04em; color:#fff; }
.idx-hero-metric span { display:block; margin-top:.5rem; color:var(--text-55); font-size:.78rem; line-height:1.45; }
.idx-snapshot { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:.8rem; margin-top:1rem; padding:.75rem 1rem; border-left:2px solid var(--quaerion-purple); background:rgba(123,97,255,.055); color:var(--text-55); font:.7rem/1.55 var(--font-mono); }
.idx-snapshot b { color:#e1dcff; font-weight:500; }

.idx-section-head { display:flex; align-items:end; justify-content:space-between; gap:1.5rem; margin-bottom:2rem; }
.idx-section-head > div { max-width:780px; }
.idx-section-head h2 { margin-top:.8rem; }
.idx-section-head p { margin-top:1rem; color:var(--text-75); font-size:1.03rem; max-width:74ch; }
.idx-section-note { max-width:310px; color:var(--text-40); font:.68rem/1.6 var(--font-mono); text-align:right; }

.idx-dashboard-grid { display:grid; gap:1rem; grid-template-columns:repeat(12,minmax(0,1fr)); }
.idx-panel { grid-column:span 12; min-width:0; border:1px solid var(--border-10); border-radius:16px; background:var(--idx-panel); padding:clamp(1.2rem,3vw,1.7rem); }
.idx-panel-head { display:flex; align-items:flex-start; justify-content:space-between; gap:1rem; margin-bottom:1.4rem; }
.idx-panel-head h3 { font-size:1.15rem; line-height:1.2; }
.idx-panel-head p { max-width:58ch; margin-top:.38rem; color:var(--text-55); font-size:.82rem; line-height:1.55; }
.idx-panel-badge { flex:0 0 auto; padding:.32rem .5rem; border:1px solid var(--border-10); border-radius:999px; color:var(--text-40); font:.62rem/1 var(--font-mono); }
.idx-chart-source { margin-top:1.15rem; padding-top:.8rem; border-top:1px solid var(--border-10); color:var(--text-40); font:.64rem/1.55 var(--font-mono); }

.idx-bars { display:grid; gap:.9rem; }
.idx-bar-row { display:grid; grid-template-columns:minmax(130px,1.2fr) minmax(110px,3fr) auto; align-items:center; gap:.8rem; }
.idx-bar-row .label { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color:var(--text-75); font-size:.82rem; }
.idx-bar-row .track { height:8px; border-radius:999px; background:rgba(255,255,255,.065); overflow:hidden; }
.idx-bar-row .track > span { display:block; width:var(--size,0%); height:100%; border-radius:inherit; background:var(--bar-color,var(--quaerion-purple)); transform-origin:left; }
.idx-bar-row .value { min-width:3rem; color:#fff; font:500 .72rem/1 var(--font-mono); text-align:right; }
.idx-bar-row.subtle .track > span { background:#6f667f; }

.idx-model-cards { display:grid; gap:.8rem; }
.idx-model { padding:1rem; border:1px solid var(--border-10); border-radius:12px; background:rgba(255,255,255,.025); }
.idx-model-top { display:flex; align-items:center; justify-content:space-between; gap:1rem; }
.idx-model-top span { color:var(--text-55); font:.68rem var(--font-mono); text-transform:uppercase; letter-spacing:.09em; }
.idx-model-top strong { font:600 1.55rem/1 var(--font-display); }
.idx-model .track { height:5px; margin-top:.8rem; background:rgba(255,255,255,.07); border-radius:999px; overflow:hidden; }
.idx-model .track span { display:block; width:var(--size,0%); height:100%; background:var(--model-color,var(--quaerion-purple)); border-radius:inherit; }
.idx-model small { display:block; margin-top:.55rem; color:var(--text-40); font-size:.7rem; }

.idx-distribution { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:.7rem; align-items:end; min-height:190px; }
.idx-dist-col { display:flex; flex-direction:column; justify-content:flex-end; min-width:0; height:100%; }
.idx-dist-value { margin-bottom:.55rem; color:#fff; font:600 1.2rem/1 var(--font-display); }
.idx-dist-track { display:flex; align-items:end; height:115px; padding:.35rem; border-radius:9px; background:rgba(255,255,255,.035); }
.idx-dist-fill { width:100%; height:var(--size,0%); min-height:3px; border-radius:6px; background:#7b61ff; border:1px solid rgba(255,255,255,.14); }
.idx-dist-col:nth-child(2) .idx-dist-fill { background:#856eff; }
.idx-dist-col:nth-child(3) .idx-dist-fill { background:#927dff; }
.idx-dist-col:nth-child(4) .idx-dist-fill { background:#a78bfa; }
.idx-dist-label { margin-top:.6rem; color:var(--text-55); font:.64rem/1.35 var(--font-mono); }

.idx-movement { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:.7rem; }
.idx-move { min-width:0; padding:1rem; border:1px solid var(--border-10); border-radius:12px; background:rgba(255,255,255,.025); }
.idx-move strong { display:block; font:600 1.75rem/1 var(--font-display); }
.idx-move span { display:block; margin-top:.42rem; color:var(--text-55); font-size:.76rem; }
.idx-move.up strong { color:#a78bfa; }
.idx-move.down strong { color:#cac2d6; }

.idx-cohort-grid { display:grid; gap:1rem; }
.idx-cohort-metric { min-width:0; padding:1rem; border:1px solid var(--border-10); border-radius:12px; background:rgba(255,255,255,.02); }
.idx-cohort-metric > span { display:block; margin-bottom:.9rem; color:var(--text-75); font-size:.82rem; }
.idx-cohort-bars { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); align-items:end; gap:.7rem; min-height:126px; }
.idx-cohort-bars i { display:flex; flex-direction:column; justify-content:flex-end; min-height:36px; height:var(--size,0%); max-height:110px; padding:.55rem; border:1px solid rgba(167,139,250,.22); border-radius:8px 8px 4px 4px; background:#7562da; font-style:normal; }
.idx-cohort-bars i:nth-child(2) { background:#9b87ff; }
.idx-cohort-bars b { color:#fff; font:600 .88rem/1 var(--font-display); }
.idx-cohort-bars small { margin-top:.3rem; color:rgba(255,255,255,.65); font:.58rem/1 var(--font-mono); text-transform:uppercase; }

.idx-workbench { border:1px solid var(--border-10); border-radius:18px; background:linear-gradient(180deg,rgba(123,97,255,.055),rgba(255,255,255,.015)); overflow:hidden; }
.idx-filter-head { padding:1.3rem clamp(1rem,3vw,1.6rem); border-bottom:1px solid var(--border-10); }
.idx-filter-head label { display:block; color:var(--text-55); font:.65rem/1 var(--font-mono); letter-spacing:.12em; text-transform:uppercase; }
.idx-chips { display:flex; gap:.5rem; margin-top:.85rem; padding-bottom:.15rem; overflow-x:auto; scrollbar-width:thin; }
.idx-chips .chip { flex:0 0 auto; color:var(--text-55); background:rgba(0,0,0,.2); border-color:var(--border-10); }
.idx-chips .chip.active { color:#0b0910; background:#f4f1ff; border-color:#f4f1ff; }
.idx-selected { padding:clamp(1.2rem,3vw,1.8rem); }
.idx-selected-head { display:flex; align-items:start; justify-content:space-between; gap:1rem; margin-bottom:1.3rem; }
.idx-selected-head h3 { margin-top:.4rem; font-size:clamp(1.45rem,3vw,2.1rem); }
.idx-round { color:var(--text-40); font:.68rem/1.5 var(--font-mono); text-align:right; }
.idx-selected-grid { display:grid; gap:1rem; }
.idx-summary { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:.7rem; }
.idx-card { min-width:0; padding:1rem; border:1px solid var(--border-10); border-radius:12px; background:rgba(0,0,0,.18); }
.idx-card small { display:block; color:var(--text-40); font:.61rem/1.3 var(--font-mono); letter-spacing:.1em; text-transform:uppercase; }
.idx-card strong { display:block; margin-top:.55rem; color:#fff; font:600 clamp(1.15rem,3vw,1.65rem)/1.1 var(--font-display); overflow-wrap:anywhere; }
.idx-card span { display:block; margin-top:.38rem; color:var(--text-55); font-size:.72rem; line-height:1.4; }

.idx-leader-viz { display:grid; grid-template-columns:auto 1fr; align-items:center; gap:1.25rem; padding:1.15rem; border:1px solid rgba(167,139,250,.2); border-radius:14px; background:rgba(123,97,255,.055); }
.idx-donut { --value:0; display:grid; width:112px; aspect-ratio:1; place-items:center; border-radius:50%; background:conic-gradient(#9b87ff calc(var(--value) * 1%),rgba(255,255,255,.07) 0); position:relative; }
.idx-donut::after { content:""; position:absolute; width:78%; aspect-ratio:1; border-radius:50%; background:#09080e; border:1px solid var(--border-10); }
.idx-donut span { position:relative; z-index:1; font:600 1.25rem/1 var(--font-display); }
.idx-leader-bars { display:grid; gap:.72rem; min-width:0; }
.idx-leader-bars .idx-bar-row { grid-template-columns:76px minmax(80px,1fr) auto; }

.rank-table td:first-child { width:2.5rem; color:var(--violet-glow); font-family:var(--font-mono); }
.rank-brand { color:#fff; font-family:var(--font-display); font-weight:600; }
.rank-brand a { color:inherit; border-bottom:1px solid var(--border-15); }
.ment { display:flex; align-items:center; gap:.5rem; min-width:120px; }
.ment .bar { flex:1; height:6px; border-radius:999px; background:var(--border-10); overflow:hidden; }
.ment .bar span { display:block; height:100%; background:#8e78ff; }
.ment .num,.score,.plat,.var { font-family:var(--font-mono); font-variant-numeric:tabular-nums; }
.ment .num,.plat,.var { color:var(--text-55); font-size:.74rem; }
.score { color:#d6ceff; font-weight:600; }
.var.up { color:#b9abff; }.var.down { color:#b8afc5; }.var.new { color:#d7cfff; }.var.same { color:var(--text-40); }
.top1 td { background:rgba(123,97,255,.075); }
.rank-table .heat { --heat:0; background:color-mix(in oklab,#7b61ff calc(var(--heat) * .15%),transparent); }
.idx-empty { padding:3rem 1rem!important; text-align:center!important; color:var(--text-55)!important; }
.prompts { display:flex; flex-wrap:wrap; gap:.5rem; margin-top:.8rem; }
.prompt { padding:.5rem .75rem; border:1px solid var(--border-10); border-radius:7px; background:rgba(255,255,255,.025); color:var(--text-75); font:.72rem/1.35 var(--font-mono); }
.idx-source { margin-top:1rem; color:var(--text-40); font:.66rem/1.65 var(--font-mono); }

.idx-leader-table td { vertical-align:middle; }
.idx-rank-pill { display:inline-grid; min-width:2rem; height:2rem; place-items:center; border:1px solid var(--border-10); border-radius:50%; color:var(--text-55); font:.68rem var(--font-mono); }
.idx-score-cell { min-width:150px; }
.idx-score-cell .track { height:5px; margin-top:.35rem; border-radius:999px; background:rgba(255,255,255,.07); overflow:hidden; }
.idx-score-cell .track span { display:block; width:var(--size,0%); height:100%; background:#927dff; }
.idx-live-mark { display:inline-flex; align-items:center; gap:.4rem; color:var(--text-55); font:.64rem var(--font-mono); }
.idx-live-mark::before { content:""; width:.4rem; height:.4rem; border-radius:50%; background:#9b87ff; }

.idx-protocol { display:grid; gap:.8rem; counter-reset:protocol; }
.idx-step { position:relative; display:grid; grid-template-columns:auto 1fr; gap:1rem; min-width:0; padding:1.15rem; border:1px solid var(--border-10); border-radius:13px; background:var(--glass-5); }
.idx-step::before { counter-increment:protocol; content:counter(protocol,decimal-leading-zero); color:var(--violet-glow); font:.7rem var(--font-mono); }
.idx-step h3 { font-size:1rem; }
.idx-step p { margin-top:.45rem; color:var(--text-55); font-size:.85rem; line-height:1.6; }
.idx-formula { margin-top:1rem; padding:clamp(1.2rem,4vw,2rem); border:1px solid rgba(167,139,250,.3); border-radius:16px; background:linear-gradient(135deg,rgba(123,97,255,.1),rgba(255,255,255,.02)); }
.idx-formula-code { margin-top:1rem; padding:1rem; overflow-x:auto; border:1px solid var(--border-10); border-radius:9px; background:#050507; color:#ddd6ff; font:.73rem/1.7 var(--font-mono); }
.idx-formula p { margin-top:1rem; color:var(--text-75); max-width:85ch; }

.idx-governance { display:grid; gap:1rem; }
.idx-governance-card { min-width:0; padding:1.3rem; border:1px solid var(--border-10); border-radius:14px; background:var(--glass-5); }
.idx-governance-card > span { color:var(--violet-glow); font:.65rem var(--font-mono); letter-spacing:.12em; text-transform:uppercase; }
.idx-governance-card h3 { margin-top:.65rem; font-size:1.12rem; }
.idx-governance-card p,.idx-governance-card li { color:var(--text-55); font-size:.88rem; line-height:1.62; }
.idx-governance-card p { margin-top:.7rem; }
.idx-governance-card ul { margin:.75rem 0 0 1rem; display:grid; gap:.45rem; }
.idx-data-dictionary { display:grid; gap:0; margin-top:1rem; border:1px solid var(--border-10); border-radius:12px; overflow:hidden; }
.idx-definition { display:grid; gap:.35rem; padding:1rem; border-bottom:1px solid var(--border-10); }
.idx-definition:last-child { border-bottom:0; }
.idx-definition dt { color:#fff; font:600 .85rem var(--font-display); }
.idx-definition dd { color:var(--text-55); font-size:.82rem; line-height:1.55; }

.idx-faq { max-width:960px; }
.idx-page .faq-item { border-radius:10px; }

@media (min-width:760px) {
  .idx-protocol { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .idx-governance { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .idx-definition { grid-template-columns:180px 1fr; align-items:start; gap:1rem; }
  .idx-cohort-grid { grid-template-columns:repeat(4,minmax(0,1fr)); }
}
@media (min-width:920px) {
  .idx-hero-grid { grid-template-columns:minmax(0,1.35fr) minmax(340px,.65fr); }
  .idx-selected-grid { grid-template-columns:minmax(0,1fr) minmax(340px,.72fr); }
  .idx-summary { grid-template-columns:repeat(4,minmax(0,1fr)); }
  .idx-panel.coverage { grid-column:span 7; }
  .idx-panel.models { grid-column:span 5; }
  .idx-panel.distribution { grid-column:span 7; }
  .idx-panel.movement { grid-column:span 5; }
  .idx-protocol { grid-template-columns:repeat(3,minmax(0,1fr)); }
}
@media (min-width:1100px) {
  .idx-hero-metrics { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width:759px) {
  .idx-section-head { display:block; }
  .idx-section-note { margin-top:1rem; text-align:left; }
  .idx-selected-head { display:block; }
  .idx-round { margin-top:.75rem; text-align:left; }
  .idx-leader-viz { grid-template-columns:1fr; }
  .idx-donut { width:100px; }
  .idx-bar-row { grid-template-columns:minmax(100px,1fr) minmax(80px,1.4fr) auto; gap:.55rem; }
  .idx-distribution { gap:.4rem; }
  .idx-dist-label { font-size:.57rem; }
}
@media (max-width:460px) {
  .idx-hero-metrics { grid-template-columns:1fr 1fr; }
  .idx-hero-metric { padding:1rem .85rem; }
  .idx-summary { grid-template-columns:1fr 1fr; }
  .idx-movement { grid-template-columns:1fr 1fr; }
}
@media (prefers-reduced-motion:reduce) {
  .idx-page * { scroll-behavior:auto!important; }
}
