.rediem-root {
  --rediem-surface-mute: rgba(0, 0, 0, 0.06);
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  border-radius: 16px;
  padding: 24px;
  overflow: hidden;
}

.rediem-root *,
.rediem-root *::before,
.rediem-root *::after {
  box-sizing: border-box;
}

.rediem-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}

.rediem-header-text {
  flex: 1;
  min-width: 0;
}

.rediem-title,
.rediem-subtitle {
  color: var(--rediem-primary, inherit);
}

.rediem-title {
  margin: 0;
  font-size: 26px;
  font-weight: 700;
  line-height: 1;
}

.rediem-subtitle {
  margin: 4px 0 0;
  font-size: 18px;
}

.rediem-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.rediem-nav-btn {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: 9999px;
  background: transparent;
  color: var(--rediem-primary, inherit);
  font-size: 1.25rem;
  cursor: pointer;
  transition: background 0.15s ease;
}

.rediem-nav-btn:hover:not(:disabled) {
  background: var(--rediem-surface-mute);
}

.rediem-nav-btn[disabled],
.rediem-nav-btn:disabled,
.rediem-nav-btn.rediem-nav-disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Slider track: Slick owns overflow and motion; no native horizontal scroll UI */
.rediem-slider {
  width: 100%;
}

.rediem-card {
  flex: 0 0 280px;
  border-radius: 12px;
  padding: 16px 0;
  height: 100%;
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  gap: 12px 0;
  align-content: start;
}

.rediem-card-head {
  display: flex;
  align-items: center;
  gap: 12px;
}

.rediem-card-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--rediem-primary, inherit);
  opacity: 0.9;
  flex-shrink: 0;
  display: inline-block !important;
}

.rediem-card-meta {
  min-width: 0;
}

/* Single-line text: title, snippet, author */
.rediem-card-author,
.rediem-card-title,
.rediem-card-snippet {
  min-width: 0;
  color: var(--rediem-body, inherit);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rediem-card-author {
  font-weight: 600;
  font-size: 14px;
}

.rediem-card-content {
  display: grid;
  grid-template-rows: 1.2fr 1fr;
  gap: 8px 0;
  min-width: 0;
}

.rediem-card-title {
  line-height: 1.2;
  font-size: 12px;
  font-weight: 700;
}

.rediem-card-snippet {
  margin: 0;
  font-size: 12px;
  line-height: 1.5;
}

.rediem-card-media {
  width: 100%;
  min-height: 0;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  max-height: 152px;
  display: block !important;
}

.rediem-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.rediem-card-footer {
  display: grid;
  grid-template-rows: auto auto;
  row-gap: 8px;
  min-width: 0;
}

.rediem-card-footer-stats {
  min-width: 0;
  max-width: 100%;
}

.rediem-card-tag {
  display: inline-block;
  font-size: 12px;
  line-height: 1.4;
  border-radius: 999px;
  overflow: hidden;
  background: #fff;
}

.rediem-card-tag .rediem-tag-text {
  display: inline-block;
  padding: 4px 10px;
}

.rediem-card-footer-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.rediem-card-stats {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 10px;
}

.rediem-card-stats .rediem-stat {
  flex-shrink: 0;
  white-space: nowrap;
}

.rediem-card-head,
.rediem-card-footer,
.rediem-card-content {
  padding: 0 16px;
  min-width: 0;
}

.rediem-cta {
  display: flex;
  justify-content: center;
  margin-top: 20px;
}

.rediem-cta-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 12px;
  border-radius: 8px;
  background: var(--rediem-primary, inherit);
  color: var(--rediem-card-bg, inherit);
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  transition: opacity 0.15s ease, transform 0.1s ease;
}

.rediem-cta-btn:hover {
  opacity: 0.92;
}

.rediem-cta-btn:active {
  transform: scale(0.98);
}

/* Slick: equal-height slides via flex */
.rediem-root .rediem-slick-slider.slick-initialized {
  display: flex;
}

.rediem-root .rediem-slick-slider .slick-list {
  flex: 1;
  overflow: hidden;
  display: flex;
  align-items: stretch;
}

.rediem-slider .slick-list {
  padding-right: 60px;
  margin-right: -60px;
}

.rediem-root .rediem-slick-slider .slick-track {
  display: flex;
  align-items: stretch;
}

.rediem-root .rediem-slick-slider .slick-slide {
  padding: 0;
  box-sizing: border-box;
  height: auto;
  display: flex;
  padding-right: 10px;
  max-width: calc(100% / 4);
}

.rediem-root .rediem-slick-slider .slick-slide>div {
  display: flex;
  flex: 1;
  min-width: 0;
}

.rediem-root .rediem-slick-slider .rediem-slide {
  outline: none;
  flex: 1;
  display: flex;
  min-height: 0;
}

@media(max-width: 767px) {
  .rediem-header {
    flex-wrap: wrap;
  }

  .rediem-header>* {
    width: 100%;
  }
}