@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
    --bg-dark: #030014;
    --sidebar-bg: #0b071e;
    --card-bg: rgba(20, 16, 38, 0.6);
    --accent: #8b5cf6;
    --accent-glow: rgba(139, 92, 246, 0.35);
    --accent-gradient: linear-gradient(135deg, #8b5cf6 0%, #3b82f6 100%);
    --text-primary: #f8fafc;
    --text-secondary: #a78bfa;
    --border: rgba(255, 255, 255, 0.07);
    --border-hover: rgba(139, 92, 246, 0.35);
    --success: #10b981;
    --danger: #f43f5e;
    --warning: #f59e0b;
    --radius-lg: 20px;
    --radius-md: 12px;
    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
}

body {
    background-color: var(--bg-dark);
    background-image: 
        radial-gradient(at 0% 0%, rgba(139, 92, 246, 0.15) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(59, 130, 246, 0.15) 0px, transparent 50%),
        radial-gradient(at 50% 0%, rgba(244, 63, 94, 0.05) 0px, transparent 50%);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: var(--bg-dark);
}
::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--text-secondary);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 30px;
}

/* Glassmorphism */
.glass {
    background: var(--card-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.5);
    transition: var(--transition);
}

.glass:hover {
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-4px);
    box-shadow: 0 20px 50px -15px rgba(0, 0, 0, 0.6);
}

/* Sidebar Styling */
.sidebar {
    width: 280px;
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    background: var(--sidebar-bg);
    border-right: 1px solid var(--border);
    padding: 40px 24px;
    display: flex;
    flex-direction: column;
    z-index: 1100;
}

.logo-area {
    padding-bottom: 50px;
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-primary);
    text-decoration: none;
}

.logo-area i {
    color: var(--accent);
    width: 32px;
    height: 32px;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Nav Links */
.nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-weight: 500;
    transition: var(--transition);
    text-decoration: none;
    margin-bottom: 4px;
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    transform: translateX(5px);
}

.nav-link.active {
    background: var(--accent-gradient);
    color: white;
    box-shadow: 0 10px 20px -5px var(--accent-glow);
}

.nav-link i {
    width: 20px;
    height: 20px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 24px;
    border-radius: var(--radius-md);
    font-weight: 600;
    transition: var(--transition);
    cursor: pointer;
    border: 1px solid transparent;
    text-decoration: none;
    font-size: 0.95rem;
}

.btn-primary {
    background: var(--accent-gradient);
    color: white !important;
    box-shadow: 0 10px 25px -5px var(--accent-glow);
    border: none;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px -5px var(--accent-glow);
}

.btn-glass, .btn.glass {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    color: var(--text-primary) !important;
}

.btn-glass:hover, .btn.glass:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    color: var(--text-primary) !important;
}

.btn-secondary {
    background: rgba(139, 92, 246, 0.1);
    border: 1px solid rgba(139, 92, 246, 0.25);
    color: var(--text-secondary);
}

.btn-secondary:hover {
    background: rgba(139, 92, 246, 0.18);
    border-color: var(--accent);
    color: var(--text-primary);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px -5px var(--accent-glow);
}

.btn-danger {
    background: rgba(244, 63, 94, 0.1);
    border: 1px solid rgba(244, 63, 94, 0.25);
    color: var(--danger);
}

.btn-danger:hover {
    background: rgba(244, 63, 94, 0.18);
    border-color: var(--danger);
    color: white !important;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px -5px rgba(244, 63, 94, 0.35);
}

/* Badge Styling */
.badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    text-align: center;
    white-space: nowrap;
}

/* Main Content Area */
.main-content {
    margin-left: 280px;
    padding: 30px 30px;
    min-height: 100vh;
}

/* Header Refinement */
header.glass {
    margin-bottom: 20px !important;
    padding: 12px 24px;
    border-radius: var(--radius-md);
    background: rgba(30, 41, 59, 0.3);
    transition: var(--transition);
}

@media (min-width: 993px) {
    header.logged-in-header {
        margin-left: 280px;
    }
}

/* Layout Grid */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

/* Stat Card */
.stat-card {
    padding: 30px;
}

.stat-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.stat-card h2 {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(to bottom, #fff, #94a3b8);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Tables */
.table-glass {
    padding: 25px;
}

table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 12px;
}

th {
    padding: 0 20px 10px;
    text-align: left;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 1px;
}

td {
    padding: 18px 20px;
    background: rgba(255, 255, 255, 0.03);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}

td:first-child {
    border-left: 1px solid var(--border);
    border-radius: var(--radius-md) 0 0 var(--radius-md);
}

td:last-child {
    border-right: 1px solid var(--border);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

.form-control {
    width: 100%;
    padding: 12px 18px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--accent);
    background: rgba(255, 255, 255, 0.07);
    box-shadow: 0 0 0 4px var(--accent-glow);
}

select.form-control {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-color: #0b071e !important;
    color: #f8fafc !important;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a78bfa' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e") !important;
    background-repeat: no-repeat !important;
    background-position: right 15px center !important;
    background-size: 15px !important;
    padding-right: 40px !important;
}

select.form-control option {
    background-color: #0b071e !important;
    color: #f8fafc !important;
    padding: 12px !important;
}

select.form-control option:hover,
select.form-control option:focus {
    background-color: var(--accent) !important;
    color: #ffffff !important;
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-weight: 500;
}

/* Mobile Bottom Navigation */
.bottom-nav {
    display: none;
}

@media (max-width: 992px) {
    .sidebar {
        position: fixed;
        left: -280px; /* Hidden off-screen */
        top: 0;
        width: 280px;
        height: 100vh;
        background: var(--sidebar-bg);
        border-right: 1px solid var(--border);
        box-shadow: 20px 0 50px rgba(0, 0, 0, 0.7);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 2500;
        display: flex !important; /* Force display when active */
    }
    
    .sidebar.active {
        transform: translateX(280px);
    }
    
    .sidebar-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        background: rgba(3, 0, 20, 0.6);
        backdrop-filter: blur(4px);
        -webkit-backdrop-filter: blur(4px);
        z-index: 2400;
        animation: fadeIn 0.2s ease-out;
    }
    
    .sidebar-overlay.active {
        display: block;
    }

    .main-content {
        margin-left: 0;
        padding: 20px 20px calc(88px + env(safe-area-inset-bottom, 0px)) 20px;
    }
    
    .bottom-nav {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        height: calc(72px + env(safe-area-inset-bottom, 0px));
        padding: 8px 10px calc(8px + env(safe-area-inset-bottom, 0px));
        background: rgba(11, 7, 30, 0.95);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border: none;
        border-top: 1px solid var(--border);
        border-radius: 0;
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 4px;
        z-index: 1200;
        box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.45);
    }

    .bottom-nav-indicator {
        position: absolute;
        top: 8px;
        left: 0;
        height: calc(100% - 16px);
        width: 0;
        border-radius: 20px;
        background: var(--accent-gradient);
        box-shadow: 0 8px 24px -6px var(--accent-glow);
        transition:
            left 0.38s cubic-bezier(0.34, 1.35, 0.64, 1),
            width 0.38s cubic-bezier(0.34, 1.35, 0.64, 1),
            opacity 0.25s ease;
        z-index: 0;
        pointer-events: none;
        opacity: 0;
    }

    .bottom-nav-indicator.is-visible {
        opacity: 1;
    }

    .bottom-nav-item {
        position: relative;
        z-index: 1;
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 0;
        min-width: 0;
        height: 100%;
        padding: 8px 4px;
        border-radius: 20px;
        color: var(--text-secondary);
        text-decoration: none;
        font-size: 0.68rem;
        font-weight: 600;
        letter-spacing: 0.02em;
        -webkit-tap-highlight-color: transparent;
        transition: color 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .bottom-nav-item svg,
    .bottom-nav-item i {
        width: 22px;
        height: 22px;
        stroke-width: 2;
        transition:
            color 0.3s cubic-bezier(0.4, 0, 0.2, 1),
            stroke 0.3s cubic-bezier(0.4, 0, 0.2, 1),
            transform 0.35s cubic-bezier(0.34, 1.35, 0.64, 1);
    }

    .bottom-nav-item.active {
        color: #fff;
    }

    .bottom-nav-item.active svg,
    .bottom-nav-item.active i {
        color: #fff;
        stroke: #fff;
        transform: scale(1.1) translateY(-1px);
    }

    .bottom-nav-item:not(.active):active svg,
    .bottom-nav-item:not(.active):active i {
        transform: scale(0.92);
    }

    .bottom-nav-item.active:active svg,
    .bottom-nav-item.active:active i {
        transform: scale(1.04) translateY(-1px);
    }

    .page-header-title {
        font-size: clamp(0.82rem, 3.8vw, 1rem) !important;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: calc(100vw - 155px);
        line-height: 1.3;
    }

    header.logged-in-header > div:first-child {
        min-width: 0;
        flex: 1;
    }

    header.logged-in-header .btn-glass {
        display: none;
    }

    .desktop-table-wrap {
        display: none !important;
    }

.mobile-card-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 20px;
}
}

@media (min-width: 993px) {
    .mobile-card-list {
        display: none !important;
    }
}

/* Mobile record cards */
.record-card {
    background: rgba(20, 16, 38, 0.75);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 16px;
    transition: var(--transition);
}

.record-card:active {
    transform: scale(0.99);
}

.record-card-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 12px;
}

.record-card-id {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--accent);
    background: rgba(139, 92, 246, 0.12);
    padding: 4px 10px;
    border-radius: 8px;
    border: 1px solid rgba(139, 92, 246, 0.25);
}

.record-card-status {
    font-size: 0.68rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.record-card-status--open,
.record-card-status--pending {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.record-card-status--closed,
.record-card-status--complete {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.record-card-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px 14px;
}

.record-card-field {
    min-width: 0;
}

.record-card-field--full {
    grid-column: 1 / -1;
}

.record-card-field-label {
    display: block;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-bottom: 3px;
    opacity: 0.85;
}

.record-card-field-value {
    display: block;
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text-primary);
    word-break: break-word;
}

.record-card-actions {
    display: flex;
    justify-content: space-between;
    gap: 6px;
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid var(--border);
}

.action-btn {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    border-radius: 10px;
    border: 1px solid transparent;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    background: rgba(255, 255, 255, 0.04);
}

.action-btn svg,
.action-btn i {
    width: 17px;
    height: 17px;
}

.action-btn--view { color: #60a5fa; background: rgba(59, 130, 246, 0.12); border-color: rgba(59, 130, 246, 0.25); }
.action-btn--edit { color: #a78bfa; background: rgba(139, 92, 246, 0.12); border-color: rgba(139, 92, 246, 0.25); }
.action-btn--remark { color: #fbbf24; background: rgba(245, 158, 11, 0.12); border-color: rgba(245, 158, 11, 0.25); }
.action-btn--call { color: #34d399; background: rgba(16, 185, 129, 0.12); border-color: rgba(16, 185, 129, 0.25); }
.action-btn--delete { color: #fb7185; background: rgba(244, 63, 94, 0.12); border-color: rgba(244, 63, 94, 0.25); }

.action-btn:active { transform: scale(0.93); }

/* Custom confirm & remark modals */
.app-modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 3000;
    background: rgba(3, 0, 20, 0.82);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.app-modal-overlay.is-open {
    opacity: 1;
}

.app-modal-box {
    width: 100%;
    max-width: 400px;
    background: var(--sidebar-bg);
    border: 1px solid var(--border-hover);
    border-radius: var(--radius-lg);
    padding: 28px 24px 24px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.55);
    transform: translateY(12px) scale(0.97);
    transition: transform 0.25s cubic-bezier(0.34, 1.35, 0.64, 1);
}

.app-modal-overlay.is-open .app-modal-box {
    transform: translateY(0) scale(1);
}

.app-modal-box--wide {
    max-width: 680px;
    max-height: 90vh;
    overflow-y: auto;
}

.confirm-icon-wrap {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: rgba(244, 63, 94, 0.12);
    border: 1px solid rgba(244, 63, 94, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    color: var(--danger);
}

.confirm-icon-wrap svg { width: 24px; height: 24px; }

.confirm-title {
    text-align: center;
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.confirm-message {
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 24px;
    line-height: 1.5;
}

.confirm-actions {
    display: flex;
    gap: 10px;
}

.confirm-actions .btn {
    flex: 1;
    justify-content: center;
    padding: 12px;
}

/* Detail modal redesign */
.detail-modal-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 24px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border);
}

.detail-modal-icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 8px 24px var(--accent-glow);
}

.detail-modal-icon svg { width: 24px; height: 24px; color: #fff; }

.detail-modal-label {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-secondary);
}

.detail-modal-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin: 4px 0 8px;
    word-break: break-word;
}

.detail-status-badge {
    display: inline-block;
    font-size: 0.68rem;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.detail-status-badge--open,
.detail-status-badge--pending {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.detail-status-badge--closed,
.detail-status-badge--complete {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.detail-section {
    margin-bottom: 20px;
}

/* Password toggle button (show/hide) */
.password-toggle {
    position: absolute;
    right: 12px;
    top: 8px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    cursor: pointer;
    padding: 0;
}
.password-toggle:focus {
    outline: none;
    box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.12);
    border-radius: 8px;
}

.detail-section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 12px;
}

.detail-section-title svg { width: 14px; height: 14px; }

.detail-fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.detail-field {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 12px 14px;
}

.detail-field--full { grid-column: 1 / -1; }

.detail-field-label {
    display: block;
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.detail-field-value {
    display: block;
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text-primary);
    word-break: break-word;
    line-height: 1.45;
}

.detail-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.detail-modal-close:hover {
    background: rgba(244, 63, 94, 0.15);
    color: var(--danger);
    border-color: rgba(244, 63, 94, 0.3);
}

/* Colored dashboard stat cards */
.stat-card--helpline {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.18) 0%, rgba(59, 130, 246, 0.08) 100%);
    border-color: rgba(139, 92, 246, 0.35) !important;
    position: relative;
    overflow: hidden;
}

.stat-card--helpline::before {
    content: '';
    position: absolute;
    top: -30px;
    right: -30px;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.25) 0%, transparent 70%);
    pointer-events: none;
}

.stat-card--cases {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.18) 0%, rgba(6, 182, 212, 0.08) 100%);
    border-color: rgba(59, 130, 246, 0.35) !important;
    position: relative;
    overflow: hidden;
}

.stat-card--cases::before {
    content: '';
    position: absolute;
    top: -30px;
    right: -30px;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.25) 0%, transparent 70%);
    pointer-events: none;
}

.stat-card--tasks {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.18) 0%, rgba(244, 63, 94, 0.08) 100%);
    border-color: rgba(245, 158, 11, 0.35) !important;
    position: relative;
    overflow: hidden;
}

.stat-card--tasks::before {
    content: '';
    position: absolute;
    top: -30px;
    right: -30px;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(245, 158, 11, 0.25) 0%, transparent 70%);
    pointer-events: none;
}

.stat-card-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
}

.stat-card-icon svg { width: 22px; height: 22px; }

.stat-card-icon--purple { background: rgba(139, 92, 246, 0.2); color: #a78bfa; }
.stat-card-icon--blue { background: rgba(59, 130, 246, 0.2); color: #60a5fa; }
.stat-card-icon--amber { background: rgba(245, 158, 11, 0.2); color: #fbbf24; }

.stat-card-count {
    font-size: 2.4rem;
    font-weight: 800;
    line-height: 1;
    margin: 6px 0 12px;
}

.stat-card-count--purple {
    background: linear-gradient(135deg, #c4b5fd, #8b5cf6);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.stat-card-count--blue {
    background: linear-gradient(135deg, #93c5fd, #3b82f6);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.stat-card-count--amber {
    background: linear-gradient(135deg, #fcd34d, #f59e0b);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

@media (max-width: 992px) {
    .detail-fields {
        grid-template-columns: 1fr;
    }

    .stat-card-count {
        font-size: 2rem;
    }
}

/* Utility Animations */
.fade-in {
    animation: fadeIn 0.8s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Badge Styling */
.badge {
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 9999;
    max-width: 380px;
    width: calc(100% - 40px);
}

.toast {
    position: relative;
    background: rgba(11, 7, 30, 0.9);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    gap: 15px;
    overflow: hidden;
    transform: translateX(120%);
    transition: transform 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s;
    opacity: 0;
}

.toast.show {
    transform: translateX(0);
    opacity: 1;
}

.toast.hide {
    transform: translateX(120%);
    opacity: 0;
}

.toast-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    flex-shrink: 0;
}

.toast-success {
    border-left: 4px solid var(--success);
}
.toast-success .toast-icon {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.toast-danger {
    border-left: 4px solid var(--danger);
}
.toast-danger .toast-icon {
    background: rgba(244, 63, 94, 0.15);
    color: var(--danger);
}

.toast-warning {
    border-left: 4px solid var(--warning);
}
.toast-warning .toast-icon {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.toast-content {
    flex: 1;
}

.toast-title {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.toast-msg {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.toast-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    transition: var(--transition);
}

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

.toast-timeline {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: var(--accent-gradient);
    width: 100%;
}

@keyframes shrink {
    from { width: 100%; }
    to { width: 0%; }
}
