
:root {
  --mds-bg: #f3f7f4;
  --mds-surface: #ffffff;
  --mds-primary: #668b79;
  --mds-primary-dark: #496b5a;
  --mds-primary-soft: #e7f0ea;
  --mds-text: #24332b;
  --mds-muted: #718078;
  --mds-border: #dce7df;
  --mds-danger: #b54747;
  --mds-shadow: 0 22px 60px rgba(38, 66, 49, .10);
}
* { box-sizing: border-box; }
html, body { min-height: 100%; }
body.auth-page {
  margin: 0;
  min-height: 100vh;
  padding: 28px 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(circle at 12% 8%, rgba(132,166,150,.18), transparent 32%),
    linear-gradient(145deg, #f7faf8 0%, var(--mds-bg) 100%);
  color: var(--mds-text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
}
.auth-topbar {
  width: min(100%, 480px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}
.auth-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--mds-text);
  text-decoration: none;
  font-weight: 750;
  letter-spacing: .02em;
}
.auth-brand-mark {
  width: 38px; height: 38px;
  display: grid; place-items: center;
  border-radius: 12px;
  background: var(--mds-primary-soft);
  color: var(--mds-primary-dark);
  font-size: 15px;
  font-weight: 800;
}
.auth-exit {
  color: var(--mds-primary-dark);
  text-decoration: none;
  font-size: .9rem;
  font-weight: 650;
  padding: 9px 13px;
  border: 1px solid var(--mds-border);
  border-radius: 10px;
  background: rgba(255,255,255,.72);
}
.auth-exit:hover { background: var(--mds-primary-soft); color: var(--mds-primary-dark); }
.auth-card {
  width: min(100%, 480px);
  padding: clamp(24px, 5vw, 40px);
  background: var(--mds-surface);
  border: 1px solid rgba(220,231,223,.9);
  border-radius: 22px;
  box-shadow: var(--mds-shadow);
}
.auth-eyebrow {
  margin: 0 0 8px;
  color: var(--mds-primary-dark);
  font-size: .76rem;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.auth-title { margin: 0; font-size: clamp(1.6rem, 4vw, 2rem); font-weight: 760; letter-spacing: -.035em; }
.auth-description { margin: 9px 0 26px; color: var(--mds-muted); line-height: 1.55; }
.auth-form .form-label { margin-bottom: 7px; color: #34463b; font-size: .9rem; font-weight: 650; }
.auth-form .form-control {
  min-height: 48px;
  padding: 11px 14px;
  border: 1px solid var(--mds-border);
  border-radius: 11px;
  color: var(--mds-text);
  background: #fbfdfb;
  box-shadow: none;
}
.auth-form .form-control:focus {
  border-color: var(--mds-primary);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(102,139,121,.13);
}
.auth-form .form-group, .auth-field { margin-bottom: 18px; }
.auth-submit {
  width: 100%;
  min-height: 49px;
  margin-top: 5px;
  border: 0;
  border-radius: 11px;
  background: var(--mds-primary);
  color: #fff;
  font-weight: 750;
  transition: background .15s ease, transform .15s ease;
}
.auth-submit:hover { background: var(--mds-primary-dark); color: #fff; transform: translateY(-1px); }
.auth-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 10px 16px;
  border: 1px solid var(--mds-border);
  border-radius: 11px;
  color: var(--mds-primary-dark);
  text-decoration: none;
  font-weight: 650;
}
.auth-secondary:hover { background: var(--mds-primary-soft); color: var(--mds-primary-dark); }
.auth-alert { border: 0; border-radius: 11px; font-size: .92rem; }
.auth-links { margin: 20px 0 0; text-align: center; color: var(--mds-muted); font-size: .9rem; }
.auth-links a { color: var(--mds-primary-dark); font-weight: 700; text-decoration: none; }
.auth-links a:hover { text-decoration: underline; }
.auth-footer { margin-top: 20px; color: var(--mds-muted); font-size: .8rem; text-align: center; }
.auth-logo { width: 46px; height: 46px; object-fit: contain; margin-bottom: 12px; }
@media (max-width: 520px) {
  body.auth-page { justify-content: flex-start; padding: 18px 14px; }
  .auth-topbar { margin-bottom: 14px; }
  .auth-card { border-radius: 17px; padding: 24px 20px; }
}
