/* ═══════════════════════════════════════════════════════════
   CATALOG — Arsenal Store | Perfected
   ZION OFFSEC — by ZION for SNAKE
   ═══════════════════════════════════════════════════════════ */

/* ── SCREEN READER ONLY ── */
.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;
}

/* ── FLASH MESSAGES ── */
.flash-message {
    position: fixed;
    top: 80px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10000;
    padding: 14px 24px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.4);
    transition: opacity 0.3s, transform 0.3s;
    max-width: 500px;
}
.flash-success {
    background: rgba(0,255,65,0.12);
    border: 1px solid rgba(0,255,65,0.3);
    color: var(--green);
}
.flash-error {
    background: rgba(255,0,64,0.12);
    border: 1px solid rgba(255,0,64,0.3);
    color: var(--red);
}
.flash-close {
    background: none;
    border: none;
    color: inherit;
    font-size: 20px;
    cursor: pointer;
    opacity: 0.6;
    padding: 0 0 0 8px;
    line-height: 1;
}
.flash-close:hover {
    opacity: 1;
}

/* ── CATALOG HERO ── */
.catalog-hero {
    position: relative;
    padding: 50px 20px 30px;
    text-align: center;
    overflow: hidden;
}
.catalog-hero::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: 
        radial-gradient(ellipse at 30% 0%, rgba(0,255,65,0.06) 0%, transparent 60%),
        radial-gradient(ellipse at 70% 100%, rgba(0,204,255,0.04) 0%, transparent 60%);
    pointer-events: none;
}
.catalog-hero .section-title {
    font-family: var(--font-display);
    font-size: clamp(28px, 4vw, 42px);
    font-weight: 900;
    letter-spacing: 2px;
    margin-bottom: 8px;
    position: relative;
}
.catalog-hero .section-title i {
    color: var(--green);
    margin-right: 8px;
    filter: drop-shadow(0 0 8px rgba(0,255,65,0.4));
}
.catalog-hero .section-subtitle {
    color: var(--text-dim);
    font-size: 14px;
    margin-bottom: 0;
}

/* ── CATALOG STATS BAR ── */
.catalog-stats {
    display: flex;
    justify-content: center;
    gap: 32px;
    margin-top: 24px;
    flex-wrap: wrap;
}
.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}
.stat-val {
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 800;
    color: var(--green);
    letter-spacing: 1px;
}
.stat-val .fa-star {
    font-size: 14px;
    vertical-align: middle;
}
.stat-label {
    font-size: 11px;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* ── FILTER SECTION ── */

/* ── FILTER CONSISTENCY FIX ── */
.filter-form .filter-select,
.filter-form .search-input {
    height: 44px;
    box-sizing: border-box;
}
.filter-form .filter-btn-apply,
.filter-form 

.catalog-filters {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-dim);
    font-size: 13px;
    pointer-events: none;
}

.filter-btn-apply:focus-visible {
    outline: 2px solid var(--green);
    outline-offset: 2px;
}


.filter-btn-clear:focus-visible {
    outline: 2px solid var(--red);
    outline-offset: 2px;
}

/* ── ACTIVE FILTERS CHIPS ── */
.active-filters {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px 0;
    flex-wrap: wrap;
    max-width: 1400px;
    margin: 0 auto;
}
.active-filters-label {
    font-size: 12px;
    color: var(--text-dim);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}
.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    background: rgba(0,255,65,0.08);
    border: 1px solid rgba(0,255,65,0.2);
    border-radius: 20px;
    font-size: 12px;
    color: var(--green);
    animation: chipIn 0.3s ease;
}
.filter-chip i {
    font-size: 10px;
    opacity: 0.7;
}
.chip-remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: rgba(255,0,64,0.15);
    color: var(--red);
    font-size: 9px;
    text-decoration: none;
    transition: all 0.2s;
    margin-left: 2px;
}
.chip-remove:hover {
    background: var(--red);
    color: #fff;
    transform: scale(1.1);
}
.chip-remove:focus-visible {
    outline: 2px solid var(--red);
    outline-offset: 2px;
}
@keyframes chipIn {
    from { opacity: 0.3; transform: scale(0.8); }
    to { opacity: 1; transform: scale(1); }
}

/* ── RESULTS BAR ── */
.results-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 16px auto 0;
    padding: 0 20px;
}
.results-info {
    font-size: 13px;
    color: var(--text-dim);
}
.results-info strong {
    color: var(--text);
}
.results-filtered {
    color: var(--green);
    font-style: italic;
    font-size: 12px;
}
.view-toggle {
    display: flex;
    gap: 4px;
    background: rgba(0,0,0,0.2);
    padding: 3px;
    border-radius: 8px;
    border: 1px solid var(--border);
}
.view-btn {
    padding: 6px 10px;
    border-radius: 6px;
    color: var(--text-dim);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
}
.view-btn:hover {
    color: var(--text);
    background: rgba(255,255,255,0.05);
}
.view-btn.active {
    color: var(--green);
    background: rgba(0,255,65,0.1);
}
.view-btn:focus-visible {
    outline: 2px solid var(--green);
    outline-offset: 2px;
}

/* ── PRODUCT GRID ── */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    max-width: 1400px;
    margin: 20px auto 0;
    padding: 0 20px 40px;
}

/* ── PRODUCT CARD ── */
.product-card {
    background: linear-gradient(145deg, rgba(255,255,255,0.03), rgba(0,0,0,0.1));
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
    transition: transform 0.3s cubic-bezier(0.25,0.46,0.45,0.94), 
                box-shadow 0.3s ease, 
                border-color 0.3s ease;
    display: flex;
    flex-direction: column;
    opacity: 1;
    transform: translateY(20px);
}
.product-card.card-visible {
    opacity: 1;
    transform: translateY(0);
    transition: transform 0.5s cubic-bezier(0.25,0.46,0.45,0.94),
                box-shadow 0.3s ease,
                border-color 0.3s ease,
                opacity 0.5s ease;
}
.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0,0,0,0.3), 0 0 20px rgba(0,255,65,0.06);
    border-color: rgba(0,255,65,0.2);
}

/* ── Card Image ── */
.card-img {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: rgba(0,0,0,0.2);
    display: block;
    text-decoration: none;
    border-bottom: 1px solid var(--border);
}
.card-img .product-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.25,0.46,0.45,0.94), filter 0.3s;
}
.card-img .product-thumb.fallback-img {
    object-fit: contain;
    padding: 30px;
    opacity: 0.4;
    filter: grayscale(1) brightness(0.6);
}
.product-card:hover .product-thumb:not(.fallback-img) {
    transform: scale(1.06);
}
.discount-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--red);
    color: #fff;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.5px;
    z-index: 2;
    box-shadow: 0 2px 8px rgba(255,0,64,0.3);
}
.card-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 3;
}
.product-card:hover .card-overlay {
    opacity: 1;
}
.overlay-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.3);
    background: rgba(0,0,0,0.4);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.25s;
    text-decoration: none;
    padding: 0;
}
.overlay-btn:hover {
    transform: scale(1.15);
    border-color: var(--green);
    color: var(--green);
    background: rgba(0,255,65,0.15);
}
.overlay-btn:focus-visible {
    outline: 2px solid var(--green);
    outline-offset: 2px;
}
.btn-wishlist:hover {
    border-color: var(--red);
    color: var(--red);
    background: rgba(255,0,64,0.15);
}
.overlay-form {
    display: inline;
}

/* ── Card Body ── */
.card-body {
    padding: 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.card-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.card-category {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--cat-color, var(--green));
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: opacity 0.2s;
}
.card-category:hover {
    opacity: 0.7;
}
.card-category:focus-visible {
    outline: 2px solid var(--cat-color, var(--green));
    outline-offset: 2px;
    border-radius: 2px;
}
.difficulty-badge {
    font-size: 10px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 12px;
    background: color-mix(in srgb, var(--diff-color) 12%, transparent);
    color: var(--diff-color);
    border: 1px solid color-mix(in srgb, var(--diff-color) 25%, transparent);
    display: inline-flex;
    align-items: center;
    gap: 3px;
    white-space: nowrap;
}
.difficulty-badge i {
    font-size: 8px;
}
.card-title {
    font-size: 16px;
    font-weight: 700;
    line-height: 1.3;
    margin: 0;
}
.card-title a {
    color: var(--text);
    text-decoration: none;
    transition: color 0.2s;
}
.card-title a:hover {
    color: var(--green);
}
.card-title a:focus-visible {
    outline: 2px solid var(--green);
    outline-offset: 2px;
    border-radius: 2px;
}
.card-desc {
    font-size: 13px;
    color: var(--text-dim);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: 0;
    flex: 1;
}
.card-stats {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: auto;
}

/* ── Rating Stars ── */
.star-rating {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    font-size: 12px;
}
.star-rating .fas.fa-star,
.star-rating .fas.fa-star-half-alt {
    color: #ffc107;
}
.star-rating .far.fa-star {
    color: rgba(255,255,255,0.15);
}
.rating-val {
    font-size: 12px;
    color: var(--text-dim);
    margin-left: 4px;
    font-weight: 600;
}
.card-downloads {
    font-size: 12px;
    color: var(--text-dim);
    display: flex;
    align-items: center;
    gap: 4px;
}
.card-downloads i {
    font-size: 10px;
}

/* ── Card Footer ── */
.card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    border-top: 1px solid var(--border);
    background: rgba(0,0,0,0.1);
}
.card-price {
    display: flex;
    align-items: baseline;
    gap: 6px;
}
.price-original {
    font-size: 13px;
    color: var(--text-dim);
    text-decoration: line-through;
    opacity: 0.6;
}
.price-current {
    font-size: 18px;
    font-weight: 800;
    font-family: var(--font-display);
    color: var(--green);
    letter-spacing: 0.5px;
}
.card-cart-form {
    display: inline;
}
.btn-add-cart {
    padding: 8px 16px;
    background: linear-gradient(135deg, rgba(0,255,65,0.12), rgba(0,255,65,0.04));
    border: 1px solid rgba(0,255,65,0.25);
    border-radius: 8px;
    color: var(--green);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}
.btn-add-cart:hover {
    background: rgba(0,255,65,0.2);
    border-color: var(--green);
    box-shadow: 0 0 16px rgba(0,255,65,0.15);
    transform: translateY(-1px);
}
.btn-add-cart:active {
    transform: translateY(0);
}
.btn-add-cart:focus-visible {
    outline: 2px solid var(--green);
    outline-offset: 2px;
}

/* ── LIST VIEW ── */
.product-grid.list-view {
    grid-template-columns: 1fr;
    gap: 12px;
}
.product-grid.list-view .product-card {
    flex-direction: row;
    border-radius: 10px;
}
.product-grid.list-view .card-img {
    width: 220px;
    min-width: 220px;
    height: auto;
    min-height: 180px;
    border-bottom: none;
    border-right: 1px solid var(--border);
}
.product-grid.list-view .card-body {
    padding: 16px 20px;
}
.product-grid.list-view .card-desc {
    -webkit-line-clamp: 3;
}
.product-grid.list-view .card-footer {
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 10px;
    border-top: none;
    border-left: 1px solid var(--border);
    padding: 16px 20px;
    min-width: 150px;
}

/* ── EMPTY STATE ── */
.empty-state {
    text-align: center;
    padding: 80px 20px;
    max-width: 500px;
    margin: 0 auto;
}
.empty-icon {
    font-size: 64px;
    color: var(--text-dim);
    opacity: 0.3;
    margin-bottom: 16px;
    animation: floatGhost 3s ease-in-out infinite;
}
@keyframes floatGhost {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}
.empty-state h3 {
    font-size: 22px;
    margin-bottom: 8px;
    color: var(--text);
}
.empty-state p {
    color: var(--text-dim);
    margin-bottom: 24px;
}
.empty-suggestions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}
.btn-ghost {
    padding: 10px 20px;
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-dim);
    text-decoration: none;
    font-size: 13px;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.btn-ghost:hover {
    border-color: var(--green);
    color: var(--green);
    background: rgba(0,255,65,0.05);
}
.btn-ghost:focus-visible {
    outline: 2px solid var(--green);
    outline-offset: 2px;
}

/* ── PAGINATION ── */
.catalog-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    padding: 30px 20px 50px;
    flex-wrap: wrap;
}
.page-btn {
    min-width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: rgba(0,0,0,0.2);
    color: var(--text-dim);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
}
.page-btn:hover:not(.disabled):not(.active) {
    border-color: var(--green);
    color: var(--green);
    background: rgba(0,255,65,0.05);
    transform: translateY(-1px);
}
.page-btn.active {
    background: linear-gradient(135deg, rgba(0,255,65,0.2), rgba(0,255,65,0.08));
    border-color: var(--green);
    color: var(--green);
    box-shadow: 0 0 12px rgba(0,255,65,0.15);
    cursor: default;
}
.page-btn.disabled {
    opacity: 0.3;
    cursor: not-allowed;
}
.page-btn:focus-visible {
    outline: 2px solid var(--green);
    outline-offset: 2px;
}
.page-ellipsis {
    color: var(--text-dim);
    padding: 0 4px;
    font-size: 16px;
}
.page-info {
    font-size: 12px;
    color: var(--text-dim);
    margin-left: 12px;
}

/* ── QUICK VIEW OVERLAY ── */
.qv-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}
.qv-overlay.active {
    opacity: 1;
    pointer-events: all;
}
.qv-panel {
    background: var(--surface, #0d0d0d);
    border: 1px solid var(--border);
    border-radius: 16px;
    max-width: 600px;
    width: 92%;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
    transform: scale(0.9) translateY(20px);
    transition: transform 0.35s cubic-bezier(0.25,0.46,0.45,0.94);
    box-shadow: 0 24px 64px rgba(0,0,0,0.5);
}
.qv-overlay.active .qv-panel {
    transform: scale(1) translateY(0);
}
.qv-close {
    position: absolute;
    top: 12px;
    right: 16px;
    background: none;
    border: none;
    color: var(--text-dim);
    font-size: 28px;
    cursor: pointer;
    z-index: 2;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
    line-height: 1;
}
.qv-close:hover {
    color: var(--red);
    background: rgba(255,0,64,0.1);
}
.qv-close:focus-visible {
    outline: 2px solid var(--green);
    outline-offset: 2px;
}
.qv-content {
    padding: 24px;
}
.qv-header {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}
.qv-img-wrap {
    width: 140px;
    min-width: 140px;
    height: 140px;
    border-radius: 12px;
    overflow: hidden;
    background: rgba(0,0,0,0.3);
    border: 1px solid var(--border);
    flex-shrink: 0;
}
.qv-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.qv-info {
    flex: 1;
    min-width: 0;
}
.qv-meta {
    margin-bottom: 8px;
}
.qv-cat {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--cat-color, var(--green));
}
.qv-title {
    font-size: 22px;
    font-weight: 800;
    margin: 0 0 8px;
    line-height: 1.2;
}
.qv-desc {
    font-size: 13px;
    color: var(--text-dim);
    line-height: 1.6;
    margin: 0;
}
.qv-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    padding: 16px 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    margin-bottom: 20px;
}
.qv-stat-item {
    text-align: center;
}
.qv-stat-val {
    display: block;
    font-size: 18px;
    font-weight: 800;
    color: var(--green);
    font-family: var(--font-display);
}
.qv-stat-val .fa-star {
    font-size: 13px;
    color: #ffc107;
}
.qv-stat-label {
    display: block;
    font-size: 11px;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 2px;
}
.qv-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}
.qv-price {
    font-size: 26px;
    font-weight: 900;
    font-family: var(--font-display);
    color: var(--green);
}
.qv-actions {
    display: flex;
    gap: 8px;
}
.qv-btn {
    padding: 10px 18px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
}
.qv-btn-details {
    border: 1px solid var(--border);
    color: var(--text-dim);
}
.qv-btn-details:hover {
    border-color: var(--green);
    color: var(--green);
}
.qv-btn-cart {
    background: linear-gradient(135deg, rgba(0,255,65,0.15), rgba(0,255,65,0.05));
    border: 1px solid rgba(0,255,65,0.3);
    color: var(--green);
}
.qv-btn-cart:hover {
    background: rgba(0,255,65,0.25);
    border-color: var(--green);
    box-shadow: 0 0 16px rgba(0,255,65,0.15);
}
.qv-btn:focus-visible {
    outline: 2px solid var(--green);
    outline-offset: 2px;
}

/* ── BACK TO TOP ── */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(0,255,65,0.12);
    border: 1px solid rgba(0,255,65,0.3);
    color: var(--green);
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s;
    z-index: 100;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
.back-to-top.visible {
    opacity: 1;
    transform: translateY(0);
}
.back-to-top:hover {
    background: rgba(0,255,65,0.25);
    border-color: var(--green);
    box-shadow: 0 0 20px rgba(0,255,65,0.2);
    transform: translateY(-2px);
}
.back-to-top:focus-visible {
    outline: 2px solid var(--green);
    outline-offset: 2px;
}

/* ── FOCUS VISIBLE GLOBAL ── */
*:focus-visible {
    outline: 2px solid var(--green);
    outline-offset: 2px;
}

/* ── RESPONSIVE ── */
@media (max-width: 1024px) {
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    }
    .product-grid.list-view .card-img {
        width: 180px;
        min-width: 180px;
    }
}
@media (max-width: 768px) {
    
    
    
    
    .results-bar {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 14px;
        padding: 0 14px 30px;
    }
    .product-grid.list-view .product-card {
        flex-direction: column;
    }
    .product-grid.list-view .card-img {
        width: 100%;
        min-width: unset;
        height: 180px;
        border-right: none;
        border-bottom: 1px solid var(--border);
    }
    .product-grid.list-view .card-footer {
        flex-direction: row;
        border-left: none;
        border-top: 1px solid var(--border);
    }
    .catalog-stats {
        gap: 16px;
    }
    .qv-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .qv-meta {
        justify-content: center;
    }
    .qv-stats {
        grid-template-columns: 1fr;
    }
    .qv-footer {
        flex-direction: column;
        text-align: center;
    }
}
@media (max-width: 480px) {
    .product-grid {
        grid-template-columns: 1fr;
    }
    .catalog-hero {
        padding: 35px 16px 20px;
    }
    .catalog-pagination {
        gap: 4px;
    }
    .page-btn {
        min-width: 34px;
        height: 34px;
        font-size: 12px;
    }
    .page-info {
        display: block;
        width: 100%;
        text-align: center;
        margin-left: 0;
        margin-top: 8px;
    }
}


/* ── FALLBACK IMAGE ENHANCEMENT ── */
.card-img img.fallback-img {
    object-fit: contain;
    padding: 32px;
    opacity: 0.35;
    filter: grayscale(0.5) drop-shadow(0 0 12px rgba(0,255,65,0.1));
}
.card-img img:not(.fallback-img) {
    object-fit: contain;
    padding: 12px;
}

/* ── PRINT ── */
@media print {
    .catalog-filters,
    .active-filters,
    .results-bar,
    .card-overlay,
    .btn-add-cart,
    .card-cart-form,
    .catalog-pagination,
    .qv-overlay,
    .back-to-top,
    .flash-message {
        display: none !important;
    }
    .product-card {
        break-inside: avoid;
        border: 1px solid #ccc;
        opacity: 1 !important;
        transform: none !important;
    }
    .card-img {
        height: 120px;
    }
}

/* ── REDUCED MOTION ── */
@media (prefers-reduced-motion: reduce) {
    .product-card,
    .qv-panel,
    .qv-overlay,
    .back-to-top,
    .filter-chip,
    .empty-icon {
        animation: none !important;
        transition: none !important;
    }
    .product-card {
        opacity: 1;
        transform: none;
    }
    .product-card.card-visible {
        transition: none;
    }
}

/* ═══════════════════════════════════════════════════════════
   PROFESSIONAL ENHANCEMENTS — ZION v2
   ═══════════════════════════════════════════════════════════ */

/* ── FILTER ALIGNMENT FIX — equal proportions ── */

.filter-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: rgba(255,255,255,0.45);
    margin-bottom: 6px;
    display: block;
}
.filter-input,

.filter-btn-apply,
.filter-btn-reset {
    height: 42px;
    box-sizing: border-box;
}


/* ── TEXT CONTRAST IMPROVEMENTS ── */
.card-desc {
    color: rgba(255,255,255,0.65) !important;
    font-size: 13px !important;
    line-height: 1.55 !important;
    -webkit-line-clamp: 3 !important;
}
.card-name {
    font-family: 'Segoe UI', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif !important;
    font-weight: 700 !important;
    font-size: 15px !important;
    color: rgba(255,255,255,0.95) !important;
    letter-spacing: -0.01em !important;
    line-height: 1.35 !important;
}
.card-name:hover {
    color: var(--green) !important;
}

/* ── CATEGORY & LEVEL BADGES — more visible ── */
.card-cat {
    font-size: 11px !important;
    font-weight: 600 !important;
    letter-spacing: 0.6px !important;
    color: rgba(0,255,65,0.75) !important;
    text-transform: uppercase;
}
.card-difficulty {
    font-size: 10px !important;
    font-weight: 700 !important;
    letter-spacing: 0.8px !important;
    padding: 3px 10px !important;
    border-radius: 4px !important;
}
.diff-beginner {
    background: rgba(0,200,83,0.15) !important;
    color: #00c853 !important;
    border: 1px solid rgba(0,200,83,0.3) !important;
}
.diff-intermediate {
    background: rgba(255,193,7,0.12) !important;
    color: #ffc107 !important;
    border: 1px solid rgba(255,193,7,0.3) !important;
}
.diff-advanced {
    background: rgba(255,109,0,0.12) !important;
    color: #ff6d00 !important;
    border: 1px solid rgba(255,109,0,0.3) !important;
}
.diff-expert, .diff-elite {
    background: rgba(255,0,64,0.12) !important;
    color: #ff4081 !important;
    border: 1px solid rgba(255,0,64,0.3) !important;
}

/* ── CARD IMAGE AREA — better SVG display ── */
.card-img {
    height: 210px;
    background: linear-gradient(135deg, rgba(0,10,2,0.6), rgba(0,20,5,0.4));
    display: flex;
    align-items: center;
    justify-content: center;
}
.card-img .product-thumb {
    object-fit: contain;
    padding: 16px;
    width: 100%;
    height: 100%;
}
.card-img .product-thumb.fallback-img {
    padding: 40px;
    opacity: 0.3;
}

/* ── PRICE AREA — cleaner ── */
.card-price-row {
    padding: 10px 16px 14px !important;
    border-top: 1px solid rgba(255,255,255,0.05);
    background: rgba(0,0,0,0.15);
}
.price-current {
    font-size: 20px !important;
    font-weight: 800 !important;
    color: var(--green) !important;
}
.price-original {
    font-size: 13px !important;
    color: rgba(255,255,255,0.35) !important;
}

/* ── RATING STARS — warmer ── */
.card-rating .star-full {
    color: #ffb300 !important;
}
.card-rating .star-half {
    color: #ffb300 !important;
}
.card-rating .rating-value {
    color: rgba(255,255,255,0.7) !important;
    font-weight: 600;
}
.card-rating .rating-count {
    color: rgba(255,255,255,0.4) !important;
    font-size: 11px !important;
}

/* ── PRODUCT GRID — better spacing ── */
.product-grid {
    gap: 20px;
}
.product-card {
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,0.07);
    background: rgba(255,255,255,0.025);
    overflow: hidden;
}
.product-card:hover {
    border-color: rgba(0,255,65,0.15);
}

/* ── RESULTS BAR — polish ── */
.results-bar {
    padding: 12px 0 !important;
    color: rgba(255,255,255,0.6);
    font-size: 13px;
}

/* ── STATS SECTION — subtle improvement ── */
.catalog-stats .stat-val {
    font-variant-numeric: tabular-nums;
}

/* ── QUICK-VIEW MODAL — contrast fix ── */
.qv-desc {
    color: rgba(255,255,255,0.7) !important;
    line-height: 1.6 !important;
}

/* ── PAGINATION — cleaner ── */
.pagination a, .pagination span {
    border-radius: 8px !important;
    min-width: 38px;
    height: 38px;
    font-size: 13px;
}

/* ── RESPONSIVE TUNE-UP ── */
@media (max-width: 1024px) {
    
}
@media (max-width: 768px) {
    .card-img {
        height: 180px;
    }
    .card-name {
        font-size: 14px !important;
    }
}


/* ═══ VISIBLE FILTER LABELS ═══ */
.filter-label {
    display: block;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--green);
    margin-bottom: 6px;
    white-space: nowrap;
}

/* ═══ FILTER FORM — ALIGNED ═══ */
.filter-form {
    display: flex;
    gap: 14px;
    align-items: flex-end;
    flex-wrap: wrap;
    padding: 18px 22px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.15);
}
.filter-group {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 140px;
}
.filter-group:first-child {
    flex: 1.8;
    min-width: 200px;
}
.filter-actions {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    gap: 6px;
    min-width: auto;
}
.filter-actions .filter-label {
    visibility: hidden;
}
.filter-actions > div,
.filter-actions > span.filter-label ~ * {
    display: flex;
    gap: 8px;
}

/* ═══ INPUTS/SELECTS UNIFORM HEIGHT ═══ */
.filter-input,
.filter-select {
    height: 42px;
    padding: 0 14px;
    font-size: 0.88rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg-dark);
    color: var(--text-main);
    transition: border-color 0.2s, box-shadow 0.2s;
    width: 100%;
    box-sizing: border-box;
}
.filter-input:focus,
.filter-select:focus {
    border-color: var(--green);
    box-shadow: 0 0 0 3px rgba(0,255,136,0.12);
    outline: none;
}
.search-input-wrap {
    position: relative;
    width: 100%;
}
.search-input-wrap .search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 0.85rem;
    pointer-events: none;
}
.search-input-wrap .filter-input {
    padding-left: 36px;
}

/* ═══ FILTER BUTTONS ═══ */
.filter-btn-apply {
    height: 42px;
    padding: 0 20px;
    background: var(--green);
    color: var(--bg-dark);
    border: none;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
    white-space: nowrap;
}
.filter-btn-apply:hover {
    background: var(--green-hover, #00e67a);
    box-shadow: 0 2px 10px rgba(0,255,136,0.3);
    transform: translateY(-1px);
}
.filter-btn-clear {
    height: 42px;
    padding: 0 14px;
    background: transparent;
    color: var(--text-muted);
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: all 0.2s;
    text-decoration: none;
    white-space: nowrap;
}
.filter-btn-clear:hover {
    color: #ff5555;
    border-color: #ff5555;
}

/* ═══ FILTER RESPONSIVE ═══ */
@media (max-width: 768px) {
    .filter-form {
        flex-direction: column;
        gap: 12px;
    }
    .filter-group,
    .filter-group:first-child {
        flex: unset;
        min-width: 100%;
    }
    .filter-actions {
        flex-direction: row;
        width: 100%;
    }
    .filter-actions .filter-label {
        display: none;
    }
    .filter-btn-apply,
    .filter-btn-clear {
        flex: 1;
        justify-content: center;
    }
}

/* SVG OPACITY OVERRIDE */
.product-card,
.product-card.visible {
    opacity: 1 !important;
    visibility: visible !important;
}
.card-img img {
    opacity: 1 !important;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 12px;
    box-sizing: border-box;
}
.card-img {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0d1117 0%, #161b22 100%);
    overflow: hidden;
}
/* Card description clamp */
.card-body .card-desc,
.card-body p {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.5;
}

/* ═══ FINAL POLISH ═══ */

/* Better contrast for card descriptions */
.card-body .card-desc,
.card-body .card-description,
.product-card .card-body p:not(.card-price):not(.card-meta) {
    color: #cdd5e0 !important;
    font-size: 0.88rem;
    line-height: 1.55;
    letter-spacing: 0.01em;
}

/* Download icon styling */
.card-meta .fa-download {
    color: var(--green, #00ff41);
    font-size: 0.82em;
    margin-right: 4px;
}

/* Rating stars consistent size */
.card-rating .fas,
.card-rating .far {
    font-size: 0.82rem;
}
.rating-val {
    font-weight: 600;
    margin-left: 4px;
    color: #f0f0f0;
}

/* Price styling enhancement */
.card-price {
    font-weight: 700;
    font-size: 1.15rem;
    color: var(--green, #00ff41);
}

/* Badge consistency */
.badge-difficulty {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 3px 10px;
    border-radius: 4px;
}

/* Stats bar polish */
.stats-bar .stat-val {
    font-weight: 700;
    font-size: 1.3rem;
}
.stats-bar .stat-label {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #8b949e;
}

/* Filter form final alignment */
.filter-form {
    display: flex;
    gap: 14px;
    align-items: flex-end;
    flex-wrap: wrap;
}
.filter-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}
.filter-group:first-child {
    flex: 1;
    min-width: 220px;
}
.filter-label {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--green, #00ff41);
}

/* Card grid consistent gaps */
.product-grid {
    gap: 22px;
}

/* Smooth card entrance - ensure no flash of invisible */
.product-card {
    opacity: 0;
    transform: translateY(15px);
    transition: opacity 0.4s ease, transform 0.4s ease,
                box-shadow 0.3s ease, border-color 0.3s ease;
}
.product-card.card-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Pagination polish */
.pagination a,
.pagination span {
    min-width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    font-weight: 600;
}
