/* SYNCO Commercial & Recouvrement Application CSS - Smartphone & Desktop Responsive */
:root {
  --primary: #1e3a8a;
  --primary-dark: #172554;
  --secondary: #0d9488;
  --accent: #f59e0b;
  --danger: #ef4444;
  --success: #10b981;
  --warning: #f59e0b;
  --info: #3b82f6;
  --cardio: #e11d48;
  --labo: #059669;
  --radio: #2563eb;
}

html, body {
  overflow-x: hidden;
  max-width: 100vw;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background-color: #f8fafc;
  color: #1e293b;
  -webkit-tap-highlight-color: transparent;
}

/* Custom Scrollbars */
::-webkit-scrollbar {
  width: 5px;
  height: 5px;
}
::-webkit-scrollbar-track {
  background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Badge Badges */
.badge-diamant {
  background: linear-gradient(135deg, #a855f7 0%, #06b6d4 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(168, 85, 247, 0.3);
}

.badge-or {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

.badge-argent {
  background: linear-gradient(135deg, #94a3b8 0%, #64748b 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(100, 116, 139, 0.25);
}

.badge-bronze {
  background: linear-gradient(135deg, #b45309 0%, #78350f 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(180, 83, 9, 0.25);
}

.badge-vigilance {
  background: linear-gradient(135deg, #f43f5e 0%, #e11d48 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(244, 63, 94, 0.25);
}

/* Status Pills */
.status-payee {
  background-color: #dcfce7;
  color: #15803d;
  border: 1px solid #bbf7d0;
}

.status-en_cours {
  background-color: #dbeafe;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
}

.status-echue_1_30 {
  background-color: #fef9c3;
  color: #854d0e;
  border: 1px solid #fef08a;
}

.status-echue_31_60 {
  background-color: #ffedd5;
  color: #c2410c;
  border: 1px solid #fed7aa;
}

.status-echue_61_90 {
  background-color: #fee2e2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}

.status-echue_90_plus {
  background-color: #ffe4e6;
  color: #9f1239;
  font-weight: 700;
  border: 1px solid #fecdd3;
}

.status-litige {
  background-color: #f3e8ff;
  color: #6b21a8;
  border: 1px solid #e9d5ff;
}

/* Department Themes */
.tag-cardio {
  background-color: #ffe4e6;
  color: #be123c;
  border-left: 3px solid #e11d48;
}

.tag-labo {
  background-color: #d1fae5;
  color: #047857;
  border-left: 3px solid #059669;
}

.tag-radio {
  background-color: #dbeafe;
  color: #1d4ed8;
  border-left: 3px solid #2563eb;
}

/* Card hover animation */
.card-hover {
  transition: transform 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}
.card-hover:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px -3px rgba(0, 0, 0, 0.08);
}

/* Podium Styles */
.podium-first {
  background: linear-gradient(180deg, #fef3c7 0%, #fde68a 100%);
  border: 2px solid #f59e0b;
}

.podium-second {
  background: linear-gradient(180deg, #f1f5f9 0%, #e2e8f0 100%);
  border: 2px solid #94a3b8;
}

.podium-third {
  background: linear-gradient(180deg, #ffedd5 0%, #fed7aa 100%);
  border: 2px solid #ea580c;
}

/* Mobile Bottom Navigation Bar */
.mobile-bottom-nav {
  padding-bottom: env(safe-area-inset-bottom, 0.5rem);
}

.mobile-tab-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1;
  padding: 0.5rem 0.25rem;
  color: #64748b;
  font-size: 0.65rem;
  font-weight: 600;
  transition: color 0.15s ease;
  min-height: 48px;
}

.mobile-tab-btn.active {
  color: #2563eb;
}

.mobile-tab-btn i {
  font-size: 1.15rem;
  margin-bottom: 0.2rem;
}

/* Toast notifications */
#toast-container {
  position: fixed;
  bottom: 5.5rem;
  right: 1rem;
  left: 1rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  pointer-events: none;
}

@media (min-width: 640px) {
  #toast-container {
    left: auto;
    bottom: 1.5rem;
    right: 1.5rem;
    max-width: 400px;
  }
}

.toast {
  pointer-events: auto;
  animation: slideInMobile 0.25s ease-out;
}

@keyframes slideInMobile {
  from {
    transform: translateY(100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Smartphone Bottom Sheet Modal behavior on small screens */
@media (max-width: 640px) {
  .modal-sheet-container {
    align-items: flex-end !important;
  }
  
  .modal-sheet-content {
    border-bottom-left-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
    max-height: 85vh !important;
    width: 100% !important;
    margin: 0 !important;
  }
}
