/**
 * Featured fonts — [jt_featured_fonts]
 * V5 B&W card design
 */

.jt-featured-fonts {
  width: 100%;
  max-width: 1240px;
  margin-inline: auto;
  margin-bottom: 40px;
  padding: 0 28px;
}

.jt-section.jt-featured-fonts {
  margin-bottom: 40px;
}

.jt-home-wrap .jt-featured-fonts {
  max-width: none;
  padding: 0;
  margin-bottom: 40px;
}

.jt-featured-fonts__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.jt-featured-fonts__eyebrow {
  display: block;
  margin-bottom: 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--jt-muted);
}

.jt-featured-fonts__title {
  margin: 0;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--jt-text);
}

.jt-featured-fonts__shop-link {
  flex-shrink: 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--jt-text);
  text-decoration: none;
}

.jt-featured-fonts__shop-link:hover {
  opacity: 0.65;
}

.jt-featured-fonts__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.jt-featured-card {
  border: 1px solid var(--jt-border);
  border-radius: var(--jt-radius);
  overflow: hidden;
  background: var(--jt-surface);
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.jt-featured-card:hover {
  border-color: var(--jt-text);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
}

.jt-featured-card--hero {
  grid-column: 1 / -1;
}

.jt-featured-card__link {
  display: flex;
  flex-direction: column;
  height: 100%;
  color: inherit;
  text-decoration: none;
}

.jt-featured-card--hero .jt-featured-card__link {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
}

.jt-featured-card__preview {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 160px;
  padding: 32px 24px;
  text-align: center;
  font-size: clamp(1.35rem, 3vw, 2.25rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  background: var(--jt-surface-2);
  position: relative;
  color: var(--jt-text);
  word-break: break-word;
}

/* Featured section — larger typographic preview (not newest grid covers) */
.jt-featured-fonts .jt-featured-card__preview:not(.jt-featured-card__preview--has-cover) {
  min-height: 220px;
  padding: 48px 32px;
  font-size: clamp(2rem, 4.8vw, 3.75rem);
  line-height: 1.02;
}

.jt-featured-card--hero .jt-featured-card__preview {
  min-height: 200px;
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  background: var(--jt-hero-preview-bg);
  color: var(--jt-hero-preview-text);
}

.jt-featured-fonts .jt-featured-card--hero .jt-featured-card__preview:not(.jt-featured-card__preview--has-cover) {
  min-height: 300px;
  padding: 56px 40px;
  font-size: clamp(2.25rem, 5.5vw, 4.5rem);
}

/* Newest grid — WooCommerce gallery cover ([jt_font_grid], [jt_latest_fonts]) */
.jt-featured-card__preview--has-cover {
  padding: 0;
  overflow: hidden;
  background: var(--jt-surface-2);
  border: none;
}

.jt-featured-card__preview--has-cover .jt-featured-card__cover {
  display: block;
  width: 100%;
  min-height: 160px;
  object-fit: cover;
  object-position: center;
  border: none;
  outline: none;
}

.jt-featured-card--hero .jt-featured-card__preview--has-cover .jt-featured-card__cover {
  min-height: 200px;
}

.jt-featured-card__badge {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 2;
  padding: 7px 12px;
  border-radius: 4px;
  background: var(--jt-accent, #c6ff33);
  color: var(--jt-accent-text);
  border: none;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
  line-height: 1;
}

.jt-featured-card__badge--new {
  background: var(--jt-accent, #c6ff33);
  color: var(--jt-accent-text);
}

.jt-featured-card__badge--featured {
  left: auto;
  right: 14px;
  background: #ff8a00;
  color: #111111;
}

.jt-badge-new {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  margin-right: 8px;
  border-radius: 4px;
  background: var(--jt-accent, #c6ff33);
  color: var(--jt-accent-text);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  vertical-align: middle;
}

.jt-featured-card__body {
  padding: 20px 22px 22px;
}

.jt-featured-card__name {
  margin: 0 0 6px;
  font-size: 18px;
  font-weight: 700;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--jt-text);
}

.jt-featured-card__meta {
  margin: 0 0 14px;
  font-size: 13px;
  color: var(--jt-muted);
}

.jt-featured-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.jt-featured-card__price {
  font-size: 14px;
  font-weight: 700;
  color: var(--jt-text);
}

.jt-featured-card__cta {
  font-size: 14px;
  font-weight: 600;
  color: var(--jt-text);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.jt-featured-card--hero .jt-featured-card__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  padding: 0 18px;
  border-radius: 8px;
  background: var(--jt-primary);
  color: var(--jt-primary-text);
  text-decoration: none;
}

@media (max-width: 900px) {
  .jt-featured-fonts__grid {
    grid-template-columns: 1fr;
  }

  .jt-featured-card--hero {
    grid-column: auto;
  }

  .jt-featured-card--hero .jt-featured-card__link {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 767px) {
  .jt-featured-fonts {
    padding: 0 20px;
    margin-bottom: 32px;
  }

  .jt-section.jt-featured-fonts {
    margin-bottom: 32px;
  }

  .jt-home-wrap .jt-featured-fonts {
    padding: 0;
    margin-bottom: 32px;
  }

  .jt-featured-fonts__head {
    flex-direction: column;
    align-items: flex-start;
  }

  .jt-featured-fonts .jt-featured-card__preview:not(.jt-featured-card__preview--has-cover) {
    min-height: 180px;
    padding: 36px 20px;
    font-size: clamp(1.65rem, 7vw, 2.75rem);
  }

  .jt-featured-fonts .jt-featured-card--hero .jt-featured-card__preview:not(.jt-featured-card__preview--has-cover) {
    min-height: 220px;
    padding: 40px 24px;
    font-size: clamp(1.85rem, 8vw, 3rem);
  }

  .jt-featured-card__body {
    padding: 16px 18px 20px;
  }

  .jt-featured-card__footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
}
