/* ====== ESTILOS GENERALES ====== */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background-color: #fff;
  color: #444;
  max-width: 1920px;
  margin: 0 auto; /* centra el contenido */
  overflow-x: hidden; /* evita scroll horizontal si algo se sale */
}

/* ====== IMPORTAR TIPOGRAFÍA ROBOTO ====== */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500;700;900&display=swap');

/* SECCION_HERO */

.hero {
  position: relative;
  min-height: 630px;
  background-image: url("images/Banner principal.webp");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
   background-color: #E1E1E1;
}

/* Oscurece ligeramente para que el texto se lea mejor */
.hero-overlay {
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    rgba(0,0,0,0.75) 0%,
    rgba(0,0,0,0.55) 45%,
    rgba(0,0,0,0.15) 100%
  );
  display: flex;
  align-items: center;
}

.hero-content {
max-width: 1200px;
  padding-left: 8%;
  color: #ffffff;
}

.hero h1 {
  font-size: clamp(2.3rem, 4vw, 3.3rem);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1.6rem;
  text-transform: uppercase;
}

.hero p {
  font-size: 24px;
  line-height: 1.6;
  color: #e0e0e0;
  background: rgba(255, 255, 255, 0.05);
  padding: 1.2rem 1.4rem;
  border-left: 4px solid #ff0000;
  backdrop-filter: blur(4px);
  max-width: 700px;
}

.highlight {
  color: #ff0000;
  font-weight: 700;
}


/* ===== CSS: SECCIÓN SERVICIOS ===== */
.servicios-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 40px;
  max-width: 1920px;
  margin: auto;
  background: #E1E1E1;
}

.imagen-box img {
  width: auto;
  height: 410px;
  border-radius: 12px;
  object-fit: contain;
  box-shadow: 0 10px 30px rgba(0,0,0,0.15);
  max-width: 600px;
  margin-left: 230px;
}


.contenido-box { position: relative; }

.titulo-box {
  background: white;
  border: 1px solid #ff3b3b;
  padding: 25px 30px;
  margin-bottom: 40px;
  margin-left: 170px;
  max-width: 520px;
  height: 120px;
}

.titulo-box p {
  margin: 0;
  font-size: 20px;
  line-height: 1.4;
  color: #4b4b4b;
}

.titulo-box strong { color:#2b2b2b; }

.iconos {
  display: flex;
  align-items: center;
  gap: 120px;
  justify-content: center;
}

.icono {
  width: 97px;
  height: 86px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.icono img { 
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain; /* clave para no deformar */
}

.icono:hover, .icono.activo {
  transform: scale(1.5);
}

.descripcion {
  margin-top: 25px;
  text-align: center;
  font-size: 17px;
  color: #666;
  min-height: 60px;
}

@media(max-width:900px){
  .servicios-section { grid-template-columns: 1fr; text-align:center; }
  .titulo-box { margin: 0 auto 30px; }
}

/* ================================
   SECCION_DIAGNOSTICO
================================ */

/* CONTENEDOR PRINCIPAL */
.diagnostico-section {
  display: flex;
  gap: 60px;
  padding: 140px 0px 30px 0;
  align-items: center;
  max-width: 1200px;
  margin: auto;
}

/* ================================
   LADO IZQUIERDO
================================ */
.diag-left {
  position: relative;
  width: 50%;
}

/* IMAGEN PRINCIPAL */
.diag-main {
  width: 380px;
  height: 380px;
  transform: rotate(45deg);
  overflow: hidden;
}

.diag-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: rotate(-45deg) scale(1.2);
  transition: opacity 0.6s ease;
}

/* ================================
   MINIATURAS (ROMBOS)
================================ */
.diag-thumbs {
  position: absolute;
  top: -85px;
  left: -150px;
  display: grid;
  grid-template-columns: repeat(2, 90px);
  gap: 12px;

  /* rotación general del grupo */
  transform: rotate(-45deg) scale(1.2);
}

/* ROMBO */
.diag-thumb {
  width: 90px;
  height: 90px;

  cursor: pointer;

  /* CLAVE: compensar la rotación del contenedor */
  transform: rotate(45deg) scale(1.35);

  object-fit: cover;
  transition: transform 0.4s ease, border-color 0.4s ease;
}

/* ACTIVO (sin romper rotación) */
.diag-thumb.active {
  border-color: #ff2d2d;
  transform: rotate(45deg) scale(1.45);
}

/* ================================
   LADO DERECHO
================================ */
.diag-right {
  width: 90%;
  position: sticky;
  top: 120px;
}

.diag-right h2 {
  background: #ff2d2d;
  color: #fff;
  padding: 12px 130px;
  display: inline-block;
  font-size: 40px;
}

.diag-right p {
  margin-top: 24px;
  font-size: 22px;
  line-height: 1.6;
  color: #555;
  text-align: right;
}

/* ================================
   ICONOS
================================ */
.diag-icons {
  margin-top: 32px;
  display: flex;
  gap: 30px;
}

.diag-icon {
  width: 200px;
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: diagFloat 3s ease-in-out infinite;
}

.diag-icon:nth-child(2) { animation-delay: 0.4s; }
.diag-icon:nth-child(3) { animation-delay: 0.8s; }

.diag-icon img {
  width: 100px;
  height: 100px;
  object-fit: contain;
}

/* FLOAT ICONOS */
@keyframes diagFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

/* =========================
   SECCIÓN EXPERTOS
========================= */

.expertise-section {
  position: relative;
  min-height: 100vh;
  background: url("images/Fondo-negro-(sección-clinica-y-restaurante).jpg") center center / cover no-repeat;
  color: #fff;
  overflow: hidden;
  align-content: center;
}

/* Overlay */
.expertise-section .overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

/* Elevar contenido sobre el overlay */
.expertise-section > *:not(.overlay) {
  position: relative;
  z-index: 2;
}

/* Título */
.section-title {
  text-align: center;
  font-size: 32px;
  margin-bottom: 60px;
  letter-spacing: 1px;
}

.section-title span {
  color: #ff2b2b;
}

/* Contenedor de tarjetas */
.cards-container {
  display: flex;
  justify-content: center;
  gap: 60px;
  flex-wrap: wrap;
}

/* Card */
.card {
  width: 480px;
  max-width: 100%;
}

/* Slider */
.slider {
  position: relative;
  width: 100%;
  height: 260px;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
}

.slider img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.8s ease;
}

.slider img.active {
  opacity: 1;
}

/* Contenido */
.card-content {
  margin-top: 25px;
}

.badge {
  display: inline-block;
  background: #ff2b2b;
  padding: 10px 18px;
  font-weight: bold;
  border-radius: 6px;
  margin-bottom: 12px;
}

.card-content p {
  font-size: 15px;
  line-height: 1.6;
  color: #e0e0e0;
}

/* SECCION_MONITOR */

.dierza-section {
  position: relative;
  width: 100%;
  min-height: 880px;
  background-image: url("images/fondo-monitor.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  overflow: hidden;
}

/* ===== Imágenes flotantes ===== */
.floating-img {
  position: absolute;
  width: 325px;
  height: auto;
  border-radius: 10px;
}

/* Superior derecha */
.img-top {
  top: 20px;
  right: 325px;
}

/* Inferior izquierda */
.img-bottom {
  bottom: 165px;
  left: 325px;
}

/* ===== Textos ===== */
.overlay-text {
  position: absolute;
  max-width: 570px;
  font-size: 21px;
  line-height: 1.5;
  color: #000;
  padding:48px;
}

/* Palabras destacadas */
.overlay-text span {
  color: #e10600;
  font-weight: bold;
}

/* Posiciones del texto */

.text-1 {
  top: 150px;
  left: 80px;
  background-image: url("images/Ventana-1.png");
}

.text-2 {
  bottom: 160px;
  right: 80px;
  background-image: url("images/Ventana-1.png");
}

/* ===== Animación Scroll ===== */

.animate-on-scroll {
  opacity: 0;
  transform: translateY(60px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.animate-on-scroll.show {
  opacity: 1;
  transform: translateY(0);
}

/* Variaciones opcionales */
.fade-left {
  transform: translateX(-60px);
}

.fade-right {
  transform: translateX(60px);
}

.fade-left.show,
.fade-right.show {
  transform: translateX(0);
}

/* =========================
   CONTROL VISIBILIDAD
========================= */

/* Por defecto: mostrar desktop */
.dierza-section {
  display: block;
}

.dierza-section-mobile {
  display: none;
}


/* =========================
   MOBILE DESIGN
========================= */

.dierza-section-mobile {
  padding: 60px 20px;
  background: #f5f5f5;
}

.dierza-mobile-container {
  max-width: 500px;
  margin: auto;
  display: flex;
  flex-direction: column;
  gap: 30px;
}

/* BLOQUES */
.mobile-block {
  display: flex;
  flex-direction: column;
  gap: 15px;

  opacity: 0;
  transform: translateY(40px);
  transition: all 0.7s ease;
}

/* cuando aparece */
.mobile-block.show {
  opacity: 1;
  transform: translateY(0);
}

/* delay escalonado */
.mobile-block:nth-child(1){ transition-delay: 0.1s; }
.mobile-block:nth-child(2){ transition-delay: 0.2s; }
.mobile-block:nth-child(3){ transition-delay: 0.3s; }
.mobile-block:nth-child(4){ transition-delay: 0.4s; }

/* IMAGEN */
.mobile-img {
  width: 100%;
  border-radius: 16px;
  object-fit: cover;
  box-shadow: 0 10px 25px rgba(0,0,0,0.1);

  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

/* hover imagen */
.mobile-img:hover {
  transform: scale(1.03);
  box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}

/* TEXTO */
.mobile-text {
  font-size: 16px;
  line-height: 1.6;
  background: #fff;
  padding: 20px;
  border-radius: 14px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.05);
  position: relative;

  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* hover texto */
.mobile-text:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 25px rgba(0,0,0,0.1);
}

/* BARRA ROJA */
.mobile-text::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 5px;
  height: 100%;
  background: #e10600;
  border-radius: 14px 0 0 14px;
}

/* TEXTO DESTACADO */
.mobile-text span {
  color: #e10600;
  font-weight: bold;
}

/* ANIMACIÓN */
@keyframes fadeUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}



/* =========================
   ACTIVACIÓN RESPONSIVE 🔥
========================= */

@media (max-width: 767px) {

  /* Oculta desktop */
  .dierza-section {
    display: none;
  }

  /* Muestra versión mobile */
  .dierza-section-mobile {
    display: block;
  }
}

/* ===== SECCION CTA INGENIERO ===== */

.cta-dierza {
  width: 100%;
  padding: 0px 0;
  background-image: url("images/Fondo-parte-final.jpg"); /* TU IMAGEN COMPLETA */
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.cta-container {
  width: 90%;
  max-width: 1500px;
  margin: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 60px;
}

/* Columna izquierda */
/* Contenedor icono + texto */
.cta-text-wrapper {
  display: flex;
  align-items: center;
  gap: 25px;
  margin-bottom: 50px;
}
.cta-content {
  flex: 1;
  color: #fff;
}

.cta-icon {
  width: 140px;
  flex-shrink: 0;
  margin-top: 5px; /* ajuste fino vertical */
}
/* Texto */
.cta-text {
  font-size: 22px;
  line-height: 1.6;
  margin: 0;
  color: #fff;
}

.cta-text strong {
  font-weight: 700;
}



/* Botón */
.cta-btn {
  display: inline-block;
  background: #ff2d2d;
  color: #fff;
  text-decoration: none;
  padding: 35px 50px;
  border-radius: 25px;
  max-width: 630px;
  transition: 0.3s ease;
  text-align: center !important;
}

.cta-btn:hover {
  background: #e10600;
  transform: translateY(-5px);
}

.cta-title {
  display: block;
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 10px;
  text-align: center;
}

.cta-subtitle1 {
  font-size: 28px;
  font-weight: 600;
}

/* Imagen derecha */
.cta-image {
  flex: 1;
  text-align: center;
}

.cta-image img {
  width: 520px;
  max-width: 100%;
  display: block;
  margin: -60px 0px 60px 60px;
}


/* =========================================
   RESPONSIVE TABLET Y MÓVIL
   (sin modificar escritorio)
========================================= */

/* =========================
   TABLET
========================= */
@media (max-width: 1024px) {

  /* HERO */
  .hero {
    min-height: 520px;
    background-position: center;
  }

  .hero-content {
    padding: 60px 40px;
    max-width: 100%;
  }

  .hero h1 {
    font-size: clamp(2rem, 4vw, 2.8rem);
  }

  .hero p {
    font-size: 20px;
    max-width: 100%;
  }

  /* SERVICIOS */
  .servicios-section {
    grid-template-columns: 1fr;
    gap: 30px;
    padding: 50px 30px;
  }

  .imagen-box {
    text-align: center;
  }

  .imagen-box img {
    margin: 0 auto;
    max-width: 100%;
    max-height: 420px;
  }

  .contenido-box {
    width: 100%;
  }

  .titulo-box {
    margin: 0 auto 30px auto;
    max-width: 100%;
  }

  .iconos {
    gap: 60px;
    flex-wrap: wrap;
  }

  .icono:hover,
  .icono.activo {
    transform: scale(1.25);
  }

  .descripcion {
    padding: 0 20px;
  }

  /* DIAGNOSTICO */
  .diagnostico-section {
    flex-direction: column;
    gap: 40px;
    padding: 90px 30px 40px;
    max-width: 100%;
  }

  .diag-left,
  .diag-right {
    width: 100%;
  }

  .diag-left {
    display: flex;
    justify-content: center;
    align-items: center;
  }

  .diag-main {
    width: 300px;
    height: 300px;
    margin: 40px auto 0;
  }

  .diag-thumbs {
    top: -50px;
    left: 20px;
    grid-template-columns: repeat(2, 70px);
    gap: 10px;
    transform: rotate(-45deg) scale(1);
  }

  .diag-thumb {
    width: 70px;
    height: 70px;
    transform: rotate(45deg) scale(1.15);
  }

  .diag-thumb.active {
    transform: rotate(45deg) scale(1.22);
  }

  .diag-right {
    position: static;
    top: auto;
    text-align: center;
  }

  .diag-right h2 {
    padding: 12px 40px;
    font-size: 32px;
  }

  .diag-right p {
    font-size: 20px;
    text-align: center;
  }

  .diag-icons {
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
  }

  .diag-icon {
    width: 140px;
    height: 140px;
  }

  .diag-icon img {
    width: 75px;
    height: 75px;
  }

  /* EXPERTISE */
  .expertise-section {
    min-height: auto;
    padding: 80px 30px;
  }

  .section-title {
    font-size: 28px;
    margin-bottom: 40px;
  }

  .cards-container {
    gap: 35px;
  }

  .card {
    width: 100%;
    max-width: 700px;
  }

  .slider {
    height: 240px;
  }

  

  /* CTA */
  .cta-container {
    flex-direction: column;
    gap: 30px;
    padding: 60px 20px;
    text-align: center;
  }

  .cta-text-wrapper {
    flex-direction: column;
    gap: 20px;
    margin-bottom: 30px;
  }

  .cta-icon {
    width: 110px;
    margin-top: 0;
  }

  .cta-text {
    font-size: 20px;
  }

  .cta-btn {
    padding: 24px 30px;
    max-width: 100%;
  }

  .cta-title {
    font-size: 28px;
  }

  .cta-subtitle1 {
    font-size: 22px;
  }

  .cta-image img {
    width: 380px;
    margin: 0 auto;
  }
}


/* =========================
📱 MÓVIL (hasta 767px)
========================= */
@media (max-width: 767px) {

  body {
    overflow-x: hidden;
  }

  /* ===== HERO ===== */
  .hero {
    min-height: 480px;
  }

  .hero-overlay {
    background: linear-gradient(
      180deg,
      rgba(0,0,0,0.78) 0%,
      rgba(0,0,0,0.55) 60%,
      rgba(0,0,0,0.30) 100%
    );
  }

  .hero-content {
    padding: 40px 20px;
  }

  .hero h1 {
    font-size: clamp(1.7rem, 7vw, 2.3rem);
    line-height: 1.2;
    margin-bottom: 1rem;
  }

  .hero p {
    font-size: 16px;
    line-height: 1.5;
    padding: 1rem;
  }

  /* ===== SERVICIOS ===== */
  .servicios-section {
    padding: 40px 20px;
    gap: 25px;
  }

  .imagen-box img {
    height: 255px;
	width: auto;
    object-fit: contain;
  }

  .titulo-box {
    padding: 18px 20px;
	height: 100px;
  }

  .titulo-box p {
    font-size: 17px;
  }

  .iconos {
    gap: 25px;
  }

  .icono {
    width: 48px;
    height: 48px;
  }

  .icono img {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
  }

  .descripcion {
    font-size: 15px;
    min-height: auto;
    padding: 0 10px;
  }

  /* ===== DIAGNÓSTICO ===== */
  .diagnostico-section {
    padding: 70px 20px 30px;
    gap: 30px;
  }

  .diag-main {
    width: 220px;
    height: 220px;
    margin-top: 50px;
  }

  .diag-thumbs {
    top: -38px;
    left: 0;
    grid-template-columns: repeat(2, 52px);
    gap: 8px;
    transform: rotate(-45deg);
  }

  .diag-thumb {
    width: 52px;
    height: 52px;
    transform: rotate(45deg) scale(1.08);
  }

  .diag-thumb.active {
    transform: rotate(45deg) scale(1.14);
  }

  .diag-right h2 {
    font-size: 24px;
    padding: 10px 20px;
  }

  .diag-right p {
    font-size: 16px;
    line-height: 1.6;
    margin-top: 18px;
  }

  .diag-icons {
    gap: 12px;
  }

  .diag-icon {
    width: 90px;
    height: 90px;
  }

  .diag-icon img {
    width: 48px;
    height: 48px;
  }

  /* ===== EXPERTISE ===== */
  .expertise-section {
    padding: 60px 20px;
  }

  .section-title {
    font-size: 23px;
    margin-bottom: 30px;
  }

  .slider {
    height: 200px;
    border-radius: 14px;
  }

  .badge {
    font-size: 14px;
    padding: 8px 14px;
  }

  .card-content p {
    font-size: 14px;
  }


/* MONITOR */
  
  /* ===== CTA ===== */
  .cta-container {
    padding: 45px 15px;
    gap: 25px;
  }

  .cta-icon {
    width: 85px;
  }

  .cta-text {
    font-size: 16px;
    line-height: 1.6;
  }

  .cta-btn {
    padding: 18px;
    border-radius: 18px;
    width: 100%;
  }

  .cta-title {
    font-size: 22px;
    margin-bottom: 8px;
  }

  .cta-subtitle1 {
    font-size: 17px;
  }

  .cta-image img {
    width: 100%;
    max-width: 280px;
  }
}


/* =========================
🎯 HOVER (fuera de media query)
========================= */
.icono:hover,
.icono.activo {
  transform: scale(1.1);
}

