html {
    height: 100%;
}

body.bloomberg-page {
    background-color: #000435;
    color: #d9d9d9;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.bb-grid {
    flex-grow: 1;
}

.bloomberg-page .footer {
    background-color: #000;
}

/* Metallic silver chasing light border for each box */
.bb-glow {
    position: relative;
    box-shadow:
        0 0 14px 3px rgba(230, 126, 34, 0.55),
        0 0 5px rgba(101, 67, 33, 0.6);
}

.bb-glow::before {
    content: "";
    position: absolute;
    inset: -4px;
    border-radius: 18px;
    padding: 5px;
    background: conic-gradient(
        from 0deg,
        transparent 0deg,
        #FFB733 15deg,
        #A0522D 45deg,
        transparent 75deg,
        transparent 360deg
    );
    -webkit-mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    animation: bb-chase-light 4s linear infinite;
    pointer-events: none;
}

@keyframes bb-chase-light {
    to { transform: rotate(360deg); }
}

.bb-grid {
    display: grid;
    grid-template-columns: 30px 1.4fr 1fr 0.8fr;
    grid-template-rows: auto auto;
    gap: 15px;
    margin: 10px 3px;
}

.bb-side-labels {
    grid-column: 1;
    grid-row: 1 / span 2;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.bb-label-bar {
    flex: 1;
    background: #002244;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    writing-mode: vertical-rl;
    color: #fff;
    font-size: 13px;
    font-weight: bold;
    padding: 10px 0;
}

.bb-video-box {
    grid-column: 2;
    grid-row: 1;
    background: #0d1440;
    border-radius: 15px;
    padding: 10px;
}

.bb-spotlight-col {
    grid-column: 3;
    grid-row: 1;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.bb-spotlight-card {
    background: #0d1440;
    border-radius: 15px;
    padding: 16px;
}

.bb-spotlight-card h2 {
    color: #fff;
    font-size: 20px;
    margin: 0 0 8px;
}

.bb-ticker-sym {
    font-size: 13px;
    color: #6c5ce7;
    font-weight: bold;
    margin-left: 6px;
}

.bb-spotlight-card p {
    font-size: 13px;
    color: #c9d6e8;
    margin: 0;
}

.bb-graph-box {
    background: #e8e8e8;
    border-radius: 15px;
    padding: 10px;
    height: 160px;
}

.bb-watchlist {
    grid-column: 4;
    grid-row: 1 / span 2;
    background: linear-gradient(145deg, #7f7f7f, #4a4a4a, #2d2d2d);
    border: 1px solid #9c9c9c;
    border-radius: 16px;
    padding: 12px;
    display: flex;
    flex-direction: column;
}

.bb-watchlist-title {
    text-align: center;
    font-weight: bold;
    color: #eee;
    font-size: 14px;
    margin-bottom: 10px;
    border-bottom: 1px solid rgba(255,255,255,0.15);
    padding-bottom: 8px;
}

.bb-ticker-viewport {
    flex-grow: 1;
    overflow: hidden;
}

.bb-ticker-track {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.bb-stock-btn {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(to bottom, #7d7d7d, #505050);
    border: 1px solid #9d9d9d;
    border-radius: 10px;
    padding: 8px 10px;
    color: #fff;
    font-size: 12px;
    animation: bb-slide-in 0.4s ease;
}

@keyframes bb-slide-in {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.bb-stock-sym {
    font-weight: bold;
}

.bb-up {
    color: #69BE28;
}

.bb-down {
    color: #e24b4a;
}

.bb-news-feed {
    grid-column: 2;
    grid-row: 2;
    background: #0d1440;
    border-radius: 15px;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.bb-news-item {
    font-size: 13px;
    color: #c9d6e8;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    padding-bottom: 8px;
}

.bb-upcoming {
    grid-column: 3;
    grid-row: 2;
    background: #0d1440;
    border-radius: 15px;
    padding: 14px;
}

.bb-upcoming-title {
    font-weight: bold;
    color: #fff;
    font-size: 14px;
    margin-bottom: 8px;
}

.bb-upcoming-item {
    font-size: 12px;
    color: #c9d6e8;
    margin-bottom: 6px;
}

@media (max-width: 900px) {
    .bb-grid {
        grid-template-columns: 1fr;
    }
    .bb-video-box, .bb-spotlight-col, .bb-watchlist, .bb-news-feed, .bb-upcoming, .bb-side-labels {
        grid-column: 1;
    }
    .bb-side-labels {
        flex-direction: row;
    }
}

/* ===== Individual Stock Detail Pages ===== */
.stock-back-link {
    display: inline-block;
    margin: 15px 3px 0;
    color: #FFB733;
    text-decoration: none;
    font-size: 14px;
    font-weight: bold;
}

.stock-back-link:hover {
    color: #fff;
}

.stock-detail-wrap {
    margin: 15px 3px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.stock-header-card {
    background: #0d1440;
    border-radius: 15px;
    padding: 20px;
    display: flex;
    align-items: baseline;
    gap: 16px;
    flex-wrap: wrap;
}

.stock-header-card h1 {
    color: #fff;
    font-size: 28px;
    margin: 0;
}

.stock-sym-big {
    color: #6c5ce7;
    font-size: 16px;
    font-weight: bold;
}

.stock-price-big {
    color: #fff;
    font-size: 22px;
    font-weight: bold;
    margin-left: auto;
}

.stock-chg-big {
    font-size: 16px;
    font-weight: bold;
}

.stock-desc-card {
    background: #0d1440;
    border-radius: 15px;
    padding: 18px;
    color: #c9d6e8;
    font-size: 14px;
}

.stock-graph-card {
    background: #e8e8e8;
    border-radius: 15px;
    padding: 15px;
    height: 320px;
}
