/* Respawn Wiki — Gaming News CSS */

:root {
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-card: #16161f;
    --bg-hover: #1a1a25;
    --text-primary: #e8e8f0;
    --text-secondary: #8888a0;
    --text-muted: #555570;
    --accent-primary: #7c3aed;
    --accent-secondary: #a855f7;
    --accent-glow: rgba(124, 58, 237, 0.3);
    --gradient-1: linear-gradient(135deg, #7c3aed, #ec4899);
    --gradient-2: linear-gradient(135deg, #3b82f6, #8b5cf6);
    --border-color: rgba(255, 255, 255, 0.06);
    --radius: 12px;
    --radius-lg: 16px;
    --shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
    --transition: 0.2s ease;
}

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

body {
    font-family: 'Inter', -apple-system, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
}

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

/* ===== HEADER ===== */
.header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(10, 10, 15, 0.85);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    padding: 16px 0;
}

.header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text-primary);
}

.logo-icon {
    font-size: 24px;
}

.logo-text {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.logo-wiki {
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

.nav-link {
    padding: 8px 16px;
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.06);
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    background: rgba(124, 58, 237, 0.15);
    border: 1px solid rgba(124, 58, 237, 0.3);
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    color: var(--accent-secondary);
}

/* ===== HERO ===== */
.hero {
    position: relative;
    padding: 60px 0 40px;
    overflow: hidden;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 700px;
    margin: 0 auto;
}

.hero-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 48px;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 16px;
}

.gradient-text {
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 18px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.hero-particles {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.particle {
    position: absolute;
    font-size: 32px;
    opacity: 0.15;
    animation: float 6s ease-in-out infinite;
}

.p1 { top: 20%; left: 10%; animation-delay: 0s; }
.p2 { top: 40%; right: 15%; animation-delay: 1.5s; }
.p3 { bottom: 30%; left: 20%; animation-delay: 3s; }
.p4 { top: 30%; right: 25%; animation-delay: 4.5s; }

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

/* ===== CATEGORIES BAR ===== */
.categories-bar {
    display: flex;
    gap: 8px;
    padding: 16px 0;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.categories-bar::-webkit-scrollbar { display: none; }

.cat-tag {
    display: inline-flex;
    padding: 8px 18px;
    border-radius: 20px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    white-space: nowrap;
    transition: var(--transition);
}

.cat-tag:hover,
.cat-tag.active {
    background: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
}

/* ===== ARTICLES GRID ===== */
.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 24px;
    padding: 24px 0;
}

.article-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: var(--transition);
}

.article-card:hover {
    transform: translateY(-4px);
    border-color: rgba(124, 58, 237, 0.3);
    box-shadow: 0 8px 32px rgba(124, 58, 237, 0.15);
}

.card-image {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: var(--bg-secondary);
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

.card-no-image {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1a1a2e, #16162a);
}

.card-emoji {
    font-size: 48px;
    opacity: 0.4;
}

.card-source {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 4px 10px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    color: var(--accent-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.card-body {
    padding: 20px;
}

.card-category {
    display: inline-block;
    padding: 4px 10px;
    background: rgba(124, 58, 237, 0.15);
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    color: var(--accent-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
    text-decoration: none;
}

.card-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 10px;
}

.card-title a {
    color: var(--text-primary);
    text-decoration: none;
    transition: color var(--transition);
}

.card-title a:hover {
    color: var(--accent-secondary);
}

.card-excerpt {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 16px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: var(--text-muted);
}

.card-source-name {
    font-weight: 600;
    color: var(--accent-primary);
}

/* ===== ARTICLE DETAIL ===== */
.article-detail {
    max-width: 800px;
    margin: 40px auto;
    padding: 0 20px;
}

.article-header {
    margin-bottom: 32px;
}

.article-meta-top {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
    font-size: 13px;
    color: var(--text-muted);
}

.article-source {
    color: var(--accent-primary);
    font-weight: 600;
}

.article-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 36px;
    font-weight: 700;
    line-height: 1.2;
}

.article-hero-image {
    margin-bottom: 32px;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.article-hero-image img {
    width: 100%;
    height: auto;
    max-height: 450px;
    object-fit: cover;
}

.article-content {
    font-size: 17px;
    line-height: 1.8;
    color: var(--text-primary);
}

.article-content p {
    margin-bottom: 20px;
}

.article-footer {
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.article-tags {
    display: flex;
    gap: 8px;
}

.tag {
    padding: 6px 14px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    font-size: 12px;
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition);
}

.tag:hover {
    border-color: var(--accent-primary);
    color: var(--accent-secondary);
}

.original-link {
    color: var(--accent-primary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
}

.original-link:hover {
    color: var(--accent-secondary);
}

/* ===== RELATED ===== */
.related-articles {
    max-width: 800px;
    margin: 48px auto 0;
    padding: 0 20px;
}

.section-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 24px;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
}

.related-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: var(--transition);
}

.related-card:hover {
    border-color: rgba(124, 58, 237, 0.3);
}

.related-image {
    height: 120px;
    overflow: hidden;
    background: var(--bg-secondary);
}

.related-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.related-no-image {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    opacity: 0.3;
}

.related-body {
    padding: 12px;
}

.related-body h3 {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 6px;
}

.related-body h3 a {
    color: var(--text-primary);
    text-decoration: none;
}

.related-body h3 a:hover {
    color: var(--accent-secondary);
}

.related-date {
    font-size: 11px;
    color: var(--text-muted);
}

.back-link {
    max-width: 800px;
    margin: 32px auto;
    padding: 0 20px;
}

.back-link a {
    color: var(--accent-primary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
}

.back-link a:hover {
    color: var(--accent-secondary);
}

/* ===== EMPTY STATE ===== */
.empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 80px 20px;
}

.empty-icon {
    font-size: 64px;
    display: block;
    margin-bottom: 16px;
}

.empty-state h3 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 24px;
    margin-bottom: 8px;
}

.empty-state p {
    color: var(--text-secondary);
}

/* ===== PAGINATION ===== */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;
    padding: 40px 0;
}

.page-btn {
    padding: 10px 24px;
    background: var(--accent-primary);
    color: white;
    border-radius: 8px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: var(--transition);
}

.page-btn:hover {
    background: var(--accent-secondary);
}

.page-info {
    font-size: 14px;
    color: var(--text-secondary);
}

/* ===== FOOTER ===== */
.footer {
    margin-top: 64px;
    padding: 48px 0 24px;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 32px;
    margin-bottom: 32px;
}

.footer-desc {
    font-size: 14px;
    color: var(--text-secondary);
    margin-top: 12px;
    line-height: 1.6;
}

.footer-col h4 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.footer-col ul {
    list-style: none;
}

.footer-col li {
    margin-bottom: 8px;
}

.footer-col a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 13px;
    transition: var(--transition);
}

.footer-col a:hover {
    color: var(--accent-secondary);
}

.footer-bottom {
    padding-top: 24px;
    border-top: 1px solid var(--border-color);
    text-align: center;
    font-size: 13px;
    color: var(--text-muted);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .header .container {
        flex-wrap: wrap;
    }

    .nav {
        order: 3;
        width: 100%;
        overflow-x: auto;
        scrollbar-width: none;
    }

    .header-right {
        display: none;
    }

    .hero-title {
        font-size: 32px;
    }

    .hero-subtitle {
        font-size: 16px;
    }

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

    .article-title {
        font-size: 28px;
    }

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

    .related-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 28px;
    }

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

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