html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

/* Press-state pulse: every button briefly scales down on click so the user
   sees their tap landed even before the network responds. Disabled buttons
   skip the effect to avoid implying they accept input. */
.btn {
  transition: transform 80ms ease-out, background-color var(--motion-fast, 120ms) ease,
              border-color var(--motion-fast, 120ms) ease;
}
.btn:active:not(:disabled) {
  transform: scale(0.97);
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
  overflow-x: hidden; /* guard against off-screen elements forcing horizontal scroll on mobile */
}

/* Pre-auth pages (login, register, email verification, organization setup) share
   a centred narrow-card layout. Vertically centres the card so phones don't
   show a card pinned to the top with empty space below. */
.auth-shell {
  min-height: calc(100vh - 180px); /* discount header + footer + nav margins */
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 0;
}
.auth-card {
  width: 100%;
  max-width: 26rem;
}

/* Two-column auth layout: marketing panel on the left, form card on the right.
   Below 992px the panel hides and the form falls back to the centred card. */
.auth-split {
  min-height: calc(100vh - 180px);
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  gap: var(--space-8, 2rem);
  padding: 1.5rem 0;
}
@media (min-width: 992px) {
  .auth-split {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    gap: var(--space-10, 3rem);
  }
}
.auth-split .auth-card {
  margin: 0 auto;
  max-width: 28rem;
}

.auth-brand {
  display: none;
}
@media (min-width: 992px) {
  .auth-brand {
    display: block;
    background: linear-gradient(135deg, var(--color-primary-soft) 0%, var(--color-surface) 75%);
    border-radius: var(--radius-lg, 16px);
    padding: 2.5rem;
  }
}
.auth-brand__badge {
  display: inline-block;
  background: var(--color-primary);
  color: #fff;
  font-weight: 500;
  font-size: 0.85rem;
  padding: 6px 12px;
  border-radius: 999px;
  margin-bottom: 1.25rem;
}
.auth-brand__badge .bi { margin-right: 0.25rem; }
.auth-brand__title {
  font-weight: 700;
  letter-spacing: -0.02em;
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  line-height: 1.2;
  color: var(--color-text);
  margin-bottom: 0.75rem;
}
.auth-brand__lead {
  color: var(--color-text-muted);
  font-size: 1rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}
.auth-brand__features {
  margin-bottom: 1.75rem;
}
.auth-brand__features li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 0.875rem;
}
.auth-brand__features li:last-child { margin-bottom: 0; }
.auth-brand__icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: var(--color-primary-soft);
  color: var(--color-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  margin-top: 2px;
}

.auth-brand__art {
  background: var(--color-surface);
  border-radius: var(--radius-lg, 16px);
  box-shadow: var(--shadow-md, 0 4px 12px rgba(0, 0, 0, 0.08));
  padding: 1.25rem;
  margin-top: 1rem;
}
.auth-brand__mock {
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 1rem;
  background: var(--color-surface);
}
.auth-brand__line {
  background: var(--color-border);
  height: 8px;
  border-radius: 999px;
  margin-bottom: 8px;
}
.auth-brand__line:last-child { margin-bottom: 0; }
.auth-brand__line.short { width: 50%; }
.auth-brand__line.med { width: 75%; }
.auth-brand__pill {
  display: inline-block;
  background: var(--color-success-soft);
  color: var(--color-success);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
}
.auth-brand__pill .bi { margin-right: 0.25rem; }

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}
/* Terms of Service and Privacy Notice */
.legal { line-height: 1.6; }
.legal .legal-h { font-size: 1.05rem; font-weight: 600; margin: 1.75rem 0 0.5rem; }
.legal p, .legal li { margin-bottom: 0.5rem; }
.legal-meta { color: var(--bs-secondary-color); font-size: 0.875rem; }
.legal-pending {
  background: var(--bs-warning-bg-subtle);
  border: 1px solid var(--bs-warning-border-subtle);
  border-radius: 0.375rem;
  padding: 0.5rem 0.75rem;
  margin: 1rem 0;
}
.legal-tbc { font-style: italic; color: var(--bs-secondary-color); }
.legal-table { font-size: 0.875rem; }
.legal-table th { background: var(--bs-tertiary-bg); }
.legal-bm { margin-top: 3rem; padding-top: 2rem; border-top: 1px solid var(--bs-border-color); }
