/* ═══════════════════════════════════════════════════════════
   AMEPORT DGO — Reset Password Styles
   Basado en el diseño del Portal de Asociados AMEPORT
   ═══════════════════════════════════════════════════════════ */

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

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  background: linear-gradient(180deg, #001a3d 0%, #00264d 40%, #003366 100%);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  color: #1e293b;
}

/* ── Container ── */
.reset-container {
  width: 100%;
  max-width: 460px;
  position: relative;
}

/* ── Header ── */
.reset-header {
  text-align: center;
  margin-bottom: 28px;
}

.reset-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100px;
  height: 100px;
  background: #ffffff;
  border-radius: 20px;
  margin-bottom: 18px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
  padding: 10px;
  overflow: hidden;
}

.reset-logo-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.reset-header h1 {
  font-size: 1.6rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.02em;
}

.reset-header h1 span {
  color: #93c5fd;
}

.reset-subtitle {
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.9rem;
  margin-top: 6px;
}

/* ── Stepper ── */
.reset-stepper {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 28px;
}

.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  opacity: 0.4;
  transition: opacity 0.3s ease;
}

.step.active {
  opacity: 1;
}

.step.done {
  opacity: 0.7;
}

.step-circle {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.5);
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.step.active .step-circle {
  background: #2563eb;
  color: #fff;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.45);
  border-color: rgba(255, 255, 255, 0.2);
}

.step.done .step-circle {
  background: #1d4ed8;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.15);
}

.step span {
  font-size: 0.65rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.45);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.step.active span {
  color: #93c5fd;
}

.step.done span {
  color: rgba(255, 255, 255, 0.55);
}

.step-line {
  width: 44px;
  height: 2px;
  background: rgba(255, 255, 255, 0.15);
  margin: 0 10px;
  margin-bottom: 20px;
  border-radius: 1px;
  transition: background 0.3s ease;
}

.step-line.done {
  background: #1d4ed8;
}

/* ── Step Content (Card blanca) ── */
.reset-step {
  background: #ffffff;
  border-radius: 20px;
  padding: 36px 32px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
  animation: fadeIn 0.3s ease;
}

.reset-step.hidden {
  display: none;
}

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

.step-content h2 {
  font-size: 1.25rem;
  font-weight: 700;
  color: #111827;
  margin-bottom: 6px;
}

.step-content p {
  color: #6b7280;
  font-size: 0.875rem;
  line-height: 1.5;
  margin-bottom: 24px;
}

/* ── Input ── */
.input-group {
  margin-bottom: 20px;
}

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

.input-group input {
  width: 100%;
  padding: 14px 16px;
  background: #eef2f7;
  border: 1.5px solid #dce3ed;
  border-radius: 12px;
  color: #111827;
  font-size: 1rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.input-group input::placeholder {
  color: #9ca3af;
}

.input-group input:focus {
  border-color: #2563eb;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* ── Password wrap ── */
.password-wrap {
  position: relative;
}

.password-wrap input {
  padding-right: 44px;
}

.toggle-pass {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #9ca3af;
  cursor: pointer;
  padding: 4px;
  transition: color 0.2s;
}

.toggle-pass:hover {
  color: #374151;
}

/* ── Code digits ── */
.code-inputs {
  display: flex;
  gap: 10px;
  justify-content: center;
}

.code-digit {
  width: 50px !important;
  height: 56px;
  text-align: center;
  font-size: 1.3rem;
  font-weight: 700;
  padding: 0 !important;
  border-radius: 12px;
  background: #eef2f7;
  border: 1.5px solid #dce3ed;
  color: #111827;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.code-digit:focus {
  border-color: #2563eb;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* ── Buttons ── */
.btn-primary {
  width: 100%;
  padding: 14px 24px;
  background: linear-gradient(135deg, #00367C, #002254);
  color: #fff;
  border: 2px solid #00367C;
  border-radius: 12px;
  font-size: 0.95rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s ease;
  box-shadow: 0 4px 16px rgba(0, 54, 124, 0.2);
}

.btn-primary:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(0, 54, 124, 0.35);
  background: linear-gradient(135deg, #004494, #00367C);
}

.btn-primary:active:not(:disabled) {
  transform: translateY(0);
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-loader {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.btn-link {
  background: none;
  border: none;
  color: #2563eb;
  font-size: 0.8rem;
  font-family: inherit;
  cursor: pointer;
  margin-top: 16px;
  display: block;
  width: 100%;
  text-align: center;
  transition: color 0.2s;
}

.btn-link:hover {
  color: #1d4ed8;
  text-decoration: underline;
}

/* ── Success ── */
.success-content {
  text-align: center;
}

.success-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  background: #ecfdf5;
  border-radius: 50%;
  color: #16a34a;
  margin-bottom: 20px;
  animation: scaleIn 0.4s ease;
}

@keyframes scaleIn {
  from { transform: scale(0.5); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.success-user {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 10px;
  padding: 12px 18px;
  display: inline-block;
  font-size: 0.875rem;
  color: #1e40af;
}

.success-user strong {
  color: #1d4ed8;
}

/* ── Toast ── */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: #dc2626;
  color: #fff;
  padding: 12px 24px;
  border-radius: 10px;
  font-size: 0.875rem;
  font-weight: 500;
  box-shadow: 0 8px 24px rgba(220, 38, 38, 0.3);
  transition: transform 0.3s ease;
  z-index: 100;
  max-width: 90%;
  text-align: center;
}

.toast.visible {
  transform: translateX(-50%) translateY(0);
}

.toast.hidden {
  display: block;
  transform: translateX(-50%) translateY(80px);
}

/* ── Responsive ── */
@media (max-width: 480px) {
  body {
    padding: 16px;
    align-items: flex-start;
    padding-top: 40px;
  }

  .reset-step {
    padding: 28px 22px;
    border-radius: 16px;
  }

  .code-digit {
    width: 42px !important;
    height: 48px;
    font-size: 1.1rem;
  }

  .step span {
    font-size: 0.6rem;
  }

  .step-line {
    width: 28px;
  }

  .reset-logo {
    width: 60px;
    height: 60px;
  }
}
