/* Player2 - Veamcast Player Styles
   Dark theme, cover page layout, responsive.
   This file is used by the web shell (index.html).
   VeamPlayerGenerator also embeds these styles in self-contained player.html for local preview.
*/

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --bg-primary: #0a0a14;
    --bg-header: linear-gradient(135deg, #101028 0%, #18183a 100%);
    --bg-card: rgba(255,255,255,0.03);
    --border-subtle: rgba(255,255,255,0.08);
    --border-accent: rgba(100,130,220,0.2);
    --text-primary: #e0e0e8;
    --text-heading: #fff;
    --text-muted: rgba(255,255,255,0.45);
    --text-accent: rgba(100,130,220,0.8);
    --link-color: rgba(100,160,255,0.9);
    --play-btn-bg: rgba(100,130,220,0.25);
    --play-btn-hover: rgba(100,130,220,0.45);
    --info-btn-bg: rgba(255,255,255,0.08);
    --info-btn-hover: rgba(255,255,255,0.15);

    /* Accent gradient shades — derived from accent color for menu/play buttons */
    --accent-1: #040e2e;
    --accent-2: #081a4a;
    --accent-3: #0c2868;
    --accent-4: #143c8c;
    --accent-5: #1e5cc0;
    --accent-6: #5090dd;
    --accent-border: rgba(50,120,220,0.3);
    --accent-border-strong: rgba(60,140,255,0.55);
    --accent-glow: rgba(100,130,220,0.3);
    --accent-glow-strong: rgba(100,130,220,0.5);
    --accent-subtle: rgba(100,130,220,0.15);
    --accent-tint: rgba(100,130,220,0.08);
}

html, body {
    height: 100%;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
}

/* ===== HEADER + MENU BAR ===== */
/* Hidden by default (preview mode). Shown via JS in web mode. */
.player-header {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 52px;
    z-index: 150;
    background: transparent;
    border-bottom: none;
    box-shadow: none;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
}

.player-header.visible {
    display: flex;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
    margin-left: 12px;
    margin-right: auto;
}

/* Profile avatar+name — sits after logo, pushes menu buttons right */
.header-profile {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-left: 32px;
    margin-right: 48px;
    cursor: pointer;
    border-radius: 6px;
    padding: 8px 18px 8px 10px;
    background: linear-gradient(135deg, var(--accent-1) 0%, var(--accent-2) 20%, var(--accent-3) 40%, var(--accent-4) 60%, var(--accent-3) 80%, var(--accent-1) 100%);
    border: 1px solid var(--accent-border);
    box-shadow:
        0 2px 12px var(--accent-glow),
        0 1px 3px rgba(0,0,0,0.5),
        inset 0 1px 0 rgba(255,255,255,0.2),
        inset 0 -1px 0 rgba(0,0,0,0.2);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.header-profile::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(
        170deg,
        rgba(255,255,255,0.28) 0%,
        rgba(255,255,255,0.08) 25%,
        transparent 50%,
        rgba(60,120,220,0.06) 75%,
        rgba(30,80,180,0.1) 100%
    );
    pointer-events: none;
}
.header-profile:hover {
    transform: translateY(-1px);
    box-shadow:
        0 4px 18px var(--accent-glow),
        0 2px 6px rgba(0,0,0,0.5),
        inset 0 1px 0 rgba(255,255,255,0.25),
        inset 0 -1px 0 rgba(0,0,0,0.2);
}
.header-profile:empty { display: none; }
.header-profile-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255,255,255,0.25);
    flex-shrink: 0;
}
.header-profile-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}
.header-profile-name {
    color: rgba(255,255,255,0.95);
    font-size: 16px;
    font-weight: 600;
    white-space: nowrap;
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    text-shadow: 0 1px 3px rgba(0,0,0,0.7);
}
.header-profile-email {
    color: rgba(255,255,255,0.55);
    font-size: 12px;
    white-space: nowrap;
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Animated logo (inline SVG) */
.veamcast-logo {
    display: inline-block;
}
.veamcast-logo svg {
    width: 100%;
    height: auto;
    overflow: visible;
}

/* Beam animation — only plays when .loading is on the .veamcast-logo */
.logo-beam {
    transform-box: fill-box;
    transform-origin: -3.3% 0%;
    animation: none;
}
.logo-glow {
    animation: none;
}
.veamcast-logo.loading .logo-beam {
    animation: logo-beam-scale 4s linear infinite;
}
.veamcast-logo.loading .logo-glow {
    animation: logo-glow-pulse 4s linear infinite;
}
@keyframes logo-beam-scale {
    0%   { transform: scaleX(0) scaleY(1); }
    25%  { transform: scaleX(1) scaleY(1); }
    50%  { transform: scaleX(0) scaleY(4); }
    75%  { transform: scaleX(-1) scaleY(1); }
    100% { transform: scaleX(0) scaleY(1); }
}
@keyframes logo-glow-pulse {
    0%   { opacity: 0; }
    40%  { opacity: 0; }
    45%  { opacity: 0.25; }
    50%  { opacity: 1; }
    55%  { opacity: 0.25; }
    60%  { opacity: 0; }
    100% { opacity: 0; }
}

.header-logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    cursor: pointer;
    transition: opacity 0.3s, filter 0.3s;
    opacity: 0.92;
    filter: drop-shadow(0 0 6px rgba(80,140,255,0.25));
}
.header-logo-link:hover {
    opacity: 1;
    filter: drop-shadow(0 0 12px rgba(80,140,255,0.5));
}

.header-logo {
    height: 28px;
    width: auto;
}

/* ===== NAVIGATION LOADER (ship's wheel overlay, shown during panel transitions) ===== */
.nav-loader {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 140;
    background: rgba(10, 10, 20, 0.45);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    align-items: center;
    justify-content: center;
    overflow: hidden;
    animation: nav-loader-in 0.3s ease-out;
}
.nav-loader.visible {
    display: flex;
}
.nav-loader-wheel {
    width: 110vmin;
    height: 110vmin;
    max-width: none;
    max-height: none;
    opacity: 0.08;
    animation: veamcast-spin-slow 6s linear infinite;
}
@keyframes nav-loader-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* Menu buttons — gradient glass tabs with glow effects */
.header-menu {
    display: flex;
    align-items: center;
    gap: 4px;
}

.menu-btn {
    position: relative;
    background: linear-gradient(135deg, var(--accent-1) 0%, var(--accent-2) 20%, var(--accent-3) 40%, var(--accent-4) 60%, var(--accent-3) 80%, var(--accent-1) 100%);
    border: 1px solid var(--accent-border);
    color: rgba(255,255,255,0.95);
    font-size: 14px;
    font-weight: 600;
    padding: 9px 18px;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    letter-spacing: 0.5px;
    overflow: hidden;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow:
        0 2px 12px var(--accent-glow),
        0 1px 3px rgba(0,0,0,0.5),
        inset 0 1px 0 rgba(255,255,255,0.2),
        inset 0 -1px 0 rgba(0,0,0,0.2);
    text-shadow: 0 1px 3px rgba(0,0,0,0.7);
}

/* Glass sheen overlay — bright top shine */
.menu-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(
        170deg,
        rgba(255,255,255,0.28) 0%,
        rgba(255,255,255,0.08) 25%,
        transparent 50%,
        rgba(60,120,220,0.06) 75%,
        rgba(30,80,180,0.1) 100%
    );
    pointer-events: none;
    opacity: 1;
    transition: opacity 0.3s;
}

/* Bottom glow line */
.menu-btn::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 15%;
    width: 70%;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--accent-border), var(--accent-border-strong), var(--accent-border), transparent);
    border-radius: 2px;
    opacity: 0;
    transition: opacity 0.3s, transform 0.3s;
    transform: scaleX(0.2);
    filter: blur(0.5px);
}

.menu-btn:hover {
    background: linear-gradient(135deg, var(--accent-2) 0%, var(--accent-3) 20%, var(--accent-4) 45%, var(--accent-5) 60%, var(--accent-4) 80%, var(--accent-2) 100%);
    border-color: var(--accent-border-strong);
    color: #fff;
    transform: translateY(-2px) scale(1.08);
    box-shadow:
        0 4px 24px var(--accent-glow-strong),
        0 8px 32px var(--accent-glow),
        0 1px 3px rgba(0,0,0,0.5),
        inset 0 1px 0 rgba(255,255,255,0.25);
}

.menu-btn:hover::before {
    opacity: 1;
    background: linear-gradient(
        170deg,
        rgba(255,255,255,0.4) 0%,
        rgba(255,255,255,0.12) 20%,
        transparent 45%,
        rgba(60,140,220,0.1) 80%,
        rgba(30,100,200,0.14) 100%
    );
}

.menu-btn:hover::after {
    opacity: 1;
    transform: scaleX(1);
}

.menu-btn:active {
    transform: translateY(0) scale(0.96);
    transition-duration: 0.1s;
    background: linear-gradient(135deg, var(--accent-1) 0%, var(--accent-2) 30%, var(--accent-3) 60%, var(--accent-1) 100%);
    box-shadow:
        0 0 20px var(--accent-glow-strong),
        inset 0 2px 6px rgba(0,0,0,0.5),
        inset 0 -1px 0 rgba(255,255,255,0.08);
}

.menu-btn.active {
    color: #fff;
    background: linear-gradient(135deg, var(--accent-2) 0%, var(--accent-3) 25%, var(--accent-5) 50%, var(--accent-4) 75%, var(--accent-2) 100%);
    border-color: var(--accent-border-strong);
    box-shadow:
        0 0 18px var(--accent-glow-strong),
        0 4px 20px var(--accent-glow),
        0 1px 3px rgba(0,0,0,0.4),
        inset 0 1px 0 rgba(255,255,255,0.25);
    animation: menu-btn-active-pulse 2s ease-in-out infinite;
}

.menu-btn.active::after {
    opacity: 1;
    transform: scaleX(1);
    background: linear-gradient(90deg, transparent, var(--accent-border-strong), var(--accent-6), var(--accent-border-strong), transparent);
    height: 3px;
}

@keyframes menu-btn-active-pulse {
    0%, 100% {
        box-shadow: 0 0 18px var(--accent-glow-strong), 0 4px 20px var(--accent-glow), inset 0 1px 0 rgba(255,255,255,0.25);
    }
    50% {
        box-shadow: 0 0 28px var(--accent-glow-strong), 0 4px 28px var(--accent-glow-strong), inset 0 1px 0 rgba(255,255,255,0.3);
    }
}

/* ===== MOBILE MENU TRIGGER (spinner wheel) ===== */
.mobile-menu-trigger {
    display: none;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 1px solid var(--accent-border-strong);
    background: linear-gradient(135deg, var(--accent-1) 0%, var(--accent-2) 30%, var(--accent-3) 60%, var(--accent-2) 85%, var(--accent-1) 100%);
    cursor: pointer;
    position: relative;
    overflow: visible;
    box-shadow:
        0 0 18px var(--accent-glow),
        0 2px 10px rgba(0,0,0,0.5),
        inset 0 1px 0 rgba(255,255,255,0.18);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s;
}

.mobile-menu-trigger::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: linear-gradient(160deg, rgba(255,255,255,0.35) 0%, rgba(255,255,255,0.1) 30%, transparent 55%);
    pointer-events: none;
}

.mobile-menu-trigger::after {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 50%;
    border: 1.5px solid var(--accent-border);
    pointer-events: none;
    animation: play-ring-breathe 3s ease-in-out infinite;
}

.mobile-menu-trigger:hover {
    transform: scale(1.12);
    background: linear-gradient(135deg, var(--accent-2) 0%, var(--accent-3) 30%, var(--accent-4) 55%, var(--accent-3) 80%, var(--accent-2) 100%);
    border-color: var(--accent-border-strong);
    box-shadow:
        0 0 30px var(--accent-glow-strong),
        0 4px 18px var(--accent-glow),
        inset 0 1px 0 rgba(255,255,255,0.22);
}

.mobile-menu-trigger:active {
    transform: scale(0.9);
    transition-duration: 0.1s;
}

.mobile-menu-trigger .spinner-svg {
    width: 100%;
    height: 100%;
    animation: veamcast-spin-slow 8s linear infinite;
}

.mobile-menu-trigger.open .spinner-svg {
    animation: veamcast-spin-slow 3s linear infinite;
}

@keyframes veamcast-spin-slow {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* ===== MOBILE NAVIGATION MENU (stacked buttons) ===== */
.mobile-nav-menu {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 160;
    background: rgba(5,5,18,0.97);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    overflow-y: auto;
    animation: mobile-menu-in 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.mobile-nav-menu.visible {
    display: flex;
    flex-direction: column;
}

@keyframes mobile-menu-in {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

/* Status bar at top */
.mobile-menu-status {
    flex-shrink: 0;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--accent-subtle);
    background: linear-gradient(135deg, rgba(15,15,40,0.9) 0%, rgba(25,20,55,0.9) 100%);
}

.mobile-menu-status-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.mobile-menu-status-title {
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.5px;
}

.mobile-menu-status-sub {
    font-size: 12px;
    color: var(--text-muted);
}

.mobile-menu-close {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,0.12);
    background: rgba(255,255,255,0.05);
    color: rgba(255,255,255,0.6);
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.mobile-menu-close:hover {
    background: rgba(255,80,80,0.2);
    border-color: rgba(255,80,80,0.4);
    color: #ff8080;
    transform: rotate(90deg);
}

/* Stacked menu buttons */
.mobile-menu-buttons {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 16px 12px;
    gap: 8px;
    overflow-y: auto;
}

.mobile-menu-btn {
    position: relative;
    display: flex;
    align-items: center;
    gap: 16px;
    width: 100%;
    padding: 18px 20px;
    border-radius: 8px;
    border: 1px solid var(--accent-tint);
    background: linear-gradient(135deg, rgba(10,10,30,0.8) 0%, rgba(20,15,50,0.7) 100%);
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    overflow: hidden;
    text-align: left;
    transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow:
        0 2px 12px rgba(0,0,0,0.3),
        inset 0 1px 0 rgba(255,255,255,0.06);
}

/* Gradient overlay on mobile buttons - unique per button */
.mobile-menu-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    opacity: 0.5;
    transition: opacity 0.3s;
    pointer-events: none;
}

.mobile-menu-btn[data-panel="inbox"]::before { background: linear-gradient(135deg, rgba(60,100,200,0.15) 0%, transparent 60%); }
.mobile-menu-btn[data-panel="reply"]::before { background: linear-gradient(135deg, rgba(100,200,120,0.15) 0%, transparent 60%); }
.mobile-menu-btn[data-panel="share"]::before { background: linear-gradient(135deg, rgba(200,120,60,0.15) 0%, transparent 60%); }
.mobile-menu-btn[data-panel="info"]::before { background: linear-gradient(135deg, rgba(160,100,220,0.15) 0%, transparent 60%); }
.mobile-menu-btn[data-panel="discover"]::before { background: linear-gradient(135deg, rgba(60,200,200,0.15) 0%, transparent 60%); }
.mobile-menu-btn[data-panel="rate"]::before { background: linear-gradient(135deg, rgba(220,180,60,0.15) 0%, transparent 60%); }

/* Glass sheen */
.mobile-menu-btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 50%;
    border-radius: 14px 14px 0 0;
    background: linear-gradient(180deg, rgba(255,255,255,0.06) 0%, transparent 100%);
    pointer-events: none;
}

.mobile-menu-btn:hover {
    border-color: var(--accent-border-strong);
    transform: translateX(4px) scale(1.03);
    box-shadow:
        0 4px 24px var(--accent-glow),
        0 8px 32px var(--accent-glow),
        0 2px 6px rgba(0,0,0,0.4),
        inset 0 1px 0 rgba(255,255,255,0.12);
}

.mobile-menu-btn:hover::before {
    opacity: 1;
}

.mobile-menu-btn:hover .mobile-menu-btn-icon {
    background: linear-gradient(135deg, var(--accent-2) 0%, var(--accent-3) 40%, var(--accent-4) 65%, var(--accent-3) 100%);
    border-color: var(--accent-border-strong);
    box-shadow:
        0 2px 12px var(--accent-glow),
        inset 0 1px 0 rgba(255,255,255,0.22);
}

.mobile-menu-btn:active {
    transform: translateX(2px) scale(0.98);
    transition-duration: 0.1s;
}

.mobile-menu-btn-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
    background: linear-gradient(135deg, var(--accent-1) 0%, var(--accent-2) 35%, var(--accent-3) 65%, var(--accent-2) 100%);
    border: 1px solid var(--accent-border);
    box-shadow:
        0 2px 8px var(--accent-glow),
        inset 0 1px 0 rgba(255,255,255,0.15);
}

.mobile-menu-btn-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    z-index: 1;
}

.mobile-menu-btn-label {
    font-size: 16px;
    font-weight: 600;
    color: #fff;
}

.mobile-menu-btn-desc {
    font-size: 12px;
    color: var(--text-muted);
}

.mobile-menu-btn-arrow {
    margin-left: auto;
    font-size: 16px;
    color: var(--text-muted);
    transition: transform 0.3s, color 0.3s;
    z-index: 1;
}

.mobile-menu-btn:hover .mobile-menu-btn-arrow {
    transform: translateX(4px);
    color: rgba(100,160,255,0.8);
}

/* Spinner decoration in mobile menu */
.mobile-menu-spinner {
    position: absolute;
    top: 50%;
    right: 20px;
    transform: translateY(-50%);
    width: 200px;
    height: 200px;
    opacity: 0.04;
    pointer-events: none;
    animation: veamcast-spin-slow 20s linear infinite;
}

/* ===== MENU PANEL (slide-down overlay) ===== */
.menu-panel {
    display: none;
    position: fixed;
    top: 52px;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 140;
    background: rgba(8,8,20,0.96);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    animation: menu-panel-in 0.3s ease-out;
}

.menu-panel.visible {
    display: block;
}

@keyframes menu-panel-in {
    from { opacity: 0; transform: translateY(-12px); }
    to { opacity: 1; transform: translateY(0); }
}

.menu-panel-header {
    display: none;
}

.menu-panel-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-heading);
    text-transform: capitalize;
}

.menu-panel-close {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.05);
    color: rgba(255,255,255,0.6);
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s, transform 0.25s;
}

.menu-panel-close:hover {
    background: rgba(255,255,255,0.1);
    color: #fff;
    transform: rotate(90deg);
}

.menu-panel-body {
    padding: 32px 24px;
    max-width: 800px;
    margin: 0 auto;
    overflow-y: auto;
    max-height: calc(100vh - 52px);
    color: var(--text-primary);
    font-size: 15px;
    line-height: 1.6;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.15) rgba(0,0,0,0.2);
}
.menu-panel-body::-webkit-scrollbar { width: 8px; }
.menu-panel-body::-webkit-scrollbar-track { background: rgba(0,0,0,0.2); }
.menu-panel-body::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.15);
    border-radius: 4px;
}
.menu-panel-body::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.25); }

.menu-panel-placeholder {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
    font-size: 16px;
}

/* ===== BOTTOM BAR (owner info + title) ===== */
.bottom-bar {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 12px 24px;
    background: transparent;
    pointer-events: none;
    align-items: flex-end;
    gap: 24px;
}

.bottom-bar.visible {
    display: flex;
}

.bottom-owner {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    flex-shrink: 0;
}

.bottom-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 2px solid rgba(100,130,220,0.25);
    object-fit: cover;
}

.bottom-shared-by {
    font-size: 11px;
    color: rgba(255,255,255,0.45);
}

.bottom-sender-name {
    font-size: 16px;
    font-weight: 600;
    color: #fff;
}

.bottom-date {
    font-size: 11px;
    color: rgba(255,255,255,0.4);
}

.bottom-title {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    padding: 8px 16px;
    background: linear-gradient(to right,
        rgba(0,0,80,0.5) 0%,
        rgba(0,0,0,0.3) 34%,
        transparent 100%
    );
    border-radius: 6px;
}

.bottom-subject {
    font-size: clamp(18px, 3vw, 28px);
    font-weight: 600;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 50vw;
}

.bottom-description {
    font-size: clamp(12px, 1.5vw, 14px);
    color: rgba(255,255,255,0.6);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 50vw;
}

/* When header is visible, offset cover page and playback viewport */
.player-header.visible ~ .cover-page {
    padding-top: calc(52px + 3vw);
}

.player-header.visible ~ .veam-playback {
    top: 52px;
}

.player-header.visible ~ #info-btn {
    bottom: 60px;
}

/* Bottom bar hides during playback and when menu panel is open */
.menu-panel.visible ~ .bottom-bar {
    display: none !important;
}

/* ===== COVER PAGE ===== */
.cover-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 5vw 5vw 3vw;
    text-align: center;
    position: relative;
}

.cover-title-top {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-muted);
    letter-spacing: 0.5px;
    margin-bottom: 16px;
    max-width: 90vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cover-thumbnail {
    width: 100%;
    max-width: 90vw;
    max-height: 50vh;
    object-fit: contain;
    border-radius: 12px;
    border: 1px solid var(--border-subtle);
    background: rgba(255,255,255,0.02);
    margin-bottom: 24px;
    box-shadow: 0 12px 60px rgba(0,0,0,0.5);
}

.cover-thumbnail-placeholder {
    width: 100%;
    max-width: 90vw;
    height: 40vh;
    border-radius: 12px;
    border: 1px solid var(--border-subtle);
    background: rgba(255,255,255,0.02);
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 72px;
}

.cover-subject {
    font-size: clamp(24px, 5vw, 42px);
    font-weight: 700;
    color: var(--text-heading);
    margin-bottom: 12px;
    max-width: 90vw;
    line-height: 1.2;
}

.cover-description {
    font-size: clamp(14px, 2.5vw, 18px);
    color: var(--text-muted);
    margin-bottom: 28px;
    max-width: 80vw;
    line-height: 1.5;
}

/* Owner info */
.cover-owner {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 8px;
    margin-bottom: 32px;
}

.cover-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 2px solid var(--border-accent);
    object-fit: cover;
    background: rgba(255,255,255,0.05);
}

.cover-avatar-placeholder {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 2px solid var(--border-accent);
    background: rgba(100,130,220,0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-accent);
    font-size: 18px;
    font-weight: 600;
}

.cover-owner-name {
    font-size: 15px;
    font-weight: 500;
    color: var(--text-primary);
}

/* Play button — shiny blue glass with animated glow */
.cover-play-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 14px;
    padding: 22px 64px;
    border-radius: 10px;
    border: 1px solid var(--accent-border);
    background: linear-gradient(135deg, var(--accent-1) 0%, var(--accent-2) 18%, var(--accent-3) 36%, var(--accent-4) 52%, var(--accent-3) 70%, var(--accent-2) 86%, var(--accent-1) 100%);
    color: #fff;
    font-size: clamp(17px, 2.5vw, 22px);
    font-weight: 700;
    cursor: pointer;
    letter-spacing: 1px;
    min-width: 220px;
    justify-content: center;
    overflow: hidden;
    z-index: 1;
    text-shadow: 0 2px 10px rgba(0,0,0,0.8);
    box-shadow:
        0 0 30px var(--accent-glow),
        0 6px 24px var(--accent-glow),
        0 2px 6px rgba(0,0,0,0.5),
        inset 0 1px 0 rgba(255,255,255,0.22),
        inset 0 -1px 0 rgba(0,0,0,0.25);
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.35s ease;
    animation: play-glow-breathe 3s ease-in-out infinite;
}

/* Glass overlay — bright top-shine with specular highlight */
.cover-play-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(
        170deg,
        rgba(255,255,255,0.35) 0%,
        rgba(255,255,255,0.12) 22%,
        transparent 48%,
        rgba(40,100,200,0.08) 70%,
        rgba(20,60,160,0.12) 100%
    );
    pointer-events: none;
    transition: opacity 0.4s;
}

/* Animated glow ring */
.cover-play-btn::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: inherit;
    border: 2px solid var(--accent-border);
    pointer-events: none;
    animation: play-ring-breathe 3s ease-in-out infinite;
}

.cover-play-btn:hover {
    transform: scale(1.1);
    background: linear-gradient(135deg, var(--accent-1) 0%, var(--accent-2) 20%, var(--accent-4) 42%, var(--accent-5) 55%, var(--accent-4) 72%, var(--accent-2) 88%, var(--accent-1) 100%);
    border-color: var(--accent-border-strong);
    box-shadow:
        0 0 50px var(--accent-glow-strong),
        0 0 80px var(--accent-glow),
        0 10px 40px var(--accent-glow),
        0 2px 6px rgba(0,0,0,0.4),
        inset 0 1px 0 rgba(255,255,255,0.28);
}

.cover-play-btn:hover::before {
    background: linear-gradient(
        170deg,
        rgba(255,255,255,0.45) 0%,
        rgba(255,255,255,0.18) 18%,
        transparent 45%,
        rgba(50,120,220,0.12) 75%,
        rgba(30,80,180,0.16) 100%
    );
    animation: glass-flash 0.6s ease-out;
}

.cover-play-btn:active {
    transform: scale(0.94);
    transition-duration: 0.1s;
    background: linear-gradient(135deg, var(--accent-1) 0%, var(--accent-2) 30%, var(--accent-3) 60%, var(--accent-1) 100%);
    box-shadow:
        0 0 30px var(--accent-glow-strong),
        0 2px 8px rgba(0,0,0,0.5),
        inset 0 2px 6px rgba(0,0,0,0.4),
        inset 0 -1px 0 rgba(255,255,255,0.1);
}

.cover-play-btn .play-icon {
    font-size: 28px;
    display: inline-block;
    filter: drop-shadow(0 2px 6px rgba(0,0,0,0.5));
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.cover-play-btn:hover .play-icon {
    transform: scale(1.3) translateX(3px);
    filter: drop-shadow(0 2px 10px rgba(80,160,255,0.5));
}

/* Item count badge */
.cover-item-count {
    margin-top: 16px;
    font-size: 14px;
    color: var(--text-muted);
}

/* Reply button on ending page — secondary style */
.cover-reply-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 16px;
    padding: 12px 36px;
    border-radius: 10px;
    border: 1px solid var(--accent-subtle);
    background: var(--accent-tint);
    color: var(--text-primary);
    font-size: clamp(14px, 2vw, 17px);
    font-weight: 600;
    cursor: pointer;
    letter-spacing: 0.5px;
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.cover-reply-btn .play-icon {
    font-size: 20px;
}

.cover-reply-btn:hover {
    transform: scale(1.05);
    background: var(--accent-border);
    border-color: var(--accent-border-strong);
}

.cover-reply-btn:active {
    transform: scale(0.96);
}

/* ===== CHANNEL INFO ===== */
.cover-channel-info {
    margin-top: 28px;
    padding: 14px 28px;
    border-radius: 12px;
    background: var(--accent-tint);
    border: 1px solid var(--accent-subtle);
    text-align: center;
}

.cover-channel-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-accent);
    margin-bottom: 4px;
}

.cover-channel-name {
    font-size: clamp(15px, 2.5vw, 20px);
    font-weight: 600;
    color: var(--text-heading);
}

/* ===== NEXT/PREV VEAM NAVIGATION ===== */
.cover-veam-nav {
    display: flex;
    gap: 16px;
    margin-top: 28px;
    max-width: 90vw;
    flex-wrap: wrap;
    justify-content: center;
}

.cover-veam-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 14px 24px;
    border-radius: 14px;
    border: 1px solid var(--accent-border);
    background: linear-gradient(135deg, var(--accent-tint) 0%, var(--accent-subtle) 100%);
    color: var(--text-primary);
    cursor: pointer;
    overflow: hidden;
    text-align: left;
    min-width: 160px;
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), background 0.3s, border-color 0.3s, box-shadow 0.3s;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.cover-veam-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(
        135deg,
        rgba(255,255,255,0.12) 0%,
        transparent 40%,
        rgba(255,255,255,0.04) 100%
    );
    pointer-events: none;
}

.cover-veam-btn:hover {
    background: linear-gradient(135deg, var(--accent-subtle) 0%, var(--accent-glow) 100%);
    border-color: var(--accent-border-strong);
    transform: scale(1.05);
    box-shadow: 0 0 20px var(--accent-glow), 0 4px 16px var(--accent-glow), inset 0 1px 0 rgba(255,255,255,0.1);
}

.cover-veam-btn:active {
    transform: scale(0.96);
    transition-duration: 0.1s;
}

.cover-veam-btn-arrow {
    font-size: 20px;
    color: var(--text-accent);
    flex-shrink: 0;
}

.cover-veam-btn-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.cover-veam-btn-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-accent);
}

.cover-veam-btn-title {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 200px;
}

.cover-veam-next .cover-veam-btn-text {
    text-align: right;
}

/* ===== NEXT ARROW BUTTON (ending page, bottom-right) ===== */
.cover-next-arrow {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1px solid var(--border-subtle);
    background: rgba(255,255,255,0.08);
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
    z-index: 100;
}
.cover-next-arrow:hover {
    background: rgba(255,255,255,0.15);
    color: var(--text-primary);
    border-color: var(--border-accent);
}
.cover-next-arrow:active {
    transform: scale(0.93);
}
.cover-next-arrow svg {
    width: 22px;
    height: 22px;
}

/* ===== ENDING PAGE VARIANT ===== */
.cover-page-ending .cover-thumbnail {
    max-height: 35vh;
    opacity: 0.85;
}

/* ===== INFO BUTTON (bottom-right) ===== */
.info-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--border-subtle);
    background: var(--info-btn-bg);
    color: var(--text-muted);
    font-size: 18px;
    font-weight: 700;
    font-style: italic;
    font-family: Georgia, 'Times New Roman', serif;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s;
    z-index: 100;
}

.info-btn:hover {
    background: var(--info-btn-hover);
    color: var(--text-primary);
}

/* ===== DATA SHEET OVERLAY ===== */
.datasheet-overlay {
    position: fixed;
    inset: 0;
    background: var(--bg-primary);
    z-index: 200;
    overflow-y: auto;
    display: none;
}

.datasheet-overlay.active {
    display: block;
}

.datasheet-header {
    background: var(--bg-header);
    border-bottom: 1px solid var(--border-accent);
    padding: 16px 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    position: sticky;
    top: 0;
    z-index: 10;
}

.datasheet-header h2 {
    font-size: 18px;
    font-weight: 500;
    opacity: 0.8;
    letter-spacing: 0.5px;
    flex: 1;
}

.datasheet-close {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid var(--border-subtle);
    background: rgba(255,255,255,0.05);
    color: var(--text-muted);
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.datasheet-close:hover {
    background: rgba(255,255,255,0.1);
    color: var(--text-primary);
}

.datasheet-body {
    max-width: 960px;
    margin: 0 auto;
    padding: 32px;
}

/* ===== DATA SHEET SECTIONS (shared with datasheet.js) ===== */
.section {
    margin-bottom: 28px;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    overflow: hidden;
}

.section-title {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-accent);
    padding: 14px 20px 10px;
    background: rgba(255,255,255,0.02);
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.section-body {
    padding: 16px 20px;
}

.field {
    display: flex;
    padding: 6px 0;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}
.field:last-child { border-bottom: none; }

.field-label {
    width: 160px;
    flex-shrink: 0;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding-top: 2px;
}

.field-value {
    font-size: 14px;
    line-height: 1.5;
    word-break: break-word;
    color: #d0d0dc;
}

.field-value.subject {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-heading);
}

.field-value a {
    color: var(--link-color);
    text-decoration: none;
}
.field-value a:hover { text-decoration: underline; }

.thumb-img {
    max-width: 320px;
    max-height: 200px;
    border-radius: 6px;
    margin-top: 4px;
}

.avatar-img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 10px;
    vertical-align: middle;
}

.item-card {
    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 6px;
    padding: 14px 18px;
    margin-bottom: 10px;
}
.item-card:last-child { margin-bottom: 0; }

.item-name {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 6px;
    color: #e8e8f0;
}

.item-detail {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 3px;
}

.item-thumb {
    max-width: 200px;
    max-height: 120px;
    border-radius: 4px;
    margin-top: 8px;
}

.badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.badge-video { background: rgba(220,60,60,0.2); color: #ff8080; }
.badge-audio { background: rgba(60,180,60,0.2); color: #80ff80; }
.badge-image { background: rgba(60,120,220,0.2); color: #80b0ff; }
.badge-link  { background: rgba(180,120,60,0.2); color: #ffc080; }
.badge-file  { background: rgba(120,120,120,0.2); color: #b0b0b0; }

.recipient-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.recipient-chip {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    background: rgba(100,130,220,0.15);
    border: 1px solid rgba(100,130,220,0.25);
}

/* ===== LOADING / ERROR STATES ===== */
.loading-state {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 200;
    pointer-events: none;
    background: rgba(10, 10, 20, 0.92);
}

.loading-logo {
    width: 280px;
    max-width: 60vw;
    animation: loading-logo-breathe 2s ease-in-out infinite;
}
@keyframes loading-logo-breathe {
    0%, 100% { opacity: 0.7; transform: scale(1); }
    50%      { opacity: 1;   transform: scale(1.04); }
}

.error-state {
    text-align: center;
    padding: 80px 32px;
    color: #ff6b6b;
}

/* ===== PLAYBACK VIEWPORT ===== */
.veam-playback {
    position: fixed;
    inset: 0;
    top: 0;
    background: var(--bg-primary);
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
}

.veam-content {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

/* --- Navigation Buttons — frosted glass with glow rings --- */
.veam-nav-prev, .veam-nav-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, var(--accent-1) 0%, var(--accent-3) 100%);
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 60;
    overflow: hidden;
    text-shadow: 0 2px 8px rgba(0,0,0,0.7);
    box-shadow:
        0 0 20px var(--accent-tint),
        0 4px 15px rgba(0,0,0,0.4),
        inset 0 1px 0 rgba(255,255,255,0.12);
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease, background 0.3s;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* Glass overlay for nav */
.veam-nav-prev::before, .veam-nav-next::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: linear-gradient(
        135deg,
        rgba(255,255,255,0.22) 0%,
        transparent 40%,
        rgba(255,255,255,0.06) 60%,
        transparent 100%
    );
    pointer-events: none;
}

/* Glow border ring for nav */
.veam-nav-prev::after, .veam-nav-next::after {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 50%;
    border: 1.5px solid var(--accent-subtle);
    pointer-events: none;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.veam-nav-prev { left: 20px; }
.veam-nav-next { right: 20px; }

.veam-nav-prev:hover, .veam-nav-next:hover {
    transform: translateY(-50%) scale(1.15);
    box-shadow:
        0 0 35px var(--accent-glow),
        0 6px 20px rgba(0,0,0,0.5),
        inset 0 1px 0 rgba(255,255,255,0.15);
    background: linear-gradient(135deg, var(--accent-2) 0%, var(--accent-4) 100%);
}

.veam-nav-prev:hover::after, .veam-nav-next:hover::after {
    border-color: var(--accent-border-strong);
    box-shadow: 0 0 12px var(--accent-glow);
}

.veam-nav-prev:active, .veam-nav-next:active {
    transform: translateY(-50%) scale(0.9);
    transition-duration: 0.1s;
}

/* --- Stop/Close — glass circle with red hover + rotation --- */
.veam-nav-stop {
    position: absolute;
    top: 16px;
    right: 20px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, var(--accent-1) 0%, var(--accent-2) 100%);
    color: rgba(255,255,255,0.65);
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 60;
    overflow: hidden;
    box-shadow:
        0 0 15px rgba(0,0,0,0.3),
        0 2px 10px rgba(0,0,0,0.3),
        inset 0 1px 0 rgba(255,255,255,0.1);
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s, background 0.3s, color 0.3s;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* Glass overlay for stop */
.veam-nav-stop::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: linear-gradient(
        135deg,
        rgba(255,255,255,0.18) 0%,
        transparent 45%,
        rgba(255,255,255,0.05) 100%
    );
    pointer-events: none;
}

/* Glow ring for stop */
.veam-nav-stop::after {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 50%;
    border: 1.5px solid rgba(255,255,255,0.12);
    pointer-events: none;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.veam-nav-stop:hover {
    background: linear-gradient(135deg, rgba(130,25,25,0.9) 0%, rgba(170,35,35,0.9) 100%);
    color: #fff;
    transform: scale(1.12) rotate(90deg);
    box-shadow:
        0 0 30px rgba(220,60,60,0.4),
        0 4px 15px rgba(0,0,0,0.4),
        inset 0 1px 0 rgba(255,255,255,0.1);
}

.veam-nav-stop:hover::after {
    border-color: rgba(255,80,80,0.5);
    box-shadow: 0 0 10px rgba(255,80,80,0.3);
}

.veam-nav-stop:active {
    transform: scale(0.88) rotate(90deg);
    transition-duration: 0.1s;
}

.veam-item-counter {
    position: absolute;
    bottom: 56px;
    left: 50%;
    transform: translateX(-50%);
    font-size: clamp(18px, 3.5vw, 26px);
    font-weight: 600;
    color: #fff;
    background: rgba(0,0,0,0.7);
    padding: 8px 20px;
    border-radius: 6px;
    z-index: 60;
}

/* ===== STREAMING SOURCE INDICATOR ===== */
.veam-stream-indicator {
    position: absolute;
    top: 18px;
    left: 20px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    padding: 5px 14px;
    border-radius: 14px;
    z-index: 60;
    opacity: 0.7;
    transition: opacity 0.3s;
    pointer-events: none;
}
.veam-stream-indicator:hover { opacity: 1; }
.veam-stream-local {
    color: #80ffb0;
    background: rgba(40,120,70,0.35);
    border: 1px solid rgba(80,200,120,0.3);
}
.veam-stream-cloud {
    color: #80c0ff;
    background: rgba(40,80,140,0.35);
    border: 1px solid rgba(80,140,220,0.3);
}
.veam-stream-external {
    color: #ffc080;
    background: rgba(140,90,30,0.35);
    border: 1px solid rgba(220,150,60,0.3);
}

/* ===== COUNTDOWN TIMER (image auto-advance) ===== */
.veam-countdown {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 20px;
    border-radius: 20px;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,0.1);
    cursor: pointer;
    z-index: 60;
    transition: background 0.3s, border-color 0.3s, transform 0.2s;
    user-select: none;
}

.veam-countdown:hover {
    background: rgba(0,0,0,0.75);
    border-color: rgba(255,255,255,0.2);
    transform: translateX(-50%) scale(1.05);
}

.veam-countdown:active {
    transform: translateX(-50%) scale(0.95);
}

.veam-countdown-ring {
    position: relative;
    width: 28px;
    height: 28px;
    flex-shrink: 0;
}

.veam-countdown-ring svg {
    width: 28px;
    height: 28px;
    transform: rotate(-90deg);
}

.veam-countdown-ring-bg {
    fill: none;
    stroke: rgba(255,255,255,0.12);
    stroke-width: 3;
}

.veam-countdown-ring-fill {
    fill: none;
    stroke: rgba(100,130,220,0.8);
    stroke-width: 3;
    stroke-linecap: round;
    transition: stroke-dashoffset 1s linear;
}

.veam-countdown-seconds {
    font-size: 14px;
    font-weight: 600;
    color: rgba(255,255,255,0.7);
    min-width: 20px;
    text-align: center;
}

.veam-countdown-label {
    font-size: 11px;
    color: rgba(255,255,255,0.4);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.veam-countdown-paused .veam-countdown-ring-fill {
    stroke: rgba(255,180,60,0.8);
}

.veam-countdown-paused .veam-countdown-seconds {
    color: rgba(255,180,60,0.8);
}

.veam-countdown-paused .veam-countdown-label {
    color: rgba(255,180,60,0.6);
}

/* ===== TEMPLATES ===== */
.veam-template {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0;
    position: absolute;
    inset: 0;
}

.veam-item-title {
    display: none;
}

.veam-item-desc {
    font-size: clamp(13px, 2vw, 16px);
    color: rgba(255,255,255,0.75);
    text-align: center;
    max-width: 80vw;
    padding: 6px 14px;
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.6);
    border-radius: 6px;
    line-height: 1.4;
    z-index: 5;
}

/* --- Video --- */
.veam-template-video .veam-video,
.veam-template-video .veam-video-frame {
    object-fit: contain;
    background: #000;
    position: absolute;
    inset: 52px 0 80px 0;
    width: 100%;
    height: calc(100% - 52px - 80px);
    cursor: pointer;
}
.veam-template-video .veam-video-frame {
    border: none;
}

/* --- Video Play Overlay (shown when paused) --- */
.veam-video-play-overlay {
    display: none;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    width: 100px;
    height: 100px;
    border-radius: 10px;
    border: none;
    background: linear-gradient(135deg, #0D47A1 0%, #1565C0 25%, #42A5F5 50%, #1565C0 75%, #0D47A1 100%);
    color: #fff;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow:
        0 0 24px rgba(13,71,161,0.5),
        0 4px 16px rgba(0,0,0,0.3),
        inset 0 1px 0 rgba(255,255,255,0.12);
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.35s ease;
    animation: play-glow-breathe 3s ease-in-out infinite;
}

.veam-video-play-overlay.visible {
    display: flex;
}

/* YouTube overlay — fully opaque */
.veam-video-play-overlay.veam-yt-overlay {
    opacity: 1;
}

/* Non-YouTube overlay — semi-transparent */
.veam-video-play-overlay:not(.veam-yt-overlay) {
    opacity: 0.85;
}

/* Glass overlay */
.veam-video-play-overlay::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 10px;
    background: linear-gradient(
        125deg,
        rgba(255,255,255,0.3) 0%,
        transparent 30%,
        rgba(255,255,255,0.1) 50%,
        transparent 70%,
        rgba(255,255,255,0.2) 100%
    );
    pointer-events: none;
}

/* Glow ring */
.veam-video-play-overlay::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 12px;
    border: 2px solid rgba(66,165,245,0.4);
    pointer-events: none;
    animation: play-ring-breathe 3s ease-in-out infinite;
}

.veam-video-play-overlay:hover {
    transform: translate(-50%, -50%) scale(1.12);
    box-shadow:
        0 0 60px rgba(30,80,180,0.6),
        0 8px 40px rgba(0,0,0,0.5),
        inset 0 1px 0 rgba(255,255,255,0.2);
}

.veam-video-play-overlay:active {
    transform: translate(-50%, -50%) scale(0.92);
    transition-duration: 0.1s;
}

.veam-video-play-icon {
    font-size: 42px;
    display: inline-block;
    filter: drop-shadow(0 2px 10px rgba(0,0,0,0.7));
    margin-left: 6px; /* optical centering for triangle */
}

/* --- Video Pause Overlay (shown on mousemove when playing) --- */
.veam-video-pause-overlay {
    display: none;
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, rgba(4,10,30,0.9) 0%, rgba(12,40,100,0.88) 50%, rgba(6,18,48,0.9) 100%);
    color: rgba(255,255,255,0.9);
    cursor: pointer;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow:
        0 0 20px rgba(30,80,180,0.25),
        0 4px 15px rgba(0,0,0,0.4),
        inset 0 1px 0 rgba(255,255,255,0.12);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s, opacity 0.4s;
    opacity: 0;
}

.veam-video-pause-overlay.visible {
    display: flex;
    opacity: 1;
}

/* Glass overlay */
.veam-video-pause-overlay::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: linear-gradient(
        135deg,
        rgba(255,255,255,0.2) 0%,
        transparent 40%,
        rgba(255,255,255,0.06) 100%
    );
    pointer-events: none;
}

/* Glow ring */
.veam-video-pause-overlay::after {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 50%;
    border: 1.5px solid rgba(60,120,220,0.2);
    pointer-events: none;
    transition: border-color 0.3s;
}

.veam-video-pause-overlay:hover {
    transform: translateX(-50%) scale(1.15);
    box-shadow:
        0 0 35px rgba(30,80,180,0.4),
        0 6px 20px rgba(0,0,0,0.5),
        inset 0 1px 0 rgba(255,255,255,0.15);
}

.veam-video-pause-overlay:hover::after {
    border-color: rgba(60,120,220,0.5);
}

.veam-video-pause-overlay:active {
    transform: translateX(-50%) scale(0.9);
    transition-duration: 0.1s;
}

.veam-video-pause-icon {
    font-size: 22px;
    letter-spacing: 3px;
    filter: drop-shadow(0 2px 6px rgba(0,0,0,0.6));
}

/* --- Audio (immersive circular visualizer) --- */
.veam-template-audio {
    gap: 0;
    padding: 0;
    position: relative;
    overflow: hidden;
}

/* Blurred backdrop from album art */
.veam-audio-backdrop {
    position: absolute;
    inset: -50px;
    background-size: cover;
    background-position: center;
    filter: blur(60px) saturate(1.6) brightness(0.32);
    z-index: 0;
    animation: veam-audio-backdrop-drift 25s ease-in-out infinite alternate;
}
@keyframes veam-audio-backdrop-drift {
    0% { transform: scale(1.1) rotate(-1deg); }
    100% { transform: scale(1.25) rotate(1.5deg); }
}
.veam-audio-backdrop-overlay {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, rgba(8,8,28,0.15) 0%, rgba(5,5,18,0.9) 100%);
    z-index: 1;
}

/* Full-screen canvas for circular visualizer + particles */
.veam-audio-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}
.veam-audio-paused .veam-audio-canvas {
    opacity: 0.35;
    transition: opacity 0.4s ease;
}
.veam-audio-playing .veam-audio-canvas {
    opacity: 1;
    transition: opacity 0.4s ease;
}

/* Content layer above canvas */
.veam-audio-content {
    position: relative;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    padding: 28px 24px;
    width: 100%;
    height: 100%;
    box-sizing: border-box;
}

/* "NOW PLAYING" label */
.veam-audio-now-playing {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 4px;
    color: rgba(160,140,255,0.65);
    text-transform: uppercase;
    text-shadow: 0 0 18px rgba(140,120,255,0.35);
    margin-bottom: 2px;
}

/* Circular album art ring */
.veam-audio-art-ring {
    position: relative;
    width: min(44vw, 44vh);
    height: min(44vw, 44vh);
    max-width: 240px;
    max-height: 240px;
    flex-shrink: 0;
    border-radius: 50%;
    cursor: pointer;
}

/* Glow ring behind art (pulses with music) */
.veam-audio-ring-glow {
    position: absolute;
    inset: -14px;
    border-radius: 50%;
    border: 2px solid transparent;
    z-index: 0;
    transition: all 0.4s ease;
}
.veam-audio-playing .veam-audio-ring-glow {
    border-color: rgba(120,100,255,0.25);
    box-shadow:
        0 0 35px rgba(120,100,255,0.18),
        0 0 80px rgba(120,100,255,0.08),
        inset 0 0 25px rgba(120,100,255,0.06);
    animation: veam-ring-pulse 2.5s ease-in-out infinite;
}
@keyframes veam-ring-pulse {
    0%, 100% {
        box-shadow: 0 0 35px rgba(120,100,255,0.18), 0 0 80px rgba(120,100,255,0.08);
        border-color: rgba(120,100,255,0.25);
    }
    50% {
        box-shadow: 0 0 55px rgba(120,100,255,0.3), 0 0 100px rgba(120,100,255,0.15);
        border-color: rgba(140,120,255,0.45);
    }
}

/* Circular album art image */
.veam-audio-art {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 8px 40px rgba(0,0,0,0.55);
    transition: filter 0.3s ease;
}
.veam-audio-playing .veam-audio-art {
    animation: veam-art-spin 50s linear infinite;
}
.veam-audio-paused .veam-audio-art {
    animation-play-state: paused;
}
@keyframes veam-art-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}
.veam-audio-art-ring:hover .veam-audio-art {
    filter: brightness(1.12);
}

/* Placeholder when no thumbnail */
.veam-audio-art-placeholder {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(80,60,180,0.22) 0%, rgba(40,30,100,0.12) 100%);
    border: 1px solid rgba(120,100,255,0.18);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: min(14vw, 68px);
    color: rgba(160,140,255,0.55);
    box-shadow: 0 8px 40px rgba(0,0,0,0.55);
    animation: veam-placeholder-breathe 4s ease-in-out infinite;
}
@keyframes veam-placeholder-breathe {
    0%, 100% { background: linear-gradient(135deg, rgba(80,60,180,0.22) 0%, rgba(40,30,100,0.12) 100%); }
    50% { background: linear-gradient(135deg, rgba(100,80,200,0.32) 0%, rgba(60,50,140,0.22) 100%); }
}

/* Track info */
.veam-audio-title {
    font-size: 20px;
    font-weight: 600;
    color: #fff;
    text-align: center;
    max-width: 90%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    letter-spacing: 0.3px;
    text-shadow: 0 2px 12px rgba(0,0,0,0.45);
}
.veam-audio-desc {
    font-size: 13px;
    color: rgba(255,255,255,0.5);
    text-align: center;
    max-width: 90%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-top: -6px;
}

/* Controls: prev, play/pause, next */
.veam-audio-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 22px;
    margin-top: 6px;
}

.veam-audio-play-btn {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.18);
    background: rgba(120,100,255,0.22);
    color: #fff;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(120,100,255,0.18);
}
.veam-audio-play-btn:hover {
    background: rgba(120,100,255,0.4);
    border-color: rgba(255,255,255,0.3);
    transform: scale(1.1);
    box-shadow: 0 4px 30px rgba(120,100,255,0.35);
}
.veam-audio-play-btn:active {
    transform: scale(0.94);
}

.veam-audio-play-icon {
    line-height: 1;
    margin-left: 1px;
}

.veam-audio-skip-btn {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.05);
    color: rgba(255,255,255,0.65);
    font-size: 15px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}
.veam-audio-skip-btn:hover {
    background: rgba(255,255,255,0.1);
    border-color: rgba(255,255,255,0.22);
    color: #fff;
    transform: scale(1.08);
}
.veam-audio-skip-btn:active {
    transform: scale(0.9);
}

/* Progress bar */
.veam-audio-progress-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 88%;
    max-width: 380px;
}

.veam-audio-time {
    font-size: 11px;
    color: rgba(255,255,255,0.4);
    font-variant-numeric: tabular-nums;
    flex-shrink: 0;
    min-width: 32px;
    text-align: center;
}

.veam-audio-progress {
    flex: 1;
    height: 4px;
    background: rgba(255,255,255,0.08);
    border-radius: 2px;
    cursor: pointer;
    position: relative;
    overflow: visible;
    transition: height 0.15s ease;
}
.veam-audio-progress:hover {
    height: 6px;
}

.veam-audio-progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, rgba(100,130,255,0.65) 0%, rgba(170,120,255,0.95) 100%);
    border-radius: 2px;
    transition: width 0.1s linear;
    position: relative;
}

.veam-audio-progress-glow {
    position: absolute;
    top: 50%;
    left: 0%;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(150,130,255,0.9);
    transform: translate(-50%, -50%);
    box-shadow: 0 0 12px rgba(140,120,255,0.55);
    opacity: 0;
    transition: opacity 0.2s ease, left 0.1s linear;
}
.veam-audio-progress:hover .veam-audio-progress-glow {
    opacity: 1;
}

/* Hidden native audio element */
#veam-audio-el {
    position: absolute;
    width: 0;
    height: 0;
    opacity: 0;
    pointer-events: none;
}

/* --- Image --- */
.veam-template-image .veam-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    position: absolute;
    inset: 0;
}

/* --- Link (preview card — never iframe) --- */
.veam-template-link {
    justify-content: center;
    padding: 5vw;
}
.veam-link-card {
    display: flex;
    flex-direction: column;
    max-width: 560px;
    width: 100%;
    border-radius: 14px;
    overflow: hidden;
    background: var(--bg-secondary, rgba(255,255,255,0.06));
    box-shadow: 0 4px 24px rgba(0,0,0,0.35);
}
.veam-link-thumb-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: rgba(0,0,0,0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
.veam-link-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.veam-link-thumb-wrap.veam-link-thumb-err .veam-link-thumb { display: none; }
.veam-link-thumb-wrap.veam-link-thumb-err::after,
.veam-link-thumb-placeholder::after {
    content: '\1F310'; /* globe */
    font-size: min(18vw, 80px);
    opacity: 0.35;
}
.veam-link-thumb-placeholder .veam-link-globe { display: none; }
.veam-link-info {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 18px 20px 20px;
}
.veam-link-title {
    font-size: clamp(16px, 3vw, 22px);
    font-weight: 600;
    color: var(--text-heading, #fff);
    line-height: 1.3;
}
.veam-link-desc {
    font-size: clamp(13px, 2vw, 15px);
    color: var(--text-muted, rgba(255,255,255,0.65));
    line-height: 1.45;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.veam-link-url {
    font-size: 12px;
    color: var(--text-muted, rgba(255,255,255,0.45));
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 2px;
}
.veam-link-actions {
    display: flex;
    gap: 10px;
    margin-top: 12px;
    flex-wrap: wrap;
    align-items: center;
}
.veam-link-open {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 8px 18px;
    border-radius: 8px;
    background: var(--accent, #6c63ff);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    box-shadow: 0 2px 10px var(--accent-glow, rgba(108,99,255,0.35));
    transition: transform 0.2s, box-shadow 0.2s;
}
.veam-link-open:hover {
    transform: scale(1.04);
    box-shadow: 0 0 20px var(--accent-glow, rgba(108,99,255,0.5));
}
.veam-link-open:active { transform: scale(0.96); }
.veam-link-btn {
    background: none;
    border: 1px solid var(--border-subtle, rgba(255,255,255,0.18));
    color: var(--text-muted, rgba(255,255,255,0.7));
    font-size: 13px;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
}
.veam-link-btn:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.35);
    color: #fff;
}
.veam-template-link .veam-item-title,
.veam-template-link .veam-item-desc { display: none; }

/* --- File --- */
.veam-template-file {
    gap: 16px;
    padding: 5vw;
}
.veam-file-icon {
    font-size: min(20vw, 120px);
    opacity: 0.5;
}
.veam-template-file .veam-item-title {
    display: block;
    position: static;
    transform: none;
    background: none;
    left: auto;
    bottom: auto;
    font-size: clamp(18px, 4vw, 28px);
}
.veam-template-file .veam-item-desc {
    position: static;
    transform: none;
    background: none;
    left: auto;
    bottom: auto;
}
.veam-file-size {
    font-size: 15px;
    color: var(--text-muted);
}
.veam-file-download {
    position: relative;
    display: inline-block;
    margin-top: 16px;
    padding: 14px 40px;
    border-radius: 28px;
    background: linear-gradient(135deg, var(--accent-2) 0%, var(--accent-4) 50%, var(--accent-3) 100%);
    border: none;
    color: var(--text-heading);
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    overflow: hidden;
    box-shadow:
        0 0 20px var(--accent-glow),
        0 4px 15px rgba(0,0,0,0.3),
        inset 0 1px 0 rgba(255,255,255,0.12);
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s;
}
.veam-file-download::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(125deg, rgba(255,255,255,0.22) 0%, transparent 35%, rgba(255,255,255,0.08) 50%, transparent 100%);
    pointer-events: none;
}
.veam-file-download:hover {
    transform: scale(1.06);
    box-shadow:
        0 0 35px var(--accent-glow),
        0 6px 20px rgba(0,0,0,0.4),
        inset 0 1px 0 rgba(255,255,255,0.15);
}
.veam-file-download:active { transform: scale(0.95); transition-duration: 0.1s; }

/* ===== PANELS ===== */
.veam-panel {
    position: absolute;
    z-index: 55;
}
.veam-panel-header {
    top: 0;
    left: 0;
    right: 0;
    padding: 10px 20px;
    background: linear-gradient(180deg, rgba(0,0,0,0.7) 0%, transparent 100%);
    color: var(--text-heading);
    font-size: 14px;
}
.veam-panel-footer {
    bottom: 40px;
    left: 0;
    right: 0;
    padding: 10px 20px;
    background: linear-gradient(0deg, rgba(0,0,0,0.7) 0%, transparent 100%);
    color: var(--text-primary);
    font-size: 13px;
    text-align: center;
}
.veam-panel-marquee {
    bottom: 0;
    left: 0;
    right: 0;
    height: 32px;
    overflow: hidden;
    background: rgba(0,0,0,0.8);
    border-top: 1px solid var(--border-accent);
}
.marquee-track {
    display: inline-block;
    white-space: nowrap;
    animation: marquee-scroll linear infinite;
    padding-left: 100%;
}
@keyframes marquee-scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-100%); }
}
.marquee-text {
    font-size: 13px;
    color: var(--text-primary);
    line-height: 32px;
}
.veam-panel-ad {
    top: 50%;
    transform: translateY(-50%);
    width: 120px;
    min-height: 200px;
    background: rgba(0,0,0,0.4);
    border: 1px solid var(--border-subtle);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 11px;
}
.veam-panel-ad-left { left: 8px; }
.veam-panel-ad-right { right: 8px; }

/* ===== BUTTON KEYFRAMES ===== */
@keyframes play-glow-breathe {
    0%, 100% {
        box-shadow:
            0 0 30px var(--accent-glow),
            0 6px 24px var(--accent-glow),
            0 2px 6px rgba(0,0,0,0.4),
            inset 0 1px 0 rgba(255,255,255,0.3),
            inset 0 -1px 0 rgba(0,0,0,0.2);
    }
    50% {
        box-shadow:
            0 0 50px var(--accent-glow-strong),
            0 6px 30px var(--accent-glow-strong),
            0 2px 6px rgba(0,0,0,0.4),
            inset 0 1px 0 rgba(255,255,255,0.35),
            inset 0 -1px 0 rgba(0,0,0,0.15);
    }
}

@keyframes play-ring-breathe {
    0%, 100% { border-color: var(--accent-border); }
    50% { border-color: var(--accent-border-strong); }
}

@keyframes glass-flash {
    0% { opacity: 1; }
    40% { opacity: 0.3; }
    100% { opacity: 1; }
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .header-menu { display: none; }
    .mobile-menu-trigger { display: flex; align-items: center; justify-content: center; }
}

@media (max-width: 640px) {
    .player-header {
        height: 42px;
        padding: 0 10px;
    }
    .header-left {
        gap: 8px;
        margin-left: 6px;
    }
    .header-logo { height: 18px; }
    .header-profile {
        margin-left: 12px;
        margin-right: 12px;
        padding: 4px 10px 4px 6px;
    }
    .header-profile-avatar {
        width: 28px;
        height: 28px;
    }
    .header-profile-name {
        font-size: 13px;
        max-width: 100px;
    }
    .header-profile-email { display: none; }
    .nav-loader-logo { width: 180px; }
    .menu-btn {
        font-size: 12px;
        padding: 6px 10px;
    }
    .player-header.visible ~ .cover-page {
        padding-top: calc(42px + 3vw);
    }
    .player-header.visible ~ .veam-playback {
        top: 42px;
    }
    .menu-panel { top: 42px; }
    .menu-panel-body {
        padding: 12px 0;
        max-height: calc(100vh - 42px);
    }
    .bottom-bar { padding: 10px 16px; }
    .bottom-subject { max-width: 40vw; font-size: 16px; }
    .bottom-description { max-width: 40vw; }
    .bottom-avatar { width: 38px; height: 38px; }
    .cover-page {
        padding: 3vw;
        justify-content: flex-start;
        padding-top: 4vh;
    }
    .cover-thumbnail {
        max-height: 35vh;
    }
    .cover-play-btn {
        padding: 18px 44px;
        min-width: 180px;
    }
    .cover-reply-btn {
        padding: 10px 28px;
    }
    .field {
        flex-direction: column;
    }
    .field-label {
        width: auto;
        margin-bottom: 2px;
    }
    .datasheet-body {
        padding: 16px;
    }
    .veam-nav-prev, .veam-nav-next {
        width: 48px;
        height: 48px;
        font-size: 20px;
    }
    .veam-nav-prev { left: 10px; }
    .veam-nav-next { right: 10px; }
    .veam-nav-stop { width: 38px; height: 38px; }
    .veam-panel-ad { display: none; }
    .veam-video-play-overlay { width: 80px; height: 80px; }
    .veam-video-play-icon { font-size: 34px; margin-left: 4px; }
    .veam-video-pause-overlay { width: 50px; height: 50px; bottom: 30px; }
    .veam-video-pause-icon { font-size: 18px; }
    .veam-template-audio { padding: 0; }
    .veam-audio-card { padding: 24px 16px 20px; max-width: 360px; }
    .veam-audio-art-wrap { max-width: 240px; max-height: 240px; }
    .veam-audio-visualizer { height: 40px; }
    .veam-audio-title { font-size: 15px; }
    .veam-audio-desc { font-size: 12px; }
    .veam-template-file { padding: 8vw 5vw; }
    .veam-template-link { padding: 3vw; }
    .cover-veam-nav { flex-direction: column; align-items: stretch; }
    .cover-veam-btn { min-width: 0; }
    .cover-veam-btn-title { max-width: 50vw; }
    .cover-veam-next .cover-veam-btn-text { text-align: left; }
}

@media (max-width: 360px) {
    .cover-page { padding: 2vw; }
    .cover-thumbnail-placeholder { height: 30vh; }
    .veam-nav-prev, .veam-nav-next {
        width: 42px;
        height: 42px;
    }
    .veam-nav-stop { width: 34px; height: 34px; font-size: 15px; }
    .menu-btn { font-size: 11px; padding: 5px 7px; }
    .bottom-bar { display: none !important; }
}


/* ===========================================================
   PANEL STYLES — VeamcastPlayerCSHTML theme recreation
   =========================================================== */

/* ── Veamcast Color Palette ─────────────────────────────── */
:root {
    --vc-blue-metal: linear-gradient(135deg, #183466 0%, #183488 100%);
    --vc-button-brush: linear-gradient(to bottom, #000000, #183488, #000000);
    --vc-silver-brush: linear-gradient(135deg, #000 0%, #888 25%, #343434 40%, #000 55%, #aaa 75%, #000 85%, #888 100%);
    --vc-selected-tab: linear-gradient(to right, #888888, #183466, #888888);
    --vc-playlist-item: linear-gradient(135deg, rgba(0,0,0,0.53), rgba(24,52,136,0.67), rgba(170,170,170,0.53));
    --vc-text-primary: #ffffff;
    --vc-text-muted: #aaaaaa;
    --vc-text-dim: #666666;
    --vc-text-accent: #ddcc44;
    --vc-text-link: #aaccff;
}

/* ── Shared Components ──────────────────────────────────── */

.vc-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255,255,255,0.15);
    border-top-color: rgba(100,130,220,0.7);
    border-radius: 50%;
    animation: veamcast-spin-slow 1s linear infinite;
}

/* Ship's wheel loader (replaces plain spinner in panels) */
.vc-wheel-loader {
    width: 110vmin;
    height: 110vmin;
    opacity: 0.08;
    animation: veamcast-spin-slow 6s linear infinite;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 150;
    pointer-events: none;
}

/* Channel detail: full-screen thumbnail backdrop while loading */
.vc-channel-loading-backdrop {
    position: fixed;
    inset: 0;
    z-index: 180;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
.vc-channel-loading-backdrop-img {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    filter: blur(6px);
    transform: scale(1.05);
}
.vc-channel-loading-backdrop-dim {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.55);
}
.vc-channel-loading-backdrop .vc-wheel-loader {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1;
    width: 110vmin;
    height: 110vmin;
    opacity: 0.08;
}

.vc-btn-primary {
    display: inline-block;
    padding: 12px 32px;
    background: var(--vc-blue-metal);
    color: #fff;
    border: 1px solid rgba(100,130,220,0.3);
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
    transition: opacity 0.2s;
}
.vc-btn-primary:hover { opacity: 0.88; }
.vc-btn-primary:disabled { opacity: 0.5; cursor: default; }

.vc-btn-tile {
    display: block;
    width: 188px;
    height: 48px;
    margin: 6px auto;
    background: var(--vc-blue-metal);
    color: #fff;
    border: 2px solid;
    border-image: var(--vc-silver-brush) 1;
    border-radius: 9px;
    font-size: 18px;
    cursor: pointer;
    text-align: center;
    transition: opacity 0.2s;
}
.vc-btn-tile:hover { opacity: 0.88; }

.vc-user-empty {
    text-align: center;
    padding: 48px 24px;
    color: var(--vc-text-muted);
    font-size: 16px;
}

/* ── Discover Panel ─────────────────────────────────────── */

.vc-discover-search {
    display: flex;
    gap: 8px;
    padding: 8px 18px 12px;
    align-items: center;
    max-width: 320px;
    margin-left: auto;
}
.vc-discover-search-input {
    width: 160px;
    min-width: 0;
    padding: 12px 16px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 8px;
    color: #fff;
    font-size: 16px;
    outline: none;
}
.vc-discover-search-input:focus {
    border-color: rgba(100,130,220,0.5);
    background: rgba(255,255,255,0.09);
}
.vc-discover-search-btn,
.vc-discover-search-clear {
    padding: 12px 18px;
    background: var(--vc-blue-metal);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
}
.vc-discover-search-clear {
    background: rgba(255,255,255,0.1);
}

.vc-discover-search-header {
    padding: 0 18px 12px;
}
.vc-discover-search-term {
    color: #fff;
    font-size: 16px;
    font-weight: bold;
}
.vc-discover-search-count {
    color: var(--vc-text-muted);
    font-size: 13px;
    margin-top: 4px;
}

.vc-discover-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    padding: 0 18px 88px;
    justify-content: flex-start;
}

/* Discover full-width, campaigns wider */
.menu-panel-body:has(.vc-campaigns) {
    max-width: 1200px;
}
/* Discover and channel get full-width treatment */
.menu-panel.discover-active .menu-panel-body {
    max-width: none;
    padding: 16px;
}
.menu-panel.channel-active .menu-panel-body {
    max-width: none;
    padding: 16px;
}

.vc-discover-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 48px;
}

/* ── Channel Card (Desktop) ─────────────────────────────── */

.vc-channel-card {
    width: 288px;
    height: 266px;
    border-radius: 18px;
    overflow: hidden;
    border: 3px solid #000;
    cursor: pointer;
    position: relative;
    flex-shrink: 0;
}
.vc-channel-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
}
.vc-channel-card-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    background-color: #111;
}
/* Default thumbnail for channels without an image */
.vc-channel-card-bg-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0D47A1 0%, #1a1a2e 40%, #16213e 70%, #0f3460 100%);
}
.vc-channel-card-bg-empty::after {
    content: attr(data-initial);
    font-size: 72px;
    font-weight: 700;
    color: rgba(255,255,255,0.12);
    text-transform: uppercase;
    letter-spacing: 4px;
    user-select: none;
}
/* Vary gradient per card position for visual diversity */
.vc-channel-card:nth-child(6n+2) .vc-channel-card-bg-empty {
    background: linear-gradient(160deg, #1b1b2f 0%, #162447 40%, #1f4068 70%, #1b1b2f 100%);
}
.vc-channel-card:nth-child(6n+3) .vc-channel-card-bg-empty {
    background: linear-gradient(120deg, #0a0a23 0%, #1a1a40 35%, #2d132c 70%, #0a0a23 100%);
}
.vc-channel-card:nth-child(6n+4) .vc-channel-card-bg-empty {
    background: linear-gradient(145deg, #141e30 0%, #243b55 45%, #141e30 100%);
}
.vc-channel-card:nth-child(6n+5) .vc-channel-card-bg-empty {
    background: linear-gradient(170deg, #0f0c29 0%, #302b63 50%, #24243e 100%);
}
.vc-channel-card:nth-child(6n+6) .vc-channel-card-bg-empty {
    background: linear-gradient(130deg, #1a1a2e 0%, #0f3460 40%, #e94560 120%);
}
.vc-channel-card-shimmer {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.2);
    animation: channelShimmerCycle 8s ease-in-out infinite;
}
/* Stagger shimmer per card position — varying duration and delay */
.vc-channel-card:nth-child(6n+2) .vc-channel-card-shimmer { animation-duration: 10s; animation-delay: -2s; }
.vc-channel-card:nth-child(6n+3) .vc-channel-card-shimmer { animation-duration: 7s;  animation-delay: -4s; }
.vc-channel-card:nth-child(6n+4) .vc-channel-card-shimmer { animation-duration: 12s; animation-delay: -1s; }
.vc-channel-card:nth-child(6n+5) .vc-channel-card-shimmer { animation-duration: 9s;  animation-delay: -6s; }
.vc-channel-card:nth-child(6n+6) .vc-channel-card-shimmer { animation-duration: 11s; animation-delay: -3s; }
@keyframes channelShimmerCycle {
    0%   { background: rgba(0,0,0,0.05); }
    33%  { background: rgba(255,255,255,0.15); }
    66%  { background: rgba(0,0,0,0.35); }
    100% { background: rgba(0,0,0,0.05); }
}
.vc-channel-card-play {
    position: absolute;
    top: 38%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 68px;
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(13,71,161,0.35) 0%, rgba(21,101,192,0.30) 25%, rgba(66,165,245,0.25) 50%, rgba(21,101,192,0.30) 75%, rgba(13,71,161,0.35) 100%);
    border-radius: 12px;
    opacity: 0;
    transition: opacity 0.25s;
    box-shadow: 0 0 16px rgba(13,71,161,0.25), 0 3px 10px rgba(0,0,0,0.15);
}
.vc-channel-card:hover .vc-channel-card-play { opacity: 0.85; }

.vc-channel-card-bottom {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--vc-button-brush);
    border-radius: 0 0 15px 15px;
    padding: 8px 12px;
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
    align-items: end;
    gap: 2px 10px;
}
.vc-channel-card-name {
    color: #fff;
    font-size: 16px;
    font-weight: bold;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    grid-column: 1;
    grid-row: 1;
    align-self: start;
}
.vc-channel-card-owner {
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    gap: 0;
    margin-top: 0;
    grid-column: 2;
    grid-row: 2;
    text-align: right;
}
.vc-channel-card-owner-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    margin-left: auto;
    margin-inline-start: 8px;
}
.vc-channel-card-owner-name {
    color: #bbb;
    font-size: 14px;
    text-align: right;
}
.vc-channel-card-more {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(to right, rgba(0,0,0,0.53), rgba(255,255,255,0.53), rgba(0,0,0,0.53));
    border: none;
    color: #fff;
    font-size: 18px;
    padding: 2px 12px;
    border-radius: 6px;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.25s;
    z-index: 2;
}
.vc-channel-card:hover .vc-channel-card-more { opacity: 0.8; }

/* ── Channel Card (Mobile) ──────────────────────────────── */

.vc-channel-card-mobile {
    display: flex;
    width: 100%;
    background: var(--vc-button-brush);
    border: 1px solid rgba(255,255,255,0.27);
    border-width: 1px 1px 2px 2px;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
}
.vc-channel-card-mobile-thumb {
    width: 88px;
    min-height: 80px;
    position: relative;
    flex-shrink: 0;
    background: #111;
}
.vc-channel-card-mobile-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.vc-channel-card-mobile-thumb-empty {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0D47A1 0%, #1a1a2e 50%, #16213e 100%);
}
.vc-channel-card-mobile-thumb-empty::after {
    content: attr(data-initial);
    font-size: 32px;
    font-weight: 700;
    color: rgba(255,255,255,0.15);
    text-transform: uppercase;
    user-select: none;
}
.vc-channel-card-mobile-play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    opacity: 0.7;
}
.vc-channel-card-mobile-info {
    padding: 10px 12px;
    flex: 1;
    min-width: 0;
}
.vc-channel-card-mobile-name {
    color: #fff;
    font-size: 20px;
    font-weight: bold;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.vc-channel-card-mobile-owner {
    color: #bbb;
    font-size: 15px;
    margin-top: 2px;
}
.vc-channel-card-mobile-stats {
    color: #999;
    font-size: 14px;
    margin-top: 4px;
}

/* ── Discover empty state ──────────────────────────────── */
.vc-discover-empty {
    text-align: center;
    padding: 48px 24px;
    color: var(--text-muted, rgba(255,255,255,0.45));
}
.vc-discover-empty-icon {
    font-size: 48px;
    margin-bottom: 12px;
    opacity: 0.4;
}
.vc-discover-empty-title {
    font-size: 18px;
    font-weight: 600;
    color: rgba(255,255,255,0.6);
    margin-bottom: 6px;
}
.vc-discover-empty-sub {
    font-size: 14px;
    color: rgba(255,255,255,0.35);
}
html[data-theme="light"] .vc-discover-empty-title { color: rgba(0,0,0,0.5); }
html[data-theme="light"] .vc-discover-empty-sub { color: rgba(0,0,0,0.35); }

/* ── Unsubscribe button on card ─────────────────────────── */

.vc-unsub-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    background: rgba(136,0,0,0.8);
    border: none;
    border-radius: 50%;
    color: #fff;
    font-size: 18px;
    cursor: pointer;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
}
.vc-unsub-btn:hover { background: rgba(200,0,0,0.9); }

/* ── User Panel ─────────────────────────────────────────── */

.vc-user-menu {
    display: flex;
    justify-content: center;
    gap: 0;
    padding: 12px 0;
}
.vc-user-menu-item {
    color: silver;
    font-size: 20px;
    padding: 6px 18px;
    cursor: pointer;
    text-decoration: none;
    transition: color 0.2s;
    white-space: nowrap;
}
.vc-user-menu-item:hover { color: #ddd; }
.vc-user-menu-active {
    color: #fff !important;
    font-weight: bold;
}

.vc-user-menu-combo {
    display: block;
    width: calc(100% - 32px);
    margin: 12px auto;
    padding: 10px 16px;
    background: #000;
    color: #fff;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 6px;
    font-size: 18px;
}

.vc-user-content {
    padding: 0 12px;
}

/* My Account */
.vc-user-account {
    text-align: center;
    max-width: 400px;
    margin: 0 auto;
    padding: 12px 0 48px;
}
.vc-user-account-label {
    color: #fff;
    font-size: 18px;
    margin-bottom: 8px;
}
.vc-user-account-name {
    color: #fff;
    font-size: 34px;
    word-wrap: break-word;
    width: 234px;
    margin: 0 auto;
}
.vc-user-account-email {
    color: #fff;
    font-size: 18px;
    width: 234px;
    margin: 0 auto;
}
.vc-user-account-signup {
    color: #fff;
    font-size: 18px;
    width: 234px;
    margin: 0 auto 12px;
}
.vc-user-account-avatar {
    display: block;
    width: 188px;
    margin: 12px auto;
    border-radius: 6px;
}

.vc-user-download-section {
    margin-top: 34px;
    text-align: center;
}
.vc-user-download-title {
    color: #fff;
    font-size: 18px;
    margin-bottom: 9px;
}
.vc-user-download-feature {
    color: var(--vc-text-muted);
    font-size: 16px;
    margin: 3px;
}
.vc-user-download-btn {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    margin-top: 34px;
    padding: 18px;
    background: var(--vc-button-brush);
    border: 1px solid #fff;
    border-radius: 3px;
    color: #fff;
    text-decoration: none;
    cursor: pointer;
    transition: opacity 0.2s;
}
.vc-user-download-btn:hover { opacity: 0.88; }
.vc-user-download-btn span {
    margin-top: 8px;
    font-size: 14px;
    max-width: 88px;
    text-align: center;
}
.vc-windows-logo {
    display: block;
}

/* Login form */
.vc-user-login {
    text-align: center;
    max-width: 400px;
    margin: 0 auto;
    padding: 48px 24px;
}
.vc-user-login-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}
.vc-user-login-title {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #fff;
}
.vc-user-login-subtitle {
    color: var(--vc-text-muted);
    margin-bottom: 24px;
}
.vc-user-login-email,
.vc-user-login-code {
    display: block;
    width: 100%;
    padding: 12px 16px;
    margin-bottom: 12px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 6px;
    color: #fff;
    font-size: 16px;
    outline: none;
}
.vc-user-login-email:focus,
.vc-user-login-code:focus {
    border-color: rgba(100,130,220,0.4);
}
.vc-user-login-btn,
.vc-user-login-verify {
    display: block;
    width: 100%;
    padding: 12px;
    margin-bottom: 12px;
}
.vc-user-login-status {
    color: var(--vc-text-accent);
    font-size: 14px;
    margin-top: 8px;
}

/* ── Campaigns Panel ────────────────────────────────────── */

.vc-campaigns {
    padding: 0 0 48px;
}
.vc-campaigns-header {
    font-size: 48px;
    color: rgba(255,255,255,0.2);
    text-align: center;
    padding: 18px 0;
    text-shadow: 0 2px 12px rgba(24,52,136,0.4);
}

.vc-campaigns-list {
    max-width: 690px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 0 18px;
}

.vc-campaign-card {
    background: var(--vc-button-brush);
    border: 1px solid #aaa;
    border-width: 1px 1px 2px 2px;
    border-radius: 6px;
    padding: 16px;
    cursor: pointer;
    transition: border-color 0.2s;
    position: relative;
}
.vc-campaign-card:hover {
    border-color: rgba(100,130,220,0.5);
}
.vc-campaign-card-dimmed {
    opacity: 0.6;
}
.vc-campaign-card-dimmed::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(51,68,85,0.27);
    border-radius: 6px;
    pointer-events: none;
}
.vc-campaign-card-inner {
    position: relative;
}

.vc-campaign-eye {
    position: absolute;
    top: 0;
    right: 0;
    opacity: 0.53;
}
.vc-campaign-card-name {
    color: #fff;
    font-size: 22px;
    font-weight: bold;
    margin-bottom: 4px;
    padding-right: 56px;
}
.vc-campaign-card-desc {
    color: var(--vc-text-muted);
    font-size: 16px;
    margin-bottom: 8px;
}
.vc-campaign-card-stats {
    color: var(--vc-text-dim);
    font-size: 14px;
}
.vc-campaign-status-owner {
    color: #fff;
    font-size: 13px;
    margin-top: 4px;
}
.vc-campaign-card-actions {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}
.vc-campaign-action {
    width: 36px;
    height: 36px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}
.vc-campaign-action:hover { background: rgba(255,255,255,0.18); }

.vc-campaign-new {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    height: 88px;
    background: linear-gradient(to right, #000, #222, #000);
    border: 1px dashed rgba(255,255,255,0.2);
    border-radius: 6px;
    cursor: pointer;
    color: #fff;
    font-size: 20px;
    transition: border-color 0.2s;
}
.vc-campaign-new:hover { border-color: rgba(100,130,220,0.5); }

/* Campaign Editor */
.vc-campaign-editor {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 18px 48px;
    position: relative;
}
.vc-campaign-editor-watermark {
    font-size: 48px;
    color: rgba(255,255,255,0.08);
    font-style: italic;
    text-align: center;
    margin-bottom: 12px;
    pointer-events: none;
}
.vc-campaign-editor-actions {
    display: flex;
    gap: 8px;
    margin-bottom: 18px;
    flex-wrap: wrap;
}
.vc-btn-save {
    padding: 8px 24px;
    background: #188834;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
}
.vc-btn-clone {
    padding: 8px 24px;
    background: #1888AA;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
}
.vc-btn-delete {
    padding: 8px 24px;
    background: #880034;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
}
.vc-btn-cancel {
    padding: 8px 24px;
    background: #666;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
}

.vc-campaign-editor-fields {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 18px;
}
.vc-field-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.vc-field-group label {
    color: var(--vc-text-muted);
    font-size: 14px;
}
.vc-field-group input[type="text"],
.vc-field-group textarea {
    padding: 10px 14px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 4px;
    color: #fff;
    font-size: 16px;
    outline: none;
    resize: vertical;
}
.vc-field-group input:focus,
.vc-field-group textarea:focus {
    border-color: rgba(100,130,220,0.4);
}

.vc-campaign-editor-add-btns {
    margin-bottom: 18px;
}
.vc-btn-add-ad {
    padding: 10px 24px;
    background: var(--vc-blue-metal);
    color: #fff;
    border: 1px solid rgba(100,130,220,0.3);
    border-radius: 6px;
    font-size: 15px;
    cursor: pointer;
}

/* Ad Items */
.vc-campaign-ads {
    display: flex;
    flex-direction: column;
    gap: 18px;
}
.vc-ad-item {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    overflow: hidden;
}
.vc-ad-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    background: rgba(255,255,255,0.04);
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
.vc-ad-item-label {
    color: var(--vc-text-muted);
    font-size: 14px;
    font-weight: 600;
}
.vc-ad-item-controls {
    display: flex;
    gap: 4px;
}
.vc-ad-move, .vc-ad-delete {
    width: 28px;
    height: 28px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 4px;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}
.vc-ad-delete { color: #ff6666; }
.vc-ad-move:hover { background: rgba(255,255,255,0.12); }
.vc-ad-delete:hover { background: rgba(136,0,52,0.4); }

/* Ad Tabs */
.vc-ad-tabs {
    display: flex;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
.vc-ad-tab {
    flex: 1;
    padding: 8px 12px;
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    color: silver;
    font-size: 13px;
    cursor: pointer;
    text-align: center;
    transition: color 0.2s, border-color 0.2s;
}
.vc-ad-tab:hover { color: #ddd; }
.vc-ad-tab-active {
    color: #fff;
    border-bottom-color: #183488;
    background: var(--vc-selected-tab);
}

.vc-ad-tab-content {
    padding: 16px;
}

/* Color Picker */
.vc-ad-color-pickers {
    display: flex;
    gap: 24px;
    margin-top: 12px;
    flex-wrap: wrap;
}
.vc-color-picker-group label {
    display: block;
    color: var(--vc-text-muted);
    font-size: 13px;
    margin-bottom: 6px;
}
.vc-color-grid {
    display: grid;
    grid-template-columns: repeat(6, 24px);
    gap: 3px;
}
.vc-color-swatch {
    width: 24px;
    height: 24px;
    border: 2px solid transparent;
    border-radius: 3px;
    cursor: pointer;
    padding: 0;
}
.vc-color-swatch:hover { border-color: rgba(255,255,255,0.5); }
.vc-color-selected { border-color: #fff; box-shadow: 0 0 4px rgba(255,255,255,0.6); }

/* Affiliate Tiles */
.vc-affiliate-tiles {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}
.vc-affiliate-tile {
    width: 148px;
    height: 88px;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s;
}
.vc-affiliate-tile:hover { transform: scale(1.03); }
.vc-affiliate-tile-bg {
    position: absolute;
    inset: 0;
}
.vc-affiliate-tile-name {
    position: relative;
    color: #fff;
    font-size: 14px;
    font-weight: bold;
    text-align: center;
    padding: 4px 8px;
    text-shadow: 0 1px 4px rgba(0,0,0,0.6);
}
.vc-affiliate-tile-soon {
    position: relative;
    color: rgba(255,255,255,0.6);
    font-size: 11px;
    font-style: italic;
}

/* Ad Image */
.vc-ad-image-preview {
    max-width: 200px;
    max-height: 120px;
    margin-top: 12px;
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.1);
}
.vc-ad-image-warning {
    color: var(--vc-text-accent);
    font-size: 12px;
    margin-top: 8px;
    font-style: italic;
}

/* ── Inbox Panel ────────────────────────────────────────── */

.vc-inbox {
    padding: 0 0 48px;
}
.vc-inbox-toolbar {
    display: flex;
    gap: 8px;
    padding: 12px 18px;
    align-items: center;
}
.vc-inbox-filter {
    padding: 8px 12px;
    background: #000;
    color: #fff;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 6px;
    font-size: 15px;
}
.vc-inbox-search {
    flex: 1;
    padding: 8px 14px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 6px;
    color: #fff;
    font-size: 15px;
    outline: none;
}
.vc-inbox-search:focus {
    border-color: rgba(100,130,220,0.4);
}
.vc-inbox-refresh {
    width: 38px;
    height: 38px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 6px;
    color: #fff;
    font-size: 18px;
    cursor: pointer;
}

.vc-inbox-list {
    padding: 0 18px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.vc-package-card {
    display: flex;
    gap: 12px;
    padding: 12px;
    background: var(--vc-playlist-item);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.2s;
}
.vc-package-card:hover {
    border-color: rgba(100,130,220,0.3);
}
.vc-package-card-thumb {
    width: 80px;
    height: 60px;
    flex-shrink: 0;
    border-radius: 4px;
    overflow: hidden;
    background: #111;
}
.vc-package-card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.vc-package-card-thumb-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,0.3);
    font-size: 24px;
}
.vc-package-card-info {
    flex: 1;
    min-width: 0;
}
.vc-package-card-subject {
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.vc-package-card-owner {
    color: #bbb;
    font-size: 14px;
    margin-top: 2px;
}
.vc-package-card-meta {
    display: flex;
    gap: 12px;
    color: var(--vc-text-dim);
    font-size: 13px;
    margin-top: 4px;
}

/* ── Channel View Panel ─────────────────────────────────── */

.vc-channel-view {
    max-width: 720px;
    margin: 0 auto;
    padding: 24px 18px 48px;
}
.vc-channel-view-header {
    display: flex;
    gap: 18px;
    align-items: flex-start;
    margin-bottom: 24px;
}
.vc-channel-view-avatar {
    width: 120px;
    height: 120px;
    border-radius: 12px;
    object-fit: cover;
    flex-shrink: 0;
    background: #111;
}
.vc-channel-view-info {
    flex: 1;
    min-width: 0;
}
.vc-channel-view-name {
    color: #fff;
    font-size: 28px;
    font-weight: bold;
    margin-bottom: 6px;
}
.vc-channel-view-desc {
    color: var(--vc-text-muted);
    font-size: 16px;
    line-height: 1.5;
    margin-bottom: 8px;
}
.vc-channel-view-stats {
    display: flex;
    gap: 16px;
    color: var(--vc-text-dim);
    font-size: 14px;
}

.vc-channel-view-owner {
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 16px 0;
    border-top: 1px solid rgba(255,255,255,0.08);
    border-bottom: 1px solid rgba(255,255,255,0.08);
    margin-bottom: 18px;
}
.vc-channel-view-owner-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}
.vc-channel-view-owner-name {
    color: #fff;
    font-size: 18px;
}
.vc-channel-view-owner-email {
    color: var(--vc-text-muted);
    font-size: 14px;
}

.vc-channel-back-btn {
    display: inline-flex;
    align-items: center;
    background: none;
    border: none;
    color: rgba(100,130,220,0.9);
    font-size: 14px;
    cursor: pointer;
    padding: 4px 0;
    margin-bottom: 16px;
    transition: color 0.2s;
}
.vc-channel-back-btn:hover {
    color: #fff;
}
.vc-channel-sub-btn {
    display: block;
    width: 200px;
    margin: 0 auto;
    text-align: center;
}
.vc-channel-unsub-btn {
    display: block;
    width: 200px;
    margin: 0 auto;
    background: rgba(136,0,52,0.5);
    border-color: rgba(255,255,255,0.2);
}
.vc-channel-view-login-hint {
    text-align: center;
    color: var(--vc-text-muted);
    font-size: 14px;
    padding: 18px;
}

/* ── VeamList (Channel Package List) ───────────────────── */

.vc-veamlist {
    margin-top: 24px;
    border-top: 1px solid rgba(255,255,255,0.08);
    padding-top: 18px;
}
.vc-veamlist-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 14px;
}
.vc-veamlist-title {
    color: #fff;
    font-size: 20px;
    font-weight: 700;
}
.vc-veamlist-count {
    color: var(--vc-text-dim);
    font-size: 14px;
}
.vc-veamlist-empty {
    color: var(--vc-text-muted);
    font-size: 15px;
    text-align: center;
    padding: 32px 0;
}
.vc-veamlist-grid {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

/* ── Desktop Package Card (thumbnail bg, overlay text) ──── */

.vc-veamlist-card {
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.vc-veamlist-card:hover {
    transform: scale(1.015);
    box-shadow: 0 4px 24px rgba(0,0,0,0.4);
}
.vc-veamlist-card-inner {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 */
    overflow: hidden;
}
.vc-veamlist-card-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    background-color: #111;
    transition: transform 0.4s ease;
}
.vc-veamlist-card-bg-empty {
    background: linear-gradient(135deg, #0a0a1a 0%, #111 100%);
}
.vc-veamlist-card:hover .vc-veamlist-card-bg {
    transform: scale(1.04);
}

/* Subject overlay — top gradient (hidden until hover) */
.vc-veamlist-card-subject {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    padding: 14px 16px 24px;
    background: linear-gradient(to bottom, rgba(0,0,0,0.7) 0%, transparent 100%);
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-shadow: 0 1px 6px rgba(0,0,0,0.8);
    z-index: 2;
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* Bottom info overlay (hidden until hover) */
.vc-veamlist-card-bottom {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 24px 16px 12px;
    background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, transparent 100%);
    z-index: 2;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.vc-veamlist-card:hover .vc-veamlist-card-subject,
.vc-veamlist-card:hover .vc-veamlist-card-bottom {
    opacity: 1;
}
.vc-veamlist-card-tag {
    color: rgba(255,255,255,0.7);
    font-size: 14px;
    margin-bottom: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.vc-veamlist-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: rgba(255,255,255,0.6);
    font-size: 13px;
}
.vc-veamlist-card-date {
    flex-shrink: 0;
}
.vc-veamlist-card-owner {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
}
.vc-veamlist-card-owner-avatar {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

/* Play button overlay — centered, square blue gradient, appears on hover */
.vc-veamlist-card-play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.8);
    z-index: 3;
    width: 72px;
    height: 72px;
    border-radius: 10px;
    background: linear-gradient(135deg, #0D47A1 0%, #1565C0 25%, #42A5F5 50%, #1565C0 75%, #0D47A1 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding-left: 4px;
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow:
        0 0 30px rgba(13,71,161,0.5),
        0 4px 20px rgba(0,0,0,0.4),
        inset 0 1px 0 rgba(255,255,255,0.2);
    overflow: hidden;
}
/* Glass overlay on play button */
.vc-veamlist-card-play::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 10px;
    background: linear-gradient(125deg,
        rgba(255,255,255,0.3) 0%,
        transparent 30%,
        rgba(255,255,255,0.1) 50%,
        transparent 70%,
        rgba(255,255,255,0.2) 100%);
    pointer-events: none;
}
/* Glow ring on play button */
.vc-veamlist-card-play::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 12px;
    border: 2px solid rgba(66,165,245,0.4);
    pointer-events: none;
}
.vc-veamlist-card:hover .vc-veamlist-card-play {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

/* ── Mobile Package Card ───────────────────────────────── */

.vc-veamlist-card-mobile {
    display: flex;
    gap: 12px;
    padding: 10px;
    background: var(--vc-playlist-item, rgba(255,255,255,0.04));
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.2s;
}
.vc-veamlist-card-mobile:hover {
    border-color: rgba(100,130,220,0.3);
}
.vc-veamlist-card-mobile-thumb {
    width: 120px;
    height: 80px;
    flex-shrink: 0;
    border-radius: 6px;
    overflow: hidden;
    background: #111;
    position: relative;
}
.vc-veamlist-card-mobile-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.vc-veamlist-card-mobile-thumb-empty {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,0.2);
    font-size: 28px;
}
.vc-veamlist-card-mobile-play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 36px;
    height: 36px;
    border-radius: 6px;
    background: linear-gradient(135deg, #0D47A1 0%, #1565C0 50%, #0D47A1 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding-left: 2px;
    opacity: 0.7;
    transition: opacity 0.2s;
}
.vc-veamlist-card-mobile:hover .vc-veamlist-card-mobile-play {
    opacity: 1;
}
.vc-veamlist-card-mobile-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.vc-veamlist-card-mobile-subject {
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.vc-veamlist-card-mobile-tag {
    color: var(--vc-text-muted);
    font-size: 13px;
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.vc-veamlist-card-mobile-meta {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--vc-text-dim);
    font-size: 12px;
    margin-top: 4px;
}
.vc-veamlist-card-mobile-owner-avatar {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    object-fit: cover;
}
.vc-veamlist-card-mobile-date {
    margin-left: auto;
}

/* ── Reply Panel ───────────────────────────────────────── */

.vc-reply {
    max-width: 400px;
    margin: 0 auto;
    padding: 16px;
    position: relative;
}

.vc-reply-watermark {
    font-size: 72px;
    font-weight: 700;
    color: rgba(255,255,255,0.06);
    position: absolute;
    bottom: 0;
    left: 16px;
    pointer-events: none;
    line-height: 1;
}

.vc-reply-context {
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.vc-reply-subject {
    font-size: 18px;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.vc-reply-tag {
    font-size: 26px;
    font-weight: 600;
    color: var(--text-muted);
}

.vc-reply-sender {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
}

.vc-reply-sender-label {
    font-size: 13px;
    color: var(--text-muted);
}

.vc-reply-sender-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.vc-reply-sender-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid rgba(255,255,255,0.12);
}

.vc-reply-input {
    width: 100%;
    min-height: 120px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 16px;
    padding: 14px;
    resize: vertical;
    font-family: inherit;
    box-sizing: border-box;
    opacity: 0.88;
}
.vc-reply-input:focus {
    outline: none;
    border-color: rgba(100,130,220,0.5);
    opacity: 1;
}
.vc-reply-input::placeholder {
    color: var(--text-muted);
}

.vc-reply-error {
    color: #FFD700;
    font-size: 14px;
    text-align: center;
    margin: 8px 0;
}

.vc-reply-send-row {
    display: flex;
    justify-content: center;
    margin: 18px 0;
}

.vc-reply-send-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 88px;
    height: 88px;
    border-radius: 12px;
    border: none;
    background: dodgerblue;
    color: white;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
    gap: 4px;
    font-size: 13px;
    font-weight: 600;
}
.vc-reply-send-btn:hover {
    background: #1a7ae8;
    transform: scale(1.05);
}
.vc-reply-send-btn:active {
    transform: scale(0.97);
}

.vc-reply-media-btns {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 16px;
}

.vc-reply-media-btn {
    width: 54px;
    height: 54px;
    border-radius: 10px;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s, opacity 0.2s;
    opacity: 0.85;
}
.vc-reply-media-btn:hover {
    transform: scale(1.1);
    opacity: 1;
}

.vc-reply-media-video  { background: #183466; }
.vc-reply-media-audio  { background: #883418; }
.vc-reply-media-photo  { background: #188834; }
.vc-reply-media-attach { background: #888834; }

.vc-reply-signin-hint {
    text-align: center;
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 8px;
}

/* Sending state */
.vc-reply-sending {
    text-align: center;
    padding: 60px 20px;
}

.vc-reply-sending-text {
    font-size: 18px;
    font-weight: 600;
    margin-top: 16px;
    color: var(--text-primary);
}

.vc-reply-sending-hint {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 8px;
}

/* Result state */
.vc-reply-result {
    text-align: center;
    padding: 40px 20px;
}

.vc-reply-result-msg {
    color: var(--text-muted);
    margin-bottom: 24px;
    font-size: 14px;
}

.vc-reply-actions {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 16px;
}

.vc-reply-again-btn {
    padding: 12px 28px;
    background: rgba(100,130,220,0.2);
    border: 1px solid rgba(100,130,220,0.35);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s;
}
.vc-reply-again-btn:hover {
    background: rgba(100,130,220,0.35);
}

/* Reply input wrapper — positions mic button over textarea */
.vc-reply-input-wrap {
    position: relative;
}
.vc-reply-input-wrap .vc-reply-input {
    padding-right: 70px; /* room for mic button */
}

/* Big microphone button inside textarea area */
.vc-reply-mic-btn {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 52px;
    height: 52px;
    border: 2px solid rgba(255,255,255,0.15);
    border-radius: 50%;
    background: rgba(255,255,255,0.06);
    color: rgba(255,255,255,0.5);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}
.vc-reply-mic-btn svg {
    width: 28px;
    height: 28px;
}
.vc-reply-mic-btn:hover {
    border-color: rgba(100,130,220,0.5);
    color: rgba(100,130,220,0.9);
    background: rgba(100,130,220,0.1);
}

/* Active / recording state */
.vc-reply-mic-btn.vc-mic-active {
    color: #ef4444;
    border-color: #ef4444;
    background: rgba(239,68,68,0.15);
    animation: vc-mic-pulse 1.2s ease-in-out infinite;
}
@keyframes vc-mic-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(239,68,68,0.3); }
    50% { box-shadow: 0 0 0 8px rgba(239,68,68,0); }
}

/* Mic status text below textarea */
.vc-reply-mic-status {
    text-align: center;
    font-size: 12px;
    color: var(--text-muted);
    margin: 4px 0 0;
}
.vc-reply-mic-status--error {
    color: #FFD700;
}

/* ── Rating Panel ──────────────────────────────────────── */

.vc-rating {
    max-width: 560px;
    margin: 0 auto;
    padding: 8px 0;
}

.vc-rating-nav {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 16px;
}

.vc-rating-nav-btn {
    background: rgba(100,130,220,0.15);
    border: 1px solid rgba(100,130,220,0.3);
    color: #ccc;
    padding: 8px 18px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    transition: background 0.2s;
    margin-left: 8px;
}
.vc-rating-nav-btn:hover {
    background: rgba(100,130,220,0.3);
    color: #fff;
}

.vc-rating-header {
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-subtle, rgba(255,255,255,0.08));
}

.vc-rating-write-btn {
    display: block;
    width: 100%;
    padding: 14px 20px;
    background: rgba(100,130,220,0.15);
    border: 1px solid rgba(100,130,220,0.35);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
}
.vc-rating-write-btn:hover {
    background: rgba(100,130,220,0.3);
    border-color: rgba(100,130,220,0.55);
}

.vc-rating-signin {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border-subtle, rgba(255,255,255,0.08));
    border-radius: 8px;
    color: var(--text-muted, #999);
    font-size: 14px;
}
.vc-rating-signin-icon {
    font-size: 24px;
    color: #FFD700;
    opacity: 0.5;
}

.vc-rating-login {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted, #999);
}

.vc-rating-section {
    margin-bottom: 20px;
}

.vc-rating-label {
    font-size: 13px;
    font-weight: 600;
    color: rgba(255,255,255,0.6);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Stars */
.vc-rating-stars {
    display: flex;
    gap: 4px;
}

.vc-star {
    background: none;
    border: none;
    font-size: 32px;
    color: rgba(255,255,255,0.2);
    cursor: pointer;
    padding: 2px 4px;
    transition: color 0.15s, transform 0.15s;
    line-height: 1;
}
.vc-star:hover {
    transform: scale(1.2);
    color: #FFD700;
}
.vc-star-active {
    color: #FFD700;
}

/* Category chips */
.vc-rating-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.vc-cat-chip {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    color: rgba(255,255,255,0.7);
    padding: 6px 14px;
    border-radius: 16px;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.15s;
}
.vc-cat-chip:hover {
    background: rgba(100,130,220,0.15);
    border-color: rgba(100,130,220,0.3);
}
.vc-cat-active {
    background: rgba(100,130,220,0.25);
    border-color: rgba(100,130,220,0.5);
    color: #fff;
}

/* Tag chips */
.vc-rating-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.vc-tag-chip {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    color: rgba(255,255,255,0.7);
    padding: 6px 14px;
    border-radius: 16px;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.15s;
}
.vc-tag-chip:hover {
    background: rgba(100,180,100,0.15);
    border-color: rgba(100,180,100,0.3);
}
.vc-tag-active {
    background: rgba(100,180,100,0.25);
    border-color: rgba(100,180,100,0.5);
    color: #fff;
}

/* Comment textarea */
.vc-rating-comment {
    width: 100%;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 8px;
    color: #fff;
    padding: 12px;
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    transition: border-color 0.2s;
    box-sizing: border-box;
}
.vc-rating-comment:focus {
    outline: none;
    border-color: rgba(100,130,220,0.5);
}

/* Actions */
.vc-rating-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 20px;
}

.vc-rating-submit,
.vc-rating-post {
    padding: 12px 36px;
    background: rgba(100,130,220,0.3);
    border: 1px solid rgba(100,130,220,0.4);
    border-radius: 24px;
    color: #fff;
    font-size: 15px;
    cursor: pointer;
    transition: background 0.2s;
}
.vc-rating-submit:hover,
.vc-rating-post:hover {
    background: rgba(100,130,220,0.5);
}
.vc-rating-submit:disabled {
    opacity: 0.4;
    cursor: default;
}

.vc-rating-back {
    padding: 12px 36px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 24px;
    color: #ccc;
    font-size: 15px;
    cursor: pointer;
    transition: background 0.2s;
}
.vc-rating-back:hover {
    background: rgba(255,255,255,0.12);
}

/* Confirm view */
.vc-rating-confirm {
    text-align: center;
}

.vc-rating-confirm-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 24px;
}

.vc-rating-summary-row {
    margin-bottom: 8px;
    font-size: 14px;
}

.vc-rating-summary-label {
    color: rgba(255,255,255,0.5);
    margin-right: 8px;
}

.vc-rating-summary-comment {
    background: rgba(255,255,255,0.04);
    border-radius: 8px;
    padding: 12px;
    margin: 8px 0 16px;
    text-align: left;
    font-size: 14px;
    line-height: 1.5;
    color: rgba(255,255,255,0.8);
}

/* Submitted view */
.vc-rating-submitted {
    text-align: center;
    padding: 40px 20px;
}

/* Comments list */
.vc-rating-comments-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 16px;
}

.vc-rating-empty {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted, #999);
    font-size: 14px;
}

.vc-comment-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.vc-comment-card {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    padding: 14px;
    transition: border-color 0.2s;
}
.vc-comment-card:hover {
    border-color: rgba(255,255,255,0.15);
}

.vc-comment-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.vc-comment-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

.vc-comment-meta {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.vc-comment-user {
    font-size: 14px;
    font-weight: 600;
    color: #fff;
}

.vc-comment-stars {
    font-size: 14px;
}

.vc-comment-date {
    font-size: 12px;
    color: rgba(255,255,255,0.4);
    white-space: nowrap;
}

.vc-comment-tags {
    display: flex;
    gap: 6px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.vc-comment-tag {
    font-size: 11px;
    background: rgba(100,130,220,0.15);
    border-radius: 10px;
    padding: 2px 10px;
    color: rgba(255,255,255,0.6);
}

.vc-comment-text {
    font-size: 14px;
    line-height: 1.5;
    color: rgba(255,255,255,0.8);
    margin-bottom: 10px;
}

.vc-comment-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.vc-comment-action {
    background: none;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 14px;
    color: rgba(255,255,255,0.5);
    padding: 3px 12px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.15s;
    display: flex;
    align-items: center;
    gap: 4px;
}
.vc-comment-action:hover {
    background: rgba(255,255,255,0.08);
    color: #fff;
    border-color: rgba(255,255,255,0.2);
}

.vc-comment-action-alert:hover {
    background: rgba(220,100,100,0.15);
    border-color: rgba(220,100,100,0.3);
    color: #ff8888;
}

.vc-comment-count {
    font-size: 12px;
}

/* ── Responsive: Panels ─────────────────────────────────── */

@media (max-width: 768px) {
    .vc-channel-card {
        width: 100%;
        height: auto;
        min-height: 160px;
    }
    .vc-discover-grid {
        flex-direction: column;
        gap: 10px;
        padding: 0 12px 48px;
    }
    .vc-discover-search {
        max-width: none;
        margin-left: 0;
        padding: 8px 12px 12px;
    }
    .vc-discover-search-input {
        width: auto;
        flex: 1;
        font-size: 16px;
    }
    .vc-discover-search-header {
        padding: 0 12px 10px;
    }
    .menu-panel.discover-active .menu-panel-body {
        padding: 8px 0;
    }
    .vc-channel-card-mobile {
        min-height: 72px;
    }
    .vc-channel-card-mobile-thumb {
        width: 80px;
        min-height: 72px;
    }
    .vc-channel-card-mobile-info {
        padding: 10px 14px;
    }
    .vc-channel-card-mobile-name {
        font-size: 16px;
    }
    .vc-user-menu-item {
        font-size: 16px;
        padding: 6px 10px;
    }
    .vc-campaigns-header {
        font-size: 32px;
    }
    .vc-campaign-editor-actions {
        justify-content: center;
    }
    .vc-affiliate-tiles {
        justify-content: center;
    }
    .vc-channel-view-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .vc-channel-view-stats {
        justify-content: center;
    }
    .vc-veamlist-card-play {
        width: 56px;
        height: 56px;
    }
    .vc-veamlist-card-play svg {
        width: 36px;
        height: 36px;
    }
    .vc-ad-color-pickers {
        flex-direction: column;
    }
}

@media (max-width: 640px) {
    .vc-inbox-toolbar {
        flex-direction: column;
    }
}

/* ===========================================================
   LIGHT MODE
   Toggle via data-theme="light" on <html>.
   =========================================================== */

/* ── Core variable overrides ──────────────────────────────── */
html[data-theme="light"] {
    --bg-primary: #f0f1f6;
    --bg-header: linear-gradient(135deg, #e4e6f0 0%, #d4d8e8 100%);
    --bg-card: rgba(0,0,0,0.03);
    --border-subtle: rgba(0,0,0,0.10);
    --border-accent: rgba(50,80,160,0.20);
    --text-primary: #2a2a3a;
    --text-heading: #1a1a2a;
    --text-muted: rgba(0,0,0,0.45);
    --text-accent: rgba(40,70,160,0.85);
    --link-color: #1e5cc0;
    --play-btn-bg: rgba(50,80,160,0.12);
    --play-btn-hover: rgba(50,80,160,0.22);
    --info-btn-bg: rgba(0,0,0,0.06);
    --info-btn-hover: rgba(0,0,0,0.12);
    --vc-text-primary: #1a1a2a;
    --vc-text-muted: #555;
    --vc-text-dim: #777;
    --vc-text-accent: #886600;
    --vc-text-link: #1e5cc0;

    /* Accent gradient shades — lighter for light mode */
    --accent-1: #2854a0;
    --accent-2: #3060b0;
    --accent-3: #3868bb;
    --accent-4: #4078cc;
    --accent-5: #5090dd;
    --accent-6: #60a0ee;
    --accent-border: rgba(50,100,200,0.35);
    --accent-border-strong: rgba(40,90,200,0.55);
    --accent-glow: rgba(40,80,180,0.25);
    --accent-glow-strong: rgba(40,80,180,0.35);
    --accent-subtle: rgba(50,80,160,0.1);
    --accent-tint: rgba(50,80,160,0.06);
}

/* ── Body / HTML ──────────────────────────────────────────── */
html[data-theme="light"] body {
    background: var(--bg-primary);
    color: var(--text-primary);
}

/* ── Header ───────────────────────────────────────────────── */
html[data-theme="light"] .player-header {
    background: linear-gradient(135deg, rgba(228,230,240,0.96) 0%, rgba(212,216,232,0.96) 100%);
    border-bottom-color: rgba(50,80,160,0.12);
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

html[data-theme="light"] .header-logo-link {
    filter: brightness(0) saturate(100%) invert(15%) sepia(40%) saturate(800%) hue-rotate(200deg);
}
html[data-theme="light"] .nav-loader {
    background: rgba(240, 241, 246, 0.9);
}
html[data-theme="light"] .nav-loader-logo {
    filter: brightness(0) saturate(100%) invert(15%) sepia(40%) saturate(800%) hue-rotate(200deg);
}

/* ── Menu Buttons — gradients now use accent variables ───── */
html[data-theme="light"] .menu-btn {
    box-shadow:
        0 2px 8px var(--accent-glow),
        0 1px 2px rgba(0,0,0,0.1),
        inset 0 1px 0 rgba(255,255,255,0.25);
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

html[data-theme="light"] .menu-btn:hover {
    box-shadow:
        0 4px 16px var(--accent-glow-strong),
        0 1px 3px rgba(0,0,0,0.12),
        inset 0 1px 0 rgba(255,255,255,0.3);
}

/* ── Mobile Menu — gradient uses accent variables ────────── */
html[data-theme="light"] .mobile-menu-trigger {
    box-shadow: 0 2px 10px var(--accent-glow), inset 0 1px 0 rgba(255,255,255,0.2);
}

html[data-theme="light"] .mobile-nav-menu {
    background: rgba(240,241,246,0.98);
    backdrop-filter: blur(20px);
}

html[data-theme="light"] .mobile-menu-status {
    border-bottom-color: rgba(0,0,0,0.08);
    background: linear-gradient(135deg, rgba(230,232,242,0.95) 0%, rgba(220,224,238,0.95) 100%);
}

html[data-theme="light"] .mobile-menu-status-title { color: #1a1a2a; }

html[data-theme="light"] .mobile-menu-close {
    border-color: rgba(0,0,0,0.12);
    background: rgba(0,0,0,0.05);
    color: rgba(0,0,0,0.5);
}
html[data-theme="light"] .mobile-menu-close:hover {
    background: rgba(220,60,60,0.12);
    border-color: rgba(220,60,60,0.3);
    color: #cc3030;
}

html[data-theme="light"] .mobile-menu-btn {
    border-color: rgba(0,0,0,0.08);
    background: linear-gradient(135deg, rgba(255,255,255,0.9) 0%, rgba(240,242,250,0.85) 100%);
    color: #1a1a2a;
    box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
html[data-theme="light"] .mobile-menu-btn:hover {
    border-color: var(--accent-border);
    box-shadow: 0 2px 12px var(--accent-glow);
}
html[data-theme="light"] .mobile-menu-btn-label { color: #1a1a2a; }
html[data-theme="light"] .mobile-menu-btn-icon {
    box-shadow: 0 1px 4px var(--accent-glow);
}
html[data-theme="light"] .mobile-menu-spinner { opacity: 0.03; }

/* ── Menu Panel ───────────────────────────────────────────── */
html[data-theme="light"] .menu-panel {
    background: rgba(240,241,246,0.98);
    backdrop-filter: blur(12px);
}

html[data-theme="light"] .menu-panel-body {
    scrollbar-color: rgba(0,0,0,0.15) rgba(0,0,0,0.05);
}
html[data-theme="light"] .menu-panel-body::-webkit-scrollbar-track { background: rgba(0,0,0,0.05); }
html[data-theme="light"] .menu-panel-body::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.15); }
html[data-theme="light"] .menu-panel-body::-webkit-scrollbar-thumb:hover { background: rgba(0,0,0,0.25); }
html[data-theme="light"] .header-profile-name { color: #1a1a2a; }
html[data-theme="light"] .header-profile-email { color: rgba(0,0,0,0.45); }
html[data-theme="light"] .header-profile-label { color: rgba(0,0,0,0.35); }
html[data-theme="light"] .header-profile-avatar { border-color: rgba(50,80,160,0.3); }

/* ── Bottom Bar ───────────────────────────────────────────── */
html[data-theme="light"] .bottom-bar {
    background: transparent;
}
html[data-theme="light"] .bottom-shared-by { color: rgba(0,0,0,0.4); }
html[data-theme="light"] .bottom-sender-name { color: #1a1a2a; }
html[data-theme="light"] .bottom-date { color: rgba(0,0,0,0.35); }
html[data-theme="light"] .bottom-title {
    background: linear-gradient(to right,
        rgba(200,210,240,0.5) 0%,
        rgba(220,225,245,0.3) 34%,
        transparent 100%
    );
}
html[data-theme="light"] .bottom-subject { color: #1a1a2a; }
html[data-theme="light"] .bottom-description { color: rgba(0,0,0,0.5); }
html[data-theme="light"] .bottom-avatar { border-color: rgba(50,80,160,0.2); }

/* ── Cover Page ───────────────────────────────────────────── */
html[data-theme="light"] .cover-thumbnail {
    border-color: rgba(0,0,0,0.08);
    background: rgba(0,0,0,0.02);
    box-shadow: 0 8px 40px rgba(0,0,0,0.12);
}
html[data-theme="light"] .cover-thumbnail-placeholder {
    border-color: rgba(0,0,0,0.08);
    background: rgba(0,0,0,0.02);
}
html[data-theme="light"] .cover-avatar {
    background: rgba(0,0,0,0.04);
}
html[data-theme="light"] .cover-avatar-placeholder {
    background: rgba(50,80,160,0.1);
}

/* Play button — gradients now use accent variables */
html[data-theme="light"] .cover-play-btn {
    box-shadow:
        0 4px 20px var(--accent-glow),
        0 2px 6px rgba(0,0,0,0.1),
        inset 0 1px 0 rgba(255,255,255,0.3);
    text-shadow: 0 1px 4px rgba(0,0,0,0.3);
}
html[data-theme="light"] .cover-play-btn:hover {
    box-shadow:
        0 6px 30px var(--accent-glow-strong),
        0 2px 6px rgba(0,0,0,0.1),
        inset 0 1px 0 rgba(255,255,255,0.35);
}
html[data-theme="light"] .cover-reply-btn {
    background: rgba(0,0,0,0.04);
    border-color: rgba(0,0,0,0.12);
    color: var(--text-primary);
}
html[data-theme="light"] .cover-reply-btn:hover {
    background: rgba(50,80,160,0.1);
    border-color: rgba(50,80,160,0.25);
}
html[data-theme="light"] .cover-veam-btn-title { color: var(--text-primary); }
html[data-theme="light"] .cover-next-arrow {
    background: rgba(0,0,0,0.05);
    border-color: rgba(0,0,0,0.12);
    color: rgba(0,0,0,0.4);
}
html[data-theme="light"] .cover-next-arrow:hover {
    background: rgba(0,0,0,0.1);
    color: rgba(0,0,0,0.7);
    border-color: rgba(50,80,160,0.3);
}

/* ── Data Sheet ───────────────────────────────────────────── */
html[data-theme="light"] .datasheet-overlay { background: var(--bg-primary); }

html[data-theme="light"] .datasheet-close {
    border-color: rgba(0,0,0,0.1);
    background: rgba(0,0,0,0.04);
    color: rgba(0,0,0,0.45);
}
html[data-theme="light"] .datasheet-close:hover {
    background: rgba(0,0,0,0.08);
    color: #1a1a2a;
}

html[data-theme="light"] .datasheet-header h2 { color: #1a1a2a; opacity: 1; }

/* ── Sections & Fields ────────────────────────────────────── */
html[data-theme="light"] .section {
    background: rgba(255,255,255,0.7);
    border-color: rgba(0,0,0,0.08);
}
html[data-theme="light"] .section-title {
    background: rgba(0,0,0,0.02);
    border-bottom-color: rgba(0,0,0,0.06);
}
html[data-theme="light"] .field { border-bottom-color: rgba(0,0,0,0.05); }
html[data-theme="light"] .field-value { color: #333; }
html[data-theme="light"] .field-value.subject { color: var(--text-heading); }
html[data-theme="light"] .field-value a { color: var(--link-color); }

html[data-theme="light"] .item-card {
    background: rgba(0,0,0,0.02);
    border-color: rgba(0,0,0,0.06);
}
html[data-theme="light"] .item-name { color: #222; }

html[data-theme="light"] .badge-video { background: rgba(200,40,40,0.1); color: #aa2020; }
html[data-theme="light"] .badge-audio { background: rgba(30,140,30,0.1); color: #1a8a1a; }
html[data-theme="light"] .badge-image { background: rgba(40,90,200,0.1); color: #2060c0; }
html[data-theme="light"] .badge-link  { background: rgba(160,100,30,0.1); color: #a06020; }
html[data-theme="light"] .badge-file  { background: rgba(80,80,80,0.1); color: #666; }

html[data-theme="light"] .recipient-chip {
    background: rgba(50,80,160,0.08);
    border-color: rgba(50,80,160,0.15);
    color: var(--text-primary);
}

/* ── Loading / Error ──────────────────────────────────────── */
html[data-theme="light"] .error-state { color: #cc3030; }

/* ── Playback Viewport ────────────────────────────────────── */
html[data-theme="light"] .veam-playback { background: var(--bg-primary); }
/* Item title/desc overlays stay dark with white text in both themes (they float over photos) */
html[data-theme="light"] .veam-item-counter { background: rgba(0,0,0,0.08); color: rgba(0,0,0,0.7); }
html[data-theme="light"] .veam-stream-local { color: #1a8040; background: rgba(40,160,80,0.12); border-color: rgba(40,160,80,0.25); }
html[data-theme="light"] .veam-stream-cloud { color: #2060b0; background: rgba(40,100,200,0.12); border-color: rgba(40,100,200,0.25); }
html[data-theme="light"] .veam-stream-external { color: #a06010; background: rgba(180,120,30,0.12); border-color: rgba(180,120,30,0.25); }

/* Nav buttons — frosted glass (different pattern from dark mode) */
html[data-theme="light"] .veam-nav-prev,
html[data-theme="light"] .veam-nav-next {
    background: linear-gradient(135deg, rgba(255,255,255,0.85) 0%, rgba(235,240,250,0.9) 100%);
    color: var(--accent-2);
    box-shadow: 0 2px 12px rgba(0,0,0,0.1), inset 0 1px 0 rgba(255,255,255,0.5);
    text-shadow: none;
}
html[data-theme="light"] .veam-nav-prev:hover,
html[data-theme="light"] .veam-nav-next:hover {
    background: linear-gradient(135deg, rgba(255,255,255,0.95) 0%, rgba(230,235,248,0.95) 100%);
    box-shadow: 0 4px 16px var(--accent-glow);
}

html[data-theme="light"] .veam-nav-stop {
    background: linear-gradient(135deg, rgba(255,255,255,0.85) 0%, rgba(240,240,245,0.9) 100%);
    color: rgba(0,0,0,0.5);
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
html[data-theme="light"] .veam-nav-stop:hover {
    background: linear-gradient(135deg, rgba(220,50,50,0.9) 0%, rgba(200,35,35,0.9) 100%);
    color: #fff;
}
html[data-theme="light"] .veam-nav-stop::after { border-color: rgba(0,0,0,0.1); }

/* Countdown */
html[data-theme="light"] .veam-countdown {
    background: rgba(255,255,255,0.85);
    border-color: rgba(0,0,0,0.1);
}
html[data-theme="light"] .veam-countdown-ring-bg { stroke: rgba(0,0,0,0.1); }
html[data-theme="light"] .veam-countdown-seconds { color: rgba(0,0,0,0.6); }
html[data-theme="light"] .veam-countdown-label { color: rgba(0,0,0,0.35); }

/* Video overlays */
html[data-theme="light"] .veam-video-play-overlay {
    background: linear-gradient(135deg, #1565C0 0%, #42A5F5 25%, #64B5F6 50%, #42A5F5 75%, #1565C0 100%);
    box-shadow: 0 0 24px rgba(21,101,192,0.4), 0 4px 16px rgba(0,0,0,0.15);
}
html[data-theme="light"] .veam-video-pause-overlay {
    background: linear-gradient(135deg, rgba(255,255,255,0.92) 0%, rgba(235,240,250,0.92) 100%);
    color: var(--accent-2);
}

/* ── Audio player (light mode) ────────────────────────────── */
html[data-theme="light"] .veam-audio-backdrop {
    filter: blur(60px) saturate(1.4) brightness(0.85);
}
html[data-theme="light"] .veam-audio-backdrop-overlay {
    background: radial-gradient(ellipse at center, rgba(240,241,246,0.4) 0%, rgba(240,241,246,0.9) 100%);
}
html[data-theme="light"] .veam-audio-card {
    background: rgba(255,255,255,0.6);
    border-color: rgba(0,0,0,0.08);
    box-shadow: 0 20px 80px rgba(0,0,0,0.15), 0 0 0 1px rgba(0,0,0,0.04) inset;
}
html[data-theme="light"] .veam-audio-play-btn {
    background: rgba(30,80,180,0.15);
    border-color: rgba(30,80,180,0.2);
    color: var(--accent-4);
}
html[data-theme="light"] .veam-audio-play-btn:hover {
    background: rgba(30,80,180,0.25);
}
html[data-theme="light"] .veam-audio-progress {
    background: rgba(0,0,0,0.08);
}
html[data-theme="light"] .veam-audio-progress-fill {
    background: linear-gradient(90deg, rgba(30,80,180,0.5) 0%, rgba(30,120,220,0.8) 100%);
}
html[data-theme="light"] .veam-audio-progress-glow {
    background: rgba(30,120,220,0.85);
    box-shadow: 0 0 10px rgba(30,120,220,0.4);
}

/* ── Panels (header/footer/marquee) ───────────────────────── */
html[data-theme="light"] .veam-panel-header {
    background: linear-gradient(180deg, rgba(255,255,255,0.75) 0%, transparent 100%);
    color: var(--text-heading);
}
html[data-theme="light"] .veam-panel-footer {
    background: linear-gradient(0deg, rgba(255,255,255,0.75) 0%, transparent 100%);
}
html[data-theme="light"] .veam-panel-marquee {
    background: rgba(255,255,255,0.9);
    border-top-color: rgba(50,80,160,0.15);
}
html[data-theme="light"] .veam-panel-ad {
    background: rgba(0,0,0,0.03);
    border-color: rgba(0,0,0,0.06);
}

/* ── Link template ────────────────────────────────────────── */
html[data-theme="light"] .veam-link-card {
    background: rgba(0,0,0,0.04);
    box-shadow: 0 2px 16px rgba(0,0,0,0.12);
}
html[data-theme="light"] .veam-link-btn {
    border-color: rgba(0,0,0,0.15);
    color: var(--text-muted);
}
html[data-theme="light"] .veam-link-btn:hover {
    background: rgba(0,0,0,0.05);
    border-color: rgba(0,0,0,0.3);
    color: var(--text-heading);
}

/* ── File template ────────────────────────────────────────── */
html[data-theme="light"] .veam-file-download {
    box-shadow: 0 2px 12px var(--accent-glow);
}

/* ── VC Panel Components (Discover, User, Campaigns, etc.) ─ */
html[data-theme="light"] .vc-btn-primary {
    background: linear-gradient(135deg, var(--accent-2) 0%, var(--accent-4) 100%);
}

html[data-theme="light"] .vc-btn-tile {
    background: linear-gradient(135deg, var(--accent-2) 0%, var(--accent-4) 100%);
    border-image: none;
    border: 2px solid rgba(50,100,200,0.3);
}

html[data-theme="light"] .vc-discover-search-input {
    background: rgba(0,0,0,0.04);
    border-color: rgba(0,0,0,0.12);
    color: #1a1a2a;
}
html[data-theme="light"] .vc-discover-search-input:focus {
    border-color: rgba(50,80,160,0.4);
}
html[data-theme="light"] .vc-discover-search-btn {
    background: linear-gradient(135deg, var(--accent-2) 0%, var(--accent-4) 100%);
}
html[data-theme="light"] .vc-discover-search-clear {
    background: rgba(0,0,0,0.06);
    color: #333;
}
html[data-theme="light"] .vc-discover-search-term { color: #1a1a2a; }

/* Channel cards */
html[data-theme="light"] .vc-channel-card {
    border-color: rgba(0,0,0,0.12);
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}
html[data-theme="light"] .vc-channel-card-bottom {
    background: linear-gradient(to bottom, rgba(0,0,0,0.5), rgba(0,0,0,0.7));
}
html[data-theme="light"] .vc-channel-card-mobile {
    background: rgba(255,255,255,0.8);
    border-color: rgba(0,0,0,0.1);
}
html[data-theme="light"] .vc-channel-card-mobile-name { color: #1a1a2a; }
html[data-theme="light"] .vc-channel-card-mobile-owner { color: #666; }
html[data-theme="light"] .vc-channel-card-mobile-stats { color: #888; }

/* User panel */
html[data-theme="light"] .vc-user-menu-item { color: #666; }
html[data-theme="light"] .vc-user-menu-item:hover { color: #333; }
html[data-theme="light"] .vc-user-menu-active { color: #1a1a2a !important; }
html[data-theme="light"] .vc-user-menu-combo {
    background: #fff;
    color: #1a1a2a;
    border-color: rgba(0,0,0,0.15);
}
html[data-theme="light"] .vc-user-account-label { color: #1a1a2a; }
html[data-theme="light"] .vc-user-account-name { color: #1a1a2a; }
html[data-theme="light"] .vc-user-account-email { color: #333; }
html[data-theme="light"] .vc-user-account-signup { color: #333; }
html[data-theme="light"] .vc-user-download-title { color: #1a1a2a; }
html[data-theme="light"] .vc-user-download-btn {
    background: linear-gradient(135deg, var(--accent-2) 0%, var(--accent-4) 100%);
    border-color: var(--accent-border);
}

/* Login form */
html[data-theme="light"] .vc-user-login-title { color: #1a1a2a; }
html[data-theme="light"] .vc-user-login-email,
html[data-theme="light"] .vc-user-login-code {
    background: rgba(0,0,0,0.03);
    border-color: rgba(0,0,0,0.12);
    color: #1a1a2a;
}

/* Campaigns */
html[data-theme="light"] .vc-campaigns-header { color: rgba(0,0,0,0.12); }
html[data-theme="light"] .vc-campaign-card {
    background: rgba(255,255,255,0.8);
    border-color: rgba(0,0,0,0.1);
}
html[data-theme="light"] .vc-campaign-card:hover { border-color: rgba(50,100,200,0.35); }
html[data-theme="light"] .vc-campaign-card-name { color: #1a1a2a; }
html[data-theme="light"] .vc-campaign-new {
    background: rgba(0,0,0,0.02);
    border-color: rgba(0,0,0,0.15);
    color: #333;
}
html[data-theme="light"] .vc-campaign-new:hover { border-color: rgba(50,100,200,0.35); }
html[data-theme="light"] .vc-campaign-status-owner { color: #333; }

/* Campaign editor */
html[data-theme="light"] .vc-campaign-editor-watermark { color: rgba(0,0,0,0.06); }
html[data-theme="light"] .vc-field-group label { color: #555; }
html[data-theme="light"] .vc-field-group input[type="text"],
html[data-theme="light"] .vc-field-group textarea {
    background: rgba(0,0,0,0.03);
    border-color: rgba(0,0,0,0.12);
    color: #1a1a2a;
}

html[data-theme="light"] .vc-campaign-action {
    background: rgba(0,0,0,0.04);
    border-color: rgba(0,0,0,0.1);
    color: #333;
}
html[data-theme="light"] .vc-campaign-action:hover { background: rgba(0,0,0,0.08); }

/* Ad tabs */
html[data-theme="light"] .vc-ad-tabs { border-bottom-color: rgba(0,0,0,0.08); }
html[data-theme="light"] .vc-ad-tab { color: #666; }
html[data-theme="light"] .vc-ad-tab:hover { color: #333; }
html[data-theme="light"] .vc-ad-tab-active {
    color: #1a1a2a;
    border-bottom-color: var(--accent-2);
    background: var(--accent-tint);
}
html[data-theme="light"] .vc-ad-item {
    background: rgba(0,0,0,0.02);
    border-color: rgba(0,0,0,0.08);
}
html[data-theme="light"] .vc-ad-item-header {
    background: rgba(0,0,0,0.03);
    border-bottom-color: rgba(0,0,0,0.06);
}
html[data-theme="light"] .vc-ad-move {
    background: rgba(0,0,0,0.04);
    border-color: rgba(0,0,0,0.08);
    color: #333;
}

/* Inbox */
html[data-theme="light"] .vc-inbox-filter {
    background: #fff;
    color: #1a1a2a;
    border-color: rgba(0,0,0,0.15);
}
html[data-theme="light"] .vc-inbox-search {
    background: rgba(0,0,0,0.03);
    border-color: rgba(0,0,0,0.12);
    color: #1a1a2a;
}
html[data-theme="light"] .vc-inbox-refresh {
    background: rgba(0,0,0,0.04);
    border-color: rgba(0,0,0,0.1);
    color: #333;
}
html[data-theme="light"] .vc-package-card {
    background: rgba(255,255,255,0.7);
    border-color: rgba(0,0,0,0.06);
}
html[data-theme="light"] .vc-package-card:hover { border-color: rgba(50,100,200,0.25); }
html[data-theme="light"] .vc-package-card-subject { color: #1a1a2a; }
html[data-theme="light"] .vc-package-card-owner { color: #555; }
html[data-theme="light"] .vc-package-card-thumb-placeholder { color: rgba(0,0,0,0.2); }

/* Channel view */
html[data-theme="light"] .vc-channel-view-name { color: #1a1a2a; }
html[data-theme="light"] .vc-channel-view-owner {
    border-top-color: rgba(0,0,0,0.06);
    border-bottom-color: rgba(0,0,0,0.06);
}
html[data-theme="light"] .vc-channel-view-owner-name { color: #1a1a2a; }

/* VeamList light mode */
html[data-theme="light"] .vc-veamlist { border-top-color: rgba(0,0,0,0.06); }
html[data-theme="light"] .vc-veamlist-title { color: #1a1a2a; }
html[data-theme="light"] .vc-veamlist-empty { color: #666; }
html[data-theme="light"] .vc-veamlist-card { box-shadow: 0 2px 12px rgba(0,0,0,0.1); }
html[data-theme="light"] .vc-veamlist-card-mobile {
    background: rgba(255,255,255,0.7);
    border-color: rgba(0,0,0,0.08);
}
html[data-theme="light"] .vc-veamlist-card-mobile:hover { border-color: rgba(50,100,200,0.25); }
html[data-theme="light"] .vc-veamlist-card-mobile-subject { color: #1a1a2a; }
html[data-theme="light"] .vc-veamlist-card-play {
    background: linear-gradient(135deg, #1565C0 0%, #42A5F5 25%, #64B5F6 50%, #42A5F5 75%, #1565C0 100%);
    box-shadow: 0 0 24px rgba(21,101,192,0.4), 0 4px 16px rgba(0,0,0,0.15);
}

/* ── Theme Toggle Button (lower-left) ────────────────────── */
.theme-toggle {
    position: fixed;
    bottom: 20px;
    left: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--border-subtle);
    background: var(--info-btn-bg);
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s, color 0.3s, transform 0.3s;
    z-index: 100;
}

.theme-toggle:hover {
    background: var(--info-btn-hover);
    color: var(--text-primary);
    transform: scale(1.1);
}

.theme-toggle:active {
    transform: scale(0.92);
    transition-duration: 0.1s;
}

.theme-toggle svg {
    width: 22px;
    height: 22px;
    fill: currentColor;
    transition: fill 0.3s;
}

/* In light mode, shift toggle position above bottom bar on small screens */
.player-header.visible ~ .theme-toggle {
    bottom: 60px;
}

@media (max-width: 640px) {
    .player-header.visible ~ .theme-toggle {
        bottom: 54px;
    }
}

@media (max-width: 360px) {
    .theme-toggle { bottom: 14px; left: 14px; width: 36px; height: 36px; }
    .theme-toggle svg { width: 18px; height: 18px; }
}

/* --- Share Panel Grid --- */
.share-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    justify-content: center;
    max-width: 520px;
    margin: 0 auto;
}

.share-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 110px;
    height: 110px;
    border-radius: 20px;
    border: none;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    color: #fff;
    transition: opacity 0.2s, transform 0.15s;
}

.share-btn:hover {
    opacity: 0.85;
    transform: scale(1.05);
}

.share-btn:active {
    transform: scale(0.97);
}

.share-btn-icon {
    font-size: 24px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.share-btn-icon svg {
    display: block;
}

.share-btn-copy      { background: linear-gradient(135deg, #3a3a5c, #2a2a44); }
.share-btn-email     { background: linear-gradient(135deg, #e67e22, #d35400); }
.share-btn-facebook  { background: #1877F2; }
.share-btn-x         { background: linear-gradient(135deg, #000, #343434); }
.share-btn-linkedin  { background: #0A66C2; }
.share-btn-reddit    { background: #FF4500; }
.share-btn-whatsapp  { background: #25D366; }
.share-btn-pinterest { background: #E60023; }
.share-btn-bluesky   { background: #0085FF; }
.share-btn-letterboxd{ background: #00D735; }
.share-btn-qrcode    { background: linear-gradient(135deg, #444466, #2a2a44); }

@media (max-width: 480px) {
    .share-btn {
        width: 90px;
        height: 90px;
        border-radius: 16px;
        font-size: 11px;
        gap: 6px;
    }
    .share-grid {
        gap: 10px;
    }
}
