/* Estilos de soporte para la versión sin compilación (HTML + CSS + JS + PHP) */

[hidden] { display: none !important; }

/* Tema claro fijo: el CSS original cambiaba los colores con el modo oscuro del sistema
   y dejaba textos poco legibles sobre fondos blancos. */
:root {
  color-scheme: light;
  --text: #6b6375;
  --text-h: #08060d;
  --bg: #fff;
  --border: #e5e4e7;
  --code-bg: #f4f3ec;
  --accent: #aa3bff;
  --accent-bg: #aa3bff1a;
  --accent-border: #aa3bff80;
  --social-bg: #f4f3ec80;
}
body { background: #fff; }

#page { display: block; }

/* H1 que antes eran H2/H3: conservan el aspecto original
   (los estilos en línea de cada título siguen aplicando encima) */
h1.as-h2 { font-size: 24px; letter-spacing: -.24px; margin: 0 0 8px; line-height: 118%; font-weight: 500; }
h1.as-h3 { font-size: 1.17em; letter-spacing: normal; margin: 1em 0; line-height: normal; font-weight: bold; }
@media (width <= 1024px) { h1.as-h2 { font-size: 20px; } }

/* "saint" del H1 de inicio: en el HTML es una "i" normal (se lee "saint");
   visualmente se dibuja una "ı" sin punto y el punto naranja va aparte */
.saint-i { color: transparent; }
.saint-i::before {
  content: "ı";
  position: absolute;
  left: 0;
  top: 0;
  color: #010f6b;
}

/* ---------- Animaciones de aparición al hacer scroll ---------- */
.rv-hide {
  opacity: 0 !important;
  transform: translateY(40px) !important;
}

/* ---------- Header ---------- */
#mobile-menu:not([hidden]) { display: flex; }
#site-header nav a:hover { color: #fe7200 !important; }

/* ---------- Footer: enlaces de servicios ---------- */
#site-footer a[data-service-link]:hover { color: #ffffff !important; }

/* ---------- Loader de la página de inicio ---------- */
#page-loader {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(to bottom, #01034a, #050552);
  transition: opacity 0.6s ease;
}
#page-loader.is-done { opacity: 0; pointer-events: none; }
.pl-ring {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 128px;
  height: 128px;
  border-radius: 50%;
  box-shadow: 0 0 60px rgba(255, 255, 255, 0.15);
  animation: plZoom 0.7s ease-out;
}
.pl-ring > div { position: absolute; border-radius: 50%; }
.pl-r1 { inset: 0; border-top: 4px solid rgba(255, 255, 255, 0.6); animation: plSpin 1s linear infinite; }
.pl-r2 { inset: 8px; border-right: 4px solid rgba(129, 140, 248, 0.4); animation: plSpin 2s linear infinite reverse; }
.pl-r3 { inset: 16px; border-bottom: 4px solid rgba(199, 210, 254, 0.3); animation: plSpin 3s linear infinite; }
.pl-ring img {
  position: relative;
  z-index: 10;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}
@keyframes plSpin { to { transform: rotate(360deg); } }
@keyframes plZoom { from { opacity: 0; transform: scale(0.9); } to { opacity: 1; transform: scale(1); } }

/* ---------- Botón "Ir arriba" (inicio) ---------- */
#scroll-top {
  position: fixed;
  right: 24px;
  bottom: 110px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: #00114b;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 9990;
  box-shadow: 0 8px 20px rgba(0, 13, 68, 0.34);
  transition: transform 0.25s ease, background 0.25s ease;
  animation: fadeIn 0.3s ease;
}
#scroll-top:hover { transform: translateY(-3px); background: #020daa; }

/* ---------- Chat ---------- */
#chat-launcher { transition: transform 0.2s ease; }
#chat-launcher:hover { transform: scale(1.08); }
#chat-results button:hover span:first-child,
[data-chat-view="FAQ"] button[data-q]:hover span:first-child { color: #ff7a1a; }

/* ---------- Efectos hover que en React se hacían con onMouseEnter ---------- */
.clients-grid a:hover { transform: scale(1.04); box-shadow: 0 15px 35px rgba(0, 0, 0, 0.10) !important; }
.carousel-arrow:hover { background: #ffffff !important; }
.apps-grid > div { transition: transform 0.3s ease, box-shadow 0.3s ease; }
.apps-grid > div:hover { transform: translateY(-6px); }
