/* =====================================================
   CARDS / TARJETAS GENERALES
   Contenedores principales del sistema
===================================================== */

.card {
  background: linear-gradient(180deg, rgba(20, 30, 48, 0.96), rgba(11, 16, 32, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 20px;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.22);
  padding: 22px;
}


/* =====================================================
   TITULOS Y TEXTOS DE SECCION
   Titulares internos del dashboard y módulos
===================================================== */

.page-title-sm {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.section-title {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 800;
  color: var(--text);
}

.section-subtitle {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}


/* =====================================================
   TARJETAS DE ESTADISTICAS
   KPIs del panel: pendientes, usados, monto, etc.
===================================================== */

.stat-card {
  min-height: 122px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 22px;
}

.stat-label {
  color: var(--muted);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 8px;
}

.stat-value {
  font-size: 34px;
  font-weight: 800;
  color: var(--gold-soft);
  line-height: 1;
}


/* =====================================================
   FORMULARIOS
   Estructura de labels, grupos y campos
===================================================== */

.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  margin-bottom: 7px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 14px;
  font-weight: 600;
}


/* =====================================================
   INPUTS / TEXTAREA / SELECT
   Campos generales del sistema
===================================================== */

.input,
.select,
textarea {
  width: 100%;
  min-height: 48px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02));
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text);
  border-radius: 14px;
  padding: 12px 14px;
  outline: none;
  font-family: inherit;
  font-size: 14px;
  transition: all 0.2s ease;
}

.input::placeholder,
textarea::placeholder {
  color: rgba(255, 255, 255, 0.42);
}

.input:focus,
.select:focus,
textarea:focus {
  border-color: rgba(212, 175, 55, 0.45);
  box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.08);
}

.textarea {
  min-height: 96px;
  resize: vertical;
}


/* =====================================================
   SELECT / DROPDOWN
   Ajustes para modo oscuro y compatibilidad visual
===================================================== */

select,
.select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02));
  background-color: rgba(255, 255, 255, 0.04);
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

select option,
.select option {
  background-color: #162033;
  color: #F8FAFC;
}


/* =====================================================
   BOTONES GENERALES
   Base para todos los botones del sistema
===================================================== */

.btn {
  border: none;
  border-radius: 14px;
  padding: 12px 16px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  min-height: 46px;
}

.btn-primary {
  background: linear-gradient(135deg, #f0d77a, #d4af37);
  color: #1a1a1a;
  box-shadow: 0 8px 20px rgba(212, 175, 55, 0.2);
}

.btn-primary:hover {
  transform: translateY(-1px);
  filter: brightness(1.03);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.07);
}

.btn-sm {
  min-height: 38px;
  padding: 8px 12px;
  font-size: 13px;
  border-radius: 12px;
}


/* =====================================================
   FILAS DE ACCIONES
   Grupos de botones dentro de formularios y bloques
===================================================== */

.action-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 12px;
}


/* =====================================================
   MENSAJES / TEXTO AUXILIAR
   Mensajes de estado, ayuda o respuesta del sistema
===================================================== */

.msg-inline {
  margin-top: 12px;
  color: var(--text-soft);
  font-size: 14px;
  min-height: 22px;
}


/* =====================================================
   BADGES / ESTADOS
   Etiquetas visuales para pendiente, usado, error, etc.
===================================================== */

.badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 700;
}

.badge-success {
  background: rgba(34, 197, 94, 0.14);
  color: #86efac;
}

.badge-warning {
  background: rgba(245, 158, 11, 0.14);
  color: #fcd34d;
}

.badge-danger {
  background: rgba(239, 68, 68, 0.14);
  color: #fca5a5;
}


/* =====================================================
   LOGIN
   Elementos específicos de la pantalla de ingreso
===================================================== */

.login-card {
  width: min(420px, 92vw);
  padding: 24px;
}

.login-title {
  margin: 0 0 8px;
  font-size: 28px;
  font-weight: 700;
  color: var(--text);
}

.login-subtitle {
  margin-bottom: 22px;
  color: var(--muted);
  font-size: 14px;
}

.btn-block {
  width: 100%;
}

.msg-box {
  margin-top: 14px;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.85);
  min-height: 20px;
}

.msg-box-error {
  color: #ffb4b4;
}

.msg-box-success {
  color: #86efac;
}