/* ══════════════════════════════════════
   SKILLLINK AUTH — auth.css
   Include this on every page
══════════════════════════════════════ */

/* ── MODAL OVERLAY ── */
.sl-modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 500;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  backdrop-filter: blur(4px);
  opacity: 0; pointer-events: none;
  transition: opacity .25s ease;
}
.sl-modal-overlay.open {
  opacity: 1; pointer-events: all;
}
.sl-modal {
  background: #fff;
  border-radius: 20px;
  width: 100%; max-width: 440px;
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(0,0,0,.18);
  transform: translateY(16px);
  transition: transform .25s ease;
}
.sl-modal-overlay.open .sl-modal {
  transform: translateY(0);
}

/* ── MODAL HEADER ── */
.sl-modal-header {
  padding: 24px 24px 0;
  display: flex; justify-content: space-between; align-items: flex-start;
}
.sl-modal-header-text h2 {
  font-family: 'Sora', sans-serif;
  font-size: 22px; font-weight: 800;
  color: #111827; margin-bottom: 4px;
}
.sl-modal-header-text p {
  font-size: 14px; color: #6b7280;
}
.sl-modal-close {
  background: #f3f4f6; border: none;
  width: 32px; height: 32px; border-radius: 50%;
  cursor: pointer; font-size: 18px; color: #6b7280;
  display: flex; align-items: center; justify-content: center;
  transition: .2s; flex-shrink: 0;
}
.sl-modal-close:hover { background: #e5e7eb; color: #111827; }

/* ── MODAL BODY ── */
.sl-modal-body { padding: 24px; }
.sl-form-group { margin-bottom: 16px; }
.sl-form-label {
  display: block; font-size: 13px; font-weight: 600;
  color: #374151; margin-bottom: 6px;
}
.sl-form-input {
  width: 100%; padding: 12px 14px;
  border: 1.5px solid #e5e7eb; border-radius: 10px;
  font-size: 15px; font-family: 'DM Sans', sans-serif;
  color: #111827; outline: none; transition: .2s;
  background: #fff;
}
.sl-form-input:focus { border-color: #047857; }
.sl-form-row { display: flex; gap: 8px; }
.sl-country-btn {
  flex: 1; padding: 12px 8px; border: 1.5px solid #e5e7eb;
  border-radius: 10px; font-size: 14px; font-weight: 600;
  cursor: pointer; background: #fff; color: #374151;
  font-family: 'DM Sans', sans-serif; transition: .2s;
  text-align: center;
}
.sl-country-btn.active {
  border-color: #047857; background: #ecfdf5; color: #047857;
}
.sl-mode-row { display: flex; gap: 8px; margin-bottom: 4px; }
.sl-mode-btn {
  flex: 1; padding: 14px 12px; border: 1.5px solid #e5e7eb;
  border-radius: 10px; font-size: 14px; font-weight: 600;
  cursor: pointer; background: #fff; color: #6b7280;
  font-family: 'DM Sans', sans-serif; transition: .2s;
  text-align: center; display: flex; flex-direction: column;
  align-items: center; gap: 6px;
}
.sl-mode-btn .mode-icon { font-size: 24px; }
.sl-mode-btn.active {
  border-color: #047857; background: #ecfdf5; color: #047857;
}
.sl-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.sl-pill {
  padding: 7px 14px; border: 1.5px solid #e5e7eb;
  border-radius: 20px; font-size: 13px; font-weight: 500;
  cursor: pointer; background: #fff; color: #6b7280;
  font-family: 'DM Sans', sans-serif; transition: .2s;
}
.sl-pill.active {
  border-color: #047857; background: #ecfdf5;
  color: #047857; font-weight: 600;
}

/* ── MODAL FOOTER ── */
.sl-modal-footer { padding: 0 24px 24px; }
.sl-submit-btn {
  width: 100%; padding: 14px;
  background: #047857; color: #fff;
  border: none; border-radius: 12px;
  font-size: 16px; font-weight: 700;
  font-family: 'DM Sans', sans-serif;
  cursor: pointer; transition: .2s;
  display: flex; align-items: center; justify-content: center; gap: 8px;
}
.sl-submit-btn:hover { background: #064e3b; }
.sl-submit-btn:disabled { opacity: .6; cursor: not-allowed; }
.sl-switch-text {
  text-align: center; margin-top: 14px;
  font-size: 14px; color: #6b7280;
}
.sl-switch-text a {
  color: #047857; font-weight: 600;
  cursor: pointer; text-decoration: none;
}
.sl-switch-text a:hover { text-decoration: underline; }
.sl-divider {
  border: none; border-top: 1px solid #e5e7eb;
  margin: 0 24px 20px;
}

/* ── SPINNER ── */
.sl-spinner {
  width: 18px; height: 18px;
  border: 2px solid rgba(255,255,255,.35);
  border-top-color: #fff; border-radius: 50%;
  animation: sl-spin .7s linear infinite;
  display: inline-block;
}
@keyframes sl-spin { to { transform: rotate(360deg); } }

/* ── NAV USER AREA ── */
.nav-user-area {
  display: flex; align-items: center; gap: 10px;
  cursor: pointer; position: relative;
}
.nav-avatar {
  width: 36px; height: 36px; border-radius: 50%;
  background: #d1fae5;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Sora', sans-serif; font-size: 14px;
  font-weight: 700; color: #047857;
  border: 2px solid #047857;
}
.nav-user-name {
  font-size: 14px; font-weight: 600; color: #374151;
}
.nav-user-chevron { font-size: 12px; color: #9ca3af; }
.nav-user-dropdown {
  position: absolute; top: calc(100% + 8px); right: 0;
  background: #fff; border: 1.5px solid #e5e7eb;
  border-radius: 12px; min-width: 180px;
  box-shadow: 0 8px 24px rgba(0,0,0,.1);
  display: none; z-index: 200; overflow: hidden;
}
.nav-user-area:hover .nav-user-dropdown,
.nav-user-dropdown.open { display: block; }
.nav-dropdown-item {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px; font-size: 14px; font-weight: 500;
  color: #374151; cursor: pointer; transition: .15s;
  border-bottom: 1px solid #f3f4f6; text-decoration: none;
}
.nav-dropdown-item:last-child { border-bottom: none; }
.nav-dropdown-item:hover { background: #f9fafb; }
.nav-dropdown-item.danger { color: #ef4444; }
.nav-dropdown-item.danger:hover { background: #fee2e2; }

/* ── TOAST ── */
.sl-toast {
  position: fixed; bottom: 24px; left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: #111827; color: #fff;
  padding: 12px 24px; border-radius: 10px;
  font-size: 14px; font-weight: 500;
  z-index: 9999; transition: transform .3s ease;
  white-space: nowrap; pointer-events: none;
}
.sl-toast.show { transform: translateX(-50%) translateY(0); }
