/* RECIMI – glavni stilovi
   Paleta: tamnoplava, plava i zelena iz zadanog uzorka boja. */

:root {
	--navy: #333f66;
	--blue: #24559a;
	--green: #2f7f46;
	--green-soft: #8fd0a2;   /* zelena za tamnu pozadinu */
	--mist: #eef2f8;
	--mist-2: #dfe6f1;
	--paper: #ffffff;
	--text: #1e2433;
	--muted: #525c72;
	--rule: #ccd5e4;

	--font-display: "Schibsted Grotesk", "Segoe UI", system-ui, sans-serif;
	--font-body: "Source Serif 4", Georgia, "Times New Roman", serif;

	--step--1: 0.875rem;
	--step-0: 1.125rem;
	--step-1: 1.375rem;
	--step-2: 1.75rem;
	--step-3: clamp(1.625rem, 1.25rem + 1.4vw, 2.25rem);
	--step-4: clamp(2rem, 1.4rem + 2.4vw, 3.25rem);

	--gutter: clamp(1rem, 4vw, 3rem);
	--section: clamp(4rem, 8vw, 7rem);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 6rem; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
	margin: 0;
	background: var(--paper);
	color: var(--text);
	font-family: var(--font-body);
	font-size: var(--step-0);
	line-height: 1.7;
}

img, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--blue); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--green); outline-offset: 3px; border-radius: 2px; }

h1, h2, h3, h4 { font-family: var(--font-display); color: var(--navy); line-height: 1.15; margin: 0 0 0.6em; font-weight: 700; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }

.wrap { width: 100%; max-width: 1200px; margin-inline: auto; padding-inline: var(--gutter); }

.screen-reader-text {
	position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
	overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link { position: absolute; left: 1rem; top: -4rem; z-index: 100; background: var(--green); color: #fff; padding: 0.6rem 1rem; font: 700 1rem var(--font-display); }
.skip-link:focus { top: 1rem; }

/* ---------- Zaglavlje ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--paper); border-bottom: 1px solid var(--rule); }
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 0; position: relative; } }

.site-header__inner {
	max-width: 1200px; margin-inline: auto; padding: 0.7rem var(--gutter);
	display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 1.5rem;
}
.brand { display: flex; align-items: center; gap: 0.75rem; text-decoration: none; color: var(--navy); }
.brand__seal { width: 50px; height: 50px; object-fit: contain; }
.brand__text { display: flex; flex-direction: column; line-height: 1.15; }
.brand__name { font-family: var(--font-display); font-weight: 800; font-size: 1.375rem; letter-spacing: 0.01em; color: var(--blue); }
.brand__sub { font-family: var(--font-display); font-size: 0.75rem; color: var(--muted); }

.nav__list { list-style: none; margin: 0; padding: 0; display: flex; justify-content: center; gap: 0.25rem 1.5rem; flex-wrap: wrap; }
.nav__list a { font-family: var(--font-display); color: var(--navy); text-decoration: none; font-weight: 600; font-size: 0.9375rem; padding: 0.4rem 0; border-bottom: 2px solid transparent; }
.nav__list a:hover, .nav__list .current-menu-item > a { border-bottom-color: var(--green); }

.site-header__eu { width: 187px; }
.nav-toggle { display: none; }

@media (max-width: 1080px) {
	.site-header__inner { grid-template-columns: 1fr auto; grid-template-areas: "brand toggle" "eu eu" "nav nav"; gap: 0.5rem 1rem; }
	.brand { grid-area: brand; }
	.site-header__eu { grid-area: eu; width: 150px; }
	.nav { grid-area: nav; display: none; }
	.nav-open .nav { display: block; }
	.nav__list { flex-direction: column; align-items: stretch; gap: 0; padding-block: 0.5rem; }
	.nav__list a { display: block; padding: 0.7rem 0; border-bottom: 1px solid var(--rule); }
	.nav-toggle {
		grid-area: toggle; display: inline-flex; align-items: center; gap: 0.5rem;
		background: none; border: 1px solid var(--rule); border-radius: 999px; padding: 0.45rem 0.9rem;
		font: 600 0.875rem var(--font-display); color: var(--navy); cursor: pointer;
	}
	.nav-toggle__bars, .nav-toggle__bars::before, .nav-toggle__bars::after { display: block; width: 16px; height: 2px; background: currentColor; position: relative; }
	.nav-toggle__bars::before, .nav-toggle__bars::after { content: ""; position: absolute; left: 0; }
	.nav-toggle__bars::before { top: -5px; }
	.nav-toggle__bars::after { top: 5px; }
	.nav-open .nav-toggle__bars { background: transparent; }
	.nav-open .nav-toggle__bars::before { top: 0; transform: rotate(45deg); }
	.nav-open .nav-toggle__bars::after { top: 0; transform: rotate(-45deg); }
}

/* ---------- Uvodni dio ---------- */
.hero { padding-block: clamp(3rem, 7vw, 6rem); border-bottom: 1px solid var(--rule); }
.hero__grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: clamp(2rem, 6vw, 5rem); align-items: center; }

.hero__acronym {
	font-family: var(--font-display); font-weight: 800; color: var(--blue);
	font-size: clamp(3.5rem, 1rem + 10vw, 9.25rem); line-height: 0.85; letter-spacing: -0.045em;
	margin: 0 0 0.3em -0.04em; display: flex; align-items: flex-end;
}
.hero__cursor {
	flex: none; display: inline-block; width: 0.09em; height: 0.72em; margin: 0 0 0.04em 0.08em;
	background: var(--green);
	animation: recimi-blink 1.05s steps(1) 6 both;
}
@keyframes recimi-blink { 50% { opacity: 0; } }

.hero__title { font-size: var(--step-3); font-weight: 700; max-width: 26ch; margin-bottom: 0.75em; }
.hero__lead { font-size: var(--step-1); line-height: 1.55; color: var(--muted); max-width: 40ch; margin: 0; }

.rag { margin: 0; background: var(--mist); border-radius: 12px; padding: clamp(1.25rem, 3vw, 2rem); }
.rag__caption { font: 600 0.9375rem/1.4 var(--font-display); color: var(--navy); margin-bottom: 1.25rem; max-width: 30ch; }
.rag__steps { list-style: none; margin: 0; padding: 0; }
.rag__step {
	position: relative; display: flex; flex-direction: column;
	padding: 0 0 1.4rem 2.5rem;
	animation: recimi-step 0.45s ease-out both; animation-delay: calc(0.25s + var(--i) * 0.35s);
}
.rag__step:last-child { padding-bottom: 0; }
.rag__step::before {
	content: ""; position: absolute; left: 0; top: 0.2rem; width: 1.25rem; height: 1.25rem; border-radius: 50%;
	background: var(--paper); border: 3px solid var(--blue);
}
.rag__step:not(:last-child)::after {
	content: ""; position: absolute; left: calc(0.625rem - 1.5px); top: 1.55rem; bottom: 0.15rem; width: 3px; background: var(--blue); opacity: 0.35;
}
.rag__step:last-child::before { background: var(--green); border-color: var(--green); }
.rag__name { font: 700 1.125rem/1.3 var(--font-display); color: var(--navy); }
.rag__step:last-child .rag__name { color: var(--green); }
.rag__note { font-size: 0.9375rem; color: var(--muted); line-height: 1.45; }
@keyframes recimi-step { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
	.hero__cursor, .rag__step { animation: none; }
}
@media (max-width: 900px) {
	.hero__grid { grid-template-columns: 1fr; }
	.rag { max-width: 34rem; }
}

/* ---------- Sekcije ---------- */
.section { padding-block: var(--section); }
.section--tint { background: var(--mist); }
.section__title { font-size: var(--step-4); font-weight: 800; letter-spacing: -0.025em; }
.section__intro { font-size: var(--step-1); line-height: 1.55; color: var(--muted); max-width: 54ch; margin-bottom: 2.75rem; }
.sub__heading { font-size: var(--step-1); font-weight: 700; margin-bottom: 1.25rem; }

/* O projektu */
.about { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: clamp(2rem, 6vw, 5rem); align-items: start; margin-bottom: clamp(3rem, 7vw, 5rem); }
.about__text p { max-width: 64ch; }
.about__text p:first-of-type { font-size: var(--step-1); line-height: 1.55; color: var(--navy); }
.facts { margin: 0; border-top: 3px solid var(--navy); }
.facts__row { padding: 0.8rem 0; border-bottom: 1px solid var(--rule); }
.facts dt { font: 500 var(--step--1) var(--font-display); color: var(--muted); }
.facts dd { margin: 0.1rem 0 0; font: 600 1rem/1.45 var(--font-display); color: var(--navy); }
@media (max-width: 860px) { .about { grid-template-columns: 1fr; } }

.areas { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.5rem clamp(1.25rem, 3vw, 2.5rem); }
.areas li { border-top: 4px solid var(--blue); padding-top: 1rem; }
.areas h4 { font-size: 1.1875rem; margin-bottom: 0.4em; }
.areas p { font-size: 1rem; line-height: 1.55; color: var(--muted); margin: 0; }
@media (max-width: 960px) { .areas { grid-template-columns: 1fr 1fr; } }
@media (max-width: 540px) { .areas { grid-template-columns: 1fr; } }

/* Ciljevi */
#ciljevi { background: var(--navy); color: #dfe5f2; }
#ciljevi .section__title, #ciljevi .sub__heading, #ciljevi h4 { color: #fff; }
.goal-main {
	font: 500 var(--step-3)/1.3 var(--font-display); color: #fff; letter-spacing: -0.01em;
	max-width: 34ch; margin: 0 0 clamp(2.5rem, 6vw, 4.5rem);
	padding-left: 1.25rem; border-left: 6px solid var(--green-soft);
}
.goals { list-style: none; margin: 0; padding: 0; counter-reset: cilj; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 clamp(1.5rem, 4vw, 3rem); }
.goals li { counter-increment: cilj; border-top: 1px solid rgba(255, 255, 255, 0.25); padding-top: 1rem; font-size: 1.0625rem; line-height: 1.6; }
.goals li::before { content: counter(cilj); display: block; font: 800 2.25rem/1 var(--font-display); color: var(--green-soft); margin-bottom: 0.6rem; }
.strategic { margin-top: clamp(3rem, 7vw, 4.5rem); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 clamp(2rem, 5vw, 4rem); }
.strategic .sub__heading { grid-column: 1 / -1; }
.strategic__item h4 { font-size: 1.0625rem; line-height: 1.35; margin-bottom: 0.4em; }
.strategic__item p { color: #c4cde2; font-size: 1rem; }
@media (max-width: 860px) { .goals, .strategic { grid-template-columns: 1fr; } .goals li { padding-bottom: 1.5rem; } }

/* Radni paketi – vremenski plan po mjesecima */
.gantt { border-top: 1px solid var(--rule); }
.gantt__scale, .gantt__row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: clamp(1.25rem, 4vw, 3rem); }
.gantt__scale { padding: 0.75rem 0 0.6rem; border-bottom: 1px solid var(--rule); }
.gantt__years { display: grid; grid-template-columns: repeat(4, 1fr); }
.gantt__years span { font: 600 var(--step--1) var(--font-display); color: var(--muted); padding-left: 0.5rem; border-left: 1px solid var(--rule); }

.gantt__row { padding: 1.5rem 0; border-bottom: 1px solid var(--rule); align-items: center; }
.gantt__title { font-size: 1.1875rem; margin-bottom: 0.35em; }
.gantt__code { display: inline-block; font-size: 0.8125rem; font-weight: 700; color: #fff; background: var(--blue); border-radius: 4px; padding: 0.1rem 0.45rem; margin-right: 0.35rem; vertical-align: 0.15em; }
.gantt__info p { font-size: 1rem; line-height: 1.55; color: var(--muted); margin: 0; max-width: 56ch; }
.gantt__track {
	position: relative; height: 2.25rem;
	background-image: linear-gradient(to right, var(--rule) 1px, transparent 1px);
	background-size: 25% 100%;
}
.gantt__bar {
	position: absolute; top: 0.375rem; bottom: 0.375rem;
	left: calc((var(--od) - 1) / 48 * 100%);
	width: calc((var(--do) - var(--od) + 1) / 48 * 100%);
	background: var(--blue); border-radius: 4px;
	display: flex; align-items: center; padding-inline: 0.6rem; overflow: hidden;
}
.gantt__months { font: 600 0.8125rem var(--font-display); color: #fff; white-space: nowrap; }

@media (max-width: 860px) {
	.gantt__scale { display: none; }
	.gantt__row { grid-template-columns: 1fr; gap: 0.9rem; }
	.gantt__track { background-size: 25% 100%; border-right: 1px solid var(--rule); }
}

/* Tim */
.avatar {
	flex: none; display: grid; place-items: center;
	width: 4rem; height: 4rem; border-radius: 50%; object-fit: cover;
	background: var(--navy); color: #fff; font: 700 1.125rem var(--font-display);
}
.avatar--lead { width: 9rem; height: 9rem; font-size: 2.75rem; background: var(--blue); }

.lead {
	display: flex; gap: clamp(1.5rem, 4vw, 3rem); align-items: flex-start;
	background: var(--paper); padding: clamp(1.5rem, 4vw, 2.75rem); border-radius: 10px;
	border-left: 6px solid var(--green); margin-bottom: clamp(3rem, 7vw, 4.5rem);
}
.lead__role { font: 700 1rem var(--font-display); color: var(--green); margin-bottom: 0.25rem; }
.lead__name { font-size: var(--step-3); margin-bottom: 0.2em; }
.lead__position { font-family: var(--font-display); color: var(--muted); font-size: 1rem; }
.lead__bio { max-width: 66ch; }
@media (max-width: 640px) { .lead { flex-direction: column; } .avatar--lead { width: 6rem; height: 6rem; font-size: 1.875rem; } }

.field { margin-bottom: clamp(2.5rem, 6vw, 4rem); }
.field:last-child { margin-bottom: 0; }
.field__heading { font-size: var(--step-1); padding-bottom: 0.75rem; border-bottom: 2px solid var(--navy); margin-bottom: 0; }

.team { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: clamp(2rem, 5vw, 4rem); }
.person { display: flex; gap: 1.25rem; padding: 1.5rem 0; border-bottom: 1px solid var(--rule); }
.person__name { font-size: 1.25rem; margin-bottom: 0.15em; }
.person__position { font-family: var(--font-display); color: var(--muted); font-size: 0.9375rem; margin-bottom: 0.5rem; }
.person__focus { font-size: 1.0625rem; line-height: 1.55; margin-bottom: 0.75rem; }
.person__link { font: 600 0.9375rem var(--font-display); }
@media (max-width: 760px) { .team { grid-template-columns: 1fr; } }

.rpm { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.75rem; }
.rpm__label { font: 500 0.8125rem var(--font-display); color: var(--muted); }
.rpm__cells { list-style: none; margin: 0; padding: 0; display: flex; gap: 3px; }
.rpm__cell {
	width: 1.5rem; height: 1.5rem; display: grid; place-items: center; border-radius: 3px;
	font: 700 0.75rem var(--font-display); color: #8b95aa; border: 1px solid var(--rule); background: var(--paper);
}
.rpm__cell.is-on { background: var(--green); border-color: var(--green); color: #fff; }

.support { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: clamp(1.5rem, 4vw, 3rem); }
.support li { display: flex; flex-direction: column; gap: 0.15rem; padding: 1rem 0; border-bottom: 1px solid var(--rule); line-height: 1.4; }
.support strong { font: 700 1.0625rem var(--font-display); color: var(--navy); }
.support span { font-size: 0.9375rem; color: var(--muted); }
@media (max-width: 960px) { .support { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .support { grid-template-columns: 1fr; } }

/* Rezultati */
.indicators { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 14rem), 1fr)); gap: 0 clamp(1.5rem, 4vw, 3rem); }
.indicators li { display: flex; flex-direction: column; gap: 0.4rem; padding: 1.25rem 0 1.75rem; border-top: 1px solid var(--rule); }
.indicators li.is-programme { border-top: 3px solid var(--green); }
.indicators li.is-programme .indicators__value { color: var(--green); }
.indicators__tag { font: 600 0.8125rem var(--font-display); color: var(--green); }
.indicators__value { font: 800 2.75rem/1 var(--font-display); color: var(--blue); letter-spacing: -0.03em; }
.indicators__label { font-size: 1rem; line-height: 1.5; max-width: 30ch; }

/* Novosti */
.section--news { border-top: 1px solid var(--rule); }
.news { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem; }
.news--archive { grid-template-columns: 1fr; max-width: 760px; }
.news__item { border-top: 3px solid var(--green); padding-top: 1rem; }
.news__item time { font: 500 var(--step--1) var(--font-display); color: var(--muted); }
.news__item h2, .news__item h3 { font-size: var(--step-1); margin: 0.3em 0 0.4em; }
.news__item h2 a, .news__item h3 a { color: var(--navy); text-decoration: none; }
.news__item h2 a:hover, .news__item h3 a:hover { text-decoration: underline; }
.news__item p { color: var(--muted); font-size: 1rem; }
.news__empty { color: var(--muted); max-width: 60ch; }
@media (max-width: 860px) { .news { grid-template-columns: 1fr; } }

/* Podstranice */
.page-head { background: var(--navy); color: #fff; padding-block: clamp(2.5rem, 6vw, 4.5rem); }
.page-head__title { color: #fff; font-size: var(--step-4); max-width: 24ch; margin: 0; }
.page-head__date { display: block; font: 500 var(--step--1) var(--font-display); color: #c4cde2; margin-bottom: 0.75rem; }
.entry { max-width: 68ch; }
.entry h2 { font-size: var(--step-3); margin-top: 1.5em; }
.entry h3 { font-size: var(--step-2); margin-top: 1.4em; }
.entry blockquote { margin: 1.5em 0; padding-left: 1.25rem; border-left: 4px solid var(--green); color: var(--navy); font-size: var(--step-1); }
.entry img { border-radius: 6px; }
.entry__image { margin: 0 0 2.5rem; }
.entry__image img { width: 100%; border-radius: 8px; }
.nav-links { display: flex; gap: 1rem; margin-top: 2.5rem; font: 600 1rem var(--font-display); }
.has-tamnoplava-color { color: var(--navy); } .has-tamnoplava-background-color { background-color: var(--navy); }
.has-plava-color { color: var(--blue); } .has-plava-background-color { background-color: var(--blue); }
.has-zelena-color { color: var(--green); } .has-zelena-background-color { background-color: var(--green); }
.has-svijetloplava-color { color: var(--mist); } .has-svijetloplava-background-color { background-color: var(--mist); }
.has-bijela-color { color: #fff; } .has-bijela-background-color { background-color: #fff; }

/* ---------- Podnožje ---------- */
.site-footer { background: var(--navy); color: #d7deec; font-size: 1rem; }
.site-footer__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr) auto; gap: clamp(2rem, 5vw, 4rem); padding-block: clamp(3rem, 6vw, 4.5rem); align-items: start; }
.site-footer__name { font: 800 2rem/1 var(--font-display); color: #fff; margin-bottom: 0.5em; }
.site-footer__name::after { content: ""; display: inline-block; width: 0.12em; height: 0.75em; margin-left: 0.08em; background: var(--green-soft); }
.site-footer__muted { color: #aab5cf; }
.site-footer__funding img { width: 260px; margin-bottom: 1.25rem; }
.site-footer__disclaimer { font-size: var(--step--1); line-height: 1.6; color: #bcc6dc; max-width: 60ch; }
.site-footer__seal { width: 96px; height: 96px; object-fit: contain; opacity: 0.85; }
.site-footer__base { padding-block: 0 1.5rem; font-size: var(--step--1); color: #aab5cf; }
.site-footer__base p { margin: 0; padding-top: 1.25rem; border-top: 1px solid rgba(255, 255, 255, 0.18); }
.site-footer a { color: #fff; }
@media (max-width: 860px) { .site-footer__grid { grid-template-columns: 1fr; } }

@media print {
	.site-header, .nav-toggle, .rag { display: none; }
	#ciljevi, .page-head { background: none; color: var(--text); }
	#ciljevi .section__title, #ciljevi h4, .goal-main, .page-head__title { color: var(--navy); }
}
