/* ============================================
   WhisperTray Landing Page
   Dark hero + mint green accent
   ============================================ */

:root {
    --mint-50: #f0fdf4;
    --mint-100: #dcfce7;
    --mint-200: #bbf7d0;
    --mint-300: #86efac;
    --mint-400: #4ade80;
    --mint-500: #22c55e;
    --mint-600: #16a34a;
    --mint-700: #15803d;
    --mint-800: #166534;
    --mint-900: #14532d;

    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    --gray-950: #030712;

    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --radius: 12px;
    --radius-lg: 20px;
    --shadow: 0 1px 3px rgba(0,0,0,0.1), 0 1px 2px rgba(0,0,0,0.06);
    --shadow-lg: 0 10px 40px rgba(0,0,0,0.12);
    --shadow-glow: 0 0 60px rgba(34,197,94,0.20);
}

/* ---- Reset & Base ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
    font-family: var(--font);
    color: var(--gray-800);
    background: #fff;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; }

.container {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ---- Navigation ---- */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: rgba(3, 7, 18, 0.75);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1.2rem;
    color: #fff;
}

.logo-img {
    width: 42px;
    height: 42px;
    border-radius: 10px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav-links a {
    font-size: 0.9rem;
    font-weight: 500;
    color: rgba(255,255,255,0.6);
    transition: color 0.2s;
}

.nav-links a:hover { color: #fff; }
.nav-links a.btn { color: #fff; }

/* ---- Buttons ---- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 0.9rem;
    background: var(--mint-500);
    color: #fff;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
}

.btn:hover {
    background: var(--mint-600);
    transform: translateY(-1px);
    box-shadow: var(--shadow);
}

.btn-lg {
    padding: 14px 28px;
    font-size: 1rem;
    border-radius: var(--radius);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.85rem;
    color: #fff;
}

.btn-outline {
    background: transparent;
    color: rgba(255,255,255,0.85);
    border: 1.5px solid rgba(255,255,255,0.2);
}

.btn-outline:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.35);
    color: #fff;
}

.btn-white {
    background: #fff;
    color: var(--mint-700);
}

.btn-white:hover {
    background: var(--mint-50);
}

/* ---- Hero Section ---- */
.hero {
    position: relative;
    padding: 160px 0 120px;
    min-height: 680px;
    background: #080f0c;
    overflow: hidden;
}

/* Dot grid background */
.hero-bg-grid {
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255,255,255,0.06) 1px, transparent 1px);
    background-size: 32px 32px;
    mask-image: radial-gradient(ellipse 80% 70% at 70% 50%, black 20%, transparent 70%);
    -webkit-mask-image: radial-gradient(ellipse 80% 70% at 70% 50%, black 20%, transparent 70%);
    pointer-events: none;
}

/* Ambient gradient orbs in hero background */
.hero-gradient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
}

.hero-gradient-orb-1 {
    width: 600px;
    height: 600px;
    top: -100px;
    right: -100px;
    background: radial-gradient(circle, rgba(34,197,94,0.12) 0%, transparent 70%);
    animation: orb-drift-1 12s ease-in-out infinite;
}

.hero-gradient-orb-2 {
    width: 400px;
    height: 400px;
    bottom: -80px;
    left: 10%;
    background: radial-gradient(circle, rgba(34,197,94,0.06) 0%, transparent 70%);
    animation: orb-drift-2 15s ease-in-out infinite;
}

@keyframes orb-drift-1 {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(-30px, 20px); }
}

@keyframes orb-drift-2 {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(20px, -15px); }
}

.hero .container {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.badge {
    display: inline-block;
    padding: 6px 14px;
    background: rgba(34,197,94,0.12);
    color: var(--mint-400);
    font-size: 0.8rem;
    font-weight: 600;
    border-radius: 100px;
    margin-bottom: 20px;
    border: 1px solid rgba(34,197,94,0.2);
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.12;
    color: #fff;
    margin-bottom: 24px;
    letter-spacing: -0.02em;
}

.gradient-text {
    background: linear-gradient(135deg, var(--mint-400), var(--mint-300));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.15rem;
    color: rgba(255,255,255,0.55);
    line-height: 1.7;
    margin-bottom: 32px;
    max-width: 520px;
}

.hero-actions {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
}

.hero-actions .btn:first-child {
    box-shadow: 0 0 20px rgba(34,197,94,0.3), 0 0 40px rgba(34,197,94,0.1);
}

.hero-actions .btn:first-child:hover {
    box-shadow: 0 0 24px rgba(34,197,94,0.4), 0 0 50px rgba(34,197,94,0.15);
}

/* Hotkey hint */
.hero-hotkey-hint {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
}

.key-cap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 12px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    color: rgba(255,255,255,0.7);
    font-family: var(--font);
    letter-spacing: 0.02em;
    box-shadow: 0 1px 2px rgba(0,0,0,0.3), inset 0 1px 0 rgba(255,255,255,0.05);
}

.key-plus {
    font-size: 0.75rem;
    color: rgba(255,255,255,0.3);
}

.key-label {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.35);
    margin-left: 4px;
}

.hero-note {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.3);
}

/* ---- Hero Visual (HUD centerpiece) ---- */
.hero-visual {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 380px;
}

/* Concentric rings */
.hud-ring {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}

.hud-ring-1 {
    width: 200px;
    height: 200px;
    border: 1.5px solid rgba(34, 197, 94, 0.18);
    animation: ring-pulse 4s ease-in-out infinite;
}

.hud-ring-2 {
    width: 300px;
    height: 300px;
    border: 1px dashed rgba(34, 197, 94, 0.10);
    animation: ring-pulse 4s ease-in-out infinite 1.3s;
}

.hud-ring-3 {
    width: 400px;
    height: 400px;
    border: 1px solid rgba(34, 197, 94, 0.06);
    animation: ring-pulse 4s ease-in-out infinite 2.6s;
}

@keyframes ring-pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.08);
        opacity: 0.4;
    }
}

/* Radial glow behind HUD */
.hud-glow {
    position: absolute;
    width: 400px;
    height: 280px;
    border-radius: 50%;
    background: radial-gradient(ellipse, rgba(34,197,94,0.30) 0%, rgba(34,197,94,0.10) 40%, transparent 70%);
    filter: blur(40px);
    pointer-events: none;
    animation: glow-breathe 3s ease-in-out infinite;
    z-index: 0;
}

@keyframes glow-breathe {
    0%, 100% { opacity: 0.6; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.1); }
}

/* Floating particles */
.particle {
    position: absolute;
    border-radius: 50%;
    background: var(--mint-400);
    opacity: 0;
    pointer-events: none;
}

.particle-1 {
    width: 4px; height: 4px;
    top: 12%; left: 18%;
    box-shadow: 0 0 6px rgba(34,197,94,0.6);
    animation: float-particle-up 7s ease-in-out infinite;
}
.particle-2 {
    width: 3px; height: 3px;
    top: 72%; left: 12%;
    box-shadow: 0 0 4px rgba(34,197,94,0.5);
    animation: float-particle-up 9s ease-in-out infinite 1.5s;
}
.particle-3 {
    width: 5px; height: 5px;
    top: 20%; right: 8%;
    box-shadow: 0 0 8px rgba(34,197,94,0.5);
    animation: float-particle-drift 8s ease-in-out infinite 2s;
}
.particle-4 {
    width: 3px; height: 3px;
    top: 82%; right: 22%;
    box-shadow: 0 0 4px rgba(34,197,94,0.5);
    animation: float-particle-up 6s ease-in-out infinite 0.5s;
}
.particle-5 {
    width: 2px; height: 2px;
    top: 48%; left: 4%;
    animation: float-particle-drift 10s ease-in-out infinite 3s;
}
.particle-6 {
    width: 3px; height: 3px;
    top: 8%; right: 35%;
    box-shadow: 0 0 6px rgba(34,197,94,0.4);
    animation: float-particle-up 8s ease-in-out infinite 4s;
}
.particle-7 {
    width: 6px; height: 6px;
    top: 55%; left: 32%;
    box-shadow: 0 0 10px rgba(34,197,94,0.4);
    animation: float-particle-drift 11s ease-in-out infinite 1s;
}
.particle-8 {
    width: 2px; height: 2px;
    top: 38%; right: 4%;
    animation: float-particle-up 7s ease-in-out infinite 5.5s;
}

@keyframes float-particle-up {
    0% { opacity: 0; transform: translateY(0) translateX(0); }
    20% { opacity: 0.7; }
    50% { opacity: 0.4; transform: translateY(-30px) translateX(8px); }
    80% { opacity: 0.7; }
    100% { opacity: 0; transform: translateY(-5px) translateX(0); }
}

@keyframes float-particle-drift {
    0% { opacity: 0; transform: translate(0, 0); }
    20% { opacity: 0.6; }
    50% { opacity: 0.3; transform: translate(15px, -20px); }
    80% { opacity: 0.6; }
    100% { opacity: 0; transform: translate(0, 0); }
}

/* Sound wave lines */
.wave-lines {
    position: absolute;
    width: 60px;
    height: 200px;
    pointer-events: none;
    z-index: 1;
}

.wave-lines-left {
    left: 0;
    top: 50%;
    transform: translateY(-50%);
}

.wave-lines-right {
    right: 0;
    top: 50%;
    transform: translateY(-50%);
}

/* Accent line under HUD */
.hud-accent-line {
    position: absolute;
    bottom: 60px;
    width: 180px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(34,197,94,0.3), transparent);
    z-index: 4;
}

/* HUD label */
.hud-label {
    position: absolute;
    bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.7rem;
    font-weight: 500;
    color: rgba(255,255,255,0.40);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    z-index: 4;
}

.hud-label-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--mint-500);
    animation: label-dot-pulse 2s ease-in-out infinite;
    box-shadow: 0 0 8px rgba(34,197,94,0.6);
}

@keyframes label-dot-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

/* HUD Canvas Container */
.hud-canvas-container {
    position: relative;
    z-index: 3;
    display: flex;
    justify-content: center;
    align-items: center;
    transform: scale(1.1);
}

.hud-canvas-container canvas {
    display: block;
    box-shadow:
        0 0 40px rgba(34, 197, 94, 0.25),
        0 0 80px rgba(34, 197, 94, 0.12),
        0 0 120px rgba(34, 197, 94, 0.06),
        0 8px 32px rgba(0, 0, 0, 0.5);
}

/* Reflection below HUD */
.hud-reflection {
    position: absolute;
    bottom: 0;
    width: 260px;
    height: 60px;
    background: radial-gradient(ellipse at center, rgba(34,197,94,0.15) 0%, transparent 70%);
    filter: blur(16px);
    pointer-events: none;
    z-index: 1;
    transform: translateY(50px);
}

/* Thin shadow band at the bottom of the hero to ease the hard cut to white */
.hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 80px;
    background: linear-gradient(to bottom, transparent, rgba(0,0,0,0.35));
    pointer-events: none;
    z-index: 1;
}

/* ---- Features Section ---- */
.features {
    padding: 100px 0 80px;
    scroll-margin-top: 64px;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-header h2 {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--gray-900);
    margin-bottom: 12px;
}

.section-header p {
    font-size: 1.1rem;
    color: var(--gray-500);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.feature-card {
    padding: 32px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--gray-100);
    transition: all 0.3s;
}

.feature-card:hover {
    border-color: var(--mint-200);
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: var(--mint-50);
    color: var(--mint-600);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.feature-card h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.feature-card p {
    font-size: 0.9rem;
    color: var(--gray-500);
    line-height: 1.6;
}

/* ---- Demo Section ---- */
.demo {
    padding: 80px 0;
    background: var(--gray-50);
    scroll-margin-top: 64px;
}

.video-wrapper {
    max-width: 800px;
    margin: 0 auto;
}

.video-container {
    position: relative;
    aspect-ratio: 16/9;
    background: var(--gray-900);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.video-container video {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.video-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.3);
    cursor: pointer;
    transition: background 0.3s;
}

.video-overlay:hover {
    background: rgba(0, 0, 0, 0.15);
}

.play-button {
    color: #fff;
    opacity: 0.9;
    transition: all 0.3s;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.4));
}

.video-overlay:hover .play-button {
    opacity: 1;
    transform: scale(1.1);
}

/* ---- How It Works ---- */
.how-it-works {
    padding: 100px 0;
}

.steps {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 16px;
}

.step {
    text-align: center;
    flex: 0 1 260px;
}

.step-number {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--mint-500);
    color: #fff;
    font-size: 1.3rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.step h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.step p {
    font-size: 0.9rem;
    color: var(--gray-500);
    line-height: 1.6;
}

.step-arrow {
    color: var(--gray-300);
    margin-top: 20px;
    flex-shrink: 0;
}

/* ---- Download Section ---- */
.download {
    padding: 80px 0 100px;
    scroll-margin-top: 64px;
}

.download-card {
    background: linear-gradient(135deg, var(--mint-600), var(--mint-800));
    border-radius: var(--radius-lg);
    padding: 64px;
    text-align: center;
    color: #fff;
    box-shadow: 0 20px 60px rgba(22,163,74,0.35);
}

.download-card h2 {
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 16px;
}

.download-card p {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 32px;
    line-height: 1.7;
}

.download-meta {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 16px;
    font-size: 0.85rem;
    opacity: 0.7;
}

.github-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 24px;
    font-size: 0.9rem;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.github-link:hover { opacity: 1; }

/* ---- Footer ---- */
.footer {
    padding: 32px 0;
    border-top: 1px solid var(--gray-100);
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: var(--gray-400);
}

.footer a {
    color: var(--mint-600);
    text-decoration: underline;
}

/* ---- Responsive ---- */
@media (max-width: 900px) {
    .hero .container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-subtitle { margin: 0 auto 32px; }
    .hero-actions { justify-content: center; }
    .hero-hotkey-hint { justify-content: center; }
    .hero-note { text-align: center; }
    .hero-visual { margin-top: 40px; }

    .hud-ring-3 { display: none; }

    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .hero { padding: 120px 0 80px; }
    .hero h1 { font-size: 2.2rem; }

    .hero-visual {
        min-height: 240px;
    }

    .hud-canvas-container {
        transform: scale(0.9);
    }

    .hud-ring-2, .hud-ring-3 { display: none; }

    .wave-lines { display: none; }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .steps {
        flex-direction: column;
        align-items: center;
    }

    .step-arrow {
        transform: rotate(90deg);
        margin: 0;
    }

    .download-card {
        padding: 40px 24px;
    }

    .hero-actions {
        flex-direction: column;
        align-items: center;
    }

    .nav-links a:not(.btn) {
        display: none;
    }

    .footer-inner {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }
}

/* Respect reduced-motion preferences (added in the move to dobromirdikov.com). */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
