/* ==================== */
/* FONTS */
/* ==================== */
@font-face {
  font-family: "IBM Plex Sans";
  src: url("../fonts/IBMPlexSans-Light.ttf") format("truetype");
  font-weight: normal;
  font-style: normal;
}

/* ==================== */
/* RESET & BASE */
/* ==================== */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: "IBM Plex Sans", sans-serif;
  margin: 0 auto;
  line-height: 1.6;
}

/* ==================== */
/* HEADER & NAVIGATION */
/* ==================== */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 60px;
  position: relative;
  z-index: 1000;
  color: #002fff;
  padding: 0 2%;
}

header h1, 
header h3 {
  margin: 0;
}

#menu-toggle {
  cursor: pointer;
  font-size: 2rem;
  user-select: none;
  transition: transform 0.3s, color 0.3s;
  color: #002fff;
  z-index: 1010;
  margin-top: 1.5%;
}

#menu-toggle.open {
  color: #fff;
}

#menu {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 80px;
  background-color: #002fff;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fff;
  font-size: clamp(1.3rem, 2vw, 3rem);
  transform: translateY(-100%);
  opacity: 0;
  transition: transform 0.4s ease, opacity 0.4s ease;
  z-index: 1000;
}

#menu.show {
  transform: translateY(0);
  opacity: 1;
}

#menu ul {
  display: flex;
  list-style: none;
  gap: 2rem;
}

#menu li a {
  color: #fff;
  text-decoration: none;
}

#menu li a:hover {
  text-decoration: underline;
}

/* ==================== */
/* MAIN LAYOUT */
/* ==================== */
main {
  padding: 0 2%;
  max-width: 1800px;
  margin: 0 auto;
}

/* ==================== */
/* PROJECT HEADER */
/* ==================== */
#project-header img {
  width: 100%;
  max-height: 100vh;
  object-fit: cover;
  border-radius: 6px;
  margin: 1rem 0;
}

.webcam-container {
  position: relative;
  max-width: 100%;
}

.webcam-container img {
  width: 100%;
  max-height: 100vh;
  object-fit: cover;
  border-radius: 6px;
  margin: 1rem 0;
}

.webcam-label {
  position: absolute;
  top: 30px;
  left: 20px;
  background-color: rgba(0,0,0,0.6);
  color: white;
  padding: 0.3rem 0.5rem;
  border-radius: 4px;
  font-size: clamp(0.9rem, 1vw, 1.5rem);
  pointer-events: none;
}

/* ==================== */
/* PROJECT INFO */
/* ==================== */
#project-title {
  font-size: 2rem;
  margin-bottom: 0.2rem;
}

#project-year-type {
  font-size: 1.2rem;
  margin-bottom: 1rem;
}

.typeEs {
  color: gray;
  font-style: italic;
}

#project-texts p {
  margin-bottom: 1rem;
  font-size: 1.2rem;
}

#project-descriptionEs {
  color: gray;
}

/* ==================== */
/* IMAGE GRIDS */
/* ==================== */
.images-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 50%), 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.images-grid img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 6px;
}

.extra-images {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1.5rem;
}

.extra-images img {
  width: 100%; 
  height: auto;
  border-radius: 6px;
}

/* ==================== */
/* EMBED VIDEOS */
/* ==================== */
.embed-container {
  --video-ratio: 16 / 9; 
  width: 100%;
  margin-top: 1%; 
}

.embed-container iframe {
  width: 100%;
  aspect-ratio: var(--video-ratio); 
  border: 0;
}

  .embed-container.multiple {
    grid-template-columns: 1fr;
  }

/* ==================== */
/* UTILITIES */
/* ==================== */
.hidden {
  display: none;
}

/* ==================== */
/* MEDIA QUERIES */
/* ==================== */
@media (min-width: 768px) {
  .embed-container {
    max-width: 1000px;
  }
  
  .embed-container.vertical {
    max-width: 500px;
  }

  .images-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 33.333%), 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

  .embed-container.multiple {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
}