/* pane — 잉크와 형광펜.
   원본에서 필요한 것만 형광펜으로 집어 깨끗한 카드로 옮긴다는 서비스 성격을 그대로 쓴다.
   노란 형광펜(--mark)은 "뽑아낸 것"에만 쓴다: 제목의 강조, 데모의 추출 필드, 추천 요금제. */

:root {
  --paper: #F4F6F9;
  --surface: #FFFFFF;
  --sunk: #ECEFF4;
  --ink: #0F1A2B;
  --ink-2: #2B3649;
  --muted: #5D6778;
  --faint: #8A93A3;
  --line: #E1E5EC;
  --line-2: #CDD3DD;
  --mark: #FFE14D;
  --mark-soft: #FFF3B0;
  --on-mark: #1C1700;
  --ok: #157A4A;
  --ok-bg: #E3F4EA;
  --warn: #9A5B00;
  --warn-bg: #FFF1D6;
  --bad: #B8321B;
  --bad-bg: #FCE6E1;
  --info: #2C4BD6;
  --info-bg: #E6EBFF;
  --code-bg: #0F1A2B;
  --code-fg: #C9D3E3;
  --code-dim: #5F6F89;
  --code-tag: #8AA9FF;
  --code-str: #9FD8B5;
  --focus: #2C4BD6;
  --shadow: 0 1px 2px rgba(15, 26, 43, .06), 0 8px 24px -12px rgba(15, 26, 43, .18);
  --shadow-lg: 0 2px 4px rgba(15, 26, 43, .05), 0 24px 60px -24px rgba(15, 26, 43, .35);
  --r: 10px;
  --r-lg: 16px;
  --font: "IBM Plex Sans", "IBM Plex Sans KR", "IBM Plex Sans JP", system-ui, -apple-system, "Apple SD Gothic Neo", "Hiragino Sans", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --wrap: 1160px;
  --gut: 24px;
  color-scheme: light;
}
:lang(ko) { --font: "IBM Plex Sans KR", "IBM Plex Sans", system-ui, -apple-system, "Apple SD Gothic Neo", sans-serif; word-break: keep-all; }
:lang(ja) { --font: "IBM Plex Sans JP", "IBM Plex Sans", system-ui, -apple-system, "Hiragino Sans", sans-serif; line-break: strict; }

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0B111C; --surface: #121A28; --sunk: #0E1522; --ink: #E8EDF5; --ink-2: #C9D2DF; --muted: #8E99AB; --faint: #67728A;
    --line: #1E293A; --line-2: #2A374B; --mark-soft: #3A3410;
    --ok: #5FD08F; --ok-bg: #12301F; --warn: #F2B65A; --warn-bg: #33250C; --bad: #FF8A73; --bad-bg: #3A1810; --info: #9DB0FF; --info-bg: #18224A;
    --code-bg: #070C15; --focus: #9DB0FF;
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 8px 24px -12px rgba(0,0,0,.6);
    --shadow-lg: 0 2px 4px rgba(0,0,0,.4), 0 24px 60px -24px rgba(0,0,0,.8);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #0B111C; --surface: #121A28; --sunk: #0E1522; --ink: #E8EDF5; --ink-2: #C9D2DF; --muted: #8E99AB; --faint: #67728A;
  --line: #1E293A; --line-2: #2A374B; --mark-soft: #3A3410;
  --ok: #5FD08F; --ok-bg: #12301F; --warn: #F2B65A; --warn-bg: #33250C; --bad: #FF8A73; --bad-bg: #3A1810; --info: #9DB0FF; --info-bg: #18224A;
  --code-bg: #070C15; --focus: #9DB0FF;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 80px; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 16px/1.6 var(--font); -webkit-font-smoothing: antialiased; }
h1, h2, h3 { margin: 0; line-height: 1.2; letter-spacing: -.02em; font-weight: 700; }
p { margin: 0; }
a { color: inherit; }
img { max-width: 100%; height: auto; }
.mono { font-family: var(--mono); font-feature-settings: "zero" 0; letter-spacing: 0; }
.dim { color: var(--faint); }
.muted { color: var(--muted); }
.strong { font-weight: 600; text-decoration: none; }
.clip { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
.wrap-any { overflow-wrap: anywhere; }
.inline { display: inline; margin: 0; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
.skip { position: absolute; left: -9999px; top: 8px; background: var(--ink); color: var(--paper); padding: 8px 12px; border-radius: 6px; z-index: 100; }
.skip:focus { left: 8px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gut); }
.wrap.narrow { max-width: 820px; }

/* ── 버튼 ── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 8px; border: 1px solid var(--ink); background: var(--ink); color: var(--paper); font: 600 14px/1 var(--font); text-decoration: none; cursor: pointer; transition: transform .12s ease, background .15s ease, box-shadow .15s ease; white-space: nowrap; }
.btn:hover { box-shadow: 0 0 0 4px color-mix(in srgb, var(--ink) 12%, transparent); }
.btn:active { transform: translateY(1px); }
.btn-sm { height: 32px; padding: 0 12px; font-size: 13px; border-radius: 7px; }
.btn-lg { height: 48px; padding: 0 22px; font-size: 15px; border-radius: 10px; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line-2); }
.btn-ghost:hover { background: var(--surface); box-shadow: none; border-color: var(--ink); }
.btn-danger { background: var(--bad); border-color: var(--bad); color: #fff; }
.btn-block { width: 100%; }
.link-btn { background: none; border: 0; padding: 0; font: inherit; color: var(--muted); cursor: pointer; }
.link-btn:hover { color: var(--ink); }

/* ── 상단 ── */
.nav { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--paper) 82%, transparent); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.nav.scrolled, .page-app .nav { border-bottom-color: var(--line); }
.nav-in { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gut); height: 64px; display: flex; align-items: center; gap: 28px; }
.logo { display: inline-flex; align-items: center; gap: 9px; text-decoration: none; font: 700 19px/1 var(--font); letter-spacing: -.03em; }
.logo svg { width: 26px; height: 26px; }
.logo-mark { fill: var(--mark); }
.nav-links { display: flex; gap: 22px; font-size: 14px; }
.nav-links a { text-decoration: none; color: var(--muted); padding: 6px 0; border-bottom: 2px solid transparent; }
.nav-links a:hover, .nav-links a[aria-current] { color: var(--ink); }
.app-links a[aria-current] { border-bottom-color: var(--ink); }
.nav-admin { font-family: var(--mono); font-size: 13px; }
.nav-right { margin-left: auto; display: flex; align-items: center; gap: 14px; font-size: 14px; }
.nav-text { text-decoration: none; color: var(--ink-2); }
.lang { position: relative; }
.lang summary { list-style: none; display: inline-flex; align-items: center; gap: 6px; cursor: pointer; font: 500 12px/1 var(--mono); color: var(--muted); padding: 7px 8px; border-radius: 7px; }
.lang summary::-webkit-details-marker { display: none; }
.lang summary svg { width: 15px; height: 15px; }
.lang summary:hover, .lang[open] summary { background: var(--sunk); color: var(--ink); }
.lang-menu { position: absolute; right: 0; top: calc(100% + 6px); min-width: 140px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow); padding: 6px; display: grid; }
.lang-menu a { padding: 8px 10px; border-radius: 6px; text-decoration: none; font-size: 14px; }
.lang-menu a:hover { background: var(--sunk); }
.lang-menu a[aria-current] { font-weight: 600; }
.lang-menu a[aria-current]::after { content: " ✓"; color: var(--muted); }

/* ── 첫 화면 ── */
.hero { padding: 72px 0 96px; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 56px; align-items: center; }
.hero-title { font-size: clamp(48px, 6.6vw, 92px); line-height: 1.02; letter-spacing: -.045em; font-weight: 700; }
:lang(ja) .hero-title, :lang(ko) .hero-title { letter-spacing: -.035em; line-height: 1.08; }
.hero-title mark, .cta-in mark { background: none; color: inherit; position: relative; white-space: nowrap; z-index: 0; }
.hero-title mark::before { content: ""; position: absolute; z-index: -1; left: -.06em; right: -.08em; top: .52em; bottom: .02em; background: var(--mark); border-radius: .08em .14em .1em .18em; transform: skewX(-8deg) scaleX(0); transform-origin: left center; animation: swipe .7s cubic-bezier(.6, .05, .25, 1) .35s forwards; }
@keyframes swipe { to { transform: skewX(-8deg) scaleX(1); } }
.hero-sub { margin-top: 24px; font-size: 18px; line-height: 1.65; color: var(--ink-2); max-width: 30em; }
.hero-cta { margin-top: 32px; display: flex; gap: 12px; flex-wrap: wrap; }
.hero-note { margin-top: 18px; font-size: 13px; color: var(--muted); }

/* 대표 장면 */
.demo { position: relative; display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); border-radius: var(--r-lg); box-shadow: var(--shadow-lg); background: var(--surface); border: 1px solid var(--line); overflow: hidden; min-height: 400px; }
.pane-bar { display: flex; align-items: center; gap: 10px; height: 38px; padding: 0 14px; font-size: 11.5px; color: var(--code-dim); border-bottom: 1px solid rgba(255,255,255,.06); }
.pane-bar.light { color: var(--muted); border-bottom-color: var(--line); background: var(--surface); }
.pane-bar .mono { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pane-tag { margin-left: auto; font: 600 10.5px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; }
.pane-bar.light .pane-tag { margin-left: 0; color: var(--ink); }
.pane-bar .count { margin-left: auto; }
.pane-bar .count b { color: var(--ink); font-weight: 500; }
.dots { display: inline-flex; gap: 6px; }
.dots i { width: 9px; height: 9px; border-radius: 50%; background: #26324A; }
.demo-raw { background: var(--code-bg); color: var(--code-fg); position: relative; }
.code { margin: 0; padding: 18px 16px 22px; font: 12.5px/1.75 var(--mono); white-space: pre-wrap; word-break: break-all; color: var(--code-fg); }
.code .tk { color: var(--code-dim); }
.code .at { color: var(--code-tag); }
.code .st { color: var(--code-str); }
.code .v { color: #E9EEF7; border-radius: 3px; transition: background .25s, color .25s, box-shadow .25s; }
.code .v.hl { background: var(--mark); color: var(--on-mark); box-shadow: 0 0 0 2px var(--mark); }
.demo-out { position: relative; background: var(--paper); display: flex; flex-direction: column; }
.card-parsed { position: relative; z-index: 2; margin: 22px 20px 0; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); padding: 18px 18px 14px; }
.card-parsed dl { margin: 0; display: grid; gap: 14px; }
.card-parsed .f-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.card-parsed dt { font: 500 10.5px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--faint); margin-bottom: 6px; }
.card-parsed dd { margin: 0; font-size: 14px; min-height: 1.5em; color: var(--ink); }
.card-parsed .f-title { font-size: 17px; font-weight: 700; letter-spacing: -.015em; line-height: 1.35; }
.card-parsed .f-body { color: var(--ink-2); font-size: 13.5px; line-height: 1.6; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.card-parsed dd.in { animation: land .45s cubic-bezier(.2, .8, .2, 1); }
.card-parsed dd.in::after { content: ""; }
@keyframes land { from { opacity: 0; transform: translateY(6px); background: var(--mark-soft); } 60% { background: var(--mark-soft); } to { opacity: 1; transform: none; background: transparent; } }
.card-foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--line); font-size: 11.5px; }
.card-foot .mono { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.card-parsed.filed { animation: file .6s cubic-bezier(.6, 0, .3, 1) forwards; }
@keyframes file { to { transform: translateY(18px) scale(.94); opacity: 0; } }
.stack { position: relative; margin: -6px 28px 0; }
.stack i { display: block; height: 10px; margin: 0 8px; background: var(--surface); border: 1px solid var(--line); border-top: 0; border-radius: 0 0 10px 10px; }
.stack i + i { margin: 0 18px; opacity: .7; }
.chip { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 999px; background: var(--mark-soft); color: var(--on-mark); font: 500 11.5px/1 var(--font); white-space: nowrap; }
:root[data-theme="dark"] .chip, :root:not([data-theme="light"]) .chip { color: var(--ink); }
.chip-xs { height: 18px; font-size: 10.5px; }

/* ── 구역 ── */
.sec { padding: 104px 0; }
.sec-alt { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.sec-head { max-width: 640px; margin-bottom: 48px; }
.sec-head h2, .sec-grid h2, .cta-in h2 { font-size: clamp(30px, 3.6vw, 44px); letter-spacing: -.035em; }
.sec-head p { margin-top: 14px; color: var(--muted); font-size: 17px; }

.flow { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 0; counter-reset: f; position: relative; }
.flow li { position: relative; padding: 22px 22px 0 0; border-top: 2px solid var(--line-2); }
.flow li::before { content: ""; position: absolute; top: -7px; left: 0; width: 12px; height: 12px; border-radius: 50%; background: var(--paper); border: 2px solid var(--ink); }
.flow .flow-hl::before { background: var(--mark); }
.flow-n { display: block; font-size: 12px; color: var(--faint); margin-bottom: 10px; }
.flow h3 { font-size: 18px; margin-bottom: 8px; }
.flow .flow-hl h3 { display: inline; background: linear-gradient(transparent 58%, var(--mark) 58%, var(--mark) 92%, transparent 92%); }
.flow p { color: var(--muted); font-size: 14.5px; }

.feats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.feat { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 28px; }
.feat h3 { font-size: 19px; margin: 22px 0 8px; }
.feat p { color: var(--muted); font-size: 15px; }
.feat-vis { height: 112px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); padding: 16px; display: flex; flex-direction: column; justify-content: center; gap: 8px; overflow: hidden; font-size: 13px; }
.mini-search { display: flex; align-items: center; gap: 8px; height: 34px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: 8px; color: var(--ink); }
.mini-search svg { width: 15px; height: 15px; color: var(--muted); flex: none; }
.mini-search span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini-search span::after { content: ""; display: inline-block; width: 1.5px; height: 1em; background: var(--ink); vertical-align: -2px; margin-left: 2px; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.mini-hit { padding: 0 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini-hit mark { background: var(--mark); color: var(--on-mark); border-radius: 2px; padding: 0 1px; }
.mini-series { display: flex; gap: 8px; flex-wrap: wrap; }
.mini-series span { font: 500 13px/1 var(--mono); padding: 10px 12px; border-radius: 8px; background: var(--paper); border: 1px solid var(--line-2); }
.mini-series .gap { border-style: dashed; color: var(--bad); background: transparent; }
.mini-keep { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.mini-keep .strike { text-decoration: line-through; color: var(--faint); padding: 8px 10px; border: 1px dashed var(--line-2); border-radius: 8px; }
.mini-keep .keep { padding: 8px 10px; border-radius: 8px; background: var(--ok-bg); color: var(--ok); }
.mini-keep .arrow { color: var(--faint); }
.mini-dedupe { display: grid; gap: 5px; }
.mini-dedupe .ghost { height: 9px; border-radius: 4px; background: var(--sunk); width: 70%; }
.mini-dedupe .ghost + .ghost { width: 55%; }
.mini-dedupe .one { display: flex; justify-content: space-between; gap: 10px; padding: 9px 12px; border: 1px solid var(--line-2); border-radius: 8px; overflow: hidden; white-space: nowrap; }
.mini-dedupe .one b { font-weight: 500; color: var(--muted); }

.sources { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.source { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 26px; display: flex; flex-direction: column; gap: 10px; }
.source h3 { font-size: 19px; margin-top: 8px; }
.source p { color: var(--muted); font-size: 15px; flex: 1; }
.source code { font-size: 12px; color: var(--faint); padding-top: 14px; border-top: 1px solid var(--line); }
.badge { align-self: flex-start; display: inline-flex; align-items: center; height: 22px; padding: 0 9px; border-radius: 999px; font: 500 11.5px/1 var(--font); background: var(--sunk); color: var(--muted); white-space: nowrap; vertical-align: middle; }
.badge-ok { background: var(--ok-bg); color: var(--ok); }
.badge-mark { background: var(--mark); color: var(--on-mark); }

.sec-ink { background: var(--code-bg); color: #E8EDF5; }
.sec-ink .lead { color: #A9B4C6; margin-top: 14px; font-size: 17px; }
.sec-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 64px; align-items: center; }
.checks { list-style: none; margin: 32px 0 0; padding: 0; display: grid; gap: 16px; }
.checks li { position: relative; padding-left: 30px; color: #CFD7E4; font-size: 15.5px; }
.checks li::before { content: ""; position: absolute; left: 0; top: .3em; width: 18px; height: 18px; border-radius: 5px; background: var(--mark); }
.checks li::after { content: ""; position: absolute; left: 5px; top: calc(.3em + 4px); width: 8px; height: 5px; border-left: 2px solid var(--on-mark); border-bottom: 2px solid var(--on-mark); transform: rotate(-45deg); }
.cipher { background: #0A101B; border: 1px solid #1F2A3D; border-radius: var(--r-lg); overflow: hidden; }
.cipher-head { padding: 14px 18px; font-size: 11.5px; color: #7D8BA3; border-bottom: 1px solid #1F2A3D; text-transform: uppercase; letter-spacing: .05em; }
.cipher table { width: 100%; border-collapse: collapse; font-size: 13px; }
.cipher th { text-align: left; font-weight: 400; color: #6E7D96; padding: 12px 18px; width: 34%; vertical-align: top; border-bottom: 1px solid #141C2B; }
.cipher td { color: #DCE3EE; padding: 12px 18px 12px 0; border-bottom: 1px solid #141C2B; }
.cipher tr:last-child th, .cipher tr:last-child td { border-bottom: 0; }
.cipher td.dim { color: #6E7D96; }

/* 요금 */
.pricing { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 32px; box-shadow: var(--shadow); max-width: 880px; }
.tier-input { position: absolute; opacity: 0; pointer-events: none; }
.tiers { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); background: var(--sunk); border-radius: 12px; padding: 4px; gap: 4px; }
.tier { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 12px 6px 10px; border-radius: 9px; cursor: pointer; transition: background .15s, box-shadow .15s; }
.tier:hover { background: color-mix(in srgb, var(--surface) 60%, transparent); }
.tier-n { font: 600 22px/1.1 var(--mono); letter-spacing: -.02em; }
.tier-u { font-size: 11.5px; color: var(--muted); white-space: nowrap; }
.tier em { position: absolute; top: -9px; right: 6px; font: 600 10px/1 var(--font); font-style: normal; background: var(--mark); color: var(--on-mark); padding: 4px 6px; border-radius: 5px; }
.price-panel { display: none; align-items: center; justify-content: space-between; gap: 24px; padding: 32px 4px 28px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.price-main { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; }
.price-amt { font: 700 clamp(40px, 5vw, 56px)/1 var(--font); letter-spacing: -.04em; }
.price-amt span { font-size: 16px; font-weight: 500; color: var(--muted); letter-spacing: 0; margin-left: 4px; }
.price-meta { display: grid; gap: 4px; font-size: 14px; color: var(--muted); }
.price-meta strong { color: var(--ink); font-size: 15px; }
.prio { font-size: 12px; }
#tier-d10:checked ~ .tiers .tier-d10, #tier-d30:checked ~ .tiers .tier-d30, #tier-d50:checked ~ .tiers .tier-d50, #tier-d100:checked ~ .tiers .tier-d100, #tier-d500:checked ~ .tiers .tier-d500 { background: var(--surface); box-shadow: var(--shadow); }
#tier-d10:checked ~ .price-panels .panel-d10, #tier-d30:checked ~ .price-panels .panel-d30, #tier-d50:checked ~ .price-panels .panel-d50, #tier-d100:checked ~ .price-panels .panel-d100, #tier-d500:checked ~ .price-panels .panel-d500 { display: flex; }
.tier-input:focus-visible ~ .tiers { outline: 2px solid var(--focus); outline-offset: 3px; }
.calc { display: flex; align-items: center; gap: 14px; padding: 22px 4px; border-bottom: 1px solid var(--line); flex-wrap: wrap; font-size: 14px; }
.calc label { color: var(--muted); }
.calc input { width: 130px; height: 38px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--paper); color: var(--ink); font: 500 15px var(--mono); }
.calc output { font-size: 15px; }
.calc output b { background: linear-gradient(transparent 60%, var(--mark) 60%); font-weight: 700; }
.archive-plan { display: flex; justify-content: space-between; gap: 12px; padding: 18px 4px; border-bottom: 1px solid var(--line); font-size: 14px; color: var(--muted); flex-wrap: wrap; }
.archive-plan strong { color: var(--ink); }
.fine { margin-top: 18px; font-size: 13px; color: var(--muted); }
.fine b { color: var(--ink); font-weight: 600; }

.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 22px 40px 22px 0; font-size: 17px; font-weight: 600; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; position: absolute; right: 6px; top: 50%; width: 10px; height: 10px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: translateY(-70%) rotate(45deg); transition: transform .2s; }
.faq details[open] summary::after { transform: translateY(-30%) rotate(225deg); }
.faq p { padding: 0 40px 24px 0; color: var(--ink-2); }

.cta-band { padding: 120px 0; text-align: center; }
.cta-in { display: grid; justify-items: center; gap: 16px; }
.cta-in p { color: var(--muted); font-size: 17px; margin-bottom: 12px; }

.foot { border-top: 1px solid var(--line); padding: 36px 0 48px; font-size: 13px; color: var(--muted); }
.foot-in { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gut); display: grid; gap: 16px; }
.foot-row { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.foot-langs { display: flex; gap: 14px; }
.foot-langs a { text-decoration: none; }
.foot-langs a[aria-current] { color: var(--ink); font-weight: 600; }

/* ── 로그인 ── */
.auth { min-height: calc(100vh - 64px - 140px); display: grid; place-items: center; padding: 48px var(--gut); }
.auth-card { width: 100%; max-width: 400px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-lg); padding: 36px 32px; }
.auth-card h1 { font-size: 26px; }
.auth-card > .muted { margin-top: 6px; font-size: 14.5px; }
.auth-alt { margin-top: 20px; font-size: 14px; color: var(--muted); text-align: center; }
.auth-alt a { color: var(--ink); font-weight: 600; }

.form { display: grid; gap: 16px; margin-top: 24px; }
.field { display: grid; gap: 6px; font-size: 13px; font-weight: 500; color: var(--ink-2); min-width: 0; }
.field em { font-style: normal; color: var(--faint); font-weight: 400; }
.field input, .field textarea, .field select, .search input, .search select { width: 100%; height: 42px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--surface); color: var(--ink); font: 400 15px var(--font); transition: border-color .15s, box-shadow .15s; }
.field input.mono { font-family: var(--mono); font-size: 13.5px; }
.field textarea { height: auto; padding: 10px 12px; resize: vertical; }
.field input:focus, .field textarea:focus, .search input:focus, .search select:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px color-mix(in srgb, var(--ink) 12%, transparent); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.alert { margin-top: 18px; padding: 12px 14px; border-radius: 9px; font-size: 14px; }
.alert-ok { background: var(--ok-bg); color: var(--ok); }
.alert-bad { background: var(--bad-bg); color: var(--bad); }
.alert-note { background: var(--mark-soft); color: var(--ink); }

/* ── 앱 ── */
.app { padding-top: 36px; padding-bottom: 80px; }
.app-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 8px; flex-wrap: wrap; }
.app-head h1 { font-size: 28px; letter-spacing: -.03em; min-width: 0; }
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 24px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 20px; display: grid; gap: 8px; align-content: start; }
.stat-l { font-size: 13px; color: var(--muted); }
.stat-v { font-size: 26px; font-weight: 600; letter-spacing: -.02em; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.stat-v small { font-size: 15px; color: var(--faint); font-weight: 400; }
.stat-hint { font-size: 13px; color: var(--faint); }
.stat-link { font-size: 13px; color: var(--muted); text-decoration: none; }
.stat-link:hover { color: var(--ink); }
.meter { display: block; height: 6px; border-radius: 99px; background: var(--sunk); overflow: hidden; }
.meter i { display: block; height: 100%; width: var(--p); max-width: 100%; background: var(--ink); border-radius: inherit; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 24px; margin-top: 16px; }
.panel > h2 { font-size: 16px; letter-spacing: -.01em; margin-bottom: 16px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.panel.form { margin-top: 16px; gap: 14px; }
.panel.form h2 { margin-bottom: 0; }
.req-form { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) auto; gap: 12px; align-items: end; }
.req-form .btn { height: 42px; }
.empty { color: var(--muted); font-size: 14.5px; padding: 8px 0; }

.status { display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 8px; border-radius: 6px; font: 500 12px/1 var(--font); background: var(--sunk); color: var(--muted); white-space: nowrap; }
.status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.st-reviewing, .st-requested { background: var(--warn-bg); color: var(--warn); }
.st-approved, .st-trial { background: var(--info-bg); color: var(--info); }
.st-active { background: var(--ok-bg); color: var(--ok); }
.st-rejected, .st-cancelled { background: var(--bad-bg); color: var(--bad); }

.site-list, .post-list, .worker-list, .events { list-style: none; margin: 0; padding: 0; }
.site-item { padding: 14px 0; border-top: 1px solid var(--line); display: grid; gap: 6px; }
.site-item:first-child { border-top: 0; padding-top: 0; }
.site-main { display: flex; align-items: center; gap: 10px; min-width: 0; flex-wrap: wrap; }
.site-host { font-weight: 600; text-decoration: none; }
.site-url { font-size: 12px; color: var(--faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 1 1 200px; }
.site-meta { display: flex; align-items: center; gap: 14px; font-size: 13px; color: var(--muted); flex-wrap: wrap; }
.site-meta a:not(.btn) { color: var(--ink); }
.site-reason { font-size: 13.5px; color: var(--bad); background: var(--bad-bg); padding: 8px 10px; border-radius: 8px; }
.site-reason b { font-weight: 600; margin-right: 6px; }

.post-item a { display: grid; gap: 4px; padding: 14px 0; border-top: 1px solid var(--line); text-decoration: none; }
.post-item:first-child a { border-top: 0; }
.post-item a:hover .post-title { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.post-title { font-weight: 600; font-size: 15.5px; }
.post-ex { color: var(--muted); font-size: 14px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.post-meta { font-size: 11.5px; color: var(--faint); }
.star { color: #D4A400; margin-right: 6px; }

.search { display: grid; grid-template-columns: minmax(0, 1fr) 200px auto auto; gap: 10px; align-items: center; margin: 20px 0 8px; }
.check { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; color: var(--muted); white-space: nowrap; }
.pager { display: flex; justify-content: center; align-items: center; gap: 24px; margin-top: 28px; font-size: 14px; }
.pager a { text-decoration: none; }

.reader { max-width: 760px; }
.back { display: inline-block; font-size: 14px; color: var(--muted); text-decoration: none; margin-bottom: 18px; }
.back:hover { color: var(--ink); }
.reader-title { font-size: clamp(26px, 3.4vw, 36px); letter-spacing: -.03em; line-height: 1.25; }
.reader-meta { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 16px 0 32px; padding-bottom: 20px; border-bottom: 1px solid var(--line); font-size: 13.5px; color: var(--muted); align-items: center; }
.reader-meta a { color: var(--ink); }
.reader-body { font-size: 17px; line-height: 1.9; color: var(--ink); overflow-wrap: anywhere; }
.reader-body p { margin: 0 0 1em; }
.reader-body img { border-radius: 8px; }

.plan-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 20px; }
.plan-card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 22px; display: flex; flex-direction: column; gap: 6px; margin: 0; }
.plan-card.is-featured { border-color: var(--ink); }
.plan-card.is-current { border-color: var(--ok); box-shadow: 0 0 0 3px var(--ok-bg); }
.plan-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.plan-price { font-size: 30px; font-weight: 700; letter-spacing: -.03em; margin-top: 6px; }
.plan-price span { font-size: 14px; color: var(--muted); font-weight: 400; margin-left: 2px; }
.plan-desc { color: var(--muted); font-size: 14px; }
.plan-prio { font-size: 12px; color: var(--faint); flex: 1; }
.plan-card .btn { margin-top: 14px; }

/* 관리 */
.admin-tabs { display: flex; gap: 6px; margin-bottom: 20px; border-bottom: 1px solid var(--line); }
.admin-tabs a { padding: 10px 4px; margin-right: 14px; font-size: 14px; color: var(--muted); text-decoration: none; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.admin-tabs a[aria-current] { color: var(--ink); border-bottom-color: var(--ink); font-weight: 600; }
.seg { display: inline-flex; background: var(--sunk); padding: 3px; border-radius: 9px; font-size: 13px; }
.seg a { padding: 6px 12px; border-radius: 7px; text-decoration: none; color: var(--muted); }
.seg a[aria-current] { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.table { width: 100%; border-collapse: collapse; font-size: 14px; table-layout: fixed; }
.table th { text-align: left; font-size: 12px; font-weight: 500; color: var(--faint); padding: 0 12px 10px 0; border-bottom: 1px solid var(--line); }
.table td { padding: 14px 12px 14px 0; border-bottom: 1px solid var(--line); vertical-align: top; overflow: hidden; }
.table tr:last-child td { border-bottom: 0; }
.table .clip { font-size: 12px; }
.worker-list li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); font-size: 14px; flex-wrap: wrap; }
.worker-list li:first-child { border-top: 0; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--line-2); }
.dot.on { background: var(--ok); box-shadow: 0 0 0 3px var(--ok-bg); }
.admin-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.kv { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 10px 20px; margin: 0; font-size: 14px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; min-width: 0; }
.json { margin: 0; padding: 14px; background: var(--sunk); border-radius: 8px; font: 12px/1.6 var(--mono); overflow: auto; max-height: 360px; }
.events li { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); font-size: 13px; flex-wrap: wrap; }
.events li:first-child { border-top: 0; }
.role-form { display: flex; gap: 6px; }
.role-form select { height: 32px; padding: 0 8px; border: 1px solid var(--line-2); border-radius: 7px; background: var(--surface); color: var(--ink); font: 13px var(--mono); }
.role { font: 500 12px var(--mono); }
.role-superadmin { color: var(--bad); }

/* ── 좁은 화면 ── */
@media (max-width: 1000px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 48px; }
  .hero { padding-top: 40px; }
  .flow { grid-template-columns: 1fr; gap: 0; }
  .flow li { padding: 0 0 28px 30px; border-top: 0; border-left: 2px solid var(--line-2); }
  .flow li:last-child { border-left-color: transparent; padding-bottom: 0; }
  .flow li::before { top: 0; left: -7px; }
  .sources { grid-template-columns: 1fr; }
  .sec-grid { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .nav-links:not(.app-links) { display: none; }
  .admin-grid { grid-template-columns: 1fr; }
  .plan-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  :root { --gut: 16px; }
  .nav-in { gap: 14px; height: 58px; }
  .nav-right { gap: 8px; }
  .nav-text { display: none; }
  .app-links { gap: 14px; overflow-x: auto; scrollbar-width: none; }
  .page-app .nav-in { flex-wrap: wrap; height: auto; padding-top: 10px; row-gap: 4px; }
  .page-app .app-links { order: 3; width: 100%; }
  .sec { padding: 72px 0; }
  .hero-sub { font-size: 16.5px; }
  .demo { grid-template-columns: minmax(0, 1fr); }
  .code { font-size: 11.5px; }
  .feats { grid-template-columns: minmax(0, 1fr); }
  .feat { padding: 20px; }
  .pricing { padding: 18px; border-radius: 16px; }
  .tiers { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .tier-n { font-size: 17px; }
  .tier-u { font-size: 10px; white-space: normal; text-align: center; line-height: 1.2; }
  .price-panel .btn { width: 100%; }
  .stats { grid-template-columns: 1fr; }
  .req-form { grid-template-columns: 1fr; }
  .search { grid-template-columns: 1fr 1fr; }
  .search input { grid-column: 1 / -1; }
  .plan-grid { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .table { table-layout: auto; }
  .table th:nth-child(2), .table td:nth-child(2) { display: none; }
  .auth-card { padding: 28px 20px; }
  .cta-band { padding: 80px 0; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .hero-title mark::before { transform: skewX(-8deg) scaleX(1); }
}

/* ── 충전·결제 ── */
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wallet-top { display: grid; grid-template-columns: minmax(0, 320px) minmax(0, 1fr); gap: 20px; align-items: end; margin-top: 20px; }
.methods { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }
.method { border: 1px solid var(--line); border-radius: 12px; padding: 18px; display: grid; gap: 14px; margin: 0; background: var(--paper); }
.method-head { display: flex; gap: 12px; align-items: center; }
.method-head div { display: grid; gap: 2px; font-size: 13px; }
.method-head strong { font-size: 15px; }
.pm { width: 34px; height: 34px; border-radius: 9px; flex: none; display: grid; place-items: center; font: 700 13px/1 var(--font); }
.pm-kakaopay { background: #FEE500; }
.pm-kakaopay::after { content: "pay"; color: #191600; font-size: 11px; }
.pm-paypal { background: #003087; }
.pm-paypal::after { content: "P"; color: #fff; font-style: italic; }
.pm-unifi { background: #06C755; }
.pm-unifi::after { content: "₮"; color: #fff; }
.packs { border: 0; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 6px; }
.pack { position: relative; display: grid; gap: 2px; padding: 10px; border: 1px solid var(--line-2); border-radius: 9px; background: var(--surface); cursor: pointer; }
.pack input { position: absolute; opacity: 0; }
.pack:has(input:checked) { border-color: var(--ink); box-shadow: 0 0 0 2px color-mix(in srgb, var(--ink) 14%, transparent); }
.pack:has(input:focus-visible) { outline: 2px solid var(--focus); outline-offset: 2px; }
.pack-a { font: 600 15px/1.2 var(--mono); }
.pack-c { font-size: 11.5px; color: var(--muted); }
.two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; }
.rows { list-style: none; margin: 0; padding: 0; }
.rows li, .rows li a { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; gap: 12px; align-items: center; font-size: 13.5px; }
.rows li { padding: 10px 0; border-top: 1px solid var(--line); }
.rows li:has(a) { padding: 0; }
.rows li a { padding: 10px 0; text-decoration: none; grid-column: 1 / -1; }
.rows li:first-child { border-top: 0; }
.plus { color: var(--ok); }
.minus { color: var(--ink-2); }
.pstatus { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 6px; font: 500 12px/1 var(--font); background: var(--sunk); color: var(--muted); white-space: nowrap; }
.ps-submitted { background: var(--warn-bg); color: var(--warn); }
.ps-paid { background: var(--ok-bg); color: var(--ok); }
.ps-rejected, .ps-failed { background: var(--bad-bg); color: var(--bad); }
.pay { max-width: 920px; }
.pay-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.pay-facts .big { font-size: 26px; font-weight: 600; }
.pay-act { display: grid; gap: 14px; justify-items: stretch; }
.pay-act .alert { margin-top: 0; }
.code-chip { display: inline-block; padding: 4px 10px; border-radius: 7px; background: var(--mark); color: var(--on-mark); font-size: 15px; font-weight: 500; letter-spacing: .04em; user-select: all; }
.qr { justify-self: center; background: #fff; padding: 10px; border-radius: 12px; border: 1px solid var(--line); line-height: 0; }
.qr svg { width: 200px; height: 200px; }
.only-mobile { display: none; }
.plan-balance { display: flex; align-items: center; gap: 14px; margin-top: 16px; font-weight: 600; flex-wrap: wrap; }
.pay-confirm { display: flex; gap: 6px; margin-bottom: 6px; flex-wrap: wrap; }
.pay-confirm input { height: 32px; padding: 0 8px; border: 1px solid var(--line-2); border-radius: 7px; background: var(--surface); color: var(--ink); font-size: 12.5px; width: 150px; }
@media (max-width: 720px) {
  .wallet-top, .two, .pay-grid { grid-template-columns: minmax(0, 1fr); }
  .only-mobile { display: inline-flex; }
  .rows li, .rows li a { grid-template-columns: auto minmax(0, 1fr) auto; }
  .rows li > :last-child, .rows li a > :last-child { display: none; }
}
