/* ─── User Accounts (auth pages) ─── */

.auth-wrap {
  min-height: calc(100vh - 64px);
  background: #EDE8DC;
  padding: 48px 16px;
}

.auth-card {
  background: #fff;
  border-radius: 16px;
  padding: 32px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.08);
  max-width: 460px;
  margin: 0 auto;
}

@media (max-width: 480px) {
  .auth-wrap { padding: 24px 12px; }
  .auth-card { padding: 24px 20px; border-radius: 14px; }
}

.auth-card h1 {
  font-size: 24px;
  font-weight: 800;
  color: #1A1A1A;
  margin-bottom: 6px;
  letter-spacing: -0.01em;
}

.auth-card .auth-subtitle {
  color: #6B7280;
  font-size: 14px;
  margin-bottom: 24px;
}

.oauth-btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  background: #fff;
  border: 1.5px solid #E5E7EB;
  border-radius: 12px;
  padding: 13px 20px;
  font-weight: 600;
  font-size: 15px;
  color: #1A1A1A;
  cursor: pointer;
  transition: all 0.15s;
  text-decoration: none;
}
.oauth-btn-google:hover {
  border-color: #0A5C4A;
  background: #FAFAFA;
}
.oauth-btn-google[disabled],
.oauth-btn-google.disabled {
  opacity: 0.55;
  cursor: not-allowed;
}
.oauth-btn-google svg { flex-shrink: 0; }

/* Continuer avec Online Africa — the SSO button. Carries the brand green rather than
   the neutral treatment of the third-party providers: this is our own account, not
   somebody else's identity service, and it should read as the primary way in. */
.oauth-btn-oa {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  background: var(--green-primary);
  border: 1.5px solid var(--green-primary);
  border-radius: 12px;
  padding: 13px 20px;
  font-weight: 600;
  font-size: 15px;
  color: #fff;
  cursor: pointer;
  transition: all 0.15s;
  text-decoration: none;
}
.oauth-btn-oa:hover {
  background: var(--green-dark);
  border-color: var(--green-dark);
}
.oauth-btn-oa img { flex-shrink: 0; border-radius: 4px; }

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #9CA3AF;
  font-size: 12px;
  margin: 20px 0;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
}
.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #E5E7EB;
}

.auth-input {
  width: 100%;
  border: 1.5px solid #E5E7EB;
  border-radius: 12px;
  padding: 12px 16px;
  font-size: 15px;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
  background: #fff;
  color: #111827;
  font-family: inherit;
}
.auth-input:focus {
  border-color: #0A5C4A;
  box-shadow: 0 0 0 3px rgba(10,92,74,0.1);
}
.auth-input::placeholder { color: #9CA3AF; }

.auth-label {
  font-size: 13px;
  font-weight: 600;
  color: #374151;
  margin-bottom: 6px;
  display: block;
}

.auth-field { margin-bottom: 14px; }
.auth-field-row {
  display: flex;
  gap: 8px;
}

.auth-link {
  color: #0A5C4A;
  font-weight: 600;
  text-decoration: none;
}
.auth-link:hover { text-decoration: underline; }

.auth-error {
  background: #FEF2F2;
  border: 1px solid #FECACA;
  color: #B91C1C;
  font-size: 13px;
  padding: 10px 14px;
  border-radius: 10px;
  margin-bottom: 14px;
}
.auth-success {
  background: #F0FDF4;
  border: 1px solid #BBF7D0;
  color: #15803D;
  font-size: 13px;
  padding: 10px 14px;
  border-radius: 10px;
  margin-bottom: 14px;
}
.auth-info {
  background: #F3F4F6;
  color: #374151;
  font-size: 13px;
  padding: 10px 14px;
  border-radius: 10px;
  margin-bottom: 14px;
}

.auth-submit {
  width: 100%;
  background: #F7941D;
  color: #fff;
  font-weight: 700;
  font-size: 15px;
  border: none;
  cursor: pointer;
  border-radius: 12px;
  padding: 13px 24px;
  transition: all 0.2s;
  box-shadow: 0 4px 14px rgba(247,148,29,0.35);
  margin-top: 4px;
}
.auth-submit:hover:not(:disabled) {
  background: #E07F0A;
  transform: translateY(-1px);
}
.auth-submit:disabled {
  background: #D1D5DB;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

.auth-footer-link {
  margin-top: 18px;
  text-align: center;
  font-size: 14px;
  color: #6B7280;
}

.auth-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #4B5563;
  cursor: pointer;
  user-select: none;
}
.auth-checkbox input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: #0A5C4A;
  cursor: pointer;
}

/* ── Profile / dashboard ── */
.account-shell {
  max-width: 960px;
  margin: 0 auto;
  padding: 32px 16px 64px;
}

.account-header {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 28px;
}
.account-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #0A5C4A;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 26px;
  overflow: hidden;
  flex-shrink: 0;
}
.account-avatar img { width: 100%; height: 100%; object-fit: cover; }
.account-header h1 {
  font-size: 22px;
  font-weight: 800;
  color: #1A1A1A;
  margin: 0;
  letter-spacing: -0.01em;
}
.account-header p {
  color: #6B7280;
  font-size: 14px;
  margin: 2px 0 0;
}
/* ─── Account hero — single row: identity left, phone right ─── */
.account-hero-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}
.account-identity {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
  flex: 1;
}
.account-hero-text { min-width: 0; }
.account-hero-text h1 {
  font-size: 22px;
  font-weight: 800;
  color: #1A1A1A;
  margin: 0;
  letter-spacing: -0.01em;
  line-height: 1.15;
}
.account-email {
  color: #6B7280;
  font-size: 13px;
  margin: 4px 0 0;
  display: flex;
  align-items: center;
  letter-spacing: -0.005em;
}

/* Compact phone block sitting at the right edge of the hero row */
.account-phone-compact {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: #fff;
  border: 1px solid #E5E7EB;
  border-radius: 12px;
  padding: 10px 14px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  transition: all 0.18s;
}
.account-phone-compact:hover {
  border-color: #0A5C4A;
  box-shadow: 0 4px 16px rgba(10, 92, 74, 0.1);
}
.account-phone-flag {
  width: 2em !important;
  height: 1.5em !important;
  border-radius: 3px;
  flex-shrink: 0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}
.account-phone-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.account-phone-number {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 15px;
  color: #0A5C4A;
  letter-spacing: 0.01em;
  line-height: 1.15;
}
.account-phone-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.account-phone-country-name {
  font-size: 11px;
  color: #6B7280;
  font-weight: 500;
}
.account-phone-compact .carrier-badge { font-size: 10px; padding: 2px 8px; }

@media (max-width: 720px) {
  .account-hero-row {
    align-items: flex-start;
  }
  .account-phone-compact {
    width: 100%;
  }
}

/* Carrier logo chip — small white pill containing the operator's logo image */
.carrier-logo-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border: 1px solid #E5E7EB;
  border-radius: 6px;
  padding: 3px 8px;
  height: 24px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}
.carrier-logo-chip img {
  height: 16px;
  width: auto;
  display: block;
}

@media (max-width: 640px) {
  .account-phone-card { width: 100%; }
}

.account-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 28px;
}
@media (max-width: 600px) {
  .account-stats { grid-template-columns: 1fr; }
}
.stat-card {
  background: #fff;
  border-radius: 14px;
  padding: 18px 20px;
  box-shadow: 0 4px 18px rgba(0,0,0,0.05);
}
.stat-card .stat-label {
  font-size: 12px;
  color: #6B7280;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 6px;
}
.stat-card .stat-value {
  font-size: 22px;
  font-weight: 800;
  color: #0A5C4A;
}

.account-section {
  background: #fff;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 4px 18px rgba(0,0,0,0.05);
  margin-bottom: 18px;
}
.account-section h2 {
  font-size: 16px;
  font-weight: 700;
  color: #1A1A1A;
  margin: 0 0 14px;
}

.method-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #E8F5F1;
  color: #0A5C4A;
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 9999px;
  margin-right: 6px;
}
.method-badge.muted {
  background: #F3F4F6;
  color: #6B7280;
}

.quick-link-row {
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: #F3F4F6;
  border-radius: 12px;
  overflow: hidden;
}
.quick-link-row a {
  background: #fff;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #1F2937;
  font-weight: 500;
  font-size: 14px;
  text-decoration: none;
  transition: background 0.12s;
}
.quick-link-row a:hover { background: #F9FAFB; }
.quick-link-row a.danger { color: #B91C1C; }

.user-menu-wrap { position: relative; }
.user-menu-trigger {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.18);
  color: #fff;
  padding: 6px 10px 6px 6px;
  border-radius: 9999px;
  cursor: pointer;
  font-weight: 500;
  font-size: 13px;
  transition: background 0.15s, border-color 0.15s;
}
.user-menu-trigger:hover {
  background: rgba(255,255,255,0.14);
  border-color: rgba(255,255,255,0.35);
}
.user-menu-trigger .menu-avatar {
  width: 26px; height: 26px; border-radius: 50%;
  background: rgba(255,255,255,0.2);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 12px;
  overflow: hidden;
}
.user-menu-trigger .menu-avatar img { width: 100%; height: 100%; object-fit: cover; }
.user-menu-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  width: 220px;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 12px 36px rgba(0,0,0,0.18);
  padding: 6px;
  z-index: 60;
}
.user-menu-panel a {
  display: block;
  padding: 10px 14px;
  color: #1F2937;
  font-size: 14px;
  border-radius: 10px;
  text-decoration: none;
}
.user-menu-panel a:hover { background: #F3F4F6; }
.user-menu-panel a.danger { color: #B91C1C; }
.user-menu-panel hr {
  border: none;
  border-top: 1px solid #F3F4F6;
  margin: 4px 6px;
}


/* ──────────────────────────────────────────────────────────
   Simple (Ding-style) auth layout — used by /account/login
   ────────────────────────────────────────────────────────── */

.auth-simple-wrap {
  min-height: calc(100vh - 64px);
  background: #EDE8DC;
  padding: 48px 16px;
  display: flex;
  justify-content: center;
  align-items: flex-start;
}
.auth-simple-card {
  background: #fff;
  border-radius: 24px;
  padding: 40px 32px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
  max-width: 440px;
  width: 100%;
}
.auth-simple-title {
  font-size: 24px;
  font-weight: 800;
  color: #0A5C4A;
  text-align: center;
  margin-bottom: 8px;
}
.auth-simple-subtitle {
  font-size: 14px;
  color: #6B7280;
  text-align: center;
}
.auth-simple-field {
  margin-bottom: 18px;
}
.auth-simple-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: #374151;
  margin-bottom: 8px;
  letter-spacing: 0.01em;
}

/* Phone pill */
.auth-phone-pill {
  display: flex;
  align-items: center;
  border: 1.5px solid #E5E7EB;
  border-radius: 9999px;
  background: #fff;
  padding: 6px 8px 6px 16px;
  transition: all 0.18s;
  gap: 10px;
}
.auth-phone-pill:focus-within,
.auth-phone-pill.focused {
  border-color: #0A5C4A;
  box-shadow: 0 0 0 3px rgba(10, 92, 74, 0.1);
}
.auth-phone-flag {
  display: flex;
  align-items: center;
  gap: 4px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 4px 2px 4px 0;
}
.auth-phone-flag .fi {
  width: 1.8em;
  height: 1.3em;
}
.auth-phone-pill .auth-phone-dial {
  color: #6B7280;
  font-family: 'JetBrains Mono', monospace;
  font-size: 15px;
  font-weight: 500;
  padding-right: 4px;
  border-right: 1px solid #E5E7EB;
  padding-right: 12px;
}
.auth-phone-pill input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 15px;
  padding: 12px 8px;
  background: transparent;
  font-family: inherit;
  color: #1A1A1A;
}
.auth-phone-pill input::placeholder { color: #9CA3AF; }

/* Password / generic pill input */
.auth-pill-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
  border: 1.5px solid #E5E7EB;
  border-radius: 9999px;
  background: #fff;
  transition: all 0.18s;
}
.auth-pill-input-wrap:focus-within {
  border-color: #0A5C4A;
  box-shadow: 0 0 0 3px rgba(10, 92, 74, 0.1);
}
.auth-pill-input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-size: 15px;
  padding: 14px 18px;
  font-family: inherit;
  color: #1A1A1A;
}
.auth-pill-input::placeholder { color: #9CA3AF; }
.auth-pwd-toggle {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 8px 16px;
  color: #9CA3AF;
  display: flex;
  align-items: center;
}
.auth-pwd-toggle:hover { color: #6B7280; }

/* Forgot password small link */
.auth-forgot-link {
  font-size: 13px;
  color: #0A5C4A;
  font-weight: 600;
  text-decoration: none;
}
.auth-forgot-link:hover { text-decoration: underline; }

/* Pill CTA */
.auth-pill-btn {
  width: 100%;
  background: #F7941D;
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  border: none;
  border-radius: 9999px;
  padding: 16px 24px;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 4px 14px rgba(247, 148, 29, 0.35);
  margin-top: 8px;
  letter-spacing: 0.01em;
}
.auth-pill-btn:hover:not(:disabled) {
  background: #E07F0A;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(247, 148, 29, 0.45);
}
.auth-pill-btn:disabled {
  background: #D1D5DB;
  box-shadow: none;
  transform: none;
  cursor: not-allowed;
}

/* Divider */
.auth-simple-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #9CA3AF;
  font-size: 13px;
  margin: 28px 0 20px;
}
.auth-simple-divider::before,
.auth-simple-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #E5E7EB;
}

/* Social circles */
.auth-social-circles {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-bottom: 8px;
}
.auth-social-circle {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #fff;
  border: 1.5px solid #E5E7EB;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.18s;
  text-decoration: none;
}
.auth-social-circle:hover {
  border-color: #0A5C4A;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}
.auth-social-circle.disabled {
  cursor: not-allowed;
  background: #F9FAFB;
}
.auth-social-circle.disabled:hover {
  border-color: #E5E7EB;
  transform: none;
  box-shadow: none;
}
.auth-social-labels {
  display: flex;
  justify-content: center;
  gap: 24px;
}
.auth-social-labels span {
  font-size: 12px;
  color: #6B7280;
  font-weight: 500;
  width: 52px;
  text-align: center;
}

/* Footer link */
.auth-simple-footer {
  text-align: center;
  font-size: 14px;
  color: #6B7280;
  margin-top: 28px;
}
.auth-simple-link {
  color: #0A5C4A;
  font-weight: 700;
  text-decoration: none;
}
.auth-simple-link:hover { text-decoration: underline; }

/* Terms */
.auth-simple-terms {
  text-align: center;
  font-size: 12px;
  color: #9CA3AF;
  margin-top: 20px;
  line-height: 1.5;
}
.auth-simple-link-soft {
  color: #6B7280;
  text-decoration: underline;
}
.auth-simple-link-soft:hover { color: #0A5C4A; }

/* Spinner */
.spin { animation: spin 0.9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Country dropdown z-index when used in auth */
.auth-simple-card .country-dropdown {
  z-index: 100;
}

/* Inline "(optionnel)" label hint */
.auth-optional {
  color: #9CA3AF;
  font-weight: 400;
  font-size: 11px;
  margin-left: 4px;
}
