/* TAPAS ENTERPRISE — Full-bleed hero slider (reference-style) */

.te-hero {
  --te-h: clamp(620px, 72vh, 820px);
  /* Align with site container, inset toward left-center (not flush to edge) */
  --te-content-inset: max(1.5rem, calc((100vw - min(1200px, 92vw)) / 2 + clamp(2rem, 6vw, 5.5rem)));
  position: relative;
  margin-top: var(--header-h);
  scroll-margin-top: var(--header-h);
  height: var(--te-h);
  background: #1a1410;
  overflow: hidden;
}

.te-hero-slider {
  position: relative;
  width: 100%;
  height: 100%;
}

.te-hero-track {
  position: relative;
  width: 100%;
  height: 100%;
}

/* Slide — crossfade stack */
.te-hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 1.15s cubic-bezier(0.45, 0, 0.15, 1), visibility 1.15s;
  z-index: 0;
  pointer-events: none;
}

.te-hero-slide.is-active {
  opacity: 1;
  visibility: visible;
  z-index: 1;
  pointer-events: auto;
}

.te-hero-slide.is-leaving {
  opacity: 0;
  visibility: visible;
  z-index: 2;
  pointer-events: none;
}

/* Background video */
.te-hero-media {
  position: absolute;
  inset: 0;
}

.te-hero-fallback {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(135deg, #2a2118 0%, #3d2814 45%, #1c1510 100%);
  transition: opacity 0.6s ease;
}

.te-hero-media.has-video .te-hero-fallback {
  opacity: 0;
}

.te-hero-video {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0;
  transform: scale(1.1);
  filter: brightness(0.85);
  transition:
    opacity 1.15s cubic-bezier(0.45, 0, 0.15, 1),
    transform 14s cubic-bezier(0.25, 0.1, 0.25, 1),
    filter 1.15s ease;
}

.te-hero-slide.is-active .te-hero-video.is-ready,
.te-hero-slide.is-active .te-hero-video {
  opacity: 1;
  transform: scale(1);
  filter: brightness(1);
}

.te-hero-slide.is-leaving .te-hero-video {
  opacity: 0;
  transform: scale(1.04);
  filter: brightness(0.7);
}

/* Dark overlay — heavier on left for text */
.te-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(26, 20, 16, 0.92) 0%,
    rgba(42, 33, 24, 0.75) 38%,
    rgba(42, 33, 24, 0.4) 65%,
    rgba(26, 20, 16, 0.35) 100%
  );
  z-index: 2;
  opacity: 0.92;
  transition: opacity 1.15s ease;
}

.te-hero-slide.is-leaving .te-hero-overlay {
  opacity: 1;
}

/* Content — left-center aligned (container + inset, not edge-flush) */
.te-hero-wrap {
  position: relative;
  z-index: 10;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 2.5rem clamp(1.25rem, 4vw, 2.5rem) clamp(2.5rem, 5vh, 3.5rem);
  padding-left: var(--te-content-inset);
}

.te-hero-content {
  max-width: min(640px, 100%);
}

.te-hero-tag {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--yellow);
  margin-bottom: 1.125rem;
  opacity: 0;
  transform: translateY(14px);
}

.te-hero-headline {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4.5vw, 3.25rem);
  font-weight: var(--heading-weight);
  line-height: var(--heading-lh);
  color: #fff;
  margin-bottom: 1.25rem;
  letter-spacing: var(--heading-tracking);
  opacity: 0;
  transform: translateY(18px);
}

.te-hero-headline .te-hero-hl {
  color: var(--orange);
  background: linear-gradient(135deg, var(--yellow-light), var(--orange));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.te-hero-desc {
  font-family: var(--font-heading);
  font-size: clamp(1rem, 1.4vw, 1.125rem);
  font-weight: 400;
  letter-spacing: 0;
  font-weight: 400;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.88);
  margin-bottom: 2rem;
  max-width: 540px;
  opacity: 0;
  transform: translateY(16px);
}

.te-hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.875rem;
  margin-bottom: 0;
  opacity: 0;
  transform: translateY(16px);
}

/* Pill buttons like reference */
.te-hero-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.9rem 1.65rem;
  font-family: var(--font-heading);
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: 0;
  border-radius: 100px;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, border-color 0.25s;
}

.te-hero-btn svg {
  flex-shrink: 0;
  transition: transform 0.25s ease;
}

.te-hero-btn:hover svg {
  transform: translateX(3px);
}

.te-hero-btn--solid {
  color: #fff;
  background: linear-gradient(135deg, var(--brown-dark), #2a2118);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}

.te-hero-btn--solid:hover {
  background: linear-gradient(135deg, var(--orange-deep), var(--brown-dark));
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.te-hero-btn--ghost {
  color: #fff;
  background: transparent;
  border: 1.5px solid rgba(255, 255, 255, 0.55);
}

.te-hero-btn--ghost:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

/* Pager — directly below CTA buttons */
.te-hero-pager {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 1.5rem;
  opacity: 0;
  transform: translateY(12px);
}

.te-hero-pager-item {
  padding: 0;
  border: none;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.35);
  border-radius: 100px;
  height: 8px;
  width: 8px;
  transition: width 0.4s ease, background 0.3s ease;
}

.te-hero-pager-item.is-active {
  width: 48px;
  background: rgba(255, 255, 255, 0.25);
  position: relative;
  overflow: hidden;
}

.te-hero-pager-fill {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--yellow), var(--orange));
  border-radius: 100px;
}

/* Animations */
.te-hero-slide.is-active .te-hero-tag { animation: teUp 0.7s ease 0.08s forwards; }
.te-hero-slide.is-active .te-hero-headline { animation: teUp 0.75s ease 0.18s forwards; }
.te-hero-slide.is-active .te-hero-desc { animation: teUp 0.7s ease 0.32s forwards; }
.te-hero-slide.is-active .te-hero-actions { animation: teUp 0.7s ease 0.42s forwards; }
.te-hero-slide.is-active .te-hero-pager { animation: teUp 0.65s ease 0.5s forwards; }

@keyframes teUp {
  to { opacity: 1; transform: translateY(0); }
}

.te-hero-slide:not(.is-active) .te-hero-tag,
.te-hero-slide:not(.is-active) .te-hero-headline,
.te-hero-slide:not(.is-active) .te-hero-desc,
.te-hero-slide:not(.is-active) .te-hero-actions,
.te-hero-slide:not(.is-active) .te-hero-pager {
  opacity: 0;
  transform: translateY(16px);
  animation: none;
}

/* Side arrows */
.te-hero-arrows {
  position: absolute;
  inset: 0;
  z-index: 15;
  pointer-events: none;
}

.te-hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: auto;
  cursor: pointer;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  opacity: 0;
  transition: opacity 0.3s, background 0.25s, transform 0.25s;
}

.te-hero:hover .te-hero-arrow {
  opacity: 1;
}

.te-hero-arrow:hover {
  background: rgba(232, 122, 30, 0.85);
  border-color: transparent;
  transform: translateY(-50%) scale(1.06);
}

.te-hero-arrow--prev { left: 1rem; }
.te-hero-arrow--next { right: 1rem; }

/* Reset anim helper target */
.te-hero-slide .te-hero-tag,
.te-hero-slide .te-hero-headline,
.te-hero-slide .te-hero-desc,
.te-hero-slide .te-hero-actions {
  /* animated via keyframes */
}

@media (max-width: 768px) {
  .te-hero {
    --te-h: clamp(420px, 78vh, 680px);
    --te-content-inset: clamp(1.25rem, 6vw, 2rem);
  }

  .te-hero-wrap {
    padding: 2rem clamp(1rem, 4vw, 1.5rem) clamp(2rem, 4vh, 2.5rem);
    padding-left: var(--te-content-inset);
    align-items: flex-end;
  }

  .te-hero-overlay {
    background: linear-gradient(
      180deg,
      rgba(26, 20, 16, 0.75) 0%,
      rgba(42, 33, 24, 0.88) 55%,
      rgba(26, 20, 16, 0.92) 100%
    );
  }

  .te-hero-headline {
    font-size: clamp(1.65rem, 7vw, 2.1rem);
  }

  .te-hero-desc {
    font-size: 0.95rem;
    margin-bottom: 1.35rem;
    max-width: 100%;
  }

  .te-hero-actions {
    flex-direction: column;
    align-items: stretch;
    margin-bottom: 1.5rem;
  }

  .te-hero-btn {
    justify-content: center;
    width: 100%;
    min-height: 44px;
  }

  .te-hero-arrow {
    opacity: 1;
    width: 36px;
    height: 36px;
  }
}

@media (max-width: 480px) {
  .te-hero {
    --te-h: clamp(380px, 72vh, 560px);
    --te-content-inset: 1rem;
  }

  .te-hero-tag {
    font-size: 0.72rem;
    letter-spacing: 0.12em;
    margin-bottom: 0.85rem;
  }

  .te-hero-headline {
    font-size: clamp(1.45rem, 7.5vw, 1.85rem);
    margin-bottom: 0.85rem;
  }

  .te-hero-desc {
    font-size: 0.9rem;
    line-height: 1.6;
  }

  .te-hero-btn {
    padding: 0.82rem 1.25rem;
    font-size: 0.875rem;
  }

  .te-hero-arrow--prev {
    left: 0.35rem;
  }

  .te-hero-arrow--next {
    right: 0.35rem;
  }

  .te-hero-pager {
    margin-top: 1.15rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .te-hero-slide,
  .te-hero-video {
    transition-duration: 0.01ms !important;
  }
  .te-hero-video {
    transform: scale(1) !important;
    opacity: 1 !important;
    filter: none !important;
  }
  .te-hero-slide:not(.is-active) .te-hero-video {
    opacity: 0 !important;
  }
  .te-hero-slide.is-active .te-hero-tag,
  .te-hero-slide.is-active .te-hero-headline,
  .te-hero-slide.is-active .te-hero-desc,
  .te-hero-slide.is-active .te-hero-actions,
  .te-hero-slide.is-active .te-hero-pager {
    opacity: 1;
    transform: none;
    animation: none;
  }
}
