/* ═══════════════════════════════════════
   ESTATE-SERVICES.CSS
═══════════════════════════════════════ */

#estate-services {
  background: var(--black);
  padding: 9rem 0;
  border-top: 1px solid var(--border);
}

/* ── Header ── */
.es-header {
  padding: 0 5vw 5rem;
  border-bottom: 1px solid var(--border);
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: 5vw;
  align-items: start;
}

.es-header .label {
  grid-column: 1 / -1;
  margin-bottom: 1.2rem;
}

.es-header h2 {
  font-size: clamp(2.2rem, 4vw, 4rem);
  color: var(--white);
  line-height: 1.05;
}

.es-intro {
  font-size: 1rem;
  font-weight: 300;
  line-height: 1.85;
  color: var(--muted);
  max-width: 560px;
  align-self: end;
  padding-bottom: 0.25rem;
}

/* ── Grid 4 × 2 ── */
.es-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--border);
}

.es-card {
  padding: 3.5rem 2.8rem;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
  cursor: default;
  transition: background 0.45s ease, transform 0.4s cubic-bezier(.16,1,.3,1);
}
.es-card:nth-child(4n) { border-right: none; }
.es-card:nth-last-child(-n+4) { border-bottom: none; }

/* Línea de acento que sube desde abajo al hacer hover */
.es-card::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s cubic-bezier(.16,1,.3,1);
}
.es-card:hover::before { transform: scaleX(1); }

.es-card:hover {
  background: rgba(255,255,255,0.035);
  transform: translateY(-4px);
}

/* ── Icono ── */
.es-icon {
  font-size: 1.4rem;
  color: var(--accent);
  opacity: 0.5;
  margin-bottom: 1.8rem;
  line-height: 1;
  display: inline-block;
  transition: opacity 0.35s ease, transform 0.4s cubic-bezier(.16,1,.3,1);
}
.es-card:hover .es-icon {
  opacity: 1;
  transform: rotate(90deg) scale(1.15);
}

/* ── Nombre ── */
.es-name {
  font-family: 'Playfair Display', serif;
  font-size: 1.15rem;
  font-weight: 400;
  color: var(--white);
  margin-bottom: 1rem;
  line-height: 1.3;
  transition: color 0.3s ease;
}
.es-card:hover .es-name { color: var(--accent); }

/* ── Línea decorativa bajo el nombre ── */
.es-name-line {
  width: 1.5rem;
  height: 1px;
  background: var(--accent);
  margin-bottom: 1.2rem;
  opacity: 0.4;
  transition: width 0.4s cubic-bezier(.16,1,.3,1), opacity 0.4s ease;
}
.es-card:hover .es-name-line {
  width: 3rem;
  opacity: 1;
}

/* ── Descripción ── */
.es-desc {
  font-size: 0.88rem;
  font-weight: 300;
  line-height: 1.9;
  color: var(--muted);
  transition: color 0.35s ease;
}
.es-card:hover .es-desc { color: var(--subtle); }

/* ── Responsive ── */
@media (max-width: 1100px) {
  .es-grid { grid-template-columns: repeat(2, 1fr); }
  .es-card:nth-child(4n)  { border-right: 1px solid var(--border); }
  .es-card:nth-child(2n)  { border-right: none; }
  .es-card:nth-last-child(-n+4) { border-bottom: 1px solid var(--border); }
  .es-card:nth-last-child(-n+2) { border-bottom: none; }
}

@media (max-width: 600px) {
  .es-grid { grid-template-columns: 1fr; }
  .es-card { border-right: none !important; border-bottom: 1px solid var(--border) !important; }
  .es-card:last-child { border-bottom: none !important; }
  .es-header { grid-template-columns: 1fr; }
}
