/* CrunchHub Catalog Styles */

.hub-container { padding: 30px 0; }

.hub-hero-banner { background: linear-gradient(135deg, #181d28 0%, #0f1219 100%); border-radius: 8px; padding: 25px 30px; margin-bottom: 25px; border-left: 5px solid #FFD800; box-shadow: 0 8px 30px rgba(0,0,0,0.4); }
.hub-hero-title { font-size: 2.2em; font-weight: bold; text-transform: uppercase; margin-bottom: 4px; color: #fff; }
.hub-hero-title span { color: #FFD800; }
.hub-hero-subtitle { color: #8c9ba5; font-size: 1.05em; }

.filter-controls { display: flex; flex-direction: column; gap: 12px; margin-bottom: 25px; }
.search-input-wrap { flex: 1 1 320px; min-width: 260px; }
.search-input, .search-field { width: 100%; height: 50px; background: #141820; border: 1px solid #232936; border-radius: 8px; padding: 14px 20px; color: #ffffff; font-size: 15px; font-weight: 500; outline: none; box-sizing: border-box; transition: all 0.2s; display: block; }
.search-input::placeholder, .search-field::placeholder { color: #7C818D; }
.search-input:focus, .search-field:focus { border-color: #FFD800; background: #1a1f2c; box-shadow: 0 0 12px rgba(255,216,0,0.2); }

.alphabet-bar { background: #141820; border-radius: 6px; padding: 8px 14px; display: flex; flex-wrap: wrap; gap: 5px; align-items: center; border: 1px solid #232936; }
.alphabet-label { font-size: 0.85em; font-weight: bold; color: #8c9ba5; text-transform: uppercase; margin-right: 6px; }
.alpha-btn { color: #cbd5e0; background: #1a1f2c; border: 1px solid #232936; font-weight: bold; font-size: 0.85em; padding: 5px 10px; border-radius: 4px; cursor: pointer; transition: all 0.15s; }
.alpha-btn:hover, .alpha-btn.active { background: #FFD800; color: #000; border-color: #FFD800; }

.game-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; margin-bottom: 40px; }
@media (max-width: 1024px) { .game-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 768px)  { .game-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px)  { .game-grid { grid-template-columns: 1fr; } }

.game-card { background: #1a1f2c; border: 1px solid #232936; border-radius: 8px; overflow: hidden; display: flex; flex-direction: column; text-decoration: none; color: inherit; box-shadow: 0 4px 15px rgba(0,0,0,0.25); transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s; cursor: pointer; }
.game-card:hover { transform: translateY(-5px); box-shadow: 0 10px 25px rgba(0,0,0,0.45); border-color: #FFD800; }
.game-card__cover { width: 100%; height: 180px; position: relative; overflow: hidden; background: #000; }
.game-card__cover img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s ease; display: block; }
.game-card:hover .game-card__cover img { transform: scale(1.05); }
.game-card__badge { position: absolute; top: 8px; left: 8px; background: #FFD800; color: #000; font-size: 0.75em; font-weight: bold; padding: 3px 7px; border-radius: 4px; text-transform: uppercase; z-index: 2; }
.game-card__rating { position: absolute; bottom: 8px; right: 8px; background: rgba(0,0,0,0.85); color: #fff; font-size: 0.8em; font-weight: bold; padding: 2px 7px; border-radius: 4px; z-index: 2; }
.game-card__rating span { color: #FFD800; }
.game-card__body { padding: 14px 16px; display: flex; flex-direction: column; flex-grow: 1; background: #1a1f2c; }
.game-card__title { font-size: 1.15em; font-weight: bold; margin-bottom: 4px; line-height: 1.3; color: #fff; transition: color 0.2s; }
.game-card:hover .game-card__title { color: #FFD800; }
.game-card__dev { color: #8c9ba5; font-size: 0.85em; margin-bottom: 12px; }
.game-card__footer { margin-top: auto; padding-top: 10px; border-top: 1px solid #232936; display: flex; align-items: center; justify-content: space-between; font-size: 0.8em; color: #8c9ba5; }
.game-card__year { color: #FFD800; font-weight: bold; font-size: 1.1em; }
.game-card__year.released { color: #48bb78 !important; font-weight: 800; }
.game-card__year.upcoming  { color: #FFD800 !important; font-weight: 800; }
.loading-state { text-align: center; padding: 60px 0; color: #8c9ba5; font-size: 1.2em; }

.catalog-meta-bar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; padding-bottom: 12px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.catalog-count { font-size: 15px; color: #8C9BA5; font-weight: 500; }
.catalog-count strong { color: #FFD800; font-weight: 800; }

.pagination-wrap { display: flex; justify-content: center; align-items: center; gap: 8px; margin: 40px 0 20px; flex-wrap: wrap; }
.page-btn { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; height: 44px; padding: 0 14px; background: #282B33; border: 1px solid rgba(255,255,255,0.08); border-radius: 8px; color: #FFFFFF; font-size: 15px; font-weight: 700; cursor: pointer; text-decoration: none; transition: all 0.2s ease; user-select: none; }
.page-btn:hover:not(.disabled):not(.active) { background: #343842; border-color: #FFD800; color: #FFD800; transform: translateY(-2px); }
.page-btn.active { background: #FFD800; color: #1A1D22; border-color: #FFD800; font-weight: 800; box-shadow: 0 4px 14px rgba(255,216,0,0.3); }
.page-btn.disabled { opacity: 0.35; cursor: not-allowed; pointer-events: none; }
.page-dots { color: #7C818D; font-size: 16px; padding: 0 4px; }

.filter-controls-row { display: flex; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; align-items: center; }
.platform-dropdown-wrap { position: relative; user-select: none; }
.platform-dropdown-btn { display: inline-flex; align-items: center; gap: 10px; height: 50px; padding: 0 20px; background: #282B33; border: 1px solid rgba(255,255,255,0.1); border-radius: 8px; color: #FFFFFF; font-size: 15px; font-weight: 700; cursor: pointer; transition: all 0.2s; }
.platform-dropdown-btn:hover, .platform-dropdown-wrap.open .platform-dropdown-btn { border-color: #FFD800; color: #FFD800; box-shadow: 0 4px 15px rgba(255,216,0,0.15); }
.platform-dropdown-btn .badge-count { background: #FFD800; color: #1A1D22; font-size: 12px; font-weight: 800; padding: 2px 8px; border-radius: 12px; margin-left: 4px; }
.platform-dropdown-menu { position: absolute; top: 58px; left: 0; width: 340px; max-height: 440px; background: #20232A; border: 1px solid rgba(255,216,0,0.3); border-radius: 10px; box-shadow: 0 12px 35px rgba(0,0,0,0.6); z-index: 1000; display: none; flex-direction: column; padding: 12px; box-sizing: border-box; }
.platform-dropdown-wrap.open .platform-dropdown-menu { display: flex; }
.plat-search-field { width: 100%; height: 40px; background: #181A20; border: 1px solid rgba(255,255,255,0.1); border-radius: 6px; padding: 0 12px; color: #FFFFFF; font-size: 14px; box-sizing: border-box; outline: none; margin-bottom: 8px; }
.plat-search-field:focus { border-color: #FFD800; }
.plat-actions { display: flex; justify-content: space-between; padding: 4px 2px 8px; border-bottom: 1px solid rgba(255,255,255,0.08); margin-bottom: 8px; }
.plat-action-btn { background: transparent; border: none; color: #8C9BA5; font-size: 13px; font-weight: 700; cursor: pointer; padding: 2px 6px; border-radius: 4px; transition: color 0.2s; }
.plat-action-btn:hover { color: #FFD800; }
.plat-list-scroll { overflow-y: auto; max-height: 300px; padding-right: 4px; }
.plat-list-scroll::-webkit-scrollbar { width: 6px; }
.plat-list-scroll::-webkit-scrollbar-thumb { background: #343842; border-radius: 3px; }
.plat-group-title { font-size: 12px; text-transform: uppercase; color: #FFD800; font-weight: 800; letter-spacing: 0.5px; margin: 10px 0 6px 4px; }
.plat-item { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-radius: 6px; cursor: pointer; color: #E2E8F0; font-size: 14px; font-weight: 600; transition: background 0.15s; }
.plat-item:hover { background: #2C303A; color: #FFFFFF; }
.plat-item input[type=checkbox] { appearance: none; width: 18px; height: 18px; border: 2px solid #5A606D; border-radius: 4px; background: #181A20; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; position: relative; margin: 0; outline: none; transition: all 0.2s; }
.plat-item input[type=checkbox]:checked { background: #FFD800; border-color: #FFD800; }
.plat-item input[type=checkbox]:checked::after { content: '\2714'; font-size: 12px; color: #1A1D22; font-weight: 900; position: absolute; }

.reset-filters-btn { display: inline-flex; align-items: center; gap: 8px; height: 50px; padding: 0 20px; background: #282B33; border: 1px solid rgba(255,255,255,0.1); border-radius: 8px; color: #8C9BA5; font-size: 15px; font-weight: 700; cursor: pointer; transition: all 0.2s; user-select: none; white-space: nowrap; box-sizing: border-box; }
.reset-filters-btn:hover { background: #343842; border-color: #FFD800; color: #FFD800; transform: translateY(-2px); }
.extra-filter-toggle-btn { display: inline-flex; align-items: center; gap: 8px; height: 50px; padding: 0 18px; background: #282B33; border: 1px solid rgba(255,255,255,0.1); border-radius: 8px; color: #FFFFFF; font-size: 15px; font-weight: 700; cursor: pointer; transition: all 0.2s; user-select: none; white-space: nowrap; box-sizing: border-box; }
.extra-filter-toggle-btn:hover, .extra-filter-toggle-btn.active { border-color: #FFD800; color: #FFD800; background: #343842; }
.extra-filter-toggle-btn .arrow { transition: transform 0.25s ease; font-size: 10px; }
.extra-filter-toggle-btn.active .arrow { transform: rotate(180deg); }
.extra-filters-drawer { display: none; background: #181B22; border: 1px solid rgba(255,216,0,0.25); border-radius: 10px; padding: 24px; margin-top: 14px; margin-bottom: 20px; box-shadow: 0 10px 30px rgba(0,0,0,0.45); animation: hubFadeIn 0.2s ease-out; }
.extra-filters-drawer.open { display: block; }
@keyframes hubFadeIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }
.extra-filters-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.extra-filter-section-title { font-size: 14px; text-transform: uppercase; font-weight: 800; color: #FFD800; letter-spacing: 0.5px; margin-bottom: 12px; display: flex; align-items: center; gap: 6px; }
.extra-select-control { width: 100%; height: 44px; background: #20242E; border: 1px solid rgba(255,255,255,0.12); border-radius: 6px; padding: 0 14px; color: #FFFFFF; font-size: 14px; outline: none; box-sizing: border-box; cursor: pointer; }
.extra-select-control:focus { border-color: #FFD800; }
.extra-select-control option { background: #141820; color: #FFFFFF; padding: 8px; }
.extra-genres-container { display: flex; flex-wrap: wrap; gap: 8px; max-height: 140px; overflow-y: auto; padding-right: 4px; }
.extra-genres-container::-webkit-scrollbar { width: 5px; }
.extra-genres-container::-webkit-scrollbar-thumb { background: #343842; border-radius: 3px; }
.genre-chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; background: #20242E; border: 1px solid rgba(255,255,255,0.08); border-radius: 6px; color: #cbd5e0; font-size: 13px; font-weight: 600; cursor: pointer; user-select: none; transition: all 0.15s; }
.genre-chip:hover { background: #2A303D; color: #FFFFFF; }
.genre-chip.active { background: #FFD800; color: #1A1D22; border-color: #FFD800; font-weight: 800; }

