/* ===========================
   RESET & BASE
   =========================== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --green: #1ed760;
    --green-dim: #1ed76033;
    --green-glow: #1ed76066;
    --green-dark: #0d5c2a;
    --bg: #050505;
    --bg-card: #0c0c0c;
    --bg-card-hover: #111111;
    --surface: #0f0f0f;
    --surface-2: #161616;
    --border: #1a1a1a;
    --border-light: #252525;
    --text: #f0f0f0;
    --text-muted: #888;
    --text-dim: #555;
    --blue: #3b82f6;
    --purple: #a855f7;
    --amber: #f59e0b;
    --rose: #f43f5e;
    --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --mono: 'JetBrains Mono', monospace;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

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

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.text-accent { color: var(--green); }

/* ===========================
   REVEAL ANIMATIONS
   =========================== */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}
.reveal-delay-1 { transition-delay: 0.15s; }
.reveal-delay-2 { transition-delay: 0.3s; }
.reveal-delay-3 { transition-delay: 0.45s; }

/* ===========================
   BUTTONS
   =========================== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    font-family: var(--font);
}

.btn-primary {
    background: var(--green);
    color: #000;
}
.btn-primary:hover {
    background: #22e668;
    transform: translateY(-2px);
    box-shadow: 0 8px 30px var(--green-dim);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--border-light);
    color: var(--text);
}
.btn-outline:hover {
    border-color: var(--green);
    color: var(--green);
    transform: translateY(-2px);
}

.btn-glow {
    box-shadow: 0 0 20px var(--green-dim), 0 0 60px var(--green-dim);
}
.btn-glow:hover {
    box-shadow: 0 0 30px var(--green-glow), 0 0 80px var(--green-dim);
}

.btn-block { width: 100%; justify-content: center; }

.btn-xl {
    padding: 18px 40px;
    font-size: 1.1rem;
    border-radius: 14px;
}

/* ===========================
   NAVBAR
   =========================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 0 40px;
    background: rgba(5,5,5,0.6);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid transparent;
    transition: all 0.3s ease;
}
.navbar.scrolled {
    border-bottom-color: var(--border);
    background: rgba(5,5,5,0.85);
}
.nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
    height: 70px;
}
.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1.2rem;
}
.nav-logo-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    /* Electric Card Lightning Effect */
    filter: drop-shadow(0 0 10px var(--green)) drop-shadow(0 0 20px rgba(30, 215, 96, 0.5));
    animation: electricLogoPulse 2s infinite alternate;
}
@keyframes electricLogoPulse {
    0% { filter: drop-shadow(0 0 8px var(--green)) drop-shadow(0 0 15px rgba(30, 215, 96, 0.4)); transform: scale(1); }
    100% { filter: drop-shadow(0 0 15px var(--green)) drop-shadow(0 0 30px rgba(30, 215, 96, 0.7)); transform: scale(1.05); }
}
.nav-logo-icon img {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain;
}
.nav-links {
    display: flex;
    align-items: center;
    gap: 0;
    white-space: nowrap;
}
.nav-links a {
    position: relative;
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    margin-left: 26px;
    padding-left: 28px;
    font-size: 0.98rem;
    color: var(--text-muted);
    transition: color 0.2s, text-shadow 0.2s;
    font-weight: 500;
}
.nav-links a:first-child {
    margin-left: 0;
    padding-left: 0;
}
.nav-links a + a::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    width: 1px;
    height: 24px;
    background: rgba(255,255,255,0.38);
    transform: translateY(-50%) rotate(36deg);
    transform-origin: center;
}
.nav-links a:hover,
.nav-links a.active {
    color: var(--text);
}
.nav-links a.active {
    text-shadow: 0 0 18px rgba(30,215,96,0.28);
}
.nav-links a:focus-visible {
    outline: 1px solid rgba(30,215,96,0.65);
    outline-offset: 8px;
    border-radius: 4px;
}
.nav-cta {
    padding: 10px 22px;
    background: var(--green);
    color: #000;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.85rem;
    transition: all 0.3s;
}
.nav-cta:hover {
    background: #22e668;
    box-shadow: 0 4px 20px var(--green-dim);
}

.hero,
.extension-section,
.pricing-section {
    scroll-margin-top: 90px;
}

/* ===========================
   HERO
   =========================== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 120px 40px 60px;
    overflow: hidden;
}
.hero-bg-canvas {
    position: absolute;
    inset: 0;
    z-index: 0;
}
.hero-glow {
    position: absolute;
    top: -200px;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 800px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--green-dim) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}
.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 800px;
}
.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 16px 6px 10px;
    border-radius: 100px;
    background: var(--green-dim);
    border: 1px solid rgba(30,215,96,0.2);
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--green);
    margin-bottom: 28px;
}
.hero-badge-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--green);
    animation: pulse-dot 2s infinite;
}
@keyframes pulse-dot {
    0%, 100% { opacity: 1; box-shadow: 0 0 0 0 var(--green-glow); }
    50% { opacity: 0.6; box-shadow: 0 0 0 6px transparent; }
}
.hero-title {
    font-size: clamp(3rem, 7vw, 5.5rem);
    font-weight: 900;
    line-height: 1.05;
    letter-spacing: -0.03em;
    margin-bottom: 24px;
}
.hero-title-accent {
    background: linear-gradient(135deg, var(--green), #6bff9e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-muted);
    max-width: 560px;
    margin: 0 auto 36px;
    line-height: 1.7;
}
.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}
.hero-platform {
    margin-top: 16px;
    font-size: 0.78rem;
    color: var(--text-dim);
}
.hero-image-wrap {
    position: relative;
    z-index: 1;
    margin-top: 60px;
    margin-bottom: 80px;
    max-width: 1300px;
    width: 100%;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid var(--border);
}
.hero-image-glow {
    position: absolute;
    inset: -2px;
    border-radius: 18px;
    background: linear-gradient(135deg, var(--green-dim), transparent 50%);
    z-index: -1;
}

/* ===========================
   LIVE APP DEMO
   =========================== */
.demo-app {
    display: flex;
    background: #0a0a0a;
    border-radius: 16px;
    min-height: 420px;
    font-size: 13px;
    color: #e0e0e0;
    overflow: hidden;
    box-shadow: 0 40px 80px rgba(0,0,0,0.6);
}

/* -- Sidebar -- */
.demo-sidebar {
    width: 180px;
    min-width: 180px;
    background: #080808;
    border-right: 1px solid #1a1a1a;
    display: flex;
    flex-direction: column;
    padding: 16px 0;
}
.demo-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 16px 20px;
    font-weight: 700;
    font-size: 14px;
}
.demo-logo-icon {
    width: 36px; height: 36px;
    display: flex; align-items: center; justify-content: center;
}
.demo-logo-icon img {
    width: 100% !important; height: 100% !important; object-fit: contain;
}
.demo-nav { flex: 1; display: flex; flex-direction: column; gap: 2px; padding: 0 8px; }
.demo-nav-bottom { padding: 0 8px; border-top: 1px solid #1a1a1a; padding-top: 8px; margin-top: 8px; }
.demo-nav-item {
    display: flex; align-items: center; gap: 10px;
    padding: 9px 12px;
    border-radius: 10px;
    color: #666;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: 500;
    position: relative;
}
.demo-nav-item:hover { background: rgba(255,255,255,0.04); color: #aaa; }
.demo-nav-item.active {
    background: linear-gradient(135deg, rgba(30,215,96,0.15), rgba(30,215,96,0.05));
    color: var(--green);
}
.demo-nav-badge {
    margin-left: auto;
    background: var(--green);
    color: #000;
    font-size: 10px;
    font-weight: 800;
    width: 18px; height: 18px;
    border-radius: 6px;
    display: flex; align-items: center; justify-content: center;
}

/* -- Main Area -- */
.demo-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    position: relative;
    overflow: hidden;
}

/* -- Animated Background Layer -- */
.demo-bg-layer {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}
.demo-bg-canvas {
    width: 100%;
    height: 100%;
    display: block;
}

/* -- Single Card Layout -- */
.demo-single-card-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
    padding: 24px;
}
.demo-dl-card-hero {
    max-width: 420px;
    width: 100%;
    backdrop-filter: blur(8px);
    background: rgba(15, 15, 15, 0.85) !important;
}

/* -- Top Bar -- */
.demo-topbar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid #1a1a1a;
    background: rgba(10,10,10,0.9);
    position: relative;
    z-index: 1;
}
.demo-search {
    display: flex; align-items: center; gap: 8px;
    background: rgba(255,255,255,0.04);
    border: 1px solid #222;
    border-radius: 10px;
    padding: 8px 14px;
    color: #555;
    flex: 1;
    max-width: 240px;
    font-size: 12px;
}
.demo-stats-bar {
    display: flex; gap: 10px; margin-left: auto;
}
.demo-stat-chip {
    display: flex; flex-direction: column; align-items: center; gap: 1px;
}
.demo-stat-label {
    font-size: 9px; font-weight: 700; letter-spacing: 0.08em;
    color: #555; text-transform: uppercase;
}
.demo-stat-val { font-size: 12px; font-weight: 700; color: #ccc; }
.demo-stat-green { color: var(--green) !important; }
.demo-signal {
    display: flex; align-items: center; gap: 6px;
    font-size: 11px; color: #555; font-weight: 500;
    margin-left: 8px;
}
.demo-signal-dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 6px var(--green);
    animation: pulse-dot 2s infinite;
}
.demo-avatar {
    width: 30px; height: 30px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(30,215,96,0.3), rgba(30,215,96,0.1));
    border: 2px solid var(--green);
    display: flex; align-items: center; justify-content: center;
    font-size: 14px;
    cursor: pointer;
}

/* -- Cards Grid -- */
.demo-cards-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    padding: 16px;
    flex: 1;
    overflow: hidden;
}

/* -- Download Card -- */
.demo-dl-card {
    background: #0f0f0f;
    border: 1px solid #1e1e1e;
    border-radius: 14px;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}
.demo-dl-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 14px;
    opacity: 0;
    background: linear-gradient(135deg, rgba(30,215,96,0.05), transparent 60%);
    transition: opacity 0.3s;
}
.demo-dl-card:hover {
    border-color: rgba(30,215,96,0.3);
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(30,215,96,0.08);
}
.demo-dl-card:hover::before { opacity: 1; }

.demo-card-header { display: flex; align-items: center; gap: 10px; position: relative; z-index: 1; }
.demo-card-ext {
    width: 36px; height: 36px;
    border-radius: 10px;
    background: linear-gradient(135deg, rgba(30,215,96,0.2), rgba(30,215,96,0.05));
    border: 1px solid rgba(30,215,96,0.15);
    display: flex; align-items: center; justify-content: center;
    font-size: 10px; font-weight: 800; text-transform: uppercase;
    color: var(--green);
    font-family: var(--mono);
}
.demo-ext-mov {
    background: linear-gradient(135deg, rgba(139,92,246,0.2), rgba(139,92,246,0.05));
    border-color: rgba(139,92,246,0.15);
    color: #8b5cf6;
}
.demo-ext-iso {
    background: linear-gradient(135deg, rgba(59,130,246,0.2), rgba(59,130,246,0.05));
    border-color: rgba(59,130,246,0.15);
    color: #3b82f6;
}
.demo-card-info { flex: 1; min-width: 0; }
.demo-card-name {
    font-weight: 700; font-size: 12.5px; color: #eee;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.demo-card-size { font-size: 11px; color: #555; margin-top: 2px; }
.demo-card-menu {
    width: 26px; height: 26px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 8px; cursor: pointer; color: #555;
    font-size: 16px; font-weight: 700;
    transition: all 0.2s;
}
.demo-card-menu:hover { background: rgba(255,255,255,0.06); color: #aaa; }
.demo-menu-active { background: var(--green); color: #000 !important; border-radius: 8px; }

/* Progress Row (graph + percentage) */
.demo-card-progress-row {
    display: flex; align-items: center; gap: 8px;
    position: relative; z-index: 1;
}
.demo-card-graph {
    flex: 1; height: 32px;
    background: rgba(30,215,96,0.03);
    border-radius: 6px;
    overflow: hidden;
}
.demo-card-graph canvas { width: 100%; height: 100%; }
.demo-card-pct {
    font-size: 14px; font-weight: 800;
    font-family: var(--mono);
    min-width: 40px; text-align: right;
}

/* Progress Bar */
.demo-card-bar-wrap {
    height: 4px; border-radius: 4px;
    background: rgba(255,255,255,0.06);
    overflow: hidden;
    position: relative; z-index: 1;
}
.demo-card-bar {
    height: 100%; border-radius: 4px;
    background: linear-gradient(90deg, var(--green), #6bff9e);
    transition: width 1.5s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
}
.demo-bar-glow {
    box-shadow: 0 0 12px var(--green), 0 0 30px rgba(30,215,96,0.3);
}
.demo-bar-glow::after {
    content: '';
    position: absolute;
    right: -2px; top: -3px;
    width: 10px; height: 10px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 14px var(--green);
    animation: pulse-dot 1.5s infinite;
}

/* Footer */
.demo-card-footer {
    display: flex; justify-content: space-between;
    font-size: 11px; color: #555;
    position: relative; z-index: 1;
}

/* Action Buttons */
.demo-card-actions {
    display: flex; gap: 6px;
    position: relative; z-index: 1;
}
.demo-action-btn {
    width: 28px; height: 28px;
    border-radius: 8px;
    border: 1px solid #222;
    background: rgba(255,255,255,0.03);
    color: #666;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.2s;
}
.demo-action-btn:hover { background: rgba(255,255,255,0.08); color: #ccc; border-color: #444; }
.demo-action-danger:hover { background: rgba(244,63,94,0.15); color: var(--rose); border-color: rgba(244,63,94,0.3); }

/* Bottom Bar */
.demo-bottom-bar {
    display: flex; align-items: center; justify-content: space-between;
    padding: 8px 16px;
    border-top: 1px solid #1a1a1a;
    font-size: 11px; color: #444;
    position: relative; z-index: 1;
    background: rgba(10,10,10,0.9);
}
.demo-network { display: flex; align-items: center; gap: 6px; }
.demo-signal-quality { display: flex; align-items: center; gap: 8px; }
.demo-signal-bars { display: flex; align-items: flex-end; gap: 2px; height: 12px; }
.demo-sbar {
    width: 3px; border-radius: 1px;
    background: #333;
}
.demo-sbar:nth-child(1) { height: 4px; }
.demo-sbar:nth-child(2) { height: 6px; }
.demo-sbar:nth-child(3) { height: 8px; }
.demo-sbar:nth-child(4) { height: 10px; }
.demo-sbar:nth-child(5) { height: 12px; }
.demo-sbar-full { background: var(--green); }

/* -- Tab Content -- */
.demo-tab-content { flex: 1; overflow: hidden; position: relative; z-index: 1; }
.demo-panel { display: none; padding: 16px; overflow-y: auto; height: 100%; animation: fadePanel 0.3s ease; position: relative; z-index: 1; }
.demo-panel.active { display: block; }
.demo-panel[data-panel="active"].active { display: flex; flex-direction: column; }
@keyframes fadePanel { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }

/* -- Panel Title -- */
.demo-panel-title {
    font-size: 14px; font-weight: 800; margin-bottom: 14px;
    color: #eee; letter-spacing: -0.01em;
}

/* -- List View (Completed, Videos, Music, Docs, Software) -- */
.demo-list { display: flex; flex-direction: column; gap: 6px; }
.demo-list-item {
    display: flex; align-items: center; gap: 12px;
    padding: 10px 14px; border-radius: 12px;
    background: #0f0f0f;
    border: 1px solid #1a1a1a;
    transition: all 0.2s;
    cursor: pointer;
}
.demo-list-item:hover { border-color: rgba(30,215,96,0.2); background: #111; }
.demo-list-info { flex: 1; min-width: 0; }
.demo-done-badge {
    width: 24px; height: 24px;
    border-radius: 50%;
    background: rgba(30,215,96,0.15);
    color: var(--green);
    display: flex; align-items: center; justify-content: center;
    font-size: 12px; font-weight: 800;
}

/* -- Extension type badges for music/docs -- */
.demo-ext-music {
    background: linear-gradient(135deg, rgba(236,72,153,0.2), rgba(236,72,153,0.05));
    border-color: rgba(236,72,153,0.15);
    color: #ec4899;
}
.demo-ext-doc {
    background: linear-gradient(135deg, rgba(245,158,11,0.2), rgba(245,158,11,0.05));
    border-color: rgba(245,158,11,0.15);
    color: #f59e0b;
}

/* ===========================
   DEMO SETTINGS
   =========================== */
.demo-settings {
    display: flex; flex-direction: column; gap: 20px;
}
.demo-settings-section {
    background: #0d0d0d;
    border: 1px solid #1a1a1a;
    border-radius: 14px;
    padding: 16px;
}
.demo-settings-title {
    font-size: 13px; font-weight: 800;
    color: #eee; margin-bottom: 14px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-size: 10px;
}
.demo-setting-row {
    margin-bottom: 16px;
}
.demo-setting-label {
    font-size: 12px; font-weight: 600; color: #888;
    margin-bottom: 8px;
}

/* -- Color Swatches -- */
.demo-color-swatches {
    display: flex; gap: 8px; flex-wrap: wrap;
}
.demo-swatch {
    width: 28px; height: 28px;
    border-radius: 50%;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}
.demo-swatch:hover { transform: scale(1.15); }
.demo-swatch.active {
    border-color: #fff;
    box-shadow: 0 0 12px currentColor;
}
.demo-swatch.active::after {
    content: '✓';
    position: absolute;
    inset: 0;
    display: flex; align-items: center; justify-content: center;
    font-size: 12px; font-weight: 900;
    color: #000;
}

/* -- Background Theme Previews -- */
.demo-bg-options { display: flex; gap: 10px; }
.demo-bg-option {
    flex: 1;
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    cursor: pointer;
}
.demo-bg-option span { font-size: 10px; color: #666; font-weight: 600; }
.demo-bg-option.active span { color: var(--green); }
.demo-bg-preview {
    width: 100%; height: 60px;
    border-radius: 10px;
    background: #080808;
    border: 2px solid #1a1a1a;
    overflow: hidden;
    position: relative;
    transition: all 0.2s;
}
.demo-bg-option.active .demo-bg-preview {
    border-color: var(--green);
    box-shadow: 0 0 12px rgba(30,215,96,0.2);
}

/* Gravity preview */
.demo-bg-gravity .demo-bg-dots {
    position: absolute; inset: 0;
    background: radial-gradient(circle at 20% 40%, rgba(30,215,96,0.3) 0%, transparent 40%),
                radial-gradient(circle at 70% 30%, rgba(30,215,96,0.2) 0%, transparent 30%),
                radial-gradient(circle at 50% 80%, rgba(30,215,96,0.15) 0%, transparent 35%);
    animation: demoGravFloat 3s ease-in-out infinite alternate;
}
@keyframes demoGravFloat {
    from { transform: translateY(0); }
    to { transform: translateY(-4px); }
}

/* Dotted preview */
.demo-bg-dotted .demo-bg-dot-grid {
    position: absolute; inset: 0;
    background-image: radial-gradient(circle, rgba(30,215,96,0.4) 1px, transparent 1px);
    background-size: 8px 8px;
    animation: demoDotPulse 2s ease-in-out infinite alternate;
}
@keyframes demoDotPulse {
    from { opacity: 0.5; }
    to { opacity: 1; }
}

/* Pulsar preview */
.demo-bg-pulsar .demo-bg-pulse-ring {
    position: absolute;
    top: 50%; left: 50%;
    width: 20px; height: 20px;
    border-radius: 50%;
    border: 1px solid rgba(30,215,96,0.6);
    transform: translate(-50%, -50%);
    animation: demoPulseRing 2s ease-out infinite;
}
.demo-bg-pulsar::before {
    content: '';
    position: absolute;
    top: 50%; left: 50%;
    width: 4px; height: 4px;
    border-radius: 50%;
    background: var(--green);
    transform: translate(-50%, -50%);
    box-shadow: 0 0 6px var(--green);
}
@keyframes demoPulseRing {
    from { width: 8px; height: 8px; opacity: 1; }
    to { width: 50px; height: 50px; opacity: 0; }
}

/* -- Toggle Switch -- */
.demo-setting-toggle-row {
    display: flex; align-items: center; justify-content: space-between;
    padding: 6px 0;
}
.demo-toggle {
    position: relative;
    width: 36px; height: 20px;
    cursor: pointer;
}
.demo-toggle input { opacity: 0; width: 0; height: 0; }
.demo-toggle-slider {
    position: absolute; inset: 0;
    background: #333;
    border-radius: 20px;
    transition: all 0.3s;
}
.demo-toggle-slider::before {
    content: '';
    position: absolute;
    left: 2px; top: 2px;
    width: 16px; height: 16px;
    border-radius: 50%;
    background: #888;
    transition: all 0.3s;
}
.demo-toggle input:checked + .demo-toggle-slider {
    background: rgba(30,215,96,0.3);
}
.demo-toggle input:checked + .demo-toggle-slider::before {
    transform: translateX(16px);
    background: var(--green);
    box-shadow: 0 0 6px var(--green);
}

/* -- Range Slider -- */
.demo-range-wrap { display: flex; align-items: center; gap: 8px; }
.demo-range {
    flex: 1; -webkit-appearance: none; appearance: none;
    height: 4px; border-radius: 4px;
    background: #333;
    outline: none;
}
.demo-range::-webkit-slider-thumb {
    -webkit-appearance: none; appearance: none;
    width: 14px; height: 14px;
    border-radius: 50%;
    background: var(--green);
    cursor: pointer;
    box-shadow: 0 0 6px var(--green);
}
.demo-range-val {
    font-size: 12px; font-weight: 800;
    color: var(--green);
    font-family: var(--mono);
    min-width: 20px; text-align: center;
}
.hero-scroll-indicator {
    position: absolute;
    bottom: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    z-index: 1;
}
.hero-scroll-indicator span {
    font-size: 0.7rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.15em;
}
.scroll-line {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, var(--green), transparent);
    animation: scroll-bounce 2s infinite;
}
@keyframes scroll-bounce {
    0%, 100% { transform: scaleY(1); opacity: 1; }
    50% { transform: scaleY(0.5); opacity: 0.3; }
}

/* ===========================
   STATS BAR
   =========================== */
.stats-bar {
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    background: var(--surface);
    padding: 0 40px;
}
.stats-inner {
    max-width: 1000px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 36px 0;
}
.stat {
    text-align: center;
    flex: 1;
}
.stat-number {
    display: block;
    font-size: 2.8rem;
    font-weight: 800;
    color: var(--green);
    font-variant-numeric: tabular-nums;
}
.stat-label {
    display: block;
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-top: 4px;
    font-weight: 500;
}
.stat-divider {
    width: 1px;
    height: 50px;
    background: var(--border);
}

/* ===========================
   SECTION COMMONS
   =========================== */
.section-header {
    text-align: center;
    margin-bottom: 60px;
}
.section-label {
    display: inline-block;
    padding: 4px 14px;
    border-radius: 100px;
    background: var(--green-dim);
    color: var(--green);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 16px;
}
.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 16px;
}
.section-desc {
    font-size: 1.05rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.7;
}

/* Gravity particles */
.gravity-particles {
    width: 100%;
    height: 100%;
    position: relative;
}
.gp {
    position: absolute;
    left: var(--x);
    top: var(--y);
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 12px var(--green-glow);
    animation: float-particle var(--d) ease-in-out infinite alternate;
}
@keyframes float-particle {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(15px, -20px) scale(1.3); }
}

/* Dotted grid */
.dotted-grid {
    width: 100%;
    height: 100%;
    background-image: radial-gradient(var(--green-dim) 1.5px, transparent 1.5px);
    background-size: 16px 16px;
    animation: dotted-wave 4s ease-in-out infinite;
}
@keyframes dotted-wave {
    0%, 100% { background-position: 0 0; opacity: 0.6; }
    50% { background-position: 8px 8px; opacity: 1; }
}

/* Pulsar rings */
.pulsar-rings {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}
.pr {
    position: absolute;
    border-radius: 50%;
    border: 1px solid var(--green);
    width: calc(60px + var(--i) * 50px);
    height: calc(60px + var(--i) * 50px);
    opacity: 0;
    animation: pulsar-expand 3s ease-out infinite;
    animation-delay: calc(var(--i) * 0.7s);
}
@keyframes pulsar-expand {
    0% { transform: scale(0.5); opacity: 0.8; }
    100% { transform: scale(2); opacity: 0; }
}

/* ===========================
   EXTENSION SECTION
   =========================== */
.extension-section {
    padding: 120px 40px;
    background: var(--surface);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}
.extension-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}
.extension-text .section-label { margin-bottom: 12px; }
.extension-text .section-title {
    text-align: left;
    margin-bottom: 12px;
}
.extension-text .section-desc {
    text-align: left;
    margin: 0 0 28px 0;
}
.extension-features {
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.ext-feat {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.92rem;
    color: var(--text-muted);
}
.extension-image img {
    border-radius: 16px;
    border: 1px solid var(--border);
    box-shadow: 0 20px 60px rgba(0,0,0,0.4);
}

/* Sideload card — lives here until the Chrome Web Store listing goes live. */
.ext-download {
    margin-top: 32px;
    padding: 24px;
    border: 1px solid var(--border-light);
    border-radius: 16px;
    background: rgba(255,255,255,0.02);
}
.ext-dl-head {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 10px;
}
.ext-badge {
    padding: 4px 12px;
    border-radius: 100px;
    background: var(--green-dim);
    color: var(--green);
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.ext-ver {
    font-size: 0.8rem;
    color: var(--text-muted);
}
.ext-dl-desc {
    margin: 0 0 18px 0;
    font-size: 0.92rem;
    color: var(--text-muted);
}
.ext-dl-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}
.ext-dl-buttons .btn {
    padding: 12px 22px;
    font-size: 0.9rem;
}
/* Google's "Available in the Chrome Web Store" badge, rebuilt in markup so it
   stays crisp at any DPI without a third-party asset request. */
.cws-badge {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    padding: 10px 22px 10px 16px;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.35);
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.cws-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(0,0,0,0.45);
}
.cws-logo { flex-shrink: 0; }
.cws-text {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
    text-align: left;
}
.cws-sub {
    font-size: 0.8rem;
    color: #5f6368;
}
.cws-main {
    font-size: 1.15rem;
    font-weight: 500;
    color: #202124;
}
.ext-dl-note {
    margin: 16px 0 0 0;
    font-size: 0.8rem;
    line-height: 1.5;
    color: var(--text-muted);
    opacity: 0.8;
}
.ext-dl-note code {
    padding: 1px 6px;
    border-radius: 6px;
    background: rgba(255,255,255,0.06);
    font-size: 0.8rem;
    color: var(--green);
}

/* ===========================
   TORRENT
   =========================== */
.torrent-section {
    padding: 120px 40px;
    max-width: 1000px;
    margin: 0 auto;
    text-align: center;
}
.torrent-inner {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 60px 48px;
    position: relative;
    overflow: hidden;
}
.torrent-inner::before {
    content: '';
    position: absolute;
    top: -1px;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--green), transparent);
}
.torrent-features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    margin-top: 40px;
}
.torrent-feat {
    text-align: center;
}
.tf-icon {
    font-size: 2rem;
    margin-bottom: 12px;
}
.torrent-feat h4 {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 6px;
}
.torrent-feat p {
    font-size: 0.8rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* ===========================
   PRICING
   =========================== */
.pricing-section {
    padding: 120px 40px;
    max-width: 1100px;
    margin: 0 auto;
}
.pricing-focus-grid {
    display: flex;
    justify-content: center;
    gap: 28px;
    padding: 60px 0;
    align-items: center;
}

.pf-card {
    position: relative;
    flex: 1 1 0;
    max-width: 340px;
    min-height: 480px;
    padding: 32px;
    border-radius: 20px;
    background: linear-gradient(180deg, #161616 0%, #0e0e0e 100%);
    border: 1px solid rgba(255,255,255,0.08);
    display: flex;
    flex-direction: column;
    will-change: transform, filter;

    /* Base side-card state */
    transform: scale(0.95);
    filter: brightness(0.4) blur(4px);
    z-index: 1;
    box-shadow: 0 8px 24px rgba(0,0,0,0.4);
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Default focused state: popular card when grid is not hovered */
.pricing-focus-grid:not(:hover) .pf-card.popular,
/* Hovered state: any card when hovered */
.pricing-focus-grid:hover .pf-card:hover {
    transform: translateY(-20px) scale(1.05);
    filter: brightness(1) blur(0px);
    z-index: 10;
    box-shadow: 0 30px 80px rgba(0,0,0,0.7), 0 0 0 1px rgba(30,215,96,0.33);
}

.pf-cta {
    margin-top: 24px;
    position: relative;
    height: 44px;
    border-radius: 12px;
    background: rgba(255,255,255,0.08);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.1);
    transition: all 0.5s;
    cursor: pointer;
}

/* Focused CTA colors */
.pricing-focus-grid:not(:hover) .pf-card.popular .pf-cta,
.pricing-focus-grid:hover .pf-card:hover .pf-cta,
.pricing-focus-grid:not(:hover) .pf-card.popular .pf-cta-primary,
.pricing-focus-grid:hover .pf-card:hover .pf-cta-primary {
    background: var(--green);
    color: #0a0a0a;
    border: none;
}

.pf-cta-primary {
    background: var(--green);
    color: #0a0a0a;
    border: none;
}

.pf-shimmer {
    position: absolute;
    top: 0; left: 0; bottom: 0;
    width: 80px;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.55) 50%, transparent 100%);
    opacity: 0;
    pointer-events: none;
}

/* Activate shimmer ONLY when card is focused */
.pricing-focus-grid:not(:hover) .pf-card.popular .pf-shimmer,
.pricing-focus-grid:hover .pf-card:hover .pf-shimmer {
    opacity: 1;
    animation: cta-shimmer 2.5s infinite;
}

@keyframes cta-shimmer {
    0% { transform: translateX(-150px) skewX(-20deg); }
    100% { transform: translateX(350px) skewX(-20deg); }
}

.pf-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--green);
    color: #0a0a0a;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    opacity: 0;
    transition: opacity 0.3s;
}

/* Show popular badge only when focused */
.pricing-focus-grid:not(:hover) .pf-card.popular .pf-badge,
.pricing-focus-grid:hover .pf-card:hover .pf-badge {
    opacity: 1;
}

.pf-name {
    font-size: 14px;
    font-weight: 600;
    color: rgba(255,255,255,0.6);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.pf-price-wrap {
    margin-top: 12px;
    display: flex;
    align-items: baseline;
    gap: 4px;
}
.pf-price {
    font-size: 56px;
    font-weight: 700;
    color: white;
    letter-spacing: -0.04em;
    line-height: 1;
}
.pf-period {
    font-size: 16px;
    color: rgba(255,255,255,0.5);
    font-weight: 500;
}

.pf-features {
    margin-top: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex: 1;
    list-style: none;
}
.pf-features li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: rgba(255,255,255,0.85);
}
.pf-check {
    width: 16px;
    height: 16px;
    border-radius: 999px;
    background: rgba(30,215,96,0.13);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--green);
    font-size: 11px;
    font-weight: 700;
    flex-shrink: 0;
}

/* ===========================
   FOOTER
   =========================== */
.footer {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    border-top: 1px solid var(--border);
    background: var(--bg);
    padding: 150px 24px 40px;
}

/* --- ambient background --- */
.footer-aurora {
    position: absolute;
    left: 50%; top: 46%;
    width: 80vw; height: 60vh; max-width: 1100px;
    transform: translate(-50%, -50%);
    background: radial-gradient(circle at 50% 50%,
        var(--green-glow) 0%, rgba(30,215,96,0.08) 40%, transparent 70%);
    filter: blur(80px);
    border-radius: 50%;
    pointer-events: none;
    z-index: -2;
    animation: footer-breathe 8s ease-in-out infinite alternate;
}
@keyframes footer-breathe {
    from { transform: translate(-50%, -50%) scale(1);    opacity: 0.5; }
    to   { transform: translate(-50%, -50%) scale(1.12); opacity: 0.9; }
}
.footer-grid {
    position: absolute; inset: 0;
    z-index: -2; pointer-events: none;
    background-size: 60px 60px;
    background-image:
        linear-gradient(to right, rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(255,255,255,0.03) 1px, transparent 1px);
    -webkit-mask-image: linear-gradient(to bottom, transparent, #000 30%, #000 70%, transparent);
    mask-image: linear-gradient(to bottom, transparent, #000 30%, #000 70%, transparent);
}
.footer-giant {
    position: absolute;
    left: 50%; bottom: -4vh;
    transform: translateX(-50%);
    z-index: -1;
    font-size: 26vw; font-weight: 900; line-height: 0.75; letter-spacing: -0.05em;
    white-space: nowrap; user-select: none; pointer-events: none;
    color: transparent;
    -webkit-text-stroke: 1px rgba(255,255,255,0.04);
    background: linear-gradient(180deg, rgba(255,255,255,0.07) 0%, transparent 60%);
    -webkit-background-clip: text;
    background-clip: text;
}

/* --- diagonal marquee --- */
.footer-marquee {
    position: absolute;
    top: 68px; left: -5%; width: 110%;
    z-index: 0; overflow: hidden;
    padding: 14px 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    background: rgba(5,5,5,0.6);
    backdrop-filter: blur(8px);
    transform: rotate(-2deg);
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}
.footer-marquee-track {
    display: flex; width: max-content;
    animation: footer-marquee 40s linear infinite;
}
@keyframes footer-marquee { to { transform: translateX(-50%); } }
.fm-item {
    padding: 0 12px; white-space: nowrap;
    font-size: 0.8rem; font-weight: 700; letter-spacing: 0.28em; text-transform: uppercase;
    color: var(--text-muted);
}
.fm-item i { margin: 0 6px; font-style: normal; color: var(--green); }

/* --- main content --- */
.footer-main {
    position: relative; z-index: 2;
    max-width: 900px; margin: 0 auto;
    padding-top: 40px;
    display: flex; flex-direction: column; align-items: center; text-align: center;
}
.footer-brand-lg {
    display: flex; align-items: center; gap: 10px;
    margin-bottom: 22px;
    font-weight: 800; font-size: 1rem; letter-spacing: 0.02em;
}
.footer-heading {
    margin-bottom: 40px;
    font-size: clamp(2.4rem, 7vw, 5rem); font-weight: 900; line-height: 1; letter-spacing: -0.03em;
    background: linear-gradient(180deg, #fff 0%, rgba(255,255,255,0.4) 100%);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 24px rgba(255,255,255,0.12));
}

/* --- glass pills --- */
.footer-pill {
    position: relative;
    display: inline-flex; align-items: center; gap: 12px;
    padding: 18px 34px; border-radius: 999px;
    font-weight: 700; font-size: 0.95rem; color: var(--text);
    background: linear-gradient(145deg, rgba(255,255,255,0.05), rgba(255,255,255,0.01));
    border: 1px solid rgba(255,255,255,0.08);
    box-shadow: 0 10px 30px -10px rgba(0,0,0,0.6), inset 0 1px 1px rgba(255,255,255,0.08);
    backdrop-filter: blur(16px);
    cursor: pointer; will-change: transform;
    transition: transform 0.4s cubic-bezier(0.16,1,0.3,1),
                background 0.3s, border-color 0.3s, box-shadow 0.3s, color 0.3s;
}
.footer-pill:hover {
    background: linear-gradient(145deg, rgba(255,255,255,0.09), rgba(255,255,255,0.02));
    border-color: rgba(255,255,255,0.2);
    box-shadow: 0 20px 40px -10px rgba(0,0,0,0.7), inset 0 1px 1px rgba(255,255,255,0.18);
}
.footer-pill svg { width: 22px; height: 22px; flex-shrink: 0; }

.footer-downloads {
    display: flex; flex-wrap: wrap; justify-content: center; gap: 16px;
    margin-bottom: 28px;
}
.footer-pill-primary {
    color: #fff;
    background: linear-gradient(145deg, rgba(30,215,96,0.16), rgba(30,215,96,0.04));
    border-color: rgba(30,215,96,0.35);
    box-shadow: 0 10px 30px -8px rgba(30,215,96,0.3), inset 0 1px 1px rgba(255,255,255,0.12);
}
.footer-pill-primary:hover {
    background: linear-gradient(145deg, rgba(30,215,96,0.26), rgba(30,215,96,0.08));
    border-color: var(--green);
    box-shadow: 0 20px 44px -8px rgba(30,215,96,0.45), inset 0 1px 1px rgba(255,255,255,0.2);
}
.footer-pill-primary svg { color: var(--green); }

/* android — coming soon */
.footer-pill-soon {
    cursor: default;
    padding: 12px 20px 12px 26px;
    text-align: left;
}
.footer-pill-soon svg { color: var(--text-muted); }
.footer-pill-soon .fp-stack { display: flex; flex-direction: column; line-height: 1.15; }
.fp-label { font-size: 0.95rem; font-weight: 700; }
.fp-sub { font-size: 0.72rem; font-weight: 500; letter-spacing: 0.02em; color: var(--text-muted); }
.fp-badge {
    margin-left: 8px; padding: 4px 10px; border-radius: 999px;
    font-size: 0.6rem; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase;
    color: var(--green);
    background: rgba(30,215,96,0.12);
    border: 1px solid rgba(30,215,96,0.3);
    white-space: nowrap;
}

/* secondary links */
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.footer-pill.sm {
    padding: 10px 20px; font-size: 0.82rem; font-weight: 500; color: var(--text-muted);
}
.footer-pill.sm:hover { color: var(--text); }

/* --- bottom bar --- */
.footer-bottom {
    position: relative; z-index: 2;
    max-width: 1200px; margin: 90px auto 0;
    display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
}
.footer-copy {
    font-size: 0.72rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase;
    color: var(--text-dim);
}
.footer-made {
    display: flex; align-items: center; gap: 7px;
    padding: 10px 18px; border-radius: 999px;
    font-size: 0.72rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase;
    color: var(--text-muted);
    background: linear-gradient(145deg, rgba(255,255,255,0.04), rgba(255,255,255,0.01));
    border: 1px solid rgba(255,255,255,0.08);
}
.footer-heart {
    color: var(--rose);
    animation: footer-heartbeat 2s cubic-bezier(0.25,1,0.5,1) infinite;
}
@keyframes footer-heartbeat {
    0%,100% { transform: scale(1); }
    15%,45% { transform: scale(1.25); }
    30%     { transform: scale(1); }
}
.footer-top {
    width: 46px; height: 46px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: var(--text-muted); cursor: pointer; will-change: transform;
    background: linear-gradient(145deg, rgba(255,255,255,0.04), rgba(255,255,255,0.01));
    border: 1px solid rgba(255,255,255,0.08);
    transition: transform 0.4s cubic-bezier(0.16,1,0.3,1), color 0.3s, border-color 0.3s;
}
.footer-top:hover { color: var(--text); border-color: rgba(255,255,255,0.2); }
.footer-top svg { width: 20px; height: 20px; transition: transform 0.3s; }
.footer-top:hover svg { transform: translateY(-3px); }

@media (prefers-reduced-motion: reduce) {
    .footer-aurora, .footer-marquee-track, .footer-heart { animation: none; }
}

/* ===========================
   AUTH MODAL
   =========================== */
.auth-modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(8px);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}
.auth-modal-overlay.active {
    display: flex;
    opacity: 1;
}
.auth-modal-content {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 20px;
    width: 100%;
    max-width: 400px;
    padding: 36px;
    position: relative;
    transform: scale(0.95) translateY(20px);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 40px 80px rgba(0,0,0,0.8);
}
.auth-modal-overlay.active .auth-modal-content {
    transform: scale(1) translateY(0);
}
.auth-close-btn {
    position: absolute;
    top: 16px; right: 16px;
    background: none; border: none; color: var(--text-muted);
    font-size: 24px; cursor: pointer;
    transition: color 0.2s;
}
.auth-close-btn:hover { color: white; }

.auth-modal-header { text-align: center; margin-bottom: 24px; }
.auth-modal-header h3 { font-size: 1.5rem; font-weight: 800; margin-bottom: 8px; }
.auth-modal-header p { font-size: 0.9rem; color: var(--text-muted); }

.form-group { margin-bottom: 20px; }
.form-group label {
    display: block; font-size: 0.8rem; font-weight: 600;
    color: var(--text-dim); text-transform: uppercase;
    letter-spacing: 0.05em; margin-bottom: 8px;
}
.form-group input {
    width: 100%; padding: 12px 16px;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border);
    border-radius: 10px; color: white;
    font-family: inherit; font-size: 0.95rem;
    transition: all 0.2s;
}
.form-group input:focus {
    outline: none; border-color: rgba(30,215,96,0.5);
    background: rgba(30,215,96,0.05);
}
.auth-error-msg {
    padding: 12px; background: rgba(244,63,94,0.1);
    border: 1px solid rgba(244,63,94,0.2);
    border-radius: 8px; color: var(--rose);
    font-size: 0.85rem; text-align: center; margin-bottom: 20px;
}
.auth-success-msg {
    text-align: center; margin-bottom: 20px;
}
.auth-success-msg p { color: var(--green); font-weight: 600; margin-bottom: 12px; }
.auth-toggle {
    text-align: center; margin-top: 20px;
    font-size: 0.85rem; color: var(--text-muted);
}
.auth-toggle a { color: var(--green); font-weight: 600; }
.auth-toggle a:hover { text-decoration: underline; }

/* ===========================
   RESPONSIVE
   =========================== */
@media (max-width: 900px) {
    .navbar { padding: 0 20px; }
    .nav-inner {
        height: auto;
        min-height: 70px;
        flex-wrap: wrap;
        padding: 8px 0 12px;
        row-gap: 4px;
    }
    .nav-links {
        order: 3;
        width: 100%;
        overflow-x: auto;
        padding: 0 2px 2px;
        scrollbar-width: none;
    }
    .nav-links::-webkit-scrollbar { display: none; }
    .nav-links a {
        min-height: 34px;
        margin-left: 20px;
        padding-left: 22px;
        font-size: 0.9rem;
    }
    .nav-links a + a::before { height: 21px; }
    .nav-cta {
        padding: 9px 14px;
        font-size: 0.8rem;
    }
    .hero { padding-top: 160px; }
    .extension-inner { grid-template-columns: 1fr; }
    .torrent-features-grid { grid-template-columns: repeat(2, 1fr); }
    .pricing-focus-grid { flex-direction: column; gap: 40px; align-items: center; }
    .pf-card {
        transform: scale(1) !important;
        filter: none !important;
        box-shadow: 0 8px 24px rgba(0,0,0,0.4) !important;
        z-index: 1 !important;
        width: 100%;
    }
    .pf-card.popular {
        box-shadow: 0 0 30px var(--green-dim) !important;
        border-color: var(--green) !important;
    }
    .stats-inner { flex-wrap: wrap; gap: 20px; }
    .stat-divider { display: none; }
    .footer { padding: 110px 18px 32px; }
    .footer-marquee { top: 54px; }
    .footer-bottom { flex-direction: column; text-align: center; margin-top: 64px; gap: 16px; }

    /* Live Demo responsive */
    .demo-sidebar { display: none; }
    .demo-cards-grid { grid-template-columns: 1fr; }
    .demo-topbar { flex-wrap: wrap; }
    .demo-search { max-width: 100%; }
    .demo-stats-bar { margin-left: 0; }
    .demo-signal { display: none; }
    .demo-app { min-height: 360px; }
}

@media (max-width: 480px) {
    .navbar { padding: 0 14px; }
    .nav-inner { gap: 10px; }
    .nav-logo span { display: none; }
    .nav-logo-icon {
        width: 40px;
        height: 40px;
    }
    .nav-cta { padding: 8px 12px; }
    .nav-links a {
        margin-left: 17px;
        padding-left: 19px;
        font-size: 0.86rem;
    }
}

/* ===========================
   LEGAL PAGES (privacy / terms / refund)
   =========================== */
.legal-topbar {
    display: flex; align-items: center; justify-content: space-between;
    padding: 18px 28px; border-bottom: 1px solid var(--border);
    position: sticky; top: 0; background: rgba(5,5,5,0.82);
    backdrop-filter: blur(12px); z-index: 50;
}
.legal-topbar .brand { display: flex; align-items: center; gap: 10px; font-weight: 800; color: var(--text); }
.legal-topbar .brand img { width: 24px; height: 24px; object-fit: contain; }
.legal-topbar .back { font-size: 0.85rem; color: var(--text-muted); transition: color 0.2s; }
.legal-topbar .back:hover { color: var(--green); }

.legal-page {
    max-width: 820px; margin: 0 auto; padding: 64px 24px 80px;
    position: relative;
}
.legal-page::before {
    content: ""; position: fixed; top: -10%; left: 50%; transform: translateX(-50%);
    width: 900px; height: 640px; z-index: -1;
    background: radial-gradient(circle, var(--green-dim) 0%, transparent 62%);
    filter: blur(52px); opacity: 0.35; pointer-events: none;
}
.legal-page .eyebrow {
    font-size: 0.72rem; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase;
    color: var(--green); margin-bottom: 14px;
}
.legal-page h1 {
    font-size: clamp(2rem, 5vw, 3rem); font-weight: 900; line-height: 1.05;
    letter-spacing: -0.02em; margin-bottom: 18px;
}
.legal-page .effective {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(30,215,96,0.08); border: 1px solid rgba(30,215,96,0.2);
    border-radius: 8px; padding: 6px 14px; font-size: 0.8rem; color: var(--text-muted);
    margin-bottom: 34px;
}
.legal-page .effective strong { color: var(--green); font-weight: 600; }
.legal-page .lead {
    font-size: 0.98rem; color: var(--text-muted); line-height: 1.85;
    padding: 18px 20px; margin-bottom: 40px;
    background: rgba(30,215,96,0.05); border: 1px solid rgba(30,215,96,0.12); border-radius: 12px;
}
.legal-page section { margin-bottom: 38px; scroll-margin-top: 90px; }
.legal-page section .num {
    font-size: 0.68rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase;
    color: var(--green); margin-bottom: 8px;
}
.legal-page section h2 {
    font-size: 1.28rem; font-weight: 800; color: var(--text);
    margin-bottom: 14px; line-height: 1.25; letter-spacing: -0.01em;
}
.legal-page section p { font-size: 0.95rem; color: var(--text-muted); line-height: 1.85; margin-bottom: 12px; }
.legal-page section p strong { color: var(--text); font-weight: 600; }
.legal-page section a { color: var(--green); }
.legal-page section ul { list-style: none; padding: 0; margin: 14px 0; }
.legal-page section ul li {
    position: relative; padding-left: 22px; margin-bottom: 9px;
    font-size: 0.93rem; color: var(--text-muted); line-height: 1.7;
}
.legal-page section ul li::before {
    content: ""; position: absolute; left: 4px; top: 10px;
    width: 6px; height: 6px; border-radius: 50%; background: var(--green);
    box-shadow: 0 0 6px var(--green);
}
.legal-page section ul li strong { color: var(--text); }
.legal-page .divider {
    height: 1px; margin: 34px 0;
    background: linear-gradient(90deg, rgba(30,215,96,0.18), transparent);
}
.legal-page .accent { color: var(--green); font-weight: 600; }
@media (max-width: 640px) {
    .legal-topbar { padding: 14px 18px; }
    .legal-page { padding: 44px 20px 60px; }
}


/* ===========================
   FEATURES BENTO (features-8 style)
   =========================== */
.features-bento {
    padding: 120px 40px;
    max-width: 1080px;
    margin: 0 auto;
    scroll-margin-top: 90px;
}
.bento-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 16px;
}
.bento-card {
    grid-column: 1 / -1;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 32px;
    position: relative;
    overflow: hidden;
    transition: border-color 0.4s ease, background 0.4s ease, transform 0.4s ease;
}
.bento-card:hover {
    border-color: var(--border-light);
    background: var(--bg-card-hover);
    transform: translateY(-4px);
}
@media (min-width: 640px) {
    .bento-card.span-2, .bento-card.span-3 { grid-column: span 3; }
}
@media (min-width: 960px) {
    .bento-card.span-2 { grid-column: span 2; }
    .bento-card.span-3 { grid-column: span 3; }
}
.bento-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 8px;
}
.bento-card p {
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.6;
}

/* Centered top-row cards */
.bento-stat, .bento-centered {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-height: 280px;
}
.bento-stat h3, .bento-centered h3 { margin-top: 26px; }

/* Card: big stat + curved underline */
.bento-stat-graphic {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 220px;
    height: 96px;
}
.bento-curve {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    color: var(--green-dim);
}
.bento-stat-num {
    position: relative;
    font-size: 3.4rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--green);
    text-shadow: 0 0 26px var(--green-glow);
}

/* Circular icon badge (double ring) */
.bento-badge {
    position: relative;
    width: 56px;
    height: 56px;
    flex-shrink: 0;
    border-radius: 50%;
    border: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--green);
    background: var(--surface);
}
.bento-badge::before {
    content: "";
    position: absolute;
    inset: -8px;
    border-radius: 50%;
    border: 1px solid var(--border);
}
.bento-badge.sm { width: 48px; height: 48px; }
.bento-badge.blue { color: var(--blue); }
.bento-badge.purple { color: var(--purple); }

/* Card: live line chart */
.bento-chart {
    width: 100%;
    max-width: 320px;
    padding: 4px 4px 0;
}
.bento-chart svg { width: 100%; height: auto; display: block; }

/* Card: live theme orbs (Make It Yours) */
.theme-orbs {
    display: flex;
    align-items: center;
    justify-content: center;
    /* matches the peer-swarm svg height so both card titles line up */
    height: 175px;
}
.theme-orb {
    position: relative;
    width: 84px;
    height: 84px;
    flex-shrink: 0;
    border-radius: 50%;
    overflow: hidden;
    border: 1px solid var(--green-dim);
    background: radial-gradient(circle at 50% 30%, #1ed76014, var(--bg) 72%);
    box-shadow: 0 10px 26px rgba(0, 0, 0, 0.55);
    transition: transform 0.45s ease;
}
.theme-orb:nth-child(1) { z-index: 1; }
.theme-orb:nth-child(2) { width: 104px; height: 104px; margin: 0 -22px; z-index: 3; }
.theme-orb:nth-child(3) { z-index: 2; }
.bento-card:hover .theme-orb:nth-child(1) { transform: translateX(-12px) rotate(-8deg); }
.bento-card:hover .theme-orb:nth-child(3) { transform: translateX(12px) rotate(8deg); }
.theme-orb .gp { width: 6px; height: 6px; box-shadow: 0 0 10px var(--green); }
.theme-orb .dotted-grid {
    background-image: radial-gradient(#1ed76099 1.7px, transparent 1.7px);
    background-size: 12px 12px;
}
/* always-lit core so the pulsar orb reads even between pulses */
.theme-orb .pulsar-rings::before {
    content: "";
    width: 15px;
    height: 15px;
    border-radius: 50%;
    border: 1px solid var(--green);
    box-shadow: 0 0 12px var(--green-glow);
}
.theme-orb .pr {
    border-color: #1ed760aa;
    width: calc(22px + var(--i) * 22px);
    height: calc(22px + var(--i) * 22px);
}

/* Card: peer swarm (Torrent) */
.peer-swarm {
    width: 100%;
    max-width: 250px;
}
.peer-swarm svg { width: 100%; height: auto; display: block; }
.swarm-ring {
    transform-box: view-box;
    transform-origin: 100px 70px;
    animation: swarm-spin 26s linear infinite;
}
.swarm-link {
    animation: swarm-flow 1.3s linear infinite;
    animation-delay: calc(var(--i) * -0.2s);
}
.swarm-peer {
    filter: drop-shadow(0 0 6px #1ed76099);
    transform-box: fill-box;
}
.swarm-peer.alt {
    filter: drop-shadow(0 0 6px #3b82f699);
    transform-origin: center;
    animation: swarm-blink 3.2s ease-in-out infinite;
    animation-delay: calc(var(--i) * 0.42s);
}
.swarm-pulse {
    transform-box: view-box;
    transform-origin: 100px 70px;
    animation: swarm-pulse 2.8s ease-out infinite;
}
@keyframes swarm-spin { to { transform: rotate(360deg); } }
@keyframes swarm-flow { to { stroke-dashoffset: -20; } }
@keyframes swarm-blink {
    0%, 100% { opacity: 0.35; transform: scale(0.85); }
    50% { opacity: 1; transform: scale(1); }
}
@keyframes swarm-pulse {
    0% { transform: scale(0.55); opacity: 0.75; }
    100% { transform: scale(2.1); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
    .swarm-ring, .swarm-link, .swarm-peer, .swarm-pulse,
    .theme-orb .gp, .theme-orb .dotted-grid, .theme-orb .pr { animation: none; }
    .theme-orb .pr { opacity: 0.5; }
}

/* ===========================
   BYTE COMPANION
   =========================== */
.byte-section {
    padding: 120px 40px;
    max-width: 1240px;
    margin: 0 auto;
}
.byte-stage {
    display: grid;
    grid-template-columns: 1fr minmax(300px, 500px) 1fr;
    align-items: center;
    gap: 40px;
    margin-top: 48px;
}
.byte-center {
    display: flex;
    flex-direction: column;
    align-items: center;
}
/* the robot rises out of the lid into this gap */
.byte-fn.is-top { margin-bottom: 128px; }
.byte-fn-col {
    display: flex;
    flex-direction: column;
    align-self: start;
    padding-top: 98px;
    gap: 120px;
    z-index: 4;
}
.byte-fn-col.is-left { align-items: flex-end; }
.byte-fn-col.is-right { align-items: flex-start; }
/* splay the lower pair outward so the five sit on an arc around the robot */
.byte-fn-col.is-left .byte-fn:last-child { margin-right: 34px; }
.byte-fn-col.is-right .byte-fn:last-child { margin-left: 34px; }

.byte-fn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    border-radius: 100px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--text-muted);
    font-family: inherit;
    font-size: 0.92rem;
    font-weight: 600;
    white-space: nowrap;
    cursor: pointer;
    transition: border-color 0.3s, color 0.3s, box-shadow 0.3s, transform 0.3s;
}
.byte-fn svg { stroke: var(--green); flex-shrink: 0; opacity: 0.55; transition: opacity 0.3s; }
.byte-fn:hover,
.byte-fn:focus-visible {
    border-color: var(--green);
    color: var(--text);
    box-shadow: 0 0 28px rgba(30, 215, 96, 0.28);
    transform: translateY(-2px);
}
.byte-fn:hover svg,
.byte-fn:focus-visible svg { opacity: 1; }
.byte-fn.is-active {
    border-color: var(--green);
    background: var(--green-dim);
    color: var(--text);
    box-shadow: 0 0 28px rgba(30, 215, 96, 0.25);
}
.byte-fn.is-active svg { opacity: 1; }

/* --- the laptop (stationary, black, green glow) --- */
.byte-laptop { position: relative; width: 100%; }
.byte-lid {
    position: relative;
    z-index: 1;
    aspect-ratio: 16 / 10;
    border-radius: 16px;
    background: #090909;
    border: 1px solid #1f1f1f;
    box-shadow:
        0 0 50px 6px rgba(30, 215, 96, 0.20),
        0 0 130px 26px rgba(30, 215, 96, 0.10),
        inset 0 2px 5px rgba(255, 255, 255, 0.05);
}
.byte-cam {
    position: absolute;
    top: 6px; left: 50%;
    width: 4px; height: 4px;
    margin-left: -2px;
    border-radius: 50%;
    background: #161616;
}
.byte-screen {
    position: absolute;
    inset: 14px 14px 20px;
    border-radius: 6px;
    background: radial-gradient(120% 90% at 50% 0%, #06140b 0%, #000 70%);
    box-shadow: inset 0 0 40px rgba(30, 215, 96, 0.18), inset 0 0 2px #000;
    overflow: hidden;
}
/* single soft sheen, not a tiled band */
.byte-screen::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(-135deg, rgba(255,255,255,0) 42%, rgba(30,215,96,0.07) 50%, rgba(255,255,255,0) 58%);
    pointer-events: none;
}
.byte-term {
    position: absolute;
    left: 0; right: 0; bottom: 0;
    padding: 0 22px 20px;
    font-family: var(--mono);
    font-size: 0.72rem;
    line-height: 1.9;
    text-align: left;
}
.byte-term { transition: opacity 0.16s ease; }
.byte-term.is-swapping { opacity: 0; }
.byte-term p { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.byte-term-cmd { color: var(--text); }
.byte-term-cmd span { color: var(--green); }
.byte-term-ok { color: var(--green); opacity: 0.8; }
.byte-term-dl { color: var(--text-dim); display: flex; justify-content: space-between; gap: 12px; }
.byte-term-dl b { color: var(--green); font-weight: 500; }
.byte-term-bar {
    height: 3px;
    border-radius: 3px;
    background: rgba(30, 215, 96, 0.15);
    overflow: hidden;
    margin-top: 6px;
}
.byte-term-bar i {
    display: block;
    height: 100%;
    border-radius: 3px;
    background: var(--green);
    box-shadow: 0 0 10px var(--green);
    animation: byte-fill 4.5s ease-in-out infinite;
}
@keyframes byte-fill {
    0%   { width: 8%; }
    70%  { width: 86%; }
    100% { width: 92%; }
}

.byte-base {
    position: relative;
    z-index: 3;
    aspect-ratio: 16 / 3.2;
    perspective: 1800px;
}
.byte-deck {
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    /* scales with the laptop instead of a fixed pixel height */
    aspect-ratio: 16 / 9;
    border-radius: 0 0 10px 10px;
    background: #0a0a0a;
    border: 1px solid #1c1c1c;
    transform: rotateX(72deg);
    transform-origin: top center;
    box-shadow: 0 0 40px rgba(30, 215, 96, 0.14);
}
.byte-keys {
    position: absolute;
    left: 5%; top: 8%;
    width: 90%; height: 44%;
    border-radius: 5px;
    background: #070707;
    box-shadow: inset 0 0 10px #000, 0 0 0 1px #191919;
    padding-left: 4px;
    overflow: hidden;
}
.byte-keys i {
    float: left;
    width: 20px; height: 18px;
    margin: 2px;
    border-radius: 3px;
    background: #141414;
    box-shadow: 0 -2px 0 #040404, inset 0 0 2px rgba(30, 215, 96, 0.13);
}
.byte-keys i.is-fn { height: 9px; }
.byte-keys i.is-space { width: 142px; }
.byte-trackpad {
    position: absolute;
    left: 50%; top: 56%;
    width: 27%; height: 34%;
    margin-left: -13.5%;
    border-radius: 7px;
    background: #0d0d0d;
    box-shadow: inset 0 0 8px #000, 0 0 0 1px #1a1a1a;
}

/* --- the robot, emerging from the screen --- */
.byte-robot {
    position: absolute;
    z-index: 2;
    left: 50%;
    bottom: -28%;
    width: 114%;
    aspect-ratio: 1;
    margin-left: -57%;
    pointer-events: none;
    /* recolour Spline's purple diorama into ByteSub green */
    filter: hue-rotate(-132deg) saturate(1.35) brightness(1.05);
    /* fade the scene's baked-in floor away so only the robot emerges */
    -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 34%, rgba(0,0,0,0.35) 45%, transparent 54%);
    mask-image: linear-gradient(to bottom, #000 0%, #000 34%, rgba(0,0,0,0.35) 45%, transparent 54%);
    opacity: 0;
    transition: opacity 0.9s ease;
}
.byte-robot.is-ready { opacity: 1; }
.byte-robot spline-viewer { width: 100%; height: 100%; display: block; }

@media (max-width: 900px) {
    .byte-section { padding: 90px 20px; }
    .byte-stage {
        grid-template-columns: 1fr;
        gap: 28px;
    }
    .byte-laptop { max-width: 320px; margin: 0 auto; width: 100%; }
    .byte-fn-col {
        flex-direction: row; flex-wrap: wrap; justify-content: center;
        align-self: stretch; padding-top: 0; gap: 12px;
    }
    .byte-fn-col.is-left, .byte-fn-col.is-right { align-items: center; }
    .byte-fn-col.is-left .byte-fn:last-child,
    .byte-fn-col.is-right .byte-fn:last-child { margin: 0; }
    .byte-center { order: -1; }
    .byte-fn.is-top { margin-bottom: 96px; }
    .byte-fn { padding: 11px 16px; font-size: 0.82rem; }
}
@media (max-width: 480px) {
    .byte-term { font-size: 0.6rem; padding: 0 14px 12px; }
}
@media (prefers-reduced-motion: reduce) {
    .byte-term-bar i { animation: none; width: 72%; }
    .byte-robot { transition: none; }
}
