/* ============================================================
   HHpoker / 德扑圈 — Zen Rock Garden Theme
   Custom Styles: FAQ Accordion, Scroll Animations, etc.
   ============================================================ */

/* ---- BASE ---- */
html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Noto Serif SC', system-ui, serif;
}

/* ---- CUSTOM SCROLLBAR ---- */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: #f2ece3;
}
::-webkit-scrollbar-thumb {
    background: #c4b8a8;
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: #9c8c7c;
}

/* ---- NAVBAR SHADOW ON SCROLL ---- */
.navbar-scrolled {
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.06);
}

/* ---- HERO OVERLAY ---- */
.hero-overlay {
    background: linear-gradient(
        to bottom,
        rgba(31, 28, 26, 0.55) 0%,
        rgba(31, 28, 26, 0.35) 50%,
        rgba(31, 28, 26, 0.65) 100%
    );
}

/* ---- SCROLL-REVEAL ANIMATIONS ---- */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.22, 0.61, 0.36, 1),
                transform 0.8s cubic-bezier(0.22, 0.61, 0.36, 1);
}
.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 0.7s cubic-bezier(0.22, 0.61, 0.36, 1) 0.1s,
                transform 0.7s cubic-bezier(0.22, 0.61, 0.36, 1) 0.1s;
}
.reveal-left.revealed {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(40px);
    transition: opacity 0.7s cubic-bezier(0.22, 0.61, 0.36, 1) 0.1s,
                transform 0.7s cubic-bezier(0.22, 0.61, 0.36, 1) 0.1s;
}
.reveal-right.revealed {
    opacity: 1;
    transform: translateX(0);
}

.reveal-scale {
    opacity: 0;
    transform: scale(0.92);
    transition: opacity 0.7s cubic-bezier(0.22, 0.61, 0.36, 1),
                transform 0.7s cubic-bezier(0.22, 0.61, 0.36, 1);
}
.reveal-scale.revealed {
    opacity: 1;
    transform: scale(1);
}

/* Staggered delay classes */
.delay-100 { transition-delay: 0.1s; }
.delay-200 { transition-delay: 0.2s; }
.delay-300 { transition-delay: 0.3s; }
.delay-400 { transition-delay: 0.4s; }
.delay-500 { transition-delay: 0.5s; }

/* ---- COUNTER ANIMATION ---- */
.counter-value {
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum";
}

/* ---- FEATURE CARDS ---- */
.feature-card {
    transition: transform 0.35s cubic-bezier(0.22, 0.61, 0.36, 1),
                box-shadow 0.35s cubic-bezier(0.22, 0.61, 0.36, 1);
}
.feature-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 40px -12px rgba(31, 28, 26, 0.15);
}

.feature-icon-wrapper {
    transition: background-color 0.35s ease;
}
.feature-card:hover .feature-icon-wrapper {
    background-color: #3c3733;
}

/* ---- TESTIMONIAL CARDS ---- */
.testimonial-card {
    transition: transform 0.35s cubic-bezier(0.22, 0.61, 0.36, 1),
                box-shadow 0.35s cubic-bezier(0.22, 0.61, 0.36, 1);
}
.testimonial-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 32px -8px rgba(31, 28, 26, 0.12);
}

/* ---- FAQ ACCORDION ---- */
.faq-accordion {
    border-bottom: 1px solid #d4c8b4;
}

.faq-question {
    cursor: pointer;
    user-select: none;
    position: relative;
    padding: 1.25rem 3rem 1.25rem 0;
    font-size: 1rem;
    font-weight: 500;
    color: #3c3733;
    transition: color 0.25s ease;
    line-height: 1.6;
}
.faq-question:hover {
    color: #1f1c1a;
}
.faq-question::after {
    content: '\f107';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    right: 0.5rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.1rem;
    color: #9c8c7c;
    transition: transform 0.35s cubic-bezier(0.22, 0.61, 0.36, 1),
                color 0.25s ease;
}
.faq-question.active {
    color: #1f1c1a;
}
.faq-question.active::after {
    transform: translateY(-50%) rotate(180deg);
    color: #5c5550;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.45s cubic-bezier(0.22, 0.61, 0.36, 1),
                padding 0.45s cubic-bezier(0.22, 0.61, 0.36, 1);
    padding: 0;
}
.faq-answer.open {
    max-height: 300px;
    padding-bottom: 1.25rem;
}

.faq-answer-content {
    font-size: 0.95rem;
    line-height: 1.8;
    color: #5c5550;
    padding-right: 1.5rem;
}

/* ---- CTA PULSE ---- */
.cta-pulse {
    animation: ctaPulse 2.5s ease-in-out infinite;
}
@keyframes ctaPulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(92, 85, 80, 0.4);
    }
    50% {
        box-shadow: 0 0 0 16px rgba(92, 85, 80, 0);
    }
}

/* ---- FLOATING BUTTONS ---- */
#back-to-top.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.floating-btn-hover {
    transition: all 0.3s cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* ---- STAT COUNTER CARD ---- */
.stat-card {
    transition: transform 0.3s ease;
}
.stat-card:hover {
    transform: translateY(-3px);
}

/* ---- CONTACT FORM ---- */
.form-input {
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
    background-color: #faf7f2;
    border: 1px solid #d4c8b4;
}
.form-input:focus {
    outline: none;
    border-color: #5c5550;
    box-shadow: 0 0 0 3px rgba(92, 85, 80, 0.08);
    background-color: #fff;
}

/* ---- PAGE HERO (non-home) ---- */
.page-hero {
    background: linear-gradient(135deg, #f2ece3 0%, #e8ddd0 50%, #d4c8b4 100%);
}

/* ---- DIVIDER ---- */
.zen-divider {
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #c4b8a8, #5c5550);
    margin: 0 auto;
    border-radius: 2px;
}

/* ---- ABOUT PAGE TIMELINE ---- */
.timeline-line {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    background: linear-gradient(180deg, #e8ddd0, #c4b8a8, #e8ddd0);
}

/* ---- RESPONSIVE ---- */
@media (max-width: 768px) {
    .faq-question {
        font-size: 0.95rem;
        padding: 1rem 2.5rem 1rem 0;
    }
    .faq-answer-content {
        font-size: 0.9rem;
    }
}

@media (max-width: 640px) {
    #cs-float-btn,
    #back-to-top {
        width: 3rem;
        height: 3rem;
        bottom: 1.25rem;
        right: 1rem;
    }
    #cs-float-btn {
        bottom: 5rem;
    }
    .faq-question {
        font-size: 0.9rem;
    }
}
