/*
  Shared across every page of the site (principal + los 7 ejemplos):
  reset, accesibilidad (foco/skip-link), animación de aparición al scroll,
  botón flotante de WhatsApp y botón "volver arriba".

  Cada página define sus propias variables de tema (--accent, --border,
  --surface, --text, --bg) en su :root — este archivo solo las consume.
*/

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

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: 12px;
  z-index: 1000;
  background: var(--accent);
  color: #05130a;
  font-weight: 700;
  padding: 12px 20px;
  border-radius: 8px;
  transition: top .2s ease;
}
.skip-link:focus { top: 12px; }

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s cubic-bezier(.16,1,.3,1), transform .7s cubic-bezier(.16,1,.3,1);
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }

.wa-float {
  position: fixed;
  bottom: 22px;
  right: 22px;
  z-index: 200;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #25D366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 28px -8px rgba(37, 211, 102, 0.65);
  transition: transform .2s ease;
}
.wa-float:hover { transform: scale(1.08); }
.wa-float svg { width: 28px; height: 28px; }

.back-to-top {
  position: fixed;
  bottom: 22px;
  right: 92px;
  z-index: 200;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-size: 1.2rem;
  cursor: pointer;
  box-shadow: 0 12px 24px -10px rgba(0, 0, 0, 0.35);
  transition: transform .2s ease, border-color .2s ease;
}
.back-to-top:hover { border-color: var(--accent); transform: translateY(-2px); }
.back-to-top[hidden] { display: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}
