:root {
    --background: #070a0f;
    --background-soft: #0b1018;
    --panel: #0f1620;
    --panel-hover: #141e2a;
    --border: #1d2937;
    --border-hover: #304156;
    --text: #f5f7fa;
    --text-soft: #98a5b6;
    --text-dark: #667386;
    --green: #66ff91;
    --green-hover: #8affaa;
    --green-soft: rgba(102, 255, 145, 0.08);
    --blue: #6aa7ff;
    --blue-hover: #8bbbff;
    --max-width: 1200px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    background: var(--background);
    color: var(--text);
    font-family: "Segoe UI", Arial, Helvetica, sans-serif;
    line-height: 1.5;
}

body.modal-open {
    overflow: hidden;
}

a {
    color: inherit;
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    height: 72px;
    background: rgba(7, 10, 15, 0.94);
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    backdrop-filter: blur(14px);
}

.topbar-container {
    width: min(var(--max-width), calc(100% - 40px));
    height: 100%;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    color: #ffffff;
    font-size: 24px;
    font-weight: 900;
    letter-spacing: -1px;
    text-decoration: none;
}

.logo span {
    color: var(--green);
}

.navigation {
    display: flex;
    align-items: center;
    gap: 4px;
}

.navigation a {
    padding: 10px 13px;
    color: var(--text-soft);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    border-radius: 7px;
    transition:
        background 0.15s ease,
        color 0.15s ease,
        border-color 0.15s ease,
        box-shadow 0.15s ease;
}

.navigation a:hover {
    color: white;
    background: rgba(255, 255, 255, 0.06);
}

.navigation .active {
    color: white;
}

.navigation a.privacy-button {
    color: #a9bbca;
}

.navigation a.privacy-button:hover {
    color: var(--green);
    background: rgba(102, 255, 145, 0.08);
}

.navigation a.staff-button {
    margin-left: 10px !important;
    padding-left: 18px !important;
    padding-right: 18px !important;
    color: #07101f !important;
    background: var(--blue) !important;
    border: 1px solid rgba(142, 190, 255, 0.65) !important;
    box-shadow: 0 0 16px rgba(106, 167, 255, 0.38) !important;
    font-weight: 800 !important;
}

.navigation a.staff-button:hover,
.navigation a.staff-button.active {
    color: #07101f !important;
    background: var(--blue-hover) !important;
    border-color: var(--blue-hover) !important;
    box-shadow: 0 0 24px rgba(106, 167, 255, 0.56) !important;
}

.navigation .account-button {
    margin-left: 4px;
    padding-left: 18px;
    padding-right: 18px;
    color: #07110a;
    background: var(--green);
    font-weight: 800;
}

.navigation .account-button:hover {
    color: #07110a;
    background: var(--green-hover);
}

.mobile-menu-button {
    display: none;
    border: 0;
    background: transparent;
    color: white;
    font-size: 26px;
    cursor: pointer;
}

.news-hero {
    position: relative;
    min-height: 420px;
    display: flex;
    align-items: center;
    overflow: hidden;
    background:
        linear-gradient(
            90deg,
            rgba(5, 9, 14, 0.94) 0%,
            rgba(5, 9, 14, 0.72) 45%,
            rgba(5, 9, 14, 0.90) 100%
        ),
        linear-gradient(
            180deg,
            rgba(5, 9, 14, 0.55) 0%,
            rgba(5, 9, 14, 1) 100%
        ),
        url("/images/MainMenu_Star.png");
    background-size: cover;
    background-position: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.news-hero-overlay {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        radial-gradient(
            circle at 70% 20%,
            rgba(102, 255, 145, 0.12),
            transparent 32%
        ),
        radial-gradient(
            circle at 20% 80%,
            rgba(106, 167, 255, 0.12),
            transparent 34%
        );
}

.news-hero-content {
    position: relative;
    z-index: 1;
    width: min(var(--max-width), calc(100% - 40px));
    margin: 0 auto;
}

.back-link {
    display: inline-flex;
    align-items: center;
    margin-bottom: 28px;
    color: var(--text-soft);
    text-decoration: none;
    font-size: 14px;
    font-weight: 700;
}

.back-link:hover {
    color: var(--green);
}

.hero-label {
    display: inline-flex;
    margin-bottom: 16px;
    padding: 7px 12px;
    color: var(--green);
    background: var(--green-soft);
    border: 1px solid rgba(102, 255, 145, 0.20);
    border-radius: 6px;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 2px;
}

.news-hero h1 {
    max-width: 800px;
    margin-bottom: 18px;
    font-size: clamp(48px, 7vw, 76px);
    line-height: 0.96;
    letter-spacing: -3px;
}

.news-hero p {
    max-width: 720px;
    color: var(--text-soft);
    font-size: 17px;
    line-height: 1.7;
}

.news-section {
    width: min(var(--max-width), calc(100% - 40px));
    margin: 0 auto;
    padding: 90px 0 110px;
}

.section-heading {
    max-width: 740px;
    margin-bottom: 44px;
}

.section-label {
    display: inline-block;
    margin-bottom: 13px;
    color: var(--green);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 1.8px;
}

.section-heading h2 {
    margin-bottom: 17px;
    font-size: clamp(32px, 5vw, 48px);
    line-height: 1.08;
    letter-spacing: -2px;
}

.section-heading p {
    color: var(--text-soft);
    font-size: 16px;
    line-height: 1.7;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.news-card {
    overflow: hidden;
    min-height: 100%;
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 12px;
    transition:
        transform 0.18s ease,
        background 0.18s ease,
        border-color 0.18s ease;
}

.news-card:hover {
    transform: translateY(-4px);
    background: var(--panel-hover);
    border-color: rgba(102, 255, 145, 0.25);
}

.news-card-featured {
    grid-column: span 2;
}

.news-card-button {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 0;
    color: inherit;
    text-align: left;
    background: transparent;
    border: 0;
    cursor: pointer;
    font: inherit;
}

.news-image {
    display: block;
    height: 210px;
    overflow: hidden;
    background: #080c12;
}

.news-card-featured .news-image {
    height: 300px;
}

.news-image img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    opacity: 0.88;
    transition:
        transform 0.25s ease,
        opacity 0.25s ease;
}

.news-card:hover .news-image img {
    transform: scale(1.04);
    opacity: 1;
}

.news-content {
    display: block;
    padding: 24px;
}

.news-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 14px;
    color: var(--green);
    font-size: 12px;
    font-weight: 800;
}

.news-meta span {
    padding: 5px 8px;
    background: var(--green-soft);
    border: 1px solid rgba(102, 255, 145, 0.14);
    border-radius: 6px;
}

.news-title {
    display: block;
    margin-bottom: 12px;
    color: var(--text);
    font-size: 24px;
    font-weight: 800;
    line-height: 1.16;
}

.news-summary {
    display: block;
    color: var(--text-soft);
    font-size: 14px;
    line-height: 1.7;
}

.news-card-button:hover .news-title {
    color: var(--green);
}

.read-more {
    display: inline-flex;
    margin-top: 22px;
    color: var(--green);
    text-decoration: none;
    font-size: 13px;
    font-weight: 800;
}

.empty-state {
    padding: 38px;
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 12px;
}

.empty-state h3 {
    margin-bottom: 8px;
}

.empty-state p {
    color: var(--text-soft);
}

.news-modal {
    position: fixed;
    inset: 0;
    z-index: 3000;
    display: none;
    padding: 24px;
    align-items: center;
    justify-content: center;
}

.news-modal.open {
    display: flex;
}

.news-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.72);
    backdrop-filter: blur(8px);
}

.news-modal-card {
    position: relative;
    z-index: 1;
    width: min(780px, 100%);
    overflow: hidden;
    background: #0f1620;
    border: 1px solid rgba(102, 255, 145, 0.22);
    border-radius: 14px;
    box-shadow: 0 28px 90px rgba(0, 0, 0, 0.72);
}

.news-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 2;
    width: 38px;
    height: 38px;
    color: white;
    background: rgba(7, 10, 15, 0.78);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 10px;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
}

.news-modal-close:hover {
    color: var(--green);
    border-color: rgba(102, 255, 145, 0.35);
}

.news-modal-image {
    height: 300px;
    background: #080c12;
}

.news-modal-image img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.news-modal-content {
    padding: 30px;
}

.news-modal-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.news-modal-meta span {
    padding: 5px 8px;
    color: var(--green);
    background: var(--green-soft);
    border: 1px solid rgba(102, 255, 145, 0.14);
    border-radius: 6px;
    font-size: 12px;
    font-weight: 800;
}

.news-modal-content h2 {
    margin-bottom: 14px;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.05;
}

.news-modal-content p {
    color: var(--text-soft);
    font-size: 16px;
    line-height: 1.75;
}

.footer {
    background: #05070b;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.footer-container {
    width: min(var(--max-width), calc(100% - 40px));
    margin: 0 auto;
    padding: 65px 0;
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 70px;
}

.footer-brand p {
    margin-top: 15px;
    color: var(--text-dark);
    font-size: 14px;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.footer-links h4 {
    margin-bottom: 16px;
    color: white;
    font-size: 13px;
}

.footer-links a {
    display: block;
    width: fit-content;
    margin-bottom: 9px;
    color: var(--text-dark);
    text-decoration: none;
    font-size: 13px;
    transition: color 0.15s ease;
}

.footer-links a:hover {
    color: var(--green);
}

.footer-bottom {
    width: min(var(--max-width), calc(100% - 40px));
    margin: 0 auto;
    padding: 22px 0;
    color: #596475;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 12px;
}

@media (max-width: 950px) {
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .news-card-featured {
        grid-column: span 2;
    }

    .footer-container {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    .mobile-menu-button {
        display: block;
    }

    .navigation {
        display: none;
        position: absolute;
        top: 72px;
        left: 0;
        width: 100%;
        padding: 15px 20px 22px;
        flex-direction: column;
        align-items: stretch;
        background: #080c12;
        border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    }

    .navigation.open {
        display: flex;
    }

    .navigation a {
        padding: 13px;
    }

    .navigation a.staff-button,
    .navigation .account-button {
        margin: 5px 0 0 !important;
    }

    .news-hero {
        min-height: 360px;
    }

    .news-hero h1 {
        letter-spacing: -2px;
    }

    .news-grid {
        grid-template-columns: 1fr;
    }

    .news-card-featured {
        grid-column: auto;
    }

    .news-card-featured .news-image,
    .news-image {
        height: 210px;
    }

    .news-modal {
        padding: 14px;
    }

    .news-modal-image {
        height: 210px;
    }

    .news-modal-content {
        padding: 22px;
    }

    .footer-links {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 500px) {
    .topbar-container,
    .news-hero-content,
    .news-section,
    .footer-container,
    .footer-bottom {
        width: calc(100% - 28px);
    }

    .news-hero h1 {
        font-size: 44px;
    }

    .news-hero p {
        font-size: 15px;
    }

    .news-section {
        padding: 70px 0 80px;
    }

    .news-content {
        padding: 20px;
    }

    .footer-links {
        gap: 35px 20px;
    }
}