/* ============================================
   Houston Roleplay — Design System & Styles
   ============================================ */

/* --- CSS Variables --- */
:root {
    /* Colors */
    --bg-primary: #0a0a14;
    --bg-secondary: #0d0d1a;
    --bg-card: rgba(15, 15, 30, 0.7);
    --bg-card-hover: rgba(20, 20, 40, 0.85);

    --text-primary: #f0f0f5;
    --text-secondary: #8888aa;
    --text-muted: #555577;

    --accent-purple: #a855f7;
    --accent-cyan: #06d6e0;
    --accent-blue: #3b82f6;
    --accent-pink: #e879f9;

    --gradient-primary: linear-gradient(135deg, #a855f7, #06d6e0);
    --gradient-hero: linear-gradient(135deg, rgba(168, 85, 247, 0.15), rgba(6, 214, 224, 0.08));
    --gradient-card: linear-gradient(135deg, rgba(168, 85, 247, 0.05), rgba(6, 214, 224, 0.03));

    --border-color: rgba(136, 136, 170, 0.12);
    --border-glow: rgba(168, 85, 247, 0.3);

    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 8px 32px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 16px 64px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 40px rgba(168, 85, 247, 0.15);

    /* Typography */
    --font-display: 'Orbitron', sans-serif;
    --font-body: 'Inter', sans-serif;

    /* Spacing */
    --section-padding: 120px 0;
    --container-max: 1200px;

    /* Transitions */
    --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- Reset & Base --- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* --- Particles Canvas --- */
#particles-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

/* --- Utility Classes --- */
.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 24px;
}

.text-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 32px;
    border-radius: 12px;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    border: none;
    transition: var(--transition-base);
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.1), transparent);
    opacity: 0;
    transition: var(--transition-base);
}

.btn:hover::before {
    opacity: 1;
}

.btn-primary {
    background: var(--gradient-primary);
    color: #fff;
    box-shadow: 0 4px 20px rgba(168, 85, 247, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(168, 85, 247, 0.5);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--accent-purple);
    transform: translateY(-2px);
}

.btn-discord {
    background: #5865F2;
    color: #fff;
    box-shadow: 0 4px 20px rgba(88, 101, 242, 0.3);
    width: 100%;
    justify-content: center;
    padding: 16px;
    border-radius: 12px;
    font-size: 1rem;
}

.btn-discord:hover {
    background: #4752c4;
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(88, 101, 242, 0.5);
}

.btn-large {
    padding: 18px 48px;
    font-size: 1.1rem;
    border-radius: 14px;
}

/* ============================================
   NAVBAR
   ============================================ */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 16px 0;
    transition: var(--transition-base);
}

.navbar.scrolled {
    background: rgba(10, 10, 20, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    padding: 10px 0;
}

.nav-container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 1001;
}

.logo-icon {
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gradient-primary);
    border-radius: 10px;
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.2rem;
    color: #fff;
}

.logo-text {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.1rem;
    letter-spacing: 2px;
    color: var(--text-primary);
}

.logo-accent {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 8px;
}

.nav-link {
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: var(--transition-fast);
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary);
    background: rgba(168, 85, 247, 0.1);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 2px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 2px;
    background: var(--gradient-primary);
    border-radius: 1px;
}

.nav-cta {
    padding: 10px 24px;
    background: var(--gradient-primary);
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.9rem;
    color: #fff;
    transition: var(--transition-base);
}

.nav-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 20px rgba(168, 85, 247, 0.4);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
}

.nav-toggle span {
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: var(--transition-base);
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-bg-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.4) saturate(1.2);
    animation: heroZoom 30s ease-in-out infinite alternate;
}

@keyframes heroZoom {
    from { transform: scale(1); }
    to { transform: scale(1.08); }
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(10,10,20,0.5) 0%, rgba(10,10,20,0.3) 40%, rgba(10,10,20,0.7) 80%, var(--bg-primary) 100%),
        radial-gradient(ellipse at 30% 50%, rgba(168,85,247,0.12) 0%, transparent 60%),
        radial-gradient(ellipse at 70% 50%, rgba(6,214,224,0.08) 0%, transparent 60%);
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 800px;
    padding: 0 24px;
    animation: fadeUp 1s ease-out;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 20px;
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 500;
    color: #10b981;
    margin-bottom: 32px;
    animation: fadeUp 1s ease-out 0.2s backwards;
}

.badge-dot {
    width: 8px;
    height: 8px;
    background: #10b981;
    border-radius: 50%;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4); }
    50% { opacity: 0.8; box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
}

.hero-title {
    margin-bottom: 24px;
    animation: fadeUp 1s ease-out 0.3s backwards;
}

.title-line {
    display: block;
    font-family: var(--font-display);
    font-weight: 900;
    letter-spacing: 6px;
    line-height: 1.1;
}

.title-line:first-child {
    font-size: clamp(2.5rem, 8vw, 5rem);
    color: var(--text-primary);
    text-shadow: 0 0 60px rgba(168, 85, 247, 0.3);
}

.title-line.accent {
    font-size: clamp(2.8rem, 9vw, 5.5rem);
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 30px rgba(168, 85, 247, 0.3));
}

.hero-subtitle {
    font-size: 1.15rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 40px;
    line-height: 1.7;
    animation: fadeUp 1s ease-out 0.4s backwards;
}

.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 60px;
    animation: fadeUp 1s ease-out 0.5s backwards;
}

.hero-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 40px;
    padding: 24px 40px;
    background: rgba(15, 15, 30, 0.6);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    animation: fadeUp 1s ease-out 0.6s backwards;
}

.stat-item {
    text-align: center;
}

.stat-number {
    display: block;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.8rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.stat-divider {
    width: 1px;
    height: 40px;
    background: var(--border-color);
}

.hero-scroll {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    z-index: 2;
    animation: fadeUp 1s ease-out 0.8s backwards;
}

.hero-scroll span {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 2px;
}

.scroll-line {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, var(--accent-purple), transparent);
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
    0%, 100% { opacity: 1; height: 40px; }
    50% { opacity: 0.5; height: 24px; }
}

/* ============================================
   SECTION COMMON STYLES
   ============================================ */
.section {
    position: relative;
    z-index: 1;
    padding: var(--section-padding);
}

.section-header {
    text-align: center;
    margin-bottom: 72px;
}

.section-tag {
    display: inline-block;
    padding: 6px 18px;
    background: rgba(168, 85, 247, 0.1);
    border: 1px solid rgba(168, 85, 247, 0.2);
    border-radius: 50px;
    font-family: var(--font-display);
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent-purple);
    letter-spacing: 3px;
    margin-bottom: 20px;
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 800;
    letter-spacing: 2px;
    margin-bottom: 16px;
}

.section-desc {
    font-size: 1.05rem;
    color: var(--text-secondary);
    max-width: 560px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ============================================
   COMMUNITY SECTION
   ============================================ */
.section-community {
    background:
        radial-gradient(ellipse at 20% 50%, rgba(88, 101, 242, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 50%, rgba(168, 85, 247, 0.04) 0%, transparent 50%),
        var(--bg-primary);
}

.community-grid {
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 32px;
    align-items: start;
}

.discord-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 32px;
    backdrop-filter: blur(10px);
    transition: var(--transition-base);
}

.discord-card:hover {
    border-color: rgba(88, 101, 242, 0.3);
    box-shadow: 0 0 40px rgba(88, 101, 242, 0.1);
}

.discord-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 28px;
}

.discord-icon {
    color: #5865F2;
}

.discord-header h3 {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: 1px;
}

.discord-status {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.status-dot.online {
    background: #23a55a;
    box-shadow: 0 0 8px rgba(35, 165, 90, 0.5);
}

.discord-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 24px;
}

.discord-stat {
    background: rgba(88, 101, 242, 0.08);
    border-radius: 12px;
    padding: 16px;
    text-align: center;
}

.discord-stat-number {
    display: block;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.5rem;
    color: #5865F2;
    margin-bottom: 4px;
}

.discord-stat-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.features-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 28px;
    transition: var(--transition-base);
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transition: var(--transition-base);
    transform-origin: left;
}

.feature-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-glow);
    transform: translateY(-4px);
    box-shadow: var(--shadow-glow);
}

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

.feature-icon {
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(168, 85, 247, 0.1);
    border-radius: 12px;
    color: var(--accent-purple);
    margin-bottom: 16px;
}

.feature-card h3 {
    font-family: var(--font-display);
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

.feature-card p {
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ============================================
   RULES SECTION
   ============================================ */
.section-rules {
    background:
        radial-gradient(ellipse at 50% 0%, rgba(168, 85, 247, 0.06) 0%, transparent 50%),
        var(--bg-secondary);
}

.rules-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.rule-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 32px;
    transition: var(--transition-base);
    position: relative;
    overflow: hidden;
}

.rule-card::after {
    content: attr(data-number);
    position: absolute;
    top: -10px;
    right: -5px;
    font-family: var(--font-display);
    font-size: 6rem;
    font-weight: 900;
    color: rgba(168, 85, 247, 0.04);
    line-height: 1;
    pointer-events: none;
}

.rule-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-glow);
    transform: translateY(-4px);
    box-shadow: var(--shadow-glow);
}

.rule-number {
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 900;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 16px;
}

.rule-card h3 {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

.rule-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ============================================
   STAFF SECTION
   ============================================ */
.section-staff {
    background:
        radial-gradient(ellipse at 70% 50%, rgba(6, 214, 224, 0.04) 0%, transparent 50%),
        var(--bg-primary);
}

.staff-showcase {
    display: flex;
    flex-direction: column;
    gap: 48px;
}

.staff-image-wrapper {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    max-height: 400px;
}

.staff-image {
    width: 100%;
    height: 400px;
    object-fit: cover;
    filter: brightness(0.85) saturate(1.1);
}

.staff-image-glow {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, transparent 50%, var(--bg-primary) 100%),
        radial-gradient(ellipse at 50% 50%, rgba(168, 85, 247, 0.08) 0%, transparent 70%);
    pointer-events: none;
}

.staff-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.staff-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 28px;
    text-align: center;
    transition: var(--transition-base);
}

.staff-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-glow);
    transform: translateY(-4px);
    box-shadow: var(--shadow-glow);
}

.staff-avatar {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.4rem;
    color: #fff;
}

.staff-info h3 {
    font-family: var(--font-display);
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 6px;
}

.staff-role {
    display: inline-block;
    padding: 4px 12px;
    background: rgba(168, 85, 247, 0.1);
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent-purple);
    margin-bottom: 10px;
}

.staff-info p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* ============================================
   JOIN SECTION
   ============================================ */
.section-join {
    background:
        radial-gradient(ellipse at 30% 60%, rgba(168, 85, 247, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 70% 40%, rgba(6, 214, 224, 0.06) 0%, transparent 50%),
        var(--bg-secondary);
}

.steps-grid {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-bottom: 60px;
}

.step-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 40px 32px;
    text-align: center;
    flex: 1;
    max-width: 300px;
    transition: var(--transition-base);
    position: relative;
}

.step-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-glow);
    transform: translateY(-6px);
    box-shadow: var(--shadow-glow);
}

.step-number {
    position: absolute;
    top: -16px;
    left: 50%;
    transform: translateX(-50%);
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gradient-primary);
    border-radius: 10px;
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 0.95rem;
    color: #fff;
}

.step-icon {
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(168, 85, 247, 0.08);
    border-radius: 16px;
    color: var(--accent-cyan);
    margin: 0 auto 20px;
}

.step-card h3 {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

.step-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.step-card p a {
    color: var(--accent-cyan);
    border-bottom: 1px solid transparent;
}

.step-card p a:hover {
    border-bottom-color: var(--accent-cyan);
}

.step-connector {
    color: var(--text-muted);
    flex-shrink: 0;
    padding: 0 12px;
}

.join-cta {
    text-align: center;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
    position: relative;
    z-index: 1;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 80px 0 32px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 48px;
    margin-bottom: 48px;
}

.footer-brand p {
    margin-top: 16px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
    max-width: 320px;
}

.footer-links h4 {
    font-family: var(--font-display);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 2px;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.footer-links a {
    display: block;
    padding: 6px 0;
    font-size: 0.9rem;
    color: var(--text-secondary);
    transition: var(--transition-fast);
}

.footer-links a:hover {
    color: var(--accent-purple);
    transform: translateX(4px);
}

.footer-bottom {
    border-top: 1px solid var(--border-color);
    padding-top: 24px;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}

.footer-bottom p {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* ============================================
   SCROLL ANIMATIONS
   ============================================ */
.section-header,
.feature-card,
.rule-card,
.staff-card,
.step-card,
.discord-card,
.staff-image-wrapper {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

.section-header.visible,
.feature-card.visible,
.rule-card.visible,
.staff-card.visible,
.step-card.visible,
.discord-card.visible,
.staff-image-wrapper.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger animations for grid items */
.feature-card:nth-child(2).visible { transition-delay: 0.1s; }
.feature-card:nth-child(3).visible { transition-delay: 0.2s; }
.feature-card:nth-child(4).visible { transition-delay: 0.3s; }

.rule-card:nth-child(2).visible { transition-delay: 0.1s; }
.rule-card:nth-child(3).visible { transition-delay: 0.15s; }
.rule-card:nth-child(4).visible { transition-delay: 0.2s; }
.rule-card:nth-child(5).visible { transition-delay: 0.25s; }
.rule-card:nth-child(6).visible { transition-delay: 0.3s; }

.staff-card:nth-child(2).visible { transition-delay: 0.1s; }
.staff-card:nth-child(3).visible { transition-delay: 0.2s; }
.staff-card:nth-child(4).visible { transition-delay: 0.3s; }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
    .community-grid {
        grid-template-columns: 1fr;
    }

    .rules-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .staff-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-content {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    :root {
        --section-padding: 80px 0;
    }

    .nav-links,
    .nav-cta {
        display: none;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-links.open {
        display: flex;
        flex-direction: column;
        position: fixed;
        inset: 0;
        background: rgba(10, 10, 20, 0.97);
        backdrop-filter: blur(20px);
        align-items: center;
        justify-content: center;
        gap: 8px;
        z-index: 1000;
    }

    .nav-links.open .nav-link {
        font-size: 1.2rem;
        padding: 14px 32px;
    }

    .nav-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .nav-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }

    .hero-stats {
        flex-direction: column;
        gap: 20px;
        padding: 24px;
    }

    .stat-divider {
        width: 60px;
        height: 1px;
    }

    .rules-grid {
        grid-template-columns: 1fr;
    }

    .staff-grid {
        grid-template-columns: 1fr;
    }

    .steps-grid {
        flex-direction: column;
        gap: 24px;
    }

    .step-connector {
        transform: rotate(90deg);
    }

    .step-card {
        max-width: 100%;
        width: 100%;
    }

    .footer-content {
        grid-template-columns: 1fr;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .hero-actions {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }
}

/* =============================================
   MODAL RÈGLEMENT GÉNÉRAL
   ============================================= */
.modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(5, 5, 10, 0.9);
    backdrop-filter: blur(10px);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
}

.modal-content {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    width: 90%;
    max-width: 800px;
    max-height: 80vh;
    padding: 40px;
    position: relative;
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
    display: flex;
    flex-direction: column;
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.modal.show .modal-content {
    transform: translateY(0);
}

.close-modal {
    position: absolute;
    top: 20px;
    right: 20px;
    color: var(--text-secondary);
    font-size: 32px;
    font-weight: bold;
    cursor: pointer;
    line-height: 1;
    transition: color 0.3s;
}

.close-modal:hover {
    color: var(--accent-primary);
}

.modal-title {
    font-family: var(--font-display);
    font-size: 2rem;
    margin-bottom: 20px;
    color: #fff;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
}

.modal-body {
    overflow-y: auto;
    padding-right: 10px;
}

.modal-body h3 {
    color: var(--accent-primary);
    margin-top: 20px;
    margin-bottom: 10px;
    font-family: var(--font-display);
}

.modal-body p, .modal-body ul {
    color: var(--text-secondary);
    margin-bottom: 15px;
    line-height: 1.6;
}

.modal-body ul {
    padding-left: 20px;
}

