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

html {
    overflow-x: hidden;
}

body {
    font-family: 'Rajdhani', sans-serif;
    background-color: #0F0F0F;
    color: #fff;
    min-height: 100vh;
    overflow-x: hidden;
}

.bottom-nav-container {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    z-index: 999;
    height: 100px;
    pointer-events: none;
}

.bottom-nav {
    background-color: #1C1C1C;
    border: 1px solid #333333;
    padding: 12px 25px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 25px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    position: absolute;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    pointer-events: auto;
}

.nav-btn {
    color: #aaa;
    font-size: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: color 0.3s ease;
}

.nav-btn:hover {
    color: #fff;
}

.nav-spacer {
    width: 64px;
}

.settings-fab {
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    width: 66px;
    height: 66px;
    background-color: #C93131;
    border: 4px solid #1d1d1d;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 28px;
    transition: background-color 0.3s ease;
    z-index: 1000;
    pointer-events: auto;
    text-decoration: none;
}

.settings-fab:hover {
    background-color: #ad2b2b;
}

.main {
    flex: 1;
    padding: 30px;
    padding-bottom: 105px;
}
.page-header {
    background: linear-gradient(145deg, #C93131, #a91f1f);
    padding: 30px;
    border-radius: 16px;
    margin-bottom: 30px;
    box-shadow: 0 0 30px rgba(201, 49, 49, 0.3);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 30px;
}

.page-header h1 {
    font-size: 36px;
    font-weight: 700;
}

.page-header p {
    margin-top: 10px;
    font-size: 18px;
    font-weight: 300;
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    column-gap: 1.6rem;
    row-gap: 1.6rem;
}

@media (max-width: 1024px) {
    .games-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .games-grid {
        grid-template-columns: 1fr;
    }

    .game-card img {
        height: 220px;
    }
}

.game-card {
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-radius: 16px;
    overflow: hidden;
    background-color: transparent;
}

.game-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
}

.game-card img {
    width: 100%;
    height: 175px;
    object-fit: cover;
    display: block;
    border-radius: 16px 16px 0 0;
}

.game-card .info {
    background-color: #1C1C1C;
    border: 1px solid #333333;
    border-top: none;
    border-radius: 0 0 16px 16px;
    padding: 15px;
}

.game-card .info h3 {
    font-size: 1.3rem;
    color: #fff;
    margin-bottom: 0.2rem;
}

.game-card .info p {
    font-size: 0.9rem;
    color: #c2c2c2;
}

.filters {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.filter-btn {
    background-color: #1c1c1c;
    color: #ccc;
    padding: 8px 16px;
    border-radius: 999px;
    border: 1px solid #333;
    cursor: pointer;
    transition: 0.2s;
}

.filter-btn:hover {
    background-color: #111111;
}

.filter-btn.active {
    background-color: #C93131;
    color: #fff;
    border-color: #C93131;
}

.search-bar {
    position: relative;
    margin-bottom: 30px;
}

.search-bar i {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: #888;
    font-size: 20px;
}

.search-bar input {
    width: 100%;
    background: #1C1C1C;
    border: 1px solid #333;
    color: #fff;
    padding: 15px 20px 15px 52px;
    border-radius: 999px;
    font-size: 17px;
    font-family: inherit;
}

.search-bar input:focus {
    outline: none;
    border-color: #333;
}

::-webkit-scrollbar {
    width: 3px;
}

::-webkit-scrollbar-track {
    background: #111;
}

::-webkit-scrollbar-thumb {
    background: #695d5d;
    border-radius: 999px;
}

.settings-overlay {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,.55);
    backdrop-filter: blur(10px);
    opacity: 0;
    visibility: hidden;
    transition: .15s;
    z-index: 99999;
}

.settings-overlay.active {
    opacity: 1;
    visibility: visible;
}

.settings-overlay iframe {
    width: min(1300px,95vw);
    height: min(760px,92vh);
    border: #333333 1px solid;
    border-radius: 30px;
    overflow: hidden;
    background: #111;
    transform: scale(.96);
    transition: transform .15s;
    box-shadow: 0 25px 80px rgba(0,0,0,.6);
}

.settings-overlay.active iframe {
    transform: scale(.98);
}

:focus {
    outline: none;
    box-shadow: none;
}

:focus-visible {
    outline: 3px solid #C93131;
}
