/* Camto 위생사 화면 — 모바일(390px) 우선, 데스크톱(980px~)은 2단 */
:root {
  --paper: #FBF9F4;
  --paper-deep: #F3EFE6;
  --surface: #FFFFFF;
  --ink: #1C2420;
  --ink-soft: #3D4842;
  --muted: #5A655F;
  --faint: #6B756F;
  --line: #E4DED1;
  --sage: #147A5E;
  --sage-deep: #0F5D47;
  --sage-soft: #E6F4EE;
  --amber: #8A5A00;
  --amber-soft: #FFF4D9;
  --danger: #B3402D;
  --danger-soft: #FDEDE9;
  --radius: 18px;
  --shadow: 0 1px 2px rgba(28, 36, 32, 0.04), 0 8px 24px rgba(28, 36, 32, 0.05);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; scroll-padding-top: 16px; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  /* 방문자 정보가 다른 회사로 가지 않도록 외부 글꼴을 불러오지 않는다. 기기에 있는 한글 글꼴을 쓴다. */
  font-family: -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', 'Pretendard Variable', Pretendard, 'Noto Sans KR', 'Noto Sans CJK KR', 'Malgun Gothic', 'Segoe UI', Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  letter-spacing: -0.01em;
  word-break: keep-all;
  overflow-wrap: anywhere;
  -webkit-font-smoothing: antialiased;
}
h1, h2, p, ul, ol, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
button, input { font: inherit; color: inherit; letter-spacing: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
a { color: var(--sage-deep); text-underline-offset: 3px; }
:focus-visible { outline: 3px solid #1F9D7A; outline-offset: 2px; border-radius: 8px; }

.sr-only {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 10; padding: 10px 14px; border-radius: 10px;
  background: var(--ink); color: #fff; font-weight: 700; text-decoration: none;
}
.skip-link:focus { top: 12px; }

.page {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 14px 16px calc(40px + env(safe-area-inset-bottom));
}

/* ── 머리 ── */
.top { display: flex; align-items: center; justify-content: space-between; min-height: 44px; margin-bottom: 18px; }
.brand { display: inline-flex; align-items: center; gap: 9px; min-height: 44px; color: var(--ink); font-size: 18px; font-weight: 800; letter-spacing: -0.03em; text-decoration: none; }
.brand-mark { width: 30px; height: 30px; flex: none; }
.beta-chip { padding: 5px 11px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--muted); font-size: 13px; font-weight: 700; }

.layout { display: flex; flex-direction: column; gap: 16px; }
.col-main, .col-side { display: flex; flex-direction: column; gap: 16px; min-width: 0; }

/* ── 첫 화면 ── */
.hero { padding: 6px 2px 4px; }
.eyebrow { color: var(--sage-deep); font-size: 14px; font-weight: 700; }
.hero h1, .doc h1 { margin-top: 8px; font-size: clamp(27px, 7.4vw, 36px); line-height: 1.28; font-weight: 800; letter-spacing: -0.04em; }
.lede { margin-top: 12px; color: var(--ink-soft); font-size: 16px; }
.lede b { color: var(--ink); font-weight: 700; }
.pulse { display: flex; align-items: center; gap: 8px; margin-top: 14px; color: var(--muted); font-size: 14px; font-weight: 600; }
.dot { width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--sage); box-shadow: 0 0 0 4px rgba(20, 122, 94, 0.14); }

/* ── 카드 공통 ── */
.card { padding: 20px 18px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.card h2 { font-size: 19px; line-height: 1.4; font-weight: 800; letter-spacing: -0.03em; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.card-sub { margin-top: 8px; color: var(--ink-soft); font-size: 15px; }
.card-sub b { color: var(--ink); }
.card-sub.small { color: var(--muted); font-size: 13.5px; }

.text-btn { min-height: 44px; padding: 0 6px; border: 0; background: none; color: var(--muted); font-size: 14px; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.text-btn:hover { color: var(--ink); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  width: 100%; min-height: 52px; padding: 0 18px; border: 1px solid transparent; border-radius: 14px;
  font-size: 17px; font-weight: 800; letter-spacing: -0.02em; text-decoration: none; transition: background-color 0.15s, transform 0.1s;
}
.btn:active { transform: scale(0.985); }
.btn:disabled { opacity: 0.6; cursor: progress; }
.btn.primary { background: var(--sage); color: #fff; }
.btn.primary:hover { background: var(--sage-deep); }
.btn.dark { background: var(--ink); color: #fff; }
.btn.dark:hover { background: #000; }
.btn.ghost { border-color: var(--line); background: var(--surface); color: var(--ink); font-size: 15.5px; font-weight: 700; min-height: 48px; }
.btn.ghost:hover { background: var(--paper); }
.btn.ghost.danger { color: var(--danger); }
.btn.small { width: auto; min-height: 44px; padding: 0 16px; border-radius: 12px; background: var(--ink); color: #fff; font-size: 15px; }
.btn.source { min-height: 48px; background: var(--sage-soft); color: var(--sage-deep); font-size: 16px; }
.btn.source:hover { background: #D5ECE2; }

/* ── 조건 빈칸 ── */
.madlib { margin-top: 12px; font-size: clamp(19px, 5.3vw, 22px); line-height: 2.5; font-weight: 600; letter-spacing: -0.03em; }
.blank {
  display: inline; margin: 0 1px; padding: 7px 10px; border: 0; border-bottom: 2px solid var(--sage); border-radius: 10px 10px 4px 4px;
  background: var(--sage-soft); color: var(--sage-deep); font-weight: 800; line-height: 1.3;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.blank::after { content: '▾'; margin-left: 5px; font-size: 0.7em; opacity: 0.75; }
.blank:hover, .blank.is-open { background: #D5ECE2; }
.blank.is-open { border-bottom-color: var(--ink); color: var(--ink); }
.nowrap { white-space: nowrap; }
.hint { margin-top: 4px; color: var(--muted); font-size: 14px; }

.picker { margin-top: 14px; padding: 16px 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--paper); }
.picker-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.picker-head b { display: block; font-size: 16.5px; font-weight: 800; outline: none; }
.picker-note { margin-top: 2px; color: var(--muted); font-size: 13.5px; line-height: 1.5; }
.tabs { display: flex; gap: 6px; margin-bottom: 12px; padding: 4px; border-radius: 12px; background: var(--paper-deep); }
.tab { flex: 1; min-height: 44px; border: 0; border-radius: 9px; background: none; color: var(--muted); font-size: 15px; font-weight: 700; }
.tab.is-on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(28, 36, 32, 0.12); }
.tab i { display: inline-block; min-width: 18px; margin-left: 5px; padding: 0 5px; border-radius: 999px; background: var(--sage); color: #fff; font-size: 11.5px; font-style: normal; line-height: 18px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips + .chips { margin-top: 10px; }
.chip {
  min-height: 44px; padding: 0 15px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface);
  color: var(--ink-soft); font-size: 15.5px; font-weight: 600;
}
.chip:hover { border-color: #B9C7BF; }
.chip.is-on { border-color: var(--sage); background: var(--sage); color: #fff; font-weight: 700; }
.chips.days .chip { flex: 1 0 44px; min-width: 44px; padding: 0; }
.field-label { display: block; margin: 16px 0 6px; font-size: 14.5px; font-weight: 700; }
.field-label span { margin-left: 4px; color: var(--muted); font-size: 12.5px; font-weight: 600; }
.input {
  width: 100%; min-height: 52px; padding: 0 14px; border: 1px solid #CFC8B8; border-radius: 12px; background: var(--surface);
  font-size: 17px; font-weight: 600;
}
.input::placeholder { color: #8F9893; font-weight: 500; }
.input:focus { border-color: var(--sage); outline: 3px solid rgba(20, 122, 94, 0.2); outline-offset: 0; }
.picker .text-btn { margin-top: 6px; padding: 0; }

.conditions .btn.primary { margin-top: 18px; }
.form-note { margin-top: 10px; padding: 11px 13px; border-radius: 12px; background: var(--danger-soft); color: #8E2F20; font-size: 14.5px; font-weight: 600; }
.form-note.is-ok { background: var(--sage-soft); color: var(--sage-deep); }
.form-note.is-info { background: var(--amber-soft); color: #6B4700; }

/* ── 이용 방법 ── */
.steps ol { display: grid; gap: 10px; counter-reset: step; }
.steps li { display: grid; grid-template-columns: 30px 1fr; column-gap: 12px; align-items: start; padding: 2px 4px; counter-increment: step; }
.steps li::before {
  content: counter(step); grid-row: span 2; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%;
  background: var(--paper-deep); color: var(--sage-deep); font-size: 14px; font-weight: 800;
}
.steps b { font-size: 15.5px; font-weight: 700; }
.steps span { color: var(--muted); font-size: 14px; }

/* ── 결과 ── */
.results { display: flex; flex-direction: column; gap: 12px; scroll-margin-top: 12px; }
.results-head { padding: 6px 2px 0; }
.results-head h2, .empty h2 { font-size: 20px; line-height: 1.4; font-weight: 800; letter-spacing: -0.03em; }
.results-head h2 b { color: var(--sage-deep); }
.near-head { margin-top: 14px; }
.near-head h2 b { color: var(--amber); }
.basis { margin-top: 3px; color: var(--muted); font-size: 13.5px; }
.basis.center { text-align: center; }
.notice { padding: 11px 13px; border-radius: 12px; background: var(--amber-soft); color: #6B4700; font-size: 14px; font-weight: 600; }

.job-list { display: grid; gap: 12px; }
.job { padding: 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); box-shadow: var(--shadow); }
.job.is-near { border-color: #EBD9A8; }
.near-flag { display: inline-block; margin-bottom: 12px; padding: 4px 10px; border-radius: 8px; background: var(--amber-soft); color: var(--amber); font-size: 13.5px; font-weight: 800; }
.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 14px; }
.fact { min-width: 0; }
.fact dt { color: var(--muted); font-size: 12.5px; font-weight: 700; line-height: 1.4; }
.fact dd { margin-top: 1px; font-size: 17px; line-height: 1.4; font-weight: 800; letter-spacing: -0.03em; }
.fact dd small { display: block; margin-top: 2px; color: var(--muted); font-size: 12.5px; font-weight: 600; letter-spacing: -0.01em; }
.fact dd.na { color: var(--faint); font-size: 14.5px; font-weight: 600; }
.job-title {
  display: -webkit-box; margin-top: 13px; padding-left: 11px; border-left: 3px solid var(--line); overflow: hidden;
  color: var(--ink-soft); font-size: 14.5px; line-height: 1.55; -webkit-box-orient: vertical; -webkit-line-clamp: 3; line-clamp: 3;
}
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.tags span { padding: 3px 9px; border-radius: 7px; background: var(--paper-deep); color: var(--ink-soft); font-size: 12.5px; font-weight: 700; }
.job-foot { margin-top: 14px; }
.job-meta { margin-top: 8px; color: var(--muted); font-size: 13px; text-align: center; }

.more { margin-top: 2px; }
.empty { padding: 26px 20px; border: 1px dashed #CFC8B8; border-radius: var(--radius); background: var(--surface); text-align: center; }
.empty p { margin-top: 8px; color: var(--ink-soft); font-size: 15px; }
.widen { padding: 14px 16px; border-radius: 14px; background: var(--paper-deep); }
.widen p { color: var(--ink-soft); font-size: 14.5px; font-weight: 600; }
.widen-list { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.empty .widen-list { justify-content: center; }
.widen-chip { border-color: var(--sage); color: var(--sage-deep); font-weight: 700; }
.widen-chip b { margin-left: 4px; }
.disclaimer { padding: 4px 4px 0; color: var(--muted); font-size: 13.5px; line-height: 1.6; }

.skeleton { display: grid; gap: 12px; }
.skeleton div { height: 18px; border-radius: 8px; background: linear-gradient(90deg, #EFEBE2 25%, #F7F4EC 40%, #EFEBE2 60%); background-size: 300% 100%; animation: shimmer 1.3s linear infinite; }
.skeleton div:nth-child(1) { width: 62%; height: 24px; }
.skeleton div:nth-child(3) { width: 84%; }
@keyframes shimmer { from { background-position: 100% 0; } to { background-position: 0 0; } }

/* ── 문자 알림 ── */
.recap { display: grid; gap: 2px; margin-top: 14px; padding: 12px 14px; border-radius: 12px; background: var(--paper); font-size: 15px; font-weight: 700; }
.recap-label { color: var(--muted); font-size: 12.5px; font-weight: 700; }
.consent { margin-top: 16px; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--paper); }
.check { display: grid; grid-template-columns: 28px 1fr; gap: 10px; align-items: start; min-height: 44px; font-size: 15.5px; font-weight: 600; cursor: pointer; }
.check input { width: 26px; height: 26px; margin: 1px 0 0; accent-color: var(--sage); }
.check b { color: var(--sage-deep); }
.consent-table { display: grid; gap: 8px; margin-top: 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.consent-table div { display: grid; grid-template-columns: 68px 1fr; gap: 10px; font-size: 13.5px; line-height: 1.55; }
.consent-table dt { color: var(--muted); font-weight: 700; }
.consent-table dd { color: var(--ink-soft); }
.consent-note { margin-top: 10px; color: var(--muted); font-size: 13px; line-height: 1.55; }
.contact { font-weight: 700; color: var(--ink); }
.promises { display: grid; gap: 6px; margin-top: 14px; }
.promises li { position: relative; padding-left: 24px; color: var(--ink-soft); font-size: 14.5px; }
.promises li::before { content: '✓'; position: absolute; left: 3px; color: var(--sage); font-weight: 800; }
.alert-card .btn.dark { margin-top: 16px; }
.done-actions { display: grid; gap: 8px; margin-top: 16px; }

/* ── 소개 ── */
.about-list { display: grid; gap: 14px; margin-top: 14px; }
.about-list li { position: relative; padding-left: 16px; color: var(--ink-soft); font-size: 15px; line-height: 1.65; }
.about-list li::before { content: ''; position: absolute; left: 0; top: 0.72em; width: 6px; height: 6px; border-radius: 50%; background: var(--sage); }
.about-list b { color: var(--ink); font-weight: 700; }

.foot { display: grid; gap: 4px; margin-top: 28px; padding: 20px 4px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; line-height: 1.6; }
.foot b { color: var(--ink-soft); }
.foot a { display: inline-block; padding: 8px 0; color: var(--ink-soft); font-weight: 700; }

/* ── 처리방침 문서 ── */
.doc { max-width: 680px; margin: 0 auto; padding: 6px 2px; }
.doc section { margin-top: 26px; }
.doc h2 { font-size: 18px; font-weight: 800; letter-spacing: -0.03em; }
.doc section p, .doc section ul { margin-top: 8px; color: var(--ink-soft); font-size: 15.5px; }
.doc section ul { display: grid; gap: 6px; padding-left: 18px; list-style: disc; }
.doc section b { color: var(--ink); }
.doc-meta { margin: 28px 0 16px; color: var(--muted); font-size: 14px; }
.doc .btn { width: auto; }

@media (min-width: 560px) {
  .page { padding-left: 24px; padding-right: 24px; }
  .card { padding: 24px; }
  .facts { grid-template-columns: 1.6fr 1fr 1.3fr 1.1fr; }
  .job-foot { display: flex; align-items: center; gap: 14px; }
  .job-foot .btn { width: auto; flex: none; padding: 0 20px; }
  .job-meta { margin-top: 0; text-align: left; }
  .done-actions { grid-template-columns: 1fr 1fr; }
}

@media (min-width: 980px) {
  .page { padding: 22px 32px 56px; }
  .top { margin-bottom: 26px; }
  .layout { display: grid; grid-template-columns: minmax(0, 420px) minmax(0, 1fr); gap: 44px; align-items: start; }
  .hero h1 { font-size: 38px; }
  .madlib { font-size: 21px; }
  .results-head h2, .empty h2 { font-size: 22px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* ── 공개 화면 다듬기: 결과 위 조건 줄, 링크 보내기 ── */
.cond-bar {
  position: fixed; top: max(8px, env(safe-area-inset-top)); left: 16px; right: 16px; z-index: 5;
  max-width: 528px; margin: 0 auto;
  display: flex; align-items: center; gap: 10px;
  padding: 6px 6px 6px 16px; border: 1px solid var(--line); border-radius: 999px;
  background: rgba(255, 255, 255, 0.94); box-shadow: var(--shadow);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  color: var(--ink); font-size: 14.5px; font-weight: 700;
}
.cond-bar > span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cond-bar button {
  flex: none; min-height: 40px; padding: 0 14px; border: 0; border-radius: 999px;
  background: var(--sage-soft); color: var(--sage-deep); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer;
}
.cond-bar button:hover { background: #D8EDE4; }
.share {
  display: grid; gap: 12px; padding: 18px; border: 1px dashed #C9D9D0; border-radius: var(--radius); background: var(--sage-soft);
}
.share p { color: var(--ink-soft); font-size: 15px; line-height: 1.6; }
.share p b { display: block; color: var(--ink); font-size: 16px; font-weight: 800; letter-spacing: -0.02em; }
.share .btn { width: 100%; }
.share .form-note { margin: 0; word-break: break-all; }
.share .form-note.is-ok { background: var(--surface); }
.about-list a, .hero a { color: var(--sage-deep); font-weight: 700; text-underline-offset: 3px; }
@media (min-width: 980px) {
  .cond-bar { display: none; }
}
