:root {
  --cream: #F7F4EF;
  --ink:   #1C1C1A;
  --mid:   #6B6860;
  --line:  #E2DDD7;
  --spot:  #2D5A3D;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--cream);
  color: var(--ink);
  font-family: 'DM Sans', sans-serif;
  cursor: none;
  overflow-x: hidden;
}

/* ── cursor ── */
.cur-dot {
  position: fixed; width: 8px; height: 8px;
  background: var(--spot);
  border-radius: 50%;
  pointer-events: none; z-index: 999;
  transform: translate(-50%,-50%);
  transition: width .2s, height .2s;
}
.cur-ring {
  position: fixed; width: 36px; height: 36px;
  border: 1px solid var(--spot);
  border-radius: 50%;
  pointer-events: none; z-index: 998;
  transform: translate(-50%,-50%);
  opacity: .45;
  transition: width .25s, height .25s, opacity .25s;
}
.cur-ring.big { width: 56px; height: 56px; opacity: .2; }

/* ── nav ── */
nav {
  position: fixed; top: 0; left: 0; right: 0;
  display: flex; justify-content: space-between; align-items: center;
  padding: 28px 56px;
  z-index: 100;
  background: linear-gradient(var(--cream), transparent);
}
.logo {
  display: flex; align-items: center; gap: 10px;
  font-family: 'Playfair Display', serif;
  font-size: 19px; letter-spacing: .04em;
  color: var(--ink); text-decoration: none;
}
.logo-img {
  width: 28px; height: 28px;
  object-fit: contain;
  filter: invert(1);
  mix-blend-mode: multiply;
}
.nav-links { display: flex; gap: 36px; list-style: none; }
.nav-links a {
  font-size: 12px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--mid); text-decoration: none;
  transition: color .2s;
}
.nav-links a:hover { color: var(--ink); }

/* hamburger — oculto en desktop */
.nav-toggle { display: none; }

/* ── hero ── */
#hero {
  min-height: 100vh;
  display: grid;
  grid-template-rows: 1fr auto;
  padding: 0 56px 80px;
  border-bottom: 1px solid var(--line);
}

.hero-center {
  display: flex; flex-direction: column;
  justify-content: center;
  padding-top: 120px;
}

.hero-eyebrow {
  font-size: 11px; letter-spacing: .22em; text-transform: uppercase;
  color: var(--spot); margin-bottom: 40px;
  display: flex; align-items: center; gap: 12px;
  opacity: 0; animation: up .7s ease .1s forwards;
}
.hero-eyebrow::before {
  content: ''; width: 24px; height: 1px; background: var(--spot);
}

.hero-h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(52px, 7.5vw, 110px);
  line-height: 1.02;
  font-weight: 400;
  max-width: 820px;
}
.hero-h1 .line {
  display: block;
  opacity: 0; transform: translateY(30px);
  animation: up .85s cubic-bezier(.16,1,.3,1) forwards;
}
.hero-h1 .line:nth-child(1) { animation-delay: .2s; }
.hero-h1 .line:nth-child(2) { animation-delay: .35s; }
.hero-h1 em { font-style: italic; color: var(--spot); }

.hero-foot {
  display: flex; justify-content: space-between; align-items: flex-end;
  opacity: 0; animation: up .7s ease .7s forwards;
}
.hero-desc {
  max-width: 340px;
  font-size: 15px; font-weight: 300;
  color: var(--mid); line-height: 1.75;
}
.hero-btn {
  display: inline-flex; align-items: center; gap: 12px;
  font-size: 12px; letter-spacing: .16em; text-transform: uppercase;
  color: var(--ink); text-decoration: none;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 4px;
  transition: gap .3s, color .2s;
}
.hero-btn:hover { gap: 20px; color: var(--spot); border-color: var(--spot); }

/* ── services strip ── */
#servicios {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-bottom: 1px solid var(--line);
}
.svc {
  padding: 64px 48px;
  border-right: 1px solid var(--line);
  position: relative; overflow: hidden;
  opacity: 0; transform: translateY(24px);
  transition: background .3s, opacity .7s ease, transform .7s ease;
}
.svc:last-child { border-right: none; }
.svc.visible { opacity: 1; transform: translateY(0); }
.svc:hover { background: white; }

.svc-num {
  font-size: 10px; letter-spacing: .2em; text-transform: uppercase;
  color: var(--spot); margin-bottom: 32px;
}
.svc-name {
  font-family: 'Playfair Display', serif;
  font-size: 28px; font-weight: 400; line-height: 1.15;
  margin-bottom: 16px;
}
.svc-desc {
  font-size: 14px; color: var(--mid);
  font-weight: 300; line-height: 1.75;
}

/* ── qsp index strip ── */
#qsp {
  display: flex; justify-content: space-between; align-items: center;
  padding: 56px;
  border-bottom: 1px solid var(--line);
  gap: 40px;
}
.qsp-eyebrow {
  font-size: 11px; letter-spacing: .22em; text-transform: uppercase;
  color: var(--spot); margin-bottom: 10px;
  display: flex; align-items: center; gap: 12px;
}
.qsp-eyebrow::before {
  content: ''; width: 24px; height: 1px; background: var(--spot);
}
.qsp-desc {
  font-family: 'Playfair Display', serif;
  font-size: clamp(18px, 2vw, 26px);
  font-weight: 400; line-height: 1.35;
  max-width: 560px;
}
.qsp-link {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 12px; letter-spacing: .16em; text-transform: uppercase;
  color: var(--ink); text-decoration: none;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 4px;
  white-space: nowrap;
  transition: gap .3s, color .2s, border-color .2s;
  flex-shrink: 0;
}
.qsp-link:hover { gap: 16px; color: var(--spot); border-color: var(--spot); }

/* ── statement ── */
#statement {
  padding: 140px 56px;
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
}
.stmt {
  font-family: 'Playfair Display', serif;
  font-size: clamp(28px, 3.5vw, 50px);
  font-weight: 400; line-height: 1.45;
  max-width: 560px; text-align: center;
  color: var(--ink);
  opacity: 0; transform: translateY(20px);
  transition: opacity .9s ease, transform .9s ease;
}
.stmt.visible { opacity: 1; transform: translateY(0); }
.stmt em { color: var(--spot); font-style: italic; }

/* ── cta strip ── */
#cta {
  display: grid; grid-template-columns: 1fr 1fr;
  min-height: 240px;
}
.cta-left {
  padding: 72px 56px;
  border-right: 1px solid var(--line);
  display: flex; align-items: center;
}
.cta-left p {
  font-size: 15px; color: var(--mid);
  font-weight: 300; line-height: 1.75;
  max-width: 360px;
}
.cta-right {
  padding: 72px 56px;
  display: flex; align-items: center;
  background: var(--spot);
  transition: background .3s;
}
.cta-right:hover { background: #1e3d2a; }
.cta-link {
  font-family: 'Playfair Display', serif;
  font-size: clamp(32px, 4vw, 52px);
  color: var(--cream); text-decoration: none;
  display: flex; align-items: center; gap: 20px;
  transition: gap .3s;
}
.cta-link:hover { gap: 32px; }

/* ── footer ── */
footer {
  padding: 32px 56px;
  border-top: 1px solid var(--line);
  display: flex; justify-content: space-between; align-items: center;
}
footer span {
  font-size: 12px; letter-spacing: .1em;
  text-transform: uppercase; color: var(--mid);
}

/* ── keyframes ── */
@keyframes up {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ════════════════════════════════════════
   RESPONSIVE
   ════════════════════════════════════════ */

/* ── Tablet (≤ 1024px) ── */
@media (max-width: 1024px) {
  nav { padding: 24px 32px; }

  #hero { padding: 0 32px 64px; }

  #servicios { grid-template-columns: repeat(2, 1fr); }
  .svc:nth-child(2) { border-right: none; }
  .svc:nth-child(3) { border-top: 1px solid var(--line); border-right: none; grid-column: 1 / -1; }

  #statement { padding: 100px 32px; }

  #cta { grid-template-columns: 1fr 1fr; }
  .cta-left, .cta-right { padding: 56px 32px; }

  footer { padding: 28px 32px; }
}

/* ── Mobile (≤ 768px) ── */
@media (max-width: 768px) {

  /* cursor — desactivar en touch */
  body { cursor: auto; }
  .cur-dot, .cur-ring { display: none; }

  /* nav */
  nav { padding: 20px 24px; }

  .nav-links {
    display: none;
    flex-direction: column;
    gap: 0;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: var(--cream);
    justify-content: center;
    align-items: center;
    z-index: 99;
  }
  .nav-links.open { display: flex; }
  .nav-links li { border-bottom: 1px solid var(--line); width: 100%; text-align: center; }
  .nav-links a {
    display: block;
    padding: 20px 24px;
    font-size: 13px;
    letter-spacing: .18em;
  }

  /* hamburger button */
  .nav-toggle {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 24px; height: 16px;
    background: none; border: none;
    cursor: pointer; z-index: 101;
    padding: 0;
  }
  .nav-toggle span {
    display: block;
    width: 100%; height: 1px;
    background: var(--ink);
    transition: transform .3s, opacity .3s;
  }
  .nav-toggle.open span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
  .nav-toggle.open span:nth-child(2) { opacity: 0; }
  .nav-toggle.open span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

  /* hero */
  #hero { padding: 0 24px 56px; }
  .hero-center { padding-top: 100px; }
  .hero-eyebrow { margin-bottom: 28px; }

  .hero-h1 { font-size: clamp(40px, 11vw, 64px); }

  .hero-foot {
    flex-direction: column;
    align-items: flex-start;
    gap: 32px;
  }
  .hero-desc { max-width: 100%; }

  /* servicios — 1 columna */
  #servicios { grid-template-columns: 1fr; }
  .svc {
    border-right: none;
    border-bottom: 1px solid var(--line);
    padding: 48px 24px;
  }
  .svc:nth-child(3) { border-top: none; grid-column: auto; }
  .svc:last-child { border-bottom: none; }

  /* statement */
  #statement { padding: 72px 24px; }
  .stmt { font-size: clamp(24px, 6.5vw, 36px); }

  /* qsp */
  #qsp { flex-direction: column; align-items: flex-start; padding: 48px 24px; gap: 28px; }

  /* cta — 1 columna */
  #cta { grid-template-columns: 1fr; min-height: auto; }
  .cta-left {
    padding: 48px 24px;
    border-right: none;
    border-bottom: 1px solid var(--line);
  }
  .cta-right { padding: 48px 24px; }
  .cta-link { font-size: clamp(28px, 8vw, 40px); }

  /* footer */
  footer {
    padding: 28px 24px;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}

/* ════════════════════════════════════════
   MODAL DE CONTACTO
   ════════════════════════════════════════ */

.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(28, 28, 26, 0.55);
  backdrop-filter: blur(4px);
  z-index: 200;
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
  opacity: 0; pointer-events: none;
  transition: opacity .3s ease;
}
.modal-overlay.open {
  opacity: 1; pointer-events: all;
}

.modal {
  background: var(--cream);
  max-width: 600px; width: 100%;
  padding: 56px;
  position: relative;
  transform: translateY(20px);
  transition: transform .35s cubic-bezier(.16,1,.3,1);
}
.modal-overlay.open .modal {
  transform: translateY(0);
}

.modal-close {
  position: absolute; top: 24px; right: 24px;
  background: none; border: none;
  font-size: 16px; color: var(--mid);
  cursor: pointer; line-height: 1;
  transition: color .2s;
}
.modal-close:hover { color: var(--ink); }

.modal-eyebrow {
  font-size: 11px; letter-spacing: .22em; text-transform: uppercase;
  color: var(--spot); margin-bottom: 20px;
  display: flex; align-items: center; gap: 12px;
}
.modal-eyebrow::before {
  content: ''; width: 24px; height: 1px; background: var(--spot);
}

.modal-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(28px, 3.5vw, 42px);
  font-weight: 400; line-height: 1.15;
  margin-bottom: 12px;
}

.modal-sub {
  font-size: 14px; color: var(--mid);
  font-weight: 300; margin-bottom: 40px;
}

/* ── formulario ── */
.contact-form { display: flex; flex-direction: column; gap: 20px; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

.form-field { display: flex; flex-direction: column; gap: 8px; }

.form-field label {
  font-size: 11px; letter-spacing: .16em; text-transform: uppercase;
  color: var(--mid);
}

.form-field input,
.form-field textarea {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--line);
  padding: 10px 0;
  font-family: 'DM Sans', sans-serif;
  font-size: 15px; font-weight: 300;
  color: var(--ink);
  outline: none;
  transition: border-color .2s;
  resize: none;
}
.form-field input:focus,
.form-field textarea:focus { border-color: var(--spot); }

.form-footer {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: 8px;
}

.modal-email {
  font-size: 12px; letter-spacing: .08em;
  color: var(--mid); text-decoration: none;
  transition: color .2s;
}
.modal-email:hover { color: var(--spot); }

.form-submit {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: 'DM Sans', sans-serif;
  font-size: 12px; letter-spacing: .16em; text-transform: uppercase;
  color: var(--cream);
  background: var(--spot);
  border: none; cursor: pointer;
  padding: 14px 28px;
  transition: background .2s, gap .3s;
}
.form-submit:hover { background: #1e3d2a; gap: 16px; }

.form-status {
  font-size: 13px; text-align: center;
  min-height: 20px; color: var(--spot);
}
.form-status.error { color: #c0392b; }

/* ── modal responsive ── */
@media (max-width: 768px) {
  .modal { padding: 40px 24px; }
  .form-row { grid-template-columns: 1fr; }
  .form-footer { flex-direction: column; align-items: flex-start; gap: 20px; }
  .form-submit { width: 100%; justify-content: center; }
}
