:root {
  --bg-base: #FDFBF7;
  --bg-alt: #F5F1E9;
  --text-primary: #4C2F1C;
  --text-muted: #6A4C38;
  --green-dark: #395125;
  --green-light: #C7E2B0;
  --green-tint: rgba(199, 226, 176, 0.36);
  --green-hover: rgba(199, 226, 176, 0.2);
  --green-border: rgba(57, 81, 37, 0.16);
  --white: #FFFFFF;

  --font-sans: ui-rounded, "SF Pro Rounded", "Hiragino Maru Gothic ProN", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", Arial, sans-serif;
  --ease-out-expo: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background-color: var(--bg-base);
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow-x: hidden;
  font-family: var(--font-sans);
  color: var(--text-primary);
  background-color: var(--bg-base);
  background-image:
    radial-gradient(circle at 18% 14%, rgba(199, 226, 176, 0.22) 0%, rgba(199, 226, 176, 0) 44%),
    radial-gradient(circle at 84% 82%, rgba(245, 241, 233, 0.95) 0%, rgba(245, 241, 233, 0) 54%),
    radial-gradient(circle at 50% 44%, var(--white) 0%, var(--bg-base) 68%);
  padding-top: env(safe-area-inset-top, 0px);
  padding-right: env(safe-area-inset-right, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  padding-left: env(safe-area-inset-left, 0px);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Suptilni organski dekorativni elementi u pozadini */
.bg-decor {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.decor-shape {
  position: absolute;
  display: block;
  user-select: none;
}

.decor-leaf-top {
  top: clamp(-3.5rem, -5vw, -1.5rem);
  right: clamp(-3.5rem, -4vw, -1rem);
  width: clamp(120px, 22vw, 240px);
  height: auto;
  opacity: 0.34;
}

.decor-leaf-bottom {
  bottom: clamp(-3rem, -4vw, -1rem);
  left: clamp(-3.5rem, -4vw, -1rem);
  width: clamp(130px, 24vw, 260px);
  height: auto;
  opacity: 0.3;
}

.decor-arc {
  top: 12%;
  left: max(3%, 1rem);
  width: clamp(110px, 16vw, 210px);
  height: auto;
  opacity: 0.26;
}

/* Minimalistički izbor jezika u gornjem desnom uglu */
.site-header {
  position: relative;
  z-index: 2;
  flex-shrink: 0;
  width: 100%;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding: clamp(0.625rem, 2.2vh, 1.25rem) clamp(0.875rem, 4vw, 2.25rem) 0;
}

.lang-switcher {
  display: inline-flex;
  align-items: center;
  gap: 0.125rem;
}

.lang-link {
  position: relative;
  z-index: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.75rem;
  min-height: 2.75rem;
  padding: 0 0.5rem;
  border-radius: 999px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: clamp(0.75rem, 0.72rem + 0.16vw, 0.84rem);
  font-weight: 500;
  letter-spacing: 0.08em;
  line-height: 1;
  transition: color 180ms ease;
}

.lang-link::before {
  content: "";
  position: absolute;
  inset: 0.45rem 0.125rem;
  z-index: -1;
  border-radius: 999px;
  background-color: transparent;
  border: 1px solid transparent;
  transition: background-color 180ms ease, border-color 180ms ease;
}

.lang-link:hover {
  color: var(--text-primary);
}

.lang-link:hover::before {
  background-color: var(--green-hover);
}

.lang-link:focus-visible {
  outline: 2px solid var(--green-dark);
  outline-offset: -3px;
}

.lang-link[aria-current="page"] {
  color: var(--green-dark);
  font-weight: 700;
}

.lang-link[aria-current="page"]::before {
  background-color: var(--green-tint);
  border-color: var(--green-border);
}

.lang-sep {
  color: rgba(76, 47, 28, 0.3);
  font-size: 0.875rem;
  line-height: 1;
  user-select: none;
}

/* Glavni centralni dio */
.hero {
  position: relative;
  z-index: 1;
  flex: 1 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: clamp(1rem, 3.5vh, 2.5rem) clamp(1.25rem, 5vw, 3rem) clamp(1.25rem, 3.5vh, 2.5rem);
}

.hero-content {
  width: 100%;
  max-width: 44rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.logo-wrap {
  width: 100%;
  display: flex;
  justify-content: center;
  margin-bottom: clamp(1.375rem, 4vh, 2.5rem);
}

.brand-logo {
  display: block;
  width: 85%;
  max-width: 340px;
  height: auto;
}

.badge {
  margin: 0 0 clamp(0.875rem, 2.2vh, 1.25rem);
  padding: 0.4375rem 1.0625rem;
  border-radius: 999px;
  background-color: var(--green-tint);
  border: 1px solid var(--green-border);
  color: var(--green-dark);
  font-size: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  font-weight: 700;
  letter-spacing: 0.18em;
  line-height: 1.2;
  text-indent: 0.18em;
}

.headline {
  margin: 0 0 clamp(0.625rem, 1.8vh, 1rem);
  max-width: 26ch;
  color: var(--text-primary);
  font-size: clamp(1.5rem, 1.15rem + 1.65vw, 2.625rem);
  font-weight: 700;
  line-height: 1.22;
  letter-spacing: -0.015em;
  text-wrap: balance;
}

.subtitle {
  margin: 0;
  max-width: 40ch;
  color: var(--text-muted);
  font-size: clamp(1rem, 0.92rem + 0.45vw, 1.28rem);
  font-weight: 500;
  line-height: 1.55;
  letter-spacing: 0.005em;
  text-wrap: pretty;
}

/* Diskretan footer */
.site-footer {
  position: relative;
  z-index: 1;
  flex-shrink: 0;
  width: 100%;
  padding: clamp(0.75rem, 2vh, 1.25rem) clamp(1.25rem, 5vw, 2rem) clamp(1.125rem, 3vh, 1.75rem);
  text-align: center;
}

.copyright {
  margin: 0;
  color: var(--text-muted);
  font-size: clamp(0.78rem, 0.74rem + 0.16vw, 0.875rem);
  font-weight: 400;
  line-height: 1.5;
}

/* Kratka, suptilna ulazna animacija bez odlaganja prvog prikaza */
@keyframes gentleFadeUp {
  from {
    opacity: 0.01;
    transform: translate3d(0, 10px, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

.reveal {
  animation: gentleFadeUp 680ms var(--ease-out-expo) both;
}

.reveal-logo {
  animation-duration: 620ms;
}

.reveal-badge {
  animation-delay: 60ms;
}

.reveal-title {
  animation-delay: 110ms;
}

.reveal-subtitle {
  animation-delay: 160ms;
}

.reveal-footer {
  animation-delay: 200ms;
}

/* Prilagodba veličine logotipa po uređajima */
@media (min-width: 640px) {
  .brand-logo {
    width: clamp(350px, 50vw, 420px);
    max-width: 100%;
  }
}

@media (min-width: 1024px) {
  .brand-logo {
    width: clamp(420px, 34vw, 480px);
  }

  .decor-arc {
    top: 14%;
    left: 6%;
  }
}

@media (min-width: 1600px) {
  .brand-logo {
    width: clamp(480px, 26vw, 520px);
  }
}

/* Mobilni uređaji i ekrani male visine u horizontalnoj orijentaciji */
@media (max-height: 540px) and (orientation: landscape) {
  .site-header {
    padding-top: 0.375rem;
  }

  .hero {
    padding-top: 0.5rem;
    padding-bottom: 0.75rem;
  }

  .logo-wrap {
    margin-bottom: 0.875rem;
  }

  .brand-logo {
    width: clamp(180px, 44svh, 320px);
    max-width: 85%;
  }

  .badge {
    margin-bottom: 0.5rem;
  }

  .headline {
    font-size: clamp(1.35rem, 1rem + 1.2vw, 1.85rem);
    margin-bottom: 0.375rem;
  }

  .decor-arc {
    display: none;
  }
}

/* Poštovanje korisničkih postavki za smanjeno kretanje */
@media (prefers-reduced-motion: reduce) {
  .reveal {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }

  .lang-link,
  .lang-link::before {
    transition: none;
  }
}
