/* ────────────────────────────────────────────
   Reset & 기본 설정
──────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --primary:       #6366f1;
  --primary-dark:  #4f46e5;
  --primary-light: #e0e7ff;
  --accent:        #06b6d4;
  --success:       #10b981;
  --warning:       #f59e0b;
  --danger:        #ef4444;
  --bg:            #f8fafc;
  --surface:       #ffffff;
  --border:        #e2e8f0;
  --text-main:     #1e293b;
  --text-muted:    #64748b;
  --radius:        14px;
  --shadow-sm:     0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
  --shadow-md:     0 4px 16px rgba(0,0,0,.08);
  --shadow-lg:     0 8px 32px rgba(0,0,0,.10);
  --transition:    .2s ease;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Segoe UI', 'Apple SD Gothic Neo', sans-serif;
  background: var(--bg);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
}

/* ────────────────────────────────────────────
   헤더
──────────────────────────────────────────── */
.site-header {
  background: linear-gradient(135deg, #4f46e5 0%, #6366f1 50%, #06b6d4 100%);
  color: #fff;
  padding: 18px 24px;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 12px rgba(79,70,229,.3);
}

.header-inner {
  max-width: 820px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -.5px;
}

.logo-icon { font-size: 1.4rem; }

.header-tagline {
  font-size: .85rem;
  opacity: .85;
}

/* ────────────────────────────────────────────
   레이아웃
──────────────────────────────────────────── */
.container {
  max-width: 820px;
  margin: 0 auto;
  padding: 32px 16px 64px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.hidden { display: none !important; }

/* ────────────────────────────────────────────
   히어로
──────────────────────────────────────────── */
.hero {
  text-align: center;
  padding: 12px 0 4px;
}

.hero-title {
  font-size: clamp(1.5rem, 4vw, 2.1rem);
  font-weight: 800;
  letter-spacing: -1px;
  background: linear-gradient(135deg, #4f46e5, #06b6d4);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 12px;
}

.hero-desc {
  font-size: .97rem;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ────────────────────────────────────────────
   카드 공통
──────────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  padding: 28px 28px 32px;
}

/* ────────────────────────────────────────────
   위자드 헤더 (진행 바)
──────────────────────────────────────────── */
.wizard-header {
  margin-bottom: 28px;
  padding-bottom: 24px;
  border-bottom: 2px solid var(--primary-light);
}

.step-indicators {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
}

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

.step-dot {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .9rem;
  font-weight: 700;
  background: var(--border);
  color: var(--text-muted);
  border: 2.5px solid var(--border);
  transition: background .35s ease, color .35s ease, border-color .35s ease,
              box-shadow .35s ease, transform .25s ease;
}

.step-indicator.active .step-dot {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  box-shadow: 0 0 0 5px rgba(99,102,241,.18);
  transform: scale(1.08);
}

.step-indicator.done .step-dot {
  background: var(--success);
  color: #fff;
  border-color: var(--success);
}

.step-indicator.done .step-dot span::before {
  content: '✓';
}

.step-indicator.done .step-dot span {
  font-size: 0; /* 숫자 숨기기 */
}

.step-label {
  font-size: .75rem;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
  transition: color .3s ease;
}

.step-indicator.active .step-label { color: var(--primary-dark); }
.step-indicator.done  .step-label  { color: var(--success); }

/* 커넥터 */
.step-connector {
  flex: 1;
  height: 3px;
  background: var(--border);
  border-radius: 2px;
  margin: 0 8px;
  margin-bottom: 24px; /* step-label 높이 보정 */
  overflow: hidden;
  position: relative;
}

.connector-fill {
  height: 100%;
  width: 0%;
  background: var(--success);
  border-radius: 2px;
  transition: width .45s ease;
}

.connector-fill.filled { width: 100%; }

/* ────────────────────────────────────────────
   스텝 패널 (폼 단계)
──────────────────────────────────────────── */
.form-steps-wrap {
  overflow: hidden;
}

.step-panel {
  display: none;
}

.step-panel.active {
  display: block;
  animation: stepSlideIn .32s ease both;
}

.step-panel.active.from-left {
  animation: stepSlideFromLeft .32s ease both;
}

@keyframes stepSlideIn {
  from { opacity: 0; transform: translateX(32px); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes stepSlideFromLeft {
  from { opacity: 0; transform: translateX(-32px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* 스텝 상단 제목 */
.step-heading {
  font-size: .82rem;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: .8px;
  margin-bottom: 20px;
  padding: 6px 12px;
  background: var(--primary-light);
  border-radius: 6px;
  display: inline-block;
}

/* ────────────────────────────────────────────
   스텝 내비게이션 버튼
──────────────────────────────────────────── */
.step-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 12px;
  gap: 12px;
}

.step-nav-spacer { flex: 1; }

.btn-step-prev {
  padding: 11px 22px;
  border: 2px solid var(--border);
  border-radius: 9px;
  background: transparent;
  color: var(--text-muted);
  font-size: .92rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
  flex-shrink: 0;
}

.btn-step-prev:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

.btn-step-next {
  padding: 11px 26px;
  background: linear-gradient(135deg, #4f46e5, #6366f1 60%, #06b6d4);
  color: #fff;
  border: none;
  border-radius: 9px;
  font-size: .95rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition);
  box-shadow: 0 3px 12px rgba(79,70,229,.3);
}

.btn-step-next:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 18px rgba(79,70,229,.4);
}

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

/* ────────────────────────────────────────────
   입력 폼 공통
──────────────────────────────────────────── */
.field-group {
  border: none;
  margin-bottom: 28px;
}

.field-legend {
  font-size: .95rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.legend-icon { font-size: 1.05rem; }

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
}

.field label {
  font-size: .82rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .5px;
}

.field input,
.field textarea {
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: .93rem;
  font-family: inherit;
  color: var(--text-main);
  background: var(--bg);
  transition: border-color var(--transition), box-shadow var(--transition);
  resize: vertical;
}

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99,102,241,.15);
  background: #fff;
}

.field input::placeholder,
.field textarea::placeholder {
  color: #a0aec0;
  font-size: .88rem;
}

.field-row.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

/* 희망 직군 드롭다운 */
.job-select {
  width: 100%;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 10px 40px 10px 14px;
  font-size: .93rem;
  font-family: inherit;
  color: var(--text-main);
  background-color: var(--bg);
  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='none' stroke='%2364748b' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round' d='M2 4l4 4 4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 14px;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.job-select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99,102,241,.15);
  background-color: #fff;
}

.job-custom-wrap {
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  margin-top: 0;
  transition: max-height .28s ease, opacity .22s ease, margin-top .28s ease;
}

.job-custom-wrap.visible {
  max-height: 60px;
  opacity: 1;
  margin-top: 10px;
}

.job-custom-input {
  width: 100%;
  border: 1.5px solid var(--primary);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: .93rem;
  font-family: inherit;
  color: var(--text-main);
  background: var(--bg);
  transition: border-color var(--transition), box-shadow var(--transition);
}

.job-custom-input:focus {
  outline: none;
  border-color: var(--primary-dark);
  box-shadow: 0 0 0 3px rgba(99,102,241,.15);
  background: #fff;
}

.job-custom-input::placeholder {
  color: #a0aec0;
  font-size: .88rem;
}

/* 분석 버튼 */
.btn-analyze {
  display: block;
  flex: 1;
  width: auto;
  padding: 15px;
  background: linear-gradient(135deg, #4f46e5, #6366f1 60%, #06b6d4);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: .3px;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition);
  box-shadow: 0 4px 14px rgba(79,70,229,.35);
}

.btn-analyze:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(79,70,229,.45);
}

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

.btn-analyze:disabled {
  opacity: .65;
  cursor: not-allowed;
  transform: none;
}

/* ────────────────────────────────────────────
   로딩
──────────────────────────────────────────── */
.loading-section {
  text-align: center;
  padding: 56px 24px;
}

.loader-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.spinner {
  width: 56px;
  height: 56px;
  border: 5px solid var(--primary-light);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin .85s linear infinite;
}

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

.loading-msg {
  font-size: 1rem;
  font-weight: 600;
  color: var(--primary-dark);
}

.loading-steps {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
}

.step {
  padding: 4px 14px;
  border-radius: 50px;
  font-size: .82rem;
  font-weight: 600;
  background: var(--border);
  color: var(--text-muted);
  transition: all .4s ease;
}

.step.active {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 2px 8px rgba(99,102,241,.3);
}

.step.done {
  background: var(--success);
  color: #fff;
}

.step-arrow {
  color: var(--text-muted);
  font-size: .85rem;
}

/* ────────────────────────────────────────────
   결과 섹션
──────────────────────────────────────────── */
.results-section {
  display: flex;
  flex-direction: column;
  gap: 22px;
  animation: fadeUp .5s ease both;
}

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

.results-header { text-align: center; }

.results-title {
  font-size: 1.6rem;
  font-weight: 800;
  background: linear-gradient(135deg, #4f46e5, #06b6d4);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.results-sub {
  font-size: .9rem;
  color: var(--text-muted);
  margin-top: 6px;
}

/* 종합 점수 카드 */
.score-card {
  display: flex;
  align-items: center;
  gap: 32px;
  background: linear-gradient(135deg, #f0f0ff 0%, #e8fffe 100%);
  border-color: #c7d2fe;
  flex-wrap: wrap;
}

.score-left {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  min-width: 130px;
}

.score-label {
  font-size: .78rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .5px;
}

.score-circle {
  position: relative;
  width: 120px;
  height: 120px;
}

.score-circle svg {
  transform: rotate(-90deg);
  width: 100%;
  height: 100%;
}

.score-circle .track {
  fill: none;
  stroke: #e0e7ff;
  stroke-width: 10;
}

.score-circle .progress {
  fill: none;
  stroke: url(#scoreGrad);
  stroke-width: 10;
  stroke-linecap: round;
  transition: stroke-dashoffset 1.2s ease;
}

.score-num {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--primary-dark);
}

.score-right {
  flex: 1;
  min-width: 200px;
}

.score-grade {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--primary-dark);
  margin-bottom: 8px;
}

.score-comment {
  font-size: .92rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 14px;
}

.score-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
}

.score-tags li {
  padding: 4px 12px;
  border-radius: 50px;
  font-size: .8rem;
  font-weight: 600;
  background: rgba(99,102,241,.12);
  color: var(--primary-dark);
}

/* 결과 카드 공통 */
.result-card { animation: fadeUp .5s ease both; }
.result-card:nth-child(2) { animation-delay: .08s; }
.result-card:nth-child(3) { animation-delay: .16s; }
.result-card:nth-child(4) { animation-delay: .24s; }
.result-card:nth-child(5) { animation-delay: .32s; }
.result-card:nth-child(6) { animation-delay: .40s; }
.result-card:nth-child(7) { animation-delay: .48s; }

.card-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--border);
}

.card-icon { font-size: 1.3rem; }

.card-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-main);
}

/* 추천 직무 리스트 */
.job-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.job-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 10px;
  background: var(--bg);
  border: 1px solid var(--border);
  transition: box-shadow var(--transition);
}

.job-item:hover { box-shadow: var(--shadow-md); }

.job-rank {
  min-width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-size: .78rem;
  font-weight: 700;
  flex-shrink: 0;
}

.job-rank.rank-1 { background: #f59e0b; }
.job-rank.rank-2 { background: #94a3b8; }
.job-rank.rank-3 { background: #a16207; }

.job-info { flex: 1; }

.job-name {
  font-weight: 700;
  font-size: .95rem;
  margin-bottom: 3px;
}

.job-desc {
  font-size: .83rem;
  color: var(--text-muted);
}

.job-match {
  font-size: .78rem;
  font-weight: 700;
  color: var(--success);
  white-space: nowrap;
  align-self: center;
}

/* 이력서 체크리스트 */
.checklist {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.checklist li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 8px;
  font-size: .9rem;
  line-height: 1.55;
}

.checklist li.warn {
  background: #fff7ed;
  border-left: 3px solid var(--warning);
  color: #92400e;
}

.checklist li.info {
  background: #eff6ff;
  border-left: 3px solid #3b82f6;
  color: #1e40af;
}

.checklist li.ok {
  background: #f0fdf4;
  border-left: 3px solid var(--success);
  color: #14532d;
}

.check-icon { font-size: 1rem; flex-shrink: 0; margin-top: 1px; }

/* 합격 전략 리스트 */
.strategy-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-left: 0;
  list-style: none;
  counter-reset: strategy;
}

.strategy-list li {
  counter-increment: strategy;
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 14px 16px;
  border-radius: 10px;
  background: var(--bg);
  border: 1px solid var(--border);
  font-size: .9rem;
  line-height: 1.6;
}

.strategy-list li::before {
  content: counter(strategy);
  min-width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, #4f46e5, #06b6d4);
  color: #fff;
  font-size: .78rem;
  font-weight: 700;
  flex-shrink: 0;
}

.strategy-list li strong {
  color: var(--primary-dark);
  display: block;
  margin-bottom: 3px;
}

/* 다시하기 버튼 */
.results-actions { text-align: center; padding-top: 4px; }

.btn-reset {
  padding: 11px 28px;
  border: 2px solid var(--primary);
  border-radius: 8px;
  color: var(--primary);
  background: transparent;
  font-size: .92rem;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--transition);
}

.btn-reset:hover {
  background: var(--primary);
  color: #fff;
}

/* ────────────────────────────────────────────
   푸터
──────────────────────────────────────────── */
.site-footer {
  text-align: center;
  padding: 24px 16px;
  font-size: .8rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
  background: var(--surface);
}

/* ── 사업자 정보 푸터 ──────────────────────────────────────── */
.biz-footer {
  background: #f1f3f6;
  border-top: 1px solid #dde1e7;
  padding: 28px 20px 24px;
}

.biz-footer-inner {
  max-width: 820px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: center;
}

.biz-info {
  font-size: .75rem;
  color: #6b7280;
  line-height: 1.7;
}

.biz-info strong {
  color: #374151;
  font-weight: 700;
}

.biz-mail {
  color: #6b7280;
  text-decoration: none;
}
.biz-mail:hover { text-decoration: underline; }

.biz-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 10px;
}

.biz-links a {
  font-size: .8rem;
  font-weight: 600;
  color: #4f46e5;
  text-decoration: none;
  transition: color .15s;
}
.biz-links a:hover { color: #06b6d4; text-decoration: underline; }

.biz-divider {
  color: #d1d5db;
  font-size: .8rem;
}

/* ────────────────────────────────────────────
   안내 텍스트
──────────────────────────────────────────── */
.field-hint {
  font-size: .76rem;
  color: var(--text-muted);
  margin-top: 6px;
  line-height: 1.5;
}

/* ────────────────────────────────────────────
   스킬 태그 입력
──────────────────────────────────────────── */
.tag-input-wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 7px 10px;
  background: var(--bg);
  cursor: text;
  min-height: 46px;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.tag-input-wrap:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99,102,241,.15);
  background: #fff;
}

.skill-tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 8px 4px 11px;
  background: var(--primary-light);
  border: 1px solid rgba(99,102,241,.25);
  border-radius: 50px;
  font-size: .82rem;
  font-weight: 600;
  color: var(--primary-dark);
  white-space: nowrap;
  animation: tagIn .15s ease both;
}

@keyframes tagIn {
  from { opacity: 0; transform: scale(.8); }
  to   { opacity: 1; transform: scale(1); }
}

.tag-remove {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--primary-dark);
  font-size: .72rem;
  line-height: 1;
  opacity: .55;
  padding: 0 1px;
  transition: opacity var(--transition);
}

.tag-remove:hover { opacity: 1; }

.tag-text-input {
  flex: 1;
  min-width: 140px;
  border: none;
  outline: none;
  font-size: .93rem;
  font-family: inherit;
  color: var(--text-main);
  background: transparent;
  padding: 2px 4px;
}

.tag-text-input::placeholder {
  color: #a0aec0;
  font-size: .88rem;
}

/* ────────────────────────────────────────────
   자격증 동적 입력
──────────────────────────────────────────── */
.cert-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 10px;
}

.cert-row {
  display: flex;
  align-items: center;
  gap: 8px;
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity .22s ease, transform .22s ease;
}

.cert-row.visible {
  opacity: 1;
  transform: translateY(0);
}

.cert-input {
  flex: 1;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: .93rem;
  font-family: inherit;
  color: var(--text-main);
  background: var(--bg);
  transition: border-color var(--transition), box-shadow var(--transition);
}

.cert-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99,102,241,.15);
  background: #fff;
}

.cert-input::placeholder {
  color: #a0aec0;
  font-size: .88rem;
}

.cert-delete-btn {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--border);
  border-radius: 7px;
  background: var(--bg);
  color: var(--text-muted);
  font-size: .8rem;
  cursor: pointer;
  flex-shrink: 0;
  transition: all var(--transition);
}

.cert-delete-btn:hover {
  background: #fee2e2;
  border-color: var(--danger);
  color: var(--danger);
}

.btn-add-cert {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 8px 16px;
  border: 1.5px dashed var(--primary);
  border-radius: 8px;
  background: transparent;
  color: var(--primary);
  font-size: .87rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all var(--transition);
}

.btn-add-cert:hover {
  background: var(--primary-light);
}

/* ────────────────────────────────────────────
   입력 방식 토글 (파일 업로드 / 직접 작성)
──────────────────────────────────────────── */
.input-mode-toggle {
  display: flex;
  width: fit-content;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 14px;
}

.toggle-tab {
  padding: 8px 20px;
  border: none;
  background: var(--bg);
  color: var(--text-muted);
  font-size: .87rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background var(--transition), color var(--transition);
}

.toggle-tab:first-child {
  border-right: 1.5px solid var(--border);
}

.toggle-tab.active {
  background: var(--primary);
  color: #fff;
}

.toggle-tab:hover:not(.active) {
  background: var(--primary-light);
  color: var(--primary-dark);
}

.mode-panel {
  display: none;
}

.mode-panel.active {
  display: block;
  animation: modeFadeIn .2s ease both;
}

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

/* ────────────────────────────────────────────
   파일 업로드
──────────────────────────────────────────── */
.file-input { display: none; }

.file-upload-area {
  border: 2px dashed var(--border);
  border-radius: 10px;
  overflow: hidden;
  transition: border-color var(--transition), background var(--transition);
  background: var(--bg);
}

.file-upload-area:hover,
.file-upload-area:focus-within {
  border-color: var(--primary);
  background: var(--primary-light);
}

.file-upload-label {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 26px 20px;
  cursor: pointer;
  text-align: center;
}

.upload-icon {
  font-size: 1.9rem;
  line-height: 1;
}

.upload-text {
  font-size: .9rem;
  font-weight: 600;
  color: var(--primary);
}

.upload-hint {
  font-size: .78rem;
  color: var(--text-muted);
}

.file-name-display {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  background: #eef2ff;
  border-top: 1.5px solid #c7d2fe;
}

.file-doc-icon {
  font-size: 1.1rem;
  flex-shrink: 0;
}

.file-name-text {
  flex: 1;
  font-size: .88rem;
  font-weight: 600;
  color: var(--primary-dark);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-remove-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: .82rem;
  color: var(--text-muted);
  padding: 3px 7px;
  border-radius: 4px;
  flex-shrink: 0;
  transition: background var(--transition), color var(--transition);
}

.file-remove-btn:hover {
  background: #fee2e2;
  color: var(--danger);
}

/* ────────────────────────────────────────────
   추천 기업군 카드
──────────────────────────────────────────── */
.company-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.company-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 16px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  transition: box-shadow var(--transition);
}

.company-item:hover { box-shadow: var(--shadow-md); }

.company-tier {
  flex-shrink: 0;
  padding: 4px 12px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff;
  font-size: .78rem;
  font-weight: 700;
  border-radius: 20px;
  white-space: nowrap;
  margin-top: 2px;
}

.company-info { flex: 1; }

.company-examples {
  font-size: .9rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 4px;
}

.company-reason {
  font-size: .84rem;
  color: var(--text-muted);
  line-height: 1.55;
}

/* ────────────────────────────────────────────
   연봉·문화 어드바이스 박스
──────────────────────────────────────────── */
.advice-box {
  font-size: .92rem;
  line-height: 1.75;
  color: var(--text-main);
  background: var(--bg);
  border-left: 4px solid var(--primary);
  border-radius: 0 10px 10px 0;
  padding: 14px 18px;
}

/* ────────────────────────────────────────────
   마크다운 렌더링 스타일
──────────────────────────────────────────── */
.markdown-body h1,
.markdown-body h2,
.markdown-body h3 {
  font-weight: 700;
  color: var(--text-main);
  border-bottom: 1px solid var(--border);
  padding-bottom: .3em;
  margin: 1.1em 0 .55em;
}
.markdown-body h1 { font-size: 1.15rem; }
.markdown-body h2 { font-size: 1.05rem; }
.markdown-body h3 { font-size: .96rem; }
.markdown-body p  { line-height: 1.8; margin: .55em 0; }
.markdown-body ul,
.markdown-body ol { padding-left: 1.5em; margin: .55em 0; }
.markdown-body li { line-height: 1.75; margin: .28em 0; }
.markdown-body li::marker { color: var(--primary); }
.markdown-body strong { font-weight: 700; color: var(--text-main); }
.markdown-body em     { font-style: italic; color: var(--text-muted); }
.markdown-body code {
  background: var(--bg-card, #f4f4f8);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: .1em .45em;
  font-size: .86em;
  font-family: 'Fira Code', 'Consolas', monospace;
}
.markdown-body > *:first-child { margin-top: 0; }
.markdown-body > *:last-child  { margin-bottom: 0; }

/* ────────────────────────────────────────────
   인라인 로딩 사이클 텍스트
──────────────────────────────────────────── */
.loading-cycle-msg {
  font-size: .97rem;
  font-weight: 600;
  color: var(--primary);
  text-align: center;
  line-height: 1.7;
  min-height: 1.7em;
  margin: 4px 0 0;
  transition: opacity .3s ease;
}

/* ────────────────────────────────────────────
   반응형
──────────────────────────────────────────── */
@media (max-width: 600px) {
  .card { padding: 20px 16px 24px; }
  .field-row.two-col { grid-template-columns: 1fr; }
  .score-card { justify-content: center; }
  .score-right { text-align: center; }
  .score-tags { justify-content: center; }
  .tag-text-input { min-width: 80px; }
  .job-select { font-size: .88rem; }
  .step-label { font-size: .68rem; }
  .step-dot { width: 34px; height: 34px; font-size: .82rem; }
  .btn-step-prev, .btn-step-next { padding: 10px 16px; font-size: .87rem; }
}

/* ── results-actions (PDF + 리셋 버튼) ──────────────────────── */
.results-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 8px;
}

.btn-download {
  background: linear-gradient(135deg, #4f46e5, #06b6d4);
  color: #fff;
  border: none;
  padding: 12px 24px;
  border-radius: 8px;
  font-weight: bold;
  font-size: 1rem;
  cursor: pointer;
  transition: transform .2s, opacity .2s;
}
.btn-download:hover { transform: translateY(-2px); opacity: .92; }

.btn-reset {
  padding: 12px 24px;
  border-radius: 8px;
  font-weight: bold;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-main);
  cursor: pointer;
  transition: background .2s;
}
.btn-reset:hover { background: var(--bg); }

.results-reset-wrap {
  display: flex;
  justify-content: center;
  margin-top: 24px;
}

/* ── 프리미엄 잠금 게이트 ────────────────────────────────────── */
.premium-gate {
  position: relative;
}

/* 잠긴 상태: 블러 처리 */
.premium-gate.locked .premium-blurred-area {
  filter: blur(12px) brightness(0.97);
  pointer-events: none !important;
  user-select: none !important;
  -webkit-user-select: none !important;
  -ms-user-select: none !important;
}

/* 잠긴 상태: 내부 모든 자식 요소도 개별 차단 */
.premium-gate.locked .premium-blurred-area * {
  pointer-events: none !important;
  user-select: none !important;
  -webkit-user-select: none !important;
  -ms-user-select: none !important;
}

/* 잠금 해제 상태 */
.premium-gate.unlocked .premium-blurred-area {
  filter: none;
  pointer-events: auto;
  user-select: auto;
}
.premium-gate.unlocked .premium-overlay {
  display: none;
}

/* 오버레이 레이어 — 반드시 클릭 가능하도록 pointer-events: auto */
.premium-overlay {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(248, 250, 252, 0.55);
  backdrop-filter: blur(2px);
  z-index: 30;
  padding: 24px 16px;
  border-radius: var(--radius);
  pointer-events: auto !important;
}

/* 오버레이 내부 모든 요소 클릭 허용 */
.premium-overlay *,
.premium-overlay-card,
.btn-payment {
  pointer-events: auto !important;
}

/* 오버레이 카드 */
.premium-overlay-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: 0 12px 48px rgba(79,70,229,.18), 0 2px 8px rgba(0,0,0,.08);
  padding: 40px 36px 36px;
  max-width: 480px;
  width: 100%;
  text-align: center;
}

.premium-lock-icon {
  font-size: 3rem;
  margin-bottom: 16px;
  animation: lockPulse 2s ease-in-out infinite;
}
@keyframes lockPulse {
  0%, 100% { transform: scale(1); }
  50%       { transform: scale(1.12); }
}

.premium-overlay-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 8px;
  letter-spacing: -.5px;
}

.premium-overlay-desc {
  color: var(--text-muted);
  font-size: .93rem;
  margin-bottom: 20px;
}

.premium-item-list {
  list-style: none;
  text-align: left;
  display: inline-flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 28px;
  font-size: .95rem;
  font-weight: 600;
  color: var(--text-main);
}

.prem-check { margin-right: 8px; }

/* 결제 버튼 */
.btn-payment {
  display: block;
  width: 100%;
  padding: 16px 20px;
  background: linear-gradient(135deg, #4f46e5 0%, #06b6d4 100%);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 1.02rem;
  font-weight: 800;
  letter-spacing: -.3px;
  cursor: pointer;
  box-shadow: 0 4px 18px rgba(79,70,229,.35);
  transition: transform .2s, box-shadow .2s;
  line-height: 1.4;
}
.btn-payment:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 28px rgba(79,70,229,.45);
}
.btn-payment:active { transform: translateY(0); }

.premium-notice {
  margin-top: 14px;
  font-size: .78rem;
  color: var(--text-muted);
}

/* ── PDF 인쇄 전용 스타일 (인쇄할 때만 작동) ────────────────── */
@media print {
  /* 1. 헤더·입력폼·푸터·버튼 등 불필요한 요소 모두 숨기기 */
  .site-header, .hero, #form-section, #loading-section, .site-footer, #results-actions {
    display: none !important;
  }

  /* 2. 배경 흰색으로 초기화 */
  body {
    background-color: #fff !important;
    margin: 0;
    padding: 0;
  }

  /* 3. 결과창을 용지에 꽉 차게 펼치기 */
  #results-section {
    display: block !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  /* 4. 카드가 페이지 경계에서 반토막 나지 않도록 보호 */
  .card {
    page-break-inside: avoid;
    break-inside: avoid;
    box-shadow: none !important;
    border: 1px solid #ddd !important;
    margin-bottom: 20px !important;
  }
}
