/* Linear식 무채색 화면(2026-10-19 사무엘님 지시: "Linear스럽게, 무채색 위주, 파랑은 포인트에만").
   값은 Linear 다크 화면 실제 값을 기준으로 함(바탕 #08090A·글자 #F7F8F8/#8A8F98·모서리 6~8). 파랑은 주 단추·선택 표시·그래프 주 선에만 쓴다.
   좋음·보통·주의 같은 상태는 색 점 하나로만 나타내고 글자·바탕은 무채색을 유지한다. */
:root {
  --bg-page: #08090A; --bg-rail: #0B0C0D; --bg-surface: #0F1011; --bg-subtle: #16171A; --bg-hover: #1C1D21; --bg-selected: #1F2024; --bg-raised: #141518;
  --border: rgba(255, 255, 255, .06); --border-strong: rgba(255, 255, 255, .11);
  --text: #F7F8F8; --text-2: #D0D6E0; --text-3: #8A8F98; --text-4: #80858E; --text-on-accent: #FFFFFF; --text-accent: #7AA2FF;
  --accent: #3B6CEC; --accent-hover: #3461DA; --accent-soft: rgba(62, 111, 240, .14);
  --good: #4CB782; --good-soft: rgba(76, 183, 130, .12); --good-solid: #4CB782;
  --mid: #E2B340; --mid-soft: rgba(226, 179, 64, .12);
  --gauge-2: #E0823D; --gauge-4: #8FBF5A; --bad: #EB5757; --bad-soft: rgba(235, 87, 87, .12);
  --c1: #5B8DEF; --c2: #8A8F98; --c3: #C9CDD4; --c4: #4CB782; --grid: rgba(255, 255, 255, .05);
  --glass: rgba(8, 9, 10, .72); --glass-raised: rgba(22, 23, 26, .78);
  --r-sm: 6px; --r-md: 8px; --r-lg: 10px; --r-pill: 999px;
  --side-w: 232px; --pad-x: 32px;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: 'IBM Plex Sans', Pretendard, -apple-system, 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  font-size: 13px; line-height: 1.5; color: var(--text); background: var(--bg-page); -webkit-font-smoothing: antialiased;
}
button, input, textarea { font: inherit; color: inherit; }
a { color: var(--text-2); text-decoration: none; }
svg.i { width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

/* 왼쪽 메뉴 — Linear처럼 묶음 이름 아래 글자 달린 항목 */
.side {
  position: fixed; inset: 0 auto 0 0; width: var(--side-w); padding: 12px 10px; display: flex; flex-direction: column; gap: 1px;
  background: var(--bg-rail); border-right: 1px solid var(--border); z-index: 6; overflow-y: auto; scrollbar-width: none;
}
.logo { display: flex; align-items: center; gap: 10px; padding: 4px 8px 14px; font-weight: 600; font-size: 13px; color: var(--text); }
.logo-mark { width: 22px; height: 22px; border-radius: 6px; background: var(--accent); color: #fff; display: grid; place-items: center; flex: none; }
.logo-mark svg.i { width: 13px; height: 13px; }
.group { padding: 14px 8px 4px; font-size: 12px; font-weight: 500; color: var(--text-4); }
.nav { display: flex; align-items: center; gap: 10px; padding: 0 8px; height: 30px; border-radius: var(--r-sm); color: var(--text-3); cursor: pointer; font-weight: 500; white-space: nowrap; }
.nav .ic { display: grid; place-items: center; position: relative; }
.nav .ic[data-dot="1"]::after { content: ''; position: absolute; top: -2px; right: -3px; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.nav .sh { display: none; }
.nav:hover { background: var(--bg-hover); color: var(--text-2); }
.nav.on { background: var(--bg-selected); color: var(--text); }
.nav.on .ic { color: var(--text); }
.nav.on:hover { background: #26272C; }
.side .grow { flex: 1; min-height: 12px; }
.side-card { display: none; }
main { margin-left: var(--side-w); padding: 0 var(--pad-x) 56px; display: flex; flex-direction: column; gap: 16px; min-height: 100vh; }
.icon-btn.menu-btn { display: none; }

/* 위쪽 고정 줄: 제목·검색·탭이 붙어 있고 본문은 그 뒤로 지나간다(떠 있는 것은 반투명 + 흐림) */
.topbar {
  position: sticky; top: 0; z-index: 5; margin: 0 calc(-1 * var(--pad-x)); padding: 18px var(--pad-x) 12px;
  display: flex; flex-direction: column; gap: 12px;
  background: var(--glass); -webkit-backdrop-filter: blur(16px) saturate(140%); backdrop-filter: blur(16px) saturate(140%);
  border-bottom: 1px solid var(--border);
}

/* 글자 */
h1 { margin: 0; font-size: 18px; line-height: 26px; font-weight: 600; letter-spacing: -0.01em; }
.lead { margin: 2px 0 0; color: var(--text-3); }
h2 { margin: 0; font-size: 14px; line-height: 20px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
h2 svg.i { width: 14px; height: 14px; color: var(--text-4); }
.muted { color: var(--text-3); font-size: 12px; }
.head-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.head-row.between { justify-content: space-between; }

/* 부품 */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 32px; padding: 0 14px; border-radius: var(--r-sm);
  font-weight: 500; border: 1px solid transparent; cursor: pointer; white-space: nowrap; background: var(--accent); color: var(--text-on-accent);
}
.btn:hover { background: var(--accent-hover); }
.btn.sub { background: var(--bg-subtle); color: var(--text-2); border-color: var(--border-strong); }
.btn.sub:hover { background: var(--bg-hover); color: var(--text); }
.btn:disabled { opacity: .5; cursor: default; }
.btn.small { height: 28px; padding: 0 10px; font-size: 12px; }
.search {
  display: flex; align-items: center; gap: 8px; flex: 1; min-width: 200px; height: 36px; padding: 0 12px; border-radius: var(--r-md);
  background: var(--bg-surface); border: 1px solid var(--border-strong);
}
.search:hover { border-color: rgba(255, 255, 255, .18); }
.search:focus-within { border-color: rgba(122, 162, 255, .55); box-shadow: 0 0 0 3px rgba(62, 111, 240, .14); }
.search:focus-within:hover { border-color: rgba(122, 162, 255, .8); }
.search svg.i { color: var(--text-4); }
.search input { flex: 1; border: 0; outline: 0; background: transparent; min-width: 0; font-size: 13px; }
.search input::placeholder, textarea::placeholder { color: var(--text-4); }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.panel { background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 16px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.panel.flush { padding: 14px 0 6px; gap: 0; }
.panel.flush > .head-row, .panel.flush > .note, .panel.flush > .hint-wrap { padding: 0 16px 10px; }
.hint-wrap { display: flex; justify-content: flex-start; }
.hint { display: inline-block; color: var(--text-4); font-size: 12px; }
.cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.card { background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.card .lab { font-size: 12px; color: var(--text-3); display: flex; align-items: center; gap: 4px; }
.card .lab svg.i { width: 12px; height: 12px; color: var(--text-4); }
.card .val { font-size: 22px; line-height: 30px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -0.01em; }
.card .val.good, .card .val.mid, .card .val.bad { color: var(--text); }
.card .val.good::before, .card .val.mid::before, .card .val.bad::before { content: ''; display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin: 0 8px 4px 0; vertical-align: middle; }
.card .val.good::before { background: var(--good); } .card .val.mid::before { background: var(--mid); } .card .val.bad::before { background: var(--bad); }
.card .sub { font-size: 12px; color: var(--text-4); }
/* 상태 표시: 무채색 알약 + 색 점 하나 */
.chip { display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 8px; border-radius: var(--r-pill); font-size: 12px; font-weight: 500; white-space: nowrap; background: var(--bg-subtle); color: var(--text-2); border: 1px solid var(--border); }
.chip.good::before, .chip.mid::before, .chip.bad::before { content: ''; width: 6px; height: 6px; border-radius: 50%; flex: none; }
.chip.good::before { background: var(--good); } .chip.mid::before { background: var(--mid); } .chip.bad::before { background: var(--bad); }
.chip.none { color: var(--text-4); }
.badge { display: inline-flex; min-width: 34px; justify-content: center; align-items: center; gap: 5px; height: 22px; padding: 0 7px; border-radius: var(--r-sm); font-weight: 500; font-size: 12px; font-variant-numeric: tabular-nums; background: var(--bg-subtle); color: var(--text); border: 1px solid var(--border); }
.badge.good::before, .badge.mid::before, .badge.bad::before { content: ''; width: 6px; height: 6px; border-radius: 50%; flex: none; }
.badge.good::before { background: var(--good); } .badge.mid::before { background: var(--mid); } .badge.bad::before { background: var(--bad); }
.badge.none { color: var(--text-4); }
.tag { display: inline-flex; align-items: center; gap: 8px; height: 28px; padding: 0 10px; border-radius: var(--r-sm); background: var(--bg-subtle); border: 1px solid var(--border); font-size: 12px; color: var(--text-2); cursor: pointer; }
.tag.plain { color: var(--text-2); }
.tag:hover { background: var(--bg-hover); color: var(--text); }
.tag.plain.on { background: var(--bg-selected); color: var(--text); border-color: var(--border-strong); }
.tag.plain.on:hover { background: #26272C; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.two { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 12px; align-items: start; }
.stack { display: flex; flex-direction: column; gap: 12px; min-width: 0; }

/* 탭: Linear 위쪽 보기 전환처럼 무채색, 고른 것만 한 단 밝게 */
.tabs { display: inline-flex; flex-wrap: wrap; gap: 2px; align-self: flex-start; }
.tabs button, .tabs a { border: 1px solid transparent; background: transparent; height: 28px; padding: 0 10px; display: inline-flex; align-items: center; border-radius: var(--r-sm); cursor: pointer; color: var(--text-3); font-weight: 500; font-size: 12px; }
.tabs .on { background: var(--bg-selected); color: var(--text); border-color: var(--border-strong); }
.tabs :is(a, button):not(.on):hover { color: var(--text); background: var(--bg-hover); }
.tabs .on:hover { background: #26272C; }

/* 표: 바탕 없는 머리줄과 얇은 줄 */
table { width: 100%; border-collapse: separate; border-spacing: 0; }
th { white-space: nowrap; text-align: left; font-size: 12px; font-weight: 500; color: var(--text-4); padding: 8px 10px; border-bottom: 1px solid var(--border); }
.tbl { padding: 0; overflow-x: auto; }
tr.click:focus-visible, .idea:focus-visible { outline: 2px solid var(--accent, #3E6FF0); outline-offset: -2px; }
td { padding: 9px 10px; border-bottom: 1px solid var(--border); }
tr:last-child td { border-bottom: 0; }
th:first-child, td:first-child { padding-left: 16px; }
th:last-child, td:last-child { padding-right: 16px; }
td.kw { font-weight: 500; color: var(--text); word-break: keep-all; }
td a:hover { text-decoration: underline; color: var(--text); }
input[type=checkbox] { accent-color: var(--accent); cursor: pointer; opacity: .7; }
input[type=checkbox]:hover { opacity: 1; }
.num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ctr { text-align: center; }
tr.click { cursor: pointer; } tr.click:hover td { background: var(--bg-raised); }
.icon-btn { border: 0; background: transparent; color: var(--text-4); padding: 5px; border-radius: var(--r-sm); cursor: pointer; display: inline-grid; place-items: center; }
.icon-btn svg.i { width: 15px; height: 15px; }
.icon-btn:hover { background: var(--bg-hover); color: var(--text); }
.icon-btn.on { color: var(--text-accent); }
.icon-btn.on svg.i { fill: currentColor; }
.more { display: flex; justify-content: center; padding: 10px 0 4px; }
.sort { border: 0; background: transparent; padding: 0; min-height: 24px; font: inherit; color: inherit; cursor: pointer; white-space: nowrap; }
.sort:hover { color: var(--text); }
.sort::after { content: '↕'; margin-left: 4px; opacity: .45; }
.sort[data-dir="up"]::after { content: '↑'; opacity: 1; } .sort[data-dir="down"]::after { content: '↓'; opacity: 1; }

/* 점수 바늘 — 좋고 나쁨을 읽는 신호라 색을 남김(채도만 낮춤) */
.overview { display: grid; grid-template-columns: minmax(0, 1fr); justify-items: center; gap: 6px; padding-bottom: 6px; }
.overview h3 { justify-self: start; margin: 0 0 4px; font-size: 14px; font-weight: 600; }
.gauge { width: 240px; height: 150px; position: relative; }
.gauge svg { width: 240px; height: 150px; overflow: visible; }
.gauge .score { position: absolute; left: 50%; top: 58px; transform: translateX(-50%); width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; font-size: 20px; font-weight: 600; background: var(--bg-subtle); color: var(--text); border: 2px solid var(--border-strong); }
.gauge .score.good { border-color: var(--good); } .gauge .score.mid { border-color: var(--mid); } .gauge .score.bad { border-color: var(--bad); } .gauge .score.none { color: var(--text-4); }
.gauge .cap { position: absolute; left: 0; right: 0; top: 120px; text-align: center; font-size: 11px; font-weight: 500; color: var(--text-4); line-height: 1.3; }
.gauge .cap b { display: block; font-size: 12px; color: var(--text-2); font-weight: 500; }
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; width: 100%; max-width: 420px; text-align: center; margin-top: 8px; }
.stats .lab { color: var(--text-3); font-size: 12px; }
.stats .val { font-size: 22px; font-weight: 600; line-height: 30px; font-variant-numeric: tabular-nums; }

/* 영상 */
.vids { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.vcard { display: flex; flex-direction: column; gap: 6px; color: inherit; min-width: 0; padding: 6px; margin: -6px; border-radius: var(--r-md); }
.vcard:hover { background: var(--bg-hover); }
.vcard img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--r-sm); background: var(--bg-subtle); }
.vcard .t { font-weight: 500; color: var(--text); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.4; }
.vcard .m { font-size: 12px; color: var(--text-4); }
.vcard .g { font-size: 12px; font-weight: 500; color: var(--text-3); }
.vid { display: flex; gap: 10px; padding: 8px 6px; margin: 0 -6px; color: inherit; border-radius: var(--r-md); }
.vid:hover { background: var(--bg-hover); }
.vid img { width: 88px; height: 50px; border-radius: var(--r-sm); object-fit: cover; background: var(--bg-subtle); flex: none; }
.vid .t { font-weight: 500; color: var(--text); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.vid .m { font-size: 12px; color: var(--text-4); }

/* 그래프 */
.chart svg { width: 100%; height: 170px; display: block; overflow: visible; }
.chart .grid { stroke: var(--grid); stroke-width: 1; }
.chart .ln.anchor { stroke-width: 1.25; opacity: .6; }
.chart .ln { fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.axis { display: flex; justify-content: space-between; font-size: 11px; color: var(--text-4); margin-top: 6px; }
.legend { display: flex; flex-wrap: wrap; gap: 14px; font-size: 12px; color: var(--text-3); }
.dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; margin-right: 6px; vertical-align: 1px; }
.kchip { display: inline-flex; align-items: center; gap: 8px; height: 28px; padding: 0 6px 0 10px; border-radius: var(--r-sm); background: var(--bg-subtle); border: 1px solid var(--border-strong); font-weight: 500; font-size: 12px; }
.kchip .x { border: 0; background: transparent; color: var(--text-4); cursor: pointer; width: 24px; height: 24px; border-radius: var(--r-sm); display: grid; place-items: center; padding: 0; }
.kchip .x svg.i { width: 14px; height: 14px; }
.kchip .x:hover { background: var(--bg-hover); color: var(--text); }

/* 상태 */
.empty { padding: 36px 16px; text-align: center; color: var(--text-4); }
.err { padding: 12px 14px; border-radius: var(--r-md); background: var(--bad-soft); color: #F2A0A0; border: 1px solid rgba(235, 87, 87, .2); }
.skel { background: linear-gradient(90deg, var(--bg-surface), var(--bg-subtle), var(--bg-surface)); background-size: 200% 100%; animation: sh 1.2s infinite; border-radius: var(--r-lg); }
@keyframes sh { to { background-position: -200% 0; } }
.idea { padding: 12px 14px; border-radius: var(--r-md); background: var(--bg-subtle); cursor: pointer; border: 1px solid var(--border); }
.idea:hover { background: var(--bg-hover); }
.idea .t { font-weight: 500; } .idea .m { font-size: 12px; color: var(--text-3); }
textarea { width: 100%; min-height: 88px; resize: vertical; padding: 10px 12px; border-radius: var(--r-md); border: 1px solid var(--border-strong); background: var(--bg-surface); outline: 0; font-size: 13px; }
textarea:hover { border-color: rgba(255, 255, 255, .18); }
textarea:focus { border-color: rgba(122, 162, 255, .55); }
.label { font-size: 12px; font-weight: 500; color: var(--text-3); }
.cand { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--r-md); background: var(--bg-raised); }
.cand .t { font-weight: 500; } .cand .m { font-size: 12px; color: var(--text-4); }
.cand > div { flex: 1; min-width: 0; }
.seg { display: inline-flex; padding: 2px; border-radius: var(--r-md); background: var(--bg-subtle); gap: 2px; }
.seg button { border: 0; background: transparent; padding: 5px 12px; border-radius: var(--r-sm); cursor: pointer; color: var(--text-3); }
.seg button.on { background: var(--bg-selected); color: var(--text); }
details.how summary { cursor: pointer; color: var(--text-4); font-size: 12px; display: inline-block; }
details.how summary:hover { color: var(--text-2); }
details.how p { margin: 8px 0 0; color: var(--text-3); font-size: 12px; max-width: 600px; }

/* 떠 있는 것: 모두 반투명 + 배경 흐림 */
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); padding: 8px 14px; border-radius: var(--r-md); background: var(--glass-raised); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); border: 1px solid var(--border-strong); color: var(--text); font-size: 12px; font-weight: 500; z-index: 20; opacity: 0; transition: opacity .2s; pointer-events: none; }
.toast.show { opacity: 1; }
.selbar { position: fixed; left: calc(50% + var(--side-w) / 2); bottom: 20px; transform: translateX(-50%); display: flex; align-items: center; gap: 6px; padding: 6px 6px 6px 14px; border-radius: var(--r-lg);
  background: var(--glass-raised); -webkit-backdrop-filter: blur(20px) saturate(140%); backdrop-filter: blur(20px) saturate(140%); border: 1px solid var(--border-strong); z-index: 15; max-width: calc(100vw - var(--side-w) - 32px); flex-wrap: wrap; box-shadow: 0 8px 24px rgba(0, 0, 0, .4); }
.selbar .cnt { font-weight: 600; margin-right: 4px; }
body.has-selbar main { padding-bottom: 120px; }

/* 기능 화면 */
.ideas { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.idea-card { gap: 8px; }
.idea-card h2 { font-size: 14px !important; }
.pbar { height: 6px; border-radius: 999px; background: var(--bg-subtle); overflow: hidden; }
.pbar i { display: block; height: 100%; border-radius: 999px; background: var(--text-3); }
.pbar i.good { background: var(--accent); }
.hbars { display: flex; align-items: flex-end; gap: 2px; height: 130px; }
.hbars i { flex: 1; background: var(--c1); border-radius: 2px 2px 0 0; min-height: 2px; opacity: .85; }
.areas { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.grade { min-width: 30px; height: 26px; padding: 0 8px; border-radius: var(--r-sm); display: inline-flex; align-items: center; justify-content: center; gap: 6px; font-weight: 600; font-size: 13px; background: var(--bg-subtle); border: 1px solid var(--border); color: var(--text); }
.grade.good::before, .grade.mid::before, .grade.bad::before { content: ''; width: 6px; height: 6px; border-radius: 50%; }
.grade.good::before { background: var(--good); } .grade.mid::before { background: var(--mid); } .grade.bad::before { background: var(--bad); }
.grade.none { color: var(--text-4); }
.facts { margin: 0; padding-left: 16px; color: var(--text-3); display: flex; flex-direction: column; gap: 3px; }
.tip { padding: 10px 12px; border-radius: var(--r-md); background: var(--bg-raised); border: 1px solid var(--border); color: var(--text-2); font-size: 12px; }
.check { display: flex; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--border); }
.check:last-child { border-bottom: 0; }
.check .mark { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-weight: 600; flex: none; font-size: 11px; background: var(--bg-subtle); border: 1px solid var(--border-strong); }
.check.ok .mark { color: var(--good); } .check.no .mark { color: var(--bad); }
.check .t { font-weight: 500; }
.heatwrap { overflow-x: auto; }
.heat { border-collapse: separate; border-spacing: 3px; width: 100%; min-width: 520px; table-layout: fixed; }
.heat th { background: transparent; padding: 4px; text-align: center; font-size: 11px; border: 0; }
.heat td.hc { height: 36px; border-radius: 6px; text-align: center; font-weight: 500; font-size: 12px; padding: 0; border: 0; color: var(--text); }
.heat td.hc.empty { background: var(--bg-subtle); }
.goals { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 24px; }
.goal { display: flex; flex-direction: column; gap: 6px; }
.badges { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; }
.ach { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: var(--r-md); background: var(--bg-raised); border: 1px solid var(--border); }
.ach .t { font-weight: 500; }
.medal { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--bg-subtle); color: var(--text-2); flex: none; border: 1px solid var(--border-strong); }
tr.unread td .kw { font-weight: 600; }
tr.unread td .kw::before { content: ''; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); margin-right: 6px; vertical-align: middle; }

/* 큰 화면(1600~4K): 칸 수를 늘리고, 2400 넘으면 화면 전체를 키워 글자가 작아 보이지 않게 */
@media (min-width: 1600px) {
  .vids { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .ideas { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 1920px) {
  :root { --pad-x: 48px; }
  .vids { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .areas { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 2400px) { body { zoom: 1.25; } }
@media (min-width: 3200px) { body { zoom: 1.5; } }

/* 두 칸 묶음은 본문 폭이 충분할 때만(왼쪽 메뉴 232 빼고 약 1100 이상) */
@media (max-width: 1400px) { .two { grid-template-columns: minmax(0, 1fr); } }
.clamp2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* 중간 화면 */
@media (max-width: 1180px) {
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .two { grid-template-columns: minmax(0, 1fr); }
  .vids { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .ideas, .areas { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 960px) {
  :root { --side-w: 64px; }
  .side .lb, .side .group, .logo-text { display: none; }
  .side { padding: 12px 8px; align-items: stretch; }
  .logo { justify-content: center; padding: 4px 0 12px; }
  .nav { justify-content: center; padding: 0; height: 36px; }
  .vids { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
/* 휴대폰: 왼쪽 메뉴는 아래 탭(반투명·흐림, 옆으로 밀어 더 보기) */
@media (max-width: 640px) {
  :root { --side-w: 0px; --pad-x: 16px; }
  .side { inset: auto 0 0 0; width: auto; height: 60px; flex-direction: row; padding: 4px; border-right: 0; border-top: 1px solid var(--border); gap: 0;
    background: var(--glass); -webkit-backdrop-filter: blur(20px) saturate(140%); backdrop-filter: blur(20px) saturate(140%); overflow-x: auto; overflow-y: hidden; }
  .side .logo, .side .grow, .side .group, .side .lb { display: none; }
  .nav { flex: 1 1 0; min-width: 0; flex-direction: column; justify-content: center; gap: 3px; height: 52px; padding: 0; font-size: 12px; }
  .side { overflow: visible; }
  .side > .nav:not(.pin):not(.more-btn) { display: none; }
  .side > .more-btn { display: flex; }
  body.more-open .side { height: auto; flex-wrap: wrap; padding: 10px 6px calc(8px + env(safe-area-inset-bottom, 0px)); background: var(--glass-raised); }
  body.more-open .side > .nav, body.more-open .side > .nav:not(.pin):not(.more-btn) { display: flex; flex: 0 0 25%; }
  body.more-open .side > .more-btn { order: 99; }
  .icon-btn { min-width: 40px; min-height: 40px; }
  .kchip .x { width: 44px; height: 44px; }
  .tabs a, .tag, .btn.small { min-height: 36px; display: inline-flex; align-items: center; }
  input[type=checkbox] { width: 20px; height: 20px; }
  .axis, .gauge .cap { font-size: 12px; }
  td.kw { white-space: nowrap; }
  .nav .sh { display: block; }
  main { padding-bottom: 90px; gap: 14px; }
  .topbar { padding-top: 12px; }
  .cards { grid-template-columns: minmax(0, 1fr); }
  .card .val { font-size: 20px; }
  .panel { padding: 14px; }
  .panel.flush > .head-row, .panel.flush > .note, .panel.flush > .hint-wrap { padding: 0 14px 10px; }
  th.hide-s, td.hide-s { display: none; }
  th:first-child, td:first-child { padding-left: 12px; } th:last-child, td:last-child { padding-right: 12px; }
  .axis .odd { display: none; }
  .vids, .ideas, .areas, .goals { grid-template-columns: minmax(0, 1fr); }
  .heat { min-width: 0; border-spacing: 2px; }
  .heat td.hc { height: 28px; font-size: 12px; }
  .heat th { font-size: 11px; padding: 2px; }
  .tabs { align-self: stretch; overflow-x: auto; flex-wrap: nowrap; }
  .mv-thumb { width: 64px !important; height: 36px !important; }
  .selbar { left: 50%; bottom: 72px; max-width: calc(100vw - 24px); justify-content: center; }
  .toast { bottom: 72px; }
}

/* 무엇이 통했나 */
.ww-h { font-size: 13px; font-weight: 500; color: var(--text-2); margin: 4px 0 0; }
.ww-topics { display: flex; flex-direction: column; }
.ww-topic { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-top: 1px solid var(--border); }
.ww-topic:first-child { border-top: 0; }
.ww-topic .tag { flex: none; }
.ww-body { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ww-x { color: var(--good); font-weight: 500; }
.ww-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 16px; }
.ww-list { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; color: var(--text-2); line-height: 1.55; }
.ww-top { display: flex; flex-direction: column; gap: 2px; margin: 0 -8px; }
.ww-v { display: flex; gap: 10px; align-items: flex-start; padding: 6px 8px; border-radius: var(--r-md); color: var(--text); text-decoration: none; }
.ww-v:hover { background: var(--bg-hover); }
.ww-body a { color: var(--text-2); }
.ww-body a:hover { color: var(--text); text-decoration: underline; }
.ww-v img { width: 96px; height: 54px; object-fit: cover; border-radius: 6px; display: block; }
.ww-v img { flex: none; }

/* 성장 기록 그래프 */
.gr-chart svg { width: 100%; height: auto; display: block; overflow: visible; }
.gr-chart .grid { stroke: var(--grid); stroke-width: 1; vector-effect: non-scaling-stroke; }
.gr-chart .ax { fill: var(--text-3); font-size: 11px; }
.gr-dot { fill: var(--text-3); opacity: .55; }
.gr-med { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.gr-hit { fill: none; stroke: var(--good); stroke-width: 2; vector-effect: non-scaling-stroke; }
.gr-lab { fill: var(--good); font-size: 12px; font-weight: 500; }
.gr-gap { fill: var(--bg-subtle); }
.ww-ch h2 a { color: var(--text); }
.ww-ch h2 a:hover { text-decoration: underline; }
.cand .m a { color: var(--text-2); display: inline-block; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: bottom; }
.cand .m a:hover { color: var(--text); text-decoration: underline; }

/* 2026-10-21 사용성 정리: 키보드 초점 표시, 더보기 단추, 개요 다음 할 일, 빈 표 한 줄 */
:is(a, button, input, textarea, [tabindex]):focus-visible { outline: 2px solid var(--text-accent); outline-offset: 2px; }
.more-btn { display: none; border: 0; background: none; font: inherit; }
.ov-title { font-size: 18px; margin: 0; }
.next-row { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-top: 14px; }
.panel.slim { padding-top: 12px; padding-bottom: 12px; }
.panel.slim .head-row { padding-bottom: 0 !important; gap: 12px; }
.saved-pick { align-items: center; }
.btn { font-weight: 600; }

/* 2026-10-22 완성도 점검표 1판 걸림 고침 */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
b, strong { font-weight: 600; }
.page-h { font-size: 18px; line-height: 26px; }
.overview .ov-sub { justify-self: start; margin: 0 0 4px; font-size: 14px; font-weight: 600; }
.ckcell { width: 40px; }
label.ck { display: inline-grid; place-items: center; width: 28px; height: 28px; margin: -6px; cursor: pointer; border-radius: var(--r-sm); }
label.ck:hover { background: var(--bg-hover); }
.err { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.err .btn svg.i, .empty .btn svg.i { width: 14px; height: 14px; }
.check .mark svg.i { width: 12px; height: 12px; stroke-width: 2.4; }
.mv-thumb { width: 88px; height: 50px; object-fit: cover; border-radius: var(--r-sm); flex: none; }
.al-thumb { width: 96px; height: 54px; object-fit: cover; border-radius: var(--r-md); }
.field { display: flex; flex-direction: column; gap: 6px; }
select { height: 32px; padding: 0 10px; border-radius: var(--r-sm); border: 1px solid var(--border-strong); background: var(--bg-surface); color: var(--text); font: inherit; min-width: 180px; }
@media (max-width: 640px) {
  .btn, .btn.small, .icon-btn, .tabs a, .tabs button, select, .search { min-height: 44px; }
  .icon-btn { min-width: 44px; }
  label.ck { width: 44px; height: 44px; margin: -12px; }
  .tags.scroll-x { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-right: -16px; padding-right: 16px; }
  .tags.scroll-x .tag { flex: none; }
  select, .search input { font-size: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
.field { cursor: pointer; }
.only-s { display: none; }
@media (max-width: 640px) { .only-s { display: flex; } }
td.kw > a, td > a, td .muted > a, h2 > a { display: inline-flex; align-items: center; min-height: 24px; }
div.muted { max-width: 640px; }
.overview div.muted { max-width: none; }
@media (max-width: 640px) { .tabs a, .tabs button, .btn { min-width: 44px; } td.kw > a, td > a, td .muted > a, h2 > a { min-height: 44px; min-width: 44px; } }
.field:hover select, select:hover { background: var(--bg-hover); border-color: var(--text-4); }
@media (max-width: 640px) { nav.hide-s { display: none; } }
.field:hover .label, label.label:hover { color: var(--text-2); }
@media (max-width: 640px) { .ww-ch h2 > a { padding: 0 6px; margin: 0 -6px; } }
.cand .m a { display: inline-flex; align-items: center; min-height: 24px; }
@media (max-width: 640px) { .cand .m a { min-height: 44px; } }
