/* ============================================================
   Career Time Machine™ — Premium Glassmorphism Dark UI
   Design system: purple-blue gradient, glass cards, dark bg
   ============================================================ */

/* ── Reset / Base ─────────────────────────────────────────── */
#ctm-overlay *,
#ctm-overlay *::before,
#ctm-overlay *::after {
  box-sizing: border-box;
}

/* ── 1. #ctm-overlay ──────────────────────────────────────── */
#ctm-overlay {
  position: fixed;
  inset: 0;
  z-index: 9000;
  background-color: #060614;
  overflow-y: auto;
  overflow-x: hidden;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  scrollbar-width: thin;
  scrollbar-color: rgba(124, 58, 237, 0.4) transparent;
}

#ctm-overlay::-webkit-scrollbar {
  width: 6px;
}

#ctm-overlay::-webkit-scrollbar-track {
  background: transparent;
}

#ctm-overlay::-webkit-scrollbar-thumb {
  background: rgba(124, 58, 237, 0.4);
  border-radius: 3px;
}

#ctm-overlay.is-open {
  opacity: 1;
  pointer-events: all;
}

/* Animated gradient orbs */
#ctm-overlay::before,
#ctm-overlay::after {
  content: "";
  position: fixed;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
  filter: blur(80px);
  animation: ctmFloat 18s ease-in-out infinite;
}

#ctm-overlay::before {
  width: 600px;
  height: 600px;
  top: -150px;
  left: -150px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.28) 0%, transparent 70%);
  animation-delay: 0s;
}

#ctm-overlay::after {
  width: 500px;
  height: 500px;
  bottom: -100px;
  right: -100px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.24) 0%, transparent 70%);
  animation-delay: -9s;
  animation-direction: reverse;
}

/* ── 2. .ctm-container ────────────────────────────────────── */
.ctm-container {
  position: relative;
  z-index: 1;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 1.5rem 4rem;
  min-height: 100vh;
}

/* ── 3. .ctm-header ───────────────────────────────────────── */
.ctm-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.5rem;
  margin: 0 -1.5rem;
  background: rgba(6, 6, 20, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.ctm-header-left {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.ctm-title {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #a78bfa 0%, #60a5fa 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-wrap: balance;
  margin: 0;
}

.ctm-subtitle {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.42);
  letter-spacing: 0.01em;
  margin: 0;
}

.ctm-close-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: rgba(255, 255, 255, 0.7);
  font-size: 1.1rem;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, transform 0.2s, border-color 0.2s;
  flex-shrink: 0;
  outline: none;
  line-height: 1;
}

.ctm-close-btn:hover {
  background: rgba(167, 139, 250, 0.15);
  border-color: rgba(167, 139, 250, 0.35);
  color: #a78bfa;
  transform: rotate(90deg);
}

.ctm-close-btn:focus-visible {
  outline: 2px solid #a78bfa;
  outline-offset: 2px;
}

/* ── 4. .ctm-setup ────────────────────────────────────────── */
.ctm-setup {
  max-width: 700px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
}

.ctm-step {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: 16px;
  padding: 2rem;
  margin-bottom: 1.5rem;
  animation: ctmFadeIn 0.4s ease both;
}

.ctm-step:nth-child(2) { animation-delay: 0.08s; }
.ctm-step:nth-child(3) { animation-delay: 0.16s; }

.ctm-step-label {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #a78bfa;
  margin-bottom: 0.5rem;
}

.ctm-step-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.92);
  margin: 0 0 1.25rem;
  text-wrap: balance;
}

/* Search */
.ctm-search-wrap {
  position: relative;
  margin-bottom: 0.25rem;
}

.ctm-search-icon {
  position: absolute;
  left: 0.875rem;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(167, 139, 250, 0.6);
  font-size: 0.95rem;
  pointer-events: none;
  line-height: 1;
}

.ctm-search {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.95rem;
  padding: 0.75rem 1rem 0.75rem 2.5rem;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
  font-family: inherit;
}

.ctm-search::placeholder {
  color: rgba(255, 255, 255, 0.28);
}

.ctm-search:focus {
  border-color: rgba(167, 139, 250, 0.5);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.18);
  background: rgba(255, 255, 255, 0.07);
}

/* Dropdown — inline scrollable list, always visible after build */
.ctm-dropdown {
  position: relative;
  margin-top: 8px;
  background: rgba(15, 12, 35, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  max-height: 260px;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: rgba(124, 58, 237, 0.3) transparent;
}

.ctm-dropdown::-webkit-scrollbar {
  width: 4px;
}

.ctm-dropdown::-webkit-scrollbar-thumb {
  background: rgba(124, 58, 237, 0.3);
  border-radius: 2px;
}

.ctm-dropdown.is-open {
  display: block;
}

.ctm-cat-group {
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.ctm-cat-group:last-child {
  border-bottom: none;
}

.ctm-cat-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.6rem 1rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #a78bfa;
  cursor: pointer;
  user-select: none;
  transition: background 0.15s;
}

.ctm-cat-label:hover {
  background: rgba(167, 139, 250, 0.08);
}

.ctm-cat-label::after {
  content: "›";
  font-size: 1rem;
  font-weight: 400;
  color: rgba(167, 139, 250, 0.5);
  transition: transform 0.2s;
  line-height: 1;
}

.ctm-cat-label.is-open::after {
  transform: rotate(90deg);
}

.ctm-profession-list {
  display: none;
  list-style: none;
  margin: 0;
  padding: 0 0 0.25rem;
}

.ctm-profession-list.is-open {
  display: block;
}

.ctm-profession-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.55rem 1rem 0.55rem 1.5rem;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.72);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  gap: 0.5rem;
}

.ctm-profession-item:hover {
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.92);
}

.ctm-profession-item.is-selected {
  color: #a78bfa;
}

.ctm-profession-item.is-selected::after {
  content: "✓";
  font-size: 0.8rem;
  color: #a78bfa;
  flex-shrink: 0;
}

/* Stage grid */
.ctm-stage-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.ctm-stage-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 1.1rem 0.75rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid transparent;
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, box-shadow 0.2s, transform 0.15s;
  text-align: center;
  user-select: none;
}

.ctm-stage-card:hover {
  background: rgba(167, 139, 250, 0.08);
  border-color: rgba(167, 139, 250, 0.2);
  transform: translateY(-2px);
}

.ctm-stage-card.is-selected {
  background: rgba(124, 58, 237, 0.12);
  border-color: rgba(167, 139, 250, 0.5);
  box-shadow: 0 0 20px rgba(124, 58, 237, 0.2), inset 0 0 12px rgba(124, 58, 237, 0.08);
}

.ctm-stage-icon {
  font-size: 1.75rem;
  line-height: 1;
}

.ctm-stage-name {
  font-size: 0.75rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.72);
  letter-spacing: 0.01em;
  line-height: 1.2;
}

.ctm-stage-card.is-selected .ctm-stage-name {
  color: #a78bfa;
}

/* Slider */
.ctm-slider-wrap {
  position: relative;
  padding: 0.75rem 0 0.25rem;
}

.ctm-slider-value {
  text-align: center;
  font-size: 2.25rem;
  font-weight: 900;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, #a78bfa 0%, #60a5fa 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.75rem;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.ctm-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: linear-gradient(90deg, #7c3aed 0%, #2563eb 100%);
  outline: none;
  cursor: pointer;
  margin: 0.25rem 0;
}

.ctm-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: linear-gradient(135deg, #a78bfa, #60a5fa);
  border: 2px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 0 12px rgba(124, 58, 237, 0.5);
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}

.ctm-slider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
  box-shadow: 0 0 20px rgba(124, 58, 237, 0.7);
}

.ctm-slider::-moz-range-thumb {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: linear-gradient(135deg, #a78bfa, #60a5fa);
  border: 2px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 0 12px rgba(124, 58, 237, 0.5);
  cursor: pointer;
}

.ctm-slider::-moz-range-track {
  height: 6px;
  border-radius: 3px;
  background: linear-gradient(90deg, #7c3aed 0%, #2563eb 100%);
}

.ctm-slider:focus-visible::-webkit-slider-thumb {
  outline: 2px solid #a78bfa;
  outline-offset: 2px;
}

.ctm-slider-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.35);
  margin-top: 0.35rem;
  font-variant-numeric: tabular-nums;
}

/* Next button */
.ctm-next-btn {
  display: block;
  width: 100%;
  padding: 0.875rem 1.5rem;
  background: linear-gradient(135deg, #7c3aed, #2563eb);
  border: none;
  border-radius: 12px;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  letter-spacing: 0.02em;
  transition: transform 0.18s, box-shadow 0.18s, filter 0.18s;
  outline: none;
  margin-top: 1.25rem;
  box-shadow: 0 4px 20px rgba(124, 58, 237, 0.3);
}

.ctm-next-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(124, 58, 237, 0.45);
  filter: brightness(1.08);
}

.ctm-next-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 10px rgba(124, 58, 237, 0.25);
}

.ctm-next-btn:focus-visible {
  outline: 2px solid #a78bfa;
  outline-offset: 3px;
}

/* Step dots */
.ctm-step-dots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  margin-top: 1.5rem;
}

.ctm-step-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
  transition: background 0.2s, width 0.2s;
}

.ctm-step-dot.is-active {
  background: linear-gradient(135deg, #a78bfa, #60a5fa);
  width: 22px;
  border-radius: 4px;
}

/* ── 5. .ctm-main ─────────────────────────────────────────── */
.ctm-main {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 1.5rem;
  padding-top: 1.5rem;
  align-items: start;
}

.ctm-main-left {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  position: sticky;
  top: 80px;
  max-height: calc(100vh - 100px);
  overflow-y: auto;
  scrollbar-width: none;
}

.ctm-main-left::-webkit-scrollbar {
  display: none;
}

.ctm-main-right {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-width: 0;
}

/* ── 6. .ctm-year-strip ───────────────────────────────────── */
.ctm-year-strip-wrap {
  position: relative;
}

.ctm-year-strip-wrap::before,
.ctm-year-strip-wrap::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 40px;
  z-index: 2;
  pointer-events: none;
}

.ctm-year-strip-wrap::before {
  left: 0;
  background: linear-gradient(to right, #060614, transparent);
}

.ctm-year-strip-wrap::after {
  right: 0;
  background: linear-gradient(to left, #060614, transparent);
}

.ctm-year-strip {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding: 0.5rem 0.75rem;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
}

.ctm-year-strip::-webkit-scrollbar {
  display: none;
}

.ctm-year-pill {
  flex-shrink: 0;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition: background 0.18s, color 0.18s, border-color 0.18s, box-shadow 0.18s;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  user-select: none;
}

.ctm-year-pill:hover {
  background: rgba(167, 139, 250, 0.1);
  color: rgba(255, 255, 255, 0.8);
  border-color: rgba(167, 139, 250, 0.25);
}

.ctm-year-pill.is-active {
  background: linear-gradient(135deg, #7c3aed, #2563eb);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 2px 12px rgba(124, 58, 237, 0.35);
}

/* ── 7. .ctm-cards-grid ───────────────────────────────────── */
.ctm-cards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.875rem;
  margin-bottom: 0.25rem;
}

.ctm-stat-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: 16px;
  padding: 1.25rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.ctm-stat-card:hover {
  border-color: rgba(167, 139, 250, 0.2);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.ctm-stat-value {
  font-size: 2rem;
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1;
  background: linear-gradient(135deg, #a78bfa 0%, #60a5fa 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-variant-numeric: tabular-nums;
  margin-bottom: 0.3rem;
  transition: all 0.4s ease;
}

.ctm-stat-label {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.38);
  letter-spacing: 0.03em;
  font-weight: 500;
}

/* ── 8. .ctm-section-card ─────────────────────────────────── */
.ctm-section-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: 16px;
  padding: 1.5rem;
  margin-bottom: 0;
  animation: ctmFadeIn 0.35s ease both;
}

.ctm-section-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 1rem;
  letter-spacing: 0.01em;
}

.ctm-section-title-icon {
  font-size: 1rem;
  line-height: 1;
}

/* Skill pills */
.ctm-skills-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.ctm-skill-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
  background: rgba(124, 58, 237, 0.14);
  border: 1px solid rgba(167, 139, 250, 0.25);
  color: #a78bfa;
  letter-spacing: 0.01em;
  transition: background 0.18s, box-shadow 0.18s;
}

.ctm-skill-pill:hover {
  background: rgba(124, 58, 237, 0.22);
}

.ctm-skill-pill.is-new {
  background: rgba(52, 211, 153, 0.1);
  border-color: #34d399;
  color: #34d399;
  animation: ctmNewSkill 0.6s ease both;
}

/* Cert items */
.ctm-cert-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.6rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.ctm-cert-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.ctm-cert-icon {
  font-size: 1rem;
  line-height: 1.4;
  flex-shrink: 0;
}

.ctm-cert-info {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.ctm-cert-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.82);
}

.ctm-cert-meta {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.38);
}

/* Achievement items */
.ctm-achievement-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.6rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.ctm-achievement-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.ctm-achievement-badge {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.25), rgba(37, 99, 235, 0.25));
  border: 1px solid rgba(167, 139, 250, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  color: #a78bfa;
  font-variant-numeric: tabular-nums;
}

.ctm-achievement-text {
  font-size: 0.84rem;
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.4;
  padding-top: 0.25rem;
}

/* ── 9. .ctm-roadmap ──────────────────────────────────────── */
.ctm-roadmap {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0.25rem 0;
}

.ctm-rm-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  position: relative;
}

.ctm-rm-track {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
  width: 20px;
}

.ctm-rm-dot {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 800;
  transition: background 0.2s, border-color 0.2s;
  z-index: 1;
}

.ctm-rm-dot.is-done {
  background: linear-gradient(135deg, #34d399, #059669);
  border: 2px solid rgba(52, 211, 153, 0.4);
  color: #fff;
  box-shadow: 0 0 10px rgba(52, 211, 153, 0.3);
}

.ctm-rm-dot.is-future {
  background: transparent;
  border: 2px solid rgba(255, 255, 255, 0.18);
  color: rgba(255, 255, 255, 0.25);
}

.ctm-rm-line {
  width: 2px;
  flex: 1;
  min-height: 24px;
  background: rgba(255, 255, 255, 0.08);
  margin: 2px 0;
}

.ctm-rm-content {
  flex: 1;
  padding-bottom: 1.25rem;
  min-width: 0;
}

.ctm-rm-item:last-child .ctm-rm-content {
  padding-bottom: 0;
}

.ctm-rm-title {
  font-size: 0.875rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.82);
  margin-bottom: 0.2rem;
  line-height: 1.3;
}

.ctm-rm-title.is-future {
  color: rgba(255, 255, 255, 0.35);
}

.ctm-rm-year {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 6px;
  background: rgba(124, 58, 237, 0.14);
  border: 1px solid rgba(167, 139, 250, 0.2);
  color: #a78bfa;
  font-variant-numeric: tabular-nums;
}

.ctm-rm-year.is-future {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.3);
}

/* ── 10. .ctm-chart-card ──────────────────────────────────── */
.ctm-chart-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: 16px;
  padding: 1.25rem;
}

.ctm-chart-title {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.38);
  margin-bottom: 0.75rem;
}

canvas.ctm-chart {
  width: 100% !important;
  height: 160px !important;
  border-radius: 8px;
  display: block;
}

/* ── 11. .ctm-preview-panel ───────────────────────────────── */
.ctm-preview-panel {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: 16px;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.ctm-preview-header {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.ctm-preview-name {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 900;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #a78bfa 0%, #60a5fa 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.1;
  margin: 0;
}

.ctm-preview-title {
  font-size: 1rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.55);
  margin: 0;
}

.ctm-preview-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.25rem;
}

.ctm-preview-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.7);
  letter-spacing: 0.02em;
}

.ctm-preview-badge.is-open {
  background: rgba(52, 211, 153, 0.1);
  border-color: rgba(52, 211, 153, 0.3);
  color: #34d399;
}

.ctm-preview-badge.is-senior {
  background: rgba(245, 158, 11, 0.1);
  border-color: rgba(245, 158, 11, 0.3);
  color: #f59e0b;
}

.ctm-preview-bio {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.5);
  font-style: italic;
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
}

.ctm-preview-stats {
  display: flex;
  gap: 0;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  overflow: hidden;
}

.ctm-preview-stat {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.875rem 0.5rem;
  gap: 0.2rem;
  border-right: 1px solid rgba(255, 255, 255, 0.07);
}

.ctm-preview-stat:last-child {
  border-right: none;
}

.ctm-preview-stat-value {
  font-size: 1.35rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  color: #fff;
  font-variant-numeric: tabular-nums;
}

.ctm-preview-stat-label {
  font-size: 0.68rem;
  color: rgba(255, 255, 255, 0.35);
  text-align: center;
  line-height: 1.2;
}

.ctm-preview-skills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.ctm-preview-projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

.ctm-preview-proj {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 1rem;
  transition: border-color 0.2s, background 0.2s;
}

.ctm-preview-proj:hover {
  background: rgba(167, 139, 250, 0.07);
  border-color: rgba(167, 139, 250, 0.2);
}

.ctm-preview-proj-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.82);
  margin-bottom: 0.25rem;
}

.ctm-preview-proj-meta {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.35);
}

.ctm-preview-achievements {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.ctm-preview-achievement {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.84rem;
  color: rgba(255, 255, 255, 0.65);
}

.ctm-preview-achievement-icon {
  font-size: 0.9rem;
  line-height: 1.35;
  flex-shrink: 0;
}

/* ── 12. .ctm-motivational ────────────────────────────────── */
.ctm-motivational {
  border-radius: 16px;
  padding: 1.75rem;
  text-align: center;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(167, 139, 250, 0.2);
  position: relative;
  overflow: hidden;
  animation: ctmFadeIn 0.4s ease both;
}

.ctm-motivational::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.06) 0%, rgba(37, 99, 235, 0.06) 100%);
  pointer-events: none;
}

.ctm-motivational-emoji {
  font-size: 2rem;
  display: block;
  margin-bottom: 0.75rem;
  line-height: 1;
}

.ctm-motivational-quote {
  font-size: 1.05rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.5;
  margin: 0;
  font-style: italic;
  position: relative;
}

.ctm-motivational.is-peak {
  border-color: rgba(245, 158, 11, 0.45);
  box-shadow: 0 0 40px rgba(245, 158, 11, 0.1), inset 0 0 30px rgba(245, 158, 11, 0.04);
}

.ctm-motivational.is-peak::before {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.07) 0%, rgba(251, 191, 36, 0.05) 100%);
}

/* ── 13. .ctm-celebration ─────────────────────────────────── */
.ctm-celebration {
  display: none;
  position: absolute;
  inset: 0;
  z-index: 100;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background: rgba(6, 6, 20, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.ctm-celebration.is-visible {
  display: flex;
  animation: ctmFadeIn 0.4s ease both;
}

.ctm-celebration-canvas {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.ctm-celebration-card {
  position: relative;
  z-index: 1;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(167, 139, 250, 0.35);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 20px;
  padding: 3rem 2.5rem;
  text-align: center;
  max-width: 480px;
  width: 100%;
  box-shadow: 0 0 60px rgba(124, 58, 237, 0.2), 0 40px 80px rgba(0, 0, 0, 0.4);
  animation: ctmCelebScale 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

.ctm-celebration-emoji {
  font-size: 3.5rem;
  display: block;
  margin-bottom: 1rem;
  line-height: 1;
}

.ctm-celebration-title {
  font-size: 1.75rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #a78bfa 0%, #60a5fa 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.75rem;
}

.ctm-celebration-body {
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.6;
  margin-bottom: 1.75rem;
}

.ctm-celebration-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 2rem;
  border-radius: 10px;
  background: linear-gradient(135deg, #7c3aed, #2563eb);
  border: none;
  color: #fff;
  font-size: 0.9rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
  box-shadow: 0 4px 20px rgba(124, 58, 237, 0.35);
  outline: none;
}

.ctm-celebration-close:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(124, 58, 237, 0.5);
}

.ctm-celebration-close:focus-visible {
  outline: 2px solid #a78bfa;
  outline-offset: 3px;
}

/* ── 14. .ctm-reset-btn ───────────────────────────────────── */
.ctm-reset-btn {
  display: block;
  margin: 2rem auto 0;
  padding: 0.65rem 1.75rem;
  border-radius: 10px;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.82rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
  letter-spacing: 0.02em;
  outline: none;
}

.ctm-reset-btn:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.22);
  color: rgba(255, 255, 255, 0.65);
}

.ctm-reset-btn:focus-visible {
  outline: 2px solid rgba(167, 139, 250, 0.6);
  outline-offset: 3px;
}

/* ── 15. .ctm-goals-list ──────────────────────────────────── */
.ctm-goals-list {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  padding: 0.25rem 0;
}

.ctm-goal-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.ctm-goal-year {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.6rem;
  border-radius: 8px;
  background: rgba(124, 58, 237, 0.14);
  border: 1px solid rgba(167, 139, 250, 0.22);
  color: #a78bfa;
  font-size: 0.72rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  margin-top: 0.1rem;
}

.ctm-goal-text {
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.68);
  line-height: 1.45;
}

/* ── Divider utility ──────────────────────────────────────── */
.ctm-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.07);
  border: none;
  margin: 0;
}

/* ── Empty / loading state ────────────────────────────────── */
.ctm-empty {
  text-align: center;
  padding: 2.5rem 1rem;
  color: rgba(255, 255, 255, 0.28);
  font-size: 0.875rem;
}

.ctm-empty-icon {
  font-size: 2rem;
  display: block;
  margin-bottom: 0.5rem;
  opacity: 0.5;
}

/* ── 16. Responsive ───────────────────────────────────────── */
@media (max-width: 991px) {
  .ctm-main {
    grid-template-columns: 1fr;
  }

  .ctm-main-left {
    position: static;
    max-height: none;
    overflow-y: visible;
  }

  .ctm-cards-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .ctm-stage-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 576px) {
  .ctm-container {
    padding: 0 1rem 3rem;
  }

  .ctm-header {
    padding: 0.875rem 1rem;
    margin: 0 -1rem;
  }

  .ctm-setup {
    padding: 1.75rem 0;
  }

  .ctm-step {
    padding: 1.25rem;
  }

  .ctm-cards-grid {
    grid-template-columns: 1fr;
  }

  .ctm-stage-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .ctm-preview-panel {
    padding: 1.25rem;
  }

  .ctm-preview-projects-grid {
    grid-template-columns: 1fr;
  }

  .ctm-celebration-card {
    padding: 2rem 1.5rem;
  }

  .ctm-motivational {
    padding: 1.25rem;
  }

  .ctm-preview-stats {
    flex-direction: column;
  }

  .ctm-preview-stat {
    border-right: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    flex-direction: row;
    justify-content: space-between;
    padding: 0.65rem 1rem;
  }

  .ctm-preview-stat:last-child {
    border-bottom: none;
  }
}

/* ── 17. Keyframe Animations ──────────────────────────────── */
@keyframes ctmFadeIn {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes ctmPulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.4);
    border-color: rgba(52, 211, 153, 0.5);
  }
  50% {
    box-shadow: 0 0 0 6px rgba(52, 211, 153, 0);
    border-color: rgba(52, 211, 153, 0.9);
  }
}

@keyframes ctmFloat {
  0%, 100% {
    transform: translate(0, 0) scale(1);
  }
  33% {
    transform: translate(40px, -30px) scale(1.05);
  }
  66% {
    transform: translate(-20px, 20px) scale(0.97);
  }
}

@keyframes ctmNewSkill {
  0% {
    transform: scale(1.1);
    box-shadow: 0 0 16px rgba(52, 211, 153, 0.6);
    border-color: #34d399;
  }
  60% {
    transform: scale(1.02);
    box-shadow: 0 0 8px rgba(52, 211, 153, 0.3);
  }
  100% {
    transform: scale(1);
    box-shadow: none;
  }
}

@keyframes ctmCelebScale {
  0% {
    opacity: 0;
    transform: scale(0.7);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

/* Applied to skill pills that are new — pulsing green border */
.ctm-skill-pill.is-new {
  animation: ctmNewSkill 0.6s ease both, ctmPulse 2s ease-in-out 0.6s 3;
}

/* Reduce motion overrides */
@media (prefers-reduced-motion: reduce) {
  #ctm-overlay::before,
  #ctm-overlay::after {
    animation: none;
  }

  .ctm-step,
  .ctm-section-card,
  .ctm-motivational,
  .ctm-celebration,
  .ctm-celebration-card {
    animation: none;
  }

  .ctm-skill-pill.is-new {
    animation: none;
  }

  .ctm-close-btn:hover {
    transform: none;
  }

  .ctm-stage-card:hover,
  .ctm-next-btn:hover,
  .ctm-celebration-close:hover {
    transform: none;
  }

  .ctm-slider::-webkit-slider-thumb:hover {
    transform: none;
  }

  #ctm-overlay {
    transition: none;
  }
}
