:root {
  --amazon-orange: #ff9900;
  --amazon-blue: #232f3e;
  --amazon-dark-blue: #131a22;
  --amazon-yellow: #febd69;
  --white: #ffffff;
  --light-gray: #f3f3f3;
  --border-gray: #ddd;
  --text-dark: #0f1111;
  --text-light: #565959;
  --success-green: #067d62;
  --error-red: #d13212;
}

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

body {
  font-family: 'Inter', Arial, sans-serif;
  background: linear-gradient(135deg, #f0f4f8 0%, #e8f4f8 100%);
  min-height: 100vh;
  color: var(--text-dark);
  line-height: 1.6;
}

.registration-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.step-card {
  background: var(--white);
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
  padding: 40px;
  width: 100%;
  max-width: 600px;
  position: relative;
  overflow: hidden;
}
.step-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 6px;
  background: linear-gradient(90deg, var(--amazon-orange), var(--amazon-yellow));
}

.header-section { text-align: center; margin-bottom: 30px; }
.logo {
  color: var(--amazon-blue);
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  text-decoration: none;
}
.back-link { font-size: 13px; color: var(--text-light); text-decoration: none; }
.back-link:hover { color: var(--amazon-orange); }

.step-indicator { display: flex; justify-content: center; margin-bottom: 30px; gap: 10px; flex-wrap: wrap; }
.step-dot { width: 12px; height: 12px; border-radius: 50%; background: var(--light-gray); transition: all 0.3s ease; }
.step-dot.active { background: var(--amazon-orange); transform: scale(1.2); }
.step-dot.completed { background: var(--success-green); }

.step-title { font-size: 24px; font-weight: 700; color: var(--amazon-blue); margin-bottom: 8px; text-align: center; }
.step-subtitle { color: var(--text-light); margin-bottom: 30px; text-align: center; font-size: 16px; }

.form-group { margin-bottom: 25px; }
.form-label { display: block; margin-bottom: 8px; font-weight: 600; color: var(--amazon-blue); font-size: 16px; }

.form-input, .form-select {
  width: 100%;
  padding: 16px 20px;
  border: 2px solid var(--border-gray);
  border-radius: 8px;
  font-size: 16px;
  font-family: inherit;
  transition: all 0.3s ease;
  background: var(--white);
}
.form-select { cursor: pointer; }
.form-input:focus, .form-select:focus {
  outline: none;
  border-color: var(--amazon-orange);
  box-shadow: 0 0 0 3px rgba(255, 153, 0, 0.2);
}
.form-input.error, .form-select.error { border-color: var(--error-red); background: rgba(209, 50, 18, 0.05); }
.form-input.success, .form-select.success { border-color: var(--success-green); background: rgba(6, 125, 98, 0.05); }

.error-message, .success-message { font-size: 14px; margin-top: 5px; display: none; align-items: center; gap: 5px; }
.error-message { color: var(--error-red); }
.success-message { color: var(--success-green); }
.error-message.show, .success-message.show { display: flex; }

.char-count { font-size: 12px; color: var(--text-light); text-align: right; margin-top: 4px; }

.btn-container { display: flex; gap: 15px; margin-top: 40px; justify-content: space-between; }

.btn {
  padding: 16px 32px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  border: none;
  position: relative;
  overflow: hidden;
}
.btn::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left 0.5s;
}
.btn:hover::before { left: 100%; }
.btn-primary { background: linear-gradient(135deg, var(--amazon-orange) 0%, #e88900 100%); color: var(--white); flex: 1; }
.btn-primary:hover { background: linear-gradient(135deg, #e88900 0%, #d17800 100%); transform: translateY(-2px); box-shadow: 0 6px 20px rgba(255, 153, 0, 0.4); }
.btn-secondary { background: linear-gradient(135deg, var(--light-gray) 0%, #e8e9ea 100%); color: var(--text-dark); border: 2px solid var(--border-gray); }
.btn-secondary:hover { background: linear-gradient(135deg, #e8e9ea 0%, #d8d9da 100%); transform: translateY(-2px); }
.btn-whatsapp { background: linear-gradient(135deg, #25d366 0%, #20ba5a 100%); color: var(--white); }
.btn:disabled { opacity: 0.6; cursor: not-allowed; transform: none !important; }

.progress-bar { width: 100%; height: 8px; background: var(--light-gray); border-radius: 4px; margin-bottom: 30px; overflow: hidden; }
.progress-fill { height: 100%; background: linear-gradient(90deg, var(--amazon-orange), var(--amazon-yellow)); transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1); border-radius: 4px; }

.form-step { display: none; }
.form-step.active { display: block; }
.step-content { opacity: 0; transform: translateX(30px); animation: slideIn 0.5s ease-out forwards; }
@keyframes slideIn { to { opacity: 1; transform: translateX(0); } }

.form-alert {
  display: none;
  background: linear-gradient(135deg,#f8d7da,#f5c6cb);
  border: 1px solid #f5c6cb;
  color: #721c24;
  padding: 12px 14px;
  border-radius: 8px;
  margin-top: 20px;
  font-size: 14px;
}
.form-alert.show { display: block; }

.terms-box {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 20px; background: var(--light-gray);
  border-radius: 8px; border: 2px solid var(--border-gray);
}
.terms-box input { width: 20px; height: 20px; margin-top: 2px; cursor: pointer; flex-shrink: 0; }
.terms-box label { cursor: pointer; font-size: 14px; line-height: 1.5; color: var(--text-dark); }
.terms-box ul { margin: 10px 0 0 20px; font-size: 13px; color: var(--text-light); }

/* Registro con Google */
.google-reg { margin: 4px 0 14px; text-align: center; }
.google-reg-t { font-size: 14px; color: #37475a; margin: 0 0 10px; font-weight: 600; }
.google-btn { display: flex; justify-content: center; min-height: 44px; }
.google-reg-msg { margin-top: 10px; background: #fff4e5; border: 1px solid #ffd59a; color: #7a4b00; border-radius: 8px; padding: 9px 11px; font-size: 13px; text-align: left; }
.google-reg-msg a { color: #0b57d0; font-weight: 700; }
.or-sep { display: flex; align-items: center; gap: 10px; color: #6b7280; font-size: 12.5px; margin: 16px 0 6px; }
.or-sep::before, .or-sep::after { content: ''; flex: 1; height: 1px; background: #e3e5e8; }
.google-done { display: flex; gap: 10px; align-items: flex-start; background: #eef4ff; border: 1px solid #c9dafc; color: #0c2f66; border-radius: 10px; padding: 11px 13px; font-size: 13.5px; line-height: 1.45; margin: 0 0 14px; text-align: left; }
.google-done i { font-size: 18px; margin-top: 2px; }
.form-input.locked { background: #f3f4f6; color: #374151; }
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.completion-screen { text-align: center; padding: 40px 20px; }
.success-icon { font-size: 80px; color: var(--success-green); margin-bottom: 30px; animation: bounceIn 0.6s ease-out; }
@keyframes bounceIn { 0% { transform: scale(0.3); opacity: 0; } 50% { transform: scale(1.1); opacity: 1; } 100% { transform: scale(1); } }
.completion-title { font-size: 28px; font-weight: 700; color: var(--amazon-blue); margin-bottom: 20px; }
.completion-message { font-size: 16px; color: var(--text-light); margin-bottom: 30px; line-height: 1.6; }
.whatsapp-info { background: linear-gradient(135deg, #25d366 0%, #20ba5a 100%); color: white; padding: 20px; border-radius: 12px; margin: 20px 0; }
.whatsapp-info h3 { margin-bottom: 10px; display: flex; align-items: center; justify-content: center; gap: 10px; }
.whatsapp-info a { color: #fff; }
.community-box { background: linear-gradient(135deg, #e7f3ff 0%, #d1ecf1 100%); padding: 20px; border-radius: 12px; margin: 20px 0; border-left: 4px solid #ff9900; text-align: left; }
.community-box h3 { color: #232f3e; margin-bottom: 15px; display: flex; align-items: center; gap: 10px; }
.community-box p, .community-box ul { color: #565959; }
.community-box ul { margin: 15px 0 0 20px; }
.completion-actions { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 20px; }
.completion-actions .btn { flex: 1; min-width: 200px; }

.loading-spinner {
  display: none;
  width: 20px; height: 20px;
  border: 2px solid transparent;
  border-top: 2px solid var(--white);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}
@keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }

.tooltip { position: relative; display: inline-block; cursor: help; margin-left: 5px; }
.tooltip .tooltiptext {
  visibility: hidden; width: 200px;
  background-color: var(--amazon-dark-blue); color: var(--white);
  text-align: center; border-radius: 6px; padding: 8px;
  position: absolute; z-index: 1; bottom: 125%; left: 50%; margin-left: -100px;
  opacity: 0; transition: opacity 0.3s; font-size: 12px; font-weight: 400;
}
.tooltip:hover .tooltiptext { visibility: visible; opacity: 1; }

@media (max-width: 768px) {
  .registration-container { padding: 10px; }
  .step-card { padding: 30px 20px; margin: 10px 0; }
  .btn-container { flex-direction: column-reverse; }
  .btn { width: 100%; }
  .step-title { font-size: 20px; }
  .logo { font-size: 24px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }

.instant-password { display: block; margin: 14px auto; font-family: ui-monospace, Consolas, monospace; font-size: 26px; font-weight: 700; letter-spacing: .06em; color: var(--amazon-blue); background: #fff3d6; border: 1px dashed #e0b45a; border-radius: 10px; padding: 12px; max-width: 280px; }

/* Celular: sin zoom automático del iPhone al tocar un campo (necesita letra de 16 px o más) */
@media (max-width: 768px) {
  input, select, textarea { font-size: 16px !important; }
}
