/* ==========================================
   Index Page Styles
   ========================================== */

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%);
    color: var(--white);
    padding: 80px 0;
    text-align: center;
}

.hero-content h1 {
    font-size: 48px;
    margin-bottom: 20px;
    animation: fadeInUp 0.8s ease;
}

.hero-subtitle {
    font-size: 20px;
    margin-bottom: 30px;
    opacity: 0.95;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    animation: fadeInUp 0.8s ease 0.2s both;
}

.hero-actions {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeInUp 0.8s ease 0.4s both;
}

.btn-large {
    padding: 16px 32px;
    font-size: 18px;
}

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

/* Search Section */
.search-section {
    background-color: var(--white);
    padding: 40px 0;
    box-shadow: var(--box-shadow);
    margin-bottom: 40px;
}

.search-box {
    display: flex;
    max-width: 600px;
    margin: 0 auto;
    gap: 10px;
}

.search-box input {
    flex: 1;
    padding: 14px 20px;
    border: 2px solid var(--light-gray);
    border-radius: var(--border-radius);
    font-size: 16px;
    transition: var(--transition);
}

.search-box input:focus {
    outline: none;
    border-color: var(--secondary-color);
}

.search-box .btn {
    padding: 14px 30px;
}

/* Categories Section */
.categories-section {
    margin-bottom: 60px;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 20px;
}

.category-card {
    background: linear-gradient(135deg, #3a3a3a, #2a2a2a);
    color: var(--white);
    padding: 30px 20px;
    border-radius: var(--border-radius);
    text-align: center;
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.category-card .category-icon {
    font-size: 48px;
    margin-bottom: 10px;
    display: block;
}

.category-card h3 {
    font-size: 20px;
    margin-bottom: 5px;
}

.category-card .game-count {
    opacity: 0.9;
    font-size: 14px;
}

/* Games Section */
.games-section {
    margin-bottom: 60px;
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

/* Enhanced Game Card Styles */
.game-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8f8f8 100%);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    color: var(--text-color);
    border: 1px solid #e0e0e0;
    display: flex;
    flex-direction: column;
    height: 100%;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.game-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
    border-color: var(--secondary-color);
}

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

.game-card:hover .game-card-image {
    transform: scale(1.1);
}

.game-card-content {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.game-card-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--primary-color);
    line-height: 1.4;
}

.game-card-description {
    font-size: 13px;
    color: var(--gray);
    line-height: 1.5;
    margin-bottom: 12px;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.game-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid #f0f0f0;
}

.game-category {
    background: linear-gradient(135deg, var(--secondary-color) 0%, #f59e0b 100%);
    color: var(--white);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.game-rating {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: var(--primary-color);
}

.star-rating {
    display: flex;
    gap: 2px;
}

.star {
    color: #ffd700;
    font-size: 14px;
}

.star.empty {
    color: #ddd;
}

/* Trending Games Section */
.trending-section {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    padding: 60px 0;
    margin-bottom: 60px;
}

.trending-section .section-title {
    color: var(--white);
    text-align: center;
    margin-bottom: 40px;
}

.trending-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-bottom: 20px;
}

.trending-card {
    background: linear-gradient(to bottom, rgba(255,255,255,0.95), rgba(248,248,248,0.98));
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    text-decoration: none;
    color: var(--text-color);
    border: 1px solid rgba(255,255,255,0.5);
    display: flex;
    flex-direction: column;
    position: relative;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.trending-card:hover {
    transform: translateY(-12px) scale(1.03);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    border-color: var(--secondary-color);
}

.trending-card-image {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
}

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

.trending-card:hover .trending-card-image img {
    transform: scale(1.15) rotate(2deg);
}

.trending-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: white;
    padding: 8px 12px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 14px;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
}

.trending-card-content {
    padding: 24px 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.trending-card-title {
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--primary-color);
    line-height: 1.3;
}

.trending-card-description {
    font-size: 13px;
    color: var(--gray);
    line-height: 1.5;
    margin-bottom: 14px;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.trending-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 14px;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.trending-category {
    background: linear-gradient(135deg, #e879f9 0%, #c084fc 100%);
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.trending-rating {
    display: flex;
    gap: 2px;
}

/* Blog Section */
.blog-section {
    display: none;
}

/* About Section */
.about-section {
    margin-bottom: 60px;
}

.about-content {
    max-width: 900px;
    margin: 0 auto;
    text-align: center;
}

.about-content h2 {
    font-size: 36px;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.about-content p {
    font-size: 16px;
    line-height: 1.8;
    color: var(--gray);
    margin-bottom: 15px;
}

.about-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.feature {
    padding: 20px;
}

.feature-icon {
    font-size: 48px;
    display: block;
    margin-bottom: 15px;
}

.feature h3 {
    font-size: 20px;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.feature p {
    font-size: 14px;
    color: var(--gray);
    margin: 0;
}

/* Utility Classes */
.text-center {
    text-align: center;
    margin-top: 30px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 36px;
    }

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

    .hero-actions {
        flex-direction: column;
        align-items: center;
    }

    .btn-large {
        padding: 14px 28px;
        font-size: 16px;
    }

    .search-box {
        flex-direction: column;
    }

    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    .games-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 20px;
    }

    .game-card-image {
        height: 150px;
    }

    .trending-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .about-features {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 60px 0;
    }

    .hero-content h1 {
        font-size: 28px;
    }

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

    .game-card-image {
        height: 120px;
    }

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