
/* Layout: Arena GM web app. Sign-in card; student start page with module cards; instructor course pages with a student x module matrix as the loud element. Modules run in a full-width frame under a slim nav bar. */
:root {
  --bg: #EDF1F5;
  --surface: #FFFFFF;
  --surface-2: #F5F7FA;
  --ink: #132030;
  --muted: #586678;
  --line: #D2DAE3;
  --accent: #1B4FA0;
  --accent-ink: #FFFFFF;
  --accent-soft: #E2EBF8;
  --seat-season: #143A78;
  --seat-single: #4D88E2;
  --seat-empty: #D5DDE6;
  --pitch: #6A9A5B;
  --pitch-2: #628F53;
  --pitch-line: rgba(255,255,255,.72);
  --good: #1C7549; --good-soft: #E0F2E8;
  --warn: #9A600C; --warn-soft: #FAEFD9;
  --bad: #B0291C; --bad-soft: #FAE6E3;
  --display: "Barlow Condensed", "Roboto Condensed", "Arial Narrow", sans-serif;
  --body: "Public Sans", "Segoe UI", system-ui, -apple-system, sans-serif;
  --r: 5px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0E141B; --surface: #161F29; --surface-2: #1B2532; --ink: #E4EBF2; --muted: #98A6B5; --line: #2B3747;
    --accent: #79A8F3; --accent-ink: #0A1424; --accent-soft: #1D2E48;
    --seat-season: #9DC0F8; --seat-single: #4F87DC; --seat-empty: #2A3544;
    --pitch: #2E4A2C; --pitch-2: #2A4428; --pitch-line: rgba(255,255,255,.38);
    --good: #57C690; --good-soft: #15332A; --warn: #E3AE55; --warn-soft: #3A2C14; --bad: #F2806F; --bad-soft: #3D1D1A;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0E141B; --surface: #161F29; --surface-2: #1B2532; --ink: #E4EBF2; --muted: #98A6B5; --line: #2B3747;
  --accent: #79A8F3; --accent-ink: #0A1424; --accent-soft: #1D2E48;
  --seat-season: #9DC0F8; --seat-single: #4F87DC; --seat-empty: #2A3544;
  --pitch: #2E4A2C; --pitch-2: #2A4428; --pitch-line: rgba(255,255,255,.38);
  --good: #57C690; --good-soft: #15332A; --warn: #E3AE55; --warn-soft: #3A2C14; --bad: #F2806F; --bad-soft: #3D1D1A;
  color-scheme: dark;
}
* { box-sizing: border-box; }
body { background: var(--bg); color: var(--ink); font-family: var(--body); font-size: 15px; line-height: 1.5; }
.wrap { max-width: 1340px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); padding-block: 18px 40px; }
h1, h2, h3 { font-family: var(--display); font-weight: 700; line-height: 1.1; text-wrap: balance; margin: 0; letter-spacing: .005em; }
h1 { font-size: 34px; }
h2 { font-size: 26px; }
h3 { font-size: 19px; font-weight: 600; }
p { margin: 0; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.num { font-variant-numeric: tabular-nums; }

/* header */
.top { display: flex; flex-wrap: wrap; gap: 12px 28px; align-items: end; justify-content: space-between; padding-bottom: 14px; border-bottom: 2px solid var(--ink); }
.brand { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.brand .mark { font-family: var(--display); font-weight: 700; font-size: 15px; color: var(--accent); letter-spacing: .06em; }
.brand h1 { font-size: 30px; }
.idchip { font-size: 13px; color: var(--muted); }
.idchip b { color: var(--ink); font-weight: 600; }

.steps { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 14px 0 20px; padding: 0; }
.steps button { font: inherit; font-size: 13px; display: flex; align-items: center; gap: 8px; padding: 7px 12px 7px 8px; border: 1px solid var(--line); background: var(--surface); color: var(--muted); border-radius: 999px; cursor: pointer; }
.steps button .n { font-family: var(--display); font-weight: 700; font-size: 14px; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); color: var(--muted); }
.steps button.done { color: var(--ink); }
.steps button.done .n { background: var(--good-soft); color: var(--good); }
.steps button.cur { border-color: var(--accent); color: var(--ink); font-weight: 600; }
.steps button.cur .n { background: var(--accent); color: var(--accent-ink); }
.steps button:disabled { cursor: not-allowed; opacity: .55; }

/* layout */
.grid { display: grid; grid-template-columns: minmax(0, 440px) minmax(0, 1fr); gap: 22px; align-items: start; }
.grid.wide { grid-template-columns: minmax(0, 1fr); }
@media (max-width: 960px) { .grid { grid-template-columns: minmax(0, 1fr); } }
.col { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.panel.quiet { background: var(--surface-2); }
.lede { font-size: 16px; }
.rule { height: 1px; background: var(--line); border: 0; margin: 2px 0; }

.event { border-left: 4px solid var(--accent); padding: 8px 12px; background: var(--surface-2); border-radius: 0 var(--r) var(--r) 0; display: flex; flex-direction: column; gap: 2px; }
.event .t { font-family: var(--display); font-weight: 700; font-size: 19px; }
.event.derby { border-left-color: var(--bad); }

/* controls */
.btn { font: inherit; font-weight: 600; font-size: 14px; padding: 9px 16px; border-radius: var(--r); border: 1px solid var(--accent); background: var(--accent); color: var(--accent-ink); cursor: pointer; }
.btn.ghost { background: transparent; color: var(--accent); }
.btn.plain { background: var(--surface); color: var(--ink); border-color: var(--line); }
.btn.small { padding: 5px 10px; font-size: 13px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.row.between { justify-content: space-between; }
button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
label { font-size: 13px; font-weight: 600; }
input[type="text"], input[type="number"], textarea { font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 7px 9px; }
input[type="number"] { width: 72px; text-align: right; font-variant-numeric: tabular-nums; }
input[type="range"] { width: 100%; accent-color: var(--accent); }
textarea { width: 100%; min-height: 230px; resize: vertical; line-height: 1.55; }

.prices { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 8px 12px; align-items: center; }
.prices .hint { font-size: 12px; color: var(--muted); text-align: right; }
.prices .s { font-weight: 600; font-size: 14px; }
.prices .s small { display: block; font-weight: 400; color: var(--muted); font-size: 12px; }
.inwrap { display: flex; align-items: center; gap: 4px; }
.inwrap span { color: var(--muted); font-size: 13px; }
.flag { font-size: 12px; color: var(--bad); }

.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { font: inherit; font-size: 13px; padding: 5px 11px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }

.status { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; padding: 3px 10px; border-radius: 999px; }
.status.ok { background: var(--good-soft); color: var(--good); }
.status.no { background: var(--bad-soft); color: var(--bad); }
.status.wait { background: var(--surface-2); color: var(--muted); }
.status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }

.note { font-size: 13px; padding: 10px 12px; border-radius: var(--r); background: var(--accent-soft); }
.note.warn { background: var(--warn-soft); color: var(--ink); }
.note.good { background: var(--good-soft); }

ol.arc { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }
ol.arc li::marker { font-family: var(--display); font-weight: 700; color: var(--accent); }
ul.plain { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 4px; }

/* board */
.board { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.boardhead { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: baseline; justify-content: space-between; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 0; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.kpi { padding: 10px 12px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); margin: 0 -1px -1px 0; display: flex; flex-direction: column; gap: 2px; }
.kpi .k { font-size: 12px; color: var(--muted); }
.kpi .v { font-family: var(--display); font-weight: 700; font-size: 27px; line-height: 1.05; font-variant-numeric: tabular-nums; }
.kpi .b { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.kpi.bad .v { color: var(--bad); }
.kpi.warn .v { color: var(--warn); }
.kpi.good .v { color: var(--good); }

.mapwrap { min-width: 0; }
svg.map { width: 100%; height: auto; display: block; max-width: 100%; }
svg.map .pitch { fill: var(--pitch); }
svg.map .pitch2 { fill: var(--pitch-2); }
svg.map .pl { fill: none; stroke: var(--pitch-line); stroke-width: 1.4; }
svg.map .d0 { fill: var(--seat-empty); }
svg.map .d1 { fill: var(--seat-single); }
svg.map .d2 { fill: var(--seat-season); }
svg.map .dl { fill: var(--muted); opacity: .55; }
svg.map .lbl { font-family: var(--display); font-weight: 700; font-size: 12.5px; fill: var(--ink); letter-spacing: .05em; }
svg.map .lbl2 { font-family: var(--body); font-size: 10.5px; fill: var(--muted); }
svg.map .lbl2 .hot { fill: var(--warn); font-weight: 700; }
svg.map .dim { opacity: .28; }
svg.map .hit { fill: transparent; cursor: pointer; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12px; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 10px; height: 10px; border-radius: 2px; display: inline-block; }

.tablewrap { overflow-x: auto; min-width: 0; }
table.data { width: 100%; border-collapse: collapse; font-size: 13.5px; font-variant-numeric: tabular-nums; }
table.data th { text-align: right; font-weight: 600; font-size: 12px; color: var(--muted); padding: 6px 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.data td { text-align: right; padding: 7px 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.data th:first-child, table.data td:first-child { text-align: left; }
table.data tr:last-child td { border-bottom: 0; }
table.data tfoot td { font-weight: 700; border-top: 1px solid var(--ink); }
.bar { display: inline-block; height: 6px; border-radius: 3px; background: var(--seat-single); vertical-align: middle; margin-left: 6px; }
.hotcell { color: var(--warn); font-weight: 600; }

.msgs { display: flex; flex-direction: column; gap: 8px; }
.msg { padding: 9px 12px; border-radius: var(--r); background: var(--surface-2); border-left: 3px solid var(--muted); font-size: 14px; }
.msg.bad { border-left-color: var(--bad); }
.msg.warn { border-left-color: var(--warn); }
.msg.good { border-left-color: var(--good); }
.msg .who { display: block; font-size: 12px; color: var(--muted); margin-bottom: 2px; }

.cmp { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; }
.cmpcard { border: 1px solid var(--line); border-radius: var(--r); padding: 12px; display: flex; flex-direction: column; gap: 6px; background: var(--surface); cursor: pointer; text-align: left; font: inherit; color: inherit; }
.cmpcard[aria-pressed="true"] { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.cmpcard .t { font-family: var(--display); font-weight: 700; font-size: 18px; }
.cmpcard dl { margin: 0; display: grid; grid-template-columns: auto auto; gap: 2px 10px; font-size: 13px; font-variant-numeric: tabular-nums; }
.cmpcard dt { color: var(--muted); }
.cmpcard dd { margin: 0; text-align: right; font-weight: 600; }

.quiz { display: flex; flex-direction: column; gap: 14px; }
.q { display: flex; flex-direction: column; gap: 6px; }
.q .qt { font-weight: 600; font-size: 14px; }
.opt { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; font-weight: 400; cursor: pointer; }
.opt input { margin-top: 3px; }
.fb { font-size: 13px; padding: 6px 10px; border-radius: var(--r); }
.fb.ok { background: var(--good-soft); }
.fb.no { background: var(--bad-soft); }

.chart svg { width: 100%; height: auto; display: block; }
.chart .ax { stroke: var(--line); }
.chart .barR { fill: var(--seat-single); }
.chart .barCap { fill: none; stroke: var(--ink); stroke-dasharray: 3 3; }
.chart text { font-family: var(--body); font-size: 11px; fill: var(--muted); }
.chart text.v { fill: var(--ink); font-weight: 600; }

.plan table.data td { padding: 4px 6px; }
.plan table.data th { text-align: center; white-space: normal; vertical-align: bottom; min-width: 92px; }
.plan table.data th:first-child { min-width: 150px; }
.plan table.data td { text-align: center; }
.plan .evh { display: flex; flex-direction: column; gap: 1px; align-items: center; }
.plan .evh b { font-family: var(--display); font-size: 15px; color: var(--ink); }
.plan .evh.derby b { color: var(--bad); }
.plan input[type="number"] { width: 64px; }
.plan input.over { border-color: var(--bad); color: var(--bad); }

.conds { display: flex; flex-direction: column; gap: 0; border: 1px solid var(--line); border-radius: var(--r); }
.cond { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; padding: 10px 12px; border-bottom: 1px solid var(--line); align-items: center; }
.cond:last-child { border-bottom: 0; }
.cond .l { font-size: 14px; }
.cond .l small { display: block; color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }

.split { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 18px; align-items: start; }
@media (max-width: 900px) { .split { grid-template-columns: minmax(0, 1fr); } }

.wordcount { font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.wordcount.ok { color: var(--good); }
.score { font-family: var(--display); font-weight: 700; font-size: 56px; line-height: 1; color: var(--accent); font-variant-numeric: tabular-nums; }
.memoout { white-space: pre-wrap; font-size: 14px; background: var(--surface-2); padding: 12px; border-radius: var(--r); }

details.inst { margin-top: 28px; background: var(--surface); border: 1px dashed var(--line); border-radius: var(--r); padding: 12px 16px; }
details.inst summary { cursor: pointer; font-weight: 600; }
details.inst .body { display: flex; flex-direction: column; gap: 14px; padding-top: 12px; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* start page */
.intro { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 22px; align-items: start; margin: 22px 0 28px; }
@media (max-width: 900px) { .intro { grid-template-columns: minmax(0, 1fr); } }
.idform { display: flex; flex-direction: column; gap: 6px; }
.idform input[type="text"] { min-width: 0; flex: 1 1 160px; max-width: 260px; text-transform: uppercase; }
.secthead { display: flex; justify-content: space-between; align-items: baseline; gap: 6px 16px; flex-wrap: wrap; margin: 6px 0 12px; }
.secthead h2 { margin: 0; }
section + section { margin-top: 26px; }
.mods { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.mod { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.mod.done { border-color: var(--good); }
.mod.prog { border-color: var(--accent); }
.mod.soon { background: var(--surface-2); border-style: dashed; }
.mhead { display: flex; gap: 12px; align-items: center; }
.mhead > div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.num { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-family: var(--display); font-weight: 700; font-size: 20px; background: var(--accent-soft); color: var(--accent); }
.mod.done .num { background: var(--good-soft); color: var(--good); }
.mt { font-family: var(--display); font-weight: 700; font-size: 19px; line-height: 1.15; }
.mod p { margin: 0; }
.bar { height: 6px; border-radius: 3px; background: var(--surface-2); overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--accent); border-radius: 3px; }
.mod.done .bar i { background: var(--good); }
.mod .row.between { margin-top: auto; }
a.btn { text-decoration: none; display: inline-block; }
.dots { display: flex; gap: 6px; flex-wrap: wrap; }
.dots i { width: 22px; height: 8px; border-radius: 4px; background: var(--surface-2); display: inline-block; }
.dots i.prog { background: var(--accent); } .dots i.done { background: var(--good); }
.warnline { color: var(--warn); }
.foot { margin-top: 28px; }
#overall a, .panel a { color: var(--accent); }
/* module view */
.modbar { padding-bottom: 0; }
.modbar .appnav { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; font-size: 13px; padding: 14px 0 0; }
.modbar .appnav a { color: var(--accent); text-decoration: none; font-weight: 600; }
.modbar .appnav a:hover { text-decoration: underline; }
.modbar .appnav .sp { flex: 1; }
#modframe { display: block; width: 100%; border: 0; min-height: 600px; background: var(--bg); }

/* ---------- web app ---------- */
a.mark { text-decoration: none; }
.center { padding: 18vh 0; text-align: center; }
.authwrap { min-height: 90vh; display: grid; place-items: center; }
.authcard { max-width: 480px; width: 100%; margin: 6vh auto; }
.authcard h1 { font-family: var(--display); font-weight: 700; font-size: 30px; margin: 0; line-height: 1.1; }
.authcard input[type="email"], .authcard input[type="text"] { width: 100%; }
.codebox summary { cursor: pointer; font-size: 14px; font-weight: 600; color: var(--accent); }
.codebox[open] summary { margin-bottom: 8px; }
.userbox { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 6px 10px; }
.coursehead { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; margin: 16px 0 6px; }
.coursehead .sp { flex: 1; }
.coursehead a { color: var(--accent); font-weight: 600; text-decoration: none; }
.code { font-family: var(--display); font-weight: 700; font-size: 1.15em; letter-spacing: .12em; color: var(--accent); }
.tabs { display: flex; flex-wrap: wrap; gap: 4px; border-bottom: 1px solid var(--line); margin: 6px 0 18px; }
.tab { padding: 9px 14px; font-size: 14px; font-weight: 600; color: var(--muted); text-decoration: none; border-bottom: 3px solid transparent; margin-bottom: -1px; }
.tab.on { color: var(--ink); border-bottom-color: var(--accent); }
.tab:hover { color: var(--ink); }
.badge { display: inline-block; min-width: 18px; padding: 0 6px; border-radius: 999px; background: var(--warn); color: #fff; font-size: 11.5px; line-height: 18px; text-align: center; }
.kpis4 { margin-bottom: 16px; }
table.matrix th, table.matrix td { text-align: center; padding: 6px 5px; }
table.matrix th:first-child, table.matrix td:first-child { text-align: left; }
table.matrix th.req { color: var(--ink); text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 3px; }
table.matrix td.who b { display: block; font-weight: 600; white-space: nowrap; }
table.matrix td.who small, table.matrix td small { display: block; color: var(--muted); font-size: 11px; }
table.matrix td.cell.sub { background: var(--good-soft); }
table.matrix td.cell.late { box-shadow: inset 0 0 0 2px var(--warn); }
table.matrix td.cell.overdue { background: var(--bad-soft); }
.cellbtn { font: inherit; font-weight: 700; font-variant-numeric: tabular-nums; background: none; border: 0; color: var(--ink); cursor: pointer; padding: 2px 4px; border-radius: 4px; }
.cellbtn:hover { background: var(--surface); }
.reviewgrid { display: grid; grid-template-columns: minmax(0, 330px) minmax(0, 1fr); gap: 18px; align-items: start; }
@media (max-width: 900px) { .reviewgrid { grid-template-columns: minmax(0, 1fr); } }
.sublist { gap: 6px; }
.subitem { font: inherit; text-align: left; display: flex; flex-direction: column; gap: 3px; padding: 9px 11px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); color: var(--ink); cursor: pointer; }
.subitem.on { border-color: var(--accent); box-shadow: inset 3px 0 0 var(--accent); }
.tag { display: inline-block; align-self: flex-start; font-size: 11px; font-weight: 600; padding: 1px 8px; border-radius: 999px; background: var(--surface-2); color: var(--muted); }
.tag.todo { background: var(--warn-soft); color: var(--ink); } .tag.draft { background: var(--accent-soft); color: var(--accent); } .tag.released { background: var(--good-soft); color: var(--good); }
.reviewcard { gap: 12px; }
.memotext { white-space: pre-wrap; text-align: justify; hyphens: auto; line-height: 1.6; padding: 12px 14px; border-radius: var(--r); background: var(--surface-2); font-size: 14.5px; }
.rubric { display: flex; flex-direction: column; gap: 8px; }
.rubrow { border: 1px solid var(--line); border-radius: var(--r); padding: 8px 12px; margin: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 14px; align-items: center; }
.rubrow legend { float: left; padding: 0; display: flex; flex-direction: column; gap: 2px; font-size: 14px; }
.rubrow legend small { color: var(--muted); font-size: 12px; font-weight: 400; }
.rubopts { display: flex; gap: 12px; }
.rubopts label { display: inline-flex; gap: 4px; align-items: center; font-weight: 600; font-size: 14px; }
@media (max-width: 560px) { .rubrow { grid-template-columns: minmax(0, 1fr); } }
.fbank { border: 1px dashed var(--line); border-radius: var(--r); padding: 8px 12px 10px; display: flex; flex-direction: column; gap: 8px; }
.fbgroup { display: flex; flex-direction: column; gap: 4px; }
.fbchips { display: flex; flex-wrap: wrap; gap: 6px; }
.fbchip { font: inherit; font-size: 13px; line-height: 1.35; text-align: left; color: var(--ink); background: var(--surface-2); border: 1px solid var(--line); border-radius: 12px; padding: 4px 10px; cursor: pointer; max-width: 100%; }
.fbchip:hover, .fbchip:focus-visible { border-color: var(--accent); background: var(--accent-soft); }
.fbchip.used { color: var(--muted); background: transparent; border-style: dashed; }
.fbchip.used::before { content: "✓ "; color: var(--good); }
.fbedit { gap: 10px; }
.fbset { border: 1px solid var(--line); border-radius: var(--r); padding: 8px 12px 10px; margin: 0; }
.fbset legend { padding: 0 4px; font-size: 14px; }
.fbset textarea { width: 100%; min-height: 64px; font-size: 13px; }
.fbgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 12px; }
@media (max-width: 760px) { .fbgrid { grid-template-columns: minmax(0, 1fr); } }
.toast { position: fixed; left: 50%; bottom: 20px; transform: translate(-50%, 120%); max-width: min(560px, calc(100vw - 32px)); padding: 11px 16px; border-radius: var(--r); background: var(--ink); color: var(--bg); font-size: 14px; box-shadow: 0 6px 24px rgba(0,0,0,.18); opacity: 0; transition: transform .25s, opacity .25s; z-index: 50; pointer-events: none; }
.toast.show { transform: translate(-50%, 0); opacity: 1; }
.toast.bad { background: var(--bad); color: #fff; }
details.fb { border-top: 1px solid var(--line); padding-top: 8px; }
details.fb summary { cursor: pointer; font-weight: 600; font-size: 13.5px; color: var(--accent); }
.rubline { display: flex; justify-content: space-between; font-size: 13px; padding: 2px 0; }
.fbtext { white-space: pre-wrap; text-align: justify; margin: 6px 0 0; }
a.courselink { text-decoration: none; color: var(--ink); }
a.courselink:hover { border-color: var(--accent); }
.kv2 { display: grid; grid-template-columns: auto auto; gap: 2px 12px; font-size: 13px; color: var(--muted); }
.kv2 b { color: var(--ink); text-align: right; font-weight: 600; }
table.settings td { vertical-align: middle; }
table.settings td.wrapc, table.roster td.wrapc { white-space: normal; text-align: left; }
table.settings input[type="datetime-local"] { font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 5px 7px; }
.modbar .appnav #syncstate { margin-left: 4px; }
.okc { color: var(--good); font-weight: 600; } .hot { color: var(--bad); } .warnline { color: var(--warn); }
input[type="email"] { font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 7px 9px; }
code { font-size: .95em; background: var(--surface-2); padding: 1px 5px; border-radius: 4px; }
.fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px 16px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field input[type="text"] { width: 100%; }
table.data td.wrap { white-space: normal; text-align: left; }
.foot a, .authcard a { color: var(--accent); }
/* MI-nyilatkozat, írásjelzések, szóbeli védés */
details.aipol { border-top: 1px solid var(--line); padding-top: 8px; margin-top: 4px; }
details.aipol summary { cursor: pointer; font-weight: 600; font-size: 13.5px; color: var(--accent); }
details.aipol p { text-align: justify; margin: 6px 0 0; }
.integ { border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; }
.integ h3 { margin: 0; }
.integ p { margin: 0; }
.integ details summary { cursor: pointer; font-weight: 600; font-size: 13px; color: var(--accent); }
.flags { display: flex; flex-wrap: wrap; gap: 6px; }
.flag { display: inline-block; font-size: 12px; font-weight: 600; padding: 2px 10px; border-radius: 999px; }
.flag.sus { background: var(--warn-soft); color: var(--warn); }
.flag.info { background: var(--accent-soft); color: var(--accent); }
.flag.ok { background: var(--good-soft); color: var(--good); }
.flaglist { margin: 0; padding-left: 18px; }
.flaglist li { margin: 2px 0; text-align: justify; }
table.mini th, table.mini td { white-space: normal; text-align: left; font-size: 13px; padding: 5px 8px; vertical-align: top; }
table.mini th { font-weight: 600; color: var(--muted); width: 42%; }
.flagdot { display: inline-block; margin-left: 3px; width: 15px; height: 15px; line-height: 15px; border-radius: 50%; background: var(--warn); color: #fff; font-size: 10.5px; font-style: normal; font-weight: 700; vertical-align: 1px; text-align: center; }
table.matrix td.cell.def { outline: 2px dashed var(--accent); outline-offset: -4px; }
.tags { display: flex; flex-wrap: wrap; gap: 4px; }
.tag.sus { background: var(--warn-soft); color: var(--warn); }
.tag.defn { background: var(--accent-soft); color: var(--accent); }
table.defs td { vertical-align: middle; }
table.defs td.acts { white-space: nowrap; text-align: right; }
.defsheet { gap: 12px; }
.defsheet h2 small { font-size: 15px; font-weight: 500; }
.qlist { margin: 0; padding-left: 22px; }
.qlist li { margin: 5px 0; text-align: justify; }
.sheetbar { margin-bottom: 10px; }
@media print {
  header.top, .noprint, .foot, .toast, #modview, #livestate { display: none !important; }
  body { background: #fff !important; color: #000; }
  .wrap { max-width: none; padding: 0; }
  .panel.defsheet { border: 0; box-shadow: none; padding: 0; background: #fff; }
  .defsheet .memotext { background: #fff; border: 1px solid #bbb; }
  .defsheet details { display: block; }
  .defsheet .kpi { border: 1px solid #bbb; background: #fff; }
}
table.defs th, table.defs td { text-align: left; }
table.defs th:last-child, table.defs td.acts { text-align: right; }
select { font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 7px 9px; max-width: 100%; }
/* másolásvédelem a modulnézetben (hallgatók, a kurzus beállítása szerint) */
@media print {
  .nocopy-mod #modview { display: none !important; }
  .nocopy-mod body::after { content: "A modulok nyomtatása ebben a kurzusban nem engedélyezett."; display: block; padding: 24px; font: 16px sans-serif; }
}
/* belépési mód választó, jelszó */
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; align-self: flex-start; margin: 4px 0 10px; }
.segbtn { font: inherit; font-size: 13.5px; font-weight: 600; padding: 7px 14px; border: 0; background: var(--surface); color: var(--muted); cursor: pointer; }
.segbtn + .segbtn { border-left: 1px solid var(--line); }
.segbtn.on { background: var(--accent); color: var(--accent-ink); }
input[type="password"] { font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 7px 9px; }
fieldset.pwset { border: 1px solid var(--line); border-radius: var(--r); padding: 10px 14px 12px; margin: 6px 0 4px; display: flex; flex-direction: column; gap: 6px; }
fieldset.pwset legend { font-size: 13px; font-weight: 700; padding: 0 4px; }
fieldset.pwset p { margin: 0 0 4px; }
/* időkeret */
.timerpill { position: fixed; top: 10px; right: 12px; z-index: 40; font-size: 13.5px; font-weight: 700; font-variant-numeric: tabular-nums; padding: 6px 12px; border-radius: 999px; background: var(--surface); color: var(--ink); border: 1px solid var(--line); box-shadow: 0 2px 10px rgba(0,0,0,.12); }
.timerpill.warn { background: var(--warn-soft); color: var(--warn); border-color: var(--warn); }
.timerpill.bad { background: var(--bad); color: #fff; border-color: var(--bad); }
.btn.disabled { opacity: .55; cursor: not-allowed; pointer-events: none; }
table.matrix td.cell small.warnline, table.matrix td.cell small.hot { display: block; font-size: 11px; font-weight: 600; }
table.settings input.tl { width: 86px; }
/* oktatótársak, egyéni beállítások, jegyek */
.cotlist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.cotlist li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 7px 10px; border: 1px solid var(--line); border-radius: var(--r); font-size: 14px; }
#cotform input { flex: 1; min-width: 200px; font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 7px 9px; }
.gdist { display: flex; flex-wrap: wrap; gap: 8px 18px; font-size: 14px; margin-bottom: 8px; }
.gdist b { font-size: 18px; margin-right: 4px; }
table.grades th, table.grades td { text-align: left; }
.grth { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
@media print { .timerpill { display: none !important; } }
[hidden] { display: none !important; }
/* 0. modul */
.introsteps { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 14px; }
.introsteps .chip.on { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.introbody { gap: 10px; }
.introbody p, .introbody li { text-align: justify; hyphens: auto; line-height: 1.6; }
.introbody h2 { margin-bottom: 2px; }
ul.introlist, ol.steplist { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }
table.introtab th, table.introtab td { text-align: left; white-space: normal; }
table.introtab td small { display: block; }
.policy { padding: 10px 12px; border-left: 3px solid var(--accent); background: var(--surface-2); border-radius: var(--r); }
fieldset.qitem { border: 1px solid var(--line); border-radius: var(--r); padding: 10px 14px; margin: 0; display: flex; flex-direction: column; gap: 6px; }
fieldset.qitem legend { font-weight: 600; font-size: 14.5px; padding: 0 4px; }
fieldset.qitem.ok { border-color: var(--good); }
fieldset.qitem.bad { border-color: var(--bad); }
fieldset.qitem p { margin: 2px 0 0; }
/* visszajelzés, hozzájárulás */
.fbpanel { border-color: var(--accent); }
fieldset.likert { border: 0; padding: 0; margin: 0; }
fieldset.likert legend { font-size: 14px; font-weight: 600; padding: 0; margin-bottom: 4px; }
.lk { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; }
.lk label { display: inline-flex; align-items: center; gap: 3px; font-weight: 600; font-size: 14px; }
.note.consent { text-align: justify; }
/* megbeszélés */
.debhead { align-items: end; margin-bottom: 12px; gap: 12px; }
.debhead .field { min-width: 260px; }
.dgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; margin: 14px 0; }
.dcard { gap: 8px; }
.dcard.wide { grid-column: 1 / -1; }
.dcard h3 { margin: 0; font-size: 15px; }
.barlist { display: flex; flex-direction: column; gap: 6px; }
.brow { display: grid; grid-template-columns: minmax(90px, 40%) 1fr auto; align-items: center; gap: 8px; font-size: 13px; }
.brow .bl { color: var(--ink); overflow-wrap: anywhere; }
.brow .bt { height: 14px; display: block; }
.brow .bt i { display: block; height: 100%; background: var(--accent); border-radius: 0 4px 4px 0; }
.brow .bv { font-variant-numeric: tabular-nums; font-weight: 600; color: var(--ink); white-space: nowrap; }
.brow .bv small { color: var(--muted); font-weight: 400; }
svg.strip { width: 100%; height: 40px; display: block; overflow: visible; }
svg.strip .axis { stroke: var(--line); stroke-width: 1; }
svg.strip .med { stroke: var(--muted); stroke-width: 1.5; }
svg.strip .dot { fill: var(--accent); stroke: var(--surface); stroke-width: 2; }
.stripaxis { display: flex; justify-content: space-between; gap: 8px; font-variant-numeric: tabular-nums; }
.kw { display: flex; flex-wrap: wrap; gap: 6px; }
.kwchip { font-size: 13px; padding: 3px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--ink); }
.kwchip small { color: var(--muted); }
.lkavg { display: flex; align-items: baseline; gap: 6px; font-size: 14px; padding: 3px 0; border-bottom: 1px solid var(--line); }
.lkavg span { flex: 1; }
.lkavg b { font-size: 18px; font-variant-numeric: tabular-nums; }
ul.comments { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 4px; font-size: 13.5px; }
ul.comments li { text-align: justify; }
/* kivetítés: nevek nélkül, nagyobb betű */
.projector header.top, .projector .coursehead, .projector nav.tabs, .projector .foot { display: none !important; }
.projector body { font-size: 18px; }
.projector .wrap { max-width: none; }
.projector .dgrid { grid-template-columns: repeat(auto-fill, minmax(420px, 1fr)); }
.projector .dcard h3 { font-size: 20px; }
.projector .brow { font-size: 17px; }
.projector .brow .bt { height: 20px; }
.projector .stripaxis, .projector .kwchip, .projector .lkavg { font-size: 16px; }
.projector svg.strip { height: 54px; }

/* záróprojekt: csapatok (oktatói nézet) */
.teamgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 400px), 1fr)); gap: 14px; margin: 16px 0; }
.tcard { gap: 10px; }
.tcard .field.grow { flex: 1; min-width: 0; }
.tcard .field.grow input { width: 100%; }
table.data.troles th { text-align: left; font-size: 13px; color: var(--ink); white-space: nowrap; }
table.data.troles td { text-align: left; }
table.data.troles select { width: 100%; min-width: 150px; }
table.data.troles td:last-child { white-space: nowrap; width: 1%; }
.qchips { display: flex; flex-wrap: wrap; gap: 6px; }
.qchip { font-size: 12px; padding: 2px 9px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); color: var(--muted); }

.peertab { display: flex; flex-direction: column; gap: 4px; }
.peertab table.mini td, .peertab table.mini th { padding: 3px 8px; font-size: 13px; }
.peerset { align-items: flex-end; }
.peernotes li { padding: 2px 0; }
.peerbox p { margin: 0 0 4px; }

.modctl { display: inline-flex; gap: 2px; margin-left: 8px; vertical-align: middle; }
.modctl .btn.small { padding: 2px 7px; min-height: 0; }
