/* WS Editore — EL MARCO (ola 1, 16-oct-2026)
   Copia fiel del Sistema de Diseño:
   · W-27 La botonera — escritorio 84 px (64 px tras 80 px de scroll, con sombra),
     once botones de 44 px (radio 22, padding 0 12, Karla 14/500), WhatsApp 44 px.
     Móvil: barra 72 px, botón «Menú» 48 px, filas 56 px, WhatsApp 52 px.
     Estados: normal · hover · presionado · foco (anillo teal 3 px a 2 px) · página actual
     (600 + barra dorada 3 px). Transición 120 ms. Menú móvil: altura en 240 ms.
   · W-19 El pie — Tinta cálida, 3 columnas, logotipo crema 72 px, enlaces 15 px,
     línea legal 13 px; móvil en una columna.
   · W-28 El movimiento — curva cubic-bezier(.2,.7,.2,1), freno con prefers-reduced-motion.
   Los nombres que usa main.js se conservan: .site-header · .is-scrolled · .nav-toggle ·
   .main-nav · .open · aria-expanded. */

/* ============ W-27 · LA BOTONERA ============ */
.site-header.wsb{
  position: sticky; top: 0; z-index: 60;
  background: #fbf9f4;
  border-bottom: 1px solid #d6cec2;
  backdrop-filter: none;
  font-family: "Karla", system-ui, sans-serif;
  color: #3c4650;
  transition: box-shadow .12s ease;
}
.site-header.wsb.is-scrolled{ box-shadow: 0 2px 12px rgba(62,49,40,.12); }
.wsb__in{
  max-width: 1440px; margin: 0 auto; box-sizing: border-box;
  height: 84px; padding: 0 40px;
  display: flex; align-items: center; gap: 16px;
  transition: height .12s ease;
}
.site-header.wsb.is-scrolled .wsb__in{ height: 64px; }

.wsb__brand{ display: flex; align-items: center; gap: 12px; flex: none; color: inherit; text-decoration: none; border-radius: 12px; outline: none; }
.wsb__brand:hover{ color: inherit; }
.wsb__brand:focus-visible{ box-shadow: 0 0 0 2px #fbf9f4, 0 0 0 5px #0e5a6f; outline: none; }
.wsb__brand img{ height: 40px; width: auto; display: block; }
.wsb__name{ display: flex; flex-direction: column; line-height: 1; }
.wsb__t{ font-family: "Fraunces", Georgia, serif; font-weight: 600; font-size: 20px; letter-spacing: -0.01em; color: #1f252c; }
.wsb__s{ font-family: "JetBrains Mono", ui-monospace, monospace; font-size: 9px; letter-spacing: .16em; text-transform: uppercase; color: #b68c4a; margin-top: 4px; }

.site-header.wsb .main-nav{
  display: flex; gap: 2px; margin-left: auto; align-items: center;
  position: static; padding: 0; background: none; border: 0; flex-direction: row;
}
.site-header.wsb .main-nav a{
  position: relative;
  height: 44px; display: flex; align-items: center; padding: 0 12px; width: auto;
  border-radius: 22px; border: 0;
  font-family: "Karla", system-ui, sans-serif; font-size: 14px; font-weight: 500;
  color: #3c4650; text-decoration: none; white-space: nowrap; outline: none;
  transition: background .12s ease, color .12s ease, transform .12s ease;
}
.site-header.wsb .main-nav a:hover{ background: #f5ecdd; color: #a55a3b; }
.site-header.wsb .main-nav a:active{ background: #eae3d7; color: #a55a3b; transform: translateY(1px); }
.site-header.wsb .main-nav a:focus-visible{ box-shadow: 0 0 0 2px #fbf9f4, 0 0 0 5px #0e5a6f; outline: none; border-radius: 22px; }
.site-header.wsb .main-nav a[aria-current="page"]{ font-weight: 600; color: #a55a3b; background: transparent; }
.site-header.wsb .main-nav a[aria-current="page"]::after{
  content: ""; position: absolute; left: 12px; right: 12px; bottom: 4px;
  height: 3px; border-radius: 2px; background: #b68c4a;
}
.site-header.wsb .main-nav a.wsb__wa-m{ display: none; }

.wsb__wa{
  flex: none; height: 44px; display: flex; align-items: center; gap: 8px;
  padding: 0 18px; border-radius: 22px; background: #25d366; color: #1f252c;
  font: 700 14px "Karla", system-ui, sans-serif; text-decoration: none; white-space: nowrap; outline: none;
  transition: background .12s ease, transform .12s ease;
}
.wsb__wa:hover{ background: #1eb356; color: #1f252c; }
.wsb__wa:active{ transform: translateY(1px); }
.wsb__wa:focus-visible{ box-shadow: 0 0 0 2px #fbf9f4, 0 0 0 5px #0e5a6f; outline: none; }
.wsb__dot{ width: 8px; height: 8px; border-radius: 50%; background: #1f252c; display: block; flex: none; }

.site-header.wsb .nav-toggle{ display: none; }

/* Medido con el navegador: la botonera entera (marca 185 + once botones 980 + WhatsApp 158)
   pide 1440 px. Entre 1280 y 1439 px los botones conservan sus 44 px de alto y solo
   ceden aire lateral (12 → 6 px); por debajo de 1280 px pasa al panel «Menú» (W-27c). */
@media (min-width: 1280px) and (max-width: 1439px){
  .wsb__in{ padding: 0 20px; }
  .site-header.wsb .main-nav{ gap: 0; }
  .site-header.wsb .main-nav a{ padding: 0 clamp(6px, calc((100vw - 1140px) / 22), 12px); }
  .site-header.wsb .main-nav a[aria-current="page"]::after{ left: clamp(6px, calc((100vw - 1140px) / 22), 12px); right: clamp(6px, calc((100vw - 1140px) / 22), 12px); }
}
@media (max-width: 1279px){
  .wsb__in, .site-header.wsb.is-scrolled .wsb__in{ height: 72px; padding: 0 16px; gap: 10px; }
  .wsb__brand{ gap: 10px; }
  .wsb__brand img{ height: 36px; }
  .wsb__t{ font-size: 18px; }
  .wsb__s{ font-size: 8px; }
  .wsb__wa{ display: none; }

  .site-header.wsb .nav-toggle{
    margin-left: auto; height: 48px; min-width: 48px; padding: 0 14px; border-radius: 24px;
    border: 1px solid #d6cec2; background: #fbf9f4; color: #1f252c;
    font: 600 13px "Karla", system-ui, sans-serif;
    display: flex; align-items: center; gap: 8px; cursor: pointer; outline: none;
    transition: background .12s ease;
  }
  .site-header.wsb .nav-toggle:hover{ background: #f5ecdd; }
  .site-header.wsb .nav-toggle:active{ background: #eae3d7; }
  .site-header.wsb .nav-toggle:focus-visible{ box-shadow: 0 0 0 2px #fbf9f4, 0 0 0 5px #0e5a6f; outline: none; }
  .wsb__burger{ display: flex; flex-direction: column; gap: 4px; }
  .wsb__burger i{ width: 18px; height: 2px; background: #1f252c; display: block; transition: transform .24s cubic-bezier(.2,.7,.2,1), opacity .12s ease; }
  .nav-toggle[aria-expanded="true"] .wsb__burger i:nth-child(1){ transform: translateY(6px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] .wsb__burger i:nth-child(2){ opacity: 0; }
  .nav-toggle[aria-expanded="true"] .wsb__burger i:nth-child(3){ transform: translateY(-6px) rotate(-45deg); }

  /* Panel: altura en 240 ms (W-28 · 03). Siempre en el DOM para poder animar. */
  .site-header.wsb .main-nav{
    position: absolute; top: 100%; left: 0; right: 0; margin: 0;
    display: flex; flex-direction: column; align-items: stretch; gap: 2px;
    background: #fbf9f4; border-bottom: 1px solid #d6cec2;
    padding: 0 8px; max-height: 0; overflow: hidden; visibility: hidden;
    transition: max-height .24s cubic-bezier(.2,.7,.2,1), padding .24s cubic-bezier(.2,.7,.2,1), visibility 0s linear .24s;
  }
  .site-header.wsb .main-nav.open{
    max-height: calc(100vh - 72px); overflow-y: auto; visibility: visible;
    padding: 8px 8px 16px;
    transition: max-height .24s cubic-bezier(.2,.7,.2,1), padding .24s cubic-bezier(.2,.7,.2,1), visibility 0s;
    box-shadow: 0 12px 24px rgba(62,49,40,.12);
  }
  .site-header.wsb .main-nav a{
    height: 56px; flex: none; padding: 0 16px; border-radius: 12px; font-size: 17px; font-weight: 500;
    border-left: 3px solid transparent; width: auto;
  }
  .site-header.wsb .main-nav a:focus-visible{ box-shadow: inset 0 0 0 2px #0e5a6f; border-radius: 12px; }
  .site-header.wsb .main-nav a[aria-current="page"]{ font-weight: 600; color: #a55a3b; background: #f8f1e7; border-left-color: #b68c4a; }
  .site-header.wsb .main-nav a[aria-current="page"]::after{ display: none; }
  .site-header.wsb .main-nav a.wsb__wa-m{
    display: flex; margin: 12px 8px 0; height: 52px; justify-content: center; gap: 8px;
    border-radius: 26px; border-left: 0; background: #25d366; color: #1f252c; font-size: 16px; font-weight: 700;
  }
  .site-header.wsb .main-nav a.wsb__wa-m:hover{ background: #1eb356; color: #1f252c; }
}

/* ============ W-19 · EL PIE ============ */
.site-footer.wsf{
  background: #3e3128; color: #f8f1e7; padding: 0;
  font-family: "Karla", system-ui, sans-serif;
}
.wsf__in{ max-width: 1440px; margin: 0 auto; box-sizing: border-box; padding: 64px 80px 28px; }
.wsf__grid{ display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 48px; }
.wsf__logo{ height: 72px; width: auto; display: block; margin-left: -6px; }
.wsf__txt{ margin: 16px 0 0; font-size: 15px; line-height: 1.5; color: #e8dcc9; max-width: 360px; }
.wsf__tag{ margin: 18px 0 0; font-family: "JetBrains Mono", ui-monospace, monospace; font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: #c79a52; }
.wsf__h{ margin: 0 0 14px; font-family: "JetBrains Mono", ui-monospace, monospace; font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: #c79a52; }
.wsf__list{ display: flex; flex-direction: column; align-items: flex-start; gap: 10px; font-size: 15px; }
.wsf__list a{ color: #f8f1e7; text-decoration: none; border-radius: 4px; outline: none; transition: color .12s ease; }
.wsf__list a:hover{ color: #c79a52; text-decoration: underline; text-underline-offset: 3px; }
.wsf__list a:focus-visible{ box-shadow: 0 0 0 2px #3e3128, 0 0 0 5px #c79a52; outline: none; }
.wsf__legal{
  margin-top: 36px; padding-top: 20px; border-top: 1px solid #56493d;
  display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between;
  font-size: 13px; color: #cdbfa9;
}
@media (max-width: 760px){
  .wsf__in{ padding: 40px 20px 24px; }
  .wsf__grid{ grid-template-columns: 1fr; gap: 32px; }
}

/* ============ W-28 · EL MOVIMIENTO (piezas nuevas) ============ */
[data-reveal]{ opacity: 0; transform: translateY(14px); transition: opacity .48s cubic-bezier(.2,.7,.2,1), transform .48s cubic-bezier(.2,.7,.2,1); }
[data-reveal="in"], [data-reveal="done"]{ opacity: 1; transform: none; }
[data-lift]{ transition: transform .18s ease, box-shadow .18s ease; }
[data-reveal][data-lift]{ transition: opacity .48s cubic-bezier(.2,.7,.2,1), transform .48s cubic-bezier(.2,.7,.2,1), box-shadow .18s ease; }
[data-reveal="done"][data-lift]{ transition: transform .18s ease, box-shadow .18s ease; }
[data-lift]:hover{ transform: translateY(-3px); box-shadow: 0 10px 24px rgba(62,49,40,.14); }

/* FRENO: quien pide menos, recibe nada — todo quieto y visible. */
html[data-motion="reducido"] [data-reveal], html[data-motion="reducido"] [data-lift]{ transition: none !important; opacity: 1; transform: none !important; }
@media (prefers-reduced-motion: reduce){
  [data-reveal], [data-lift]{ transition: none !important; opacity: 1; transform: none !important; }
  .site-header.wsb, .wsb__in, .site-header.wsb .main-nav, .site-header.wsb .main-nav a, .wsb__wa, .wsb__burger i, .wsf__list a{ transition: none !important; }
}
@media print{ [data-reveal]{ opacity: 1; transform: none; transition: none; } }
