header, footer {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  width: 100vw;
  
}


  /* =========================================================
     Typography & Utilities
     ========================================================= */
  a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
  }
  
  img {
    display: block;
    max-width: 100%;
    height: auto;
    object-fit: contain;
  }
  
  .secondary-button {
    padding: 0.5rem 1rem;
    border: none;
    background-color: #fff;
    color: #000;
    cursor: pointer;
    border-radius: 5px;
    margin-top: 1rem;
  }
  
  /* =========================================================
     Header
     ========================================================= */

  
  .logo {
    cursor: pointer;
    
    
  }
  .logo a {
    display: inline-block;
    transition: transform 0.3s ease;
  }
  .logo a:hover {
    transform: scale(1.05);
  }
  .logo img {
    width: 200px;
    height: 200px;
    object-fit: cover;
  }

  header {
    font-family: lexend deca;
    font-weight: regular;
    display: flex; 
    justify-content: space-evenly; 
    align-items: center; 
    padding: 1rem 1rem;
    border-bottom: 1px solid #333;
    padding-bottom: 5px;
    gap: 0rem;
    top: 0;
    width: 100vw;
    background: #000;
    color: #fff;
   
    
  }
  
  /* Navigation */
  header ul {
    list-style: none;
    display: flex;
    /* gap between header */
    gap: 0px;
    /* margin-right: 95px; */
  }

  header ul li{
    margin-top: 5px;
    margin-right: 200px;
  }
/*   
  header a{
    gap: 686px;
  } */

  header ul li a {
    display: inline-flex;         /* center text neatly */
    align-items: center;          /* vertical centering */
    justify-content: center;
    padding: 0.5rem 1.25rem;      /* same padding for all links */
    line-height: 1;               /* prevent extra vertical height */
    text-decoration: none;
    font-size: 19px;
    color: #fff;
    transition: color 0.2s, background-color 0.2s, box-shadow 0.2s;
  }
  header ul li a:hover {
    color: #36c3ff;
    background-color: transparent;          /* no bg on normal links */
  }
  
  /* CTA Buttons in Header */
  header .wwu-button {     
    font-weight: bold;
    padding: 0.5rem 1rem;
    background-color: #000;     
    color: #fff;     
    border: 3px solid #fff;     
    border-radius: 30px;     
    font-size: 19px;
    cursor: pointer;     
    transition: all 0.3s ease;
    margin-right: 100px;
}  
  header .wwu-button:hover {     
    background-color: #fff;     
    color: #000;
  }
  
  header .apply-button {
    font-weight: bold;
    padding: 0.5rem 1rem;
    background-color: #fff;
    color: #000;
    border: 3px solid #fff;
    border-radius: 30px;
    font-size: 19px;
    cursor: pointer;
    transition: background-color 0.3s;
    margin-right: 2rem;
  }
  header .apply-button:hover {
    background-color: #36c3ff;
  }


/* Remove ring from Work With Us button */
header .wwu-button {
  border: none !important;
  box-shadow: none !important;
}

/* Add ring to Contact link */
header .nav-contact-ring {
  display: inline-block;
  padding: 8px 18px;
  border: 2px solid #ffffff;
  border-radius: 40px;
  text-decoration: none;
  color: #ffffff !important;
  font-family: 'Lexend Deca', sans-serif;
  font-size: 19px; /* was 16px — match other nav items */
  line-height: 1;
  transition: background .25s, color .25s;
}

header .nav-contact-ring:hover {
  background: #ffffff;
  color: #000000 !important;
}

/* Base layout for all nav links: consistent vertical alignment and padding */
header ul li a {
  display: inline-flex;         /* center text neatly */
  align-items: center;          /* vertical centering */
  justify-content: center;
  padding: 0.5rem 1.25rem;      /* same padding for all links */
  line-height: 1;               /* prevent extra vertical height */
  text-decoration: none;
  font-size: 19px;
  color: #fff;
  transition: color 0.2s, background-color 0.2s, box-shadow 0.2s;
}

/* Invisible ring baseline for alignment */
header .nav-contact-ring {
  border: none;                           /* ensure no layout-changing border */
  box-shadow: 0 0 0 1.5px transparent;  /* invisible ring */
  border-radius: 999px;                   /* pill shape for all links */
}

/* Visible ring: Contact + Apply */
header .nav-contact-ring.nav-ring-visible {
  box-shadow: 0 0 0 1.5px white;
}

/* Not visible ring: Join Us, About Us, Work With Us */
header .nav-contact-ring.nav-ring-not-visible {
  box-shadow: 0 0 0 1.5px transparent !important; /* no ring */
  border: none !important;
  background: transparent !important;
}

/* Hover: not visible -> blue text only (no bg, no ring) */
header .nav-contact-ring.nav-ring-not-visible:hover {
  color: #36c3ff !important;
  background: transparent !important;
  box-shadow: none !important;
}

/* Hover: visible ring can have subtle purple bg */

/* Desktop: default hover for non-visible-ring links (blue text) remains via existing rule */
/* Ensure Contact (visible ring) gets white button hover */
header .nav-contact-ring.nav-ring-visible[href*="contact"]:hover {
  background: #ffffff !important;
  color: #000000 !important;
  box-shadow: 0 0 0 1.5px #ffffff !important;
}

/* Apply now matches Contact on desktop */
header .nav-contact-ring.nav-ring-visible[href*="apply"]:hover {
  background: #ffffff !important;
  color: #000000 !important;
  box-shadow: 0 0 0 1.5px #ffffff !important;
}

/* Restore Apply hover effect: keep Apply default as white pill with black text; on hover, use the site blue background (#36c3ff) with black text. Applies on desktop and hamburger. */
/* Apply default: white pill with black text */
header .nav-contact-ring.nav-ring-visible[href*="apply"] {
  background: #ffffff !important;
  color: #000000 !important;
  box-shadow: 0 0 0 1.5px #ffffff;
}

/* Apply hover: restore site blue background */
header .nav-contact-ring.nav-ring-visible[href*="apply"]:hover {
  background: #36c3ff !important;
  color: #000000 !important;
}


/* =========================================================
     Footer
     ========================================================= */
     footer {
      display: flex;
      flex-direction: column;
      text-align: center;
      padding-bottom: 3%;
      background-color: #000;
    }

    
    
    .footer-top-divider {
      border-top: 1px solid #333;
      margin-bottom: 40px;
    }
    
    .footer-info {
      display: flex;
      flex-direction: row;
      justify-content: space-evenly;
      margin-top: 5%;
    }
    
    .footer-nav-menu {
      display: flex;
      justify-content: center;
      
    }
    .footer-nav-menu ul {
      list-style: none;
      display: flex;
      gap: 8rem;
      padding: 0%;
      margin: 0;
      font-size: 19px;
    }
    .footer-nav-menu ul li a:hover {
      color: #36c3ff;
    }
  
    .footer-middle-content{
      margin-top: -40px;
     
    }
  
    .footer-address{
      font-size: 19px;
      margin-top: 40px;
    }
      
      /* Social Icons (Footer and elsewhere) */
      .social-icons {
        display: flex;
        justify-content: center;
        gap: 20px;
        padding: 20px;
        margin-bottom: 20px;
      }
      .social-icons a {
        width: 50px;
        height: 50px;
        background-color: #333;
        border-radius: 50%;
        display: flex;
        justify-content: center;
        align-items: center;
        color: #fff;
        font-size: 24px;
        transition: background-color 0.3s;
        text-decoration: none;
      }
      .social-icons a:hover {
        background-color: #555;
      }
      .icon img {
        width: 32px;
        height: 32px;
        transition: transform 0.3s ease;
      }
      .icon img:hover {
        transform: scale(1.1);
      }
      
    /* hides hambuger and x icon*/
      header .fa-solid{
        display: none;
    }

/********************* Responsiveness ********************************/

  @media only screen and (max-width: 1472px) {




    header{
     justify-content: space-evenly;
     align-items: center;
     gap: 70%;
     
    }
 
    .logo img {
     width: 150px;
     height: 150px;
     object-fit: cover;
   }

     
     header ul li a {
         font-size: 40px;
         margin-left: 35px;
         
     }
     header .fa-solid{
       
       display: block;
       font-size: 35px;
       
     } 
 
     header .wwu-button {     
         
       font-size: 35px;
       margin-left: 55px;
       margin-top: 25px;
     
     }  
 
     header .apply-button{
       font-size: 35px;
       margin-left: 55px;
       margin-top: 55px;
 
     }

     header .nav-contact-ring {
       font-size: 35px;
       padding: 15px 35px;
       margin-left:20px;
       margin-top: 25px;
       border-width: 3px;
       display: inline-block;
     }
 
     /* Increase left spacing specifically for visible-ring items in hamburger */
     header .nav-contact-ring.nav-ring-visible {
       /* ...existing ring styles... */
       margin-left: 40px;
     }

     header ul{
       display: flex;
       flex-wrap: wrap;
       flex-direction: column;
       background: #000;
       position: fixed;
       color: #ffffff;
       top: 0;
       right: -200%;
       width: 100%;
       height: 100%;
       /* Remove padding-top so sticky X can sit at the very top */
       padding-top: 0;
       gap: 0px;
       font-size: 20px;
       z-index: 2;
       transition: right 0.5s ease-in-out;
       overflow-y: auto;
     }
 
     header ul li{
       display: block;
       margin: 25px;
       margin-top: 60px;
       margin: 10px 0;
       margin-left: 25px;
     }

     /* Push first link down to compensate for removed padding */
     header ul li:first-of-type {
       margin-top: 140px;
     }
 
     /* Sticky close icon: stays in top-right of the menu, moves with menu */
     header ul .fa-xmark {
       position: sticky;
       top: 30px;
       align-self: flex-end; /* Align right in flex column */
       order: -1; /* Visual top */
       margin-right: 50px;
       margin-top: 30px;
       cursor: pointer;
       z-index: 100;
       font-size: 35px;
       display: block;
     }
     
     /* Ensure bars icon is visible (it's outside ul) */
     header > .fa-bars {
        display: block;
        font-size: 35px;
     }
 
     /* Unified hover for hamburger menu: all links behave like desktop */
  header ul li a:hover,
  header .nav-contact-ring:hover,
  header .nav-contact-ring.nav-ring-visible:hover,
  header .nav-contact-ring.nav-ring-not-visible:hover {
    color: #36c3ff !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  /* Responsive font size: scales with height to prevent cutoff */
  header ul li a {
      font-size: clamp(24px, 4vh, 40px);
      margin-left: 35px;
  }
 
 }
     
   
   @media screen and (max-width: 1010px) {
 
     header ul .fa-solid{
       position: fixed;
       top: 30px;
       right: 30px;  
       cursor: pointer;
     }
 
     /*
     Project card font sizes
     */
     .project-card .text-content h3 {
       font-size: 20px;
     }
     .project-card .text-content p {
       font-size: clamp(0.875rem, 2.5vw, 1rem);
     }
 
     .carousel {
       width: 100%;
       padding-top: 80%;
       height: 360px;
       
     }
 
   }
 
   @media only screen and (max-width: 900px){
     .project-card {
       border-radius: min(50px, 100%);
     }
     .project-card .text-content h3 {
       font-size: 15px;
     }
     .project-card .text-content p {
       font-size: clamp(0.875rem, 2.5vw, 1rem);
 
     }
 
     .carousel {
       width: 100%;
       padding-top: 80%;
       height: 360px;
       
     }
 
   }
   
   @media screen and (max-width: 800px) {
     .bottom-row, .top-row {
       flex-direction: column;
     }
     .hideImgWhenSmall {
       display: none;
     }
     .hero h1 {
       font-size: 3rem;
     }
     .hero p {
       font-size: 1.5rem;
     }
     .hero .images img {
       width: 80%;
     }
     .collaborate-section {
       text-align: center;
       margin: 0 auto;
       width: 100%;
       padding: 0; 
       padding-bottom: 15%;
     }
     .collaborate-section h2{
       font-size: 220%;
       text-align: center;
       padding: 2%;
     }
     .collaborate-section p {
       font-size: 120%;
     }
     .skills h2{
       font-size: 250%;
     }
     .skills p{
       font-size: 110%;
       text-align: center;
     }
     .skills .aboutus-button{
       font-size: 150%;
     }
     .join-us-section p{
       padding: 0 4rem;
     }
     .projects h2 {
       font-size: 290%;
     }
 
 
     
 
     .project-grid {
     flex-direction: column;
     align-items: center;
     }
     .project-card {
       margin-bottom: 2rem;
 
       border-radius: min(50px, 100%);
     }
     .questions-card h2{
       font-size: 240%;
     }
     .questions-card p{
       font-size: 140%;
     }
     .questions-card, .collaborate-section {
       width: 90%;
     }
 
     .project-card .text-content h3 {
       font-size: 35px;
     }
     .project-card .text-content p {
       font-size: 18px
     }
 
     .carousel {
       width: 100%;
       padding-top: 80%;
       height: 360px;
       
     }
     .fa-solid {
      padding-right: 5%;
     }
     
   }
   @media (max-width: 768px) {
   .carousel {
     width: 100%;
     padding-top: 60%;
     height: 360px;
   }
 
   .carousel img {
       max-width: 100%;
       height: auto;
   }
 }
 
   
   @media (max-width: 600px) {
 
     .carousel {
       width: 100%;
       padding-top: 80%;
       height: 360px;
       
     }
 
    .social-icons a {
      width: 40px;
      height: 40px;
      font-size: 20px;
      padding: 0; 
    }
    .footer-nav-menu ul {
      gap: 5.3rem;
      font-size: 0.9rem;
      
    }
    .logo img {
    width: 115px;
    height: 115px;
    object-fit: cover;
    }
   }
  
   @media only screen and (max-width: 480px) {

    header{
     
      padding-left: 5%;
    }

    .logo a {
      width: 200%;
      height: auto;
      object-fit: cover;
    }
    
     .carousel {
       padding: 0; /* Remove padding on very small screens */
       height: 300px;
     }
   
     .carousel img {
       border-radius: 35px; /* Further reduce the radius for very small screens */
     }

     header ul li a{
      font-size: 25px;
    }

     header .wwu-button{
      font-size: 25px;
      
      width: fit-content;
      
      margin-top: 2.5%;

     }

     header .apply-button{
      font-size: 25px;
      border-radius: 40px;
      width: fit-content;
      margin-top: 8%;
     }

     footer{
      text-align: center;
      
     }

     .footer-nav-menu{
      font-size: 15px;
      
    
    }

    .footer-middle-content{
      margin-top: -10px;
     
    }


     .footer-address{
      font-size: 15px;
      margin-top: -1%;
    }

   }
   @media (max-width: 400px) {
     .project-card {
       border-radius: min(50px, 100%);
     }
     .project-card .text-content {
       padding-left: 20px;
     }
 
    header ul .fa-solid{
       position: fixed;
       top: 20px;
       right: 20px;
       cursor: pointer;
    }
 
     .logo img {
       width: 80px;
       height: 80px;
       object-fit: cover;
     }
 
     .project-card .text-content h3 {
       font-size: 30px;
     }
     .project-card .text-content p {
       font-size: 15px
     }
 
   }
header .fa-solid.fa-bars,
header .fa-solid.fa-xmark {
  cursor: pointer;
}

/* If an image is ever used as a hamburger button */
header .hamburger-button img {
  cursor: pointer;
}

/* === Progressive spacing adjustments (added) ===
   Only affects desktop before hamburger breakpoint (1472px).
   No HTML, sizing, or ordering changes.
   Gradually reduces space between items instead of abrupt jump. */

/* Ensure flex container behaves predictably */
header ul {
  flex-wrap: nowrap;
}

/* Prevent oversized margin-right from causing uneven spacing as width shrinks */
@media (max-width: 1815px) {
  header ul li {
    margin-right: 0 !important; /* override large static margin */
    flex-shrink: 1;              /* allow mild contraction */
  }
  header ul {
    gap: 8rem;                   /* start controlled spacing */
  }
}

/* Slightly tighter */
@media (max-width: 1700px) {
  header ul { gap: 6.5rem; }
}

/* Continue reducing */
@media (max-width: 1600px) {
  header ul { gap: 5rem; }
}

/* Fine-tune before breakpoint */
@media (max-width: 1550px) {
  header ul { gap: 4rem; }
}

/* Just before hamburger activation */
@media (max-width: 1500px) {
  header ul { gap: 3rem; }
}

/* Gradual nav font-size reductions before hamburger breakpoint */
@media (max-width: 1815px) {
  header ul li a {
    font-size: 18px; /* was 19px */
  }
}

@media (max-width: 1700px) {
  header ul li a {
    font-size: 17px;
  }
}

@media (max-width: 1600px) {
  header ul li a {
    font-size: 16px;
  }
}

@media (max-width: 1550px) {
  header ul li a {
    font-size: 15.5px;
  }
}

@media (max-width: 1500px) {
  header ul li a {
    font-size: 15px;
  }
}

/* Hamburger menu: switch to two columns when viewport height is small */
@media only screen and (max-width: 1472px) and (max-height: 800px) {
  /* Use grid to form two columns; keep your existing styles intact */
  #sidemenu {
    display: grid;                    /* start as single column */
    grid-template-columns: 1fr;
    grid-auto-rows: min-content;      /* rows sized to content */
    align-content: start;             /* pack items at the top */
    column-gap: 2rem;                 /* horizontal spacing */
    row-gap: clamp(0.5rem, 1.8vh, 1.25rem);
    padding-inline: clamp(0.75rem, 2.2vh, 2rem);
    width: 100%;
    padding-top: 0; /* Ensure no padding interferes with sticky */
  }

  /* Gradually tighten spacing as height reduces */
  @media (max-height: 900px) {
    #sidemenu {
      row-gap: clamp(0.35rem, 1.4vh, 1rem);
      padding-inline: 1rem;
      column-gap: 1.5rem;
    }
  }

  @media (max-height: 900px) {
    #sidemenu {
      row-gap: 0.6rem;
      padding-inline: 0.75rem;
      column-gap: 1.25rem;
    }
  }

  /* When the viewport gets very short, switch to two columns */
  @media (max-height: 560px) {
    #sidemenu {
      grid-template-columns: 1fr 1fr;  /* two equal columns */
      column-gap: 1rem;
      row-gap: 0.5rem;
    }
  }

  /* Normalize spacing for grid items */
  #sidemenu li {
    margin: 0 !important;           /* remove large margins that force overflow */
  }
  #sidemenu li a {
    margin-top: 0.25rem;            /* compact consistent spacing */
  }

  /* Ensure Apply appears in the right column */
  #sidemenu li:last-child {
    grid-column: 2;
  }

  /* Keep close icon visible across both columns at the top-right */
  #sidemenu .fa-xmark {
    position: sticky;
    grid-column: 1 / -1;            /* span both columns */
    top: 20px;
    justify-self: end;              /* Align right in grid */
    margin-right: 20px;
    margin-top: 20px;
    z-index: 100;
    order: -1;
  }
}

/* Compact vertical spacing when the viewport height is 885px or less */
@media only screen and (max-width: 1472px) and (max-height: 885px) {
  #sidemenu {
    row-gap: 3rem;
    padding-top: 0; /* Remove padding */
    padding-bottom: 1rem;
  }
  #sidemenu li:first-of-type {
      margin-top: 100px; /* Reduced top spacing */
  }
  #sidemenu li a {
    margin-top: 0.15rem;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
  }
  #sidemenu .fa-xmark {
    position: sticky;
    top: 20px;
    margin-right: 30px;
    margin-top: 20px;
    z-index: 9999;
  }
}