/**
 * Kompostovanie page — design layer.
 *
 * The page is a hybrid: the chrome is the eco long-form shell
 * (pages/ekomaterialy.css — breadcrumb, leaf headline, sticky anchor nav,
 * .eko-content card, CTA band, feature strip) and the card's body is untouched
 * WPBakery editor content wearing .legal-doc__body (pages/legal.css), which
 * restyles the raw editor HTML. This sheet only carries what neither of those
 * two already gives, so it must load after both.
 *
 * Everything is scoped under .kompost so nothing leaks onto the other pages that
 * share those two sheets.
 */

/* ---- The WPBakery wrapper neutralizer, re-scoped ------------------------- */
/* pages/legal.css neutralizes the legacy vc_row / wpb_* wrappers (js_composer
 * renders them and ships its own margins/padding for them), but it scopes that
 * to .legal-doc — the legal pages' document card. This page's card is the
 * shell's .eko-content instead, so the same reset is re-pointed at it. Adding
 * .legal-doc to the markup is not an option: it would nest a second card
 * (max-width, border, padding, shadow) inside .eko-content. */
.kompost .eko-content .vc_row,
.kompost .eko-content .wpb_column,
.kompost .eko-content .vc_column-inner,
.kompost .eko-content .wpb_wrapper,
.kompost .eko-content .wpb_text_column,
.kompost .eko-content .wpb_content_element {
  margin: 0;
  padding: 0;
  width: auto;
  float: none;
  background: none;
  box-shadow: none;
}

/* ---- Document body copy: settle the two-sheet collision ------------------ */
/* .eko-content p (the shell) and .legal-doc__body p (legal) have equal
 * specificity, so source order alone would silently decide how the document
 * reads. This page is a document, so it keeps legal.css's reading typography
 * rather than the shell's shorter-form 15px/1.7 — pinned here so the result does
 * not depend on the enqueue order. */
.kompost .eko-content .legal-doc__body p {
  color: var(--ink-soft);
  font-size: 15.5px;
  line-height: 1.75;
  margin: 0 0 var(--space-4);
}

/* ---- Table head ---------------------------------------------------------- */
/* The legacy table marks its header row with <h4>s inside plain <td>s — it has
 * no <thead> and no <th>, so legal.css's "--teal-50 table head" (thead td, th)
 * never lands on it. Select the row by what the editor actually wrote rather
 * than by position: tbody tr:first-child would wrongly paint the first body row
 * of any future table that does carry a real <thead>. */
.kompost .legal-doc__body tr:has(> td h4) td {
  background: var(--teal-50);
  vertical-align: middle;
}
.kompost .legal-doc__body td h4 {
  margin: 0;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -.01em;
  line-height: 1.35;
}
/* Two comparable columns of short phrases read best evenly split; the header
 * cells are the shortest text in the table, so auto layout would starve them. */
.kompost .legal-doc__body table { table-layout: fixed; }

/* ---- CTA band ------------------------------------------------------------ */
/* The band follows the document body instead of the shell's .eko-sec (whose
 * 34px bottom margin normally opens this gap), so it gives itself the room. */
.kompost .eko-content > .eko-cta { margin-top: var(--space-7); }

/* ---- No-heading fallback ------------------------------------------------- */
/* The anchor nav is derived from the content's <h2>s. If an editor ever strips
 * them the aside is not rendered at all, and the card stands alone in the grid —
 * the shape the short company pages use. */
.kompost .kompost-layout--solo { grid-template-columns: minmax(0, 1fr); }
