/* ============================================================
   ResumeMatch AI — Premium Light UI (Space Grotesk Theme)
   ============================================================ */

:root {
  /* Backgrounds */
  --bg-base:        #fcf8f8;
  --bg-surface:     rgba(255, 255, 255, 0.6);
  --bg-elevated:    rgba(255, 255, 255, 0.85);
  --bg-card:        rgba(255, 255, 255, 0.7);
  --bg-card-hover:  rgba(255, 255, 255, 0.8);
  --bg-purple-card: #5D21D0;
  --bg-purple-light: rgba(93, 33, 208, 0.08);

  /* Borders */
  --border:         rgba(93, 33, 208, 0.12);
  --border-strong:  rgba(93, 33, 208, 0.28);
  --border-light:   rgba(28, 27, 27, 0.08);

  /* Brand palette */
  --purple:         #5D21D0;
  --purple-solid:   #5D21D0;
  --purple-dark:    #4400a8;
  --blue:           #4C5377;
  --cyan:           #06b6d4;
  --indigo:         #949AB1;
  --pink-light:     #E2D4E0;

  /* Semantic */
  --success:  #10b981;
  --warning:  #f59e0b;
  --danger:   #ef4444;

  /* Text - Enhanced contrast */
  --text-1:         #1c1b1b;
  --text-2:         rgba(28, 27, 27, 0.72);
  --text-3:         rgba(28, 27, 27, 0.55);
  --text-4:         rgba(28, 27, 27, 0.45);
  --text-on-purple: #FFFFFF;

  /* Gradients */
  --grad:     #5D21D0;
  --grad-soft:rgba(93, 33, 208, 0.07);
  --grad-card:#FFFFFF;
  --grad-bg:  #fcf8f8;

  /* Misc */
  --radius:   1rem;
  --radius-sm:10px;
  --radius-lg:20px;
  --shadow:         0 8px 24px rgba(0,0,0,0.06);
  --shadow-md:      0 10px 30px rgba(0,0,0,0.08);
  --shadow-lg:      0 16px 40px rgba(0,0,0,0.10);
  --font:     'Space Grotesk', system-ui, sans-serif;
  --transition: 0.3s cubic-bezier(.4,0,.2,1);
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
* { color: #3F3A5A; }
html { scroll-behavior: smooth; font-size: 16px; }

body {
  background: #F7F4FA;
  color: var(--text-1);
  font-family: var(--font);
  line-height: 1.65;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a { color: #7C7E9D; text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--blue); }

img, svg { display: block; }

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-surface); }
::-webkit-scrollbar-thumb { 
  background: var(--purple); 
  border-radius: 3px; 
}
::-webkit-scrollbar-thumb:hover { 
  background: var(--purple-dark); 
}

/* ============================================================
   NAVBAR
   ============================================================ */
.navbar {
  background: #FFFFFF;
  border-bottom: 1px solid var(--border);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 8px 24px rgba(0,0,0,0.06);
}

.navbar .container {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.navbar-brand {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -.02em;
  display: flex;
  align-items: center;
  gap: .6rem;
}

.navbar-logo {
  width: 32px;
  height: 32px;
  display: block;
  transition: transform 0.3s ease;
}

.navbar-brand:hover .navbar-logo {
  transform: scale(1.1);
}

.gradient-text,
.text-gradient,
[class*="gradient"] {
  color: var(--purple) !important;
  -webkit-text-fill-color: initial !important;
  background: none !important;
}

@keyframes gradShift {
  0%,100% { background-position: 0% 50%; }
  50%      { background-position: 100% 50%; }
}

.nav-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.nav-user {
  display: flex;
  align-items: center;
  gap: .6rem;
  color: var(--text-1);
  font-size: .9rem;
  font-weight: 600;
}

.nav-user i { color: #7C7E9D; font-size: 1.1rem; }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  overflow: hidden;
  padding: 5rem 0 4rem;
  text-align: center;
}

.hero-glow {
  display: none !important;
  background: none !important;
}

.hero-glow::before {
  display: none !important;
  background: none !important;
}

@keyframes pulseGlow {
  0%,100% { opacity: .7; transform: translateX(-50%) scale(1); }
  50%      { opacity: 1;  transform: translateX(-50%) scale(1.05); }
}

.hero .container { position: relative; z-index: 1; }

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  background: var(--purple) !important; /* Changed to solid purple */
  border: 1px solid var(--purple-dark) !important;
  border-radius: 25px;
  padding: .5rem 1.25rem;
  font-size: .85rem;
  font-weight: 700;
  color: #ffffff !important; /* Changed text to white */
  letter-spacing: .05em;
  text-transform: uppercase;
  margin-bottom: 2rem;
  box-shadow: var(--shadow);
}

.hero-eyebrow i { 
  color: #ffffff !important; /* Changed the icon to white to match the text */
}

.hero-title {
  font-size: clamp(2.25rem, 5vw, 4rem);
  font-weight: 800;
  letter-spacing: -.03em;
  line-height: 1.15;
  margin-bottom: 1.5rem;
  color: var(--text-1);
}

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-2);
  max-width: 600px;
  margin: 0 auto 2.5rem;
  line-height: 1.7;
  font-weight: 500;
}

/* ============================================================
   GLASS CARD
   ============================================================ */
.glass {
  background: #ffffff;
  border: 1px solid #E6E1EF;
  border-radius: var(--radius);
  box-shadow: 0 8px 24px rgba(0,0,0,0.06);
  transition: all var(--transition);
}

.glass:hover { 
  border-color: var(--border-strong); 
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

/* Purple cards with white text */
.glass.purple-card,
.stat-card.purple,
.job-card.purple {
  background: #7C7E9D;
  color: white;
  border-color: rgba(255, 255, 255, 0.15);
  box-shadow: 0 16px 40px rgba(0,0,0,0.10);
}

.glass.purple-card *,
.stat-card.purple *,
.job-card.purple * {
  color: white !important;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font-family: var(--font);
  font-weight: 600;
  font-size: .9rem;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: #3F3A5A !important;
  background-image: none !important;
  background-size: auto;
  animation: none;
  color: #ffffff !important;
  border: none !important;
  padding: .85rem 2rem;
  box-shadow: 0 6px 18px rgba(0,0,0,0.08) !important;
  font-weight: 700;
}

.btn-primary:hover {
  background: #35304D !important;
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(0,0,0,0.10) !important;
  color: #ffffff !important;
}

.btn-primary:active {
  background: #2E2A44 !important;
  transform: translateY(0);
}

.btn-primary:disabled {
  opacity: .5;
  cursor: not-allowed;
  transform: none;
  animation: none;
  box-shadow: none;
}

.btn-ghost {
  background: #FFFFFF;
  color: var(--text-1);
  border: 1px solid var(--border);
  padding: .7rem 1.5rem;
  font-weight: 600;
}

.btn-ghost:hover {
  background: var(--bg-surface);
  border-color: #3F3A5A;
  color: var(--text-1);
  transform: translateY(-2px);
}

.btn-danger-ghost {
  background: transparent;
  color: var(--danger);
  border: 1px solid rgba(239,68,68,.3);
  padding: .6rem 1.25rem;
  font-size: .85rem;
  font-weight: 600;
}

.btn-danger-ghost:hover {
  background: rgba(239,68,68,.1);
  border-color: var(--danger);
  color: var(--danger);
  transform: translateY(-2px);
}

.btn-success-ghost {
  background: transparent;
  color: var(--success);
  border: 1px solid rgba(16,185,129,.3);
  padding: .6rem 1.25rem;
  font-size: .85rem;
  font-weight: 600;
}

.btn-success-ghost:hover {
  background: rgba(16,185,129,.1);
  border-color: var(--success);
  color: var(--success);
  transform: translateY(-2px);
}

.btn-sm { padding: .45rem .9rem; font-size: .8rem; }
.btn-lg { padding: 1rem 2.5rem; font-size: 1rem; }

.btn::before,
.btn::after {
  display: none !important;
  content: none !important;
  background: none !important;
}

.btn,
.btn-primary,
.btn-ghost,
.btn-danger-ghost {
  background-image: none !important;
  opacity: 1 !important;
  filter: none !important;
}

.btn-icon {
  width: 40px;
  height: 40px;
  padding: 0;
  justify-content: center;
  border-radius: var(--radius-sm);
  background: #ffffff !important;
  border: 1px solid #E6E1EF !important;
  color: var(--text-2);
  font-size: 1rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05) !important;
}

.btn-icon:hover { 
  background: var(--bg-surface); 
  color: var(--text-1); 
  border-color: var(--border-strong); 
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.btn-icon.edit:hover  { 
  color: var(--warning); 
  border-color: rgba(245,158,11,.5); 
  background: rgba(245,158,11,.08);
}

.btn-icon.delete:hover { 
  color: var(--danger); 
  border-color: rgba(239,68,68,.5); 
  background: rgba(239,68,68,.08);
}

.btn-icon.upload:hover { 
  color: var(--success); 
  border-color: rgba(16,185,129,.5); 
  background: rgba(16,185,129,.08);
}

.btn-icon.view:hover   { 
  color: #7C7E9D; 
  border-color: rgba(124,126,157,.5); 
  background: rgba(124,126,157,.08);
}

/* ============================================================
   FORMS
   ============================================================ */
.form-group { margin-bottom: 1.5rem; }

.form-label {
  display: flex;
  align-items: center;
  gap: .6rem;
  font-size: .85rem;
  font-weight: 700;
  color: var(--text-1);
  margin-bottom: .75rem;
  text-transform: uppercase;
  letter-spacing: .05em;
}

.form-label i { color: #7C7E9D; font-size: 1rem; }

.form-control, .form-select {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-1);
  font-family: var(--font);
  font-size: .95rem;
  font-weight: 500;
  padding: .85rem 1.15rem;
  transition: all var(--transition);
  outline: none;
}

.form-control:focus, .form-select:focus {
  border-color: var(--purple);
  box-shadow: 0 0 0 4px rgba(0,0,0,0.06);
  background: var(--bg-elevated);
}

.form-control::placeholder { color: var(--text-4); }

textarea.form-control {
  resize: vertical;
  min-height: 200px;
  line-height: 1.7;
}

.form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2394a3b8' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
  cursor: pointer;
}

.form-select option { background: var(--bg-elevated); }

.char-count {
  font-size: .78rem;
  color: var(--text-3);
  margin-top: .4rem;
  text-align: right;
}

.field-error { color: var(--danger); font-size: .8rem; margin-top: .4rem; }

/* ============================================================
   UPLOAD ZONE
   ============================================================ */
.upload-zone {
  position: relative;
  background: var(--bg-card);
  border: 3px dashed var(--border);
  border-radius: var(--radius-lg);
  padding: 3.5rem 2rem;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition);
  overflow: hidden;
}

.upload-zone::before {
  content: '';
  position: absolute;
  inset: 0;
  background: none;
  opacity: 0;
  transition: opacity var(--transition);
}

.upload-zone:hover {
  border-color: var(--purple);
  border-style: solid;
  transform: scale(1.01);
  box-shadow: var(--shadow-md);
}

.upload-zone:hover::before { opacity: 1; }

.upload-zone.drag-over {
  border-color: var(--purple);
  border-style: solid;
  transform: scale(1.02);
  box-shadow: var(--shadow-lg);
  background: var(--bg-surface);
}

.upload-zone.drag-over::before { opacity: 1; }

.upload-zone input[type="file"] {
  display: none;
}

.upload-icon {
  width: 80px;
  height: 80px;
  background: #F1ECF6;
  border: 1px solid var(--border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  font-size: 2rem;
  color: #7C7E9D;
  position: relative;
  z-index: 1;
  box-shadow: 0 8px 24px rgba(0,0,0,0.06);
}

.upload-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-1);
  margin-bottom: .6rem;
  position: relative;
  z-index: 1;
}

.upload-hint {
  font-size: .9rem;
  color: var(--text-3);
  position: relative;
  z-index: 1;
  font-weight: 500;
}

/* File list */
.file-list {
  list-style: none;
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: .75rem;
}

.file-list li {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: .85rem 1.25rem;
  font-size: .9rem;
  animation: fadeInUp .3s ease forwards;
  transition: all var(--transition);
}

.file-list li:hover {
  border-color: var(--purple);
  background: var(--bg-surface);
  transform: translateX(4px);
}

.file-list li i { color: #7C7E9D; flex-shrink: 0; font-size: 1.1rem; }
.file-list li .file-name { font-weight: 600; flex: 1; color: var(--text-1); }
.file-list li .file-size { color: var(--text-3); font-size: .8rem; font-weight: 500; }

/* ============================================================
   STATS ROW
   ============================================================ */
.stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.stat-card {
  padding: 2rem 1.5rem;
  text-align: center;
  border-radius: var(--radius);
  background: #ffffff;
  border: 1px solid #E6E1EF;
  box-shadow: 0 8px 24px rgba(0,0,0,0.06);
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--grad);
  opacity: 0;
  transition: opacity var(--transition);
}

.stat-card:hover { 
  border-color: var(--purple); 
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.stat-card:hover::before {
  opacity: 1;
}

.stat-value {
  font-size: 2.75rem;
  font-weight: 800;
  letter-spacing: -.03em;
  line-height: 1;
  margin-bottom: .6rem;
  background: none;
  color: #3F3A5A;
}


.row .stat-card:first-child .stat-value.text-gradient,
.row .stat-card:first-child .stat-value {
  display: block !important;
  font-size: 2.75rem !important; 
  font-weight: 800 !important;  
  color: var(--purple) !important;
  -webkit-text-fill-color: initial !important;
  background: none !important;
}

.stat-label {
  font-size: .8rem;
  font-weight: 700;
  color: var(--text-2);
  text-transform: uppercase;
  letter-spacing: .08em;
}

/* ============================================================
   RESULTS TABLE
   ============================================================ */
.table-wrap {
  border-radius: var(--radius);
  border: 1px solid #E6E1EF;
  overflow: hidden;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(0,0,0,0.06);
}

.table-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem 2rem;
  background: #F1ECF6;
  border-bottom: 1px solid var(--border);
}

.table-head-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-1);
  display: flex;
  align-items: center;
  gap: .75rem;
}

.table-head-title i { color: #7C7E9D; font-size: 1.25rem; }

.results-table {
  width: 100%;
  border-collapse: collapse;
}

.results-table th {
  padding: 1rem 1.5rem;
  font-size: .75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text-2);
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
  text-align: left;
}

.results-table td {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border-light);
  vertical-align: middle;
  color: var(--text-1);
  font-weight: 500;
}

.results-table tbody tr {
  transition: background var(--transition);
  animation: fadeInUp .5s ease forwards;
  opacity: 0;
  background: var(--bg-card);
}

.results-table tbody tr:hover { 
  background: var(--bg-surface);
}

.results-table tbody tr:last-child td { border-bottom: none; }

/* Rank */
.rank {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .9rem;
  font-weight: 800;
  color: var(--text-2);
}

.rank.top-1 { 
  background: #f59e0b; 
  border-color: #f59e0b; 
  color: #fff;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.rank.top-2 { 
  background: #949AB1; 
  border-color: #949AB1; 
  color: #fff;
  box-shadow: 0 8px 24px rgba(0,0,0,0.06);
}

.rank.top-3 { 
  background: #cd7c2f; 
  border-color: #cd7c2f; 
  color: #fff;
  box-shadow: 0 4px 12px rgba(205, 124, 47, 0.3);
}

/* Avatar */
.avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--grad);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1rem;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 8px 24px rgba(0,0,0,0.06);
  border: 3px solid var(--bg-card);
}

/* Score badge */
.score-pill {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .5rem 1.1rem;
  border-radius: 25px;
  font-weight: 700;
  font-size: .95rem;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.score-pill.high   { 
  background: #ECFDF5; 
  color: #059669; 
  border: 1px solid rgba(16,185,129,.4); 
}

.score-pill.medium { 
  background: #FFFBEB; 
  color: #d97706; 
  border: 1px solid rgba(245,158,11,.4); 
}

.score-pill.low    {
  background: #FEF2F2;
  color: #dc2626;
  border: 1px solid rgba(239,68,68,.4);
}

.score-pill.skipped {
  background: #F1F5F9;
  color: #64748b;
  border: 1px solid rgba(100,116,139,.3);
}

/* Score bar */
.score-bar {
  height: 6px;
  background: var(--bg-surface);
  border-radius: 3px;
  margin-top: .6rem;
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.1);
}

.score-fill {
  height: 100%;
  border-radius: 3px;
  transition: width .8s cubic-bezier(.4,0,.2,1);
  box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}

.score-fill.high   { background: #10b981; }
.score-fill.medium { background: #f59e0b; }
.score-fill.low    { background: #ef4444; }
.score-fill.skipped { background: #94a3b8; }

/* Keyword badges */
.kw-wrap { display: flex; flex-wrap: wrap; gap: .5rem; }

.kw {
  display: inline-flex;
  align-items: center;
  padding: .35rem .75rem;
  border-radius: 8px;
  font-size: .75rem;
  font-weight: 700;
  border: 1px solid;
  letter-spacing: .02em;
}

.kw-match { 
  background: #ECFDF5; 
  color: #059669; 
  border-color: rgba(16,185,129,.35); 
}

.kw-miss  { 
  background: #FEF2F2; 
  color: #dc2626;  
  border-color: rgba(239,68,68,.3); 
}

/* Candidate name link */
.candidate-name-link {
  color: var(--text-1);
  text-decoration: none;
  transition: color var(--transition);
  position: relative;
  font-weight: 600;
}

.candidate-name-link:hover {
  color: #7C7E9D;
}

.candidate-name-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: #7C7E9D;
  transition: width var(--transition);
}

.candidate-name-link:hover::after {
  width: 100%;
}

/* Candidate Information Items */
.candidate-info-item {
  display: flex;
  align-items: flex-start;
  gap: 1.25rem;
  padding: 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: all var(--transition);
  box-shadow: var(--shadow);
}

.candidate-info-item:hover {
  border-color: var(--purple);
  background: var(--bg-card-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.candidate-info-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  flex-shrink: 0;
  border: 1px solid;
  background: var(--grad-soft);
}

.candidate-info-content {
  flex: 1;
  min-width: 0;
}

.candidate-info-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-2);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.6rem;
}

.candidate-info-value {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-1);
  line-height: 1.4;
  margin-bottom: 0.3rem;
}

.candidate-info-meta {
  font-size: 0.85rem;
  color: var(--text-3);
  margin-top: 0.5rem;
  font-weight: 500;
}

/* ============================================================
   JOB CARDS (Dashboard)
   ============================================================ */
.job-card {
  background: #ffffff;
  border: 1px solid #E6E1EF;
  border-radius: var(--radius);
  padding: 2rem;
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  box-shadow: 0 8px 24px rgba(0,0,0,0.06);
  position: relative;
  overflow: hidden;
}

.job-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--grad);
  opacity: 0;
  transition: opacity var(--transition);
}

.job-card:hover {
  border-color: var(--purple);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.job-card:hover::before {
  opacity: 1;
}

.job-card-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; }

.job-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-1);
  margin-bottom: .5rem;
  line-height: 1.4;
}

.job-category {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  color: #7C7E9D;
  font-size: .75rem;
  font-weight: 700;
  padding: .35rem .85rem;
  border-radius: 8px;
  text-transform: uppercase;
  letter-spacing: .05em;
}

.job-category i { color: #7C7E9D; }

.job-meta {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  font-size: .85rem;
  color: var(--text-2);
  font-weight: 500;
}

.job-meta span { display: flex; align-items: center; gap: .4rem; }
.job-meta i { color: #7C7E9D; font-size: 1rem; }

.job-actions { display: flex; gap: .75rem; }

/* ============================================================
   EMPTY STATE
   ============================================================ */
.empty-state {
  text-align: center;
  padding: 5rem 2rem;
}

.empty-icon {
  width: 96px;
  height: 96px;
  background: var(--grad-soft);
  border: 1px solid var(--border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  color: #7C7E9D; 
  margin: 0 auto 2rem;
  box-shadow: var(--shadow);
}

.empty-title { 
  font-size: 1.25rem; 
  font-weight: 700; 
  color: var(--text-1);
  margin-bottom: .75rem; 
}

.empty-text  { 
  font-size: .95rem; 
  color: var(--text-3); 
  margin-bottom: 2rem;
  max-width: 400px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.6;
}

/* ============================================================
   ALERTS
   ============================================================ */
.alert {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  border-radius: var(--radius-sm);
  font-size: .9rem;
  margin-bottom: 1.5rem;
  font-weight: 500;
  border: 1px solid;
}

.alert i { flex-shrink: 0; margin-top: .15rem; font-size: 1.1rem; }

.alert-danger  { 
  background: #FEF2F2; 
  border-color: rgba(239,68,68,.3); 
  color: #dc2626; 
}

.alert-success { 
  background: #ECFDF5; 
  border-color: rgba(16,185,129,.3); 
  color: #059669; 
}

.alert-info    { 
  background: #F5F3FF;  
  border-color: rgba(124,126,157,.3);  
  color: #7C7E9D; 
}

.alert-info i { color: #7C7E9D; }

/* ============================================================
   TOAST NOTIFICATIONS
   ============================================================ */
.toast-container {
  z-index: 9999 !important;
}

.toast {
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: var(--radius-sm);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6);
  min-width: 320px;
  animation: slideInRight 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(100%);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.toast.hiding {
  animation: slideOutRight 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideOutRight {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(100%);
  }
}

.toast .toast-body {
  padding: 1rem 1.25rem;
  font-size: 0.9rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.toast .toast-body i {
  font-size: 1.1rem;
  flex-shrink: 0;
}

/* Toast color variants with enhanced styling */
.toast.text-bg-success {
  background: #10b981 !important;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.toast.text-bg-danger {
  background: #ef4444 !important;
  border: 1px solid rgba(239, 68, 68, 0.4);
}

.toast.text-bg-warning {
  background: #f59e0b !important;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.toast.text-bg-info {
  background: #7C7E9D !important;
  border: 1px solid rgba(6, 182, 212, 0.4);
}

.toast .btn-close-white {
  filter: brightness(1.2);
  opacity: 0.8;
  transition: opacity var(--transition);
}

.toast .btn-close-white:hover {
  opacity: 1;
}

/* Responsive toast sizing */
@media (max-width: 480px) {
  .toast {
    min-width: 280px;
    max-width: calc(100vw - 2rem);
  }
  
  .toast .toast-body {
    padding: 0.875rem 1rem;
    font-size: 0.85rem;
  }
}

/* ============================================================
   SECTION DIVIDER
   ============================================================ */
.section-title {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -.02em;
  margin-bottom: 2rem;
  display: flex;
  align-items: center;
  gap: .85rem;
  color: var(--text-1);
}

.section-title i { 
  color: #7C7E9D; 
  font-size: 1.6rem;
}

/* ============================================================
   SPINNER
   ============================================================ */
.spinner {
  width: 18px;
  height: 18px;
  border: 1px solid rgba(0,0,0,0.1);
  border-top-color: #4C5377;
  border-radius: 50%;
  animation: spin .7s linear infinite;
  flex-shrink: 0;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

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

.fade-in { animation: fadeIn .4s ease forwards; }

/* ============================================================
   UTILITIES
   ============================================================ */
.text-gradient {
  all: unset !important;
  color: #3F3A5A !important;
  font-weight: inherit;
}
.text-muted    { color: var(--text-3); }
.text-secondary{ color: var(--text-2); }
.text-success  { color: var(--success); }
.text-warning  { color: var(--warning); }
.text-danger   { color: var(--danger); }
.text-cyan     { color: #7C7E9D; }

:root {
  --text-1: #3F3A5A;
  --text-2: #6B6785;
}

body {
  color: #3F3A5A;
}

.gradient-text,
.text-gradient,
[class*="gradient"] {
  all: unset !important;
  color: #3F3A5A !important;
  font-weight: inherit;
}

.hero-glow,
.hero-glow::before,
.hero::before,
.hero::after {
  display: none !important;
  background: none !important;
}

.navbar {
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  background: #ffffff !important;
}

.hero,
.container,
.glass {
  opacity: 1 !important;
  filter: none !important;
}

.upload-zone::before,
[style*="gradient("] {
  background: none !important;
  background-image: none !important;
}

[style*="opacity:"],
[style*="filter:"],
[style*="color:#"],
[style*="color: #"],
[style*="color:var("],
[style*="color: var("] {
  opacity: 1 !important;
  filter: none !important;
  color: #3F3A5A !important;
}

.fw-500 { font-weight: 500; }
.fw-600 { font-weight: 600; }
.fw-700 { font-weight: 700; }
.fw-800 { font-weight: 800; }

.d-flex { display: flex; }
.align-center { align-items: center; }
.gap-1 { gap: .5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }
.ms-auto { margin-left: auto; }
.mt-1 { margin-top: .5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: .5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.p-0  { padding: 0; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 768px) {
  .hero { padding: 2.5rem 0 2rem; }
  .hero-title { font-size: 2rem; }

  .results-table th:nth-child(4),
  .results-table td:nth-child(4),
  .results-table th:nth-child(5),
  .results-table td:nth-child(5) { display: none; }

  .stats-row { grid-template-columns: repeat(2, 1fr); }
  .stat-value { font-size: 1.75rem; }
  .stats-row .stat-card:first-child .stat-value.text-gradient { font-size: 1.75rem !important; }

  .nav-actions .nav-user { display: none; }
}

@media (max-width: 480px) {
  .stats-row { grid-template-columns: 1fr 1fr; }
  .job-card { padding: 1.25rem; }
}


/* ============================================================
   CHARTS & ANALYTICS
   ============================================================ */

/* Chart containers */
.chart-container {
  position: relative;
  height: 300px;
  margin-bottom: 1rem;
}

.chart-container canvas {
  max-height: 100%;
}

/* Activity Feed */
.activity-feed {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-height: 500px;
  overflow-y: auto;
  padding-right: 0.5rem;
}

.activity-feed::-webkit-scrollbar {
  width: 4px;
}

.activity-feed::-webkit-scrollbar-thumb {
  background: var(--border-strong);
  border-radius: 2px;
}

.activity-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 0.75rem;
  border-radius: var(--radius-sm);
  transition: background var(--transition);
}

.activity-item:hover {
  background: var(--bg-card-hover);
}

.activity-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.activity-icon.user {
  background: #F1ECF6;
  color: #7C7E9D;
  border: 1px solid rgba(124, 126, 157, 0.3);
}

.activity-icon.job {
  background: #F1ECF6;
  color: #7C7E9D;
  border: 1px solid rgba(148, 154, 177, 0.3);
}

.activity-icon.resume {
  background: #ECFDF5;
  color: var(--success);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.activity-content {
  flex: 1;
  min-width: 0;
}

.activity-title {
  font-size: 0.9rem;
  color: var(--text-1);
  margin-bottom: 0.25rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.activity-time {
  font-size: 0.75rem;
  color: var(--text-3);
}

/* Quick Actions */
.quick-actions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1rem;
}

.quick-action-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 2rem 1.25rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-decoration: none;
  transition: all var(--transition);
  box-shadow: var(--shadow);
}

.quick-action-card:hover {
  border-color: var(--purple);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.quick-action-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  border: 1px solid;
  background: #F1ECF6;
  box-shadow: var(--shadow);
}

.quick-action-label {
  font-size: .9rem;
  font-weight: 700;
  color: var(--text-1);
  text-align: center;
}

/* Performance Insights */
.insights-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.insight-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 1rem;
  padding: 2.5rem 1.5rem;
  background: #6B6D8C;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  transition: all var(--transition);
  flex: 1 1 0;
  min-width: 280px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
  position: relative;
  overflow: hidden;
}

.insight-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: #FFFFFF;
  opacity: 0;
  transition: opacity var(--transition);
}

.insight-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 40px rgba(0,0,0,0.10);
  border-color: rgba(255, 255, 255, 0.25);
}

.insight-card:hover::before {
  opacity: 1;
}

.insight-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  flex-shrink: 0;
  border: 3px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.95);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  margin-bottom: 0.5rem;
}

.insight-content {
  flex: 1;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.insight-label {
  font-size: 0.75rem;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.85);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.75rem;
  line-height: 1.4;
  text-align: center;
}
/* 1. Base style (Controls "Software Engineer" title) */
.insight-value {
  font-size: 1.35rem !important; 
  font-weight: 700 !important; /* Slightly pulled back from 800 for a cleaner look */
  color: var(--text-1) !important;
  line-height: 1.2;
  text-align: center;
  word-break: break-word;
  text-shadow: none !important;
}

/* 2. Controls the "(6.8% avg)" in Card 1 */
.insight-meta {
  font-size: 1.45rem !important; /* Elegant, balanced sizing */
  font-weight: 700 !important;   /* MAKES IT NOT BOLD (Medium Weight) */
  color: var(--purple) !important;
  display: block;
  margin-top: 0.4rem;
  text-align: center;
}

/* 3. Controls the "65" in Card 2 */
.insight-value.text-gradient, 
.insight-value.gradient-text {
  font-size: 1.45rem !important; /* Perfectly matches the other numbers */
  font-weight: 700 !important;   /* MAKES IT NOT BOLD (Medium Weight) */
  color: var(--purple) !important;
  -webkit-text-fill-color: initial !important;
  background: none !important;
}

/* 4. Controls the "5.3%" in Card 3 */
.insight-card:nth-child(3) .insight-value {
  font-size: 1.45rem !important; /* Perfectly matches the other numbers */
  font-weight: 700 !important;   /* MAKES IT NOT BOLD (Medium Weight) */
  color: var(--purple) !important;
}

/* Analytics Grid Layout */
.analytics-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.analytics-col-2 {
  grid-column: span 2;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .chart-container {
    height: 250px;
  }
  
  .analytics-row {
    grid-template-columns: 1fr;
  }
  
  .analytics-col-2 {
    grid-column: span 1;
  }
  
  .quick-actions-grid {
    grid-template-columns: 1fr;
  }
  
  .insights-grid {
    flex-direction: column;
  }
  
  .insight-card {
    flex: 1 1 100%;
  }
  
  .activity-feed {
    max-height: 400px;
  }
}

@media (max-width: 480px) {
  .chart-container {
    height: 200px;
  }
  
  .insight-value {
    font-size: 1rem;
  }
  
  .quick-action-icon {
    width: 48px;
    height: 48px;
    font-size: 1.25rem;
  }
}

/* ============================================================
   THEME OVERRIDES (Glassmorphism & New Colors)
   ============================================================ */

body {
  background-color: var(--bg-base) !important;
  color: var(--text-1) !important;
}

.text-primary { color: var(--purple) !important; }
.bg-primary { background-color: var(--purple) !important; }
.border-primary { border-color: var(--purple) !important; }

.navbar {
  background: rgba(252, 248, 248, 0.9) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border-bottom-color: rgba(93, 33, 208, 0.10) !important;
}

.card, .glass, .stat-card, .job-card, .table-wrap {
  border-radius: var(--radius) !important;
  background: var(--bg-card) !important;
  border: 1px solid rgba(255, 255, 255, 0.4) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
}

.btn-primary {
  background: var(--purple) !important;
  border-color: var(--purple) !important;
  color: #ffffff !important;
}

.btn-primary:hover, .btn-primary:focus {
  background: var(--purple-dark) !important;
  border-color: var(--purple-dark) !important;
  color: #ffffff !important;
}

.btn-ghost, .btn-icon {
  background: rgba(255, 255, 255, 0.75) !important;
  border-color: rgba(93, 33, 208, 0.14) !important;
}

.btn-ghost:hover, .btn-icon:hover {
  background: rgba(255, 255, 255, 0.88) !important;
  border-color: rgba(93, 33, 208, 0.28) !important;
}

a { color: rgba(28, 27, 27, 0.88); }
a:hover { color: var(--purple) !important; }
.candidate-name-link:hover { color: var(--purple) !important; }
.candidate-name-link::after { background: var(--purple) !important; }

.form-control:focus, .form-select:focus {
  border-color: var(--purple) !important;
  box-shadow: 0 0 0 4px rgba(93, 33, 208, 0.12) !important;
  background: rgba(255, 255, 255, 0.9) !important;
}

.table-head, .results-table th {
  background: rgba(255, 255, 255, 0.55) !important;
  border-bottom-color: rgba(93, 33, 208, 0.12) !important;
}

.results-table td {
  border-bottom-color: rgba(28, 27, 27, 0.08) !important;
}

.results-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.65) !important;
}

.job-category {
  color: var(--purple) !important;
  border-color: rgba(93, 33, 208, 0.18) !important;
  background: rgba(93, 33, 208, 0.07) !important;
}

.insight-card {
  background: var(--bg-card) !important;
  border: 1px solid rgba(255, 255, 255, 0.4) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
}

.insight-card::before { background: var(--purple) !important; }
.insight-label { color: #6c757d !important; }
.insight-value { color: #1c1b1b !important; text-shadow: none !important; }
.insight-meta { color: var(--purple) !important; }

.insight-icon {
  background: rgba(93, 33, 208, 0.1) !important;
  color: var(--purple) !important;
  border: none !important;
  box-shadow: none !important;
}

.section-title i { color: var(--purple); }
.text-cyan { color: var(--purple); }
.admin-title, .gradient-text, .text-gradient, [class*="gradient"] {
  color: var(--purple) !important;
  -webkit-text-fill-color: initial !important;
  background: none !important;
}



/* ============================================================
   RESPONSIVE DESIGN PATCH FOR TABLETS AND PHONES
   ============================================================ */

@media (max-width: 992px) {
  /* Prevent chart containers from becoming completely squished */
  .chart-container {
    height: 260px !important;
  }
}

@media (max-width: 768px) {
  /* Re-align cards from desktop-centric centering definitions */
  .insight-card {
    min-width: 100% !important;
    padding: 1.5rem 1rem !important;
    margin-bottom: 0 !important;
  }


  /* Optimize font structures so titles don't overflow on small screens */
  .insight-value {
    font-size: 1.2rem !important;
  }

  .insight-meta,
  .insight-value.text-gradient,
  .insight-value.gradient-text,
  .insight-card:nth-child(3) .insight-value {
    font-size: 1.25rem !important;
  }
  
  /* Fix navbar internal alignment */
  .nav-actions {
    width: 100%;
    justify-content: space-between;
  }

  .row .stat-card:first-child .stat-value.text-gradient {
    font-size: 1.75rem !important; }
}

@media (max-width: 480px) {
  .chart-container {
    height: 220px !important;
  }
  
  /* Give the body clean breathing room on sides */
  .container {
    padding-left: 15px !important;
    padding-right: 15px !important;
  }
}