/* Google Fonts Import */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;700&display=swap');

:root {
    --primary-color: #042980;
    --primary-glow: #042980cc;
    --background-dark: #000205;
    /* Deep black with slight blue tint */
    --background-card: rgba(4, 41, 128, 0.05);
    --text-white: #ffffff;
    --text-gray: #a0a0a0;
    --border-color: rgba(4, 41, 128, 0.3);

    --font-main: 'Outfit', sans-serif;

    --transition-fast: 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

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

ul {
    list-style: none;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--background-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

/* Utilities */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.text-gradient {
    background: linear-gradient(to right, #fff, var(--primary-color));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.btn {
    display: inline-block;
    padding: 0.8rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    position: relative;
    overflow: hidden;
    background: transparent;
    border: 1px solid var(--primary-color);
    box-shadow: 0 0 15px rgba(4, 41, 128, 0.2);
}

.btn:hover {
    background: var(--primary-color);
    box-shadow: 0 0 30px var(--primary-glow);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1.5rem 0;
    z-index: 1000;
    background: transparent;
    transition: var(--transition-fast);
}

.navbar.scrolled {
    padding: 1rem 0;
    background: rgba(0, 2, 5, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-white);
}

.logo span {
    color: var(--primary-color);
}

.logo-img {
    height: 105px;
    width: auto;
    vertical-align: middle;
    transition: var(--transition-fast);
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: var(--transition-fast);
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

/* Footer */
footer {
    padding: 4rem 0;
    background: linear-gradient(to top, #000, var(--background-dark));
    text-align: center;
    border-top: 1px solid var(--border-color);
    margin-top: 4rem;
}

.footer-text {
    color: var(--text-gray);
    font-size: 0.9rem;
}

/* Guidebook Layout (Reglement / Lore) */
.guidebook-layout {
    display: flex;
    padding-top: 80px;
    /* Navbar height */
    min-height: 100vh;
}

/* Sidebar */
.guidebook-sidebar {
    width: 300px;
    background: rgba(0, 2, 5, 0.95);
    border-right: 1px solid var(--border-color);
    position: fixed;
    top: 80px;
    bottom: 0;
    left: 0;
    overflow-y: auto;
    padding: 2rem;
    z-index: 100;
    transition: transform var(--transition-fast);
}

.sidebar-title {
    color: var(--text-gray);
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 2px;
    margin-bottom: 1.5rem;
    font-weight: 700;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.sidebar-link {
    display: block;
    padding: 0.8rem 1rem;
    border-radius: 8px;
    color: var(--text-white);
    font-size: 0.95rem;
    position: relative;
    overflow: hidden;
}

.sidebar-link:hover,
.sidebar-link.active {
    background: rgba(4, 41, 128, 0.2);
    color: var(--primary-color);
    font-weight: 600;
}

.sidebar-link.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 3px;
    background: var(--primary-color);
}

/* Main Content Area for Guidebook */
.guidebook-content {
    margin-left: 300px;
    flex: 1;
    padding: 4rem 10% 4rem 4rem;
    background: var(--background-dark);
}

.guide-section {
    margin-bottom: 2rem;
    /* Reduced from 4rem to keep it tighter */
    scroll-margin-top: 100px;
    /* Offset for sticky header */
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 2rem;
}

.guide-section:last-child {
    border-bottom: none;
}

.guide-title {
    font-size: 2.2rem;
    margin-bottom: 1.5rem;
    color: var(--text-white);
    display: flex;
    align-items: center;
}

.guide-title::before {
    content: '#';
    color: var(--primary-color);
    margin-right: 0.5rem;
    opacity: 0.5;
}

/* Responsive Guidebook */
@media (max-width: 900px) {
    .guidebook-sidebar {
        transform: translateX(-100%);
        z-index: 1001;
        /* Higher than content */
        width: 280px;
    }

    .guidebook-sidebar.open {
        transform: translateX(0);
    }

    .guidebook-content {
        margin-left: 0;
        padding: 2rem;
    }
}