/* HERO — full-width slider with overlaid content */

.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: clamp(560px, 75vh, 760px);
  overflow: hidden;
  background: var(--color-primary-dark);
  color: #fff;
}

/* Slider as background layer */
.hero__slider {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.hero__slides {
  position: absolute;
  inset: 0;
}

.hero__slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 800ms ease;
}
.hero__slide.is-active { opacity: 1; }

.hero__slide-image,
.hero__slide-placeholder {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.hero__slide-placeholder {
  background:
    linear-gradient(135deg, var(--color-primary-dark) 0%, var(--color-primary) 60%, var(--color-primary-light) 100%),
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.06), transparent 40%);
}

/* Dark gradient overlay for text readability */
.hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  background:
    linear-gradient(90deg, rgba(15, 45, 92, 0.85) 0%, rgba(15, 45, 92, 0.55) 45%, rgba(15, 45, 92, 0.15) 100%),
    linear-gradient(180deg, transparent 60%, rgba(15, 45, 92, 0.7) 100%);
  pointer-events: none;
}

/* Content overlay */
.hero__container {
  position: relative;
  z-index: 3;
  width: 100%;
  padding-top: var(--space-2xl);
  padding-bottom: var(--space-2xl);
}

/* Only the active content is visible - safe default that works even without JS animation */
.hero .hero__content {
  display: none;
  max-width: 720px;
  flex-direction: column;
  gap: var(--space-md);
  opacity: 0;
  transition: opacity 500ms ease;
}
.hero .hero__content.is-active {
  display: flex;
  opacity: 1;
}

.hero__headline--slide {
  font-size: clamp(var(--text-3xl), 5.5vw, var(--text-6xl));
}

.hero__kicker {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-accent);
  width: fit-content;
}
.hero__kicker-dash {
  width: 24px;
  height: 2px;
  background: var(--color-accent);
}

.hero__headline {
  font-size: clamp(var(--text-4xl), 7vw, var(--text-7xl));
  line-height: 1;
  color: #fff;
  margin: 0;
  text-shadow: 0 2px 16px rgba(15, 45, 92, 0.35);
}

.hero__sub {
  font-size: var(--text-lg);
  color: rgba(255, 255, 255, 0.9);
  max-width: 540px;
  margin: 0;
  text-shadow: 0 1px 8px rgba(15, 45, 92, 0.25);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin-top: var(--space-sm);
}

/* Controls (arrows + dots) */
.hero__controls {
  position: absolute;
  bottom: var(--space-md);
  left: 0;
  right: 0;
  z-index: 4;
  pointer-events: none;
}
.hero__controls-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
}

.hero__arrow {
  pointer-events: auto;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
  color: #fff;
  font-size: var(--text-2xl);
  line-height: 1;
  border: 1px solid rgba(255, 255, 255, 0.25);
  transition: background var(--transition-fast), color var(--transition-fast);
}
.hero__arrow:hover {
  background: var(--color-accent);
  color: var(--color-dark);
  border-color: var(--color-accent);
}

.hero__dots {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}
.hero__dot {
  width: 32px;
  height: 4px;
  background: rgba(255, 255, 255, 0.4);
  transition: background var(--transition-fast), width var(--transition-fast);
  border: 0;
  cursor: pointer;
}
.hero__dot.is-active {
  background: var(--color-accent);
  width: 48px;
}

/* Mobile — kompaktowy poziomy baner */
@media (max-width: 768px) {
  .hero {
    min-height: 0;
    aspect-ratio: 16 / 11;
    max-height: 60vh;
  }
  .hero__slide-image,
  .hero__slide-placeholder {
    object-position: center;
  }
  .hero__overlay {
    background:
      linear-gradient(180deg, rgba(15, 45, 92, 0.45) 0%, rgba(15, 45, 92, 0.85) 100%);
  }
  .hero__container {
    padding-top: var(--space-md);
    padding-bottom: var(--space-md);
  }
  .hero__content { max-width: 100%; }
  .hero__kicker {
    font-size: 11px;
    margin-bottom: 8px;
  }
  .hero__kicker-dash { width: 20px; }
  .hero__headline {
    font-size: clamp(26px, 7vw, 38px);
    margin-bottom: 8px;
  }
  .hero__sub {
    font-size: 13px;
    line-height: 1.45;
    max-width: 100%;
    margin-bottom: 14px;
  }
  .hero__actions {
    gap: 8px;
    flex-wrap: wrap;
  }
  .hero__actions .btn {
    padding: 10px 18px;
    font-size: 12px;
  }
  .hero__controls {
    bottom: 12px;
  }
  .hero__arrow {
    width: 36px;
    height: 36px;
    font-size: 16px;
  }
  .hero__dot { width: 18px; height: 3px; }
  .hero__dot.is-active { width: 28px; }
}

@media (max-width: 480px) {
  .hero {
    aspect-ratio: 4 / 3;
    max-height: 56vh;
  }
  .hero__headline {
    font-size: clamp(22px, 6.5vw, 32px);
  }
  .hero__sub { font-size: 12.5px; }
}

@media (max-height: 500px) and (orientation: landscape) {
  .hero {
    aspect-ratio: auto;
    min-height: 320px;
    max-height: none;
  }
}
