/* Fuentes */
@import url("https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap"); /* Poppins */
@import url('https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&family=JetBrains+Mono:ital,wght@0,100..800;1,100..800&family=Source+Sans+3:ital,wght@0,200..900;1,200..900&display=swap');
:root {
  --color-base: rgb(165, 95, 220);
  --fuente-base: "Poppins";
}

/* Animaciones al cargar la página */

/* Presentación */
#presentacion {
  animation: presentacion 1.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;
}

@keyframes presentacion {
  0% {
    transform: translateY(+300px);
  }
  100% {
    transform: translateY(0px);
  }
}

/* Resto */
.navbar,
.sidebar,
#sobremi,
#proyectos,
#skills,
#contacto {
  animation: inicio 2s;
}

@keyframes inicio {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 100%;
  }
}


/* Animaciones al hacer scroll */

@keyframes show {
  from {
    opacity: 0;
    scale: 25%;
  }

  to {
    opacity: 1;
    scale: 100%;
  }
}

#proyectos, #skills {
  view-timeline-name: --section;
  view-timeline-axis: block;

  animation-timeline: --section;
  animation-name: show;

  animation-range: entry 25% cover 50%;
  animation-fill-mode: both;
}

/* Fin animaciones */

body,
html {
  margin: 0;
  padding: 0;
  height: 100%;
}

/** General */
ul {
  list-style-type: none;
}

* {
  font-family: var(--fuente-base);
}

#sobremi,
#proyectos,
#contacto,
#skills {
  font-size: 1.3em;
}

/** Títulos */

.title {
  align-items: left;
  font-size: 5vw;
  font-weight: bold;
}

/** Fondo */
html[scheme="light-mode"] body {
  background-color: white;
  color: black;
}


html[scheme="dark-mode"] body {
  background-color: black;
  color: white;
}



body {
  transition: background-color 0.5s ease;;
  margin: 0 15%;
}

/** Logo */

#logo {
  width: 15%;
}

#logo img {
  width: 100%;
}

html[scheme="light-mode"] #logo {
  content: url(Img/logo_negro.svg) !important;
}

/** Dark/light button */

html[scheme="dark-mode"] .sun {
  display: none;
}

html[scheme="dark-mode"] .moon {
  display: block;
  animation: keyframes-fill 0.5s ease;
}

html[scheme="light-mode"] .sun {
  display: block;
  animation: keyframes-fill 0.5s ease;
}

html[scheme="light-mode"] .moon {
  display: none;
}

/* Hide checkbox */
.dark-light input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

/* ------ Animation ------ */
@keyframes keyframes-fill {
  0% {
    transform: rotate(-360deg) scale(0);
    opacity: 0;
  }

  75% {
    transform: rotate(25deg);
  }
}

/** RRSS */

#rrss {
  padding-right: 30px;
}

.icon {
  width: 2.5vw;
  height: auto;
  margin-left: 1vw;
}

#rrss .navlink img {
  width: auto;
}

html[scheme="light-mode"] #linkedin {
  content: url(Img/icons/linkedin_dark.svg) !important;
}

html[scheme="light-mode"] #github {
  content: url(Img/icons/git_dark.svg) !important;
}

html[scheme="light-mode"] #instagram {
  content: url(Img/icons/insta_dark.svg) !important;
}

html[scheme="light-mode"] #twitter {
  content: url(Img/icons/twitter_dark.svg) !important;
}

html[scheme="light-mode"] #correo {
  content: url(Img/icons/correo_dark.svg) !important;
}

.nav-link #linkedin:hover {
  filter: drop-shadow(0px 0px 10px rgba(0, 119, 181, 0.8));
}

.nav-link #github:hover {
  filter: drop-shadow(0px 0px 10px rgba(240, 240, 240, 0.8));
}

.nav-link #twitter:hover {
  filter: drop-shadow(0px 0px 10px rgba(240, 240, 240, 0.8));
}

.nav-link #correo:hover {
  filter: drop-shadow(0px 0px 10px rgba(253, 81, 81, 0.8));
}

.nav-link #instagram:hover {
  filter: drop-shadow(0px 0px 10px rgba(221, 42, 123, 0.8));
}

#rrss #nav-link {
  overflow: hidden;
  transition: transform 10s ease-in-out;
}

.nav-link img:hover {
  transform: scale(
    1.3
  ); /* Escalar la imagen al 110% del tamaño original al pasar el cursor sobre ella */
}

/** Nav */

.sidebar {
  position: fixed;
  top: 40%;
  left: 0;
  z-index: 100;
  box-shadow: inset -1px 0 0 rgba(0, 0, 0, 0.1);
}

.sidebar .nav-link {
  font-family: var(--fuente-base);
  font-weight: bold;
  color: var(--color-base);
}

/** Presentación */

.hello {
  font-weight: bold;
  font-size: 6vw;
  text-align: left;
}

.hello span {
  color: var(--color-base);
}

#subtitle {
  font-size: 2vw;
  text-align: left;
  padding-bottom: 1%;
}

#presentacion {
  padding: 10% 0;
  padding-top: 3%;
  padding-bottom: 4%;
}

/* Botón curriculum */
#boton-cv {
  font-size: 2vw;
}

/* estilos de los botones */
#boton-cv {
  margin: 0;
  height: auto;
  background: transparent;
  padding: 0;
  border: none;
  cursor: pointer;
  --border-right: 6px;
  --text-stroke-color: rgba(133, 133, 133, 0.6);
  --animation-color: var(--color-base);
  --fs-size: 2em;
  letter-spacing: 3px;
  text-decoration: none;
  font-size: var(--fs-size);
  font-family: "Arial";
  position: relative;
  text-transform: uppercase; 
  color: transparent; 
  -webkit-text-stroke: 1px var(--color-base);
}
/* texto al hacer hover */
#boton-cv .hover-text {
  position: absolute;
  box-sizing: border-box;
  content: attr(data-text);
  color: var(--animation-color);
  width: 0%;
  inset: 0;
  border-right: var(--border-right) solid var(--animation-color);
  overflow: hidden;
  transition: 0.5s;
  -webkit-text-stroke: 1px var(--animation-color);
}
/* hover */
#boton-cv:hover .hover-text {
  width: 100%;
  filter: drop-shadow(0 0 23px var(--animation-color));
}

.arrow-container {
  margin-top: 10%;
  padding: 0 50%;
  width: 50px;
  height: 50px;
}

.arrow {
  border-left: 25px solid transparent;
  border-right: 25px solid transparent;
  border-top: 25px solid #333;
  animation: bounce 4s infinite;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
      transform: translateY(0);
  }
  40% {
      transform: translateY(-10px);
  }
  60% {
      transform: translateY(-5px);
  }
}

/** Sección sobre mi */
.content {
  overflow: hidden; /* Esto es importante para que el texto fluya correctamente */
}

#sobremi p {
  font-size: 1.5vw;
}

/** Sección proyectos */

.card {
  border: 2px solid var(--color-base);
  background-color: transparent;
  transition: scale 0.3s ease-in-out;
}

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

.card:hover {
  scale: 110%;
  z-index: 99;
}

.card:hover .card {
  filter: blur(5px);
}

.card-title {
  color: var(--color-base);
}



/** Sección skills */
.skill-logos {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}

.skill-item img {
  margin: 1.2vw;
  width: 8vw;
  height: auto;
}

/* Al hacer hover en una skill el resto se quedan en B&N */
 .skill-item:hover {
  scale: 1.2;
  transition: 0.5s ease;
  z-index: 5;
  filter: grayscale(0%);
}

/*
.skill-logos:hover .skill-item:not(:hover) {
  filter: grayscale(100%);
} */

.etiqueta {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  background-color: rgba(0, 0, 0, 0.7);
  color: white;
  padding: 5px 10px;
  border-radius: 5px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.skill-item {
  position: relative;
  display: inline-block;
}

.skill-item:hover .etiqueta {
  opacity: 1;
}

/* Estilos generales para el botón */
.contact-button {
  position: fixed;
  bottom: 5%;
  right: 5%;
  width: 60px;
  height: 60px;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  overflow: hidden;
  transition-duration: 0.3s;
  background-color: var(--color-base);
}

.contact-button a {
  text-decoration: none;
  justify-content: center;
}

.contact-button .sign {
  width: 100%;
  transition-duration: 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Texto */
.contact-button .text {
  right: 0%;
  width: 0%;
  opacity: 0;
  font-size: 1.2em;
  font-weight: 600;
  transition-duration: 0.3s;
}

/* Hace que se haga más grande */
.contact-button:hover {
  width: 140px;
  border-radius: 40px;
  transition-duration: 0.3s;
  text-align: center;
}

.contact-button img {
  width: 80%;
}

.contact-button:hover img {
  display: none;
}

.contact-button:hover .text {
  opacity: 1;
  width: 80%;
  transition-duration: 0.3s;
  color: white;
}

/* Animación cuando se hace click */
.contact-button:active {
  transform: translate(2px, 2px);
}

/* Footer */
footer {
  padding: 20px 0;
}

/** Responsive para móviles */

@media only screen and (max-width: 1023px) {
  /* Animaciones al cargar la página */

  /* Botón contacto */

  .contact-button {
    bottom: 2%;
    right: 5%;
  }

  /* Presentación */
  #presentacion {
    animation: presentacion 1.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;
  }

  @keyframes presentacion {
    0% {
      transform: translateY(+300px);
    }
    100% {
      transform: translateY(0px);
    }
  }

  /* Resto */
  .navbar,
  .sidebar,
  #sobremi,
  #proyectos {
    animation: inicio 2s;
  }

  @keyframes inicio {
    0% {
      opacity: 0;
    }
    100% {
      opacity: 100%;
    }
  }

  #skills {
    animation-name: none !important;
  }

  /** Títulos */

  .title {
    align-items: left;
    font-size: 8vw;
    font-weight: bold;
    margin-left: 0;
    padding-left: 0;
  }

  body {
    margin: 0;
  }

  header {
    margin: 0 3% 0;
    display: grid;
    place-items: center;
  }

  header .navbar {
    width: 100%;
    margin-top: 5%;
    padding: 0;
    margin-bottom: 5%;
  }

  /** Logo */

  #logo {
    width: 30%;
  }

  #logo img {
    width: 100%;
  }

  /** RRSS */

  #rrss {
    padding-right: 0px;
  }

  .icon {
    width: 5vw;
    height: auto;
    margin-left: 2vw;
  }

  #rrss .navlink img {
    width: auto;
  }

  #linkedin:hover,
  #github:hover,
  #twitter:hover,
  #correo:hover,
  #instagram:hover {
    filter: none;
  }

  #rrss #nav-link {
    display: none;
  }

  a img:hover {
    transform: none;
  }

  /** Nav */

  .sidebar {
    display: none;
  }

  /** Presentación */

  .hello {
    font-weight: bold;
    font-size: 8.3vw;
    text-align: left;
  }

  .hello span {
    color: var(--color-base);
  }

  #subtitle {
    font-size: 3vw;
    text-align: left;
    padding-bottom: 1%;
  }

  #boton-cv {
    font-size: 5vw;
    color: var(--color-base);
  }

  #presentacion {
    padding: 10% 0;
    padding-top: 3%;
    padding-bottom: 4%;
  }

  /* texto al hacer hover */
  .hover-text {
    display: none;
  }
  /* hover */
  .button:hover .hover-text {
    display: none;
  }

  .arrow-container {
    display: none;
    visibility: hidden;
  }

  /** Sección sobre mi */
  .content {
    overflow: hidden;
  }

  
  #sobremi p {
    font-size: 100%;
    text-align: center;
  }

  #sobremi .container {
    height: 50vh;
  }

  /** Sección proyectos */

  .card {
    border: 2px solid var(--color-base);
    background-color: transparent;
    margin-bottom: 15%;
  }

  .card-title {
    color: var(--color-base);
  }

  /** Sección skills */
  .skill-logos {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
  }

  .skill-item img {
    margin: 4vw;
    width: 20vw;
    height: auto;
  }

  .skill-item:hover {
    scale: 1.2;
    transition: 0.5s ease;
    z-index: 5;
  }

  .etiqueta {
    position: absolute;
    bottom: 10px; /* Ajusta la posición vertical según tu preferencia */
    left: 50%; /* Centra la etiqueta horizontalmente */
    transform: translateX(-50%);
    background-color: rgba(0, 0, 0, 0.7); /* Color de fondo con transparencia */
    color: white; /* Color del texto */
    padding: 5px 10px; /* Espaciado interior */
    border-radius: 5px; /* Bordes redondeados */
    opacity: 0; /* Inicialmente la etiqueta no es visible */
    transition: opacity 0.3s ease; /* Efecto de transición */
  }

  .skill-item {
    position: relative;
    display: inline-block;
  }

  .skill-item:hover .etiqueta {
    opacity: 1;
  }

  /* Footer */
  footer {
    padding: 20px 0;
  }
}
