/* V2 homepage: dedicated components and responsive states. */
.portal-module,
.lead-tabs,
.module-feature {
  min-width: 0;
}

.module-head__tabs {
  flex: 1 1 auto;
  min-width: 0;
}

.module-tab {
  padding: 7px 9px;
  border: 0;
  background: transparent;
  color: var(--color-muted);
  font-family: inherit;
  font-size: 13px;
  line-height: 1.4;
  white-space: nowrap;
  cursor: pointer;
  transition: color 0.18s ease;
}

.module-feature__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.module-feature h3 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.module-feature p {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@media (max-width: 767px) {
  .module-head__tabs {
    order: 3;
    width: 100%;
  }
}

.home-main {
  min-width: 0;
}

.home-sidebar {
  min-width: 0;
}

.home-lead {
  display: grid;
  grid-template-columns: 340px 340px;
  gap: 20px;
}

.legacy-slider {
  position: relative;
  width: 340px;
  aspect-ratio: 340/230;
  overflow: hidden;
  border-radius: var(--radius-md);
  background: #102a3a;
}

.legacy-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
}

.legacy-slide.is-active {
  opacity: 1;
  pointer-events: auto;
}

.legacy-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.legacy-slide__caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 28px 14px 12px;
  background: linear-gradient(transparent, rgba(4, 27, 42, 0.92));
  color: #fff;
  font-size: 15px;
  font-weight: 650;
  line-height: 1.4;
}

.slider-dots {
  position: absolute;
  right: 10px;
  top: 10px;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 5px;
}

.slider-dot {
  display: block;
  flex: 0 0 9px;
  width: 9px;
  min-width: 9px;
  max-width: 9px;
  height: 9px;
  min-height: 9px;
  max-height: 9px;
  aspect-ratio: 1/1;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.85);
  border-radius: 50%;
  background: rgba(9, 45, 67, 0.38);
  line-height: 0;
  cursor: pointer;
  transition:
    transform 0.18s ease,
    background-color 0.18s ease;
}

.slider-dot:hover {
  transform: scale(1.3);
}

.slider-dot.is-active {
  background: #fff;
  box-shadow: 0 0 0 2px rgba(5, 104, 168, 0.35);
}

.lead-tabs {
  height: 100%;
  overflow: hidden;
}

.compact-tabs {
  display: flex;
  height: 36px;
  border: 1px solid var(--color-border);
  border-bottom: 0;
  background: var(--color-bg-soft);
}

.compact-tab {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
  min-width: 0;
  padding: 7px 4px;
  border-bottom: 2px solid transparent;
  color: var(--color-muted);
  font-size: 14px;
  text-align: center;
  cursor: pointer;
}

.compact-tab[aria-selected="true"] {
  border-bottom-color: var(--color-primary);
  background: #fff;
  color: var(--color-primary);
  font-weight: 700;
}

.lead-tabs .news-list a {
  padding: 8px 0;
  font-size: 14px;
}

.module-pair {
  display: grid;
  grid-template-columns: 340px 340px;
  gap: 20px;
  margin-top: 14px;
}

.portal-module {
  min-height: 315px;
  overflow: hidden;
  border: 1px solid #e8edf2;
  border-radius: var(--radius-md);
  background: #fff;
}

.module-head {
  display: flex;
  align-items: center;
  height: 46px;
  border-bottom: 1px solid #e8edf2;
  background: #fff;
  border-radius: var(--radius-md) var(--radius-md) 0 0;
}

.module-head h2 {
  position: relative;
  flex: 0 0 auto;
  padding: 0 12px 0 24px;
  color: var(--color-heading);
  font-size: 18px;
  white-space: nowrap;
}

.module-head h2::before {
  content: "";
  position: absolute;
  left: 12px;
  top: 50%;
  width: 4px;
  height: 16px;
  transform: translateY(-50%);
  border-radius: 2px;
  background: var(--color-primary);
}

.module-head__tabs {
  display: flex;
  min-width: 0;
  overflow: auto;
}

.module-head__tabs a {
  padding: 7px 9px;
  color: var(--color-muted);
  font-size: 13px;
  white-space: nowrap;
}

.module-head__tabs a:hover {
  color: var(--color-primary);
}

.module-head .section-more {
  margin-left: auto;
  padding-right: 10px;
}

.module-feature {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 10px;
  margin-top: 10px;
  padding-inline: 12px;
}

.module-feature .media {
  height: 100px;
  border-radius: var(--radius-sm);
}

.module-feature h3 {
  font-size: 15px;
  line-height: 1.4;
  transition: color 0.18s ease;
}

.module-feature:hover h3 {
  color: var(--color-primary);
}

.module-feature h3 a:hover {
  color: var(--color-primary);
}

.module-feature p {
  display: -webkit-box;
  margin-top: 5px;
  color: var(--color-muted);
  font-size: 12px;
  line-height: 1.5;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.portal-module .news-list {
  padding-inline: 12px;
}

.portal-module .news-list a {
  padding: 6px 0;
  font-size: 14px;
}

.lead-tabs {
  padding: 0 18px 10px;
  border: 1px solid #e8edf2;
  border-radius: var(--radius-md);
  background: #fff;
  box-shadow: var(--shadow-xs);
}

.compact-tabs {
  height: 52px;
  margin: 0 -18px 4px;
  padding: 0 12px;
  border: 0;
  border-bottom: 1px solid #e8edf2;
  background: #fff;
  border-radius: var(--radius-md) var(--radius-md) 0 0;
}

.compact-tab {
  position: relative;
  padding: 15px 6px 13px;
  border: 0;
  background: transparent;
  color: #475569;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.02em;
  transition: color 0.18s ease;
}

.compact-tab::after {
  content: "";
  position: absolute;
  left: 50%;
  width: 22px;
  margin-left: -11px;
  bottom: -1px;
  height: 3px;
  border-radius: 2px;
  background: var(--color-primary);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.22s ease;
}

.compact-tab:hover {
  color: var(--color-primary);
  background: transparent;
}

.compact-tab:focus-visible {
  outline-offset: -3px;
}

.compact-tab[aria-selected="true"] {
  background: transparent;
  color: var(--color-primary);
  font-weight: 700;
}

.compact-tab[aria-selected="true"]::after {
  transform: scaleX(1);
}

.lead-tabs .news-list a {
  padding: 9px 2px;
}

.lead-tabs .news-list li:last-child {
  border-bottom: 0;
}

@media (max-width: 1039px) {
  .home-lead,
  .module-pair {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
  }
}

@media (max-width: 1039px) {
  .legacy-slider {
    width: 100%;
  }
}

@media (max-width: 1039px) {
  .portal-module {
    height: auto;
    min-height: 315px;
  }
}

@media (max-width: 767px) {
  .home-lead {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 767px) {
  .legacy-slider {
    aspect-ratio: 340/230;
  }
}

@media (max-width: 767px) {
  .lead-tabs {
    height: auto;
    padding-inline: 14px;
  }
}

@media (max-width: 767px) {
  .compact-tabs {
    margin-inline: -14px;
    overflow-x: auto;
  }
}

@media (max-width: 767px) {
  .module-pair {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 767px) {
  .portal-module {
    min-height: 0;
    height: auto;
  }
}

@media (max-width: 767px) {
  .home-sidebar {
    margin-top: 10px;
  }
}

@media (max-width: 420px) {
  .module-feature {
    grid-template-columns: 110px 1fr;
  }
}

@media (max-width: 420px) {
  .module-feature .media {
    height: 82px;
  }
}

@media (min-width: 1320px) {
  .home-lead,
  .module-pair {
    grid-template-columns: 436px 436px;
    gap: 24px;
  }
}

@media (min-width: 1320px) {
  .legacy-slider {
    width: 436px;
  }
}

@media (min-width: 768px) and (max-width: 1319px) {
  .home-lead,
  .module-pair {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
  }
}

@media (min-width: 768px) and (max-width: 1319px) {
  .legacy-slider {
    width: 100%;
  }
}

@media (min-width: 768px) and (max-width: 1319px) {
  .portal-module {
    height: auto;
    min-height: 315px;
  }
}

@media (max-width: 767px) {
  .home-lead,
  .module-pair {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 767px) {
  .module-head {
    height: auto;
    min-height: 46px;
    padding-block: 8px;
  }
}

@media (max-width: 767px) {
  .module-head__tabs {
    flex-basis: 100%;
  }
}

@media (max-width: 767px) {
  .legacy-slider {
    max-width: 100%;
  }
}

@media (min-width: 768px) and (max-width: 900px) {
  .home-lead {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 768px) and (max-width: 900px) {
  .lead-tabs {
    height: auto;
  }
}

.lead-tabs {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.compact-tabs {
  position: relative;
  height: 54px;
  margin: 0 0 4px;
  padding: 0;
  border: 0;
  border-bottom: 1px solid #eef2f5;
  background: transparent;
  border-radius: 0;
}

.compact-tab {
  padding: 16px 6px 14px;
  color: #5b6b7a;
  font-size: clamp(14px, 1.05vw, 16px);
  font-weight: 500;
  letter-spacing: 0.02em;
}

.compact-tab:hover {
  color: var(--color-primary);
}

.compact-tab[aria-selected="true"] {
  color: var(--color-primary);
  font-weight: 700;
}

.lead-tabs .news-list {
  margin-top: 6px;
}

.lead-tabs .news-list a {
  padding: 12px 0;
  font-size: clamp(14px, 1.05vw, 15.5px);
}

@keyframes v2fade {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.compact-tabs,
.module-head__tabs {
  scrollbar-width: none;
}

.compact-tabs::-webkit-scrollbar,
.module-head__tabs::-webkit-scrollbar {
  display: none;
}

.module-pair {
  margin-top: 26px;
}

.portal-module {
  height: auto;
  min-height: 315px;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.module-head {
  height: auto;
  min-height: 44px;
  border-bottom: 0;
  background: transparent;
  border-radius: 0;
}

.module-head h2 {
  padding: 0 12px 0 15px;
  font-size: clamp(19px, 1.5vw, 22px);
}

.module-head h2::before {
  left: 0;
  height: 18px;
}

.module-head__tabs {
  position: relative;
  align-items: center;
}

.module-tab {
  position: relative;
  padding: 7px 9px;
  border: 0;
  background: transparent;
  color: var(--color-muted);
  font-size: clamp(13px, 1vw, 14px);
  white-space: nowrap;
  cursor: pointer;
  transition: color 0.18s ease;
}

.module-tab:hover {
  color: var(--color-primary);
}

.module-tab:focus-visible {
  outline-offset: 2px;
}

.module-tab[aria-selected="true"] {
  color: var(--color-primary);
  font-weight: 700;
}

.module-feature {
  gap: 14px;
  margin-bottom: 14px;
  padding-inline: 0;
}

.module-feature .media {
  height: 108px;
}

.module-feature h3 {
  font-size: clamp(16px, 1.25vw, 18px);
  font-weight: 650;
}

.module-feature p {
  font-size: 13px;
  margin-top: 6px;
}

.portal-module .news-list {
  padding-inline: 0;
}

.portal-module .news-list a {
  font-size: clamp(14px, 1.05vw, 15px);
}

.legacy-slider {
  border-radius: 10px;
}

.legacy-slide__caption {
  background: linear-gradient(transparent, rgba(4, 27, 42, 0.85));
}

@media (max-width: 767px) {
  .lead-tabs {
    padding: 0;
  }
}

@media (max-width: 767px) {
  .compact-tabs {
    margin-inline: 0;
    overflow-x: auto;
  }
}

@media (max-width: 767px) {
  .module-pair {
    margin-top: 22px;
  }
}

@media (max-width: 767px) {
  .portal-module {
    min-height: 0;
  }
}

.tabs-indicator {
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 0;
  height: 3px;
  border-radius: 2px;
  background: var(--color-primary);
  pointer-events: none;
  transition:
    left 0.25s ease,
    width 0.25s ease;
  z-index: 2;
}

.module-head__tabs .tabs-indicator {
  bottom: 0;
  height: 2px;
}

.slider-arrow {
  position: absolute;
  top: 50%;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  transform: translateY(-50%);
  border-radius: 50%;
  background: rgba(9, 45, 67, 0.38);
  color: #fff;
  cursor: pointer;
  transition:
    background-color 0.2s ease,
    transform 0.2s ease;
}

.slider-arrow svg {
  width: 16px;
  height: 16px;
}

.slider-arrow--prev {
  left: 10px;
}

.slider-arrow--next {
  right: 10px;
}

.slider-arrow:hover {
  background: rgba(9, 45, 67, 0.62);
}

.slider-arrow:active {
  transform: translateY(-50%) scale(0.92);
}

.slider-arrow:focus-visible {
  outline-color: rgba(255, 255, 255, 0.85);
  outline-offset: 2px;
}

.module-head {
  justify-content: space-between;
}

.module-head h2 {
  flex: 0 0 auto;
}

.module-head__tabs {
  flex: 1 1 auto;
}

.module-more {
  flex: 0 0 auto;
  margin-left: auto;
  padding: 8px 0;
  font-size: 13px;
  color: var(--color-muted);
  white-space: nowrap;
  transition: color 0.18s ease;
}

.module-more:hover {
  color: var(--color-primary);
}

.module-pair .portal-module {
  min-height: 315px;
}

.module-feature .module-feature__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.module-feature p {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@media (max-width: 767px) {
  .module-head {
    flex-wrap: wrap;
    gap: 4px 12px;
  }
}

@media (max-width: 767px) {
  .module-head__tabs {
    order: 3;
    width: 100%;
    max-width: none;
  }
}

@media (max-width: 767px) {
  .module-more {
    order: 2;
  }
}

/* Six static activity banners, aligned with the shared main/sidebar tracks. */
.activities {
  margin-block: 12px 16px;
}
.activities__viewport {
  display: grid;
  gap: 12px;
}
.activity-group {
  display: grid;
  grid-template-columns: 700px 280px;
  gap: 20px;
}
.activity-pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  min-width: 0;
}
.activity-card {
  display: block;
  height: 140px;
  min-width: 0;
  overflow: hidden;
  border-radius: 8px;
  background: #123652;
}
.activity-card img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: fill;
}
@media (min-width: 1320px) {
  .activity-group {
    grid-template-columns: 896px 358px;
    gap: 26px;
  }
  .activity-pair {
    gap: 24px;
  }
}
@media (min-width: 768px) and (max-width: 1319px) {
  .activity-group {
    grid-template-columns: minmax(0, 7fr) minmax(250px, 2.8fr);
    gap: 18px;
  }
  .activity-pair {
    gap: 18px;
  }
}
@media (max-width: 767px) {
  .activity-group {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
  }
  .activity-pair {
    display: contents;
  }
  .activity-card {
    height: auto;
    aspect-ratio: 326 / 80;
  }
  .activities__viewport {
    gap: 6px;
  }
}

.legacy-slider {
  width: 100%;
  min-width: 0;
  max-width: 100%;
}

/* Restore left image / right title and summary. */
.module-feature {
  grid-template-columns: minmax(0, 140px) minmax(0, 1fr);
  align-items: start;
  row-gap: 10px;
}
.module-feature .module-feature__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  max-height: 108px;
  overflow: hidden;
}
.module-feature .module-feature__body h3 {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  flex-shrink: 0;
  max-height: none;
  min-height: 0;
  overflow: hidden;
  white-space: normal;
  overflow-wrap: anywhere;
  line-height: 1.35;
}
.module-feature .module-feature__body p {
  margin: 6px 0 0;
  flex-shrink: 0;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  line-height: 2em;
  max-height: 4em;
  overflow: hidden;
}

@media (max-width: 767px) {
  .module-feature { grid-template-columns: 110px minmax(0, 1fr); }
}
