/* Linea landing page. Requires styles/tokens.css. */
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  font-weight: 400;
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  word-break: keep-all;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; border: 0; background: none; cursor: pointer; color: inherit; }
img { display: block; max-width: 100%; }
.container { width: min(var(--container), calc(100% - 32px)); margin: 0 auto; }

/* OS-specific content: <html data-os="win|other"> */
html[data-os="win"] .os-mac, html[data-os="win"] .os-other,
html[data-os="mac"] .os-win, html[data-os="mac"] .os-other,
html[data-os="other"] .os-win, html[data-os="other"] .os-mac { display: none !important; }

/* ---------- Nav ---------- */
.nav-wrap { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 96%, transparent); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.nav { height: 64px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; }
.logo { display: flex; align-items: center; gap: 8px; font-weight: 600; letter-spacing: 0.02em; font-size: 17px; white-space: nowrap; }
.logo img { width: 32px; height: 32px; margin-left: -3px; }
.nav-links { display: flex; gap: 32px; font-size: 14.5px; white-space: nowrap; }
.nav-links a { opacity: 0.85; }
.nav-links a:hover { opacity: 1; }
.nav-right { display: flex; justify-content: flex-end; align-items: center; gap: 10px; font-size: 14px; }
.nav-right .login { padding: 0 10px; opacity: 0.85; }
/* 로그인한 상태: 이메일 + 지금 플랜(js/landing/account-nav.js) */
.nav-right .login.account { display: inline-flex; align-items: center; gap: 8px; opacity: 1; }
.account-email { max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-soft); }
.account-plan { display: inline-flex; align-items: center; justify-content: center; line-height: 1; height: 22px; padding: 0 9px; border-radius: 999px; font-size: 12.5px; background: var(--pill); color: var(--ink); }
.account-plan.is-paid { background: var(--ink); color: var(--bg); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  line-height: 1;
  border-radius: 999px; white-space: nowrap;
  transition: background 0.15s ease;
}
.btn-sm { height: 32px; padding: 2px 14px 0; font-size: 14px; }
.btn-md { height: 38px; padding: 2px 18px 0; font-size: 14.5px; }
.btn-lg { height: 44px; padding: 2px 22px 0; font-size: 16px; }
.btn-dark { background: var(--ink); color: var(--bg); }
.btn-dark:hover { background: color-mix(in srgb, var(--ink), #fff 12%); }
.btn-gray { background: var(--pill); }
.btn-gray:hover { background: color-mix(in srgb, var(--bg), var(--ink) 10%); }
.more { color: var(--accent-text); font-size: 16px; }
.more:hover { text-decoration: underline; text-underline-offset: 4px; }

/* Two-tone text: title in ink, description faded, same size */
.duo { font-size: 22px; font-weight: 400; line-height: 1.4; letter-spacing: -0.015em; }
.duo span { display: block; color: var(--ink-soft); margin-top: 2px; font-size: 0.9em; }

/* ---------- Hero ---------- */
.hero { padding: 112px 0 56px; }
.hero h1 { font-size: 30px; line-height: 1.38; font-weight: 400; letter-spacing: -0.02em; }
.hero-cta { margin-top: 28px; display: flex; gap: 10px; flex-wrap: wrap; }
.hero-note { margin-top: 14px; font-size: 13px; color: var(--ink-faint); }
.hero-note a { text-decoration: underline; text-underline-offset: 3px; }
.hero-note a:hover { color: var(--ink); }
/* 주 버튼 옆 글자 링크(데스크톱 앱 안내) */
.text-link { display: inline-flex; align-items: center; height: 44px; padding: 0 6px; font-size: 15px; color: var(--ink-soft); }
.text-link:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }

/* ---------- Linea Architectural Precision Stage ---------- */
.stage {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  isolation: isolate;
  box-shadow: inset 0 0 0 1px rgba(30, 50, 92, 0.12), 0 18px 44px -22px rgba(15, 23, 42, 0.16);
}
.stage::before {
  content: "";
  position: absolute; inset: 0;
  background-color: #16233d;
  background-image:
    radial-gradient(80% 75% at 18% 12%, rgba(59, 130, 246, 0.28) 0%, transparent 65%),
    radial-gradient(70% 70% at 85% 88%, rgba(99, 102, 241, 0.22) 0%, transparent 65%),
    linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 32px 32px, 32px 32px;
  z-index: -1;
}
.stage.dusk::before {
  background-color: #1c2842;
  background-image:
    radial-gradient(75% 75% at 80% 15%, rgba(96, 165, 250, 0.25) 0%, transparent 62%),
    radial-gradient(65% 65% at 15% 85%, rgba(245, 158, 11, 0.14) 0%, transparent 60%),
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 32px 32px, 32px 32px;
}
.stage.sea::before {
  background-color: #e8edf6;
  background-image:
    radial-gradient(75% 75% at 15% 15%, rgba(37, 99, 235, 0.14) 0%, transparent 62%),
    radial-gradient(70% 70% at 88% 85%, rgba(30, 50, 92, 0.12) 0%, transparent 62%),
    linear-gradient(rgba(30, 50, 92, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(30, 50, 92, 0.055) 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 28px 28px, 28px 28px;
}
.stage.meadow::before {
  background-color: #ecebe4;
  background-image:
    radial-gradient(75% 75% at 22% 16%, rgba(38, 67, 126, 0.12) 0%, transparent 62%),
    radial-gradient(65% 65% at 82% 84%, rgba(16, 185, 129, 0.10) 0%, transparent 62%),
    linear-gradient(rgba(39, 38, 30, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(39, 38, 30, 0.05) 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 28px 28px, 28px 28px;
}
.stage.night::before {
  background-color: #11192c;
  background-image:
    radial-gradient(70% 70% at 25% 18%, rgba(59, 130, 246, 0.26) 0%, transparent 62%),
    radial-gradient(70% 70% at 80% 82%, rgba(129, 140, 248, 0.20) 0%, transparent 62%),
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 32px 32px, 32px 32px;
}
/* 창이 무대보다 넓으면(휴대폰·태블릿·좁은 창) 데모가 보여 줄 곳으로 창을 옆으로 옮긴다(main.js panTo) */
.stage .window, .stage .page { transition: translate 0.6s cubic-bezier(0.3, 0, 0.2, 1); }
.hero-stage { height: clamp(550px, 55vw, 680px); }
.hero-stage .window { left: max(16px, 7.5%); right: auto; width: 1088px; }
/* the hero window bleeds 24px past the stage, so lift the chat input above the cut */
.hero-stage .chat { padding-bottom: 38px; }

/* ---------- App window (kept deliberately minimal) ---------- */
.window {
  position: absolute;
  left: 7.5%; right: 7.5%; top: 56px; bottom: -24px;
  background: var(--surface);
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.6);
  box-shadow: 0 24px 60px rgba(30, 28, 18, 0.22), 0 0 0 0.5px rgba(30,28,18,0.2);
  display: flex; flex-direction: column;
  overflow: hidden;
}
/* 예시 창은 웹에서 쓰는 모습이라 브라우저 창 모양 */
.browserbar {
  height: 36px; flex: none;
  display: grid; grid-template-columns: 80px 1fr 80px; align-items: center;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg), var(--ink) 4%);
}
.browserbar .dots { display: flex; gap: 7px; padding-left: 14px; }
.browserbar .dots i { width: 11px; height: 11px; border-radius: 50%; background: color-mix(in srgb, var(--ink) 16%, transparent); }
.browserbar .url {
  justify-self: center; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 24px; padding: 0 14px; min-width: min(360px, 100%);
  border-radius: 999px; background: var(--surface); font-size: 12px; color: var(--ink-soft);
}
.browserbar .url svg { width: 11px; height: 11px; }

.app-body { flex: 1; display: grid; grid-template-columns: 1fr 320px; grid-template-rows: minmax(0, 1fr); min-height: 0; }
.app-body.solo { grid-template-columns: 1fr; }
.viewer { display: flex; flex-direction: column; min-width: 0; background: color-mix(in srgb, var(--bg), var(--ink) 3.5%); }
.viewer-bar {
  height: 40px; flex: none;
  display: flex; align-items: center; gap: 12px;
  padding: 0 14px; border-bottom: 1px solid var(--line); background: var(--surface);
  font-size: 12.5px; color: var(--ink-soft);
}
.viewer-bar .file { color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.viewer-bar .spacer { flex: 1; }
.seg { display: inline-flex; padding: 2px; border-radius: 999px; background: var(--pill); flex: none; }
.seg button { height: 24px; padding: 0 12px; border-radius: 999px; font-size: 12.5px; color: var(--ink-soft); }
.seg button.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,0.08); }

.page-wrap { flex: 1; overflow: hidden; display: flex; justify-content: center; padding: 20px 20px 0; }
.page { position: relative; width: min(100%, 620px); background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,0.08), 0 0 0 1px rgba(0,0,0,0.04); align-self: flex-start; }
.page img { width: 100%; transition: opacity 0.25s ease; }
.page img.alt { position: absolute; inset: 0; background: #fff; opacity: 0; }
.page.show-src img.alt { opacity: 1; }
.page.show-src img.main { opacity: 0; }

/* zoomed view onto part of a page: translate % is relative to the page itself */
.zoom { position: relative; flex: 1; overflow: hidden; background: #fff; }
.zoom-page { position: absolute; left: 0; top: 0; width: var(--zw, 100%); transform: translate(var(--zx, 0), var(--zy, 0)); }
.zoom-page img { width: 100%; }

.chat { border-left: 1px solid var(--line); background: var(--surface); display: flex; flex-direction: column; gap: 12px; padding: 14px; font-size: 13px; overflow: hidden; }
.chat-head { display: flex; justify-content: space-between; align-items: center; font-size: 12.5px; color: var(--ink-soft); }
.linked { color: var(--ok); }
.chat-head .quota b { font-weight: 600; color: var(--ink); }
.linked::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--ok); margin-right: 6px; vertical-align: 1px; }
.quote { background: var(--accent-tint); border-radius: 8px; padding: 10px 12px; color: var(--accent-ink); font-size: 12.5px; line-height: 1.6; }
.quote small { display: block; font-size: 11.5px; opacity: 0.8; margin-bottom: 2px; }
.bubble { align-self: flex-end; max-width: 88%; background: var(--accent); color: #fff; border-radius: 14px 14px 4px 14px; padding: 8px 12px; line-height: 1.5; }
.answer { line-height: 1.75; }
.answer p + p { margin-top: 8px; }
.src { display: inline-block; font-size: 11px; padding: 0 6px; border-radius: 4px; background: var(--accent-tint); color: var(--accent-ink); white-space: nowrap; }
.chat-input { margin-top: auto; border: 1px solid var(--line-strong); border-radius: 10px; padding: 10px 12px; color: var(--ink-faint); }
.bubble, .quote { transition: opacity 0.25s ease, transform 0.25s ease; }

/* Chat demos (js/landing/main.js): typed question, thinking dots, streamed answer */
.bubble.is-hidden, .quote.is-hidden { opacity: 0; transform: translateY(6px); }
/* Hero sentence selection: cursor drag, selection, "ask about this" popup */
.sel-layer { position: absolute; inset: 0; pointer-events: none; transition: opacity 0.12s ease; }
.sel-layer.fading { opacity: 0; }
.mark.select.dragging { width: calc(var(--w) * var(--p, 1) * 1%); height: calc(var(--h, 1.8) * var(--p, 1) * 1%); will-change: transform; }
.mark.select.is-empty { opacity: 0; }
.mark.sel { background: rgba(38, 67, 126, 0.24); mix-blend-mode: multiply; transform-origin: left center; transform: scaleX(var(--p, 0)); will-change: transform; }
.sel-pop { position: absolute; padding: 6px; border-radius: 12px; background: var(--surface); box-shadow: 0 8px 24px rgba(30, 28, 18, 0.18), 0 0 0 1px var(--line); translate: -100% -100%; opacity: 0; transform: translateY(4px) scale(0.98); transform-origin: bottom right; transition: opacity 0.18s ease, transform 0.18s ease; }
.sel-pop.show { opacity: 1; transform: none; }
.sel-ask { display: flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 8px; background: var(--accent); color: #fff; font-size: 12.5px; white-space: nowrap; transition: transform 0.1s ease, filter 0.1s ease; }
.sel-ask svg { width: 14px; height: 14px; }
.sel-ask.pressed { transform: scale(0.96); filter: brightness(0.9); }
.demo-cursor { position: absolute; left: 0; top: 0; z-index: 2; opacity: 0; transition: opacity 0.2s ease; will-change: transform; }
.demo-cursor.show { opacity: 1; }
.demo-cursor svg { display: block; }
.demo-cursor .ibeam, .demo-cursor.is-ibeam .arrow { display: none; }
.demo-cursor.is-ibeam .ibeam { display: block; }
.chat-input.typing { color: var(--ink); }
.chat-input.typing::after { content: ""; display: inline-block; width: 1.5px; height: 1.15em; margin-left: 1px; vertical-align: -0.2em; background: var(--ink); animation: caret 1s steps(1) infinite; }
.thinking { display: inline-flex; gap: 4px; padding: 6px 0; }
.thinking i { width: 5px; height: 5px; border-radius: 50%; background: var(--ink-faint); animation: thinking 1s ease-in-out infinite; }
.thinking i:nth-child(2) { animation-delay: 0.15s; }
.thinking i:nth-child(3) { animation-delay: 0.3s; }
.src.pop { animation: src-pop 0.3s ease; }
.summary dl > .sum-pending { display: none; }
.summary dl > .sum-in { animation: sum-in 0.25s ease; }
@keyframes caret { 50% { opacity: 0; } }
@keyframes thinking { 0%, 80%, 100% { opacity: 0.3; transform: none; } 40% { opacity: 1; transform: translateY(-2px); } }
@keyframes sum-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
@keyframes src-pop { from { opacity: 0; transform: scale(0.8); } to { opacity: 1; transform: none; } }

/* selection box and highlights placed in page percentages */
.mark { position: absolute; left: calc(var(--x) * 1%); top: calc(var(--y) * 1%); width: calc(var(--w) * 1%); height: calc(var(--h, 1.8) * 1%); border-radius: 2px; }
.mark.select { border: 1.5px solid var(--accent); background: color-mix(in srgb, var(--accent) 8%, transparent); border-radius: 4px; }
/* 3 memos take turns over a 12s loop; the matching color is emphasized meanwhile */
.mark.hl { mix-blend-mode: multiply; opacity: 0.35; animation: hl-focus 12s ease infinite; }
.hl.y { background: rgba(250, 214, 92, 0.6); }
.hl.b { background: rgba(120, 178, 240, 0.45); animation-delay: 4s; }
.hl.p { background: rgba(240, 140, 180, 0.45); animation-delay: 8s; }
.hl-note {
  position: absolute; left: var(--nx); top: var(--ny); width: 30%;
  background: var(--surface); border-radius: 8px; padding: 10px 12px;
  box-shadow: 0 8px 24px rgba(30,28,18,0.18), 0 0 0 1px var(--line);
  font-size: 12.5px; line-height: 1.6;
  opacity: 0; animation: note-turn 12s ease infinite;
}
.hl-note.b { animation-delay: 4s; }
.hl-note.above { translate: 0 calc(-100% - 6px); }
.hl-note.p { animation-delay: 8s; }
.hl-note small { display: flex; align-items: center; gap: 6px; color: var(--ink-faint); font-size: 11.5px; margin-bottom: 2px; }
.hl-note small::before { content: ""; width: 8px; height: 8px; border-radius: 2px; }
.hl-note.y small::before { background: rgb(250, 214, 92); }
.hl-note.b small::before { background: rgb(120, 178, 240); }
.hl-note.p small::before { background: rgb(240, 140, 180); }
/* Script-driven version (js/landing/main.js): each colour is painted like a marker, then its memo streams */
.hl-demo .mark.hl { animation: none; opacity: 0.35; transform-origin: left center; will-change: transform; transition: transform 0.4s ease-out, opacity 0.3s ease; }
.hl-demo .mark.hl.unpainted { transform: scaleX(0); }
.hl-demo .mark.hl.focus { opacity: 1; }
.hl-demo .hl-note { animation: none; opacity: 0; transform: translateY(8px); transition: opacity 0.25s ease, transform 0.25s ease; }
.hl-demo .hl-note.show { opacity: 1; transform: none; }
@keyframes hl-focus { 0% { opacity: 0.35; } 3% { opacity: 1; } 30% { opacity: 1; } 33.3%, 100% { opacity: 0.35; } }
@keyframes note-turn {
  0% { opacity: 0; transform: translateY(8px); }
  3% { opacity: 1; transform: none; }
  30% { opacity: 1; transform: none; }
  33.3%, 100% { opacity: 0; transform: translateY(-6px); }
}
@media (prefers-reduced-motion: reduce) {
  .mark.hl { animation: none; opacity: 1; }
  .hl-note { animation: none; }
  .hl-note.y { opacity: 1; }
}

.summary { padding: 18px 20px; font-size: 13px; line-height: 1.65; overflow: hidden; background: var(--surface); border-right: 1px solid var(--line); }
.app-body.summary-app { grid-template-columns: min(310px, calc(100vw - 100px)) 1fr; }
.summary h4 { display: flex; align-items: baseline; gap: 8px; font-size: 15px; font-weight: 500; color: var(--ink); letter-spacing: -0.01em; padding-bottom: 10px; margin-bottom: 12px; border-bottom: 1px solid var(--line); }
.summary h4 .sum-label { flex: none; color: var(--accent-text); }
.summary dl { display: grid; gap: 11px; }
.summary dt { font-size: 12px; color: var(--ink-soft); }
.summary dt b { font-weight: 500; color: var(--ink); }
.summary dd { margin-top: 2px; }

/* ---------- Feature cards ---------- */
.features { padding-top: 120px; display: grid; gap: 24px; }
.feature {
  background: var(--card);
  border-radius: 4px;
  padding: 18px;
  display: grid;
  grid-template-columns: minmax(300px, 1fr) 2.3fr;
  gap: 18px;
  min-height: 700px;
}
.feature.rev { grid-template-columns: 2.3fr minmax(300px, 1fr); }
.feature.rev .f-text { order: 2; }
.f-text { padding: 24px 22px; align-self: center; }
.f-eyebrow { font-size: 13.5px; color: var(--ink-faint); margin-bottom: 16px; }
.f-eyebrow .plan-tag { color: var(--accent-text); }
.f-visual { position: relative; border-radius: 4px; overflow: hidden; min-height: 600px; }
.f-visual.solid { background: var(--solid); display: flex; align-items: center; justify-content: flex-start; padding: clamp(16px, 3.75vw, 48px); }
.f-visual.solid .window, .f-window { position: relative; left: auto; right: auto; top: auto; bottom: auto; flex: none; width: 757px; height: 520px; }
.f-visual.stage .f-window { position: absolute; left: max(16px, 7%); right: auto; top: 50%; width: 734px; transform: translateY(-50%); }

/* compare slider */
.compare {
  --pos: 50%;
  position: absolute; left: 50%; top: 56px; bottom: 0;
  transform: translateX(-50%);
  width: min(88%, 600px);
  background: #fff;
  box-shadow: 0 24px 60px rgba(30, 28, 18, 0.22), 0 0 0 0.5px rgba(30,28,18,0.2);
  border-radius: 6px 6px 0 0;
  overflow: hidden;
  user-select: none;
}
.compare .c-frame { position: relative; }
.compare img { width: 100%; pointer-events: none; }
.compare .c-top { position: absolute; inset: 0; background: #fff; clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.compare .c-handle {
  position: absolute; top: 0; bottom: 0; left: var(--pos);
  width: 1.5px; margin-left: -0.75px; background: var(--accent);
  pointer-events: none;
}
.compare .c-handle::after {
  content: "";
  position: absolute; top: 46%; left: 50%; transform: translate(-50%, -50%);
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%2327261e' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M7.5 6 3.5 10l4 4M12.5 6l4 4-4 4'/%3E%3C/svg%3E") center / 18px 18px no-repeat;
  box-shadow: 0 2px 10px rgba(0,0,0,0.15), 0 0 0 1px var(--line-strong);
}
.compare { touch-action: pan-y; cursor: ew-resize; }
.compare input[type="range"] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; margin: 0; pointer-events: none; }
.c-chip {
  position: absolute; top: 18px; z-index: 2;
  font-size: 12px; padding: 4px 10px; border-radius: 999px;
  background: color-mix(in srgb, var(--surface) 92%, transparent); color: var(--ink-soft);
  box-shadow: 0 0 0 1px var(--line);
}
.c-chip.l { left: calc(50% - min(44%, 300px)); }
.c-chip.r { right: calc(50% - min(44%, 300px)); }

/* ---------- Side translation showcase ---------- */
/* 실제 뷰어의 번역 패널(side-panel.css)과 같은 모양을 작게 옮겼다. 원문 쪽 상자(.sd-box)와 번역 문장(.sd-sent)은 data-s로 짝을 짓는다. */
.side-show { padding-top: 120px; }
.side-show-head { max-width: 680px; padding: 0 22px 36px; }
.side-stage { height: clamp(560px, 56vw, 700px); }
.side-stage .window { left: max(16px, 7.5%); right: max(16px, 7.5%); max-width: 1088px; margin: 0 auto; }
.side-app { grid-template-columns: 1fr min(400px, 42%); }
.sd-mode { flex: none; display: inline-flex; align-items: center; height: 24px; padding: 0 10px; border-radius: 999px; background: var(--accent-tint); color: var(--accent-ink); font-size: 12px; }
.sd-page { translate: 0 -8%; }
.sd-page img { height: auto; }
.sd-box { position: absolute; left: calc(var(--x) * 1%); top: calc(var(--y) * 1%); width: calc(var(--w) * 1%); height: calc(var(--h) * 1%); border-radius: 2px; mix-blend-mode: multiply; transition: background-color 0.25s ease; }
/* 번역 중인 문장(live)도 마우스로 짝을 맞출 때(on)와 같은 색으로 칠한다 */
.sd-box.live, .sd-box.on { background: rgba(38, 67, 126, 0.26); }
.sd-panel { display: flex; flex-direction: column; min-width: 0; min-height: 0; border-left: 1px solid var(--line); background: #fbfbf8; }
.sd-head { flex: none; display: flex; align-items: center; gap: 10px; height: 42px; padding: 0 16px 0 18px; border-bottom: 1px solid var(--line); font-size: 13px; white-space: nowrap; }
.sd-head b { font-weight: 600; }
.sd-follow { margin: 0 auto; display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--ink-faint); }
.sd-follow i { font-style: normal; opacity: 0.45; }
.sd-follow i.on { color: var(--accent); opacity: 1; }
.sd-x { color: var(--ink-faint); font-size: 16px; line-height: 1; }
.sd-body { flex: 1; min-height: 0; overflow: hidden; padding: 0 20px; }
.sd-pg { padding: 14px 0 220px; }
.sd-pg-head { margin-bottom: 10px; font-size: 11.5px; letter-spacing: 0.04em; color: var(--ink-faint); }
.sd-pg-head b { color: var(--ink-soft); font-weight: 600; }
.sd-pg-body { font-size: 14.5px; line-height: 1.8; color: var(--ink); word-break: keep-all; overflow-wrap: anywhere; }
.sd-block { margin: 0 0 12px; }
.sd-block.heading { margin-top: 4px; font-size: 15.5px; font-weight: 700; line-height: 1.6; }
.sd-block.caption { font-size: 13px; color: var(--ink-soft); }
.sd-sent { border-radius: 3px; transition: background-color 0.25s ease; }
.sd-sent.on { background: rgba(38, 67, 126, 0.16); }
/* 받는 중인 문장 끝의 깜박이는 주황 커서 */
.sd-tail::after { content: ""; display: inline-block; width: 6px; height: 1em; margin-left: 3px; vertical-align: -0.15em; border-radius: 2px; background: var(--accent); animation: caret 1s steps(1) infinite; }
.sd-state { display: grid; gap: 10px; padding: 12px 14px; border-radius: 10px; background: var(--card); }
.sd-status { display: flex; align-items: center; gap: 9px; font-size: 13px; font-weight: 500; }
.sd-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); animation: sd-pulse 1.6s ease-out infinite; }
.sd-lines { display: grid; gap: 9px; }
.sd-shimmer { display: block; height: 9px; border-radius: 5px; background: linear-gradient(90deg, var(--card) 0%, color-mix(in srgb, var(--accent) 14%, var(--card)) 50%, var(--card) 100%); background-size: 220% 100%; animation: sd-shimmer 1.8s ease-in-out infinite; }
.sd-shimmer:nth-child(2) { animation-delay: 0.12s; }
.sd-shimmer:nth-child(3) { animation-delay: 0.24s; }
.sd-shimmer:nth-child(4) { animation-delay: 0.36s; }
.sd-shimmer:nth-child(5) { animation-delay: 0.48s; }
@keyframes sd-pulse { from { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 28%, transparent); } to { box-shadow: 0 0 0 9px transparent; } }
@keyframes sd-shimmer { from { background-position: 110% 0; } to { background-position: -110% 0; } }

/* ---------- Desktop app band ---------- */
.band-wrap { padding-top: 24px; }
/* '데스크톱 앱' 메뉴로 오면 띠가 상단 바 아래 화면 한가운데 오도록 (띠 약 104px + 위 여백 24px 기준) */
#app { scroll-margin-top: calc(50vh - 44px); }
.band {
  background: var(--card); border-radius: 4px; padding: 30px 36px;
  display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap;
}
.band p { font-size: 19px; line-height: 1.5; color: var(--ink-soft); letter-spacing: -0.01em; }
.band p b { font-weight: 400; color: var(--ink); }
.app-band-text { flex: 1; min-width: 260px; display: flex; align-items: center; gap: 18px; }
.app-icon { width: 56px; height: 56px; flex: none; filter: drop-shadow(0 2px 6px rgba(39, 38, 30, 0.12)); }
.app-band-actions { display: flex; align-items: center; gap: 12px; }
.app-band-actions small { font-size: 12.5px; color: var(--ink-faint); }

/* ---------- Section heads ---------- */
.section { padding-top: 140px; }
.section-head { margin-bottom: 36px; display: flex; justify-content: space-between; align-items: end; gap: 24px; flex-wrap: wrap; }

/* ---------- Pricing ---------- */
/* 월간/연간 토글: 연간 가격이 있을 때만 보인다(hidden). 연간 쪽에 '2개월 무료' 표시 */
.billing-toggle { display: inline-flex; gap: 2px; padding: 3px; border-radius: 999px; background: var(--pill); }
#pricing .section-head { position: relative; align-items: flex-end; }
#pricing .billing-toggle { flex: none; margin-left: auto; }
.billing-toggle[hidden], .yearly-change-note[hidden], .plan-yearly-note[hidden] { display: none; }
.billing-toggle button {
  height: 36px; padding: 0 16px; border-radius: 999px; font-size: 14px; color: var(--ink-soft);
  display: inline-flex; align-items: center; gap: 8px; white-space: nowrap;
}
.billing-toggle button:hover { color: var(--ink); }
.billing-toggle button.is-active { background: var(--ink); color: var(--bg); }
.billing-toggle button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.billing-free { display: inline-flex; align-items: center; justify-content: center; line-height: 1; height: 20px; font-size: 11.5px; padding: 0 7px; border-radius: 999px; background: var(--accent-tint); color: var(--accent-ink); }
.billing-toggle button.is-active .billing-free { background: var(--accent); color: #fff; }
.yearly-change-note { margin-bottom: 12px; padding: 12px 16px; border-radius: 4px; background: var(--card); font-size: 14px; color: var(--ink-soft); }
.plans { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.plan { background: var(--card); border-radius: 8px; padding: 26px 22px 22px; display: flex; flex-direction: column; }
.plan.featured { box-shadow: inset 0 0 0 1.5px var(--accent); background: color-mix(in srgb, var(--accent-tint) 38%, var(--card)); }
.plan.featured .tag { background: var(--accent); color: #fff; font-weight: 600; }
.plan-name { display: flex; align-items: center; gap: 8px; }
.plan-name h3 { font-size: 15px; font-weight: 400; }
.tag { display: inline-flex; align-items: center; justify-content: center; line-height: 1; height: 20px; font-size: 11.5px; padding: 0 8px; border-radius: 999px; background: var(--bg); color: var(--ink-soft); }
.plan-price { margin-top: 18px; font-size: 26px; letter-spacing: -0.02em; }
.plan-price span { margin-left: 3px; font-size: 14px; color: var(--ink-faint); }
.plan ul { margin: 20px 0 24px; list-style: none; font-size: 14px; color: var(--ink-soft); flex: 1; }
.plan li { padding: 6px 0; display: flex; align-items: baseline; gap: 8px; }
.plan li::before {
  content: ""; flex: none; width: 13px; height: 13px; align-self: center; background: var(--ink);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 8.5 6.5 12 13 4.5'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 8.5 6.5 12 13 4.5'/%3E%3C/svg%3E") center / contain no-repeat;
}
.feature-highlight-link { color: var(--accent-text); }
.feature-highlight-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.feature-highlight-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 2px; }
.feature-link-icon { margin-right: 4px; }
.plan .btn { width: 100%; }
.plan .btn-gray { background: var(--bg); }
.plan .btn-gray:hover { background: color-mix(in srgb, var(--bg), var(--ink) 4%); }
/* 구독자 버튼 상태: 이용 중(초록 톤), 변경 예정(흐린 글자). 둘 다 누를 수 없다. */
.plan .btn:disabled { cursor: default; }
.plan .btn.is-current,
.plan .btn.is-current:hover {
  background: color-mix(in srgb, var(--ok) 13%, var(--bg));
  color: var(--ok);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ok) 28%, transparent);
}
.plan .btn.is-current::before { content: "✓"; font-size: 13px; }
.plan .btn.is-scheduled,
.plan .btn.is-scheduled:hover { background: var(--bg); color: var(--ink-faint); }
/* 카드에는 차이만: 누구에게 맞는지 한 줄, '앞 플랜의 모든 기능 +', 그 플랜에서 늘어나는 것 */
.plan-yearly-note { margin-top: 4px; font-size: 13px; color: var(--ink-soft); }
.plan-current-note { margin-top: 8px; font-size: 13px; line-height: 1.5; color: var(--ok); }
.plan-current-note b { font-weight: 500; }
.plan-who { margin-top: 4px; font-size: 13px; color: var(--ink-faint); }
.plan-base { margin-top: 18px; min-height: 18px; font-size: 13px; color: var(--ink-faint); }
.plan .plan-base + ul { margin-top: 6px; }

/* 플랜별 기능 비교표: 카드 아래에서 줄마다 비교. 좁은 화면은 표만 옆으로 밀리고 첫 열은 붙어 있다 */
.plan-compare { margin-top: 64px; }
.plan-compare h3 { font-size: 17px; font-weight: 400; margin-bottom: 12px; }
.compare-scroll { overflow-x: auto; }
.compare-table { width: 100%; min-width: 760px; border-collapse: collapse; table-layout: fixed; font-size: 14px; }
.compare-table th, .compare-table td { padding: 13px 12px; text-align: left; font-weight: 400; vertical-align: middle; border-top: 1px solid var(--line); }
.compare-table thead th, .compare-table thead td { border-top: 0; padding-bottom: 10px; }
.compare-table thead td:first-child { width: 26%; }
.compare-table tbody th[scope="row"] { color: var(--ink-soft); }
.compare-table .group th { border-top: 0; padding: 28px 12px 8px; font-size: 13px; }
.compare-table thead td:first-child, .compare-table tbody th { position: sticky; left: 0; background: var(--bg); }
.compare-table .featured { background: color-mix(in srgb, var(--accent-tint) 60%, var(--bg)); }
.compare-table thead .featured { border-radius: 4px 4px 0 0; }
.compare-table .ck {
  display: inline-block; width: 14px; height: 14px; vertical-align: middle; background: var(--ink);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 8.5 6.5 12 13 4.5'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 8.5 6.5 12 13 4.5'/%3E%3C/svg%3E") center / contain no-repeat;
}
.compare-table .no { color: var(--ink-faint); }
.compare-table .meter { display: inline-flex; gap: 3px; margin-right: 8px; vertical-align: middle; }
.compare-table .meter i { width: 10px; height: 6px; border-radius: 2px; background: var(--line-strong); }
.compare-table .meter i.on { background: var(--ink); }
.compare-note { margin-top: 16px; font-size: 13px; color: var(--ink-faint); }
/* 비교표 줄 이름 옆 i: 마우스를 올리거나 키보드로 고르면 설명 말풍선을 띄운다 */
.compare-table tbody th:hover, .compare-table tbody th:focus-within { z-index: 2; }
.info { position: relative; display: inline-flex; vertical-align: middle; margin-left: 6px; }
.info-btn { display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; color: var(--ink-faint); }
.info-btn svg { width: 15px; height: 15px; }
.info-btn:hover, .info-btn:focus-visible { color: var(--ink); }
.info-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.info-tip {
  position: absolute; left: 50%; bottom: calc(100% + 8px); z-index: 3; width: max-content; max-width: 240px;
  padding: 8px 11px; border-radius: 8px; background: var(--ink); color: var(--bg);
  font-size: 12.5px; line-height: 1.5; white-space: normal; word-break: keep-all;
  opacity: 0; visibility: hidden; transform: translate(-50%, 3px); pointer-events: none;
  transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s;
}
.info:hover .info-tip, .info-btn:focus + .info-tip { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
/* 줄 이름 칸(맨 왼쪽 열)은 말풍선을 칸 왼쪽 끝에 맞춰 표 왼쪽 밖으로 잘리지 않게(줄 이름이 짧으면 가운데 맞춤이 넘친다) */
.compare-table tbody th .info { position: static; }
.compare-table tbody th .info-tip { left: 12px; transform: translate(0, 3px); }
.compare-table tbody th .info:hover .info-tip, .compare-table tbody th .info-btn:focus + .info-tip { transform: translate(0, 0); }
/* 오른쪽 끝 열은 말풍선을 아이콘 오른쪽 끝에 맞춰 표 밖으로 넘치지 않게 */
.info-end .info-tip { left: auto; right: -4px; transform: translate(0, 3px); }
.info-end:hover .info-tip, .info-end .info-btn:focus + .info-tip { transform: translate(0, 0); }
.info-tip-title { display: block; margin-bottom: 4px; color: color-mix(in srgb, var(--bg) 70%, transparent); }
.info-tip-item { display: block; }
.info-tip-item::before { content: "· "; }

/* ---------- Closing ---------- */
.closing { padding: 200px 0 180px; text-align: center; }
.closing h2 { font-size: clamp(34px, 5vw, 64px); font-weight: 400; line-height: 1.15; letter-spacing: -0.035em; }
.closing .hero-cta { justify-content: center; margin-top: 36px; }

footer { border-top: 1px solid var(--line); padding: 56px 0 40px; font-size: 14px; }
.foot { display: grid; grid-template-columns: 2fr repeat(3, 1fr); gap: 32px; }
.foot p { margin-top: 12px; color: var(--ink-faint); line-height: 1.7; font-size: 13.5px; }
.foot h4 { font-size: 13px; font-weight: 400; color: var(--ink-faint); margin-bottom: 14px; }
.foot ul { list-style: none; }
.foot li { padding: 5px 0; }
.foot li a { color: var(--ink-soft); }
.foot li a:hover { color: var(--ink); }
.copy { margin-top: 48px; font-size: 12.5px; color: var(--ink-faint); }
/* 사업자 정보: 상호·사업자등록번호, 주소, 연락처 */
.biz { margin-top: 48px; font-style: normal; font-size: 12.5px; line-height: 1.8; color: var(--ink-faint); }
.biz a:hover { color: var(--ink); }
.biz + .copy { margin-top: 12px; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .plans { grid-template-columns: repeat(2, 1fr); }
  .nav-links { gap: 20px; font-size: 14px; }
}
@media (max-width: 960px) {
  .feature, .feature.rev { grid-template-columns: 1fr; min-height: 0; }
  .feature.rev .f-text { order: 0; }
  .f-text { padding: 18px 12px 8px; }
  .plans { grid-template-columns: repeat(2, 1fr); }
  #pricing .section-head { flex-direction: column; align-items: stretch; }
  #pricing .billing-toggle { position: static; transform: none; align-self: center; }
  .foot { grid-template-columns: 1fr 1fr; }
  .foot > div:first-child { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  .nav-links { display: none; }
  .nav { grid-template-columns: 1fr auto; }
}
@media (max-width: 600px) {
  .nav-wrap { background: var(--bg); backdrop-filter: none; }
  .hero-stage { height: 560px; }
  .app-body { grid-template-columns: 1fr min(320px, calc(100vw - 88px)); }
  .hero { padding: 64px 0 40px; }
  .hero h1 { font-size: 24px; }
  .hero h1 br { display: none; }
  .nav-right .login { display: none; }
  .viewer-bar .hide-sm { display: none; }
  .page-wrap { padding: 12px 12px 0; }
  .features { padding-top: 80px; }
  .duo { font-size: 19px; }
  .compare { top: 48px; width: calc(100% - 32px); }
  .c-chip.l { left: 16px; }
  .c-chip.r { right: 16px; }
  .side-show { padding-top: 96px; }
  .side-stage { height: 600px; }
  /* 휴대폰은 히어로처럼 넓은 창을 옆으로 옮겨 가며 보여 준다 */
  .side-stage .window { left: 16px; right: auto; width: 1088px; max-width: none; margin: 0; }
  .sd-pg-body { font-size: 13.5px; }
  .band { padding: 24px 20px; }
  .app-band-text { align-items: flex-start; }
  .app-band-actions { flex-wrap: wrap; }
  .browserbar { grid-template-columns: 40px 1fr 12px; }
  .browserbar .dots i:nth-child(n+2) { display: none; }
  .browserbar .url { min-width: 0; width: 100%; }
  .band p { font-size: 17px; }
  .section { padding-top: 96px; }
  .plans { grid-template-columns: 1fr; }
  .compare-table { min-width: 640px; font-size: 13px; }
  .closing { padding: 128px 0 112px; }
}

/* ---------- Contact modal ---------- */
.modal { position: fixed; inset: 0; z-index: 30; display: none; align-items: center; justify-content: center; padding: 16px; background: color-mix(in srgb, var(--ink) 35%, transparent); }
.modal.show { display: flex; }
.modal-content { position: relative; width: min(100%, 380px); padding: 28px 24px 24px; border-radius: 10px; background: var(--surface); box-shadow: 0 24px 60px rgba(30, 28, 18, 0.25); }
.modal-content h3 { font-size: 18px; font-weight: 500; }
.modal-content p { margin-top: 8px; font-size: 14px; line-height: 1.6; color: var(--ink-soft); }
.email-box { margin-top: 16px; padding: 12px 14px; border-radius: 8px; background: var(--card); font-size: 15px; }
.close-button { position: absolute; top: 10px; right: 12px; width: 32px; height: 32px; font-size: 22px; line-height: 1; color: var(--ink-soft); }
