/* ==================================================
   MARIA PORTELL — ESTILOS GENERALES
   ================================================== */


/* ==================================================
   RESET
   ================================================== */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  height: 100%;
  margin: 0;
  padding: 0;
}

body {
  font-family: Arial, sans-serif;
  min-height: 100%;
  margin: 0;
  padding-top: 110px;
  display: flex;
  flex-direction: column;
  background-color: #fff;
  color: #111;
  overflow-x: hidden;
}


/* ==================================================
   HEADER
   ================================================== */

header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 110px;
  background-color: #000;

  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;

  padding: 12px 20px;
  z-index: 1000;
}


/* Título */

.titulo {
  position: static;
  color: white;
  font-weight: bold;
  font-size: 28px;
  text-align: center;
  user-select: none;
}

.titulo h1 {
  margin: 0;
}


/* Menú */

.menu ul {
  list-style: none;

  display: flex;
  justify-content: center;
  align-items: center;

  gap: 30px;
  margin-top: 10px;
}

.menu a {
  color: white;
  text-decoration: none;
  font-weight: bold;
  font-size: 18px;
  transition: color 0.3s ease;
}

.menu a:hover {
  color: #888;
}


/* ==================================================
   CONTENIDO GENERAL
   ================================================== */

main {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  flex: 1;
}


/* ==================================================
   ABOUT PAGE
   ================================================== */


/* CARRUSEL */

.carrusel {
  width: 100vw;
  height: 800px;
  overflow: hidden;
  position: relative;
  margin-top: 0;
}

.slides {
  display: flex;
  width: calc(100vw * 4);
  height: 100%;
  transition: transform 0.5s ease-in-out;
}

.slide {
  flex: 0 0 100vw;
  height: 100%;
  position: relative;
  overflow: hidden;

  background-repeat: no-repeat;
  background-position: center;
  background-size: cover;
}


/* FRASE ABOUT */

.bienvenida {
  margin-left: 50px;
  margin-top: 70px;
}

.bienvenida h2 {
  font-size: 5rem;
  font-weight: 700;
}
/* =========================
   TEXTO ABOUT
   ========================= */

.about-text {
  width: 100%;
  max-width: 1100px;
  margin: 100px auto 140px;
  padding: 0 50px;
}

.about-text p {
  font-size: 1.35rem;
  line-height: 1.65;
  font-weight: 400;
  margin: 0 0 45px 0;
}

.about-text p:last-child {
  margin-bottom: 0;
}

.about-text .about-intro {
  font-size: 2rem;
  line-height: 1.25;
  font-weight: 700;
  margin-bottom: 55px;
}

/* ==================================================
   PÁGINAS INDIVIDUALES DE PROYECTOS
   ================================================== */

.project-page {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 70px 40px;
}


/* TÍTULO */

.project-intro {
  margin-bottom: 60px;
}

.project-intro h1 {
  font-size: 4rem;
  font-weight: 600;
  margin-bottom: 12px;
}

.project-role {
  font-size: 1rem;
  color: #666;
}


/* TEXTO */

.project-text {
  max-width: 650px;
  margin: 70px auto;
}

.project-text p {
  font-size: 1.15rem;
  line-height: 1.7;
}

.project-text p + p {
  margin-top: 25px;
}


/* IMAGEN GRANDE */

.project-image-full {
  display: block;
  width: auto;
  max-width: 100%;
  max-height: 750px;
  height: auto;
  margin: 70px auto;
  object-fit: contain;
}


/* DOS IMÁGENES */

.project-image-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin: 70px 0;
}

.project-image-grid img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
}


/* TRES IMÁGENES */

.project-image-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin: 70px 0;
}

.project-image-grid-3 img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
}


/* VÍDEO VERTICAL */

.project-video-vertical {
  display: flex;
  justify-content: center;
  width: 100%;
  margin: 70px 0;
}

.project-video-vertical video {
  display: block;
  width: 100%;
  max-width: 420px;
  height: auto;
}


/* VOLVER A PROJECTS */

.project-back {
  margin-top: 100px;
  margin-bottom: 40px;
}

.project-back a {
  color: #111;
  text-decoration: none;
  font-size: 1rem;
}

.project-back a:hover {
  text-decoration: underline;
}


/* ==================================================
   PROJECTS PAGE — GALERÍA GENERAL
   ================================================== */

.projects-feed {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2px;

  width: 100%;
  max-width: 1200px;

  margin: 60px auto 50px;
  padding: 0;
}

.project-tile {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  cursor: pointer;
  display: block;
}

.project-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;

  transition: transform 0.3s ease;
}

.project-tile .overlay {
  position: absolute;
  inset: 0;
  z-index: 2;

  display: flex;
  align-items: center;
  justify-content: center;

  background-color: rgba(0, 0, 0, 0);
  color: white;

  font-size: 1.2rem;
  font-weight: bold;
  text-align: center;

  padding: 15px;
  opacity: 0;

  transition:
    background-color 0.3s ease,
    opacity 0.3s ease;

  pointer-events: none;
}

.project-tile:hover img {
  transform: scale(1.05);
}

.project-tile:hover .overlay {
  background-color: rgba(0, 0, 0, 0.6);
  opacity: 1;
}


/* ==================================================
   CONTACT PAGE
   ================================================== */

.contact-section {
  text-align: center;
  padding: 20px 0;
  margin-top: 100px;
  flex: 1;
}

.contact-title {
  font-size: 4rem;
  margin-bottom: 60px;
  font-weight: 600;
}

.contact-container {
  display: flex;
  justify-content: center;
  align-items: center;

  gap: 80px;
  margin-top: 20px;

  flex-wrap: wrap;
}

.contact-item {
  position: relative;
  width: 400px;
  height: 400px;
}

.contact-item img {
  width: 100%;
  height: auto;
  display: block;

  transition: opacity 0.3s ease;
}

.contact-hover {
  position: absolute;
  top: 50%;
  left: 50%;

  transform: translate(-50%, -50%);

  font-family: Arial, sans-serif;
  font-size: 26px;
  font-weight: 600;

  opacity: 0;
  transition: opacity 0.3s ease;

  pointer-events: none;
  color: #111;
}

.contact-item:hover img {
  opacity: 0;
}

.contact-item:hover .contact-hover {
  opacity: 1;
}


/* ==================================================
   FOOTER
   ================================================== */

footer {
  background-color: #000;
  color: white;

  padding: 20px 40px;

  font-size: 14px;
  user-select: none;
  text-align: center;

  width: 100%;
}

.footer-container {
  max-width: 900px;
  margin: 0 auto;

  display: flex;
  align-items: center;
  justify-content: space-between;
}

.social-icons a {
  margin-right: 20px;
  display: inline-block;

  transition: opacity 0.3s ease;
}

.social-icons a:last-child {
  margin-right: 0;
}

.social-icons a:hover {
  opacity: 0.7;
}

.social-icons img {
  width: 24px;
  height: 24px;
  display: block;

  filter: invert(1);
}


/* ==================================================
   RESPONSIVE — TABLET
   ================================================== */

@media (max-width: 900px) {

  .projects-feed {
    grid-template-columns: repeat(3, 1fr);
  }

}


/* ==================================================
   RESPONSIVE — MÓVIL / TABLET PEQUEÑA
   ================================================== */

@media (max-width: 768px) {


  /* ABOUT — CARRUSEL */

  .carrusel {
    width: 100vw;
    height: 300px;
  }

  .slides {
    width: calc(100vw * 4);
    height: 100%;
  }

  .slide {
    flex: 0 0 100vw;
    height: 100%;

    background-size: cover;
    background-position: center;
  }


  /* ABOUT — FRASE */

  .bienvenida {
    margin-left: 0;
    margin-top: 50px;
    padding: 0 20px;
  }

  .bienvenida h2 {
    font-size: 2.5rem;
    text-align: center;
  }
   
/* =========================
   TEXTO ABOUT
   ========================= */

.about-text {
  width: 100%;
  max-width: 1100px;
  margin: 100px auto 140px;
  padding: 0 50px;
}

.about-text p {
  font-size: 1.35rem;
  line-height: 1.65;
  font-weight: 400;
  margin: 0 0 45px 0;
}

.about-text p:last-child {
  margin-bottom: 0;
}

.about-text .about-intro {
  font-size: 2rem;
  line-height: 1.25;
  font-weight: 700;
  margin-bottom: 55px;
}

  /* CONTACT */

  .contact-title {
    font-size: 2.5rem;
  }

  .contact-container {
    gap: 40px;
    padding: 0 20px;
  }

  .contact-item {
    width: 100%;
    max-width: 350px;

    height: auto;
    aspect-ratio: 1 / 1;
  }

}


/* ==================================================
   RESPONSIVE — MÓVIL
   ================================================== */

@media (max-width: 600px) {


  /* =========================
     HEADER MÓVIL
     ========================= */

  body {
    padding-top: 100px;
  }

  header {
    height: 100px;
    padding: 10px 15px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
  }

  .titulo {
    font-size: 22px;
    text-align: center;
    width: 100%;
  }

  .titulo h1 {
    margin: 0;
    line-height: 1;
  }

  .menu {
    width: 100%;
  }

  .menu ul {
    width: 100%;

    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;

    gap: 22px;
    margin-top: 10px;
  }

  .menu a {
    font-size: 16px;
    white-space: nowrap;
  }


  /* =========================
     PÁGINAS DE PROYECTO
     ========================= */

  .project-page {
    padding: 40px 20px;
  }

  .project-intro {
    margin-bottom: 40px;
  }

  .project-intro h1 {
    font-size: 2.5rem;
  }

  .project-text {
    margin: 50px auto;
  }

  .project-text p {
    font-size: 1rem;
    line-height: 1.6;
  }


  /* IMAGEN GRANDE */

.project-image-full {
  width: auto;
  max-width: 100%;
  max-height: 600px;
  margin: 40px auto;
}


  /* DOS IMÁGENES */

  .project-image-grid {
    grid-template-columns: 1fr;
    gap: 15px;
    margin: 50px 0;
  }


  /* TRES IMÁGENES */

  .project-image-grid-3 {
    grid-template-columns: 1fr;
    gap: 15px;
    margin: 50px 0;
  }


  /* VÍDEO */

  .project-video-vertical {
    margin: 50px 0;
  }

  .project-video-vertical video {
    width: 100%;
    max-width: 100%;
    height: auto;
  }


  /* BACK */

  .project-back {
    margin-top: 60px;
  }


  /* =========================
     PROJECTS
     ========================= */

  .projects-feed {
    grid-template-columns: repeat(3, 1fr);
    margin-top: 40px;
  }

  .project-tile .overlay {
    font-size: 0.85rem;
    padding: 8px;
  }


  /* =========================
     FOOTER
     ========================= */

  footer {
    padding: 20px;
  }

  .footer-container {
    flex-direction: column;
    gap: 15px;
    text-align: center;
  }

  .footer-text {
    order: 1;
  }

  .social-icons {
    order: 2;
  }

}
