/* Split auth screen — aligned with manage login; uses tokens.css */
.page--login {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-sans);
  color: var(--color-text);
  background: var(--color-bg-base);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.auth-shell {
  width: 100%;
  max-width: 960px;
}

.auth-card {
  display: grid;
  grid-template-columns: 1fr;
  background: var(--color-surface);
  border-radius: 16px;
  box-shadow: 0 12px 40px rgba(var(--shadow-rgb), 0.1), 0 2px 8px rgba(var(--shadow-rgb), 0.05);
  overflow: hidden;
  min-height: min(560px, calc(100vh - 3rem));
}

@media (min-width: 840px) {
  .auth-card {
    grid-template-columns: 1fr 1fr;
    min-height: 520px;
  }
}

.auth-panel--form {
  padding: 2rem 2rem 1.25rem;
  display: flex;
  flex-direction: column;
}

@media (min-width: 840px) {
  .auth-panel--form {
    padding: 2.5rem 2.75rem 1.5rem;
  }
}

.auth-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 2rem;
}

.auth-brand__mark {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--color-brand-primary), var(--color-brand-strong));
  box-shadow: 0 2px 8px rgba(var(--rgb-brand), 0.35);
}

.auth-brand__text {
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
  color: var(--color-text);
}

.auth-brand__text span {
  font-weight: 600;
  color: var(--color-brand-strong);
  margin-left: 0.25rem;
}

.auth-heading {
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin: 0 0 0.5rem;
  line-height: 1.2;
}

.auth-lead {
  margin: 0 0 1.5rem;
  font-size: 0.95rem;
  color: var(--color-text-muted);
  line-height: 1.5;
}

.auth-form {
  width: 100%;
  max-width: 100%;
}

.auth-field-group {
  margin-bottom: 1rem;
  width: 100%;
}

.auth-form .form__label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 0.4rem;
}

.auth-form .form__input {
  display: block;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--color-border);
  border-radius: 10px;
  font: inherit;
  background: var(--color-surface);
  transition: border-color 0.15s, box-shadow 0.15s;
}

.auth-form .form__input:focus {
  outline: none;
  border-color: var(--color-brand-primary);
  box-shadow: 0 0 0 3px rgba(var(--rgb-brand), 0.22);
}

.auth-form .form__input::placeholder {
  color: color-mix(in srgb, var(--color-text-muted) 72%, var(--color-surface));
}

.auth-field-wrap {
  position: relative;
  width: 100%;
  max-width: 100%;
}

.auth-field-wrap .form__input {
  padding-right: 2.75rem;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.auth-toggle-pw {
  position: absolute;
  right: 0.5rem;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: transparent;
  padding: 0.35rem;
  cursor: pointer;
  color: var(--color-text-muted);
  border-radius: 6px;
  line-height: 0;
}

.auth-toggle-pw:hover {
  color: var(--color-text);
  background: color-mix(in srgb, var(--color-info-bg) 55%, var(--color-surface));
}

.auth-toggle-pw:focus-visible {
  outline: 2px solid var(--color-brand-primary);
  outline-offset: 2px;
}

.auth-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  margin-bottom: 1.25rem;
  font-size: 0.875rem;
}

.auth-remember {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-weight: 500;
  color: var(--color-text-muted);
  user-select: none;
}

.auth-remember input {
  width: 1rem;
  height: 1rem;
  accent-color: var(--color-brand-strong);
}

.auth-link {
  color: var(--color-brand-strong);
  font-weight: 600;
  text-decoration: none;
}

.auth-link:hover {
  text-decoration: underline;
}

.auth-link--muted {
  color: var(--color-text-muted);
  font-weight: 500;
}

.auth-link--muted:hover {
  color: var(--color-brand-strong);
}

.auth-submit {
  display: block;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  padding: 0.75rem 1.25rem;
  font: inherit;
  font-weight: 600;
  font-size: 1rem;
  color: #fff;
  background: linear-gradient(180deg, var(--color-brand-primary) 0%, var(--color-brand-strong) 100%);
  border: none;
  border-radius: 10px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(var(--rgb-brand), 0.32);
  transition: transform 0.12s, box-shadow 0.12s;
}

.auth-submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(var(--rgb-brand), 0.38);
}

.auth-submit:active {
  transform: translateY(0);
}

.auth-switch {
  text-align: center;
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--color-border);
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

.auth-switch__line {
  margin: 0.4rem 0;
  line-height: 1.5;
}

.auth-switch__line .auth-link {
  margin-left: 0.15rem;
}

.auth-panel-footer {
  margin-top: auto;
  padding-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.auth-panel-footer a {
  color: var(--color-text-muted);
  text-decoration: none;
}

.auth-panel-footer a:hover {
  color: var(--color-brand-primary);
  text-decoration: underline;
}

.auth-panel--hero {
  position: relative;
  padding: 2rem 1.75rem;
  background: var(--color-brand-strong);
  color: #fff;
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

@media (min-width: 840px) {
  .auth-panel--hero {
    display: flex;
  }
}

.auth-hero__pattern {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 120% 80% at 100% 0%, rgba(255, 255, 255, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 20% 90%, rgba(0, 0, 0, 0.12) 0%, transparent 45%),
    radial-gradient(circle at 80% 40%, rgba(255, 255, 255, 0.06) 0%, transparent 35%);
  pointer-events: none;
}

.auth-hero__content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 100%;
  text-align: center;
}

.auth-hero__logo-wrap {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  margin: 0 0 0.85rem;
}

.auth-hero__logo {
  display: block;
  width: auto;
  height: auto;
  max-height: min(10.5rem, 42vh);
  max-width: min(16rem, 94%);
  margin-left: auto;
  margin-right: auto;
  object-fit: contain;
  object-position: center center;
  filter: drop-shadow(0 4px 20px rgba(0, 0, 0, 0.2));
}

.auth-hero__title {
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.3;
  margin: 0 auto 0.75rem;
  letter-spacing: -0.02em;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
  width: 100%;
  max-width: 22rem;
  text-align: center;
}

.auth-hero__subtitle {
  margin: 0 auto 1.75rem;
  font-size: 0.95rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.88);
  max-width: 22rem;
  text-align: center;
}

.auth-hero__content .hero-mock {
  align-self: stretch;
  width: 100%;
  text-align: left;
}

.hero-mock {
  position: relative;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  padding: 0.85rem;
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
}

.hero-mock__kpis {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin-bottom: 0.65rem;
}

.hero-mock__kpi {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  padding: 0.5rem 0.65rem;
}

.hero-mock__kpi-label {
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  opacity: 0.85;
  margin-bottom: 0.2rem;
}

.hero-mock__kpi-value {
  font-size: 1rem;
  font-weight: 700;
}

.hero-mock__chart {
  height: 4.5rem;
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.25) 0%, rgba(255, 255, 255, 0.08) 100%);
  margin-bottom: 0.5rem;
  position: relative;
  overflow: hidden;
}

.hero-mock__chart::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0.35rem;
  height: 2px;
  background: rgba(255, 255, 255, 0.35);
}

.hero-mock__bars {
  position: absolute;
  bottom: 0.5rem;
  left: 0.5rem;
  right: 0.5rem;
  display: flex;
  align-items: flex-end;
  gap: 4px;
  height: 2.5rem;
}

.hero-mock__bar {
  flex: 1;
  background: rgba(255, 255, 255, 0.5);
  border-radius: 2px 2px 0 0;
  min-height: 15%;
}

.hero-mock__bar:nth-child(1) { height: 45%; }
.hero-mock__bar:nth-child(2) { height: 70%; }
.hero-mock__bar:nth-child(3) { height: 55%; }
.hero-mock__bar:nth-child(4) { height: 90%; }
.hero-mock__bar:nth-child(5) { height: 60%; }
.hero-mock__bar:nth-child(6) { height: 40%; }

.hero-mock__table {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.hero-mock__row {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.hero-mock__cell {
  height: 0.35rem;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.35);
}

.hero-mock__cell--w40 { width: 40%; }
.hero-mock__cell--w25 { width: 25%; }
.hero-mock__cell--w20 { width: 20%; }

.page--login .alert {
  padding: 0.75rem 1rem;
  border-radius: 10px;
  font-size: 0.9rem;
  line-height: 1.45;
}

.page--login .alert--error {
  margin-bottom: 1rem;
  background: var(--color-alert-error-bg);
  color: var(--color-error);
  border: 1px solid var(--color-alert-error-border);
}

.page--login .alert--success {
  margin-bottom: 1rem;
  background: #edf6f0;
  color: #1e4d2a;
  border: 1px solid #b5d9c4;
}
