@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;800&display=swap');

:root {
    --color-primary: #de1a24;
    --color-primary-dark: #b3141c;
    --color-secondary: #ffffff;
    --color-text-main: #f0f0f0;
    --color-text-muted: #a0a0a0;
    --color-bg-dark: #121212;
    --color-bg-card: rgba(255, 255, 255, 0.05);
    --color-bg-card-hover: rgba(255, 255, 255, 0.1);
    --color-accent: #ffd700;
    /* Goldish for shield highlights */

    --font-main: 'Outfit', sans-serif;

    --shadow-card: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    --border-glass: 1px solid rgba(255, 255, 255, 0.08);

    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-main);
    background-color: var(--color-bg-dark);
    color: var(--color-text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1rem;
}

h1 {
    font-size: 3.5rem;
    background: linear-gradient(135deg, var(--color-secondary) 0%, var(--color-primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

h2 {
    font-size: 2.5rem;
    color: var(--color-secondary);
}

p {
    margin-bottom: 1rem;
    color: var(--color-text-muted);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

/* Layout Utilities */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.section {
    padding: 5rem 0;
}

.grid {
    display: grid;
    gap: 2rem;
}

.flex {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.text-center {
    text-align: center;
}

.justify-center {
    justify-content: center;
}

.justify-between {
    justify-content: space-between;
}

.flex-col {
    flex-direction: column;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    border: none;
    font-size: 1rem;
    gap: 0.5rem;
    transition: all var(--transition-normal);
}

.btn-primary {
    background: var(--color-primary);
    color: white;
    box-shadow: 0 4px 15px rgba(222, 26, 36, 0.4);
}

.btn-primary:hover {
    background: var(--color-primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(222, 26, 36, 0.6);
}

.btn-secondary {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: white;
    transform: translateY(-2px);
}

/* Navigation */
.navbar {
    padding: 1.5rem 0;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(18, 18, 18, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: var(--border-glass);
}

.nav-brand {
    font-weight: 800;
    font-size: 1.5rem;
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-link {
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    color: var(--color-text-muted);
}

.nav-link:hover,
.nav-link.active {
    color: var(--color-primary);
}

/* Glassmorphism Cards */
.card {
    background: var(--color-bg-card);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: var(--border-glass);
    border-radius: 16px;
    padding: 2rem;
    transition: var(--transition-normal);
}

.card:hover {
    background: var(--color-bg-card-hover);
    transform: translateY(-5px);
    box-shadow: var(--shadow-card);
    border-color: rgba(255, 255, 255, 0.2);
}

/* Responsive Navigation */
@media (max-width: 768px) {
    h1 {
        font-size: 2.2rem;
    }

    h2 {
        font-size: 1.8rem;
    }

    .navbar .container {
        flex-direction: column;
        gap: 1rem;
    }

    .nav-links {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
        width: 100%;
    }

    .grid {
        grid-template-columns: 1fr !important;
        /* Force single column on mobile */
    }

    .hero .grid {
        grid-template-columns: 1fr !important;
    }

    .hero-content {
        order: 2;
        text-align: center;
    }

    .hero-image {
        order: 1;
        margin-bottom: 2rem;
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.section {
    animation: fadeIn 0.8s ease-out forwards;
}

.btn:active {
    transform: scale(0.98);
}

/* Interactive Rules Cards */
.interactive-card {
    cursor: pointer;
    transition: all var(--transition-normal);
}

.interactive-card:hover {
    background: var(--color-bg-card-hover);
    border-left-color: var(--color-accent);
}

.card-header h4 {
    margin-bottom: 0;
}

.toggle-icon {
    color: var(--color-text-muted);
    transition: transform var(--transition-normal);
}

.interactive-card.active .toggle-icon {
    transform: rotate(180deg);
    color: var(--color-primary);
}

.interactive-card.active {
    background: rgba(255, 255, 255, 0.08);
    border-left-color: var(--color-primary);
}

.rule-image-container {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease-out, margin-top 0.3s ease;
    margin-top: 0;
    opacity: 0;
}

.interactive-card.active .rule-image-container {
    max-height: 500px;
    /* Adjust as needed */
    margin-top: 1rem;
    opacity: 1;
    transition: max-height 0.5s ease-in, opacity 0.3s ease 0.2s;
}

.rule-img-placeholder {
    width: 100%;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    display: block;
}

.img-caption {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    text-align: center;
    margin-top: 0.5rem;
    font-style: italic;
}