@font-face {
    font-family: 'norsebold';
    src: url('../fonts/norse-bold-webfont.woff2') format('woff2'),
         url('../fonts/norse-bold-webfont.woff') format('woff');
    font-weight: normal;
    font-style: normal;
    font-display: optional;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #111;
    color: #ddd;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

a {
    color: #d4af37;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Buttons should never have underline on hover */
button:hover,
.btn:hover,
.btn-primary:hover,
.btn-secondary:hover,
.btn-ghost:hover,
.btn-back:hover,
.btn-forum:hover,
.btn-visit:hover,
.btn-vote:hover,
.btn-view-all:hover,
a.btn:hover,
a.btn-primary:hover,
a.btn-secondary:hover,
a.btn-ghost:hover,
a.btn-back:hover,
a.btn-forum:hover,
a.btn-visit:hover,
a.btn-vote:hover,
a.btn-view-all:hover {
    text-decoration: none !important;
}

/* Header */
.site-header {
    background-color: rgba(20, 20, 20, 0.95);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 20px rgba(0,0,0,0.5);
}

.header-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 30px;
    height: 90px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 40px;
    position: relative;
}

.header-logo {
    position: absolute;
    top: -20px;
    left: 30px;
    width: 45px;
    z-index: 1001;
    transition: transform 0.3s ease;
    filter: drop-shadow(0 5px 15px rgba(0,0,0,0.5));
}

.header-logo:hover {
    transform: translateY(10px);
}

.header-svg {
    color: #fff;
}

.main-menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 30px;
}

.main-menu ul li a {
    color: #fff;
    font-family: 'norsebold', sans-serif;
    font-weight: normal;
    font-size: 1.2em;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-decoration: none;
    transition: color 0.2s ease;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
    backface-visibility: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.main-menu ul li a:hover,
.main-menu ul li a.active {
    color: #d4af37;
    text-decoration: none;
}

.social-menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 15px;
    align-items: center;
}

.social-menu ul li a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    font-size: 38px;
    color: #fff;
    transition: color 0.2s ease, transform 0.2s ease;
}

.social-menu ul li a:hover,
.social-menu ul li a.active {
    color: #d4af37 !important;
    transform: translateY(-2px);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.header-actions .btn {
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 46px;
    padding: 10px 18px;
    font-family: 'Heretic', 'norsebold', 'Segoe UI', sans-serif;
    font-size: 1.15rem;
    line-height: 1.6rem;
    font-weight: 400;
    text-transform: uppercase;
    color: #181614;
    background: transparent;
    border: 0;
    box-shadow: none;
    text-decoration: none;
    transition: 0.5s;
}

.header-actions .btn .btn-text {
    position: relative;
    z-index: 20;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.header-actions .btn .btn-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    overflow: hidden;
    background-image: linear-gradient(to right, #d4af37, #b88f24);
    clip-path: url(#btn-mask);
}

.header-actions .btn:hover {
    background: transparent;
    box-shadow: none;
    filter: brightness(1.02) saturate(1.05);
}

.header-actions .btn:active,
.header-actions .btn:focus-visible {
    background: transparent;
    box-shadow: none;
    outline: none;
}

@media (max-width: 1024px) {
    .header-container {
        justify-content: flex-end;
    }
    .main-menu {
        display: none; /* Hide on mobile for now or implement burger */
    }
    .social-menu {
        display: none;
    }
}

/* Burger Menu & Mobile Overlay */
.burger-menu-btn {
    display: none;
    background: none;
    border: none;
    color: #d4af37;
    font-size: 1.8rem;
    cursor: pointer;
    padding: 10px;
    margin-left: 15px;
    transition: color 0.2s;
}

.burger-menu-btn:hover {
    color: #fff;
}

.mobile-menu-overlay {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100vh;
    background-color: rgba(17, 17, 17, 0.98);
    z-index: 2000;
    transition: right 0.3s cubic-bezier(0.77, 0, 0.175, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
}

.mobile-menu-overlay.active {
    right: 0;
}

.close-menu-btn {
    position: absolute;
    top: 20px;
    right: 30px;
    background: none;
    border: none;
    color: #d4af37;
    font-size: 3rem;
    cursor: pointer;
    transition: transform 0.2s;
}

.close-menu-btn:hover {
    color: #fff;
    transform: rotate(90deg);
}

.mobile-nav {
    text-align: center;
    width: 100%;
}

.mobile-nav ul {
    list-style: none;
    padding: 0;
    margin: 0 0 40px 0;
}

.mobile-nav ul li {
    margin: 25px 0;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.mobile-menu-overlay.active .mobile-nav ul li {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger animations */
.mobile-menu-overlay.active .mobile-nav ul li:nth-child(1) { transition-delay: 0.1s; }
.mobile-menu-overlay.active .mobile-nav ul li:nth-child(2) { transition-delay: 0.2s; }
.mobile-menu-overlay.active .mobile-nav ul li:nth-child(3) { transition-delay: 0.3s; }
.mobile-menu-overlay.active .mobile-nav ul li:nth-child(4) { transition-delay: 0.4s; }
.mobile-menu-overlay.active .mobile-nav ul li:nth-child(5) { transition-delay: 0.5s; }
.mobile-menu-overlay.active .mobile-nav ul li:nth-child(6) { transition-delay: 0.6s; }

.mobile-nav ul li a {
    font-family: 'norsebold', sans-serif;
    font-size: 2.5rem;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-decoration: none;
    transition: color 0.2s;
}

.mobile-nav ul li a:hover {
    color: #d4af37;
}

.mobile-social {
    display: flex;
    justify-content: center;
    gap: 25px;
    margin-top: 20px;
}

.mobile-social a {
    color: #888;
    font-size: 1.8rem;
    transition: all 0.2s;
}

.mobile-social a:hover {
    color: #d4af37;
    transform: scale(1.1);
}

@media (max-width: 1024px) {
    .burger-menu-btn {
        display: block;
    }
    /* Hide header actions on very small screens if needed, or keep them */
    /* .header-actions { display: none; } */
}

/* Layout */
.container {
    display: flex;
    max-width: 1200px;
    margin: 20px auto;
    padding: 0 20px;
    gap: 20px;
    flex: 1;
    width: 100%;
    box-sizing: border-box;
}

/* Sidebar */
.sidebar {
    width: 250px;
    background-color: #1e1e1e;
    padding: 20px;
    border-radius: 5px;
    border: 1px solid #333;
    flex-shrink: 0;
}

.sidebar h3 {
    color: #d4af37;
    border-bottom: 1px solid #444;
    padding-bottom: 10px;
    margin-top: 0;
}

.sidebar ul {
    list-style: none;
    padding: 0;
}

.sidebar ul li {
    margin-bottom: 10px;
    border-bottom: 1px solid #2a2a2a;
    padding-bottom: 5px;
}

/* Main Content */
.main-content {
    flex-grow: 1;
    background-color: #1e1e1e;
    padding: 30px;
    border-radius: 5px;
    border: 1px solid #333;
}

.main-content h2 {
    color: #d4af37;
    margin-top: 0;
}

/* Server List Table */
table.server-list {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

table.server-list th, table.server-list td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #333;
}

table.server-list th {
    background-color: #252525;
    color: #d4af37;
}

table.server-list tr:hover {
    background-color: #252525;
}

/* Forms */
input[type="text"], input[type="password"], textarea {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    background-color: #2a2a2a;
    border: 1px solid #444;
    color: #fff;
    border-radius: 3px;
}

button {
    background-color: #d4af37;
    color: #111;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    font-weight: bold;
    text-transform: uppercase;
}

button:hover {
    background-color: #b5922b;
}

/* Footer */
.site-footer {
    position: relative;
    padding: 80px 20px 30px; /* Increased top padding to account for the jagged edge */
    margin-top: 40px;
    z-index: 1;
    flex-shrink: 0;
}

.footer-bg {
    position: absolute;
    top: -50px; /* Move up to create the overlap effect */
    left: 0;
    width: 100%;
    height: calc(100% + 50px); /* Extend height to cover the moved up area */
    background: linear-gradient(to bottom, rgba(10,10,10,0.9), rgba(10,10,10,1)), url('/assets/images/bg-texture.webp');
    background-size: cover;
    background-position: center;
    clip-path: url(#footer-mask);
    z-index: -1;
    pointer-events: none;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
    position: relative;
}

.footer-logo {
    margin-bottom: 30px;
}

.footer-logo img {
    transition: transform 0.3s ease;
}

.footer-logo img:hover {
    transform: scale(1.05);
}

.footer-nav ul {
    list-style: none;
    padding: 0;
    margin: 0 0 25px 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px 30px;
}

.footer-nav ul li {
    margin: 0;
    border: none;
    padding: 0;
}

.footer-nav ul li a {
    color: #bbb;
    font-size: 0.95em;
    transition: color 0.3s ease;
}

.footer-nav ul li a:hover {
    color: #d4af37;
    text-decoration: none;
}

.footer-social {
    margin-bottom: 25px;
}

.footer-social ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    gap: 15px;
}

.footer-social ul li {
    margin: 0;
}

.footer-social ul li a {
    display: inline-block;
    width: 40px;
    height: 40px;
    padding: 8px;
    background-color: #1a1a1a;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.footer-social ul li a:hover {
    background-color: #d4af37;
    transform: translateY(-3px);
}

.footer-social ul li a svg {
    fill: #fff;
    transition: fill 0.3s ease;
}

.footer-social ul li a:hover svg {
    fill: #111;
}

.footer-copyright {
    color: #666;
    font-size: 0.85em;
    margin: 20px 0 0 0;
    padding-top: 20px;
    border-top: 1px solid #222;
}

@media (max-width: 768px) {
    .footer-nav ul {
        flex-direction: column;
        gap: 10px;
    }
    
    .site-footer {
        padding: 40px 15px 20px;
    }
}

/* Hero / About Section */
.hero-section {
    position: relative;
    padding: 100px 20px 150px; /* Increased bottom padding for jagged edge */
    color: #fff;
    margin-bottom: 40px;
    z-index: 1;
    overflow: hidden;
}

/* LCP-optimiertes Background Image */
.hero-bg-image {
    clip-path: url(#hero-mask);
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: linear-gradient(to right, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0.3) 50%, rgba(0,0,0,0) 100%);
    z-index: 0;
    pointer-events: none;
}

.hero-content {
    max-width: 1200px;
    margin: 0 auto;
    padding-left: 20px; /* Align with container padding */
}

.hero-label {
    text-transform: uppercase;
    letter-spacing: 3px;
    font-size: 0.9em;
    margin-bottom: 15px;
    color: #ddd;
    font-weight: 600;
}

.hero-title {
    font-family: 'norsebold', sans-serif;
    font-size: 3.5em;
    font-weight: normal;
    line-height: 1.1;
    margin: 0 0 30px 0;
    text-transform: uppercase;
    color: #fff;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
}

.hero-text {
    max-width: 600px;
    font-size: 1.15em;
    line-height: 1.6;
    color: rgba(255,255,255,0.9);
    text-shadow: 1px 1px 2px rgba(0,0,0,0.8);
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5em;
    }
    .hero-section {
        padding: 60px 20px;
    }
}

/* Decorated Header (Neuigkeiten) */
.section-header-decorated {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 50px;
    width: 100%;
    position: relative;
}

.decoration-line {
    height: 2px;
    flex-grow: 1;
    max-width: 200px;
    background-color: #d4af37;
    position: relative;
    opacity: 0.8;
}

.decoration-line.left {
    background: linear-gradient(to right, transparent, #d4af37);
}

.decoration-line.right {
    background: linear-gradient(to left, transparent, #d4af37);
}

.decoration-icon {
    width: 12px;
    height: 12px;
    background-color: #d4af37;
    transform: rotate(45deg);
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.8);
    flex-shrink: 0;
}

.decoration-icon img {
    display: none; /* Fallback to CSS shape */
}

.section-header-decorated .section-title {
    font-family: 'norsebold', sans-serif;
    font-size: 3em;
    color: #fff;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.8);
    padding: 0 10px;
}

/* News Section */
.latest-news-section {
    max-width: 1600px; /* Match header width */
    margin: 0 auto 60px;
    padding: 0 30px; /* Match header padding */
}

/* Override the default news-container width when inside latest-news-section */
.latest-news-section .news-container {
    max-width: 100%;
    padding: 0;
    margin: 0;
}

.news-featured-container {
    width: 100%;
}

.news-featured {
    display: flex;
    flex-direction: row;
    background-color: #000;
    text-decoration: none;
    color: #fff;
    width: 100%;
    /* Removed fixed min-height to allow content to dictate height */
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-featured:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.6);
    text-decoration: none;
}

.news-featured-image {
    width: 66.666%;
    position: relative;
    overflow: hidden;
    min-height: 600px; /* Increased height for better aspect ratio */
}

.news-featured-image .image-wrapper {
    width: 100%;
    height: 100%;
    position: absolute; /* Ensure it fills the container */
    top: 0;
    left: 0;
}

.news-featured-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.news-featured:hover .news-featured-image img {
    transform: scale(1.05);
}

.news-featured-content {
    width: 33.333%;
    padding: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background-color: #000;
    position: relative;
    z-index: 1;
    min-height: 600px; /* Match image height */
}

.small-heading {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
}

.small-heading .news-label {
    font-family: 'Segoe UI', sans-serif;
    text-transform: uppercase;
    letter-spacing: 3px;
    font-size: 0.9em;
    color: #fff;
    margin: 0;
}

.decoration-icon-small {
    width: 10px;
    height: 10px;
    background-color: #555; /* Muted color for the icon */
    transform: rotate(45deg);
    display: flex;
    align-items: center;
    justify-content: center;
}

.decoration-icon-small img {
    display: none;
}

.decoration-line-small {
    height: 1px;
    background-color: #555;
    flex-grow: 1;
    max-width: 100px;
}

.news-featured-title {
    font-family: 'norsebold', sans-serif;
    font-size: 3.5em;
    line-height: 1;
    margin: 0 0 30px 0;
    color: #fff;
    text-transform: uppercase;
}

.news-featured-date {
    color: #888;
    margin-bottom: 20px;
    font-size: 0.9em;
}

.news-featured-excerpt {
    color: rgba(255, 255, 255, 0.6);
    font-size: 1.1em;
    line-height: 1.6;
    margin-bottom: 40px;
}

.more-row {
    display: flex;
    justify-content: flex-end;
    margin-top: auto;
}

.read-more-featured {
    color: #d4af37;
    text-transform: uppercase;
    font-weight: bold;
    letter-spacing: 2px;
    font-size: 1.1em;
    position: relative;
    padding-left: 30px;
}

.read-more-featured::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 20px;
    height: 1px;
    background-color: #d4af37;
}

.read-more-featured::after {
    content: '';
    position: absolute;
    left: 5px;
    top: 50%;
    width: 6px;
    height: 6px;
    border-top: 1px solid #d4af37;
    border-right: 1px solid #d4af37;
    transform: translateY(-50%) rotate(45deg);
}

@media (max-width: 1024px) {
    .news-featured {
        flex-direction: column;
    }
    .news-featured-image, .news-featured-content {
        width: 100%;
    }
    .news-featured-image {
        height: 300px;
    }
    .news-featured-content {
        padding: 40px;
    }
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 30px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 15px;
}

.section-header h2 {
    font-family: 'norsebold', sans-serif;
    font-size: 2.5em;
    color: #fff;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-view-all {
    color: #d4af37;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.9em;
    letter-spacing: 1px;
    transition: color 0.2s ease;
}

.btn-view-all:hover {
    color: #fff;
    text-decoration: none;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.news-card {
    background-color: #1a1a1a;
    border: 1px solid #333;
    border-radius: 4px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.news-link {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.news-link:hover {
    text-decoration: none;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.3);
    border-color: #d4af37;
}

.news-image {
    height: 200px;
    overflow: hidden;
    position: relative;
    background-color: #0a0a0a;
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
    display: block;
}

.news-image picture {
    width: 100%;
    height: 100%;
    display: block;
}

.news-card:hover .news-image img {
    transform: scale(1.05);
}

.news-content {
    padding: 25px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.news-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    font-size: 0.85em;
}

.news-label {
    color: #d4af37;
    text-transform: uppercase;
    font-weight: bold;
    letter-spacing: 1px;
}

.news-date {
    color: #888;
}

.news-title {
    font-family: 'norsebold', sans-serif;
    font-size: 1.5em;
    margin: 0 0 15px 0;
    line-height: 1.2;
}

.news-title a {
    color: #fff;
    text-decoration: none;
    transition: color 0.2s ease;
}

.news-card:hover .news-title a {
    color: #d4af37;
}

.news-excerpt {
    color: #ccc;
    font-size: 0.95em;
    line-height: 1.6;
    margin-bottom: 20px;
    flex-grow: 1;
}

.read-more {
    display: inline-block;
    color: #d4af37;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.85em;
    letter-spacing: 1px;
    margin-top: auto;
}

.read-more:hover {
    color: #fff;
    text-decoration: none;
}

/* News Page Specifics */
.news-page-header {
    padding: 80px 20px 150px;
    position: relative;
    z-index: 1;
    text-align: center;
    color: #fff;
    min-height: 250px;
}

.news-page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 470px;
    background: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url('/assets/images/news-header.jpg');
    background-size: cover;
    background-position: center;
    clip-path: url(#hero-mask);
    z-index: -1;
}

.news-page-header h1 {
    font-family: 'norsebold', sans-serif;
    font-size: 3.5em;
    color: #d4af37;
    margin: 0;
    text-transform: uppercase;
}

.news-container {
    max-width: 1200px;
    margin: 0 auto 60px;
    padding: 0 20px;
}

@media (max-width: 768px) {
    .news-grid {
        grid-template-columns: 1fr;
    }
    
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
}

/* Server List Card Design */
.card-server {
    background-color: #1e1e1e;
    border: 1px solid #333;
    border-radius: 4px;
    margin-bottom: 20px;
    position: relative;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    overflow: hidden;
}

.card-server:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.3);
    border-color: #444;
}

.card-rank {
    position: absolute;
    top: 0;
    left: 0;
    background-color: #d4af37;
    color: #000;
    font-weight: bold;
    padding: 5px 10px;
    font-size: 0.9em;
    z-index: 10;
    border-bottom-right-radius: 4px;
}

.server-banner-container {
    overflow: hidden;
    position: relative;
}

.server-banner img {
    width: 100%;
    height: auto;
    max-height: 270px;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.card-server:hover .server-banner img {
    transform: scale(1.05);
}

.server-tags {
    padding: 10px 15px;
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    background-color: #1a1a1a;
    border-top: 1px solid #2a2a2a;
    margin-top: auto;
}

.srv-tag {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 0.75em;
    color: #fff;
    text-decoration: none;
    text-transform: uppercase;
    font-weight: 600;
}

.server-content {
    padding: 20px;
}

.server-title {
    margin: 0 0 10px 0;
    font-size: 1.4em;
    font-family: 'norsebold', sans-serif;
    letter-spacing: 1px;
}

.server-title a {
    color: #fff;
    text-decoration: none;
    transition: color 0.2s ease;
}

.server-title a:hover {
    color: #d4af37;
}

.server-description {
    color: #aaa;
    font-size: 0.9em;
    line-height: 1.5;
    margin-bottom: 15px;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.server-stats-col {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    height: 100%;
    justify-content: center;
    border-left: 1px solid #2a2a2a;
    background-color: #1a1a1a;
}

.box-stats {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 10px;
    background-color: #252525;
    border-radius: 4px;
    min-width: 80px;
}

.box-stats i {
    font-size: 1.2em;
    color: #666;
    margin-bottom: 5px;
}

.box-stats.vote-box i {
    color: #d4af37;
}

.box-stats .count {
    font-size: 1.2em;
    font-weight: bold;
    color: #fff;
}

.box-stats .label {
    font-size: 0.7em;
    text-transform: uppercase;
    color: #888;
    margin-top: 2px;
}

.box-reviews {
    text-align: center;
    color: #d4af37;
    font-size: 0.8em;
}

.card-footer {
    background-color: #151515;
    padding: 10px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid #2a2a2a;
}

.footer-left {
    display: flex;
    align-items: center;
    gap: 15px;
    color: #888;
    font-size: 0.9em;
}

.slots-info var {
    color: #fff;
    font-style: normal;
    font-weight: bold;
}

.discord-link {
    color: #7289da;
    font-size: 1.2em;
    transition: color 0.2s ease;
}

.discord-link:hover {
    color: #fff;
}

.footer-actions {
    display: flex;
    gap: 10px;
}

.btn-visit, .btn-vote {
    padding: 5px 15px;
    border-radius: 3px;
    font-size: 0.85em;
    font-weight: bold;
    text-transform: uppercase;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-visit {
    background-color: #333;
    color: #fff;
}

.btn-visit:hover {
    background-color: #444;
    color: #fff;
    text-decoration: none;
}

.btn-vote {
    background-color: #d4af37;
    color: #000;
}

.btn-vote:hover {
    background-color: #fff;
    color: #000;
    text-decoration: none;
}

@media (max-width: 768px) {
    .server-stats-col {
        flex-direction: row;
        border-left: none;
        border-top: 1px solid #2a2a2a;
        justify-content: space-around;
    }
    
    .card-footer {
        flex-direction: column;
        gap: 10px;
    }
    
    .footer-actions {
        width: 100%;
    }
    
    .btn-visit, .btn-vote {
        flex: 1;
        text-align: center;
    }
}
/* Server List Card Design */
.card-server {
    background-color: #1e1e1e;
    border: 1px solid #333;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    position: relative;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
    color: #ddd;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-server:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.4);
    border-color: #444;
}

.card-server .row {
    display: flex;
    flex-wrap: wrap;
    margin-right: -15px;
    margin-left: -15px;
    padding-bottom: 0;
}

.card-server .col-12 {
    width: 100%;
    padding-right: 15px;
    padding-left: 15px;
    box-sizing: border-box;
}

@media (min-width: 768px) {
    .card-server .col-md-5 {
        flex: 0 0 41.666667%;
        max-width: 41.666667%;
    }
    .card-server .col {
        flex-basis: 0;
        flex-grow: 1;
        max-width: 100%;
    }
}

@media (min-width: 992px) {
    .card-server .col-lg-auto {
        flex: 0 0 auto;
        width: auto;
        max-width: 100%;
    }
}

/* Rank Badge */
.card-rank {
    background-color: #d4af37;
    color: #000;
    padding: 5px 12px;
    font-weight: 800;
    font-size: 1.1rem;
    position: absolute;
    top: 15px;
    left: -8px;
    z-index: 10;
    box-shadow: 2px 2px 5px rgba(0,0,0,0.5);
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 10% 50%); /* Optional shape */
    border-radius: 0 4px 4px 0;
}

.card-rank::before {
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    width: 8px;
    height: 8px;
    background-color: #8a701f; /* Darker gold for fold */
    clip-path: polygon(0 0, 100% 0, 100% 100%);
}

/* Banner */
.server-banner-container {
    overflow: hidden;
}

.server-banner img {
    width: 100%;
    height: auto;
    max-height: 270px;
    object-fit: cover;
    display: block;
}

.srv-tag {
    display: inline-block;
    padding: 4px 8px;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: 4px;
    color: #fff;
    text-decoration: none;
    text-transform: uppercase;
    background-color: #333;
    transition: opacity 0.2s;
}

.srv-tag:hover {
    opacity: 0.9;
    text-decoration: none;
    color: #fff;
}

/* Content Header */
.server-content {
    padding: 15px 15px 0 15px;
    display: flex;
    flex-direction: column;
}

.server-title {
    color: #fff;
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 1.3rem;
    font-weight: 600;
    font-family: 'Segoe UI', sans-serif;
}

.server-title a {
    color: #fff;
    text-decoration: none;
    transition: color 0.2s;
}

.server-title a:hover {
    color: #d4af37;
}

.server-description {
    color: #aaa;
    font-size: 0.95rem;
    line-height: 1.5;
    overflow-wrap: anywhere;
    word-break: break-word;
}

/* Stats Column */
.server-stats-col {
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-width: 200px;
    position: relative;
    z-index: 5;
}

.box-stats {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    border-radius: 8px;
    background-color: #252525;
    border: 1px solid #333;
    transition: transform 0.2s;
}

.box-stats:hover {
    transform: translateX(2px);
}

.box-stats.vote-box {
    background: linear-gradient(135deg, #d4af37 0%, #b5922b 100%);
    color: #1a1a1a;
    border: none;
}

.box-stats.vote-box i,
.box-stats.vote-box .count,
.box-stats.vote-box .label {
    color: #1a1a1a !important;
}

.box-stats i {
    font-size: 1.2rem;
    margin-right: 12px;
    width: 20px;
    text-align: center;
}

.box-stats .count {
    font-weight: 800;
    font-size: 1.1rem;
}

.box-stats .label {
    margin-left: 6px;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    opacity: 0.9;
}

/* Reviews */
.box-reviews {
    display: flex;
    align-items: center;
    padding: 5px 0;
    color: #d4af37;
}

.box-reviews i {
    margin-right: 2px;
}

.box-reviews span {
    color: #888;
    margin-left: 8px;
    font-size: 0.9rem;
}

/* Tags */
.server-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

/* Footer */
.card-footer {
    padding: 15px 20px;
    border-top: 1px solid #333;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 15px;
    background-color: rgba(0,0,0,0.2);
    border-radius: 0 0 12px 12px;
    position: relative;
    z-index: 1;
}

.footer-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.slots-info {
    background-color: #2a2a2a;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #ccc;
    border: 1px solid #333;
}

.slots-info var {
    font-style: normal;
    font-weight: bold;
    color: #fff;
}

.discord-link {
    color: #7289da;
    font-size: 1.5rem;
    transition: transform 0.2s;
    display: flex;
    align-items: center;
}

.discord-link:hover {
    transform: scale(1.1);
    color: #fff;
}

.footer-actions {
    display: flex;
    gap: 10px;
}

.btn-visit {
    border: 1px solid #d4af37;
    color: #d4af37;
    background: transparent;
    padding: 8px 16px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.2s;
}

.btn-visit:hover {
    background-color: rgba(212, 175, 55, 0.1);
    color: #fff;
    text-decoration: none;
}

.btn-vote {
    background-color: #d4af37;
    color: #000;
    border: 1px solid #d4af37;
    padding: 8px 24px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 800;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.2s;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.btn-vote:hover {
    background-color: #fff;
    border-color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
    color: #000;
}

/* Responsive adjustments */
@media (max-width: 767px) {
    .server-banner img {
        object-fit: cover;
    }
    .server-stats-col {
        flex-direction: row;
        flex-wrap: wrap;
        margin-bottom: 10px;
        z-index: 5;
    }
    .box-stats {
        flex: 1;
        justify-content: center;
    }
    .box-reviews {
        width: 100%;
        justify-content: center;
        padding: 10px 0;
    }
    .card-footer {
        flex-direction: column;
        align-items: stretch;
        position: relative;
        z-index: 1;
    }
    .footer-left, .footer-actions {
        justify-content: space-between;
        width: 100%;
    }
    .btn-visit, .btn-vote {
        flex: 1;
        text-align: center;
    }
}

/* Server List Header */
.server-list-header {
    padding: 80px 20px 150px;
    position: relative;
    z-index: 1;
    text-align: center;
    color: #fff;
    min-height: 250px;
}

.server-list-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 470px;
    background: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url('/assets/images/server-header.webp');
    background-size: cover;
    background-position: center;
    clip-path: url(#hero-mask);
    z-index: -1;
}

.server-list-header h1 {
    font-family: 'norsebold', sans-serif;
    font-size: 3.5em;
    color: #d4af37;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
    margin-bottom: 10px;
}

.pagination {
    text-align: center;
    margin-top: 40px;
    margin-bottom: 40px;
}

.pagination a {
    display: inline-block;
    padding: 10px 15px;
    background: #1e1e1e;
    color: #fff;
    text-decoration: none;
    margin: 0 5px;
    border-radius: 3px;
    border: 1px solid #333;
}

.pagination a.active, .pagination a:hover {
    background: #d4af37;
    color: #000;
    border-color: #d4af37;
}

/* Server Profile Layout (matching Forum) */
.server-profile-content {
    max-width: 1200px;
    margin: 30px auto 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 30px;
    padding: 0 20px;
}

.server-profile-content.stats-page {
    grid-template-columns: 1fr;
}

.server-profile-main {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.server-profile-sidebar {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

@media (max-width: 900px) {
    .server-profile-content {
        grid-template-columns: 1fr;
    }
}

/* Fix for breadcrumb layout in server header */
.server-page-header .container {
    display: block;
}
.forum-page {
    background: transparent; /* Let global body background show through */
    padding-bottom: 80px;
}

.forum-hero {
    padding: 80px 20px 150px;
    position: relative;
    min-height: 250px;
    margin-bottom: 5px;
}

.forum-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 470px;
    background: linear-gradient(145deg, rgba(5, 7, 13, 0.85), rgba(10, 14, 24, 0.85)), url('/assets/images/forum-bg.jpg');
    background-size: cover;
    background-position: center;
    clip-path: url(#hero-mask);
    z-index: 1;
}

/* Add texture overlay to hero if needed, or rely on transparency */

.hero-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 20px 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    align-items: stretch;
    position: relative;
    z-index: 2;
    margin-top: -60px;
}

.forum-hero .hero-content {
    padding: 32px;
    background: rgba(20, 20, 20, 0.8);
    border-radius: 4px;
    border: 1px solid rgba(212, 175, 55, 0.2);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero-eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 0.9rem;
    color: #d4af37;
    margin: 0 0 10px;
    font-weight: bold;
}

.hero-content h1 {
    margin: 0 0 15px;
    font-family: 'norsebold', sans-serif;
    font-size: clamp(2.5rem, 5vw, 4rem);
    color: #fff;
    text-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

.hero-copy {
    margin: 0 0 25px;
    color: #ccc;
    line-height: 1.6;
    font-size: 1.1rem;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 30px;
}

.forum-page .btn {
    display: inline-block;
    border: none;
    border-radius: 2px;
    padding: 12px 26px;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 0.08em;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Segoe UI', sans-serif;
}

.forum-page .btn-primary {
    background: #d4af37;
    color: #10121c;
    box-shadow: 0 5px 15px rgba(212, 175, 55, 0.2);
}

.forum-page .btn-primary:hover {
    background: #fff;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(212, 175, 55, 0.3);
}

.forum-page .btn-ghost {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
}

.forum-page .btn-ghost:hover {
    border-color: #d4af37;
    color: #d4af37;
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
    gap: 15px;
    margin: 0;
}

.hero-stats div {
    background: rgba(0, 0, 0, 0.4);
    padding: 16px;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.hero-stats dt {
    font-size: 0.75rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #888;
    margin: 0 0 6px;
}

.hero-stats dd {
    margin: 0;
    font-size: 1.4rem;
    font-weight: 700;
    color: #d4af37;
}

.hero-search {
    background: rgba(20, 20, 20, 0.8);
    padding: 24px;
    border-radius: 4px;
    border: 1px solid rgba(212, 175, 55, 0.2);
    display: flex;
    flex-direction: column;
    gap: 16px;
    justify-content: center;
}

.search-field {
    position: relative;
}

.search-field i {
    position: absolute;
    top: 50%;
    left: 18px;
    transform: translateY(-50%);
    color: #888;
}

.search-field input {
    width: 100%;
    box-sizing: border-box;
    padding: 14px 18px 14px 50px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    color: #fff;
    font-size: 1rem;
}

.search-field input:focus {
    outline: none;
    border-color: #d4af37;
    box-shadow: 0 0 0 1px rgba(212, 175, 55, 0.5);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

.forum-search-status {
    max-width: 1200px;
    margin: 20px auto 0;
    padding: 15px 25px;
    border-radius: 4px;
    background: rgba(20, 20, 20, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    gap: 15px;
    align-items: center;
}

.reset-search {
    color: #d4af37;
    font-weight: 600;
}

.forum-content {
    max-width: 1200px;
    margin: 30px auto 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 30px;
    padding: 0 20px;
}

/* Only apply negative margin when forum-hero exists (on index page) */
.forum-hero ~ .forum-content {
    margin-top: -120px;
}

.forum-main {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.forum-section {
    background: rgba(20, 20, 20, 0.9);
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 10px;
}

.section-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 25px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 15px;
}

.section-eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: #d4af37;
    margin: 0 0 5px;
    font-size: 0.75rem;
    font-weight: bold;
}

.section-header h2 {
    margin: 0;
    font-family: 'norsebold', sans-serif;
    font-size: 2rem;
    color: #fff;
}

.section-description {
    margin: 8px 0 0;
    color: #aaa;
    max-width: 650px;
}

.section-meta {
    display: flex;
    flex-direction: column;
    gap: 6px;
    color: #888;
    font-size: 0.85rem;
}

.section-meta i {
    margin-right: 6px;
    color: #d4af37;
}

.forum-category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.forum-card {
    background: rgba(30, 30, 30, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    padding: 22px;
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 20px;
    align-items: flex-start;
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.forum-card:hover {
    transform: translateY(-2px);
    border-color: #d4af37;
}

.forum-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 4px;
    background: rgba(212, 175, 55, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #d4af37;
    font-size: 1.4rem;
}

.forum-card-body h3 {
    margin: 0 0 6px;
    font-size: 1.2rem;
    font-family: 'norsebold', sans-serif;
}

.forum-card-body h3 a {
    color: #fff;
    text-decoration: none;
}

.forum-card-body h3 a:hover {
    color: #d4af37;
}

.forum-card-body p {
    margin: 0 0 12px;
    color: #ccc;
    line-height: 1.5;
    font-size: 0.95rem;
}

.forum-card-headline {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
}

.forum-card-activity {
    font-size: 0.8rem;
    color: #888;
    white-space: nowrap;
}

.forum-subforums {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.subforum-pill {
    padding: 4px 12px;
    border-radius: 2px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.75rem;
    color: #aaa;
    text-decoration: none;
    background: rgba(0,0,0,0.2);
}

.subforum-pill:hover {
    border-color: #d4af37;
    color: #d4af37;
}

.forum-card-stats {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    text-align: right;
}

.forum-card-stats .label {
    display: block;
    font-size: 0.7rem;
    text-transform: uppercase;
    color: #666;
    letter-spacing: 0.08em;
}

.forum-card-stats .value {
    font-size: 1.1rem;
    font-weight: 600;
    color: #d4af37;
}

.forum-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.sidebar-card {
    background: rgba(20, 20, 20, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    padding: 24px;
}

.sidebar-card h3 {
    margin: 0 0 20px;
    font-family: 'norsebold', sans-serif;
    color: #d4af37;
    font-size: 1.4rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 10px;
}

.latest-posts, .trending-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.latest-posts li a,
.trending-list li a {
    display: block;
    padding: 12px 14px;
    border-radius: 4px;
    background: rgba(30, 30, 30, 0.5);
    border: 1px solid transparent;
    text-decoration: none;
}

.latest-posts li a:hover,
.trending-list li a:hover {
    border-color: #d4af37;
    background: rgba(30, 30, 30, 0.8);
}

.latest-posts .title {
    display: block;
    font-weight: 600;
    margin-bottom: 4px;
    color: #fff;
}

.latest-posts .excerpt {
    display: block;
    font-size: 0.85rem;
    color: #aaa;
    margin-bottom: 6px;
}

.latest-posts .meta {
    font-size: 0.75rem;
    color: #666;
}

.trend-name {
    display: block;
    font-weight: 600;
    color: #fff;
}

.trend-meta {
    font-size: 0.8rem;
    color: #888;
}

.support-card p,
.guides-card p {
    color: #ccc;
    line-height: 1.5;
}

.guides-card ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.guides-card li a {
    color: #ddd;
    display: inline-flex;
    gap: 10px;
    align-items: center;
    text-decoration: none;
    transition: color 0.2s;
}

.guides-card li a:hover {
    color: #d4af37;
}

.support-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 15px;
}

.forum-empty {
    text-align: center;
    padding: 60px 20px;
    border: 1px dashed rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.02);
}

.forum-empty h2 {
    margin-top: 0;
    font-family: 'norsebold', sans-serif;
    color: #fff;
}

.muted {
    color: #666;
}

@media (max-width: 1100px) {
    .forum-content {
        grid-template-columns: 1fr;
    }

    .forum-sidebar {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .sidebar-card {
        flex: 1 1 320px;
    }
}

@media (max-width: 768px) {
    .hero-inner {
        grid-template-columns: 1fr !important;
        gap: 20px;
        padding: 80px 15px 20px;
        margin-top: 0;
    }

    .forum-content {
        grid-template-columns: 1fr !important;
        padding: 0 10px;
        gap: 15px;
        max-width: 100%;
    }

    .forum-main {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0;
        gap: 15px;
    }

    .forum-section {
        padding: 15px;
        max-width: 100%;
        box-sizing: border-box;
    }

    .hero-content,
    .hero-search,
    .sidebar-card {
        padding: 15px;
        max-width: 100%;
        box-sizing: border-box;
    }

    .forum-card {
        grid-template-columns: 1fr;
    }

    .forum-card-stats {
        flex-direction: row;
        justify-content: space-between;
        text-align: left;
    }

    .section-header {
        flex-direction: column;
        gap: 15px;
    }

    .forum-search-status {
        flex-direction: column;
        text-align: center;
    }

    .forum-category-grid {
        grid-template-columns: 1fr !important;
        gap: 15px;
    }

    .forum-card {
        padding: 15px;
    }
}

/* Category View Styles */
.forum-header-wrapper {
    background: rgba(20, 20, 20, 0.95);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding: 20px 0;
    margin-bottom: 30px;
}

.forum-header-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.forum-breadcrumbs {
    font-size: 0.9rem;
    color: #888;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.forum-breadcrumbs a {
    color: #aaa;
    text-decoration: none;
    transition: color 0.2s;
}

.forum-breadcrumbs a:hover {
    color: #d4af37;
}

.forum-breadcrumbs .separator {
    color: #444;
    font-size: 0.8rem;
}

.forum-breadcrumbs .current {
    color: #fff;
    font-weight: 600;
}

.category-header-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
}

.category-info {
    flex: 1;
    min-width: 0;
}

.category-actions {
    flex-shrink: 0;
    align-self: flex-start;
}

.category-info h1 {
    font-family: 'norsebold', sans-serif;
    font-size: 2.5rem;
    color: #fff;
    margin: 0 0 10px;
}

.category-description {
    color: #aaa;
    margin: 0;
    font-size: 1rem;
    max-width: 800px;
}

.forum-thread-list {
    display: flex;
    flex-direction: column;
    gap: 2px; /* Small gap for list feel */
    background: rgba(20, 20, 20, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    overflow: hidden;
}

.thread-item {
    display: grid;
    grid-template-columns: 60px 1fr 120px 200px;
    gap: 15px;
    padding: 15px 20px;
    background: rgba(30, 30, 30, 0.4);
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    align-items: center;
    transition: background 0.2s;
}

.thread-item:last-child {
    border-bottom: none;
}

.thread-item:hover {
    background: rgba(40, 40, 40, 0.6);
}

.thread-avatar {
    display: flex;
    justify-content: center;
}

.avatar-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #333;
    color: #d4af37;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.2rem;
    border: 1px solid rgba(212, 175, 55, 0.3);
}

.thread-main {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.thread-title {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
}

.thread-title a {
    color: #fff;
    text-decoration: none;
    transition: color 0.2s;
}

.thread-title a:hover {
    color: #d4af37;
}

.thread-meta {
    font-size: 0.85rem;
    color: #888;
    display: flex;
    gap: 10px;
}

.thread-meta i {
    margin-right: 4px;
    color: #666;
}

.thread-stats {
    display: flex;
    justify-content: center;
}

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

.stat-value {
    display: block;
    font-size: 1.1rem;
    font-weight: 600;
    color: #ddd;
}

.stat-label {
    font-size: 0.75rem;
    color: #666;
    text-transform: uppercase;
}

.thread-last-post {
    text-align: right;
    font-size: 0.85rem;
}

.last-post-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.last-post-date {
    color: #aaa;
}

.last-post-user {
    color: #d4af37;
}

.sidebar-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.sidebar-stats div {
    background: rgba(0,0,0,0.2);
    padding: 10px;
    border-radius: 4px;
    text-align: center;
}

.sidebar-stats dt {
    font-size: 0.75rem;
    color: #888;
    text-transform: uppercase;
    margin-bottom: 5px;
}

.sidebar-stats dd {
    font-size: 1.2rem;
    font-weight: bold;
    color: #fff;
    margin: 0;
}

@media (max-width: 768px) {
    .category-header-content {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .thread-item {
        grid-template-columns: 1fr;
        gap: 10px;
        padding: 15px;
    }
    
    .thread-avatar, .thread-stats, .thread-last-post {
        display: none; /* Simplify for mobile or rearrange */
    }
    
    .thread-main {
        width: 100%;
    }
}

/* Topic View Styles */
.topic-meta-header {
    display: flex;
    gap: 15px;
    color: #aaa;
    font-size: 0.9rem;
    margin-top: 5px;
}

.topic-meta-header i {
    color: #d4af37;
    margin-right: 5px;
}

.topic-posts {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.forum-post {
    display: grid;
    grid-template-columns: 200px 1fr;
    background: rgba(20, 20, 20, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    overflow: hidden;
}

.post-sidebar {
    background: rgba(30, 30, 30, 0.4);
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.avatar-circle.large {
    width: 80px;
    height: 80px;
    font-size: 2.5rem;
    margin-bottom: 15px;
}

.user-details .username {
    display: block;
    font-weight: bold;
    color: #d4af37;
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.user-details .user-role {
    display: block;
    font-size: 0.8rem;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: rgba(255, 255, 255, 0.05);
    padding: 2px 8px;
    border-radius: 10px;
}

.post-content-wrapper {
    padding: 20px 30px;
    display: flex;
    flex-direction: column;
}

.post-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: #888;
    font-size: 0.85rem;
}

.post-body {
    flex: 1;
    color: #ddd;
    line-height: 1.7;
    font-size: 1rem;
}

.post-body img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin: 10px 0;
}

.post-footer {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: flex-end;
}

.reply-section {
    background: rgba(20, 20, 20, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    padding: 30px;
    margin-top: 30px;
}

.reply-section h3 {
    margin-top: 0;
    color: #fff;
    font-family: 'norsebold', sans-serif;
}

.forum-form textarea {
    width: 100%;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    padding: 15px;
    color: #fff;
    font-family: inherit;
    resize: vertical;
}

.forum-form textarea:focus {
    outline: none;
    border-color: #d4af37;
}

.login-to-reply {
    text-align: center;
    padding: 30px;
    background: rgba(20, 20, 20, 0.9);
    border-radius: 4px;
    margin-top: 30px;
    color: #aaa;
}

.login-to-reply a {
    color: #d4af37;
    text-decoration: none;
}

@media (max-width: 768px) {
    .forum-post {
        grid-template-columns: 1fr;
    }
    
    .post-sidebar {
        flex-direction: row;
        text-align: left;
        padding: 15px;
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
        gap: 15px;
    }
    
    .avatar-circle.large {
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
        margin-bottom: 0;
    }
    
    .post-content-wrapper {
        padding: 20px;
    }
}

/* Simple Editor Styles */
.simple-editor {
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    background: rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.editor-toolbar {
    background: rgba(40, 40, 40, 0.9);
    padding: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    gap: 5px;
    align-items: center;
    flex-wrap: wrap;
}

.editor-btn {
    background: transparent;
    border: 1px solid transparent;
    color: #ccc;
    width: 32px;
    height: 32px;
    border-radius: 3px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.editor-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.editor-btn:active {
    background: rgba(212, 175, 55, 0.2);
    color: #d4af37;
}

.toolbar-separator {
    width: 1px;
    height: 20px;
    background: rgba(255, 255, 255, 0.1);
    margin: 0 5px;
}

.editor-content {
    min-height: 200px;
    padding: 15px;
    color: #ddd;
    outline: none;
    line-height: 1.6;
}

.editor-content:focus {
    background: rgba(0, 0, 0, 0.2);
}

.editor-content img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin: 10px 0;
}

.editor-content ul, .editor-content ol {
    padding-left: 20px;
    margin: 10px 0;
}

.editor-content a {
    color: #d4af37;
    text-decoration: underline;
}

/* Forum Image Attachments & Lightbox */
.forum-attachment-preview {
    max-width: 300px !important;
    max-height: 300px !important;
    width: auto !important;
    height: auto !important;
    border-radius: 4px;
    cursor: zoom-in;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.2s, border-color 0.2s;
    display: block;
    margin: 10px 0;
}

.forum-attachment-full {
    max-width: 100%;
    width: auto;
    height: auto;
    border-radius: 4px;
    cursor: zoom-in;
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: block;
    margin: 10px 0;
}

.forum-attachment-preview:hover, .forum-attachment-full:hover {
    transform: scale(1.01);
    border-color: #d4af37;
}

/* Lightbox Overlay */
.lightbox-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    backdrop-filter: blur(5px);
}

.lightbox-overlay.active {
    opacity: 1;
    visibility: visible;
}

.lightbox-content {
    max-width: 95%;
    max-height: 95%;
    position: relative;
    box-shadow: 0 0 50px rgba(0,0,0,0.5);
}

.lightbox-image {
    max-width: 100%;
    max-height: 90vh;
    display: block;
    border-radius: 2px;
    object-fit: contain;
}

.lightbox-close {
    position: absolute;
    top: -40px;
    right: 0;
    color: #fff;
    font-size: 30px;
    cursor: pointer;
    background: none;
    border: none;
    padding: 5px;
    transition: color 0.2s;
}

.lightbox-close:hover {
    color: #d4af37;
}

/* Editor Modal */
.editor-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s;
    backdrop-filter: blur(3px);
}

.editor-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.editor-modal {
    background: #1e1e1e;
    border: 1px solid #d4af37;
    border-radius: 4px;
    padding: 25px;
    width: 400px;
    max-width: 90%;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    text-align: center;
    position: relative;
}

.editor-modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    color: #888;
    font-size: 1.5rem;
    cursor: pointer;
    line-height: 1;
    padding: 0 5px;
}

.editor-modal-close:hover {
    color: #d4af37;
}

.editor-modal h3 {
    margin-top: 0;
    color: #d4af37;
    font-family: 'norsebold', sans-serif;
    font-size: 1.5rem;
}

.editor-modal p {
    color: #ccc;
    margin-bottom: 25px;
}

.editor-modal-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.editor-modal-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    font-weight: bold;
    text-transform: uppercase;
    transition: all 0.2s;
}

.editor-modal-btn.primary {
    background: #d4af37;
    color: #000;
}

.editor-modal-btn.primary:hover {
    background: #fff;
}

.editor-modal-btn.secondary {
    background: #333;
    color: #fff;
    border: 1px solid #555;
}

.editor-modal-btn.secondary:hover {
    border-color: #d4af37;
    color: #d4af37;
}

/* Custom Select Styles */
.custom-select-wrapper {
    position: relative;
    user-select: none;
    width: 100%;
}

.custom-select-trigger {
    position: relative;
    display: block;
    width: 100%;
    padding: 12px;
    background-color: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
    box-sizing: border-box;
}

.custom-select-trigger:after {
    content: '';
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    width: 0; 
    height: 0; 
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid #d4af37;
}

.custom-select-wrapper.open .custom-select-trigger {
    border-color: #d4af37;
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    background-color: rgba(0, 0, 0, 0.5);
}

.custom-options {
    position: absolute;
    display: block;
    top: 100%;
    left: 0;
    right: 0;
    border: 1px solid #d4af37;
    border-top: 0;
    background: #1e1e1e;
    transition: all 0.2s;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    z-index: 100;
    max-height: 300px;
    overflow-y: auto;
    border-bottom-left-radius: 4px;
    border-bottom-right-radius: 4px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.5);
}

.custom-select-wrapper.open .custom-options {
    opacity: 1;
    visibility: visible;
    pointer-events: all;
}

.custom-option {
    position: relative;
    display: block;
    padding: 10px 15px;
    font-size: 0.95rem;
    font-weight: 300;
    color: #ccc;
    cursor: pointer;
    transition: all 0.2s;
}

.custom-option:hover {
    background-color: #d4af37;
    color: #000;
}

.custom-option.selected {
    color: #d4af37;
    font-weight: bold;
    background-color: rgba(212, 175, 55, 0.1);
}

.custom-option.selected:hover {
    color: #000;
    background-color: #d4af37;
}

.custom-option-group {
    padding: 10px 15px;
    font-weight: bold;
    color: #d4af37;
    background: #252525;
    cursor: default;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

/* Form Elements */
.forum-select {
    width: 100%;
    padding: 12px;
    background-color: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    border-radius: 4px;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23d4af37%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E");
    background-repeat: no-repeat;
    background-position: right 15px top 50%;
    background-size: 12px auto;
    cursor: pointer;
    color-scheme: dark;
}

.forum-select:focus {
    outline: none;
    border-color: #d4af37;
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
}

.forum-select option {
    background-color: #1e1e1e;
    color: #fff;
    padding: 10px;
}

.forum-select optgroup {
    background-color: #1e1e1e;
    color: #d4af37;
    font-weight: bold;
}

.forum-input {
    width: 100%;
    padding: 12px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    border-radius: 4px;
    box-sizing: border-box;
}

.forum-input:focus {
    outline: none;
    border-color: #d4af37;
}
#network-map {
    width: 100%;
    height: 800px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 8px;
}

.map-container {
    max-width: 1600px;
    margin: 40px auto;
    padding: 0 30px;
}

.map-controls {
    background: rgba(20, 20, 20, 0.95);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    gap: 20px;
    align-items: center;
    flex-wrap: wrap;
}

.map-control-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.map-control-group label {
    color: #ddd;
    font-weight: bold;
}

.map-search {
    padding: 8px 12px;
    border-radius: 4px;
    border: 1px solid #444;
    background: #222;
    color: #fff;
    min-width: 200px;
}

.map-checkbox {
    accent-color: #d4af37;
    width: 18px;
    height: 18px;
}

.map-legend {
    display: flex;
    gap: 15px;
    margin-left: auto;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.9em;
    color: #aaa;
}

.legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.loading-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #d4af37;
    font-size: 1.5em;
    pointer-events: none;
    z-index: 10;
}

/* Vis.js Tooltip Styling */
div.vis-tooltip {
    background-color: rgba(15, 15, 20, 0.98) !important;
    border: 2px solid #d4af37 !important;
    color: #eee !important;
    border-radius: 6px !important;
    padding: 0 !important;
    z-index: 1000 !important;
    font-family: 'Segoe UI', sans-serif !important;
    box-shadow: 0 8px 32px rgba(0,0,0,0.8) !important;
    backdrop-filter: blur(5px);
    min-width: 280px;
}

.map-tooltip-content {
    padding: 15px;
}

.map-tooltip-header {
    font-size: 1.3em;
    font-weight: bold;
    color: #d4af37;
    margin-bottom: 8px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.3);
    padding-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.map-tooltip-meta {
    font-size: 0.9em;
    color: #bbb;
    margin-bottom: 3px;
    display: flex;
    justify-content: space-between;
}

.map-tooltip-divider {
    height: 1px;
    background: linear-gradient(to right, transparent, rgba(212, 175, 55, 0.5), transparent);
    margin: 12px 0;
}

.map-tooltip-section {
    font-weight: bold;
    color: #fff;
    margin-bottom: 8px;
    font-size: 1em;
}

.map-tooltip-portal {
    display: grid;
    grid-template-columns: auto 1fr auto 1fr;
    align-items: center;
    gap: 8px;
    font-size: 0.95em;
    margin-bottom: 4px;
    background: rgba(255, 255, 255, 0.03);
    padding: 6px 10px;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.portal-bullet {
    color: #d4af37;
    font-size: 1.2em;
    line-height: 0.5;
}

.portal-source {
    color: #fff;
    font-weight: 600;
}

.portal-arrow {
    color: #d4af37;
    font-weight: bold;
}

.portal-target {
    color: #ccc;
}

.map-tooltip-empty {
    font-style: italic;
    color: #777;
    padding: 10px;
    text-align: center;
    background: rgba(0,0,0,0.2);
    border-radius: 4px;
}

/* Sidebar Toggle Styles */
.sidebar-toggle-btn {
    width: 100%;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.2);
    color: #aaa;
}

.sidebar-toggle-btn i {
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
}

.forum-content.sidebar-collapsed .sidebar-toggle-btn i {
    transform: rotate(180deg);
}

.sidebar-toggle-btn:hover {
    background: rgba(212, 175, 55, 0.1);
    color: #d4af37;
    border-color: #d4af37;
}

/* Collapsed State */
.forum-content.sidebar-collapsed {
    grid-template-columns: 1fr; /* Use full width for content */
    position: relative;
}

.forum-content.sidebar-collapsed .forum-main {
    width: 100%;
    margin: 0;
}

.forum-content.sidebar-collapsed .sidebar-content-wrapper {
    display: none;
}

.forum-content.sidebar-collapsed .forum-sidebar {
    position: absolute;
    right: 0;
    top: 0;
    width: auto;
    padding: 0;
    background: transparent;
    border: none;
    z-index: 10;
}

.forum-content.sidebar-collapsed .sidebar-toggle-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(20, 20, 20, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #d4af37;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
    margin-bottom: 0;
}

.forum-content.sidebar-collapsed .sidebar-toggle-btn:hover {
    background: #d4af37;
    color: #10121c;
}

/* Force 2 columns in grid when sidebar is collapsed */
.forum-content.sidebar-collapsed .forum-category-grid {
    grid-template-columns: repeat(2, 1fr);
}

.forum-content.sidebar-collapsed .sidebar-toggle-btn .btn-text {
    display: none;
}

/* Responsive adjustment */
@media (max-width: 900px) {
    .forum-content.sidebar-collapsed {
        grid-template-columns: 1fr;
    }
    
    .forum-content.sidebar-collapsed .forum-sidebar {
        display: none; /* Hide completely on mobile if collapsed, or keep button? */
        /* Usually on mobile sidebar is stacked below, so collapsing might just hide it */
    }
    
    /* If sidebar is stacked, grid-template-columns is 1fr usually */
}

/* ===========================
   SERVER STATS PAGE STYLES
   =========================== */

/* Server stats header + layout */
.server-page-header { background-color: #1a1a1a; padding: 40px 0; border-bottom: 1px solid #333; margin-bottom: 30px; }
.header-layout { display: flex; justify-content: space-between; align-items: flex-end; gap: 40px; }
.header-left { flex: 1; display: flex; flex-direction: column; gap: 15px; min-width: 0; }
.header-right { display: flex; gap: 20px; align-items: center; flex-shrink: 0; }
.server-identity h1 { font-family: 'norsebold', sans-serif; font-size: 3em; color: #fff; margin: 0 0 10px 0; line-height: 1; text-transform: uppercase; text-shadow: 0 2px 10px rgba(0,0,0,0.5); }
.server-subtitle { color: #d4af37; font-size: 1.2em; text-transform: uppercase; letter-spacing: 2px; font-weight: bold; }

.rank-wrapper { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 8px; contain: layout style; }
.rank-badge { background: #d4af37; color: #000; padding: 10px 15px; border-radius: 4px; font-weight: bold; display: flex; flex-direction: column; align-items: center; line-height: 1.2; min-width: 90px; box-shadow: 0 5px 15px rgba(0,0,0,0.3); will-change: transform; }
.rank-label { font-size: 0.8em; text-transform: uppercase; letter-spacing: 1px; }
.rank-value { font-size: 1.6em; font-weight: 800; }

.server-nav { display: flex; background: #111; border-radius: 4px; overflow: hidden; border: 1px solid #333; }
.server-nav .nav-item { display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 15px 25px; color: #888; text-decoration: none; font-weight: bold; text-transform: uppercase; font-size: 0.85em; border-right: 1px solid #333; transition: all 0.2s; min-height: 80px; line-height: 1.3; min-width: 100px; }
.server-nav .nav-item:last-child { border-right: none; }
.server-nav .nav-item:hover, .server-nav .nav-item.active { background: #1e1e1e; color: #d4af37; }
.server-nav .nav-item.active { box-shadow: inset 0 3px 0 #d4af37; }
.nav-label { display: block; }

.server-profile-content { max-width: 1200px; margin: 30px auto 0; display: grid; grid-template-columns: 1fr; gap: 30px; padding: 0 20px; }
.server-profile-content.stats-page { grid-template-columns: 1fr; }
.server-profile-main { display: flex; flex-direction: column; gap: 30px; }

.content-block { background: #1e1e1e; border: 1px solid #333; padding: 25px; margin-bottom: 30px; border-radius: 4px; }
.block-title-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.block-title { color: #fff; font-family: 'norsebold', sans-serif; font-size: 1.5em; margin: 0 0 20px 0; border-bottom: 1px solid #333; padding-bottom: 10px; }

.collapse-toggle { position: relative; overflow: hidden; display: inline-flex; align-items: center; justify-content: center; height: 46px; padding: 10px 18px; font-family: 'Heretic', 'norsebold', 'Segoe UI', sans-serif; font-size: 1.05rem; line-height: 1.4rem; font-weight: 400; text-transform: uppercase; color: #181614; background: transparent; border: 0; box-shadow: none; text-decoration: none; transition: 0.25s ease; cursor: pointer; }
.collapse-toggle .btn-text { position: relative; z-index: 20; display: inline-flex; align-items: center; gap: 8px; color: #181614; }
.collapse-toggle .btn-bg { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; overflow: hidden; background-image: linear-gradient(to right, #d4af37, #b88f24); clip-path: url(#btn-mask); }
.collapsible-body.collapsed { display: none; }

.breadcrumb { color: #888; font-size: 0.9em; margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.breadcrumb a { color: #aaa; text-decoration: none; transition: color 0.2s; }
.breadcrumb a:hover { color: #d4af37; }
.breadcrumb span { color: #fff; }

.live-stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 14px; }
.live-stat { background: #252525; border: 1px solid #333; border-radius: 4px; padding: 12px 14px; }
.live-label { color: #888; font-size: 0.85em; text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 4px; }
.live-value { color: #fff; font-size: 1.3em; font-weight: 700; }

.player-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
.query-status-grid, .query-stats-grid { width: 100%; }
.query-chart-container { width: 100%; overflow-x: auto; }
.query-chart-container canvas { min-width: 260px; }

.player-card { background: #252525; border: 1px solid #333; border-radius: 4px; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; }

/* Player card grid layout */
.player-card-grid { display: grid; grid-template-columns: 200px 1fr 200px; grid-template-rows: auto auto; grid-template-areas: 'portrait stats fullbody' 'xp xp fullbody'; gap: 14px; align-items: start; }
.portrait-cell { grid-area: portrait; display: flex; align-items: center; justify-content: flex-start; margin-left: 20px; margin-top: 8px; }
.stats-cell { grid-area: stats; }
.fullbody-cell { grid-area: fullbody; display: flex; align-items: center; justify-content: center; }
.xp-cell { grid-area: xp; padding-top: 8px; }

/* Avatar styles */
.avatar-circle.large { width: 120px; height: 120px; object-fit: cover; border: 3px solid rgba(212, 175, 55, 0.5); border-radius: 50%; }
.avatar-placeholder { font-size: 6rem; border: 3px solid rgba(212, 175, 55, 0.3) !important; display: flex; align-items: center; justify-content: center; background: rgba(0,0,0,0.3); color: #d4af37; }
.fullbody-img { width: 170px; height: 260px; object-fit: cover; object-position: center; border: 3px solid rgba(212, 175, 55, 0.5); border-radius: 4px; background: rgba(0,0,0,0.3); }
.player-last-known { color: #888; margin-top: 6px; }
.player-id { color: #d4af37; font-weight: 700; word-break: break-word; }
.player-meta { color: #888; font-size: 0.9em; }
.player-stats-line { color: #fff; font-size: 0.95em; }
.xp-meta { color: #aaa; font-size: 0.85em; }
.xp-progress { background: #111; border: 1px solid #333; border-radius: 3px; height: 8px; overflow: hidden; margin: 2px 0 6px; }
.xp-bar { background: linear-gradient(90deg, #d4af37, #ffce54); height: 100%; width: 0; }

.event-list { list-style: none; padding: 0; margin: 0; }
.event-item { border-bottom: 1px solid #2a2a2a; padding: 12px 0; }
.event-item:last-child { border-bottom: none; }
.event-row { display: flex; justify-content: space-between; gap: 12px; }
.event-type { color: #d4af37; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; font-size: 0.95em; }
.event-player { color: #fff; font-weight: 600; margin-top: 4px; display: flex; flex-wrap: wrap; gap: 6px; align-items: baseline; }
.event-message { color: #ccc; margin-top: 4px; }
.event-meta { color: #888; font-size: 0.85em; margin-top: 4px; }
.event-time { color: #aaa; font-size: 0.9em; text-align: right; white-space: nowrap; }
.event-age { color: #666; font-size: 0.8em; margin-left: 4px; }

.rating-stars { color: #d4af37; font-size: 0.9em; }
.server-nav-mobile { display: none; width: 100%; }
.server-nav-mobile-label { display: block; margin: 0 0 8px; color: #aaa; font-size: 0.85em; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; }
.server-nav-select { width: 100%; padding: 14px 16px; background: #111; border: 1px solid #333; border-radius: 4px; color: #d4af37; font-weight: 800; text-transform: uppercase; font-size: 0.9em; }
.server-nav-select:focus { outline: none; border-color: #d4af37; box-shadow: 0 0 0 1px rgba(212, 175, 55, 0.5); }

.main-body { padding-bottom: 50px; }
.alert-info { background: rgba(33, 150, 243, 0.1); border: 1px solid #2196f3; color: #2196f3; padding: 15px; border-radius: 5px; margin-bottom: 15px; }

@media (max-width: 992px) {
    .header-layout { flex-direction: column; align-items: flex-start; }
    .header-right { width: 100%; justify-content: space-between; }
    .server-nav { flex: 1; }
}

@media (max-width: 768px) {
    /* Header */
    .server-page-header { padding: 20px 0; }
    .server-identity h1 { font-size: 1.8em; }
    .server-subtitle { font-size: 1em; }
    .header-layout { gap: 20px; }
    .header-right { flex-direction: column; align-items: flex-start; gap: 15px; }
    
    /* Navigation */
    .server-nav { display: none; }
    .server-nav-mobile { display: block; }
    
    /* Content blocks */
    .content-block { padding: 15px; margin-bottom: 20px; }
    .block-title { font-size: 1.2em; margin-bottom: 15px; }
    .collapse-toggle { padding: 8px 14px; font-size: 0.9rem; height: 38px; }
    
    /* Live stats grid */
    .live-stats-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .live-stat { padding: 10px 12px; }
    .live-label { font-size: 0.75em; }
    .live-value { font-size: 1.1em; }
    
    /* Query grids */
    .query-status-grid, .query-stats-grid { grid-template-columns: 1fr !important; gap: 12px; }
    .query-chart-container { padding: 12px !important; overflow-x: auto; }
    .query-chart-container canvas { min-width: 100%; }
    
    /* Player cards */
    .player-card { padding: 14px; }
    .player-card-grid { grid-template-columns: 1fr !important; grid-template-areas: 'portrait' 'stats' 'fullbody' 'xp' !important; justify-items: center; gap: 12px; }
    .portrait-cell { margin-left: 0 !important; margin-top: 4px !important; justify-content: center !important; }
    .stats-cell { text-align: center; width: 100%; }
    .fullbody-cell { justify-content: center !important; }
    .player-card-grid img.avatar-circle.large { width: 90px; height: 90px; }
    .player-card-grid .fullbody-img { width: 120px !important; height: 200px !important; }
    .player-id { font-size: 1em; }
    .player-meta { font-size: 0.85em; }
    
    /* Events */
    .event-item { padding: 10px 0; }
    .event-row { flex-direction: column; gap: 6px; }
    .event-time { text-align: left; margin-top: 4px; }
    .event-type { font-size: 0.85em; }
    .event-message { font-size: 0.9em; }
    
    /* Rank badge */
    .rank-badge { min-width: 70px; padding: 8px 12px; }
    .rank-value { font-size: 1.4em; }
}

@media (max-width: 480px) {
    /* Extra small screens */
    .server-identity h1 { font-size: 1.5em; }
    .server-subtitle { font-size: 0.9em; }
    
    /* Single column for live stats */
    .live-stats-grid { grid-template-columns: 1fr; }
    
    /* Smaller player avatars */
    .player-card-grid img.avatar-circle.large { width: 80px; height: 80px; }
    .player-card-grid .fullbody-img { width: 100px !important; height: 180px !important; }
    
    /* Compact event list */
    .event-type { font-size: 0.8em; }
    .event-player { font-size: 0.9em; }
    .event-message { font-size: 0.85em; }
    
    /* Breadcrumb */
    .breadcrumb { font-size: 0.8em; }
}
