@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@500;600;700;800&display=swap');

:root {
  color-scheme: light;
  --navy: #18365e;
  --ink: #10243f;
  --muted: #7184a0;
  --line: #dce5f2;
  --blue: #528fe5;
  --mint: #48d5a4;
  --surface: #ffffff;
  --page: #f4f7fc;
}

* { box-sizing: border-box; }
body.auth-page {
  min-height: 100vh;
  margin: 0;
  padding: 32px 18px;
  display: grid;
  place-items: center;
  color: var(--ink);
  background: radial-gradient(circle at 50% 15%, #fff 0, #f6f8fc 37%, #edf3fb 100%);
  font-family: "DM Sans", Arial, sans-serif;
}
.auth-shell { width: min(100%, 460px); text-align: center; }
.auth-brand {
  display: inline-block;
  margin: 0 0 22px;
  color: #536984;
  font: 800 13px/1.2 "Manrope", Arial, sans-serif;
  letter-spacing: .17em;
  text-decoration: none;
}
.auth-card {
  padding: 36px 40px 30px;
  border: 1px solid rgba(217, 228, 242, .9);
  border-radius: 26px;
  background: var(--surface);
  box-shadow: 0 22px 64px rgba(25, 54, 94, .11);
  text-align: left;
}
.auth-mark {
  width: 52px; height: 52px;
  display: grid; place-items: center;
  margin: 0 auto 17px;
  border-radius: 17px;
  color: #12543f;
  background: linear-gradient(145deg, #a5f1d3, #47d3a3);
  font-size: 25px;
}
.auth-eyebrow {
  margin: 0 0 9px;
  color: #6f83a0;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .16em;
  text-align: center;
}
.auth-card h1 {
  margin: 0;
  color: var(--ink);
  font: 800 clamp(27px, 7vw, 34px)/1.16 "Manrope", Arial, sans-serif;
  letter-spacing: -.04em;
  text-align: center;
}
.auth-subtitle {
  margin: 11px 0 27px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.5;
  text-align: center;
}
.auth-form { display: flex; flex-direction: column; align-items: stretch; }
.auth-form label {
  margin: 0 0 7px;
  color: #2b4261;
  font-size: 13px;
  font-weight: 700;
}
.auth-form input {
  width: 100%;
  min-height: 48px;
  margin: 0 0 17px;
  padding: 12px 14px;
  border: 1px solid #d6e0ed;
  border-radius: 12px;
  outline: none;
  background: #fbfcfe;
  color: var(--ink);
  font: inherit;
  transition: border-color .15s, box-shadow .15s, background .15s;
}
.auth-form input:focus {
  border-color: #69a0eb;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(82, 143, 229, .15);
}
.auth-form input:invalid:not(:placeholder-shown) { border-color: #e59b9b; }
.field-hint { margin: -11px 0 15px; color: var(--muted); font-size: 11px; line-height: 1.4; }
.primary-button, .secondary-button, .logout, .refresh {
  min-height: 47px;
  border: 0;
  border-radius: 13px;
  font: 700 14px "DM Sans", Arial, sans-serif;
  cursor: pointer;
  transition: transform .15s, filter .15s, box-shadow .15s;
}
.primary-button {
  margin-top: 3px;
  color: #fff;
  background: linear-gradient(100deg, #356db3, #24558d);
  box-shadow: 0 9px 18px rgba(31, 80, 137, .18);
}
.primary-button:hover, .secondary-button:hover { filter: brightness(1.04); transform: translateY(-1px); }
.primary-button:disabled { opacity: .62; cursor: wait; transform: none; }
.secondary-button {
  width: 100%;
  color: #214c7c;
  border: 1px solid #d7e3f2;
  background: #f7faff;
}
.text-button {
  align-self: center;
  margin: 12px 0 0;
  padding: 5px 8px;
  border: 0;
  color: #376ca7;
  background: transparent;
  font: 600 13px "DM Sans", Arial, sans-serif;
  cursor: pointer;
}
.text-button:hover { color: #1f4c7e; text-decoration: underline; }
.auth-divider { display: flex; align-items: center; gap: 12px; margin: 25px 0 17px; color: #92a1b5; font-size: 10px; font-weight: 800; letter-spacing: .14em; }
.auth-divider span:first-child, .auth-divider span:last-child { height: 1px; flex: 1; background: #e7edf5; }
.auth-message { min-height: 21px; margin: 15px 0 0; color: #325d8e; font-size: 13px; line-height: 1.45; text-align: center; }
.auth-message.error { color: #a83a3a; }
.auth-message.success { color: #187456; }
.form-intro { margin: 0 0 17px; color: var(--muted); font-size: 13px; line-height: 1.5; }
.auth-footer { margin: 20px 0 0; color: #778ba7; font-size: 13px; }
.hidden { display: none !important; }

@media (max-width: 520px) {
  body.auth-page { padding: 22px 12px; }
  .auth-card { padding: 30px 22px 24px; border-radius: 22px; }
}
