/* ============================================================
   Droos — Auth-page additions
   Adds: provider buttons, "or" divider, form-row (checkbox + link),
   neutral wordmark variant, simulated-Google picker.
   All sizes/colours use the existing tokens in main.css; logical
   properties only so RTL/LTR both work without overrides.
============================================================ */

/* Neutral wordmark variant of .auth-card__brand — used while the
   real branding pass is pending (notes/branding-decision.md).
   Typography is doing all the work here: enlarged + bold + tighter
   leading so it anchors the card top instead of floating, then a
   reduced margin to the heading below so the two read as one block.
   Symmetric — holds in both AR-RTL and EN-LTR. */
.auth-card__brand--wordmark {
  justify-content: center;
  text-align: center;
  margin-block-start: var(--space-2);  /* settles into the card padding */
  margin-block-end:   var(--space-3);  /* tightens the gap to the heading */
}

.auth-card__brand--wordmark .auth-card__platform {
  font-size:      var(--font-size-4xl); /* 36px — anchors the card */
  font-weight:    var(--font-weight-bold);
  line-height:    var(--line-height-tight);
  letter-spacing: -0.01em;
  color:          var(--color-text-primary);
}

@media (min-width: 768px) {
  .auth-card__brand--wordmark .auth-card__platform {
    font-size: var(--font-size-5xl); /* 48px on tablet+ */
  }
}


/* ── Provider buttons (Google now; Microsoft etc. later) ───── */
.provider-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-block-end: var(--space-5);
}

.provider-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  inline-size: 100%;
  padding-block: var(--space-3);
  padding-inline: var(--space-4);
  background-color: var(--color-surface);
  color: var(--color-text-primary);
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-medium);
  text-decoration: none;
  cursor: pointer;
  transition:
    border-color var(--transition-fast),
    background-color var(--transition-fast),
    box-shadow var(--transition-fast);
}

.provider-btn:hover {
  border-color: var(--color-border-strong);
  background-color: var(--color-surface-alt);
}

.provider-btn:focus-visible {
  outline: none;
  border-color: var(--color-brand-black);
  box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.15);
}

.provider-btn__icon {
  flex-shrink: 0;
  inline-size: 18px;
  block-size: 18px;
}

.provider-btn__label {
  /* Keep "Google" / "Microsoft" Latin even in Arabic context */
  unicode-bidi: plaintext;
}


/* ── "or" divider between provider buttons and email form ─── */
.auth-or-divider {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-block: var(--space-5);
  color: var(--color-text-muted);
  font-size: var(--font-size-sm);
}

.auth-or-divider::before,
.auth-or-divider::after {
  content: '';
  flex: 1;
  block-size: 1px;
  background-color: var(--color-border);
}

.auth-or-divider span {
  text-transform: lowercase;
}


/* ── Inline row: "Remember me" checkbox + "Forgot password?" link ─ */
.form-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-block-end: var(--space-5);
}

.form-row--between {
  justify-content: space-between;
  flex-wrap: wrap;
}

.form-checkbox {
  display: inline-flex;
  align-items: center;
  /* space-3 (12px) — bumped from space-2 because RTL was reading as
     a collision between the input and the first Arabic glyph
     ("تذكَّرني"). Symmetric change via `gap`, no physical margins
     anywhere, so LTR (already correct) just gets a hair more room. */
  gap: var(--space-3);
  font-size: var(--font-size-sm);
  color: var(--color-text-secondary);
  cursor: pointer;
}

.form-checkbox input[type='checkbox'] {
  inline-size: 16px;
  block-size: 16px;
  /* flex-shrink: 0 keeps the native checkbox at its intrinsic size
     in narrow rows; without it, some UAs let the input collapse a
     fraction and the label visually overruns it in RTL. */
  flex-shrink: 0;
  accent-color: var(--color-brand-black);
  margin: 0;
}

.form-inline-link {
  font-size: var(--font-size-sm);
  color: var(--color-text-primary);
  text-decoration: underline;
  font-weight: var(--font-weight-medium);
}


/* ── Language toggle in the site header ─────────────────────── */
.site-header__lang-toggle {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding-block: var(--space-2);
  padding-inline: var(--space-3);
  border-radius: var(--radius-md);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-medium);
  color: var(--color-text-secondary);
  text-decoration: none;
  transition: background-color var(--transition-fast), color var(--transition-fast);
}

.site-header__lang-toggle:hover {
  background-color: var(--color-surface-sunken);
  color: var(--color-text-primary);
}

.site-header__lang-toggle:focus-visible {
  outline: 2px solid var(--color-brand-black);
  outline-offset: 2px;
}

@media (max-width: 480px) {
  .site-header__lang-toggle span { display: none; }
}


/* ── Simulated-Google picker (DEV ONLY screen) ─────────────── */
.sim-account-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-block-end: var(--space-4);
}

.sim-account {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-3);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background-color: var(--color-surface);
}

.sim-account__info {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-inline-size: 0;
}

.sim-account__avatar {
  flex-shrink: 0;
  inline-size: 36px;
  block-size: 36px;
  border-radius: var(--radius-full);
  background-color: var(--color-surface-sunken);
  color: var(--color-text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: var(--font-weight-semibold);
}

.sim-account__name {
  font-weight: var(--font-weight-medium);
  color: var(--color-text-primary);
  font-size: var(--font-size-sm);
}

.sim-account__email {
  font-size: var(--font-size-xs);
  color: var(--color-text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
