:root { color-scheme: dark; --bg: #0f1b2d; --panel: #172742; --line: #2b4066; --text: #f4efe6; --muted: #a9b6cc; --accent: #ffcf6b; --danger: #ff9b8a; }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: radial-gradient(120% 80% at 50% 0%, #1d3558 0%, var(--bg) 60%); color: var(--text); font: 16px/1.6 -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", system-ui, sans-serif; min-height: 100vh; }
.page { width: min(100%, 560px); margin: 0 auto; padding: max(20px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(32px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left)); }
a { color: var(--accent); }
.back { display: inline-block; padding: 8px 0; min-height: 44px; }
h1 { font-size: 28px; line-height: 1.25; margin: 4px 0 8px; }
h2 { font-size: 17px; margin: 0 0 8px; }
.lead { color: var(--muted); margin: 0 0 12px; }
.facts { margin: 0 0 24px; padding-left: 20px; color: var(--muted); font-size: 15px; }
form, .done { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 20px 16px; }
.field { margin-bottom: 18px; }
label { display: block; font-weight: 600; margin-bottom: 6px; }
.hint { font-weight: 400; color: var(--muted); font-size: 13px; margin-left: 6px; }
input[type=text], input[type=url], input[type=email], textarea { display: block; width: 100%; min-width: 0; font: inherit; font-size: 16px; color: var(--text); background: #0e1a2f; border: 1px solid var(--line); border-radius: 10px; padding: 11px 12px; }
textarea { resize: vertical; min-height: 110px; }
input:focus-visible, textarea:focus-visible, button:focus-visible, a:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
input[aria-invalid=true], textarea[aria-invalid=true] { border-color: var(--danger); }
.help { color: var(--muted); font-size: 13px; margin: 0 0 8px; }
.error-text { color: var(--danger); font-size: 14px; margin: 6px 0 0; min-height: 0; }
.error-text:empty { display: none; }
.trap { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.privacy { border: 1px solid var(--line); border-radius: 12px; padding: 14px; margin: 4px 0 18px; font-size: 14px; color: var(--muted); }
.privacy h2 { color: var(--text); }
.privacy ul { margin: 0 0 12px; padding-left: 18px; }
.privacy strong { color: var(--text); margin-right: 4px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 600; color: var(--text); margin: 0; min-height: 44px; }
.check input { width: 22px; height: 22px; margin: 2px 0 0; flex: none; accent-color: var(--accent); }
.notice { margin: 0 0 14px; padding: 10px 12px; border-radius: 10px; background: #20365a; }
.notice.error { background: #4a2430; color: #ffd8d0; }
button { width: 100%; min-height: 48px; font: inherit; font-weight: 700; color: #2a1a00; background: var(--accent); border: 0; border-radius: 12px; cursor: pointer; }
button[disabled] { opacity: .6; cursor: progress; }
/* 게임 안 모달(iframe, ?embed=1)에서는 뒤로가기와 큰 제목을 숨기고 부모 모달이 제목·닫기를 맡는다. */
.embed body { background: var(--bg); min-height: 0; }
.embed .page { padding-top: 4px; padding-bottom: 16px; }
.embed .back, .embed header h1 { display: none; }
.embed .lead { margin-top: 0; }
.embed form, .embed .done { border-radius: 12px; }
.done code { background: #0e1a2f; padding: 2px 6px; border-radius: 6px; overflow-wrap: anywhere; }
/* 소개 자리 고르기 */
fieldset.placements { border: 0; padding: 0; margin: 0 0 18px; min-width: 0; }
fieldset.placements legend { font-weight: 600; margin-bottom: 6px; padding: 0; }
fieldset.placements .check { margin-bottom: 6px; font-weight: 600; }
fieldset.placements .check .hint { display: block; margin: 0; }
fieldset.placements[aria-invalid=true] legend { color: var(--danger); }
/* 접수 뒤 확인 링크 */
.status-box { border: 1px solid var(--line); border-radius: 12px; padding: 12px; margin: 12px 0; background: #13223b; }
.status-box .label { font-weight: 700; margin: 0 0 6px; }
.status-box input { font-size: 14px; }
.status-box .row { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.status-box .row > * { flex: 1 1 140px; }
.button-link { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; border: 1px solid var(--accent); border-radius: 12px; font-weight: 700; text-decoration: none; padding: 0 12px; }
.status-box .help { margin-top: 8px; }
@media (prefers-reduced-motion: no-preference) { button { transition: transform .1s; } button:active { transform: translateY(1px); } }
