/* 최승규 수학 통합 사이트 (2026-10-30) — 반 사이트(pmc)와 같은 색 */
:root{
  --paper:#F5F4F1; --card:#FFFFFF; --ink:#1A1718; --muted:#62656D; --soft:#F1EFEB;
  --line:#E7E4DF; --line2:#DDD9D3; --brand:#B0272A; --brand-d:#8C1E21; --brand-l:#F6E3E2;
  --ok:#2E7D4F;
}
*{box-sizing:border-box;-webkit-tap-highlight-color:transparent}
html,body{margin:0}
body{background:var(--paper); color:var(--ink);
  font-family:-apple-system,BlinkMacSystemFont,"Apple SD Gothic Neo","Malgun Gothic","Noto Sans KR",sans-serif;
  line-height:1.6; padding:0 16px calc(48px + env(safe-area-inset-bottom)); max-width:760px; margin:0 auto; word-break:keep-all}
button{font:inherit}
[hidden]{display:none !important}

/* ---------- 첫 화면 ---------- */
#gate{max-width:440px; margin:0 auto; padding-top:max(14px, env(safe-area-inset-top))}
@media (min-width:700px){ #gate{padding-top:5vh} }
.hero{text-align:center; padding:4px 0 2px}
.hero .wm{font-size:26px; font-weight:800; color:var(--brand); letter-spacing:-.02em}
.hero .who{margin:14px 0 0}
.hero .nm{font-size:17px; font-weight:700}
.hero ul.cv{list-style:none; padding:0; margin:6px 0 0; color:#3F3B3C; font-size:14.5px; line-height:1.75}
.stats{display:grid; grid-template-columns:1fr 1fr; gap:10px; margin:20px 0 0}
.stat{background:var(--card); border:1px solid var(--line); border-radius:14px; padding:12px 8px}
.stat .v{font-size:24px; font-weight:800; color:var(--brand); font-variant-numeric:tabular-nums}
.stat .l{font-size:12.5px; color:var(--muted)}
.card{background:var(--card); border:1px solid var(--line); border-radius:16px; padding:16px; margin:14px 0}
.card .ch{font-size:13px; font-weight:700; color:var(--brand-d); margin:0 0 10px}
.results table{width:100%; border-collapse:collapse; font-size:14px}
.results th{font-size:12px; color:var(--muted); font-weight:600; text-align:left; padding:4px 6px; border-bottom:1px solid var(--line2)}
.results td{padding:9px 6px; border-bottom:1px solid var(--line)}
.results td.blank{color:#C4BFB9}button.more{display:block; width:100%; margin-top:10px; border:1px solid var(--line2); background:var(--soft); color:var(--ink);
  border-radius:10px; height:38px; font-size:13.5px; font-weight:600; cursor:pointer}
button.more:hover{border-color:var(--brand); color:var(--brand)}
.field{margin-bottom:12px}
.field label{display:block; font-size:12.5px; color:var(--muted); margin:0 0 5px 2px}
.field input{width:100%; height:48px; border:1px solid var(--line2); border-radius:12px; background:var(--card);
  padding:0 14px; font-size:16px; color:var(--ink); font-family:inherit}
.field input:focus{outline:2px solid var(--brand); border-color:var(--brand)}
button.primary{width:100%; height:50px; border:0; border-radius:12px; background:var(--brand); color:#fff;
  font-size:16px; font-weight:600; cursor:pointer; margin-top:4px}
button.primary:active{transform:scale(.98)}
.err{color:var(--brand); font-size:13px; font-weight:600; min-height:20px; margin-top:10px}
.note{font-size:12px; color:var(--muted); line-height:1.55}
.note.parent{margin-top:8px; padding-top:8px; border-top:1px dashed var(--line2)}
.note.parent b{color:var(--ink)}
/* 입장하기 칸 글씨 키움 (2026-10-31) */
.card.login .ch, .contact .ch{font-size:15px}
.card.login .field label{font-size:14.5px; font-weight:600; color:#4A4648}
.card.login .field input{height:52px; font-size:17px}
.card.login button.primary{height:54px; font-size:17px}
.card.login .keep{font-size:14.5px}
.card.login .note{font-size:14px; line-height:1.6}
.card.login .note.one{margin-top:2px}
.keeps{display:flex; flex-wrap:wrap; gap:4px 22px}
/* 학생 관리 탭 (2026-10-31) */
.rsbar{display:flex; flex-wrap:wrap; gap:8px; margin:6px 0 10px}
.rsbar .sel{flex:1 1 180px; margin:0}
.rsbar input{height:40px; border:1px solid var(--line,#ddd); border-radius:10px; padding:0 10px; font-size:15px; flex:1 1 150px; background:#fff}
.rssum{margin:8px 0 4px; font-size:15px}
.rssum .bad{color:#B0272A; font-weight:700}
.rtwrap{overflow-x:auto; -webkit-overflow-scrolling:touch; margin-top:8px}
.rster td,.rbook td{vertical-align:middle}
.rster td,.rster th{padding-left:5px;padding-right:5px}
.rster td.cl{font-size:13px; color:#6C6F77; white-space:nowrap}
.rster td.pin{font-family:Consolas,monospace; font-weight:800; font-size:16px; letter-spacing:1px}
.atts{white-space:nowrap}
button.att{height:32px; padding:0 7px; margin:0 2px 0 0; border:1px solid #DDD9D3; border-radius:8px; background:#fff; color:#6C6F77; font-size:13px; font-weight:700; cursor:pointer}
button.att.on.aO{background:#2E7D4F; border-color:#2E7D4F; color:#fff}
button.att.on.aL{background:#E8A317; border-color:#E8A317; color:#fff}
button.att.on.aE{background:#4A6FA5; border-color:#4A6FA5; color:#fff}
button.att.on.aX{background:#B0272A; border-color:#B0272A; color:#fff}
.rster input.memo{width:80px; height:32px; border:1px solid #E7E4DF; border-radius:8px; padding:0 8px; font-size:13px}
button.sm.warn{background:#B0272A; color:#fff; border-color:#B0272A}
.lockbox{background:#FFF6D6; border:1px solid #F1D98A; border-radius:12px; padding:10px 12px; margin:6px 0 10px; font-size:14px}
.lockbox .lk{display:flex; justify-content:space-between; align-items:center; gap:8px; margin-top:6px}
.rbook th,.rbook td{text-align:center; white-space:nowrap}
.rbook td.mO{color:#2E7D4F; font-weight:800} .rbook td.mL{color:#E8A317; font-weight:800} .rbook td.mE{color:#4A6FA5; font-weight:800} .rbook td.mX{color:#B0272A; font-weight:800; background:#FBEAEA}
.inapp{background:#FFF6D6; border:1px solid #F1D98A; border-radius:12px; padding:10px 12px; margin:0 0 10px; font-size:14px; line-height:1.5; color:#5B4A12}
.inapp a{display:block; margin-top:8px; text-align:center; height:40px; line-height:40px; border-radius:10px; background:#191919; color:#fff; font-weight:700; text-decoration:none}
.pwwrap{position:relative}
.pwwrap input{padding-right:64px}
button.eye{position:absolute; right:6px; top:50%; transform:translateY(-50%); height:38px; padding:0 12px; border:1px solid var(--line2); border-radius:9px; background:var(--soft); color:var(--muted); font-size:13.5px; font-weight:700; cursor:pointer}
button.eye.on{background:var(--brand-l); color:var(--brand-d); border-color:var(--brand-l)}
.nmforget{float:right; border:0; background:none; color:var(--brand); font-size:13px; font-weight:600; cursor:pointer; padding:6px 4px; margin:-6px -4px}
button.a2hs{display:block; width:100%; height:46px; margin:4px 0 10px; border:1.5px dashed var(--brand); border-radius:12px; background:var(--brand-l); color:var(--brand-d); font-size:15px; font-weight:700; cursor:pointer}
button.a2hs[hidden]{display:none}
.a2hstip{background:var(--soft); border-radius:10px; padding:10px 12px; font-size:14px; line-height:1.6; margin:-4px 0 10px}
details.note.parent summary{cursor:pointer; font-weight:700; color:var(--brand-d); list-style:none}
details.note.parent summary::-webkit-details-marker{display:none}
details.note.parent summary::after{content:" ▾"}
details.note.parent[open] summary::after{content:" ▴"}
details.note.parent[open] summary{margin-bottom:4px}
.card.bio{padding:0; overflow:hidden; border-color:var(--line2)}
.bio-head{display:flex; align-items:center; justify-content:center; text-align:center; gap:14px; padding:18px 20px 16px;
  background:linear-gradient(135deg,var(--brand) 0%,var(--brand-d) 100%); color:#fff}
.bio-av{flex:none; width:56px; height:56px; border-radius:50%; display:flex; align-items:center; justify-content:center;
  background:rgba(255,255,255,.16); border:1.5px solid rgba(255,255,255,.55); font:italic 600 30px/1 Georgia,'Times New Roman',serif}
.bio-tag{font-size:12.5px; font-weight:700; letter-spacing:.12em; opacity:.85}
.bio-nm{font-size:25px; font-weight:800; letter-spacing:-.01em; margin-top:2px}
.bio-nm small{font-size:15px; font-weight:600; opacity:.85; margin-left:2px}
.bio-list{margin:0; padding:6px 20px 4px}
.bio-row{display:grid; grid-template-columns:88px 1fr; gap:10px; align-items:center; padding:13px 0; border-bottom:1px solid var(--line)}
.bio-row:last-child{border-bottom:0}
.bio-row dt{font-size:13.5px; font-weight:700; color:var(--muted)}
.bio-row dd{margin:0; font-size:17px; font-weight:600; color:var(--ink); line-height:1.45}
.chips{display:flex; flex-wrap:wrap; gap:6px}
.chips{display:grid; grid-template-columns:1fr 1fr; gap:6px; max-width:300px}
.chip{display:flex; flex-direction:column; align-items:center; justify-content:center; height:50px; padding:4px 8px; text-align:center; border-radius:14px; background:var(--brand-l); color:var(--brand-d); font-size:15px; font-weight:700; line-height:1.25}
.chip small{font-size:11.5px; font-weight:600; opacity:.8; margin-top:1px}
a.chip{text-decoration:none; cursor:pointer}
a.chip:hover{filter:brightness(.96)}
.chip .cnm{display:inline-flex; align-items:center; gap:3px}
.chip .pin{flex:none; opacity:.75}
.bio-note{margin:0; padding:12px 20px 14px; background:var(--soft); font-size:14px; color:var(--muted); border-top:1px solid var(--line)}
.bio-note::before{content:"ⓘ "; color:var(--brand)}
.contact .ch{font-size:15px}
.contact .ctbtn{font-size:16.5px; height:54px}
.ctbtn{display:flex; align-items:center; justify-content:center; height:50px; border-radius:12px; background:#FEE500; color:#191919; font-weight:700; font-size:15px; text-decoration:none; margin-bottom:8px}
.ctbtn:hover{filter:brightness(.97)}
.ctsub{margin:-2px 0 10px; font-size:14px; line-height:1.55; color:#555; word-break:keep-all}
.ctsub b{color:#191919}
.snsrow{display:grid; grid-template-columns:1fr 1fr; gap:8px}
.snsbtn{display:flex; align-items:center; justify-content:center; gap:8px; height:48px; border-radius:12px; background:#fff; border:1px solid #E3E6EE; color:#191919; font-weight:700; font-size:15px; text-decoration:none}
.snsbtn:hover{background:#F6F7FA}

/* ---------- 앱 ---------- */
header{padding:16px 0 0; position:sticky; top:0; background:var(--paper); z-index:5}
.top{display:flex; align-items:center; gap:10px}
.top .wm{font-size:19px; font-weight:800; color:var(--brand); letter-spacing:-.02em; flex:1}
.top .me{font-size:13px; color:var(--muted)}
.top .me b{color:var(--ink)}
button.ghost{border:1px solid var(--line2); background:var(--card); color:var(--muted); border-radius:9px; height:36px; padding:0 12px; font-size:13px; cursor:pointer}
.tabs{display:flex; gap:2px; margin-top:12px; border-bottom:2px solid var(--brand); overflow-x:auto; scrollbar-width:none}
.tabs::-webkit-scrollbar{display:none}
.tab{flex:none; padding:10px 13px; font-size:14.5px; font-weight:600; color:var(--muted); white-space:nowrap;
  cursor:pointer; border:none; background:none; border-bottom:2.5px solid transparent; margin-bottom:-2px; position:relative}
.tab.active{color:var(--brand); border-bottom-color:var(--brand)}
.tab .mine{display:inline-block; font-size:10.5px; font-weight:700; color:#fff; background:var(--brand); border-radius:5px; padding:0 5px; margin-left:5px; vertical-align:2px}
footer{padding:26px 0; color:var(--muted); font-size:12px; text-align:center}

/* 홈 */
.hello{font-size:18px; font-weight:700; margin:18px 0 2px}
.sub{font-size:13.5px; color:var(--muted); margin:0}
.classes{display:grid; grid-template-columns:repeat(auto-fill,minmax(200px,1fr)); gap:10px; margin-top:14px}
button.cls{appearance:none; text-align:left; border:1px solid var(--line2); background:var(--card); border-radius:14px; padding:14px; cursor:pointer}
button.cls:hover{border-color:var(--brand)}
button.cls .t{font-size:15.5px; font-weight:700; color:var(--ink)}
button.cls .d{font-size:12.5px; color:var(--muted); margin-top:3px}
button.cls.mine{border-color:var(--brand); background:var(--brand-l)}

/* 반 */
.ctitle{font-size:20px; font-weight:700; margin:18px 0 0}
.seg{display:flex; gap:6px; margin:12px 0 4px; flex-wrap:wrap}
.seg button{border:1px solid var(--line2); background:var(--card); color:var(--muted); border-radius:999px; padding:8px 14px; font-size:13.5px; font-weight:600; cursor:pointer}
.seg button.on{background:var(--ink); border-color:var(--ink); color:#fff}
.seg button.staff{border-style:dashed}
.seg button.staff.on{background:var(--brand); border-color:var(--brand); border-style:solid}
table.rt{width:100%; border-collapse:collapse; font-size:14px; background:var(--card); border:1px solid var(--line); border-radius:14px; overflow:hidden}
table.rt th{font-size:12px; color:var(--muted); font-weight:600; text-align:left; padding:9px 10px; border-bottom:1px solid var(--line2); background:#FBFAF8; white-space:nowrap}
table.rt td{padding:11px 10px; border-bottom:1px solid var(--line); vertical-align:top}
table.rt tr:last-child td{border-bottom:0}
table.rt td.no{font-weight:700; white-space:nowrap; font-variant-numeric:tabular-nums}
table.rt td.dt{color:var(--muted); font-size:12.5px; white-space:nowrap; font-variant-numeric:tabular-nums}
table.rt td.tx{white-space:pre-wrap}
td.pc{white-space:nowrap; width:1%}
.pct{display:flex; align-items:center; gap:6px; font-size:13px; font-variant-numeric:tabular-nums}
.pct .bar{width:46px; height:6px; border-radius:3px; background:var(--line); overflow:hidden}
.pct .bar i{display:block; height:100%; background:var(--muted)}
.pct.me .bar i{background:var(--brand)}
.pct.me b{color:var(--brand)}
.pct .none{color:#C4BFB9}
.empty{padding:34px 8px; text-align:center; color:var(--muted); font-size:14px}
.hint{font-size:12px; color:var(--muted); margin:8px 2px 0}

/* 자료 */
.fgrp{margin:16px 0 0}
.fgrp .gh{display:flex; align-items:center; gap:8px; font-size:13.5px; font-weight:700; color:var(--brand-d); margin:0 0 8px}
.fgrp .gh span{flex:1}
.flist{display:flex; flex-direction:column; gap:8px}
.frow{display:flex; align-items:center; gap:10px; border:1px solid var(--line2); background:var(--card); border-radius:11px; padding:11px 12px}
.frow a{flex:1; display:flex; align-items:center; gap:10px; text-decoration:none; color:var(--ink); min-width:0}
.frow .ico{flex:none; width:32px; height:32px; border-radius:8px; background:var(--brand-l); color:var(--brand-d); display:flex; align-items:center; justify-content:center; font-size:10.5px; font-weight:800}
.frow .fn{font-size:14px; line-height:1.35; overflow-wrap:anywhere}
.frow .fm{display:block; font-size:11.5px; color:var(--muted)}
.frow button.del{border:0; background:none; color:var(--muted); font-size:18px; cursor:pointer; padding:0 4px}
.fempty{font-size:13px; color:#6C6F77; border:1px dashed var(--line2); border-radius:11px; padding:14px; text-align:center}
button.sm{border:1px solid var(--brand); background:var(--card); color:var(--brand); border-radius:9px; padding:7px 12px; font-size:12.5px; font-weight:600; cursor:pointer}
button.sm.fill{background:var(--brand); color:#fff}
.prog{font-size:12.5px; color:var(--muted); margin-top:6px}

/* 과제 입력 (조교) · 회차표 편집 (선생님) */
.gridwrap{overflow-x:auto; background:var(--card); border:1px solid var(--line); border-radius:14px}
table.hw{border-collapse:collapse; font-size:13.5px; min-width:100%}
table.hw th,table.hw td{border-bottom:1px solid var(--line); padding:6px; text-align:center; white-space:nowrap}
table.hw th{font-size:12px; color:var(--muted); font-weight:600; background:#FBFAF8}
table.hw td.nm,table.hw th.nm{text-align:left; position:sticky; left:0; background:var(--card); font-weight:600; padding-left:12px; z-index:1}
table.hw th.nm{background:#FBFAF8}
table.hw input{width:52px; height:34px; border:1px solid var(--line2); border-radius:8px; text-align:center; font-size:15px; font-family:inherit; font-variant-numeric:tabular-nums}
table.hw input:focus{outline:2px solid var(--brand); border-color:var(--brand)}
table.hw input.saved{border-color:var(--ok); background:#EEF7F1}
table.hw input.bad{border-color:var(--brand); background:var(--brand-l)}
table.hw tr.avg td{font-weight:700; color:var(--brand-d); background:#FBFAF8}
.ed{display:flex; flex-direction:column; gap:10px}
.edrow{background:var(--card); border:1px solid var(--line); border-radius:12px; padding:10px; display:grid; grid-template-columns:64px 1fr auto; gap:8px; align-items:start}
.edrow input,.edrow textarea{width:100%; border:1px solid var(--line2); border-radius:8px; padding:7px 9px; font:inherit; font-size:14px; background:#fff}
.edrow textarea{resize:vertical; min-height:38px}
.edrow .cols{display:grid; gap:6px}
.edrow .cols label{font-size:11.5px; color:var(--muted)}
.edrow button.del{border:0; background:none; color:var(--muted); font-size:20px; cursor:pointer}
.edbar{display:flex; gap:8px; align-items:center; margin-top:12px}
.edbar .msg{font-size:13px; color:var(--muted)}
.edbar .msg.ok{color:var(--ok); font-weight:600}
.edbar .msg.bad{color:var(--brand); font-weight:600}
@media (max-width:480px){ .edrow{grid-template-columns:52px 1fr auto} }

/* 테스트 채점 (조교) */
.badge{flex:none; font-size:11.5px; font-weight:700; border-radius:999px; padding:2px 9px; background:#EDEAE5; color:var(--muted); white-space:nowrap}
.badge.warn{background:#FDF0DA; color:#9A6400}
.badge.ok{background:#E3F1E8; color:var(--ok)}
.badge.bad{background:var(--brand-l); color:var(--brand)}
.trow3{display:grid; grid-template-columns:70px 150px 1fr; gap:8px}
.trow3 label{font-size:11.5px; color:var(--muted); display:flex; flex-direction:column; gap:3px; min-width:0}
.trow3 input{height:38px; border:1px solid var(--line2); border-radius:8px; padding:0 9px; font:inherit; font-size:14px; background:#fff; min-width:0}
@media (max-width:520px){ .trow3{grid-template-columns:70px 1fr} .trow3 .w{grid-column:1/-1} }
.tlist{display:flex; flex-direction:column; gap:8px; margin-top:4px}
button.trow{appearance:none; display:flex; align-items:center; gap:12px; text-align:left; border:1px solid var(--line2); background:var(--card); border-radius:12px; padding:12px 14px; cursor:pointer; font:inherit; color:var(--ink)}
button.trow:hover{border-color:var(--brand)}
button.trow .no{font-weight:800; font-variant-numeric:tabular-nums; min-width:34px}
button.trow .tt{flex:1; font-size:14.5px; font-weight:600; min-width:0}
.fm{display:block; font-size:11.5px; color:var(--muted); font-weight:400}
.thead{display:flex; align-items:center; gap:8px; flex-wrap:wrap; font-size:16px; margin:12px 0 0}
.thead .fm{display:inline}
.spin{display:inline-block; width:14px; height:14px; border:2px solid var(--line); border-top-color:var(--brand); border-radius:50%; animation:spin 1s linear infinite; vertical-align:-2px; margin-right:6px}
@keyframes spin{to{transform:rotate(360deg)}}
.keygrid{display:grid; grid-template-columns:repeat(auto-fill,minmax(58px,1fr)); gap:6px}
.keygrid label{display:flex; flex-direction:column; align-items:center; background:var(--card); border:1px solid var(--line); border-radius:9px; padding:4px}
.keygrid span{font-size:11px; color:var(--muted)}
.keygrid input{width:100%; height:30px; border:1px solid var(--line2); border-radius:6px; text-align:center; font:inherit; font-size:15px; font-weight:700}
.keygrid input:disabled{background:var(--soft); color:var(--ink); border-color:transparent}
.slist{display:flex; flex-direction:column; gap:8px}
.srow{display:flex; gap:12px; background:var(--card); border:1px solid var(--line); border-radius:12px; padding:10px}
.srow.need{border:2px solid var(--brand)}
img.crop{flex:none; width:150px; height:64px; object-fit:contain; background:var(--soft); border-radius:8px; border:1px solid var(--line)}
.sbody{flex:1; min-width:0}
.sline{display:flex; align-items:center; gap:10px}
.sline select{flex:1; min-width:0; height:36px; border:1px solid var(--line2); border-radius:8px; font:inherit; font-size:14.5px; padding:0 8px; background:#fff}
.sline .sc{font-size:16px; white-space:nowrap; font-variant-numeric:tabular-nums}
.ans{display:flex; flex-wrap:wrap; gap:3px; margin-top:7px}
.ans span{width:22px; height:22px; border-radius:5px; font-size:12px; font-weight:700; display:flex; align-items:center; justify-content:center; font-variant-numeric:tabular-nums}
.ans .o{background:#E3F1E8; color:var(--ok)}
.ans .x{background:var(--brand-l); color:var(--brand)}
.ans .q{background:#FDF0DA; color:#9A6400; outline:1.5px solid #E0A800}
.flags{display:flex; flex-wrap:wrap; gap:4px; margin-top:6px}
.flags span{font-size:11px; font-weight:700; color:#9A6400; background:#FDF0DA; border-radius:5px; padding:1px 6px}
.sbtn{display:flex; gap:12px; margin-top:6px}
button.lnk{border:0; background:none; color:var(--muted); font:inherit; font-size:12.5px; text-decoration:underline; cursor:pointer; padding:5px 3px; margin:-5px -3px}
.pagebox img{display:block; width:100%; margin-top:8px; border:1px solid var(--line); border-radius:8px}
.fixbox{display:flex; flex-wrap:wrap; gap:6px; align-items:center; margin-top:6px}
.fixbox input{flex:1; min-width:180px; height:34px; border:1px solid var(--line2); border-radius:8px; padding:0 9px; font-family:var(--num,monospace); font-size:14px}
.fixbox .fm{flex-basis:100%}
textarea.copy{width:100%; border:1px solid var(--line2); border-radius:10px; padding:10px; font:inherit; font-size:13.5px; background:var(--soft); resize:vertical}
@media (max-width:520px){ img.crop{width:96px; height:48px} }

/* 10/30 추가: 회원 칸 숨김 · 반 관리 */
.stats.one{grid-template-columns:1fr}
select.sel{width:100%; height:40px; border:1px solid var(--line2); border-radius:10px; font:inherit; font-size:14.5px; padding:0 10px; background:#fff}
.calist{display:flex; flex-direction:column; gap:8px}
.caform{display:flex; flex-direction:column; gap:10px}
.caform label{font-size:12.5px; color:var(--muted); display:flex; flex-direction:column; gap:4px}
.caform input,.caform textarea{border:1px solid var(--line2); border-radius:9px; padding:8px 10px; font:inherit; font-size:14.5px; color:var(--ink); background:#fff}
.caform input{height:40px}

/* 10/30 추가: 로그인 유지 · 숨긴 반 */
.keep{display:flex; align-items:center; gap:7px; font-size:13.5px; color:var(--muted); margin:2px 0 12px; cursor:pointer; user-select:none}
.keep input{width:17px; height:17px; accent-color:var(--accent,#B0272A)}
.frow.hid{opacity:.6}
.frow .badge{display:inline-block; font-size:11px; font-weight:700; padding:1px 7px; border-radius:99px; background:#EEE; color:#666; vertical-align:2px}
.frow button.sm+button.sm{margin-left:6px}

/* 10/30 추가: 반 공지 · 풀이 영상 · 정답률 */
.notice{background:#FFF7E6; border:1px solid #F1DDB0; border-radius:14px; padding:12px 14px; margin:0 0 12px}
.notice .nh{font-size:13px; font-weight:700; color:#8A5A00; display:flex; gap:8px; align-items:baseline; margin-bottom:4px}
.notice .nh .fm{font-weight:400}
.notice .nt{white-space:pre-wrap; font-size:14.5px; line-height:1.65; color:var(--ink); word-break:keep-all}
.notice.edit textarea{width:100%; box-sizing:border-box; border:1px solid var(--line2); border-radius:9px; padding:8px 10px; font:inherit; font-size:14.5px; background:#fff; margin:4px 0 6px}
.vlist{display:grid; grid-template-columns:repeat(auto-fill,minmax(200px,1fr)); gap:10px}
.vcard{display:flex; flex-direction:column; background:#fff; border:1px solid var(--line); border-radius:12px; overflow:hidden; color:var(--ink); text-decoration:none}
.vcard img,.vcard .noimg{width:100%; aspect-ratio:16/9; object-fit:cover; background:#222; display:block}
.vcard .noimg{color:#fff; font-size:28px; display:flex; align-items:center; justify-content:center}
.vcard span{padding:8px 10px; font-size:13.5px; line-height:1.4; word-break:keep-all}
.vcard:hover{border-color:var(--accent,#B0272A)}
.vedit{display:flex; flex-direction:column; gap:6px}
.vrow{display:flex; gap:6px; align-items:center}
.vrow input{height:36px; border:1px solid var(--line2); border-radius:8px; padding:0 8px; font:inherit; font-size:14px; min-width:0; background:#fff}
.vrow .vno{width:56px; flex:none}.vrow .vt{flex:1}.vrow .vu{flex:1.3}
@media (max-width:560px){ .vrow{flex-wrap:wrap} .vrow .vu{flex-basis:100%} }
.rategrid{display:grid; grid-template-columns:repeat(auto-fill,minmax(48px,1fr)); gap:4px}
.rategrid div{border-radius:7px; padding:4px 0; text-align:center; font-size:12px; line-height:1.3}
.rategrid b{display:block}

.gfoot{text-align:center; font-size:12px; color:var(--muted); padding:18px 0 28px}
footer a,.gfoot a{color:var(--muted)}

/* 10/30 추가: 새 글 점 · 과제 경고 · 시스템 상태 · 변경 기록 */
.tab.hasnew,#seg button.hasnew{position:relative}
.tab.hasnew::after,#seg button.hasnew::after{content:""; position:absolute; top:4px; right:2px; width:7px; height:7px; border-radius:50%; background:#E0302F}
#seg button.hasnew::after{top:2px; right:2px}
.hwwarn{background:#FDECEC; border:1px solid #F3C4C4; border-radius:12px; padding:10px 12px; margin:0 0 12px; font-size:13.5px; color:#8E1F22}
.hwwarn div{display:flex; flex-wrap:wrap; gap:6px 12px; margin-top:6px; color:var(--ink)}
.hwwarn span b{color:#B0272A}
.strow{display:flex; gap:8px; align-items:baseline; padding:6px 0; border-bottom:1px solid var(--line); font-size:14px}
.strow:last-child{border-bottom:0}
.strow b{min-width:86px; flex:none}
.strow .dot{width:9px; height:9px; border-radius:50%; flex:none; align-self:center}
.strow .dot.ok{background:#2E9E5B}.strow .dot.bad{background:#E0302F}
.stalert{background:#FDECEC; color:#8E1F22; border-radius:10px; padding:9px 11px; font-size:13.5px; font-weight:600; margin-bottom:8px}
table.audit td{font-size:13px; vertical-align:top; padding:6px 6px}
table.audit td.dt{white-space:nowrap; color:var(--muted)}

/* 10/30 추가: 반 지우기 */
button.sm.danger{color:#fff; background:#B0272A; border-color:#B0272A}
.delconfirm{background:#FDECEC; border:1px solid #F3C4C4; border-radius:12px; padding:12px; margin-top:10px; font-size:13.5px; line-height:1.7; color:#5A1416}
.delconfirm input{display:block; width:100%; box-sizing:border-box; height:38px; margin-top:6px; border:1px solid #E3A9A9; border-radius:9px; padding:0 10px; font:inherit; background:#fff}

/* 10/30 폰 화면 손보기: 탭이 화면 밖으로 숨지 않게 두 줄로, 안내 링크·체크박스 색 통일 */
@media (max-width:560px){
  .tabs{flex-wrap:wrap; overflow:visible; row-gap:0}
  .tab{padding:9px 10px; font-size:14px}
}
.note a{color:var(--brand); font-weight:600}
input[type=checkbox]{accent-color:#B0272A}
table.audit{width:100%} table.audit td{word-break:keep-all} table.audit td:last-child{overflow-wrap:anywhere} table.audit td.dt{white-space:nowrap}
.annbox{background:#F7F5F1; border:1px solid var(--line); border-radius:12px; padding:12px; margin-top:10px; font-size:13.5px} .annbox .fm{margin-top:8px} .annbox textarea{display:block; width:100%; box-sizing:border-box; margin-top:4px; border:1px solid var(--line2); border-radius:9px; padding:8px 10px; font:inherit; font-size:13px; line-height:1.55; resize:vertical; background:#fff}
.seencls{margin:4px 0 12px} .seengrid{display:flex; flex-wrap:wrap; gap:6px; margin-top:6px} .seen{display:inline-flex; flex-direction:column; align-items:center; min-width:64px; padding:5px 8px; border-radius:9px; font-size:13px; font-weight:600; background:#EEF6F0; color:#1F5E36} .seen i{font-style:normal; font-weight:400; font-size:11px; opacity:.8} .seen.mid{background:#FFF3E0; color:#8A4B00} .seen.bad{background:#FDECEC; color:#9B1C1F} .seen.t{background:#F1F0EE; color:#6B6660}

/* 2026-10-31 학생 홈 '이번 주 할 것' · 내 성적표에서 넘어온 회차 표시 */
.week .wrow{display:flex; gap:12px; padding:9px 0; border-top:1px solid var(--line2); font-size:14px; line-height:1.5}
.week .ch+.wrow{border-top:0; padding-top:2px}
.week .wl{flex:none; width:64px; font-size:12.5px; font-weight:700; color:var(--muted); padding-top:1px}
.week .wv{flex:1; min-width:0; word-break:keep-all; overflow-wrap:anywhere}
.week .wv b.me{color:var(--brand)}
.empty .fm{margin-top:6px}
.frow.mark{border-color:var(--brand); box-shadow:0 0 0 2px var(--brand-l)}
.fgrp.mark .gh{color:var(--brand)}
/* 2026-10-31 자료 회차 · 학부모 접속 · 다시 풀기 모음 */
.edbar.upno{flex-wrap:wrap; gap:6px 10px; align-items:center; margin:4px 0 6px}
.edbar.upno label{font-size:13px; font-weight:700; color:var(--brand-d); display:flex; align-items:center; gap:6px}
.edbar.upno input{width:64px; height:32px; border:1px solid var(--line2); border-radius:8px; padding:0 8px; font:inherit; font-size:14px; text-align:center}
.seen i.par{color:#3A6EA5}
.retrylist{display:flex; flex-direction:column; gap:6px}
.retrylist .rrow{display:flex; flex-wrap:wrap; gap:4px 10px; align-items:baseline; font-size:13.5px; padding:8px 10px; border:1px solid var(--line2); border-radius:10px; background:var(--card)}
.retrylist .stuck{color:#8A5A00} .retrylist .ok{color:#2E7D4F}
/* 2026-10-31 자료 보기 화면 · 다른 반 접기 */
.pv{position:fixed; inset:0; z-index:1000; background:#3A3A3C; display:flex; flex-direction:column}
.pvbar{display:flex; align-items:center; gap:8px; padding:8px 10px; background:#1A1718; color:#fff; flex:none}
.pvbar button{appearance:none; border:0; border-radius:8px; font:inherit; font-size:14px; font-weight:600; padding:8px 12px; cursor:pointer}
.pvx{background:transparent; color:#fff} .pvs{background:var(--brand); color:#fff}
.pvt{flex:1; min-width:0; font-size:14px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap}
.pvbody{flex:1; overflow:auto; -webkit-overflow-scrolling:touch; padding:8px; display:flex; flex-direction:column; align-items:center; gap:8px}
.pvbody .hint{color:#ddd; padding:30px 10px}
.pvpg{background:#fff; display:block; box-shadow:0 1px 4px rgba(0,0,0,.4)}
.pvimg{max-width:100%; height:auto; background:#fff}
.tab[hidden],.cls[hidden]{display:none!important}
/* 다른 반은 작게 + 탭줄 맨 끝으로 (AI 질문·내 성적표가 앞에 오게) */
.tab.othtog,.tab.oth{order:9; font-size:12px; font-weight:500; padding:10px 6px; color:var(--muted)}
.tab.oth.active{color:var(--brand)}
#othCls{margin:8px 0 0}
/* 2026-10-31 재시험 · 학부모 문구 · 과제표 사진 */
.mklist{display:flex; flex-direction:column; gap:6px}
.mkrow{display:flex; align-items:center; gap:8px; font-size:14px}
.mkrow .nm{min-width:72px; font-weight:600}
.mkrow input{width:56px; height:32px; border:1px solid var(--line2); border-radius:8px; text-align:center; font:inherit}
.mkrow input.saved{border-color:#9CCDB0; background:#F1F9F3} .mkrow input.bad{border-color:#B0272A}
.mkst{font-size:12px; border-radius:999px; padding:2px 9px; background:#FFF1DE; color:#8A5A00} .mkst.ok{background:#E5F3EA; color:#2E7D4F}
.pmrow{border:1px solid var(--line2); border-radius:10px; padding:10px 12px; margin:8px 0; background:var(--card)}
.pmh{display:flex; align-items:center; gap:8px} .pmh button{margin-left:auto}
.pmt{white-space:pre-wrap; word-break:keep-all; font:inherit; font-size:13px; line-height:1.6; margin:6px 0 0; color:var(--ink)}
.hwscan{flex-wrap:wrap; gap:6px 10px; margin-bottom:8px}
table.hw input.ai{background:#FFF4C2; border-color:#E8C547}
/* 2026-10-31 과제 체크 모드 */
.hwmode{flex-wrap:wrap; gap:6px; margin-bottom:6px}
table.hw button.ck{width:100%; min-width:44px; height:36px; border:1px solid var(--line2); border-radius:8px; background:#fff; font:inherit; font-size:16px; font-weight:700; cursor:pointer; color:var(--muted)}
table.hw button.ck.o{background:#E5F3EA; border-color:#9CCDB0; color:#2E7D4F}
table.hw button.ck.t{background:#FFF1DE; border-color:#F0C27A; color:#8A5A00}
table.hw button.ck.x{background:#FDECEC; border-color:#E8A9A9; color:#B0272A}
table.hw button.ck.bad{outline:2px solid #B0272A}
/* 2026-10-31 내 숙제 기록 (부산대성 반 학생) */
.selfsum .ssrow{display:flex; gap:8px; margin:6px 0 10px}
.selfsum .sst{flex:1; background:var(--soft); border-radius:10px; padding:10px 6px; text-align:center}
.selfsum .sst b{display:block; font-size:20px; color:var(--brand)} .selfsum .sst span{font-size:11.5px; color:var(--muted)}
.selfsum .ssbars{display:flex; align-items:flex-end; gap:6px; height:70px; padding:0 2px}
.selfsum .ssbars div{flex:1; height:100%; display:flex; flex-direction:column; justify-content:flex-end; align-items:center}
.selfsum .ssbars i{display:block; width:100%; max-width:26px; background:#2E7D4F; border-radius:5px 5px 0 0; min-height:0}
.selfsum .ssbars span{font-size:10.5px; color:var(--muted); margin-top:3px}
.selfsum .cheer{margin:10px 0 0; font-size:14px; font-weight:600}
.selfbtns{display:flex; gap:4px; margin-top:8px}
.selfbtns button{appearance:none; flex:1; min-width:0; border:1px solid var(--line2); background:#fff; border-radius:999px; padding:9px 0; font:inherit; font-size:13px; cursor:pointer; color:var(--muted)}
.selfbtns button.on{background:#2E7D4F; border-color:#2E7D4F; color:#fff; font-weight:700}
.rbmonth{background:#fff; border:1px solid #E7E4DF; border-radius:12px; padding:10px 12px; margin:8px 0}
.rbmonth summary{cursor:pointer; font-size:15px}
.rbook th .fm{font-weight:400; font-size:11px}

/* 학생 관리 표: 새 코드 버튼까지 한 화면에 (2026-10-31) */
.rster{width:100%; font-size:14px}
.rster td,.rster th{padding:8px 4px}
.rster th{font-size:12.5px; white-space:nowrap}
.rster td.pin{font-size:15px; letter-spacing:0}
.rster button.sm{height:30px; padding:0 8px; font-size:12.5px; margin:0}
.rster td.btns{white-space:nowrap}
.rster td.btns button+button{margin-left:3px}
.rster input.memo{width:100%; min-width:76px; max-width:120px; box-sizing:border-box}
.rster td.lastc{white-space:nowrap; font-size:12px; color:#6C6F77}

/* 홈 확인할 것 · 연속 결석 (2026-10-31) */
.alrt{display:flex; width:100%; align-items:center; gap:6px; text-align:left; background:#F7F6F3; border:1px solid #E7E4DF; border-radius:10px; padding:10px 12px; margin:6px 0 0; font-size:14.5px; color:inherit; cursor:pointer; font-family:inherit}
.alrt span{margin-left:auto; color:#B0272A; font-weight:700; font-size:13px; white-space:nowrap}
.alrt.warn{background:#FFF6D6; border-color:#F1D98A}
.alrt.bad{background:#FBEAEA; border-color:#EBC0C0}
.alrt.kakaodown{flex-wrap:wrap; cursor:default; border-width:2px; border-color:#D9534F}
.alrt.kakaodown span{white-space:normal; margin-left:0; width:100%; font-weight:400; color:#7A2E2E}
.seenmore{margin-top:10px}
.seenmore summary{cursor:pointer; font-size:14px; color:#6C6F77}
.streak{display:inline-block; margin-top:2px; background:#B0272A; color:#fff; font-size:11.5px; font-weight:700; border-radius:6px; padding:1px 6px; white-space:nowrap}
.rster td.lastc.stale{color:#B0272A; font-weight:700}

/* 학생 추가·빼기 (2026-10-31) */
button.rmst{display:block; margin-top:3px; background:none; border:0; padding:0; color:#9A9A9A; font-size:11.5px; text-decoration:underline; cursor:pointer; font-family:inherit}
button.rmst.warn{color:#fff; background:#B0272A; border-radius:6px; padding:1px 6px; text-decoration:none}
.rsaddf{display:flex; flex-wrap:wrap; gap:8px; align-items:center; background:#fff; border:1px solid #E7E4DF; border-radius:12px; padding:10px; margin:8px 0}
.rsaddf .sel{flex:1 1 160px; margin:0}
.rsaddf input{height:38px; border:1px solid #DDD9D3; border-radius:10px; padding:0 10px; font-size:14px; flex:1 1 150px}

/* 상담 카드 · 메모 · 보충 (2026-10-31) */
button.stname{background:none; border:0; padding:0; font:inherit; font-weight:800; color:#1A1718; cursor:pointer; text-decoration:underline; text-decoration-color:#DDD9D3; text-underline-offset:3px}
button.stname:hover{color:#B0272A}
.memob{font-size:11.5px; color:#6C6F77}
.mkchk{display:flex; align-items:center; gap:4px; margin-top:4px; font-size:12px; color:#6C6F77; white-space:nowrap; cursor:pointer}
.mkchk input{width:auto; height:auto; margin:0}
.stcard .sc-top{font-size:20px; margin-bottom:10px}
.sc-kpis{display:grid; grid-template-columns:repeat(5,1fr); gap:8px; margin-bottom:6px}
.sc-kpis div{background:#F7F6F3; border-radius:10px; padding:8px; text-align:center}
.sc-kpis i{display:block; font-style:normal; font-size:12px; color:#6C6F77}
.sc-kpis b{font-size:18px}
.sc-kpis b.bad,.stcard .bad{color:#B0272A}
.stcard .ok{color:#2E7D4F; font-weight:700}
.sc-sec{margin-top:16px}
.sc-h{font-weight:800; color:#8C1E21; margin-bottom:6px}
.sc-memoadd{display:flex; gap:8px; align-items:flex-end; margin-bottom:8px}
.sc-memoadd textarea{flex:1; border:1px solid #DDD9D3; border-radius:10px; padding:8px; font:inherit; font-size:14px}
.sc-memo{border-left:3px solid #F1D98A; background:#FFFBEA; padding:6px 10px; margin:6px 0; font-size:14px; border-radius:0 8px 8px 0}
.sc-hw{display:flex; flex-wrap:wrap; gap:6px}
.hwb{background:#F7F6F3; border-radius:8px; padding:4px 8px; font-size:13px}
.hwb.bad{background:#FBEAEA; color:#B0272A}
@media (max-width:560px){ .sc-kpis{grid-template-columns:repeat(3,1fr)} }
.sc-memo button.rmst{display:inline; margin:0 0 0 8px}
/* 메모 종류·고치기 (2026-11-08) */
.sc-memoadd select{height:36px; border:1px solid #DDD9D3; border-radius:10px; padding:0 6px; font:inherit; font-size:13px; background:#fff}
.sc-memoedit{margin:6px 0 2px; flex-wrap:wrap}
.sc-memof{display:flex; flex-wrap:wrap; gap:4px 12px; margin:2px 0 4px}
.sc-memof button.rmst{display:inline; margin:0; font-size:12.5px}
.sc-memof button.rmst.on{color:#8C1E21; font-weight:800; text-decoration:none}
.sc-memof button.rmst:disabled{opacity:.45; cursor:default}
.sc-sec .msg.bad{color:#B0272A; font-size:13px; font-weight:600; margin:-2px 0 8px; line-height:1.45}
.sc-sec .msg:empty{display:none}
.mkb{display:inline-block; border-radius:6px; padding:0 6px; font-size:11.5px; font-weight:700; color:#fff; background:#9A9A9A}
.mkb.mk-0{background:#2E6DB4}
.mkb.mk-1{background:#B0272A}
@media (max-width:560px){ .sc-memoadd{flex-wrap:wrap} .sc-memoadd textarea{min-width:100%; font-size:16px} .sc-memoadd select{font-size:16px} }   /* 아이폰 16px 미만 칸은 확대됨 */
/* 학생 관리 필터 (2026-10-31) */
.rsflt{display:flex; flex-wrap:wrap; gap:6px; margin:10px 0 2px}
.rsflt button{height:32px; padding:0 12px; border:1px solid #DDD9D3; border-radius:16px; background:#fff; color:#4A4A4A; font-size:13px; cursor:pointer; font-family:inherit}
.rsflt button b{margin-left:3px; color:#B0272A}
.rsflt button.on{background:#1A1718; border-color:#1A1718; color:#fff}
.rsflt button.on b{color:#FFD9D9}
.rsflt button.zero{opacity:.55}
.nomkb{display:inline-block; margin-top:2px; background:#FFF6D6; color:#8A6A00; border:1px solid #F1D98A; font-size:11px; font-weight:700; border-radius:6px; padding:0 5px; white-space:nowrap}
/* 지난 날짜 경고 (2026-10-31) */
.pastbar{display:flex; align-items:center; gap:8px; flex-wrap:wrap; background:#FFF0C2; border:2px solid #E8A317; border-radius:12px; padding:10px 12px; margin:8px 0; font-size:15px; color:#5B4A12}
.pastbar .sm{margin-left:auto; background:#1A1718; color:#fff; border-color:#1A1718}
#rsDate.past{border:2px solid #E8A317; background:#FFF6D6}
/* 정렬 머리글 (2026-10-31) */
.rster th.sortable{cursor:pointer; user-select:none; text-decoration:underline dotted #C9C4BC; text-underline-offset:3px}
.rster th.sortable:hover,.rster th.sortable.on{color:#B0272A}
/* 출석부 칸 바로 고치기 (2026-10-31) */
.rbook td.cell{cursor:pointer; min-width:34px}
.rbook td.cell:hover{outline:2px solid #E8A317; outline-offset:-2px}
.rbook td.cell.busy{opacity:.4}
/* 결석 보충 카드 (학생, 2026-11-05) */
.mkc{background:#EEF5FF; border-color:#C9DBF5}
.mkc .mkrow{display:flex; gap:10px; align-items:center; justify-content:space-between; padding:8px 0; border-top:1px dashed #C9DBF5}
.mkc .mkrow a{color:#1D4E9E; font-weight:600; text-decoration:none; margin-right:6px}
.mkc .mkrow button{flex:none}
/* 회차별 진도 및 숙제 (2026-11-04): 한 칸에 진도 줄 + 숙제 줄 */
.rt .pgl{margin:1px 0}
.rt .pgl+.pgl{margin-top:5px}
.rt .tag{display:inline-block; font-size:11px; font-weight:700; color:#6B6B6B; background:#EFEDE8; border-radius:6px; padding:1px 6px; margin-right:6px; vertical-align:1px}
.rt .tag.hw{color:#B0272A; background:#FBE9E9}
/* 다시 풀어 보기 안내 (학생, 2026-11-04) */
.rnudge{background:#F3F8EE; border-color:#CFE3BD}
/* 결석 미리 알리기 (2026-11-04) */
.plc{background:#F5F3FB; border-color:#DCD5EE}
.planf{display:flex; flex-wrap:wrap; gap:6px; margin:6px 0 4px}
.planf input{flex:1 1 140px; min-width:0; font-size:16px}
.plbtn{margin:0 0 10px}
.planb{display:inline-block; margin-left:6px; font-size:11px; font-weight:700; color:#5B4A9B; background:#EEEAF8; border-radius:6px; padding:1px 6px}
/* 반 화면 카드 접기 (학생, 2026-11-04): 접힌 카드는 제목 한 줄 */
.notice.foldable .nh{cursor:pointer}
.notice.foldable .nh::after{content:'접기 ▴'; margin-left:auto; font-size:11px; font-weight:400; color:#8A8F99; white-space:nowrap; flex:none}
.notice.fold{padding:9px 14px; margin-bottom:8px}
.notice.fold .nh{margin-bottom:0}
.notice.fold .nh::after{content:'펼치기 ▾'}
.notice.fold > :not(.nh){display:none !important}

/* 2026-11-04 입장 화면 학생이세요? / 학부모님이세요? 이용 안내 버튼 */
.who{display:flex;gap:8px;margin:12px 0 4px}
.whob{flex:1;display:flex;flex-direction:column;align-items:center;gap:1px;background:#fff;border:1px solid var(--line2,#E7E4DF);border-radius:12px;padding:10px 6px;text-decoration:none;color:var(--ink,#1A1718);font-weight:700;font-size:14.5px}
.whob small{font-weight:400;font-size:12px;color:#8A8F99}
.whob:active{background:#F5F4F1}
/* 11/04 반 화면 맨 아래 이용 안내 한 줄 */
.cguide{text-align:center;font-size:13px;color:#6C6F77;margin:18px 0 4px}
.cguide a{color:#6C6F77}
/* 11/28 학생별 성적 변화 — 줄 안 바꾸는 작은 회색 글씨 */
.fmi{font-size:11.5px; color:var(--muted); font-weight:400}
