/* ==========================================================================
   CloudLearn LXP Enterprise Design System & Multi-View Styling
   ========================================================================== */

:root, html.light, body.light, body.light-theme {
    /* Color Palette - Light Mode Default */
    --bg-base: #f8fafc;
    --bg-surface: #ffffff;
    --bg-surface-hover: #f1f5f9;
    --bg-card: #ffffff;
    --bg-elevated: #ffffff;
    --bg-hover: #f1f5f9;
    --border-color: #cbd5e1;
    --border-highlight: #94a3b8;
    
    --text-primary: #0f172a;
    --text-main: #0f172a;
    --text-secondary: #334155;
    --text-muted: #64748b;
    
    /* Brand & Accent Colors */
    --brand-primary: #4f46e5;
    --brand-primary-hover: #4338ca;
    --brand-gradient: linear-gradient(135deg, #6366f1 0%, #a855f7 100%);
    --brand-security: #0284c7;
    
    --accent-success: #059669;
    --accent-warning: #d97706;
    --accent-danger: #dc2626;
    --accent-info: #0891b2;
    --accent-xp: #d97706;
    --accent-paid: #db2777;
    
    /* Spacing & Radii */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-full: 9999px;
    
    --shadow-subtle: 0 4px 12px rgba(15, 23, 42, 0.06);
    --shadow-glow: 0 0 25px rgba(99, 102, 241, 0.15);
    
    --header-height: 64px;
    --footer-height: 76px;
    --sidebar-width: 320px;
    
    --font-main: 'Inter', system-ui, -apple-system, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
}

html.dark, body.dark, body.dark-theme {
    /* Color Palette - Dark Mode Override */
    --bg-base: #090d16;
    --bg-surface: #151d30;
    --bg-surface-hover: #1e293b;
    --bg-card: #1e293b;
    --bg-elevated: #1e293b;
    --bg-hover: #1e293b;
    --border-color: #243049;
    --border-highlight: #3b4d71;
    
    --text-primary: #f8fafc;
    --text-main: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    
    --shadow-subtle: 0 4px 12px rgba(0, 0, 0, 0.3);
    --shadow-glow: 0 0 25px rgba(99, 102, 241, 0.3);
}

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

html, body {
    font-family: var(--font-main);
    background-color: var(--bg-base);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    height: auto;
    width: 100%;
    overflow-x: hidden;
    overflow-y: auto;
}

.app-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    width: 100%;
}

.view-container {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.view-container.hidden {
    display: none !important;
}

/* Custom Scrollbars */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: var(--radius-full);
}
::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* ==========================================================================
   Header Bar & View Navigation Switcher
   ========================================================================== */
.top-header {
    height: var(--header-height);
    background-color: var(--bg-surface);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    z-index: 30;
}

.header-left, .header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

/* Profile Dropdown */
.profile-dropdown-container {
    position: relative;
    display: inline-block;
}

.profile-avatar-btn {
    background: var(--bg-hover);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    width: auto;
    height: 36px;
    padding: 0 12px;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}

.profile-avatar-btn:hover {
    background: var(--bg-elevated);
    border-color: var(--border-highlight);
}

.profile-dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: var(--bg-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
    min-width: 180px;
    display: flex;
    flex-direction: column;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 1000;
}

.profile-dropdown-container:hover .profile-dropdown-menu,
.profile-dropdown-container:focus-within .profile-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.profile-dropdown-menu a {
    color: var(--text-primary);
    text-decoration: none;
    padding: 10px 16px;
    font-size: 13px;
    transition: background 0.2s;
}

.profile-dropdown-menu a:hover {
    background: var(--bg-hover);
}

.profile-dropdown-menu .dropdown-divider {
    height: 1px;
    background: var(--border-color);
    margin: 4px 0;
}

.profile-dropdown-menu a.danger-link {
    color: var(--accent-danger);
}

/* Logo */
.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-right: 12px;
}

.logo-badge {
    background: var(--brand-gradient);
    color: #fff;
    font-size: 11px;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 4px;
}

.logo-title {
    font-weight: 800;
    font-size: 18px;
    background: var(--brand-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* View Switcher Tabs */
.header-nav-group {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-left: 20px;
}

.home-nav-container {
    background-color: var(--bg-elevated);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 4px;
    display: flex;
    align-items: center;
}

.view-nav-switcher {
    display: flex;
    gap: 4px;
    background-color: var(--bg-hover);
    padding: 4px;
    border-radius: 8px;
}

.view-nav-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.view-nav-btn:hover {
    color: var(--text-primary);
    background-color: var(--bg-surface-hover);
}

.view-nav-btn.active {
    background-color: var(--brand-primary);
    color: #fff;
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.4);
}

.user-stats {
    display: flex;
    align-items: center;
    gap: 14px;
    background-color: var(--bg-base);
    padding: 6px 14px;
    border-radius: var(--radius-full);
    border: 1px solid var(--border-color);
    font-size: 13px;
}

.stat-item { display: flex; align-items: center; gap: 6px; }
.stat-icon.xp { color: var(--accent-xp); }
.stat-icon.streak { color: var(--accent-danger); }

.user-tier-badge {
    background: rgba(236, 72, 153, 0.15);
    color: var(--accent-paid);
    border: 1px solid rgba(236, 72, 153, 0.3);
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: var(--radius-full);
}

.user-tier-badge.pro {
    background: rgba(16, 185, 129, 0.15);
    color: var(--accent-success);
    border-color: rgba(16, 185, 129, 0.3);
}

/* ==========================================================================
   VIEW 1: Marketplace Catalog / Home Page
   ========================================================================== */
.hero-banner {
    background: var(--bg-surface-low, #f1f5f9);
    padding: 36px 20px;
    text-align: center;
    border-bottom: 1px solid var(--border-color, #cbd5e1);
    display: flex;
    justify-content: center;
    position: relative;
    z-index: 1;
}

.hero-banner-content {
    max-width: 800px;
}

.hero-badge {
    background: rgba(124, 58, 237, 0.1);
    color: var(--brand-tertiary, #7c3aed);
    border: 1px solid rgba(124, 58, 237, 0.2);
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 12px;
    display: inline-block;
}

.hero-heading {
    font-size: 32px;
    font-weight: 800;
    margin: 12px 0;
    color: var(--text-primary, #0f172a);
    background: none;
    -webkit-background-clip: unset;
    -webkit-text-fill-color: initial;
}

.hero-subtext {
    font-size: 15px;
    color: var(--text-secondary, #334155);
    margin-bottom: 24px;
    max-width: 650px;
    margin-left: auto;
    margin-right: auto;
}

.hero-search-bar {
    display: flex;
    align-items: center;
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    padding: 4px 8px 4px 16px;
    gap: 10px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-glow);
}

.hero-search-bar input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 14px;
    outline: none;
}

.search-btn {
    background: var(--brand-gradient);
    color: #fff;
    border: none;
    padding: 10px 24px;
    border-radius: var(--radius-full);
    font-weight: 700;
    cursor: pointer;
}

.category-pills {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
}

.cat-pill {
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 6px 14px;
    border-radius: var(--radius-full);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
}

.cat-pill.active, .cat-pill:hover {
    background-color: var(--brand-primary);
    color: #fff;
    border-color: var(--brand-primary);
}

/* Course Grid */
.section-container {
    padding: 0 48px;
    margin-bottom: 60px;
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
    width: 100%;
}

.section-header {
    margin-bottom: 32px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 20px;
}

.course-status-tabs {
    display: flex;
    gap: 4px;
    background: var(--bg-hover);
    padding: 4px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.status-tab-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.status-tab-btn.active {
    background: var(--bg-elevated);
    color: var(--text-primary);
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.status-tab-btn:hover:not(.active) {
    color: var(--text-primary);
}

.section-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
}

.section-subtitle {
    font-size: 14px;
    color: var(--text-secondary);
}

/* Secondary Actions for Completed Courses */
.completed-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}

.completed-actions button {
    flex: 1;
    background: var(--bg-hover);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 8px 4px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;
}

.completed-actions button:hover {
    background: var(--bg-elevated);
    border-color: var(--brand-primary);
    color: var(--brand-primary);
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
    gap: 24px;
}

.path-card {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    cursor: pointer;
    transition: all 0.25s ease;
    display: flex;
    flex-direction: column;
}

.path-card:hover {
    transform: translateY(-4px);
    border-color: var(--brand-primary);
    box-shadow: var(--shadow-glow);
}

.path-card-image {
    height: 160px;
    background-size: cover;
    background-position: center;
    position: relative;
    padding: 12px;
}

.card-badge {
    position: absolute;
    top: 12px; right: 12px;
    font-size: 10px;
    font-weight: 800;
    padding: 4px 8px;
    border-radius: var(--radius-full);
}

.card-badge.paid { background-color: var(--accent-paid); color: #fff; }
.card-badge.free { background-color: var(--accent-success); color: #fff; }

.path-card-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.card-category {
    font-size: 10px;
    font-weight: 800;
    color: var(--brand-primary);
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.card-title {
    font-size: 16px;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 8px;
}

.card-desc {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 20px;
    flex: 1;
}

.card-footer-meta {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: var(--text-muted);
    border-top: 1px solid var(--border-color);
    padding-top: 12px;
}

/* ==========================================================================
   VIEW 2 & 3: Path & Course Detail Pages
   ========================================================================== */
.page-stage-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 24px;
    width: 100%;
}

.path-hero-header, .course-header-banner {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 36px;
    margin-bottom: 32px;
    display: flex;
    justify-content: space-between;
    gap: 32px;
}

.path-hero-content { flex: 1; }

.path-main-title {
    font-size: 30px;
    font-weight: 800;
    margin: 12px 0;
    line-height: 1.2;
}

.path-description {
    font-size: 15px;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.path-meta-row {
    display: flex;
    gap: 20px;
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.path-action-btns { display: flex; gap: 12px; }

.primary-cta-btn {
    background: var(--brand-gradient);
    color: #fff;
    border: none;
    padding: 12px 28px;
    border-radius: var(--radius-full);
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
}

.primary-cta-btn.large { padding: 16px 36px; font-size: 16px; }
.primary-cta-btn.full-width { width: 100%; text-align: center; }

.secondary-cta-btn {
    background-color: var(--bg-surface-hover);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    padding: 12px 24px;
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
}

.path-badge-card {
    background: rgba(99, 102, 241, 0.1);
    border: 1px dashed var(--brand-primary);
    border-radius: var(--radius-md);
    padding: 24px;
    width: 260px;
    text-align: center;
}

.badge-icon-circle { font-size: 36px; margin-bottom: 12px; }

.path-courses-list { display: flex; flex-direction: column; gap: 16px; }

.path-course-row {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 20px;
    cursor: pointer;
    transition: border-color 0.2s;
}

.path-course-row:hover { border-color: var(--brand-primary); }

.row-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--bg-base);
    color: var(--brand-primary);
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
}

.row-details { flex: 1; }
.row-details h3 { font-size: 16px; font-weight: 700; margin-bottom: 4px; }
.row-details p { font-size: 13px; color: var(--text-secondary); margin-bottom: 6px; }
.row-meta { font-size: 11px; color: var(--text-muted); }

.row-cta-btn {
    background-color: var(--bg-surface-hover);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 8px 16px;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 13px;
}

.course-body-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
}

.syllabus-module-card {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-bottom: 16px;
    cursor: pointer;
}

.syllabus-module-card:hover { border-color: var(--brand-primary); }

.mod-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.mod-num { font-size: 11px; font-weight: 800; color: var(--brand-primary); }
.mod-time { font-size: 12px; color: var(--text-muted); }

.enroll-box {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
}

.price-header { font-size: 18px; font-weight: 800; margin-bottom: 16px; }
.features-list { display: flex; flex-direction: column; gap: 10px; margin-top: 20px; font-size: 13px; color: var(--text-secondary); }

/* ==========================================================================
   VIEW 4: Module Pre-Learning Overview Page
   ========================================================================== */
.module-intro-card {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 40px;
}

.info-grid-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin: 32px 0;
}

.info-tile {
    background-color: var(--bg-base);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px;
    display: flex;
    flex-direction: column;
}

.info-label { font-size: 11px; color: var(--text-muted); text-transform: uppercase; font-weight: 700; }
.info-val { font-size: 15px; font-weight: 700; color: var(--text-primary); margin-top: 4px; }

.objectives-box {
    background-color: var(--bg-base);
    border-radius: var(--radius-md);
    padding: 24px;
    margin-bottom: 32px;
}

.objectives-box h3 { margin-bottom: 12px; font-size: 16px; }

/* ==========================================================================
   VIEW 5: Interactive Player (Full Height Sidebar & Stage Wrapper)
   ========================================================================== */
.player-layout {
    display: flex;
    flex: 1;
    min-height: calc(100vh - var(--header-height, 64px));
    position: relative;
    align-items: stretch;
    background-color: var(--bg-surface);
}

/* Sidebar in Player Layout - Fully Expanded Without Inner Frame Scrollbars */
.sidebar {
    width: var(--sidebar-width);
    height: auto;
    min-height: 100%;
    background-color: var(--bg-surface);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    z-index: 10;
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
    background-color: var(--bg-surface-low, #f8fafc);
}

html.dark .sidebar-header {
    background-color: rgba(15, 23, 42, 0.6);
}

.course-tag {
    font-size: 10px;
    font-weight: 800;
    color: var(--brand-primary);
    letter-spacing: 1px;
}

.course-title {
    font-size: 15px;
    font-weight: 800;
    color: var(--text-primary, #0f172a);
    line-height: 1.3;
    margin: 4px 0 12px 0;
}

.progress-bar-wrapper { margin-bottom: 12px; }
.progress-info { display: flex; justify-content: space-between; font-size: 12px; color: var(--text-secondary, #475569); margin-bottom: 6px; font-weight: 600; }

.progress-bar-track {
    height: 6px;
    background-color: var(--border-color, #e2e8f0);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    background: var(--brand-gradient);
    border-radius: var(--radius-full);
}

.sidebar-search input {
    width: 100%;
    background-color: var(--bg-base, #ffffff);
    border: 1px solid var(--border-color, #cbd5e1);
    border-radius: var(--radius-md);
    padding: 8px 12px;
    color: var(--text-primary, #0f172a);
    font-size: 13px;
    outline: none;
}

.sidebar-search input:focus { border-color: var(--brand-primary); }

.sidebar-nav {
    flex: 1;
    overflow: visible;
    padding: 16px;
}

/* Module Section Header in Sidebar */
.module-section-header {
    font-size: 11px;
    font-weight: 800;
    color: var(--brand-primary, #4338ca);
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-top: 16px;
    margin-bottom: 10px;
    padding-left: 6px;
}

.module-section-header:first-child { margin-top: 0; }

/* Topic Item List in Sidebar */
.topic-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 12px;
}

.topic-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    border-radius: var(--radius-md);
    color: #1e293b; /* High contrast dark text for light mode */
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.2s ease;
    background-color: transparent;
}

.topic-item:hover {
    background-color: #f1f5f9;
    color: #0f172a;
}

.topic-item.active {
    background-color: #e0e7ff;
    color: #4338ca;
    border-color: #c7d2fe;
    font-weight: 800;
}

html.dark .topic-item {
    color: #cbd5e1;
}

html.dark .topic-item:hover {
    background-color: rgba(255, 255, 255, 0.08);
    color: #f8fafc;
}

html.dark .topic-item.active {
    background-color: rgba(99, 102, 241, 0.25);
    color: #818cf8;
    border-color: rgba(99, 102, 241, 0.4);
}

.topic-item-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.status-icon {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 800;
}

.status-icon.completed {
    color: var(--accent-success);
    background-color: rgba(16, 185, 129, 0.15);
}

.status-icon.locked { color: var(--accent-paid); }
.status-icon.current { color: var(--brand-primary); }

/* Stage Wrapper (Stage + Footer right of sidebar) */
.stage-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
    position: relative;
}

/* Stage Area in Player - 180px EXTRA BOTTOM PADDING prevents footer overlap! */
.content-stage {
    flex: 1;
    overflow-y: auto;
    padding: 36px 48px 180px 48px; /* Generous 180px bottom padding! */
    background-color: var(--bg-base);
    display: flex;
    justify-content: center;
}

.stage-container {
    width: 100%;
    max-width: 860px;
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.stage-container > * {
    flex-shrink: 0;
}

.stage-bottom-spacer {
    height: 120px;
    width: 100%;
    display: block;
}

/* ==========================================================================
   15 WEB PARTS CATALOG STYLING
   ========================================================================== */

/* Web Part 1: Hero */
.webpart-hero {
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 24px;
}

.hero-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    font-size: 12px;
}

.hero-type-pill {
    background-color: var(--bg-surface-hover);
    color: var(--text-secondary);
    padding: 4px 10px;
    border-radius: var(--radius-full);
    font-weight: 600;
}

.hero-xp { color: var(--accent-xp); font-weight: 700; }
.hero-title { font-size: 32px; font-weight: 800; line-height: 1.2; margin-bottom: 12px; }
.hero-summary { font-size: 16px; color: var(--text-secondary); }

/* Web Part 2: Text */
.webpart-text p {
    font-size: 15px;
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.7;
}

.webpart-text h3 {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 24px 0 12px 0;
}

.bullet-list {
    list-style: none;
    margin: 16px 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.bullet-list li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 15px;
    color: var(--text-secondary);
}

.bullet-icon { color: var(--brand-primary); margin-top: 4px; flex-shrink: 0; }

/* Web Part 3 & 4: Split Image & Text (Left/Right) */
.webpart-split-container {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
}

.split-image-side {
    height: 100%;
    min-height: 240px;
    background-size: cover;
    background-position: center;
}

.split-text-side {
    padding: 32px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.split-text-side h3 {
    font-size: 20px;
    font-weight: 800;
    margin-bottom: 12px;
}

.split-text-side p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Web Part 5: Media Embed */
.webpart-media {
    background-color: #000;
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-subtle);
}

.video-container {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 */
    height: 0;
    background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 100%);
}

.video-placeholder {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    color: #fff;
    cursor: pointer;
    background: radial-gradient(circle at center, rgba(99, 102, 241, 0.3) 0%, transparent 70%);
}

.play-btn-circle {
    width: 64px;
    height: 64px;
    background: var(--brand-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-glow);
}

/* Web Part 6: Flip Cards */
.webpart-flipcards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
}

.flip-card {
    perspective: 1000px;
    height: 200px;
    cursor: pointer;
}

.flip-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.6s ease;
    transform-style: preserve-3d;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-subtle);
}

.flip-card.flipped .flip-card-inner {
    transform: rotateY(180deg);
}

.flip-card-front, .flip-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: var(--radius-md);
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: var(--bg-surface);
}

.flip-card-front {
    font-weight: 700;
    font-size: 15px;
    color: var(--text-primary);
}

.flip-card-back {
    background-color: #1e1b4b;
    color: #e0e7ff;
    transform: rotateY(180deg);
    font-size: 14px;
    border: 1px solid var(--brand-primary);
}

.flip-icon {
    position: absolute;
    bottom: 12px; right: 12px;
    font-size: 12px;
    color: var(--text-muted);
}

/* Web Part 7: Tabbed Container (FIXED STYLING - NO LEAKING BORDER LINES) */
.webpart-tab-container {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.tab-header-nav {
    display: flex;
    background-color: var(--bg-base);
    padding: 8px 8px 0 8px;
    gap: 6px;
    border-bottom: 1px solid var(--border-color);
}

.tab-nav-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: 10px 18px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    border-radius: var(--radius-sm) var(--radius-sm) 0 0;
    transition: all 0.2s ease;
}

.tab-nav-btn.active {
    color: #ffffff;
    background-color: var(--brand-primary);
}

.tab-pane-content {
    padding: 24px;
    display: none;
}

.tab-pane-content.active {
    display: block;
}

/* Web Part 8: Callouts */
.webpart-callout {
    padding: 16px 20px;
    border-radius: var(--radius-md);
    border-left: 4px solid var(--brand-primary);
    background-color: rgba(99, 102, 241, 0.08);
    display: flex;
    gap: 14px;
}

.webpart-callout.tip { border-left-color: var(--accent-success); background-color: rgba(16, 185, 129, 0.08); }
.webpart-callout.warning { border-left-color: var(--accent-warning); background-color: rgba(245, 158, 11, 0.08); }

.callout-content h4 { font-size: 14px; font-weight: 700; margin-bottom: 4px; }
.callout-content p { font-size: 14px; color: var(--text-secondary); }

/* Web Part 9: Code Sandbox */
.webpart-code {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
}

/* Web Part 10: Actionable Checklist */
.webpart-checklist {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 24px;
}

.checklist-items {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 16px;
}

.checklist-item {
    display: flex;
    align-items: center;
    gap: 12px;
    background-color: var(--bg-base);
    border: 1px solid var(--border-color);
    padding: 12px 16px;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 14px;
}

.checklist-item.checked {
    border-color: var(--accent-success);
    color: var(--accent-success);
    background-color: rgba(16, 185, 129, 0.08);
}

/* Web Part 11: Quiz */
.webpart-quiz {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
}

.quiz-header { font-size: 11px; font-weight: 800; color: var(--brand-primary); margin-bottom: 12px; letter-spacing: 1px; }
.quiz-question { font-size: 18px; font-weight: 700; margin-bottom: 16px; }

.quiz-options { display: flex; flex-direction: column; gap: 10px; margin-bottom: 20px; }

.quiz-option {
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background-color: var(--bg-base);
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
}

.quiz-option:hover { border-color: var(--brand-primary); background-color: var(--bg-surface-hover); }
.quiz-option.selected { border-color: var(--brand-primary); background-color: rgba(99, 102, 241, 0.15); }

.submit-quiz-btn {
    background: var(--brand-gradient);
    color: #fff;
    border: none;
    padding: 10px 24px;
    border-radius: var(--radius-md);
    font-weight: 700;
    cursor: pointer;
}

/* Web Part 12: Accordion / FAQ */
.webpart-accordion-card {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.accordion-item {
    border-bottom: 1px solid var(--border-color);
}

.accordion-item:last-child { border-bottom: none; }

.accordion-header {
    padding: 16px 20px;
    font-weight: 700;
    font-size: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.accordion-header:hover { background-color: var(--bg-surface-hover); }

.accordion-content {
    display: none;
    padding: 16px 20px 20px 20px;
    font-size: 14px;
    color: var(--text-secondary);
    border-top: 1px solid var(--border-color);
    background-color: var(--bg-base);
}

.accordion-item.open .accordion-content { display: block; }

/* Web Part 13: KPI Metrics Bar */
.webpart-kpi-card {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
}

.kpi-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-top: 16px;
}

.kpi-box {
    background-color: var(--bg-base);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px;
    text-align: center;
}

.kpi-number {
    font-size: 26px;
    font-weight: 800;
    color: var(--brand-primary);
}

.kpi-label {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 4px;
}

/* Web Part 14: Contact Banner */
.webpart-contact-banner {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.contact-btn {
    background-color: var(--brand-security);
    color: #fff;
    border: none;
    padding: 10px 24px;
    border-radius: var(--radius-full);
    font-weight: 700;
    cursor: pointer;
}

/* Web Part 15: Paywall Lock Card */
.webpart-paywall-card {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.9) 0%, rgba(15, 23, 42, 0.95) 100%);
    border: 1px solid rgba(236, 72, 153, 0.3);
    border-radius: var(--radius-lg);
    padding: 40px;
    text-align: center;
}

.paywall-icon {
    width: 56px; height: 56px;
    background: rgba(236, 72, 153, 0.15);
    color: var(--accent-paid);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 16px auto; font-size: 24px;
}

.paywall-title { font-size: 24px; font-weight: 800; margin-bottom: 8px; }
.paywall-desc { color: var(--text-secondary); max-width: 500px; margin: 0 auto 24px auto; font-size: 14px; }

.unlock-trigger-btn {
    background: linear-gradient(135deg, #ec4899 0%, #a855f7 100%);
    color: #fff; border: none; padding: 12px 28px; border-radius: var(--radius-full); font-weight: 700; cursor: pointer;
}

/* ==========================================================================
   Right-Aligned Player Flow Footer & Toast Alert
   ========================================================================== */
.flow-footer {
    height: var(--footer-height);
    background-color: var(--bg-surface);
    border-top: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
    z-index: 30;
}

.completion-toast {
    background-color: rgba(16, 185, 129, 0.15);
    color: var(--accent-success);
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 8px 16px;
    border-radius: var(--radius-full);
    font-size: 13px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
    animation: toastFadeIn 0.3s ease;
}

.completion-toast.hidden { display: none; }

@keyframes toastFadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

.footer-flow-controls {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-left: auto;
}

.nav-flow-btn {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    color: #0f172a !important;
    padding: 10px 24px;
    border-radius: var(--radius-full);
    display: inline-flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 13px;
    font-weight: 700;
}

.nav-flow-btn:hover:not(:disabled) {
    background-color: #f1f5f9 !important;
    border-color: #6366f1 !important;
    color: #4338ca !important;
}

.nav-flow-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.nav-flow-btn.large-continue {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%) !important;
    border: 1px solid #4338ca !important;
    color: #ffffff !important;
    padding: 12px 24px !important;
    border-radius: 16px !important;
    font-weight: 800;
    box-shadow: 0 6px 18px rgba(79, 70, 229, 0.35) !important;
    height: auto !important;
    min-height: 52px !important;
    max-width: 580px !important;
    white-space: normal !important;
    word-break: break-word !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.nav-flow-btn.large-continue * {
    color: #ffffff !important;
}

.nav-flow-btn.large-continue:hover {
    background: linear-gradient(135deg, #4338ca 0%, #6d28d9 100%) !important;
    color: #ffffff !important;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(67, 56, 202, 0.45) !important;
}

html.dark .nav-flow-btn {
    background: #1e293b;
    border-color: #334155;
    color: #f8fafc !important;
}

html.dark .nav-flow-btn:hover:not(:disabled) {
    background-color: #334155 !important;
    border-color: #818cf8 !important;
    color: #ffffff !important;
}

html.dark .nav-flow-btn.large-continue {
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%) !important;
    border: none !important;
    color: #ffffff !important;
}

html.dark .nav-flow-btn.large-continue:hover {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%) !important;
    color: #ffffff !important;
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.5) !important;
}

.btn-text-group { display: flex; flex-direction: column; }
.btn-text-group.text-right { text-align: right; }
.btn-subtext { font-size: 10px; text-transform: uppercase; letter-spacing: 0.5px; opacity: 0.8; }
.btn-maintext { font-size: 13px; font-weight: 700; }

/* Custom Notification Modal */
.notification-card {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 36px;
    text-align: center;
    max-width: 480px;
    width: 90%;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
    animation: modalPopIn 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes modalPopIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.notification-icon-circle {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background-color: rgba(99, 102, 241, 0.15);
    color: var(--brand-primary);
    font-size: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px auto;
}

.notification-title { font-size: 20px; font-weight: 800; margin-bottom: 10px; }
.notification-message { font-size: 14px; color: var(--text-secondary); line-height: 1.6; }

/* Modals */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
}

.modal-overlay.hidden { display: none; }

.modal-card {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 580px;
    padding: 32px;
    position: relative;
    box-shadow: var(--shadow-subtle);
}

.close-modal-btn {
    position: absolute;
    top: 16px; right: 20px;
    background: transparent; border: none;
    font-size: 24px; color: var(--text-muted); cursor: pointer;
}

.modal-badge { font-size: 10px; font-weight: 800; color: var(--brand-primary); letter-spacing: 1px; margin-bottom: 6px; }
.modal-title { font-size: 24px; font-weight: 800; margin-bottom: 8px; }
.modal-subtitle { font-size: 14px; color: var(--text-secondary); margin-bottom: 24px; }

.form-group { margin-bottom: 20px; }
.form-group label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; }
.form-control {
    width: 100%;
    background-color: var(--bg-base);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 10px 14px;
    color: var(--text-primary);
    font-size: 14px;
    outline: none;
}

.pricing-options { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

.price-card {
    background-color: var(--bg-base);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    display: flex; flex-direction: column; justify-content: space-between; position: relative;
}

.price-card.featured { border-color: var(--brand-primary); box-shadow: var(--shadow-glow); }

.best-value-pill {
    position: absolute; top: -10px; right: 16px;
    background: var(--brand-gradient); color: #fff; font-size: 9px; font-weight: 800; padding: 2px 8px; border-radius: var(--radius-full);
}

.price-card h3 { font-size: 16px; font-weight: 700; margin-bottom: 8px; }
.price { font-size: 28px; font-weight: 800; margin-bottom: 16px; }
.price span { font-size: 13px; font-weight: 400; color: var(--text-muted); }

.price-card ul { list-style: none; font-size: 12px; color: var(--text-secondary); display: flex; flex-direction: column; gap: 8px; margin-bottom: 20px; }

.upgrade-cta-btn { border: none; padding: 10px; border-radius: var(--radius-md); font-weight: 700; cursor: pointer; font-size: 13px; }
.upgrade-cta-btn.primary { background: var(--brand-gradient); color: #fff; }
.upgrade-cta-btn.secondary { background-color: var(--bg-surface-hover); color: var(--text-primary); }


/* ==========================================================================
   Mobile Responsive Adjustments
   ========================================================================== */
@media (max-width: 768px) {
    /* Header layout */
    .top-header {
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        height: 60px !important;
        padding: 0 16px !important;
        gap: 8px !important;
    }
    .header-nav-group {
        display: none !important;
    }
    .view-nav-switcher {
        display: none !important;
    }
    .header-right {
        justify-content: flex-end !important;
        width: auto !important;
        gap: 8px !important;
    }
    
    /* Layout containers */
    .section-container {
        padding: 0 16px;
        margin-bottom: 32px;
    }
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    .course-status-tabs {
        width: 100%;
    }
    .status-tab-btn {
        flex: 1;
        text-align: center;
    }
    .page-stage-container {
        padding: 24px 16px;
    }

    /* Course Detail & Path Views */
    .path-hero-header, .course-header-banner {
        flex-direction: column;
        padding: 24px;
        gap: 16px;
    }
    .course-body-grid {
        grid-template-columns: 1fr;
    }
    .info-grid-row {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .path-course-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    /* Mobile Player Layout - Full Width Clean Stage with Off-Canvas Drawer */
    .player-layout {
        flex-direction: column !important;
        position: relative !important;
        width: 100% !important;
        min-height: calc(100vh - 64px) !important;
    }
    .mobile-player-bar {
        display: flex !important;
    }
    .sidebar {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        bottom: 0 !important;
        width: min(88vw, 350px) !important;
        height: 100vh !important;
        max-height: 100vh !important;
        background-color: #ffffff !important;
        z-index: 99999 !important;
        box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.45) !important;
        transform: translateX(-100%) !important;
        transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1) !important;
        overflow-y: auto !important;
        border-right: 1px solid var(--border-color) !important;
        border-bottom: none !important;
        padding-bottom: 40px !important;
    }
    html.dark .sidebar {
        background-color: #0f172a !important;
    }
    .sidebar.mobile-open {
        transform: translateX(0) !important;
    }
    .sidebar-backdrop {
        position: fixed !important;
        inset: 0 !important;
        background-color: rgba(15, 23, 42, 0.65) !important;
        backdrop-filter: blur(4px) !important;
        -webkit-backdrop-filter: blur(4px) !important;
        z-index: 99998 !important;
        display: none;
    }
    .sidebar-backdrop.active {
        display: block !important;
    }
    .stage-wrapper {
        width: 100% !important;
        flex: 1 !important;
        overflow: visible !important;
        position: relative !important;
    }
    .content-stage {
        padding: 16px 16px 140px 16px !important;
        overflow: visible !important;
        width: 100% !important;
        max-width: 100% !important;
    }
    
    /* Footer Flow Controls on Mobile */
    .flow-footer {
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        z-index: 800 !important;
        background: rgba(255, 255, 255, 0.95) !important;
        backdrop-filter: blur(12px) !important;
        -webkit-backdrop-filter: blur(12px) !important;
        border-top: 1px solid var(--border-color) !important;
        padding: 10px 16px !important;
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 8px !important;
        height: auto !important;
        box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.05) !important;
    }
    html.dark .flow-footer {
        background: rgba(15, 23, 42, 0.95) !important;
    }
    .footer-flow-controls {
        width: 100% !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 8px !important;
    }
    .nav-flow-btn {
        padding: 10px 14px !important;
        font-size: 13px !important;
    }
    .nav-flow-btn.large-continue {
        flex: 1 !important;
    }
    
    .cards-grid {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   IMAGE LIGHTBOX MODAL & SPLIT IMAGE UNCROPPED VIEW & BUTTON TEXT WRAPPING
   ========================================================================== */
#image-lightbox-modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    background-color: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

#image-lightbox-modal.hidden {
    display: none !important;
}

.lightbox-content-card {
    position: relative;
    max-width: 92vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #0f172a;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.85);
    animation: lightboxPop 0.25s ease-out;
}

@keyframes lightboxPop {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

.lightbox-close-btn {
    position: absolute;
    top: -14px;
    right: -14px;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #ef4444;
    color: #ffffff;
    border: 2px solid #ffffff;
    font-size: 22px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
    z-index: 10;
}

.lightbox-close-btn:hover {
    background: #dc2626;
    transform: scale(1.1);
}

#lightbox-img {
    max-width: 88vw;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 8px;
}

.lightbox-caption-bar {
    margin-top: 12px;
    color: #f8fafc;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
}

/* Split Image Side Uncropped & Interactive */
.split-image-side {
    position: relative;
    min-height: 280px;
    background-size: contain !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
    background-color: var(--bg-surface-low, #f8fafc);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    overflow: hidden;
}

html.dark .split-image-side {
    background-color: rgba(15, 23, 42, 0.6);
}

.split-image-side:hover {
    transform: scale(1.015);
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.25);
}

.split-image-side::after {
    content: "🔍 Click to Enlarge";
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(15, 23, 42, 0.85);
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
    backdrop-filter: blur(4px);
    opacity: 0.9;
    transition: opacity 0.2s, background 0.2s;
}

.split-image-side:hover::after {
    opacity: 1;
    background: #4338ca;
}

/* Flow Footer Container & Controls */
.flow-footer {
    min-height: 80px !important;
    height: auto !important;
    padding: 12px 24px !important;
    overflow: visible !important;
}

.footer-flow-controls {
    display: flex !important;
    gap: 12px !important;
    align-items: center !important;
    justify-content: flex-end !important;
    margin-left: auto !important;
    max-width: 80% !important;
}

/* Button Text Group Wrapping */
.nav-flow-btn.large-continue {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%) !important;
    border: 1px solid #4338ca !important;
    color: #ffffff !important;
    padding: 10px 20px !important;
    border-radius: 12px !important;
    font-weight: 700;
    box-shadow: 0 4px 14px rgba(79, 70, 229, 0.35) !important;
    height: auto !important;
    min-height: 48px !important;
    max-width: 100% !important;
    white-space: normal !important;
    word-break: break-word !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.nav-btn-text-content {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    text-align: center !important;
    line-height: 1.25 !important;
    width: 100% !important;
    pointer-events: none !important;
}

.nav-btn-label {
    font-size: 10px !important;
    font-weight: 800 !important;
    letter-spacing: 0.08em !important;
    text-transform: uppercase !important;
    opacity: 0.9 !important;
    color: #ffffff !important;
    display: block !important;
    margin-bottom: 2px !important;
    line-height: 1.1 !important;
}

.nav-btn-title {
    font-size: 13px !important;
    font-weight: 700 !important;
    color: #ffffff !important;
    display: block !important;
    word-break: break-word !important;
    line-height: 1.3 !important;
}

