/* FONTS */
@font-face {
  font-family: "primary-font";
  src: url("../assets/StretchPro.otf") format("truetype");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: "secondary-font";
  src: url("../assets/BebasNeue-Regular.ttf") format("truetype");
  font-weight: normal;
  font-style: normal;
}

@import url("https://fonts.googleapis.com/css2?family=Nunito+Sans:ital,opsz,wght@0,6..12,200..1000;1,6..12,200..1000&display=swap");

/*  */
:root {
  --color-primary: #e9ece1;
  --color-accent: #323402;
  --color-dark: #181818;
}

body {
  background-color: var(--color-primary);
  padding: 1rem;
  position: relative;

  overflow-x: hidden !important;
}

/* Noise effecct */
.bg {
  background-image: url("../assets/bg.jpg"); /* La ruta de la imagen de fondo */
  background-size: cover; /* Ajusta el tamaño de la imagen al contenedor */
  background-position: center; /* Centra la imagen */
  background-repeat: no-repeat; /* Evita que la imagen se repita */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  opacity: 0.05;
  z-index: 14;
}

/* nav */

.nav {
  width: 100%;
  display: flex;
  justify-content: space-between;
  position: fixed;
  left: 0;
  z-index: 20;
  top: 0;
  background-color: transparent;
  transition: 0.3s ease all;
}

nav.scrolled {
  background-color: var(--color-accent);
}
.nav-link.scrolled {
  color: var(--color-primary) !important;
}

.nav-ul {
  font-size: 1.3rem;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 4rem;
  padding: 0 1rem;
}

.nav-ul li {
  padding: 0.75rem;
}

.nav-ul li a {
  text-decoration: none;
  font-family: "secondary-font", sans-serif;
  font-weight: 400;
  font-style: normal;
  color: var(--color-accent);
  font-size: 2rem;
  margin: 1rem;
}

.logo {
  text-decoration: none;
  font-family: "secondary-font", sans-serif;
  font-weight: 400;
  font-style: normal;
  color: var(--color-accent);
  font-size: 2rem;
  margin: 1rem;
  width: 200px;
}

#logo-svg {
  width: 200px;
}

#logo-svg path.scrolled {
  fill: var(--color-primary);
}

/* header */

header {
  position: relative;
  z-index: 15;
}

.header-svg-title {
  width: 100%;
}

.header-svg-title img {
  width: 100%;
}

.header-description {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  text-align: left;

  width: clamp(100%, 50vw, 500px);
  max-width: 500px;
  line-height: 25px;

  font-size: clamp(16px, 1.2vw, 19px);
  font-family: "Nunito Sans", sans-serif !important;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
  font-variation-settings: "wdth" 100, "YTLC" 500;

  color: var(--color-accent);
  height: 70vh;
  padding-top: 30vh;
}

.header-description h1 {
  font-size: calc(clamp(3em, 5vw, 4.5em) * 0.75);
  font-family: "secondary-font", sans-serif;
  font-family: "secondary-font", sans-serif;
  font-weight: 400;
  font-style: normal;
  color: var(--color-accent);
}

/* main */

.main {
  margin-top: 30vh;
  height: 70vh;
  width: 100%;
  display: flex;
  flex-direction: row;
  align-items: center;

  position: relative;
  z-index: 10;
}

.main-description {
  width: 40%;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.main-description h2 {
  font-size: calc(clamp(3em, 5vw, 4.5em) * 0.75);
  font-family: "secondary-font", sans-serif;
  font-weight: 400;
  font-style: normal;
  color: var(--color-accent);
}

.main-description p {
  font-size: clamp(16px, 1.2vw, 19px);
  font-family: "Nunito Sans", sans-serif !important;
  font-optical-sizing: auto;
  font-weight: 400;

  line-height: 25px;
  font-style: normal;
  font-variation-settings: "wdth" 100, "YTLC" 500;

  color: var(--color-accent);
}

/* section 1 */

section {
  position: relative;
  z-index: 10;
}

.section-1 {
  height: 60vh;
  width: 100%;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
}

.section1-description {
  width: 40%;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.section1-description h2 {
  font-size: calc(clamp(3em, 5vw, 4.5em) * 0.75);
  font-family: "secondary-font", sans-serif;
  font-weight: 400;
  font-style: normal;
  color: var(--color-accent);
}

.section1-description p {
  font-size: clamp(16px, 1.2vw, 19px);
  font-family: "Nunito Sans", sans-serif !important;
  font-optical-sizing: auto;
  font-weight: 400;

  line-height: 25px;
  font-style: normal;
  font-variation-settings: "wdth" 100, "YTLC" 500;

  color: var(--color-accent);
}

/* footer */

.footer {
  margin-top: 10vh;
  padding-top: 3rem;
  height: 90vh;
  width: 100%;
  display: flex;
  justify-content: space-between;
  position: relative;
  align-items: start;
  flex-direction: column;
  z-index: 15;
}

.container-footer {
  display: flex;
  justify-content: center;
  width: 100%;
}
.container-footer img {
  width: 100%;
}

.footer-sm {
  width: 100%;
  height: 5rem;
}

.footer-sm ul {
  position: absolute;
  list-style: none;
  z-index: 10000;
  bottom: 0;
  left: 0;
  width: 100%;
  display: flex;
  justify-content: space-between;
}

.footer-sm a {
  font-family: "secondary-font", sans-serif;
  font-weight: 400;
  font-style: normal;
  color: var(--color-accent);
  text-decoration: none;
  font-size: 3rem;
}

/* CANVAS FOR 3D MODEL */
canvas {
  position: fixed;
  top: 0;
  z-index: 1;
  background-color: transparent;

  width: 100%;
  height: 100vh;
  left: 0;
}

/* BUTTONS */
button {
  width: 200px;
  padding: 1rem;
  border: 2px solid var(--color-accent);
  background-color: var(--color-accent);

  font-size: 1.2rem;

  font-family: "Nunito Sans", sans-serif !important;
  font-optical-sizing: auto;
  font-weight: 500;
  font-style: normal;
  font-variation-settings: "wdth" 100, "YTLC" 500;

  color: var(--color-primary);
}

/* Splash */

.splash-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: var(--color-primary);
  z-index: 20;
  opacity: 1;
  transition: opacity 0.2s ease-in-out;
}

.splash-logo img {
  width: 150px;
  height: auto;
  animation: logo-fade-in 2s ease forwards;
}

@keyframes logo-fade-in {
  0% {
    opacity: 0;
    transform: scale(0.7);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

.splash-container.fade-out {
  opacity: 0;
  transform: translateY(20);
  pointer-events: none;
}


/* SVG Circle Loader */
.circular-loader {
  width: 250px;
  height: 250px;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.circle-bg {
  fill: none;
  stroke: #f3f3f3;
  stroke-width: 1;
}

.circle {
  fill: none;
  stroke: #323402; /* Color de relleno (verde oscuro) */
  stroke-width: 1;
  stroke-linecap: round;
  animation: progress 3s ease-out forwards;
}

@keyframes progress {
  0% {
    stroke-dasharray: 0, 100;
  }
  100% {
    stroke-dasharray: 100, 0;
  }
}

/* RESPONSIVE */
@media (max-width: 430px) {
  .nav-ul {
    display: none;
  }
  .header-description {
    padding-top: 40vh;
  }
  .main {
    margin-top: 30vh;
  }

  .section-1 {
    margin-top: 20vh;
  }

  .section1-description,
  .main-description {
    width: 100%;
  }

  .footer {
    height: 70vh;
  }

  .footer-sm ul {
    flex-direction: column;
  }

  .footer-sm ul a {
    font-size: 2.5rem;
  }
}
