@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;800&family=Inter:wght@400;500;600&display=swap");

:root {
  /* Colors */
  --primary: rgb(236, 130, 0);
  --primary-dark: rgb(200, 110, 0);
  --primary-light: rgba(236, 130, 0, 0.1);
  --bg-dark: #0a0a0b;
  --bg-light: #ffffff;
  --bg-alt: #f8f9fc;
  --text-main: #1a1a2e;
  --text-muted: #6b7280;

  /* Glassmorphism */
  --glass-bg: rgba(255, 255, 255, 0.85);
  --glass-border: rgba(255, 255, 255, 0.3);

  /* Shadows */
  --shadow-sm: 0 4px 6px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.08);
  --shadow-primary: 0 10px 20px rgba(236, 130, 0, 0.25);

  /* Utilities */
  --radius-lg: 24px;
  --radius-md: 16px;
  --radius-sm: 8px;
  --transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);

  /* Fonts */
  --font-heading: 'Poppins', sans-serif;
  --font-body: 'Inter', sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
}

body {
  font-family: var(--font-body);
  color: var(--text-main);
  background-color: var(--bg-alt);
  /* The original bg image was fon.jpg, we will use it for the Hero instead to keep the rest clean */
  overflow-x: hidden;
  line-height: 1.6;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  color: var(--text-main);
}

.section-title {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 1rem;
  position: relative;
  display: inline-block;
  left: 50%;
  transform: translateX(-50%);
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background-color: var(--primary);
  border-radius: 2px;
}

.section-desc {
  text-align: center;
  color: var(--text-muted);
  max-width: 700px;
  margin: 0 auto 4rem auto;
  font-size: 1.1rem;
  font-weight: 400;
}

/* Button */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 32px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  color: #fff;
  background: var(--primary);
  border: none;
  border-radius: 50px;
  cursor: pointer;
  box-shadow: var(--shadow-primary);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--primary-dark);
  z-index: -1;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s ease;
  border-radius: 50px;
}

.btn-primary:hover::before {
  transform: scaleX(1);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 15px 25px rgba(236, 130, 0, 0.35);
}

/* Header & Nav */
header {
  position: fixed;
  top: 0;
  width: 100%;
  padding: 15px 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--glass-border);
  z-index: 1000;
  transition: var(--transition);
}

header.scrolled {
  padding: 10px 5%;
  box-shadow: var(--shadow-sm);
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo img {
  height: 50px;
  object-fit: contain;
}

.logo img:nth-child(2) {
  height: 35px;
}

.nav-menu {
  display: flex;
  gap: 30px;
}

.nav-menu a {
  font-family: var(--font-heading);
  font-weight: 500;
  font-size: 1rem;
  position: relative;
  padding: 5px 0;
}

.nav-menu a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0%;
  height: 2px;
  background: var(--primary);
  transition: var(--transition);
}

.nav-menu a:hover::after {
  width: 100%;
}

.nav-menu a:hover {
  color: var(--primary);
}

.menu-toggle {
  display: none;
  background: transparent;
  border: none;
  font-size: 1.5rem;
  color: var(--text-main);
  cursor: pointer;
}

/* Hero Section */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 120px 5% 0;
  background-image: url('../fondos/fon.jpg'), linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(248, 249, 252, 0.95));
  background-blend-mode: overlay;
  background-position: center;
  background-size: cover;
  background-attachment: fixed;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
}

.hero-tag {
  display: inline-block;
  padding: 8px 16px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 20px;
  letter-spacing: 1px;
}

.hero h1 {
  font-size: 4rem;
  margin-bottom: 20px;
  color: var(--text-main);
}

.hero h1 span {
  color: var(--primary);
}

.hero p {
  font-size: 1.25rem;
  color: var(--text-muted);
  margin-bottom: 40px;
  font-weight: 400;
}

.hero-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 32px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-main);
  background: transparent;
  border: 2px solid var(--text-main);
  border-radius: 50px;
  cursor: pointer;
  transition: var(--transition);
}

.btn-outline:hover {
  background: var(--text-main);
  color: #fff;
}

/* Sections Structure */
section {
  padding: 100px 5%;
}

.section-bg-white {
  background: var(--bg-light);
}

.section-bg-alt {
  background: var(--bg-alt);
}

/* Nosotros (Bento Grid Style) */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
}

.about-card {
  background: var(--bg-light);
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  border: 1px solid rgba(0, 0, 0, 0.03);
}

.about-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-5px);
}

.about-card.primary {
  background: var(--primary);
  color: #fff;
}

.about-card.primary h3 {
  color: #fff;
}

.about-card.primary .about-icon {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.about-card.full-width {
  grid-column: 1 / -1;
  text-align: center;
}

.about-icon {
  width: 60px;
  height: 60px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  margin-bottom: 20px;
}

.about-card h3 {
  font-size: 1.5rem;
  margin-bottom: 15px;
}

/* Productos Preview */
.products-preview {
  max-width: 1200px;
  margin: 0 auto;
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.product-card-sm {
  border-radius: var(--radius-md);
  overflow: hidden;
  position: relative;
  background: #fff;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.product-card-sm:hover {
  box-shadow: var(--shadow-primary);
  transform: translateY(-10px);
}

.product-img-wrap {
  width: 100%;
  height: 250px;
  overflow: hidden;
  position: relative;
  background-color: #f1f2f6;
  /* Soft back base */
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.product-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  filter: drop-shadow(0 10px 10px rgba(0, 0, 0, 0.1));
}

.product-card-sm:hover .product-img-wrap img {
  transform: scale(1.08);
}

.product-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
  display: flex;
  align-items: flex-end;
  padding: 20px;
  opacity: 0;
  transition: var(--transition);
}

.product-card-sm:hover .product-overlay {
  opacity: 1;
}

.product-overlay h3 {
  color: #fff;
  font-size: 1.5rem;
  margin: 0;
  transform: translateY(20px);
  transition: transform 0.4s ease;
}

.product-card-sm:hover .product-overlay h3 {
  transform: translateY(0);
}

/* ==========================================
   Product LOGO Cards  (reemplaza product-card-sm)
   ========================================== */
.product-logo-card {
  display: block;
  border-radius: var(--radius-lg);
  overflow: hidden;
  position: relative;
  background: #fff;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.07);
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  text-decoration: none;
  border: 1.5px solid rgba(0, 0, 0, 0.04);
}

.product-logo-card:hover {
  transform: translateY(-12px) scale(1.02);
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(236, 130, 0, 0.08);
}

.logo-card-inner {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 30px 30px;
  min-height: 280px;
  overflow: hidden;
}

/* Glow animado por marca */
.logo-card-glow {
  position: absolute;
  top: -40%;
  left: 50%;
  transform: translateX(-50%);
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--glow-color, rgba(236, 130, 0, 0.3)) 0%, transparent 70%);
  filter: blur(30px);
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
  z-index: 0;
}

.product-logo-card:hover .logo-card-glow {
  opacity: 1;
  animation: glow-pulse 2.5s ease-in-out infinite;
}

@keyframes glow-pulse {

  0%,
  100% {
    transform: translateX(-50%) scale(1);
    opacity: 0.8;
  }

  50% {
    transform: translateX(-50%) scale(1.2);
    opacity: 1;
  }
}

/* Contenedor de imagen del logo */
.logo-card-img-wrap {
  position: relative;
  z-index: 1;
  width: 160px;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  background: #fff;
  border-radius: var(--radius-md);
  padding: 16px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  animation: float-logo 4s ease-in-out infinite;
}

.logo-card-img-wrap.bytevance-wrap {
  width: 210px;
  height: 90px;
  background: #ffffff;
  border: 1.5px solid rgba(0, 210, 255, 0.15);
  padding: 12px 18px;
}

@keyframes float-logo {

  0%,
  100% {
    transform: translateY(0px);
  }

  50% {
    transform: translateY(-6px);
  }
}

.product-logo-card:hover .logo-card-img-wrap {
  animation: none;
  transform: translateY(-4px) scale(1.06);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.1);
}

.logo-card-img-wrap img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  filter: none;
  transition: filter 0.4s ease;
}

/* Shimmer effect al hover */
.logo-card-img-wrap::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(to right, transparent 0%, rgba(255, 255, 255, 0.7) 50%, transparent 100%);
  transform: skewX(-15deg);
  opacity: 0;
  transition: opacity 0.2s;
}

.product-logo-card:hover .logo-card-img-wrap::after {
  opacity: 1;
  animation: shimmer 0.8s ease forwards;
}

@keyframes shimmer {
  0% {
    left: -100%;
    opacity: 1;
  }

  100% {
    left: 150%;
    opacity: 1;
  }
}

/* Texto de info */
.logo-card-info {
  position: relative;
  z-index: 1;
  text-align: center;
  flex: 1;
}

.logo-card-label {
  display: block;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--text-main);
  margin-bottom: 6px;
  transition: color 0.3s ease;
}

.product-logo-card:hover .logo-card-label {
  color: var(--primary);
}

.logo-card-sub {
  display: block;
  font-size: 0.82rem;
  color: var(--text-muted);
  font-weight: 400;
  letter-spacing: 0.3px;
}

/* Flecha animada */
.logo-card-arrow {
  position: absolute;
  bottom: 20px;
  right: 20px;
  z-index: 1;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  opacity: 0;
  transform: translateX(-8px);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.product-logo-card:hover .logo-card-arrow {
  opacity: 1;
  transform: translateX(0);
  background: var(--primary);
  color: #fff;
}

/* Línea decorativa de entrada */
.product-logo-card::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0%;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--primary-dark));
  transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  border-radius: 0 0 0 var(--radius-lg);
  z-index: 10;
}

.product-logo-card:hover::before {
  width: 100%;
}

/* Asegurar que products-grid mantenga buen spacing */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

/* ==========================================
   Servicios */
.servi-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
}

.service-tier {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 40px 30px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  position: relative;
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(0, 0, 0, 0.05);
}

.service-tier:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary-light);
}

.service-tier.featured {
  border: 2px solid var(--primary);
  transform: scale(1.05);
  box-shadow: var(--shadow-primary);
  z-index: 2;
}

.service-tier.featured:hover {
  transform: scale(1.05) translateY(-10px);
}

.badge-featured {
  position: absolute;
  top: -15px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary);
  color: #fff;
  padding: 5px 15px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 1px;
}

.service-tier h3 {
  text-align: center;
  font-size: 1.5rem;
  margin-bottom: 25px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.service-features {
  list-style: none;
  margin-bottom: 30px;
  flex-grow: 1;
}

.service-features li {
  position: relative;
  padding-left: 30px;
  margin-bottom: 15px;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.service-features li::before {
  content: '\f00c';
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  position: absolute;
  left: 0;
  top: 2px;
  color: var(--primary);
}

.service-tier.featured .service-features li::before {
  color: var(--primary);
}

.service-features li.disabled {
  color: #ccc;
  text-decoration: line-through;
}

.service-features li.disabled::before {
  content: '\f00d';
  color: #ccc;
}

.btn-service {
  width: 100%;
  padding: 12px;
  border-radius: var(--radius-sm);
  background: var(--bg-alt);
  color: var(--text-main);
  font-weight: 600;
  text-align: center;
  transition: var(--transition);
}

.service-tier:hover .btn-service,
.service-tier.featured .btn-service {
  background: var(--primary);
  color: #fff;
}

/* Banner CTA (Mantenimiento) */
.mantenimiento-cta {
  background: linear-gradient(135deg, var(--bg-dark), #1a1a2e);
  border-radius: var(--radius-lg);
  padding: 60px;
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
  color: #fff;
  position: relative;
  overflow: hidden;
}

.mantenimiento-cta::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(236, 130, 0, 0.1) 0%, transparent 60%);
  animation: rotar 20s linear infinite;
  z-index: 0;
}

@keyframes rotar {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

.mantenimiento-cta h2,
.mantenimiento-cta p,
.mantenimiento-cta .btn-primary {
  position: relative;
  z-index: 1;
}

.mantenimiento-cta h2 {
  color: #fff;
  font-size: 2.2rem;
  margin-bottom: 20px;
}

.mantenimiento-cta p {
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.1rem;
  max-width: 700px;
  margin: 0 auto 30px auto;
}

/* Logos Slider */
.slider-section {
  padding: 40px 0;
  background: #fff;
  border-top: 1px solid var(--glass-border);
}

.slider-title {
  text-align: center;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--text-muted);
  margin-bottom: 30px;
}

.slider {
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
  overflow: hidden;
}

.slider::before,
.slider::after {
  content: "";
  height: 100%;
  width: 100px;
  position: absolute;
  top: 0;
  z-index: 2;
}

.slider::before {
  left: 0;
  background: linear-gradient(to right, #fff 0%, rgba(255, 255, 255, 0) 100%);
}

.slider::after {
  right: 0;
  background: linear-gradient(to left, #fff 0%, rgba(255, 255, 255, 0) 100%);
}

.slide-track {
  display: flex;
  width: calc(280px * 12);
  animation: scroll 30s linear infinite;
  align-items: center;
}

.slide {
  width: 280px;
  padding: 0 30px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Slide con fondo oscuro (para logos blancos como Bytevance) */
.slide-dark {
  padding: 0 20px;
}

.slide-dark .slide-pill {
  background: #0d1e35;
  border-radius: 10px;
  padding: 8px 18px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.slide-dark .slide-pill:hover {
  background: #112843;
}

.slide img {
  width: 100%;
  max-height: 55px;
  object-fit: contain;
  filter: grayscale(100%) opacity(0.55);
  transition: var(--transition);
}

.slide-dark img {
  max-height: 58px;
  max-width: 200px;
  filter: none;
}

.slide:hover img,
.slide-dark:hover img {
  filter: grayscale(0%) opacity(1);
  transform: scale(1.08);
}

@keyframes scroll {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(calc(-280px * 6));
  }
}


/* Footer */
footer {
  background: var(--bg-dark);
  color: #fff;
  padding: 80px 5% 40px;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 50px;
}

.footer-brand p {
  color: var(--text-muted);
  margin: 20px 0;
  font-size: 0.95rem;
  max-width: 350px;
}

.media-icons {
  display: flex;
  gap: 15px;
}

.media-icons a {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  transition: var(--transition);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.media-icons a:hover {
  background: var(--primary);
  border-color: var(--primary);
  transform: translateY(-3px);
}

.footer-box h3 {
  font-size: 1.2rem;
  margin-bottom: 25px;
  position: relative;
  display: inline-block;
}

.footer-box h3::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 30px;
  height: 2px;
  background: var(--primary);
}

.footer-box ul {
  list-style: none;
}

.footer-box ul li {
  margin-bottom: 12px;
}

.footer-box ul li a {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.footer-box ul li a:hover {
  color: var(--primary);
  padding-left: 5px;
}

.footer-bottom {
  max-width: 1200px;
  margin: 50px auto 0;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Responsiveness */
@media (max-width: 1024px) {
  .hero h1 {
    font-size: 3.5rem;
  }

  .servi-container {
    grid-template-columns: repeat(2, 1fr);
  }

  .service-tier.featured {
    transform: scale(1);
  }

  .service-tier.featured:hover {
    transform: translateY(-10px);
  }
}

@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.8rem;
  }

  .about-grid {
    grid-template-columns: 1fr;
  }

  .servi-container {
    grid-template-columns: 1fr;
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 40px;
    text-align: center;
  }

  .footer-brand p {
    margin: 20px auto;
  }

  .media-icons {
    justify-content: center;
  }

  .footer-box h3::after {
    left: 50%;
    transform: translateX(-50%);
  }

  .menu-toggle {
    display: block;
  }

  .nav-menu {
    position: fixed;
    top: 75px;
    left: -100%;
    width: 100%;
    height: calc(100vh - 75px);
    background: var(--bg-light);
    flex-direction: column;
    align-items: center;
    padding-top: 40px;
    transition: 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  }

  .nav-menu.active {
    left: 0;
  }

  .nav-menu a {
    font-size: 1.2rem;
    padding: 15px;
  }

  .mantenimiento-cta {
    padding: 40px 20px;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 2.2rem;
  }

  .hero-buttons {
    flex-direction: column;
  }

  .btn-primary,
  .btn-outline {
    width: 100%;
  }
}