/* ============================================================
   HHPoker德扑圈 - Landing Page Style
   Theme: Modern Gradient Tech (蓝紫科技渐变)
   ============================================================ */

/* ---------- CSS Variables / Theme ---------- */
:root {
    --primary: #1a56db;
    --primary-dark: #1e40af;
    --accent: #7c3aed;
    --accent-dark: #6d28d9;
    --gradient: linear-gradient(135deg, var(--primary), var(--accent));
    --gradient-reverse: linear-gradient(135deg, var(--accent), var(--primary));
    --dark: #1e1b4b;
    --text: #1f2937;
    --text-muted: #6b7280;
    --white: #ffffff;
    --bg: #f9fafb;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08), 0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.12), 0 4px 12px rgba(0, 0, 0, 0.06);
    --shadow-xl: 0 20px 48px rgba(0, 0, 0, 0.16), 0 8px 24px rgba(0, 0, 0, 0.08);
    --radius-sm: 0.5rem;
    --radius-md: 0.75rem;
    --radius-lg: 1rem;
    --radius-xl: 1.5rem;
    --radius-full: 9999px;
    --transition: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* ---------- Base & Smooth Scroll ---------- */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 5rem;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', 'Helvetica Neue', sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
    background-color: var(--bg);
    color: var(--text);
}

/* Selection */
::selection {
    background: rgba(26, 86, 219, 0.2);
    color: var(--primary);
}

/* ---------- Navbar ---------- */
#navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: var(--shadow-md);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--gradient);
    border-radius: 2px;
    transition: all var(--transition);
    transform: translateX(-50%);
}

.nav-link:hover::after {
    width: 100%;
}

/* Hamburger Menu Bars Animation */
#menu-toggle.active .menu-bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

#menu-toggle.active .menu-bar:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

#menu-toggle.active .menu-bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Mobile Menu */
#mobile-menu {
    animation: slideDown 0.3s ease;
}

#mobile-menu.hidden {
    display: none;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ---------- Feature Cards ---------- */
.feature-card {
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gradient);
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
    transform: scaleX(0);
    transform-origin: center;
    transition: transform var(--transition-slow);
}

.feature-card:hover::before {
    transform: scaleX(1);
}

/* ---------- Stats Counters ---------- */
.stat-item {
    transform: translateY(0);
    transition: transform var(--transition-slow), background var(--transition-slow), box-shadow var(--transition-slow);
}

.stat-item:hover {
    transform: translateY(-6px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

/* ---------- Testimonial Cards ---------- */
.testimonial-card {
    position: relative;
    overflow: hidden;
}

.testimonial-card::after {
    content: '\201C';
    position: absolute;
    top: 16px;
    right: 24px;
    font-size: 4rem;
    line-height: 1;
    font-family: Georgia, serif;
    color: rgba(26, 86, 219, 0.08);
    pointer-events: none;
}

/* ---------- FAQ Accordion ---------- */
.faq-item {
    transition: box-shadow var(--transition), background var(--transition);
}

.faq-item:hover {
    box-shadow: var(--shadow-md);
}

.faq-toggle {
    cursor: pointer;
    background: none;
    border: none;
    outline: none;
    font-family: inherit;
}

.faq-toggle:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: -2px;
    border-radius: var(--radius-lg);
}

.faq-icon {
    transition: transform var(--transition);
}

.faq-item.active .faq-icon {
    transform: rotate(180deg);
}

.faq-content {
    animation: fadeInDown 0.35s ease;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-8px);
        max-height: 0;
    }
    to {
        opacity: 1;
        transform: translateY(0);
        max-height: 500px;
    }
}

/* ---------- CTA Section Decorative Shapes ---------- */
#download::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.06) 0%, transparent 60%),
                radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.04) 0%, transparent 50%);
    pointer-events: none;
}

/* ---------- Footer ---------- */
footer a {
    text-decoration: none;
}

/* ---------- Scroll Reveal Animation ---------- */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* ---------- Pulse animation for CTA buttons ---------- */
@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(124, 58, 237, 0.4);
    }
    50% {
        box-shadow: 0 0 0 12px rgba(124, 58, 237, 0);
    }
}

.pulse-glow {
    animation: pulse-glow 2.5s infinite;
}

/* ---------- Floating animation for hero image ---------- */
@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-12px);
    }
}

.hero-image-float {
    animation: float 5s ease-in-out infinite;
}

/* ---------- Gradient text utility ---------- */
.gradient-text {
    background: var(--gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ---------- Custom scrollbar ---------- */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--primary), var(--accent));
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, var(--primary-dark), var(--accent-dark));
}

/* ---------- Responsive Tweaks ---------- */
@media (max-width: 1023px) {
    html {
        scroll-padding-top: 4rem;
    }

    .feature-card::before {
        height: 2px;
    }
}

@media (max-width: 767px) {
    .stat-item {
        padding: 1.5rem 1rem;
    }

    .stat-item .text-4xl,
    .stat-item .text-5xl,
    .stat-item .text-6xl {
        font-size: 2rem;
    }

    .testimonial-card::after {
        font-size: 3rem;
    }
}

@media (max-width: 639px) {
    #home h1 {
        font-size: 2.25rem;
    }

    #home .text-lg {
        font-size: 1rem;
    }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .feature-card,
    .stat-item,
    .testimonial-card {
        transition: none;
    }

    .hero-image-float {
        animation: none;
    }
}

/* ---------- Focus styles for accessibility ---------- */
a:focus-visible,
button:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
    border-radius: 4px;
}

/* ---------- Print styles ---------- */
@media print {
    #navbar,
    #mobile-menu,
    footer,
    #download {
        display: none;
    }

    body {
        background: white;
        color: black;
    }

    section {
        page-break-inside: avoid;
    }
}
