@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;600;800&display=swap');

:root {
    --bg-color: #0d0d12;
    --card-bg: rgba(255, 255, 255, 0.03);
    --card-border: rgba(255, 255, 255, 0.08);
    --accent-color: #9d50bb;
    --accent-gradient: linear-gradient(135deg, #6e48aa, #9d50bb);
    --gold-accent: #f9d423;
    --text-primary: #ffffff;
    --text-secondary: #a0a0ab;
    --glass-bg: rgba(13, 13, 18, 0.7);
    --glass-blur: blur(12px);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
}

body.nav-open {
    overflow: hidden;
}

h1,
h2,
h3,
.brand__name {
    font-family: 'Outfit', sans-serif;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Glassmorphism Card Base */
.card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    backdrop-filter: var(--glass-blur);
    padding: 24px;
    transition: var(--transition);
}

.card:hover {
    border-color: rgba(157, 80, 187, 0.3);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

/* Header & Navigation */
.site-header {
    padding: 24px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    border-bottom: 1px solid var(--card-border);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand {
    display: flex;
    align-items: center;
    gap: 16px;
    text-decoration: none;
    color: inherit;
    z-index: 1001;
}

.brand__logo img {
    height: 48px;
    filter: drop-shadow(0 0 10px rgba(157, 80, 187, 0.5));
}

.brand__name {
    font-size: 24px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    background: linear-gradient(to right, #fff, #9d50bb);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav {
    display: flex;
    gap: 32px;
}

.nav a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: var(--transition);
}

.nav a:hover {
    color: var(--text-primary);
}

.header-actions {
    display: flex;
    gap: 12px;
    align-items: center;
    z-index: 1001;
}

/* Burger Menu */
.burger {
    display: none;
    width: 32px;
    height: 32px;
    background: transparent;
    border: none;
    cursor: pointer;
    position: relative;
    padding: 0;
}

.burger span {
    display: block;
    width: 24px;
    height: 2px;
    background-color: var(--text-primary);
    margin: 5px auto;
    transition: var(--transition);
}

.nav-open .burger span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav-open .burger span:nth-child(2) {
    opacity: 0;
}

.nav-open .burger span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Buttons */
.btn {
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    cursor: pointer;
    font-size: 14px;
}

.btn--accent {
    background: var(--accent-gradient);
    color: white;
    border: none;
}

.btn--accent:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(157, 80, 187, 0.4);
}

.btn--ghost {
    background: transparent;
    border: 1px solid var(--card-border);
    color: var(--text-primary);
}

.btn--ghost:hover {
    background: rgba(255, 255, 255, 0.05);
}

/* Hero Section */
.hero {
    margin: 40px 0;
    position: relative;
    overflow: hidden;
    padding: 60px 40px;
}

.hero__bg {
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(110, 72, 170, 0.2) 0%, transparent 70%);
    z-index: -1;
    filter: blur(80px);
}

.hero__inner {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 48px;
    align-items: center;
}

.hero h1 {
    font-size: 48px;
    line-height: 1.1;
    margin-bottom: 20px;
}

.hero p {
    color: var(--text-secondary);
    font-size: 18px;
    margin-bottom: 32px;
}

.hero__chips {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.badge {
    padding: 4px 12px;
    background: rgba(157, 80, 187, 0.1);
    border: 1px solid rgba(157, 80, 187, 0.2);
    border-radius: 20px;
    font-size: 13px;
    color: var(--accent-color);
}

/* Main Grid */
.grid {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 24px;
    margin-bottom: 60px;
}

.section__title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.section__title::before {
    content: '';
    width: 4px;
    height: 20px;
    background: var(--accent-gradient);
    border-radius: 2px;
}

/* News Grid */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.news-item {
    display: flex;
    flex-direction: column;
    padding: 20px;
    height: 100%;
}

.news-item__top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.news-item__title {
    font-weight: 700;
    font-size: 16px;
    line-height: 1.4;
    color: var(--text-primary);
}

.news-item__date {
    font-size: 12px;
    color: var(--text-secondary);
    white-space: nowrap;
}

.news-item__desc {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 20px;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-item__more {
    margin-top: auto;
}

.news-item__more .btn {
    width: 100%;
    padding: 8px;
}

/* Rating / Stats */
.tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    background: rgba(255, 255, 255, 0.03);
    padding: 4px;
    border-radius: 12px;
}

.tab {
    flex: 1;
    padding: 8px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
}

.tab.is-active {
    background: var(--accent-gradient);
    color: white;
}

.tabpanel {
    display: none;
}

.tabpanel.is-active {
    display: block;
}

.top-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--card-border);
}

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

.top-row b {
    font-size: 14px;
    font-weight: 600;
}

.top-row span {
    font-size: 12px;
    color: var(--accent-color);
    font-weight: 700;
}

/* Server Status - Unified */
.status-pill {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    padding: 32px;
    text-align: center;
    border-radius: 24px;
    margin-bottom: 24px;
}

.status-pill__online {
    font-size: 56px;
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    transition: var(--transition);
    line-height: 1;
}

.status-pill__label {
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 13px;
    font-weight: 700;
    color: var(--text-secondary);
    margin-top: 8px;
}

/* Server List */
.server-card {
    padding: 16px;
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.server-name {
    font-weight: 700;
    font-size: 16px;
}

.server-rate {
    color: var(--accent-color);
    margin-left: 8px;
}

.pill {
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
}

.pill--on {
    background: rgba(34, 197, 94, 0.1);
    color: #22c55e;
}

.pill--off {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

/* Footer */
.footer {
    padding: 60px 0;
    border-top: 1px solid var(--card-border);
    color: var(--text-secondary);
    font-size: 14px;
}

.footer a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition);
}

.footer a:hover {
    color: var(--text-primary);
}

@media (max-width: 992px) {
    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background: var(--bg-color);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 1000;
        gap: 32px;
        padding-top: 80px;
    }

    .nav a {
        font-size: 24px;
        font-weight: 700;
        font-family: 'Outfit', sans-serif;
    }

    .nav-open .nav {
        right: 0;
    }

    .burger {
        display: block;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }

    .hero {
        padding: 40px 16px;
        margin: 20px 0;
    }

    .hero__inner {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .hero h1 {
        font-size: 32px;
        margin-bottom: 16px;
    }

    .hero p {
        font-size: 15px;
        margin-bottom: 24px;
    }

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

    .status-pill {
        padding: 24px 16px;
        border-radius: 16px;
    }

    .status-pill__online {
        font-size: 40px;
    }

    .news-grid {
        display: block;
    }

    .news-item {
        margin-bottom: 16px;
    }

    .header-actions .btn {
        display: none;
    }

    .header-actions .btn:nth-last-child(2) {
        display: inline-flex;
    }

    .langs {
        margin-right: 12px;
    }
}

/* Language Switcher */
.langs {
    position: relative;
    z-index: 1010;
}

.langs__content {
    cursor: pointer;
    position: relative;
}

.langs__content-current {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.langs__content:hover .langs__content-current {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.langs__content-stroke {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 8px;
    list-style: none;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
    width: 48px;
}

.langs__content:hover .langs__content-stroke,
.langs__content.active .langs__content-stroke {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.langs__content-stroke li {
    margin-bottom: 4px;
}

.langs__content-stroke li:last-child {
    margin-bottom: 0;
}

.langs__content-stroke a {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
    border-radius: 6px;
    transition: var(--transition);
}

.langs__content-stroke a:hover {
    background: rgba(255, 255, 255, 0.05);
}

/* Streams Section */
.stream-card {
    padding: 0 !important;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.stream-card__preview {
    position: relative;
    aspect-ratio: 16/9;
    background: #000;
    border-radius: 12px 12px 0 0;
    overflow: hidden;
}

.stream-card__preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.8;
    transition: var(--transition);
}

.stream-card:hover .stream-card__preview img {
    opacity: 1;
    transform: scale(1.05);
}

.stream-status {
    position: absolute;
    top: 12px;
    left: 12px;
    background: #ef4444;
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    gap: 5px;
    animation: pulse-live 2s infinite;
    z-index: 1;
}

.stream-status::before {
    content: '';
    width: 6px;
    height: 6px;
    background: #fff;
    border-radius: 50%;
}

.stream-status--offline {
    background: #4b5563;
    animation: none;
}

.stream-status--offline::before {
    background: #9ca3af;
}

@keyframes pulse-live {
    0% {
        opacity: 1;
    }

    50% {
        opacity: 0.6;
    }

    100% {
        opacity: 1;
    }
}

.stream-card__info {
    padding: 20px;
}

.stream-card__name {
    font-size: 13px;
    font-weight: 700;
    color: var(--accent-color);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stream-card__title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.stream-card__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
}

.lang__img {
    width: 20px;
    height: auto;
    border-radius: 2px;
}