/*
  WIKTORIA.FIT — GLOBAL EDGE-TO-EDGE LAYOUT
  Shared by pages, posts, archives, search, shop and the front page.
  Draft theme only. Preserves Gutenberg blocks and existing SEO headings.
*/

/* Pricing cards: preserve white lettering on black CTA buttons. */
body:is(.page-id-297,.page-id-2747) #main .wp-block-column[style*="background-color:#ffe97d"],
body:is(.page-id-297,.page-id-2747) #main .wp-block-column[style*="background-color:#ffe97d"] :is(h2,h3,h4,h5,h6,p,span,strong,b,li,small,a),
body:is(.page-id-297,.page-id-2747) #main .wp-block-column[style*="background-color:#ffe97d"] .stk-block-text__text {
  color:#171717!important;
  opacity:1!important;
  text-shadow:none!important;
}
body:is(.page-id-297,.page-id-2747) #main .wp-block-column[style*="background-color:#ffe97d"] .wp-block-button__link[style*="background-color:#000000"],
body:is(.page-id-297,.page-id-2747) #main .wp-block-column[style*="background-color:#ffe97d"] .wp-block-button__link[style*="background-color:#000000"] :is(span,strong,b) {
  color:#ffffff!important;
}

:root {
  --wf-edge-gutter: clamp(22px,5.2vw,108px);
  --wf-global-dark: #0f0e17;
  --wf-global-deeper: #0a0a10;
  --wf-global-panel: #191820;
  --wf-global-panel-2: #201e27;
  --wf-global-gold: #bba14f;
  --wf-global-ivory: #f7f4f3;
}

/* Remove theme / Bootstrap viewport letterboxing rather than
   stripping useful padding *inside* full-width sections. */
html, body { max-width:100%; }
body #wrapper,
body #main {
  width:100%;
  max-width:none!important;
  margin-inline:0!important;
  background:var(--wf-global-dark);
}
body #main > .row {
  width:100%!important;
  max-width:none!important;
  margin-inline:0!important;
}
body:is(.single,.archive,.search) #main > .row > .col-md-10,
body:is(.single,.archive,.search) #main > .row > .col-sm-12 {
  max-width:none!important;
  flex:0 0 100%!important;
  width:100%!important;
  padding:0!important;
}
body:not(.home) #main > :is(.container,.container-fluid) {
  max-width:none!important;
  width:100%!important;
  margin:0!important;
  padding-inline:0!important;
}

/* Edge-to-edge navigation matches the homepage. */
#header,
#wrapper > header {
  width:100%;
  max-width:none!important;
  margin:0!important;
}
#header .container,
#header .container-fluid {
  width:100%!important;
  max-width:none!important;
  margin:0!important;
  padding-left:var(--wf-edge-gutter)!important;
  padding-right:var(--wf-edge-gutter)!important;
}
#header .navbar-brand img {max-width:220px;}
#header .navbar-nav {flex-wrap:wrap;}

/* Full-width top-level templates — no 1200px outer article */
body:not(.home) #main .wf-global-article {
  display:block;
  width:100%!important;
  max-width:none!important;
  margin:0!important;
  padding:0!important;
  min-width:0;
  background:var(--wf-global-dark);
}
body:not(.home) #main .wf-global-article > .wf-editorial,
body:not(.home) #main .wf-editorial {
  width:100%;
  max-width:none!important;
  min-width:0;
  padding:0;
  margin:0;
}
body:not(.home) #main .wf-article-head {
  display:flex;
  flex-direction:column;
  justify-content:center;
  width:100%!important;
  max-width:none!important;
  min-height:clamp(130px,14vw,210px);
  margin:0!important;
  border:0!important;
  border-bottom:1px solid #ffffff1b!important;
  border-radius:0;
  padding:clamp(29px,3.8vw,56px) var(--wf-edge-gutter)!important;
  background:
    radial-gradient(ellipse 48vw 40vw at 85% 47%,#bba14f22,transparent 74%),
    linear-gradient(115deg,#0d0c12,#1c1a25 68%,#111017);
}
body:not(.home) #main .wf-article-head::after {
  right:0;
  bottom:-130px;
  font-size:clamp(240px,30vw,550px);
}
body:not(.home) #main .wf-page-title {
  width:100%;
  max-width:1750px!important;
  font-size:clamp(33px,3.7vw,60px);
  line-height:1.04;
  margin:0!important;
  font-weight:750;
  text-wrap:balance;
}
body:not(.home) #main .wf-article-head .wf-overline {
  color:var(--wf-global-gold);
  margin:0 0 26px;
}
body:not(.home) #main .wf-article-head .wf-intro {
  max-width:1000px;
  margin-top:27px;
}

/* Whole article is a broad canvas with generous *internal* gutters.
   No outer card, no sidebar stripe, no narrow Gutenberg article box. */
body:not(.home) #main .wf-gutenberg-content {
  --wf-content-inset:var(--wf-edge-gutter);
  display:flow-root;
  box-sizing:border-box;
  width:100%!important;
  min-width:0;
  max-width:none!important;
  margin:0!important;
  padding:clamp(65px,7.5vw,118px) var(--wf-content-inset)!important;
  background:var(--wf-global-panel);
  border:0;
  border-radius:0;
  color:var(--wf-global-ivory);
}
body:not(.home) #main .wf-gutenberg-content > :where(
  .wp-block-group,
  .wp-block-columns,
  .wp-block-kadence-rowlayout,
  .wp-block-cover,
  .wp-block-media-text,
  .wp-block-gallery
) {
  width:100%;
  max-width:none!important;
  margin-left:0;
  margin-right:0;
}
body:not(.home) #main .wf-gutenberg-content > .wp-block-group > .wp-block-group__inner-container {
  width:100%;
  max-width:none!important;
}
body:not(.home) #main .wf-gutenberg-content .wp-block-columns,
body:not(.home) #main .wf-gutenberg-content .kt-row-column-wrap,
body:not(.home) #main .wf-gutenberg-content .wp-block-gallery {
  max-width:none!important;
}
body:not(.home) #main .wf-gutenberg-content .is-layout-constrained > :where(
  :not(.alignleft):not(.alignright):not(.alignfull)
) {max-width:none;}
body:not(.home) #main .wf-gutenberg-content > .alignfull,
body:not(.home) #main .wf-gutenberg-content > .wp-block-cover.alignfull {
  width:calc(100% + var(--wf-content-inset) + var(--wf-content-inset))!important;
  max-width:none!important;
  margin-left:calc(0px - var(--wf-content-inset))!important;
  margin-right:calc(0px - var(--wf-content-inset))!important;
}
body:not(.home) #main .wf-gutenberg-content > :is(p,.wp-block-paragraph) {
  max-width:115ch;
  font-size:clamp(15px,1.05vw,17px);
  line-height:1.85;
}
body:not(.home) #main .wf-gutenberg-content > h2,
body:not(.home) #main .wf-gutenberg-content > .wp-block-heading {
  margin-top:50px;
}
body:not(.home) #main .wf-gutenberg-content img {
  max-width:100%;
  height:auto;
}
body:not(.home) #main .wf-gutenberg-content .wp-block-image.alignfull img,
body:not(.home) #main .wf-gutenberg-content .wp-block-cover.alignfull img {
  width:100%;
  object-fit:cover;
}
body:not(.home) #main .wf-gutenberg-content .wp-block-cover {
  border-radius:0;
}

/* The existing Osielsko landing (and other pages containing an authored H1)
   gets a genuine full-bleed title section without adding a duplicate H1. */
body:not(.home) #main .wf-global-page .wf-gutenberg-content > h1:first-child {
  width:calc(100% + var(--wf-content-inset) + var(--wf-content-inset))!important;
  max-width:none!important;
  margin:
    calc(0px - clamp(65px,7.5vw,118px))
    calc(0px - var(--wf-content-inset))
    clamp(45px,6vw,95px)!important;
  padding:
    clamp(34px,4.3vw,62px)
    var(--wf-content-inset)
    clamp(32px,4vw,60px)!important;
  font-size:clamp(32px,3.7vw,59px);
  line-height:.94;
  font-weight:800;
  background:
    radial-gradient(ellipse 38vw 31vw at 81% 40%,#bba14f27,transparent 78%),
    linear-gradient(125deg,#101016,#23202b 75%,#131218);
  border-bottom:1px solid #ffffff20;
  text-wrap:balance;
}

/* The new "O mnie" and "Bydgoszcz Fordon" page drafts were built from
   Gutenberg groups — make their hero sections true full-width bands too. */
body:not(.home) #main .wf-editorial-landing {
  width:100%!important;
  max-width:none!important;
  margin:0!important;
}
body:not(.home) #main .wf-editorial-landing > .wp-block-group__inner-container {
  max-width:none!important;
  width:100%;
}
body:not(.home) #main .wf-editorial-landing .wf-page-intro {
  box-sizing:border-box;
  width:calc(100% + var(--wf-content-inset) + var(--wf-content-inset))!important;
  max-width:none!important;
  margin:
    calc(0px - clamp(65px,7.5vw,118px))
    calc(0px - var(--wf-content-inset))
    clamp(65px,7vw,115px)!important;
  padding:clamp(32px,4.3vw,64px) var(--wf-content-inset)!important;
  border:0!important;
  border-bottom:1px solid #ffffff26!important;
  border-radius:0;
  background:
    radial-gradient(ellipse 40vw 29vw at 81% 48%,#bba14f21,transparent 72%),
    linear-gradient(125deg,#111019,#24202b 72%,#141218)!important;
}
body:not(.home) #main .wf-editorial-landing .wf-intro-columns {
  width:100%!important;
  max-width:none!important;
  display:grid;
  grid-template-columns:minmax(0,1.07fr) minmax(0,.93fr);
  align-items:center;
  gap:clamp(38px,6vw,115px)!important;
}
body:not(.home) #main .wf-editorial-landing .wf-intro-columns > .wp-block-column {
  width:100%;min-width:0;
}
body:not(.home) #main .wf-editorial-landing .wf-feature-image {
  width:100%;max-width:none!important;
  max-height:680px;overflow:hidden;
  border-radius:2px;
}
body:not(.home) #main .wf-editorial-landing .wf-feature-image img {
  display:block;width:100%;
  height:clamp(400px,38vw,650px);
  max-height:none;
  object-fit:cover;
  object-position:center;
}
body:not(.home) #main .wf-editorial-landing .wf-page-lead {
  max-width:900px;
  font-size:clamp(16px,1.35vw,21px);
  line-height:1.65;
  color:#f3eee8;
}
body:not(.home) #main .wf-editorial-landing .wf-page-content {
  width:100%!important;
  max-width:none!important;
  margin:0!important;
}
body:not(.home) #main .wf-editorial-landing .wf-page-content > h2 {
  font-size:clamp(29px,3.3vw,47px);
  max-width:1250px;
  padding:0 0 17px;
  margin:clamp(50px,6vw,102px) 0 30px;
  border-bottom:1px solid #ffffff30;
}
body:not(.home) #main .wf-editorial-landing .wf-page-content > p {
  max-width:120ch;
  font-size:clamp(15px,1.05vw,17px);
  line-height:1.9;
}
body:not(.home) #main .wf-editorial-landing .wf-tile-columns {
  display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:clamp(18px,2.8vw,50px)!important;
}
body:not(.home) #main .wf-editorial-landing .wf-tile-columns > .wp-block-column {min-width:0}
body:not(.home) #main .wf-editorial-landing .wf-feature-tile {
  height:100%;padding:clamp(26px,3vw,54px);
  background:#22212a;border:1px solid #ffffff26;
}
body:not(.home) #main .wf-editorial-landing .wf-story-columns {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  align-items:center;
  gap:clamp(28px,5vw,90px)!important;
}
body:not(.home) #main .wf-editorial-landing .wf-story-columns > .wp-block-column{min-width:0}

/* Full-bleed article header and imagery, but keep photographs at a sensible
   rendered size rather than a giant square across a 4K monitor. */
body:not(.home) #main .wf-single-article .wf-post-cover {
  width:100%;
  max-width:none!important;
  margin:0!important;
  padding:clamp(38px,5vw,90px) var(--wf-edge-gutter);
  background:var(--wf-global-deeper);
}
body:not(.home) #main .wf-single-article .wf-post-cover img {
  display:block;
  width:min(100%,1000px);
  max-height:660px;
  height:auto;
  object-fit:cover;
  border-radius:2px;
}
body:not(.home) #main .wf-single-article .wf-gutenberg-content {
  max-width:none!important;
}
body:not(.home) #main .wf-post-navigation {
  width:100%;
  max-width:none!important;
  padding:50px var(--wf-edge-gutter) 90px;
  margin:0;
  background:var(--wf-global-dark);
}

/* Blog/search/archives now use the whole viewport as a responsive grid. */
body:not(.home) #main .wf-global-archive .wf-posts-grid {
  display:grid;
  width:100%;
  max-width:none!important;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:clamp(18px,2.35vw,45px);
  padding:clamp(45px,6vw,105px) var(--wf-edge-gutter);
  background:var(--wf-global-panel);
  margin:0;
}
body:not(.home) #main .wf-global-archive .wf-post-card {
  width:100%;min-width:0;
  background:#24232d;border:1px solid #ffffff1e;
}
body:not(.home) #main .wf-post-card-image {height:clamp(200px,20vw,380px);}
body:not(.home) #main .wf-post-card-image img {width:100%;height:100%!important;object-fit:cover}
body:not(.home) #main .wf-post-card-body {padding:clamp(23px,2.5vw,45px)}
body:not(.home) #main .wf-post-card-body h2 {font-size:clamp(29px,2.7vw,46px)}
body:not(.home) #main .wf-global-archive .wf-pagination {
  margin:0;
  padding:26px var(--wf-edge-gutter) 85px;
  width:100%;
  max-width:none!important;
  background:var(--wf-global-panel);
}
body:not(.home) #main .wf-notfound {
  max-width:none!important;
  min-height:68vh;
  padding:clamp(90px,10vw,170px) var(--wf-edge-gutter);
  background:var(--wf-global-panel);
}

/* Footer background and columns run to the same viewport edges as the header. */
#wrapper > .container-fluid,
#wrapper > .container-fluid > footer {
  width:100%!important;
  max-width:none!important;
  margin:0!important;
}
#wrapper > .container-fluid {padding-inline:0!important}
#wrapper > .container-fluid > footer {
  padding:clamp(50px,6vw,95px) var(--wf-edge-gutter) 28px!important;
  background:#111016!important;
}
#wrapper > .container-fluid footer > .container-fluid {
  width:100%!important;
  max-width:none!important;
  padding:0!important;
  margin:0!important;
}
#wrapper > .container-fluid footer .row {
  width:100%;
  margin-inline:0;
}

/* Ensure WooCommerce pages use the global canvas where Woo supplies templates. */
body.woocommerce-page #main > .container,
body.woocommerce-page #main > .container-fluid {
  width:100%!important;max-width:none!important;padding-inline:0!important;
}
body.woocommerce-page #main .woocommerce {
  width:100%;max-width:none!important;
  padding:clamp(28px,5vw,75px) var(--wf-edge-gutter);
  background:var(--wf-global-panel);
}
body.woocommerce-page #main .woocommerce ul.products {max-width:none}
body.woocommerce-page #main .woocommerce ul.products li.product {min-width:0}

/* Responsive — inner gutters remain for legibility; outside stays edge-to-edge. */
@media(max-width:1200px) {
  body:not(.home) #main .wf-global-archive .wf-posts-grid {
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}
@media(max-width:900px) {
  :root {--wf-edge-gutter:clamp(19px,4vw,36px)}
  #header .navbar-nav {flex-wrap:nowrap}
  body:not(.home) #main .wf-editorial-landing .wf-intro-columns,
  body:not(.home) #main .wf-editorial-landing .wf-story-columns {grid-template-columns:1fr}
  body:not(.home) #main .wf-editorial-landing .wf-feature-image img {height:clamp(360px,54vw,520px)}
  body:not(.home) #main .wf-editorial-landing .wf-tile-columns {
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
  body:not(.home) #main .wf-editorial-landing .wf-tile-columns > .wp-block-column:last-child {
    grid-column:1/-1;
  }
}
@media(max-width:650px) {
  :root {--wf-edge-gutter:20px}
  body:not(.home) #main .wf-article-head {min-height:0;padding:30px var(--wf-edge-gutter)!important}
  body:not(.home) #main .wf-page-title {font-size:clamp(30px,7.7vw,44px)}
  body:not(.home) #main .wf-gutenberg-content {padding:55px var(--wf-edge-gutter) 75px!important}
  body:not(.home) #main .wf-global-page .wf-gutenberg-content > h1:first-child {
    margin-top:-55px!important;
    padding:34px var(--wf-edge-gutter) 36px!important;
    font-size:clamp(30px,7.7vw,44px);
  }
  body:not(.home) #main .wf-editorial-landing .wf-page-intro {
    margin-top:-55px!important;
    padding:33px var(--wf-edge-gutter)!important;
  }
  body:not(.home) #main .wf-editorial-landing .wf-tile-columns,
  body:not(.home) #main .wf-global-archive .wf-posts-grid {grid-template-columns:1fr}
  body:not(.home) #main .wf-editorial-landing .wf-tile-columns > .wp-block-column:last-child {grid-column:auto}
  body:not(.home) #main .wf-post-card-image {height:230px}
  body:not(.home) #main .wf-post-navigation {flex-direction:column}
  #wrapper > .container-fluid > footer {padding:52px var(--wf-edge-gutter) 28px!important}
}

/* Smaller, calmer type scale across secondary pages.
   The homepage retains its separate hero and heading sizes. */
body:not(.home) #main .wf-gutenberg-content :is(p,li),
body:not(.home) #main .wf-post-card-body p {
  font-size:clamp(15px,1.05vw,17px);
  line-height:1.68;
}
body:not(.home) #main h2:not(.wf-page-title) {
  font-size:clamp(28px,2.7vw,41px);
  line-height:1.14;
}
body:not(.home) #main h3 {
  font-size:clamp(22px,2.1vw,30px);
  line-height:1.2;
}
body:not(.home) #main h4 {
  font-size:clamp(19px,1.7vw,25px);
  line-height:1.25;
}
body:not(.home) #main .wf-article-head .wf-overline {
  font-size:10px;
  margin-bottom:13px;
}
body:not(.home) #main .wf-article-head .wf-intro {
  font-size:clamp(15px,1.25vw,18px);
  margin-top:15px;
}
body:not(.home) #main .wf-editorial-landing .wf-page-content > h2 {
  font-size:clamp(29px,3vw,44px);
  margin:clamp(32px,3.8vw,68px) 0 22px;
}
body:not(.home) #main .wf-global-archive .wf-post-card-body h2 {
  font-size:clamp(24px,2vw,33px);
}
@media(max-width:650px) {
  body:not(.home) #main .wf-global-page .wf-gutenberg-content > h1:first-child {
    line-height:1.1;
  }
  body:not(.home) #main h2:not(.wf-page-title) {font-size:clamp(26px,7.6vw,34px)}
  body:not(.home) #main h3 {font-size:clamp(21px,6vw,26px)}
  body:not(.home) #main .wf-editorial-landing .wf-page-content > h2 {
    font-size:clamp(27px,7.8vw,34px);
  }
}
