/**
 * Shared hero chrome (all layouts).
 */

.kutby-hero {
  position: relative;
  background: var(--kutby-color-bg);
  color: var(--kutby-color-text);
}

.kutby-hero--space-compact {
  padding-block: var(--kutby-space-4);
}

.kutby-hero--space-normal {
  padding-block: var(--kutby-space-6);
}

.kutby-hero--space-relaxed {
  padding-block: var(--kutby-space-8);
}

.kutby-hero--width-narrow .kutby-hero__container {
  max-width: 48rem;
}

.kutby-hero--width-wide .kutby-hero__container {
  max-width: var(--kutby-site-width, 1400px);
}

.kutby-hero-media {
  position: relative;
  overflow: hidden;
  border-radius: var(--kutby-radius-md);
  background: var(--kutby-color-surface);
}

.kutby-hero-media__img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.kutby-hero-media--16x9 {
  aspect-ratio: 16 / 9;
}

.kutby-hero-media--4x3 {
  aspect-ratio: 4 / 3;
}

.kutby-hero-media--1x1 {
  aspect-ratio: 1 / 1;
}

.kutby-hero-media--21x9 {
  aspect-ratio: 21 / 9;
}

.kutby-hero-overlay {
  position: absolute;
  inset: 0;
  background: var(--kutby-overlay);
  pointer-events: none;
}

.kutby-hero-badge {
  display: inline-block;
  margin-bottom: var(--kutby-space-2);
  padding: var(--kutby-space-1) var(--kutby-space-2);
  border-radius: var(--kutby-radius-sm);
  background: var(--kutby-color-surface);
  color: var(--kutby-color-link);
  font-size: var(--kutby-font-size-sm);
  text-decoration: none;
}

.kutby-hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--kutby-space-2);
  margin-top: var(--kutby-space-2);
  color: var(--kutby-color-muted);
  font-size: var(--kutby-font-size-sm);
}

.kutby-hero-featured__title,
.kutby-hero-card__title {
  margin: 0;
  line-height: var(--kutby-line-height-tight);
}

.kutby-hero-featured__title a,
.kutby-hero-card__title a,
.kutby-hero-list__link {
  color: inherit;
  text-decoration: none;
}

.kutby-hero-featured__title a:hover,
.kutby-hero-card__title a:hover,
.kutby-hero-list__link:hover,
.kutby-hero-featured__title a:focus-visible,
.kutby-hero-card__title a:focus-visible,
.kutby-hero-list__link:focus-visible {
  color: var(--kutby-color-link);
}

.kutby-hero-featured__excerpt {
  margin: var(--kutby-space-3) 0;
  color: var(--kutby-color-muted);
}

.kutby-hero-card__body,
.kutby-hero-featured__body {
  padding-top: var(--kutby-space-3);
}

.kutby-hero-list__heading {
  margin: 0 0 var(--kutby-space-3);
  font-size: var(--kutby-font-size-lg);
}

.kutby-hero-list__items {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--kutby-space-3);
}

.kutby-hero-list__item {
  display: flex;
  gap: var(--kutby-space-3);
  align-items: flex-start;
}

.kutby-hero-list__index {
  flex: 0 0 auto;
  width: 1.5rem;
  color: var(--kutby-color-muted);
  font-weight: 700;
}

.kutby-hero-grid {
  display: grid;
  gap: var(--kutby-space-5);
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .kutby-hero-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .kutby-hero-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.kutby-hero-skeleton {
  display: grid;
  gap: var(--kutby-space-2);
}

.kutby-hero-skeleton__media {
  aspect-ratio: 16 / 9;
  border-radius: var(--kutby-radius-md);
  background: var(--kutby-color-surface);
}

.kutby-hero-skeleton__line {
  height: 0.75rem;
  border-radius: var(--kutby-radius-sm);
  background: var(--kutby-color-surface);
}

.kutby-hero-skeleton__line--short {
  width: 60%;
}

.kutby-hero-empty {
  padding: var(--kutby-space-6);
  text-align: center;
  color: var(--kutby-color-muted);
  background: var(--kutby-color-surface);
  border-radius: var(--kutby-radius-md);
}
