﻿/* ============================================================
   wrs.css — The Whisper Report archive page (EW2027).
   Uses ew-theme.css tokens. Dark-mode aware.
   ============================================================ */

.wr-page {
    max-width: 1300px;
    margin: 0 auto;
    padding: 1.5rem 1rem 4rem;
}

.wr-head {
    text-align: left;
    margin-bottom: 1.5rem;
}

.wr-head-title {
    font-size: clamp(1.7rem, 3.6vw, 2.4rem);
    font-weight: 800;
    color: var(--text);
    margin: 0 0 .25rem;
}

    .wr-head-title sup {
        font-size: .5em;
        font-weight: 600;
    }

.wr-head-sub {
    font-size: .95rem;
    color: var(--text-muted);
    margin: 0;
}

.wr-loading {
    color: var(--text-muted);
    padding: 3rem 1rem;
    text-align: center;
}

/* ---- Current (latest) issue ---- */
.wr-current {
    margin-bottom: 3rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border);
}

.wr-current-title {
    font-size: clamp(1.3rem, 2.6vw, 1.8rem);
    font-weight: 800;
    color: var(--text);
    margin: 0 0 .35rem;
}

.wr-current-date {
    font-size: .85rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.wr-current-summary {
    color: var(--text);
    line-height: 1.6;
    margin-bottom: 1.25rem;
    max-width: 70ch;
}

.wr-read-btn {
    display: inline-block;
    padding: .55rem 1.4rem;
    background: var(--ew-color);
    color: #1b1b1b;
    font-weight: 700;
    border-radius: 8px;
    text-decoration: none;
    transition: filter 120ms ease;
}

    .wr-read-btn:hover {
        filter: brightness(1.06);
    }

/* per-ticker cards under the current issue */
.wr-ticker-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(420px, 1fr));
    gap: 1rem;
    margin-top: 2rem;
}

.wr-ticker-card {
    display: block;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: .85rem;
    text-decoration: none;
    color: inherit;
    transition: border-color 120ms ease, box-shadow 120ms ease;
}

    .wr-ticker-card:hover {
        border-color: var(--ew-color);
        box-shadow: 0 4px 16px -10px rgba(0, 0, 0, 0.4);
    }

.wr-tc-head {
    display: flex;
    align-items: center;
    gap: .6rem;
    margin-bottom: .5rem;
}

.wr-tc-logo {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #fff center/contain no-repeat;
    flex: 0 0 auto;
    border: 1px solid var(--border);
}

.wr-tc-ticker {
    font-weight: 800;
    font-size: 1.15rem;
    color: var(--text);
}

/* ---- Archive grid (infinite scroll) ---- */
.wr-past {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(480px, 1fr));
    gap: 1.25rem;
}

.wr-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.1rem;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    transition: border-color 120ms ease, box-shadow 120ms ease;
}

    .wr-card:hover {
        border-color: var(--ew-color);
        box-shadow: 0 4px 16px -10px rgba(0, 0, 0, 0.4);
    }

.wr-card-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text);
    margin: 0 0 .3rem;
}

.wr-card-date {
    font-size: .8rem;
    color: var(--text-muted);
    margin-bottom: .6rem;
}

.wr-card-summary {
    color: var(--text);
    font-size: .9rem;
    line-height: 1.5;
    margin-bottom: .75rem;
}

.wr-card-tickers {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
    margin-bottom: .75rem;
}

.wr-chip {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    padding: .2rem .5rem .2rem .3rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    text-decoration: none;
    color: var(--text);
    font-size: .78rem;
    font-weight: 600;
    transition: border-color 120ms ease;
}

    .wr-chip:hover {
        border-color: var(--ew-color);
    }

.wr-chip-logo {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #fff;
    object-fit: contain;
}

/* ---- Mini chart host ---- */
.wr-chart {
    width: 100%;
    height: 240px;
    margin-top: auto;
    border-radius: 8px;
    overflow: hidden;
}

/* ---- Mini chart overlays (reusable EWMiniChart) ---- */
.ewmc-wrap {
    position: relative;
}

.ewmc-mount {
    position: absolute;
    inset: 0;
}

.ewmc-ov {
    position: absolute;
    top: 8px;
    z-index: 3;
    pointer-events: none;
}

.ewmc-ov-left {
    left: 10px;
    right: 62px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    align-items: flex-start;
}

/* legend row (top of the left overlay) — items laid out horizontally */
.ewmc-legend {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.ewmc-legend-row {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: .72rem;
    font-weight: 600;
    color: var(--text-muted);
    white-space: nowrap;
}

.ewmc-swatch {
    width: 14px;
    height: 8px;
    border-radius: 2px;
    flex: 0 0 auto;
}

.ewmc-sw-eps {
    background: var(--chart-marker, #9389c5);
    opacity: .6;
}

.ewmc-sw-avwap {
    background: var(--chart-line, #4e2d9e);
    height: 3px;
    border-radius: 2px;
}

.ewmc-sw-pbv {
    background: linear-gradient(90deg, rgba(15,138,59,0.55) 0 50%, rgba(198,40,40,0.55) 50% 100%);
}

/* logo + ticker (below the legend) */
.ewmc-id {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.ewmc-logo {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #fff center/contain no-repeat;
    border: 1px solid var(--border);
    flex: 0 0 auto;
}

.ewmc-ticker {
    font-weight: 800;
    font-size: 1.05rem;
    color: var(--text);
    text-shadow: 0 1px 2px var(--surface, rgba(255, 255, 255, 0.6));
}

.ewmc-loading,
.ewmc-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: var(--text-muted);
    font-size: .85rem;
}

.wr-sentinel {
    height: 1px;
}

/* ============================================================
   Home-page Whisper Report promo (_HomeWhisperReport partial)
   ============================================================ */
.wrp-home {
    max-width: 1300px;
    margin: 2.5rem auto 0;
    padding: 0 1rem;
}

.wrp-home-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.wrp-home-title {
    font-size: clamp(1.3rem, 2.6vw, 1.7rem);
    font-weight: 800;
    color: var(--text);
    margin: 0;
}

    .wrp-home-title sup {
        font-size: .5em;
        font-weight: 600;
    }

.wrp-home-all {
    font-size: .9rem;
    font-weight: 600;
    color: var(--ew-color);
    text-decoration: none;
    white-space: nowrap;
}

    .wrp-home-all:hover {
        text-decoration: underline;
    }

.wrp-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.25rem;
}

.wrp-title {
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--text);
    margin: 0 0 .3rem;
}

.wrp-date {
    font-size: .82rem;
    color: var(--text-muted);
    margin-bottom: .9rem;
}

.wrp-summary {
    color: var(--text);
    line-height: 1.6;
    margin-bottom: 1rem;
    max-width: 75ch;
}

.wrp-tickers {
    display: flex;
    flex-wrap: wrap;
    gap: .45rem;
    margin-bottom: 1.1rem;
}

.wrp-chip {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    padding: .2rem .55rem .2rem .3rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    text-decoration: none;
    color: var(--text);
    font-size: .8rem;
    font-weight: 600;
    transition: border-color 120ms ease;
}

    .wrp-chip:hover {
        border-color: var(--ew-color);
    }

.wrp-chip-logo {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #fff;
    object-fit: contain;
}

.wrp-chart {
    width: 100%;
    height: 340px;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 1.1rem;
}

.wrp-read-btn {
    display: inline-block;
    padding: .55rem 1.4rem;
    background: var(--ew-color);
    color: #1b1b1b;
    font-weight: 700;
    border-radius: 8px;
    text-decoration: none;
    transition: filter 120ms ease;
}

    .wrp-read-btn:hover {
        filter: brightness(1.06);
    }
