﻿/* ======== BASE ======== */
* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
  }
  
  body {
    font-family: 'Poppins', sans-serif;
    color: var(--text);
    background: #fff;
    overflow-x: hidden;
  }
  
  h2 { 
    font-weight: 600; 
    color: var(--text); 
  }

h2{
  position: relative;
  display: inline-block;
}
h2::after{
  content:"";
  display:block;
  width:64px;
  height:3px;
  background: var(--brand);
  margin-top:10px;
  border-radius:999px;
}


  
/* ==== HERO ==== */
.hero {
  padding: 110px 8% 92px;
  text-align: left;
  margin-top: var(--header-height);
  background: #fff;
}

.hero-content {
  max-width: 980px;
}

.hero span,
.services-heading span {
  display: inline-block;
  margin-bottom: 16px;
  color: var(--brand);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.hero h1 {
  max-width: 16ch;
  font-size: clamp(2.45rem, 4.2vw, 4.7rem);
  font-weight: 800;
  line-height: 1.08;
  margin-bottom: 24px;
  color: #15191d;
}

.hero p {
  font-size: 1.18rem;
  color: #555;
  max-width: 690px;
  margin: 0;
  line-height: 1.75;
}

.hero .subtext {
  color: #777;
  font-size: 0.95rem;
}
  
/* ======== SERVICIOS ======== */
.services {
  padding: 96px 8% 110px;
  background: #f7f5f1;
}

.services .container {
  max-width: 1380px;
  margin: 0 auto;
}

.services-heading {
  display: block;
  max-width: 820px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 52px;
  text-align: center;
}

.services-heading h2 {
  display: block;
  max-width: 18ch;
  margin: 0 auto;
  font-size: clamp(2.05rem, 3.6vw, 3.9rem);
  font-weight: 800;
  line-height: 1.08;
  color: #15191d;
}

.services-heading h2::after {
  margin: 20px auto 0;
}

.services-heading p {
  max-width: 650px;
  margin: 24px auto 0;
  color: #4f565d;
  font-size: 1.08rem;
  line-height: 1.75;
}

.service-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.service-card {
  position: relative;
  min-height: 260px;
  padding: 34px;
  border: 1px solid #e5ded3;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(35, 28, 20, 0.07);
  overflow: hidden;
  transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.28s ease;
}

.service-card::before {
  content: "";
  position: absolute;
  left: 34px;
  top: 0;
  width: 64px;
  height: 4px;
  border-radius: 999px;
  background: var(--brand);
}

.service-card::after {
  content: "";
  position: absolute;
  right: -58px;
  bottom: -58px;
  width: 160px;
  height: 160px;
  border-radius: 999px;
  background: rgba(79, 176, 104, 0.08);
  pointer-events: none;
}

.service-card:hover {
  transform: translateY(-7px);
  border-color: rgba(79, 176, 104, 0.24);
  box-shadow: 0 22px 46px rgba(35, 28, 20, 0.12);
}

.service-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  margin-bottom: 34px;
  border-radius: 999px;
  background: #edf3e9;
  color: #4f8b55;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.service-card h3 {
  max-width: 16ch;
  margin-bottom: 14px;
  color: #15191d;
  font-size: clamp(1.22rem, 1.55vw, 1.55rem);
  line-height: 1.18;
  font-weight: 800;
}

.service-card p {
  max-width: 32ch;
  color: #515860;
  font-size: 1rem;
  line-height: 1.7;
}
  
/* ======== EXTRA SECTION ======== */
.extra {
  display: grid;
  grid-template-columns: minmax(380px, 0.74fr) minmax(0, 1fr);
  min-height: 560px;
  background: #f7f5f1;
}

.extra .text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding: clamp(48px, 6vw, 88px) clamp(34px, 5vw, 76px) clamp(48px, 6vw, 88px) 8vw;
}

.extra .text span {
  display: inline-block;
  margin-bottom: 16px;
  color: var(--brand);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.extra .text h2 {
  max-width: 12ch;
  margin: 0 0 22px;
  color: #15191d;
  font-size: clamp(2rem, 3.5vw, 3.8rem);
  font-weight: 800;
  line-height: 1.08;
}

.extra .text h2::after {
  margin-top: 18px;
}

.extra .text p {
  max-width: 62ch;
  margin: 0 0 18px;
  color: #4f565d;
  font-size: 1.05rem;
  line-height: 1.8;
}

.extra .image {
  min-height: 560px;
  overflow: hidden;
}

.extra .image img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 560px;
  object-fit: cover;
}
  
/* ==== FOOTER ==== */
.footer {
    text-align: center;
    padding: 40px 20px;
    background: #333;
    font-size: 0.95rem;
    color: #f5f5f5;
  }

  /* ==== SCROLL REVEAL ==== */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: all 0.6s ease;
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

.hero.reveal {
  opacity: 1;
  transform: none;
}

/* evita que el header tape el inicio al hacer anchor links */
:root { --header-height: 80px; }
section { scroll-margin-top: calc(var(--header-height) + 20px); }

@media (max-width: 1100px) {
  .service-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .extra {
    grid-template-columns: 1fr;
  }

  .extra .image {
    min-height: 360px;
  }

  .extra .image img {
    min-height: 360px;
  }
}

@media (max-width: 720px) {
  .hero {
    padding: 86px 6% 64px;
  }

  .hero-content {
    width: 100%;
    min-width: 0;
  }

  .hero h1 {
    max-width: min(16ch, calc(100vw - 12vw));
    font-size: clamp(1.95rem, 7.8vw, 2.35rem);
    line-height: 1.12;
    overflow-wrap: normal;
  }

  .hero p {
    max-width: min(32ch, calc(100vw - 12vw));
    font-size: 1.02rem;
    overflow-wrap: break-word;
  }

  .services {
    padding: 70px 6% 82px;
  }

  .services-heading {
    margin-bottom: 34px;
  }

  .service-cards {
    grid-template-columns: 1fr;
  }

  .service-card {
    min-height: 0;
    padding: 28px 24px;
  }

  .service-number {
    margin-bottom: 24px;
  }

  .extra .text {
    padding: 64px 6%;
  }

  .extra .image,
  .extra .image img {
    min-height: 320px;
  }
}
  
