/* style.css — 1021214 CPS_TEST (CPS 미터) · 2026-09-26 REDESIGN
   출발점: DesignKit kit-playful (큰 라운드 · 통통한 누름 버튼 · Baloo 2 헤드라인 · 넉넉한 여백)
   → 평면·절제 변형: 컬러 그림자·그라디언트·블러·파스텔 다색 배지·바운스 애니메이션 전부 제거.
   무드: "큰 버튼 하나" 아케이드 — 가운데 정렬 단일 열, 잉크로 칠한 거대한 둥근 누름판,
   알약(pill) 칩·버튼, 둥근 수치 방울(bubble), Baloo 2 800 의 통통한 tabular 숫자.
   디자인 레퍼런스: figma.com (둥근 컴포넌트·굵은 검정 알약 버튼·큰 타이포) — 컬러는 걷어내고 형태만.
   색: 무채 잉크 1색 + 옅은 회색 면(--fill). 유일한 기능색: 더블클릭 점검의 "의심"(--bad). */
:root {
  --bg: #ffffff; --fill: #f2f2f0; --fill-2: #e6e6e3; --run: #2b2b2b;
  --ink: #141414; --ink-2: #525252; --ink-3: #8b8b88; --ink-inv: #ffffff;
  --line: #e4e4e1; --line-2: #cbcbc7;
  --bad: #c42b1f;
  --r-s: 12px; --r-m: 20px; --r-l: 28px; --r-xl: 40px; --pill: 999px;
  --disp: 'Baloo 2', 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Noto Sans', 'Noto Sans Arabic', sans-serif;
  --sans: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Noto Sans', 'Noto Sans Arabic', sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #121212; --fill: #1e1e1e; --fill-2: #2a2a2a; --run: #d6d6d2;
  --ink: #f0f0ed; --ink-2: #b9b9b5; --ink-3: #7e7e7a; --ink-inv: #121212;
  --line: #2a2a2a; --line-2: #3e3e3c;
  --bad: #ff8b80;
  color-scheme: dark;
}
[hidden] { display: none !important; }
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--sans); font-size: 16px; line-height: 1.65;
  -webkit-font-smoothing: antialiased; min-height: 100vh; display: flex; flex-direction: column; }
a { color: var(--ink); text-underline-offset: 3px; text-decoration-thickness: 1.5px; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
kbd { font-family: var(--sans); font-size: .74em; font-weight: 700; border: 1.5px solid currentColor; border-radius: 6px; padding: 0 5px; opacity: .75; }

/* ── header ── */
.top { background: var(--bg); }
.top-in { max-width: 1080px; margin: 0 auto; padding: 14px 16px; display: flex; align-items: center; gap: 18px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); white-space: nowrap; }
.mark { width: 38px; height: 38px; border-radius: 50%; background: var(--ink); color: var(--ink-inv); display: inline-grid; place-items: center;
  font-family: var(--disp); font-size: 11px; font-weight: 800; letter-spacing: .02em; line-height: 1; padding-top: 2px; }
.brand-t { font-family: var(--disp); font-weight: 800; font-size: 1.2rem; letter-spacing: -0.01em; }
.nav { display: flex; gap: 2px; padding: 4px; background: var(--fill); border-radius: var(--pill); }
.nav a { color: var(--ink-2); text-decoration: none; padding: 7px 15px; border-radius: var(--pill); font-size: .88rem; font-weight: 600; white-space: nowrap; }
.nav a:hover { color: var(--ink); background: var(--fill-2); }
.nav a[aria-current="page"] { background: var(--ink); color: var(--ink-inv); }
.top-tools { margin-inline-start: auto; display: flex; gap: 8px; align-items: center; }
.lang { height: 38px; border: 0; border-radius: var(--pill); background: var(--fill); padding: 0 14px; font-size: .84rem; font-weight: 600; max-width: 128px; cursor: pointer; }
.lang:hover { background: var(--fill-2); }
.theme-btn { width: 38px; height: 38px; border: 0; border-radius: 50%; background: var(--fill); display: grid; place-items: center; color: var(--ink); padding: 0; }
.theme-btn:hover { background: var(--fill-2); }
@media (max-width: 900px) {
  .top-in { flex-wrap: wrap; gap: 10px 12px; padding-bottom: 8px; }
  .nav { order: 3; width: 100%; overflow-x: auto; scrollbar-width: none; }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { flex: 0 0 auto; padding: 7px 13px; }
}

/* ── tool layout: 가운데 정렬 단일 열 ── */
.app { width: 100%; max-width: 780px; margin: 0 auto; padding: 22px 16px 44px; flex: 1; }
.ctl { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px 30px; margin-bottom: 22px; }
.ctl-row { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.ctl-k { font-size: .78rem; font-weight: 600; color: var(--ink-3); }
.ctl-hint { flex-basis: 100%; margin: 0; text-align: center; font-size: .84rem; color: var(--ink-3); }
.seg { display: inline-flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.seg-b { border: 0; border-radius: var(--pill); background: var(--fill); padding: 9px 17px; font-size: .9rem; font-weight: 700; color: var(--ink-2); min-width: 3.4em;
  transition: background .12s, color .12s, transform .12s; }
.seg-b:hover { background: var(--fill-2); color: var(--ink); }
.seg-b:active { transform: scale(.96); }
.seg-b[aria-pressed="true"] { background: var(--ink); color: var(--ink-inv); }
.seg.locked { opacity: .4; pointer-events: none; }

/* 수치 방울 4개 */
.meter { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.ro { background: var(--fill); border-radius: var(--r-m); padding: 14px 10px 12px; display: grid; gap: 4px; justify-items: center; text-align: center; min-width: 0; }
.ro-k { font-size: .74rem; font-weight: 600; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.ro-v { font-family: var(--disp); font-size: clamp(1.7rem, 5vw, 2.5rem); font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1; letter-spacing: -0.01em; }
@media (max-width: 560px) { .meter { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; } }

/* 눈금 트랙 (0~20 CPS) — 알약 모양 */
.tape { margin: 10px 0; height: 46px; padding: 8px 14px 0; background: var(--fill); border-radius: var(--pill); }
.tape svg { display: block; width: 100%; height: 100%; overflow: visible; }
.tape .tk { stroke: var(--ink-3); stroke-width: 1.5; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.tape .tk.maj { stroke: var(--ink); stroke-width: 2; }
.tape .tl { fill: var(--ink-3); font-family: var(--disp); font-weight: 700; font-size: 10px; }
.tape .nd { stroke: var(--ink); stroke-width: 6; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.tape .nd-avg { stroke: var(--ink-2); stroke-width: 2; stroke-dasharray: 2 4; stroke-linecap: round; vector-effect: non-scaling-stroke; }

/* 누름판 — 잉크로 칠한 큰 둥근 버튼 */
.pad { position: relative; border-radius: var(--r-xl); height: clamp(250px, 42vh, 380px); display: grid; place-content: center; justify-items: center; gap: 8px;
  text-align: center; cursor: pointer; background: var(--ink); color: var(--ink-inv); outline: none; padding: 20px;
  user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; touch-action: manipulation; -webkit-tap-highlight-color: transparent;
  transition: transform .06s ease-out, background .15s; }
.pad:active { transform: scale(.985); }
.pad:focus-visible { outline: 3px solid var(--ink); outline-offset: 4px; }
.pad-t { font-family: var(--disp); font-size: clamp(1.1rem, 3.4vw, 1.45rem); font-weight: 700; line-height: 1.3; }
.pad-sub { font-size: .86rem; opacity: .65; }
.pad-big { font-family: var(--disp); font-size: clamp(4rem, 17vw, 8rem); font-weight: 800; line-height: .9; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.pad-big:empty { display: none; }
.pad.running { background: var(--run); }
.pad.running .pad-t { opacity: .6; font-size: 1rem; }
.pad.done { cursor: default; background: var(--fill); color: var(--ink); }
.pad.done:active { transform: none; }

.shared { width: fit-content; max-width: 100%; margin: 0 auto 16px; padding: 8px 18px; border-radius: var(--pill); background: var(--fill); font-size: .88rem; font-weight: 600; color: var(--ink-2); text-align: center; }

/* 결과 카드 */
.result { margin-top: 18px; border: 2px solid var(--ink); border-radius: var(--r-l); padding: 28px 22px 20px; }
.res-head { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; }
.res-main { display: grid; grid-template-columns: auto auto; align-items: baseline; justify-content: center; column-gap: 8px; }
.res-main .ro-k { grid-column: 1 / -1; font-size: .82rem; }
#rAvg { font-family: var(--disp); font-size: clamp(3.6rem, 13vw, 6rem); font-weight: 800; line-height: 1; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.res-u { font-family: var(--disp); font-size: 1.15rem; font-weight: 700; color: var(--ink-3); }
.res-badge { margin: 0; font-size: .88rem; font-weight: 600; color: var(--ink-2); }
.res-badge:empty { display: none; }
.res-badge.best { background: var(--ink); color: var(--ink-inv); padding: 5px 14px; border-radius: var(--pill); }
.res-badge.best::before { content: '★ '; }
.res-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.btn-ink, .btn-line { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border-radius: var(--pill); padding: 11px 22px; font-size: .92rem; font-weight: 700;
  text-decoration: none; line-height: 1.25; transition: background .12s, transform .12s; }
.btn-ink { border: 2px solid var(--ink); background: var(--ink); color: var(--ink-inv); }
.btn-ink:hover { background: var(--ink-2); border-color: var(--ink-2); }
.btn-line { border: 2px solid var(--ink); background: transparent; color: var(--ink); }
.btn-line:hover { background: var(--fill); }
.btn-ink:active, .btn-line:active { transform: scale(.97); }
.btn-line.sm { padding: 5px 12px; font-size: .78rem; border-width: 1.5px; }
.btn-text { border: 0; background: none; padding: 6px 2px; font-size: .82rem; font-weight: 600; color: var(--ink-3); text-decoration: underline; text-underline-offset: 3px; }
.btn-text:hover { color: var(--ink); }

.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(138px, 1fr)); gap: 8px; margin: 22px 0 0; }
.st { background: var(--fill); border-radius: var(--r-m); padding: 12px 14px; }
.st dt { font-size: .74rem; font-weight: 600; color: var(--ink-3); line-height: 1.35; }
.st dt small { display: block; font-size: .7rem; font-weight: 500; }
.st dd { margin: 4px 0 0; font-family: var(--disp); font-size: 1.4rem; font-weight: 800; line-height: 1.1; font-variant-numeric: tabular-nums; }

.charts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
.chart { margin: 0; min-width: 0; background: var(--fill); border-radius: var(--r-m); padding: 14px 14px 8px; }
.chart figcaption { font-size: .78rem; font-weight: 700; color: var(--ink-2); margin-bottom: 8px; }
.chart figcaption small { font-weight: 500; color: var(--ink-3); }
.chart svg { display: block; width: 100%; height: 150px; overflow: visible; }
.chart .ax { stroke: var(--ink); stroke-width: 1.5; stroke-linecap: round; }
.chart .gr { stroke: var(--line-2); stroke-width: 1; stroke-dasharray: 2 4; }
.chart .bar { fill: var(--ink); rx: 3px; ry: 3px; }
.chart .ln { fill: none; stroke: var(--ink-2); stroke-width: 2; stroke-dasharray: 5 4; stroke-linecap: round; }
.chart text { fill: var(--ink-3); font-family: var(--disp); font-weight: 600; font-size: 10px; }
.chart text.v { fill: var(--ink); font-weight: 800; }
@media (max-width: 720px) { .charts { grid-template-columns: 1fr; } }
.acc { margin: 16px 0 0; font-size: .8rem; color: var(--ink-3); line-height: 1.6; text-align: center; }
.acc a { color: var(--ink-2); font-weight: 600; }

/* 기록 */
.records { margin-top: 40px; }
.sec-h { font-family: var(--disp); font-size: 1.3rem; font-weight: 800; letter-spacing: -0.01em; color: var(--ink); margin: 0 0 10px; }
.tbl { overflow-x: auto; border: 2px solid var(--line); border-radius: var(--r-m); margin: 0 0 12px; }
.tbl table { border-collapse: collapse; width: 100%; font-size: .9rem; }
.tbl th, .tbl td { padding: 10px 14px; border-bottom: 1px solid var(--line); text-align: start; vertical-align: middle; }
.tbl thead th { background: var(--fill); font-weight: 700; font-size: .76rem; color: var(--ink-2); white-space: nowrap; border-bottom: 0; }
.tbl tbody tr:last-child th, .tbl tbody tr:last-child td { border-bottom: 0; }
.tbl tbody th { font-weight: 600; }
.tbl td.n, .tbl .num { font-family: var(--disp); font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tbl tr.cur th, .tbl tr.cur td { background: var(--fill); }
.tbl tr.cur th::before { content: ''; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--ink); margin-inline-end: 8px; vertical-align: middle; }
.tbl .empty { color: var(--ink-3); font-size: .86rem; text-align: center; }
.spark { display: block; width: 120px; height: 22px; }
.spark polyline { fill: none; stroke: var(--ink); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.spark circle { fill: var(--ink); }

/* 키 연타 — 키캡 */
.ctl-row.slots { flex-direction: row; flex-wrap: wrap; justify-content: center; flex-basis: 100%; gap: 10px; }
.slot { display: inline-flex; align-items: center; gap: 10px; background: var(--fill); border-radius: var(--pill); padding: 6px 6px 6px 16px; }
.slot .ctl-k { min-width: 0; }
.kcap { display: inline-block; min-width: 3.2em; text-align: center; font-family: var(--disp); font-size: 1rem; font-weight: 800; padding: 3px 10px 1px; opacity: 1;
  background: var(--bg); border: 2px solid var(--ink); border-bottom-width: 5px; border-radius: 10px; }
.slot.wait .kcap { border-style: dashed; border-bottom-width: 2px; color: var(--ink-3); font-size: .8rem; }
.slot.off { opacity: .35; }

/* 더블클릭 점검 */
.pad-ch { height: clamp(220px, 34vh, 300px); }
.pad-ch.flash { background: var(--run); }
.pad-ch.flash-bad { box-shadow: inset 0 0 0 6px var(--bad); }
.verdict { width: fit-content; max-width: 100%; margin: 14px auto 0; padding: 9px 20px; border-radius: var(--pill); background: var(--fill); font-weight: 700; font-size: .92rem; text-align: center; }
.verdict.bad { color: var(--bad); box-shadow: inset 0 0 0 2px var(--bad); background: transparent; }
.warn { margin: 12px 0 0; font-size: .86rem; color: var(--ink-2); background: var(--fill); border-radius: var(--r-s); padding: 10px 14px; text-align: center; }
.ch-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 20px; margin-top: 26px; }
@media (max-width: 760px) { .ch-grid { grid-template-columns: 1fr; } }
.ch-dbl { font-size: .88rem; color: var(--ink-2); margin: 0 0 12px; }
.ch-dbl b { font-family: var(--disp); color: var(--ink); font-weight: 800; font-size: 1.05rem; }
.ch-t td[data-f="flagged"].on { color: var(--bad); font-weight: 800; }
.log { max-height: 340px; overflow-y: auto; }
.log td { font-size: .82rem; padding: 6px 12px; font-variant-numeric: tabular-nums; }
.log tr.bad td { color: var(--bad); font-weight: 600; }
.log td.flag { font-size: .74rem; font-weight: 700; }

/* ── ads (애드핏 규정: 래퍼에 radius·overflow 금지) ── */
.ad-wrap { margin: 32px auto 0; }
.ad-grid { display: flex; flex-direction: column; align-items: center; gap: 14px; width: 100%; max-width: 672px; margin: 0 auto; }
.ad-grid[data-ad-layout="mixed"] { max-width: 760px; }
.ad-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; width: 100%; }
.ad-cell { min-height: 50px; max-width: 100%; }
.ad-pc { display: none; }
@media (min-width: 720px) { .ad-pc { display: flex; } .ad-mo { display: none; } }
.prose .ad-wrap { margin: 36px 0; }

/* ── content pages ── */
.page { width: 100%; max-width: 720px; margin: 0 auto; padding: 22px 16px 52px; flex: 1; }
.crumb { font-size: .8rem; font-weight: 600; color: var(--ink-3); display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: 26px; }
.crumb a { color: var(--ink-2); text-decoration: none; background: var(--fill); padding: 3px 12px; border-radius: var(--pill); }
.crumb a:hover { background: var(--fill-2); color: var(--ink); }
.crumb .sep { color: var(--line-2); }
.kicker { display: inline-block; font-family: var(--disp); font-size: .78rem; font-weight: 800; letter-spacing: .06em; background: var(--ink); color: var(--ink-inv);
  padding: 3px 12px 1px; border-radius: var(--pill); margin: 0 0 14px; }
.prose { font-size: 1.02rem; line-height: 1.85; }
.prose h1, .page-h { font-family: var(--disp); font-size: clamp(1.8rem, 5.2vw, 2.6rem); line-height: 1.18; letter-spacing: -0.015em; margin: 0 0 16px; font-weight: 800; }
.prose h2 { font-family: var(--disp); font-size: 1.36rem; line-height: 1.3; margin: 44px 0 12px; letter-spacing: -0.01em; font-weight: 800; display: flex; align-items: baseline; gap: 10px; }
.prose h2::before { content: ''; flex: 0 0 10px; width: 10px; height: 10px; border-radius: 50%; background: var(--ink); transform: translateY(-2px); }
.prose p { margin: 0 0 15px; }
.prose ul, .prose ol { padding-inline-start: 1.35em; margin: 0 0 18px; }
.prose li { margin: 6px 0; }
.prose li::marker { color: var(--ink-3); font-weight: 700; }
.prose code { font-family: var(--mono); font-size: .86em; background: var(--fill); padding: 1px 7px; border-radius: 6px; }
.prose strong { font-weight: 700; }
.lead { color: var(--ink-2); font-size: 1.1rem; line-height: 1.7; }
.formula { font-family: var(--mono); font-size: .92rem; background: var(--fill); border-radius: var(--r-m); padding: 14px 18px; }
.prose .tbl td { font-variant-numeric: tabular-nums; }
.cta { margin-top: 32px; }
.faq { background: var(--fill); border-radius: var(--r-m); padding: 0; margin: 8px 0; }
.faq summary { cursor: pointer; font-weight: 700; list-style: none; padding: 15px 52px 15px 20px; position: relative; }
[dir="rtl"] .faq summary { padding: 15px 20px 15px 52px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; position: absolute; inset-inline-end: 14px; top: 50%; transform: translateY(-50%); width: 28px; height: 28px; border-radius: 50%;
  background: var(--bg); display: grid; place-items: center; font-family: var(--disp); font-weight: 800; font-size: 1.1rem; line-height: 1; }
.faq[open] summary::after { content: '−'; background: var(--ink); color: var(--ink-inv); }
.faq p { margin: 0; padding: 0 20px 16px; color: var(--ink-2); }
.mail { font-size: 1rem; background: var(--fill); border-radius: var(--pill); padding: 10px 20px; width: fit-content; max-width: 100%; overflow-wrap: anywhere; }
.mail span { color: var(--ink-3); margin-inline-end: 8px; font-weight: 600; }
.related { margin-top: 40px; background: var(--fill); border-radius: var(--r-l); padding: 20px 22px 8px; }
.related h2 { font-size: 1.05rem; margin: 0 0 6px; }
.related h2::before { display: none; }
.related ul { padding-inline-start: 1.1em; }

.glist { list-style: none; padding: 0; margin: 26px 0 8px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 600px) { .glist { grid-template-columns: 1fr; } }
.gl { display: grid; grid-template-columns: 40px 1fr; column-gap: 14px; padding: 18px; height: 100%; text-decoration: none; color: var(--ink);
  background: var(--fill); border-radius: var(--r-l); transition: background .12s, transform .12s; }
.gl:hover { background: var(--fill-2); transform: translateY(-2px); }
.gl-n { grid-row: 1 / 3; width: 40px; height: 40px; border-radius: 50%; background: var(--ink); color: var(--ink-inv); display: grid; place-items: center;
  font-family: var(--disp); font-size: .95rem; font-weight: 800; padding-top: 2px; }
.gl-t { font-weight: 700; line-height: 1.45; }
.gl-d { color: var(--ink-2); font-size: .88rem; line-height: 1.55; margin-top: 4px; }

.nf { text-align: center; padding-top: 30px; }
.nf-code { font-family: var(--disp); font-size: clamp(6rem, 26vw, 10rem); font-weight: 800; margin: 0; line-height: 1; letter-spacing: -0.03em; }
.nf h1 { font-size: 1.6rem; }
.nf-langs { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 26px; font-size: .88rem; }
.nf-langs a { text-decoration: none; background: var(--fill); padding: 5px 14px; border-radius: var(--pill); font-weight: 600; }
.nf-langs a:hover { background: var(--fill-2); }

/* ── footer: 둥근 윗면의 회색 판 ── */
.foot { background: var(--fill); border-radius: var(--r-xl) var(--r-xl) 0 0; margin-top: 36px; }
.foot-in { max-width: 1080px; margin: 0 auto; padding: 30px 20px 34px; display: grid; gap: 14px; justify-items: center; text-align: center; }
.foot-main, .foot-guides { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 18px; }
.foot-main a { color: var(--ink); text-decoration: none; font-size: .88rem; font-weight: 700; }
.foot-guides a { color: var(--ink-2); text-decoration: none; font-size: .82rem; }
.foot a:hover { text-decoration: underline; }
.copyright { margin: 4px 0 0; font-size: .76rem; color: var(--ink-3); }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 16px); background: var(--ink); color: var(--ink-inv); padding: 10px 20px; border-radius: var(--pill);
  font-size: .88rem; font-weight: 600; opacity: 0; pointer-events: none; transition: opacity .16s, transform .16s; z-index: 50; max-width: calc(100% - 32px); text-align: center; }
.toast.on { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 480px) {
  .app { padding-top: 16px; }
  .ctl { gap: 12px; }
  .seg-b { padding: 8px 13px; font-size: .86rem; }
  .result { padding: 22px 14px 16px; border-radius: var(--r-m); }
  .pad { border-radius: var(--r-l); }
}
@media (prefers-reduced-motion: reduce) {
  .pad, .seg-b, .btn-ink, .btn-line, .gl, .toast { transition: none; }
}

/* RTL: 숫자·단위는 LTR 유지 */
[dir="rtl"] .ro-v, [dir="rtl"] #rAvg, [dir="rtl"] .st dd, [dir="rtl"] .pad-big { direction: ltr; unicode-bidi: isolate; }
[dir="rtl"] .kicker { letter-spacing: 0; }
