    
      :root {
        --primary: #ffc107;
        --secondary: #e6ac00;
        --dark: #1e293b;
        --light: #f8f9fa;
        --accent: #ff006e;
      }
      .service-image-header {
        width: 100%;
        height: 180px; /* Altura fija como la del antiguo .service-icon */
        overflow: hidden;
        position: relative;
      }

      .service-image-header img {
        width: 100%;
        height: 100%;
        object-fit: cover; /* O "contain" si quieres que no se recorte nada */
        display: block;
      }

      body {
        font-family: "Poppins", sans-serif;
        background-color: #f5f7fa;
      }

      /* Hero Section */
      .hero-services {
        background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)),
          url("img/header.jpg") center center;
        background-size: cover;
        padding: 120px 0 80px;
        margin-bottom: 60px;
        text-align: center;
        color: white;
      }

      .hero-services h1 {
        font-size: 3rem;
        font-weight: 800;
        margin-bottom: 20px;
        text-transform: uppercase;
        letter-spacing: 1px;
      }

      .hero-services p {
        font-size: 1.2rem;
        max-width: 800px;
        margin: 0 auto 30px;
        opacity: 0.9;
      }

      /* Services Section */
      .services-section {
        padding: 50px 0 100px;
      }

      .section-title {
        text-align: center;
        margin-bottom: 60px;
      }

      .section-title h2 {
        font-size: 2.5rem;
        font-weight: 700;
        color: var(--dark);
        position: relative;
        display: inline-block;
        margin-bottom: 15px;
      }

      .section-title h2::after {
        content: "";
        position: absolute;
        bottom: -10px;
        left: 50%;
        transform: translateX(-50%);
        width: 80px;
        height: 4px;
        background: linear-gradient(45deg, var(--primary), var(--secondary));
        border-radius: 2px;
      }

      .section-title p {
        color: #666;
        max-width: 700px;
        margin: 20px auto 0;
        font-size: 1.1rem;
      }

      /* Services Cards */
      .services-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
        gap: 30px;
        max-width: 1200px;
        margin: 0 auto;
      }

      .service-card {
        background: white;
        border-radius: 12px;
        overflow: hidden;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
        transition: all 0.4s ease;
        cursor: pointer;
        position: relative;
        height: 100%;
        display: flex;
        flex-direction: column;
      }

      .service-card:hover {
        transform: translateY(-10px);
        box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
      }

      .service-icon {
        height: 180px;
        background: linear-gradient(135deg, var(--primary), var(--secondary));
        display: flex;
        align-items: center;
        justify-content: center;
        color: white;
        font-size: 3.5rem;
      }

      .service-content {
        padding: 25px;
        flex-grow: 1;
        display: flex;
        flex-direction: column;
      }

      .service-content h3 {
        font-size: 1.5rem;
        font-weight: 700;
        margin-bottom: 15px;
        color: var(--dark);
      }

      .service-content p {
        color: #666;
        margin-bottom: 20px;
        flex-grow: 1;
      }

      .service-link {
        color: var(--primary);
        font-weight: 600;
        text-decoration: none;
        display: flex;
        align-items: center;
        transition: all 0.3s;
      }

      .service-link i {
        margin-left: 8px;
        transition: transform 0.3s;
      }

      .service-link:hover {
        color: var(--secondary);
      }

      .service-link:hover i {
        transform: translateX(5px);
      }

      /* Service Modal */
      .service-modal {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.8);
        z-index: 1000;
        overflow: auto;
        padding: 30px;
        box-sizing: border-box;
      }

      .modal-content {
        background: white;
        max-width: 800px;
        margin: 50px auto;
        border-radius: 12px;
        overflow: hidden;
        box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
        animation: modalFade 0.5s;
        position: relative;
      }

      @keyframes modalFade {
        from {
          opacity: 0;
          transform: translateY(-50px);
        }
        to {
          opacity: 1;
          transform: translateY(0);
        }
      }

      .modal-header {
        background: linear-gradient(135deg, var(--primary), var(--secondary));
        padding: 30px;
        color: white;
        position: relative;
      }

      .close-modal {
        position: absolute;
        top: 20px;
        right: 20px;
        color: white;
        font-size: 1.8rem;
        cursor: pointer;
        background: rgba(0, 0, 0, 0.2);
        width: 40px;
        height: 40px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.3s;
      }

      .close-modal:hover {
        background: rgba(0, 0, 0, 0.3);
        transform: rotate(90deg);
      }

      .modal-header h2 {
        font-size: 2rem;
        font-weight: 700;
        margin-bottom: 10px;
      }

      .modal-icon {
        font-size: 4rem;
        margin-bottom: 20px;
        color: rgba(255, 255, 255, 0.3);
      }

      .modal-body {
        padding: 30px;
      }

      .modal-body h3 {
        font-size: 1.5rem;
        color: var(--primary);
        margin-bottom: 20px;
        padding-bottom: 10px;
        border-bottom: 2px solid #f0f0f0;
      }

      .modal-body p {
        color: #555;
        line-height: 1.8;
        margin-bottom: 20px;
      }

      .modal-features {
        background: #f8fafc;
        padding: 20px;
        border-radius: 8px;
        margin: 25px 0;
      }

      .modal-features h4 {
        color: var(--dark);
        margin-bottom: 15px;
        font-size: 1.2rem;
      }

      .modal-features ul {
        list-style-type: none;
        padding: 0;
      }

      .modal-features li {
        padding: 8px 0;
        padding-left: 30px;
        position: relative;
        color: #555;
      }

      .modal-features li:before {
        content: "✓";
        position: absolute;
        left: 0;
        top: 8px;
        color: var(--primary);
        font-weight: bold;
      }

      /* Responsive Design */
      @media (max-width: 992px) {
        .services-grid {
          grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        }
      }

      @media (max-width: 768px) {
        .hero-services {
          padding: 100px 0 60px;
        }

        .hero-services h1 {
          font-size: 2.5rem;
        }

        .section-title h2 {
          font-size: 2rem;
        }

        .modal-content {
          margin: 20px auto;
        }
      }

      @media (max-width: 576px) {
        .services-grid {
          grid-template-columns: 1fr;
        }

        .hero-services h1 {
          font-size: 2rem;
        }

        .modal-header {
          padding: 20px;
        }

        .modal-header h2 {
          font-size: 1.5rem;
        }

      }
      .detalle-box {
        background: white;
        padding: 40px;
        border-radius: 16px;
        box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
        max-width: 900px;
        margin: 0 auto 60px;
        color: var(--dark);
        animation: fadeIn 0.5s ease-in-out;
      }

      .detalle-header {
        border-bottom: 2px solid #eee;
        margin-bottom: 30px;
      }

      .detalle-title {
        font-size: 2rem;
        font-weight: 700;
        color: var(--primary);
        margin-bottom: 10px;
      }

      .detalle-description {
        font-size: 1.1rem;
        color: #555;
      }

      .detalle-section {
        margin-top: 30px;
      }

      .detalle-subtitulo {
        font-size: 1.3rem;
        color: var(--secondary);
        margin-bottom: 15px;
      }

      .detalle-lista {
        padding-left: 20px;
        margin-top: 10px;
      }

      .detalle-lista li {
        margin-bottom: 10px;
        position: relative;
        padding-left: 1.5em;
        color: #444;
      }

      .detalle-lista li::before {
        content: "✔";
        position: absolute;
        left: 0;
        color: var(--primary);
        font-weight: bold;
      }

      @keyframes fadeIn {
        from { opacity: 0; transform: translateY(20px); }
        to { opacity: 1; transform: translateY(0); }
      }

/* ===========================
   Base & Variables
=========================== */
:root{
  --bg: #f7f8fb;
  --card-bg:#fff;
  --text:#1f2937;
  --muted:#6b7280;
  --brand:#ffc107;
  --ring: rgba(255,193,7,0.35);
  --radius:14px;
  --shadow-sm: 0 2px 8px rgba(0,0,0,.06);
  --shadow-md: 0 10px 24px rgba(0,0,0,.10);
  --shadow-lg: 0 18px 40px rgba(0,0,0,.12);
}

* { box-sizing: border-box; }
img{ display:block; max-width:100%; }

/* Accesibilidad: foco visible para teclado */
:focus-visible{
  outline: 2px solid var(--brand);
  outline-offset: 2px;
  border-radius: 10px;
}

/* Respeta usuarios con motion reducido */
@media (prefers-reduced-motion: reduce){
  *, *::before, *::after{ animation: none !important; transition: none !important; }
}

/* ===========================
   Contenedor principal
=========================== */
#servicios-container{
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1rem;
  background: var(--bg);
}

/* Usamos grid para un layout más consistente */
.servicios-grid{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.1rem;
}

/* ===========================
   Tarjetas
=========================== */
.servicio-card{
  position: relative;
  background: var(--card-bg);
  border-radius: var(--radius);
  border: 1px solid #eef0f4;
  box-shadow: var(--shadow-sm);
  transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
  overflow: hidden;
  cursor: pointer;
  isolation: isolate; /* para pseudo-elementos */
}

.servicio-card::after{
  /* sutil brillo superior */
  content:"";
  position:absolute; inset:0 0 auto 0; height: 6px;
  background: linear-gradient(90deg, transparent, rgba(255,193,7,.35), transparent);
  opacity:.0; transition: opacity .25s ease;
}

.servicio-card:hover{
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: rgba(255,193,7,.45);
}
.servicio-card:hover::after{ opacity:1; }

/* Imagen: más pequeña, nítida y con sombra limpia */
.servicio-card .servicio-media{
  display:flex; align-items:center; justify-content:center;
  padding: 1rem 1rem .6rem;
}
.servicio-card img{
  width: 64%;
  max-width: 140px;
  height: 92px;              /* más compacto */
  object-fit: contain;
  background: #fffef9;
  border-radius: 10px;
  padding: .45rem;
  box-shadow: 0 3px 10px rgba(0,0,0,.07);
  transition: transform .2s ease;
}
.servicio-card:hover img{ transform: scale(1.04); }

/* Texto */
.servicio-card .servicio-body{
  text-align: center;
  padding: 0 .9rem 1rem;
}
.servicio-card h5{
  font-size: .96rem;
  font-weight: 700;
  margin: .25rem 0 .35rem;
  color: var(--text);
  letter-spacing: .2px;
}
.servicio-card p{
  font-size: .84rem;
  color: var(--muted);
  line-height: 1.45;
  margin: 0 auto;
}

/* Botón/CTA opcional dentro de la card */
.servicio-card .servicio-cta{
  display:inline-flex; align-items:center; justify-content:center;
  gap:.4rem; font-size:.82rem; font-weight:600;
  color:#5a4a00; background: #fff6cf;
  border:1px solid #ffe28b;
  padding:.45rem .7rem; border-radius: 10px;
  margin: .25rem 0 0;
  transition: background .2s ease, transform .2s ease;
}
.servicio-card .servicio-cta:hover{
  background:#ffec9a; transform: translateY(-1px);
}

/* ===========================
   Vista Detalle / Modal
=========================== */
.detalle-box{
  background: var(--card-bg);
  border:1px solid #eef0f4;
  border-radius: calc(var(--radius) + 2px);
  box-shadow: var(--shadow-lg);
  overflow:hidden;
}

/* Hero con imagen más cuidada */
.detalle-hero{
  position: relative;
  aspect-ratio: 16/7;           /* capa hero responsiva */
  background: linear-gradient(180deg, #fffdf4, #fff);
  overflow: hidden;
}
.detalle-hero img{
  position:absolute; inset:0; margin:auto;
  width: 100%; height:100%;
  object-fit: cover;
  filter: saturate(1.02) contrast(1.02);
  transform: scale(1.02);
}
.detalle-hero::after{
  content:"";
  position:absolute; inset:0;
  box-shadow: inset 0 -60px 80px -40px rgba(0,0,0,.18);
  border-bottom-left-radius: calc(var(--radius) + 2px);
  border-bottom-right-radius: calc(var(--radius) + 2px);
}

/* Header */
.detalle-header{
  padding: 1.2rem 1.2rem .6rem;
}
.detalle-header h2{
  font-size: 1.35rem;
  margin: 0 0 .35rem;
  color: var(--text);
  line-height: 1.2;
}
.detalle-header p{
  margin: 0;
  color: var(--muted);
  font-size: .95rem;
  line-height: 1.55;
}

/* Secciones */
.detalle-section{
  padding: .8rem 1.2rem 1.2rem;
  border-top: 1px dashed #eef0f4;
}
.detalle-section h3,
.detalle-section h4{
  margin: .25rem 0 .6rem;
  color: var(--text);
  font-size: 1.05rem;
}

/* Lista con “checks” sutiles sin iconos externos */
.detalle-section ul{
  list-style: none; padding: 0; margin: 0;
  display: grid; gap: .55rem;
}
.detalle-section li{
  position: relative; padding-left: 1.55rem;
  color: #374151; font-size: .95rem; line-height: 1.45;
}
.detalle-section li::before{
  content:"";
  position:absolute; left:0; top:.28rem;
  width: 18px; height: 18px; border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, #ffe48a 0 40%, transparent 41% 100%);
  border: 2px solid var(--brand);
  box-shadow: 0 2px 6px var(--ring);
}

/* Pequeños ajustes responsivos */
@media (min-width: 992px){
  .detalle-header{ padding: 1.4rem 1.6rem .6rem; }
  .detalle-section{ padding: 1rem 1.6rem 1.4rem; }
}
