/**
 * Knowledge Hub Page Styles
 * Desktop-first responsive design
 */

/* ============================================
   SECTION 1: Cover + Tabs (shared cover structure)
   ============================================ */

.knowledge-hub .privacy-cover-frame__content {
  height: 100%;
  display: flex;
  flex-direction: column;
}

.kh-cover__content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 60px;
  flex: 1 1 auto;
  padding: 0 24px;
}

.kh-cover__title {
  margin: 0;
}

.knowledge-hub .privacy-cover-frame h1.kh-cover__title {
  font-size: 82px;
  line-height: 0.95;
  letter-spacing: -4px;
}

.kh-cover__subtitle {
  color: rgba(255, 255, 255, 0.78);
  font-family: 'Mont', sans-serif;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  max-width: 330px;
  margin: 0;
  line-height: 1.55;
  letter-spacing: 0.04em;
}

.kh-cover__tabs {
  display: flex;
  gap: 30px;
  flex-wrap: wrap;
  align-items: center;
  min-height: 50px;
  padding: 0 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

.kh-filters__tab {
  font-family: 'Mont', sans-serif;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: color 0.3s ease;
  padding: 0;
}

.kh-filters__tab.active,
.kh-filters__tab:hover {
  color: var(--color-primary);
}

.kh-filters__icon {
  width: 8px;
  height: 8px;
  border: 1px solid rgba(255, 255, 255, 0.65);
  background: transparent;
  display: inline-block;
  flex-shrink: 0;
}

.kh-filters__tab.active .kh-filters__icon {
  border-color: var(--color-primary);
  background: var(--color-primary);
}

/* ============================================
   SECTION 3: Featured Posts
   ============================================ */

.kh-featured {
  background: #EEF2F2;
  padding: 40px 0 0;
}

.kh-featured__grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 20px;
}

/* Featured Article Card (Left - Teal background) */
.kh-card--featured-article {
  background: var(--color-primary);
  border-radius: 16px;
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 40px;
  transition: transform 0.3s ease;
}

.kh-card--featured-article:hover {
  transform: translateY(-4px);
}

.kh-card--featured-article .kh-card__image {
  position: relative;
  overflow: hidden;
  flex: 0 0 47%;
}

.kh-card--featured-article .kh-card__image img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: 14px;
}

.kh-card--featured-article .kh-card__content {
  padding: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  flex: 1 1 auto;
}

.kh-card--featured-article .kh-card__meta {
  display: flex;
  gap: 16px;
  margin-bottom: 24px;
}

.kh-card--featured-article .kh-card__date,
.kh-card--featured-article .kh-card__category {
  font-family: 'Mont', sans-serif;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: #FFFFFF;
  opacity: 0.9;
}

.kh-card--featured-article .kh-card__title {
  font-family: 'Mont', sans-serif;
  font-size: 28px;
  font-weight: 700;
  color: #FFFFFF;
  line-height: 1.2;
  margin-bottom: 14px;
}

.kh-card--featured-article .kh-card__excerpt {
  font-family: 'Mont', sans-serif;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.6;
  margin-bottom: 18px;
}

.kh-card--featured-article .kh-card__link {
  font-family: 'Mont', sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: #FFFFFF;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  transition: gap 0.3s ease;
}

.kh-card--featured-article .kh-card__link:hover {
  gap: 12px;
}

.kh-card--featured-article .kh-card__arrow {
  font-size: 16px;
}

/* Featured Video Card (Right - Orange background) */
.kh-card--featured-video {
  background: var(--cta-accent);
  border-radius: 16px;
  min-height: 100%;
  overflow: hidden;
  transition: transform 0.3s ease;
}

.kh-card--featured-video:hover {
  transform: translateY(-4px);
}

.kh-card--featured-video .kh-card__play {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cta-accent);
  transition: transform 0.3s ease, background 0.3s ease;
  align-self: flex-end;
  margin-top: auto;
}

.kh-card--featured-video .kh-card__image {
  padding: 24px 24px 0;
}

.kh-card--featured-video .kh-card__thumb {
  position: relative;
}

.kh-card--featured-video .kh-card__thumb img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
  border-radius: 14px;
}

.kh-card--featured-video .kh-card__play:hover {
  transform: scale(1.1);
  background: #FFFFFF;
}

.kh-card--featured-video .kh-card__content {
  padding: 28px 40px 40px;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.kh-card--featured-video .kh-card__meta {
  display: flex;
  gap: 16px;
  margin-bottom: 16px;
}

.kh-card--featured-video .kh-card__date,
.kh-card--featured-video .kh-card__category {
  font-family: 'Mont', sans-serif;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: #FFFFFF;
  opacity: 0.9;
}

.kh-card--featured-video .kh-card__title {
  font-family: 'Mont', sans-serif;
  font-size: 28px;
  font-weight: 700;
  color: #FFFFFF;
  line-height: 1.2;
  margin-bottom: 18px;
}

.kh-card--featured-video .kh-card__link {
  font-family: 'Mont', sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: #FFFFFF;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  transition: gap 0.3s ease;
}

.kh-card--featured-video .kh-card__link:hover {
  gap: 12px;
}

.kh-card--featured-video .kh-card__arrow {
  font-size: 16px;
}

/* ============================================
   SECTION 4: Content Grid
   ============================================ */

.kh-grid {
  padding: 20px 0 60px;
  background: #EEF2F2;
}

.kh-grid__list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

/* Grid Card Styles */
.kh-card--grid {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 22px;
  overflow: hidden;
  background: #003A44;
  padding: 40px 40px;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
}

.kh-card--grid:hover {
  background: var(--color-primary);
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.kh-card--grid .kh-card__image {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 60px;
}

.kh-card--grid .kh-card__image img {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  display: block;
  border-radius: 16px;
}

.kh-card--grid .kh-card__tags {
  display: flex;
  justify-content: space-between;
  width: 100%;
}

.kh-card--grid .kh-card__date,
.kh-card--grid .kh-card__category {
  font-family: 'Mont', sans-serif;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: #FFFFFF;
  letter-spacing: 0.06em;
  text-shadow: none;
}

/* Image + play wrapper for video cards */
.kh-card__thumb {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
}

.kh-card__thumb img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

/* Play button for video cards in grid */
.kh-card--video .kh-card__play-small {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary);
  transition: transform 0.3s ease, background 0.3s ease;
  z-index: 3;
}

.kh-card--video .kh-card__play-small:hover {
  transform: translate(-50%, -50%) scale(1.1);
  background: #FFFFFF;
}

.kh-card--grid .kh-card__body {
  padding: 0;
  background: transparent;
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
}

.kh-card--grid .kh-card__title {
  font-family: 'Mont', sans-serif;
  font-size: 32px;
  font-weight: 700;
  color: #FFFFFF;
  margin-bottom: 70px;
  line-height: normal;
  letter-spacing: -0.72px;
}

.kh-card--grid .kh-card__excerpt {
  font-family: 'Mont', sans-serif;
  font-size: 14px;
  font-weight: 400;
  color: #FFFFFF;
  margin-bottom: 24px;
  line-height: 32px;
  letter-spacing: 0.16px;
}

.kh-card--grid .kh-card__link {
  font-family: 'Mont', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: #EC852F;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  transition: color 0.3s ease;
  letter-spacing: 0.28px;
  margin-top: auto;
}

.kh-card--grid .kh-card__link-text {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.kh-card--grid .kh-card__link-start,
.kh-card--grid .kh-card__link-end {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
}

.kh-card--grid .kh-card__link-bullet {
  width: 5px;
  height: 5px;
  flex: 0 0 5px;
  border-radius: 50%;
  background: currentColor;
}

.kh-card--grid .kh-card__link-line {
  height: 1px;
  background: currentColor;
  border-radius: 999px;
  transition: width 0.28s ease, opacity 0.28s ease;
}

.kh-card--grid .kh-card__link-line--start {
  width: 0;
  opacity: 0;
}

.kh-card--grid .kh-card__link-line--end {
  width: 40px;
  opacity: 1;
}

.kh-card--grid .kh-card__link-end .kh-card__link-bullet {
  margin-left: -1px;
}

.kh-card--grid:hover .kh-card__link-line--start,
.kh-card--grid .kh-card__link:hover .kh-card__link-line--start {
  width: 40px;
  opacity: 1;
}

.kh-card--grid:hover .kh-card__link-line--end,
.kh-card--grid .kh-card__link:hover .kh-card__link-line--end {
  width: 0;
  opacity: 0;
}

/* ============================================
   SECTION 5: Pagination
   ============================================ */

.kh-pagination {
  padding: 40px 0 60px;
  background: #EEF2F2;
}

.kh-pagination .container {
  border-top: 1px solid var(--border-dark-soft);
  border-bottom: 1px solid var(--border-dark-soft);
  padding: 20px 0;
}

.kh-pagination__wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.kh-pagination__prev,
.kh-pagination__next {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: transparent;
  border: 1px solid var(--border-dark-mid);
  font-size: 18px;
  color: var(--color-text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s ease, color 0.3s ease;
}

.kh-pagination__prev:hover:not(:disabled),
.kh-pagination__next:hover:not(:disabled) {
  background: var(--color-primary);
  color: #FFFFFF;
  border-color: var(--color-primary);
}

.kh-pagination__prev:disabled,
.kh-pagination__next:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.kh-pagination__pages {
  display: flex;
  align-items: center;
  gap: 8px;
}

.kh-pagination__page {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Mont', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--color-text);
  text-decoration: none;
  transition: background 0.3s ease, color 0.3s ease;
}

.kh-pagination__page.active {
  background: var(--color-primary);
  color: #FFFFFF;
}

.kh-pagination__page:hover:not(.active) {
  background: rgba(15, 121, 140, 0.1);
}

.kh-pagination__dots {
  font-family: 'Mont', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: rgba(31, 31, 31, 0.5);
  padding: 0 8px;
}
