/* 토스 UI 톤: 회색 배경 + 테두리 없는 흰 카드, 채워진 입력창, 큰 숫자 하나 */
:root {
  --grey-50: #f9fafb;
  --grey-100: #f2f4f6;
  --grey-200: #e5e8eb;
  --grey-300: #d1d6db;
  --grey-400: #b0b8c1;
  --grey-500: #8b95a1;
  --grey-600: #6b7684;
  --grey-700: #4e5968;
  --grey-800: #333d4b;
  --grey-900: #191f28;

  --bg: var(--grey-100);
  --surface: #ffffff;
  --ink: var(--grey-900);
  --ink-2: var(--grey-700);
  --muted: #5b6573; /* 설명 글 (흰 바탕 5.8:1) */
  --faint: var(--grey-600); /* 힌트 · 보조 글자 (흰 바탕 4.6:1) */
  --line: var(--grey-100);

  --accent: #ff5a1f;
  --accent-hover: #f04c12;
  --accent-ink: #c2410c; /* 작은 주황 글자용 (흰 바탕 대비 5.2:1). 브랜드 주황은 면 · 큰 글자에만 */
  --accent-weak: rgba(255, 90, 31, 0.1);
  --accent-weak-hover: rgba(255, 90, 31, 0.16);
  --good: #03b26c;
  --good-weak: rgba(3, 178, 108, 0.1);
  --warn: #e08a00;
  --warn-weak: rgba(255, 168, 0, 0.12);
  --bad: #f04452;
  --bad-weak: rgba(240, 68, 82, 0.1);

  --dark: #17171c;
  --dark-2: #202027;
  --dark-line: #2c2c35;
  --dark-ink: #ffffff;
  --dark-muted: #9e9ea4;

  --h-sm: 36px;
  --h-md: 48px;
  --h-lg: 56px;
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 24px;
  --font: 'Pretendard', -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  word-break: keep-all;
}
button, input, textarea, select { font: inherit; color: inherit; letter-spacing: inherit; }
button { cursor: pointer; }
a { color: var(--accent-ink); font-weight: 600; text-decoration: none; }
a:hover { text-decoration: underline; }
[hidden] { display: none !important; }
svg { flex: none; }

/* ---------- 레이아웃 ---------- */

.app { display: grid; grid-template-columns: 260px minmax(0, 1fr); min-height: 100vh; }

.side {
  position: sticky; top: 0; height: 100vh;
  display: flex; flex-direction: column; gap: 32px;
  padding: 28px 16px 20px;
  background: var(--surface);
}
.brand { display: flex; align-items: center; gap: 10px; padding: 0 12px; }
.brand-mark { width: 30px; height: 30px; border-radius: 10px; background: var(--accent); display: grid; place-items: center; }
.brand-mark::after { content: ''; width: 10px; height: 10px; border-radius: 50%; background: #fff; }
.brand strong { display: block; font-size: 17px; font-weight: 700; line-height: 1.3; letter-spacing: -0.03em; }
.brand small { display: block; color: var(--faint); font-size: 12px; line-height: 1.3; }

.steps { display: flex; flex-direction: column; gap: 4px; }
.nav-item {
  display: grid; grid-template-columns: 28px 1fr; align-items: center; column-gap: 12px;
  width: 100%; padding: 12px; border: 0; border-radius: var(--r-md);
  background: none; text-align: left; color: var(--ink-2);
  transition: background 0.15s;
}
.nav-item .no {
  grid-row: span 2; display: grid; place-items: center;
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--grey-100); font-size: 13px; font-weight: 700; color: var(--faint);
}
.nav-item .label { font-weight: 600; font-size: 15px; line-height: 1.35; }
.nav-item .meta { font-size: 13px; color: var(--faint); line-height: 1.35; }
.nav-item:hover { background: var(--grey-50); }
.nav-item.on { background: var(--grey-100); color: var(--ink); }
.nav-item.on .no { background: var(--ink); color: #fff; }
.nav-item.done .no { background: var(--accent-weak); color: var(--accent-ink); }
.side-foot { margin-top: auto; }
.side-foot .nav-item .no { background: none; grid-row: auto; color: var(--faint); }
.side-foot .nav-item.on .no { color: var(--ink); background: none; }

.main { padding: 56px 56px 120px; min-width: 0; }
.page { max-width: 880px; margin: 0 auto; }

/* ---------- 타이포 ---------- */

.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 32px; }
.eyebrow { color: var(--faint); font-weight: 600; font-size: 14px; margin: 0 0 6px; }
h1 { font-size: 28px; line-height: 1.35; font-weight: 700; letter-spacing: -0.03em; margin: 0; }
h2 { font-size: 20px; line-height: 1.4; font-weight: 700; letter-spacing: -0.03em; margin: 0; }
h3 { font-size: 17px; line-height: 1.45; font-weight: 700; letter-spacing: -0.02em; margin: 0; }
.lead { color: var(--muted); font-size: 16px; margin: 8px 0 0; max-width: 600px; }
.muted { color: var(--muted); }
.small { font-size: 14px; }

/* ---------- 카드 ---------- */

.stack { display: grid; gap: 12px; }
.section { margin-top: 48px; }
.section-title { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 16px; padding: 0 4px; }
.section-title p { margin: 4px 0 0; font-size: 14px; color: var(--muted); }

.card { background: var(--surface); border-radius: var(--r-lg); }
.card-pad { padding: 28px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 24px 28px 8px; }
.card-head p { margin: 4px 0 0; font-size: 14px; color: var(--muted); }
.card-body { padding: 20px 28px 28px; }
.card-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 20px 28px 24px; border-top: 1px solid var(--line); }

/* ---------- 버튼 ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: var(--h-md); padding: 0 20px; border-radius: var(--r-md); border: 0;
  background: var(--grey-100); color: var(--ink-2);
  font-weight: 600; font-size: 16px; line-height: 1; white-space: nowrap;
  transition: background 0.15s, color 0.15s, transform 0.1s;
}
.btn:hover { background: var(--grey-200); }
.btn:active { transform: scale(0.98); }
.btn.primary { background: var(--ink); color: #fff; }
.btn.primary:hover { background: #000; }
.btn.accent { background: var(--accent); color: #fff; }
.btn.accent:hover { background: var(--accent-hover); }
.btn.weak { background: var(--accent-weak); color: var(--accent-ink); }
.btn.weak:hover { background: var(--accent-weak-hover); }
.btn.ghost { background: none; color: var(--muted); }
.btn.ghost:hover { background: var(--grey-100); color: var(--ink); }
.btn.danger { background: var(--bad-weak); color: var(--bad); }
.btn.danger:hover { background: rgba(240, 68, 82, 0.16); }
/* 회색 배경 위(카드 밖)에 놓인 기본 버튼은 흰색으로 */
.page-head .btn:not(.primary):not(.accent):not(.danger):not(.ghost),
.section-title .btn:not(.primary):not(.accent):not(.danger):not(.ghost),
.notice + .btn { background: var(--surface); }
.page-head .btn:not(.primary):not(.accent):not(.danger):not(.ghost):hover,
.section-title .btn:not(.primary):not(.accent):not(.danger):not(.ghost):hover { background: var(--grey-200); }
.btn.sm { height: var(--h-sm); padding: 0 14px; font-size: 14px; border-radius: var(--r-sm); }
.btn.lg { height: var(--h-lg); padding: 0 28px; font-size: 17px; border-radius: 16px; }
.btn.block { width: 100%; }
.btn:disabled { opacity: 0.35; cursor: not-allowed; transform: none; }
.btn.primary:disabled:hover { background: var(--ink); }
.btn.accent:disabled:hover { background: var(--accent); }
.icon-btn {
  display: inline-grid; place-items: center; width: var(--h-sm); height: var(--h-sm);
  border: 0; border-radius: var(--r-sm); background: none; color: var(--grey-400);
}
.icon-btn:hover { background: var(--grey-100); color: var(--ink-2); }
.spin { width: 15px; height: 15px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin 0.8s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

.actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.hint { font-size: 14px; color: var(--faint); }

/* ---------- 입력 ---------- */

.field { display: block; }
.field + .field, .grid-2 + .field, .field + .grid-2 { margin-top: 24px; }
.grid-2 > .field { margin-top: 0; }
.field-label { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: var(--h-sm); margin-bottom: 4px; }
.field-label > span { font-size: 14px; font-weight: 600; color: var(--muted); }
.field-label .optional { font-weight: 500; color: var(--grey-400); margin-left: 6px; }

.input, select.input, textarea.input {
  display: block; width: 100%; height: var(--h-md); padding: 0 16px;
  border-radius: var(--r-md); border: 1.5px solid transparent; background: var(--grey-100);
  font-size: 16px; color: var(--ink); outline: none; transition: border-color 0.15s, background 0.15s;
}
textarea.input { height: auto; min-height: 128px; padding: 13px 16px; line-height: 1.6; resize: vertical; }
select.input {
  appearance: none; -webkit-appearance: none; padding-right: 40px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%238b95a1' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center;
}
.input:hover { background-color: var(--grey-200); }
.input:focus { border-color: var(--accent); background-color: var(--surface); }
.input::placeholder { color: var(--grey-400); }

.inline { display: flex; gap: 8px; align-items: center; }
.inline .input { flex: 1; min-width: 0; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.upload { position: relative; display: inline-flex; align-items: center; gap: 10px; }
.upload input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.upload .hint { font-size: 13px; }

.check {
  appearance: none; -webkit-appearance: none; flex: none;
  width: 22px; height: 22px; margin: 0; border-radius: 50%;
  border: 0; background: var(--grey-200); cursor: pointer;
  display: grid; place-items: center; transition: 0.15s;
}
.check::after { content: ''; width: 9px; height: 5px; border: 2px solid #fff; border-top: 0; border-right: 0; transform: translateY(-1px) rotate(-45deg); }
.check:checked { background: var(--accent); }

.switch { position: relative; width: 44px; height: 26px; flex: none; display: inline-block; }
.switch input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; z-index: 1; }
.switch i { position: absolute; inset: 0; background: var(--grey-300); border-radius: 999px; transition: 0.2s; }
.switch i::after { content: ''; position: absolute; left: 3px; top: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: 0.2s; box-shadow: 0 1px 3px rgba(0,0,0,0.15); }
.switch input:checked + i { background: var(--accent); }
.switch input:checked + i::after { transform: translateX(18px); }

/* ---------- 칩 / 안내 ---------- */

.chip {
  display: inline-flex; align-items: center; height: 26px; padding: 0 10px;
  border-radius: 8px; background: var(--grey-100); color: var(--ink-2); font-size: 13px; font-weight: 600; white-space: nowrap;
}
.chip.accent { background: var(--accent-weak); color: var(--accent-ink); }
.chip.outline { background: var(--grey-100); color: var(--muted); height: 24px; font-size: 12px; }
.count-badge { display: inline-flex; align-items: center; height: 24px; padding: 0 8px; border-radius: 8px; background: var(--grey-100); font-size: 13px; font-weight: 700; color: var(--muted); margin-left: 8px; vertical-align: 2px; }
.count-badge.accent { background: var(--accent-weak); color: var(--accent-ink); }

.notice {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 20px 18px 24px; border-radius: 18px; margin-bottom: 16px;
  background: var(--surface); font-size: 15px; color: var(--ink-2);
}
.notice b { color: var(--ink); font-weight: 700; display: block; }
.notice.neutral { background: var(--surface); }
.empty { padding: 48px 24px; text-align: center; color: var(--muted); font-size: 15px; }
.empty .btn { margin-top: 20px; }

/* ---------- 1. 경험 정리 ---------- */

.chat { display: flex; flex-direction: column; overflow: hidden; }
.chat-log { height: 440px; overflow-y: auto; padding: 16px 28px 24px; display: flex; flex-direction: column; gap: 16px; }
.msg-row { display: flex; gap: 10px; align-items: flex-start; }
.msg-row.me { justify-content: flex-end; }
.emoji, .avatar, .coach-face { font-family: 'Tossface', var(--font); font-weight: 400; line-height: 1; }
.avatar { width: 36px; height: 36px; border-radius: 50%; background: #fff4e5; display: grid; place-items: center; font-size: 20px; flex: none; }
.coach { display: flex; align-items: center; gap: 14px; }
.coach-face { width: 52px; height: 52px; border-radius: 16px; background: #fff4e5; display: grid; place-items: center; font-size: 30px; flex: none; }
.msg { max-width: 72%; padding: 12px 16px; border-radius: 20px; white-space: pre-wrap; font-size: 16px; line-height: 1.55; }
.msg.ai { background: var(--grey-100); color: var(--ink); border-top-left-radius: 6px; }
.msg.me { background: var(--accent); color: #fff; border-top-right-radius: 6px; }
.msg.typing { display: inline-flex; gap: 4px; align-items: center; padding: 16px 18px; }
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--grey-400); animation: blink 1.2s infinite; }
.dot:nth-child(2) { animation-delay: 0.2s; } .dot:nth-child(3) { animation-delay: 0.4s; }
@keyframes blink { 0%, 60%, 100% { opacity: 0.3; } 30% { opacity: 1; } }

.composer { padding: 16px 20px 20px; border-top: 1px solid var(--line); }
.composer-box {
  display: flex; align-items: flex-end; gap: 6px; padding: 6px;
  border: 1.5px solid transparent; border-radius: 18px; background: var(--grey-100);
  transition: border-color 0.15s, background 0.15s;
}
.composer-box:focus-within { border-color: var(--accent); background: var(--surface); }
.composer-box textarea {
  flex: 1; min-width: 0; border: 0; outline: none; resize: none; background: none;
  height: 40px; max-height: 160px; padding: 9px 4px; line-height: 22px; font-size: 16px;
}
.composer-box textarea::placeholder { color: var(--grey-400); }
.round-btn {
  flex: none; width: 40px; height: 40px; border-radius: 12px;
  border: 0; background: none; color: var(--faint); display: grid; place-items: center;
}
.round-btn:hover { background: var(--grey-200); color: var(--ink); }
.round-btn.send { background: var(--accent); color: #fff; }
.round-btn.send:hover { background: var(--accent-hover); color: #fff; }
.round-btn:disabled { opacity: 0.35; cursor: not-allowed; }
.round-btn.rec { background: var(--accent); color: #fff; animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px rgba(255, 90, 31, 0.18); } }
.composer-hint { display: flex; justify-content: space-between; margin-top: 8px; padding: 0 4px; font-size: 13px; color: var(--grey-400); }

.exp-card .card-head { align-items: flex-start; }
.exp-meta { color: var(--faint); font-size: 14px; margin-top: 2px; }
.star { display: grid; grid-template-columns: 52px 1fr; gap: 12px 16px; font-size: 15px; margin: 0; }
.star dt { color: var(--faint); font-weight: 600; }
.star dd { margin: 0; color: var(--ink-2); }
.tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 20px; }
.exp-missing { display: flex; gap: 8px; align-items: flex-start; margin-top: 16px; padding: 12px 14px; border-radius: var(--r-md); background: var(--warn-weak); font-size: 14px; color: #b36b00; }
.exp-missing svg { margin-top: 3px; }

/* ---------- 2. 질문 준비 ---------- */

.q-group + .q-group { border-top: 8px solid var(--grey-100); }
.q-group-head { display: flex; align-items: center; justify-content: space-between; padding: 24px 28px 8px; }
.q-list { padding: 0 12px 8px; }
.q-item {
  display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; gap: 14px; align-items: start;
  padding: 14px 16px; border-radius: var(--r-md); cursor: pointer; transition: background 0.15s;
}
.q-item:hover { background: var(--grey-50); }
.q-item .check { margin-top: 1px; }
.q-text { font-weight: 600; font-size: 16px; line-height: 1.5; color: var(--ink); }
.q-sub { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 6px; font-size: 13px; color: var(--faint); }
.q-item .icon-btn { margin: -6px -6px 0 0; }
.q-add { padding: 4px 28px 24px; }

/* ---------- 3. 면접 준비 ---------- */

.ready { display: grid; grid-template-columns: 1.1fr 1fr; gap: 12px; align-items: stretch; }
.big-start {
  display: flex; flex-direction: column; justify-content: space-between; gap: 24px;
  min-width: 0; padding: 32px; border-radius: var(--r-lg); color: var(--dark-ink);
  background: radial-gradient(ellipse at 75% 68%, rgba(255, 90, 31, 0.18), rgba(255, 128, 64, 0.06) 42%, transparent 72%), var(--dark);
}
.ready-moki { display: grid; place-items: center; flex: 1; }
.ready-moki img { display: block; width: min(208px, 100%); height: auto; filter: drop-shadow(0 12px 28px rgba(255, 90, 31, 0.1)); }
.big-start .label { font-size: 15px; color: var(--dark-muted); font-weight: 600; }
.big-start .count { display: flex; align-items: baseline; gap: 6px; margin-top: 8px; }
.big-start .count b { font-size: 80px; line-height: 1; font-weight: 800; letter-spacing: -0.05em; }
.big-start .count span { font-size: 24px; color: var(--dark-ink); font-weight: 700; }
.big-start .eta { margin-top: 16px; font-size: 14px; color: var(--dark-muted); }
.option-list { padding: 8px 28px; }
.option { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 80px; padding: 14px 0; }
.option + .option { border-top: 1px solid var(--line); }
.option .t { font-weight: 600; font-size: 16px; }
.option .d { font-size: 14px; color: var(--faint); margin-top: 2px; }
.option select.input { width: 112px; height: var(--h-sm); font-size: 15px; border-radius: var(--r-sm); background-position: right 12px center; padding: 0 34px 0 14px; }
.meter { height: 6px; background: var(--grey-100); border-radius: 999px; overflow: hidden; margin: -6px 0 20px; }
.meter i { display: block; height: 100%; width: 0; background: var(--accent); transition: width 0.08s; }
.flow { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.flow-step { padding: 24px; }
.flow-step b { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--accent-weak); font-size: 13px; color: var(--accent-ink); margin-bottom: 14px; }
.flow-step p { margin: 0; font-size: 15px; color: var(--ink-2); }

/* ---------- 면접 무대 (전체 화면) ---------- */

.stage {
  position: fixed; inset: 0; z-index: 50;
  background: var(--dark); color: var(--dark-ink);
  display: grid; grid-template-rows: auto minmax(0, 1fr) auto; grid-template-columns: minmax(0, 1fr);
  padding: 28px 40px 36px; overflow: hidden;
}
.stage-top { display: flex; justify-content: space-between; align-items: center; gap: 16px; color: var(--dark-muted); font-size: 15px; }
.stage-top .row { display: flex; align-items: center; gap: 16px; flex: 1; min-width: 0; }
.stage-top .row > span { white-space: nowrap; }
.stage-top .progress { display: flex; gap: 6px; flex: 0 1 auto; min-width: 0; }
.stage-top .progress i { flex: 0 1 28px; min-width: 4px; height: 4px; border-radius: 4px; background: var(--dark-line); }
.stage-top .progress i.done { background: var(--dark-muted); }
.stage-top .progress i.now { background: var(--accent); }
.stage .btn { background: var(--dark-2); color: var(--dark-ink); }
.stage .btn:hover { background: var(--dark-line); }
.stage-top .btn { color: var(--dark-muted); flex: none; }

.stage-center { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 48px; min-height: 0; }
.stage-label { display: inline-flex; height: 30px; align-items: center; padding: 0 12px; border-radius: 999px; background: var(--dark-2); font-size: 14px; font-weight: 600; color: var(--dark-muted); margin-bottom: 20px; }
.stage-label.follow { color: var(--accent); background: rgba(255, 90, 31, 0.14); }
.stage-label:empty { display: none; }
.stage-q {
  font-size: clamp(26px, 3.6vw, 44px); line-height: 1.38; font-weight: 700; letter-spacing: -0.035em;
  max-width: 900px; margin: 0; overflow-wrap: anywhere; animation: rise 0.5s ease both;
}
@keyframes rise { from { opacity: 0; transform: translateY(12px); } }

.orb-wrap { position: relative; flex: none; width: 160px; height: 160px; display: grid; place-items: center; }
.orb { width: 96px; height: 96px; border-radius: 50%; background: var(--dark-line); transition: background 0.3s, transform 0.08s linear; }
.orb-ring { position: absolute; inset: 0; border-radius: 50%; border: 1px solid var(--dark-line); }
.stage[data-phase='asking'] .orb { background: var(--dark-ink); animation: breathe 1.6s ease-in-out infinite; }
.stage[data-phase='listening'] .orb { background: var(--accent); }
.stage[data-phase='listening'] .orb-ring { border-color: rgba(255, 90, 31, 0.35); }
.stage[data-phase='thinking'] .orb { animation: breathe 1s ease-in-out infinite; }
@keyframes breathe { 50% { transform: scale(0.88); } }
.stage-status { color: var(--dark-muted); font-size: 15px; margin-top: -28px; min-height: 24px; }
.stage-timer { font-variant-numeric: tabular-nums; }
.stage-timer.long { color: var(--accent); }

.stage-bottom { display: flex; flex-direction: column; align-items: center; gap: 20px; }
.caption { max-width: 820px; min-height: 48px; text-align: center; color: var(--dark-muted); font-size: 17px; line-height: 1.6; }
.caption em { font-style: normal; color: #5f5f68; }
.stage-actions { display: flex; gap: 8px; align-items: center; }
.stage-actions .btn { height: var(--h-lg); padding: 0 24px; border-radius: 16px; font-size: 17px; }
.stage-actions .btn.accent { background: var(--accent); color: #fff; padding: 0 40px; }
.stage-actions .btn.accent:hover { background: var(--accent-hover); }
.kbd { font-size: 13px; color: var(--dark-muted); }
.kbd b { display: inline-block; padding: 1px 8px; background: var(--dark-2); border-radius: 6px; font-weight: 500; margin-right: 4px; }
.stage-end { text-align: center; }
.stage-end h2 { font-size: 36px; letter-spacing: -0.035em; margin-bottom: 10px; }
.stage-end p { color: var(--dark-muted); margin: 0 0 32px; }
.stage-end .btn.accent { height: var(--h-lg); padding: 0 32px; font-size: 17px; border-radius: 16px; background: var(--accent); }

/* ---------- 4. 리포트 ---------- */

.sessions { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 16px; scrollbar-width: none; }
.sess {
  flex: none; display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px;
  border-radius: 999px; border: 0; background: var(--surface); color: var(--muted); font-size: 14px; font-weight: 600;
}
.sess b { color: var(--ink); font-weight: 700; }
.sess:hover { background: var(--grey-50); }
.sess.on { background: var(--ink); color: var(--grey-400); }
.sess.on b { color: #fff; }

/* 점수: 이 화면에서 유일하게 크게, 유일하게 주황 */
.score-hero { background: var(--dark); color: var(--dark-ink); border-radius: var(--r-lg); padding: 36px 40px 40px; }
.score-hero .label { font-size: 16px; font-weight: 600; color: var(--dark-muted); }
.score-line { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 16px; margin-top: 8px; }
.score-num { font-size: 136px; line-height: 0.95; font-weight: 800; letter-spacing: -0.06em; color: var(--accent); font-variant-numeric: tabular-nums; }
.score-num small { font-size: 40px; font-weight: 700; letter-spacing: -0.03em; margin-left: 4px; }
.score-num.empty-score { color: var(--dark-line); }
.score-meta { display: flex; gap: 8px; align-items: center; padding-bottom: 14px; }
.pill { display: inline-flex; align-items: center; height: 30px; padding: 0 12px; border-radius: 999px; background: var(--dark-2); color: var(--dark-ink); font-size: 14px; font-weight: 600; }
.pill.up { color: #4ad99a; }
.pill.down { color: #ff8a93; }
.score-hero h2 { font-size: 22px; line-height: 1.45; color: var(--dark-ink); margin-top: 28px; display: flex; align-items: center; gap: 10px; }
.score-hero p { margin: 8px 0 0; color: var(--dark-muted); font-size: 16px; max-width: 640px; }
.score-hero .btn { margin-top: 24px; }

.list { padding: 8px 0; }
.list-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; padding: 12px 28px; }
.list-row .k { font-size: 16px; color: var(--ink-2); }
.list-row .k small { display: block; font-size: 13px; color: var(--faint); margin-top: 1px; }
.list-row .v { display: flex; align-items: center; gap: 10px; font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tag { display: inline-flex; align-items: center; height: 24px; padding: 0 8px; border-radius: 6px; font-size: 12px; font-weight: 700; }
.tag.ok { background: var(--good-weak); color: var(--good); }
.tag.mid { background: var(--warn-weak); color: #c27700; }
.tag.low { background: var(--bad-weak); color: var(--bad); }
.footnote { margin: 12px 4px 0; font-size: 13px; color: var(--grey-400); }

.bars { padding: 12px 28px; }
.bar-row { display: grid; grid-template-columns: 104px 1fr 36px; gap: 8px 20px; align-items: center; padding: 16px 0; }
.bar-row + .bar-row { border-top: 1px solid var(--line); }
.bar-row .name { font-weight: 600; font-size: 15px; color: var(--ink-2); }
.bar-row .track { height: 8px; background: var(--grey-100); border-radius: 999px; overflow: hidden; }
.bar-row .track i { display: block; height: 100%; background: var(--grey-400); border-radius: 999px; }
.bar-row b { text-align: right; font-size: 16px; font-variant-numeric: tabular-nums; color: var(--ink-2); }
.bar-row .note { grid-column: 2 / 4; font-size: 14px; color: var(--faint); }
.bar-row.weak .name, .bar-row.weak b { color: var(--accent-ink); }
.bar-row.weak .track i { background: var(--accent); }
.bar-row.weak .note { color: var(--ink-2); }
.weak-tag { display: block; font-size: 12px; font-weight: 700; color: var(--accent-ink); margin-top: 2px; }

.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.points { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 12px; }
.points li { display: grid; grid-template-columns: 22px 1fr; gap: 8px; font-size: 15px; color: var(--ink-2); }
.points li::before { content: ''; width: 18px; height: 18px; border-radius: 50%; margin-top: 3px; background: var(--good-weak) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='%2303b26c' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center no-repeat; }
.points.fix li::before { background: var(--grey-100) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='%236b7684' stroke-width='4' stroke-linecap='round'%3E%3Cpath d='M5 12h14M13 6l6 6-6 6'/%3E%3C/svg%3E") center no-repeat; }

.answers { padding: 4px 0; }
.answer + .answer { border-top: 1px solid var(--line); }
.answer summary {
  list-style: none; display: grid; grid-template-columns: 60px minmax(0, 1fr) 40px 20px; gap: 12px;
  padding: 20px 28px; cursor: pointer; align-items: center; transition: background 0.15s;
}
.answer summary:hover { background: var(--grey-50); }
.answer:first-child summary { border-radius: var(--r-lg) var(--r-lg) 0 0; }
.answer summary::-webkit-details-marker { display: none; }
.answer .qno { font-size: 14px; font-weight: 700; color: var(--grey-400); }
.answer .qno.follow { color: var(--accent-ink); font-size: 13px; }
.answer .qtext { font-weight: 600; font-size: 16px; }
.answer .sc { text-align: right; font-weight: 700; font-size: 16px; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.answer .chev { display: grid; place-items: center; color: var(--grey-400); transition: transform 0.2s; }
.answer[open] .chev { transform: rotate(180deg); }
.answer-body { padding: 0 28px 28px 100px; display: grid; gap: 20px; font-size: 15px; }
.answer-body h4 { margin: 0 0 6px; font-size: 13px; color: var(--faint); font-weight: 600; }
.answer-body p { margin: 0; white-space: pre-wrap; color: var(--ink-2); }
.answer-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.better { background: var(--grey-50); padding: 20px; border-radius: 16px; }
.better h4 { color: var(--accent-ink); }
audio { height: 40px; width: 100%; max-width: 380px; }

/* ---------- 설정 ---------- */

.setting { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 32px; padding: 28px; }
.setting + .setting { border-top: 1px solid var(--line); }
.setting-label { padding-top: 10px; }
.setting-label h3 { margin-bottom: 4px; }
.setting-label p { margin: 0; font-size: 14px; color: var(--faint); }
.setting-body { display: grid; gap: 16px; align-content: start; }
.status-line { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); flex-wrap: wrap; }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--grey-300); }
.status-dot.ok { background: var(--good); } .status-dot.low { background: var(--bad); }
.status-line.low, .status-line .low { color: var(--bad); }

/* ---------- 토스트 ---------- */

.toast {
  position: fixed; left: 50%; bottom: 32px; transform: translateX(-50%); z-index: 100;
  background: rgba(25, 31, 40, 0.94); color: #fff; padding: 14px 20px; border-radius: 16px; font-size: 15px; font-weight: 500;
  max-width: calc(100vw - 32px); box-shadow: 0 8px 24px rgba(0, 0, 0, 0.16);
}
.toast.error { background: var(--bad); }

/* ---------- 좁은 화면 ---------- */

@media (max-width: 1080px) {
  .main { padding: 40px 32px 100px; }
  .setting { grid-template-columns: 1fr; gap: 12px; }
  .setting-label { padding-top: 0; }
}
@media (max-width: 860px) {
  .app { grid-template-columns: minmax(0, 1fr); }
  .side, .main { min-width: 0; }
  .side { position: static; height: auto; flex-direction: row; align-items: center; gap: 4px; padding: 10px 12px; overflow-x: auto; scrollbar-width: none; }
  .brand { padding: 0 4px; } .brand div { display: none; }
  .steps { flex-direction: row; gap: 2px; }
  .nav-item { width: auto; white-space: nowrap; grid-template-columns: 24px auto; column-gap: 8px; padding: 8px 10px; }
  .nav-item .meta { display: none; }
  .nav-item .no { grid-row: auto; width: 24px; height: 24px; font-size: 12px; }
  .side-foot { margin: 0 0 0 auto; }
  .side-foot .label { display: none; }
  .main { padding: 28px 16px 80px; }
  .page-head { flex-direction: column; align-items: flex-start; }
  .grid-2, .ready, .two-col, .flow, .answer-grid { grid-template-columns: 1fr; }
  .big-start { padding: 24px; }
  .ready-moki img { width: min(168px, 100%); }
  .card-head, .card-body, .card-foot, .setting, .option-list, .bars, .list-row, .q-group-head, .q-add { padding-left: 20px; padding-right: 20px; }
  .card-foot { flex-direction: column; align-items: stretch; }
  .section-title { flex-wrap: wrap; }
  .score-hero { padding: 28px 24px 32px; }
  .score-num { font-size: 104px; }
  .score-hero h2 { font-size: 19px; }
  .bar-row { grid-template-columns: 84px 1fr 32px; gap: 6px 12px; }
  .answer summary { grid-template-columns: 48px minmax(0, 1fr) 32px 16px; padding: 18px 20px; }
  .answer-body { padding: 0 20px 24px; }
  .stage { padding: 20px 16px 24px; }
  .stage-center { gap: 28px; }
  .stage-status { margin-top: -12px; }
  .orb-wrap { width: 120px; height: 120px; }
  .orb { width: 72px; height: 72px; }
  .stage-actions .btn { padding: 0 18px; }
  .chat-log { height: 380px; padding: 12px 20px 20px; }
}

/* ---------- 직군 선택 ---------- */

.segment { display: flex; flex-wrap: wrap; gap: 8px; }
.seg {
  height: 40px; padding: 0 16px; border: 0; border-radius: 999px;
  background: var(--grey-100); color: var(--ink-2); font-size: 15px; font-weight: 600;
  transition: background 0.15s, color 0.15s;
}
.seg:hover { background: var(--grey-200); }
.seg.on { background: var(--ink); color: #fff; }

/* ---------- 인터랙션 다듬기 ---------- */

/* 키보드로 이동할 때 현재 위치 표시 */
button:focus-visible, a:focus-visible, .seg:focus-visible, .q-item:focus-within:has(.check:focus-visible), summary:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 2px;
}
.check:focus-visible, .switch input:focus-visible + i { outline: 2px solid var(--accent); outline-offset: 2px; }

/* 메뉴를 옮길 때만 살짝 올라오며 등장 */
.page.enter { animation: pageIn 0.28s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
@keyframes pageIn { from { opacity: 0; transform: translateY(8px); } }

/* 새로 생긴 질문/카드 강조 */
.is-new { animation: freshIn 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) both, freshGlow 2.4s ease 0.2s; }
@keyframes freshIn { from { opacity: 0; transform: translateY(8px); } }
@keyframes freshGlow { 0%, 40% { background-color: var(--accent-weak); } 100% { background-color: transparent; } }
.card.is-new { animation: freshIn 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) both, cardGlow 2.4s ease 0.2s; }
@keyframes cardGlow { 0%, 40% { box-shadow: 0 0 0 2px var(--accent); } 100% { box-shadow: 0 0 0 2px transparent; } }

/* 토스트: 아래에서 올라오기 */
.toast { bottom: 104px; animation: toastIn 0.3s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
@keyframes toastIn { from { opacity: 0; transform: translate(-50%, 12px); } }

/* 확인 팝업 */
.dialog-backdrop {
  position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 16px;
  background: rgba(0, 0, 0, 0.42); animation: fadeIn 0.18s ease both;
}
.dialog {
  width: min(400px, 100%); background: var(--surface); color: var(--ink); border-radius: var(--r-lg);
  padding: 28px 24px 20px; box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
  animation: dialogIn 0.25s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}
.dialog h3 { font-size: 20px; line-height: 1.4; }
.dialog p { margin: 8px 0 0; color: var(--muted); font-size: 15px; }
.dialog-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 24px; }
.btn.danger-solid { background: var(--bad); color: #fff; }
.btn.danger-solid:hover { background: #e03342; }
@keyframes fadeIn { from { opacity: 0; } }
@keyframes dialogIn { from { opacity: 0; transform: translateY(12px) scale(0.98); } }

/* 질문 준비: 아래에 붙는 시작 버튼 */
.sticky-cta {
  position: sticky; bottom: 16px; z-index: 5; margin-top: 24px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 10px 10px 10px 24px; border-radius: 20px;
  background: rgba(255, 255, 255, 0.92); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 8px 28px rgba(25, 31, 40, 0.12);
}
.sticky-cta b { font-size: 17px; }

/* 면접 화면: 시작 안내 + 단축키 구분 */
.stage-sub { margin: 16px 0 0; color: var(--dark-muted); font-size: 17px; }
.kbd { display: flex; align-items: center; gap: 6px; }
.kbd-sep { width: 1px; height: 12px; background: var(--dark-line); margin: 0 8px; }
.kbd b:first-child:last-child { margin: 0; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-delay: 0ms !important; transition-duration: 0.01ms !important; }
}
@media (max-width: 860px) {
  .sticky-cta { padding-left: 18px; }
  .sticky-cta .hint { display: none; }
  .kbd { display: none; }
}

/* 면접 코치 아이콘 (말풍선 + 눈) */
.avatar, .coach-face { background: linear-gradient(145deg, #fff7f2, #ffe9de); box-shadow: inset 0 0 0 1px rgba(255, 90, 31, 0.08); }
.avatar img { width: 26px; height: 26px; display: block; }
.coach-face img { width: 38px; height: 38px; display: block; }

/* 로고 */
.brand-logo { width: 32px; height: 32px; display: block; flex: none; }

/* ---------- claude.ai 가져오기 ---------- */

.steps-list { list-style: none; margin: 0; padding: 8px 28px 20px; display: grid; }
.steps-list li { display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 14px 0; }
.steps-list li + li { border-top: 1px solid var(--line); }
.steps-list b { display: block; font-size: 15px; }
.steps-list span:not(.step-no) { display: block; font-size: 13px; color: var(--faint); margin-top: 1px; }
.step-no { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--grey-100); font-size: 13px; font-weight: 700; color: var(--muted); }
a.btn { text-decoration: none; }
.dialog.wide { width: min(560px, 100%); }
.dialog-text { margin-top: 16px; font-size: 14px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; line-height: 1.5; }
.dialog-actions.single { grid-template-columns: 1fr; }

/* 비용 표 */
.cost-table { display: grid; background: var(--grey-50); border-radius: var(--r-md); padding: 6px 16px; }
.cost-table div { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; font-size: 14px; color: var(--ink-2); }
.cost-table div + div { border-top: 1px solid var(--grey-100); }
.cost-table b { font-variant-numeric: tabular-nums; white-space: nowrap; }

@media (max-width: 860px) {
  .steps-list { padding-left: 20px; padding-right: 20px; }
  .steps-list li { grid-template-columns: 28px minmax(0, 1fr); }
  .steps-list li .btn { grid-column: 2; justify-self: start; }
}

/* ---------- 접고 펴는 카드 ---------- */

.page > .card + .card, .page > .card + .notice, .page > .notice + .card { margin-top: 12px; }
.import-card { margin-top: 12px; }
.collapse-head {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 16px; row-gap: 2px;
  width: 100%; padding: 20px 24px 20px 28px; border: 0; background: none; text-align: left; border-radius: var(--r-lg);
  transition: background 0.15s;
}
.collapse-head:hover { background: var(--grey-50); }
.collapse-title { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.collapse-title b { font-size: 17px; letter-spacing: -0.02em; }
.collapse-sub { grid-column: 1; font-size: 14px; color: var(--faint); }
.collapse-chev { grid-column: 2; grid-row: 1 / span 2; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; color: var(--faint); transition: transform 0.25s ease, background 0.15s; }
.collapse-head:hover .collapse-chev { background: var(--grey-100); }
.import-card.open .collapse-chev { transform: rotate(180deg); }
.collapse-body { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.3s cubic-bezier(0.2, 0.8, 0.2, 1); }
.import-card.open .collapse-body { grid-template-rows: 1fr; }
.collapse-inner { overflow: hidden; min-height: 0; }
.import-card .steps-list { padding-top: 0; border-top: 1px solid var(--line); margin: 0 28px; padding-left: 0; padding-right: 0; }
.import-card:not(.open) .collapse-inner { visibility: hidden; transition: visibility 0s 0.3s; }

@media (max-width: 860px) {
  .collapse-head { padding: 18px 16px 18px 20px; }
  .import-card .steps-list { margin: 0 20px; }
}

/* ---------- 포트폴리오 ---------- */

.pf-card { margin-top: 12px; }
.pf-empty {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px;
  padding: 36px 20px; border-radius: 18px; background: var(--grey-50); border: 1.5px dashed var(--grey-200);
}
.pf-empty b { font-size: 16px; }
.pf-empty span { font-size: 14px; color: var(--faint); max-width: 420px; }
.pf-empty .upload { margin-top: 14px; }
.pf-loading { display: flex; align-items: center; gap: 14px; padding: 24px 20px; border-radius: 18px; background: var(--grey-50); color: var(--accent-ink); }
.pf-loading b { display: block; color: var(--ink); font-size: 15px; }
.pf-loading span { display: block; color: var(--faint); font-size: 13px; }
.pf-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; font-size: 15px; color: var(--ink-2); }
.pf-toolbar b { color: var(--accent-ink); font-size: 17px; }
.pf-toolbar .actions { gap: 4px; }
.btn.danger-text { color: var(--bad); }
.pf-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; max-height: 520px; overflow-y: auto; padding: 2px; margin: -2px; }
.pf-page {
  position: relative; display: block; padding: 0; border: 0; border-radius: 12px; overflow: hidden;
  aspect-ratio: 4 / 3; background: var(--grey-100); cursor: pointer;
  box-shadow: inset 0 0 0 1px var(--grey-200); transition: box-shadow 0.15s, transform 0.1s;
}
.pf-page:active { transform: scale(0.97); }
.pf-page img { width: 100%; height: 100%; object-fit: contain; display: block; opacity: 0.55; transition: opacity 0.15s; }
.pf-page:hover img { opacity: 0.8; }
.pf-page.on { box-shadow: inset 0 0 0 2.5px var(--accent); }
.pf-page.on img { opacity: 1; }
.pf-label {
  position: absolute; left: 6px; bottom: 6px; padding: 2px 7px; border-radius: 6px;
  background: rgba(25, 31, 40, 0.72); color: #fff; font-size: 11px; font-weight: 700;
}
.pf-check {
  position: absolute; top: 6px; right: 6px; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.9); color: transparent; box-shadow: 0 0 0 1px var(--grey-200);
}
.pf-page.on .pf-check { background: var(--accent); color: #fff; box-shadow: none; }

@media (max-width: 860px) {
  .pf-grid { grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); }
  .pf-card .card-foot .actions { order: 2; }
}

/* ---------- 면접관 캐릭터 ---------- */

.iv { --lv: 0; position: relative; flex: none; width: 168px; height: 160px; display: grid; place-items: center; }
.iv-body { position: relative; overflow: visible; filter: drop-shadow(0 10px 24px rgba(255, 90, 31, 0.18)); transition: filter 0.3s; }
.iv-glow {
  position: absolute; inset: 18px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 90, 31, 0.32), rgba(255, 90, 31, 0) 70%);
  opacity: 0; transform: scale(calc(0.9 + var(--lv) * 0.5)); transition: opacity 0.4s;
}
.iv-eye { fill: #ff5a1f; transform-box: fill-box; transform-origin: center; transform: scaleY(calc(1 + var(--lv) * 0.35)); transition: transform 0.08s linear; }
.iv-eyes { transform-box: fill-box; transform-origin: center; }
.iv.blink .iv-eye { transform: scaleY(0.12); transition: transform 0.06s ease; }

/* 인사·질문하는 중: 천천히 숨쉬기 */
.stage[data-phase='intro'] .iv-body, .stage[data-phase='asking'] .iv-body { animation: ivBreathe 2.6s ease-in-out infinite; }
@keyframes ivBreathe { 50% { transform: translateY(-3px) scale(1.03); } }

/* 듣는 중: 뒤에 은은한 빛, 눈이 목소리에 반응 */
.stage[data-phase='listening'] .iv-glow { opacity: 1; }
.stage[data-phase='listening'] .iv-body { filter: drop-shadow(0 10px 30px rgba(255, 90, 31, 0.32)); }

/* 생각 중: 눈을 옆으로 천천히 굴리기 */
.stage[data-phase='thinking'] .iv-eyes { animation: ivThink 2.2s ease-in-out infinite; }
@keyframes ivThink { 0%, 100% { transform: translateX(0); } 30% { transform: translateX(-5px) translateY(-2px); } 65% { transform: translateX(5px) translateY(-2px); } }

@media (max-width: 860px) {
  .iv { width: 128px; height: 122px; }
  .iv-body { width: 112px; height: 104px; }
}

/* ---------- 베타 피드백 ---------- */

.feedback-card { display: flex; align-items: center; gap: 16px; padding: 20px 24px; background: linear-gradient(135deg, #fff, #fff6f1); }
.feedback-card .coach-face { width: 48px; height: 48px; border-radius: 14px; }
.feedback-card .coach-face img { width: 34px; height: 34px; }
.feedback-text { flex: 1; min-width: 0; }
.feedback-text p { margin: 2px 0 0; font-size: 14px; color: var(--muted); }
a.nav-item { text-decoration: none; }
.side-foot { display: grid; gap: 2px; }
@media (max-width: 860px) {
  .feedback-card { flex-wrap: wrap; }
  .feedback-card .actions { width: 100%; justify-content: flex-end; }
}

/* ---------- 베타 설문 ---------- */

.dialog.survey { width: min(560px, 100%); max-height: calc(100vh - 32px); display: flex; flex-direction: column; }
.survey-body { overflow-y: auto; margin: 16px -24px 0; padding: 0 24px; display: grid; gap: 22px; }
.sq > b { display: block; font-size: 15px; margin-bottom: 10px; }
.sq .segment .seg { height: 36px; padding: 0 14px; font-size: 14px; }
.scale { display: flex; gap: 6px; }
.scale .seg { flex: 1; min-width: 0; height: 40px; padding: 0; border: 0; border-radius: 10px; background: var(--grey-100); color: var(--ink-2); font-weight: 700; font-size: 15px; }
.scale .seg:hover { background: var(--grey-200); }
.scale .seg.on { background: var(--accent); color: #fff; }
.scale-cap { display: flex; justify-content: space-between; margin-top: 6px; font-size: 12px; color: var(--faint); }
.segment .seg.on { background: var(--ink); color: #fff; }
.consent { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--ink-2); cursor: pointer; }
.consent + .input { margin-top: 10px; }
@media (max-width: 860px) { .scale { gap: 4px; } .scale .seg { height: 36px; font-size: 13px; } }

/* ---------- 사이드바 프로모션 박스 ---------- */

.promo {
  position: relative; display: block; overflow: hidden; margin-bottom: 10px;
  padding: 16px 16px 16px 18px; min-height: 112px; border-radius: 18px;
  background: radial-gradient(120% 90% at 100% 100%, rgba(255, 90, 31, 0.55), rgba(255, 90, 31, 0) 60%), var(--dark);
  color: #fff; text-decoration: none; transition: transform 0.15s;
}
.promo:hover { transform: translateY(-2px); }
.promo:hover .promo-link::after { transform: translateX(3px); }
.promo-eyebrow { display: block; font-size: 12px; font-weight: 700; color: #ff8a5c; }
.promo-title { display: block; margin-top: 4px; font-size: 17px; line-height: 1.35; letter-spacing: -0.03em; }
.promo-link { display: inline-flex; align-items: center; gap: 4px; margin-top: 10px; font-size: 13px; color: var(--dark-muted); }
.promo-link::after { content: '→'; transition: transform 0.15s; }
.promo-moki { position: absolute; right: 8px; bottom: 6px; width: 64px; height: 64px; filter: drop-shadow(0 6px 14px rgba(255, 90, 31, 0.45)); transform: rotate(-8deg); }
.promo-close {
  position: absolute; top: 10px; right: 10px; display: grid; place-items: center; width: 24px; height: 24px;
  border: 0; border-radius: 8px; background: rgba(255, 255, 255, 0.08); color: var(--dark-muted);
}
.promo-close:hover { background: rgba(255, 255, 255, 0.16); color: #fff; }
@media (max-width: 860px) { .promo { display: none; } }

/* ---------- 면접 화면 모키: 3D 몸체 + 코드로 그린 눈 (랜딩과 같은 모키) ---------- */
.iv.iv3d { width: 220px; height: 220px; display: block; }
.iv3d .iv-glow { inset: 6%; }
.iv3d .iv-float { position: relative; width: 100%; height: 100%; }
.iv3d .iv-img { width: 100%; height: 100%; display: block; filter: drop-shadow(0 18px 40px rgba(255, 90, 31, 0.22)); transition: filter 0.3s; }
.iv3d .iv-eyes3d { position: absolute; left: 50%; top: 44%; width: 21%; height: 20%; translate: -50% -50%; display: flex; justify-content: space-between; }
.iv3d .iv-eyes3d i {
  width: 27%; height: 100%; border-radius: 999px; background: linear-gradient(180deg, #ff7b45, #ff5a1f 60%, #ef4a10);
  box-shadow: inset 0 3px 4px rgba(255, 255, 255, 0.35), 0 3px 10px rgba(255, 90, 31, 0.3);
  transform: scaleY(calc(1 + var(--lv) * 0.35)); transition: transform 0.08s linear;
}
.iv3d.blink .iv-eyes3d i { transform: scaleY(0.12); transition: transform 0.06s ease; }
.stage[data-phase='intro'] .iv3d .iv-float, .stage[data-phase='asking'] .iv3d .iv-float { animation: ivBreathe 2.6s ease-in-out infinite; }
.stage[data-phase='listening'] .iv3d .iv-img { filter: drop-shadow(0 18px 48px rgba(255, 90, 31, 0.5)); }
.stage[data-phase='thinking'] .iv3d .iv-eyes3d { animation: ivThink 2.2s ease-in-out infinite; }
/* 예전 그림용 움직임은 3D 모키에선 끈다 */
.stage .iv3d .iv-body { display: none; }
@media (max-width: 860px) { .iv.iv3d { width: 150px; height: 150px; } }

/* ---------- 내 모습 보기 (면접 화면 오른쪽 아래) ---------- */
.self-view {
  position: fixed; z-index: 60; right: 28px; bottom: 28px; width: 248px; aspect-ratio: 16 / 9;
  border-radius: 16px; overflow: hidden; background: #1c1c22;
  box-shadow: 0 0 0 1.5px rgba(255, 255, 255, 0.1), 0 16px 40px rgba(0, 0, 0, 0.45);
  transition: box-shadow 0.3s, width 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), height 0.3s, border-radius 0.3s;
  animation: svIn 0.4s cubic-bezier(0.2, 0.9, 0.25, 1.1);
}
@keyframes svIn { from { opacity: 0; transform: translateY(12px) scale(0.96); } }
.self-view video { width: 100%; height: 100%; object-fit: cover; display: block; transform: scaleX(-1); }
.self-view[data-phase='listening'] { box-shadow: 0 0 0 2.5px var(--accent), 0 0 30px rgba(255, 90, 31, 0.35), 0 16px 40px rgba(0, 0, 0, 0.45); }
.sv-name { position: absolute; left: 10px; bottom: 8px; padding: 2px 8px; border-radius: 6px; background: rgba(0, 0, 0, 0.5); color: #fff; font-size: 12px; font-weight: 700; }
.sv-toggle {
  position: absolute; top: 8px; right: 8px; display: grid; place-items: center; width: 28px; height: 28px;
  border: 0; border-radius: 8px; background: rgba(0, 0, 0, 0.45); color: #fff; opacity: 0; transition: opacity 0.2s;
}
.self-view:hover .sv-toggle, .sv-toggle:focus-visible { opacity: 1; }
.sv-toggle .sv-show { display: none; }
/* 접었을 때: 작은 카메라 버튼만 */
.self-view.collapsed { width: 44px; aspect-ratio: 1; border-radius: 14px; }
.self-view.collapsed video, .self-view.collapsed .sv-name { opacity: 0; }
.self-view.collapsed .sv-toggle { inset: 0; width: auto; height: auto; opacity: 1; background: var(--dark-2); border-radius: 14px; }
.self-view.collapsed .sv-hide { display: none; }
.self-view.collapsed .sv-show { display: block; }
@media (max-width: 860px) {
  .self-view { right: auto; bottom: auto; top: 64px; left: auto; width: 76px; aspect-ratio: 3 / 4; border-radius: 12px; transition: box-shadow 0.3s, width 0.3s, height 0.3s, border-radius 0.3s; }
  .self-view:not([style*='left']) { right: 12px; }
  .sv-toggle { opacity: 1; }
}

/* 모톡 로고: 글자는 currentColor, 말풍선만 주황 */
.motok-logo { display: block; height: 22px; width: auto; color: var(--ink); }
.brand .motok-logo { height: 21px; }
.brand small { margin-top: 6px; }
.brand-symbol { display: none; width: 30px; height: 30px; flex: none; }
@media (max-width: 860px) { .brand-symbol { display: block; } }
@media (max-width: 640px) { .brand-symbol { display: none; } .brand .motok-logo { height: 19px; } }

/* ---------- 화면 전환 ---------- */
/* 랜딩 ↔ 앱 ↔ 개인정보: 페이지를 옮길 때 부드럽게 겹쳐 바뀐다 */
@media (prefers-reduced-motion: no-preference) {
  @view-transition { navigation: auto; }
}
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .28s; }
/* 앱 안에서 화면을 바꿀 때는 사이드바는 그대로 두고 본문만 움직인다 */
.main { view-transition-name: page; }
.nav-item.on { view-transition-name: nav-on; }
html[data-vt]::view-transition-old(root), html[data-vt]::view-transition-new(root) { animation: none; }
html[data-vt]::view-transition-group(page) { animation: none; }
html[data-vt]::view-transition-old(page), html[data-vt]::view-transition-new(page) { width: 100%; height: 100%; object-fit: none; object-position: top center; }
html[data-vt="page"]::view-transition-old(page) { animation: vtOut .16s cubic-bezier(.4, 0, 1, 1) both; }
html[data-vt="page"]::view-transition-new(page) { animation: vtIn .36s cubic-bezier(.2, .8, .2, 1) .05s both; }
html[data-vt="swap"]::view-transition-old(page) { animation: vtFadeOut .14s ease both; }
html[data-vt="swap"]::view-transition-new(page) { animation: vtFadeIn .22s ease .04s both; }
::view-transition-group(nav-on) { animation-duration: .34s; animation-timing-function: cubic-bezier(.2, .8, .2, 1); }
@keyframes vtOut { to { opacity: 0; transform: translateY(-6px); } }
@keyframes vtIn { from { opacity: 0; transform: translateY(14px); } }
@keyframes vtFadeOut { to { opacity: 0; } }
@keyframes vtFadeIn { from { opacity: 0; } }
.nav-item { transition: background .2s, color .2s, transform .12s cubic-bezier(.2, .8, .2, 1); }

/* 면접 화면: 열 때 살짝 떠오르고, 닫을 때 흐려진다 */
.stage:not([hidden]) { animation: stageIn .34s cubic-bezier(.2, .8, .2, 1) both; }
.stage.closing { animation: stageOut .24s ease both; pointer-events: none; }
@keyframes stageIn { from { opacity: 0; transform: scale(.985); } }
@keyframes stageOut { to { opacity: 0; transform: scale(.99); } }

/* ---------- 모키의 팁 · 연습 카드 ---------- */
.tip-card { display: flex; gap: 14px; align-items: flex-start; padding: 16px 20px; border-radius: 16px; background: #fff5ee; }
.tip-card img { flex: none; width: 40px; height: 40px; }
.tip-card div { min-width: 0; }
.tip-eyebrow { display: block; font-size: 12px; font-weight: 700; color: #c2410c; letter-spacing: -0.01em; }
.tip-card b { display: block; margin-top: 3px; font-size: 15px; line-height: 1.5; color: var(--ink); }
.tip-card p { margin: 3px 0 0; font-size: 14px; line-height: 1.6; color: var(--ink-2); }
.tip-card.plain { background: var(--surface); }
.decision-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 20px 0; }
.decision-pair > div { background: #fff7f1; border-left: 3px solid #f48450; padding: 18px; border-radius: 4px 14px 14px 4px; min-width: 0; }
.decision-pair span { font-size: 12px; font-weight: 700; color: #ae4319; }
.decision-pair p { margin: 9px 0 0; line-height: 1.7; white-space: pre-wrap; overflow-wrap: anywhere; }
.experience-context { margin: 16px 0; }
.experience-context summary { cursor: pointer; color: var(--ink-2); font-size: 13px; margin-bottom: 14px; }
.practice-plan { margin: 22px 0 0; padding: 0; border: 0; min-width: 0; }
.practice-plan legend { font-size: 15px; font-weight: 700; margin-bottom: 8px; }
.practice-point { padding: 18px 0; border-bottom: 1px solid var(--line); }
.practice-point > label:first-child { display: flex; align-items: center; gap: 10px; font-weight: 650; cursor: pointer; }
.practice-point input[type=checkbox] { width: 18px; height: 18px; accent-color: #e9632a; }
.practice-point p { margin: 8px 0 12px 28px; color: var(--ink-2); white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.65; }
.point-cue { display: flex; align-items: center; gap: 14px; margin-left: 28px; font-size: 12px; color: var(--ink-2); }
.point-cue .input { flex: 1; min-width: 0; max-width: 420px; }
.single-practice { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 14px; padding: 22px 28px; background: #fff7f1; }
.single-practice span { font-size: 14px; }
.practice-review { padding: 22px; background: #faf8f5; border-radius: 16px; }
.practice-review-list { display: grid; gap: 10px; margin: 16px 0; }
.practice-review-point { padding: 16px; background: white; border: 1px solid #e6e2dc; border-radius: 12px; }
.practice-review-point > div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; font-size: 13px; }
.practice-review-point > div span { color: #886446; font-size: 12px; }
.practice-review-point.found > div span { color: #247051; }
.practice-review-point p { margin: 10px 0 !important; overflow-wrap: anywhere; }
.practice-review-point small { color: var(--ink-2); }
.practice-review > .btn { margin-top: 14px; }
@media(max-width:640px) { .decision-pair { grid-template-columns: 1fr; gap: 10px; } .point-cue { align-items: stretch; flex-direction: column; gap: 6px; } .single-practice { padding: 20px; } .practice-review { padding: 15px; } }
.tip-carousel-inner { width: 100%; }
.tip-carousel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.tip-controls, .tip-dots { display: flex; align-items: center; gap: 2px; }
.tip-controls { flex: none; }
.tip-controls button { display: grid; place-items: center; width: 28px; height: 28px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--ink-2); cursor: pointer; }
.tip-controls button:hover { background: #fff1e8; }
.tip-controls button:focus-visible { outline: 2px solid #e45b20; outline-offset: 2px; }
.tip-dots button span { width: 5px; height: 5px; border-radius: 8px; background: #d4d8de; transition: width 220ms, background 220ms; }
.tip-dots button[aria-pressed="true"] span { width: 16px; background: #ed692e; }
.tip-play { font-size: 11px; }
.tip-slides { display: grid; margin-top: 2px; }
.tip-slide { grid-area: 1 / 1; visibility: hidden; opacity: 0; }
.tip-slide.is-active { visibility: visible; opacity: 1; animation: tip-arrive 380ms ease-out; }
@keyframes tip-arrive { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) { .tip-slide.is-active { animation: none; } .tip-dots button span { transition: none; } }
.script-q .tip-card { margin-top: 18px; }
.ready + .ready-access + .tip-card, .ready-access + .tip-card { margin-top: 16px; }
.share-card { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 24px 28px; }
.share-card h3 { margin: 0; font-size: 17px; }
.share-card p { margin: 6px 0 0; font-size: 14px; color: var(--muted); line-height: 1.6; }
.share-card .btn { flex: none; }
.share-dialog { max-width: 420px; text-align: center; }
.share-preview { display: block; width: 100%; max-width: 300px; margin: 16px auto 4px; border-radius: 18px; box-shadow: 0 12px 40px rgba(0, 0, 0, .18); }
.share-dialog .dialog-actions a.btn { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }
@media (max-width: 600px) {
  .share-card { flex-direction: column; align-items: stretch; padding: 20px; }
}
.tip-carousel .tip-carousel-inner { flex: 1; min-width: 0; }

/* 화면 맨 아래 작은 정책 링크 */
.legal-foot { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 16px; margin: 56px 0 8px; padding-top: 20px; border-top: 1px solid var(--grey-200); font-size: 12px; color: var(--faint); }
.legal-foot a, .legal-foot .text-btn { font-size: 12px; font-weight: 500; color: var(--muted); text-decoration: none; }
.legal-foot a:hover, .legal-foot .text-btn:hover { color: var(--ink); text-decoration: underline; }
.legal-foot span { color: var(--faint); }

/* ---------- 인터랙션: 누를 때 · 닫힐 때 · 펼칠 때 ---------- */
/* 휴대폰에서 누르면 파란 하이라이트 대신 우리 반응이 보이고, 두 번 탭 확대 지연이 없게 */
button, a, summary, [role="button"], label { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }

/* 작은 버튼 · 탭 · 칩: 누르면 살짝 눌린다 (.btn은 위에서 이미 같은 반응) */
:where(.nav-arrow, .round-btn, .icon-btn, .seg, .mode-tab, .sub-chip, .home-shortcut, .level-opt, .exp-pick, .pt-pick, .pf-tab, .pf-page, .chip-link, .exp-keyword, .exp-keyword-filter, .drill-folder, .moki-poke, .ck, .page-back, .q-del, .nav-item) {
  transition: transform .12s cubic-bezier(.2, .8, .2, 1), background-color .15s, color .15s, box-shadow .15s;
}
:where(.nav-arrow, .round-btn, .icon-btn, .seg, .mode-tab, .sub-chip, .home-shortcut, .level-opt, .exp-pick, .pt-pick, .pf-tab, .pf-page, .chip-link, .exp-keyword, .exp-keyword-filter, .drill-folder, .moki-poke, .ck, .page-back, .q-del, .nav-item):not(:disabled):active { transform: scale(.96); }
/* 넓은 줄 · 카드: 줄어들면 어색해서 살짝 어두워지기만 */
:where(.sess, .q-open, .ch-invite, .ch-home.done, .ready-question-link, .promo, details > summary) { transition: filter .15s, background-color .15s; }
:where(.sess, .q-open, .ch-invite, .ch-home.done, .ready-question-link, .promo, details > summary):active { filter: brightness(.96); }
/* 글자 버튼: 누르는 동안 흐려진다 */
.text-btn { transition: opacity .15s, color .15s; }
.text-btn:not(:disabled):active { opacity: .55; }

/* 키보드로 이동할 때만 보이는 초점 테두리 (마우스 · 터치로 누를 땐 안 보인다) */
:where(button, a, summary, [tabindex]):focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.input { transition: border-color .15s, background-color .15s, box-shadow .15s; }

/* 팝업 · 토스트: 열릴 때처럼 닫힐 때도 짧게 */
.dialog-backdrop.closing { animation: fadeOut .16s ease both; pointer-events: none; }
.dialog-backdrop.closing .dialog { animation: dialogOut .16s ease both; }
@keyframes fadeOut { to { opacity: 0; } }
@keyframes dialogOut { to { opacity: 0; transform: translateY(8px) scale(.98); } }
.toast.out { animation: toastOut .2s ease both; }
@keyframes toastOut { to { opacity: 0; transform: translate(-50%, 8px); } }

/* 펼치기(리포트 답변 · 질문 목록 등): 내용이 위에서 살짝 내려오며 나타난다 */
details[open] > :not(summary) { animation: discIn .24s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes discIn { from { opacity: 0; transform: translateY(-4px); } }

/* 면접 끝 화면: 별점 한 번 (누르면 바로 저장) */
.quick-rate { margin-top: 40px; }
.stage-end .quick-rate p { margin: 0 0 8px; font-size: 15px; color: var(--dark-muted); }
.stars { display: inline-flex; gap: 4px; }
.star { width: 46px; height: 46px; display: grid; place-items: center; border: 0; border-radius: 12px; background: none; color: #5c5c66; cursor: pointer; transition: color .15s, transform .12s cubic-bezier(.2, .8, .2, 1); }
.star:not(:disabled):active { transform: scale(.9); }
.stars:hover .star { color: var(--accent); }
.stars:hover .star svg { fill: currentColor; }
.stars .star:hover ~ .star { color: #5c5c66; }
.stars .star:hover ~ .star svg { fill: none; }
.star.on { color: var(--accent); }
.star.on svg { fill: currentColor; }
.quick-rate.done .stars { pointer-events: none; }
.quick-rate.done .star.on { animation: starPop .32s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes starPop { 50% { transform: scale(1.18); } }

/* 홈 화면 앱 권유 (면접 끝 화면) */
.pwa-tip { margin-top: 28px; display: grid; justify-items: center; gap: 12px; animation: discIn .3s ease both; }
.stage-end .pwa-tip p { margin: 0; font-size: 15px; line-height: 1.6; color: var(--dark-muted); }
.stage-end .pwa-tip p b { color: #fff; font-weight: 700; }
.pwa-tip svg { vertical-align: -3px; color: #fff; }
