/* ===== ZXin Site Styles ===== */

:root {
    --sidebar-width: 260px;
    --sidebar-bg: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
}

/* ===== Sidebar ===== */
.sidebar {
    width: var(--sidebar-width);
    min-height: 100vh;
    background: var(--sidebar-bg);
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
}

.sidebar .nav-link {
    color: rgba(255,255,255,.7);
    border-radius: .5rem;
    margin: 2px 8px;
    padding: 10px 16px;
    transition: all .2s;
    font-size: 0.9rem;
}

.sidebar .nav-link:hover,
.sidebar .nav-link.active {
    color: #fff;
    background: rgba(255,255,255,.1);
}

.sidebar .nav-link i {
    width: 24px;
    text-align: center;
    margin-right: 8px;
}

/* ===== Main Content ===== */
.main-content {
    margin-left: var(--sidebar-width);
    min-height: 100vh;
}

/* ===== Stat Cards ===== */
.stat-card {
    transition: transform .2s, box-shadow .2s;
}
.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,.1);
}

/* ===== Loading ===== */
.loading-spinner {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: spin .75s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ===== Status Badge ===== */
.badge-status-draft { background-color: #6c757d; }
.badge-status-scheduled { background-color: #fd7e14; color: #000; }
.badge-status-cancelled { background-color: #adb5bd; color: #000; }
.badge-status-sent { background-color: #198754; }
.badge-status-delivered { background-color: #0d6efd; }
.badge-status-opened { background-color: #6f42c1; }
.badge-status-clicked { background-color: #d63384; }
.badge-status-bounced { background-color: #dc3545; }
.badge-status-failed { background-color: #dc3545; }
.badge-status-queued { background-color: #ffc107; color: #000; }
.badge-status-sending { background-color: #0dcaf0; color: #000; }
.badge-status-complained { background-color: #6c757d; }

/* ===== Auth pages (no sidebar) ===== */
.auth-page {
    min-height: 100vh;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-card {
    max-width: 420px;
    width: 100%;
}

/* ===== Mobile Top Bar ===== */
.mobile-topbar {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 56px;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    z-index: 1100;
    align-items: center;
    padding: 0 16px;
}

.mobile-topbar .topbar-toggle {
    background: none;
    border: none;
    color: #fff;
    font-size: 1.4rem;
    padding: 4px 8px;
    cursor: pointer;
}

.mobile-topbar .topbar-brand {
    color: #fff;
    font-weight: 700;
    font-size: 1.05rem;
    margin-left: 10px;
}

/* ===== Sidebar Overlay ===== */
.sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.5);
    z-index: 999;
}
.sidebar-overlay.show {
    display: block;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .mobile-topbar {
        display: flex;
    }

    .sidebar {
        transform: translateX(-100%);
        transition: transform .3s ease;
        top: 0;
        bottom: 0;
        min-height: 100vh;
        z-index: 1050;
    }
    .sidebar.open {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0;
        padding-top: 56px;
    }
}

/* ===== Table ===== */
.table th { font-weight: 600; font-size: 0.85rem; color: #6c757d; text-transform: uppercase; }
.table td { vertical-align: middle; }

/* ===== Empty State ===== */
.empty-state {
    text-align: center;
    padding: 3rem;
    color: #6c757d;
}
.empty-state i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* ===== Spin Animation (for verify button) ===== */
.spin-animation {
    animation: spin 1s linear infinite;
}
@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}
