:root {
    --bg-color: #f8f9fa;
    --text-dark: #2d3436;
    --text-light: #636e72;
    --primary: #6c5ce7;
    --card-radius: 16px;
    --shadow: 0 4px 15px rgba(0,0,0,0.05);
}

body {
    margin: 0;
    font-family: 'Fredoka', 'Segoe UI', sans-serif; 
    background-color: var(--bg-color);
    color: var(--text-dark);
}


#pixi-canvas {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: -1; opacity: 0.4; pointer-events: none;
}

.container {
    max-width: 1250px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- HEADER --- */
.main-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 0;
    background: #fff;
    border-bottom: 1px solid #eee;
    margin-bottom: 20px;
}
.logo { font-size: 2rem; font-weight: 800; color: var(--text-dark); text-decoration: none; display: flex; align-items: center; gap: 10px; }
.logo span { color: var(--primary); }


.search-wrapper {
    position: relative; 
    width: 300px; 
}

.search-box {
    background: #f1f2f6;
    padding: 10px 20px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    width: 100%;
    box-sizing: border-box; 
    border: 2px solid transparent;
    transition: 0.3s;
}

.search-box:focus-within {
    background: #fff;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(108, 92, 231, 0.1);
}

.search-box input {
    border: none; 
    background: transparent; 
    outline: none; 
    width: 100%; 
    font-family: inherit; 
    font-weight: 600; 
    color: var(--text-dark);
}


#searchResults {
    position: absolute;
    top: 100%; 
    left: 0;
    width: 100%; 
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    z-index: 1000;
    margin-top: 10px;
    overflow: hidden;
    display: none; 
}

.search-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    text-decoration: none;
    border-bottom: 1px solid #f1f1f1;
    transition: 0.2s;
}

.search-item:last-child { border-bottom: none; }
.search-item:hover { background: #f8f9fa; }

.search-item img {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    object-fit: cover;
    background: #eee;
}

.search-info { display: flex; flex-direction: column; }
.search-title { font-weight: 700; color: var(--text-dark); font-size: 0.9rem; }
.search-cat { font-size: 0.75rem; color: #999; }


@media (max-width: 900px) {
    .search-wrapper { width: 100%; margin-top: 10px; }
}

.ad-slot {
    background: #eee;
    margin: 20px auto;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    font-size: 0.8rem;
    overflow: hidden;
    border-radius: 8px;
}
.ad-970 { width: 100%; max-width: 970px; height: 250px; }
.ad-728 { width: 100%; max-width: 728px; height: 90px; }
.ad-300-600 { width: 300px; height: 600px; }
.ad-300-250 { width: 300px; height: 250px; }


.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 15px;
    margin-bottom: 40px;
}
.cat-card {
    display: flex;
    align-items: center;
    padding: 15px;
    border-radius: var(--card-radius);
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
    color: #fff;
    position: relative;
    overflow: hidden;
    height: 80px;
}
.cat-card:hover { transform: translateY(-5px); box-shadow: 0 10px 20px rgba(0,0,0,0.15); }
.cat-img { width: 60px; height: 60px; border-radius: 12px; object-fit: cover; background: rgba(255,255,255,0.2); margin-right: 15px; }
.cat-info h3 { margin: 0; font-size: 1.1rem; text-transform: uppercase; font-weight: 800; }
.cat-info span { font-size: 0.8rem; opacity: 0.8; }


.bg-orange { background: linear-gradient(135deg, #f0932b, #ffbe76); }
.bg-green { background: linear-gradient(135deg, #6ab04c, #badc58); }
.bg-blue { background: linear-gradient(135deg, #22a6b3, #7ed6df); }
.bg-red { background: linear-gradient(135deg, #eb4d4b, #ff7979); }
.bg-purple { background: linear-gradient(135deg, #be2edd, #e056fd); }
.bg-dark { background: linear-gradient(135deg, #30336b, #535c68); }


.section-title { font-size: 1.5rem; margin-bottom: 20px; font-weight: 700; display: flex; align-items: center; gap: 10px; }
.section-title::before { content: ''; width: 5px; height: 25px; background: var(--primary); border-radius: 5px; display: block; }

.game-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 15px;
}
.game-card {
    background: #fff;
    border-radius: 12px;
    padding: 8px;
    text-decoration: none;
    box-shadow: var(--shadow);
    transition: 0.2s;
    text-align: center;
}
.game-card:hover { transform: scale(1.05); z-index: 2; }
.game-card img { aspect-ratio: 1/1; object-fit: cover; width: 100%; border-radius: 8px; }
.game-title { font-size: 0.9rem; color: var(--text-dark); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; }


.game-layout { display: flex; gap: 20px; margin-top: 20px; flex-wrap: wrap; }
.game-area { flex: 3; min-width: 600px; }
.sidebar { flex: 1; min-width: 300px; display: flex; flex-direction: column; align-items: center; }

.iframe-container {
    position: relative;
    width: 100%;
    padding-top: 56.25%; 
    background: #000;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}


.game-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-size: cover;
    background-position: center;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}
.game-overlay::after { /* Karartma */
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.6); backdrop-filter: blur(5px); z-index: -1;
}
.play-btn {
    background: linear-gradient(45deg, #f0932b, #eb4d4b);
    color: white; border: none; padding: 15px 50px; font-size: 1.5rem;
    border-radius: 50px; cursor: pointer; font-weight: 800;
    box-shadow: 0 0 20px rgba(235, 77, 75, 0.5);
    transition: 0.3s;
    animation: pulse 1.5s infinite;
}
.play-btn:hover { transform: scale(1.1); }

iframe {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: none;
    z-index: 1;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Footer */
footer { background: #fff; padding: 40px 0; margin-top: 50px; text-align: center; border-top: 1px solid #eee; }

/* Responsive */
@media (max-width: 768px) {
    .game-layout { flex-direction: column; }
    .game-area { min-width: 100%; }
    .ad-970 { display: none; } 
}


.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin: 40px 0;
    flex-wrap: wrap;
}

.page-btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    min-width: 40px;
    height: 40px;
    padding: 0 10px;
    background: #fff;
    color: var(--text-dark);
    font-weight: 700;
    text-decoration: none;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    transition: all 0.2s;
    font-size: 1rem;
}

.page-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.1);
    background: #f1f2f6;
}

.page-btn.active {
    background: var(--primary);
    color: #fff;
    box-shadow: 0 4px 15px rgba(108, 92, 231, 0.4);
    pointer-events: none; /* Tıklanmasın */
}

.page-btn.disabled {
    opacity: 0.5;
    pointer-events: none;
    background: #e0e0e0;
}


.nav-wrapper {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap; 
}

.nav-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: transparent;
    color: var(--text-dark);
    text-decoration: none;
    font-weight: 700;
    border-radius: 50px;
    transition: all 0.2s ease;
    font-size: 0.95rem;
}

.nav-link:hover {
    background: #eccc68; /* Hover rengi */
    color: #fff;
    transform: translateY(-2px);
}


.nav-link.active {
    background: var(--primary);
    color: #fff;
    box-shadow: 0 4px 10px rgba(108, 92, 231, 0.3);
}


.nav-icon { font-size: 1.1rem; }


@media (max-width: 900px) {
    .main-header { flex-direction: column; gap: 15px; }
    .nav-wrapper { justify-content: center; width: 100%; overflow-x: auto; white-space: nowrap; padding-bottom: 5px; }
    .search-box { width: 100%; }
}


.text-content {
    background: #fff;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    margin-top: 20px;
    line-height: 1.8;
    color: #444;
}
.text-content h1 { color: var(--text-dark); margin-bottom: 10px; }
.text-content h2 { color: var(--primary); margin-top: 30px; font-size: 1.4rem; }
.text-content ul { padding-left: 20px; }
.text-content li { margin-bottom: 10px; }