/* Servitechni - CSS Común basado en Next.js + Tailwind */

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

html {
  scroll-behavior: smooth;
  margin: 0;
  padding: 0;
  width: 100%;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  color: oklch(0.15 0 0);
  background: oklch(0.99 0 0);
  -webkit-font-smoothing: antialiased;
  margin: 0;
  padding: 0;
  width: 100%;
  overflow-x: hidden;
}

/* Container - Igual que Tailwind */
.container {
  width: 100%;
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1rem;
  padding-right: 1rem;
}

/* Header - Sticky con backdrop blur */
header {
  position: sticky;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  width: 100%;
  border-bottom: 1px solid oklch(0.90 0 0);
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
  margin: 0;
  padding: 0;
}

header .container {
  display: flex;
  height: 7rem;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

/* Logo - IMPORTANTE: Tamaño ajustado para mejor visualización */
.logo-link {
  flex-shrink: 0;
  display: block;
  line-height: 0;
}

.logo-image,
header .logo-image,
.logo-link .logo-image {
  height: 6rem !important;
  width: auto !important;
  max-height: 6rem !important;
  object-fit: contain !important;
  display: block;
}

/* Navigation */
.nav-menu {
  display: none;
  list-style: none;
  align-items: center;
  gap: 0;
  margin: 0;
  flex: 1;
  justify-content: center;
}

@media (min-width: 1024px) {
  .nav-menu {
    display: flex;
  }
}

.nav-menu > li {
  position: relative;
}

.nav-menu > li > a {
  display: inline-flex;
  height: 2.5rem;
  align-items: center;
  justify-content: center;
  border-radius: 0.375rem;
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: oklch(0.15 0 0);
  text-decoration: none;
  transition: all 0.2s;
  white-space: nowrap;
}

.nav-menu > li > a:hover {
  background: oklch(0.96 0.02 210);
  color: oklch(0.15 0 0);
}

/* Dropdown */
.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  width: 400px;
  background: white;
  border: 1px solid oklch(0.90 0 0);
  border-radius: 0.5rem;
  padding: 1rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.2s;
  z-index: 100;
}

.nav-dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-menu li {
  list-style: none;
}

.dropdown-menu a {
  display: block;
  padding: 0.75rem;
  border-radius: 0.375rem;
  text-decoration: none;
  transition: all 0.2s;
}

.dropdown-menu a:hover {
  background: oklch(0.96 0.02 210);
}

.dropdown-title {
  font-size: 0.875rem;
  font-weight: 500;
  color: oklch(0.15 0 0);
  white-space: nowrap;
}

.dropdown-desc {
  margin-top: 0.25rem;
  font-size: 0.875rem;
  color: oklch(0.52 0 0);
  line-height: 1.25rem;
}

/* CTA Button Container */
.nav-cta-container {
  display: none;
  flex-shrink: 0;
}

@media (min-width: 1024px) {
  .nav-cta-container {
    display: flex;
    align-items: center;
  }
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 0.75rem 2rem;
  border-radius: 0.375rem;
  font-size: 1.125rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s;
  cursor: pointer;
}

.btn-primary {
  background: white;
  color: oklch(0.45 0.15 210);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.btn-primary:hover {
  background: oklch(0.985 0 0);
}

.btn-outline {
  background: transparent;
  color: white;
  border: 2px solid white;
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.1);
}

/* CTA Button */
.btn-cta {
  display: inline-flex !important;
  height: 2.5rem;
  align-items: center;
  justify-content: center;
  border-radius: 0.375rem;
  background: oklch(0.45 0.15 210);
  padding: 0.5rem 1.5rem !important;
  font-size: 0.875rem;
  font-weight: 500;
  color: white !important;
  text-decoration: none;
  transition: all 0.2s;
  line-height: 1;
}

.btn-cta:hover {
  background: oklch(0.40 0.15 210);
  color: white !important;
}

/* Asegurar color blanco en el botón CTA dentro del nav */
.nav-cta .btn-cta {
  color: white !important;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
  display: flex;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  flex-shrink: 0;
}

@media (min-width: 1024px) {
  .mobile-menu-toggle {
    display: none;
  }
}

.menu-icon {
  width: 24px;
  height: 24px;
}

/* Sections */
section {
  padding: 4rem 0;
}

h2 {
  text-align: center;
  font-size: 1.875rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

@media (min-width: 1024px) {
  h2 {
    font-size: 2.25rem;
  }
}

.section-subtitle {
  text-align: center;
  font-size: 1.125rem;
  color: oklch(0.52 0 0);
  max-width: 42rem;
  margin: 0 auto 3rem;
}

/* Backgrounds */
.bg-white {
  background: white;
}

.bg-slate {
  background: oklch(0.985 0 0);
}

.bg-slate-50 {
  background: oklch(0.985 0 0);
}

/* Grid */
.grid {
  display: grid;
  gap: 1.5rem;
}

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

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

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

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

@media (min-width: 768px) {
  .grid-2 {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid-6 {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1024px) {
  .grid-2 {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
  }
  .grid-4 {
    grid-template-columns: repeat(4, 1fr);
  }
  .grid-6 {
    grid-template-columns: repeat(6, 1fr);
  }
}

/* Cards */
.card {
  background: white;
  border: 2px solid oklch(0.90 0 0);
  border-radius: 0.5rem;
  padding: 1.5rem;
  text-align: center;
  transition: all 0.3s;
}

.card:hover {
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.card-icon {
  width: 3.5rem;
  height: 3.5rem;
  margin: 0 auto 1rem;
  color: oklch(0.45 0.15 210);
  stroke-width: 2;
}

.card h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.card p {
  color: oklch(0.52 0 0);
}

.card-link {
  display: inline-block;
  margin-top: 1rem;
  color: oklch(0.45 0.15 210);
  font-weight: 500;
  text-decoration: none;
}

.card-link:hover {
  text-decoration: underline;
}

/* Footer */
footer {
  position: relative;
  background: rgb(15, 23, 42);
  color: white;
  padding: 3rem 0 1rem;
  z-index: 50;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .footer-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.footer-section {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Footer Logo - IMPORTANTE: Tamaño ajustado para mejor visualización */
.footer-logo,
footer .footer-logo,
.footer-section .footer-logo {
  height: 5rem !important;
  width: auto !important;
  max-height: 5rem !important;
  object-fit: contain !important;
  display: block;
  margin-bottom: 0.5rem;
}

.footer-section h4 {
  color: white;
  font-weight: 600;
  font-size: 1.125rem;
  margin-bottom: 1rem;
}

.footer-section p {
  font-size: 0.875rem;
  color: oklch(0.708 0 0);
  line-height: 1.5;
}

.social-links {
  display: flex;
  gap: 1rem;
  margin-top: 0.5rem;
}

.social-links a {
  color: oklch(0.708 0 0);
  transition: color 0.2s;
}

.social-links a:hover {
  color: oklch(0.55 0.15 210);
}

.social-icon {
  width: 1.25rem;
  height: 1.25rem;
}

.footer-section ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-section li {
  margin-bottom: 0;
}

.footer-section a {
  color: oklch(0.708 0 0);
  text-decoration: none;
  font-size: 0.875rem;
  transition: color 0.2s;
}

.footer-section a:hover {
  color: oklch(0.55 0.15 210);
}

.contact-item {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.contact-icon {
  width: 1.25rem;
  height: 1.25rem;
  flex-shrink: 0;
  margin-top: 0.125rem;
  color: oklch(0.708 0 0);
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
}

.contact-details div {
  font-size: 0.875rem;
  color: oklch(0.708 0 0);
}

.contact-details .contact-label {
  font-size: 0.75rem;
  color: oklch(0.556 0 0);
}

.footer-bottom {
  border-top: 1px solid oklch(0.269 0 0);
  padding-top: 2rem;
  margin-top: 2rem;
  text-align: center;
  font-size: 0.875rem;
  color: oklch(0.556 0 0);
}

/* Mobile Responsive */
@media (max-width: 1023px) {
  .nav-menu {
    display: flex;
    position: fixed;
    top: 7rem;
    right: -100%;
    width: 300px;
    height: calc(100vh - 7rem);
    background: white;
    flex-direction: column;
    align-items: flex-start;
    padding: 2rem 1rem;
    box-shadow: -2px 0 10px rgba(0,0,0,0.1);
    transition: right 0.3s;
    overflow-y: auto;
  }

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

  .nav-menu > li {
    width: 100%;
    border-bottom: 1px solid oklch(0.90 0 0);
    padding: 0.5rem 0;
  }

  .nav-menu > li > a {
    width: 100%;
    justify-content: flex-start;
  }

  .dropdown-menu {
    position: static;
    width: 100%;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    border: none;
    padding-left: 1rem;
    margin-top: 0.5rem;
    display: none;
  }

  .nav-dropdown.active .dropdown-menu {
    display: block;
  }
}

/* Clase especial para cards de clientes con texto más pequeño */
.grid-6 .card h3 {
  font-size: 1.125rem;  /* 18px - aumentado de 16px */
  font-weight: 400;
}

/* --- ESTILOS PARA MENÚ ACTIVO --- */

/* Color azul para la página actual y sus padres (si es un submenú) */
.nav-menu > li.current-menu-item > a,
.nav-menu > li.current-menu-parent > a,
.nav-menu > li.current_page_item > a,
.nav-menu > li.current_page_ancestor > a {
    color: #0ea5e9 !important; /* Tu azul corporativo */
    font-weight: 600;          /* Un poco más negrita para destacar */
}

/* Opcional: Si quieres mantener el estilo en los submenús también */
.dropdown-menu li.current-menu-item > a {
    color: #0ea5e9 !important;
    background-color: #f8fafc; /* Un fondo gris muy suave */
}

/* --- HEADER TRANSPARENTE --- */
header {
    /* Color blanco con 90% de opacidad (ajusta el 0.9 a tu gusto, ej: 0.8 es más transparente) */
    background-color: rgba(255, 255, 255, 0.9) !important;
    
    /* Opcional: Añade un efecto de desenfoque detrás (estilo "cristal esmerilado") */
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    
}