/* =========================================================
   DOLCI HANDS — CARRITO
========================================================= */

.cart-page {

    width: min(1180px, calc(100% - 40px));

    margin: 0 auto;

    padding: 55px 0 80px;

    color: #49352c;

}


/* =========================================================
   CABECERA
========================================================= */

.cart-header {

    margin-bottom: 42px;

}


.cart-eyebrow {

    display: block;

    margin-bottom: 8px;

    color: #a86c55;

    font-size: 10px;

    font-weight: 800;

    letter-spacing: .12em;

    text-transform: uppercase;

}


.cart-header h1 {

    margin: 0 0 10px;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size: clamp(36px, 5vw, 52px);

    font-weight: 500;

    line-height: 1.05;

    color: #3f2b24;

}


.cart-header p {

    max-width: 560px;

    margin: 0;

    color: #80695d;

    font-size: 14px;

    line-height: 1.7;

}


/* =========================================================
   NOTIFICACIÓN FLOTANTE
========================================================= */

.cart-toast-container {

    position: fixed;

    top: 92px;

    right: 28px;

    z-index: 9999;

    display: flex;

    flex-direction: column;

    gap: 10px;

    pointer-events: none;

}


.cart-toast {

    display: flex;

    align-items: center;

    gap: 12px;

    min-width: 270px;

    max-width: 360px;

    padding: 13px 17px;

    border:
        1px solid
        rgba(91, 64, 52, .12);

    border-radius: 14px;

    background:
        rgba(255, 253, 251, .96);

    box-shadow:
        0 14px 35px
        rgba(76, 51, 40, .14);

    backdrop-filter:
        blur(12px);

    color: #65493d;

    font-size: 12px;

    font-weight: 600;

    animation:
        cartToastIn .3s ease forwards,
        cartToastOut .45s ease 1.6s forwards;

}


.cart-toast-icon {

    width: 27px;

    height: 27px;

    flex-shrink: 0;

    display: flex;

    align-items: center;

    justify-content: center;

    border-radius: 50%;

    background: #f0dfd4;

    color: #a86c55;

    font-size: 13px;

    font-weight: 700;

}


.cart-toast-message {

    line-height: 1.4;

}


@keyframes cartToastIn {

    from {

        opacity: 0;

        transform:
            translateY(-12px)
            translateX(10px);

    }

    to {

        opacity: 1;

        transform:
            translateY(0)
            translateX(0);

    }

}


@keyframes cartToastOut {

    from {

        opacity: 1;

        transform: translateY(0);

    }

    to {

        opacity: 0;

        transform: translateY(-8px);

    }

}


/* =========================================================
   LAYOUT
========================================================= */

.cart-layout {

    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        330px;

    gap: 34px;

    align-items: start;

}


/* =========================================================
   PRODUCTOS
========================================================= */

.cart-products {

    min-width: 0;

}


.cart-section-heading {

    display: flex;

    align-items: flex-end;

    justify-content: space-between;

    gap: 20px;

    margin-bottom: 18px;

}


.cart-section-heading h2 {

    margin: 0;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size: 25px;

    font-weight: 500;

    color: #49352c;

}


.cart-product-count {

    padding: 7px 11px;

    border-radius: 999px;

    background: #f3e7de;

    color: #87675a;

    font-size: 11px;

    font-weight: 700;

}


/* =========================================================
   LISTA
========================================================= */

.cart-product-list {

    display: flex;

    flex-direction: column;

    gap: 14px;

}


/* =========================================================
   TARJETA DEL PRODUCTO
========================================================= */

.cart-product-card {

    display: grid;

    grid-template-columns: 145px minmax(0, 1fr);

    gap: 22px;

    min-width: 0;

    padding: 18px;

    border:
        1px solid
        rgba(91, 64, 52, .10);

    border-radius: 22px;

    background: #fffdfa;

    box-shadow:
        0 8px 28px
        rgba(76, 51, 40, .045);

    transition:
        transform .2s ease,
        box-shadow .2s ease,
        border-color .2s ease;

}


.cart-product-card:hover {

    transform: translateY(-2px);

    border-color:
        rgba(184, 120, 93, .25);

    box-shadow:
        0 14px 35px
        rgba(76, 51, 40, .075);

}


/* =========================================================
   IMAGEN
========================================================= */

.cart-product-image {

    position: relative;

    min-height: 150px;

    display: flex;

    align-items: center;

    justify-content: center;

    overflow: hidden;

    border-radius: 17px;

    background:
        radial-gradient(
            circle at center,
            #fff8f2 0%,
            #f3e4d9 100%
        );

}


.cart-product-image img {

    width: 100%;

    height: 100%;

    max-height: 155px;

    object-fit: contain;

    display: block;

    transition:
        transform .3s ease;

}


.cart-product-card:hover
.cart-product-image img {

    transform: scale(1.04);

}


.cart-product-image-placeholder {

    padding: 20px;

    text-align: center;

    color: #a88b7d;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size: 15px;

}


/* =========================================================
   INFORMACIÓN
========================================================= */

.cart-product-info {

    min-width: 0;

    display: flex;

    flex-direction: column;

}


.cart-product-label {

    margin-bottom: 5px;

    color: #a97963;

    font-size: 9px;

    font-weight: 800;

    letter-spacing: .11em;

}


.cart-product-info h3 {

    margin: 0 0 5px;

    color: #3f2b24;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size: 21px;

    font-weight: 500;

}


.cart-product-price {

    margin: 0;

    color: #87675a;

    font-size: 13px;

}


/* =========================================================
   PARTE INFERIOR
========================================================= */

.cart-product-bottom {

    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 20px;

    margin-top: auto;

    padding-top: 20px;

}


/* =========================================================
   CANTIDAD
========================================================= */

.cart-quantity {

    display: inline-flex;

    align-items: center;

    gap: 10px;

    padding: 4px;

    border:
        1px solid
        #e3d4ca;

    border-radius: 999px;

    background: #fffaf6;

}


.cart-quantity form {

    margin: 0;

}


.cart-quantity button {

    width: 30px;

    height: 30px;

    display: flex;

    align-items: center;

    justify-content: center;

    border: 0;

    border-radius: 50%;

    background: #f0e1d6;

    color: #65493d;

    font-size: 17px;

    line-height: 1;

    cursor: pointer;

    transition:
        background .2s ease,
        transform .2s ease;

}


.cart-quantity button:hover {

    background: #e5d1c4;

    transform: scale(1.05);

}


.cart-quantity > span {

    min-width: 20px;

    text-align: center;

    color: #4b362d;

    font-size: 13px;

    font-weight: 700;

}


.cart-product-subtotal {

    color: #49352c;

    font-size: 16px;

    white-space: nowrap;

}


/* =========================================================
   ELIMINAR
========================================================= */

.cart-remove-form {

    margin-top: 9px;

}


.cart-remove {

    padding: 0;

    border: 0;

    background: transparent;

    color: #a4877a;

    font-family: inherit;

    font-size: 11px;

    cursor: pointer;

}


.cart-remove:hover {

    color: #a85f48;

    text-decoration: underline;

}


/* =========================================================
   RESUMEN
========================================================= */

.cart-summary {

    position: sticky;

    top: 25px;

    padding: 25px;

    border:
        1px solid
        rgba(91, 64, 52, .11);

    border-radius: 23px;

    background:
        linear-gradient(
            145deg,
            #fffdfb,
            #f8eee7
        );

    box-shadow:
        0 14px 40px
        rgba(76, 51, 40, .065);

}


.cart-summary h2 {

    margin: 0 0 24px;

    color: #3f2b24;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size: 26px;

    font-weight: 500;

}


.cart-summary-line {

    display: flex;

    justify-content: space-between;

    gap: 15px;

    color: #80695d;

    font-size: 12px;

}


.cart-summary-divider {

    height: 1px;

    margin: 20px 0;

    background:
        rgba(91, 64, 52, .12);

}


.cart-summary-total {

    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 20px;

}


.cart-summary-total span {

    color: #65493d;

    font-size: 13px;

}


.cart-summary-total strong {

    color: #3f2b24;

    font-size: 21px;

}


/* =========================================================
   BOTÓN CHECKOUT
========================================================= */

.cart-checkout-button {

    width: 100%;

    box-sizing: border-box;

    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 15px;

    margin-top: 25px;

    padding: 14px 17px;

    border-radius: 13px;

    background: #5b4034;

    color: #fffdfa;

    font-size: 12px;

    font-weight: 700;

    text-decoration: none;

    transition:
        transform .2s ease,
        background .2s ease,
        box-shadow .2s ease;

}


.cart-checkout-button:hover {

    transform: translateY(-2px);

    background: #493229;

    box-shadow:
        0 9px 22px
        rgba(91, 64, 52, .20);

}


.cart-checkout-button span {

    font-size: 17px;

}


/* =========================================================
   SEGUIR COMPRANDO
========================================================= */

.cart-continue-shopping {

    display: block;

    margin-top: 17px;

    text-align: center;

    color: #8b6d60;

    font-size: 11px;

    font-weight: 600;

    text-decoration: none;

}


.cart-continue-shopping:hover {

    color: #5b4034;

}


/* =========================================================
   CARRITO VACÍO
========================================================= */

.cart-empty {

    max-width: 600px;

    margin: 50px auto 0;

    padding: 65px 30px;

    text-align: center;

    border:
        1px solid
        rgba(91, 64, 52, .10);

    border-radius: 28px;

    background:
        linear-gradient(
            145deg,
            #fffdfb,
            #f7eee8
        );

}


.cart-empty-icon {

    width: 65px;

    height: 65px;

    display: flex;

    align-items: center;

    justify-content: center;

    margin: 0 auto 18px;

    border-radius: 50%;

    background: #f0dfd4;

    font-size: 27px;

}


.cart-empty h2 {

    margin: 0 0 9px;

    color: #49352c;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size: 28px;

    font-weight: 500;

}


.cart-empty p {

    max-width: 420px;

    margin: 0 auto;

    color: #80695d;

    font-size: 13px;

    line-height: 1.7;

}


.cart-empty .cart-checkout-button {

    width: auto;

    display: inline-flex;

    margin-top: 25px;

}


/* =========================================================
   RESPONSIVE
========================================================= */

@media (max-width: 900px) {

    .cart-layout {

        grid-template-columns: 1fr;

    }


    .cart-summary {

        position: static;

    }

}


@media (max-width: 600px) {

    .cart-page {

        width:
            calc(100% - 28px);

        padding:
            38px 0 55px;

    }


    .cart-header {

        margin-bottom: 30px;

    }


    .cart-header h1 {

        font-size: 38px;

    }


    .cart-product-card {

        grid-template-columns: 105px minmax(0, 1fr);

        gap: 14px;

        padding: 12px;

        border-radius: 18px;

    }


    .cart-product-image {

        min-height: 125px;

    }


    .cart-product-image img {

        max-height: 130px;

    }


    .cart-product-info h3 {

        font-size: 17px;

    }


    .cart-product-bottom {

        align-items: flex-start;

        flex-direction: column;

        gap: 10px;

        padding-top: 14px;

    }


    .cart-product-subtotal {

        font-size: 14px;

    }


    .cart-summary {

        padding: 21px;

    }

}


@media (max-width: 420px) {

    .cart-product-card {

        grid-template-columns: 88px minmax(0, 1fr);

        gap: 11px;

    }


    .cart-product-image {

        min-height: 110px;

    }


    .cart-product-image img {

        max-height: 115px;

    }

}



@media (max-width: 600px) {

    .cart-toast-container {

        top: 78px;

        left: 14px;

        right: 14px;

        align-items: center;

    }


    .cart-toast {

        width: min(
            100%,
            340px
        );

        min-width: 0;

        box-sizing: border-box;

    }

}



.account-navbar-divider {
    width: 100%;
    height: 1px;
    display: block;
    background: rgba(91, 64, 52, 0.15);
}



/* =========================================================
   MINI CARRITO / MODAL
========================================================= */

.cart-modal {

    position: fixed;

    inset: 0;

    z-index: 99999;

    display: none;

    align-items: center;

    justify-content: center;

}


.cart-modal.is-open {

    display: flex;

}


/* =========================================================
   FONDO
========================================================= */

.cart-modal-overlay {

    position: absolute;

    inset: 0;

    background:
        rgba(35, 24, 20, .48);

    backdrop-filter:
        blur(5px);

}


/* =========================================================
   VENTANA
========================================================= */

.cart-modal-window {

    position: relative;

    z-index: 1;

    width:
        min(520px, calc(100% - 32px));

    max-height:
        min(720px, calc(100vh - 40px));

    display:
        flex;

    flex-direction:
        column;

    padding:
        28px;

    box-sizing:
        border-box;

    overflow:
        hidden;

    border:
        1px solid
        rgba(255, 255, 255, .65);

    border-radius:
        28px;

    background:
        #fffdfa;

    box-shadow:
        0 30px 80px
        rgba(39, 25, 20, .22);

    animation:
        cartModalIn .22s ease-out;

}


@keyframes cartModalIn {

    from {

        opacity:
            0;

        transform:
            translateY(14px)
            scale(.97);

    }

    to {

        opacity:
            1;

        transform:
            translateY(0)
            scale(1);

    }

}


/* =========================================================
   CABECERA
========================================================= */

.cart-modal-header {

    display:
        flex;

    align-items:
        flex-start;

    justify-content:
        space-between;

    gap:
        20px;

    padding-bottom:
        22px;

}


.cart-modal-success {

    display:
        inline-block;

    margin-bottom:
        7px;

    color:
        #a9664f;

    font-size:
        10px;

    font-weight:
        800;

    letter-spacing:
        .12em;

    text-transform:
        uppercase;

}


.cart-modal-header h2 {

    margin:
        0;

    color:
        #35231e;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size:
        32px;

    font-weight:
        500;

}


.cart-modal-close {

    width:
        38px;

    height:
        38px;

    flex-shrink:
        0;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    border:
        1px solid
        #e3d5cb;

    border-radius:
        50%;

    background:
        #fffaf6;

    color:
        #765a4e;

    font-size:
        23px;

    line-height:
        1;

    cursor:
        pointer;

    transition:
        background .2s ease,
        color .2s ease,
        transform .2s ease;

}


.cart-modal-close:hover {

    background:
        #604236;

    color:
        white;

    transform:
        rotate(5deg);

}


/* =========================================================
   LISTA DE PRODUCTOS
========================================================= */

.cart-modal-items {

    min-height:
        0;

    max-height:
        330px;

    overflow-y:
        auto;

    padding-right:
        5px;

}


.cart-modal-items::-webkit-scrollbar {

    width:
        5px;

}


.cart-modal-items::-webkit-scrollbar-thumb {

    border-radius:
        999px;

    background:
        #d9c7ba;

}


/* =========================================================
   PRODUCTO
========================================================= */

.cart-modal-item {

    display:
        grid;

    grid-template-columns:
        72px 1fr auto;

    align-items:
        center;

    gap:
        15px;

    padding:
        14px 0;

    border-bottom:
        1px solid
        #eee4dc;

}


.cart-modal-item:first-child {

    padding-top:
        0;

}


.cart-modal-item:last-child {

    border-bottom:
        none;

}


.cart-modal-item-image {

    width:
        72px;

    height:
        72px;

    overflow:
        hidden;

    border-radius:
        14px;

    background:
        #f3e8df;

}


.cart-modal-item-image img {

    width:
        100%;

    height:
        100%;

    display:
        block;

    object-fit:
        cover;

}


.cart-modal-item-info {

    min-width:
        0;

}


.cart-modal-item-name {

    margin:
        0 0 5px;

    color:
        #49352c;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size:
        15px;

    font-weight:
        500;

    line-height:
        1.25;

}


.cart-modal-item-price {

    margin:
        0 0 9px;

    color:
        #96776b;

    font-size:
        11px;

}


/* =========================================================
   CONTROLES DE CANTIDAD
========================================================= */

.cart-modal-quantity {

    display:
        inline-flex;

    align-items:
        center;

    border:
        1px solid
        #dfd0c5;

    border-radius:
        999px;

    background:
        #fffaf7;

}


.cart-modal-quantity button {

    width:
        27px;

    height:
        27px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    border:
        none;

    background:
        transparent;

    color:
        #76564a;

    font-size:
        16px;

    cursor:
        pointer;

}


.cart-modal-quantity span {

    min-width:
        24px;

    color:
        #49352c;

    font-size:
        11px;

    font-weight:
        700;

    text-align:
        center;

}


.cart-modal-item-total {

    align-self:
        center;

    color:
        #49352c;

    font-size:
        13px;

    font-weight:
        700;

    white-space:
        nowrap;

}


/* =========================================================
   TOTAL
========================================================= */

.cart-modal-total {

    display:
        flex;

    align-items:
        center;

    justify-content:
        space-between;

    margin-top:
        8px;

    padding:
        20px 0;

    border-top:
        1px solid
        #e8ddd5;

}


.cart-modal-total span {

    color:
        #80665b;

    font-size:
        11px;

    font-weight:
        800;

    letter-spacing:
        .1em;

    text-transform:
        uppercase;

}


.cart-modal-total strong {

    color:
        #33231f;

    font-size:
        22px;

}


/* =========================================================
   BOTONES
========================================================= */

.cart-modal-actions {

    display:
        flex;

    flex-direction:
        column;

    gap:
        10px;

}


.cart-modal-button {

    width:
        100%;

    min-height:
        48px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    gap:
        9px;

    box-sizing:
        border-box;

    border-radius:
        999px;

    font-size:
        13px;

    font-weight:
        700;

    text-decoration:
        none;

    cursor:
        pointer;

    transition:
        transform .2s ease,
        background .2s ease,
        box-shadow .2s ease;

}


.cart-modal-button:hover {

    transform:
        translateY(-1px);

}


/* SECUNDARIO */

.cart-modal-button-secondary {

    border:
        1px solid
        #d9c7ba;

    background:
        #fffaf6;

    color:
        #76564a;

}


.cart-modal-button-secondary:hover {

    background:
        #f3e7de;

}


/* PRINCIPAL */

.cart-modal-button-primary {

    border:
        1px solid
        #604236;

    background:
        #604236;

    color:
        white;

    box-shadow:
        0 8px 20px
        rgba(96, 66, 54, .14);

}


.cart-modal-button-primary:hover {

    background:
        #4f352c;

}


/* =========================================================
   CARRITO COMPLETO
========================================================= */

.cart-modal-full-cart {

    display:
        block;

    margin-top:
        15px;

    color:
        #a45f49;

    font-size:
        11px;

    font-weight:
        700;

    text-align:
        center;

    text-decoration:
        none;

}


.cart-modal-full-cart:hover {

    text-decoration:
        underline;

}


/* =========================================================
   RESPONSIVE
========================================================= */

@media (max-width: 600px) {

    .cart-modal-window {

        width:
            calc(100% - 20px);

        max-height:
            calc(100vh - 20px);

        padding:
            22px;

        border-radius:
            23px;

    }


    .cart-modal-header h2 {

        font-size:
            28px;

    }


    .cart-modal-items {

        max-height:
            42vh;

    }


    .cart-modal-item {

        grid-template-columns:
            58px 1fr;

        gap:
            12px;

    }


    .cart-modal-item-image {

        width:
            58px;

        height:
            58px;

    }


    .cart-modal-item-total {

        grid-column:
            2;

        justify-self:
            end;

        margin-top:
            -32px;

    }

}



/* =========================================================
   PROMOCIÓN DEL PRODUCTO — MODAL DEL CARRITO
   ========================================================= */

.cart-modal-promotion {
    display: flex;
    align-items: center;
    gap: 12px;

    width: 100%;

    margin-top: 12px;
    padding: 10px 12px;

    border: 1px solid rgba(184, 94, 72, 0.12);
    border-radius: 10px;

    background: #f5e1dc;
    box-sizing: border-box;
}


/* ICONO */

.cart-modal-promotion-icon {
    width: 42px;
    height: 42px;

    flex: 0 0 42px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: #cb745a;
}


.cart-modal-promotion-icon img {
    width: 25px;
    height: 25px;

    display: block;

    object-fit: contain;
}


/* CONTENIDO */

.cart-modal-promotion-content {
    min-width: 0;

    display: flex;
    flex-direction: column;
    gap: 2px;
}


.cart-modal-promotion-content strong {
    display: block;

    margin: 0;

    color: #b85f49;

    font-size: 12px;
    line-height: 1.25;
    font-weight: 700;
}


.cart-modal-promotion-content span {
    display: block;

    margin: 0;

    color: #5b4239;

    font-size: 10px;
    line-height: 1.35;
}