/* Reset y configuración base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  font-family: "Arial", sans-serif;
  line-height: 1.6;
  color: #333;
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  -ms-overflow-style: none;
  scrollbar-width: none;
}

* {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

*::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}

/* Responsive images base rule */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Variables CSS */
:root {
  --white: #ffffff;
}

/* ==================== COVER PAGE ==================== */
.cover-page {
  height: 100vh;
  overflow: hidden;
}

.cover-container {
  position: relative;
  width: 100%;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cover-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url("../img/ui/maestroclave.jpg") center center/cover no-repeat;
  transform: scaleX(-1);
}

.background-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.3);
}

.cover-content {
  position: relative;
  z-index: 10;
  width: 100%;
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: var(--white);
  padding: 2rem;
}

.cover-header {
  align-self: flex-start;
  margin-top: 5rem;
  margin-left: 2rem;
}

.brand-logo {
  max-width: 250px;
  max-height: 100px;
  height: auto;
  opacity: 0;
  animation: fadeInUp 1.5s ease 0.5s forwards;
}

.enter-section {
  align-self: flex-end;
  margin-top: 5rem;
  opacity: 0;
  animation: fadeInUp 1.5s ease 1.5s forwards;
}

.enter-button {
  display: inline-block;
  text-decoration: none;
  color: var(--white);
  padding: 1rem 2rem;
  border: 2px solid rgba(255, 255, 255, 0.6);
  border-radius: 40px;
  backdrop-filter: blur(10px);
  background: rgba(255, 255, 255, 0.1);
  transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
  position: relative;
  overflow: hidden;
}

.enter-button:hover {
  background: #ffffff;
  border-color: #ffffff;
  color: #000000;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}

.enter-text {
  font-family: "Arial", sans-serif;
  font-size: 0.9rem;
  font-weight: bold;
  letter-spacing: 0.2em;
  position: relative;
  z-index: 2;
}

.button-line {
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 1px;
  background: var(--white);
  transform: translateX(-50%);
  transition: width 0.3s ease;
}

.enter-button:hover .button-line {
  width: 0;
}

.enter-button:hover .enter-text {
  color: #000000;
}

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

/* ==================== RESPONSIVE COVER PAGE ==================== */
@media (max-width: 768px) {
  html,
  body {
    min-height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
  }

  .cover-page,
  .home-page,
  .project-page,
  .estudio-page,
  .contacto-page {
    width: 100% !important;
    max-width: 100vw;
    min-height: 100dvh;
    overflow-x: hidden !important;
    overflow-y: auto !important;
  }

  .cover-page {
    height: auto;
  }

  .cover-container,
  .cover-content {
    height: auto;
    min-height: 100dvh;
  }

  .cover-content {
    padding: 1.5rem;
  }

  .cover-header {
    margin-top: 2rem;
    margin-left: 0;
    align-self: center;
    text-align: center;
  }

  .brand-logo {
    max-width: 200px;
    max-height: 80px;
  }

  .enter-section {
    align-self: center;
    margin-top: 2rem;
    text-align: center;
  }

  .enter-button {
    padding: 0.8rem 1.5rem;
  }

  .enter-text {
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  .cover-content {
    padding: 1rem;
  }

  .cover-header {
    margin-top: 1.5rem;
  }

  .brand-logo {
    max-width: 180px;
    max-height: 70px;
  }

  .enter-button {
    padding: 0.7rem 1.2rem;
  }
}

/* ==================== HOME PAGE ==================== */
.home-page {
  font-family: "Arial", sans-serif;
  background: #e5e4e4;
  min-height: 100vh;
  position: relative;
}

.home-logo {
  position: absolute;
  top: 2rem;
  left: 2rem;
  z-index: 1000;
}

.home-brand-logo {
  max-width: 150px;
  max-height: 60px;
  height: auto;
}

.home-nav {
  position: absolute;
  top: 2rem;
  right: 2rem;
  z-index: 1000;
  display: flex;
  gap: 2rem;
}

.horizontal-line {
  position: absolute;
  top: 33vh;
  left: 2rem;
  right: 2rem;
  height: 1px;
  background: #333;
  z-index: 1001;
}

.projects-label {
  position: absolute;
  top: calc(33vh + 4rem);
  left: 2rem;
  z-index: 1000;
}

.project-title-meta {
  display: block;
  margin-top: 0.35rem;
  font-family: "Arial", sans-serif;
  font-size: 0.78rem;
  font-weight: 400;
  letter-spacing: 0.01em;
  color: #5a5a5a;
}

.projects-text {
  color: #333;
  text-decoration: none;
  font-family: "Arial", sans-serif;
  font-weight: bold;
  font-size: 0.9rem;
  letter-spacing: -0.02em;
  cursor: pointer;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.projects-text:hover {
  color: #111;
  opacity: 0.85;
}

.scroll-arrow {
  position: fixed;
  bottom: 2rem;
  left: 2rem;
  z-index: 1000;
  width: 2rem;
  height: 2rem;
  color: #333;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s ease, color 0.3s ease;
  pointer-events: none;
}

.scroll-arrow.visible {
  opacity: 1;
  pointer-events: auto;
}

.scroll-arrow:hover {
  color: #000;
  transform: translateY(3px);
}

.scroll-arrow svg {
  width: 100%;
  height: 100%;
}

.home-page .project-header-bar {
  position: absolute;
}

.projects-layout {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  gap: 1rem;
  margin-top: calc(33vh + 4rem);
  padding: 0 2rem 4rem;
}

.projects-sidebar {
  grid-column: 1;
  position: sticky;
  top: calc(33vh + 4rem);
  height: fit-content;
}

.years-column {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.projects-content {
  grid-column: 2 / 5;
  width: 100%;
}

.year-link {
  color: #333;
  text-decoration: none;
  font-family: "Arial", sans-serif;
  font-weight: normal;
  font-size: 0.9rem;
  letter-spacing: -0.02em;
  transition: color 0.3s ease;
}

.projects-link {
  font-weight: bold;
  display: block;
  margin-bottom: 1rem;
}

.year-link:hover {
  color: #666;
}

.year-link.active {
  color: #333;
  font-weight: bold;
}

.nav-link {
  color: #333;
  text-decoration: none;
  font-family: "Arial", sans-serif;
  font-weight: normal;
  font-size: 0.9rem;
  letter-spacing: -0.02em;
  transition: color 0.3s ease;
}

.nav-link:hover {
  color: #666;
}

/* ==================== RESPONSIVE HOME PAGE NAVIGATION ==================== */
@media (max-width: 768px) {
  .home-logo {
    top: 1.5rem;
    left: 1.5rem;
  }

  .home-brand-logo {
    max-width: 120px;
    max-height: 50px;
  }

  .home-nav {
    top: 1.5rem;
    right: 1.5rem;
    gap: 1.5rem;
  }

  .nav-link {
    font-size: 0.8rem;
  }

  .horizontal-line {
    left: 1.5rem;
    right: 1.5rem;
  }

  .projects-label {
    left: 1.5rem;
  }
}

@media (max-width: 480px) {
  .home-logo {
    top: 1rem;
    left: 1rem;
  }

  .home-brand-logo {
    max-width: 100px;
    max-height: 40px;
  }

  .home-nav {
    top: 1rem;
    right: 1rem;
    gap: 1rem;
  }

  .nav-link {
    font-size: 0.75rem;
  }

  .horizontal-line {
    left: 1rem;
    right: 1rem;
  }

  .projects-label {
    left: 1rem;
  }

  .projects-text {
    font-size: 0.8rem;
  }

  .project-title-meta {
    font-size: 0.7rem;
  }
}

.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  width: 100%;
}

.gallery-item {
  aspect-ratio: 1080/1350;
  overflow: hidden;
  position: relative;
  opacity: 1;
  transform: translateY(0) scale(1);
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.gallery-item.filter-exit {
  opacity: 0;
  transform: translateY(8px) scale(0.98);
}

.gallery-item.filter-enter {
  opacity: 0;
  transform: translateY(8px) scale(0.98);
}

.gallery-item.is-hidden {
  display: none;
}

.project-link {
  display: block;
  width: 100%;
  height: 100%;
  text-decoration: none;
  cursor: pointer;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

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

.project-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.82);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  padding: 1rem;
}

.gallery-item:hover .project-overlay {
  opacity: 1;
}

@media (max-width: 1024px) {
  .projects-sidebar {
    flex-basis: 160px;
  }

  .gallery {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Tablet responsive styles */
@media (max-width: 1024px) and (min-width: 769px) {
  .home-logo {
    top: 1.8rem;
    left: 1.8rem;
  }

  .home-brand-logo {
    max-width: 130px;
    max-height: 55px;
  }

  .home-nav {
    top: 1.8rem;
    right: 1.8rem;
    gap: 1.8rem;
  }

  .nav-link {
    font-size: 0.85rem;
  }

  .horizontal-line {
    left: 1.8rem;
    right: 1.8rem;
  }

  .projects-label {
    left: 1.8rem;
  }

  /* Estudio page tablet */
  .estudio-page .home-logo {
    top: 1.8rem;
    left: 1.8rem;
  }

  .estudio-page .home-nav {
    top: 1.8rem;
    right: 1.8rem;
  }

  .estudio-layout {
    left: 1.8rem;
    right: 1.8rem;
  }

  /* Contacto page tablet */
  .contacto-page .home-logo {
    top: 1.8rem;
    left: 1.8rem;
  }

  .contacto-page .home-nav {
    top: 1.8rem;
    right: 1.8rem;
  }

  .contacto-layout {
    left: 1.8rem;
    right: 1.8rem;
  }

  /* Project page tablet */
  .project-page .home-logo {
    top: 1.8rem;
    left: 1.8rem;
  }

  .project-page .home-nav {
    top: 1.8rem;
    right: 1.8rem;
  }

  .project-header-inner {
    padding: 1.8rem;
  }

  .project-header-inner::after {
    left: 1.8rem;
    right: 1.8rem;
  }

  .project-page .projects-label {
    left: 1.8rem;
  }

  .project-content-track {
    left: 1.8rem;
    right: 1.8rem;
  }
}

@media (max-width: 768px) {
  .projects-layout {
    display: block;
    margin-top: calc(33vh + 3.5rem);
    padding: 0 1rem 3rem;
  }

  .projects-sidebar {
    position: static;
    margin-top: 0;
    margin-bottom: 1rem;
  }

  .projects-content {
    margin-left: 0;
  }

  .years-column {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.6rem 1rem;
  }

  .gallery {
    grid-template-columns: 1fr;
    gap: 0.8rem;
    max-width: 100%;
    margin-left: 0;
  }

  .gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    max-width: 100%;
  }
}

.project-info {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2rem;
  text-align: center;
}

.project-name {
  color: #111;
  font-family: "Arial", sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: -0.02em;
}

.project-meta {
  display: flex;
  align-items: baseline;
  gap: 0.3rem;
}

.project-location {
  color: #555;
  font-family: "Arial", sans-serif;
  font-weight: 400;
  font-size: 0.75rem;
  letter-spacing: -0.02em;
  text-transform: uppercase;
}

.project-year {
  color: #555;
  font-family: "Arial", sans-serif;
  font-weight: 400;
  font-size: 0.75rem;
  letter-spacing: -0.02em;
  text-transform: uppercase;
}

/* ==================== PROJECT PAGES ==================== */
.project-page {
  background: #e5e4e4;
  min-height: 100vh;
  padding: 0;
  margin: 0;
  overflow-x: auto;
  overflow-y: hidden;
  width: 300vw;
}

.project-page::after {
  content: "";
  position: fixed;
  top: 33vh;
  right: 0;
  width: 2rem;
  bottom: 0;
  background: #e5e4e4;
  pointer-events: none;
  z-index: 1500;
}

.project-page::before {
  content: "";
  position: fixed;
  top: 33vh;
  left: 0;
  width: 2rem;
  bottom: 0;
  background: #e5e4e4;
  pointer-events: none;
  z-index: 1500;
}

.project-header-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 33vh;
  background: #e5e4e4;
  z-index: 2000;
}

.project-header-inner {
  position: relative;
  height: 100%;
  padding: 2rem 2rem 1.5rem;
}

.project-header-inner::after {
  content: "";
  position: absolute;
  left: 2rem;
  right: 2rem;
  bottom: 0;
  height: 1px;
  background: #3d3d3d;
}

.project-page .home-logo {
  position: static;
  z-index: auto;
}

.project-page .home-nav {
  position: absolute;
  top: 2rem;
  right: 2rem;
  z-index: auto;
}

.project-page .horizontal-line {
  display: none;
}

.project-page .projects-label {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.project-page .projects-text {
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.project-page .project-title-meta {
  margin-top: 0;
  font-size: 0.9rem;
  letter-spacing: 0.01em;
}

.project-description {
  position: absolute;
  top: calc(33vh + 8.25rem);
  bottom: 4rem;
  left: 2rem;
  width: calc(25vw - 2rem);
  overflow-y: auto;
  padding-right: 0.35rem;
  -webkit-overflow-scrolling: touch;
  z-index: 10;
}

.project-text {
  font-family: "Arial", sans-serif;
  font-size: 0.9rem;
  font-weight: 300;
  line-height: 1.4;
  color: #333;
  margin: 0;
  text-align: justify;
}

.project-gallery {
  position: absolute;
  top: calc(33vh + 4rem);
  left: calc(25vw + 2rem);
  right: 2rem;
  bottom: 4rem;
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 1rem;
}

.project-image-large,
.project-image-small {
  overflow: hidden;
  position: relative;
  background: #f5f5f5;
}

.project-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.project-gallery .project-image {
  transition: transform 0.22s ease, filter 0.22s ease;
}

.project-gallery .project-image:hover {
  transform: scale(1.015);
  filter: brightness(1.04);
}

.project-gallery-sequence {
  display: flex;
  align-items: stretch;
  gap: 1rem;
  --gallery-gap: 1rem;
  --gallery-visible-width: calc(75vw - 4rem);
  --gallery-unit: calc((var(--gallery-visible-width) - (var(--gallery-gap) * 3)) / 4);
}

.project-gallery-sequence .project-image-panel {
  flex: 0 0 calc(37.5vw - 2.5rem);
  min-width: 300px;
  height: 70vh;
  overflow: hidden;
  position: relative;
}

.project-gallery-sequence .project-image-panel.is-vertical,
.project-gallery-sequence .project-image-panel.is-square {
  flex-basis: max(var(--gallery-unit), 180px);
  min-width: 0;
}

.project-gallery-sequence .project-image-panel.is-horizontal {
  flex-basis: max(calc((var(--gallery-unit) * 3) + (var(--gallery-gap) * 2)), 420px);
  min-width: 0;
}

.project-gallery-sequence .project-gallery-note {
  flex: 0 0 30vw;
  min-width: 300px;
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid rgba(0, 0, 0, 0.08);
  padding: 1rem;
  overflow-y: auto;
}

.project-content-track {
  position: absolute;
  top: calc(33vh + 4rem);
  left: 2rem;
  right: 2rem;
  bottom: 4rem;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  --project-slot-gap: 1rem;
  --project-slot-width: calc((100% - (var(--project-slot-gap) * 3)) / 4);
  --project-slot-height: calc(100vh - 33vh - 8rem);
  min-height: var(--project-slot-height);
}

.project-content-track .project-description,
.project-content-track .project-gallery-note,
.project-content-track .project-image-panel {
  flex: 0 0 var(--project-slot-width);
  min-width: 0;
  height: var(--project-slot-height);
  overflow: hidden;
  background: #f5f5f5;
}

.project-content-track .project-description {
  position: relative;
  top: auto;
  left: auto;
  right: auto;
  bottom: auto;
  width: var(--project-slot-width);
  overflow-y: auto;
  background: transparent;
  padding-right: 0;
  margin-top: 4.25rem;
  height: calc(var(--project-slot-height) - 4.25rem);
}

.project-content-track .project-gallery-note {
  background: transparent;
  border: 0;
  padding: 0;
  overflow-y: auto;
  margin-right: 4rem;
}

.project-content-track .project-image-panel.is-horizontal {
  flex-basis: calc((var(--project-slot-width) * 2) + var(--project-slot-gap));
}

.project-content-track .project-image-panel.is-vertical,
.project-content-track .project-image-panel.is-square {
  flex-basis: var(--project-slot-width);
}

.project-lightbox {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background: rgba(0, 0, 0, 0.78);
  z-index: 5000;
}

.project-lightbox.is-open {
  display: flex;
}

.project-lightbox-image {
  max-width: min(92vw, 1700px);
  max-height: 90vh;
  object-fit: contain;
  box-shadow: 0 12px 38px rgba(0, 0, 0, 0.45);
}

.project-lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  border: 0;
  background: transparent;
  color: #fff;
  width: auto;
  height: auto;
  padding: 0;
  border-radius: 0;
  font-size: 2rem;
  font-weight: 300;
  line-height: 1;
  cursor: pointer;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.45);
}

@media (max-width: 768px) {
  .project-page {
    width: 100% !important;
    overflow-x: hidden;
    overflow-y: auto;
  }

  .project-page::after,
  .project-page::before {
    display: none;
  }

  .project-header-bar {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 33vh;
    background: #e5e4e4;
    z-index: 2000;
  }

  .project-page .home-logo {
    position: absolute;
    top: 1.5rem;
    left: 1.5rem;
  }

  .project-page .home-brand-logo {
    max-width: 120px;
    max-height: 50px;
  }

  .project-page .home-nav {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    gap: 1.5rem;
  }

  .project-page .nav-link {
    font-size: 0.8rem;
  }

  .project-header-inner {
    padding: 1.5rem;
  }

  .project-header-inner::after {
    left: 1.5rem;
    right: 1.5rem;
  }

  .projects-label {
    position: absolute;
    top: calc(33vh + 1.5rem);
    left: 1.5rem;
    z-index: 100;
  }

  .project-content-track {
    position: static;
    display: block;
    margin-top: calc(33vh + 6rem);
    padding: 0 1.5rem 2rem;
    left: auto;
    right: auto;
    top: auto;
    bottom: auto;
    min-height: 0;
  }

  .project-content-track .project-description,
  .project-content-track .project-gallery-note,
  .project-content-track .project-image-panel {
    position: static;
    width: 100%;
    height: auto;
    min-height: 0;
    flex-basis: auto;
    margin-bottom: 1.5rem;
  }

  .project-content-track .project-image-panel {
    height: auto;
    aspect-ratio: 4 / 5;
    max-height: none;
  }

  .project-content-track .project-image-panel.is-horizontal {
    aspect-ratio: 16 / 10;
  }

  .project-content-track .project-image-panel.is-vertical {
    aspect-ratio: 4 / 5;
  }

  .project-content-track .project-image-panel.is-square {
    aspect-ratio: 1 / 1;
  }

  .project-content-track .project-description {
    margin-bottom: 2rem;
    height: auto;
    overflow: visible;
    background: transparent;
    padding: 0;
    max-height: none;
  }

  .project-content-track .project-gallery-note {
    background: transparent;
    border: 0;
    padding: 0;
    overflow: visible;
    max-height: none;
  }

  .project-gallery {
    position: static;
    display: block;
    margin-top: calc(33vh + 6rem);
    padding: 0 1.5rem 2rem;
    left: auto;
    right: auto;
    top: auto;
    bottom: auto;
  }

  .project-gallery-sequence {
    position: static;
    display: block;
    margin-top: calc(33vh + 6rem);
    padding: 0 1.5rem 2rem;
    left: auto;
    right: auto;
    top: auto;
    bottom: auto;
  }

  .project-gallery-sequence .project-image-panel,
  .project-gallery-sequence .project-gallery-note {
    width: 100%;
    min-width: 0;
    flex: none;
    margin-bottom: 1.5rem;
    height: auto;
  }

  .project-gallery-sequence .project-image-panel {
    height: auto;
    aspect-ratio: 4 / 5;
    max-height: none;
  }

  .project-gallery-sequence .project-image-panel.is-horizontal {
    aspect-ratio: 16 / 10;
  }

  .project-gallery-sequence .project-image-panel.is-vertical {
    aspect-ratio: 4 / 5;
  }

  .project-gallery-sequence .project-image-panel.is-square {
    aspect-ratio: 1 / 1;
  }

  .project-gallery-sequence .project-image,
  .project-content-track .project-image,
  .project-gallery .project-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
  }

  .project-gallery-sequence .project-gallery-note {
    background: transparent;
    border: 0;
    padding: 0;
  }

  .project-description {
    position: static;
    width: auto;
    margin-top: calc(33vh + 6rem);
    padding: 0 1.5rem 2rem;
    max-height: none;
    overflow: visible;
  }
}

@media (max-width: 480px) {
  .project-page .home-logo {
    top: 1rem;
    left: 1rem;
  }

  .project-page .home-brand-logo {
    max-width: 100px;
    max-height: 40px;
  }

  .project-page .home-nav {
    top: 1rem;
    right: 1rem;
    gap: 1rem;
  }

  .project-page .nav-link {
    font-size: 0.75rem;
  }

  .project-header-inner {
    padding: 1rem;
  }

  .project-header-inner::after {
    left: 1rem;
    right: 1rem;
  }

  .projects-label {
    top: calc(33vh + 1rem);
    left: 1rem;
  }

  .project-page .projects-text {
    font-size: 0.8rem;
  }

  .project-page .project-title-meta {
    font-size: 0.7rem;
  }

  .project-text {
    font-size: 0.8rem;
    line-height: 1.5;
  }

  .project-content-track,
  .project-gallery,
  .project-gallery-sequence,
  .project-description {
    margin-top: calc(33vh + 5rem);
    padding: 0 1rem 1.5rem;
  }

  .project-content-track .project-gallery-note,
  .project-gallery-sequence .project-gallery-note {
    padding: 0;
  }

  .project-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
  }

  .project-image-panel {
    overflow: hidden;
    background: #f5f5f5;
  }

  .project-lightbox {
    padding: 1rem;
  }

  .project-lightbox-image {
    max-width: 95vw;
    max-height: 85vh;
  }

  .project-lightbox-close {
    top: 0.5rem;
    right: 0.5rem;
    width: auto;
    height: auto;
    font-size: 1.7rem;
  }
}

/* ==================== ESTUDIO PAGE ==================== */
.estudio-page {
  background: #e5e4e4;
  height: 100vh;
  overflow: hidden;
}

.estudio-page .home-logo {
  position: static;
  z-index: auto;
}

.estudio-page .home-nav {
  position: absolute;
  top: 2rem;
  right: 2rem;
  z-index: auto;
}

.estudio-page .horizontal-line {
  display: none;
}

.estudio-layout {
  position: absolute;
  top: calc(33vh + 4rem);
  left: 2rem;
  right: 2rem;
  bottom: 4rem;
  display: flex;
  gap: 1rem;
}

.estudio-text {
  flex: 0 0 calc(50% - 0.5rem);
  padding: 0 0.25rem 0 0;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  overflow-x: hidden;
  overflow-y: auto;
}

.estudio-bios {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.estudio-intro {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.estudio-section-title {
  font-family: "Arial", sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #333;
}

.estudio-section-sub {
  font-family: "Arial", sans-serif;
  font-size: 0.78rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: #5a5a5a;
  text-transform: uppercase;
  display: none;
}

.estudio-bio {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0.55rem 0.65rem 0.6rem 0;
  background: transparent;
  border: none;
}

.estudio-bio-name {
  font-family: "Arial", sans-serif;
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.03em;
  color: #555;
  margin: 0;
  text-transform: uppercase;
}

.estudio-bio-text {
  font-family: "Arial", sans-serif;
  font-size: 0.9rem;
  font-weight: 300;
  line-height: 1.5;
  color: #333;
  margin: 0;
  text-align: justify;
  overflow: visible;
  padding-right: 0;
}

.estudio-text::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}

.estudio-text {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.estudio-photo {
  flex: 0 0 calc(50% - 0.5rem);
  margin: 0;
  overflow: hidden;
}

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

@media (max-width: 768px) {
  .estudio-page {
    height: auto;
    min-height: 100dvh;
    overflow-x: hidden;
    overflow-y: auto;
  }

  .estudio-page .home-logo {
    top: 1.5rem;
    left: 1.5rem;
  }

  .estudio-page .home-brand-logo {
    max-width: 120px;
    max-height: 50px;
  }

  .estudio-page .home-nav {
    top: 1.5rem;
    right: 1.5rem;
    gap: 1.5rem;
  }

  .estudio-layout {
    position: static;
    flex-direction: column;
    padding-top: calc(33vh + 2rem);
    padding-bottom: 3rem;
    left: auto;
    right: auto;
    bottom: auto;
    gap: 0;
  }

  .estudio-text {
    flex: none;
    padding: 1.5rem 1rem;
    gap: 1.5rem;
    overflow: visible;
  }

  .estudio-bios {
    gap: 1rem;
  }

  .estudio-bio {
    display: flex;
  }

  .estudio-bio-text {
    overflow: visible;
    padding-right: 0;
  }

  .estudio-photo {
    margin: 0 1rem 2rem;
    height: 70vw;
  }
}

@media (max-width: 480px) {
  .estudio-page .home-logo {
    top: 1rem;
    left: 1rem;
  }

  .estudio-page .home-brand-logo {
    max-width: 100px;
    max-height: 40px;
  }

  .estudio-page .home-nav {
    top: 1rem;
    right: 1rem;
    gap: 1rem;
  }

  .estudio-layout {
    padding-top: calc(33vh + 1.5rem);
    padding-bottom: 2rem;
  }

  .estudio-text {
    padding: 1rem 0.8rem;
    gap: 1rem;
  }

  .estudio-section-title {
    font-size: 0.8rem;
  }

  .estudio-bio-name {
    font-size: 0.7rem;
  }

  .estudio-bio-text {
    font-size: 0.8rem;
  }

  .estudio-photo {
    margin: 0 0.8rem 1.5rem;
    height: 75vw;
  }
}

/* ==================== CONTACTO PAGE ==================== */
.contacto-page {
  background: #e5e4e4;
  height: 100vh;
  overflow: hidden;
}

.contacto-page .home-logo {
  position: static;
  z-index: auto;
}

.contacto-page .home-nav {
  position: absolute;
  top: 2rem;
  right: 2rem;
  z-index: auto;
}

.contacto-page .horizontal-line {
  display: none;
}

.contacto-layout {
  position: absolute;
  top: calc(33vh + 4rem);
  left: 2rem;
  right: 2rem;
  bottom: 4rem;
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  min-height: 0;
}

.contacto-info {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  flex: 0 0 calc(50% - 0.5rem);
  min-height: 0;
  overflow-y: auto;
  padding-right: 0.2rem;
}

.contacto-title {
  font-family: "Arial", sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #333;
}

.contacto-text {
  font-family: "Arial", sans-serif;
  font-size: 0.9rem;
  font-weight: 300;
  line-height: 1.55;
  color: #333;
  margin: 0;
}

.contacto-link {
  color: #333;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.contacto-form-wrapper {
  background: transparent;
  border: none;
  padding: 0;
  flex: 0 0 calc(50% - 0.5rem);
  min-height: 0;
  overflow: hidden;
}

.contacto-form {
  display: grid;
  grid-template-rows: repeat(6, auto) minmax(0, 1fr) auto;
  gap: 0;
  height: 100%;
  min-height: 0;
}

.contacto-label {
  font-family: "Arial", sans-serif;
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #555;
  margin-top: 0.5rem;
}

.contacto-input,
.contacto-textarea {
  width: 100%;
  border: none;
  border-bottom: 1px solid rgba(0, 0, 0, 0.2);
  background: transparent;
  color: #333;
  font-family: "Arial", sans-serif;
  font-size: 0.85rem;
  padding: 0.6rem 0;
  outline: none;
  transition: border-color 0.3s ease;
}

.contacto-textarea {
  resize: none;
  min-height: 0;
  height: 100%;
  overflow-y: auto;
}

.contacto-input:focus,
.contacto-textarea:focus {
  border-bottom-color: #333;
}

.contacto-button {
  justify-self: start;
  border: 1px solid #333;
  background: transparent;
  color: #333;
  font-family: "Arial", sans-serif;
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 0.6rem 1.2rem;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 0.8rem;
}

.contacto-button:hover {
  background: #333;
  color: #e5e4e4;
  transform: translateY(-2px);
}

.contacto-info::-webkit-scrollbar,
.contacto-textarea::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}

.contacto-info,
.contacto-textarea {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

@media (max-width: 900px) {
  .contacto-page {
    height: auto;
    min-height: 100dvh;
    overflow-x: hidden;
    overflow-y: auto;
  }

  .contacto-page .home-logo {
    top: 1.5rem;
    left: 1.5rem;
  }

  .contacto-page .home-brand-logo {
    max-width: 120px;
    max-height: 50px;
  }

  .contacto-page .home-nav {
    top: 1.5rem;
    right: 1.5rem;
    gap: 1.5rem;
  }

  .contacto-layout {
    position: static;
    flex-direction: column;
    padding: calc(33vh + 2rem) 1.5rem 2rem;
    gap: 1.25rem;
  }

  .contacto-info {
    max-width: none;
    overflow: visible;
    flex: none;
  }

  .contacto-form-wrapper {
    flex: none;
    width: calc(100% + 1.5rem);
    margin-right: -1.5rem;
    padding-right: 1.5rem;
  }

  .contacto-form {
    grid-template-rows: none;
    height: auto;
  }

  .contacto-textarea {
    min-height: 7rem;
    height: auto;
  }

  /* Responsive images for tablet */
  .project-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
  }

  .project-image-panel {
    overflow: hidden;
    background: #f5f5f5;
  }

  .gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
}

@media (max-width: 768px) {
  .contacto-page .nav-link {
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  .contacto-page .home-logo {
    top: 1rem;
    left: 1rem;
  }

  .contacto-page .home-brand-logo {
    max-width: 100px;
    max-height: 40px;
  }

  .contacto-page .home-nav {
    top: 1rem;
    right: 1rem;
    gap: 1rem;
  }

  .contacto-page .nav-link {
    font-size: 0.75rem;
  }

  .contacto-layout {
    padding: calc(33vh + 1.5rem) 1rem 1.5rem;
    gap: 1rem;
  }

  .contacto-form-wrapper {
    width: calc(100% + 1rem);
    margin-right: -1rem;
    padding-right: 1rem;
  }

  .contacto-title {
    font-size: 0.8rem;
  }

  .contacto-text {
    font-size: 0.8rem;
  }

  .contacto-label {
    font-size: 0.7rem;
  }

  .contacto-input,
  .contacto-textarea {
    font-size: 0.8rem;
  }

  .contacto-button {
    font-size: 0.7rem;
    padding: 0.5rem 1rem;
  }
}

/* ==================== FOOTER ==================== */
.site-footer {
  position: relative;
  width: 100%;
  padding: 2rem;
  background: transparent;
}

.footer-line {
  position: relative;
  left: 0;
  right: 0;
  height: 1px;
  background: #333;
  margin-bottom: 1.5rem;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: "Arial", sans-serif;
  font-size: 0.9rem;
  color: #666;
}

.footer-left,
.footer-center,
.footer-right {
  font-weight: 300;
  flex: 1;
}

.footer-left {
  text-align: left;
}

.footer-center {
  text-align: center;
}

.footer-right {
  text-align: right;
}

/* Responsive footer */
@media (max-width: 768px) {
  .site-footer {
    padding: 1.5rem;
  }

  .footer-content {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
  
  .footer-left,
  .footer-center,
  .footer-right {
    text-align: center;
  }

  .footer-content {
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  .site-footer {
    padding: 1rem;
  }

  .footer-line {
    margin-bottom: 1rem;
  }

  .footer-content {
    gap: 0.8rem;
    font-size: 0.75rem;
  }
}
