/**
 * css/wiclee-landing.css — Base visual de la web pública (landing y registro).
 *
 * Fuentes autoalojadas, variables acotadas a .wiclee-home, contenedor, tipografía de
 * sección, botones, cabecera, menú móvil y pie. Lo carga templates/home/paginaHome.twig.
 * Secciones: wiclee-landing-sections.css y wiclee-landing-producto.css.
 * Animaciones: wiclee-landing-motion.css.
 *
 * Colores solo con tokens de css/tokens.css (AGENTS.md §5.5); transparencias con
 * color-mix() sobre tokens, sin hex. BEM: wiclee-landing__*.
 *
 * Fuente: Open Sans autoalojada (OFL, fonts/landing/OFL.txt; latin 400/600/700/800 y
 * cursiva 700/800), sin Google Fonts. Una sola variable, --wiclee-landing-font, acotada
 * a .wiclee-home. Titulares en 800; lo destacado, en cursiva 800.
 *
 * Justificación >400 líneas (AGENTS.md §3.1): es la única hoja compartida por landing
 * y registro (cabecera, menú, pie y botones); dividirla añadiría otra petición
 * bloqueante a ambas páginas sin separar responsabilidades distintas.
 */

@font-face {
  font-family: 'Open Sans';
  src: url('../fonts/landing/open-sans-latin-400-normal.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Open Sans';
  src: url('../fonts/landing/open-sans-latin-600-normal.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Open Sans';
  src: url('../fonts/landing/open-sans-latin-700-normal.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Open Sans';
  src: url('../fonts/landing/open-sans-latin-800-normal.woff2') format('woff2');
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Open Sans';
  src: url('../fonts/landing/open-sans-latin-700-italic.woff2') format('woff2');
  font-weight: 700;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: 'Open Sans';
  src: url('../fonts/landing/open-sans-latin-800-italic.woff2') format('woff2');
  font-weight: 800;
  font-style: italic;
  font-display: swap;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 104px;
}

.wiclee-home {
  --wiclee-landing-font: 'Open Sans', 'Segoe UI', ui-sans-serif, system-ui, -apple-system, Roboto, Arial, sans-serif;
  --wiclee-landing-header-h: 104px;
  --wiclee-landing-gutter: 44px;
  --wiclee-landing-section-y: 104px;
  --wiclee-landing-max: 1680px;
  --wiclee-landing-white-10: color-mix(in srgb, var(--wiclee-text-inverse) 10%, transparent);
  --wiclee-landing-white-16: color-mix(in srgb, var(--wiclee-text-inverse) 16%, transparent);
  --wiclee-landing-white-55: color-mix(in srgb, var(--wiclee-text-inverse) 55%, transparent);
  --wiclee-landing-white-78: color-mix(in srgb, var(--wiclee-text-inverse) 78%, transparent);
  --wiclee-landing-deep-shadow: color-mix(in srgb, var(--wiclee-primary-900) 45%, transparent);
  --wiclee-landing-text-shadow: color-mix(in srgb, var(--wiclee-primary-900) 28%, transparent);
  --wiclee-landing-ink-shadow: color-mix(in srgb, var(--wiclee-text) 18%, transparent);

  margin: 0;
  min-height: 100vh;
  font-family: var(--wiclee-landing-font);
  font-size: 16px;
  line-height: 1.55;
  color: var(--wiclee-text);
  background: var(--wiclee-bg-card);
  -webkit-font-smoothing: antialiased;
}

@supports (min-height: 100dvh) {
  .wiclee-home {
    min-height: 100dvh;
  }
}

.wiclee-home *,
.wiclee-home *::before,
.wiclee-home *::after {
  box-sizing: border-box;
}

.wiclee-home img {
  display: block;
  max-width: 100%;
}

.wiclee-home :focus-visible {
  outline: 3px solid var(--wiclee-primary-700);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ---------- Contenedor y tipografía de sección ---------- */

.wiclee-landing__wrap {
  width: 100%;
  max-width: var(--wiclee-landing-max);
  margin: 0 auto;
  padding: 0 var(--wiclee-landing-gutter);
}

.wiclee-landing__section {
  position: relative;
  padding: var(--wiclee-landing-section-y) 0;
}

.wiclee-landing__eyebrow {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--wiclee-primary-800);
}

.wiclee-landing__h2 {
  margin: 14px 0 0;
  font-weight: 800;
  font-size: clamp(30px, 3.2vw, 46px);
  line-height: 1.12;
  letter-spacing: -0.015em;
}

.wiclee-landing__h2 em {
  font-style: italic;
  color: var(--wiclee-primary-800);
}

.wiclee-landing__lead {
  max-width: 56ch;
  margin: 20px 0 0;
  font-size: 19px;
  color: var(--wiclee-text-secondary);
}

.wiclee-landing__note {
  margin: 18px 0 0;
  font-size: 13px;
  color: var(--wiclee-text-muted);
}

.wiclee-landing__icon {
  display: block;
  flex: none;
}

/* ---------- Botones ---------- */

.wiclee-landing__cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 30px;
}

.wiclee-landing__btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  padding: 0 26px;
  border: 1px solid transparent;
  border-radius: 10px;
  font: 700 16px/1.2 var(--wiclee-landing-font);
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.25s, border-color 0.25s, transform 0.25s;
}

.wiclee-landing__btn .wiclee-landing__icon {
  width: 18px;
  height: 18px;
  transition: transform 0.3s;
}

.wiclee-landing__btn:hover .wiclee-landing__btn-arrow {
  transform: translateX(5px);
}

.wiclee-landing__btn:active {
  transform: translateY(1px);
}

.wiclee-landing__btn--primary {
  background: var(--wiclee-accent);
  color: var(--wiclee-text);
}

.wiclee-landing__btn--primary:hover {
  background: var(--wiclee-accent-600);
  color: var(--wiclee-text);
}

.wiclee-landing__btn--ghost {
  border-color: var(--wiclee-text-inverse);
  color: var(--wiclee-text-inverse);
}

.wiclee-landing__btn--ghost:hover {
  background: color-mix(in srgb, var(--wiclee-text-inverse) 18%, transparent);
  color: var(--wiclee-text-inverse);
}

.wiclee-landing__btn--dark {
  background: var(--wiclee-text);
  color: var(--wiclee-text-inverse);
}

.wiclee-landing__btn--dark:hover {
  background: var(--wiclee-primary-900);
  color: var(--wiclee-text-inverse);
}

.wiclee-landing__btn--outline-dark {
  border-color: var(--wiclee-text);
  color: var(--wiclee-text);
}

.wiclee-landing__btn--outline-dark:hover {
  background: color-mix(in srgb, var(--wiclee-text-inverse) 25%, transparent);
  color: var(--wiclee-text);
}

.wiclee-landing__btn--sm {
  min-height: 46px;
  padding: 0 18px;
  font-size: 14px;
  white-space: nowrap;
}

/* ---------- Cabecera ---------- */

.wiclee-landing__header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--wiclee-landing-header-h);
  padding-top: env(safe-area-inset-top, 0);
  background: var(--wiclee-bg-card);
  border-bottom: 1px solid var(--wiclee-border);
  color: var(--wiclee-text);
}

.wiclee-landing__header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  height: 100%;
}

.wiclee-landing__logo {
  display: block;
  flex: none;
}

.wiclee-landing__logo img {
  width: auto;
  height: 60px;
}

.wiclee-landing__nav {
  display: flex;
  gap: 40px;
  font-size: 16px;
  font-weight: 600;
  white-space: nowrap;
}

.wiclee-landing__nav-link {
  position: relative;
  color: inherit;
  text-decoration: none;
}

.wiclee-landing__nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -6px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s;
}

.wiclee-landing__nav-link:hover::after {
  transform: scaleX(1);
}

.wiclee-landing__header-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.wiclee-landing__access {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 10px;
  background: var(--wiclee-primary);
  color: var(--wiclee-text);
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color 0.25s;
}

.wiclee-landing__access:hover {
  background: var(--wiclee-primary-600);
  color: var(--wiclee-text);
}

.wiclee-landing__access .wiclee-landing__icon {
  width: 18px;
  height: 18px;
}

/* Menú móvil: botón verde de marca + panel (oculto con [hidden] hasta abrirse) */
.wiclee-landing__menu {
  display: none;
  position: relative;
}

.wiclee-landing__menu-button {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 46px;
  min-height: 46px;
  padding: 0;
  border: 0;
  border-radius: 10px;
  background: var(--wiclee-primary);
  color: var(--wiclee-text);
  cursor: pointer;
}

.wiclee-landing__menu-button[aria-expanded="true"] {
  background: var(--wiclee-primary-600);
}

.wiclee-landing__menu-button .wiclee-landing__icon {
  width: 24px;
  height: 24px;
}

.wiclee-landing__menu-panel {
  position: absolute;
  top: 58px;
  right: 0;
  display: flex;
  flex-direction: column;
  width: 260px;
  padding: 12px;
  background: var(--wiclee-bg-card);
  border: 1px solid var(--wiclee-border);
  border-radius: 12px;
  box-shadow: 0 20px 40px var(--wiclee-landing-ink-shadow);
}

.wiclee-landing__menu-panel[hidden] {
  display: none;
}

.wiclee-landing__menu-link {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 10px 12px;
  border-radius: 8px;
  color: var(--wiclee-text);
  font-weight: 600;
  text-decoration: none;
}

.wiclee-landing__menu-link:hover {
  background: var(--wiclee-primary-50);
  color: var(--wiclee-text);
}

.wiclee-landing__menu-link--cta {
  margin-top: 6px;
  background: var(--wiclee-accent);
  font-weight: 700;
}

.wiclee-landing__menu-link--cta:hover {
  background: var(--wiclee-accent-600);
}

.wiclee-landing__menu-link--access {
  margin-top: 6px;
  background: var(--wiclee-primary);
  font-weight: 700;
}

.wiclee-landing__menu-link--access:hover {
  background: var(--wiclee-primary-600);
}

.wiclee-landing__menu-link .wiclee-landing__icon {
  width: 18px;
  height: 18px;
}

/* ---------- Cabecera en anchos intermedios: sin desbordar y sin saltos de línea ---------- */

@media (max-width: 1560px) {
  .wiclee-landing__header-inner {
    gap: 24px;
  }

  .wiclee-landing__nav {
    gap: 28px;
    font-size: 15px;
  }
}

@media (max-width: 1320px) {
  .wiclee-landing__header-cta {
    display: none;
  }
}

@media (max-width: 1180px) {
  .wiclee-landing__nav,
  .wiclee-landing__access {
    display: none;
  }

  .wiclee-landing__menu {
    display: block;
  }
}

/* ---------- Pantallas pequeñas (≤1000 px): cabecera 76 px, gutter 20 px, ritmo 72 px ---------- */

@media (max-width: 1000px) {
  html {
    scroll-padding-top: 76px;
  }

  .wiclee-home {
    --wiclee-landing-header-h: 76px;
    --wiclee-landing-gutter: 20px;
    --wiclee-landing-section-y: 72px;
  }

  .wiclee-landing__logo img {
    height: 46px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
