/* Marek Kloc Brand Book 2027 — site-wide RELEASE CANDIDATE v0.17 (public flag OFF).
 * Public rollout remains OFF unless the local public.enabled flag is deliberately
 * created after mobile, accessibility, consent and functional smoke tests pass.
 * All rules require body.mkb27-preview (administrator) or body.mkb27-public
 * (explicit public rollout). Distinct MK360 tools/forms stay autonomous.
 * Source-of-truth logo palette: blue #27519B, gold #E9B538, black, white.
 */

/* Shared typographic foundation, contained within the frontend WordPress shell. */
html body:is(.mkb27-preview,.mkb27-public) {
  --mkb27-blue:#27519B;
  --mkb27-gold:#E9B538;
  --mkb27-text:#000000;
  --mkb27-surface:#FFFFFF;
  --mkb27-kicker-bg:linear-gradient(rgba(0,0,0,.20),rgba(0,0,0,.20)),#27519B;
  --mkb27-font:"Manrope",Arial,Helvetica,sans-serif;
  font-family:var(--mkb27-font);
}
html body:is(.mkb27-preview,.mkb27-public) :is(.site-header,header#masthead,.navbar) :is(a,button,.nav-link) {
  font-family:var(--mkb27-font);
}
html body:is(.mkb27-preview,.mkb27-public) :is(.entry-header,.entry-content,.wp-block-post-content) {
  font-family:var(--mkb27-font);
}
/* Native WordPress headings and article content; no selectors for form labels,
 * buttons, calculators, pricing tools, custom plugin UI, or icon fonts. */
/* Approved blog hierarchy: H1 in elegant dark navy, H2 in logo blue. */
html body:is(.mkb27-preview,.mkb27-public).single-post h1.entry-title {
  color:#253544 !important; /* Override legacy theme title colour only on posts. */
  font-family:var(--mkb27-font);
}
html body:is(.mkb27-preview,.mkb27-public).single-post .entry-content :is(h2,.wp-block-heading) {
  color:#27519B;
  font-family:var(--mkb27-font);
}
html body:is(.mkb27-preview,.mkb27-public).single-post .entry-content h3 {
  color:#000000;
  font-family:var(--mkb27-font);
}
html body:is(.mkb27-preview,.mkb27-public).single-post .entry-content :is(p,li,blockquote) {
  font-family:var(--mkb27-font);
}
html body:is(.mkb27-preview,.mkb27-public).single-post .entry-content :is(p,li) > a,
html body:is(.mkb27-preview,.mkb27-public).single-post .mk-article-toc a {
  color:#27519B;
  text-underline-offset:.16em;
}
html body:is(.mkb27-preview,.mkb27-public).single-post .entry-content :is(a,button,input,textarea,select):focus-visible {
  outline:3px solid #E9B538;
  outline-offset:3px;
}
/* Theme-controlled page titles; leave app/shortcode components untouched. */
html body:is(.mkb27-preview,.mkb27-public).page .entry-header .entry-title {
  color:#27519B;
  font-family:var(--mkb27-font);
}
html body:is(.mkb27-preview,.mkb27-public).page .entry-content > :is(h2,h3,.wp-block-heading) {
  color:#27519B;
  font-family:var(--mkb27-font);
}
html body:is(.mkb27-preview,.mkb27-public).page .entry-content > p > a {
  color:#27519B;
}
/* Front-page Wordpress blocks: preserve photographs, brand/social platform logos,
 * embedded video, and the existing hero layout. */
html body:is(.mkb27-preview,.mkb27-public).page-id-9216 .entry-content h1.wp-block-heading {
  color:#27519B;
  font-family:var(--mkb27-font)!important; /* page uses inline font-family */
}
html body:is(.mkb27-preview,.mkb27-public).page-id-9216 .mk-testimonials {
  --mk-gold:#E9B538;
  --mk-text:#000000;
  --mk-muted:rgba(0,0,0,.70);
}
html body:is(.mkb27-preview,.mkb27-public).page-id-9216 .mk-testimonials__title { color:#27519B; }
html body:is(.mkb27-preview,.mkb27-public).page-id-9216 .mk-media-more a { color:#27519B!important; }
/* Keep social platform native colours and partner marks intact. */

/* Hub poradnika sprzedaży — its inline CSS uses !important for blue H2/H3. */
html body:is(.mkb27-preview,.mkb27-public).page-id-911651 #post-911651 .entry-title {
  color:#27519B;
}
html body:is(.mkb27-preview,.mkb27-public).page-id-911651 .mk-hub-2026 :is(h2,h3) {
  color:#27519B!important;
}
html body:is(.mkb27-preview,.mkb27-public).page-id-911651 .mk-hub-2026 .cta {
  border-left-color:#27519B;
  background:rgba(0,0,0,.03);
}
html body:is(.mkb27-preview,.mkb27-public).page-id-911651 .mk-hub-2026 a { color:#27519B; }

/* Prezenty: preserve gift page content and responsive cards; unify only its
 * private colour variables and brand-specific content elements. */
html body:is(.mkb27-preview,.mkb27-public).page-id-912322 .mk-prezenty {
  --mk-blue:#27519B;
  --mk-navy:#27519B;
  --mk-ink:#000000;
  --mk-muted:rgba(0,0,0,.74);
  --mk-border:rgba(0,0,0,.13);
  --mk-bg:rgba(0,0,0,.03);
  font-family:var(--mkb27-font);
}
html body:is(.mkb27-preview,.mkb27-public).page-id-912322 .mk-prezenty .mk-hero {
  background:linear-gradient(120deg,rgba(0,0,0,.05),rgba(0,0,0,.28)),#27519B;
}
html body:is(.mkb27-preview,.mkb27-public).page-id-912322 .mk-prezenty .mk-kicker,
html body:is(.mkb27-preview,.mkb27-public).page-id-912322 .mk-prezenty .mk-eyebrow {
  display:inline-block;
  width:fit-content;
  max-width:100%;
  padding:6px 10px;
  border-radius:6px;
  background:var(--mkb27-kicker-bg);
  color:#E9B538;
  font-weight:800;
  line-height:1.45;
}
html body:is(.mkb27-preview,.mkb27-public).page-id-912322 .mk-prezenty .mk-hero .mk-kicker {
  border:1px solid rgba(233,181,56,.55);
}
html body:is(.mkb27-preview,.mkb27-public).page-id-912322 .mk-prezenty .mk-section h2 { color:#27519B; }
html body:is(.mkb27-preview,.mkb27-public).page-id-912322 .mk-prezenty .mk-hero :is(h2,p) { color:#FFFFFF; }
html body:is(.mkb27-preview,.mkb27-public).page-id-912322 .mk-prezenty :is(.mk-trust strong,.mk-mark,.mk-card .mk-type) {
  color:#27519B;
}
html body:is(.mkb27-preview,.mkb27-public).page-id-912322 .mk-prezenty a:focus-visible {
  outline:3px solid #E9B538;
  outline-offset:3px;
}

/* Visible diagnostic label on pages without the older per-page badge. */
html body.mkb27-preview:not(.page-id-11):not(.page-id-911415):not(.page-id-912307):not(.page-id-911221)::after {
  content:"PODGLĄD GLOBALNY 2027 · ADMIN";
  position:fixed;
  bottom:12px;
  right:12px;
  z-index:2147483000;
  padding:9px 13px;
  border:2px solid #E9B538;
  border-radius:8px;
  background:#27519B;
  color:#FFFFFF;
  font:700 12px/1.3 "Manrope",Arial,sans-serif;
  pointer-events:none;
  box-shadow:0 4px 15px rgba(0,0,0,.24);
}
@media(max-width:600px) {
  html body.mkb27-preview:not(.page-id-11):not(.page-id-911415):not(.page-id-912307):not(.page-id-911221)::after {
    bottom:8px;
    right:8px;
    font-size:10px;
  }
  html body:is(.mkb27-preview,.mkb27-public).page-id-912322 .mk-prezenty :is(.mk-kicker,.mk-eyebrow) {
    max-width:100%;
    overflow-wrap:anywhere;
  }
}
@media(prefers-reduced-motion:reduce) {
  html body:is(.mkb27-preview,.mkb27-public).page-id-912322 .mk-prezenty .mk-hero a.mk-button {
    transition:none;
  }
}

/* Precise brand corrections requested after desktop homepage screenshot.
 * Legacy homepage wrapper has inline gold (#F8B626) on the parent SPAN,
 * while a theme link rule renders "Dowiedz się więcej" in bright old blue.
 */
html body:is(.mkb27-preview,.mkb27-public).page-id-9216 .mk-home-intro-row a[href="https://marekkloc.pl/o-mnie/"] {
  color:#27519B !important;
  text-decoration-color:#27519B;
}
html body:is(.mkb27-preview,.mkb27-public).page-id-9216 .mk-home-intro-row a[href="https://marekkloc.pl/o-mnie/"]:focus-visible {
  outline:3px solid #E9B538;
  outline-offset:3px;
}
/* "Nieruchomości" is a classic-menu item whose href ends in /property/.
 * Match exactly the archive suffix, never individual property card URLs.
 * Text and outline use the same source-logo blue, not legacy #1b76af.
 */
html body:is(.mkb27-preview,.mkb27-public) a[href$="/property/"] {
  color:#27519B !important;
  border-color:#27519B !important;
}
html body:is(.mkb27-preview,.mkb27-public) a[href$="/property/"] :is(span,i) {
  color:#27519B !important;
}
html body:is(.mkb27-preview,.mkb27-public) a[href$="/property/"]::before,
html body:is(.mkb27-preview,.mkb27-public) a[href$="/property/"]::after {
  border-color:#27519B !important;
}
/* Override prior single-page adapter (About) whose gold outline was injected
 * later in the <head>, to keep one consistent navigation treatment. */
html body.page-id-11:is(.mkb27-preview,.mkb27-public) a[href$="/property/"],
html body.page-id-11:is(.mkb27-preview,.mkb27-public) a[href$="/property/"]::before,
html body.page-id-11:is(.mkb27-preview,.mkb27-public) a[href$="/property/"]::after {
  border-color:#27519B !important;
}

/* Editorial balance v0.14: a blog article must read as an article,
 * not an ocean of blue. H2 = brand landmarks, H3 = dark supporting hierarchy;
 * TOC = dark and quiet; links are blue only where they are actionable.
 * Specific !important on H3 counters legacy theme heading declarations.
 */
html body:is(.mkb27-preview,.mkb27-public).single-post .entry-content h2 {
  color:#27519B !important;
  font-weight:750;
}
html body:is(.mkb27-preview,.mkb27-public).single-post .entry-content h3,
html body:is(.mkb27-preview,.mkb27-public).single-post .entry-content h3.wp-block-heading {
  color:#253544 !important;
  font-weight:700;
}
html body:is(.mkb27-preview,.mkb27-public).single-post .entry-content :is(h4,h5,h6) {
  color:#253544 !important;
}
html body:is(.mkb27-preview,.mkb27-public).single-post .mk-article-toc a,
html body:is(.mkb27-preview,.mkb27-public).single-post .entry-content nav.mk-article-toc a {
  color:#253544 !important;
  text-decoration:none;
}
html body:is(.mkb27-preview,.mkb27-public).single-post .mk-article-toc a:hover,
html body:is(.mkb27-preview,.mkb27-public).single-post .mk-article-toc a:focus-visible {
  color:#27519B !important;
  text-decoration:underline;
  text-underline-offset:.17em;
}
html body:is(.mkb27-preview,.mkb27-public).single-post .entry-content p > a,
html body:is(.mkb27-preview,.mkb27-public).single-post .entry-content li > a {
  color:#27519B;
  text-decoration:underline;
  text-underline-offset:.18em;
}

/* Brand Book 2027: native MK Cookie Consent, visual-only adapter.
 * Source verified on Zenbox: mu-plugins/mk-cookie-assets/consent.css.
 * Keep the first-party plugin/consent.js untouched. No hidden, consent,
 * event, tracking, click handling or preference semantics are modified.
 * Scoped to admin preview, and later separately controlled public flag.
 */
html body:is(.mkb27-preview,.mkb27-public) :is(.mk-cc-banner,.mk-cc-dialog) {
  font-family:var(--mkb27-font);
  color:#253544;
  border-color:rgba(39,81,155,.28);
}
html body:is(.mkb27-preview,.mkb27-public) .mk-cc-banner p,
html body:is(.mkb27-preview,.mkb27-public) .mk-cc-dialog p {
  color:#253544;
}
html body:is(.mkb27-preview,.mkb27-public) .mk-cc-dialog h2 {
  color:#253544;
  font-family:var(--mkb27-font);
}
html body:is(.mkb27-preview,.mkb27-public) :is(.mk-cc-banner,.mk-cc-dialog) a {
  color:#27519B;
  text-decoration:underline;
  text-underline-offset:.17em;
}
html body:is(.mkb27-preview,.mkb27-public) :is(.mk-cc-banner,.mk-cc-dialog) button {
  background:#FFFFFF;
  border-color:#27519B;
  color:#27519B;
  font:650 14px/1.25 var(--mkb27-font);
}
html body:is(.mkb27-preview,.mkb27-public) :is(.mk-cc-banner,.mk-cc-dialog) button:hover {
  background:rgba(39,81,155,.065);
}
html body:is(.mkb27-preview,.mkb27-public) :is(.mk-cc-banner,.mk-cc-dialog) button:is(.mk-cc-primary,[data-mk-cc-action="reject"]) {
  background:#27519B;
  border-color:#27519B;
  color:#FFFFFF;
}
html body:is(.mkb27-preview,.mkb27-public) :is(.mk-cc-banner,.mk-cc-dialog) button:is(.mk-cc-primary,[data-mk-cc-action="reject"]):hover {
  background:linear-gradient(rgba(0,0,0,.13),rgba(0,0,0,.13)),#27519B;
  border-color:#27519B;
  color:#FFFFFF;
}
html body:is(.mkb27-preview,.mkb27-public) .mk-cc-switch {
  border-color:rgba(39,81,155,.28);
  color:#253544;
  font-family:var(--mkb27-font);
}
html body:is(.mkb27-preview,.mkb27-public) .mk-cc-switch input {
  accent-color:#27519B;
}
html body:is(.mkb27-preview,.mkb27-public) :is(.mk-cc-switch small,.mk-cc-status) {
  color:rgba(0,0,0,.72);
}
html body:is(.mkb27-preview,.mkb27-public) button.mk-cc-footer-button {
  color:#27519B;
  text-decoration:underline;
  text-underline-offset:.17em;
}
html body:is(.mkb27-preview,.mkb27-public) button.mk-cc-floating {
  background:#FFFFFF;
  color:#27519B;
  border-color:#27519B;
  font-family:var(--mkb27-font);
}
html body:is(.mkb27-preview,.mkb27-public) .mk-cc-embed {
  color:#253544;
  background:rgba(39,81,155,.045);
  border-color:rgba(39,81,155,.28);
}
html body:is(.mkb27-preview,.mkb27-public) .mk-cc-embed button {
  background:#27519B;
  border-color:#27519B;
  color:#FFFFFF;
}
html body:is(.mkb27-preview,.mkb27-public) :is(.mk-cc-banner,.mk-cc-dialog,.mk-cc-embed) :is(button,input,a):focus-visible,
html body:is(.mkb27-preview,.mkb27-public) :is(button.mk-cc-footer-button,button.mk-cc-floating):focus-visible {
  outline:3px solid #27519B;
  outline-offset:3px;
  box-shadow:0 0 0 5px #E9B538;
}

/* The admin-only diagnostic badge must never obstruct cookie choices, especially
 * on narrow screens. Do not hide the cookie UI itself. */
html body.mkb27-preview:has(.mk-cc-banner:not([hidden]))::after,
html body.mkb27-preview:has(.mk-cc-dialog:not([hidden]))::after {
  display:none!important;
}
