/* ============================================================
   Življenje Skuškove zbirke — styles
   ============================================================ */
:root{
  --ink:        #363636;
  --ink-soft:   #5a5a5a;
  --paper:      #ffffff;
  --paper-warm: #faf8f4;
  --red:        #e54141;
  --gray:       #d9d9d9;
  --ease:       cubic-bezier(.5,0,.1,1);
  --serif:      "Bodoni Moda", Georgia, serif;
  --sans:       "Average Sans","Cabin",system-ui,sans-serif;
  --ui:         "Cabin","Average Sans",system-ui,sans-serif;
}

*{ box-sizing:border-box; margin:0; padding:0; }
html{ scroll-behavior:smooth; }
body{
  font-family:var(--sans);
  color:var(--ink);
  background:#222;
  -webkit-font-smoothing:antialiased;
  overflow-x:clip;
}
img{ display:block; max-width:100%; }
button{ font:inherit; color:inherit; background:none; border:none; cursor:pointer; }
a{ color:inherit; text-decoration:none; }

/* ============================================================
   App shell
   ============================================================ */
#scroller{ position:relative; background:var(--paper); }
body.locked{ overflow:hidden; height:100vh; }

/* ============================================================
   SCENE — full-height story panel
   ============================================================ */
.scene{
  position:relative;
  min-height:100vh;
  width:100%;
  overflow:hidden;
  display:flex;
  background:var(--paper);
}
.scene__bg{
  position:absolute; inset:0;
  background-size:cover;
  background-position:center;
  z-index:0;
}
.lottie-bg{ background:none; z-index:0; }
.lottie-bg > div{ width:100%; height:100%; }
.lottie-bg svg{ width:100%!important; height:100%!important; display:block; }
#mornarica .lottie-bg > div{ display:flex; justify-content:center; width:auto; }
#mornarica .lottie-bg svg{ width:auto!important; height:100%!important; }
#nastanek-zbirke{ z-index:100; }
#nastanek-zbirke .scene__bg{ background-size:auto 110%; }
#nastanek-zbirke .hpoi-layer{
  position:absolute; right:0; bottom:0; height:110%;
  aspect-ratio:9344/7284; pointer-events:none;
}
#nastanek-zbirke .hpoi-wrap{ pointer-events:auto; }
#nastanek-zbirke .hpoi{ width:42px; height:42px; }
#nastanek-zbirke .hpoi--custom{ width:auto; aspect-ratio:82/60; }
#nastanek-zbirke .hpoi-card{
  position:absolute;
  bottom:5%; right:5%; top:auto; left:auto;
  width:420px; max-width:85vw;
  transform:scale(.97);
}
#nastanek-zbirke .hpoi-card.open{
  transform:scale(1);
}
#nastanek-zbirke .hpoi-card__img{
  height:auto; max-height:70vh;
  object-fit:contain;
  background:var(--paper-warm);
}
#transportni-seznam{ z-index:100; overflow:visible; }
#knjiga-obiskov{ z-index:100; overflow:visible; }
#knjiga-obiskov .hpoi-card__img{ height:auto; object-fit:contain; }
#transportni-seznam{ min-height:calc(66vw * 2648 / 1919); height:auto; }
#transportni-seznam .scene__bg{ background-size:66% auto; background-position:right center; }
#peking{ min-height:calc(80vw * 2726 / 1920); height:auto; }
#peking .scene__bg{ background-size:80% auto; }
#transportni-seznam .hpoi-wrap{ z-index:500; }
#transportni-seznam .hpoi{ width:42px; height:42px; }

/* Transportni seznam — same card sizing, opens next to icon */
#transportni-seznam .hpoi-card{
  width:fit-content; min-width:240px; max-width:500px;
  height:auto;
  z-index:500;
}
#transportni-seznam .hpoi-card__img{
  width:100%;
  height:360px;
  object-fit:contain;
  display:block;
}
#transportni-seznam .hpoi-card__body{
  width:100%;
  box-sizing:border-box;
  padding:20px;
  height:auto;
}

/* watercolor fade behind text columns */
.fade{
  position:absolute; top:0; bottom:0; z-index:1;
  pointer-events:none;
}
.fade--left{
  left:0; width:46%;
  background:linear-gradient(90deg, var(--paper) 38%, rgba(255,255,255,.85) 64%, rgba(255,255,255,0) 100%);
}
.fade--left::before{
  content:""; position:absolute; inset:0;
  background:url(images/watercolor.png) left center / cover no-repeat;
  opacity:.35;
  mask-image:linear-gradient(90deg,#000 30%,transparent 92%);
  -webkit-mask-image:linear-gradient(90deg,#000 30%,transparent 92%);
  mix-blend-mode:multiply;
}
.fade--right{
  right:0; width:46%;
  background:linear-gradient(270deg, var(--paper) 38%, rgba(255,255,255,.85) 64%, rgba(255,255,255,0) 100%);
}
.fade--right::before{
  content:""; position:absolute; inset:0;
  background:url(images/watercolor.png) right center / cover no-repeat;
  opacity:.35;
  mask-image:linear-gradient(270deg,#000 30%,transparent 92%);
  -webkit-mask-image:linear-gradient(270deg,#000 30%,transparent 92%);
  mix-blend-mode:multiply;
}

/* ---- Text column ---- */
.col{
  position:relative; z-index:2;
  display:flex; flex-direction:column;
  justify-content:center;
  gap:34px;
  padding:7vh 5vw;
  max-width:560px;
}
.col--right{ margin-left:auto; align-items:flex-start; }
.col--left{ margin-right:auto; }
.col--center{ margin:auto; text-align:center; align-items:center; max-width:760px; }

.kicker{
  font-family:var(--ui);
  font-weight:600;
  letter-spacing:.22em;
  text-transform:uppercase;
  font-size:14px;
  color:var(--red);
}
.title{
  font-family:var(--serif);
  font-style:italic;
  font-weight:500;
  line-height:.92;
  font-size:clamp(48px,6.2vw,92px);
  color:var(--ink);
  white-space:pre-line;
  text-wrap:balance;
}
.title--upright{ font-style:normal; }
.body{
  font-family:var(--sans);
  font-size:clamp(16px,1.15vw,19px);
  line-height:1.62;
  color:var(--ink);
  white-space:pre-line;
  max-width:46ch;
  text-wrap:pretty;
}

/* reveal animation */
.reveal{ opacity:0; transform:translateY(26px); transition:opacity 1s var(--ease),transform 1s var(--ease); }
.reveal.in{ opacity:1; transform:none; }
.reveal.d1{ transition-delay:.08s; }
.reveal.d2{ transition-delay:.16s; }
.reveal.d3{ transition-delay:.24s; }
@media (prefers-reduced-motion:reduce){ .reveal{ opacity:1!important; transform:none!important; } }

/* ============================================================
   POI markers (diamond in pulsing ring)
   ============================================================ */
.poi{
  position:absolute; z-index:6;
  width:62px; height:62px;
  transform:translate(-50%,-50%);
  display:grid; place-items:center;
  cursor:pointer;
}
.poi__ring{
  position:absolute; inset:0; border-radius:50%;
  border:3px solid #fff;
  box-shadow:0 2px 14px rgba(0,0,0,.35);
  transition:transform .4s var(--ease),background .4s var(--ease);
}
.poi__diamond{
  width:26px; height:26px; border:3px solid #fff;
  transform:rotate(45deg);
  transition:transform .4s var(--ease),background .4s var(--ease);
}
.poi::after{
  content:""; position:absolute; inset:0; border-radius:50%;
  border:2px solid #fff; opacity:.7;
  animation:poipulse 2.6s var(--ease) infinite;
}
@keyframes poipulse{
  0%{ transform:scale(1); opacity:.55; }
  70%{ transform:scale(1.9); opacity:0; }
  100%{ opacity:0; }
}
.poi:hover .poi__ring{ background:rgba(229,65,65,.25); }
.poi:hover .poi__diamond{ background:var(--red); border-color:var(--red); transform:rotate(45deg) scale(1.08); }
.poi--dark .poi__ring,.poi--dark .poi__diamond{ border-color:var(--ink); }
.poi--dark::after{ border-color:var(--ink); }

/* ============================================================
   Top nav bar
   ============================================================ */
.nav{
  position:fixed; top:0; left:0; right:0; z-index:115;
  display:flex; align-items:center; justify-content:space-between;
  padding:22px 34px;
  pointer-events:none;
  transition:opacity .5s,transform .5s;
}
.nav > *{ pointer-events:auto; }
.nav.hide{ opacity:0; transform:translateY(-12px); }

.logo{
  background:none; border:none; padding:0; line-height:0;
  cursor:pointer;
  transition:transform .4s var(--ease);
}
.logo:hover{ transform:translateY(-2px); }
.logo img{ height:46px; width:auto; display:block; }

.nav__right{ display:flex; align-items:center; gap:18px; }

.chapbtn{
  font-family:var(--ui); font-weight:600; letter-spacing:.12em; text-transform:uppercase;
  font-size:13px; color:var(--ink);
  background:rgba(255,255,255,.82); backdrop-filter:blur(8px);
  border:2px solid var(--ink); border-radius:30px;
  padding:9px 18px; display:flex; align-items:center; gap:9px;
  transition:background .3s,color .3s;
}
.chapbtn:hover{ background:var(--ink); color:#fff; }
.chapbtn .dot{ width:7px; height:7px; border-radius:50%; background:var(--red); }

.sound{
  width:48px; height:36px; border-radius:23px; border:3px solid var(--ink);
  background:rgba(255,255,255,.82); backdrop-filter:blur(8px);
  display:grid; place-items:center; position:relative;
  transition:background .3s;
}
.sound:hover{ background:#fff; }
.sound svg{ width:22px; height:20px; color:var(--ink); }
.sound .slash{
  position:absolute; width:30px; height:3px; background:var(--red);
  transform:rotate(-32deg); border-radius:2px;
  transition:opacity .25s,transform .25s;
}
.sound.on .slash{ opacity:0; transform:rotate(-32deg) scaleX(.3); }

.lang{
  display:flex; align-items:center; gap:8px;
  font-family:var(--serif); font-style:italic; font-size:22px; color:var(--ink);
  background:rgba(255,255,255,.82); backdrop-filter:blur(8px);
  border:2px solid var(--ink); border-radius:30px; padding:5px 14px 7px;
}
.lang button{ font-family:var(--sans); font-style:normal; font-size:22px; line-height:1;
  color:var(--ink); opacity:.4; transition:opacity .25s,color .25s; padding:2px 3px; }
.lang button.active{ opacity:1; color:var(--red); }
.lang .sep{ width:2px; height:22px; background:var(--gray); }

/* ============================================================
   Chapter side-rail dots
   ============================================================ */
.chapnav{
  position:fixed; left:22px; top:50%; transform:translateY(-50%);
  z-index:110; display:flex; flex-direction:column; gap:10px;
  pointer-events:none;
  transition:opacity .5s;
}
.chapnav.hide{ opacity:0; }
.chapdot{
  width:10px; height:10px; border-radius:50%;
  border:2px solid var(--ink); background:transparent;
  cursor:pointer; pointer-events:auto;
  transition:background .3s,transform .3s,border-color .3s;
}
.chapdot.cur{ background:var(--red); border-color:var(--red); transform:scale(1.3); }
.chapdot:hover{ background:var(--ink); }
@media (max-width:900px){ .chapnav{ display:none; } }

/* ============================================================
   Language gate
   ============================================================ */
.gate{
  position:fixed; inset:0; z-index:200;
  background:var(--paper);
  display:flex; flex-direction:column; align-items:center; justify-content:center;
  gap:40px;
  transition:opacity .9s var(--ease),visibility .9s;
}
.gate.gone{ opacity:0; visibility:hidden; pointer-events:none; }
.gate__logo{
  background:none; border:none; line-height:0;
  animation:floaty 5s ease-in-out infinite;
}
@keyframes floaty{
  0%,100%{ transform:translateY(0); }
  50%{ transform:translateY(-12px); }
}
.gate__logo img{ height:150px; width:auto; display:block; }
.gate__hint{
  font-family:var(--serif); font-style:italic; font-size:18px; color:var(--ink-soft);
  display:flex; align-items:center; gap:18px;
}
.gate__hint .v{ width:2px; height:26px; background:var(--red); }
.gate__choose{ display:flex; align-items:center; gap:10px; }
.gate__choose button{
  font-family:var(--serif); font-style:italic; font-size:46px; color:var(--ink);
  opacity:.5; transition:opacity .3s,transform .3s,color .3s; padding:4px 16px;
}
.gate__choose button:hover{ opacity:1; color:var(--red); transform:translateY(-3px); }
.gate__choose .v{ width:2px; height:40px; background:var(--gray); }

/* ============================================================
   Progress bar
   ============================================================ */
.progress{
  position:fixed; top:0; left:0; height:3px;
  background:var(--red); z-index:60;
  width:0; transition:width .1s linear;
}

/* ============================================================
   Scroll cue
   ============================================================ */
.scrollcue{
  display:flex; align-items:center; gap:18px; margin-top:8px;
  font-family:var(--sans); font-size:clamp(20px,2vw,30px); color:var(--ink);
}
.mouse{
  width:50px; height:80px; border-radius:30px; border:3px solid var(--ink);
  position:relative; flex:none;
}
.mouse i{
  position:absolute; left:50%; top:9px; transform:translateX(-50%);
  width:26px; height:26px; border-radius:50%; background:var(--red);
  animation:mousewheel 1.8s var(--ease) infinite;
}
@keyframes mousewheel{
  0%{ opacity:0; top:9px; }
  30%{ opacity:1; }
  70%{ opacity:1; top:34px; }
  100%{ opacity:0; top:34px; }
}

/* ============================================================
   Voyage / lottie scenes
   ============================================================ */
.voyage{ background:var(--paper-warm); }
.lottie-wrap{
  position:relative; z-index:2;
  width:min(60vw,820px);
  margin:auto;
  aspect-ratio:16/10;
}
.lottie-wrap > div{ width:100%; height:100%; }
.voyage .scene__bg{ opacity:.9; }
.voyage__overlay{
  position:absolute; inset:0; z-index:1;
  background:radial-gradient(circle at center, rgba(255,255,255,0), rgba(255,255,255,0) 78%);
}

/* ============================================================
   Voyage timeline — scroll-scrubbed map background
   ============================================================ */
.voyage-section{
  position:relative; background:var(--paper-warm);
  min-height:auto; display:block;
}
.voyage-bg{
  position:sticky; top:0; height:100vh; width:100%; z-index:0; overflow:hidden;
}
.voyage-lottie{ position:absolute; inset:0; }
.voyage-lottie canvas,.voyage-lottie svg{ width:100%!important; height:100%!important; display:block; }
.voyage-wash{
  position:absolute; inset:0;
  background:linear-gradient(180deg,
    rgba(250,248,244,.72) 0%,
    rgba(250,248,244,.62) 50%,
    rgba(250,248,244,.72) 100%);
}
.voyage-head .kicker,.voyage-head .title,.voyage-head .body,.voyage-hint,
.vstop__date,.vstop__note,.vstop__body{
  text-shadow:0 1px 12px rgba(250,248,244,.96), 0 0 3px rgba(250,248,244,.9);
}
.voyage-inner{ position:relative; z-index:2; margin-top:-100vh; padding:0 7vw 16vh; }
.voyage-head{
  min-height:100vh; display:flex; flex-direction:column; justify-content:center;
  gap:26px; max-width:760px;
}
.voyage-hint{
  display:flex; align-items:center; gap:12px;
  font-family:var(--ui); font-weight:600; letter-spacing:.14em; text-transform:uppercase;
  font-size:12px; color:var(--red);
}
.voyage-hint::before{ content:""; width:42px; height:2px; background:var(--red); }

.vtl{ display:flex; flex-direction:column; gap:clamp(40px,6vh,72px); max-width:1180px; margin:0 auto; }
.vstop{
  display:grid; grid-template-columns:minmax(0,1fr) clamp(220px,30vw,400px);
  column-gap:6vw; align-items:start;
}
.vstop__date{
  font-family:var(--serif); font-size:clamp(20px,1.7vw,27px); line-height:1.2;
  display:flex; flex-wrap:wrap; gap:.4em; align-items:baseline;
}
.vstop__date .d{ font-style:italic; color:var(--ink-soft); }
.vstop__date .p{ font-weight:600; color:var(--ink); }
.vstop__note{ font-family:var(--sans); font-style:italic; color:var(--ink-soft); font-size:14px; margin-top:5px; }
.vstop__body{ font-family:var(--sans); font-size:15px; line-height:1.6; color:var(--ink); margin-top:10px; max-width:48ch; text-wrap:pretty; }
.vstop__photo{ display:flex; justify-content:flex-start; }
.pframe{
  background:#fff; padding:11px 11px 16px; border-radius:2px;
  box-shadow:0 16px 38px rgba(0,0,0,.20);
  transition:transform .5s var(--ease),box-shadow .5s var(--ease);
  max-width:100%;
}
.pframe img{ width:100%; height:auto; display:block; object-fit:cover; }
.vstop:nth-child(odd)  .pframe{ transform:rotate(-1.1deg); }
.vstop:nth-child(even) .pframe{ transform:rotate(1.3deg); }
.vstop:hover           .pframe{ transform:rotate(0) scale(1.015); box-shadow:0 22px 50px rgba(0,0,0,.26); }

/* ============================================================
   Collection object card
   ============================================================ */
.objcard{
  position:relative; z-index:2; background:#fff; border-radius:6px;
  box-shadow:0 24px 60px rgba(0,0,0,.16);
  padding:22px; margin:auto 6vw auto auto;
  width:min(34vw,420px);
  display:flex; flex-direction:column; gap:16px;
}
.objcard img{ border-radius:4px; width:100%; object-fit:cover; max-height:52vh; }
.objcard .cap{ font-size:15px; line-height:1.5; color:var(--ink-soft); }

/* ---- Tsuneko portraits ---- */
.portraits{
  position:relative; z-index:2; display:flex; gap:30px; align-items:center; margin:auto 6vw;
}
.portraits .pf{
  border-radius:6px; overflow:hidden; box-shadow:0 20px 50px rgba(0,0,0,.22);
  transition:transform .6s var(--ease);
}
.portraits .pf img{ height:min(64vh,640px); width:auto; object-fit:cover; }
.portraits .pf:nth-child(1){ transform:translateY(18px) rotate(-1.5deg); }
.portraits .pf:nth-child(2){ transform:translateY(-18px) rotate(1.5deg); }
.scene.in .portraits .pf:nth-child(1){ transform:translateY(0) rotate(0); }
.scene.in .portraits .pf:nth-child(2){ transform:translateY(0) rotate(0); }

/* ============================================================
   Gallery section
   ============================================================ */
.gallery-section{ background:var(--paper); min-height:auto; display:block; }
.gallery-inner{ padding:14vh 6vw 12vh; max-width:1400px; margin:0 auto; }
.gallery-head{ max-width:640px; display:flex; flex-direction:column; gap:26px; margin-bottom:8vh; }
.gallery-grid{ display:grid; grid-template-columns:repeat(auto-fill,minmax(240px,1fr)); gap:34px 28px; }
.gcard{ display:flex; flex-direction:column; gap:14px; }
.gcard img{
  width:100%; aspect-ratio:4/3; object-fit:cover; border-radius:3px;
  box-shadow:0 14px 32px rgba(0,0,0,.15);
  transition:transform .4s var(--ease),box-shadow .4s var(--ease);
}
.gcard:hover img{ transform:translateY(-4px); box-shadow:0 20px 42px rgba(0,0,0,.22); }
.gcap{ font-size:14px; line-height:1.55; color:var(--ink-soft); }
.figurine-wrap{ margin-top:10vh; }
.figurine-wrap .kicker{ margin-bottom:22px; }
.figurine-strip{ display:grid; grid-template-columns:repeat(6,1fr); gap:22px; }
.fcard{ display:flex; flex-direction:column; gap:10px; }
.fcard img{
  width:100%; aspect-ratio:1/1; object-fit:cover; border-radius:50%;
  box-shadow:0 10px 24px rgba(0,0,0,.18);
  transition:transform .4s var(--ease),box-shadow .4s var(--ease);
}
.fcard:hover img{ transform:translateY(-3px) scale(1.04); box-shadow:0 16px 32px rgba(0,0,0,.24); }
.fcap{ font-size:13px; line-height:1.4; color:var(--ink-soft); text-align:center; }

/* ============================================================
   Scene variants
   ============================================================ */
.scene--tall{ min-height:200vh; }
.col--bottom{ justify-content:flex-end; padding-bottom:10vh; }
.col--dark .kicker,.col--dark .title,.col--dark .body{ color:#fff; }
.col--dark .kicker{ color:var(--red); }
#vrtnarija .title{ color:var(--ink); }
@media(min-width:901px){ #razstava-azija .title{ font-size:clamp(48px,6.2vw,75px); } }
#vrtnarija .collage-col-wrap .fade--left{ width:100%; }

/* ============================================================
   Corner photo (Zgodba section)
   ============================================================ */
.zgodba-corner-img{
  position:absolute; z-index:1; /* under the text column (z 2) */
  right:4vw; bottom:4vh;
  /* fit in the free space right of the centered text column (max 760px wide) */
  width:min(561px, max(0px, calc((100% - 760px) / 2 - 4vw)));
}
@media(max-width:900px){
  .zgodba-corner-img{ display:none; }
}

/* ============================================================
   Intro legend (Zgodba section)
   ============================================================ */
.legend-box{
  position:absolute; z-index:3;
  right:6vw; top:50%; transform:translateY(-50%);
  background:rgba(255,255,255,.86); backdrop-filter:blur(12px);
  border:2px solid var(--gray); border-radius:10px;
  padding:28px 32px; display:flex; flex-direction:column; gap:18px;
  min-width:220px;
}
.lg-row{ display:flex; align-items:center; gap:16px; }
.lg-icon{
  width:44px; height:44px; flex:none;
  display:grid; place-items:center;
  border:2px solid var(--ink); border-radius:50%;
  font-family:var(--serif); font-style:italic; font-size:18px;
}
.lg-icon svg{ width:20px; height:18px; }
.lg-lang{ font-size:16px; }
.lg-chap{ font-size:12px; letter-spacing:-.04em; }
.lg-poi{ position:relative; display:grid; place-items:center;
  width:24px; height:24px; }
.lg-poi .poi__ring{
  position:absolute; inset:-6px; border-radius:50%;
  border:2px solid var(--ink); box-shadow:none; animation:none;
}
.lg-poi .poi__diamond{
  width:12px; height:12px; border:2px solid var(--ink); border-radius:0;
}
.lg-label{
  font-family:var(--ui); font-size:13px; font-weight:600;
  letter-spacing:.1em; text-transform:uppercase; color:var(--ink);
}
@media(max-width:900px){
  .legend-box{ display:none; }
}

/* ============================================================
   Collage section (Vrtnarija, Aktivnosti)
   ============================================================ */
.collage-section{
  background:#1e1a16;
  display:grid;
  grid-template-columns:min(42vw,500px) 1fr;
  align-items:start;
  min-height:100vh;
}
.collage-section--tall{ min-height:160vh; }
.collage-section .col{
  position:sticky; top:0; height:100vh;
  background:transparent; z-index:2;
}
.collage-col-wrap{
  position:relative;
  align-self:stretch;
}
.collage-grid{
  position:relative;
  padding:12vh 5vw 10vh 3vw;
  display:flex; flex-wrap:wrap; gap:22px;
  align-content:flex-start;
}
.cphoto{
  position:relative;
  background:#fff; padding:10px 10px 14px;
  box-shadow:0 18px 44px rgba(0,0,0,.55);
  flex:0 0 auto; width:clamp(160px,22vw,280px);
  transition:transform .5s var(--ease),box-shadow .5s var(--ease);
  cursor:default;
}
.cphoto:nth-child(odd){ transform:rotate(-1.4deg) translateY(6px); }
.cphoto:nth-child(even){ transform:rotate(1.2deg) translateY(-6px); }
.cphoto:hover{ transform:rotate(0) scale(1.04) translateY(-8px);
  box-shadow:0 28px 60px rgba(0,0,0,.7); z-index:5; }
.cphoto img{ width:100%; display:block; object-fit:cover; aspect-ratio:3/4; }
.cphoto__tip{
  margin-top:8px;
  font-family:var(--sans); font-size:14px; line-height:1.45;
  color:var(--ink-soft); text-align:center;
}
.collage-section--bare .cphoto{
  background:none; padding:0; box-shadow:none;
}
.collage-section--bare .cphoto img{ aspect-ratio:auto; }
.collage-section--bare .cphoto:hover{ box-shadow:none; }
.collage-heroimg{
  grid-column:1 / -1;
  width:100%;
  position:relative;
}
.collage-heroimg > img{ width:100%; height:auto; display:block; }
.collage-heroimg .col{ position:absolute; top:0; bottom:0; left:0; }

#aktivnosti .collage-grid{
  grid-column:1 / -1;
  display:grid;
  grid-template-columns:1fr;
  justify-items:center;
  width:100%;
  padding:12vh 5vw 10vh;
  box-sizing:border-box;
  gap:22px;
}
#aktivnosti .cphoto{ width:auto; max-width:50vw; }
#aktivnosti .cphoto{ width:auto; max-width:50vw; }
#aktivnosti .cphoto img{ width:auto; max-width:100%; max-height:70vh; height:auto; aspect-ratio:auto; object-fit:unset; display:block; }
/* caption takes no part in sizing the frame, then stretches to the photo's width */
#aktivnosti .cphoto__tip{ width:0; min-width:100%; }
#aktivnosti .collage-heroimg .col .kicker,
#aktivnosti .collage-heroimg .col .title,
#aktivnosti .collage-heroimg .col .body{ color:var(--ink); }

.collage-fullimg{
  grid-column:1 / -1;
  width:100vw; position:relative; left:50%; transform:translateX(-50%);
}
.collage-fullimg img{ width:100%; height:auto; display:block; }
@media(max-width:900px){
  .collage-section{ grid-template-columns:1fr; }
  .collage-section .col{ position:relative; height:auto; padding-bottom:6vh; }
  .collage-grid{ padding:6vw; gap:14px; }
  .cphoto{ width:clamp(130px,38vw,220px); }
}

/* ============================================================
   Document section (Transportni seznam, Knjiga obiskov)
   ============================================================ */
.doc-section{
  background:#f5f0e4;
  display:grid;
  grid-template-columns:min(38vw,480px) 1fr;
  align-items:start;
  min-height:100vh;
}
.doc-section .col{ position:sticky; top:0; height:100vh; z-index:2; }
.docview{
  position:relative;
  padding:10vh 5vw 10vh 4vw;
  display:flex; flex-direction:column; gap:28px;
  z-index:2;
}
.docpage{
  background:#fefce6;
  border:1px solid #d0c8a8; border-radius:2px;
  padding:32px 36px;
  box-shadow:0 6px 28px rgba(0,0,0,.12), 3px 3px 0 rgba(0,0,0,.06);
  font-family:"Courier New",Courier,monospace;
  font-size:13px; line-height:1.65; color:#3a3530;
  position:relative;
}
.docpage--book{
  font-family:var(--serif); font-style:italic;
  font-size:15px; background:#fffdf5;
  border-left:4px solid var(--red);
}
.doc-header{ margin-bottom:20px; border-bottom:1px solid #c8c0a0; padding-bottom:14px; }
.doc-title{ font-size:14px; font-weight:600; letter-spacing:.06em; text-transform:uppercase; }
.doc-sub{ font-size:12px; color:#7a7060; margin-top:4px; }
.doc-entry{ margin-bottom:18px; }
.doc-entry__label{
  font-size:13px; font-weight:600; text-transform:uppercase;
  letter-spacing:.08em; color:#5a4a38; margin-bottom:6px;
  padding-bottom:4px; border-bottom:1px solid #d0c8a8;
}
.doc-entry__items{ margin-left:20px; }
.doc-entry__items li{ margin-bottom:3px; }
.docbook__year{
  font-family:var(--ui); font-size:11px; font-weight:700;
  letter-spacing:.18em; text-transform:uppercase;
  color:var(--red); margin-bottom:10px; font-style:normal;
}
.docbook__text{
  font-size:16px; line-height:1.7; color:var(--ink);
  border:none; margin:0 0 12px;
}
.docbook__source{
  font-family:var(--ui); font-style:normal; font-size:12px;
  letter-spacing:.08em; color:var(--ink-soft);
}
/* POI markers inside docview are positioned relative to it */
.poi--doc{ position:absolute; z-index:6; transform:translate(-50%,-50%); }
@media(max-width:900px){
  .doc-section{ grid-template-columns:1fr; }
  .doc-section .col{ position:relative; height:auto; padding-bottom:6vh; }
  .docview{ padding:6vw; }
}

/* ============================================================
   Portraits pair (Pot v Evropo)
   ============================================================ */
.portraits{
  position:relative; z-index:2; display:flex; gap:30px; align-items:flex-end;
  margin:auto 6vw auto auto;
}
.pf{
  display:flex; flex-direction:column; align-items:center; gap:12px;
  border-radius:6px; overflow:visible;
  transition:transform .6s var(--ease);
}
.pf img{
  height:min(60vh,580px); width:auto; object-fit:cover;
  border-radius:6px;
  box-shadow:0 22px 54px rgba(0,0,0,.32);
}
.pf-label{
  font-family:var(--serif); font-style:italic; font-size:15px;
  color:var(--ink); text-align:center;
  background:rgba(255,255,255,.9); padding:6px 14px; border-radius:4px;
}
.pf:nth-child(1){ transform:translateY(12px) rotate(-1.2deg); }
.pf:nth-child(2){ transform:translateY(-12px) rotate(1.2deg); }
.scene.in .pf:nth-child(1){ transform:translateY(0) rotate(0); }
.scene.in .pf:nth-child(2){ transform:translateY(0) rotate(0); }
@media(max-width:900px){
  .portraits{ flex-direction:column; gap:14px; margin:14vh auto 8vh; }
  .pf img{ height:34vh; }
}

/* ============================================================
   Zbirka v Ljubljani — POI house markers + Nesojen muzej sub
   ============================================================ */
.poi--house .poi__house{
  font-size:28px; color:#fff; line-height:1;
}
/* Zbirka v Ljubljani — full-width map, auto height */
#zbirka-v-lj{ display:block; min-height:0; overflow:visible; }
.zbirka-map-wrap{ position:relative; width:100%; }
.zbirka-map__img{ width:100%; height:auto; display:block; }
#zbirka-v-lj .col{ position:absolute; top:0; bottom:0; left:0; }

.museum-sub{
  position:relative; min-height:80vh;
  display:flex; align-items:center;
  overflow:hidden;
}
#nesojen-muzej{ z-index:50; }
.museum-sub__bg{
  position:absolute; inset:0;
  background-size:contain; background-position:center; background-repeat:no-repeat;
}
.museum-sub__overlay{
  position:absolute; inset:0;
  background:linear-gradient(90deg, rgba(255,255,255,0) 30%, rgba(54,54,54,.72) 100%);
}
.museum-sub .col{
  position:relative; z-index:2;
  margin-left:auto; /* right-align */
}
.museum-sub .title,.museum-sub .body,.museum-sub .kicker{ color:#fff; }

/* ============================================================
   Poroka
   ============================================================ */
#poroka{ height:calc(90vw * 4096 / 3237); min-height:0; }
#poroka .scene__bg{ background-size:90% auto; background-repeat:no-repeat; }

/* ============================================================
   Poroka — wedding document
   ============================================================ */
.wedding-doc{
  position:absolute; bottom:8vh; left:6vw; z-index:3;
  background:rgba(255,255,255,.93); backdrop-filter:blur(8px);
  border:1px solid var(--gray); border-radius:6px;
  padding:28px 36px; max-width:min(44vw,560px);
  box-shadow:0 20px 50px rgba(0,0,0,.16);
}
.wedding-doc__title{
  font-family:var(--ui); font-weight:600; letter-spacing:.14em;
  text-transform:uppercase; font-size:12px; color:var(--red); margin-bottom:12px;
}
.wedding-doc__text{
  font-family:var(--serif); font-style:italic; font-size:17px; line-height:1.6;
  color:var(--ink); margin-bottom:14px;
}
.wedding-doc__sig{
  font-family:var(--serif); font-style:italic; font-size:16px;
  color:var(--ink-soft);
}
@media(max-width:900px){
  .wedding-doc{ max-width:90vw; left:4vw; bottom:4vh; }
}

/* ============================================================
   Ljubljana homes strip (kept for reference; now in POI overlay)
   ============================================================ */
.homes-wrap{
  position:relative; z-index:2;
  display:grid; grid-template-columns:repeat(2,1fr); gap:24px;
  margin:auto 6vw auto auto; width:min(46vw,620px);
}
.homecard{
  background:#fff; border-radius:6px; box-shadow:0 20px 44px rgba(0,0,0,.18);
  padding:14px 14px 18px; display:flex; flex-direction:column; gap:10px;
}
.homecard img{ width:100%; aspect-ratio:4/3; object-fit:cover; border-radius:3px; }
.homeyear{
  font-family:var(--ui); font-weight:600; letter-spacing:.1em;
  text-transform:uppercase; font-size:11px; color:var(--red);
}
.homecap{ font-size:13px; line-height:1.5; color:var(--ink-soft); }

/* ============================================================
   Hover caption chips (on photos)
   ============================================================ */
.hovertag{
  position:absolute; z-index:7; transform:translate(-50%,-50%);
}
.hovertag .hdot{
  width:16px; height:16px; border-radius:50%; background:var(--red);
  border:3px solid #fff; box-shadow:0 2px 8px rgba(0,0,0,.4); cursor:help;
}
.hovertag .htip{
  position:absolute; left:50%; bottom:150%;
  transform:translateX(-50%) translateY(8px);
  background:var(--ink); color:#fff;
  padding:10px 14px; border-radius:6px;
  font-size:14px; line-height:1.4; width:max-content; max-width:260px;
  opacity:0; pointer-events:none;
  transition:opacity .3s,transform .3s;
  white-space:pre-wrap;
}
.hovertag:hover .htip{ opacity:1; transform:translateX(-50%) translateY(0); }
.hovertag .htip::after{
  content:""; position:absolute; top:100%; left:50%; transform:translateX(-50%);
  border:7px solid transparent; border-top-color:var(--ink);
}

/* ============================================================
   POI overlay (slide-in panel)
   ============================================================ */
.overlay{
  position:fixed; inset:0; z-index:120;
  display:flex; justify-content:flex-end;
  pointer-events:none;
}
.overlay.open{ pointer-events:auto; }
.overlay__scrim{
  position:absolute; inset:0; background:rgba(40,40,40,0);
  transition:background .5s var(--ease);
}
.overlay.open .overlay__scrim{ background:rgba(40,40,40,.45); }
.overlay__panel{
  position:relative; height:100%;
  width:min(92vw,1180px);
  background:var(--paper);
  transform:translateX(102%);
  transition:transform .62s var(--ease);
  display:flex; overflow:hidden;
  box-shadow:-30px 0 80px rgba(0,0,0,.3);
}
.overlay.open .overlay__panel{ transform:translateX(0); }

.overlay__media{
  position:relative; flex:1 1 52%; min-width:0;
  background:transparent center/contain no-repeat;
}
.overlay__media::after{ display:none; }
.overlay__text{
  flex:1 1 48%;
  padding:9vh 4.5vw;
  display:flex; flex-direction:column; justify-content:center; gap:30px;
  overflow-y:auto; position:relative;
}
.overlay__text .title{ font-size:clamp(40px,4vw,78px); }
.overlay[data-sec="zbirka-v-lj"] .overlay__text .title{ font-size:3vw; }
.overlay__tab{
  position:absolute; left:0; top:0; bottom:0; width:6px; background:var(--red);
}
.overlay__back{
  position:absolute; top:28px; left:34px; z-index:5;
  display:flex; align-items:center; gap:12px;
  font-family:var(--ui); font-weight:600; letter-spacing:.12em; text-transform:uppercase; font-size:13px;
}
.overlay__back .arrow{
  width:46px; height:46px; border-radius:50%; border:3px solid var(--ink);
  display:grid; place-items:center;
  transition:background .3s,color .3s;
}
.overlay__back:hover .arrow{ background:var(--ink); color:#fff; }
.overlay__close{
  position:absolute; top:28px; right:34px; z-index:5;
  width:58px; height:58px; border-radius:50%;
  border:4px solid var(--ink); display:grid; place-items:center;
  transition:transform .4s var(--ease),background .3s;
}
.overlay__close:hover{ transform:rotate(90deg); background:var(--ink); }
.overlay__close:hover svg{ color:#fff; }
.overlay__close svg{ width:24px; height:24px; color:var(--ink); }

/* ============================================================
   Chapter drawer
   ============================================================ */
.drawer{
  position:fixed; top:0; left:0; bottom:0; z-index:130;
  width:min(86vw,420px); background:var(--ink); color:#fff;
  padding:90px 40px;
  transform:translateX(-104%); transition:transform .55s var(--ease);
  display:flex; flex-direction:column; gap:6px; overflow-y:auto;
}
.drawer.open{ transform:none; }
.drawer h3{
  font-family:var(--ui); text-transform:uppercase; letter-spacing:.2em;
  font-size:13px; color:var(--red); margin-bottom:20px;
}
.drawer a{
  font-family:var(--serif); font-style:italic; font-size:30px; color:#fff;
  padding:11px 0; border-bottom:1px solid rgba(255,255,255,.12);
  display:flex; align-items:baseline; gap:14px;
  opacity:.78; transition:opacity .3s,padding-left .3s,color .3s;
}
.drawer a .n{ font-family:var(--ui); font-style:normal; font-size:13px; color:var(--red); width:26px; }
.drawer a:hover{ opacity:1; padding-left:8px; }
.drawer a.cur{ opacity:1; color:var(--red); }
.drawer__close{
  position:absolute; top:30px; right:30px;
  width:46px; height:46px; border-radius:50%;
  border:2px solid rgba(255,255,255,.5); display:grid; place-items:center;
  transition:border-color .3s;
}
.drawer__close:hover{ border-color:#fff; }
.drawer__close svg{ width:20px; height:20px; color:#fff; }
.scrim-dark{
  position:fixed; inset:0; background:rgba(0,0,0,0); z-index:125;
  pointer-events:none; transition:background .5s;
}
.scrim-dark.show{ background:rgba(0,0,0,.4); pointer-events:auto; }

/* ============================================================
   Responsive — tablet
   ============================================================ */
@media (max-width:900px){
  .fade--left,.fade--right{
    width:100%;
    background:linear-gradient(180deg,rgba(255,255,255,.94) 55%,rgba(255,255,255,.6));
  }
  .fade--left::before,.fade--right::before{
    mask-image:none; -webkit-mask-image:none; opacity:.18;
  }
  .col{ max-width:none; width:100%; padding:14vh 8vw 10vh; justify-content:flex-end; }
  .col--right,.col--left{ margin:0; }
  .overlay__panel{ flex-direction:column; width:100vw; }
  .overlay__media{ flex:0 0 38vh; }
  .overlay__media::after{ background:linear-gradient(0deg, var(--paper) 2%, rgba(255,255,255,0) 40%); }
  .overlay__text{ padding:5vh 8vw 9vh; }
  .objcard,.lottie-wrap{ width:84vw; margin:auto; }
  .portraits{ flex-direction:column; gap:14px; margin:14vh auto 8vh; }
  .portraits .pf img{ height:34vh; }
  .nav{ padding:14px 16px; }
  .chapbtn span:not(.dot){ display:none; }
  .title{ font-size:clamp(40px,11vw,62px); }
  .voyage-inner{ padding:0 7vw 12vh; }
  .vstop{ grid-template-columns:1fr; row-gap:18px; }
  .vstop__photo{ justify-content:flex-start; }
  .pframe{ max-width:min(78vw,420px); }
  .vstop:nth-child(odd) .pframe,.vstop:nth-child(even) .pframe{ transform:none; }
  .gallery-grid{ grid-template-columns:repeat(auto-fill,minmax(160px,1fr)); gap:20px 16px; }
  .figurine-strip{ grid-template-columns:repeat(3,1fr); }
  .homes-wrap{ width:100%; grid-template-columns:1fr; margin:6vh auto; }
}

/* ============================================================
   Responsive — phone
   ============================================================ */
@media (max-width:560px){
  .gate__logo img{ height:110px; width:auto; }
  .lang{ font-size:18px; } .lang button{ font-size:18px; }
  .gallery-grid{ grid-template-columns:repeat(auto-fill,minmax(140px,1fr)); }
  .figurine-strip{ grid-template-columns:repeat(2,1fr); }
  .overlay__back{ top:18px; left:16px; }
  .overlay__close{ top:18px; right:16px; width:46px; height:46px; }
}

/* ============================================================
   Hover POI (sparkle marker + floating card)
   ============================================================ */
.hpoi-wrap{
  position:absolute; transform:translate(-50%,-50%); z-index:50;
}
.hpoi{
  display:block; width:60px; height:60px;
  padding:0; background:none; border:none; cursor:pointer;
  transition:transform .2s var(--ease);
}
.hpoi:hover{ transform:scale(1.15); }
.hpoi img{ width:100%; height:100%; display:block; }
.hpoi--custom{ width:auto; aspect-ratio:82/60; }
.hpoi--custom img{ object-fit:contain; }

.hpoi-card{
  position:absolute; width:280px;
  top:50%; transform:translateY(-50%) scale(.96);
  left:calc(100% + 10px);
  background:#fff; border-radius:5px; overflow:hidden;
  box-shadow:0 6px 28px rgba(0,0,0,.18);
  opacity:0; pointer-events:none;
  transition:opacity .22s var(--ease), transform .22s var(--ease);
  z-index:100;
}
.hpoi-wrap--left .hpoi-card{
  left:auto; right:calc(100% + 10px);
}
.hpoi-card.open{
  opacity:1; pointer-events:auto; transform:translateY(-50%) scale(1);
}
.hpoi-card__img{
  width:100%; height:180px; object-fit:cover; display:block;
}
.hpoi-card__body{ padding:12px 16px 16px; }
.hpoi-card__title{
  font-family:'Bodoni Moda',serif; font-size:20px; line-height:1.2;
  color:var(--ink); margin:0 0 6px;
}
.hpoi-card__text{
  font-family:'Average Sans',sans-serif; font-size:13px; line-height:1.5;
  color:var(--ink-soft); margin:0;
}

/* Collage hero image (Vrtnarija) */
.collage-hero{
  grid-column:1 / -1;
  width:83%; max-height:55vh; overflow:hidden;
  border-radius:0 50px 0 0;
}
.collage-hero img{ width:100%; height:100%; object-fit:cover; display:block; }
@media(max-width:900px){
  .collage-hero{ width:100%; border-radius:0; max-height:40vh; }
  .hpoi-card{ width:220px; }
}

/* Muzej — full-width sequential photos */
.muzej-photos{ display:block; width:100%; }
#razstava-photos{ position:relative; }

/* ============================================================
   Full-screen YouTube embed
   ============================================================ */
.yt-section{ background:#000; }
.yt-wrap{
  position:absolute; top:50%; left:50%;
  width:100vw; height:56.25vw;       /* 16:9 */
  min-height:100vh; min-width:177.78vh; /* cover the viewport like background-size:cover */
  transform:translate(-50%,-50%);
}
.yt-frame{ width:100%; height:100%; display:block; border:0; }

/* ============================================================
   Site footer — credits (deliberately set apart from the content)
   ============================================================ */
.site-footer{
  position:relative;
  background:var(--gray);
  border-top:3px solid var(--red);
  padding:10vh 6vw 6vh;
}
.footer-inner{ max-width:760px; margin:0 auto; text-align:center; }
.footer-title{
  font-family:var(--serif); font-weight:700;
  font-size:clamp(28px,4vw,46px);
  color:var(--ink);
  margin:0 0 28px;
}
.footer-title:has(+ .footer-subtitle){ margin-bottom:10px; }
.footer-subtitle{
  font-family:var(--serif); font-style:italic;
  font-size:clamp(18px,2vw,24px); line-height:1.3;
  color:var(--ink-soft);
  margin:0 0 28px;
}
.footer-body p{
  font-family:var(--sans); font-size:14px; line-height:1.7;
  color:var(--ink-soft);
  margin:0 0 14px;
}
.footer-body ul{
  list-style:none; padding:0; margin:0 0 14px;
}
.footer-body li{
  font-family:var(--sans); font-size:14px; line-height:1.7;
  color:var(--ink-soft);
  margin:0 0 8px;
}
.footer-logos{
  display:flex; flex-wrap:wrap; align-items:center; justify-content:center; gap:32px;
  margin-top:40px; padding-top:28px;
  border-top:1px solid rgba(0,0,0,.14);
}
.footer-logo{ height:38px; display:flex; align-items:center; }
.footer-logo img{
  max-height:100%; width:auto; display:block;
}
@media(max-width:900px){
  .site-footer{ padding:8vh 7vw 6vh; }
  .footer-logos{ gap:22px; }
}
.muzej-fullimg{ width:100%; height:auto; display:block; }

/* Panorama — full-width image between Aktivnosti and Knjiga obiskov */
.panorama-photo{ display:block; width:100vw; }
.panorama-photo__img{ width:100vw; height:auto; display:block; }

/* ============================================================
   POI Editor — dev only, hidden from end users
   ============================================================ */
#editor-badge{
  display:none; position:fixed; bottom:12px; left:50%; transform:translateX(-50%);
  background:#e54141; color:#fff; font:700 11px/1 Cabin,sans-serif;
  letter-spacing:.06em; text-transform:uppercase;
  padding:6px 14px; border-radius:20px; z-index:99999; pointer-events:none;
}
#editor-badge.visible{ display:block; }

#poi-editor-panel{
  display:none; position:fixed; top:0; right:0; bottom:0; width:320px;
  background:#fff; border-left:1px solid #d9d9d9;
  flex-direction:column; z-index:99998;
  font:14px/1.5 Average\ Sans,sans-serif; color:#363636;
  box-shadow:-4px 0 16px rgba(0,0,0,.1);
}
#poi-editor-panel.visible{ display:flex; }

.ed-header{
  display:flex; align-items:center; justify-content:space-between;
  padding:14px 16px; border-bottom:1px solid #d9d9d9;
  background:#363636; color:#fff;
}
.ed-title{ font:700 13px/1 Cabin,sans-serif; letter-spacing:.08em; text-transform:uppercase; }
.ed-close{
  background:none; border:none; color:#fff; font-size:20px; line-height:1;
  cursor:pointer; padding:0 2px; opacity:.7;
}
.ed-close:hover{ opacity:1; }

.ed-body{
  flex:1; overflow-y:auto; padding:16px;
  display:flex; flex-direction:column; gap:14px;
}
.ed-hint{ font-size:13px; color:#5a5a5a; margin:0; line-height:1.6; }
.ed-section-label{ font-size:12px; color:#5a5a5a; }
.ed-section-label b{ color:#363636; }

.ed-group{
  display:flex; flex-direction:column; gap:5px;
}
.ed-label{ font:700 11px/1 Cabin,sans-serif; letter-spacing:.06em; text-transform:uppercase; color:#5a5a5a; }
.ed-group input[type="text"],
.ed-group input[type="number"],
.ed-group textarea{
  width:100%; box-sizing:border-box;
  border:1px solid #d9d9d9; border-radius:4px;
  padding:6px 8px; font:13px/1.5 Average\ Sans,sans-serif; color:#363636;
  resize:vertical;
}
.ed-group input[type="text"]:focus,
.ed-group input[type="number"]:focus,
.ed-group textarea:focus{
  outline:none; border-color:#363636;
}
.ed-row{ display:flex; gap:10px; }
.ed-row label{ flex:1; display:flex; flex-direction:column; gap:4px; font-size:12px; color:#5a5a5a; }
.ed-row input{ width:100%; }

.ed-footer{
  padding:12px 16px; border-top:1px solid #d9d9d9;
  display:flex; flex-direction:column; gap:6px;
}
#edCopyAll{
  width:100%; padding:9px; background:#363636; color:#fff; border:none;
  border-radius:4px; font:700 12px/1 Cabin,sans-serif; letter-spacing:.05em;
  text-transform:uppercase; cursor:pointer;
}
#edCopyAll:hover{ background:#1a1a1a; }
#edCopyMsg{ font-size:12px; color:#e54141; text-align:center; }

/* ============================================================
   Pot v Azijo — voyage stops timeline
   ============================================================ */
.voyage-timeline{
  background: var(--paper-warm);
  padding: 8vh 8vw 10vh;
  box-sizing: border-box;
}
.vstop{
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 36px 48px;
  padding: 40px 0;
  border-bottom: 1px solid var(--gray);
  align-items: start;
}
.vstop--noimg{
  grid-template-columns: 1fr;
}
.vstop:last-child{ border-bottom: none; }
.vstop__date{
  font: 500 12px/1 Cabin, sans-serif;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 10px;
}
.vstop__place{
  font: 700 2.4em/1.1 Cabin, sans-serif;
  color: var(--ink);
  margin: 0 0 14px;
}
.vstop__body{
  font: 15px/1.65 "Average Sans", sans-serif;
  color: var(--ink-soft);
  margin: 0;
}
.vstop__imgs{
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.vstop__imgs img{
  width: 100%;
  height: auto;
  display: block;
  border-radius: 2px;
}

/* ============================================================
   Knjiga obiskov — collage photo gallery with hover POI cards
   ============================================================ */
.knjiga-gallery{
  background: var(--paper-warm);
  display: flex;
  flex-direction: column;
  align-items: center;
}
.kg-card{
  position: relative;
  width: 70%;
}
.kg-card > img{
  display: block;
  width: 100%;
  height: auto;
}

/* hpoi card overrides for gallery context — appears above the icon */
#knjiga-gallery .hpoi-wrap{ position:absolute; }
#knjiga-gallery .hpoi-card{
  position: absolute;
  bottom: calc(100% + 10px);
  right: 0;
  left: auto;
  top: auto;
  width: 260px;
  max-width: 80vw;
  height: auto;
  transform: none;
  box-shadow: 0 4px 20px rgba(0,0,0,.2);
}
#knjiga-gallery .hpoi-card.open{ transform: none; }
#knjiga-gallery .hpoi-wrap--left .hpoi-card{
  right: auto;
  left: 0;
}
#knjiga-gallery .hpoi-card__img{
  width: 100%;
  height: auto;
  display: block;
  object-fit: unset;
}
#knjiga-gallery .hpoi-card__body{
  width: 100%;
  box-sizing: border-box;
  height: auto;
  padding: 14px;
}
#knjiga-gallery .kg-body2{
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--gray);
  font-style: italic;
}

/* Pot v Evropo — 3-column grid override */
#pot-v-evropo-stops{
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 40px 48px;
  align-items: start;
}
#pot-v-evropo-stops .vstop{
  display: flex;
  flex-direction: column;
  padding: 0;
  border-bottom: none;
  border-top: 1px solid var(--gray);
  padding-top: 28px;
}
#pot-v-evropo-stops .vstop__text{
  display: flex;
  flex-direction: column;
  flex: 1;
}
#pot-v-evropo-stops .vstop__imgs{
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
#pot-v-evropo-stops .vstop__imgs img{
  width: auto;
  max-width: 100%;
  max-height: 70vh;
}

/* ============================================================
   Voyage Stop Editor panel (Alt+V)
   ============================================================ */
#vstop-editor-panel{
  display:none; position:fixed; top:0; left:0; bottom:0; width:320px;
  background:#fff; border-right:1px solid #d9d9d9;
  flex-direction:column; z-index:99998;
  font:14px/1.5 "Average Sans",sans-serif; color:#363636;
  box-shadow:4px 0 16px rgba(0,0,0,.1);
}
#vstop-editor-panel.visible{ display:flex; }
#vstop-editor-badge{
  display:none; position:fixed; bottom:40px; left:50%; transform:translateX(-50%);
  background:#363636; color:#fff; font:700 11px/1 Cabin,sans-serif;
  letter-spacing:.06em; text-transform:uppercase;
  padding:6px 14px; border-radius:20px; z-index:99999; pointer-events:none;
}
#vstop-editor-badge.visible{ display:block; }
.vstop-editor-active .vstop{ cursor:pointer; }
.vstop--selected{ outline:2px solid #e54141; outline-offset:2px; }

/* drag cursor on all POI buttons in editor mode */
.poi-editor-active .poi{ cursor:grab !important; }
.poi-editor-active .poi:active{ cursor:grabbing !important; }
.poi-editor-active .hpoi{ cursor:grab !important; }
.poi-editor-active .hpoi:active{ cursor:grabbing !important; }

/* highlight selected POI */
.poi.poi--selected .poi__ring{
  border-color:#e54141 !important;
  box-shadow:0 0 0 3px rgba(229,65,65,.35);
}
.hpoi.poi--selected img{
  filter:drop-shadow(0 0 5px rgba(229,65,65,.8));
}
