/* ============================================================
   KENI METHOD — Premium TikTok Video Quality Platform
   Design System & Core Styles
   ============================================================ */

/* ---------- CSS Variables ---------- */
:root {
    --bg-primary: #07070d;
    --bg-secondary: #0d0d16;
    --bg-card: #111119;
    --bg-card-hover: #16161f;
    --bg-elevated: #1a1a24;
    --bg-input: #0f0f18;

    --accent-purple: #a855f7;
    --accent-purple-dim: rgba(168, 85, 247, 0.15);
    --accent-purple-glow: rgba(168, 85, 247, 0.4);
    --accent-cyan: #06b6d4;
    --accent-cyan-dim: rgba(6, 182, 212, 0.15);
    --accent-rose: #f43f5e;
    --accent-rose-dim: rgba(244, 63, 94, 0.15);
    --accent-green: #22c55e;
    --accent-green-dim: rgba(34, 197, 94, 0.15);

    --text-primary: #e8eaf0;
    --text-secondary: #8b8fa3;
    --text-muted: #555770;

    --border-color: rgba(255, 255, 255, 0.06);
    --border-hover: rgba(168, 85, 247, 0.25);

    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 14px;
    --radius-xl: 20px;

    --shadow-glow: 0 0 30px rgba(168, 85, 247, 0.12);
    --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.3);

    --font-main: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-display: 'Rajdhani', 'Inter', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;

    --nav-height: 56px;
    --sidebar-width: 240px;
    --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    font-size: 15px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-main);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { cursor: pointer; border: none; background: none; font: inherit; color: inherit; }
input, select, textarea { font: inherit; color: inherit; }

/* Custom Scrollbar */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-primary); }
::-webkit-scrollbar-thumb { background: rgba(168, 85, 247, 0.3); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(168, 85, 247, 0.5); }

/* ---------- Preloader ---------- */
#preloader {
    position: fixed; inset: 0; z-index: 9999;
    background: var(--bg-primary);
    display: flex; align-items: center; justify-content: center;
    transition: opacity 0.5s, visibility 0.5s;
}
#preloader.hidden { opacity: 0; visibility: hidden; pointer-events: none; }

.preloader-inner { text-align: center; }
.preloader-logo {
    font-family: var(--font-display);
    font-weight: 700; font-size: 2.4rem;
    margin-bottom: 20px;
}
.logo-k { color: var(--accent-purple); }
.logo-m { color: var(--accent-cyan); }

.preloader-bar {
    width: 160px; height: 3px;
    background: rgba(255,255,255,0.06);
    border-radius: 2px; overflow: hidden;
}
.preloader-fill {
    width: 0%; height: 100%;
    background: linear-gradient(90deg, var(--accent-purple), var(--accent-cyan));
    border-radius: 2px;
    animation: preloaderFill 1.2s ease forwards;
}
@keyframes preloaderFill { to { width: 100%; } }

/* ---------- Background Effects ---------- */
.bg-grid {
    position: fixed; inset: 0; z-index: 0; pointer-events: none;
    background-image:
        linear-gradient(rgba(168,85,247,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(168,85,247,0.03) 1px, transparent 1px);
    background-size: 60px 60px;
}

#particles-canvas {
    position: fixed; inset: 0; z-index: 0; pointer-events: none;
}

/* ---------- Navigation ---------- */
.navbar {
    position: fixed; top: 0; left: 0; right: 0;
    height: var(--nav-height);
    z-index: 1000;
    background: rgba(7, 7, 13, 0.75);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
    transition: background var(--transition), box-shadow var(--transition);
}
.navbar.scrolled {
    background: rgba(7, 7, 13, 0.92);
    box-shadow: 0 2px 20px rgba(0,0,0,0.3);
}

.nav-inner {
    max-width: 1200px; margin: 0 auto;
    height: 100%;
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 24px;
}

.nav-logo {
    display: flex; align-items: center; gap: 8px;
    text-decoration: none; flex-shrink: 0;
}
.logo-icon {
    width: 32px; height: 32px;
    display: flex; align-items: center; justify-content: center;
    background: transparent;
    border-radius: var(--radius-sm);
    border: none;
}
.logo-text {
    font-family: var(--font-display);
    font-weight: 700; font-size: 1.15rem;
    letter-spacing: 1px;
}
.logo-accent { color: var(--accent-purple); }

.nav-links {
    display: flex; gap: 4px;
}
.nav-link {
    padding: 6px 14px;
    font-size: 0.85rem; font-weight: 500;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    transition: color var(--transition), background var(--transition);
}
.nav-link:hover, .nav-link.active {
    color: var(--text-primary);
    background: rgba(255,255,255,0.04);
}
.nav-link.active { color: var(--accent-purple); }

.nav-actions { display: flex; align-items: center; gap: 10px; }

/* Language Selector */
.lang-selector {
    display: inline-flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 2px 4px;
    gap: 2px;
}
.lang-btn {
    padding: 3px 8px;
    font-size: 0.72rem;
    font-family: var(--font-mono);
    font-weight: 600;
    color: var(--text-muted);
    border-radius: 4px;
    transition: all var(--transition);
}
.lang-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}
.lang-btn.active {
    color: #fff;
    background: var(--accent-purple);
    box-shadow: 0 0 10px rgba(168, 85, 247, 0.4);
}
.lang-divider {
    width: 1px;
    height: 12px;
    background: var(--border-color);
}

.mobile-lang-picker {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 12px;
}
.mobile-lang-picker .lang-btn {
    padding: 6px 16px;
    font-size: 0.9rem;
}

/* Mobile Toggle */
.mobile-toggle {
    display: none;
    flex-direction: column; gap: 4px;
    width: 24px; padding: 4px 0;
}
.mobile-toggle span {
    display: block; height: 2px; width: 100%;
    background: var(--text-secondary);
    border-radius: 1px;
    transition: transform var(--transition), opacity var(--transition);
}
.mobile-toggle.active span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.mobile-toggle.active span:nth-child(2) { opacity: 0; }
.mobile-toggle.active span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* Mobile Menu */
.mobile-menu {
    position: fixed; inset: 0; z-index: 999;
    background: rgba(7,7,13,0.95);
    backdrop-filter: blur(20px);
    display: flex; align-items: center; justify-content: center;
    opacity: 0; visibility: hidden; pointer-events: none;
    transition: opacity 0.3s, visibility 0.3s;
}
.mobile-menu.active { opacity: 1; visibility: visible; pointer-events: auto; }

.mobile-menu-inner { text-align: center; }
.mobile-link {
    display: block; padding: 12px 24px;
    font-size: 1.3rem; font-weight: 600;
    color: var(--text-secondary);
    transition: color var(--transition);
}
.mobile-link:hover, .mobile-link.accent { color: var(--accent-purple); }
.mobile-divider { height: 1px; background: var(--border-color); margin: 12px 0; }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 8px 20px;
    font-size: 0.85rem; font-weight: 600;
    border-radius: var(--radius-md);
    transition: all var(--transition);
    white-space: nowrap;
    position: relative; overflow: hidden;
}

.btn-sm { padding: 6px 14px; font-size: 0.8rem; }
.btn-lg { padding: 12px 28px; font-size: 0.9rem; }
.btn-full { width: 100%; justify-content: center; }

.btn-primary {
    background: linear-gradient(135deg, var(--accent-purple), #7c3aed);
    color: #fff;
    border: 1px solid rgba(168,85,247,0.3);
    box-shadow: 0 2px 12px rgba(168,85,247,0.25);
}
.btn-primary:hover {
    box-shadow: 0 4px 20px rgba(168,85,247,0.4);
    transform: translateY(-1px);
}
.btn-primary:active { transform: translateY(0); }

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border-hover);
}
.btn-outline:hover {
    background: var(--accent-purple-dim);
    border-color: var(--accent-purple);
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}
.btn-ghost:hover {
    color: var(--text-primary);
    border-color: var(--border-hover);
    background: rgba(255,255,255,0.03);
}

.btn-social {
    width: 100%; justify-content: center;
    padding: 10px 20px;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.85rem; font-weight: 500;
    color: var(--text-secondary);
}
.btn-social:hover {
    background: rgba(255,255,255,0.06);
    border-color: var(--border-hover);
    color: var(--text-primary);
}

/* ---------- Page System ---------- */
.page {
    display: none; min-height: 100vh;
    position: relative; z-index: 1;
}
.page.active { display: block; animation: pageIn 0.4s ease; }
@keyframes pageIn {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ---------- Container ---------- */
.container { max-width: 1100px; margin: 0 auto; padding: 0 24px; }
.container-narrow { max-width: 680px; margin: 0 auto; padding: 0 24px; }

/* ---------- Section (Compact & Balanced Spacing) ---------- */
.section { padding: 34px 0; }
.section-header { text-align: center; margin-bottom: 22px; }
.section-header.compact { margin-bottom: 18px; }
.section-tag {
    display: inline-block; padding: 3px 12px;
    font-size: 0.7rem; font-weight: 600;
    text-transform: uppercase; letter-spacing: 1.5px;
    color: var(--accent-purple);
    background: var(--accent-purple-dim);
    border: 1px solid rgba(168,85,247,0.15);
    border-radius: 20px; margin-bottom: 8px;
}
.section-title {
    font-family: var(--font-display);
    font-size: 1.85rem; font-weight: 700;
    line-height: 1.2;
}
.section-desc {
    color: var(--text-secondary);
    font-size: 0.88rem;
    margin-top: 6px;
}
.gradient-text {
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ============================================================
   HERO SECTION (Compact & No Excessive Scroll)
   ============================================================ */
.hero {
    padding-top: calc(var(--nav-height) + 20px);
    padding-bottom: 24px;
    display: flex; align-items: center; justify-content: center;
    min-height: auto;
    max-width: 1200px; margin: 0 auto;
    padding-left: 24px; padding-right: 24px;
    gap: 36px;
}

.hero-content { flex: 1; max-width: 560px; }

.hero-badge {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 4px 12px;
    font-size: 0.7rem; font-weight: 500;
    color: var(--accent-cyan);
    background: var(--accent-cyan-dim);
    border: 1px solid rgba(6,182,212,0.15);
    border-radius: 20px; margin-bottom: 12px;
}
.badge-dot {
    width: 6px; height: 6px;
    background: var(--accent-cyan);
    border-radius: 50%;
    animation: pulse 2s infinite;
}
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

.hero-title {
    font-family: var(--font-display);
    font-size: 2.5rem; font-weight: 800;
    line-height: 1.1;
    margin-bottom: 10px;
}
.hero-desc {
    font-size: 0.92rem;
    color: var(--text-secondary);
    line-height: 1.55;
    margin-bottom: 18px;
    max-width: 480px;
}
.hero-actions {
    display: flex; gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

/* Hero Technical Value Propositions (Replaces unverified statistics) */
.hero-val-props {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 8px;
}
.val-prop-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    transition: all var(--transition);
}
.val-prop-card:hover {
    border-color: var(--border-hover);
    background: rgba(168, 85, 247, 0.04);
}
.val-prop-icon {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    background: var(--accent-purple-dim);
    color: var(--accent-purple);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.val-prop-icon.cyan {
    background: var(--accent-cyan-dim);
    color: var(--accent-cyan);
}
.val-prop-icon.green {
    background: var(--accent-green-dim);
    color: var(--accent-green);
}
.val-prop-text {
    display: flex;
    flex-direction: column;
}
.val-prop-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text-primary);
}
.val-prop-desc {
    font-size: 0.72rem;
    color: var(--text-muted);
}

/* Hero Visual — Phone Mockup */
.hero-visual {
    flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
}
.phone-mockup { position: relative; }
.phone-frame {
    width: 220px; height: 440px;
    background: #0a0a12;
    border-radius: 28px;
    border: 2px solid rgba(168,85,247,0.2);
    overflow: hidden;
    position: relative;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 40px rgba(168,85,247,0.1);
}
.phone-notch {
    position: absolute; top: 0; left: 50%;
    transform: translateX(-50%);
    width: 100px; height: 20px;
    background: #0a0a12;
    border-radius: 0 0 14px 14px;
    z-index: 2;
}
.phone-screen { width: 100%; height: 100%; position: relative; }

.mock-video {
    width: 100%; height: 100%;
    background: linear-gradient(180deg, #1a0a2e 0%, #0a1628 50%, #071018 100%);
    position: relative;
    overflow: hidden;
}
.mock-video-element {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}
.mock-video-gradient {
    position: absolute; bottom: 0; left: 0; right: 0;
    height: 50%;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    z-index: 2;
}
.mock-quality-badge {
    position: absolute; top: 28px; right: 10px;
    padding: 2px 8px;
    font-size: 0.6rem; font-weight: 700;
    background: rgba(168,85,247,0.85);
    backdrop-filter: blur(4px);
    color: white;
    border-radius: 4px;
    letter-spacing: 0.5px;
    z-index: 3;
}
.mock-ui-bottom {
    position: absolute; bottom: 12px; left: 10px; right: 10px;
    z-index: 3;
}
.mock-actions {
    display: flex; flex-direction: column; gap: 10px;
    position: absolute; right: 0; bottom: 40px;
    align-items: center;
}
.mock-action-btn {
    width: 32px; height: 32px;
    display: flex; align-items: center; justify-content: center;
    opacity: 0.8;
}
.mock-user-info { display: flex; align-items: center; gap: 6px; }
.mock-avatar {
    width: 24px; height: 24px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-cyan));
    border: 1.5px solid white;
}
.mock-username {
    font-size: 0.65rem; font-weight: 600;
    color: white;
}

.phone-glow {
    position: absolute; inset: -20px;
    background: radial-gradient(ellipse, rgba(168,85,247,0.12) 0%, transparent 70%);
    z-index: -1;
    animation: glowPulse 4s ease-in-out infinite;
}
@keyframes glowPulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

/* ============================================================
   FEATURES SECTION
   ============================================================ */
.features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}
.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px 20px;
    transition: all var(--transition);
    position: relative;
    overflow: hidden;
}
.feature-card::before {
    content: '';
    position: absolute; top: 0; left: 0; right: 0; height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent-purple), transparent);
    opacity: 0;
    transition: opacity var(--transition);
}
.feature-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-3px);
    box-shadow: var(--shadow-glow);
}
.feature-card:hover::before { opacity: 1; }

.feature-icon {
    width: 40px; height: 40px;
    display: flex; align-items: center; justify-content: center;
    background: var(--accent-purple-dim);
    border-radius: var(--radius-md);
    color: var(--accent-purple);
    margin-bottom: 14px;
}
.feature-icon.icon-cyan { background: var(--accent-cyan-dim); color: var(--accent-cyan); }
.feature-icon.icon-rose { background: var(--accent-rose-dim); color: var(--accent-rose); }
.feature-icon.icon-green { background: var(--accent-green-dim); color: var(--accent-green); }

.feature-card h3 {
    font-size: 0.95rem; font-weight: 600;
    margin-bottom: 6px;
}
.feature-card p {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* ============================================================
   HOW IT WORKS
   ============================================================ */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
.step-card {
    text-align: center; padding: 18px 16px;
    position: relative;
}
.step-number {
    font-family: var(--font-display);
    font-size: 2.2rem; font-weight: 700;
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 8px;
}
.step-content h3 {
    font-size: 0.95rem; font-weight: 600;
    margin-bottom: 4px;
}
.step-content p {
    font-size: 0.8rem;
    color: var(--text-secondary);
}
.step-line {
    position: absolute; top: 38px; right: -16px;
    width: 32px; height: 2px;
    background: linear-gradient(90deg, var(--accent-purple), transparent);
}
.step-card:last-child .step-line { display: none; }

/* ============================================================
   CTA SECTION (Compact)
   ============================================================ */
.cta-section { padding: 24px 0 32px; }
.cta-card {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 32px 24px; text-align: center;
    overflow: hidden;
}
.cta-glow {
    position: absolute; top: -50%; left: 50%; transform: translateX(-50%);
    width: 400px; height: 400px;
    background: radial-gradient(ellipse, rgba(168,85,247,0.08), transparent 70%);
    pointer-events: none;
}
.cta-card h2 {
    font-family: var(--font-display);
    font-size: 1.8rem; font-weight: 700;
    margin-bottom: 10px;
    position: relative;
}
.cta-card p {
    color: var(--text-secondary);
    margin-bottom: 20px;
    position: relative;
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
    border-top: 1px solid var(--border-color);
    padding: 40px 0 20px;
}
.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 32px;
    margin-bottom: 32px;
}
.footer-desc {
    color: var(--text-secondary);
    font-size: 0.8rem;
    margin-top: 10px;
}
.footer-col h4 {
    font-size: 0.8rem; font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
    color: var(--text-secondary);
}
.footer-col a {
    display: block; padding: 3px 0;
    font-size: 0.82rem;
    color: var(--text-muted);
    transition: color var(--transition);
}
.footer-col a:hover { color: var(--accent-purple); }

.footer-bottom {
    display: flex; align-items: center; justify-content: space-between;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
    font-size: 0.75rem; color: var(--text-muted);
}
.footer-socials { display: flex; gap: 12px; }
.footer-socials a {
    color: var(--text-muted);
    transition: color var(--transition);
}
.footer-socials a:hover { color: var(--accent-purple); }

/* ============================================================
   AUTH PAGES (Login / Register)
   ============================================================ */
.auth-section {
    min-height: 100vh;
    display: flex; align-items: center; justify-content: center;
    padding: 80px 24px 40px;
}
.auth-card {
    width: 100%; max-width: 400px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 32px;
}
.auth-header { text-align: center; margin-bottom: 24px; }
.auth-logo { margin-bottom: 14px; }
.auth-header h2 {
    font-family: var(--font-display);
    font-size: 1.5rem; font-weight: 700;
}
.auth-header p {
    font-size: 0.82rem;
    color: var(--text-secondary);
    margin-top: 4px;
}

.auth-form { display: flex; flex-direction: column; gap: 14px; }

.form-group { display: flex; flex-direction: column; gap: 4px; }
.form-group label {
    font-size: 0.78rem; font-weight: 500;
    color: var(--text-secondary);
}

.input-wrapper {
    display: flex; align-items: center; gap: 10px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 0 12px;
    transition: border-color var(--transition), box-shadow var(--transition);
}
.input-wrapper:focus-within {
    border-color: var(--accent-purple);
    box-shadow: 0 0 0 3px var(--accent-purple-dim);
}
.input-wrapper svg { flex-shrink: 0; color: var(--text-muted); }
.input-wrapper input {
    flex: 1; padding: 10px 0;
    background: none; border: none; outline: none;
    font-size: 0.85rem;
}
.input-wrapper input::placeholder { color: var(--text-muted); }

.toggle-pass {
    padding: 4px; opacity: 0.5;
    transition: opacity var(--transition);
}
.toggle-pass:hover { opacity: 1; }

.form-row {
    display: flex; align-items: center; justify-content: space-between;
    font-size: 0.78rem;
}
.form-link { color: var(--accent-purple); }
.form-link:hover { text-decoration: underline; }

.checkbox-label {
    display: flex; align-items: center; gap: 8px;
    font-size: 0.78rem; color: var(--text-secondary);
    cursor: pointer;
}
.checkbox-label input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 17px; height: 17px;
    background: rgba(18, 18, 32, 0.85);
    border: 1px solid rgba(168, 85, 247, 0.35);
    border-radius: 4px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
    transition: all 0.2s ease;
    position: relative;
    outline: none;
    flex-shrink: 0;
}
.checkbox-label input[type="checkbox"]:hover {
    border-color: var(--accent-purple);
    box-shadow: 0 0 8px rgba(168, 85, 247, 0.25);
}
.checkbox-label input[type="checkbox"]:checked {
    background: var(--accent-purple);
    border-color: var(--accent-purple);
    box-shadow: 0 0 10px rgba(168, 85, 247, 0.5);
}
.checkbox-label input[type="checkbox"]:checked::after {
    content: '';
    display: block;
    width: 4px;
    height: 8px;
    border: solid #ffffff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
    position: absolute;
    top: 2px;
    left: 5px;
}
.checkbox-label .checkmark { display: none; }
.checkbox-label a { color: var(--accent-purple); }

.auth-divider {
    display: flex; align-items: center; gap: 12px;
    color: var(--text-muted); font-size: 0.75rem;
}
.auth-divider::before, .auth-divider::after {
    content: ''; flex: 1; height: 1px;
    background: var(--border-color);
}

.auth-footer {
    text-align: center; margin-top: 18px;
    font-size: 0.82rem; color: var(--text-secondary);
}
.auth-footer a { color: var(--accent-purple); font-weight: 500; }
.auth-footer a:hover { text-decoration: underline; }

/* Password Strength */
.password-strength { margin-top: 4px; }
.strength-bar {
    width: 100%; height: 3px;
    background: rgba(255,255,255,0.06);
    border-radius: 2px; overflow: hidden;
}
.strength-fill {
    width: 0; height: 100%;
    border-radius: 2px;
    transition: width 0.3s, background 0.3s;
}
.strength-text { font-size: 0.7rem; color: var(--text-muted); }

/* ============================================================
   DASHBOARD
   ============================================================ */
.dashboard-layout {
    display: flex;
    min-height: 100vh;
    padding-top: var(--nav-height);
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-secondary);
    border-right: 1px solid var(--border-color);
    display: flex; flex-direction: column;
    position: fixed; top: var(--nav-height); bottom: 0; left: 0;
    z-index: 100;
    transition: transform 0.3s ease;
}

.sidebar-header {
    padding: 16px;
    border-bottom: 1px solid var(--border-color);
}
.user-info { display: flex; align-items: center; gap: 10px; }
.user-avatar {
    width: 36px; height: 36px;
    border-radius: var(--radius-sm);
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-cyan));
    display: flex; align-items: center; justify-content: center;
    font-size: 0.75rem; font-weight: 700; color: white;
}
.user-details { display: flex; flex-direction: column; }
.user-name { font-size: 0.82rem; font-weight: 600; }
.user-plan {
    font-size: 0.65rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: 1px;
}
.plan-pro { color: var(--accent-purple); }

.sidebar-nav {
    flex: 1; padding: 10px 8px;
    display: flex; flex-direction: column; gap: 2px;
}
.sidebar-link {
    display: flex; align-items: center; gap: 10px;
    padding: 9px 12px;
    font-size: 0.82rem; font-weight: 500;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    transition: all var(--transition);
}
.sidebar-link:hover {
    color: var(--text-primary);
    background: rgba(255,255,255,0.04);
}
.sidebar-link.active {
    color: var(--accent-purple);
    background: var(--accent-purple-dim);
}

.sidebar-footer { padding: 14px 16px; border-top: 1px solid var(--border-color); }
.usage-meter { }
.usage-header {
    display: flex; justify-content: space-between;
    font-size: 0.72rem; color: var(--text-secondary);
    margin-bottom: 6px;
}
.usage-count { font-weight: 600; color: var(--text-primary); }
.usage-bar {
    width: 100%; height: 4px;
    background: rgba(255,255,255,0.06);
    border-radius: 2px; overflow: hidden;
}
.usage-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-purple), var(--accent-cyan));
    border-radius: 2px;
    transition: width 0.5s ease;
}

/* Dashboard Content */
.dash-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    padding: 0 24px 24px;
}

.dash-topbar {
    display: flex; align-items: center; gap: 12px;
    padding: 16px 0;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 20px;
}
.dash-title {
    font-family: var(--font-display);
    font-size: 1.2rem; font-weight: 700;
    flex: 1;
}
.sidebar-toggle { display: none; }

.dash-topbar-actions {
    display: flex; gap: 8px;
}

/* Dashboard Tabs */
.dash-tab { display: none; }
.dash-tab.active { display: block; animation: pageIn 0.3s ease; }

/* Stat Cards Row */
.stats-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin-bottom: 20px;
}
.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 16px;
    display: flex; align-items: center; gap: 12px;
    transition: border-color var(--transition);
}
.stat-card:hover { border-color: var(--border-hover); }

.stat-card-icon {
    width: 38px; height: 38px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    border-radius: var(--radius-md);
}
.stat-card-icon.purple { background: var(--accent-purple-dim); color: var(--accent-purple); }
.stat-card-icon.cyan { background: var(--accent-cyan-dim); color: var(--accent-cyan); }
.stat-card-icon.green { background: var(--accent-green-dim); color: var(--accent-green); }
.stat-card-icon.rose { background: var(--accent-rose-dim); color: var(--accent-rose); }

.stat-card-info { flex: 1; min-width: 0; }
.stat-card-value {
    font-family: var(--font-display);
    font-size: 1.3rem; font-weight: 700;
    display: block;
}
.stat-card-label {
    font-size: 0.72rem; color: var(--text-muted);
    display: block;
}
.stat-card-change {
    font-size: 0.7rem; font-weight: 600; flex-shrink: 0;
}
.stat-card-change.up { color: var(--accent-green); }
.stat-card-change.down { color: var(--accent-rose); }

/* Panel */
.dash-panel {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
}
.panel-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 18px;
    border-bottom: 1px solid var(--border-color);
}
.panel-header h3 { font-size: 0.9rem; font-weight: 600; }
.panel-link {
    font-size: 0.78rem; color: var(--accent-purple);
    font-weight: 500;
}
.panel-filters { display: flex; gap: 8px; }
.select-mini {
    padding: 4px 10px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 0.78rem; color: var(--text-secondary);
    outline: none;
}

/* Video List */
.video-list { }
.video-item {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 18px;
    border-bottom: 1px solid var(--border-color);
    transition: background var(--transition);
}
.video-item:last-child { border-bottom: none; }
.video-item:hover { background: rgba(255,255,255,0.02); }

.video-thumb {
    width: 48px; height: 36px; flex-shrink: 0;
    background: linear-gradient(135deg, #1a0a2e, #0a1628);
    border-radius: var(--radius-sm);
    display: flex; align-items: center; justify-content: center;
}
.thumb-play {
    font-size: 0.6rem; color: white; opacity: 0.7;
}
.video-info { flex: 1; min-width: 0; }
.video-name {
    display: block; font-size: 0.82rem; font-weight: 500;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.video-meta {
    display: block; font-size: 0.72rem;
    color: var(--text-muted);
}
.video-status {
    font-size: 0.7rem; font-weight: 600;
    padding: 3px 10px;
    border-radius: 20px;
    flex-shrink: 0;
}
.video-status.done {
    background: var(--accent-green-dim);
    color: var(--accent-green);
}
.video-status.processing {
    background: var(--accent-cyan-dim);
    color: var(--accent-cyan);
    animation: pulse 2s infinite;
}
.video-quality {
    font-family: var(--font-mono);
    font-size: 0.78rem; font-weight: 600;
    color: var(--accent-purple);
    flex-shrink: 0; min-width: 32px; text-align: right;
}

/* TikTok Connect */
.tiktok-connect-area {
    text-align: center; padding: 40px 24px;
}
.tiktok-icon-large {
    width: 72px; height: 72px; margin: 0 auto 16px;
    display: flex; align-items: center; justify-content: center;
    background: rgba(255,255,255,0.04);
    border-radius: 50%;
    color: var(--text-muted);
}
.tiktok-connect-area h3 {
    font-size: 1.1rem; font-weight: 600;
    margin-bottom: 6px;
}
.tiktok-connect-area p {
    font-size: 0.82rem; color: var(--text-secondary);
    margin-bottom: 20px;
}
.tiktok-connected {
    margin-top: 24px;
    display: flex; flex-direction: column; align-items: center; gap: 14px;
}
.connected-badge {
    display: inline-flex; align-items: center; gap: 6px;
    font-size: 0.82rem; font-weight: 600;
    color: var(--accent-green);
}
.connected-account {
    display: flex; align-items: center; gap: 12px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 12px 16px; width: 100%; max-width: 380px;
}
.connected-avatar {
    width: 36px; height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-cyan));
    display: flex; align-items: center; justify-content: center;
    font-size: 0.7rem; font-weight: 700; color: white;
    flex-shrink: 0;
}
.connected-details { flex: 1; text-align: left; }
.connected-name {
    display: block; font-size: 0.85rem; font-weight: 600;
}
.connected-followers {
    display: block; font-size: 0.72rem; color: var(--text-muted);
}

/* Settings Form */
.settings-form { padding: 20px; }
.settings-section {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-color);
}
.settings-section:last-of-type { border-bottom: none; }
.settings-section h4 {
    font-size: 0.88rem; font-weight: 600;
    margin-bottom: 14px;
}
.form-row-2col {
    display: grid; grid-template-columns: 1fr 1fr;
    gap: 14px;
}
.select-full {
    width: 100%; padding: 10px 12px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.85rem; color: var(--text-primary);
    outline: none;
    transition: border-color var(--transition);
}
.select-full:focus { border-color: var(--accent-purple); }

.toggle-row {
    display: flex; align-items: center; justify-content: space-between;
    padding: 8px 0;
    font-size: 0.82rem; color: var(--text-secondary);
}

/* Toggle Switch */
.toggle {
    position: relative; display: inline-block;
    width: 40px; height: 22px;
}
.toggle input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
    position: absolute; inset: 0;
    background: rgba(255,255,255,0.1);
    border-radius: 11px;
    transition: background var(--transition);
    cursor: pointer;
}
.toggle-slider::before {
    content: '';
    position: absolute; left: 3px; top: 3px;
    width: 16px; height: 16px;
    background: white;
    border-radius: 50%;
    transition: transform var(--transition);
}
.toggle input:checked + .toggle-slider { background: var(--accent-purple); }
.toggle input:checked + .toggle-slider::before { transform: translateX(18px); }

/* ============================================================
   UPLOAD PAGE — Redesigned Pro Compact Panel (850px)
   ============================================================ */
.upload-section {
    padding-top: calc(var(--nav-height) + 16px);
    padding-bottom: 20px;
    min-height: calc(100vh - var(--nav-height));
    display: flex; align-items: center; justify-content: center;
}
.upload-container {
    width: 100%; max-width: 850px;
    padding: 0 20px;
    margin: 0 auto;
}

/* Header Area */
.optimizer-header {
    text-align: center;
    margin-bottom: 14px;
}
.optimizer-badge {
    display: inline-block;
    padding: 3px 12px;
    font-family: var(--font-mono);
    font-size: 0.68rem; font-weight: 600;
    color: var(--accent-purple);
    background: var(--accent-purple-dim);
    border: 1px solid rgba(168, 85, 247, 0.25);
    border-radius: 20px;
    letter-spacing: 1.5px;
    margin-bottom: 6px;
}
.optimizer-title {
    font-family: var(--font-display);
    font-size: 2.3rem; font-weight: 800;
    line-height: 1.1;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin: 0 0 6px 0;
}
.optimizer-subtitle {
    font-size: 0.85rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.45;
}

/* Panel */
.upload-panel {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    position: relative;
    overflow: hidden;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4), 0 0 40px rgba(168, 85, 247, 0.05);
}

/* Drop Zone */
.upload-dropzone {
    margin: 20px 24px 14px;
    border: 2px dashed rgba(168, 85, 247, 0.2);
    border-radius: var(--radius-lg);
    cursor: pointer;
    background: rgba(168, 85, 247, 0.015);
    transition: all var(--transition);
    position: relative;
}
.upload-dropzone:hover,
.upload-dropzone.dragover {
    border-color: var(--accent-purple);
    background: rgba(168, 85, 247, 0.05);
    box-shadow: inset 0 0 30px rgba(168, 85, 247, 0.08);
}
.upload-dropzone.has-file {
    border-style: solid;
    border-color: rgba(168, 85, 247, 0.25);
    background: rgba(168, 85, 247, 0.03);
}

.dropzone-inner {
    padding: 38px 24px;
    display: flex; flex-direction: column; align-items: center;
    text-align: center;
}

.dropzone-icon { margin-bottom: 12px; }
.dropzone-icon-ring {
    width: 68px; height: 68px;
    border-radius: 50%;
    border: 2px solid rgba(168, 85, 247, 0.2);
    background: rgba(168, 85, 247, 0.06);
    display: flex; align-items: center; justify-content: center;
    color: var(--accent-purple);
    transition: all var(--transition);
}
.upload-dropzone:hover .dropzone-icon-ring {
    border-color: var(--accent-purple);
    background: rgba(168, 85, 247, 0.12);
    box-shadow: 0 0 24px rgba(168, 85, 247, 0.35);
    transform: scale(1.04);
}

.dropzone-title {
    font-size: 1rem; font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 3px;
}
.dropzone-sub {
    font-size: 0.82rem; color: var(--text-secondary);
    margin-bottom: 14px;
}
.dropzone-browse {
    color: var(--accent-purple); font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.dropzone-formats {
    display: flex; align-items: center; gap: 8px;
}
.format-tag {
    font-size: 0.7rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.5px;
    padding: 3px 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    color: var(--text-secondary);
}
.format-sep {
    font-size: 0.72rem; color: var(--text-muted);
}
.format-limit {
    font-size: 0.72rem; color: var(--text-muted);
}

/* File Row */
.upload-file-row {
    display: flex; align-items: center; justify-content: space-between;
    margin: 0 24px 8px;
    padding: 10px 14px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
}
.file-row-left {
    display: flex; align-items: center; gap: 10px;
    flex: 1; min-width: 0;
}
.file-icon {
    width: 34px; height: 34px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    background: var(--accent-purple-dim);
    border-radius: var(--radius-sm);
    color: var(--accent-purple);
}
.file-details { min-width: 0; }
.file-name {
    display: block;
    font-size: 0.82rem; font-weight: 500;
    color: var(--text-primary);
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.file-size {
    display: block;
    font-size: 0.7rem; color: var(--text-muted);
    font-family: var(--font-mono);
}

.file-row-right {
    display: flex; align-items: center; gap: 10px;
    flex-shrink: 0;
}
.file-progress-text {
    font-family: var(--font-mono);
    font-size: 0.78rem; font-weight: 600;
    color: var(--accent-purple);
    min-width: 36px; text-align: right;
}
.file-remove {
    width: 28px; height: 28px;
    display: flex; align-items: center; justify-content: center;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    transition: all var(--transition);
}
.file-remove:hover {
    background: var(--accent-rose-dim);
    color: var(--accent-rose);
}

/* Progress Bar */
.upload-progress-bar {
    margin: 0 24px 12px;
}
.progress-track {
    width: 100%; height: 3px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 2px; overflow: hidden;
}
.progress-fill {
    width: 0; height: 100%;
    background: linear-gradient(90deg, var(--accent-purple), var(--accent-cyan));
    border-radius: 2px;
    transition: width 0.25s ease;
}

/* Action Area */
.upload-action-area {
    padding: 0 24px 16px;
}
.btn-optimize {
    display: flex; align-items: center; justify-content: center; gap: 10px;
    width: 100%;
    padding: 13px 24px;
    font-size: 0.92rem; font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, var(--accent-purple), #7c3aed);
    border: 1px solid rgba(168, 85, 247, 0.35);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition);
    box-shadow: 0 4px 16px rgba(168, 85, 247, 0.25);
    letter-spacing: 0.3px;
}
.btn-optimize:hover:not(:disabled) {
    box-shadow: 0 6px 24px rgba(168, 85, 247, 0.45);
    transform: translateY(-1px);
    border-color: rgba(168, 85, 247, 0.5);
}
.btn-optimize:active:not(:disabled) { transform: translateY(0); }
.btn-optimize:disabled {
    background: rgba(255, 255, 255, 0.04);
    border-color: var(--border-color);
    color: var(--text-muted);
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}
.btn-optimize:disabled svg { opacity: 0.4; }

/* Panel Footer: Quota & Status */
.upload-panel-footer {
    display: flex; align-items: center; justify-content: space-between;
    padding: 12px 24px;
    background: rgba(0, 0, 0, 0.25);
    border-top: 1px solid var(--border-color);
    font-size: 0.78rem;
}
.footer-quota {
    display: flex; align-items: center; gap: 8px;
    color: var(--text-secondary);
}
.quota-dot {
    width: 7px; height: 7px;
    border-radius: 50%;
    background: var(--accent-green);
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.5);
}
.quota-text { font-weight: 500; }
.quota-value {
    font-family: var(--font-mono);
    font-weight: 700;
    color: var(--text-primary);
}
.quota-badge {
    font-size: 0.62rem; font-weight: 700;
    letter-spacing: 0.8px;
    padding: 2px 7px;
    border-radius: 4px;
    background: var(--accent-purple-dim);
    color: var(--accent-purple);
    border: 1px solid rgba(168, 85, 247, 0.25);
}

.footer-engine-note {
    display: flex; align-items: center; gap: 6px;
    font-size: 0.72rem; color: var(--text-muted);
}
.footer-engine-note svg { color: var(--accent-purple); opacity: 0.7; }

/* Processing Overlay */
.upload-processing {
    position: absolute; inset: 0;
    background: rgba(7, 7, 13, 0.9);
    backdrop-filter: blur(8px);
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    gap: 14px; z-index: 10;
    border-radius: var(--radius-xl);
    animation: fadeIn 0.3s ease;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.processing-spinner { position: relative; }
.proc-spin {
    animation: procSpin 1.8s linear infinite;
    transform-origin: center;
}
@keyframes procSpin { to { transform: rotate(360deg); } }

.processing-label {
    font-size: 0.88rem; font-weight: 500;
    color: var(--text-secondary);
}

/* Mobile Adjustments for Optimizer */
@media (max-width: 768px) {
    .optimizer-title { font-size: 1.8rem; }
    .optimizer-subtitle { font-size: 0.78rem; }
    .upload-dropzone { margin: 16px 16px 12px; }
    .dropzone-inner { padding: 30px 16px; }
    .dropzone-icon-ring { width: 56px; height: 56px; }
    .upload-file-row { margin: 0 16px 8px; }
    .upload-progress-bar { margin: 0 16px 10px; }
    .upload-action-area { padding: 0 16px 14px; }
    .upload-panel-footer {
        padding: 10px 16px;
        flex-direction: column;
        gap: 6px;
        align-items: flex-start;
    }
}

/* ============================================================
   PRICING PAGE (RTX Fury inspired layout with Keni Purple aesthetic)
   ============================================================ */
.pricing-section {
    padding: calc(var(--nav-height) + 36px) 0 60px;
    min-height: 100vh;
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 32px;
    align-items: stretch;
}

.price-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 32px 26px;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all var(--transition);
}
.price-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}
.price-card.featured {
    border-color: var(--accent-purple);
    box-shadow: 0 0 36px rgba(168, 85, 247, 0.15), 0 12px 32px rgba(0, 0, 0, 0.4);
    background: linear-gradient(180deg, rgba(168, 85, 247, 0.05) 0%, var(--bg-card) 40%);
}
.price-card.premium {
    border-color: rgba(6, 182, 212, 0.35);
    background: linear-gradient(180deg, rgba(6, 182, 212, 0.05) 0%, var(--bg-card) 40%);
}
.price-card.premium:hover {
    border-color: var(--accent-cyan);
    box-shadow: 0 0 36px rgba(6, 182, 212, 0.15), 0 12px 32px rgba(0, 0, 0, 0.4);
}

.price-badge-top {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    padding: 3px 14px;
    font-size: 0.68rem;
    font-family: var(--font-mono);
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    background: linear-gradient(135deg, var(--accent-purple), #7c3aed);
    color: white;
    border-radius: 20px;
    white-space: nowrap;
    box-shadow: 0 2px 10px rgba(168, 85, 247, 0.4);
}
.price-badge-top.cyan {
    background: linear-gradient(135deg, var(--accent-cyan), #0284c7);
    box-shadow: 0 2px 10px rgba(6, 182, 212, 0.4);
}
.price-badge-top.current-plan-badge {
    background: linear-gradient(135deg, #10b981, #06b6d4) !important;
    box-shadow: 0 2px 12px rgba(16, 185, 129, 0.45) !important;
}
.price-card.is-current-plan {
    border-color: rgba(16, 185, 129, 0.5) !important;
    background: linear-gradient(180deg, rgba(16, 185, 129, 0.08) 0%, var(--bg-card) 40%) !important;
    box-shadow: 0 0 25px rgba(16, 185, 129, 0.15) !important;
}
.btn.btn-current-plan {
    background: rgba(16, 185, 129, 0.18) !important;
    color: #34d399 !important;
    border: 1px solid rgba(16, 185, 129, 0.4) !important;
    cursor: default !important;
    opacity: 0.95;
}

.price-header {
    text-align: center;
    margin-bottom: 24px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}
.price-name {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    display: block;
    margin-bottom: 10px;
}
.price-amount {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 4px;
}
.price-value {
    font-family: var(--font-display);
    font-size: 2.8rem;
    font-weight: 800;
    color: var(--text-primary);
}
.price-period {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-family: var(--font-mono);
}

.price-features {
    list-style: none;
    margin-bottom: 28px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.price-features li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}
.price-features li svg {
    flex-shrink: 0;
}
.price-features li.included {
    color: var(--text-primary);
}
.price-features li.excluded {
    color: var(--text-muted);
    opacity: 0.6;
}

/* Dashboard Badges & Empty State */
.plan-badge-free {
    color: var(--text-muted);
}
.plan-badge-pro {
    color: var(--accent-purple);
}
.plan-badge-premium {
    color: var(--accent-cyan);
}

.dash-empty-state {
    padding: 48px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 12px;
    color: var(--text-muted);
}
.dash-empty-state svg {
    opacity: 0.4;
}
.dash-empty-state p {
    font-size: 0.85rem;
}

/* ============================================================
   TOAST NOTIFICATIONS
   ============================================================ */
.toast-container {
    position: fixed; bottom: 20px; right: 20px;
    z-index: 10000;
    display: flex; flex-direction: column; gap: 8px;
}
.toast {
    display: flex; align-items: center; gap: 10px;
    padding: 12px 18px;
    background: var(--bg-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.82rem;
    animation: toastIn 0.3s ease;
    box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}
.toast.success { border-left: 3px solid var(--accent-green); }
.toast.error { border-left: 3px solid var(--accent-rose); }
.toast.info { border-left: 3px solid var(--accent-cyan); }

@keyframes toastIn {
    from { opacity: 0; transform: translateX(20px); }
    to { opacity: 1; transform: translateX(0); }
}

/* ---------- Utility ---------- */
.hidden { display: none !important; }
.desktop-only-text { display: block; }
.mobile-only-text { display: none !important; }

/* User Profile Popover / Dropdown (RTX Fury Style Compact) */
.profile-popover {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 220px;
    background: rgba(13, 12, 24, 0.97);
    border: 1px solid rgba(168, 85, 247, 0.3);
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.65), 0 0 20px rgba(168, 85, 247, 0.15);
    backdrop-filter: blur(16px);
    z-index: 1050;
    padding: 8px;
    animation: popoverFadeIn 0.18s ease-out;
}
@keyframes popoverFadeIn {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: translateY(0); }
}
.profile-popover-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    margin-bottom: 6px;
}
.popover-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, #a855f7, #6366f1);
    color: #fff;
    font-size: 0.8rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.popover-user-meta {
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.popover-username {
    font-size: 13px;
    font-weight: 700;
    color: #f1f5f9;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.popover-plan-badge {
    font-size: 10px;
    font-weight: 700;
    color: #c084fc;
    letter-spacing: 0.5px;
}
.profile-popover-menu {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.popover-item {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 7px 10px;
    border-radius: 8px;
    color: #cbd5e1;
    font-size: 12.5px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.15s ease;
}
.popover-item svg {
    color: #94a3b8;
    flex-shrink: 0;
    transition: color 0.15s ease;
}
.popover-item:hover {
    background: rgba(168, 85, 247, 0.14);
    color: #fff;
}
.popover-item:hover svg {
    color: #a855f7;
}
.popover-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.08);
    margin: 4px 0;
}
.popover-logout {
    color: #f87171 !important;
}
.popover-logout svg {
    color: #f87171 !important;
}
.popover-logout:hover {
    background: rgba(239, 68, 68, 0.15) !important;
    color: #fca5a5 !important;
}

/* ============================================================
   RTX FURY STYLE LIVE TELEMETRY & BOTTOM NAVIGATION BASE (DESKTOP)
   ============================================================ */
.hero-live-stats {
    display: flex;
    gap: 12px;
    margin-top: 24px;
    margin-bottom: 24px;
}
.hero-live-stats .live-stat-card {
    background: rgba(14, 13, 26, 0.7);
    border: 1px solid rgba(168, 85, 247, 0.2);
    border-radius: 12px;
    padding: 12px 16px;
    min-width: 130px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(10px);
}
.live-stat-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
}
.live-stat-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
}
.purple-pulse {
    background: #a855f7;
    box-shadow: 0 0 8px #a855f7;
}
.cyan-pulse {
    background: #06b6d4;
    box-shadow: 0 0 8px #06b6d4;
}
.green-pulse {
    background: #22c55e;
    box-shadow: 0 0 8px #22c55e;
}
.amber-pulse {
    background: #f59e0b;
    box-shadow: 0 0 8px #f59e0b;
}
.live-stat-label {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 0.5px;
}
.live-stat-value {
    font-size: 1.15rem;
    font-weight: 800;
    color: #fff;
    font-family: var(--font-mono);
    line-height: 1.2;
}
.live-stat-sub {
    font-size: 0.7rem;
    color: #64748b;
    margin-top: 2px;
}

/* Bottom Nav hidden on Desktop */
.bottom-nav {
    display: none;
}

/* ============================================================
   RESPONSIVE: TABLET & MOBILE (RTX FURY COMPACT APP ARCHITECTURE)
   ============================================================ */
@media (max-width: 991px) {
    /* Global Viewport & Flow Guard */
    html {
        font-size: 13.5px;
        -webkit-text-size-adjust: 100%;
    }
    body {
        max-width: 100vw;
        overflow-x: hidden !important;
        padding-bottom: calc(64px + env(safe-area-inset-bottom, 0px)) !important;
    }
    .page {
        max-width: 100vw;
        overflow-x: hidden;
        padding-bottom: 24px;
    }
    .container {
        padding-left: 14px;
        padding-right: 14px;
        max-width: 100%;
        box-sizing: border-box;
    }

    /* Fixed Bottom Navigation Bar (RTX Fury Mobile App Style) */
    .bottom-nav {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        height: 56px;
        background: rgba(9, 9, 18, 0.94);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border-top: 1px solid rgba(168, 85, 247, 0.22);
        box-shadow: 0 -4px 25px rgba(0, 0, 0, 0.65), 0 -1px 0 rgba(255, 255, 255, 0.04);
        z-index: 9999;
        align-items: center;
        justify-content: space-around;
        padding: 0 4px;
        padding-bottom: env(safe-area-inset-bottom, 0px);
    }
    .bottom-nav-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 3px;
        flex: 1;
        height: 100%;
        color: #94a3b8;
        text-decoration: none;
        position: relative;
        transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
        -webkit-tap-highlight-color: transparent;
    }
    .bottom-nav-item .bottom-nav-icon {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 32px;
        height: 24px;
        border-radius: 8px;
        transition: all 0.2s ease;
    }
    .bottom-nav-item .bottom-nav-icon svg {
        width: 18px;
        height: 18px;
        transition: transform 0.2s;
    }
    .bottom-nav-item .bottom-nav-label {
        font-size: 10.5px;
        font-weight: 600;
        letter-spacing: 0.1px;
        line-height: 1;
        transition: color 0.2s;
    }
    .bottom-nav-item.active {
        color: #c084fc;
    }
    .bottom-nav-item.active .bottom-nav-icon {
        background: rgba(168, 85, 247, 0.16);
        color: #c084fc;
        box-shadow: 0 0 14px rgba(168, 85, 247, 0.4);
    }
    .bottom-nav-item.active .bottom-nav-icon svg {
        transform: translateY(-1px);
    }
    .bottom-nav-item.active::before {
        content: '';
        position: absolute;
        top: 0;
        left: 50%;
        transform: translateX(-50%);
        width: 24px;
        height: 2.5px;
        background: linear-gradient(90deg, #a855f7, #06b6d4);
        border-radius: 0 0 3px 3px;
        box-shadow: 0 0 8px #a855f7;
    }

    /* Compact Top Header */
    .navbar {
        height: 52px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
        background: rgba(8, 8, 15, 0.92);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
    }
    .nav-inner {
        height: 52px;
        padding: 0 12px;
        max-width: 100%;
        box-sizing: border-box;
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 8px;
    }
    .nav-links {
        display: none !important;
    }
    .nav-logo {
        gap: 8px;
        flex-shrink: 0;
    }
    .nav-logo .logo-icon svg {
        width: 26px;
        height: 26px;
    }
    .nav-logo .logo-text {
        font-size: 15px;
        font-weight: 800;
        letter-spacing: 0.5px;
    }
    .nav-actions {
        gap: 6px;
        flex-shrink: 0;
        align-items: center;
    }
    .nav-guest-actions {
        display: none !important; /* Delegated cleanly to Bottom Nav / Hero */
    }
    .nav-user-profile {
        align-items: center;
        gap: 6px;
        position: relative;
    }
    .user-profile-badge {
        padding: 3px 8px !important;
        background: rgba(255, 255, 255, 0.05) !important;
        border: 1px solid rgba(255, 255, 255, 0.1) !important;
        max-width: 130px !important;
        gap: 5px !important;
    }
    .user-avatar-mini {
        width: 22px !important;
        height: 22px !important;
        font-size: 0.65rem !important;
        flex-shrink: 0;
    }
    .user-name-mini {
        display: none !important; /* Compact mobile top bar: avatar + plan badge */
    }
    .user-plan-mini {
        font-size: 0.62rem !important;
        padding: 1px 5px !important;
        white-space: nowrap;
    }
    .profile-popover {
        position: absolute !important;
        top: calc(100% + 6px) !important;
        right: 0 !important;
        left: auto !important;
        width: 210px !important;
        max-width: calc(100vw - 20px) !important;
        box-sizing: border-box;
    }
    #btn-nav-logout {
        display: none !important;
    }
    .mobile-toggle {
        display: none !important; /* Bottom nav completely replaces hamburger */
    }
    .lang-selector {
        padding: 2px 3px;
        height: 24px;
        gap: 2px;
        background: rgba(255, 255, 255, 0.05);
        border: 1px solid rgba(255, 255, 255, 0.1);
        border-radius: 14px;
    }
    .lang-btn {
        padding: 1px 4px;
        font-size: 10px;
        font-weight: 700;
        border-radius: 10px;
    }
    .lang-divider {
        height: 10px;
    }

    /* Hero Section: Compact, High-Density, RTX Fury Style */
    .hero {
        flex-direction: column;
        text-align: left;
        padding: calc(52px + 16px) 14px 20px;
        min-height: auto;
        gap: 16px;
        box-sizing: border-box;
    }
    .hero-content {
        max-width: 100%;
        width: 100%;
    }
    .hero-visual {
        display: none !important; /* Large phone mockup removed on mobile/tablet per user requirement */
    }
    .hero-badge {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 3px 10px;
        font-size: 11px;
        font-weight: 700;
        margin-bottom: 10px;
        border-radius: 20px;
        background: rgba(168, 85, 247, 0.12);
        border: 1px solid rgba(168, 85, 247, 0.3);
        color: #c084fc;
        text-transform: uppercase;
        letter-spacing: 0.4px;
    }
    .badge-dot {
        width: 6px;
        height: 6px;
    }
    .hero-title {
        font-size: 23px !important;
        line-height: 1.25 !important;
        font-weight: 800 !important;
        margin-bottom: 10px;
        letter-spacing: -0.3px;
        color: #fff;
    }
    .hero-desc {
        font-size: 13.5px !important;
        line-height: 1.45 !important;
        color: #94a3b8;
        max-width: 100%;
        margin-bottom: 16px;
    }
    .hero-actions {
        display: flex;
        gap: 10px;
        width: 100%;
        margin-bottom: 16px;
    }
    .hero-actions .btn {
        flex: 1;
        height: 42px;
        font-size: 13px;
        font-weight: 600;
        padding: 0 12px;
        justify-content: center;
        border-radius: 10px;
        box-sizing: border-box;
    }
    .hero-actions .btn svg {
        width: 16px;
        height: 16px;
    }

    /* Live Platform Telemetry (RTX Fury Style) */
    .hero-live-stats {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
        width: 100%;
        margin-top: 0;
        margin-bottom: 18px;
    }
    .hero-live-stats .live-stat-card {
        background: rgba(13, 12, 24, 0.85);
        border: 1px solid rgba(168, 85, 247, 0.22);
        border-radius: 10px;
        padding: 9px 8px;
        min-width: 0;
        text-align: center;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        box-sizing: border-box;
    }
    .hero-live-stats .live-stat-header {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 4px;
        margin-bottom: 4px;
    }
    .hero-live-stats .live-stat-dot {
        width: 5px;
        height: 5px;
        border-radius: 50%;
        flex-shrink: 0;
    }
    .hero-live-stats .live-stat-label {
        font-size: 9.8px;
        color: #94a3b8;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.2px;
        white-space: nowrap;
    }
    .hero-live-stats .live-stat-value {
        font-size: 13.5px;
        font-weight: 800;
        color: #fff;
        font-family: var(--font-mono, monospace);
        line-height: 1.2;
        margin-bottom: 2px;
    }
    .hero-live-stats .live-stat-sub {
        font-size: 9.5px;
        color: #64748b;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    /* Technical Value Props */
    .hero-val-props {
        display: flex;
        flex-direction: column;
        gap: 8px;
        width: 100%;
        margin-top: 0;
    }
    .val-prop-card {
        padding: 9px 12px;
        gap: 10px;
        border-radius: 10px;
        background: rgba(255, 255, 255, 0.025);
        border: 1px solid rgba(255, 255, 255, 0.07);
    }
    .val-prop-icon {
        width: 28px;
        height: 28px;
        border-radius: 7px;
        flex-shrink: 0;
    }
    .val-prop-icon svg {
        width: 15px;
        height: 15px;
    }
    .val-prop-title {
        font-size: 12.5px;
        font-weight: 700;
        color: #f1f5f9;
        margin-bottom: 1px;
    }
    .val-prop-desc {
        font-size: 11.5px;
        line-height: 1.35;
        color: #94a3b8;
    }

    /* Sections & Headers */
    .section {
        padding: 24px 0;
    }
    .section-header {
        margin-bottom: 18px;
        text-align: left;
    }
    .section-tag {
        font-size: 11px;
        padding: 2px 8px;
        border-radius: 12px;
        margin-bottom: 6px;
    }
    .section-title {
        font-size: 20px !important;
        font-weight: 800 !important;
        line-height: 1.25 !important;
        margin-bottom: 6px;
    }
    .section-desc {
        font-size: 13px !important;
        line-height: 1.45 !important;
        color: #94a3b8;
        max-width: 100%;
    }

    /* Features Grid (RTX Fury Style 2-Column Responsive) */
    .features-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px !important;
    }
    .feature-card {
        padding: 12px 10px !important;
        border-radius: 10px !important;
        background: rgba(14, 13, 26, 0.7);
        border: 1px solid rgba(255, 255, 255, 0.08);
        display: flex;
        flex-direction: column;
    }
    .feature-icon {
        width: 30px !important;
        height: 30px !important;
        border-radius: 7px !important;
        margin-bottom: 6px !important;
    }
    .feature-icon svg {
        width: 15px !important;
        height: 15px !important;
    }
    .feature-card h3 {
        font-size: 13px !important;
        font-weight: 700;
        margin-bottom: 3px !important;
        color: #fff;
    }
    .feature-card p {
        font-size: 11px !important;
        line-height: 1.35 !important;
        color: #94a3b8;
    }

    /* How it Works / Steps */
    .steps-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    .step-card {
        padding: 14px 16px;
        border-radius: 12px;
        display: flex;
        align-items: flex-start;
        gap: 12px;
        background: rgba(14, 13, 26, 0.7);
        border: 1px solid rgba(255, 255, 255, 0.08);
    }
    .step-number {
        font-size: 16px;
        font-weight: 800;
        color: #a855f7;
        width: 32px;
        height: 32px;
        border-radius: 8px;
        background: rgba(168, 85, 247, 0.12);
        display: flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
        margin-bottom: 0;
    }
    .step-content h3 {
        font-size: 14px;
        font-weight: 700;
        margin-bottom: 3px;
        color: #fff;
    }
    .step-content p {
        font-size: 12.5px;
        line-height: 1.4;
        color: #94a3b8;
    }
    .step-line {
        display: none !important;
    }

    /* CTA Section */
    .cta-card {
        padding: 22px 18px;
        border-radius: 14px;
        text-align: center;
    }
    .cta-card h2 {
        font-size: 18px;
        font-weight: 800;
        margin-bottom: 8px;
    }
    .cta-card p {
        font-size: 13px;
        line-height: 1.4;
        margin-bottom: 14px;
    }
    .cta-card .btn {
        width: 100%;
        height: 42px;
        font-size: 13.5px;
        justify-content: center;
        border-radius: 10px;
    }

    .desktop-only-text {
        display: none !important;
    }
    .mobile-only-text {
        display: block !important;
    }
    #btn-nav-logout {
        display: none !important;
    }

    /* Optimizer Page (#page-upload) */
    .upload-section {
        padding: calc(52px + 8px) 12px 18px !important;
    }
    .upload-container {
        padding: 0;
        max-width: 100%;
    }
    .optimizer-header {
        margin-bottom: 8px !important;
        text-align: left;
    }
    .optimizer-badge {
        font-size: 10px !important;
        padding: 2px 7px !important;
        margin-bottom: 4px !important;
    }
    .optimizer-title {
        font-size: 19px !important;
        font-weight: 800 !important;
        line-height: 1.2 !important;
        margin-bottom: 2px !important;
    }
    .optimizer-subtitle {
        font-size: 11.5px !important;
        line-height: 1.35 !important;
        color: #94a3b8;
    }
    .upload-panel {
        padding: 12px !important;
        border-radius: 12px !important;
        background: rgba(12, 11, 22, 0.85);
        border: 1px solid rgba(168, 85, 247, 0.25);
    }
    .tiktok-status-bar {
        padding: 8px 12px;
        border-radius: 10px;
        margin-bottom: 10px;
        flex-wrap: nowrap;
        gap: 8px;
    }
    .tiktok-icon-circle {
        width: 28px;
        height: 28px;
        border-radius: 7px;
    }
    .tiktok-icon-circle svg {
        width: 15px;
        height: 15px;
    }
    .tiktok-title {
        font-size: 12px;
        font-weight: 700;
    }
    .tiktok-sub {
        font-size: 10.5px;
    }
    .btn-tiktok-action {
        padding: 5px 10px;
        font-size: 11.5px;
        border-radius: 7px;
        white-space: nowrap;
    }
    .upload-dropzone {
        padding: 14px 10px !important;
        border-radius: 10px !important;
        min-height: auto !important;
    }
    .dropzone-icon-ring {
        width: 36px !important;
        height: 36px !important;
        border-radius: 9px !important;
        margin-bottom: 6px !important;
    }
    .dropzone-icon-ring svg {
        width: 18px !important;
        height: 18px !important;
    }
    .dropzone-title {
        font-size: 13px !important;
        font-weight: 700;
        margin-bottom: 2px !important;
    }
    .dropzone-sub {
        font-size: 11px !important;
        margin-bottom: 6px !important;
    }
    .dropzone-formats {
        gap: 6px !important;
        font-size: 10.5px !important;
    }
    .format-tag {
        font-size: 10px;
        padding: 2px 6px;
    }
    .upload-action-area {
        flex-direction: column;
        gap: 8px !important;
        margin-top: 10px;
    }
    .btn-optimize, .btn-tiktok-share {
        width: 100% !important;
        height: 42px !important;
        font-size: 13px !important;
        font-weight: 700;
        border-radius: 9px;
        justify-content: center;
    }
    .upload-panel-footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
        margin-top: 10px;
        padding-top: 8px;
        font-size: 11px;
    }

    /* Pricing Page (#page-pricing) */
    .pricing-section {
        padding: calc(52px + 10px) 12px 20px !important;
    }
    .pricing-grid {
        grid-template-columns: 1fr !important;
        gap: 10px !important;
        max-width: 100%;
        margin: 0;
    }
    .price-card, .pricing-card {
        padding: 12px 12px !important;
        border-radius: 12px !important;
        background: rgba(13, 12, 24, 0.85);
        border: 1px solid rgba(255, 255, 255, 0.08);
    }
    .price-card.featured, .pricing-card.featured {
        border-color: rgba(6, 182, 212, 0.45) !important;
        box-shadow: 0 0 25px rgba(6, 182, 212, 0.15) !important;
    }
    .price-header {
        margin-bottom: 8px !important;
        padding-bottom: 8px !important;
    }
    .price-name {
        font-size: 14px !important;
        margin-bottom: 4px !important;
    }
    .price-value {
        font-size: 23px !important;
        font-weight: 900;
    }
    .price-period {
        font-size: 11px !important;
    }
    .price-features {
        margin-bottom: 10px !important;
        gap: 6px !important;
    }
    .price-features li {
        font-size: 11.5px !important;
        gap: 6px !important;
    }
    .price-features li svg {
        width: 13px !important;
        height: 13px !important;
    }
    .price-card .btn, .pricing-card .btn {
        height: 38px !important;
        font-size: 12.5px !important;
        font-weight: 700;
        border-radius: 9px !important;
        width: 100%;
    }

    /* Dashboard Page (#page-dashboard) */
    .dashboard-layout {
        flex-direction: column;
    }
    .sidebar {
        position: fixed;
        top: 52px;
        left: 0;
        bottom: 56px;
        width: 260px;
        z-index: 1000;
        background: rgba(10, 10, 18, 0.98);
        border-right: 1px solid rgba(168, 85, 247, 0.25);
        box-shadow: 10px 0 30px rgba(0, 0, 0, 0.7);
        transform: translateX(-100%);
        transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    }
    .sidebar.active {
        transform: translateX(0);
    }
    .dash-content {
        margin-left: 0 !important;
        padding: calc(52px + 8px) 12px 20px !important;
        box-sizing: border-box;
        max-width: 100%;
    }
    .dash-topbar {
        padding: 0 4px;
        margin-bottom: 14px;
        height: 40px;
    }
    .dash-title {
        font-size: 17px !important;
        font-weight: 800;
    }
    .stats-row {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px !important;
        margin-bottom: 14px !important;
    }
    .stat-card {
        padding: 10px 12px !important;
        border-radius: 10px !important;
        gap: 10px !important;
    }
    .stat-card-icon {
        width: 32px !important;
        height: 32px !important;
        border-radius: 8px !important;
    }
    .stat-card-icon svg {
        width: 16px !important;
        height: 16px !important;
    }
    .stat-card-value {
        font-size: 14.5px !important;
        font-weight: 800;
    }
    .stat-card-label {
        font-size: 10.5px !important;
    }
    .dash-panel {
        padding: 14px !important;
        border-radius: 12px !important;
        margin-bottom: 14px;
    }

    /* Auth Pages: Login & Register */
    .auth-section {
        padding: calc(52px + 16px) 12px 24px;
    }
    .auth-card {
        padding: 20px 16px !important;
        border-radius: 14px !important;
        max-width: 100% !important;
    }
    .auth-header h2 {
        font-size: 20px !important;
        margin-bottom: 4px;
    }
    .auth-header p {
        font-size: 12.5px !important;
    }
    .auth-form .form-group {
        margin-bottom: 12px;
    }
    .auth-form label {
        font-size: 12px !important;
        margin-bottom: 4px;
    }
    .input-wrapper input {
        height: 42px !important;
        font-size: 14px !important;
        border-radius: 8px !important;
    }
    .btn-full, .btn-social {
        height: 42px !important;
        font-size: 13px !important;
        border-radius: 9px !important;
    }

    /* Modals Mobile App View */
    .auth-modal-overlay, .modal-overlay, #modal-tiktok-publish, #modal-payment-choice {
        padding: 12px !important;
        align-items: flex-end !important;
    }
    .auth-modal, .auth-modal-card {
        max-width: 100% !important;
        width: 100% !important;
        border-radius: 16px 16px 12px 12px !important;
        margin: 0 auto;
        max-height: 90vh;
        overflow-y: auto;
    }
    .auth-modal-header {
        padding: 14px 16px !important;
    }
    .payment-option-card {
        padding: 12px !important;
        gap: 10px !important;
    }

    /* Footer on Mobile */
    .footer {
        padding: 24px 0 16px;
        border-top: 1px solid rgba(255, 255, 255, 0.06);
    }
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    .footer-col h4 {
        font-size: 12px;
        margin-bottom: 8px;
    }
    .footer-col a {
        font-size: 12px;
        padding: 2px 0;
    }
    .footer-bottom {
        flex-direction: column;
        gap: 8px;
        text-align: center;
        font-size: 11px;
        padding-top: 14px;
    }

    /* Toasts positioned above fixed bottom nav on mobile */
    .toast-container {
        bottom: calc(56px + 12px) !important;
        right: 12px !important;
        left: 12px !important;
        align-items: center;
    }
}

/* Extra small devices (<= 360px - e.g. iPhone SE 1st gen, 320px) */
@media (max-width: 360px) {
    html {
        font-size: 12px;
    }
    .nav-inner {
        padding: 0 8px;
    }
    .nav-logo .logo-text {
        font-size: 13.5px;
    }
    .hero-title {
        font-size: 20px !important;
    }
    .hero-actions {
        flex-direction: column;
    }
    .hero-actions .btn {
        width: 100%;
    }
    .features-grid {
        grid-template-columns: 1fr !important;
    }
    .hero-live-stats {
        grid-template-columns: 1fr;
        gap: 6px;
    }
    .bottom-nav-item .bottom-nav-label {
        font-size: 9.5px;
    }
}

/* ============================================================
   TIKTOK & ZERNIO INTEGRATION STYLES
   ============================================================ */
.tiktok-status-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(18, 18, 32, 0.7);
    border: 1px solid rgba(168, 85, 247, 0.2);
    border-radius: 12px;
    padding: 12px 16px;
    margin-bottom: 16px;
    transition: all 0.25s ease;
}
.tiktok-status-bar:hover {
    border-color: rgba(6, 182, 212, 0.4);
    box-shadow: 0 0 20px rgba(6, 182, 212, 0.1);
}
.tiktok-status-left {
    display: flex;
    align-items: center;
    gap: 12px;
}
.tiktok-icon-circle {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    background: rgba(6, 182, 212, 0.15);
    color: #06b6d4;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
}
.tiktok-status-info {
    display: flex;
    flex-direction: column;
}
.tiktok-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: #fff;
    line-height: 1.2;
}
.tiktok-sub {
    font-size: 0.75rem;
    color: var(--text-muted);
}
.btn-tiktok-action {
    background: rgba(6, 182, 212, 0.15);
    color: #38bdf8;
    border: 1px solid rgba(6, 182, 212, 0.3);
    padding: 6px 14px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}
.btn-tiktok-action:hover {
    background: #06b6d4;
    color: #000;
    box-shadow: 0 0 15px rgba(6, 182, 212, 0.4);
}
.btn-tiktok-action.connected {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    border-color: rgba(239, 68, 68, 0.3);
}
.btn-tiktok-action.connected:hover {
    background: #ef4444;
    color: #fff;
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.4);
}
.btn-tag-preset:hover {
    background: var(--accent-purple) !important;
    color: #fff !important;
}

.btn-tiktok-share {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 10px;
    font-weight: 700;
    background: linear-gradient(135deg, #06b6d4, #a855f7);
    color: #fff;
    border: none;
    cursor: pointer;
    box-shadow: 0 0 20px rgba(6, 182, 212, 0.3);
    transition: all 0.25s;
}
.btn-tiktok-share.hidden {
    display: none !important;
}
#modal-tiktok-publish {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}
#modal-tiktok-publish.hidden {
    display: none !important;
}


/* ============================================================
   PHASE 8 MOBILE NAVBAR HARDENING (Prevent Header Overflow)
   ============================================================ */
@media (max-width: 768px) {
    #nav-admin-btn span {
        display: none !important;
    }
    #nav-admin-btn {
        padding: 5px 8px !important;
        gap: 0 !important;
        flex-shrink: 0 !important;
    }
    .nav-user-profile {
        gap: 6px !important;
        flex-shrink: 0 !important;
    }
    .user-profile-badge {
        padding: 3px 8px !important;
        gap: 6px !important;
        max-width: 140px !important;
    }
    #nav-user-name {
        max-width: 70px !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        white-space: nowrap !important;
    }
}
