@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@100;200;300;400;500;600&display=swap");

:root {
  --text-color: hsl(0, 0%, 0%);
  --text-color-uno: #b74b4b;
  --bg-color: hsl(0, 0%, 85%);
  --bg-card-color: hsl(0, 0%, 20%);
  --bg-color-uno: hsl(0, 0%, 90%);
  --beaver: hsl(0, 28%, 16%);
  --bg-color-footer: hsl(0, 23%, 87%);
  --transition: 0.3s ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  text-decoration: none;
  border: none;
  outline: none;
  font-family: "Poppins", sans-serif;
}

html {
  font-size: 62.5%;
  scrollbar-width: thin;
  scrollbar-color: var(--beaver) var(--eerie-black);
  scroll-behavior: smooth;
}

body {
  width: 100%;
  height: 100vh;
  overflow-x: hidden;
  background-color: var(--bg-color-uno);
  color: var(--text-color);
  transition: var(--transition);
}

body.dark {
  --text-color: hsla(0, 12%, 75%, 1);
  --bg-color: hsl(0, 0%, 3%);
  --bg-card-color: hsl(0, 0%, 90%);
  --beaver: hsl(0, 5%, 44%);
  --eerie-black: #1f1f1f;
  --bg-color-uno: hsla(0, 2%, 10%, 1);
  --bg-color-footer: hsla(0, 0%, 11%, 1);
}

.container--loader {
  background-color: var(--eerie-black);
  position: fixed;
  width: 100vw;
  height: 100vh;
  z-index: 9999;
  transition: all 1.5s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.loader,
.loader:before,
.loader:after {
  border-radius: 50%;
  width: 2rem;
  height: 2rem;
  animation: loader 1.5s infinite ease-in-out;
}

.loader {
  color: var(--beaver);
  font-size: 13px;
  position: relative;
  animation-delay: -0.16s;
}

.loader:before,
.loader:after {
  content: "";
  position: absolute;
  top: 0;
}

.loader:before {
  left: -3.5rem;
  animation-delay: -0.32s;
}

.loader:after {
  left: 3.5rem;
}

@keyframes loader {
  0%,
  80%,
  100% {
    box-shadow: 0 2.5rem 0 -1.3rem;
  }
  40% {
    box-shadow: 0 2.5rem 0 0;
  }
}

/* ===================header Style================== */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 1rem 8% 0 9%;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  filter: drop-shadow(10px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 100;
  height: 75px;
  transition: var(--transition);
  backdrop-filter: blur(15px);
}

.toggle-theme {
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
  bottom: 30px;
}

.toggle-theme__icon {
  margin-right: 0.5em;
  width: 30px;
  color: var(--text-color-uno);
}

.logo {
  font-size: 3rem;
  color: var(--text-color-uno);
  font-weight: 800;
  cursor: pointer;
  transition: var(--transition);
}

.logo:hover,
.toggle-theme:hover {
  transform: scale(1.1);
}

.nav-links a {
  font-size: 1.8rem;
  color: var(--text-color);
  margin-left: 4rem;
  font-weight: 500;
  transition: var(--transition);
  border-bottom: 3px solid transparent;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-color-uno);
  border-bottom: 3px solid #b74b4b;
  animation: ease 0.4s left forwards;
}

.scroll-header {
  box-shadow: 0 -1px 4px rgba(0, 0, 0, 0.15);
}

.nav-links .fas {
  display: none;
}

.menu-icon,
.close-icon {
  display: none;
  font-size: 24px;
  cursor: pointer;
}

@media (max-width: 995px) {
  .home-img {
    margin-top: -100px;
    padding: -100px;
  }

  header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    top: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 60px;
    padding: 0 2rem;
    justify-content: space-between;
  }

  .nav-links.active {
    display: flex;
  }

  .nav-links a:hover,
  .nav-links a.active {
    border-bottom: none;
  }

  .nav-links a {
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 1.5rem;
    flex: 1 1 33%;
    max-width: calc(33.333% - 50px);
    font-weight: 900;
    transition: transform 0.3s ease, color 0.3s ease;
    position: relative;
  }

  .nav-links a i {
    font-size: 1.5rem;
  }

  .nav-links {
    display: none;
    position: fixed;
    left: 0;
    width: 100%;
    height: 30vh;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    padding: 8rem 5rem 12rem 0;
    background-color: var(--bg-color);
    gap: 10px;
  }

  .logo {
    font-size: 24px;
  }

  .switches {
    display: flex;
    gap: 5px;
    align-items: center;
  }

  .toggle-theme__icon {
    width: 24px;
    height: 24px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 24px;
    cursor: pointer;
  }

  .menu-icon {
    display: block;
    cursor: pointer;
  }

  .nav-links.show {
    display: flex;
  }

  .close-icon {
    display: block;
    position: absolute;
    bottom: 20px;
    right: 20px;
    cursor: pointer;
    font-size: 3rem;
    color: var(--text-color-uno);
  }

  .nav-links .fas {
    display: flex;
    font-size: 2.5rem;
  }
}

main {
  display: block;
  padding-top: 75px;
  box-sizing: border-box;
}

/*inicio */
.home {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8rem;
  max-width: 1400px;
  padding: 10px 20px;
}

.home .home-content h1 {
  font-size: 4rem;
  font-weight: 700;
  line-height: 1.3;
}

span.highlight {
  color: var(--text-color-uno);
}

.home-content h3 {
  font-size: 3rem;
  margin-bottom: 1rem;
  font-weight: 700;
}

.home-content p {
  font-size: 1.6rem;
  width: 90%;
  line-height: 1.8;
  margin-bottom: 2rem;
}

.home-img {
  border-radius: 50%;
}

.home-img img {
  position: relative;
  width: 32vw;
  border-radius: 50%;
  box-shadow: 0 0 25px solid var(--text-color-uno);
  cursor: pointer;
  transition: var(--transition);
}

.home-img img:hover {
  transform: scale(1.05);
}

.social-icons a {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: 4rem;
  height: 4rem;
  background-color: transparent;
  border: 0.2rem solid var(--text-color-uno);
  font-size: 2rem;
  border-radius: 50%;
  margin: 3rem 1.5rem 3rem 0;
  transition: var(--transition);
  color: var(--text-color-uno);
}

.social-icons a:hover {
  color: var(--text-color);
  transform: scale(1.3) translateY(-5px);
  background-color: var(--text-color-uno);
  box-shadow: 0 0 25px var(--text-color-uno);
}

.btn {
  display: inline-block;
  padding: 1rem 2.8rem;
  background-color: transparent;
  border-radius: 4rem;
  font-size: 1.6rem;
  color: var(--text-color-uno);
  letter-spacing: 0.3rem;
  font-weight: 600;
  border: 2px solid var(--text-color-uno);
  transition: 0.3s ease;
  cursor: pointer;
  text-decoration: none;
}

.btn:hover {
  transform: scale(1.03);
  background-color: var(--text-color-uno);
  color: var(--text-color);
  box-shadow: 0 0 25px var(--text-color-uno);
}

.typing-text {
  font-size: 3.4rem;
  font-weight: 600;
  min-width: 280px;
  height: 4.5rem;
  margin-bottom: 2rem;
  display: flex;
  align-items: center;
}

.typing-text .text {
  color: var(--text-color-uno);
  font-weight: 700;
  margin-left: 8px;
}

.typing-text .cursor {
  display: inline-block;
  width: 3px;
  height: 1.1em;
  background-color: var(--text-color-uno);
  margin-left: 4px;
  animation: blink 0.7s infinite;
  vertical-align: middle;
}

@keyframes blink {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0;
  }
}

@media (max-width: 1000px) {
  .home {
    gap: 4rem;
  }
}

@media (max-width: 995px) {
  .home {
    flex-direction: column;
    text-align: center;
  }

  .home .home-content h3 {
    font-size: 2.5rem;
  }

  .home-img img {
    margin-top: 6rem;
  }

  .home-content p {
    width: 100%;
  }

  .typing-text {
    font-size: 2.2rem;
    height: 3.2rem;
    justify-content: center;
  }
}

@media (max-width: 600px) {
  .home {
    max-width: 100%;
  }

  .home .home-content h1 {
    font-size: 3rem;
  }

  .typing-text {
    font-size: 2rem;
    height: 2.8rem;
  }

  .typing-text .text {
    font-size: 2.5rem;
  }

  .home-content h3 {
    font-size: 2rem;
  }
}

/* Sobre mí */
.sobreMi {
  height: auto;
}

.sobreMi h1 {
  display: block;
  text-align: center;
  color: var(--text-color);
  font-size: 3rem;
  letter-spacing: 0.1rem;
  padding-top: 6rem;
}

.container_content-sobreMi {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .sobreMi {
    padding-bottom: 4rem;
  }

  .sobreMi h1 {
    padding-top: 7rem;
    margin-top: 2rem;
    font-size: 3rem;
  }

  .container_content-sobreMi {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }

  .container_texto-sobreMi {
    width: 90%;
    margin: 0 100px;
  }

  .texto_sobreMi {
    text-align: start;
    font-size: 2rem;
    letter-spacing: 0.2rem;
    line-height: 2.8rem;
  }

  .image_sobreMi {
    width: 100%;
    margin-top: 70px;
  }
}

.container_texto-sobreMi {
  display: flex;
  flex-direction: column;
  padding: 4rem 3rem 3rem 3rem;
}

.title_sobreMi {
  color: var(--beaver);
  text-align: center;
  font-size: 2.2rem;
  letter-spacing: 0.1rem;
  font-weight: bold;
  margin-bottom: 2rem;
}

@media (min-width: 768px) {
  .title_sobreMi {
    text-align: start;
    font-size: 2.8rem;
    letter-spacing: 0.3rem;
  }
}

.texto_sobreMi {
  color: var(--text-color);
  font-size: 1.6rem;
  letter-spacing: 0.1rem;
  white-space: pre-line;
  line-height: 2.2rem;
}

.container_image-sobreMi {
  width: 100%;
  height: auto;
  display: flex;
  justify-content: center;
  padding: 1rem 0;
}

.image_sobreMi {
  width: 65%;
  margin-bottom: 5rem;
  border: none;
}

/* Habilidades */
.habilidades {
  height: auto;
  color: black;
}

.habilidades h1 {
  display: block;
  text-align: center;
  color: var(--text-color);
  font-size: 2.4rem;
  letter-spacing: 0.1rem;
  padding: 6rem 0 5rem 0;
}

.puntos1-habilidades,
.puntos2-habilidades {
  display: none;
}

.container_fondoPuntos--habilidades img {
  display: none;
}

.cards_container--habilidades {
  display: grid;
  grid-template-columns: 13rem 13rem;
  gap: 3rem;
  justify-content: center;
  padding-bottom: 1rem;
}

.cards--habilidades {
  background-color: hsla(0, 6%, 82%, 1.00);
  border-radius: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  /* filter: saturate(40%); */
  width: 13rem;
  height: 14rem;
}

.cards--habilidades img {
  margin-top: 0.7rem;
  width: 9rem;
}

.cards--habilidades p {
  color: var(--white);
  letter-spacing: 0.1rem;
  font-size: 1.4rem;
  margin-bottom: 0.7rem;
}

@media (min-width: 768px) {
  .habilidades {
    padding-bottom: 8rem;
    position: relative;
  }

  .habilidades h1 {
    padding-top: 8rem;
    font-size: 3rem;
  }

  .puntos1-habilidades {
    display: inline;
    position: absolute;
    width: 6rem;
    margin: 15rem 0 0 /* 41rem */ 20%;
    background-attachment: fixed;
  }

  .puntos2-habilidades {
    display: inline;
    position: absolute;
    width: 6rem;
    margin: 0 0 0 76%;
  }

  .cards_container--habilidades {
    grid-template-columns: 14rem 14rem 14rem;
    padding: 0;
    margin-top: 2rem;
  }

  .cards--habilidades p {
    font-size: 1.6rem;
    margin-top: 0.8rem;
  }
}

.cards--habilidades:hover {
  filter: saturate(100%);
  border: 1px solid var(--text-color-uno);
  transition: all 1s;
}

/* Formación */
.formacion {
  margin-bottom: 5rem;
  color: black;
}

.formacion h1 {
  display: block;
  text-align: center;
  font-size: 3rem;
  letter-spacing: 0.1rem;
  padding: 6rem;
}

.cards_container--formacion {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0 2rem 1rem 2rem;
}

@media (min-width: 768px) {
  .formacion h1 {
    padding: 7rem;
    margin-top: 2rem;
    font-size: 3rem;
  }

  .cards_container--formacion {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    padding: 0 2rem 1rem 2rem;
  }
}

.cards--formacion {
  background-color: hsla(0, 6%, 82%, 1.00);
  border-radius: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 33rem;
  height: 35rem;
  margin: 1rem 5rem 2rem 5rem;
  padding: 1rem;
  justify-content: space-between;
}

.cards--formacion img {
  width: 100%;
}

img.logo-unal {
  width: 100%;
}

img.logo-freeCodeCamp {
  width: 90%;
}

.cards--formacion p:nth-child(1) {
  letter-spacing: 0.1rem;
  font-size: 2.1rem;
  font-weight: 900;
  margin-bottom: 0.7rem;
}

.cards--formacion:hover {
  border: 1px solid var(--text-color-uno);
  box-shadow: 0 10px 16px -6px rgb(5 5 5 / 30%),
    0 25px 10px -24px rgb(5 5 5 / 10%);
  transform: scale(1.1);
  transition: 0.4s all;
}

/* project style */
.proyectos {
  padding: 4rem 0;
  margin-bottom: 5rem;
}

.proyectos h1 {
  display: block;
  text-align: center;
  font-size: 3rem;
  letter-spacing: 0.1rem;
  padding: 3rem 2rem 7rem 2rem;
  font-weight: 900;
}

/* Contenedor principal del carrusel */
.carrusel-container {
  max-width: 1000px;
  margin: 0 auto;
  position: relative;
  padding: 0 2rem;
}

/* Carrusel con scroll-snap */
.carrusel-proyectos {
  display: flex;
  gap: 5rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: 1rem 0;
  scrollbar-width: none; /* Ocultar scrollbar en Firefox */
}

.carrusel-proyectos::-webkit-scrollbar {
  display: none; /* Ocultar scrollbar */
}

/* Tarjeta individual */
.card-proyecto {
  scroll-snap-align: start;
  flex: 0 0 calc(30% - 1.2rem); /* 3 tarjetas con gap incluido */
  border-radius: 16px;
  overflow: hidden;
  background-color: var(--bg-color);
  box-shadow: 0 3px 13px rgba(0, 0, 0, 0.2);
  transition: var(--transition), box-shadow 0.3s ease;
}

/* Contenedor de imagen */
.img-container {
  position: relative;
  width: 100%;
  height: 180px;
  overflow: hidden;
}

.card-proyecto img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Overlay al hover */
.overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(23, 23, 23, 0.9);
  color: white;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 1rem;
  opacity: 0;
  transition: opacity var(--transition);
  text-align: center;
}

.card-proyecto:hover .overlay {
  opacity: 1;
}

.descripcion-proyecto {
  font-size: 0.9rem;
  margin: 0.8rem 0;
}

.botones-proyecto {
  display: flex;
  gap: 0.8rem;
}

.botones-proyecto a {
  background-color: var(--text-color-uno);
  color: var(--text-color);
  padding: 0.4rem 0.8rem;
  border-radius: 8px;
  text-decoration: none;
  font-size: 1.2rem;
  transition: var(--transition);
}

.botones-proyecto a:hover {
  background-color: #e05c5c;
}

.card-content {
  padding: 1rem;
}

.card-title {
  font-size: 1.5rem;
  text-align: center;
  margin-bottom: 0.5rem;
  font-weight: bold;
}

.card-desc {
  font-size: 0.9rem;
  font-size: 1.2rem;
  line-height: 1.4;
  color: var(--text-color);
}

/* Efecto hover tarjeta */
.card-proyecto:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

/* Flechas de navegación */
.carrusel-nav {
  display: flex;
  justify-content: center;
  margin-top: 1.5rem;
  gap: 1rem;
}

.nav-btn {
  background-color: var(--text-color-uno);
  color: var(--text-color);
  border: none;
  width: 50px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  transition: background-color 0.3s;
}

.nav-btn:hover {
  background-color: #e05c5c;
}

/* Responsive */
@media (max-width: 992px) {
  .card-proyecto {
    flex: 0 0 calc(50% - 1.2rem); /* 2 tarjetas */
  }
  .carrusel-proyectos {
    gap: 1.7rem;
  }
}

@media (max-width: 600px) {
  .card-proyecto {
    flex: 0 0 calc(100% - 1.2rem); /* 1 tarjeta */
  }
}

/* contact Style */
.contact {
  padding-bottom: 7rem;
  margin-bottom: 5rem;
}

.contact .h1 {
  display: block;
  text-align: center;
  font-size: 3rem;
  letter-spacing: 0.1rem;
  padding: 6rem 2rem 4rem 2rem;
  font-weight: 900;
}

@media (min-width: 768px) {
  .contact .h1 {
    padding: 7rem 0 3rem;
    margin-top: 1rem;
    font-size: 3rem;
  }
}

.contact .main {
  width: 340px;
  height: 420px;
  border: 2px solid var(--text-color-uno);
  box-shadow: 0 0 10px white;
  outline: none;
  padding: 10px;
  text-align: center;
  border-radius: 12px;
  margin: 1rem auto;
}

.main h1 {
  font-size: 22px;
  font-weight: bold;
}

.main .sanjay {
  width: 90%;
  padding: 10px;
  margin: 10px;
  border-radius: 10px;
  background-color: transparent;
  color: var(--text-color);
  font-size: 14px;
  font-weight: bold;
  border: 1px solid var(--text-color-uno);
  outline: none;
}

.main .text {
  width: 90%;
  padding: 10px;
  margin: 20px;
  border: 1px solid var(--text-color-uno);
  border-radius: 10px;
  box-shadow: 0 0 10px white;
  outline: none;
  font-size: 14px;
  font-weight: bold;
  color: var(--text-color);
  background-color: transparent;
}

.main .send {
  width: 90%;
  padding: 10px;
  margin: 20px;
  background-color: transparent;
  border: 2px solid var(--text-color-uno);
  box-shadow: 0 0 10px white;
  outline: none;
  color: var(--text-color-uno);
  border-radius: 10px;
  font-size: 20px;
  font-weight: 800;
  cursor: pointer;
  transition: var(--transition);
}

.main .send:hover {
  scale: 1.1;
  background-color: var(--text-color-uno);
  color: var(--text-color);
}

.main .icon {
  position: absolute;
  margin-left: 270px;
  margin-top: -40px;
}

.main .icon i {
  color: var(--text-color-uno);
}

/* Footer */
footer {
  background-color: var(--bg-color-footer);
}

@media (max-width: 995px) {
  footer {
    padding-bottom: 1rem;
  }
}

.contianer--footer {
  border-top: 1px solid var(--jet);
  width: 90%;
  margin: 0 auto;
  padding-top: 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.container_redes-footer {
  gap: 2.5rem;
  flex-wrap: wrap;
  justify-content: space-between;
  margin-bottom: 0rem;
}

.contact__title,
.contact__subtitle {
  font-size: 1.2rem;
  padding: 1px;
}

@media (min-width: 768px) {
  .contact__title,
  .contact__subtitle {
    font-size: 1.5rem;
    padding: 1px;
  }
  .container_redes-footer {
    display: flex;
  }
  .container_text--footer {
    margin: 1rem 0;
  }
}

.container_text--footer {
  text-align: center;
  font-size: 0.875rem;
}

.container_text--footer span {
  font-size: 1.5rem;
  letter-spacing: 1px;
}

.container_text--footer span:nth-child(1),
.container_text--footer span:nth-child(3) {
  color: var(--beaver);
}

.container_text--footer span:nth-child(4) {
  color: var(--beaver);
  letter-spacing: 0.1rem;
  margin-left: 0.2rem;
}

.contact__information {
  padding: 1rem;
  text-align: center;
}

.contact__icon {
  font-size: 2rem;
  color: var(--text-color-uno);
}

/* Toast Notification */
#toast-container {
  position: fixed;
  top: 20px;
  right: 40%;
  z-index: 9999;
}

.toast {
  min-width: 250px;
  margin-bottom: 10px;
  padding: 15px 20px;
  border-radius: 8px;
  color: #fff;
  font-weight: bold;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  opacity: 0;
  transform: translateX(100%);
  transition: all var(--transition);
}

.toast.show {
  opacity: 1;
  transform: translateX(0);
}

.toast.success {
  background-color: #4caf50; /* verde */
}

.toast.error {
  background-color: #f44336; /* rojo */
}
