/* ── Auth pages ─────────────────────────────────────────────────────────────── */

.at-auth-wrap {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px 20px;
  padding-top: calc(24px + var(--at-safe-top));
  padding-bottom: calc(24px + var(--at-safe-bottom));
  background: var(--at-surface-app);
}

.at-auth-logo {
  text-align: center;
  margin-bottom: 28px;
}

.at-auth-logo svg {
  margin: 0 auto 12px;
}

.at-auth-brand {
  font-size: 22px;
  font-weight: var(--at-weight-medium);
  color: var(--at-text-primary);
}

.at-auth-tagline {
  font-size: 13px;
  color: var(--at-text-muted);
  margin-top: 4px;
}

.at-auth-card {
  width: 100%;
  max-width: 400px;
  background: var(--at-surface-card);
  border-radius: var(--at-radius-xl);
  border: 0.5px solid var(--at-border);
  padding: 24px 20px;
}

.at-form-group {
  margin-bottom: 16px;
}

.at-auth-error {
  background: var(--at-coral-50);
  color: var(--at-coral-800);
  border-radius: var(--at-radius-md);
  padding: 10px 14px;
  font-size: 13px;
  margin-bottom: 16px;
  line-height: 1.5;
}

.at-auth-success {
  background: var(--at-teal-50);
  color: var(--at-teal-800);
  border-radius: var(--at-radius-md);
  padding: 10px 14px;
  font-size: 13px;
  margin-bottom: 16px;
  line-height: 1.5;
}

.at-auth-hint {
  font-size: 13px;
  color: var(--at-text-muted);
  text-align: center;
  line-height: 1.5;
}

.at-auth-link {
  color: var(--at-color-brand);
  text-decoration: none;
  font-weight: var(--at-weight-medium);
}

.at-auth-link:hover {
  text-decoration: underline;
}

.at-auth-footer {
  font-size: 13px;
  color: var(--at-text-muted);
  text-align: center;
  margin-top: 20px;
}

/* ── Settings pages ─────────────────────────────────────────────────────────── */

.at-settings-section {
  padding: 0 var(--at-space-4);
  margin-bottom: var(--at-space-4);
}

.at-settings-section-title {
  font-size: var(--at-text-xs);
  font-weight: var(--at-weight-medium);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--at-text-muted);
  padding: var(--at-space-4) 0 var(--at-space-2);
}

.at-settings-card {
  background: var(--at-surface-card);
  border-radius: var(--at-radius-lg);
  border: 0.5px solid var(--at-border);
  overflow: hidden;
}

.at-plan-banner {
  background: var(--at-brand-50);
  border: 1.5px solid var(--at-color-brand);
  border-radius: var(--at-radius-lg);
  padding: var(--at-space-4);
  margin: 0 var(--at-space-4) var(--at-space-4);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--at-space-3);
}

.at-plan-banner-text {
  flex: 1;
}

.at-plan-name {
  font-size: var(--at-text-base);
  font-weight: var(--at-weight-medium);
  color: var(--at-brand-800);
}

.at-plan-desc {
  font-size: var(--at-text-xs);
  color: var(--at-brand-700);
  margin-top: 2px;
}

/* ── Upgrade / billing page ────────────────────────────────────────────────── */

.at-upgrade-wrap {
  padding: var(--at-space-4);
}

.at-plan-card {
  background: var(--at-surface-card);
  border-radius: var(--at-radius-xl);
  border: 1.5px solid var(--at-border);
  padding: var(--at-space-6) var(--at-space-5);
  margin-bottom: var(--at-space-3);
}

.at-plan-card.featured {
  border-color: var(--at-color-brand);
}

.at-plan-card-badge {
  background: var(--at-brand-50);
  color: var(--at-brand-800);
  border-radius: var(--at-radius-full);
  padding: 3px 10px;
  font-size: 11px;
  font-weight: var(--at-weight-medium);
  display: inline-block;
  margin-bottom: var(--at-space-2);
}

.at-plan-card-name {
  font-size: var(--at-text-xl);
  font-weight: var(--at-weight-medium);
  color: var(--at-text-primary);
  margin-bottom: var(--at-space-1);
}

.at-plan-card-price {
  font-size: var(--at-text-2xl);
  font-weight: var(--at-weight-medium);
  color: var(--at-color-brand);
  margin-bottom: var(--at-space-4);
}

.at-plan-card-price span {
  font-size: var(--at-text-sm);
  font-weight: var(--at-weight-regular);
  color: var(--at-text-muted);
}

.at-plan-feature {
  display: flex;
  align-items: center;
  gap: var(--at-space-2);
  font-size: var(--at-text-sm);
  color: var(--at-text-primary);
  margin-bottom: var(--at-space-2);
}

.at-plan-feature-check {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--at-teal-50);
  border: 1.5px solid var(--at-teal-600);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ── Member list ────────────────────────────────────────────────────────────── */

.at-member-row {
  display: flex;
  align-items: center;
  gap: var(--at-space-3);
  padding: var(--at-space-3) var(--at-space-4);
  border-bottom: 0.5px solid var(--at-border);
}

.at-member-row:last-child { border-bottom: none; }

.at-member-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--at-brand-50);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: var(--at-weight-medium);
  color: var(--at-brand-800);
  flex-shrink: 0;
}

.at-member-name  { font-size: 14px; font-weight: var(--at-weight-medium); color: var(--at-text-primary); }
.at-member-email { font-size: 12px; color: var(--at-text-muted); }

.at-role-badge {
  border-radius: var(--at-radius-full);
  padding: 2px 8px;
  font-size: 11px;
  font-weight: var(--at-weight-medium);
  margin-left: auto;
  flex-shrink: 0;
}

.at-role-owner  { background: var(--at-brand-50);  color: var(--at-brand-800); }
.at-role-admin  { background: var(--at-blue-50);   color: var(--at-blue-800); }
.at-role-member { background: var(--at-gray-100);  color: var(--at-gray-700); }
.at-role-partner{ background: var(--at-teal-50);   color: var(--at-teal-800); }
