* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter_24pt-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter_28pt-Medium.ttf") format("truetype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter_24pt-SemiBold.ttf") format("truetype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter_24pt-ExtraLightItalic.ttf") format("truetype");
  font-weight: 200;
  font-style: italic;
  font-display: swap;
}

body {
  font-family: "Inter", sans-serif;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  background: white;
  color: #111;
  line-height: 1.4;
}

/* header */

.header {
  position: fixed;
  top: 0;
  left: 0;
  height: 65px;
  width: 100%;

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

  padding: 0px 40px;

  background: white;

  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);

  z-index: 1000;

  transition: box-shadow 0.3s ease;
}

body.scrolled .header {
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.12);
}

.logo {
  display: flex;
  align-items: baseline;
  gap: 8px;
  text-decoration: none; /* elimina subrayado */
  font-size: 18px;
  font-weight: 600;
  color: black; /* asegura color negro */
}

.logo .title {
  font-weight: 600;
  color: black;
}

.logo .role {
  font-weight: 600;
  font-size: 18px;
  color: #cdcdcd;
}

/* Evita que el hover cambie el color o subrayado */
.logo:hover,
.logo:visited,
.logo:active {
  color: inherit;
  text-decoration: none;
}

.header nav {
  display: flex;
  gap: 24px; /* espacio entre links */
}

.header nav a.nav-link {
  text-decoration: none;
  color: #cdcdcd;
  font-size: 14px;
  font-weight: 600;
  position: relative;
  transition: color 0.3s;
}

.header nav a.nav-link.active {
  color: #111; /* negro para la página activa */
  font-weight: 600;
}

.header nav a:hover {
  color: #111;
}

/* Subrayado animado al hover (profesional) */
.header nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0;
  height: 2px;
  background: #111;
  transition: width 0.3s ease;
}

.header nav a:hover::after {
  width: 100%;
}

.header nav a.active::after {
  width: 100%;
}

main {
  padding-top: 65px;
}

/* masonry */

.masonry {
  column-count: 3;
  column-gap: 8px;
  padding: 30px;
}

.masonry .project-title {
  font-weight: 600;
}

.masonry .project-subtitle {
  font-weight: 200;
  font-style: italic;
}

.item {
  opacity: 0;
  transform: translateY(20px) scale(0.98);
  transition:
    opacity 0.5s ease,
    transform 0.5s ease;
  break-inside: avoid;
  margin-bottom: 8px;
  position: relative;
  overflow: hidden;
  border-radius: 5px;
}

.item.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.item img {
  width: 100%;
  height: auto;
  display: block;
  transition:
    transform 0.3s ease,
    filter 0.3s ease;
  border-radius: 5px;
}
.item a {
  cursor: pointer;
}

.item:hover img {
  transform: scale(1.04);
  filter: brightness(40%);
}

/* hover overlay */

.overlay {
  position: absolute;
  bottom: 14px;
  left: 14px;
  color: white;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.item:hover .overlay {
  opacity: 1;
}

/* tablet */

@media (max-width: 1000px) {
  .masonry {
    column-count: 2;
  }
}

/* mobile */

@media (max-width: 600px) {
  .masonry {
    column-count: 1;
  }
}

.feature-media {
  display: block;
  border-radius: 5px;
  overflow: hidden;
}

.feature-media img,
.feature-media video {
  width: 100%;
  display: block;
  transition: 0.3s;
}

.feature-media:hover img {
  filter: brightness(40%);
  transform: scale(1.02);
}

.home-btn {
  position: fixed;
  top: 20px;
  right: 80px;
  visibility: hidden;
}

@media (max-width: 600px) {
  .home-btn {
    visibility: visible;
  }
}

.home-btn a {
  text-decoration: none;
  color: black;
  font-size: 14px;
  border: 1px solid #111;
  padding: 6px 12px;
  border-radius: 4px;
  transition: all 0.5s;
}

.home-btn a:hover {
  background: black;
  color: white;
}

.contact-form {
  max-width: 600px;
  margin: 120px auto 100px;
  padding: 20px;
}

.contact-form h2 {
  margin-bottom: 30px;
  font-size: 24px;
}

.contact-form label {
  display: block;
  margin-bottom: 6px;
  font-size: 14px;
  font-weight: 500;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 10px;
  margin-bottom: 20px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 14px;
}

.contact-form button {
  padding: 12px 20px;
  font-size: 14px;
  border: none;
  background: #111;
  color: white;
  border-radius: 4px;
  cursor: pointer;
  transition: 0.3s;
}

.contact-form button:hover {
  background: #444;
}

.about-main {
  max-width: 900px;
  margin: 0 auto;
  padding: 120px 20px 60px; /* deja espacio debajo del header fijo */
  display: flex;
  flex-direction: column;
  gap: 60px;
  font-family:
    -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial,
    sans-serif;
}

.about-intro h1 {
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 20px;
}

.about-intro p {
  font-size: 18px;
  line-height: 1.6;
  color: #333;
}

.about-details h2 {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 15px;
}

.about-details ul {
  list-style: none;
  padding-left: 0;
}

.about-details li {
  font-size: 16px;
  line-height: 1.5;
  margin-bottom: 10px;
  position: relative;
  padding-left: 18px;
}

.about-details li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: #111;
  font-weight: bold;
}

.about-photo {
  display: flex;
  justify-content: center;
}

.about-photo img {
  width: 250px;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

/* Oculta el hamburger en desktop */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 24px;
  height: 18px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.menu-toggle span {
  display: block;
  height: 2px;
  background: #111;
  border-radius: 1px;
}

/* Mobile */
@media (max-width: 600px) {
  .header nav {
    position: absolute;
    top: 70px; /* debajo del header */
    right: 0;
    background: white;
    flex-direction: column;
    width: 200px;
    padding: 20px;
    gap: 20px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    transform: translateX(100%);
    transition: transform 0.3s ease;
  }

  .header nav.open {
    transform: translateX(0);
  }

  .menu-toggle {
    display: flex;
  }
}

/* Ocultar el rol en celular */
@media (max-width: 600px) {
  .logo .role {
    display: none;
  }
}

.hero-container {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-areas: "a a b";
  width: 100%;
  margin: 30px 0px 8px 0px;
  justify-content: center;
  align-items: center;
  gap: 8px;
}

.project-hero {
  grid-area: b;
  padding: 0 50px 0 10px;
  width: 100%;
}

.project-hero h1 {
  font-size: 2.5rem;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.project-hero h2 {
  font-size: 1.5rem;
  font-weight: 200;
  font-style: italic;
  color: #aaaaaa;
}

.project-hero p {
  white-space: pre-line;
  font-size: 1rem;
  font-weight: 400;
  margin-top: 20px;
  line-height: 1.6;
}

@media (max-width: 1000px) {
  .project-hero p {
    font-size: 0.7rem;
    margin-top: 10px;
  }
  .project-hero h1 {
    font-size: 1.5rem;
  }

  .project-hero h2 {
    font-size: 1rem;
  }
}

/* Hero feature */

.project-feature {
  grid-area: a;
  padding-left: 30px;
  padding-right: 10px;
  width: 100%;
}

.project-feature img,
.project-feature video {
  height: auto;
  display: block;
  border-radius: 5px;
  width: 100%;
}

@media (max-width: 1000px) {
  .hero-container {
    grid-template-columns: 1fr 1fr;
    grid-template-areas: "a b";
  }
  .project-feature {
    padding-right: 0;
  }
}

@media (max-width: 600px) {
  .hero-container {
    grid-template-columns: 100vw;
    grid-template-areas:
      "b"
      "a";
  }
  .project-hero {
    grid-area: b;
    padding: 0 30px 0 30px;
  }
  .project-feature {
    padding-left: 30px;
    padding-right: 30px;
  }
}

/* Masonry */
.project-gallery {
  column-count: 3;
  column-gap: 8px;
  padding: 0 30px 30px 30px;
}

.project-gallery .item {
  break-inside: avoid;
  margin-bottom: 8px;
  overflow: hidden;
  border-radius: 5px;
  opacity: 0;
  transform: translateY(20px) scale(0.98);
  transition:
    opacity 0.5s ease,
    transform 0.5s ease;
}

.project-gallery .item.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.project-gallery img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 5px;
}

/* Responsive */
@media (max-width: 1000px) {
  .project-gallery {
    column-count: 2;
  }
}

@media (max-width: 600px) {
  .project-gallery {
    column-count: 1;
  }
  .project-hero h1 {
    font-size: 34px;
  }
}

/* =========================================
   FOOTER Y PÁGINAS LEGALES
   ========================================= */

/* Estilos del Footer */
.site-footer {
  background-color: #f8f9fa; /* Color de fondo gris muy claro */
  color: #333333;
  padding: 30px 20px;
  text-align: center;
  font-family:
    system-ui,
    -apple-system,
    sans-serif;
  border-top: 1px solid #eaeaea;
  margin-top: 60px; /* Separación del contenido principal */
}

.site-footer p {
  margin: 0 0 15px 0;
  font-size: 14px;
  color: #666;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  justify-content: center;
  gap: 25px;
}

.footer-links a {
  color: #333;
  text-decoration: none;
  font-size: 14px;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: #0066cc; /* Color azul al pasar el ratón */
  text-decoration: underline;
}

/* Estilos para las páginas legales (Impressum / Datenschutz) */
.legal-page {
  max-width: 800px;
  margin: 40px auto;
  padding: 0 20px;
  font-family:
    system-ui,
    -apple-system,
    sans-serif;
  line-height: 1.6;
  color: #333;
}

.legal-page h1 {
  font-size: 2rem;
  border-bottom: 2px solid #eaeaea;
  padding-bottom: 10px;
  margin-bottom: 25px;
}

.legal-page h2 {
  font-size: 1.5rem;
  margin-top: 35px;
  margin-bottom: 15px;
}

.legal-page p {
  margin-bottom: 15px;
}

.legal-page .back-link {
  display: inline-block;
  margin-bottom: 30px;
  color: #0066cc;
  text-decoration: none;
  font-weight: bold;
}

.legal-page .back-link:hover {
  text-decoration: underline;
}
