/* ============================================================
   Academic Planner AI — Account & Security (Sprint 14.1)
   Estilos para la tarjeta "Cuenta y Seguridad" en profile.html
   Usa las variables CSS de styles.css, sin romper estilos existentes.
   ============================================================ */

/* ── Sección ── */
.acs-section-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--color-primary);
  margin: 0 0 14px;
  letter-spacing: -0.01em;
}

.acs-section-text {
  font-size: 0.88rem;
  line-height: 1.65;
  color: var(--color-text-muted);
  margin-bottom: 10px;
}

.acs-divider {
  border: none;
  border-top: 1px solid var(--color-border);
  margin: 28px 0;
}

/* ── Información de la cuenta ── */
.acs-info-grid {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.acs-info-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--color-border);
  background: var(--color-card);
}

.acs-info-row:last-child {
  border-bottom: none;
}

.acs-info-label {
  font-size: 0.83rem;
  color: var(--color-text-muted);
  font-weight: 500;
  flex-shrink: 0;
}

.acs-info-value {
  font-size: 0.88rem;
  color: var(--color-text);
  font-weight: 600;
  text-align: right;
  word-break: break-all;
}

.acs-info-value--success {
  color: #059669;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.acs-info-value--success::before {
  content: "●";
  font-size: 8px;
  color: #10B981;
}

/* ── Privacidad: lista de datos ── */
.acs-data-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 10px 0 16px;
  padding: 0;
}

.acs-data-list li {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-primary);
  background: var(--color-accent);
  border: 1px solid #BFDBFE;
  border-radius: var(--radius-pill);
  padding: 4px 12px;
}

.acs-privacy-btns {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* ── Cambiar contraseña ── */
.acs-pw-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.acs-pw-strength {
  margin-top: 6px;
}

.acs-pw-strength__track {
  height: 4px;
  background: var(--color-border);
  border-radius: 2px;
  overflow: hidden;
  margin-bottom: 4px;
}

.acs-pw-strength__bar {
  height: 100%;
  width: 0%;
  border-radius: 2px;
  transition: width 0.3s ease, background 0.3s ease;
  background: #EF4444;
}

.acs-pw-strength__label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--color-text-muted);
  transition: color 0.3s;
}

/* ── Restore actions ── */
.acs-restore-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.acs-restore-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-bg);
  transition: border-color 0.15s;
}

.acs-restore-item:hover {
  border-color: #CBD5E1;
}

.acs-restore-item__info {
  flex: 1;
  min-width: 0;
}

.acs-restore-item__title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 2px;
}

.acs-restore-item__desc {
  font-size: 0.78rem;
  color: var(--color-text-muted);
  line-height: 1.5;
}

.acs-restore-btn {
  flex-shrink: 0;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 8px 14px;
  background: transparent;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-pill);
  color: var(--color-text-muted);
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s, background 0.15s;
}

.acs-restore-btn:hover {
  border-color: var(--color-cta);
  color: var(--color-cta);
  background: var(--color-accent);
}

.acs-restore-btn--all {
  border-color: #FCA5A5;
  color: #DC2626;
}

.acs-restore-btn--all:hover {
  border-color: #DC2626;
  color: #fff;
  background: #DC2626;
}

/* ── Danger zone ── */
.acs-danger-zone {
  border: 1.5px solid #FECACA;
  border-radius: var(--radius-md);
  padding: 20px;
  background: #FFF5F5;
}

.acs-danger-zone__title {
  font-size: 0.92rem;
  font-weight: 700;
  color: #DC2626;
  margin-bottom: 10px;
}

.acs-danger-zone__text {
  font-size: 0.85rem;
  color: #7F1D1D;
  line-height: 1.6;
  margin-bottom: 14px;
}

.acs-danger-zone__list {
  list-style: none;
  padding: 0;
  margin: 0 0 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.acs-danger-zone__list li {
  font-size: 0.78rem;
  color: #DC2626;
  background: #FEE2E2;
  border-radius: var(--radius-pill);
  padding: 3px 10px;
}

.acs-danger-btn {
  background: #DC2626;
  color: #fff;
  border: none;
  border-radius: var(--radius-pill);
  font-size: 0.88rem;
  font-weight: 600;
  padding: 10px 20px;
  cursor: pointer;
  transition: background 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.acs-danger-btn:hover {
  background: #B91C1C;
}

/* ── Progress modal ── */
.acs-progress-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 8px;
}

.acs-progress-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
  color: var(--color-text);
  opacity: 0.4;
  transition: opacity 0.3s, color 0.3s;
}

.acs-progress-dot {
  font-size: 1rem;
  flex-shrink: 0;
  width: 18px;
  text-align: center;
  color: var(--color-text-muted);
}

.acs-progress-item.is-done .acs-progress-dot {
  color: #059669;
}

/* ── Confirm input (for text-match modals) ── */
.acs-confirm-input {
  width: 100%;
  padding: 10px 12px;
  border: 1.5px solid var(--color-border);
  border-radius: 8px;
  font-size: 0.9rem;
  font-family: inherit;
  color: var(--color-text);
  background: var(--color-bg);
  box-sizing: border-box;
  margin-top: 6px;
  transition: border-color 0.2s;
}

.acs-confirm-input:focus {
  outline: none;
  border-color: var(--color-cta);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

/* ── Modal footer actions ── */
.acs-modal-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 24px;
  flex-wrap: wrap;
}

/* ── Responsive ── */
@media (max-width: 600px) {
  .acs-restore-item {
    flex-direction: column;
    align-items: flex-start;
  }
  .acs-restore-btn {
    width: 100%;
    text-align: center;
    justify-content: center;
  }
  .acs-privacy-btns {
    flex-direction: column;
  }
  .acs-privacy-btns .btn {
    width: 100%;
    justify-content: center;
  }
}
