/* ============================================================
   SARWESHWAR INDUSTRIES — common.css
   Shared UI: Cart Sidebar | Wishlist | Search | Toast
   Used on ALL pages
   ============================================================ */

/* ── SEARCH OVERLAY ── */
.search-overlay { position:fixed; inset:0; background:rgba(0,0,0,0.85); z-index:9999; display:flex; flex-direction:column; align-items:center; padding-top:80px; opacity:0; pointer-events:none; transition:opacity 0.3s; }
.search-overlay.open { opacity:1; pointer-events:all; }
.search-overlay__box { display:flex; align-items:center; width:90%; max-width:680px; background:#fff; border-radius:50px; padding:10px 20px; gap:12px; box-shadow:0 8px 40px rgba(0,0,0,0.3); }
.search-overlay__box input { flex:1; border:none; outline:none; font-size:18px; font-family:'Poppins',sans-serif; color:#222; background:transparent; }
.search-overlay__box button { background:none; border:none; font-size:22px; color:#b01a1a; cursor:pointer; }
.search-results { width:90%; max-width:680px; background:#fff; border-radius:12px; margin-top:14px; overflow:hidden; max-height:400px; overflow-y:auto; }
.search-result-item { display:flex; align-items:center; gap:14px; padding:12px 18px; border-bottom:1px solid #f0f0f0; cursor:pointer; transition:background 0.2s; }
.search-result-item:hover { background:#fff5f5; }
.search-result-item img { width:50px; height:50px; object-fit:contain; border-radius:6px; border:1px solid #eee; }
.sri-name { font-size:14px; font-weight:600; color:#222; }
.sri-price { font-size:13px; color:#b01a1a; font-weight:700; }
.search-no-result { text-align:center; padding:24px; color:#888; font-size:14px; }

/* ── CART SIDEBAR ── */
.cart-sidebar { position:fixed; top:0; right:-420px; width:420px; height:100vh; background:#fff; z-index:9998; box-shadow:-4px 0 30px rgba(0,0,0,0.15); display:flex; flex-direction:column; transition:right 0.35s ease; }
.cart-sidebar.open { right:0; }
.cart-sidebar__header { display:flex; align-items:center; justify-content:space-between; padding:20px 24px; border-bottom:2px solid #b01a1a; background:#b01a1a; color:#fff; }
.cart-sidebar__header h3 { font-size:18px; font-weight:700; font-family:'Poppins',sans-serif; }
.cart-sidebar__header button { background:none; border:none; color:#fff; font-size:22px; cursor:pointer; }
.cart-sidebar__items { flex:1; overflow-y:auto; padding:16px; }
.cart-empty { display:flex; flex-direction:column; align-items:center; justify-content:center; height:100%; gap:12px; color:#ccc; }
.cart-empty i { font-size:52px; }
.cart-empty p { font-size:15px; font-weight:500; }
.cart-item { display:flex; gap:12px; padding:14px 0; border-bottom:1px solid #f5f5f5; align-items:center; }
.cart-item img { width:70px; height:70px; object-fit:contain; border:1px solid #eee; border-radius:8px; flex-shrink:0; }
.cart-item__info { flex:1; }
.cart-item__name  { font-size:13px; font-weight:600; color:#222; line-height:1.4; margin-bottom:4px; }
.cart-item__price { font-size:14px; font-weight:700; color:#b01a1a; }
.cart-item__qty   { display:flex; align-items:center; gap:8px; margin-top:6px; }
.qty-btn { width:26px; height:26px; border:1.5px solid #ddd; background:#fff; border-radius:4px; cursor:pointer; font-size:16px; display:flex; align-items:center; justify-content:center; transition:all 0.2s; }
.qty-btn:hover { border-color:#b01a1a; color:#b01a1a; }
.qty-num { font-size:14px; font-weight:700; min-width:20px; text-align:center; }
.cart-item__remove { background:none; border:none; color:#ccc; font-size:16px; cursor:pointer; transition:color 0.2s; }
.cart-item__remove:hover { color:#b01a1a; }
.cart-sidebar__footer { padding:16px 20px; border-top:1px solid #eee; background:#fafafa; }
.cart-total { font-size:17px; font-weight:700; color:#222; margin-bottom:12px; display:flex; justify-content:space-between; }
.cart-total span { color:#b01a1a; }
.cart-checkout-btn { width:100%; background:#b01a1a; color:#fff; border:none; padding:13px; font-size:14px; font-weight:700; border-radius:6px; cursor:pointer; letter-spacing:1px; text-transform:uppercase; font-family:'Poppins',sans-serif; transition:background 0.2s; }
.cart-checkout-btn:hover { background:#8a1212; }

/* ── WISHLIST SIDEBAR ── */
.wishlist-sidebar { right:-420px; }
.wishlist-item { display:flex; gap:12px; padding:14px 0; border-bottom:1px solid #f5f5f5; align-items:center; }
.wishlist-item img { width:70px; height:70px; object-fit:contain; border:1px solid #eee; border-radius:8px; flex-shrink:0; }
.wishlist-item__info { flex:1; }
.wishlist-item__name  { font-size:13px; font-weight:600; color:#222; line-height:1.4; margin-bottom:4px; }
.wishlist-item__price { font-size:14px; font-weight:700; color:#b01a1a; }
.wishlist-item__actions { display:flex; flex-direction:column; gap:6px; }
.btn-move-cart { background:#b01a1a; color:#fff; border:none; border-radius:4px; padding:5px 10px; font-size:11px; font-weight:700; cursor:pointer; white-space:nowrap; transition:background 0.2s; }
.btn-move-cart:hover { background:#8a1212; }
.btn-remove-wish { background:none; border:none; color:#ccc; font-size:14px; cursor:pointer; transition:color 0.2s; text-align:center; }
.btn-remove-wish:hover { color:#b01a1a; }

/* ── OVERLAY ── */
.cart-overlay { position:fixed; inset:0; background:rgba(0,0,0,0.5); z-index:9997; opacity:0; pointer-events:none; transition:opacity 0.3s; }
.cart-overlay.open { opacity:1; pointer-events:all; }

/* ── TOAST ── */
.toast { position:fixed; bottom:28px; right:28px; background:#222; color:#fff; padding:14px 20px; border-radius:10px; font-size:14px; font-weight:500; z-index:99999; display:flex; align-items:center; gap:10px; box-shadow:0 4px 20px rgba(0,0,0,0.2); transform:translateY(80px); opacity:0; transition:all 0.4s ease; max-width:320px; font-family:'Poppins',sans-serif; }
.toast.show { transform:translateY(0); opacity:1; }
.toast.cart-toast { border-left:4px solid #b01a1a; }
.toast.wish-toast { border-left:4px solid #e67e22; }
.toast.buy-toast  { border-left:4px solid #ff6b00; }
.toast.cart-toast i { color:#b01a1a; }
.toast.wish-toast i { color:#e67e22; }
.toast.buy-toast  i { color:#ff6b00; }

/* ── WISHLIST BADGE ── */
.wishlist-badge { background:#e67e22 !important; }

@media(max-width:480px) { .cart-sidebar, .wishlist-sidebar { width:100%; right:-100%; } }