/* Template04 - Neon Nocturna Pro. Solo actua bajo body[data-template="template04"]. Consume variables del inquilino (--neon-blue, --neon-pink, --eu-*). */
body[data-template="template04"]{
  --t04-blue: var(--neon-blue, #3b82f6);
  --t04-pink: var(--neon-pink, #ec4899);
  --t04-bg: var(--eu-bg, #070b14);
  --t04-surface: var(--eu-surface, #0d1424);
  --t04-card: var(--eu-card, #111a2e);
  --t04-border: var(--eu-border, #1e293b);
  --t04-text: var(--eu-text, #e5edf7);
  --t04-muted: var(--eu-muted, #94a3b8);
  background: var(--t04-bg);
  color: var(--t04-text);
}
/* Encabezado con cristal al bajar */
body[data-template="template04"] .gsm-header{
  transition: background .35s ease, backdrop-filter .35s ease, box-shadow .35s ease, border-color .35s ease;
  border-bottom: 1px solid transparent;
}
body[data-template="template04"].t04-scrolled .gsm-header{
  background: color-mix(in srgb, var(--t04-surface) 78%, transparent);
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  backdrop-filter: blur(16px) saturate(150%);
  border-bottom-color: color-mix(in srgb, var(--t04-blue) 45%, transparent);
  box-shadow: 0 10px 34px rgba(0,0,0,.38), 0 1px 0 color-mix(in srgb, var(--t04-pink) 25%, transparent);
}
/* Hero a pantalla con foto y parallax (el fondo real lo inserta template.js) */
body[data-template="template04"] #heroToolCarousel{
  position: relative;
  overflow: hidden;
  min-height: min(100svh, 920px);
  background: var(--t04-bg);
}
body[data-template="template04"] .t04-hero-bg{
  position: absolute; inset: -12% 0; z-index: 0; pointer-events: none;
  background: url("images/hero-tools.webp") center center / cover no-repeat;
  will-change: transform;
}
body[data-template="template04"] .t04-hero-bg::after{
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, color-mix(in srgb, var(--t04-bg) 55%, transparent), color-mix(in srgb, var(--t04-bg) 82%, transparent) 72%, var(--t04-bg));
}
body[data-template="template04"] #heroToolCarousel .carousel-inner,
body[data-template="template04"] #heroToolCarousel .carousel-indicators,
body[data-template="template04"] #heroToolCarousel .carousel-control-prev,
body[data-template="template04"] #heroToolCarousel .carousel-control-next{ position: relative; z-index: 2; }
body[data-template="template04"] #heroToolCarousel .carousel-item{ min-height: min(100svh, 920px); }
body[data-template="template04"] #heroToolCarousel .carousel-item > .container,
body[data-template="template04"] #heroToolCarousel .carousel-item > div{ text-shadow: 0 2px 18px rgba(0,0,0,.55); }
/* Bento herramientas destacadas */
.t04-bento-section{ padding: clamp(2.5rem, 6vw, 5rem) 1rem; background: linear-gradient(180deg, var(--t04-bg), var(--t04-surface)); }
.t04-bento-inner{ max-width: 1200px; margin: 0 auto; }
.t04-bento-kicker{ color: var(--t04-blue); letter-spacing: .22em; text-transform: uppercase; font-size: .78rem; font-weight: 700; }
.t04-bento-title{ color: var(--t04-text); font-weight: 800; margin: .35rem 0 .5rem; font-size: clamp(1.7rem, 4vw, 2.6rem); }
.t04-bento-sub{ color: var(--t04-muted); max-width: 720px; }
.t04-bento-grid{ display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 180px; gap: 14px; margin-top: 1.6rem; }
.t04-bento-card{ position: relative; overflow: hidden; border-radius: 18px; border: 1px solid var(--t04-border); background: var(--t04-card); display: block; text-decoration: none; }
.t04-bento-card img{ width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .6s ease, filter .6s ease; filter: saturate(1.05); }
.t04-bento-card:hover img{ transform: scale(1.07); }
.t04-bento-card::after{ content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 42%, rgba(0,0,0,.82)); }
.t04-bento-card span{ position: absolute; left: 14px; right: 14px; bottom: 12px; z-index: 2; color: #fff; font-weight: 800; letter-spacing: .04em; text-shadow: 0 2px 12px rgba(0,0,0,.8); }
.t04-bento-card small{ display: block; color: color-mix(in srgb, var(--t04-blue) 70%, #fff); font-weight: 600; letter-spacing: .14em; text-transform: uppercase; font-size: .68rem; }
.t04-bento-card:nth-child(1){ grid-column: span 2; grid-row: span 2; }
.t04-bento-card:nth-child(4){ grid-column: span 2; }
@media (max-width: 820px){ .t04-bento-grid{ grid-template-columns: repeat(2, 1fr); grid-auto-rows: 150px; } .t04-bento-card:nth-child(1){ grid-column: span 2; grid-row: span 1; } .t04-bento-card:nth-child(4){ grid-column: span 2; } }
/* Catalogo con presentacion propia (sin tocar su logica) */
body[data-template="template04"] #services-catalog .card,
body[data-template="template04"] #services-catalog article,
body[data-template="template04"] #toolsGallery article{
  background: var(--t04-card) !important;
  border: 1px solid var(--t04-border) !important;
  border-radius: 18px !important;
  box-shadow: 0 10px 30px rgba(0,0,0,.28);
  transition: transform .3s ease, border-color .3s ease, box-shadow .3s ease;
}
body[data-template="template04"] #services-catalog .card:hover,
body[data-template="template04"] #services-catalog article:hover,
body[data-template="template04"] #toolsGallery article:hover{
  transform: translateY(-5px);
  border-color: color-mix(in srgb, var(--t04-blue) 60%, transparent) !important;
  box-shadow: 0 18px 44px rgba(0,0,0,.42), 0 0 0 1px color-mix(in srgb, var(--t04-pink) 22%, transparent);
}
body[data-template="template04"] main h2, body[data-template="template04"] main h3{ color: var(--t04-text); }
body[data-template="template04"] main .text-secondary{ color: var(--t04-muted) !important; }
/* Pie diferenciado */
body[data-template="template04"] #cgFooter{ background: linear-gradient(180deg, var(--t04-surface), color-mix(in srgb, var(--t04-bg) 88%, #000)); border-top: 1px solid color-mix(in srgb, var(--t04-blue) 35%, transparent); }
body[data-template="template04"] #footerMega{
  font-size: clamp(2.2rem, 7vw, 5.2rem); font-weight: 900; letter-spacing: .06em; line-height: 1.05; text-align: center; padding: 1.2rem 1rem .4rem;
  background: linear-gradient(90deg, var(--t04-blue), var(--t04-pink)); -webkit-background-clip: text; background-clip: text; color: transparent;
}
/* Aparicion al hacer scroll */
.t04-reveal{ opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s ease; }
.t04-reveal.t04-visible{ opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce){ .t04-reveal{ opacity: 1; transform: none; transition: none; } body[data-template="template04"] .t04-bento-card img{ transition: none; } }
body[data-template="template04"] #heroToolCarousel .carousel-item{ background: transparent !important; }
