/* Modus (BRAND=2) auth pages — two-panel login / forgot / reset */

:root {
  --azure:       #2771FF;
  --azure-deep:  #1a5ce8;
  --azure-muted: #6699FF;
  --navy:        #0F2439;
  --orchid:      #D3B0FF;
  --cocoa:       #362314;
  --gray-50:     #fafaf9;
  --gray-200:    #e8e5e1;
  --gray-300:    #d0ccc6;
  --gray-400:    #aaa49e;
  --gray-500:    #888280;
  --gray-600:    #5e5a57;
  --font-display:'DM Serif Display', Georgia, serif;
  --font-body:   'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --ease-out:    cubic-bezier(0.16, 1, 0.3, 1);
}

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

html, body {
  min-height: 100%;
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  background: #fff;
}

/* ============================================
   PAGE — two panels, content toward center seam
   ============================================ */
.page {
  min-height: 100vh;
  display: flex;
  align-items: stretch;
}

/* ── LEFT: brand panel ── */
.panel-left {
  flex: 1 1 50%;
  background: var(--navy);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-end;
  padding: 56px 64px;
}

.panel-left::before {
  content: '';
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 70% 60% at 30% 110%, rgba(39,113,255,.25) 0%, transparent 60%),
    radial-gradient(ellipse 50% 40% at 90% -10%, rgba(211,176,255,.15) 0%, transparent 60%);
}

.panel-left::after {
  content: '';
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px);
  background-size: 48px 48px;
}

.left-inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 460px;
  display: flex;
  flex-direction: column;
  animation: fadeUp .55s var(--ease-out) both;
}

.brand { margin-bottom: 44px; }
.brand-logo { height: 34px; width: auto; display: block; }

.headline {
  font-family: var(--font-display);
  font-size: clamp(30px, 3vw, 40px);
  line-height: 1.15;
  letter-spacing: -.3px;
  color: #fff;
  margin-bottom: 18px;
}
.headline em { color: var(--orchid); font-style: italic; }

.lede {
  font-size: 15px;
  line-height: 1.65;
  color: rgba(255,255,255,.5);
  max-width: 420px;
}

.pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 32px;
  max-width: 420px;
}
.pill {
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 20px;
  padding: 5px 14px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .3px;
  color: rgba(255,255,255,.5);
  white-space: nowrap;
}

.left-footer {
  margin-top: 48px;
  font-size: 11px;
  color: rgba(255,255,255,.25);
}
.left-footer a {
  color: rgba(255,255,255,.5);
  text-decoration: none;
  font-weight: 500;
  transition: color .15s;
}
.left-footer a:hover { color: rgba(255,255,255,.8); }

/* ── RIGHT: form panel ── */
.panel-right {
  flex: 1 1 50%;
  background: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: 56px 64px;
}

.right-inner {
  width: 100%;
  max-width: 380px;
  animation: fadeUp .55s var(--ease-out) .08s both;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.mobile-brand { display: none; }

.form-header { margin-bottom: 30px; }
.form-title {
  font-family: var(--font-display);
  font-size: 27px;
  color: var(--navy);
  margin-bottom: 6px;
  letter-spacing: -.2px;
}
.form-sub {
  font-size: 13.5px;
  color: var(--gray-500);
  line-height: 1.5;
}

.form { display: flex; flex-direction: column; gap: 17px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }

label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .3px;
  color: var(--gray-600);
}

input[type="text"],
input[type="email"],
input[type="password"] {
  width: 100%;
  padding: 12px 14px;
  border-radius: 8px;
  border: 1.5px solid var(--gray-200);
  background: var(--gray-50);
  color: var(--cocoa);
  font-family: var(--font-body);
  font-size: 14px;
  outline: none;
  transition: border-color .2s, background .2s, box-shadow .2s;
}
input::placeholder { color: var(--gray-400); }
input:focus {
  border-color: var(--azure);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(39,113,255,.1);
}

.input-wrap { position: relative; }
.input-wrap input { padding-right: 44px; }
.toggle-pw {
  position: absolute;
  right: 12px; top: 50%;
  transform: translateY(-50%);
  background: none; border: none;
  cursor: pointer;
  color: var(--gray-400);
  padding: 4px; line-height: 0;
  transition: color .15s;
}
.toggle-pw:hover { color: var(--gray-600); }
.toggle-pw:focus-visible {
  outline: 2px solid var(--azure);
  outline-offset: 2px;
  border-radius: 4px;
}

.forgot { text-align: right; margin-top: -7px; }
.forgot a {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--azure);
  text-decoration: none;
  transition: color .15s;
}
.forgot a:hover { color: var(--azure-deep); text-decoration: underline; }

.btn-primary {
  width: 100%;
  padding: 13px 20px;
  margin-top: 4px;
  border: none;
  border-radius: 8px;
  background: var(--azure);
  color: #fff;
  font-family: var(--font-body);
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: .2px;
  cursor: pointer;
  transition: background .2s, box-shadow .2s, transform .15s;
  box-shadow: 0 2px 12px rgba(39,113,255,.3);
}
.btn-primary:hover {
  background: var(--azure-deep);
  box-shadow: 0 4px 20px rgba(39,113,255,.42);
  transform: translateY(-1px);
}
.btn-primary:active { transform: translateY(0); }
.btn-primary:focus-visible {
  outline: 2px solid var(--navy);
  outline-offset: 2px;
}

a.btn-primary {
  display: block;
  text-align: center;
  text-decoration: none;
  line-height: 1.25;
  box-sizing: border-box;
}
a.btn-primary:hover { color: #fff; }

.right-footer {
  margin-top: 30px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
}
.right-footer a {
  font-size: 11.5px;
  color: var(--gray-400);
  text-decoration: none;
  transition: color .15s;
}
.right-footer a:hover { color: var(--gray-600); }

.card-title {
  font-family: var(--font-display);
  font-size: 27px;
  color: var(--navy);
  margin-bottom: 6px;
  letter-spacing: -.2px;
}
.card-sub {
  font-size: 13.5px;
  color: var(--gray-500);
  line-height: 1.5;
  margin-bottom: 24px;
}
.auth-back {
  text-align: center;
  margin-top: 4px;
}
.auth-back a {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--azure);
  text-decoration: none;
  transition: color .15s;
}
.auth-back a:hover { color: var(--azure-deep); text-decoration: underline; }

.login-alert {
  padding: 12px 14px;
  border-radius: 8px;
  margin-bottom: 4px;
  font-size: 13px;
  line-height: 1.45;
}
.login-alert a { color: inherit; text-decoration: underline; }
.login-alert-danger { background: #fef2f2; border: 1px solid #fecaca; color: #b91c1c; }
.login-alert-warning { background: #fffbeb; border: 1px solid #fde68a; color: #92400e; }
.login-alert-success { background: #f0fdf4; border: 1px solid #bbf7d0; color: #166534; }
.login-alert-info { background: #eff6ff; border: 1px solid #bfdbfe; color: #1e40af; }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1100px) {
  .panel-left  { padding: 48px 44px; }
  .panel-right { padding: 48px 44px; }
}

@media (max-width: 860px) {
  .page { flex-direction: column; }

  .panel-left { display: none; }

  .panel-right {
    flex: 1 1 auto;
    min-height: 100vh;
    align-items: center;
    justify-content: flex-start;
    padding: 48px 24px 40px;
  }

  .right-inner { max-width: 400px; }

  .mobile-brand {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    margin-bottom: 32px;
  }
  .mobile-logo { height: 28px; width: auto; display: block; }
  .mobile-tagline {
    font-size: 10.5px;
    letter-spacing: .9px;
    text-transform: uppercase;
    color: var(--gray-400);
    font-weight: 500;
  }

  .mobile-powered {
    display: block;
    margin-top: 14px;
    font-size: 11.5px;
    color: var(--gray-400);
  }
  .mobile-powered a {
    color: var(--gray-600);
    text-decoration: none;
    font-weight: 500;
  }
  .mobile-powered a:hover { color: var(--cocoa); }
}

.mobile-powered { display: none; }

@media (max-width: 400px) {
  .panel-right { padding: 40px 20px 36px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}
