* {
  box-sizing: border-box;
}

body, html {
  margin: 0;
  padding: 0;
  font-family: 'Segoe UI', sans-serif;
  width: 100%;
  min-height: 100%;
}

main {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.seccion {
  flex: 1;
  padding: 3rem 1rem;
  background: linear-gradient(to right, rgba(13, 110, 253, 0.25), #ffffff);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.titulo-logo img.logo-img {
  max-width: 200px;
}

.descripcion {
  font-size: 1.3rem;
  color: #333;
  margin-top: 1rem;
  margin-bottom: 3rem;
}

.tarjetas-servicio {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem;
  margin-bottom: 2rem;
}

.card-flip {
  background: #fff;
  border-radius: 15px;
  perspective: 1000px;
  width: 300px;
  height: 320px;
}

.card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.8s;
  transform-style: preserve-3d;
}

.card-flip:hover .card-inner {
  transform: rotateY(180deg);
}

.card-front, .card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 15px;
  backface-visibility: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 1rem;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.card-front {
  background-color: #ffffff;
  color: #000;
}

.card-back {
  background-size: cover;
  background-position: center;
  color: #fff;
  transform: rotateY(180deg);
  background-blend-mode: overlay;
  background-color: rgba(0, 0, 0, 0.5);
}

.card-back p {
  padding: 1rem;
  background: rgba(0, 0, 0, 0.6);
  border-radius: 10px;
}

.card-flip:nth-child(1) .card-back {
  background-image: url('img/mantenimiento.jpg');
}

.card-flip:nth-child(2) .card-back {
  background-image: url('img/desarrollo.jpg');
}

.card-flip:nth-child(3) .card-back {
  background-image: url('img/proyectos.jpg');
}

.card-flip:nth-child(4) .card-back {
  background-image: url('img/seguridad.jpg');
}

.btn-wsp {
  background-color: #25D366;
  color: white;
  padding: 0.75rem 2rem;
  border-radius: 50px;
  font-weight: bold;
  text-decoration: none;
  transition: background 0.3s ease;
}

.btn-wsp:hover {
  background-color: #1ebe5d;
}

.wsp-float {
  display: none;
}

footer {
  background-color: #19397c;
  color: white;
  text-align: center;
  padding: 1rem;
  font-size: 0.9rem;
}

@media (max-width: 768px) {
  .tarjetas-servicio {
    flex-direction: column;
    align-items: center;
  }

  .wsp-float {
    display: flex;
    align-items: center;
    justify-content: center;
    position: fixed;
    bottom: 1rem;
    right: 1rem;
    background-color: #25D366;
    color: white;
    font-weight: bold;
    padding: 0.7rem 1.2rem;
    border-radius: 50px;
    text-decoration: none;
    z-index: 1000;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
  }

  .wsp-float i {
    margin-right: 0.5rem;
  }
}
