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

/* ================== BODY ================== */
body {
    font-family: Arial, sans-serif;
    background: radial-gradient(circle at center, #0a0a0a 0%, #000000 100%);
    color: white;
    overflow-x: hidden;
}

.bg-logo {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90vw;
    height: 90vw;
    opacity: 0.18;
    z-index: 0;
    pointer-events: none;
}

.bg-logo text {
    fill: #ff0000;
    filter: drop-shadow(0 0 12px red);
}

.bg-logo circle {
    stroke: #ff0000;
}

/* ================== NAVBAR ================== */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    position: relative;
    z-index: 1001;
}

nav img {
    width: 50px;
}

/* ================== NAV LINKS ================== */
.nav-links {
    display: flex;
    gap: 25px;
}

.nav-links a {
    text-decoration: none;
    color: white;
    font-weight: bold;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0%;
    height: 2px;
    background: red;
    left: 0;
    bottom: -5px;
    transition: 0.3s;
}

.nav-links a:hover::after {
    width: 100%;
}

/* ================== HAMBURGER MENU ================== */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 22px;
    cursor: pointer;
    z-index: 1001;
}

.menu-toggle span {
    display: block;
    height: 4px;
    width: 100%;
    background: red;
    border-radius: 2px;
}

/* ================== HERO ================== */
.hero {
    text-align: center;
    padding: 120px 20px;
    animation: fadeIn 1.5s ease;
}

.hero h1 {
    font-size: 70px;
    color: red;
    text-shadow: 0 0 20px red;
}

.hero p {
    font-size: 22px;
    margin: 15px 0 25px;
    opacity: 0.85;
}

/* ================== BUTTON ================== */
.btn {
    display: inline-block;
    padding: 14px 30px;
    background: red;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    transition: 0.3s;
    box-shadow: 0 0 15px rgba(255,0,0,0.5);
}

.btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 25px rgba(255,0,0,0.9);
}

/* ================== SECTIONS ================== */
.section {
    padding: 80px 20px;
    max-width: 1000px;
    margin: auto;
    animation: fadeInUp 1s ease;
}

.section h2 {
    margin-bottom: 20px;
    color: red;
    text-shadow: 0 0 10px red;
}

/* ================== GALLERY ================== */
.gallery {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.gallery img {
    width: 30%;
    border-radius: 10px;
    transition: 0.3s;
}

.gallery img:hover {
    transform: scale(1.05);
    box-shadow: 0 0 20px red;
}

/* ================== LAUNCHER ================== */
.launcher {
    text-align: center;
}

.progress {
    width: 100%;
    background: #222;
    height: 10px;
    margin-top: 20px;
    border-radius: 5px;
}

.bar {
    width: 0%;
    height: 100%;
    background: red;
    border-radius: 5px;
}

/* ================== ANIMATIONS ================== */
@keyframes fadeIn {
    from {opacity: 0;}
    to {opacity: 1;}
}

@keyframes fadeInUp {
    from {opacity: 0; transform: translateY(30px);}
    to {opacity: 1; transform: translateY(0);}
}

/* ================== MOBILE RESPONSIVE ================== */
@media (max-width: 768px) {

    .bg-logo {
        width: 300px;
        opacity: 0.03;
    }

    nav {
        padding: 15px 20px;
    }

    /* Show hamburger menu */
    .menu-toggle {
        display: flex;
    }

    /* Mobile nav */
    .nav-links {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: 0;
        right: 0;
        height: 100vh;
        width: 70%;
        max-width: 300px;
        background: #000;
        padding-top: 80px;
        gap: 20px;
        text-align: center;
        transform: translateX(100%);
        transition: transform 0.3s ease-in-out;
        z-index: 1000;
    }

    .nav-links.active {
        transform: translateX(0);
    }

    .nav-links a {
        font-size: 18px;
        padding: 10px 0;
    }

    .hero h1 {
        font-size: 40px;
    }

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

    .gallery {
        flex-direction: column;
    }

    .gallery img {
        width: 100%;
    }
}

/* ================== ENCYCLOPEDIA SECTION (index.html) ================== */
.enc-section {
    max-width: 1000px;
    margin: 0 auto 70px;
    padding: 0 20px;
    position: relative;
    z-index: 1;
}
.enc-header {
    margin-bottom: 28px;
}
.enc-header h2 {
    font-size: 22px;
    color: #ccc;
    font-weight: bold;
    margin-bottom: 8px;
    letter-spacing: 0.3px;
}
.enc-header p {
    font-size: 14px;
    color: #555;
    line-height: 1.5;
}
.enc-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}
.enc-card {
    background: #0d0d0d;
    border: 1px solid #1a1a1a;
    border-radius: 8px;
    padding: 18px;
    text-decoration: none;
    color: white;
    display: block;
    transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.enc-card:hover {
    border-color: red;
    transform: translateY(-3px);
    box-shadow: 0 0 16px rgba(255,0,0,0.2);
}
.enc-card-name {
    font-size: 15px;
    font-weight: bold;
    color: white;
    margin-bottom: 4px;
}
.enc-card-era {
    font-size: 11px;
    color: red;
    font-weight: bold;
    letter-spacing: 0.4px;
    margin-bottom: 10px;
}
.enc-card-desc {
    font-size: 12px;
    color: #777;
    line-height: 1.5;
    margin: 0;
}
.enc-browse-btn {
    display: inline-block;
    color: #888;
    text-decoration: none;
    font-size: 14px;
    border: 1px solid #2a2a2a;
    padding: 10px 20px;
    border-radius: 6px;
    transition: border-color 0.2s, color 0.2s;
}
.enc-browse-btn:hover {
    border-color: red;
    color: white;
}

/* ================== EXTRA SMALL DEVICES ================== */
@media (max-width: 480px) {
    .hero h1 {
        font-size: 28px;
    }
    .hero p {
        font-size: 14px;
    }
    nav img {
        width: 40px;
    }
}



/* ================== GAMES HERO ================== */
.games-hero {
    text-align: center;
    padding: 80px 20px 30px;
    animation: fadeIn 1.2s ease;
    position: relative;
    z-index: 1;
}

.games-hero h1 {
    font-size: 52px;
    color: red;
    text-shadow: 0 0 20px red;
    margin-bottom: 12px;
}

.games-hero p {
    font-size: 18px;
    opacity: 0.75;
}

/* ================== CONTROLS ================== */
.games-controls {
    max-width: 1100px;
    margin: 0 auto 12px;
    padding: 0 20px;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: center;
    justify-content: space-between;
    position: relative;
    z-index: 1;
}

.search-wrapper {
    position: relative;
    flex: 1;
    min-width: 220px;
    max-width: 420px;
}

.search-wrapper input {
    width: 100%;
    padding: 12px 40px 12px 16px;
    background: #111;
    border: 1px solid #333;
    border-radius: 6px;
    color: white;
    font-size: 15px;
    outline: none;
    transition: border-color 0.25s;
}

.search-wrapper input:focus {
    border-color: red;
    box-shadow: 0 0 8px rgba(255,0,0,0.3);
}

.search-wrapper input::placeholder {
    color: #555;
}

.search-icon {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #555;
    font-size: 16px;
    pointer-events: none;
}

.filter-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.filter-btn {
    background: transparent;
    border: 1px solid #333;
    color: #aaa;
    padding: 10px 18px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    transition: all 0.2s;
}

.filter-btn:hover {
    border-color: red;
    color: white;
}

.filter-btn.active {
    background: red;
    border-color: red;
    color: white;
    box-shadow: 0 0 12px rgba(255,0,0,0.5);
}

/* ================== GAME COUNT ================== */
.games-count {
    text-align: center;
    color: #555;
    font-size: 13px;
    margin-bottom: 30px;
    position: relative;
    z-index: 1;
}

/* ================== GAMES GRID ================== */
.games-grid {
    max-width: 1100px;
    margin: 0 auto 80px;
    padding: 0 20px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 24px;
    position: relative;
    z-index: 1;
}

.loading-msg {
    grid-column: 1 / -1;
    text-align: center;
    color: #555;
    padding: 60px 0;
    font-size: 18px;
}

/* ================== GAME CARD ================== */
.game-card {
    background: #0d0d0d;
    border: 1px solid #1a1a1a;
    border-radius: 10px;
    overflow: hidden;
    text-decoration: none;
    color: white;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
    content-visibility: auto;
    contain-intrinsic-size: auto 300px;
}

.game-card:hover {
    transform: translateY(-4px);
    border-color: red;
    box-shadow: 0 0 20px rgba(255,0,0,0.25);
}

.game-card-img-wrap {
    position: relative;
    width: 100%;
    height: 180px;
    background: #111;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.game-card-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
    transition: transform 0.3s;
}

.game-card:hover .game-card-img-wrap img {
    transform: scale(1.05);
}

.game-card-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 72px;
    font-weight: bold;
    color: #1a1a1a;
    background: #0d0d0d;
}

.game-card-decade {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(200,0,0,0.85);
    color: white;
    font-size: 11px;
    font-weight: bold;
    padding: 3px 8px;
    border-radius: 4px;
    letter-spacing: 0.5px;
}

.game-card-playable {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(0,0,0,0.75);
    color: #ff4444;
    font-size: 11px;
    font-weight: bold;
    padding: 3px 8px;
    border-radius: 4px;
    letter-spacing: 0.5px;
    border: 1px solid rgba(255,68,68,0.4);
}

.game-card-body {
    padding: 14px 16px 18px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.game-card-title {
    font-size: 17px;
    color: white;
    margin: 0;
    line-height: 1.2;
}

.game-card-meta {
    font-size: 13px;
    color: #cc0000;
    display: flex;
    gap: 6px;
    align-items: center;
}

.dot {
    opacity: 0.5;
}

.game-card-platform {
    font-size: 12px;
    color: #555;
    margin: 0;
}

.game-card-desc {
    font-size: 13px;
    color: #888;
    margin: 6px 0 0;
    line-height: 1.5;
}

/* ================== NO RESULTS ================== */
.no-results {
    text-align: center;
    padding: 60px 20px;
    color: #555;
    position: relative;
    z-index: 1;
}

.no-results p {
    font-size: 18px;
    margin-bottom: 20px;
}

/* ================== ACTIVE NAV ================== */
.nav-links a.active {
    color: red;
}

.nav-links a.active::after {
    width: 100%;
}

/* ================== GAME DETAIL PAGE ================== */
.game-detail-wrapper {
    max-width: 1050px;
    margin: 0 auto 80px;
    padding: 30px 20px 0;
    position: relative;
    z-index: 1;
}

.back-link {
    display: inline-block;
    color: #888;
    text-decoration: none;
    font-size: 14px;
    margin-bottom: 24px;
    transition: color 0.2s;
}

.back-link:hover {
    color: red;
}

.game-detail-card {
    display: flex;
    gap: 40px;
    align-items: flex-start;
}

.game-detail-image-col {
    flex: 0 0 260px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.game-detail-img {
    width: 100%;
    border-radius: 10px;
    border: 1px solid #222;
    box-shadow: 0 0 30px rgba(255,0,0,0.1);
}

.game-meta {
    background: #0d0d0d;
    border: 1px solid #1a1a1a;
    border-radius: 8px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.meta-item {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    font-size: 13px;
    border-bottom: 1px solid #1a1a1a;
    padding-bottom: 8px;
}

.meta-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.meta-label {
    color: #555;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 11px;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.meta-value {
    color: #ccc;
    text-align: right;
}

.game-detail-info-col {
    flex: 1;
    min-width: 0;
}

.game-decade-badge {
    display: inline-block;
    background: red;
    color: white;
    font-size: 12px;
    font-weight: bold;
    padding: 4px 12px;
    border-radius: 4px;
    margin-bottom: 12px;
    letter-spacing: 0.5px;
    box-shadow: 0 0 10px rgba(255,0,0,0.4);
}

.game-detail-title {
    font-size: 44px;
    color: white;
    text-shadow: 0 0 20px rgba(255,0,0,0.3);
    margin: 0 0 6px;
    line-height: 1.1;
}

.game-detail-year {
    color: #cc0000;
    font-size: 15px;
    margin: 0 0 30px;
}

.game-detail-desc {
    margin-bottom: 28px;
}

.game-detail-desc h2 {
    font-size: 18px;
    color: red;
    text-shadow: 0 0 8px rgba(255,0,0,0.4);
    margin-bottom: 10px;
    border-bottom: 1px solid #1a1a1a;
    padding-bottom: 8px;
}

.game-detail-desc p {
    font-size: 15px;
    color: #ccc;
    line-height: 1.75;
}

/* ================== MOBILE ================== */
@media (max-width: 768px) {
    .games-hero h1 { font-size: 32px; }
    .games-controls { flex-direction: column; }
    .search-wrapper { max-width: 100%; }
    .games-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 14px; }
    .game-card-img-wrap { height: 130px; }

    .game-detail-card {
        flex-direction: column;
        gap: 24px;
    }

    .game-detail-image-col {
        flex: none;
        width: 100%;
        flex-direction: row;
        align-items: flex-start;
        gap: 16px;
    }

    .game-detail-img {
        width: 140px;
        flex-shrink: 0;
    }

    .game-meta {
        flex: 1;
    }

    .game-detail-title { font-size: 28px; }
}

@media (max-width: 480px) {
    .games-grid { grid-template-columns: 1fr 1fr; }
    .game-detail-image-col { flex-direction: column; }
    .game-detail-img { width: 100%; }
}

/* ================== NAV EXTRAS ================== */
.nav-random {
    color: #aaa;
    font-size: 14px;
    letter-spacing: 0.3px;
}
.nav-random:hover { color: red !important; }

/* ================== PLAY / DOWNLOAD ACTIONS ================== */
.game-play-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 24px;
    margin-bottom: 4px;
}
.btn-play, .btn-download {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 22px;
    border-radius: 6px;
    font-size: 15px;
    font-weight: bold;
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
}
.btn-play {
    background: red;
    color: white;
    border: 1px solid red;
}
.btn-play:hover {
    background: #cc0000;
    box-shadow: 0 0 16px rgba(255,0,0,0.5);
}
.btn-download {
    background: transparent;
    color: #ccc;
    border: 1px solid #444;
}
.btn-download:hover {
    border-color: red;
    color: white;
    box-shadow: 0 0 10px rgba(255,0,0,0.2);
}

/* ================== SHARE BUTTON ================== */
.share-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: transparent;
    border: 1px solid #333;
    color: #aaa;
    padding: 9px 18px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    transition: all 0.2s;
    margin-top: 16px;
}
.share-btn:hover {
    border-color: red;
    color: white;
    box-shadow: 0 0 10px rgba(255,0,0,0.2);
}

/* ================== RELATED GAMES ================== */
.related-section {
    max-width: 1050px;
    margin: 48px auto 80px;
    padding: 0 20px;
    position: relative;
    z-index: 1;
}
.related-section h2 {
    font-size: 22px;
    color: red;
    text-shadow: 0 0 8px rgba(255,0,0,0.4);
    margin-bottom: 20px;
    border-bottom: 1px solid #1a1a1a;
    padding-bottom: 10px;
}
.related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 18px;
}

/* ================== GAME OF THE DAY (index.html) ================== */
.gotd-section {
    max-width: 900px;
    margin: 0 auto 60px;
    padding: 0 20px;
    position: relative;
    z-index: 1;
}
.gotd-section h2 {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #555;
    margin-bottom: 16px;
}
.gotd-card {
    display: flex;
    gap: 28px;
    background: #0d0d0d;
    border: 1px solid #cc0000;
    border-radius: 12px;
    overflow: hidden;
    text-decoration: none;
    color: white;
    box-shadow: 0 0 30px rgba(200,0,0,0.15);
    transition: box-shadow 0.3s, border-color 0.3s;
}
.gotd-card:hover {
    box-shadow: 0 0 40px rgba(255,0,0,0.3);
    border-color: red;
}
.gotd-img {
    width: 160px;
    min-height: 160px;
    object-fit: cover;
    object-position: top;
    flex-shrink: 0;
}
.gotd-body {
    padding: 22px 22px 22px 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 8px;
}
.gotd-badge {
    display: inline-block;
    background: red;
    color: white;
    font-size: 11px;
    font-weight: bold;
    padding: 3px 10px;
    border-radius: 4px;
    letter-spacing: 0.5px;
    width: fit-content;
}
.gotd-title {
    font-size: 26px;
    font-weight: bold;
    color: white;
    text-shadow: 0 0 12px rgba(255,0,0,0.2);
    line-height: 1.15;
    margin: 0;
}
.gotd-meta {
    font-size: 13px;
    color: #cc0000;
}
.gotd-desc {
    font-size: 14px;
    color: #888;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
@media (max-width: 600px) {
    .gotd-card { flex-direction: column; }
    .gotd-img { width: 100%; min-height: 140px; }
    .gotd-body { padding: 16px; }
}

/* ================== PLATFORM LIST PAGE ================== */
.platforms-hero {
    text-align: center;
    padding: 80px 20px 40px;
    position: relative;
    z-index: 1;
}
.platforms-hero h1 {
    font-size: 48px;
    color: red;
    text-shadow: 0 0 20px red;
    margin-bottom: 12px;
}
.platforms-hero p { font-size: 17px; opacity: 0.7; }
.platforms-grid {
    max-width: 1050px;
    margin: 0 auto 80px;
    padding: 0 20px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    position: relative;
    z-index: 1;
}
.platform-card {
    background: #0d0d0d;
    border: 1px solid #1a1a1a;
    border-radius: 10px;
    padding: 24px;
    text-decoration: none;
    color: white;
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}
.platform-card:hover {
    border-color: red;
    box-shadow: 0 0 20px rgba(255,0,0,0.2);
    transform: translateY(-3px);
}
.platform-card-name {
    font-size: 20px;
    font-weight: bold;
    color: white;
}
.platform-card-era {
    font-size: 12px;
    color: red;
    font-weight: bold;
    letter-spacing: 0.5px;
}
.platform-card-count {
    font-size: 13px;
    color: #555;
}
.platform-card-desc {
    font-size: 13px;
    color: #888;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ================== PLATFORM DETAIL PAGE ================== */
.platform-detail-wrapper {
    max-width: 1050px;
    margin: 0 auto;
    padding: 30px 20px 0;
    position: relative;
    z-index: 1;
}
.platform-detail-header {
    margin-bottom: 40px;
}
.platform-detail-header h1 {
    font-size: 42px;
    color: white;
    text-shadow: 0 0 20px rgba(255,0,0,0.3);
    margin: 0 0 6px;
}
.platform-detail-era {
    color: red;
    font-size: 14px;
    margin: 0 0 24px;
    font-weight: bold;
    letter-spacing: 0.5px;
}
.platform-detail-desc {
    font-size: 15px;
    color: #ccc;
    line-height: 1.75;
    margin-bottom: 16px;
    max-width: 780px;
}
/* ================== GENRE ENCYCLOPEDIA — LIST PAGE ================== */
.genres-hero {
    text-align: center;
    padding: 80px 20px 40px;
    position: relative;
    z-index: 1;
}
.genres-hero h1 {
    font-size: 48px;
    color: red;
    text-shadow: 0 0 20px red;
    margin-bottom: 12px;
}
.genres-hero p { font-size: 17px; opacity: 0.7; max-width: 600px; margin: 0 auto; }

.genres-grid {
    max-width: 1100px;
    margin: 0 auto 80px;
    padding: 0 20px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
    position: relative;
    z-index: 1;
}

.genre-card {
    background: #0d0d0d;
    border: 1px solid #1a1a1a;
    border-radius: 10px;
    overflow: hidden;
    text-decoration: none;
    color: white;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
}
.genre-card:hover {
    transform: translateY(-4px);
    border-color: red;
    box-shadow: 0 0 20px rgba(255,0,0,0.25);
}
.genre-card-img-wrap {
    width: 100%;
    height: 160px;
    background: #111;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}
.genre-card-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.3s;
    filter: grayscale(20%);
}
.genre-card:hover .genre-card-img-wrap img { transform: scale(1.06); filter: grayscale(0%); }
.genre-card-body { padding: 18px 20px 22px; flex: 1; display: flex; flex-direction: column; gap: 6px; }
.genre-card-era { font-size: 11px; color: red; font-weight: bold; letter-spacing: 0.5px; text-transform: uppercase; }
.genre-card-name { font-size: 20px; font-weight: bold; color: white; line-height: 1.2; }
.genre-card-count { font-size: 12px; color: #555; }
.genre-card-desc { font-size: 13px; color: #888; line-height: 1.55; margin-top: 4px;
    display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* ================== GENRE ENCYCLOPEDIA — DETAIL (WIKI) PAGE ================== */
.genre-wiki-wrapper {
    max-width: 1000px;
    margin: 0 auto 80px;
    padding: 30px 20px 0;
    position: relative;
    z-index: 1;
}

.genre-article { position: relative; }

.genre-article-title {
    font-size: 42px;
    color: white;
    text-shadow: 0 0 20px rgba(255,0,0,0.3);
    margin: 0 0 6px;
    line-height: 1.1;
}
.genre-article-subtitle {
    font-size: 16px;
    color: #888;
    font-style: italic;
    margin: 0 0 24px;
    line-height: 1.5;
}

/* Infobox — floats right like Wikipedia */
.genre-infobox {
    float: right;
    margin: 0 0 24px 32px;
    width: 260px;
    background: #0d0d0d;
    border: 1px solid #333;
    border-radius: 8px;
    overflow: hidden;
    font-size: 13px;
    flex-shrink: 0;
}
.genre-infobox-title {
    background: #cc0000;
    color: white;
    text-align: center;
    padding: 8px 12px;
    font-size: 13px;
    font-weight: bold;
    letter-spacing: 0.5px;
}
.genre-infobox-image img {
    width: 100%;
    display: block;
    max-height: 200px;
    object-fit: cover;
    object-position: center;
    border-bottom: 1px solid #222;
}
.genre-infobox-caption {
    font-size: 11px;
    color: #888;
    padding: 8px 10px;
    line-height: 1.45;
    border-bottom: 1px solid #222;
    text-align: center;
}
.genre-infobox-license { font-size: 10px; color: #555; display: block; margin-top: 3px; }
.genre-infobox-table { width: 100%; border-collapse: collapse; }
.genre-infobox-table tr { border-top: 1px solid #1a1a1a; }
.genre-infobox-table tr:first-child { border-top: none; }
.gi-label {
    color: #666;
    font-size: 11px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    padding: 7px 10px;
    vertical-align: top;
    white-space: nowrap;
    width: 40%;
}
.gi-value {
    color: #ccc;
    font-size: 12px;
    padding: 7px 10px;
    vertical-align: top;
}

/* Table of contents */
.genre-toc {
    display: inline-block;
    background: #0d0d0d;
    border: 1px solid #2a2a2a;
    border-radius: 6px;
    padding: 14px 20px 14px 16px;
    margin-bottom: 28px;
    min-width: 210px;
    max-width: 320px;
    clear: left;
}
.genre-toc-title {
    font-size: 13px;
    font-weight: bold;
    color: #ccc;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.genre-toc ol {
    margin: 0;
    padding-left: 18px;
    list-style: decimal;
}
.genre-toc li { font-size: 13px; line-height: 1.9; color: #888; }
.genre-toc a { color: #aaa; text-decoration: none; transition: color 0.15s; }
.genre-toc a:hover { color: red; }

/* Intro paragraph */
.genre-article-intro {
    margin-bottom: 32px;
}
.genre-article-intro p {
    font-size: 16px;
    color: #ccc;
    line-height: 1.75;
    border-left: 3px solid #cc0000;
    padding-left: 16px;
}

/* Article sections */
.genre-section { margin-bottom: 36px; }
.genre-section h2 {
    font-size: 22px;
    color: white;
    text-shadow: 0 0 8px rgba(255,0,0,0.2);
    border-bottom: 1px solid #222;
    padding-bottom: 8px;
    margin-bottom: 16px;
}
.genre-section p {
    font-size: 15px;
    color: #bbb;
    line-height: 1.8;
    margin: 0 0 14px;
}
.genre-section p:last-child { margin-bottom: 0; }
.genre-section strong { color: #fff; }
.genre-section em { color: #ddd; font-style: italic; }

/* Games section */
.genre-games-section { clear: both; margin-top: 48px; }
.genre-games-heading {
    font-size: 24px;
    color: red;
    text-shadow: 0 0 8px rgba(255,0,0,0.4);
    border-bottom: 1px solid #1a1a1a;
    padding-bottom: 10px;
    margin-bottom: 24px;
}
.genre-games-section .games-grid { max-width: 100%; margin-bottom: 0; padding: 0; }

/* Responsive: collapse infobox on mobile */
@media (max-width: 700px) {
    .genre-infobox {
        float: none;
        width: 100%;
        margin: 0 0 24px 0;
    }
    .genre-article-title { font-size: 28px; }
    .genres-hero h1 { font-size: 32px; }
    .genres-grid { grid-template-columns: 1fr; }
}

/* ================== PLATFORM GAMES HEADING ================== */
.platform-games-heading {
    font-size: 22px;
    color: red;
    text-shadow: 0 0 8px rgba(255,0,0,0.4);
    margin: 40px 0 20px;
    border-bottom: 1px solid #1a1a1a;
    padding-bottom: 10px;
}
