@import url('https://fonts.googleapis.com/css2?family=Familjen+Grotesk:wght@400;600;700&display=swap');

:root {
  --color-white: #fff;
  --color-black: #000;
}

html {
  box-sizing: border-box;
  scroll-behavior: smooth;
  scroll-snap-type: y mandatory;
}

*,
*::before,
*::after {
  box-sizing: inherit;
}

body {
  background: var(--color-black);
  color: var(--color-white);
  font-family: 'Familjen Grotesk', sans-serif;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: var(--color-white);
}

ul {
  list-style: none;
}

/* Header & Navbar */

.main-header {
  position: fixed;
  top: 0;
  left: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 3;
  width: 100%;
  height: 100px;
  padding: 0 30px;
}

/* Logo */

.logo {
  width: 210px;
  height: auto;
}

.logo img {
  display: block;
  width: 100%;
  height: auto;
}

/* Desktop Menu */

.desktop-main-menu {
  margin-right: 50px;
}

.desktop-main-menu ul {
  display: flex;
}

.desktop-main-menu ul li {
  position: relative;
  margin-right: 20px;
  padding-bottom: 2px;
}

/* Menu Item Bottom Border */

.desktop-main-menu ul li a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 1px;
  background: var(--color-white);
  transform: scaleX(0);
  transition: transform 0.6s cubic-bezier(0.19, 1, 0.22, 1);
  transform-origin: right center;
}

.desktop-main-menu ul li a:hover::after {
  transform: scaleX(1);
  transform-origin: left center;
  transition-duration: 0.4s;
}

/* Sections */

section {
  position: relative;
  height: 100vh;
  height: 100dvh;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  scroll-snap-align: start;
}

footer {
  scroll-snap-align: end;
}

.section-inner {
  position: absolute;
  bottom: 200px;
  left: 150px;
  max-width: 560px;
}

.section-inner h4 {
  font-size: 22px;
  font-weight: 300;
  margin-bottom: 5px;
}

.section-inner h2 {
  font-size: 50px;
  margin-top: 0;
  margin-bottom: 16px;
  line-height: 1.05;
}

.section-a .section-inner h4 {
  margin-bottom: 8px;
  line-height: 1.15;
}

.section-inner .section-copy {
  font-size: 16px;
  font-weight: 400;
  line-height: 1.65;
  margin: 0 0 22px;
  max-width: 520px;
  color: rgba(255, 255, 255, 0.9);
}

/* Scroll-triggered reveal: staggered children */
.reveal > * {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.is-visible > *:nth-child(1) { transition-delay: 0s; }
.reveal.is-visible > *:nth-child(2) { transition-delay: 0.12s; }
.reveal.is-visible > *:nth-child(3) { transition-delay: 0.24s; }
.reveal.is-visible > *:nth-child(4) { transition-delay: 0.36s; }

.reveal.is-visible > * {
  opacity: 1;
  transform: translateY(0);
}

/* CTA arrow micro-interaction */
.btn {
  transition: border-color 0.4s cubic-bezier(0.19, 1, 0.22, 1);
}

.btn-arrow {
  display: inline-block;
  transition: transform 0.35s cubic-bezier(0.19, 1, 0.22, 1);
  margin-left: 4px;
}

.btn:hover .btn-arrow {
  transform: translateX(5px);
}

.section-inner a {
  /* no load animation — handled by reveal */
}

/* Section dot navigation */
.section-dots {
  position: fixed;
  right: 28px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.5);
  background: transparent;
  cursor: pointer;
  padding: 0;
  transition: background 0.35s, border-color 0.35s, transform 0.35s;
}

.dot:hover {
  border-color: var(--color-white);
  transform: scale(1.3);
}

.dot.active {
  background: var(--color-white);
  border-color: var(--color-white);
}

/* Background Images */

.section-a {
  overflow: hidden;
}

.section-a::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.28);
  z-index: 1;
}

.section-a-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.section-a .section-inner,
.section-a .scroll-arrow {
  z-index: 2;
}

.section-b {
  overflow: hidden;
}

.section-b::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.28);
  z-index: 1;
}

.section-b-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.section-b .section-inner,
.section-b .scroll-arrow {
  z-index: 2;
}

.section-c {
  overflow: hidden;
}

.section-c::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.28);
  z-index: 1;
}

.section-c-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.section-c .section-inner,
.section-c .scroll-arrow {
  z-index: 2;
}

.section-d {
  background-image: url('../media/section-d.webp');
}

.section-e {
  background-image: url('../media/section-e.webp');
}

.section-f {
  background-image: url('../media/section-f.webp');
}

.btn {
  position: relative;
  display: inline-block;
  cursor: pointer;
  text-align: center;
  min-width: 130px;
  padding: 15px 50px;
  margin-top: 10px;
  border: 2px solid var(--color-white);
  font-weight: 700;
  overflow: hidden;
  z-index: 2;
}

.btn:hover span {
  color: var(--color-black);
}

.btn .hover {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--color-white);
  color: var(--color-black);
  z-index: -1;
  transform: translateY(100%);
  transition: transform 0.6s cubic-bezier(0.19, 1, 0.22, 1);
}

.btn:hover .hover {
  transform: translateY(0);
}

.scroll-arrow {
  position: absolute;
  bottom: 50px;
  left: 50%;
  transform: translateX(-50%);
  animation: gentleBounce 2.4s cubic-bezier(0.45, 0, 0.55, 1) infinite;
  cursor: pointer;
  z-index: 2;
  opacity: 0.7;
  transition: opacity 0.3s;
}

.scroll-arrow:hover {
  opacity: 1;
}

/* Footer */

footer {
  position: relative;
  padding: 55px 0;
}

footer ul {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
}

footer ul li {
  color: #aaa;
  font-size: 13px;
  line-height: 2.5;
  margin-right: 30px;
  text-transform: uppercase;
}

footer ul li a {
  color: var(--color-white);
  transition: color 0.6s;
}

footer ul li a:hover {
  color: #aaa;
}

/* Hamburger Menu */

.hamburger {
  position: fixed;
  top: 40px;
  right: 16px;
  z-index: 10;
  cursor: pointer;
  width: 44px;
  height: 44px;
  padding: 12px;
  background: none;
  border: none;
  box-sizing: border-box;
}

.hamburger-top,
.hamburger-middle,
.hamburger-bottom {
  position: absolute;
  width: 20px;
  height: 2px;
  top: 11px;
  left: 12px;
  background: var(--color-white);
  transition: all 0.5s;
}

.hamburger-middle {
  transform: translateY(5px);
}

.hamburger-bottom {
  transform: translateY(10px);
}

.open {
  transform: rotate(90deg);
}

.open .hamburger-top {
  transform: rotate(45deg) translateY(6px) translateX(6px);
}

.open .hamburger-middle {
  display: none;
}

.open .hamburger-bottom {
  transform: rotate(-45deg) translateY(6px) translateX(-6px);
}

/* Overlay */

.overlay-show {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 3;
}

.stop-scrolling {
  overflow: hidden;
}

/* Hide Mobile Main Items */

.mobile-only {
  display: none;
}

/* Mobile Menu */

.mobile-main-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: min(350px, 100vw);
  max-width: 100%;
  height: 100%;
  height: 100dvh;
  background-color: var(--color-black);
  z-index: 4;
  display: flex;
  justify-content: center;
  align-items: center;
  transform: translateX(100%);
  transition: transform 0.6s cubic-bezier(0.19, 1, 0.22, 1);
}

/* Bring Menu from Right */

.show-menu {
  transform: translateX(0);
}

.mobile-main-menu ul {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: center;
  padding: 50px;
  width: 100%;
}

.mobile-main-menu ul li {
  border-bottom: 1px dotted #555;
  font-size: 18px;
  margin-bottom: 20px;
  padding-bottom: 8px;
  text-align: right;
  width: 100%;
}

.mobile-main-menu ul li a {
  color: var(--color-white);
  transition: color 0.6s;
}

.mobile-main-menu ul li a:hover {
  color: #aaa;
}

/* Inner Pages */

.bg-falcon-9 {
  background-image: url('../media/falcon-9.webp');
}

.bg-falcon-heavy {
  background-image: url('../media/falcon-heavy.webp');
}

.bg-dragon {
  background-image: url('../media/dragon.webp');
}

.section-animate {
  animation: fadeIn 2s ease-in-out;
}

.section-inner-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  width: 80%;
}

.section-inner-center h3 {
  font-size: 100px;
  margin-bottom: 15px;
  animation: fadeInUp 0.5s ease-in-out;
}

.section-inner-center p {
  font-size: 20px;
  animation: fadeInUp 0.5s ease-in-out 0.2s;
  animation-fill-mode: both;
}

/* Stats */

.stats {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-align: center;
}

.stats div span {
  font-size: 160px;
}

.stats div h4 {
  font-size: 24px;
  font-weight: 300;
}

/* Animations */

@keyframes fadeInUp {
  0% {
    opacity: 0;
    transform: translateY(140px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

@keyframes fadeBounce {
  0%,
  20%,
  50%,
  80%,
  100% {
    opacity: 0;
    transform: translateY(-20px);
  }

  40% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes gentleBounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50%      { transform: translateX(-50%) translateY(8px); }
}

/* Subtle video scale on section entry */
section video {
  transition: transform 8s cubic-bezier(0.16, 1, 0.3, 1);
  transform: scale(1.05);
}

section.in-view video {
  transform: scale(1);
}

/* prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
    scroll-snap-type: none;
  }

  .reveal > * {
    opacity: 1;
    transform: none;
    transition: none;
  }

  section video {
    transform: none;
    transition: none;
  }

  .scroll-arrow {
    animation: none;
  }

  .btn-arrow {
    transition: none;
  }

  .dot {
    transition: none;
  }
}

/* Media Queries */

@media (max-width: 960px) {
  /* Hide Desktop Menu */

  .desktop-main-menu {
    display: none;
  }

  /* Show Mobile Main Items */

  .mobile-only {
    display: block;
  }

  .main-header {
    padding: 0 56px 0 16px;
    height: 88px;
  }

  .logo {
    width: min(180px, 42vw);
  }

  .section-inner {
    left: 40px;
    right: 40px;
    bottom: 130px;
    max-width: none;
    width: auto;
  }

  .section-inner h2 {
    font-size: clamp(32px, 6vw, 44px);
  }

  .section-inner-center h3 {
    font-size: 75px;
  }

  .section-dots {
    right: 16px;
  }
}

@media (max-width: 600px) {
  .section-dots {
    display: none;
  }

  .main-header {
    padding: 0 max(52px, calc(env(safe-area-inset-right, 0px) + 44px)) 0 max(14px, env(safe-area-inset-left, 0px));
    height: 80px;
  }

  .hamburger {
    top: max(22px, env(safe-area-inset-top, 0px));
    right: max(10px, env(safe-area-inset-right, 0px));
  }

  .section-inner {
    bottom: max(88px, env(safe-area-inset-bottom, 0px));
    left: max(20px, env(safe-area-inset-left, 0px));
    right: max(20px, env(safe-area-inset-right, 0px));
  }

  .section-inner h2 {
    font-size: clamp(26px, 9vw, 36px);
    margin-bottom: 12px;
  }

  .section-inner .section-copy {
    font-size: 15px;
    line-height: 1.55;
    margin: 0 0 18px;
    max-width: none;
  }

  .btn {
    padding: 12px 28px;
    min-width: 0;
    width: 100%;
    max-width: 280px;
    box-sizing: border-box;
  }

  .scroll-arrow {
    bottom: 28px;
  }

  footer {
    padding: 72px max(16px, env(safe-area-inset-right, 0px))
      max(48px, env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
  }

  footer ul {
    flex-direction: column;
    align-items: center;
    gap: 4px 0;
  }

  footer ul li:first-child {
    position: static;
    transform: none;
    margin-right: 0;
    margin-bottom: 12px;
    text-align: center;
    width: 100%;
  }

  footer ul li {
    margin-right: 0;
    line-height: 2;
    text-align: center;
  }

  .logo {
    width: 140px;
    margin: 0;
  }

  .section-inner-center h3 {
    font-size: 50px;
  }

  .stats {
    flex-direction: column;
  }

  .stats div {
    margin-bottom: 20px;
  }
}
