/* Ivica i Marica — izvedba u Elementoru. Mjere iz prototipa (handoff/…/prototip, README).
   Klase .iv-* su naše; Elementorove klase (.e-con, .elementor-*) ciljaju se samo UNUTAR naših klasa. */

:root {
	/* Odluka 1 (Toni 10.10.2026.): tamnije inačice za tekst na svijetlim podlogama (kontrast ≥ 4,5 : 1). */
	--iv-medenjak-tekst: #9A5A24; --iv-zelena-tekst: #4E6C3A;
	--iv-terakota: #B8422F; --iv-terakota-t: #8E3122; --iv-smeda: #6B4A2F; --iv-medenjak: #C77B3C; --iv-zlatna: #E0A93C;
	--iv-zelena: #5E7E46; --iv-krem: #FFF8EC; --iv-krem-s: #FFF6E8; --iv-pijesak: #FBEEDA; --iv-hover: #F6E6CB;
	--iv-tekst: #3E2E22; --iv-tijelo: #5A483A; --iv-sek: #6E6047; --iv-linija: #EBDCC2;
	--iv-bitter: "Bitter", Georgia, serif; --iv-nunito: "Nunito Sans", system-ui, sans-serif;
}

/* Osnovno pismo stranice kao u prototipu (body: Nunito Sans, #3E2E22). */
body { font-family: var(--iv-nunito); color: var(--iv-tekst); }

/* Naši kontejneri: bez Elementorovih zadanih razmaka (gap, padding) — razmake nose klase. */
.e-con[class*="iv-"] { --gap: 0px; --row-gap: 0px; --column-gap: 0px; --padding-top: 0px; --padding-right: 0px; --padding-bottom: 0px; --padding-left: 0px; flex-wrap: nowrap; }
:where([class*="iv-"]) .elementor-widget-text-editor p:last-child { margin-bottom: 0; }
/* Najniža specifičnost (:where) — pravila pojedinih dijelova uvijek nadjačaju ovo poništavanje. */
:where([class*="iv-"]) .elementor-widget-text-editor p { margin-top: 0; }
/* Prototip: p { text-wrap: pretty } — isti prijelom redaka (npr. adresa na 390 px). */
[class*="iv-"] .elementor-widget-text-editor p, [class*="iv-"] p { text-wrap-style: pretty; }

/* Fokus tipkovnice (README §7). */
.iv-root a:focus-visible, .iv-root button:focus-visible, .iv-root input:focus-visible, .iv-root select:focus-visible, .iv-root textarea:focus-visible,
.iv-cs a:focus-visible { outline: 3px solid var(--iv-zlatna); outline-offset: 3px; border-radius: 6px; }

/* ---------- Gumbi (README §7) ---------- */
.iv-gumb .elementor-button { display: inline-flex; align-items: center; gap: 10px; border-radius: 999px; font-family: var(--iv-nunito); font-size: 16px; font-weight: 700; line-height: normal; letter-spacing: normal; text-transform: none; box-shadow: none; transition: background-color .15s; }
.iv-gumb .elementor-button .elementor-button-content-wrapper { display: flex; align-items: center; gap: 10px; flex-direction: row; }
.iv-gumb .elementor-button-icon { display: inline-flex; margin: 0; }
.iv-gumb .elementor-button-icon svg { width: 20px; height: 20px; flex: 0 0 auto; fill: none; }
.iv-gumb--p .elementor-button { padding: 15px 26px; background: var(--iv-terakota); color: var(--iv-krem-s); border: 0; }
.iv-gumb--p .elementor-button:hover, .iv-gumb--p .elementor-button:focus { background: var(--iv-terakota-t); color: var(--iv-krem-s); }
.iv-gumb--p .elementor-button-icon svg { stroke: var(--iv-krem-s); }
.iv-gumb--s .elementor-button { padding: 13px 24px; background: transparent; color: var(--iv-smeda); border: 2px solid var(--iv-medenjak); }
.iv-gumb--s .elementor-button:hover, .iv-gumb--s .elementor-button:focus { background: var(--iv-hover); color: var(--iv-smeda); }
.iv-gumb--s .elementor-button-icon svg { stroke: var(--iv-medenjak); }
.iv-gumb .elementor-button-text { min-width: 0; overflow-wrap: anywhere; }

/* Pojavljivanje pri pomicanju (prototip .im-reveal; iv-r postavlja skripta u <head>, iv-in iv.js). */
html.iv-r .iv-reveal:not(.iv-in) { opacity: 0; }
html.iv-r .iv-reveal.iv-in { animation: im-rise .7s cubic-bezier(.22, .7, .3, 1) both; }
/* Prototip: section[id] { scroll-margin-top } — sidra ispod ljepljivog zaglavlja. */
.e-con[id] { scroll-margin-top: 148px; }
@media (max-width: 1024px) { .e-con[id] { scroll-margin-top: 100px; } }
[class*="iv-"] .elementor-heading-title { text-wrap-style: balance; }

/* ---------- Slojevite scene ---------- */
.iv-scena { position: relative; }
.iv-sloj { position: absolute; display: block; height: auto; max-width: none; }
.iv-sjena { position: absolute; border-radius: 50%; }
@keyframes iv-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
@keyframes iv-perch { 0%, 72%, 100% { transform: rotate(0); } 78% { transform: rotate(-6deg); } 84% { transform: rotate(3deg); } 90% { transform: rotate(0); } }

/* ---------- Ornament (vez) ---------- */
.e-con.iv-vez { height: 26px; min-height: 26px; flex: 0 0 auto; background: var(--iv-krem-s) url("../ukrasi/vez-ornament.svg") repeat-x 0 0 / 60px 26px; }

/* ---------- Dolazimo uskoro ---------- */
.e-con.iv-cs { line-height: normal; min-height: 100dvh; display: flex; flex-direction: column; overflow-x: clip; background: var(--iv-pijesak); color: var(--iv-tekst); font-family: var(--iv-nunito); }
.e-con.iv-cs-main { flex: 1 0 auto; display: flex; align-items: center; justify-content: center; padding: 40px 24px 48px; }
.e-con.iv-cs-in { max-width: 720px; width: 100%; text-align: center; display: flex; flex-direction: column; align-items: center; }
.iv-cs-logo img { width: 96px; height: 96px; display: block; }
.iv-cs-scena { width: min(380px, 80vw); }
.iv-scena--uskoro { width: 100%; margin: 22px auto 0; }
.iv-scena--uskoro .iv-anim-djeca { animation: iv-bob 6s ease-in-out infinite; transform-origin: 50% 100%; }
.iv-scena--uskoro .iv-anim-ptica { animation: iv-perch 7s ease-in-out infinite; transform-origin: 50% 100%; }
.elementor-widget.iv-cs-natpis { margin-top: 18px; }
.iv-cs-natpis p { font-size: 13px; letter-spacing: .18em; color: var(--iv-sek); font-weight: 700; line-height: normal; }
.iv-cs-h1 .elementor-heading-title { font-family: var(--iv-bitter); font-size: clamp(32px, 5vw, 52px); line-height: 1.1; font-weight: 800; color: var(--iv-smeda); margin: 12px 0 0; text-wrap-style: balance; }
.elementor-widget.iv-cs-p { margin-top: 16px; }
.iv-cs-p p { font-size: 18px; line-height: 1.65; color: var(--iv-tijelo); max-width: 44ch; margin: 0 auto; text-wrap-style: pretty; }
.e-con.iv-cs-gumbi { flex-direction: row; flex-wrap: wrap; gap: 12px; --gap: 12px; --row-gap: 12px; --column-gap: 12px; justify-content: center; margin-top: 26px; }
.elementor-widget.iv-cs-adresa { margin-top: 22px; }
.iv-cs-adresa p { font-size: 15px; line-height: 1.6; color: var(--iv-sek); }
.iv-nowrap { white-space: nowrap; }
.e-con.iv-cs-dno { flex: 0 0 auto; background: var(--iv-smeda); padding: 14px 24px; font-size: 14px; color: #E3C89C; }
.iv-cs-dno p { color: #E3C89C; font-size: 14px; text-align: center; line-height: normal; }
@media (max-width: 560px) {
	.iv-cs-scena { width: min(280px, 76vw); }
	.iv-cs-logo img { width: 76px; height: 76px; }
}

@media (prefers-reduced-motion: reduce) {
	.iv-root *, .iv-cs * { animation: none !important; transition: none !important; }
}
/* Prototip: natpis je span (bez text-wrap: pretty iz p). */
.elementor-widget.iv-cs-natpis p { text-wrap-style: auto; }
