/**
 * Cart component.
 *
 * The cart owns one responsive layout: a stacked mobile flow and a two-column
 * desktop grid. No cart positioning belongs in style.css.
 */

body.woocommerce-cart {
    background: #fff;
}

.ic-commerce-page--cart {
    width: 100%;
    background: #fff;
}

.ic-cart-page {
    width: min(100% - 24px, 1220px);
    margin: 0 auto;
    padding: 28px 0 36px;
}

.ic-cart-page__title {
    margin: 0 0 18px;
    color: #171512;
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    line-height: 1.1;
    letter-spacing: 0;
}

.ic-cart-page__grid {
    display: grid;
    gap: 20px;
    align-items: start;
}

.ic-cart-main,
.ic-cart-rail {
    min-width: 0;
}

.ic-cart-form {
    margin: 0;
}

.ic-cart-table,
.ic-cart-summary,
.ic-cart-addons {
    border: 1px solid #e6d8c5;
    border-radius: 8px;
    background: #fffdf9;
}

.ic-cart-table {
    overflow: hidden;
}

.ic-cart-table__head {
    display: none;
}

.ic-cart-row {
    display: grid;
    grid-template-columns: 60px minmax(0, 1fr) 68px;
    gap: 6px 10px;
    padding: 10px;
    border-bottom: 1px solid #eadfce;
}

.ic-cart-row:last-child {
    border-bottom: 0;
}

.ic-cart-product {
    display: contents;
}

.ic-cart-product__image,
.ic-cart-product__image a,
.ic-cart-product__image img {
    display: block;
}

.ic-cart-product__image img {
    width: 60px;
    height: 60px;
    border-radius: 5px;
    object-fit: cover;
}

.ic-cart-product__image {
    grid-column: 1;
    grid-row: 1 / span 2;
    align-self: start;
}

.ic-cart-product__content {
    grid-column: 2;
    grid-row: 1;
    min-width: 0;
}

.ic-cart-product__title {
    display: -webkit-box !important;
    margin: 0;
    overflow: hidden;
    color: #171512;
    font-size: 0.93rem;
    font-weight: 700;
    line-height: 1.3;
    max-height: 2.6em;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.ic-cart-product__title a {
    color: inherit;
    text-decoration: none;
}

.ic-cart-product__content .variation {
    margin: 4px 0 0;
    color: #73695d;
    font-size: 0.75rem;
}

.ic-cart-product__content .variation dt,
.ic-cart-product__content .variation dd,
.ic-cart-product__content .variation p {
    display: inline;
    margin: 0;
}

.ic-cart-row__price,
.ic-cart-row__subtotal {
    align-self: center;
    color: #171512;
    font-size: 0.82rem;
    font-weight: 700;
    white-space: nowrap;
}

.ic-cart-row__price {
    grid-column: 2;
    grid-row: 2;
}

.ic-cart-row__quantity {
    display: flex;
    grid-column: 3;
    grid-row: 1;
    flex-direction: row;
    align-items: center;
    gap: 4px;
}

.ic-cart-row__quantity .quantity {
    margin: 0;
}

.ic-cart-row__quantity input.qty {
    width: 48px;
    height: 36px;
    padding: 6px;
    border: 1px solid #dbc7aa;
    border-radius: 6px;
    background: #fff;
    color: #171512;
    text-align: center;
}

.ic-cart-row__remove {
    display: inline-flex;
    width: 16px;
    height: 36px;
    align-items: center;
    justify-content: center;
    color: #78634c;
    font-size: 0;
    font-weight: 600;
    text-decoration: none;
}

.ic-cart-row__remove::before {
    content: "\00d7";
    font-size: 1.15rem;
    line-height: 1;
}

.ic-cart-row__subtotal {
    grid-column: 3;
    grid-row: 2;
    text-align: right;
}

.ic-cart-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    margin-top: 12px;
}

.ic-cart-coupon {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
}

.ic-cart-coupon input,
.ic-cart-actions .button {
    min-height: 46px;
    border: 1px solid #d7bea0;
    border-radius: 6px;
    font: inherit;
}

.ic-cart-coupon input {
    width: 100%;
    min-width: 0;
    padding: 0 13px;
    background: #fff;
}

.ic-cart-actions .button {
    padding: 0 20px;
    background: #c59a68;
    color: #171512;
    font-weight: 700;
    cursor: pointer;
}

.ic-cart-actions .ic-cart-update {
    background: #fff;
}

.ic-cart-actions .button:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.ic-cart-rail {
    display: grid;
    gap: 16px;
}

.ic-cart-summary,
.ic-cart-addons {
    padding: 18px;
}

.ic-cart-summary h2,
.ic-cart-addons h2 {
    margin: 0;
    color: #171512;
    font-size: 1.35rem;
    line-height: 1.2;
}

.ic-cart-summary__rows {
    margin-top: 14px;
}

.ic-cart-summary__row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    padding: 11px 0;
    border-bottom: 1px solid #eadfce;
    color: #2a2723;
    font-size: 0.9rem;
}

.ic-cart-summary__row strong {
    text-align: right;
}

.ic-cart-summary__total {
    padding-top: 15px;
    border-bottom: 0;
    font-size: 1.1rem;
}

.ic-cart-summary__total strong {
    font-size: 1.35rem;
}

.ic-cart-summary .wc-proceed-to-checkout {
    margin-top: 14px;
}

.ic-cart-summary .checkout-button {
    display: flex;
    min-height: 50px;
    align-items: center;
    justify-content: center;
    width: 100%;
    border-radius: 6px;
    background: #c59a68;
    color: #171512;
    font-weight: 800;
    text-align: center;
    text-decoration: none;
}

.ic-cart-addons__head p {
    margin: 4px 0 0;
    color: #766c61;
    font-size: 0.78rem;
}

.ic-cart-addons__grid {
    display: grid;
    gap: 0;
    margin-top: 10px;
}

.ic-cart-addon-card {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr);
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid #eadfce;
}

.ic-cart-addon-card:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.ic-cart-addon-card__image,
.ic-cart-addon-card__image img {
    display: block;
}

.ic-cart-addon-card__image img {
    width: 64px;
    height: 64px;
    border-radius: 5px;
    object-fit: cover;
}

.ic-cart-addon-card__body {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 3px 8px;
    align-items: center;
    min-width: 0;
}

.ic-cart-addon-card h3 {
    grid-column: 1 / -1;
    margin: 0;
    font-size: 0.82rem;
    line-height: 1.25;
}

.ic-cart-addon-card h3 a {
    display: -webkit-box !important;
    overflow: hidden;
    color: #171512;
    text-decoration: none;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.ic-cart-addon-card__price {
    font-size: 0.76rem;
    font-weight: 700;
}

.ic-cart-addon-card__price del {
    color: #8f877e;
    font-weight: 500;
}

.ic-cart-addon-card__button {
    display: inline-flex;
    min-height: 32px;
    align-items: center;
    justify-content: center;
    padding: 0 16px;
    border: 1px solid #c59a68;
    border-radius: 5px;
    color: #8a6338;
    font-size: 0.76rem;
    font-weight: 700;
    text-decoration: none;
}

.ic-cart-trust-strip {
    width: 100%;
    border-top: 1px solid #e6d8c5;
    background: #fffdf9;
}

.ic-cart-trust-inner {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    width: min(100% - 24px, 1220px);
    margin: 0 auto;
    padding: 16px 0;
}

.ic-cart-trust-item {
    display: flex;
    align-items: center;
    gap: 9px;
    min-width: 0;
}

.ic-cart-trust-item__icon {
    display: grid;
    flex: 0 0 34px;
    width: 34px;
    height: 34px;
    place-items: center;
    border: 1px solid #d9bd98;
    border-radius: 50%;
    font-size: 0.9rem;
}

.ic-cart-trust-item strong,
.ic-cart-trust-item small {
    display: block;
}

.ic-cart-trust-item strong {
    color: #27231f;
    font-size: 0.78rem;
}

.ic-cart-trust-item small {
    margin-top: 1px;
    color: #766c61;
    font-size: 0.68rem;
}

@media (max-width: 639px) {
    .ic-cart-actions {
        grid-template-columns: 1fr;
    }

    .ic-cart-update {
        width: 100%;
    }
}

@media (min-width: 768px) {
    .ic-cart-page {
        padding-top: 36px;
    }

    .ic-cart-table__head,
    .ic-cart-row {
        display: grid;
        grid-template-columns: minmax(260px, 1.8fr) minmax(90px, 0.65fr) minmax(100px, 0.7fr) minmax(100px, 0.7fr);
        align-items: center;
    }

    .ic-cart-table__head {
        gap: 18px;
        padding: 13px 18px;
        color: #171512;
        font-size: 0.83rem;
        font-weight: 700;
    }

    .ic-cart-row {
        gap: 18px;
        min-height: 116px;
        padding: 14px 18px;
    }

    .ic-cart-product {
        display: grid;
        grid-column: auto;
        grid-template-columns: 78px minmax(0, 1fr);
    }

    .ic-cart-row__quantity {
        flex-direction: column;
        gap: 5px;
    }

    .ic-cart-row__subtotal {
        text-align: right;
    }

    .ic-cart-actions {
        grid-template-columns: minmax(0, 1fr) 190px;
    }

    .ic-cart-trust-inner {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (min-width: 1024px) {
    .ic-cart-page {
        padding-top: 42px;
    }

    .ic-cart-page__grid {
        grid-template-columns: minmax(0, 2fr) minmax(310px, 0.95fr);
        gap: 34px;
    }

    .ic-cart-summary,
    .ic-cart-addons {
        padding: 20px;
    }
}

@media (min-width: 1280px) {
    .ic-cart-page {
        width: min(100% - 64px, 1220px);
    }

    .ic-cart-page__title {
        margin-bottom: 20px;
    }
}

.ic-cart-trust-item__icon svg {
    width: 17px;
    height: 17px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
}

