/**
 * Fitness Coach Pro Theme CSS Design System
 * Inspired by Duolingo playfulness + High-Tech Scientific Glassmorphism
 */

/* ─────────────────────────────────────────────
     Theme Token Variables
     ───────────────────────────────────────────── */
:root {
    /* Fonts */
    --font-en: 'Outfit', sans-serif;
    --font-ar: 'Tajawal', sans-serif;

    /* Premium Minimal Business Light Theme */
    --bg-color: #f8fafc;
    --card-bg: #ffffff;
    --card-border: #cbd5e1;
    --border-stroke: #e2e8f0;
    --text-primary: #0f172a;
    --text-secondary: #334155;
    --text-muted: #64748b;
    
    /* Elegant Business Accents */
    --accent-green: #0f766e; /* Teal-700 */
    --accent-green-shadow: #0d9488;
    --accent-green-glow: rgba(13, 148, 136, 0.08);
    --accent-blue: #1d4ed8; /* Blue-700 */
    --accent-blue-shadow: #2563eb;
    --accent-blue-glow: rgba(37, 99, 235, 0.08);
    --accent-orange: #be123c; /* Rose-700 (Very premium brand feel) */
    --accent-orange-shadow: #e11d48;
    --accent-yellow: #b45309; /* Amber-700 */
    --accent-yellow-shadow: #d97706;
    --accent-red: #be123c;
    --accent-red-shadow: #e11d48;
    --accent-purple: #6d28d9;
    --accent-purple-glow: rgba(109, 40, 217, 0.08);

    /* Premium Clean Shadow */
    --box-shadow: 0 1px 3px rgba(15,23,42,0.06), 0 12px 32px -4px rgba(15,23,42,0.08);
    --glass-blur: none; /* Crisp layout in Business Mode */
    --card-glow: none;

    /* Spacing & Business Radii */
    --section-gap: 80px;
    --card-radius: 12px; /* Sleek business radius */
    --btn-radius: 8px; /* Professional button radius */

    /* Default */
    --font-family: var(--font-en);

    /* Distinct Muscle Radar Variables for Light Mode */
    --radar-bg: #4f46e5; /* Indigo-600 */
    --radar-glow: rgba(79, 70, 229, 0.35);
    --radar-icon-color: #ffffff;
}

/* Dark Theme overrides (Cyberpunk Glassmorphism) */
body.dark-theme,
html.dark-theme {
    --bg-color: #030712;
    --card-bg: rgba(15, 23, 42, 0.7);
    --card-border: rgba(255, 255, 255, 0.06);
    --border-stroke: rgba(255, 255, 255, 0.06);
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;

    --accent-green: #4ade80;
    --accent-green-shadow: #22c55e;
    --accent-green-glow: rgba(74, 222, 128, 0.3);
    --accent-blue: #60a5fa;
    --accent-blue-shadow: #3b82f6;
    --accent-blue-glow: rgba(96, 165, 250, 0.3);
    --accent-orange: #f97316;
    --accent-orange-shadow: #ea580c;
    --accent-yellow: #eab308;
    --accent-yellow-shadow: #ca8a04;
    --accent-red: #ef4444;
    --accent-red-shadow: #dc2626;

    --box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255,255,255,0.03);
    --glass-blur: blur(20px) saturate(200%);
    --card-glow: 0 0 0 1px rgba(255,255,255,0.1);
    --card-radius: 24px;
    --btn-radius: 14px;

    /* Distinct Muscle Radar Variables for Dark Mode */
    --radar-bg: #f97316; /* Cyberpunk Orange */
    --radar-glow: rgba(249, 115, 22, 0.45);
    --radar-icon-color: #ffffff;
}

/* RTL Layout Font Override */
body.rtl-layout {
    --font-family: var(--font-ar);
    direction: rtl;
}

/* ─────────────────────────────────────────────
     Base & Canvas Layout
     ───────────────────────────────────────────── */
body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-family);
    transition: background-color 0.4s ease, color 0.4s ease;
    min-height: 100vh;
}

/* WebGL canvas background */
.nerve-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

/* ─────────────────────────────────────────────
     Reusable UI Components: Glass & Buttons
     ───────────────────────────────────────────── */
.glass-card {
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--card-border);
    border-radius: var(--card-radius);
    box-shadow: var(--box-shadow);
    padding: 28px;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), 
                border-color 0.3s ease,
                box-shadow 0.4s ease;
    position: relative;
    overflow: hidden;
}

.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    z-index: 1;
}

.glass-card:hover {
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: var(--box-shadow), 0 0 30px rgba(34, 197, 94, 0.05);
    transform: translateY(-2px);
}

/* ─────────────────────────────────────────────
     Hero & Media Elements
     ───────────────────────────────────────────── */
.hero-section {
    position: relative !important;
    width: 100% !important;
    height: 100vh !important;
    min-height: 600px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important; /* Left aligned content */
    overflow: hidden !important;
    z-index: 5 !important; /* Sit on top of nerve-canvas to block it */
}

body.rtl-layout .hero-section {
    justify-content: flex-start !important; /* Start is right side in RTL flow */
}

.hero-bg-video {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
}

iframe.hero-embed-iframe {
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    width: 115vw !important;
    height: 115vh !important;
    min-width: 115% !important;
    min-height: 115% !important;
    transform: translate(-50%, -50%) scale(1.1) !important;
    object-fit: cover !important;
    border: 0 !important;
    pointer-events: none !important;
}

.image-cover-bg {
    background-size: cover;
    background-position: center;
    width: 100%;
    height: 100%;
}

.video-overlay, 
.image-overlay {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 2 !important;
    background: rgba(15, 23, 42, 0.25) !important; /* Subtle dark overlay for contrast without washing out */
    display: block !important;
    opacity: 1 !important;
}

body:not(.dark-theme) .video-overlay,
body:not(.dark-theme) .image-overlay {
    background: rgba(255, 255, 255, 0.15) !important; /* Light mode subtle overlay */
}

.video-container, 
.image-cover-bg, 
.fallback-gradient-bg {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 1 !important;
    overflow: hidden !important;
}

/* Desktop Glassmorphic Content Card Layout */
@media (min-width: 992px) {
    .hero-content-wrapper {
        position: relative !important;
        width: 100% !important;
        max-width: 1200px !important;
        margin: 0 auto !important;
        padding: 0 80px !important;
        display: flex !important;
        justify-content: flex-start !important;
        z-index: 3 !important;
        background: transparent !important;
    }
    
    body.rtl-layout .hero-content-wrapper {
        justify-content: flex-start !important; /* Start is right side in RTL flow */
    }
}

/* Mobile Stacking Layout */
@media (max-width: 991px) {
    .hero-section {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        height: 100vh !important;
        min-height: 560px !important;
        background: transparent !important;
    }
    
    .hero-content-wrapper {
        position: relative !important;
        width: 100% !important;
        padding: 0 24px !important;
        z-index: 3 !important;
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        background: transparent !important;
    }
    
    iframe.hero-embed-iframe {
        position: absolute !important;
        top: 50% !important;
        left: 50% !important;
        width: 177.77vh !important; /* Maintain 16:9 aspect scale on mobile height */
        height: 100% !important;
        min-width: 100% !important;
        min-height: 100% !important;
        transform: translate(-50%, -50%) scale(1.1) !important;
    }
}

.hero-card {
    background: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    max-width: 580px !important;
    width: 100% !important;
    text-align: left;
    transition: all 0.3s ease;
}

body.rtl-layout .hero-card {
    text-align: right;
}

body.dark-theme .hero-card {
    background: none !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    padding: 0 !important;
}

.hero-card:hover {
    transform: translateY(-2px);
}

body.dark-theme .hero-card:hover {
    transform: translateY(-2px);
}

.hero-title {
    font-size: 3.25rem;
    font-weight: 800 !important;
    line-height: 1.15;
    margin-bottom: 18px;
    letter-spacing: -0.03em !important;
    color: #0f172a !important; /* Premium Business Slate */
    text-shadow: none !important; /* Remove fuzzy outlines */
}

body.dark-theme .hero-title {
    color: #ffffff !important;
    text-shadow: none !important;
}

body.rtl-layout .hero-title {
    letter-spacing: 0;
}

.hero-description {
    font-size: 1.15rem;
    line-height: 1.75;
    margin-bottom: 28px;
    color: #475569 !important; /* Premium Slate Gray */
    max-width: 540px;
    margin-left: 0;
    margin-right: 0;
    text-shadow: none !important;
}

body.dark-theme .hero-description {
    color: #94a3b8 !important;
    text-shadow: none !important;
}

body.rtl-layout .hero-description {
    margin-left: 0;
    margin-right: 0;
}

.hero-cta-btn {
    font-size: 1.05rem;
    padding: 16px 36px;
    border-radius: var(--btn-radius);
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.hero-cta-btn:hover {
    transform: translateY(-2px) scale(1.03);
    box-shadow: 0 6px 0 var(--accent-green-shadow), 0 20px 50px var(--accent-green-glow);
}

/* ─────────────────────────────────────────────
     Dashboard General Layout
     ───────────────────────────────────────────── */
.dashboard-wrapper {
    padding: 100px 0;
    position: relative;
    z-index: 2;
}

.section-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.welcome-header {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 40px;
}

.welcome-avatar {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    border: 3px solid var(--accent-green);
    object-fit: cover;
}

.welcome-title {
    font-size: 1.8rem;
    font-weight: 900;
    margin-bottom: 6px;
}

.welcome-quote {
    color: var(--text-secondary);
    font-style: italic;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 30px;
}

.dashboard-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.card-icon {
    font-size: 1.4rem;
}

.icon-yellow { color: var(--accent-yellow); }
.icon-blue { color: var(--accent-blue); }
.icon-green { color: var(--accent-green); }
.icon-orange { color: var(--accent-orange); }

.card-title {
    font-size: 1.2rem;
    font-weight: 800;
}

.card-divider {
    border: 0;
    height: 1px;
    background: var(--border-stroke);
    margin: 20px 0;
}

/* ─────────────────────────────────────────────
     Card 1: Gamification UI
     ───────────────────────────────────────────── */
.level-badge-display {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.level-indicator {
    font-size: 1.1rem;
    font-weight: 600;
}

.level-indicator strong {
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--accent-green);
}

.rank-badge {
    padding: 6px 12px;
    border-radius: 12px;
    color: #ffffff;
    font-weight: 800;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* Progress bar styled like Duolingo */
.duo-progress-container {
    width: 100%;
    height: 20px;
    background: rgba(0,0,0,0.08);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 8px;
    position: relative;
}

body.dark-theme .duo-progress-container {
    background: rgba(255,255,255,0.08);
}

.duo-progress-bar {
    height: 100%;
    background-color: var(--accent-green);
    border-radius: 10px;
    transition: width 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
}

.progress-glow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 50%;
    background: rgba(255, 255, 255, 0.2);
}

.xp-numerical-summary {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    font-weight: 600;
}

.streak-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.streak-item {
    background: rgba(0,0,0,0.03);
    border: 1px solid var(--border-stroke);
    border-radius: 16px;
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: transform 0.2s ease;
}

body.dark-theme .streak-item {
    background: rgba(255,255,255,0.03);
}

.streak-item:hover {
    transform: scale(1.02);
}

.streak-icon {
    font-size: 1.8rem;
}

.streak-details h4 {
    font-size: 1.4rem;
    font-weight: 900;
}

.streak-details p {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* ─────────────────────────────────────────────
     Card 2: Subscription & ID
     ───────────────────────────────────────────── */
.member-id-banner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0,0,0,0.04);
    padding: 12px 18px;
    border-radius: 16px;
    border-left: 4px solid var(--accent-blue);
    margin-bottom: 16px;
    font-weight: 700;
}

body.dark-theme .member-id-banner {
    background: rgba(255,255,255,0.04);
}

.member-id-banner .code {
    font-family: monospace;
    font-size: 1.1rem;
    color: var(--accent-blue);
    letter-spacing: 1px;
}

.subscription-tier-wrapper {
    display: flex;
    justify-content: center;
    margin-bottom: 16px;
}

.tier-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 20px;
    border-radius: 20px;
    font-weight: 900;
    font-size: 1.1rem;
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.free-tier {
    background: linear-gradient(135deg, #94a3b8 0%, #475569 100%);
}

.premium-tier {
    background: linear-gradient(135deg, var(--accent-yellow) 0%, var(--accent-orange) 100%);
    animation: goldGlow 3s infinite alternate;
}

@keyframes goldGlow {
    0% { box-shadow: 0 0 5px rgba(255,200,0,0.4); }
    100% { box-shadow: 0 0 20px rgba(255,150,0,0.8); }
}

.expiry-alert {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    justify-content: center;
}

.activity-metric-flex {
    display: flex;
    justify-content: space-around;
}

.metric-block {
    text-align: center;
}

.metric-block .value {
    display: block;
    font-size: 1.8rem;
    font-weight: 900;
    color: var(--accent-blue);
}

.metric-block .label {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* ─────────────────────────────────────────────
     Card 3: Target Nutrition & Macros
     ───────────────────────────────────────────── */
.calories-indicator-container {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.calories-circle {
    width: 130px;
    height: 130px;
    border-radius: 50%;
    border: 6px solid var(--accent-green);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.1), 0 4px 15px rgba(88,204,2,0.2);
}

body.dark-theme .calories-circle {
    box-shadow: inset 0 0 10px rgba(255,255,255,0.05), 0 4px 15px rgba(52,211,153,0.2);
}

.calories-value {
    font-size: 1.8rem;
    font-weight: 900;
}

.calories-lbl {
    font-size: 0.8rem;
    color: var(--text-secondary);
    text-transform: uppercase;
}

.macro-bars-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.macro-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 4px;
}

.macro-progress-track {
    width: 100%;
    height: 10px;
    background: rgba(0,0,0,0.05);
    border-radius: 5px;
    overflow: hidden;
}

body.dark-theme .macro-progress-track {
    background: rgba(255,255,255,0.05);
}

.macro-progress-fill {
    height: 100%;
    border-radius: 5px;
}

.p-fill { background-color: var(--accent-red); }
.c-fill { background-color: var(--accent-yellow); }
.f-fill { background-color: var(--accent-blue); }

/* ─────────────────────────────────────────────
     Card 4: Leaderboard
     ───────────────────────────────────────────── */
.leaderboard-table-container {
    width: 100%;
}

.leaderboard-table {
    width: 100%;
    border-collapse: collapse;
}

.leaderboard-table th {
    text-align: left;
    padding: 10px;
    color: var(--text-muted);
    font-weight: 800;
    border-bottom: 2px solid var(--border-stroke);
}

body.rtl-layout .leaderboard-table th {
    text-align: right;
}

.leaderboard-table td {
    padding: 12px 10px;
    border-bottom: 1px solid var(--border-stroke);
}

.athlete-cell {
    display: flex;
    align-items: center;
    gap: 10px;
}

.athlete-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

.highlighted-row {
    background-color: rgba(88,204,2,0.08);
}

/* ─────────────────────────────────────────────
     Guest Marketing Template
     ───────────────────────────────────────────── */
.guest-marketing-card {
    text-align: center;
    padding: 60px 40px;
    border-radius: 30px;
}

.marketing-logo-icon {
    font-size: 3.5rem;
    margin-bottom: 20px;
}

.marketing-title {
    font-size: 2.2rem;
    font-weight: 900;
    margin-bottom: 16px;
}

.marketing-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 30px auto;
    line-height: 1.6;
}

.marketing-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
}

/* ─────────────────────────────────────────────
     Floating Muscle Radar Widget
     ───────────────────────────────────────────── */
.muscle-radar-wrapper {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 90;
}

body.rtl-layout .muscle-radar-wrapper {
    right: auto;
    left: 30px;
}

.radar-handle-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: var(--radar-bg, var(--accent-orange));
    color: var(--radar-icon-color, #ffffff);
    box-shadow: 0 4px 15px var(--radar-glow, var(--accent-orange-shadow));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    border: none;
    position: relative;
    cursor: pointer;
}

.radar-handle-btn .handle-text {
    display: none;
}

.radar-handle-btn:hover {
    transform: scale(1.05);
}

.pulse-ring {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 2px solid var(--radar-bg, var(--accent-orange));
    animation: radarPulse 2s infinite ease-out;
}

@keyframes radarPulse {
    0% { transform: scale(1); opacity: 1; }
    100% { transform: scale(1.6); opacity: 0; }
}

.radar-window-card {
    display: none;
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 320px;
    background: var(--card-bg);
    border-radius: 20px;
    animation: slideUp 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

body.rtl-layout .radar-window-card {
    right: auto;
    left: 0;
}

@keyframes slideUp {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.radar-window-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.radar-window-header h4 {
    font-size: 1.1rem;
    font-weight: 800;
}

.radar-close-btn {
    border: none;
    background: none;
    font-size: 1.5rem;
    color: var(--text-primary);
    cursor: pointer;
}

.radar-instruction {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 15px;
}

.anatomy-svg-wrapper {
    display: flex;
    justify-content: center;
    margin-bottom: 15px;
}

.anatomy-svg {
    width: 150px;
    height: 250px;
}

.body-silhouette {
    fill: rgba(0,0,0,0.05);
}

body.dark-theme .body-silhouette {
    fill: rgba(255,255,255,0.05);
}

.muscle-group {
    fill: rgba(0,0,0,0.15);
    stroke: var(--bg-color);
    stroke-width: 1.5px;
    cursor: pointer;
    transition: fill 0.2s ease, filter 0.2s ease;
}

body.dark-theme .muscle-group {
    fill: rgba(255,255,255,0.15);
}

.muscle-group:hover, .muscle-group.active {
    fill: var(--accent-orange);
    filter: drop-shadow(0 0 5px var(--accent-orange));
}

.muscle-info-card {
    background: rgba(0,0,0,0.04);
    border-radius: 12px;
    padding: 10px;
    font-size: 0.8rem;
}

body.dark-theme .muscle-info-card {
    background: rgba(255,255,255,0.04);
}

.muscle-info-card h5 {
    font-weight: 800;
    margin-bottom: 4px;
    color: var(--accent-orange);
}

/* ─────────────────────────────────────────────
     Footer Layout
     ───────────────────────────────────────────── */
.glass-footer {
    background: linear-gradient(180deg, transparent, rgba(0,0,0,0.03));
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-top: 1px solid var(--card-border);
    padding: 32px 24px;
    margin-top: var(--section-gap);
    position: relative;
}

body.dark-theme .glass-footer {
    background: linear-gradient(180deg, transparent, rgba(0,0,0,0.2));
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

.footer-info p {
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 0.3px;
}

.footer-accessibility {
    display: flex;
    gap: 12px;
}

.footer-tool-btn {
    font-size: 0.8rem;
    padding: 8px 16px;
    border-radius: 10px;
}

.footer-tool-btn .battery-off-icon { display: none; }
.footer-tool-btn.active .battery-off-icon { display: block; }
.footer-tool-btn.active .battery-on-icon { display: none; }

.footer-tool-btn .volume-off-icon { display: none; }
.footer-tool-btn.muted .volume-off-icon { display: block; }
.footer-tool-btn.muted .volume-on-icon { display: none; }

/* ─────────────────────────────────────────────
     Login Modal Overlay
     ───────────────────────────────────────────── */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 200;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
}

.modal-card {
    position: relative;
    width: 90%;
    max-width: 440px;
    border-radius: 30px;
    padding: 30px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.3);
    animation: popIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes popIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.modal-close-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--text-primary);
    cursor: pointer;
    font-weight: 300;
}

body.rtl-layout .modal-close-btn {
    right: auto;
    left: 20px;
}

.mascot-animation-container {
    height: 100px;
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.modal-form-content h2 {
    text-align: center;
    margin-bottom: 20px;
    font-weight: 900;
    font-size: 1.8rem;
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 6px;
}

.form-input {
    width: 100%;
    padding: 12px 18px;
    border-radius: 14px;
    border: 2px solid var(--border-stroke);
    background: transparent;
    color: var(--text-primary);
    font-family: var(--font-family);
    outline: none;
    transition: border-color 0.2s;
}

.form-input:focus {
    border-color: var(--accent-green);
}

.submit-btn {
    width: 100%;
    margin-top: 10px;
    height: 48px;
    font-size: 1.1rem;
}

.error-banner {
    display: none;
    background-color: rgba(255, 75, 75, 0.15);
    border: 1px solid var(--accent-red);
    color: var(--accent-red);
    padding: 10px;
    border-radius: 12px;
    margin-bottom: 15px;
    font-weight: 600;
    font-size: 0.85rem;
    text-align: center;
}

/* ─────────────────────────────────────────────
     Duolingo Mascot CSS Drawing & Physics
     ───────────────────────────────────────────── */
.mascot-owl {
    width: 80px;
    height: 80px;
    position: relative;
    animation: mascotIdle 2s infinite alternate ease-in-out;
}

@keyframes mascotIdle {
    from { transform: translateY(0); }
    to { transform: translateY(-5px); }
}

.mascot-body {
    width: 100%;
    height: 100%;
    background-color: var(--accent-green);
    border-radius: 50% 50% 40% 40%;
    position: relative;
    border: 3px solid var(--accent-green-shadow);
    overflow: hidden;
}

.mascot-wings {
    position: absolute;
    width: 90px;
    left: -5px;
    top: 30px;
    display: flex;
    justify-content: space-between;
}

.mascot-wings::before, .mascot-wings::after {
    content: '';
    width: 15px;
    height: 35px;
    background-color: var(--accent-green);
    border: 3px solid var(--accent-green-shadow);
    border-radius: 50%;
}

.mascot-wings::before { transform: rotate(-20deg); }
.mascot-wings::after { transform: rotate(20deg); }

.mascot-face {
    position: absolute;
    width: 60px;
    height: 40px;
    left: 10px;
    top: 20px;
}

.mascot-eyes {
    display: flex;
    justify-content: space-between;
    width: 100%;
}

.mascot-eyes .eye {
    width: 26px;
    height: 26px;
    background-color: #ffffff;
    border-radius: 50%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--text-primary);
    transition: height 0.15s ease, margin-top 0.15s ease;
}

.mascot-eyes .pupil {
    width: 10px;
    height: 10px;
    background-color: var(--text-primary);
    border-radius: 50%;
    position: absolute;
    transition: transform 0.2s ease;
}

.mascot-beak {
    position: absolute;
    width: 12px;
    height: 12px;
    background-color: var(--accent-yellow);
    border: 2px solid var(--accent-yellow-shadow);
    transform: rotate(45deg);
    bottom: -6px;
    left: 24px;
    border-radius: 0 0 4px 0;
}

/* Mascot states triggers */
.mascot-owl.look-shy .eye {
    height: 4px;
    margin-top: 11px;
    border-radius: 2px;
    background-color: var(--text-primary);
}

.mascot-owl.look-shy .pupil {
    display: none;
}

.mascot-owl.celebrating {
    animation: mascotJump 0.5s infinite alternate cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes mascotJump {
    from { transform: translateY(0) scaleY(1); }
    to { transform: translateY(-30px) scaleY(1.05); }
}

.mascot-owl.celebrating .eye {
    background-color: var(--accent-yellow);
}

/* ─────────────────────────────────────────────
     Responsive Mobile Layout overrides (9:16 Aspect)
     ───────────────────────────────────────────── */
@media (max-width: 768px) {
    .glass-nav {
        top: 40px !important;
        left: 0 !important;
        right: 0 !important;
        transform: none !important;
        width: 100% !important;
        height: 64px !important;
        border-radius: 10px !important;
        display: block !important;
    }

    .nav-container {
        padding: 0 12px !important;
    }

    .nav-btn .btn-text {
        display: none; /* Hide lang text on mobile for spacing */
    }

    .nav-stat-badge {
        padding: 4px 8px;
        font-size: 0.8rem;
    }

    .hero-title {
        font-size: 1.8rem;
    }

    .hero-description {
        font-size: 0.95rem;
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    /* 9:16 Instagram-style mobile fallback for video section */
    .hero-section {
        height: 100vh;
        aspect-ratio: 9/16;
    }
}

/* General Animations */
.hover-scale {
    transition: transform 0.2s ease;
}
.hover-scale:hover {
    transform: scale(1.03);
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.animate-pulse {
    animation: pulse 2s infinite ease-in-out;
}

/* ─────────────────────────────────────────────
     Premium Footer Controls Bar
     ───────────────────────────────────────────── */
.footer-controls-bar {
    display: flex;
    align-items: center;
    gap: 0;
    background: rgba(0,0,0,0.2);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 50px;
    padding: 4px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), 0 4px 15px rgba(0,0,0,0.2);
}

body.dark-theme .footer-controls-bar {
    background: rgba(255,255,255,0.04);
    border-color: rgba(255,255,255,0.06);
}

.footer-ctrl-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    border: none;
    border-radius: 50px;
    background: transparent;
    color: rgba(255,255,255,0.5);
    font-family: var(--font-family);
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    white-space: nowrap;
}

.footer-ctrl-pill.active {
    background: rgba(88, 204, 2, 0.15);
    color: var(--accent-green);
    box-shadow: 0 0 20px rgba(88, 204, 2, 0.1);
}

.footer-ctrl-pill:hover {
    background: rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.9);
}

.footer-ctrl-pill.active:hover {
    background: rgba(88, 204, 2, 0.25);
    color: var(--accent-green);
}

.ctrl-icon-wrap {
    font-size: 1rem;
    line-height: 1;
}

.ctrl-icon-off { display: none; }
.footer-ctrl-pill:not(.active) .ctrl-icon-on { display: none; }
.footer-ctrl-pill:not(.active) .ctrl-icon-off { display: inline; }

.ctrl-status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255,255,255,0.2);
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.footer-ctrl-pill.active .ctrl-status-dot {
    background: var(--accent-green);
    box-shadow: 0 0 8px rgba(88, 204, 2, 0.6);
}

.ctrl-divider {
    width: 1px;
    height: 24px;
    background: rgba(255,255,255,0.1);
    flex-shrink: 0;
}

@media (max-width: 768px) {
    .footer-controls-bar {
        width: 100%;
        justify-content: center;
    }
    .ctrl-label {
        display: none;
    }
    .footer-ctrl-pill {
        padding: 10px 14px;
    }
}

/* ─────────────────────────────────────────────
     Testimonial Avatar Styles
     ───────────────────────────────────────────── */
.testimonial-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--accent-green);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* ─────────────────────────────────────────────
     How It Works — 3-Step Timeline
     ───────────────────────────────────────────── */
.how-it-works-grid {
    display: flex;
    gap: 24px;
    justify-content: center;
    align-items: flex-start;
    flex-wrap: wrap;
    margin: 40px auto;
    max-width: 900px;
    position: relative;
}

.how-step-card {
    flex: 1;
    min-width: 220px;
    max-width: 280px;
    text-align: center;
    padding: 32px 20px;
    position: relative;
}

.step-number {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    font-size: 1.5rem;
    font-weight: 900;
    color: #fff;
    position: relative;
    z-index: 2;
}

.step-number.step-1 { background: linear-gradient(135deg, var(--accent-green), #45d416); }
.step-number.step-2 { background: linear-gradient(135deg, var(--accent-blue), #0088ff); }
.step-number.step-3 { background: linear-gradient(135deg, var(--accent-yellow), #ffaa00); }

.how-step-card h4 {
    font-size: 1.1rem;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.how-step-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Connector line between steps (desktop) */
.how-it-works-grid::before {
    content: '';
    position: absolute;
    top: 60px;
    left: 20%;
    width: 60%;
    height: 2px;
    background: linear-gradient(90deg, var(--accent-green), var(--accent-blue), var(--accent-yellow));
    opacity: 0.3;
    z-index: 1;
}

@media (max-width: 768px) {
    .how-it-works-grid::before { display: none; }
    .how-it-works-grid { flex-direction: column; align-items: center; }
}

/* ─────────────────────────────────────────────
     Before & After Transformation Cards
     ───────────────────────────────────────────── */
.transformations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin: 40px auto;
    max-width: 1000px;
}

.transformation-card {
    text-align: center;
    padding: 24px;
    position: relative;
    overflow: hidden;
}

.transformation-card .transform-stats {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin: 16px 0;
    flex-wrap: wrap;
}

.transform-stat {
    background: rgba(88, 204, 2, 0.1);
    border: 1px solid rgba(88, 204, 2, 0.2);
    border-radius: 12px;
    padding: 8px 16px;
    font-weight: 800;
    font-size: 0.85rem;
    color: var(--accent-green);
}

.transformation-card .transform-name {
    font-weight: 800;
    font-size: 1rem;
    margin-top: 12px;
    color: var(--text-primary);
}

.transform-emoji {
    font-size: 3.5rem;
    margin-bottom: 8px;
    display: block;
}

/* ─────────────────────────────────────────────
     FAQ Accordion Section
     ───────────────────────────────────────────── */
.faq-list {
    max-width: 800px;
    margin: 40px auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.faq-item {
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.faq-question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 18px 24px;
    background: none;
    border: none;
    color: var(--text-primary);
    font-family: var(--font-family);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    text-align: start;
    gap: 16px;
    transition: all 0.2s ease;
}

.faq-question:hover {
    color: var(--accent-green);
}

.faq-question .faq-toggle-icon {
    font-size: 0.85rem;
    transition: transform 0.3s ease;
    flex-shrink: 0;
    color: var(--accent-green);
}

.faq-item.open .faq-toggle-icon {
    transform: rotate(45deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
    padding: 0 24px;
}

.faq-item.open .faq-answer {
    max-height: 300px;
    padding: 0 24px 18px;
}

.faq-answer p {
    color: var(--text-secondary);
    font-size: 0.92rem;
    line-height: 1.7;
    margin: 0;
}

/* ─────────────────────────────────────────────
     Final CTA Section
     ───────────────────────────────────────────── */
.final-cta-section {
    text-align: center;
    padding: 60px 24px;
    margin: 40px auto;
    max-width: 700px;
    position: relative;
}

.final-cta-section .cta-emoji {
    font-size: 4rem;
    margin-bottom: 16px;
    display: block;
    animation: subtleBounce 2s ease-in-out infinite;
}

.final-cta-section h2 {
    font-size: 2rem;
    font-weight: 900;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.final-cta-section p {
    font-size: 1.05rem;
    color: var(--text-secondary);
    margin-bottom: 32px;
    line-height: 1.7;
}

.final-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 18px 48px;
    font-size: 1.15rem;
    font-weight: 800;
    border-radius: 16px;
    text-decoration: none;
    transition: all 0.3s ease;
    animation: subtleBounce 2s ease-in-out infinite;
}

.final-cta-btn:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 16px 40px rgba(88, 204, 2, 0.3);
}

/* ─────────────────────────────────────────────
     Visitor Sales Funnel & Marketing Elements
     ───────────────────────────────────────────── */
.fcp-topbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 36px;
    background: rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(12px) saturate(180%);
    -webkit-backdrop-filter: blur(12px) saturate(180%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    z-index: 1200;
    display: flex;
    align-items: center;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.15);
}
body.dark-theme .fcp-topbar {
    background: rgba(15, 23, 42, 0.7);
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}
.topbar-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.topbar-promo {
    font-size: 0.8rem;
    font-weight: 800;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
}
body.dark-theme .topbar-promo {
    color: #f1f5f9;
}
.topbar-switchers {
    display: flex;
    align-items: center;
    gap: 12px;
}
.topbar-btn {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #ffffff;
    padding: 4px 14px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 800;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    font-family: var(--font-family);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}
body.dark-theme .topbar-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
}
.topbar-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
body.dark-theme .topbar-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}
.topbar-btn:active {
    transform: translateY(1px);
    box-shadow: none;
}
.topbar-btn i {
    font-size: 0.85rem;
}
.topbar-btn .theme-icon-light { display: none; }
body.dark-theme .topbar-btn .theme-icon-dark { display: none; }
body.dark-theme .topbar-btn .theme-icon-light { display: block; }

/* Shift body and nav down */
body {
    padding-top: 100px;
}
.glass-nav {
    top: 36px;
    transform: none;
}

@media (max-width: 768px) {
    .fcp-topbar {
        height: 40px;
    }
    .topbar-container {
        padding: 0 12px;
    }
    .topbar-promo {
        font-size: 0.7rem;
        max-width: 60%;
        line-height: 1.2;
    }
    body {
        padding-top: 104px;
    }
    .glass-nav {
        top: 40px !important;
        transform: none !important;
        left: 0 !important;
        right: 0 !important;
    }
}

.funnel-marketing-content {
    margin-top: 40px;
}

.marketing-section-header {
    margin-bottom: 56px;
    text-align: center;
}

.section-main-title {
    font-size: 2.5rem;
    font-weight: 900;
    letter-spacing: -0.8px;
    margin-bottom: 14px;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent-green) 60%, var(--accent-blue) 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientShift 5s ease infinite;
}

.section-sub-title {
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 580px;
    margin: 0 auto;
    line-height: 1.7;
}

.funnel-features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-bottom: 80px;
}

.funnel-feature-card {
    text-align: center;
    border-radius: var(--card-radius);
    padding: 40px 28px;
    border: 1px solid var(--card-border);
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    position: relative;
    overflow: hidden;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275),
                box-shadow 0.4s ease,
                border-color 0.3s ease;
}

.funnel-feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
}

.funnel-feature-card:hover {
    transform: translateY(-6px);
    border-color: rgba(255,255,255,0.15);
    box-shadow: var(--box-shadow), 0 20px 50px rgba(0,0,0,0.08);
}

.feat-icon-badge {
    width: 72px;
    height: 72px;
    border-radius: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    margin-bottom: 22px;
    color: #ffffff;
    box-shadow: 0 6px 0 rgba(0,0,0,0.15);
    position: relative;
}

/* Icon glow halo effect */
.feat-icon-badge::after {
    content: '';
    position: absolute;
    inset: -8px;
    border-radius: 28px;
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: -1;
}

.funnel-feature-card:hover .feat-icon-badge::after {
    opacity: 1;
}

.feat-icon-badge.color-orange {
    background: linear-gradient(135deg, var(--accent-orange), #ea580c);
    box-shadow: 0 6px 0 var(--accent-orange-shadow);
}
.feat-icon-badge.color-orange::after {
    background: radial-gradient(circle, rgba(249,115,22,0.3), transparent 70%);
}

.feat-icon-badge.color-blue {
    background: linear-gradient(135deg, var(--accent-blue), #2563eb);
    box-shadow: 0 6px 0 var(--accent-blue-shadow);
}
.feat-icon-badge.color-blue::after {
    background: radial-gradient(circle, rgba(59,130,246,0.3), transparent 70%);
}

.feat-icon-badge.color-green {
    background: linear-gradient(135deg, var(--accent-green), #16a34a);
    box-shadow: 0 6px 0 var(--accent-green-shadow);
}
.feat-icon-badge.color-green::after {
    background: radial-gradient(circle, rgba(34,197,94,0.3), transparent 70%);
}

.funnel-feature-card h4 {
    font-size: 1.25rem;
    font-weight: 800;
    margin-bottom: 12px;
    letter-spacing: -0.3px;
}

.funnel-feature-card p {
    color: var(--text-secondary);
    font-size: 0.92rem;
    line-height: 1.7;
}

/* Testimonial Leaderboard Rows */
.testimonial-leaderboard-wrapper {
    padding: 30px;
    border-radius: 28px;
    margin-bottom: 80px;
}

.testimonial-th {
    width: 50%;
}

.athlete-avatar-placeholder {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: var(--accent-blue);
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.8rem;
}

.text-yellow {
    color: var(--accent-yellow);
}

/* Pricing Cards Design System */
.funnel-pricing-cards-flex {
    display: flex;
    justify-content: center;
    align-items: stretch;
    gap: 30px;
    flex-wrap: wrap;
    margin-top: 40px;
}

.pricing-plan-card {
    flex: 1;
    min-width: 290px;
    max-width: 360px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border-radius: var(--card-radius);
    padding: 44px 32px;
    border: 2px solid var(--card-border);
    position: relative;
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    box-shadow: var(--box-shadow);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275),
                box-shadow 0.4s ease,
                border-color 0.3s ease;
    overflow: hidden;
}

.premium-plan-card {
    border: 3px solid var(--accent-yellow);
}

.elite-plan-card {
    border: 3px solid var(--accent-red);
}

.popular-ribbon {
    position: absolute;
    top: 15px;
    right: -10px;
    padding: 4px 15px;
    font-size: 0.75rem;
    font-weight: 900;
    color: #ffffff;
    border-radius: 6px 0 0 6px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

body.rtl-layout .popular-ribbon {
    right: auto;
    left: -10px;
    border-radius: 0 6px 6px 0;
}

.pricing-plan-card .plan-header h3 {
    font-size: 1.5rem;
    font-weight: 900;
    margin-bottom: 10px;
}

.pricing-plan-card .plan-price {
    font-size: 2.8rem;
    font-weight: 900;
    margin-bottom: 25px;
}

.pricing-plan-card .plan-price .currency {
    font-size: 1.8rem;
    vertical-align: super;
}

.pricing-plan-card .plan-price .period {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 600;
}

.pricing-plan-card .plan-features {
    list-style: none;
    padding: 0;
    margin: 0 0 30px 0;
    text-align: left;
}

body.rtl-layout .pricing-plan-card .plan-features {
    text-align: right;
}

.pricing-plan-card .plan-features li {
    font-size: 0.95rem;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-primary);
}

.pricing-plan-card .plan-features li i {
    font-size: 1.1rem;
}

.check-green { color: var(--accent-green); }
.check-yellow { color: var(--accent-yellow); }
.check-red { color: var(--accent-red); }

.pricing-plan-card .plan-footer {
    margin-top: auto;
}

.pricing-plan-card .plan-cta-btn {
    width: 100%;
    padding: 14px 20px;
    box-sizing: border-box;
}

/* ─────────────────────────────────────────────
     Off-Canvas Checkout Panel Drawer & Confetti
     ───────────────────────────────────────────── */
.checkout-drawer-wrapper {
    position: fixed;
    top: 0;
    right: 0;
    width: 450px;
    height: 100vh;
    z-index: 1500;
    transform: translateX(100%);
    transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
    max-width: 100%;
}

.checkout-drawer-wrapper.drawer-open {
    transform: translateX(0);
}

body.rtl-layout .checkout-drawer-wrapper {
    right: auto;
    left: 0;
    transform: translateX(-100%);
}

body.rtl-layout .checkout-drawer-wrapper.drawer-open {
    transform: translateX(0);
}

.checkout-drawer-card {
    height: 100%;
    border-radius: 0;
    border-left: 1px solid var(--card-border);
    border-right: none;
    border-top: none;
    border-bottom: none;
    padding: 40px 30px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    box-sizing: border-box;
}

body.rtl-layout .checkout-drawer-card {
    border-right: 1px solid var(--card-border);
    border-left: none;
}

.drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1400;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    display: none;
}

.drawer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.drawer-header h3 {
    font-size: 1.5rem;
    font-weight: 900;
}

.drawer-close-btn {
    background: none;
    border: none;
    font-size: 2.2rem;
    cursor: pointer;
    color: var(--text-primary);
    line-height: 1;
}

.selected-plan-summary {
    background: rgba(0,0,0,0.03);
    border: 1px solid var(--border-stroke);
    border-radius: 20px;
    padding: 20px;
    margin-bottom: 25px;
    text-align: center;
}

body.dark-theme .selected-plan-summary {
    background: rgba(255,255,255,0.03);
}

.selected-plan-summary h4 {
    font-size: 1.2rem;
    font-weight: 800;
    margin-bottom: 8px;
}

.plan-price-block {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 4px;
}

.plan-price-block .price-val {
    font-size: 2.2rem;
    font-weight: 900;
    color: var(--accent-green);
}

.plan-price-block .price-period {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.checkout-form-fields {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.input-icon-wrapper {
    position: relative;
}

.input-icon-wrapper .form-input {
    padding-right: 45px;
}

body.rtl-layout .input-icon-wrapper .form-input {
    padding-right: 18px;
    padding-left: 45px;
}

.input-icon-wrapper .input-icon {
    position: absolute;
    top: 50%;
    right: 15px;
    transform: translateY(-50%);
    color: var(--text-secondary);
    font-size: 1.1rem;
    pointer-events: none;
}

body.rtl-layout .input-icon-wrapper .input-icon {
    right: auto;
    left: 15px;
}

.form-row-flex {
    display: flex;
    gap: 15px;
}

.flex-1 {
    flex: 1;
}

.transaction-breakdown {
    background: rgba(0,0,0,0.02);
    border: 1px solid var(--border-stroke);
    border-radius: 16px;
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-size: 0.9rem;
}

body.dark-theme .transaction-breakdown {
    background: rgba(255,255,255,0.02);
}

.breakdown-row {
    display: flex;
    justify-content: space-between;
}

.breakdown-divider {
    border: 0;
    height: 1px;
    background: var(--border-stroke);
    margin: 5px 0;
}

.breakdown-row.total-row {
    font-size: 1.1rem;
    font-weight: 900;
}

.text-green {
    color: var(--accent-green) !important;
}

.secure-footer-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 10px;
}

.confetti-overlay-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2000;
    pointer-events: none;
    display: none;
}

/* ─────────────────────────────────────────────
     Premium Polish & Micro-Animations
     ───────────────────────────────────────────── */

/* Smooth scroll behavior */
html {
    scroll-behavior: smooth;
}

/* Premium text selection */
::selection {
    background: var(--accent-green);
    color: #ffffff;
}

/* Glass nav entrance animation (opacity fade-in) */
.glass-nav {
    animation: navSlideIn 0.6s ease-out both;
}

@keyframes navSlideIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Topbar entrance */
.fcp-topbar {
    animation: topbarSlide 0.4s ease-out both;
}

@keyframes topbarSlide {
    from { transform: translateY(-100%); }
    to { transform: translateY(0); }
}

/* Hero section parallax-like depth */
.hero-section::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 120px;
    background: linear-gradient(to top, var(--bg-color), transparent);
    z-index: 2;
    pointer-events: none;
}

/* Section reveal animation */
.marketing-section-header,
.funnel-features-grid,
.testimonial-leaderboard-wrapper,
.funnel-pricing-cards-flex {
    opacity: 0;
    transform: translateY(30px);
    animation: sectionReveal 0.8s ease-out forwards;
}

.funnel-features-grid { animation-delay: 0.1s; }
.testimonial-leaderboard-wrapper { animation-delay: 0.2s; }
.funnel-pricing-cards-flex { animation-delay: 0.3s; }

@keyframes sectionReveal {
    to { opacity: 1; transform: translateY(0); }
}

/* Feature cards stagger animation */
.funnel-feature-card:nth-child(1) { animation: cardPop 0.5s 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275) both; }
.funnel-feature-card:nth-child(2) { animation: cardPop 0.5s 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275) both; }
.funnel-feature-card:nth-child(3) { animation: cardPop 0.5s 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) both; }

@keyframes cardPop {
    from { opacity: 0; transform: scale(0.8) translateY(20px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

/* Pricing card hover glow with perspective tilt */
.pricing-plan-card:hover {
    transform: translateY(-8px) perspective(1000px) rotateX(2deg);
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.18), 0 0 0 1px rgba(255,255,255,0.05);
}

.premium-plan-card:hover {
    border-color: var(--accent-yellow);
    box-shadow: 0 24px 64px rgba(234, 179, 8, 0.2), 0 0 40px rgba(234, 179, 8, 0.1);
}

.elite-plan-card:hover {
    border-color: var(--accent-red);
    box-shadow: 0 24px 64px rgba(239, 68, 68, 0.2), 0 0 40px rgba(239, 68, 68, 0.1);
}

/* Dashboard card hover lift */
.dashboard-card.glass-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

/* Premium login button glow pulse */
.login-btn {
    position: relative;
    overflow: hidden;
}

.login-btn::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, transparent 60%);
    animation: loginGlow 3s infinite;
    pointer-events: none;
}

@keyframes loginGlow {
    0%, 100% { transform: translate(-10%, -10%); opacity: 0; }
    50% { transform: translate(10%, 10%); opacity: 1; }
}

/* Streak badge fire animation */
.streak-badge {
    position: relative;
}

.streak-badge .badge-icon {
    display: inline-block;
    animation: fireFlicker 1.5s infinite alternate;
}

@keyframes fireFlicker {
    0% { transform: scale(1) rotate(-2deg); }
    50% { transform: scale(1.15) rotate(2deg); }
    100% { transform: scale(1.05) rotate(-1deg); }
}

/* XP badge star spin on hover */
.xp-badge:hover .badge-icon {
    animation: starSpin 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes starSpin {
    from { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(180deg) scale(1.3); }
    to { transform: rotate(360deg) scale(1); }
}

/* Avatar ring pulse */
.nav-avatar-circle {
    transition: all 0.3s ease;
}

.nav-avatar-circle:hover {
    transform: scale(1.1);
    box-shadow: 0 0 0 4px rgba(88, 204, 2, 0.3);
}

/* Footer glass enhancement — premium rainbow gradient line */
.glass-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 10%;
    width: 80%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent-green), var(--accent-blue), var(--accent-purple, #a855f7), transparent);
    opacity: 0.5;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-color);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--accent-green), var(--accent-blue));
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, var(--accent-blue), var(--accent-green));
}

/* Loading skeleton shimmer for AJAX content */
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.skeleton-loading {
    background: linear-gradient(90deg, var(--card-bg) 25%, rgba(255,255,255,0.1) 50%, var(--card-bg) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

/* Hero title gradient text effect */
.hero-title {
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent-green) 50%, var(--accent-blue) 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientShift 4s ease infinite;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% center; }
    50% { background-position: 100% center; }
}

/* Section title underline accent — premium glow */
.section-main-title {
    position: relative;
    display: inline-block;
}

.section-main-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--accent-green), var(--accent-blue), var(--accent-purple, #a855f7));
    box-shadow: 0 0 12px var(--accent-green-glow, rgba(34,197,94,0.3));
}

/* Testimonial table row hover */
.leaderboard-table tbody tr {
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.leaderboard-table tbody tr:hover {
    background-color: rgba(88, 204, 2, 0.06);
}

/* Plan CTA button bounce hint */
.plan-cta-btn {
    transition: all 0.2s ease;
}

.premium-plan-card .plan-cta-btn {
    animation: subtleBounce 2s ease-in-out infinite;
}

@keyframes subtleBounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}

/* Modal backdrop premium blur */
.modal-overlay {
    transition: opacity 0.3s ease;
}

.glass-modal {
    background: var(--card-bg);
    backdrop-filter: blur(20px) saturate(200%);
    -webkit-backdrop-filter: blur(20px) saturate(200%);
}

/* Input focus glow */
.form-input:focus {
    box-shadow: 0 0 0 3px rgba(88, 204, 2, 0.15);
}

/* Radar widget entrance */
.muscle-radar-wrapper {
    animation: radarEntrance 0.6s 1s cubic-bezier(0.175, 0.885, 0.32, 1.275) both;
}

@keyframes radarEntrance {
    from { transform: scale(0) rotate(-90deg); opacity: 0; }
    to { transform: scale(1) rotate(0); opacity: 1; }
}

/* transition animations between funnel and dashboard views */
#guest-funnel-view, #client-dashboard-view {
    transition: opacity 0.5s ease, transform 0.5s ease;
}

/* Below-the-fold rendering optimization */
#features-section,
#how-it-works-section,
#transformations-section,
#testimonials-section,
#faq-section,
#pricing-plans-section {
    content-visibility: auto;
    contain-intrinsic-size: auto 500px;
}

/* ═══════════════════════════════════════════════
   Universal Section Alignment & Responsiveness
   ═══════════════════════════════════════════════ */
.how-it-works-grid {
    max-width: 1200px !important;
    width: 100% !important;
}
.transformations-grid {
    max-width: 1200px !important;
    width: 100% !important;
}
.faq-list {
    max-width: 1200px !important;
    width: 100% !important;
}
.final-cta-section {
    max-width: 1200px !important;
    width: 100% !important;
}
/* Ensure table responsiveness */
.leaderboard-table-container {
    width: 100% !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
}

/* Move Radar icon slightly upward to clear footer buttons (logical inset positioning) */
.muscle-radar-wrapper {
    bottom: 100px !important;
    inset-inline-end: 30px !important;
}

/* Premium Circular Icon-Only Footer Controls */
.footer-ctrl-pill {
    width: 44px !important;
    height: 44px !important;
    padding: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 50% !important;
    gap: 0 !important;
}
.footer-ctrl-pill .ctrl-status-dot {
    position: absolute;
    bottom: 6px;
    inset-inline-end: 6px;
    width: 6px;
    height: 6px;
}

/* Desktop Navigation Menu styling inside sticky glass-nav */
.desktop-nav-menu {
    display: flex;
    align-items: center;
    margin: 0 auto;
}
.nav-menu-list {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 4px;
    gap: 6px;
    background: rgba(0, 0, 0, 0.04);
    border-radius: 14px;
    border: 1px solid rgba(0, 0, 0, 0.03);
    transition: all 0.3s ease;
}
body.dark-theme .nav-menu-list {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.03);
}
.nav-menu-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 700;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    padding: 8px 16px;
    border-radius: 10px;
    position: relative;
    letter-spacing: -0.1px;
}
.nav-menu-link:hover {
    color: var(--text-primary);
    background: rgba(0, 0, 0, 0.03);
    transform: translateY(-1px);
}
.nav-menu-link.active {
    color: var(--accent-green) !important;
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06), inset 0 1px 0 rgba(255, 255, 255, 0.9);
}
body.dark-theme .nav-menu-link {
    color: #94a3b8;
}
body.dark-theme .nav-menu-link:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.03);
    transform: translateY(-1px);
}
body.dark-theme .nav-menu-link.active {
    color: #4ade80 !important;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}


/* ==========================================================================
   SECTION: MENU & NAVIGATION SYSTEM (Desktop & Mobile Dropdown)
   ========================================================================== */
/* ─────────────────────────────────────────────
     Navigation Bar (Header)
     ───────────────────────────────────────────── */
.glass-nav {
    position: fixed !important;
    top: 36px !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    height: 64px !important;
    z-index: 1000 !important;
    background: var(--card-bg) !important;
    backdrop-filter: blur(24px) saturate(200%) !important;
    -webkit-backdrop-filter: blur(24px) saturate(200%) !important;
    border-bottom: 1px solid var(--card-border) !important;
    border-radius: 10px !important;
    box-shadow: 0 4px 24px rgba(0,0,0,0.05) !important;
    display: block !important; /* Block-level container for robust margin-auto centering */
    transform: none !important;
}

.nav-logo {
    display: flex;
    align-items: center;
}
.nav-logo img,
.nav-logo .custom-logo {
    max-height: 36px;
    width: auto;
    display: block;
    object-fit: contain;
}

.nav-container {
    width: 100% !important;
    max-width: 1200px !important;
    height: 100% !important;
    margin: 0 auto !important;
    padding: 0 24px !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
}

.site-title-link {
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--text-primary);
    text-decoration: none;
    letter-spacing: -1px;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.nav-btn {
    height: 44px;
    border-radius: 12px;
}

/* Dark mode icons */
.theme-icon-light { display: none; }
body.dark-theme .theme-icon-dark { display: none; }
body.dark-theme .theme-icon-light { display: block; }

/* Logged-in profile widget */
.nav-profile-widget {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-stat-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(0,0,0,0.05);
    padding: 6px 12px;
    border-radius: 12px;
    font-weight: 800;
    font-size: 0.9rem;
}

body.dark-theme .nav-stat-badge {
    background: rgba(255,255,255,0.05);
}

.nav-avatar-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid var(--accent-green);
    object-fit: cover;
    display: block;
    cursor: pointer;
}

.logout-btn {
    font-size: 0.8rem;
    padding: 6px 12px;
    height: auto;
    background: rgba(255,75,75,0.15);
    color: var(--accent-red);
    border: 1px solid rgba(255,75,75,0.3);
}

body.dark-theme .logout-btn {
    background: rgba(255,75,75,0.2);
    color: #ff6b6b;
    border-color: rgba(255,75,75,0.4);
}

/* Mobile Toggle Hamburger Button */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 18px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 200;
    margin-inline-start: 12px;
}
.mobile-menu-toggle .bar {
    width: 100%;
    height: 2px;
    background-color: var(--text-primary);
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}
.mobile-menu-toggle.open .bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}
.mobile-menu-toggle.open .bar:nth-child(2) {
    opacity: 0;
}
.mobile-menu-toggle.open .bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* Mobile Menu Dropdown (Replaces Side Drawer) */
.mobile-menu-drawer {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    height: auto;
    background: var(--card-bg);
    backdrop-filter: blur(30px) saturate(180%);
    -webkit-backdrop-filter: blur(30px) saturate(180%);
    border-bottom: 1px solid var(--card-border);
    z-index: 1000;
    padding: 24px;
    display: flex;
    flex-direction: column;
    transform-origin: top;
    transform: scaleY(0);
    opacity: 0;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
    box-shadow: 0 10px 30px rgba(0,0,0,0.12);
}
.mobile-menu-drawer.open {
    transform: scaleY(1);
    opacity: 1;
}
.mobile-drawer-close {
    display: none; /* Hidden, toggling handled by hamburger toggle */
}
.mobile-nav-menu {
    margin-top: 0;
}
.mobile-menu-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.mobile-menu-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 700;
    display: block;
    padding: 12px 16px;
    border-radius: 12px;
    transition: all 0.3s ease;
}
.mobile-menu-link:hover,
.mobile-menu-link.active {
    color: var(--accent-green);
    background: rgba(34, 197, 94, 0.08);
}
body.dark-theme .mobile-menu-link {
    color: #94a3b8;
}
body.dark-theme .mobile-menu-link:hover,
body.dark-theme .mobile-menu-link.active {
    color: #4ade80;
    background: rgba(74, 222, 128, 0.08);
}

/* Hide desktop nav / show mobile toggle at smaller screens */
@media (max-width: 1024px) {
    .desktop-nav-menu {
        display: none;
    }
    .mobile-menu-toggle {
        display: flex;
    }
}

/* Scroll target offset adjustments to compensate sticky header */
[id] {
    scroll-margin-top: 95px !important;
}

/* ═══════════════════════════════════════════════
   Section Width & Spacing Overrides
   ═══════════════════════════════════════════════ */

/* Normalize all sections to match Leaderboard Champions (1200px max) */
.how-it-works-grid {
    max-width: 1200px !important;
    width: 100% !important;
    gap: 30px !important;
}
.how-step-card {
    max-width: 380px !important;
    min-width: 280px !important;
}
.transformations-grid {
    max-width: 1200px !important;
    width: 100% !important;
    gap: 30px !important;
}
.faq-list {
    max-width: 1200px !important;
    width: 100% !important;
    gap: 16px !important;
}
.final-cta-section {
    max-width: 1200px !important;
    width: 100% !important;
    padding: 80px 40px !important;
}
.final-cta-section p {
    max-width: 720px !important;
    margin: 0 auto 30px !important;
}

/* Standardize vertical spacing between sections (100px) and headers (40px) */
.marketing-section-header {
    margin-top: 0 !important;
    margin-bottom: 40px !important;
}
.funnel-features-grid,
.how-it-works-grid,
.transformations-grid,
.testimonial-leaderboard-wrapper,
.funnel-pricing-cards-flex,
.faq-list,
.final-cta-section {
    margin-top: 0 !important;
    margin-bottom: 100px !important;
}



/* ==========================================================================
   SECTION: LIGHT (BUSINESS) THEME OVERRIDES
   ========================================================================== */
/* Flat button system for Business Light Mode */
/* Premium Flat Corporate Button System for Business Light Mode */
.btn-3d {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    border-radius: var(--btn-radius);
    cursor: pointer;
    border: 1px solid rgba(0,0,0,0.06);
    outline: none;
    font-family: var(--font-family);
    background-color: #f1f5f9;
    color: #334155;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.btn-3d::after {
    display: none;
}

.btn-3d:hover {
    background-color: #e2e8f0;
    color: #1e293b;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.btn-3d:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(0,0,0,0.05) !important;
}

.primary-3d-btn {
    background: #0f172a !important; /* Deep Business Navy/Slate */
    color: #ffffff !important;
    border: 1px solid #0f172a !important;
    box-shadow: 0 2px 4px rgba(15, 23, 42, 0.1) !important;
}

.primary-3d-btn:hover {
    background: #1e293b !important;
    border-color: #1e293b !important;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.15) !important;
}

.secondary-3d-btn {
    background: #ffffff !important;
    color: #0f172a !important;
    border: 1px solid #cbd5e1 !important;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05) !important;
}

.secondary-3d-btn:hover {
    background: #f8fafc !important;
    border-color: #94a3b8 !important;
}

.orange-3d-btn {
    background: #2563eb !important; /* Royal Accent Blue */
    color: #ffffff !important;
    border: 1px solid #2563eb !important;
    box-shadow: 0 2px 4px rgba(37, 99, 235, 0.15) !important;
}

.orange-3d-btn:hover {
    background: #1d4ed8 !important;
    border-color: #1d4ed8 !important;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2) !important;
}

/* ═══════════════════════════════════════════════
   Business Theme Overrides for Light Mode
   ═══════════════════════════════════════════════ */
body:not(.dark-theme) {
    /* Clean flat backgrounds */
    --card-bg: #ffffff;
    --card-border: #e2e8f0;
    background-color: #f8fafc;
    color: #0f172a;
}

/* Flatten glass-cards to minimal solid cards in Light Mode */
body:not(.dark-theme) .glass-card {
    background: #ffffff !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 1px 3px rgba(15,23,42,0.05), 0 10px 30px rgba(15,23,42,0.04) !important;
    border-radius: 12px !important;
}

body:not(.dark-theme) .glass-card::before {
    display: none !important; /* Remove top white glare line */
}

/* Hero card in Business Light Mode */
body:not(.dark-theme) .hero-card {
    background: none !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    padding: 0 !important;
}

/* Flat icons and dark expressive colors in Light Mode */
body:not(.dark-theme) .feat-icon-badge {
    background: #f1f5f9 !important;
    border: 1px solid #cbd5e1 !important;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05) !important;
    border-radius: 12px !important;
    color: #0f172a !important;
}
body:not(.dark-theme) .feat-icon-badge i {
    color: #0f172a !important;
}
body:not(.dark-theme) .feat-icon-badge::after {
    display: none !important;
}

/* Flat style checkmarks inside pricing and lists */
body:not(.dark-theme) .plan-features li i.check-green,
body:not(.dark-theme) .plan-features li i.check-yellow,
body:not(.dark-theme) .plan-features li i.check-red {
    color: #0f172a !important; /* Flat dark checkmarks */
    font-size: 0.95rem;
}

/* Step numbers/badges in How It Works */
body:not(.dark-theme) .how-step-card .step-number {
    background: #f1f5f9 !important;
    border: 1px solid #cbd5e1 !important;
    color: #0f172a !important;
    box-shadow: none !important;
}

/* Testimonial and Leaderboard layout adjustments */
body:not(.dark-theme) .testimonial-leaderboard-wrapper {
    background: #ffffff !important;
    border: 1px solid #cbd5e1 !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03) !important;
    border-radius: 16px !important;
}

/* Table styles in Light Business Mode */
body:not(.dark-theme) .leaderboard-table th {
    background-color: #f1f5f9 !important;
    color: #0f172a !important;
    font-weight: 700 !important;
    border-bottom: 2px solid #cbd5e1 !important;
}
body:not(.dark-theme) .leaderboard-table td {
    border-bottom: 1px solid #e2e8f0 !important;
}
body:not(.dark-theme) .leaderboard-table tr:hover td {
    background-color: #f8fafc !important;
}

/* FAQ Accordions */
body:not(.dark-theme) .faq-item {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 8px !important;
}
body:not(.dark-theme) .faq-question {
    color: #0f172a !important;
    font-weight: 700 !important;
}
body:not(.dark-theme) .faq-toggle-icon {
    color: #0f172a !important;
}

/* Final CTA Section in Light Mode */
body:not(.dark-theme) .final-cta-section {
    background: #ffffff !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 16px !important;
    box-shadow: 0 10px 40px rgba(0,0,0,0.04) !important;
}

/* FOMO Topbar background in Light Mode */
body:not(.dark-theme) .fcp-topbar {
    background: #0f172a !important; /* Solid sleek dark topbar */
    border-bottom: 1px solid #1e293b !important;
}
body:not(.dark-theme) .topbar-btn {
    color: #94a3b8 !important;
}
body:not(.dark-theme) .topbar-btn:hover {
    color: #ffffff !important;
    background: rgba(255, 255, 255, 0.05) !important;
}

/* Navigation Header in Light Mode */
body:not(.dark-theme) .glass-nav {
    background: #ffffff !important;
    border-bottom: 1px solid #cbd5e1 !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.02) !important;
}

/* Headings in Light Mode */
body:not(.dark-theme) h1,
body:not(.dark-theme) h2,
body:not(.dark-theme) h3,
body:not(.dark-theme) h4 {
    color: #0f172a !important;
    letter-spacing: -0.5px !important;
}

/* Badge styles in Light Mode */
body:not(.dark-theme) .section-badge {
    background-color: #f1f5f9 !important;
    border: 1px solid #cbd5e1 !important;
    color: #0f172a !important;
}



/* ==========================================================================
   SECTION: DARK (CYBERPUNK GLASSMORPHISM) THEME OVERRIDES
   ========================================================================== */
/* Cyberpunk Playful 3D Button Overrides for Dark Mode */
body.dark-theme .btn-3d {
    background-color: #e5e7eb;
    color: #4b5563;
    box-shadow: 0 4px 0 #d1d5db, 0 8px 24px rgba(0,0,0,0.08);
    border: none;
    border-radius: var(--btn-radius);
    transition: all 0.12s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

body.dark-theme .btn-3d::after {
    display: block;
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s ease;
}

body.dark-theme .btn-3d:hover {
    transform: none;
    background-color: #e5e7eb;
    color: #4b5563;
    box-shadow: 0 4px 0 #d1d5db, 0 10px 28px rgba(0,0,0,0.1);
}

body.dark-theme .btn-3d:hover::after {
    left: 100%;
}

body.dark-theme .btn-3d:active {
    transform: translateY(4px);
    box-shadow: 0 0 0 transparent !important;
}

body.dark-theme .primary-3d-btn {
    background: linear-gradient(135deg, var(--accent-green), #16a34a) !important;
    color: #ffffff !important;
    border: none !important;
    box-shadow: 0 4px 0 var(--accent-green-shadow), 0 8px 24px var(--accent-green-glow) !important;
}

body.dark-theme .primary-3d-btn:hover {
    filter: brightness(1.1) !important;
    box-shadow: 0 4px 0 var(--accent-green-shadow), 0 12px 32px var(--accent-green-glow) !important;
}

body.dark-theme .secondary-3d-btn {
    background: linear-gradient(135deg, var(--accent-blue), #2563eb) !important;
    color: #ffffff !important;
    border: none !important;
    box-shadow: 0 4px 0 var(--accent-blue-shadow), 0 8px 24px var(--accent-blue-glow) !important;
}

body.dark-theme .secondary-3d-btn:hover {
    filter: brightness(1.1) !important;
    box-shadow: 0 4px 0 var(--accent-blue-shadow), 0 12px 32px var(--accent-blue-glow) !important;
}

body.dark-theme .orange-3d-btn {
    background: linear-gradient(135deg, var(--accent-orange), #ea580c) !important;
    color: #ffffff !important;
    border: none !important;
    box-shadow: 0 4px 0 var(--accent-orange-shadow) !important;
}

body.dark-theme .orange-3d-btn:hover {
    filter: brightness(1.1) !important;
}

/* ─────────────────────────────────────────────
   Checkout Drawer Payment Tab Selectors & Badges
   ───────────────────────────────────────────── */
.payment-method-selector {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    background: #f1f5f9;
    padding: 4px;
    border-radius: 10px;
    border: 1px solid #cbd5e1;
}
body.dark-theme .payment-method-selector {
    background: rgba(15, 23, 42, 0.45);
    border-color: rgba(255, 255, 255, 0.08);
}
.pay-method-tab {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px;
    font-size: 0.85rem;
    font-weight: 700;
    color: #475569;
    background: transparent;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}
body.dark-theme .pay-method-tab {
    color: #94a3b8;
}
.pay-method-tab.active {
    background: #ffffff;
    color: #0f172a;
    box-shadow: 0 2px 6px rgba(15,23,42,0.08);
}
body.dark-theme .pay-method-tab.active {
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
    box-shadow: none;
}
.pay-method-tab i {
    font-size: 1rem;
}

/* Trust Signals styling */
.checkout-trust-badge {
    text-align: center;
    font-size: 0.78rem;
    color: #64748b;
    margin: 8px 0 20px 0;
    font-weight: 600;
}
body.dark-theme .checkout-trust-badge {
    color: #94a3b8;
}

/* Wallet Carrier sniffer input adjustments */
.wallet-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}
.wallet-carrier-logo {
    position: absolute;
    inset-inline-end: 12px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    pointer-events: none;
    z-index: 5;
}
.wallet-badge {
    font-size: 0.7rem;
    font-weight: 800;
    padding: 4px 8px;
    border-radius: 6px;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    animation: fieldFadeIn 0.2s ease;
}
.badge-vodafone { background-color: #e60000 !important; }
.badge-orange { background-color: #ff6600 !important; }
.badge-etisalat { background-color: #789904 !important; }
.badge-we { background-color: #5c2d91 !important; }

/* Dynamic fields toggle animation */
.pay-fields-group {
    animation: fieldFadeIn 0.25s ease-out;
}
@keyframes fieldFadeIn {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}
.field-desc {
    font-size: 0.75rem;
    color: #64748b;
    margin-top: 4px;
}
body.dark-theme .field-desc {
    color: #94a3b8;
}

/* Hide all browser-native video player controls and overlays (Safari/Chrome/iOS) */
.hero-bg-video::-webkit-media-controls,
.hero-bg-video::-webkit-media-controls-panel,
.hero-bg-video::-webkit-media-controls-play-button,
.hero-bg-video::-webkit-media-controls-start-playback-button,
.hero-bg-video::-webkit-media-controls-volume-slider,
.hero-bg-video::-webkit-media-controls-mute-button,
.hero-bg-video::-webkit-media-controls-timeline,
.hero-bg-video::-webkit-media-controls-current-time-display,
.hero-bg-video::-webkit-media-controls-time-remaining-display,
.hero-bg-video::-webkit-media-controls-seek-back-button,
.hero-bg-video::-webkit-media-controls-seek-forward-button,
.hero-bg-video::-webkit-media-controls-fullscreen-button,
.hero-bg-video::-webkit-media-controls-rewind-button,
.hero-bg-video::-webkit-media-controls-return-to-realtime-button,
.hero-bg-video::-webkit-media-controls-toggle-closed-captions-button {
    display: none !important;
    -webkit-appearance: none !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

/* ==========================================================================
   SECTION: PREVENT FOUC (FLASH OF UNTRANSLATED CONTENT)
   ========================================================================== */
body:not(.rtl-layout) .lang-ar {
    display: none !important;
}
body:not(.rtl-layout) .lang-en {
    /* Flow naturally */
}

body.rtl-layout .lang-en {
    display: none !important;
}
body.rtl-layout .lang-ar {
    display: inline-block !important;
}

/* ==========================================================================
   SECTION: CUSTOM AESTHETIC ENHANCEMENTS & BRANDING INTEGRATION
   ========================================================================== */

/* 1. Header Platform Branding Link & Typography */
.nav-logo {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
}
.logo-platform-name-link {
    text-decoration: none !important;
    display: flex;
    align-items: center;
}
.logo-platform-name {
    font-size: 1.25rem;
    font-weight: 850;
    color: var(--text-color);
    letter-spacing: -0.5px;
    white-space: nowrap;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    transition: opacity 0.2s ease;
}
.logo-platform-name-link:hover .logo-platform-name {
    opacity: 0.8;
}

/* 2. Smart Wallet UI & Input Glows */
.wallet-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}
.wallet-carrier-logo {
    position: absolute;
    inset-inline-end: 12px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    pointer-events: none;
    z-index: 5;
}
.wallet-svg-logo {
    height: 24px;
    width: auto;
    animation: bounceInLogo 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) both;
}

@keyframes bounceInLogo {
    0% { transform: scale(0.3); opacity: 0; }
    50% { transform: scale(1.15); }
    75% { transform: scale(0.92); }
    100% { transform: scale(1); opacity: 1; }
}

/* Smart Wallet Sniffer glow classes */
.form-input.glow-vodafone {
    border-color: #e60000 !important;
    box-shadow: 0 0 10px rgba(230, 0, 0, 0.35) !important;
}
.form-input.glow-etisalat {
    border-color: #789904 !important;
    box-shadow: 0 0 10px rgba(120, 153, 4, 0.35) !important;
}
.form-input.glow-orange {
    border-color: #ff6600 !important;
    box-shadow: 0 0 10px rgba(255, 102, 0, 0.35) !important;
}
.form-input.glow-we {
    border-color: #5c2d91 !important;
    box-shadow: 0 0 10px rgba(92, 45, 145, 0.35) !important;
}

/* 3. Muscle Radar Variable Transitions */
body {
    transition: background-color 0.3s ease, color 0.3s ease, --radar-bg 0.3s ease, --radar-glow 0.3s ease;
}
.radar-handle-btn {
    transition: transform 0.2s ease, background-color 0.3s ease, box-shadow 0.3s ease !important;
}
.pulse-ring {
    transition: border-color 0.3s ease !important;
}

/* Restore clean Radar widget default positioning */
.muscle-radar-wrapper {
    bottom: 30px !important;
}
body.rtl-layout .muscle-radar-wrapper {
    bottom: 30px !important;
}

/* Skeleton Screens for Loading States */
.skeleton-loader {
    background: linear-gradient(90deg, rgba(255,255,255,0.05) 25%, rgba(255,255,255,0.12) 37%, rgba(255,255,255,0.05) 63%);
    background-size: 400% 100%;
    animation: skeleton-glow 1.4s ease infinite;
    border-radius: 12px;
    height: 18px;
    margin-bottom: 12px;
}
.skeleton-circle {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    margin: 0 auto 15px auto;
}
.skeleton-card {
    padding: 24px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
}
@keyframes skeleton-glow {
    0% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}




