/* ═══════════════════════════════════════════════════════════════
   visual-polish.css — Additive visual consistency pass
   Each feature is scoped under body.vp-<feature> so it can be
   toggled off by removing that class (set flag to false in JS).
   ═══════════════════════════════════════════════════════════════ */

/* ═══ 4.1 — Dot grid background ═══ */
body.dark-mode.vp-dotGrid {
    background-image: radial-gradient(circle, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 20px 20px;
}
body:not(.dark-mode).vp-dotGrid {
    background-image: radial-gradient(circle, rgba(0,0,0,0.04) 1px, transparent 1px);
    background-size: 20px 20px;
}

/* ═══ 4.1 — Glassmorphic top nav bar ═══ */
body.dark-mode.vp-glassNav .nav-bar {
    background: rgba(30,30,30,0.7) !important;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255,255,255,0.06) !important;
}
body:not(.dark-mode).vp-glassNav .nav-bar {
    background: rgba(245,244,239,0.75) !important;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(0,0,0,0.08) !important;
}

/* ═══ 4.1 — Pipeline step tab styling ═══ */
body.dark-mode.vp-tabStyle .pipeline-tabs {
    background: rgba(46,46,46,0.6);
    border-color: rgba(46,46,46,0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}
body:not(.dark-mode).vp-tabStyle .pipeline-tabs {
    background: rgba(245,244,239,0.7);
    border-color: rgba(245,244,239,0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

/* ═══ 4.1 — Dark/light theme consistency ═══ */
body.dark-mode.vp-themeSync .pipeline-tabs-bar {
    background: transparent;
}
body.dark-mode.vp-themeSync .workflow-step {
    border-color: rgba(255,255,255,0.08) !important;
    background: rgba(255,255,255,0.06) !important;
}
body.dark-mode.vp-themeSync .workflow-step:hover {
    background: rgba(255,255,255,0.12) !important;
}

/* ═══ 4.2 — Homepage drop zone glass treatment ═══ */
body.dark-mode.vp-glassDrop .console-drop-zone-content {
    background: rgba(255,255,255,0.02);
    border: 1px dashed rgba(255,255,255,0.08);
    border-radius: 16px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
body:not(.dark-mode).vp-glassDrop .console-drop-zone-content {
    background: rgba(0,0,0,0.01);
    border: 1px dashed rgba(0,0,0,0.1);
    border-radius: 16px;
}

/* ═══ 4.2 — Preview player chrome update ═══ */
body.dark-mode.vp-previewChrome #previewWrapper {
    border-radius: 0;
}
body.dark-mode.vp-previewChrome #previewToggles {
    border-top: 1px solid rgba(255,255,255,0.06);
}
body.dark-mode.vp-previewChrome #previewBottomBar {
    border-top: 1px solid rgba(255,255,255,0.06);
}

/* ═══ 4.2 — Titles card styling ═══ */
body.dark-mode.vp-titlesCards .step-titles-content .overlay-assignment-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 10px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
body:not(.dark-mode).vp-titlesCards .step-titles-content .overlay-assignment-card {
    background: rgba(255,255,255,0.7);
    border: 1px solid rgba(0,0,0,0.08);
    border-radius: 10px;
}

/* ═══ 4.2 — Export card styling ═══ */
body.dark-mode.vp-exportCards .export-layout {
    gap: 16px;
}
body.dark-mode.vp-exportCards .export-left,
body.dark-mode.vp-exportCards .export-right {
    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 12px;
}
body:not(.dark-mode).vp-exportCards .export-left,
body:not(.dark-mode).vp-exportCards .export-right {
    background: rgba(255,255,255,0.5);
    border: 1px solid rgba(0,0,0,0.06);
    border-radius: 12px;
}

/* ═══ 4.2 — Sidebar CHAT/TOOLS toggle ═══ */
body.dark-mode.vp-sidebarToggle .mode-toggle {
    background: rgba(255,255,255,0.03);
    border-color: rgba(255,255,255,0.06);
    border-radius: 10px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
body.dark-mode.vp-sidebarToggle .mode-btn.active {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.1);
}
body:not(.dark-mode).vp-sidebarToggle .mode-toggle {
    background: rgba(0,0,0,0.02);
    border-color: rgba(0,0,0,0.06);
    border-radius: 10px;
}

/* ═══ 4.3 — Trafficking teaser ═══ */
#vp-trafficking-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1200;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: 10px;
    border: 1px solid rgba(124,106,239,0.3);
    background: rgba(124,106,239,0.12);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: #7c6aef;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s;
}
#vp-trafficking-btn:hover {
    background: rgba(124,106,239,0.2);
    border-color: rgba(124,106,239,0.5);
    transform: translateY(-1px);
}

#vp-trafficking-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}
#vp-trafficking-overlay.open {
    display: flex;
}
#vp-trafficking-card {
    background: #1c1c1e;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 20px;
    padding: 40px 48px;
    max-width: 600px;
    width: 90%;
    text-align: center;
}
#vp-trafficking-card h2 {
    color: #f5f5f7;
    font-size: 22px;
    font-weight: 700;
    margin: 0 0 6px;
}
#vp-trafficking-card p {
    color: rgba(245,245,247,0.5);
    font-size: 13px;
    margin: 0 0 28px;
}
.vp-logo-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: 28px;
}
.vp-logo-pill {
    padding: 6px 14px;
    border-radius: 8px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    color: rgba(245,245,247,0.7);
    font-size: 11px;
    font-weight: 500;
    white-space: nowrap;
}
#vp-trafficking-close {
    padding: 8px 24px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.06);
    color: #f5f5f7;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.15s;
}
#vp-trafficking-close:hover {
    background: rgba(255,255,255,0.1);
}

/* ═══ 4.4 — Premiere Pro button ═══ */
#vp-premiere-btn {
    position: relative;
}
.vp-premiere-tooltip {
    display: none;
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    padding: 4px 10px;
    border-radius: 6px;
    background: rgba(30,30,30,0.95);
    border: 1px solid rgba(255,255,255,0.1);
    color: #7c6aef;
    font-size: 11px;
    font-weight: 500;
    white-space: nowrap;
    pointer-events: none;
}
#vp-premiere-btn:hover .vp-premiere-tooltip {
    display: block;
}
