/* ─── MARKET INSIGHTS PAGE ─── */

.mi-page {
    color: var(--text);
    font-family: 'DM Sans', sans-serif;
    line-height: 1.6;
}

/* HERO */
.mi-hero {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 40px 40px;
}

.mi-hero-eyebrow {
    font-size: 12px;
    font-weight: 700;
    color: var(--gold);
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 12px;
}

.mi-hero h1 {
    font-family: 'Playfair Display', serif;
    font-size: clamp(36px, 5vw, 52px);
    font-weight: 800;
    color: var(--navy-ink);
    line-height: 1.15;
    margin-bottom: 16px;
}

.mi-hero h1 em {
    font-style: normal;
    color: var(--gold);
}

.mi-hero-sub {
    font-size: 17px;
    color: var(--text-dim);
    max-width: 560px;
    line-height: 1.7;
}

.mi-hero-meta {
    margin-top: 20px;
    display: flex;
    gap: 24px;
    align-items: center;
    font-size: 13px;
    color: var(--text-muted);
}

.mi-hero-meta .dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--gold);
}

.mi-hero-divider {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
}

.mi-hero-divider > div {
    height: 1px;
    background: linear-gradient(90deg, var(--gold) 0%, transparent 70%);
}

/* MAIN GRID */
.mi-main {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 40px 80px;
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 40px;
}

/* SECTION HEADERS */
.mi-section-label {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.mi-section-label .icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: var(--gold-glow);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
}

.mi-section-label h2 {
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    font-weight: 700;
    color: var(--gold);
    letter-spacing: 2.5px;
    text-transform: uppercase;
}

/* SNAPSHOT */
.mi-snapshot-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 32px;
    margin-bottom: 32px;
}

.mi-snapshot-text {
    font-size: 15.5px;
    color: var(--text);
    line-height: 1.8;
    margin-bottom: 20px;
}

.mi-snapshot-text strong {
    color: var(--navy-ink);
}

.mi-index-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 20px;
}

.mi-index-card {
    background: var(--surface-raised);
    border: 1px solid var(--border-subtle);
    border-radius: 10px;
    padding: 16px;
    text-align: center;
}

.mi-index-card .name {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-bottom: 6px;
}

.mi-index-card .value {
    font-size: 20px;
    font-weight: 700;
    color: var(--navy-ink);
    font-variant-numeric: tabular-nums;
}

.mi-index-card .change {
    font-size: 13px;
    font-weight: 600;
    margin-top: 4px;
    font-variant-numeric: tabular-nums;
}

.mi-index-card .change.up { color: var(--green); }
.mi-index-card .change.down { color: var(--red); }

.mi-spark {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 2px;
    height: 24px;
    margin-top: 8px;
}

.mi-spark .bar {
    width: 4px;
    border-radius: 2px;
    transition: height 0.3s;
}

.mi-spark .bar.g { background: var(--green); }
.mi-spark .bar.r { background: var(--red); }

/* KEY DATES */
.mi-dates-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 28px 32px;
    margin-bottom: 32px;
}

.mi-date-row {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 16px;
    padding: 14px 0;
    border-bottom: 1px solid var(--border-subtle);
    align-items: start;
}

.mi-date-row:last-child { border-bottom: none; }

.mi-date-badge {
    background: var(--surface-raised);
    border: 1px solid var(--border);
    border-radius: 10px;
    text-align: center;
    padding: 8px 6px;
}

.mi-date-badge .month {
    font-size: 10px;
    font-weight: 700;
    color: var(--gold);
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

.mi-date-badge .day {
    font-size: 22px;
    font-weight: 700;
    color: var(--navy-ink);
    line-height: 1.2;
}

.mi-date-info .event-name {
    font-size: 14px;
    font-weight: 700;
    color: var(--navy-ink);
    margin-bottom: 3px;
}

.mi-date-info .event-tag {
    display: inline-block;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 2px 8px;
    border-radius: 4px;
    margin-bottom: 6px;
}

.mi-tag-fed { background: rgba(176, 125, 26, 0.14); color: var(--gold); }
.mi-tag-data { background: rgba(42, 100, 175, 0.12); color: #2A64AF; }
.mi-tag-earnings { background: rgba(26, 158, 82, 0.12); color: var(--green); }
.mi-tag-options { background: rgba(192, 57, 43, 0.10); color: var(--red); }

.mi-date-info .event-why {
    font-size: 13px;
    color: var(--text-dim);
    line-height: 1.6;
}

/* SECTOR PULSE */
.mi-sector-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 24px;
}

.mi-sector-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 8px;
    border-bottom: 1px solid var(--border-subtle);
    transition: background 0.15s;
}

.mi-sector-row:hover {
    background: var(--surface-raised);
    border-radius: 8px;
}

.mi-sector-row:last-child { border-bottom: none; }

.mi-sector-name {
    font-size: 13.5px;
    font-weight: 500;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 10px;
}

.mi-sector-icon {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    background: var(--surface-raised);
}

.mi-sector-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.mi-sector-change {
    font-size: 13px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    min-width: 58px;
    text-align: right;
}

.mi-sector-change.up { color: var(--green); }
.mi-sector-change.down { color: var(--red); }
.mi-sector-change.flat { color: var(--text-muted); }

.mi-sector-bar-wrap {
    width: 80px;
    height: 6px;
    background: var(--surface-raised);
    border-radius: 3px;
    overflow: hidden;
}

.mi-sector-bar {
    height: 100%;
    border-radius: 3px;
    transition: width 0.6s ease;
}

.mi-sector-bar.up { background: var(--green); }
.mi-sector-bar.down { background: var(--red); }

/* SIDEBAR */
.mi-sidebar {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.mi-sidebar-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 24px;
}

.mi-sidebar-card h3 {
    font-size: 12px;
    font-weight: 700;
    color: var(--gold);
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.mi-stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-subtle);
}

.mi-stat-row:last-child { border-bottom: none; }

.mi-stat-label { font-size: 13px; color: var(--text-dim); }

.mi-stat-value {
    font-size: 14px;
    font-weight: 700;
    color: var(--navy-ink);
    font-variant-numeric: tabular-nums;
}

/* Fear & Greed */
.mi-gauge-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px 0;
}

.mi-gauge-outer {
    width: 180px;
    height: 90px;
    position: relative;
    overflow: hidden;
}

.mi-gauge-bg {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    background: conic-gradient(
        var(--red) 0deg, #E67E22 72deg, var(--gold) 108deg,
        #F1C40F 144deg, var(--green) 180deg
    );
    mask: radial-gradient(circle at center, transparent 55px, black 56px);
    -webkit-mask: radial-gradient(circle at center, transparent 55px, black 56px);
}

.mi-gauge-needle {
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 3px;
    height: 60px;
    background: #2A3D5A;
    border-radius: 2px;
    transform-origin: bottom center;
    transform: translateX(-50%) rotate(25deg);
    transition: transform 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 0 8px rgba(0,0,0,0.15);
}

.mi-gauge-center {
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%);
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #2A3D5A;
    box-shadow: 0 0 12px rgba(0,0,0,0.1);
}

.mi-gauge-label {
    margin-top: 14px;
    text-align: center;
}

.mi-gauge-label .score {
    font-size: 32px;
    font-weight: 700;
    color: var(--gold);
}

.mi-gauge-label .mood {
    font-size: 13px;
    color: var(--text-dim);
    font-weight: 500;
}

.mi-gauge-legend {
    display: flex;
    justify-content: space-between;
    width: 180px;
    margin-top: 6px;
    font-size: 10px;
    color: var(--text-muted);
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* Earnings */
.mi-earnings-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-subtle);
}

.mi-earnings-item:last-child { border-bottom: none; }

.mi-earnings-name {
    font-size: 13.5px;
    font-weight: 600;
    color: var(--navy-ink);
}

.mi-earnings-ticker {
    font-size: 11px;
    color: var(--text-muted);
    font-weight: 500;
}

.mi-earnings-date {
    font-size: 12px;
    color: var(--text-dim);
    text-align: right;
}

.mi-earnings-when {
    font-size: 10px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* CTA */
.mi-cta-card {
    background: linear-gradient(135deg, var(--navy-light) 0%, #C8D4E8 100%);
    border: 1px solid var(--gold);
    border-radius: 16px;
    padding: 28px;
    text-align: center;
}

.mi-cta-card h3 {
    font-family: 'Playfair Display', serif;
    font-size: 20px;
    color: var(--navy-ink);
    font-weight: 700;
    margin-bottom: 10px;
    justify-content: center;
}

.mi-cta-card p {
    font-size: 13px;
    color: var(--text-dim);
    line-height: 1.6;
    margin-bottom: 18px;
}

.mi-cta-btn {
    display: inline-block;
    background: var(--gold);
    color: #FFFFFF !important;
    padding: 12px 28px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    letter-spacing: 0.5px;
    transition: background 0.2s, transform 0.15s;
}

.mi-cta-btn:hover {
    background: var(--gold-dim);
    transform: translateY(-1px);
    color: #fff;
    text-decoration: none;
}

/* RESPONSIVE */
@media (max-width: 900px) {
    .mi-main { grid-template-columns: 1fr; }
    .mi-index-grid { grid-template-columns: 1fr 1fr 1fr; }
    .mi-hero, .mi-main { padding-left: 20px; padding-right: 20px; }
}

@media (max-width: 600px) {
    .mi-index-grid { grid-template-columns: 1fr; }
}

/* ANIMATIONS */
@keyframes mi-fadeUp {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}

.mi-snapshot-card,
.mi-dates-card,
.mi-sector-card,
.mi-sidebar-card,
.mi-cta-card {
    animation: mi-fadeUp 0.5s ease both;
}

.mi-dates-card { animation-delay: 0.1s; }
.mi-sector-card { animation-delay: 0.2s; }
.mi-sidebar-card:nth-child(1) { animation-delay: 0.05s; }
.mi-sidebar-card:nth-child(2) { animation-delay: 0.15s; }
.mi-sidebar-card:nth-child(3) { animation-delay: 0.25s; }
.mi-cta-card { animation-delay: 0.3s; }
