/* ============================================================
                RAY STUDIO - SHOPPING CART PAGE
============================================================ */


/* ============================================================
                CART PAGE COLORS
============================================================ */

:root {

    --cart-background: #fffdf9;

    --cart-section: #f3ece3;

    --cart-card: #ffffff;

    --cart-heading: #3f2c24;

    --cart-text: #6f5e55;

    --cart-accent: #9b6b43;

    --cart-border:
        rgba(63, 44, 36, 0.14);

    --cart-shadow:
        0 16px 40px
        rgba(63, 44, 36, 0.08);

}


/* ============================================================
                GENERAL PAGE SETTINGS
============================================================ */

* {

    margin: 0;

    padding: 0;

    box-sizing: border-box;

}


body {

    margin: 0;

    color:
        var(--cart-text);

    background:
        var(--cart-background);

    font-family:
        "Poppins",
        sans-serif;

}


button,
a,
input {

    font-family:
        "Poppins",
        sans-serif;

}


/* ============================================================
                CART HERO
============================================================ */

.cart-hero {

    padding:
        58px
        7%
        52px;

    text-align:
        center;

    background:
        linear-gradient(
            135deg,
            #f8f2ea,
            #eadfce
        );

}


.cart-eyebrow {

    margin-bottom: 8px;

    color:
        var(--cart-accent);

    font-size: 9px;

    font-weight: 600;

    letter-spacing: 3px;

}


.cart-hero h1 {

    color:
        var(--cart-heading);

    font-family:
        "Cormorant Garamond",
        serif;

    font-size:
        clamp(
            42px,
            5vw,
            62px
        );

    font-weight: 600;

    line-height: 1;

}


.cart-hero-text {

    margin-top: 15px;

    font-family:
        "Cormorant Garamond",
        serif;

    font-size: 19px;

}


/* ============================================================
                MAIN CART PAGE
============================================================ */

.cart-page {

    padding:
        55px
        7%
        70px;

}


.cart-layout {

    width: 100%;

    max-width: 1450px;

    margin: 0 auto;

    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        390px;

    gap: 38px;

    align-items: start;

}


/* ============================================================
                CART TITLE
============================================================ */

.cart-title-row {

    margin-bottom: 22px;

    display: flex;

    align-items: flex-end;

    justify-content: space-between;

    gap: 20px;

}


.small-label {

    margin-bottom: 5px;

    color:
        var(--cart-accent);

    font-size: 9px;

    font-weight: 600;

    letter-spacing: 2.4px;

}


.cart-title-row h2,
.cart-summary h2 {

    color:
        var(--cart-heading);

    font-family:
        "Cormorant Garamond",
        serif;

    font-size: 36px;

    font-weight: 600;

}


.cart-count {

    font-size: 11px;

}


/* ============================================================
                CART ITEM
============================================================ */

.cart-item {

    position: relative;

    margin-bottom: 18px;

    padding: 14px;

    border:
        1px solid
        var(--cart-border);

    border-radius: 20px;

    display: grid;

    grid-template-columns:
        135px
        minmax(0, 1fr)
        145px
        125px
        38px;

    align-items: center;

    gap: 20px;

    background:
        var(--cart-card);

    transition:
        transform 0.3s ease,
        box-shadow 0.3s ease;

}


.cart-item:hover {

    transform:
        translateY(-2px);

    box-shadow:
        var(--cart-shadow);

}


/* ============================================================
                CART IMAGE
============================================================ */

.cart-image {

    width: 135px;

    aspect-ratio:
        3 / 4;

    border-radius: 15px;

    overflow: hidden;

    background:
        var(--cart-section);

}


.cart-image img {

    width: 100%;

    height: 100%;

    display: block;

    object-fit: cover;

}


/* ============================================================
                PRODUCT INFORMATION
============================================================ */

.cart-category {

    margin-bottom: 5px;

    color:
        var(--cart-accent);

    font-size: 8px;

    font-weight: 600;

    letter-spacing: 1.8px;

}


.cart-product-info h3 {

    color:
        var(--cart-heading);

    font-family:
        "Cormorant Garamond",
        serif;

    font-size: 24px;

    font-weight: 600;

    line-height: 1.12;

}


.cart-size {

    margin-top: 7px;

    font-size: 10px;

}


.cart-prices {

    margin-top: 11px;

    display: flex;

    gap: 9px;

    flex-wrap: wrap;

}


.old-price {

    color:
        #b1a29b;

    font-size: 10px;

    text-decoration:
        line-through;

}


.current-price {

    color:
        var(--cart-heading);

    font-size: 12px;

    font-weight: 600;

}


/* ============================================================
                QUANTITY
============================================================ */

.cart-quantity {

    display: flex;

    flex-direction: column;

    gap: 8px;

}


.cart-quantity > span {

    font-size: 9px;

}


.quantity-box {

    width: 125px;

    height: 40px;

    border:
        1px solid
        var(--cart-border);

    border-radius: 50px;

    display: grid;

    grid-template-columns:
        38px
        1fr
        38px;

    overflow: hidden;

    background:
        #faf6f0;

}


.quantity-box button {

    border: none;

    background: transparent;

    color:
        var(--cart-heading);

    cursor: pointer;

}


.quantity-box input {

    width: 100%;

    border: none;

    outline: none;

    text-align: center;

    color:
        var(--cart-heading);

    background: transparent;

}


/* ============================================================
                ITEM TOTAL
============================================================ */

.cart-item-total {

    display: flex;

    flex-direction: column;

    gap: 5px;

}


.cart-item-total span {

    font-size: 9px;

}


.cart-item-total strong {

    color:
        var(--cart-heading);

    font-size: 12px;

}


/* ============================================================
                REMOVE BUTTON
============================================================ */

.remove-button {

    width: 34px;

    height: 34px;

    border:
        1px solid
        var(--cart-border);

    border-radius: 50%;

    display: flex;

    align-items: center;

    justify-content: center;

    color:
        #9a6c5c;

    background:
        transparent;

    cursor: pointer;

    transition:
        color 0.3s ease,
        background 0.3s ease;

}


.remove-button:hover {

    color:
        #ffffff;

    background:
        var(--cart-heading);

}


/* ============================================================
                CONTINUE SHOPPING
============================================================ */

.continue-shopping {

    margin-top: 24px;

    display: inline-flex;

    align-items: center;

    gap: 10px;

    color:
        var(--cart-heading);

    font-size: 10px;

    font-weight: 600;

    text-decoration: none;

}


/* ============================================================
                ORDER SUMMARY
============================================================ */

.cart-summary {

    position: sticky;

    top: 110px;

    padding: 28px;

    border:
        1px solid
        var(--cart-border);

    border-radius: 22px;

    background:
        var(--cart-card);

    box-shadow:
        var(--cart-shadow);

}


.summary-row {

    padding: 13px 0;

    display: flex;

    justify-content: space-between;

    gap: 20px;

    font-size: 11px;

}


.summary-row strong {

    color:
        var(--cart-heading);

    font-size: 11px;

    font-weight: 500;

}


.summary-line {

    height: 1px;

    margin: 10px 0;

    background:
        var(--cart-border);

}


.summary-total {

    padding:
        14px
        0
        18px;

    display: flex;

    justify-content: space-between;

    gap: 20px;

}


.summary-total span {

    color:
        var(--cart-heading);

    font-family:
        "Cormorant Garamond",
        serif;

    font-size: 18px;

    font-weight: 600;

}


.summary-total strong {

    color:
        var(--cart-heading);

    font-size: 16px;

}


/* ============================================================
                CHECKOUT BUTTON
============================================================ */

.checkout-button {

    width: 100%;

    min-height: 48px;

    padding:
        12px
        18px;

    border:
        1px solid
        var(--cart-heading);

    border-radius: 50px;

    display: flex;

    align-items: center;

    justify-content: center;

    gap: 12px;

    color:
        #ffffff;

    background:
        var(--cart-heading);

    font-size: 11px;

    font-weight: 600;

    cursor: pointer;

    transition:
        color 0.3s ease,
        background 0.3s ease,
        transform 0.3s ease;

}


.checkout-button:hover {

    color:
        var(--cart-heading);

    background:
        transparent;

    transform:
        translateY(-2px);

}


/* ============================================================
                SECURE NOTE
============================================================ */

.secure-note {

    margin-top: 15px;

    display: flex;

    justify-content: center;

    align-items: center;

    gap: 8px;

    font-size: 9px;

}


.secure-note i {

    color:
        var(--cart-accent);

}


/* ============================================================
                TABLET
============================================================ */

@media screen and (max-width: 1100px) {

    .cart-layout {

        grid-template-columns:
            1fr;

    }


    .cart-summary {

        position: static;

    }

}


/* ============================================================
                MOBILE
============================================================ */

@media screen and (max-width: 700px) {

    .cart-page {

        padding:
            38px
            14px
            50px;

    }


    .cart-item {

        grid-template-columns:
            100px
            minmax(0, 1fr);

        gap: 14px;

    }


    .cart-image {

        width: 100px;

    }


    .cart-quantity,
    .cart-item-total {

        grid-column: 2;

    }


    .remove-button {

        position: absolute;

        top: 12px;

        right: 12px;

    }

}


/* ============================================================
                SMALL MOBILE
============================================================ */

@media screen and (max-width: 550px) {

    .cart-hero {

        padding:
            42px
            18px
            38px;

    }


    .cart-hero h1 {

        font-size: 42px;

    }


    .cart-item {

        padding: 10px;

        border-radius: 16px;

        grid-template-columns:
            90px
            minmax(0, 1fr);

    }


    .cart-image {

        width: 90px;

        border-radius: 12px;

    }


    .cart-product-info h3 {

        padding-right: 30px;

        font-size: 19px;

    }


    .cart-summary {

        padding:
            22px
            18px;

        border-radius: 18px;

    }

}


/* ============================================================
                REDUCED MOTION
============================================================ */

@media (prefers-reduced-motion: reduce) {

    .cart-item,
    .checkout-button,
    .remove-button {

        transition: none;

    }

}


/* ============================================================
                DYNAMIC CART ADDITIONS
============================================================ */

.cart-image {

    display: block;

    text-decoration: none;

}


.cart-product-info h3 a {

    color: inherit;

    text-decoration: none;

}


.cart-product-info h3 a:hover {

    color: var(--cart-accent);

}


.cart-code {

    margin-top: 5px;

    color: var(--cart-accent);

    font-size: 8px;

    font-weight: 600;

    letter-spacing: 1px;

    text-transform: uppercase;

}


.cart-item > form {

    margin: 0;

}


.checkout-button {

    text-decoration: none;

}


.checkout-button:disabled {

    opacity: 0.5;

    cursor: not-allowed;

    transform: none;

}


.empty-cart {

    padding: 55px 24px;

    border: 1px solid var(--cart-border);

    border-radius: 20px;

    background: var(--cart-card);

    text-align: center;

}


.empty-cart > i {

    margin-bottom: 18px;

    color: var(--cart-accent);

    font-size: 34px;

}


.empty-cart h3 {

    color: var(--cart-heading);

    font-family: "Cormorant Garamond", serif;

    font-size: 30px;

    font-weight: 600;

}


.empty-cart p {

    margin-top: 8px;

    font-size: 11px;

}


.empty-cart a {

    margin-top: 20px;

    padding: 11px 20px;

    border: 1px solid var(--cart-heading);

    border-radius: 50px;

    display: inline-flex;

    color: #ffffff;

    background: var(--cart-heading);

    font-size: 10px;

    font-weight: 600;

    text-decoration: none;

}