* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg-main: #0b0b0b;
    --bg-secondary: #140000;
    --bg-tertiary: #1a0000;
    --card-bg: rgba(255, 255, 255, 0.045);
    --card-border: rgba(255, 59, 59, 0.25);
    --card-border-strong: rgba(255, 59, 59, 0.45);
    --text-main: #ffffff;
    --text-soft: #dddddd;
    --text-muted: #cfcfcf;
    --accent: #ff3b3b;
    --accent-dark: #d91f1f;
    --accent-soft: #ff7a7a;
    --shadow-soft: 0 0 20px rgba(255, 42, 42, 0.10);
    --shadow-medium: 0 0 24px rgba(255, 42, 42, 0.20);
    --shadow-strong: 0 0 30px rgba(255, 42, 42, 0.30);
    --radius-sm: 12px;
    --radius-md: 16px;
    --radius-lg: 18px;
    --radius-xl: 22px;
    --transition: 0.3s ease;
    --container-width: 1400px;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: Arial, sans-serif;
    background:
        radial-gradient(circle at top, rgba(255, 59, 59, 0.12), transparent 35%),
        linear-gradient(135deg, var(--bg-main), var(--bg-secondary) 45%, var(--bg-tertiary) 100%);
    color: var(--text-main);
    line-height: 1.6;
    min-height: 100vh;
}

/* Announcement Bar */
.announcement-bar {
    width: 100%;
    background: linear-gradient(135deg, rgba(255, 59, 59, 0.96), rgba(217, 31, 31, 0.96));
    color: #ffffff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: 0 4px 16px rgba(255, 42, 42, 0.20);
    position: relative;
    z-index: 1100;
}

.announcement-content {
    max-width: var(--container-width);
    margin: 0 auto;
    min-height: 52px;
    padding: 10px 20px;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 12px;
}

.announcement-message {
    grid-column: 2;
    text-align: center;
    font-weight: 600;
    font-size: 15px;
    line-height: 1.4;
}

.announcement-message span,
.announcement-message a,
#announcementText {
    color: #ffffff;
    text-decoration: none;
}

.announcement-message a:hover {
    text-decoration: underline;
}

.announcement-close {
    grid-column: 3;
    justify-self: end;
    appearance: none;
    -webkit-appearance: none;
    border: 1px solid rgba(255, 255, 255, 0.18);
    outline: none;
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
    width: 34px;
    height: 34px;
    min-width: 34px;
    min-height: 34px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 22px;
    font-weight: bold;
    line-height: 1;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    box-shadow: none;
}

.announcement-close:hover {
    background: rgba(255, 255, 255, 0.20);
    transform: scale(1.05);
}

.announcement-close:focus {
    border-color: rgba(255, 255, 255, 0.4);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.12);
}

/* Navbar */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 50px;
    background: rgba(0, 0, 0, 0.88);
    border-bottom: 2px solid var(--accent);
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.35);
}

.logo {
    font-size: 28px;
    font-weight: 700;
    color: var(--accent);
    letter-spacing: 1px;
    text-transform: uppercase;
    text-shadow: 0 0 18px rgba(255, 59, 59, 0.35);
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 25px;
    align-items: center;
}

.nav-links a {
    color: var(--text-main);
    text-decoration: none;
    font-weight: bold;
    transition: var(--transition);
    position: relative;
    padding: 6px 0;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--accent);
}

.nav-links a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -3px;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: var(--transition);
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

/* Hero */
.hero {
    min-height: 88vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 80px 20px;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: "";
    position: absolute;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255, 59, 59, 0.18) 0%, transparent 70%);
    top: -120px;
    left: 50%;
    transform: translateX(-50%);
    pointer-events: none;
    filter: blur(10px);
}

.hero-content {
    max-width: 900px;
    position: relative;
    z-index: 1;
}

.tagline {
    display: inline-block;
    font-size: 15px;
    font-weight: bold;
    color: var(--accent-soft);
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 15px;
    padding: 8px 16px;
    border: 1px solid rgba(255, 59, 59, 0.3);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
}

.hero h1 {
    font-size: 64px;
    margin-bottom: 20px;
    color: var(--accent);
    line-height: 1.1;
    text-shadow: 0 0 30px rgba(255, 42, 42, 0.45);
}

.hero p {
    font-size: 20px;
    margin-bottom: 30px;
    color: var(--text-soft);
    max-width: 760px;
    margin-left: auto;
    margin-right: auto;
}

/* Error and maintenance hero helper */
.hero.error-hero h1,
.error-code {
    font-size: 110px;
    line-height: 1;
    margin-bottom: 18px;
    color: var(--accent);
    text-shadow:
        0 0 10px rgba(255, 59, 59, 0.35),
        0 0 24px rgba(255, 59, 59, 0.35),
        0 0 44px rgba(255, 59, 59, 0.25);
}

.error-subtitle {
    max-width: 700px;
    margin: 0 auto 24px auto;
    color: var(--text-soft);
    font-size: 20px;
}

.error-panel {
    max-width: 900px;
    margin: 30px auto 0 auto;
    padding: 30px;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(6px);
}

.error-links {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

/* Buttons */
.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
    margin-top: 10px;
}

.btn {
    display: inline-block;
    padding: 14px 28px;
    background: linear-gradient(135deg, #ff3434, var(--accent-dark));
    color: #fff;
    text-decoration: none;
    border-radius: var(--radius-sm);
    font-weight: bold;
    transition: var(--transition);
    border: 2px solid transparent;
    box-shadow: 0 0 18px rgba(255, 42, 42, 0.18);
    cursor: pointer;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 0 24px rgba(255, 42, 42, 0.35);
}

.btn-secondary {
    background: transparent;
    border: 2px solid var(--accent);
    color: var(--text-main);
}

.btn-secondary:hover {
    background: var(--accent);
    color: var(--text-main);
}

/* Forms */
input,
textarea,
select {
    width: 100%;
    padding: 14px 16px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255, 59, 59, 0.25);
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-main);
    outline: none;
    transition: var(--transition);
    font-size: 16px;
    font-family: inherit;
}

input::placeholder,
textarea::placeholder {
    color: #bbbbbb;
}

input:focus,
textarea:focus,
select:focus {
    border-color: rgba(255, 59, 59, 0.55);
    box-shadow: 0 0 12px rgba(255, 59, 59, 0.15);
}

label {
    display: block;
    text-align: left;
    margin-bottom: 8px;
    color: var(--text-soft);
    font-weight: bold;
}

.form-group {
    margin-bottom: 16px;
}

.maintenance-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-width: 520px;
    margin: 0 auto;
}

.maintenance-note {
    margin-top: 14px;
    color: var(--text-muted);
    font-size: 15px;
}

.maintenance-error {
    color: var(--accent-soft);
    margin-bottom: 15px;
    font-weight: bold;
}

/* Stats */
.stats {
    margin-top: 45px;
    display: flex;
    justify-content: center;
    gap: 22px;
    flex-wrap: wrap;
}

.stat {
    background: rgba(255, 255, 255, 0.05);
    padding: 20px 28px;
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 42, 42, 0.25);
    text-align: center;
    min-width: 160px;
    box-shadow: 0 0 20px rgba(255, 42, 42, 0.08);
    transition: var(--transition);
}

.stat:hover {
    transform: translateY(-4px);
    border-color: rgba(255, 42, 42, 0.45);
    box-shadow: 0 0 24px rgba(255, 42, 42, 0.18);
}

.stat h3 {
    color: var(--accent);
    font-size: 24px;
    margin-bottom: 6px;
}

.stat p {
    font-size: 14px;
    color: #cccccc;
    margin: 0;
}

/* Sections */
.intro {
    padding: 85px 40px;
    text-align: center;
}

.intro h2 {
    font-size: 40px;
    margin-bottom: 18px;
    color: var(--accent);
    text-shadow: 0 0 16px rgba(255, 42, 42, 0.18);
}

.intro > p {
    max-width: 800px;
    margin: 0 auto 35px auto;
    color: #d9d9d9;
    font-size: 18px;
}

/* Cards */
.cards {
    display: flex;
    justify-content: center;
    gap: 25px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-lg);
    padding: 30px;
    width: 320px;
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
    backdrop-filter: blur(6px);
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: 0 0 28px rgba(255, 42, 42, 0.22);
    border-color: var(--card-border-strong);
}

.card h3 {
    color: var(--accent);
    margin-bottom: 15px;
    font-size: 24px;
}

.card p {
    color: var(--text-soft);
    font-size: 16px;
}

.card strong {
    color: var(--text-main);
}

/* Live Status Card */
#live-status-card {
    position: relative;
    overflow: hidden;
}

#live-status-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 59, 59, 0.06), transparent 45%);
    pointer-events: none;
}

#live-status-card > * {
    position: relative;
    z-index: 1;
}

#next-stream-card {
    position: relative;
}

/* Twitch Section */
.twitch-section {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 30px;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(6px);
}

.embed-status-text {
    text-align: center;
    font-size: 18px;
    color: var(--text-soft);
    margin-bottom: 25px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.twitch-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
    align-items: stretch;
    width: 100%;
}

.twitch-player-wrap,
.twitch-chat-wrap {
    width: 100%;
}

#twitch-player,
#twitch-chat {
    width: 100%;
    display: block;
    border: 1px solid rgba(255, 59, 59, 0.28);
    border-radius: var(--radius-lg);
    background: rgba(0, 0, 0, 0.45);
    box-shadow: var(--shadow-soft);
}

#twitch-player {
    height: 540px;
}

#twitch-chat {
    height: 540px;
}

/* Footer */
.footer {
    text-align: center;
    padding: 28px 20px;
    background: rgba(0, 0, 0, 0.88);
    border-top: 2px solid var(--accent);
    margin-top: 40px;
    color: #d0d0d0;
}

/* Utility */
a {
    transition: var(--transition);
}

img {
    max-width: 100%;
    display: block;
}

iframe {
    border: 0;
}

.hidden {
    display: none !important;
}

/* Responsive */
@media (max-width: 1100px) {
    .twitch-grid {
        grid-template-columns: 1fr;
    }

    #twitch-player {
        height: 500px;
    }

    #twitch-chat {
        height: 420px;
    }
}

@media (max-width: 992px) {
    .navbar {
        padding: 18px 24px;
        flex-direction: column;
        gap: 15px;
    }

    .nav-links {
        flex-wrap: wrap;
        justify-content: center;
        gap: 16px;
    }

    .hero h1 {
        font-size: 52px;
    }

    .hero p {
        font-size: 18px;
    }

    .intro {
        padding: 70px 24px;
    }

    .hero.error-hero h1,
    .error-code {
        font-size: 88px;
    }
}

@media (max-width: 768px) {
    .announcement-content {
        min-height: auto;
        grid-template-columns: 1fr auto;
        text-align: left;
        padding: 12px 14px;
        gap: 12px;
    }

    .announcement-message {
        grid-column: 1;
        text-align: left;
        font-size: 14px;
    }

    .announcement-close {
        grid-column: 2;
        justify-self: end;
    }

    .logo {
        font-size: 24px;
    }

    .hero {
        min-height: auto;
        padding: 70px 20px;
    }

    .hero h1 {
        font-size: 42px;
    }

    .hero p {
        font-size: 17px;
    }

    .tagline {
        font-size: 13px;
        letter-spacing: 1.5px;
    }

    .btn {
        width: 100%;
        max-width: 280px;
        text-align: center;
    }

    .hero-buttons,
    .error-links {
        flex-direction: column;
        align-items: center;
    }

    .stats {
        gap: 16px;
    }

    .stat {
        width: 100%;
        max-width: 260px;
    }

    .intro h2 {
        font-size: 32px;
    }

    .card {
        width: 100%;
        max-width: 360px;
    }

    .twitch-section {
        padding: 20px;
    }

    .embed-status-text {
        font-size: 16px;
    }

    #twitch-player {
        height: 360px;
    }

    #twitch-chat {
        height: 350px;
    }

    .hero.error-hero h1,
    .error-code {
        font-size: 72px;
    }

    .error-subtitle {
        font-size: 18px;
    }

    .error-panel {
        padding: 24px;
    }
}

@media (max-width: 480px) {
    .announcement-content {
        padding: 10px 12px;
        gap: 10px;
    }

    .announcement-message {
        font-size: 13px;
    }

    .announcement-close {
        width: 30px;
        height: 30px;
        min-width: 30px;
        min-height: 30px;
        font-size: 20px;
        border-radius: 8px;
    }

    .navbar {
        padding: 16px;
    }

    .hero h1 {
        font-size: 34px;
    }

    .hero p {
        font-size: 16px;
    }

    .intro {
        padding: 60px 16px;
    }

    .intro h2 {
        font-size: 28px;
    }

    .card {
        padding: 24px;
    }

    .card h3 {
        font-size: 21px;
    }

    #twitch-player {
        height: 260px;
    }

    #twitch-chat {
        height: 300px;
    }

    .hero.error-hero h1,
    .error-code {
        font-size: 56px;
    }

    .error-subtitle {
        font-size: 16px;
    }
}