/* klarwerk v2 — "작업대": 이미지 대신 눌러 보는 미니 도구. 종이·흑연·주황 1점. */
:root {
  --paper: #FBFBFB; --card: #FFFFFF; --surface: #F2F2F3;
  --line: #E4E5E8; --line-soft: #EEEFF1;
  --ink: #14161A; --ink-2: #4A4E57; --muted: #6B7079; --on-ink: #FFFFFF; --on-accent: #FFFFFF;
  --accent: #E5602A; --accent-ink: #C24A1C; --accent-deep: #A83E15; --tint: rgba(229, 96, 42, .12); --danger: #DC2626;
  --paper-rgb: 251, 251, 251; --ink-rgb: 20, 22, 26; --accent-rgb: 229, 96, 42; --accent2-rgb: 217, 86, 34; --grain: .05;
  --wm: "Noto Serif KR", serif;
  --sans: "Pretendard Variable", Pretendard, -apple-system, system-ui, sans-serif;
  --r: 10px; --gutter: clamp(20px, 5vw, 72px); --max: 1180px;
  --ease: cubic-bezier(.16, 1, .3, 1);
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; overflow-x: clip; color-scheme: light; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 16px/1.6 var(--sans); -webkit-font-smoothing: antialiased; word-break: keep-all; overflow-wrap: break-word; overflow-x: clip; }
h1, h2, h3, p, ol, ul, figure { margin: 0; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; margin: 0; }
a, button, input, select, textarea, label { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
[id] { scroll-margin-top: 80px; }
.skip { position: absolute; left: 16px; top: -60px; z-index: 30; padding: 8px 12px; border-radius: var(--r); background: var(--ink); color: var(--paper); font-size: 14px; text-decoration: none; }
.skip:focus { top: 12px; }

/* 워드마크: 명조 소문자 + 첫 k 위 주황 점 */
.wm { position: relative; display: inline-block; font: 600 22px/1 var(--wm); letter-spacing: -.01em; text-decoration: none; color: var(--ink); padding-top: .42em; }
.wm::before { content: ""; position: absolute; left: .06em; top: 0; width: .2em; height: .2em; border-radius: 50%; background: var(--accent); }

/* 상단 바 */
.top { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 64px; padding: 0 var(--gutter); background: color-mix(in srgb, var(--paper) 78%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line-soft); }
.top-right { display: flex; align-items: center; gap: 12px; }
.lang { display: inline-flex; gap: 2px; padding: 3px; border: 0; border-radius: var(--r); background: var(--surface); cursor: pointer; font: 500 12px/1 var(--sans); color: var(--muted); }
.lang span { padding: 6px 8px; border-radius: 7px; }
.lang .on { background: var(--card); color: var(--ink); }
.lang:hover span:not(.on) { color: var(--ink); }

/* 버튼 · 링크 */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 0 20px; border: 1px solid var(--accent-ink); border-radius: var(--r); background: var(--accent-ink); color: var(--on-accent); font: 600 15px/1.2 var(--sans); text-decoration: none; white-space: nowrap; cursor: pointer; transition: background-color .2s var(--ease), transform .12s var(--ease); }
.btn:hover { background: var(--accent-deep); border-color: var(--accent-deep); transform: translateY(-1px); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.btn-sm { min-height: 38px; padding: 0 14px; font-size: 14px; background: transparent; color: var(--ink); border-color: var(--line); }
.btn-sm:hover { background: var(--card); border-color: var(--ink-2); }
.link { font-weight: 600; color: var(--ink); text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 1.5px; text-underline-offset: .2em; }
.link:hover { text-decoration-thickness: 2.5px; }

/* 공통 섹션 폭 */
main > section, .foot { max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
h2 { font: 700 clamp(26px, 1.6rem + 1.6vw, 40px)/1.25 var(--sans); letter-spacing: -.02em; text-wrap: balance; overflow-wrap: anywhere; }
.sub { margin-top: 14px; max-width: 30em; font: 500 clamp(18px, 1rem + .7vw, 24px)/1.4 var(--sans); letter-spacing: -.01em; color: var(--ink); text-wrap: balance; }

/* 1. 첫 화면: 전체 화면 영상 위에 비전 문장 */
.hero { position: relative; isolation: isolate; max-width: none; padding: 0; min-height: calc(100svh - 64px); display: grid; align-items: center; overflow: hidden; }
.hero-canvas { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; display: block; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(180deg, rgba(var(--paper-rgb), .4) 0%, rgba(var(--paper-rgb), 0) 18%, rgba(var(--paper-rgb), 0) 82%, var(--paper) 100%); }
.hero { cursor: crosshair; }
/* 텍스처: 필름 그레인 */
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: var(--grain); mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .9 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); background-size: 240px 240px; }
.hero-copy { position: absolute; left: 0; right: 0; top: 50%; transform: translateY(-50%); width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); pointer-events: none; }
.hero-copy > * { opacity: 0; }
.hero-copy a { pointer-events: auto; }
.hero.is-revealed .hero-copy > * { opacity: 1; animation: rise .7s var(--ease) both; }
.hero.is-revealed .hero-copy > :nth-child(2) { animation-delay: .12s; }
.hero.is-revealed .hero-copy > :nth-child(3) { animation-delay: .24s; }
.hero.is-revealed .hero-copy > :nth-child(4) { animation-delay: .36s; }
.hero.is-revealed::before { background: linear-gradient(90deg, rgba(var(--paper-rgb), .8) 0%, rgba(var(--paper-rgb), .35) 36%, rgba(var(--paper-rgb), 0) 55%), linear-gradient(180deg, rgba(var(--paper-rgb), .4) 0%, rgba(var(--paper-rgb), 0) 18%, rgba(var(--paper-rgb), 0) 82%, var(--paper) 100%); transition: background .8s; }
.hero h1 { font: 700 clamp(34px, 1.6rem + 2.4vw, 60px)/1.12 var(--sans); letter-spacing: -.03em; text-wrap: balance; overflow-wrap: anywhere; max-width: 9.5em; color: var(--ink); }
.hero-wm { margin-bottom: 22px; }
.hero-wm .wm { font-size: 56px; }
.lede { margin-top: 24px; max-width: 28em; font-size: 18px; color: var(--ink-2); }
.cta-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 36px; }
.js .hero-copy > * { animation: rise .6s var(--ease) both; }
.js .hero-copy > :nth-child(2) { animation-delay: .1s; }
.js .hero-copy > :nth-child(3) { animation-delay: .2s; }
@keyframes rise { from { opacity: 0; transform: translateY(12px); } }

/* 작업대: 주간 배정표(벤토 첫 타일) */
.tile-bench .bench { border: 0; padding: 0; box-shadow: none; }
.bench { border: 1px solid var(--line); border-radius: var(--r); background: var(--card); padding: 20px; }
.bench-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.bench-head strong { font-size: 15px; }
.bench-head span { font-size: 13px; color: var(--muted); }
.board { display: grid; grid-template-columns: 28px repeat(7, minmax(0, 1fr)); gap: 6px; }
.day, .time, .corner { font-size: 12px; font-weight: 500; color: var(--muted); text-align: center; font-variant-numeric: tabular-nums; }
.time { display: flex; align-items: center; }
.cell { display: block; height: 40px; border: 1px dashed var(--line); border-radius: 6px; background: transparent; padding: 0; cursor: pointer; transition: background-color .18s var(--ease), border-color .18s var(--ease), transform .12s var(--ease); }
.cell:hover { border-color: var(--accent); background: var(--tint); }
.cell:active { transform: scale(.96); }
.cell.on { border: 0; background: var(--accent); }
.cell.on:hover { background: var(--accent-ink); }
.cell.other { border: 0; background: var(--surface); cursor: default; }
.cell.off { border: 0; background: repeating-linear-gradient(-45deg, transparent 0 5px, var(--line-soft) 5px 6px); cursor: default; }
.bench-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line-soft); font-size: 13px; color: var(--muted); }
.legend { display: inline-flex; align-items: center; gap: 6px; }
.sw { width: 12px; height: 12px; border-radius: 3px; background: var(--surface); }
.sw.on { background: var(--accent); }
.legend .sw + span { margin-right: 6px; }
.sum b { font-size: 15px; color: var(--ink); font-variant-numeric: tabular-nums; }
.sum .arrow { margin: 0 4px; color: var(--accent); }

/* 2. 만드는 것: 벤토 + 미니 도구 */
.work { padding-block: 72px; }
.tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 32px; }
.tile { display: flex; flex-direction: column; padding: 24px 24px 26px; border: 1px solid var(--line); border-radius: var(--r); background: var(--card); }
.tile h3 { font-size: 18px; font-weight: 600; line-height: 1.35; }
.tile p { margin-top: 4px; font-size: 14px; line-height: 1.5; color: var(--ink-2); }
.tile > .bench, .tile > .mini { margin-top: 22px; }
.tile > .mini { flex: 1; font-size: 15px; }
/* 현황판 + 지표 */
.overview { display: grid; grid-template-columns: 1.3fr 1fr; gap: 28px; align-content: center; }
.slots { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; align-content: start; }
.slots i { display: block; aspect-ratio: 1; border: 1px solid var(--line); border-radius: 6px; transition: background-color .15s, border-color .15s; }
.slots i:nth-child(4), .slots i:nth-child(11) { grid-row: span 2; aspect-ratio: auto; }
.slots i:hover { background: var(--tint); border-color: var(--accent); }
.slots .hot { background: var(--accent); border-color: var(--accent); }
.kpis { list-style: none; padding: 0; display: grid; gap: 18px; align-content: center; }
.kpis span { display: block; color: var(--muted); margin-bottom: 6px; }
.kpis b { display: block; height: 10px; border-radius: 4px; background: var(--surface); position: relative; }
.kpis b::after { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--w); border-radius: 5px; background: var(--ink-2); }
.kpis li:first-child b::after { background: var(--accent); }
.list { list-style: none; padding: 0; margin-top: 40px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 40px; border-top: 1px solid var(--line); }
.list li { padding: 18px 0; border-bottom: 1px solid var(--line-soft); }
.list b { display: block; font-weight: 600; }
.list span { display: block; margin-top: 3px; font-size: 14px; line-height: 1.5; color: var(--ink-2); }
.list-cta { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; padding-block: 24px; }
.list-cta b { color: var(--accent-ink); }

/* 3. 진행 방식: 선 위의 점 7개(가로 타임라인) */
.flow { padding-block: 88px; border-top: 1px solid var(--line); }
.flow strong { color: var(--accent-ink); }
.steps { list-style: none; padding: 0; margin-top: 56px; position: relative; counter-reset: s; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 0 16px; }
.steps::before { content: ""; position: absolute; left: 6px; right: calc((100% - 96px) / 7 - 6px); top: 5.25px; height: 1.5px; background: var(--line); }
.steps li { position: relative; padding-top: 30px; counter-increment: s; }
.steps li::after { content: ""; position: absolute; left: 0; top: 0; width: 12px; height: 12px; border-radius: 50%; background: var(--paper); border: 1.5px solid var(--muted); }
.steps li::before { content: counter(s, decimal-leading-zero); display: block; margin-bottom: 4px; font-size: 13px; font-weight: 500; color: var(--muted); font-variant-numeric: tabular-nums; }
.steps b { display: block; font-weight: 600; line-height: 1.35; }
.steps span { display: block; margin-top: 4px; font-size: 14px; color: var(--ink-2); }
.steps .key::after { left: -2px; top: -2px; width: 16px; height: 16px; background: var(--accent); border-color: var(--accent); }
.steps .key::before, .steps .key b { color: var(--accent-ink); }
.steps .key { position: relative; }
.gate { position: absolute; top: -4px; bottom: -12px; right: -8px; width: 0; border-left: 1.5px solid var(--accent); }
.gate b { position: absolute; top: -30px; left: 50%; transform: translateX(-50%); white-space: nowrap; padding: 3px 9px; border: 1px solid var(--accent); border-radius: 6px; background: var(--paper); font: 600 12px/1.3 var(--sans); color: var(--accent-ink); }
@supports (animation-timeline: view()) {
  .steps::before { transform-origin: left; animation: draw linear both; animation-timeline: view(); animation-range: entry 30% entry 90%; }
  @keyframes draw { from { transform: scaleX(0); } }
}

/* 4. 문의 */
.contact { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px 64px; align-items: start; padding-block: 72px 80px; border-top: 1px solid var(--line); }
.contact-copy p:not(.sub) { margin-top: 18px; max-width: 26em; color: var(--ink-2); }
.form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 14px; }
.field { display: grid; gap: 4px; min-width: 0; }
.full { grid-column: 1 / -1; }
.field > label { font-size: 13px; font-weight: 500; color: var(--ink-2); }
.form input:not([type="checkbox"]), .form select, .form textarea { width: 100%; min-height: 46px; padding: 0 12px; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); outline: 2px solid transparent; outline-offset: 1px; transition: border-color .15s, background-color .15s; }
.form textarea { padding-block: 11px; resize: vertical; }
.form :is(input, select, textarea):hover { border-color: var(--ink-2); }
.form :is(input, select, textarea):focus-visible { outline-color: var(--accent); border-color: var(--ink-2); border-radius: var(--r); }
.form :is(input, select, textarea):disabled { opacity: .55; cursor: not-allowed; }
.form [aria-invalid="true"] { border-color: var(--danger); }
.form ::placeholder { color: var(--muted); opacity: 1; }
.select { position: relative; display: block; }
.select select { appearance: none; padding-right: 36px; }
.select::after { content: ""; position: absolute; right: 14px; top: 50%; width: 8px; height: 8px; border-right: 1.5px solid var(--muted); border-bottom: 1.5px solid var(--muted); transform: translateY(-70%) rotate(45deg); pointer-events: none; }
.err { min-height: 18px; font-size: 13px; line-height: 1.4; color: var(--danger); }
.more { grid-column: 1 / -1; }
.more summary { cursor: pointer; font-size: 14px; font-weight: 500; color: var(--ink-2); padding: 6px 0; list-style: none; display: flex; align-items: center; gap: 8px; }
.more summary::-webkit-details-marker { display: none; }
.more summary::before { content: ""; width: 7px; height: 7px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(-45deg); transition: transform .15s; }
.more[open] summary::before { transform: rotate(45deg); }
.more-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 14px; padding-top: 8px; }
.check { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; cursor: pointer; }
.check input { flex: none; width: 18px; height: 18px; margin: 3px 0 0; accent-color: var(--accent); }
.check small { display: block; margin-top: 2px; font-size: 13px; color: var(--muted); }
.form-foot { grid-column: 1 / -1; display: flex; align-items: center; justify-content: flex-end; gap: 16px; }
.status { margin-right: auto; font-size: 14px; color: var(--danger); }
.status:empty { display: none; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; opacity: 0; }
.done { padding-top: 20px; border-top: 1.5px solid var(--ink); }
.done h3 { font: 600 20px/1.3 var(--sans); }
.done p { margin-top: 8px; color: var(--ink-2); }

/* 푸터 */
.foot { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; padding-block: 32px calc(32px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); }
.foot .wm { font-size: 30px; }
.foot p { display: flex; flex-wrap: wrap; gap: 20px; font-size: 14px; color: var(--muted); }
.foot a { text-decoration: none; color: var(--ink-2); font-weight: 500; }
.foot a:hover { text-decoration: underline; text-decoration-color: var(--accent); }

/* 반응형 */
@media (max-width: 959px) {
  .contact { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; gap: 22px; }
  .steps::before { display: none; }
  .steps li { padding: 0 0 0 32px; }
  .steps li::after { top: 24px; }
  .steps .key::after { top: 22px; }
  .gate { position: static; display: block; width: auto; margin-top: 16px; border-left: 0; border-top: 1.5px solid var(--accent); }
  .gate b { position: static; display: inline-block; transform: none; margin-top: 10px; }
  .tiles, .list { grid-template-columns: 1fr; }
}
@media (max-width: 639px) {
  .form, .more-grid { grid-template-columns: 1fr; }
  .bench { padding: 14px; }
  .board { gap: 4px; }
  .cell { height: 34px; }
  .btn-sm { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-copy > *, .hero.is-revealed .hero-copy > * { opacity: 1; animation: none; }
  .steps::before { animation: none; }
  .btn, .cell, .switch i, .switch i::after, .slots i { transition: none; }
}
