:root {
  --bg: #f4f1ec;
  --paper: #ffffff;
  --sand: #ece6dd;
  --ink: #1e1c19;
  --muted: #746f67;
  --line: #d8d1c5;
  --accent: #4a3f31;
  --dark: #1f1a15;
  --font-display: "Playfair Display", Georgia, serif;
  --font-body: "Inter", "Segoe UI", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.78;
  font-size: 1.03rem;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.45s ease, transform 0.45s ease;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: var(--bg);
  opacity: 1;
  pointer-events: none;
  z-index: 9999;
  transition: opacity 0.45s ease;
}

body.is-ready {
  opacity: 1;
  transform: translateY(0);
}

body.is-ready::before {
  opacity: 0;
}

body.is-leaving {
  opacity: 0;
  transform: translateY(12px);
}

body.is-leaving::before {
  opacity: 1;
}

.container {
  width: min(1180px, 92%);
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.95);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(8px);
}

.nav-wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.46rem 0;
}

.brand-block {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
}

.brand-logo {
  width: 148px;
  max-width: 100%;
  height: auto;
  display: block;
}

.brand-sub {
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.03em;
}

.main-nav {
  display: flex;
  gap: 0.95rem;
}

.main-nav a {
  text-decoration: none;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  font-size: 0.68rem;
  font-weight: 600;
  position: relative;
  padding-bottom: 0.2rem;
  transition: color 0.3s ease;
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}

.main-nav a.is-active,
.main-nav a:hover {
  color: var(--accent);
}

.main-nav a.is-active::after,
.main-nav a:hover::after {
  transform: scaleX(1);
}

.hero {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
}

.hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 58%;
  transform: scale(1.04);
  animation: heroZoom 8s ease-out forwards;
}

.hero-filter {
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, rgba(21, 16, 11, 0.58), rgba(21, 16, 11, 0.42));
}

.hero-copy {
  position: relative;
  z-index: 1;
  color: #faf8f5;
  min-height: 100vh;
  max-width: 1000px;
  margin-inline: auto;
  padding: 0 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.hero-kicker {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.13em;
  font-size: 0.78rem;
  opacity: 0.94;
}

.hero h1 {
  margin: 0 0 1rem;
  font-family: "Urbanist", "Inter", Arial, sans-serif;
  font-size: clamp(2.4rem, 6vw, 4.5rem);
  line-height: 1;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 800;
  text-shadow: 0 10px 28px rgba(0, 0, 0, 0.22);
}

.hero p {
  margin: 0 0 1.8rem;
  font-size: 0.98rem;
  max-width: 560px;
  line-height: 1.75;
  text-shadow: 0 6px 22px rgba(0, 0, 0, 0.2);
}

.section {
  padding: 3rem 0;
}

.section-soft {
  background: var(--sand);
}

#filosofia {
  position: relative;
  background-image: url("https://images.unsplash.com/photo-1511818966892-d7d671e672a2?auto=format&fit=crop&w=2200&q=80");
  background-size: cover;
  background-position: center;
  overflow: hidden;
}

#filosofia::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(244, 241, 236, 0.9), rgba(244, 241, 236, 0.82));
}

#filosofia .container {
  position: relative;
  z-index: 1;
}

.section-head {
  max-width: 790px;
  margin-bottom: 1.8rem;
}

.section-head h2,
.page-intro h1 {
  margin: 0;
  text-transform: none;
  letter-spacing: 0.03em;
  font-family: var(--font-display);
  line-height: 1.25;
  font-size: clamp(2rem, 3.2vw, 2.7rem);
}

.section-head p,
.page-intro p {
  margin: 1rem 0 0;
  color: var(--muted);
  max-width: 760px;
  font-size: 1.08rem;
  line-height: 1.9;
}

.page-intro {
  padding-bottom: 1.4rem;
}

.page-intro-projects {
  position: relative;
  background-image: url("./assets/images/proyectos-fondo-mapa.png");
  background-size: cover;
  background-position: center;
  overflow: hidden;
}

.page-intro-projects::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, rgba(25, 22, 18, 0.72), rgba(25, 22, 18, 0.4));
}

.page-intro-projects .container {
  position: relative;
  z-index: 1;
}

.page-intro-projects h1,
.page-intro-projects p {
  color: #f5efe5;
}

.studio-shell,
.philosophy-shell {
  padding-block: 4rem;
}

.section-kicker {
  margin: 0 0 0.55rem;
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
  font-weight: 600;
}

.impact-title {
  margin: 0;
  font-family: "Urbanist", "Inter", Arial, sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: clamp(1.7rem, 3.2vw, 2.6rem);
  font-weight: 800;
  line-height: 1.1;
}

.studio-head {
  margin-bottom: 1.1rem;
}

.studio-grid {
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  grid-template-areas: "text main";
  gap: 2rem 2.4rem;
  align-items: start;
  position: relative;
}

.studio-text-block {
  grid-area: text;
  max-width: 520px;
  margin-top: 0.2rem;
}

.studio-text-block p {
  margin: 0;
  font-size: 1.03rem;
  line-height: 1.9;
  color: #3b352d;
}

.studio-text-block p + p {
  margin-top: 1.2rem;
}

.studio-image-main {
  grid-area: main;
  margin: 0;
  border: 1px solid var(--line);
  aspect-ratio: 5 / 4;
  max-width: 560px;
  overflow: hidden;
  transform: translateY(-78px);
  justify-self: end;
}

.studio-image-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.philosophy-head {
  max-width: 760px;
  margin-bottom: 2.2rem;
}

.philosophy-intro {
  margin: 1rem 0 0;
  font-size: 1.04rem;
  line-height: 1.9;
  color: #4a443b;
}

.philosophy-concepts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.2rem;
}

.concept-card {
  border: 1px solid #cfc5b8;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  padding: 1.25rem 1.1rem 1.35rem;
}

.concept-icon {
  width: 46px;
  height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #bcae9b;
  margin-bottom: 0.85rem;
}

.concept-icon svg {
  width: 22px;
  height: 22px;
  stroke: #4a3f31;
  stroke-width: 1.5;
  fill: none;
  vector-effect: non-scaling-stroke;
}

.concept-card h3 {
  margin: 0;
  font-family: "Urbanist", "Inter", Arial, sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 1rem;
  font-weight: 800;
}

.concept-card p {
  margin: 0.7rem 0 0;
  font-size: 1rem;
  line-height: 1.85;
  color: #484239;
}

.split-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
}

.section-image {
  width: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
  border: 1px solid var(--line);
}

.project-banner {
  margin-top: 1.35rem;
  max-height: 320px;
  object-fit: contain;
  object-position: center;
  background: #e9e2d7;
  padding: 0.35rem;
}

.trust-grid,
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.4rem;
}

.card {
  background: transparent;
  border: 1px solid var(--line);
  padding: 1.25rem 1.25rem 1.6rem;
  transition: border-color 0.3s ease, transform 0.35s ease;
}

.card:hover {
  border-color: #bcae9b;
  transform: translateY(-4px);
}

.philosophy-grid .card img {
  width: 100%;
  height: 185px;
  object-fit: cover;
  margin-bottom: 1.2rem;
}

.project-card {
  background: var(--paper);
  border: 1px solid var(--line);
  transition: transform 0.35s ease, border-color 0.3s ease;
}

.project-card:hover {
  transform: translateY(-6px);
  border-color: #b5a792;
}

.project-grid.is-loaded .project-card {
  opacity: 0;
  transform: translateY(24px);
  animation: catalogIn 0.7s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  animation-delay: var(--delay, 0ms);
}

.project-image-frame {
  aspect-ratio: 1.48 / 1;
  overflow: hidden;
  background: #e9e6df;
}

.project-image-frame img,
.detail-image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.project-content {
  padding: 1.15rem 1.1rem 1.2rem;
}

.project-content h3 {
  margin: 0;
  text-transform: none;
  letter-spacing: 0.02em;
  font-size: 1.55rem;
  font-family: var(--font-display);
}

.project-eyebrow {
  margin: 0 0 0.45rem;
  color: var(--accent);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  line-height: 1.4;
  text-transform: uppercase;
}

.project-meta {
  margin: 0.5rem 0 1rem;
  color: var(--muted);
}

.project-price {
  margin: 0;
  color: var(--accent);
  font-weight: 700;
  font-size: 1.2rem;
}

.project-list {
  margin: 1.25rem 0 1.45rem;
  padding-left: 1rem;
}

.project-list li {
  margin: 0.36rem 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  text-decoration: none;
  border: 1px solid transparent;
  padding: 0.74rem 1.18rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 700;
  transition: all 0.28s ease;
  cursor: pointer;
}

.btn-solid {
  background: var(--dark);
  color: #fff;
  border-color: var(--dark);
}

.btn-solid:hover {
  background: transparent;
  color: var(--dark);
}

.btn-outline {
  color: var(--dark);
  border-color: var(--dark);
}

.btn-outline:hover {
  background: var(--dark);
  color: #fff;
}

.center {
  text-align: center;
  margin-top: 1.9rem;
}

.detail-card {
  background: var(--paper);
  border: 1px solid var(--line);
}

.detail-top {
  padding: 1.5rem 1.5rem 1.3rem;
  border-bottom: 1px solid var(--line);
}

.detail-back-button {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--dark);
  padding: 0.5rem 0.85rem;
  margin-bottom: 0.9rem;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.25s ease, transform 0.25s ease;
}

.detail-back-button:hover {
  border-color: var(--accent);
  transform: translateX(-2px);
}

.detail-top h1 {
  margin: 0;
  text-transform: none;
  letter-spacing: 0.02em;
  font-size: clamp(2rem, 3vw, 2.8rem);
  font-family: var(--font-display);
}

.detail-subtitle {
  margin: 0.45rem 0 0;
  color: var(--muted);
}

.detail-layout {
  display: grid;
  gap: 1.6rem;
  padding: 1.5rem;
}

.detail-image-frame {
  width: 100%;
  aspect-ratio: 1.48 / 1;
  overflow: hidden;
  background: #e9e6df;
  border: 1px solid var(--line);
}

.main-photo { display: block; }

.image-caption {
  margin: 0.55rem 0 0;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.5;
}

.thumb-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 0.55rem;
  margin-top: 0.75rem;
}

.thumb-grid img {
  width: 100%;
  height: 94px;
  object-fit: cover;
  border: 1px solid transparent;
  cursor: pointer;
  transition: border-color 0.24s ease, opacity 0.24s ease;
}

.thumb-grid img:hover {
  opacity: 0.82;
}

.thumb-grid img.active {
  border-color: var(--accent);
}

.project-description {
  margin: 0 0 1.45rem;
  font-size: 1.08rem;
  line-height: 1.95;
}

.detail-block-title {
  margin: 0 0 0.8rem;
  font-family: var(--font-display);
  letter-spacing: 0.03em;
  font-size: 1.45rem;
}

.feature-table {
  width: 100%;
  border-collapse: collapse;
}

.feature-table th,
.feature-table td {
  border-bottom: 1px solid var(--line);
  padding: 0.84rem 0.5rem;
  text-align: left;
}

.feature-table th {
  width: 42%;
  color: var(--muted);
  font-weight: 600;
}

.extras-title {
  margin: 1.7rem 0 0.7rem;
  font-family: var(--font-display);
  font-size: 1.5rem;
}

.extras {
  margin: 0;
  padding-left: 1rem;
}

.contact-showcase {
  position: relative;
  overflow: hidden;
  background-image: url("https://images.unsplash.com/photo-1512918728675-ed5a9ecdebfd?auto=format&fit=crop&w=2200&q=80");
  background-size: cover;
  background-position: center;
  padding: 5.3rem 0;
}

.contact-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(17, 14, 10, 0.74), rgba(17, 14, 10, 0.48));
}

.contact-premium-layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.2rem;
}

.contact-premium-info {
  color: #f8f4ed;
  padding: 1.1rem 0.2rem;
}

.contact-kicker {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.75rem;
  opacity: 0.92;
}

.contact-premium-info h2 {
  margin: 0.8rem 0 0.65rem;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3vw, 2.5rem);
  line-height: 1.25;
}

.contact-premium-info > p {
  margin: 0;
  max-width: 560px;
  font-size: 1.02rem;
  line-height: 1.85;
  color: #ece4d8;
}

.contact-meta {
  list-style: none;
  margin: 2rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.95rem;
}

.contact-meta li {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 0.8rem;
  align-items: start;
}

.contact-icon {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(240, 231, 216, 0.5);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
}

.contact-meta strong {
  display: block;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: #fff8ed;
}

.contact-meta p {
  margin: 0.2rem 0 0;
  color: #ede5d8;
}

.contact-social {
  display: flex;
  gap: 0.55rem;
  margin-top: 1.5rem;
}

.contact-social a {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(240, 231, 216, 0.5);
  color: #f8f1e6;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  transition: background 0.25s ease, color 0.25s ease;
}

.contact-social a:hover {
  background: #f8f1e6;
  color: #2a241d;
}

.contact-form-glass {
  background: rgba(252, 248, 242, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.35);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  padding: 1.5rem 1.4rem 1.6rem;
}

.contact-form-glass h3 {
  margin: 0 0 0.7rem;
  font-family: var(--font-display);
  font-size: 1.8rem;
  color: #fff8ef;
}

.contact-form-glass label {
  display: block;
  margin: 0.88rem 0 0.3rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #f4ebdf;
}

.contact-form-glass input,
.contact-form-glass select,
.contact-form-glass textarea {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: rgba(255, 255, 255, 0.82);
  color: #2b251d;
  font: inherit;
  padding: 0.74rem 0.7rem;
  transition: border-color 0.24s ease, box-shadow 0.24s ease, background 0.24s ease;
}

.contact-form-glass input:focus,
.contact-form-glass select:focus,
.contact-form-glass textarea:focus {
  outline: none;
  border-color: #f9e9d1;
  box-shadow: 0 0 0 2px rgba(252, 241, 225, 0.4);
  background: #fff;
}

.contact-form-glass button {
  margin-top: 1.15rem;
}

.contact-form-glass button[disabled] {
  opacity: 0.82;
  cursor: wait;
}

.form-feedback,
.form-feedback-error {
  margin: 0.85rem 0 0;
  font-size: 0.92rem;
  display: none;
}

.form-feedback {
  color: #def8e8;
}

.form-feedback-error {
  color: #ffe2de;
}

.form-feedback.is-visible,
.form-feedback-error.is-visible {
  display: block;
}

.site-footer {
  background: #1f1a15;
  color: #e8dfd2;
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.35rem 0;
}

.footer-brand {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 700;
}

.footer-grid p {
  margin: 0.2rem 0;
}

.not-found {
  border: 1px solid var(--line);
  padding: 1.4rem;
  background: var(--paper);
}

.animate-on-scroll {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.animate-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
}

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

@keyframes heroZoom {
  from {
    transform: scale(1.08);
  }
  to {
    transform: scale(1.02);
  }
}

@keyframes sectionPulse {
  0% {
    background: transparent;
  }
  50% {
    background: rgba(74, 63, 49, 0.08);
  }
  100% {
    background: transparent;
  }
}

.section-focus {
  animation: sectionPulse 0.85s ease;
}

@media (max-width: 880px) {
  .studio-shell,
  .philosophy-shell {
    padding-block: 3rem;
  }

  .studio-grid {
    grid-template-columns: 1fr;
    grid-template-areas:
      "text"
      "main";
    gap: 1rem;
  }

  .studio-image-main {
    transform: none;
    max-width: none;
  }

  .philosophy-concepts {
    grid-template-columns: 1fr;
  }

  .split-layout,
  .contact-premium-layout {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    flex-direction: column;
  }
}

@media (max-width: 760px) {
  .nav-wrap {
    flex-direction: column;
    align-items: flex-start;
  }

  .main-nav {
    flex-wrap: wrap;
  }

  .hero {
    min-height: 100vh;
  }

  .hero-copy {
    padding-top: 0;
  }

  .brand-logo {
    width: 142px;
  }

}
