/* =========================================
   STRANICE KATALOGA VRATA
========================================= */

.catalog-page {
    background-color: #ffffff;
}

.catalog-page.farbana-page {
    --catalog-hero-image: url("../images/farbana.png");
}

.catalog-page.craftmaster-page {
    --catalog-hero-image: url("../images/craftmaster.png");
}
.catalog-page.cpl-page {
    --catalog-hero-image: url("../images/cpl.png");
}


/* =========================================
   AKTIVNO „SOBNA VRATA“ U NAVBARU
========================================= */

.catalog-page .nav-dropdown-toggle.active {
    position: relative;
    color: #6e4723;
}


/* Linija ispod „Sobna vrata“ na računaru */

@media (min-width: 981px) {

    .catalog-page .nav-dropdown-toggle.active::after {
        content: "";

        position: absolute;
        left: 0;
        right: 0;
        bottom: -13px;

        height: 2px;

        background-color: #6e4723;
    }

}


/* Aktivna stranica unutar dropdown menija */

.catalog-page .nav-dropdown-menu a[aria-current="page"] {
    color: #6e4723;
    background-color: #f4eee8;
}


/* =========================================
   UVOD STRANICE — FARBANA VRATA
========================================= */

.catalog-hero {
    min-height: 540px;
    padding: 72px 0 76px;

    display: flex;
    align-items: center;

    background-color: #f6f1ec;

    /*
        Prvi sloj je prelaz preko slike.
        Drugi sloj je sama slika farbana.png.
    */

    background-image:
        linear-gradient(
            90deg,
            #f6f1ec 0%,
            rgba(246, 241, 236, 0.99) 27%,
            rgba(246, 241, 236, 0.94) 38%,
            rgba(246, 241, 236, 0.73) 48%,
            rgba(246, 241, 236, 0.34) 57%,
            rgba(246, 241, 236, 0.08) 65%,
            rgba(246, 241, 236, 0) 72%
        ),
        var(--catalog-hero-image);

    background-repeat:
        no-repeat,
        no-repeat;

    /*
        Slika se prilagođava visini sekcije.
        Tako se vrata vide cela po visini.
    */

    background-size:
        100% 100%,
        auto 100%;

    background-position:
        left top,
        right center;

    border-bottom: 1px solid rgba(102, 66, 31, 0.12);
}


/* =========================================
   SADRŽAJ UVODNOG DELA
========================================= */

.catalog-hero-container {
    width: 90%;
    max-width: 1480px;
    margin: 0 auto;
}


.catalog-hero-content {
    max-width: 650px;
}


/* =========================================
   MALA OZNAKA IZNAD NASLOVA
========================================= */

.catalog-label {
    margin: 0 0 16px;

    color: #7a5129;

    font-size: 13px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 2px;
    text-transform: uppercase;
}


/* =========================================
   GLAVNI NASLOV
========================================= */

.catalog-hero h1 {
    margin: 0 0 28px;

    color: #25170d;

    font-size: 64px;
    font-weight: 700;
    line-height: 1.04;
    letter-spacing: -1.5px;
}


/* =========================================
   OPIS
========================================= */

.catalog-description {
    max-width: 620px;
    margin: 0 0 36px;

    color: #493d35;

    font-size: 17px;
    line-height: 1.85;
}


/* =========================================
   DUGMAD ZA KATEGORIJE
========================================= */

.catalog-category-links {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}


.catalog-category-link {
    min-width: 175px;
    min-height: 52px;
    padding: 0 23px;

    display: inline-flex;
    justify-content: center;
    align-items: center;

    background-color: rgba(255, 255, 255, 0.88);
    color: #6e4723;

    border: 1px solid #81532b;
    border-radius: 4px;

    text-decoration: none;
    text-transform: uppercase;

    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.4px;

    transition:
        background-color 0.2s ease,
        color 0.2s ease,
        border-color 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}


.catalog-category-link:hover {
    background-color: #6e4723;
    color: #ffffff;
    border-color: #6e4723;

    transform: translateY(-2px);

    box-shadow: 0 8px 18px rgba(37, 23, 13, 0.12);
}


/* Trenutno otvorena kategorija */

.catalog-category-link.active {
    background-color: #6e4723;
    color: #ffffff;
    border-color: #6e4723;
}


/* =========================================
   MANJI LAPTOP
========================================= */

@media (max-width: 1250px) {

    .catalog-hero {
        min-height: 500px;
        padding: 66px 0 70px;

        background-image:
            linear-gradient(
                90deg,
                #f6f1ec 0%,
                rgba(246, 241, 236, 0.99) 32%,
                rgba(246, 241, 236, 0.94) 43%,
                rgba(246, 241, 236, 0.68) 54%,
                rgba(246, 241, 236, 0.25) 65%,
                rgba(246, 241, 236, 0.04) 76%,
                rgba(246, 241, 236, 0) 84%
            ),
            var(--catalog-hero-image);

        background-size:
            100% 100%,
            auto 100%;

        background-position:
            left top,
            right center;
    }


    .catalog-hero-content {
        max-width: 580px;
    }


    .catalog-hero h1 {
        font-size: 58px;
    }


    .catalog-description {
        max-width: 570px;
        font-size: 16px;
    }


    .catalog-category-link {
        min-width: 160px;
    }

}


/* =========================================
   TABLET I MOBILNI NAVBAR
========================================= */

@media (max-width: 980px) {

    .catalog-page .nav-dropdown-toggle.active {
        color: #6e4723;
        background-color: #f6f1ec;
    }


    .catalog-page .nav-dropdown-toggle.active::after {
        display: none;
    }


    .catalog-hero {
        min-height: 470px;
        padding: 60px 0 64px;

        background-image:
            linear-gradient(
                90deg,
                #f6f1ec 0%,
                rgba(246, 241, 236, 0.99) 42%,
                rgba(246, 241, 236, 0.94) 54%,
                rgba(246, 241, 236, 0.68) 68%,
                rgba(246, 241, 236, 0.20) 86%,
                rgba(246, 241, 236, 0) 100%
            ),
            var(--catalog-hero-image);

        background-size:
            100% 100%,
            auto 100%;

        background-position:
            left top,
            right center;
    }


    .catalog-hero-content {
        max-width: 500px;
    }


    .catalog-hero h1 {
        font-size: 50px;
        letter-spacing: -1px;
    }


    .catalog-description {
        max-width: 500px;

        font-size: 16px;
        line-height: 1.75;
    }


    .catalog-category-link {
        min-width: 145px;
        padding: 0 18px;

        font-size: 12px;
    }

}


/* =========================================
   MANJI TABLET
========================================= */

@media (max-width: 760px) {

    .catalog-hero {
        min-height: auto;
        padding: 55px 0 60px;

        background-image:
            linear-gradient(
                90deg,
                rgba(246, 241, 236, 0.99) 0%,
                rgba(246, 241, 236, 0.98) 56%,
                rgba(246, 241, 236, 0.88) 74%,
                rgba(246, 241, 236, 0.60) 100%
            ),
            var(--catalog-hero-image);

        background-size:
            100% 100%,
            auto 88%;

        background-position:
            left top,
            right bottom;
    }


    .catalog-hero-content {
        max-width: 100%;
    }


    .catalog-hero h1 {
        font-size: 44px;
    }


    .catalog-description {
        max-width: 100%;

        font-size: 15px;
        line-height: 1.7;
    }

}


/* =========================================
   TELEFON
========================================= */

@media (max-width: 600px) {

    .catalog-hero {
        padding: 50px 0 55px;

        /*
            Na telefonu je prelaz jači da tekst ostane čitljiv,
            ali se vrata i dalje diskretno vide desno.
        */

        background-image:
            linear-gradient(
                90deg,
                rgba(246, 241, 236, 0.98) 0%,
                rgba(246, 241, 236, 0.97) 68%,
                rgba(246, 241, 236, 0.82) 100%
            ),
            var(--catalog-hero-image);

        background-size:
            100% 100%,
            auto 70%;

        background-position:
            left top,
            right bottom 15px;
    }


    .catalog-hero-container {
        width: 91%;
    }


    .catalog-label {
        margin-bottom: 12px;

        font-size: 11px;
        letter-spacing: 1.7px;
    }


    .catalog-hero h1 {
        margin-bottom: 20px;

        font-size: 39px;
        line-height: 1.06;
        letter-spacing: -0.7px;
    }


    .catalog-description {
        margin-bottom: 28px;

        font-size: 15px;
        line-height: 1.65;
    }


    .catalog-category-links {
        flex-direction: column;
        gap: 10px;
    }


    .catalog-category-link {
        width: 100%;
        min-width: 0;
        min-height: 50px;
    }

}


/* =========================================
   VEOMA MALI TELEFONI
========================================= */

@media (max-width: 390px) {

    .catalog-hero {
        padding: 44px 0 48px;

        background-size:
            100% 100%,
            auto 58%;
    }


    .catalog-hero h1 {
        font-size: 35px;
    }


    .catalog-description {
        font-size: 14px;
    }


    .catalog-category-link {
        min-height: 48px;
        font-size: 11px;
    }

}
/* =========================================
   SEKCIJA SA MODELIMA VRATA
========================================= */

.door-models-section {
    padding: 85px 0 95px;
    background-color: #ffffff;
}


/* NASLOV SEKCIJE */

.door-models-heading {
    max-width: 720px;
    margin: 0 auto 45px;
    text-align: center;
}

.door-models-label {
    margin: 0 0 12px;

    color: #7a5129;

    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1.8px;
    text-transform: uppercase;
}

.door-models-heading h2 {
    margin: 0 0 16px;

    color: #25170d;

    font-size: 42px;
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.7px;
}

.door-models-description {
    margin: 0;

    color: #5a4c42;

    font-size: 16px;
    line-height: 1.7;
}


/* =========================================
   RASPORED KARTICA
========================================= */

.door-models-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 30px;
}


/* =========================================
   KARTICA MODELA
========================================= */

.door-model-card {
    overflow: hidden;

    display: flex;
    flex-direction: column;

    background-color: #ffffff;

    border: 1px solid rgba(102, 66, 31, 0.14);
    border-radius: 8px;

    box-shadow: 0 8px 25px rgba(37, 23, 13, 0.07);

    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease,
        border-color 0.25s ease;
}

.door-model-card:hover {
    transform: translateY(-6px);

    border-color: rgba(102, 66, 31, 0.25);

    box-shadow: 0 16px 38px rgba(37, 23, 13, 0.12);
}


/* =========================================
   SLIKA MODELA
========================================= */

.door-model-image {
    position: relative;
    overflow: hidden;

    display: block;

    aspect-ratio: 4 / 5;

    background-color: #f4efea;
}

.door-model-image img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: cover;
    object-position: center;

    transition: transform 0.4s ease;
}

.door-model-card:hover .door-model-image img {
    transform: scale(1.035);
}


/* Blagi prelaz pri dnu slike */

.door-model-image::after {
    content: "";

    position: absolute;
    inset: 0;

    background: linear-gradient(
        to bottom,
        rgba(30, 18, 9, 0) 68%,
        rgba(30, 18, 9, 0.13) 100%
    );

    pointer-events: none;
}


/* =========================================
   TEKST KARTICE
========================================= */

.door-model-content {
    flex: 1;

    display: flex;
    flex-direction: column;

    padding: 25px 24px 24px;
}

.door-model-content h3 {
    margin: 0 0 10px;

    color: #301c0f;

    font-size: 25px;
    font-weight: 700;
    line-height: 1.2;
}

.door-model-content p {
    margin: 0 0 22px;

    color: #62554c;

    font-size: 15px;
    line-height: 1.65;
}


/* =========================================
   DUGME KARTICE
========================================= */

.door-model-button {
    width: 100%;
    min-height: 49px;
    margin-top: auto;
    padding: 0 18px;

    display: inline-flex;
    justify-content: center;
    align-items: center;

    background-color: #ffffff;
    color: #6e4723;

    border: 1px solid #6e4723;
    border-radius: 4px;

    text-decoration: none;
    text-transform: uppercase;

    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.45px;

    transition:
        background-color 0.2s ease,
        color 0.2s ease,
        transform 0.2s ease;
}

.door-model-button:hover {
    background-color: #6e4723;
    color: #ffffff;

    transform: translateY(-2px);
}


/* =========================================
   TABLET — DVE KARTICE U REDU
========================================= */

@media (max-width: 980px) {

    .door-models-section {
        padding: 70px 0 80px;
    }

    .door-models-heading {
        margin-bottom: 38px;
    }

    .door-models-heading h2 {
        font-size: 37px;
    }

    .door-models-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 25px;
    }

}


/* =========================================
   TELEFON — JEDNA KARTICA U REDU
========================================= */

@media (max-width: 650px) {

    .door-models-section {
        padding: 58px 0 65px;
    }

    .door-models-heading {
        margin-bottom: 30px;
        text-align: left;
    }

    .door-models-label {
        font-size: 11px;
    }

    .door-models-heading h2 {
        margin-bottom: 13px;

        font-size: 32px;
        letter-spacing: -0.4px;
    }

    .door-models-description {
        font-size: 15px;
        line-height: 1.65;
    }

    .door-models-grid {
        grid-template-columns: 1fr;
        gap: 22px;
    }

    .door-model-image {
        aspect-ratio: 4 / 4.6;
    }

    .door-model-content {
        padding: 22px 20px 20px;
    }

    .door-model-content h3 {
        font-size: 23px;
    }

}


/* =========================================
   VEOMA MALI TELEFONI
========================================= */

@media (max-width: 390px) {

    .door-models-heading h2 {
        font-size: 29px;
    }

    .door-model-content {
        padding: 20px 17px 18px;
    }

    .door-model-button {
        min-height: 47px;
        font-size: 11px;
    }

}
/* HERO SEKCIJA BEZ SLIKE NA TELEFONU */
@media (max-width: 760px) {
    .catalog-hero {
        background-image: none;
        background-color: #f6f1ec;
        min-height: auto;
    }
}
.door-model-card.unavailable .door-model-image {
    position: relative;
}

.door-model-card.unavailable .door-model-image img {
    filter: brightness(55%);
}

.door-model-unavailable {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);

    width: max-content;
    max-width: 85%;
    padding: 10px 16px;

    background-color: rgba(255, 255, 255, 0.92);
    color: #5a3825;
    border-radius: 4px;

    font-size: 14px;
    font-weight: 600;
    text-align: center;
}

.door-model-button:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}