/* OneID Modern Variant - Glassmorphism, Gradient, Responsive, Dark Mode */
.oneid-variant-modern {
  background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.oneid-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
  margin: 2rem auto;
  box-sizing: border-box;
}
.oneid-container.oneid-variant-modern {
  border-radius: 1.25rem; /* 20px */
  box-shadow: 0 0.5rem 2rem 0 rgba(31,38,135,0.13);
  padding: 2.5rem 2rem;
  max-width: 26.25rem; /* 420px */
  background: rgba(255,255,255,0.18);
}

.oneid-title {
  font-family: 'Inter', 'Segoe UI', Arial, sans-serif;
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  letter-spacing: -1px;
  text-align: center;
}

.oneid-desc {
  font-size: 1.1rem;
  color: #444;
  margin-bottom: 1.5rem;
  text-align: center;
}

.oneid-field-group {
  width: 100%;
  display: flex;
  flex-direction: column;

  gap: 0.5rem;
}

.oneid-label {
  font-size: 1rem;
  font-weight: 500;
  color: #666;
  margin-bottom: 0.3rem;
}

.oneid-button {
  width: 100%;
  min-height: 3rem;
  font-size: 1.08rem;
  font-weight: 600;
  border-radius: 0.75rem;
  margin-top: 1rem;
  margin-bottom: 0.5rem;
  border: none;
  cursor: pointer;
  transition: background 0.2s;
}
.oneid-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
.oneid-button:hover:not(:disabled) {
  background: linear-gradient(90deg, #2575fc 0%, #6a11cb 100%);
  box-shadow: 0 4px 16px rgba(31,38,135,0.13);
}

.oneid-link {
  background: none;
  border: none;
  color: #2575fc;
  font-size: 1rem;
  text-decoration: underline;
  cursor: pointer;
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
  display: inline-block;
}

.oneid-message {
  padding: 1rem;
  border-radius: 0.5rem;
  background: rgba(255,255,255,0.7);
  color: #222;
  font-size: 1rem;
  text-align: center;
  box-shadow: 0 1px 4px rgba(31,38,135,0.07);
}

.oneid-message[aria-live="polite"]:empty {
  min-height: 0;
  padding: 0;
  background: none;
  box-shadow: none;
}

.oneid-timer {
  text-align: center;
  color: #6a11cb;
  font-size: 1rem;
  margin: 0.5rem 0;
}

/* OTP Section */
.oneid-otp-section {
  margin-top: 1.5rem;
}
.oneid-otp-inputs {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

/* ==== Tối ưu intl-tel-input cho Modern ==== */

.iti {
    width: 100% !important;
}

.iti__flag-container {
  border: none !important;
  background: transparent !important;
  border-radius: 12px !important;
  box-shadow: none !important;
  transition: border-color 0.2s;
}
.iti--allow-dropdown .iti__flag-container {
  border: 1.5px solid #b3b3b3 !important;
  background: #fff !important;
}
.iti__flag-container:focus-within,
.iti__flag-container:focus {
  border-color: #6a11cb !important;
  box-shadow: 0 0 0 2px #b388ff44 !important;
}
.iti__selected-flag {
  border: none !important;
  background: transparent !important;
  border-radius: 12px !important;
  box-shadow: none !important;
}
.iti__country-list {
  border-radius: 12px !important;
  box-shadow: 0 4px 16px rgba(31,38,135,0.13) !important;
}

/* ==== Tối ưu padding, gap, responsive cho Modern ==== */

.oneid-button {
  margin-top: 1rem;
  margin-bottom: 0.5rem;
  min-height: 48px;
  font-size: 1.08rem;
}

.oneid-inline-message {
  color: #ef4444;
  font-size: 0.95rem;
  margin-top: 0.25rem;
  margin-bottom: 0.25rem;
  text-align: left;
  padding-left: 0.2rem;
}
.oneid-inline-message.success {
  color: #10b981;
}

/* Dark mode */
@media (prefers-color-scheme: dark) {
  .oneid-variant-modern {
    background: linear-gradient(135deg, #232526 0%, #414345 100%);
  }
  .oneid-container.oneid-variant-modern {
    background: rgba(34,34,40,0.7);
    color: #f3f3f3;
    box-shadow: 0 8px 32px 0 rgba(0,0,0,0.37);
    border: 1px solid rgba(255,255,255,0.08);
  }
  .oneid-input {
    background: rgba(34,34,40,0.8);
    color: #f3f3f3;
    border-color: #444;
  }
  .oneid-message {
    background: rgba(34,34,40,0.8);
    color: #f3f3f3;
  }
  .oneid-link {
    color: #b388ff;
  }
}

@keyframes oneid-fade-in-modern {
  from { opacity: 0; transform: translateY(20px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
} 

/* Loại bỏ hoàn toàn viền đen quanh country selector của intl-tel-input */
.iti__flag-container,
.iti__flag-container:focus,
.iti__flag-container:focus-within,
.iti__selected-flag {
  border: none !important;
  box-shadow: none !important;
  outline: none !important;
} 

/* Tối ưu thông báo hướng dẫn */
#oneid-otp-guide-modern {
  font-size: 1.08rem;
  font-weight: 500;
  color: #333;
  margin-bottom: 0.7rem;
  text-align: left;
  line-height: 1.5;
}

/* Ô nhập OTP */
.oneid-otp-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  max-width: 100%;
  min-height: 3.2rem;
}
.oneid-otp-digit {
  flex: 1 1 2.5rem;
  min-width: 2.2rem;
  max-width: 3rem;
  width: 2.8rem;
  height: 2.8rem;
  font-size: 1.35rem;
  border-radius: 0.5rem;
  border: 1.5px solid #b3b3b3;
  text-align: center;
  transition: border-color 0.2s;
  margin: 0 0.1rem;
  box-sizing: border-box;
}
.oneid-otp-digit:focus {
  border-color: #6a11cb;
  outline: none;
}

/* Button xác thực */
#oneid-verify-otp-modern {
  width: 100%;
  font-size: 1.1rem;
  border-radius: 0.75rem;
  padding: 0.75rem 0;
  margin-top: 1rem;
}

/* Responsive cho mobile */
@media (max-width: 480px) {
  .oneid-otp-digit {
    min-width: 1.7rem;
    width: 2rem;
    height: 2rem;
    font-size: 1rem;
  }
  .oneid-otp-container {
    gap: 0.25rem;
  }
  #oneid-otp-guide-modern {
    font-size: 0.98rem;
  }
} 

#oneid-otp-resend-modern,
#oneid-otp-expiry-modern {
  font-size: 1rem;
  line-height: 1.5;
  text-align: left;
  padding: 0.2rem 0.5rem;
  font-weight: 400;
} 

.oneid-button-tertiary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4em;
  background: #fff;
  color: #6b7280;
  border: 1.5px solid #e5e7eb;
  font-size: 1rem;
  font-weight: 500;
  border-radius: 0.5rem;
  padding: 0.55em 1.2em;
  min-height: 2.2rem;
  cursor: pointer;
  transition: background 0.18s, color 0.18s, border 0.18s;
  box-shadow: none;
}
.oneid-button-tertiary:hover {
  background: #f3f4f6;
  color: #fff;
  border-color: #93c5fd;
}
.oneid-icon-back {
  font-size: 1.1em;
  margin-right: 0.4em;
  display: inline-block;
  vertical-align: middle;
} 