.module-showcase,
.module-news,
.learning-module__grid {
  width: min(100%, 1100px);
  margin-inline: auto;
}

.learning-module--wide .module-showcase,
.learning-module--wide .module-news,
.learning-module--wide .learning-module__grid {
  width: min(100%, 1320px);
}

.module-showcase {
  --module-showcase-panel-color: #1854a5;
  --module-showcase-label-color: #3478c1;
  --module-showcase-panel-overlay: rgba(24, 84, 165, 0.88);
  --module-showcase-panel-hover: #004a6a;
  --module-showcase-surface-color: #eff0f1;
  --module-showcase-text-color: #0b1724;
  --module-showcase-stat-bg: #f8fbfd;
  --module-showcase-stat-border: #d6e3ef;
  --module-showcase-stat-accent: #008cad;
  display: grid;
  grid-template-columns: 1fr;
  align-items: stretch;
  min-height: 0;
  margin-top: 28px;
}

.module-showcase--red {
  --module-showcase-panel-color: #b50f1f;
  --module-showcase-label-color: #910f18;
  --module-showcase-panel-overlay: rgba(181, 15, 31, 0.88);
  --module-showcase-panel-hover: #7f0c16;
}

.module-showcase--blue {
  --module-showcase-panel-color: #1854a5;
  --module-showcase-label-color: #3478c1;
  --module-showcase-panel-overlay: rgba(24, 84, 165, 0.88);
  --module-showcase-panel-hover: #004a6a;
}

.module-showcase--teal {
  --module-showcase-panel-color: #0092bf;
  --module-showcase-label-color: #0c6d84;
  --module-showcase-panel-overlay: rgba(0, 146, 191, 0.88);
  --module-showcase-panel-hover: #004a6a;
}

.module-showcase--brown {
  --module-showcase-panel-color: #6f4a12;
  --module-showcase-label-color: #9a6a1f;
  --module-showcase-panel-overlay: rgba(111, 74, 18, 0.88);
  --module-showcase-panel-hover: #51350c;
}

.module-showcase--green {
  --module-showcase-panel-color: #1f6f4a;
  --module-showcase-label-color: #2f8f62;
  --module-showcase-panel-overlay: rgba(31, 111, 74, 0.88);
  --module-showcase-panel-hover: #155237;
}

.module-showcase--purple {
  --module-showcase-panel-color: #5d3b8c;
  --module-showcase-label-color: #7754a6;
  --module-showcase-panel-overlay: rgba(93, 59, 140, 0.88);
  --module-showcase-panel-hover: #43286d;
}

.module-showcase--slate {
  --module-showcase-panel-color: #31465f;
  --module-showcase-label-color: #536f8e;
  --module-showcase-panel-overlay: rgba(49, 70, 95, 0.88);
  --module-showcase-panel-hover: #243346;
}

.module-showcase__stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  align-self: stretch;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(247, 251, 253, 0.98) 100%);
  border: 1px solid rgba(33, 77, 101, 0.12);
  border-radius: 8px;
  box-shadow: 0 16px 34px rgba(16, 48, 82, 0.055);
}

.module-showcase__stat {
  position: relative;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  align-items: center;
  column-gap: 22px;
  min-width: 0;
  min-height: 118px;
  padding: 24px 34px;
  color: #001b3f;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  text-align: left;
}

.module-showcase__stat::before {
  position: absolute;
  top: 28px;
  bottom: 28px;
  left: -1px;
  width: 1px;
  height: auto;
  background: linear-gradient(180deg, transparent, rgba(67, 102, 121, 0.18), transparent);
  border-radius: 999px;
  content: "";
  opacity: 1;
}

.module-showcase__stat-icon {
  display: block;
  grid-column: 1;
  grid-row: 1 / span 2;
  width: 58px;
  height: 58px;
  color: #2d8194;
  background: transparent;
  border: 0;
  border-radius: 0;
  object-fit: contain;
}

i.module-showcase__stat-icon {
  display: grid;
  place-items: center;
  font-size: 2.25rem;
}

.module-showcase__stat:first-child::before {
  opacity: 0;
}

.module-showcase__stat-label {
  display: inline-flex;
  grid-column: 2;
  grid-row: 1;
  align-items: center;
  justify-content: flex-start;
  min-height: auto;
  padding: 0;
  color: #23364f;
  background: transparent;
  font-size: 0.76rem;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.module-showcase__stat-value {
  display: inline-flex;
  grid-column: 2;
  grid-row: 2;
  align-items: center;
  justify-content: flex-start;
  color: #061f45;
  font-family: "Noto Sans", system-ui, sans-serif;
  font-size: clamp(2rem, 2.8vw, 2.8rem);
  font-weight: 900;
  line-height: 0.92;
}

.module-showcase__highlight {
  display: none;
  position: relative;
  /*grid-template-rows: minmax(0, 1fr) 40px;*/
  min-width: 0;
  color: #ffffff;
  background: transparent;
}

.module-showcase__highlight::before {
  position: absolute;
  top: 18px;
  left: -26px;
  width: 54px;
  height: 54px;
  background: var(--module-showcase-label-color);
  clip-path: polygon(100% 0, 0 100%, 100% 100%);
  content: "";
}

.module-showcase__highlight-content {
  position: relative;
  z-index: 1;
  display: grid;
  align-content: start;
  min-height: 160px;
  padding: 14px 18px 12px 18px;
  background: var(--module-showcase-panel-color);
}

.module-showcase__highlight-text {
  margin: 0;
  color: #ffffff;
  font-size: 0.90rem;
  font-weight: 500;
  line-height: 1.18;
}

.module-showcase__highlight-footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  min-height: 40px;
  padding-left: 4px;
  background: var(--module-showcase-surface-color);
}

.module-showcase__highlight-title {
  margin: 0;
  color: #0b0b0b;
  font-size: clamp(1.45rem, 3vw, 2rem);
  font-weight: 800;
  line-height: 1;
  text-align: left;
}

.module-showcase__highlight-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 6px 18px;
  color: #ffffff;
  background: var(--module-showcase-label-color);
  border: 1px solid var(--module-showcase-label-color);
  border-radius: 0 0 8px 0;
  font-weight: 800;
  font-size: 0.82rem;
  text-decoration: none;
}

.module-showcase__highlight-action:hover,
.module-showcase__highlight-action:focus-visible {
  color: #ffffff;
  background: var(--module-showcase-panel-hover);
  border-color: var(--module-showcase-panel-hover);
}

.module-showcase__highlight-action:focus-visible {
  outline: 3px solid #f6c343;
  outline-offset: 2px;
}

.module-news {
  --module-news-color: var(--module-showcase-panel-color, #1854a5);
  --module-news-label-color: var(--module-showcase-label-color, #3478c1);
  --module-news-gap: 18px;
  --module-news-per-view: 3;
  margin-top: 18px;
  padding: 18px;
  background: #ffffff;
  border: 1px solid rgba(20, 35, 58, 0.08);
  border-radius: 10px;
  box-shadow: 0 18px 42px rgba(25, 53, 82, 0.08);
}

.module-news--red {
  --module-news-color: #b50f1f;
  --module-news-label-color: #910f18;
}

.module-news--blue {
  --module-news-color: #1854a5;
  --module-news-label-color: #3478c1;
}

.module-news--teal {
  --module-news-color: #0092bf;
  --module-news-label-color: #0c6d84;
}

.module-news--brown {
  --module-news-color: #6f4a12;
  --module-news-label-color: #9a6a1f;
}

.module-news--green {
  --module-news-color: #1f6f4a;
  --module-news-label-color: #2f8f62;
}

.module-news--purple {
  --module-news-color: #5d3b8c;
  --module-news-label-color: #7754a6;
}

.module-news--slate {
  --module-news-color: #31465f;
  --module-news-label-color: #536f8e;
}

.module-news__header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(20, 35, 58, 0.08);
}

.module-news__eyebrow,
.module-news__title {
  margin: 0;
}

.module-news__eyebrow {
  color: var(--module-news-label-color);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.module-news__title {
  margin-top: 4px;
  color: #14233a;
  font-size: clamp(1.28rem, 2.4vw, 1.7rem);
  font-weight: 800;
  line-height: 1.16;
}

.module-news__all-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  flex: 0 0 auto;
  padding: 8px 14px;
  color: #ffffff;
  background: var(--module-news-color);
  border: 1px solid var(--module-news-color);
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 800;
  text-decoration: none;
}

.module-news__all-link:hover,
.module-news__all-link:focus-visible {
  color: #ffffff;
  background: #004a6a;
  border-color: #004a6a;
}

.module-news__all-link:focus-visible,
.module-news__control:focus-visible,
.module-news .home-news__mini-link:focus-visible {
  outline: 3px solid #f6c343;
  outline-offset: 3px;
}

.module-news__carousel {
  overflow: hidden;
}

.module-news__viewport {
  overflow: hidden;
  padding: 2px;
}

.module-news__track {
  display: flex;
  gap: var(--module-news-gap);
  transition: transform 260ms ease;
  will-change: transform;
}

.module-news__card {
  flex: 0 0 calc((100% - (var(--module-news-gap) * (var(--module-news-per-view) - 1))) / var(--module-news-per-view));
  min-width: 0;
}

.module-news__footer {
  display: flex;
  justify-content: center;
  margin-top: 16px;
}

.module-news__controls {
  display: inline-flex;
  gap: 8px;
}

.module-news__control {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  color: var(--module-news-color);
  background: #f4f8fb;
  border: 1px solid rgba(24, 84, 165, 0.14);
  border-radius: 10px;
  cursor: pointer;
  transition: color 180ms ease, background 180ms ease, border-color 180ms ease;
}

.module-news__control:hover,
.module-news__control:focus-visible {
  color: #ffffff;
  background: var(--module-news-color);
  border-color: var(--module-news-color);
}

.module-news__control:disabled {
  opacity: 0.42;
  cursor: not-allowed;
}

.module-news__control svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.learning-module__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  margin-top: 18px;
}

.learning-module__card {
  position: relative;
  display: grid;
  min-height: 560px;
  overflow: hidden;
  color: #ffffff;
  background: #122744;
  border-radius: 8px;
  box-shadow: 0 18px 34px rgba(18, 39, 68, 0.12);
  transition: box-shadow 220ms ease, transform 220ms ease;
}

.learning-module__card::before {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(5, 22, 40, 0.68) 0%, rgba(5, 22, 40, 0.16) 42%, rgba(5, 22, 40, 0.82) 100%),
    linear-gradient(135deg, rgba(25, 75, 147, 0.28), rgba(0, 146, 191, 0.12));
  content: "";
  pointer-events: none;
}

.learning-module__card::after {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  color: #122744;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 50%;
  box-shadow: 0 8px 18px rgba(3, 18, 34, 0.24);
  content: "+";
  font-size: 1.45rem;
  font-weight: 500;
  line-height: 1;
  pointer-events: none;
  transition: opacity 180ms ease, transform 220ms ease;
}

.learning-module__card:hover,
.learning-module__card:focus-within {
  box-shadow: 0 22px 42px rgba(18, 39, 68, 0.16);
  transform: translateY(-4px);
}

.learning-module__card:hover::after,
.learning-module__card:focus-within::after {
  opacity: 0;
  transform: translateY(-5px) rotate(45deg);
}

.learning-module__card:focus-visible {
  outline: 3px solid #f6c343;
  outline-offset: 3px;
}

.learning-module__card-image {
  grid-column: 1;
  grid-row: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: filter 240ms ease, transform 420ms ease;
}

.learning-module__card:hover .learning-module__card-image,
.learning-module__card:focus-within .learning-module__card-image {
  filter: saturate(1.04) contrast(1.02);
  transform: scale(1.012);
}

.learning-module__summary {
  position: absolute;
  top: 28px;
  right: 22px;
  bottom: 20px;
  left: 22px;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  color: #ffffff;
  text-align: left;
  transition: opacity 220ms ease, transform 220ms ease;
}

.learning-module__card:hover .learning-module__summary,
.learning-module__card:focus-within .learning-module__summary {
  opacity: 0.16;
  transform: translateY(4px);
}

.learning-module__eyebrow,
.learning-module__summary-title,
.learning-module__summary-tags {
  margin: 0;
}

.learning-module__summary-heading {
  display: grid;
  gap: 12px;
  width: 100%;
  margin-block: auto;
}

.learning-module__eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 20px;
  padding: 8px;
  color: #ffffff;
  background: rgba(25, 75, 147, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 6px;
  font-size: 0.92rem;
  font-weight: 500;
  line-height: 1;
  text-transform: uppercase;
}

.learning-module__summary-title {
  color: #ffffff;
  font-size: clamp(1.35rem, 2.2vw, 1.7rem);
  font-weight: 900;
  line-height: 1.04;
  letter-spacing: 0;
  text-shadow: 0 8px 22px rgba(0, 0, 0, 0.34);
}

.learning-module__summary-title span {
  display: block;
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.66em;
  font-weight: 800;
}

.learning-module__summary-value {
  display: flex;
  align-items: end;
  gap: 10px;
}

.learning-module__summary-value strong {
  display: block;
  color: #ffffff;
  font-family: "Noto Sans", system-ui, sans-serif;
  font-size: clamp(2.75rem, 5.6vw, 4.1rem);
  font-weight: 900;
  line-height: 0.82;
  text-shadow: 0 10px 24px rgba(0, 0, 0, 0.28);
}

.learning-module__summary-value small {
  display: block;
  padding-bottom: 6px;
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.9rem;
  font-weight: 800;
  line-height: 1.1;
}

.learning-module__summary-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 0;
}

.learning-module__summary-tags span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 0 10px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 800;
}

.learning-module__overlay {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  align-content: center;
  gap: 10px;
  padding: 26px;
  color: #ffffff;
  background:
    linear-gradient(180deg, rgba(3, 18, 34, 0.34) 0%, rgba(0, 54, 82, 0.70) 100%),
    rgba(0, 31, 54, 0.32);
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
  opacity: 0;
  pointer-events: none;
  transform: translateY(6px);
  transition: opacity 220ms ease, transform 220ms ease;
}

.learning-module__card:hover .learning-module__overlay,
.learning-module__card:focus-within .learning-module__overlay {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.learning-module__overlay h3 {
  margin: 0 0 10px;
  color: #ffffff;
  font-size: clamp(1.18rem, 1.8vw, 1.42rem);
  font-weight: 900;
  line-height: 1.1;
  text-shadow: 0 8px 20px rgba(0, 0, 0, 0.34);
}

.learning-module__overlay a {
  display: inline-flex;
  align-items: center;
  width: min(100%, 320px);
  min-height: 42px;
  padding: 0 12px;
  color: #122744;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 6px;
  text-decoration: none;
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.1;
  transition: color 160ms ease, background 160ms ease, border-color 160ms ease;
}

.learning-module__overlay a::before {
  width: 7px;
  height: 7px;
  margin-right: 8px;
  background: currentColor;
  border-radius: 50%;
  content: "";
}

.learning-module__overlay a:hover,
.learning-module__overlay a:focus-visible {
  color: #ffffff;
  background: #194b93;
  border-color: #194b93;
}

.learning-module__overlay a:focus-visible {
  outline: 3px solid #f6c343;
  outline-offset: 2px;
}

@media (max-width: 991.98px) {
  .module-news {
    --module-news-per-view: 2;
  }

  .learning-module__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767.98px) {
  .module-showcase__stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .module-showcase__stat {
    grid-template-columns: 46px minmax(0, 1fr);
    column-gap: 14px;
    min-height: 102px;
    padding: 18px;
  }

  .module-showcase__stat-icon {
    width: 46px;
    height: 46px;
  }

  .module-showcase__stat-value {
    font-size: clamp(1.7rem, 7vw, 2.25rem);
  }

  .module-news {
    padding: 15px;
  }

  .module-news__header {
    align-items: flex-start;
    flex-direction: column;
  }

  .module-news__all-link {
    width: 100%;
  }

  .learning-module__grid {
    grid-template-columns: 1fr;
  }

  .learning-module__card {
    min-height: auto;
    background: #004a6a;
    box-shadow: 0 10px 24px rgba(18, 39, 68, 0.12);
  }

  .learning-module__card::before,
  .learning-module__card::after,
  .learning-module__card-image,
  .learning-module__summary {
    display: none;
  }

  .learning-module__card:hover,
  .learning-module__card:focus-within {
    transform: none;
  }

  .learning-module__overlay {
    position: relative;
    inset: auto;
    align-content: end;
    gap: 8px;
    padding: 18px;
    background: #004a6a;
    border: 0;
    border-radius: 0;
    opacity: 1;
    pointer-events: auto;
    transform: none;
  }

  .learning-module__overlay h3 {
    margin-bottom: 6px;
    font-size: 1.18rem;
  }

  .learning-module__overlay a {
    width: 100%;
    min-height: 40px;
  }
}

@media (max-width: 575.98px) {
  .module-news {
    --module-news-per-view: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .module-news__track,
  .module-news .home-news__mini img,
  .module-news .home-news__mini-link,
  .module-news__control,
  .learning-module__card,
  .learning-module__card-image,
  .learning-module__summary,
  .learning-module__overlay,
  .learning-module__overlay a {
    transition-duration: 0.01ms;
  }
}
