@font-face {
    font-family: 'Mojang';
    src: url('assets/mojang/Mojang-Bold.ttf') format('truetype');
    font-weight: bold;
}
@font-face {
    font-family: 'Mojang';
    src: url('assets/mojang/Mojang-Regular.ttf') format('truetype');
    font-weight: normal;
}
@font-face {
    font-family: 'Coolvetica';
    src: url('assets/coolvetica/Coolvetica%20Rg.otf') format('opentype');
}

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

:root {
    --bg: #1a1a1a;
    --nav-bg: #2a2a2a;
    --nav-border: #3a3a3a;
    --nav-active: #111;
    --nav-hover: rgba(255,255,255,0.06);
    --nav-text: #ddd;
    --logo-bg: #222;
    --gmod-bg: #222;
    --gmod-title: #eee;
    --text: #ddd;
    --card-body: #2a2a2a;
    --card-border: #3a3a3a;
    --label-color: #aaa;
    --legal-note: #888;
    --code-bg: #333;
    --hr-color: #3a3a3a;
    --footer-bg: #111;
    --footer-text: #666;
    --logo-src: url('/assets/ponzdark.png');
}

body {
    font-family: Arial, sans-serif;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background: var(--bg);
    transition: background 0.2s, color 0.2s;
}

header {
    display: grid;
    grid-template-columns: 340px 1fr 340px;
    height: 100px;
}

.header-mc {
    display: flex;
    flex-direction: column;
}

.header-mc .game-title {
    padding: 10px 14px 6px;
    letter-spacing: 0.01em;
}

.header-mc .player-btn,
.header-gmod .player-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    letter-spacing: 0.02em;
}

.header-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--logo-bg);
    position: relative;
}

.header-logo a {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
}

.header-logo img {
    height: 78px;
    width: auto;
    content: var(--logo-src);
}


.header-gmod {
    display: flex;
    flex-direction: column;
}

.header-gmod .game-title {
    padding: 10px 14px 6px;
    letter-spacing: 0.01em;
}

.title-theme-minecraft,
.title-theme-modded {
    font-family: 'Mojang', monospace;
    font-weight: bold;
    font-size: 20px;
    color: #fff;
}

.title-theme-gmod,
.title-theme-super {
    font-family: 'Coolvetica', Arial, sans-serif;
    font-size: 22px;
    text-align: center;
}

.title-theme-gmod {
    color: var(--gmod-title);
}

.title-theme-super {
    color: #1f1233;
}

.header-theme-minecraft,
.header-theme-modded {
    background: #111;
}

.header-theme-gmod {
    background: var(--gmod-bg);
}

.header-theme-super {
    background: #bba0ff;
}

.player-theme-minecraft,
.player-theme-modded {
    color: #fff;
    font-family: 'Mojang', monospace;
    font-weight: normal;
    font-size: 18px;
    text-shadow: 2px 2px 0 #000, -1px 0 0 #000, 0 -1px 0 #000, 1px 0 0 #000, 0 1px 0 #000;
}

.player-theme-minecraft {
    background-image: url('assets/minecrafttexture.png');
    background-size: 120px;
    background-position: center 55%;
}

.player-theme-modded {
    background: #111;
}

.player-theme-modded::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('assets/minecrafttexture.png');
    background-size: 120px;
    background-position: center 55%;
    filter: invert(1);
    z-index: 0;
}

.player-theme-gmod {
    background: #1565c0;
    color: #fff;
    font-family: 'Coolvetica', Arial, sans-serif;
    font-size: 22px;
}

.player-theme-super {
    background: #c9adff;
    color: #1f1233;
    font-family: 'Coolvetica', Arial, sans-serif;
    font-size: 22px;
    text-shadow: none;
    letter-spacing: 0.02em;
}

nav {
    background: var(--nav-bg);
    display: flex;
    align-items: stretch;
    justify-content: center;
    border-top: 1px solid var(--nav-border);
}

nav a {
    text-decoration: none;
    color: var(--nav-text);
    font-family: Arial, sans-serif;
    font-size: 15px;
    padding: 8px 18px;
    display: flex;
    align-items: center;
    border-right: 1px solid var(--nav-border);
}

nav a:first-child {
    border-left: 1px solid var(--nav-border);
}

nav a:hover {
    background: var(--nav-hover);
}

nav a.active {
    background: var(--nav-active);
}

nav a.donate {
    color: #c8860a;
}

nav a.discord {
    color: #589bff;
}

main {
    flex: 1;
    padding: 24px 28px;
    background: var(--bg);
}

main h1 {
    font-size: 28px;
    font-weight: bold;
    color: var(--text);
    margin-bottom: 4px;
}

main h2 {
    font-size: 20px;
    font-weight: bold;
    color: var(--text);
    margin-bottom: 14px;
}

main p {
    font-size: 14px;
    color: var(--text);
    line-height: 1.55;
    margin-bottom: 12px;
    max-width: 1100px;
}

footer {
    background: var(--footer-bg);
    padding: 12px 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    font-size: 13px;
    color: var(--footer-text);
}

footer a {
    color: #589bff;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

code {
    font-family: monospace;
    background: var(--code-bg);
    color: var(--text);
    padding: 1px 5px;
    border-radius: 3px;
    font-size: 13px;
}

.server-card {
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 24px;
    max-width: 600px;
}

.server-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 18px;
    color: #fff;
}

.server-card.dark .server-card-header {
    position: relative;
    background: #111;
    overflow: hidden;
}
.server-card.blue .server-card-header { background: #1565c0; }
.server-card.gmod .server-card-header { background: #1565c0; }
.server-card.super .server-card-header { background: #bba0ff; color: #1f1233; }
.server-card.modded .server-card-header {
    position: relative;
    background: #111;
    overflow: hidden;
}

.server-card.modded .server-card-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('assets/minecrafttexture.png');
    background-size: 120px;
    background-position: center 55%;
    filter: invert(1);
    opacity: 0.45;
    z-index: 0;
}

.server-card.dark .server-card-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('assets/minecrafttexture.png');
    background-size: 120px;
    background-position: center 55%;
    opacity: 0.45;
    z-index: 0;
}

.server-card.dark .server-card-header > * {
    position: relative;
    z-index: 1;
}

.server-card.modded .server-card-header > * {
    position: relative;
    z-index: 1;
}

.server-name.mojang {
    font-family: 'Mojang', monospace;
    font-weight: bold;
    font-size: 17px;
    letter-spacing: 0.02em;
}

.server-name.coolvetica {
    font-family: 'Coolvetica', Arial, sans-serif;
    font-size: 20px;
}

.server-players {
    font-size: 13px;
    opacity: 0.85;
}

.server-card-body {
    background: var(--card-body);
    padding: 14px 18px;
}

.server-info-row {
    display: flex;
    gap: 12px;
    padding: 5px 0;
    border-bottom: 1px solid var(--card-border);
    font-size: 14px;
    color: var(--text);
}

.server-info-row:last-child { border-bottom: none; }

.server-info-row .label {
    font-weight: bold;
    min-width: 70px;
    color: var(--label-color);
}

.server-card-body a { color: #589bff; text-decoration: none; }
.server-card-body a:hover { text-decoration: underline; }

.legal-note {
    margin-top: 20px;
    font-size: 12px;
    color: var(--legal-note);
}

.legal-note a { color: #589bff; text-decoration: none; }
.legal-note a:hover { text-decoration: underline; }

.rules-list {
    margin: 0 0 20px 22px;
    padding: 0;
}

.rules-list li {
    font-size: 14px;
    line-height: 1.6;
    color: var(--text);
    margin-bottom: 6px;
}

main.legal h2 {
    margin-top: 22px;
}

main.legal hr {
    border: none;
    border-top: 1px solid var(--hr-color);
    margin: 20px 0;
}

main.legal a {
    color: #589bff;
    text-decoration: none;
}

main.legal a:hover {
    text-decoration: underline;
}

@media (max-width: 768px) {
    header {
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
        height: auto;
    }

    .header-logo {
        width: 100%;
        order: 1;
        padding: 12px;
    }

    .header-logo img {
        height: 56px;
    }

    .header-mc {
        width: 50%;
        order: 2;
        min-height: 80px;
    }

    .header-gmod {
        width: 50%;
        order: 3;
        min-height: 80px;
    }

    .header-mc .game-title,
    .header-gmod .game-title {
        font-size: 13px;
        padding: 6px 10px 4px;
    }

    .header-mc .player-btn,
    .header-gmod .player-btn {
        font-size: 13px;
    }

    nav {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        flex-wrap: nowrap;
        border-top: none;
    }

    nav a {
        white-space: nowrap;
        font-size: 14px;
        padding: 10px 14px;
        flex-shrink: 0;
    }

    main {
        padding: 16px;
    }

    main h1 {
        font-size: 22px;
    }

    main h2 {
        font-size: 17px;
    }

    main p {
        max-width: 100%;
    }

    footer {
        flex-direction: column;
        gap: 6px;
        text-align: center;
        padding: 14px 16px;
    }
}
