@font-face {
    font-family: "DataType";
    src: url("fonts/Datatype.woff2") format("woff2");
    font-weight: 100 900;
    font-stretch: 50% 150%;
    font-style: normal;
    font-display: swap;
}

:root {
    /* Y2K Retro-Futuristic Aesthetic */
    --y2k-blue: #00f2ff;
    --y2k-blue-glow: rgba(0, 242, 255, 0.5);
    --y2k-green: #39ff14;
    --y2k-purple: #bc13fe;
    --y2k-bg-dark: #000510;
    --y2k-glass: rgba(255, 255, 255, 0.05);
    --y2k-border: rgba(255, 255, 255, 0.2);
    --y2k-text-light: #e0e0ff;
    
    /* Carousel Specifics — Ellipse Cards */
    --card-width: 520px;
    --card-height: 320px;
    --card-gap: 50px;
    
    --font-heading: 'VT323', 'DataType', monospace;
    --font-body: 'VT323', monospace;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    overflow-x: hidden;
}

body {
    background: radial-gradient(circle at center, #001a33 0%, var(--y2k-bg-dark) 100%);
    color: var(--y2k-text-light);
    font-family: var(--font-body);
    overflow-x: hidden;
    overflow-y: auto;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
html, body, a, button, .nxe-card, video, .os-container, .os-modal, * {
    cursor: auto !important;
}

#custom-cursor {
    display: none;
}

#custom-cursor::before,
#custom-cursor::after {
    display: none; /* Hide old crosshairs */
}

#custom-cursor-dot {
    display: none; /* Hide old dot */
}

#custom-cursor.hovering {
    transform: scale(1.2) rotate(5deg);
    filter: drop-shadow(0 0 15px rgba(57, 255, 20, 0.7));
}

/* --- Xbox 360 Background FX --- */
.background-video {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    overflow: hidden;
}

.background-video video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 1; /* Raw appearance */
}

.nxe-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: transparent;
}

.nxe-bubbles::before, .nxe-bubbles::after {
    display: none;
}

.nxe-bubbles::before { top: -300px; left: -200px; }
.nxe-bubbles::after { bottom: -300px; right: -200px; }

/* --- App Layout --- */
.os-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding: 20px 40px;
    position: relative;
    z-index: 10;
    box-sizing: border-box;
    gap: 40px;
}

/* --- Bottom Tagline --- */
.top-tagline {
    text-align: center;
    font-family: var(--font-body);
    font-size: 1.1rem;
    font-weight: 400;
    color: #ffffff;
    text-shadow: 0 0 8px rgba(57, 255, 20, 0.4);
    letter-spacing: 0.2rem;
    text-transform: uppercase;
    opacity: 0.6;
    white-space: nowrap;
    padding-bottom: 10px;
}

/* Header */
.os-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    position: relative;
}

.header-center {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    pointer-events: none;
}

.header-welcome {
    font-family: var(--font-body);
    font-size: 1.6rem;
    color: #ffffff;
    letter-spacing: 6px;
    text-transform: uppercase;
    text-shadow: 0 0 8px rgba(57, 255, 20, 0.4);
}

.header-visitors {
    font-family: var(--font-body);
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.4);
    letter-spacing: 3px;
    text-transform: uppercase;
}

.os-logo {
    height: 60px;
    display: flex;
    align-items: center;
}

.os-logo img {
    height: 100%;
    width: auto;
    filter: drop-shadow(0 0 10px var(--y2k-blue-glow));
}

#clock {
    font-family: var(--font-body);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--y2k-text-light);
    letter-spacing: 0.5px;
    background: transparent;
    padding: 0;
    border-radius: 0;
    border: none;
    box-shadow: none;
}

.os-status {
    font-weight: bold;
    color: #666;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
}

.visit-countdown-block {
    display: flex;
    align-items: center;
    gap: 6px;
}

.countdown-label {
    font-family: "DataType", var(--font-heading);
    font-size: 0.7rem;
    color: var(--y2k-blue);
    opacity: 0.7;
}

#visit-time-static {
    font-family: var(--font-body);
    font-size: 1.4rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.35);
    letter-spacing: 0.5px;
}

#visit-countdown {
    font-family: var(--font-body);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--y2k-text-light);
    letter-spacing: 0.5px;
}

.status-widget {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 400;
    color: var(--xbox-green-dark);
    background: rgba(0,0,0,0.05);
    padding: 3px 10px;
    border-radius: 4px;
    border: 1px solid rgba(0,0,0,0.1);
}

.os-btn-icon {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    padding: 5px;
    border-radius: 5px;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.os-btn-icon:hover {
    background: rgba(255, 255, 255, 0.1);
}

.os-btn-icon svg {
    width: 24px;
    height: 24px;
    color: var(--y2k-blue);
    filter: drop-shadow(0 0 5px var(--y2k-blue-glow));
    transition: transform 0.2s, color 0.2s, filter 0.2s;
}

.os-btn-icon:hover svg {
    transform: scale(1.1);
    color: var(--y2k-green);
    filter: drop-shadow(0 0 8px rgba(57, 255, 20, 0.6));
}

/* --- Live Broadcast Section --- */
.live-broadcast-section {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.live-window {
    display: flex;
    flex-direction: column;
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    height: 600px;
}

.live-video-container {
    position: relative;
    flex-grow: 1;
    background: transparent;
    border-radius: 0;
    overflow: hidden;
    border: none;
}

.live-video-container video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: transparent;
}


.live-osd {
    position: absolute;
    top: 20px;
    left: 20px;
    display: flex;
    align-items: flex-start;
    gap: 15px;
    pointer-events: none;
    z-index: 5;
}

.live-badge {
    background: #ff0000;
    color: #fff;
    font-family: var(--font-body);
    font-weight: 400;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 1.1rem;
    letter-spacing: 1px;
    box-shadow: 0 0 15px rgba(255,0,0,0.5);
    animation: pulse-red 2s infinite;
}

@keyframes pulse-red {
    0% { opacity: 1; }
    50% { opacity: 0.6; }
    100% { opacity: 1; }
}

.live-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

#live-ch-name {
    font-family: var(--font-body);
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--y2k-text-light);
    letter-spacing: 1px;
}

#live-ch-num {
    font-family: var(--font-body);
    font-size: 1.1rem;
    color: var(--y2k-text-light);
    opacity: 0.8;
    letter-spacing: 2px;
}

.zap-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #fff;
    opacity: 0;
    pointer-events: none;
    z-index: 10;
}

.zapping .zap-overlay {
    animation: zap-flash 0.3s ease-out;
}

@keyframes zap-flash {
    0% { opacity: 0.8; }
    10% { opacity: 0; }
    20% { opacity: 0.4; }
    100% { opacity: 0; }
}

.live-bgm-toggle {
    position: absolute;
    top: 74px;
    right: 20px;
    background: var(--y2k-glass);
    border: 1px solid var(--y2k-border);
    backdrop-filter: blur(10px);
    color: var(--y2k-blue);
    padding: 10px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 15;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 15px rgba(0,0,0,0.3);
}

.live-bgm-toggle:hover {
    transform: scale(1.1);
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.95);
    border-color: rgba(255, 255, 255, 0.55);
    box-shadow:
        0 0 12px rgba(255, 255, 255, 0.18),
        0 0 24px rgba(255, 255, 255, 0.12);
}

.live-bgm-toggle img {
    width: 24px;
    height: 24px;
    object-fit: contain;
    transition: filter 0.3s ease;
}

.live-bgm-toggle.muted {
    opacity: 0.6;
    color: #666;
    border-color: rgba(255, 255, 255, 0.1);
}

.live-bgm-toggle.muted img {
    filter: grayscale(100%) opacity(70%);
}

.live-bgm-toggle.muted:hover {
    opacity: 1;
}



/* --- Fullscreen Button --- */
.live-fullscreen-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(180, 180, 180, 0.25);
    border: 1px solid rgba(200, 200, 200, 0.4);
    backdrop-filter: blur(10px);
    color: rgba(210, 210, 210, 0.85);
    padding: 10px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 15;
    font-size: 18px;
    line-height: 1;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    box-shadow: 0 0 10px rgba(0,0,0,0.3);
}

.live-fullscreen-btn:hover {
    transform: scale(1.1);
    background: rgba(200, 200, 200, 0.35);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.6);
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
}

/* --- News / Breaking Toggle Button --- */
.live-ticker-toggle {
    position: absolute;
    top: 128px;
    right: 20px;
    background: rgba(180, 180, 180, 0.25);
    border: 1px solid rgba(200, 200, 200, 0.4);
    backdrop-filter: blur(10px);
    color: rgba(210, 210, 210, 0.85);
    padding: 10px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 15;
    font-size: 18px;
    line-height: 1;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    box-shadow: 0 0 10px rgba(0,0,0,0.3);
}

.live-ticker-toggle:hover {
    transform: scale(1.1);
    background: rgba(200, 200, 200, 0.35);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.6);
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
}

.live-ticker-toggle.off {
    opacity: 0.6;
    color: #666;
    border-color: rgba(255, 255, 255, 0.12);
}

.news-ticker-bar.ticker-hidden,
.rss-ticker-bar.ticker-hidden {
    display: none;
}

/* --- Live Video Fullscreen State --- */
.live-video-container.is-fullscreen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 5000;
    border-radius: 0;
    overflow: hidden;
    background: transparent;
}

.live-video-container.is-fullscreen #live-player {
    position: relative;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: transparent;
    z-index: 1;
}

/* In fullscreen, the BREAKING bar gets moved inside .live-video-container
   (see enterFullscreen/exitFullscreen in script.js) and stacks below NEWS. */
.live-video-container.is-fullscreen .news-ticker-bar {
    bottom: 34px;
}

.live-video-container.is-fullscreen .rss-ticker-bar {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 15;
}

/* --- News Ticker Bar --- */
.news-ticker-bar {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    max-width: none;
    margin: 0;
    display: flex;
    align-items: center;
    overflow: hidden;
    background: linear-gradient(90deg, rgba(0, 5, 16, 0.97) 0%, rgba(0, 15, 40, 0.92) 50%, rgba(0, 5, 16, 0.97) 100%);
    border: none;
    border-top: 1px solid rgba(255,255,255,0.06);
    height: 68px;
    z-index: 15;
    box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.6), 0 -2px 20px rgba(0,0,0,0.4);
}

.rec-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    background: #ff2200;
    border-radius: 50%;
    margin-right: 10px;
    animation: rec-blink 1.2s ease-in-out infinite;
    flex-shrink: 0;
    box-shadow: 0 0 6px rgba(255,34,0,0.8);
}

@keyframes rec-blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.15; }
}

.ticker-label {
    flex-shrink: 0;
    min-width: var(--news-label-w, 130px);
    background: #cc0000;
    color: #ffffff;
    font-family: var(--font-heading);
    font-weight: 400;
    font-size: 1.5rem;
    letter-spacing: 3px;
    padding: 0 20px;
    height: 100%;
    display: flex;
    align-items: center;
    text-transform: uppercase;
    white-space: nowrap;
    position: relative;
    z-index: 2;
    text-shadow: 0 0 10px rgba(255,100,100,0.4);
    box-shadow: 4px 0 16px rgba(0, 0, 0, 0.6);
}

@keyframes ticker-label-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.75; }
}

.ticker-track {
    flex-grow: 1;
    overflow: hidden;
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
    mask-image: linear-gradient(90deg, transparent 0%, #000 3%, #000 97%, transparent 100%);
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 3%, #000 97%, transparent 100%);
}

.ticker-content {
    display: flex;
    align-items: center;
    padding: 0 24px;
    gap: 12px;
    opacity: 1;
    transition: opacity 0.3s ease;
    white-space: nowrap;
}

.ticker-content.fade-out {
    opacity: 0;
}

.ticker-content.scrolling {
    animation: ticker-headline-scroll linear infinite;
    padding: 0;
}

@keyframes ticker-headline-scroll {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.ticker-sep-mobile {
    display: inline-block;
    width: 60px;
    flex-shrink: 0;
}

.ticker-item {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-body);
    font-size: 1.7rem;
    font-weight: 400;
    letter-spacing: 1.5px;
    color: #ffffff;
    white-space: nowrap;
    text-shadow: 0 0 12px rgba(255,255,255,0.15);
}

.ticker-item::before {
    content: '◆';
    color: #cc0000;
    font-size: 0.7rem;
    opacity: 0.9;
    flex-shrink: 0;
}

.ticker-lang-btns {
    flex-shrink: 0;
    display: flex;
    gap: 4px;
    padding: 0 14px;
    align-items: center;
}

.ticker-lang-btn {
    font-family: var(--font-body);
    font-size: 1.1rem;
    letter-spacing: 1px;
    background: none;
    border: 1px solid rgba(255,255,255,0.2);
    color: rgba(255,255,255,0.35);
    padding: 2px 8px;
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s, background 0.2s;
}

.ticker-lang-btn:hover {
    color: rgba(255,255,255,0.7);
    border-color: rgba(255,255,255,0.5);
}

.ticker-lang-btn.active {
    color: #ffffff;
    border-color: #cc0000;
    background: rgba(204,0,0,0.25);
}

/* --- RSS Live Feed Bar --- */
.rss-ticker-bar {
    width: 100%;
    height: 34px;
    display: flex;
    align-items: center;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.7);
    border-top: 1px solid rgba(255,255,255,0.06);
    border-bottom: 1px solid rgba(255,255,255,0.04);
    flex-shrink: 0;
}

.rss-ticker-label {
    flex-shrink: 0;
    min-width: var(--news-label-w, 130px);
    background: rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.4);
    font-family: var(--font-body);
    font-size: 0.95rem;
    letter-spacing: 2px;
    padding: 0 20px;
    height: 100%;
    display: flex;
    align-items: center;
    white-space: nowrap;
    border-right: 1px solid rgba(255,255,255,0.08);
}

.rss-ticker-track {
    flex-grow: 1;
    overflow: hidden;
    height: 100%;
    display: flex;
    align-items: center;
    mask-image: linear-gradient(90deg, transparent 0%, #000 2%, #000 98%, transparent 100%);
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 2%, #000 98%, transparent 100%);
}

.rss-ticker-content {
    display: flex;
    align-items: center;
    white-space: nowrap;
    gap: 0;
    will-change: transform;
}

.rss-ticker-content.scrolling {
    animation: rss-scroll linear infinite;
}

@keyframes rss-scroll {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.rss-ticker-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 0 28px;
    font-family: var(--font-body);
    font-size: 1.05rem;
    color: rgba(200, 210, 230, 0.75);
    letter-spacing: 0.5px;
    white-space: nowrap;
    cursor: pointer;
    transition: color 0.2s;
}

.rss-ticker-item:hover {
    color: rgba(255,255,255,0.95);
}

.rss-ticker-item::before {
    content: '//';
    color: rgba(255,255,255,0.2);
    font-size: 0.8rem;
    flex-shrink: 0;
}

.rss-ticker-sep {
    display: inline-block;
    width: 1px;
    height: 12px;
    background: rgba(255,255,255,0.12);
    flex-shrink: 0;
}

.rss-ticker-placeholder {
    padding: 0 20px;
    font-family: var(--font-body);
    font-size: 1.05rem;
    color: rgba(255,255,255,0.2);
    letter-spacing: 2px;
    animation: ticker-loading-blink 1.2s ease-in-out infinite;
}

.player-drawer-shell {
    position: relative;
    width: fit-content;
    margin-left: auto;
    padding-top: 0;
}

.live-player-drawer-toggle {
    position: absolute;
    top: 0;
    right: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 18px;
    border: 1.5px solid #999;
    border-top: none;
    border-radius: 0 0 10px 10px;
    background: linear-gradient(180deg,
        #f4f4f8 0%,
        #dcdce8 18%,
        #b8bcc8 52%,
        #cfd3dd 100%);
    color: #5f77b8;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.95);
    z-index: 4;
    cursor: pointer;
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, top 0.2s ease, width 0.2s ease, height 0.2s ease;
}

.live-player-drawer-toggle:hover {
    transform: translateY(-1px);
    border-color: rgba(255, 255, 255, 0.7);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.95),
        0 0 10px rgba(255, 255, 255, 0.16),
        0 0 20px rgba(255, 255, 255, 0.1);
}

.drawer-toggle-icon {
    font-size: 1rem;
    line-height: 1;
    transition: transform 0.24s ease;
    text-shadow: 0 0 10px rgba(180, 220, 255, 0.35);
}

.player-drawer-shell.is-open .drawer-toggle-icon {
    transform: rotate(180deg);
}

.wmp-drawer {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: max-height 0.32s ease, opacity 0.22s ease;
}

.wmp-drawer.is-open {
    max-height: 130px;
    opacity: 1;
}

/* --- Channel Selector --- */
.channel-selector {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.channel-selector-label {
    font-family: var(--font-heading);
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.3);
    letter-spacing: 6px;
    text-transform: uppercase;
}

.channel-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
}

.channel-btn {
    background: linear-gradient(180deg, rgba(20, 20, 40, 0.9) 0%, rgba(5, 5, 15, 0.95) 100%);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 50%;
    width: 180px;
    height: 108px;
    padding: 0;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.channel-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 10%;
    right: 10%;
    height: 1px;
    background: transparent;
    border-radius: 50%;
    transition: background 0.3s ease;
    z-index: 3;
}

.channel-thumb {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.5;
    filter: brightness(0.8) saturate(0.9);
    pointer-events: none;
    z-index: 0;
    transition: opacity 0.3s ease, filter 0.3s ease;
}

.channel-btn:hover .channel-thumb {
    opacity: 0.65;
    filter: brightness(0.95) saturate(1);
}

.channel-btn.active .channel-thumb {
    opacity: 0.75;
    filter: brightness(1) saturate(1.05);
}

.channel-scrim {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(5,5,15,0.25) 0%, rgba(5,5,15,0.8) 100%);
    z-index: 1;
    pointer-events: none;
}

.channel-label {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    pointer-events: none;
}

.channel-btn:hover {
    border-color: rgba(255, 255, 255, 0.3);
    background: linear-gradient(180deg, rgba(30, 30, 60, 0.9) 0%, rgba(10, 10, 25, 0.95) 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.channel-btn.active {
    border-color: rgba(255, 255, 255, 0.7);
    background: linear-gradient(180deg, rgba(60, 60, 80, 0.9) 0%, rgba(30, 30, 50, 0.95) 100%);
}

.channel-btn.active::before {
    background: rgba(255, 255, 255, 0.6);
}

.channel-num {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    color: rgba(255, 255, 255, 0.6);
    letter-spacing: 2px;
    line-height: 1;
    transition: color 0.3s ease;
}

.channel-btn.active .channel-num {
    color: #ffffff;
}

.channel-name {
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.35);
    letter-spacing: 2px;
    text-transform: uppercase;
    white-space: nowrap;
    transition: color 0.3s ease;
}

.channel-btn.active .channel-name {
    color: rgba(255, 255, 255, 0.7);
}

.carousel-header {
    width: 100%;
    max-width: 1400px;
    margin: 40px auto -40px;
    padding: 0 20px;
    display: flex;
    justify-content: center;
    position: relative;
    z-index: 20;
}

.carousel-header .os-btn-icon {
    background: transparent;
    border: none;
    backdrop-filter: none;
    width: auto;
    height: auto;
    box-shadow: none;
    transition: transform 0.2s ease;
}

.carousel-header .os-btn-icon:hover {
    background: transparent;
    border: none;
    box-shadow: none;
    transform: scale(1.1);
}

.carousel-header .os-btn-icon svg {
    color: rgba(255, 255, 255, 0.7);
    filter: none;
    transition: color 0.2s ease;
}

.carousel-header .os-btn-icon:hover svg {
    color: #fff;
    filter: none;
    transform: none;
}

/* --- Carousel System --- */
.carousel-viewport {
    height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
    perspective: 2000px;
    position: relative;
    margin-bottom: 50px;
}

.carousel-container {
    position: relative;
    width: var(--card-width);
    height: var(--card-height);
    transform-style: preserve-3d;
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1), 
                width 0.8s cubic-bezier(0.16, 1, 0.3, 1), 
                height 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

/* --- Grid Mode --- */
.carousel-viewport.grid-mode {
    perspective: none;
    overflow: visible !important;
    height: auto;
    display: block; /* Switch from flex to block for standard scrolling */
    padding: 20px;
    margin-top: 100px; /* Adjusted to match distance to the button in slider mode */
}

.carousel-viewport.grid-mode::-webkit-scrollbar {
    width: 6px;
}

.carousel-viewport.grid-mode::-webkit-scrollbar-thumb {
    background: var(--y2k-blue);
    border-radius: 10px;
}

.carousel-viewport.grid-mode .carousel-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 50px 30px;
    width: 100%;
    height: auto;
    transform: none !important;
    perspective: none;
}

.carousel-viewport.grid-mode .nxe-card {
    position: relative;
    width: 100%;
    height: auto;
    transform: none !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    z-index: 1 !important;
    filter: none !important;
    animation: none !important;
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
}

.carousel-viewport.grid-mode .nxe-card .card-screen {
    aspect-ratio: 16 / 10;
    height: auto;
    border-radius: 50%;
}

.carousel-viewport.grid-mode .nxe-card:hover .card-screen {
    box-shadow: 0 8px 40px rgba(255, 255, 255, 0.12);
    transform: scale(1.03);
}

.carousel-viewport.grid-mode .nxe-card .card-reflection {
    display: none;
}



/* ============================================
   Cards — Horizontal Ellipse Video Windows
   ============================================ */
.nxe-card {
    position: absolute;
    top: 0;
    left: 0;
    width: var(--card-width);
    height: var(--card-height);
    background: transparent;
    border: none;
    border-radius: 0;
    box-shadow: none;
    overflow: visible;
    transition:
        transform 0.6s cubic-bezier(0.16, 1, 0.3, 1),
        opacity 0.6s ease,
        filter 0.4s ease;
    cursor: pointer;
    backface-visibility: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0;
}

.nxe-card.hidden {
    opacity: 0;
    pointer-events: none;
    visibility: hidden;
    transform: translateZ(-1000px) scale(0.1);
}

/* ===== Ellipse Screen Area ===== */
.card-screen {
    width: 100%;
    height: 0;
    padding-bottom: 60%; /* Horizontal ellipse aspect ratio */
    background: #000;
    position: relative;
    overflow: hidden;
    border-radius: 50%;
    border: none;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
    transition: box-shadow 0.4s ease, transform 0.4s ease;
}

.nxe-card.active .card-screen {
    box-shadow:
        0 15px 50px rgba(0, 0, 0, 0.7),
        0 0 30px rgba(255, 255, 255, 0.06);
}

.card-screen video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ===== Title Below Ellipse ===== */
.card-footer {
    padding: 14px 0 0 0;
    background: transparent;
    border: none;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    position: relative;
}

.card-footer::before {
    display: none;
}

.card-title {
    font-family: var(--font-body);
    font-weight: 400;
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.6);
    letter-spacing: 2px;
    text-transform: uppercase;
    text-shadow: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 90%;
    text-align: center;
    transition: color 0.3s ease;
}

.nxe-card.active .card-title {
    color: rgba(255, 255, 255, 0.85);
}

/* ===== Card States ===== */

.nxe-card.active {
    transform: translateZ(250px);
    z-index: 100;
}

.nxe-card.prev {
    transform: translateX(-500px) rotateY(40deg) scale(0.75);
    opacity: 0.5;
    z-index: 50;
    filter: brightness(0.55);
}

.nxe-card.next {
    transform: translateX(500px) rotateY(-40deg) scale(0.75);
    opacity: 0.5;
    z-index: 50;
    filter: brightness(0.55);
}

.nxe-card.far-prev {
    transform: translateX(-880px) rotateY(55deg) scale(0.55);
    opacity: 0.2;
    filter: brightness(0.35) blur(1px);
}

.nxe-card.far-next {
    transform: translateX(880px) rotateY(-55deg) scale(0.55);
    opacity: 0.2;
    filter: brightness(0.35) blur(1px);
}

.nxe-card:not(.active) {
    pointer-events: none;
}

/* ===== Reflections ===== */
.card-reflection {
    display: none;
}

/* --- Controls Footer --- */
.controls-hint {
    padding: 20px;
    display: flex;
    justify-content: center;
    gap: 30px;
    font-weight: bold;
    color: #555;
}

.button-icon {
    display: inline-block;
    width: 24px;
    height: 24px;
    background: #333;
    color: #fff;
    border-radius: 50%;
    text-align: center;
    line-height: 24px;
    font-size: 12px;
    margin-right: 8px;
}

.btn-a { background: #4caf50; }
.btn-b { background: #f44336; }
.btn-x { background: #2196f3; }
.btn-y { background: #ffeb3b; color: #000; }


.live-badge {
    animation: pulse-red 2s infinite;
}

/* CRT Overlay (Legacy fallback for weirdcore feel) */
.crt-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
    opacity: 0.1; /* Subtler for NXE */
}

@keyframes scanline-move {
    from { background-position: 0 0; }
    to { background-position: 0 100%; }
}

.scanlines {
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(24, 255, 236, 0.05) 50%);
    background-size: 100% 4px;
    animation: scanline-move 10s linear infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0) translateZ(0); }
    50% { transform: translateY(-10px) translateZ(20px); }
}

/* (active state defined above in Card States) */



/* Hover effect on active ellipse card */
.nxe-card.active:hover .card-screen {
    box-shadow:
        0 15px 50px rgba(0, 0, 0, 0.7),
        0 0 40px rgba(255, 255, 255, 0.08);
    transform: scale(1.02);
}

/* --- WMP9 Style Music Player --- */
.wmp-player {
    display: flex;
    width: fit-content;
    margin-left: auto;
    margin-top: 0;
    align-items: center;
    gap: 0;
    z-index: 10000;
    height: 78px;
    min-width: 380px;
    border-radius: 50px;
    background: linear-gradient(180deg,
        #f4f4f8 0%,
        #dcdce8 15%,
        #b8bcc8 45%,
        #c4c8d4 75%,
        #e0e0ea 100%);
    border: 1.5px solid #999;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.95),
        inset 0 -1px 0 rgba(0,0,0,0.2),
        inset 1px 0 0 rgba(255,255,255,0.6);
    padding: 0 16px 0 0;
    user-select: none;
    cursor: default;
}

.player-drawer-shell .wmp-player {
    border-top-left-radius: 6px;
    border-top-right-radius: 6px;
    border-bottom-left-radius: 50px;
    border-bottom-right-radius: 50px;
}

.player-drawer-shell.is-open .wmp-player {
    padding-right: 44px;
}

.player-drawer-shell.is-open .live-player-drawer-toggle {
    top: 0;
    width: 44px;
    height: 78px;
    border: 1.5px solid #999;
    border-radius: 0 6px 50px 0;
    background: linear-gradient(180deg,
        #f4f4f8 0%,
        #dcdce8 15%,
        #b8bcc8 45%,
        #c4c8d4 75%,
        #e0e0ea 100%);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.95),
        inset 0 -1px 0 rgba(0,0,0,0.2);
}

.player-drawer-shell.is-open .live-player-drawer-toggle:hover {
    transform: none;
    border-color: #999;
    filter: none;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.95),
        inset 0 -1px 0 rgba(0,0,0,0.2);
}

/* Orb (Play/Pause) */
.wmp-orb {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    flex-shrink: 0;
    margin-left: 8px;
    background: radial-gradient(circle at 37% 33%,
        #d0e0ff 0%,
        #6090e0 22%,
        #1848c0 52%,
        #082888 78%,
        #040e40 100%);
    border: 2px solid rgba(80,120,200,0.6);
    box-shadow:
        inset 0 -4px 10px rgba(0,0,0,0.5),
        inset 3px 4px 10px rgba(200,220,255,0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: filter 0.1s, transform 0.1s;
}

.wmp-orb:hover { filter: brightness(1.15); }
.wmp-orb:active { transform: scale(0.95); filter: brightness(0.85); }

.wmp-orb-icon {
    font-family: sans-serif;
    font-size: 1.65rem;
    color: rgba(255,255,255,0.92);
    text-shadow: 0 0 10px rgba(160,200,255,0.9);
    margin-left: 3px;
    line-height: 1;
}

/* Transport Buttons */
.wmp-transport {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 0 10px;
    flex-shrink: 0;
}

.wmp-ctrl {
    background: linear-gradient(180deg, #e8e8f2 0%, #c0c4d2 100%);
    border: 1px solid #8888a0;
    border-radius: 3px;
    width: 32px;
    height: 18px;
    font-size: 0.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #222;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.85),
        inset 0 -1px 0 rgba(0,0,0,0.12);
    transition: filter 0.1s;
    padding: 0;
}

.wmp-ctrl:hover { filter: brightness(1.1); }
.wmp-ctrl:active {
    filter: brightness(0.85);
    box-shadow: inset 0 2px 3px rgba(0,0,0,0.3);
}

/* Right panel */
.wmp-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 7px;
    min-width: 0;
    padding-right: 4px;
}

/* Display */
.wmp-display {
    background: linear-gradient(180deg, #04070f 0%, #080e22 60%, #050918 100%);
    border: 1px solid #223;
    border-radius: 4px;
    padding: 4px 8px;
    box-shadow: inset 0 2px 6px rgba(0,0,0,0.9);
    overflow: hidden;
}

.wmp-track-wrap {
    font-family: var(--font-body);
    font-size: 1.1rem;
    color: #7799ee;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: 1px;
}

/* Volume row */
.wmp-vol-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.wmp-vol-label {
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: #555;
    flex-shrink: 0;
    letter-spacing: 1px;
}

#wmp-vol {
    flex: 1;
    height: 3px;
    cursor: pointer;
    accent-color: #5577cc;
    border-radius: 2px;
}

@keyframes wmp-marquee {
    0%   { transform: translateX(0); }
    20%  { transform: translateX(0); }
    80%  { transform: translateX(var(--marquee-distance, -50%)); }
    100% { transform: translateX(var(--marquee-distance, -50%)); }
}

.wmp-track-wrap.scrolling span {
    display: inline-block;
    animation: wmp-marquee 6s ease-in-out infinite alternate;
}


/* --- Story Overlay --- */
.story-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 15000;
    justify-content: center;
    align-items: center;
    background: rgba(0, 5, 16, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    opacity: 0;
    transition: opacity 0.5s ease;
}

.story-overlay.show {
    display: flex;
    opacity: 1;
}

.story-content {
    max-width: 560px;
    padding: 0 40px;
    display: flex;
    flex-direction: column;
    gap: 5.5rem;
}

.story-lang {
    display: flex;
    flex-direction: column;
    gap: 1.3rem;
}

.story-content p {
    font-family: var(--font-body);
    font-size: 1.4rem;
    color: var(--y2k-text-light);
    line-height: 1.9;
    letter-spacing: 1px;
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

#story-ja p {
    font-size: 0.9rem;
    letter-spacing: 0.05em;
    line-height: 2.1;
}

.story-overlay.show .story-content p:nth-child(1) { opacity: 1; transform: none; transition-delay: 0.2s; }
.story-overlay.show .story-content p:nth-child(2) { opacity: 1; transform: none; transition-delay: 0.5s; }
.story-overlay.show .story-content p:nth-child(3) { opacity: 1; transform: none; transition-delay: 0.8s; }
.story-overlay.show .story-content p:nth-child(4) { opacity: 1; transform: none; transition-delay: 1.1s; }
.story-overlay.show .story-content p:nth-child(5) { opacity: 1; transform: none; transition-delay: 1.4s; }
.story-overlay.show .story-content p:nth-child(6) { opacity: 1; transform: none; transition-delay: 1.7s; }

.story-lang-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 1rem;
}

.story-lang-btn {
    background: none;
    border: none;
    font-family: var(--font-body);
    font-size: 1.2rem;
    letter-spacing: 2px;
    color: rgba(255, 255, 255, 0.25);
    cursor: pointer;
    transition: color 0.2s;
    padding: 0;
}

.story-lang-btn.active {
    color: var(--y2k-text-light);
}

.story-lang-btn:hover { color: rgba(255, 255, 255, 0.6); }

.story-lang-sep {
    color: rgba(255, 255, 255, 0.15);
    font-family: var(--font-body);
    font-size: 1.2rem;
}

.story-close {
    position: absolute;
    top: 32px;
    right: 40px;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.3);
    font-size: 2.5rem;
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s;
}

.story-close:hover { color: rgba(255, 255, 255, 0.8); }

.os-logo {
    cursor: pointer;
}

.archive-link {
    font-family: var(--font-body);
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.35);
    text-decoration: none;
    letter-spacing: 2px;
    transition: color 0.2s;
    white-space: nowrap;
}

/* --- Video Modal (Focus Mode) --- */
.os-modal {
    display: none;
    position: fixed;
    z-index: 20000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.9);
    backdrop-filter: blur(10px);
    justify-content: center;
    align-items: center;
}

.os-modal-content {
    position: relative;
    width: 80%;
    max-width: 1000px;
    background: var(--y2k-bg-dark);
    border: 1px solid var(--y2k-border);
    border-radius: 8px;
    padding: 5px;
    backdrop-filter: blur(20px);
}

.os-modal-content video {
    width: 100%;
    max-height: 80vh; /* Ensure it fits vertically */
    display: block;
    border-radius: 10px;
    object-fit: contain;
}

.os-close-btn {
    position: absolute;
    top: -40px;
    right: 0;
    color: #fff;
    font-size: 3rem;
    cursor: pointer;
    transition: color 0.2s;
}

.os-close-btn:hover {
    color: var(--xbox-green);
}

.os-modal.show {
    display: flex;
}

/* --- Mobile Responsiveness --- */
@media (max-width: 768px) {
    :root {
        --card-width: 300px;
        --card-height: 225px;
        --card-gap: 20px;
    }

    .os-container {
        padding: 15px;
    }

    .os-logo {
        font-size: 1.8rem;
    }

    .status-widget {
        display: none; /* Hide complex widgets on small mobile */
    }

    .status-widget:first-child {
        display: block; /* Keep at least one */
    }

    .nxe-card.prev {
        transform: translateX(-180px) rotateY(45deg) scale(0.6);
    }

    .nxe-card.next {
        transform: translateX(180px) rotateY(-45deg) scale(0.6);
    }
    
    .nxe-card.far-prev, .nxe-card.far-next {
        display: none;
    }

    .top-tagline {
        top: 15px;
        font-size: 0.65rem;
    }

    .os-header {
        flex-direction: column;
        align-items: center;
        gap: 24px;
        margin-top: 10px;
    }

    .os-logo {
        align-self: center;
        order: 1;
    }

    .header-center {
        display: flex;
        position: static;
        transform: none;
        left: auto;
        order: 2;
    }

    .os-status {
        position: static;
        align-items: center;
        order: 3;
    }

    .os-status {
        position: static;
        align-items: center;
    }

    #clock {
        display: none;
    }

    .visit-countdown-block {
        display: none;
    }

    #visit-time-static {
        font-size: 1rem;
    }

    #custom-cursor {
        display: none; /* No custom cursor on touch devices */
    }

    body {
        cursor: auto;
    }

    .os-container {
        gap: 16px;
    }

    .os-header {
        margin-bottom: 0;
    }

    .live-broadcast-section {
        padding: 0;
    }

    .wmp-player {
        width: 100%;
        min-width: 0;
        margin-left: 0;
    }

    .player-drawer-shell .wmp-player {
        border-radius: 12px;
    }

    .player-drawer-shell {
        width: 100%;
        padding-top: 0;
    }

    .live-player-drawer-toggle {
        right: 0;
        width: 40px;
        height: 18px;
    }

    .player-drawer-shell.is-open .wmp-player {
        padding-right: 38px;
    }

    .player-drawer-shell.is-open .live-player-drawer-toggle {
        top: 0;
        width: 38px;
        height: 78px;
        border-radius: 0 12px 12px 0;
    }

    .channel-buttons {
        gap: 8px;
    }

    .channel-btn {
        width: 120px;
        height: 72px;
    }

    .channel-num {
        font-size: 1.4rem;
    }

    .channel-name {
        font-size: 0.7rem;
    }
}
