body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
  position: relative;
  overflow-y: auto;
  overflow-x: hidden;
}

/* Animated background gradient orbs */
.bg-orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.4;
  animation: float 20s ease-in-out infinite;
  z-index: -1;
}

.bg-orb-1 {
  width: 600px;
  height: 600px;
  background: var(--accent-primary);
  top: -200px;
  left: -200px;
  animation-delay: 0s;
}

.bg-orb-2 {
  width: 500px;
  height: 500px;
  background: var(--whatsapp-green);
  bottom: -150px;
  right: -150px;
  animation-delay: -5s;
}

.bg-orb-3 {
  width: 400px;
  height: 400px;
  background: var(--info);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  animation-delay: -10s;
  opacity: 0.2;
}

@keyframes float {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }

  25% {
    transform: translate(50px, -50px) scale(1.1);
  }

  50% {
    transform: translate(-30px, 30px) scale(0.95);
  }

  75% {
    transform: translate(20px, 40px) scale(1.05);
  }
}

/* Register Container */
.register-container {
  width: 100%;
  max-width: 520px;
  animation: fadeInUp 0.6s ease-out;
  max-height: none;
  overflow-y: visible;
}

/* Register Card */
.register-card {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-2xl);
  padding: var(--space-8);
  box-shadow: var(--shadow-xl);
}

/* Logo */
.register-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-4);
  margin-bottom: var(--space-8);
}

.register-logo-icon {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, var(--whatsapp-green), var(--accent-primary));
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: white;
  box-shadow: 0 8px 24px var(--whatsapp-glow);
  animation: glow 3s ease-in-out infinite;
  overflow: hidden;
}

.register-logo-icon img {
  border-radius: var(--radius-full);
}

/* Header */
.register-header {
  text-align: center;
  margin-bottom: var(--space-8);
}

.register-title {
  font-size: var(--text-2xl);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-2);
}

.register-subtitle {
  font-size: var(--text-md);
  color: var(--text-tertiary);
}

/* Form */
.register-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

/* Form row group for side-by-side fields */
.form-row-group {
  display: flex;
  gap: var(--space-4);
  width: 100%;
}

.form-group-half {
  flex: 1;
  min-width: 0;
}

.form-row-three {
  display: flex;
  gap: var(--space-3);
  width: 100%;
}

.form-group-third {
  min-width: 0;
}

.form-row-three .form-group-third:first-child {
  flex: 0 0 25%;
}

.form-row-three .form-group-third:nth-child(2),
.form-row-three .form-group-third:nth-child(3) {
  flex: 1;
}

.form-label {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--text-secondary);
}

.form-input {
  width: 100%;
  height: 52px;
  padding: 0 var(--space-5);
  font-family: var(--font-sans);
  font-size: var(--text-md);
  color: var(--text-primary);
  background: var(--bg-tertiary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  transition: all var(--transition-fast);
}

.form-input::placeholder {
  color: var(--text-muted);
}

.form-input:hover {
  border-color: var(--border-default);
}

.form-input:focus {
  outline: none;
  border-color: var(--accent-border);
  box-shadow: 0 0 0 4px var(--accent-soft);
  background: var(--bg-surface);
}

.form-input:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Input with icon */
.input-with-icon {
  position: relative;
}

.input-with-icon .form-input {
  padding-left: 52px;
}

.input-with-icon .input-icon {
  position: absolute;
  left: var(--space-5);
  top: 50%;
  transform: translateY(-50%);
  font-size: 20px;
  color: var(--text-muted);
  pointer-events: none;
  transition: color var(--transition-fast);
}

.input-with-icon .form-input:focus~.input-icon {
  color: var(--accent-primary);
}

/* Email and OTP container - stacked vertically */
.email-otp-container {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.email-input-wrapper {
  width: 100%;
}

.email-verify-row {
  display: flex;
  gap: var(--space-3);
  align-items: center;
}

.otp-input-wrapper {
  flex: 1;
}

.otp-buttons-row {
  display: flex;
  gap: var(--space-3);
  align-items: center;
}

.verify-btn,
.edit-btn {
  flex: 1;
  height: 52px;
  padding: 0 var(--space-5);
  font-family: var(--font-sans);
  font-size: var(--text-sm);
  font-weight: 600;
  color: white;
  background: var(--accent-primary);
  border: none;
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.edit-btn {
  background: var(--warning);
}

.verify-btn:hover,
.edit-btn:hover {
  background: var(--accent-primary-light);
  transform: translateY(-1px);
}

.edit-btn:hover {
  background: var(--warning-light, #f59e0b);
}

.verify-btn:disabled,
.edit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.verify-otp-btn {
  flex: 1;
  height: 52px;
  padding: 0 var(--space-4);
  font-family: var(--font-sans);
  font-size: var(--text-sm);
  font-weight: 600;
  color: white;
  background: var(--accent-primary);
  border: none;
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
  flex-shrink: 0;
}

.verify-otp-btn:hover {
  background: var(--accent-primary-light);
}

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

.otp-hint {
  font-size: var(--text-xs);
  color: var(--text-muted);
  margin-top: var(--space-2);
  width: 100%;
}

/* Password toggle */
.password-toggle {
  position: absolute;
  right: var(--space-4);
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: var(--text-muted);
  background: transparent;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.password-toggle:hover {
  color: var(--text-secondary);
  background: var(--bg-hover);
}

/* Terms Section */
.terms-section {
  margin-top: var(--space-6);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-tertiary);
}

.terms-header {
  padding: var(--space-4);
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border-subtle);
}

.terms-header h3 {
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.terms-content {
  max-height: 250px;
  overflow-y: auto;
  padding: var(--space-5);
  scroll-behavior: smooth;
}

.terms-content::-webkit-scrollbar {
  width: 8px;
}

.terms-content::-webkit-scrollbar-track {
  background: var(--bg-surface);
  border-radius: var(--radius-sm);
}

.terms-content::-webkit-scrollbar-thumb {
  background: var(--border-strong);
  border-radius: var(--radius-sm);
}

.terms-content::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

.terms-text h4 {
  font-size: var(--text-md);
  font-weight: 600;
  color: var(--text-primary);
  margin-top: var(--space-5);
  margin-bottom: var(--space-3);
}

.terms-text h4:first-child {
  margin-top: 0;
}

.terms-text p {
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: var(--space-4);
}

.terms-text ul {
  list-style: disc;
  padding-left: var(--space-6);
  margin-bottom: var(--space-4);
}

.terms-text li {
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: var(--space-2);
}

.terms-end-marker {
  margin-top: var(--space-6);
  padding-top: var(--space-6);
  border-top: 2px solid var(--border-default);
}

.terms-end-marker p {
  font-size: var(--text-sm);
  color: var(--accent-primary);
  text-align: center;
}

/* Terms Acceptance Checkbox */
.terms-acceptance {
  margin-top: var(--space-6);
  padding: var(--space-5);
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  animation: fadeInDown 0.3s ease-out;
}

.terms-acceptance .checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  cursor: pointer;
}

.terms-acceptance .checkbox-input {
  width: 20px;
  height: 20px;
  min-width: 20px;
  margin-top: 2px;
  border: 2px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: transparent;
  cursor: pointer;
  appearance: none;
  transition: all var(--transition-fast);
}

.terms-acceptance .checkbox-input:checked {
  background: var(--accent-primary);
  border-color: var(--accent-primary);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'%3E%3C/polyline%3E%3C/svg%3E");
  background-size: 14px;
  background-position: center;
  background-repeat: no-repeat;
}

.terms-acceptance .checkbox-label {
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: 1.5;
  font-weight: 500;
}

/* Submit Button */
.register-btn {
  width: 100%;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  font-family: var(--font-sans);
  font-size: var(--text-md);
  font-weight: 600;
  color: white;
  background: var(--border-subtle);
  border: none;
  border-radius: var(--radius-lg);
  cursor: not-allowed;
  transition: all var(--transition-base);
  margin-top: var(--space-4);
  opacity: 0.5;
}

.register-btn.enabled {
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-primary-dark));
  cursor: pointer;
  box-shadow: 0 4px 16px var(--accent-primary-glow);
  opacity: 1;
}

.register-btn.enabled:hover {
  background: linear-gradient(135deg, var(--accent-primary-light), var(--accent-primary));
  transform: translateY(-2px);
  box-shadow: 0 8px 24px var(--accent-primary-glow);
}

.register-btn.enabled:active {
  transform: translateY(0);
}

.register-btn:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.register-btn i {
  font-size: 18px;
  transition: transform var(--transition-fast);
}

.register-btn.enabled:hover i {
  transform: translateX(4px);
}

/* Error Message */
.error-message {
  display: none;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4);
  background: var(--danger-subtle);
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-radius: var(--radius-lg);
  font-size: var(--text-sm);
  color: var(--danger);
  animation: fadeInDown 0.3s ease-out;
}

.error-message.show {
  display: flex;
}

.error-message i {
  font-size: 18px;
}

/* Success Message */
.success-message {
  display: none;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4);
  background: var(--success-subtle);
  border: 1px solid rgba(34, 197, 94, 0.2);
  border-radius: var(--radius-lg);
  font-size: var(--text-sm);
  color: var(--success);
  animation: fadeInDown 0.3s ease-out;
}

.success-message.show {
  display: flex;
}

.success-message i {
  font-size: 18px;
}

/* Footer */
.register-footer {
  text-align: center;
  margin-top: var(--space-6);
  padding-top: var(--space-6);
  border-top: 1px solid var(--border-subtle);
}

.register-footer-text {
  font-size: var(--text-sm);
  color: var(--text-tertiary);
}

.register-footer-link {
  color: var(--accent-primary);
  text-decoration: none;
  font-weight: 500;
}

.register-footer-link:hover {
  color: var(--accent-primary-light);
}

/* Bottom Links */
.bottom-links {
  display: flex;
  justify-content: center;
  gap: var(--space-6);
  margin-top: var(--space-8);
}

.bottom-link {
  font-size: var(--text-sm);
  color: var(--text-muted);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.bottom-link:hover {
  color: var(--text-secondary);
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes glow {
  0%, 100% {
    box-shadow: 0 8px 24px var(--whatsapp-glow);
  }
  50% {
    box-shadow: 0 8px 32px var(--whatsapp-glow), 0 0 40px var(--whatsapp-glow);
  }
}

/* Responsive */
@media (max-width: 900px) {
  .form-row-three {
    flex-wrap: wrap;
  }

  .form-row-three .form-group-third:first-child {
    flex: 0 0 100%;
  }

  .form-row-three .form-group-third:nth-child(2),
  .form-row-three .form-group-third:nth-child(3) {
    flex: 1;
    min-width: calc(50% - var(--space-2));
  }
}

@media (max-width: 768px) {
  .form-row-group {
    flex-direction: column;
  }

  .form-group-half {
    width: 100%;
  }

  .form-row-three {
    flex-direction: column;
  }

  .form-row-three .form-group-third {
    width: 100%;
  }

  .email-otp-container {
    flex-direction: column;
    align-items: stretch;
  }

  .email-input-wrapper,
  .otp-input-wrapper {
    width: 100%;
  }

  .verify-btn,
  .edit-btn,
  .verify-otp-btn {
    width: 100%;
  }
}

@media (max-width: 640px) {
  body {
    padding: var(--space-4);
  }

  .register-card {
    padding: var(--space-6);
  }

  .register-logo-icon {
    width: 48px;
    height: 48px;
    font-size: 24px;
  }
}
