/**
 * gamehtm_cards Section Styles
 * Collector'tZ Game Section
 * Displays game cards and hall of fame
 */

/* ============================================================
 * MAIN SECTION
 * ============================================================ */

.gamehtm_cards {
    position: relative;
    width: 100%;
    min-height: auto;
    padding: 0;
    overflow: hidden;
    background: var(--color-bg);
}

/* ============================================================
 * BACKGROUND LAYER
 * ============================================================ */

.gamehtm_cards__background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center bottom;
    z-index: 1;
}

/* ============================================================
 * WRAPPER (container_sections)
 * ============================================================ */

.gamehtm_cards__container {
    position: relative;
    width: 100%;
    z-index: 1000;
    padding: 60px 20px;
}

.gamehtm_cards__wrapper {
    position: relative;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px;
    background: rgba(20, 20, 30, 0.85);
    backdrop-filter: blur(10px);
    border-radius: 8px;
    border: 1px solid rgba(132, 185, 255, 0.1);
}

/* ============================================================
 * HEADER WITH NAVIGATION ARROWS
 * ============================================================ */

.gamehtm_cards__header {
    text-align: center;
    margin-bottom: 30px;
}

/* ============================================================
 * TYPOGRAPHY
 * ============================================================ */

.gamehtm_cards__title {
    font-family: 'Changa', sans-serif;
    font-weight: 400;
    font-size: 2.5rem;
    color: var(--color-link);
    margin-bottom: 10px;
    text-align: center;
    letter-spacing: 0.02em;
}

.gamehtm_cards__subtitle {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.9);
    margin: 15px 0;
    text-align: center;
    font-weight: 500;
}

.gamehtm_cards__description {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.6;
    margin: 20px 0;
    text-align: center;
}

/* ============================================================
 * BUTTON
 * ============================================================ */

.gamehtm_cards__reveal-btn {
    background: linear-gradient(135deg, #0dcaf0 0%, #13c8e7 100%);
    color: #000;
    border: none;
    padding: 12px 30px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    display: block;
    margin: 30px auto;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(13, 202, 240, 0.3);
}

.gamehtm_cards__reveal-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(13, 202, 240, 0.5);
}

.gamehtm_cards__reveal-btn:active {
    transform: translateY(0);
}

.gamehtm_cards__reveal-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ============================================================
 * GAME BOARD
 * ============================================================ */

.gamehtm_cards__board {
    margin: 40px 0;
}

.game-board {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 20px;
    padding: 20px;
    background: rgba(50, 50, 80, 0.3);
    border-radius: 8px;
    border: 1px solid rgba(132, 185, 255, 0.1);
}

.game-card-stack {
    position: relative;
    aspect-ratio: 3 / 4;
    cursor: pointer;
    background: rgba(50, 50, 80, 0.6);
    border: 2px solid rgba(132, 185, 255, 0.3);
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    padding: 10px;
}

.game-card-stack:hover {
    border-color: rgba(132, 185, 255, 0.6);
    box-shadow: 0 4px 15px rgba(13, 202, 240, 0.2);
    transform: translateY(-4px);
}

.game-card-stack.card_success {
    border-color: rgba(25, 200, 100, 0.6);
    background: rgba(25, 200, 100, 0.1);
    box-shadow: inset 0 0 20px rgba(25, 200, 100, 0.1);
}

.game-card-stack.card_success:hover {
    box-shadow: 0 4px 20px rgba(25, 200, 100, 0.3);
}

/* ============================================================
 * CARD IMAGES
 * ============================================================ */

.game-card-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.5s ease;
    opacity: 0;
}

.game-card-img.active {
    z-index: 10;
    opacity: 1;
}

.game-card-img.owned-card {
    filter: drop-shadow(0 0 8px rgba(25, 200, 100, 0.6));
}

/* ============================================================
 * CARD NAME
 * ============================================================ */

.card-name {
    position: relative;
    z-index: 20;
    font-size: 0.8rem;
    font-weight: 600;
    color: white;
    text-align: center;
    background: rgba(0, 0, 0, 0.7);
    padding: 6px 8px;
    border-radius: 4px;
    width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 8px;
}

.card-name small {
    font-size: 0.7rem;
    color: rgba(25, 200, 100, 0.9);
    margin-left: 4px;
}

/* ============================================================
 * HALL OF FAME
 * ============================================================ */

.gamehtm_cards__hof {
    margin-top: 40px;
    padding: 20px;
    background: rgba(50, 50, 80, 0.3);
    border-radius: 8px;
    border: 1px solid rgba(132, 185, 255, 0.1);
}

/* ============================================================
 * FOOTER TEXT
 * ============================================================ */

.gamehtm_cards__footer-text {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.6);
    text-align: center;
    margin: 20px 0;
    font-style: italic;
}

/* ============================================================
 * GAME LINK
 * ============================================================ */

.gamehtm_cards__game-link {
    background: linear-gradient(135deg, #0dcaf0 0%, #13c8e7 100%);
    color: #000;
    border: none;
    padding: 12px 30px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    display: block;
    margin: 20px auto;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(13, 202, 240, 0.3);
    text-decoration: none;
    text-align: center;
}

.gamehtm_cards__game-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(13, 202, 240, 0.5);
    color: #000;
    text-decoration: none;
}

/* ============================================================
 * FOOTER WITH NAVIGATION ARROWS
 * ============================================================ */

.gamehtm_cards__footer {
    text-align: center;
    margin-top: 30px;
}

/* ============================================================
 * RESPONSIVE
 * ============================================================ */

@media (max-width: 768px) {
    .gamehtm_cards__title {
        font-size: 1.8rem;
    }

    .gamehtm_cards__subtitle {
        font-size: 1rem;
    }

    .gamehtm_cards__wrapper {
        padding: 25px;
    }

    .game-board {
        grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
        gap: 15px;
        padding: 15px;
    }

    .gamehtm_cards__container {
        padding: 40px 15px;
    }
}

/* ============================================================
 * DARK THEME
 * ============================================================ */

.gamehtm_cards.theme-dark {
    --color-link: #84b9ff;
    --color-bg: #0d0d1a;
    --color-surface: rgba(20, 20, 30, 0.85);
    --color-border: rgba(132, 185, 255, 0.1);
}

/* ============================================================
 * LIGHT THEME
 * ============================================================ */

.gamehtm_cards.theme-light {
    --color-link: #0d6efd;
    --color-bg: #ffffff;
    --color-surface: rgba(255, 255, 255, 0.95);
    --color-border: rgba(13, 110, 253, 0.1);
}

.gamehtm_cards.theme-light .gamehtm_cards__description {
    color: rgba(0, 0, 0, 0.7);
}

.gamehtm_cards.theme-light .gamehtm_cards__subtitle {
    color: rgba(0, 0, 0, 0.9);
}

.gamehtm_cards.theme-light .game-card-stack {
    background: rgba(240, 240, 250, 0.8);
    border-color: rgba(13, 110, 253, 0.2);
}

.gamehtm_cards.theme-light .game-card-stack:hover {
    border-color: rgba(13, 110, 253, 0.5);
}