/* Header / Hero Section Styles */
.hero-section {
  position: relative;
  height: 100vh;
  max-height: 1024px;
  display: flex;
  flex-direction: column;
  background: url('../assets/images/hero.webp') left/cover;
  background-color: #1a1a2e;
  background-position: bottom left;
  color: white;
  align-items: center;
  text-align: center;
  padding: 36px 40px;
  overflow: hidden;
}

/* Gradient overlay filter */
.hero-section::before {
  display: none;
}

/* Background decorative circles (vectors) */
.hero-section::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* TODO: Add PNG fallback for iOS Safari - hero SVGs use filters */
  background-image: url('../assets/svg/hero-top-left.svg'),
    url('../assets/svg/hero-top-right.svg');
  /* Fallbacks: url('../assets/images/hero-top-left@2x.png'), url('../assets/images/hero-top-right@2x.png') */
  background-position: top left, top right;
  background-repeat: no-repeat;
  background-size: auto, auto;
  z-index: 2;
  pointer-events: none;
}

.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  padding: 0;
  z-index: 1000;
  display: flex;
  justify-content: center;
  transition: background 0.3s ease;
}

.navbar.scrolled {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.nav-container {
  box-sizing: border-box;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  padding: 0 42.9647px;
  gap: 28.64px;
  position: absolute;
  height: 64px;
  left: calc(50% - 702.6px / 2);
  top: 36.22px;
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 56.6896px;
  flex: none;
  z-index: 6;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  transition: background 0.3s ease, border-color 0.3s ease;
}

.navbar.scrolled .nav-container {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.logo {
  width: 158px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex: none;
  order: 0;
  flex-grow: 0;
}

.logo-image {
  width: 158px;
  height: 32px;
  display: block;
  border-radius: 0;
  object-fit: contain;
  transition: opacity 0.3s ease; /* smooth change on scroll */
}

/* Object fallback styling for iOS Safari */
.logo-image object {
  width: 100%;
  height: 100%;
  display: block;
}

.logo.has-image .logo-image {
  opacity: 1;
}

.logo.has-image .logo-text {
  display: none; /* Hide text when logo image exists */
}

.logo-text {
  display: inline-block;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 28.64px;
  margin: 0;
  padding: 0;
  align-items: center;
  flex: none;
}

.nav-menu li {
  margin: 0;
  flex: none;
  flex-grow: 0;
}

.nav-menu a {
  font-family: 'Manrope', sans-serif;
  font-style: normal;
  font-weight: 700;
  font-size: clamp(16px, 2vw, 24px);
  line-height: clamp(24px, 3vw, 48px);
  color: #ffffff;
  text-decoration: none;
  white-space: nowrap;
  display: block;
  transition: color 0.3s ease;
}

.navbar.scrolled .nav-menu a {
  color: #111113;
}

.nav-menu a:hover {
  color: #3a7cff;
}

.navbar.scrolled .nav-menu a:hover {
  color: #3a7cff;
}

.nav-right {
  display: none;
  align-items: center;
  gap: 1rem;
}

.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 5px;
}

.hamburger span {
  width: 25px;
  height: 3px;
  background: white;
  transition: 0.3s;
}

.navbar.scrolled .hamburger span {
  background: #1a1a2e;
}

.hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
  max-width: 100%;
  width: 1142px;
  z-index: 10;
  margin-top: 104px;
}

.hero-title {
  width: 337px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
}

/* Object fallback styling for iOS Safari */
.hero-title object {
  width: 100%;
  height: auto;
  display: block;
}

.hero-subtitle {
  font-family: 'Manrope', sans-serif;
  font-style: normal;
  font-weight: 700;
  font-size: 80px;
  line-height: 96px;
  text-align: center;
  letter-spacing: 0.01em;
  color: #ffffff;
}

.cta-button {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  padding: 24px 56px;
  gap: 10px;
  background: #ffffff;
  border-radius: 40px;
  border: none;
  cursor: pointer;
  transition: transform 0.3s, box-shadow 0.3s, background 0.3s;
  flex: none;
  order: 2;
  flex-grow: 0;
  justify-content: center;
}

.cta-button span {
  font-family: 'Manrope', sans-serif;
  font-style: normal;
  font-weight: 600;
  font-size: 32px;
  line-height: 40px;
  color: #111113;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
  order: 0;
  flex-grow: 0;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
  background: #f0f5ff;
}

/* Tablet Styles */
@media (max-width: 768px) {
  .hero-section {
    padding: 36px 20px;
    background: url('../assets/images/hero-tablet.webp') left/cover;
  }

  /* Hide right vector on tablet and mobile */
  .hero-section::after {
    background-image: url('../assets/svg/hero-top-left.svg');
    background-position: top left;
  }

  .navbar {
    padding: 0;
    top: 0;
  }

  .nav-container {
    box-sizing: border-box;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    gap: 0;
    width: 100%;
    position: relative;
    left: auto;
    top: 0;
    transform: none;
    background: #010b4d;
    border: none;
    border-radius: 0;
    z-index: 9;
  }

  .logo {
    width: 158px;
    height: 32px;
    flex: none;
    order: 0;
    flex-grow: 0;
  }

  .logo-image {
    width: 158px;
    height: 32px;
    border-radius: 0;
  }

  .nav-menu {
    position: fixed;
    left: -100%;
    top: 64px;
    flex-direction: column;
    background-color: #010b4d;
    width: 100%;
    height: calc(100vh - 64px);
    text-align: left;
    transition: 0.3s;
    padding: 2rem 20px;
    gap: 1rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    align-items: flex-start;
    overflow-y: auto;
  }

  .navbar.scrolled .nav-menu a {
    color: #ffffff;
  }

  .nav-menu.active {
    left: 0;
  }

  .nav-menu li {
    width: 100%;
  }

  .nav-menu a {
    font-size: clamp(16px, 3vw, 20px);
    width: auto !important;
    text-align: left;
  }

  .nav-right {
    display: flex;
    width: auto;
    height: 24px;
    flex: none;
    order: 1;
    flex-grow: 0;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 0;
  }

  .hamburger {
    display: flex;
    width: 24px;
    height: 24px;
    position: relative;
    flex: none;
    order: 2;
    flex-grow: 0;
    gap: 0;
  }

  .hamburger span {
    position: absolute;
    left: 12.5%;
    right: 12.5%;
    width: 75%;
    height: 2px;
    background: #ffffff;
    transition: 0.3s;
  }

  .hamburger span:nth-child(1) {
    top: 28.12%;
  }

  .hamburger span:nth-child(2) {
    top: 50%;
    transform: translateY(-50%);
  }

  .hamburger span:nth-child(3) {
    bottom: 28.12%;
  }

  /* Adjust hero content spacing and vector position */
  .hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 32px;
    z-index: 10;
    margin-top: 210px;
  }

  .hero-section::after {
    top: 64px;
  }

  .hero-title {
    width: 280px;
  }

  .hero-subtitle {
    font-family: 'Manrope', sans-serif;
    font-style: normal;
    font-weight: 600;
    font-size: 56px;
    line-height: 68px;
    text-align: center;
    color: #ffffff;
    max-width: 700px;
    margin: 0 auto;
  }

  .cta-button {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    padding: 24px 56px;
    gap: 10px;
    background: #ffffff;
    border-radius: 40px;
    border: none;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s, background 0.3s;
    flex: none;
    order: 2;
    flex-grow: 0;
    justify-content: center;
  }

  .cta-button span {
    font-family: 'Manrope', sans-serif;
    font-style: normal;
    font-weight: 600;
    font-size: 24px;
    line-height: 32px;
    color: #111113;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: none;
    order: 0;
    flex-grow: 0;
  }
}

/* Mobile Styles */
@media (max-width: 480px) {
  .hero-section {
    background: url('../assets/images/hero-mobile.webp') left/cover;
  }

  .nav-container {
    width: 100%;
    padding: 0 20px;
  }

  .nav-menu {
    padding: 2rem 20px;
  }

  .navbar.scrolled .nav-menu a {
    color: #ffffff;
  }

  .hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
    flex-grow: 1;
    z-index: 10;
    margin-top: 210px;
    box-sizing: border-box;
  }

  .hero-section {
    padding: 36px 20px;
  }

  .hero-section::after {
    top: 32px;
  }

  .hero-title {
    width: 235px;
  }

  .hero-subtitle {
    font-family: 'Manrope', sans-serif;
    font-style: normal;
    font-weight: 600;
    font-size: 40px;
    line-height: 49px;
    text-align: center;
    color: #ffffff;
  }

  .cta-button {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 8px 56px;
    width: 100%;
    background: #ffffff;
    border-radius: 40px;
    border: none;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s, background 0.3s;
    margin-top: 8px;
  }

  .cta-button span {
    width: 100%;
    font-family: 'Manrope', sans-serif;
    font-style: normal;
    font-weight: 600;
    font-size: 24px;
    line-height: 32px;
    color: #111113;
  }
}
