/* ── Monika & Matija ─ 22.5.2027. ────────────────────────────────── */
:root {
  --bg:        #FBF8F3;
  --bg-warm:   #F4EEE4;
  --paper:     #FFFDFA;
  --ink:       #35302A;
  --ink-soft:  #6E6459;
  --muted:     #9A8F81;
  --gold:      #A98F5F;
  --gold-soft: #C9B489;
  --line:      #E6DCCB;
  --err:       #A3543F;
  --serif: 'Cormorant Garamond', 'Iowan Old Style', Palatino, Georgia, serif;
  --sans:  'Jost', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

/* ── tipografija ──────────────────────────────────────────────── */
h1, h2, h3 { font-family: var(--serif); font-weight: 400; margin: 0; letter-spacing: .01em; }

.eyebrow {
  font-family: var(--sans);
  font-size: .72rem;
  letter-spacing: .34em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 400;
}

/* ── layout ───────────────────────────────────────────────────── */
.wrap { max-width: 640px; margin: 0 auto; padding: 0 26px; }

section { padding: 68px 0; }

.rule {
  width: 1px; height: 56px; margin: 0 auto;
  background: linear-gradient(to bottom, transparent, var(--gold-soft), transparent);
}

.ornament {
  display: flex; align-items: center; justify-content: center;
  gap: 14px; margin: 0 auto 30px;
}
.ornament::before, .ornament::after {
  content: ''; height: 1px; width: 54px;
  background: linear-gradient(to right, transparent, var(--line), transparent);
}
.ornament span { color: var(--gold); font-size: 1rem; line-height: 1; }

/* ── hero ─────────────────────────────────────────────────────── */
.hero {
  min-height: 100svh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center;
  padding: 60px 26px 46px;
  background:
    radial-gradient(120% 80% at 50% 0%, #FFFFFF 0%, var(--bg) 55%, var(--bg-warm) 100%);
  position: relative;
}

.monogram {
  font-family: var(--serif);
  font-size: clamp(2.9rem, 13vw, 4.6rem);
  color: var(--gold);
  line-height: 1;
  margin-bottom: 26px;
  font-weight: 300;
}
.monogram em { font-style: italic; font-size: .62em; opacity: .8; margin: 0 .12em; }

.hero .eyebrow { margin-bottom: 20px; }

.imena {
  font-size: clamp(2.6rem, 12.5vw, 4.4rem);
  line-height: 1.06;
  margin-bottom: 6px;
}
.imena .amp {
  display: block;
  font-style: italic;
  color: var(--gold);
  font-size: .48em;
  margin: 6px 0;
}

.hero-datum {
  font-family: var(--serif);
  font-size: clamp(1.15rem, 4.6vw, 1.5rem);
  color: var(--ink-soft);
  margin-top: 22px;
  letter-spacing: .04em;
}
.hero-mjesto {
  font-size: .8rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 12px;
}

.scroll-hint {
  position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%);
  color: var(--muted); font-size: .68rem;
  letter-spacing: .24em; text-transform: uppercase;
  display: flex; flex-direction: column; align-items: center; gap: 9px;
  text-decoration: none;
}
.scroll-hint::after {
  content: ''; width: 1px; height: 26px;
  background: linear-gradient(to bottom, var(--gold-soft), transparent);
  animation: drift 2.4s ease-in-out infinite;
}
@keyframes drift { 0%,100% { opacity:.35; transform: translateY(-3px); } 50% { opacity:1; transform: translateY(3px); } }

/* ── odbrojavanje ─────────────────────────────────────────────── */
.odbrojavanje { display: flex; justify-content: center; gap: 8px; margin-top: 34px; }
.odb-jed {
  min-width: 62px; padding: 12px 6px;
  border: 1px solid var(--line); border-radius: 2px;
  background: rgba(255,253,250,.6);
}
.odb-jed b {
  display: block; font-family: var(--serif); font-weight: 400;
  font-size: 1.65rem; line-height: 1; color: var(--ink);
}
.odb-jed span {
  display: block; margin-top: 6px;
  font-size: .58rem; letter-spacing: .16em;
  text-transform: uppercase; color: var(--muted);
}

/* ── pozivni tekst ────────────────────────────────────────────── */
.poziv { text-align: center; }
.poziv p {
  font-family: var(--serif);
  font-size: clamp(1.18rem, 4.6vw, 1.42rem);
  line-height: 1.75;
  color: var(--ink-soft);
  margin: 0 auto;
  max-width: 30ch;
}

/* ── program ──────────────────────────────────────────────────── */
.naslov-sekcije { text-align: center; margin-bottom: 44px; }
.naslov-sekcije h2 { font-size: clamp(1.9rem, 7.5vw, 2.5rem); margin-top: 10px; }

.program { list-style: none; margin: 0; padding: 0; position: relative; }
.program::before {
  content: ''; position: absolute; left: 5px; top: 12px; bottom: 12px; width: 1px;
  background: linear-gradient(to bottom, transparent, var(--line) 12%, var(--line) 88%, transparent);
}
.program li { position: relative; padding: 0 0 40px 34px; }
.program li:last-child { padding-bottom: 0; }
.program li::before {
  content: ''; position: absolute; left: 0; top: 9px;
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--bg); border: 1px solid var(--gold-soft);
}
.program li.istaknuto::before { background: var(--gold); border-color: var(--gold); }

.vrijeme {
  font-family: var(--serif); font-size: 1.5rem;
  color: var(--gold); line-height: 1; display: block; margin-bottom: 7px;
}
.program h3 { font-size: 1.28rem; margin-bottom: 3px; }
.program .adresa { color: var(--ink-soft); font-size: .93rem; margin: 0 0 12px; }

.maps-btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .74rem; letter-spacing: .13em; text-transform: uppercase;
  color: var(--ink); text-decoration: none;
  border: 1px solid var(--line); border-radius: 2px;
  padding: 9px 15px; background: var(--paper);
  transition: border-color .2s, background .2s;
}
.maps-btn:hover, .maps-btn:focus-visible { border-color: var(--gold-soft); background: #fff; }
.maps-btn svg { width: 13px; height: 13px; flex: none; stroke: var(--gold); }

/* ── RSVP ─────────────────────────────────────────────────────── */
.rsvp { background: var(--bg-warm); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

.rok {
  text-align: center; font-size: .93rem; color: var(--ink-soft);
  max-width: 34ch; margin: -26px auto 40px;
}
.rok b { font-weight: 500; color: var(--ink); }

form { display: grid; gap: 22px; }

.polje { display: grid; gap: 8px; }
.polje > label, .grupa > legend {
  font-size: .71rem; letter-spacing: .17em; text-transform: uppercase;
  color: var(--ink-soft); font-weight: 400; padding: 0;
}
.polje small { color: var(--muted); font-size: .78rem; margin-top: -3px; }

input[type=text], input[type=number], textarea, select {
  width: 100%; font-family: var(--sans); font-size: 1rem; font-weight: 300;
  color: var(--ink); background: var(--paper);
  border: 1px solid var(--line); border-radius: 2px;
  padding: 13px 14px;
  transition: border-color .2s, box-shadow .2s;
  -webkit-appearance: none; appearance: none;
}
textarea { min-height: 96px; resize: vertical; line-height: 1.6; }
input:focus, textarea:focus, select:focus {
  outline: none; border-color: var(--gold-soft);
  box-shadow: 0 0 0 3px rgba(169,143,95,.12);
}
input::placeholder, textarea::placeholder { color: #BDB3A5; }

.grupa { border: 0; margin: 0; padding: 0; display: grid; gap: 10px; }

.izbor { display: grid; gap: 10px; }
.izbor label {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 15px 16px; cursor: pointer;
  background: var(--paper); border: 1px solid var(--line); border-radius: 2px;
  transition: border-color .2s, background .2s;
  font-size: .97rem;
}
.izbor label:hover { border-color: var(--gold-soft); }
.izbor input { accent-color: var(--gold); margin: 3px 0 0; flex: none; width: 16px; height: 16px; }
.izbor input:checked ~ span { color: var(--ink); }
.izbor label:has(input:checked) { border-color: var(--gold); background: #fff; }

.uvjetno[hidden] { display: none; }
.uvjetno { display: grid; gap: 22px; }

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

button[type=submit] {
  font-family: var(--sans); font-size: .78rem;
  letter-spacing: .2em; text-transform: uppercase;
  color: #fff; background: var(--ink);
  border: 1px solid var(--ink); border-radius: 2px;
  padding: 17px 24px; cursor: pointer; width: 100%;
  transition: background .2s, opacity .2s;
}
button[type=submit]:hover:not(:disabled) { background: #221E19; }
button[type=submit]:disabled { opacity: .5; cursor: default; }

.greska {
  color: var(--err); font-size: .88rem; text-align: center;
  border: 1px solid rgba(163,84,63,.28); background: rgba(163,84,63,.06);
  padding: 12px 14px; border-radius: 2px; margin: 0;
}
.greska[hidden] { display: none; }

/* ── potvrda ──────────────────────────────────────────────────── */
.potvrda { text-align: center; padding: 22px 0; }
.potvrda[hidden] { display: none; }
.kvacica {
  width: 54px; height: 54px; margin: 0 auto 24px;
  border: 1px solid var(--gold-soft); border-radius: 50%;
  display: grid; place-items: center;
}
.kvacica svg { width: 22px; height: 22px; stroke: var(--gold); }
.potvrda h3 { font-size: 1.9rem; margin-bottom: 12px; }
.potvrda p { color: var(--ink-soft); max-width: 32ch; margin: 0 auto; font-size: .98rem; }

/* ── podnožje ─────────────────────────────────────────────────── */
footer { text-align: center; padding: 56px 26px 64px; }
footer .imena-mala {
  font-family: var(--serif); font-size: 1.5rem; color: var(--ink);
}
footer .imena-mala em { font-style: italic; color: var(--gold); }
footer p { color: var(--muted); font-size: .82rem; margin: 10px 0 0; letter-spacing: .06em; }

/* ── ulazna animacija ─────────────────────────────────────────── */
.pojava { opacity: 0; transform: translateY(14px); transition: opacity .8s ease, transform .8s ease; }
.pojava.vidljivo { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .pojava { opacity: 1; transform: none; transition: none; }
  .scroll-hint::after { animation: none; }
  html { scroll-behavior: auto; }
}

@media (max-width: 380px) {
  .odb-jed { min-width: 54px; padding: 10px 4px; }
  .odb-jed b { font-size: 1.4rem; }
}
