/* =========================================
   CART PAGE
========================================= */

.cart-page {
    width: 100%;
    background: #f8f6f1;
}

.cart-section {
    width: 100%;
    padding: 65px 35px 80px;
}

.cart-container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
}


/* =========================================
   HEADING
========================================= */

.cart-heading {
    margin-bottom: 38px;
}

.cart-heading h1 {
    margin: 0;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size: 32px;
    font-weight: 500;
    line-height: 1.2;

    color: #18251d;

    text-transform: uppercase;
    letter-spacing: 1px;
}


/* =========================================
   CART LAYOUT
========================================= */

.cart-layout {
    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        330px;

    gap: 25px;

    align-items: start;
}


/* =========================================
   CART ITEM
========================================= */

.cart-item {
    display: grid;

    grid-template-columns:
        150px
        minmax(0, 1fr)
        120px;

    gap: 20px;

    align-items: center;

    padding: 18px;
    margin-bottom: 12px;

    background: #fbfaf7;

    border: 1px solid #ded8cb;

    border-radius: 6px;
}


/* =========================================
   IMAGE
========================================= */

.cart-item-image {
    width: 150px;

    aspect-ratio: 1 / 1;

    overflow: hidden;

    background: #eee9df;

    border-radius: 4px;
}

.cart-item-image img {
    width: 100%;
    height: 100%;

    display: block;

    object-fit: cover;
}


/* =========================================
   DETAILS
========================================= */

.cart-item-details {
    min-width: 0;
}

.cart-item-title {
    margin: 0 0 8px;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size: 19px;
    font-weight: 600;

    line-height: 1.25;

    color: #1d2921;
}

.cart-item-title a {
    color: inherit;
}

.cart-item-price {
    margin-bottom: 12px;

    color: #7b6030;

    font-size: 14px;
    font-weight: 600;
}


/* =========================================
   QUANTITY
========================================= */

.cart-item-controls {
    display: flex;

    align-items: center;

    gap: 18px;
}

.cart-quantity {
    display: flex;

    align-items: center;

    gap: 8px;
}

.cart-quantity label {
    color: #55564f;

    font-size: 10px;
    font-weight: 600;
}

.cart-quantity .quantity {
    margin: 0;
}

.cart-quantity input.qty {
    width: 58px;

    padding: 7px 5px;

    text-align: center;

    border: 1px solid #d5cfc1;

    border-radius: 3px;

    background: #ffffff;

    color: #1d2921;

    font-size: 12px;
}


/* =========================================
   REMOVE
========================================= */

.cart-remove {
    color: #8a3f35;

    font-size: 9px;
    font-weight: 600;

    letter-spacing: 0.6px;
}

.cart-remove:hover {
    color: #b14e41;
}


/* =========================================
   ITEM TOTAL
========================================= */

.cart-item-total {
    text-align: right;

    color: #1b261f;

    font-size: 14px;
    font-weight: 600;
}


/* =========================================
   BUTTON
========================================= */

.cart-button {
    display: inline-block;

    padding: 10px 18px;

    border: 0;
    border-radius: 3px;

    background: #0b281a;

    color: #ffffff;

    font-size: 9px;
    font-weight: 600;

    letter-spacing: 0.7px;

    cursor: pointer;

    text-align: center;

    transition:
        background 0.2s ease,
        transform 0.2s ease;
}

.cart-button:hover {
    background: #173d29;

    color: #ffffff;

    transform: translateY(-1px);
}


/* =========================================
   UPDATE
========================================= */

.cart-update-row {
    display: flex;

    justify-content: flex-end;

    padding-top: 8px;
}


/* =========================================
   SUMMARY
========================================= */

.cart-summary {
    padding: 23px 22px 25px;

    background: #fbfaf7;

    border: 1px solid #ded8cb;

    border-radius: 6px;
}

.cart-summary h2 {
    margin: 0 0 22px;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size: 21px;
    font-weight: 600;

    color: #1d2921;
}

.cart-summary-row {
    display: flex;

    justify-content: space-between;

    gap: 15px;

    padding: 11px 0;

    border-bottom: 1px solid #e6e1d7;

    color: #66675f;

    font-size: 11px;
}

.cart-summary-row strong {
    color: #29342d;

    font-weight: 600;

    text-align: right;
}

.cart-summary-total {
    display: flex;

    justify-content: space-between;

    padding: 17px 0;

    color: #1d2921;

    font-size: 15px;
    font-weight: 600;
}

.cart-checkout-button {
    display: block;

    width: 100%;

    padding: 12px 14px;
}

.cart-continue {
    display: block;

    margin-top: 17px;

    text-align: center;

    color: #7b6030;

    font-size: 9px;
    font-weight: 600;

    letter-spacing: 0.6px;
}

.cart-continue:hover {
    color: #18251d;
}


/* =========================================
   EMPTY CART
========================================= */

.cart-empty {
    max-width: 650px;

    margin: 35px auto 0;

    padding: 55px 30px;

    text-align: center;

    background: #fbfaf7;

    border: 1px solid #ded8cb;

    border-radius: 6px;
}

.cart-empty h2 {
    margin: 0 0 10px;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size: 25px;
    font-weight: 600;

    color: #1d2921;
}

.cart-empty p {
    margin: 0 0 25px;

    color: #6f7069;

    font-size: 11px;

    line-height: 1.6;
}


/* =========================================
   TABLET
========================================= */

@media (max-width: 950px) {

    .cart-section {
        padding: 55px 25px 65px;
    }

    .cart-layout {
        grid-template-columns: 1fr;
    }

    .cart-summary {
        width: 100%;
        max-width: 500px;

        margin: 0 auto;
    }

}


/* =========================================
   MOBILE
========================================= */

@media (max-width: 600px) {

    .cart-section {
        padding: 45px 16px 55px;
    }

    .cart-heading {
        margin-bottom: 28px;
    }

    .cart-heading h1 {
        font-size: 24px;
    }

    .cart-item {
        grid-template-columns:
            85px
            minmax(0, 1fr);

        gap: 12px;

        padding: 12px;
    }

    .cart-item-image {
        width: 85px;
    }

    .cart-item-title {
        font-size: 14px;
    }

    .cart-item-price {
        font-size: 12px;
    }

    .cart-item-controls {
        align-items: flex-start;

        flex-direction: column;

        gap: 10px;
    }

    .cart-item-total {
        grid-column: 2;

        text-align: left;

        font-size: 12px;
    }

    .cart-summary {
        padding: 20px 16px 22px;
    }

    .cart-summary h2 {
        font-size: 19px;
    }

    .cart-empty {
        padding: 40px 20px;
    }

}

/* =========================================
   CART RESPONSIVE FIX
========================================= */

@media (max-width: 900px) {

    .cart-container {
        padding-left: 20px;
        padding-right: 20px;
    }

    .cart-content {
        grid-template-columns: 1fr;
        gap: 45px;
    }

    .cart-summary {
        width: 100%;
    }

}


/* =========================================
   MOBILE CART
========================================= */

@media (max-width: 600px) {

    .cart-page {
        padding: 50px 20px 70px;
    }

    .cart-container {
        padding: 0;
    }

    .cart-heading {
        margin-bottom: 30px;
    }

    .cart-heading h1 {
        font-size: 32px;
    }


    /* Cart items */

    .cart-items {
        width: 100%;
    }

    .cart-item {
        display: grid;
        grid-template-columns: 80px 1fr;
        gap: 15px;

        padding: 20px 0;
    }


    .cart-item-image {
        width: 80px;
        height: 80px;
    }

    .cart-item-image img {
        width: 100%;
        height: 100%;
        object-fit: contain;
    }


    .cart-item-details {
        min-width: 0;
    }

    .cart-item-title {
        font-size: 16px;
        line-height: 1.3;
        margin-bottom: 6px;
    }

    .cart-item-price {
        font-size: 13px;
    }


    /* Quantity */

    .cart-item-quantity {
        margin-top: 12px;
    }

    .cart-item-quantity input {
        width: 45px;
    }


    /* Remove button */

    .cart-item-remove {
        font-size: 10px;
    }


    /* Item total */

    .cart-item-total {
        font-size: 13px;
        white-space: nowrap;
    }


    /* Cart controls */

    .cart-actions {
        display: flex;
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }

    .cart-actions button,
    .cart-actions a {
        width: 100%;
        text-align: center;
    }


    /* Summary */

    .cart-summary {
        width: 100%;
        padding: 25px 20px;
    }

    .cart-summary h2 {
        font-size: 24px;
    }


    /* Checkout */

    .checkout-button {
        width: 100%;
    }


    /* Continue shopping */

    .continue-shopping {
        width: 100%;
        text-align: center;
    }

}