:root {
  --primary: #0077ff;
  --primary-dark: #005fe0;
  --primary-soft: #eaf4ff;
  --secondary: #0f172a;
  --text: #111827;
  --muted: #64748b;
  --border: #dbe5f0;
  --white: #ffffff;
  --danger: #dc2626;
  --danger-bg: #fee2e2;
  --success: #15803d;
  --success-bg: #dcfce7;
  --shadow: 0 24px 70px rgba(15, 23, 42, 0.13);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Poppins", sans-serif;
  color: var(--text);
  background:
    radial-gradient(
      circle at top left,
      rgba(0, 119, 255, 0.16),
      transparent 30%
    ),
    radial-gradient(
      circle at bottom right,
      rgba(96, 165, 250, 0.18),
      transparent 32%
    ),
    linear-gradient(135deg, #f5f9ff 0%, #ffffff 100%);
  min-height: 100vh;
}
a {
  color: inherit;
}

button,
input {
  font-family: inherit;
}
.container {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

/* ==============================
   MAIN AUTH LAYOUT
============================== */

.register-section,
.verify-section {
  position: relative;
  min-height: 100vh;
  padding: 54px 0;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.register-inner {
  display: flex;
  justify-content: center;
  align-items: center;
}

.register-card,
.verify-card {
  position: relative;
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  padding: 38px;
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(219, 229, 240, 0.9);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
  z-index: 2;
}

.ecommerce-register-card {
  max-width: 520px;
}

/* ==============================
   BACKGROUND DECORATION
============================== */

.register-bg-circle,
.register-noise-layer {
  position: absolute;
  pointer-events: none;
}

.register-bg-circle {
  border-radius: 999px;
  filter: blur(2px);
  opacity: 0.7;
}

.register-bg-circle-one {
  width: 220px;
  height: 220px;
  background: rgba(0, 119, 255, 0.16);
  top: 8%;
  left: 8%;
}

.register-bg-circle-two {
  width: 280px;
  height: 280px;
  background: rgba(96, 165, 250, 0.18);
  right: 7%;
  bottom: 8%;
}

.register-bg-circle-three {
  width: 120px;
  height: 120px;
  background: rgba(15, 23, 42, 0.08);
  right: 18%;
  top: 16%;
}

.register-noise-layer {
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.35) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.35) 1px, transparent 1px);
  background-size: 42px 42px;
  opacity: 0.22;
}

/* ==============================
   LOGO
============================== */

.register-brand-wrap,
.register-brand-hero {
  text-align: center;
  margin-bottom: 26px;
}

.auth-logo,
.register-logo-text {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-size: 34px;
  font-weight: 900;
  letter-spacing: -1.2px;
  color: var(--secondary);
  line-height: 1;
}

.auth-logo span,
.register-logo-text span {
  color: var(--primary);
  margin-left: 4px;
  position: relative;
}

.regi-logo {
  display: none !important;
}

/* ==============================
   HEADINGS
============================== */

.register-card h1,
.verify-card h1 {
  margin: 0 0 10px;
  text-align: center;
  font-size: 32px;
  line-height: 1.15;
  font-weight: 900;
  letter-spacing: -0.8px;
  color: var(--secondary);
}

.verify-message,
.register-subtitle,
.auth-subtitle {
  max-width: 390px;
  margin: 0 auto 26px;
  text-align: center;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}

/* ==============================
   FORM
============================== */

.user-login-form-input-main,
.register-form {
  width: 100%;
}

.user-input-error-main,
.form-group {
  margin-bottom: 18px;
}

.register-label,
.form-group label {
  display: block;
  margin-bottom: 8px;
  font-size: 14px;
  font-weight: 800;
  color: var(--secondary);
}

.user-login-input,
.form-group input,
.form-group select {
  width: 100%;
  height: 54px;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 0 16px;
  background: #ffffff;
  color: var(--text);
  font-size: 15px;
  font-weight: 600;
  outline: none;
  transition: 0.25s ease;
}

.user-login-input::placeholder,
.form-group input::placeholder {
  color: #94a3b8;
  font-weight: 500;
}

.user-login-input:focus,
.form-group input:focus,
.form-group select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 5px rgba(0, 119, 255, 0.11);
}

/* ==============================
   PASSWORD FIELD
============================== */

.password-field-wrap {
  position: relative;
}

.password-field-wrap .user-login-input {
  padding-right: 76px;
}

.password-toggle {
  position: absolute;
  top: 50%;
  right: 9px;
  transform: translateY(-50%);
  height: 38px;
  padding: 0 13px;
  border: 0;
  border-radius: 12px;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.password-toggle:hover {
  background: var(--primary);
  color: #fff;
}

.password-hint {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.5;
}

/* ==============================
   BUTTONS
============================== */

.user-login-btn,
.auth-btn,
.login-popup-register-btn,
.login-popup-login-btn {
  width: 100%;
  min-height: 54px;
  border: 0;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  font-size: 15px;
  font-weight: 900;
  cursor: pointer;
  transition: 0.25s ease;
  box-shadow: 0 14px 26px rgba(0, 119, 255, 0.28);
}

.user-login-btn:hover,
.auth-btn:hover,
.login-popup-register-btn:hover,
.login-popup-login-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 34px rgba(0, 119, 255, 0.34);
}

.user-login-btn:active,
.auth-btn:active {
  transform: translateY(0);
}

/* ==============================
   LINKS
============================== */

.auth-link-row,
.register-link-row {
  margin-top: 20px;
  text-align: center;
  color: var(--muted);
  font-size: 14px;
}

.auth-link-row a,
.register-link-row a,
.forgot-link,
.verify-message a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 900;
}

.auth-link-row a:hover,
.register-link-row a:hover,
.forgot-link:hover,
.verify-message a:hover {
  text-decoration: underline;
}

.forgot-link-wrap {
  margin: -6px 0 18px;
  text-align: right;
}

/* ==============================
   INPUT VALIDATION ERRORS
============================== */

.user-input-error-main {
  position: relative;
  margin-bottom: 18px;
}

.user-login-error {
  min-height: 18px;
  margin: 7px 0 0;
  padding-left: 3px;
  color: #dc2626;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
}

.user-login-error:empty {
  display: block;
  min-height: 0;
  margin: 0;
}

.user-input-error-main:has(.user-login-error:not(:empty)) .user-login-input {
  border-color: #ef4444;
  background: #fffafa;
  box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.08);
}
.user-login-input.input-error {
  border-color: #ef4444;
  background: #fffafa;
  box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.08);
}
.user-input-error-main:has(.user-login-error:not(:empty)) .register-label {
  color: #b91c1c;
}

/* fallback error class if JS adds it later */
.user-login-input.input-invalid,
.user-login-input.error {
  border-color: #ef4444;
  background: #fffafa;
  box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.08);
}

/* ==============================
   FORGOT PASSWORD LINK
============================== */

.forgot-password-row {
  display: flex;
  justify-content: flex-end;
  margin: -6px 0 22px;
}

.register-text {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--primary);
  font-size: 14px;
  font-weight: 900;
  text-decoration: none;
  transition: 0.25s ease;
}

.register-text:hover {
  color: var(--primary-dark);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.register-text:active {
  transform: translateY(1px);
}

/* Current inline forgot password div support */
.user-login-form-input-main > div[style*="text-align:right"] {
  margin: -6px 0 22px !important;
}

/* ==============================
   BOTTOM ACCOUNT TEXT
============================== */

.not-account-text {
  margin: 24px 0 0;
  padding: 16px 18px;
  border-radius: 18px;
  background: linear-gradient(135deg, #f8fbff, #eef6ff);
  border: 1px solid #dbeafe;
  color: #64748b;
  text-align: center;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.6;
}

.not-account-text .register-text {
  margin-left: 4px;
  font-size: 14px;
}

/* ==============================
   PASSWORD HINT BETTER STYLE
============================== */

.password-hint {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  margin: 8px 0 0;
  padding: 10px 12px;
  border-radius: 13px;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  color: #64748b;
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.45;
}

.password-hint::before {
  content: "i";
  flex: 0 0 17px;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  background: var(--primary-soft);
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 900;
}

/* ==============================
   FORM MESSAGE IMPROVEMENT
============================== */

.form-message {
  position: relative;
  padding: 14px 16px 14px 44px;
  border-radius: 16px;
  margin-bottom: 20px;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.5;
}

.form-message::before {
  position: absolute;
  left: 16px;
  top: 14px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 900;
}

.form-message.success-message::before {
  content: "✓";
  background: #15803d;
  color: #fff;
}

/* ==============================
   OTP INPUT
============================== */

.otp-input,
input[name="otp"] {
  text-align: center;
  letter-spacing: 10px;
  font-size: 24px;
  font-weight: 900;
}

.resend-otp-wrap {
  margin-top: 18px;
  text-align: center;
}

.resend-otp-wrap a,
.resend-otp-wrap button {
  border: 0;
  background: transparent;
  color: var(--primary);
  font-weight: 900;
  cursor: pointer;
  text-decoration: none;
}

/* ==============================
   MESSAGES
============================== */

.message,
.alert-message,
.error-message,
.success-message {
  padding: 13px 15px;
  margin-bottom: 18px;
  border-radius: 15px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.5;
}

.error-message,
.alert-error,
.message.error {
  background: var(--danger-bg);
  color: var(--danger);
}

.success-message,
.alert-success,
.message.success {
  background: var(--success-bg);
  color: var(--success);
}

.input-error,
.error-text {
  display: block;
  margin-top: 7px;
  color: var(--danger);
  font-size: 13px;
  font-weight: 700;
}

/* ==============================
   POPUP
============================== */

.login-popup-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: rgba(15, 23, 42, 0.54);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  backdrop-filter: blur(8px);
}

.login-popup-content {
  width: 100%;
  max-width: 430px;
  padding: 32px;
  border-radius: 26px;
  background: #fff;
  text-align: center;
  box-shadow: 0 30px 80px rgba(15, 23, 42, 0.28);
  animation: popupScale 0.25s ease;
}

.verify-login-popup-content {
  max-width: 450px;
}

@keyframes popupScale {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.verify-mail-icon {
  width: 62px;
  height: 62px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background: var(--primary-soft);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
}

.verify-mail-icon.error-icon {
  background: var(--danger-bg);
  color: var(--danger);
}

.verify-popup-title {
  margin: 0 0 10px;
  font-size: 24px;
  font-weight: 900;
  color: var(--secondary);
}

.regi-alert-text,
.popup-error-text {
  margin: 0 0 22px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}

.login-popup-btn-main {
  display: flex;
  gap: 12px;
}

/* ==============================
   LOGIN PAGE TWO COLUMN OPTIONAL
============================== */

.auth-section {
  min-height: 100vh;
  padding: 60px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.auth-wrapper {
  width: 100%;
  max-width: 1080px;
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  background: #fff;
  border-radius: 30px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.auth-left {
  padding: 60px;
  background:
    linear-gradient(135deg, rgba(0, 119, 255, 0.96), rgba(15, 23, 42, 0.96)),
    url("../images/cover-1.jpeg") center/cover;
  color: #fff;
}

.auth-left h1 {
  margin: 0 0 18px;
  font-size: 44px;
  line-height: 1.1;
  font-weight: 900;
}

.auth-left p {
  margin: 0;
  font-size: 16px;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.86);
}

.auth-right {
  padding: 44px;
}

.auth-tabs {
  display: flex;
  gap: 12px;
  margin-bottom: 26px;
}

.tab-btn {
  flex: 1;
  min-height: 48px;
  border: 0;
  border-radius: 14px;
  background: var(--primary-soft);
  color: var(--primary);
  font-weight: 900;
  cursor: pointer;
}

.tab-btn.active {
  background: var(--primary);
  color: #fff;
}

.auth-form {
  display: none;
}

.auth-form.active {
  display: block;
}

.register-mini-subtitle {
  max-width: 400px;
  margin: 0 auto 30px;
  text-align: center;
  color: #64748b;
  font-size: 15px;
  line-height: 1.8;
  font-weight: 500;
  letter-spacing: 0.1px;
}

/* small highlight effect */
.register-mini-subtitle strong {
  color: var(--secondary);
  font-weight: 800;
}

/* login/register spacing improvement */
.premium-form-wrap {
  width: 100%;
}

/* better heading spacing */
.user-login-heading {
  margin: 0 0 12px;
  text-align: center;
  font-size: 34px;
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: -1px;
  color: var(--secondary);
}
/* ==============================
   RESPONSIVE
============================== */

@media (max-width: 900px) {
  .auth-wrapper {
    grid-template-columns: 1fr;
  }

  .auth-left {
    padding: 42px 28px;
  }

  .auth-left h1 {
    font-size: 34px;
  }

  .auth-right {
    padding: 34px 22px;
  }
}

@media (max-width: 600px) {
  .register-section,
  .verify-section {
    padding: 28px 0;
    align-items: flex-start;
  }

  .container {
    width: min(100% - 24px, 1180px);
  }

  .register-card,
  .verify-card {
    padding: 28px 20px;
    border-radius: 24px;
  }

  .register-card h1,
  .verify-card h1 {
    font-size: 26px;
  }

  .auth-logo,
  .register-logo-text {
    font-size: 29px;
  }

  .user-login-input,
  .form-group input {
    height: 52px;
    border-radius: 14px;
  }

  .login-popup-content {
    padding: 26px 20px;
    border-radius: 22px;
  }

  .login-popup-btn-main {
    flex-direction: column;
  }

  .not-account-text {
    padding: 14px;
    font-size: 13.5px;
  }

  .register-text {
    font-size: 13.5px;
  }

  .user-login-error {
    font-size: 12.5px;
  }
  .register-mini-subtitle {
    font-size: 14px;
    line-height: 1.7;
    margin-bottom: 24px;
  }

  .user-login-heading {
    font-size: 28px;
  }
}
