:root {
    --ps-blue: #00439C;
    --ps-light-blue: #0070D1;
    --brand-red: #E62222;
}

html, body {
    height: 100%;
    margin: 0;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-color: #ffffff;
}

.main-wrapper {
    flex: 1 0 auto;
}

/* 1. TOP NAVBAR HEADER */
.nav-link-custom {
    color: var(--ps-light-blue) !important;
    font-weight: 800;
    font-size: 1.7rem;
    margin-left: 12px;
    margin-right: 12px;
    text-transform: uppercase;
}
.nav-link-custom:hover, .nav-link-custom.active {
    color: var(--ps-blue) !important;
    border-bottom: 3px solid var(--ps-blue);
}

/* 2. CAROUSEL BANNER */
.carousel-item {
    height: 800px;
    background-color: var(--ps-light-blue);
}
.carousel-item img {
    height: 100%;
    object-fit: cover;
}
.carousel-caption-custom {
    background: rgba(0, 0, 0, 0.6);
    padding: 25px;
    border-radius: 12px;
}

/* RUANG KOSONG (SPACER) */
.spacer-section {
    height: 80px;
    background-color: #ffffff;
}

/* 3. GAMES POPULER SECTION (DARK) */
.games-section {
    background-color: #000000;
    color: white;
    padding: 60px 0;
}
.filter-btn {
    background-color: var(--ps-light-blue);
    color: white;
    border: none;
    border-radius: 25px;
    padding: 8px 30px;
    font-weight: 700;
    margin: 0 5px;
    transition: all 0.2s ease-in-out;
    text-decoration: none;
    display: inline-block;
}
.filter-btn:hover, .filter-btn.active {
    background-color: #ffffff;
    color: var(--ps-blue);
    transform: scale(1.05);
}

/* GRID GAME CARDS */
.game-card {
    background-color: #121212;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-decoration: none;
    color: white;
    display: block;
    border: 1px solid #222;
}
.game-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 20px rgba(0, 112, 209, 0.5);
    color: white;
}
.game-cover-container {
    width: 100%;
    padding-top: 100%; /* 1:1 Square Ratio */
    position: relative;
    background-color: #1e1e1e;
}
.game-cover-container img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.game-title {
    padding: 10px 8px;
    font-weight: 700;
    font-size: 0.85rem;
    text-align: center;
    background: #121212;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-transform: uppercase;
}

/* GAME CARD KHUSUS THEME LIGHT (UNTUK KATALOG.PHP) */
.katalog-light .game-card {
    background-color: #ffffff;
    border: 1px solid #e0e0e0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    color: #212529;
}
.katalog-light .game-card:hover {
    box-shadow: 0 8px 20px rgba(0, 112, 209, 0.25);
    color: var(--ps-blue);
}
.katalog-light .game-title {
    background: #ffffff;
    border-top: 1px solid #f0f0f0;
}

/* 4. FOLLOW KITA SECTION */
.follow-section {
    color: #000;
    padding: 45px 0;
}
.social-box {
    background-color: var(--ps-light-blue);
    color: #ffffff !important;
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    text-decoration: none;
    transition: transform 0.2s, background-color 0.2s;
}
.social-box i {
    font-size: 2rem;
    line-height: 1;
    color: #ffffff !important;
}
.social-box:hover {
    transform: scale(1.12);
    background-color: var(--ps-blue);
}

#btnBackToTop {
            position: fixed !important;
            bottom: 30px !important;
            right: 30px !important;
            width: 50px !important;
            height: 50px !important;
            border-radius: 50% !important;
            background-color: #00439C !important;
            color: #ffffff !important;
            border: none !important;
            box-shadow: 0 4px 10px rgba(0,0,0,0.3) !important;
            display: none; /* Muncul lewat JS */
            align-items: center;
            justify-content: center;
            z-index: 99999 !important; /* Memastikan tombol melayang di atas semua elemen */
            cursor: pointer;
            transition: all 0.3s ease;
}

#btnBackToTop:hover {
            background-color: #002b66 !important;
            transform: translateY(-5px);
}

/* 5. FOOTER SECTION */
footer {
    flex-shrink: 0;
    background-color: var(--ps-blue);
    color: white;
    padding: 40px 0 20px 0;
    width: 100%;
}
