/* 코델퍼(Codelper) — "엔지니어링 노트" 테마(2026-11-10)
   종이 + 점 모눈, 잉크 글자, 형광펜(--hi) 강조, 편집기는 늘 터미널처럼 어둡게. 노선도 커리큘럼. */
:root {
  --paper: #f3f0e8;
  --paper-2: #e9e4d8;
  --sheet: #fbf9f4;
  --ink: #1a1813;
  --ink-2: #57513f;
  --rule: #d5cdb9;
  --dot: rgba(26, 24, 19, 0.09);
  --hi: #e4ff3d;
  --hi-ink: #1a1813;
  --signal: #f0441c;
  --link: #1d46d1;
  --pass: #138a3f;
  --fail: #d0341a;
  --warn: #c98a00;
  --term: #15160f;
  --term-2: #1f2117;
  --term-line: #2e3125;
  --term-fg: #e8e5d8;
  --term-dim: #8d8a78;
  --l1: #1d46d1;
  --l2: #f0441c;
  --l3: #138a3f;
  --l4: #8a3ffc;
  --l5: #b86e00;
  --l6: #0f7d8c;
  --l7: #c2255c;
  --shadow: 4px 4px 0 var(--ink);
  --sans: "IBM Plex Sans KR", "IBM Plex Sans JP", "IBM Plex Sans", "Apple SD Gothic Neo", "Hiragino Sans", "PingFang SC", "Noto Sans SC", system-ui, sans-serif;
  --mono: "IBM Plex Mono", "D2Coding", ui-monospace, SFMono-Regular, Menlo, monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #12130e;
    --paper-2: #1b1c16;
    --sheet: #181914;
    --ink: #ece8da;
    --ink-2: #a9a38e;
    --rule: #34352b;
    --dot: rgba(236, 232, 218, 0.07);
    --hi: #d7f53a;
    --hi-ink: #12130e;
    --signal: #ff6a3d;
    --link: #8fb0ff;
    --pass: #46d17e;
    --fail: #ff6b55;
    --warn: #f0b429;
    --term: #0b0c08;
    --term-2: #14150f;
    --term-line: #26281f;
    --l1: #6f95ff;
    --l2: #ff6a3d;
    --l3: #46d17e;
    --l4: #b28bff;
    --l5: #f2b84b;
    --l6: #4fd0de;
    --l7: #ff7aa8;
    --shadow: 4px 4px 0 #000;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #12130e;
  --paper-2: #1b1c16;
  --sheet: #181914;
  --ink: #ece8da;
  --ink-2: #a9a38e;
  --rule: #34352b;
  --dot: rgba(236, 232, 218, 0.07);
  --hi: #d7f53a;
  --hi-ink: #12130e;
  --signal: #ff6a3d;
  --link: #8fb0ff;
  --pass: #46d17e;
  --fail: #ff6b55;
  --warn: #f0b429;
  --term: #0b0c08;
  --term-2: #14150f;
  --term-line: #26281f;
  --l1: #6f95ff;
  --l2: #ff6a3d;
  --l3: #46d17e;
  --l4: #b28bff;
  --l5: #f2b84b;
  --l6: #4fd0de;
  --l7: #ff7aa8;
  --shadow: 4px 4px 0 #000;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; color: var(--ink); background-color: var(--paper); }
body {
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.7;
  overflow-x: hidden;
  background-image: radial-gradient(var(--dot) 1px, transparent 1.2px);
  background-size: 22px 22px;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--link); text-underline-offset: 3px; }
h1 { font-size: clamp(26px, 3.4vw, 38px); line-height: 1.2; letter-spacing: -0.02em; margin: 6px 0 12px; }
h2 { font-size: 22px; letter-spacing: -0.01em; margin: 0 0 6px; }
h3 { font-size: 17px; margin: 0; }
pre, code, kbd, textarea { font-family: var(--mono); font-size: 13px; }
:not(pre) > code { background: var(--paper-2); border: 1px solid var(--rule); border-radius: 3px; padding: 0 5px; font-size: 0.88em; }
pre { margin: 0; overflow-x: auto; }
.dim { color: var(--ink-2); }
.lead { color: var(--ink-2); margin: 0 0 18px; max-width: 70ch; }
.grow { flex: 1; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.scroll { overflow-x: auto; max-width: 100%; }
table { border-collapse: collapse; font-size: 13px; background: var(--sheet); }
th, td { border: 1px solid var(--rule); padding: 5px 9px; text-align: left; vertical-align: top; }
thead th { background: var(--paper-2); font-family: var(--mono); font-weight: 500; }
:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }

/* 형광펜 제목 */
.hl { display: inline; background: linear-gradient(transparent 58%, var(--hi) 58%, var(--hi) 92%, transparent 92%); padding: 0 2px; color: var(--ink); }

/* ---------- 머리 ---------- */
.top {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 6px 22px; flex-wrap: wrap;
  padding: 10px clamp(16px, 4vw, 40px);
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1.5px solid var(--ink);
}
.brand { display: inline-flex; align-items: center; gap: 6px; color: var(--ink); text-decoration: none; font-family: var(--mono); font-weight: 600; font-size: 18px; letter-spacing: -0.02em; }
.brand-mark { background: var(--ink); color: var(--hi); border-radius: 4px; padding: 0 5px; font-size: 14px; line-height: 22px; }
.caret { width: 9px; height: 18px; background: var(--signal); animation: blink 1.1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .caret { animation: none; } }
.main-nav { display: flex; gap: 4px 16px; flex-wrap: wrap; }
.main-nav a { color: var(--ink); text-decoration: none; font-size: 14px; font-weight: 500; padding: 2px 0; border-bottom: 2px solid transparent; }
.main-nav a:hover { border-bottom-color: var(--ink); }
.nav-n { font-family: var(--mono); font-size: 11px; color: var(--ink-2); margin-right: 5px; }
.site-lang, .lang-select { font: 500 13px var(--sans); padding: 5px 26px 5px 10px; border-radius: 999px; border: 1.5px solid var(--ink); background: var(--sheet) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23888'/%3E%3C/svg%3E") no-repeat right 10px center; color: var(--ink); appearance: none; cursor: pointer; }

main { max-width: 1280px; margin: 0 auto; padding: 28px clamp(16px, 4vw, 40px) 64px; }
main > section { margin-bottom: 64px; }
.more { font-family: var(--mono); font-size: 14px; }

/* ---------- 오늘의 문제 ---------- */
.today-head { display: flex; align-items: center; gap: 22px; margin-bottom: 18px; }
.today-head .lead { margin: 6px 0 0; }
.datestamp {
  display: grid; justify-items: center; flex: none;
  padding: 8px 14px 6px; border: 2px solid var(--ink); border-radius: 6px; background: var(--sheet); box-shadow: var(--shadow);
  font-family: var(--mono); line-height: 1.1; transform: rotate(-2deg);
}
.datestamp .lbl { font-size: 10px; letter-spacing: 0.25em; color: var(--signal); font-weight: 600; }
.datestamp .md { font-size: 34px; font-weight: 600; letter-spacing: -0.04em; }
.datestamp .wd { font-size: 11px; color: var(--ink-2); }

.solve-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 20px; align-items: start; }
.problem { background: var(--sheet); border: 1.5px solid var(--ink); border-radius: 8px; padding: 20px 22px 22px; min-width: 0; position: relative; }
.problem::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 5px; background: var(--hi); border-right: 1.5px solid var(--ink); border-radius: 6px 0 0 6px; }
.ptitle { font-size: 24px; margin: 10px 0 8px; letter-spacing: -0.02em; }
h1.ptitle { font-size: clamp(26px, 3vw, 34px); }
.ptitle a { color: var(--ink); text-decoration: none; }
.ptitle a:hover { text-decoration: underline; text-decoration-color: var(--hi); text-decoration-thickness: 6px; text-underline-offset: -2px; }
.pmeta { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; }
.stamp { font-family: var(--mono); font-size: 11px; color: var(--ink-2); opacity: .6; margin-left: auto; } /* 문제 번호는 눈에 덜 띄게(2026-11-12) */
.bars { display: inline-flex; gap: 2px; align-items: flex-end; height: 14px; }
.bars i { width: 5px; background: var(--rule); border-radius: 1px; }
.bars i:nth-child(1) { height: 6px; } .bars i:nth-child(2) { height: 8px; } .bars i:nth-child(3) { height: 10px; } .bars i:nth-child(4) { height: 12px; } .bars i:nth-child(5) { height: 14px; }
.bars i.on { background: var(--ink); }
.tags { display: inline-flex; gap: 4px; flex-wrap: wrap; }
.tags i { font-style: normal; font-family: var(--mono); font-size: 11px; color: var(--ink-2); background: var(--paper-2); border-radius: 3px; padding: 0 6px; }
.statement { font-size: 16px; margin: 0 0 12px; }
.io { display: grid; grid-template-columns: auto 1fr; gap: 2px 14px; margin: 0 0 14px; padding: 10px 0; border-top: 1px dashed var(--rule); border-bottom: 1px dashed var(--rule); }
.io dt { font-family: var(--mono); font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-2); padding-top: 3px; }
.io dd { margin: 0; }
.example { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 10px; }
.example figure, .io-pair figure { margin: 0; min-width: 0; }
figcaption { font-family: var(--mono); font-size: 11px; color: var(--ink-2); letter-spacing: 0.04em; margin-bottom: 3px; }
.example pre { background: var(--paper-2); border: 1px solid var(--rule); border-radius: 4px; padding: 9px 12px; }

/* ---------- 터미널(편집기·코드) ---------- */
.term { background: var(--term); color: var(--term-fg); border: 1.5px solid var(--ink); border-radius: 8px; box-shadow: var(--shadow); overflow: hidden; min-width: 0; }
.term-bar { display: flex; align-items: center; gap: 10px; padding: 8px 10px 8px 12px; background: var(--term-2); border-bottom: 1px solid var(--term-line); }
.dots { display: inline-flex; gap: 6px; }
.dots i { width: 10px; height: 10px; border-radius: 50%; background: #3a3c31; }
.dots i:first-child { background: var(--signal); }
.file { font-family: var(--mono); font-size: 12px; color: var(--term-fg); background: var(--term); border: 1px solid var(--term-line); border-bottom-color: var(--term); border-radius: 4px 4px 0 0; padding: 3px 10px; margin-bottom: -9px; }
.term .lang-select { background-color: var(--term); color: var(--term-fg); border-color: var(--term-line); }
/* 칸이 좁으면 고르개·파일 이름이 줄어들고 ⓘ 단추는 늘 보인다 */
.term-bar .lang-select { flex: 0 1 auto; min-width: 0; }
.term-bar .grow { flex: 1 1 0; min-width: 0; }
.term-bar .file { flex: none; }
.solver { position: sticky; top: 76px; }
.editor .cm-editor { height: clamp(320px, 46vh, 520px); font-size: 13.5px; background: var(--term); }
.editor .cm-scroller { font-family: var(--mono); line-height: 1.6; }
.editor .cm-gutters { background: var(--term); border-right: 1px solid var(--term-line); color: #5d5f50; }
.editor .cm-activeLine, .editor .cm-activeLineGutter { background: rgba(228, 255, 61, 0.06); }
.term-actions { display: flex; gap: 8px; align-items: center; padding: 10px 12px; border-top: 1px solid var(--term-line); background: var(--term-2); flex-wrap: wrap; }
.key {
  font: 500 13px var(--sans); display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; border-radius: 6px; cursor: pointer;
  color: var(--term-fg); background: #2a2c22; border: 1px solid #3c3f31; border-bottom-width: 3px;
}
.key:hover { background: #33362a; }
.key:active { transform: translateY(1px); border-bottom-width: 2px; }
.key.primary { background: var(--hi); color: var(--hi-ink); border-color: #a9c21c; font-weight: 700; }
.key.primary:hover { filter: brightness(1.05); }
.key.ghost { background: transparent; border-color: transparent; color: var(--term-dim); }
.key:disabled { opacity: 0.4; cursor: not-allowed; transform: none; }
kbd { font-size: 11px; opacity: 0.65; }
.cases { display: flex; flex-wrap: wrap; gap: 3px; padding: 0 12px; min-height: 0; }
.cases:not(:empty) { padding: 10px 12px 0; }
.cases i { width: 11px; height: 11px; border-radius: 2px; background: #34372b; }
.cases i.AC { background: var(--pass); }
.cases i.WA { background: var(--fail); }
.cases i.TLE, .cases i.OLE { background: var(--warn); }
.cases i.RE { background: #b44be1; }
.cases i.run { background: var(--hi); animation: pulse 0.8s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: 0.35; } }
.result { min-height: 64px; max-height: 260px; overflow: auto; padding: 10px 14px 14px; font-size: 13px; white-space: pre-wrap; color: var(--term-fg); background: var(--term); }
.result .prompt { color: var(--hi); }
.result .ok { color: var(--pass); font-weight: 600; }
.result .bad { color: var(--fail); font-weight: 600; }
.result .warn { color: var(--warn); }
.mobile-only { display: none; }
.note, .callout { background: var(--sheet); border: 1.5px solid var(--ink); border-left: 6px solid var(--hi); border-radius: 6px; padding: 12px 16px; }

/* 코드 블록(줄 번호) */
pre.code { background: var(--term); color: var(--term-fg); padding: 12px 0; font-size: 13.5px; line-height: 1.6; counter-reset: ln; }
pre.code .l { display: block; padding: 0 16px 0 0; white-space: pre; }
pre.code .l::before { counter-increment: ln; content: counter(ln); display: inline-block; width: 3.2em; padding-right: 1em; text-align: right; color: #55574a; user-select: none; }

/* 언어별 풀이 */
.solutions { margin-top: 28px; border: 1.5px solid var(--ink); border-radius: 8px; background: var(--sheet); }
.solutions summary { cursor: pointer; display: flex; flex-wrap: wrap; gap: 4px 14px; align-items: baseline; padding: 14px 18px; font-weight: 700; font-size: 17px; list-style: none; }
.solutions summary::before { content: "+"; font-family: var(--mono); color: var(--signal); }
.solutions[open] summary::before { content: "−"; }
.solutions summary .dim { font-weight: 400; font-size: 13px; }
.solutions .callout { margin: 0 18px 14px; }
.sol-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); gap: 14px; padding: 0 18px 18px; }
.codefig { margin: 0; min-width: 0; border: 1.5px solid var(--ink); border-radius: 6px; overflow: hidden; }
.codefig figcaption { display: flex; justify-content: space-between; gap: 8px; margin: 0; padding: 6px 12px; background: var(--term-2); color: var(--term-fg); font-size: 12px; }
.codefig figcaption span { color: var(--term-dim); }

/* ---------- 노선도 커리큘럼 ---------- */
.metro { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.line { --c: var(--l1); }
.line-2 { --c: var(--l2); } .line-3 { --c: var(--l3); } .line-4 { --c: var(--l4); } .line-5 { --c: var(--l5); } .line-6 { --c: var(--l6); } .line-7 { --c: var(--l7); }
.line-head { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; padding-bottom: 8px; border-bottom: 4px solid var(--c); }
.line-head .dim { margin-left: auto; font-family: var(--mono); font-size: 11px; }
.line-chip { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--c); color: #fff; font: 600 12px var(--mono); flex: none; }
.stations { list-style: none; margin: 0; padding: 0; position: relative; }
.stations::before { content: ""; position: absolute; left: 15px; top: 14px; bottom: 14px; width: 4px; background: var(--c); border-radius: 2px; }
.stations li { position: relative; }
.stations a { display: grid; grid-template-columns: 34px 1fr; gap: 10px; align-items: start; padding: 8px 8px 8px 0; color: var(--ink); text-decoration: none; border-radius: 6px; }
.stop { position: relative; z-index: 1; display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--sheet); border: 4px solid var(--c); font: 600 12px var(--mono); }
.st-body { display: grid; padding-top: 3px; }
.st-body b { font-size: 15px; line-height: 1.35; }
.st-body .sum { color: var(--ink-2); font-size: 13px; line-height: 1.5; }
.stations a:hover b { background: linear-gradient(transparent 60%, var(--hi) 60%); }
.stations a:hover .stop { background: var(--c); color: #fff; }

/* ---------- 문제 줄 ---------- */
.prows { list-style: none; margin: 0 0 14px; padding: 0; border-top: 1.5px solid var(--ink); }
.prows a { display: grid; grid-template-columns: minmax(0, 1fr) auto auto auto; gap: 4px 16px; align-items: center; padding: 12px 6px; color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--rule); }
.prows a:has(.tags) { grid-template-columns: minmax(0, 1fr) auto auto auto auto; }
.prows a:hover { background: color-mix(in srgb, var(--hi) 35%, transparent); }
.pid { font-family: var(--mono); font-size: 11px; color: var(--ink-2); opacity: .6; }
.pt { font-size: 16px; }
.langs8 { font: 600 11px var(--mono); border: 1.5px solid var(--ink); border-radius: 999px; padding: 0 7px; }
.langs8::after { content: " langs"; font-weight: 400; color: var(--ink-2); }
.langs8.some { border-color: var(--l6); color: var(--l6); }

/* ---------- 배우기 ---------- */
.lang-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 14px 0 22px; }
.lang-tabs a { padding: 4px 12px; border-radius: 999px; border: 1.5px solid var(--ink); background: var(--sheet); color: var(--ink); text-decoration: none; font-size: 14px; font-weight: 500; }
.lang-tabs a[aria-current] { background: var(--ink); color: var(--paper); }
.lesson-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 36px; }
.lesson-side { position: sticky; top: 76px; align-self: start; max-height: calc(100vh - 96px); overflow: auto; font-size: 14px; padding-right: 6px; }
.lesson-side .side-ch { display: flex; align-items: center; gap: 6px; font-weight: 700; margin: 14px 0 4px; }
.lesson-side ol { list-style: none; margin: 0; padding: 0 0 0 10px; border-left: 4px solid var(--c); margin-left: 9px; }
.lesson-side a { display: flex; align-items: center; gap: 8px; padding: 4px 8px; color: var(--ink); text-decoration: none; border-radius: 4px; }
.lesson-side .stop { width: 24px; height: 24px; border-width: 3px; font-size: 10px; margin-left: -24px; }
.lesson-side a[aria-current] { background: var(--hi); color: var(--hi-ink); font-weight: 700; }
.lesson { max-width: 860px; min-width: 0; font-size: 16px; }
.lesson > p { max-width: 70ch; }
.crumb { font-family: var(--mono); font-size: 12px; color: var(--ink-2); margin: 0; }
.lesson-no { font-family: var(--mono); font-size: 12px; letter-spacing: 0.08em; color: var(--signal); margin: 14px 0 0; text-transform: uppercase; }
.lesson-term { margin: 24px 0; }
.code-tabs { display: flex; overflow-x: auto; background: var(--term-2); border-bottom: 1px solid var(--term-line); scrollbar-width: thin; }
.code-tabs a { display: grid; padding: 7px 14px 6px; color: var(--term-dim); text-decoration: none; border-right: 1px solid var(--term-line); white-space: nowrap; line-height: 1.25; border-top: 2px solid transparent; }
.code-tabs a b { font-size: 13px; font-weight: 600; }
.code-tabs a span { font: 11px var(--mono); }
.code-tabs a:hover { color: var(--term-fg); }
.code-tabs a[aria-current] { background: var(--term); color: var(--term-fg); border-top-color: var(--hi); }
.io-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--term-line); border-top: 1px solid var(--term-line); }
.io-pair figure { background: var(--term-2); padding: 8px 14px 10px; }
.io-pair figcaption { color: var(--term-dim); }
.io-pair pre { color: var(--term-fg); }
.run-row { margin: 0; padding: 10px 14px; background: var(--term-2); border-top: 1px solid var(--term-line); display: flex; align-items: center; gap: 12px; color: var(--term-dim); font-family: var(--mono); font-size: 12px; }
.prevnext { display: flex; justify-content: space-between; gap: 12px; margin-top: 36px; padding-top: 16px; border-top: 1.5px solid var(--ink); flex-wrap: wrap; }
.prevnext a { font-weight: 600; text-decoration: none; }

/* ---------- 크레이콘 놀이터 ---------- */
.playground { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.code-area, .stdin { width: 100%; border: 1.5px solid var(--ink); border-radius: 8px; background: var(--term); color: var(--term-fg); padding: 12px; line-height: 1.6; }
.code-area { min-height: 400px; box-shadow: var(--shadow); }
.stdin { min-height: 56px; display: block; margin-top: 4px; }
.playground .result { border: 1.5px solid var(--ink); border-radius: 8px; }
.playground .result.pass { box-shadow: inset 4px 0 0 var(--pass); }
.playground .result.fail { box-shadow: inset 4px 0 0 var(--fail); }
.btn { display: inline-flex; align-items: center; gap: 6px; font: 500 14px var(--sans); padding: 6px 14px; border-radius: 6px; border: 1.5px solid var(--ink); background: var(--sheet); color: var(--ink); cursor: pointer; text-decoration: none; }
.btn:hover { background: var(--hi); color: var(--hi-ink); }
.btn.primary { background: var(--ink); color: var(--paper); }
.btn.small { font-size: 12px; padding: 2px 9px; }

.doc { max-width: 920px; overflow-wrap: anywhere; background: var(--sheet); border: 1.5px solid var(--ink); border-radius: 8px; padding: 8px 28px 24px; }
.doc pre { background: var(--paper-2); padding: 10px; border-radius: 4px; }
.doc blockquote { margin: 0; padding: 4px 14px; border-left: 4px solid var(--hi); color: var(--ink-2); }

/* ---------- 바닥 ---------- */
.foot { border-top: 1.5px solid var(--ink); padding: 26px clamp(16px, 4vw, 40px) 44px; color: var(--ink-2); font-size: 13px; text-align: center; background: var(--paper); }
.foot p { margin: 4px 0; }
.foot-links a { color: var(--ink-2); }
.root-pick { max-width: 420px; margin: 15vh auto; text-align: center; padding: 0 16px; }
.root-pick ul { list-style: none; padding: 0; display: grid; gap: 10px; }
.root-pick a { display: block; padding: 12px; border: 1.5px solid var(--ink); border-radius: 8px; background: var(--sheet); color: var(--ink); text-decoration: none; box-shadow: var(--shadow); }

/* ---------- 좁은 화면 ---------- */
@media (max-width: 1100px) {
  .metro { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 899px) {
  .solve-grid { grid-template-columns: 1fr; }
  .solver, .pc-only { display: none !important; }
  .mobile-only { display: block; margin-top: 14px; }
  .example { grid-template-columns: 1fr; }
  .io-pair { grid-template-columns: 1fr; }
  .lesson-layout { grid-template-columns: 1fr; }
  .lesson-side { display: none; }
  .playground { grid-template-columns: 1fr; }
  .sol-grid { grid-template-columns: 1fr; }
  .prows a, .prows a:has(.tags) { grid-template-columns: minmax(0, 1fr) auto; }
  .prows .tags, .prows .langs8, .prows .pid { display: none; }
  .today-head { gap: 14px; }
  .datestamp .md { font-size: 26px; }
  .problem { padding: 16px 16px 18px 20px; }
}
@media (max-width: 560px) {
  .metro { grid-template-columns: 1fr; }
  .top { gap: 6px 14px; }
  .nav-n { display: none; }
  .today-head .lead { display: none; }
}

/* 고침(2026-11-10): 옆 목록 노선 색, 현재 단원 표시, 단원 안 제목 간격 */
.line-1 { --c: var(--l1); }
.lesson-side ol { padding-left: 14px; }
.lesson-side .stop { margin-left: -27px; background: var(--paper); }
.lesson-side a[aria-current] { background: transparent; color: var(--ink); font-weight: 700; }
.lesson-side a[aria-current] .stop { background: var(--c); color: #fff; }
.lesson-side a[aria-current]::after { content: ""; flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--hi); box-shadow: 0 0 0 2px var(--ink); margin-left: auto; }
.lesson h2 { margin-top: 36px; }

/* ---------- IntelliSense·오류 표시(Visual Studio처럼) ---------- */
/* 물결 밑줄: 오류 빨강, 경고 초록빛 노랑(VS 경고색), 줄 전체 옅게, 여백에 아이콘 */
.editor .cm-lintRange-error { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='6' height='3'%3E%3Cpath d='m0 3 l2 -2 l1 0 l2 2 l1 0' stroke='%23ff5f56' fill='none' stroke-width='1.1'/%3E%3C/svg%3E"); }
.editor .cm-lintRange-warning { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='6' height='3'%3E%3Cpath d='m0 3 l2 -2 l1 0 l2 2 l1 0' stroke='%23e8c547' fill='none' stroke-width='1.1'/%3E%3C/svg%3E"); }
.editor .cm-line-error { background: rgba(255, 95, 86, 0.11); box-shadow: inset 3px 0 0 #ff5f56; }
.editor .cm-line-warning { background: rgba(232, 197, 71, 0.08); box-shadow: inset 3px 0 0 #e8c547; }
.editor .cm-gutter-lint { width: 16px; }
.editor .cm-gutter-lint .cm-gutterElement { padding: 0 2px; }
.editor .cm-lint-marker { width: 12px; height: 12px; margin-top: 3px; }
.editor .cm-lint-marker-error { content: none; background: #ff5f56; border-radius: 50%; position: relative; }
.editor .cm-lint-marker-error::after { content: "×"; position: absolute; inset: -3px 0 0; text-align: center; font: 700 12px/16px var(--mono); color: #1b0a09; }
.editor .cm-lint-marker-warning { content: none; background: #e8c547; clip-path: polygon(50% 0, 100% 100%, 0 100%); }
/* 떠 있는 상자: 진단·자동완성·매개변수·설명 */
.term .cm-tooltip, .ck-editor .cm-tooltip { font: 12.5px/1.5 var(--mono); border-radius: 6px; box-shadow: 0 6px 24px rgba(0, 0, 0, 0.45); overflow: hidden; }
.cm-tooltip.cm-tooltip-lint { padding: 0; max-width: 520px; }
.cm-tooltip .cm-diagnostic { padding: 6px 10px 6px 12px; white-space: pre-wrap; border-left-width: 4px; }
.cm-tooltip .cm-diagnostic-error { border-left-color: #ff5f56; }
.cm-tooltip .cm-diagnostic-warning { border-left-color: #e8c547; }
.cm-tooltip .cm-diagnosticSource { display: inline-block; margin-top: 2px; color: var(--term-dim); font-size: 11px; opacity: 1; }
/* 고른 항목의 설명(옆에 붙는 상자)이 잘리지 않게: 자동완성 상자만 넘침을 보인다 */
.term .cm-tooltip.cm-tooltip-autocomplete, .ck-editor .cm-tooltip.cm-tooltip-autocomplete { overflow: visible; }
.cm-tooltip.cm-tooltip-autocomplete > ul { border-radius: 6px; }
.cm-tooltip.cm-tooltip-autocomplete > ul { font: 13px/1.4 var(--mono); max-height: 16em; min-width: 260px; }
.cm-tooltip.cm-tooltip-autocomplete > ul > li { padding: 2px 10px 2px 4px; }
.cm-tooltip.cm-tooltip-autocomplete > ul > li[aria-selected] { background: #33402a; color: var(--term-fg); }
.cm-tooltip-autocomplete .cm-completionDetail { color: var(--term-dim); font-style: normal; margin-left: 10px; }
.cm-tooltip-autocomplete .cm-completionMatchedText { color: var(--hi); text-decoration: none; font-weight: 700; }
.cm-completionIcon { width: 1.1em; opacity: 1; padding-right: 0.7em; text-align: center; }
.cm-completionIcon-function::after, .cm-completionIcon-method::after { content: "ƒ"; color: #c792ea; }
.cm-completionIcon-property::after { content: "◆"; color: #82aaff; font-size: 0.8em; }
.cm-completionIcon-class::after { content: "◇"; color: #ffcb6b; }
.cm-completionIcon-keyword::after { content: "⌘"; color: #89ddff; font-size: 0.85em; }
.cm-completionIcon-variable::after { content: "𝑥"; color: #addb67; }
.cm-completionIcon-text::after { content: "⎘"; color: var(--hi); }
.cm-tooltip.cm-completionInfo { padding: 8px 10px; max-width: 420px; min-width: 200px; border: 1px solid #3a3f33; border-radius: 6px; box-shadow: 0 6px 24px rgba(0, 0, 0, 0.45); }
.cm-intel-info code, .cm-sig code { background: none; border: 0; padding: 0; font: inherit; }
.cm-intel-info code { display: block; color: var(--hi); white-space: pre-wrap; }
.cm-intel-info p { margin: 4px 0 0; color: var(--term-fg); font-family: var(--sans); }
.cm-intel-info p.more { margin-top: 8px; padding-top: 8px; border-top: 1px solid #343a2c; color: #cfd3c4; line-height: 1.55; font-size: 12.5px; }
.cm-intel-info p.more code { display: inline; color: var(--hi); background: rgba(255, 255, 255, 0.06); border-radius: 3px; padding: 0 3px; }
.cm-intel-info .exl { margin-top: 8px; font: 600 10.5px/1 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--term-dim); }
.cm-intel-info pre { margin: 4px 0 0; padding: 6px 8px; background: rgba(0, 0, 0, 0.35); border-radius: 4px; font: 12px/1.45 var(--mono); color: var(--term-fg); white-space: pre-wrap; }
.cm-sig { padding: 5px 10px; max-width: 560px; }
.cm-sig code { color: var(--term-fg); }
.cm-sig code .on { color: var(--hi); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.cm-sig .dim { color: var(--term-dim); font-family: var(--sans); font-size: 12px; }
/* 오류 목록 */
.errlist { border-top: 1px solid var(--term-line); background: var(--term); font-size: 12.5px; }
.errhead { display: flex; align-items: center; gap: 12px; padding: 6px 12px; background: var(--term-2); border-bottom: 1px solid var(--term-line); color: var(--term-fg); }
.errhead b { font-weight: 600; letter-spacing: 0.02em; }
.errhead .cnt { display: inline-flex; align-items: center; gap: 5px; font-family: var(--mono); color: var(--term-dim); }
.errhead .dim { color: var(--term-dim); font-size: 11px; font-family: var(--mono); }
.errlist ol { list-style: none; margin: 0; padding: 0; max-height: 260px; overflow: auto; }
.errlist li { display: grid; grid-template-columns: 16px minmax(64px, auto) minmax(0, 1fr) auto; gap: 10px; align-items: start; padding: 5px 12px; cursor: pointer; color: var(--term-fg); border-bottom: 1px solid #1d1f16; }
.errlist li:hover, .errlist li:focus { background: #23261b; outline: none; }
.errlist li:focus { box-shadow: inset 2px 0 0 var(--hi); }
.errlist .code { font-family: var(--mono); color: var(--term-dim); white-space: nowrap; }
.errlist .msg { min-width: 0; overflow-wrap: anywhere; }
.errlist .msg small { display: block; color: #b9c98a; font-size: 12px; margin-top: 2px; }
.errlist .msg small.orig { color: var(--term-dim); font-family: var(--mono); font-size: 11.5px; }
.errlist .msg small.orig b { font-weight: 500; border: 1px solid var(--term-line); border-radius: 3px; padding: 0 4px; margin-right: 4px; font-family: var(--sans); font-size: 10.5px; }
.errlist .pos { font-family: var(--mono); color: var(--term-dim); white-space: nowrap; }
.ico { display: inline-block; width: 13px; height: 13px; margin-top: 2px; position: relative; flex: none; }
.ico.error { background: #ff5f56; border-radius: 50%; }
.ico.error::after { content: "×"; position: absolute; inset: -2px 0 0; text-align: center; font: 700 12px/15px var(--mono); color: #1b0a09; }
.ico.warning { background: #e8c547; clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.ico.warning::after { content: "!"; position: absolute; inset: 2px 0 0; text-align: center; font: 800 9px/12px var(--sans); color: #2a2205; }
.result .loc-link { color: #ff8a80; text-decoration: underline dotted; cursor: pointer; }
.result .loc-link:hover { color: var(--hi); }
.result .raw { opacity: 0.85; }
/* 크레이콘 놀이터: 편집기 칸 */
.ck-left { display: flex; flex-direction: column; }
.ck-left .code-area { border: 0; border-radius: 0; box-shadow: none; }
.ck-editor .cm-editor { height: 420px; font-size: 14px; background: var(--term); }
.ck-editor .cm-gutters { background: var(--term); border-right: 1px solid var(--term-line); color: #5d5f50; }

/* 빠른 수정(고치는 예 + 적용 단추) */
.errlist .fix { display: grid; justify-items: start; gap: 2px; margin-top: 6px; padding: 7px 10px; background: #191b13; border: 1px solid var(--term-line); border-left: 3px solid var(--hi); border-radius: 4px; }
.errlist .fix-t { color: var(--hi); font-size: 11.5px; font-weight: 600; margin-bottom: 2px; }
.errlist .fix code { font: 12.5px/1.5 var(--mono); background: none; border: 0; padding: 0 4px; white-space: pre-wrap; border-radius: 2px; }
.errlist .fix code.del { color: #ff9c94; background: rgba(255, 95, 86, 0.1); text-decoration: line-through; text-decoration-color: rgba(255, 95, 86, 0.5); }
.errlist .fix code.ins { color: #9be38f; background: rgba(70, 209, 126, 0.12); }
.errlist .fix .key { margin-top: 6px; }
.key.small { font-size: 12px; padding: 3px 10px; }
.cm-tooltip .cm-diagnosticAction { background: var(--hi); color: var(--hi-ink); border: 0; border-radius: 4px; padding: 2px 10px; font: 600 12px var(--sans); margin: 4px 0 2px; cursor: pointer; }

/* 되돌리기·다시 하기 */
.hist { display: inline-flex; gap: 4px; margin-right: 4px; }
.key.icon { padding: 5px 8px; line-height: 0; }
.key.icon svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.key:disabled { opacity: 0.35; cursor: default; transform: none; }
/* 코드가 바뀐 뒤의 지난 결과 */
.result.stale { opacity: 0.55; }
.result .stale-note { color: var(--hi); opacity: 1; }

/* 입력(stdin) 칸 */
.stdin-panel { border-top: 1px solid var(--term-line); background: var(--term); padding: 8px 12px 6px; }
.stdin-tabs { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; margin-bottom: 6px; }
.stdin-title { color: var(--term-dim); font: 600 12px var(--sans); margin-right: 8px; }
.stdin-tab { font: 12px var(--mono); color: var(--term-dim); background: transparent; border: 1px solid var(--term-line); border-radius: 4px; padding: 2px 9px; cursor: pointer; }
.stdin-tab:hover { color: var(--term-fg); }
.stdin-tab[aria-selected="true"] { color: var(--hi-ink); background: var(--hi); border-color: var(--hi); font-weight: 600; }
.stdin-box { display: block; width: 100%; resize: vertical; font: 13px/1.5 var(--mono); color: var(--term-fg); background: #181a12; border: 1px solid var(--term-line); border-radius: 4px; padding: 6px 10px; }
.stdin-box[readonly] { color: #cfd0b8; background: #14150f; }
.stdin-box:focus { outline: 1px solid var(--hi); }
.stdin-hint { margin: 4px 0 0; color: var(--term-dim); font-size: 11.5px; }
/* 결과: 입력·내 출력·기대 출력 */
.result .io3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 6px; }
.result .io3.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.result .iob { display: block; background: #181a12; border: 1px solid var(--term-line); border-radius: 4px; padding: 4px 8px 6px; white-space: pre-wrap; overflow-wrap: anywhere; min-width: 0; }
.result .iot { display: block; color: var(--term-dim); font: 600 11px var(--sans); margin-bottom: 2px; }
.result .dl { background: rgba(255, 95, 86, 0.18); color: #ffb3ad; }
.result .dl.want { background: rgba(70, 209, 126, 0.15); color: #9be38f; }

/* 터미널(대화형) */
.result .tin { color: var(--hi); }
.result .tline { display: inline-flex; align-items: baseline; gap: 12px; }
.result .tinput { font: inherit; color: var(--hi); background: transparent; border: 0; border-bottom: 1px dashed var(--hi); padding: 0 2px; outline: none; caret-color: var(--hi); min-width: 2ch; }
.result .thelp { color: var(--term-dim); font-size: 11px; font-family: var(--sans); white-space: nowrap; }
.result .tspin { animation: pulse 0.9s ease-in-out infinite; }
.stdin-box[hidden] { display: none; }

.stdin-load { display: inline-flex; gap: 4px; margin-left: auto; }
.stdin-load[hidden] { display: none; }
.stdin-chip { font: 11.5px var(--sans); color: var(--term-dim); background: transparent; border: 1px dashed var(--term-line); border-radius: 4px; padding: 2px 8px; cursor: pointer; }
.stdin-chip:hover { color: var(--hi); border-color: var(--hi); }
.result .miss { color: var(--term-dim); border: 1px dashed var(--term-line); border-radius: 2px; padding: 0 3px; }
.result .refin { display: block; color: var(--term-dim); border-bottom: 1px dashed var(--term-line); padding-bottom: 4px; margin-bottom: 4px; }
.result .cta { display: inline-flex; align-items: center; gap: 10px; margin-top: 4px; padding: 6px 10px; border: 1px solid var(--term-line); border-left: 3px solid var(--hi); border-radius: 4px; background: #191b13; color: var(--term-fg); font-family: var(--sans); font-size: 12.5px; }

/* 실행 판(2026-11-10): 편집기 위 판 고르기 + 한 줄 실행 환경 */
.term .ver-select { margin-left: 6px; }
.term .rt-toggle { width: 22px; height: 22px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, 0.25); background: none; color: var(--term-dim); font: italic 600 12px/1 Georgia, serif; cursor: pointer; padding: 0; flex: none; }
.term .rt-toggle:hover, .term .rt-toggle[aria-expanded="true"] { color: var(--term-fg); border-color: var(--term-fg); }
.term .rt-info[hidden] { display: none; }
.term .rt-info { padding: 4px 14px 6px; font: 11.5px/1.5 var(--mono); color: var(--term-dim); border-bottom: 1px solid rgba(255, 255, 255, 0.06); overflow-wrap: anywhere; }
.term .rt-info b { color: var(--term-fg); font-weight: 500; }
.term .rt-info code { background: none; border: 0; padding: 0; color: var(--term-dim); font: inherit; }
.term .rt-info a { color: var(--term-dim); text-decoration: underline; }
.rt-table td, .rt-table th { white-space: nowrap; }
.rt-table tr.def td { font-weight: 600; }
/* 편집기 칸이 좁으면 장식 점을 빼서 파일 이름·고르개·ⓘ가 다 보이게 */
.solver.term { container-type: inline-size; }
@container (max-width: 480px) { .term-bar .dots { display: none; } }

/* 언어가 정해진 단원(포인터는 C·C++ 등) */
.only-chip { display: inline-block; margin: 2px 0 0; padding: 0 7px; border: 1px solid var(--c, var(--ink)); border-radius: 999px; font: 500 11px/1.6 var(--mono); color: var(--c, var(--ink)); width: fit-content; }
.only-line { padding: 8px 12px; border-left: 4px solid var(--l6); background: color-mix(in srgb, var(--l6) 10%, transparent); border-radius: 0 6px 6px 0; }
.prevnext .pn-next { margin-left: auto; }

/* ---------- 배우기 글 읽기 쉽게(2026-11-10) ---------- */
.lesson { font-size: 16.5px; line-height: 1.8; }
.lesson > p, .lesson .intro, .lesson .points, .lesson .only-line { max-width: 66ch; }
.lesson .intro { font-size: 17.5px; line-height: 1.85; margin: 0 0 22px; }
.lesson :not(pre) > code { background: color-mix(in srgb, var(--ink) 8%, transparent); border: 0; padding: 1px 5px; border-radius: 4px; font-size: 0.86em; white-space: nowrap; }
.lesson h2 { font-size: 20px; margin: 40px 0 12px; }
.lesson .lesson-term { margin: 6px 0 8px; }
.points { padding-left: 1.2em; margin: 0; }
.points li { margin: 0 0 10px; padding-left: 4px; }
.points li::marker { color: var(--l1); }
.howto { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 1.6; }
.howto th { text-align: left; white-space: nowrap; width: 1%; padding: 9px 14px 9px 10px; font: 600 13px var(--mono); color: var(--ink-2); vertical-align: top; }
.howto td { padding: 9px 10px; }
.howto tr { border-bottom: 1px solid var(--rule); }
.howto tr.me { background: color-mix(in srgb, var(--hi) 14%, transparent); }
.howto tr.me th { color: var(--ink); }
.howto td code { white-space: normal; }
.traps { display: grid; gap: 14px; }
.trap { border: 1.5px solid var(--rule); border-left: 5px solid var(--l2); border-radius: 6px; padding: 12px 16px; }
.trap h3 { font-size: 16px; margin: 0 0 8px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.trap-code { margin: 0 0 6px; padding: 8px 12px; background: var(--term); color: var(--term-fg); border-radius: 4px; font: 13.5px/1.6 var(--mono); overflow-x: auto; }
.trap-result { margin: 0 0 6px; color: var(--l2); font-weight: 600; }
.trap-fix { margin: 0; }
@media (max-width: 560px) {
  .lesson { font-size: 16px; } .lesson .intro { font-size: 16.5px; }
  /* 좁은 화면: 언어 이름을 줄 위에 */
  .howto, .howto tbody, .howto tr, .howto th, .howto td { display: block; width: auto; }
  .howto th { padding: 10px 10px 0; } .howto td { padding: 4px 10px 10px; }
}
.lesson .traps + .callout, .lesson .callout { margin-top: 26px; }
/* 문장마다 줄을 바꾼 글: 줄 사이를 조금 띄운다 */
.lesson .points li, .howto td, .trap-fix, .callout, .statement, .io dd { line-height: 1.85; }

/* 문제 목록 거르기 */
.pfilter { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 0 0 14px; }
.pfilter input[type="search"] { flex: 1 1 220px; min-width: 0; font: inherit; padding: 6px 12px; border: 1.5px solid var(--ink); border-radius: 999px; background: var(--sheet); color: var(--ink); }
.pfilter select { font: 500 13px var(--sans); padding: 6px 26px 6px 10px; border-radius: 999px; border: 1.5px solid var(--ink); background: var(--sheet) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23888'/%3E%3C/svg%3E") no-repeat right 10px center; color: var(--ink); appearance: none; max-width: 100%; }
.pfilter .pcount { color: var(--ink-2); font: 500 13px var(--mono); margin-left: auto; }
@media (max-width: 560px) { .pfilter select { flex: 1 1 45%; } .pfilter .pcount { margin-left: 0; } }

/* ---------- 계정: 로그인 버튼, 가입 권유, 푼 문제 체크 ---------- */
.acct { font: 500 13px var(--sans); padding: 5px 12px; border-radius: 999px; border: 1.5px solid var(--ink); background: var(--ink); color: var(--paper); cursor: pointer; white-space: nowrap; max-width: 46vw; overflow: hidden; text-overflow: ellipsis; }
.signed-in .acct { background: var(--sheet); color: var(--ink); }
.acct[hidden] { display: none; }
.join { display: flex; align-items: center; gap: 10px 20px; flex-wrap: wrap; margin: 0 0 34px; padding: 14px 18px; border: 1.5px solid var(--ink); border-radius: 10px; background: var(--sheet); }
.join p { margin: 0; flex: 1 1 280px; font-size: 14.5px; line-height: 1.6; color: var(--ink-2); }
.join b { color: var(--ink); }
.signed-in .join { display: none; }
.ck-banner { display: flex; align-items: center; gap: 10px 14px; flex-wrap: wrap; margin: 0 0 34px; padding: 14px 18px; border: 1.5px solid var(--ink); border-left: 8px solid #ff7a1a; border-radius: 10px; background: #fff6e0; }
.ck-banner p { margin: 0; flex: 1 1 280px; font-size: 14.5px; line-height: 1.6; color: #4a4435; }
.ck-banner b { color: #1a1814; }
.ck-banner a.key { text-decoration: none; }
.ck-new { display: inline-block; margin-left: 4px; padding: 0 7px; border-radius: 999px; background: #ff7a1a; color: #fff; font-size: 12px; font-weight: 700; white-space: nowrap; }
.solved-count { display: inline-block; margin-left: 6px; padding: 1px 9px; border-radius: 999px; background: var(--hi); color: var(--hi-ink); font: 600 12.5px var(--mono); }
.solved-count[hidden] { display: none; }
.prows li.done .pt::before, .problem.done .ptitle::before { content: "✓"; display: inline-block; margin-right: 7px; padding: 0 5px; border-radius: 4px; background: var(--hi); color: var(--hi-ink); font: 700 0.8em/1.5 var(--mono); vertical-align: 0.08em; }
.prows li.done .pt { color: var(--ink-2); }
.acct-dlg { width: min(440px, calc(100vw - 32px)); padding: 22px 22px 18px; border: 1.5px solid var(--ink); border-radius: 12px; background: var(--paper); color: var(--ink); font: 14.5px/1.6 var(--sans); }
.acct-dlg::backdrop { background: rgb(0 0 0 / 0.45); }
.acct-dlg h2 { margin: 0 0 10px; font-size: 20px; }
.acct-dlg p { margin: 8px 0; }
.acct-why { margin: 0 0 10px; padding-left: 20px; }
.acct-why li { margin: 3px 0; }
.acct-shared { padding: 9px 12px; border-left: 3px solid var(--signal); background: var(--paper-2); font-size: 13.5px; }
.acct-shared a { color: inherit; }
.acct-dlg input[type="email"], .acct-dlg #acct-code { display: block; width: 100%; box-sizing: border-box; margin: 10px 0 0; padding: 10px 12px; border: 1.5px solid var(--ink); border-radius: 8px; background: var(--sheet); color: var(--ink); font: 16px var(--sans); }
.acct-dlg #acct-code { font: 600 20px var(--mono); letter-spacing: 0.25em; }
.acct-dlg input[readonly] { opacity: 0.65; }
.acct-check { display: flex; gap: 8px; align-items: flex-start; margin: 12px 0 0; cursor: pointer; }
.acct-check input { margin-top: 5px; }
.acct-sent, .acct-fine { font-size: 13px; color: var(--ink-2); }
.acct-msg { min-height: 1.6em; color: var(--signal); font-weight: 500; }
.acct-msg[role="status"] { color: var(--ink-2); }
.acct-row { display: flex; align-items: center; gap: 8px; margin-top: 6px; }
@media (max-width: 480px) {
  /* 첫 줄: 로고 · 로그인 · 사이트 언어, 둘째 줄: 메뉴 */
  .top { column-gap: 8px; }
  .top .main-nav { order: 3; flex-basis: 100%; }
  .acct-who { display: none; }
  .site-lang { padding-left: 8px; padding-right: 22px; background-position: right 8px center; }
}
@media (max-width: 360px) {
  .top .caret { display: none; }
  .top .brand { font-size: 16px; }
  .top > .sr { position: absolute; }
  .top > .grow { display: none; }
  .top .acct { margin-left: auto; padding: 5px 9px; }
}

/* ---------- 크레이콘 코스·타일 문제 ---------- */
.tchip { display: inline-block; padding: 1px 9px; border-radius: 5px; background: color-mix(in srgb, var(--c) 74%, #7a4b22); color: #fff; font-weight: 700; font-size: .92em; white-space: nowrap; }
.ck-track .crumb { font-size: 14px; color: var(--ink-2); margin: 0 0 4px; }
.ck-chapter { margin: 28px 0; }
.ck-ch { display: inline-block; margin-right: 6px; padding: 2px 10px; border-radius: 999px; background: var(--ink); color: var(--sheet); font-size: .7em; vertical-align: middle; }
.ck-soon { margin: 8px 0 0; color: var(--dim, #8a8372); font-size: 14px; }
.ck-cards { list-style: none; padding: 0; margin: 12px 0 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.ck-card { display: grid; gap: 4px; padding: 14px; border: 2px solid var(--ink); border-radius: 12px; background: var(--sheet); color: inherit; text-decoration: none; height: 100%; box-sizing: border-box; }
.ck-card:hover { background: var(--hi); }
.ck-no { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--ink); color: var(--sheet); font-weight: 800; font-size: 14px; }
.ck-done .ck-no, .ck-plist a.ck-done .lv { background: #1f9d55; color: #fff; }
.ck-card.ck-done strong::after, .ck-plist a.ck-done strong::after { content: " ★"; color: #1f9d55; }
.ck-step { margin: 28px 0; padding-top: 8px; border-top: 1px dashed var(--rule); }
.ck-step h2 { margin: 8px 0; }
.tb-goal { margin: 12px 0 0; padding: 10px 12px; border-left: 5px solid var(--ink); background: var(--paper-2); font-weight: 600; }
.tb-goal span { display: inline-block; margin-right: 6px; padding: 0 8px; border-radius: 999px; background: var(--ink); color: var(--sheet); font-size: 12px; }
.ck-plist { list-style: none; padding: 0; margin: 16px 0; display: grid; gap: 8px; }
.ck-plist a { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; padding: 12px 14px; border: 1px solid var(--rule); border-radius: 10px; background: var(--sheet); color: inherit; text-decoration: none; }
.ck-plist a:hover { border-color: var(--ink); }
.ck-track .lv { font-size: 11px; letter-spacing: 1px; padding: 2px 6px; border-radius: 999px; color: var(--ink-2); }
.ck-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 4px 0 12px; }
.ck-example { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin: 12px 0; }
.ck-example span { font-size: 12px; font-weight: 700; color: var(--ink-2); }
.ck-example pre { margin: 2px 0 0; }
.ck-next { margin: 28px 0; }
.ck-track .tag { display: inline-block; padding: 1px 8px; border: 1px solid var(--rule); border-radius: 999px; font-size: 12px; color: var(--ink-2); background: var(--paper-2); margin-right: 4px; }
.ck-track .tag[class*="kind-"] { border-color: var(--ink); color: var(--ink); background: var(--sheet); font-weight: 700; }
.ck-plist a strong { flex: 1 1 150px; }
.ck-plist a .lv { flex: none; }
