/* Cards */
.featured-article {
  border-radius: 16px;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  background-color: var(--bg-card);
  box-shadow: 0 4px 16px rgba(var(--shadow-color-light-rgb), var(--shadow-opacity-light));
}

.featured-article:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 24px rgba(var(--shadow-color-light-rgb), var(--shadow-opacity-medium));
}

.featured-article__link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.featured-article__media {
  display: flex;
  justify-content: center;
  align-items: center;
  max-height: 300px;
  position: relative;
  padding-top: 5px; /* Adjust as needed, or use aspect-ratio */
  padding-bottom: 5px;
  overflow: hidden;
  background-color: var(--bg-secondary);
}

.featured-article__image {
  aspect-ratio: 3 / 1;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  margin: auto;
  width: 80%;
  height: 80%;
  object-fit: contain;
  transition: transform 1s ease;
  z-index: 2;
  border-radius: 8px;
}

.featured-article:hover .featured-article__image {
  transform: scale(1.03);
}

.featured-article__content {
  padding: 24px;
}

.featured-article__meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.featured-article__tag {
  background-color: var(--primary-color);
  color: var(--primary-text-over);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.03em;
}

.featured-article__date {
  color: var(--text-tertiary);
  font-size: 14px;
  line-height: 1.42859;
  font-weight: 500;
}

.featured-article__title {
  font-size: 28px;
  line-height: 1.14286;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text-main);
}

.featured-article__excerpt {
  font-size: 17px;
  line-height: 1.47059;
  color: var(--text-secondary);
  margin-bottom: 20px;
}

.featured-article__cta {
  display: inline-block;
  font-size: 16px;
  font-weight: 600;
  color: var(--text-link);
  position: relative;
}

.featured-article__cta:after {
  content: "→";
  margin-left: 8px;
  transition: transform 0.3s ease;
  display: inline-block;
}

.featured-article:hover .featured-article__cta:after {
  transform: translateX(4px);
}

.stream-article {
  border-radius: 12px;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  background-color: var(--bg-card);
  box-shadow: 0 2px 12px rgba(var(--shadow-color-light-rgb), var(--shadow-opacity-light));
  height: 100%;
  display: flex;
  flex-direction: column;
}

.stream-article:hover {
  transform: translateY(-6px);
  box-shadow: 0 8px 20px rgba(var(--shadow-color-light-rgb), var(--shadow-opacity-medium));
}

.stream-article__link {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  height: 100%;
}

.stream-article__media {
  position: relative;
  padding-top: 80%; /* Aspect ratio for the media container */
  overflow: hidden;
  background-color: var(--bg-secondary);
}

.stream-article__image {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  margin: auto;
  width: 85%;
  height: 85%;
  object-fit: contain;
  transition: transform 0.8s ease;
  border-radius: 4px;
}

.stream-article:hover .stream-article__image {
  transform: scale(1.05);
}

.stream-article__content {
  padding: 20px;
  flex-grow: 1;
}

.stream-article__meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.stream-article__tag {
  background-color: var(--bg-secondary);
  color: var(--text-main);
  padding: 3px 10px;
  border-radius: 16px;
  font-size: 11px;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.02em;
}

html.dark-mode .stream-article__tag {
    color: var(--text-main); /* Ensure contrast or specific dark mode color */
}

.stream-article__date {
  color: var(--text-tertiary);
  font-size: 12px;
  line-height: 1.33337;
  font-weight: 500;
}

.stream-article__title {
  font-size: 18px;
  line-height: 1.33337;
  font-weight: 600;
  color: var(--text-main);
  margin: 0;
}

/* Secondary Featured Section with Blur (Variant of Stream Article) */
.secondary-featured-section .stream-article__media {
  padding-top: 35%; /* Different aspect ratio for this type */
}

.secondary-featured-section .stream-article__media::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: var(--bg-image);
  background-size: cover;
  background-position: center;
  filter: blur(10px) brightness(0.85);
  z-index: 1;
  transform: scale(1.1);
}
html.dark-mode .secondary-featured-section .stream-article__media::before {
  filter: blur(10px) brightness(0.65);
}

.secondary-featured-section .stream-article__image {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  margin: auto;
  width: 70%;
  height: 90%;
  object-fit: contain;
  z-index: 2;
  border-radius: 6px;
  transition: transform 0.8s ease;
}

.secondary-featured-section .stream-article:hover .stream-article__image {
  transform: scale(1.03);
}