:root { --ink: #1d1445; --ink-2: rgba(29,20,69,.62); --soft: #efeaf8; --ml: 'Anek Malayalam', 'Noto Sans Malayalam', system-ui, sans-serif; --en: 'Plus Jakarta Sans', system-ui, sans-serif; }
/* shared poster viewer (home page and map): soft, story-like, with a love button */
/* pin close-up */
.viewer { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 20px; }
.viewer-bg { position: absolute; inset: 0; background: rgba(15,8,40,.72); animation: vfade .2s; }
@keyframes vfade { from { opacity: 0; } }
@keyframes vrise { from { transform: translateY(18px) scale(.98); opacity: 0; } }
.viewer-card { position: relative; display: flex; width: min(1020px, 100%); max-height: calc(100dvh - 40px); border-radius: 32px; overflow: hidden; background: #fff; box-shadow: 0 30px 90px rgba(0,0,0,.5); animation: vrise .3s cubic-bezier(.2,.9,.3,1); }
.viewer-img { flex: 1 1 56%; min-width: 0; display: grid; place-items: center; background: #f4f0fb; }
.viewer-img img { display: block; max-width: 100%; max-height: calc(100dvh - 40px); object-fit: contain; }
.viewer-info { flex: 1 1 44%; min-width: 260px; display: flex; flex-direction: column; gap: 8px; padding: 36px 32px; overflow: auto; }
.viewer-info h2 { font: 800 28px/1.15 var(--ml); }
.viewer-info p { font: 600 15px var(--ml), var(--en); }
.viewer-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; padding-top: 18px; }
.viewer-x, .viewer-nav { position: absolute; z-index: 3; border: 0; border-radius: 50%; background: #fff; color: var(--ink); box-shadow: 0 6px 22px rgba(0,0,0,.3); display: grid; place-items: center; }
.viewer-x { top: 16px; right: 16px; width: 44px; height: 44px; font-size: 16px; }
.viewer-nav { top: 50%; translate: 0 -50%; width: 48px; height: 48px; font-size: 30px; line-height: 1; padding-bottom: 4px; }
.viewer-nav.prev { left: 16px; } .viewer-nav.next { right: 16px; }
.viewer-nav[disabled] { opacity: .3; cursor: default; }
.viewer .muted { color: var(--ink-2); font-weight: 500; font-size: 13.5px; }
.viewer .btn { height: 46px; padding: 0 20px; border: 0; border-radius: 24px; background: var(--soft); color: var(--ink); font: 800 14.5px var(--ml), var(--en); text-decoration: none; display: inline-flex; align-items: center; cursor: pointer; }
.viewer .btn:hover { background: #e3dbf3; }
.viewer .btn.primary { background: linear-gradient(135deg, #ffd23a, #ff9d00); color: #1a0b4a; }
.viewer .btn.ghost { background: transparent; color: var(--ink-2); }
/* ---------- poster modal: soft, story-like, with a love button ---------- */
.viewer-bg { background: rgba(40,24,100,.55); backdrop-filter: blur(10px); }
.viewer-card { background: #fff; border-radius: 34px; box-shadow: 0 40px 100px rgba(30,15,90,.45); }
.viewer-img { position: relative; padding: 26px; background: radial-gradient(120% 90% at 30% 0%, #fff4e2 0%, #f3ecff 55%, #e8defa 100%); }
.viewer-img img { border-radius: 22px; box-shadow: 0 22px 60px rgba(40,20,110,.3); max-height: calc(100dvh - 92px); -webkit-user-select: none; user-select: none; }
.viewer-info { gap: 10px; padding: 34px 30px 28px; }
.v-head { display: flex; align-items: center; gap: 14px; padding-right: 44px; }
.v-ring { flex: none; width: 56px; height: 56px; border-radius: 50%; border: 3px solid transparent; display: grid; place-items: center;
  background: linear-gradient(#fff, #fff) padding-box, linear-gradient(135deg, #ffd23a, #ff8a00, #e11fc0) border-box; }
.v-ring img { width: 76%; height: 76%; object-fit: contain; }
.v-head h2 { font: 800 25px/1.15 var(--ml), var(--en); }
.v-head p { margin-top: 2px; font: 600 14px var(--ml), var(--en); color: var(--ink-2); }
.v-react { display: flex; align-items: center; gap: 14px; margin: 12px 0 2px; padding: 14px 16px; border-radius: 22px; background: linear-gradient(135deg, #fff1f5, #fff6ea); flex-wrap: wrap; }
.v-love { position: relative; flex: none; width: 58px; height: 58px; border: 2px solid #ffc7d8; border-radius: 50%; background: #fff; display: grid; place-items: center; cursor: pointer; transition: transform .15s, background .2s, border-color .2s; }
.v-love svg { width: 28px; height: 28px; fill: none; stroke: #ff3d6e; stroke-width: 2.2; stroke-linejoin: round; transition: fill .2s; }
.v-love:hover { transform: scale(1.06); }
.v-love:active { transform: scale(.94); }
.v-love[aria-pressed="true"] { background: linear-gradient(135deg, #ff5c8a, #ff2d55); border-color: transparent; }
.v-love[aria-pressed="true"] svg { fill: #fff; stroke: #fff; }
.v-love.pop { animation: lovepop .5s cubic-bezier(.2, 1.4, .3, 1); }
@keyframes lovepop { 0% { transform: scale(1); } 35% { transform: scale(1.4); } 100% { transform: scale(1); } }
.v-count { display: flex; flex-direction: column; line-height: 1.1; }
.v-count b { font: 800 26px var(--en); color: #d6174a; }
.v-count span { font: 700 12px var(--en); letter-spacing: .04em; text-transform: uppercase; color: var(--ink-2); }
.v-hint { flex: 1 1 100%; font: 500 12px var(--en); color: var(--ink-2); }
.v-burst { position: absolute; left: 50%; top: 50%; z-index: 4; font-size: 96px; line-height: 1; translate: -50% -50%; opacity: 0; pointer-events: none; filter: drop-shadow(0 10px 24px rgba(214,23,74,.5)); }
.v-burst.go { animation: burst .9s cubic-bezier(.2, .9, .3, 1); }
@keyframes burst { 0% { opacity: 0; transform: scale(.2); } 25% { opacity: 1; transform: scale(1.25); } 60% { opacity: 1; transform: scale(1); } 100% { opacity: 0; transform: scale(1.1) translateY(-30px); } }
.v-float { position: fixed; z-index: 80; font-size: 22px; pointer-events: none; animation: vfloat 1.2s ease-out forwards; }
@keyframes vfloat { from { opacity: 1; transform: translate(0, 0) scale(.6); } to { opacity: 0; transform: translate(var(--dx), -120px) scale(1.2); } }
@media (max-width: 767px) {
  .viewer-img { padding: 16px 16px 8px; }
  .viewer-img img { max-height: 54dvh; }
  .viewer-info { padding: 14px 20px calc(22px + env(safe-area-inset-bottom)); }
  .v-head h2 { font-size: 21px; }
}

@media (max-width: 767px) {
  .viewer { padding: 0; align-items: end; }
  .viewer-card { flex-direction: column; width: 100%; max-height: 94dvh; border-radius: 26px 26px 0 0; overflow-y: auto; }
  .viewer-img img { max-height: 62dvh; }
  .viewer-info { padding: 20px 20px calc(24px + env(safe-area-inset-bottom)); min-width: 0; }
  .viewer-info h2 { font-size: 24px; }
  .viewer-nav { top: 30dvh; width: 40px; height: 40px; font-size: 26px; }
  .viewer-nav.prev { left: 8px; } .viewer-nav.next { right: 8px; }
}
