/* ==========================================================================
   Financial Indexes — Listing (idx-*) + Detail (iv2-*) Page Styles
   Detail layout mirrors site-new/stocks/stock-v2 (sv2-*) pattern.
   ========================================================================== */

/* ── Shared helpers ────────────────────────────────────────────────────── */
.idx-pulse-dot {
    display: inline-block;
    inline-size: 8px;
    block-size: 8px;
    border-radius: 50%;
    background: #16a34a;
    box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.6);
    animation: idxPulse 1.6s infinite;
    margin-inline-end: 6px;
    vertical-align: middle;
}
@keyframes idxPulse {
    0%   { box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.55); }
    70%  { box-shadow: 0 0 0 10px rgba(22, 163, 74, 0); }
    100% { box-shadow: 0 0 0 0 rgba(22, 163, 74, 0); }
}

/* ===========================================================================
   LISTING PAGE (idx-*) — unchanged from previous version
   =========================================================================== */
.idx-hero {
    position: relative;
    padding-block: clamp(40px, 6vw, 80px);
    background: linear-gradient(135deg, var(--navy, #152D50) 0%, var(--navy-deep, #071428) 100%);
    color: #fff;
    overflow: hidden;
}
.idx-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(14, 124, 123, 0.25), transparent 40%),
        radial-gradient(circle at 80% 70%, rgba(192, 138, 46, 0.18), transparent 45%);
    pointer-events: none;
}
.idx-hero-inner { position: relative; }
.idx-hero-badge {
    display: inline-flex; align-items: center;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.18);
    color: #fff; padding: 6px 14px;
    border-radius: 999px; font-size: 12px; font-weight: 600;
    margin-block-end: 16px;
    backdrop-filter: blur(4px);
}
.idx-hero-title { font-size: clamp(28px, 4vw, 44px); font-weight: 800; margin: 0 0 12px; line-height: 1.2; }
.idx-hero-sub { font-size: clamp(15px, 1.6vw, 18px); color: rgba(255, 255, 255, 0.78); max-inline-size: 720px; margin: 0 0 28px; line-height: 1.7; }
.idx-hero-stats { display: flex; flex-wrap: wrap; gap: 16px; }
.idx-hero-stat { background: rgba(255, 255, 255, 0.07); border: 1px solid rgba(255, 255, 255, 0.12); padding: 14px 22px; border-radius: 14px; display: flex; flex-direction: column; min-inline-size: 110px; }
.idx-hero-stat-val { font-size: 26px; font-weight: 800; color: #fff; line-height: 1; }
.idx-hero-stat-lbl { font-size: 12px; color: rgba(255, 255, 255, 0.65); margin-block-start: 6px; }

.idx-list-section { padding-block: 40px 80px; }
.idx-search-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; margin-block-end: 24px; }
.idx-search-input-wrap { position: relative; flex: 1 1 280px; max-inline-size: 460px; }
.idx-search-icon { position: absolute; inset-inline-start: 14px; inset-block-start: 50%; transform: translateY(-50%); color: var(--text-muted, #5E7A95); }
.idx-search-input { inline-size: 100%; padding-inline-start: 42px; padding-inline-end: 14px; padding-block: 12px; border: 1.5px solid #e2e8f0; border-radius: 12px; font-size: 14px; font-family: inherit; background: #fff; transition: border-color 0.18s, box-shadow 0.18s; }
.idx-search-input:focus { outline: none; border-color: var(--teal, #0E7C7B); box-shadow: 0 0 0 4px rgba(14, 124, 123, 0.1); }
.idx-filter-pills { display: inline-flex; background: #f1f5f9; border-radius: 999px; padding: 4px; gap: 2px; }
.idx-pill { border: none; background: transparent; color: #475569; padding: 8px 16px; border-radius: 999px; font-size: 13px; font-weight: 600; cursor: pointer; transition: background 0.18s, color 0.18s; }
.idx-pill:hover { color: var(--navy, #152D50); }
.idx-pill.active { background: var(--navy, #152D50); color: #fff; }
.idx-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.idx-card { background: #fff; border: 1px solid #e2e8f0; border-radius: 16px; padding: 18px 18px 16px; text-decoration: none; color: inherit; transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s; position: relative; overflow: hidden; isolation: isolate; }
.idx-card::before { content: ''; position: absolute; inset: 0; background: linear-gradient(135deg, transparent 60%, rgba(14, 124, 123, 0.05)); opacity: 0; transition: opacity 0.2s; z-index: -1; }
.idx-card:hover { transform: translateY(-3px); box-shadow: 0 12px 28px -10px rgba(15, 23, 42, 0.16); border-color: var(--teal, #0E7C7B); color: inherit; }
.idx-card:hover::before { opacity: 1; }
.idx-card-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-block-end: 10px; }
.idx-card-symbol { font-size: 13px; font-weight: 700; color: var(--text-muted, #5E7A95); letter-spacing: 0.5px; }
.idx-card-badge { display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; }
.idx-card-badge.is-up   { background: rgba(22, 163, 74, 0.1); color: #15803d; }
.idx-card-badge.is-down { background: rgba(220, 38, 38, 0.1); color: #b91c1c; }
.idx-card-name { font-size: 15px; font-weight: 700; color: var(--navy, #152D50); margin-block-end: 16px; min-block-size: 42px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.idx-card-price-row { display: flex; align-items: baseline; gap: 10px; margin-block-end: 12px; }
.idx-card-price { font-size: 24px; font-weight: 800; color: var(--navy, #152D50); line-height: 1; }
.idx-card-change { font-size: 14px; font-weight: 700; }
.idx-card-change.is-up   { color: #15803d; }
.idx-card-change.is-down { color: #b91c1c; }
.idx-card-foot { display: flex; gap: 8px; flex-wrap: wrap; padding-block-start: 12px; border-block-start: 1px solid #f1f5f9; }
.idx-card-meta { font-size: 11px; color: var(--text-muted, #5E7A95); background: #f8fafc; padding: 3px 8px; border-radius: 6px; }
.idx-empty, .idx-empty-results { text-align: center; padding: 48px 16px; color: var(--text-muted, #5E7A95); grid-column: 1 / -1; }

/* ===========================================================================
   DETAIL PAGE (iv2-*) — stock-v2-style layout
   =========================================================================== */

/* ── Hero ──────────────────────────────────────────────────────────────── */
.iv2-hero {
    position: relative;
    background: linear-gradient(135deg, var(--navy, #152D50) 0%, var(--navy-deep, #071428) 100%);
    color: #fff;
    padding-block: clamp(40px, 5vw, 64px);
    overflow: hidden;
    isolation: isolate;
}
.iv2-hero-bg { position: absolute; inset: 0; pointer-events: none; z-index: -1; overflow: hidden; }
.iv2-hero-orb { position: absolute; border-radius: 50%; filter: blur(60px); opacity: 0.32; animation: iv2OrbFloat 18s ease-in-out infinite; }
.iv2-hero-orb-1 { inline-size: 360px; block-size: 360px; inset-block-start: -120px; inset-inline-end: -100px; background: radial-gradient(circle, var(--teal-light, #12A09E), transparent 70%); }
.iv2-hero-orb-2 { inline-size: 260px; block-size: 260px; inset-block-end: -80px; inset-inline-start: 20%; background: radial-gradient(circle, var(--gold-light, #E5A83A), transparent 70%); animation-delay: -9s; }
@keyframes iv2OrbFloat {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33%      { transform: translate(40px, -30px) scale(1.08); }
    66%      { transform: translate(-30px, 25px) scale(0.95); }
}

.iv2-hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 28px;
    align-items: start;
}
@media (max-width: 991px) {
    .iv2-hero-grid { grid-template-columns: 1fr; }
}

.iv2-id { display: flex; gap: 16px; align-items: flex-start; margin-block-end: 22px; }
.iv2-logo {
    flex: 0 0 64px;
    inline-size: 64px;
    block-size: 64px;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--gold, #C08A2E) 0%, var(--gold-light, #E5A83A) 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 900;
    font-family: ui-monospace, monospace;
    letter-spacing: 1px;
    box-shadow: 0 8px 22px -8px rgba(192, 138, 46, 0.5);
}
.iv2-ticker {
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.65);
    letter-spacing: 0.6px;
    text-transform: uppercase;
    margin-block-end: 6px;
}
.iv2-h1 {
    font-size: clamp(28px, 4.2vw, 44px);
    font-weight: 900;
    margin: 0 0 6px;
    line-height: 1.2;
    letter-spacing: -0.5px;
}
.iv2-subtitle {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    margin: 0;
}

.iv2-price-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    margin-block-end: 22px;
}
.iv2-price {
    font-size: clamp(34px, 5vw, 52px);
    font-weight: 900;
    line-height: 1;
    letter-spacing: -1px;
    font-variant-numeric: tabular-nums;
    text-shadow: 0 4px 18px rgba(0, 0, 0, 0.18);
}
.iv2-price-ccy {
    font-size: clamp(13px, 1.4vw, 16px);
    font-weight: 700;
    color: rgba(255, 255, 255, 0.65);
    letter-spacing: 0.5px;
    margin-inline-start: -6px;
    align-self: flex-end;
    padding-block-end: 6px;
}
.iv2-change {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 800;
    backdrop-filter: blur(6px);
}
.iv2-change.up   { background: rgba(22, 163, 74, 0.22); color: #4ade80; border: 1px solid rgba(74, 222, 128, 0.3); }
.iv2-change.down { background: rgba(220, 38, 38, 0.22); color: #fca5a5; border: 1px solid rgba(252, 165, 165, 0.3); }
.iv2-live {
    display: inline-flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.14);
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.85);
}

.iv2-quick-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
    margin-block-end: 22px;
}
.iv2-qs {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    padding: 12px 14px;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    transition: background 0.2s, transform 0.2s;
}
.iv2-qs:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}
.iv2-qs-val { font-size: 17px; font-weight: 800; color: #fff; line-height: 1.2; font-variant-numeric: tabular-nums; }
.iv2-qs-label { font-size: 11px; color: rgba(255, 255, 255, 0.65); margin-block-start: 4px; }

.iv2-hero-spark {
    position: relative;
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    block-size: 90px;
    backdrop-filter: blur(8px);
}
.iv2-hero-spark-label {
    position: absolute;
    inset-block-start: 8px;
    inset-inline-start: 12px;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 600;
}
.iv2-hero-spark svg { inline-size: 100%; block-size: 100%; display: block; overflow: visible; }

/* ── Hero sidebar ──────────────────────────────────────────────────────── */
.iv2-sidebar { display: flex; flex-direction: column; gap: 16px; }

.iv2-perf-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 16px;
    padding: 16px;
    backdrop-filter: blur(8px);
}
.iv2-perf-caption {
    font-size: 12px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.65);
    letter-spacing: 0.5px;
    margin-block-end: 12px;
    text-transform: uppercase;
}
.iv2-perf-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}
.iv2-perf-cell {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    padding: 10px 12px;
    text-align: center;
}
.iv2-perf-lbl { font-size: 11px; color: rgba(255, 255, 255, 0.6); margin-block-end: 4px; }
.iv2-perf-val { font-size: 15px; font-weight: 800; font-variant-numeric: tabular-nums; }
.iv2-perf-cell.is-up    .iv2-perf-val { color: #4ade80; }
.iv2-perf-cell.is-down  .iv2-perf-val { color: #fca5a5; }
.iv2-perf-cell.is-neutral .iv2-perf-val { color: rgba(255, 255, 255, 0.5); }

.iv2-cta-card {
    background: linear-gradient(135deg, var(--gold, #C08A2E) 0%, var(--gold-light, #E5A83A) 100%);
    color: #fff;
    border-radius: 16px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 12px 30px -10px rgba(192, 138, 46, 0.6);
    position: relative;
    overflow: hidden;
    isolation: isolate;
}
.iv2-cta-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 80% 0%, rgba(255, 255, 255, 0.18), transparent 50%);
    pointer-events: none;
    z-index: -1;
}
.iv2-cta-card-title { font-size: 17px; font-weight: 800; margin-block-end: 14px; }
.iv2-cta-btn {
    display: block;
    background: #fff;
    color: var(--navy, #152D50);
    padding: 12px 20px;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 800;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 4px 12px -4px rgba(0, 0, 0, 0.18);
}
.iv2-cta-btn:hover {
    transform: translateY(-2px);
    color: var(--navy, #152D50);
    box-shadow: 0 8px 20px -6px rgba(0, 0, 0, 0.25);
}
.iv2-cta-card-note { font-size: 11px; opacity: 0.85; margin-block-start: 10px; }

/* ── Two-column content grid ──────────────────────────────────────────── */
.iv2-grid {
    display: grid;
    grid-template-columns: 260px minmax(0, 1fr);
    gap: 28px;
    max-inline-size: 1300px;
    margin: 0 auto;
    padding: clamp(20px, 3vw, 36px) clamp(12px, 2vw, 24px);
}
@media (max-width: 991px) {
    /* minmax(0,1fr) (not bare 1fr) caps the single column at the viewport so
       wide children — the components table, sidebar rows — scroll/shrink inside
       it instead of stretching the whole column past the screen edge. */
    .iv2-grid { grid-template-columns: minmax(0, 1fr); gap: 20px; }
    .iv2-grid__sidebar, .iv2-grid__main { min-inline-size: 0; }
}

/* ── Left sidebar (TOC + mini + brokers) ──────────────────────────────── */
.iv2-grid__sidebar {
    position: sticky;
    inset-block-start: 90px;
    block-size: -moz-fit-content;
    block-size: fit-content;
    align-self: start;
    display: flex;
    flex-direction: column;
    gap: 16px;
}
@media (max-width: 991px) {
    .iv2-grid__sidebar { position: static; }
}

.iv2-toc, .iv2-mini-card, .iv2-broker-sidebar {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 18px;
}
.iv2-toc__title, .iv2-mini-card__title, .iv2-bs-title {
    font-size: 13px;
    font-weight: 800;
    color: var(--navy, #152D50);
    margin: 0 0 14px;
    padding-block-end: 10px;
    border-block-end: 2px solid var(--teal, #0E7C7B);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.iv2-toc__list { list-style: none; padding: 0; margin: 0; }
.iv2-toc__list li { margin-block-end: 4px; }
.iv2-toc__list a {
    display: block;
    padding: 7px 10px;
    color: #475569;
    text-decoration: none;
    font-size: 13.5px;
    border-radius: 8px;
    transition: background 0.15s, color 0.15s, padding 0.15s;
}
.iv2-toc__list a:hover {
    background: var(--teal-bg, #EBF7F7);
    color: var(--navy, #152D50);
    padding-inline-start: 14px;
}

.iv2-mini-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-block: 8px;
    border-block-end: 1px dashed #e2e8f0;
    font-size: 13px;
}
.iv2-mini-row:last-child { border-block-end: none; }
.iv2-mini-row span { color: var(--text-muted, #5E7A95); }
.iv2-mini-row strong { color: var(--navy, #152D50); font-weight: 700; }

/* Broker rows in sidebar */
.iv2-bs-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-block: 10px;
    border-block-end: 1px dashed #e2e8f0;
}
.iv2-bs-row:last-of-type { border-block-end: none; }
.iv2-bs-logo, .iv2-bs-logo-fallback {
    flex-shrink: 0;
    inline-size: 36px;
    block-size: 36px;
    border-radius: 8px;
    object-fit: contain;
    background: #f8fafc;
}
.iv2-bs-logo-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--navy, #152D50), var(--navy-light, #1A3456));
    color: #fff;
    font-size: 12px;
    font-weight: 700;
}
.iv2-bs-info { flex: 1; min-inline-size: 0; }
.iv2-bs-name {
    font-size: 13px;
    font-weight: 700;
    color: var(--navy, #152D50);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.iv2-bs-rating { font-size: 11px; color: var(--text-muted, #5E7A95); margin-block-start: 2px; }
.iv2-bs-star { color: var(--gold, #C08A2E); }
.iv2-bs-cta {
    background: var(--gold, #C08A2E);
    color: #fff;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
    transition: background 0.18s, transform 0.18s;
    white-space: nowrap;
}
.iv2-bs-cta:hover { background: var(--gold-light, #E5A83A); color: #fff; transform: translateY(-1px); }
.iv2-bs-disclaimer {
    font-size: 10.5px;
    color: var(--text-muted, #5E7A95);
    margin: 12px 0 0;
    line-height: 1.5;
}

/* ── Main column sections ─────────────────────────────────────────────── */
.iv2-section {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: clamp(18px, 2.6vw, 28px);
    margin-block-end: 20px;
    box-shadow: 0 2px 8px -4px rgba(15, 23, 42, 0.06);
}
.iv2-section-title {
    font-size: clamp(18px, 2vw, 22px);
    font-weight: 800;
    color: var(--navy, #152D50);
    margin: 0 0 18px;
    padding-block-end: 10px;
    border-block-end: 2px solid var(--teal, #0E7C7B);
    display: inline-block;
}

/* Summary cards */
.iv2-summary-card {
    display: flex;
    gap: 16px;
    padding: clamp(16px, 2vw, 22px);
    border-radius: 12px;
    align-items: flex-start;
}
.iv2-summary-card-start {
    background: linear-gradient(135deg, var(--teal-bg, #EBF7F7) 0%, #fff 100%);
    border-inline-start: 4px solid var(--teal, #0E7C7B);
}
.iv2-summary-card-end {
    background: linear-gradient(135deg, var(--gold-bg, #FAF3E5) 0%, #fff 100%);
    border-inline-start: 4px solid var(--gold, #C08A2E);
}
.iv2-summary-icon {
    flex: 0 0 44px;
    inline-size: 44px;
    block-size: 44px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
}
.iv2-summary-card-start .iv2-summary-icon { background: var(--teal, #0E7C7B); }
.iv2-summary-card-end   .iv2-summary-icon { background: var(--gold, #C08A2E); }
.iv2-summary-label {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    color: var(--text-muted, #5E7A95);
    letter-spacing: 0.5px;
    margin-block-end: 6px;
}
.iv2-summary-text { font-size: 15px; line-height: 1.85; color: #1e293b; }
.iv2-summary-text p:last-child { margin-block-end: 0; }

/* Range card (day + 52w bars) */
.iv2-range-card { display: flex; flex-direction: column; gap: 18px; }
.iv2-range-block { }
.iv2-range-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: var(--text-muted, #5E7A95);
    margin-block-end: 8px;
}
.iv2-range-head span:last-child { color: var(--navy, #152D50); font-weight: 700; font-variant-numeric: tabular-nums; }
.iv2-range-bar {
    position: relative;
    block-size: 8px;
    background: #f1f5f9;
    border-radius: 999px;
    overflow: visible;
}
.iv2-range-fill {
    position: absolute;
    inset-block-start: 0;
    inset-inline-start: 0;
    block-size: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--teal, #0E7C7B), var(--teal-light, #12A09E));
}
.iv2-range-fill.is-52w {
    background: linear-gradient(90deg, var(--gold, #C08A2E), var(--gold-light, #E5A83A));
}
.iv2-range-pin {
    position: absolute;
    inset-block-start: 50%;
    transform: translate(50%, -50%);
    inline-size: 16px;
    block-size: 16px;
    background: #fff;
    border: 2px solid var(--navy, #152D50);
    border-radius: 50%;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}
/* RTL: shift the pin by +50% (toward inline-start = right) so its centre lands
   on the fill's value edge and it never spills past the card border at extremes. */
[dir="rtl"] .iv2-range-pin { transform: translate(50%, -50%); }

/* Period perf strip */
.iv2-perf-strip {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
}
.iv2-perf-card-lg {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 14px 12px;
    text-align: center;
    position: relative;
    overflow: hidden;
    transition: transform 0.18s, box-shadow 0.18s, border-color 0.18s;
}
.iv2-perf-card-lg::before {
    content: '';
    position: absolute;
    inset-block-start: 0;
    inset-inline: 0;
    block-size: 3px;
}
.iv2-perf-card-lg.is-up::before   { background: linear-gradient(90deg, #16a34a, #4ade80); }
.iv2-perf-card-lg.is-down::before { background: linear-gradient(90deg, #dc2626, #f87171); }
.iv2-perf-card-lg.is-neutral::before { background: #e2e8f0; }
.iv2-perf-card-lg:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 18px -8px rgba(15, 23, 42, 0.12);
    border-color: transparent;
}
.iv2-perf-card-lbl { font-size: 11px; color: var(--text-muted, #5E7A95); font-weight: 600; margin-block-end: 6px; }
.iv2-perf-card-val { font-size: 18px; font-weight: 800; font-variant-numeric: tabular-nums; }
.iv2-perf-card-lg.is-up   .iv2-perf-card-val { color: #15803d; }
.iv2-perf-card-lg.is-down .iv2-perf-card-val { color: #b91c1c; }
.iv2-perf-card-lg.is-neutral .iv2-perf-card-val { color: var(--text-muted, #5d6b7a); }

/* Stats grid */
.iv2-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 10px;
}
.iv2-stat {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    transition: border-color 0.18s, background 0.18s;
}
.iv2-stat:hover { border-color: var(--teal, #0E7C7B); background: #fff; }
.iv2-stat-label { font-size: 11.5px; color: var(--text-muted, #5E7A95); font-weight: 600; }
.iv2-stat-val { font-size: 16px; font-weight: 800; color: var(--navy, #152D50); font-variant-numeric: tabular-nums; }
.iv2-stat-val.is-up   { color: #15803d; }
.iv2-stat-val.is-down { color: #b91c1c; }

/* Chart card */
.iv2-chart-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 16px;
}
.iv2-chart-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: space-between;
    align-items: center;
    margin-block-end: 14px;
    padding-block-end: 10px;
    border-block-end: 1px solid #e2e8f0;
}
.iv2-chart-range-tabs, .iv2-chart-type-tabs { display: inline-flex; background: #fff; border-radius: 8px; padding: 3px; gap: 2px; box-shadow: inset 0 0 0 1px #e2e8f0; }
.iv2-range-tab, .iv2-type-tab { border: none; background: transparent; color: #475569; padding: 6px 12px; border-radius: 6px; font-size: 12px; font-weight: 700; cursor: pointer; transition: background 0.18s, color 0.18s; }
.iv2-range-tab:hover, .iv2-type-tab:hover { color: var(--navy, #152D50); }
.iv2-range-tab.active, .iv2-type-tab.active { background: var(--navy, #152D50); color: #fff; }
.iv2-chart-figure { margin: 0; }
.iv2-chart-container { inline-size: 100%; min-block-size: 460px; }
.iv2-chart-noscript { padding: 24px; text-align: center; color: var(--text-muted, #5E7A95); }

/* Article body */
.iv2-article { line-height: 1.9; color: #1e293b; font-size: 15.5px; }
.iv2-article h2, .iv2-article h3 { color: var(--navy, #152D50); margin-block: 24px 12px; font-weight: 800; }
.iv2-article h2 { font-size: 20px; } .iv2-article h3 { font-size: 17px; }
.iv2-article p { margin-block: 0 14px; }
.iv2-article ul, .iv2-article ol { padding-inline-start: 22px; margin-block: 12px 16px; }
.iv2-article li { margin-block-end: 6px; }

/* Table */
.iv2-table-wrap { background: #fff; border: 1px solid #e2e8f0; border-radius: 12px; overflow-x: auto; }
.iv2-table { inline-size: 100%; border-collapse: collapse; font-size: 13.5px; }
.iv2-table thead th { background: #f8fafc; color: var(--navy, #152D50); font-weight: 700; text-align: start; padding: 11px 14px; border-block-end: 2px solid #e2e8f0; font-size: 11.5px; text-transform: uppercase; letter-spacing: 0.5px; }
.iv2-table tbody td { padding: 10px 14px; border-block-end: 1px solid #f1f5f9; color: #334155; font-variant-numeric: tabular-nums; }
.iv2-table tbody tr:last-child td { border-block-end: none; }
.iv2-table tbody tr:hover { background: #f8fafc; }

/* How-to-invest step grid */
.iv2-step-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.iv2-step {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 18px;
    text-align: center;
    transition: transform 0.2s, box-shadow 0.2s;
}
.iv2-step:hover { transform: translateY(-3px); box-shadow: 0 10px 22px -10px rgba(15, 23, 42, 0.15); }
.iv2-step-num {
    inline-size: 44px;
    block-size: 44px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 18px;
    font-weight: 900;
    margin-block-end: 12px;
}
.iv2-step-num--gold  { background: linear-gradient(135deg, var(--gold, #C08A2E), var(--gold-light, #E5A83A)); }
.iv2-step-num--teal  { background: linear-gradient(135deg, var(--teal, #0E7C7B), var(--teal-light, #12A09E)); }
.iv2-step-num--green { background: linear-gradient(135deg, #16a34a, #4ade80); }
.iv2-step-title { font-size: 15px; font-weight: 800; color: var(--navy, #152D50); margin-block-end: 6px; }
.iv2-step-text { font-size: 13px; color: var(--text-muted, #5E7A95); line-height: 1.6; }
.iv2-step-cta-row { text-align: center; margin-block-start: 20px; }
.iv2-step-cta {
    display: inline-block;
    background: var(--gold, #C08A2E);
    color: #fff;
    padding: 12px 28px;
    border-radius: 10px;
    font-weight: 800;
    text-decoration: none;
    transition: background 0.18s, transform 0.18s, box-shadow 0.18s;
    box-shadow: 0 6px 18px -6px rgba(192, 138, 46, 0.5);
}
.iv2-step-cta:hover { background: var(--gold-light, #E5A83A); color: #fff; transform: translateY(-2px); }

/* Similar indexes */
.iv2-similar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 12px;
}
.iv2-similar-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 14px;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
    position: relative;
    overflow: hidden;
}
.iv2-similar-card::after {
    content: '';
    position: absolute;
    inset-block-end: 0;
    inset-inline: 0;
    block-size: 3px;
}
.iv2-similar-card.is-up::after   { background: linear-gradient(90deg, #16a34a, #4ade80); }
.iv2-similar-card.is-down::after { background: linear-gradient(90deg, #dc2626, #f87171); }
.iv2-similar-card:hover { transform: translateY(-3px); box-shadow: 0 12px 24px -10px rgba(15, 23, 42, 0.15); border-color: var(--teal, #0E7C7B); color: inherit; }
.iv2-similar-top { display: flex; justify-content: space-between; gap: 8px; }
.iv2-similar-meta { flex: 1; min-inline-size: 0; }
.iv2-similar-symbol { font-size: 11px; font-weight: 700; color: var(--text-muted, #5E7A95); letter-spacing: 0.5px; margin-block-end: 4px; }
.iv2-similar-name { font-size: 13.5px; font-weight: 700; color: var(--navy, #152D50); line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.iv2-similar-badge { padding: 3px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 700; flex-shrink: 0; height: -moz-fit-content; height: fit-content; }
.iv2-similar-badge.is-up   { background: rgba(22, 163, 74, 0.1); color: #15803d; }
.iv2-similar-badge.is-down { background: rgba(220, 38, 38, 0.1); color: #b91c1c; }
.iv2-similar-spark { inline-size: 100%; block-size: 48px; }
.iv2-similar-spark svg { inline-size: 100%; block-size: 100%; display: block; overflow: visible; }
.iv2-similar-bottom { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding-block-start: 8px; border-block-start: 1px solid #f1f5f9; }
.iv2-similar-price { font-size: 16px; font-weight: 800; color: var(--navy, #152D50); font-variant-numeric: tabular-nums; }
.iv2-similar-exchange { font-size: 10.5px; color: var(--text-muted, #5E7A95); text-align: end; }

/* ── Sticky CTA bar (post-hero) ───────────────────────────────────────── */
.iv2-sticky-bar {
    position: fixed;
    inset-inline: 0;
    inset-block-end: 0;
    background: var(--navy, #152D50);
    color: #fff;
    box-shadow: 0 -6px 22px -8px rgba(0, 0, 0, 0.25);
    transform: translateY(100%);
    transition: transform 0.3s ease;
    z-index: 1040;
}
.iv2-sticky-bar.is-visible { transform: translateY(0); }
.iv2-sticky-inner {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-block: 12px;
    padding-inline: clamp(12px, 2vw, 24px);
}
.iv2-sticky-name { font-size: 14px; font-weight: 700; flex: 1; min-inline-size: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.iv2-sticky-ticker {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.16);
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
    font-family: ui-monospace, monospace;
    letter-spacing: 0.5px;
}
.iv2-sticky-cta {
    background: var(--gold, #C08A2E);
    color: #fff;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 800;
    text-decoration: none;
    white-space: nowrap;
    transition: background 0.18s, transform 0.18s;
}
.iv2-sticky-cta:hover { background: var(--gold-light, #E5A83A); color: #fff; transform: translateY(-1px); }

@media (max-width: 640px) {
    .iv2-sticky-name { display: none; }
    .iv2-sticky-cta { padding: 8px 14px; font-size: 13px; }
}

/* ── Mobile tightening ────────────────────────────────────────────────── */
@media (max-width: 640px) {
    .idx-grid { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
    .idx-card { padding: 14px; }
    .idx-card-price { font-size: 20px; }
    .idx-search-row { flex-direction: column; align-items: stretch; }
    .idx-filter-pills { align-self: flex-start; }

    .iv2-id { gap: 12px; }
    .iv2-logo { flex-basis: 52px; inline-size: 52px; block-size: 52px; font-size: 15px; }
    .iv2-h1 { font-size: 24px; }
    .iv2-price { font-size: 32px; }
    .iv2-quick-stats { grid-template-columns: repeat(2, 1fr); }
    .iv2-perf-grid { grid-template-columns: repeat(2, 1fr); }
    .iv2-stats-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
    .iv2-stat { padding: 10px 12px; }
    .iv2-stat-val { font-size: 14px; }
    .iv2-chart-container { min-block-size: 340px; }
    .iv2-table { font-size: 12px; }
    .iv2-table thead th, .iv2-table tbody td { padding: 8px 10px; }
    .iv2-similar-grid { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }
    .iv2-step-grid { grid-template-columns: 1fr; }
}

/* ===========================================================================
   INDEX COMPONENTS (constituents) — interactive list on the detail page
   =========================================================================== */
.iv2-comp-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
    margin-block-end: 16px;
}
.iv2-comp-intro {
    margin: 0;
    font-size: 13.5px;
    line-height: 1.7;
    color: var(--text-muted, #5E7A95);
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.iv2-comp-count {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    background: var(--teal-bg, #EBF7F7);
    color: var(--teal, #0E7C7B);
    font-size: 12px;
    font-weight: 700;
}
.iv2-comp-search-wrap { position: relative; flex: 0 1 260px; }
.iv2-comp-search-icon {
    position: absolute;
    inset-inline-start: 12px;
    inset-block-start: 50%;
    transform: translateY(-50%);
    color: var(--text-muted, #5E7A95);
    pointer-events: none;
}
.iv2-comp-search {
    inline-size: 100%;
    padding-block: 9px;
    padding-inline: 38px 12px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: #f8fafc;
    font-size: 13px;
    font-family: inherit;
    color: var(--navy, #152D50);
    transition: border-color 0.15s, background 0.15s;
}
.iv2-comp-search:focus {
    outline: none;
    border-color: var(--teal, #0E7C7B);
    background: #fff;
}

/* horizontal scroll on narrow screens instead of clipping the 6-col table */
.iv2-comp-table-wrap { overflow-x: auto; }
.iv2-comp-table { min-inline-size: 540px; }

.iv2-comp-sort {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: none;
    border: 0;
    margin: 0;
    padding: 0;
    font: inherit;
    color: inherit;
    text-transform: inherit;
    letter-spacing: inherit;
    cursor: pointer;
    transition: color 0.15s;
}
.iv2-comp-sort:hover,
.iv2-comp-sort.is-active { color: var(--teal, #0E7C7B); }
.iv2-comp-caret {
    inline-size: 0;
    block-size: 0;
    border-inline: 4px solid transparent;
    opacity: 0;
    transition: opacity 0.15s;
}
.iv2-comp-sort.is-active .iv2-comp-caret { opacity: 1; }
.iv2-comp-sort.is-desc .iv2-comp-caret { border-block-start: 5px solid currentColor; }
.iv2-comp-sort.is-asc  .iv2-comp-caret { border-block-end: 5px solid currentColor; }

.iv2-comp-rank {
    inline-size: 1%;
    white-space: nowrap;
    color: var(--text-muted, #5E7A95);
    font-weight: 600;
}
.iv2-comp-link {
    color: var(--navy, #152D50);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.15s;
}
.iv2-comp-link:hover { color: var(--teal, #0E7C7B); text-decoration: underline; }
.iv2-comp-name { color: #334155; }
.iv2-comp-na { color: var(--text-muted, #5E7A95); }

.iv2-comp-weight { min-inline-size: 92px; }
.iv2-comp-wbar {
    position: relative;
    display: flex;
    align-items: center;
    min-inline-size: 68px;
    block-size: 24px;
    padding-inline: 8px;
    border-radius: 6px;
    background: #f1f5f9;
    overflow: hidden;
    font-size: 12px;
    font-weight: 700;
    color: var(--navy, #152D50);
}
.iv2-comp-wbar::before {
    content: "";
    position: absolute;
    inset-block: 0;
    inset-inline-start: 0;
    inline-size: var(--w, 0%);
    background: linear-gradient(90deg, rgba(14, 124, 123, 0.16), rgba(14, 124, 123, 0.32));
    z-index: 0;
}
.iv2-comp-wbar span { position: relative; z-index: 1; }

.iv2-comp-empty {
    text-align: center;
    padding: 24px 12px;
    color: var(--text-muted, #5E7A95);
    font-size: 13.5px;
}
.iv2-comp-foot {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    margin-block-start: 16px;
}
.iv2-comp-pager {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 6px;
}
.iv2-comp-page {
    min-inline-size: 36px;
    padding: 7px 11px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    background: #fff;
    color: var(--navy, #152D50);
    font-size: 13px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.iv2-comp-page:hover:not(:disabled) { border-color: var(--teal, #0E7C7B); color: var(--teal, #0E7C7B); }
.iv2-comp-page.is-active {
    background: var(--teal, #0E7C7B);
    border-color: var(--teal, #0E7C7B);
    color: #fff;
    cursor: default;
}
.iv2-comp-page:disabled { opacity: 0.45; cursor: not-allowed; }
.iv2-comp-page-nav { font-weight: 600; }
.iv2-comp-ellipsis { padding-inline: 4px; color: var(--text-muted, #5E7A95); }
.iv2-comp-note {
    margin: 0;
    font-size: 11.5px;
    color: var(--text-muted, #5E7A95);
    text-align: center;
}

@media (max-width: 640px) {
    .iv2-comp-head { flex-direction: column; align-items: stretch; }
    .iv2-comp-search-wrap { flex-basis: auto; }
    .iv2-comp-th-rank, .iv2-comp-rank { display: none; }
}
