:root {
  --blue: #0b5683;
  --blue-dark: #073e60;
  --green: #27864c;
  --green-dark: #206e3f;
  --ink: #111827;
  --muted: #4b5563;
  --line: #dce5e9;
  --pale-blue: #edf5f9;
  --pale-green: #eef7f0;
  --page: #f7fafb;
  --white: #fff;
  --radius: 12px;
  font-family: "Nunito Sans", Arial, sans-serif;
  color: var(--ink);
  background: var(--page);
  font-size: 18px;
  line-height: 1.55;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  font-family: inherit;
}
h1,
h2,
h3,
h4 {
  color: var(--blue);
  line-height: 1.22;
  letter-spacing: -0.025em;
  margin: 0;
}
h1 {
  font-size: 46px;
  font-weight: 800;
}
h2 {
  font-size: 27px;
  font-weight: 800;
}
h3 {
  font-size: 22px;
  font-weight: 800;
}
h4 {
  font-size: 21px;
  font-weight: 700;
}
p {
  margin: 0 0 14px;
}
a {
  color: var(--blue);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: not-allowed;
  opacity: 0.65;
}
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid #459bc0;
  outline-offset: 3px;
}
svg {
  flex-shrink: 0;
}
input,
select,
textarea {
  color: var(--ink);
  background: #fff;
  border: 1px solid #adbec8;
  border-radius: 8px;
  padding: 11px 13px;
  min-width: 0;
  width: 100%;
}
textarea {
  resize: vertical;
  min-height: 200px;
  line-height: 1.6;
}
input::placeholder,
textarea::placeholder {
  color: #616e78;
}
input[type="file"] {
  padding: 9px;
  max-width: 100%;
}
input[type="checkbox"] {
  width: 20px;
  height: 20px;
  accent-color: var(--green);
}
.portal-header {
  height: 96px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  padding: 12px 40px;
  display: flex;
  align-items: center;
  gap: 30px;
  position: sticky;
  top: 0;
  z-index: 20;
}
.brand {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}
.brand img {
  width: 220px;
  height: auto;
  max-height: 72px;
  object-fit: contain;
}
.header-course {
  border-left: 1px solid var(--line);
  padding-left: 26px;
  display: flex;
  flex-direction: column;
  line-height: 1.4;
}
.header-course > span {
  font-size: 16px;
  color: var(--muted);
}
.header-course strong {
  font-size: 21px;
  color: var(--blue);
}
.header-user {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
  color: var(--muted);
  font-size: 18px;
}
.header-user svg {
  color: var(--green);
}
.eyebrow {
  display: block;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  font-weight: 800;
  font-size: 16px;
  color: var(--green);
  margin-bottom: 10px;
}
.source {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 16px;
}
.source-dot {
  background: var(--green);
  border-radius: 50%;
  width: 7px;
  height: 7px;
  display: inline-block;
}
.primary-button,
.secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 11px;
  min-height: 49px;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 18px;
  font-weight: 800;
  line-height: 1.35;
  text-align: center;
  border: 1px solid transparent;
  transition:
    background 0.15s,
    color 0.15s;
}
.primary-button {
  background: var(--green);
  color: #fff;
}
.primary-button:hover {
  background: var(--green-dark);
  color: #fff;
  text-decoration: none;
}
.secondary-button {
  background: #fff;
  border-color: #a9bdc9;
  color: var(--blue);
}
.secondary-button:hover {
  background: var(--pale-blue);
  text-decoration: none;
}
.text-button {
  border: 0;
  background: none;
  padding: 8px 0;
  color: var(--blue);
  font-weight: 700;
  font-size: 18px;
  text-decoration: underline;
}
.button-row {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.notice {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 18px 20px;
  border: 1px solid #bed5e2;
  background: var(--pale-blue);
  border-radius: var(--radius);
  font-size: 18px;
  margin: 24px 0;
}
.notice > svg {
  color: var(--blue);
  margin-top: 3px;
}
.notice p:last-child {
  margin-bottom: 0;
}
.notice strong {
  color: var(--blue);
}
.muted-text {
  color: var(--muted);
  font-size: 16px;
  display: block;
}
.error-text,
.form-message.error {
  color: #a82323;
}
.form-message {
  padding: 12px 14px;
  background: var(--pale-blue);
  border-radius: 8px;
  margin: 16px 0;
  font-size: 18px;
}
.form-message:empty {
  display: none;
}
.form-message.error {
  background: #fff0ed;
  border: 1px solid #e1b3a7;
}
.form-message.success {
  color: var(--green-dark);
  background: var(--pale-green);
}
.portal-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  border-top: 1px solid var(--line);
  padding: 22px 40px;
  font-size: 16px;
  color: var(--muted);
}
.portal-main {
  max-width: 1140px;
  margin: auto;
  padding: 56px 28px 64px;
  min-height: calc(100vh - 170px);
}
.auth-layout {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 64px;
  align-items: center;
}
.auth-intro {
  padding-right: 16px;
}
.auth-intro h1 {
  margin: 0 0 22px;
}
.auth-intro p {
  font-size: 20px;
  max-width: 530px;
  line-height: 1.65;
}
.auth-intro ol {
  padding: 0;
  list-style: none;
  counter-reset: step;
  margin: 30px 0;
}
.auth-intro ol li {
  position: relative;
  padding: 0 0 20px 48px;
  counter-increment: step;
  font-size: 18px;
  min-height: 46px;
}
.auth-intro ol li:before {
  content: counter(step);
  width: 33px;
  height: 33px;
  position: absolute;
  left: 0;
  top: 0;
  border-radius: 50%;
  background: var(--pale-green);
  color: var(--green-dark);
  font-weight: 800;
  display: grid;
  place-items: center;
}
.auth-card {
  background: #fff;
  padding: 30px;
  border: 1px solid var(--line);
  border-top: 4px solid var(--green);
  border-radius: var(--radius);
  box-shadow: 0 12px 38px #103d5810;
}
.auth-card h2 {
  margin-bottom: 12px;
}
.auth-card > p {
  color: var(--muted);
}
.form-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 20px 0;
  font-size: 18px;
}
.form-field > span,
.form-field > label {
  font-weight: 700;
  color: var(--ink);
}
.form-field small {
  font-size: 16px;
  color: var(--muted);
  font-weight: 400;
}
.auth-card .primary-button {
  width: 100%;
  margin-top: 6px;
}
.auth-card form + a,
.auth-card .forgot-link {
  display: block;
  text-align: center;
  margin: 18px 0;
}
.auth-card hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 24px 0;
}
.auth-card a {
  font-weight: 700;
}
.auth-card .notice {
  font-size: 16px;
  margin: 20px 0 0;
  padding: 14px;
}
.auth-card .notice a {
  display: inline;
}
.auth-bottom {
  border-top: 1px solid var(--line);
  margin-top: 22px;
  padding-top: 20px;
  text-align: center;
  font-size: 16px;
}
.portal-link {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  font-weight: 700;
}
.admin-layout {
  max-width: 1150px;
  margin: auto;
  padding: 38px 28px;
}
.admin-layout h1 {
  margin-bottom: 15px;
}
.admin-card {
  padding: 24px;
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin: 22px 0;
}
.admin-card h2 {
  margin-bottom: 18px;
}
.admin-card h3 {
  margin: 20px 0 12px;
}
.table-wrap {
  width: 100%;
  overflow: auto;
}
table {
  border-collapse: collapse;
  width: 100%;
  text-align: left;
  font-size: 18px;
}
td,
th {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
th {
  color: var(--blue);
  background: var(--pale-blue);
  font-weight: 800;
}
table td {
  overflow-wrap: anywhere;
}
.admin-stats {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}
.admin-stats > div {
  padding: 16px;
  background: var(--pale-green);
  border-radius: 8px;
  min-width: 180px;
}
.admin-stats strong {
  font-size: 30px;
  color: var(--green);
  display: block;
}
.admin-status {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin: 12px 0;
}
.admin-status span {
  padding: 5px 10px;
  background: var(--pale-blue);
  border-radius: 7px;
}
.training-shell {
  min-height: 100vh;
}
.shell-body {
  display: flex;
  align-items: stretch;
}
.course-sidebar {
  width: 280px;
  flex: 0 0 280px;
  background: #fff;
  border-right: 1px solid var(--line);
  padding: 30px 20px 24px;
  min-height: calc(100vh - 96px);
}
.sidebar-heading {
  padding: 0 10px 24px;
}
.sidebar-heading h2 {
  font-size: 24px;
  margin-bottom: 8px;
}
.course-code {
  font-size: 16px;
  color: var(--muted);
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 12px;
  border-radius: 8px;
  color: var(--ink);
  font-weight: 700;
  font-size: 18px;
}
.nav-item:hover,
.day-nav:hover {
  background: var(--pale-blue);
  text-decoration: none;
}
.nav-item.active,
.day-nav.active {
  background: var(--pale-blue);
  color: var(--blue);
}
.nav-item.active {
  box-shadow: inset 3px 0 0 var(--green);
}
.sidebar-divider {
  height: 1px;
  background: var(--line);
  margin: 20px 10px;
}
.sidebar-block {
  padding: 0 6px;
  margin: 18px 0;
}
.block-label {
  font-weight: 800;
  color: var(--blue);
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 14px 6px;
  font-size: 18px;
}
.block-label > span {
  font-size: 16px;
  font-weight: 400;
  color: var(--muted);
}
.day-nav {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 8px;
  font-size: 18px;
  color: var(--ink);
  border-radius: 8px;
  margin: 3px 0;
}
.day-nav svg {
  margin-left: auto;
  color: #647787;
}
.day-nav-number {
  width: 32px;
  height: 32px;
  border: 1px solid #d3e0e7;
  border-radius: 7px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 800;
  color: var(--blue);
  flex-shrink: 0;
  background: #f8fbfd;
}
.day-nav.active .day-nav-number {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
}
.sidebar-bottom {
  margin: 28px 6px 0;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.platform-link {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 800;
}
.sidebar-note {
  font-size: 16px;
  color: var(--muted);
  margin-top: 12px;
}
.logout-button {
  display: flex;
  align-items: center;
  gap: 10px;
  background: none;
  border: 0;
  font-size: 18px;
  color: var(--muted);
  padding: 10px 0;
}
.training-main {
  flex: 1;
  min-width: 0;
  padding: 38px 44px;
  max-width: 1320px;
}
.page-heading {
  margin: 0 0 28px;
  max-width: 880px;
}
.page-heading h1 {
  margin: 0 0 17px;
}
.page-heading > p {
  font-size: 20px;
  max-width: 790px;
  margin-bottom: 0;
}
.overview-ribbon {
  display: flex;
  gap: 20px;
  margin: 30px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 21px 0;
  flex-wrap: wrap;
}
.ribbon-item {
  display: flex;
  gap: 12px;
  align-items: center;
  flex: 1;
  min-width: 200px;
}
.ribbon-item > svg {
  color: var(--blue);
  width: 26px;
  height: 26px;
}
.ribbon-item > span {
  display: flex;
  flex-direction: column;
}
.ribbon-item strong {
  font-size: 20px;
  color: var(--blue);
}
.ribbon-item small {
  font-size: 16px;
  color: var(--muted);
}
.course-start-banner {
  display: flex;
  align-items: center;
  gap: 24px;
  background: var(--pale-green);
  border: 1px solid #c5dfcd;
  border-radius: var(--radius);
  padding: 23px 26px;
  margin-bottom: 24px;
}
.course-start-banner > div {
  flex: 1;
}
.course-start-banner h2 {
  margin-bottom: 10px;
}
.course-start-banner p {
  font-size: 18px;
  margin: 0;
  max-width: 650px;
}
.course-start-banner .eyebrow {
  margin-bottom: 8px;
}
.course-start-banner .primary-button {
  flex-shrink: 0;
}
.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 26px 0 20px;
}
.section-heading h2 {
  display: flex;
  align-items: center;
  gap: 11px;
}
.section-heading > span {
  font-size: 16px;
  color: var(--muted);
}
.course-filters {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  padding: 0 0 12px;
}
.block-tabs {
  display: flex;
  gap: 3px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  padding: 4px;
  flex-shrink: 0;
}
.block-tabs button {
  font-size: 18px;
  font-weight: 700;
  padding: 9px 13px;
  border: 0;
  border-radius: 6px;
  background: none;
  color: var(--muted);
}
.block-tabs button.selected {
  background: var(--blue);
  color: #fff;
}
.subject-filter {
  flex: 1;
  min-width: 155px;
}
.subject-filter select {
  height: 49px;
  border-color: var(--line);
}
.search-field {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 1px solid var(--line);
  padding: 0 12px;
  border-radius: 8px;
  min-width: 180px;
  flex: 1;
}
.search-field input {
  padding: 10px 0;
  border: 0;
  background: none;
  min-height: 47px;
  width: 100%;
}
.search-field svg {
  color: var(--muted);
}
.result-count {
  font-size: 18px;
  color: var(--green-dark);
  font-weight: 700;
  margin-bottom: 15px;
}
.day-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
}
.day-card {
  display: flex;
  gap: 21px;
  align-items: flex-start;
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  color: var(--ink);
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
}
.day-card:hover {
  border-color: #85b1ca;
  box-shadow: 0 4px 16px #1255740b;
  text-decoration: none;
}
.day-number {
  width: 56px;
  height: 60px;
  display: grid;
  place-items: center;
  background: var(--pale-blue);
  border-radius: 10px;
  color: var(--blue);
  font-weight: 900;
  font-size: 26px;
  flex-shrink: 0;
}
.day-card-content {
  flex: 1;
  min-width: 0;
}
.day-card-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 9px;
}
.day-card-topline > span:first-child {
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 16px;
  color: var(--green);
  font-weight: 800;
}
.day-card h3 {
  margin-bottom: 14px;
}
.day-topics p {
  font-size: 18px;
  margin: 7px 0;
  color: var(--ink);
}
.day-topics strong {
  font-weight: 800;
  color: var(--blue);
}
.status-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 6px;
  background: #eff2f4;
  color: var(--muted);
  padding: 5px 10px;
  font-size: 18px;
  line-height: 1.4;
  white-space: normal;
  font-weight: 700;
}
.status-pill.working {
  background: var(--pale-blue);
  color: var(--blue);
}
.status-pill.reviewed {
  background: var(--pale-green);
  color: var(--green-dark);
}
.day-flags {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 14px;
}
.day-flags span {
  padding: 4px 9px;
  border: 1px solid #b9d8c4;
  background: var(--pale-green);
  color: var(--green-dark);
  font-size: 16px;
  border-radius: 6px;
}
.day-arrow {
  margin-top: 33px;
  color: var(--blue);
}
.training-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  font-size: 16px;
  color: var(--muted);
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 23px;
}
.day-heading {
  margin-bottom: 32px;
}
.content-section {
  margin: 25px 0 32px;
}
.subject-panels {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.subject-panel {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.subject-panel-heading {
  padding: 16px 20px;
  background: var(--pale-blue);
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.subject-panel-heading > span {
  font-size: 16px;
  color: var(--muted);
}
.subject-panel-heading.subject-deutsch {
  border-left: 4px solid #257b9a;
}
.subject-panel-heading.subject-mathematik,
.subject-panel-heading.subject-geometrie {
  border-left: 4px solid #0b5683;
}
.subject-panel-heading.subject-französisch {
  border-left: 4px solid var(--green);
}
.subject-panel-heading.subject-englisch {
  border-left: 4px solid #578376;
}
.subject-items {
  padding: 0 20px;
}
.topic-item {
  padding: 20px 0;
}
.topic-item + .topic-item {
  border-top: 1px solid var(--line);
}
.topic-label {
  display: block;
  font-size: 16px;
  color: var(--muted);
  margin-bottom: 8px;
  line-height: 1.5;
}
.topic-item h4 {
  font-size: 21px;
  font-weight: 700;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.check-notice {
  background: var(--pale-blue);
  margin-top: 26px;
}
.check-notice h2 {
  font-size: 23px;
  margin-bottom: 12px;
}
.homework-box {
  padding: 22px 24px;
  background: var(--pale-green);
  border: 1px solid #bfdcc9;
  border-left: 4px solid var(--green);
  border-radius: var(--radius);
  font-size: 18px;
}
.homework-box h3 {
  margin: 10px 0 17px;
}
.homework-box .text-link {
  display: flex;
  width: fit-content;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  margin: 12px 0;
}
.resource-list {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.resource-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 22px;
}
.resource-row + .resource-row {
  border-top: 1px solid var(--line);
}
.resource-row > svg {
  color: var(--blue);
}
.resource-row > div {
  flex: 1;
  min-width: 0;
}
.resource-row h3 {
  font-size: 21px;
  margin-bottom: 7px;
}
.resource-row p {
  font-size: 18px;
  color: var(--muted);
  margin: 0;
}
.resource-status {
  color: var(--muted);
  font-size: 16px;
  padding: 5px 8px;
  background: #f1f4f6;
  border-radius: 5px;
  max-width: 180px;
}
.personal-section {
  background: white;
  border: 1px solid var(--line);
  border-top: 4px solid var(--green);
  padding: 25px;
  border-radius: var(--radius);
  margin: 30px 0;
}
.personal-section .section-heading {
  margin-top: 0;
}
.personal-section .section-heading > svg {
  color: var(--green);
}
.personal-section .form-field {
  margin: 19px 0;
}
.status-field {
  max-width: 390px;
}
.notes-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 16px;
  color: var(--muted);
  margin-bottom: 17px;
}
.save-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--blue);
  font-size: 18px;
}
.save-indicator.saved {
  color: var(--green-dark);
}
.save-error {
  background: #fff4ec;
  border: 1px solid #ddc0a8;
  padding: 14px;
  border-radius: 8px;
  font-size: 18px;
  max-width: 100%;
}
.save-error p {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.save-error .button-row button {
  font-size: 18px;
}
.pending-banner {
  background: #fff4e6;
  border: 1px solid #dbc29e;
  color: #7c4e13;
  padding: 14px 18px;
  border-radius: 8px;
  margin-bottom: 22px;
  font-size: 18px;
}
.day-pagination {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 28px;
}
.progress-summary {
  display: flex;
  gap: 40px;
  background: #fff;
  padding: 26px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  margin: 26px 0;
}
.progress-main {
  flex: 1;
}
.progress-value {
  font-size: 54px;
  font-weight: 900;
  color: var(--green);
  line-height: 1.3;
}
.progress-value > span {
  font-size: 24px;
  color: var(--muted);
  font-weight: 600;
  margin-left: 8px;
}
.progress-track {
  height: 9px;
  background: var(--pale-green);
  border-radius: 5px;
  margin: 15px 0;
  overflow: hidden;
}
.progress-track > span {
  height: 100%;
  display: block;
  background: var(--green);
  border-radius: 5px;
}
.progress-main > p {
  font-size: 18px;
  color: var(--muted);
  margin: 0;
}
.progress-facts {
  display: flex;
  flex-direction: column;
  gap: 22px;
  justify-content: center;
  min-width: 230px;
  padding-left: 30px;
  border-left: 1px solid var(--line);
}
.progress-facts > div {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.progress-facts svg {
  color: var(--blue);
}
.progress-facts strong {
  font-size: 27px;
  color: var(--green);
}
.progress-facts span {
  font-size: 18px;
}
.progress-day-list {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.progress-day {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  padding: 22px;
}
.progress-day + .progress-day {
  border-top: 1px solid var(--line);
}
.progress-day-detail {
  flex: 1;
  min-width: 0;
}
.progress-day-detail h3 {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 22px;
}
.progress-day-detail p {
  font-size: 18px;
  margin: 9px 0;
  color: var(--muted);
  overflow-wrap: anywhere;
}
.progress-day-detail .save-indicator {
  font-size: 18px;
}
.icon-button {
  border: 0;
  background: none;
  padding: 9px;
  color: var(--blue);
  display: inline-flex;
}
.mobile-menu {
  display: none;
}
.empty-state,
.loading-panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 34px;
  text-align: center;
  margin: 24px auto;
  max-width: 900px;
}
.empty-state svg {
  color: var(--blue);
  margin: 0 auto 18px;
  display: block;
}
.empty-state h3,
.loading-panel h1 {
  margin-bottom: 14px;
}
.loading-panel h1 {
  font-size: 29px;
}
.loading-panel > a {
  display: block;
  margin-top: 20px;
  font-size: 18px;
}
.loader {
  height: 30px;
  width: 30px;
  border: 3px solid #d5e8f2;
  border-top-color: var(--blue);
  border-radius: 50%;
  margin: 0 auto 22px;
  animation: spin 1s linear infinite;
}
.spin {
  animation: spin 1s linear infinite;
}
.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;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
@media (min-width: 1650px) {
  .training-main {
    padding-right: 65px;
    padding-left: 65px;
  }
}
@media (max-width: 1200px) {
  .portal-header {
    padding: 12px 24px;
  }
  .course-sidebar {
    width: 245px;
    flex-basis: 245px;
    padding: 28px 14px;
  }
  .training-main {
    padding: 34px 27px;
  }
  .header-user {
    max-width: 240px;
    overflow-wrap: anywhere;
  }
  .course-start-banner {
    flex-wrap: wrap;
  }
  .course-start-banner .primary-button {
    margin-left: 0;
  }
  .ribbon-item {
    min-width: 175px;
  }
  .course-filters .search-field {
    min-width: 220px;
  }
  .auth-layout {
    gap: 36px;
  }
  .auth-card {
    padding: 26px;
  }
  .subject-panels {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 900px) {
  .portal-header {
    height: 87px;
    padding: 12px 20px;
    gap: 18px;
  }
  .brand img {
    width: 185px;
  }
  .header-course {
    padding-left: 18px;
  }
  .header-user {
    display: none;
  }
  .auth-layout {
    grid-template-columns: 1fr;
    gap: 24px;
    max-width: 650px;
    margin: auto;
  }
  .auth-intro {
    padding: 0;
  }
  .auth-intro h1 br {
    display: none;
  }
  .auth-intro ol {
    margin: 24px 0 0;
  }
  .portal-main {
    padding-top: 36px;
  }
  .auth-card {
    padding: 28px;
  }
  .course-sidebar {
    flex-basis: 225px;
    width: 225px;
  }
  .training-main {
    padding: 30px 24px;
  }
  h1 {
    font-size: 39px;
  }
  .progress-summary {
    flex-direction: column;
    gap: 25px;
  }
  .progress-facts {
    border-left: 0;
    border-top: 1px solid var(--line);
    padding: 20px 0 0;
    flex-direction: row;
    justify-content: flex-start;
    flex-wrap: wrap;
  }
  .resource-row {
    flex-wrap: wrap;
  }
  .resource-status {
    margin-left: 41px;
  }
  .progress-day {
    flex-wrap: wrap;
  }
  .progress-day > .status-pill {
    margin-left: 50px;
  }
  .block-tabs {
    flex-wrap: wrap;
  }
  .section-heading {
    flex-wrap: wrap;
  }
  .course-filters {
    align-items: stretch;
  }
}
@media (max-width: 720px) {
  .portal-header {
    height: 84px;
    position: sticky;
    top: 0;
    gap: 12px;
    padding: 9px 16px;
  }
  .brand img {
    width: 162px;
  }
  .header-course {
    padding-left: 12px;
  }
  .header-course > span {
    font-size: 16px;
  }
  .header-course strong {
    font-size: 18px;
  }
  .mobile-menu {
    display: inline-flex;
    margin-left: auto;
  }
  .shell-body {
    display: block;
  }
  .course-sidebar {
    display: none;
    width: 100%;
    min-height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 20px;
  }
  .course-sidebar.is-open {
    display: block;
  }
  .sidebar-block {
    display: none;
  }
  .sidebar-heading {
    padding-bottom: 14px;
  }
  .sidebar-note {
    max-width: 100%;
  }
  .training-main {
    padding: 27px 18px;
  }
  .page-heading h1 {
    font-size: 35px;
  }
  .page-heading p {
    font-size: 19px;
  }
  .overview-ribbon {
    gap: 18px;
    padding: 20px 0;
  }
  .ribbon-item {
    min-width: 100%;
    flex-basis: 100%;
  }
  .ribbon-item strong {
    font-size: 20px;
  }
  .course-start-banner {
    padding: 20px;
    gap: 18px;
  }
  .course-start-banner .primary-button {
    width: 100%;
  }
  .notice {
    padding: 16px;
    gap: 11px;
  }
  .course-filters {
    gap: 12px;
  }
  .block-tabs {
    width: 100%;
    justify-content: space-between;
    flex-wrap: nowrap;
  }
  .block-tabs button {
    font-size: 18px;
    padding: 9px 10px;
  }
  .subject-filter,
  .search-field {
    flex-basis: 100%;
  }
  .day-card {
    padding: 17px;
    gap: 14px;
  }
  .day-number {
    width: 44px;
    height: 50px;
    font-size: 23px;
  }
  .day-card-topline {
    align-items: flex-start;
  }
  .day-card-topline .status-pill {
    font-size: 18px;
  }
  .day-card h3 {
    font-size: 22px;
    margin-top: 12px;
  }
  .day-arrow {
    display: none;
  }
  .day-topics p {
    font-size: 18px;
  }
  .section-heading h2 {
    font-size: 25px;
  }
  .subject-panel-heading {
    padding: 15px 18px;
  }
  .subject-items {
    padding: 0 18px;
  }
  .homework-box {
    padding: 20px;
  }
  .resource-row {
    padding: 18px;
    gap: 12px;
  }
  .resource-row > div {
    min-width: calc(100% - 42px);
  }
  .resource-status {
    margin-left: 37px;
    font-size: 16px;
  }
  .personal-section {
    padding: 20px;
  }
  .notes-meta {
    gap: 15px;
  }
  .save-error {
    padding: 12px;
  }
  .day-pagination {
    flex-wrap: wrap;
  }
  .day-pagination > a {
    flex: 1;
    min-width: 150px;
  }
  .training-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  .progress-summary {
    padding: 22px;
  }
  .progress-day {
    padding: 18px;
    gap: 12px;
  }
  .progress-day > .status-pill {
    margin-left: 44px;
  }
  .progress-day-detail {
    flex-basis: calc(100% - 45px);
  }
  .progress-facts {
    gap: 22px;
  }
  .portal-main {
    padding: 29px 18px 40px;
  }
  .auth-intro h1 {
    font-size: 35px;
  }
  .auth-intro p {
    font-size: 19px;
  }
  .auth-card {
    padding: 22px;
  }
  .portal-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding: 20px;
  }
  .admin-layout {
    padding: 26px 18px;
  }
  .admin-card {
    padding: 20px;
  }
  table {
    font-size: 18px;
  }
  .empty-state,
  .loading-panel {
    padding: 28px 20px;
  }
}
@media (max-width: 390px) {
  .header-course > span {
    display: none;
  }
  .brand img {
    width: 145px;
  }
  .header-course {
    border: 0;
    padding-left: 0;
  }
  .block-tabs button {
    padding: 9px 7px;
    font-size: 18px;
  }
  .day-card {
    gap: 11px;
  }
  .day-number {
    width: 38px;
    font-size: 21px;
  }
  .auth-card {
    padding: 19px;
  }
  .primary-button,
  .secondary-button {
    padding: 11px 16px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    transition: none !important;
  }
}

.exercise-count {
  font-size: 18px !important;
  font-weight: 800;
  color: var(--green-dark) !important;
}
.exercise-tabs {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin: 20px 0;
}
.exercise-tabs button {
  display: flex;
  flex-direction: column;
  text-align: left;
  gap: 3px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px 18px;
  color: var(--blue);
  font-size: 20px;
  font-weight: 800;
}
.exercise-tabs button span {
  font-size: 18px;
  font-weight: 700;
  color: var(--green);
}
.exercise-tabs button.selected {
  background: var(--pale-blue);
  border-color: var(--blue);
  box-shadow: inset 0 -3px var(--green);
}
.exercise-theory {
  padding: 22px;
  border-radius: 12px;
  background: var(--pale-blue);
  border: 1px solid #bed5e2;
  margin: 18px 0;
}
.exercise-theory h3 {
  margin-bottom: 14px;
}
.exercise-theory ol,
.exercise-solution ol {
  padding-left: 25px;
  margin-bottom: 0;
}
.exercise-theory li,
.exercise-solution li {
  padding-left: 4px;
  margin: 9px 0;
  font-size: 18px;
}
.exercise-question {
  background: white;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 22px;
  margin: 18px 0;
  overflow-wrap: anywhere;
}
.exercise-question-meta {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  font-size: 18px;
  color: var(--muted);
  margin-bottom: 16px;
}
.exercise-number {
  font-weight: 800;
  color: var(--green);
}
.solved-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--green-dark);
  margin-left: auto;
  font-size: 18px;
}
.exercise-context {
  white-space: pre-wrap;
  background: #f8fafb;
  padding: 18px;
  border-left: 3px solid #a5becb;
  margin-bottom: 17px;
  line-height: 1.7;
  font-size: 18px;
}
.exercise-question h4 {
  font-size: 21px;
  line-height: 1.5;
  margin-bottom: 18px;
  white-space: pre-wrap;
}
.answer-choices {
  padding: 0;
  margin: 18px 0;
  border: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
}
.answer-choices label {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  padding: 13px 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 18px;
}
.answer-choices label.selected {
  background: var(--pale-green);
  border-color: var(--green);
}
.answer-choices input {
  width: 20px;
  height: 20px;
  accent-color: var(--green);
  padding: 0;
  flex-shrink: 0;
}
.choice-letter {
  display: grid;
  place-items: center;
  background: var(--pale-blue);
  color: var(--blue);
  width: 29px;
  height: 29px;
  flex-shrink: 0;
  border-radius: 5px;
  font-weight: 800;
}
.exercise-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 18px;
}
.exercise-actions .save-indicator {
  font-size: 18px;
}
.exercise-question .save-error {
  margin: 18px 0;
}
.exercise-hint {
  margin-top: 20px;
  border-left: 3px solid var(--blue);
  padding: 15px 18px;
  background: var(--pale-blue);
  border-radius: 0 8px 8px 0;
}
.exercise-hint strong {
  color: var(--blue);
}
.exercise-hint p {
  margin: 8px 0 0;
}
.exercise-solution {
  margin-top: 20px;
  padding: 18px 20px;
  background: #f6f9fb;
  border: 1px solid #cedde5;
  border-radius: 9px;
}
.exercise-solution.correct {
  background: var(--pale-green);
  border-color: #bfdcc9;
}
.exercise-solution h4 {
  margin-bottom: 12px;
}
.exercise-solution .muted-text {
  margin-top: 15px;
}
.video-pending {
  background: white;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 20px;
}
.video-pending p:last-child {
  margin-bottom: 0;
}
.video-card {
  padding: 22px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  margin: 18px 0;
}
.video-card-header {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 18px;
}
.video-card-header > span {
  font-size: 18px;
  color: var(--green-dark);
  font-weight: 700;
}
.video-card video {
  width: 100%;
  aspect-ratio: 16/9;
  background: #f0f5f8;
  border-radius: 8px;
  display: block;
  margin: 15px 0;
}
.exercise-progress-summary {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  padding: 20px;
  background: var(--pale-green);
  border: 1px solid #bfdcc9;
  border-radius: 12px;
  margin: 24px 0;
}
.exercise-progress-summary strong {
  display: block;
  font-size: 28px;
  color: var(--green);
}
.exercise-progress-summary > div {
  flex: 1;
  min-width: 150px;
}
.exercise-progress-summary span {
  font-size: 18px;
}
.day-exercise-progress {
  font-size: 18px;
  color: var(--green-dark);
  font-weight: 700;
  margin: 10px 0;
}
.exercise-question[hidden],
[hidden] {
  display: none !important;
}
@media (max-width: 720px) {
  .exercise-question,
  .exercise-theory,
  .video-card {
    padding: 18px;
  }
  .exercise-tabs button {
    flex: 1;
    min-width: 135px;
    padding: 12px 14px;
  }
  .exercise-actions > .primary-button,
  .exercise-actions > .secondary-button {
    flex: 1;
    min-width: 150px;
  }
  .answer-choices label {
    padding: 12px;
    gap: 9px;
  }
  .solved-label {
    margin-left: 0;
  }
  .exercise-question h4 {
    font-size: 21px;
  }
  .exercise-solution {
    padding: 16px;
  }
  .video-card-header h3 {
    font-size: 22px;
  }
}
