/**
 * Tamkeen Al-Roaya Master Coach Qualification Platform v3.0
 * Ultra-Premium Executive SaaS Stylesheet
 * Optimized for Arabic RTL, Dark/Light Mode, Interactive Dashboards & High-Fidelity Printing
 */

@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;500;600;700;800;900&family=Tajawal:wght@300;400;500;700;800;900&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
    /* Brand Colors - Tamkeen Al-Roaya */
    --brand-navy: #0B1B3D;
    --brand-navy-deep: #060E20;
    --brand-blue: #1D4ED8;
    --brand-blue-light: #3B82F6;
    --accent-cyan: #0284C7;
    --accent-cyan-light: #38BDF8;
    --status-emerald: #059669;
    --status-emerald-light: #10B981;
    --status-amber: #D97706;
    --status-amber-light: #F59E0B;
    --status-crimson: #DC2626;
    --status-crimson-light: #EF4444;
    --status-purple: #7C3AED;

    /* Theme Variables - Executive Light Default (Light Mode First) */
    --bg-page: #F8FAFC;
    --bg-surface: #FFFFFF;
    --bg-card: #FFFFFF;
    --bg-card-hover: #F8FAFC;
    --bg-input: #F1F5F9;
    --border-subtle: #E2E8F0;
    --border-accent: rgba(29, 78, 216, 0.25);
    --border-gold: rgba(217, 119, 6, 0.25);
    --border-emerald: rgba(5, 150, 105, 0.25);

    --text-primary: #0B1B3D;
    --text-secondary: #334155;
    --text-muted: #64748B;
    --text-gold: #B45309;
    --text-emerald: #047857;
    --text-cyan: #0284C7;

    --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06), 0 1px 2px rgba(15, 23, 42, 0.04);
    --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.07), 0 2px 4px -1px rgba(15, 23, 42, 0.04);
    --shadow-lg: 0 10px 15px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -2px rgba(15, 23, 42, 0.03);
    --shadow-glow-blue: 0 0 15px rgba(29, 78, 216, 0.15);
    --shadow-glow-emerald: 0 0 15px rgba(5, 150, 105, 0.15);

    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;

    --transition-fast: 0.15s ease;
    --transition-normal: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.4s cubic-bezier(0.4, 0, 0.2, 1);

    --font-sans: 'Tajawal', 'Cairo', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-heading: 'Cairo', 'Tajawal', sans-serif;
    --font-mono: 'JetBrains Mono', 'Cairo', monospace;
}

/* Dark Theme Variables (Activated via theme-dark) */
body.theme-dark {
    --bg-page: #070D18;
    --bg-surface: #0E1726;
    --bg-card: rgba(18, 30, 49, 0.85);
    --bg-card-hover: rgba(26, 42, 68, 0.95);
    --bg-input: #132238;
    --border-subtle: rgba(255, 255, 255, 0.08);
    --border-accent: rgba(59, 130, 246, 0.3);
    --border-gold: rgba(217, 119, 6, 0.3);
    --border-emerald: rgba(16, 185, 129, 0.3);

    --text-primary: #F8FAFC;
    --text-secondary: #94A3B8;
    --text-muted: #64748B;
    --text-gold: #FBBF24;
    --text-emerald: #34D399;
    --text-cyan: #38BDF8;

    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.4);
    --shadow-glow-blue: 0 0 20px rgba(37, 99, 235, 0.25);
    --shadow-glow-emerald: 0 0 20px rgba(16, 185, 129, 0.25);
}

/* Light Theme Variables (Default / Explicit theme-light) */
body.theme-light {
    --bg-page: #F8FAFC;
    --bg-surface: #FFFFFF;
    --bg-card: #FFFFFF;
    --bg-card-hover: #F8FAFC;
    --bg-input: #F1F5F9;
    --border-subtle: #E2E8F0;
    --border-accent: rgba(29, 78, 216, 0.25);
    --border-gold: rgba(217, 119, 6, 0.25);
    --border-emerald: rgba(5, 150, 105, 0.25);

    --text-primary: #0B1B3D;
    --text-secondary: #334155;
    --text-muted: #64748B;
    --text-gold: #B45309;
    --text-emerald: #047857;
    --text-cyan: #0284C7;

    --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06), 0 1px 2px rgba(15, 23, 42, 0.04);
    --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.07), 0 2px 4px -1px rgba(15, 23, 42, 0.04);
    --shadow-lg: 0 10px 15px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -2px rgba(15, 23, 42, 0.03);
    --shadow-glow-blue: 0 0 15px rgba(29, 78, 216, 0.15);
    --shadow-glow-emerald: 0 0 15px rgba(5, 150, 105, 0.15);
}

/* Global Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    direction: rtl;
    text-align: right;
    scroll-behavior: smooth;
    font-size: 16px;
    height: 100%;
    overflow-x: clip !important;
    position: static !important;
    scroll-padding-top: min(var(--total-sticky-offset, 94px), 25vh) !important;
}

body {
    font-family: var(--font-sans);
    background-color: var(--bg-page);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.6;
    overflow-x: clip !important;
    position: static !important;
    transition: background-color var(--transition-normal), color var(--transition-normal);
}

/* Typography Helpers */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.3;
    color: var(--text-primary);
}

a {
    color: var(--accent-cyan);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--brand-blue-light);
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    outline: none;
    background: transparent;
    transition: all var(--transition-fast);
    white-space: nowrap !important;
    flex-shrink: 0;
}

input, select, textarea {
    font-family: inherit;
    color: var(--text-primary);
    background-color: var(--bg-input);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    padding: 0.7rem 1.15rem;
    font-size: 0.95rem;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

select {
    white-space: nowrap;
    min-width: 170px;
    cursor: pointer;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--brand-blue);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2);
}

/* Top Executive Header & Sticky Offset System */
:root {
    --app-header-height: 74px;
    --coach-sticky-height: 0px;
    --total-sticky-offset: 94px;
}

/* Scroll target clearance for sticky headers & quick-nav bars across zoom levels */
section,
.section,
.tab-panel,
.card,
.card-panel,
.dashboard-card,
.table-container,
.coaches-table-card,
.admin-segmented-tabs,
.admin-tab-btn,
.section-header-wrap,
table,
tr,
th,
td,
button,
.btn,
.btn-xs,
.btn-icon-action,
input:not([type="hidden"]),
select,
textarea,
a[href] {
    scroll-margin-top: min(calc(var(--total-sticky-offset, 94px) + 20px), calc(100vh - var(--app-header-height, 74px) - 50px)) !important;
}

/* Reset scroll-margin inside modals so internal modal scrolling behaves cleanly */
.modal-overlay button,
.modal-overlay .btn,
.modal-overlay .btn-xs,
.modal-overlay .btn-icon-action,
.modal-overlay input,
.modal-overlay input:not([type="hidden"]),
.modal-overlay select,
.modal-overlay textarea,
.modal-overlay a,
.modal-overlay a[href],
.modal-overlay section,
.modal-overlay .card,
.modal-overlay div,
.modal-container button,
.modal-container .btn,
.modal-container .btn-xs,
.modal-container .btn-icon-action,
.modal-container input,
.modal-container input:not([type="hidden"]),
.modal-container select,
.modal-container textarea,
.modal-container a,
.modal-container a[href],
.modal-container section,
.modal-container .card,
.modal-container div,
.modal-dialog button,
.modal-dialog .btn,
.modal-dialog .btn-xs,
.modal-dialog .btn-icon-action,
.modal-dialog input,
.modal-dialog input:not([type="hidden"]),
.modal-dialog select,
.modal-dialog textarea,
.modal-dialog a,
.modal-dialog a[href],
.modal-dialog section,
.modal-dialog .card,
.modal-dialog div {
    scroll-margin-top: 8px !important;
    scroll-margin-bottom: 8px !important;
}

.app-header {
    background: var(--bg-surface);
    border-bottom: 1px solid var(--border-subtle);
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(16px);
    transition: all var(--transition-normal);
    width: 100%;
    box-sizing: border-box;
}

.header-inner {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0.75rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    box-sizing: border-box;
}

.brand-section {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    flex-shrink: 0;
    min-width: 0;
}

.brand-logo-img {
    height: 48px;
    width: auto;
    object-fit: contain;
    border-radius: var(--radius-sm);
    filter: drop-shadow(0 2px 6px rgba(0,0,0,0.2));
}

.brand-title-wrap {
    display: flex;
    flex-direction: column;
}

.brand-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.badge-version {
    font-size: 0.7rem;
    padding: 0.15rem 0.5rem;
    border-radius: var(--radius-full);
    background: linear-gradient(135deg, var(--brand-blue), var(--accent-cyan));
    color: #FFFFFF;
    font-weight: 600;
}

.brand-subtitle {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.brand-subtitle-dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--status-emerald);
}

/* Header Action Controls */
.header-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    justify-content: flex-end;
    flex-shrink: 0;
}

.role-switcher-box {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    background: var(--bg-input);
    padding: 0.45rem 1rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
    min-width: 290px;
    white-space: nowrap;
}

.role-label {
    font-size: 0.82rem;
    color: var(--text-secondary);
    white-space: nowrap;
    flex-shrink: 0;
}

.role-select {
    background: transparent;
    border: none;
    padding: 0.25rem 0.5rem;
    font-weight: 700;
    font-size: 0.88rem;
    color: var(--brand-blue-light);
    cursor: pointer;
    min-width: 195px;
    white-space: nowrap;
}

.role-select:focus {
    box-shadow: none;
}

.btn-icon-action {
    width: 38px;
    height: 38px;
    min-width: 38px;
    min-height: 38px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-input);
    border: 1px solid var(--border-subtle);
    color: var(--text-secondary);
    cursor: pointer;
    pointer-events: auto !important;
    flex-shrink: 0;
    position: relative;
    z-index: 2;
}

.btn-icon-action:hover {
    background: var(--bg-card-hover);
    color: var(--text-primary);
    border-color: var(--border-accent);
}

/* Header Mode Switcher Toggle */
.mode-toggle-group {
    display: inline-flex;
    align-items: center;
    background: var(--bg-input);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-full);
    padding: 3px;
    gap: 3px;
}

body.theme-dark .mode-toggle-group {
    background: rgba(255, 255, 255, 0.08);
}

.mode-toggle-btn {
    border: none;
    background: transparent;
    color: var(--text-secondary);
    padding: 0.35rem 0.85rem;
    font-size: 0.78rem;
    font-weight: 700;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap !important;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.mode-toggle-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.4);
}

.mode-toggle-btn.active.fresh {
    background: #059669;
    color: #FFFFFF;
    box-shadow: 0 1px 4px rgba(5, 150, 105, 0.3);
}

.mode-toggle-btn.active.demo {
    background: #1D4ED8;
    color: #FFFFFF;
    box-shadow: 0 1px 4px rgba(29, 78, 216, 0.3);
}

/* Executive Quick Summary Strip */
.quick-status-strip {
    background: linear-gradient(90deg, rgba(11, 27, 61, 0.95), rgba(15, 23, 42, 0.95));
    border-bottom: 1px solid var(--border-subtle);
    padding: 0.5rem 1.5rem;
}

.status-strip-inner {
    max-width: 1440px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.82rem;
}

.candidate-mini-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #F8FAFC;
    white-space: nowrap;
    flex-shrink: 0;
}

.candidate-mini-info strong,
.candidate-mini-info span {
    white-space: nowrap;
}

.candidate-avatar {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--brand-blue);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: bold;
    color: #FFFFFF;
    flex-shrink: 0;
}

.status-metrics-group {
    display: flex;
    align-items: center;
    gap: 1.35rem;
    flex-wrap: wrap;
}

.status-metric-pill {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    color: #CBD5E1;
    white-space: nowrap !important;
    flex-shrink: 0;
}

.status-metric-pill strong {
    color: #FFFFFF;
    font-family: var(--font-mono);
}

.status-metric-pill.emerald strong {
    color: var(--status-emerald-light);
}

.status-metric-pill.gold strong {
    color: var(--text-gold);
}

.ethics-pill-pass {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.4);
    color: var(--status-emerald-light);
    padding: 0.2rem 0.65rem;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 700;
}

/* Primary Navigation Bar (Tabs) */
.main-nav-bar {
    background: var(--bg-surface);
    border-bottom: 1px solid var(--border-subtle);
    overflow-x: auto;
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
    width: 100%;
    box-sizing: border-box;
}

body.role-participant .main-nav-bar {
    display: none !important;
}

/* Quick Status Strip Role Conditioning */
body.role-participant .status-metric-pill.pill-passive-hours,
body.role-participant .status-metric-pill.pill-passive-comps {
    display: none !important;
}

body:not(.role-participant) .pill-action-recordings,
body:not(.role-participant) .pill-action-tasks {
    display: none !important;
}

/* Participant View Clean Action Portal Overrides: Hide passive evaluation & reference noise */
body.role-participant #panel-rubrics,
body.role-participant #panel-competencies,
body.role-participant #panel-ethics,
body.role-participant #panel-labs,
body.role-participant #panel-report {
    display: none !important;
}

.nav-tabs-container {
    display: flex;
    align-items: center;
    width: max-content;
    min-width: 100%;
    gap: 0.35rem;
    padding: 0 1rem;
    box-sizing: border-box;
}

.nav-tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text-secondary);
    border-bottom: 3px solid transparent;
    white-space: nowrap;
    transition: all var(--transition-fast);
    cursor: pointer;
    pointer-events: auto;
    flex-shrink: 0;
    min-height: 44px;
    box-sizing: border-box;
}

.nav-tab-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.02);
}

.nav-tab-btn.active {
    color: var(--brand-blue-light);
    border-bottom-color: var(--brand-blue);
    background: rgba(37, 99, 235, 0.05);
}

.nav-tab-btn .tab-badge {
    font-size: 0.7rem;
    padding: 0.1rem 0.45rem;
    border-radius: var(--radius-full);
    background: var(--bg-input);
    color: var(--text-secondary);
    font-family: var(--font-mono);
}

.nav-tab-btn.active .tab-badge {
    background: var(--brand-blue);
    color: #FFFFFF;
}

/* Main Content Area */
.app-main-content {
    max-width: 1440px;
    margin: 0 auto;
    padding: 2rem 1.5rem 4rem;
    min-height: calc(100vh - 220px);
}

.tab-panel {
    display: none;
    animation: fadeIn var(--transition-normal);
}

.tab-panel.active {
    display: block;
}

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

/* Section Header Component */
.section-header-wrap {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.75rem;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.section-desc {
    font-size: 0.9rem;
    color: var(--text-secondary);
    max-width: 800px;
}

.section-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* Button Component Styles */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-weight: 600;
    padding: 0.65rem 1.45rem;
    border-radius: var(--radius-md);
    white-space: nowrap !important;
    flex-shrink: 0;
    font-family: inherit;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.btn-primary {
    background: linear-gradient(135deg, var(--brand-blue), #1E40AF);
    color: #FFFFFF;
    font-weight: 600;
    padding: 0.65rem 1.45rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    white-space: nowrap !important;
    flex-shrink: 0;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #2563EB, var(--brand-blue));
    box-shadow: var(--shadow-glow-blue);
    transform: translateY(-1px);
}

.btn-secondary {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    color: var(--text-primary);
    font-weight: 600;
    padding: 0.65rem 1.4rem;
    border-radius: var(--radius-md);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    white-space: nowrap !important;
    flex-shrink: 0;
}

.btn-secondary:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-accent);
}

.btn-emerald {
    background: linear-gradient(135deg, var(--status-emerald), #047857);
    color: #FFFFFF;
    font-weight: 600;
    padding: 0.65rem 1.45rem;
    border-radius: var(--radius-md);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    white-space: nowrap !important;
    flex-shrink: 0;
}

.btn-emerald:hover {
    background: linear-gradient(135deg, var(--status-emerald-light), var(--status-emerald));
    box-shadow: var(--shadow-glow-emerald);
}

.btn-amber {
    background: linear-gradient(135deg, var(--status-amber), #B45309);
    color: #FFFFFF;
    font-weight: 600;
    padding: 0.65rem 1.45rem;
    border-radius: var(--radius-md);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    white-space: nowrap !important;
    flex-shrink: 0;
}

.btn-sm {
    padding: 0.45rem 1.05rem;
    font-size: 0.84rem;
    border-radius: var(--radius-sm);
    white-space: nowrap !important;
    flex-shrink: 0;
}

/* Callout & Principle Banner */
.doctrine-callout-box {
    background: #FFFBEB;
    border: 1px solid #FDE68A;
    border-right: 5px solid var(--status-amber);
    border-radius: var(--radius-md);
    padding: 1.25rem 1.5rem;
    margin-bottom: 2rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    box-shadow: 0 1px 3px rgba(217, 119, 6, 0.08);
}

.doctrine-icon {
    color: var(--status-amber);
    font-size: 1.5rem;
    flex-shrink: 0;
    margin-top: 0.15rem;
}

.doctrine-content h4 {
    font-size: 1.05rem;
    font-weight: 800;
    color: #92400E;
    margin-bottom: 0.35rem;
}

.doctrine-content p {
    font-size: 0.9rem;
    color: #78350F;
    line-height: 1.6;
}

body.theme-dark .doctrine-callout-box {
    background: linear-gradient(135deg, rgba(11, 27, 61, 0.7), rgba(30, 41, 59, 0.7));
    border-color: var(--border-subtle);
    border-right-color: var(--status-amber);
}
body.theme-dark .doctrine-content h4 { color: var(--text-gold); }
body.theme-dark .doctrine-content p { color: var(--text-secondary); }

/* Dual Engine Dashboard Cards Grid */
.dual-engine-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

@media (max-width: 992px) {
    .dual-engine-grid {
        grid-template-columns: 1fr;
    }
}

.engine-card {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1.75rem;
    box-shadow: var(--shadow-md);
    backdrop-filter: blur(12px);
    position: relative;
    overflow: hidden;
    transition: transform var(--transition-normal), border-color var(--transition-normal);
}

.engine-card:hover {
    border-color: var(--border-accent);
}

.engine-card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    height: 4px;
}

.engine-card.quant::before {
    background: linear-gradient(90deg, var(--brand-blue), var(--accent-cyan));
}

.engine-card.competency::before {
    background: linear-gradient(90deg, var(--status-emerald), var(--text-gold));
}

.engine-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 1.25rem;
}

.engine-card-title {
    font-size: 1.25rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.engine-tag {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.25rem 0.65rem;
    border-radius: var(--radius-full);
}

.engine-tag.blue {
    background: rgba(37, 99, 235, 0.15);
    color: var(--brand-blue-light);
    border: 1px solid rgba(37, 99, 235, 0.3);
}

.engine-tag.emerald {
    background: rgba(16, 185, 129, 0.15);
    color: var(--status-emerald-light);
    border: 1px solid rgba(16, 185, 129, 0.3);
}

/* Engine Gauge Display */
.engine-gauge-wrap {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    padding: 1.25rem;
    background: var(--bg-surface);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
}

.radial-progress-box {
    position: relative;
    width: 100px;
    height: 100px;
    flex-shrink: 0;
}

.radial-progress-svg {
    transform: rotate(-90deg);
    width: 100px;
    height: 100px;
}

.radial-bg {
    stroke: var(--bg-input);
    stroke-width: 8;
    fill: none;
}

.radial-bar {
    stroke-width: 8;
    stroke-linecap: round;
    fill: none;
    transition: stroke-dashoffset 1s ease-in-out;
}

.radial-bar.blue {
    stroke: var(--brand-blue);
}

.radial-bar.emerald {
    stroke: var(--status-emerald);
}

.radial-center-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 1.25rem;
    font-weight: 800;
    font-family: var(--font-mono);
    color: var(--text-primary);
}

.gauge-details {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.gauge-big-stat {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--text-primary);
    font-family: var(--font-mono);
}

.gauge-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Engine Mini Stat Row */
.engine-mini-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 0.75rem;
}

.mini-stat-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    padding: 0.75rem 1rem;
    display: flex;
    flex-direction: column;
}

.mini-stat-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 0.2rem;
}

.mini-stat-val {
    font-size: 1.1rem;
    font-weight: 700;
    font-family: var(--font-mono);
    color: var(--text-primary);
}

.mini-stat-val.gold {
    color: var(--text-gold);
}

.mini-stat-val.emerald {
    color: var(--status-emerald-light);
}

.mini-stat-sub {
    font-size: 0.7rem;
    color: var(--text-secondary);
}

/* Ethics Independent Gate Banner */
.ethics-gate-banner {
    background: #ECFDF5;
    border: 1px solid #A7F3D0;
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1.5rem;
    box-shadow: 0 1px 3px rgba(5, 150, 105, 0.08);
}

.ethics-banner-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.ethics-shield-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(16, 185, 129, 0.2);
    border: 2px solid var(--status-emerald);
    color: #047857;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    flex-shrink: 0;
}

.ethics-banner-info h3 {
    font-size: 1.15rem;
    font-weight: 800;
    color: #065F46;
    margin-bottom: 0.2rem;
}

.ethics-banner-info p {
    font-size: 0.88rem;
    color: #047857;
}

.ethics-gate-action-btn {
    background: #FFFFFF;
    border: 1px solid #A7F3D0;
    padding: 0.65rem 1.45rem;
    min-width: 230px;
    border-radius: var(--radius-md);
    font-size: 0.88rem;
    font-weight: 700;
    color: #065F46;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    white-space: nowrap !important;
    flex-shrink: 0;
}

.ethics-gate-action-btn:hover {
    border-color: var(--status-emerald);
    background: #D1FAE5;
    color: #047857;
}

body.theme-dark .ethics-gate-banner {
    background: linear-gradient(135deg, rgba(220, 38, 38, 0.08), rgba(15, 23, 42, 0.9));
    border-color: rgba(220, 38, 38, 0.3);
}
body.theme-dark .ethics-shield-icon { color: var(--status-emerald-light); }
body.theme-dark .ethics-banner-info h3 { color: var(--text-primary); }
body.theme-dark .ethics-banner-info p { color: var(--text-secondary); }
body.theme-dark .ethics-gate-action-btn {
    background: var(--bg-card);
    border-color: var(--border-subtle);
    color: var(--text-primary);
}

/* Category Grid & Cards */
.cards-grid-4 {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
    gap: 1.25rem;
    margin-bottom: 2rem;
}

.cards-grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
    gap: 1.35rem;
    margin-bottom: 2rem;
}

.standard-card {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.standard-card:hover {
    border-color: var(--border-accent);
    transform: translateY(-2px);
}

.card-top-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.card-title-lg {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-primary);
}

.card-desc-sm {
    font-size: 0.82rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 1rem;
}

/* Progress Bar Component */
.progress-bar-wrap {
    width: 100%;
    height: 8px;
    background: var(--bg-input);
    border-radius: var(--radius-full);
    overflow: hidden;
    position: relative;
    margin: 0.5rem 0;
}

.progress-bar-fill {
    height: 100%;
    border-radius: var(--radius-full);
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-bar-fill.blue {
    background: linear-gradient(90deg, var(--brand-blue), var(--accent-cyan));
}

.progress-bar-fill.emerald {
    background: linear-gradient(90deg, #059669, #10B981);
}

.progress-bar-fill.gold {
    background: linear-gradient(90deg, #D97706, #F59E0B);
}

/* Data Tables */
.table-responsive-container {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    box-shadow: var(--shadow-sm);
    margin-bottom: 2rem;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    text-align: right;
    font-size: 0.88rem;
}

.data-table th {
    background: var(--bg-surface);
    color: var(--text-secondary);
    font-weight: 700;
    padding: 0.9rem 1.25rem;
    border-bottom: 1px solid var(--border-subtle);
    white-space: nowrap;
}

.data-table td {
    padding: 0.9rem 1.25rem;
    border-bottom: 1px solid var(--border-subtle);
    color: var(--text-primary);
    vertical-align: middle;
}

.data-table tr:last-child td {
    border-bottom: none;
}

.data-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.02);
}

/* Status Badges */
.badge-status {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.25rem 0.65rem;
    border-radius: var(--radius-full);
}

.badge-status.approved {
    background: rgba(16, 185, 129, 0.15);
    color: var(--status-emerald-light);
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.badge-status.submitted {
    background: rgba(59, 130, 246, 0.15);
    color: var(--brand-blue-light);
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.badge-status.revision_required {
    background: rgba(245, 158, 11, 0.15);
    color: var(--text-gold);
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.badge-status.draft {
    background: rgba(148, 163, 184, 0.15);
    color: var(--text-secondary);
    border: 1px solid rgba(148, 163, 184, 0.3);
}

.badge-status.referred {
    background: rgba(220, 38, 38, 0.15);
    color: var(--status-crimson-light);
    border: 1px solid rgba(220, 38, 38, 0.3);
}

/* Filter Controls Toolbar */
.toolbar-filter-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.search-input-wrap {
    position: relative;
    flex-grow: 1;
    min-width: 280px;
    max-width: 460px;
}

.search-input-wrap input {
    width: 100%;
    padding-right: 2.25rem;
    padding-left: 1rem;
    min-height: 42px;
}

.search-icon-inside {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.filter-pills-group {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    flex-wrap: wrap;
}

.filter-pill-btn {
    padding: 0.45rem 1.15rem;
    border-radius: var(--radius-full);
    font-size: 0.84rem;
    font-weight: 600;
    color: var(--text-secondary);
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    white-space: nowrap !important;
    flex-shrink: 0;
    cursor: pointer;
    transition: all 0.2s ease;
}

.filter-pill-btn.active {
    background: var(--brand-blue);
    color: #FFFFFF;
    border-color: var(--brand-blue);
}

/* Competency Domain Cards */
.domain-card {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.domain-header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-subtle);
}

.domain-title-wrap {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.domain-badge-circle {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
}

.domain-name {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text-primary);
}

.domain-stats-summary {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.subcompetencies-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1rem;
}

.comp-item-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 1rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 0.75rem;
}

.comp-item-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.5rem;
}

.comp-item-id {
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.15rem 0.45rem;
    border-radius: var(--radius-sm);
    background: var(--bg-input);
    color: var(--accent-cyan);
    font-family: var(--font-mono);
}

.comp-item-title {
    font-size: 0.92rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.4;
    margin-top: 0.2rem;
}

.comp-item-eval {
    font-size: 0.78rem;
    color: var(--text-secondary);
    background: var(--bg-input);
    padding: 0.4rem 0.6rem;
    border-radius: var(--radius-sm);
}

.comp-item-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.78rem;
    border-top: 1px solid var(--border-subtle);
    padding-top: 0.5rem;
}

/* Rubrics Evaluator Interactive Matrix */
.rubric-card-full {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1.75rem;
    margin-bottom: 2rem;
}

.rubric-header-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--border-subtle);
}

.rubric-title-block h3 {
    font-size: 1.35rem;
    font-weight: 800;
    margin-bottom: 0.25rem;
}

.rubric-score-display {
    text-align: left;
    background: var(--bg-surface);
    padding: 0.75rem 1.25rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
}

.rubric-score-val {
    font-size: 1.75rem;
    font-weight: 900;
    font-family: var(--font-mono);
    color: var(--status-emerald-light);
}

.criterion-box {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    margin-bottom: 1.25rem;
}

.criterion-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.criterion-name-wrap {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.criterion-name {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.criterion-weight-tag {
    font-size: 0.75rem;
    padding: 0.15rem 0.5rem;
    border-radius: var(--radius-full);
    background: rgba(37, 99, 235, 0.1);
    color: var(--brand-blue-light);
    font-weight: 700;
}

.level-selector-row {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

@media (max-width: 768px) {
    .level-selector-row {
        grid-template-columns: 1fr;
    }
}

.level-option-btn {
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    padding: 0.65rem 0.5rem;
    text-align: center;
    background: var(--bg-card);
    transition: all var(--transition-fast);
}

.level-option-btn.selected {
    background: var(--brand-blue);
    border-color: var(--brand-blue-light);
    color: #FFFFFF;
    box-shadow: 0 0 10px rgba(37, 99, 235, 0.3);
}

.level-num {
    font-size: 1.1rem;
    font-weight: 800;
    font-family: var(--font-mono);
    display: block;
    margin-bottom: 0.15rem;
}

.level-name {
    font-size: 0.75rem;
    font-weight: 600;
    display: block;
}

.level-desc-active {
    font-size: 0.8rem;
    color: var(--text-secondary);
    background: var(--bg-input);
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    margin-top: 0.5rem;
}

/* Audio Player Simulator */
.audio-player-simulator {
    background: #F8FAFC;
    border: 1px solid #E2E8F0;
    border-radius: var(--radius-lg);
    padding: 1.25rem 1.5rem;
    margin-top: 1rem;
    box-shadow: var(--shadow-sm);
}

.audio-player-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.audio-track-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.audio-play-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--brand-blue), var(--accent-cyan));
    color: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    box-shadow: 0 4px 6px -1px rgba(29, 78, 216, 0.3);
}

.audio-play-btn:hover {
    transform: scale(1.05);
}

.audio-meta h5 {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-primary);
}

.audio-meta span {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.waveform-scrubber-wrap {
    margin-bottom: 0.75rem;
}

.waveform-visual-bars {
    display: flex;
    align-items: flex-end;
    gap: 3px;
    height: 38px;
    cursor: pointer;
    padding: 2px 0;
}

.wave-bar {
    flex: 1;
    background: #CBD5E1;
    border-radius: 2px;
    transition: height 0.2s, background-color 0.2s;
}

.wave-bar.played {
    background: linear-gradient(180deg, var(--accent-cyan), var(--brand-blue));
}

body.theme-dark .audio-player-simulator {
    background: linear-gradient(135deg, #091325, #0E1E38);
    border-color: var(--border-accent);
}
body.theme-dark .audio-meta h5 { color: #FFFFFF; }
body.theme-dark .wave-bar { background: #1E3A8A; }
body.theme-dark .wave-bar.played { background: linear-gradient(180deg, var(--accent-cyan-light), var(--brand-blue-light)); }

.audio-time-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--text-secondary);
    font-family: var(--font-mono);
}

.timestamps-pills-wrap {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.ts-pill-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: rgba(37, 99, 235, 0.2);
    border: 1px solid rgba(37, 99, 235, 0.4);
    color: var(--text-cyan);
    padding: 0.2rem 0.65rem;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-family: var(--font-mono);
}

.ts-pill-btn:hover {
    background: var(--brand-blue);
    color: #FFFFFF;
}

/* Modal Dialog Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(6px);
    z-index: 100000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    animation: modalBackdropFade var(--transition-fast);
    box-sizing: border-box;
}

#chat-media-modal {
    z-index: 100100 !important;
}

.modal-overlay.active {
    display: flex !important;
    pointer-events: auto !important;
}

.modal-overlay:not(.active) {
    display: none !important;
    pointer-events: none !important;
}

@keyframes modalBackdropFade {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-container, .modal-card {
    background: var(--bg-surface, #FFFFFF);
    border: 1px solid var(--border-accent, #CBD5E1);
    border-radius: var(--radius-lg, 14px);
    width: 95%;
    max-width: 720px;
    max-height: 90vh;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.4);
    position: relative;
    pointer-events: auto;
    box-sizing: border-box;
    animation: modalSlideUp var(--transition-normal, 0.25s ease);
}

@keyframes modalSlideUp {
    from { transform: translateY(20px) scale(0.98); opacity: 0; }
    to { transform: translateY(0) scale(1); opacity: 1; }
}

.modal-header {
    padding: 1.25rem 2rem;
    border-bottom: 1px solid var(--border-subtle);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
    position: relative;
    background: var(--bg-surface);
    z-index: 6;
    box-sizing: border-box;
}

.modal-header h3 {
    font-size: 1.25rem;
    font-weight: 800;
}

.btn-close-modal {
    width: 36px;
    height: 36px;
    min-width: 36px;
    min-height: 36px;
    border-radius: 50%;
    background: var(--bg-input);
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    flex-shrink: 0;
    border: none;
    cursor: pointer;
    pointer-events: auto;
    position: relative;
    z-index: 7;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.btn-close-modal:hover {
    background: var(--status-crimson);
    color: #FFFFFF;
    transform: scale(1.05);
}

.btn-close-modal svg {
    pointer-events: none;
}

.modal-close-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--bg-input, #F1F5F9);
    color: var(--text-secondary, #64748B);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    line-height: 1;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.modal-close-btn:hover {
    background: #EF4444;
    color: #FFFFFF;
    transform: scale(1.05);
}

.modal-card .modal-body {
    padding: 1.5rem 2rem;
    overflow-y: auto;
    background: var(--bg-surface, #FFFFFF);
    max-height: calc(85vh - 140px);
}

.modal-card .modal-footer {
    padding: 1rem 2rem;
    border-top: 1px solid var(--border-subtle, #E2E8F0);
    background: var(--bg-card, #F8FAFC);
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.modal-body {
    padding: 1.5rem 2rem;
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    box-sizing: border-box;
}

.modal-footer {
    padding: 1.25rem 2rem;
    border-top: 1px solid var(--border-subtle);
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.85rem;
    background: var(--bg-surface);
    flex-shrink: 0;
    position: relative;
    z-index: 6;
    flex-wrap: wrap;
    box-sizing: border-box;
}

.modal-footer button,
.modal-footer .btn,
.modal-footer .btn-primary,
.modal-footer .btn-secondary,
.modal-footer .btn-emerald,
.modal-footer .btn-amber {
    white-space: nowrap !important;
    padding: 0.65rem 1.45rem;
    min-width: 140px;
    justify-content: center;
    flex-shrink: 0;
    cursor: pointer;
    pointer-events: auto;
}

/* 4-Part Reflection Form in Modal */
.reflection-section-box {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    margin-bottom: 1.25rem;
}

.reflection-question-wrap {
    margin-bottom: 1rem;
}

.reflection-label {
    display: block;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.35rem;
}

.reflection-hint {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

/* Formal Official Dossier & Printable Report */
.official-dossier-sheet {
    background: #FFFFFF;
    color: #0F172A;
    border-radius: var(--radius-lg);
    padding: 3.5rem 3rem;
    box-shadow: 0 20px 40px -15px rgba(11, 27, 61, 0.12), 0 0 0 1px #E2E8F0;
    margin: 0 auto 3rem;
    max-width: 980px;
    border: 3px double #D97706;
    outline: 1px solid #CBD5E1;
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
}

.dossier-watermark {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-30deg);
    font-size: 6rem;
    font-weight: 900;
    color: rgba(11, 27, 61, 0.03);
    pointer-events: none;
    white-space: nowrap;
    user-select: none;
}

.dossier-header-grid {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 3px double #0B1B3D;
    padding-bottom: 1.5rem;
    margin-bottom: 2rem;
}

.dossier-logo-img {
    height: 70px;
    width: auto;
}

.dossier-org-text h2 {
    color: #0B1B3D;
    font-size: 1.35rem;
    font-weight: 800;
}

.dossier-org-text p {
    color: #475569;
    font-size: 0.85rem;
}

.dossier-meta-box {
    text-align: left;
    font-size: 0.82rem;
    color: #334155;
    font-family: var(--font-mono);
}

.dossier-summary-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 2rem;
}

.dossier-summary-table th, .dossier-summary-table td {
    border: 1px solid #CBD5E1;
    padding: 0.75rem 1rem;
    font-size: 0.88rem;
}

.dossier-summary-table th {
    background: #F1F5F9;
    color: #0B1B3D;
    font-weight: 700;
}

.signatures-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 3rem;
    padding-top: 1.5rem;
    border-top: 1px solid #E2E8F0;
    gap: 1rem;
    flex-wrap: wrap;
}

.signature-block {
    text-align: center;
    min-width: 220px;
    padding: 0.75rem 1.25rem;
    background: #F8FAFC;
    border-radius: 8px;
    border: 1px solid #E2E8F0;
}

.signature-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: #64748B;
    margin-bottom: 0.4rem;
}

.signature-calligraphy {
    font-family: 'Tajawal', 'Amiri', cursive, serif;
    font-size: 1.35rem;
    color: #1E3A8A;
    font-style: italic;
    font-weight: 900;
    margin: 0.35rem 0;
    letter-spacing: 0.5px;
    text-shadow: 0 1px 2px rgba(30, 58, 138, 0.1);
}

.signature-name {
    font-size: 0.95rem;
    font-weight: 800;
    color: #0B1B3D;
}

.stamp-box-simulated {
    width: 110px;
    height: 110px;
    border: 3px double #059669;
    outline: 2px dashed #D97706;
    outline-offset: -6px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    color: #065F46;
    font-size: 0.72rem;
    font-weight: 800;
    transform: rotate(-10deg);
    background: radial-gradient(circle, rgba(5, 150, 105, 0.08) 0%, rgba(217, 119, 6, 0.05) 100%);
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.15);
    line-height: 1.3;
    text-align: center;
    position: relative;
    user-select: none;
}

.stamp-box-simulated::before {
    content: "";
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #D97706;
    box-shadow: 0 0 4px rgba(217, 119, 6, 0.4);
}

.stamp-box-simulated::after {
    content: "";
    position: absolute;
    bottom: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #D97706;
    box-shadow: 0 0 4px rgba(217, 119, 6, 0.4);
}

/* ==========================================================================
   Executive Toast Notification System (Arabic RTL Optimized)
   ========================================================================== */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 100050;
    display: flex;
    flex-direction: column-reverse;
    gap: 12px;
    pointer-events: none !important;
    max-width: 440px;
    width: auto;
}

.app-toast,
.toast-item {
    pointer-events: auto !important;
    position: relative;
    background: #FFFFFF !important;
    color: #0B1B3D !important;
    border: 1px solid #E2E8F0;
    border-right: 4px solid var(--brand-blue, #1D4ED8);
    border-radius: 12px;
    box-shadow: 0 12px 32px -4px rgba(11, 27, 61, 0.16), 0 4px 12px -2px rgba(11, 27, 61, 0.08);
    padding: 0.85rem 1.15rem;
    min-width: 290px;
    max-width: 440px;
    direction: rtl;
    overflow: hidden;
    animation: toastEntrance 0.28s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    transition: transform 0.2s ease, opacity 0.2s ease, max-height 0.25s ease, margin 0.25s ease, padding 0.25s ease;
}

body.theme-dark .app-toast,
body.theme-dark .toast-item {
    background: #0E1726 !important;
    color: #F8FAFC !important;
    border-color: rgba(255, 255, 255, 0.14);
    box-shadow: 0 14px 36px -4px rgba(0, 0, 0, 0.55), 0 4px 14px -2px rgba(0, 0, 0, 0.35);
}

.app-toast.toast-hiding,
.toast-item.toast-hiding {
    animation: toastExit 0.26s cubic-bezier(0.4, 0, 1, 1) forwards !important;
    pointer-events: none !important;
}

.toast-content-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
}

.toast-icon-badge,
.toast-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    min-width: 34px;
    border-radius: 50%;
    background: rgba(29, 78, 216, 0.1);
    color: #1D4ED8;
    flex-shrink: 0;
}

.toast-text {
    flex: 1;
    font-family: var(--font-sans, 'Tajawal', sans-serif);
    font-size: 0.92rem;
    font-weight: 600;
    line-height: 1.45;
    color: inherit;
    word-break: break-word;
}

.toast-close-btn,
.toast-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    min-width: 28px;
    border-radius: 8px;
    border: none;
    background: transparent;
    color: #64748B;
    cursor: pointer;
    padding: 0;
    transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease;
    flex-shrink: 0;
    pointer-events: auto !important;
}

.toast-close-btn:hover,
.toast-close:hover {
    background: rgba(11, 27, 61, 0.08);
    color: #0B1B3D;
}

body.theme-dark .toast-close-btn:hover,
body.theme-dark .toast-close:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #FFFFFF;
}

/* Variant Accents */
.app-toast.toast-info,
.toast-item.toast-info {
    border-right-color: #2563EB;
}
.app-toast.toast-info .toast-icon-badge,
.app-toast.toast-info .toast-icon {
    background: rgba(37, 99, 235, 0.12);
    color: #2563EB;
}

.app-toast.toast-success,
.toast-item.toast-success {
    border-right-color: #059669;
}
.app-toast.toast-success .toast-icon-badge,
.app-toast.toast-success .toast-icon {
    background: rgba(5, 150, 105, 0.12);
    color: #059669;
}

.app-toast.toast-warning,
.toast-item.toast-warning {
    border-right-color: #D97706;
}
.app-toast.toast-warning .toast-icon-badge,
.app-toast.toast-warning .toast-icon {
    background: rgba(217, 119, 6, 0.12);
    color: #D97706;
}

.app-toast.toast-error,
.toast-item.toast-error {
    border-right-color: #DC2626;
}
.app-toast.toast-error .toast-icon-badge,
.app-toast.toast-error .toast-icon {
    background: rgba(220, 38, 38, 0.12);
    color: #DC2626;
}

/* Auto-dismiss progress countdown line */
.toast-progress-bar {
    position: absolute;
    bottom: 0;
    right: 0;
    left: 0;
    height: 3px;
    background: rgba(29, 78, 216, 0.5);
    transform-origin: right center;
    animation: toastProgress linear forwards;
}

.app-toast.toast-success .toast-progress-bar {
    background: rgba(5, 150, 105, 0.6);
}
.app-toast.toast-warning .toast-progress-bar {
    background: rgba(217, 119, 6, 0.6);
}
.app-toast.toast-error .toast-progress-bar {
    background: rgba(220, 38, 38, 0.6);
}

@keyframes toastProgress {
    0% { transform: scaleX(1); }
    100% { transform: scaleX(0); }
}

@keyframes toastEntrance {
    0% {
        opacity: 0;
        transform: translateY(16px) scale(0.96);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes toastExit {
    0% {
        opacity: 1;
        transform: translateY(0) scale(1);
        max-height: 120px;
        margin-bottom: 0;
    }
    100% {
        opacity: 0;
        transform: translateY(10px) scale(0.92);
        max-height: 0;
        margin-bottom: -12px;
        padding-top: 0;
        padding-bottom: 0;
        border-width: 0;
    }
}

@media (max-width: 640px) {
    .toast-container {
        bottom: 80px;
        right: 16px;
        left: 16px;
        max-width: none;
    }
    .app-toast,
    .toast-item {
        min-width: 0;
        width: 100%;
    }
}

.standard-card.selected-tool {
    border-color: var(--brand-blue-light) !important;
    box-shadow: var(--shadow-glow-blue) !important;
    background: var(--bg-card-hover) !important;
}

.criterion-improvement-box input.ref-input {
    background: var(--bg-surface);
    border: 1px solid var(--border-accent);
    border-radius: var(--radius-sm);
    padding: 0.4rem 0.75rem;
    color: var(--text-primary);
    font-family: var(--font-sans);
    transition: var(--transition-fast);
}

.criterion-improvement-box input.ref-input:focus {
    outline: none;
    border-color: var(--status-emerald);
    box-shadow: var(--shadow-glow-emerald);
}

/* Print Media Styles */
@media print {
    body {
        background: #FFFFFF !important;
        color: #0F172A !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    @page {
        size: A4 portrait;
        margin: 12mm 10mm 12mm 10mm;
    }

    .app-header,
    .quick-status-strip,
    .main-nav-bar,
    .section-actions,
    .toolbar-filter-row,
    .modal-overlay,
    .toast-container,
    .no-print,
    .cert-admin-toolbar,
    .floating-chat-root,
    .floating-chat-btn,
    .chat-drawer,
    .chat-drawer-backdrop,
    .skip-link,
    .view-mode-toggle,
    .admin-segmented-tabs,
    .btn-icon-action {
        display: none !important;
    }

    .app-main-content {
        padding: 0 !important;
        max-width: 100% !important;
        margin: 0 !important;
    }

    .tab-panel {
        display: none !important;
    }

    #panel-report {
        display: block !important;
    }

    .official-dossier-sheet {
        box-shadow: none !important;
        border: 2px solid #0B1B3D !important;
        padding: 1.5rem !important;
        max-width: 100% !important;
        margin: 0 !important;
        page-break-after: avoid;
    }

    .dossier-header-grid {
        border-bottom: 2px solid #0B1B3D !important;
    }

    .dossier-signature-row,
    .dossier-meta-grid,
    .dossier-table tr {
        page-break-inside: avoid !important;
    }
}

/* ==========================================================================
   Fullstack Authentication, User Session & Executive Admin Dashboard Styles
   ========================================================================== */

/* User Session Header Widget */
.user-session-widget {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.user-profile-badge {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    padding: 0.35rem 0.75rem;
    border-radius: var(--radius-full);
}

.user-profile-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--brand-blue), var(--brand-purple));
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
}

.user-profile-avatar.admin {
    background: linear-gradient(135deg, #D97706, #B45309);
    box-shadow: 0 0 10px rgba(217, 119, 6, 0.4);
}

.user-profile-name {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-primary);
}

.user-profile-role-tag {
    font-size: 0.7rem;
    font-weight: 600;
    padding: 0.15rem 0.5rem;
    border-radius: var(--radius-sm);
    background: rgba(30, 41, 59, 0.8);
    color: var(--text-secondary);
}

.user-profile-role-tag.admin {
    background: rgba(217, 119, 6, 0.2);
    color: #FBBF24;
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.user-profile-role-tag.coach {
    background: rgba(14, 165, 233, 0.15);
    color: #38BDF8;
    border: 1px solid rgba(56, 189, 248, 0.3);
}

.btn-auth-trigger {
    background: linear-gradient(135deg, var(--brand-gold), #B45309);
    color: #0F172A;
    font-weight: 700;
    padding: 0.45rem 1rem;
    border-radius: var(--radius-md);
    border: none;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-auth-trigger:hover {
    filter: brightness(1.1);
    transform: translateY(-1px);
}

.btn-auth-logout {
    background: transparent;
    color: var(--text-muted);
    border: 1px solid var(--border-subtle);
    padding: 0.3rem 0.6rem;
    border-radius: var(--radius-md);
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-auth-logout:hover {
    color: var(--status-crimson);
    border-color: var(--status-crimson);
}

/* Auth Modal Styles */
.auth-modal-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-focus);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 520px;
    padding: 2rem;
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
}

.auth-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    background: var(--bg-input);
    padding: 0.3rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
}

.auth-tab-btn {
    flex: 1;
    background: transparent;
    border: none;
    padding: 0.6rem;
    font-weight: 700;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
    font-size: 0.9rem;
}

.auth-tab-btn.active {
    background: var(--brand-blue);
    color: #fff;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
}

/* Production Auth Modal Styles */
.auth-credential-hint {
    margin-bottom: 1.25rem;
    padding: 0.85rem;
    background: #F8FAFC;
    border: 1px solid #E2E8F0;
    border-radius: var(--radius-md);
}

.credential-box {
    cursor: pointer;
    background: #FFFFFF;
    padding: 0.65rem 0.8rem;
    border-radius: var(--radius-sm);
    border: 1px solid #E2E8F0;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.credential-box:hover {
    border-color: var(--brand-blue);
    background: #EFF6FF;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px -2px rgba(29, 78, 216, 0.12);
}

.credential-box.admin {
    border-color: #FDE68A;
    background: #FFFBEB;
}

.credential-box.admin:hover {
    border-color: var(--brand-gold);
    background: #FEF3C7;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px -2px rgba(217, 119, 6, 0.15);
}

body.theme-dark .auth-credential-hint {
    background: rgba(15, 23, 42, 0.7);
    border-color: var(--border-subtle);
}

body.theme-dark .credential-box {
    background: var(--bg-surface);
    border-color: var(--border-subtle);
}

body.theme-dark .credential-box:hover {
    border-color: var(--brand-blue-light);
    background: rgba(29, 78, 216, 0.2);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

body.theme-dark .credential-box.admin {
    border-color: rgba(217, 119, 6, 0.35);
    background: rgba(217, 119, 6, 0.08);
}

body.theme-dark .credential-box.admin:hover {
    border-color: var(--brand-gold);
    background: rgba(217, 119, 6, 0.18);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

/* Executive Admin Dashboard Panels */
.admin-kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 1rem;
    margin-bottom: 1.75rem;
}

.admin-kpi-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: all 0.2s ease;
}

.admin-kpi-card:hover {
    transform: translateY(-2px);
    border-color: var(--border-focus);
}

.admin-kpi-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.admin-kpi-icon.blue { background: rgba(30, 64, 175, 0.2); color: #60A5FA; }
.admin-kpi-icon.gold { background: rgba(217, 119, 6, 0.2); color: #FBBF24; }
.admin-kpi-icon.emerald { background: rgba(5, 150, 105, 0.2); color: #34D399; }
.admin-kpi-icon.purple { background: rgba(124, 58, 237, 0.2); color: #A78BFA; }

.admin-kpi-val {
    font-size: 1.8rem;
    font-weight: 900;
    font-family: var(--font-mono);
    color: var(--text-primary);
    line-height: 1.1;
}

.admin-kpi-label {
    font-size: 0.82rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
}

/* Registered Coaches Table */
.coaches-table-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.coaches-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin-top: 1rem;
}

.coaches-table th {
    background: var(--bg-input);
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-weight: 700;
    padding: 0.85rem 1rem;
    text-align: right;
    border-bottom: 1px solid var(--border-subtle);
}

.coaches-table td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-subtle);
    font-size: 0.85rem;
    vertical-align: middle;
}

.coaches-table tr:hover td {
    background: #F1F5F9;
}

body.theme-dark .coaches-table tr:hover td {
    background: rgba(30, 41, 59, 0.5);
}

.coach-avatar-initials {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--brand-blue), var(--brand-purple));
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
}

/* Review Submissions Queue */
.review-queue-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.25rem;
    margin-top: 1rem;
}

.review-queue-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    border-right: 4px solid var(--brand-gold);
}

.review-queue-card.approved {
    border-right-color: var(--status-emerald);
}

/* File Upload Real Zone */
.upload-drop-zone {
    border: 2px dashed #CBD5E1;
    background: #F8FAFC;
    border-radius: var(--radius-md);
    padding: 1.75rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 1rem;
}

.upload-drop-zone:hover {
    background: #EFF6FF;
    border-color: var(--brand-blue);
}

.upload-drop-zone.drag-active {
    background: #EFF6FF;
    border-color: var(--brand-blue);
}

body.theme-dark .upload-drop-zone {
    border-color: var(--border-focus);
    background: rgba(15, 23, 42, 0.5);
}
body.theme-dark .upload-drop-zone:hover {
    background: rgba(30, 41, 59, 0.8);
    border-color: var(--brand-blue-light);
}
body.theme-dark .upload-drop-zone.drag-active {
    background: rgba(29, 78, 216, 0.15);
    border-color: var(--brand-gold);
}

.file-progress-bar {
    width: 100%;
    height: 6px;
    background: var(--bg-input);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 0.5rem;
}

.file-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--brand-blue), var(--status-emerald));
    width: 0%;
    transition: width 0.3s ease;
}
/* Executive Admin Navigation Tabs */
.admin-segmented-tabs {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: #F1F5F9;
    padding: 0.45rem;
    border-radius: var(--radius-lg);
    border: 1px solid #E2E8F0;
    margin-bottom: 1.5rem;
    flex-wrap: wrap !important;
    width: 100%;
    box-sizing: border-box;
}

body.theme-dark .admin-segmented-tabs {
    background: #1E293B;
    border-color: #334155;
}

.admin-tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    border-radius: var(--radius-md);
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
    flex-shrink: 0;
    min-height: 40px;
    pointer-events: auto;
    box-sizing: border-box;
}

.admin-tab-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.7);
}

body.theme-dark .admin-tab-btn:hover {
    background: rgba(255, 255, 255, 0.05);
}

.admin-tab-btn.active {
    background: #0B1B3D;
    color: #FFFFFF;
    box-shadow: 0 2px 8px rgba(11, 27, 61, 0.2);
}

body.theme-dark .admin-tab-btn.active {
    background: #2563EB;
    color: #FFFFFF;
}

/* Cohorts Management & Production Premium Styles */
.cohorts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: 1.5rem;
    margin-top: 1.25rem;
}

.cohort-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cohort-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.06);
}

.cohort-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.cohort-card-title {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.cohort-card-desc {
    font-size: 0.82rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 1rem;
}

.cohort-targets-box {
    background: var(--bg-input);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 0.85rem;
    margin-bottom: 1rem;
    font-size: 0.8rem;
}

.cohort-targets-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.cohort-target-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.35rem 0.5rem;
    background: var(--bg-surface);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-subtle);
}

.cohort-coaches-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 1.25rem;
}

.cohort-coach-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.6rem;
    background: rgba(37, 99, 235, 0.08);
    color: #2563EB;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
}

body.theme-dark .cohort-coach-chip {
    background: rgba(59, 130, 246, 0.15);
    color: #93C5FD;
}

.cohort-actions-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid var(--border-subtle);
}

.audit-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 0.82rem;
}

.audit-table th {
    background: var(--bg-input);
    color: var(--text-secondary);
    font-weight: 700;
    padding: 0.75rem;
    text-align: right;
    border-bottom: 1px solid var(--border-subtle);
}

.audit-table td {
    padding: 0.75rem;
    border-bottom: 1px solid var(--border-subtle);
    vertical-align: middle;
}

/* Certificate Admin Toolbar & Action Buttons */
.cert-admin-toolbar {
    margin-bottom: 1.25rem;
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    background: #F8FAFC;
    padding: 0.75rem 1.25rem;
    border-radius: var(--radius-md);
    border: 1px solid #E2E8F0;
}

body.theme-dark .cert-admin-toolbar {
    background: #1E293B;
    border-color: #334155;
}

.btn-xs {
    padding: 0.35rem 0.85rem;
    font-size: 0.78rem;
    border-radius: var(--radius-sm);
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s ease;
    white-space: nowrap !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    min-height: 28px;
    min-width: 28px;
    pointer-events: auto !important;
    position: relative;
    z-index: 2;
}

table td .btn,
table td .btn-xs,
table td .btn-icon-action,
table td button,
table td input,
table td select,
table td a {
    pointer-events: auto !important;
    position: relative;
    z-index: 2;
}

.table-actions-cell,
table td .table-actions-cell {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    flex-wrap: wrap;
    min-width: 130px;
    pointer-events: auto !important;
    position: relative;
    z-index: 2;
}

.btn-outline {
    background: transparent;
    border: 1px solid #CBD5E1;
    color: var(--text-primary);
}

.btn-outline:hover {
    background: #F1F5F9;
    border-color: #94A3B8;
}

.btn-danger-outline {
    background: transparent;
    border: 1px solid #FCA5A5;
    color: #DC2626;
}

.btn-danger-outline:hover {
    background: #FEF2F2;
    border-color: #EF4444;
}

.admin-form-group {
    margin-bottom: 1.25rem;
}

.admin-form-group label {
    display: block;
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.45rem;
    white-space: nowrap;
}

.admin-form-group input,
.admin-form-group select,
.admin-form-group textarea {
    width: 100%;
    padding: 0.7rem 1rem;
    border: 1px solid #CBD5E1;
    border-radius: var(--radius-sm);
    font-size: 0.92rem;
    background: var(--bg-surface);
    color: var(--text-primary);
    font-family: inherit;
    min-height: 42px;
}

.admin-form-group input:focus,
.admin-form-group select:focus,
.admin-form-group textarea:focus {
    outline: none;
    border-color: #2563EB;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.admin-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.35rem;
}

.admin-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.admin-grid-5 {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.75rem;
}

@media (max-width: 768px) {
    .admin-grid-2 {
        grid-template-columns: 1fr;
        gap: 0.85rem;
    }
    .admin-grid-3 {
        grid-template-columns: 1fr;
        gap: 0.85rem;
    }
    .admin-grid-5 {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.65rem;
    }
}

@media (max-width: 480px) {
    .admin-grid-5 {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
}

/* ==========================================================================
   Chat & Supervisory Messaging Hub (مركز المحادثات والتوجيه الإشرافي)
   ========================================================================== */

.chat-hub-container {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    display: grid;
    grid-template-columns: 340px 1fr;
    height: calc(100vh - 210px);
    min-height: 680px;
    margin-bottom: 2rem;
}

@media (max-width: 900px) {
    .chat-hub-container {
        grid-template-columns: 1fr;
        height: auto;
        min-height: auto;
    }
}

/* Sidebar Channels List */
.chat-sidebar {
    background: #F8FAFC;
    border-left: 1px solid var(--border-subtle);
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}

body.theme-dark .chat-sidebar {
    background: rgba(15, 23, 42, 0.6);
}

.chat-sidebar-header {
    padding: 1.25rem 1rem 0.75rem;
    border-bottom: 1px solid var(--border-subtle);
}

.chat-sidebar-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.chat-sidebar-title-row h3 {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.chat-search-wrap {
    position: relative;
    width: 100%;
}

.chat-search-wrap input {
    width: 100%;
    padding: 0.55rem 2.25rem 0.55rem 0.75rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
    background: var(--bg-surface);
    font-size: 0.85rem;
    color: var(--text-primary);
    font-family: inherit;
    transition: all 0.2s ease;
}

.chat-search-wrap input:focus {
    outline: none;
    border-color: var(--brand-blue);
    box-shadow: 0 0 0 2px rgba(29, 78, 216, 0.15);
}

.chat-search-wrap svg {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    pointer-events: none;
}

.chat-channels-scroll {
    flex: 1;
    overflow-y: auto;
    padding: 0.5rem;
}

.chat-channels-section-label {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-muted);
    padding: 0.5rem 0.5rem 0.25rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.chat-channel-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.15s ease;
    margin-bottom: 0.25rem;
    border: 1px solid transparent;
    position: relative;
}

.chat-channel-item:hover {
    background: rgba(29, 78, 216, 0.05);
    border-color: rgba(29, 78, 216, 0.1);
}

.chat-channel-item.active {
    background: #EFF6FF;
    border-color: var(--brand-blue);
}

body.theme-dark .chat-channel-item.active {
    background: rgba(29, 78, 216, 0.2);
    border-color: var(--brand-blue-light);
}

.chat-channel-avatar-wrap {
    position: relative;
    flex-shrink: 0;
}

.chat-channel-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--brand-navy);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.95rem;
    border: 2px solid var(--border-subtle);
    object-fit: cover;
}

.chat-channel-avatar.group-avatar {
    background: linear-gradient(135deg, #0B1B3D 0%, #1D4ED8 100%);
    box-shadow: 0 2px 6px rgba(11, 27, 61, 0.2);
}

.chat-channel-avatar.supervisor-avatar {
    background: linear-gradient(135deg, #059669 0%, #10B981 100%);
    box-shadow: 0 2px 6px rgba(5, 150, 105, 0.2);
}

.chat-channel-info {
    flex: 1;
    min-width: 0;
}

.chat-channel-top-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.2rem;
}

.chat-channel-name {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.chat-channel-time {
    font-size: 0.72rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

.chat-channel-bottom-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

.chat-channel-snippet {
    font-size: 0.78rem;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.chat-unread-badge {
    background: var(--brand-emerald);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.15rem 0.45rem;
    border-radius: 999px;
    min-width: 18px;
    text-align: center;
    box-shadow: 0 1px 3px rgba(5, 150, 105, 0.3);
}

/* Main Chat Area */
.chat-main-area {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: var(--bg-surface);
    position: relative;
}

.chat-header {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border-subtle);
    background: var(--bg-surface);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
    box-shadow: 0 1px 2px rgba(0,0,0,0.02);
}

.chat-header-title-box {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.chat-header-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--border-subtle);
}

.chat-header-details h3 {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.chat-header-details p {
    font-size: 0.78rem;
    color: var(--text-secondary);
    margin: 0.15rem 0 0;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.chat-online-dot {
    width: 8px;
    height: 8px;
    background: var(--status-emerald);
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 0 2px rgba(5, 150, 105, 0.2);
}

.chat-header-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Chat Messages Scroll Container */
.chat-messages-scroll {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    background: #F8FAFC;
    scroll-behavior: smooth;
}

body.theme-dark .chat-messages-scroll {
    background: #0B1120;
}

.chat-date-separator {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0.5rem 0;
    position: relative;
}

.chat-date-separator span {
    background: #E2E8F0;
    color: #475569;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.25rem 0.85rem;
    border-radius: 999px;
    box-shadow: var(--shadow-sm);
}

body.theme-dark .chat-date-separator span {
    background: #1E293B;
    color: #94A3B8;
}

/* Message Rows & Bubbles */
.chat-message-row {
    display: flex;
    gap: 0.75rem;
    max-width: 78%;
    animation: fadeIn 0.2s ease;
}

.chat-message-row.incoming {
    align-self: flex-start;
}

.chat-message-row.outgoing {
    align-self: flex-end;
    flex-direction: row;
    max-width: 82%;
}

.chat-msg-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    flex-shrink: 0;
    border: 1px solid var(--border-subtle);
    object-fit: cover;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFFFFF;
    font-size: 0.8rem;
    font-weight: 800;
}

.chat-msg-content-wrap {
    display: flex;
    flex-direction: column;
}

.chat-message-row.incoming .chat-msg-content-wrap {
    align-items: flex-start;
}

.chat-message-row.outgoing .chat-msg-content-wrap {
    align-items: flex-end;
}

.chat-msg-sender-meta {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.78rem;
    margin-bottom: 0.25rem;
    padding: 0 0.25rem;
}

.chat-msg-sender-name {
    font-weight: 700;
    color: var(--text-primary);
}

.chat-msg-sender-badge {
    font-size: 0.68rem;
    padding: 0.1rem 0.4rem;
    border-radius: 4px;
    font-weight: 600;
}

.chat-msg-sender-badge.admin-badge {
    background: #0B1B3D;
    color: #F8FAFC;
}

.chat-msg-sender-badge.coach-badge {
    background: #059669;
    color: #FFFFFF;
}

.chat-bubble {
    padding: 0.75rem 1rem;
    border-radius: 16px;
    font-size: 0.92rem;
    line-height: 1.6;
    position: relative;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
    word-break: break-word;
}

.chat-message-row.incoming .chat-bubble {
    background: #FFFFFF;
    color: #0F172A;
    border: 1px solid #E2E8F0;
    border-top-right-radius: 4px;
}

body.theme-dark .chat-message-row.incoming .chat-bubble {
    background: #1E293B;
    color: #F8FAFC;
    border-color: #334155;
}

.chat-message-row.outgoing .chat-bubble {
    background: linear-gradient(135deg, #0B1B3D 0%, #172554 100%);
    color: #FFFFFF;
    border-top-left-radius: 4px;
    box-shadow: 0 2px 6px rgba(11, 27, 61, 0.18);
}

body.theme-dark .chat-message-row.outgoing .chat-bubble {
    background: linear-gradient(135deg, #1E40AF 0%, #1D4ED8 100%);
    color: #FFFFFF;
}

.chat-bubble-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.35rem;
    margin-top: 0.35rem;
}

.chat-bubble-time {
    display: inline-block;
    font-size: 0.68rem;
    opacity: 0.75;
    font-family: var(--font-mono, monospace);
    margin: 0;
}

.chat-check-icon {
    color: #38BDF8;
    font-size: 0.72rem;
    font-weight: bold;
    letter-spacing: -1px;
}

/* Audio Player Component */
.chat-audio-player {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.4rem 0.2rem;
    min-width: 260px;
    direction: ltr;
}

.audio-play-btn {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: none;
    background: var(--brand-emerald);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.15s ease, background 0.15s ease;
    flex-shrink: 0;
}

.chat-message-row.outgoing .audio-play-btn {
    background: #fff;
    color: #0B1B3D;
}

.audio-play-btn:hover {
    transform: scale(1.06);
}

.audio-waveform-wrap {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.audio-progress-bar {
    width: 100%;
    height: 5px;
    background: rgba(148, 163, 184, 0.3);
    border-radius: 3px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.audio-progress-fill {
    height: 100%;
    background: var(--status-emerald);
    width: 0%;
    transition: width 0.1s linear;
}

.chat-message-row.outgoing .audio-progress-fill {
    background: #38BDF8;
}

.audio-time-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.72rem;
    font-family: var(--font-mono);
    opacity: 0.85;
}

/* Image Attachment */
.chat-image-wrap {
    margin-top: 0.25rem;
    border-radius: var(--radius-md);
    overflow: hidden;
    cursor: pointer;
    border: 1px solid rgba(0,0,0,0.1);
    transition: transform 0.2s ease;
    max-width: 320px;
}

.chat-image-wrap:hover {
    transform: scale(1.02);
}

.chat-image-preview {
    width: 100%;
    max-height: 240px;
    object-fit: cover;
    display: block;
}

/* File Attachment Card */
.chat-file-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.6rem 0.85rem;
    border-radius: var(--radius-md);
    background: rgba(0,0,0,0.06);
    margin-top: 0.4rem;
    border: 1px solid rgba(0,0,0,0.08);
}

.chat-message-row.outgoing .chat-file-card {
    background: rgba(255,255,255,0.12);
    border-color: rgba(255,255,255,0.2);
}

.chat-file-icon {
    width: 36px;
    height: 36px;
    border-radius: 6px;
    background: var(--brand-blue);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.chat-file-details {
    flex: 1;
    min-width: 0;
}

.chat-file-title {
    font-size: 0.85rem;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.chat-file-meta {
    font-size: 0.72rem;
    opacity: 0.8;
}

.chat-file-download-btn {
    color: inherit;
    opacity: 0.8;
    transition: opacity 0.15s ease;
    padding: 0.25rem;
}

.chat-file-download-btn:hover {
    opacity: 1;
}

/* Chat Input Bar */
.chat-input-bar {
    padding: 1rem 1.5rem;
    background: var(--bg-surface);
    border-top: 1px solid var(--border-subtle);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    position: relative;
    flex-shrink: 0;
}

.chat-attach-btn, .chat-record-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1px solid var(--border-subtle);
    background: #F8FAFC;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

body.theme-dark .chat-attach-btn, body.theme-dark .chat-record-btn {
    background: #1E293B;
}

.chat-attach-btn:hover, .chat-record-btn:hover {
    background: #EFF6FF;
    color: var(--brand-blue);
    border-color: var(--brand-blue);
}

.chat-record-btn.recording {
    background: #FEE2E2;
    color: #DC2626;
    border-color: #EF4444;
    animation: pulseRecording 1s infinite;
}

@keyframes pulseRecording {
    0% { transform: scale(1); }
    50% { transform: scale(1.08); }
    100% { transform: scale(1); }
}

.chat-input-field-wrap {
    flex: 1;
    position: relative;
}

.chat-textarea {
    width: 100%;
    min-height: 44px;
    max-height: 120px;
    padding: 0.7rem 1rem;
    border-radius: 22px;
    border: 1px solid var(--border-subtle);
    background: var(--bg-input);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 0.92rem;
    resize: none;
    line-height: 1.4;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.chat-textarea:focus {
    border-color: var(--brand-blue);
    box-shadow: 0 0 0 3px rgba(29, 78, 216, 0.15);
}

.chat-send-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background: var(--brand-navy);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(11, 27, 61, 0.25);
}

.chat-send-btn:hover {
    background: var(--brand-blue);
    transform: scale(1.05);
}

/* Voice Recording Active Banner */
.chat-recording-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    background: #FEF2F2;
    border: 1px solid #FECACA;
    border-radius: 22px;
    padding: 0.5rem 1rem;
    color: #991B1B;
    font-size: 0.88rem;
    font-weight: 600;
}

body.theme-dark .chat-recording-banner {
    background: rgba(153, 27, 27, 0.2);
    border-color: rgba(239, 68, 68, 0.3);
    color: #FCA5A5;
}

.recording-dot {
    width: 10px;
    height: 10px;
    background: #DC2626;
    border-radius: 50%;
    display: inline-block;
    margin-left: 0.5rem;
    animation: blinkDot 1s infinite;
}

@keyframes blinkDot {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

.recording-timer {
    font-family: var(--font-mono);
    font-weight: 700;
}

/* ==========================================================================
   14 Core Competency Domains UI
   ========================================================================== */

.comps-view-switcher {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--bg-surface);
    padding: 0.35rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
    margin-bottom: 1.5rem;
    width: fit-content;
}

.comps-switch-btn {
    padding: 0.55rem 1.25rem;
    border-radius: var(--radius-sm);
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.comps-switch-btn.active {
    background: var(--brand-navy);
    color: #FFFFFF;
    box-shadow: 0 1px 3px rgba(11, 27, 61, 0.2);
}

body.theme-dark .comps-switch-btn.active {
    background: var(--brand-blue);
    color: #FFFFFF;
}

.domains14-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.25rem;
    margin-top: 1rem;
}

.domain14-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 1.4rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: var(--shadow-sm);
    transition: all 0.2s ease;
    border-top: 4px solid var(--brand-blue);
    position: relative;
}

.domain14-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--brand-blue);
}

.domain14-card.critical-gate {
    border-top-color: var(--status-rose);
}

.domain14-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.domain14-code-pill {
    font-size: 0.72rem;
    font-weight: 800;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-family: var(--font-mono);
    color: #fff;
    background: var(--brand-navy);
}

.domain14-card h4 {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0.25rem 0 0.15rem;
}

.domain14-subtitle {
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 0.75rem;
}

.domain14-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 1rem;
}

.domain14-indicators-list {
    list-style: none;
    padding: 0;
    margin: 0 0 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.domain14-indicators-list li {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: flex;
    align-items: flex-start;
    gap: 0.4rem;
    line-height: 1.4;
}

.domain14-indicators-list li svg {
    color: var(--status-emerald);
    flex-shrink: 0;
    margin-top: 2px;
}

.domain14-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border-subtle);
}

.domain14-meta {
    font-size: 0.78rem;
    color: var(--text-muted);
}

/* ================================================================
   ONE-PAGE TRAINED COACH DASHBOARD SYSTEM
   ================================================================ */

html {
    scroll-behavior: smooth;
}

.app-main-content.mode-onepage {
    display: flex;
    flex-direction: column;
    gap: 2.25rem;
    padding-top: 1rem;
}

.app-main-content.mode-onepage .tab-panel {
    display: block !important;
    scroll-margin-top: calc(var(--total-sticky-offset, 94px) + 20px) !important;
    margin-bottom: 0;
    animation: none;
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
    padding: 1.75rem 2rem 2.25rem;
    position: relative;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.app-main-content.mode-onepage .tab-panel:hover {
    border-color: rgba(5, 150, 105, 0.3);
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.06);
}

body.theme-dark .app-main-content.mode-onepage .tab-panel {
    background: #111827;
    border-color: #1F2937;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
}

.app-main-content.mode-onepage #panel-admin-dashboard {
    display: none !important;
}

/* Sticky Quick-Navigation Anchor Bar */
.coach-sticky-nav-bar {
    position: sticky;
    top: var(--app-header-height, 74px);
    z-index: 95;
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid #E2E8F0;
    border-radius: var(--radius-full);
    padding: 0.4rem 0.6rem;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.35rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.07);
    overflow-x: auto;
    scrollbar-width: none;
    margin-bottom: 1.75rem;
}

body.theme-dark .coach-sticky-nav-bar {
    background: rgba(17, 24, 39, 0.94);
    border-color: #374151;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.5);
}

.coach-sticky-nav-bar::-webkit-scrollbar {
    display: none;
}

.sticky-nav-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.45rem 0.95rem;
    border-radius: var(--radius-full);
    font-size: 0.84rem;
    font-weight: 700;
    color: var(--text-secondary);
    background: transparent;
    border: 1px solid transparent;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
    font-family: inherit;
}

.sticky-nav-pill:hover {
    color: var(--brand-emerald);
    background: rgba(5, 150, 105, 0.08);
}

.sticky-nav-pill.active {
    color: #FFFFFF;
    background: #0B1B3D;
    border-color: #0B1B3D;
    box-shadow: 0 2px 8px rgba(11, 27, 61, 0.25);
}

body.theme-dark .sticky-nav-pill.active {
    background: var(--brand-emerald);
    border-color: var(--brand-emerald);
}

.sticky-nav-pill .pill-count {
    background: #E2E8F0;
    color: #475569;
    padding: 0.1rem 0.45rem;
    border-radius: var(--radius-full);
    font-size: 0.72rem;
    font-family: var(--font-mono);
}

.sticky-nav-pill.active .pill-count {
    background: rgba(255, 255, 255, 0.25);
    color: #FFFFFF;
}

.sticky-nav-pill.active .pill-count {
    background: rgba(255, 255, 255, 0.25);
    color: #FFFFFF;
}

body.theme-dark .sticky-nav-pill:not(.active) .pill-count {
    background: #374151;
    color: #CBD5E1;
}

.sticky-nav-pill .pill-live-dot {
    width: 7px;
    height: 7px;
    background: #10B981;
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.35);
}

.sticky-nav-pill .pill-badge-pass {
    background: rgba(16, 185, 129, 0.15);
    color: #059669;
    padding: 0.1rem 0.45rem;
    border-radius: var(--radius-full);
    font-size: 0.72rem;
    font-weight: 800;
}

.sticky-nav-pill.active .pill-badge-pass {
    background: rgba(255, 255, 255, 0.25);
    color: #FFFFFF;
}

/* One-Page Section Headers */
.onepage-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 1.25rem;
    margin-bottom: 1.75rem;
    border-bottom: 2px solid var(--border-subtle);
    flex-wrap: wrap;
    gap: 1rem;
}

.sec-header-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.sec-icon-box {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: rgba(5, 150, 105, 0.1);
    color: var(--brand-emerald);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(5, 150, 105, 0.12);
}

.sec-title {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0;
}

.sec-subtitle {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin: 0.25rem 0 0;
    line-height: 1.4;
}

.sec-header-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

/* Coach Executive Hero Banner */
.coach-hero-summary-card {
    background: linear-gradient(135deg, #0B1B3D 0%, #152C5E 60%, #059669 100%);
    color: #FFFFFF;
    border-radius: var(--radius-lg);
    padding: 1.75rem 2rem;
    margin-bottom: 1.75rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1.5rem;
    box-shadow: 0 8px 24px rgba(11, 27, 61, 0.18);
    position: relative;
    overflow: hidden;
}

.coach-hero-summary-card::before {
    content: '';
    position: absolute;
    top: -50px;
    left: -50px;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.coach-hero-info {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    z-index: 1;
}

.coach-hero-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: #FFFFFF;
    color: #0B1B3D;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    font-weight: 800;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    border: 3px solid rgba(255, 255, 255, 0.4);
    flex-shrink: 0;
}

.coach-hero-texts h2 {
    font-size: 1.45rem;
    font-weight: 800;
    color: #FFFFFF;
    margin: 0 0 0.3rem;
}

.coach-hero-texts p {
    font-size: 0.88rem;
    color: #E2E8F0;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.coach-hero-badge {
    background: rgba(255, 255, 255, 0.2);
    padding: 0.2rem 0.6rem;
    border-radius: var(--radius-full);
    font-size: 0.78rem;
    font-weight: 700;
}

.coach-hero-actions {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    flex-wrap: wrap;
    z-index: 1;
}

.coach-hero-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.7rem 1.45rem;
    min-width: 165px;
    border-radius: var(--radius-full);
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    font-family: inherit;
    text-decoration: none;
    white-space: nowrap !important;
    flex-shrink: 0;
}

.coach-hero-btn.primary {
    background: #FFFFFF;
    color: #0B1B3D;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.coach-hero-btn.primary:hover {
    background: #F8FAFC;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.coach-hero-btn.secondary {
    background: rgba(255, 255, 255, 0.15);
    color: #FFFFFF;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.coach-hero-btn.secondary:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
}

/* Quick Action Shortcuts Strip */
.quick-shortcuts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(285px, 1fr));
    gap: 1.15rem;
    margin-bottom: 1.75rem;
}

.quick-shortcut-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 1.15rem 1.35rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    color: inherit;
    box-shadow: 0 1px 3px rgba(0,0,0,0.03);
    min-height: 82px;
}

.quick-shortcut-card:hover {
    border-color: var(--brand-emerald);
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(5, 150, 105, 0.12);
}

.quick-shortcut-icon {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    flex-shrink: 0;
}

.quick-shortcut-icon.blue { background: rgba(37, 99, 235, 0.1); color: var(--brand-blue); }
.quick-shortcut-icon.emerald { background: rgba(5, 150, 105, 0.1); color: var(--brand-emerald); }
.quick-shortcut-icon.amber { background: rgba(217, 119, 6, 0.1); color: var(--brand-gold); }
.quick-shortcut-icon.purple { background: rgba(124, 58, 237, 0.1); color: #7C3AED; }

.quick-shortcut-info h4 {
    font-size: 0.95rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0 0 0.25rem;
    white-space: nowrap;
}

.quick-shortcut-info p {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* View Mode Switcher in Nav Bar */
.view-mode-toggle {
    display: inline-flex;
    align-items: center;
    background: #F1F5F9;
    border: 1px solid #E2E8F0;
    border-radius: var(--radius-full);
    padding: 0.2rem;
    gap: 0.2rem;
    margin-left: 1rem;
}

body.theme-dark .view-mode-toggle {
    background: #1F2937;
    border-color: #374151;
}

.view-mode-btn {
    padding: 0.35rem 0.85rem;
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 700;
    border: none;
    background: transparent;
    color: #64748B;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    font-family: inherit;
}

.view-mode-btn.active {
    background: #FFFFFF;
    color: #0B1B3D;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
}

body.theme-dark .view-mode-btn.active {
    background: #0B1B3D;
    color: #FFFFFF;
}

/* ================================================================
   OMNIPRESENT FLOATING CHAT WIDGET & SLIDE-OVER DRAWER
   ================================================================ */

.floating-chat-root {
    position: relative;
    z-index: 8500;
    pointer-events: none !important;
}

/* Floating Action Launcher Button (pinned at bottom-left in Arabic RTL) */
.floating-chat-btn {
    position: fixed;
    bottom: 28px;
    left: 28px;
    width: 62px;
    height: 62px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0B1B3D 0%, #1D4ED8 100%);
    color: #FFFFFF;
    border: none;
    box-shadow: 0 10px 25px rgba(11, 27, 61, 0.35), 0 4px 10px rgba(0, 0, 0, 0.12);
    cursor: pointer;
    z-index: 8505;
    pointer-events: auto !important;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    outline: none;
    -webkit-tap-highlight-color: transparent;
}

.floating-chat-btn:focus-visible {
    outline: 3px solid #D97706;
    outline-offset: 3px;
}

.floating-chat-btn:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 14px 32px rgba(29, 78, 216, 0.4), 0 0 20px rgba(5, 150, 105, 0.3);
}

.floating-chat-btn:active {
    transform: translateY(-1px) scale(0.98);
}

.chat-launcher-icon-wrap {
    position: relative;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-launcher-icon {
    position: absolute;
    inset: 0;
    transition: transform 0.25s ease, opacity 0.25s ease;
}

.chat-launcher-icon.chat-icon-open {
    opacity: 1;
    transform: rotate(0deg) scale(1);
}

.chat-launcher-icon.chat-icon-close {
    opacity: 0;
    transform: rotate(-90deg) scale(0.6);
}

/* When drawer is open, rotate to close X */
.floating-chat-btn.is-open {
    background: #DC2626;
    box-shadow: 0 10px 25px rgba(220, 38, 38, 0.35);
}

.floating-chat-btn.is-open .chat-launcher-icon.chat-icon-open {
    opacity: 0;
    transform: rotate(90deg) scale(0.6);
}

.floating-chat-btn.is-open .chat-launcher-icon.chat-icon-close {
    opacity: 1;
    transform: rotate(0deg) scale(1);
}

/* Unread Badge */
.chat-launcher-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #DC2626;
    color: #FFFFFF;
    font-size: 0.72rem;
    font-weight: 800;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #FFFFFF;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
    font-family: var(--font-mono, monospace);
}

.chat-launcher-badge.pulse {
    animation: badgePulse 2s infinite;
}

@keyframes badgePulse {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(220, 38, 38, 0.7); }
    70% { transform: scale(1.08); box-shadow: 0 0 0 8px rgba(220, 38, 38, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(220, 38, 38, 0); }
}

/* Status Dot */
.chat-launcher-status-dot {
    position: absolute;
    bottom: 2px;
    right: 2px;
    width: 13px;
    height: 13px;
    border-radius: 50%;
    border: 2px solid #FFFFFF;
    transition: background 0.2s ease;
}

.chat-launcher-status-dot.online {
    background: #10B981;
}

.chat-launcher-status-dot.reconnecting {
    background: #F59E0B;
    animation: dotBlink 1.2s infinite;
}

.chat-launcher-status-dot.offline {
    background: #94A3B8;
}

@keyframes dotBlink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

/* Backdrop Overlay */
.chat-drawer-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(11, 27, 61, 0.45);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 9996;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.chat-drawer-backdrop.is-active {
    opacity: 1;
    pointer-events: auto;
}

/* Slide-Over Drawer Container */
.chat-drawer {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    width: 440px;
    max-width: 95vw;
    background: #FFFFFF;
    z-index: 9997;
    box-shadow: 12px 0 35px rgba(0, 0, 0, 0.22);
    transform: translateX(-105%);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    font-family: inherit;
    direction: rtl;
    pointer-events: none;
}

.chat-drawer.is-open {
    transform: translateX(0);
    pointer-events: auto !important;
}

.chat-drawer.is-fullscreen {
    position: fixed !important;
    inset: 0 !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    max-width: 100vw !important;
    height: 100vh !important;
    max-height: 100vh !important;
    border-radius: 0 !important;
    border: none !important;
    transform: none !important;
    z-index: 99999 !important;
    box-shadow: none !important;
}

body.theme-dark .chat-drawer {
    background: #0F172A;
    border-right: 1px solid #1E293B;
}

/* Drawer Header */
.chat-drawer-header {
    padding: 0.85rem 1rem 0.65rem 1rem;
    background: linear-gradient(135deg, #0B1B3D 0%, #172554 100%);
    color: #FFFFFF;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
}

.chat-drawer.is-fullscreen .chat-drawer-header {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 0.85rem 1.75rem;
}

.chat-drawer-header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 0.75rem;
}

.chat-drawer.is-fullscreen .chat-drawer-header-top {
    width: 100%;
}

.chat-header-main-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
    flex: 1;
}

.chat-header-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #1E40AF 0%, #3B82F6 100%);
    color: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.chat-header-avatar.group {
    background: linear-gradient(135deg, #059669 0%, #10B981 100%);
}

.chat-header-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
    flex: 1;
}

.chat-header-title-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.chat-drawer-title {
    font-size: 0.98rem;
    font-weight: 800;
    color: #FFFFFF;
    margin: 0;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.chat-drawer-subtitle {
    font-size: 0.72rem;
    color: #93C5FD;
    margin: 2px 0 0 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.chat-drawer-header-actions {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-shrink: 0;
}

.chat-drawer-channel-tabs-bar {
    width: 100%;
}

.chat-drawer.is-fullscreen .chat-drawer-channel-tabs-bar {
    display: none;
}

.chat-channel-segmented {
    display: flex;
    width: 100%;
    background: rgba(255, 255, 255, 0.12);
    padding: 3px;
    border-radius: 10px;
    gap: 3px;
}

.chat-channel-segmented .chat-channel-tab-btn {
    flex: 1;
    padding: 0.42rem 0.6rem;
    border-radius: 8px;
    font-size: 0.78rem;
    font-weight: 700;
    color: #E2E8F0;
    border: none;
    background: transparent;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    white-space: nowrap;
    font-family: inherit;
}

.chat-channel-segmented .chat-channel-tab-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    color: #FFFFFF;
}

.chat-channel-segmented .chat-channel-tab-btn.active {
    background: #FFFFFF;
    color: #0B1B3D;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}

body.theme-dark .chat-channel-segmented .chat-channel-tab-btn.active {
    background: #1E293B;
    color: #60A5FA;
}

.chat-drawer-action-btn {
    background: rgba(255, 255, 255, 0.12);
    color: #FFFFFF;
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
    flex-shrink: 0;
}

.chat-drawer-action-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.06);
}

.chat-ws-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 700;
}

.chat-ws-status-badge.online {
    background: rgba(16, 185, 129, 0.2);
    color: #34D399;
    border: 1px solid rgba(16, 185, 129, 0.35);
}

.chat-ws-status-badge.online .ws-status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #34D399;
    box-shadow: 0 0 8px #34D399;
}

.chat-ws-status-badge.reconnecting {
    background: rgba(245, 158, 11, 0.2);
    color: #FBBF24;
    border: 1px solid rgba(245, 158, 11, 0.35);
}

.chat-ws-status-badge.reconnecting .ws-status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #FBBF24;
    animation: dotBlink 1s infinite;
}

.chat-drawer-close-btn {
    background: rgba(255, 255, 255, 0.12);
    color: #FFFFFF;
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
    flex-shrink: 0;
}

.chat-drawer-close-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.06);
}

/* Channel Switcher Tabs */
.chat-drawer-channel-tabs {
    display: flex;
    background: #F1F5F9;
    padding: 0.4rem 0.6rem;
    gap: 0.4rem;
    border-bottom: 1px solid #E2E8F0;
    flex-shrink: 0;
}

body.theme-dark .chat-drawer-channel-tabs {
    background: #1E293B;
    border-color: #334155;
}

.chat-channel-tab-btn {
    flex: 1;
    padding: 0.55rem 0.65rem;
    border-radius: 8px;
    border: none;
    background: transparent;
    font-size: 0.82rem;
    font-weight: 700;
    color: #64748B;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    font-family: inherit;
    white-space: nowrap;
}

.chat-channel-tab-btn:hover {
    color: #0B1B3D;
    background: rgba(255, 255, 255, 0.6);
}

body.theme-dark .chat-channel-tab-btn:hover {
    color: #F8FAFC;
    background: rgba(255, 255, 255, 0.05);
}

.chat-channel-tab-btn.active {
    background: #FFFFFF;
    color: #0B1B3D;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

body.theme-dark .chat-channel-tab-btn.active {
    background: #0B1B3D;
    color: #F8FAFC;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.channel-tab-badge {
    background: #DC2626;
    color: #FFFFFF;
    font-size: 0.68rem;
    font-weight: 800;
    padding: 0.1rem 0.4rem;
    border-radius: 999px;
}

/* Typing Indicator */
.chat-drawer-typing-bar {
    padding: 0.35rem 1.25rem;
    font-size: 0.78rem;
    color: #059669;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(5, 150, 105, 0.08);
    border-bottom: 1px solid rgba(5, 150, 105, 0.15);
    flex-shrink: 0;
}

.typing-bouncing-dots {
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.typing-bouncing-dots .dot {
    width: 5px;
    height: 5px;
    background: #059669;
    border-radius: 50%;
    animation: typingBounce 1.4s infinite ease-in-out both;
}

.typing-bouncing-dots .dot:nth-child(1) { animation-delay: -0.32s; }
.typing-bouncing-dots .dot:nth-child(2) { animation-delay: -0.16s; }

@keyframes typingBounce {
    0%, 80%, 100% { transform: scale(0); }
    40% { transform: scale(1); }
}

/* Drawer Body & Inner */
.chat-drawer-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
    background: #F8FAFC;
}

body.theme-dark .chat-drawer-body {
    background: #0B132B;
}

.chat-drawer-inner {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}

.chat-drawer-interlocutor-bar {
    padding: 0.75rem 1.25rem;
    background: #FFFFFF;
    border-bottom: 1px solid #E2E8F0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

body.theme-dark .chat-drawer-interlocutor-bar {
    background: #111827;
    border-color: #1F2937;
}

.chat-interlocutor-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #0B1B3D;
    color: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 800;
}

.chat-interlocutor-avatar.group {
    background: linear-gradient(135deg, #059669 0%, #10B981 100%);
}

.chat-interlocutor-info {
    flex: 1;
    overflow: hidden;
}

.chat-interlocutor-name {
    font-size: 0.92rem;
    font-weight: 800;
    color: var(--text-primary, #0B1B3D);
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.chat-interlocutor-desc {
    font-size: 0.75rem;
    color: var(--text-muted, #64748B);
    margin: 2px 0 0 0;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.chat-online-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #10B981;
    display: inline-block;
}

/* Messages Scroll Area */
.chat-drawer-messages-scroll {
    flex: 1;
    overflow-y: auto;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    scroll-behavior: smooth;
}

/* Empty State */
.chat-empty-state {
    margin: auto;
    text-align: center;
    padding: 2.5rem 1.5rem;
    color: #94A3B8;
}

.chat-empty-icon {
    font-size: 3rem;
    margin-bottom: 0.75rem;
    opacity: 0.7;
}

.chat-empty-title {
    font-size: 1rem;
    font-weight: 700;
    color: #475569;
    margin-bottom: 0.4rem;
}

.chat-empty-desc {
    font-size: 0.82rem;
    max-width: 280px;
    margin: 0 auto;
    line-height: 1.5;
}

/* Composer Area */
.chat-drawer-composer {
    padding: 0.85rem 1rem;
    background: #FFFFFF;
    border-top: 1px solid #E2E8F0;
    display: flex;
    align-items: flex-end;
    gap: 0.5rem;
    position: relative;
    flex-shrink: 0;
}

body.theme-dark .chat-drawer-composer {
    background: #111827;
    border-color: #1F2937;
}

.chat-attach-btn,
.chat-record-btn {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    border: 1px solid #E2E8F0;
    background: #F8FAFC;
    color: #475569;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.chat-attach-btn:hover,
.chat-record-btn:hover {
    background: #EEF2F6;
    color: #0B1B3D;
    border-color: #CBD5E1;
}

body.theme-dark .chat-attach-btn,
body.theme-dark .chat-record-btn {
    background: #1E293B;
    border-color: #334155;
    color: #94A3B8;
}

.chat-input-field-wrap {
    flex: 1;
    position: relative;
}

.chat-textarea {
    width: 100%;
    resize: none;
    padding: 0.55rem 0.85rem;
    border-radius: 10px;
    border: 1px solid #CBD5E1;
    background: #F8FAFC;
    font-family: inherit;
    font-size: 0.88rem;
    color: #0F172A;
    line-height: 1.35;
    outline: none;
    height: 40px;
    min-height: 40px;
    max-height: 110px;
    overflow-y: auto;
    scrollbar-width: none;
    transition: border-color 0.2s;
    box-sizing: border-box;
    display: block;
}

.chat-textarea::-webkit-scrollbar {
    display: none;
}

.chat-textarea:focus {
    border-color: #2563EB;
    background: #FFFFFF;
}

body.theme-dark .chat-textarea {
    background: #1E293B;
    border-color: #334155;
    color: #F8FAFC;
}

.chat-send-btn {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    border: none;
    background: linear-gradient(135deg, #059669 0%, #10B981 100%);
    color: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(5, 150, 105, 0.3);
}

.chat-send-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 10px rgba(5, 150, 105, 0.4);
}

/* Voice Recording Banner */
.chat-recording-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 0.6rem 0.9rem;
    background: #FEF2F2;
    border: 1px solid #FCA5A5;
    border-radius: 10px;
    animation: bannerPulse 2s infinite ease-in-out;
}

@keyframes bannerPulse {
    0%, 100% { border-color: #FCA5A5; }
    50% { border-color: #EF4444; }
}

.chat-recording-left {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.recording-pulse-dot {
    width: 10px;
    height: 10px;
    background: #DC2626;
    border-radius: 50%;
    animation: dotPulse 1s infinite;
}

@keyframes dotPulse {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.3); opacity: 0.4; }
    100% { transform: scale(1); opacity: 1; }
}

.recording-label {
    font-size: 0.82rem;
    font-weight: 700;
    color: #991B1B;
}

.recording-timer {
    font-size: 0.85rem;
    font-weight: 800;
    color: #DC2626;
    font-family: var(--font-mono, monospace);
}

.chat-recording-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-cancel-recording {
    background: transparent;
    border: 1px solid #DC2626;
    color: #DC2626;
    padding: 0.3rem 0.65rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
}

.btn-send-recording {
    background: #DC2626;
    border: none;
    color: #FFFFFF;
    padding: 0.35rem 0.75rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
}

/* Image Preview in Composer */
.chat-composer-image-preview {
    padding: 0.5rem 1rem;
    background: #FFFFFF;
    border-top: 1px solid #E2E8F0;
}

.composer-preview-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: #F1F5F9;
    padding: 0.4rem 0.6rem;
    border-radius: 8px;
    border: 1px solid #E2E8F0;
}

.composer-preview-thumb {
    width: 44px;
    height: 44px;
    object-fit: cover;
    border-radius: 6px;
}

.composer-preview-info {
    flex: 1;
    overflow: hidden;
}

.composer-preview-filename {
    display: block;
    font-size: 0.8rem;
    font-weight: 700;
    color: #1E293B;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.composer-preview-size {
    display: block;
    font-size: 0.72rem;
    color: #64748B;
}

.composer-preview-remove-btn {
    background: none;
    border: none;
    color: #DC2626;
    font-size: 1.1rem;
    cursor: pointer;
    padding: 0 0.3rem;
}

/* Audio Player in Chat Bubbles */
.chat-audio-player {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.35rem 0;
    min-width: 220px;
}

.audio-play-btn {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #059669;
    color: #FFFFFF;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    flex-shrink: 0;
    transition: transform 0.2s;
}

.audio-play-btn:hover {
    transform: scale(1.08);
}

.chat-message-row.outgoing .audio-play-btn {
    background: #FFFFFF;
    color: #0B1B3D;
}

.audio-waveform-wrap {
    flex: 1;
}

.audio-progress-bar {
    height: 6px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 3px;
    overflow: hidden;
    cursor: pointer;
    position: relative;
}

.chat-message-row.outgoing .audio-progress-bar {
    background: rgba(255, 255, 255, 0.3);
}

.audio-progress-fill {
    height: 100%;
    width: 0%;
    background: #059669;
    border-radius: 3px;
    transition: width 0.1s linear;
}

.chat-message-row.outgoing .audio-progress-fill {
    background: #34D399;
}

.audio-time-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.7rem;
    color: #64748B;
    margin-top: 3px;
    font-family: var(--font-mono, monospace);
}

.chat-message-row.outgoing .audio-time-row {
    color: #CBD5E1;
}

/* Image attachments in chat */
.chat-image-wrap {
    border-radius: 10px;
    overflow: hidden;
    max-width: 260px;
    cursor: pointer;
    position: relative;
    margin-bottom: 0.4rem;
}

.chat-image-preview {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.2s ease;
}

.chat-image-wrap:hover .chat-image-preview {
    transform: scale(1.02);
}

/* Lightbox Modal */
.chat-lightbox-container {
    max-width: 800px;
    width: 90vw;
}

.chat-lightbox-image {
    max-width: 100%;
    max-height: 75vh;
    display: block;
    margin: 0 auto;
    border-radius: 8px;
}

/* Responsive adjustments & interactive clearance */
.table-container,
.coaches-table-card,
.card-panel,
.tab-panel,
.admin-dashboard-wrapper,
.app-main-content {
    margin-bottom: 2.5rem;
    padding-bottom: 5.5rem !important;
}

@media (max-width: 768px) {
    .table-container,
    .coaches-table-card,
    .card-panel,
    .tab-panel,
    .admin-dashboard-wrapper,
    .app-main-content {
        padding-bottom: 5.5rem !important;
    }
}

@media (max-width: 540px) {
    .chat-drawer {
        width: 100vw;
        max-width: 100vw;
    }
    .floating-chat-btn {
        bottom: 16px;
        left: 16px;
        width: 52px;
        height: 52px;
    }
}

/* =========================================================================
   Executive Fullscreen Messenger Layout & Components
   ========================================================================= */

.chat-fullscreen-layout {
    display: flex;
    flex-direction: row;
    width: 100%;
    height: 100%;
    overflow: hidden;
    direction: rtl;
}

.chat-fullscreen-sidebar {
    width: 360px;
    min-width: 320px;
    max-width: 400px;
    background: #F8FAFC;
    border-left: 1px solid #E2E8F0;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    padding: 1.25rem 1rem;
    gap: 1.15rem;
    flex-shrink: 0;
}

body.theme-dark .chat-fullscreen-sidebar {
    background: #0B132B;
    border-left-color: #1E293B;
}

.chat-fs-sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #E2E8F0;
}

body.theme-dark .chat-fs-sidebar-header {
    border-bottom-color: #1E293B;
}

.chat-fs-sidebar-title-wrap {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.chat-fs-sidebar-title-wrap h4 {
    font-size: 0.95rem;
    font-weight: 800;
    margin: 0;
    color: #0B1B3D;
}

body.theme-dark .chat-fs-sidebar-title-wrap h4 {
    color: #F8FAFC;
}

.chat-fs-channels-badge {
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    background: #E2E8F0;
    color: #475569;
}

body.theme-dark .chat-fs-channels-badge {
    background: #1E293B;
    color: #94A3B8;
}

.chat-fs-channels-list {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.chat-fs-channel-card {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.85rem 1rem;
    border-radius: 12px;
    background: #FFFFFF;
    border: 1px solid #E2E8F0;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: right;
}

.chat-fs-channel-card:hover {
    border-color: #CBD5E1;
    background: #F1F5F9;
    transform: translateY(-1px);
}

.chat-fs-channel-card.active {
    background: #EFF6FF;
    border-color: #3B82F6;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.15);
}

body.theme-dark .chat-fs-channel-card {
    background: #1E293B;
    border-color: #334155;
}

body.theme-dark .chat-fs-channel-card.active {
    background: #172554;
    border-color: #2563EB;
}

.chat-fs-chan-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    position: relative;
    flex-shrink: 0;
}

.chat-fs-chan-avatar.direct {
    background: linear-gradient(135deg, #0B1B3D 0%, #1D4ED8 100%);
    color: #FFFFFF;
}

.chat-fs-chan-avatar.group {
    background: linear-gradient(135deg, #059669 0%, #10B981 100%);
    color: #FFFFFF;
}

.chat-fs-avatar-status {
    position: absolute;
    bottom: 1px;
    right: 1px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 2px solid #FFFFFF;
}

body.theme-dark .chat-fs-avatar-status {
    border-color: #1E293B;
}

.chat-fs-avatar-status.online {
    background: #10B981;
}

.chat-fs-avatar-status.cohort {
    background: #3B82F6;
}

.chat-fs-chan-details {
    flex: 1;
    min-width: 0;
}

.chat-fs-chan-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.2rem;
}

.chat-fs-chan-name {
    font-size: 0.88rem;
    font-weight: 800;
    color: #0B1B3D;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

body.theme-dark .chat-fs-chan-name {
    color: #F8FAFC;
}

.chat-fs-chan-time {
    font-size: 0.7rem;
    color: #94A3B8;
    white-space: nowrap;
    font-family: var(--font-mono, monospace);
}

.chat-fs-chan-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

.chat-fs-chan-preview {
    font-size: 0.78rem;
    color: #64748B;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

body.theme-dark .chat-fs-chan-preview {
    color: #94A3B8;
}

.chat-fs-unread-pill {
    background: #DC2626;
    color: #FFFFFF;
    font-size: 0.68rem;
    font-weight: 800;
    padding: 0.1rem 0.45rem;
    border-radius: 999px;
    flex-shrink: 0;
}

.chat-fs-info-card {
    margin-top: auto;
    background: linear-gradient(135deg, #0B1B3D 0%, #172554 100%);
    color: #FFFFFF;
    border-radius: 14px;
    padding: 1.15rem;
    box-shadow: 0 4px 14px rgba(11, 27, 61, 0.15);
}

.chat-fs-info-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.65rem;
    gap: 0.4rem;
}

.chat-fs-info-badge {
    background: rgba(245, 158, 11, 0.25);
    color: #FCD34D;
    border: 1px solid rgba(245, 158, 11, 0.4);
    font-size: 0.68rem;
    font-weight: 800;
    padding: 0.2rem 0.5rem;
    border-radius: 6px;
}

.chat-fs-info-accreditation {
    font-size: 0.72rem;
    color: #93C5FD;
    font-weight: 700;
}

.chat-fs-info-desc {
    font-size: 0.76rem;
    line-height: 1.5;
    color: #E2E8F0;
    margin: 0 0 0.85rem 0;
}

.chat-fs-info-metrics {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 0.5rem;
    text-align: center;
}

.chat-fs-metric-item .metric-num {
    display: block;
    font-size: 0.95rem;
    font-weight: 900;
    color: #F8FAFC;
    font-family: var(--font-mono, monospace);
}

.chat-fs-metric-item .metric-lbl {
    font-size: 0.65rem;
    color: #93C5FD;
}

/* Main Workspace in Fullscreen */
.chat-fullscreen-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
    min-width: 0;
    background: #FFFFFF;
    position: relative;
}

body.theme-dark .chat-fullscreen-main {
    background: #0F172A;
}

.chat-fs-active-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.85rem 1.5rem;
    background: #F8FAFC;
    border-bottom: 1px solid #E2E8F0;
    flex-shrink: 0;
}

body.theme-dark .chat-fs-active-banner {
    background: #111827;
    border-bottom-color: #1F2937;
}

.chat-fs-active-info {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

.chat-fs-active-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
}

.chat-fs-active-avatar.direct {
    background: linear-gradient(135deg, #0B1B3D 0%, #1D4ED8 100%);
    color: #FFFFFF;
}

.chat-fs-active-avatar.group {
    background: linear-gradient(135deg, #059669 0%, #10B981 100%);
    color: #FFFFFF;
}

.chat-fs-active-title {
    font-size: 1rem;
    font-weight: 800;
    color: #0B1B3D;
    margin: 0;
}

body.theme-dark .chat-fs-active-title {
    color: #F8FAFC;
}

.chat-fs-active-sub {
    font-size: 0.76rem;
    color: #64748B;
    margin: 2px 0 0 0;
}

body.theme-dark .chat-fs-active-sub {
    color: #94A3B8;
}

.chat-fs-active-tags {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.chat-fs-tag-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.65rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
}

.chat-fs-tag-badge.encryption-badge {
    background: #ECFDF5;
    color: #059669;
    border: 1px solid #A7F3D0;
}

body.theme-dark .chat-fs-tag-badge.encryption-badge {
    background: rgba(5, 150, 105, 0.2);
    color: #34D399;
    border-color: rgba(5, 150, 105, 0.4);
}

.chat-fs-tag-badge.channel-kind-tag {
    background: #EFF6FF;
    color: #2563EB;
    border: 1px solid #BFDBFE;
}

body.theme-dark .chat-fs-tag-badge.channel-kind-tag {
    background: rgba(37, 99, 235, 0.2);
    color: #60A5FA;
    border-color: rgba(37, 99, 235, 0.4);
}

.chat-fullscreen-messages {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    max-width: 960px;
    margin: 0 auto;
    width: 100%;
}

.chat-fullscreen-composer-wrap {
    padding: 0.85rem 1.5rem 1.25rem 1.5rem;
    background: #FFFFFF;
    border-top: 1px solid #E2E8F0;
    width: 100%;
}

body.theme-dark .chat-fullscreen-composer-wrap {
    background: #0F172A;
    border-top-color: #1E293B;
}

.chat-fs-composer-inner {
    display: flex;
    align-items: flex-end;
    gap: 0.65rem;
    width: 100%;
    max-width: 920px;
    margin: 0 auto;
    background: #F8FAFC;
    border: 1px solid #CBD5E1;
    border-radius: 26px;
    padding: 0.4rem 0.75rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
    transition: all 0.2s ease;
}

body.theme-dark .chat-fs-composer-inner {
    background: #1E293B;
    border-color: #334155;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.chat-fs-composer-inner:focus-within {
    border-color: #3B82F6;
    background: #FFFFFF;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

body.theme-dark .chat-fs-composer-inner:focus-within {
    background: #0F172A;
    border-color: #60A5FA;
}

.chat-fs-composer-inner .chat-textarea {
    border: none;
    background: transparent;
    box-shadow: none;
    padding: 0.45rem 0.5rem;
}

.chat-fs-composer-inner .chat-textarea:focus {
    border: none;
    box-shadow: none;
    background: transparent;
}

/* Audio mic tag */
.audio-mic-tag {
    font-size: 0.68rem;
    color: #059669;
    font-weight: 700;
}

.chat-message-row.outgoing .audio-mic-tag {
    color: #93C5FD;
}

/* ==========================================================================
   PREMIUM VECTOR ICON SYSTEM & LUXURY SAAS UI POLISH
   ========================================================================== */

.ui-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: -0.15em;
    flex-shrink: 0;
    stroke: currentColor;
    fill: none;
    line-height: 1;
    transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1), stroke 0.2s ease, filter 0.2s ease;
}

.ui-icon.inline-icon {
    margin-left: 0.4rem;
    vertical-align: -0.18em;
}

[dir="ltr"] .ui-icon.inline-icon {
    margin-left: 0;
    margin-right: 0.4rem;
}

/* Button Icon Integration */
.btn .ui-icon,
.btn-primary .ui-icon,
.btn-outline .ui-icon,
.btn-secondary .ui-icon,
.btn-gold .ui-icon,
.btn-sm .ui-icon,
.btn-xs .ui-icon {
    margin-left: 0.4rem;
    vertical-align: middle;
}

.btn:hover .ui-icon,
.btn-primary:hover .ui-icon,
.btn-gold:hover .ui-icon {
    transform: translateY(-1px) scale(1.04);
}

.btn-xs .ui-icon {
    margin-left: 0.25rem;
}

/* Sticky Navigation Pills Icons */
.sticky-nav-pill .ui-icon {
    margin-left: 0.45rem;
    stroke-width: 2.2;
    transition: transform 0.2s ease, stroke 0.2s ease;
}

.sticky-nav-pill:hover .ui-icon {
    transform: scale(1.12);
}

.sticky-nav-pill.active .ui-icon {
    transform: scale(1.15);
    stroke: var(--brand-emerald, #059669);
}

/* Section Header Icon Box */
.sec-icon-box {
    background: linear-gradient(135deg, rgba(5, 150, 105, 0.12) 0%, rgba(11, 27, 61, 0.05) 100%);
    border: 1px solid rgba(5, 150, 105, 0.2);
    box-shadow: 0 4px 14px rgba(5, 150, 105, 0.1);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.sec-icon-box:hover {
    transform: translateY(-2px) scale(1.03);
    box-shadow: 0 6px 18px rgba(5, 150, 105, 0.18);
}

.sec-icon-box .ui-icon {
    stroke-width: 2;
}

/* Badge and Status Icons */
.badge-status .ui-icon,
.status-pill .ui-icon {
    margin-left: 0.3rem;
    vertical-align: -0.12em;
}

/* Luxury Card & Certificate Elevation */
.kpi-card {
    border: 1px solid rgba(203, 213, 225, 0.85);
    box-shadow: 0 2px 8px rgba(11, 27, 61, 0.04), 0 10px 24px -6px rgba(11, 27, 61, 0.05);
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease, border-color 0.25s ease;
}

.kpi-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(11, 27, 61, 0.06), 0 16px 32px -6px rgba(11, 27, 61, 0.08);
    border-color: rgba(5, 150, 105, 0.4);
}

.modern-task-card {
    border: 1px solid rgba(226, 232, 240, 0.9);
    box-shadow: 0 2px 8px rgba(11, 27, 61, 0.03), 0 8px 20px -4px rgba(11, 27, 61, 0.04);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.modern-task-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(11, 27, 61, 0.08);
    border-color: rgba(11, 27, 61, 0.18);
}

/* Premium Gold Accent for Official Certificate & Audit */
.certificate-container {
    box-shadow: 0 8px 32px rgba(11, 27, 61, 0.08), 0 1px 3px rgba(11, 27, 61, 0.04);
    border: 1px solid #E2E8F0;
    position: relative;
}

.certificate-container::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, #D97706 0%, #F59E0B 50%, #B45309 100%);
    border-top-left-radius: inherit;
    border-top-right-radius: inherit;
}

/* Micro-interactions on interactive cards */
.coach-hero-stat-card {
    box-shadow: 0 2px 6px rgba(11, 27, 61, 0.03), 0 8px 20px -4px rgba(11, 27, 61, 0.05);
    border: 1px solid rgba(226, 232, 240, 0.85);
}

/* ==========================================================================
   ACCESSIBILITY, DIALOGS, MOBILE FULLSCREEN & SKELETON ENHANCEMENTS
   ========================================================================== */

/* Accessibility Skip Link (WCAG 2.4.1) */
.skip-link {
    position: fixed;
    top: -120px;
    right: 20px;
    background: #0B1B3D;
    color: #FFFFFF;
    padding: 0.75rem 1.25rem;
    border-radius: 8px;
    border: 2px solid #D97706;
    font-weight: 700;
    font-size: 0.9rem;
    z-index: 9999999;
    text-decoration: none;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
    transition: top 0.25s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s;
    pointer-events: none !important;
    opacity: 0;
    visibility: hidden;
}

.skip-link:focus-visible {
    top: 20px;
    outline: none;
    pointer-events: auto !important;
    opacity: 1;
    visibility: visible;
}

/* Focus Visible Rings for Keyboard Accessibility (WCAG 2.4.7) */
:focus-visible {
    outline: 2px solid #2563EB;
    outline-offset: 2px;
}

button:focus-visible,
select:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #2563EB;
    outline-offset: 2px;
}

/* Accessible Custom Confirmation & Alert Dialog */
.confirm-dialog-card {
    max-width: 460px;
    width: 90vw;
    background: var(--bg-surface, #FFFFFF);
    border-radius: var(--radius-lg, 16px);
    box-shadow: 0 20px 45px rgba(11, 27, 61, 0.25);
    border: 1px solid var(--border-accent, #E2E8F0);
    overflow: hidden;
    animation: modalScaleUp 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

body.theme-dark .confirm-dialog-card {
    background: #0F172A;
    border-color: #334155;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.6);
}

.confirm-dialog-header {
    padding: 1.15rem 1.4rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border-bottom: 1px solid var(--border-subtle, #F1F5F9);
}

.confirm-dialog-header.danger {
    background: #FEF2F2;
    color: #991B1B;
}

body.theme-dark .confirm-dialog-header.danger {
    background: #450A0A;
    color: #FECACA;
}

.confirm-dialog-header.warning {
    background: #FFFBEB;
    color: #92400E;
}

body.theme-dark .confirm-dialog-header.warning {
    background: #451A03;
    color: #FDE68A;
}

.confirm-dialog-header.info {
    background: #EFF6FF;
    color: #1E40AF;
}

body.theme-dark .confirm-dialog-header.info {
    background: #172554;
    color: #BFDBFE;
}

.confirm-dialog-body {
    padding: 1.4rem;
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-primary, #0B1B3D);
}

.confirm-dialog-footer {
    padding: 0.9rem 1.4rem;
    background: var(--bg-card, #F8FAFC);
    border-top: 1px solid var(--border-subtle, #F1F5F9);
    display: flex;
    justify-content: flex-end;
    gap: 0.65rem;
}

body.theme-dark .confirm-dialog-footer {
    background: #0B132B;
    border-top-color: #1E293B;
}

/* Inline Form Validation Highlights */
.form-input.is-invalid,
input.is-invalid,
textarea.is-invalid,
select.is-invalid {
    border-color: #DC2626 !important;
    background-color: #FEF2F2 !important;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.15) !important;
}

body.theme-dark input.is-invalid,
body.theme-dark textarea.is-invalid {
    background-color: #450A0A !important;
    border-color: #EF4444 !important;
}

.inline-field-error {
    color: #DC2626;
    font-size: 0.78rem;
    font-weight: 600;
    margin-top: 0.35rem;
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

/* Skeleton Loading Shimmer Utility */
.skeleton-box {
    background: linear-gradient(90deg, #F1F5F9 25%, #E2E8F0 50%, #F1F5F9 75%);
    background-size: 200% 100%;
    animation: skeletonShimmer 1.5s infinite;
    border-radius: 6px;
}

body.theme-dark .skeleton-box {
    background: linear-gradient(90deg, #1E293B 25%, #334155 50%, #1E293B 75%);
    background-size: 200% 100%;
}

@keyframes skeletonShimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Mobile Responsive Layout and Ergonomics */
@media (max-width: 768px) {
    html, body {
        overflow-x: hidden !important;
        max-width: 100vw !important;
        width: 100% !important;
        position: relative;
    }

    .app-header {
        width: 100% !important;
        max-width: 100vw !important;
    }

    .header-inner {
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        padding: 0.6rem 0.85rem !important;
        gap: 0.65rem !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    .brand-section {
        flex: 1 !important;
        min-width: 0 !important;
        width: auto !important;
    }

    .brand-logo-img {
        height: 36px;
    }

    .brand-title {
        font-size: 0.95rem !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    .brand-subtitle {
        display: none !important;
    }

    .header-actions {
        width: auto !important;
        display: flex !important;
        align-items: center !important;
        justify-content: flex-end !important;
        gap: 0.5rem !important;
        flex-shrink: 0 !important;
    }

    .user-session-widget {
        width: 100% !important;
        flex-basis: 100% !important;
    }

    .role-switcher-box {
        width: 100% !important;
        flex-basis: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        padding: 0.35rem 0.75rem !important;
    }

    .role-label {
        display: none;
    }

    select, .role-select {
        width: 100% !important;
        min-width: 0 !important;
        font-size: 0.8rem !important;
        box-sizing: border-box !important;
    }

    .mode-toggle-group {
        width: 100% !important;
        flex-basis: 100% !important;
        display: flex !important;
        box-sizing: border-box !important;
    }

    .mode-toggle-btn {
        flex: 1 !important;
        justify-content: center !important;
        text-align: center !important;
        padding: 0.35rem 0.4rem !important;
        font-size: 0.74rem !important;
        white-space: nowrap !important;
    }

    .btn-icon-action {
        flex: 0 0 auto !important;
        width: 38px !important;
        height: 38px !important;
        min-width: 38px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        padding: 0 !important;
    }

    /* Primary Navigation Bar (Tabs) Mobile Scrolling */
    .main-nav-bar {
        width: 100% !important;
        max-width: 100vw !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
        scrollbar-width: none !important;
        box-sizing: border-box !important;
    }

    .main-nav-bar::-webkit-scrollbar {
        display: none !important;
    }

    .nav-tabs-container {
        width: max-content !important;
        min-width: 100% !important;
        padding: 0 0.5rem !important;
        gap: 0.35rem !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        box-sizing: border-box !important;
    }

    .nav-tab-btn {
        flex-shrink: 0 !important;
        padding: 0.5rem 0.75rem !important;
        font-size: 0.82rem !important;
        white-space: nowrap !important;
        gap: 0.35rem !important;
    }

    .view-mode-toggle {
        margin-left: 0.35rem !important;
        padding: 0.15rem !important;
        flex-shrink: 0 !important;
    }

    .view-mode-btn {
        padding: 0.25rem 0.5rem !important;
        font-size: 0.72rem !important;
        white-space: nowrap !important;
    }

    /* Quick Status Strip Mobile Layout */
    .quick-status-strip {
        width: 100% !important;
        max-width: 100vw !important;
        overflow-x: hidden !important;
        padding: 0.5rem 0.75rem !important;
        box-sizing: border-box !important;
    }

    .status-strip-inner {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0.5rem !important;
    }

    .candidate-mini-info {
        white-space: normal !important;
        flex-wrap: wrap !important;
        width: 100% !important;
        font-size: 0.82rem !important;
        line-height: 1.4 !important;
    }

    .candidate-mini-info strong,
    .candidate-mini-info span {
        white-space: normal !important;
    }

    .status-metrics-group {
        width: 100% !important;
        display: flex !important;
        flex-wrap: wrap !important;
        justify-content: flex-start !important;
        gap: 0.35rem 0.75rem !important;
        font-size: 0.78rem !important;
    }

    .status-metric-pill {
        white-space: nowrap !important;
    }

    /* Sticky Quick-Navigation Anchor Bar */
    .coach-sticky-nav-bar {
        border-radius: var(--radius-md) !important;
        padding: 0.35rem 0.5rem !important;
        width: 100% !important;
        max-width: 100vw !important;
        margin-bottom: 1rem !important;
        top: var(--app-header-height, 68px) !important;
        z-index: 95 !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
        scrollbar-width: none !important;
        box-sizing: border-box !important;
        flex-wrap: nowrap !important;
    }

    .coach-sticky-nav-bar::-webkit-scrollbar {
        display: none !important;
    }

    .sticky-nav-pill {
        padding: 0.35rem 0.75rem !important;
        font-size: 0.78rem !important;
        flex-shrink: 0 !important;
        white-space: nowrap !important;
    }

    /* Main Content Area & Mode Onepage */
    .app-main-content {
        padding: 0.75rem 0.6rem 2.5rem !important;
        width: 100% !important;
        max-width: 100vw !important;
        box-sizing: border-box !important;
        overflow-x: hidden !important;
    }

    .app-main-content.mode-onepage {
        gap: 1.25rem !important;
        padding-top: 0.5rem !important;
    }

    .app-main-content.mode-onepage .tab-panel {
        padding: 1rem 0.65rem 1.25rem !important;
        border-radius: var(--radius-lg) !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        margin-bottom: 0 !important;
    }

    .tab-panel {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    /* Hero Summary Card Spans 100% */
    .coach-hero-summary-card {
        padding: 1.25rem 0.85rem !important;
        border-radius: var(--radius-md) !important;
        margin-bottom: 1.25rem !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    .coach-hero-summary-card::before {
        display: none !important;
    }

    .coach-hero-info {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 0.75rem !important;
        width: 100% !important;
    }

    .coach-hero-texts {
        width: 100% !important;
    }

    .coach-hero-texts h2 {
        font-size: 1.15rem !important;
        line-height: 1.35 !important;
    }

    .coach-hero-texts p {
        font-size: 0.8rem !important;
        line-height: 1.4 !important;
        gap: 0.35rem !important;
    }

    .coach-hero-actions {
        width: 100% !important;
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0.5rem !important;
    }

    .coach-hero-btn {
        width: 100% !important;
        min-width: 0 !important;
        justify-content: center !important;
        padding: 0.65rem 1rem !important;
        font-size: 0.82rem !important;
    }

    /* Responsive Grids & Cards */
    .cards-grid-3,
    .cards-grid-4,
    .tasks-grid,
    .domains14-grid,
    .quant-dashboard-overview,
    .quick-shortcuts-grid {
        grid-template-columns: 1fr !important;
        gap: 0.85rem !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    .standard-card {
        padding: 1rem 0.85rem !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    /* Competencies View Switcher */
    .comps-view-switcher {
        width: 100% !important;
        max-width: 100% !important;
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0.4rem !important;
        box-sizing: border-box !important;
        padding: 0.35rem !important;
    }

    .comps-switch-btn {
        width: 100% !important;
        white-space: normal !important;
        text-align: center !important;
        justify-content: center !important;
        padding: 0.6rem 0.75rem !important;
        font-size: 0.82rem !important;
    }

    /* Official Dossier Sheet */
    .official-dossier-sheet {
        padding: 1.25rem 0.75rem !important;
        margin: 0 auto 1.5rem !important;
        width: 100% !important;
        max-width: 100% !important;
        overflow: hidden !important;
        box-sizing: border-box !important;
    }

    .dossier-watermark {
        font-size: 2.2rem !important;
        max-width: 90vw !important;
        overflow: hidden !important;
    }

    .dossier-summary-table {
        display: block !important;
        width: 100% !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
    }

    /* Subtabs & Segmented Navs (Tools, Rubrics) */
    .tool-subtabs,
    .rubric-tabs-nav {
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
        scrollbar-width: none !important;
        flex-wrap: nowrap !important;
        box-sizing: border-box !important;
        padding-bottom: 0.25rem !important;
    }

    .tool-subtabs::-webkit-scrollbar,
    .rubric-tabs-nav::-webkit-scrollbar {
        display: none !important;
    }

    .tool-subtab-btn,
    .rubric-tab-btn {
        flex-shrink: 0 !important;
        white-space: nowrap !important;
        font-size: 0.8rem !important;
        padding: 0.5rem 0.75rem !important;
    }

    /* Admin Segmented Tabs Mobile Wrap */
    .admin-segmented-tabs {
        width: 100% !important;
        max-width: 100% !important;
        flex-wrap: wrap !important;
        box-sizing: border-box !important;
        padding: 0.35rem !important;
        gap: 0.4rem !important;
    }

    .admin-tab-btn {
        flex: 1 1 auto !important;
        white-space: normal !important;
        font-size: 0.78rem !important;
        padding: 0.45rem 0.65rem !important;
        text-align: center !important;
        justify-content: center !important;
    }

    .chat-drawer {
        width: 100vw;
        max-width: 100vw;
    }

    .chat-textarea {
        resize: none;
    }

    .chat-fullscreen-layout {
        flex-direction: column;
    }

    .chat-fullscreen-sidebar {
        width: 100%;
        min-width: 0;
        max-width: 100%;
        max-height: 150px;
        border-left: none;
        border-bottom: 1px solid var(--border-subtle);
        padding: 0.65rem 0.75rem;
        gap: 0.65rem;
    }

    .chat-fullscreen-main {
        flex: 1;
        min-height: 0;
    }

    .cohorts-grid {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }

    .cohort-card {
        padding: 1rem !important;
    }

    .cohort-targets-grid {
        grid-template-columns: 1fr !important;
    }

    .audit-table {
        display: block !important;
        width: 100% !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
    }
}

/* Reduced Motion Support (WCAG 2.3.3) */
@media (prefers-reduced-motion: reduce) {
    *, ::before, ::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Footer Landmark Styling */
.app-footer {
    background: #0B1B3D;
    color: #94A3B8;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 1.5rem;
    margin-top: 3.5rem;
    font-size: 0.85rem;
}

.footer-inner {
    max-width: 1440px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-brand strong {
    color: #FFFFFF;
    margin-left: 0.5rem;
}

/* ==========================================================================
   Tamkeen Al-Roaya Master Coach Platform - Interactive Guided Tour Styling
   ========================================================================== */

/* Header Tour Info Button Pulse Badge */
#btn-tour-info.tour-pulse {
    position: relative;
    border-color: rgba(217, 119, 6, 0.45);
    color: var(--brand-gold, #D97706);
    background: rgba(217, 119, 6, 0.08);
}

#btn-tour-info.tour-pulse::after {
    content: '';
    position: absolute;
    top: -3px;
    right: -3px;
    width: 8px;
    height: 8px;
    border-radius: var(--radius-full);
    background: var(--brand-gold, #D97706);
    box-shadow: 0 0 10px rgba(217, 119, 6, 0.9);
    animation: tourDotPulse 2s infinite cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes tourDotPulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.35);
        opacity: 0.6;
    }
}

/* Tour Backdrop Veil */
.tamkeen-tour-backdrop {
    position: fixed;
    inset: 0;
    z-index: 99990;
    background: transparent;
    opacity: 0;
    display: none !important;
    pointer-events: none !important;
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.tamkeen-tour-backdrop.active {
    display: block !important;
    opacity: 1;
    pointer-events: auto !important;
}

/* Spotlight Highlight Frame */
.tamkeen-tour-highlight-box {
    position: fixed;
    z-index: 99995;
    pointer-events: none !important;
    display: none;
    border-radius: var(--radius-md, 12px);
    border: 2px solid var(--brand-gold, #D97706);
    box-shadow: 0 0 0 9999px rgba(11, 27, 61, 0.78),
                0 0 25px rgba(217, 119, 6, 0.5),
                inset 0 0 16px rgba(217, 119, 6, 0.25);
    transition: top 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                left 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                width 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                height 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                border-radius 0.25s ease;
}

/* Tour Popover Card */
.tamkeen-tour-popover {
    position: fixed;
    z-index: 100000;
    width: 460px;
    max-width: calc(100vw - 32px);
    background: var(--bg-surface, #FFFFFF);
    color: var(--text-primary, #0B1B3D);
    border: 1px solid var(--border-gold, rgba(217, 119, 6, 0.35));
    border-radius: var(--radius-lg, 16px);
    box-shadow: 0 20px 45px -10px rgba(11, 27, 61, 0.45),
                0 0 30px rgba(217, 119, 6, 0.18);
    direction: rtl;
    padding: 1.25rem;
    box-sizing: border-box;
    opacity: 0;
    display: none !important;
    pointer-events: none !important;
    transform: translateY(10px) scale(0.97);
    transition: opacity 0.25s ease, transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: var(--font-sans, 'Tajawal', 'Cairo', sans-serif);
}

.tamkeen-tour-popover.active {
    display: block !important;
    pointer-events: auto !important;
    opacity: 1;
    transform: translateY(0) scale(1);
}

.tour-popover-inner {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

/* Popover Header */
.tour-popover-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding-bottom: 0.65rem;
    border-bottom: 1px solid var(--border-subtle);
}

.tour-header-badges {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.tour-step-badge {
    background: rgba(217, 119, 6, 0.12);
    color: var(--brand-gold, #D97706);
    border: 1px solid rgba(217, 119, 6, 0.3);
    padding: 0.2rem 0.6rem;
    border-radius: var(--radius-full);
    font-size: 0.76rem;
    font-weight: 700;
    font-family: var(--font-mono, monospace);
}

.tour-role-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.2rem 0.65rem;
    border-radius: var(--radius-full);
    font-size: 0.74rem;
    font-weight: 700;
}

.tour-role-badge.coach {
    background: rgba(5, 150, 105, 0.1);
    color: var(--status-emerald, #059669);
    border: 1px solid rgba(5, 150, 105, 0.25);
}

.tour-role-badge.admin {
    background: rgba(29, 78, 216, 0.1);
    color: var(--brand-blue, #1D4ED8);
    border: 1px solid rgba(29, 78, 216, 0.25);
}

.tour-header-actions {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.tour-switch-role-btn {
    background: none;
    border: 1px solid var(--border-subtle);
    color: var(--text-secondary);
    padding: 0.2rem 0.55rem;
    border-radius: var(--radius-sm);
    font-size: 0.72rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.tour-switch-role-btn:hover {
    background: var(--bg-input);
    color: var(--text-primary);
    border-color: var(--border-accent);
}

.tour-btn-close {
    background: none;
    border: none;
    color: var(--text-muted);
    line-height: 1;
    cursor: pointer;
    padding: 0.3rem;
    border-radius: var(--radius-sm);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: color var(--transition-fast), transform var(--transition-fast);
}

.tour-btn-close:hover {
    color: var(--status-crimson, #DC2626);
    transform: scale(1.1);
}

.tour-btn-close svg {
    pointer-events: none;
}

/* Popover Body */
.tour-popover-body {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.tour-step-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0;
    line-height: 1.4;
    font-family: var(--font-heading, 'Cairo', sans-serif);
}

.tour-step-subtitle {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--brand-blue-light, #3B82F6);
    margin-top: -0.2rem;
}

.tour-step-desc {
    font-size: 0.86rem;
    color: var(--text-secondary);
    line-height: 1.55;
    margin: 0.2rem 0 0.4rem 0;
}

.tour-step-guidance {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    background: rgba(217, 119, 6, 0.08);
    border: 1px solid rgba(217, 119, 6, 0.22);
    border-right: 3px solid var(--brand-gold, #D97706);
    border-radius: var(--radius-sm);
    padding: 0.6rem 0.75rem;
    margin-top: 0.2rem;
}

.tour-guidance-icon {
    color: var(--brand-gold, #D97706);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    margin-top: 2px;
}

.tour-guidance-text {
    font-size: 0.8rem;
    color: var(--text-primary);
    line-height: 1.45;
}

/* Popover Footer */
.tour-popover-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border-subtle);
    flex-wrap: wrap;
}

.tour-progress-dots {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.tour-progress-dot {
    width: 8px;
    height: 8px;
    border-radius: var(--radius-full);
    border: none;
    background: var(--border-subtle);
    padding: 0;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.tour-progress-dot.active {
    width: 22px;
    background: var(--brand-gold, #D97706);
    box-shadow: 0 0 8px rgba(217, 119, 6, 0.6);
}

.tour-progress-dot.completed {
    background: var(--status-emerald, #059669);
}

.tour-action-buttons {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tour-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.45rem 0.85rem;
    border-radius: var(--radius-md);
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    transition: all var(--transition-fast);
    border: 1px solid transparent;
}

.tour-btn-skip {
    background: transparent;
    color: var(--text-muted);
    padding: 0.45rem 0.55rem;
}

.tour-btn-skip:hover {
    color: var(--text-primary);
    text-decoration: underline;
}

.tour-nav-group {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.tour-btn-prev {
    background: var(--bg-input);
    color: var(--text-primary);
    border-color: var(--border-subtle);
}

.tour-btn-prev:hover:not(:disabled) {
    background: var(--bg-card-hover);
    border-color: var(--border-accent);
}

.tour-btn-prev:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.tour-btn-next {
    background: var(--brand-navy, #0B1B3D);
    color: #FFFFFF;
    border-color: var(--brand-navy);
}

.tour-btn-next:hover {
    background: var(--brand-blue, #1D4ED8);
    border-color: var(--brand-blue);
    box-shadow: var(--shadow-glow-blue);
}

.tour-btn-next.finish {
    background: var(--status-emerald, #059669);
    border-color: var(--status-emerald);
}

.tour-btn-next.finish:hover {
    background: var(--status-emerald-light, #10B981);
    box-shadow: var(--shadow-glow-emerald);
}

/* Mobile Responsive Optimization (<= 640px) */
@media (max-width: 640px) {
    .tamkeen-tour-popover {
        left: 12px !important;
        right: 12px !important;
        bottom: 14px !important;
        top: auto !important;
        width: auto !important;
        max-width: calc(100vw - 24px) !important;
        margin: 0 !important;
        transform: translateY(0) scale(1) !important;
        padding: 1rem;
        box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.45);
    }

    .tamkeen-tour-popover.dock-top {
        top: 76px !important;
        bottom: auto !important;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
    }

    .tour-step-title {
        font-size: 1.05rem;
    }

    .tour-step-desc {
        font-size: 0.8rem;
    }

    .tour-step-guidance {
        padding: 0.5rem 0.65rem;
    }

    .tour-guidance-text {
        font-size: 0.76rem;
    }

    .tour-popover-footer {
        gap: 0.5rem;
    }

    .tour-progress-dot {
        width: 6px;
        height: 6px;
    }

    .tour-progress-dot.active {
        width: 16px;
    }

    .tour-btn {
        padding: 0.4rem 0.65rem;
        font-size: 0.78rem;
    }
}

/* ==========================================================================
   Tamkeen v3.0 Interactive Live Audio Recording, Waveforms & Curriculum Modals
   ========================================================================== */

.live-recorder-panel {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    text-align: center;
    margin-bottom: 1.25rem;
    position: relative;
    box-shadow: var(--shadow-sm);
}

.recorder-status-banner {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    margin-bottom: 1rem;
    background: rgba(2, 132, 199, 0.12);
    color: var(--brand-primary, #0284C7);
    border: 1px solid rgba(2, 132, 199, 0.3);
}

.recorder-status-banner.recording {
    background: rgba(220, 38, 38, 0.15);
    color: #EF4444;
    border-color: rgba(220, 38, 38, 0.35);
}

.recorder-status-banner.paused {
    background: rgba(245, 158, 11, 0.15);
    color: #F59E0B;
    border-color: rgba(245, 158, 11, 0.35);
}

.recorder-status-banner.completed {
    background: rgba(5, 150, 105, 0.15);
    color: #10B981;
    border-color: rgba(5, 150, 105, 0.35);
}

.recording-pulse-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: #EF4444;
    display: inline-block;
    animation: pulseRecDot 1.2s infinite ease-in-out;
}

@keyframes pulseRecDot {
    0% { transform: scale(0.9); opacity: 0.6; }
    50% { transform: scale(1.3); opacity: 1; }
    100% { transform: scale(0.9); opacity: 0.6; }
}

.recorder-timer-display {
    font-family: var(--font-mono);
    font-size: 2.5rem;
    font-weight: 800;
    letter-spacing: 2px;
    color: var(--text-primary);
    margin: 0.5rem 0 1rem;
}

.live-wave-meter {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    height: 48px;
    margin: 1rem auto;
    max-width: 320px;
}

.live-meter-bar {
    width: 6px;
    background: var(--border-accent);
    border-radius: 3px;
    height: 12%;
    transition: height 0.12s ease, background-color 0.2s ease;
}

.live-wave-meter.active .live-meter-bar {
    background: linear-gradient(180deg, #38BDF8, #2563EB);
    animation: meterBounce 0.8s infinite alternate ease-in-out;
}

.live-wave-meter.active .live-meter-bar:nth-child(2n) { animation-duration: 0.6s; }
.live-wave-meter.active .live-meter-bar:nth-child(3n) { animation-duration: 0.9s; }
.live-wave-meter.active .live-meter-bar:nth-child(4n) { animation-duration: 0.75s; }
.live-wave-meter.active .live-meter-bar:nth-child(5n) { animation-duration: 0.65s; }

@keyframes meterBounce {
    0% { height: 15%; }
    50% { height: 85%; }
    100% { height: 35%; }
}

.recorder-controls-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 1.25rem;
}

.modal-tabs-segmented {
    display: flex;
    background: var(--bg-input);
    border-radius: var(--radius-md);
    padding: 4px;
    margin-bottom: 1.25rem;
    border: 1px solid var(--border-subtle);
    gap: 4px;
}

.modal-tab-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    border-radius: calc(var(--radius-md) - 2px);
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.88rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.modal-tab-btn:hover {
    color: var(--text-primary);
}

.modal-tab-btn.active {
    background: var(--bg-card);
    color: var(--brand-blue-light, #38BDF8);
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    border: 1px solid var(--border-accent);
}

.curriculum-guidance-card {
    background: rgba(2, 132, 199, 0.05);
    border-right: 4px solid var(--brand-primary, #0284C7);
    border-top: 1px solid var(--border-subtle);
    border-left: 1px solid var(--border-subtle);
    border-bottom: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    padding: 1rem 1.25rem;
    margin-bottom: 1.25rem;
    font-size: 0.84rem;
    line-height: 1.6;
}

.curriculum-guidance-card h4 {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--brand-primary, #0284C7);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.curriculum-guidance-card ul {
    margin: 0.4rem 0 0.4rem 1.25rem;
    padding: 0;
}

.curriculum-guidance-card li {
    margin-bottom: 0.35rem;
    color: var(--text-secondary);
}

.curriculum-guidance-card strong {
    color: var(--text-primary);
}

.empty-state-action-card {
    grid-column: 1 / -1;
    background: var(--bg-card);
    border: 1px dashed var(--border-accent);
    border-radius: var(--radius-lg);
    padding: 2.25rem 1.75rem;
    text-align: center;
    box-shadow: var(--shadow-sm);
}

.empty-state-title {
    font-weight: 700;
    font-size: 1.15rem;
    color: var(--text-primary);
    margin-bottom: 0.4rem;
}

.empty-state-subtitle {
    color: var(--text-muted);
    font-size: 0.86rem;
    max-width: 600px;
    margin: 0 auto 1.5rem;
}

.empty-state-actions-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 1.25rem;
}

.live-audio-preview-box {
    margin-top: 1rem;
    padding: 0.75rem;
    background: var(--bg-input);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
}

/* ==========================================================================
   Executive Polish: Empty States, Micro-interactions & Visual Hierarchy
   ========================================================================== */

.empty-state-icon-box {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 68px;
    height: 68px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(2, 132, 199, 0.12) 0%, rgba(5, 150, 105, 0.08) 100%);
    border: 1px solid rgba(2, 132, 199, 0.22);
    box-shadow: 0 4px 16px rgba(2, 132, 199, 0.1);
    margin: 0 auto 1rem;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
}

body.theme-dark .empty-state-icon-box {
    background: linear-gradient(135deg, rgba(2, 132, 199, 0.2) 0%, rgba(5, 150, 105, 0.15) 100%);
    border-color: rgba(2, 132, 199, 0.35);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.empty-state-icon-box:hover {
    transform: scale(1.08) translateY(-2px);
    box-shadow: 0 8px 24px rgba(2, 132, 199, 0.22);
}

.cycle-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
    color: var(--brand-primary);
    opacity: 0.85;
    margin: 0 4px;
}

/* Enhanced Focus & Micro-Interactions */
.btn:active,
.view-mode-btn:active,
.sticky-nav-pill:active {
    transform: scale(0.97);
}

.btn:focus-visible,
.btn-icon-action:focus-visible,
.view-mode-btn:focus-visible,
.btn-close-modal:focus-visible,
.tour-btn-close:focus-visible,
.nav-tab-btn:focus-visible {
    outline: 2px solid var(--brand-primary, #0284c7) !important;
    outline-offset: 2px !important;
    box-shadow: 0 0 0 4px rgba(2, 132, 199, 0.25) !important;
}

/* Modal Elevation & Animation */
.modal-overlay {
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.modal-container {
    animation: modalScaleUp 0.26s cubic-bezier(0.16, 1, 0.3, 1);
    border: 1px solid rgba(203, 213, 225, 0.85);
    box-shadow: 0 25px 60px -15px rgba(11, 27, 61, 0.28), 0 0 0 1px rgba(255, 255, 255, 0.1);
}

body.theme-dark .modal-container {
    border-color: rgba(51, 65, 85, 0.9);
    box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.7);
}

@keyframes modalScaleUp {
    from {
        opacity: 0;
        transform: scale(0.96) translateY(12px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* ==========================================================================
   PRODUCTION UPGRADES: LIVE NOTIFICATIONS HUB, OFFICIAL CERTIFICATE,
   NETWORK RECONNECTION BADGE, DATA TABLE SEARCH & DARK MODE PARITY
   ========================================================================== */

/* 1. Real-Time Cloud Network Status Badge */
.network-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.35rem 0.75rem;
    border-radius: var(--radius-full);
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-normal);
    border: 1px solid transparent;
    user-select: none;
}

.network-status-badge.online {
    background: rgba(5, 150, 105, 0.12);
    color: #059669;
    border-color: rgba(5, 150, 105, 0.28);
}

body.theme-dark .network-status-badge.online {
    background: rgba(16, 185, 129, 0.15);
    color: #34D399;
    border-color: rgba(16, 185, 129, 0.35);
}

.network-status-badge.reconnecting {
    background: rgba(217, 119, 6, 0.12);
    color: #D97706;
    border-color: rgba(217, 119, 6, 0.35);
}

body.theme-dark .network-status-badge.reconnecting {
    background: rgba(245, 158, 11, 0.18);
    color: #FBBF24;
    border-color: rgba(245, 158, 11, 0.38);
}

.network-status-badge.offline {
    background: rgba(220, 38, 38, 0.12);
    color: #DC2626;
    border-color: rgba(220, 38, 38, 0.35);
}

body.theme-dark .network-status-badge.offline {
    background: rgba(239, 68, 68, 0.18);
    color: #F87171;
    border-color: rgba(239, 68, 68, 0.38);
}

.status-ping-dot {
    position: relative;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: currentColor;
    flex-shrink: 0;
}

.network-status-badge.online .status-ping-dot::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border-radius: 50%;
    background-color: currentColor;
    opacity: 0.45;
    animation: pingAnimation 2s cubic-bezier(0, 0, 0.2, 1) infinite;
}

@keyframes pingAnimation {
    75%, 100% {
        transform: scale(2.2);
        opacity: 0;
    }
}

/* 2. Live Notifications Hub */
.notification-hub-wrapper {
    position: relative;
    display: inline-flex;
}

.btn-notifications {
    position: relative;
}

.notification-badge {
    position: absolute;
    top: -4px;
    left: -4px;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    border-radius: 999px;
    background: #DC2626;
    color: #FFFFFF;
    font-size: 0.68rem;
    font-weight: 800;
    font-family: var(--font-mono);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--bg-surface);
    box-shadow: 0 2px 4px rgba(220, 38, 38, 0.35);
}

.notification-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    width: 390px;
    max-width: 92vw;
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    box-shadow: 0 16px 40px -10px rgba(11, 27, 61, 0.22), 0 0 0 1px rgba(0, 0, 0, 0.05);
    z-index: 1000;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: dropdownFadeIn 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

body.theme-dark .notification-dropdown {
    background: #0E1726;
    border-color: rgba(255, 255, 255, 0.12);
    box-shadow: 0 20px 45px -10px rgba(0, 0, 0, 0.7);
}

@keyframes dropdownFadeIn {
    from {
        opacity: 0;
        transform: translateY(-8px) scale(0.97);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.notification-dropdown-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.85rem 1rem;
    border-bottom: 1px solid var(--border-subtle);
    background: rgba(2, 132, 199, 0.04);
}

body.theme-dark .notification-dropdown-header {
    background: rgba(2, 132, 199, 0.08);
}

.notification-header-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.92rem;
    font-weight: 800;
    color: var(--text-primary);
}

.notification-unread-chip {
    background: var(--accent-cyan);
    color: #FFFFFF;
    font-size: 0.7rem;
    font-weight: 800;
    padding: 1px 7px;
    border-radius: 999px;
    font-family: var(--font-mono);
}

.btn-mark-all-read,
.notif-action-btn {
    background: none;
    border: none;
    color: var(--brand-blue-light);
    font-size: 0.76rem;
    font-weight: 700;
    cursor: pointer;
    padding: 3px 6px;
    border-radius: var(--radius-sm);
    transition: background var(--transition-fast);
}

.btn-mark-all-read:hover,
.notif-action-btn:hover {
    background: rgba(59, 130, 246, 0.1);
    text-decoration: underline;
}

.notif-close-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 3px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
}

.notif-close-btn:hover {
    color: var(--text-primary);
    background: rgba(0, 0, 0, 0.06);
}

body.theme-dark .notif-close-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.notification-filter-tabs {
    display: flex;
    gap: 0.35rem;
    padding: 0.5rem 0.75rem;
    overflow-x: auto;
    border-bottom: 1px solid var(--border-subtle);
    background: var(--bg-surface);
    scrollbar-width: none;
}

.notification-filter-tabs::-webkit-scrollbar {
    display: none;
}

.notif-tab-btn,
.notif-filter-tab {
    background: var(--bg-input);
    border: 1px solid transparent;
    color: var(--text-secondary);
    padding: 0.28rem 0.65rem;
    border-radius: var(--radius-full);
    font-size: 0.72rem;
    font-weight: 600;
    white-space: nowrap;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.notif-tab-btn:hover,
.notif-filter-tab:hover {
    background: rgba(2, 132, 199, 0.1);
    color: var(--accent-cyan);
}

.notif-tab-btn.active,
.notif-filter-tab.active {
    background: var(--brand-navy);
    color: #FFFFFF;
    border-color: var(--brand-navy);
}

body.theme-dark .notif-tab-btn,
body.theme-dark .notif-filter-tab {
    background: #1E293B;
    color: var(--text-secondary);
}

body.theme-dark .notif-tab-btn.active,
body.theme-dark .notif-filter-tab.active {
    background: var(--brand-blue);
    border-color: var(--brand-blue);
    color: #FFFFFF;
}

.notification-list,
.notification-items-list {
    max-height: 380px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.notification-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border-bottom: 1px solid var(--border-subtle);
    cursor: pointer;
    transition: background var(--transition-fast);
    position: relative;
    text-decoration: none;
}

.notification-item:hover {
    background: rgba(2, 132, 199, 0.05);
}

body.theme-dark .notification-item:hover {
    background: rgba(59, 130, 246, 0.12);
}

.notification-item.unread {
    background: rgba(2, 132, 199, 0.04);
}

body.theme-dark .notification-item.unread {
    background: rgba(30, 58, 138, 0.18);
}

.notification-item.read {
    background: transparent;
}

.notification-item-unread-dot,
.notif-unread-dot {
    position: absolute;
    top: 14px;
    left: 12px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--brand-blue-light);
    box-shadow: 0 0 6px var(--brand-blue-light);
    flex-shrink: 0;
}

.notification-type-icon,
.notif-item-icon {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 2px;
    background: rgba(2, 132, 199, 0.1);
}

.notification-type-icon.voice_note {
    background: rgba(124, 58, 237, 0.12);
    color: #7C3AED;
}

.notification-type-icon.task_review {
    background: rgba(2, 132, 199, 0.12);
    color: #0284C7;
}

.notification-type-icon.rubric_eval,
.notification-type-icon.rubric_update {
    background: rgba(217, 119, 6, 0.12);
    color: #D97706;
}

.notification-type-icon.cohort_update,
.notification-type-icon.cohort_announcement {
    background: rgba(5, 150, 105, 0.12);
    color: #059669;
}

.notification-type-icon.ethics_alert,
.notification-type-icon.ethics_clearance {
    background: rgba(16, 185, 129, 0.12);
    color: #10B981;
}

.notification-type-icon.chat_msg {
    background: rgba(37, 99, 235, 0.12);
    color: #2563EB;
}

.notification-content,
.notif-item-content {
    flex: 1;
    min-width: 0;
}

.notif-item-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 2px;
}

.notification-item-title,
.notif-item-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 2px;
    line-height: 1.35;
}

.notification-item-time,
.notif-item-time {
    font-size: 0.68rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-weight: 400;
    white-space: nowrap;
}

.notification-item-desc,
.notif-item-message {
    font-size: 0.77rem;
    color: var(--text-secondary);
    line-height: 1.45;
    margin: 0;
}

.notification-empty-state {
    padding: 2.5rem 1.5rem;
    text-align: center;
    color: var(--text-muted);
}

.notification-empty-icon {
    margin: 0 auto 0.75rem;
    opacity: 0.6;
}

/* 3. Global Instant Search & Data Table Filters */
.data-table-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: wrap;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 0.75rem 1rem;
    margin-bottom: 1rem;
}

body.theme-dark .data-table-toolbar {
    background: var(--bg-card);
    border-color: var(--border-subtle);
}

.toolbar-search-wrap {
    position: relative;
    flex: 1;
    min-width: 220px;
    max-width: 360px;
}

.toolbar-search-input {
    width: 100%;
    padding: 0.45rem 2.2rem 0.45rem 1.8rem;
    border-radius: var(--radius-full);
    border: 1px solid var(--border-subtle);
    background: var(--bg-input);
    color: var(--text-primary);
    font-size: 0.82rem;
    font-family: var(--font-sans);
    outline: none;
    transition: all var(--transition-fast);
}

.toolbar-search-input:focus {
    border-color: var(--brand-primary, #0284c7);
    box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15);
    background: var(--bg-surface);
}

.toolbar-search-icon {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    pointer-events: none;
    display: flex;
}

.toolbar-search-clear {
    position: absolute;
    left: 0.6rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 2px;
    display: flex;
    border-radius: 50%;
}

.toolbar-search-clear:hover {
    color: var(--text-primary);
}

.toolbar-filter-group {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-wrap: wrap;
}

.toolbar-filter-pill {
    padding: 0.32rem 0.75rem;
    border-radius: var(--radius-full);
    background: var(--bg-input);
    border: 1px solid transparent;
    color: var(--text-secondary);
    font-size: 0.74rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
    user-select: none;
}

.toolbar-filter-pill:hover {
    background: rgba(2, 132, 199, 0.1);
    color: var(--accent-cyan);
}

.toolbar-filter-pill.active {
    background: var(--brand-navy);
    border-color: var(--brand-navy);
    color: #FFFFFF;
}

body.theme-dark .toolbar-filter-pill.active {
    background: var(--brand-blue);
    border-color: var(--brand-blue);
    color: #FFFFFF;
}

.toolbar-results-count {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 600;
    margin-right: auto;
}

.modal-dialog,
.cert-modal-dialog {
    background: var(--bg-surface);
    border-radius: var(--radius-lg);
    box-shadow: 0 25px 60px -15px rgba(11, 27, 61, 0.35);
    border: 1px solid var(--border-subtle);
    animation: modalScaleUp 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    max-height: 90vh;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
    box-sizing: border-box;
}

.cert-modal-dialog {
    max-width: 960px;
    width: 95vw;
}

body.theme-dark .cert-modal-dialog,
body.theme-dark .modal-dialog {
    background: #0E1726;
    border-color: #1E293B;
    box-shadow: 0 25px 70px -15px rgba(0, 0, 0, 0.85);
    color: var(--text-primary);
}

/* Modal Dark Theme Contrast and Typography Parity */
body.theme-dark .modal-container,
body.theme-dark .modal-dialog {
    background: #0E1726;
    color: var(--text-primary);
    border-color: #1E293B;
}

body.theme-dark .modal-container h1,
body.theme-dark .modal-container h2,
body.theme-dark .modal-container h3,
body.theme-dark .modal-container h4,
body.theme-dark .modal-container h5,
body.theme-dark .modal-container strong,
body.theme-dark .modal-container label,
body.theme-dark .modal-dialog h1,
body.theme-dark .modal-dialog h2,
body.theme-dark .modal-dialog h3,
body.theme-dark .modal-dialog h4,
body.theme-dark .modal-dialog h5,
body.theme-dark .modal-dialog strong,
body.theme-dark .modal-dialog label {
    color: var(--text-primary) !important;
}

body.theme-dark .modal-container [style*="color:#0B1B3D"],
body.theme-dark .modal-container [style*="color: #0B1B3D"],
body.theme-dark .modal-dialog [style*="color:#0B1B3D"],
body.theme-dark .modal-dialog [style*="color: #0B1B3D"] {
    color: var(--text-primary) !important;
}

.cert-modal-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.85rem 1.5rem;
    background: #0B1B3D;
    color: #FFFFFF;
    border-bottom: 2px solid #D4AF37;
}

body.theme-dark .cert-modal-toolbar {
    background: #060E20;
    border-color: #B45309;
}

.cert-modal-toolbar-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.05rem;
    font-weight: 800;
    color: #F8FAFC;
}

.cert-modal-toolbar-actions {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.royal-cert-outer {
    padding: 2rem;
    background: #F8FAFC;
    overflow-y: auto;
    max-height: calc(85vh - 70px);
}

body.theme-dark .royal-cert-outer {
    background: #070D18;
}

.royal-cert-frame {
    position: relative;
    background: #FFFFFF;
    color: #0B1B3D;
    border: 12px double #D4AF37;
    border-radius: 12px;
    padding: 3rem 2.5rem;
    box-shadow: 0 10px 30px rgba(11, 27, 61, 0.12), inset 0 0 40px rgba(212, 175, 55, 0.08);
    background-image: radial-gradient(circle at center, rgba(212, 175, 55, 0.03) 0%, transparent 70%);
}

.royal-cert-watermark {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-25deg);
    font-size: 5rem;
    font-weight: 900;
    color: rgba(212, 175, 55, 0.04);
    letter-spacing: 12px;
    pointer-events: none;
    user-select: none;
    white-space: nowrap;
    z-index: 1;
}

.royal-cert-header {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 2px solid rgba(212, 175, 55, 0.35);
    padding-bottom: 1.5rem;
    margin-bottom: 2rem;
}

.royal-cert-emblem {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    max-width: 170px;
}

.royal-cert-emblem-crest {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0B1B3D 0%, #1D4ED8 100%);
    border: 2px solid #D4AF37;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #D4AF37;
    margin-bottom: 0.4rem;
    box-shadow: 0 4px 10px rgba(11, 27, 61, 0.2);
}

.royal-cert-center-titles {
    text-align: center;
    flex: 1;
    padding: 0 1rem;
}

.royal-cert-super-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #475569;
    letter-spacing: 0.5px;
    margin-bottom: 0.4rem;
}

.royal-cert-main-title {
    font-size: 1.85rem;
    font-weight: 900;
    color: #0B1B3D;
    line-height: 1.3;
    margin-bottom: 0.4rem;
    text-shadow: 0 1px 2px rgba(11, 27, 61, 0.1);
}

.royal-cert-sub-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: #B45309;
    font-family: var(--font-mono);
}

.royal-cert-body {
    position: relative;
    z-index: 2;
    text-align: center;
    margin-bottom: 2rem;
}

.royal-cert-preamble {
    font-size: 1.05rem;
    color: #334155;
    line-height: 1.8;
    margin-bottom: 1.25rem;
}

.royal-cert-candidate-name {
    display: inline-block;
    font-size: 2.1rem;
    font-weight: 900;
    color: #0B1B3D;
    padding: 0.4rem 2.5rem;
    border-bottom: 3px double #D4AF37;
    margin: 0.5rem 0 1.25rem;
}

.royal-cert-achievement-text {
    font-size: 1.02rem;
    color: #1E293B;
    line-height: 1.85;
    max-width: 820px;
    margin: 0 auto 1.5rem;
}

.royal-cert-verdict-banner {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.15) 0%, rgba(5, 150, 105, 0.12) 100%);
    border: 1px solid #D4AF37;
    padding: 0.6rem 1.8rem;
    border-radius: var(--radius-full);
    font-size: 1.05rem;
    font-weight: 800;
    color: #065F46;
    margin-bottom: 1.5rem;
}

.royal-cert-metrics-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    background: #F8FAFC;
    border: 1px solid #E2E8F0;
    border-radius: var(--radius-md);
    padding: 1rem;
    margin-bottom: 2.25rem;
    text-align: center;
}

.royal-cert-metric-item strong {
    display: block;
    font-size: 1.25rem;
    font-family: var(--font-mono);
    color: #0B1B3D;
}

.royal-cert-metric-item span {
    font-size: 0.78rem;
    color: #64748B;
    font-weight: 600;
}

.royal-cert-footer {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 1fr 140px 140px 1fr;
    gap: 1.5rem;
    align-items: center;
    border-top: 2px solid rgba(212, 175, 55, 0.35);
    padding-top: 1.75rem;
}

.royal-cert-sig-block {
    text-align: center;
}

.royal-cert-sig-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: #475569;
    margin-bottom: 0.25rem;
}

.royal-cert-sig-script {
    font-size: 1.4rem;
    font-weight: 900;
    color: #0B1B3D;
    font-family: 'Cairo', cursive;
    margin: 0.5rem 0;
}

.royal-cert-sig-name {
    font-size: 0.95rem;
    font-weight: 800;
    color: #0B1B3D;
}

.royal-cert-sig-sub {
    font-size: 0.72rem;
    color: #64748B;
    font-family: var(--font-mono);
}

.royal-cert-seal-wrap {
    text-align: center;
}

.royal-cert-gold-seal {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    background: radial-gradient(circle, #F59E0B 0%, #D4AF37 50%, #B45309 100%);
    border: 3px dashed #FFFFFF;
    box-shadow: 0 4px 14px rgba(180, 83, 9, 0.35);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #FFFFFF;
    text-align: center;
    margin: 0 auto;
}

.royal-cert-seal-text1 {
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 0.5px;
}

.royal-cert-seal-text2 {
    font-size: 0.78rem;
    font-weight: 900;
}

.royal-cert-seal-text3 {
    font-size: 0.65rem;
    font-family: var(--font-mono);
    font-weight: 700;
}

.royal-cert-qr-wrap {
    text-align: center;
}

.royal-cert-qr-box {
    display: inline-block;
    padding: 6px;
    background: #FFFFFF;
    border: 1px solid #CBD5E1;
    border-radius: 6px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.royal-cert-qr-caption {
    font-size: 0.65rem;
    color: #64748B;
    margin-top: 4px;
    font-weight: 600;
}

/* Print Overrides for Certificate */
@media print {
    body.is-printing-cert * {
        visibility: hidden !important;
    }

    body.is-printing-cert #certificate-modal,
    body.is-printing-cert #certificate-modal * {
        visibility: visible !important;
    }

    body.is-printing-cert #certificate-modal {
        position: absolute !important;
        left: 0 !important;
        top: 0 !important;
        width: 100% !important;
        background: #FFFFFF !important;
        padding: 0 !important;
    }

    body.is-printing-cert .cert-modal-toolbar,
    body.is-printing-cert .btn-close-modal,
    body.is-printing-cert .no-print {
        display: none !important;
    }

    body.is-printing-cert .royal-cert-outer {
        padding: 0 !important;
        background: transparent !important;
        max-height: none !important;
        overflow: visible !important;
    }

    body.is-printing-cert .royal-cert-frame {
        border-width: 8px !important;
        box-shadow: none !important;
        padding: 2rem !important;
        page-break-inside: avoid !important;
    }

    @page {
        size: A4 landscape;
        margin: 10mm;
    }
}

/* ================================================================
   COACH ACTION & SUBMISSION PORTAL HUB (Deliverables Action Hub)
   ================================================================ */

.coach-action-portal-hub {
    margin-top: 1.5rem;
    margin-bottom: 2.5rem;
}

.portal-hub-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
    padding-bottom: 1rem;
    margin-bottom: 1.25rem;
    border-bottom: 2px solid var(--border-subtle);
}

.hub-header-title {
    display: flex;
    align-items: center;
    gap: 0.65rem;
}

.hub-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(5, 150, 105, 0.12);
    color: var(--brand-emerald);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.submission-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
    gap: 1.25rem;
}

.sub-action-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 1.25rem 1.35rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
    position: relative;
    overflow: hidden;
}

.sub-action-card:hover {
    border-color: var(--brand-emerald);
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(5, 150, 105, 0.14);
}

.sub-action-card.highlight {
    border-color: var(--brand-gold);
    background: linear-gradient(180deg, rgba(217, 119, 6, 0.04) 0%, var(--bg-surface) 100%);
}

.sub-action-card.highlight:hover {
    border-color: #F59E0B;
    box-shadow: 0 8px 24px rgba(245, 158, 11, 0.18);
}

.sub-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.85rem;
}

.sub-card-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: rgba(11, 27, 61, 0.06);
    color: var(--brand-blue);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.2s, color 0.2s;
}

body.theme-dark .sub-card-icon {
    background: rgba(255, 255, 255, 0.08);
    color: #60A5FA;
}

.sub-action-card:hover .sub-card-icon {
    background: rgba(5, 150, 105, 0.15);
    color: var(--brand-emerald);
}

.sub-card-badge {
    font-size: 0.78rem;
    font-weight: 700;
    padding: 0.25rem 0.65rem;
    border-radius: var(--radius-full);
    font-family: var(--font-mono, monospace);
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.sub-card-badge.completed {
    background: rgba(5, 150, 105, 0.12);
    color: #059669;
    border: 1px solid rgba(5, 150, 105, 0.28);
}

body.theme-dark .sub-card-badge.completed {
    background: rgba(16, 185, 129, 0.2);
    color: #34D399;
    border-color: rgba(16, 185, 129, 0.4);
}

.sub-card-badge.pending {
    background: rgba(11, 27, 61, 0.07);
    color: var(--text-secondary);
    border: 1px solid var(--border-subtle);
}

body.theme-dark .sub-card-badge.pending {
    background: rgba(255, 255, 255, 0.06);
    color: #94A3B8;
}

.sub-action-card h4 {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0 0 0.45rem;
    line-height: 1.35;
}

.sub-action-card p {
    font-size: 0.84rem;
    color: var(--text-secondary);
    margin: 0 0 1.15rem;
    line-height: 1.5;
    flex-grow: 1;
}

.sub-card-btn-wrap {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-top: auto;
}

.sub-card-btn-wrap .btn {
    font-size: 0.82rem;
    font-weight: 700;
    padding: 0.45rem 0.85rem;
    border-radius: 8px;
    transition: all 0.2s ease;
}

@media (max-width: 768px) {
    .submission-cards-grid {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   MARKETING-GRADE PUBLIC LANDING PAGE & CANDIDATE ONBOARDING SUITE v3.0
   ========================================================================== */

/* Public Landing Header Navigation */
.landing-public-nav {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-left: 1rem;
}

.landing-nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.4rem 0.75rem;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
    white-space: nowrap;
}

.landing-nav-link:hover {
    color: var(--brand-blue-light);
    background: rgba(29, 78, 216, 0.08);
}

@media (max-width: 1100px) {
    .landing-public-nav {
        display: none !important;
    }
}

/* Hide internal operational actions for unauthenticated visitors on public landing page */
body.landing-page-active #btn-certificate-viewer,
body.landing-page-active #btn-tour-info,
body.landing-page-active #btn-export-data,
body.landing-page-active #btn-reset-data,
body.landing-page-active #btn-print-report,
body.landing-page-active #notification-hub-wrapper,
body.landing-page-active #floating-chat-launcher {
    display: none !important;
}

/* Guest Preview Banner */
.guest-preview-banner {
    background: linear-gradient(90deg, rgba(16, 185, 129, 0.12) 0%, rgba(59, 130, 246, 0.12) 100%);
    border-bottom: 1px solid rgba(16, 185, 129, 0.3);
    padding: 0.6rem 1.5rem;
    position: relative;
    z-index: 90;
}

.guest-preview-banner-inner {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.guest-preview-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.guest-preview-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Candidate ID Badges */
.user-candidate-id-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-gold);
    background: rgba(217, 119, 6, 0.12);
    border: 1px solid rgba(217, 119, 6, 0.35);
    padding: 0.2rem 0.6rem;
    border-radius: 6px;
    letter-spacing: 0.5px;
}

.candidate-code-chip {
    font-family: var(--font-mono);
    font-weight: 700;
    color: var(--status-amber);
    background: rgba(217, 119, 6, 0.12);
    border: 1px solid rgba(217, 119, 6, 0.3);
    border-radius: 4px;
    padding: 2px 7px;
    font-size: 0.75rem;
    display: inline-block;
}

/* Landing Page Wrapper & Containers */
.public-landing-page {
    width: 100%;
    min-height: 100vh;
    background: var(--bg-page);
    color: var(--text-primary);
    overflow-x: hidden;
    position: relative;
    padding-bottom: 90px;
}

.landing-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1.5rem;
    position: relative;
}

/* Hero Section */
.landing-hero-section {
    position: relative;
    padding: 4.5rem 0 3.5rem 0;
    background: radial-gradient(circle at 50% 10%, rgba(29, 78, 216, 0.08) 0%, rgba(11, 27, 61, 0) 70%),
                linear-gradient(180deg, var(--bg-surface) 0%, var(--bg-page) 100%);
    border-bottom: 1px solid var(--border-subtle);
    overflow: hidden;
}

.landing-hero-backdrop {
    position: absolute;
    top: -200px;
    right: 50%;
    transform: translateX(50%);
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.1) 0%, rgba(59, 130, 246, 0) 70%);
    pointer-events: none;
    z-index: 1;
}

.landing-hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 1000px;
    margin: 0 auto;
}

.landing-badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(29, 78, 216, 0.08);
    border: 1px solid rgba(29, 78, 216, 0.25);
    padding: 0.4rem 1.1rem;
    border-radius: var(--radius-full);
    font-size: 0.84rem;
    font-weight: 700;
    color: var(--brand-blue-light);
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10B981;
    box-shadow: 0 0 8px #10B981;
}

.landing-hero-title {
    font-size: 2.75rem;
    font-weight: 900;
    color: var(--text-primary);
    line-height: 1.25;
    margin: 0 0 1.25rem 0;
    letter-spacing: -0.5px;
}

.landing-title-highlight {
    display: block;
    margin-top: 0.4rem;
    background: linear-gradient(135deg, #1D4ED8 0%, #0284C7 50%, #D97706 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-size: 1.95rem;
    font-weight: 800;
}

.landing-hero-subtitle {
    font-size: 1.12rem;
    line-height: 1.75;
    color: var(--text-secondary);
    max-width: 880px;
    margin: 0 auto 2.25rem auto;
}

.landing-hero-ctas {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.85rem;
    flex-wrap: wrap;
    margin-bottom: 3.5rem;
}

.btn-landing-primary {
    background: linear-gradient(135deg, #1D4ED8 0%, #0284C7 100%);
    color: #FFFFFF;
    font-size: 1rem;
    font-weight: 800;
    padding: 0.95rem 1.85rem;
    border-radius: var(--radius-md);
    border: none;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(29, 78, 216, 0.3);
    transition: all 0.25s ease;
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.btn-landing-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(29, 78, 216, 0.4);
    background: linear-gradient(135deg, #2563EB 0%, #0369A1 100%);
}

.btn-landing-secondary {
    background: var(--bg-surface);
    color: var(--text-primary);
    font-size: 0.95rem;
    font-weight: 700;
    padding: 0.95rem 1.6rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.btn-landing-secondary:hover {
    background: var(--bg-card-hover);
    border-color: var(--brand-blue-light);
    color: var(--brand-blue-light);
    transform: translateY(-2px);
}

.btn-landing-ghost {
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.95rem;
    font-weight: 700;
    padding: 0.95rem 1.4rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
}

.btn-landing-ghost:hover {
    background: rgba(15, 23, 42, 0.04);
    color: var(--text-primary);
}

.btn-landing-preview {
    background: rgba(16, 185, 129, 0.08);
    color: #059669;
    font-size: 0.95rem;
    font-weight: 700;
    padding: 0.95rem 1.4rem;
    border-radius: var(--radius-md);
    border: 1px solid rgba(16, 185, 129, 0.3);
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
}

.btn-landing-preview:hover {
    background: rgba(16, 185, 129, 0.16);
    transform: translateY(-2px);
}

/* Apple Spring Physics: Instant Touch Feedback */
.btn-landing-primary:active,
.btn-landing-secondary:active,
.btn-landing-ghost:active,
.btn-landing-preview:active {
    transform: scale(0.97) !important;
    transition: transform 100ms ease-out !important;
}

/* High-Impact Trust Badge Strip (Above-The-Fold) */
.landing-trust-strip {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin: 0 auto 3rem auto;
    max-width: 1040px;
    width: 100%;
}

.trust-badge-card {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 1rem 1.15rem;
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(217, 119, 6, 0.22);
    border-radius: var(--radius-lg);
    box-shadow: 0 4px 18px rgba(11, 27, 61, 0.04);
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    text-align: right;
}

[data-theme="dark"] .trust-badge-card {
    background: rgba(17, 24, 39, 0.75);
    border-color: rgba(217, 119, 6, 0.32);
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.25);
}

.trust-badge-card:hover {
    transform: translateY(-2px);
    border-color: #D97706;
    box-shadow: 0 8px 24px rgba(217, 119, 6, 0.15);
}

.trust-badge-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    min-width: 44px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(217, 119, 6, 0.16) 0%, rgba(245, 158, 11, 0.06) 100%);
    color: #D97706;
}

.trust-badge-info {
    flex-grow: 1;
    overflow: hidden;
}

.trust-badge-title {
    font-size: 0.88rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 0.2rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.trust-badge-text {
    font-size: 0.74rem;
    color: var(--text-secondary);
    line-height: 1.35;
}

@media (max-width: 992px) {
    .landing-trust-strip {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .landing-trust-strip {
        grid-template-columns: 1fr;
    }
}

/* =========================================================================
   Executive Benchmark Comparison Matrix
   ========================================================================= */
.landing-comparison-section {
    padding: 5rem 0;
    background: var(--bg-surface);
    border-bottom: 1px solid var(--border-subtle);
}

.comparison-matrix-wrapper {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: 0 12px 35px rgba(11, 27, 61, 0.05);
}

[data-theme="dark"] .comparison-matrix-wrapper {
    background: var(--bg-card);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.3);
}

.comparison-matrix-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    text-align: right;
}

.comparison-matrix-table th,
.comparison-matrix-table td {
    padding: 1.25rem 1.4rem;
    border-bottom: 1px solid var(--border-subtle);
    vertical-align: middle;
}

.comparison-matrix-table th {
    font-size: 0.95rem;
    font-weight: 800;
    color: var(--text-primary);
}

.comparison-matrix-table .col-criterion {
    width: 25%;
    background: var(--bg-card);
}

.comparison-matrix-table .col-conventional {
    width: 35%;
    background: rgba(239, 68, 68, 0.03);
    color: var(--text-secondary);
}

.comparison-matrix-table .col-master-coach.highlight-col {
    width: 40%;
    background: linear-gradient(180deg, rgba(29, 78, 216, 0.08) 0%, rgba(5, 150, 105, 0.06) 100%);
    border-top: 2px solid #1D4ED8;
    border-right: 2px solid #1D4ED8;
    border-left: 2px solid #1D4ED8;
    border-top-left-radius: var(--radius-xl);
    position: relative;
}

.col-head-title {
    font-size: 1.05rem;
    font-weight: 900;
    margin-bottom: 0.2rem;
}

.col-head-sub {
    font-size: 0.76rem;
    font-weight: 600;
    color: var(--text-muted);
}

.featured-badge {
    position: absolute;
    top: 8px;
    left: 16px;
    background: linear-gradient(135deg, #D97706 0%, #F59E0B 100%);
    color: #FFFFFF;
    font-size: 0.72rem;
    font-weight: 800;
    padding: 3px 10px;
    border-radius: 999px;
    box-shadow: 0 2px 8px rgba(217, 119, 6, 0.3);
}

.comparison-matrix-table .cell-criterion {
    font-weight: 800;
    color: var(--text-primary);
    font-size: 0.92rem;
    background: var(--bg-card);
}

.comparison-matrix-table .cell-conventional {
    color: var(--text-secondary);
    font-size: 0.86rem;
    line-height: 1.55;
    background: rgba(239, 68, 68, 0.02);
}

.comparison-matrix-table .cell-master-coach.highlight-cell {
    background: rgba(29, 78, 216, 0.03);
    border-right: 2px solid #1D4ED8;
    border-left: 2px solid #1D4ED8;
    color: var(--text-primary);
    font-size: 0.88rem;
    font-weight: 700;
    line-height: 1.55;
}

.comparison-matrix-table .cell-content {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
}

.status-cross {
    color: #EF4444;
    min-width: 18px;
    margin-top: 2px;
}

.status-check {
    color: #059669;
    min-width: 18px;
    margin-top: 2px;
}

.comparison-cta-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 2.25rem 2.5rem;
    background: linear-gradient(135deg, #0B1B3D 0%, #1E3A8A 100%);
    color: #FFFFFF;
    flex-wrap: wrap;
}

.comparison-cta-text .cta-heading {
    font-size: 1.25rem;
    font-weight: 900;
    margin-bottom: 0.35rem;
}

.comparison-cta-text .cta-sub {
    font-size: 0.88rem;
    color: rgba(255, 255, 255, 0.85);
}

.mobile-comp-header {
    display: none !important;
}

@media (max-width: 768px) {
    .comparison-matrix-wrapper {
        border-radius: var(--radius-lg);
        overflow: visible !important;
        border: none !important;
        background: transparent !important;
        box-shadow: none !important;
    }

    .comparison-matrix-table {
        display: block !important;
        width: 100% !important;
        border: none !important;
        border-collapse: separate !important;
        overflow: visible !important;
    }

    .comparison-matrix-table thead {
        display: none !important;
    }

    .comparison-matrix-table tbody {
        display: flex !important;
        flex-direction: column !important;
        gap: 1.25rem !important;
        width: 100% !important;
    }

    .comparison-matrix-table tr {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        background: var(--bg-card) !important;
        border: 1px solid var(--border-subtle) !important;
        border-radius: 16px !important;
        padding: 1.25rem !important;
        box-shadow: 0 4px 16px rgba(11, 27, 61, 0.05) !important;
        box-sizing: border-box !important;
    }

    .comparison-matrix-table th,
    .comparison-matrix-table td {
        padding: 0 !important;
        border: none !important;
    }

    /* 1. Criterion Name Header */
    .comparison-matrix-table td.cell-criterion {
        display: block !important;
        width: 100% !important;
        background: transparent !important;
        padding-bottom: 0.85rem !important;
        margin-bottom: 0.85rem !important;
        border-bottom: 2px solid var(--border-subtle) !important;
    }

    .comparison-matrix-table td.cell-criterion .criterion-name {
        font-size: 1.15rem !important;
        font-weight: 900 !important;
        color: var(--text-primary) !important;
        line-height: 1.4 !important;
    }

    /* 2. Master Coach Highlight Option - Shown First */
    .comparison-matrix-table td.cell-master-coach.highlight-cell {
        order: 1 !important;
        display: block !important;
        width: 100% !important;
        background: linear-gradient(180deg, rgba(29, 78, 216, 0.06) 0%, rgba(5, 150, 105, 0.04) 100%) !important;
        border: 2px solid #1D4ED8 !important;
        border-radius: 12px !important;
        padding: 1rem 1.15rem !important;
        margin-bottom: 0.85rem !important;
        box-sizing: border-box !important;
    }

    .comparison-matrix-table td.cell-master-coach.highlight-cell .cell-content {
        display: flex !important;
        align-items: flex-start !important;
        gap: 0.75rem !important;
        font-size: 0.92rem !important;
        font-weight: 700 !important;
        line-height: 1.65 !important;
        color: var(--text-primary) !important;
    }

    /* 3. Conventional Courses Option - Shown Second */
    .comparison-matrix-table td.cell-conventional {
        order: 2 !important;
        display: block !important;
        width: 100% !important;
        background: rgba(239, 68, 68, 0.02) !important;
        border: 1px dashed rgba(239, 68, 68, 0.25) !important;
        border-radius: 12px !important;
        padding: 0.9rem 1.15rem !important;
        box-sizing: border-box !important;
    }

    .comparison-matrix-table td.cell-conventional .cell-content {
        display: flex !important;
        align-items: flex-start !important;
        gap: 0.75rem !important;
        font-size: 0.86rem !important;
        line-height: 1.6 !important;
        color: var(--text-secondary) !important;
    }

    .mobile-comp-header {
        display: flex !important;
        flex-direction: column !important;
        gap: 3px !important;
        margin-bottom: 0.65rem !important;
    }

    .mobile-comp-badge {
        display: inline-block !important;
        align-self: flex-start !important;
        background: linear-gradient(135deg, #D97706 0%, #F59E0B 100%) !important;
        color: #FFFFFF !important;
        font-size: 0.68rem !important;
        font-weight: 800 !important;
        padding: 2px 8px !important;
        border-radius: 999px !important;
        margin-bottom: 3px !important;
    }

    .mobile-comp-tag {
        font-size: 0.92rem !important;
        font-weight: 900 !important;
        color: #1D4ED8 !important;
    }

    .conventional-header .mobile-comp-tag {
        color: #DC2626 !important;
    }

    .mobile-comp-sub {
        font-size: 0.74rem !important;
        font-weight: 600 !important;
        color: var(--text-muted) !important;
    }

    .comparison-cta-box {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
        border-radius: 16px !important;
        margin-top: 1.5rem !important;
    }
    .comparison-cta-box .btn-landing-primary {
        justify-content: center;
    }
}

/* Landing Stats Grid */
.landing-stats-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 1.25rem;
    margin: 1.75rem auto 0;
    max-width: 1200px;
    width: 100%;
    justify-content: center;
}

.landing-stat-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1.35rem 1rem;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: all 0.25s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.landing-stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: rgba(5, 150, 105, 0.4);
}

.stat-num {
    font-size: 1.85rem;
    font-weight: 900;
    color: var(--brand-blue-light);
    font-family: var(--font-heading);
    line-height: 1.1;
    margin-bottom: 0.35rem;
    text-align: center;
}

.stat-unit {
    font-size: 0.88rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 0.4rem;
    text-align: center;
}

.stat-desc {
    font-size: 0.74rem;
    color: var(--text-muted);
    line-height: 1.45;
    text-align: center;
}

@media (max-width: 1100px) {
    .landing-stats-grid {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }
    .landing-stat-card {
        flex: 1 1 200px;
        max-width: 260px;
        min-width: 180px;
    }
}
@media (max-width: 576px) {
    .landing-stats-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }
    .landing-stat-card:last-child {
        grid-column: 1 / -1;
        max-width: 100%;
    }
    .landing-hero-title {
        font-size: 1.95rem;
    }
    .landing-title-highlight {
        font-size: 1.4rem;
    }
}

/* Landing Section General */
.landing-section {
    padding: 5rem 0;
    position: relative;
    scroll-margin-top: calc(var(--app-header-height, 74px) + 16px);
}

.landing-section-header {
    text-align: center;
    max-width: 820px;
    margin: 0 auto 3.5rem auto;
}

.landing-section-pill {
    display: inline-block;
    background: rgba(29, 78, 216, 0.08);
    color: var(--brand-blue-light);
    font-size: 0.8rem;
    font-weight: 700;
    padding: 0.3rem 0.9rem;
    border-radius: var(--radius-full);
    border: 1px solid rgba(29, 78, 216, 0.2);
    margin-bottom: 0.75rem;
}

.landing-section-title {
    font-size: 2.15rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0 0 1rem 0;
    letter-spacing: -0.3px;
}

.landing-section-desc {
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--text-secondary);
    margin: 0;
}

/* Interactive Curriculum Explorer Toolbar */
.landing-curriculum-toolbar {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-sm);
}

.landing-curriculum-search-box {
    position: relative;
    margin-bottom: 1rem;
}

.landing-curriculum-search-box input {
    width: 100%;
    padding: 0.75rem 2.6rem 0.75rem 1rem;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    background: var(--bg-input);
    font-size: 0.92rem;
    color: var(--text-primary);
    transition: border 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}

.landing-curriculum-search-box input:focus {
    outline: none;
    border-color: var(--brand-blue-light);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.landing-search-icon {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    pointer-events: none;
}

.landing-domain-tabs {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.landing-tab-pill {
    background: rgba(11, 27, 61, 0.04);
    border: 1px solid var(--border-subtle);
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-weight: 700;
    padding: 0.4rem 0.85rem;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: all 0.2s ease;
}

.landing-tab-pill:hover {
    background: rgba(29, 78, 216, 0.08);
    color: var(--brand-blue-light);
    border-color: var(--border-accent);
}

.landing-tab-pill.active {
    background: var(--brand-blue-light);
    color: #FFFFFF;
    border-color: var(--brand-blue-light);
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25);
}

.landing-tab-pill.critical {
    color: #DC2626;
    border-color: rgba(220, 38, 38, 0.3);
    background: rgba(220, 38, 38, 0.05);
}

.landing-tab-pill.critical.active {
    background: #DC2626;
    color: #FFFFFF;
    border-color: #DC2626;
}

/* Domains Cards Grid (8 Domains) */
.domains-cards-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.domain-showcase-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1.75rem;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    transition: all 0.25s ease;
    position: relative;
}

.domain-showcase-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--border-accent);
}

.domain-showcase-card.featured {
    border: 2px solid rgba(29, 78, 216, 0.4);
    background: linear-gradient(180deg, rgba(29, 78, 216, 0.02) 0%, var(--bg-surface) 100%);
}

.domain-showcase-card.critical-ethics {
    border: 2px solid rgba(220, 38, 38, 0.35);
    background: linear-gradient(180deg, rgba(220, 38, 38, 0.02) 0%, var(--bg-surface) 100%);
}

.domain-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.85rem;
}

.domain-tag {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--brand-blue-light);
    background: rgba(29, 78, 216, 0.08);
    padding: 0.25rem 0.65rem;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(29, 78, 216, 0.2);
}

.domain-count {
    font-size: 0.8rem;
    font-weight: 800;
    color: var(--text-primary);
}

.domain-card-title {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0 0 0.65rem 0;
}

.domain-card-desc {
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.55;
    margin: 0 0 1rem 0;
}

.domain-competencies-list {
    list-style: none;
    padding: 0;
    margin: 0 0 1.25rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    flex-grow: 1;
}

.domain-competencies-list li {
    font-size: 0.83rem;
    color: var(--text-primary);
    position: relative;
    padding-right: 1.2rem;
    line-height: 1.5;
}

.domain-competencies-list li::before {
    content: "•";
    position: absolute;
    right: 0;
    color: var(--brand-blue-light);
    font-weight: 900;
    font-size: 1.1rem;
    line-height: 1;
}

.domain-card-footer {
    border-top: 1px dashed var(--border-subtle);
    padding-top: 0.85rem;
    font-size: 0.77rem;
    color: var(--text-muted);
    line-height: 1.5;
}

@media (max-width: 850px) {
    .domains-cards-grid {
        grid-template-columns: 1fr;
    }
}

/* 14 Domains Grid on Landing Page */
.landing-domains14-grid,
.domains-14-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.15rem;
}

@media (min-width: 1101px) {
    /* Symmetrically center the last 2 items on row 4 */
    .landing-domains14-grid > :nth-child(13):nth-last-child(2),
    .domains-14-grid > :nth-child(13):nth-last-child(2) {
        grid-column-start: 2;
    }
}

@media (max-width: 1100px) {
    .landing-domains14-grid,
    .domains-14-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .landing-domains14-grid,
    .domains-14-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.85rem;
    }
}

@media (max-width: 480px) {
    .landing-domains14-grid,
    .domains-14-grid {
        grid-template-columns: 1fr;
    }
}

#landing-domains14 .domain14-card,
.landing-domains14-grid .domain14-card,
.domains-14-grid .domain14-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg, 12px);
    padding: 1.25rem 1.15rem;
    box-shadow: var(--shadow-sm, 0 1px 3px rgba(0,0,0,0.04));
    display: flex;
    flex-direction: column;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    border-top: 3px solid var(--brand-navy, #0B1B3D);
}

#landing-domains14 .domain14-card:hover,
.landing-domains14-grid .domain14-card:hover,
.domains-14-grid .domain14-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 22px -5px rgba(11,27,61,0.08), 0 4px 6px -2px rgba(11,27,61,0.04);
    border-color: rgba(217, 119, 6, 0.4);
    border-top-color: var(--status-amber, #D97706);
}

.domain14-title {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--brand-navy, #0B1B3D);
    margin: 0 0 0.5rem 0;
    line-height: 1.4;
}

.domain14-desc {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.55;
    margin: 0;
    flex-grow: 1;
}

/* Hours Track Grid (240 Hours) */
.hours-track-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
}

.hour-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1.35rem;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    transition: all 0.2s ease;
}

.hour-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: var(--brand-blue-light);
}

.hour-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.65rem;
}

.hour-badge {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--text-muted);
}

.hour-val {
    font-size: 1.35rem;
    font-weight: 900;
    color: var(--brand-blue-light);
    font-family: var(--font-heading);
}

.hour-title {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0 0 0.5rem 0;
}

.hour-desc {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin: 0 0 0.85rem 0;
    flex-grow: 1;
}

.hour-tag {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--text-primary);
    background: rgba(15, 23, 42, 0.05);
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius-sm);
    text-align: center;
}

.total-hours-callout {
    margin-top: 2rem;
    background: linear-gradient(90deg, rgba(29, 78, 216, 0.08) 0%, rgba(217, 119, 6, 0.08) 100%);
    border: 1px solid var(--border-accent);
    border-radius: var(--radius-lg);
    padding: 1.5rem 2rem;
    text-align: center;
}

.total-hours-title {
    font-size: 1.25rem;
    color: var(--text-primary);
    margin-bottom: 0.35rem;
}

.total-hours-title strong {
    color: var(--brand-blue-light);
    font-size: 1.4rem;
}

.total-hours-note {
    font-size: 0.85rem;
    color: var(--text-muted);
}

@media (max-width: 992px) {
    .hours-track-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 576px) {
    .hours-track-grid {
        grid-template-columns: 1fr;
    }
}

/* Deliverables Grid */
.deliverables-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
}

.deliverable-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1.4rem;
    box-shadow: var(--shadow-sm);
    transition: all 0.2s ease;
}

.deliverable-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: var(--border-accent);
}

.deliverable-card.featured-gold {
    border: 2px solid rgba(217, 119, 6, 0.4);
    background: linear-gradient(180deg, rgba(217, 119, 6, 0.03) 0%, var(--bg-surface) 100%);
}

.deliv-icon-wrap {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.75rem;
}

.deliv-num {
    font-size: 1.35rem;
    font-weight: 900;
    color: var(--text-primary);
    font-family: var(--font-heading);
    margin-bottom: 0.25rem;
}

.deliv-title {
    font-size: 0.95rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0 0 0.5rem 0;
    line-height: 1.35;
}

.deliv-desc {
    font-size: 0.78rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin: 0;
}

@media (max-width: 992px) {
    .deliverables-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 576px) {
    .deliverables-grid {
        grid-template-columns: 1fr;
    }
}

/* Accreditation Showcase Box */
.accreditation-showcase-box {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 2.5rem;
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: 2.5rem;
    box-shadow: var(--shadow-md);
    align-items: center;
}

.accreditation-badge-gold {
    display: inline-flex;
    align-items: center;
    background: rgba(217, 119, 6, 0.1);
    color: var(--text-gold);
    border: 1px solid rgba(217, 119, 6, 0.3);
    padding: 0.35rem 0.85rem;
    border-radius: var(--radius-full);
    font-size: 0.82rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.accreditation-title {
    font-size: 1.75rem;
    font-weight: 900;
    color: var(--text-primary);
    margin: 0 0 0.85rem 0;
}

.accreditation-desc {
    font-size: 0.95rem;
    line-height: 1.7;
    color: var(--text-secondary);
    margin: 0 0 1.25rem 0;
}

.accreditation-features-list {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.acc-feat-item {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Mini Royal Certificate Preview Card */
.accreditation-preview-card {
    display: flex;
    justify-content: center;
}

.royal-mini-cert-frame {
    background: #FFFDF9;
    border: 8px solid #0B1B3D;
    outline: 2px solid #D4AF37;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    position: relative;
    max-width: 380px;
    width: 100%;
    text-align: center;
}

.cert-mini-header {
    margin-bottom: 1rem;
    border-bottom: 1px solid rgba(212, 175, 55, 0.3);
    padding-bottom: 0.75rem;
}

.cert-mini-body {
    margin-bottom: 1.25rem;
}

.cert-mini-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid rgba(212, 175, 55, 0.3);
    padding-top: 0.75rem;
    text-align: right;
}

.cert-mini-seal-gold {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: radial-gradient(circle, #F59E0B 0%, #B45309 100%);
    color: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 0.65rem;
    border: 2px solid #D4AF37;
    box-shadow: 0 2px 8px rgba(180, 83, 9, 0.4);
}

@media (max-width: 900px) {
    .accreditation-showcase-box {
        grid-template-columns: 1fr;
    }
}

/* Instructor & Consulting House Grid */
.instructor-bio-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.75rem;
    align-items: stretch;
}

.instructor-card,
.consulting-house-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg, 16px);
    padding: 2.25rem 2rem;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.25s ease;
    position: relative;
    overflow: hidden;
}

.instructor-card {
    border-top: 3px solid #D4AF37;
}

.consulting-house-card {
    border-top: 3px solid #059669;
}

.instructor-card:hover,
.consulting-house-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.instructor-header-row,
.consulting-header-row {
    display: flex;
    align-items: flex-start;
    gap: 1.25rem;
    margin-bottom: 1.25rem;
}

.instructor-crest-badge {
    width: 60px;
    height: 60px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.16) 0%, rgba(11, 27, 61, 0.08) 100%);
    border: 1.5px solid rgba(212, 175, 55, 0.5);
    color: #D4AF37;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.15);
}

.consulting-logo-box {
    width: 60px;
    height: 60px;
    border-radius: 14px;
    background: #FFFFFF;
    border: 1.5px solid rgba(5, 150, 105, 0.3);
    padding: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.1);
}

.consulting-logo-box img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.instructor-role-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: rgba(212, 175, 55, 0.12);
    color: #B45309;
    border: 1px solid rgba(212, 175, 55, 0.3);
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    font-size: 0.76rem;
    font-weight: 800;
    margin-bottom: 0.45rem;
}

.consulting-role-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: rgba(5, 150, 105, 0.1);
    color: #059669;
    border: 1px solid rgba(5, 150, 105, 0.25);
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    font-size: 0.76rem;
    font-weight: 800;
    margin-bottom: 0.45rem;
}

.instructor-name {
    font-size: 1.35rem;
    font-weight: 900;
    color: var(--text-primary);
    margin: 0 0 0.25rem 0;
    line-height: 1.25;
}

.instructor-title-sub {
    font-size: 0.82rem;
    color: var(--text-secondary);
    font-weight: 600;
}

.instructor-divider {
    height: 1px;
    background: var(--border-subtle);
    margin: 1.1rem 0;
}

.instructor-p {
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin: 0 0 1.25rem 0;
}

.instructor-credentials-list {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.cred-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.84rem;
    font-weight: 700;
    color: var(--text-primary);
}

.cred-item svg {
    flex-shrink: 0;
    color: #059669;
}

@media (max-width: 900px) {
    .instructor-bio-grid {
        grid-template-columns: 1fr;
    }
}

/* FAQ Accordion */
.faq-accordion-list {
    max-width: 860px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.faq-accordion-item {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: all 0.2s ease;
}

.faq-accordion-item[open] {
    border-color: var(--border-accent);
    box-shadow: var(--shadow-sm);
}

.faq-question {
    padding: 1.15rem 1.4rem;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
    list-style: none;
}

.faq-question::-webkit-details-marker {
    display: none;
}

.faq-chevron {
    transition: transform 0.25s ease;
    flex-shrink: 0;
    color: var(--brand-blue-light);
}

.faq-accordion-item[open] .faq-chevron {
    transform: rotate(180deg);
}

.faq-answer {
    padding: 0 1.4rem 1.25rem 1.4rem;
    font-size: 0.9rem;
    line-height: 1.7;
    color: var(--text-secondary);
    border-top: 1px dashed var(--border-subtle);
    padding-top: 0.85rem;
}

/* Final CTA Section */
.landing-final-cta-section {
    padding: 4.5rem 0;
    background: radial-gradient(circle at 50% 50%, rgba(29, 78, 216, 0.08) 0%, transparent 70%);
}

.landing-final-cta-card {
    background: linear-gradient(135deg, #0B1B3D 0%, #162B55 100%);
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-radius: var(--radius-xl);
    padding: 3.5rem 2.5rem;
    text-align: center;
    color: #FFFFFF;
    box-shadow: 0 15px 35px rgba(11, 27, 61, 0.35);
    max-width: 980px;
    margin: 0 auto;
}

.landing-cta-pill {
    display: inline-block;
    background: rgba(217, 119, 6, 0.25);
    color: #FBBF24;
    font-size: 0.82rem;
    font-weight: 800;
    padding: 0.35rem 1rem;
    border-radius: var(--radius-full);
    border: 1px solid rgba(217, 119, 6, 0.4);
    margin-bottom: 1.25rem;
}

.landing-final-cta-title {
    font-size: 2.25rem;
    font-weight: 900;
    color: #FFFFFF;
    margin: 0 0 1rem 0;
}

.landing-final-cta-desc {
    font-size: 1.05rem;
    color: #CBD5E1;
    line-height: 1.7;
    max-width: 700px;
    margin: 0 auto 2rem auto;
}

.landing-final-cta-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Sticky Bottom Action Bar */
.landing-sticky-cta {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(11, 27, 61, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid rgba(212, 175, 55, 0.4);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.2);
    padding: 0.75rem 1.5rem;
    z-index: 1000;
    transition: transform 0.3s ease;
}

.landing-sticky-inner,
.sticky-cta-content {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.sticky-text-wrap,
.sticky-cta-text {
    color: #FFFFFF !important;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.sticky-text-wrap strong,
.sticky-cta-text strong {
    color: #FBBF24 !important;
}

.sticky-text-wrap span,
.sticky-cta-text span {
    color: #E2E8F0 !important;
}

.sticky-actions-wrap,
.sticky-cta-actions {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

@media (max-width: 600px) {
    .sticky-text-wrap,
    .sticky-cta-text {
        display: none !important;
    }
    .landing-sticky-inner,
    .sticky-cta-content {
        justify-content: center !important;
        width: 100% !important;
    }
    .landing-sticky-cta {
        padding: 0.55rem 1rem !important;
    }
    .sticky-cta-actions {
        width: 100% !important;
    }
    .sticky-cta-actions .btn-emerald {
        width: 100% !important;
        justify-content: center !important;
    }
}

/* ==========================================================================
   Master Coach Landing Page CMS & Dynamic Customization Studio Styling
   ========================================================================== */

.landing-cms-container {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: 1.75rem;
    box-shadow: var(--shadow-sm);
    margin-bottom: 2.5rem;
}

.cms-header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1.25rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-subtle);
    margin-bottom: 1.75rem;
}

.cms-title-wrap {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.cms-title-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(217, 119, 6, 0.12);
    color: #D97706;
    border: 1px solid rgba(217, 119, 6, 0.3);
    padding: 3px 10px;
    border-radius: var(--radius-full);
    font-size: 0.78rem;
    font-weight: 700;
    width: fit-content;
}

.cms-title {
    font-size: 1.45rem;
    font-weight: 900;
    color: var(--text-primary);
    margin: 0;
}

.cms-desc {
    font-size: 0.88rem;
    color: var(--text-secondary);
    margin: 0;
}

.cms-actions-bar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.cms-section-card {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    margin-bottom: 1rem;
    overflow: hidden;
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.cms-section-card:hover {
    border-color: rgba(29, 78, 216, 0.35);
}

.cms-section-card.section-hidden {
    opacity: 0.65;
    background: rgba(148, 163, 184, 0.04);
    border-style: dashed;
}

.cms-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    background: rgba(11, 27, 61, 0.02);
    border-bottom: 1px solid var(--border-subtle);
    cursor: pointer;
    user-select: none;
    gap: 1rem;
    flex-wrap: wrap;
}

.cms-section-title-side {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

.cms-order-controls {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.cms-btn-order {
    background: transparent;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xs);
    color: var(--text-secondary);
    padding: 1px 4px;
    font-size: 0.68rem;
    cursor: pointer;
    line-height: 1;
}

.cms-btn-order:hover {
    background: var(--bg-hover);
    color: var(--brand-blue);
}

.cms-section-icon-badge {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-md);
    background: rgba(29, 78, 216, 0.08);
    color: var(--brand-blue);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.cms-section-meta h4 {
    margin: 0 0 2px 0;
    font-size: 1rem;
    font-weight: 800;
    color: var(--text-primary);
}

.cms-section-meta span {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

.cms-section-controls-side {
    display: flex;
    align-items: center;
    gap: 1rem;
}

/* Custom switch toggle */
.cms-toggle-wrap {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    font-weight: 700;
}

.cms-switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
}

.cms-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.cms-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #CBD5E1;
    transition: 0.25s;
    border-radius: 24px;
}

.cms-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.25s;
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0,0,0,0.25);
}

.cms-switch input:checked + .cms-slider {
    background-color: #059669;
}

.cms-switch input:focus + .cms-slider {
    box-shadow: 0 0 1px #059669;
}

.cms-switch input:checked + .cms-slider:before {
    transform: translateX(20px);
}

.cms-section-body {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.cms-form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1rem;
}

.cms-form-group {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.cms-form-group label {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text-primary);
}

.cms-form-group input,
.cms-form-group textarea,
.cms-form-group select {
    padding: 0.6rem 0.85rem;
    font-size: 0.88rem;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    background: var(--bg-surface);
    color: var(--text-primary);
    transition: border-color 0.2s;
    font-family: inherit;
}

.cms-form-group input:focus,
.cms-form-group textarea:focus,
.cms-form-group select:focus {
    outline: none;
    border-color: var(--brand-blue);
    box-shadow: 0 0 0 3px rgba(29, 78, 216, 0.12);
}

.cms-button-editor-box {
    background: rgba(11, 27, 61, 0.03);
    border: 1px dashed var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.cms-button-editor-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--text-primary);
}

.cms-items-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.84rem;
    margin-top: 0.5rem;
}

.cms-items-table th,
.cms-items-table td {
    padding: 0.65rem 0.75rem;
    text-align: right;
    border-bottom: 1px solid var(--border-subtle);
}

.cms-items-table th {
    background: rgba(11, 27, 61, 0.04);
    font-weight: 800;
    color: var(--text-secondary);
}

.cms-btn-item-action {
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 3px 6px;
    border-radius: var(--radius-xs);
    transition: all 0.15s;
}

.cms-btn-item-action:hover {
    color: #DC2626;
    background: rgba(220, 38, 38, 0.08);
}

/* Action Notice Modal */
.landing-notice-modal {
    max-width: 540px;
    text-align: center;
    padding: 1.5rem;
    border-top: 5px solid #D97706;
}

.landing-notice-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1rem auto;
    border-radius: 50%;
    background: rgba(217, 119, 6, 0.12);
    color: #D97706;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
}

/* Button Disabled Styling on landing page */
.btn-landing-primary.btn-disabled,
.btn-landing-secondary.btn-disabled,
.btn-landing-ghost.btn-disabled,
.btn-landing-preview.btn-disabled,
.btn-emerald.btn-disabled {
    opacity: 0.65 !important;
    cursor: not-allowed !important;
    filter: grayscale(0.2);
}

/* ==========================================================================
   Landing Analytics & Conversion Funnel Styles
   ========================================================================== */

.landing-analytics-strip {
    background: linear-gradient(135deg, rgba(11, 27, 61, 0.03) 0%, rgba(5, 150, 105, 0.04) 100%);
    border: 1px solid rgba(5, 150, 105, 0.25);
    border-radius: var(--radius-xl);
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.03);
}

.landing-analytics-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.landing-analytics-title-wrap {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.landing-analytics-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0;
}

.landing-analytics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.landing-analytics-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.landing-analytics-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.landing-analytics-val {
    font-size: 1.45rem;
    font-weight: 900;
    color: var(--text-primary);
    line-height: 1.1;
}

.landing-analytics-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 600;
    margin-top: 0.2rem;
}

.landing-analytics-panels {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.25rem;
}

.landing-analytics-subcard {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
}

.landing-analytics-subcard-title {
    font-size: 0.95rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0 0 1rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.analytics-list-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.6rem 0;
    border-bottom: 1px dashed var(--border-subtle);
    font-size: 0.85rem;
}

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

.analytics-bar-bg {
    width: 100%;
    height: 6px;
    background: var(--bg-hover);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 4px;
}

.analytics-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #059669, #10B981);
    border-radius: 3px;
    transition: width 0.6s ease;
}

/* ==========================================================================
   STREAMLINED EDITION: ADMIN SESSION BADGE & DASHBOARD CONTAINER
   ========================================================================== */

.admin-session-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.35rem 0.85rem;
    border-radius: 9999px;
    background: var(--bg-surface-elevated, #FFFFFF);
    border: 1px solid var(--border-subtle, #E2E8F0);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    font-size: 0.85rem;
}

.admin-badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #059669;
    box-shadow: 0 0 0 2px rgba(5, 150, 105, 0.25);
    display: inline-block;
    flex-shrink: 0;
}

.admin-name {
    font-weight: 700;
    color: var(--text-primary);
    white-space: nowrap;
}

.btn-landing-nav-action {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.45rem 1.1rem;
    border-radius: 9999px;
    background: linear-gradient(135deg, #0B1B3D 0%, #1E3A8A 100%);
    color: #FFFFFF !important;
    font-size: 0.85rem;
    font-weight: 700;
    text-decoration: none;
    border: 1px solid rgba(255, 255, 255, 0.15);
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 6px rgba(11, 27, 61, 0.15);
}

.btn-landing-nav-action:hover {
    background: linear-gradient(135deg, #1E3A8A 0%, #2563EB 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(11, 27, 61, 0.25);
}

.btn-xs {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.65rem;
    border-radius: var(--radius-sm, 6px);
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s ease;
}

.admin-dashboard-container {
    width: 100%;
    max-width: 1440px;
    margin: 0 auto;
    padding: 1.5rem 1.25rem 3.5rem 1.25rem;
    min-height: calc(100vh - 160px);
}

.auth-modal-card {
    max-width: 440px;
    border-radius: var(--radius-lg, 16px);
}

.auth-form .form-group {
    margin-bottom: 1.2rem;
}

.auth-form .form-label {
    display: block;
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.45rem;
}

.auth-form .form-input {
    width: 100%;
    padding: 0.7rem 1rem;
    border: 1px solid var(--border-subtle, #CBD5E1);
    border-radius: var(--radius-sm, 6px);
    font-size: 0.95rem;
    font-family: inherit;
    background: var(--bg-surface);
    color: var(--text-primary);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.auth-form .form-input:focus {
    outline: none;
    border-color: #059669;
    box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.15);
}

/* ==========================================================================
   DEDICATED /admin LOGIN SCREEN STYLING
   ========================================================================== */

.admin-login-view {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 160px);
    padding: 3rem 1.25rem;
    background: radial-gradient(circle at 50% 30%, rgba(11, 27, 61, 0.04) 0%, transparent 70%);
}

.admin-login-card {
    width: 100%;
    max-width: 460px;
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle, #CBD5E1);
    border-radius: var(--radius-lg, 18px);
    box-shadow: 0 20px 45px -15px rgba(11, 27, 61, 0.14), 0 0 0 1px rgba(0, 0, 0, 0.03);
    padding: 2.5rem 2.25rem;
    animation: fadeIn 0.35s ease;
}

.admin-login-header {
    text-align: center;
    margin-bottom: 2rem;
}

.admin-login-logo {
    height: 56px;
    width: auto;
    margin-bottom: 1rem;
    object-fit: contain;
}

.admin-login-title {
    font-size: 1.45rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0 0 0.5rem 0;
}

.admin-login-subtitle {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.5;
}

.admin-back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    transition: color 0.2s ease;
}

.admin-back-link:hover {
    color: var(--text-primary) !important;
}

/* ==========================================================================
   VISUAL LIVE IN-CONTEXT LANDING PAGE EDITOR (CMS)
   ========================================================================== */

.cms-visual-editor-root {
    min-height: 100vh;
    background: var(--bg-body);
}

/* Top Floating Admin Toolbar */
.cms-admin-bar {
    position: sticky;
    top: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: #0B1B3D;
    color: #FFFFFF;
    padding: 0.65rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 4px 20px rgba(11, 27, 61, 0.4);
    border-bottom: 2px solid #D97706;
    gap: 1rem;
    flex-wrap: wrap;
    font-family: var(--font-primary, 'Cairo', sans-serif);
}

.cms-bar-left, .cms-bar-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.cms-status-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-left: 0.5rem;
}

.cms-live-pulse-dot {
    width: 9px;
    height: 9px;
    background: #10B981;
    border-radius: 50%;
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    animation: cmsPulse 1.8s infinite;
}

@keyframes cmsPulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 7px rgba(16, 185, 129, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.cms-bar-title {
    font-size: 0.92rem;
    font-weight: 800;
    color: #F8FAFC;
    letter-spacing: -0.01em;
}

.cms-version-pill {
    background: rgba(217, 119, 6, 0.25);
    color: #FBBF24;
    font-size: 0.72rem;
    font-weight: 800;
    padding: 2px 7px;
    border-radius: 999px;
    border: 1px solid rgba(217, 119, 6, 0.4);
}

.cms-mode-switcher {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 2px;
    gap: 2px;
}

.cms-mode-btn {
    background: transparent;
    border: none;
    color: #CBD5E1;
    font-size: 0.82rem;
    font-weight: 700;
    padding: 5px 12px;
    border-radius: 6px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: all 0.2s ease;
    font-family: inherit;
}

.cms-mode-btn:hover {
    color: #FFFFFF;
    background: rgba(255, 255, 255, 0.1);
}

.cms-mode-btn.active {
    background: #059669;
    color: #FFFFFF;
    box-shadow: 0 2px 8px rgba(5, 150, 105, 0.35);
}

.cms-device-switcher {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 2px;
    gap: 2px;
}

.cms-device-btn {
    background: transparent;
    border: none;
    color: #94A3B8;
    padding: 5px 8px;
    border-radius: 6px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    transition: all 0.2s ease;
}

.cms-device-btn:hover {
    color: #FFFFFF;
    background: rgba(255, 255, 255, 0.1);
}

.cms-device-btn.active {
    color: #F59E0B;
    background: rgba(245, 158, 11, 0.18);
}

.cms-unsaved-badge {
    background: #DC2626;
    color: #FFFFFF;
    font-size: 0.75rem;
    font-weight: 800;
    padding: 4px 10px;
    border-radius: 999px;
    animation: fadeIn 0.3s ease;
}

.cms-btn-save {
    background: #059669;
    color: #FFFFFF;
    border: none;
    font-weight: 800;
    font-size: 0.85rem;
    padding: 6px 14px;
    border-radius: 7px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: all 0.2s ease;
    font-family: inherit;
    box-shadow: 0 2px 6px rgba(5, 150, 105, 0.3);
}

.cms-btn-save.has-changes {
    background: #10B981;
    animation: saveGlow 2s infinite alternate;
}

@keyframes saveGlow {
    from { box-shadow: 0 0 4px #10B981; }
    to { box-shadow: 0 0 14px #10B981; }
}

.cms-btn-save:hover {
    background: #047857;
    transform: translateY(-1px);
}

.cms-btn-revert, .cms-btn-link, .cms-btn-logout {
    background: rgba(255, 255, 255, 0.1);
    color: #E2E8F0;
    border: 1px solid rgba(255, 255, 255, 0.15);
    font-weight: 700;
    font-size: 0.82rem;
    padding: 6px 11px;
    border-radius: 7px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    text-decoration: none;
    transition: all 0.2s ease;
    font-family: inherit;
}

.cms-btn-revert:hover, .cms-btn-link:hover {
    background: rgba(255, 255, 255, 0.2);
    color: #FFFFFF;
}

.cms-btn-logout:hover {
    background: rgba(239, 68, 68, 0.25);
    color: #F87171;
    border-color: #EF4444;
}

/* Viewport device studios */
.cms-viewport-desktop {
    width: 100%;
}

.cms-viewport-tablet {
    max-width: 768px;
    margin: 2rem auto;
    border-radius: 18px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
    border: 10px solid #1E293B;
    overflow-x: hidden;
    background: var(--bg-body);
}

.cms-viewport-mobile {
    max-width: 390px;
    margin: 2rem auto;
    border-radius: 28px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
    border: 12px solid #1E293B;
    overflow-x: hidden;
    background: var(--bg-body);
}

/* Section Floating Toolbar in Visual Editor Mode */
.cms-mode-editing .cms-editor-section {
    position: relative;
    transition: box-shadow 0.2s ease;
}

.cms-section-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(11, 27, 61, 0.95);
    backdrop-filter: blur(8px);
    color: #FFFFFF;
    padding: 0.35rem 0.85rem;
    border-radius: 8px;
    margin: 0.5rem auto;
    max-width: 1200px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(217, 119, 6, 0.4);
    font-family: var(--font-primary, 'Cairo', sans-serif);
    z-index: 10;
}

.cms-sec-tag {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.82rem;
    font-weight: 700;
}

.cms-sec-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
}

.cms-sec-dot.active { background: #10B981; }
.cms-sec-dot.hidden { background: #EF4444; }

.cms-sec-actions {
    display: flex;
    align-items: center;
    gap: 5px;
}

.cms-btn-pill {
    background: rgba(255, 255, 255, 0.12);
    border: none;
    color: #F8FAFC;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 5px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: background 0.15s ease;
}

.cms-btn-pill:hover {
    background: rgba(255, 255, 255, 0.25);
}

.cms-btn-add {
    background: #059669;
    color: #FFFFFF;
}

.cms-btn-add:hover {
    background: #047857;
}

.cms-btn-visible { color: #A7F3D0; }
.cms-btn-hidden { color: #FCA5A5; background: rgba(239, 68, 68, 0.2); }

/* Inline Text Editing Highlights (Active only in editor mode) */
.cms-mode-editing .cms-editable-text {
    cursor: text;
    transition: outline 0.15s ease, background 0.15s ease;
    border-radius: 4px;
}

.cms-mode-editing .cms-editable-text:hover {
    outline: 2px dashed #D97706 !important;
    outline-offset: 3px;
    background: rgba(217, 119, 6, 0.08);
}

.cms-mode-editing .cms-editable-text:focus,
.cms-mode-editing .cms-editable-text.cms-editing-active {
    outline: 2px solid #059669 !important;
    outline-offset: 3px;
    background: rgba(5, 150, 105, 0.1);
    box-shadow: 0 0 12px rgba(5, 150, 105, 0.25);
}

/* Button Customization Trigger Cues (Active only in editor mode) */
.cms-mode-editing .cms-editable-btn {
    position: relative;
    cursor: pointer !important;
    transition: transform 0.15s ease, outline 0.15s ease;
}

.cms-mode-editing .cms-editable-btn:hover {
    outline: 2px dashed #3B82F6 !important;
    outline-offset: 4px;
    box-shadow: 0 0 14px rgba(59, 130, 246, 0.35);
}

/* Micro-actions on items (FAQ delete, stat delete, etc.) */
.cms-item-mini-actions {
    position: absolute;
    top: 6px;
    left: 6px;
    z-index: 5;
    display: none;
}

.domain-showcase-card:hover .cms-item-mini-actions,
.domain14-card:hover .cms-item-mini-actions,
.deliverable-card:hover .cms-item-mini-actions,
.hour-card:hover .cms-item-mini-actions,
.landing-stat-card:hover .cms-item-mini-actions {
    display: block;
}

.cms-item-mini-actions button, .cms-btn-xs-delete {
    background: rgba(239, 68, 68, 0.85);
    color: #FFFFFF;
    border: none;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 13px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    transition: background 0.15s ease;
}

.cms-item-mini-actions button:hover, .cms-btn-xs-delete:hover {
    background: #DC2626;
    transform: scale(1.1);
}

/* ==========================================================================
   PERSISTENT SECTION TOGGLES STRIP & HIDDEN SECTION STATES
   ========================================================================== */
.cms-section-toggles-strip {
    background: var(--bg-card, #ffffff);
    border: 1px solid var(--border-subtle, #e2e8f0);
    border-radius: 12px;
    padding: 0.85rem 1.25rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.25rem;
    flex-wrap: wrap;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
    position: sticky;
    top: 10px;
    z-index: 35;
    backdrop-filter: blur(8px);
}

.cms-toggle-wrap {
    user-select: none;
    -webkit-user-select: none;
    transition: all 0.15s ease;
}

.cms-toggle-wrap:hover {
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
    transform: translateY(-1px);
}

.cms-toggle-wrap.is-disabled {
    opacity: 0.7;
    background: var(--bg-muted, #f1f5f9) !important;
    border-color: #E2E8F0 !important;
}

.cms-toggle-wrap.is-disabled .sec-label-text {
    color: var(--text-muted, #94a3b8) !important;
}

.btn-xs-action:hover {
    background: #E2E8F0 !important;
    color: var(--text-primary) !important;
}

/* Hidden Section State in Editor Mode */
.cms-mode-editing .cms-section-hidden-state {
    opacity: 0.55;
    filter: grayscale(70%);
    border: 2px dashed #EF4444 !important;
    border-radius: 12px;
    margin: 12px 0;
    position: relative;
    transition: opacity 0.2s ease, filter 0.2s ease, border-color 0.2s ease;
}

.cms-mode-editing .cms-section-hidden-state::before {
    content: '⚠️ هذا القسم مخفي حالياً عن زوار صفحة الهبوط';
    display: table;
    margin: 10px auto;
    background: #FEF2F2;
    color: #DC2626;
    border: 1px solid #FCA5A5;
    font-size: 0.8rem;
    font-weight: 800;
    padding: 4px 14px;
    border-radius: 20px;
    box-shadow: 0 2px 6px rgba(220, 38, 38, 0.12);
}

/* ==========================================================================
   TRAINEE PORTAL STYLING (Modular Import)
   ========================================================================== */
@import url('trainee-portal.css');
