/* =========================================================
   TRADERS DE ELITE
   MARKET DESK
   ========================================================= */

.market-hero {
    min-height: 48vh;
    display: flex;
    align-items: center;
    padding: 150px 0 80px;
    background:
        radial-gradient(
            circle at 80% 30%,
            rgba(212, 175, 55, 0.10),
            transparent 35%
        ),
        var(--bg);
}

.market-hero-content {
    max-width: 760px;
}

.market-hero h1 {
    margin: 18px 0;
    font-family: "Playfair Display", serif;
    font-size: clamp(3rem, 7vw, 6rem);
    line-height: .95;
    letter-spacing: -3px;
}

.market-hero h1 span {
    color: var(--gold);
}

.market-hero p {
    max-width: 620px;
    color: var(--muted);
    font-size: 1.1rem;
    line-height: 1.8;
}

.market-status {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 25px;
    padding: 10px 15px;
    border: 1px solid var(--border);
    border-radius: 999px;
    color: var(--muted);
    background: rgba(255,255,255,.025);
}

.status-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--muted-2);
}

.status-dot.online {
    background: #45d483;
    box-shadow: 0 0 12px rgba(69,212,131,.6);
}

.status-dot.offline {
    background: #d94b4b;
}


/* =========================================================
   SECTIONS
   ========================================================= */

.market-section {
    padding: 70px 0;
}

.chart-section {
    padding-top: 20px;
}

.section-heading {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 20px;
    margin-bottom: 30px;
}

.section-heading h2 {
    margin-top: 8px;
}

.last-update {
    color: var(--muted-2);
    font-size: .85rem;
}


/* =========================================================
   WATCHLIST
   ========================================================= */

.asset-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 14px;
}

.asset-card {
    appearance: none;
    width: 100%;
    text-align: left;
    cursor: pointer;

    padding: 22px;

    border: 1px solid var(--border-light);
    border-radius: var(--radius);

    background: var(--surface);

    color: var(--white);

    transition:
        transform .25s ease,
        border-color .25s ease,
        background .25s ease;
}

.asset-card:hover {
    transform: translateY(-3px);
    border-color: var(--border);
}

.asset-card.active {
    border-color: var(--gold);
    background:
        linear-gradient(
            145deg,
            rgba(212,175,55,.10),
            rgba(255,255,255,.02)
        );
}

.asset-name {
    display: block;
    margin-bottom: 12px;
    color: var(--muted);
    font-size: .82rem;
    font-weight: 600;
    letter-spacing: .08em;
}

.asset-price {
    display: block;
    margin-bottom: 8px;
    font-size: 1.35rem;
}

.asset-change {
    font-size: .85rem;
    color: var(--muted);
}

.asset-change.positive {
    color: #45d483;
}

.asset-change.negative {
    color: #e05b5b;
}


/* =========================================================
   CHART PANEL
   ========================================================= */

.chart-panel {
    overflow: hidden;

    border: 1px solid var(--border-light);
    border-radius: var(--radius);

    background: var(--surface);

    box-shadow:
        0 25px 70px rgba(0,0,0,.25);
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;

    padding: 25px;

    border-bottom: 1px solid var(--border-light);
}

.selected-market {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 8px;
}

.selected-market h2 {
    margin: 0;
    font-size: 1.5rem;
}

.selected-price {
    font-weight: 700;
}

.selected-change {
    font-size: .9rem;
}

.selected-change.positive {
    color: #45d483;
}

.selected-change.negative {
    color: #e05b5b;
}


/* =========================================================
   TIMEFRAMES
   ========================================================= */

.timeframes {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.timeframe {
    border: 1px solid var(--border-light);
    background: transparent;

    color: var(--muted);

    padding: 8px 12px;

    border-radius: 8px;

    cursor: pointer;

    font-size: .75rem;
    font-weight: 700;
}

.timeframe:hover,
.timeframe.active {
    border-color: var(--gold);
    color: var(--gold);
    background: rgba(212,175,55,.08);
}


/* =========================================================
   CHART
   ========================================================= */

.market-chart {
    position: relative;
    width: 100%;
    height: 500px;
    background: #080808;
}

.chart-loading {
    position: absolute;
    inset: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    color: var(--muted);

    font-size: .9rem;

    z-index: 5;
    pointer-events: none;
}

.chart-footer {
    display: flex;
    justify-content: space-between;
    gap: 20px;

    padding: 14px 20px;

    border-top: 1px solid var(--border-light);

    color: var(--muted-2);

    font-size: .75rem;
}


/* =========================================================
   MARKET INFO
   ========================================================= */

.market-info-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
}

.info-card {
    padding: 25px;

    border: 1px solid var(--border-light);
    border-radius: var(--radius);

    background: var(--surface);
}

.info-card strong {
    display: block;
    margin-top: 12px;

    font-size: 1.35rem;
}


/* =========================================================
   DISCLAIMER
   ========================================================= */

.market-disclaimer {
    padding: 0 0 80px;
}

.disclaimer-box {
    padding: 25px;

    border: 1px solid rgba(212,175,55,.15);
    border-radius: var(--radius);

    background: rgba(212,175,55,.04);
}

.disclaimer-box strong {
    color: var(--gold);
}

.disclaimer-box p {
    margin: 10px 0 0;
    color: var(--muted);
    line-height: 1.7;
    font-size: .9rem;
}


/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 1000px) {

    .asset-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .market-info-grid {
        grid-template-columns: repeat(2, 1fr);
    }

}


@media (max-width: 750px) {

    .market-hero {
        padding-top: 120px;
    }

    .market-hero h1 {
        letter-spacing: -1.5px;
    }

    .section-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .asset-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}


    .chart-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .market-chart {
        height: 400px;
    }

}


@media (max-width: 500px) {

    .asset-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}


    .market-info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

    .market-chart {
        height: 350px;
    }

    .chart-footer {
        flex-direction: column;
        gap: 6px;
    }

}