/* =========================================================
   CORNERSTONE TECHDEV
   PORTFOLIO PAGE
   ========================================================= */


/* =========================================================
   HERO
   ========================================================= */

.portfolio-hero {
    position: relative;
    min-height: 72vh;

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

    padding: 150px 6% 100px;

    text-align: center;

    overflow: hidden;
}


.portfolio-hero-content {
    position: relative;
    z-index: 2;

    width: 100%;
    max-width: 1200px;

    margin: 0 auto;
}


.portfolio-eyebrow {
    margin: 0 0 25px;

    color: #D9943F;

    font-size: 0.72rem;
    font-weight: 700;

    letter-spacing: 0.28em;

    text-transform: uppercase;
}


.portfolio-hero h1 {
    margin: 0;

    color: #FAF7F1;

    font-size: clamp(
        3.5rem,
        8vw,
        8rem
    );

    line-height: 0.88;

    font-weight: 800;

    letter-spacing: -0.055em;

    text-transform: uppercase;
}


.portfolio-hero h1 span {
    display: block;

    color: #D9943F;
}


.portfolio-hero-description {
    max-width: 760px;

    margin: 38px auto 0;

    color: #E5DED4;

    font-size: 1rem;

    line-height: 1.8;
}


/* =========================================================
   PROJECT SECTION
   ========================================================= */

.portfolio-projects {
    position: relative;

    padding: 110px 5% 130px;

    overflow: hidden;
}


.portfolio-heading {
    width: min(1250px, 100%);

    margin: 0 auto 55px;

    display: flex;

    align-items: flex-end;

    justify-content: space-between;

    gap: 50px;
}


.portfolio-section-label {
    margin: 0 0 16px;

    color: #D9943F;

    font-size: 0.7rem;

    font-weight: 700;

    letter-spacing: 0.25em;

    text-transform: uppercase;
}


.portfolio-heading h2 {
    margin: 0;

    color: #FAF7F1;

    font-size: clamp(
        2.8rem,
        5vw,
        5.2rem
    );

    line-height: 0.92;

    font-weight: 800;

    letter-spacing: -0.055em;

    text-transform: uppercase;
}


.portfolio-heading h2 span {
    color: #D9943F;
}


.portfolio-heading-description {
    max-width: 400px;

    margin: 0;

    color: #AAA29A;

    font-size: 0.9rem;

    line-height: 1.75;
}


/* =========================================================
   CAROUSEL
   ========================================================= */

.portfolio-carousel {
    width: min(1250px, 100%);

    margin: 0 auto;

    position: relative;
}


.portfolio-carousel-viewport {
    width: 100%;

    overflow: hidden;

    cursor: grab;

    touch-action: pan-y;

    border-radius: 3px;
}


.portfolio-carousel-viewport:active {
    cursor: grabbing;
}


/* =========================================================
   TRACK
   ========================================================= */

.portfolio-carousel-track {
    display: flex;

    gap: 30px;

    width: max-content;

    transition:
        transform 0.65s
        cubic-bezier(
            0.22,
            1,
            0.36,
            1
        );

    will-change: transform;
}


.portfolio-carousel-track.is-dragging {
    transition: none;
}


/* =========================================================
   PROJECT CARD
   ========================================================= */

.portfolio-carousel-card {
    position: relative;

    flex: 0 0
        calc(
            min(1250px, 90vw)
        );

    min-height: 600px;

    display: grid;

    grid-template-columns:
        1.25fr
        0.75fr;

    overflow: hidden;

    border:
        1px solid
        rgba(
            217,
            148,
            63,
            0.30
        );

    background:
        linear-gradient(
            135deg,
            rgba(
                255,
                255,
                255,
                0.055
            ),
            rgba(
                255,
                255,
                255,
                0.015
            )
        );

    box-shadow:
        0 30px 80px
        rgba(
            0,
            0,
            0,
            0.35
        );
}


/* =========================================================
   PROJECT IMAGE
   ========================================================= */

.portfolio-carousel-image {
    position: relative;

    min-height: 600px;

    overflow: hidden;

    background:
        linear-gradient(
            135deg,
            #211A14,
            #0D0B09
        );
}


.portfolio-carousel-image img {
    width: 100%;
    height: 100%;

    display: block;

    object-fit: cover;

    object-position: center;

    user-select: none;

    pointer-events: none;

    transition:
        transform 0.8s
        cubic-bezier(
            0.2,
            0.8,
            0.2,
            1
        );
}


.portfolio-carousel-card:hover
.portfolio-carousel-image img {
    transform: scale(1.035);
}


.portfolio-carousel-image::after {
    content: "";

    position: absolute;

    inset: 0;

    pointer-events: none;

    background:
        linear-gradient(
            90deg,
            transparent 55%,
            rgba(
                13,
                11,
                9,
                0.65
            )
        );
}


/* =========================================================
   PROJECT NUMBER
   ========================================================= */

.portfolio-carousel-number {
    position: absolute;

    top: 25px;
    left: 25px;

    z-index: 3;

    width: 52px;
    height: 52px;

    display: flex;

    align-items: center;
    justify-content: center;

    color: #D9943F;

    background:
        rgba(
            13,
            11,
            9,
            0.72
        );

    border:
        1px solid
        rgba(
            243,
            238,
            230,
            0.35
        );

    backdrop-filter: blur(10px);

    -webkit-backdrop-filter: blur(10px);

    font-size: 0.7rem;

    font-weight: 700;

    letter-spacing: 0.12em;
}


/* =========================================================
   EMPTY PROJECT
   ========================================================= */

.portfolio-carousel-image-empty {
    display: flex;

    align-items: center;
    justify-content: center;

    background:
        radial-gradient(
            circle,
            rgba(
                217,
                148,
                63,
                0.13
            ),
            transparent 60%
        ),
        #0E0B09;
}


.portfolio-carousel-image-empty::before {
    content: "";

    position: absolute;

    inset: 35px;

    border:
        1px solid
        rgba(
            217,
            148,
            63,
            0.20
        );
}


.portfolio-carousel-empty-content {
    position: relative;

    z-index: 2;

    display: flex;

    flex-direction: column;

    align-items: center;

    gap: 18px;

    text-align: center;
}


.portfolio-carousel-empty-content span {
    color: #D9943F;

    font-size: 0.75rem;

    letter-spacing: 0.2em;
}


.portfolio-carousel-empty-content strong {
    color: #FAF7F1;

    font-size: clamp(
        2rem,
        4vw,
        3.8rem
    );

    font-weight: 800;

    letter-spacing: -0.05em;
}


/* =========================================================
   PROJECT CONTENT
   ========================================================= */

.portfolio-carousel-content {
    display: flex;

    flex-direction: column;

    justify-content: center;

    padding: 65px;
}


.portfolio-carousel-category {
    margin: 0 0 18px;

    color: #D9943F;

    font-size: 0.65rem;

    font-weight: 700;

    letter-spacing: 0.2em;

    line-height: 1.5;

    text-transform: uppercase;
}


.portfolio-carousel-content h3 {
    margin: 0;

    color: #FAF7F1;

    font-size: clamp(
        2.5rem,
        4vw,
        5rem
    );

    line-height: 0.9;

    font-weight: 800;

    letter-spacing: -0.055em;

    text-transform: uppercase;
}


.portfolio-carousel-description {
    max-width: 460px;

    margin: 30px 0 0;

    color: #D8D0C6;

    font-size: 0.92rem;

    line-height: 1.8;
}


/* =========================================================
   TAGS
   ========================================================= */

.portfolio-carousel-tags {
    display: flex;

    flex-wrap: wrap;

    gap: 8px;

    margin-top: 28px;
}


.portfolio-carousel-tags span {
    padding: 7px 10px;

    border:
        1px solid
        rgba(
            217,
            148,
            63,
            0.25
        );

    color: #AFA79D;

    background:
        rgba(
            217,
            148,
            63,
            0.04
        );

    font-size: 0.56rem;

    font-weight: 700;

    letter-spacing: 0.1em;
}


/* =========================================================
   PROJECT LINK
   ========================================================= */

.portfolio-carousel-link {
    width: fit-content;

    display: inline-flex;

    align-items: center;

    gap: 17px;

    margin-top: 38px;

    padding-bottom: 9px;

    border-bottom:
        1px solid
        #D9943F;

    color: #D9943F;

    font-size: 0.68rem;

    font-weight: 700;

    letter-spacing: 0.17em;

    text-decoration: none;

    transition:
        gap 0.25s ease,
        color 0.25s ease,
        border-color 0.25s ease;
}


.portfolio-carousel-link span {
    font-size: 1rem;
}


.portfolio-carousel-link:hover {
    gap: 25px;

    color: #FAF7F1;

    border-color: #FAF7F1;
}


/* =========================================================
   CONTROLS
   ========================================================= */

.portfolio-carousel-controls {
    display: flex;

    align-items: center;

    justify-content: space-between;

    margin-top: 28px;
}


.portfolio-carousel-prev,
.portfolio-carousel-next {
    width: 52px;
    height: 52px;

    display: flex;

    align-items: center;
    justify-content: center;

    padding: 0;

    border:
        1px solid
        rgba(
            217,
            148,
            63,
            0.35
        );

    background:
        rgba(
            217,
            148,
            63,
            0.035
        );

    color: #D9943F;

    font-family: inherit;

    font-size: 1.1rem;

    cursor: pointer;

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


.portfolio-carousel-prev:hover:not(:disabled),
.portfolio-carousel-next:hover:not(:disabled) {
    background:
        rgba(
            217,
            148,
            63,
            0.12
        );

    border-color: #D9943F;

    color: #FAF7F1;

    transform: translateY(-2px);
}


.portfolio-carousel-prev:disabled,
.portfolio-carousel-next:disabled {
    opacity: 0.25;

    cursor: not-allowed;
}


/* =========================================================
   STATUS
   ========================================================= */

.portfolio-carousel-status {
    display: flex;

    align-items: center;

    gap: 9px;

    color: #77716A;

    font-size: 0.65rem;

    font-weight: 700;

    letter-spacing: 0.16em;
}


.portfolio-carousel-current {
    color: #D9943F;
}


/* =========================================================
   INDICATORS
   ========================================================= */

.portfolio-carousel-indicators {
    display: flex;

    align-items: center;

    justify-content: center;

    gap: 8px;

    margin-top: 25px;
}


.portfolio-carousel-indicator {
    width: 30px;
    height: 3px;

    padding: 0;

    border: 0;

    background:
        rgba(
            243,
            238,
            230,
            0.18
        );

    cursor: pointer;

    transition:
        width 0.3s ease,
        background 0.3s ease;
}


.portfolio-carousel-indicator.active {
    width: 55px;

    background: #D9943F;
}


.portfolio-carousel-indicator:hover {
    background: #B9B2A8;
}


/* =========================================================
   HINT
   ========================================================= */

.portfolio-carousel-hint {
    display: flex;

    align-items: center;

    justify-content: center;

    gap: 12px;

    margin: 20px 0 0;

    color: #77716A;

    font-size: 0.58rem;

    font-weight: 700;

    letter-spacing: 0.18em;

    text-transform: uppercase;
}


.portfolio-carousel-hint::before,
.portfolio-carousel-hint::after {
    content: "";

    width: 30px;
    height: 1px;

    background:
        rgba(
            217,
            148,
            63,
            0.25
        );
}


/* =========================================================
   FULL-STACK SECTION
   ========================================================= */

.portfolio-capability {
    position: relative;

    padding: 130px 5%;

    border-top:
        1px solid
        rgba(
            217,
            148,
            63,
            0.15
        );

    border-bottom:
        1px solid
        rgba(
            217,
            148,
            63,
            0.15
        );
}


.portfolio-capability-inner {
    width: min(1250px, 100%);

    margin: 0 auto;

    display: grid;

    grid-template-columns:
        0.85fr
        1.15fr;

    align-items: center;

    gap: 90px;
}


.portfolio-capability-label {
    margin: 0 0 20px;

    color: #D9943F;

    font-size: 0.68rem;

    font-weight: 700;

    letter-spacing: 0.22em;

    text-transform: uppercase;
}


.portfolio-capability h2 {
    margin: 0;

    color: #FAF7F1;

    font-size: clamp(
        2.7rem,
        5vw,
        5.2rem
    );

    line-height: 0.92;

    font-weight: 800;

    letter-spacing: -0.055em;

    text-transform: uppercase;
}


.portfolio-capability h2 span {
    color: #D9943F;
}


.portfolio-capability-copy {
    color: #D8D0C6;

    font-size: 0.95rem;

    line-height: 1.85;
}


.portfolio-capability-copy p {
    margin: 0 0 22px;
}


/* =========================================================
   SERVICES LINK
   ========================================================= */

.portfolio-services-link {
    width: fit-content;

    display: inline-flex;

    align-items: center;

    gap: 15px;

    margin-top: 12px;

    padding-bottom: 8px;

    border-bottom:
        1px solid
        #D9943F;

    color: #D9943F;

    font-size: 0.68rem;

    font-weight: 700;

    letter-spacing: 0.16em;

    text-decoration: none;

    transition:
        gap 0.25s ease,
        color 0.25s ease;
}


.portfolio-services-link:hover {
    gap: 23px;

    color: #FAF7F1;
}


/* =========================================================
   CTA
   ========================================================= */

.portfolio-cta {
    padding: 135px 5%;

    text-align: center;
}


.portfolio-cta-inner {
    width: min(850px, 100%);

    margin: 0 auto;
}


.portfolio-cta-label {
    margin: 0 0 20px;

    color: #D9943F;

    font-size: 0.68rem;

    font-weight: 700;

    letter-spacing: 0.23em;

    text-transform: uppercase;
}


.portfolio-cta h2 {
    margin: 0;

    color: #FAF7F1;

    font-size: clamp(
        3rem,
        7vw,
        6.5rem
    );

    line-height: 0.9;

    font-weight: 800;

    letter-spacing: -0.055em;

    text-transform: uppercase;
}


.portfolio-cta h2 span {
    color: #D9943F;
}


.portfolio-cta-inner > p:not(.portfolio-cta-label) {
    max-width: 570px;

    margin: 30px auto 0;

    color: #AFA79D;

    font-size: 0.9rem;

    line-height: 1.8;
}


/* =========================================================
   CTA BUTTONS
   ========================================================= */

.portfolio-cta-buttons {
    display: flex;

    justify-content: center;

    align-items: center;

    flex-wrap: wrap;

    gap: 14px;

    margin-top: 38px;
}


.portfolio-cta-button {
    min-width: 175px;

    min-height: 52px;

    display: inline-flex;

    align-items: center;

    justify-content: center;

    padding: 14px 25px;

    border:
        1px solid
        #D9943F;

    color: #D9943F;

    background: transparent;

    font-size: 0.65rem;

    font-weight: 700;

    letter-spacing: 0.15em;

    text-decoration: none;

    text-transform: uppercase;

    transition:
        background 0.25s ease,
        color 0.25s ease,
        transform 0.25s ease;
}


.portfolio-cta-button:hover {
    background: #D9943F;

    color: #15110D;

    transform: translateY(-2px);
}


.portfolio-cta-button.primary {
    background: #D9943F;

    color: #15110D;
}


.portfolio-cta-button.primary:hover {
    background: #FAF7F1;

    border-color: #FAF7F1;
}


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

@media (max-width: 1000px) {

    .portfolio-hero {
        min-height: 65vh;

        padding-top: 130px;
    }


    .portfolio-heading {
        flex-direction: column;

        align-items: flex-start;
    }


    .portfolio-heading-description {
        max-width: 600px;
    }


    .portfolio-carousel-card {
        grid-template-columns: 1fr;

        min-height: auto;
    }


    .portfolio-carousel-image {
        min-height: 460px;
    }


    .portfolio-carousel-content {
        padding: 55px;
    }


    .portfolio-capability-inner {
        grid-template-columns: 1fr;

        gap: 55px;
    }

}


/* =========================================================
   MOBILE / TABLET
   ========================================================= */

@media (max-width: 768px) {

    .portfolio-hero {
        min-height: 60vh;

        padding:
            120px
            7%
            80px;
    }


    .portfolio-hero h1 {
        font-size:
            clamp(
                3rem,
                13vw,
                5.5rem
            );
    }


    .portfolio-hero-description {
        margin-top: 28px;

        font-size: 0.88rem;
    }


    .portfolio-projects {
        padding:
            80px
            5%
            95px;
    }


    .portfolio-heading {
        margin-bottom: 40px;
    }


    .portfolio-carousel-card {
        flex-basis:
            calc(
                100vw - 10vw
            );
    }


    .portfolio-carousel-image {
        min-height: 370px;
    }


    .portfolio-carousel-content {
        padding: 45px 35px;
    }


    .portfolio-carousel-content h3 {
        font-size:
            clamp(
                2.4rem,
                10vw,
                4rem
            );
    }


    .portfolio-capability {
        padding: 90px 7%;
    }


    .portfolio-cta {
        padding: 100px 7%;
    }

}


/* =========================================================
   SMALL MOBILE
   ========================================================= */

@media (max-width: 480px) {

    .portfolio-hero {
        min-height: 58vh;

        padding:
            110px
            7%
            70px;
    }


    .portfolio-eyebrow {
        font-size: 0.58rem;

        letter-spacing: 0.18em;
    }


    .portfolio-hero h1 {
        font-size: 3.15rem;
    }


    .portfolio-hero-description {
        font-size: 0.82rem;

        line-height: 1.7;
    }


    .portfolio-projects {
        padding:
            70px
            5%
            80px;
    }


    .portfolio-heading h2 {
        font-size: 2.5rem;
    }


    .portfolio-carousel-image {
        min-height: 280px;
    }


    .portfolio-carousel-number {
        top: 18px;
        left: 18px;

        width: 43px;
        height: 43px;

        font-size: 0.6rem;
    }


    .portfolio-carousel-content {
        padding:
            35px
            25px
            40px;
    }


    .portfolio-carousel-category {
        font-size: 0.56rem;
    }


    .portfolio-carousel-content h3 {
        font-size: 2.65rem;
    }


    .portfolio-carousel-description {
        font-size: 0.82rem;

        line-height: 1.7;
    }


    .portfolio-carousel-tags span {
        font-size: 0.48rem;

        padding:
            6px
            8px;
    }


    .portfolio-carousel-prev,
    .portfolio-carousel-next {
        width: 45px;
        height: 45px;
    }


    .portfolio-carousel-status {
        font-size: 0.56rem;
    }


    .portfolio-carousel-hint {
        font-size: 0.5rem;

        letter-spacing: 0.11em;
    }


    .portfolio-carousel-hint::before,
    .portfolio-carousel-hint::after {
        width: 17px;
    }


    .portfolio-capability {
        padding: 75px 7%;
    }


    .portfolio-capability h2 {
        font-size: 2.7rem;
    }


    .portfolio-capability-copy {
        font-size: 0.84rem;
    }


    .portfolio-cta {
        padding: 85px 7%;
    }


    .portfolio-cta h2 {
        font-size: 3.2rem;
    }


    .portfolio-cta-buttons {
        flex-direction: column;
    }


    .portfolio-cta-button {
        width: 100%;
    }

}


/* =========================================================
   ACCESSIBILITY
   ========================================================= */

.portfolio-carousel-prev:focus-visible,
.portfolio-carousel-next:focus-visible,
.portfolio-carousel-indicator:focus-visible,
.portfolio-carousel-link:focus-visible,
.portfolio-services-link:focus-visible,
.portfolio-cta-button:focus-visible {
    outline:
        2px solid
        #D9943F;

    outline-offset: 4px;
}


/* =========================================================
   REDUCED MOTION
   ========================================================= */

@media (prefers-reduced-motion: reduce) {

    .portfolio-carousel-track,
    .portfolio-carousel-image img,
    .portfolio-carousel-link,
    .portfolio-carousel-prev,
    .portfolio-carousel-next,
    .portfolio-carousel-indicator,
    .portfolio-services-link,
    .portfolio-cta-button {
        transition: none !important;
    }

}