/* Nedu – arkusz stylów (bez kroku budowania, motyw jak w NetiCRM) */
[hidden] { display: none !important; }
:root {
  --navy: #252459; --blue: #3650C1; --blue-dark: #2a3f9e; --ink: #1d1f2b; --text: #3b3f52; --muted: #5f6475;
  --line: #d9dce5; --line-soft: #eceef3; --bg: #f6f7fb; --white: #fff;
  --ok-bg: #e7f6ec; --ok: #166534; --warn-bg: #fff4e5; --warn: #92400e; --info-bg: #eef1fb; --prog-bg: #dfe5fa; --prog: #1f2f7a;
  --neutral-bg: #f1f2f5; --err-bg: #fdecea; --err: #9f1c12; --radius: 10px;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--ink); background: var(--bg); font-size: 15px; line-height: 1.45; }
a { color: var(--blue); } a:hover { color: var(--blue-dark); }
h1 { margin: 0; font-size: 26px; font-weight: 700; color: var(--navy); }
h2 { margin: 0; font-size: 17px; color: var(--navy); }
p { margin: 0; }
.muted { color: var(--muted); } .small { font-size: 13px; } .xs { font-size: 12px; }
.sr { position: absolute; left: -9999px; }
.sr:focus { left: 12px; top: 12px; z-index: 1000; background: #fff; color: var(--navy); padding: 10px 16px; border-radius: 8px; box-shadow: 0 4px 16px rgba(0,0,0,.18); font-weight: 600; }

/* układ */
.shell { min-height: 100vh; display: flex; flex-direction: column; }
.topbar { background: var(--white); border-bottom: 1px solid var(--line); }
.topbar-in { max-width: 1240px; margin: 0 auto; padding: 12px 24px; display: flex; flex-wrap: wrap; align-items: center; gap: 20px; }
.topbar-in.wide { max-width: none; }
.brand img { height: 26px; display: block; }
.nav { display: flex; flex-wrap: wrap; gap: 4px; flex: 1 1 400px; }
.nav a { padding: 10px 14px; border-radius: 8px; color: var(--text); text-decoration: none; font-weight: 500; font-size: 14px; }
.nav a.on { background: var(--info-bg); color: var(--navy); font-weight: 600; }
.who { display: flex; align-items: center; gap: 10px; }
.avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--blue); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: 14px; flex: none; }
.who-text { display: flex; flex-direction: column; line-height: 1.25; }
.who-text b { font-size: 14px; } .who-text span { font-size: 12px; color: var(--muted); }
.linkbtn { background: none; border: 0; color: var(--muted); font: inherit; font-size: 13px; cursor: pointer; padding: 8px; }
.linkbtn:hover { color: var(--blue); }
main.page { max-width: 1240px; width: 100%; margin: 0 auto; padding: 28px 24px 40px; display: flex; flex-direction: column; gap: 22px; flex: 1; }
.admin-wrap { display: flex; flex-wrap: wrap; flex: 1; }
.sidenav { flex: 1 1 220px; max-width: 250px; background: var(--white); border-right: 1px solid var(--line); padding: 20px 12px; display: flex; flex-direction: column; gap: 2px; }
.sidenav a { padding: 10px 12px; border-radius: 8px; color: var(--text); text-decoration: none; font-weight: 500; font-size: 14px; display: flex; justify-content: space-between; }
.sidenav a.on { background: var(--info-bg); color: var(--navy); font-weight: 600; }
.sidenav .label { margin: 16px 12px 6px; font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.count { background: var(--blue); color: #fff; border-radius: 999px; font-size: 11px; padding: 1px 7px; font-weight: 600; }
main.admin { flex: 999 1 560px; min-width: 0; padding: 28px 28px 40px; display: flex; flex-direction: column; gap: 20px; }
.foot { display: flex; justify-content: center; align-items: center; gap: 8px; width: max-content; margin: 14px auto 12px; padding: 6px 14px; border-radius: 999px;
  background: rgba(255,255,255,.82); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); font-size: 11px; color: var(--muted); }
.foot img { height: 12px; display: block; }

/* elementy */
.head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.head-l { display: flex; flex-direction: column; gap: 4px; }
.back { font-size: 14px; font-weight: 500; text-decoration: none; }
.card { background: var(--white); border: 1px solid var(--line); border-radius: 12px; padding: 20px; }
.card > h2 { margin-bottom: 12px; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.row { display: flex; flex-wrap: wrap; gap: 20px; align-items: flex-start; }
.col-main { flex: 999 1 540px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.col-side { flex: 1 1 320px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 14px; }
.grid-4 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 16px; }
.tile { background: var(--white); border: 1px solid var(--line); border-radius: 12px; padding: 18px 20px; text-decoration: none; color: inherit; display: flex; flex-direction: column; gap: 10px; }
.tile .k { font-size: 13px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }
.tile .v { font-size: 26px; font-weight: 700; color: var(--navy); }
.kv { display: flex; justify-content: space-between; gap: 8px; font-size: 13px; }
.kv span { color: var(--muted); }
.list-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding: 13px 0; border-top: 1px solid var(--line-soft); text-decoration: none; color: inherit; }
.list-row:first-of-type { border-top: 0; }
.list-row .grow { flex: 1 1 260px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.badge { display: inline-block; padding: 3px 9px; border-radius: 999px; font-size: 12px; font-weight: 600; white-space: nowrap; background: var(--neutral-bg); color: var(--text); }
.b-info { background: var(--info-bg); color: var(--navy); } .b-neutral { background: var(--neutral-bg); color: var(--text); }
.b-progress { background: var(--prog-bg); color: var(--prog); } .b-warning { background: var(--warn-bg); color: var(--warn); }
.b-success { background: var(--ok-bg); color: var(--ok); } .b-muted { background: var(--neutral-bg); color: var(--muted); }
.b-danger { background: var(--err-bg); color: var(--err); }
.bar { height: 8px; border-radius: 999px; background: var(--line-soft); overflow: hidden; } .bar > i { display: block; height: 8px; background: var(--blue); }
.alert { padding: 13px 16px; border-radius: 12px; font-size: 14px; }
.alert-ok { background: var(--ok-bg); color: #14532d; } .alert-err { background: var(--err-bg); color: var(--err); }
.alert-warn { background: var(--warn-bg); color: #7a3306; border: 1px solid #f5d7a8; display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
.alert-warn .grow { flex: 1 1 320px; display: flex; flex-direction: column; gap: 2px; }

/* formularze i przyciski */
label { font-size: 13px; font-weight: 500; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field .hint { font-size: 12px; color: var(--muted); }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=time], input[type=number], input[type=url], input[type=search], select, textarea {
  height: 44px; font: inherit; font-size: 14px; padding: 0 12px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; color: var(--ink); width: 100%; }
textarea { height: auto; padding: 10px 12px; resize: vertical; min-height: 90px; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 2px var(--blue); }
.check { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 400; }
.check input { width: 18px; height: 18px; accent-color: var(--blue); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 18px; border: 0; border-radius: var(--radius); background: var(--blue); color: #fff; font: inherit; font-weight: 600; font-size: 14px; cursor: pointer; text-decoration: none; white-space: nowrap; }
.btn:hover { background: var(--blue-dark); color: #fff; }
.btn-2 { background: #fff; color: var(--ink); border: 1px solid var(--line); font-weight: 500; }
.btn-2:hover { background: #fafbfd; color: var(--ink); border-color: #b9bfcf; }
.btn-ok { background: #fff; color: var(--ok); border: 1px solid var(--ok); }
.btn-warn { background: #fff; color: var(--warn); border: 1px solid var(--warn); }
.btn-danger { background: #fff; color: var(--err); border: 1px solid #e5b6b1; }
.btn-sm { height: 36px; padding: 0 12px; font-size: 13px; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.err { color: var(--err); font-size: 12px; }
.pills { display: flex; flex-wrap: wrap; gap: 8px; }
.pill { height: 40px; padding: 0 14px; border-radius: 999px; font-size: 14px; display: inline-flex; align-items: center; text-decoration: none; color: var(--text); background: #fff; border: 1px solid var(--line); font-weight: 500; }
.pill.on { background: var(--navy); color: #fff; border-color: var(--navy); font-weight: 600; }
.radio-card { display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 10px 14px; border-radius: 10px; border: 1px solid var(--line); cursor: pointer; }
.radio-card:has(input:checked) { border: 2px solid var(--blue); background: var(--info-bg); }
.radio-card input { width: 18px; height: 18px; accent-color: var(--blue); flex: none; }
.radio-card span { display: flex; flex-direction: column; gap: 2px; } .radio-card b { font-size: 14px; } .radio-card small { font-size: 12px; color: var(--muted); }
details.fold summary { cursor: pointer; list-style: none; } details.fold summary::-webkit-details-marker { display: none; }

/* tabele */
.table-box { overflow-x: auto; }
table.t { width: 100%; border-collapse: collapse; font-size: 14px; }
table.t th { text-align: left; color: var(--muted); font-size: 12px; font-weight: 600; padding: 10px 8px; }
table.t td { padding: 12px 8px; border-top: 1px solid var(--line-soft); vertical-align: middle; }
table.t td.num { white-space: nowrap; }
table.t a.title { color: var(--ink); text-decoration: none; font-weight: 500; }
.who-cell { display: flex; flex-direction: column; gap: 2px; } .who-cell small { font-size: 12px; color: var(--muted); }
.empty { padding: 26px 0; text-align: center; color: var(--muted); font-size: 14px; }

/* historia */
.timeline { display: flex; flex-direction: column; gap: 16px; }
.tl { display: flex; gap: 12px; }
.tl .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--blue); margin-top: 5px; flex: none; }
.tl .dot.client { background: #9aa0b2; } .tl .dot.internal { background: #b45309; }
.tl .body { display: flex; flex-direction: column; gap: 4px; flex: 1; min-width: 0; }
.tl .meta { display: flex; flex-wrap: wrap; gap: 8px; font-size: 13px; color: var(--muted); }
.tl .meta b { color: var(--ink); }
.tl .text { font-size: 14px; white-space: pre-line; overflow-wrap: anywhere; }
.files { display: flex; flex-wrap: wrap; gap: 8px; }
.files a { padding: 6px 10px; border-radius: 8px; background: var(--neutral-bg); font-size: 13px; text-decoration: none; color: var(--ink); }

/* kalendarz */
.week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); min-width: 700px; }
.day { container-type: inline-size; min-width: 0; display: flex; flex-direction: column; gap: 8px; padding: 12px 8px; min-height: 420px; border-left: 1px solid var(--line-soft); }
.day:first-child { border-left: 0; } .day.weekend { background: #fafbfd; }
.day-h { display: flex; flex-direction: column; gap: 2px; padding-bottom: 8px; border-bottom: 1px solid var(--line-soft); }
.day-h span { font-size: 12px; color: var(--muted); } .day-h b { font-size: 15px; } .day-h.today b { color: var(--blue); }
.ev { display: flex; flex-direction: column; gap: 2px; padding: 7px; border-radius: 8px; color: #fff; text-decoration: none; background: #5f6475; overflow: hidden; }
.ev:hover { color: #fff; filter: brightness(1.08); }
.ev.ticket { background: var(--blue); } .ev.contract { background: #b45309; } .ev.topic { background: #0f766e; } .ev.done { opacity: .55; }
.ev small { font-size: clamp(10px, 7cqi, 11px); opacity: .9; }
.ev b { font-size: clamp(10.5px, 8.5cqi, 13px); font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; hyphens: auto; }
.legend { display: flex; flex-wrap: wrap; gap: 16px; font-size: 12px; color: var(--text); }
.legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }

/* paginacja */
.pager { display: flex; gap: 6px; justify-content: center; padding-top: 12px; }
.pager a, .pager span { padding: 6px 12px; border-radius: 8px; border: 1px solid var(--line); text-decoration: none; font-size: 13px; color: var(--text); background: #fff; }
.pager span.on { background: var(--navy); color: #fff; border-color: var(--navy); }

@media (max-width: 760px) {
  main.page, main.admin { padding: 20px 16px 32px; }
  .sidenav { max-width: none; flex-direction: row; flex-wrap: wrap; border-right: 0; border-bottom: 1px solid var(--line); padding: 10px; }
  .sidenav .label { display: none; }
}

/* Tematy (1.1) */
.tl .dot.task { background: #0f766e; }
.stages { display: flex; flex-direction: column; }
.stage { display: flex; align-items: flex-start; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line-soft); flex-wrap: wrap; }
.stage:last-child { border-bottom: 0; }
.stage .grow { flex: 1; min-width: 160px; display: flex; flex-direction: column; gap: 2px; }
.stage.done b { color: var(--muted); text-decoration: line-through; }
.tick { width: 24px; height: 24px; border-radius: 7px; border: 2px solid var(--blue); background: #fff; color: #fff; font-weight: 700; font-size: 14px; line-height: 1; display: grid; place-items: center; cursor: pointer; padding: 0; flex: none; }
.stage.done .tick { background: var(--ok); border-color: var(--ok); }
.tick.ro { cursor: default; }
.stage-edit summary { cursor: pointer; color: var(--muted); list-style: none; }
.stage-edit[open] { flex-basis: 100%; }
.health-ok { color: var(--ok); } .health-err { color: var(--err); }
.count.warn { background: var(--err); }

/* ===== Nedu ===== */
.topbar-in .nav { flex: 1 1 300px; }
.hdr-tools { display: flex; align-items: center; gap: 6px; }
.icon-btn { position: relative; width: 40px; height: 40px; border-radius: 10px; border: 0; background: none; color: var(--text); cursor: pointer; display: grid; place-items: center; }
.icon-btn:hover, .icon-btn[aria-expanded=true] { background: var(--info-bg); color: var(--navy); }
.icon-btn svg { width: 22px; height: 22px; }
.icon-btn .dot-count { position: absolute; top: 3px; right: 2px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--err); color: #fff; font-size: 11px; font-weight: 700; display: grid; place-items: center; }
.icon-btn .dot-count.ops { background: var(--blue); }
.icon-btn.spin svg { animation: spin 1.4s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.drop { position: absolute; right: 0; top: 46px; width: min(380px, 92vw); max-height: 70vh; overflow: auto; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 14px 40px rgba(37,36,89,.16); z-index: 50; padding: 8px; }
.drop[hidden] { display: none; }
.drop h3 { margin: 6px 8px 8px; font-size: 13px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }
.drop-item { display: flex; flex-direction: column; gap: 4px; padding: 10px; border-radius: 8px; text-decoration: none; color: var(--ink); font-size: 14px; }
.drop-item:hover { background: var(--bg); color: var(--ink); }
.drop-item.unread { background: var(--info-bg); }
.drop-item small { color: var(--muted); font-size: 12px; }
.drop-empty { padding: 18px 10px; color: var(--muted); font-size: 14px; text-align: center; }
.wrap-rel { position: relative; }
.op-bar { height: 8px; border-radius: 999px; background: var(--line-soft); overflow: hidden; }
.op-bar > i { display: block; height: 8px; background: var(--blue); transition: width .3s; }
.op-bar.done > i { background: var(--ok); } .op-bar.failed > i { background: var(--err); }
.op-inline { display: flex; flex-direction: column; gap: 6px; min-width: 220px; margin-top: 14px; }
.btn[aria-busy=true] { opacity: .75; cursor: progress; }
.btn[aria-busy=true]::before { content: ""; width: 14px; height: 14px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .8s linear infinite; }
.user-menu summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 10px; }
.user-menu summary::-webkit-details-marker { display: none; }
.user-menu .drop { width: 240px; }

/* Plakietki plików i ikony materiałów */
.fbadge { display: inline-flex; align-items: center; justify-content: center; min-width: 46px; height: 24px; padding: 0 6px; border-radius: 5px; font-size: 11px; font-weight: 700; letter-spacing: .03em; flex: none; }
.mat-lead { width: 64px; flex: none; display: flex; justify-content: center; align-items: center; }
.mat-ico { width: 46px; text-align: center; color: var(--muted); flex: none; display: flex; justify-content: center; }
.mat-ico.has-badge { flex-direction: column; align-items: center; gap: 3px; width: 64px; }
.lbadge { display: inline-flex; align-items: center; justify-content: center; min-width: 46px; max-width: 64px; height: 16px; padding: 0 5px; border-radius: 4px; font-size: 9.5px; font-weight: 700; letter-spacing: .01em; white-space: nowrap; line-height: 1; }
.mat-ico svg { width: 22px; height: 22px; }

/* Tablica */
.board-filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.board-filters select { width: auto; min-width: 200px; }
.section-card { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 16px 20px 8px; }
.section-card.hidden-sec { background: repeating-linear-gradient(45deg, #fff, #fff 10px, #fafbfd 10px, #fafbfd 20px); }
.section-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 8px 12px; padding-bottom: 6px; }
.section-head h2 { min-width: 0; overflow-wrap: break-word; padding-top: 2px; }
.section-tools { display: flex; justify-content: flex-end; }
.section-tools details.fold { position: relative; }
/* panel „Sekcja ▾” zawsze przy prawej krawędzi przycisku i mieści się na ekranie */
.sec-panel { position: absolute; z-index: 20; margin-top: 6px; right: 0; left: auto; width: min(320px, calc(100vw - 56px)); }
/* telefon: tytuł na całą szerokość, przycisk w osobnym wierszu pod nim, po prawej */
/* telefon: przycisk „Sekcja” zawsze w osobnym wierszu pod tytułem, po prawej – długość tytułu nie zmienia jego miejsca */
@media (max-width: 760px) { .section-head { grid-template-columns: minmax(0, 1fr); } }
.section-head h2 { font-size: 18px; }
.mat { display: flex; align-items: center; gap: 14px; padding: 11px 0; border-top: 1px solid var(--line-soft); }
.mat:first-child { border-top: 0; }
.mat .grow { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.mat .grow a.title { color: var(--ink); text-decoration: none; font-weight: 500; font-size: 15px; overflow-wrap: anywhere; }
.mat .grow a.title:hover { color: var(--blue); }
.mat .meta { font-size: 12.5px; color: var(--muted); }
.mat.is-hidden .title { color: var(--muted); }
.mat-tools { display: flex; gap: 4px; align-items: center; }
.mini { height: 30px; padding: 0 10px; border-radius: 8px; border: 1px solid var(--line); background: #fff; font: inherit; font-size: 12.5px; color: var(--text); cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; }
.mini:hover { border-color: #b9bfcf; color: var(--ink); }
.add-row { display: flex; flex-wrap: wrap; gap: 8px; padding: 10px 0 8px; border-top: 1px dashed var(--line); margin-top: 4px; }
.drag-handle { cursor: grab; color: #b0b5c3; padding: 0 2px; font-size: 18px; user-select: none; }
.mat.dragging { opacity: .4; }
.embed { position: relative; width: 100%; aspect-ratio: 16 / 9; border-radius: 10px; overflow: hidden; background: #000; }
.embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.prose { font-size: 15px; line-height: 1.6; overflow-wrap: anywhere; }
.prose img { max-width: 100%; height: auto; }
.prose p { margin: 0 0 .7em; }

/* Kody i QR */
.join-code { font-size: 34px; font-weight: 700; letter-spacing: .16em; color: var(--navy); font-family: ui-monospace, Menlo, monospace; }
.qr { width: 220px; height: 220px; image-rendering: pixelated; }

/* Bank pytań */
.bank { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 18px; align-items: start; }
.bank.with-preview { grid-template-columns: 230px minmax(0, 1fr) 320px; }
@media (max-width: 1250px) { .bank.with-preview { grid-template-columns: 230px minmax(0, 1fr); } .bank.with-preview .qpreview { grid-column: 1 / -1; position: static; } }
@media (max-width: 900px) { .bank, .bank.with-preview { grid-template-columns: 1fr; } }
.excerpt { display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.tree { display: flex; flex-direction: column; gap: 1px; font-size: 14px; }
.tree a { display: flex; justify-content: space-between; gap: 8px; padding: 7px 10px; border-radius: 8px; color: var(--text); text-decoration: none; }
.tree a.on { background: var(--info-bg); color: var(--navy); font-weight: 600; }
.tree a .n { color: var(--muted); font-size: 12px; }
.tree .lock { font-size: 11px; color: var(--warn); }
table.t tr.sel td { background: var(--info-bg); }
table.t tr.click { cursor: pointer; }
.qpreview { position: sticky; top: 16px; }
.sticky-actions { position: sticky; bottom: 0; background: #fff; border-top: 1px solid var(--line); padding: 12px 0 2px; margin-top: 8px; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; z-index: 5; }
.type-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 10px; }
.ans-row { display: flex; gap: 10px; align-items: flex-start; padding: 10px; border: 1px solid var(--line); border-radius: 10px; }
.ans-row .grow { flex: 1; min-width: 0; }

/* Edytor HTML (contenteditable) */
.rte { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.rte-bar { display: flex; flex-wrap: wrap; gap: 2px; padding: 4px; border-bottom: 1px solid var(--line-soft); }
.rte-bar button { height: 30px; min-width: 30px; border: 0; background: none; border-radius: 6px; cursor: pointer; font: inherit; font-size: 13px; color: var(--text); }
.rte-bar button:hover { background: var(--bg); }
.rte-area { min-height: 90px; padding: 10px 12px; outline: none; font-size: 15px; line-height: 1.5; overflow-wrap: anywhere; }
.rte-area.small { min-height: 44px; }
.rte:focus-within { border-color: var(--blue); box-shadow: 0 0 0 2px var(--blue); }
.rte-area img { max-width: 100%; }

/* Test – rozwiązywanie */
.run { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 20px; align-items: start; }
@media (max-width: 900px) { .run { grid-template-columns: 1fr; } }
.run-side { position: sticky; top: 16px; display: flex; flex-direction: column; gap: 14px; }
.timer { font-size: 28px; font-weight: 700; color: var(--navy); font-variant-numeric: tabular-nums; }
.timer.low { color: var(--err); }
.qnav { display: grid; grid-template-columns: repeat(auto-fill, minmax(38px, 1fr)); gap: 6px; }
.qnav button { height: 38px; border-radius: 8px; border: 1px solid var(--line); background: #fff; font: inherit; font-weight: 600; cursor: pointer; color: var(--text); }
.qnav button.answered { background: var(--info-bg); border-color: var(--blue); color: var(--navy); }
.qnav button.current { outline: 3px solid rgba(54, 80, 193, .35); }
.qcard { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 22px; display: flex; flex-direction: column; gap: 16px; }
.qcard .qhead { display: flex; justify-content: space-between; gap: 10px; color: var(--muted); font-size: 13px; }
.opt { display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; font-size: 15px; }
.opt:has(input:checked) { border: 2px solid var(--blue); background: var(--info-bg); padding: 11px 13px; }
.opt input { width: 20px; height: 20px; accent-color: var(--blue); flex: none; margin-top: 1px; }
.match { display: grid; grid-template-columns: minmax(0, 1fr) minmax(180px, 1fr); gap: 10px 14px; align-items: center; }
.match .left { padding: 10px 12px; border-radius: 10px; background: var(--bg); }
.drop-zone { min-height: 44px; border: 2px dashed var(--line); border-radius: 10px; display: flex; align-items: center; padding: 4px; gap: 6px; }
.drop-zone.over { border-color: var(--blue); background: var(--info-bg); }
.drop-zone select { height: 36px; border: 0; background: transparent; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; padding: 10px; border-radius: 10px; background: var(--bg); }
.chip { padding: 8px 12px; border-radius: 8px; background: #fff; border: 1px solid var(--line); cursor: grab; font-size: 14px; user-select: none; }
.chip.used { opacity: .4; }
.blocked-overlay { padding: 22px; border-radius: 12px; background: var(--warn-bg); color: #7a3306; border: 1px solid #f5d7a8; }
.save-state { font-size: 12px; color: var(--muted); min-height: 16px; }
.review-q { border-left: 4px solid var(--line); padding-left: 14px; }
.review-q.ok { border-color: var(--ok); } .review-q.part { border-color: #d97706; } .review-q.bad { border-color: var(--err); } .review-q.manual { border-color: var(--blue); }
.live-row td { vertical-align: middle; }
.grade-cell { text-align: center; white-space: nowrap; }
table.t.gb th, table.t.gb td { white-space: nowrap; }
.kbd { font-family: ui-monospace, Menlo, monospace; font-size: 12px; background: var(--bg); border: 1px solid var(--line); border-radius: 5px; padding: 1px 5px; }
.section-head details.fold { position: relative; } .add-row details[open] { flex-basis: 100%; }

/* 0.9.1 */
.dropzone { border: 2px dashed var(--line); border-radius: 10px; padding: 22px 16px; text-align: center; color: var(--muted); background: #fafbfd; cursor: pointer; transition: border-color .15s, background .15s; }
.dropzone:hover, .dropzone:focus-within, .dropzone.over { border-color: var(--blue); background: #f1f6ff; color: var(--ink); }
.dropzone b { color: var(--blue); }
.dropzone input[type=file] { position: absolute; width: 1px; height: 1px; opacity: 0; }
.dz-list { display: flex; flex-direction: column; gap: 6px; }
.dz-file { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border: 1px solid var(--line-soft); border-radius: 8px; font-size: 13.5px; }
.dz-file .grow { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.dz-file.bad { border-color: #f1b5b0; background: #fff6f5; }
.dz-file .err { color: var(--danger, #c0392b); font-size: 12px; }
.section-card.file-over { outline: 2px dashed var(--blue); outline-offset: 4px; }
.qstate { display: inline-block; font-size: 12px; font-weight: 600; padding: 1px 8px; border-radius: 10px; }
.qstate.open { background: #e3f6ea; color: #17663a; }
.qstate.soon { background: #fff4d6; color: #7a5600; }
.qstate.closed { background: #eef0f3; color: #5b6170; }
.qstate.locked { background: #f1e9ff; color: #5b2ca8; }
.up-row { display: flex; gap: 10px; align-items: flex-start; padding: 10px 0; border-top: 1px solid var(--line-soft); }
.up-row:first-of-type { border-top: 0; }
.up-row .grow { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.up-row .grow a:not(.btn) { color: var(--ink); text-decoration: none; font-weight: 600; font-size: 14px; }
.up-row .btn { white-space: nowrap; }
.up-when { font-size: 12.5px; color: var(--ink); }
.attempt-tools { display: flex; gap: 4px; align-items: center; flex-wrap: wrap; }

/* 0.9.3 – typy pytań */
.plain { border: 0; padding: 0; margin: 0; }
.qbody .qtext { font-size: 16px; }
.chip { font-family: inherit; color: var(--ink); line-height: 1.3; }
.chip.armed { outline: 3px solid var(--blue); outline-offset: 1px; background: var(--info-bg); }
.chip img { max-height: 60px; max-width: 120px; display: block; }
.placing .gap-box, .placing .dd-box, .placing .drop-zone, .mk-pic.placing { cursor: copy; }
/* grupy wyborów (luki, obraz) – jasne kolory, każda inna */
.g1 { --gc: #dbe6ff; } .g2 { --gc: #ffe2c6; } .g3 { --gc: #d6f5dc; } .g4 { --gc: #fde0ef; }
.g5 { --gc: #fff3b0; } .g6 { --gc: #e4dcff; } .g7 { --gc: #cff4f6; } .g8 { --gc: #ececec; }
.chip[class*=" g"] { background: var(--gc); border-color: color-mix(in srgb, var(--gc) 70%, #555); }
.gap-text { line-height: 2.4; }
.gap-box { display: inline-flex; align-items: center; min-width: 110px; min-height: 34px; vertical-align: middle; border: 2px dashed color-mix(in srgb, var(--gc) 60%, #777); background: color-mix(in srgb, var(--gc) 45%, #fff); border-radius: 8px; padding: 0 4px; margin: 0 2px; }
.gap-box.filled { border-style: solid; background: var(--gc); }
.gap-box.over { outline: 3px solid var(--blue); }
.gap-box select, .dd-box select { border: 0; background: transparent; height: 30px; font: inherit; font-weight: 600; color: var(--ink); min-width: 100px; padding: 0 4px; }
.gap-text select, .dd-box select { width: auto; display: inline-block; }
.gap-sel { height: 34px; border: 1px solid var(--line); border-radius: 8px; background: var(--gc); font: inherit; padding: 0 6px; margin: 0 2px; min-width: 110px; }
.nope { animation: nope .4s; } @keyframes nope { 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }
.gap-blank { display: inline-block; min-width: 60px; border-bottom: 1px solid var(--muted); color: transparent; }
/* porządkowanie */
.ord-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.ord-list.h { flex-direction: row; flex-wrap: wrap; }
.ord-item { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: #fff; border: 1px solid var(--line); border-radius: 10px; cursor: grab; touch-action: none; }
.ord-list.h .ord-item { flex: 0 1 auto; }
.ord-item.dragging { opacity: .5; border-style: dashed; }
.ord-no { width: 26px; height: 26px; border-radius: 50%; background: var(--info-bg); color: var(--navy); font-weight: 700; font-size: 13px; display: grid; place-items: center; flex: none; }
.ord-btns { display: flex; gap: 4px; flex: none; }
/* zaznacz słowa */
.ws-text { font-size: 17px; line-height: 2.1; padding: 14px 16px; border: 1px solid var(--line-soft); border-radius: 10px; background: #fff; }
.ws-w { font: inherit; color: inherit; background: none; border: 0; padding: 1px 2px; margin: 0 -2px; border-radius: 5px; cursor: pointer; }
.ws-w:hover { background: var(--info-bg); }
.ws-w.on { background: #ffe58f; box-shadow: inset 0 -2px 0 #d4a300; }
.ws-text.review .ws-w { cursor: default; }
.ws-text.review .ws-w.ok { background: #c9f0d3; box-shadow: inset 0 -2px 0 #2f9e57; }
.ws-text.review .ws-w.bad { background: #ffd6d2; box-shadow: inset 0 -2px 0 #c0392b; text-decoration: line-through; }
.ws-text.review .ws-w.missed { box-shadow: inset 0 -2px 0 #2f9e57; }
/* obraz */
.dd-pic { position: relative; display: block; width: 100%; user-select: none; border: 1px solid var(--line-soft); border-radius: 8px; overflow: hidden; }
.dd-pic > img { display: block; }
.dd-box { position: absolute; display: inline-flex; flex-direction: column; align-items: stretch; min-width: 96px; min-height: 34px; border: 2px dashed color-mix(in srgb, var(--gc) 50%, #555); background: color-mix(in srgb, var(--gc) 75%, transparent); border-radius: 7px; font-size: 14px; }
.dd-box.filled { border-style: solid; background: var(--gc); }
.dd-box.over { outline: 3px solid var(--blue); }
.dd-box .dd-in:empty { display: none; }
.dd-box .dd-in { padding: 3px 6px 0; font-weight: 600; }
.dd-box .dd-in img { max-height: 54px; display: block; }
.dd-box.filled select { font-size: 11px; height: 20px; font-weight: 400; color: var(--muted); }
.dd-box.review { padding: 4px 8px; font-weight: 600; justify-content: center; }
.dd-box.review img { max-height: 54px; }
.dd-box.ok { box-shadow: 0 0 0 3px #2f9e57; } .dd-box.bad { box-shadow: 0 0 0 3px #c0392b; }
.mk-pic { cursor: default; touch-action: none; }
.mk-pin { position: absolute; transform: translate(-50%, -100%); padding: 3px 8px 3px 8px; border-radius: 8px 8px 8px 0; background: var(--blue); color: #fff; font: 600 12.5px/1.2 inherit; border: 2px solid #fff; box-shadow: 0 2px 6px rgba(0,0,0,.25); cursor: grab; white-space: nowrap; }
.mk-pin::after { content: ''; position: absolute; left: -2px; bottom: -8px; border: 5px solid transparent; border-top-color: var(--blue); border-left-color: var(--blue); }
.mk-pin:focus-visible { outline: 3px solid #ffbf00; }
.mk-pin.review.ok { background: #1d7a43; } .mk-pin.review.ok::after { border-top-color: #1d7a43; border-left-color: #1d7a43; }
.mk-pin.review.bad { background: #c0392b; } .mk-pin.review.bad::after { border-top-color: #c0392b; border-left-color: #c0392b; }
.mk-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--blue); margin-right: 6px; }
.mk-zones { position: absolute; inset: 0; width: 100%; height: 100%; }
.mk-zones > * { fill: rgba(47, 158, 87, .22); stroke: #2f9e57; stroke-width: 2; vector-effect: non-scaling-stroke; }
/* rysunek */
.draw-tools { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.draw-col { width: 28px; height: 28px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 0 0 1px var(--line); cursor: pointer; }
.draw-col.on { box-shadow: 0 0 0 3px var(--blue); }
.draw-tools .mini.on { background: var(--info-bg); border-color: var(--blue); }
.draw-wrap { position: relative; width: 100%; border: 1px solid var(--line); border-radius: 8px; background: #fff; overflow: hidden; }
.draw-wrap img, .draw-wrap canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.draw-wrap canvas { touch-action: none; cursor: crosshair; }
/* nagranie */
.card-soft { border: 1px solid var(--line-soft); border-radius: 10px; padding: 14px; background: #fafbfd; }
.rec-time { font-weight: 700; color: #c0392b; font-variant-numeric: tabular-nums; }
.rec audio, .ans-html audio { width: 100%; max-width: 420px; }
/* odpowiedzi z plikami */
.ans-files { list-style: none; padding: 0; margin: 4px 0; display: flex; flex-direction: column; gap: 6px; }
.ans-img { max-width: 100%; max-height: 420px; border: 1px solid var(--line); border-radius: 8px; display: block; }
.ans-html { margin-top: 8px; max-width: 760px; }
/* edytor typów */
.type-group { margin: 22px 0 8px; font-size: 13px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.ed-pic { position: relative; display: inline-block; max-width: 100%; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; cursor: crosshair; user-select: none; touch-action: none; }
.ed-pic > img { display: block; max-width: 100%; }
.ed-drop { position: absolute; min-width: 90px; min-height: 30px; border: 2px dashed var(--navy); background: rgba(255,255,255,.85); border-radius: 6px; font-size: 12.5px; font-weight: 700; padding: 4px 8px; cursor: move; }
.ed-drop.sel, .ed-zone.sel { outline: 3px solid #ffbf00; }
.ed-pic svg { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.ed-pic svg .z { fill: rgba(54, 80, 193, .2); stroke: var(--blue); stroke-width: 2; vector-effect: non-scaling-stroke; }
.ed-pic svg .z.sel { fill: rgba(255, 191, 0, .3); stroke: #c48d00; }
.ed-pic svg text { font: 700 14px sans-serif; fill: var(--navy); paint-order: stroke; stroke: #fff; stroke-width: 3px; }
.var-row { display: grid; grid-template-columns: 80px repeat(3, minmax(90px, 1fr)); gap: 8px; align-items: end; }
.formula-ok { color: var(--ok); } .formula-err { color: #c0392b; }

.num-rows { counter-reset: r; }
.num-rows > .ans-row > .row-no::before { counter-increment: r; content: counter(r) "."; font-weight: 700; color: var(--navy); font-size: 13px; }
.num-rows > .ans-row > .row-no { width: 24px; flex: none; padding-top: 12px; text-align: right; }
.dg-img { display: inline-flex; gap: 6px; align-items: center; }
.ans-row.sel { background: #fff8e1; border-radius: 8px; }
.ans-html .mk-pin, .kv .mk-pin { color: #fff; font-size: 12.5px; }
.ans-html .dd-box, .kv .dd-box { color: var(--ink); font-size: 14px; }
.ans-html .ws-w, .kv .ws-w { color: var(--ink); font-size: 17px; }
.ed-pic { align-self: flex-start; width: fit-content; }
.ed-pic > img { width: auto; max-width: 100%; height: auto; }
[data-mk-rows] .ans-row select, [data-dd-rows] .ans-row select { width: auto; min-width: 180px; flex: 0 1 260px; }
[data-mk-rows] .ans-row input { flex: 0 1 220px; }
/* 0.9.4 – import kursu z Moodle */
.imp-sec { border-top: 1px solid var(--line-soft); padding-top: 10px; }
.imp-sec legend { padding: 0; margin-bottom: 4px; }
.imp-row { display: flex; gap: 10px; align-items: center; padding: 5px 0 5px 26px; }
.imp-row .badge { font-size: 11px; }
.imp-row.blocked > label { opacity: .65; }
.check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(220px, 100%), 1fr)); gap: 4px 14px; }

/* 0.9.5: delikatne fale Netiserv w tle po zalogowaniu (styl ze strony logowania + fala z instrukcji) */
body[data-ops-url] { position: relative; isolation: isolate; }
body[data-ops-url]::before { content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: url('../img/tlo-fale.svg?v=2') center bottom / cover no-repeat; }
@media (max-width: 700px) { body[data-ops-url]::before { opacity: .7; background-size: auto 100%; background-position: 20% bottom; } }
@media print { body[data-ops-url]::before { display: none; } }

/* 0.9.8: dziennik aktywności */
.act-filters { flex-wrap: wrap; gap: 8px; }
.act-filters .act-export { margin-left: auto; }
.act-date { display: inline-flex; align-items: center; gap: 6px; }
.act-person a { color: inherit; text-decoration: none; margin-left: 6px; font-weight: 700; }
.act-table td { vertical-align: top; }
.act-desc { padding-left: 9px; border-left: 3px solid var(--line, #dfe3ee); }
.act-auth { border-color: #8FA3E6; } .act-course { border-color: #2E51C8; } .act-quiz { border-color: #c2410c; }
.act-assignment { border-color: #15803d; } .act-bank { border-color: #7c3aed; } .act-admin { border-color: #202058; }
.nowrap { white-space: nowrap; }
.row-inline { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }

/* 0.9.11: odpowiedzi w podglądzie pytania – znacznik w jednej linii z treścią (także gdy treść to akapit z edytora) */
.ans-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.ans-list li { display: flex; align-items: baseline; gap: 6px; }
.ans-list .ans-mark { flex: 0 0 14px; font-weight: 700; color: var(--ok); }
.ans-list li:not(.ok) .ans-mark::before { content: "•"; color: var(--muted); font-weight: 400; }
.ans-list .ans-text { min-width: 0; }
.ans-list .ans-text > :first-child { margin-top: 0; } .ans-list .ans-text > :last-child { margin-bottom: 0; }
.ans-list .ans-text p { margin: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* 0.9.11: widok na telefonie */
.mat-menu { display: none; position: relative; }
.mat-menu summary { list-style: none; cursor: pointer; font-size: 18px; line-height: 1; padding: 6px 10px; }
.mat-menu summary::-webkit-details-marker { display: none; }
.mat-menu-list { position: absolute; right: 0; top: calc(100% + 4px); z-index: 30; background: #fff; border: 1px solid var(--line); border-radius: 12px;
  box-shadow: 0 14px 40px rgba(37,36,89,.16); padding: 6px; display: flex; flex-direction: column; min-width: 170px; }
.mat-menu-list .mini, .mat-menu-list form { display: block; width: 100%; }
.mat-menu-list .mini { text-align: left; padding: 9px 12px; border: 0; background: none; font-size: 14px; border-radius: 8px; }
.mat-menu-list .mini:hover { background: var(--info-bg); }
@media (max-width: 760px) {
  /* nagłówek: dolny wiersz wyśrodkowany, panele na całą szerokość ekranu */
  .topbar-in { gap: 10px; padding: 10px 14px; }
  .hdr-tools { flex-basis: 100%; justify-content: center; position: relative; }
  .hdr-tools .wrap-rel { position: static; }
  .hdr-tools .drop { left: 0; right: 0; width: auto; max-width: none; top: calc(100% + 6px); }
  /* tablica kursu */
  .mat { gap: 10px; }
  .mat-tools, .drag-handle { display: none; }
  .mat-menu { display: block; }
  .add-row { display: grid; grid-template-columns: 1fr 1fr; }
  .add-row > details > summary, .add-row > a, .add-row > button { display: flex; align-items: center; justify-content: center; min-height: 40px; margin: 0; }
  .add-row details[open] { grid-column: 1 / -1; }
}
.m-only { display: none; }
@media (max-width: 760px) {
  .bank-t .c-type, .bank-t .c-cat, .bank-t .c-ver { display: none; }
  .bank-t .m-only { display: block; margin-top: 2px; }
  .bank-t .excerpt { display: none; }
}

/* 0.9.11: okno „Co nowego” */
.whatsnew { border: 0; border-radius: 16px; padding: 0; width: min(520px, 92vw); box-shadow: 0 24px 60px rgba(37,36,89,.25); }
.whatsnew::backdrop { background: rgba(32,32,88,.35); }
.whatsnew form { padding: 24px 26px 20px; display: grid; gap: 10px; }
.whatsnew .wn-head { display: flex; align-items: center; gap: 14px; }
.whatsnew h2 { margin: 0; font-size: 19px; color: var(--navy); }
.whatsnew ul { margin: 4px 0 0; padding-left: 20px; display: grid; gap: 6px; line-height: 1.45; }
.whatsnew .actions { justify-content: flex-end; }

/* 0.9.11: kopie zapasowe */
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); gap: 18px; align-items: start; }
.gr-add { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px 14px; margin: 0; }
.gr-add legend { padding: 0 6px; }
.gr-add .row-inline > select, .gr-add .row-inline > button { width: auto; flex: 0 0 auto; }
.gr-add #gr-search { flex: 1 1 220px; width: auto; }
.gr-add #gr-list { width: 100%; height: 190px; padding: 4px; }
.gr-add #gr-list option { padding: 5px 8px; border-radius: 6px; }

/* ---------- Dostępność (WCAG 2.2 AA) ---------- */
/* 2.4.7 / 1.4.11: wyraźny fokus klawiatury na każdym elemencie (podwójna obwódka – widoczna na jasnym i ciemnym tle) */
:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; box-shadow: 0 0 0 5px #fff; border-radius: 4px; }
input:focus-visible, select:focus-visible, textarea:focus-visible, .rte-area:focus-visible { outline: 2px solid var(--blue); outline-offset: 1px; box-shadow: none; }
canvas:focus-visible { outline: 3px solid var(--blue); outline-offset: -3px; }
.mk-pin:focus-visible, .ed-drop:focus-visible { outline: 3px solid #ffbf00; }
/* 2.4.11: fokus nie chowa się pod przyklejonymi paskami przycisków */
html { scroll-padding-top: 16px; scroll-padding-bottom: 24px; }
html:has(.sticky-actions) { scroll-padding-bottom: 140px; }
/* 2.5.8: cele dotyku co najmniej 24 × 24 px */
.mini, .btn-sm, .chip, summary, .pager a, .pager span { min-height: 28px; }
.mini { min-width: 28px; justify-content: center; }
a.small, a.xs, .back, td a, summary.small, .who a, .foot a { display: inline-block; min-height: 24px; line-height: 24px; }
p a.small, li a.small, .prose a { display: inline; min-height: 0; line-height: inherit; }
input[type=file] { min-height: 40px; padding: 8px 0; }
input[type=checkbox], input[type=radio] { min-width: 18px; min-height: 18px; }
.mat-menu summary { min-width: 36px; min-height: 36px; display: inline-flex; align-items: center; justify-content: center; }
/* przeciąganie materiałów: uchwyt jest przyciskiem, przesuwanie także strzałkami i przyciskami */
.drag-handle { border: 0; background: none; font: inherit; color: var(--muted); cursor: grab; min-width: 28px; min-height: 28px; border-radius: 6px; }
.drag-handle:hover { background: var(--info-bg); color: var(--ink); }
.mat.moving { outline: 2px dashed var(--blue); outline-offset: 2px; background: var(--info-bg); }
.move-bar { display: inline-flex; gap: 6px; align-items: center; }
/* 2.3.3 / ustawienia systemu: bez animacji dla osób, które je wyłączyły */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
/* 1.4.10: treść mieści się na szerokości 320 px */
img, video, svg, canvas { max-width: 100%; }
/* długie słowa łamiemy tylko, gdy naprawdę się nie mieszczą (break-word nie zwęża kolumn tabel ani przycisków) */
.ans-row, td, th { overflow-wrap: break-word; }
.btn, .mini, .pill, .badge, .chip, th { white-space: nowrap; }
/* komunikat o wygasającej sesji */
.session-warn { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); z-index: 1200; background: #fff; border: 2px solid var(--blue); border-radius: 12px; box-shadow: 0 8px 30px rgba(0,0,0,.2); padding: 14px 18px; display: flex; gap: 14px; align-items: center; flex-wrap: wrap; max-width: calc(100% - 24px); }
fieldset { min-width: 0; }
.card, .grow, .field, form { min-width: 0; }
.field input, .field select, .field textarea { max-width: 100%; }
@media (max-width: 480px) { .var-row { grid-template-columns: 1fr 1fr; } .match { grid-template-columns: 1fr; } }
.foot { max-width: calc(100% - 24px); flex-wrap: wrap; } .foot-link { color: var(--muted); margin-right: 6px; }
input[type=datetime-local], input[type=date], input[type=time] { min-height: 40px; } th a, .mat a.title { display: inline-block; min-height: 24px; line-height: 24px; }
@media (max-width: 560px) { .ans-row { flex-wrap: wrap; } .ans-row > .grow { flex: 1 1 200px; } }
/* tabela szersza niż ekran: przewija się w poziomie (dozwolone dla tabel danych w WCAG 1.4.10), cień po prawej podpowiada, że jest więcej */
.table-box { background: linear-gradient(to right, #fff 30%, rgba(255,255,255,0)) left center / 40px 100% no-repeat local,
  linear-gradient(to left, #fff 30%, rgba(255,255,255,0)) right center / 40px 100% no-repeat local,
  radial-gradient(farthest-side at 0 50%, rgba(0,0,0,.14), transparent) left center / 12px 100% no-repeat scroll,
  radial-gradient(farthest-side at 100% 50%, rgba(0,0,0,.14), transparent) right center / 12px 100% no-repeat scroll; }
.add-row > details, .add-row > details > .card { min-width: 0; max-width: 100%; }
@media (max-width: 400px) { .section-card { padding: 14px 12px 6px; } }
