/* reset all */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --dark: #0e3b20;
  --light: #6ec58b;

  --gradient-text: linear-gradient(to bottom left, var(--accent), var(--secondary));

  --primary-bg: #ffffff;
  --primary-200: #ffffff;
  --primary-light: #1d8a47bf;
  --secondary: #8affc9;
  --accent: #3F4739;
  --text-muted: #56554e;

  --ff-sans: "Raleway", sans-serif;
  --spacing--24: 1.5rem;
  --navbar-width: 200px;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

li {
  list-style: none;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 2rem;
}

/* utility classes */
.container {
  width: min(100%, 1080px);
  padding-inline: 1rem;
  margin: auto;
}

.relative {
  position: relative;
}

.absolute {
  position: absolute;
}

.w-full {
  width: 100%;
}

.h-full {
  height: 100%;
}

.flex-group {
  display: flex;
  align-items: center;
}

.button {
  border-radius: 4px;
  font-size: 0.875rem;
  font-family: inherit;
  display: inline-block;
  padding: 0.45rem 0.75rem;
}
.button,
.cta i {
  transition: 300ms;
}

/* Avoid duplicates */
.hero-image-container::before,
.image-section::before,
.image-section::after,
.features-section::after,
.nav-links li::after {
  content: " ";
  position: absolute;
  left: 0;
}


/****! Starting from Mobile Devices *****/
body {
  background-color: var(--primary-bg);
  color: var(--dark);
  font-family: var(--ff-sans);
  overflow-x: hidden;
}

header {
  top: 0;
  position: sticky;
  z-index: 99;
  backdrop-filter: blur(1rem);
  background-color: var(--primary-light);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.1);
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.header-section .logo {
  width: fit-content;
  margin: auto;
}

.header-section .logo a {
  font-size: clamp(1.25rem, 5vw, 2rem);
  font-weight: 600;
  text-shadow: 0px 2px 0px var(--secondary);
}

nav,
.menu {
  position: fixed;
}

nav {
  top: 0;
  left: 0;
  height: 100vh;
  background: var(--dark);
  padding-inline: 1rem;
  width: var(--navbar-width);
  overflow: hidden;
}

.nav-links {
  margin-block: 3rem;
  color: var(--light);
}

nav,
.nav-links li,
.btns {
  transform:translate(-110%);
}
nav,.menu,
.nav-links li,
.btns{
  transition: 0.5s cubic-bezier(0.65, 0.05, 0.36, 1);;
  transition-delay: var(--d);
}

/* when active */
nav.active,
nav.active .nav-links li,
nav.active .btns {
  transform: translate(0);
}

.nav-links li {
  width: 100%;
  position: relative;
}

/* style of nav links */
.nav-links a {
  display: block;
  padding: 0.85em 0;
  font-size: 0.938rem;
}

.nav-links li::after,
.nav-links li::before {
  position:absolute;
  content:'';
  bottom: 0;
  width: 100%;
  height: 1px;
  background-color: rgb(255 255 255 / 15%);
  border-radius: 2px;
  transition: 0.25s;
}
.nav-links li::after{
  width: 0%;
  background-color: rgb(255 255 255 / 20%);
}
.nav-links li:is(.active, :hover)::after {
  width: 100%;
  transform: translate(0);
}

.btns {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.btns > * {
  color: var(--light);
}
.btns > *:hover {
  background: var(--primary-200);
  color: var(--dark);
  transform: translateY(-2px);
}
/* signin button */
.signin-btn {
  box-shadow: inset 0 0 0 1px var(--accent);
  background-color: transparent;
}
.signin-btn:hover {
  box-shadow: none;
}

.sign-up {
  background-color: var(--accent);
}

/* Hero section starts */

.hero-section {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-block: 5rem;
  text-align: center;
  overflow: hidden;
}
.hero-contents {
  max-width: 60ch;
  margin: auto;
  order: 2;
  margin-bottom: 2rem;
}

.hero-text {
  font-size: clamp(3rem, 10.5vw, 5rem);
  line-height: 1;
  background: var(--gradient-text);
  color: transparent;
  -webkit-background-clip: text;
  background-clip: text;
}
.hero-subText {
  color: var(--text-muted);
  font-weight: 600;
  font-size: clamp(1rem, 4.5vw, 1.25rem);
  margin-block: 1rem 2rem;
}

.hero-image-container {
  max-width: 445px;
  margin: auto;
  order: 2;
  border-radius: 8px;
  position: relative;
}
.hero-image-container::before {
  top: 0;
  left: 0;
  width: 270px;
  border-radius: 50%;
  height: 100%;
  scale: 1.35;
  filter: blur(1.5rem);
  user-select: none;
  pointer-events: none;
  z-index: -1;
  background: linear-gradient(45deg, hsl(0, 0%, 100%), #ffffff, #00ff88a6);
}

.social-links {
  order: 3;
  display: flex;
  justify-content: center;
  margin-top: 3em;
  gap: 20px;
}

.social-links a {
  padding: 0.5em;
  color: var(--dark);
  font-size: 1.5rem;
  filter: drop-shadow(2px 4px 8px var(--accent));
}
.social-links a:hover {
  color: var(--accent);
}

/* features section */
section#features {
  background-color: var(--primary-200);
}
.features_heading {
  text-align: center;
  margin-bottom: 2rem;
}

.features{
  flex-direction: column;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
}
.feature {
  width: min(22rem, 90%);
  justify-content: space-between;
  flex-direction: column;
  margin-inline-start: var(--spacing--24);
  margin-bottom: 1.5rem;
  border-radius: 0.5rem;
  background-color: var(--primary-bg);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.image-section img {
  border-radius: 0.45rem 0.45rem 0 0;
}

.text-section {
  padding: 1em;
  padding-bottom: 2em;
}
.feature-two .text-section {
  order: 1;
}
.text-section .title {
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: 1px;
  margin-bottom: 1rem;
}
.text-section .description {
  width: 100%;
  line-height: 1.6;
  margin-bottom: 1.5rem;
  max-height: calc(3rem * 1.6);
  overflow: hidden;
}

.about-section,
.features-section,
.footer-section {
  padding-block: 2.5rem;
}

/* about section */
.about-section {
  line-height: 1.6;
  width: min(100%, 800px);
}
.about-section h2 {
  text-align: center;
  padding-bottom: 1rem;
}
.about-section p {
  text-align: justify;
  padding-inline: 0.2 rem;
}

.about-section p {
  max-width: clamp(40ch, 10vw, 50ch);
  text-align: center;
  margin: auto;
}

footer {
  background: var(--dark);
  color: var(--light);
  text-align: center;

  position: relative;
  overflow: hidden;
}

.footer-section {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 2rem;
}
.footer-logo{
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%,-50%);

  color: rgb(255 255 255 / 5%);
  font-size: 10rem;
  
  user-select: none;
  pointer-events: none;
}

.footer-links a {
  display: inline-block;
  padding: 0.5em 0;
  text-decoration: underline;
}
.footer-links a:hover {
  color: var(--primary-200);
  text-decoration: none;
}
.footer-links:hover > *:not(:hover) {
  opacity: 0.3;
}

/* menu styling starts */
.menu {
  width: 24px;
  padding: 6px 3px;
  aspect-ratio: 1;
  z-index: 2;
  left: 1rem;
  top: 50%;
  transform: translate(0, -11px);
  border-radius: 0.2rem;
  cursor: pointer;
}
.menu .line {
  position: absolute;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background-color: var(--dark);
  transform: translate(0, var(--y, 0)) rotate(var(--r, 0));
}
.menu .line:nth-child(2) {
  --y: 5px;
}
.menu .line:nth-child(3) {
  --y: 10px;
}
/* on activation */
.menu.active {
  left: calc(var(--navbar-width) - 1.25rem);
  background-color: var(--dark);
  box-shadow: 0 0 2px 1px rgb(255 255 255 / 15%);
}
.menu.active .line {
  background-color: var(--light);
}
.menu.active .line:nth-child(2) {
  transform: translate(100%);
  opacity: 0;
}
.menu.active .line:nth-child(1) {
  --r: 45deg;
  --y: 5px;
}
.menu.active .line:nth-child(3) {
  --r: -45deg;
  --y: 5px;
}

/* CTA Button */
.cta {
  font-size: inherit;
  background-color: var(--accent);
  color: var(--light);
  border: 1px solid var(--accent);
  box-shadow: 0px 10px 20px #6d978d71;
  padding: 0.75em 1rem;
}
.cta:is(:hover, :focus) {
  background-color: var(--dark);
}
.cta i{
  margin-left: 4px;
}

.more-btn {
  padding: 0.6rem 1.2rem;
  width: 100%;
  text-align: center;
  background: var(--dark);
  color: var(--light);
  box-shadow: 1px 4px 10px rgba(0, 0, 0, 0.15);
}
.more-btn:hover {
  background-color: #3e3f3d;
}

/* strip-lines */
.strip-line {
  position: absolute;
  transition: .7s;
  left: 8px;
}
.horizontal{display: none;}
.circle {
  width: 20px;
  aspect-ratio: 1/1;
  z-index: 1;
  border-radius: 50%;
  left: 8px;
  transform: translate(-50%,220px);
  scale: 0;
  border: 3px solid var(--primary-200);
  box-shadow: 0 0 0 3px var(--primary-200);
  transition: 0.5s .2s;
  transform-origin: center;
}
.circle.active{
   scale: 1;
}
.circle,.strip-line{
  background-color: var(--dark);
  pointer-events: none;
  /* user-select: none; */
}

.vertical{
  width: 1.5px;
  top:0;
}

/* Desktop */
@media screen and (min-width: 869px) {
  .header-section,
  nav,
  .nav-links {
    display: flex;
    align-items: center;
  }

  .header-section,
  nav {
    justify-content: space-between;
  }

  .hero-section {
    flex-direction: row;
    text-align: left;
  }
  .hero-contents {
    order: 1;
    margin: 0;
    max-width: 25rem;
  }
  .hero-image-container {
    width: 40%;
  }

  .social-links {
    margin-top: 1em;
    flex-direction: column;
  }
  
  .circle,
  .vertical{
    left: 50%;
    transform: translate(-50%);
  }

  .vertical {
    --height:0;
    width: 2px;
    height: var(--height);
  }
  .vertical.active .line {
    height: var(--feature-height);
  }
    
  .horizontal {
    display: block;
    top: 26%;
    left: 45%;
    width: 8vw;
    --scaleX:0;
    transform: translate(-50%) scaleX(var(--scaleX));
    transform-origin: right;
    height: 2px;
  }
  .horizontal:nth-of-type(2) {
    top: 53%;
    left: 55%;
  }
  .horizontal:nth-of-type(3) {
    top: 80%;
  }
  .horizontal.active {
    --scaleX: 1;
  }

  .feature {
    flex-direction: row;
    justify-content: space-between;
    margin-block: 1.5em;
    margin-inline: auto;
    box-shadow: none;   
    
    flex-grow: 1;
    width: 100%;
    padding-inline: 0;
    background-color: transparent;
  }
  .features {
    flex-direction: row;
  }
  .about-section,
  .features-section{
    padding-block: 5rem;
  }
  .image-section {
    --feature-img-width: 22rem;
    --feature-img-height: 14rem;
    width: var(--feature-img-width);
    height: var( --feature-img-height);

    z-index: 1;
    position: relative;
    border-radius: 0.5rem;
    border: 2px solid rgba(39, 184, 71, 0.15);
  }
  .image-section img {
    border-radius: .5rem;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  }
    /* 3 rotating rectangles */
  .image-section::before {
    border: 4px solid var(--accent);
    border-radius: 50%;
    width: 60%;
    aspect-ratio: 1;
    top: -1rem;
    opacity: 0.4;
    left: -1rem;
    animation: rotate 5s infinite alternate;
    z-index: -1;
  }

  .image-section img{
    opacity: 0;
    transition: 1s;
  
    transform: translate(50%);
    transition-delay: .7s;
  }

  .image-section img:nth-child(2) {
    transform: translate(-50%);
  }

  .image-section.active img {
    opacity: 1;
    transform: translate(0);
  }
  .image-section.active::after{
    width: 40%;
  }
  .feature-two .image-section::after {
    right: unset;
    left: -61%;
  }

  @keyframes rotate {
    15% {
      transform: scale(1.1);
    }

    30% {
      transform: scale(0.5);
    }

    50% {
      transform: translate(80%, 40%) scale(0.5);
    }

    100% {
      transform: translate(80%, 40%) scale(1.1);
    }
  }

  .feature-two .text-section {
    order: 0;
  }
  .text-section {
    padding: 0;
    width: min(100%, 320px);
    text-align: justify;
  }

  nav {
    position: static;
    flex-grow: 1;
    height: auto;
    padding-inline-end: 0;
    background-color: transparent;
  }

  nav > * {
    padding-inline: 0;
    max-width: auto;
  }

  .nav-links {
    margin: auto;
  }
  .nav-links li::after {
    height: 3px;
    border-radius: 3rem 3rem 0 0;
    background-color: var(--accent);
  }
  .nav-links li:is(.active, :hover)::after {
    width: 50%;
    transform: translate(50%);
  }

  .nav-links a {
    padding: 1.25em;
    color: var(--text-muted);
  }
  .nav-links li:is(.active, :hover) a {
    color: var(--dark);
  }

  :is(nav, .nav-links li, .btns) {
    transform: translate(0);
  }

  .cta{
    padding: 0.65em 1rem;
    /* padding-right: 0; */
  }
  .cta i {
    opacity: 0;
    transform: translateX(-8px);
  }
  .cta:is(:hover, :focus) {
    transform: translateY(-2px);
  }
  .cta:is(:hover, :focus) i {
    opacity: 1;
    transform: translate(0);
  }
  
  .more-btn{
    width: fit-content;
    border: 1px solid var(--dark);
  }
  .btns > * {
    margin: 0 0.5rem;
    border: 1px solid var(--accent);
  }
  .signin-btn {
    box-shadow: none;
    color: var(--dark);
  }
  .btns > *:hover {
    transform: translateY(-2px);
    background-color: var(--dark);
    color: var(--light);
  }
  .menu {
    display: none;
  }
  
  .about-section p{
    max-width: 65ch;
    text-align: left;
  }
  footer{
    text-align: left;
  }
  .footer-section{
    flex-direction: row;
    justify-content: space-between;
  }
  .footer-links{
    margin: 0;
  }
  .footer-logo {
    position: static;
    transform: translate(0);
    font-weight: 600;
  }
  .footer-section .copy-write{
    font-size: 2rem;
  }
}
