/* ============================================
   Auth UI System — Logonvoice
   Login + Register pages
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800;900&display=swap');

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

body {
  font-family: 'Plus Jakarta Sans', 'Inter', sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* ── Shell ─────────────────────────────────── */

.auth-shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  padding: 40px 24px;
  background: linear-gradient(145deg, #e0f2fe 0%, #67e8f9 25%, #0d9488 60%, #0f766e 100%);
}

/* Radial light bloom top-left */
.auth-shell::before {
  content: '';
  position: absolute;
  top: -120px;
  left: -80px;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(186,230,253,0.55) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

/* Radial bloom bottom-right */
.auth-shell::after {
  content: '';
  position: absolute;
  bottom: -100px;
  right: -60px;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(103,232,249,0.30) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

/* ── Two-column wrapper ─────────────────────── */

.auth-shell > .auth-hero,
.auth-shell > .auth-card {
  position: relative;
  z-index: 2;
}

/* ── Hero / Left panel ──────────────────────── */

.auth-hero {
  flex: 1;
  max-width: 500px;
  padding: 16px 8px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 36px;
  color: #fff;
  position: relative;
  z-index: 2;
  margin-right: 24px;
}

.brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start; /* ensure the mark and title share the same left edge */
  gap: 8px;
}

.brand-mark {
  width: 62px;
  height: 62px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.25);
  border: 1.5px solid rgba(255, 255, 255, 0.42);
  box-shadow: 0 10px 32px rgba(0,0,0,0.16), inset 0 1px 0 rgba(255,255,255,0.5);
  font-weight: 800;
  font-size: 19px;
  letter-spacing: -0.5px;
  color: #fff;
  margin-bottom: 0px;
  padding-left: 2px; /* slight nudge to better align text optical left edge with title */
}

.auth-hero h1 {
  font-size: 44px;
  line-height: 1.06;
  margin-top: 4px; /* reduce gap so title sits tightly under the mark */
  font-weight: 900;
  letter-spacing: -0.04em;
  color: #fff;
  text-shadow: 0 2px 20px rgba(0,0,0,0.10);
}

.auth-hero > .brand > p {
  margin-top: 14px;
  max-width: 360px;
  font-weight: 500;
  font-size: 15.5px;
  line-height: 1.65;
  color: rgba(255,255,255,0.85);
}

/* Trust metrics */
.trust-metrics {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.metric {
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 18px;
  padding: 14px 18px;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  min-width: 130px;
  transition: background 0.2s, transform 0.2s;
}

.metric:hover {
  background: rgba(255, 255, 255, 0.26);
  transform: translateY(-2px);
}

.metric-value {
  font-weight: 900;
  font-size: 19px;
  margin-bottom: 3px;
  letter-spacing: -0.02em;
  color: #fff;
}

.metric-label {
  font-size: 11px;
  color: rgba(255,255,255,0.78);
  line-height: 1.3;
  font-weight: 500;
}

/* Float icons — CSS fallback layer */
.float-icons {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.float-icons .icon {
  position: absolute;
  opacity: 0.15;
  font-size: 24px;
  animation: cssFloat 13s ease-in-out infinite;
}

.float-icons .icon:nth-child(1) { left: 5%;  top: 12%; animation-duration: 11s; animation-delay: 0s; }
.float-icons .icon:nth-child(2) { left: 22%; top: 68%; animation-duration: 9s;  animation-delay: -3s; }
.float-icons .icon:nth-child(3) { left: 58%; top: 35%; animation-duration: 10s; animation-delay: -5s; }
.float-icons .icon:nth-child(4) { left: 72%; top: 78%; animation-duration: 13s; animation-delay: -1s; }
.float-icons .icon:nth-child(5) { left: 88%; top: 22%; animation-duration: 8s;  animation-delay: -7s; }

@keyframes cssFloat {
  0%   { transform: translateY(0)     translateX(0)     scale(1)    rotate(0deg);   opacity: 0.10; }
  20%  { transform: translateY(-24px)  translateX(16px)  scale(1.09) rotate(7deg);   opacity: 0.22; }
  45%  { transform: translateY(-9px)   translateX(-14px) scale(0.95) rotate(-6deg);  opacity: 0.14; }
  70%  { transform: translateY(-32px)  translateX(9px)   scale(1.12) rotate(10deg);  opacity: 0.24; }
  100% { transform: translateY(0)     translateX(0)     scale(1)    rotate(0deg);   opacity: 0.10; }
}

/* ── Auth floating card ──────────────────────── */

.auth-card {
  width: 440px;
  max-width: 100%;
  position: relative;
  z-index: 3;
  flex-shrink: 0;
}

.auth-card-inner {
  background: rgba(255, 255, 255, 0.13);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 28px;
  padding: 40px 38px 36px;
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  box-shadow:
    0 36px 88px rgba(4,120,87,0.22),
    0 10px 28px rgba(4,120,87,0.12),
    inset 0 1.5px 0 rgba(255,255,255,0.35);
  color: #fff;
}

/* Card header */
.auth-header {
  margin-bottom: 26px;
}

.auth-header h2 {
  font-size: 26px;
  font-weight: 900;
  color: #fff;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.muted {
  margin-top: 6px;
  color: rgba(255,255,255,0.68);
  font-size: 14px;
  font-weight: 500;
}

/* Alert */
.auth-alert {
  background: #fef2f2;
  border: 1px solid #fecaca;
  padding: 12px 16px;
  border-radius: 14px;
  margin-bottom: 20px;
  font-size: 13px;
  color: #b91c1c;
  line-height: 1.5;
}

/* ── Form ───────────────────────────────────── */

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.auth-form label {
  display: block;
  font-size: 11.5px;
  font-weight: 700;
  color: rgba(255,255,255,0.72);
  letter-spacing: 0.07em;
  text-transform: uppercase;
  margin-top: 18px;
  margin-bottom: 7px;
}

.auth-form label:first-of-type {
  margin-top: 0;
}

/* All text inputs */
.auth-form input[type="text"],
.auth-form input[type="email"],
.auth-form input[type="password"],
.auth-form input[type="tel"],
.password-input {
  width: 100%;
  height: 52px;
  border-radius: 14px;
  border: 1.5px solid rgba(255,255,255,0.22);
  background: rgba(255,255,255,0.12);
  color: #fff;
  font-family: inherit;
  font-size: 14.5px;
  font-weight: 500;
  padding: 0 18px;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
  appearance: none;
  -webkit-appearance: none;
}

.auth-form input::placeholder,
.password-input::placeholder {
  color: rgba(255,255,255,0.40);
  font-weight: 400;
}

.auth-form input:focus,
.password-input:focus {
  border-color: rgba(255,255,255,0.60);
  background: rgba(255,255,255,0.18);
  box-shadow: 0 0 0 4px rgba(255,255,255,0.10);
}

/* Password row */
.password-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
}

.password-input {
  flex: 1;
  min-width: 0;
}

.showpass {
  display: flex;
  align-items: center;
  gap: 7px;
  cursor: pointer;
  white-space: nowrap;
  color: rgba(255,255,255,0.75);
  flex-shrink: 0;
}

.showpass span {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: rgba(255,255,255,0.80);
}

.showpass input[type="checkbox"] {
  width: 15px;
  height: 15px;
  accent-color: #0d9488;
  cursor: pointer;
  flex-shrink: 0;
}
.toggle-pass {
  position: absolute;
  right: 10px;
  height: 34px;
  top: 50%;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: rgba(255,255,255,0.04);
  color: rgba(255,255,255,0.92);
  padding: 6px 10px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 14px;
  gap: 8px;
  transition: background 0.12s, transform 0.08s;
}

.toggle-pass:hover { background: rgba(255,255,255,0.06); transform: translateY(-50%) scale(1.02); }

.toggle-pass:active { transform: translateY(-50%) scale(0.98); }

.toggle-pass svg { width: 18px; height: 18px; display: block; }

/* Terms checkbox row */
.terms {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 10px !important;
  margin-top: 18px !important;
  text-transform: none !important;
  letter-spacing: 0 !important;
  font-size: 13px !important;
  color: rgba(255,255,255,0.82) !important;
  font-weight: 500 !important;
  cursor: pointer;
}

.terms input[type="checkbox"] {
  width: 16px !important;
  height: 16px !important;
  accent-color: #0d9488;
  cursor: pointer;
  flex-shrink: 0;
}

/* Submit button */
.btn-primary {
  width: 100%;
  margin-top: 24px;
  height: 52px;
  border: none;
  border-radius: 14px;
  background: linear-gradient(135deg, #0d9488 0%, #0f766e 100%);
  color: #fff;
  font-family: inherit;
  font-weight: 800;
  font-size: 15.5px;
  letter-spacing: 0.01em;
  cursor: pointer;
  box-shadow: 0 10px 28px rgba(13,148,136,0.38), inset 0 1px 0 rgba(255,255,255,0.22);
  transition: transform 0.14s ease, box-shadow 0.14s ease, background 0.14s ease;
  position: relative;
  overflow: hidden;
}

.btn-primary::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.10) 0%, transparent 55%);
  pointer-events: none;
}

.btn-primary:hover {
  background: linear-gradient(135deg, #0d9488 0%, #0f766e 100%);
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(13,148,136,0.50);
}

.btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 6px 16px rgba(13,148,136,0.30);
}

/* Links */
.auth-links {
  margin-top: 20px;
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
  font-size: 13px;
}

.auth-links a {
  color: #ffffff;
  font-weight: 700;
  text-decoration: none;
  transition: color 0.14s;
}

.auth-links a:hover {
  color: #134e4a;
  text-decoration: underline;
}

.auth-links .dot {
  color: #cbd5e1;
}

.auth-footer {
  margin-top: 22px;
  text-align: center;
  font-size: 11.5px;
  color: #94a3b8;
  font-weight: 500;
}

/* ── Responsive ─────────────────────────────── */

@media (max-width: 980px) {
  .auth-hero { max-width: 360px; margin-right: 16px; }
}

@media (max-width: 760px) {
  .auth-shell  { padding: 32px 16px; align-items: center; justify-content: center; }
  .auth-hero   { display: none; }
  .auth-card   { width: 100%; max-width: 420px; }
  .auth-card-inner { padding: 32px 24px 28px; border-radius: 24px; }
  .auth-form input[type="text"],
  .auth-form input[type="email"],
  .auth-form input[type="password"],
  .auth-form input[type="tel"],
  .password-input { height: 50px; }
}