/* Factory Visit gallery. Images are published through the existing content manager. */
.huzaro-factory-page .huzaro-factory-hero {
    background-position: center 48%;
}

.huzaro-factory-gallery-section {
    padding: 8rem 0 9rem;
    background: #fcfaf7;
}

.huzaro-factory-intro {
    max-width: 72rem;
    margin: 0 auto 5rem;
    text-align: center;
}

.huzaro-factory-intro h2 {
    margin: 1rem 0 1.6rem;
    color: #28211c;
    font-size: clamp(3rem, 4vw, 4.2rem);
    line-height: 1.2;
}

.huzaro-factory-intro p {
    margin: 0;
    color: #6d6258;
    font-size: 1.5rem;
    line-height: 1.85;
}

.huzaro-factory-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2rem;
}

.huzaro-factory-card {
    position: relative;
    min-width: 0;
    margin: 0;
    min-height: 24rem;
    overflow: hidden;
    border-radius: 1rem;
    background: #e9dfd4;
    aspect-ratio: 16 / 10;
    box-shadow: 0 .8rem 2.5rem rgba(51, 32, 20, .08);
}

.huzaro-factory-photo-link {
    position: absolute;
    inset: 0;
    display: block;
    overflow: hidden;
}

.huzaro-factory-photo-link::after {
    position: absolute;
    inset: 25% 0 0;
    content: '';
    background: linear-gradient(transparent 30%, rgba(24, 15, 10, .68));
    pointer-events: none;
}

.huzaro-factory-photo-link img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .35s ease;
}

.huzaro-factory-card:hover img,
.huzaro-factory-card:focus-within img {
    transform: scale(1.045);
}

.huzaro-factory-photo-link:focus-visible {
    outline: .3rem solid #d6a973;
    outline-offset: -.4rem;
}

.huzaro-factory-zoom {
    position: absolute;
    top: 1.7rem;
    right: 1.7rem;
    z-index: 1;
    display: grid;
    place-items: center;
    width: 4.2rem;
    height: 4.2rem;
    border: 1px solid rgba(255, 255, 255, .8);
    border-radius: 50%;
    color: #fff;
    background: rgba(30, 21, 16, .35);
    font-size: 1.5rem;
    transition: background .2s ease;
}

.huzaro-factory-card:hover .huzaro-factory-zoom,
.huzaro-factory-card:focus-within .huzaro-factory-zoom {
    background: #704321;
}

.huzaro-factory-card figcaption {
    position: absolute;
    right: 1.7rem;
    bottom: 1.7rem;
    left: 1.7rem;
    z-index: 1;
    color: #fff;
    pointer-events: none;
    text-shadow: 0 1px 8px #180f0a88;
}

.huzaro-factory-card figcaption strong,
.huzaro-factory-card figcaption span {
    display: block;
    overflow-wrap: anywhere;
}

.huzaro-factory-card figcaption strong {
    font-size: 1.75rem;
    line-height: 1.35;
}

.huzaro-factory-card figcaption span {
    margin-top: .25rem;
    color: #f0dbc7;
    font-size: 1.25rem;
}

.huzaro-factory-empty {
    max-width: 74rem;
    margin: 0 auto;
    padding: 7rem 3rem;
    border: 1px solid #e6d8c8;
    border-radius: 1rem;
    background: #fff;
    text-align: center;
}

.huzaro-factory-empty-icon {
    display: grid;
    place-items: center;
    width: 6rem;
    height: 6rem;
    margin: 0 auto 2rem;
    border-radius: 50%;
    color: #704321;
    background: #f4e8da;
    font-size: 2.5rem;
}

.huzaro-factory-empty h3 {
    margin: 0 0 1.3rem;
    font-size: 2.5rem;
}

.huzaro-factory-empty p {
    max-width: 51rem;
    margin: 0 auto 2.5rem;
    color: #6d6258;
    line-height: 1.8;
}

.huzaro-factory-inquiry {
    padding: 6rem 0;
    background: #2c2019;
    color: #f8eee4;
}

.huzaro-factory-inquiry-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 3rem;
}

.huzaro-factory-inquiry h2 {
    margin: .8rem 0 1rem;
    color: #fff;
    font-size: clamp(2.8rem, 3.4vw, 3.8rem);
    line-height: 1.2;
}

.huzaro-factory-inquiry p {
    margin: 0;
    color: #d8c6b5;
    font-size: 1.45rem;
}

.huzaro-factory-inquiry .btn {
    flex: 0 0 auto;
}

.huzaro-factory-dialog {
    width: min(110rem, calc(100vw - 4rem));
    max-width: none;
    max-height: calc(100dvh - 4rem);
    margin: auto;
    padding: 1.5rem;
    overflow: auto;
    border: 0;
    border-radius: .8rem;
    background: #201711;
    color: #fff;
    box-shadow: 0 2rem 8rem #0008;
}

.huzaro-factory-dialog::backdrop {
    background: rgba(13, 9, 7, .86);
}

.huzaro-factory-dialog-inner {
    position: relative;
}

.huzaro-factory-dialog img {
    display: block;
    max-width: 100%;
    max-height: calc(100dvh - 14rem);
    margin: 0 auto;
    object-fit: contain;
}

.huzaro-factory-dialog-close,
.huzaro-factory-dialog-footer button {
    display: grid;
    place-items: center;
    width: 4.4rem;
    height: 4.4rem;
    border: 1px solid #84674d;
    border-radius: 50%;
    color: #fff;
    background: #4c3323;
    cursor: pointer;
}

.huzaro-factory-dialog-close {
    position: absolute;
    top: .8rem;
    right: .8rem;
    z-index: 2;
}

.huzaro-factory-dialog button:hover,
.huzaro-factory-dialog button:focus-visible {
    background: #86552e;
    outline: 2px solid #e5b580;
}

.huzaro-factory-dialog-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    min-height: 7rem;
    padding: 1rem;
    text-align: center;
}

.huzaro-factory-dialog-footer p {
    min-width: 0;
    margin: 0;
    overflow-wrap: anywhere;
}

.huzaro-factory-dialog-footer strong,
.huzaro-factory-dialog-footer span {
    display: block;
}

.huzaro-factory-dialog-footer span {
    color: #ddc5ad;
    font-size: 1.25rem;
}

.huzaro-factory-dialog [hidden] {
    display: none !important;
}

body.huzaro-factory-dialog-open {
    overflow: hidden;
}

html[data-theme=dark] .huzaro-factory-gallery-section {
    background: #211d1a;
}

html[data-theme=dark] .huzaro-factory-intro h2,
html[data-theme=dark] .huzaro-factory-empty h3 {
    color: #f2e8dc;
}

html[data-theme=dark] .huzaro-factory-intro p,
html[data-theme=dark] .huzaro-factory-empty p {
    color: #c7b8aa;
}

html[data-theme=dark] .huzaro-factory-empty {
    border-color: #534135;
    background: #29231f;
}

@media (max-width: 991px) {
    .huzaro-factory-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .huzaro-factory-gallery-section {
        padding: 5.5rem 0 7rem;
    }

    .huzaro-factory-intro {
        margin-bottom: 3.5rem;
    }

    .huzaro-factory-inquiry-inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .huzaro-factory-inquiry .btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 575px) {
    .huzaro-factory-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 1.5rem;
    }

    .huzaro-factory-card {
        aspect-ratio: 16 / 11;
    }

    .huzaro-factory-empty {
        padding: 4rem 2rem;
    }

    .huzaro-factory-dialog {
        width: calc(100vw - 2rem);
        max-height: calc(100dvh - 2rem);
        padding: .8rem;
    }

    .huzaro-factory-dialog img {
        max-height: calc(100dvh - 13rem);
    }

    .huzaro-factory-dialog-footer {
        gap: .6rem;
    }

    .huzaro-factory-dialog-footer button {
        width: 3.8rem;
        height: 3.8rem;
        flex: 0 0 3.8rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .huzaro-factory-photo-link img,
    .huzaro-factory-zoom {
        transition: none;
    }
}
