/* McKay Math Atelier — 제도판(설계 도면) 톤의 고급 외형. math-lab.css 위에 덧입힌다. */
:root,
:root[data-theme="light"] {
  --at-bg: #edf1ee;
  --at-surface: #fbfcfa;
  --at-surface-2: #f2f5f1;
  --at-ink: #14232a;
  --at-muted: #56676c;
  --at-line: #d2dbd6;
  --at-brass: #9c6a17;
  --at-shadow: 0 1px 0 rgba(20, 35, 42, 0.04), 0 18px 40px -26px rgba(20, 35, 42, 0.45);
  --pl-paper: #fbfcfa;
  --pl-ink: #14232a;
  --pl-muted: #677a7f;
  --pl-grid: #e2e8e4;
  --pl-axis: #7b8b8f;
  --pl-a: #cf5526;
  --pl-b: #2465b5;
  --pl-c: #0f7d67;
  --pl-d: #c03358;
  --pl-e: #6a4fc4;
  --pl-f: #9c6a17;
  /* 기존 중학교 실험이 쓰는 토큰 */
  --ink: var(--at-ink);
  --muted: var(--at-muted);
  --paper: var(--at-bg);
  --surface: var(--at-surface);
  --line: var(--at-line);
  --plot-ink: var(--pl-ink);
  --brand: #14232a;
  --brand2: #1d6570;
  --accent: #cf5526;
  --course: #0f8a8a;
  --f-sans: "IBM Plex Sans KR", "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif;
  --f-kr-serif: "Nanum Myeongjo", "AppleMyungjo", "Batang", serif;
  --f-display: "Instrument Serif", "Nanum Myeongjo", Georgia, serif;
  --f-mono: "IBM Plex Mono", "IBM Plex Sans KR", ui-monospace, "Cascadia Mono", Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --at-bg: #0c1417; --at-surface: #121d21; --at-surface-2: #17252a; --at-ink: #e2eae9; --at-muted: #95a7aa; --at-line: #27393f; --at-brass: #d9a54a;
    --at-shadow: 0 1px 0 rgba(0, 0, 0, 0.3), 0 20px 44px -26px rgba(0, 0, 0, 0.8);
    --pl-paper: #10191d; --pl-ink: #e2eae9; --pl-muted: #93a6a9; --pl-grid: #1b2a2f; --pl-axis: #6c8388;
    --pl-a: #f08650; --pl-b: #6ea9f0; --pl-c: #40cfa5; --pl-d: #f07893; --pl-e: #a894f5; --pl-f: #d9a54a;
    --brand: #e2eae9; --brand2: #81d0d1;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --at-bg: #0c1417; --at-surface: #121d21; --at-surface-2: #17252a; --at-ink: #e2eae9; --at-muted: #95a7aa; --at-line: #27393f; --at-brass: #d9a54a;
  --at-shadow: 0 1px 0 rgba(0, 0, 0, 0.3), 0 20px 44px -26px rgba(0, 0, 0, 0.8);
  --pl-paper: #10191d; --pl-ink: #e2eae9; --pl-muted: #93a6a9; --pl-grid: #1b2a2f; --pl-axis: #6c8388;
  --pl-a: #f08650; --pl-b: #6ea9f0; --pl-c: #40cfa5; --pl-d: #f07893; --pl-e: #a894f5; --pl-f: #d9a54a;
  --brand: #e2eae9; --brand2: #81d0d1;
}

body.at {
  margin: 0;
  background: var(--at-bg);
  color: var(--at-ink);
  font-family: var(--f-sans);
  font-size: 16.5px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
}
body.at a { color: inherit; }
body.at :focus-visible { outline: 2.5px solid var(--course); outline-offset: 2px; }

/* ── 머리글 ── */
.at-header {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 20;
  background: color-mix(in srgb, var(--at-bg) 86%, transparent);
  backdrop-filter: blur(14px) saturate(1.2);
  border-bottom: 1px solid var(--at-line);
}
.at-header-inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: 12px clamp(16px, 4vw, 40px);
  display: flex;
  align-items: center;
  gap: 20px;
}
.at-brand { display: flex; align-items: center; gap: 11px; text-decoration: none; }
.at-mark { width: 34px; height: 34px; flex: none; }
.at-word { font-weight: 600; font-size: 18.5px; letter-spacing: -0.01em; white-space: nowrap; }
.at-word em { font-family: var(--f-display); font-style: italic; font-weight: 400; font-size: 24px; margin-left: 2px; }
.at-nav { display: flex; gap: 18px; margin-left: auto; }
.at-nav a { color: var(--at-muted); text-decoration: none; font-size: 16px; }
.at-nav a:hover { color: var(--at-ink); }
.at-tools { display: flex; gap: 10px; align-items: center; }
body.at .language-switch { display: flex; border: 1px solid var(--at-line); border-radius: 999px; padding: 3px; background: var(--at-surface); }
body.at .language-switch button { border: 0; background: none; color: var(--at-muted); border-radius: 999px; padding: 4px 11px; font-size: 15px; }
body.at .language-switch button[aria-pressed="true"] { background: var(--at-ink); color: var(--at-bg); }
.at-theme { border: 1px solid var(--at-line); background: var(--at-surface); color: var(--at-ink); border-radius: 999px; padding: 6px 13px; font-size: 15px; white-space: nowrap; }

.at-main { max-width: 1320px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px) 40px; }

/* ── 첫 화면 ── */
.at-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: clamp(24px, 4vw, 56px);
  align-items: center;
  padding: clamp(28px, 5vw, 64px) 0 clamp(24px, 3vw, 36px);
}
.at-eyebrow { margin: 0 0 14px; font-family: var(--f-mono); font-size: 14px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--at-brass); }
.at-hero h1 { margin: 0; font-family: var(--f-display); font-weight: 400; font-size: clamp(52px, 7.4vw, 104px); line-height: 0.92; letter-spacing: -0.02em; text-wrap: balance; }
.at-hero h1 em { display: block; font-style: italic; color: var(--at-brass); }
.at-lede { margin: 22px 0 10px; font-family: var(--f-kr-serif); font-weight: 800; font-size: clamp(20px, 2.3vw, 27px); line-height: 1.4; text-wrap: balance; }
.at-sub { margin: 0; max-width: 52ch; color: var(--at-muted); }
.at-stats { display: flex; gap: clamp(20px, 4vw, 44px); margin: 28px 0 0; padding-top: 20px; border-top: 1px solid var(--at-line); }
.at-stats div { display: grid; gap: 2px; }
.at-stats dt { font-family: var(--f-mono); font-size: 14px; letter-spacing: 0.06em; color: var(--at-muted); }
.at-stats dd { margin: 0; font-family: var(--f-display); font-size: 47px; line-height: 1; font-variant-numeric: tabular-nums; }
.at-hero-fig { margin: 0; background: var(--pl-paper); border: 1px solid var(--at-line); border-radius: 22px; box-shadow: var(--at-shadow); overflow: hidden; }
.at-hero-fig svg { display: block; width: 100%; height: auto; }
.hero-grid line { stroke: var(--pl-grid); stroke-width: 1; }
.hero-ghost { fill: none; stroke: var(--pl-muted); stroke-width: 1.2; stroke-dasharray: 3 7; opacity: 0.6; }
.hero-axis { stroke: var(--pl-axis); stroke-width: 1.2; }
.hero-curve { fill: none; stroke: var(--pl-a); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.hero-string { stroke: var(--at-brass); stroke-width: 2; }
.hero-string.s2 { stroke: var(--pl-b); }
.hero-focus { fill: var(--pl-ink); }
.hero-pen { fill: var(--pl-a); stroke: var(--pl-paper); stroke-width: 3; }
.hero-label { font-family: var(--f-display); font-style: italic; font-size: 22px; fill: var(--pl-ink); text-anchor: middle; }
.at-hero-fig figcaption { display: flex; flex-wrap: wrap; gap: 6px 16px; padding: 12px 18px; border-top: 1px solid var(--at-line); font-family: var(--f-mono); font-size: 15px; color: var(--at-muted); background: var(--at-surface); }
.at-hero-fig figcaption b { color: var(--at-ink); font-weight: 600; font-variant-numeric: tabular-nums; }

/* ── 과정 선로(중1 → 미적분) ── */
.at-rail { margin: 6px 0 30px; }
.at-rail ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 14px 22px; }
.at-rgroup { display: grid; gap: 7px; align-content: start; }
.at-rg-label { font-family: var(--f-mono); font-size: 14px; letter-spacing: 0.08em; color: var(--at-muted); padding-left: 2px; display: flex; align-items: center; gap: 8px; }
.at-rg-label::after { content: ""; flex: 1; min-width: 16px; height: 1px; background: var(--at-line); }
.at-rg-row { display: flex; flex-wrap: wrap; gap: 6px; }
.at-station { position: relative; display: inline-flex; align-items: baseline; gap: 7px; padding: 9px 14px 9px 30px; border-radius: 12px; text-decoration: none; border: 1px solid var(--at-line); background: var(--at-surface); transition: background 0.2s, border-color 0.2s, box-shadow 0.2s; white-space: nowrap; }
.at-station::before { content: ""; position: absolute; top: 50%; left: 12px; width: 10px; height: 10px; margin-top: -5px; border-radius: 50%; background: transparent; border: 2px solid var(--c); }
.at-station b { font-family: var(--f-kr-serif); font-weight: 800; font-size: 17px; line-height: 1.2; }
.at-station small { font-family: var(--f-mono); font-size: 14px; color: var(--at-muted); font-variant-numeric: tabular-nums; }
.at-station:hover { border-color: var(--c); }
.at-station.active { background: color-mix(in srgb, var(--c) 9%, var(--at-surface)); border-color: var(--c); box-shadow: 0 0 0 1px var(--c) inset; }
.at-station.active::before { background: var(--c); }
.at-station.active b, .at-station.active small { color: var(--c); }

/* ── 과정·단원 ── */
.at-course { display: grid; gap: 16px; margin-bottom: 22px; }
.at-course-head .at-eyebrow { color: var(--course); margin-bottom: 4px; }
.at-course-head h2 { margin: 0; font-family: var(--f-kr-serif); font-weight: 800; font-size: clamp(26px, 3vw, 34px); }
.at-units { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 10px; }
.at-unit { display: grid; gap: 2px; padding: 13px 16px; border: 1px solid var(--at-line); border-radius: 14px; background: var(--at-surface); text-decoration: none; transition: border-color 0.2s, background 0.2s; }
.at-unit small { font-family: var(--f-mono); font-size: 14px; color: var(--at-muted); }
.at-unit b { font-weight: 600; }
.at-unit:hover { border-color: var(--course); }
.at-unit.active { border-color: var(--course); background: color-mix(in srgb, var(--course) 10%, var(--at-surface)); }
.at-unit-all b { color: var(--at-muted); }

/* ── 도구줄 ── */
.at-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding: 14px 0; margin-bottom: 8px; border-top: 1px solid var(--at-line); }
.at-search { display: flex; align-items: center; gap: 8px; flex: 1 1 260px; max-width: 420px; padding: 0 14px; border: 1px solid var(--at-line); border-radius: 12px; background: var(--at-surface); color: var(--at-muted); }
.at-search input { flex: 1; min-width: 0; border: 0; background: none; padding: 10px 0; color: var(--at-ink); outline: none; }
.at-filters { display: flex; flex-wrap: wrap; gap: 6px; }
.at-chip { border: 1px solid var(--at-line); background: var(--at-surface); color: var(--at-ink); border-radius: 999px; padding: 6px 13px; font-size: 15px; }
.at-chip:hover { border-color: var(--course); }
.at-chip.active { background: var(--at-ink); color: var(--at-bg); border-color: var(--at-ink); }
.at-count { margin-left: auto; font-family: var(--f-mono); font-size: 14.5px; color: var(--at-muted); }

/* ── 실험 카드 ── */
.at-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(268px, 1fr)); gap: 18px; }
.at-card { position: relative; display: flex; flex-direction: column; background: var(--at-surface); border: 1px solid var(--at-line); border-radius: 18px; overflow: hidden; transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s; }
.at-card:hover { transform: translateY(-3px); box-shadow: var(--at-shadow); border-color: color-mix(in srgb, var(--c) 45%, var(--at-line)); }
.at-thumb { aspect-ratio: 16 / 10.5; max-width: 100%; border-bottom: 1px solid var(--at-line); background: var(--pl-paper); overflow: hidden; }
.at-thumb svg { display: block; width: 100%; height: 100%; transition: transform 0.5s ease; }
.at-card:hover .at-thumb svg { transform: scale(1.035); }
.at-thumb .pl-text, .at-thumb .tick, .at-thumb .axis-name { display: none; }
.at-card-body { display: flex; flex-direction: column; gap: 6px; padding: 14px 16px 16px; flex: 1; }
.at-code { font-family: var(--f-mono); font-size: 14px; letter-spacing: 0.03em; color: var(--c, var(--course)); font-weight: 500; }
.at-card h2 { margin: 0; font-family: var(--f-kr-serif); font-weight: 800; font-size: 19.5px; line-height: 1.35; text-wrap: balance; }
.at-card h2 a { text-decoration: none; }
.at-card h2 a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.at-card p { margin: 0; color: var(--at-muted); font-size: 15.5px; line-height: 1.55; }
.at-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: auto; padding-top: 8px; }
.at-tags span { font-size: 14px; padding: 2px 9px; border-radius: 999px; background: var(--at-surface-2); color: var(--at-muted); border: 1px solid var(--at-line); }
.at-tags .at-time { font-family: var(--f-mono); margin-left: auto; border-color: transparent; background: none; }
.at-fav { position: absolute; top: 10px; right: 10px; z-index: 2; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--at-line); background: color-mix(in srgb, var(--at-surface) 88%, transparent); color: var(--at-brass); font-size: 17.5px; line-height: 1; }
.at-fav[aria-pressed="true"] { background: var(--at-brass); color: var(--at-surface); border-color: var(--at-brass); }
body.at .empty { grid-column: 1 / -1; color: var(--at-muted); padding: 30px 0; }

/* ── 실험 화면 ── */
.at-lab-top { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px 24px; padding: 26px 0 20px; }
.at-lab-title { max-width: 760px; }
.at-back { display: inline-block; font-size: 15.5px; color: var(--at-muted); text-decoration: none; margin-bottom: 10px; }
.at-back:hover { color: var(--at-ink); }
.at-lab-top .at-code { display: block; color: var(--course); margin: 0 0 6px; }
.at-lab-title h1 { margin: 0; font-family: var(--f-kr-serif); font-weight: 800; font-size: clamp(28px, 3.6vw, 42px); line-height: 1.2; text-wrap: balance; }
.at-desc { margin: 10px 0 0; color: var(--at-muted); max-width: 64ch; }
body.at .top-actions { display: flex; flex-wrap: wrap; gap: 8px; }
body.at .btn { border: 1px solid var(--at-line); background: var(--at-surface); color: var(--at-ink); border-radius: 10px; padding: 8px 14px; font-size: 15.5px; font-weight: 500; transition: border-color 0.2s, background 0.2s; }
body.at .btn:hover { border-color: var(--course); }
body.at .btn.primary { background: var(--at-ink); color: var(--at-bg); border-color: var(--at-ink); }
body.at .panel { background: var(--at-surface); border: 1px solid var(--at-line); border-radius: 18px; box-shadow: var(--at-shadow); }
body.at .stage-panel { overflow: hidden; }
body.at .stage-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 14px; padding: 12px 18px; border-bottom: 1px solid var(--at-line); background: var(--at-surface); }
body.at .stage-head strong { font-family: var(--f-mono); font-size: 14.5px; font-weight: 500; letter-spacing: 0.02em; color: var(--course); }
body.at .stage-head span { color: var(--at-muted); font-size: 15px; }
body.at .plot-caption { margin: 0; padding: 10px 18px; font-size: 15.5px; color: var(--at-muted); border-bottom: 1px solid var(--at-line); background: var(--at-surface-2); }
body.at .stage { background: var(--pl-paper); }
body.at .stage.hs-stage { padding: 0; height: auto; aspect-ratio: 640 / 440; max-width: 100%; touch-action: none; user-select: none; }
body.at .stage.hs-stage > svg { display: block; width: 100%; height: 100%; }
body.at .stage.hs-stage-3d { cursor: grab; }
body.at .stage.hs-stage-3d.rotating { cursor: grabbing; }
.hs-svg .pl-text { font-family: var(--f-sans); font-size: 15px; paint-order: stroke; stroke: var(--pl-paper); stroke-width: 4px; stroke-linejoin: round; }
.hs-svg .pl-text.b { font-weight: 700; }
.hs-svg .pl-text.i { font-family: var(--f-display); font-style: italic; font-size: 19px; font-weight: 400; }
.hs-svg .pl-text.m { font-family: var(--f-mono); font-size: 14px; }
.hs-svg .tick { font-family: var(--f-mono); font-size: 11.5px; fill: var(--pl-muted); }
.hs-svg .axis-name { font-family: var(--f-display); font-style: italic; font-size: 20px; fill: var(--pl-muted); }
.hs-svg .pl-hint { font-family: var(--f-mono); font-size: 11.5px; fill: var(--pl-muted); }
.hs-handle { cursor: grab; outline: none; }
.hs-handle .ring { transition: r 0.15s; }
.hs-handle:hover .ring, .hs-handle:focus-visible .ring { r: 14; stroke-width: 3; }
.hs-handle:focus-visible .ring { stroke: var(--at-ink); }
@media (prefers-reduced-motion: no-preference) {
  .hs-handle .ring { animation: at-pulse 2.4s ease-in-out infinite; }
  @keyframes at-pulse { 50% { stroke-opacity: 0.45; } }
}
body.at .metrics { gap: 10px; padding: 14px 16px; background: var(--at-surface); border-top: 1px solid var(--at-line); }
body.at .metrics > div { display: grid; gap: 1px; padding: 9px 13px; border: 1px solid var(--at-line); border-radius: 12px; background: var(--at-surface-2); min-width: 0; }
body.at .metrics small { font-size: 14px; color: var(--at-muted); }
body.at .metrics strong { font-family: var(--f-sans); font-size: 16.5px; font-weight: 600; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
body.at .metrics > .tone-key { border-color: color-mix(in srgb, var(--course) 55%, var(--at-line)); background: color-mix(in srgb, var(--course) 9%, var(--at-surface)); }
body.at .metrics > .tone-key strong { color: var(--course); font-weight: 600; }
body.at .metrics .hs-note { flex-basis: 100%; margin: 0; font-size: 15.5px; color: var(--at-ink); }
body.at .control-panel { padding: 18px 18px 20px; }
body.at .control-panel h2 { margin: 0 0 14px; font-family: var(--f-kr-serif); font-weight: 800; font-size: 19.5px; }
body.at .control-panel h3 { font-size: 15px; font-family: var(--f-mono); color: var(--at-muted); letter-spacing: 0.04em; }
body.at .lab-control > span { font-size: 15.5px; }
body.at .lab-control output { font-family: var(--f-mono); font-variant-numeric: tabular-nums; color: var(--course); font-weight: 500; }
body.at .lab-control input[type="range"] { accent-color: var(--course); width: 100%; }
body.at .lab-control select { width: 100%; padding: 8px 10px; border-radius: 10px; border: 1px solid var(--at-line); background: var(--at-surface); color: var(--at-ink); }
body.at .lab-check { display: flex; gap: 8px; align-items: flex-start; font-size: 15.5px; margin-bottom: 14px; }
body.at .lab-check input { accent-color: var(--course); margin-top: 4px; }
.hs-seg { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; padding: 3px; border-radius: 12px; background: var(--at-surface-2); border: 1px solid var(--at-line); }
.hs-seg button { flex: 1 1 auto; border: 0; background: none; color: var(--at-muted); border-radius: 9px; padding: 6px 10px; font-size: 15px; }
.hs-seg button[aria-pressed="true"] { background: var(--at-surface); color: var(--at-ink); box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12); font-weight: 600; }
.hs-actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 12px; }
.hs-tip { margin: 10px 0 0; font-size: 14.5px; color: var(--at-muted); line-height: 1.5; }
body.at .info-grid { gap: 16px; margin-top: 18px; }
body.at .info-card { padding: 18px 20px; }
body.at .info-card h2 { margin: 0 0 10px; font-family: var(--f-kr-serif); font-weight: 800; font-size: 18.5px; }
body.at .info-card li, body.at .info-card p { color: var(--at-ink); font-size: 16px; }
body.at .formula { display: block; font-family: var(--f-mono); font-size: 16px; line-height: 1.7; padding: 12px 14px; border-radius: 12px; background: var(--at-surface-2); border: 1px solid var(--at-line); color: var(--at-ink); overflow-wrap: anywhere; }
body.at .lesson-guide h2 { margin-top: 16px; font-size: 16.5px; }
body.at .lesson-guide p { color: var(--at-muted); font-size: 15.5px; }
.at-links { display: grid; gap: 18px; margin-top: 22px; padding: 20px; border: 1px dashed var(--at-line); border-radius: 18px; }
.at-links h2 { margin: 0 0 10px; font-family: var(--f-mono); font-size: 14px; letter-spacing: 0.06em; font-weight: 500; color: var(--at-muted); }
.at-link-row { display: flex; flex-wrap: wrap; gap: 10px; }
.at-link-chip { display: grid; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--at-line); background: var(--at-surface); text-decoration: none; min-width: 180px; transition: border-color 0.2s, transform 0.2s; }
.at-link-chip:hover { border-color: var(--c); transform: translateY(-1px); }
.at-link-chip small { font-family: var(--f-mono); font-size: 14px; color: var(--c); }
.at-link-chip b { font-weight: 600; font-size: 16px; }

/* ── 바닥글·알림·그림 저장 ── */
.at-footer { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 20px 40px; margin-top: 56px; padding-top: 22px; border-top: 1px solid var(--at-line); font-size: 15px; color: var(--at-muted); }
.at-footer strong { color: var(--at-ink); }
.at-footer p { margin: 4px 0; }
body.at #lab-status:empty { display: none; }
body.at #lab-status { position: fixed; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); z-index: 40; background: var(--at-ink); color: var(--at-bg); padding: 9px 16px; border-radius: 999px; font-size: 15.5px; box-shadow: var(--at-shadow); max-width: calc(100vw - 32px); }
.at-shot { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 20px; background: rgba(8, 14, 16, 0.72); backdrop-filter: blur(6px); }
.at-shot figure { margin: 0; display: grid; gap: 10px; justify-items: center; max-width: min(1000px, 100%); }
.at-shot img { max-width: 100%; max-height: 72vh; border-radius: 14px; background: var(--at-surface); }
.at-shot figcaption { color: #e9f0ef; font-size: 16px; text-align: center; }

body.at.presentation .at-header, body.at.presentation .at-footer, body.at.presentation .at-links, body.at.presentation .info-grid, body.at.presentation .at-back { display: none; }

@media (max-width: 960px) {
  .at-hero { grid-template-columns: 1fr; }
  .at-hero-fig { max-width: 640px; }
  body.at .lab-layout { grid-template-columns: 1fr; }
  .at-footer { grid-template-columns: 1fr; }
}
@media (max-width: 620px) {
  .at-nav { display: none; }
  .at-header-inner { gap: 10px; }
  .at-word em { font-size: 20.5px; }
  .at-word { font-size: 16.5px; }
  .at-theme { padding: 6px 10px; }
  .at-stats dd { font-size: 37px; }
  .at-count { margin-left: 0; }
  body.at .info-grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .at-card, .at-thumb svg, .at-station, .at-link-chip { transition: none; }
}

/* 한국어 어절 단위 줄바꿈 — 단어 중간에서 끊기지 않게 */
body.at, body.at * { word-break: keep-all; overflow-wrap: break-word; line-break: strict; }
body.at h1, body.at h2, body.at h3, body.at .at-lede { text-wrap: balance; }
body.at p, body.at li, body.at .at-desc, body.at .at-card p { text-wrap: pretty; }
body.at .metrics strong, body.at .formula, body.at .metrics > div, body.at .metrics p { overflow-wrap: break-word; word-break: keep-all; }

/* ── 수식(MathJax) ── */
.mx { display: inline-block; vertical-align: middle; line-height: 0; }
.mx svg { vertical-align: middle; max-width: 100%; }
.mx mjx-container, .mx > mjx-container { margin: 0 !important; }
body.at .formula { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; font-family: var(--f-sans); padding: 14px 16px; overflow-x: auto; }
body.at .formula .mx-d { font-size: 1.12em; }
body.at .metrics strong .mx { font-size: 1.05em; }
body.at .lab-control output .mx { font-size: 0.95em; }
body.at .hs-note .mx, body.at .info-card .mx, body.at .at-desc .mx { font-size: 1.02em; margin: 0 1px; }

/* ── 목록·사이트맵 머리 ── */
.at-page-head { padding: 34px 0 10px; display: grid; gap: 8px; }
.at-page-head h1 { margin: 0; font-family: var(--f-kr-serif); font-weight: 800; font-size: clamp(30px, 4vw, 44px); }
.at-page-head .at-eyebrow { margin: 0; }
.at-hero-cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
body.at .at-hero-cta .btn { text-decoration: none; padding: 10px 18px; font-size: 16.5px; }
.at-search-wide { max-width: 520px; margin-top: 8px; }
.at-map { columns: 3 300px; column-gap: 28px; margin-top: 18px; }
.at-map-course { break-inside: avoid; margin: 0 0 26px; padding: 16px 18px 12px; border: 1px solid var(--at-line); border-radius: 16px; background: var(--at-surface); border-top: 4px solid var(--c); }
.at-map-course h2 { margin: 0 0 6px; display: flex; align-items: baseline; justify-content: space-between; gap: 10px; font-family: var(--f-kr-serif); font-weight: 800; font-size: 21.5px; }
.at-map-course h2 a { text-decoration: none; color: var(--c); }
.at-map-course h2 small { font-family: var(--f-mono); font-size: 14px; color: var(--at-muted); font-weight: 400; }
.at-map-course h3 { margin: 14px 0 6px; font-size: 14.5px; font-family: var(--f-mono); letter-spacing: 0.02em; color: var(--at-muted); font-weight: 500; }
.at-map-course ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.at-map-course li a { display: flex; gap: 10px; align-items: baseline; padding: 5px 8px; border-radius: 8px; text-decoration: none; font-size: 16px; }
.at-map-course li a:hover { background: color-mix(in srgb, var(--c) 10%, var(--at-surface)); }
.at-map-code { flex: none; min-width: 58px; font-family: var(--f-mono); font-size: 14px; color: var(--c); }
.at-nav a[aria-current="page"] { color: var(--at-ink); font-weight: 600; text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 2px; text-decoration-color: var(--at-brass); }

/* ── 실험 화면 보강 ── */
.at-crumbs { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: baseline; margin-bottom: 8px; }
.at-crumbs .at-back { margin: 0; }
.at-crumbs span { font-size: 15px; color: var(--at-muted); }
.at-lab-nav { display: grid; grid-template-columns: 1fr auto 1fr; gap: 12px; align-items: stretch; margin-top: 22px; }
.at-lab-nav a { display: grid; gap: 2px; padding: 14px 18px; border: 1px solid var(--at-line); border-radius: 14px; background: var(--at-surface); text-decoration: none; transition: border-color 0.2s, transform 0.2s; }
.at-lab-nav a:hover { border-color: var(--course); transform: translateY(-1px); }
.at-lab-nav small { font-family: var(--f-mono); font-size: 14px; color: var(--course); }
.at-lab-nav b { font-weight: 600; font-size: 16.5px; }
.at-lab-nav-next { text-align: right; }
.at-lab-nav-pos { align-self: center; font-family: var(--f-mono); font-size: 14px; color: var(--at-muted); }
body.at .control-panel { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 76px); align-self: start; max-height: calc(100vh - 96px); overflow-y: auto; }
@media (max-width: 960px) { body.at .control-panel { position: static; max-height: none; } }
@media (max-width: 620px) {
  .at-nav { display: flex !important; gap: 12px; margin-left: 0; order: 3; width: 100%; }
  .at-header-inner { flex-wrap: wrap; row-gap: 6px; }
  .at-lab-nav { grid-template-columns: 1fr 1fr; }
  .at-lab-nav-pos { display: none; }
  .at-map { columns: 1; }
}
mjx-assistive-mml { display: none !important; }

/* ── 전체 실험 찾기 ── */
.at-find { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 10px 0 12px; border: 1px solid var(--at-line); border-radius: 999px; background: var(--at-surface); color: var(--at-muted); font: inherit; font-size: 15.5px; cursor: pointer; transition: border-color 0.2s, color 0.2s; }
.at-find:hover { border-color: var(--at-ink); color: var(--at-ink); }
.at-find kbd, .at-finder kbd { font-family: var(--f-mono); font-size: 13.5px; padding: 2px 6px; border: 1px solid var(--at-line); border-radius: 6px; background: var(--at-bg); color: var(--at-muted); }
.at-finder { position: fixed; inset: 0; z-index: 90; display: grid; justify-items: center; align-items: start; padding: max(9vh, 24px) 16px 16px; background: color-mix(in srgb, var(--at-ink) 38%, transparent); backdrop-filter: blur(3px); }
.at-finder-box { width: min(680px, 100%); max-height: min(72vh, 640px); display: grid; grid-template-rows: auto 1fr auto; border-radius: 18px; background: var(--at-surface); border: 1px solid var(--at-line); box-shadow: 0 30px 80px -20px rgba(0,0,0,0.45); overflow: hidden; }
.at-finder-in { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--at-line); font-size: 19.5px; color: var(--at-muted); }
.at-finder-in input { flex: 1; min-width: 0; border: 0 !important; outline: 0 !important; box-shadow: none !important; padding: 4px 0 !important; background: transparent !important; -webkit-appearance: none; appearance: none; font: inherit; font-size: 18px; color: var(--at-ink); }
.at-finder-list { list-style: none; margin: 0; padding: 6px; overflow-y: auto; }
.at-finder-list li[data-i] { display: grid; grid-template-columns: 92px 1fr auto; align-items: baseline; gap: 12px; padding: 10px 12px; border-radius: 10px; cursor: pointer; }
.at-finder-list li[aria-selected="true"] { background: color-mix(in srgb, var(--c) 10%, var(--at-surface)); box-shadow: inset 3px 0 0 var(--c); }
.at-finder-c { font-family: var(--f-mono); font-size: 14px; color: var(--c); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.at-finder-t { font-weight: 600; color: var(--at-ink); }
.at-finder-u { font-size: 14px; color: var(--at-muted); white-space: nowrap; }
.at-finder-empty { padding: 22px 16px; color: var(--at-muted); font-size: 16px; line-height: 1.6; }
.at-finder-foot { display: flex; gap: 16px; margin: 0; padding: 9px 18px; border-top: 1px solid var(--at-line); font-family: var(--f-mono); font-size: 14px; color: var(--at-muted); background: var(--at-bg); }
@media (max-width: 720px) { .at-find-t, .at-find kbd { display: none; } .at-find { padding: 0 11px; } .at-finder-list li[data-i] { grid-template-columns: 1fr; gap: 2px; } .at-finder-u { white-space: normal; } .at-finder-foot { display: none; } }

/* ── 수업 흐름 ── */
.lesson-guide h2 small { font-family: var(--f-mono); font-size: 14px; font-weight: 500; color: var(--at-muted); margin-left: 6px; }
.at-flow { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 10px; counter-reset: flow; }
.at-flow li { position: relative; display: grid; gap: 2px; padding-left: 34px; counter-increment: flow; }
.at-flow li::before { content: counter(flow); position: absolute; left: 0; top: 0; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-family: var(--f-mono); font-size: 14px; font-weight: 600; color: var(--at-bg); background: var(--course, var(--at-ink)); }
.at-flow li:not(:last-child)::after { content: ""; position: absolute; left: 10.5px; top: 25px; bottom: -9px; width: 1px; background: var(--at-line); }
.at-flow span { font-family: var(--f-mono); font-size: 14px; letter-spacing: 0.04em; color: var(--course, var(--at-muted)); font-weight: 600; }
.at-flow p { margin: 0; font-size: 16px; line-height: 1.6; color: var(--at-ink); }

/* ── 설명 카드: 왼쪽에 관찰·질문, 오른쪽에 개념·수업 흐름 ── */
@media (min-width: 621px) {
  body.at .info-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-rows: auto 1fr; align-items: stretch; }
  body.at .info-grid > .info-card:nth-child(1) { grid-column: 1; grid-row: 1; }
  body.at .info-grid > .info-card:nth-child(2) { grid-column: 1; grid-row: 2; }
  body.at .info-grid > .info-card:nth-child(3) { grid-column: 2; grid-row: 1 / span 2; }
}
body.at .info-card:nth-child(2) p { font-size: 17.5px; line-height: 1.65; color: var(--at-ink); }
body.at .formula .mx-part { font-size: 15px; color: var(--at-ink); }
body.at .formula .mx-part .mx { font-size: 1.12em; margin: 0 2px; }

/* 예측하고 확인하기 */
.hs-pred { margin: 16px 0 4px; padding: 14px 14px 12px; border: 1px solid var(--at-line); border-radius: 14px; background: var(--at-surface-2, var(--at-surface)); }
.hs-pred h3 { margin: 0 0 8px; font-size: 16px; display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.hs-pred h3 small { font-family: var(--f-mono); font-size: 14px; color: var(--at-muted); font-weight: 500; }
.hs-pred-q { margin: 0 0 10px; line-height: 1.6; font-size: 16px; }
.hs-pred-row { display: flex; gap: 8px; align-items: stretch; flex-wrap: wrap; margin-top: 8px; }
.hs-pred-in { flex: 1 1 120px; min-width: 0; padding: 8px 10px; border: 1px solid var(--at-line); border-radius: 10px; background: var(--at-surface); color: var(--at-ink); font: inherit; font-size: 16.5px; }
.hs-pred-opts { flex: 1 1 100%; flex-wrap: wrap; }
.hs-pred-opts button { flex: 1 1 45%; }
.hs-pred-res { margin-top: 10px; padding: 10px 12px; border-radius: 10px; font-size: 15.5px; line-height: 1.55; }
.hs-pred-res.ok { background: color-mix(in srgb, var(--pl-c) 14%, transparent); }
.hs-pred-res.no { background: color-mix(in srgb, var(--pl-d) 14%, transparent); }
.hs-pred-res p { margin: 6px 0 0; color: var(--at-ink); }
.hs-pred-nav { display: flex; justify-content: space-between; gap: 8px; margin-top: 10px; }
.hs-pred-nav .btn[disabled] { opacity: .4; pointer-events: none; }

/* 학습지 */
.at-sheet-n:not(:empty) { display: inline-grid; place-items: center; min-width: 18px; height: 18px; margin-left: 5px; padding: 0 5px; border-radius: 9px; background: var(--at-brass); color: #fff; font-size: 14px; font-family: var(--f-mono); vertical-align: 1px; }
.sh-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 0 18px; }
.sh-bar .hs-seg { min-width: 260px; }
.sh-gap { flex: 1; }
.sh-empty { padding: 48px 20px; text-align: center; border: 1px dashed var(--at-line); border-radius: 18px; color: var(--at-muted); }
.sh-paper { --ink: #1f2a2e; --line: #d9d2c1; --soft: #6b6458; background: #fbf8f1; background-image: radial-gradient(circle at 100% 0, rgba(201,162,95,.10), transparent 40%), radial-gradient(circle at 0 100%, rgba(96,150,140,.08), transparent 45%); color: var(--ink); border-radius: 10px; box-shadow: 0 12px 40px rgba(60,48,20,.14); padding: 40px 46px; max-width: 860px; margin: 0 auto 40px; font-size: 14.5px; line-height: 1.65; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
.sh-paper .mx svg { color: var(--ink); }
.sh-paper-head { position: relative; margin: -40px -46px 26px; padding: 30px 46px 18px; border-radius: 10px 10px 0 0; background: linear-gradient(120deg, #f1e6cc 0%, #f6efe0 45%, #e3eee9 100%); border-bottom: 2px solid #c9a25f; }
.sh-title { font-family: var(--f-kr-serif, serif); font-size: 27px; margin: 0 0 12px; outline: none; color: #2b2416; }
.sh-title:focus { background: rgba(255,255,255,.6); }
.sh-badge { position: absolute; right: 46px; top: 30px; margin: 0; padding: 3px 12px; background: #fff3f1; border: 1.5px solid #b23a48; color: #b23a48; border-radius: 999px; font-weight: 700; font-size: 13px; }
.sh-name { display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: flex-end; font-size: 13.5px; color: var(--soft); }
.sh-name i { display: inline-block; width: 120px; border-bottom: 1px solid #8f7a52; height: 18px; }
.sh-name i.s { width: 44px; }
.sh-item { --c: #9a7a3c; padding: 0 0 18px; margin-bottom: 26px; }
.sh-item-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 12px; background: var(--ct, #efe7d4); border-left: 5px solid var(--c); }
.sh-item h2 { font-size: 18.5px; margin: 0; display: flex; gap: 10px; align-items: center; }
.sh-no { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--c); color: #fff; font-size: 14px; flex: none; }
.sh-tools { display: flex; gap: 4px; flex: none; }
.sh-tools button, .sh-tools a { border: 1px solid var(--line); background: rgba(255,255,255,.75); color: var(--ink); border-radius: 7px; padding: 3px 8px; font-size: 12px; cursor: pointer; text-decoration: none; }
.sh-tools button[disabled] { opacity: .35; pointer-events: none; }
.sh-meta { margin: 6px 0 12px 19px; color: var(--soft); font-size: 12.5px; }
.sh-goal, .sh-formula { display: grid; grid-template-columns: 78px 1fr; gap: 10px; margin: 0 0 8px; padding: 10px 14px; border-radius: 10px; }
.sh-goal { background: #ecf3f7; }
.sh-formula { background: #faf1de; align-items: center; }
.sh-goal b, .sh-formula b { font-size: 12.5px; color: var(--soft); padding-top: 2px; }
.sh-goal p { margin: 0; }
.sh-fig { margin: 14px auto 14px; text-align: center; }
.sh-fig img { max-width: 100%; height: auto; max-height: 380px; background: #fff; border: 1px solid #e6dfcf; border-radius: 12px; box-shadow: 0 4px 14px rgba(60,48,20,.08); }
.sh-block { margin-top: 12px; padding: 12px 16px 14px; border-radius: 12px; background: #f4f6ef; }
.sh-block.k-table { background: #f6f3ec; }
.sh-block.k-pred { background: #f3f0f9; }
.sh-block.k-obs { background: #ebf5f1; }
.sh-block.k-think { background: #fcf0ec; }
.sh-block h3 { font-size: 14.5px; margin: 0 0 8px; padding-left: 0; border: 0; display: flex; align-items: center; gap: 8px; color: #3a3428; }
.sh-block h3::before { content: ""; width: 9px; height: 9px; border-radius: 3px; background: var(--c); }
.sh-block ol, .sh-block ul { margin: 0; padding-left: 22px; }
.sh-block li { margin: 3px 0; }
.sh-table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13px; background: #fff; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.sh-table th, .sh-table td { border-bottom: 1px solid #ece6d8; border-right: 1px solid #ece6d8; padding: 6px 9px; text-align: left; vertical-align: middle; }
.sh-table tr > :last-child { border-right: 0; }
.sh-table tbody tr:last-child > * { border-bottom: 0; }
.sh-table thead th { background: var(--ch, #f2ede2); font-size: 12px; }
.sh-table tbody th { background: #faf8f3; }
.sh-table td:nth-child(3), .sh-table td:nth-child(4) { width: 22%; }
.sh-pred > li { margin-bottom: 8px; padding: 8px 10px; background: rgba(255,255,255,.7); border-radius: 8px; }
.sh-pred p { margin: 0 0 4px; }
.sh-opts { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 13px; }
.sh-pq { display: grid; grid-template-columns: auto 1fr auto 1fr; gap: 8px; align-items: end; font-size: 12.5px; color: var(--soft); }
.sh-line { border-bottom: 1px solid #8f7a52; height: 20px; }
.sh-blank { display: inline-block; min-width: 92px; border-bottom: 1.4px solid #6f5b33; background: rgba(255,255,255,.75); height: 1.25em; vertical-align: -3px; margin: 0 3px; border-radius: 3px 3px 0 0; }
.sh-ans { color: #b23a48; font-weight: 700; border-bottom: 1.4px solid #b23a48; padding: 0 3px; margin: 0 2px; background: rgba(255,255,255,.75); }
.sh-ans .mx svg { color: #b23a48; }
.sh-check { color: var(--soft); }
.sh-key { margin: 6px 0 0; padding: 6px 10px; background: #fff3f1; border: 1px dashed #e3a9b1; border-radius: 6px; color: #7d2633; font-size: 13px; }
.sh-write { height: 92px; margin-top: 8px; border-radius: 6px; background: rgba(255,255,255,.7) repeating-linear-gradient(transparent 0 29px, #e2cfc6 29px 30px); }
.sh-ctl { font-weight: 700; color: #3a3428; }
.sh-foot { margin-top: 10px; text-align: right; font-size: 11px; color: #8a7f6c; }
@media (max-width: 640px) { .sh-paper { padding: 24px 18px; } .sh-goal, .sh-formula { grid-template-columns: 1fr; gap: 2px; } .sh-meta { margin-left: 0; } .sh-item-head { flex-direction: column; align-items: flex-start; } .sh-paper-head { margin: -24px -18px 20px; padding: 22px 18px 14px; } .sh-badge { right: 18px; top: 22px; } }
@media print {
  .at-header, .at-footer, .sh-head, .sh-bar, .sh-tools, #lab-status, .skip { display: none !important; }
  body, .at-main { background: #fff !important; }
  .sh-paper { box-shadow: none; padding: 0; max-width: none; background-image: none; }
  .sh-paper-head { margin: 0 0 20px; padding: 18px 20px 14px; border-radius: 10px; }
  .sh-badge { right: 20px; top: 18px; }
  .sh-item { break-inside: auto; }
  .sh-fig, .sh-table, .sh-pred > li { break-inside: avoid; }
}

.sh-exporting .sh-tools { display: none !important; }
.sh-dl { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.sh-dl .btn[aria-busy="true"] { opacity: .6; pointer-events: none; }
.sh-tools button[data-sh="ai"] { border-color: #d8c59a; background: #fff8e8; color: #6b4f16; }
.sh-tools button[data-sh="ai"][disabled] { opacity: .6; pointer-events: none; }
.sh-block.k-ai { background: #fff6e3; }
.sh-block.k-ai h3 small { font-weight: 500; color: var(--soft); }
.sh-msg { flex-basis: 100%; margin: 0; font-size: 13px; color: var(--at-muted); }

.sh-unit { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 13px; }
.sh-unit select { min-width: 0; flex: 0 1 360px; padding: 7px 10px; border: 1px solid var(--at-line); border-radius: 10px; background: var(--at-surface); color: var(--at-ink); font: inherit; }

.at-pred-panel { margin: 18px 0 0; padding: 4px 18px 12px; }
.at-pred-panel .hs-pred { margin: 12px 0 0; }

/* ═══════════ 청사진 리디자인 (22차) — 제도판·청사진·황동 자 ═══════════ */
:root,
:root[data-theme="light"] {
  --at-bg: #eef2f7;
  --at-surface: #ffffff;
  --at-surface-2: #f4f7fb;
  --at-ink: #13233f;
  --at-muted: #5a6880;
  --at-line: #d5deea;
  --at-brass: #b07a2a;
  --at-shadow: 0 1px 0 rgba(19, 35, 63, 0.04), 0 14px 30px -22px rgba(19, 35, 63, 0.45);
  --bp: #123a6b;
  --bp-deep: #0d2c53;
  --bp-ink: #eaf1fb;
  --bp-dim: #9fb6d6;
  --bp-grid: rgba(234, 241, 251, 0.09);
  --bp-grid-strong: rgba(234, 241, 251, 0.18);
  --brass-light: #e3b768;
  --pencil: #d64534;
  --pl-paper: #ffffff;
  --pl-grid: #e4eaf2;
  --f-cond: "Barlow Condensed", "IBM Plex Sans KR", "Arial Narrow", sans-serif;
  --f-display: "Barlow Condensed", "IBM Plex Sans KR", sans-serif;
  --f-kr-serif: "IBM Plex Sans KR", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  --r: 8px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --at-bg: #0a1424; --at-surface: #0f1d34; --at-surface-2: #13243f; --at-ink: #e6edf7; --at-muted: #93a3bd; --at-line: #23385a; --at-brass: #e0b064;
    --bp: #0b2244; --bp-deep: #081a35; --pl-paper: #0f1d34; --pl-grid: #1a2c4a;
  }
}
:root[data-theme="dark"] {
  --at-bg: #0a1424; --at-surface: #0f1d34; --at-surface-2: #13243f; --at-ink: #e6edf7; --at-muted: #93a3bd; --at-line: #23385a; --at-brass: #e0b064;
  --bp: #0b2244; --bp-deep: #081a35; --pl-paper: #0f1d34; --pl-grid: #1a2c4a;
}
/* 바탕: 제도판 위의 아주 옅은 모눈 */
body.at { background-color: var(--at-bg); background-image: linear-gradient(var(--at-line) 1px, transparent 1px), linear-gradient(90deg, var(--at-line) 1px, transparent 1px); background-size: 48px 48px; background-position: -1px -1px; background-attachment: fixed; }
body.at::before { content: ""; position: fixed; inset: 0; z-index: -1; background: color-mix(in srgb, var(--at-bg) 78%, transparent); pointer-events: none; }

/* ── 머리글: 청사진 띠 + 아래쪽 자 눈금 ── */
.at-header { background: var(--bp); backdrop-filter: none; border-bottom: 0; color: var(--bp-ink); box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25); }
.at-header::after { content: ""; position: absolute; left: 0; right: 0; bottom: -6px; height: 6px; pointer-events: none;
  background: repeating-linear-gradient(90deg, var(--brass-light) 0 1px, transparent 1px 8px) bottom / 100% 4px no-repeat, repeating-linear-gradient(90deg, var(--brass-light) 0 1px, transparent 1px 40px) bottom / 100% 6px no-repeat; opacity: 0.85; }
.at-header-inner { padding-top: 11px; padding-bottom: 11px; }
.at-brand { color: var(--bp-ink); }
.at-mark rect { fill: var(--bp-ink); }
.at-mark ellipse { stroke: var(--bp); }
.at-word { font-family: var(--f-cond); font-weight: 700; font-size: 22.5px; letter-spacing: 0.01em; }
.at-word em { font-family: var(--f-cond); font-style: normal; font-weight: 500; font-size: 22.5px; color: var(--brass-light); margin-left: 4px; }
.at-nav a { color: var(--bp-dim); font-size: 16.5px; padding: 6px 2px; border-bottom: 2px solid transparent; }
.at-nav a:hover { color: var(--bp-ink); }
.at-nav a[aria-current="page"] { color: var(--bp-ink); border-bottom-color: var(--brass-light); text-decoration: none; }
.at-header .at-find, .at-header .at-theme, body.at .at-header .language-switch { background: rgba(234, 241, 251, 0.08); border-color: rgba(234, 241, 251, 0.22); color: var(--bp-ink); }
body.at .at-header .language-switch button { color: var(--bp-dim); }
body.at .at-header .language-switch button[aria-pressed="true"] { background: var(--bp-ink); color: var(--bp); }
.at-header .at-find kbd { background: rgba(234, 241, 251, 0.12); color: var(--bp-dim); border-color: transparent; }
.at-sheet-n:not(:empty) { background: var(--brass-light); color: var(--bp-deep); }
.at-menu { display: none; }

/* ── 첫 화면: 청사진 도면 ── */
.at-hero { position: relative; isolation: isolate; color: var(--bp-ink); padding: clamp(36px, 6vw, 76px) 0 clamp(40px, 5vw, 64px); margin-bottom: 34px; }
.at-hero::before { content: ""; position: absolute; z-index: -1; top: 0; bottom: 0; left: calc(50% - 50vw); right: calc(50% - 50vw);
  background-color: var(--bp); background-image: linear-gradient(var(--bp-grid-strong) 1px, transparent 1px), linear-gradient(90deg, var(--bp-grid-strong) 1px, transparent 1px), linear-gradient(var(--bp-grid) 1px, transparent 1px), linear-gradient(90deg, var(--bp-grid) 1px, transparent 1px);
  background-size: 120px 120px, 120px 120px, 24px 24px, 24px 24px; background-position: -1px -1px; }
.at-hero::after { content: ""; position: absolute; z-index: -1; bottom: 0; left: calc(50% - 50vw); right: calc(50% - 50vw); height: 10px;
  background: repeating-linear-gradient(90deg, var(--brass-light) 0 1px, transparent 1px 12px) bottom / 100% 5px no-repeat, repeating-linear-gradient(90deg, var(--brass-light) 0 2px, transparent 2px 120px) bottom / 100% 10px no-repeat; opacity: 0.7; }
.at-hero .at-eyebrow { color: var(--brass-light); text-transform: none; letter-spacing: 0.02em; font-family: var(--f-sans); font-size: 15.5px; font-weight: 500; }
.at-hero h1 { font-family: var(--f-cond); font-weight: 700; font-size: clamp(60px, 9vw, 128px); line-height: 0.86; letter-spacing: -0.01em; text-transform: none; }
.at-hero h1 em { font-style: normal; font-weight: 500; color: var(--brass-light); }
.at-lede { font-family: var(--f-sans); font-weight: 600; color: var(--bp-ink); }
.at-sub { color: var(--bp-dim); }
.at-stats { border-top: 1px solid var(--bp-grid-strong); }
.at-stats dt { color: var(--bp-dim); font-family: var(--f-sans); letter-spacing: 0; font-size: 14.5px; }
.at-stats dd { font-family: var(--f-cond); font-weight: 600; font-size: 55px; color: var(--bp-ink); }
.at-hero .btn { background: transparent; color: var(--bp-ink); border-color: rgba(234, 241, 251, 0.35); }
.at-hero .btn:hover { border-color: var(--brass-light); }
.at-hero .btn.primary { background: var(--brass-light); color: var(--bp-deep); border-color: var(--brass-light); font-weight: 600; }
/* 작도 그림: 청사진 위 흰 선 */
.at-hero-fig { background: transparent; border: 1.5px solid var(--bp-grid-strong); border-radius: 4px; box-shadow: none;
  --pl-paper: var(--bp); --pl-ink: var(--bp-ink); --pl-muted: var(--bp-dim); --pl-grid: rgba(234, 241, 251, 0.07); --pl-axis: var(--bp-dim); --pl-a: #ffffff; --pl-b: #8fc2ff; }
.hero-curve { stroke-width: 3; }
.hero-string { stroke: var(--brass-light); }
.hero-label { font-family: var(--f-cond); font-style: normal; font-weight: 600; }
/* 표제란 */
.at-titleblock { padding: 0; border-top: 1.5px solid var(--bp-grid-strong); background: transparent; font-family: var(--f-sans); }
.at-titleblock dl { margin: 0; display: grid; grid-template-columns: 1fr 1fr 0.55fr 0.55fr; }
.at-titleblock dl > div { padding: 8px 12px; border-left: 1px solid var(--bp-grid-strong); min-width: 0; }
.at-titleblock dl > div:first-child { border-left: 0; }
.at-titleblock dt { font-size: 13.5px; color: var(--bp-dim); }
.at-titleblock dd { margin: 2px 0 0; font-size: 15.5px; color: var(--bp-ink); font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.at-titleblock dd b { color: var(--brass-light); font-weight: 600; }

/* ── 이어서 하기 / 즐겨찾기 ── */
.at-resume-wrap { display: grid; gap: 18px; margin: 0 0 34px; }
.at-resume-row h2 { margin: 0 0 10px; font-size: 16.5px; font-weight: 600; color: var(--at-ink); }
.at-resume-list { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x mandatory; }
.at-resume { flex: 0 0 auto; width: 248px; scroll-snap-align: start; display: grid; grid-template-columns: 72px 1fr; gap: 10px; align-items: center; padding: 8px 12px 8px 8px; background: var(--at-surface); border: 1px solid var(--at-line); border-left: 3px solid var(--c); border-radius: var(--r); text-decoration: none; color: var(--at-ink); }
.at-resume:hover { border-color: var(--at-ink); border-left-color: var(--c); }
.at-resume-thumb { display: block; width: 72px; height: 50px; background: var(--pl-paper); border-radius: 4px; overflow: hidden; }
.at-resume-thumb svg { width: 100%; height: 100%; display: block; }
.at-resume small { display: block; font-size: 14px; color: var(--at-muted); }
.at-resume b { display: block; font-size: 15.5px; font-weight: 600; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ── 과정 지도: 자 위의 눈금 ── */
.at-rail { margin: 0 0 30px; padding: 18px 20px 16px; background: var(--at-surface); border: 1px solid var(--at-line); border-radius: var(--r); }
.at-rail ol { gap: 16px 28px; }
.at-rg-label { font-family: var(--f-sans); font-size: 14px; letter-spacing: 0; color: var(--at-muted); }
.at-rg-label::after { background: repeating-linear-gradient(90deg, var(--at-line) 0 1px, transparent 1px 6px); height: 6px; }
.at-station { border-radius: 4px; padding: 7px 12px 7px 26px; background: transparent; border-color: transparent; }
.at-station:hover { border-color: var(--at-line); background: var(--at-surface-2); }
.at-station::before { left: 10px; width: 9px; height: 9px; margin-top: -4.5px; border-radius: 2px; transform: rotate(45deg); }
.at-station b { font-family: var(--f-sans); font-weight: 600; font-size: 16.5px; }
.at-station.active { background: var(--at-ink); border-color: var(--at-ink); color: var(--at-surface); }
.at-station.active::before { background: var(--c); border-color: var(--c); }
.at-station.active small { color: color-mix(in srgb, var(--at-surface) 70%, transparent); }

/* ── 과정 머리 / 단원 ── */
.at-course-head .at-eyebrow, .at-page-head .at-eyebrow { color: var(--at-brass); text-transform: none; letter-spacing: 0; font-family: var(--f-sans); font-size: 15px; font-weight: 500; }
.at-course-head h2, .at-page-head h1 { font-family: var(--f-sans); font-weight: 700; letter-spacing: -0.02em; }
.at-unit { border-radius: var(--r); border-top: 3px solid var(--course, var(--at-ink)); }
.at-unit b { font-family: var(--f-sans); font-weight: 600; }
.at-unit.active { background: var(--at-ink); color: var(--at-surface); }
.at-ugroup { grid-column: 1 / -1; display: flex; align-items: baseline; gap: 10px; margin: 18px 0 2px; padding-bottom: 8px; font-size: 19.5px; font-weight: 700; color: var(--at-ink); border-bottom: 1px solid var(--at-line); position: relative; }
.at-ugroup:first-child { margin-top: 0; }
.at-ugroup::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 5px; background: repeating-linear-gradient(90deg, var(--at-line) 0 1px, transparent 1px 10px) bottom / 100% 5px no-repeat; }
.at-ugroup span { font-family: var(--f-cond); font-weight: 600; font-size: 18.5px; color: var(--course, var(--at-brass)); }
.at-ugroup small { margin-left: auto; font-size: 14.5px; font-weight: 500; color: var(--at-muted); }

/* ── 실험 카드: 제도지 한 장 ── */
.at-card { border-radius: var(--r); border-color: var(--at-line); overflow: hidden; transition: border-color 0.15s; }
.at-card::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: var(--c); z-index: 2; }
.at-card:hover { transform: none; box-shadow: none; border-color: var(--at-ink); }
.at-card:hover .at-thumb svg { transform: none; }
.at-thumb { background-color: var(--pl-paper); background-image: linear-gradient(var(--pl-grid) 1px, transparent 1px), linear-gradient(90deg, var(--pl-grid) 1px, transparent 1px); background-size: 16px 16px; border-bottom: 1px solid var(--at-line); }
.at-card h2 { font-family: var(--f-sans); font-weight: 650; font-size: 18px; letter-spacing: -0.015em; }
.at-card:hover h2 a { text-decoration: underline; text-decoration-color: var(--c); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.at-more { display: grid; align-content: center; justify-items: start; gap: 6px; padding: 22px; border: 1.5px dashed var(--at-line); border-radius: var(--r); text-decoration: none; color: var(--at-ink); background: var(--at-surface-2); min-height: 160px; }
.at-more:hover { border-color: var(--at-ink); }
.at-more b { font-size: 18.5px; font-weight: 700; }
.at-more small { color: var(--at-muted); font-size: 15px; }

/* ── 버튼·칩·패널 ── */
body.at .btn { border-radius: 6px; font-weight: 500; }
body.at .btn.primary { background: var(--bp); border-color: var(--bp); color: #fff; }
body.at .btn.primary:hover { background: var(--bp-deep); }
.at-chip { border-radius: 6px; }
.at-chip.active { background: var(--bp); border-color: var(--bp); color: #fff; }
body.at .panel { border-radius: var(--r); box-shadow: var(--at-shadow); }
body.at .stage-head strong { font-family: var(--f-sans); font-weight: 600; letter-spacing: 0; color: var(--at-ink); }
body.at .control-panel h2 { font-family: var(--f-sans); font-weight: 700; font-size: 17.5px; }
body.at .control-panel h3 { font-family: var(--f-sans); letter-spacing: 0; }
.hs-seg button[aria-pressed="true"] { background: var(--bp); color: #fff; }
body.at input[type="range"] { accent-color: var(--bp); }

/* ── 실험 화면 머리 ── */
.at-lab-top h1 { font-family: var(--f-sans); font-weight: 700; letter-spacing: -0.025em; }
.at-code { font-family: var(--f-sans); letter-spacing: 0; }
.at-back { color: var(--at-muted); }

/* ── 휴대폰 ── */
@media (max-width: 860px) {
  .at-header-inner { flex-wrap: nowrap; gap: 10px; }
  .at-menu { display: inline-grid; place-content: center; gap: 4px; margin-left: auto; width: 40px; height: 40px; border: 1px solid rgba(234, 241, 251, 0.25); border-radius: 6px; background: transparent; }
  .at-menu span { display: block; width: 18px; height: 2px; background: var(--bp-ink); transition: transform 0.2s, opacity 0.2s; }
  body.nav-open .at-menu span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
  body.nav-open .at-menu span:nth-child(2) { opacity: 0; }
  body.nav-open .at-menu span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
  .at-nav, .at-tools { display: none !important; }
  body.nav-open .at-header-inner { flex-wrap: wrap; }
  body.nav-open .at-nav { display: flex !important; order: 3; width: 100%; margin: 6px 0 0; gap: 4px; flex-direction: column; }
  body.nav-open .at-nav a { padding: 10px 4px; font-size: 17.5px; border-bottom: 1px solid var(--bp-grid-strong); }
  body.nav-open .at-tools { display: flex !important; order: 4; width: 100%; flex-wrap: wrap; padding: 10px 0 6px; }
  .at-hero { grid-template-columns: 1fr; }
  .at-titleblock dl { grid-template-columns: 1fr 1fr; }
  .at-titleblock dl > div:nth-child(3) { border-left: 0; }
  .at-titleblock dl > div:nth-child(n+3) { border-top: 1px solid var(--bp-grid-strong); }
  /* 실험할 때 그림이 화면 위에 남아 있게 */
  body.at .lab-layout { display: flex; flex-direction: column; }
  body.at .stage-panel { position: sticky; top: 64px; z-index: 6; }
  body.at .stage-panel .stage-head, body.at .stage-panel .plot-caption { display: none; }
  body.at .stage-panel .metrics { display: flex; flex-wrap: nowrap; overflow-x: auto; gap: 8px; padding: 8px 10px; scroll-snap-type: x proximity; }
  body.at .stage-panel .metrics > div { flex: 0 0 auto; min-width: 120px; max-width: 72vw; scroll-snap-align: start; padding: 6px 10px; }
  body.at .stage-panel .metrics .hs-note { display: none; }
  body.at .top-actions { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 4px; }
  body.at .top-actions .btn { flex: 0 0 auto; }
}
@media (max-width: 860px) and (max-height: 700px) { body.at .stage-panel { position: static; } }
@media print { .at-header::after, .at-hero::before, .at-hero::after, body.at::before { display: none; } }
.at-hero-fig .at-titleblock { background: transparent; padding: 0; border-top: 1.5px solid var(--bp-grid-strong); font-family: var(--f-sans); color: var(--bp-ink); }
body.at .at-hero .btn { background: transparent; color: var(--bp-ink); border-color: rgba(234, 241, 251, 0.35); }
body.at .at-hero .btn:hover { border-color: var(--brass-light); }
body.at .at-hero .btn.primary { background: var(--brass-light); color: var(--bp-deep); border-color: var(--brass-light); font-weight: 600; }
body.at .at-hero .btn.primary:hover { background: #f0c87e; }
@media (max-width: 860px) {
  body.at .lab-layout > * { min-width: 0; width: 100%; max-width: 100%; box-sizing: border-box; }
  body.at .stage-panel .metrics { max-width: 100%; box-sizing: border-box; }
}
/* 손가락으로 쓰는 화면: 슬라이더를 잡기 쉽게 (터치 영역 높이 44px, 손잡이 26px) */
@media (pointer: coarse) {
  body.at input[type="range"] { -webkit-appearance: none; appearance: none; height: 44px; background: transparent; touch-action: pan-y; }
  body.at input[type="range"]::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; background: color-mix(in srgb, var(--course, var(--at-brass, #b08a3e)) 35%, transparent); }
  body.at input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 26px; height: 26px; margin-top: -10px; border-radius: 50%; background: var(--course, var(--at-brass, #b08a3e)); border: 3px solid var(--at-bg, #fff); box-shadow: 0 1px 4px rgba(0, 0, 0, 0.35); }
  body.at input[type="range"]::-moz-range-track { height: 6px; border-radius: 3px; background: color-mix(in srgb, var(--course, var(--at-brass, #b08a3e)) 35%, transparent); }
  body.at input[type="range"]::-moz-range-thumb { width: 22px; height: 22px; border-radius: 50%; background: var(--course, var(--at-brass, #b08a3e)); border: 3px solid var(--at-bg, #fff); }
  body.at input[type="range"]:focus-visible { outline: 2px solid var(--course, var(--at-brass, #b08a3e)); outline-offset: 2px; }
}
/* 과정 선택 줄: 과정마다 고유 색으로 칩 전체를 물들여 한눈에 구별 */
body.at .at-rail ol { gap: 12px; }
body.at .at-rgroup { gap: 9px; padding: 10px 12px 12px; border: 1px solid var(--at-line); border-radius: 10px; background: color-mix(in srgb, var(--at-surface-2, var(--at-surface)) 70%, transparent); }
body.at .at-rg-label { font-size: 14.5px; font-weight: 700; color: var(--at-ink); letter-spacing: 0.02em; }
body.at .at-rg-label::after { display: none; }
body.at .at-rg-row { gap: 8px; }
body.at .at-station { padding: 8px 12px 8px 14px; border-radius: 8px; border: 1px solid color-mix(in srgb, var(--c) 45%, transparent); border-left: 5px solid var(--c); background: color-mix(in srgb, var(--c) 13%, var(--at-surface)); }
body.at .at-station::before { display: none; }
body.at .at-station b { font-size: 16.5px; font-weight: 700; color: color-mix(in srgb, var(--c) 55%, var(--at-ink)); }
body.at .at-station small { font-size: 14px; padding: 1px 7px; border-radius: 999px; background: color-mix(in srgb, var(--c) 22%, transparent); color: color-mix(in srgb, var(--c) 45%, var(--at-ink)); }
body.at .at-station:hover { background: color-mix(in srgb, var(--c) 24%, var(--at-surface)); border-color: var(--c); }
body.at .at-station.active { background: var(--c); border-color: var(--c); box-shadow: 0 2px 10px color-mix(in srgb, var(--c) 45%, transparent); }
body.at .at-station.active b { color: #fff; }
body.at .at-station.active small { background: rgba(255, 255, 255, 0.25); color: #fff; }
body.at .at-station:focus-visible { outline: 2px solid var(--c); outline-offset: 2px; }
@media (max-width: 640px) { body.at .at-rail ol > .at-rgroup { flex: 1 1 100%; } body.at .at-rail { padding: 12px; } }

/* ═══════════ v3 화면 구조 (2026-10-07) — 목차 → 단원 → 실험, 작업대형 실험 화면 ═══════════ */
body.at .ic { width: 18px; height: 18px; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
body.at .at-main.v3 { max-width: 1480px; padding: 0 clamp(16px, 2.6vw, 32px) 40px; }
/* 머리글 검색 */
body.at .v3-hsearch { flex: 1; max-width: 520px; margin-left: 28px; height: 40px; display: flex; align-items: center; gap: 10px; padding: 0 14px; border-radius: 10px; border: 1px solid var(--bp-grid-strong); background: rgba(255, 255, 255, 0.1); color: var(--bp-dim); font: inherit; font-size: 16px; cursor: text; text-align: left; }
body.at .v3-hsearch span { flex: 1; }
body.at .v3-hsearch kbd { font-family: var(--f-mono); font-size: 14px; padding: 2px 6px; border-radius: 4px; background: rgba(255, 255, 255, 0.16); color: var(--bp-ink); }
body.at .v3-hsearch:hover { border-color: var(--brass-light); color: var(--bp-ink); }
body.at .v3-head .at-tools .v3-find-m { display: none; }
body.at .v3-head .at-nav { margin-left: auto; }

/* ── 첫 화면 ── */
body.at .v3-hero { margin: 0 calc(-1 * clamp(16px, 2.6vw, 32px)); background: var(--bp); color: var(--bp-ink); background-image: linear-gradient(var(--bp-grid) 1px, transparent 1px), linear-gradient(90deg, var(--bp-grid) 1px, transparent 1px); background-size: 32px 32px; }
body.at .v3-hero-in { max-width: 1480px; margin: 0 auto; box-sizing: border-box; padding: 40px clamp(16px, 4vw, 56px) 46px; display: flex; gap: 48px; align-items: center; flex-wrap: wrap; }
body.at .v3-hero-main { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
body.at .v3-eyebrow { margin: 0; font-size: 15px; font-weight: 600; color: var(--brass-light); }
body.at .v3-title { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; }
body.at .v3-title h1 { margin: 0; font-size: clamp(28px, 3.4vw, 42px); line-height: 1.22; font-weight: 700; color: var(--bp-ink); letter-spacing: -0.01em; }
body.at .v3-wordmark { font-family: var(--f-display); font-weight: 700; font-size: clamp(40px, 5vw, 66px); line-height: 1; color: var(--brass-light); padding-left: 28px; border-left: 2px solid color-mix(in srgb, var(--brass-light) 45%, transparent); white-space: nowrap; }
body.at .v3-bigsearch { margin-top: 6px; height: 58px; display: flex; align-items: center; gap: 12px; padding: 0 20px; border-radius: 14px; border: 0; background: #ffffff; color: #5a6880; font: inherit; font-size: 17.5px; text-align: left; cursor: text; box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22); }
body.at .v3-bigsearch .ic { color: #123a6b; width: 20px; height: 20px; }
body.at .v3-bigsearch span { flex: 1; }
body.at .v3-bigsearch kbd { font-family: var(--f-mono); font-size: 14px; color: #5a6880; }
body.at .v3-popular { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; font-size: 15px; }
body.at .v3-popular > span { color: var(--bp-dim); margin-right: 2px; }
body.at .v3-popular button { min-height: 32px; padding: 4px 12px; border-radius: 999px; border: 1px solid var(--bp-grid-strong); background: transparent; color: var(--bp-ink); font: inherit; font-size: 15px; cursor: pointer; }
body.at .v3-popular button:hover { border-color: var(--brass-light); color: var(--brass-light); }
body.at .v3-stats { flex: 1 1 360px; max-width: 460px; margin: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
body.at .v3-stats div { padding: 16px 18px; border-radius: 12px; background: rgba(255, 255, 255, 0.07); border: 1px solid var(--bp-grid-strong); display: flex; flex-direction: column-reverse; }
body.at .v3-stats dd { margin: 0; font-family: var(--f-display); font-weight: 700; font-size: 43px; line-height: 1.05; color: var(--bp-ink); }
body.at .v3-stats dt { font-size: 14px; color: var(--bp-dim); }
body.at .v3-home { display: flex; gap: 28px; padding-top: 28px; flex-wrap: wrap; }
body.at .v3-courses { flex: 999 1 640px; min-width: 0; }
body.at .v3-sec-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
body.at .v3-sec-head h2, body.at .v3-resume h2 { margin: 0; font-size: 21.5px; font-weight: 700; }
body.at .v3-sec-head span { font-size: 15px; color: var(--at-muted); }
body.at .v3-cgrid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 12px; }
body.at .v3-cgroup { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
body.at .v3-cgroup h3 { margin: 0 0 2px; font-size: 14px; font-weight: 700; color: var(--at-muted); }
body.at .v3-ctile { display: flex; flex-direction: column; gap: 3px; padding: 12px 12px 12px 16px; border-radius: 10px; text-decoration: none; color: var(--at-ink); background: var(--at-surface); border: 1px solid var(--at-line); box-shadow: inset 4px 0 0 var(--c); transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s; min-height: 44px; }
body.at .v3-ctile b { font-size: 16.5px; font-weight: 700; }
body.at .v3-ctile small { font-size: 14px; color: var(--at-muted); }
body.at .v3-ctile:hover { transform: translateY(-2px); border-color: var(--c); box-shadow: inset 4px 0 0 var(--c), var(--at-shadow); }
body.at .v3-resume { flex: 1 1 300px; max-width: 380px; display: flex; flex-direction: column; gap: 10px; }
body.at .v3-rc { display: flex; gap: 12px; align-items: center; padding: 10px; border-radius: 12px; background: var(--at-surface); border: 1px solid var(--at-line); text-decoration: none; color: var(--at-ink); }
body.at .v3-rc:hover { border-color: var(--c); }
body.at .v3-rc-thumb { width: 76px; height: 52px; flex-shrink: 0; border-radius: 8px; overflow: hidden; background: var(--pl-paper); }
body.at .v3-rc-thumb svg { width: 100%; height: 100%; display: block; }
body.at .v3-rc small { display: block; font-size: 14px; color: var(--at-muted); }
body.at .v3-rc b { display: block; font-size: 16px; line-height: 1.35; font-weight: 600; }
body.at .v3-empty, body.at .v3-favs { margin: 0; font-size: 15px; color: var(--at-muted); }
body.at .v3-maplink { font-size: 15px; color: var(--at-muted); }

/* ── 과정 화면 ── */
body.at .v3-course { display: flex; gap: 28px; padding-top: 24px; align-items: flex-start; }
body.at .v3-side { width: 300px; flex-shrink: 0; position: sticky; top: 76px; max-height: calc(100vh - 92px); overflow-y: auto; display: flex; flex-direction: column; gap: 14px; padding: 16px; box-sizing: border-box; border-radius: 14px; background: var(--at-surface); border: 1px solid var(--at-line); }
body.at .v3-picker { position: relative; }
body.at .v3-picker summary { list-style: none; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--at-line); background: var(--at-surface-2); cursor: pointer; min-height: 44px; }
body.at .v3-picker summary::-webkit-details-marker { display: none; }
body.at .v3-picker summary i { width: 12px; height: 12px; border-radius: 3px; background: var(--c); flex-shrink: 0; }
body.at .v3-picker summary span { flex: 1; display: flex; flex-direction: column; }
body.at .v3-picker summary small { font-size: 14px; color: var(--at-muted); }
body.at .v3-picker summary b { font-size: 18.5px; font-weight: 700; }
body.at .v3-picker[open] summary .ic { transform: rotate(180deg); }
body.at .v3-picker-list { position: absolute; z-index: 30; left: 0; width: 460px; top: calc(100% + 6px); padding: 14px; box-sizing: border-box; border-radius: 12px; background: var(--at-surface); border: 1px solid var(--at-line); box-shadow: 0 18px 40px -16px rgba(19, 35, 63, 0.45); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 16px; }
body.at .v3-picker-list h4 { margin: 0 0 4px; font-size: 14px; color: var(--at-muted); }
body.at .v3-picker-list a { display: flex; align-items: center; gap: 8px; padding: 7px 8px; border-radius: 8px; text-decoration: none; color: var(--at-ink); font-size: 16px; min-height: 36px; }
body.at .v3-picker-list a i { width: 9px; height: 9px; border-radius: 2px; background: var(--c); }
body.at .v3-picker-list a span { flex: 1; }
body.at .v3-picker-list a small { color: var(--at-muted); font-size: 14px; }
body.at .v3-picker-list a:hover, body.at .v3-picker-list a[aria-current] { background: color-mix(in srgb, var(--c) 12%, transparent); }
body.at .v3-progress { display: grid; grid-template-columns: 1fr auto; gap: 6px; font-size: 14px; color: var(--at-muted); }
body.at .v3-progress span:nth-child(2) { color: var(--course); font-weight: 600; }
body.at .v3-bar { grid-column: 1 / -1; height: 6px; border-radius: 3px; background: var(--at-surface-2); overflow: hidden; }
body.at .v3-bar i { display: block; height: 100%; background: var(--course); border-radius: 3px; }
body.at .v3-units { display: flex; flex-direction: column; gap: 2px; }
body.at .v3-unit { display: flex; align-items: center; gap: 8px; padding: 10px; border-radius: 8px; text-decoration: none; color: var(--at-ink); min-height: 44px; box-sizing: border-box; }
body.at .v3-unit .no { font-family: var(--f-display); font-weight: 700; font-size: 19.5px; min-width: 26px; color: var(--course); }
body.at .v3-unit .nm { flex: 1; font-size: 16px; font-weight: 600; line-height: 1.35; }
body.at .v3-unit .ct { font-size: 14px; color: var(--at-muted); }
body.at .v3-unit:hover { background: var(--at-surface-2); }
body.at .v3-unit.on { background: color-mix(in srgb, var(--course) 12%, var(--at-surface)); box-shadow: inset 3px 0 0 var(--course); }
body.at .v3-lessons { display: flex; flex-direction: column; gap: 1px; padding: 2px 0 8px 36px; }
body.at .v3-lessons a { display: flex; justify-content: space-between; gap: 8px; padding: 6px 10px; border-radius: 6px; font-size: 15px; color: var(--at-muted); text-decoration: none; }
body.at .v3-lessons a:hover { color: var(--at-ink); background: var(--at-surface-2); }
body.at .v3-lessons a[aria-current] { color: var(--course); font-weight: 700; background: color-mix(in srgb, var(--course) 9%, transparent); }
body.at .v3-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
body.at .v3-crumbs { margin: 0; font-size: 15px; color: var(--at-muted); }
body.at .v3-crumbs a { color: var(--at-muted); text-decoration: none; }
body.at .v3-crumbs a:hover { color: var(--at-ink); text-decoration: underline; }
body.at .v3-unit-head { display: flex; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
body.at .v3-unit-head > div { flex: 1; min-width: 260px; }
body.at .v3-unit-head h1 { margin: 2px 0 0; font-size: clamp(24px, 2.4vw, 32px); font-weight: 700; letter-spacing: -0.01em; }
body.at .v3-unit-head p { margin: 6px 0 0; font-size: 16px; color: var(--at-muted); }
body.at .v3-unit-head .btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; }
body.at .v3-tools { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px; border-radius: 12px; background: var(--at-surface); border: 1px solid var(--at-line); }
body.at .v3-search { flex: 1 1 220px; display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px; border-radius: 9px; background: var(--at-surface-2); border: 1px solid var(--at-line); color: var(--at-muted); }
body.at .v3-search input { flex: 1; min-width: 0; border: 0; background: transparent; font: inherit; font-size: 16px; color: var(--at-ink); outline: none; }
body.at .v3-chips { display: flex; gap: 6px; flex-wrap: wrap; }
body.at .v3-chips .at-chip { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 12px; border-radius: 999px; }
body.at .v3-chips .at-chip small { font-size: 14px; opacity: 0.7; }
body.at .v3-sort { display: flex; align-items: center; gap: 6px; font-size: 15px; color: var(--at-muted); }
body.at .v3-sort select { height: 36px; border-radius: 8px; border: 1px solid var(--at-line); background: var(--at-surface); color: var(--at-ink); font: inherit; font-size: 15px; padding: 0 8px; }
body.at .v3-view { display: flex; border: 1px solid var(--at-line); border-radius: 8px; overflow: hidden; }
body.at .v3-view button { width: 40px; height: 36px; border: 0; background: var(--at-surface); color: var(--at-muted); cursor: pointer; display: flex; align-items: center; justify-content: center; }
body.at .v3-view button[aria-pressed="true"] { background: var(--bp); color: #ffffff; }
body.at .v3-count { margin-left: auto; font-size: 15px; color: var(--at-muted); }
/* 카드 */
body.at .v3-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(232px, 1fr)); gap: 16px; }
body.at .v3-card { position: relative; display: flex; flex-direction: column; border-radius: 12px; background: var(--at-surface); border: 1px solid var(--at-line); overflow: hidden; transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s; }
body.at .v3-card:hover { transform: translateY(-2px); border-color: var(--c); box-shadow: var(--at-shadow); }
body.at .v3-card:focus-within { border-color: var(--c); box-shadow: 0 0 0 2px color-mix(in srgb, var(--c) 40%, transparent); }
body.at .v3-thumb { position: relative; aspect-ratio: 16 / 10; background: var(--pl-paper); border-bottom: 1px solid var(--at-line); overflow: hidden; }
body.at .v3-thumb svg { width: 100%; height: 100%; display: block; }
body.at .v3-seen { position: absolute; left: 10px; top: 10px; font-size: 14px; font-weight: 700; padding: 3px 8px; border-radius: 999px; background: #e3f2e9; color: #1f6b43; }
body.at .v3-fav { position: absolute; z-index: 2; right: 8px; top: 8px; width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--at-line); background: var(--at-surface); color: var(--at-brass); font-size: 18.5px; cursor: pointer; }
body.at .v3-card-body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
body.at .v3-meta { font-size: 14px; font-weight: 600; color: var(--c); }
body.at .v3-card h2 { margin: 0; font-size: 17px; line-height: 1.38; font-weight: 700; }
body.at .v3-card h2 a { color: var(--at-ink); text-decoration: none; }
body.at .v3-card h2 a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
body.at .v3-card p { margin: 0; font-size: 15px; line-height: 1.55; color: var(--at-muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
body.at .v3-sub { margin-top: auto; display: flex; gap: 6px; flex-wrap: wrap; font-size: 14px; color: var(--at-muted); }
body.at .v3-sub i { font-style: normal; padding: 1px 8px; border-radius: 999px; background: var(--at-surface-2); }
/* 목록 보기 */
body.at .v3-grid.is-list { grid-template-columns: 1fr; gap: 8px; }
body.at .v3-grid.is-list .v3-card { flex-direction: row; align-items: center; }
body.at .v3-grid.is-list .v3-thumb { width: 112px; flex-shrink: 0; aspect-ratio: 16 / 10; border-bottom: 0; border-right: 1px solid var(--at-line); }
body.at .v3-grid.is-list .v3-card-body { padding: 10px 56px 10px 14px; flex-direction: row; align-items: center; gap: 14px; flex-wrap: wrap; }
body.at .v3-grid.is-list .v3-card-body h2 { flex: 1 1 260px; }
body.at .v3-grid.is-list .v3-card p { display: none; }
body.at .v3-grid.is-list .v3-sub { margin: 0; }
body.at .v3-grid.is-list .v3-fav { top: 50%; transform: translateY(-50%); }
body.at .v3-grid.is-list .v3-seen { font-size: 13px; left: 6px; top: 6px; padding: 2px 6px; }
body.at .v3-pager { display: flex; justify-content: space-between; gap: 12px; margin-top: 8px; padding-top: 14px; border-top: 1px solid var(--at-line); }
body.at .v3-pager a { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 10px; border: 1px solid var(--at-line); background: var(--at-surface); text-decoration: none; color: var(--at-ink); min-height: 44px; }
body.at .v3-pager a:hover { border-color: var(--course); }
body.at .v3-pager a.next { text-align: right; }
body.at .v3-pager small { display: block; font-size: 14px; color: var(--at-muted); }
body.at .v3-pager b { font-size: 16px; }

/* ── 실험 화면 (작업대) ── */
body.at .v3-labbar { display: flex; align-items: center; gap: 14px; padding: 18px 0 14px; }
body.at .v3-arrow { width: 44px; height: 44px; flex-shrink: 0; border-radius: 12px; border: 1px solid var(--at-line); background: var(--at-surface); color: var(--at-ink); display: flex; align-items: center; justify-content: center; text-decoration: none; }
body.at .v3-arrow:hover { border-color: var(--course); color: var(--course); }
body.at .v3-arrow.off { visibility: hidden; }
body.at .v3-labtitle { flex: 1; min-width: 0; }
body.at .v3-labtitle .v3-meta { margin: 2px 0 0; color: var(--course); }
body.at .v3-labtitle h1 { margin: 2px 0 0; font-size: clamp(21px, 2vw, 27px); line-height: 1.3; font-weight: 700; }
body.at .v3-lead { margin: 4px 0 0; font-size: 16px; line-height: 1.6; color: var(--at-muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; max-width: 980px; }
body.at .v3-labtools { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
body.at .v3-labtools .btn { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 12px; font-size: 15px; }
body.at .lab-layout.v3-lab { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 16px; align-items: start; }
body.at .v3-sidepanel { position: sticky; top: 76px; max-height: calc(100vh - 92px); display: flex; flex-direction: column; padding: 0; overflow: hidden; }
body.at .v3-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-bottom: 1px solid var(--at-line); flex-shrink: 0; }
body.at .v3-tabs button { min-height: 48px; border: 0; background: transparent; font: inherit; font-size: 16px; color: var(--at-muted); cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 6px; }
body.at .v3-tabs button small { font-size: 14px; padding: 1px 6px; border-radius: 999px; background: color-mix(in srgb, var(--course) 15%, transparent); color: var(--course); font-weight: 700; }
body.at .v3-tabs button[aria-selected="true"] { color: var(--at-ink); font-weight: 700; box-shadow: inset 0 -3px 0 var(--bp); }
body.at .v3-tabpanel { flex: 1; min-height: 0; overflow-y: auto; }
body.at .v3-tabpanel .control-panel { position: static; max-height: none; overflow: visible; border: 0; box-shadow: none; background: transparent; }
body.at .v3-tabpanel #pred-slot:empty { display: none; }
body.at .v3-tabpanel #pred-slot { padding: 0 18px 18px; }
body.at .v3-info { padding: 16px 18px 20px; }
body.at .v3-info h2 { margin: 16px 0 8px; font-size: 16px; font-weight: 700; color: var(--at-muted); }
body.at .v3-info h2:first-child { margin-top: 0; }
body.at .v3-info ul { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; font-size: 16px; line-height: 1.6; }
body.at .v3-info p { margin: 0; font-size: 16px; line-height: 1.6; }
body.at .v3-tabpanel[data-panel="rel"] { padding: 16px 18px; }
body.at .v3-tabpanel .at-links { margin: 0; display: flex; flex-direction: column; gap: 14px; }
body.at .v3-tabpanel .at-links h2 { font-size: 15px; color: var(--at-muted); margin: 0 0 8px; }
body.at .v3-tabpanel .at-link-row { display: flex; flex-direction: column; gap: 8px; }
body.at .v3-nextcard { flex-shrink: 0; margin: 0 12px 12px; display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--at-line); background: var(--at-surface-2); text-decoration: none; color: var(--at-ink); }
body.at .v3-nextcard span { flex: 1; min-width: 0; }
body.at .v3-nextcard small { display: block; font-size: 14px; color: var(--course); font-weight: 600; }
body.at .v3-nextcard b { display: block; font-size: 16px; line-height: 1.35; }
body.at .v3-nextcard:hover { border-color: var(--course); }
body.at.presentation .v3-labbar .v3-crumbs, body.at.presentation .v3-lead, body.at.presentation .v3-bottom { display: none; }

/* ── 아래 메뉴 (휴대폰) ── */
body.at .v3-bottom { display: none; }

@media (max-width: 1180px) {
  body.at .v3-cgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  body.at .lab-layout.v3-lab { grid-template-columns: minmax(0, 1fr) 340px; }
  body.at .v3-labtools .btn span { display: none; }
  body.at .v3-labtools .btn.primary span { display: inline; }
}
@media (max-width: 960px) {
  body.at .v3-hsearch { display: none; }
  body.at .v3-head .at-tools .v3-find-m { display: inline-flex; }
  body.at .v3-course { flex-direction: column; gap: 14px; padding-top: 14px; }
  body.at .v3-side { position: static; width: 100%; max-height: none; overflow: visible; padding: 12px; gap: 10px; }
  body.at .v3-picker-list { width: 100%; }
  body.at .v3-units { flex-direction: row; overflow-x: auto; gap: 6px; padding-bottom: 2px; scrollbar-width: none; }
  body.at .v3-unit { flex: 0 0 auto; min-height: 40px; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--at-line); }
  body.at .v3-unit .nm { font-size: 15px; white-space: nowrap; }
  body.at .v3-unit.on { box-shadow: none; border-color: var(--course); background: var(--course); color: #ffffff; }
  body.at .v3-unit.on .no, body.at .v3-unit.on .ct { color: #ffffff; }
  body.at .v3-lessons, body.at .v3-side .v3-maplink { display: none; }
  body.at .lab-layout.v3-lab { display: flex; flex-direction: column; }
  body.at .v3-sidepanel { position: static; max-height: none; }
  body.at .v3-tabpanel { overflow: visible; }
  body.at .v3-labbar { flex-wrap: wrap; }
  body.at .v3-labtitle { order: 1; flex-basis: calc(100% - 116px); }
  body.at .v3-labbar > .v3-arrow:first-child { order: 0; }
  body.at .v3-labbar > .v3-arrow:last-child { order: 2; }
  body.at .v3-labtools { order: 3; width: 100%; justify-content: flex-start; }
}
@media (max-width: 760px) {
  body.at .v3-hero-in { padding: 26px 16px 28px; gap: 20px; }
  body.at .v3-title { gap: 14px; }
  body.at .v3-wordmark { padding-left: 0; border-left: 0; font-size: 41px; }
  body.at .v3-bigsearch { height: 52px; font-size: 16.5px; }
  body.at .v3-bigsearch kbd { display: none; }
  body.at .v3-stats dd { font-size: 31px; }
  body.at .v3-stats div { padding: 10px 12px; }
  body.at .v3-cgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  body.at .v3-resume { max-width: none; }
  body.at .v3-tools { padding: 8px; gap: 8px; }
  body.at .v3-sort, body.at .v3-view, body.at .v3-count { display: none; }
  body.at .v3-chips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; width: 100%; }
  body.at .v3-chips .at-chip { flex: 0 0 auto; }
  body.at .v3-unit-head .btn { width: 100%; justify-content: center; }
  /* 휴대폰은 늘 짧은 목록으로 */
  body.at .v3-grid, body.at .v3-grid.is-list { grid-template-columns: 1fr; gap: 8px; }
  body.at .v3-grid .v3-card { flex-direction: row; align-items: center; }
  body.at .v3-grid .v3-thumb { width: 84px; flex-shrink: 0; border-bottom: 0; border-right: 1px solid var(--at-line); }
  body.at .v3-grid .v3-card-body { padding: 8px 48px 8px 12px; gap: 2px; }
  body.at .v3-grid .v3-card p, body.at .v3-grid .v3-sub { display: none; }
  body.at .v3-grid .v3-card h2 { font-size: 16px; }
  body.at .v3-grid .v3-fav { top: 50%; transform: translateY(-50%); width: 34px; height: 34px; }
  body.at .v3-grid .v3-seen { font-size: 13px; left: 4px; top: 4px; padding: 1px 5px; }
  body.at .v3-pager a b { font-size: 15px; }
  body.at .v3-lead { display: none; }
  body.at .v3-labtools .btn { min-height: 40px; padding: 0 10px; }
  body.at .v3-labtools .btn span { display: none; }
  body.at .at-lab-nav { display: none; }
  body.at .at-footer { padding-bottom: 84px; }
  body.at .v3-bottom { display: grid; position: fixed; z-index: 40; left: 0; right: 0; bottom: 0; grid-template-columns: repeat(4, minmax(0, 1fr)); padding-bottom: env(safe-area-inset-bottom, 0px); background: var(--at-surface); border-top: 1px solid var(--at-line); box-shadow: 0 -6px 18px -10px rgba(19, 35, 63, 0.35); }
  body.at .v3-bottom a, body.at .v3-bottom button { min-height: 58px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; border: 0; background: transparent; font: inherit; font-size: 14px; color: var(--at-muted); text-decoration: none; cursor: pointer; }
  body.at .v3-bottom [aria-current="page"] { color: var(--bp); font-weight: 700; }
  body.at .v3-bottom .ic { width: 21px; height: 21px; }
}
:root[data-theme="dark"] body.at .v3-bottom [aria-current="page"] { color: var(--brass-light); }

/* ── 사용설명서 (#/guide) ── */
.g-wrap { max-width: 1180px; margin: 0 auto; padding: 40px 28px 80px; display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 56px; align-items: start; }
.g-toc { position: sticky; top: 88px; display: flex; flex-direction: column; gap: 2px; font-size: 16px; }
.g-toc > b { font-size: 14px; letter-spacing: .08em; color: var(--at-muted); margin: 0 0 8px 12px; }
.g-toc a { color: var(--at-ink); text-decoration: none; padding: 7px 12px; border-left: 2px solid var(--at-line); line-height: 1.4; }
.g-toc a:hover { background: var(--at-surface); }
.g-toc a[aria-current] { border-left-color: var(--at-brass); font-weight: 700; background: var(--at-surface); }
.g-toc .g-dl { margin-top: 10px; border: 1px solid var(--at-line); border-radius: 10px; text-align: center; font-weight: 600; background: var(--at-surface); }
.g-toc .g-dl + .g-dl { margin-top: 6px; }
.g-toc .g-dl:first-of-type { margin-top: 22px; }
.g-body { min-width: 0; color: var(--at-ink); }
.g-eyebrow { margin: 0; font-size: 15px; font-weight: 700; letter-spacing: .1em; color: var(--at-brass); }
.g-body h1 { margin: 8px 0 10px; font-size: clamp(30px, 4vw, 44px); line-height: 1.15; letter-spacing: -.01em; }
.g-lede { margin: 0 0 40px; font-size: 19.5px; color: var(--at-muted); padding-bottom: 32px; border-bottom: 1px solid var(--at-line); }
.g-sec { padding: 8px 0 40px; scroll-margin-top: 84px; }
.g-sec + .g-sec { border-top: 1px solid var(--at-line); padding-top: 36px; }
.g-sec h2 { margin: 0 0 12px; font-size: 25px; letter-spacing: -.01em; }
.g-intro { margin: 0 0 20px; font-size: 17.5px; line-height: 1.75; max-width: 72ch; }
.g-fig { margin: 0 0 24px; }
.g-fig img { display: block; width: 100%; height: auto; border-radius: 14px; border: 1px solid var(--at-line); box-shadow: 0 18px 40px -22px rgba(16, 33, 58, .45); background: var(--at-surface); }
.g-sec#g-predict .g-fig img, .g-sec#g-mobile .g-fig img { width: auto; max-width: min(100%, 460px); }
.g-fig figcaption { margin-top: 10px; font-size: 15px; color: var(--at-muted); }
.g-steps { list-style: none; counter-reset: g; margin: 0; padding: 0; display: grid; gap: 12px; max-width: 76ch; }
.g-steps li { counter-increment: g; position: relative; padding: 2px 0 2px 44px; line-height: 1.7; font-size: 17px; }
.g-steps li::before { content: counter(g); position: absolute; left: 0; top: 1px; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-size: 15px; font-weight: 700; color: #fff; background: var(--at-ink); }
.g-tip { margin: 20px 0 0; max-width: 76ch; padding: 14px 18px; border-radius: 12px; border: 1px solid color-mix(in srgb, var(--at-brass) 40%, transparent); background: color-mix(in srgb, var(--at-brass) 9%, var(--at-surface)); line-height: 1.65; font-size: 16.5px; }
.g-tip b { color: var(--at-brass); margin-right: 8px; }
.g-qa { margin: 0; display: grid; gap: 12px; max-width: 80ch; }
.g-qa div { padding: 16px 20px; border: 1px solid var(--at-line); border-radius: 12px; background: var(--at-surface); }
.g-qa dt { font-weight: 700; margin-bottom: 6px; }
.g-qa dt::before { content: "Q"; color: var(--at-brass); margin-right: 10px; font-weight: 800; }
.g-qa dd { margin: 0; line-height: 1.65; color: var(--at-muted); padding-left: 24px; }
@media (max-width: 900px) {
  .g-wrap { grid-template-columns: 1fr; gap: 24px; padding: 24px 16px 96px; }
  .g-toc { position: static; flex-direction: row; flex-wrap: wrap; gap: 6px; }
  .g-toc > b { width: 100%; margin: 0; }
  .g-toc a { border: 1px solid var(--at-line); border-radius: 999px; padding: 6px 12px; font-size: 15px; }
  .g-toc .g-dl, .g-toc .g-dl:first-of-type { margin-top: 0; }
}
@media print { .g-toc { display: none; } .g-wrap { display: block; } }

/* ── 메뉴 다듬기 (v3.1) ── */
body.at .v3-head .at-nav { gap: 2px; align-items: center; }
body.at .v3-head .at-nav a { display: inline-flex; align-items: center; gap: 7px; height: 38px; padding: 0 12px; border-radius: 9px; border-bottom: 0; position: relative; color: var(--bp-dim); font-weight: 500; white-space: nowrap; }
body.at .v3-head .at-nav a .ic { width: 17px; height: 17px; opacity: .8; }
body.at .v3-head .at-nav a:hover { background: rgba(234, 241, 251, 0.09); color: var(--bp-ink); }
body.at .v3-head .at-nav a[aria-current="page"] { color: var(--bp-ink); font-weight: 700; background: rgba(234, 241, 251, 0.1); }
body.at .v3-head .at-nav a[aria-current="page"]::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: -11px; height: 3px; border-radius: 3px 3px 0 0; background: var(--brass-light); }
body.at .v3-head .at-nav a[aria-current="page"] .ic { opacity: 1; color: var(--brass-light); }
body.at .v3-head .nv-d, body.at .v3-head .nv-set { display: none; }
body.at .v3-head .at-sheet-n:empty { display: none; }
body.at .v3-head .at-tools { gap: 8px; padding-left: 14px; margin-left: 6px; border-left: 1px solid rgba(234, 241, 251, 0.18); }
body.at .v3-head .at-theme { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; }
body.at .v3-head .at-theme .ic { width: 16px; height: 16px; }
@media (max-width: 1180px) {
  body.at .v3-head .at-nav a .ic { display: none; }
  body.at .v3-head .at-theme span { display: none; }
  body.at .v3-head .at-theme { width: 34px; padding: 0; justify-content: center; }
}
@media (max-width: 860px) {
  body.at.nav-open .v3-head .at-nav { display: grid !important; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 10px 0 2px; }
  body.at.nav-open .v3-head .at-nav a { height: auto; min-height: 74px; display: grid; grid-template-columns: auto 1fr auto; grid-template-rows: auto auto; align-content: center; column-gap: 10px; row-gap: 2px; padding: 12px 14px; border: 1px solid rgba(234, 241, 251, 0.16); border-radius: 12px; background: rgba(234, 241, 251, 0.05); font-size: 17px; white-space: normal; }
  body.at.nav-open .v3-head .at-nav a .ic { display: block; grid-row: 1 / 3; width: 22px; height: 22px; align-self: center; opacity: 1; color: var(--brass-light); }
  body.at.nav-open .v3-head .at-nav a .nv-t { grid-column: 2; }
  body.at.nav-open .v3-head .at-nav a .at-sheet-n { grid-column: 3; grid-row: 1; }
  body.at.nav-open .v3-head .at-nav a .nv-d { display: block; grid-column: 2 / 4; font-size: 14px; color: var(--bp-dim); font-weight: 400; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  body.at.nav-open .v3-head .at-nav a[aria-current="page"] { border-color: var(--brass-light); background: rgba(232, 194, 122, 0.1); }
  body.at.nav-open .v3-head .at-nav a[aria-current="page"]::after { display: none; }
  body.at.nav-open .v3-head .at-tools { display: grid !important; grid-template-columns: auto auto 1fr; align-items: center; gap: 10px; border-left: 0; margin: 0; padding: 12px 0 8px; }
  body.at.nav-open .v3-head .at-tools .v3-find-m { grid-column: 1 / -1; order: -1; width: 100%; height: 46px; justify-content: flex-start; gap: 10px; padding: 0 14px; border-radius: 12px; font-size: 16.5px; }
  body.at.nav-open .v3-head .at-tools .v3-find-m .at-find-t { display: inline !important; }
  body.at.nav-open .v3-head .nv-set { display: block; font-size: 14px; color: var(--bp-dim); letter-spacing: .06em; }
  body.at.nav-open .v3-head .at-theme { justify-self: start; width: auto; padding: 0 12px; }
  body.at.nav-open .v3-head .at-theme span { display: inline; }
  body.at .v3-bottom { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}
body.at .v3-course > *, body.at .v3-main, body.at .v3-tools, body.at .v3-chips { min-width: 0; }
@media (max-width: 960px) { body.at .v3-course { align-items: stretch; } body.at .v3-course > * { width: auto; max-width: 100%; } }

/* ── 특별관 (#/special) ── */
body.at .sp-hero { background: radial-gradient(120% 140% at 85% 0%, #3a2466 0%, var(--bp) 55%); color: var(--bp-ink); margin: 0 calc(50% - 50vw); padding: 56px 16px 60px; }
body.at .sp-hero-in { max-width: 1180px; margin: 0 auto; padding: 0 28px; }
body.at .sp-hero h1 { margin: 10px 0 14px; font-size: clamp(30px, 4.4vw, 50px); line-height: 1.15; letter-spacing: -.01em; }
body.at .sp-hero p { margin: 0; max-width: 60ch; color: var(--bp-dim); font-size: 18.5px; line-height: 1.7; }
body.at .sp-hero .v3-eyebrow { color: var(--brass-light); }
body.at .sp-jump { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
body.at .sp-jump a { display: inline-flex; align-items: center; gap: 10px; padding: 12px 18px; border-radius: 12px; border: 1px solid rgba(234, 241, 251, .22); background: rgba(234, 241, 251, .07); color: var(--bp-ink); text-decoration: none; font-weight: 600; }
body.at .sp-jump a:hover { border-color: var(--brass-light); }
body.at .sp-jump a .ic { width: 18px; height: 18px; color: var(--brass-light); }
body.at .sp-jump b { font-family: var(--f-mono); font-size: 15px; padding: 2px 8px; border-radius: 999px; background: rgba(232, 194, 122, .18); color: var(--brass-light); }
body.at .sp-body { max-width: 1180px; margin: 0 auto; padding: 8px 28px 80px; }
body.at .sp-hall { padding-top: 48px; scroll-margin-top: 70px; }
body.at .sp-hall-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; padding-bottom: 18px; border-bottom: 3px solid var(--c); margin-bottom: 8px; }
body.at .sp-hall-head h2 { margin: 4px 0 8px; font-size: 31px; }
body.at .sp-hall-head p { margin: 0; color: var(--at-muted); max-width: 64ch; line-height: 1.65; }
body.at .sp-hall-head .v3-eyebrow { color: var(--c); }
body.at .sp-unit { display: flex; align-items: baseline; gap: 12px; margin: 30px 0 14px; font-size: 20.5px; }
body.at .sp-unit span { font-size: 14px; font-weight: 700; letter-spacing: .06em; color: var(--c); padding: 3px 9px; border-radius: 6px; background: color-mix(in srgb, var(--c) 12%, transparent); }
body.at .sp-unit small { margin-left: auto; font-size: 15px; color: var(--at-muted); font-weight: 500; }
@media (max-width: 760px) { body.at .sp-hero { padding: 36px 0 40px; } body.at .sp-hero-in, body.at .sp-body { padding-left: 16px; padding-right: 16px; } }
@media (max-width: 860px) { body.at.nav-open .v3-head .at-nav a:last-child { grid-column: 1 / -1; min-height: 60px; } }
body.at .v3-cgroup:last-child h3 { color: var(--brass); }
body.at .v3-ctile b { overflow-wrap: anywhere; }
@media (max-width: 1360px) and (min-width: 1181px) { body.at .v3-cgrid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* ── 첫 화면·배경 새 단장 (31차) ── */
/* 배경: 모눈 대신 차분한 단색 + 아주 옅은 점무늬 */
body.at { background-image: radial-gradient(color-mix(in srgb, var(--at-line) 70%, transparent) 1px, transparent 1.3px); background-size: 26px 26px; background-position: 0 0; }
body.at { overflow-x: clip; }
/* 남색 띠: 화면 끝까지, 모눈 대신 은은한 빛과 떠다니는 수식 */
body.at .v3-hero { position: relative; overflow: hidden; margin: 0 calc(50% - 50vw); background-image: radial-gradient(1100px 420px at 85% -10%, color-mix(in srgb, var(--brass) 22%, transparent), transparent 70%), radial-gradient(900px 500px at -10% 120%, rgba(90, 140, 255, 0.18), transparent 70%); background-size: auto; }
body.at .v3-hero-in { position: relative; z-index: 1; padding-top: 48px; padding-bottom: 52px; }
body.at .v3-hero-deco { position: absolute; inset: 0; color: var(--bp-ink); opacity: 0.12; pointer-events: none; }
body.at .v3-hero-deco svg { width: 100%; height: 100%; display: block; }
body.at .hd { transform-box: fill-box; transform-origin: center; animation: hdfloat 18s ease-in-out infinite; }
body.at .hd2 { animation-duration: 23s; animation-delay: -6s; } body.at .hd3 { animation-duration: 27s; animation-delay: -11s; }
body.at .hd4 { animation-duration: 21s; animation-delay: -3s; } body.at .hd5 { animation-duration: 25s; animation-delay: -15s; }
@keyframes hdfloat { 0%, 100% { transform: translate(0, 0) rotate(0deg); } 50% { transform: translate(18px, -14px) rotate(6deg); } }
@media (prefers-reduced-motion: reduce) { body.at .hd { animation: none; } }
body.at .v3-stats div { backdrop-filter: blur(6px); }
/* 아래 본문: 위아래로 차례대로 */
body.at .v3-home { display: flex; flex-direction: column; gap: 34px; padding-top: 32px; }
body.at .v3-sec-head { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
body.at .v3-sec-head span { font-size: 15px; color: var(--at-muted); }
body.at .v3-sec-head .v3-favs { margin-left: auto; color: var(--brass); font-weight: 600; }
/* 이어서 하기 / 처음이라면: 가로 띠 */
body.at .v3-resume { max-width: none; flex: none; gap: 0; display: block; }
body.at .v3-rcrow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
body.at .v3-rc { padding: 12px; gap: 14px; border-radius: 14px; background: var(--at-surface); border: 1px solid var(--at-line); box-shadow: inset 0 3px 0 var(--c, var(--brass)); transition: transform 0.15s, border-color 0.15s, box-shadow 0.15s; min-width: 0; }
body.at .v3-rc:hover { transform: translateY(-2px); border-color: var(--c, var(--brass)); box-shadow: inset 0 3px 0 var(--c, var(--brass)), var(--at-shadow); }
body.at .v3-rc-thumb { width: 92px; height: 62px; }
body.at .v3-rc-tx { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
body.at .v3-rc-tx b { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
body.at .v3-start { --c: var(--brass); }
body.at .v3-start .v3-rc-tx small { font-size: 14.5px; }
body.at .v3-start-ic { width: 46px; height: 46px; flex-shrink: 0; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--brass) 16%, transparent); color: var(--brass); }
body.at .v3-start-ic svg { width: 22px; height: 22px; }
/* 과정 고르기: 묶음마다 한 줄 */
body.at .v3-cgrid { display: flex; flex-direction: column; gap: 0; border: 1px solid var(--at-line); border-radius: 16px; background: var(--at-surface); overflow: hidden; }
body.at .v3-cgroup { display: grid; grid-template-columns: 132px minmax(0, 1fr); align-items: center; gap: 16px; padding: 14px 18px; border-top: 1px solid var(--at-line); }
body.at .v3-cgroup:first-child { border-top: 0; }
body.at .v3-cgroup h3 { margin: 0; font-size: 15px; letter-spacing: 0.02em; }
body.at .v3-ctiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(232px, 1fr)); gap: 10px; }
body.at .v3-ctile { flex-direction: row; align-items: center; gap: 12px; padding: 8px 12px 8px 8px; border-radius: 12px; background: var(--at-bg); box-shadow: none; border: 1px solid var(--at-line); }
body.at .v3-ctile:hover { box-shadow: var(--at-shadow); border-color: var(--c); }
body.at .v3-cgif { width: 56px; height: 56px; flex-shrink: 0; border-radius: 12px; display: block; box-shadow: 0 0 0 1px color-mix(in srgb, var(--c) 45%, transparent); }
body.at .v3-ctx { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
body.at .v3-ctx b { font-size: 16.5px; }
body.at .v3-ctx small { font-size: 14px; color: var(--at-muted); }
@media (max-width: 1100px) { body.at .v3-rcrow { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) {
  body.at .v3-rcrow { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 4px; }
  body.at .v3-rc { flex: 0 0 78%; scroll-snap-align: start; }
  body.at .v3-cgroup { grid-template-columns: 1fr; gap: 8px; padding: 12px; }
  body.at .v3-ctiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  body.at .v3-ctile { flex-direction: column; align-items: flex-start; padding: 10px; }
  body.at .v3-cgif { width: 48px; height: 48px; }
  body.at .v3-ctx b { font-size: 16px; }
}
body.at .v3-courses { flex: none; }
body.at .v3-home { flex-wrap: nowrap; }
@media (max-width: 720px) { body.at .v3-ctile { flex-direction: row; align-items: center; gap: 10px; padding: 8px; } body.at .v3-cgif { width: 44px; height: 44px; border-radius: 10px; } body.at .v3-ctx b { font-size: 15.5px; line-height: 1.3; } }
/* 숫자 칸(실험·과정·예측 문항) 이름표 크게 */
body.at .v3-stats div { padding: 16px 18px 14px; gap: 6px; }
body.at .v3-stats dt { font-size: 17.5px; font-weight: 700; color: var(--bp-ink); opacity: 0.88; letter-spacing: 0.01em; }
body.at .v3-stats dd { font-size: 45px; }
@media (max-width: 720px) { body.at .v3-stats dt { font-size: 16px; } body.at .v3-stats dd { font-size: 33px; } }
body.at .v3-stats { max-width: 540px; flex-basis: 420px; }
body.at .v3-stats dt { white-space: nowrap; overflow-wrap: normal; word-break: keep-all; }
html[lang="en"] body.at .v3-stats dt { font-size: 16.5px; }
@media (max-width: 720px) { html[lang="en"] body.at .v3-stats dt { font-size: 15px; } }
/* 숫자 칸: 가운데 정렬 + 빛남 */
@property --sg { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
body.at .v3-stats div { position: relative; align-items: center; text-align: center; justify-content: center; border-color: color-mix(in srgb, var(--brass) 45%, transparent); background: linear-gradient(160deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.03)); box-shadow: 0 0 22px color-mix(in srgb, var(--brass) 28%, transparent), inset 0 0 18px color-mix(in srgb, var(--brass) 12%, transparent); overflow: hidden; isolation: isolate; }
body.at .v3-stats div::before { content: ""; position: absolute; inset: -1px; border-radius: inherit; padding: 1.5px; background: conic-gradient(from var(--sg), transparent 0 70%, color-mix(in srgb, var(--brass) 95%, white) 82%, transparent 94%); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; animation: sgspin 5s linear infinite; pointer-events: none; z-index: -1; }
body.at .v3-stats div:nth-child(2)::before { animation-delay: -1.7s; } body.at .v3-stats div:nth-child(3)::before { animation-delay: -3.4s; }
body.at .v3-stats dd { color: #ffe7b3; text-shadow: 0 0 14px color-mix(in srgb, var(--brass) 75%, transparent), 0 0 32px color-mix(in srgb, var(--brass) 40%, transparent); animation: sgglow 3.6s ease-in-out infinite; }
body.at .v3-stats div:nth-child(2) dd { animation-delay: -1.2s; } body.at .v3-stats div:nth-child(3) dd { animation-delay: -2.4s; }
@keyframes sgspin { to { --sg: 360deg; } }
@keyframes sgglow { 0%, 100% { text-shadow: 0 0 12px color-mix(in srgb, var(--brass) 60%, transparent), 0 0 26px color-mix(in srgb, var(--brass) 30%, transparent); } 50% { text-shadow: 0 0 18px color-mix(in srgb, var(--brass) 90%, transparent), 0 0 42px color-mix(in srgb, var(--brass) 55%, transparent); } }
@media (prefers-reduced-motion: reduce) { body.at .v3-stats div::before, body.at .v3-stats dd { animation: none; } body.at .v3-stats div::before { background: color-mix(in srgb, var(--brass) 60%, transparent); } }
body.at .v3-stats { overflow: visible; }
body.at .v3-stats div { box-shadow: 0 0 26px color-mix(in srgb, var(--brass) 45%, transparent), 0 0 60px color-mix(in srgb, var(--brass) 18%, transparent), inset 0 0 22px color-mix(in srgb, var(--brass) 16%, transparent); border-color: color-mix(in srgb, var(--brass) 35%, transparent); }
body.at .v3-stats div::before { padding: 2px; background: conic-gradient(from var(--sg), transparent 0 62%, color-mix(in srgb, var(--brass) 70%, transparent) 74%, #fff6dc 82%, color-mix(in srgb, var(--brass) 70%, transparent) 90%, transparent 97%); }
@media (max-width: 720px) { body.at .v3-stats div { padding: 10px 6px; } html[lang="en"] body.at .v3-stats dt { font-size: 14px; } }
/* 금색 이름 정의 (첫 화면 새 단장에서 쓰는 --brass): 본문은 테마별 금색, 남색 띠 안은 밝은 금색 */
body.at { --brass: var(--at-brass); }
body.at .v3-hero { --brass: var(--brass-light); }
/* 머리글: 961~1279px에서는 검색을 돋보기만, 메뉴 간격 좁게 (글자를 키운 뒤에도 한 줄 유지) */
@media (min-width: 961px) and (max-width: 1279px) {
  body.at .v3-hsearch { flex: 0 0 auto; width: 44px; max-width: 44px; padding: 0; justify-content: center; margin-left: 14px; }
  body.at .v3-hsearch span, body.at .v3-hsearch kbd { display: none; }
  body.at .v3-head .at-nav { gap: 10px; }
  body.at .v3-head .at-nav a { font-size: 15.5px; }
}
@media (min-width: 961px) and (max-width: 1140px) { html[lang="en"] body.at .v3-head .at-nav a svg { display: none; } html[lang="en"] body.at .v3-head .at-nav { gap: 8px; } }
/* 영어 머리글: 메뉴 낱말이 길어서 1440px까지는 검색을 돋보기만 */
@media (min-width: 961px) and (max-width: 1440px) {
  html[lang="en"] body.at .v3-hsearch { flex: 0 0 auto; width: 44px; max-width: 44px; padding: 0; justify-content: center; margin-left: 14px; }
  html[lang="en"] body.at .v3-hsearch span, html[lang="en"] body.at .v3-hsearch kbd { display: none; }
  html[lang="en"] body.at .v3-head .at-nav { gap: 10px; }
}
@media (min-width: 961px) and (max-width: 1040px) { html[lang="en"] body.at .v3-head .at-nav a { font-size: 14.5px; } html[lang="en"] body.at .v3-head .at-nav { gap: 6px; } }
/* 머리글 검색칸·메뉴 글자는 늘 한 줄 */
body.at .v3-hsearch { min-width: 0; }
body.at .v3-hsearch span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
body.at .v3-hsearch kbd, body.at .v3-head .at-nav a { white-space: nowrap; }
@media (min-width: 1441px) { html[lang="en"] body.at .v3-head .at-nav { gap: 12px; } html[lang="en"] body.at .v3-hsearch { margin-left: 18px; } }
@media (min-width: 961px) and (max-width: 1010px) { html[lang="en"] body.at .v3-head .at-nav { gap: 2px; } html[lang="en"] body.at .v3-hsearch { margin-left: 8px; } }
body.at .sh-unit { flex-wrap: wrap; min-width: 0; max-width: 100%; } body.at .sh-unit select { min-width: 0; max-width: 100%; flex: 1 1 180px; }
body.at .v3-stats dt { font-size: 17px; } html[lang="en"] body.at .v3-stats dt { font-size: 15.5px; } @media (max-width: 720px) { body.at .v3-stats dt { font-size: 15px; } html[lang="en"] body.at .v3-stats dt { font-size: 13px; } }
body.at .v3-cgroup h3 { font-size: 18px; font-weight: 800; color: var(--at-ink); letter-spacing: 0; } body.at .v3-cgroup:last-child h3 { color: var(--brass); } body.at .v3-cgroup { grid-template-columns: 150px minmax(0, 1fr); } @media (max-width: 720px) { body.at .v3-cgroup h3 { font-size: 16px; } }
/* 공개판(Vercel)에서는 claude.ai에서만 되는 단추를 숨김 */ html.public [data-sh="ai"] { display: none !important; }

/* 첫 화면 '몇 학년인가요?' 띠와 '내 과정' */
body.at .v3-level { background: var(--at-surface); border: 1px solid var(--at-line); border-radius: 16px; padding: 18px 22px; box-shadow: inset 0 3px 0 var(--brass); }
body.at .v3-level .v3-sec-head { margin-bottom: 12px; }
body.at .v3-level-btns { display: flex; flex-wrap: wrap; gap: 10px; }
body.at .v3-level-btns button { font: inherit; font-size: 16px; font-weight: 700; min-width: 72px; padding: 10px 20px; border-radius: 999px; border: 1px solid var(--at-line); background: var(--at-bg); color: var(--at-ink); cursor: pointer; transition: border-color 0.15s, color 0.15s, transform 0.15s; }
body.at .v3-level-btns button:hover, body.at .v3-level-btns button:focus-visible { border-color: var(--brass); color: var(--brass); transform: translateY(-1px); }
body.at .v3-level-btns button[data-level="all"] { font-weight: 600; color: var(--at-muted); }
body.at .v3-mine { background: var(--at-surface); border: 1px solid var(--at-line); border-radius: 16px; padding: 16px 18px 18px; box-shadow: inset 0 3px 0 var(--brass); }
body.at .v3-mine .v3-sec-head span { color: var(--brass); font-weight: 600; }
body.at .v3-mine .v3-ctile { background: var(--at-bg); }
body.at .v3-level-change { margin-left: auto; font: inherit; font-size: 14px; color: var(--at-muted); background: none; border: 1px solid var(--at-line); border-radius: 999px; padding: 4px 12px; cursor: pointer; }
body.at .v3-level-change:hover { color: var(--brass); border-color: var(--brass); }
@media (max-width: 720px) {
  body.at .v3-level { padding: 14px; }
  body.at .v3-level-btns { gap: 8px; }
  body.at .v3-level-btns button { min-width: 0; flex: 1 0 calc(33% - 8px); padding: 10px 8px; font-size: 15px; }
  body.at .v3-mine { padding: 12px; }
}
