/* ========================================
   PC预测网 - 自定义样式表
   ======================================== */

/* ---------- Smooth Scroll ---------- */
html {
    scroll-behavior: smooth;
}

/* ---------- Custom Scrollbar ---------- */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
    background: linear-gradient(to bottom, #6366f1, #4338ca);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(to bottom, #4f46e5, #3730a3);
}

/* ---------- Navbar Scroll Effect ---------- */
#navbar.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

/* ---------- Active Nav Link ---------- */
.nav-link.active {
    color: #4f46e5;
    background-color: #eef2ff;
}

/* ---------- Feature Card Hover ---------- */
.feature-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.feature-card:hover {
    transform: translateY(-4px);
}

/* ---------- FAQ Accordion ---------- */
.faq-item .faq-toggle {
    cursor: pointer;
    user-select: none;
}
.faq-item.active .faq-icon {
    transform: rotate(180deg);
    color: #4f46e5;
}
.faq-item.active {
    border-color: #c7d2fe;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.08);
}
.faq-content {
    animation: fadeSlideDown 0.35s ease-out;
}

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

/* ---------- Floating Animation ---------- */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}
.animate-float {
    animation: float 4s ease-in-out infinite;
}

@keyframes floatDelayed {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}
.animate-float-delayed {
    animation: floatDelayed 4.5s ease-in-out 0.5s infinite;
}

/* ---------- Stats Counter ---------- */
.stat-number {
    font-variant-numeric: tabular-nums;
}

/* ---------- Back to Top Button ---------- */
#backToTop.visible {
    opacity: 1;
    visibility: visible;
}

/* ---------- Selection Color ---------- */
::selection {
    background-color: #c7d2fe;
    color: #312e81;
}

/* ---------- Responsive Adjustments ---------- */
@media (max-width: 640px) {
    .feature-card:hover {
        transform: translateY(-2px);
    }
}
