/* CSS RESET */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ---------------------------------------------------------------------- General Styles */
:root {
  /* Base font size for the entire website */
  font-size: 62.5%;

  /* ----------------------- Colors */
  /* m = modified */
  /* l = light */
  /* d = dark */
  --color-primary: rgb(135, 85, 46); /* Dark wood brown */
  --color-primary-m-l: rgba(135, 85, 46, 0.55); /* Lighter version */
  --color-primary-m-d: rgba(135, 85, 46, 0.85); /* Darker version */

  /* Secondary Color - Warm amber orange */
  --color-secondary: rgb(215, 124, 43); /* Amber orange */
  --color-secondary-m-l: rgba(215, 124, 43, 0.55); /* Lighter amber */
  --color-secondary-m-d: rgba(215, 124, 43, 0.85); /* Darker amber */

  /* Tertiary Color - Forest green */
  --color-tertiary: rgb(50, 100, 67); /* Earthy forest green */
  --color-tertiary-m-l: rgba(50, 100, 67, 0.55); /* Lighter green */
  --color-tertiary-m-d: rgba(50, 100, 67, 0.85); /* Darker green */

  /* Quaternary Color - Light beige (neutral background) */
  --color-quaternary: rgb(245, 239, 224); /* Light beige */
  --color-quaternary-m-l: rgba(245, 239, 224, 0.55); /* Lighter beige */
  --color-quaternary-m-d: rgba(245, 239, 224, 0.85);

  /* ----------------------- Padding */
  /* 
      xl     = extra large
      l      = large
      m      = medium
      s      = small
  */

  --padding-xl: calc(2rem + 6vh) calc(2rem + 6vw);
  --padding-l: calc(3rem + 4vh) calc(3rem + 4vw);
  --padding-m: calc(2rem + 2vh) calc(2rem + 2vw);
  --padding-s: calc(1rem + 1vh) calc(1rem + 1vw);

  /* ----------------------- Font Size */
  /* 
      l      = large
      m      = medium
      s      = small
      xs     = extra small
  */

  --font-size-l: calc(1.5rem + 2vw);
  --font-size-m: calc(1rem + 1.5vw);
  --font-size-s: calc(1.2rem + 0.6vw);
  --font-size-xs: calc(0.5rem + 0.8vw);

  /* ----------------------- Font Family */

  --font-family-main: "Fredoka", sans-serif;
  --font-family-sub: "Poppins", sans-serif;
}

body {
  font-family: var(--font-family-sub);
  line-height: 1.5;
  color: #fff;
}

.wrapper {
  display: grid;
  grid-template-columns:
    [container-start] 1fr [center-start] repeat(
      14,
      [col-start] minmax(min-content, 11rem) [col-end]
    )
    [center-end] 1fr [container-end];

  grid-template-rows: repeat(6, min-content);
  background-color: white;
}

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

li {
  list-style: none;
}

/* ********************************************************************************************************** Header **/
#main-header {
  background-color: white;
  grid-column: center-start / center-end;
  padding: var(--padding-s);
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

.logo-container {
  height: 10rem;
  width: 10rem;
}

.logo-container img {
  width: 100%;
  height: 100%;
}

.nav-menu {
  display: flex;
  align-items: center;
}

.hamburger {
  z-index: 1;
}

.nav-menu li {
  position: relative;
  padding-left: 1.5vw;
}

.nav-menu li a {
  position: relative;
  padding: 1rem 0.6rem;
  font-size: calc(1rem + 0.4vw);
  color: black;
  display: flex;
  gap: 0.5rem;
  align-items: center;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  z-index: 10; /* Ensure text and icons stay above the line */
}

.navbar {
  z-index: 1000;
}

.hamburger {
  display: none;
}

/* Nav Links Animation (Only the line at the bottom now) */
ul.nav-menu li :link::after,
ul.nav-menu li :visited::after {
  content: "";
  position: absolute;
  left: 0;
  width: 100%;
  height: 0.25rem;
  background-color: black;
  transform: scaleX(0);
  transition: transform 0.6s cubic-bezier(1, 0, 0, 1);
  bottom: 0; /* Position the line at the bottom */
  z-index: -1; /* Keeps the line behind the text and icon */
}

ul.nav-menu li :hover::after,
ul.nav-menu li :active::after {
  transform: scaleX(1);
}

/* **************************************************************************************************** Hero Section **/

#hero {
  grid-column: center-start / center-end;
  background-color: var(--color-tertiary);
  padding: var(--padding-m);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 3vw;
  justify-content: space-evenly;
  color: var(--color-quaternary);
  padding-bottom: 5rem;
}

.hero-container {
  display: flex;
  flex-basis: 5rem;
  flex-grow: 1;
  flex-direction: column;
  justify-content: center;
  gap: 2rem;
}

#main-title span {
  color: var(--color-secondary);
}

.hero__vec {
  flex-basis: 10rem;
  flex-grow: 1;
}

.fa-star,
.hero__content--rating__text span {
  color: var(--color-secondary);
}

.fa-star,
.container1 p {
  font-size: 1.6rem;
}

.container1 p {
  font-size: 1.6rem;
  line-height: 2;
}

.hero__content--rating__text p {
  font-size: 1.4rem;
}

#main-title {
  font-size: calc(5rem + 0.5vw);
  margin-bottom: 1rem;
  font-weight: 500;
  font-family: var(--font-family-main);
  line-height: 1.2;
  margin-bottom: 2rem;
}

.hero__content--rating {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

#main-para {
  font-size: var(--font-size-s);
}

.login-register-container {
  display: flex;
  flex-direction: row;
  gap: 1.5rem;
}

.login-register-container .login-register-link {
  align-self: flex-start;
  padding: 1rem 2.5rem;
  background: none;
  border: 1px solid var(--color-secondary);
  color: var(--color-secondary);
  font-size: var(--font-size-s);
  cursor: pointer;
  transition: all 0.4s ease-in-out;
}

.login-register-container .login-register-link:hover {
  background-color: var(--color-primary);
  color: #fff;
}

/* **************************************************************************************************** Know Us More Section **/
section#more__container {
  grid-column: center-start / center-end;
  padding: var(--padding-m);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4rem;
}

.more__title {
  color: var(--color-quaternary);
  font-size: var(--font-size-l);
  font-weight: 600;
  font-family: var(--font-family-main);
}

.more__contant {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(24rem, 1fr));
  gap: 2rem;
}

.mission,
.aim,
.about-us {
  border: 0.2rem solid var(--color-secondary);
  padding: var(--padding-s);
  flex-grow: 1;
}

.about-us__icon,
.aim__icon,
.mission__icon {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.about-us h3,
.aim h3,
.mission h3 {
  font-size: var(--font-size-m);
  font-weight: 300;
  align-self: flex-start;
}

.aim i,
.mission i,
.about-us i,
.about-us h3,
.aim h3,
.mission h3 {
  color: var(--color-secondary);
}

.aim i,
.mission i,
.about-us i {
  font-size: 3.5rem;
}

.about-us p,
.aim p,
.mission p {
  font-size: var(--font-size-s);
  color: var(--color-quaternary);
}
.aim ul li i {
  font-size: 1.2rem;
}

.aim ul li p {
  font-size: var(--font-size-s);
  font-family: var(--font-family-main);
  font-style: italic;
}
.aim ul li {
  font-size: var(--font-size-s);
  display: flex;
  gap: 1rem;
  margin-bottom: 1rem;
}

.aim p.strive {
  margin-top: 1rem;
  text-decoration: underline dotted var(--color-secondary) 0.3rem;
}

.aim ul li:first-of-type {
  margin-top: 1rem;
}

p.strive {
  margin: 1.2rem 0;
}

/* **************************************************************************************************** Image   Slider Section **/
#image-section {
  grid-column: 1/-1;
  background-color: var(--color-quaternary);
}
.image-slider {
  position: relative;
  padding: var(--padding-s);
  display: flex;
  overflow: hidden;
  overflow: hidden;
  white-space: nowrap;
}

.gallery {
  display: flex;
  align-items: center;
  justify-content: center;

  animation: 20s slide infinite linear;
}

/* Animation */
@keyframes slide {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-100%);
  }
}

/* Blur at the end and start of the images */
.image-slider::before {
  position: absolute;
  content: "";
  top: 0;
  left: 0;
  width: 15rem;
  height: 100%;
  background: linear-gradient(to left, transparent, #fff);
  z-index: 10;
}

.image-slider::after {
  position: absolute;
  content: "";
  top: 0;
  right: 0;
  width: 15rem;
  height: 100%;
  background: linear-gradient(to right, transparent, #fff);
  z-index: 10;
}

/* Pause on hover */
#image-section:hover .gallery {
  animation-play-state: paused;
}

.gallery img {
  height: 20rem;
  margin: 0 1rem;
}

/* **************************************************************************************************** WORKING SECTION **/
#work-section {
  grid-column: center-start / center-end;
  background-color: var(--color-primary);
  padding: var(--padding-m);
}
#work-section h2 {
  text-align: center;
}

.work-section__container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(24rem, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

#work-section h2 {
  color: var(--color-quaternary);
  font-size: var(--font-size-l);
  font-weight: 600;
  font-family: var(--font-family-main);
}

.work-section__container h3 {
  font-size: var(--font-size-m);
  font-weight: 500;
  color: var(--color-secondary);
}

.work-section__container p {
  font-size: var(--font-size-s);
  color: var(--color-quaternary);
}

.features-one,
.features-two,
.features-three,
.features-four,
.features-five {
  display: flex;
  align-items: center;
  text-align: center;
  padding: var(--padding-xs);
  flex-direction: column;
  gap: 1rem;
  border: 2px solid var(--color-secondary);
  padding: var(--padding-s);
}

.work-section__container i {
  font-size: 3.5rem;
  color: var(--color-secondary);
}

/* ****************************************** Footer Section */
#footer {
  grid-column: 1 / -1;
  background-color: var(--color-tertiary);
  padding: var(--padding-m);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 2rem;
}

.contacts {
  margin-bottom: 2rem;
}

.contacts h2 {
  font-size: var(--font-size-l);
}
.contacts p,
.footer__container p {
  font-size: var(--font-size-s);
}
/* ****************************************************************************************************Media Queries **/
@media screen and (max-width: 980px) {
  /* Hero Section */
  .hero__vec {
    flex-basis: 30rem;
  }
}

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

    /* ---------------------------- Hamburger Menu */
    .hamburger {
        display: block;
        height: 5rem;
        width: 5rem;
        position: fixed;
        top: 3rem;
        right: 4rem;
        padding: 0.6rem;
        cursor: pointer;
        z-index: 100000000;
    }

    /* ----------------------- Hamburger Menu Line */
    .hamburger-line {

        position: absolute;
        background-color: rgb(50, 100, 67);
        height: 0.3rem;
        width: 3rem;
    }

    .hamburger-line:first-child {
        width: 6rem;
        top: 0;
        left: 0;
        transition: all 0.35s ease-in-out;
    }

    .hamburger-line:nth-child(2) {
        top: 1rem;
        width: 2.5rem;
        left: 0;
        transition: all 0.2s ease-in-out;
    }

    .hamburger-line:last-child {
        width: 4.5rem;
        top: 2rem;
        left: 0;
        transition: all 0.35s ease-in-out;
    }

    /* --- Toggling Nav Bar --- */
    .line-1 {
        transform: rotate(45deg) translate(0.3rem, 1.4rem);
        width: 3.5rem !important;
    }

    .line-2 {
        visibility: hidden;
    }

    .line-3 {
        transform: rotate(-45deg) translate(0, -1.15rem);
        width: 3.5rem !important;
    }

    .block.visible {
        transform: translateX(0);
    }

    /* --- Nav Links --- */
    nav.navbar,
    ul.nav-menu {
        flex-direction: column;
        justify-content: space-evenly;
        align-items: flex-start;
        gap: 2rem;

    }

        nav.navbar {
          position: fixed;
          top: 0;
          right: 0;
          width: 25rem;
          height: 100vh;
          padding: 8rem 2rem 4rem 0.2rem;
          background-color: orange;
          transform: translateX(100rem);
          transition: all 0.55s cubic-bezier(1, 0, 0, 1);
    
          /* ← Add these */
          overflow-y: auto;
          /* allow vertical scroll */
          overflow-x: hidden;
          /* prevent horizontal scroll */
          -webkit-overflow-scrolling: touch;
          /* smooth scrolling on iOS */
        }

    .nav-menu li a {
        color: white;
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 1rem;
        font-size: 1.6rem;
    }

    .logo-container {
        height: 6rem;
        width: 6rem;
    }

    /* ******************************************Know Us More Section */
    .more__contant p,
    .more__contant ul li p {
        font-size: 1.6rem;
    }

    .more__contant h3 {
        font-size: 2.5rem;
    }
}

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

    /* Image Gallary Section */
    .gallery img {
        height: 10rem;
        margin: 0 1rem;
    }
}

@media screen and (max-width: 390px) {
    /* Know Us More Section */

    .container1 h2 span {
        display: block;
        /* width: 200px; */
    }

    .image-slider::before {
        width: 8rem;
    }

    .image-slider::after {
        width: 8rem;
    }
}