/* Login / auth page styles — layout H from the approved reference */

/* Base rules — standalone pages don't load base.css.
   Only what auth pages actually need is replicated here. */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-family);
  font-size: 14px;
  line-height: 1.5;
  color: #fff;
  -webkit-font-smoothing: antialiased;
}

.form-group {
  margin-bottom: 14px;
}

/* Full-bleed navy stage */
.login-stage {
  position: relative;
  min-height: 100vh;
  background: var(--color-structure);
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Engineering-pad grid on navy */
.login-grid {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .65;
  background-image:
    linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px),
    linear-gradient(rgba(255,255,255,.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.025) 1px, transparent 1px);
  background-size: 100px 100px, 100px 100px, 20px 20px, 20px 20px;
}

/* ============ Timeline — three bands on a shared time axis ============ */
.login-timeline {
  position: absolute;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  left: 6vw;
  right: calc(372px + 14vw - 56px);
  top: calc(28vh - 40px);
  bottom: calc(10vh + 20px);
}

.tl-label {
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(255,255,255,.24);
  margin-bottom: 7px;
}

.tl-now {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--now, 62%);
  width: 1px;
  background: rgba(201,138,60,.38);
  z-index: 4;
}

.tl-now::before {
  content: "DATA DATE";
  position: absolute;
  top: -16px;
  left: 7px;
  font-size: 9px;
  letter-spacing: .12em;
  color: rgba(201,138,60,.55);
  white-space: nowrap;
}

.tl-axis {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 1px;
  background: rgba(255,255,255,.09);
}

/* Schedule — Gantt bars */
.login-gantt {
  position: relative;
}

.gbar {
  position: relative;
  height: 5px;
  border-radius: 3px;
  margin-bottom: 6px;
  margin-left: calc(var(--s) * 1%);
  width: calc(var(--w) * 1%);
  background: rgba(255,255,255,.18);
  transform-origin: left;
  animation: extend 11s ease-in-out infinite alternate;
  animation-delay: var(--d);
}

.gbar.amber {
  background: rgba(201,138,60,.38);
}

.gbar:last-child {
  margin-bottom: 0;
}

@keyframes extend {
  from { transform: scaleX(.5); }
  to { transform: scaleX(1); }
}

/* Steps — chip band */
.login-steps {
  display: flex;
  gap: 3px;
}

.chip {
  flex: 1 1 0;
  height: 13px;
  min-width: 0;
  border-radius: 2px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.035);
  animation: wave 15s linear infinite;
  animation-delay: calc(var(--i) * .14s);
}

.chip.done {
  background: rgba(255,255,255,.11);
  border-color: transparent;
}

.chip.now {
  background: rgba(201,138,60,.3);
  border-color: rgba(201,138,60,.5);
}

@keyframes wave {
  0%, 90%, 100% { transform: none; }
  93% { background: var(--color-accent-on-dark); border-color: var(--color-accent-on-dark); transform: translateY(-3px); }
  96% { transform: none; }
}

/* Cost — histogram bars + S-curve */
.cost-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  height: 30%;
}

.cost {
  position: relative;
  flex: 1;
  display: flex;
  align-items: flex-end;
  gap: .9%;
}

.hbar {
  flex: 1;
  border-radius: 2px 2px 0 0;
  background: rgba(255,255,255,.15);
  height: calc(var(--h) * 1.35%);
  transform-origin: bottom;
  transform: scaleY(0);
}

/* 20 synced keyframes — copied verbatim from the reference */
@keyframes hb0{0%,0.0%{transform:scaleY(0)}2.5%,97.5%{transform:scaleY(1)}100.0%,100%{transform:scaleY(0)}}
.hbar:nth-child(1){animation:hb0 24s linear infinite}
@keyframes hb1{0%,2.0%{transform:scaleY(0)}5.0%,95.0%{transform:scaleY(1)}98.0%,100%{transform:scaleY(0)}}
.hbar:nth-child(2){animation:hb1 24s linear infinite}
@keyframes hb2{0%,4.5%{transform:scaleY(0)}7.5%,92.5%{transform:scaleY(1)}95.5%,100%{transform:scaleY(0)}}
.hbar:nth-child(3){animation:hb2 24s linear infinite}
@keyframes hb3{0%,7.0%{transform:scaleY(0)}10.0%,90.0%{transform:scaleY(1)}93.0%,100%{transform:scaleY(0)}}
.hbar:nth-child(4){animation:hb3 24s linear infinite}
@keyframes hb4{0%,9.5%{transform:scaleY(0)}12.5%,87.5%{transform:scaleY(1)}90.5%,100%{transform:scaleY(0)}}
.hbar:nth-child(5){animation:hb4 24s linear infinite}
@keyframes hb5{0%,12.0%{transform:scaleY(0)}15.0%,85.0%{transform:scaleY(1)}88.0%,100%{transform:scaleY(0)}}
.hbar:nth-child(6){animation:hb5 24s linear infinite}
@keyframes hb6{0%,14.5%{transform:scaleY(0)}17.5%,82.5%{transform:scaleY(1)}85.5%,100%{transform:scaleY(0)}}
.hbar:nth-child(7){animation:hb6 24s linear infinite}
@keyframes hb7{0%,17.0%{transform:scaleY(0)}20.0%,80.0%{transform:scaleY(1)}83.0%,100%{transform:scaleY(0)}}
.hbar:nth-child(8){animation:hb7 24s linear infinite}
@keyframes hb8{0%,19.5%{transform:scaleY(0)}22.5%,77.5%{transform:scaleY(1)}80.5%,100%{transform:scaleY(0)}}
.hbar:nth-child(9){animation:hb8 24s linear infinite}
@keyframes hb9{0%,22.0%{transform:scaleY(0)}25.0%,75.0%{transform:scaleY(1)}78.0%,100%{transform:scaleY(0)}}
.hbar:nth-child(10){animation:hb9 24s linear infinite}
@keyframes hb10{0%,24.5%{transform:scaleY(0)}27.5%,72.5%{transform:scaleY(1)}75.5%,100%{transform:scaleY(0)}}
.hbar:nth-child(11){animation:hb10 24s linear infinite}
@keyframes hb11{0%,27.0%{transform:scaleY(0)}30.0%,70.0%{transform:scaleY(1)}73.0%,100%{transform:scaleY(0)}}
.hbar:nth-child(12){animation:hb11 24s linear infinite}
@keyframes hb12{0%,29.5%{transform:scaleY(0)}32.5%,67.5%{transform:scaleY(1)}70.5%,100%{transform:scaleY(0)}}
.hbar:nth-child(13){animation:hb12 24s linear infinite}
@keyframes hb13{0%,32.0%{transform:scaleY(0)}35.0%,65.0%{transform:scaleY(1)}68.0%,100%{transform:scaleY(0)}}
.hbar:nth-child(14){animation:hb13 24s linear infinite}
@keyframes hb14{0%,34.5%{transform:scaleY(0)}37.5%,62.5%{transform:scaleY(1)}65.5%,100%{transform:scaleY(0)}}
.hbar:nth-child(15){animation:hb14 24s linear infinite}
@keyframes hb15{0%,37.0%{transform:scaleY(0)}40.0%,60.0%{transform:scaleY(1)}63.0%,100%{transform:scaleY(0)}}
.hbar:nth-child(16){animation:hb15 24s linear infinite}
@keyframes hb16{0%,39.5%{transform:scaleY(0)}42.5%,57.5%{transform:scaleY(1)}60.5%,100%{transform:scaleY(0)}}
.hbar:nth-child(17){animation:hb16 24s linear infinite}
@keyframes hb17{0%,42.0%{transform:scaleY(0)}45.0%,55.0%{transform:scaleY(1)}58.0%,100%{transform:scaleY(0)}}
.hbar:nth-child(18){animation:hb17 24s linear infinite}
@keyframes hb18{0%,44.5%{transform:scaleY(0)}47.5%,52.5%{transform:scaleY(1)}55.5%,100%{transform:scaleY(0)}}
.hbar:nth-child(19){animation:hb18 24s linear infinite}
@keyframes hb19{0%,47.0%{transform:scaleY(0)}50.0%,50.0%{transform:scaleY(1)}53.0%,100%{transform:scaleY(0)}}
.hbar:nth-child(20){animation:hb19 24s linear infinite}

.curve {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  bottom: 0;
  overflow: visible;
}

.curve polyline {
  fill: none;
  stroke: rgba(201,138,60,.72);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 1000;
  stroke-dashoffset: 1000;
  animation: trace 24s linear infinite;
}

@keyframes trace {
  0% { stroke-dashoffset: 1000; }
  50% { stroke-dashoffset: 0; }
  100% { stroke-dashoffset: 1000; }
}

/* ============ Right rail ============ */
.login-rail {
  position: absolute;
  top: 0;
  bottom: 0;
  right: 14vw;
  z-index: 6;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-bottom: 200px;
  width: 372px;
  color: #FFFFFF;
}

.login-wordmark {
  font-size: 50px;
  font-weight: var(--font-weight-strong);
  letter-spacing: -.03em;
  line-height: 1;
  color: #FFFFFF;
}

.wm-dot {
  color: var(--color-accent-on-dark);
}

.login-rule {
  width: 64px;
  height: 3px;
  background: var(--color-accent-on-dark);
  margin: 18px 0;
}

.login-tagline {
  font-size: 20px;
  font-weight: var(--font-weight-medium);
  letter-spacing: -.01em;
  line-height: 1.4;
  margin-bottom: 26px;
}

.login-tagline em {
  font-style: normal;
  color: var(--color-accent-on-dark);
}

/* ============ Card ============ */
.login-card {
  background: var(--color-bg);
  color: var(--color-text);
  border-radius: var(--radius-lg);
  padding: 30px 28px;
  box-shadow: 0 24px 70px rgba(0,0,0,.45);
  width: 372px;
}

.login-card h2 {
  font-size: 19px;
  font-weight: var(--font-weight-strong);
  margin-bottom: 3px;
  color: var(--color-text);
  border: none;
  padding: 0;
}

.login-card .login-tenant {
  font-size: var(--font-size-small);
  color: var(--color-text-muted);
  margin-bottom: 22px;
}

.login-card .form-group {
  margin-bottom: 14px;
}

.login-card label {
  font-size: 11px;
  font-weight: var(--font-weight-medium);
  letter-spacing: .04em;
  text-transform: uppercase;
  margin-bottom: 5px;
}

.login-card input[type="email"],
.login-card input[type="password"],
.login-card input[type="text"] {
  width: 100%;
  height: 40px;
  padding: 0 12px;
  font: inherit;
  font-size: var(--font-size-body);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-bg);
  color: var(--color-text);
}

.login-card input:focus {
  outline: 2px solid var(--color-accent);
  outline-offset: 1px;
}

.login-submit {
  width: 100%;
  height: 42px;
  font: inherit;
  font-size: var(--font-size-dense);
  font-weight: var(--font-weight-strong);
  border: none;
  border-radius: var(--radius-md);
  background: var(--color-accent);
  color: var(--color-on-accent);
  cursor: pointer;
}

.login-submit:hover {
  opacity: .9;
}

.login-forgot {
  display: block;
  margin-top: 12px;
  font-size: var(--font-size-small);
  color: var(--color-text-muted);
  text-decoration: none;
}

.login-forgot:hover {
  color: var(--color-text);
}

.login-card .login-help {
  font-size: var(--font-size-small);
  color: var(--color-text-muted);
  margin-bottom: 22px;
}

/* Error state */
.login-error {
  background: #FDF0F0;
  color: var(--color-error);
  font-size: var(--font-size-small);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  margin-bottom: 14px;
}

/* ============ Reduced motion ============ */
@media (prefers-reduced-motion: reduce) {
  .chip, .gbar, .hbar, .curve polyline {
    animation: none;
  }
  .curve polyline {
    stroke-dashoffset: 0;
  }
  .hbar {
    transform: scaleY(1);
  }
}
