/* Data Source Notice */
.data-source-notice {
    width: 100%;
    background: #000;
    color: #fff;
    text-align: center;
    padding: 10px 0;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 20px;
}

.data-source-notice p {
    margin: 0;
}

/* Main Container */
main {
    display: flex;
    flex-direction: column;
}

.ready-container {
    width: 100%;
    max-width: var(--all-width);
    margin: 0 auto;
    padding: 0 15px;
}

/* Featured Game Section */
.featured-game-section {
    margin-bottom: 40px;
}

.featured-game-section h2 {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin-bottom: 16px;
}

.game {
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    background-color: #fff;
    padding: 30px;
    box-shadow: 0 1px 4px rgba(16, 20, 30, .05), 0 2px 2px rgba(16, 20, 30, .1), 0 0 2px rgba(16, 20, 30, .05);
}

.game .bg {
    position: absolute;
    width: 100%;
    height: 100%;
    z-index: 0;
    filter: blur(15px) brightness(0.9);
    opacity: 0.2;
}

.game-content {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 40px;
    width: 100%;
}

.game .img-box {
    width: 280px;
    height: 280px;
    overflow: hidden;
    border-radius: 10px;
    border: 2px solid #ddd;
    flex-shrink: 0;
}

.game .img-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

.game-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
}

.game h3 {
    font-size: 28px;
    font-weight: 700;
    color: #333;
    margin: 0;
    line-height: 1.2;
}

.category-badge {
    color: #40434b;
    font-size: 16px;
    margin: 0;
}

.category-badge i {
    color: #183dff;
    font-weight: 700;
}

.game-description {
    width: 100%;
    margin: 0;
    font-size: 16px;
    line-height: 1.6;
    color: #666;
    text-align: left;
}

.game a.play {
    min-width: 200px;
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    padding: 12px 40px;
    text-align: center;
    border: none;
    background: #000;
    border-radius: 5px;
    transition: all 0.3s ease;
    letter-spacing: 2px;
}

.game a.play:hover {
    background: #333;
}

/* Screenshots Section */
.screenshots-section {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid #e0e0e0;
}

.screenshots-section h3 {
    font-size: 20px;
    font-weight: 700;
    color: #333;
    margin-bottom: 20px;
}

.screenshots-container {
    min-height: 100px;
}

.loading-text {
    text-align: center;
    color: #666;
    font-size: 16px;
    padding: 40px 0;
}

.no-screenshots-text {
    text-align: center;
    color: #999;
    font-size: 16px;
    padding: 40px 0;
    font-style: italic;
}

.error-text {
    text-align: center;
    color: #f44336;
    font-size: 16px;
    padding: 20px 0;
    margin: 0;
}

.error-hint {
    text-align: center;
    color: #999;
    font-size: 14px;
    margin: 10px 0 0 0;
}

.screenshot-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.screenshot-item {
    position: relative;
    width: 100%;
    padding-top: 75%; /* 4:3 aspect ratio */
    overflow: hidden;
    border-radius: 8px;
    background: #f5f5f5;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: box-shadow 0.3s ease;
}

.screenshot-item:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.screenshot-item img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.screenshot-item:hover img {
    transform: scale(1.05);
}

/* Lightbox Styles */
.screenshot-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: lightboxFadeIn 0.3s ease;
}

.screenshot-lightbox.lightbox-closing {
    animation: lightboxFadeOut 0.3s ease;
}

@keyframes lightboxFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes lightboxFadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

.lightbox-content {
    max-width: 90%;
    max-height: 90%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-image {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 5px;
    box-shadow: 0 10px 50px rgba(0, 0, 0, 0.5);
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 40px;
    font-weight: 300;
    cursor: pointer;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s ease;
    z-index: 10001;
}

.lightbox-close:hover {
    transform: rotate(90deg);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    border: none;
    color: #fff;
    font-size: 30px;
    cursor: pointer;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease;
    z-index: 10001;
    border-radius: 5px;
}

.lightbox-nav:hover {
    background: rgba(0, 0, 0, 0.8);
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

.lightbox-counter {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    z-index: 10001;
}

/* Recommended Games Section */
.list h2 {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin-bottom: 16px;
}

/* Responsive Design */
@media screen and (max-width: 769px) {
    .data-source-notice {
        font-size: 11px;
        padding: 8px 0;
    }

    main {
        padding: 0;
    }

    .featured-game-section {
        margin-bottom: 30px;
    }

    .featured-game-section h2 {
        font-size: 20px;
    }

    .game {
        padding: 20px 15px;
        border-radius: 10px;
    }

    .game-content {
        flex-direction: column;
        gap: 20px;
    }

    .game .img-box {
        width: 80%;
        max-width: 250px;
        height: auto;
        aspect-ratio: 1;
    }

    .game-info {
        width: 100%;
        align-items: center;
        text-align: center;
    }

    .game h3 {
        font-size: 22px;
    }

    .game-description {
        display: -webkit-box;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 3;
        overflow: hidden;
        text-overflow: ellipsis;
        text-align: center;
    }

    .game a.play {
        width: 100%;
        min-width: auto;
        padding: 12px 30px;
        font-size: 16px;
    }

    .list h2 {
        font-size: 20px;
    }

    .screenshots-section {
        margin-top: 30px;
        padding-top: 20px;
    }

    .screenshots-section h3 {
        font-size: 18px;
    }

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

    /* Lightbox mobile styles */
    .lightbox-close {
        top: 10px;
        right: 10px;
        font-size: 35px;
        width: 40px;
        height: 40px;
    }

    .lightbox-nav {
        width: 40px;
        height: 40px;
        font-size: 24px;
    }

    .lightbox-prev {
        left: 10px;
    }

    .lightbox-next {
        right: 10px;
    }

    .lightbox-counter {
        bottom: 20px;
        font-size: 12px;
        padding: 6px 16px;
    }
}