/* 회원가입 전용 스타일. 공통 요소는 styles.css와 account.css를 함께 사용합니다. */

.signup { max-width: 860px; margin: 0 auto; padding: clamp(8px, 2vw, 20px) var(--gutter) clamp(48px, 7vw, 96px); }
.signup-page { padding-bottom: 0 !important; }
.step-title { font-size: clamp(1.75rem, 4vw, 2.75rem); font-weight: 800; line-height: 1.22; letter-spacing: -.04em; outline: none; }
.step .answer { margin-bottom: 8px; align-items: flex-start; }
.step-lead { margin-bottom: clamp(18px, 2.6vw, 26px); padding-left: calc(clamp(40px, 4.4vw, 56px) + clamp(12px, 1.6vw, 20px)); color: var(--muted); font-size: clamp(1rem, 1.5vw, 1.15rem); line-height: 1.5; }
.step .card + .step-nav { margin-top: 14px; }
.field > span em, .field-label em { font-style: normal; color: var(--muted); font-weight: 500; }
.field-label { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; }
.field-label label { font-size: 15px; font-weight: 700; }
.help-btn {
  /* 보이는 원은 22px이고, 누르는 영역은 더 넓게 잡습니다 */
  position: relative; flex: none; display: grid; place-items: center; width: 22px; height: 22px; padding: 0;
  background: var(--ink); color: var(--white); border: 0; border-radius: 50%;
  font: 800 13px/1 var(--font); cursor: pointer;
}
.help-btn::before { content: ""; position: absolute; inset: -11px; }
.help-btn:hover { background: var(--orange); color: var(--ink); }

/* ---------- 진행 단계 ---------- */
.progress { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; margin-bottom: clamp(18px, 3vw, 28px); counter-reset: none; }
.progress li {
  display: flex; align-items: center; gap: 7px; padding-top: 9px;
  border-top: 4px solid var(--paper-2); color: var(--muted);
  font-size: 14px; font-weight: 700; white-space: nowrap;
}
.progress li span {
  display: grid; place-items: center; flex: none; width: 22px; height: 22px;
  background: var(--paper-2); border-radius: 50%; font-size: 13px; font-weight: 800;
}
.progress li.is-done { border-color: var(--ink); color: var(--ink); }
.progress li.is-done span { background: var(--ink); color: var(--white); }
.progress li.is-now { border-color: var(--orange); color: var(--ink); }
.progress li.is-now span { background: var(--orange); color: var(--ink); }

/* ---------- 내가 고른 내용 ---------- */
.picked { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: clamp(16px, 2.6vw, 24px); }
.picked-item {
  flex: 1 1 220px; display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 12px; align-items: center;
  padding: 10px 16px; background: var(--white); border-radius: var(--r-sm);
}
.picked-item small { grid-column: 1; color: var(--muted); font-size: 13px; font-weight: 600; }
.picked-item strong { grid-column: 1; font-weight: 800; letter-spacing: -.02em; }
.picked-item .text-btn { grid-column: 2; grid-row: 1 / span 2; font-size: 14px; }
.picked.is-on #picked-benefit-wrap { background: var(--orange); }
.picked.is-on #picked-benefit-wrap small { color: var(--ink); }

/* ---------- 1단계: 게임 ---------- */
.search-box {
  display: flex; align-items: center; gap: 14px; padding: 0 clamp(18px, 2.4vw, 26px);
  background: var(--paper); border-radius: 999px; border: 2px solid transparent;
}
.search-box:focus-within { border-color: var(--ink); }
.search-box svg { flex: none; }
.search-box input {
  flex: 1; min-width: 0; height: clamp(60px, 6.4vw, 72px); border: 0; outline: 0; background: transparent; color: var(--ink);
  font: 700 clamp(1.15rem, 2.1vw, 1.5rem)/1.2 var(--font); letter-spacing: -.02em;
  -webkit-appearance: none; appearance: none;
}
.search-box input::placeholder { color: #8A847B; font-weight: 500; }

.game-results { display: grid; gap: 6px; }
.game-results:not(:empty) { margin-top: 12px; }
.game-result {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; width: 100%;
  padding: 14px 18px; background: var(--paper); border: 0; border-radius: var(--r-sm);
  font: 700 17px var(--font); letter-spacing: -.02em; text-align: left; cursor: pointer;
}
.game-result::after { content: "선택"; flex: none; color: var(--muted); font-size: 14px; font-weight: 600; }
.game-result:hover { background: var(--paper-2); }
.game-result.is-blocked { color: var(--muted); }
.game-result.is-blocked::after { content: "서비스 안 함"; padding: 2px 10px; background: var(--ink); color: var(--white); border-radius: 999px; font-size: 13px; font-weight: 700; }
.game-none { padding: 14px 18px; border-radius: var(--r-sm); line-height: 1.45; background: var(--paper); }
.game-none strong { display: block; font-weight: 800; }
.game-none span { display: block; font-size: 15px; }
.game-none a { font-weight: 700; }

.chips-wrap { margin-top: 20px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { padding: 9px 16px; border: 0; border-radius: 999px; background: var(--paper); color: var(--ink); font-size: 15px; font-weight: 600; cursor: pointer; }
.chip:hover { background: var(--paper-2); }

.game-selected { display: flex; align-items: center; gap: 12px; margin-top: 14px; padding: 14px 18px; background: #FFE9DF; border-radius: var(--r-sm); }
.game-selected small { display: block; font-size: 13px; font-weight: 600; }
.game-selected strong { display: block; font-size: clamp(1.15rem, 2.1vw, 1.5rem); font-weight: 800; letter-spacing: -.03em; line-height: 1.25; }
.check-mark { position: relative; flex: none; width: 30px; height: 30px; background: var(--orange); border-radius: 50%; }
.check-mark::after { content: ""; position: absolute; left: 10px; top: 6px; width: 8px; height: 14px; border: solid var(--ink); border-width: 0 3px 3px 0; transform: rotate(40deg); }

.other-option {
  display: block; width: 100%; margin-top: 10px; padding: 14px 20px; text-align: left; cursor: pointer;
  background: transparent; border: 2px solid var(--paper-2); border-radius: var(--r-sm);
}
.other-option:hover { background: var(--white); }
.other-option.is-on { background: var(--white); border-color: var(--ink); }
.other-option strong { display: block; font-size: 16px; font-weight: 700; }
.other-option span { display: block; color: var(--muted); font-size: 14px; }

/* ---------- 2단계: PC방 혜택 ---------- */
.benefit-choice { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; }
.choice { position: relative; display: block; cursor: pointer; }
.choice input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.choice-body {
  display: flex; flex-direction: column; height: 100%;
  padding: clamp(18px, 2.6vw, 26px); border: 4px solid transparent; border-radius: var(--r-md);
  transition: transform .25s cubic-bezier(.2, .9, .3, 1.2), opacity .2s, border-color .15s, box-shadow .2s;
}
/* 고른 카드는 조금 크게, 고르지 않은 카드는 조금 작고 흐리게 */
.choice.is-picked { z-index: 1; }
.choice.is-picked .choice-body { transform: scale(1.03); box-shadow: 0 12px 28px rgba(26, 26, 26, .18); }
.benefit-choice.has-pick .choice:not(.is-picked) .choice-body { transform: scale(.94); opacity: .72; }
.choice-on .choice-body { background: var(--orange); }
.choice-off .choice-body { background: var(--white); }
.choice:hover .choice-body { border-color: rgba(26, 26, 26, .35); }
.choice input:focus-visible + .choice-body { outline: 3px solid var(--ink); outline-offset: 3px; }
.choice.is-picked .choice-body { border-color: var(--ink); }
.choice-top { display: flex; justify-content: space-between; align-items: center; }
.choice-radio { position: relative; width: 30px; height: 30px; background: var(--white); border: 3px solid var(--ink); border-radius: 50%; }
.choice.is-picked .choice-radio { background: var(--ink); }
.choice.is-picked .choice-radio::after { content: ""; position: absolute; left: 8px; top: 3px; width: 7px; height: 13px; border: solid var(--white); border-width: 0 3px 3px 0; transform: rotate(40deg); }
.choice-title { margin-top: 14px; font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 800; line-height: 1.2; letter-spacing: -.04em; }
.choice-effect { margin-top: 6px; line-height: 1.45; }
.choice-effect b { font-weight: 800; }
.choice-rows { display: block; margin-top: auto; padding-top: 16px; }
.choice-rows > span { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-top: 1px solid rgba(26, 26, 26, .18); }
.choice-rows small { flex: none; font-size: 14px; font-weight: 500; }
.choice-rows b { text-align: right; font-size: 15px; font-weight: 700; line-height: 1.35; }
/* PC방 혜택을 고를 수 없는 게임 */
.locked-notice { margin-bottom: 12px; padding: clamp(14px, 2.2vw, 20px) clamp(16px, 2.6vw, 24px); background: var(--ink); color: var(--white); border-radius: var(--r-md); line-height: 1.5; }
.locked-notice strong { display: block; font-size: clamp(1.1rem, 2vw, 1.3rem); font-weight: 800; letter-spacing: -.025em; color: var(--orange); }
.locked-notice span { display: block; margin-top: 2px; }
.choice.is-locked { cursor: not-allowed; }
.choice.is-locked:hover .choice-body { border-color: transparent; }
.choice.is-locked .choice-body { background: var(--paper-2); color: var(--muted); }
.choice.is-locked .pill-on { background: #8A847B; }
.choice.is-locked .pill-on i { background: var(--paper-2); }
.choice.is-locked .choice-rows > span { border-color: rgba(26, 26, 26, .1); }
.choice.is-locked .choice-radio { background: var(--paper-2); border-color: #8A847B; }
.choice.is-locked .choice-radio::before, .choice.is-locked .choice-radio::after {
  content: ""; position: absolute; left: 4px; right: 4px; top: 50%; height: 3px; margin-top: -1.5px; background: #8A847B; border-radius: 2px;
}
.choice.is-locked .choice-radio::before { transform: rotate(45deg); }
.choice.is-locked .choice-radio::after { transform: rotate(-45deg); }

/* 추천아이디 설명 팝업 */
.popup-help .help-steps { margin-top: 16px; }

/* 서비스되지 않는 게임 안내 팝업 */
.popup-notice { width: min(420px, calc(100vw - 32px)); }
.popup-notice .popup-actions { grid-template-columns: minmax(0, 1fr); }
.popup-notice .popup-text strong { color: var(--ink); font-weight: 800; }
.notice-mark { position: relative; display: block; width: 44px; height: 44px; margin-bottom: 14px; background: var(--ink); border-radius: 50%; }
.notice-mark::before, .notice-mark::after { content: ""; position: absolute; left: 12px; right: 12px; top: 50%; height: 3px; margin-top: -1.5px; background: var(--white); border-radius: 2px; }
.notice-mark::before { transform: rotate(45deg); }
.notice-mark::after { transform: rotate(-45deg); }
.choice-result { margin-top: 12px; padding: 14px 18px; background: var(--paper-2); border-radius: var(--r-sm); color: var(--muted); font-weight: 600; line-height: 1.45; }
.choice-result.is-on, .choice-result.is-off { color: var(--white); background: var(--ink); font-weight: 700; }
.help-line { margin-top: 10px; color: var(--muted); font-size: 15px; }
.help-line a { font-weight: 700; color: var(--ink); }

/* ---------- 3단계: 내 정보 ---------- */
.field-msg { margin: -8px 0 12px; font-size: 14px; font-weight: 600; line-height: 1.4; }
.field-msg:empty { display: none; }
.field-msg.is-ok { color: #1B7A3E; }
.field-msg.is-error { color: #C93F0C; }
.field input:disabled { opacity: .55; }
.agree { margin: 12px 0; }

/* ---------- 4단계: 최종 확인 ---------- */
.final { padding: clamp(22px, 3.4vw, 36px); border-radius: var(--r-md); }
.final.is-on { background: var(--orange); }
.final.is-off { background: var(--white); }
.final-label { font-size: 15px; font-weight: 700; }
.final-game { margin-top: 6px; font-size: clamp(1.9rem, 5vw, 3.25rem); font-weight: 800; line-height: 1.15; letter-spacing: -.045em; }
.final-benefit { margin-top: 6px; font-size: clamp(1.2rem, 2.6vw, 1.75rem); font-weight: 800; letter-spacing: -.03em; }
.final-rows { margin: 18px 0 0; }
.final-rows div { display: flex; justify-content: space-between; gap: 16px; padding: 9px 0; border-top: 1px solid rgba(26, 26, 26, .18); }
.final-rows dd { margin: 0; font-weight: 700; text-align: right; }
.final-warn { margin-top: 12px; padding: clamp(14px, 2.2vw, 20px) clamp(16px, 2.6vw, 22px); background: #FFE9DF; color: var(--ink); border-radius: var(--r-md); }
.final-warn strong { display: block; font-size: clamp(1.05rem, 1.9vw, 1.2rem); font-weight: 800; line-height: 1.45; letter-spacing: -.025em; }

/* ---------- 단계 이동 ---------- */
.step-nav { margin-top: 16px; }
.step-nav-two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 8px; }
.step-nav .btn { width: 100%; }
.btn:disabled { background: var(--paper-2); color: #8A847B; cursor: not-allowed; transform: none; }

/* ---------- 완료 ---------- */
.done-card .avatar { margin: 0 0 14px; }
.done-card .step-lead { margin: 12px 0 8px; padding-left: 0; color: var(--ink); font-weight: 700; }

/* ---------- 반응형 ---------- */
@media (max-width: 720px) {
  .benefit-choice { grid-template-columns: minmax(0, 1fr); }
  /* 고를 수 있는 카드를 먼저 보여 줍니다 */
  .benefit-choice.is-locked .choice-off { order: -1; }
  .step-lead { padding-left: 0; margin-top: 8px; }
  .progress li { flex-direction: column; align-items: flex-start; gap: 4px; font-size: 13px; }
  .field-row .btn { padding: 0 14px; }
}
@media (prefers-reduced-motion: reduce) {
  .choice-body { transition: none; }
}

/* 약관 보기 창 */
.policy-dialog { width: min(640px, calc(100vw - 32px)); max-height: min(760px, calc(100dvh - 32px)); }
.policy-dialog .popup-actions { grid-template-columns: 1fr; }
.policy-dialog-content { margin-top: 12px; }
.policy-dialog .policy-lead { margin-top: 0; font-size: 15px; }
.policy-dialog .policy-summary { margin-top: 14px; background: var(--paper-2); }
.policy-dialog .policy-summary div { padding: 12px 16px; background: var(--paper); }
.policy-dialog .policy-body { margin-top: 14px; padding: 0; font-size: 15px; }
.policy-dialog .policy-body section + section { margin-top: 22px; padding-top: 22px; }
.policy-dialog .policy-body h2 { font-size: 1.02rem; }
