/* ============================================================
   Shopora — Custom Styles (Tailwind CDN overrides & additions)
   ============================================================ */

/* ── Base ────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
body { font-family: 'Inter', sans-serif; -webkit-font-smoothing: antialiased; }

/* ── Scrollbar ───────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #f1f1f1; }
::-webkit-scrollbar-thumb { background: #c4b5fd; border-radius: 6px; }
::-webkit-scrollbar-thumb:hover { background: #6C2BD9; }

/* ── Transitions ─────────────────────────────────────────── */
a, button { transition: all 0.15s ease; }

/* ── Product Card hover lift ─────────────────────────────── */
.product-card:hover { transform: translateY(-2px); }

/* ── Gradient Hero ───────────────────────────────────────── */
.hero-gradient { background: linear-gradient(135deg, #6C2BD9 0%, #4c1d95 100%); }

/* ── Sidebar active item ─────────────────────────────────── */
.sidebar-link.active { background: #6C2BD9; color: #fff; }

/* ── Table striped ───────────────────────────────────────── */
.table-striped tbody tr:nth-child(even) { background-color: #fafafa; }

/* ── Badge pill ──────────────────────────────────────────── */
.badge { display: inline-flex; align-items: center; padding: 0.2rem 0.6rem;
         border-radius: 9999px; font-size: 0.7rem; font-weight: 600; }

/* ── Star rating interactive ─────────────────────────────── */
.star-btn { cursor: pointer; font-size: 1.8rem; line-height: 1; transition: color 0.1s; }
.star-btn.filled { color: #F59E0B; }

/* ── Chat bubbles ────────────────────────────────────────── */
.chat-bubble-me   { background:#6C2BD9; color:#fff; border-radius:1rem 1rem 0.2rem 1rem; }
.chat-bubble-them { background:#f3f4f6; color:#1f2937; border-radius:1rem 1rem 1rem 0.2rem; }

/* ── Status pills ────────────────────────────────────────── */
.status-pending          { background:#f3f4f6; color:#6b7280; }
.status-processing       { background:#dbeafe; color:#1d4ed8; }
.status-packed           { background:#ede9fe; color:#6d28d9; }
.status-shipped          { background:#e0e7ff; color:#4338ca; }
.status-out_for_delivery { background:#fef3c7; color:#92400e; }
.status-delivered        { background:#d1fae5; color:#065f46; }
.status-cancelled        { background:#fee2e2; color:#991b1b; }
.status-refunded         { background:#ffedd5; color:#9a3412; }

/* ── Form focus ring ─────────────────────────────────────── */
input:focus, select:focus, textarea:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(108, 43, 217, 0.15);
    border-color: #6C2BD9;
}

/* ── Live search dropdown ────────────────────────────────── */
#live-search-dropdown { animation: fadeIn 0.1s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: translateY(0); } }

/* ── Skeleton loader ─────────────────────────────────────── */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.4s ease infinite;
    border-radius: 0.5rem;
}
@keyframes skeleton-loading { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* ── Mobile bottom nav ───────────────────────────────────── */
@media (max-width: 768px) {
    .mobile-bottom-nav {
        position: fixed; bottom: 0; left: 0; right: 0;
        background: #fff; border-top: 1px solid #e5e7eb;
        display: flex; z-index: 40; padding: 0.5rem 0 env(safe-area-inset-bottom);
    }
    .mobile-bottom-nav a {
        flex: 1; display: flex; flex-direction: column; align-items: center;
        font-size: 0.65rem; color: #9ca3af; padding: 0.25rem 0;
    }
    .mobile-bottom-nav a.active { color: #6C2BD9; }
    .mobile-bottom-nav a svg { width: 1.3rem; height: 1.3rem; }
}

/* ── Print styles ────────────────────────────────────────── */
@media print {
    header, footer, nav, aside, .no-print { display: none !important; }
    body { font-size: 12px; }
    .print-full { width: 100% !important; }
}

/* ── Notification dropdown animation ─────────────────────── */
#notif-dropdown, #user-dropdown {
    animation: dropdownIn 0.15s ease;
    transform-origin: top right;
}
@keyframes dropdownIn {
    from { opacity: 0; transform: scale(0.95) translateY(-4px); }
    to   { opacity: 1; transform: scale(1)    translateY(0); }
}

/* ── Toast notification ──────────────────────────────────── */
.toast {
    position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 9999;
    background: #1f2937; color: #fff; padding: 0.75rem 1.25rem;
    border-radius: 0.75rem; font-size: 0.875rem; font-weight: 500;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    animation: toastIn 0.3s ease;
}
@keyframes toastIn { from { opacity:0; transform:translateY(1rem); } to { opacity:1; transform:translateY(0); } }

/* ── Utilities ───────────────────────────────────────────── */
.line-clamp-2 { display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.line-clamp-3 { display:-webkit-box; -webkit-line-clamp:3; -webkit-box-orient:vertical; overflow:hidden; }
.truncate-2   { overflow:hidden; display:-webkit-box; -webkit-box-orient:vertical; -webkit-line-clamp:2; }
