* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary-green: #10b981;
  --primary-green-dark: #059669;
  --primary-green-darker: #047857;
  --secondary-green: #34d399;
  --light-green: #d1fae5;
  --accent-blue: #3b82f6;
  --accent-purple: #8b5cf6;
  --warning-orange: #f59e0b;
  --danger-red: #ef4444;
  --success-green: #10b981;
}

body {
  font-family: "Inter", sans-serif;
  line-height: 1.6;
  color: #111827;
  background-color: #f9fafb;
}

/* Header */
.header {
  background: white;
  border-bottom: 1px solid #e5e7eb;
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 70px;
}

.logo {
  display: flex;
  align-items: center;
  font-size: 20px;
  font-weight: 700;
  color: #059669;
  cursor: pointer;
  text-decoration: none;
}

.logo-icon {
  width: 28px;
  height: 28px;
  margin-right: 8px;
  background: #059669;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 14px;
  font-weight: 700;
}

.logo-text {
  display: flex;
  flex-direction: column;
}

.logo-main {
  font-size: 20px;
  font-weight: 700;
  color: #059669;
  line-height: 1;
}

.logo-subtitle {
  font-size: 10px;
  font-weight: 500;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  line-height: 1;
  margin-top: 1px;
}

.breadcrumb {
  display: flex;
  align-items: center;
  color: #6b7280;
  font-size: 14px;
}

.breadcrumb a {
  color: #059669;
  text-decoration: none;
}

.breadcrumb span {
  margin: 0 8px;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 15px;
}

#userEmailDisplay {
  font-size: 16px;
  color: #374151;
  font-weight: 500;
}

#userEmailDisplay:hover {
  color: #39475f;
  /* cursor: pointer; */
}

#userNameDisplay {
  font-size: 14px;
  color: #6b7280;
  font-weight: 500;
}
#userNameDisplay:hover {
  color: #39475f;
  /* cursor: pointer; */
}
.btn {
  padding: 10px 20px;
  border: none;
  border-radius: 8px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
  text-decoration: none;
  display: inline-block;
  text-align: center;
  font-size: 14px;
}

.btn-primary {
  background: linear-gradient(
    135deg,
    var(--primary-green) 0%,
    var(--primary-green-dark) 100%
  );
  color: white;
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
}

.btn-primary:hover {
  background: linear-gradient(
    135deg,
    var(--primary-green-dark) 0%,
    var(--primary-green-darker) 100%
  );
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
}

.btn-outline {
  background: transparent;
  color: var(--primary-green-dark);
  border: 2px solid var(--primary-green);
}

.btn-outline:hover {
  background: var(--primary-green);
  color: white;
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
}

.btn-secondary {
  background: #f3f4f6;
  color: #374151;
  border: 1px solid #d1d5db;
}

.btn-secondary:hover {
  background: #e5e7eb;
}

.btn-warning {
  background: var(--warning-orange);
  color: white;
}

.btn-danger {
  background: var(--danger-red);
  color: white;
}

.btn-success {
  background: var(--success-green);
  color: white;
}

.btn-purple {
  background: var(--accent-purple);
  color: white;
}

.btn-small {
  padding: 6px 12px;
  font-size: 12px;
}

/* Main Layout */
.main-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 20px;
  display: flex;
  gap: 30px;
}

.sidebar {
  width: 280px;
  background: white;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  padding: 25px;
  height: fit-content;
  position: sticky;
  top: 90px;
}

.agent-icon {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, var(--light-green) 0%, #ecfdf5 100%);
  color: var(--primary-green-dark);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  margin: 0 auto 15px;
  box-shadow: 0 8px 25px rgba(16, 185, 129, 0.15);
}

.agent-title {
  font-size: 20px;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 8px;
}

.agent-status {
  /* display: inline-block; */
  padding: 4px 8px;
  background: var(--light-green);
  color: var(--primary-green-dark);
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
}

.calling-agent-direction {
  display: inline-block;
  padding: 4px 6px;
  background: #e0e7ff;
  /* color: var(--primary-green-dark); */
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  min-width: 70px;
  /* text-transform: uppercase; */
  white-space: nowrap;
}

.agent-status-direction {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.workflow-nav {
  list-style: none;
  margin-top: 25px;
}

.workflow-nav li {
  margin-bottom: 8px;
}

.workflow-nav a,
.nav-btn {
  display: flex;
  align-items: center;
  padding: 12px 15px;
  text-decoration: none;
  color: #6b7280;
  border-radius: 8px;
  transition: all 0.3s;
  font-size: 14px;
  border: none;
  background: none;
  width: 100%;
  cursor: pointer;
  font-family: inherit;
}

.workflow-nav a:hover,
.workflow-nav a.active,
.nav-btn:hover,
.nav-btn.active {
  background: linear-gradient(
    135deg,
    var(--primary-green) 0%,
    var(--primary-green-dark) 100%
  );
  color: white;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.step-number {
  background: #e5e7eb;
  color: #6b7280;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 600;
  margin-right: 12px;
}

.workflow-nav a.active .step-number,
.nav-btn.active .step-number {
  background: white;
  color: var(--primary-green-dark);
}

/* Main Content */
.main-content {
  flex: 1;
  background: white;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  padding: 30px;
}

.step-section {
  display: none;
}

.step-section.active {
  display: block;
}

.step-header {
  margin-bottom: 25px;
}

.step-title {
  font-size: 24px;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 8px;
}

.step-description {
  color: #6b7280;
  font-size: 16px;
}

/* Hero Stats */
.hero-stats {
  background: linear-gradient(
    135deg,
    var(--primary-green) 0%,
    var(--primary-green-dark) 100%
  );
  color: white;
  padding: 2rem;
  border-radius: 12px;
  margin-bottom: 25px;
  position: relative;
  overflow: hidden;
}

.hero-stats::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
  opacity: 0.3;
}

.stats-container {
  position: relative;
  z-index: 2;
}

.stats-header {
  text-align: center;
  margin-bottom: 2rem;
}

.stats-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.stats-subtitle {
  font-size: 1rem;
  opacity: 0.9;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1.5rem;
}

.stat-card {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  padding: 1.5rem;
  text-align: center;
  backdrop-filter: blur(20px);
  transition: all 0.3s ease;
}

.stat-card:hover {
  transform: translateY(-3px);
  background: rgba(255, 255, 255, 0.15);
}

.stat-value {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.stat-label {
  font-size: 0.8rem;
  opacity: 0.9;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.stat-change {
  font-size: 0.7rem;
  margin-top: 0.5rem;
  opacity: 0.8;
}

/* Cards and Grid */
.grid {
  display: grid;
  gap: 20px;
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.card {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 20px;
  transition: all 0.3s;
}

.card:hover {
  border-color: var(--primary-green);
  box-shadow: 0 8px 25px rgba(16, 185, 129, 0.1);
  transform: translateY(-2px);
}

.card-header {
  display: flex;
  align-items: center;
  margin-bottom: 15px;
}

.card-icon {
  width: 50px;
  height: 50px;
  background: linear-gradient(135deg, var(--light-green) 0%, #ecfdf5 100%);
  color: var(--primary-green-dark);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  margin-right: 15px;
}

.card-title {
  font-size: 18px;
  font-weight: 600;
  color: #1f2937;
}

.card-content {
  color: #6b7280;
  margin-bottom: 20px;
}

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

/* Agent Cards */
.agents-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 20px;
}

.agent-card {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 20px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.agent-card:hover {
  transform: translateY(-5px);
  border-color: var(--primary-green);
  box-shadow: 0 10px 25px rgba(16, 185, 129, 0.15);
}

.agent-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(
    135deg,
    var(--primary-green) 0%,
    var(--primary-green-dark) 100%
  );
}

.agent-header-card {
  display: flex;
  gap: 15px;
  margin-bottom: 15px;
}

.agent-avatar {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  background: linear-gradient(
    135deg,
    var(--primary-green) 0%,
    var(--primary-green-dark) 100%
  );
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 700;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.agent-info {
  flex: 1;
  min-width: 0;
}

.agent-name {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: #1f2937;
}

.agent-status-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.status-active {
  background: rgba(34, 197, 94, 0.1);
  color: #15803d;
}

.status-training {
  background: rgba(245, 158, 11, 0.1);
  color: #d97706;
}

.status-offline {
  background: rgba(239, 68, 68, 0.1);
  color: #dc2626;
}

.agent-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 15px;
}

.metric-card {
  background: rgba(16, 185, 129, 0.05);
  border-radius: 8px;
  padding: 12px;
  text-align: center;
}

.metric-value {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--primary-green);
  margin-bottom: 0.25rem;
}

.metric-label {
  font-size: 0.7rem;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.agent-details {
  margin-bottom: 15px;
}

.agent-detail {
  margin-top: 12px;
  font-size: 0.85rem;
  color: #4b5563;
  padding: 6px 10px;
  background-color: #f3f4f6;
  border-radius: 6px;
}

.detail-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
  font-size: 0.85rem;
}

.detail-label {
  color: #6b7280;
}

.detail-value {
  font-weight: 500;
  color: #1f2937;
}

.agent-capabilities {
  margin-bottom: 15px;
}

.capabilities-title {
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: #1f2937;
}

.capability-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.capability-tag {
  padding: 0.25rem 0.75rem;
  background: rgba(52, 152, 219, 0.1);
  color: var(--accent-blue);
  border-radius: 15px;
  font-size: 0.7rem;
  font-weight: 500;
}

.agent-description {
  font-size: 0.85rem;
  color: #6b7280;
  margin-bottom: 15px;
  line-height: 1.4;
}

.agent-actions {
  display: flex;
  gap: 8px;
}

/* Controls Section */
.controls-container {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 25px;
}

.search-container {
  flex: 1;
  max-width: 400px;
  position: relative;
}

.search-input {
  width: 100%;
  padding: 10px 15px 10px 40px;
  border: 1px solid #d1d5db;
  border-radius: 25px;
  background: white;
  transition: all 0.3s ease;
  outline: none;
}

.search-input:focus {
  border-color: var(--primary-green);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

.search-icon {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: #6b7280;
}

.filters-container {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.filter-pill {
  padding: 8px 16px;
  background: rgba(16, 185, 129, 0.1);
  color: var(--primary-green);
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.8rem;
  font-weight: 500;
}

.filter-pill:hover,
.filter-pill.active {
  background: var(--primary-green);
  color: white;
  border-color: var(--primary-green);
  transform: translateY(-1px);
}

/* Call Scheduling Styles */
.campaign-builder {
  background: linear-gradient(
    135deg,
    rgba(16, 185, 129, 0.05) 0%,
    rgba(16, 185, 129, 0.02) 100%
  );
  border: 2px dashed var(--primary-green);
  border-radius: 12px;
  padding: 30px;
  text-align: center;
  margin-bottom: 25px;
  transition: all 0.3s ease;
}

.campaign-builder:hover {
  background: linear-gradient(
    135deg,
    rgba(16, 185, 129, 0.08) 0%,
    rgba(16, 185, 129, 0.04) 100%
  );
  border-color: var(--primary-green-dark);
}

.upload-area {
  border: 2px dashed #d1d5db;
  border-radius: 8px;
  padding: 40px 20px;
  text-align: center;
  transition: all 0.3s ease;
  cursor: pointer;
  background: #fafafa;
}

.upload-area:hover {
  border-color: var(--primary-green);
  background: rgba(16, 185, 129, 0.02);
}

.upload-area.dragover {
  border-color: var(--primary-green);
  background: rgba(16, 185, 129, 0.05);
}

.upload-area.processing {
  background: rgba(59, 130, 246, 0.05) !important;
  border: 2px dashed #3b82f6 !important;
}

.upload-area.success {
  background: rgba(16, 185, 129, 0.05) !important;
  border: 2px dashed #10b981 !important;
}

#csvUploadArea .upload-area {
  transition: all 0.3s ease;
}

.contact-list {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  max-height: 300px;
  overflow-y: auto;
}

.contact-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid #f3f4f6;
  transition: all 0.3s ease;
}

.contact-item:hover {
  background: rgba(16, 185, 129, 0.02);
}

.contact-item:last-child {
  border-bottom: none;
}

/* Recording Styles */
.recording-card {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 15px;
  transition: all 0.3s ease;
}

.recording-card:hover {
  border-color: var(--primary-green);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.1);
}

.recording-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}

.recording-info {
  flex: 1;
}

.recording-title {
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 4px;
}

.recording-meta {
  color: #6b7280;
  font-size: 0.9rem;
}

.audio-player {
  width: 100%;
  height: 40px;
  margin: 15px 0;
  border-radius: 20px;
  outline: none;
}

.audio-player::-webkit-media-controls-panel {
  background-color: var(--light-green);
}

.recording-actions {
  display: flex;
  gap: 8px;
  margin-top: 15px;
}

/* Document Upload Styles */
.knowledge-base {
  background: linear-gradient(
    135deg,
    rgba(59, 130, 246, 0.05) 0%,
    rgba(139, 92, 246, 0.05) 100%
  );
  border: 1px solid rgba(59, 130, 246, 0.2);
  border-radius: 12px;
  padding: 25px;
  margin-bottom: 25px;
}

.document-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 15px;
  margin-top: 20px;
}

.document-card {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 15px;
  transition: all 0.3s ease;
}

.document-card:hover {
  border-color: var(--accent-blue);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.1);
}

.doc-icon {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
  color: white;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
  font-size: 16px;
}

.training-progress {
  background: #f3f4f6;
  border-radius: 8px;
  height: 8px;
  overflow: hidden;
  margin: 10px 0;
}

.progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--primary-green), var(--accent-blue));
  transition: width 0.5s ease;
}

/* Voice Cloning Styles */
.voice-studio {
  background: linear-gradient(
    135deg,
    rgba(139, 92, 246, 0.05) 0%,
    rgba(236, 72, 153, 0.05) 100%
  );
  border: 1px solid rgba(139, 92, 246, 0.2);
  border-radius: 12px;
  padding: 25px;
  margin-bottom: 25px;
}

.voice-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.voice-card {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 20px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.voice-card:hover {
  border-color: var(--accent-purple);
  box-shadow: 0 8px 25px rgba(139, 92, 246, 0.15);
  transform: translateY(-2px);
}

.voice-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-purple), #ec4899);
}

.voice-avatar {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, var(--accent-purple), #ec4899);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 24px;
  margin: 0 auto 15px;
}

.waveform {
  height: 60px;
  background: rgba(139, 92, 246, 0.1);
  border-radius: 8px;
  margin: 15px 0;
  position: relative;
  overflow: hidden;
}

.waveform::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(139, 92, 246, 0.3) 25%,
    rgba(139, 92, 246, 0.5) 50%,
    rgba(139, 92, 246, 0.3) 75%,
    transparent 100%
  );
  animation: waveAnimation 2s ease-in-out infinite;
}

@keyframes waveAnimation {
  0%,
  100% {
    transform: scaleY(0.3);
  }
  50% {
    transform: scaleY(1);
  }
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 2000;
  backdrop-filter: blur(4px);
  align-items: center;
  justify-content: center;
}

.modal.show {
  display: flex;
}

.modal-content {
  background: white;
  border-radius: 12px;
  padding: 10px;
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
  transform: scale(0.9);
  transition: all 0.3s ease;
}

.modal.show .modal-content {
  transform: scale(1);
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  color: #6b7280;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.modal-close:hover {
  background: rgba(0, 0, 0, 0.1);
  color: #1f2937;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}

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

.form-group.full-width {
  grid-column: 1 / -1;
}

.form-label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  color: #374151;
  font-size: 0.9rem;
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  transition: all 0.3s ease;
  outline: none;
  background: white;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--primary-green);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

.form-textarea {
  resize: vertical;
  min-height: 100px;
}

.form-actions {
  display: flex;
  gap: 15px;
  margin-top: 25px;
}

/* Role Badge */
.role-badge {
  display: inline-block;
  padding: 4px 12px;
  background: #ddd6fe;
  color: #7c3aed;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  margin-left: 10px;
}

/* Notification */
.notification {
  position: fixed;
  top: 100px;
  right: 20px;
  background: var(--primary-green);
  color: white;
  padding: 15px 20px;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(16, 185, 129, 0.3);
  z-index: 3000;
  transform: translateX(400px);
  transition: all 0.3s ease;
}

.notification.show {
  transform: translateX(0);
}

.notification-content {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Status Indicators */
.status-indicator {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 8px;
}

.status-active .status-indicator {
  background: #10b981;
  animation: pulse 2s infinite;
}

.status-scheduled .status-indicator {
  background: #f59e0b;
}

.status-completed .status-indicator {
  background: #6b7280;
}

@keyframes pulse {
  0% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
  100% {
    opacity: 1;
  }
}

/* Responsive */
@media (max-width: 768px) {
  .main-container {
    flex-direction: column;
    padding: 15px;
  }

  .sidebar {
    width: 100%;
    position: static;
  }

  .workflow-nav {
    display: flex;
    overflow-x: auto;
    gap: 10px;
  }

  .workflow-nav li {
    flex-shrink: 0;
    margin-bottom: 0;
  }

  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }

  .controls-container {
    flex-direction: column;
    align-items: stretch;
  }

  .agents-grid,
  .document-grid,
  .voice-grid {
    grid-template-columns: 1fr;
  }

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

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.rag-success-message {
  background: linear-gradient(
    135deg,
    rgba(34, 197, 94, 0.1) 0%,
    rgba(16, 185, 129, 0.1) 100%
  );
  border: 2px solid #10b981;
  border-radius: 12px;
  padding: 20px;
  margin-top: 20px;
  text-align: center;
  animation: fadeIn 0.5s ease-in-out;
}

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

.spinner {
  border: 2px solid #f3f3f3;
  border-top: 2px solid #8b5cf6;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  animation: spin 1s linear infinite;
  display: inline-block;
  margin-right: 8px;
  vertical-align: middle;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.btn-loading {
  opacity: 0.7;
  pointer-events: none;
}

.call-popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: none;
  z-index: 9999;
  align-items: center;
  justify-content: center;
}

.call-popup-overlay.show {
  display: flex;
}

.call-popup {
  background: white;
  border-radius: 12px;
  padding: 30px;
  max-width: 400px;
  width: 90%;
  text-align: center;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  animation: popupSlideIn 0.3s ease-out;
}

@keyframes popupSlideIn {
  from {
    transform: scale(0.9) translateY(-10px);
    opacity: 0;
  }
  to {
    transform: scale(1) translateY(0);
    opacity: 1;
  }
}

.calling-spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #f3f4f6;
  border-top: 4px solid #10b981;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 20px auto;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.popup-btn {
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
  margin: 5px;
}

.popup-btn-primary {
  background: #10b981;
  color: white;
}

.popup-btn-secondary {
  background: #f3f4f6;
  color: #374151;
}

/* UI Enhancements for CSV Doctor List */
.csv-contacts-display {
  background-color: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 20px;
  animation: fadeIn 0.5s ease-in-out;
}

.csv-preview-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 1px solid #e5e7eb;
}

.csv-preview-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary-green, #10b981);
}

.csv-clear-btn {
  background-color: #fef2f2;
  color: #ef4444;
  border: 1px solid #fecaca;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s;
}

.csv-clear-btn:hover {
  background-color: #fee2e2;
}

.csv-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  margin-bottom: 20px;
}
.csv-stat {
  background-color: #fff;
  border: 1px solid #e5e7eb;
  padding: 15px;
  border-radius: 8px;
  text-align: center;
}
.csv-stat-value {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--primary-green, #10b981);
}
.csv-stat-label {
  font-size: 0.8rem;
  color: #6b7280;
  margin-top: 5px;
}

.doctor-list-container {
  max-height: 400px;
  overflow-y: auto;
  padding-right: 10px; /* space for scrollbar */
}

.doctor-list-container::-webkit-scrollbar {
  width: 8px;
}

.doctor-list-container::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 10px;
}

.doctor-list-container::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 10px;
}

.doctor-list-container::-webkit-scrollbar-thumb:hover {
  background: #aaa;
}

.csv-contact-item {
  background-color: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 15px;
  margin-bottom: 12px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  transition: box-shadow 0.2s, transform 0.2s;
}

.csv-contact-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.07);
}

.csv-contact-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.csv-contact-name {
  font-weight: 600;
  color: #1f2937;
}

.csv-contact-meta {
  font-size: 0.85rem;
  color: #6b7280;
  margin-bottom: 12px;
}

.csv-contact-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

/* Helper class to hide/show campaigns */
.hidden {
  display: none !important;
}

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

/* Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

/* .modal-container {
    background: white;
    border-radius: 12px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    width: 90%;
    max-width: 600px;
    min-height: 400px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
} */

/* .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 24px 0 24px;
    border-bottom: 1px solid #e5e7eb;
    margin-bottom: 24px;
} */

.modal-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-green);
  margin: 0;
}

.modal-close {
  background: none;
  border: none;
  font-size: 2rem;
  color: #6b7280;
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: all 0.2s;
}

.modal-close:hover {
  background: #f3f4f6;
  color: #374151;
}

.form-group label {
  display: block;
  font-weight: 600;
  color: #374151;
  margin-bottom: 8px;
  font-size: 0.9rem;
}

.required {
  color: #ef4444;
}

.optional {
  color: #6b7280;
  font-weight: 400;
}

.form-group input,
.form-group textarea {
  width: 100%;
  min-height: 25px;
  line-height: 1.5;
  padding: 12px 16px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 0.9rem;
  transition: all 0.2s ease;
  font-family: inherit;
  resize: vertical;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary-green);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  padding: 24px;
  border-top: 1px solid #e5e7eb;
  margin-top: 24px;
}

.modal-footer.hidden {
  display: none;
}

.modal-content.hidden {
  display: none;
}

.success-message {
  background: linear-gradient(
    135deg,
    rgba(16, 185, 129, 0.95) 0%,
    rgba(5, 150, 105, 0.95) 100%
  );
  color: white;
  padding: 30px;
  border-radius: 12px;
  text-align: center;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
  z-index: 100;
  animation: fadeInScale 0.3s ease-out;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80%;
  max-width: 400px;
}

.success-message .success-icon {
  font-size: 3.5rem;
  margin-bottom: 20px;
  display: block;
}

@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.9);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

.success-icon {
  font-size: 3rem;
  margin-bottom: 16px;
}

/* .success-text {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary-green);
} */

.success-message .success-text {
  font-size: 1.3rem;
  font-weight: 600;
  margin: 0;
  color: white;
}

/* Agent Card Styles */
.agent-card {
  background: white;
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  border: 1px solid #e5e7eb;
  transition: all 0.3s ease;
  position: relative;
}

.agent-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px -3px rgba(0, 0, 0, 0.1);
}

.agent-header {
  display: flex;
  justify-content: space-between;
  text-align: center;
  align-items: flex-start;
  margin-bottom: 25px;
  flex-wrap: wrap;
}

.agent-info h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: #1f2937;
  margin: 0px;
}

.agent-role {
  font-size: 0.9rem;
  color: var(--primary-green);
  font-weight: 600;
}

.agent-goal {
  font-size: 0.9rem;
  color: #6b7280;
  line-height: 1.5;
  margin-bottom: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3; /* Limits to 3 lines */
  -webkit-box-orient: vertical;
  white-space: normal;
  word-break: break-word;
  overflow: hidden;
  text-overflow: ellipsis;
}

.agent-backstory {
  font-size: 0.85rem;
  color: #9ca3af;
  line-height: 1.4;
  margin-bottom: 16px;
  font-style: italic;
}

.agent-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  color: #6b7280;
  margin-bottom: 16px;
}

.agent-actions {
  display: flex;
  gap: 8px;
}

.delete-btn {
  background-color: #ef4444;
  color: white;
  border: none;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s;
}

.delete-btn:hover {
  background: #dc2626;
}

.agents-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

/* styles.css */

.rag-document-card {
  display: flex;
  align-items: center;
  padding: 12px 15px;
  border-bottom: 1px solid #e5e7eb;
  transition: background-color 0.2s;
}

.rag-document-card:last-child {
  border-bottom: none;
}

.rag-document-card:hover {
  background-color: #f9fafb;
}

.rag-doc-icon {
  background-color: #eef2ff;
  color: #4f46e5;
  padding: 8px 8px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.8rem;
  margin-right: 15px;
  text-transform: uppercase;
}

.rag-doc-info {
  flex: 1;
  overflow: hidden;
}

.rag-doc-name {
  font-weight: 600;
  color: #1f2937;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rag-doc-meta {
  font-size: 0.8rem;
  color: #6b7280;
}

.rag-doc-delete {
  background: #fee2e2;
  color: #ef4444;
  border: none;
  border-radius: 50%;
  width: 28px;
  height: 28px;
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s, color 0.2s;
}

.rag-doc-delete:hover {
  background-color: #ef4444;
  color: white;
}

/* styles.css */

.rag-collection-group {
  border-bottom: 2px solid #d1d5db;
  margin-bottom: 10px;
}
.rag-collection-group:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.rag-collection-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 15px;
  background-color: #f3f4f6;
}

.rag-collection-name {
  font-weight: 700;
  font-size: 1rem;
  color: #15803d;
}

.rag-collection-delete-btn {
  background-color: #ef4444;
  color: white;
  border: none;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s;
}
.rag-collection-delete-btn:hover {
  background-color: #dc2626;
}

/* Minor tweak to document card */
.rag-document-card {
  border-bottom: 1px solid #e5e7eb;
  background-color: #ffffff;
}
.rag-collection-group .rag-document-card:last-child {
  border-bottom: none;
}

/* styles.css */

.voice-clone-card {
  display: flex;
  align-items: center;
  padding: 12px 15px;
  border-bottom: 1px solid #e5e7eb;
  transition: background-color 0.2s;
}
.voice-clone-card:last-child {
  border-bottom: none;
}
.voice-clone-card:hover {
  background-color: #f0eefc;
}

.voice-clone-icon {
  font-size: 1.5rem;
  margin-right: 15px;
}

.voice-clone-info {
  flex: 1;
  overflow: hidden; /* Prevents long names from breaking layout */
}

.voice-clone-name {
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.voice-clone-id {
  font-size: 0.8rem;
  color: #6b7280;
  font-family: monospace;
}

.voice-clone-delete-btn {
  background-color: #ef4444;
  color: white;
  border: none;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s;
}
.voice-clone-delete-btn:hover {
  background-color: #dc2626;
}

#agentRagCollection {
  padding: 8px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  max-height: 200px;
  overflow-y: auto;
  background: white;
  margin-top: 8px;
  font-size: 0.9rem;
  color: #374151;
  width: 100%;
}

#agentVoiceClone {
  padding: 8px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  max-height: 200px;
  overflow-y: auto;
  background: white;
  margin-top: 8px;
  font-size: 0.9rem;
  color: #374151;
  width: 100%;
}
#editAgentRagCollection {
  padding: 8px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  max-height: 200px;
  overflow-y: auto;
  background: white;
  margin-top: 8px;
  font-size: 0.9rem;
  color: #374151;
  width: 100%;
}

#editAgentVoiceClone {
  padding: 8px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  max-height: 200px;
  overflow-y: auto;
  background: white;
  margin-top: 8px;
  font-size: 0.9rem;
  color: #374151;
  width: 100%;
}

/* CSV Contacts with Agent Assignment */
.csv-preview-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 15px;
  border-bottom: 1px solid #e5e7eb;
  margin-bottom: 15px;
}

.csv-preview-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: #1f2937;
}

.csv-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 15px;
  margin: 20px 0;
}

.csv-stat {
  background: rgba(16, 185, 129, 0.05);
  padding: 15px;
  border-radius: 8px;
  text-align: center;
}

.csv-stat-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-green);
  margin-bottom: 5px;
}

.csv-stat-label {
  font-size: 0.85rem;
  color: #6b7280;
}

.doctor-list-container {
  max-height: 500px;
  overflow-y: auto;
  padding-right: 10px;
}

.csv-contact-item {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 15px;
  margin-bottom: 10px;
  transition: all 0.2s;
}

.csv-contact-item:hover {
  border-color: var(--primary-green);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.csv-contact-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.csv-contact-name {
  font-weight: 600;
  color: #1f2937;
}

.csv-contact-meta {
  font-size: 0.85rem;
  color: #6b7280;
  margin-bottom: 10px;
}

.csv-contact-actions {
  display: flex;
  gap: 8px;
}

/* Agent Assignment Modal */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  animation: fadeIn 0.2s ease-out;
}

.modal-container {
  background: white;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  max-width: 600px;
  width: 90%;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  animation: slideUp 0.3s ease-out;
}

.modal-header {
  padding: 20px;
  border-bottom: 1px solid #e5e7eb;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-title {
  font-size: 1.3rem;
  font-weight: 600;
  color: #1f2937;
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  color: #6b7280;
  cursor: pointer;
  padding: 0;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: all 0.2s;
}

.modal-close:hover {
  background: #f3f4f6;
  color: #1f2937;
}

/* .modal-content {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
} */

.modal-footer {
  padding: 20px;
  border-top: 1px solid #e5e7eb;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

/* Form Controls */
.form-control {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  font-size: 0.9rem;
  transition: all 0.2s;
}

.form-control:focus {
  border-color: var(--primary-green);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
  outline: none;
}

.contact-agent-select {
  padding: 5px 10px;
  border: 1px solid #d1d5db;
  border-radius: 4px;
  font-size: 0.85rem;
}

/* Status Indicators */
.status-indicator {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  margin-right: 5px;
  background: currentColor;
  animation: pulse 2s infinite;
}

.status-scheduled {
  color: #f59e0b;
}

.status-active {
  color: #10b981;
}

.status-completed {
  color: #3b82f6;
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

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

/* for Call status */
@keyframes pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

/* Scrollbar Styling */
.doctor-list-container::-webkit-scrollbar {
  width: 6px;
}

.doctor-list-container::-webkit-scrollbar-track {
  background: #f3f4f6;
  border-radius: 3px;
}

.doctor-list-container::-webkit-scrollbar-thumb {
  background: #9ca3af;
  border-radius: 3px;
}

.doctor-list-container::-webkit-scrollbar-thumb:hover {
  background: #6b7280;
}

.contact-list-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #f9fafb;
  padding: 12px 15px;
  border-radius: 8px;
  margin-bottom: 8px;
  border: 1px solid #e5e7eb;
}
.list-name {
  font-weight: 600;
  color: #1f2937;
}
.list-meta {
  font-size: 0.8rem;
  color: #6b7280;
}

.direction-badge {
  text-transform: uppercase;
}
.direction-outbound {
  color: #2e6df5;
}
.direction-inbound {
  color: #dc2626;
}
.direction-both {
  color: #6d28e6;
}

#agentCallDirection {
  padding: 8px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  max-height: 200px;
  overflow-y: auto;
  background: white;
  margin-top: 8px;
  font-size: 0.9rem;
  color: #374151;
  width: 100%;
}

#editAgentCallDirection {
  padding: 8px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  max-height: 200px;
  overflow-y: auto;
  background: white;
  margin-top: 8px;
  font-size: 0.9rem;
  color: #374151;
  width: 100%;
}

/* styles.css */
.voice-filters {
  padding: 0 25px 15px 25px;
  border-bottom: 1px solid #e5e7eb;
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.filter-group {
  display: flex;
  align-items: center;
  gap: 8px;
}
.filter-label {
  font-weight: 600;
  font-size: 0.9rem;
  color: #374151;
  margin-right: 8px;
}
.filter-btn {
  background-color: #f3f4f6;
  border: 1px solid #e5e7eb;
  color: #4b5563;
  padding: 5px 12px;
  font-size: 0.8rem;
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
}
.filter-btn:hover {
  background-color: #e5e7eb;
}
.filter-btn.active {
  background-color: #10b981;
  color: white;
  border-color: #10b981;
}

/* Add this to your existing CSS or in a <style> tag in the <head> */
.btn-danger {
  background-color: #ef4444;
  color: white;
}
.btn-danger:hover {
  background-color: #dc2626;
}
#recordBtn.is-recording {
  background-color: #dc2626;
  animation: pulse 1.5s infinite;
}

/* @keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(239, 68, 68, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
  }
} */

#audioVisualizer {
  border-radius: 8px;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1),
    0 2px 4px -1px rgba(0, 0, 0, 0.06);
  background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

/* Add this to the end of your styles.css file */

.popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(17, 24, 39, 0.6);
  backdrop-filter: blur(5px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 20000;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.popup-overlay.show {
  opacity: 1;
}

.popup-container {
  background: white;
  border-radius: 12px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  width: 90%;
  max-width: 450px;
  transform: scale(0.95);
  transition: transform 0.3s ease;
}

.popup-overlay.show .popup-container {
  transform: scale(1);
}

.popup-header {
  display: flex;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid #e5e7eb;
  position: relative;
}

.popup-icon {
  font-size: 1.5rem;
  margin-right: 12px;
}

.popup-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: #1f2937;
}

.popup-close-btn {
  position: absolute;
  top: 10px;
  right: 12px;
  background: none;
  border: none;
  font-size: 1.8rem;
  color: #9ca3af;
  cursor: pointer;
  line-height: 1;
}
.popup-close-btn:hover {
  color: #1f2937;
}

.popup-body {
  padding: 24px 20px;
  font-size: 0.95rem;
  color: #4b5563;
  line-height: 1.6;
}

.popup-footer {
  padding: 16px 20px;
  background-color: #f9fafb;
  display: flex;
  justify-content: flex-end;
  border-bottom-left-radius: 12px;
  border-bottom-right-radius: 12px;
}

/* --- Type-Specific Styling --- */

/* Success Popup */
.popup-container.popup--success .popup-header {
  background-color: #f0fdf4; /* Light green background */
}
.popup-container.popup--success .popup-icon::before {
  content: "✅";
}
.popup-container.popup--success .popup-footer .btn {
  background-color: var(--primary-green);
  color: white;
}

/* Error Popup */
.popup-container.popup--error .popup-header {
  background-color: #fef2f2; /* Light red background */
}
.popup-container.popup--error .popup-icon::before {
  content: "❌";
}
.popup-container.popup--error .popup-footer .btn {
  background-color: var(--danger-red);
  color: white;
}

/* Info/Default Popup */
.popup-container.popup--info .popup-header {
  background-color: #eff6ff; /* Light blue background */
}
.popup-container.popup--info .popup-icon::before {
  content: "ℹ️";
}
.popup-container.popup--info .popup-footer .btn {
  background-color: var(--accent-blue);
  color: white;
}

/* Grid layout for the search form */
.number-search-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px 25px;
  align-items: flex-start;
}

/* Hint text below form inputs */
.form-hint {
  font-size: 0.8rem;
  color: #6b7280;
  margin-top: 6px;
}

/* Styling for checkbox groups */
.checkbox-group {
  display: flex;
  align-items: center;
  gap: 20px;
  height: 40px; /* Aligns with input fields */
}

.checkbox-group label {
  font-size: 0.9rem;
  color: #374151;
}

/* Aligns the search button with the form grid */
.form-action-group {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.form-action-group .btn {
  width: 100%;
  max-width: 200px; /* Or 'width: 100%;' if you prefer */
}

/* Responsive table for search results */
.results-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.results-table th,
.results-table td {
  padding: 15px;
  text-align: left;
  border-bottom: 1px solid #e5e7eb;
}

.results-table th {
  background-color: #f9fafb;
  font-weight: 600;
  color: #374151;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

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

.results-table tr:hover {
  background-color: #f9fafb;
}

.results-table td strong {
  color: #1f2937;
  font-weight: 600;
}

.capabilities-icons {
  font-size: 1.2rem;
  display: flex;
  gap: 10px;
}

.cap-icon {
  cursor: default;
}

/* Responsive adjustments for the form and table */
@media (max-width: 768px) {
  .number-search-form {
    grid-template-columns: 1fr;
    gap: 15px;
  }

  .form-action-group .btn {
    max-width: 100%;
  }

  /* Force table to not be a table */
  .results-table,
  .results-table thead,
  .results-table tbody,
  .results-table th,
  .results-table td,
  .results-table tr {
    display: block;
  }

  /* Hide table headers */
  .results-table thead tr {
    position: absolute;
    top: -9999px;
    left: -9999px;
  }

  .results-table tr {
    border: 1px solid #e5e7eb;
    margin-bottom: 15px;
    border-radius: 8px;
    overflow: hidden;
  }

  .results-table td {
    border: none;
    border-bottom: 1px solid #f3f4f6;
    position: relative;
    padding-left: 50%;
    text-align: right;
  }

  .results-table td:before {
    /* Use the data-label for the header */
    content: attr(data-label);
    position: absolute;
    left: 15px;
    width: 45%;
    padding-right: 10px;
    white-space: nowrap;
    text-align: left;
    font-weight: 600;
    color: #374151;
  }

  .results-table td:last-child {
    border-bottom: 0;
  }
}

.checkbox-group input[type="checkbox"] {
  margin-right: 5px;
  /* The transform: scale(1.1); was removed */
  width: 16px; /* Explicitly set size */
  height: 16px; /* Explicitly set size */
}

.agent-prompt-preview {
  display: -webkit-box;
  -webkit-line-clamp: 4;
  line-clamp: 4; /* Limits to 4 lines */
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 4px;
  white-space: normal; /* Ensures text wraps correctly before clamping */
  word-break: break-word; /* Prevent long words from overflowing */
  color: #4b5563; /* Match your design */
  font-size: 0.85rem;
  line-height: 1.4;
}

.divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 20px 0;
  color: #6b7280;
  font-size: 0.85rem;
}
.divider::before,
.divider::after {
  content: "";
  flex: 1;
  border-bottom: 1px solid #d1d5db;
}
.divider::before {
  margin-right: 0.5em;
}
.divider::after {
  margin-left: 0.5em;
}

/* Center the Google button */
.google-btn-container {
  display: flex;
  justify-content: center;
  margin-bottom: 20px;
}

.top-bar-status {
  display: flex;
  align-items: center;
  gap: 15px;
  font-size: 0.9rem;
}
.status-value.connected {
  color: #10b981;
  font-weight: 600;
} /* Green */
.status-value.disconnected {
  color: #ef4444;
  font-weight: 600;
} /* Red */
.btn-sm {
  padding: 5px 12px;
  font-size: 0.85rem;
  border-radius: 4px;
  cursor: pointer;
}
/* .btn-outline { border: 1px solid #10b981; background: 10b981; } */
/* .btn-outline:hover { background: #10b981; } */

/* Pulse animation for disconnected button */
@keyframes calendar-pulse {
  0%,
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4);
  }
  50% {
    transform: scale(1.02);
    box-shadow: 0 0 0 6px rgba(239, 68, 68, 0);
  }
}

.btn-animate-disconnected {
  animation: calendar-pulse 1.5s ease-in-out infinite;
  border-color: #ef4444 !important;
  color: #ef4444 !important;
  font-weight: 600;
}

/* Keep hover effect functional */
.btn-animate-disconnected:hover {
  background: #fef2f2 !important;
  border-color: #dc2626 !important;
}

.popup-container.popup--info .popup-header {
  background-color: #eff6ff; /* Light blue background */
}
.popup-container.popup--info .popup-icon::before {
  content: "ℹ️";
}
.popup-container.popup--info .popup-footer .btn {
  background-color: var(--accent-blue);
  color: white;
}

/* AFTER (Add this block) */
/* Info/Default Popup */
.popup-container.popup--info .popup-header {
  background-color: #eff6ff; /* Light blue background */
}
.popup-container.popup--info .popup-icon::before {
  content: "ℹ️";
}
.popup-container.popup--info .popup-footer .btn {
  background-color: var(--accent-blue);
  color: white;
}

/* --- Onboarding Modal Styles --- */
.onboarding-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(5px);
}

.onboarding-card {
  background: white;
  width: 100%;
  max-width: 500px;
  border-radius: 16px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
  overflow: hidden;
  animation: slideUp 0.4s ease-out;
}

.onboarding-image {
  height: 160px;
  background: linear-gradient(
    135deg,
    var(--primary-green) 0%,
    var(--accent-blue) 100%
  );
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  color: white;
}

.onboarding-content {
  padding: 30px;
  text-align: center;
}

.onboarding-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 10px;
}

.onboarding-desc {
  color: #6b7280;
  line-height: 1.6;
  margin-bottom: 25px;
  font-size: 0.95rem;
}

.step-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 25px;
}

.step-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #e5e7eb;
  transition: all 0.3s;
}

.step-dot.active {
  background: var(--primary-green);
  transform: scale(1.2);
}

.onboarding-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.btn-link {
  background: none;
  border: none;
  color: #6b7280;
  cursor: pointer;
  font-size: 0.9rem;
}
.btn-link:hover {
  color: #1f2937;
}

.onboarding-nav {
  display: flex;
  gap: 10px;
}

/* Add this to your styles.css or <style> block */

.help-link {
  color: var(--accent-blue);
  font-size: 0.8rem;
  cursor: pointer;
  margin-left: 8px;
  text-decoration: underline;
  font-weight: 500;
}

.help-link:hover {
  color: #2563eb;
}

/* Prompt Help Modal Specifics */
.prompt-example-box {
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 1px solid #e5e7eb;
}

.prompt-example-box:last-child {
  border-bottom: none;
}

.prompt-category {
  font-weight: 700;
  color: var(--primary-green);
  margin-bottom: 12px;
  font-size: 1rem;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Make the code block look like a clean document */
.prompt-code-block {
  font-family: "Consolas", "Monaco", "Courier New", monospace;
  font-size: 0.95rem;
  color: #1f2937;
  white-space: pre-wrap; /* Preserves line breaks */
  word-wrap: break-word;
  line-height: 1.6;
  background: #f9fafb; /* Very light grey */
  padding: 20px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  border-left: 5px solid #10b981; /* Green accent */
  width: 100%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
  margin-bottom: 15px;
}

.prompt-copy-btn {
  font-size: 0.85rem;
  padding: 8px 16px;
  background: white;
  color: #374151;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.prompt-copy-btn:hover {
  background: #f3f4f6;
  border-color: #9ca3af;
  color: #111827;
}

/* --- NEW: Dashboard Navigation Cards --- */
.dash-nav-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.dash-nav-card {
  background: #fff;
  padding: 24px;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  transition: all 0.3s ease;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  position: relative;
  overflow: hidden;
}

.dash-nav-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.08);
  border-color: #10b981;
}

.dash-nav-icon {
  font-size: 2.5rem;
  background: #f0fdf4;
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  margin-bottom: 8px;
}

.dash-nav-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #111827;
}

.dash-nav-desc {
  font-size: 0.9rem;
  color: #6b7280;
  line-height: 1.5;
}

.dash-nav-arrow {
  position: absolute;
  bottom: 24px;
  right: 24px;
  color: #10b981;
  opacity: 0;
  transform: translateX(-10px);
  transition: all 0.3s ease;
  font-weight: bold;
  font-size: 1.2rem;
}

.dash-nav-card:hover .dash-nav-arrow {
  opacity: 1;
  transform: translateX(0);
}

/* Add this to styles.css */
.dash-step-badge {
  position: absolute;
  top: 20px;
  right: 20px;
  background: #f3f4f6; /* Light gray default */
  color: #6b7280;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
}

/* Highlight the badge when card is hovered */
.dash-nav-card:hover .dash-step-badge {
  background: #d1fae5; /* Light green */
  color: #065f46; /* Dark green text */
}

#bulkCampaignControls[data-status="running"] {
  border-color: #10b981 !important;
  background: #f0fdf4 !important;
}

#bulkCampaignControls[data-status="stopped"] {
  border-color: #ef4444 !important;
  background: #fef2f2 !important;
}

#bulkCampaignControls[data-status="completed"] {
  border-color: #3b82f6 !important;
  background: #eff6ff !important;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 500;
  margin-top: 6px;
}

.status-success {
  background: rgba(16, 185, 129, 0.1);
  color: #059669;
}

.status-stopped {
  background: rgba(245, 158, 11, 0.1);
  color: #d97706;
}

.status-failed {
  background: rgba(239, 68, 68, 0.1);
  color: #dc2626;
}

.status-neutral {
  background: rgba(156, 163, 175, 0.1);
  color: #6b7280;
  font-style: italic;
}

.status-warning {
    background: #fff7ed !important;
    color: #c2410c !important;
    border: 2px solid #fdba74 !important;
    animation: pulse 2s infinite;
}

.time-window-alert {
    animation: pulse 2s infinite;
}

/* .radio-card{
  border: 1px solid #d1d5db;
  border-radius: 8px;
  padding: 5px;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 8px;
} */

.radio-card {
    flex: 1;
    cursor: pointer;
    position: relative;
}

.radio-card input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.radio-card-content {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 15px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    transition: all 0.2s;
    justify-content: center;
}

.radio-card input:checked + .radio-card-content {
    border-color: #10b981;
    background-color: #f0fdf4;
    color: #065f46;
    box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.1);
}

.radio-label {
    font-weight: 500;
    font-size: 0.9rem;
}

.toggle-container {
  display: flex;
  align-items: center;
  gap: 10px;
}

.input-error {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1) !important;
}

/* Success state for inputs */
.input-success {
    border-color: #10b981 !important;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1) !important;
}

/* Disabled state styling */
input[readonly] {
    background-color: #f9fafb !important;
    cursor: not-allowed;
}

/* Integrations Screen Styles */

.integrations-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
  padding-bottom: 40px;
}

.integration-card {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
  position: relative;
  height: 100%;
}

.integration-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.06);
  border-color: #d1d5db;
}

.integration-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 16px;
  height: 48px;
}

.integration-icon {
  width: 55px;
  height: 55px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.integration-status.connected {
  color: var(--primary-green);
  font-size: 0.8rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
}

.integration-status.connected::before {
  content: "●";
  font-size: 0.6rem;
}

.integration-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #111827;
  margin-bottom: 8px;
}

.integration-desc {
  font-size: 0.9rem;
  color: #6b7280;
  line-height: 1.5;
  margin-bottom: 20px;
  flex-grow: 1; /* Pushes the button to bottom */
}

/* Responsive adjustments */
@media (max-width: 600px) {
  .integrations-grid {
    grid-template-columns: 1fr;
  }
}

.integration-badge {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    background: #fee2e2;
    color: #991b1b;
}

@keyframes wiggle-scale {
  0%, 100% { transform: rotate(0deg) scale(1); }
  10%, 30%, 50%, 70%, 90% { transform: rotate(-4deg) scale(1.1); }
  20%, 40%, 60%, 80% { transform: rotate(4deg) scale(1.1); }
}

.wiggle-on-hover:hover {
  animation: wiggle-scale 0.8s ease-in-out;
}
