/* ============================================
   IZ Group - Hero Section with Scroll-Hijacking Carousel
   Inspired by PASHA Holding - Premium, elegant, refined
   ============================================ */

/* ============================================
   HERO CONTAINER
   ============================================ */

.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  margin-top: 0;
}

/* Mobile: Allow natural scrolling - slides stack */
@media (max-width: 767px) {
  .hero {
    height: auto;
    overflow: visible;
  }
}

/* Carousel Container */
.hero-carousel {
  position: relative;
  width: 100%;
  height: 100%;
}

/* ============================================
   HERO SLIDES
   ============================================ */

.hero-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  visibility: hidden;
  transition: opacity 1.2s cubic-bezier(0.4, 0, 0.2, 1), visibility 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.hero-slide.active {
  opacity: 1;
  visibility: visible;
  z-index: 1;
}

/* Mobile: Stack slides naturally */
@media (max-width: 767px) {
  .hero-slide {
    position: relative;
    opacity: 1;
    visibility: visible;
    height: auto;
    min-height: auto; /* Let slides be as tall as their content */
    display: flex;
    flex-direction: column;
    margin: 0; /* Remove any margins between slides */
  }

  /* First slide needs top padding for fixed navbar and min-height */
  .hero-slide:first-child {
    padding-top: 140px; /* Account for navbar height (utility nav + main nav) */
    min-height: 100vh; /* Only first slide should fill viewport */
  }

  /* Section background colors on mobile - contains BOTH text and image */
  .hero-slide-white {
    background-color: #ffffff;
  }

  .hero-slide:not(.hero-slide-white) {
    background-color: var(--color-primary);
  }
}

/* Mobile Image Container */
.hero-slide-mobile-img {
  display: none; /* Hidden on desktop */
}

@media (max-width: 767px) {
  .hero-slide-mobile-img {
    display: block;
    width: 100%;
    padding: 0 var(--space-6) var(--space-6); /* Reduced bottom padding */
    margin-top: var(--space-10); /* Minimal spacing between text and image */
    flex-shrink: 0;
    order: 2; /* Image appears AFTER content */
  }

  .hero-slide-mobile-img img {
    width: 100%;
    height: 350px;
    object-fit: cover;
    object-position: center;
    border-radius: var(--border-radius-lg); /* Just rounded corners */
  }

  /* Exception: First slide (flags) - no rounded corners */
  .hero-slide:first-child .hero-slide-mobile-img img {
    border-radius: 0;
    height: 280px;
  }
}

/* Background Image - Right side focus */
.hero-slide-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center right;
  background-repeat: no-repeat;
}

/* Hide background images on mobile - use <img> instead */
@media (max-width: 767px) {
  .hero-slide-bg {
    display: none;
  }
}

/* ============================================
   VIDEO BACKGROUND (First Slide)
   ============================================ */

.hero-video-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none; /* Video not clickable */
  z-index: 0;
}

.hero-video-bg video {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100vw;
  height: 56.25vw; /* 16:9 aspect ratio */
  min-height: 100vh;
  min-width: 177.77vh; /* 16:9 aspect ratio */
  transform: translate(-50%, -50%);
  pointer-events: none;
  object-fit: cover;
}

/* Video also shows on mobile */
@media (max-width: 767px) {
  .hero-video-bg {
    display: block; /* Keep video on mobile */
  }

  /* Ensure video covers properly on mobile */
  .hero-video-bg video {
    width: 100vw;
    height: 56.25vw;
    min-height: 100vh;
    min-width: 177.77vh;
  }
}

/* Subtle overlay - doesn't overpower the image */
.hero-slide-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to right,
    rgba(26, 58, 92, 0.88) 0%,
    rgba(26, 58, 92, 0.55) 55%,
    rgba(26, 58, 92, 0.7) 100%
  );
  z-index: 1;
}

/* Hide overlay on mobile (except for video slide) */
@media (max-width: 767px) {
  .hero-slide-overlay {
    display: none;
  }

  /* Keep overlay visible on video slide for text readability */
  .hero-slide-video .hero-slide-overlay {
    display: block;
  }
}

/* Dark overlay for video slide - ensures text readability */
.hero-slide-overlay-dark {
  background: linear-gradient(
    to right,
    rgba(0, 0, 0, 0.4) 0%,
    rgba(0, 0, 0, 0.3) 55%,
    rgba(0, 0, 0, 0.35) 100%
  ) !important;
}

/* On mobile, use a stronger overlay for better text readability */
@media (max-width: 767px) {
  .hero-slide-overlay-dark {
    background: rgba(0, 0, 0, 0.35) !important;
  }
}

/* ============================================
   VIDEO SLIDE - DARK THEME WITH LIGHT TEXT
   ============================================ */

/* Video slide uses default dark theme with white text */
.hero-slide-video {
  background-color: var(--color-primary); /* Fallback if video doesn't load */
}

/* Mobile background for video slide */
@media (max-width: 767px) {
  .hero-slide-video {
    background-color: var(--color-primary);
  }
}

/* ============================================
   WHITE SLIDES - LIGHT BACKGROUND WITH DARK TEXT
   ============================================ */

/* White slide specific styling */
.hero-slide-white {
  background-color: #ffffff;
}

.hero-slide-white .hero-slide-bg {
  background-position: right center;
  opacity: 1;
}

.hero-slide-white .hero-slide-overlay {
  background: linear-gradient(
    to right,
    rgba(255, 255, 255, 0.98) 0%,
    rgba(255, 255, 255, 0.85) 50%,
    rgba(255, 255, 255, 0) 70%
  );
}

/* Dark text for white slide */
.hero-slide-white .hero-eyebrow {
  color: var(--color-gold);
}

.hero-slide-white .hero-headline {
  color: var(--color-primary);
}

.hero-slide-white .hero-subtitle {
  color: rgba(26, 58, 92, 0.75);
}

/* Dark outline button for white slide */
.hero-slide-white .hero-cta {
  color: var(--color-primary);
  border: 2px solid var(--color-primary);
  padding: var(--space-2) var(--space-6);
  border-radius: var(--border-radius);
}

.hero-slide-white .hero-cta:hover {
  color: var(--color-white);
  background-color: var(--color-primary);
  border-color: var(--color-primary);
}

.hero-slide-white .hero-cta::before {
  background-color: var(--color-primary);
}

.hero-slide-white .hero-cta:hover::before {
  width: 0;
}

/* ============================================
   HERO CONTENT - Left side (50% width)
   ============================================ */

.hero-content-wrapper {
  position: relative;
  height: 100%;
  z-index: 2;
}

/* Mobile: Content wrapper fits content snugly */
@media (max-width: 767px) {
  .hero-content-wrapper {
    position: relative;
    height: auto;
    /* No flex: 1 - wrapper should fit content, not expand */
    display: flex;
    flex-direction: column;
    order: 1; /* Content appears BEFORE image */
    /* No background - uses section background */
  }
}

.hero-content {
  position: relative;
  max-width: var(--container-7xl);
  margin: 0 auto;
  padding: 0 var(--space-6);
  height: 100%;
  display: flex;
  align-items: center;
  z-index: 2;
}

/* Mobile: Content padding and layout */
@media (max-width: 767px) {
  .hero-content {
    padding: var(--space-8) var(--space-6) 0; /* No bottom padding - let content fit snugly */
    height: auto;
    min-height: auto;
  }

  /* First slide needs less top padding since slide has padding-top */
  .hero-slide:first-child .hero-content {
    padding-top: var(--space-4);
  }
}

@media (min-width: 640px) {
  .hero-content {
    padding: 0 var(--space-8);
  }
}

@media (min-width: 1024px) {
  .hero-content {
    padding: 0 var(--space-12);
  }
}

/* Content Container - Limited to left 50% */
.hero-text-content {
  max-width: 50%;
  width: 100%;
  animation: slideUpFadeIn 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.hero-slide.active .hero-text-content {
  animation: slideUpFadeIn 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (max-width: 1023px) {
  .hero-text-content {
    max-width: 65%;
  }
}

@media (max-width: 767px) {
  .hero-text-content {
    max-width: 100%;
  }
}

/* Hero Eyebrow - Elegant small text */
.hero-eyebrow {
  font-family: var(--font-body);
  font-size: 0.6875rem;
  font-weight: 500;
  color: var(--color-gold);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  margin-bottom: var(--space-5);
  opacity: 0.92;
}

@media (min-width: 768px) {
  .hero-eyebrow {
    font-size: 0.75rem;
    margin-bottom: var(--space-6);
  }
}

@media (min-width: 1024px) {
  .hero-eyebrow {
    font-size: 0.8125rem;
  }
}

/* Hero Headline - Reduced size, lighter weight, more refined */
.hero-headline {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 500;
  color: var(--color-white);
  line-height: 1.2;
  letter-spacing: -0.015em;
  margin-bottom: var(--space-6);
}

@media (min-width: 640px) {
  .hero-headline {
    font-size: 2.5rem;
  }
}

@media (min-width: 768px) {
  .hero-headline {
    font-size: 2.75rem;
    margin-bottom: var(--space-8);
  }
}

@media (min-width: 1024px) {
  .hero-headline {
    font-size: 3.25rem;
    line-height: 1.15;
  }
}

@media (min-width: 1280px) {
  .hero-headline {
    font-size: 3.75rem;
  }
}

/* Hero Subtitle - Light, airy, refined */
.hero-subtitle {
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.75;
  margin-bottom: var(--space-8);
  max-width: 520px;
  letter-spacing: 0.015em;
}

@media (min-width: 768px) {
  .hero-subtitle {
    font-size: 1rem;
    margin-bottom: var(--space-10);
  }
}

@media (min-width: 1024px) {
  .hero-subtitle {
    font-size: 1.0625rem;
    line-height: 1.8;
    max-width: 560px;
  }
}

@media (min-width: 1280px) {
  .hero-subtitle {
    font-size: 1.125rem;
    max-width: 600px;
  }
}

/* ============================================
   HERO CTA BUTTON - PASHA Holding Style
   ============================================ */

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-white);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  position: relative;
  padding: var(--space-1) 0;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.hero-cta:hover {
  color: var(--color-gold);
  transform: translateX(6px);
}

/* Animated horizontal line extending to the right */
.hero-cta::before {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 0;
  width: 40px;
  height: 1px;
  background-color: var(--color-gold);
  transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.hero-cta:hover::before {
  width: calc(100% - 28px);
}

/* Arrow icon - Refined */
.hero-cta-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.hero-cta:hover .hero-cta-arrow {
  transform: translateX(4px);
}

.hero-cta-arrow svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
  opacity: 0.88;
}

/* ============================================
   PAGINATION - PASHA Holding Style with Labels
   ============================================ */

.hero-pagination {
  position: absolute;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: var(--space-4);
  z-index: 3;
}

/* Hide pagination on mobile - not needed for stacked layout */
@media (max-width: 767px) {
  .hero-pagination {
    display: none;
  }
}

@media (min-width: 1024px) {
  .hero-pagination {
    bottom: 100px;
    gap: var(--space-5);
  }
}

/* Pagination Item (contains label + dot) */
.hero-pagination-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-3);
  position: relative;
}

/* Pagination Label - Shows on hover/active */
.hero-pagination-label {
  font-family: var(--font-body);
  font-size: 0.6875rem;
  font-weight: 500;
  color: var(--color-white);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  opacity: 0;
  transform: translateY(4px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  white-space: nowrap;
  pointer-events: none;
}

/* Dark pagination labels for white slide */
.hero-pagination-dark .hero-pagination-label {
  color: var(--color-primary);
}

.hero-pagination-item:hover .hero-pagination-label,
.hero-pagination-item.active .hero-pagination-label {
  opacity: 1;
  transform: translateY(0);
}

/* Pagination Dot - Small and refined */
.hero-pagination-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.3);
  border: none;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 0;
}

.hero-pagination-dot:hover {
  background-color: rgba(255, 255, 255, 0.5);
  transform: scale(1.2);
}

/* Dark pagination dots for white slide */
.hero-pagination-dark .hero-pagination-dot {
  background-color: rgba(26, 58, 92, 0.3);
}

.hero-pagination-dark .hero-pagination-dot:hover {
  background-color: rgba(26, 58, 92, 0.5);
}

.hero-pagination-item.active .hero-pagination-dot {
  background-color: var(--color-gold);
  width: 28px;
  border-radius: 4px;
}

/* ============================================
   HERO FOOTER (Copyright & Social Media)
   ============================================ */

.hero-footer {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: var(--space-4) 0;
  z-index: 3;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  background: linear-gradient(to top, rgba(0, 0, 0, 0.12) 0%, transparent 100%);
  transition: border-color var(--transition-fast), background var(--transition-fast);
}

/* Dark footer for white slide */
.hero-footer-dark {
  border-top-color: rgba(26, 58, 92, 0.1);
  background: linear-gradient(to top, rgba(26, 58, 92, 0.06) 0%, transparent 100%);
}

/* Mobile: Solid white footer at bottom */
@media (max-width: 767px) {
  .hero-footer {
    position: relative; /* Not absolute on mobile */
    background: #ffffff; /* Solid white background */
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    padding: var(--space-6) 0;
  }
}

@media (min-width: 1024px) {
  .hero-footer {
    padding: var(--space-5) 0;
  }
}

.hero-footer-container {
  max-width: var(--container-7xl);
  margin: 0 auto;
  padding: 0 var(--space-6);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

@media (min-width: 640px) {
  .hero-footer-container {
    padding: 0 var(--space-8);
  }
}

@media (min-width: 1024px) {
  .hero-footer-container {
    padding: 0 var(--space-12);
  }
}

/* Copyright - Bottom left */
.hero-copyright {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.58);
  font-weight: 400;
  letter-spacing: 0.015em;
  transition: color var(--transition-fast);
}

/* Dark copyright for white slide */
.hero-footer-dark .hero-copyright {
  color: rgba(26, 58, 92, 0.65);
}

/* Mobile: Dark copyright text on white footer */
@media (max-width: 767px) {
  .hero-copyright {
    color: rgba(26, 58, 92, 0.7);
  }
}

@media (min-width: 768px) {
  .hero-copyright {
    font-size: 0.8125rem;
  }
}

/* Social Media Icons - Bottom right, minimal */
.hero-social {
  display: flex;
  gap: var(--space-2);
  align-items: center;
}

@media (min-width: 768px) {
  .hero-social {
    gap: var(--space-3);
  }
}

.hero-social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.6);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  text-decoration: none;
}

.hero-social-link:hover {
  background-color: rgba(255, 255, 255, 0.12);
  color: var(--color-gold);
  transform: translateY(-2px);
}

/* Dark social icons for white slide */
.hero-footer-dark .hero-social-link {
  background-color: rgba(26, 58, 92, 0.08);
  color: rgba(26, 58, 92, 0.7);
}

.hero-footer-dark .hero-social-link:hover {
  background-color: rgba(26, 58, 92, 0.15);
  color: var(--color-gold);
}

/* Mobile: Dark social icons on white footer */
@media (max-width: 767px) {
  .hero-social-link {
    background-color: rgba(26, 58, 92, 0.08);
    color: rgba(26, 58, 92, 0.7);
  }

  .hero-social-link:hover {
    background-color: rgba(26, 58, 92, 0.15);
    color: var(--color-gold);
  }
}

.hero-social-link svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
}

/* ============================================
   ANIMATIONS
   ============================================ */

@keyframes slideUpFadeIn {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */

.hero-pagination-dot:focus-visible {
  outline: 2px solid var(--color-gold);
  outline-offset: 4px;
}

.hero-cta:focus-visible {
  outline: 2px solid var(--color-gold);
  outline-offset: 4px;
  border-radius: var(--border-radius-sm);
}

.hero-social-link:focus-visible {
  outline: 2px solid var(--color-gold);
  outline-offset: 4px;
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
  .hero-slide,
  .hero-text-content,
  .hero-cta,
  .hero-social-link,
  .hero-pagination-dot,
  .hero-pagination-label {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
