/* =========================================================================
   VERDEA v3 — cabecera y pie únicos para todo el sitio (los genera
   js/navigation.js). Clases propias (cab-*, pie-*) para no chocar con los
   estilos de las páginas existentes.
   ========================================================================= */

.cabecera {
  position: sticky; top: 0; z-index: 50; width: 100%;
  background: rgba(7, 19, 13, .82); border-bottom: 1px solid rgba(193, 214, 197, .1);
  font-family: "Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  transition: background .4s cubic-bezier(.2, .7, .2, 1), border-color .4s;
}
@supports (backdrop-filter: blur(12px)) { .cabecera { background: rgba(7, 19, 13, .64); backdrop-filter: blur(14px) saturate(140%); } }
/* En la portada y en páginas con cabeza ilustrada la cabecera flota sobre el contenido */
body.flota .cabecera { position: fixed; inset: 0 0 auto; background: transparent; border-bottom-color: transparent; backdrop-filter: none; }
body.flota .cabecera.con-fondo { background: rgba(7, 19, 13, .64); border-bottom-color: rgba(193, 214, 197, .1); }
@supports (backdrop-filter: blur(12px)) { body.flota .cabecera.con-fondo { backdrop-filter: blur(14px) saturate(140%); } }

.cab-fila { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); height: 74px; display: flex; align-items: center; gap: 28px; }
.cab-logo { flex: none; display: block; }
.cab-logo img { height: 23px; width: auto; display: block; }
.cab-links { display: none; align-items: center; gap: 28px; margin: 0 auto; }
.cab-links a { position: relative; padding: 8px 1px; color: #c0ccc2; font-size: .92rem; text-decoration: none; white-space: nowrap; transition: color .25s; }
.cab-links a::after { content: ""; position: absolute; left: 50%; bottom: 0; width: 4px; height: 4px; border-radius: 50%; background: #a5d66b; transform: translateX(-50%) scale(0); transition: transform .3s cubic-bezier(.2, .7, .2, 1); }
.cab-links a:hover, .cab-links a[aria-current="page"] { color: #f1f5ef; }
.cab-links a:hover::after, .cab-links a[aria-current="page"]::after { transform: translateX(-50%) scale(1); }
.cab-acciones { display: flex; align-items: center; gap: 14px; margin-left: auto; min-width: 0; }
.cab-links + .cab-acciones { margin-left: 0; }
.cab-ingresar { color: #c0ccc2; font-size: .92rem; text-decoration: none; white-space: nowrap; }
.cab-ingresar:hover { color: #f1f5ef; }
.cab-cta {
  display: inline-flex; align-items: center; min-height: 40px; padding: 0 18px; border-radius: 999px; white-space: nowrap;
  background: #a5d66b; color: #07130d; font: 600 .9rem/1 "Plex Sans", system-ui, sans-serif; text-decoration: none;
  box-shadow: 0 0 0 1px rgba(165, 214, 107, .4), 0 10px 32px -14px rgba(165, 214, 107, .6);
  transition: transform .3s cubic-bezier(.2, .7, .2, 1), background .2s;
}
.cab-cta:hover { background: #b8e083; transform: translateY(-1px); }

/* Cuenta iniciada: nombre recortado para que nunca se salga */
.cab-cuenta { position: relative; min-width: 0; }
.cab-cuenta summary { list-style: none; display: flex; align-items: center; gap: 9px; max-width: 210px; min-height: 40px; padding: 4px 12px 4px 4px; border-radius: 999px; border: 1px solid rgba(193, 214, 197, .2); color: #f1f5ef; font-size: .88rem; cursor: pointer; transition: border-color .25s; }
.cab-cuenta summary::-webkit-details-marker { display: none; }
.cab-cuenta summary:hover, .cab-cuenta[open] summary { border-color: #76b85b; }
.cab-avatar { flex: none; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; background: #193d2b; color: #a5d66b; font: 600 .72rem/1 "Plex Sans", sans-serif; letter-spacing: .02em; }
.cab-nombre { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cab-panel { position: absolute; right: 0; top: calc(100% + 10px); width: 250px; padding: 8px; border-radius: 12px; background: #10271b; border: 1px solid rgba(193, 214, 197, .16); box-shadow: 0 24px 60px -20px rgba(0, 0, 0, .8); }
.cab-panel strong { display: block; padding: 10px 12px 12px; margin-bottom: 4px; border-bottom: 1px solid rgba(193, 214, 197, .12); color: #89978d; font: 400 .8rem/1.3 "Plex Sans", sans-serif; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cab-panel a, .cab-panel button { display: block; width: 100%; padding: 10px 12px; border: 0; border-radius: 8px; background: none; color: #f1f5ef; font: 400 .92rem/1.3 "Plex Sans", sans-serif; text-align: left; text-decoration: none; cursor: pointer; }
.cab-panel a:hover, .cab-panel button:hover { background: rgba(118, 184, 91, .1); color: #a5d66b; }

/* Menú en celulares */
.cab-boton { flex: none; width: 44px; height: 44px; display: grid; place-items: center; margin-left: 4px; border-radius: 50%; border: 1px solid rgba(193, 214, 197, .24); background: rgba(241, 245, 239, .04); color: #f1f5ef; cursor: pointer; }
.cab-boton span, .cab-boton span::before, .cab-boton span::after { display: block; width: 16px; height: 1.5px; background: currentColor; transition: transform .3s cubic-bezier(.2, .7, .2, 1), background .2s; }
.cab-boton span { position: relative; }
.cab-boton span::before, .cab-boton span::after { content: ""; position: absolute; left: 0; }
.cab-boton span::before { top: -5px; } .cab-boton span::after { top: 5px; }
.cab-boton[aria-expanded="true"] span { background: transparent; }
.cab-boton[aria-expanded="true"] span::before { transform: translateY(5px) rotate(45deg); }
.cab-boton[aria-expanded="true"] span::after { transform: translateY(-5px) rotate(-45deg); }
.cab-movil { display: none; max-height: calc(100svh - 74px); overflow-y: auto; padding: 6px clamp(16px, 4vw, 40px) 26px; background: rgba(7, 19, 13, .98); border-top: 1px solid rgba(193, 214, 197, .1); }
.cab-movil.abierto { display: block; }
.cab-movil a, .cab-movil button.cab-salir { display: block; width: 100%; padding: 14px 0; border: 0; border-bottom: 1px solid rgba(193, 214, 197, .1); background: none; color: #f1f5ef; font: 500 1.2rem/1.3 "Plex Sans", sans-serif; letter-spacing: -.01em; text-align: left; text-decoration: none; cursor: pointer; }
.cab-movil a[aria-current="page"] { color: #a5d66b; }
.cab-movil .cab-cta { display: flex; justify-content: center; align-items: center; margin-top: 22px; min-height: 50px; border: 0; background: #a5d66b; color: #07130d; font-size: 1rem; font-weight: 600; }
.cab-movil-cuenta { margin-top: 10px; padding: 12px 0 2px; color: #89978d; font-size: .85rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 559px) { .cab-acciones .cab-cta, .cab-acciones .cab-ingresar, .cab-acciones .cab-cuenta { display: none; } }
@media (min-width: 560px) and (max-width: 979px) { .cab-acciones .cab-ingresar { display: none; } }
@media (min-width: 980px) { .cab-links { display: flex; } .cab-boton, .cab-movil, .cab-movil.abierto { display: none; } }
@media (min-width: 980px) and (max-width: 1140px) { .cab-links { gap: 20px; } .cab-links a { font-size: .88rem; } .cab-fila { gap: 20px; } }

/* Pie */
.pie { margin-top: auto; padding: 64px 0 34px; background: #091711; border-top: 1px solid rgba(193, 214, 197, .12); color: #89978d; font: 400 .92rem/1.6 "Plex Sans", system-ui, sans-serif; }
.pie-contenido { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); }
.pie-grilla { display: grid; gap: 34px; }
.pie-logo img { height: 22px; width: auto; margin-bottom: 16px; display: block; }
.pie-lema { margin: 0; max-width: 24em; color: #c0ccc2; }
.pie-columna { display: grid; align-content: start; gap: 10px; }
.pie-columna b { margin-bottom: 4px; color: #f1f5ef; font: 500 .76rem/1.4 "Plex Mono", ui-monospace, monospace; letter-spacing: .1em; text-transform: uppercase; }
.pie a { color: #a3b0a6; text-decoration: none; transition: color .2s; }
.pie a:hover { color: #a5d66b; }
.pie-base { margin-top: 48px; padding-top: 20px; border-top: 1px solid rgba(193, 214, 197, .12); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; font: 400 .76rem/1.5 "Plex Mono", ui-monospace, monospace; letter-spacing: .03em; }
@media (min-width: 760px) { .pie-grilla { grid-template-columns: 1.5fr 1fr 1fr 1fr; } }

/* Aviso del sitio de prueba */
.aviso-prueba { position: relative; z-index: 60; margin: 0; padding: 9px 16px; background: #e2c46a; color: #07130d; font: 600 .82rem/1.4 "Plex Sans", system-ui, sans-serif; text-align: center; }
body.flota .aviso-prueba { position: fixed; inset: auto 0 0; }
