/*
Theme Name: Proyeknort Theme
Theme URI: https://proyeknort.com
Description: Tema personalizado para Grupo Proyeknort
Author: Pymergy Media
Author URI: https://www.pymergy.com
Version: 1.0
Template: twentytwentyfour
License: GPL v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
*/

/* Importar Google Font */
@import url("https://fonts.googleapis.com/css2?family=Red+Hat+Display:wght@400;500;600;700;800;900&display=swap");

/* Variables */
:root {
  --pk-red: #e31e24;
  --pk-red-dark: #c41a1f;
  --pk-dark: #1a1a1a;
  --pk-gray: #666666;
  --pk-light: #f8f8f8;
}

/* Base */
* {
  box-sizing: border-box;
}

body {
  font-family: "Red Hat Display", -apple-system, BlinkMacSystemFont, sans-serif;
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
}

/* Reset padding del tema padre */
body .wp-site-blocks {
  padding: 0 !important;
}

/* Contenedor principal de bloques con ancho máximo */
.wp-block-group.has-global-padding > * {
  max-width: 1100px !important;
  margin-left: auto !important;
  margin-right: auto !important;
}

/* Columnas ocupan el ancho del contenedor */
.wp-block-columns {
  max-width: 100% !important;
  width: 100% !important;
}

/* Galerías de imágenes - 3 columnas en desktop */
.wp-block-gallery {
  max-width: 100% !important;
}

.wp-block-gallery.columns-2 {
  columns: 3 !important;
}

.wp-block-gallery.is-layout-flex {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr) !important;
  gap: 1rem !important;
}

@media (max-width: 768px) {
  .wp-block-gallery.is-layout-flex {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

@media (max-width: 480px) {
  .wp-block-gallery.is-layout-flex {
    grid-template-columns: 1fr !important;
  }
}

/* Padding interno para secciones full width */
.wp-block-group.alignfull.has-global-padding {
  padding-left: 5% !important;
  padding-right: 5% !important;
}

@media (min-width: 1400px) {
  .wp-block-group.alignfull.has-global-padding {
    padding-left: calc((100% - 1100px) / 2) !important;
    padding-right: calc((100% - 1100px) / 2) !important;
  }
}

/* Ocultar comentarios HTML que quedaron como texto */
p:empty,
p:has(> br:only-child) {
  display: none;
}

.wp-block-post-content {
  padding: 0 !important;
}

/* Botones profesionales */
.wp-block-button__link {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
  font-family: "Red Hat Display", sans-serif !important;
  font-weight: 600 !important;
  letter-spacing: 0.05em !important;
}

.wp-block-button__link:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 35px rgba(0,0,0,0.2);
}

/* Imágenes responsive con aspect ratio fijo */
.wp-block-image img {
  width: 100%;
  height: auto;
}

.wp-block-image.pk-project img {
  aspect-ratio: 4/3;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.wp-block-image.pk-project {
  overflow: hidden;
  position: relative;
}

.wp-block-image.pk-project:hover img {
  transform: scale(1.1);
}

/* Overlay en hover */
.wp-block-image.pk-project::before {
  content: "VER PROYECTO";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 2rem 1rem 1rem;
  background: linear-gradient(transparent, rgba(0,0,0,0.8));
  color: white;
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.4s ease;
  z-index: 2;
}

.wp-block-image.pk-project:hover::before {
  opacity: 1;
  transform: translateY(0);
}

/* Cards de servicios */
.pk-service {
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border-bottom: 4px solid transparent !important;
}

.pk-service:hover {
  transform: translateY(-10px);
  box-shadow: 0 25px 50px rgba(0,0,0,0.1);
  border-bottom-color: var(--pk-red) !important;
}

/* Estadísticas con animación */
.pk-stat {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.6s ease forwards;
}

.pk-stat:nth-child(1) { animation-delay: 0.1s; }
.pk-stat:nth-child(2) { animation-delay: 0.2s; }
.pk-stat:nth-child(3) { animation-delay: 0.3s; }

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Cover con parallax */
.wp-block-cover {
  background-attachment: fixed !important;
}

@media (max-width: 768px) {
  .wp-block-cover {
    background-attachment: scroll !important;
  }
}

/* Tipografía mejorada */
h1, h2, h3, h4, h5, h6 {
  font-family: "Red Hat Display", sans-serif;
  font-weight: 700;
}

/* Scroll suave */
html {
  scroll-behavior: smooth;
}

/* CTA hover */
.pk-cta:hover {
  background-color: var(--pk-red-dark) !important;
}

/* Links animados */
a {
  transition: color 0.3s ease;
}

/* Columnas responsive mejoradas */
@media (max-width: 782px) {
  .wp-block-columns {
    flex-wrap: wrap !important;
  }
  .wp-block-column {
    flex-basis: 100% !important;
    margin-bottom: 1.5rem;
  }
}

/* Separador rojo */
hr.pk-separator {
  border: none;
  height: 4px;
  width: 60px;
  background: var(--pk-red);
  margin: 1rem auto 2rem;
}

/* ELIMINAR ESPACIOS ENTRE SECCIONES FULL-WIDTH */
/* Esto asegura que los bloques full-width se peguen sin gaps blancos */
.wp-block-group.alignfull {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

/* Eliminar márgenes automáticos del tema en secciones consecutivas */
.wp-block-group.alignfull + .wp-block-group.alignfull {
  margin-top: 0 !important;
}

/* Quitar gap del contenedor principal */
.wp-block-post-content > *:first-child {
  margin-top: 0 !important;
}

.wp-block-post-content > *:last-child {
  margin-bottom: 0 !important;
}

/* Fix para el tema twentytwentyfour - elimina gaps entre bloques */
.wp-site-blocks > * + * {
  margin-block-start: 0 !important;
}

.wp-site-blocks .wp-block-group + .wp-block-group {
  margin-top: 0 !important;
}

/* Eliminar cualquier gap del editor */
.entry-content > *,
.wp-block-post-content > * {
  margin-block-start: 0 !important;
  margin-block-end: 0 !important;
}

/* Asegurar que el cover también no tenga gap */
.wp-block-cover.alignfull {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

/* Fix específico para main content wrapper */
main.wp-block-group {
  gap: 0 !important;
}

main.wp-block-group > * {
  margin: 0 !important;
}

/* ============================================
   HEADER - DESKTOP
   ============================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.site-header.scrolled {
  background: rgba(255, 255, 255, 1);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

.header-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 1rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header-logo a {
  display: block;
}

.header-logo img {
  height: 50px;
  width: auto;
  transition: transform 0.3s ease;
}

.header-logo a:hover img {
  transform: scale(1.05);
}

.header-logo .logo-text {
  font-size: 24px;
  font-weight: 800;
  color: var(--pk-red);
}

/* Desktop Menu */
.desktop-menu {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-links {
  display: flex;
  align-items: center;
}

.main-nav {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 0.5rem;
}

.main-nav li {
  margin: 0;
}

.main-nav a {
  display: block;
  padding: 0.5rem 1rem;
  text-decoration: none;
  color: var(--pk-dark);
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: color 0.3s ease;
  position: relative;
}

.main-nav a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--pk-red);
  transition: width 0.3s ease, left 0.3s ease;
}

.main-nav a:hover,
.main-nav .current-menu-item a {
  color: var(--pk-red);
}

.main-nav a:hover::after,
.main-nav .current-menu-item a::after {
  width: 100%;
  left: 0;
}

/* ============================================
   DROPDOWN SUBMENU - DESKTOP
   ============================================ */
.main-nav > li {
  position: relative;
}

.main-nav > li.menu-item-has-children > a::after {
  display: none; /* Quitar línea roja del padre */
}

.main-nav > li.menu-item-has-children > a {
  display: flex;
  align-items: center;
  gap: 5px;
}

.main-nav > li.menu-item-has-children > a::before {
  content: '';
  display: inline-block;
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid currentColor;
  margin-left: 5px;
  transition: transform 0.3s ease;
  order: 1;
}

.main-nav > li.menu-item-has-children:hover > a::before {
  transform: rotate(180deg);
}

/* Submenú */
.main-nav .sub-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: white;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  border-radius: 8px;
  padding: 0.5rem 0;
  list-style: none;
  margin: 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 0.3s ease;
  z-index: 1000;
}

.main-nav .sub-menu::before {
  content: '';
  position: absolute;
  top: -8px;
  left: 20px;
  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-bottom: 8px solid white;
}

.main-nav > li.menu-item-has-children:hover > .sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.main-nav .sub-menu li {
  margin: 0;
}

.main-nav .sub-menu a {
  display: block;
  padding: 0.75rem 1.25rem;
  color: var(--pk-dark);
  font-size: 0.85rem;
  font-weight: 500;
  text-transform: none;
  letter-spacing: 0;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.main-nav .sub-menu a::after {
  display: none;
}

.main-nav .sub-menu a:hover {
  background: rgba(227, 30, 36, 0.05);
  color: var(--pk-red);
  padding-left: 1.5rem;
}

.main-nav .sub-menu li:first-child a {
  border-radius: 8px 8px 0 0;
}

.main-nav .sub-menu li:last-child a {
  border-radius: 0 0 8px 8px;
}

.header-phone-btn {
  background: var(--pk-red);
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 600;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.header-phone-btn:hover {
  background: var(--pk-red-dark);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(227, 30, 36, 0.3);
}

/* Menu Toggle (Hamburger) */
.menu-toggle {
  display: none;
  position: relative;
  z-index: 1001;
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  width: 50px;
  height: 50px;
  transition: transform 0.3s ease;
}

.menu-toggle:hover {
  transform: scale(1.1);
}

.menu-toggle span {
  display: block;
  width: 30px;
  height: 3px;
  background: var(--pk-red);
  margin: 6px auto;
  border-radius: 2px;
  transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  transform-origin: center;
}

/* Hamburger to X animation */
.menu-toggle.active span:nth-child(1) {
  transform: translateY(9px) rotate(45deg);
}

.menu-toggle.active span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.menu-toggle.active span:nth-child(3) {
  transform: translateY(-9px) rotate(-45deg);
}

/* ============================================
   MOBILE MENU - SUPER PROFESIONAL
   ============================================ */

/* Overlay */
.menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(3px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  z-index: 998;
}

.menu-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* Mobile Menu Container */
.mobile-menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: 85%;
  max-width: 400px;
  height: 100vh;
  background: #ffffff;
  box-shadow: -5px 0 30px rgba(0, 0, 0, 0.2);
  z-index: 999;
  overflow-y: auto;
  transition: right 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  display: flex;
  flex-direction: column;
}

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

/* Mobile Menu Header */
.mobile-menu-header {
  padding: 30px 25px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #f8f8f8;
}

.mobile-menu-logo img {
  max-height: 40px;
  width: auto;
}

.mobile-menu-logo span {
  color: var(--pk-dark);
  font-size: 20px;
  font-weight: 800;
}

/* Menu Items Container */
.mobile-menu-items {
  padding: 20px 0;
  flex: 1;
}

.mobile-nav {
  list-style: none;
  margin: 0;
  padding: 0;
}

.mobile-menu .menu-item {
  opacity: 0;
  transform: translateX(50px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.mobile-menu .menu-item.animate-in {
  opacity: 1;
  transform: translateX(0);
}

.mobile-menu .menu-item a {
  display: block;
  padding: 18px 25px;
  color: var(--pk-dark);
  text-decoration: none;
  font-size: 18px;
  font-weight: 600;
  font-family: 'Red Hat Display', sans-serif;
  border-left: 3px solid transparent;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.mobile-menu .menu-item a::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(227, 30, 36, 0.1), transparent);
  transition: left 0.5s ease;
}

.mobile-menu .menu-item a:hover::before,
.mobile-menu .menu-item a:focus::before {
  left: 100%;
}

.mobile-menu .menu-item a:hover,
.mobile-menu .menu-item a:focus {
  background: rgba(227, 30, 36, 0.1);
  border-left-color: var(--pk-red);
  padding-left: 35px;
  color: var(--pk-red);
}

.mobile-menu .menu-item.current-menu-item a {
  background: rgba(227, 30, 36, 0.15);
  border-left-color: var(--pk-red);
  color: var(--pk-red);
}

/* ============================================
   MOBILE SUBMENU - ACCORDION STYLE
   ============================================ */
.mobile-menu .menu-item-has-children {
  position: relative;
}

.mobile-menu .menu-item-has-children > a {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.mobile-menu .menu-item-has-children > a::after {
  content: '';
  width: 10px;
  height: 10px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  transition: transform 0.3s ease;
  margin-right: 5px;
}

.mobile-menu .menu-item-has-children.submenu-open > a::after {
  transform: rotate(-135deg);
}

.mobile-menu .sub-menu {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 0;
  overflow: hidden;
  background: #f5f5f5;
  transition: max-height 0.4s ease;
}

.mobile-menu .menu-item-has-children.submenu-open > .sub-menu {
  max-height: 500px;
}

.mobile-menu .sub-menu li {
  opacity: 0;
  transform: translateX(20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.mobile-menu .menu-item-has-children.submenu-open > .sub-menu li {
  opacity: 1;
  transform: translateX(0);
}

.mobile-menu .sub-menu li:nth-child(1) { transition-delay: 0.05s; }
.mobile-menu .sub-menu li:nth-child(2) { transition-delay: 0.1s; }
.mobile-menu .sub-menu li:nth-child(3) { transition-delay: 0.15s; }
.mobile-menu .sub-menu li:nth-child(4) { transition-delay: 0.2s; }
.mobile-menu .sub-menu li:nth-child(5) { transition-delay: 0.25s; }
.mobile-menu .sub-menu li:nth-child(6) { transition-delay: 0.3s; }
.mobile-menu .sub-menu li:nth-child(7) { transition-delay: 0.35s; }

.mobile-menu .sub-menu a {
  padding: 12px 25px 12px 40px !important;
  font-size: 15px !important;
  border-left: none !important;
  color: #666 !important;
}

.mobile-menu .sub-menu a::before {
  content: '→';
  margin-right: 10px;
  color: var(--pk-red);
}

.mobile-menu .sub-menu a:hover,
.mobile-menu .sub-menu a:focus {
  color: var(--pk-red) !important;
  background: rgba(227, 30, 36, 0.15) !important;
  padding-left: 45px !important;
}

/* Mobile Menu Footer */
.mobile-menu-footer {
  padding: 25px;
  border-top: 1px solid rgba(0, 0, 0, 0.1);
  background: #f8f8f8;
}

.mobile-menu-contact {
  margin-bottom: 20px;
}

.mobile-menu-contact p {
  color: #666;
  font-size: 14px;
  margin-bottom: 10px;
}

.mobile-menu-phone {
  display: flex;
  align-items: center;
  color: var(--pk-red);
  font-size: 20px;
  font-weight: 700;
  text-decoration: none;
  margin-bottom: 15px;
  transition: transform 0.2s ease;
}

.mobile-menu-phone:hover {
  transform: scale(1.05);
}

.mobile-menu-phone i {
  margin-right: 10px;
  font-size: 24px;
}

.mobile-menu-email {
  color: var(--pk-dark);
  text-decoration: none;
  font-size: 14px;
  display: block;
  margin-bottom: 10px;
  transition: color 0.2s ease;
}

.mobile-menu-email:hover {
  color: var(--pk-red);
}

/* Prevent body scroll when menu open */
body.menu-open {
  overflow: hidden;
  height: 100vh;
}

/* ============================================
   BREADCRUMBS
   ============================================ */
.breadcrumbs-section {
  background: #f5f5f5;
  padding: 1rem 2rem;
}

.breadcrumbs-container {
  max-width: 1400px;
  margin: 0 auto;
  font-size: 0.85rem;
  color: #666;
}

.breadcrumbs-container a {
  color: #666;
  text-decoration: none;
  transition: color 0.3s ease;
}

.breadcrumbs-container a:hover {
  color: var(--pk-red);
}

.breadcrumbs-container span {
  color: var(--pk-red);
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
  background: var(--pk-dark);
  color: #ffffff;
  padding: 4rem 2rem 2rem;
}

.footer-container {
  max-width: 1400px;
  margin: 0 auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-column h4 {
  color: var(--pk-red);
  font-size: 1rem;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  letter-spacing: 0.05em;
}

.footer-logo img {
  max-height: 50px;
  margin-bottom: 1rem;
}

.footer-description {
  color: #999;
  font-size: 0.9rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.footer-contact p {
  color: #999;
  font-size: 0.85rem;
  margin-bottom: 0.8rem;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.footer-contact i {
  color: var(--pk-red);
  margin-top: 2px;
}

.footer-contact a {
  color: #999;
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-contact a:hover {
  color: var(--pk-red);
}

.footer-menu {
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-menu li {
  margin-bottom: 0.8rem;
}

.footer-menu a {
  color: #999;
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.3s ease;
  display: inline-block;
  position: relative;
}

.footer-menu a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--pk-red);
  transition: width 0.3s ease;
}

.footer-menu a:hover {
  color: var(--pk-red);
}

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

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-bottom p {
  color: #666;
  font-size: 0.85rem;
  margin: 0;
}

/* Botón cookies - ver estilos en sección BANNER DE COOKIES */

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
  .desktop-menu {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

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

@media (max-width: 768px) {
  .header-container {
    padding: 1rem 1.5rem;
  }

  .header-logo img {
    height: 40px;
  }

  .mobile-menu {
    width: 90%;
  }

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

  .footer-bottom {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }

  .breadcrumbs-section {
    padding: 0.8rem 1.5rem;
  }

  .breadcrumbs-container {
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  .site-footer {
    padding: 3rem 1.5rem 1.5rem;
  }
}

/* Accessibility */
.menu-toggle:focus,
.mobile-menu a:focus,
.header-phone-btn:focus,
.cookie-settings-btn:focus {
  outline: 2px solid var(--pk-red);
  outline-offset: 2px;
}

/* Smooth scrolling */
@media (prefers-reduced-motion: reduce) {
  .mobile-menu,
  .menu-toggle span,
  .mobile-menu .menu-item {
    transition: none;
  }
}

/* Kit Digital Banner */
.footer-kit-digital {
    text-align: center;
    padding: 2rem 0;
    margin-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.footer-kit-digital img {
    max-width: 500px;
    width: 100%;
    height: auto;
}

@media (max-width: 768px) {
    .footer-kit-digital img {
        max-width: 100%;
    }
}

/* ========== HERO SLIDER ========== */
.hero-slider {
    position: relative;
    height: 90vh;
    min-height: 600px;
    overflow: hidden;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    background-size: cover;
    background-position: center;
}

.hero-slide.active {
    opacity: 1;
}

.hero-slide::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
}

.hero-slide-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: white;
    max-width: 800px;
    padding: 0 2rem;
    z-index: 2;
}

.hero-slide-content h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.hero-slide-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.hero-buttons .btn {
    padding: 1rem 2rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.3s;
}

.hero-buttons .btn-primary {
    background: var(--pk-red);
    color: white;
}

.hero-buttons .btn-primary:hover {
    background: var(--pk-red-dark);
}

.hero-buttons .btn-secondary {
    background: white;
    color: var(--pk-dark);
}

.hero-buttons .btn-secondary:hover {
    background: #f0f0f0;
}

/* Slider dots */
.slider-dots {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.75rem;
    z-index: 10;
}

.slider-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255,255,255,0.5);
    cursor: pointer;
    transition: all 0.3s;
    border: none;
}

.slider-dot.active,
.slider-dot:hover {
    background: var(--pk-red);
}

/* ========== PROYECTOS GRID HOME ========== */
.proyectos-grid-home {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
}

.proyecto-card-home {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.proyecto-card-home:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.proyecto-card-home a {
    text-decoration: none;
    color: inherit;
    display: block;
}

.proyecto-card-home img {
    width: 100%;
    aspect-ratio: 4/3;
    object-fit: cover;
}

.proyecto-card-content {
    padding: 1.25rem;
    background: white;
}

.proyecto-card-content h4 {
    margin: 0 0 0.5rem 0;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--pk-dark);
}

.proyecto-card-content p {
    margin: 0;
    color: #666;
    font-size: 0.9rem;
}

/* ========== SERVICIOS GRID HOME ========== */
.servicios-grid-home {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
}

.servicio-card-home {
    background: #f5f5f5;
    padding: 2rem 1.5rem;
    border-radius: 8px;
    text-align: center;
    transition: all 0.3s;
}

.servicio-card-home:hover {
    background: #eee;
    transform: translateY(-3px);
}

.servicio-card-home h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 1rem 0;
    color: var(--pk-dark);
}

.servicio-card-home p {
    color: #666;
    font-size: 0.9rem;
    margin: 0 0 1.5rem 0;
}

.btn-ver-mas {
    color: var(--pk-red);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
}

.btn-ver-mas:hover {
    text-decoration: underline;
}

/* Responsive */
@media (max-width: 992px) {
    .servicios-grid-home {
        grid-template-columns: repeat(2, 1fr);
    }
    .proyectos-grid-home {
        grid-template-columns: repeat(2, 1fr);
    }
    .hero-slide-content h1 {
        font-size: 2.5rem;
    }
}

@media (max-width: 576px) {
    .servicios-grid-home,
    .proyectos-grid-home {
        grid-template-columns: 1fr;
    }
    .hero-slide-content h1 {
        font-size: 2rem;
    }
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
}

/* Fix slider text color */
.hero-slide-content h1,
.hero-slide-content p {
    color: white !important;
}

/* ========== ÁREAS DE TRABAJO ========== */
.areas-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
}

.area-card {
    background: white;
    border-radius: 12px;
    padding: 2rem 1.5rem;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    border: 1px solid #eee;
}

.area-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.12);
    border-color: var(--pk-red);
}

.area-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--pk-red) 0%, #ff4a4a 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.25rem;
    color: white;
    font-size: 1.75rem;
}

.area-card h4 {
    font-size: 1rem;
    font-weight: 700;
    margin: 0 0 0.75rem 0;
    color: var(--pk-dark);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.area-card p {
    font-size: 0.85rem;
    color: #666;
    margin: 0;
    line-height: 1.5;
}

/* ========== GARANTÍAS ========== */
.garantias-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}

.garantia-item {
    text-align: center;
    padding: 1.5rem;
}

.garantia-icon {
    width: 80px;
    height: 80px;
    background: rgba(227, 30, 36, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    color: var(--pk-red);
    font-size: 2rem;
}

.garantia-item h4 {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 0.5rem 0;
    color: var(--pk-dark);
}

.garantia-item p {
    font-size: 0.9rem;
    color: #666;
    margin: 0;
}

/* ========== COBERTURA ========== */
.cobertura-section {
    position: relative;
    overflow: hidden;
}

.cobertura-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.cobertura-text h2 {
    color: white;
    font-weight: 700;
    margin-bottom: 1rem;
}

.cobertura-text p {
    color: rgba(255,255,255,0.8);
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

.cobertura-zones {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.zone-tag {
    background: rgba(255,255,255,0.15);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 500;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255,255,255,0.2);
}

.cobertura-map {
    background: rgba(255,255,255,0.1);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
}

.cobertura-map i {
    font-size: 8rem;
    color: rgba(255,255,255,0.3);
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
    .areas-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 992px) {
    .areas-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .garantias-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .cobertura-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    .cobertura-map {
        display: none;
    }
}

@media (max-width: 576px) {
    .areas-grid,
    .garantias-grid {
        grid-template-columns: 1fr;
    }
}
/* ========== SERVICIOS CON ICONOS (Nuevo diseño) ========== */
.servicios-con-iconos {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
}

.servicio-card-icono {
    background: white;
    border-radius: 12px;
    padding: 2rem 1.5rem;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    border: 1px solid #eee;
}

.servicio-card-icono:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.12);
    border-color: var(--pk-red);
}

.servicio-card-icono a {
    text-decoration: none;
    color: inherit;
    display: block;
}

.servicio-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--pk-red) 0%, #ff4a4a 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.25rem;
    color: white;
    font-size: 1.75rem;
    transition: transform 0.3s ease;
}

.servicio-card-icono:hover .servicio-icon {
    transform: scale(1.1);
}

.servicio-card-icono h4 {
    font-size: 1rem;
    font-weight: 700;
    margin: 0 0 0.75rem 0;
    color: var(--pk-dark);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.servicio-card-icono p {
    font-size: 0.85rem;
    color: #666;
    margin: 0;
    line-height: 1.5;
}

/* Responsive servicios con iconos */
@media (max-width: 1200px) {
    .servicios-con-iconos {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 992px) {
    .servicios-con-iconos {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .servicios-con-iconos {
        grid-template-columns: 1fr;
    }
}

/* ========== GALERÍA OFICINAS ========== */
.oficinas-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
}

.oficina-img {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.oficina-img img {
    width: 100%;
    aspect-ratio: 4/3;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.oficina-img:hover img {
    transform: scale(1.05);
}

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

@media (max-width: 480px) {
    .oficinas-gallery {
        grid-template-columns: 1fr;
    }
}

/* ========== PÁGINA CONTACTO ========== */
.contacto-info-cards {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.contacto-card {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1.25rem;
    background: #f8f9fa;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.contacto-card:hover {
    background: #f0f0f0;
    transform: translateX(5px);
}

.contacto-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #e31e24 0%, #ff4a4a 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.contacto-data h4 {
    margin: 0 0 0.25rem 0;
    font-size: 1rem;
    font-weight: 700;
    color: #1a1a1a;
}

.contacto-data p {
    margin: 0;
    color: #666;
    font-size: 0.95rem;
    line-height: 1.5;
}

.contacto-data a {
    color: #e31e24;
    text-decoration: none;
    font-weight: 600;
}

.contacto-data a:hover {
    text-decoration: underline;
}

/* Social Links */
.social-links {
    display: flex;
    gap: 0.75rem;
}

.social-link {
    width: 45px;
    height: 45px;
    background: #1a1a1a;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    text-decoration: none;
}

.social-link:hover {
    background: #e31e24;
    transform: translateY(-3px);
}

/* Formulario Contacto */
.contacto-form {
    background: #f8f9fa;
    padding: 2rem;
    border-radius: 12px;
}

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

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

.form-group label {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #1a1a1a;
    font-size: 0.9rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 0.85rem 1rem;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #e31e24;
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* RGPD Section */
.rgpd-section {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #ddd;
}

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

.checkbox-group input[type=checkbox] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    accent-color: #e31e24;
}

.checkbox-group label {
    font-weight: 400;
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 0;
}

.checkbox-group label a {
    color: #e31e24;
}

.rgpd-info {
    background: #fff;
    padding: 1rem;
    border-radius: 6px;
    margin-top: 1rem;
    border-left: 3px solid #e31e24;
}

.rgpd-info p {
    margin: 0 0 0.5rem 0;
    font-size: 0.8rem;
    color: #666;
}

.rgpd-info ul {
    margin: 0;
    padding-left: 1rem;
    font-size: 0.75rem;
    color: #888;
}

.rgpd-info li {
    margin-bottom: 0.25rem;
}

.captcha-note {
    font-size: 0.75rem;
    color: #888;
    margin-top: 0.5rem;
}

.btn-submit {
    background: linear-gradient(135deg, #e31e24 0%, #c41a1f 100%);
    color: white;
    padding: 1rem 2.5rem;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1rem;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(227, 30, 36, 0.3);
}

/* Mapa */
.mapa-container {
    width: 100%;
    line-height: 0;
}

.mapa-container iframe {
    width: 100%;
    height: 450px;
}

/* Responsive */
@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .contacto-form {
        padding: 1.5rem;
    }
}

/* ========== BANNER DE COOKIES ========== */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #ffffff;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.15);
    z-index: 99999;
    padding: 1.5rem;
    border-top: 3px solid #e31e24;
}
.cookie-banner-container {
    max-width: 1200px;
    margin: 0 auto;
}
.cookie-banner-content {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1.5rem;
}
.cookie-banner-text {
    flex: 1;
    min-width: 300px;
}
.cookie-banner-text h3 {
    font-size: 1.1rem;
    margin: 0 0 0.5rem 0;
    color: #1a1a1a;
    font-weight: 700;
}
.cookie-banner-text h3 i {
    color: #e31e24;
    margin-right: 0.5rem;
}
.cookie-banner-text p {
    font-size: 0.9rem;
    color: #666;
    margin: 0 0 0.5rem 0;
    line-height: 1.5;
}
.cookie-banner-text a {
    color: #e31e24;
    text-decoration: underline;
}
.cookie-banner-buttons {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}
.cookie-btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 4px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}
.cookie-btn-accept {
    background: #e31e24;
    color: #fff;
}
.cookie-btn-accept:hover {
    background: #c41a1f;
}
.cookie-btn-reject {
    background: #666;
    color: #fff;
}
.cookie-btn-reject:hover {
    background: #555;
}
.cookie-btn-config {
    background: transparent;
    color: #1a1a1a;
    border: 2px solid #1a1a1a;
}
.cookie-btn-config:hover {
    background: #1a1a1a;
    color: #fff;
}

/* Modal de cookies */
.cookie-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.6);
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}
.cookie-modal-content {
    background: #fff;
    border-radius: 8px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
}
.cookie-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid #eee;
    background: #f8f8f8;
    border-radius: 8px 8px 0 0;
}
.cookie-modal-header h3 {
    margin: 0;
    font-size: 1.2rem;
    color: #1a1a1a;
}
.cookie-modal-header h3 i {
    color: #e31e24;
    margin-right: 0.5rem;
}
.cookie-modal-close {
    background: none;
    border: none;
    font-size: 1.75rem;
    cursor: pointer;
    color: #999;
    line-height: 1;
    padding: 0;
}
.cookie-modal-close:hover {
    color: #e31e24;
}
.cookie-modal-body {
    padding: 1.5rem;
}
.cookie-modal-intro {
    color: #666;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}
.cookie-category {
    border: 1px solid #eee;
    border-radius: 6px;
    margin-bottom: 1rem;
    padding: 1rem;
}
.cookie-category-header {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}
.cookie-category-info h4 {
    margin: 0 0 0.25rem 0;
    font-size: 1rem;
    color: #1a1a1a;
}
.cookie-category-info p {
    margin: 0;
    font-size: 0.85rem;
    color: #666;
}
.cookie-required {
    font-size: 0.75rem;
    color: #999;
    font-weight: normal;
}

/* Toggle switch */
.cookie-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 28px;
    flex-shrink: 0;
}
.cookie-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}
.cookie-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 28px;
}
.cookie-slider:before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}
.cookie-switch input:checked + .cookie-slider {
    background-color: #e31e24;
}
.cookie-switch input:disabled + .cookie-slider {
    background-color: #28a745;
    cursor: not-allowed;
}
.cookie-switch input:checked + .cookie-slider:before {
    transform: translateX(22px);
}

.cookie-modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid #eee;
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    background: #f8f8f8;
    border-radius: 0 0 8px 8px;
}

/* Botón flotante */
.cookie-settings-btn {
    position: fixed;
    bottom: 20px;
    left: 20px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #e31e24;
    color: #fff;
    border: none;
    cursor: pointer;
    z-index: 9998;
    box-shadow: 0 4px 15px rgba(227,30,36,0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    transition: all 0.3s ease;
}
.cookie-settings-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(227,30,36,0.5);
}

@media (max-width: 768px) {
    .cookie-banner {
        padding: 1rem;
    }
    .cookie-banner-content {
        flex-direction: column;
        text-align: center;
    }
    .cookie-banner-buttons {
        width: 100%;
        justify-content: center;
    }
    .cookie-btn {
        flex: 1;
        min-width: 100px;
    }
    .cookie-modal-footer {
        flex-direction: column;
    }
    .cookie-modal-footer .cookie-btn {
        width: 100%;
    }
}

/* ========== PÁGINAS LEGALES ========== */
.page-content-legal {
    max-width: 900px;
    margin: 0 auto;
    padding: 3rem 2rem;
}
.page-content-legal h1 {
    color: #1a1a1a;
    margin-bottom: 2rem;
}
.page-content-legal h2,
.page-content-legal h3 {
    color: #1a1a1a;
    margin-top: 2rem;
}
.page-content-legal p,
.page-content-legal li {
    color: #555;
    line-height: 1.7;
}
.page-content-legal a {
    color: #e31e24;
}
.page-content-legal ul {
    padding-left: 1.5rem;
}
.page-content-legal ul li {
    margin-bottom: 0.5rem;
}

/* Equipo directivo - iconos centrados */
.wp-block-column div[style*="border-radius:50%"] {
    display: flex !important;
    align-items: center;
    justify-content: center;
}

/* Footer social */
.footer-social {
    margin-top: 1rem;
}
