@import url("https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&family=Sora:wght@500;600;700;800&display=swap");

:root {
  --auth-ink: #071525;
  --auth-navy: #0c2340;
  --auth-teal: #0f9f8a;
  --auth-teal-deep: #0b7c6c;
  --auth-coral: #e11d48;
  --auth-mist: #eef3f8;
  --auth-card: #ffffff;
  --auth-text: #102033;
  --auth-muted: #64748b;
}

.auth-pro-body {
  margin: 0;
  min-height: 100vh;
  font-family: "DM Sans", sans-serif !important;
  font-weight: 400 !important;
  background:
    radial-gradient(900px 420px at 85% 10%, rgba(15, 159, 138, 0.12), transparent 55%),
    linear-gradient(160deg, #e8eef5 0%, #f4f7fb 45%, #eef2f7 100%);
  color: var(--auth-text) !important;
  overflow-x: hidden;
}

.auth-pro-body .main-wrapper {
  padding: 0;
}

.auth-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(380px, 48%) 1fr;
}

/* ===== Brand panel ===== */
.auth-brand {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(700px 420px at 10% 0%, rgba(15, 159, 138, 0.35), transparent 55%),
    radial-gradient(600px 380px at 100% 100%, rgba(225, 29, 72, 0.22), transparent 50%),
    linear-gradient(165deg, #061421 0%, #0c2340 48%, #0a1c34 100%);
  color: #fff !important;
  padding: 48px 56px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.auth-brand,
.auth-brand * {
  color: #ffffff !important;
}

.auth-grid-glow {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(circle at 35% 25%, #000 15%, transparent 72%);
  pointer-events: none;
  animation: authGridDrift 28s linear infinite;
}

.auth-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(2px);
  pointer-events: none;
  opacity: 0.55;
}

.auth-orb-a {
  width: 280px;
  height: 280px;
  top: -80px;
  right: -60px;
  background: radial-gradient(circle, rgba(15, 159, 138, 0.55), transparent 70%);
  animation: authFloat 9s ease-in-out infinite;
}

.auth-orb-b {
  width: 220px;
  height: 220px;
  bottom: 8%;
  left: -70px;
  background: radial-gradient(circle, rgba(225, 29, 72, 0.35), transparent 70%);
  animation: authFloat 11s ease-in-out infinite reverse;
}

.auth-orb-c {
  width: 140px;
  height: 140px;
  top: 42%;
  right: 12%;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.28), transparent 70%);
  animation: authFloat 7s ease-in-out infinite 1s;
}

.auth-brand-inner {
  position: relative;
  z-index: 1;
  max-width: 520px;
}

.auth-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(8px);
  margin-bottom: 26px;
}

.auth-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--auth-teal);
  box-shadow: 0 0 0 0 rgba(15, 159, 138, 0.55);
  animation: authPulse 2s ease-out infinite;
}

.auth-brand h1 {
  font-family: "Sora", sans-serif !important;
  font-size: clamp(30px, 3.5vw, 46px);
  line-height: 1.12;
  font-weight: 700 !important;
  letter-spacing: -0.035em;
  margin: 0 0 16px;
}

.auth-brand p.lead {
  margin: 0 0 28px;
  font-size: 15.5px;
  line-height: 1.7;
  color: #c8d6e8 !important;
  max-width: 440px;
}

/* Pipeline viz */
.auth-pipeline {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 28px;
  padding: 18px 16px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
}

.pipe-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  min-height: 110px;
  justify-content: flex-end;
}

.pipe-bar {
  width: 100%;
  max-width: 44px;
  height: var(--h, 50%);
  border-radius: 10px 10px 6px 6px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.35), rgba(255, 255, 255, 0.08));
  transform-origin: bottom;
  animation: authBarRise 1.1s cubic-bezier(0.22, 1, 0.36, 1) both;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.pipe-stage:nth-child(2) .pipe-bar { animation-delay: 0.12s; }
.pipe-stage:nth-child(3) .pipe-bar { animation-delay: 0.24s; }
.pipe-stage:nth-child(4) .pipe-bar { animation-delay: 0.36s; }

.pipe-stage.is-hot .pipe-bar {
  background: linear-gradient(180deg, #2dd4bf, #0f9f8a);
  box-shadow: 0 8px 20px rgba(15, 159, 138, 0.35);
}

.pipe-stage span {
  font-size: 11px;
  font-weight: 600 !important;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #b8c9dc !important;
}

.auth-features {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}

.auth-features li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 14px 16px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  transition: transform 0.25s ease, background 0.25s ease, border-color 0.25s ease;
}

.auth-features li:hover {
  transform: translateX(4px);
  background: rgba(255, 255, 255, 0.11);
  border-color: rgba(15, 159, 138, 0.45);
}

.auth-features i {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, #12b39c, #0b7c6c);
  color: #fff !important;
  font-size: 18px;
  flex-shrink: 0;
  box-shadow: 0 8px 16px rgba(15, 159, 138, 0.28);
}

.auth-features strong {
  display: block;
  font-size: 14.5px;
  font-weight: 700 !important;
  margin-bottom: 2px;
}

.auth-features span {
  font-size: 13px;
  color: #b7c7da !important;
}

.auth-brand-footer {
  position: relative;
  z-index: 1;
}

.auth-mini-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.auth-mini-stats > div {
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.auth-mini-stats b {
  display: block;
  font-family: "Sora", sans-serif;
  font-size: 13px;
  font-weight: 700 !important;
  margin-bottom: 2px;
}

.auth-mini-stats span {
  font-size: 11px;
  color: #9eb0c6 !important;
}

/* ===== Form panel ===== */
.auth-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  position: relative;
}

.auth-card {
  width: 100%;
  max-width: 430px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 24px;
  box-shadow:
    0 24px 60px rgba(7, 21, 37, 0.1),
    0 2px 0 rgba(255, 255, 255, 0.8) inset;
  padding: 36px 36px 28px;
  backdrop-filter: blur(12px);
}

.auth-logo {
  display: flex;
  justify-content: center;
  margin-bottom: 18px;
}

.auth-logo img {
  max-height: 42px;
  width: auto;
}

.auth-badge {
  display: inline-flex;
  margin: 0 auto 14px;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--auth-teal-deep) !important;
  background: rgba(15, 159, 138, 0.12);
  border: 1px solid rgba(15, 159, 138, 0.22);
  width: fit-content;
}

.auth-card .auth-badge {
  display: flex;
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
}

.auth-card h2 {
  font-family: "Sora", sans-serif !important;
  font-size: 26px;
  font-weight: 700 !important;
  letter-spacing: -0.03em;
  margin: 0 0 6px;
  text-align: center;
  color: #0b1a2b !important;
}

.auth-card .sub {
  text-align: center;
  color: var(--auth-muted) !important;
  font-size: 14px;
  margin-bottom: 26px;
}

.auth-card .form-label {
  font-size: 13px;
  font-weight: 600 !important;
  color: #334155 !important;
  margin-bottom: 8px;
}

.auth-field {
  position: relative;
}

.auth-field .form-control {
  height: 52px;
  border-radius: 14px;
  border: 1px solid #d5dee9;
  padding: 12px 44px 12px 14px;
  font-size: 14px;
  background: #f7fafc;
  box-shadow: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.auth-field .form-control:focus {
  background: #fff;
  border-color: var(--auth-teal);
  box-shadow: 0 0 0 4px rgba(15, 159, 138, 0.15);
}

.auth-field .field-icon {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8 !important;
  font-size: 18px;
  cursor: default;
}

.auth-field .toggle-password {
  cursor: pointer;
}

.auth-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 4px 0 22px;
  font-size: 13px;
}

.auth-meta .form-check-input {
  width: 16px;
  height: 16px;
  margin-top: 0;
  border-color: #cbd5e1;
}

.auth-meta .form-check-input:checked {
  background-color: var(--auth-teal);
  border-color: var(--auth-teal);
}

.auth-meta .form-check-label {
  color: #475569 !important;
  font-weight: 500 !important;
  margin-left: 6px;
}

.auth-forgot {
  color: var(--auth-teal, #0d9488);
  font-weight: 600;
  text-decoration: none;
  font-size: 13px;
}

.auth-forgot:hover {
  text-decoration: underline;
}

.auth-submit {
  width: 100%;
  height: 52px;
  border: 0;
  border-radius: 14px;
  background: linear-gradient(135deg, #12b39c 0%, #0b7c6c 55%, #0a6b5d 100%);
  color: #fff !important;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.01em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
  box-shadow: 0 12px 28px rgba(11, 124, 108, 0.32);
}

.auth-submit i {
  font-size: 18px;
  transition: transform 0.2s ease;
}

.auth-submit:hover,
.auth-submit:focus {
  color: #fff !important;
  filter: brightness(1.05);
  transform: translateY(-1px);
  box-shadow: 0 16px 32px rgba(11, 124, 108, 0.4);
}

.auth-submit:hover i {
  transform: translateX(3px);
}

.auth-submit:disabled {
  opacity: 0.75;
  transform: none;
}

.auth-copy {
  margin-top: 22px;
  text-align: center;
  font-size: 12px;
  color: #94a3b8 !important;
}

.auth-secure {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 14px;
  font-size: 12px;
  color: #64748b !important;
}

.auth-secure i {
  color: var(--auth-teal) !important;
}

/* Animations */
@keyframes authFloat {
  0%, 100% { transform: translateY(0) translateX(0); }
  50% { transform: translateY(-18px) translateX(8px); }
}

@keyframes authPulse {
  0% { box-shadow: 0 0 0 0 rgba(15, 159, 138, 0.55); }
  70% { box-shadow: 0 0 0 10px rgba(15, 159, 138, 0); }
  100% { box-shadow: 0 0 0 0 rgba(15, 159, 138, 0); }
}

@keyframes authBarRise {
  from { transform: scaleY(0.15); opacity: 0.3; }
  to { transform: scaleY(1); opacity: 1; }
}

@keyframes authGridDrift {
  from { transform: translateY(0); }
  to { transform: translateY(48px); }
}

@keyframes authFadeUp {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes authCardIn {
  from { opacity: 0; transform: translateY(24px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.anim-fade-up {
  animation: authFadeUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.anim-card {
  animation: authCardIn 0.75s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.delay-1 { animation-delay: 0.08s; }
.delay-2 { animation-delay: 0.16s; }
.delay-3 { animation-delay: 0.24s; }
.delay-4 { animation-delay: 0.32s; }
.delay-5 { animation-delay: 0.4s; }
.delay-6 { animation-delay: 0.48s; }
.delay-7 { animation-delay: 0.56s; }

@media (prefers-reduced-motion: reduce) {
  .anim-fade-up,
  .anim-card,
  .pipe-bar,
  .auth-orb,
  .auth-grid-glow,
  .auth-pulse {
    animation: none !important;
  }
}

@media (max-width: 991.98px) {
  .auth-shell {
    grid-template-columns: 1fr;
  }

  .auth-brand {
    display: none;
  }

  .auth-pro-body {
    background:
      radial-gradient(700px 320px at 50% -10%, rgba(15, 159, 138, 0.16), transparent 55%),
      #eef2f7;
  }
}

@media (max-width: 575.98px) {
  .auth-card {
    padding: 28px 20px 22px;
    border-radius: 18px;
  }
}
