:root {
  color-scheme: light;
  --bg: #f3efe6;
  --surface: #ffffff;
  --surface-2: #eef2ea;
  --ink: #14211b;
  --muted: #516055;
  --green: #1f5c46;
  --green-2: #2f7359;
  --blue: #2f5f8a;
  --clay: #c8793d;
  --line: rgba(20, 33, 27, 0.12);
  --shadow: 0 20px 60px rgba(20, 33, 27, 0.12);
  --radius: 12px;
  --container: min(1180px, calc(100vw - 40px));
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.5;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, textarea { font: inherit; }

.container { width: var(--container); margin: 0 auto; }
.page-shell {
  position: relative;
}
.preloader {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at top, rgba(243, 239, 230, 0.98), rgba(220, 229, 216, 0.98));
  transition: opacity 420ms ease, visibility 420ms ease;
}
.preloader-mark {
  display: grid;
  place-items: center;
  gap: 14px;
  width: 124px;
  height: 124px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 18px 50px rgba(20, 33, 27, 0.14);
  animation: pulse 1.8s ease-in-out infinite;
}
.preloader-mark img {
  width: 58px;
  height: 58px;
  object-fit: contain;
}
html:not(.has-js) .preloader {
  display: none;
}
html.has-js body:not(.is-loaded) .preloader {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
body.is-loaded .preloader {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 20px;
  background: rgba(243, 239, 230, 0.9);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
  transition: padding 180ms ease, background 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}
.topbar.is-scrolled {
  padding-top: 10px;
  padding-bottom: 10px;
  background: rgba(243, 239, 230, 0.96);
  box-shadow: 0 10px 28px rgba(20, 33, 27, 0.08);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  letter-spacing: 0;
}
.brand img { width: 38px; height: 38px; object-fit: contain; }
.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.55);
  color: var(--ink);
  box-shadow: 0 8px 18px rgba(20, 33, 27, 0.06);
}
.nav-toggle span {
  position: absolute;
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transition: transform 180ms ease, opacity 180ms ease, top 180ms ease;
}
.nav-toggle span:nth-child(1) { transform: translateY(-6px); }
.nav-toggle span:nth-child(2) { transform: translateY(0); }
.nav-toggle span:nth-child(3) { transform: translateY(6px); }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(0) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(0) rotate(-45deg); }
.nav {
  display: flex;
  align-items: center;
  gap: 20px;
  color: var(--muted);
}
.nav a:hover { color: var(--ink); }
.nav a {
  position: relative;
  padding: 6px 0;
}
.nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 180ms ease;
}
.nav a:hover::after,
.nav a.is-active::after {
  transform: scaleX(1);
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid transparent;
  transition: transform 160ms ease, background 160ms ease, border-color 160ms ease;
  letter-spacing: 0;
}
.btn:hover { transform: translateY(-1px); }
.btn-solid {
  color: white;
  background: var(--green);
}
.btn-solid:hover { background: var(--green-2); }
.btn-ghost {
  border-color: rgba(255,255,255,0.35);
  color: white;
  background: rgba(255,255,255,0.08);
}

.hero {
  position: relative;
  min-height: calc(100vh - 70px);
  display: grid;
  align-items: center;
  overflow: hidden;
  background: #102019;
}
.hero-media,
.hero-overlay {
  position: absolute;
  inset: 0;
}
.hero-media {
  background:
    linear-gradient(180deg, rgba(8,15,12,0.15), rgba(8,15,12,0.7)),
    url("hero-portada.jpg") center/cover no-repeat;
  transform: scale(1.03);
}
.hero-overlay {
  background:
    linear-gradient(90deg, rgba(12, 24, 18, 0.84) 0%, rgba(12, 24, 18, 0.58) 55%, rgba(12, 24, 18, 0.3) 100%);
}
.hero-content {
  position: relative;
  z-index: 1;
  padding: 90px 0 120px;
  color: white;
}
html.has-js body:not(.is-loaded) .hero-content > * {
  opacity: 0;
  transform: translateY(18px);
}
body.is-loaded .hero-content > * {
  animation: riseUp 720ms ease forwards;
}
.hero-content > *:nth-child(1) { animation-delay: 120ms; }
.hero-content > *:nth-child(2) { animation-delay: 240ms; }
.hero-content > *:nth-child(3) { animation-delay: 360ms; }
.hero-content > *:nth-child(4) { animation-delay: 480ms; }
.eyebrow {
  margin: 0 0 10px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.8rem;
  color: #d8e3d8;
}
.hero h1 {
  margin: 0;
  font-size: clamp(3.2rem, 6vw, 6.2rem);
  line-height: 0.95;
}
.lead {
  max-width: 700px;
  margin: 18px 0 0;
  font-size: clamp(1.1rem, 2vw, 1.45rem);
  color: #f3f6ef;
}
.support {
  max-width: 720px;
  margin: 12px 0 0;
  color: rgba(255,255,255,0.8);
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}
.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}
.hero-badges span,
.contact-points span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.15);
  color: white;
}
.hero-badges a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.15);
  color: white;
}
.hero-badges a:hover {
  background: rgba(255,255,255,0.16);
}

.band, .section {
  padding: 72px 0;
}
.band-tight { padding: 22px 0; background: #dce5d8; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}
.stats article {
  padding: 14px 16px;
  border-left: 3px solid var(--green);
}
html.has-js body:not(.is-loaded) .stats article {
  opacity: 0;
  transform: translateY(14px);
}
body.is-loaded .band-tight .stats article {
  animation: riseUp 700ms ease forwards;
}
body.is-loaded .band-tight .stats article:nth-child(1) { animation-delay: 80ms; }
body.is-loaded .band-tight .stats article:nth-child(2) { animation-delay: 160ms; }
body.is-loaded .band-tight .stats article:nth-child(3) { animation-delay: 240ms; }
body.is-loaded .band-tight .stats article:nth-child(4) { animation-delay: 320ms; }
.stats strong { display: block; font-size: 1.1rem; }
.stats span { color: var(--muted); }
.section-head {
  display: grid;
  gap: 10px;
  margin-bottom: 28px;
}
.section-head h2, .split h2, .contact-grid h2 { margin: 0; font-size: clamp(1.8rem, 3vw, 2.7rem); line-height: 1.05; }
.section-head p, .split p, .contact-grid p { margin: 0; color: var(--muted); max-width: 780px; }
.compare-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.compare-card, .service-card, .contact-form, .photo-stack, .gallery img {
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.compare-card {
  padding: 18px;
  min-height: 260px;
}
html.has-js body:not(.is-loaded) .compare-card,
html.has-js body:not(.is-loaded) .service-card,
html.has-js body:not(.is-loaded) .contact-grid > * {
  opacity: 0;
  transform: translateY(16px);
}
body.is-loaded .compare-grid .compare-card,
body.is-loaded .service-grid .service-card,
body.is-loaded .contact-grid > * {
  animation: riseUp 760ms ease forwards;
}
body.is-loaded .compare-grid .compare-card:nth-child(1),
body.is-loaded .service-grid .service-card:nth-child(1) { animation-delay: 80ms; }
body.is-loaded .compare-grid .compare-card:nth-child(2),
body.is-loaded .service-grid .service-card:nth-child(2) { animation-delay: 160ms; }
body.is-loaded .compare-grid .compare-card:nth-child(3),
body.is-loaded .service-grid .service-card:nth-child(3) { animation-delay: 240ms; }
body.is-loaded .compare-grid .compare-card:nth-child(4) { animation-delay: 320ms; }
.compare-card h3 { margin: 0 0 14px; font-size: 1.15rem; }
.compare-card ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
}
.compare-card li + li { margin-top: 10px; }
.compare-card.warm { background: #fff9f2; }
.compare-card.cool { background: #f1f6fb; }
.compare-card.neutral { background: #f4f7f2; }
.compare-card.accent { background: #fff5e7; }

.section-alt { background: #edf1ea; }
.service-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  perspective: 1200px;
}
.service-card {
  overflow: hidden;
  transform: translateY(0);
  transition: transform 240ms ease, box-shadow 240ms ease, border-color 240ms ease;
  will-change: transform;
}
.service-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-bottom: 1px solid var(--line);
  transition: transform 320ms ease, filter 320ms ease;
  transform: scale(1);
}
.service-card div { padding: 16px; }
.service-card h3 { margin: 0 0 8px; }
.service-card p { margin: 0; color: var(--muted); }
.service-feature {
  grid-column: span 1;
  background:
    linear-gradient(180deg, rgba(47, 95, 138, 0.08), rgba(31, 92, 70, 0.04)),
    var(--surface);
}
.service-card:hover,
.service-card:focus-within {
  transform: translateY(-10px);
  box-shadow: 0 28px 72px rgba(20, 33, 27, 0.18);
  border-color: rgba(31, 92, 70, 0.26);
}
.service-card:hover img,
.service-card:focus-within img {
  transform: scale(1.05);
  filter: saturate(1.05) contrast(1.02);
}
.service-card:hover h3,
.service-card:focus-within h3 {
  color: var(--green);
}

.split {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 28px;
  align-items: center;
}
.checklist {
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}
.checklist li {
  position: relative;
  padding-left: 24px;
  margin-top: 12px;
  color: var(--muted);
}
.checklist li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.45em;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--clay);
}
.photo-stack {
  display: grid;
  gap: 16px;
  padding: 16px;
}
.photo-stack img,
.gallery img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}
.gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.contact-band {
  background: linear-gradient(180deg, #d8e3d8, #cfdccf);
}
.contact-grid {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 28px;
  align-items: start;
}
body.is-loaded .contact-grid > *:nth-child(1) { animation-delay: 120ms; }
body.is-loaded .contact-grid > *:nth-child(2) { animation-delay: 220ms; }
.contact-visual {
  margin: 18px 0 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  background: var(--surface);
}
.contact-visual img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}
.contact-points {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0 22px;
}
.contact-points span {
  background: rgba(20,33,27,0.06);
  border-color: rgba(20,33,27,0.08);
  color: var(--ink);
}
.contact-form {
  display: grid;
  gap: 14px;
  padding: 20px;
}
.form-status {
  display: grid;
  gap: 4px;
  padding: 14px 16px;
  border-radius: 10px;
  border: 1px solid transparent;
  font-weight: 700;
}
.form-status-success {
  border-color: rgba(31, 92, 70, 0.2);
  background: rgba(31, 92, 70, 0.08);
  color: var(--green);
}
.contact-form label {
  display: grid;
  gap: 6px;
  font-weight: 700;
}
.contact-form label.form-check {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
}
.contact-form label.form-check input {
  width: 18px;
  height: 18px;
  margin: 0;
  padding: 0;
  accent-color: var(--green);
  flex: 0 0 auto;
}
.contact-form label.form-check span {
  line-height: 1.3;
}
.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
}
.contact-form button {
  min-height: 46px;
  border: 0;
  border-radius: 999px;
  background: var(--clay);
  color: #fff;
  font-weight: 700;
}

.footer {
  padding: 20px 0 30px;
  border-top: 1px solid var(--line);
}
.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: var(--muted);
  font-size: 0.95rem;
  text-align: center;
}

.floating-actions {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 10px;
}
.floating-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 14px 0 12px;
  border-radius: 999px;
  color: #fff;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.18);
}
.floating-instagram {
  background: linear-gradient(135deg, #f58529 0%, #dd2a7b 42%, #8134af 75%, #515bd4 100%);
}
.floating-instagram:hover {
  background: linear-gradient(135deg, #ff9a3d 0%, #eb3b89 42%, #943dca 75%, #6570e8 100%);
}
.floating-btn svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
  flex: 0 0 auto;
}
.floating-whatsapp { background: #1fa855; }
.floating-btn span {
  font-weight: 700;
  letter-spacing: 0;
}

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

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.04); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .preloader,
  .preloader-mark,
  .hero-content > *,
  .stats article,
  .compare-card,
  .service-card,
  .contact-grid > * {
    animation: none !important;
    transition: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
  body.is-loaded .preloader {
    opacity: 0;
    visibility: hidden;
  }
}

@media (max-width: 1080px) {
  .stats, .compare-grid, .service-grid, .split, .contact-grid, .gallery {
    grid-template-columns: 1fr 1fr;
  }
  .compare-card, .service-card {
    min-height: 0;
  }
}

@media (max-width: 720px) {
  .topbar {
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
  }
  .container { width: min(100vw - 28px, 1180px); }
  .hero-content { padding: 72px 0 88px; }
  .stats, .compare-grid, .service-grid, .split, .contact-grid, .gallery {
    grid-template-columns: 1fr;
  }
  .hero-badges span,
  .contact-points span {
    width: 100%;
    justify-content: center;
    text-align: center;
  }
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .btn, .floating-btn {
    width: 100%;
  }
  .floating-actions {
    left: 14px;
    right: 14px;
    justify-content: space-between;
  }
  .floating-btn {
    flex: 1 1 0;
    justify-content: center;
  }
  .footer-inner {
    align-items: center;
  }
  .floating-btn span {
    display: none;
  }
  .nav-toggle {
    display: inline-flex;
    position: relative;
    flex: 0 0 auto;
  }
  .nav {
    display: grid;
    width: 100%;
    gap: 0;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    padding: 0 0;
    transition: max-height 220ms ease, opacity 180ms ease, visibility 180ms ease, padding 220ms ease;
    order: 3;
    flex-basis: 100%;
  }
  .nav.is-open {
    max-height: 220px;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    padding: 10px 0 4px;
  }
  .nav a {
    padding: 12px 0;
    border-top: 1px solid var(--line);
  }
  .nav a::after {
    display: none;
  }
}
