/* IT Solutions — estilos específicos de la Home */

/* ---------- Hero ---------- */
.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--color-navy);
  color: var(--color-on-dark);
  --focus-ring: var(--color-turquoise);
}
.hero__image { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
.hero--photo .hero__image { object-position: 70% center; }
.hero--photo::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: rgba(16, 42, 67, 0.82);   /* móvil: velo uniforme para que el texto se lea sobre toda la foto */
}
@media (min-width: 48em) {
  /* Escritorio: texto sobre la parte oscura a la izquierda y las personas visibles a la derecha */
  .hero--photo::before {
    background: linear-gradient(90deg, rgba(16, 42, 67, 0.94) 0%, rgba(16, 42, 67, 0.88) 38%, rgba(16, 42, 67, 0.55) 56%, rgba(16, 42, 67, 0.12) 78%, rgba(16, 42, 67, 0) 100%);
  }
  .hero--photo .hero__image { object-position: center; }
  .hero__title { max-width: 26ch; }
  .hero__line { display: block; }
}
.hero__pattern {
  display: none; position: absolute; z-index: -1; top: 50%; right: -2rem;
  width: min(40rem, 52%); transform: translateY(-50%);
  color: var(--color-turquoise); opacity: 0.25;
}
@media (min-width: 48em) { .hero__pattern { display: block; } }
.hero--photo .hero__pattern { display: none; }

.hero__inner { padding-block: clamp(2.5rem, 6vw, 5rem); }
.hero__title { max-width: 22ch; margin-bottom: var(--space-4); color: var(--color-on-dark); text-wrap: balance; }
.hero__accent { color: var(--color-turquoise); }
.hero__text { max-width: 52ch; margin-bottom: var(--space-5); font-size: var(--fs-lead); color: var(--color-on-dark-muted); }
.hero .btn-group { margin-top: 0; }

/* ---------- Servicios ---------- */
.service-grid {
  --cols: 1;
  --grid-gap: var(--space-4);
  list-style: none;
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: var(--grid-gap);
}
@media (min-width: 40em) { .service-grid { --cols: 2; } }
@media (min-width: 64em) { .service-grid { --cols: 3; } }
@media (min-width: 75em) { .service-grid { --cols: 5; --grid-gap: var(--space-5); } }

.service-card {
  display: flex; flex-direction: column; align-items: flex-start;
  flex: 0 0 calc((100% - (var(--cols) - 1) * var(--grid-gap)) / var(--cols));
  padding: var(--space-5);
}
.service-card .card__title { font-size: 1.1875rem; }
.service-card .card__text { font-size: 0.9375rem; }
.service-card .card__link { margin-top: auto; padding-top: var(--space-2); }
.service-card__media {
  width: 100%; margin-top: var(--space-4);
  aspect-ratio: 5 / 3; object-fit: cover; border-radius: var(--radius-md);
}

/* ---------- Sobre nosotros ---------- */
.about { display: grid; gap: var(--space-6); align-items: center; }
@media (min-width: 48em) { .about { grid-template-columns: 5fr 6fr; gap: var(--space-7); } }
.about__brand {
  display: grid; place-items: center;
  padding: var(--space-7) var(--space-5);
  background: var(--color-navy); border-radius: var(--radius-lg);
}
.about__brand img { width: min(100%, 22rem); }
.about__figure { position: relative; margin: 0; overflow: hidden; border-radius: var(--radius-lg); }
.about__figure img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.about__text h2 { max-width: 20ch; }
.about__text .btn { margin-top: var(--space-5); }

/* ---------- Confianza ---------- */
.trust-grid { list-style: none; display: grid; gap: var(--space-5); grid-template-columns: 1fr; }
@media (min-width: 40em) { .trust-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 64em) { .trust-grid { grid-template-columns: repeat(4, 1fr); gap: 0; } }
.trust-item { text-align: center; padding-inline: var(--space-4); }
.trust-item__title { margin-bottom: var(--space-2); font-size: var(--fs-h4); }
.trust-item p { margin-inline: auto; max-width: 26ch; color: var(--color-text-muted); }
@media (min-width: 64em) { .trust-item + .trust-item { border-left: 1px solid var(--color-border); } }

/* ---------- Proceso ---------- */
.process-title { margin-bottom: var(--space-5); }
.process { display: grid; gap: var(--space-5); }
.steps { list-style: none; display: grid; gap: var(--space-5); grid-template-columns: 1fr; }
@media (min-width: 48em) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step { position: relative; }
.step__number {
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.5rem; height: 2.5rem; margin-bottom: var(--space-3);
  border-radius: 50%; background: var(--color-teal-deep); color: var(--color-white); font-weight: 700;
}
.step__title { margin-bottom: var(--space-1); font-size: var(--fs-h4); }
.step p { color: var(--color-text-muted); }
.process__media { margin: 0; overflow: hidden; border-radius: var(--radius-lg); }
.process__media img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
@media (min-width: 64em) {
  /* Sin relleno vertical en la sección: la foto llega de borde a borde (arriba y abajo) y el aire pasa al bloque de pasos */
  .section--process { padding-block: 0; }
  .process { gap: 0; }
  .process__main { padding-block: var(--space-6); }
  .process--media { grid-template-columns: 3fr 1fr; align-items: stretch; column-gap: var(--space-5); }
  .step:not(:last-child)::after {
    content: ""; position: absolute; top: 1.2rem; left: 3.25rem; right: var(--space-3);
    height: 2px; background: var(--color-border);
  }
  /* La foto ocupa el lugar del 4.º paso, con el borde izquierdo en diagonal */
  .process__media { position: relative; min-height: 13rem; border-radius: 0; clip-path: polygon(0 0, 100% 0, 100% 100%, 14% 100%); }
  .process__media img { position: absolute; inset: 0; height: 100%; aspect-ratio: auto; object-position: 45% center; }
}

/* ---------- Banda de contacto ---------- */
.cta-band {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: var(--space-5); padding: var(--space-5);
  background: var(--color-navy); color: var(--color-on-dark); border-radius: var(--radius-lg);
  --focus-ring: var(--color-turquoise);
}
@media (min-width: 48em) { .cta-band { padding: var(--space-6); } }
.cta-band__lead { display: flex; align-items: center; gap: var(--space-4); flex: 1 1 22rem; }
.cta-band__title { margin-bottom: var(--space-1); color: var(--color-on-dark); font-size: var(--fs-h3); }
.cta-band p { color: var(--color-on-dark-muted); }
