/* ============================================================
   CLAZ Stat — 모바일 우선 (세로 화면 기준, PRD 8절)
   ============================================================ */
:root {
  --bg: #f5f6fa; --surface: #fff; --surface2: #eef0f6; --border: #e1e4ee;
  --accent: #4f6fe0; --accent2: #0f9b8e; --warn: #c79a14; --danger: #e05555;
  --text: #1b2030; --text2: #576074; --text3: #7a8295; --radius: 12px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  font-family: 'Pretendard', -apple-system, sans-serif;
  background: var(--bg); color: var(--text);
  display: flex; flex-direction: column; min-height: 100dvh;
}

/* ---- 헤더 ---- */
header {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px; background: var(--surface);
  border-bottom: 1px solid var(--border);
}
.brand { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 15px; cursor: pointer; }
.brand:hover { opacity: .85; }
.brand .logo {
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  color: #fff; font-size: 11px; font-weight: 600; padding: 4px 9px; border-radius: 6px;
}
.user-chip {
  margin-left: auto; display: flex; align-items: center; gap: 8px;
  font-size: 11px; color: var(--text2);
}
.tier-badge { font-size: 10px; padding: 2px 8px; border-radius: 10px; font-weight: 600; }
.tier-paid { background: rgba(15,155,142,.12); color: var(--accent2); }
.tier-free { background: var(--surface2); color: var(--text3); }
.chip-name { max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; color: var(--text); }
.chip-btn {
  padding: 4px 10px; font-size: 11px; border: 1px solid var(--border); border-radius: 8px;
  background: var(--surface); color: var(--text2); cursor: pointer; font-family: inherit;
}
.chip-btn:hover { border-color: var(--accent); color: var(--accent); }
.chip-login { background: var(--accent); color: #fff; border-color: var(--accent); font-weight: 600; }
.chip-login:hover { color: #fff; opacity: .92; }
.chip-admin { background: var(--warn, #c79a14); color: #fff; border-color: var(--warn, #c79a14); font-weight: 600; }
.chip-admin:hover { color: #fff; opacity: .92; }
/* 회원 관리 */
.admin-form { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 14px 0 6px; }
.admin-form input[type=email] { flex: 1 1 220px; min-width: 160px; padding: 9px 11px; border: 1px solid var(--border); border-radius: 8px; font-size: 14px; font-family: inherit; }
.admin-form select, .admin-form input[type=date] { padding: 8px 10px; border: 1px solid var(--border); border-radius: 8px; font-size: 14px; font-family: inherit; }
.adm-exp { font-size: 13px; color: var(--text2); display: inline-flex; align-items: center; gap: 6px; }
.admin-msg { font-size: 13px; margin: 6px 0; min-height: 18px; }
.admin-msg.ok { color: var(--accent2, #0f9b8e); }
.admin-msg.err { color: var(--danger, #e05555); }
.admin-list { margin-top: 12px; }
.admin-loading, .admin-empty { color: var(--text3); font-size: 13px; padding: 12px 0; }
.admin-row { display: flex; align-items: center; gap: 10px; padding: 10px 8px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.ar-email { flex: 1 1 200px; font-size: 13px; font-weight: 600; word-break: break-all; }
.ar-tier { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 10px; }
.ar-tier.t-paid { background: rgba(15,155,142,.12); color: var(--accent2); }
.ar-tier.t-free { background: var(--surface2); color: var(--text3); }
.ar-exp { font-size: 12px; color: var(--text2); }
.ar-exp.ar-expired { color: var(--danger); }
.admin-count { font-size: 12px; color: var(--text2); margin: 8px 0 4px; font-weight: 600; }
.ar-name { font-weight: 400; color: var(--text3); font-size: 12px; }
.ar-actions { margin-left: auto; display: inline-flex; gap: 6px; }
.ar-actions button { font-size: 12px; }
.ar-up { padding: 5px 12px; font-size: 12px; width: auto; }
/* 도구 화면 잠금 패널 */
.tool-lock {
  margin: 8px 0 4px; padding: 22px 18px; border-radius: 12px; text-align: center;
  background: var(--surface2); border: 1px dashed var(--border);
}
.tool-lock .lock-title { font-size: 15px; font-weight: 800; color: var(--text); margin-bottom: 8px; }
.tool-lock .lock-desc { font-size: 13px; color: var(--text2); line-height: 1.6; margin-bottom: 14px; }
.tool-lock .lock-cta { display: inline-block; width: auto; padding-left: 22px; padding-right: 22px; }
.lock-code { display: flex; gap: 8px; justify-content: center; align-items: center; margin: 12px 0; flex-wrap: wrap; }
.lock-code input { padding: 9px 11px; border: 1px solid var(--border); border-radius: 8px; font-size: 14px; font-family: inherit; min-width: 170px; }
.lock-code button { width: auto; margin-top: 0; padding: 9px 16px; }
/* 메뉴 카드 자물쇠 */
.menu-card { position: relative; }
.mc-lock { position: absolute; top: 8px; right: 8px; font-size: 13px; }
.menu-card.is-locked { opacity: .82; }
.btn-sm {
  padding: 6px 12px; font-size: 12px; border: 1px solid var(--border); border-radius: 8px;
  background: var(--surface2); color: var(--text2); cursor: pointer; font-family: inherit;
}
.btn-sm:hover { border-color: var(--accent); color: var(--accent); }

/* ---- 레이아웃 ---- */
main { flex: 1; width: 100%; max-width: 960px; margin: 0 auto; padding: 16px; }
.view { display: none; }
.view.on { display: block; }
.card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 18px 16px; margin-bottom: 14px;
  box-shadow: 0 1px 3px rgba(28,34,48,.04);
}
h2 { font-size: 17px; margin-bottom: 10px; }
.sub { font-size: 12px; color: var(--text3); line-height: 1.6; }

/* ---- 로그인 ---- */
.login-hero { text-align: center; padding: 48px 16px 32px; }
.login-hero h1 { font-size: 22px; margin-bottom: 10px; }
.login-hero p { font-size: 13px; color: var(--text2); line-height: 1.7; margin-bottom: 24px; }
.btn-google {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 13px 26px; font-size: 14px; font-weight: 600;
  border: 1px solid var(--border); border-radius: 10px;
  background: var(--surface); cursor: pointer; font-family: inherit;
  box-shadow: 0 2px 8px rgba(28,34,48,.06);
}
.btn-google:active { transform: scale(.98); }
.setup-warn {
  margin-top: 20px; padding: 12px; border-radius: 8px; font-size: 12px;
  background: rgba(199,154,20,.08); border: 1px solid rgba(199,154,20,.3);
  color: var(--warn); text-align: left; line-height: 1.6;
}

/* ---- 분석 메뉴 (유형별 섹션 + 카드 그리드) ---- */
.menu-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(158px, 1fr)); gap: 10px;
}
.menu-sec { min-width: 0; }
/* 하위 카테고리 좌우 배치: 폭에 맞춰 1~3열 자동, 모바일 세로 */
.menu-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; align-items: start; }
@media (max-width: 560px) { .menu-cols { grid-template-columns: 1fr; gap: 4px; } }
/* 대분류(집단차이 검증 · 관계분석) 제목 */
.menu-super { margin-top: 4px; }
.menu-super-title {
  font-size: 15px; font-weight: 800; color: var(--text);
  margin: 22px 0 8px; padding-bottom: 7px; border-bottom: 2px solid var(--border);
}
#menu-list > *:first-child .menu-section-title,
#menu-list > *:first-child .menu-super-title { margin-top: 2px; }
.menu-section-title {
  display: flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 700; color: var(--text2); margin: 20px 0 10px;
}
.menu-section-title:first-child { margin-top: 2px; }
.menu-section-title .ms-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--cat, var(--accent)); }
.menu-section-title .ms-count {
  font-size: 10px; font-weight: 700; color: var(--text3);
  background: var(--surface2); padding: 1px 8px; border-radius: 10px;
}
.menu-card {
  position: relative; display: flex; flex-direction: column; gap: 7px;
  padding: 15px 14px 14px; text-align: left; min-height: 120px; overflow: hidden;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); cursor: pointer; font-family: inherit;
  transition: transform .12s, box-shadow .18s, border-color .18s;
}
/* 상단 얇은 컬러 액센트 바 */
.menu-card::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: var(--cat, var(--accent)); opacity: .9;
}
.menu-card:hover {
  border-color: var(--cat, var(--accent)); transform: translateY(-2px);
  box-shadow: 0 8px 22px var(--cat-bg, rgba(79,111,224,.12));
}
.menu-card .mc-badge {
  align-self: flex-start; font-size: 10px; font-weight: 700; letter-spacing: .3px;
  padding: 3px 9px; border-radius: 20px;
  background: var(--cat-bg, rgba(79,111,224,.1)); color: var(--cat, var(--accent));
}
.menu-card .mc-label { font-size: 14.5px; font-weight: 700; color: var(--text); line-height: 1.3; }
.menu-card .mc-memo { display: flex; flex-direction: column; gap: 2px; margin-top: auto; }
.menu-card .mc-row { font-size: 11px; color: var(--text2); line-height: 1.5; word-break: keep-all; }
.menu-card .mc-row.mc-note { color: var(--text2); }
.material-note {
  padding: 12px 14px; margin: 12px 0; border-radius: 9px; line-height: 1.7;
  background: rgba(138,144,160,.1); border: 1px solid var(--border); font-size: 12px; color: var(--text2);
}
.menu-card .mc-row b {
  display: inline-block; min-width: 30px; font-size: 9px; font-weight: 700;
  color: var(--cat, var(--text3)); letter-spacing: .5px;
}

/* ---- 참고자료 (블로그) ---- */
.ref-box {
  margin-top: 22px; padding: 14px 16px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--border);
}
.ref-title { font-size: 13px; font-weight: 700; color: var(--text2); margin-bottom: 12px; }
.ref-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; }
.ref-card {
  display: flex; flex-direction: column; gap: 8px; padding: 16px 16px 18px;
  border: 1px solid var(--border); border-radius: 10px; background: var(--surface2);
  text-decoration: none; color: var(--text2); transition: border-color .15s, transform .15s, box-shadow .15s;
}
.ref-card:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: 0 4px 14px rgba(79,111,224,.14); }
.ref-card-ic { font-size: 22px; line-height: 1; }
.ref-card-tx { font-size: 13px; line-height: 1.55; color: var(--text); }
.ref-card b { color: var(--accent); font-weight: 700; }

/* ---- 도구: 단계 표시 ---- */
.steps { display: flex; gap: 6px; margin-bottom: 14px; }
.step {
  flex: 1; text-align: center; font-size: 11px; padding: 7px 4px;
  border-radius: 8px; background: var(--surface2); color: var(--text3);
}
.step.on { background: rgba(79,111,224,.12); color: var(--accent); font-weight: 600; }
.step.done { color: var(--accent2); }

/* ---- 입력 ---- */
textarea {
  width: 100%; min-height: 180px; padding: 12px; font-size: 12px;
  font-family: 'Courier New', monospace; line-height: 1.6;
  background: var(--surface2); border: 1px solid var(--border); border-radius: 8px;
  color: var(--text); resize: vertical; outline: none;
}
textarea:focus { border-color: var(--accent); }
.sample-box {
  width: 100%; box-sizing: border-box; max-height: 260px; overflow: auto;
  padding: 12px; margin: 4px 0 4px; font-size: 11px;
  font-family: 'Courier New', monospace; line-height: 1.7; white-space: pre;
  background: var(--surface2); border: 1px solid var(--border); border-radius: 8px;
  color: var(--text2);
}
.narr-box {
  padding: 14px 16px; margin: 6px 0 4px; font-size: 13px; line-height: 1.9;
  background: var(--surface2); border: 1px solid var(--border); border-radius: 8px;
  color: var(--text); word-break: keep-all;
}
.narr-box i { font-style: italic; }
/* ---- 실습 자료 다운로드 ---- */
.material-box { margin: 14px 0 4px; }
.material-links { display: flex; flex-wrap: wrap; gap: 8px; }
.material-link {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 9px 13px; font-size: 13px; font-weight: 600; text-decoration: none;
  color: var(--text); background: var(--surface2);
  border: 1px solid var(--border); border-radius: 9px; transition: border-color .15s, background .15s;
}
.material-link:hover { border-color: var(--accent); background: rgba(79,111,224,.06); }
.material-link .ml-ext {
  font-size: 9px; font-weight: 700; letter-spacing: .3px; color: var(--accent);
  background: rgba(79,111,224,.12); padding: 2px 6px; border-radius: 5px;
}
.material-hint { font-size: 11px; color: var(--text3); line-height: 1.6; margin-top: 8px; }
.chart-box { overflow-x: auto; padding: 6px 0; text-align: center; }
.chart-box .chart-svg { display: inline-block; }
.help {
  font-size: 11px; color: var(--text3); line-height: 1.7;
  padding: 10px 12px; margin-bottom: 10px;
  background: rgba(79,111,224,.05); border-left: 3px solid var(--accent); border-radius: 6px;
}
.btn-primary {
  display: block; width: 100%; padding: 14px; margin-top: 12px;
  font-size: 15px; font-weight: 600; font-family: inherit;
  background: linear-gradient(135deg, var(--accent), #6d4ee0);
  color: #fff; border: none; border-radius: 10px; cursor: pointer;
}
.btn-primary:active { transform: scale(.98); }
.btn-secondary {
  display: inline-block; padding: 11px 18px; font-size: 13px; font-family: inherit;
  background: var(--surface2); color: var(--text2);
  border: 1px solid var(--border); border-radius: 9px; cursor: pointer;
}
.btn-secondary:hover { border-color: var(--accent); color: var(--accent); }

/* ---- 접이식 섹션 (영상·예시·값확인) ---- */
.disc {
  border: 1px solid var(--border); border-radius: 10px;
  margin: 12px 0 4px; background: var(--surface); overflow: hidden;
}
.disc > summary {
  list-style: none; cursor: pointer; padding: 12px 14px;
  font-size: 13px; font-weight: 600; color: var(--text2);
  display: flex; align-items: center; gap: 6px; user-select: none;
}
.disc > summary::-webkit-details-marker { display: none; }
.disc > summary::after { content: "▾"; margin-left: auto; color: var(--text3); transition: transform .2s; }
.disc[open] > summary::after { transform: rotate(180deg); }
.disc > summary:hover { color: var(--accent); }
.disc-hint { font-size: 11px; font-weight: 400; color: var(--text3); }
.disc > *:not(summary) { margin-left: 14px; margin-right: 14px; }
.disc > *:last-child { margin-bottom: 14px; }
/* 값 확인 헤더 우측에 '다시 만들기' 버튼 */
.confirm-sum { flex-wrap: wrap; }
.confirm-rebuild { margin-left: auto; width: auto; flex: 0 0 auto; padding: 6px 12px; font-size: 12px; }

.sec-title { font-size: 13px; font-weight: 700; color: var(--text); margin: 18px 0 8px; }
.warn-list { font-size: 11px; color: var(--warn); line-height: 1.7; margin: 4px 0 10px; padding-left: 30px; }

/* ---- 값 확인: 변수별 컴팩트 카드 그리드 ---- */
.vcard {
  border: 1px solid var(--border); border-radius: 10px;
  padding: 10px 12px 12px; margin-bottom: 10px; background: var(--surface2);
}
.vcard-title { font-size: 12px; font-weight: 700; color: var(--accent); margin-bottom: 8px; }
.fgrid { display: flex; flex-wrap: wrap; gap: 8px; }
.fcell { display: flex; flex-direction: column; gap: 3px; width: 96px; flex: 0 0 auto; }
.fcell.wide { width: 132px; }
.fcell label {
  font-size: 10px; color: var(--text3); line-height: 1.3;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.fcell input, .fcell select {
  width: 100%; padding: 7px 8px; font-size: 13px; text-align: right;
  font-family: 'Courier New', monospace;
  background: var(--surface); border: 1px solid var(--border); border-radius: 7px;
  color: var(--text); outline: none; -webkit-appearance: none;
}
.fcell select { text-align: left; font-family: inherit; font-size: 12px; }
.fcell input:focus, .fcell select:focus { border-color: var(--accent); }
.fcell input.missing { border-color: var(--danger); background: rgba(224,85,85,.06); }
.fcell input.locked { background: repeating-linear-gradient(-45deg, rgba(148,163,184,.10), rgba(148,163,184,.10) 5px, transparent 5px, transparent 10px); color: var(--text2); cursor: not-allowed; }

/* 표 아래 그래프 값 입력 바 (독립/조절 2줄) */
.graph-inputs { margin: 14px 0 4px; padding: 12px 14px; background: var(--card2, #f8fafc); border: 1px solid var(--line, #e2e8f0); border-radius: 10px; }
.graph-inputs .sec-title { margin: 0 0 10px; }
.ginput-row { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; flex-wrap: wrap; }
.ginput-row:last-child { margin-bottom: 0; }
.ginput-lab { flex: 0 0 84px; font-size: 13px; font-weight: 600; color: var(--text2); }
.ginput { flex: 1 1 90px; min-width: 70px; padding: 7px 9px; border: 1px solid var(--line, #cbd5e1); border-radius: 7px; font-size: 13px; background: #fff; }
.ginput-name { flex: 1 1 130px; }
.ginput:focus { outline: none; border-color: var(--brand, #6366f1); }

/* 분석 방법 가이드 캐러셀 */
.guide-box { margin: 6px 0 14px; padding: 12px 14px; background: var(--card2, #f8fafc); border: 1px solid var(--line, #e2e8f0); border-radius: 12px; }
.guide-box .sec-title { margin: 0 0 10px; }
.guide-carousel { position: relative; }
.guide-viewport { position: relative; width: 100%; min-height: 120px; background: #eef2f7; border: 1px solid var(--line, #e2e8f0); border-radius: 10px; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.guide-ph { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; text-align: center; padding: 24px; font-size: 12px; color: var(--text2, #64748b); }
.guide-img { position: relative; max-width: 100%; height: auto; display: block; cursor: zoom-in; }
.guide-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border: none; border-radius: 50%; background: rgba(15,23,42,.55); color: #fff; font-size: 15px; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.guide-nav:hover { background: rgba(15,23,42,.78); }
.guide-prev { left: 8px; } .guide-next { right: 8px; }
.guide-cap { margin-top: 10px; font-size: 13px; color: var(--text, #1e293b); text-align: center; line-height: 1.5; }
.guide-step { display: inline-block; margin-right: 6px; padding: 1px 8px; border-radius: 999px; background: var(--brand, #6366f1); color: #fff; font-size: 11px; font-weight: 700; }
.guide-dots { margin-top: 8px; display: flex; gap: 6px; justify-content: center; }
.guide-dot { width: 8px; height: 8px; border-radius: 50%; background: #cbd5e1; cursor: pointer; }
.guide-dot.on { background: var(--brand, #6366f1); }
.guide-lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(0,0,0,.85); display: flex; align-items: center; justify-content: center; padding: 16px; cursor: zoom-out; }
.guide-lightbox img { max-width: 100%; max-height: 100%; border-radius: 6px; }
.fcheck {
  display: inline-flex; align-items: center; gap: 6px; cursor: pointer;
  font-size: 12px; color: var(--text2); padding: 6px 2px;
}
.fcheck input { width: 16px; height: 16px; accent-color: var(--accent); cursor: pointer; }

/* ---- APA 표 ---- */
.apa-wrap { overflow-x: auto; margin-bottom: 8px; }
.apa-title { font-size: 13px; margin-bottom: 6px; }
.apa-table {
  border-collapse: collapse; min-width: 100%; font-size: 13px;
  border-top: 2px solid var(--text); border-bottom: 2px solid var(--text);
}
.apa-table th {
  padding: 7px 12px; font-weight: 500; border-bottom: 1px solid var(--text); white-space: nowrap;
}
.apa-table td { padding: 6px 12px; white-space: nowrap; }
.apa-compact { font-size: 11px; }
.apa-compact th { padding: 5px 6px; }
.apa-compact td { padding: 4px 6px; }
.apa-wrap { -webkit-overflow-scrolling: touch; }
.apa-note { font-size: 11px; color: var(--text2); margin-top: 4px; }
.export-row { display: flex; gap: 8px; flex-wrap: wrap; margin: 10px 0 4px; align-items: center; }
/* 붙여넣기 영역: 분석하기 + 초기화 나란히 */
.paste-btns { display: flex; gap: 10px; align-items: stretch; }
.paste-btns .btn-primary { flex: 1 1 auto; }
.paste-btns .btn-secondary { flex: 0 0 auto; margin-top: 12px; }
/* 기술문 복사 옆 '유의하지 않음 포함' 옵션 */
.narr-opt { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--text2); cursor: pointer; }
.result-block { margin-bottom: 22px; }
.dp-bar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px;
  padding: 9px 11px; margin-bottom: 12px; border-radius: 9px;
  background: var(--surface2); border: 1px solid var(--border); font-size: 11px; color: var(--text3);
}
.dp-bar-lab { font-weight: 700; color: var(--text2); }
.dp-bar label { display: inline-flex; align-items: center; gap: 5px; color: var(--text2); }
.dp-bar select {
  padding: 3px 6px; font-size: 12px; border: 1px solid var(--border); border-radius: 6px;
  background: var(--surface); color: var(--text); -webkit-appearance: none;
}
.dp-bar select:focus { border-color: var(--accent); outline: none; }
/* 결과 상단 옵션 바 (표·기술문 옵션 체크박스 모음) */
.result-opts {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px;
  padding: 9px 11px; margin-bottom: 12px; border-radius: 9px;
  background: var(--surface2); border: 1px solid var(--border);
}
.result-opts .opts-lab { font-size: 11px; font-weight: 700; color: var(--text3); }
.result-opts .opt-check { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; color: var(--text2); cursor: pointer; }
.table-controls { display: flex; gap: 8px; margin-bottom: 10px; }
.btn-toggle {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 7px 13px; font-size: 12px; font-weight: 600; font-family: inherit; cursor: pointer;
  background: var(--surface2); color: var(--text2); border: 1px solid var(--border); border-radius: 8px;
}
.btn-toggle:hover { border-color: var(--accent); color: var(--accent); }
.btn-toggle.on { background: var(--accent); color: #fff; border-color: var(--accent); }
.coltoggle {
  display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px;
  padding: 8px 10px; margin-bottom: 8px; border-radius: 8px;
  background: var(--surface2); border: 1px solid var(--border);
}
.coltoggle-lab { font-size: 11px; font-weight: 700; color: var(--text3); }
.colchk { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: var(--text2); cursor: pointer; }
.colchk input { width: 15px; height: 15px; accent-color: var(--accent); cursor: pointer; }

/* ---- 영상 ---- */
.video-wrap { position: relative; width: 100%; padding-top: 56.25%; border-radius: 10px; overflow: hidden; margin-top: 10px; }
.video-wrap iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.paywall {
  padding: 16px; border-radius: 10px; text-align: center; font-size: 13px; line-height: 1.7;
  background: var(--surface2); color: var(--text2);
}

/* ---- 토스트 / 푸터 ---- */
.toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(8px);
  padding: 11px 22px; font-size: 13px; border-radius: 9px; white-space: nowrap;
  background: var(--surface); border: 1px solid var(--accent); color: var(--accent);
  box-shadow: 0 6px 24px rgba(28,34,48,.14); opacity: 0; pointer-events: none;
  transition: all .25s; z-index: 99;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast.error { border-color: var(--danger); color: var(--danger); }
footer {
  padding: 20px 16px 28px; text-align: center;
  font-size: 11px; color: var(--text3); line-height: 1.8;
}
footer a { color: var(--accent); text-decoration: none; }

.back-row { margin-bottom: 12px; }
@media (min-width: 640px) {
  .frow input, .frow select { width: 200px; }
}
