/* ==========================================================================
   Page background — global off-white (--light-bg / --page-bg)
   Default: #FBFCFE. Crne sekcije ostaju netaknute.
   ========================================================================== */

/* Sve stranice osim kontakta (tamna full-page) */
body:not(.is-contact-page) {
	background-color: var(--light-bg);
}

/*
 * Glavne svijetle sekcije — samo root elementi s page-level bijelom pozadinom.
 * Namjerno ISKLJUČENO: crne sekcije, UI elementi, kartice, gumbi, navigacija.
 */
body:not(.is-contact-page) :is(
	.wm-hero,
	.wm-hero__atmosphere,
	.wm-portfolio-preview,
	.wm-results,
	.wm-clients,
	.wm-home-about,
	.wm-testimonials:not(.wm-testimonials--dark),
	.wm-testimonials-editorial,
	.wm-faq,
	.wm-sp-hero,
	.wm-sp-services,
	.wm-sp-faq,
	.wm-sp-ed-list,
	.wm-pt-hero,
	.wm-ab-intro__media,
	.wm-ab-stats,
	.wm-ab-clients,
	.wm-sp-clients,
	.wm-ab-reviews,
	.wm-home-services--partner-light,
	.wm-ptnr-projects,
	.wm-pt-intro,
	.wm-pt-grid,
	.process-section,
	.wm-proof,
	.partners-section,
	.reviews-section,
	.wm-home-cta,
	.wm-svc-approach,
	.wm-svc-included,
	.wm-svc-audience,
	.wm-home-cta--services-page,
	.about-ed,
	.portfolio-page-process,
	.portfolio-page-cta
) {
	background-color: var(--light-bg);
}

/*
 * Page wrappers must stay transparent so the last light section's
 * bottom radius reveals the black footer canvas (O nama / global system).
 * Do NOT paint light backgrounds on wrapping <article> elements.
 */
body:not(.is-contact-page) .wm-main > article {
	background-color: transparent;
}

/* Last light section — shared footer transition (beats page-specific overrides) */
body:not(.is-contact-page) .wm-main > section:last-child,
body:not(.is-contact-page) .wm-main > article:last-child > section:last-child,
body:not(.is-contact-page) .wm-main > .wm-prefooter-cta:last-child,
body:not(.is-contact-page) .wm-main > .wm-global-prefooter-cta:last-child {
	border-bottom-left-radius: var(--wm-footer-content-radius, clamp(28px, 3.5vw, 40px));
	border-bottom-right-radius: var(--wm-footer-content-radius, clamp(28px, 3.5vw, 40px));
	overflow: hidden;
	position: relative;
	z-index: 20;
}

@media (max-width: 768px) {
	body:not(.is-contact-page) .wm-main > section:last-child,
	body:not(.is-contact-page) .wm-main > article:last-child > section:last-child,
	body:not(.is-contact-page) .wm-main > .wm-prefooter-cta:last-child,
	body:not(.is-contact-page) .wm-main > .wm-global-prefooter-cta:last-child {
		border-bottom-left-radius: var(--wm-footer-content-radius-mobile, clamp(18px, 5vw, 24px));
		border-bottom-right-radius: var(--wm-footer-content-radius-mobile, clamp(18px, 5vw, 24px));
	}
}

/* O nama — Kako radimo (crna editorial sekcija) */
body.is-about-page .wm-ab-why {
	background-color: #0a0a0a;
}

/* B2B — crne sekcije (mora biti specifičnije od globalnog light-bg pravila) */
body.is-partner-page:not(.is-contact-page) :is(
	.wm-ptnr-hero,
	.wm-ptnr-intro
) {
	background-color: #0a0a0a;
}

/* Usluge — crni editorial proces */
body.is-services-page:not(.is-contact-page) .wm-sp-process--editorial {
	background-color: #0a0a0a;
}

/* B2B — svijetli editorial proces */
body.is-partner-page:not(.is-contact-page) .wm-sp-process--editorial {
	background-color: var(--light-bg);
}

/* B2B — usluge panel (light) */
body.is-partner-page:not(.is-contact-page) .wm-home-services--partner-light {
	background-color: var(--light-bg);
}
