/* ═══════════════════════════════════════════════════════════════════════════
   LIVE ARENA - "Live Now" takeover of the Action Portal
   Mirrors the VIP technical integration:
   - all state on <body> (data-pp-live / data-pp-live-stage), CSS is attribute-scoped
   - tiny WebP backdrop, hidden until decoded (.is-ready), then faded in
   - animations are transform/opacity only and run ONLY while body[data-pp-screen="portal"]
   - no blend modes, big layers isolated with contain
   VIP art/attributes are never touched: the arena has its own backdrop and only borrows a thin
   tier rim (--pla-tier) on the player card.
   ═══════════════════════════════════════════════════════════════════════════ */

/* Portal chrome is hidden while the arena owns the screen */
body[data-pp-live="on"] #hud-sticky-header { display: none !important; }
body[data-pp-live="on"] #hud-pulse-array {
    padding: 0 !important;
    gap: 0 !important;
    overflow: hidden !important;
}

.pla {
    --pla-a: #22c55e;
    --pla-tier: #fbbf24;
    position: relative;
    flex: 1 1 0%;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    contain: layout paint;
    background: #05070c;
    color: #fff;
    font-family: 'Manrope', sans-serif;
    --pla-dock: calc(clamp(54px, 8.5dvh, 62px) + env(safe-area-inset-bottom, 0px));
    padding-bottom: var(--pla-dock);
    box-sizing: border-box;
    isolation: isolate;
}

/* ── Backdrop: art + stage glow + light cones (all static layers; motion only on portal screen) ── */
.pla-bg, .pla-glow, .pla-cones { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.pla-bg {
    background:
        linear-gradient(180deg, rgba(4, 6, 12, 0.78) 0%, rgba(4, 6, 12, 0.18) 22%, rgba(4, 6, 12, 0.1) 52%, rgba(4, 6, 12, 0.7) 82%, rgba(4, 6, 12, 0.92) 100%),
        var(--pla-art) center 38% / cover no-repeat;
    opacity: 0;
    transition: opacity 0.5s ease;
    will-change: opacity;
}
.pla.is-ready .pla-bg { opacity: 1; }
.pla[data-theme="night"] { --pla-art: url('../../images/live_bg/live_night.webp'); }
.pla[data-theme="day"] { --pla-art: url('../../images/live_bg/live_day.webp'); }

.pla-glow {
    background: radial-gradient(70% 38% at 50% 46%, color-mix(in srgb, var(--pla-a) 34%, transparent) 0%, transparent 70%);
    opacity: 0.75;
    will-change: opacity;
}
.pla[data-theme="day"] .pla-glow { opacity: 0.4; }
.pla-cones {
    background:
        linear-gradient(115deg, rgba(255, 200, 120, 0.2) 0%, transparent 38%) top left / 60% 55% no-repeat,
        linear-gradient(245deg, rgba(255, 200, 120, 0.2) 0%, transparent 38%) top right / 60% 55% no-repeat;
    opacity: 0.7;
}
.pla[data-theme="day"] .pla-cones {
    background: linear-gradient(160deg, rgba(255, 244, 214, 0.28) 0%, transparent 42%) top left / 80% 50% no-repeat;
}

/* Finals: gold flood */
.pla[data-stage="finals"] .pla-glow { background: radial-gradient(75% 42% at 50% 44%, rgba(251, 191, 36, 0.4) 0%, transparent 72%); }

@keyframes pla-breathe { 0%, 100% { opacity: 0.55; } 50% { opacity: 0.95; } }
@keyframes pla-sweep { 0%, 100% { opacity: 0.45; } 50% { opacity: 0.85; } }
@keyframes pla-pulse { 0% { transform: scale(0.9); opacity: 0.5; } 50% { transform: scale(1.15); opacity: 1; } 100% { transform: scale(0.9); opacity: 0.5; } }
@keyframes pla-rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

body[data-pp-screen="portal"] .pla:not(.is-calm) .pla-glow { animation: pla-breathe 6s ease-in-out infinite; }
body[data-pp-screen="portal"] .pla-live i,
body[data-pp-screen="portal"] .pla-stage i,
body[data-pp-screen="portal"] .pla-btn-pri.is-live i,
body[data-pp-screen="portal"] .pla-return-chip i { animation: pla-pulse 1.4s ease-in-out infinite; }
.pla-enter .pla-me, .pla-enter .pla-hero, .pla-enter .pla-results, .pla-enter .pla-floor { animation: pla-rise 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
.pla-enter .pla-hero { animation-delay: 0.07s; }
.pla-enter .pla-results { animation-delay: 0.14s; }
.pla-enter .pla-floor { animation-delay: 0.21s; }
@media (prefers-reduced-motion: reduce) {
    .pla-glow, .pla-cones, .pla i, .pla-enter * { animation: none !important; }
}

/* ── Layout ── */
.pla-top, .pla-scroll, .pla-bar { position: relative; z-index: 2; }
.pla-top {
    display: flex; align-items: center; gap: clamp(6px, 2vw, 10px);
    padding: calc(8px + env(safe-area-inset-top, 0px)) clamp(10px, 3vw, 14px) 8px;
    flex-shrink: 0; min-width: 0;
}
.pla-back, .pla-theme, .pla-x {
    font-family: 'Oswald', sans-serif; font-weight: 800; letter-spacing: 0.8px; text-transform: uppercase;
    background: rgba(15, 23, 42, 0.82); border: 1px solid rgba(255, 255, 255, 0.14); color: rgba(255, 255, 255, 0.85); cursor: pointer; flex-shrink: 0;
    -webkit-tap-highlight-color: transparent; touch-action: manipulation;
}
.pla-back { border-radius: 8px; min-height: 36px; min-width: 36px; padding: 7px 10px; font-size: clamp(9px, 2.5vw, 10.5px); white-space: nowrap; }
.pla-theme, .pla-x { width: 36px; height: 36px; border-radius: 50%; font-size: clamp(12.5px, 3.59vw, 14px); display: flex; align-items: center; justify-content: center; padding: 0; }
.pla-top-mid { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 1px; }
.pla-live {
    display: inline-flex; align-items: center; gap: 5px; font-family: 'Oswald', sans-serif; font-size: clamp(8.5px, 2.56vw, 10px); font-weight: 800;
    letter-spacing: 1.4px; color: #f87171;
}
.pla-live i, .pla-stage i, .pla-btn-pri.is-live i, .pla-return-chip i {
    width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 8px currentColor; display: inline-block; flex-shrink: 0;
}
.pla-top-t {
    font-family: 'Oswald', sans-serif; font-weight: 700; font-size: clamp(13px, 3.8vw, 16px); letter-spacing: 0.6px; text-transform: uppercase;
    max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-shadow: 0 1px 6px rgba(0, 0, 0, 0.8);
}

.pla-scroll {
    flex: 1 1 0%; min-height: 0; overflow-y: auto; overflow-x: hidden; scrollbar-width: none;
    padding: 4px clamp(10px, 3vw, 14px) 14px; display: flex; flex-direction: column; gap: clamp(8px, 2.2vh, 12px);
}
.pla-scroll::-webkit-scrollbar { display: none; }
.pla-scroll > * { flex-shrink: 0; }

/* Glass cards */
.pla-me, .pla-hero, .pla-results, .pla-floor {
    background: rgba(10, 16, 30, 0.78); border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 18px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.06);
    box-sizing: border-box; min-width: 0;
}

/* Spotlight card (me) */
.pla-me { display: flex; align-items: center; gap: 12px; padding: 12px 14px; position: relative; overflow: hidden; }
.pla-me::before {
    content: ''; position: absolute; left: -20px; top: -30px; width: 140px; height: 140px; border-radius: 50%; pointer-events: none;
    background: radial-gradient(circle, color-mix(in srgb, var(--pla-tier) 38%, transparent) 0%, transparent 70%);
}
.pla-me-txt { min-width: 0; flex: 1; position: relative; }
.pla-me-name {
    font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(18px, 5.4vw, 22px); letter-spacing: 0.5px; line-height: 1.1;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-shadow: 0 1px 6px rgba(0, 0, 0, 0.7);
}
.pla-me-sub { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 8px; margin-top: 4px; font-size: clamp(9.5px, 2.82vw, 11px); }
.pla-stage {
    display: inline-flex; align-items: center; gap: 5px; font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(9px, 2.69vw, 10.5px); letter-spacing: 1px;
    color: var(--pla-a); background: color-mix(in srgb, var(--pla-a) 16%, transparent); border: 1px solid color-mix(in srgb, var(--pla-a) 45%, transparent);
    border-radius: 8px; padding: 2px 8px;
}
.pla-dim { color: rgba(255, 255, 255, 0.58); font-weight: 600; }

/* Avatars + name plates (readable, never on the court lines) */
.pla-av {
    --s: 40;
    width: clamp(calc(var(--s) * 0.78px), calc(var(--s) / 3.9 * 1vw), calc(var(--s) * 1px));
    height: clamp(calc(var(--s) * 0.78px), calc(var(--s) / 3.9 * 1vw), calc(var(--s) * 1px));
    position: relative; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; flex-shrink: 0; overflow: visible;
    background: rgba(15, 23, 42, 0.8); box-shadow: 0 0 0 2.5px var(--pla-ring, rgba(255, 255, 255, 0.35)), 0 4px 12px rgba(0, 0, 0, 0.55);
}
.pla-av-img { position: absolute; inset: 0; border-radius: 50%; overflow: hidden; display: block; }
.pla-av-img img {
    position: absolute !important; inset: 0 !important; width: 100% !important; height: 100% !important; max-width: none !important;
    object-fit: cover !important; transform: none !important; margin: 0 !important; display: block;
}
.pla-av-mono { display: none; font-family: 'Oswald', sans-serif; font-weight: 800; font-size: 1.1em; }
.pla-av.pla-av-fallback .pla-av-mono { display: block; font-size: clamp(13px, calc(var(--s) * 0.1vw), calc(var(--s) * 0.42px)); }
.pla-av-guest {
    display: none !important;
}
.pla-plate {
    display: inline-flex; flex-direction: column; align-items: center; max-width: 100%; margin-top: 3px; padding: 0; line-height: 1.1;
    background: transparent; border: none; border-radius: 0;
}
.pla-plate b { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(10px, 2.8vw, 12px); letter-spacing: 0.5px; text-transform: uppercase; max-width: clamp(58px, 20vw, 84px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pla-plate em { display: none !important; }

/* Photo 2 Avatar Seat and Match Styling */
.pm-avatar-seat {
    position: relative;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: visible;
}
.pm-avatar-name {
    font-family: 'Oswald', sans-serif;
    font-size: clamp(9.5px, 1.3vw, 12px);
    font-weight: 800;
    white-space: nowrap;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    max-width: 72px;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: center;
}
.pm-game-card {
    position: relative;
    background: linear-gradient(180deg, #0d111c 0%, #070a12 100%);
    border: 1.5px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    padding: 14px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    box-sizing: border-box;
    width: 100%;
}
.match-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    width: 100%;
    gap: 8px;
}
.team-side {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    flex: 1;
    min-width: 0;
}
.score-tunnel {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex-shrink: 0;
    padding: 0 6px;
}
.score-input {
    width: 48px;
    height: 52px;
    text-align: center;
    font-size: 26px;
    font-weight: 900;
    border-radius: 10px;
    outline: none;
    font-family: 'Oswald', sans-serif;
    box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.4);
    -moz-appearance: textfield;
    appearance: textfield;
}
.score-input::-webkit-outer-spin-button,
.score-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.vs-divider {
    font-family: 'Oswald', sans-serif;
    font-size: 13px;
    font-weight: 900;
    color: rgba(255, 255, 255, 0.4);
    padding: 0 4px;
}
.btn-enter {
    width: 100%;
    padding: 12px;
    border-radius: 10px;
    border: none;
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    font-family: 'Oswald', sans-serif;
    font-size: 13.5px;
    font-weight: 800;
    letter-spacing: 1.5px;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.3);
    text-transform: uppercase;
    transition: all 0.2s;
}
.btn-enter:active {
    transform: scale(0.98);
}

/* Hero: my match on a vertical, top-down court */
.pla-hero { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 8px; }
.pla-hero-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-width: 0; }
.pla-court-tag { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(11.5px, 3.33vw, 13px); letter-spacing: 1.2px; color: #fff; }
.pla-badge {
    font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(8.5px, 2.44vw, 9.5px); letter-spacing: 0.8px; text-transform: uppercase; color: var(--pla-a);
    background: color-mix(in srgb, var(--pla-a) 16%, transparent); border: 1px solid color-mix(in srgb, var(--pla-a) 45%, transparent);
    border-radius: 8px; padding: 2px 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 60%;
}
.pla-court {
    position: relative; height: clamp(170px, 27dvh, 250px); border-radius: 12px; overflow: hidden;
    background: linear-gradient(180deg, rgba(23, 74, 140, 0.82), rgba(18, 58, 112, 0.88));
    border: 1px solid rgba(255, 255, 255, 0.18); box-shadow: inset 0 0 28px rgba(0, 0, 0, 0.35);
    display: flex; flex-direction: column; justify-content: space-between; padding: 8px 6px;
}
.pla[data-theme="day"] .pla-court { background: linear-gradient(180deg, rgba(30, 105, 160, 0.82), rgba(24, 84, 130, 0.88)); }
.pla-court-lines { position: absolute; inset: 0; pointer-events: none;
    background:
        linear-gradient(rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0.5)) 50% 50% / 2px 100% no-repeat,
        linear-gradient(rgba(255, 255, 255, 0.4), rgba(255, 255, 255, 0.4)) 0 28% / 100% 1.5px no-repeat,
        linear-gradient(rgba(255, 255, 255, 0.4), rgba(255, 255, 255, 0.4)) 0 72% / 100% 1.5px no-repeat;
}
.pla-team { position: relative; display: flex; justify-content: space-evenly; align-items: flex-start; z-index: 1; }
.pla-slot { display: flex; flex-direction: column; align-items: center; min-width: 0; max-width: 46%; }
.pla-net {
    position: relative; z-index: 2; height: 4px; margin: 0 -6px; background: rgba(255, 255, 255, 0.85); box-shadow: 0 0 10px rgba(255, 255, 255, 0.6);
    display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.pla-score {
    font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(12.5px, 3.59vw, 14px); letter-spacing: 1px; color: #fff; background: rgba(8, 12, 24, 0.92);
    border: 1px solid color-mix(in srgb, var(--pla-a) 70%, transparent); border-radius: 8px; padding: 2px 12px; box-shadow: 0 0 14px color-mix(in srgb, var(--pla-a) 50%, transparent);
}
.pla-court-field { justify-content: center; height: auto; min-height: 0; padding: 12px 6px 10px; }
.pla-field { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px 2px; justify-items: center; }
.pla-field .pla-plate b { max-width: clamp(44px, 14vw, 60px); font-size: clamp(9.5px, 2.82vw, 11px); }
.pla-hero-line { font-size: clamp(10.5px, 3.08vw, 12px); line-height: 1.4; color: rgba(255, 255, 255, 0.82); text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8); }
.pla-hero-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.pla-chip {
    font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(8.5px, 2.44vw, 9.5px); letter-spacing: 0.7px; text-transform: uppercase; color: #cbd5e1;
    background: rgba(255, 255, 255, 0.07); border: 1px solid rgba(255, 255, 255, 0.14); border-radius: 8px; padding: 2px 8px;
}
.pla-chip-amber { color: #fbbf24; background: rgba(245, 158, 11, 0.16); border-color: rgba(245, 158, 11, 0.45); }

/* Section headers */
.pla-sec-h, .pla-floor summary {
    display: flex; align-items: center; justify-content: space-between; gap: 8px; font-family: 'Oswald', sans-serif; font-weight: 800;
    font-size: clamp(9.5px, 2.82vw, 11px); letter-spacing: 1.2px; color: rgba(255, 255, 255, 0.7); text-transform: uppercase;
}
.pla-rec { color: #fbbf24; }

/* Results strip */
.pla-results { padding: 10px 12px 12px; }
.pla-res-row { display: flex; gap: 6px; margin-top: 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.pla-res-row::-webkit-scrollbar { display: none; }
.pla-res {
    display: inline-flex; align-items: center; gap: 5px; flex-shrink: 0; font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(10.5px, 3.08vw, 12px);
    border-radius: 8px; min-height: 32px; padding: 5px 10px; white-space: nowrap; border: 1px solid; background: transparent;
}
.pla-res b { font-size: clamp(8.5px, 2.56vw, 10px); border-radius: 4px; padding: 0 4px; }
.pla-res em { font-style: normal; font-family: 'Manrope', sans-serif; font-weight: 600; font-size: clamp(8.5px, 2.56vw, 10px); opacity: 0.7; }
.pla-res.w { color: #4ade80; background: rgba(34, 197, 94, 0.14); border-color: rgba(34, 197, 94, 0.4); }
.pla-res.w b { background: #22c55e; color: #052e16; }
.pla-res.l { color: #f87171; background: rgba(239, 68, 68, 0.14); border-color: rgba(239, 68, 68, 0.4); }
.pla-res.l b { background: #ef4444; color: #fff; }
.pla-res-add { color: #38bdf8; background: rgba(56, 189, 248, 0.12); border-color: rgba(56, 189, 248, 0.45); cursor: pointer; letter-spacing: 0.6px; }
.pla-res-empty { font-size: clamp(9.5px, 2.82vw, 11px); align-self: center; white-space: normal; }

/* The Floor */
.pla-floor { padding: 10px 12px; }
.pla-floor summary { cursor: pointer; list-style: none; }
.pla-floor summary::-webkit-details-marker { display: none; }
.pla-floor summary em { font-style: normal; color: rgba(255, 255, 255, 0.5); font-size: clamp(8.5px, 2.56vw, 10px); }
.pla-floor > *:not(summary) { margin-top: 9px; }
.pla-steps { display: flex; gap: 5px; flex-wrap: wrap; }
.pla-step { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(8.5px, 2.56vw, 10px); letter-spacing: 0.6px; color: rgba(255, 255, 255, 0.5); border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 8px; padding: 3px 8px; }
.pla-step em { font-style: normal; opacity: 0.8; }
.pla-step.done { color: #4ade80; border-color: rgba(34, 197, 94, 0.4); background: rgba(34, 197, 94, 0.1); }
.pla-step.act { color: #fbbf24; border-color: rgba(245, 158, 11, 0.5); background: rgba(245, 158, 11, 0.12); }
.pla-note { font-size: clamp(10.5px, 3.08vw, 12px); line-height: 1.4; color: rgba(255, 255, 255, 0.82); }
.pla-meta { display: flex; gap: 6px; flex-wrap: wrap; }
.pla-lane { display: flex; align-items: center; gap: 8px; background: rgba(0, 0, 0, 0.3); border: 1px solid rgba(255, 255, 255, 0.08); border-radius: 10px; padding: 7px 10px; min-width: 0; }
.pla-lane-c { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(9.5px, 2.82vw, 11px); color: #38bdf8; letter-spacing: 0.8px; flex-shrink: 0; }
.pla-lane-t { flex: 1; min-width: 0; font-size: clamp(10.5px, 3.08vw, 12px); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pla-lane-t i { opacity: 0.5; font-style: normal; font-size: clamp(8.5px, 2.56vw, 10px); }
.pla-lane-s { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(11.5px, 3.33vw, 13px); color: #fbbf24; flex-shrink: 0; }
.pla-roster { display: flex; flex-wrap: wrap; gap: 8px 10px; }
.pla-rt { display: flex; flex-direction: column; align-items: center; gap: 3px; width: clamp(40px, 12vw, 48px); min-width: 0; }
.pla-rt span:last-child { font-family: 'Oswald', sans-serif; font-weight: 700; font-size: clamp(8.5px, 2.56vw, 10px); letter-spacing: 0.4px; text-transform: uppercase; color: rgba(255, 255, 255, 0.78); max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Bottom action bar (sticky above the dock) */
.pla-bar {
    position: absolute; left: 0; right: 0; bottom: var(--pla-dock); z-index: 3;
    display: flex; gap: 8px; padding: 10px clamp(10px, 3vw, 14px);
    background: linear-gradient(to top, rgba(4, 6, 12, 0.95) 0%, rgba(4, 6, 12, 0.7) 70%, transparent 100%);
}
.pla-btn {
    font-family: 'Oswald', sans-serif; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; border-radius: 8px; cursor: pointer;
    font-size: clamp(11px, 3.2vw, 13px); padding: 12px 10px; display: flex; align-items: center; justify-content: center; gap: 7px; min-width: 0;
    -webkit-tap-highlight-color: transparent; touch-action: manipulation; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.pla-btn-sec { flex: 1 1 0; color: rgba(255, 255, 255, 0.85); background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.14); }
.pla-btn-pri {
    flex: 1.35 1 0; color: #fff; border: none;
    background: linear-gradient(135deg, var(--pla-a), color-mix(in srgb, var(--pla-a) 60%, #000));
    box-shadow: 0 0 18px color-mix(in srgb, var(--pla-a) 50%, transparent);
}
.pla-btn-pri.is-live { background: linear-gradient(135deg, #ef4444, #b91c1c); box-shadow: 0 0 18px rgba(239, 68, 68, 0.5); }
.pla-btn:active { transform: scale(0.98); }

/* Browse mode: return chip to the arena */
.pla-return-chip {
    display: flex; align-items: center; gap: 8px; width: 100%; box-sizing: border-box; margin-bottom: 10px; padding: 9px 12px; border-radius: 12px; cursor: pointer;
    font-family: 'Oswald', sans-serif; font-weight: 800; letter-spacing: 0.8px; font-size: clamp(9.5px, 2.82vw, 11px); text-transform: uppercase; color: var(--pla-a);
    background: color-mix(in srgb, var(--pla-a) 14%, rgba(10, 16, 30, 0.8)); border: 1px solid color-mix(in srgb, var(--pla-a) 50%, transparent);
}
.pla-return-chip span { flex: 1; text-align: left; color: #fff; }
.pla-return-chip b { color: var(--pla-a); }

/* Compact phones */
@media (max-width: 380px) {
    .pla-me { padding: 10px 11px; gap: 10px; }
    .pla-court:not(.pla-court-field) { height: clamp(170px, 29dvh, 240px); }
    .pla-back span { display: none; }
    .pla-back { padding: 7px; font-size: 16px; }
}
@media (max-height: 700px) {
    .pla-me::before { display: none; }
    .pla-court:not(.pla-court-field) { height: clamp(150px, 27dvh, 210px); }
    .pla-hero-line { display: none; }
}

/* ═══ Organize a Game: user scope (NOW card, MY SCHEDULE & RESULTS) ═══ */
.pla-court-preview { opacity: 0.78; filter: saturate(0.85); }
.pla-court-preview .pla-score { border-color: rgba(167, 139, 250, 0.7); box-shadow: 0 0 14px rgba(167, 139, 250, 0.45); color: #ddd6fe; }
.pla-done { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: clamp(14px, 3dvh, 22px) 8px; border-radius: 12px; background: rgba(0, 0, 0, 0.28); border: 1px solid rgba(255, 255, 255, 0.1); }
.pla-done b { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(24px, 7vw, 30px); letter-spacing: 0.8px; color: #34d399; }
.pla-done span { font-family: 'Oswald', sans-serif; font-weight: 700; font-size: clamp(9.5px, 2.6vw, 11px); letter-spacing: 1px; color: rgba(255, 255, 255, 0.65); }

.pla-sched { background: rgba(10, 16, 30, 0.78); border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 18px; padding: 10px 12px 10px; box-sizing: border-box; min-width: 0; box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.06); }
.pla-rows { display: flex; flex-direction: column; gap: 6px; margin-top: 9px; }
.pla-row { display: flex; align-items: center; gap: 9px; min-width: 0; padding: 7px 9px; border-radius: 12px; background: rgba(0, 0, 0, 0.26); border: 1px solid rgba(255, 255, 255, 0.07); }
.pla-row.is-now { border-color: color-mix(in srgb, var(--pla-a) 65%, transparent); background: color-mix(in srgb, var(--pla-a) 12%, rgba(0, 0, 0, 0.3)); box-shadow: 0 0 14px color-mix(in srgb, var(--pla-a) 28%, transparent); }
.pla-row.break { opacity: 0.72; }
.pla-row.done { opacity: 0.95; }
.pla-row-r { flex: 0 0 auto; min-width: clamp(26px, 8vw, 32px); text-align: center; font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(11px, 3.1vw, 12.5px); letter-spacing: 0.6px; color: rgba(255, 255, 255, 0.7); }
.pla-row-m { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.pla-row-m b { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(11.5px, 3.2vw, 13px); letter-spacing: 0.6px; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pla-row-m em { font-style: normal; font-weight: 600; font-size: clamp(10px, 2.8vw, 11px); color: rgba(255, 255, 255, 0.6); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pla-row-s { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; }
.pla-st { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(9.5px, 2.6vw, 10.5px); letter-spacing: 0.8px; color: rgba(255, 255, 255, 0.55); border: 1px solid rgba(255, 255, 255, 0.14); border-radius: 8px; padding: 3px 8px; background: transparent; }
.pla-row.is-now .pla-st { color: var(--pla-a); border-color: color-mix(in srgb, var(--pla-a) 55%, transparent); }
.pla-st-live { color: #fff !important; background: linear-gradient(135deg, #ef4444, #b91c1c); border-color: transparent !important; cursor: pointer; min-height: 32px; padding: 5px 12px; box-shadow: 0 0 12px rgba(239, 68, 68, 0.45); }
.pla-edit { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(9.5px, 2.6vw, 10.5px); letter-spacing: 0.8px; color: #38bdf8; background: rgba(56, 189, 248, 0.12); border: 1px solid rgba(56, 189, 248, 0.45); border-radius: 8px; min-height: 32px; padding: 5px 10px; cursor: pointer; }
.pla-sess { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 10px; padding-top: 9px; border-top: 1px solid rgba(255, 255, 255, 0.08); min-width: 0; }
.pla-sess span { font-family: 'Oswald', sans-serif; font-weight: 700; font-size: clamp(9.5px, 2.6vw, 10.5px); letter-spacing: 0.8px; color: rgba(255, 255, 255, 0.55); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.pla-sess button { flex: 0 0 auto; font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(9.5px, 2.6vw, 10.5px); letter-spacing: 0.7px; color: #38bdf8; background: rgba(56, 189, 248, 0.12); border: 1px solid rgba(56, 189, 248, 0.45); border-radius: 8px; min-height: 32px; padding: 5px 9px; cursor: pointer; white-space: nowrap; }
.pla[data-stage="break"] .pla-glow { background: radial-gradient(70% 38% at 50% 46%, rgba(167, 139, 250, 0.3) 0%, transparent 70%); }
@media (max-width: 380px) { .pla-row { gap: 7px; padding: 6px 7px; } .pla-sess span { display: none; } .pla-sess button { margin-left: auto; } }

.pla-past { margin-top: 9px; }
.pla-past summary { list-style: none; display: flex; align-items: center; gap: 8px; min-height: 36px; padding: 6px 10px; border-radius: 12px; cursor: pointer; background: rgba(0, 0, 0, 0.26); border: 1px solid rgba(255, 255, 255, 0.07); }
.pla-past summary::-webkit-details-marker { display: none; }
.pla-past summary > span:first-child { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(9.5px, 2.6vw, 10.5px); letter-spacing: 1px; color: rgba(255, 255, 255, 0.6); flex: 0 0 auto; }
.pla-past-chips { flex: 1 1 0; min-width: 0; display: flex; gap: 5px; overflow: hidden; }
.pla-past summary i { font-style: normal; color: rgba(255, 255, 255, 0.55); transition: transform 0.2s; flex: 0 0 auto; }
.pla-past[open] summary i { transform: rotate(180deg); }
.pla-past .pla-rows { margin-top: 6px; }
.pla-res.mini { min-height: 0; padding: 2px 7px; font-size: clamp(10.5px, 2.9vw, 11.5px); }
.pla-res.mini b { font-size: 9px; }

/* ═══ Organize a Game v2: compact user scope (me + now card, folds, inline score entry) ═══ */
.pla-pm { display: flex; flex-direction: column; gap: 10px; padding: 12px; border-radius: 18px; box-sizing: border-box; min-width: 0;
    background: rgba(10, 16, 30, 0.78); border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.06); position: relative; overflow: hidden; }
.pla-pm::before { content: ''; position: absolute; left: -24px; top: -34px; width: 150px; height: 150px; border-radius: 50%; pointer-events: none;
    background: radial-gradient(circle, color-mix(in srgb, var(--pla-tier) 34%, transparent) 0%, transparent 70%); }
.pla-gold { border-color: rgba(251, 191, 36, 0.5); background: linear-gradient(180deg, rgba(40, 28, 6, 0.72), rgba(10, 16, 30, 0.82)); box-shadow: 0 8px 28px rgba(0, 0, 0, 0.4), 0 0 22px rgba(251, 191, 36, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.08); }
.pla-me-c { position: relative; display: flex; align-items: center; gap: 10px; min-width: 0; }
.pla-me-c .pla-me-txt { min-width: 0; flex: 1; }
.pla-me-c .pla-me-name { font-size: clamp(17px, 5vw, 20px); }
.pla-ctx { position: relative; display: flex; gap: 6px; flex-wrap: wrap; min-width: 0; }
.pla-gold .pla-chip { color: #fde68a; border-color: rgba(251, 191, 36, 0.4); background: rgba(251, 191, 36, 0.1); }

/* Score entry */
.pla-sc { position: relative; display: flex; flex-direction: column; gap: 9px; min-width: 0; }
.pla-sc-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(11.5px, 3.2vw, 13px); letter-spacing: 1px; color: #fff; text-transform: uppercase; min-width: 0; }
.pla-sc-head span:first-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.pla-sc-tgt { flex: 0 0 auto; color: var(--pla-a); background: color-mix(in srgb, var(--pla-a) 15%, transparent); border: 1px solid color-mix(in srgb, var(--pla-a) 45%, transparent); border-radius: 8px; padding: 2px 8px; font-size: clamp(9.5px, 2.6vw, 10.5px); }
.pla-sc-row { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: 8px; align-items: center; }
.pla-sc-side { display: flex; flex-direction: column; align-items: center; gap: 6px; min-width: 0; padding: 9px 6px; border-radius: 12px; background: rgba(0, 0, 0, 0.3); border: 1px solid rgba(255, 255, 255, 0.09); }
.pla-sc-side.me { border-color: rgba(56, 189, 248, 0.45); }
.pla-sc-side.opp { border-color: rgba(248, 113, 113, 0.4); }
.pla-pair { display: inline-flex; }
.pla-pair .pla-av + .pla-av { margin-left: -9px; }
.pla-sc-names { max-width: 100%; font-family: 'Oswald', sans-serif; font-weight: 700; font-size: clamp(11px, 3.1vw, 12.5px); letter-spacing: 0.4px; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: center; }
.pla-sc-in { width: clamp(54px, 18vw, 74px); height: clamp(44px, 12vw, 52px); box-sizing: border-box; text-align: center; font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(22px, 6.4vw, 28px); color: #fff;
    background: rgba(15, 23, 42, 0.92); border: 1.5px solid rgba(255, 255, 255, 0.24); border-radius: 10px; padding: 0; -moz-appearance: textfield; appearance: textfield; }
.pla-sc-in::-webkit-outer-spin-button, .pla-sc-in::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.pla-sc-in:focus { outline: none; border-color: var(--pla-a); box-shadow: 0 0 14px color-mix(in srgb, var(--pla-a) 55%, transparent); }
.pla-sc-vs { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(10px, 2.8vw, 11px); letter-spacing: 1px; color: rgba(255, 255, 255, 0.45); }
.pla-sc-go { min-height: 44px; border: none; border-radius: 8px; cursor: pointer; font-family: 'Oswald', sans-serif; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; font-size: clamp(12px, 3.4vw, 13.5px); color: #fff;
    background: linear-gradient(135deg, #ef4444, #b91c1c); box-shadow: 0 0 18px rgba(239, 68, 68, 0.45); -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.pla-gold .pla-sc-go { background: linear-gradient(135deg, #fde047, #ca8a04); color: #1c1917; box-shadow: 0 0 18px rgba(245, 158, 11, 0.45); }
.pla-sc-go:active { transform: scale(0.98); }

/* Waiting / up next / finished */
.pla-wait { position: relative; display: flex; align-items: center; gap: 12px; min-width: 0; padding: 4px 2px; }
.pla-wait-big { flex: 0 0 auto; min-width: clamp(54px, 16vw, 68px); text-align: center; font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(38px, 11vw, 48px); line-height: 1; color: var(--pla-a); text-shadow: 0 0 18px color-mix(in srgb, var(--pla-a) 55%, transparent); }
.pla-wait-next .pla-wait-big, .pla-wait-done .pla-wait-big { font-size: clamp(20px, 6vw, 26px); }
.pla-wait-t { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.pla-wait-t b { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(13px, 3.8vw, 15px); letter-spacing: 0.9px; color: #fff; }
.pla-wait-t span { font-family: 'Oswald', sans-serif; font-weight: 700; font-size: clamp(9.5px, 2.7vw, 11px); letter-spacing: 0.8px; color: rgba(255, 255, 255, 0.62); }
.pla-nextrow { position: relative; display: flex; align-items: center; gap: 8px; min-width: 0; padding: 8px 10px; border-radius: 12px; background: rgba(0, 0, 0, 0.28); border: 1px solid rgba(255, 255, 255, 0.08);
    font-family: 'Oswald', sans-serif; font-weight: 700; font-size: clamp(11px, 3.1vw, 12.5px); letter-spacing: 0.4px; text-transform: uppercase; }
.pla-nextrow span { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pla-nextrow i { font-style: normal; color: rgba(255, 255, 255, 0.4); font-size: 10px; }
.pla-nextrow em { font-style: normal; flex: 0 0 auto; color: var(--pla-a); letter-spacing: 1px; }
.pla-nr-v { flex: 1; color: rgba(255, 255, 255, 0.72); text-transform: none; font-family: 'Manrope', sans-serif; font-weight: 600; }

/* Folds: reveal more on demand */
.pla-fold { background: rgba(10, 16, 30, 0.78); border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 16px; padding: 0 12px; box-sizing: border-box; min-width: 0; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3); }
.pla-fold > summary { list-style: none; display: flex; align-items: center; gap: 8px; min-height: 44px; cursor: pointer; font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(10.5px, 2.9vw, 11.5px); letter-spacing: 1.1px; color: rgba(255, 255, 255, 0.75); text-transform: uppercase; -webkit-tap-highlight-color: transparent; }
.pla-fold > summary::-webkit-details-marker { display: none; }
.pla-fold > summary > span:first-child { flex: 0 0 auto; }
.pla-fold-chips, .pla-fold-sum { flex: 1 1 0; min-width: 0; display: flex; justify-content: flex-end; gap: 5px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; color: #fbbf24; }
.pla-fold > summary i { font-style: normal; color: rgba(255, 255, 255, 0.55); transition: transform 0.2s; flex: 0 0 auto; }
.pla-fold[open] > summary i { transform: rotate(180deg); }
.pla-fold[open] { padding-bottom: 12px; }
.pla-fold .pla-rows { margin-top: 2px; }
.pla-lb-title { font-family: 'Oswald', sans-serif; font-weight: 700; font-size: clamp(9.5px, 2.6vw, 10.5px); letter-spacing: 0.9px; color: rgba(255, 255, 255, 0.5); text-transform: uppercase; margin: 0 0 8px; }
.pla-lb { display: flex; flex-direction: column; gap: 5px; }
.pla-lb-row { display: flex; align-items: center; gap: 9px; min-width: 0; padding: 6px 9px; border-radius: 10px; background: rgba(0, 0, 0, 0.26); border: 1px solid rgba(255, 255, 255, 0.07); }
.pla-lb-row.me { border-color: rgba(251, 191, 36, 0.6); background: rgba(251, 191, 36, 0.1); }
.pla-lb-rk { flex: 0 0 auto; width: 24px; height: 24px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-family: 'Oswald', sans-serif; font-weight: 800; font-size: 12px; color: #cbd5e1; background: rgba(255, 255, 255, 0.08); }
.pla-lb-rk.r1 { background: radial-gradient(circle at 35% 35%, #fffbeb, #eab308 70%, #a16207); color: #78350f; }
.pla-lb-rk.r2 { background: radial-gradient(circle at 35% 35%, #fff, #94a3b8 70%, #475569); color: #1e293b; }
.pla-lb-rk.r3 { background: radial-gradient(circle at 35% 35%, #ffedd5, #c2410c 70%, #7c2d12); color: #431407; }
.pla-lb-nm { flex: 1 1 0; min-width: 0; font-family: 'Oswald', sans-serif; font-weight: 700; font-size: clamp(12px, 3.4vw, 13.5px); letter-spacing: 0.5px; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pla-lb-wl { flex: 0 0 auto; font-family: 'Manrope', sans-serif; font-weight: 600; font-size: clamp(10px, 2.8vw, 11px); color: rgba(255, 255, 255, 0.55); }
.pla-lb-pt { flex: 0 0 auto; font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(15px, 4.3vw, 17px); color: #fbbf24; }
.pla-lb-pt small { font-size: 8.5px; margin-left: 2px; color: rgba(251, 191, 36, 0.7); }
.pla-lb-empty { font-size: 11px; padding: 6px 2px; }

/* Inline editor + session line */
.pla-ed { display: flex; align-items: center; gap: 6px; margin: -2px 0 2px; padding: 8px 10px; border-radius: 12px; background: rgba(56, 189, 248, 0.08); border: 1px solid rgba(56, 189, 248, 0.35); min-width: 0; }
.pla-ed .pla-sc-in { width: clamp(46px, 14vw, 58px); height: 40px; font-size: 20px; }
.pla-ed-l { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: 9.5px; letter-spacing: 0.8px; color: rgba(255, 255, 255, 0.55); }
.pla-ed-d { color: rgba(255, 255, 255, 0.4); }
.pla-ed-save { margin-left: auto; }
.pla-sessline { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 0 4px; min-width: 0; }
.pla-sessline span { font-family: 'Oswald', sans-serif; font-weight: 700; font-size: clamp(9.5px, 2.6vw, 10.5px); letter-spacing: 0.8px; color: rgba(255, 255, 255, 0.5); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.pla-sessline button { flex: 0 0 auto; min-height: 32px; font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(9.5px, 2.6vw, 10.5px); letter-spacing: 0.7px; color: #38bdf8; background: transparent; border: none; cursor: pointer; padding: 5px 4px; }
@media (max-width: 380px) { .pla-sessline span { display: none; } .pla-sessline button { margin-left: auto; } .pla-lb-wl { display: none; } }

/* ═══ v3: Details / Lobby in the player card, no footer bar, per-mode leaderboards ═══ */
.pla-bar { display: none !important; }
.pla-navb { position: relative; flex: 0 0 auto; display: flex; flex-direction: column; gap: 5px; align-self: center; }
.pla-navb button { min-height: 34px; min-width: clamp(70px, 21vw, 84px); padding: 5px 10px; border-radius: 8px; cursor: pointer; font-family: 'Oswald', sans-serif; font-weight: 800; letter-spacing: 0.9px; text-transform: uppercase; font-size: clamp(10px, 2.8vw, 11.5px);
    color: rgba(255, 255, 255, 0.85); background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.16); -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.pla-navb .pla-navb-lobby { color: #fff; border-color: color-mix(in srgb, var(--pla-a) 60%, transparent); background: color-mix(in srgb, var(--pla-a) 28%, rgba(10, 16, 30, 0.7)); box-shadow: 0 0 12px color-mix(in srgb, var(--pla-a) 30%, transparent); }
.pla-gold .pla-navb .pla-navb-lobby { color: #fde68a; }
.pla-me .pla-navb { margin-left: auto; position: relative; }
.pla-cta { flex: 0 0 auto; width: 100%; min-height: 46px; border: none; border-radius: 8px; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 7px; box-sizing: border-box;
    font-family: 'Oswald', sans-serif; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; font-size: clamp(12px, 3.4vw, 13.5px); color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
    background: linear-gradient(135deg, var(--pla-a), color-mix(in srgb, var(--pla-a) 60%, #000)); box-shadow: 0 0 18px color-mix(in srgb, var(--pla-a) 45%, transparent); -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.pla-cta.is-live { background: linear-gradient(135deg, #ef4444, #b91c1c); box-shadow: 0 0 18px rgba(239, 68, 68, 0.5); }
.pla-cta i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 8px currentColor; display: inline-block; }
body[data-pp-screen="portal"] .pla-cta.is-live i { animation: pla-pulse 1.4s ease-in-out infinite; }

/* Golden leaderboard: gold plaque bars, medals, stars (engine's golden style) */
.pla-fold-lb.is-golden { border-color: rgba(251, 191, 36, 0.4); background: linear-gradient(180deg, rgba(40, 28, 6, 0.5), rgba(10, 16, 30, 0.78)); }
.pla-gb-row { display: flex; align-items: center; gap: 7px; min-width: 0; }
.pla-gb-track { position: relative; flex: 1 1 0; min-width: 0; height: 32px; border-radius: 9px; background: rgba(0, 0, 0, 0.5); border: 1px solid rgba(255, 255, 255, 0.08); overflow: hidden; }
.pla-gb-fill { position: absolute; left: 0; top: 0; bottom: 0; width: var(--w, 100%); min-width: min(100%, 100px); display: flex; align-items: center; gap: 5px; padding: 0 9px; box-sizing: border-box; border-radius: 9px; overflow: hidden;
    background: linear-gradient(180deg, #fff7b0 0%, #fde047 20%, #eab308 55%, #ca8a04 85%, #a16207 100%); box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.7), 0 2px 8px rgba(245, 158, 11, 0.3); }
.pla-gb-fill b { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(12px, 3.4vw, 13.5px); letter-spacing: 0.5px; color: #422006; text-transform: uppercase; white-space: nowrap; text-shadow: 0 1px 0 rgba(255, 255, 255, 0.45); }
.pla-gb-stars { display: inline-flex; gap: 2px; flex: 0 0 auto; }
.pla-gb-row.me .pla-gb-track { border-color: #fff; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.5), 0 0 12px rgba(251, 191, 36, 0.45); }
.pla-gb-pts { flex: 0 0 auto; min-width: clamp(46px, 14vw, 54px); box-sizing: border-box; display: flex; align-items: baseline; justify-content: center; gap: 2px; padding: 5px 6px; border-radius: 9px; background: rgba(0, 0, 0, 0.35); border: 1.5px solid rgba(251, 191, 36, 0.6); }
.pla-gb-pts b { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(15px, 4.4vw, 18px); color: #fbbf24; }
.pla-gb-pts small { font-family: 'Oswald', sans-serif; font-weight: 700; font-size: 8.5px; color: rgba(251, 191, 36, 0.75); }
.pla-fold-lb.is-golden .pla-lb { gap: 7px; }

/* Traditional leaderboard: compact table (rank, player, W-L, difference) */
.pla-fold-lb.is-trad { border-color: rgba(56, 189, 248, 0.25); }
.pla-tb-head, .pla-tb-row { display: grid; grid-template-columns: 26px minmax(0, 1fr) auto auto; align-items: center; gap: 8px; }
.pla-tb-head { padding: 0 9px 4px; font-family: 'Oswald', sans-serif; font-weight: 700; font-size: 9px; letter-spacing: 1px; color: rgba(255, 255, 255, 0.4); }
.pla-tb-head span:nth-child(3), .pla-tb-head span:nth-child(4) { text-align: center; }
.pla-tb-row { padding: 7px 9px; border-radius: 10px; background: rgba(0, 0, 0, 0.26); border: 1px solid rgba(255, 255, 255, 0.07); }
.pla-tb-row.me { border-color: rgba(56, 189, 248, 0.6); background: rgba(56, 189, 248, 0.1); }
.pla-tb-rk { width: 24px; height: 24px; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-family: 'Oswald', sans-serif; font-weight: 800; font-size: 12px; color: #cbd5e1; background: rgba(255, 255, 255, 0.08); }
.pla-tb-rk.r1 { color: #38bdf8; background: rgba(56, 189, 248, 0.18); border: 1px solid rgba(56, 189, 248, 0.5); }
.pla-tb-nm { min-width: 0; font-family: 'Oswald', sans-serif; font-weight: 700; font-size: clamp(12px, 3.4vw, 13.5px); letter-spacing: 0.4px; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pla-tb-wl { display: inline-flex; align-items: baseline; gap: 2px; padding: 2px 8px; border-radius: 6px; background: rgba(34, 197, 94, 0.14); border: 1px solid rgba(34, 197, 94, 0.4); color: #4ade80; font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(11px, 3.1vw, 12px); white-space: nowrap; }
.pla-tb-wl b { font-size: 9px; opacity: 0.75; margin-right: 1px; }
.pla-tb-wl i { font-style: normal; opacity: 0.5; margin: 0 2px; }
.pla-tb-df { min-width: 34px; text-align: center; padding: 2px 6px; border-radius: 6px; background: rgba(255, 255, 255, 0.07); border: 1px solid rgba(255, 255, 255, 0.14); font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(11px, 3.1vw, 12px); color: rgba(255, 255, 255, 0.75); }
.pla-tb-df.pos { color: #4ade80; } .pla-tb-df.neg { color: #f87171; }
@media (max-width: 380px) { .pla-navb button { min-width: 64px; padding: 5px 7px; } .pla-gb-stars { display: none; } }

/* ═══ v4: result feel copied from the session (engine classes from style.css are reused: gp-/trad- pulse + glow, theater winner/dim) ═══ */
.pla-sc-go.pla-locked { background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important; color: #fff !important; border: 1px solid #6ee7b7 !important; box-shadow: 0 0 20px rgba(16, 185, 129, 0.55) !important; animation: pmScoreLockedPop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) both; }
.pla-sc-in:disabled { opacity: 1; -webkit-text-fill-color: #fff; }
.pla-sc-side.is-winner { border-color: rgba(251, 191, 36, 0.7) !important; }
.pla-orb { position: absolute; left: 0; top: 0; width: 12px; height: 12px; border-radius: 50%; pointer-events: none; z-index: 20; will-change: transform, opacity; }
.pla-row-flash { animation: plaRowFlash 0.7s ease-out; }
.pla-pts-pop { animation: plaPtsPop 0.7s cubic-bezier(0.34, 1.56, 0.64, 1); display: inline-block; }
@keyframes plaRowFlash { 0% { box-shadow: 0 0 0 0 rgba(251, 191, 36, 0.9); } 40% { box-shadow: 0 0 18px 2px rgba(251, 191, 36, 0.7); } 100% { box-shadow: 0 0 0 0 rgba(251, 191, 36, 0); } }
@keyframes plaPtsPop { 0% { transform: scale(1); } 45% { transform: scale(1.35); color: #fff; } 100% { transform: scale(1); } }
@keyframes pmScoreLockedPop { 0% { transform: scale(0.97); } 55% { transform: scale(1.03); } 100% { transform: scale(1); } }

/* ═══ v5 weight: VIP-style discipline ═══
   - no backdrop-filter (blur under moving layers is the costliest thing on mobile GPUs)
   - one breathing layer (opacity only, own compositor layer); cones/art are static
   - motion pauses by itself after a calm period (.is-calm) and whenever the portal is not the visible screen
   - backdrop layers are size-contained so they never trigger layout */
.pla-bg, .pla-glow, .pla-cones { contain: strict; }
.pla.is-calm .pla-glow { animation: none !important; }
.pla-orb { contain: layout paint; }

/* ═══ Opening veil: hides intermediate screens while a session opens ═══ */
#pla-veil { position: fixed; inset: 0; z-index: 2147483000; display: flex; align-items: center; justify-content: center; background: #05070c; opacity: 1; transition: opacity 0.25s ease; touch-action: none; }
#pla-veil[data-theme="day"] { background: #0b1220; }
#pla-veil-card span { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(11px, 3.2vw, 13px); letter-spacing: 2px; color: rgba(255, 255, 255, 0.7); }
.pla-veil-card { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.pla-veil-card span { font-family: 'Oswald', sans-serif; font-weight: 800; font-size: clamp(11px, 3.2vw, 13px); letter-spacing: 2px; color: rgba(255, 255, 255, 0.7); }
.pla-veil-spin { width: 30px; height: 30px; border-radius: 50%; border: 3px solid rgba(255, 255, 255, 0.14); border-top-color: #38bdf8; animation: pla-veil-rot 0.8s linear infinite; }
@keyframes pla-veil-rot { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .pla-veil-spin { animation-duration: 2s; } }

/* ═══ v6: Mix & Match Pairing Projection + Player-View Monrad Bracket (kaavio) ═══ */
.pla-monrad {
    border-color: rgba(16, 185, 129, 0.45);
    background: linear-gradient(180deg, rgba(6, 36, 28, 0.76), rgba(10, 16, 30, 0.86));
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.42), 0 0 20px rgba(16, 185, 129, 0.14), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}
.pla-monrad .pla-chip {
    color: #a7f3d0;
    border-color: rgba(16, 185, 129, 0.4);
    background: rgba(16, 185, 129, 0.12);
}

/* Monrad Doubles Team & Path Banner */
.pla-mnr-team-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 9px 11px;
    border-radius: 13px;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.16), rgba(15, 23, 42, 0.82));
    border: 1px solid rgba(16, 185, 129, 0.42);
    min-width: 0;
}
.pla-mnr-tb-left {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    flex: 1;
}
.pla-mnr-pair .pm-avatar-seat + .pm-avatar-seat {
    margin-left: -10px;
}
.pla-mnr-tb-txt {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}
.pla-mnr-tb-kicker {
    display: flex;
    align-items: center;
    gap: 5px;
    flex-wrap: wrap;
}
.pla-mnr-seed-pill {
    font-family: 'Oswald', sans-serif;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.9px;
    color: #064e3b;
    background: #34d399;
    padding: 1px 6px;
    border-radius: 5px;
    text-transform: uppercase;
}
.pla-mnr-orig-pill {
    font-family: 'Oswald', sans-serif;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.7px;
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.14);
    border: 1px solid rgba(56, 189, 248, 0.38);
    padding: 1px 6px;
    border-radius: 5px;
}
.pla-mnr-tb-names {
    font-family: 'Oswald', sans-serif;
    font-weight: 800;
    font-size: clamp(12.5px, 3.6vw, 14.5px);
    letter-spacing: 0.5px;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pla-mnr-tb-stage {
    flex: 0 0 auto;
    font-family: 'Oswald', sans-serif;
    font-size: clamp(9.5px, 2.7vw, 11px);
    font-weight: 800;
    letter-spacing: 0.8px;
    color: #fde68a;
    background: rgba(245, 158, 11, 0.16);
    border: 1px solid rgba(251, 191, 36, 0.45);
    border-radius: 8px;
    padding: 4px 9px;
    text-transform: uppercase;
    white-space: nowrap;
}

/* Mix & Match Phase 1 Live Pairing Projection Banner */
.pla-mix-proj-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px 10px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.14), rgba(15, 23, 42, 0.82));
    border: 1px solid rgba(16, 185, 129, 0.36);
    min-width: 0;
}
.pla-mix-proj-left {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}
.pla-mix-badge {
    font-family: 'Oswald', sans-serif;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.9px;
    color: #34d399;
}
.pla-mix-seed {
    font-family: 'Oswald', sans-serif;
    font-size: clamp(11px, 3.1vw, 12.5px);
    font-weight: 700;
    color: #e2e8f0;
    letter-spacing: 0.5px;
}
.pla-mix-seed b {
    color: #fbbf24;
    font-weight: 900;
}
.pla-mix-proj-right {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 4px 8px;
    border-radius: 9px;
    background: rgba(0, 0, 0, 0.32);
    border: 1px solid rgba(255, 255, 255, 0.1);
    min-width: 0;
}
.pla-mix-proj-ptxt {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
    min-width: 0;
}
.pla-mix-proj-ptxt span {
    font-family: 'Oswald', sans-serif;
    font-size: 8.5px;
    font-weight: 700;
    letter-spacing: 0.7px;
    color: #94a3b8;
}
.pla-mix-proj-ptxt b {
    font-family: 'Oswald', sans-serif;
    font-size: clamp(10px, 2.8vw, 11.5px);
    font-weight: 800;
    color: #6ee7b7;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pla-mix-row-pill {
    display: inline-flex;
    align-items: center;
    margin-left: 6px;
    padding: 1px 6px;
    border-radius: 5px;
    font-family: 'Oswald', sans-serif;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.5px;
    color: #34d399;
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.35);
    vertical-align: middle;
}

/* Player-View Monrad Bracket Fold (kaavio) */
.pla-fold-mnr {
    border-color: rgba(16, 185, 129, 0.36);
    background: linear-gradient(180deg, rgba(8, 28, 24, 0.78), rgba(10, 16, 30, 0.86));
}
.pla-mnr-steps {
    display: flex;
    align-items: center;
    gap: 5px;
    overflow-x: auto;
    scrollbar-width: none;
    padding: 2px 0 10px;
}
.pla-mnr-steps::-webkit-scrollbar { display: none; }
.pla-mnr-step {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 9px;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.78);
    border: 1px solid rgba(255, 255, 255, 0.12);
    font-family: 'Oswald', sans-serif;
    font-size: clamp(9.5px, 2.7vw, 11px);
    font-weight: 800;
    letter-spacing: 0.6px;
    color: rgba(255, 255, 255, 0.65);
    white-space: nowrap;
    flex-shrink: 0;
}
.pla-mnr-step-r {
    padding: 1px 5px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.1);
    color: #cbd5e1;
    font-size: 9px;
}
.pla-mnr-step.is-done {
    border-color: rgba(34, 197, 94, 0.45);
    color: #86efac;
    background: rgba(20, 83, 45, 0.35);
}
.pla-mnr-step.is-done .pla-mnr-step-r {
    background: #22c55e;
    color: #052e16;
}
.pla-mnr-step.is-active {
    border-color: rgba(251, 191, 36, 0.65);
    color: #fef08a;
    background: rgba(120, 53, 15, 0.4);
}
.pla-mnr-step.is-active .pla-mnr-step-r {
    background: #fbbf24;
    color: #422006;
}
.pla-mnr-step-arr {
    color: rgba(255, 255, 255, 0.32);
    font-size: 11px;
    flex-shrink: 0;
}

/* Horizontal Scrollable Round Columns */
.pla-mnr-cols {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: 4px;
    scroll-snap-type: x proximity;
}
.pla-mnr-cols::-webkit-scrollbar { display: none; }
.pla-mnr-col {
    flex: 0 0 clamp(228px, 72vw, 275px);
    min-width: 0;
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
    gap: 7px;
    padding: 8px;
    border-radius: 12px;
    background: rgba(6, 10, 20, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.08);
}
.pla-mnr-col.is-active-col {
    border-color: rgba(16, 185, 129, 0.38);
    background: rgba(6, 24, 22, 0.65);
}
.pla-mnr-col-h {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    padding: 0 2px 3px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    font-family: 'Oswald', sans-serif;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.9px;
    color: #94a3b8;
    text-transform: uppercase;
}
.pla-mnr-col-h em {
    font-style: normal;
    font-size: 9px;
    color: #34d399;
}
.pla-mnr-col-cards {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

/* Bracket Match Card */
.pla-mnr-card {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: 8px 9px;
    border-radius: 11px;
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.1);
    min-width: 0;
}
.pla-mnr-card.is-mine {
    border: 1.5px solid rgba(16, 185, 129, 0.72);
    background: linear-gradient(180deg, rgba(6, 48, 38, 0.88), rgba(12, 22, 38, 0.92));
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.18);
}
.pla-mnr-card.is-gold-match {
    border-color: rgba(251, 191, 36, 0.55);
}
.pla-mnr-card.is-proj {
    opacity: 0.78;
    border-style: dashed;
}
.pla-mnr-card[data-pla="mnr-focus"] {
    cursor: pointer;
}
.pla-mnr-c-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    font-family: 'Oswald', sans-serif;
    font-size: 9.5px;
    font-weight: 800;
    letter-spacing: 0.7px;
    text-transform: uppercase;
}
.pla-mnr-c-tier {
    color: #cbd5e1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pla-mnr-card.is-mine .pla-mnr-c-tier {
    color: #6ee7b7;
}
.pla-mnr-c-st {
    flex: 0 0 auto;
    padding: 1px 6px;
    border-radius: 5px;
    font-size: 8.5px;
}
.pla-mnr-c-st.live {
    color: #fff;
    background: #10b981;
}
.pla-mnr-c-st.done {
    color: #86efac;
    background: rgba(34, 197, 94, 0.16);
    border: 1px solid rgba(34, 197, 94, 0.35);
}
.pla-mnr-c-st.proj {
    color: #94a3b8;
    background: rgba(255, 255, 255, 0.07);
}
.pla-mnr-c-st.bye {
    color: #fde68a;
    background: rgba(245, 158, 11, 0.2);
    border: 1px solid rgba(251, 191, 36, 0.4);
}

/* Team Row inside Bracket Card */
.pla-mnr-trow {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 5px 7px;
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.32);
    border: 1px solid rgba(255, 255, 255, 0.06);
    min-width: 0;
}
.pla-mnr-trow.is-me {
    border-color: rgba(16, 185, 129, 0.55);
    background: rgba(16, 185, 129, 0.14);
}
.pla-mnr-trow.is-win {
    border-color: rgba(34, 197, 94, 0.55);
}
.pla-mnr-trow.is-lose {
    opacity: 0.62;
}
.pla-mnr-sd {
    flex: 0 0 auto;
    min-width: 20px;
    text-align: center;
    font-family: 'Oswald', sans-serif;
    font-size: 9.5px;
    font-weight: 800;
    color: #fbbf24;
    background: rgba(251, 191, 36, 0.14);
    border-radius: 4px;
    padding: 1px 4px;
}
.pla-mnr-sd.ph {
    color: #64748b;
    background: rgba(255, 255, 255, 0.05);
}
.pla-mnr-mini-pair .pm-avatar-seat + .pm-avatar-seat {
    margin-left: -7px;
}
.pla-mnr-t-ph {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
    border: 1px dashed rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Oswald', sans-serif;
    font-size: 10px;
    font-weight: 800;
    color: #64748b;
    flex-shrink: 0;
}
.pla-mnr-tinfo {
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 5px;
}
.pla-mnr-tnm {
    font-family: 'Oswald', sans-serif;
    font-size: clamp(10.5px, 3vw, 12px);
    font-weight: 700;
    color: #f8fafc;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-transform: uppercase;
}
.pla-mnr-trow.is-me .pla-mnr-tnm {
    color: #6ee7b7;
    font-weight: 800;
}
.pla-mnr-orig {
    flex: 0 0 auto;
    font-style: normal;
    font-family: 'Oswald', sans-serif;
    font-size: 8.5px;
    font-weight: 700;
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.12);
    padding: 0 4px;
    border-radius: 4px;
}
.pla-mnr-sc {
    flex: 0 0 auto;
    min-width: 22px;
    text-align: center;
    font-family: 'Oswald', sans-serif;
    font-size: 13px;
    font-weight: 800;
    color: rgba(255, 255, 255, 0.65);
    padding: 1px 5px;
    border-radius: 5px;
    background: rgba(255, 255, 255, 0.06);
}
.pla-mnr-sc.win {
    color: #052e16;
    background: #4ade80;
    font-weight: 900;
}
.pla-mnr-byetag {
    margin-left: auto;
    font-family: 'Oswald', sans-serif;
    font-size: 9px;
    font-weight: 800;
    color: #fde68a;
    letter-spacing: 0.6px;
}

/* Monrad Doubles Progression Leaderboard */
.pla-fold-lb.is-monrad {
    border-color: rgba(16, 185, 129, 0.35);
}
.pla-mnr-lb-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 9px;
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.28);
    border: 1px solid rgba(255, 255, 255, 0.07);
    min-width: 0;
}
.pla-mnr-lb-row.me {
    border-color: rgba(16, 185, 129, 0.65);
    background: rgba(16, 185, 129, 0.12);
}
.pla-mnr-lb-pair .pm-avatar-seat + .pm-avatar-seat {
    margin-left: -8px;
}
.pla-mnr-lb-info {
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 1px;
}
.pla-mnr-lb-nm {
    font-family: 'Oswald', sans-serif;
    font-size: clamp(11.5px, 3.3vw, 13px);
    font-weight: 800;
    color: #fff;
    text-transform: uppercase;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pla-mnr-lb-orig {
    font-style: normal;
    font-size: 9px;
    color: #38bdf8;
    margin-left: 4px;
}
.pla-mnr-lb-st {
    font-family: 'Oswald', sans-serif;
    font-size: 9.5px;
    font-weight: 700;
    letter-spacing: 0.6px;
    color: #fde68a;
    text-transform: uppercase;
}
