:root {
    --bg: #0D0D0D; /* Deep night black for brooding halls */
    --card: #1F1F1F; /* Charcoal stone */
    --text: #D9D9D9; /* Aged parchment gray */
    --text-muted: #A6A6A6; /* Faded rune etchings */
    --accent-primary: #8B4513; /* Rusty iron/blood red-brown */
    --accent-secondary: #4D4D4D; /* Forged steel gray */
    --accent-highlight: #B8860B; /* Dull warrior gold */
    --border: #333333; /* Dark engraved lines */
    --shadow: rgba(0, 0, 0, 0.6); /* Deep shadows without glow */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Old Standard TT', Georgia, serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
}

header {
    background: #1A1A1A; /* Dark wooden beam */
    border-bottom: 2px solid var(--border);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1300px;
    margin: 0 auto;
    padding: 1.2rem 2rem;
}

.logo {
    font-family: 'Njord', 'Old Standard TT', sans-serif !important;
    font-size: 2.2rem;
    font-weight: bold;
    color: var(--accent-highlight);
    text-shadow: 1px 1px 2px var(--shadow);
    letter-spacing: 2px;
    text-transform: uppercase;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
    position: relative;
}

.nav-links a:hover {
    color: var(--accent-primary);
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -6px;
    left: 0;
    background: var(--accent-primary);
    transition: width 0.3s;
}

.nav-links a:hover::after {
    width: 100%;
}

.hamburger {
    display: none;
    flex-direction: column;
    gap: 0.35rem;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--text);
    transition: all 0.3s;
}

.hero {
    height: 100vh;
    background: var(--bg) url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1400 800" opacity="0.3"><rect fill="%231F1F1F" width="1400" height="800"/><path fill="%234D4D4D" d="M0 600 Q350 500 700 600 T1400 600 L1400 800 L0 800 Z"/><path fill="%238B4513" d="M200 200 L250 150 L300 200 L275 250 L225 250 Z M800 300 L850 250 L900 300 L875 350 L825 350 Z"/></svg>') center/cover no-repeat;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    margin-top: 80px;
    padding: 0 2rem;
}

.hero h1 {
    font-family: 'Njord', 'Old Standard TT', sans-serif !important;
    font-size: 5.5rem;
    font-weight: bold;
    color: var(--accent-highlight);
    text-shadow: 2px 2px 4px var(--shadow);
    margin-bottom: 1rem;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.hero p {
    font-size: 1.4rem;
    max-width: 700px;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
}

.btn {
    background: var(--accent-primary);
    color: var(--text);
    padding: 1rem 2.5rem;
    border: 2px solid var(--border);
    border-radius: 4px;
    font-weight: bold;
    text-decoration: none;
    transition: background 0.3s;
    display: inline-block;
    font-family: 'Njord', 'Old Standard TT', sans-serif !important;
}

.btn:hover {
    background: var(--accent-secondary);
}

section {
    padding: 6rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

h2 {
    font-family: 'Njord', 'Old Standard TT', sans-serif !important;
    font-size: 3rem;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--accent-highlight);
    text-shadow: 1px 1px 2px var(--shadow);
    letter-spacing: 2px;
    text-transform: uppercase;
}

.card {
    background: var(--card);
    border: 2px solid var(--border);
    border-radius: 8px;
    padding: 2.5rem;
    box-shadow: 0 4px 10px var(--shadow);
    transition: box-shadow 0.3s;
    max-width: 800px;
    margin: 2rem auto;
    text-align: center;
}

.card:hover {
    box-shadow: 0 6px 15px var(--shadow);
}

/* LIVE SERVER STATUS SECTION */
#servers h2 {
    margin-bottom: 2rem;
}

.server-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1rem;
}

.server-card {
    background: var(--card);
    border: 2px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 10px var(--shadow);
    transition: box-shadow 0.3s;
}

.server-card:hover {
    box-shadow: 0 6px 15px var(--shadow);
}

.server-header {
    padding: 1.8rem 1.5rem;
    background: var(--accent-secondary);
    border-bottom: 2px solid var(--border);
    text-align: center;
}

.server-title {
    font-family: 'Njord', 'Old Standard TT', sans-serif !important;
    font-size: 2rem;
    color: var(--accent-highlight);
    letter-spacing: 2px;
    text-transform: uppercase;
}

.server-desc {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
}

.server-body {
    padding: 2rem 1.5rem;
    text-align: center;
}

.status-line {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 1rem;
    font-weight: 600;
}

.status-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    display: inline-block;
}

.online-dot {
    background: #4CAF50; /* Simple green, no animation */
}

.offline-dot {
    background: #F44336;
}

.players {
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--accent-primary);
    margin: 0.5rem 0;
    font-family: 'Njord', 'Old Standard TT', sans-serif !important;
}

.join-btn {
    background: var(--accent-primary);
    color: var(--text);
    padding: 0.9rem 2rem;
    border: 2px solid var(--border);
    border-radius: 4px;
    font-weight: bold;
    cursor: pointer;
    margin-top: 1rem;
    font-size: 1.1rem;
    transition: background 0.3s;
    font-family: 'Njord', 'Old Standard TT', sans-serif !important;
}

.join-btn:hover {
    background: var(--accent-secondary);
}

.join-btn.disabled {
    background: #333333;
    cursor: not-allowed;
    opacity: 0.6;
}

.loading {
    text-align: center;
    font-size: 1.3rem;
    color: var(--text-muted);
    grid-column: 1 / -1;
    padding: 3rem;
}

.rules ul {
    list-style: none;
    margin: 0 auto;
    max-width: 90%;
    text-align: left;
}

.rules li {
    padding: 0.8rem 0;
    padding-left: 2rem;
    position: relative;
    font-size: 1.1rem;
}

.rules li:before {
    content: "⚔"; /* Viking sword icon */
    color: var(--accent-primary);
    position: absolute;
    left: 0;
    font-family: 'Njord', 'Old Standard TT', sans-serif !important;
}

.discord-btn {
    display: inline-block;
    max-width: 340px;
    margin: 3rem auto;
    background: #5865F2; /* Keep Discord blue, or change if needed */
    border: 2px solid var(--border);
    border-radius: 4px;
    padding: 1rem 2.5rem;
    color: white;
    font-weight: bold;
    text-decoration: none;
    transition: background 0.3s;
    font-family: 'Njord', 'Old Standard TT', sans-serif !important;
}

.discord-btn:hover {
    background: #404EED;
}

footer {
    background: #1A1A1A;
    color: var(--text-muted);
    text-align: center;
    padding: 3rem;
    border-top: 2px solid var(--border);
    margin-top: 4rem;
}

@media (max-width: 768px) {
    .hero {
        margin-top: 60px;
    }
    .hero h1 {
        font-size: 3.5rem;
    }
    .hero p {
        font-size: 1.2rem;
    }
    nav {
        padding: 1rem;
    }
    .nav-links {
        display: none;
    }
    .hamburger {
        display: flex;
    }
    .server-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 2.8rem;
    }
    h2 {
        font-size: 2.5rem;
    }
    section {
        padding: 4rem 1rem;
    }
}