::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: #ecf0fc; }
::-webkit-scrollbar-thumb { background: #1e4691; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #192b5c; }

/* Thin scrollbar for compact containers */
.scrollbar-thin::-webkit-scrollbar { width: 4px; }
.scrollbar-thin::-webkit-scrollbar-track { background: transparent; }
.scrollbar-thin::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 2px; }
.scrollbar-thin::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

/* RTL Support */
[dir="rtl"] { font-family: 'Tajawal', 'Plus Jakarta Sans', sans-serif; }
[dir="rtl"] .toast { transform: translateX(-120%); }
[dir="rtl"] .toast.show { transform: translateX(0); }
[dir="rtl"] .border-l-4 { border-left-width: 0; border-right-width: 4px; }
[dir="rtl"] .border-l-green-500 { border-left-color: transparent; border-right-color: #22c55e; }
[dir="rtl"] .border-l-slate-300 { border-left-color: transparent; border-right-color: #cbd5e1; }
[dir="rtl"] .border-l-yellow-500 { border-left-color: transparent; border-right-color: #eab308; }
[dir="rtl"] .border-l-primary { border-left-color: transparent; border-right-color: #1e4691; }
[dir="rtl"] .status-scheduled { border-left-color: transparent !important; border-right-color: #1e4691 !important; }
[dir="rtl"] .status-active { border-left-color: transparent !important; border-right-color: #f97316 !important; }
[dir="rtl"] .status-completed { border-left-color: transparent !important; border-right-color: #64748b !important; }
[dir="rtl"] .pl-7 { padding-left: 0; padding-right: 1.75rem; }
[dir="rtl"] .ml-auto { margin-left: 0; margin-right: auto; }
[dir="rtl"] .mr-1 { margin-right: 0; margin-left: 0.25rem; }
[dir="rtl"] .text-right { text-align: left; }
[dir="rtl"] .text-left { text-align: right; }
[dir="rtl"] #toast-container { right: auto; left: 1rem; }

.page { display: none; }
.page.active { display: block; }

/* Mobile bottom navigation safe area */
.safe-area-bottom { padding-bottom: env(safe-area-inset-bottom, 0); }

/* Add padding to main content on mobile for header and bottom nav */
@media (max-width: 767px) {
    main { padding-top: 60px; padding-bottom: 80px; }
}

/* Mobile nav button styles */
.mobile-nav-btn {
    flex: 1;
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    color: rgba(255, 255, 255, 0.7);
    transition: all 0.2s;
    cursor: pointer;
}
.nav-link:hover { background: rgba(255, 255, 255, 0.1); color: #ffffff; }
.nav-link.active { background: #f78f3a; color: white; }

.toast {
    transform: translateX(120%);
    transition: transform 0.3s ease;
}
.toast.show { transform: translateX(0); }

@keyframes pulse-border {
    0%, 100% { border-color: rgba(34, 197, 94, 0.5); }
    50% { border-color: rgba(34, 197, 94, 1); }
}
.compliant-border { animation: pulse-border 2s ease-in-out infinite; border-left-color: #22c55e !important; }
.non-compliant-border { border-left-color: #ef4444 !important; }

.event-card {
    transition: all 0.2s;
}
.event-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}

.status-scheduled { border-left-color: #1e4691 !important; }
.status-active { border-left-color: #f78f3a !important; }
.status-completed { border-left-color: #607bac !important; }

.btn-primary {
    background: linear-gradient(to right, #1e4691, #192b5c);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}
.btn-primary:hover { background: linear-gradient(to right, #192b5c, #192b5c); }

.btn-secondary {
    background: #ecf0fc;
    color: #192b5c;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-weight: 500;
    font-size: 0.875rem;
    border: 1px solid #e0e8ff;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}
.btn-secondary:hover { background: #e0e8ff; }

.btn-success {
    background: #22c55e;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 0.2s;
}
.btn-success:hover { background: #16a34a; }

.btn-danger {
    background: #ef4444;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 0.2s;
}
.btn-danger:hover { background: #dc2626; }

.input-field {
    background: #ffffff;
    border: 1px solid #e0e8ff;
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    color: #192b5c;
    font-size: 0.875rem;
    width: 100%;
    transition: border-color 0.2s;
    color-scheme: light;
}
.input-field:focus {
    outline: none;
    border-color: #1e4691;
}
/* Date/time input styling */
input[type="datetime-local"]::-webkit-calendar-picker-indicator,
input[type="date"]::-webkit-calendar-picker-indicator,
input[type="time"]::-webkit-calendar-picker-indicator {
    cursor: pointer;
    opacity: 0.7;
}
input[type="datetime-local"]::-webkit-calendar-picker-indicator:hover,
input[type="date"]::-webkit-calendar-picker-indicator:hover,
input[type="time"]::-webkit-calendar-picker-indicator:hover {
    opacity: 1;
}

/* Toggle switch */
.toggle-switch {
    position: relative;
    width: 36px;
    height: 20px;
    background: #cbd5e1;
    border-radius: 10px;
    cursor: pointer;
    transition: background 0.2s;
}
.toggle-switch.active {
    background: #1e4691;
}
.toggle-switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 16px;
    height: 16px;
    background: white;
    border-radius: 50%;
    transition: transform 0.2s;
}
.toggle-switch.active::after {
    transform: translateX(16px);
}
.toggle-switch.disabled {
    background: #e2e8f0;
    cursor: not-allowed;
    opacity: 0.5;
}
.toggle-switch.disabled::after {
    background: #cbd5e1;
}

.input-field::placeholder { color: #64748b; }

.card {
    background: #ffffff;
    border: 1px solid #e0e8ff;
    border-radius: 0.5rem;
    padding: 1.5rem;
    box-shadow: 0 0 8px 0 rgba(25, 43, 92, 0.2);
}

.table-header {
    background: #ecf0fc;
    font-size: 0.75rem;
    text-transform: uppercase;
    color: #192b5c;
    font-weight: 600;
}

.table-row:hover {
    background: #e0e8ff;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 0.625rem;
    border-radius: 9999px;
    font-size: 0.625rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-scheduled { background: rgba(30, 70, 145, 0.2); color: #1e4691; border: 1px solid rgba(30, 70, 145, 0.3); }
.badge-active { background: rgba(247, 143, 58, 0.2); color: #f78f3a; border: 1px solid rgba(247, 143, 58, 0.3); }
.badge-completed { background: rgba(96, 123, 172, 0.2); color: #607bac; border: 1px solid rgba(96, 123, 172, 0.3); }
.badge-pending { background: rgba(234, 179, 8, 0.2); color: #eab308; border: 1px solid rgba(234, 179, 8, 0.3); }
.badge-accepted { background: rgba(34, 197, 94, 0.2); color: #22c55e; border: 1px solid rgba(34, 197, 94, 0.3); }
.badge-declined { background: rgba(239, 68, 68, 0.2); color: #ef4444; border: 1px solid rgba(239, 68, 68, 0.3); }
.badge-no-response { background: rgba(100, 116, 139, 0.2); color: #94a3b8; border: 1px solid rgba(100, 116, 139, 0.3); }
.badge-compliant { background: rgba(34, 197, 94, 0.1); color: #22c55e; border: 1px solid rgba(34, 197, 94, 0.2); }
.badge-non-compliant { background: rgba(239, 68, 68, 0.1); color: #ef4444; border: 1px solid rgba(239, 68, 68, 0.2); }
.badge-cooldown { background: rgba(234, 179, 8, 0.2); color: #eab308; border: 1px solid rgba(234, 179, 8, 0.3); }

/* Stepper connector lines */
.step-connector::after {
    content: '';
    position: absolute;
    left: 12px;
    top: 24px;
    width: 2px;
    height: calc(100% - 8px);
    background-color: #e0e8ff;
    z-index: 0;
}

.stat-card {
    background: #ffffff;
    border: 1px solid #e0e8ff;
    border-radius: 0.5rem;
    padding: 1.25rem;
    position: relative;
    overflow: hidden;
    box-shadow: 0 0 8px 0 rgba(25, 43, 92, 0.15);
}
.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 80px;
    height: 80px;
    background: radial-gradient(circle, rgba(30, 70, 145, 0.1) 0%, transparent 70%);
}

.progress-bar {
    height: 6px;
    background: #e0e8ff;
    border-radius: 3px;
    overflow: hidden;
}
.progress-bar-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.5s ease;
}

.countdown {
    font-family: 'Montserrat', monospace;
    font-weight: 700;
}

.client-card {
    padding: 1rem;
    border-bottom: 1px solid #e0e8ff;
    cursor: pointer;
    transition: all 0.2s;
}
.client-card:hover { background: #e0e8ff; }
.client-card.selected {
    background: rgba(30, 70, 145, 0.1);
    border-left: 3px solid #1e4691;
}
