/* v103: build-house is a reward activity, separated from pure minigames. */
.hunter-page .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house,
.hunter-page .hunter-game-card.hunter-explore-list-mode .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house {
    position: relative !important;
    min-height: 86px !important;
    margin-top: 18px !important;
    overflow: visible !important;
    border: 2px solid rgba(99, 102, 241, .72) !important;
    border-radius: 20px !important;
    padding: 16px 118px 16px 17px !important;
    color: #eef2ff !important;
    background:
        radial-gradient(circle at 94% 12%, rgba(129, 140, 248, .34), transparent 30%),
        linear-gradient(135deg, #172554, #312e81 52%, #4338ca) !important;
    outline: 3px solid rgba(99, 102, 241, .2);
    outline-offset: 3px;
    box-shadow:
        0 10px 22px rgba(30, 41, 120, .26),
        inset 0 1px 0 rgba(255, 255, 255, .18) !important;
}

.hunter-page .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house::before,
.hunter-page .hunter-game-card.hunter-explore-list-mode .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house::before {
    content: "成就＋獎勵" !important;
    position: absolute !important;
    top: 11px !important;
    right: 13px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 4px 9px !important;
    border: 1px solid rgba(224, 231, 255, .34) !important;
    border-radius: 999px !important;
    color: #e0e7ff !important;
    background: rgba(15, 23, 42, .34) !important;
    font-size: 11px !important;
    font-weight: 950 !important;
    letter-spacing: .04em;
    line-height: 1.1 !important;
    box-shadow: 0 4px 10px rgba(15, 23, 42, .18);
    pointer-events: none !important;
    z-index: 2;
}

.hunter-page .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house::after,
.hunter-page .hunter-game-card.hunter-explore-list-mode .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house::after {
    content: "50 層" !important;
    position: absolute !important;
    right: 17px !important;
    bottom: 13px !important;
    top: auto !important;
    left: auto !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-width: 54px !important;
    padding: 5px 8px !important;
    border: 1px solid rgba(224, 231, 255, .28) !important;
    border-radius: 7px !important;
    color: #e0e7ff !important;
    background: rgba(15, 23, 42, .3) !important;
    font-size: 11px !important;
    font-weight: 950 !important;
    letter-spacing: .08em;
    line-height: 1.1 !important;
    transform: none !important;
    pointer-events: none !important;
    z-index: 1;
}

.hunter-page .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house:hover,
.hunter-page .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house:focus-visible,
.hunter-page .hunter-game-card.hunter-explore-list-mode .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house:hover,
.hunter-page .hunter-game-card.hunter-explore-list-mode .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house:focus-visible {
    transform: translateY(-1px) !important;
    border-color: rgba(165, 180, 252, .96) !important;
    outline-color: rgba(129, 140, 248, .34);
    box-shadow:
        0 14px 28px rgba(30, 41, 120, .32),
        0 0 0 3px rgba(129, 140, 248, .12),
        inset 0 1px 0 rgba(255, 255, 255, .24) !important;
}

.hunter-page .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house.active,
.hunter-page .hunter-game-card.hunter-explore-list-mode .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house.active {
    border-color: rgba(199, 210, 254, .96) !important;
    background: linear-gradient(135deg, #3730a3, #6366f1) !important;
}

.hunter-page .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house > span,
.hunter-page .hunter-game-card.hunter-explore-list-mode .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house > span {
    color: #ffffff !important;
    text-shadow: 0 1px 2px rgba(15, 23, 42, .34);
}

.hunter-page .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house > small,
.hunter-page .hunter-game-card.hunter-explore-list-mode .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house > small {
    color: rgba(224, 231, 255, .94) !important;
    font-weight: 900 !important;
    text-shadow: 0 1px 2px rgba(15, 23, 42, .28);
}

@media (max-width: 768px) {
    .hunter-page .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house,
    .hunter-page .hunter-game-card.hunter-explore-list-mode .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house {
        min-height: 82px !important;
        margin-top: 16px !important;
        padding: 14px 104px 14px 14px !important;
    }

    .hunter-page .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house::before,
    .hunter-page .hunter-game-card.hunter-explore-list-mode .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house::before {
        top: 9px !important;
        right: 10px !important;
        padding: 4px 7px !important;
        font-size: 10px !important;
    }

    .hunter-page .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house::after,
    .hunter-page .hunter-game-card.hunter-explore-list-mode .hunter-explore-room .hunter-explore-game-entry.hunter-explore-game-entry--build-house::after {
        right: 12px !important;
        bottom: 11px !important;
        min-width: 46px !important;
        padding: 4px 6px !important;
        font-size: 10px !important;
    }
}


/* v101: Snack Memory mobile scroll recovery
   - the previous compact/explore fixes made the memory panel participate in a flex fill layout,
     which could clip the lower part of the board on mobile.
   - keep the game inside the app scroller, but let the memory card grow naturally. */
@media (max-width: 768px) {
    body.hunter-page.hunter-explore-playing-mode #hunterGameRoot.hunter-game-card .hunter-game-views,
    .hunter-page #hunterGameRoot.hunter-game-card.hunter-explore-playing-mode .hunter-game-views,
    .hunter-page #hunterGameRoot.hunter-game-card:has(.hunter-explore-room.active.is-playing-explore-game) .hunter-game-views {
        overflow-x: hidden !important;
        overflow-y: auto !important;
        overscroll-behavior-y: contain !important;
        -webkit-overflow-scrolling: touch !important;
    }

    body.hunter-page.hunter-explore-playing-mode #hunterGameRoot.hunter-game-card .hunter-subtab-panel[data-hunter-subtab-panel="memory"].active,
    .hunter-page #hunterGameRoot.hunter-game-card.hunter-explore-playing-mode .hunter-subtab-panel[data-hunter-subtab-panel="memory"].active,
    .hunter-page #hunterGameRoot.hunter-game-card:has(.hunter-explore-room.active.is-playing-explore-game) .hunter-subtab-panel[data-hunter-subtab-panel="memory"].active {
        display: block !important;
        flex: 0 0 auto !important;
        width: 100% !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow: visible !important;
        padding-bottom: 22px !important;
    }

    body.hunter-page.hunter-explore-playing-mode #hunterGameRoot.hunter-game-card .hunter-subtab-panel[data-hunter-subtab-panel="memory"].active .hunter-minigame-shell,
    .hunter-page #hunterGameRoot.hunter-game-card.hunter-explore-playing-mode .hunter-subtab-panel[data-hunter-subtab-panel="memory"].active .hunter-minigame-shell,
    .hunter-page #hunterGameRoot.hunter-game-card:has(.hunter-explore-room.active.is-playing-explore-game) .hunter-subtab-panel[data-hunter-subtab-panel="memory"].active .hunter-minigame-shell {
        display: block !important;
        flex: none !important;
        width: 100% !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow: visible !important;
        padding: 0 !important;
    }

    body.hunter-page.hunter-explore-playing-mode #hunterGameRoot.hunter-game-card .hunter-memory-game-card,
    .hunter-page #hunterGameRoot.hunter-game-card.hunter-explore-playing-mode .hunter-memory-game-card,
    .hunter-page #hunterGameRoot.hunter-game-card:has(.hunter-explore-room.active.is-playing-explore-game) .hunter-memory-game-card {
        display: block !important;
        flex: none !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow: visible !important;
        margin-bottom: 24px !important;
    }

    body.hunter-page.hunter-explore-playing-mode #hunterGameRoot.hunter-game-card .hunter-memory-board,
    .hunter-page #hunterGameRoot.hunter-game-card.hunter-explore-playing-mode .hunter-memory-board,
    .hunter-page #hunterGameRoot.hunter-game-card:has(.hunter-explore-room.active.is-playing-explore-game) .hunter-memory-board {
        min-height: 0 !important;
        align-content: start !important;
        padding-bottom: max(24px, env(safe-area-inset-bottom, 0px)) !important;
    }

    body.hunter-page.hunter-explore-playing-mode #hunterGameRoot.hunter-game-card .hunter-memory-game-card.is-playing .hunter-memory-board,
    .hunter-page #hunterGameRoot.hunter-game-card.hunter-explore-playing-mode .hunter-memory-game-card.is-playing .hunter-memory-board,
    .hunter-page #hunterGameRoot.hunter-game-card:has(.hunter-explore-room.active.is-playing-explore-game) .hunter-memory-game-card.is-playing .hunter-memory-board {
        min-height: 0 !important;
    }
}

