:root {
  --navy: #24214a;
  --orange: #eb941f;
  --green: #94c21f;
  --blue: #00579e;
  --blue-light: #e6f1fb;
  --border: #e8e8e8;
  --text: #222;
  --muted: #666;
  --bg: #f4f5f7;
}

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

body {
  font-family: 'Nunito', sans-serif;
  font-weight: 300;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
}

/* LOGIN */
.login-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
}
.login-box {
  background: #fff;
  border-radius: 12px;
  border: 1px solid var(--border);
  padding: 40px;
  width: 100%;
  max-width: 420px;
}
.login-logo { height: 40px; margin-bottom: 24px; display: block; }
.login-box h1 { font-size: 20px; font-weight: 800; color: var(--navy); margin-bottom: 4px; }
.login-sub { font-size: 13px; color: var(--muted); margin-bottom: 24px; }
.login-help { font-size: 12px; color: var(--muted); text-align: center; margin-top: 16px; }
.login-help a { color: var(--blue); }
.error-msg { background: #fce8e8; color: #7f1d1d; border: 1px solid #fca5a5; border-radius: 6px; padding: 10px 12px; font-size: 13px; margin-bottom: 14px; }
.success-box { background: #e8f5e9; color: #1b5e20; border: 1px solid #a5d6a7; border-radius: 6px; padding: 12px; font-size: 13px; margin-bottom: 14px; font-weight: 400; }

/* TOPBAR */
.topbar {
  background: var(--navy);
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  position: sticky;
  top: 0;
  z-index: 100;
}
.logo-area { display: flex; align-items: center; gap: 12px; }
.topbar-logo { height: 24px; width: auto; }
.hub-label { color: var(--orange); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; font-weight: 800; padding-left: 12px; border-left: 1px solid rgba(255,255,255,0.15); margin-left: 2px; }
.nav { display: flex; gap: 2px; }
.tab {
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.5);
  font-family: 'Nunito', sans-serif;
  font-size: 12px;
  font-weight: 400;
  padding: 7px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}
.tab:hover { background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.85); }
.tab.active { background: var(--blue); color: #fff; font-weight: 800; }
.topbar-right { display: flex; align-items: center; gap: 6px; }
.usr-chip { display: flex; align-items: center; gap: 7px; background: rgba(255,255,255,0.08); border-radius: 20px; padding: 4px 10px 4px 4px; }
.usr-av { width: 26px; height: 26px; border-radius: 50%; background: var(--blue); display: flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 800; color: #fff; }
.usr-name { font-size: 12px; color: var(--orange); font-weight: 800; }

/* CONTENT */
.content { padding: 20px; }
.view { display: none; }
.view.active { display: block; }

/* PAGE HEADER */
.page-hdr { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 18px; flex-wrap: wrap; gap: 10px; }
.page-title { font-size: 20px; font-weight: 800; color: var(--navy); }
.page-sub { font-size: 12px; color: var(--muted); margin-top: 2px; }

/* BUTTONS */
.btn { display: inline-flex; align-items: center; gap: 5px; padding: 8px 15px; border-radius: 6px; font-family: 'Nunito', sans-serif; font-size: 12px; font-weight: 800; cursor: pointer; border: none; transition: opacity 0.15s; }
.btn:hover { opacity: 0.85; }
.btn-blue { background: var(--blue); color: #fff; }
.btn-orange { background: var(--orange); color: #fff; }
.btn-outline { background: transparent; border: 1.5px solid var(--blue); color: var(--blue); }
.btn-sm { padding: 5px 11px; font-size: 11px; }
.full-btn { width: 100%; padding: 11px; background: var(--blue); color: #fff; border: none; border-radius: 7px; font-size: 14px; font-weight: 800; font-family: 'Nunito', sans-serif; cursor: pointer; transition: opacity 0.15s; }
.full-btn:hover { opacity: 0.88; }
.act-btn { padding: 5px 12px; font-size: 11px; font-weight: 800; border-radius: 6px; cursor: pointer; border: 1.5px solid var(--blue); background: transparent; color: var(--blue); font-family: 'Nunito', sans-serif; transition: all 0.15s; white-space: nowrap; }
.act-btn:hover { background: var(--blue); color: #fff; }
.act-btn.done { border-color: #2e7d32; color: #2e7d32; background: #e8f5e9; }

/* CARDS */
.card { background: #fff; border-radius: 10px; border: 1px solid var(--border); padding: 16px; }
.card-hdr { font-size: 13px; font-weight: 800; color: var(--navy); margin-bottom: 14px; display: flex; align-items: center; justify-content: space-between; }
.card-sub { font-size: 11px; font-weight: 300; color: var(--muted); }

/* GRIDS */
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.grid3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }
@media (max-width: 768px) { .grid2, .grid3 { grid-template-columns: 1fr; } }

/* KPI */
.kpi-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; margin-bottom: 16px; }
.kpi { background: #fff; border-radius: 10px; border: 1px solid var(--border); padding: 14px 16px; border-top: 3px solid var(--blue); }
.kpi.o { border-top-color: var(--orange); }
.kpi.g { border-top-color: var(--green); }
.kpi.n { border-top-color: var(--navy); }
.kpi-lbl { font-size: 10px; color: #888; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 5px; font-weight: 800; }
.kpi-val { font-size: 26px; font-weight: 800; color: var(--navy); line-height: 1; }
.kpi-delta { font-size: 11px; margin-top: 4px; color: var(--muted); }
.delta-up { color: #2e7d32; }
.delta-dn { color: #c0392b; }
.delta-warn { color: #d97706; }

/* ALERT */
.alert-bar { background: #fef3e2; border: 1px solid #f59e0b; border-radius: 8px; padding: 10px 14px; margin-bottom: 14px; display: flex; align-items: center; gap: 10px; font-size: 12px; color: #92400e; }
.alert-bar strong { font-weight: 800; }
.alert-bar a { color: #92400e; font-weight: 800; cursor: pointer; }

/* TABLE */
.tbl { width: 100%; border-collapse: collapse; font-size: 12px; }
.tbl th { font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; color: #888; text-align: left; padding: 5px 8px; border-bottom: 1px solid #eee; }
.tbl td { padding: 9px 8px; border-bottom: 1px solid #f0f0f0; color: #333; vertical-align: middle; font-weight: 300; }
.tbl tr:last-child td { border-bottom: none; }
.tbl tr:hover td { background: #fafafa; }
.tbl strong { font-weight: 800; color: var(--navy); }

/* BADGES */
.bdg { display: inline-block; padding: 2px 8px; border-radius: 20px; font-size: 10px; font-weight: 800; white-space: nowrap; }
.bdg-screen { background: #eeedf5; color: #24214a; }
.bdg-docs { background: #fef3e2; color: #92400e; }
.bdg-review { background: #e6f1fb; color: #0c447c; }
.bdg-offer { background: #e8f5e9; color: #1b5e20; }
.bdg-hired { background: #00579e18; color: #00579e; }
.bdg-fail { background: #fce8e8; color: #7f1d1d; }
.bdg-warn { background: #fef3e2; color: #92400e; }
.bdg-pass { background: #e8f5e9; color: #1b5e20; }
.bdg-reject { background: #f3f4f6; color: #6b7280; }

/* FORM */
.form-group { margin-bottom: 12px; }
.form-lbl { display: block; font-size: 11px; font-weight: 800; color: #555; margin-bottom: 4px; text-transform: uppercase; letter-spacing: 0.04em; }
.form-input { width: 100%; padding: 9px 11px; border: 1.5px solid #ddd; border-radius: 6px; font-size: 13px; font-family: 'Nunito', sans-serif; font-weight: 300; color: #333; background: #fff; outline: none; transition: border 0.15s; }
.form-input:focus { border-color: var(--blue); }
select.form-input { cursor: pointer; }
.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.span2 { grid-column: span 2; }

/* SOURCE TAGS */
.src { display: inline-block; padding: 1px 7px; border-radius: 3px; font-size: 10px; font-weight: 800; }
.src-in { background: #003A9B18; color: #003A9B; }
.src-fb { background: #1877F218; color: #1877F2; }
.src-dr { background: #2e7d3218; color: #2e7d32; }
.src-ag { background: #92400e18; color: #92400e; }

/* FUNNEL */
.funnel-row { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.funnel-lbl { font-size: 11px; color: var(--muted); width: 110px; flex-shrink: 0; }
.funnel-track { flex: 1; background: #f0f0f0; border-radius: 3px; height: 7px; overflow: hidden; }
.funnel-fill { height: 7px; border-radius: 3px; background: var(--blue); }
.funnel-n { font-size: 11px; font-weight: 800; color: var(--navy); width: 28px; text-align: right; flex-shrink: 0; }
.funnel-pct { font-size: 10px; color: #999; width: 32px; text-align: right; flex-shrink: 0; }

/* COMPLIANCE */
.comp-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid #f0f0f0; }
.comp-row:last-child { border-bottom: none; }
.comp-lbl { font-size: 12px; flex: 1; }
.dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.dot-g { background: #2e7d32; } .dot-a { background: #d97706; } .dot-r { background: #c0392b; } .dot-k { background: #111; }
.alert-item { display: flex; align-items: center; gap: 9px; padding: 8px 0; border-bottom: 1px solid #f0f0f0; font-size: 12px; }
.alert-item:last-child { border-bottom: none; }
.adot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }

/* DOC ITEMS */
.doc-item { display: flex; align-items: center; justify-content: space-between; padding: 11px; border: 1.5px solid #eee; border-radius: 8px; margin-bottom: 8px; }
.doc-left { display: flex; align-items: center; gap: 10px; }
.doc-ico { width: 30px; height: 30px; background: var(--blue-light); border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 14px; color: var(--blue); flex-shrink: 0; }
.doc-nm { font-size: 12px; font-weight: 800; color: var(--navy); }
.doc-hint { font-size: 11px; color: #888; margin-top: 1px; }

/* SCORING */
.check-lbl { display: flex; align-items: center; gap: 8px; font-size: 12px; cursor: pointer; }
.pts { font-size: 10px; color: #888; margin-left: auto; }
.score-display { margin-top: 14px; padding: 10px 12px; background: var(--blue-light); border-radius: 6px; display: flex; align-items: center; justify-content: space-between; }

/* STEPS (portal) */
.steps { display: flex; background: #fff; border: 1px solid var(--border); border-radius: 10px; overflow: hidden; margin-bottom: 14px; }
.step { flex: 1; padding: 10px 5px; text-align: center; border-right: 1px solid #eee; cursor: pointer; transition: background 0.15s; }
.step:last-child { border-right: none; }
.step.done { background: var(--blue-light); }
.step.done .s-n, .step.done .s-l { color: var(--blue); }
.step.cur { background: var(--navy); }
.step.cur .s-n, .step.cur .s-l { color: #fff; }
.s-n { font-size: 14px; font-weight: 800; color: #aaa; margin-bottom: 1px; }
.s-l { font-size: 9px; color: #aaa; font-weight: 800; text-transform: uppercase; letter-spacing: 0.03em; }
.section-card { background: #fff; border: 1px solid var(--border); border-radius: 10px; padding: 18px; margin-bottom: 12px; }
.section-hdr { font-size: 14px; font-weight: 800; color: var(--navy); margin-bottom: 14px; display: flex; align-items: center; gap: 7px; }

/* MODAL */
.modal-bg { position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 500; display: flex; align-items: center; justify-content: center; }
.modal { background: #fff; border-radius: 12px; padding: 24px; width: 480px; max-width: 95vw; max-height: 90vh; overflow-y: auto; }
.modal-lg { width: 700px; }
.modal-title { font-size: 16px; font-weight: 800; color: var(--navy); }
