/* ==========================================================================
   CART PAGE STYLES
   ========================================================================== */

.cart-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
    margin-top: 40px;
    align-items: start;
}

.cart-items {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cart-item {
    background-color: var(--cream);
    padding: 10px 14px;
    border-radius: 2px;
    display: flex;
    align-items: center;
    gap: 14px;
    border: 1px solid rgba(0,0,0,0.05);
    transition: all 0.3s var(--ease);
}

.cart-item:hover {
    border-color: rgba(0,0,0,0.1);
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
}

.cart-item-img {
    width: 60px;
    height: 60px;
    background-color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 2px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    overflow: hidden;
    flex-shrink: 0;
}

.cart-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item-img svg {
    width: 40px;
    height: 40px;
    opacity: 0.2;
}

.cart-item-details {
    flex-grow: 1;
    min-width: 0;
}

.cart-item-details h4 {
    font-family: var(--font-serif);
    font-size: 1.1rem;
    margin-bottom: 2px;
    color: var(--ink);
    overflow-wrap: break-word;
}

.cart-qty {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 6px;
    background: #fff;
    border: 1px solid rgba(0,0,0,0.1);
    border-radius: 8px;
    padding: 3px 8px;
}

.cart-qty-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #F1EAD6;
    color: var(--green);
    font-size: 1rem;
    font-weight: 600;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}

.cart-qty-btn:hover {
    background: var(--green);
    color: #fff;
}

.cart-qty-count {
    font-weight: 600;
    min-width: 18px;
    text-align: center;
    color: var(--ink);
    font-size: 0.95rem;
}

.cart-summary {
    position: sticky;
    top: 120px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
    margin-bottom: 10px;
    font-family: var(--font-sans);
    color: var(--ink-soft);
}

.summary-row > span:first-child {
    flex-shrink: 0;
}

.summary-row > span:last-child {
    text-align: right;
}

.summary-total {
    border-top: 1px solid rgba(0,0,0,0.1);
    padding-top: 20px;
    margin-top: 20px;
    font-weight: bold;
    font-size: 1.3rem;
    color: var(--ink);
    position: relative;
    z-index: 6;
    background: #fff;
}

.cart-summary-wrap {
    position: relative;
    align-self: start;
    width: 100%;
    padding-right: 45px; /* reserves room so the dog sits beside, not on top of, the card */
}

.cart-dog {
    position: absolute;
    right: -10px;
    bottom: -18px;
    width: 100px;
    text-align: center;
    pointer-events: none;
    z-index: 5;
}

.cart-dog img {
    width: 100%;
    filter: drop-shadow(2px 4px 6px rgba(0,0,0,0.15));
}

.cart-dog-text {
    display: block;
    margin-top: 4px;
    font-family: var(--font-hand);
    font-size: 0.85rem;
    color: var(--green);
    transform: rotate(-3deg);
}

/* ==========================================================================
   YOU MAY ALSO LIKE — recommendations
   ========================================================================== */
.reco-lead {
    font-family: var(--font-hand);
    font-size: 1.15rem;
    color: var(--ink-faded);
    margin-bottom: 30px;
}

.reco-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 24px;
}

.reco-card {
    background: #fff;
    border: 1px solid rgba(0,0,0,0.06);
    border-radius: 16px;
    overflow: hidden;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    box-shadow: 0 1px 3px rgba(20,20,10,0.04);
    transition: box-shadow 0.35s var(--ease), transform 0.35s var(--ease), border-color 0.35s ease;
}

.reco-card:hover {
    box-shadow: 0 18px 34px rgba(20, 30, 10, 0.12);
    transform: translateY(-6px);
    border-color: rgba(62,107,39,0.15);
}

.reco-img {
    aspect-ratio: 1 / 1;
    background: linear-gradient(180deg, #FBF8F2 0%, #F5F0E6 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.reco-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 10px;
    transition: transform 0.5s var(--ease);
}

.reco-card:hover .reco-img img {
    transform: scale(1.05);
}

.reco-info {
    padding: 14px 16px 16px;
    border-top: 1px solid rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.reco-brand {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--ink-faded);
    margin-bottom: 4px;
}

.reco-name {
    font-family: var(--font-serif);
    font-size: 1rem;
    font-weight: 600;
    color: var(--ink);
    line-height: 1.3;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.reco-price {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--ink);
    margin-top: auto;
}

/* ==========================================================================
   RESPONSIVE — consistent breakpoint scale: 1100 / 900 / 768 / 600 / 480 / 380
   ========================================================================== */

@media (max-width: 900px) {
    .cart-layout {
        grid-template-columns: 1fr;
        gap: 28px;
    }
    .cart-summary {
        position: static;
        top: auto;
    }
    .cart-summary-wrap {
        padding-right: 0;
    }
    .cart-dog {
        position: static;
        margin: 20px auto 0;
        width: 80px;
    }
}

@media (max-width: 600px) {
    .cart-item {
        padding: 12px;
        gap: 10px;
    }
    .cart-item-img {
        width: 52px;
        height: 52px;
    }
    .cart-item-details h4 {
        font-size: 1rem;
    }
    .reco-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 16px;
    }
}

@media (max-width: 480px) {
    .cart-layout {
        margin-top: 24px;
        gap: 22px;
    }
    .cart-item {
        flex-wrap: wrap;
    }
    .cart-item-details {
        flex-basis: 100%;
    }
    .summary-total {
        font-size: 1.15rem;
    }
    .reco-lead {
        font-size: 1rem;
        margin-bottom: 20px;
    }
    .reco-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    .reco-name {
        font-size: 0.92rem;
    }
}

@media (max-width: 380px) {
    .cart-item-img {
        width: 46px;
        height: 46px;
    }
    .cart-qty-btn {
        width: 24px;
        height: 24px;
    }
}