/* Shared adapter for the retained kit and legacy footer DOM. No link reordering
   or body rewrites; specificity keeps this ahead of family export styles. */
body[data-content-template] footer.publication-footer[class]{
  width:100%;max-width:1280px;margin:0 auto;padding:20px 24px;
  display:grid;grid-template-columns:minmax(0,1fr) auto;gap:4px 24px;
  align-items:start;border-top:1px solid var(--kit-line,var(--line));
  background:transparent;color:var(--kit-muted,var(--secondary));
  font-family:inherit;font-size:13px;line-height:1.5;
}
body[data-content-template] footer.publication-footer[class]>div{
  min-width:0;max-width:none;margin:0;padding:0;display:grid;
  grid-template-columns:94px minmax(0,1fr);grid-template-rows:44px 44px;gap:0 16px;align-items:center;
  font:inherit;color:inherit;
}
body[data-content-template] footer.publication-footer[class] img{
  grid-column:1;grid-row:1;width:94px;height:auto;max-width:100%;
  content:url('/brand/kit/weem-logo-sobre-claro.svg');
}
html[data-theme=dark] body[data-content-template] footer.publication-footer[class] img{
  content:url('/brand/kit/weem-logo-sobre-oscuro.svg');
}
body[data-content-template] footer.publication-footer[class]>div>span:not(.mono):not(.weem-release){
  grid-column:2;grid-row:1;min-width:0;overflow-wrap:break-word;
}
body[data-content-template] footer.publication-footer[class] a{
  min-height:44px;display:inline-flex;align-items:center;
  color:var(--kit-ink,var(--ink));font:inherit;text-decoration:none;
}
body[data-content-template] footer.publication-footer[class] a:hover{text-decoration:underline}
body[data-content-template] footer.publication-footer[class] a:focus-visible{
  outline:2px solid var(--kit-ink,var(--ink));outline-offset:3px;border-radius:2px;
}
body[data-content-template] footer.publication-footer[class]>nav{
  min-width:0;display:grid;grid-template-columns:repeat(3,max-content);gap:0 16px;
  align-items:center;
}
body[data-content-template] footer.publication-footer[class]>nav>a[href='https://owncoding.dev/']{
  grid-column:1/-1;justify-self:end;
}
body[data-content-template] footer.publication-footer[class]>div>.weem-release{
  grid-column:2;grid-row:2;align-self:center;
}
body[data-content-template] footer.publication-footer[class] .weem-release,
body[data-content-template] footer.publication-footer[class] .mono,
body[data-content-template] footer.publication-footer[class] a[href='https://owncoding.dev/']{
  font-family:inherit;font-size:12px;letter-spacing:normal;
  color:var(--kit-muted,var(--secondary));padding:0;border:0;background:transparent;
}
body[data-content-template] footer.publication-footer[class] .weem-release::before{content:none}

/* The kit export owns one inner group rather than a separate nav. */
body[data-content-template] footer.publication-footer[class]:not(:has(>nav)){grid-template-columns:minmax(0,1fr)}
body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div{
  grid-template-columns:94px minmax(0,1fr) repeat(3,max-content);gap:0 16px;
}
body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div>a[href='/privacidad']{grid-column:3;grid-row:1}
body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div>a[href='/terminos']{grid-column:4;grid-row:1}
body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div>a[href='/status']{grid-column:5;grid-row:1}
body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div>a:is([href='/'],[href='/ecosistema']){
  grid-column:2;grid-row:2;font-size:12px;color:var(--kit-muted,var(--secondary));
}
body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div>.mono{
  grid-column:3/-1;grid-row:2;min-width:0;margin:0;text-align:right;display:block;
}
/* Compact tool/learning contracts omit the decorative img; keep their DOM
   intact and use the same approved master, with the adjacent WEEM legal name. */
body[data-content-template] footer.publication-footer[class]>div:not(:has(>img))::before{
  content:'';grid-column:1;grid-row:1;display:block;width:94px;height:23px;
  background:url('/brand/kit/weem-logo-sobre-claro.svg') left center/contain no-repeat;
}
html[data-theme=dark] body[data-content-template] footer.publication-footer[class]>div:not(:has(>img))::before{
  background-image:url('/brand/kit/weem-logo-sobre-oscuro.svg');
}

@media(max-width:760px){
  body[data-content-template] footer.publication-footer[class]{
    grid-template-columns:minmax(0,1fr);padding:16px;gap:8px;
  }
  body[data-content-template] footer.publication-footer[class]>nav{
    justify-self:start;gap:0 20px;
  }
  body[data-content-template] footer.publication-footer[class]>div{grid-template-rows:auto auto}
  body[data-content-template] footer.publication-footer[class]>nav>a[href='https://owncoding.dev/']{justify-self:start}
  body[data-content-template] footer.publication-footer[class]>div>span:not(.mono):not(.weem-release){font-size:12px}
  body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div{
    grid-template-columns:repeat(6,minmax(0,1fr));gap:0 8px;
  }
  body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div>img,
  body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div::before{grid-column:1/3}
  body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div>span:not(.mono):not(.weem-release){grid-column:3/-1}
  body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div>a:is([href='/'],[href='/ecosistema']){grid-column:1/-1;grid-row:2}
  body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div>a[href='/privacidad']{grid-column:1/3;grid-row:3}
  body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div>a[href='/terminos']{grid-column:3/5;grid-row:3}
  body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div>a[href='/status']{grid-column:5/-1;grid-row:3}
  body[data-content-template] footer.publication-footer[class]:not(:has(>nav))>div>.mono{grid-column:1/-1;grid-row:4;text-align:left}
}
