:root {
  --blue-900: #1e3a8a;
  --blue-700: #1d4ed8;
  --blue-600: #2563eb;
  --blue-500: #3b82f6;
  --gold: #f5b700;
  --ink: #0f172a;
  --muted: #64748b;
  --border: #e2e8f0;
  --page-bg: #f7f9fc;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: #fff;
  color: var(--ink);
  font-family: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* ---------- Split layout ---------- */

/* The nav's container is min(100% - 80px, 1120px) centred, so the logo's
   left edge sits at max(40px, (100vw - 1120px) / 2). The hero copy uses the
   same expression, which is what lines the two up at every width. */
.auth-split {
  position: relative;
  display: flex;
  min-height: calc(100vh - 76px);
  background: #fff url("images/hero-skyline.jpg") center / cover no-repeat;
  isolation: isolate;
}
/* A white wash rather than a dark one: nearly solid at the left where the
   copy sits, thinning towards the right so the skyline still shows as a pale
   blue cityscape. The tints are taken from the photograph's own blue. */
.auth-split::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    100deg,
    rgba(255, 255, 255, 0.985) 0%,
    rgba(248, 251, 255, 0.96) 34%,
    rgba(227, 238, 255, 0.86) 62%,
    rgba(206, 226, 252, 0.76) 100%
  );
}

.auth-hero {
  flex: 1;
  padding: 72px 56px 72px max(40px, calc((100vw - 1120px) / 2));
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.auth-split .auth-hero .eyebrow {
  color: var(--blue-600);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.auth-hero .eyebrow {
  color: var(--blue-600);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.auth-hero h1 {
  font-size: 34px;
  line-height: 1.2;
  margin: 14px 0;
  font-weight: 800;
}
.auth-split .auth-hero h1 {
  font-size: 46px;
  line-height: 1.12;
  margin: 18px 0 20px;
  color: var(--ink);
  letter-spacing: -0.02em;
}
.accent-blue {
  color: var(--blue-600);
}
.auth-split .accent-blue {
  color: var(--blue-600);
}
/* A lighter gold than the body text would take, which a 46px bold display
   heading can carry. */
.auth-split .accent-gold {
  color: #eaa600;
}
.accent-gold {
  color: var(--gold);
}
.auth-hero p {
  color: var(--muted);
  font-size: 15px;
  max-width: 420px;
  line-height: 1.5;
}
.auth-split .auth-hero p {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.6;
  max-width: 460px;
}
.auth-hero .footnote {
  color: var(--blue-600);
  font-size: 13px;
  margin-top: 32px;
}
.auth-split .auth-hero .footnote {
  color: var(--blue-700);
  font-size: 14px;
  font-weight: 600;
  margin-top: 36px;
}

.auth-card-wrap {
  flex: 1;
}
/* The card column carries the wider element, so it gets the larger share --
   an even split leaves the card short of its 560px. */
.auth-split .auth-card-wrap {
  flex: 1.15;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px max(40px, calc((100vw - 1120px) / 2)) 48px 48px;
  background: none;
}

/* ---------- Sign Up ----------
   Same split and skyline as login. The form has a three-column name row and
   two two-column rows, so its card gets the wider share of the page. */
.auth-split.auth-split-signup .auth-card-wrap {
  flex: 1.45;
}
.auth-split.auth-split-signup .auth-card {
  max-width: 680px;
}
/* The hero keeps the logo gutter, which leaves it narrower here than on
   login, so the heading is set a step smaller to match. */
.auth-split.auth-split-signup .auth-hero h1 {
  font-size: 39px;
}
.auth-split.auth-split-signup .auth-hero p {
  font-size: 16px;
  max-width: 400px;
}
/* Sign-up is a taller form -- let it scroll rather than centring a card that
   overflows the viewport. */
.auth-split.auth-split-signup .auth-card-wrap {
  align-items: flex-start;
  padding-top: 56px;
  padding-bottom: 56px;
}

.auth-card {
  background: #fff;
  border-radius: 18px;
  border: 1px solid var(--border);
  box-shadow: 0 10px 30px -15px rgba(15, 23, 42, 0.15);
  padding: 36px;
  width: 100%;
  max-width: 480px;
}
.auth-card .eyebrow {
  color: var(--blue-600);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.auth-card h2 {
  margin: 8px 0 4px;
  font-size: 22px;
  font-weight: 800;
}
.card-subtext {
  color: var(--muted);
  font-size: 13.5px;
  margin: 0 0 20px;
}

/* ---------- Form elements ---------- */
form label {
  display: block;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--ink);
  margin: 14px 0 6px;
}
form input[type="text"],
form input[type="email"],
form input[type="password"],
form input[type="date"],
form select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 9px;
  font-size: 14px;
  color: var(--ink);
}
form input:focus,
form select:focus {
  outline: 2px solid var(--blue-500);
  outline-offset: 1px;
  border-color: var(--blue-500);
}
.password-field {
  position: relative;
}
.password-field input {
  padding-right: 42px;
}
.password-toggle-btn {
  position: absolute;
  top: 50%;
  right: 6px;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: none;
  border-radius: 6px;
  background: none;
  color: var(--muted);
  cursor: pointer;
}
.password-toggle-btn:hover {
  color: var(--ink);
  background: #f1f5f9;
}
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.grid-3 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 16px;
}
.grid-2 > div label,
.grid-3 > div label {
  margin-top: 0;
}

.row-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 14px;
}
.checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--muted);
  font-weight: 500;
}
.link-small {
  color: var(--blue-600);
  font-size: 13px;
  text-decoration: none;
  font-weight: 600;
}

/* .row-between spreads its children apart, which pushes a lone link to the
   left. With the remember-me checkbox gone, the row holds only the link. */
.row-end {
  justify-content: flex-end;
}

.agree-row {
  margin-top: 18px;
  align-items: flex-start;
  position: relative;
}
.agree-row a {
  color: var(--blue-600);
  font-weight: 600;
  text-decoration: none;
}
.required-tag {
  position: absolute;
  right: 0;
  color: #dc2626;
  font-size: 12px;
  font-weight: 700;
}

.btn-primary-full {
  width: 100%;
  margin-top: 22px;
  padding: 13px;
  border: none;
  border-radius: 10px;
  background: var(--blue-600);
  color: #fff;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
}
.btn-primary-full:hover {
  background: var(--blue-700);
}
.btn-primary-full:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.signup-prompt {
  text-align: center;
  font-size: 13.5px;
  color: var(--muted);
  margin-top: 16px;
}
.signup-prompt a {
  color: var(--blue-600);
  font-weight: 700;
  text-decoration: none;
}

.secure-note {
  margin-top: 20px;
  padding: 14px 16px;
  background: #f1f5f9;
  border-radius: 10px;
}
.secure-note strong {
  display: block;
  font-size: 13px;
  color: var(--ink);
}
.secure-note p {
  margin: 4px 0 0;
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.4;
}

/* ---------- Login page: a larger card, and a larger scale inside it ----------
   Scoped to .auth-split throughout. Sign-up shares this stylesheet through
   .auth-stack, and its two- and three-column rows do not have the room. */
.auth-split .auth-card {
  max-width: 560px;
  padding: 44px 44px 40px;
  border-radius: 22px;
  /* On a near-white page the card needs its own edge to separate -- the
     heavier shadow it used against the dark field is no longer enough. */
  border: 1px solid #dde7f7;
  box-shadow: 0 18px 44px -20px rgba(15, 40, 95, 0.28);
}
.auth-split .auth-card .eyebrow {
  font-size: 12px;
  letter-spacing: 0.1em;
}
.auth-split .auth-card h2 {
  font-size: 29px;
  margin: 10px 0 6px;
  letter-spacing: -0.02em;
}
.auth-split .card-subtext {
  font-size: 15px;
  line-height: 1.5;
  margin-bottom: 26px;
}
.auth-split form label {
  font-size: 13.5px;
  margin: 18px 0 7px;
}
.auth-split form input[type="text"],
.auth-split form input[type="password"],
.auth-split form input[type="date"] {
  padding: 14px 16px;
  font-size: 15.5px;
  border-radius: 11px;
}
/* input[type="password"] above carries an attribute selector, which outranks
   a plain .password-field input -- so this has to match on the type too. */
.auth-split .password-field input[type="password"],
.auth-split .password-field input[type="text"] {
  padding-right: 52px;
}

/* A step below the typed value. The sign-up password hint ("Create a strong
   password (min. 8 characters)") does not fit its field at 15.5px. */
.auth-split form input::placeholder {
  font-size: 13.5px;
}
.auth-split .password-toggle-btn {
  width: 38px;
  height: 38px;
  right: 8px;
}
.auth-split .row-between {
  margin-top: 18px;
}
.auth-split .checkbox-label,
.auth-split .link-small {
  font-size: 14px;
}
.auth-split .btn-primary-full {
  margin-top: 26px;
  padding: 16px;
  font-size: 16.5px;
  border-radius: 12px;
}
.auth-split .signup-prompt {
  font-size: 14.5px;
  margin-top: 20px;
}

/* ---------- Login page: the closing note as an information card ---------- */
.auth-split .secure-note {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 24px;
  padding: 16px 18px;
  background: #eff4ff;
  border: 1px solid #dbe6ff;
  border-radius: 14px;
}
.secure-note-icon {
  flex: none;
  width: 20px;
  height: 20px;
  margin-top: 1px;
  color: var(--blue-600);
}
.auth-split .secure-note strong {
  font-size: 14px;
  font-weight: 700;
  color: var(--blue-700);
}
.auth-split .secure-note p {
  margin-top: 5px;
  font-size: 13px;
  line-height: 1.55;
  color: #5b6b8c;
}

.form-error {
  background: #fee2e2;
  color: #b91c1c;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 13px;
  margin-bottom: 14px;
  font-weight: 600;
}
.form-success {
  background: #dcfce7;
  color: #15803d;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 13px;
  margin-bottom: 14px;
  font-weight: 600;
}

@media (max-width: 1080px) {
  /* Below this the two halves are too narrow to carry 46px headings and a
     560px card side by side. */
  .auth-split {
    flex-direction: column;
  }
  .auth-hero {
    /* same gutter expression as the nav, so the copy still starts on the
       logo's line once the halves stack */
    padding: 56px max(40px, calc((100vw - 1120px) / 2)) 8px;
  }
  .auth-split .auth-hero h1 {
    font-size: 36px;
  }
  .auth-card-wrap {
    padding: 32px max(40px, calc((100vw - 1120px) / 2)) 56px;
  }
}

@media (max-width: 860px) {
  .auth-split {
    flex-direction: column;
  }
  .auth-stack {
    padding: 40px 16px 48px;
  }
  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }
}
