               * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    width: 100%;
    overflow-x: clip;
}

body {
    width: 100%;
    min-height: 100vh;
    margin: 0;
    padding-top: 280px;

    font-family: sans-serif;
    background: linear-gradient(135deg, #000000 0%, goldenrod 100%);
    overflow-x: clip;
}


/* ======================================================
   CONTAINER PRINCIPAL
====================================================== */

.container1 {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;

    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 30px 15px;
    gap: 3rem;

    box-sizing: border-box;
    perspective: 1200px;
}


/* ======================================================
   GRUPOS DE CARTÕES
====================================================== */

.cards {
    position: relative;

    width: 250px;
    height: 350px;

    flex-shrink: 0;
    margin: 0 auto;
}


/* ======================================================
   CARTÕES INDIVIDUAIS
====================================================== */

.card {
    position: absolute;

    width: 100%;
    height: 100%;

    border-radius: 12px;
    overflow: hidden;

    cursor: pointer;

    transition:
        transform 0.5s ease,
        box-shadow 0.3s ease;

    transform-origin: bottom center;

    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.card img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: cover;
}


/* ======================================================
   POSICIONAMENTO DAS CAMADAS
====================================================== */

.front {
    z-index: 3;

    transform:
        rotateX(10deg)
        translateY(20px);
}

.back-left {
    z-index: 2;

    transform:
        rotateX(25deg)
        rotateZ(-4deg)
        translate(-30px, -6px);
}

.back-right {
    z-index: 1;

    transform:
        rotateX(25deg)
        rotateZ(4deg)
        translate(30px, -6px);
}


/* ======================================================
   EFEITO HOVER - COMPUTADORES
====================================================== */

@media (hover: hover) and (pointer: fine) {

    .cards:hover .front {
        transform:
            rotateX(20deg)
            translateY(40px)
            scale(1.05);
    }

    .cards:hover .back-left {
        transform:
            rotateX(25deg)
            rotateZ(-15deg)
            translate(-70px, 20px)
            scale(1.05);
    }

    .cards:hover .back-right {
        transform:
            rotateX(25deg)
            rotateZ(15deg)
            translate(70px, 20px)
            scale(1.05);
    }

}


/* ======================================================
   LIGHTBOX
====================================================== */

.lightbox {
    position: fixed;

    top: 0;
    left: 0;

    width: 100%;
    height: 100%;

    background: rgba(0, 0, 0, 0.95);

    display: flex;
    justify-content: center;
    align-items: center;

    opacity: 0;
    pointer-events: none;

    transition: opacity 0.4s ease;

    z-index: 10000;
}

.lightbox.active {
    opacity: 1;
    pointer-events: all;
}

.lightbox img {
    max-width: 85%;
    max-height: 85%;

    border-radius: 8px;

    box-shadow: 0 0 30px rgba(218, 165, 32, 0.3);

    transform: scale(0.8);
    transition: transform 0.3s ease;
}

.lightbox.active img {
    transform: scale(1);
}


/* ======================================================
   BOTÃO FECHAR LIGHTBOX
====================================================== */

.close {
    position: absolute;

    top: 20px;
    right: 30px;

    font-size: 50px;
    color: white;

    cursor: pointer;
    z-index: 10001;
}


/* ======================================================
   BARRA DOURADA DO PORTFÓLIO
====================================================== */

.box-shadow {
    position: fixed;

    top: 80px;
    left: 0;

    width: 100%;

    z-index: 9000;

    padding: 2px 10px;

    text-align: center;

    background: rgba(218, 165, 32, 0.97);

    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);

    backdrop-filter: blur(10px);
}

.box-shadow h1 {
    margin: 0;

    font-size: clamp(32px, 8vw, 72px);

    text-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.box-shadow p {
    max-width: 800px;

    margin: 20px auto;

    padding: 0 20px;

    font-size: 18px;
    line-height: 1.5;
}


/* ======================================================
   TELAS ATÉ 1200px
====================================================== */

@media (max-width: 1200px) {

    .container1 {
        gap: 6rem;
        padding: 45px 30px;
    }

    .cards {
        width: 240px;
        height: 340px;
    }

}


/* ======================================================
   TELAS ATÉ 992px
====================================================== */

@media (max-width: 992px) {

    .container1 {
        gap: 4rem;
        padding: 40px 25px;
    }

    .cards {
        width: 230px;
        height: 325px;
    }

    .box-shadow {
        padding: 18px 10px;
    }

    .box-shadow p {
        font-size: 17px;
    }

}


/* ======================================================
   TELAS ATÉ 768px
====================================================== */

@media (max-width: 768px) {

    body {
        padding-top: 0;
    }

    .container1 {
        gap: 3rem;
        padding: 35px 15px;
    }

    .cards {
        width: 220px;
        height: 310px;
    }

   
    .box-shadow {
        position: relative;
        top: auto;
        left: auto;

        width: 100%;
        margin: 0;

        padding: 15px 10px;

        z-index: 1;
        box-sizing: border-box;
    }


    .box-shadow h1 {
        font-size: clamp(30px, 8vw, 55px);
    }

    .box-shadow p {
        font-size: 16px;
        padding: 0 15px;
    }

    .close {
        top: 15px;
        right: 20px;
        font-size: 45px;
    }

}


/* ======================================================
   TELAS ATÉ 600px
   CARTÕES EM UMA ÚNICA COLUNA
====================================================== */

@media (max-width: 600px) {

    body {
        padding-top: 0;
    }

    .container1 {
        display: flex;

        flex-direction: column;
        flex-wrap: nowrap;

        justify-content: flex-start;
        align-items: center;

        width: 100%;
        max-width: 100%;

        margin: 0 auto;

        padding: 30px 0;

        gap: 3rem;
    }

    .cards {
        width: min(210px, 85vw);
        height: 295px;

        flex-shrink: 0;

        margin-left: auto;
        margin-right: auto;
    }

    .box-shadow {
        position: relative;

        top: auto;
        left: auto;

        width: 100%;

        margin-top: -15px;

        padding: 15px 10px;

        z-index: 1;
    }

    .box-shadow h1 {
        font-size: clamp(28px, 9vw, 48px);
    }

    .box-shadow p {
        font-size: 15px;
        line-height: 1.5;
        padding: 0 10px;
    }

    .close {
        top: 10px;
        right: 15px;
        font-size: 40px;
    }

    /* Reduzir a abertura das camadas */

    .back-left {
        transform:
            rotateX(20deg)
            rotateZ(-3deg)
            translate(-15px, -5px);
    }

    .back-right {
        transform:
            rotateX(20deg)
            rotateZ(3deg)
            translate(15px, -5px);
    }

}


/* ======================================================
   TELAS ATÉ 480px
====================================================== */

@media (max-width: 480px) {

    .container1 {
        gap: 2.5rem;
        padding: 25px 0;
    }

    .cards {
        width: min(200px, 85vw);
        height: 280px;
    }

    .box-shadow {
        padding: 14px 8px;
    }

    .box-shadow h1 {
        font-size: clamp(26px, 10vw, 42px);
    }

    .box-shadow p {
        font-size: 14px;
        padding: 0 10px;
    }

    .close {
        font-size: 38px;
        right: 12px;
    }

}


/* ======================================================
   TELAS ATÉ 380px
====================================================== */

@media (max-width: 380px) {

    .container1 {
        gap: 2.5rem;
        padding: 20px 0;
    }

    .cards {
        width: min(185px, 85vw);
        height: 260px;
    }

    .box-shadow {
        padding: 12px 6px;
    }

    .box-shadow h1 {
        font-size: clamp(24px, 10vw, 36px);
    }

    .box-shadow p {
        font-size: 13px;
        line-height: 1.4;
        padding: 0 8px;
    }

    .close {
        top: 8px;
        right: 10px;
        font-size: 35px;
    }

}


/* ======================================================
   TELAS ATÉ 320px
====================================================== */

@media (max-width: 320px) {

    .container1 {
        gap: 2rem;
        padding: 18px 0;
    }

    .cards {
        width: min(170px, 85vw);
        height: 240px;
    }

    .box-shadow {
        padding: 10px 5px;
    }

    .box-shadow h1 {
        font-size: clamp(22px, 10vw, 32px);
    }

    .box-shadow p {
        font-size: 12px;
        padding: 0 5px;
    }

}


/* ======================================================
   TELAS ATÉ 280px
====================================================== */

@media (max-width: 280px) {

    .container1 {
        gap: 1.5rem;
        padding: 15px 0;
    }

    .cards {
        width: min(155px, 85vw);
        height: 220px;
    }

    .box-shadow {
        padding: 8px 4px;
    }

    .box-shadow h1 {
        font-size: 24px;
    }

    .box-shadow p {
        font-size: 11px;
        line-height: 1.35;
        padding: 0 4px;
    }

    .close {
        top: 5px;
        right: 7px;
        font-size: 30px;
    }

}
