/* public/admin/css/app.css - Tawfero E-commerce Admin Panel */

/* ==================== CSS VARIABLES ==================== */
:root {
    /* E-commerce Pink Theme */
    --primary: #FF006E;
    --primary-dark: #CC0058;
    --primary-light: #FF4D94;
    --primary-bg: rgba(255, 0, 110, 0.1);

    /* Status Colors */
    --secondary: #10b981;
    --secondary-bg: rgba(16, 185, 129, 0.1);
    --accent: #f59e0b;
    --accent-bg: rgba(245, 158, 11, 0.1);
    --danger: #ef4444;
    --danger-bg: rgba(239, 68, 68, 0.1);
    --warning: #f59e0b;
    --warning-bg: rgba(245, 158, 11, 0.1);
    --info: #3b82f6;
    --info-bg: rgba(59, 130, 246, 0.1);

    /* Neutral Colors */
    --light: #f8fafc;
    --dark: #1e293b;
    --gray: #64748b;
    --light-gray: #e2e8f0;
    --border: #cbd5e1;
    --bg: #f1f5f9;
    --white: #ffffff;

    /* Layout */
    --sidebar-width: 280px;
    --topbar-height: 70px;
    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 16px;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.12);
    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.05);

    /* Transitions */
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ==================== ANIMATIONS ==================== */
@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        transform: translateX(30px);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes toastIn {
    from {
        transform: translateX(30px);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes toastOut {
    from {
        opacity: 1;
        transform: translateX(0);
    }

    to {
        opacity: 0;
        transform: translateX(30px);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes ripple {
    0% {
        transform: scale(0.8);
        opacity: 1;
    }

    100% {
        transform: scale(1.4);
        opacity: 0;
    }
}

@keyframes shake {

    0%,
    100% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(-5px);
    }

    75% {
        transform: translateX(5px);
    }
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

@keyframes valid {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.02);
    }

    100% {
        transform: scale(1);
    }
}

/* ==================== BASE STYLES ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    color: var(--dark);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

img {
    max-width: 100%;
    height: auto;
}

/* ==================== LAYOUT ==================== */
body {
    display: flex;
    min-height: 100vh;
}

.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    transition: var(--transition);
    background: var(--bg);
}

.main-content.expanded {
    margin-left: 0;
}

.content-wrapper {
    padding: 30px;
    min-height: calc(100vh - var(--topbar-height));
    animation: fadeIn 0.5s ease;
}

/* ==================== TOP NAVBAR ==================== */
.top-navbar {
    height: var(--topbar-height);
    background: var(--white);
    box-shadow: var(--shadow-sm);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 30px;
    position: sticky;
    top: 0;
    z-index: 900;
    border-bottom: 1px solid var(--light-gray);
    backdrop-filter: blur(10px);
}

.top-nav-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.nav-toggle {
    width: 40px;
    height: 40px;
    border-radius: var(--radius);
    background: var(--primary-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--primary);
    transition: var(--transition);
    border: 1px solid transparent;
}

.nav-toggle:hover {
    background: var(--primary);
    color: var(--white);
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(255, 0, 110, 0.3);
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    color: var(--gray);
    font-weight: 500;
}

.breadcrumb i {
    color: var(--primary);
    font-size: 14px;
}

.top-nav-right {
    display: flex;
    align-items: center;
    gap: 25px;
}

/* Language Switcher */
.language-switcher {
    display: flex;
    background: var(--light);
    border-radius: 20px;
    padding: 4px;
    border: 1px solid var(--light-gray);
}

.language-switcher a {
    padding: 6px 14px;
    border-radius: 16px;
    font-size: 13px;
    font-weight: 600;
    color: var(--gray);
    text-decoration: none;
    transition: var(--transition);
}

.language-switcher a.active {
    background: var(--primary);
    color: var(--white);
    box-shadow: 0 2px 8px rgba(255, 0, 110, 0.2);
}

.language-switcher a:hover:not(.active) {
    background: var(--light-gray);
    color: var(--dark);
}

/* Top Nav Stats */
.top-nav-stats {
    display: flex;
    gap: 15px;
}

.nav-stat {
    position: relative;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: var(--light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray);
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
}

.nav-stat:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 0, 110, 0.2);
    border-color: var(--primary-light);
}

.stat-count {
    position: absolute;
    top: -4px;
    right: -4px;
    background: var(--danger);
    color: var(--white);
    font-size: 11px;
    font-weight: 700;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.3);
    animation: pulse 2s infinite;
}

/* User Profile */
.user-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 12px;
    border-radius: var(--radius);
    cursor: pointer;
    position: relative;
    transition: var(--transition);
    border: 1px solid transparent;
}

.user-profile:hover {
    background: var(--light);
    border-color: var(--light-gray);
}

.user-profile.active {
    background: var(--light);
    border-color: var(--primary-light);
}

.user-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-weight: 600;
    overflow: hidden;
    flex-shrink: 0;
    box-shadow: 0 4px 8px rgba(255, 0, 110, 0.2);
}

.user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-avatar i {
    font-size: 18px;
}

.user-info {
    line-height: 1.3;
    min-width: 0;
}

.user-name {
    font-weight: 600;
    font-size: 14px;
    color: var(--dark);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.user-role {
    font-size: 12px;
    color: var(--gray);
    font-weight: 500;
}

.user-dropdown {
    color: var(--gray);
    font-size: 12px;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
}

.user-profile.active .user-dropdown {
    transform: rotate(180deg);
    color: var(--primary);
}

/* Dropdown Menu */
.dropdown-menu {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    min-width: 220px;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    padding: 8px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: var(--transition);
    z-index: 1000;
    border: 1px solid var(--light-gray);
}

.user-profile.active .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: var(--dark);
    text-decoration: none;
    transition: var(--transition);
    font-size: 14px;
    border-left: 3px solid transparent;
}

.dropdown-item:hover {
    background: var(--light);
    color: var(--primary);
    border-left-color: var(--primary);
}

.dropdown-item i {
    width: 20px;
    color: var(--gray);
    text-align: center;
    font-size: 14px;
}

.dropdown-item:hover i {
    color: var(--primary);
}

.dropdown-divider {
    height: 1px;
    background: var(--light-gray);
    margin: 8px 0;
}

.dropdown-item .badge {
    margin-left: auto;
    font-size: 11px;
    padding: 2px 6px;
}

.dropdown-item.text-danger {
    color: var(--danger);
}

.dropdown-item.text-danger:hover {
    background: var(--danger-bg);
    border-left-color: var(--danger);
}

.dropdown-item.text-danger i {
    color: var(--danger);
}

/* ==================== SIDEBAR ==================== */
.sidebar {
    width: var(--sidebar-width);
    background: linear-gradient(180deg, #1a1625 0%, #2d1b38 100%);
    color: var(--white);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    z-index: 1000;
    overflow-y: auto;
    transition: var(--transition);
    box-shadow: var(--shadow-lg);
    border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.sidebar.collapsed {
    transform: translateX(-100%);
}

/* Logo */
.logo {
    padding: 25px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(255, 255, 255, 0.03);
}

.logo i {
    font-size: 26px;
    color: var(--white);
    background: rgba(255, 0, 110, 0.2);
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
}

.logo:hover i {
    background: var(--primary);
    transform: rotate(5deg) scale(1.05);
    box-shadow: 0 6px 20px rgba(255, 0, 110, 0.4);
}

.logo-text {
    font-size: 22px;
    font-weight: 800;
    color: var(--white);
    letter-spacing: -0.5px;
}

.logo-subtext {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
    margin-top: 2px;
    letter-spacing: 0.3px;
}

/* Navigation Menu */
.nav-menu {
    padding: 20px 0;
    flex-grow: 1;
    overflow-y: auto;
}

.nav-menu::-webkit-scrollbar {
    width: 4px;
}

.nav-menu::-webkit-scrollbar-track {
    background: transparent;
}

.nav-menu::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
}

/* Navigation Sections */
.nav-section {
    margin-bottom: 4px;
}

.nav-section-title {
    padding: 12px 20px 8px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    user-select: none;
}

/* Navigation Items */
.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: var(--transition);
    border-left: 4px solid transparent;
    position: relative;
    margin: 2px 8px;
    border-radius: 8px;
    cursor: pointer;
}

.nav-item:hover {
    background: rgba(255, 0, 110, 0.1);
    color: var(--white);
    border-left-color: var(--primary-light);
}

.nav-item.active {
    background: rgba(255, 0, 110, 0.15);
    color: var(--white);
    border-left-color: var(--primary);
    font-weight: 600;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.nav-item.active .nav-icon {
    color: var(--primary-light);
}

/* Navigation Icons */
.nav-icon {
    width: 24px;
    text-align: center;
    font-size: 18px;
    opacity: 0.9;
    transition: var(--transition);
    flex-shrink: 0;
}

/* Navigation Text */
.nav-text {
    display: flex;
    font-size: 15px;
    flex-grow: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 500;
}

/* Navigation Badge */
.nav-badge {
    background: var(--danger);
    color: var(--white);
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 12px;
    font-weight: 700;
    min-width: 20px;
    text-align: center;
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.3);
}

/* Dropdown Toggle */
.nav-dropdown-toggle {
    width: 100%;
    border: none;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    color: inherit;
    text-align: left;
    transition: var(--transition);
    margin: 2px 8px;
    border-radius: 8px;
    border-left: 4px solid transparent;
}

.nav-dropdown-toggle:hover {
    background: rgba(255, 0, 110, 0.1);
    color: var(--white);
    border-left-color: var(--primary-light);
}

.nav-dropdown-toggle.active {
    background: rgba(255, 0, 110, 0.15);
    color: var(--white);
    border-left-color: var(--primary);
    font-weight: 600;
}

/* Navigation Caret */
.nav-caret {
    font-size: 12px;
    opacity: 0.7;
    transition: transform 0.25s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.1);
}

.nav-dropdown-toggle[aria-expanded="true"] .nav-caret {
    transform: rotate(180deg);
    background: rgba(255, 0, 110, 0.3);
    color: var(--primary-light);
}

/* Dropdown Panel */
.nav-dropdown {
    display: none;
    padding: 6px 0 2px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 0 0 8px 8px;
    margin: -4px 8px 4px;
}

.nav-dropdown.open {
    display: block;
    animation: slideDown 0.3s ease;
}

/* Dropdown Items */
.nav-item-sub {
    padding-left: 31px !important;
    font-size: 14px !important;
    border-left: 4px solid transparent !important;
    margin: 2px 0 !important;
    border-radius: 6px !important;
    opacity: 0.9;
}

.nav-item-sub:hover {
    border-left-color: rgba(255, 0, 110, 0.3) !important;
    background: rgba(255, 0, 110, 0.05) !important;
}

.nav-item-sub.active {
    border-left-color: var(--primary-light) !important;
    background: rgba(255, 0, 110, 0.1) !important;
    opacity: 1;
}

.nav-item-sub .nav-icon {
    font-size: 16px !important;
}

/* Business Info */
.business-info {
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.15);
    margin-top: auto;
}

.business-name {
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--white);
    font-size: 15px;
    letter-spacing: 0.3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.business-status {
    display: flex;
    align-items: center;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
}

.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--secondary);
    margin-right: 8px;
    position: relative;
}

.status-indicator::before {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    background: rgba(16, 185, 129, 0.3);
    border-radius: 50%;
    animation: ripple 2s infinite;
}

/* ==================== PAGE STYLES ==================== */
.page {
    display: none;
}

.page.active {
    display: block;
    animation: slideUp 0.5s ease;
}

/* Page Header */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--light-gray);
    flex-wrap: wrap;
    gap: 20px;
}

.page-title {
    font-size: 28px;
    color: var(--dark);
    font-weight: 800;
    line-height: 1.2;
    padding-left: 16px;
    position: relative;
}

.page-title::before {
    content: '';
    width: 4px;
    height: 28px;
    background: var(--primary);
    border-radius: 2px;
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
}

.header-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* ==================== SELLER STATS ==================== */
.seller-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.seller-stat-card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: var(--transition);
    border: 1px solid transparent;
    position: relative;
    overflow: hidden;
}

.seller-stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
}

.seller-stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.seller-stat-icon {
    width: 60px;
    height: 60px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(255, 0, 110, 0.15);
}

.seller-stat-value {
    font-size: 32px;
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 4px;
    line-height: 1;
}

.seller-stat-label {
    font-size: 14px;
    color: var(--gray);
    font-weight: 500;
}

/* ==================== CARDS ==================== */
.card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 25px;
    margin-bottom: 25px;
    transition: var(--transition);
    border: 1px solid transparent;
}

.card:hover {
    box-shadow: var(--shadow-lg);
    border-color: var(--light-gray);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--light-gray);
    flex-wrap: wrap;
    gap: 15px;
}

.card-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--dark);
    margin: 0;
}

/* ==================== BUTTONS ==================== */
.btn {
    padding: 12px 24px;
    border-radius: var(--radius-sm);
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    gap: 8px;
    text-decoration: none;
    font-family: inherit;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn i {
    font-size: 14px;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn:active {
    transform: translateY(0);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: var(--white);
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
    box-shadow: 0 8px 20px rgba(255, 0, 110, 0.3);
}

.btn-secondary {
    background: var(--light);
    color: var(--dark);
    border: 1px solid var(--light-gray);
}

.btn-secondary:hover {
    background: var(--light-gray);
    color: var(--dark);
    border-color: var(--gray);
}

.btn-success {
    background: linear-gradient(135deg, var(--secondary) 0%, #34d399 100%);
    color: var(--white);
    border: none;
}

.btn-danger {
    background: linear-gradient(135deg, var(--danger) 0%, #f87171 100%);
    color: var(--white);
    border: none;
}

.btn-warning {
    background: linear-gradient(135deg, var(--warning) 0%, #fbbf24 100%);
    color: var(--dark);
    border: none;
}

.btn-small {
    padding: 8px 16px;
    font-size: 14px;
    border-radius: var(--radius-sm);
}

.btn-icon {
    padding: 10px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

/* ==================== BADGES ==================== */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    line-height: 1;
    white-space: nowrap;
}

.badge i {
    font-size: 10px;
}

.badge-success {
    background: var(--secondary-bg);
    color: var(--secondary);
}

.badge-danger {
    background: var(--danger-bg);
    color: var(--danger);
}

.badge-warning {
    background: var(--warning-bg);
    color: var(--warning);
}

.badge-info {
    background: var(--info-bg);
    color: var(--info);
}

.badge-primary {
    background: var(--primary-bg);
    color: var(--primary);
}

.badge-secondary {
    background: var(--light-gray);
    color: var(--gray);
}

.badge-new {
    background: var(--info-bg);
    color: var(--info);
}

/* ==================== TABLES ==================== */
.table-container {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    margin-bottom: 25px;
    border: 1px solid var(--light-gray);
}

.table-container table {
    width: 100%;
    border-collapse: collapse;
    min-width: 800px;
}

.table-container thead {
    background: linear-gradient(135deg, var(--light) 0%, #f8fafc 100%);
}

.table-container th {
    padding: 18px 20px;
    text-align: left;
    font-weight: 700;
    color: var(--dark);
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid var(--light-gray);
    white-space: nowrap;
}

.table-container td {
    padding: 18px 20px;
    border-bottom: 1px solid var(--light-gray);
    vertical-align: middle;
    color: var(--dark);
    font-size: 15px;
}

.table-container tbody tr {
    transition: var(--transition);
}

.table-container tbody tr:hover {
    background: var(--light);
}

.table-container tbody tr:last-child td {
    border-bottom: none;
}

/* Table Actions */
.table-container td:last-child {
    text-align: right;
    white-space: nowrap;
}

/* Table Filter */
.table-container form {
    margin: 0;
}

.table-container thead tr:last-child th {
    padding-top: 12px;
    padding-bottom: 12px;
    background: var(--light);
}

.table-container input[type="text"],
.table-container input[type="number"],
.table-container select {
    width: 100%;
    max-width: 200px;
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 14px;
    background: var(--white);
}

.table-container input:focus,
.table-container select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-bg);
}

/* Empty State */
.empty-row td {
    padding: 60px 20px !important;
    text-align: center;
    color: var(--gray);
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.empty-state i {
    font-size: 48px;
    opacity: 0.3;
}

.empty-state p {
    font-size: 16px;
    margin: 0;
    color: var(--gray);
}

/* ==================== PAGINATION ==================== */
.pagination-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0 10px;
    gap: 20px;
    flex-wrap: wrap;
}

.pagination-info {
    color: var(--gray);
    font-size: 14px;
    font-weight: 500;
}

.pagination-info strong {
    color: var(--dark);
    font-weight: 700;
}

.pagination-links nav {
    display: flex;
}

.pagination {
    display: flex;
    list-style: none;
    gap: 8px;
    padding: 0;
    margin: 0;
}

.page-item {
    display: flex;
}

.page-link,
.page-item span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--light-gray);
    text-decoration: none;
    font-weight: 600;
    color: var(--dark);
    background: var(--white);
    transition: var(--transition);
    padding: 0 14px;
    font-size: 14px;
}

.page-link:hover {
    background: var(--primary-bg);
    color: var(--primary);
    border-color: var(--primary-light);
}

.page-item.active span {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

.page-item.disabled span {
    opacity: 0.5;
    cursor: not-allowed;
    background: var(--light);
}

/* ==================== ALERTS & TOASTS ==================== */
.alert-popup {
    position: fixed;
    top: 25px;
    right: 25px;
    z-index: 9999;
    min-width: 320px;
    max-width: 420px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    padding: 20px;
    background: var(--white);
    border-left: 6px solid var(--primary);
    animation: slideIn 0.4s ease;
    border: 1px solid var(--light-gray);
}

.alert-popup.danger {
    border-left-color: var(--danger);
}

.alert-popup-content {
    display: flex;
    align-items: flex-start;
    gap: 15px;
}

.alert-popup-icon {
    font-size: 24px;
    color: var(--primary);
    flex-shrink: 0;
}

.alert-popup.danger .alert-popup-icon {
    color: var(--danger);
}

.alert-popup-text strong {
    display: block;
    font-size: 16px;
    margin-bottom: 4px;
    color: var(--dark);
}

.alert-popup-text p {
    margin: 0;
    font-size: 14px;
    color: var(--gray);
    line-height: 1.5;
}

.alert-popup-close {
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    color: var(--gray);
    padding: 0;
    margin-left: auto;
    transition: var(--transition);
}

.alert-popup-close:hover {
    color: var(--dark);
}

/* Toast */
.toast {
    position: fixed;
    top: 25px;
    right: 25px;
    z-index: 9999;
    min-width: 320px;
    max-width: 420px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    padding: 20px;
    background: var(--white);
    border-left: 6px solid var(--primary);
    animation: toastIn 0.35s ease;
    overflow: hidden;
}

.toast-error {
    border-left-color: var(--danger);
}

.toast-content {
    display: flex;
    align-items: flex-start;
    gap: 15px;
}

.toast-icon {
    font-size: 24px;
    color: var(--primary);
    flex-shrink: 0;
}

.toast-error .toast-icon {
    color: var(--danger);
}

.toast-text strong {
    display: block;
    font-size: 16px;
    margin-bottom: 4px;
    color: var(--dark);
}

.toast-text p {
    margin: 0;
    font-size: 14px;
    color: var(--gray);
    line-height: 1.5;
}

.toast-close {
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    color: var(--gray);
    margin-left: auto;
    padding: 0;
    transition: var(--transition);
}

.toast-close:hover {
    color: var(--dark);
}

/* ==================== MEDIA PREVIEW ==================== */
.media-preview {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 25px;
    margin-bottom: 25px;
}

/* ==================== ADD/EDIT FORM STYLES ==================== */

/* Form Container */
.card.form-card {
    max-width: 900px;
    margin: 0 auto;
}

/* Form Sections */
.form-section {
    margin-bottom: 40px;
    padding: 25px;
    border-radius: var(--radius);
    background: linear-gradient(135deg, rgba(255, 0, 110, 0.02) 0%, rgba(255, 77, 148, 0.02) 100%);
    border: 1px solid var(--light-gray);
    position: relative;
    overflow: hidden;
}

.form-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--primary);
}

.form-section-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
}

.form-section-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius);
    background: var(--primary-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 20px;
    flex-shrink: 0;
}

.form-section-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--dark);
    margin: 0;
}

.form-section-subtitle {
    font-size: 14px;
    color: var(--gray);
    margin-top: 4px;
}

/* Form Headers */
h3 {
    font-size: 20px;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--primary-bg);
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
}

h3::before {
    content: '';
    width: 6px;
    height: 24px;
    background: var(--primary);
    border-radius: 3px;
}

/* Form Groups */
.form-group {
    margin-bottom: 25px;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--dark);
    font-size: 14px;
    transition: var(--transition);
}

.form-group label.required::after {
    content: ' *';
    color: var(--danger);
}

/* Form Controls */
.form-control {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid var(--light-gray);
    border-radius: var(--radius-sm);
    font-size: 15px;
    transition: var(--transition);
    background: var(--white);
    color: var(--dark);
    font-family: inherit;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px var(--primary-bg);
}

.form-control:hover:not(:focus) {
    border-color: var(--gray);
}

.form-control::placeholder {
    color: var(--gray);
    opacity: 0.7;
}

/* Select Styling */
select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%2364748b' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 14px;
    padding-right: 40px;
}

/* File Input Styling */
.form-control[type="file"] {
    padding: 12px 16px;
    border: 2px dashed var(--light-gray);
    background: var(--light);
    cursor: pointer;
    transition: var(--transition);
}

.form-control[type="file"]:hover {
    border-color: var(--primary-light);
    background: var(--primary-bg);
}

.form-control[type="file"]:focus {
    border-style: solid;
}

/* Error States */
.form-control.is-invalid,
.form-control.is-invalid:focus {
    border-color: var(--danger);
    box-shadow: 0 0 0 4px var(--danger-bg);
}

/* Error Messages */
.text-danger {
    display: block;
    margin-top: 6px;
    font-size: 13px;
    color: var(--danger);
    font-weight: 500;
    animation: shake 0.5s ease;
}

/* File Preview */
.file-preview {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 10px;
}

.file-item {
    position: relative;
    width: 100px;
    height: 100px;
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 1px solid var(--light-gray);
    background: var(--light);
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.file-item .file-icon {
    font-size: 32px;
    color: var(--gray);
}

.file-item .file-name {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    font-size: 11px;
    padding: 4px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Form Grid */
.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.form-group.grid-item {
    margin-bottom: 0;
}

/* Form Help Text */
.form-help {
    display: block;
    margin-top: 6px;
    font-size: 13px;
    color: var(--gray);
    font-style: italic;
}

/* Divider */
hr {
    border: none;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--light-gray), transparent);
    margin: 40px 0;
}

/* Form Actions */
.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 15px;
    margin-top: 40px;
    padding-top: 25px;
    border-top: 1px solid var(--light-gray);
}

/* Tooltips */
.form-tooltip {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: help;
}

.form-tooltip .tooltip-text {
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--dark);
    color: var(--white);
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 400;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 100;
    margin-bottom: 8px;
    box-shadow: var(--shadow);
}

.form-tooltip .tooltip-text::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: var(--dark);
}

.form-tooltip:hover .tooltip-text {
    opacity: 1;
    visibility: visible;
}

/* Password Strength Indicator */
.password-strength {
    margin-top: 10px;
}

.strength-bar {
    height: 4px;
    background: var(--light-gray);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 6px;
}

.strength-level {
    height: 100%;
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 2px;
}

.strength-level.weak {
    background: var(--danger);
    width: 25%;
}

.strength-level.fair {
    background: var(--warning);
    width: 50%;
}

.strength-level.good {
    background: var(--accent);
    width: 75%;
}

.strength-level.strong {
    background: var(--secondary);
    width: 100%;
}

.strength-text {
    font-size: 12px;
    color: var(--gray);
}

/* Commission Input with Percentage */
.commission-wrapper {
    position: relative;
}

.commission-wrapper .form-control {
    padding-right: 60px;
}

.commission-percent {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray);
    font-weight: 600;
    pointer-events: none;
}

/* Character Counters */
.char-counter {
    text-align: right;
    font-size: 12px;
    color: var(--gray);
    margin-top: 4px;
}

/* Toggle Switch Styles */
.form-toggle {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 15px;
    cursor: pointer;
}

.form-toggle input[type="checkbox"] {
    display: none;
}

.form-toggle label {
    position: relative;
    width: 50px;
    height: 26px;
    background: var(--light-gray);
    border-radius: 13px;
    transition: var(--transition);
    cursor: pointer;
}

.form-toggle label::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    background: var(--white);
    border-radius: 50%;
    transition: var(--transition);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.form-toggle input[type="checkbox"]:checked+label {
    background: var(--primary);
}

.form-toggle input[type="checkbox"]:checked+label::after {
    transform: translateX(24px);
}

/* Image Grid */
.image-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.image-item {
    position: relative;
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 2px solid var(--light-gray);
    transition: var(--transition);
}

.image-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
    border-color: var(--primary-light);
}

.image-item img {
    width: 100%;
    height: 150px;
    object-fit: cover;
}

.image-actions {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 5px;
    opacity: 0;
    transition: var(--transition);
}

.image-item:hover .image-actions {
    opacity: 1;
}

/* Form Loading State */
.form-loading .form-control {
    background: linear-gradient(90deg, var(--light) 25%, var(--light-gray) 50%, var(--light) 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

/* Success/Error States */
.form-success .form-control {
    border-color: var(--secondary);
}

.form-error .form-control {
    border-color: var(--danger);
}

/* Form Focus States with Floating Label */
.form-group.floating-label {
    position: relative;
}

.form-group.floating-label label {
    position: absolute;
    top: 14px;
    left: 16px;
    font-size: 15px;
    color: var(--gray);
    pointer-events: none;
    transition: var(--transition);
    background: var(--white);
    padding: 0 4px;
    border-radius: 4px;
}

.form-group.floating-label .form-control:focus+label,
.form-group.floating-label .form-control:not(:placeholder-shown)+label {
    top: -10px;
    font-size: 12px;
    color: var(--primary);
    font-weight: 600;
}

/* Form Field Icons */
.form-group.with-icon {
    position: relative;
}

.form-group.with-icon .form-control {
    padding-left: 45px;
}

.form-group.with-icon .icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray);
    font-size: 18px;
    pointer-events: none;
}

.form-group.with-icon .form-control:focus+.icon {
    color: var(--primary);
}

/* Form Toggles */
.form-toggle {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 25px;
}

.form-toggle input[type="checkbox"] {
    display: none;
}

.form-toggle label {
    position: relative;
    width: 50px;
    height: 26px;
    background: var(--light-gray);
    border-radius: 13px;
    cursor: pointer;
    transition: var(--transition);
}

.form-toggle label::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    background: var(--white);
    border-radius: 50%;
    transition: var(--transition);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.form-toggle input[type="checkbox"]:checked+label {
    background: var(--primary);
}

.form-toggle input[type="checkbox"]:checked+label::after {
    transform: translateX(24px);
}

/* Form Rating */
.form-rating {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 25px;
}

.form-rating .stars {
    color: var(--light-gray);
    font-size: 20px;
    cursor: pointer;
    transition: var(--transition);
}

.form-rating .stars:hover,
.form-rating .stars.active {
    color: var(--warning);
}

/* ==================== UTILITY CLASSES ==================== */
.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.text-left {
    text-align: left;
}

.text-primary {
    color: var(--primary);
}

.text-secondary {
    color: var(--secondary);
}

.text-success {
    color: var(--secondary);
}

.text-danger {
    color: var(--danger);
}

.text-warning {
    color: var(--warning);
}

.text-info {
    color: var(--info);
}

.text-gray {
    color: var(--gray);
}

.text-light {
    color: var(--light-gray);
}

.text-dark {
    color: var(--dark);
}

.text-white {
    color: var(--white);
}

.bg-primary {
    background: var(--primary-bg);
}

.bg-secondary {
    background: var(--secondary-bg);
}

.bg-success {
    background: var(--secondary-bg);
}

.bg-danger {
    background: var(--danger-bg);
}

.bg-warning {
    background: var(--warning-bg);
}

.bg-info {
    background: var(--info-bg);
}

.mt-0 {
    margin-top: 0;
}

.mt-1 {
    margin-top: 0.5rem;
}

.mt-2 {
    margin-top: 1rem;
}

.mt-3 {
    margin-top: 1.5rem;
}

.mt-4 {
    margin-top: 2rem;
}

.mt-5 {
    margin-top: 2.5rem;
}

.mb-0 {
    margin-bottom: 0;
}

.mb-1 {
    margin-bottom: 0.5rem;
}

.mb-2 {
    margin-bottom: 1rem;
}

.mb-3 {
    margin-bottom: 1.5rem;
}

.mb-4 {
    margin-bottom: 2rem;
}

.mb-5 {
    margin-bottom: 2.5rem;
}

.p-0 {
    padding: 0;
}

.p-1 {
    padding: 0.5rem;
}

.p-2 {
    padding: 1rem;
}

.p-3 {
    padding: 1.5rem;
}

.p-4 {
    padding: 2rem;
}

.p-5 {
    padding: 2.5rem;
}

.d-none {
    display: none;
}

.d-flex {
    display: flex;
}

.d-block {
    display: block;
}

.d-inline {
    display: inline;
}

.d-inline-block {
    display: inline-block;
}

.d-grid {
    display: grid;
}

.flex-row {
    flex-direction: row;
}

.flex-column {
    flex-direction: column;
}

.justify-start {
    justify-content: flex-start;
}

.justify-end {
    justify-content: flex-end;
}

.justify-center {
    justify-content: center;
}

.justify-between {
    justify-content: space-between;
}

.justify-around {
    justify-content: space-around;
}

.align-start {
    align-items: flex-start;
}

.align-end {
    align-items: flex-end;
}

.align-center {
    align-items: center;
}

.align-stretch {
    align-items: stretch;
}

.gap-1 {
    gap: 0.5rem;
}

.gap-2 {
    gap: 1rem;
}

.gap-3 {
    gap: 1.5rem;
}

.gap-4 {
    gap: 2rem;
}

.gap-5 {
    gap: 2.5rem;
}

.w-100 {
    width: 100%;
}

.h-100 {
    height: 100%;
}

.rounded {
    border-radius: var(--radius);
}

.rounded-sm {
    border-radius: var(--radius-sm);
}

.rounded-lg {
    border-radius: var(--radius-lg);
}

.rounded-circle {
    border-radius: 50%;
}

.shadow {
    box-shadow: var(--shadow);
}

.shadow-sm {
    box-shadow: var(--shadow-sm);
}

.shadow-lg {
    box-shadow: var(--shadow-lg);
}

.shadow-none {
    box-shadow: none;
}

.border {
    border: 1px solid var(--border);
}

.border-top {
    border-top: 1px solid var(--border);
}

.border-bottom {
    border-bottom: 1px solid var(--border);
}

.border-start {
    border-left: 1px solid var(--border);
}

.border-end {
    border-right: 1px solid var(--border);
}

.overflow-hidden {
    overflow: hidden;
}

.overflow-auto {
    overflow: auto;
}

.overflow-x-auto {
    overflow-x: auto;
}

.overflow-y-auto {
    overflow-y: auto;
}

.position-relative {
    position: relative;
}

.position-absolute {
    position: absolute;
}

.position-fixed {
    position: fixed;
}

.position-sticky {
    position: sticky;
}

/* ==================== CUSTOM SCROLLBAR ==================== */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--light);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--gray);
    border-radius: 4px;
    transition: var(--transition);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: var(--gray) var(--light);
}

/* ==================== SELECT2 OVERRIDES ==================== */
.select2-container--bootstrap4 .select2-selection {
    border: 1px solid var(--border) !important;
    border-radius: var(--radius-sm) !important;
    height: auto !important;
    min-height: 48px;
    padding: 4px !important;
    background: var(--white) !important;
}

.select2-container--bootstrap4 .select2-selection:focus {
    border-color: var(--primary) !important;
    box-shadow: 0 0 0 3px var(--primary-bg) !important;
}

.select2-container--bootstrap4 .select2-selection__choice {
    background: var(--primary-bg) !important;
    border-color: var(--primary-light) !important;
    color: var(--primary) !important;
    border-radius: var(--radius-sm) !important;
    display: flex;
    align-items: center;
}

.select2-container--bootstrap4 .select2-dropdown {
    border: 1px solid var(--border) !important;
    border-radius: var(--radius-sm) !important;
    box-shadow: var(--shadow) !important;
    background: var(--white) !important;
}

/* ==================== RESPONSIVE DESIGN ==================== */
@media (max-width: 1200px) {
    .sidebar {
        transform: translateX(-100%);
        position: fixed;
        z-index: 1000;
    }

    .sidebar.collapsed {
        transform: translateX(0);
        box-shadow: 0 0 0 100vmax rgba(0, 0, 0, 0.5);
    }

    .main-content {
        margin-left: 0 !important;
    }

    .top-nav-left .breadcrumb span {
        display: none;
    }
}

@media (max-width: 992px) {
    .seller-stats {
        grid-template-columns: repeat(2, 1fr);
    }

    .content-wrapper {
        padding: 20px;
    }

    .page-title {
        font-size: 24px;
    }

    .card.form-card {
        padding: 20px;
    }
}

@media (max-width: 768px) {
    .top-navbar {
        padding: 0 20px;
    }

    .top-nav-right {
        gap: 15px;
    }

    .user-info {
        display: none;
    }

    .language-switcher {
        display: none;
    }

    .page-header {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }

    .header-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .seller-stats {
        grid-template-columns: 1fr;
    }

    .card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .pagination-footer {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }

    .pagination-links {
        justify-content: center;
    }

    .table-container {
        border-radius: 0;
        margin-left: -20px;
        margin-right: -20px;
        width: calc(100% + 40px);
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .form-actions {
        flex-direction: column;
    }

    .form-actions .btn {
        width: 100%;
    }

    .form-section {
        padding: 20px;
    }

    .content-wrapper {
        padding: 15px;
    }
}

@media (max-width: 576px) {
    .top-nav-stats {
        display: none;
    }

    .content-wrapper {
        padding: 15px;
    }

    .card {
        padding: 20px;
    }

    .btn {
        padding: 10px 20px;
        font-size: 14px;
    }

    .seller-stat-card {
        padding: 20px;
    }

    .seller-stat-value {
        font-size: 28px;
    }

    .table-container {
        margin-left: -15px;
        margin-right: -15px;
        width: calc(100% + 30px);
    }

    .card.form-card {
        padding: 15px;
        margin-left: -15px;
        margin-right: -15px;
        width: calc(100% + 30px);
    }

    .form-section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .form-section-icon {
        width: 40px;
        height: 40px;
        font-size: 18px;
    }
}

/* ==================== PRINT STYLES ==================== */
@media print {

    .top-navbar,
    .sidebar {
        display: none !important;
    }

    .main-content {
        margin-left: 0 !important;
    }

    .card {
        box-shadow: none !important;
        border: 1px solid #ddd !important;
        break-inside: avoid;
    }

    .btn {
        display: none !important;
    }

    .no-print {
        display: none !important;
    }
}

button.nav-item.nav-dropdown-toggle {
    margin: 0px;
}

/* Documents Grid */
.documents-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    padding: 20px;
}

.document-card {
    border: 1px solid var(--light-gray);
    border-radius: var(--radius);
    overflow: hidden;
    transition: var(--transition);
}

.document-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.document-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px;
    background: var(--light);
    border-bottom: 1px solid var(--light-gray);
}

.document-icon {
    font-size: 20px;
    color: var(--primary);
}

.document-header h4 {
    margin: 0;
    font-size: 16px;
    color: var(--dark);
    font-weight: 600;
}

.document-preview {
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--white);
}

.document-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.document-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    color: var(--gray);
}

.document-placeholder i {
    font-size: 48px;
}

.document-pdf {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.pdf-icon {
    font-size: 64px;
    color: var(--danger);
}

.pdf-label {
    font-size: 14px;
    color: var(--gray);
    font-weight: 500;
}

.document-actions {
    display: flex;
    gap: 10px;
    padding: 15px;
    border-top: 1px solid var(--light-gray);
    background: var(--light);
}

.nav-menu {
    /* Hide scrollbar */
    scrollbar-width: none;
    /* Firefox */
    -ms-overflow-style: none;
    /* IE and Edge */
}

.nav-menu::-webkit-scrollbar {
    display: none;
    /* Chrome, Safari, Opera */
}

/* Ensure sidebar appears above overlay on mobile */
@media (max-width: 1200px) {
    .sidebar:not(.collapsed) {
        z-index: 1000 !important;
    }
}

/* select 2*/
/* Select2 multiple: allow wrapping + auto height */
.select2-container .select2-selection--multiple {
    min-height: 42px;
    /* match your input height */
    height: auto !important;
    /* let it grow */
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    padding: 6px 8px !important;
    gap: 6px;
    /* space between tags */
    overflow: hidden;
    /* keep inside the box */
}

/* Each selected tag */
.select2-container--default .select2-selection--multiple .select2-selection__choice {
    margin: 0 !important;
    /* remove default margins that break layout */
    display: inline-flex !important;
    align-items: center !important;
    padding: 4px 10px !important;
    border-radius: 10px;
    line-height: 1.2;
}

/* The remove (×) button */
.select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
    position: static !important;
    /* stop it floating weirdly */
    margin: 0 6px 0 0 !important;
    line-height: 1 !important;
    align-self: center !important;
}

/* The input (typing area) inside selection */
.select2-container--default .select2-selection--multiple .select2-search--inline .select2-search__field {
    margin: 0 !important;
    height: 28px !important;
    line-height: 28px !important;
}

button.select2-selection__choice__remove:hover {
    color: #ff006e !important;
}

button.select2-selection__choice__remove {
    margin-right: 8px !important;
    margin-left: 4px !important;
    color: rgb(255 0 110 / 65%) !important;
    border: 1px solid #ff006e;
    border-radius: 0.30rem;
}

/* ==================== NOTIFICATIONS PAGE ==================== */

/* Notification Cards */
.notification-card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 20px;
    margin-bottom: 15px;
    border-left: 4px solid transparent;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 1px solid var(--light-gray);
    position: relative;
    animation: slideIn 0.3s ease;
}

.notification-card:hover {
    transform: translateX(5px);
    box-shadow: var(--shadow);
    border-color: var(--primary-light);
}

.notification-card.unread {
    background: linear-gradient(to right, var(--primary-bg), var(--white));
    border-left-color: var(--warning);
    border-left-width: 4px;
}

.notification-card.read {
    border-left-color: var(--secondary);
    opacity: 0.9;
}

/* Notification Header */
.notification-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.notification-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 16px;
    font-weight: 600;
    color: var(--dark);
}

.notification-title i {
    color: var(--primary);
    font-size: 18px;
    width: 24px;
}

.notification-title .badge {
    margin-left: 8px;
}

/* Notification Meta */
.notification-meta {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.notification-time {
    font-size: 12px;
    color: var(--gray);
    display: flex;
    align-items: center;
    gap: 5px;
}

.notification-time i {
    font-size: 12px;
    opacity: 0.7;
}

/* Notification Content */
.notification-content {
    margin: 15px 0;
    color: var(--dark);
    line-height: 1.6;
    font-size: 14px;
    padding-left: 34px;
    /* Align with title icon */
}

/* Notification Actions */
.notification-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 15px;
    padding-left: 34px;
    /* Align with title icon */
}

.notification-actions .btn {
    padding: 8px 16px;
    font-size: 13px;
}

/* Notification Badges */
.notification-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.notification-badge i {
    font-size: 11px;
}

/* Notification Types */
.notification-card.order {
    border-top: 2px solid var(--info);
}

.notification-card.system {
    border-top: 2px solid var(--primary);
}

.notification-card.alert {
    border-top: 2px solid var(--danger);
}

/* Empty State */
.notifications-empty {
    text-align: center;
    padding: 60px 20px;
    color: var(--gray);
}

.notifications-empty i {
    font-size: 64px;
    margin-bottom: 20px;
    opacity: 0.3;
    color: var(--primary);
}

.notifications-empty h3 {
    font-size: 20px;
    margin-bottom: 10px;
    color: var(--dark);
}

.notifications-empty p {
    font-size: 14px;
    margin-bottom: 0;
}

/* Notification Filters */
.notification-filters {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.notification-filter-btn {
    padding: 8px 16px;
    border-radius: 20px;
    background: var(--white);
    border: 1px solid var(--light-gray);
    color: var(--gray);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.notification-filter-btn:hover,
.notification-filter-btn.active {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

/* Notification Stats */
.notification-stats {
    display: flex;
    gap: 20px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.notification-stat {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 20px;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    flex: 1;
    min-width: 180px;
}

.notification-stat-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.notification-stat-icon.total {
    background: var(--primary-bg);
    color: var(--primary);
}

.notification-stat-icon.unread {
    background: var(--warning-bg);
    color: var(--warning);
}

.notification-stat-icon.read {
    background: var(--secondary-bg);
    color: var(--secondary);
}

.notification-stat-info h4 {
    font-size: 14px;
    color: var(--gray);
    margin-bottom: 4px;
}

.notification-stat-info span {
    font-size: 24px;
    font-weight: 700;
    color: var(--dark);
    line-height: 1;
}

/* Bulk Actions */
.notification-bulk-actions {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 15px;
    background: var(--light);
    border-radius: var(--radius);
    margin-bottom: 20px;
}

.notification-checkbox {
    margin-right: 10px;
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: var(--primary);
}

/* Responsive */
@media (max-width: 768px) {
    .notification-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .notification-meta {
        width: 100%;
        justify-content: space-between;
    }

    .notification-content,
    .notification-actions {
        padding-left: 0;
    }

    .notification-actions {
        flex-direction: column;
    }

    .notification-actions .btn {
        width: 100%;
        justify-content: center;
    }

    .notification-stats {
        flex-direction: column;
        gap: 10px;
    }

    .notification-stat {
        width: 100%;
    }
}

@media (max-width: 576px) {
    .notification-title {
        flex-wrap: wrap;
    }

    .notification-title .badge {
        margin-left: 0;
    }

    .notification-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
}

/* Animation for new notifications */
@keyframes notificationPulse {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 0, 110, 0.4);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(255, 0, 110, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(255, 0, 110, 0);
    }
}

.notification-card.new {
    animation: notificationPulse 1.5s infinite;
}

/* Notification link styles */
.notification-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
}

.notification-link:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* Grouped notifications */
.notification-group {
    margin-bottom: 30px;
}

.notification-group-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--gray);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 15px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--light-gray);
}

/* Notification dot indicator */
.notification-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--danger);
    margin-left: 8px;
    position: relative;
}

.notification-dot::before {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    background: rgba(239, 68, 68, 0.3);
    border-radius: 50%;
    animation: ripple 2s infinite;
}

.sortable-row.dragging {
    opacity: 0.6;
    background: var(--primary-bg) !important;
    box-shadow: var(--shadow);
    cursor: grabbing;
}

.sortable-row.drag-over {
    border-bottom: 2px solid var(--primary);
}

.sortable-row.changed .position-status {
    background: var(--warning) !important;
    box-shadow: 0 0 0 2px var(--warning-bg);
}

.position-badge {
    transition: all 0.2s ease;
}

.sortable-row:hover .position-badge {
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(255, 0, 110, 0.3);
}

.alert-success {
    animation: slideDown 0.3s ease;
}
.postion-table {
    padding: 20px;
}