/*
Theme Name: Parcela
Theme URI: https://camping.org.pl
Author: Parcela
Description: Kemping w Polsce: od wyboru pola do ostatniego śledzia w ziemi
Version: 1.11
Requires at least: 6.4
Tested up to: 6.8
Requires PHP: 7.4
License: GNU General Public License v2 or later
Text Domain: parcela
*/

/* ramka wstepu (BLUF) i box TL;DR */
.wpm-bluf, .tldr { border-left: 4px solid var(--wp--preset--color--primary); border-radius: 0 6px 6px 0; padding: 1.25rem 1.5rem; margin-bottom: 2rem; }
.wpm-bluf > * { margin-left: 0 !important; margin-right: 0 !important; max-width: none; }
.wpm-bluf .wpm-bluf-label { margin: 0 0 0.5em; letter-spacing: 0.06em; text-transform: uppercase; opacity: 0.7; }
.wpm-bluf p { line-height: 1.6; }
.wpm-bluf p:last-child, .wpm-bluf ul:last-child { margin-bottom: 0; }

/* portal kit: uklad klockow (kolory i fonty z theme.json) */
.wpm-header { border-bottom: 1px solid var(--wp--preset--color--surface); }
.wpm-masthead-kompaktowy { z-index: 20; }
.wpm-servicebar { padding-block: 0.4rem; }
.wpm-brand .wp-block-site-title { margin: 0; }
.wpm-kicker { margin-block: 1.5rem 1rem; }
.wpm-home-h1 { max-width: 22ch; }
.wpm-home-lead { max-width: 60ch; }
.wpm-trust { border-block: 1px solid var(--wp--preset--color--surface); padding-block: 0.6rem; margin-block: 1rem 2rem; }
.wpm-trust-masthead { border: 0; margin: 0; padding: 0; }
.wpm-trust-kafle > p { padding: 0.6rem 1rem; margin: 0; }
.wpm-section { margin-block: 2.5rem; }
.wpm-section-head { border-bottom: 2px solid var(--wp--preset--color--contrast); padding-bottom: 0.4rem; margin-bottom: 1rem; align-items: baseline; }
.wpm-section-title { margin: 0; }
.wpm-mini > .wp-block-column:first-child img { border-radius: 6px; }
.wpm-textrow { border-bottom: 1px solid var(--wp--preset--color--surface); padding-block: 0.5rem; }
.wpm-meta { font-size: var(--wp--preset--font-size--small); color: var(--wp--preset--color--muted); }
.wpm-meta .wp-block-avatar img { border-radius: 50%; }
.wpm-sidebar { position: sticky; top: 1rem; align-self: start; }
.wpm-aside-title { font-size: var(--wp--preset--font-size--large); border-bottom: 2px solid var(--wp--preset--color--contrast); padding-bottom: 0.3rem; margin-bottom: 0.8rem; }
.wpm-most-read .wp-block-post-template { counter-reset: wpm; list-style: none; padding: 0; }
.wpm-most-read .wp-block-post { counter-increment: wpm; display: grid; grid-template-columns: 2rem 1fr; gap: 0.5rem; padding-block: 0.5rem; border-bottom: 1px solid var(--wp--preset--color--surface); }
.wpm-most-read .wp-block-post::before { content: counter(wpm); font-family: var(--wp--preset--font-family--heading, inherit); font-size: var(--wp--preset--font-size--x-large); line-height: 1; color: var(--wp--preset--color--muted); }
.wpm-silos, .wpm-footer-silos { list-style: none; padding: 0; margin: 0; }
.wpm-silos li, .wpm-footer-silos li { padding-block: 0.25rem; }
.wpm-single-head { margin-block: 1rem 1.5rem; }
.wpm-kicker-cat { font-size: var(--wp--preset--font-size--small); }
.wpm-lead { font-size: var(--wp--preset--font-size--large); color: var(--wp--preset--color--muted); }
.wpm-breadcrumbs { font-size: var(--wp--preset--font-size--small); color: var(--wp--preset--color--muted); }
.wpm-breadcrumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 0.4rem; padding: 0; margin: 0 0 0.8rem; }
.wpm-breadcrumbs li + li::before { content: "/"; margin-right: 0.4rem; color: var(--wp--preset--color--muted); }
.wpm-toc { border: 1px solid var(--wp--preset--color--surface); background: var(--wp--preset--color--surface); padding: 1rem 1.25rem; margin: 0 0 2rem; }
.wpm-toc ol { margin: 0.5rem 0 0; padding-left: 1.2rem; }
.wpm-author-box { margin-block: 2.5rem; border-radius: 6px; }
.wpm-author-box .wp-block-avatar img { border-radius: 50%; }
.wpm-prevnext { border-top: 1px solid var(--wp--preset--color--surface); padding-top: 1rem; }
.wpm-hub-head { margin-block: 1.5rem; }
.wpm-hub-list .wp-block-post:nth-child(-n+3) .wp-block-post-title { font-size: var(--wp--preset--font-size--large); }
.wpm-footer-title { font-size: var(--wp--preset--font-size--medium); margin-bottom: 0.6rem; }
.wpm-footer .wp-block-navigation { font-size: var(--wp--preset--font-size--small); }
.wpm-copy { margin-top: 2rem; }
@media (max-width: 781px) { .wpm-sidebar { position: static; } .wpm-hero-small .wp-block-post-template { grid-template-columns: 1fr; } }

/* Parcela: tafla jeziora pod H1, reszta cicha */
.wp-site-blocks { overflow-x: clip; }
.wp-site-blocks > footer { margin-block-start: 0; }
.wp-site-blocks > main.wpm-main { margin-block-start: 0; padding-top: var(--wp--preset--spacing--40); padding-bottom: var(--wp--preset--spacing--60); }
.wpm-main:has(> .wpm-kicker:first-child), .wpm-main:has(> .wpm-hub-head:first-child) { padding-top: 0; }
h1, h2, h3, h4 { text-wrap: balance; }
p, li { text-wrap: pretty; }
::selection { background: var(--wp--preset--color--surface); color: var(--wp--preset--color--contrast); }
:where(a, button, input, select, textarea, .wp-element-button, summary):focus-visible { outline: 3px solid var(--wp--preset--color--accent); outline-offset: 3px; border-radius: 2px; }

/* szerokosc portalu: strona glowna, huby, wpis z sidebarem w 1240 px; strony informacyjne waskie */
.wpm-main.is-layout-constrained:not(.wpm-page) > :where(:not(.alignleft):not(.alignright):not(.alignfull)) { max-width: var(--wp--style--global--wide-size); }

/* linki w tresci: cienkie podkreslenie, na hover grubsze */
a { text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
.wp-block-post-title a, .wp-block-navigation a, .wpm-brand a, .wp-block-post-author-name a, .wpm-footer-silos a { text-decoration: none; }
.wp-block-post-title a:hover, .wp-block-post-author-name a:hover, .wpm-footer-silos a:hover { text-decoration: underline; text-decoration-thickness: 2px; }

/* masthead centralny: logo z napisem, nazwa jako tekst dla czytnikow */
.wpm-header.is-layout-constrained > *, .wpm-masthead.is-layout-constrained > *, .wpm-footer.is-layout-constrained > * { max-width: var(--wp--style--global--wide-size); }
.wpm-servicebar .wp-block-search__button { padding: 0.45rem 0.8rem; margin-left: 0.4rem; }
.wpm-header { border-bottom: 1px solid var(--wp--preset--color--surface); }
.wpm-servicebar { color: var(--wp--preset--color--muted); border-bottom: 1px solid var(--wp--preset--color--surface); align-items: center; }
.wpm-servicebar .wp-block-search__input { padding: 0.45rem 0.7rem; border: 1px solid var(--wp--preset--color--muted); border-radius: 6px; background: var(--wp--preset--color--base); min-width: 14rem; font-size: var(--wp--preset--font-size--small); }
.wpm-servicebar .wp-block-search__inside-wrapper { border: 0; padding: 0; }
.wpm-brandrow { padding-block: var(--wp--preset--spacing--40) var(--wp--preset--spacing--30); }
.wpm-brand .wp-block-site-logo img { width: clamp(170px, 17vw, 230px); height: auto; }
.wpm-brand .wp-block-site-logo + .wp-block-site-title { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.wpm-sections-bar { padding-bottom: var(--wp--preset--spacing--30); }
.wpm-sections-bar .wp-block-navigation { gap: 0.5rem 2rem; }
.wpm-sections-bar .wp-block-navigation-item a { padding-block: 0.35rem; border-bottom: 3px solid transparent; }
.wpm-sections-bar .wp-block-navigation-item a:hover, .wpm-sections-bar .current-menu-item > a, .wpm-sections-bar [aria-current="page"] { border-bottom-color: var(--wp--preset--color--accent); }
.wp-block-navigation__responsive-container.is-menu-open { background: var(--wp--preset--color--base); padding: var(--wp--preset--spacing--40); }

/* TAFLA: pelnoszerokie pole glebokiej wody pod H1 strony glownej i hubow */
.wpm-main > .wpm-kicker, .wpm-main > .wpm-hub-head {
  position: relative; isolation: isolate;
  width: 100vw; max-width: 100vw !important;
  margin-left: calc(50% - 50vw) !important; margin-right: 0 !important; margin-top: 0; margin-bottom: 0;
  padding-inline: max(var(--wp--preset--spacing--40), calc((100vw - var(--wp--style--global--wide-size)) / 2));
  background-color: var(--wp--preset--color--secondary);
  color: var(--wp--preset--color--base);
}
.wpm-main > .wpm-kicker > *, .wpm-main > .wpm-hub-head > * { margin-left: 0 !important; margin-right: 0 !important; }
.wpm-main > .wpm-kicker { padding-block: clamp(3rem, 7vw, 5.5rem) clamp(5.5rem, 11vw, 9rem); }
.wpm-main > .wpm-kicker::before { content: ""; position: absolute; inset: 0; z-index: -1; background: url(assets/img/tafla.jpg) center 62% / cover no-repeat; opacity: 0.42; }
.wpm-kicker .wpm-home-h1 { color: var(--wp--preset--color--base); font-size: clamp(2.1rem, 4.6vw, 3.4rem); line-height: 1.06; letter-spacing: -0.03em; max-width: 17ch; margin-bottom: var(--wp--preset--spacing--30); }
.wpm-kicker .wpm-home-lead { color: var(--wp--preset--color--surface); max-width: 46ch; margin-top: 0; }
.wpm-main > .wpm-hub-head { padding-block: clamp(2.5rem, 6vw, 4.5rem) clamp(2rem, 4vw, 3rem); margin-bottom: var(--wp--preset--spacing--50); }
.wpm-hub-head .wpm-hub-h1 { color: var(--wp--preset--color--base); font-size: clamp(2rem, 4vw, 3rem); max-width: 22ch; }
.wpm-hub-head .wpm-hub-lead { color: var(--wp--preset--color--surface); max-width: 60ch; font-size: var(--wp--preset--font-size--large); }
.wpm-hub-head .wpm-trust, .wpm-hub-head .has-muted-color { color: var(--wp--preset--color--surface) !important; border-color: color-mix(in srgb, var(--wp--preset--color--base) 25%, transparent); max-width: 60ch; margin-bottom: 0; }
.wpm-hub-head a { color: var(--wp--preset--color--base); }

/* trojka: zdjecia trzech najnowszych tekstow nachodza na brzeg tafli */
.wpm-main > .wpm-hero-trojka { position: relative; z-index: 1; }
.wpm-main > .wpm-hero-trojka:has(.wp-block-post) { margin-top: calc(-1 * clamp(4rem, 8vw, 6.5rem)) !important; }
.wpm-hero-trojka .wp-block-post-template { gap: var(--wp--preset--spacing--40); }
.wpm-hero-trojka .wp-block-post-featured-image { margin-bottom: var(--wp--preset--spacing--30); }
.wpm-hero-trojka .wp-block-post-featured-image img { outline: 6px solid var(--wp--preset--color--base); }
.wpm-hero-trojka .wp-block-post-title { margin-block: 0 0.4rem; }
.wpm-main > .wp-block-buttons { margin-top: var(--wp--preset--spacing--40); }
.wpm-trust-linia { border-top: 1px solid var(--wp--preset--color--surface); border-bottom: 0; margin-top: var(--wp--preset--spacing--40); }

/* obrazy: jeden promien, bez cieni */
.wp-block-post-featured-image img, .wp-block-image img, .wpm-mini img { border-radius: 6px; }
.wp-block-post-featured-image a:hover img { opacity: 0.92; }

/* pasy dzialow: cicha linia, nazwa dzialu w Epilogue */
.wpm-section { margin-block: var(--wp--preset--spacing--50) var(--wp--preset--spacing--60); }
.wpm-section-head { border-bottom: 1px solid var(--wp--preset--color--contrast); }
.wpm-section-title { font-size: var(--wp--preset--font-size--x-large); }
.wpm-section-more { margin: 0; }
.wpm-section .wp-block-post-title { margin-block: 0.5rem 0.35rem; }
.wpm-section .wp-block-post-excerpt { color: var(--wp--preset--color--muted); font-size: var(--wp--preset--font-size--medium); }
.wpm-row { padding-bottom: var(--wp--preset--spacing--30); border-bottom: 1px solid var(--wp--preset--color--surface); margin-bottom: var(--wp--preset--spacing--30); }
.wpm-mini { margin-bottom: var(--wp--preset--spacing--30); gap: var(--wp--preset--spacing--30); }
.wpm-meta { gap: 0.25rem 1rem; }

/* sidebar: najczesciej czytane z cyframi w kolorze odciagu */
.wpm-aside-title { border-bottom: 1px solid var(--wp--preset--color--contrast); font-size: var(--wp--preset--font-size--large); }
.wpm-most-read .wp-block-post::before { color: var(--wp--preset--color--accent); font-weight: 800; }
.wpm-most-read .wp-block-post-title { margin: 0; font-size: var(--wp--preset--font-size--medium); }

/* wpis */
.wpm-single-head .wp-block-post-title { font-size: clamp(2rem, 4vw, 2.9rem); line-height: 1.1; letter-spacing: -0.025em; }
.wpm-kicker-cat a { font-family: var(--wp--preset--font-family--epilogue); font-weight: 700; text-decoration: none; }
.wpm-article .wp-block-post-content { font-size: 1.125rem; }
.wpm-article .wp-block-post-content > * { max-width: 68ch; }
.wp-block-post-content h2 { margin-top: 2.6rem; font-size: var(--wp--preset--font-size--x-large); }
.wp-block-post-content h3 { margin-top: 2rem; font-size: var(--wp--preset--font-size--large); }
.wp-block-post-content ul li::marker, .wp-block-post-content ol li::marker { color: var(--wp--preset--color--primary); font-family: var(--wp--preset--font-family--epilogue); font-weight: 700; }
.wp-block-post-content li { margin-bottom: 0.35rem; }
.wp-block-quote, .wp-block-pullquote { border-left: 3px solid var(--wp--preset--color--secondary); padding: 0.2rem 0 0.2rem 1.4rem; margin-inline: 0; font-style: italic; font-size: var(--wp--preset--font-size--large); line-height: 1.5; }
.wp-block-quote cite, .wp-block-quote .wp-block-quote__citation { font-style: normal; font-size: var(--wp--preset--font-size--small); color: var(--wp--preset--color--muted); }
figure.wp-block-image { margin-block: 2rem; }
figure figcaption, .wp-element-caption { text-align: left; color: var(--wp--preset--color--muted); font-size: var(--wp--preset--font-size--small); margin-top: 0.5rem; }
.wp-block-table table { border-collapse: collapse; width: 100%; font-size: var(--wp--preset--font-size--medium); }
.wp-block-table th { font-family: var(--wp--preset--font-family--epilogue); text-align: left; border-bottom: 2px solid var(--wp--preset--color--contrast); }
.wp-block-table td, .wp-block-table th { padding: 0.55rem 0.7rem; border: 0; border-bottom: 1px solid var(--wp--preset--color--surface); }
.wp-block-table tbody tr:nth-child(odd) { background: color-mix(in srgb, var(--wp--preset--color--surface) 55%, transparent); }
.wpm-toc, #toc_container { background: var(--wp--preset--color--surface); border: 0; border-left: 3px solid var(--wp--preset--color--accent); border-radius: 0 6px 6px 0; padding: 1rem 1.25rem; width: auto !important; }
#toc_container .toc_title { font-family: var(--wp--preset--font-family--epilogue); font-weight: 700; text-align: left; }
.wpm-author-box { gap: var(--wp--preset--spacing--40); align-items: flex-start; }
.wpm-related-wrap { margin-top: var(--wp--preset--spacing--60); }
.wpm-prevnext a { font-family: var(--wp--preset--font-family--epilogue); font-weight: 700; text-decoration: none; }

/* strony informacyjne */
.wpm-page-head { border-bottom: 1px solid var(--wp--preset--color--contrast); margin-bottom: var(--wp--preset--spacing--40); }
.wpm-page-h1 { font-size: clamp(2rem, 4vw, 2.8rem); }

/* stopka na tafli: domyka strone tym samym kolorem co pole pod H1 */
.wpm-footer.has-background { background-color: var(--wp--preset--color--secondary) !important; color: var(--wp--preset--color--base); }
.wpm-footer .wpm-footer-title { color: var(--wp--preset--color--base); font-size: var(--wp--preset--font-size--medium); }
.wpm-footer a { color: var(--wp--preset--color--surface); }
.wpm-footer a:hover { color: var(--wp--preset--color--base); }
.wpm-footer .has-muted-color { color: var(--wp--preset--color--surface) !important; }
.wpm-footer .wp-block-navigation { gap: 0.4rem 1.2rem; font-family: var(--wp--preset--font-family--newsreader); font-weight: 400; }
.wpm-copy { border-top: 1px solid color-mix(in srgb, var(--wp--preset--color--base) 22%, transparent); padding-top: var(--wp--preset--spacing--30); }

/* uklad responsywny */
@media (max-width: 1100px) {
  .wpm-section-cztery_karty .wp-block-post-template.is-layout-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 781px) {
  .wpm-servicebar .wp-block-search__input { padding: 0.45rem 0.7rem; min-width: 0; }
  .wpm-hero-trojka .wp-block-post-template.is-layout-grid { grid-template-columns: 1fr; }
  .wpm-related .wp-block-post-template.is-layout-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 480px) {
  .wpm-section-cztery_karty .wp-block-post-template.is-layout-grid { grid-template-columns: 1fr; }
  .wpm-footer-cols { gap: var(--wp--preset--spacing--40); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
.wpm-footer-silos { font-size: var(--wp--preset--font-size--small); }

/* Karty w waskich kolumnach: bez lamania slow w srodku */
.wp-block-post-template .wp-block-post-title { overflow-wrap: normal; word-break: normal; hyphens: manual; }
.wp-block-post-template.columns-4 .wp-block-post-title,
.wpm-cards-4 .wp-block-post-title { font-size: clamp(0.95rem, 1.05vw, 1.0625rem); line-height: 1.25; }
@media (min-width: 782px) and (max-width: 1280px) {
  .wp-block-post-template.columns-4 { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
}

/* Zespol: portret obok bio */
.wpm-portrait { float: left; width: 150px; margin: 0.35rem 1.5rem 0.75rem 0 !important; clear: both; }
.wpm-portrait img { aspect-ratio: 4 / 5; object-fit: cover; border-radius: 4px; }
.wpm-portrait + h3 { margin-top: 0.25rem; }
.entry-content h2, .wp-block-post-content h2 { clear: both; }
@media (max-width: 480px) { .wpm-portrait { width: 110px; margin-right: 1rem !important; } }
.wpm-portrait + h3 + p { min-height: 140px; margin-bottom: 1.5rem; }
@media (max-width: 480px) { .wpm-portrait + h3 + p { min-height: 100px; } }

/* logo = sam znak (decyzja 2026-10-08) */
.wpm-brand .wp-block-site-logo, .wp-block-site-logo.wpm-logo { line-height: 0; flex-shrink: 0; }
.wpm-brand .wp-block-site-logo img, .wp-block-site-logo.wpm-logo img { width: 56px !important; height: 56px !important; max-width: none !important; max-height: none !important; object-fit: contain; display: block; }
@media (max-width: 600px) { .wpm-brand .wp-block-site-logo img, .wp-block-site-logo.wpm-logo img { width: 44px !important; height: 44px !important; } }
/* naglowek: sam znak, nazwa tylko dla czytnikow i SEO */
.wpm-brand:has(.wp-block-site-logo img) .wp-block-site-title, header .wp-block-site-logo + .wp-block-site-title { position: absolute !important; width: 1px !important; height: 1px !important; overflow: hidden !important; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; margin: 0 !important; padding: 0 !important; }
