/* ============================================
   UPLIFT LIVE FOUNDATION — TEAM ONBOARDING
   Dark Theme · Plus Jakarta Sans + Syne
   ============================================ */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:        #0D0D0F;
  --bg2:       #141418;
  --bg3:       #1C1C22;
  --bg4:       #242430;
  --border:    #2A2A36;
  --border2:   #353545;
  --text:      #F0EEF8;
  --text2:     #A8A4C0;
  --text3:     #6B6880;
  --yellow:    #F5C842;
  --yellow2:   #FFD966;
  --green:     #3DDC84;
  --green-bg:  #0D2B1A;
  --red:       #FF5C5C;
  --red-bg:    #2B0D0D;
  --blue:      #5B8DEF;
  --blue-bg:   #0D1A2B;
  --purple:    #9B7FE8;
  --purple-bg: #1A0D2B;
  --sidebar-w: 240px;
  --radius:    12px;
  --radius-sm: 8px;
  --shadow:    0 4px 24px rgba(0,0,0,0.4);
  --shadow-lg: 0 8px 48px rgba(0,0,0,0.6);
  --font-body: 'Plus Jakarta Sans', sans-serif;
  --font-disp: 'Syne', sans-serif;
  --transition: 0.2s cubic-bezier(0.4,0,0.2,1);
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  display: flex;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ── SCROLLBAR ── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg2); }
::-webkit-scrollbar-thumb { background: var(--border2); border-radius: 3px; }

/* ══════════════════════════════════════
   SIDEBAR
══════════════════════════════════════ */
.sidebar {
  width: var(--sidebar-w);
  background: var(--bg2);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
  padding: 0;
}

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 24px 20px 20px;
  border-bottom: 1px solid var(--border);
}

.logo-icon {
  font-size: 28px;
  line-height: 1;
  filter: drop-shadow(0 0 8px rgba(245,200,66,0.4));
}

.logo-title {
  font-family: var(--font-disp);
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: 0.02em;
}

.logo-sub {
  font-size: 10px;
  color: var(--text3);
  margin-top: 1px;
  letter-spacing: 0.03em;
}

.sidebar-nav {
  flex: 1;
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow-y: auto;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  color: var(--text2);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: var(--transition);
  letter-spacing: 0.01em;
}

.nav-item:hover {
  background: var(--bg3);
  color: var(--text);
}

.nav-item.active {
  background: linear-gradient(135deg, rgba(245,200,66,0.15), rgba(245,200,66,0.05));
  color: var(--yellow);
  border: 1px solid rgba(245,200,66,0.2);
}

.sidebar-footer {
  padding: 16px 12px;
  border-top: 1px solid var(--border);
}

.user-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: var(--bg3);
  border-radius: var(--radius-sm);
}

.user-avatar {
  width: 32px; height: 32px;
  background: linear-gradient(135deg, var(--yellow), #E8A020);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 800;
  color: #0D0D0F;
  flex-shrink: 0;
}

.user-name { font-size: 12px; font-weight: 600; color: var(--text); }
.user-role { font-size: 10px; color: var(--text3); margin-top: 1px; }

/* ══════════════════════════════════════
   MAIN
══════════════════════════════════════ */
.main {
  margin-left: var(--sidebar-w);
  flex: 1;
  padding: 32px 40px 60px;
  max-width: calc(100vw - var(--sidebar-w));
  min-height: 100vh;
}

/* ── TOPBAR ── */
.topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 32px;
}

.page-title {
  font-family: var(--font-disp);
  font-size: 26px;
  font-weight: 800;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 10px;
  letter-spacing: -0.02em;
}

.title-icon { font-size: 24px; }

.page-sub {
  font-size: 13px;
  color: var(--text2);
  margin-top: 6px;
  line-height: 1.6;
  max-width: 560px;
}

.emp-id-preview {
  background: linear-gradient(135deg, rgba(245,200,66,0.12), rgba(245,200,66,0.04));
  border: 1px solid rgba(245,200,66,0.3);
  border-radius: var(--radius);
  padding: 14px 20px;
  text-align: center;
  min-width: 180px;
  flex-shrink: 0;
}

.emp-id-label {
  font-size: 10px;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  display: block;
  margin-bottom: 4px;
}

.emp-id-value {
  font-family: var(--font-disp);
  font-size: 20px;
  font-weight: 800;
  color: var(--yellow);
  letter-spacing: 0.04em;
}

/* ── STEPS BAR ── */
.steps-bar {
  display: flex;
  align-items: center;
  margin-bottom: 32px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 28px;
  gap: 0;
  overflow-x: auto;
}

.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.step-circle {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--bg3);
  border: 2px solid var(--border2);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: var(--text3);
  transition: var(--transition);
}

.step-label {
  font-size: 11px;
  color: var(--text3);
  font-weight: 500;
  white-space: nowrap;
  transition: var(--transition);
}

.step.active .step-circle {
  background: var(--yellow);
  border-color: var(--yellow);
  color: #0D0D0F;
  box-shadow: 0 0 16px rgba(245,200,66,0.4);
}

.step.active .step-label { color: var(--yellow); font-weight: 600; }

.step.done .step-circle {
  background: var(--green);
  border-color: var(--green);
  color: #0D0D0F;
}

.step.done .step-label { color: var(--green); }

.step-line {
  flex: 1;
  height: 2px;
  background: var(--border);
  min-width: 32px;
  margin-bottom: 20px;
  transition: var(--transition);
}

.step-line.done { background: var(--green); }

/* ── FORM CONTAINER ── */
.form-container { position: relative; }

.form-panel {
  display: none;
  animation: fadeSlide 0.3s ease;
}

.form-panel.active { display: block; }

@keyframes fadeSlide {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── PANEL HEADER ── */
.panel-header {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 28px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}

.panel-icon {
  font-size: 32px;
  line-height: 1;
  flex-shrink: 0;
  margin-top: 2px;
}

.panel-title {
  font-family: var(--font-disp);
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}

.panel-desc {
  font-size: 13px;
  color: var(--text2);
  margin-top: 4px;
  line-height: 1.5;
}

.api-badge {
  margin-left: auto;
  flex-shrink: 0;
  background: var(--blue-bg);
  border: 1px solid rgba(91,141,239,0.3);
  color: var(--blue);
  font-size: 11px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 20px;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

/* ── API CONFIG BAR ── */
.api-config-bar {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.config-field { display: flex; flex-direction: column; gap: 6px; flex: 1; min-width: 160px; }

.btn-config {
  background: var(--bg3);
  border: 1px solid var(--border2);
  color: var(--purple);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
  height: 42px;
  align-self: flex-end;
}

.btn-config:hover {
  background: var(--purple-bg);
  border-color: rgba(155,127,232,0.4);
}

/* ── FORM GRID ── */
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.field-group { display: flex; flex-direction: column; gap: 8px; }
.field-group.full-width { grid-column: 1 / -1; }

.field-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

.req { color: var(--yellow); }

.field-input {
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  padding: 11px 14px;
  outline: none;
  transition: var(--transition);
  width: 100%;
  appearance: none;
  -webkit-appearance: none;
}

.field-input::placeholder { color: var(--text3); }

.field-input:focus {
  border-color: var(--yellow);
  background: var(--bg4);
  box-shadow: 0 0 0 3px rgba(245,200,66,0.1);
}

.field-input[readonly] {
  color: var(--text2);
  cursor: default;
  background: var(--bg2);
}

.field-input.sm { font-size: 13px; padding: 9px 12px; }

select.field-input {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236B6880' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
  cursor: pointer;
}

/* ── VERIFY CARD ── */
.verify-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 24px;
}

.verify-input-row {
  display: flex;
  align-items: flex-end;
  gap: 16px;
}

.btn-verify {
  background: linear-gradient(135deg, var(--yellow), #E8A020);
  border: none;
  border-radius: var(--radius-sm);
  color: #0D0D0F;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 700;
  padding: 11px 20px;
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 8px;
  height: 44px;
  flex-shrink: 0;
}

.btn-verify:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(245,200,66,0.35);
}

.btn-verify:active { transform: translateY(0); }

.btn-verify.loading {
  opacity: 0.7;
  cursor: not-allowed;
  pointer-events: none;
}

.btn-verify.full-btn { width: 100%; justify-content: center; height: 48px; font-size: 14px; }

.btn-icon { font-size: 14px; }

/* ── OTP SECTION ── */
.otp-section {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.otp-info {
  background: var(--blue-bg);
  border: 1px solid rgba(91,141,239,0.25);
  border-radius: var(--radius-sm);
  color: var(--blue);
  font-size: 13px;
  padding: 10px 14px;
  margin-bottom: 16px;
}

/* ── FETCHED DATA ── */
.fetched-data {
  margin-top: 20px;
  background: var(--green-bg);
  border: 1px solid rgba(61,220,132,0.25);
  border-radius: var(--radius);
  padding: 20px;
  animation: fadeSlide 0.3s ease;
}

.fetched-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}

.fetched-icon { font-size: 18px; }

.fetched-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--green);
}

.fetched-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.fetched-field { display: flex; flex-direction: column; gap: 4px; }
.fetched-field.full { grid-column: 1 / -1; }

.fetched-field label {
  font-size: 10px;
  font-weight: 600;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

.fetched-value {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(61,220,132,0.15);
  border-radius: 6px;
  padding: 8px 12px;
}

/* ── PANEL ACTIONS ── */
.panel-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.btn-next {
  background: linear-gradient(135deg, var(--yellow), #E8A020);
  border: none;
  border-radius: var(--radius-sm);
  color: #0D0D0F;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  padding: 12px 28px;
  cursor: pointer;
  transition: var(--transition);
}

.btn-next:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(245,200,66,0.35);
}

.btn-back {
  background: var(--bg3);
  border: 1px solid var(--border2);
  border-radius: var(--radius-sm);
  color: var(--text2);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  padding: 12px 24px;
  cursor: pointer;
  transition: var(--transition);
}

.btn-back:hover { background: var(--bg4); color: var(--text); }

.btn-save {
  background: linear-gradient(135deg, var(--green), #28A060);
  border: none;
  border-radius: var(--radius-sm);
  color: #0D0D0F;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  padding: 12px 32px;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-save:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(61,220,132,0.35);
}

/* ── REVIEW CONTAINER ── */
.review-container {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-bottom: 24px;
}

.review-section {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}

.review-section-title {
  font-family: var(--font-disp);
  font-size: 13px;
  font-weight: 700;
  color: var(--yellow);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.review-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  gap: 12px;
}

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

.review-key {
  font-size: 12px;
  color: var(--text3);
  font-weight: 500;
  flex-shrink: 0;
}

.review-val {
  font-size: 13px;
  color: var(--text);
  font-weight: 600;
  text-align: right;
}

.review-val.verified {
  color: var(--green);
  display: flex;
  align-items: center;
  gap: 4px;
}

.review-val.pending { color: var(--text3); font-style: italic; }

/* ── EMPLOYEE ID CARD ── */
.emp-id-card {
  background: linear-gradient(135deg, rgba(245,200,66,0.12) 0%, rgba(245,200,66,0.04) 50%, rgba(155,127,232,0.08) 100%);
  border: 1px solid rgba(245,200,66,0.35);
  border-radius: var(--radius);
  padding: 28px 32px;
  text-align: center;
  margin-bottom: 8px;
  position: relative;
  overflow: hidden;
}

.emp-id-card::before {
  content: '';
  position: absolute;
  top: -40px; right: -40px;
  width: 120px; height: 120px;
  background: radial-gradient(circle, rgba(245,200,66,0.15), transparent 70%);
  border-radius: 50%;
}

.emp-id-card-label {
  font-size: 12px;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 10px;
}

.emp-id-card-value {
  font-family: var(--font-disp);
  font-size: 40px;
  font-weight: 800;
  color: var(--yellow);
  letter-spacing: 0.06em;
  line-height: 1;
  margin-bottom: 10px;
  text-shadow: 0 0 30px rgba(245,200,66,0.3);
}

.emp-id-card-sub {
  font-size: 13px;
  color: var(--text2);
}

/* ── MODAL ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  animation: fadeIn 0.2s ease;
}

.modal-overlay.hidden { display: none; }

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.modal-box {
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-radius: 20px;
  padding: 48px 40px;
  max-width: 480px;
  width: 90%;
  text-align: center;
  box-shadow: var(--shadow-lg);
  animation: modalPop 0.3s cubic-bezier(0.34,1.56,0.64,1);
}

@keyframes modalPop {
  from { opacity: 0; transform: scale(0.85); }
  to   { opacity: 1; transform: scale(1); }
}

.modal-icon { font-size: 56px; margin-bottom: 16px; }

.modal-title {
  font-family: var(--font-disp);
  font-size: 26px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 8px;
}

.modal-sub { font-size: 14px; color: var(--text2); margin-bottom: 24px; }

.modal-emp-id {
  font-family: var(--font-disp);
  font-size: 36px;
  font-weight: 800;
  color: var(--yellow);
  letter-spacing: 0.06em;
  background: linear-gradient(135deg, rgba(245,200,66,0.12), rgba(245,200,66,0.04));
  border: 1px solid rgba(245,200,66,0.3);
  border-radius: var(--radius);
  padding: 16px 24px;
  margin-bottom: 20px;
}

.modal-details {
  font-size: 13px;
  color: var(--text2);
  line-height: 1.8;
  margin-bottom: 28px;
}

.modal-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
}

/* ── TOAST ── */
.toast {
  position: fixed;
  bottom: 32px;
  right: 32px;
  background: var(--bg3);
  border: 1px solid var(--border2);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 13px;
  font-weight: 500;
  padding: 12px 20px;
  z-index: 2000;
  box-shadow: var(--shadow);
  animation: toastIn 0.3s ease;
  max-width: 320px;
}

.toast.hidden { display: none; }
.toast.success { border-color: rgba(61,220,132,0.4); color: var(--green); }
.toast.error   { border-color: rgba(255,92,92,0.4);  color: var(--red); }
.toast.info    { border-color: rgba(91,141,239,0.4);  color: var(--blue); }

@keyframes toastIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── HIDDEN UTILITY ── */
.hidden { display: none !important; }

/* ══════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════ */
@media (max-width: 900px) {
  :root { --sidebar-w: 0px; }
  .sidebar { display: none; }
  .main { margin-left: 0; padding: 20px 16px 40px; max-width: 100vw; }
  .form-grid { grid-template-columns: 1fr; }
  .fetched-grid { grid-template-columns: repeat(2, 1fr); }
  .review-container { grid-template-columns: 1fr; }
  .topbar { flex-direction: column; }
  .steps-bar { padding: 16px; gap: 0; }
  .step-label { font-size: 9px; }
  .verify-input-row { flex-direction: column; align-items: stretch; }
  .btn-verify { width: 100%; justify-content: center; }
  .api-config-bar { flex-direction: column; }
}

@media (max-width: 600px) {
  .fetched-grid { grid-template-columns: 1fr; }
  .modal-box { padding: 32px 24px; }
  .modal-emp-id { font-size: 26px; }
  .emp-id-card-value { font-size: 28px; }
}