﻿:root {
  --brand: #18a5ff;
  --brand-hover: #0d8de0;
  --brand-ring: rgba(24, 165, 255, 0.18);
  --text: #0f172a;
  --muted: #64748b;
  --bg: #f4f7fb;
  --bg-accent: rgba(24, 165, 255, 0.08);
  --card: #ffffff;
  --border: #e6eaf0;
  --field: #f8fafc;
}

* {
  box-sizing: border-box;
}

.auth-body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: var(--text);
  background: radial-gradient(1200px 600px at 50% -10%, var(--bg-accent), transparent 60%), var(--bg);
}

.auth-shell {
  width: 100%;
  padding: 24px;
  display: flex;
  justify-content: center;
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 12px 32px rgba(15, 23, 42, 0.08);
  padding: 2.5rem 2.25rem;
  animation: authIn 0.35s ease both;
}

@keyframes authIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.auth-logo-wrap {
  text-align: center;
  margin-bottom: 1.75rem;
}

.auth-logo {
  width: auto;
  max-width: 170px;
  height: auto;
}

.auth-head {
  margin-bottom: 1.5rem;
  text-align: center;
}

.auth-card h1,
.auth-card h2 {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 0.35rem;
  color: var(--text);
}

.auth-card p {
  font-size: 0.925rem;
  line-height: 1.5;
  margin: 0 0 0.5rem;
}

.muted {
  color: var(--muted);
}

.input-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.4rem;
}

.form-control {
  width: 100%;
  min-height: 46px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--field);
  padding: 0 14px;
  font-size: 0.95rem;
  color: var(--text);
  transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
}

.form-control::placeholder {
  color: #9aa6b6;
}

.form-control:focus {
  outline: none;
  border-color: var(--brand);
  background: #fff;
  box-shadow: 0 0 0 4px var(--brand-ring);
}

.btn {
  border-radius: 10px;
  font-weight: 600;
}

.btn-primary {
  min-height: 46px;
  border: none;
  background: var(--brand);
  color: #fff;
  font-size: 0.975rem;
  transition: background 0.15s, box-shadow 0.15s;
}

.btn-primary:hover,
.btn-primary:focus {
  background: var(--brand-hover);
  color: #fff;
  box-shadow: 0 0 0 4px var(--brand-ring);
}

.btn-outline-secondary {
  min-height: 46px;
  border-radius: 10px;
}

a,
.link-btn {
  color: var(--brand);
  text-decoration: none;
  font-weight: 600;
}

a:hover,
.link-btn:hover {
  color: var(--brand-hover);
  text-decoration: underline;
}

.form-check-input:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 4px var(--brand-ring);
}

.form-check-input:checked {
  background-color: var(--brand);
  border-color: var(--brand);
}

hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 0.5rem 0;
}

.alert {
  border-radius: 10px;
  font-size: 0.875rem;
}

.pw-field {
  position: relative;
}

.pw-field .form-control {
  padding-right: 44px;
}

.pw-toggle {
  position: absolute;
  top: 0;
  right: 0;
  height: 100%;
  width: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.pw-toggle:hover {
  color: var(--brand);
}

.pw-meter {
  height: 5px;
  border-radius: 999px;
  background: var(--border);
  margin-top: 8px;
  overflow: hidden;
}

.pw-meter > span {
  display: block;
  height: 100%;
  width: 0;
  border-radius: 999px;
  transition: width 0.25s, background 0.25s;
}

.pw-meter > span.pw-weak {
  background: #ef4444;
}

.pw-meter > span.pw-fair {
  background: #f59e0b;
}

.pw-meter > span.pw-good {
  background: #3b82f6;
}

.pw-meter > span.pw-strong {
  background: #22c55e;
}

.pw-hint {
  margin-top: 4px;
  min-height: 1rem;
}

.otp {
  display: flex;
  gap: 8px;
  justify-content: space-between;
}

.otp-box {
  flex: 1 1 0;
  min-width: 0;
  height: 54px;
  text-align: center;
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--field);
  transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
}

.otp-box:focus {
  outline: none;
  border-color: var(--brand);
  background: #fff;
  box-shadow: 0 0 0 4px var(--brand-ring);
}

.auth-legal {
  margin: 2.5rem 0 0;
  padding-top: 0.85rem;
  font-size: 0.6rem;
  line-height: 1.4;
  color: var(--muted);
  opacity: 0.7;
  text-align: center;
}

@media (max-width: 480px) {
  .auth-card {
    padding: 1.75rem 1.35rem;
    border-radius: 14px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .auth-card {
    animation: none;
  }
}
[data-bs-theme=dark] {
  --text: #e8edf4;
  --muted: #94a3b8;
  --bg: #0d1117;
  --bg-accent: rgba(24, 165, 255, 0.10);
  --card: #161b22;
  --border: #283039;
  --field: #1c2128;
}

[data-bs-theme=dark] .form-control::placeholder {
  color: #6b7888;
}

[data-bs-theme=dark] .form-control:focus,
[data-bs-theme=dark] .otp-box:focus {
  background: #1c2128;
}
