:root {
    --bg0: #070712;
    --bg1: #0d0f1a;
    --text: #e8f1ff;
    --muted: rgba(232, 241, 255, 0.68);
    --glass: rgba(255, 255, 255, 0.06);
    --border: rgba(124, 245, 255, 0.22);
    --shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
    --radius: 16px;
    --font: "Inter", system-ui, sans-serif;
    --display: "Orbitron", var(--font);
}

html {
    scroll-behavior: smooth;
}

section[id],
.panel-anchor {
    scroll-margin-top: 5.5rem;
}

html[data-theme="light"] {
    --bg0: #f4f7ff;
    --bg1: #ffffff;
    --text: #0a1020;
    --muted: rgba(10, 16, 32, 0.62);
    --glass: rgba(255, 255, 255, 0.72);
    --border: rgba(10, 16, 32, 0.12);
    --shadow: 0 16px 40px rgba(20, 40, 90, 0.12);
}

*, *::before, *::after { box-sizing: border-box; }

body.site-body {
    margin: 0;
    min-height: 100vh;
    font-family: var(--font);
    color: var(--text);
    background: var(--bg0);
    line-height: 1.55;
}

.bg-anim {
    position: fixed;
    inset: 0;
    z-index: -2;
    background:
        radial-gradient(900px 500px at 15% 10%, color-mix(in srgb, var(--primary) 22%, transparent), transparent 60%),
        radial-gradient(800px 400px at 90% 20%, color-mix(in srgb, var(--neon) 18%, transparent), transparent 55%),
        linear-gradient(180deg, var(--bg0), var(--bg1));
    animation: bgPulse 14s ease-in-out infinite alternate;
}

@keyframes bgPulse {
    from { filter: saturate(1); transform: scale(1); }
    to { filter: saturate(1.15); transform: scale(1.02); }
}

.wrap {
    width: min(1180px, calc(100% - 2rem));
    margin-inline: auto;
}

.glass {
    background: var(--glass);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    backdrop-filter: blur(14px);
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid var(--border);
}

.topbar__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.85rem 0;
}

.brand {
    position: relative;
    text-decoration: none;
    color: var(--text);
    font-family: var(--display);
    font-weight: 700;
    letter-spacing: 0.06em;
}

.brand__glow {
    position: absolute;
    inset: -6px -10px;
    background: linear-gradient(90deg, var(--primary), var(--neon));
    opacity: 0.25;
    filter: blur(12px);
    border-radius: 999px;
    z-index: -1;
}

.nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 0.75rem;
    align-items: center;
}

.nav a, .nav .btn-icon {
    color: var(--text);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.92rem;
    padding: 0.4rem 0.55rem;
    border-radius: 10px;
    border: 1px solid transparent;
    background: transparent;
    cursor: pointer;
    font-family: inherit;
}

.nav a:hover, .nav .btn-icon:hover {
    border-color: color-mix(in srgb, var(--primary) 55%, transparent);
    box-shadow: 0 0 18px color-mix(in srgb, var(--primary) 35%, transparent);
}

.nav-toggle {
    display: none;
    background: var(--glass);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 0.45rem 0.75rem;
    border-radius: 10px;
    font-weight: 700;
}

@media (max-width: 900px) {
    .nav-toggle { display: inline-block; }
    .nav {
        display: none;
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        padding: 0.5rem 0 0.75rem;
    }
    .nav.is-open { display: flex; }
}

.main-content {
    padding: 1.25rem 0 3rem;
}

.profile-hero {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 1.25rem;
    align-items: center;
    padding: 1.25rem;
    margin-bottom: 1.5rem;
}

@media (max-width: 720px) {
    .profile-hero { grid-template-columns: 1fr; text-align: center; }
    .cta-row { justify-content: center; }
    .stat-chips { justify-content: center; }
}

.profile-hero__avatar-wrap {
    position: relative;
    width: 120px;
    height: 120px;
    margin-inline: auto;
}

.profile-hero__avatar {
    width: 120px;
    height: 120px;
    border-radius: 24px;
    object-fit: cover;
    border: 2px solid color-mix(in srgb, var(--primary) 70%, transparent);
    box-shadow: 0 0 30px color-mix(in srgb, var(--neon) 35%, transparent);
}

.ring {
    position: absolute;
    inset: -6px;
    border-radius: 28px;
    border: 2px solid var(--neon);
    opacity: 0.7;
}

.ring--pulse[hidden] { display: none; }

.ring--pulse {
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.04); opacity: 1; }
}

.profile-hero__name {
    margin: 0 0 0.25rem;
    font-family: var(--display);
    font-size: 1.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.badge-verified {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), var(--neon));
    color: #061018;
    font-size: 0.85rem;
    font-weight: 900;
}

.stat-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 0.75rem 0 1rem;
}

.chip {
    padding: 0.35rem 0.65rem;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: rgba(0, 0, 0, 0.2);
    font-size: 0.85rem;
}

.cta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.cta-row--col { flex-direction: column; align-items: stretch; }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.65rem 1rem;
    border-radius: 12px;
    border: 1px solid var(--border);
    text-decoration: none;
    font-weight: 700;
    cursor: pointer;
    color: var(--text);
    background: rgba(255, 255, 255, 0.04);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn:hover { transform: translateY(-1px); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25); }

.btn--primary {
    background: linear-gradient(90deg, var(--primary), color-mix(in srgb, var(--neon) 70%, var(--primary)));
    color: #061018;
    border-color: transparent;
}

.btn--ghost { background: transparent; }

.btn--twitch { background: #9146ff; border-color: transparent; color: #fff; }
.btn--yt { background: #ff0033; border-color: transparent; color: #fff; }
.btn--kick { background: #53fc18; border-color: transparent; color: #061018; }

.section {
    margin: 2rem 0;
}

.section__head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.section__head h2 {
    margin: 0;
    font-family: var(--display);
    letter-spacing: 0.04em;
}

.section-subhead {
    margin: 1.35rem 0 0.5rem;
    font-family: var(--display);
    font-size: 1.05rem;
    letter-spacing: 0.03em;
    font-weight: 700;
}

.section-panel {
    margin-inline: auto;
    width: min(1180px, calc(100% - 2rem));
    box-sizing: border-box;
}

.section-panel--narrow {
    max-width: 720px;
    width: 100%;
}

.section-panel > h2:first-child {
    margin: 0 0 0.35rem;
    font-family: var(--display);
    letter-spacing: 0.04em;
    font-size: clamp(1.15rem, 2.5vw, 1.35rem);
}

.section-panel__lede {
    margin: 0 0 1rem;
}

.section-panel__lede + .section-subhead {
    margin-top: 0.75rem;
}

.section-panel > h2 + .section-subhead {
    margin-top: 0.85rem;
}

.section-panel > h2 + .social-row {
    margin-top: 0.5rem;
}

.section-panel > h2 + .about-html {
    margin-top: 0.65rem;
}

.section-panel > h2 + .form,
.section-panel > h2 + .embed-stack,
.section-panel > h2 + .embed-freeform,
.section-panel > h2 + .discord-widget {
    margin-top: 0.65rem;
}

.section-panel > h2 + .announce-grid {
    margin-top: 0.65rem;
}

.muted { color: var(--muted); }

.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

@media (max-width: 900px) {
    .grid-2 { grid-template-columns: 1fr; }
}

.panel { padding: 1.1rem; }

.panel__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.panel__head h2, .panel__head h3 { margin: 0; font-family: var(--display); font-size: 1.1rem; }

.panel__title { font-weight: 700; margin: 0 0 0.35rem; }

.live-pill {
    font-family: var(--display);
    font-size: 0.72rem;
    letter-spacing: 0.12em;
    padding: 0.25rem 0.5rem;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: rgba(255, 0, 80, 0.12);
    color: #ff9ec0;
}

.embed {
    margin-top: 0.75rem;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border);
    aspect-ratio: 16 / 9;
}

.embed iframe { width: 100%; height: 100%; border: 0; }

.chat-embed { aspect-ratio: 3 / 5; max-height: 420px; }

.announce-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 0.75rem;
}

.announce { padding: 1rem; }

.announce h3 { margin: 0 0 0.35rem; font-size: 1rem; }

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 0.85rem;
}

.card-grid--short {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
}

.media-card {
    display: block;
    text-decoration: none;
    color: inherit;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.media-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35), 0 0 24px color-mix(in srgb, var(--primary) 25%, transparent);
}

.media-card img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    display: block;
}

.media-card--short img { aspect-ratio: 9 / 16; }

.media-card__body { padding: 0.65rem 0.75rem; }

.media-card__body h3 {
    margin: 0 0 0.25rem;
    font-size: 0.95rem;
    line-height: 1.3;
}

.social-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.social-btn {
    padding: 0.55rem 0.85rem;
    text-decoration: none;
    color: var(--text);
    font-weight: 700;
    border-radius: 12px;
    transition: box-shadow 0.2s ease;
}

.social-btn:hover {
    box-shadow: 0 0 22px color-mix(in srgb, var(--neon) 35%, transparent);
}

.social-btn--accent {
    background: linear-gradient(90deg, var(--neon), var(--primary));
    color: #061018;
}

.thank-you {
    margin: 1rem 0;
    padding: 0.85rem 1rem;
    border-radius: 12px;
    border: 1px solid color-mix(in srgb, var(--neon) 45%, transparent);
    background: linear-gradient(120deg, rgba(255, 43, 214, 0.12), rgba(124, 245, 255, 0.1));
    animation: thankPop 4s ease-in-out infinite;
}

.thank-you--big { text-align: center; padding: 1.25rem; }

.thank-you span { font-family: var(--display); font-weight: 700; letter-spacing: 0.06em; }
.thank-you small { display: block; margin-top: 0.25rem; color: var(--muted); }

@keyframes thankPop {
    0%, 100% { transform: translateY(0); filter: brightness(1); }
    50% { transform: translateY(-2px); filter: brightness(1.08); }
}

.discord-widget iframe { width: 100%; min-height: 360px; border: 0; }

.embed-stack { display: grid; gap: 1rem; }
.embed-block { padding: 1rem; }
.embed-freeform iframe { max-width: 100%; }

.page-hero { padding: 1.5rem; margin-bottom: 1rem; }
.page-hero h1 { margin: 0; font-family: var(--display); }

.form label { display: block; font-weight: 600; margin: 0.65rem 0 0.25rem; }
.form input, .form textarea {
    width: 100%;
    padding: 0.65rem 0.75rem;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: rgba(0, 0, 0, 0.25);
    color: var(--text);
    font-family: inherit;
}

.form button { margin-top: 0.75rem; }

.link { color: var(--primary); }

.footer {
    margin-top: 2rem;
    border-top: 1px solid var(--border);
}

.footer__grid {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.25rem 0;
    flex-wrap: wrap;
}

.footer__brand { font-weight: 800; font-family: var(--display); }
.footer__muted { margin: 0.25rem 0 0; color: var(--muted); font-size: 0.9rem; }
.footer__bottom {
    display: flex;
    justify-content: space-between;
    padding-bottom: 1.25rem;
    color: var(--muted);
    font-size: 0.85rem;
}
.footer__admin { color: var(--muted); }

.toast {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 100;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: var(--glass);
    backdrop-filter: blur(10px);
    animation: toastIn 0.35s ease;
}

.toast--error { border-color: rgba(255, 100, 120, 0.45); }

@keyframes toastIn {
    from { transform: translateY(-8px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.about-html p:first-child { margin-top: 0; }

.section-panel > h2 + .sponsor-html {
    margin-top: 0.65rem;
}

.sponsor-html img {
    max-height: 52px;
    width: auto;
    vertical-align: middle;
}

.sponsor-html a {
    display: inline-block;
    margin: 0.35rem 0.75rem 0.35rem 0;
}
