/* ─── CSS Variables ─── */
:root {
  --bg:       #0d0f1a;
  --surface:  #151826;
  --surface2: #1c2035;
  --border:   #262b44;
  --accent:   #6c63ff;
  --accent2:  #00d4aa;
  --warn:     #f5a623;
  --danger:   #ff5e7e;
  --text:     #e8eaf6;
  --muted:    #7b82a0;
  --radius:   14px;
}

/* ─── Reset ─── */
* { margin: 0; padding: 0; box-sizing: border-box; }

/* ─── Body ─── */
body {
  font-family: 'Space Grotesk', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  padding: 40px 16px 80px;
}

/* ─── Header ─── */
.header {
  text-align: center;
  margin-bottom: 36px;
}
.header .badge {
  display: inline-block;
  background: rgba(108,99,255,.15);
  border: 1px solid rgba(108,99,255,.35);
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 100px;
  margin-bottom: 14px;
}
.header h1 {
  font-size: clamp(28px, 5vw, 42px);
  font-weight: 700;
  letter-spacing: -1px;
  background: linear-gradient(135deg, #fff 30%, var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.header p {
  color: var(--muted);
  margin-top: 8px;
  font-size: 15px;
}

/* ─── Page Layout ─── */
.page {
  max-width: 780px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* ─── Cards ─── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
}

/* ─── Form Grid ─── */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
@media (max-width: 560px) {
  .form-grid { grid-template-columns: 1fr; }
}

/* ─── Form Fields ─── */
.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.field label {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .8px;
}
.field input,
.field select,
.field textarea {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 16px;
  color: var(--text);
  font-family: inherit;
  font-size: 15px;
  transition: border-color .2s, box-shadow .2s;
  width: 100%;
}
.field select option { background: var(--surface2); }
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(108,99,255,.18);
}
.field input::placeholder,
.field textarea::placeholder { color: var(--muted); }
.hint {
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

/* ─── Experience Pills ─── */
.xp-pills {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.xp-pill {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 7px 16px;
  font-size: 13px;
  cursor: pointer;
  transition: all .2s;
  color: var(--muted);
  user-select: none;
}
.xp-pill.active {
  background: rgba(108,99,255,.2);
  border-color: var(--accent);
  color: var(--accent);
  font-weight: 600;
}

/* ─── Analyze Button ─── */
.btn-analyze {
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, var(--accent), #9b59b6);
  border: none;
  border-radius: 10px;
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  font-family: inherit;
  letter-spacing: .3px;
  cursor: pointer;
  transition: transform .2s, opacity .2s;
  margin-top: 8px;
}
.btn-analyze:hover { transform: translateY(-2px); opacity: .92; }
.btn-analyze:active { transform: translateY(0); }

/* ─── Results Box ─── */
#resultsBox {
  display: none;
  animation: fadeUp .4s ease;
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ─── Score Ring ─── */
.score-row {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 24px;
}
.ring-wrap {
  position: relative;
  width: 90px;
  height: 90px;
  flex-shrink: 0;
}
.ring-wrap svg { transform: rotate(-90deg); }
.ring-bg  { fill: none; stroke: var(--border); stroke-width: 8; }
.ring-fill {
  fill: none;
  stroke-width: 8;
  stroke-linecap: round;
  transition: stroke-dashoffset 1s cubic-bezier(.4,0,.2,1);
}
.ring-label {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.ring-label .pct { font-size: 20px; font-weight: 700; }
.ring-label .sub { font-size: 10px; color: var(--muted); }
.score-info h2 { font-size: 22px; font-weight: 700; margin-bottom: 4px; }
.score-info p  { color: var(--muted); font-size: 14px; line-height: 1.5; }

/* ─── Skill Chips ─── */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.chip {
  padding: 5px 12px;
  border-radius: 100px;
  font-size: 13px;
  font-weight: 600;
  font-family: 'DM Mono', monospace;
}
.chip.have { background: rgba(0,212,170,.12); color: var(--accent2); border: 1px solid rgba(0,212,170,.25); }
.chip.miss { background: rgba(255,94,126,.12); color: var(--danger);  border: 1px solid rgba(255,94,126,.25); }

/* ─── Section Titles ─── */
.sec-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}

/* ─── Roadmap ─── */
.roadmap { display: flex; flex-direction: column; }
.rm-step {
  display: flex;
  gap: 16px;
  padding-bottom: 20px;
  position: relative;
}
.rm-step:last-child { padding-bottom: 0; }
.rm-left {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.rm-dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  flex-shrink: 0;
}
.rm-line {
  width: 2px;
  flex: 1;
  background: var(--border);
  margin-top: 6px;
}
.rm-step:last-child .rm-line { display: none; }
.rm-content { padding-top: 4px; }
.rm-content h4 { font-size: 15px; font-weight: 600; margin-bottom: 4px; }
.rm-content p  { font-size: 13px; color: var(--muted); line-height: 1.5; }
.rm-badge {
  display: inline-block;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 100px;
  margin-bottom: 4px;
  font-weight: 600;
}

/* ─── Resource Grid ─── */
.res-grid { display: flex; flex-direction: column; gap: 10px; }
.res-row {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.res-skill {
  font-weight: 600;
  font-size: 15px;
  font-family: 'DM Mono', monospace;
}
.res-links { display: flex; gap: 8px; flex-wrap: wrap; }
.res-link {
  padding: 5px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  transition: opacity .2s, transform .2s;
}
.res-link:hover { opacity: .8; transform: translateY(-1px); }
.res-link.learn { background: rgba(108,99,255,.2); color: var(--accent); border: 1px solid rgba(108,99,255,.3); }
.res-link.cert  { background: rgba(0,212,170,.15); color: var(--accent2); border: 1px solid rgba(0,212,170,.3); }

/* ─── Alternative Roles ─── */
.alt-roles { display: flex; flex-direction: column; gap: 8px; }
.alt-card {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 18px;
  transition: border-color .2s;
}
.alt-card:hover { border-color: var(--warn); }
.alt-card h4 { font-size: 15px; font-weight: 600; color: var(--warn); margin-bottom: 3px; }
.alt-card p  { font-size: 13px; color: var(--muted); }

/* ─── Motivational Banner ─── */
.motive {
  background: linear-gradient(135deg, rgba(108,99,255,.15), rgba(0,212,170,.08));
  border: 1px solid rgba(108,99,255,.25);
  border-radius: var(--radius);
  padding: 20px 24px;
  font-size: 15px;
  line-height: 1.6;
  text-align: center;
  color: var(--text);
}

/* ─── Toggle Button ─── */
.btn-toggle {
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 10px;
  padding: 12px;
  width: 100%;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: border-color .2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.btn-toggle:hover { border-color: var(--accent); }

/* ─── Feedback Card ─── */
.feedback-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  display: none;
}
.feedback-card h3 {
  margin-bottom: 18px;
  font-size: 18px;
}
.feedback-card textarea { resize: vertical; min-height: 100px; }

/* ─── Submit Button ─── */
.btn-submit {
  background: var(--accent);
  border: none;
  border-radius: 10px;
  color: #fff;
  padding: 12px 24px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  width: 100%;
  margin-top: 4px;
  transition: opacity .2s;
}
.btn-submit:hover { opacity: .85; }

/* ─── Footer Notice ─── */
.notice {
  font-size: 13px;
  color: var(--muted);
  text-align: center;
  padding: 12px;
  background: var(--surface2);
  border-radius: 10px;
  line-height: 1.6;
}
