/* ═══════════════════════════════════════════════
   MR7C — Cart Drawer (mcd = mr7c cart drawer)
   ═══════════════════════════════════════════════ */

.mcd-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}
.mcd-overlay.open { opacity: 1; visibility: visible; }

.mcd-drawer {
    position: fixed;
    top: 0; right: 0;
    width: 400px;
    max-width: 100vw;
    height: 100vh;
    background: #111;
    border-left: 1px solid rgba(212,175,55,0.12);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    transform: translateX(110%);
    transition: transform 0.38s cubic-bezier(0.32, 0.72, 0, 1);
    box-shadow: -12px 0 50px rgba(0,0,0,0.7);
    overflow: hidden;
}
.mcd-drawer.open { transform: translateX(0); }

/* Header */
.mcd-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 22px 22px 18px;
    flex-shrink: 0;
}
.mcd-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 1.35rem;
    font-weight: 600;
    color: #fff;
    letter-spacing: 0.03em;
}
.mcd-cart-icon {
    width: 20px; height: 20px;
    stroke: rgba(212,175,55,0.8);
}
.mcd-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px; height: 22px;
    padding: 0 5px;
    background: linear-gradient(135deg, #d4af37, #f4d03f);
    color: #0a0a0a;
    font-family: 'Outfit', sans-serif;
    font-size: 0.68rem;
    font-weight: 700;
    border-radius: 11px;
}
.mcd-close {
    width: 34px; height: 34px;
    display: flex; align-items: center; justify-content: center;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 50%;
    cursor: pointer;
    color: rgba(255,255,255,0.5);
    transition: all 0.2s ease;
}
.mcd-close:hover { background: rgba(255,255,255,0.1); color: #fff; transform: rotate(90deg); }
.mcd-close svg { width: 14px; height: 14px; stroke: currentColor; }

.mcd-divider { height: 1px; background: rgba(255,255,255,0.06); flex-shrink: 0; }

/* Items */
.mcd-items {
    flex: 1;
    overflow-y: auto;
    padding: 6px 0;
    scrollbar-width: thin;
    scrollbar-color: rgba(212,175,55,0.25) transparent;
}
.mcd-items::-webkit-scrollbar { width: 3px; }
.mcd-items::-webkit-scrollbar-thumb { background: rgba(212,175,55,0.25); border-radius: 2px; }

.mcd-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 22px;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    transition: background 0.2s, opacity 0.2s, transform 0.2s;
}
.mcd-item:last-child { border-bottom: none; }
.mcd-item:hover { background: rgba(255,255,255,0.02); }

.mcd-img {
    width: 64px; height: 64px;
    border-radius: 8px;
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.07);
    overflow: hidden;
    flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
}
.mcd-img img { width: 100%; height: 100%; object-fit: cover; }
.mcd-img-placeholder {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    font-family: 'Cormorant Garamond', serif;
    font-size: 0.72rem; font-weight: 700;
    color: rgba(212,175,55,0.4);
    text-align: center; line-height: 1.3;
}

.mcd-info { flex: 1; min-width: 0; }
.mcd-name {
    font-family: 'Outfit', sans-serif;
    font-size: 0.76rem; font-weight: 600;
    color: rgba(255,255,255,0.88);
    letter-spacing: 0.05em; text-transform: uppercase;
    margin: 0 0 3px;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.mcd-cat { font-size: 0.7rem; color: rgba(255,255,255,0.28); margin: 0 0 10px; }

/* Qty controls */
.mcd-qty-row { display: flex; align-items: center; gap: 7px; }
.mcd-qty-btn {
    width: 24px; height: 24px;
    display: flex; align-items: center; justify-content: center;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 6px;
    color: rgba(255,255,255,0.65);
    font-size: 1rem; line-height: 1;
    cursor: pointer;
    transition: all 0.15s ease;
    flex-shrink: 0;
    padding: 0;
}
.mcd-qty-btn:hover {
    background: rgba(212,175,55,0.12);
    border-color: rgba(212,175,55,0.4);
    color: #d4af37;
}
.mcd-qty-num {
    font-family: 'Outfit', sans-serif;
    font-size: 0.82rem; font-weight: 600;
    color: rgba(255,255,255,0.85);
    min-width: 18px; text-align: center;
}
.mcd-item-total {
    font-size: 0.82rem; font-weight: 600;
    color: #d4af37;
    margin-left: 2px;
}

.mcd-remove {
    width: 26px; height: 26px;
    display: flex; align-items: center; justify-content: center;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 6px;
    cursor: pointer;
    color: rgba(255,255,255,0.22);
    transition: all 0.18s ease;
    flex-shrink: 0;
    margin-top: 2px;
}
.mcd-remove:hover { background: rgba(255,60,60,0.1); border-color: rgba(255,60,60,0.3); color: #ff5555; }
.mcd-remove svg { width: 12px; height: 12px; stroke: currentColor; }

/* Empty */
.mcd-empty {
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    height: 260px; gap: 10px;
    text-align: center; padding: 0 30px;
}
.mcd-empty svg { width: 40px; height: 40px; stroke: rgba(255,255,255,0.1); margin-bottom: 4px; }
.mcd-empty p { color: rgba(255,255,255,0.4); font-size: 0.88rem; margin: 0; font-weight: 500; }
.mcd-empty span { color: rgba(255,255,255,0.2); font-size: 0.76rem; }

/* Footer */
.mcd-footer {
    flex-direction: column;
    gap: 0;
    padding: 14px 22px 22px;
    border-top: 1px solid rgba(255,255,255,0.07);
    background: #111;
    flex-shrink: 0;
    display: none;
}
.mcd-subtotal-row,
.mcd-shipping-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px 0;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.38);
}
.mcd-free { font-size: 0.74rem; font-weight: 600; color: #3db868; letter-spacing: 0.04em; }
.mcd-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 11px 0 16px;
    border-top: 1px solid rgba(255,255,255,0.07);
    margin-top: 6px;
}
.mcd-total-label {
    font-family: 'Outfit', sans-serif;
    font-size: 0.7rem; font-weight: 600;
    letter-spacing: 0.12em;
    color: rgba(255,255,255,0.38);
    text-transform: uppercase;
}
.mcd-total-val {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.55rem; font-weight: 700;
    color: #d4af37;
}
.mcd-btn-group { display: flex; flex-direction: column; gap: 10px; }
.mcd-btn-view {
    display: flex; align-items: center; justify-content: center;
    padding: 13px;
    background: transparent;
    border: 1px solid rgba(212,175,55,0.4);
    border-radius: 8px;
    color: #d4af37;
    font-family: 'Outfit', sans-serif;
    font-size: 0.76rem; font-weight: 600;
    letter-spacing: 0.1em; text-transform: uppercase; text-decoration: none;
    transition: all 0.22s ease;
}
.mcd-btn-view:hover { background: rgba(212,175,55,0.08); border-color: rgba(212,175,55,0.65); color: #f4d03f; }

.mcd-btn-checkout {
    display: flex; align-items: center; justify-content: center;
    padding: 14px;
    background: linear-gradient(135deg, #d4af37 0%, #f4d03f 50%, #d4af37 100%);
    border: none; border-radius: 8px;
    color: #0a0a0a;
    font-family: 'Outfit', sans-serif;
    font-size: 0.76rem; font-weight: 700;
    letter-spacing: 0.1em; text-transform: uppercase; text-decoration: none;
    transition: all 0.22s ease;
    position: relative; overflow: hidden;
}
.mcd-btn-checkout::before {
    content: '';
    position: absolute; top: 0; left: -100%;
    width: 100%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.22), transparent);
    transition: left 0.45s ease;
}
.mcd-btn-checkout:hover { box-shadow: 0 0 22px rgba(212,175,55,0.4); transform: translateY(-1px); color: #0a0a0a; }
.mcd-btn-checkout:hover::before { left: 100%; }

@media (max-width: 480px) {
    .mcd-drawer { width: 100vw; }
}