/* CAD Lovćen — Modern minimal / Institutional */

:root {
  --navy: #0e2540;
  --navy-deep: #081a30;
  --gold: #c89a2c;
  --bg: #ffffff;
  --bg-alt: #f4f5f7;
  --ink: #0e2540;
  --muted: #5a6675;
  --line: rgba(200, 154, 44, 0.2);
  --line-strong: #cbd2dc;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a { color: var(--navy); text-decoration: none; transition: color 0.2s var(--ease); }
a:hover { color: var(--gold); }

::selection { background: var(--gold); color: var(--navy-deep); }

/* ----------  Header ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  gap: 32px;
  align-items: center;
  padding: 18px 48px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease), padding 0.3s var(--ease);
}
.site-header.is-scrolled { border-bottom-color: var(--line); padding: 12px 48px; }

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--navy);
  opacity: 1;
  transform: translateX(0);
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease), visibility 0s linear 0s;
}
body[data-active-section="pocetna"] .brand {
  opacity: 0;
  transform: translateX(-8px);
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0s linear 0.3s;
}
.brand-mark { width: 44px; height: 44px; border-radius: 4px; }

.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 36px; justify-content: center; }
.site-nav a {
  position: relative;
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 8px 0;
}
.site-nav a:hover, .site-nav a.is-active { color: var(--navy); }
.site-nav a.is-active::before {
  content: '';
  position: absolute;
  left: 0; top: -3px;
  width: 16px; height: 2px;
  background: var(--gold);
}

.lang-switch { display: inline-flex; align-items: center; gap: 0; border-left: 1px solid var(--line); padding-left: 24px; }
.lang-switch button {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 6px 10px;
  font: 700 0.7rem 'Inter', sans-serif;
  letter-spacing: 0.2em;
  color: var(--muted);
  cursor: pointer;
  transition: color 0.2s var(--ease);
}
.lang-switch button:hover { color: var(--navy); }
.lang-switch button.is-active { color: var(--navy); position: relative; }
.lang-switch button.is-active::after {
  content: '';
  position: absolute;
  left: 10px; right: 10px; bottom: 0;
  height: 2px; background: var(--gold);
}

.nav-toggle { display: none; background: 0; border: 0; cursor: pointer; padding: 0; width: 32px; height: 32px; flex-direction: column; justify-content: center; gap: 5px; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--navy); transition: transform 0.3s var(--ease), opacity 0.3s var(--ease); }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Section base ---------- */
.section {
  min-height: 100vh;
  padding: 140px 48px 100px;
  display: flex;
  align-items: center;
  position: relative;
}
.section-inner { width: 100%; max-width: 1200px; margin: 0 auto; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 22px;
}
.eyebrow::before { content: ''; width: 28px; height: 2px; background: var(--gold); }

.section-title {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  color: var(--navy);
  font-size: clamp(2.4rem, 5vw, 4rem);
  line-height: 1.05;
  letter-spacing: -0.025em;
  margin: 0 0 32px;
}

/* ---------- Hero ---------- */
.section--hero {
  padding: 0;
  background: var(--bg);
  min-height: 100vh;
}
.hero-split {
  display: grid;
  grid-template-columns: 5fr 7fr;
  width: 100%;
  min-height: 100vh;
}
.hero-panel {
  background: var(--navy);
  color: #fff;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}
.hero-panel::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.hero-logo {
  width: 300px;
  height: auto;
  border-radius: 50%;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.4);
  position: relative;
  z-index: 1;
  animation: fadeUp 1.1s var(--ease) both;
}
.hero-panel-meta {
  margin-top: 56px;
  font-size: 0.72rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
  position: relative;
  z-index: 1;
  animation: fadeUp 1.1s var(--ease) 0.2s both;
}
.hero-panel-meta span { display: block; margin-bottom: 6px; color: var(--gold); }

.hero-content {
  padding: 140px 80px 80px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--bg);
}
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 28px;
  animation: fadeUp 1s var(--ease) 0.1s both;
}
.hero-eyebrow::before { content: ''; width: 28px; height: 2px; background: var(--gold); }

.hero-title {
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  font-size: clamp(2.4rem, 4.6vw, 4rem);
  line-height: 1.02;
  color: var(--navy);
  letter-spacing: -0.03em;
  margin: 0 0 18px;
  animation: fadeUp 1s var(--ease) 0.2s both;
}
.hero-subtitle {
  font-family: 'Inter', sans-serif;
  font-weight: 800;
  font-size: clamp(2.4rem, 4.6vw, 4rem);
  line-height: 1.02;
  color: var(--gold);
  letter-spacing: -0.03em;
  margin: 0 0 40px;
  animation: fadeUp 1s var(--ease) 0.3s both;
}
.hero-motto {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 40px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  animation: fadeUp 1s var(--ease) 0.4s both;
}
.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  align-self: flex-start;
  padding: 14px 26px;
  background: var(--navy);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  border-radius: 0;
  transition: background 0.25s var(--ease), transform 0.25s var(--ease);
  animation: fadeUp 1s var(--ease) 0.5s both;
}
.hero-cta::after { content: '→'; font-size: 0.85rem; letter-spacing: 0; transition: transform 0.25s var(--ease); }
.hero-cta:hover { background: var(--gold); color: var(--navy-deep); }
.hero-cta:hover::after { transform: translateX(4px); }

/* ---------- About ---------- */
.section--about { background: var(--bg); }
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  margin-bottom: 96px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}
.about-col p { margin: 0 0 20px; color: var(--ink); }
.about-col p:first-child { color: var(--navy); font-size: 1.05rem; font-weight: 500; line-height: 1.55; }

.values {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line);
  counter-reset: val;
}
.values li {
  padding: 36px 28px;
  border-right: 1px solid var(--line);
  position: relative;
  transition: background 0.25s var(--ease);
}
.values li:last-child { border-right: 0; }
.values li::before {
  counter-increment: val;
  content: counter(val, decimal-leading-zero);
  display: block;
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  color: var(--gold);
  margin-bottom: 24px;
}
.values li:hover { background: var(--bg-alt); }
.values span {
  display: block;
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--navy);
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}
.values p { margin: 0; font-size: 0.92rem; color: var(--muted); line-height: 1.55; }

/* ---------- Contact ---------- */
.section--contact { background: var(--bg-alt); }
.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.contact-card {
  background: var(--bg);
  border: 1px solid var(--line);
  padding: 40px 32px;
  position: relative;
  transition: border-color 0.25s var(--ease), transform 0.25s var(--ease);
}
.contact-card::before {
  content: '';
  position: absolute;
  left: 0; top: 0;
  width: 32px; height: 2px;
  background: var(--gold);
}
.contact-card:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.contact-card h3 {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 16px;
}
.contact-card p { margin: 0; font-size: 1rem; color: var(--navy); font-weight: 500; line-height: 1.85; }
.contact-card a { color: var(--navy); border-bottom: 1px solid transparent; transition: border-color 0.25s var(--ease); }
.contact-card a:hover { border-bottom-color: var(--gold); }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--navy-deep);
  color: rgba(255, 255, 255, 0.6);
  padding: 36px 48px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  border-top: 3px solid var(--gold);
}
.site-footer p { margin: 0; }

/* ---------- Reveal ---------- */
[data-section]:not(.section--hero) .section-inner > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
[data-section].is-visible .section-inner > * { opacity: 1; transform: none; }
[data-section].is-visible .section-inner > *:nth-child(1) { transition-delay: 0.05s; }
[data-section].is-visible .section-inner > *:nth-child(2) { transition-delay: 0.15s; }
[data-section].is-visible .section-inner > *:nth-child(3) { transition-delay: 0.25s; }
[data-section].is-visible .section-inner > *:nth-child(4) { transition-delay: 0.35s; }
[data-section].is-visible .section-inner > *:nth-child(5) { transition-delay: 0.45s; }

@keyframes fadeUp { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

[data-i18n], [data-i18n-attr] { transition: opacity 0.18s var(--ease); }
body.is-lang-switching [data-i18n] { opacity: 0.4; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero-split { grid-template-columns: 1fr; min-height: auto; }
  .hero-panel { padding: 130px 28px 60px; align-items: center; text-align: center; }
  .hero-content { padding: 60px 28px 80px; align-items: center; text-align: center; }
  .hero-eyebrow { justify-content: center; }
  .hero-motto { justify-content: center; }
  .about-grid { grid-template-columns: 1fr; gap: 0; }
  .values { grid-template-columns: repeat(2, 1fr); }
  .values li { border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
  .values li:nth-child(2n) { border-right: 0; }
  .values li:nth-last-child(-n+2) { border-bottom: 0; }
  .contact-grid { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .site-header { padding: 14px 22px; grid-template-columns: auto 1fr auto; }
  .site-header.is-scrolled { padding: 10px 22px; }
  .brand .brand-text { display: none; }
  .site-nav { display: none; }
  .nav-toggle { display: flex; order: 4; }
  .lang-switch { padding-left: 12px; }
  .site-nav.is-open {
    display: block;
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: #fff;
    border-bottom: 1px solid var(--line);
  }
  .site-nav.is-open ul { flex-direction: column; gap: 0; padding: 12px 0; }
  .site-nav.is-open a { display: block; padding: 14px 22px; }
  .section { padding: 130px 22px 80px; }
  .section--hero { padding: 0; }
  .site-footer { flex-direction: column; padding: 28px 22px; text-align: center; }
}
@media (max-width: 480px) {
  .values { grid-template-columns: 1fr; }
  .values li { border-right: 0; border-bottom: 1px solid var(--line); }
  .values li:last-child { border-bottom: 0; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
