/* 店内游戏库全量列表页 */

body.games-hut-library-page .container {
    max-width: none;
}

.ghl-header {
    position: relative;
    max-width: 1100px;
    margin: 0 auto;
    padding: 1.5rem 1.5rem 0.5rem;
}

.ghl-header .games-hut-back {
    position: absolute;
    top: 1.35rem;
    left: 1.25rem;
    z-index: 2;
}

.ghl-header-text {
    padding: 2.75rem 0 0.5rem;
    text-align: center;
}

.ghl-title {
    margin: 0 0 0.4rem;
    font-size: clamp(1.45rem, 3.5vw, 1.9rem);
    font-weight: 700;
    color: rgba(255, 255, 255, 0.96);
}

.ghl-lead {
    margin: 0;
    font-size: 0.92rem;
    color: var(--text-muted);
}

.ghl-main {
    max-width: 1100px;
    margin: 0 auto;
    padding: 1rem 1.5rem 100px;
}

.ghl-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.ghl-discover {
    margin-bottom: 1.25rem;
    padding: 1rem 1.05rem 1.1rem;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: linear-gradient(155deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
}

.ghl-search-form {
    margin-bottom: 1rem;
}

.ghl-search-row {
    position: relative;
    display: flex;
    align-items: center;
}

.ghl-search-icon {
    position: absolute;
    left: 0.9rem;
    color: rgba(148, 163, 184, 0.9);
    pointer-events: none;
    font-size: 0.9rem;
}

.ghl-search-input {
    width: 100%;
    box-sizing: border-box;
    padding: 0.8rem 2.4rem 0.8rem 2.4rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(0, 0, 0, 0.32);
    color: #f8fafc;
    font-size: 0.98rem;
    font-family: inherit;
}

.ghl-search-input::placeholder {
    color: rgba(148, 163, 184, 0.85);
}

.ghl-search-input:focus {
    outline: none;
    border-color: rgba(78, 205, 196, 0.55);
    box-shadow: 0 0 0 2px rgba(78, 205, 196, 0.16);
}

.ghl-search-clear {
    position: absolute;
    right: 0.45rem;
    width: 2rem;
    height: 2rem;
    border: none;
    border-radius: 999px;
    background: transparent;
    color: rgba(226, 232, 240, 0.8);
    font-size: 1.25rem;
    line-height: 1;
    cursor: pointer;
}

.ghl-search-clear:hover {
    background: rgba(255, 255, 255, 0.08);
}

.ghl-filter-block {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
}

.ghl-filter-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.ghl-filter-title {
    margin: 0;
    font-size: 0.92rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.92);
    letter-spacing: 0.02em;
}

.ghl-clear-filters {
    border: none;
    background: transparent;
    color: rgba(78, 205, 196, 0.95);
    font-size: 0.82rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    padding: 0.2rem 0.35rem;
}

.ghl-clear-filters:hover {
    text-decoration: underline;
}

.ghl-genres {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.ghl-genre-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.42rem 0.75rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.05);
    color: rgba(226, 232, 240, 0.92);
    font-size: 0.82rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
}

.ghl-genre-chip:hover {
    border-color: rgba(78, 205, 196, 0.4);
    background: rgba(78, 205, 196, 0.08);
}

.ghl-genre-chip.is-active {
    color: #0b1220;
    background: linear-gradient(135deg, #4ecdc4, #45b7d1);
    border-color: transparent;
}

.ghl-genre-count {
    min-width: 1.2rem;
    padding: 0.05rem 0.35rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    background: rgba(0, 0, 0, 0.22);
    color: inherit;
    text-align: center;
}

.ghl-genre-chip.is-active .ghl-genre-count {
    background: rgba(255, 255, 255, 0.35);
    color: #0b1220;
}

.ghl-more-genres {
    align-self: flex-start;
    padding: 0.4rem 0.75rem;
    border-radius: 999px;
    border: 1px dashed rgba(255, 255, 255, 0.22);
    background: transparent;
    color: rgba(203, 213, 225, 0.92);
    font-size: 0.8rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
}

.ghl-more-genres:hover {
    border-color: rgba(78, 205, 196, 0.45);
    color: #99f6e4;
}

.ghl-count {
    margin: 0.85rem 0 0;
    font-size: 0.84rem;
    color: var(--text-muted);
}

.ghl-card-rating {
    margin: 0;
    font-size: 0.78rem;
    font-weight: 650;
    color: #fbbf24;
}

.ghl-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem;
}

.ghl-card-tags span {
    font-size: 0.7rem;
    font-weight: 600;
    padding: 0.12rem 0.4rem;
    border-radius: 999px;
    color: rgba(167, 243, 208, 0.95);
    background: rgba(78, 205, 196, 0.12);
    border: 1px solid rgba(78, 205, 196, 0.22);
}

.ghl-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(15.5rem, 1fr));
    gap: 1.1rem;
}

.ghl-card {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 0;
    border: none;
    background: transparent;
    color: inherit;
    font: inherit;
    text-align: left;
    text-decoration: none;
    cursor: pointer;
    min-width: 0;
}

.ghl-card:focus-visible {
    outline: 2px solid var(--secondary-color);
    outline-offset: 3px;
    border-radius: 12px;
}

.ghl-card-cover {
    position: relative;
    aspect-ratio: 3 / 4;
    border-radius: 14px;
    overflow: hidden;
    background: #111;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.ghl-card:hover .ghl-card-cover {
    transform: translateY(-4px);
    border-color: rgba(78, 205, 196, 0.3);
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.4);
}

.ghl-card-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.ghl-card-cover.is-broken {
    background: linear-gradient(145deg, rgba(78, 205, 196, 0.12), rgba(255, 255, 255, 0.04));
}

.ghl-card-cover.is-broken img {
    opacity: 0;
}

.ghl-card-body {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.ghl-card-name {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.35;
    color: rgba(255, 255, 255, 0.92);
}

.ghl-card-name-en {
    margin: 0;
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1.35;
    color: rgba(148, 163, 184, 0.95);
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.ghl-card-desc {
    margin: 0;
    font-size: 0.82rem;
    line-height: 1.5;
    color: var(--text-muted);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

@media (max-width: 560px) {
    .ghl-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.85rem;
    }
}
