/* Component styles for the front-page sections. Adheres to the editorial reference at
   c:/xampp/htdocs/tsd/data/index.html — every section has the same primitives:
   .eyebrow (small uppercase label), .container, optional grid layout, plain typography
   with italic <em> as the accent. */

/* ===== Section backgrounds =====
   The three brand-saturated sections (.section-forest, .section-gold, .section-teal)
   all share a wavy mask on their top + bottom edges so cream-to-colour transitions are
   never a flat horizontal line. The mask SVG is at ../svg/section-wave.svg; it's
   stretched with preserveAspectRatio="none" so the same shape works at any section
   height. Extra padding-top/bottom of ~5rem compensates for the deepest wave dip,
   keeping content safely inside the painted area regardless of section height.

   Cream-on-cream boundaries (e.g. cream-deep → cream, kontakt → instagram) stay flat
   because the contrast difference there is barely visible; adding waves to those would
   be visual noise without an actual transition to ease. */
/* Slanted mask applies to .section-teal only. .section-forest (Radionice) was
   originally in this group but the slants felt off against the dark green block +
   dense card grid; .section-gold (Lokacije) was later flattened too because the
   slant clashed with the warm yellow surface — flat edges read cleaner. */
.section-teal {
  padding-top: calc(var(--r-section) + 5rem);
  padding-bottom: calc(var(--r-section) + 5rem);
  -webkit-mask: url('../svg/section-wave.svg') center / 100% 100% no-repeat;
          mask: url('../svg/section-wave.svg') center / 100% 100% no-repeat;
}

/* Browsers without CSS mask support fall back to flat edges + the original padding. */
@supports not ((mask: url('a.svg')) or (-webkit-mask: url('a.svg'))) {
  .section-teal {
    padding-top: var(--r-section);
    padding-bottom: var(--r-section);
  }
}

.section-cream-deep {
  background: var(--color-cream);
}

.section-forest {
  background: var(--color-forest);
  color: var(--color-bg);
}

.section-forest h2,
.section-forest h3,
.section-forest h4 {
  color: var(--color-bg);
}

.section-forest .eyebrow,
.section-forest em,
.section-forest h1 em,
.section-forest h2 em,
.section-forest h3 em {
  color: var(--color-leaf);
}

.section-forest p {
  color: #d5cfc0;
}

/* Saturated brand-gold section (currently #lokacije). Gold is the brand's third
   primary; using it as a section background means ALL text inside must flip to
   AA-safe darks because brand-green / brand-teal / white all fail contrast on this
   yellow (under 2.5:1). Permitted text colours on this surface:
   - --color-ink (#3a332b) → 5.94:1, AA ✓ (headings, body, eyebrow)
   - --brand-green-darkest (#103a22) → 6.08:1, AA ✓ (heading em accent) */
.section-gold {
  background: var(--brand-gold);
  color: var(--color-ink);
  position: relative;
  overflow: hidden;
}

.section-gold .eyebrow,
.section-gold h1,
.section-gold h2,
.section-gold h3,
.section-gold h4,
.section-gold p {
  color: var(--color-ink);
}

/* Heading em on the gold section: white at the user's request. This
   intentionally breaks the AA contrast guidance documented above — white on
   brand-gold is 1.97:1 (below AA-Large 3:1). A small dark-green text-shadow
   gives the white some edge definition against the warm yellow so it stays
   legible at the heading sizes where this em is used. */
.section-gold em,
.section-gold h1 em,
.section-gold h2 em,
.section-gold h3 em,
.section-gold h4 em {
  color: #fff;
  text-shadow: 0 1px 2px rgba(16, 58, 34, 0.4);
}

/* Decorative leaf cluster anchored to the right of the gold section. Sits
   absolutely so it doesn't push the .container content; the section's
   overflow:hidden clips it where it extends past the right edge. The .container
   gets z-index so text always stays above the leaves. Rendered at full opacity
   so the green/teal SVG fills read as a strong graphic element on the gold
   field — the leaves are now a feature, not a tonal whisper.
   Layout strategy at each breakpoint:
     ≥1025px  large, vertically centered, partial bleed off right
     720–1024 smaller, still vertically centered, more bleed
     480–719  shrinks and moves to the bottom-right corner so it peeks under
              the lead paragraph instead of overlapping it
     <480px   hidden — the narrow column has no room for a decorative bleed
              at full opacity without colliding with text */
.section-gold-leaves {
  position: absolute;
  right: -4rem;
  top: 50%;
  transform: translateY(-50%) rotate(8deg);
  width: 28rem;
  max-width: 55%;
  opacity: 1;
  pointer-events: none;
  z-index: 1;
}

.section-gold-leaves svg {
  display: block;
  width: 100%;
  height: auto;
}

.section-gold .container {
  position: relative;
  z-index: 2;
}

@media (max-width: 1024px) {
  .section-gold-leaves {
    width: 22rem;
    max-width: 48%;
    right: -5rem;
  }
}

@media (max-width: 720px) {
  .section-gold-leaves {
    width: 18rem;
    max-width: 65%;
    right: -6rem;
    top: auto;
    bottom: -2.5rem;
    transform: rotate(18deg);
    /* On phones the leaves stay visible but drop to 0.25 opacity so they
       read as a watermark behind the lead paragraph instead of competing
       with the text at full saturation. */
    opacity: 0.25;
  }
}

/* Saturated brand-teal section (currently #suradnje). Teal is the brand's second
   primary; on this mid-tone background only white text clears AA-Normal (5.20:1).
   Permitted text colours:
   - #fff (white) → 5.20:1, AA ✓ (headings, body, links, eyebrow)
   - --color-bg (cream) → 4.46:1, AA-Large ✓ for headings + heading em (weight 800)
     and for the large .suradnje-mail-link (~24px). Don't use on small body text. */
.section-teal {
  background: var(--brand-teal);
  color: #fff;
}

.section-teal .eyebrow,
.section-teal h1,
.section-teal h2,
.section-teal h3,
.section-teal h4,
.section-teal p {
  color: #fff;
}

.section-teal em,
.section-teal h1 em,
.section-teal h2 em,
.section-teal h3 em,
.section-teal h4 em {
  color: var(--color-bg);
}

.section-teal .suradnje-mail-label {
  color: var(--color-bg);
}

.section-teal .suradnje-mail-link {
  color: #fff;
  border-bottom-color: #fff;
}

.section-teal .suradnje-mail-link:hover,
.section-teal .suradnje-mail-link:focus-visible {
  opacity: 0.85;
}

/* ===== Parallax photo section =====
   Full-width forest photo (darkomares.com) sitting between Ana Zubak and Radionice.
   Parallax via `background-attachment: fixed` — the cleanest cross-browser approach
   that needs no JavaScript. The bg stays anchored to the viewport while the page
   scrolls past, so the photo appears to drift relative to the surrounding content.

   `min-height: 70vh` gives enough scroll distance for the parallax to feel like
   parallax (not just a static photo). `background-size: cover` + `center center`
   keeps the most important part of the photo visible regardless of viewport.

   Mobile fallback: iOS Safari silently ignores `fixed` (treats as scroll) AND Android
   Chrome stutters under fixed-attachment scrolling. Drop to `scroll` under 900px to
   match what those browsers will do anyway and avoid jank. */
/* Editorial photo interlude — full-bleed forest photo with parallax + a centred
   magazine-spread quote overlay. The whole composition reads "modern editorial nature
   magazine + handmade picture-book" by combining:
     - Warm brand-coloured gradient veil over the photo (earth tones, not flat dark)
     - Big confident serif quote with brand-teal accent (modern editorial scale)
     - Two hand-rotated decorative SVGs at opposite corners (handmade asymmetry)
     - A short horizontal rule below the quote (graphic punctuation, urban) */
.photo-parallax {
  position: relative;
  min-height: 85vh;
  background-size: cover;
  background-position: center center;
  background-attachment: fixed;
  background-repeat: no-repeat;
  background-color: var(--color-forest);
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  isolation: isolate; /* contain the veil's stacking context */
}

/* Veil: layered gradient that introduces brand-green + brand-gold warmth without
   washing out the photo. Top and bottom darken for legibility; middle stays mostly
   transparent so the photo speaks through where the eye actually lands. */
.photo-parallax-veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg,
      rgba(16, 58, 34, 0.65) 0%,
      rgba(16, 58, 34, 0.20) 35%,
      rgba(229, 169, 35, 0.10) 65%,
      rgba(16, 58, 34, 0.70) 100%),
    radial-gradient(ellipse at center, transparent 30%, rgba(58, 51, 43, 0.35) 100%);
  pointer-events: none;
  z-index: 1;
}

/* Editorial quote overlay */
.photo-parallax-content {
  position: relative;
  z-index: 3;
  text-align: center;
  padding: 0 2rem;
  max-width: 880px;
  color: #fff;
}

.photo-parallax-content .eyebrow {
  /* Override default moss colour — needs to read on the photo */
  color: var(--brand-gold);
  margin-bottom: 1.5rem;
  display: inline-block;
}

.photo-parallax-quote {
  font-family: var(--font-heading);
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -0.015em;
  color: #fff;
  text-shadow: 0 2px 16px rgba(16, 58, 34, 0.55);
  margin: 0;
  max-width: none;
}

.photo-parallax-quote em {
  /* Use a light brand-tinted cream instead of teal here so it reads on the photo */
  color: var(--brand-gold);
  font-style: normal;
  font-weight: 600;
}

/* Short graphic rule below the quote — gold dash that anchors the composition. */
.photo-parallax-rule {
  width: 3rem;
  height: 2px;
  background: var(--brand-gold);
  margin: 2rem auto 0;
}

@media (max-width: 900px) {
  .photo-parallax {
    background-attachment: scroll;
    min-height: 60vh;
  }
}

@media (prefers-reduced-motion: reduce) {
  .photo-parallax {
    background-attachment: scroll;
  }
}

/* ===== Layout primitives ===== */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: start;
}

.narrow {
  max-width: 720px;
}

.narrow-copy {
  max-width: 60ch;
}

/* ===== Ana Zubak ===== */
.ana-grid {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 4rem;
  align-items: start;
}

.ana-photo {
  aspect-ratio: 4 / 5;
  background: var(--color-mushroom);
  border-radius: var(--rad);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-stone);
  font-family: var(--font-body);
  font-size: 0.8rem;
  letter-spacing: 0.08em;
}

.ana-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ana-photo-placeholder {
  padding: 1rem;
  text-align: center;
}

.ana-meta .name {
  font-family: var(--font-heading);
  font-size: 2rem;
  color: var(--color-ink);
  margin-bottom: 0.5rem;
  font-weight: 500;
  line-height: 1.1;
}

.ana-meta .role-line {
  width: 32px;
  height: 2px;
  background: var(--color-rust);
  margin: 1.5rem 0;
}

/* ===== Awards grid =====
   The two recognitions deserve more weight than a plain text list — they're the
   single strongest credibility signal on the page. Card surface is plain white
   so the gold accent (the small year period + meta separator) gives the card
   its only warm note. White cards stand cleanly off the .section-cream-deep
   parent (--color-cream #e8e1d2). All interior text uses the standard brand
   palette which clears AA on white. */
.awards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-top: 2.5rem;
  max-width: 620px;
}

.award {
  position: relative;
  background: #fff;
  padding: 1.75rem 1.75rem 1.5rem;
  border-radius: var(--rad);
  border: 1px solid rgba(58, 51, 43, 0.08);
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition);
}

.award:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 32px rgba(58, 51, 43, 0.12);
}

.award-tag {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--brand-green-deep);
  margin-bottom: 0.7rem;
}

.award .year {
  font-family: var(--font-heading);
  font-size: 2rem;
  /* On white, brand-green (#277f4b) = 5.70:1 — AA ✓ across all sizes. */
  color: var(--brand-green);
  font-weight: 700;
  margin-bottom: 0.5rem;
  line-height: 1;
}

.award .label {
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--color-bark);
  line-height: 1.45;
  margin-bottom: 0.85rem;
}

.award-meta {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--color-stone);
  padding-top: 0.7rem;
  border-top: 1px solid rgba(58, 51, 43, 0.12);
  font-style: italic;
  opacity: 0.9;
}

/* ===== Radionice cards (inside .section-forest) ===== */
.cards-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-top: 3rem;
}

.card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(245, 240, 230, 0.18);
  padding: 2.5rem;
  border-radius: var(--rad);
  transition: transform var(--transition), background-color var(--transition), border-color var(--transition);
}

.card:hover {
  transform: translateY(-3px);
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(245, 240, 230, 0.28);
}

.card h3 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: var(--color-bg);
  margin-bottom: 1rem;
}

/* Shared contact line below the two radionice cards. Was previously rendered
   per-card as .mail-line with the same email duplicated; consolidated here to
   avoid repetition. Sits as a single centered block under the grid, inside the
   dark forest section, so the cards stay equal-height and the email reads as
   "for both" rather than "again, please". */
.cards-contact {
  margin-top: 2.5rem;
  padding: 1.5rem 2rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(245, 240, 230, 0.18);
  border-radius: var(--rad);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
}

.cards-contact-label {
  font-family: var(--font-body);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-leaf);
  text-align: center;
}

.cards-contact-mail {
  font-family: var(--font-heading);
  font-size: clamp(1.15rem, 2vw, 1.5rem);
  color: var(--color-bg);
  text-decoration: none;
  padding-bottom: 0.15rem;
  border-bottom: 2px solid var(--brand-gold);
  transition: border-color var(--transition), opacity var(--transition);
}

.cards-contact-mail:hover,
.cards-contact-mail:focus-visible {
  opacity: 0.92;
  border-bottom-color: var(--color-leaf);
  outline: none;
}

/* ===== Birthday ===== */
.birthday {
  background: var(--color-bg);
}

.birthday-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 5rem;
  margin-top: 3rem;
}

/* Section-heading style for "Program uključuje" — promote it from a quiet text
   label to a small eyebrow + heading combo so it reads as the start of a list,
   not a stray paragraph. */
.program-heading {
  font-family: var(--font-heading);
  color: var(--color-ink);
  margin-bottom: 1.25rem;
  font-weight: 700;
  font-size: 1.2rem;
  position: relative;
  padding-bottom: 0.6rem;
}

.program-heading::after {
  /* Small gold accent rule under the heading — matches the .role-line treatment
     under Ana's name and the .big-mail underline. Brand-gold = decorative only. */
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 2.5rem;
  height: 2px;
  background: var(--brand-gold);
  border-radius: 2px;
}

.birthday-list {
  list-style: none;
  margin: 1.5rem 0;
  padding: 0;
}

.birthday-list li {
  position: relative;
  padding: 0.95rem 0 0.95rem 2.5rem;
  border-bottom: 1px solid rgba(90, 79, 68, 0.1);
  font-family: var(--font-body);
  color: var(--color-bark);
  font-size: 1.0625rem;
  line-height: 1.5;
  transition: padding-left 0.25s ease;
}

.birthday-list li:last-child {
  border-bottom: none;
}

/* Leaf-shaped bullet: each row uses a different leaf shape extracted from
   leafs.svg (leaf-1.svg through leaf-6.svg, one path per file). All bullets
   are masked into a square cell and tinted via background-color so a single
   colour change propagates. Per-row rotation adds organic variety on top of
   the per-row shape variety — together they make the list feel hand-set, not
   stamped. `mask` and `-webkit-mask` are both required for Safari. */
.birthday-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1.15rem;
  width: 1.45rem;
  height: 1.45rem;
  background-color: var(--brand-green);
  -webkit-mask-repeat: no-repeat;
          mask-repeat: no-repeat;
  -webkit-mask-position: center;
          mask-position: center;
  -webkit-mask-size: contain;
          mask-size: contain;
  transition: transform 0.3s cubic-bezier(0.2, 0.7, 0.1, 1), background-color 0.25s ease;
  transform-origin: center;
}

.birthday-list li:nth-child(1)::before {
  -webkit-mask-image: url('../svg/leaf-1.svg');
          mask-image: url('../svg/leaf-1.svg');
  transform: rotate(-12deg);
}
.birthday-list li:nth-child(2)::before {
  -webkit-mask-image: url('../svg/leaf-2.svg');
          mask-image: url('../svg/leaf-2.svg');
  transform: rotate(8deg);
}
.birthday-list li:nth-child(3)::before {
  -webkit-mask-image: url('../svg/leaf-3.svg');
          mask-image: url('../svg/leaf-3.svg');
  transform: rotate(-6deg);
}
.birthday-list li:nth-child(4)::before {
  -webkit-mask-image: url('../svg/leaf-4.svg');
          mask-image: url('../svg/leaf-4.svg');
  transform: rotate(14deg);
}
.birthday-list li:nth-child(5)::before {
  -webkit-mask-image: url('../svg/leaf-5.svg');
          mask-image: url('../svg/leaf-5.svg');
  transform: rotate(-9deg);
}
.birthday-list li:nth-child(6)::before {
  -webkit-mask-image: url('../svg/leaf-6.svg');
          mask-image: url('../svg/leaf-6.svg');
  transform: rotate(5deg);
}

/* Subtle interaction: hovering a row tips the leaf forward + nudges the text
   right so the row feels alive. No-op for keyboard focus since these aren't
   interactive elements. */
.birthday-list li:hover::before {
  background-color: var(--brand-green-deep);
  transform: rotate(0deg) scale(1.15);
}

.birthday-list li:hover {
  padding-left: 2.6rem;
}

.pullquote {
  font-family: var(--font-heading);
  font-style: italic;
  /* Bumped from 1.375rem (22px) to clamp 22 → 30px so the pullquote actually
     reads as a pullquote — at the old size it sat too close to body weight
     and got lost between the surrounding lists. */
  font-size: clamp(1.375rem, 2.4vw, 1.875rem);
  color: var(--color-forest);
  line-height: 1.35;
  padding: 2.5rem 0;
  border-top: 1px solid rgba(90, 79, 68, 0.15);
  border-bottom: 1px solid rgba(90, 79, 68, 0.15);
  margin: 3rem 0;
  max-width: 100%;
}

.info-block {
  background: var(--color-cream);
  border-radius: var(--rad);
  padding: 2rem 2.25rem;
  margin: 3rem 0;
}

.info-block h4 {
  font-family: var(--font-heading);
  font-size: 1.125rem;
  color: var(--color-ink);
  margin-bottom: 1rem;
  font-weight: 500;
}

.info-block ul {
  list-style: none;
  padding: 0;
}

.info-block ul li {
  position: relative;
  padding: 0.55rem 0 0.55rem 1.9rem;
  font-size: 0.98rem;
  color: var(--color-bark);
  line-height: 1.5;
}

/* Same leaf-bullet pattern as .birthday-list, scaled down for the tighter
   info-block rhythm. Six nth-child variants reuse the same leaf-{1..6}.svg
   sprite files so the two lists feel like one family — both lists are
   "program facts" and reading them with consistent ornamentation helps the
   eye chain them together. */
.info-block ul li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.7rem;
  width: 1.1rem;
  height: 1.1rem;
  background-color: var(--brand-green);
  -webkit-mask-repeat: no-repeat;
          mask-repeat: no-repeat;
  -webkit-mask-position: center;
          mask-position: center;
  -webkit-mask-size: contain;
          mask-size: contain;
  transform-origin: center;
}

.info-block ul li:nth-child(1)::before {
  -webkit-mask-image: url('../svg/leaf-1.svg');
          mask-image: url('../svg/leaf-1.svg');
  transform: rotate(-10deg);
}
.info-block ul li:nth-child(2)::before {
  -webkit-mask-image: url('../svg/leaf-2.svg');
          mask-image: url('../svg/leaf-2.svg');
  transform: rotate(7deg);
}
.info-block ul li:nth-child(3)::before {
  -webkit-mask-image: url('../svg/leaf-3.svg');
          mask-image: url('../svg/leaf-3.svg');
  transform: rotate(-5deg);
}
.info-block ul li:nth-child(4)::before {
  -webkit-mask-image: url('../svg/leaf-4.svg');
          mask-image: url('../svg/leaf-4.svg');
  transform: rotate(12deg);
}
.info-block ul li:nth-child(5)::before {
  -webkit-mask-image: url('../svg/leaf-5.svg');
          mask-image: url('../svg/leaf-5.svg');
  transform: rotate(-8deg);
}
.info-block ul li:nth-child(6)::before {
  -webkit-mask-image: url('../svg/leaf-6.svg');
          mask-image: url('../svg/leaf-6.svg');
  transform: rotate(4deg);
}

.birthday-cta {
  margin-top: 2.5rem;
}

/* ===== Tijelo kao dio prirode — feature block =====
   Sits flat on the page (no panel background) since the user wanted the
   section to read as plain editorial copy, not a card. The h2 inside is
   intentionally left to inherit the global heading scale so it matches
   every other section h2. */
.feature-block {
  margin-top: 2rem;
}

.feature-block .small-label {
  font-family: var(--font-body);
  font-size: 0.75rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-rust);
  margin-bottom: 1rem;
}

.feature-block h2 {
  margin-bottom: 1.5rem;
}

.feature-actions {
  display: flex;
  gap: 2rem;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 2rem;
}

/* ===== Suradnje typography accents ===== */
.suradnje-mail-block {
  margin-top: 2rem;
  max-width: none;
}

.suradnje-mail-label {
  font-family: var(--font-body);
  font-size: 0.875rem;
  color: var(--color-stone);
  letter-spacing: 0.05em;
}

.suradnje-mail-link {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: var(--color-moss);
  border-bottom: 1px solid var(--color-moss);
  padding-bottom: 2px;
  transition: opacity var(--transition);
}

.suradnje-mail-link:hover {
  opacity: 0.85;
}

/* ===== Kontakt ===== */
.contact {
  text-align: center;
  padding: 8rem 0;
}

.contact .eyebrow {
  display: inline-block;
}

.contact-lead {
  max-width: 50ch;
  margin: 0 auto 1rem;
}

.big-mail {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: clamp(1.75rem, 4.5vw, 2.75rem);
  /* Heading-green like every other h2/h3 so the mailto reads as a heading element. */
  color: var(--brand-green);
  /* Gold underline — the only spot brand-gold reaches text. Decorative line, contrast
     irrelevant; the warmth softens the otherwise green/cream/bark composition. */
  border-bottom: 2px solid var(--brand-gold);
  padding-bottom: 0.3rem;
  margin: 1.5rem 0;
  transition: color var(--transition), border-color var(--transition);
}

.big-mail:hover,
.big-mail:focus-visible {
  color: var(--brand-green-deep);
  border-color: var(--brand-green-deep);
  outline: none;
}

/* ===== Gallery section — pulls latest media-library images via tsd_gallery_images() =====
   Asymmetric masonry: three columns desktop, two on tablet, one on phone. Items reveal
   in a slight stagger as the section enters the viewport (.reveal sequencing in theme.js
   adds .is-visible to each .gallery-item with a 60ms delay). Hover gently scales + lifts. */
.gallery-section {
  background: var(--color-bg);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: 18rem;
  gap: 1rem;
  margin-top: 3rem;
}

.gallery-item {
  position: relative;
  margin: 0;
  overflow: hidden;
  border-radius: var(--rad-sm);
  background: var(--color-mushroom);
  opacity: 0;
  transform: translateY(14px) scale(0.985);
  transition: opacity 0.55s ease-out, transform 0.55s ease-out, box-shadow 0.4s ease;
}

.gallery-item.is-visible {
  opacity: 1;
  transform: none;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 700ms cubic-bezier(0.2, 0.7, 0.1, 1), filter 400ms ease;
  /* Earth-tone cohesion: subtle sepia + warm desaturation pulls all gallery photos
     toward the cream/green/gold palette, so a stray cool-toned shot doesn't break
     the brand mood. Hover restores full colour for a "wake up" effect. */
  filter: sepia(0.12) saturate(0.88) brightness(1.02);
}

.gallery-item:hover img,
.gallery-item:focus-within img {
  transform: scale(1.06);
  filter: sepia(0) saturate(1.05) brightness(1.02);
}

.gallery-item:hover {
  /* brand-green tint instead of neutral grey — keeps the hover state on-brand. */
  box-shadow: 0 18px 40px rgba(39, 127, 75, 0.22);
}

/* Hand-tuned asymmetry: every 5th and 7th item span two rows so the grid breathes
   instead of looking like a stamped sheet of tiles. */
.gallery-item:nth-child(5n + 3) {
  grid-row: span 2;
}

.gallery-credit {
  margin-top: 2.5rem;
  font-family: var(--font-body);
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  color: var(--color-stone);
  text-align: right;
}

.gallery-credit a {
  color: var(--color-moss);
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition);
}

.gallery-credit a:hover,
.gallery-credit a:focus-visible {
  border-bottom-color: var(--color-moss);
  outline: none;
}

@media (max-width: 900px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 14rem;
  }
  .gallery-item:nth-child(5n + 3) {
    grid-row: auto;
  }
}

@media (max-width: 560px) {
  .gallery-grid {
    /* 2 columns down to the smallest phones — at 1fr the tiles got too tall
       (16rem on a 360px screen reads as a big editorial photo column that
       crowds out the rest of the page). 2 columns at 12rem keeps the grid
       compact and lets users scan more photos at a glance. */
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 12rem;
    gap: 0.6rem;
  }
}

/* ===== Reveal — staggered children =====
   The .reveal class fades the entire section in; .reveal.is-visible cascades a delay
   onto direct child rows so cards/grid items animate in sequence instead of as a block. */
.reveal > .container > * {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.reveal.is-visible > .container > * {
  opacity: 1;
  transform: none;
}

.reveal.is-visible > .container > *:nth-child(1) { transition-delay: 0ms; }
.reveal.is-visible > .container > *:nth-child(2) { transition-delay: 100ms; }
.reveal.is-visible > .container > *:nth-child(3) { transition-delay: 200ms; }
.reveal.is-visible > .container > *:nth-child(4) { transition-delay: 300ms; }
.reveal.is-visible > .container > *:nth-child(5) { transition-delay: 400ms; }

/* The hero's two-column layout shouldn't stagger its halves — they should arrive together. */
.hero.reveal > .container > * {
  transition-delay: 0ms !important;
}

@media (prefers-reduced-motion: reduce) {
  .reveal > .container > *,
  .gallery-item {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .teaser-card,
  .teaser-card:hover,
  .teaser-card:focus-visible,
  .teaser-arrow,
  .faq-item > summary,
  .faq-item > summary::after,
  .award,
  .award:hover,
  .award-icon,
  .birthday-list li,
  .birthday-list li::before,
  .birthday-list li:hover::before {
    transform: none !important;
    transition: none !important;
  }
}

/* ===== Instagram section (theme add-on, not in reference but kept by user request) ===== */
.instagram-section {
  background: var(--color-cream);
  text-align: center;
}

.instagram-section .eyebrow {
  display: inline-block;
}

.instagram-section h2 {
  margin-bottom: 2.5rem;
}

.instagram-feed-wrap {
  max-width: var(--container);
  margin: 0 auto 2.5rem;
}

.instagram-feed-wrap .sbi_item {
  border-radius: var(--rad-sm);
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition);
}

.instagram-feed-wrap .sbi_item:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(74, 86, 65, 0.18);
}

/* Hide the plugin's own follow button + header — our themed CTA below covers it. */
.instagram-feed-wrap #sbi_load,
.instagram-feed-wrap #sb_instagram .sb_instagram_header {
  display: none !important;
}

.instagram-cta-wrap {
  margin-top: 2rem;
}

/* ===== Pravilnik page (single column legal copy) =====
   Layout-wise this page lives on its own (it's the only non-front-page that
   matters), so it gets a dedicated .pravilnik-page wrapper rather than
   reusing the front page's .container. Width matches the editorial reading
   measure (~720px); top padding clears the sticky transparent header. */
.pravilnik-page {
  max-width: 720px;
  margin: 0 auto;
  padding: 8rem 1.5rem 6rem;
}

/* Tight "back to home" link sitting above the title block — visually weight
   it like a breadcrumb, not a CTA, so the eye flows down to the h1. */
.pravilnik-back {
  margin: 0 0 2rem;
}
.pravilnik-back a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-body);
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-stone);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
}
.pravilnik-back a:hover,
.pravilnik-back a:focus-visible {
  color: var(--brand-green-deep);
  border-bottom-color: var(--brand-green-deep);
}

.pravilnik-header {
  margin-bottom: 3.5rem;
}

.pravilnik-header .eyebrow {
  margin-bottom: 1rem;
}

/* Slightly tighter than the front-page h1 because this is a legal document,
   not a landing hero — still uses the brand heading scale but anchored down. */
.pravilnik-header h1 {
  font-size: clamp(2.2rem, 4.5vw, 3.25rem);
  line-height: 1.15;
  margin: 0 0 1.5rem;
}

/* Secondary action right below the h1: download link reads as a small
   pill-styled ghost button so it's discoverable but doesn't compete with
   the eyebrow + heading group above it. */
.pravilnik-pdf {
  margin: 0;
}
.pravilnik-pdf a {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--brand-green-deep);
  text-decoration: none;
  padding: 0.55rem 1.1rem;
  border: 1px solid var(--brand-green-deep);
  border-radius: 999px;
  transition: background 200ms ease, color 200ms ease;
}
.pravilnik-pdf a::before {
  content: "\2193  "; /* U+2193 DOWNWARDS ARROW + two spaces */
}
.pravilnik-pdf a:hover,
.pravilnik-pdf a:focus-visible {
  background: var(--brand-green-deep);
  color: #fff;
}

.policy-body {
  line-height: 1.8;
}

.policy-body h2 {
  margin-top: 3.25rem;
  margin-bottom: 1rem;
  font-size: clamp(1.4rem, 2.4vw, 1.75rem);
  color: var(--color-ink);
  line-height: 1.25;
}

.policy-body h2:first-child {
  margin-top: 0;
}

.policy-body p,
.policy-body li {
  color: var(--color-bark);
  font-size: 1.0625rem;
  max-width: none;
}

.policy-body p {
  margin: 0 0 1.1rem;
}

.policy-body p + p {
  margin-top: 1.1rem;
}

.policy-body p strong {
  color: var(--color-ink);
}

.policy-body ul {
  margin: 1rem 0 1.75rem 1.4rem;
  padding: 0;
}

.policy-body ul li {
  margin-bottom: 0.5rem;
}

@media (max-width: 700px) {
  .pravilnik-page {
    padding: 6rem 1.25rem 4rem;
  }
  .pravilnik-header {
    margin-bottom: 2.5rem;
  }
  .policy-body h2 {
    margin-top: 2.5rem;
  }
}

.page-content {
  max-width: 720px;
  margin: 0 auto;
}

.page-content h1 {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4vw, 2.75rem);
  margin-bottom: 1.5rem;
  color: var(--color-ink);
}

/* ===== Footer ===== */
.site-footer {
  background: var(--color-cream);
  padding: 3rem 0 2.5rem;
  font-family: var(--font-body);
  font-size: 0.875rem;
  color: var(--color-stone);
  margin-top: 0;
}

.footer-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 2rem;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 2rem;
  align-items: center;
}

.footer-inner > div:last-child {
  text-align: right;
}

.site-footer a {
  color: var(--color-bark);
  border-bottom: 1px solid transparent;
  text-decoration: none;
  transition: border-color var(--transition);
}

.site-footer a:hover,
.site-footer a:focus-visible {
  border-bottom-color: var(--color-bark);
  outline: none;
}

/* ===== Responsive collapses ===== */
@media (max-width: 900px) {
  .two-col,
  .ana-grid,
  .birthday-grid,
  .cards-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .awards {
    grid-template-columns: 1fr;
  }

  .ana-photo {
    max-width: 280px;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1rem;
  }

  .footer-inner > div:last-child {
    text-align: center;
  }
}

/* ===== Skip-to-content link =====
   WCAG 2.4.1 Bypass Blocks: first tab inside <body> jumps past the header straight
   to #site-content. Visually hidden until focused, then becomes a prominent pill in
   the top-left so keyboard users see it. Sits above everything (z-index higher than
   the sticky header). */
.skip-link {
  position: absolute;
  top: 0;
  left: 0;
  transform: translateY(-150%);
  z-index: 1000;
  padding: 0.75rem 1.25rem;
  background: var(--brand-green);
  color: #fff;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border-radius: 0 0 8px 0;
  transition: transform 0.15s ease;
}
.skip-link:focus,
.skip-link:focus-visible {
  transform: translateY(0);
  outline: 3px solid var(--brand-gold);
  outline-offset: -3px;
  color: #fff;
}

/* ===== Stats strip ("Sezona u brojkama") =====
   Thin editorial band of 4 figures. Lives between #ana-zubak and the parallax photo
   to break up two text-heavy sections with a brief structural moment. All numbers
   are derivable from on-page copy — no invented metrics. */
.stats-strip {
  padding: 3.5rem 0;
  background: var(--color-cream);
}

.stats-strip .container {
  /* Reuse the standard 1080px container so the strip aligns with every other section. */
}

.stats-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
}

.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.5rem;
}

.stat-num {
  font-family: var(--font-heading);
  font-size: clamp(2.25rem, 4.5vw, 3.5rem);
  font-weight: 700;
  line-height: 1;
  color: var(--brand-green);
  letter-spacing: -0.02em;
}

.stat-label {
  font-family: var(--font-body);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-stone);
  max-width: 16ch;
}

@media (max-width: 720px) {
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2.5rem 1.5rem;
  }
}

/* ===== FAQ (details/summary accordion) =====
   Native disclosure widgets — keyboard accessible, screen-reader announced, no JS.
   The exclusive-accordion behavior (only one open at a time) is opt-in via the
   name="tsd-faq" attribute on each <details> (HTML 2024 spec; broadly supported in
   2026). Older browsers degrade to "multiple open" — still usable. */
.faq-section {
  padding: var(--r-section) 0;
}

.faq-section .eyebrow {
  margin-bottom: 0.6rem;
}

.faq-section h2 {
  margin-bottom: 2.5rem;
}

.faq-list {
  border-top: 1px solid rgba(90, 79, 68, 0.15);
}

.faq-item {
  border-bottom: 1px solid rgba(90, 79, 68, 0.15);
}

.faq-item > summary {
  list-style: none;
  cursor: pointer;
  padding: 1.4rem 3rem 1.4rem 0;
  font-family: var(--font-heading);
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  font-weight: 700;
  color: var(--color-ink);
  position: relative;
  transition: color 0.15s ease;
}

/* Hide default disclosure triangle (Webkit + Firefox). */
.faq-item > summary::-webkit-details-marker { display: none; }
.faq-item > summary::marker { content: ''; }

/* Custom +/× indicator anchored to the right edge of the summary row. */
.faq-item > summary::after {
  content: '+';
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 1.5rem;
  height: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 400;
  font-size: 1.75rem;
  color: var(--brand-green);
  line-height: 1;
  transition: transform 0.2s ease;
}

.faq-item[open] > summary::after {
  content: '−';
  transform: translateY(-50%) rotate(0deg);
}

.faq-item > summary:hover,
.faq-item[open] > summary {
  color: var(--brand-green-deep);
}

.faq-item > summary:focus-visible {
  outline: 2px solid var(--brand-green);
  outline-offset: 4px;
  border-radius: 2px;
}

.faq-answer {
  padding: 0 3rem 1.6rem 0;
}

.faq-answer p {
  margin: 0;
  color: var(--color-bark);
  font-size: 1.0625rem;
  line-height: 1.65;
}

/* ===== Pravilnik teaser =====
   Post-Kontakt P.S. card linking to the regulations page. Single anchor wraps the
   whole card so the entire surface is clickable; hover lifts subtly without
   competing with the kontakt CTA above. */
.pravilnik-teaser {
  padding: 4rem 0;
}

.teaser-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: 2rem 2.5rem;
  background: var(--color-cream);
  border: 1px solid rgba(90, 79, 68, 0.12);
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.teaser-card:hover,
.teaser-card:focus-visible {
  transform: translateY(-3px);
  border-color: var(--brand-green);
  box-shadow: 0 12px 28px rgba(16, 58, 34, 0.08);
  outline: none;
}

.teaser-meta {
  flex: 1;
  min-width: 0;
}

.teaser-card .eyebrow {
  margin-bottom: 0.5rem;
}

.teaser-card h3 {
  font-family: var(--font-heading);
  font-size: clamp(1.35rem, 2.2vw, 1.75rem);
  font-weight: 700;
  color: var(--brand-green);
  margin: 0 0 0.5rem;
  line-height: 1.2;
}

.teaser-card h3 em {
  color: var(--brand-teal);
  font-style: normal;
  font-weight: 800;
}

.teaser-card p {
  margin: 0;
  color: var(--color-bark);
  font-size: 0.95rem;
  line-height: 1.5;
}

.teaser-arrow {
  font-family: var(--font-heading);
  font-size: 2rem;
  color: var(--brand-green);
  flex-shrink: 0;
  transition: transform 0.25s ease;
}

.teaser-card:hover .teaser-arrow,
.teaser-card:focus-visible .teaser-arrow {
  transform: translateX(6px);
}

@media (max-width: 600px) {
  .teaser-card {
    padding: 1.5rem 1.5rem;
    gap: 1rem;
  }
  .teaser-arrow {
    font-size: 1.5rem;
  }
}

/* ===== Print (regulations page) ===== */
@media print {
  .site-header,
  .site-footer,
  .mobile-menu-overlay,
  .skip-link,
  .menu-toggle,
  .btn,
  .btn-ghost {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
    font-size: 11pt;
    line-height: 1.55;
  }

  section,
  .section-cream-deep,
  .section-forest,
  .section-gold,
  .section-teal,
  .birthday,
  .contact {
    background: #fff !important;
    color: #000 !important;
    padding: 0 !important;
    /* Drop the wave mask on print — saves ink and prevents content clipping at the
       wave troughs since we collapse padding to 0. */
    -webkit-mask: none !important;
            mask: none !important;
  }

  .section-gold .eyebrow,
  .section-gold h1,
  .section-gold h2,
  .section-gold h3,
  .section-gold p,
  .section-gold em,
  .section-teal .eyebrow,
  .section-teal h1,
  .section-teal h2,
  .section-teal h3,
  .section-teal p,
  .section-teal em,
  .section-teal .suradnje-mail-label,
  .section-teal .suradnje-mail-link {
    color: #000 !important;
  }

  .section-teal .suradnje-mail-link {
    border-bottom-color: #000 !important;
  }

  /* Decorative parallax photo wastes ink on print — hide it. */
  .photo-parallax {
    display: none !important;
  }

  .container,
  .policy-body,
  .page-content,
  .pravilnik-page {
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  /* Hide back-to-home + PDF-download links on the printed version —
     redundant once the content is on paper. */
  .pravilnik-back,
  .pravilnik-pdf {
    display: none !important;
  }

  .policy-body h2 {
    page-break-after: avoid;
    color: #000 !important;
    font-size: 13pt;
    margin-top: 1.4em;
  }

  .policy-body p,
  .policy-body li {
    color: #000 !important;
    orphans: 3;
    widows: 3;
  }

  .policy-body a[href]::after {
    content: ' (' attr(href) ')';
    font-size: 0.85em;
    word-break: break-all;
  }

  .policy-body a[href^="#"]::after,
  .policy-body a[href^="mailto:"]::after {
    content: '';
  }

  .reveal {
    opacity: 1 !important;
    transform: none !important;
  }
}
