html {
  scroll-behavior: auto;
}

a {
  color: whitesmoke !important;
}

a:hover {
  text-decoration: none !important;
}

li {
  list-style: none;
}

body {
  font-family: "Inter", sans-serif;
}

/* Loader  */
#loader {
  width: 100%;
  height: 100%;
  text-align: center;
  color: red;
  align-self: center;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 20px;
  z-index: 9999;
  backdrop-filter: brightness(0.4);
}

/* From Uiverse.io by AbanoubMagdy1 */
.loader {
  --dim: 3rem;
  width: var(--dim);
  height: var(--dim);
  position: relative;
  animation: spin988 2s linear infinite;
  margin-top: 25%;
  margin-left: 49%;
}

.loader .circle {
  --color: #333;
  --dim: 1.2rem;
  width: var(--dim);
  height: var(--dim);
  background-color: var(--color);
  border-radius: 50%;
  position: absolute;
}

.loader .circle:nth-child(1) {
  top: 0;
  left: 0;
}

.loader .circle:nth-child(2) {
  top: 0;
  right: 0;
}

.loader .circle:nth-child(3) {
  bottom: 0;
  left: 0;
}

.loader .circle:nth-child(4) {
  bottom: 0;
  right: 0;
}

@keyframes spin988 {
  0% {
    transform: scale(1) rotate(0);
  }

  20%,
  25% {
    transform: scale(1.3) rotate(90deg);
  }

  45%,
  50% {
    transform: scale(1) rotate(180deg);
  }

  70%,
  75% {
    transform: scale(1.3) rotate(270deg);
  }

  95%,
  100% {
    transform: scale(1) rotate(360deg);
  }
}

/* From Uiverse.io by AbanoubMagdy1 end*/

.loaderBodyHide {
  overflow: hidden; /* Desactiva el desplazamiento */
}

/* Section Home */

#home {
  color: whitesmoke;
  text-align: center;
  height: 100vh;
  background-image: url("../imgs/Background.webp");
  background-size: cover;
  background-position-y: 60%;
  margin: 0;
  padding: 0;
}

/* NAVBAR */

.navBar {
  width: 100%;
  height: 15%;
  padding-top: 2%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}
.nav-sides {
  font-size: larger;
  margin-left: 4%;
  margin-right: 4%;
  width: 10%;
}


.home-nav {
  padding: 0;
  margin-right: 4vw;
  width: 20vw;
  display: flex;
  justify-content: space-between;
}

.home-nav li {
  margin-top: 6%;
  padding: 4%;
  width: 6vw;
}

.home-nav li a:hover {
  opacity: 0.4;
  transition: opacity 0.8s ease;
}

/* Hamburger menu icon */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  cursor: pointer;
  width: 30px;
  height: 25px;
}

.hamburger .line {
  height: 3px;
  background-color: whitesmoke;
  margin-bottom: 5px;
  border-radius: 200px;
}

/* Mobile nav (hidden by default) */
.mobile-nav {
  position: absolute;
  top: 80%;
  left: 0;
  width: 100%;
  background-color: #262320;
  height: 0;
  overflow: hidden;
  transition: height 0.3s ease;
  border-radius: 0 0 20px 20px;
}

.mobile-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
  text-align: center;
}

.mobile-nav ul li {
  padding: 1rem;
}

.mobile-nav ul li a {
  text-decoration: none;
  color: black;
}

/* Mobile nav active state */
.mobile-nav.active {
  height: 38vh; /* Desplegar todo el menú */
  transition: height 0.5s ease;
}


/* NAVBAR end */


.contactameButton {
  font-weight: 700;
}

.contactameButton:hover {
  cursor: pointer;
  opacity: 0.4;
  transition: opacity 0.8s ease;
}

.languages {
  cursor: pointer;
  margin: auto;
  justify-content: space-around;
}

.language-selected {
  cursor: default;
  font-weight: 700;
}

.language-selected:hover {
  cursor: default !important;
  opacity: 1 !important;
}

.languages li:hover {
  cursor: pointer;
  opacity: 0.4;
  transition: opacity 0.8s ease;
}

#scroll-down {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  margin: 0 auto;
  text-align: center;
  padding-bottom: 20px;
  width: 35vw;
  height: 10vh;
}

#home-mainContainer {
  width: 100%;
  height: 60vh;
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: space-evenly;
}

.avatar {
  width: 320px;
  height: 400px;
}

.avatar img {
  width: 100%;
  height: 100%;
  border-radius: 120px;
}

.home-info {

width: 25vw;

}

.home-info h1 {
  font-family: "Jost", sans-serif;
  font-weight: bold;
  font-size: 2rem;
}

.home-info h2 {

  font-weight: 400;
  font-size: 1.5rem;
}

.home-socials {
  margin: auto;
  width: 60%;
  display: flex;
  justify-content: space-evenly;
}

.home-socials a:hover {
  opacity: 0.4;
  transition: opacity 0.8s ease;
}

.home-btn {
  text-align: center;
  width: 40%;
  height: 8%;
  font-weight: bold;
  color: whitesmoke;
  background-color: transparent;
  border: 2px whitesmoke solid;
  border-radius: 20px;
}

.home-btn:hover {
  background-color: rgba(255, 255, 255, 0.2);
  transition: background-color 0.8s ease;
}

.home-btn:hover img {
  transform: scale(1.2);
  transition: transform 0.8s ease;
}

.home-btn:hover p {
  transform: scale(0.9);
  transition: transform 0.8s ease;
}

/* Section Trabajos */

#work {
  width: 100%;
  background-color: #262320;
  color: whitesmoke;
  margin: 0;
  padding: 0;
  justify-content: center;
}

#work ul {
  display: flex;
  width: 90vw;
  padding-top: 4vh;
  justify-content: center;
  margin: 0 auto;
}

#work ul li {
  text-align: center;
  background-color: whitesmoke;
  color: #262320;
  border: 2px solid whitesmoke;
  border-radius: 20px;
  margin: 4%;
  padding: 0 2%;
  height: 8%;
  font-weight: 600;
  font-size: 1.2rem;
  cursor: pointer;
  transition: all 0.3s ease; /* Transición suave para todos los cambios */
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* Sombra para efecto de elevación */
}

#work ul li:hover {
  opacity: 0.4; /* Cambié a 0.8 para que sea más visible en hover */
  transform: translateY(-3px); /* Efecto de desplazamiento */
  box-shadow: 0 6px 10px rgba(0, 0, 0, 0.15); /* Sombra más intensa en hover */
  transition: opacity 0.8s ease;
}

#work ul li:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(38, 35, 32, 0.3); /* Resaltado de enfoque */
}

.work-container {
  padding-top: 2vw;
  padding-bottom: 4%;
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
}

/* Estilos generales */
.work-cards {
  width: 40%;
  margin: 1% 1% 2%;
  display: flex;
  position: relative; /* Necesario para el enlace absoluto en mobile */
}

.work-cards-main {
  width: 100%;
  height: 45vh;
  background-size: cover;
  background-position: center;
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.work-cards:hover {
  cursor: pointer;
}

.work-cards h6 {
  padding: 2%;
  font-size: 1.4rem;
}

.work-cards-content {
  width: 100%;
  height: 100%;
  backdrop-filter: brightness(0.3);
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition: opacity 0.8s ease;
}

.work-cards:hover .work-cards-content {
  opacity: 1;
}

.work-cards-content p {
  width: 70%;
  text-align: center;
}

.work-cards-content a {
  padding: 2%;
}

.work-cards-content div {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
}

.work-cards-content button {
  width: 10vw;
  height: 4vh;
  font-weight: 600;
  font-size: 1.1rem;
  background-color: whitesmoke;
  border: 2px solid whitesmoke;
  color: whitesmoke;
  background-color: transparent;
  border: 4px solid lightgray;
  border-radius: 20px;
  opacity: 1;
}

.work-cards-content button:hover {
  color: #262320;
  background-color: whitesmoke;
  border: 2px solid whitesmoke;
  transition:
    background-color 0.8s ease,
    color 0.8s ease,
    border 0.8s ease;
}

/* Section Contacto */

#contact {
  margin: 0;
  padding: 0;
  padding-top: 2%;
  width: 100%;
  height: 100vh;
  background-color: #0a0c0a;
  color: whitesmoke;
  padding-top: 4%;
  text-align: center;
}

#contact h4 {
  text-transform: uppercase;
  font-family: "Jost", sans-serif;
}

#contact h5 {
  font-size: 1.6rem;
  font-weight: 700;
}

.container-contact {
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #0a0c0a;
}

.containerContact-background {
  width: 100%;
  height: 40vh;
  display: flex;
  justify-content: space-evenly;
  align-items: center;
  background-image: url("../imgs/Background.webp");
  background-size: cover;
  background-position-y: bottom;
}

.container-datos {
  height: 40vh;
  width: 30%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  color: white;
}

.contact-datos {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 4%;
}

.contact-datos h6 {
  font-size: 1.1rem;
}

.contact-datos img {
  width: 12%;
}

.contact-socials {
  width: 50%;
  display: flex;
  justify-content: space-around;
}

.contact-socials a:hover {
  opacity: 0.4;
  transition: opacity 0.8s ease;
}

.container-form {
  padding: 2% 0 0 0;
  margin: 0;
  width: 30%;
  background-color: whitesmoke;
  justify-content: center;
  align-items: center;
  display: flex;
  flex-direction: column;
  border-radius: 4px;
}

.container-form form {
  width: 100%;
  color: black;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.container-form form input,
textarea {
  width: 80%;
  padding-top: 2%;
  padding-bottom: 2%;
  margin-top: 4%;
  color: #262320;
  border: none;
  border-bottom: 3px solid black;
  background-color: transparent;
}

.custom-placeholder::placeholder {
  color: gray;
  background-color: #f8d7da;
  border-color: #f5c6cb;
  height: 80%;
  border-radius: 4px;
}

#contact form textarea {
  height: 12vh;
  resize: none;
}

::placeholder {
  padding: 2%;
  color: black;
}

#contact form button {
  margin: auto;
  margin-top: 6%;
  width: 10vw;
  height: 4vh;
  font-weight: 600;
  font-size: 1.1rem;
  color: whitesmoke;
  background-color: black;
  border: 2px solid black;
  border-radius: 20px;
}

#contact form button:hover {
  color: #262320;
  background-color: lightgray;
  transition:
    background-color 0.8s ease,
    color 0.8s ease,
    border 0.8s ease;
}

.input-container {
  position: relative;
  width: 100%;
  margin-bottom: 20px;
}

/* Footer */

footer {
  width: 100%;
  padding-top: 4%;
  color: whitesmoke;
  background-color: #0a0c0a;
}

.footer-container {
  height: 20%;
  margin: auto;
  padding-top: 2dvb;
  padding-bottom: 2%;
  width: 80%;
  border-top: 2px solid gray;
  display: flex;
  justify-content: space-around;
  align-items: center;
}

.footer-label {
  width: 33%;
  display: flex;
  flex-direction: column;
  text-align: center;
  align-items: center;
  justify-content: center;
}

.footer-socials {
  width: 33%;
  display: flex;
  flex-direction: column;
  text-align: center;
}

.footer-socials div {
  display: flex;
  text-align: center;
  justify-content: center;
}
.footer-socials img {
  padding: 2%;
  width: 60%;
}

.footer-links {
  width: 33%;
}

.footer-links ul {
  width: 100%;
  display: flex;
  text-align: center;
  justify-content: space-around;
  align-items: center;
  flex-wrap: wrap;
}

.footer-links ul li {
  text-align: center;
  margin: 2%;
}

/* Footer END*/

#sobreMi {
  color: whitesmoke;
  text-align: center;
  height: 100vh;
  background-image: url("../imgs/Background.webp");
  background-size: cover;
  background-position-y: 60%;
  margin: 0;
  padding: 0;
}

.sobreMi-cats {
  width: 300px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  margin-top: 6%;
}

.sobreMi-cats button {
  width: 15vw;
  height: 4vh;
  font-weight: 600;
  font-size: 1.1rem;
  background-color: whitesmoke;
  border: 2px solid whitesmoke;
  color: whitesmoke;
  background-color: transparent;
  border: 4px solid lightgray;
  border-radius: 20px;
  opacity: 1;
  margin: auto;
  margin-top: 6%;
}
.sobreMi-cats button:hover {
  color: #262320;
  background-color: whitesmoke;
  border: 2px solid whitesmoke;
  transition:
    background-color 0.8s ease,
    color 0.8s ease,
    border 0.8s ease;
}

.selected-button {
  color: #262320 !important;
  background-color: whitesmoke !important;
  border: 2px solid whitesmoke !important;
}

.sobreMi-bio {
  margin-top: 20vh;
  justify-content: center;
  align-items: center;
  text-align: left;
  font-size: 1.2rem;
}

.sobreMi-cats-container {
  display: flex;
  flex-wrap: wrap;
  width: 100%;
  padding-inline: 10vw;
  justify-content: center;
  background-color: #0a0c0a;
}
.sobreMi-cats-Content {
  display: none;
  height: 35vh;
  padding: 0.5%;
}

.animate__animated.animate__fadeIn {
  --animate-duration: 4s;
}

.sobreMi-cats-content:hover {
  filter: brightness(1.4);
  transition: filter 0.8s ease;
}
.sobreMi-cats-content img {
  height: 100%;
  width: 100%;
}

/* Responsive */

/* Tablet */
@media screen and (min-width: 768px) and (max-width: 1024px) {
}

/* Mobile */
@media screen and (max-width: 767px) {

  .loader{
    margin-top: 80%;
    margin-left: 45%;
  }
  
  /* Home */

/* NAVBAR */
.home-nav, .contactameButton, .nav-sides {
  display: none;
}

.navBar{
  height: 10%;
  justify-content: end !important;
}

.hamburger {
  display: flex;
  margin-right: 20px;
}

/* For languages */
.languages {
  justify-content: center;
  align-items: center;
  padding: 0;
}

.languages p{
  margin: 0;
}


/* NAVBAR end */

  #home-maincontainer {
    
    flex-direction: column-reverse;
    height: auto;

  }

  .home-info {
    margin-top: 10vh;
  }

  #home-maincontainer h2 {
    padding: 4% 0;
    text-align: left !important;
  }

  .avatar {
    display: none;
    width: 150px;
    height: auto;
  }

  .home-info {
    width: 80%;
  }

  .home-btn {
    width: 60%;
    height: 12%;
  }

  #scroll-down {
    width: 35vw;
  }

  /* sobre mi */

  #sobremi {
   
    height: auto;
  }
  .home-info {
    padding: 0;
  }

  .sobreMi-bio {
    margin-top: -5vh;
  }
  .sobreMi-cats a button {
    width: 50vw;
  }

  .sobreMi-cats-container {
    height: auto;
    padding-top: 12%;
  }

  .sobreMi-cats-container a {
    height: auto;
    padding: 4% 0;
  }
  /* Work */

  #work ul {
    display: flex;
    flex-wrap: wrap;
    padding: 4% 0;
  }

  #work ul li {
    width: 40%;
  }

  .work-container {
    flex-direction: column;
  }

  .work-cards {
    margin: auto;
    width: 90%;
    margin: 6% auto;
    position: relative; /* Necesario para el enlace completo */
  }

  .work-cards-main {
    height: 30vh;
  }

  .work-cards-content {
    display: none;
  }

  /* Ocultar botones y hacer clicable toda la tarjeta en mobile */
  .work-cards-content div {
    display: none;
  }

  .work-cards a {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 90%;
    z-index: 10;
    border-radius: 20px;
  }

  .work-cards-content {
    opacity: 1;
    transition: none;
  }

  /* Contact */

  #contact {
    height: auto; /* Ajustar la altura a 'auto' para quea el contenido fluya según su tamaño */
    padding: 5% 0; /* Añadir padding para dar espacio a los elementos */
  }

  #contact h4 {
    padding: 8% 0; /* Reducir el padding en móviles */
    font-size: 1.8rem; /* Ajustar el tamaño de fuente del título */
  }

  .container-contact {
    height: auto; /* Cambiar la altura a 'auto' para que se ajuste al contenido */
    width: 100%; /* Asegurar que la sección ocupe todo el ancho disponible */
    display: flex;
    flex-direction: column; /* Alinear el contenido en columna para móviles */
    align-items: center; /* Centrar el contenido */
  }

  .containerContact-background {
    height: auto; /* De nuevo, ajustar la altura para que dependa del contenido */
    width: 100%; /* Asegurar que la sección ocupe todo el ancho */
    display: flex;
    flex-direction: column-reverse; /* Alinear elementos en columna */
    align-items: center;
    padding: 5%; /* Espacio alrededor */
  }

  .container-datos {
    height: auto; /* Ajuste dinámico según el contenido */
    width: 100%; /* Asegurar que ocupe todo el ancho */
    margin-bottom: 5%; /* Añadir un margen inferior para separar del formulario */
    display: flex;
    flex-direction: column; /* Alinear en columna */
    align-items: center; /* Centrar contenido */
    text-align: center; /* Centrar texto */
  }

  .container-form {
    width: 100%; /* Asegurar que ocupe todo el ancho disponible */
    padding: 5%; /* Añadir un padding general */
    display: flex;
    flex-direction: column; /* Formularios en columna */
    align-items: center; /* Centrar los elementos del formulario */
  }

  #contact form button {
    width: 40vw;
    height: 10vw;
  }

  #msgSubmit {
    font-size: 1rem;
  }

  /* FOOTER */

  .footer-container {
    margin: 25% auto 0 auto;
    padding-top: 10%;
    flex-direction: column;
    text-align: center;
    width: 80%;
    height: 50vh;
    justify-content: center;
  }

  .footer-label,
  .footer-socials,
  .footer-links {
    width: 100%; /* Apilar verticalmente los elementos */
    margin-bottom: 2%;
  }

  .footer-socials img {
    width: 40%; /* Ajustar el tamaño de los íconos */
  }

  .footer-socials img {
    padding: 2%;
    width: 60%;
  }

  .footer-links {
    padding: 10% 0 !important;
    margin: 0 !important;
    width: 100%;
    justify-content: start;
    text-align: center;
  }

  .footer-links ul {
    padding: 0;
  }

  /* Footer END */
}
