/* ================================================================
   Event Cards — Sidebar (≥1280px only)
   Loaded with media="(min-width: 1280px)" so mobile browsers
   skip download entirely.
   ================================================================ */

/* This file is loaded with media="(min-width: 1280px)" so these
   rules only apply on desktop viewports. Mobile gets the hide
   rules from event-cards.css. */
#ec-app {
    max-width: 1280px;
    display: grid;
    grid-template-columns: 480px 1fr;
    column-gap: 24px;
    align-items: stretch;
}
#ec-main {
    display: flex;
    flex-direction: column;
    min-height: 0;
}
#ec-sidebar {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 14px 0 8px;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
    transition: width 0.2s ease;
}
@media (min-width: 1920px) {
    #ec-app { max-width: 1440px; }
}

.ec-side-section {
    background: rgba(17,24,39,0.4);
    border: 1px solid rgba(0,150,255,0.12);
    border-radius: 12px;
    padding: 12px 14px;
    content-visibility: auto;
    contain-intrinsic-size: auto 200px;
}
.ec-side-title {
    font-family: var(--ec-font);
    font-size: 11px;
    letter-spacing: 1.2px;
    color: var(--ec-cyan);
    text-transform: uppercase;
    margin-bottom: 10px;
}
.ec-side-empty {
    font-size: 12px;
    color: var(--ec-muted);
    padding: 8px 0;
}

.ec-side-positions { display: flex; flex-direction: column; gap: 6px; }
.ec-side-pos {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 4px 8px;
    padding: 8px 10px;
    background: rgba(10,14,23,0.6);
    border: 1px solid rgba(0,150,255,0.10);
    border-radius: 8px;
    font-size: 11px;
    color: var(--ec-text);
    contain: layout style paint;
}
.ec-side-pos-title {
    font-size: 12px;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.ec-side-pos-side {
    color: var(--ec-muted);
    font-variant-numeric: tabular-nums;
}
.ec-side-pos-val {
    grid-column: 1 / 3;
    display: flex;
    justify-content: space-between;
    color: var(--ec-muted);
    font-size: 11px;
    font-variant-numeric: tabular-nums;
}
.ec-side-pos-pnl { font-weight: 700; }

.ec-side-upnext { display: flex; flex-direction: column; gap: 6px; }
.ec-side-up {
    display: grid;
    grid-template-columns: 32px 1fr auto;
    gap: 8px;
    align-items: center;
    padding: 6px 8px;
    background: rgba(10,14,23,0.6);
    border: 1px solid rgba(0,150,255,0.10);
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
    contain: layout style paint;
}
.ec-side-up:hover {
    background: rgba(0,207,255,0.08);
    border-color: rgba(0,207,255,0.25);
}
.ec-side-up-img {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    object-fit: cover;
    background: #1a2333;
}
.ec-side-up-title {
    font-size: 12px;
    color: var(--ec-text);
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}
.ec-side-up-idx {
    font-size: 11px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}
