:root {
    --primary-blue: #2c3e7a;
    --accent-blue: #4a5f9d;
    --dark-navy: #1a2744;
    --gold: #d4af37;
    --light-gray: #f5f7fa;
    --medium-gray: #e1e8ed;
    --text-dark: #2d3748;
    --text-light: #718096;
    --white: #ffffff;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.15);
}

body.houston-catalog-template {
    margin: 0;
    font-family: 'Rund Text', 'Helvetica Neue', Arial, Helvetica, sans-serif;
    color: var(--text-dark);
    line-height: 1.5;
    overflow-x: hidden;
    font-size: 1em;
    font-weight: normal;
    background: var(--white);
}

body.houston-catalog-template * {
    box-sizing: border-box;
}

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

.header {
    background: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 0;
    gap: 2rem;
    min-height: 80px;
}

.logo-link {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    transition: opacity 0.3s;
}

.logo-link:hover {
    opacity: 0.9;
}

.logo-mark {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: var(--white);
    background: linear-gradient(135deg, var(--primary-blue), var(--dark-navy));
    font-weight: 800;
    flex: 0 0 auto;
}

.logo-image {
    height: 50px;
    width: auto;
    display: block;
    flex: 0 0 auto;
}

.logo-text h1 {
    font-size: 1.25rem;
    color: var(--primary-blue);
    font-weight: 700;
    letter-spacing: 0.5px;
    margin: 0;
    line-height: 1.2;
}

.tagline {
    font-size: 0.75rem;
    color: var(--text-light);
    font-style: italic;
    margin: 0;
    line-height: 1.2;
}

.nav {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav a {
    color: var(--text-dark);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.nav a:hover {
    color: var(--primary-blue);
}

body.houston-catalog-template .header .nav a,
body.houston-catalog-template header.header nav.nav a,
body.houston-catalog-template .header .nav a:visited,
body.houston-catalog-template header.header nav.nav a:visited,
body.houston-catalog-template .header .nav a:active {
    color: var(--text-dark) !important;
    text-decoration: none !important;
}

body.houston-catalog-template .header .nav a:hover,
body.houston-catalog-template header.header nav.nav a:hover,
body.houston-catalog-template .header .nav a:focus {
    color: var(--primary-blue) !important;
    text-decoration: none !important;
}

.cta-phone {
    background: var(--primary-blue);
    color: var(--white);
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: background 0.3s;
    white-space: nowrap;
}

.cta-phone:hover {
    background: var(--dark-navy);
    color: var(--white);
}

body.houston-catalog-template .header .cta-phone,
body.houston-catalog-template .header .cta-phone:visited,
body.houston-catalog-template .header .cta-phone:active {
    background: var(--primary-blue) !important;
    color: var(--white) !important;
    text-decoration: none !important;
}

body.houston-catalog-template .header .cta-phone:hover,
body.houston-catalog-template .header .cta-phone:focus {
    background: var(--dark-navy) !important;
    color: var(--white) !important;
    text-decoration: none !important;
}

body.houston-catalog-template .header .nav .nav-phone,
body.houston-catalog-template header.header nav.nav a.nav-phone,
body.houston-catalog-template .header .nav .nav-phone:visited,
body.houston-catalog-template header.header nav.nav a.nav-phone:visited,
body.houston-catalog-template .header .nav .nav-phone:active,
body.houston-catalog-template .header .nav .nav-phone:hover,
body.houston-catalog-template .header .nav .nav-phone:focus {
    color: var(--primary-blue) !important;
    text-decoration: none !important;
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--primary-blue);
    border-radius: 3px;
    transition: all 0.3s ease;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

.nav-phone {
    display: none;
}

.gallery-layout {
    grid-template-columns: minmax(0, 1fr) 500px;
}

.gallery-item {
    appearance: none;
    border: 0;
    padding: 0;
    text-align: left;
    font: inherit;
    color: inherit;
    content-visibility: auto;
    contain-intrinsic-size: 320px;
}

.gallery-item.hidden,
.letter-section.hidden {
    display: none;
}

.gallery-item-image {
    background: #ffffff;
}

.gallery-item-thumb {
    opacity: 0;
    transform: scale(0.985);
    transition: opacity 0.28s ease, transform 0.34s ease;
    will-change: opacity, transform;
}

.gallery-item-thumb.is-loaded {
    opacity: 1;
    transform: scale(1);
}

.gallery-empty {
    grid-column: 1 / -1;
    margin: 0;
    padding: 2rem;
    background: var(--white);
    color: var(--text-light);
}

.gallery-skeleton {
    position: relative;
    overflow: hidden;
    border-radius: 999px;
    background: linear-gradient(90deg, #eef2f6 0%, #f8fafc 50%, #eef2f6 100%);
    background-size: 220% 100%;
    animation: hbc-skeleton-shimmer 1.4s ease-in-out infinite;
}

.gallery-skeleton-card {
    display: flex;
    flex-direction: column;
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
}

.gallery-skeleton-card__image {
    aspect-ratio: 1;
    border-radius: 0;
}

.gallery-skeleton-card__label {
    padding: 0.65rem 0.75rem 0.75rem;
    border-top: 1px solid #e8ecf1;
    background: var(--white);
}

.gallery-skeleton-card__line {
    height: 10px;
    border-radius: 999px;
}

.gallery-skeleton-card__line + .gallery-skeleton-card__line {
    margin-top: 0.4rem;
}

.gallery-skeleton-card__line--title {
    width: 82%;
}

.gallery-skeleton-card__line--meta {
    width: 58%;
}

.btn {
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.2s ease;
}

.btn-primary {
    background: var(--primary-blue);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--dark-navy);
    color: var(--white);
}

.btn-secondary {
    background: var(--white);
    color: var(--primary-blue);
    border: 1px solid var(--primary-blue);
}

.btn-secondary:hover {
    background: var(--light-gray);
    color: var(--primary-blue);
}

@media (max-width: 768px) {
    .header-content {
        gap: 1rem;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .nav {
        position: fixed;
        top: 80px;
        left: 0;
        right: 0;
        background: var(--white);
        box-shadow: var(--shadow);
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 0.75rem 1.25rem;
        transform: translateY(-140%);
        transition: transform 0.25s ease;
        z-index: 999;
    }

    .nav.active {
        transform: translateY(0);
    }

    .nav a {
        padding: 0.8rem 0;
        border-bottom: 1px solid var(--medium-gray);
    }

    .cta-phone {
        display: none;
    }

    .nav-phone {
        display: block;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 14px;
    }

    .logo-mark {
        width: 42px;
        height: 42px;
        font-size: 0.85rem;
    }

    .logo-image {
        height: 42px;
    }

    .logo-text h1 {
        font-size: 1rem;
    }

    .tagline {
        font-size: 0.68rem;
    }
}

/* Gallery Split Layout */
.gallery-layout {
    display: grid;
    grid-template-columns: 1fr 500px;
    height: calc(100vh - 80px);
    position: relative;
}

/* Left Sidebar */
.gallery-sidebar {
    background: var(--white);
    border-right: 1px solid rgba(0, 0, 0, 0.08);
    overflow-y: auto;
    height: 100%;
    max-width: 100%;
}

.gallery-header {
    padding: 2rem 1.5rem 1rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    position: sticky;
    top: 0;
    background: var(--white);
    z-index: 10;
}

.gallery-header h1 {
    font-size: 1.75rem;
    color: var(--dark-navy);
    margin-bottom: 0.25rem;
}

.gallery-count {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* Filter Buttons */
.gallery-filters {
    display: flex;
    gap: 0.5rem;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    position: sticky;
    top: 90px;
    background: var(--white);
    z-index: 9;
    overflow-x: auto;
}

/* Alphabetical Navigation */
.alphabet-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    padding: 0.75rem 1.5rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    position: sticky;
    top: 145px;
    background: var(--white);
    z-index: 8;
    justify-content: center;
}

.alphabet-link {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--light-gray);
    color: var(--text-dark);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.alphabet-link:hover {
    background: var(--primary-blue);
    color: var(--white);
    transform: scale(1.1);
}

.alphabet-link.disabled {
    opacity: 0.35;
    cursor: not-allowed;
    pointer-events: none;
}

.alphabet-link.disabled:hover {
    background: var(--light-gray);
    color: var(--text-dark);
    transform: none;
}

.alphabet-link.active {
    background: var(--primary-blue);
    color: var(--white);
}

.filter-btn {
    padding: 0.5rem 1rem;
    border: 1px solid rgba(0, 0, 0, 0.15);
    background: var(--white);
    color: var(--text-dark);
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.filter-btn:hover {
    border-color: var(--primary-blue);
    color: var(--primary-blue);
}

.filter-btn.active {
    background: var(--primary-blue);
    color: var(--white);
    border-color: var(--primary-blue);
}

/* Product Grid */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1px;
    background: rgba(0, 0, 0, 0.06);
    padding: 0;
}

/* Mobile-optimized grid */
@media (max-width: 768px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    }
}

@media (max-width: 480px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
}

/* Hide alphabet scrubber on desktop */
.alphabet-scrubber {
    display: none;
}

@media (max-width: 768px) {
    .alphabet-scrubber {
        display: flex;
    }
}

/* Letter Section Headers */
.letter-section {
    grid-column: 1 / -1;
    background: var(--white);
    padding: 0;
    border-bottom: 2px solid var(--primary-blue);
}

.letter-header {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-blue);
    padding: 0.75rem 1.5rem;
    background: linear-gradient(to right, var(--light-gray) 0%, var(--white) 100%);
}

.gallery-item {
    background: var(--white);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    border-radius: 8px;
}

.gallery-item-image {
    aspect-ratio: 1;
    width: 100%;
    overflow: hidden;
    position: relative;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.gallery-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f5f7fa 0%, #e8ecf1 100%);
}

.gallery-placeholder svg {
    color: var(--primary-blue);
    opacity: 0.3;
}

.gallery-item-label {
    padding: 0.5rem 0.75rem;
    background: var(--white);
    border-top: 1px solid #e8ecf1;
    text-align: center;
}

.gallery-item-name {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--dark-navy);
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 2.6em;
}

.gallery-item:hover {
    box-shadow: 0 4px 12px rgba(44, 62, 122, 0.15);
}

.gallery-item:hover img {
    transform: scale(1.05);
}

.gallery-item.active {
    box-shadow: inset 0 0 0 3px var(--primary-blue), 0 4px 12px rgba(44, 62, 122, 0.12);
    z-index: 1;
}

.gallery-item.hidden {
    display: none;
}

/* Right Detail Panel */
.gallery-detail {
    background: var(--white);
    overflow-y: auto;
    height: 100%;
    border-left: 1px solid rgba(0, 0, 0, 0.08);
}

/* Hide close button on desktop */
.detail-close-btn {
    display: none;
}

.detail-content {
    max-width: 100%;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

.detail-image-container {
    background: #ffffff;
    border-radius: 0;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: none;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    transition: opacity 0.22s ease, transform 0.28s ease;
}

.detail-image-container img {
    max-width: 100%;
    max-height: 350px;
    object-fit: contain;
}

.detail-gallery-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin: -1rem 0 2rem;
    transition: opacity 0.22s ease, transform 0.28s ease;
}

.detail-gallery-thumb {
    appearance: none;
    border: 1px solid rgba(0, 0, 0, 0.12);
    background: var(--white);
    border-radius: 8px;
    padding: 0.35rem;
    width: 72px;
    height: 72px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.detail-gallery-thumb:hover {
    border-color: var(--primary-blue);
    box-shadow: 0 4px 12px rgba(44, 62, 122, 0.12);
}

.detail-gallery-thumb.active {
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 2px rgba(44, 62, 122, 0.15);
}

.detail-gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: 4px;
}

.detail-info {
    background: transparent;
    border-radius: 0;
    padding: 0;
    box-shadow: none;
    position: relative;
}

.detail-loading-shell {
    display: grid;
    gap: 0.85rem;
    margin-bottom: 0.5rem;
    position: absolute;
    inset: 0;
    align-content: start;
    z-index: 2;
    pointer-events: none;
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 0.22s ease, transform 0.28s ease;
}

.detail-loading-shell[hidden] {
    display: none !important;
}

.detail-loading-shell__badge {
    width: 92px;
    height: 30px;
}

.detail-loading-shell__title {
    width: 72%;
    height: 34px;
    border-radius: 10px;
}

.detail-loading-shell__section-title {
    width: 132px;
    height: 18px;
    margin-top: 0.45rem;
}

.detail-loading-shell__line {
    height: 13px;
    border-radius: 999px;
}

.detail-loading-shell__line--wide {
    width: 100%;
}

.detail-loading-shell__line--medium {
    width: 84%;
}

.detail-loading-shell__line--short {
    width: 56%;
}

.gallery-detail.is-loading .detail-loading-shell:not([hidden]) {
    display: grid !important;
    opacity: 1;
    transform: translateY(0);
}

.detail-badge,
.detail-info h2,
.detail-metal,
.detail-location,
.detail-meta-row,
.detail-description,
.detail-facts,
.detail-features,
.detail-guarantee,
.detail-actions {
    transition: opacity 0.22s ease, transform 0.28s ease;
}

.gallery-detail.is-loading .detail-image-container,
.gallery-detail.is-loading .detail-gallery-strip,
.gallery-detail.is-loading .detail-badge,
.gallery-detail.is-loading #detailTitle,
.gallery-detail.is-loading #detailMetal,
.gallery-detail.is-loading #detailLocation,
.gallery-detail.is-loading #detailMetaRow,
.gallery-detail.is-loading .detail-description,
.gallery-detail.is-loading #detailFacts,
.gallery-detail.is-loading #detailFeaturesFallback,
.gallery-detail.is-loading .detail-guarantee,
.gallery-detail.is-loading .detail-actions {
    opacity: 0.22;
    transform: translateY(4px);
}

.gallery-detail.is-loading #detailBadge,
.gallery-detail.is-loading #detailTitle,
.gallery-detail.is-loading #detailMetal,
.gallery-detail.is-loading #detailLocation,
.gallery-detail.is-loading #detailMetaRow,
.gallery-detail.is-loading .detail-description,
.gallery-detail.is-loading #detailFacts,
.gallery-detail.is-loading #detailFeaturesFallback,
.gallery-detail.is-loading .detail-guarantee,
.gallery-detail.is-loading .detail-actions {
    pointer-events: none;
}

.detail-badge {
    display: inline-block;
    padding: 0.4rem 1rem;
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--accent-blue) 100%);
    color: var(--white);
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 1rem;
}

.detail-info h2 {
    font-size: 1.5rem;
    color: var(--dark-navy);
    margin-bottom: 0.5rem;
    line-height: 1.2;
}

.detail-metal {
    font-size: 1rem;
    color: var(--gold);
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.detail-location {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.detail-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: -0.5rem 0 1.5rem;
}

.detail-meta-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    background: rgba(44, 62, 122, 0.08);
    color: var(--primary-blue);
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.detail-description {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.detail-description h3 {
    font-size: 1rem;
    color: var(--dark-navy);
    margin-bottom: 0.5rem;
}

.detail-description p {
    color: var(--text-dark);
    line-height: 1.6;
    font-size: 0.95rem;
}

.detail-features {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.detail-facts {
    display: grid;
    gap: 0.65rem;
    margin-bottom: 1.5rem;
}

.detail-fact-row {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 0.85rem;
    align-items: start;
    padding-bottom: 0.65rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.detail-fact-label {
    color: var(--text-light);
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.detail-fact-value {
    color: var(--text-dark);
    font-size: 0.9rem;
    line-height: 1.45;
}

.detail-features h3 {
    font-size: 1rem;
    color: var(--dark-navy);
    margin-bottom: 0.75rem;
}

.detail-features ul {
    list-style: none;
    padding: 0;
}

.detail-features li {
    color: var(--text-dark);
    line-height: 1.6;
    padding-left: 1.5rem;
    position: relative;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.detail-features li:before {
    content: "\2713";
    position: absolute;
    left: 0;
    color: var(--primary-blue);
    font-weight: bold;
}

@keyframes hbc-skeleton-shimmer {
    0% {
        background-position: 100% 0;
    }
    100% {
        background-position: -100% 0;
    }
}

.detail-guarantee {
    display: flex;
    gap: 0.75rem;
    padding: 1rem;
    background: var(--light-gray);
    border-radius: 0;
    margin-bottom: 1.5rem;
    border-left: 3px solid var(--gold);
}

.detail-guarantee svg {
    color: var(--gold);
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}

.detail-guarantee strong {
    display: block;
    color: var(--dark-navy);
    margin-bottom: 0.25rem;
    font-size: 0.95rem;
}

.detail-guarantee p {
    color: var(--text-dark);
    font-size: 0.85rem;
    margin: 0;
}

.detail-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.detail-actions .btn {
    flex: 1;
    min-width: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.25rem;
    font-size: 0.95rem;
}

.detail-actions .btn,
.detail-actions .btn:visited,
.detail-actions .btn.btn-primary,
.detail-actions .btn.btn-primary:visited,
.detail-actions .btn.btn-secondary,
.detail-actions .btn.btn-secondary:visited {
    background: #ffd400;
    border: 1px solid #ffd400;
    color: #1a1a1a !important;
    text-decoration: none;
}

.detail-actions .btn:hover,
.detail-actions .btn:focus,
.detail-actions .btn.btn-primary:hover,
.detail-actions .btn.btn-primary:focus,
.detail-actions .btn.btn-secondary:hover,
.detail-actions .btn.btn-secondary:focus {
    background: #e6bf00;
    border-color: #e6bf00;
    color: #111111 !important;
    box-shadow: 0 8px 22px rgba(230, 191, 0, 0.28);
}

.detail-actions svg {
    width: 18px;
    height: 18px;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .gallery-layout {
        grid-template-columns: 380px 1fr;
    }

    .gallery-header {
        padding: 1.5rem 1rem 0.75rem;
    }

    .gallery-header h1 {
        font-size: 1.5rem;
    }

    .gallery-filters {
        padding: 0.75rem 1rem;
        top: 75px;
    }

    .detail-content {
        padding: 2rem 1.5rem;
    }

    .detail-image-container {
        padding: 2rem;
        min-height: 300px;
    }

    .detail-info {
        padding: 2rem;
    }

    .detail-info h2 {
        font-size: 1.75rem;
    }

}

@media (max-width: 768px) {
    .gallery-layout {
        grid-template-columns: 1fr;
        height: auto;
        display: block;
    }

    .gallery-sidebar {
        height: auto;
        border-right: none;
        border-bottom: none;
        min-height: 100vh;
    }

    .gallery-header {
        position: static;
        padding: 1.5rem 1rem 0.75rem;
    }

    .gallery-filters {
        position: static;
        padding: 0.75rem 1rem;
        top: auto;
    }

    .alphabet-nav {
        position: static;
        top: auto;
        padding: 0.75rem 1rem;
        display: none;
        /* Hide horizontal nav on mobile */
    }

    /* Vertical A-Z scrubber for mobile */
    .alphabet-scrubber {
        display: flex !important;
        position: fixed;
        right: 0;
        top: 50%;
        transform: translateY(-50%);
        flex-direction: column;
        gap: 2px;
        padding: 0.5rem 0.25rem;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(10px);
        border-radius: 12px 0 0 12px;
        box-shadow: -2px 0 8px rgba(0, 0, 0, 0.1);
        z-index: 100;
        max-height: 80vh;
        overflow-y: auto;
    }

    .alphabet-scrubber::-webkit-scrollbar {
        display: none;
    }

    .alphabet-scrubber .alphabet-link {
        width: 24px;
        height: 20px;
        font-size: 0.7rem;
        padding: 0;
        background: transparent;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-weight: 600;
        color: var(--primary-blue);
        transition: all 0.15s ease;
        flex-shrink: 0;
    }

    .alphabet-scrubber .alphabet-link:hover,
    .alphabet-scrubber .alphabet-link.active {
        background: var(--primary-blue);
        color: var(--white);
        transform: scale(1.2);
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        max-height: none;
        overflow-y: visible;
        gap: 0.5rem;
        padding-bottom: 1rem;
    }

    .gallery-item-label {
        padding: 0.4rem 0.5rem;
    }

    .gallery-item-name {
        font-size: 0.7rem;
        min-height: 2.4em;
    }

    /* Modal overlay for detail panel on mobile */
    .gallery-detail {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        height: 100vh;
        z-index: 1000;
        background: var(--white);
        overflow-y: auto;
        transform: translateY(100%);
        transition: transform 0.3s ease;
        display: none;
    }

    .gallery-detail.active {
        display: block;
        transform: translateY(0);
    }

    .detail-close-btn {
        position: sticky;
        top: 0;
        left: 0;
        right: 0;
        background: var(--white);
        border-bottom: 1px solid rgba(0, 0, 0, 0.1);
        padding: 1rem;
        display: flex;
        align-items: center;
        justify-content: space-between;
        z-index: 10;
    }

    .detail-close-btn button {
        background: var(--light-gray);
        border: none;
        width: 36px;
        height: 36px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        font-size: 1.5rem;
        color: var(--text-dark);
        transition: all 0.2s ease;
    }

    .detail-close-btn button:hover {
        background: var(--primary-blue);
        color: var(--white);
    }

    .detail-close-btn h3 {
        font-size: 1rem;
        color: var(--text-light);
        margin: 0;
    }

    .detail-content {
        padding: 1rem;
    }

    .detail-image-container {
        padding: 1.5rem;
        min-height: 250px;
    }

    .detail-gallery-strip {
        margin: -0.5rem 0 1.5rem;
    }

    .detail-info {
        padding: 1.5rem 1rem;
    }

    .detail-info h2 {
        font-size: 1.5rem;
    }

    .detail-fact-row {
        grid-template-columns: 1fr;
        gap: 0.35rem;
    }

    .detail-actions {
        flex-direction: column;
    }

    .detail-actions .btn {
        width: 100%;
        min-width: auto;
    }
}

@media (max-width: 480px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.5rem;
    }

    .gallery-header h1 {
        font-size: 1.25rem;
    }

    .filter-btn {
        font-size: 0.85rem;
        padding: 0.4rem 0.85rem;
    }

    .gallery-item-label {
        padding: 0.35rem 0.4rem;
    }

    .gallery-item-name {
        font-size: 0.65rem;
        min-height: 2.2em;
        line-height: 1.2;
    }

    .alphabet-nav {
        padding: 0.5rem;
        gap: 0.25rem;
    }

    .alphabet-link {
        width: 28px;
        height: 28px;
        font-size: 0.75rem;
    }

    .letter-header {
        font-size: 1.25rem;
        padding: 0.75rem 0.5rem 0.5rem;
    }

    .detail-content {
        padding: 1.5rem 1rem;
    }

    .detail-image-container {
        padding: 1rem;
        min-height: 200px;
    }

    .detail-info {
        padding: 1rem;
    }

    .detail-info h2 {
        font-size: 1.25rem;
    }
}
