/* ============================================
   HHPOKER 联盟 - Gaming Tournament Dark Theme
   Indigo-900 + Amber/Gold Glowing Accents
   ============================================ */

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

/* ---- Navbar scroll effect ---- */
.navbar-scrolled {
    background: rgba(15, 23, 42, 0.97) !important;
    backdrop-filter: blur(24px) !important;
    border-bottom: 1px solid rgba(251, 191, 36, 0.1) !important;
}

/* ---- Hamburger menu ---- */
#mobile-menu { max-height: 0; overflow: hidden; transition: max-height 0.4s ease; }
#mobile-menu.open { max-height: 400px; }

/* ---- Glow text for hero ---- */
.glow-text {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 30%, #fcd34d 60%, #fbbf24 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 30px rgba(251, 191, 36, 0.4));
    animation: glowPulse 3s ease-in-out infinite;
}
@keyframes glowPulse {
    0%, 100% { filter: drop-shadow(0 0 20px rgba(251, 191, 36, 0.3)); }
    50% { filter: drop-shadow(0 0 40px rgba(251, 191, 36, 0.6)); }
}

/* ---- Hero background ---- */
.hero-dark {
    background: radial-gradient(ellipse at 50% 0%, #1e1b4b 0%, #0f172a 50%, #020617 100%);
    position: relative;
    overflow: hidden;
}
.hero-dark::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 400px;
    background: radial-gradient(ellipse, rgba(251, 191, 36, 0.08) 0%, transparent 70%);
    pointer-events: none;
}
.hero-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(251, 191, 36, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(251, 191, 36, 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    pointer-events: none;
    mask-image: radial-gradient(ellipse at 50% 30%, black 30%, transparent 70%);
}

/* ---- Bracket-style feature cards ---- */
.bracket-card {
    background: linear-gradient(135deg, #1e293b, #0f172a);
    border: 1px solid #1e293b;
    border-radius: 16px;
    padding: 32px;
    position: relative;
    transition: all 0.4s ease;
    overflow: hidden;
}
.bracket-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #fbbf24, transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}
.bracket-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #fbbf24, transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}
.bracket-card .bracket-left,
.bracket-card .bracket-right {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 30px;
    background: #fbbf24;
    border-radius: 3px;
    opacity: 0;
    transition: all 0.4s ease;
}
.bracket-card .bracket-left { left: 8px; }
.bracket-card .bracket-right { right: 8px; }
.bracket-card:hover {
    transform: translateY(-8px);
    border-color: rgba(251, 191, 36, 0.3);
    box-shadow: 0 20px 50px rgba(251, 191, 36, 0.1), 0 0 30px rgba(251, 191, 36, 0.05);
}
.bracket-card:hover::before,
.bracket-card:hover::after { opacity: 1; }
.bracket-card:hover .bracket-left,
.bracket-card:hover .bracket-right { opacity: 1; }
.bracket-card:hover .bracket-icon {
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    color: #0f172a;
    box-shadow: 0 0 20px rgba(251, 191, 36, 0.4);
}
.bracket-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: rgba(251, 191, 36, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #fbbf24;
    transition: all 0.4s ease;
    margin-bottom: 20px;
}

/* ---- Leaderboard table ---- */
.leaderboard-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 8px;
}
.leaderboard-table th {
    text-align: left;
    padding: 12px 16px;
    color: #94a3b8;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
}
.leaderboard-table td {
    padding: 16px;
    background: linear-gradient(135deg, #1e293b, #0f172a);
    border: 1px solid #1e293b;
    color: #e2e8f0;
    font-size: 0.95rem;
}
.leaderboard-table tr td:first-child { border-radius: 10px 0 0 10px; }
.leaderboard-table tr td:last-child { border-radius: 0 10px 10px 0; }
.leaderboard-table .rank-1 td { border-color: rgba(251, 191, 36, 0.4); background: linear-gradient(135deg, #2d2410, #1a1a0a); }
.leaderboard-table .rank-2 td { border-color: rgba(148, 163, 184, 0.3); background: linear-gradient(135deg, #1e293b, #1a1e2a); }
.leaderboard-table .rank-3 td { border-color: rgba(180, 83, 9, 0.3); background: linear-gradient(135deg, #2d1a0a, #1a1208); }

.rank-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    font-weight: 700;
    font-size: 0.8rem;
}
.rank-1-badge { background: #fbbf24; color: #0f172a; }
.rank-2-badge { background: #94a3b8; color: #0f172a; }
.rank-3-badge { background: #b45309; color: #fff; }

/* ---- Stats counters ---- */
.stat-glow {
    font-size: 3rem;
    font-weight: 900;
    background: linear-gradient(180deg, #fbbf24, #d97706);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 15px rgba(251, 191, 36, 0.3));
}

/* ---- Card containers ---- */
.card-dark {
    background: linear-gradient(135deg, #1e293b, #0f172a);
    border: 1px solid #1e293b;
    border-radius: 16px;
    padding: 28px;
    transition: all 0.35s ease;
}
.card-dark:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(0,0,0,0.4);
    border-color: rgba(251, 191, 36, 0.2);
}

/* ---- FAQ accordion ---- */
.faq-item {
    border-bottom: 1px solid #1e293b;
    overflow: hidden;
}
.faq-question {
    cursor: pointer;
    padding: 20px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    font-size: 1.05rem;
    color: #e2e8f0;
    transition: color 0.3s;
    user-select: none;
}
.faq-question:hover { color: #fbbf24; }
.faq-question i { transition: transform 0.4s ease; color: #fbbf24; }
.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.4s ease;
    color: #94a3b8;
    line-height: 1.7;
}
.faq-item.active .faq-answer { max-height: 300px; padding-bottom: 20px; }
.faq-item.active .faq-question i { transform: rotate(180deg); }
.faq-item.active .faq-question { color: #fbbf24; }

/* ---- CTA ---- */
.cta-dark {
    background: linear-gradient(135deg, #1e1b4b, #312e81, #1e1b4b);
    border-radius: 24px;
    border: 1px solid rgba(251, 191, 36, 0.2);
    position: relative;
    overflow: hidden;
}
.cta-dark::after {
    content: '';
    position: absolute;
    right: -60px;
    top: -60px;
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, rgba(251, 191, 36, 0.1), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

/* ---- Page hero (sub-pages) ---- */
.page-hero {
    background: linear-gradient(180deg, #1e1b4b, #0f172a);
    position: relative;
    overflow: hidden;
}
.page-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 200px;
    background: radial-gradient(ellipse, rgba(251, 191, 36, 0.06), transparent 70%);
    pointer-events: none;
}

/* ---- Contact form ---- */
.form-input {
    width: 100%;
    padding: 14px 18px;
    background: #1e293b;
    border: 1px solid #334155;
    border-radius: 12px;
    color: #e2e8f0;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    outline: none;
}
.form-input:focus { border-color: #fbbf24; box-shadow: 0 0 0 3px rgba(251, 191, 36, 0.1); }
.form-input::placeholder { color: #64748b; }

@media (max-width: 768px) {
    .stat-glow { font-size: 2rem; }
    .leaderboard-table { font-size: 0.8rem; }
    .leaderboard-table th, .leaderboard-table td { padding: 10px 8px; }
    .cta-dark { border-radius: 16px; padding: 32px 20px !important; }
}