/* @font-face uvijek na početku */
/* roboto-regular */
@font-face {
  font-family: "Roboto";
  font-style: normal;
  font-weight: 400;
  src: url("../fonts/roboto/roboto-v51-latin_latin-ext-regular.woff2")
    format("woff2");
}

/* roboto-700 */
@font-face {
  font-family: "Roboto";
  font-style: normal;
  font-weight: 700;
  src: url("../fonts/roboto/roboto-v51-latin_latin-ext-700.woff2")
    format("woff2");
}

/* lato-700 */
@font-face {
  font-family: "Lato";
  font-style: normal;
  font-weight: 700;
  src: url("../fonts/lato/lato-v25-latin_latin-ext-700.woff2") format("woff2");
}

body {
  font-family: "Roboto", sans-serif;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "Lato", sans-serif;
  font-weight: bold;
}

h2,
h3 {
  margin-bottom: 1rem;
}

/* =============================================================================
   BOJE / COLORS
   ============================================================================= */

:root {
  --bs-primary: #0067b4;
  --bs-primary-rgb: 0, 103, 180;
  --bs-primary-dark: #004a82;
  --bs-primary-darker: #003d6b;
  --bs-primary-light: #3385c3;
  --bs-primary-lighter: #e6f0f8;
}

.btn-primary {
  --bs-btn-color: #fff;
  --bs-btn-bg: #0067b4;
  --bs-btn-border-color: #0067b4;
  --bs-btn-hover-color: #fff;
  --bs-btn-hover-bg: #005696;
  --bs-btn-hover-border-color: #004a82;
  --bs-btn-active-color: #fff;
  --bs-btn-active-bg: #004a82;
  --bs-btn-active-border-color: #003d6b;
  --bs-btn-focus-shadow-rgb: 0, 103, 180;
}

a {
  color: #0067b4;
}

a:hover {
  color: #004a82;
}

.bg-primary-light {
  background-color: #e6f0f8;
}

.bg-primary-dark {
  background-color: #004a82;
}

.bg-primary-lighter {
  background-color: #e6f0f8;
}

.border-primary {
  border-color: #0067b4 !important;
}

/* =============================================================================
   LAYOUT HELPERS
   ============================================================================= */

.mh660 {
  min-height: 660px;
}

.mt6rem {
  margin-top: 6rem;
}

.p2rem {
  padding-top: 2rem;
  padding-bottom: 2rem;
}

@media (min-width: 992px) {
  .p-5rem-lg {
    padding: 5rem !important;
  }
}

/* =============================================================================
   PAGE HERO
   Plava header sekcija na unutarnjim stranicama (page.php, single.php,
   archive.php, category.php, page-gradani.php, page-poslovni.php itd.)
   Breadcrumb linkovi koriste text-white-50 za diskretni prikaz.
   ============================================================================= */

.page-hero {
  padding-top: 3rem;
  padding-bottom: 3rem;
}

.page-hero .breadcrumb-item + .breadcrumb-item::before {
  color: rgba(255, 255, 255, 0.4);
}

.page-hero .breadcrumb-item a {
  text-decoration: none;
  transition: color 0.2s ease;
}

.page-hero .breadcrumb-item a:hover {
  color: #fff !important;
}

/* =============================================================================
   PAGE CONTENT
   Stilovi za sadržaj statičnih stranica (page.php).
   WordPress Gutenberg blokovi generiraju specifične klase —
   osiguravamo konzistentan izgled unutar teme.
   ============================================================================= */

.page-content,
.post-content {
  line-height: 1.8;
  font-size: 1rem;
  color: #333;
}

.page-content h2,
.post-content h2 {
  margin-top: 2rem;
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

.page-content h3,
.post-content h3 {
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
  font-size: 1.25rem;
}

.page-content p,
.post-content p {
  margin-bottom: 1.25rem;
}

.page-content ul,
.page-content ol,
.post-content ul,
.post-content ol {
  margin-bottom: 1.25rem;
  padding-left: 1.5rem;
}

.page-content li,
.post-content li {
  margin-bottom: 0.4rem;
}

.page-content a,
.post-content a {
  text-decoration: underline;
}

.page-content a:hover,
.post-content a:hover {
  text-decoration: none;
}

.page-content img,
.post-content img {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
}

/* WordPress alignment klase — Gutenberg */
.page-content .alignleft,
.post-content .alignleft {
  float: left;
  margin: 0 1.5rem 1rem 0;
}

.page-content .alignright,
.post-content .alignright {
  float: right;
  margin: 0 0 1rem 1.5rem;
}

.page-content .aligncenter,
.post-content .aligncenter {
  display: block;
  margin: 1rem auto;
}

/* WordPress tablica — konzistentna s Bootstrap stilom */
.page-content table,
.post-content table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.25rem;
  font-size: 0.9rem;
}

.page-content table th,
.post-content table th {
  background-color: #e6f0f8;
  padding: 0.5rem 0.75rem;
  text-align: left;
  font-weight: 700;
  border-bottom: 2px solid #0067b4;
}

.page-content table td,
.post-content table td {
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid #dee2e6;
}

.page-content table tr:hover td,
.post-content table tr:hover td {
  background-color: #f8f9fa;
}

/* =============================================================================
   HITNA OBAVIJEST BANNER
   ============================================================================= */

.alert-hitno {
  background-color: #dc3545;
  color: #fff;
  padding: 0.6rem 0;
  font-size: 0.875rem;
  line-height: 1.4;
}

.alert-hitno__icon {
  font-size: 1rem;
  flex-shrink: 0;
}

.alert-hitno__text {
  flex: 1;
}

.alert-hitno__link {
  color: #fff;
  font-weight: 600;
  text-decoration: underline;
  white-space: nowrap;
  flex-shrink: 0;
}

.alert-hitno__link:hover {
  color: rgba(255, 255, 255, 0.85);
}

@media (max-width: 767.98px) {
  .alert-hitno .d-flex {
    flex-direction: column;
    align-items: center !important;
    text-align: center;
    gap: 0.25rem !important;
  }

  .alert-hitno__link {
    margin-left: 0 !important;
  }
}

/* =============================================================================
   NAPOMENA O AKTUALNOSTI — "mozda vise nije aktualno"
   Dodaj u assets/css/style.css (npr. odmah nakon .alert-hitno bloka).
   Mekan, diskretan stil — žuta/jantar nijansa, ne agresivno crveno.
   ============================================================================= */

.napomena-aktualnost {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.85rem 1.1rem;
  margin-bottom: 1.5rem;
  background-color: #fff8e6; /* blago jantarna pozadina */
  border: 1px solid #ffe5a0;
  border-left: 4px solid #f0ad4e; /* naglasak s lijeve strane */
  border-radius: 4px;
  color: #6b5320;
  font-size: 0.925rem;
  line-height: 1.5;
}

.napomena-aktualnost__icon {
  flex-shrink: 0;
  font-size: 1.1rem;
  margin-top: 0.1rem;
  color: #d9941f;
}

/* =============================================================================
   VIZUALNI TAGOVI KATEGORIJA VIJESTI
   ============================================================================= */

.tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 700;
  text-decoration: none;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  transition: opacity 0.2s ease;
}

.tag:hover {
  opacity: 0.85;
  text-decoration: none;
}

.tag-hitno {
  background-color: #dc3545;
  color: #fff;
}

.tag-upozorenje {
  background-color: #ffc107;
  color: #000;
}

.tag-obavijest {
  background-color: #0067b4;
  color: #fff;
}

.tag-novost {
  background-color: #6c757d;
  color: #fff;
}

/* Aktivni tag u filter traci */
.tag.active-tag {
  outline: 2px solid currentColor;
  outline-offset: 2px;
}

/* =============================================================================
   BACKGROUND IMAGES
   ============================================================================= */

.bgimagehero {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  min-height: 85vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 4rem;
  padding-bottom: 4rem;
}

.bgblue {
  --bg-image: url("");
  background:
    linear-gradient(rgba(0, 103, 180, 0.9), rgba(0, 103, 180, 0.9)),
    var(--bg-image) no-repeat center center;
  background-size: cover;
  padding: 5rem 0;
}

.bgblue-image-1 {
  --bg-image: url("../images/photo-1554224155-6726b3ff858f.avif");
}

.bgshowcase {
  --bg-image: url("");
  background: var(--bg-image) no-repeat center center;
  background-size: cover;
  min-height: 400px;
}

.bgshowcase-image-1 {
  --bg-image: url("../images/photo-1579621970563-ebec7560ff3e.avif");
}

.bgshowcase-image-2 {
  --bg-image: url("../images/photo-1450101499163-c8848c66ca85.avif");
}

.bgshowcase-image-3 {
  --bg-image: url("../images/photo-1563906267088-b029e7101114.avif");
}

/* =============================================================================
   DEKORATIVNA LINIJA (PLETER)
   ============================================================================= */

.hr-pleter {
  height: 25px;
  width: 100%;
  background-image: url("../images/border.png");
  background-repeat: repeat-x;
  background-size: auto 100%;
  margin: 0;
}

.hr-pleter-bottom {
  background-image: url("../images/border-bottom.png");
}

/* =============================================================================
   KARTICE / CARDS
   ============================================================================= */

.card-news {
  transition: transform 0.3s;
  border: none;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.card-news:hover {
  transform: translateY(-5px);
}

/* Kartice usluga — page-gradani.php, page-poslovni.php */
.card-usluga {
  transition:
    transform 0.3s,
    box-shadow 0.3s;
}

.card-usluga:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12) !important;
}

.card-usluga .icon-wrapper i {
  transition: transform 0.3s ease;
}

.card-usluga:hover .icon-wrapper i {
  transform: scale(1.1);
}

/* =============================================================================
   TEČAJNA LISTA
   ============================================================================= */

.tecajna-tablica th,
.tecajna-tablica td {
  font-size: 0.85rem;
  padding: 0.4rem 0.6rem;
  vertical-align: middle;
}

.tecajna-tablica tbody tr:hover {
  background-color: #f0f6fb;
}

/* =============================================================================
   HERO (naslovnica)
   ============================================================================= */

@media (min-width: 1200px) {
  .hero-text {
    font-size: 3rem;
  }
}

/* =============================================================================
   FEATURES ICONS
   ============================================================================= */

.features-icons .features-icons-item .features-icons-icon i {
  font-size: 4.5rem;
}

/* =============================================================================
   TESTIMONIALS
   ============================================================================= */

.testimonials .container {
  padding-top: 7rem;
  padding-bottom: 7rem;
}

.testimonials .testimonial-item {
  max-width: 18rem;
}

.testimonials .testimonial-item img {
  max-width: 12rem;
  box-shadow: 0px 5px 5px 0px #adb5bd;
}

/* =============================================================================
   NAVIGACIJA / NAVBAR
   ============================================================================= */

.navbar {
  position: sticky;
  top: 0;
  z-index: 9999;
  margin-bottom: 0;
}

.bgcolormenu {
  background-color: rgb(200, 202, 244, 0.2);
}

.navbar .nav-link {
  position: relative;
  text-decoration: none;
}

.navbar .nav-link::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 0;
  height: 2px;
  background-color: #0067b4;
  transition: all 0.3s ease;
  transform: translateX(-50%);
}

.navbar .nav-link:hover::before {
  width: 100%;
}

.navbar .dropdown-toggle::before {
  display: none;
}

.current-menu-item > a {
  font-weight: 700;
}

/* =============================================================================
   DROPDOWN PODMENI
   ============================================================================= */

.dropdown-menu .dropdown-item:hover {
  background-color: #e6f0f8;
  color: #0067b4;
}

.dropdown-menu .dropdown-item.active,
.dropdown-menu .dropdown-item:active {
  background-color: #0067b4;
  color: #fff;
}

/* =============================================================================
   FOOTER NAVIGACIJA
   ============================================================================= */

.footer-menu {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-menu li {
  display: inline-block;
  margin-right: 10px;
}

.footer-menu li:not(:last-child)::after {
  content: "⋅";
  margin: 0 10px;
  color: #999;
}

.footer-menu a {
  position: relative;
  text-decoration: none;
}

.footer-menu a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background-color: #0067b4;
  transition: width 0.3s ease;
}

.footer-menu a:hover::after {
  width: 100%;
}

/* =============================================================================
   LINKOVI / LINKS
   ============================================================================= */

.link-underline-animate {
  position: relative;
  text-decoration: none;
}

.link-underline-animate::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background-color: #0067b4;
  transition: width 0.3s ease;
}

.link-underline-animate:hover::after {
  width: 100%;
}

/* CTA gumb u navbaru — mobilni razmak */
@media (max-width: 767.98px) {
  .navbar-cta {
    padding-bottom: 0.5rem;
  }
}

/* =============================================================================
   PRISTUPAČNOST / ACCESSIBILITY — WCAG 2.1 AA
   ============================================================================= */

/*
  SKIP TO CONTENT
  Vidljiv samo kad dobije keyboard focus — skriva se vizualno ali
  ostaje dostupan screen readerima i keyboard korisnicima.
  Pojavljuje se u gornjem lijevom kutu pri fokusiranju tipkovnicom (Tab).
*/
.skip-to-content {
  position: absolute;
  top: -100%;
  left: 1rem;
  z-index: 99999;
  padding: 0.75rem 1.5rem;
  background-color: #0067b4;
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  border-radius: 0 0 4px 4px;
  transition: top 0.2s ease;
}

.skip-to-content:focus {
  top: 0;
  color: #fff;
}

/*
  FOCUS STILOVI — keyboard navigacija
  Bootstrap uklanja outline na fokusiranim elementima u nekim slučajevima.
  Vraćamo vidljiv focus indicator u boji teme za WCAG 2.1 AA sukladnost.
  Focus vidljiv za sve interaktivne elemente: linkovi, gumbi, input polja.
*/
:focus-visible {
  outline: 3px solid #0067b4;
  outline-offset: 2px;
}

/*
  Isključi focus ring na elementima koji ga ne trebaju
  (dekorativni elementi, elementi koji nikad ne dobivaju focus tipkovnicom)
*/
.hr-pleter:focus,
.hr-pleter-bottom:focus {
  outline: none;
}

/*
  Bootstrap override — Bootstrap 5 koristi box-shadow za focus,
  ali mi koristimo outline koji je vidljiviji i standardniji.
*/
.btn:focus-visible {
  outline: 3px solid #0067b4;
  outline-offset: 2px;
  box-shadow: none;
}

.nav-link:focus-visible {
  outline: 3px solid #0067b4;
  outline-offset: 2px;
}

/*
  SCREEN READER ONLY
  Vizualno skriveni tekst koji screen readeri mogu pročitati.
  Koristiti za dodatni kontekst koji nije vizualno potreban
  ali je važan za razumijevanje (npr. "otvara se u novom tabu").
  WordPress već ima .screen-reader-text klasu, ovo je naša verzija.
*/
.sr-only,
.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/*
  REDUCED MOTION
  Poštujemo preferencije korisnika koji imaju osjetljivost na animacije.
  prefers-reduced-motion: reduce — isključuje sve animacije i tranzicije.
*/
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
