/* ==========================================================
   VARIABLES
   ========================================================== */
:root {
  --container-max-width: 1400px;
  --gutter: 0;
  --outer-padding: 1rem;
  --break-sm: 768px;
  --break-md: 992px;
  --break-lg: 1200px;
  --break-xl: 1400px;
}

/* ==========================================================
   GLOBAL STYLES
   ========================================================== */
* {
  box-sizing: border-box;
}

html,
body {
  color: rgba(16, 16, 17, 1);
  font-family: "Poppins", sans-serif;
  font-size: 16px;
  height: 100%;
  margin: 0;
  padding: 3% 0 0 0;
}

footer {
  background-color: rgba(35, 84, 134, 1);
  color: #fff;
  padding: 3% 0;
  text-align: center;
}

h1 {
  color: #fff;
}
h2 {
  color: rgba(35, 84, 134, 1);
}
h3 {
  color: rgba(117, 170, 66, 1);
  text-transform: uppercase;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

#contact {
  background-image: url("/images/contact.webp");
  background-size: cover;
  background-position: center;
  color: #ffffff;
  padding: 4% 2% 5% 2%;
  text-align: center;
}

#contact h2,
a {
  color: #ffffff;
}

.accent {
  background-color: rgba(93, 143, 203, 0.2);
}

.animated-number {
  font-size: 8rem;
  font-weight: 600;
}

.hero {
  text-align: center;
}

.icon {
  max-width: 250px;
  margin: 0 auto;
}

.container {
  max-width: var(--container-max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--outer-padding);
  padding-right: var(--outer-padding);
  width: 100%;
}

.padded-div {
  padding: 5% 2%;
}
.padded-copy {
    padding: 0 20px;
}

/* ==========================================================
   HERO VIDEO SECTION
   ========================================================== */
#hero {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}

#hero .video-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

#hero .video-container video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

#header-video {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.4);
  z-index: 1;
}

#header-video h1 {
  font-size: clamp(2rem, 5vw, 4rem);
  text-align: center;
  line-height: 1.4;
  color: #fff;
  margin: 0;
}

#header-video .line {
  display: block;
  opacity: 0;
  visibility: visible;
  animation: fadeInStable 1.5s ease-in-out forwards;
}

@keyframes fadeInStable {
  from {
    opacity: 0;
    visibility: visible;
  }
  to {
    opacity: 1;
    visibility: visible;
  }
}

/* Process Video Section - Prevent Overlap */
#process-video {
  position: relative;
  z-index: 1;
}

#process-video video {
  position: relative;
  width: 100%;
  height: auto;
}

/* ==========================================================
   NAVIGATION BAR
   ========================================================== */
.navbar {
  position: fixed;
  top: 0;
  width: 100%;
  background: #ffffff;
  z-index: 10000;
  transition: box-shadow 0.4s ease, background 0.3s ease, opacity 0.4s ease;
  padding: 1rem;
}

.navbar.scrolled {
  box-shadow: 0 6px 25px rgba(0, 0, 0, 0.08);
  animation: shadowFadeIn 0.4s ease forwards;
  opacity: 1;
}

@keyframes shadowFadeIn {
  from {
    box-shadow: 0 0 0 rgba(0, 0, 0, 0);
  }
  to {
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.08);
  }
}

.nav-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  align-items: center;
  min-height: 60px;
}

.nav-logo a {
  display: block;
  align-items: center;
  height: 100%;
}

.nav-links {
  position: relative;
  text-align: right;
}

.nav-links ul {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 1.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.social-nav-links ul {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 15px;
  justify-content: flex-end;
}

.social-nav-links a {
  transition: filter 0.3s ease;
}

.social-nav-links a:hover img {
  filter: brightness(0) saturate(100%) invert(56%) sepia(89%) saturate(1612%) hue-rotate(360deg)
    brightness(98%) contrast(101%);
}

.nav-links a {
  text-decoration: none;
  color: rgba(35, 84, 134, 1);
  font-weight: 500;
  white-space: nowrap;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: rgba(117, 170, 66, 1);
}

/* Hamburger button */
.hamburger {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 30px;
  height: 40px;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 10001;
  flex-shrink: 0;
}

.hamburger span {
  height: 3px;
  width: 100%;
  background: #333;
  border-radius: 3px;
  transition: all 0.3s ease;
  margin: 2px 0;
}

.hamburger.open {
  position: fixed;
  top: 1rem;
  right: 1rem;
}

.hamburger.open span:nth-child(1) {
  transform: rotate(45deg) translateY(7px);
}

.hamburger.open span:nth-child(2) {
  opacity: 0;
}

.hamburger.open span:nth-child(3) {
  transform: rotate(-45deg) translateY(-7px);
}

/* Mobile nav styling */
.nav-grid {
  grid-template-columns: 1fr auto;
  gap: 1rem;
}

.nav-logo {
  grid-column: 1;
  display: flex;
  align-items: center;
}

.nav-links {
  grid-column: 2;
  display: flex;
  align-items: center;
  text-align: right;
}

.nav-links ul {
  display: none;
}

/* Sliding menu panel */
.nav-links.open ul {
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: fixed;
  top: 0;
  right: 0;
  width: 70%;
  max-width: 300px;
  height: 100vh;
  padding: 1.5rem;
  background: #ffffff;
  box-shadow: -4px 0 15px rgba(0, 0, 0, 0.1);
  z-index: 10000;
  animation: slideIn 0.4s forwards ease;
}

.nav-links ul li {
  width: 100%;
  text-align: left;
}

.nav-links ul li a {
  display: block;
  padding: 0.75rem 0;
}

@keyframes slideIn {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  z-index: 9999;
}

.nav-overlay.active {
  opacity: 1;
  pointer-events: all;
}

/* ==========================================================
   GRID SYSTEM (FIXED)
   ========================================================== */
.grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--gutter);
  align-items: stretch;
}

.grid > * {
  width: 100%;
}

/* MOBILE: Full-width by default */
.col-1,
.col-2,
.col-3,
.col-4,
.col-5,
.col-6,
.col-7,
.col-8,
.col-9,
.col-10,
.col-11,
.col-12 {
  grid-column: span 12;
}

/* --------------------------------------
   Breakpoint: SM (≥768px)
   -------------------------------------- */
@media (min-width: 768px) {
  .col-sm-1 { grid-column: span 1; }
  .col-sm-2 { grid-column: span 2; }
  .col-sm-3 { grid-column: span 3; }
  .col-sm-4 { grid-column: span 4; }
  .col-sm-5 { grid-column: span 5; }
  .col-sm-6 { grid-column: span 6; }
  .col-sm-7 { grid-column: span 7; }
  .col-sm-8 { grid-column: span 8; }
  .col-sm-9 { grid-column: span 9; }
  .col-sm-10 { grid-column: span 10; }
  .col-sm-11 { grid-column: span 11; }
  .col-sm-12 { grid-column: span 12; }
}

/* --------------------------------------
   Breakpoint: MD (≥992px)
   -------------------------------------- */
@media (min-width: 992px) {
  .col-md-1 { grid-column: span 1; }
  .col-md-2 { grid-column: span 2; }
  .col-md-3 { grid-column: span 3; }
  .col-md-4 { grid-column: span 4; }
  .col-md-5 { grid-column: span 5; }
  .col-md-6 { grid-column: span 6; }
  .col-md-7 { grid-column: span 7; }
  .col-md-8 { grid-column: span 8; }
  .col-md-9 { grid-column: span 9; }
  .col-md-10 { grid-column: span 10; }
  .col-md-11 { grid-column: span 11; }
  .col-md-12 { grid-column: span 12; }
}

/* --------------------------------------
   Breakpoint: LG (≥1200px)
   -------------------------------------- */
@media (min-width: 1200px) {
  h1 { font-size: 4rem; }
  h2 { font-size: 2rem; }
  h3 { font-size: 1.4rem; }

  /* Desktop nav layout fix */
  .nav-grid {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    min-height: 60px;
    grid-template-columns: none !important;
  }
 
  .nav-logo {
    display: flex;
    align-items: center;
    order: 1;
    flex: 0 0 auto;
  }

  .nav-links {
    order: 2;
    flex: 1 1 auto;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    position: static !important;
    text-align: right;
  }

  .nav-links ul {
    display: flex !important;
    flex-direction: row !important;
    gap: 2rem;
    margin: 0;
    padding: 0;
    list-style: none;
    position: static !important;
    width: auto !important;
    height: auto !important;
    background: transparent !important;
    box-shadow: none !important;
    transform: none !important;
    animation: none !important;
  }

  .nav-links ul li {
    width: auto;
    text-align: right;
  }

  .nav-links ul li a {
    padding: 0.125rem 0;
  }

  .nav-links.open ul {
    position: static !important;
    width: auto !important;
    height: auto !important;
    right: auto !important;
    top: auto !important;
    padding: 0 !important;
    box-shadow: none !important;
    transform: none !important;
  }

  .hamburger {
    display: none !important;
  }

  .nav-overlay {
    display: none !important;
    pointer-events: none !important;
    opacity: 0 !important;
  }

  /* Grid for large screens */
  .col-lg-1 { grid-column: span 1; }
  .col-lg-2 { grid-column: span 2; }
  .col-lg-3 { grid-column: span 3; }
  .col-lg-4 { grid-column: span 4; }
  .col-lg-5 { grid-column: span 5; }
  .col-lg-6 { grid-column: span 6; }
  .col-lg-7 { grid-column: span 7; }
  .col-lg-8 { grid-column: span 8; }
  .col-lg-9 { grid-column: span 9; }
  .col-lg-10 { grid-column: span 10; }
  .col-lg-11 { grid-column: span 11; }
  .col-lg-12 { grid-column: span 12; }
}

/* --------------------------------------
   Breakpoint: XL (≥1400px)
   -------------------------------------- */
@media (min-width: 1400px) {
  .col-xl-1 { grid-column: span 1; }
  .col-xl-2 { grid-column: span 2; }
  .col-xl-3 { grid-column: span 3; }
  .col-xl-4 { grid-column: span 4; }
  .col-xl-5 { grid-column: span 5; }
  .col-xl-6 { grid-column: span 6; }
  .col-xl-7 { grid-column: span 7; }
  .col-xl-8 { grid-column: span 8; }
  .col-xl-9 { grid-column: span 9; }
  .col-xl-10 { grid-column: span 10; }
  .col-xl-11 { grid-column: span 11; }
  .col-xl-12 { grid-column: span 12; }
}

/* ==========================================================
   UTILITY CLASSES
   ========================================================== */
.grid--full {
  width: 100%;
  margin-left: calc(var(--outer-padding) * -1);
  margin-right: calc(var(--outer-padding) * -1);
}

.align-center {
  align-self: center;
  justify-self: center;
}

.align-start {
  align-self: start;
  justify-self: start;
}

.align-end {
  align-self: end;
  justify-self: end;
}
