/* StanMowing - shared auth page styles. Mirrors index.html palette. */

:root {
  --green:       #4a7c2f;
  --green-dark:  #355c20;
  --green-light: #629940;
  --green-pale:  #f0f7ea;
  --green-mid:   #ddeecf;
  --bg:          #faf9f7;
  --bg2:         #f3f2ef;
  --text:        #1a1a18;
  --muted:       #5a5a54;
  --faint:       #9a9a90;
  --border:      #e4e2dc;
  --danger:      #b53d3d;
  --radius:      10px;
  --font:        ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--green); text-decoration: none; }
a:hover { text-decoration: underline; }

.auth-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
  gap: 1.25rem;
}

.auth-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--green-dark);
  letter-spacing: -0.02em;
}
.auth-logo i { color: var(--green); width: 22px; height: 22px; }
.auth-logo .logo-text > span { color: var(--green-light); }

.auth-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem 1.75rem;
  width: 100%;
  max-width: 420px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.03), 0 8px 24px rgba(0,0,0,0.05);
}

.auth-card--success {
  text-align: center;
}

.auth-title {
  margin: 0 0 0.4rem;
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.auth-sub {
  margin: 0 0 1.25rem;
  color: var(--muted);
  font-size: 0.95rem;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-top: 0.5rem;
}

.auth-form label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
}

.auth-form input[type="email"] {
  font-family: var(--font);
  font-size: 1rem;
  padding: 0.7rem 0.9rem;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  background: white;
  color: var(--text);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.auth-form input[type="email"]:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(74,124,47,0.15);
}
.auth-form input[aria-invalid="true"] {
  border-color: var(--danger);
}

.btn-primary, .btn-passkey {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  font-family: var(--font);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s, box-shadow 0.15s;
  margin-top: 0.5rem;
}
.btn-primary {
  background: var(--green);
  color: white;
}
.btn-primary:hover { background: var(--green-dark); transform: translateY(-1px); }
.btn-primary:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

.btn-passkey {
  background: white;
  color: var(--green-dark);
  border: 1.5px solid var(--green);
}
.btn-passkey:hover {
  background: var(--green-pale);
  transform: translateY(-1px);
}
.btn-passkey:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

.btn-link {
  display: inline-block;
  margin-top: 0.75rem;
  font-size: 0.9rem;
  color: var(--muted);
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 1rem 0;
  color: var(--faint);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.auth-divider::before, .auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

.auth-status {
  margin: 0.75rem 0 0;
  font-size: 0.875rem;
  min-height: 1.4rem;
  color: var(--muted);
}
.auth-status.is-error { color: var(--danger); }
.auth-status.is-ok { color: var(--green-dark); }

.auth-fineprint {
  margin-top: 1rem;
  font-size: 0.78rem;
  color: var(--faint);
  line-height: 1.5;
}

.auth-bullets {
  list-style: none;
  padding: 0;
  margin: 0 0 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  font-size: 0.92rem;
  color: var(--muted);
}
.auth-bullets li {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}
.auth-bullets i {
  color: var(--green);
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.auth-footer {
  margin-top: 0.5rem;
  font-size: 0.85rem;
  color: var(--faint);
}

.success-icon, .cancel-icon {
  display: inline-flex;
  margin: 0 auto 1rem;
  width: 48px;
  height: 48px;
  align-items: center;
  justify-content: center;
}
.success-icon i { width: 48px; height: 48px; color: var(--green); }
.cancel-icon i { width: 48px; height: 48px; color: var(--faint); }

@media (max-width: 480px) {
  .auth-card { padding: 1.5rem 1.25rem; }
  .auth-title { font-size: 1.3rem; }
}
