/* =====================================================================
   CABAL VEYNOR - EPISODE 39 DARK PURPLE THEME V1
   HOMEPAGE ONLY
   ---------------------------------------------------------------------
   Loaded only by includes/ep39-home-theme.php from index.php.
   The dashboard/admin/standalone pages do not load this stylesheet.
   ===================================================================== */

body.ep39-home-on {
    --ep39-bg-0: #05020b;
    --ep39-bg-1: #090412;
    --ep39-bg-2: #10071d;
    --ep39-panel: rgba(18, 8, 31, 0.88);
    --ep39-purple-deep: #4c1d95;
    --ep39-purple: #7c3aed;
    --ep39-violet: #8b5cf6;
    --ep39-accent: #a855f7;
    --ep39-accent-hi: #d8b4fe;
    --ep39-magenta: #d946ef;
    --ep39-edge: rgba(168, 85, 247, 0.28);
    --ep39-edge-strong: rgba(216, 180, 254, 0.52);
    --ep39-glow: rgba(168, 85, 247, 0.38);

    /* Existing homepage tokens inherit the EP39 palette. */
    --neon-blue: var(--ep39-accent);
    --void-dark: var(--ep39-bg-0);
    --panel-bg: rgba(13, 6, 23, 0.88);
    --border-glow: 0 0 16px rgba(168, 85, 247, 0.45);

    background-color: var(--ep39-bg-0) !important;
    background-image:
        radial-gradient(circle at 12% 8%, rgba(124,58,237,.17), transparent 31%),
        radial-gradient(circle at 88% 18%, rgba(217,70,239,.09), transparent 27%),
        radial-gradient(circle at 50% 110%, rgba(76,29,149,.20), transparent 43%) !important;
    color: #f8f5ff;
}

body.ep39-home-on::selection,
body.ep39-home-on *::selection {
    background: rgba(168,85,247,.45);
    color: #fff;
}

body.ep39-home-on ::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg,#6d28d9,#a855f7) !important;
}
body.ep39-home-on ::-webkit-scrollbar-thumb:hover { background:#c084fc !important; }

/* -------------------------------------------------------------
   Ambient EP39 layer
   ------------------------------------------------------------- */
#ep39-home-fx {
    position: fixed;
    inset: 0;
    z-index: 1;
    overflow: hidden;
    pointer-events: none;
}
#ep39-home-fx .ep39-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(75px);
    opacity: .42;
    animation: ep39OrbFloat 10s ease-in-out infinite alternate;
}
#ep39-home-fx .ep39-orb-a {
    width: 430px; height: 430px; left: -150px; top: 6%;
    background: radial-gradient(circle,rgba(124,58,237,.32),transparent 70%);
}
#ep39-home-fx .ep39-orb-b {
    width: 520px; height: 520px; right: -180px; top: 30%;
    background: radial-gradient(circle,rgba(217,70,239,.20),transparent 70%);
    animation-delay: 2s;
}
#ep39-home-fx .ep39-orb-c {
    width: 480px; height: 480px; left: 34%; bottom: -240px;
    background: radial-gradient(circle,rgba(91,33,182,.25),transparent 70%);
    animation-delay: 4s;
}
#ep39-home-fx .ep39-grid {
    position:absolute; inset:-20%; opacity:.12;
    background-image:
        linear-gradient(rgba(168,85,247,.13) 1px,transparent 1px),
        linear-gradient(90deg,rgba(168,85,247,.13) 1px,transparent 1px);
    background-size: 70px 70px;
    transform: perspective(600px) rotateX(64deg) translateY(40%);
    transform-origin: center bottom;
    mask-image: linear-gradient(to bottom,transparent 0%,rgba(0,0,0,.85) 55%,transparent 100%);
}
#ep39-home-fx .ep39-spark {
    position:absolute; bottom:-8px; border-radius:50%;
    background:#d8b4fe;
    box-shadow:0 0 10px rgba(192,132,252,.85);
    opacity:0;
    animation:ep39SparkRise linear infinite;
}
@keyframes ep39OrbFloat {
    from { transform:translate3d(0,0,0) scale(1); }
    to { transform:translate3d(25px,-20px,0) scale(1.08); }
}
@keyframes ep39SparkRise {
    0% { transform:translateY(0) scale(.6); opacity:0; }
    15% { opacity:.8; }
    80% { opacity:.35; }
    100% { transform:translateY(-105vh) scale(1.25); opacity:0; }
}

/* Keep actual homepage content above the decorative FX. */
body.ep39-home-on #main-nav,
body.ep39-home-on section,
body.ep39-home-on footer,
body.ep39-home-on #music-container,
body.ep39-home-on #channel-sidebar,
body.ep39-home-on [id*="streamer"] { position:relative; z-index:2; }
body.ep39-home-on #main-nav { position:fixed; z-index:50; }
body.ep39-home-on #music-container { position:fixed; z-index:50; }

/* -------------------------------------------------------------
   Tailwind cyan compatibility on homepage only
   ------------------------------------------------------------- */
body.ep39-home-on .text-cyan-200,
body.ep39-home-on .text-cyan-300,
body.ep39-home-on .text-cyan-400,
body.ep39-home-on .text-cyan-500,
body.ep39-home-on .text-cyan-600 { color:var(--ep39-accent-hi) !important; }
body.ep39-home-on .bg-cyan-600 { background-color:#7c3aed !important; color:#fff !important; }
body.ep39-home-on .hover\:bg-cyan-500:hover { background-color:#8b5cf6 !important; }
body.ep39-home-on .hover\:text-cyan-300:hover,
body.ep39-home-on .hover\:text-cyan-400:hover { color:#f3e8ff !important; }
body.ep39-home-on .border-cyan-300,
body.ep39-home-on .border-cyan-400,
body.ep39-home-on .border-cyan-500 { border-color:var(--ep39-accent) !important; }
body.ep39-home-on .accent-cyan-500 { accent-color:var(--ep39-accent) !important; }
body.ep39-home-on .focus\:border-cyan-500:focus { border-color:var(--ep39-accent) !important; }
body.ep39-home-on .focus\:ring-cyan-500:focus { --tw-ring-color:rgba(168,85,247,.48) !important; }

/* -------------------------------------------------------------
   Main navigation
   ------------------------------------------------------------- */
body.ep39-home-on #main-nav::before {
    background:linear-gradient(90deg,transparent 0%,#5b21b6 20%,#a855f7 44%,#d946ef 60%,#7c3aed 78%,transparent 100%) !important;
    box-shadow:0 0 24px rgba(168,85,247,.36);
}
body.ep39-home-on .nav-inner {
    background:linear-gradient(180deg,rgba(7,2,13,.985),rgba(14,6,24,.965)) !important;
    border-bottom-color:rgba(168,85,247,.21) !important;
    box-shadow:0 5px 42px rgba(0,0,0,.72),0 1px 0 rgba(168,85,247,.09) inset !important;
}
body.ep39-home-on .nav-logo-img { filter:drop-shadow(0 0 11px rgba(168,85,247,.64)) !important; }
body.ep39-home-on .nav-logo-text span { color:#d8b4fe !important; text-shadow:0 0 16px rgba(168,85,247,.72) !important; }
body.ep39-home-on .nav-link-item::after { background:linear-gradient(90deg,#7c3aed,#d946ef) !important; }
body.ep39-home-on .nav-link-item.active { color:#d8b4fe !important; }
body.ep39-home-on .nav-link-item.active::after { background:#a855f7 !important; box-shadow:0 0 12px rgba(168,85,247,.88) !important; }
body.ep39-home-on .nav-discord { color:#f0a500 !important; }
body.ep39-home-on .btn-login {
    border-color:rgba(168,85,247,.58) !important;
    color:#d8b4fe !important;
}
body.ep39-home-on .btn-login:hover {
    background:rgba(124,58,237,.17) !important;
    border-color:#d8b4fe !important;
    box-shadow:0 0 24px rgba(168,85,247,.30),inset 0 0 15px rgba(168,85,247,.08) !important;
}
body.ep39-home-on .btn-download {
    background:linear-gradient(135deg,#9333ea 0%,#5b21b6 56%,#3b0764 100%) !important;
    border-color:rgba(216,180,254,.42) !important;
    box-shadow:0 0 22px rgba(147,51,234,.38),inset 0 1px 0 rgba(255,255,255,.12) !important;
}
body.ep39-home-on .btn-download:hover {
    background:linear-gradient(135deg,#c026d3 0%,#7c3aed 55%,#4c1d95 100%) !important;
    box-shadow:0 0 34px rgba(192,38,211,.48),inset 0 1px 0 rgba(255,255,255,.16) !important;
}
body.ep39-home-on .nav-hamburger:hover { border-color:rgba(168,85,247,.65) !important; }
body.ep39-home-on #mobile-nav-menu,
body.ep39-home-on .mobile-nav-menu {
    background:linear-gradient(180deg,rgba(9,4,18,.99),rgba(16,7,29,.99)) !important;
    border-bottom-color:rgba(168,85,247,.22) !important;
}
body.ep39-home-on .mobile-link:hover {
    color:#d8b4fe !important;
    border-left-color:#a855f7 !important;
    background:rgba(124,58,237,.10) !important;
}

/* -------------------------------------------------------------
   Hero
   ------------------------------------------------------------- */
body.ep39-home-on #home::before {
    content:''; position:absolute; inset:0; z-index:0; pointer-events:none;
    background:
        radial-gradient(circle at 50% 38%,rgba(168,85,247,.13),transparent 35%),
        radial-gradient(circle at 50% 58%,rgba(217,70,239,.06),transparent 43%),
        linear-gradient(180deg,rgba(7,2,14,.10),rgba(7,2,14,.04) 52%,rgba(5,2,11,.78));
}
body.ep39-home-on #home .animate-pulse {
    border-color:rgba(168,85,247,.55) !important;
    color:#d8b4fe !important;
    background:rgba(22,8,38,.52) !important;
    box-shadow:0 0 24px rgba(168,85,247,.20);
}
body.ep39-home-on .hero-register-btn .hero-btn-bg {
    border-color:rgba(168,85,247,.62) !important;
    background:linear-gradient(110deg,#130820,#4c1d95,#7c3aed) !important;
}
body.ep39-home-on .hero-register-btn:hover .hero-btn-bg {
    border-color:rgba(216,180,254,.95) !important;
    background:linear-gradient(110deg,#21103a,#6d28d9,#a855f7) !important;
    box-shadow:0 0 36px rgba(168,85,247,.34),0 0 72px rgba(217,70,239,.13),inset 0 0 28px rgba(255,255,255,.05) !important;
}
body.ep39-home-on .hero-trailer-btn .hero-btn-bg {
    border-color:rgba(192,132,252,.58) !important;
    background:linear-gradient(110deg,#0f071a,#5b21b6,#a21caf) !important;
}
body.ep39-home-on .hero-trailer-btn:hover .hero-btn-bg {
    border-color:rgba(232,121,249,.90) !important;
    background:linear-gradient(110deg,#1d0a30,#7c3aed,#c026d3) !important;
    box-shadow:0 0 34px rgba(168,85,247,.34),0 0 68px rgba(217,70,239,.14),inset 0 0 30px rgba(255,255,255,.06) !important;
}
body.ep39-home-on .hero-register-btn::before,
body.ep39-home-on .hero-register-btn::after { border-color:#a855f7 !important; }
body.ep39-home-on .hero-btn-particles i { background:rgba(216,180,254,.82) !important; }

/* -------------------------------------------------------------
   Slides / lightbox / generic homepage cards
   ------------------------------------------------------------- */
body.ep39-home-on #lightbox-content,
body.ep39-home-on .tech-border {
    background-color:#12091d !important;
    border-color:rgba(168,85,247,.25) !important;
    box-shadow:0 0 26px rgba(168,85,247,.15),0 22px 60px rgba(0,0,0,.55) !important;
}
body.ep39-home-on .cyber-card {
    border-image:linear-gradient(to right,#7c3aed,#d946ef,transparent 80%) 1 !important;
    box-shadow:0 0 14px rgba(124,58,237,.14) !important;
}
body.ep39-home-on .cyber-card:hover {
    border-image:linear-gradient(to right,#a855f7,#d946ef,#7c3aed) 1 !important;
    box-shadow:0 0 26px rgba(168,85,247,.38) !important;
}
body.ep39-home-on .tech-button { background-image:linear-gradient(to right,#6d28d9,#a855f7) !important; }
body.ep39-home-on .tech-button:hover { box-shadow:0 0 22px rgba(168,85,247,.58) !important; }

/* -------------------------------------------------------------
   Official Streamers
   ------------------------------------------------------------- */
body.ep39-home-on .cvs-showcase-section {
    background:
        radial-gradient(circle at 50% 8%,rgba(124,58,237,.17),transparent 33%),
        linear-gradient(180deg,#08030f 0%,#0d0617 46%,#06030c 100%) !important;
}
body.ep39-home-on .cvs-showcase-kicker,
body.ep39-home-on .cvs-showcase-title span { color:#c084fc !important; }
body.ep39-home-on .cvs-showcase-kicker::before,
body.ep39-home-on .cvs-showcase-kicker::after { background:linear-gradient(90deg,transparent,#a855f7) !important; }
body.ep39-home-on .cvs-showcase-title {
    color:#faf5ff !important;
    text-shadow:0 5px 30px rgba(0,0,0,.85),0 0 30px rgba(168,85,247,.18) !important;
}
body.ep39-home-on .cvs-streamer-card {
    background:#09040f !important;
    border-color:rgba(168,85,247,.31) !important;
    box-shadow:0 18px 46px rgba(0,0,0,.50) !important;
}
body.ep39-home-on .cvs-streamer-card:hover {
    border-color:rgba(216,180,254,.72) !important;
    box-shadow:0 26px 62px rgba(0,0,0,.62),0 0 34px rgba(168,85,247,.17) !important;
}
body.ep39-home-on .cvs-streamer-media {
    background:radial-gradient(circle at 50% 28%,rgba(124,58,237,.40),transparent 28%),linear-gradient(145deg,#1a0c2b,#050208 60%,#160823) !important;
}
body.ep39-home-on .cvs-streamer-media::after {
    background:linear-gradient(180deg,rgba(7,2,12,.03) 42%,rgba(8,3,14,.36) 68%,rgba(5,2,10,.97) 100%),linear-gradient(90deg,rgba(168,85,247,.09),transparent 18%,transparent 82%,rgba(217,70,239,.07)) !important;
}
body.ep39-home-on .cvs-streamer-platform {
    color:#e9d5ff !important;
    background:rgba(15,6,26,.76) !important;
    border-color:rgba(168,85,247,.40) !important;
}
body.ep39-home-on .cvs-streamer-name { color:#ead7ff !important; }
body.ep39-home-on .cvs-role-head-streamer { color:#f5d0fe !important; text-shadow:0 0 12px rgba(217,70,239,.25) !important; }
body.ep39-home-on .cvs-role-ambassador { color:#c4b5fd !important; text-shadow:0 0 12px rgba(139,92,246,.25) !important; }
body.ep39-home-on .cvs-streamer-cta {
    color:#f5e9ff !important;
    background:linear-gradient(180deg,#6d28d9,#43127d) !important;
    border-color:#a855f7 !important;
}
body.ep39-home-on .cvs-streamer-cta::before,
body.ep39-home-on .cvs-streamer-cta::after { border-color:#d8b4fe !important; }
body.ep39-home-on .cvs-streamer-card:hover .cvs-streamer-cta {
    background:linear-gradient(180deg,#9333ea,#5b21b6) !important;
    box-shadow:0 0 24px rgba(168,85,247,.25),inset 0 0 16px rgba(255,255,255,.04) !important;
}
body.ep39-home-on .cvs-streamer-card.cvs-open-slot {
    border-color:rgba(168,85,247,.38) !important;
    background:linear-gradient(180deg,rgba(18,7,30,.95),rgba(6,3,11,.99)) !important;
}
body.ep39-home-on .cvs-open-slot .cvs-streamer-media {
    background:radial-gradient(circle at 50% 33%,rgba(124,58,237,.28),transparent 26%),linear-gradient(145deg,#170a28,#050208 62%,#12071e) !important;
}

/* -------------------------------------------------------------
   News
   ------------------------------------------------------------- */
body.ep39-home-on .ns-outer::before {
    background:linear-gradient(to bottom,rgba(6,2,12,.68) 0%,transparent 20%,transparent 72%,rgba(6,2,12,.96) 100%) !important;
}
body.ep39-home-on .ns-outer::after {
    background-image:linear-gradient(rgba(168,85,247,.035) 1px,transparent 1px),linear-gradient(90deg,rgba(168,85,247,.035) 1px,transparent 1px) !important;
}
body.ep39-home-on .ns-header-eyebrow,
body.ep39-home-on .ns-slide-caption-tag,
body.ep39-home-on .ns-readmore-btn,
body.ep39-home-on .ns-tab.active,
body.ep39-home-on .ntag { color:#d8b4fe !important; }
body.ep39-home-on .ns-header-eyebrow::before { background:linear-gradient(90deg,transparent,#a855f7) !important; }
body.ep39-home-on .ns-header-eyebrow::after { background:linear-gradient(90deg,#a855f7,transparent) !important; }
body.ep39-home-on .ns-header h2 {
    background:linear-gradient(135deg,#fff 0%,#e9d5ff 52%,#a855f7 100%) !important;
    -webkit-background-clip:text !important; background-clip:text !important;
}
body.ep39-home-on .ns-panel,
body.ep39-home-on .ns-slide,
body.ep39-home-on .ns-item { border-color:rgba(168,85,247,.18) !important; }
body.ep39-home-on .ns-readmore-btn,
body.ep39-home-on .ns-tab.active { border-color:rgba(168,85,247,.44) !important; background:rgba(124,58,237,.12) !important; }
body.ep39-home-on .ns-dot.active { background:#a855f7 !important; box-shadow:0 0 10px rgba(168,85,247,.72) !important; }
body.ep39-home-on .ns-item-bar { background:linear-gradient(180deg,#d946ef,#7c3aed) !important; }

/* -------------------------------------------------------------
   Remaining homepage sections
   Preserve gold, green/red status, and faction semantics; tint the shell.
   ------------------------------------------------------------- */
body.ep39-home-on #features-section,
body.ep39-home-on #classes,
body.ep39-home-on #rankings {
    background-color:rgba(6,2,12,.40) !important;
}
body.ep39-home-on #classes {
    background-image:
        radial-gradient(circle at 80% 24%,rgba(124,58,237,.12),transparent 32%),
        radial-gradient(circle at 18% 72%,rgba(217,70,239,.07),transparent 34%) !important;
}
body.ep39-home-on #rankings {
    background-image:linear-gradient(180deg,rgba(8,3,15,.74),rgba(14,6,24,.64),rgba(6,2,12,.78)) !important;
}
body.ep39-home-on .class-num-badge,
body.ep39-home-on .class-role-tag {
    border-color:rgba(168,85,247,.30) !important;
    background:rgba(124,58,237,.10) !important;
}
body.ep39-home-on .custom-scrollbar::-webkit-scrollbar-thumb { background:#7c3aed !important; }

/* Common cyan accents embedded in included homepage modules. */
body.ep39-home-on [style*="#00d4ff"],
body.ep39-home-on [style*="#00D4FF"] { --ep39-inline-cyan:#a855f7; }

/* Login / register modals opened from the homepage */
body.ep39-home-on #loginModal-modal .tech-border,
body.ep39-home-on #register-modal .tech-border {
    background:linear-gradient(160deg,#0b0414,#160824 60%,#08030f) !important;
    border-color:rgba(168,85,247,.34) !important;
    box-shadow:0 0 42px rgba(168,85,247,.18),0 35px 90px rgba(0,0,0,.72) !important;
}

/* Subtle divider glow between major homepage sections. */
body.ep39-home-on .cvs-showcase-section,
body.ep39-home-on .ns-outer,
body.ep39-home-on #features-section,
body.ep39-home-on #classes,
body.ep39-home-on #rankings {
    border-top:1px solid rgba(168,85,247,.08);
}

/* Semantic colors intentionally NOT overridden:
   - green online/success
   - red danger/live
   - gold reward/premium accents
   - Capella/Procyon faction colors
*/

@media (prefers-reduced-motion: reduce) {
    #ep39-home-fx .ep39-orb,
    #ep39-home-fx .ep39-spark { animation:none !important; }
}
