/* Nowy wygląd (2026-11-22, design canvas "DTF Math — nowy wygląd"): the component layer loaded last by every layout.
   Colours live in the tokens (app.css light, theme-dark.css dark, training.css trainer); this file only reshapes the
   shared pieces the way the design draws them: solid header with a subject pill, pill links, 3D buttons (a 0 4px 0
   darker edge), 20 px cards with a solid border, an amber streak pill, Space Grotesk headings over Inter text.
   Physics swaps the violet accent for teal (body.subj-fizyka). Nothing here hides a link or a feature. */

/* ---------- physics accent: teal (design "Fizyka — ciemny motyw") ---------- */
html[data-theme=dark] body.subj-fizyka,body.tr-app.subj-fizyka:not(.tr-light){
  --accent:#3dd6c3;--accent-ink:#8fede0;--accent-soft:#0f3a36;--accent-deep:#8fede0;--accent-edge:#1f9486;--on-accent:#0e1016
}
html:not([data-theme=dark]) body.subj-fizyka:not(.tr-app),body.tr-app.tr-light.subj-fizyka{
  --accent:#0f766e;--accent-ink:#115e59;--accent-soft:#ccfbf1;--accent-deep:#134e4a;--accent-edge:#0b4f49;--on-accent:#ffffff
}

/* ---------- type ---------- */
body{font-family:var(--sans);font-size:16px;line-height:1.6}
@media (min-width:1600px){body{font-size:16.5px}}
h1,h2,h3{font-family:var(--display);font-weight:700;letter-spacing:-.015em}
.brand-mark,.streak-big,.hero-title,.orb-glyph,.orb-name,.page-title,.big-glyph,.task-title,.success-title,.day-num,
.cat-glyph,.acard-title,.post-title,.post-body h2,.post-practice h2,.post-next h2,.section-title,.guide-articles h2,
.matura-card-title,.lp-title,.lp-problem-title,.lp-h2,.lp-h3,.lp-offer-title,.lesson-title,.sc-pilot-n,.soft-title,
.acct-num,.acct-streak-num,.acct-mm-stats b,.acct-rating-num b,.acct-section h2,.sim .sim-title,.mm-opt span b,.mm-expr,
.mm-score-num,.mm-h3,.mm-about h2,.mm-tech-item h3,.search-h,.path-card-title,.path-module h3,.admin .adm-content>h1,
.adm-head h1,.admin .adm-content h2,.adm-stat-num,.subject-tab-glyph,.topic-box h2,.topic-list-title,.topic-group h2,
.hub-sheet-title,.nlp-title,.nlp-mast .nlp-title,.nlp-num,.day-card-title,.hk-tiers,.sk-glyph,.sk-rel-orb,.tm-h2,
.tr-card-title,.tr-num,.tr-opt span b,.tr-stats dd,.tr-reason{font-weight:700;font-style:normal;letter-spacing:-.02em}
.hero-title,.page-title,.lp-title,.post-title,.lesson-title{line-height:1.08}
.tagline{font:500 clamp(1.05rem,1.4vw,1.2rem)/1.5 var(--sans);font-style:normal;color:var(--ink-2)}
.wm{font-style:normal;color:var(--accent-ink)}
.eyebrow,.hint-caps{color:var(--accent-ink);letter-spacing:.06em}
::selection{background:var(--accent-soft);color:var(--ink)}

/* ---------- header (design: solid bar, logo tile, subject pill, pill links, amber streak) ---------- */
.site-header{background:var(--header-bg);-webkit-backdrop-filter:none;backdrop-filter:none;border-bottom:1px solid var(--border)}
.brand{gap:10px;font-family:var(--display);font-weight:700;font-size:1.2rem;letter-spacing:-.01em}
.brand-mark{width:36px;height:36px;border-radius:10px;background:var(--accent);color:var(--on-accent);font:700 20px/1 var(--display);padding:0;box-shadow:none}
.brand-mark.sm{width:24px;height:24px;border-radius:7px;font-size:14px}
.brand-name em{font:inherit;font-style:normal;color:inherit}
.nav a{border-radius:10px;font-size:.94rem;font-weight:600;color:var(--ink-2);padding:0 14px}
.nav a:hover{background:var(--surface-soft);color:var(--ink)}
.nav a[aria-current=page]{background:var(--accent-soft);color:var(--accent-ink);box-shadow:none;border-radius:10px}
.nav-secondary>summary{font-size:.94rem;font-weight:600;color:var(--ink-2);border-radius:10px}
.nav-secondary>summary:hover{background:var(--surface-soft);color:var(--ink)}
.nav-secondary-panel{border-color:var(--border);border-radius:20px;background:var(--surface)}
.nav-group-h{color:var(--accent-ink)}
/* subject switch: a segmented pill (in the header from 1280 px, at the top of the menu / "Więcej" panel below) */
.nav-subjects{display:flex;gap:2px;padding:2px;border-radius:999px;background:var(--bg);border:1px solid var(--border);width:max-content}
.subject-tab{min-height:40px;padding:0 14px;border-radius:999px;border:0;color:var(--ink-2);font-weight:700;font-size:.875rem;gap:6px}
.subject-tab:hover{background:var(--surface-soft);border-color:transparent;color:var(--ink)}
.subject-tab[aria-current]{background:var(--accent);color:var(--on-accent);border-color:transparent;box-shadow:none}
.subject-tab-glyph{font:700 1em/1 var(--display)}
.header-inner>.nav-subjects-head{display:none;flex:none}
@media (min-width:1280px){
  .header-inner>.nav-subjects-head{display:flex;margin-left:6px}
  .nav-secondary-panel .nav-subjects-panel{display:none}
  .nav{margin-left:auto}
}
/* with the subject pill in the row, the search field becomes the icon (full-screen panel) until there is room for both */
@media (min-width:1200px) and (max-width:1439px){
  .site-search{display:none}
  .search-toggle{display:inline-flex}
  .site-search.is-open{display:flex;position:fixed;inset:0;z-index:40;flex-direction:column;align-items:stretch;gap:10px;margin:0;padding:12px max(16px,calc((100% - 760px) / 2));background:var(--bg)}
  .site-search.is-open input,.site-search.is-open input:focus{width:100%;font-size:1rem;padding:12px 16px}
  .site-search.is-open .search-close{display:block;align-self:flex-end;background:none;border:0;font:600 .95rem var(--sans);color:var(--accent-ink);padding:6px}
  .site-search.is-open .search-list{position:static;width:100%;max-height:none;box-shadow:none;flex:1}
}
.site-search input{background:var(--bg);border:1px solid var(--border)}
.site-search input:focus{background:var(--surface);border-color:var(--accent)}
.streak-btn{background:var(--sun-bg);color:var(--sun-text);border:0;gap:6px;padding:0 14px}
.streak-btn .flame,.streak-btn.is-zero .flame{color:inherit;opacity:1}
.streak-btn:hover{box-shadow:none;filter:brightness(1.08)}
.streak-pop,.search-list{border-color:var(--border);border-radius:20px}
.streak-days li{border-radius:6px}
.streak-days li.on{background:var(--ok);color:var(--bg)}
.account-link{border-color:var(--border-strong);background:transparent}
.account-link svg{stroke:currentColor}
.account-link:hover{background:var(--surface-soft);box-shadow:none}
.site-theme-btn:hover,.search-toggle:hover,.menu-btn:hover{background:var(--surface-soft)}
@media (max-width:1023px){
  .site-header .nav{background:var(--surface);border-bottom-color:var(--border)}
  .site-header .nav a[aria-current=page]{background:var(--accent-soft);box-shadow:none;border-radius:10px}
  .nav>.nav-subjects-menu{width:auto;border-radius:999px;padding:2px;margin:4px 4px 12px;border:1px solid var(--border)}
  .nav>.nav-subjects-menu .subject-tab{flex:1;justify-content:center}
}

/* ---------- buttons: one shape, a darker bottom edge that a press sinks onto ---------- */
.btn-primary,.btn-soft,.k3,.lp-cta,.btn-invert{border-radius:14px;font-weight:700}
.btn-primary,.k3-primary{background:var(--accent);color:var(--on-accent);box-shadow:0 4px 0 var(--accent-edge)}
.btn-primary:hover,.k3-primary:hover{background:var(--accent-ink);color:var(--on-accent);transform:none;box-shadow:0 4px 0 var(--accent-edge)}
.btn-primary:active,.k3-primary:active,.btn-soft:active,.k3-soft:active{transform:translateY(3px);box-shadow:0 1px 0 var(--accent-edge)}
.btn-soft,.k3-soft{background:transparent;color:var(--ink);border:2px solid var(--border-strong);box-shadow:none}
.btn-soft:hover,.k3-soft:hover{background:var(--surface-soft);transform:none;box-shadow:none}
.btn-primary:focus-visible,.btn-soft:focus-visible{border-radius:14px}
.go{background:var(--accent);color:var(--on-accent);box-shadow:0 4px 0 var(--accent-edge)}
.go:hover{background:var(--accent-ink)}
@media (prefers-reduced-motion:reduce){.btn-primary:active,.k3-primary:active,.btn-soft:active,.k3-soft:active{transform:none}}

/* ---------- surfaces ---------- */
.chip{border-color:var(--border);background:var(--surface)}
.chip-link:hover{border-color:var(--accent)}
.consent{border-top:1px solid var(--border)}
.consent-btn{border-radius:14px}
.site-footer{background:var(--surface);border-top:1px solid var(--border)}
.footer-col h2{color:var(--accent-ink);font-family:var(--sans);letter-spacing:.06em}
.footer-col a:hover{color:var(--accent-ink)}
:focus-visible{outline-color:var(--accent)}

/* ---------- home: hero "Dzisiejszy zestaw" card (app/views/home.php, app.js renderSolvedMarks) ---------- */
.hv-set{position:relative;justify-self:stretch;display:flex;flex-direction:column;gap:14px;padding:24px;background:var(--surface);border:1px solid var(--border);border-radius:20px;animation:hv-rise .55s .08s cubic-bezier(.2,.9,.3,1) both}
.hv-set-sigma{display:flex;align-items:flex-end;gap:12px;margin:-4px 0 2px}
.hv-set-mascot{flex:none;width:64px;height:auto}
.hv-set-bubble{position:relative;margin:0 0 8px;padding:10px 14px;border-radius:14px 14px 14px 4px;background:var(--surface-soft);border:1px solid var(--border);font:700 .95rem/1.3 var(--display);color:var(--ink)}
.hv-set-bubble small{display:block;margin-top:2px;font:500 .85rem/1.35 var(--sans);color:var(--ink-2)}
.hv-set-head{display:flex;align-items:baseline;justify-content:space-between;gap:12px;flex-wrap:wrap}
.hv-set-head h2{margin:0;font-size:1.4rem}
.hv-set-count{font-size:.875rem;font-weight:600;color:var(--ink-2)}
.hv-set-bar{height:10px;border-radius:999px;background:var(--border);overflow:hidden}
.hv-set-bar span{display:block;width:0;height:100%;border-radius:999px;background:var(--ok);transition:width .4s var(--ease)}
.hv-set-list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:10px}
.hv-set-row{display:flex;align-items:center;gap:14px;min-height:60px;padding:8px 16px;border-radius:14px;background:var(--surface-soft);border:2px solid transparent;color:var(--ink);text-decoration:none}
a.hv-set-row:hover{border-color:var(--border-strong)}
.hv-set-n{flex:none;display:grid;place-items:center;width:32px;height:32px;border-radius:50%;border:2px solid var(--border-strong);color:var(--ink-2);font:700 .95rem/1 var(--sans)}
.hv-set-tick{display:none;width:16px;height:16px;stroke-width:3}
.hv-set-name{flex:1;min-width:0;display:flex;flex-direction:column;gap:1px}
.hv-set-name b{font-weight:600;font-size:1rem}
.hv-set-name small{font-size:.8rem;color:var(--ink-3);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.hv-set-name .pno{font:inherit;color:inherit;background:none;padding:0}
.hv-set-state{flex:none;font-size:.875rem;font-weight:600;color:var(--ink-3)}
.hv-set-row.is-solved{background:var(--ok-soft)}
.hv-set-row.is-solved .hv-set-n{background:var(--ok);border-color:var(--ok);color:var(--bg)}
.hv-set-row.is-solved .hv-set-num{display:none}
.hv-set-row.is-solved .hv-set-tick{display:block}
.hv-set-row.is-solved .hv-set-state{color:var(--ok-ink)}
.hv-set-row.is-now{background:var(--accent-soft);border-color:var(--accent)}
.hv-set-row.is-now .hv-set-n{background:var(--accent);border-color:var(--accent);color:var(--on-accent)}
.hv-set-row.is-now .hv-set-state{color:var(--accent-ink);font-weight:700}
.hv-set-row.is-empty{opacity:.7}
.hv-set-note{display:flex;align-items:center;gap:8px;margin:0;font-size:.875rem;color:var(--ink-3)}
.hv-set-note .ico{width:16px;height:16px}
@media (max-width:860px){.hv-set{order:2}}
@media (max-width:420px){.hv-set{padding:18px}.hv-set-row{padding:8px 12px;gap:10px}}
@media (prefers-reduced-motion:reduce){.hv-set{animation:hv-fade .35s ease-out both}.hv-set-bar span{transition:none}}

/* hero copy and numbers in the design's voice */
.hv-title{font-family:var(--display);font-weight:700;letter-spacing:-.025em}
.hv-title em{font-style:normal;color:var(--accent-ink)}
.hv-topic{color:var(--accent-ink);font-family:var(--sans)}
.hv-proof{border-block:1px solid var(--border)}
.hv-proof b{font-family:var(--display);font-weight:700}

/* ---------- home: grade tiles with a number badge (design "Wybierz swoją klasę") ---------- */
.lj-grades{grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:14px}
.lj-start .lj-grade,.home-v2 .lj-start .lj-grade{display:grid;grid-template-columns:52px minmax(0,1fr);grid-template-rows:auto auto;column-gap:14px;row-gap:2px;align-content:center;min-height:88px;padding:16px;
  border:1px solid var(--border);border-top-width:1px;border-bottom-width:1px;border-radius:16px;background:var(--surface);color:var(--ink);text-decoration:none}
.lj-start .lj-grade:hover,.home-v2 .lj-start .lj-grade:hover{border-color:var(--accent);box-shadow:none;transform:translateY(-2px)}
.lj-start .lj-grade .lj-badge{grid-row:1/3;display:grid;place-items:center;width:52px;height:52px;border-radius:14px;background:var(--accent-soft);color:var(--accent-ink);font:700 1.3rem/1 var(--display);-webkit-line-clamp:unset;overflow:visible}
.lj-start .lj-grade b{align-self:end;font:700 1.05rem/1.25 var(--sans)}
.lj-start .lj-grade span:not(.lj-badge){align-self:start;font-size:.85rem;color:var(--ink-2)}
.lj-start .lj-grade.is-last{border-color:var(--accent);background:var(--accent-soft)}
@media (max-width:700px){
  .lj-grades{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
  .lj-start .lj-grade,.home-v2 .lj-start .lj-grade{grid-template-columns:40px minmax(0,1fr);min-height:64px;padding:10px 12px;column-gap:10px}
  .lj-start .lj-grade .lj-badge{display:grid;grid-row:1/2;width:40px;height:40px;border-radius:12px;font-size:1.05rem}
  .lj-start .lj-grade b{align-self:center}
}

/* ---------- details ---------- */
h1 em,h2 em,.lp-title-accent{font-style:normal;color:var(--accent-ink)}
/* daily orbs: flat discs on a darker edge (the design's pressable look) instead of a coloured glow */
.orb{border:0;box-shadow:0 6px 0 color-mix(in srgb,var(--c) 55%,#000)}
.orb-link:hover .orb{transform:translateY(-2px)}
.orb-glyph{transform:none}
/* the subject pill inside the menu / "Więcej" panel: same segmented look as in the header row (ux.css draws bordered chips) */
.site-header .nav .subject-tab{border:0;min-height:40px}
.site-header .nav .subject-tab[aria-current]{background:var(--accent);color:var(--on-accent)}
.site-header .nav .subject-tab:not([aria-current]):hover{background:var(--surface-soft)}
.nav-secondary-panel .nav-subjects-panel{border:1px solid var(--border);padding:2px;margin-bottom:6px}

/* ---------- language switch (views/_lang_switch.php, lang.js; added on main 2026-11-24) ---------- */
.lang-switch>summary{border-radius:999px}
.lang-menu{border-color:var(--border);border-radius:var(--r-md);box-shadow:0 16px 40px rgba(0,0,0,.28)}
.lang-menu a[aria-current] .lang-short{background:var(--accent);color:var(--on-accent)}
.lang-offer-go{background:var(--accent);color:var(--on-accent);box-shadow:0 3px 0 var(--accent-edge)}
.lang-offer-go:hover{background:var(--accent);color:var(--on-accent);filter:brightness(1.06)}
/* English header "Practice problems" menu: the glyph chips follow the tokens instead of a fixed light blue */
.en-menu>summary{border-radius:999px}
.en-menu-panel{border-color:var(--border);border-radius:var(--r-lg)}
.en-menu-glyph{background:var(--accent-soft);color:var(--accent-ink);font-family:var(--display)}
.en-nav .en-menu-panel a.en-menu-all{color:var(--accent-ink)}
/* the mascot's backdrop on the English home: a violet wash instead of the amber one (amber turns muddy on the dark page) */
html[data-theme=dark] body:not(.tr-light) .hv-blob{background:var(--accent-soft)}
/* English header on a phone: logo tile + "Problems" + "Lessons" + globe fit 360 px once the wordmark steps aside */
@media (max-width:479px){.en .en-header .brand-name{display:none}.en .en-header{gap:8px}}

/* ---------- dark theme: full-width colour bands (home "Trening", Dla szkół) become a deep accent wash ----------
   The light accent of the dark theme cannot carry white text; a deep wash keeps the band and the white text readable. */
html[data-theme=dark] body:not(.tr-light) .lp-band,html[data-theme=dark] body:not(.tr-light) .sc-final,html[data-theme=dark] body:not(.tr-light) .hk-join{background:var(--accent-soft);color:var(--ink);box-shadow:inset 0 1px 0 var(--border),inset 0 -1px 0 var(--border)}
html[data-theme=dark] body:not(.tr-light) .hk-join{box-shadow:inset 0 0 0 1px var(--border)}
html[data-theme=dark] body:not(.tr-light) .lp-band .lp-kicker,html[data-theme=dark] body:not(.tr-light) .sc-final .lp-kicker{color:var(--accent-ink)}
html[data-theme=dark] body:not(.tr-light) .lp-band .lp-h2,html[data-theme=dark] body:not(.tr-light) .sc-final .lp-h2,html[data-theme=dark] body:not(.tr-light) .sc-band-lead,html[data-theme=dark] body:not(.tr-light) .sc-tags li{color:var(--ink)}
html[data-theme=dark] body:not(.tr-light) .sc-final-inner>p,html[data-theme=dark] body:not(.tr-light) .hk-join p{color:var(--ink-2)}
html[data-theme=dark] body:not(.tr-light) .sc-tags li{border-color:var(--border-strong)}
html[data-theme=dark] body:not(.tr-light) .lp-checks .ico,html[data-theme=dark] body:not(.tr-light) .sc-steps li::before{background:var(--accent);color:var(--on-accent)}
html[data-theme=dark] body:not(.tr-light) .btn-invert{background:var(--accent);color:var(--on-accent);box-shadow:0 4px 0 var(--accent-edge)}
html[data-theme=dark] body:not(.tr-light) .sc-btn-line{border-color:var(--accent-ink);color:var(--accent-ink)}
html[data-theme=dark] body:not(.tr-light) .sc-btn-line:hover{background:var(--accent);border-color:var(--accent);color:var(--on-accent)}
html[data-theme=dark] body:not(.tr-light) .sc-band-media img{border-color:var(--border-strong)}
html[data-theme=dark] body:not(.tr-light) .hk-join .k3-soft{border-color:var(--accent-ink)}
/* tone chips (category glyphs, course and tool icons, the active level): bright tones in the dark theme carry dark text */
html[data-theme=dark] body:not(.tr-light) .cat-glyph,html[data-theme=dark] body:not(.tr-light) .lp-ico{color:var(--on-tone,#0e1016)}
html[data-theme=dark] body:not(.tr-light) .cat-card.is-empty .cat-glyph{color:var(--bg)}
/* "odkrycia." in the discovery block and its physics twin: the accent instead of a deep violet / teal made for white */
html[data-theme=dark] body:not(.tr-light) .discover .discover-title span,html[data-theme=dark] body:not(.tr-light) .discover-physics .discover-title span{color:var(--accent-ink)}
html[data-theme=dark] body:not(.tr-light) .discover-perks .ico{color:var(--accent-ink)}
/* level filter: the count inside the active (accent) pill */
.level-filter a[aria-current=page] span{color:var(--on-accent);opacity:.75}

/* ---------- dark theme: the tools (public/assets/tools/*.css were drawn for white) ---------- */
html[data-theme=dark] body:not(.tr-light) .sci-fn,html[data-theme=dark] body:not(.tr-light) .kp-fn,html[data-theme=dark] body:not(.tr-light) .kp-memkey{background:var(--surface-soft)}
html[data-theme=dark] body:not(.tr-light) .sci-ctrl{background:var(--border)}
html[data-theme=dark] body:not(.tr-light) .sci-tab[aria-pressed=true]{background:var(--accent);border-color:var(--accent);color:var(--on-accent)}
html[data-theme=dark] body:not(.tr-light) .kp-screen{background:#07080c;color:var(--ink);box-shadow:inset 0 0 0 1px var(--border)}
html[data-theme=dark] body:not(.tr-light) .kp-expr{color:var(--ink-3)}
html[data-theme=dark] body:not(.tr-light) .kp-main.is-error{color:var(--bad-ink)}
html[data-theme=dark] body:not(.tr-light) .kp-mem{background:var(--accent);color:var(--on-accent)}
html[data-theme=dark] body:not(.tr-light) .nb-line:focus-within{background:var(--surface-soft)}
html[data-theme=dark] body:not(.tr-light) .geo-view{background:var(--surface)}
/* the drawing stages stay white paper (the canvases and SVG plots draw dark ink); what floats over them keeps light colours */
html[data-theme=dark] body:not(.tr-light) .w3d-toolbar .tool-btn:not([aria-pressed=true]),html[data-theme=dark] body:not(.tr-light) .gc-fbtn{background:rgba(255,255,255,.96);border-color:#c9cddb;color:#0e1016}
html[data-theme=dark] body:not(.tr-light) .gc-tip{background:#fff;color:#0e1016}
html[data-theme=dark] body:not(.tr-light) .geo-stage,html[data-theme=dark] body:not(.tr-light) .gc-stage,html[data-theme=dark] body:not(.tr-light) .w3d-stage{box-shadow:inset 0 0 0 1px var(--border)}

/* ---------- second audit pass (2026-11-24) ---------- */
/* ux pages (ranking, profile panels: ux.css) on the dark site: the same tokens as the rest instead of the light paper */
html[data-theme=dark] body:not(.tr-app) .ux-page,.tr-app:not(.tr-light) .ux-page{--ux-paper:var(--surface,#171a24);--ux-soft:var(--surface-soft,#1f2331);--ux-line:var(--border,#2c3144);--ux-text:var(--ink,#f3f4fa);--ux-muted:var(--ink-2,#bcc0d6);--ux-blue:var(--accent-ink,#c3c4ff);--ux-blue-soft:var(--accent-soft,#23244a);--ux-green:var(--ok-ink,#b9f6ce);--ux-green-soft:var(--ok-soft,#12301f)}
/* day orbs (archive, home), English level chips, the skill tree's "next step" pill: bright fills carry dark text in the dark theme */
html[data-theme=dark] body:not(.tr-light) .orb-glyph{color:var(--on-tone,#0e1016)}
html[data-theme=dark] body:not(.tr-light) .orb-link.is-empty .orb-glyph{color:var(--ink-3)}
html[data-theme=dark] body:not(.tr-light) .en-chip{color:#0e1016}
html[data-theme=dark] body:not(.tr-light) .sk-rec-pill{color:var(--on-accent,#0e1016)}
/* "Postęp na każdym urządzeniu" bar on the home: a solid button on the accent bar, and white body text in the light theme */
.hk-join .k3-soft{background:var(--surface);color:var(--ink)}
html:not([data-theme=dark]) .hk-join p{color:#fff}
/* grades 1–2 course map (junior.css): the current unit keeps its own light colour band; trainer-refresh's dark card
   for "current" painted over it and left the dark unit ink on a dark card */
body.tr-app:not(.tr-light) .junior-map .trc-unit.is-current>.trc-unit-head{background:var(--unit-color);color:var(--unit-ink);box-shadow:inset 0 0 0 3px var(--accent)}
/* Hero grade tiles (2026-11-25, A/B variant V2 "najpierw klasa"): the grade is the first question; the old main button
   becomes the secondary "Pomóż mi wybrać lekcję" (home.js turns it primary again for "Kontynuuj" / "Wróć do nauki"). */
.hv-grades{margin:0 0 14px;max-width:520px}
.hv-grades-q{margin:0 0 10px;font:700 1.15rem/1.3 var(--display);color:var(--ink)}
.hv-grades ul{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:10px;margin:0;padding:0;list-style:none}
.hv-grades a{display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:64px;padding:6px 4px;border:2px solid var(--border-strong);border-bottom-width:5px;border-radius:16px;background:var(--surface);color:var(--ink);text-decoration:none;transition:border-color .15s,transform .15s}
.hv-grades a:hover{border-color:var(--accent);transform:translateY(-2px)}
.hv-grades a:active{transform:translateY(2px);border-bottom-width:2px}
.hv-grades a:focus-visible{outline:3px solid var(--accent-ink);outline-offset:2px}
.hv-grades b{font:700 1.45rem/1 var(--display);color:var(--accent-ink)}
.hv-grades span{font-size:.74rem;font-weight:700;color:var(--ink-2)}
.hv-grades [hidden],.hv-grades[hidden]{display:none}
.hv-roles{margin:14px 0 0;font-size:.92rem;color:var(--ink-2)}.hv-roles a{font-weight:700;color:var(--accent-ink)}
@media (max-width:420px){.hv-grades ul{gap:8px}.hv-grades a{min-height:58px;border-radius:14px}.hv-grades b{font-size:1.3rem}}
@media (prefers-reduced-motion:reduce){.hv-grades a{transition:none}.hv-grades a:hover,.hv-grades a:active{transform:none}}
