/* ============================================
   cart-drawer.css — HappyBud "Added to bag" drawer
   Slides in from the right after Add to Cart.
   Palette matches the rest of the site:
   cream #fcfaf4, dark #1a1a1a, orange #ff6b35, green #1f5d3f
============================================ */

.hb-cart-drawer-backdrop {
    position: fixed;
    inset: 0;
    z-index: 100000;
    background: rgba(26, 26, 26, 0.55);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease;
}

.hb-cart-drawer-backdrop.is-open {
    opacity: 1;
    visibility: visible;
}

.hb-cart-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 100001;
    width: min(420px, 92vw);
    background: #fcfaf4;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.32s cubic-bezier(0.32, 0.72, 0, 1);
    box-shadow: -10px 0 36px rgba(0, 0, 0, 0.2);
}

.hb-cart-drawer.is-open {
    transform: translateX(0);
}

body.hb-drawer-open {
    overflow: hidden;
}

/* ---- Header ---- */
.hb-cart-drawer-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 20px 22px;
    background: #1f5d3f;
    color: #fcfaf4;
    border-bottom: 2px solid #1a1a1a;
}

.hb-cart-drawer-head-text {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 16px;
    font-weight: 800;
}

.hb-cart-drawer-head-text iconify-icon {
    font-size: 20px;
    color: #ffd56b;
}

.hb-cart-drawer-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    box-sizing: border-box;
    height: 32px;
    border-radius: 50%;
    padding: 0;
    min-height: 0 !important;
    flex-shrink: 0;
    appearance: none;
    margin: 0;
    line-height: 0;
    background: rgba(252, 250, 244, 0.14);
    color: #fcfaf4;
    border: none;
    cursor: pointer;
    transition: background 0.15s;
}

.hb-cart-drawer-close:hover {
    background: rgba(252, 250, 244, 0.26);
}

/* ---- Body ---- */
.hb-cart-drawer-body {
    flex: 1;
    overflow-y: auto;
    padding: 22px;
}

.hb-cart-drawer-item {
    display: flex;
    gap: 14px;
    flex-direction: column;
    padding-bottom: 20px;
    border-bottom: 1px solid #e0d8c8;
}

.hb-cart-drawer-img {
    flex-shrink: 0;
    width: 84px;
    height: 84px;
    border-radius: 14px;
    background-color: #f5e8d4;
    background-size: cover;
    background-position: center;
    border: 1px solid #e0d8c8;
}

.hb-cart-drawer-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
}

.hb-cart-drawer-name {
    margin: 0;
    font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 15px;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.3;
}

.hb-cart-drawer-meta {
    margin: 0;
    font-size: 13px;
    color: #6b6b6b;
}

.hb-cart-drawer-price {
    margin: 2px 0 0;
    font-size: 15px;
    font-weight: 800;
    color: #1a1a1a;
}

/* ---- Nudge banner (free shipping / minimum order) ---- */
.hb-cart-drawer-nudge {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-top: 18px;
    padding: 14px 16px;
    border-radius: 12px;
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1.4;
    background: #f0e8d8;
    color: #1a1a1a;
    border: 1px solid #e0d8c8;
}

.hb-cart-drawer-nudge iconify-icon {
    flex-shrink: 0;
    font-size: 18px;
    margin-top: 1px;
    color: #ff6b35;
}

.hb-cart-drawer-nudge strong {
    font-weight: 800;
}

.hb-cart-drawer-nudge.is-warning {
    background: #fbeceb;
    border-color: #f0c9c6;
}

.hb-cart-drawer-nudge.is-warning iconify-icon {
    color: #c93838;
}

.hb-cart-drawer-nudge.is-success {
    background: #e7f3ec;
    border-color: #c6e3d3;
}

.hb-cart-drawer-nudge.is-success iconify-icon {
    color: #1f5d3f;
}

/* ---- Footer / buttons ---- */
.hb-cart-drawer-foot {
    padding: 18px 22px 22px;
    border-top: 1px solid #e0d8c8;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.hb-drawer-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    width: 100%;
    padding: 15px;
    border-radius: 14px;
    font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 15px;
    font-weight: 800;
    letter-spacing: 0.01em;
    text-decoration: none;
    transition: transform 0.15s, box-shadow 0.15s;
}

.hb-drawer-btn:active {
    transform: translateY(1px);
}

.hb-drawer-btn-primary {
    background: #1f5d3f;
    color: #fcfaf4;
    box-shadow: 5px 5px 0 #1a1a1a;
}

.hb-drawer-btn-secondary {
    background: transparent;
    color: #1a1a1a;
    border: 2px solid #1a1a1a;
}

/* ---- Mobile ---- */
@media (max-width: 480px) {
    .hb-cart-drawer {
        width: 100vw;
    }
}


/* Multi-item drawer body — scrolls when many items */
.hb-cart-drawer-body {
    max-height: 60vh;
    overflow-y: auto;
}
.hb-cart-drawer-line {
    display: flex;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #f0e8d8;
}
.hb-cart-drawer-line:last-child {
    border-bottom: none;
}