/* Course overview and focused lesson workspace. */
.course-detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 3.25rem;
  align-items: start;
  margin: 2rem 0 4rem;
}
.course-detail-main, .classroom-main { min-width: 0; }
.course-detail-head { margin-bottom: 2.4rem; }
.course-detail-head .eyebrow { margin-bottom: .85rem; }
.course-detail-head h1 {
  font-size: clamp(2rem, 3.5vw, 3rem);
  line-height: 1.15;
  max-width: 22ch;
  margin-bottom: 1rem;
}
.course-detail-head .page-lead { font-size: 1.05rem; line-height: 1.7; margin-bottom: 1.25rem; }
.course-detail-meta { display: flex; gap: .8rem 1.4rem; flex-wrap: wrap; align-items: center; font-size: .83rem; color: var(--fg-muted); }
.course-detail-tabs { display: flex; gap: 1.8rem; border-bottom: 1px solid var(--line); margin-top: 2rem; }
.course-detail-tabs a { display: block; padding: .9rem 0; font-size: .87rem; font-weight: 600; color: var(--fg); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.course-detail-tabs a:hover { color: var(--accent); border-color: var(--accent); text-decoration: none; }
.course-description { margin-bottom: 3rem; scroll-margin-top: 110px; }
.course-description .prose { font-size: .98rem; line-height: 1.8; max-width: 70ch; }
.course-description .prose h2 { font-size: 1.45rem; line-height: 1.35; margin-top: 1.7rem; border: 0; padding: 0; }
.course-description .prose > :first-child { margin-top: 0; }
.course-section-head { display: flex; align-items: end; justify-content: space-between; gap: 1rem; margin-bottom: 1.4rem; }
.course-section-head .eyebrow { margin: 0 0 .3rem; }
.course-section-head h2 { font-size: 1.65rem; margin: 0; scroll-margin-top: 110px; }
.course-section-head > span { color: var(--fg-muted); font-size: .83rem; white-space: nowrap; }
.course-syllabus { border-top: 1px solid var(--line-strong); }
.course-syllabus .syllabus-row { grid-template-columns: 34px minmax(0, 1fr) 22px; padding: 1.2rem .3rem; gap: 1rem; align-items: start; color: var(--fg); }
.course-syllabus .syllabus-no { width: 32px; height: 32px; border-radius: 5px; font-size: .74rem; color: var(--fg-muted); background: var(--surface-2); margin-top: .05rem; }
.course-syllabus .syllabus-title { font-size: .98rem; line-height: 1.5; font-weight: 600; display: block; }
.course-syllabus .syllabus-sub { font-size: .84rem; line-height: 1.6; display: block; margin-top: .4rem; max-width: 62ch; }
.course-syllabus .syllabus-flags { margin-top: .6rem; gap: .6rem; }
.course-syllabus .syllabus-flags:empty { display: none; }
.course-syllabus .badge { font-size: .67rem; }
.course-syllabus-type { font-size: .72rem; color: var(--fg-muted); }
.course-syllabus-arrow { color: var(--accent); font-size: 1.15rem; padding-top: .1rem; }
.course-lock { width: 19px; height: 19px; margin-top: .35rem; color: var(--fg-faint); }
.course-syllabus .syllabus-row--done .syllabus-no { color: var(--accent); background: var(--accent-soft); }
.course-program-empty { padding: 2rem 0; color: var(--fg-muted); }
.course-enrollment { position: sticky; top: 104px; }
.course-enrollment-panel { border: 1px solid var(--line); background: var(--surface); border-radius: 10px; padding: 1.6rem; }
.course-enrollment-panel .eyebrow { margin-bottom: .6rem; }
.course-enrollment-panel h2 { font-size: 1.25rem; line-height: 1.45; margin-bottom: 1rem; letter-spacing: -.025em; }
.course-enrollment-price { font-size: 2.5rem; font-weight: 650; line-height: 1.2; letter-spacing: -.04em; margin: 1.5rem 0 .35rem; font-variant-numeric: tabular-nums; }
.course-enrollment-price span { font-size: 1.2rem; font-weight: 500; letter-spacing: 0; }
.course-enrollment-caption { color: var(--fg-muted); font-size: .76rem; line-height: 1.6; margin-bottom: 1.5rem; }
.course-enrollment-panel .btn--block { display: flex; justify-content: center; align-items: center; gap: .8rem; min-height: 46px; font-size: .86rem; }
.course-redeem { text-align: center; margin: .9rem 0 1.4rem; font-size: .77rem; }
.course-redeem a { text-underline-offset: 3px; }
.course-facts { margin: 1.5rem 0 0; padding-top: .35rem; border-top: 1px solid var(--line); }
.course-facts > div { display: flex; justify-content: space-between; gap: 1rem; padding: .65rem 0; font-size: .79rem; }
.course-facts dt { color: var(--fg-muted); }
.course-facts dd { margin: 0; text-align: right; font-weight: 550; }
.course-enrollment-note { font-size: .76rem; line-height: 1.6; color: var(--fg-muted); padding-top: 1rem; border-top: 1px solid var(--line); margin: .4rem 0 0; }
.course-team-note { margin-top: 1.25rem; padding: 0 .3rem; }
.course-team-note h3 { font-size: .85rem; margin-bottom: .35rem; }
.course-team-note p { color: var(--fg-muted); font-size: .78rem; line-height: 1.65; margin: 0; }
.course-team-note a { text-decoration: underline; text-underline-offset: 3px; }
.course-progress-caption { display: flex; justify-content: space-between; align-items: center; gap: 1rem; font-size: .76rem; color: var(--fg-muted); margin: 1.3rem 0 .45rem; }
.course-progress-caption strong { color: var(--fg); font-variant-numeric: tabular-nums; }
.course-progress { font-size: .8rem; }
.course-next-label { font-size: .72rem; color: var(--fg-muted); margin: 1.3rem 0; }
.course-next-label strong { display: block; font-size: .85rem; font-weight: 550; line-height: 1.5; color: var(--fg); margin-top: .25rem; }
.course-enrollment .certificate-link { display: block; text-align: center; font-size: .8rem; margin: .9rem 0 0; }
.course-exam-link { margin-top: 1.4rem; padding-top: 1.2rem; border-top: 1px solid var(--line); }
.course-exam-link p { font-size: .69rem; text-align: center; color: var(--fg-muted); margin: .6rem 0 0; }

.classroom-layout { grid-template-columns: 285px minmax(0, 1fr); gap: 3rem; margin: 2rem 0 4rem; }
.classroom-aside { position: sticky; top: 104px; }
.classroom-outline { border-radius: 8px; background: var(--surface); overflow: hidden; }
.classroom-aside > .classroom-outline { position: static; max-height: none; overflow: hidden; }
.classroom-outline-heading { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 1rem; cursor: pointer; padding: 1rem 1.1rem; font-size: .85rem; font-weight: 650; }
.classroom-outline-heading::-webkit-details-marker { display: none; }
.classroom-outline[open] .classroom-outline-heading { border-bottom: 1px solid var(--line); }
.classroom-outline-toggle { font-size: 1.2rem; font-weight: 400; line-height: 1; transform: rotate(-90deg); transition: transform .18s ease; }
.classroom-outline[open] .classroom-outline-toggle { transform: rotate(0); }
.classroom-outline-content { max-height: calc(100dvh - 210px); overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.classroom-course-link { padding: 1rem 1.1rem .3rem; line-height: 1.5; }
.classroom-course-link a { color: var(--fg); font-size: .85rem; font-weight: 600; }
.classroom-progress { padding: .6rem 1.1rem 1.1rem; border-bottom: 1px solid var(--line); }
.classroom-progress-caption { display: flex; justify-content: space-between; gap: .5rem; font-size: .67rem; color: var(--fg-muted); margin-bottom: .5rem; font-variant-numeric: tabular-nums; }
.classroom-progress .progress { gap: .6rem; }
.classroom-progress .progress-label { font-size: .65rem; min-width: 27px; text-align: right; }
.classroom-progress progress { height: 5px; }
.classroom-outline .syllabus-row { grid-template-columns: 25px minmax(0, 1fr); gap: .65rem; padding: .9rem 1rem; align-items: start; border-left: 3px solid transparent; }
.classroom-outline .syllabus-no { width: 25px; height: 25px; font-size: .65rem; border-radius: 4px; margin-top: .05rem; }
.classroom-outline .syllabus-title { font-size: .77rem; line-height: 1.55; color: var(--fg-muted); font-weight: 450; }
.classroom-outline .syllabus-row--current { border-left-color: var(--accent); background: var(--accent-soft); }
.classroom-outline .syllabus-row--current .syllabus-title { color: var(--accent); font-weight: 600; }
.classroom-outline .syllabus-row--done .syllabus-no { color: var(--accent); background: var(--accent-soft); }
.classroom-outline .syllabus-row--current .syllabus-no { color: #fff; background: var(--accent); }
.classroom-outline .syllabus-flags { grid-column: 2; }
.classroom-outline .syllabus-flags:empty { display: none; }
.classroom-outline .badge { font-size: .61rem; padding: .12rem .35rem; }
.classroom-course-back { display: block; padding: 1rem 1.1rem; font-size: .72rem; color: var(--fg-muted); border-top: 1px solid var(--line); }
.classroom-main { max-width: 850px; }
.classroom-head.page-head { margin: 0 0 1.5rem; }
.classroom-head .eyebrow { margin-bottom: .7rem; }
.classroom-layout .classroom-head h1 { font-size: clamp(1.85rem, 2.6vw, 2.5rem); line-height: 1.2; margin: 0 0 .8rem; }
.classroom-summary { font-size: .96rem; line-height: 1.75; color: var(--fg-muted); max-width: 66ch; margin-bottom: .9rem; }
.classroom-head .meta { margin: 0; }
.classroom-head .meta:empty { display: none; }
.classroom-head .badge { font-size: .69rem; }
.classroom-main .lesson-shortcuts { margin-bottom: 2rem; padding: 0; gap: 1.6rem; font-size: .79rem; }
.classroom-main .lesson-shortcuts a { display: block; padding: .8rem 0; color: var(--fg-muted); font-weight: 550; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.classroom-main .lesson-shortcuts a:hover { color: var(--accent); border-bottom-color: var(--accent); text-decoration: none; }
.classroom-main .prose { max-width: 74ch; font-size: 1rem; line-height: 1.85; overflow-wrap: break-word; }
.classroom-main .prose > :first-child { margin-top: 0; }
.classroom-main .prose h2 { font-size: 1.55rem; line-height: 1.4; padding-top: .3rem; padding-bottom: .65rem; margin-top: 2.5rem; }
.classroom-main .prose h3 { font-size: 1.18rem; line-height: 1.5; }
.classroom-main .prose pre { font-size: .81rem; line-height: 1.75; }
.classroom-main .prose table { font-size: .85rem; }
.classroom-main .prose th, .classroom-main .prose td { padding: .7rem .85rem; }
.classroom-main #material, .classroom-main #praktyka, .classroom-main #sprawdzian { scroll-margin-top: 110px; }
.classroom-exercises { margin-top: 3rem; }
.classroom-main .section-head h2 { font-size: 1.5rem; }
.classroom-exercises .grid { display: grid; grid-template-columns: 1fr; gap: .8rem; }
.classroom-exercise.card { padding: 1.3rem; border: 1px solid var(--line); border-radius: 8px; box-shadow: none; background: var(--surface); }
.classroom-exercise h3 { font-size: 1rem; line-height: 1.5; margin-bottom: .45rem; }
.classroom-exercise h3 a { color: var(--fg); }
.classroom-exercise .card-sub { font-size: .82rem; line-height: 1.6; }
.classroom-exercise .card-foot { padding-top: .7rem; margin-top: .1rem; }
.classroom-exercise .card-foot .btn { margin-left: auto; font-size: .76rem; }
.classroom-main .quiz { margin-top: 2.5rem; border-radius: 8px; padding: 1.7rem; }
.classroom-main .quiz .section-head { align-items: start; flex-wrap: wrap; gap: .5rem; margin-bottom: 1.4rem; }
.classroom-main .quiz .progress-label { font-size: .73rem; }
.classroom-main .q-prompt { font-size: .96rem; line-height: 1.65; }
.classroom-main .q-opt { font-size: .9rem; line-height: 1.6; }
.classroom-main .q-hint { font-size: .75rem; }
.classroom-main .result h2 { font-size: 1.3rem; }
.classroom-main .result-score { font-size: 2rem; }
.classroom-complete { margin-top: 2.5rem; }
.classroom-attempts { color: var(--fg-muted); font-size: .8rem; margin-top: 1.5rem; }
.classroom-main .lesson-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid var(--line); }
.classroom-main .lesson-nav a { display: block; min-width: 0; color: var(--fg); line-height: 1.5; }
.classroom-main .lesson-nav a:hover { color: var(--accent); text-decoration: none; }
.classroom-main .lesson-nav span { display: block; font-size: .72rem; color: var(--fg-muted); margin-bottom: .4rem; }
.classroom-main .lesson-nav strong { font-size: .85rem; font-weight: 550; }
.classroom-next { text-align: right; }
.classroom-locked.locked-box { text-align: left; padding: 2rem; border-style: solid; border-radius: 8px; }
.classroom-locked .locked-icon { display: grid; place-items: center; width: 44px; height: 44px; margin-bottom: 1.2rem; border-radius: 8px; color: var(--accent); background: var(--accent-soft); }
.classroom-locked .locked-icon svg { width: 24px; height: 24px; }
.classroom-locked h2 { font-size: 1.5rem; }
.classroom-locked.locked-box p { max-width: 60ch; margin-left: 0; font-size: .92rem; }
.classroom-locked .locked-actions { justify-content: start; margin-top: 1.5rem; }

@media (max-width: 1050px) {
  .course-detail-layout { grid-template-columns: minmax(0, 1fr) 300px; gap: 2rem; }
  .classroom-layout { grid-template-columns: 250px minmax(0, 1fr); gap: 2rem; }
  .classroom-aside { position: static; }
  .classroom-outline-content { max-height: 680px; }
}
@media (max-width: 780px) {
  .course-detail-layout { display: flex; flex-direction: column; gap: 2rem; margin-top: 1.4rem; }
  .course-detail-main { display: contents; }
  .course-detail-head { order: 0; width: 100%; margin: 0; }
  .course-detail-head h1 { max-width: 26ch; }
  .course-enrollment { position: static; order: 1; width: 100%; }
  .course-description { order: 2; margin: 0; width: 100%; }
  .course-program { order: 3; width: 100%; }
  .course-enrollment-panel { padding: 1.4rem; }
  .course-enrollment-panel h2 { font-size: 1.25rem; }
  .course-enrollment-price { margin-top: 1rem; }
  .course-facts { display: grid; grid-template-columns: 1fr 1fr; gap: 0 2rem; }
  .course-facts > div { flex-direction: column; gap: .1rem; }
  .course-facts dd { text-align: left; }
  .classroom-layout { display: flex; flex-direction: column; gap: 1.75rem; margin-top: 1.4rem; }
  .classroom-aside { order: 0; width: 100%; }
  .classroom-main { width: 100%; }
  .classroom-outline-content { max-height: 230px; }
  .classroom-course-link { display: none; }
  .classroom-progress { padding: .8rem 1rem; }
  .classroom-outline .syllabus-row { padding: .75rem 1rem; }
  .classroom-outline .syllabus-title { font-size: .82rem; }
  .classroom-main .lesson-shortcuts { gap: 1.1rem; }
}
@media (max-width: 480px) {
  .course-detail-head h1 { font-size: 2rem; }
  .course-detail-head .page-lead { font-size: .96rem; }
  .course-detail-meta { gap: .6rem 1rem; font-size: .78rem; }
  .course-syllabus .syllabus-row { grid-template-columns: 27px minmax(0, 1fr) 18px; gap: .65rem; }
  .course-syllabus .syllabus-no { width: 26px; height: 26px; font-size: .65rem; }
  .course-syllabus .syllabus-title { font-size: .9rem; }
  .course-syllabus .syllabus-sub { font-size: .79rem; }
  .course-section-head h2 { font-size: 1.45rem; }
  .course-section-head > span { font-size: .74rem; }
  .course-lock { width: 17px; }
  .classroom-main .prose { font-size: .95rem; }
  .classroom-main .prose h2 { font-size: 1.35rem; }
  .classroom-main .quiz { padding: 1.1rem; }
  .classroom-main .lesson-nav { gap: 1rem; }
  .classroom-main .lesson-nav strong { font-size: .78rem; }
  .classroom-main .lesson-nav span { font-size: .65rem; }
  .classroom-locked.locked-box { padding: 1.3rem; }
  .classroom-locked .locked-actions { align-items: stretch; flex-direction: column; }
}

/* Wideo powitalne mentora na stronie kursu (COURSE_SEO[...]["powitanie"]). */
.course-mentor {
  display: grid; grid-template-columns: 232px minmax(0, 1fr); gap: 1.4rem; align-items: center;
  margin: 1.5rem 0 1.4rem; padding: 1rem 1.4rem 1rem 1rem; max-width: 46rem;
  background: linear-gradient(120deg, var(--accent-soft) 0%, transparent 58%), var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow);
}
.course-mentor-kadr { position: relative; }
.course-mentor-wideo {
  display: block; width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: cover;
  border-radius: 14px; background: var(--surface-2);
}
.course-mentor-dzwiek {
  position: absolute; left: 50%; top: 12px; transform: translateX(-50%);
  display: inline-flex; align-items: center; gap: .35rem; white-space: nowrap;
  padding: .4rem .8rem .4rem .6rem; border: 0; border-radius: 999px; cursor: pointer;
  background: var(--accent); color: #fff; font: inherit; font-size: .8rem; font-weight: 700;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .3);
}
.course-mentor-dzwiek:hover { background: var(--accent-hover, var(--accent)); }
.course-mentor-dzwiek[hidden] { display: none; }
.course-mentor-dzwiek path { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.course-mentor-opis .eyebrow { margin: 0 0 .45rem; }
.course-mentor-tytul { margin: 0 0 .45rem; font-size: 1.12rem; font-weight: 700; line-height: 1.35; color: var(--fg); }
.course-mentor-lead { margin: 0 0 .7rem; font-size: .9rem; line-height: 1.6; color: var(--fg-muted); }
.course-mentor-transkrypcja { font-size: .88rem; }
.course-mentor-transkrypcja summary { cursor: pointer; color: var(--accent); font-weight: 600; }
.course-mentor-transkrypcja p { margin: .5rem 0 0; line-height: 1.65; color: var(--fg); }
/* atrybucja glosu mentora (CC BY 4.0 nagrania referencyjnego TTS) - maly druk;
   pod wideo powitania i w stopce lekcji/cwiczen (courses/_mentor_glos.html) */
.mentor-glos { margin: .6rem 0 0; font-size: .74rem; line-height: 1.5; color: var(--fg-muted); }
.mentor-glos a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.lesson-layout + .mentor-glos, .lesson-nav + .mentor-glos { margin-top: 1.5rem; }
@media (max-width: 600px) {
  .course-mentor { grid-template-columns: 1fr; gap: 1rem; padding: .9rem; }
  .course-mentor-kadr { max-width: 340px; width: 100%; margin: 0 auto; }
}
