* {
  /* outline: 1px solid red; */
  margin: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  background-color: #d4d8f0;
}


/* - - - Estilos generales - - - */
header, footer {
  width: 100%;
  color: #d6dbf1;
  background-color: #232946;
}

h2 {
  font-size: 28px;
}

h3 {
  font-size: 22px;
}

p {
  font-size: 18px;
  line-height: 1.5;
}


/* - - - Estilos específicos del header - - - */
.header {
  width: min(90%, 1200px);
  margin: auto;
}

/* Estilos de la barra de nav fixed */
.div-1 {
  background-color: #232946;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1;
}

.div-1_cont { 
  width: min(90%, 1200px);
  margin: auto;
  padding: 16px 0;

  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header-nav a {
  text-decoration: none;
  color: #d6dbf1;
  font-size: 20px;
  margin-left: 16px;
}

/* Estilos del texto inicial y la imágen */
.div-2 { 
  margin-top: 70px;
  padding: 32px 0 64px;

  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: 1fr;
  gap: 32px;
}

.div-2_text  {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 32px;
  
  /* <row-start> / <column-start> / <row-end> / <column-end>  */
  grid-area: 2 / 1 / 2 / 2; 
}

.div-2_text > p {
  font-size: 20px;
  line-height: 1.8;
}

/* Estilo del botón del párrafo */
.div-2_text  > a {
  display: inline-flex; /* para alinear el texto con el ícono */
  align-items: center;

  width: max-content;
  padding: 15px 25px;
  background-color: #d4939d;
  color: #232946;

  font-size: 20px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;

  transition: all 0.3s ease;
}

.div-2_text  > a:hover {
  background-color: #d4d8f0;
  transform: translateY(-3px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
}

.a-icon {
  margin-left: 8px;
}

/* Estilos de la imágen al lado del párrafo */
.div-2_img {
  padding: 0 16px;
  display: grid;
  place-content: center;
}

.div-2_img img {
  width: 100%;
  max-width: 500px;
  height: 100%;
}


/* - - - Estilos de la sección principal de las prácticas - - - */
main {
  width: min(90%, 1200px);
  min-height: 100vh;
  margin: 64px auto;

  display: flex;
  flex-direction: column;

}

.main-header {
  text-align: center;
  display: grid;
  gap: 16px;
  margin-bottom: 64px;
  color: #232946;
}

.main-section {
  display: grid;
  grid-template-columns: repeat(
    auto-fill,
    minmax(min(100%, 400px), 1fr)
  );
  gap: 32px;
}


/* Estilos de las cards del main */
.main-cardclick {
  display: block;
  position: relative;
  background-color: #fffffe;
  text-decoration: none;
  overflow: hidden;
  color: #232946;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);

  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.main-cardclick:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
}

.main-card {
  max-width: 75%;
  padding: 32px;

  display: flex;
  flex-direction: column;
  gap: 16px;
}

.main-card > div {
  display: flex;
  align-items: center;
  gap: 16px;
}

.background-image {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 50%;
  clip-path: polygon(50% 0, 100% 0, 100% 100%, 0 100%);

  background-image: url(https://zerojustice315.wordpress.com/wp-content/uploads/2016/02/310510.png); 
  background-size: cover;
  background-position: center;
  opacity: 0.2;
  transition: transform 0.3s ease;
  /* z-index: 1; */
}

.main-cardclick:hover .background-image {
  transform: scale(1.1);
}


/* - - - Boton fijo - - - */
.fixed-btn {
  width: 45px;
  height: 45px;
  border-radius: 50%;

  color: #d6dbf1;
  background-color: #232946;
  font-size: 12px;
  border: 3px solid #d4939d;

  position: fixed;
  bottom: 15px;
  right: 15px;

  display: grid;
  place-content: center;
  opacity: 0;

  transform: translateY(10px);
  animation: aparecer linear both;
  animation-timeline: scroll(root);
  animation-range: entry 20% 40%; 
  /* Empieza al hacer scroll, antes: 0 400px */
}

@keyframes aparecer {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}


/* - - - Estilos de la sección de información personal - - - */
.section {
  width: 100%;
  background-color: #eebbc3;
}

.section-info {
  width: min(90%, 1200px);
  height: 100%;
  margin: auto;
  padding: 64px 0;

  display: flex;
  flex-direction: column;
  gap: 32px;
}

/* div del texto y la foto de perfil */
.info-text {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.info-text > div {
  /* max-width: 450px; */
  min-width: 250px;
  display: flex;
  flex-direction: column;
  gap: 32px;
  color: #232946;
}

.info-text > div p {
  font-size: 20px;
  line-height: 1.8;
}

.info-cont_img {
  display: flex;
  justify-content: center;
  align-items: center;
}

.info-img {
  display: block;
  width: 100%;
  max-width: 400px;
  aspect-ratio: 1/1;
  object-fit: cover;
  object-position: bottom;
  filter: grayscale(0.8);
}

/* div de la Card art website soon */
.info-art {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.info-art > h2 {
  text-align: center;
  color: #232946;
}

/* estilos de la card para la página de arte */
.cont {
  width: 90%;
  margin: auto;
  height: 300px;

  background-color: #232946;

  position: relative;
}

/* box 0 */
.box-0 {
  width: 58%;
  height: 150px;
  clip-path: polygon(0 0, 100% 0, 75% 100%, 0 100%);
  background-color: aliceblue;

  position: absolute;
  left: 0;

  transition: .5s ease;

  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;

  padding: 16px;
}

.contenido-box-0 {
  background-color: #fffffe;
  width: 80%;
}

/* box 1 */
.box-1 {
  width: 58%;
  height: 150px;
  clip-path: polygon(25% 0, 100% 0, 100% 100%, 0 100%);
  background-color: blue;

  position: absolute;
  right: 0;

  transition: .5s ease;

  display: flex;
  justify-content: flex-end;
  align-items: flex-start;

  padding: 16px;
}

.contenido-box-1 {
  background-color: #fffffe;
  width: 70%;
}

/* box 2 */
.box-2 {
  width: 100%;
  height: 150px;
  background-color: red;

  position: absolute;
  bottom: 0;

  transition: .5s ease;

  /* alinear el boton en la esquina inferior */
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: flex-end;

  padding: 16px;
}

:is(.box-0, .box-1, .box-2):hover {
  transform: translateY(-10px);
}

/* .grid-art-cont {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  grid-template-rows: 150px 150px;
}

.part1 {
  grid-area: 1 / 1 / 1 / 4;
  clip-path: polygon(0 0, 100% 0, 75% 100%, 0% 100%);
}
.part2 {
  clip-path: polygon(25% 0, 100% 0, 100% 100%, 0% 100%);
  grid-area: 1 / 3 / 1 / 6;
}
.part3 {
  grid-area: 2 / 1 / 3 / 6;
}

:is(.part1, .part2, .part3) {
  transition: .5s ease;
}
:is(.part1, .part2, .part3):hover {
  transform: translateY(-10px);
} */

/* - - - Sección para las animaciones de entrada - - - */
/* .visible {
  opacity: 1;
  animation-duration: 1s;
  animation-fill-mode: both;
} */

.fade-left.visible {
  animation-name: fadeInLeft;
}

.fade-right.visible {
  animation-name: fadeInRight;
}

.fade-up.visible {
  animation-name: fadeInUp;
}

.fade-down.visible {
  animation-name: fadeInDown;
}

@keyframes fadeInLeft {
  from {
    opacity: 0;
    transform: translateX(-4rem);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeInRight {
  from {
    opacity: 0;
    transform: translateX(4rem);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(4rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-4rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

footer {
  height: 250px;
}


/* - - - Media queries obligado a poner - - - */
@media (width >= 750px) {

  /* header - responsive */
  .div-2 {
    grid-template-columns: 1fr 1fr;
  }

  .div-2_text  {
    /* <row-start> / <column-start> / <row-end> / <column-end>  */
    grid-area: 1 / 1 / 2 / 2; 
  }

  .div-2_img {
    padding: 0;
  }


  /* Seccion de acerca - responsive */
  .info-text {
    flex-direction: row;
  }

  .info-text > div {
    flex: 1;
  }

  .info-cont_img {
    flex: 1;
  }

  /* Seccion de la card para la página de arte */
  .cont {
    width: 90%;
    height: 200px;
  }

  .box-0 {
    width: 43%;
    height: 100%;
    clip-path: polygon(0 0, 100% 0, 75% 100%, 0 100%);

    left: 0;
  }

  .box-1 {
    width: 43%;
    height: 100%;
    clip-path: polygon(25% 0, 100% 0, 75% 100%, 0 100%);

    right: 28%;

    justify-content: flex-start;
    align-items: flex-end;
  }

  .box-2 {
    width: 43%;
    height: 100%;
    clip-path: polygon(25% 0, 100% 0, 100% 100%, 0 100%);

    right: 0;
    padding: 32px;
  }

  .contenido-box-1 {
    width: 100%;
  }
}