/* ============================================================
   Base Industries — Client Portal / Login
   Premium split-screen auth. Self-contained; does not touch
   Bootstrap or branding.css.
   ============================================================ */

:root {
  --bi-ink: #080f26;
  --bi-dark: #0d1730;
  --bi-dark-2: #0b1230;
  --bi-primary: #0b2fd8;
  --bi-primary-2: #0f41ff;
  --bi-accent: #F57A20;
  --bi-accent-2: #FF9A4D;
  --bi-text: #2a3442;
  --bi-text-soft: #56637a;
  --bi-border: #d5dbe5;
  --bi-surface: #f3f6fa;
  --bi-font-display: "Sora", "Segoe UI", sans-serif;
  --bi-font-body: "Manrope", "Segoe UI", sans-serif;
}

/* Reset the Dastone account body wrapper */
.account-body,
.account-body.accountbg {
  min-height: 100vh;
  margin: 0;
  padding: 0;
  background: #eef3fa;
  font-family: var(--bi-font-body);
  display: flex;
  align-items: stretch;
}

/* ============ Shell ============ */
.auth-shell {
  width: 100%;
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
}

/* ============ Brand panel ============ */
.auth-panel {
  position: relative;
  min-height: 100vh;
}

.auth-panel--brand {
  background:
    radial-gradient(120% 90% at 85% 15%, rgba(11,47,216,0.35) 0%, transparent 55%),
    linear-gradient(150deg, var(--bi-dark) 0%, var(--bi-dark-2) 60%, #12285e 100%);
  color: #fff;
  overflow: hidden;
  display: flex;
  align-items: stretch;
}

/* Engineering grid texture */
.auth-panel__grid {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 68px 68px;
  -webkit-mask-image: radial-gradient(120% 95% at 80% 0%, #000 0%, transparent 75%);
  mask-image: radial-gradient(120% 95% at 80% 0%, #000 0%, transparent 75%);
}

/* Soft top scrim for legibility */
.auth-panel__scrim {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(180deg, rgba(8,15,38,0.4) 0%, transparent 40%, rgba(8,15,38,0.5) 100%);
}

/* Film grain for depth */
.auth-panel--brand::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  opacity: 0.05;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.auth-panel__content {
  position: relative;
  z-index: 3;
  width: 100%;
  max-width: 640px;
  margin: auto;
  padding: clamp(2.5rem, 5vw, 5rem);
  display: flex;
  flex-direction: column;
  gap: 2.25rem;
}

/* Brand logo */
.auth-brand img {
  height: 48px;
  width: auto;
  display: block;
}
.auth-brand--mobile { display: none; }

/* Hero — explicit colors: Dastone app.min.css forces h1–h6 to a dark
   ink color, so we pin the panel's headings to white with high specificity. */
.auth-panel--brand .auth-eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--bi-accent-2) !important;
}

.auth-hero { margin-top: 0; }
.auth-panel--brand .auth-hero__title {
  font-family: var(--bi-font-display);
  font-size: clamp(2.6rem, 4.4vw, 4.5rem);
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -0.035em;
  margin: 0.9rem 0 1.1rem;
  color: #fff !important;
}
.auth-hero__accent {
  color: var(--bi-accent) !important;
  display: block;
}
.auth-panel--brand .auth-hero__sub {
  font-size: clamp(1rem, 1.3vw, 1.18rem);
  line-height: 1.65;
  color: rgba(255,255,255,0.82) !important;
  max-width: 40ch;
  margin: 0;
}

/* Stat row */
.auth-stats {
  list-style: none;
  margin: 1rem 0 0;
  padding: 1.5rem 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  border-top: 1px solid rgba(255,255,255,0.14);
  border-bottom: 1px solid rgba(255,255,255,0.14);
}
.auth-stats li { display: flex; flex-direction: column; gap: 0.3rem; }
.auth-stats__num {
  font-family: var(--bi-font-display);
  font-size: clamp(1.4rem, 2.4vw, 2rem);
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.02em;
}
.auth-stats__label {
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: rgba(255,255,255,0.6);
  text-transform: uppercase;
}

.auth-panel__foot {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.55);
  letter-spacing: 0.04em;
}

/* ============ Form panel ============ */
.auth-panel--form {
  background: linear-gradient(180deg, #f7f9fd 0%, #eef3fa 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(1.5rem, 4vw, 3.5rem);
}

.auth-form-wrap {
  width: 100%;
  max-width: 420px;
  margin: auto;
  padding: 1rem 0;
}

.auth-form-head {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--bi-border);
}
.auth-form-head h2 {
  font-family: var(--bi-font-display);
  font-size: clamp(1.7rem, 3vw, 2.2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--bi-ink);
  margin: 0.6rem 0 0.4rem;
}
.auth-form-head p {
  color: var(--bi-text-soft);
  margin: 0;
  font-size: 0.98rem;
}

/* Fields */
.auth-field { margin-bottom: 1.15rem; }
.auth-field .form-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--bi-text);
  letter-spacing: 0.02em;
  margin-bottom: 0.4rem;
}
.auth-field .form-control {
  font-family: var(--bi-font-body);
  font-size: 1rem;
  padding: 0.8rem 1rem;
  border: 1px solid var(--bi-border);
  border-radius: 0.6rem;
  background: #fff;
  color: var(--bi-text);
  transition: border-color 200ms ease, box-shadow 200ms ease;
}
.auth-field .form-control::placeholder { color: #9aa6b8; }
.auth-field .form-control:focus {
  border-color: var(--bi-primary);
  box-shadow: 0 0 0 0.22rem rgba(11,47,216,0.16);
}

/* Divider label between field groups */
.auth-divider {
  display: flex;
  align-items: center;
  margin: 1.4rem 0;
  color: var(--bi-text-soft);
}
.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--bi-border);
}
.auth-divider span {
  padding: 0 0.8rem;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* Submit button */
.auth-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  margin-top: 0.75rem;
  padding: 0.9rem 1.4rem;
  font-family: var(--bi-font-display);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: #fff;
  background: linear-gradient(135deg, var(--bi-primary) 0%, var(--bi-primary-2) 100%);
  border: none;
  border-radius: 0.7rem;
  cursor: pointer;
  box-shadow: 0 12px 28px rgba(11,47,216,0.32);
  transition: transform 200ms ease, box-shadow 200ms ease, background 200ms ease;
}
.auth-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(11,47,216,0.42);
}
.auth-submit:active { transform: translateY(0); }
.auth-submit__arrow { transition: transform 200ms ease; }
.auth-submit:hover .auth-submit__arrow { transform: translateX(4px); }

/* Alternate links */
.auth-alt {
  margin: 1.25rem 0 0;
  text-align: center;
  font-size: 0.92rem;
  color: var(--bi-text-soft);
}
.auth-alt a { color: var(--bi-primary); font-weight: 700; }
.auth-alt-row {
  margin: 0.25rem 0 1rem;
  text-align: right;
}
.auth-register-link {
  font-size: 0.86rem;
  color: var(--bi-text-soft);
  font-weight: 600;
}
.auth-register-link:hover { color: var(--bi-primary); }

/* Error alert */
.auth-alert {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 1.25rem;
  padding: 0.85rem 1rem;
  font-size: 0.92rem;
  font-weight: 600;
  color: #b42318;
  background: #fef3f2;
  border: 1px solid #fed7d7;
  border-radius: 0.6rem;
}
.auth-alert::before {
  content: "!";
  flex: 0 0 auto;
  width: 1.4rem;
  height: 1.4rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 800;
  color: #fff;
  background: #d92d20;
}

/* Success state */
.auth-success {
  text-align: center;
  padding: 2rem 0.5rem;
}
.auth-success__icon {
  width: 3.4rem;
  height: 3.4rem;
  margin: 0 auto 1.2rem;
  display: grid;
  place-items: center;
  font-size: 1.6rem;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(135deg, #12b76a 0%, #0e9f5a 100%);
  border-radius: 50%;
  box-shadow: 0 12px 28px rgba(18,183,106,0.32);
}
.auth-success h3 {
  font-family: var(--bi-font-display);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--bi-ink);
  margin: 0 0 0.5rem;
}
.auth-success p {
  color: var(--bi-text-soft);
  margin: 0 0 1.5rem;
}

/* Footer */
.auth-foot {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--bi-border);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  flex-wrap: wrap;
  font-size: 0.82rem;
  color: var(--bi-text-soft);
}
.auth-foot a { color: var(--bi-text-soft); font-weight: 600; }
.auth-foot a:hover { color: var(--bi-primary); }
.auth-foot__dot { color: var(--bi-border); }

/* ============ Responsive ============ */
@media (max-width: 991.98px) {
  .auth-shell {
    grid-template-columns: 1fr;
    min-height: 100vh;
  }
  .auth-panel--brand {
    min-height: auto;
    padding: 0;
  }
  .auth-panel__content {
    margin: 0;
    padding: 2.25rem 1.75rem;
    gap: 1.5rem;
  }
  .auth-hero { margin-top: 0.5rem; }
  .auth-hero__title { font-size: clamp(2rem, 9vw, 3rem); }
  .auth-stats { display: none; }
  .auth-panel__foot { display: none; }
  .auth-brand--mobile { display: inline-block; }
  .auth-panel--form { padding: 2.25rem 1.5rem 3rem; }
}

@media (max-width: 480px) {
  .auth-hero__sub { font-size: 0.95rem; }
}