/* health-plans-dashboard.css */

.health-plans-dashboard-page {
  padding: 0;
  width: 100%;
  margin: 0;
}

.health-plans-dashboard-page .page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding: 20px 25px 15px 25px;
  border-bottom: 2px solid var(--border);
}

.health-plans-dashboard-page .page-header h2 {
  font-size: 1.8rem;
  color: var(--text);
  margin: 0;
}

.health-plans-dashboard-page .page-header .actions {
  display: flex;
  gap: 10px;
}

.health-plans-dashboard-page .content-body {
  padding: 20px 25px;
}

/* ========================================
   DASHBOARD CARDS (ESTATÍSTICAS)
   ======================================== */

.health-plans-dashboard-page .dashboard-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.health-plans-dashboard-page .stat-card {
  background: var(--surface);
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: all 0.3s ease;
}

.health-plans-dashboard-page .stat-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.health-plans-dashboard-page .stat-card.alert-card {
  border-left: 4px solid var(--danger);
}

.health-plans-dashboard-page .stat-card .card-body {
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 15px;
}

.health-plans-dashboard-page .stat-icon {
  width: 60px;
  height: 60px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
  flex-shrink: 0;
}

.health-plans-dashboard-page .stat-content {
  flex: 1;
}

.health-plans-dashboard-page .stat-content h4 {
  margin: 0 0 8px 0;
  font-size: 0.9rem;
  color: var(--text-light);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.health-plans-dashboard-page .stat-value {
  margin: 0 0 5px 0;
  font-size: 2rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1;
}

.health-plans-dashboard-page .stat-detail {
  font-size: 0.85rem;
  color: var(--text-light);
  display: block;
}

/* ========================================
   CARDS
   ======================================== */

.health-plans-dashboard-page .card {
  background: var(--surface);
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  margin-bottom: 20px;
  overflow: hidden;
}

.health-plans-dashboard-page .card-header {
  padding: 15px 25px;
  background: var(--surface-hover);
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.health-plans-dashboard-page .card-header h3 {
  margin: 0;
  font-size: 1.2rem;
  color: var(--text);
  font-weight: 600;
}

.health-plans-dashboard-page .card-header-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.health-plans-dashboard-page .card-header-actions input {
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 0.9rem;
  background: var(--surface);
  color: var(--text);
  min-width: 250px;
}

.health-plans-dashboard-page .card-header-actions input:focus {
  outline: none;
  border-color: var(--primary);
}

.health-plans-dashboard-page .card-body {
  padding: 20px 25px;
}

/* ========================================
   GRÁFICOS
   ======================================== */

.health-plans-dashboard-page .dashboard-charts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.health-plans-dashboard-page .dashboard-charts .card-body {
  padding: 20px;
  height: 350px;
}

.health-plans-dashboard-page .dashboard-charts canvas {
  max-height: 100%;
}

/* ========================================
   TABS
   ======================================== */

.health-plans-dashboard-page .actions-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
  border-bottom: 2px solid var(--border);
  padding-bottom: 0;
}

.health-plans-dashboard-page .tab-btn {
  padding: 12px 20px;
  border: none;
  background: transparent;
  color: var(--text-light);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  border-bottom: 3px solid transparent;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 8px;
  position: relative;
  margin-bottom: -2px;
}

.health-plans-dashboard-page .tab-btn:hover {
  color: var(--text);
  background: var(--surface-hover);
}

.health-plans-dashboard-page .tab-btn.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.health-plans-dashboard-page .tab-btn .badge {
  padding: 3px 8px;
  border-radius: 10px;
  font-size: 0.75rem;
  font-weight: 700;
  background: var(--danger);
  color: white;
  min-width: 20px;
  text-align: center;
}

.health-plans-dashboard-page .tab-btn.active .badge {
  background: var(--primary);
}

.health-plans-dashboard-page .tab-content {
  display: none;
}

.health-plans-dashboard-page .tab-content.active {
  display: block;
}

/* ========================================
   BUTTONS
   ======================================== */

.health-plans-dashboard-page .btn {
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.health-plans-dashboard-page .btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.health-plans-dashboard-page .btn-primary {
  background: var(--primary);
  color: white;
}

.health-plans-dashboard-page .btn-primary:hover:not(:disabled) {
  background: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 123, 255, 0.3);
}

.health-plans-dashboard-page .btn-secondary {
  background: var(--secondary);
  color: var(--text);
}

.health-plans-dashboard-page .btn-secondary:hover:not(:disabled) {
  background: var(--secondary-dark);
}

.health-plans-dashboard-page .btn-warning {
  background: var(--warning);
  color: white;
}

.health-plans-dashboard-page .btn-warning:hover:not(:disabled) {
  background: var(--warning-dark);
  transform: translateY(-2px);
}

.health-plans-dashboard-page .btn-danger {
  background: var(--danger);
  color: white;
}

.health-plans-dashboard-page .btn-danger:hover:not(:disabled) {
  background: var(--danger-dark);
}

/* ========================================
   TABLE
   ======================================== */

.health-plans-dashboard-page .table-responsive {
  overflow-x: auto;
}

.health-plans-dashboard-page .table {
  width: 100%;
  border-collapse: collapse;
}

.health-plans-dashboard-page .table thead {
  background: var(--surface-hover);
}

.health-plans-dashboard-page .table thead th {
  padding: 12px 15px;
  text-align: left;
  font-weight: 600;
  color: var(--text);
  border-bottom: 2px solid var(--border);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.health-plans-dashboard-page .table tbody td {
  padding: 12px 15px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}

.health-plans-dashboard-page .table tbody tr:hover {
  background: var(--surface-hover);
}

.health-plans-dashboard-page .table tbody tr:last-child td {
  border-bottom: none;
}

.health-plans-dashboard-page .table .actions {
  display: flex;
  gap: 8px;
  justify-content: flex-start;
}

/* ========================================
   ACTION BUTTONS
   ======================================== */

.health-plans-dashboard-page .btn-action {
  padding: 8px 12px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.health-plans-dashboard-page .btn-eye {
  background: var(--info);
  color: white;
}

.health-plans-dashboard-page .btn-eye:hover {
  background: var(--info-dark);
  transform: scale(1.1);
}

.health-plans-dashboard-page .btn-check {
  background: var(--success);
  color: white;
}

.health-plans-dashboard-page .btn-check:hover {
  background: var(--success-dark);
  transform: scale(1.1);
}

.health-plans-dashboard-page .btn-times {
  background: var(--danger);
  color: white;
}

.health-plans-dashboard-page .btn-times:hover {
  background: var(--danger-dark);
  transform: scale(1.1);
}

/* ========================================
   TEXT UTILITIES
   ======================================== */

.health-plans-dashboard-page .text-danger {
  color: var(--danger) !important;
  font-weight: 600;
}

.health-plans-dashboard-page .text-warning {
  color: var(--warning) !important;
  font-weight: 600;
}

.health-plans-dashboard-page .text-success {
  color: var(--success) !important;
  font-weight: 600;
}

/* ========================================
   BADGES
   ======================================== */

.health-plans-dashboard-page .badge {
  padding: 5px 12px;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 600;
  display: inline-block;
}

.health-plans-dashboard-page .badge.green {
  background: var(--success-light);
  color: var(--success-dark);
}

.health-plans-dashboard-page .badge.red {
  background: var(--danger-light);
  color: var(--danger-dark);
}

.health-plans-dashboard-page .badge.yellow {
  background: var(--warning-light);
  color: var(--warning-dark);
}

/* ========================================
   RESPONSIVE
   ======================================== */

@media (max-width: 1200px) {
  .health-plans-dashboard-page .dashboard-cards {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  }

  .health-plans-dashboard-page .dashboard-charts {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .health-plans-dashboard-page .page-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
    padding: 15px;
  }

  .health-plans-dashboard-page .page-header .actions {
    width: 100%;
    flex-direction: column;
  }

  .health-plans-dashboard-page .page-header .actions button {
    width: 100%;
    justify-content: center;
  }

  .health-plans-dashboard-page .content-body {
    padding: 15px;
  }

  .health-plans-dashboard-page .dashboard-cards {
    grid-template-columns: 1fr;
    gap: 15px;
  }

  .health-plans-dashboard-page .stat-card .card-body {
    padding: 15px;
  }

  .health-plans-dashboard-page .stat-icon {
    width: 50px;
    height: 50px;
    font-size: 1.5rem;
  }

  .health-plans-dashboard-page .stat-value {
    font-size: 1.6rem;
  }

  .health-plans-dashboard-page .card-header {
    padding: 12px 15px;
  }

  .health-plans-dashboard-page .card-body {
    padding: 15px;
  }

  .health-plans-dashboard-page .card-header-actions input {
    min-width: 100%;
  }

  .health-plans-dashboard-page .actions-tabs {
    overflow-x: auto;
    flex-wrap: nowrap;
  }

  .health-plans-dashboard-page .tab-btn {
    padding: 10px 15px;
    font-size: 0.85rem;
    white-space: nowrap;
  }

  .health-plans-dashboard-page .table {
    font-size: 0.85rem;
  }

  .health-plans-dashboard-page .table thead th,
  .health-plans-dashboard-page .table tbody td {
    padding: 8px 10px;
  }

  .health-plans-dashboard-page .dashboard-charts .card-body {
    height: 300px;
  }
}

@media (max-width: 480px) {
  .health-plans-dashboard-page .page-header h2 {
    font-size: 1.4rem;
  }

  .health-plans-dashboard-page .btn {
    padding: 8px 15px;
    font-size: 0.85rem;
  }

  .health-plans-dashboard-page .stat-value {
    font-size: 1.4rem;
  }

  .health-plans-dashboard-page .stat-detail {
    font-size: 0.75rem;
  }

  .health-plans-dashboard-page .table {
    font-size: 0.8rem;
  }

  .health-plans-dashboard-page .table .actions {
    flex-direction: column;
    gap: 5px;
  }

  .health-plans-dashboard-page .btn-action {
    width: 100%;
  }

  .health-plans-dashboard-page .dashboard-charts .card-body {
    height: 250px;
    padding: 15px;
  }
}