/*
 * Studio invitations, Cultural Wedding Collections: scripts beyond Devanagari (Gurmukhi, Gujarati,
 * Bengali, Urdu, Malayalam, Tamil), the cultural openings, card shapes, the magazine and postcard
 * covers and more floating decorations. As in studio.css, everything that moves animates transform,
 * opacity or clip-path(inset) only, so the link, the MP4 video and the PDF show the same motion.
 */

/* ---------- Scripts: only the chosen language(s) show ---------- */
body.st:not([data-lang*='pa']) [data-l='pa'], body.st:not([data-lang*='gu']) [data-l='gu'], body.st:not([data-lang*='bn']) [data-l='bn'],
body.st:not([data-lang*='ur']) [data-l='ur'], body.st:not([data-lang*='ml']) [data-l='ml'], body.st:not([data-lang*='ta']) [data-l='ta'] { display: none !important; }

/* Each script's text and heading fonts (the editor sets the variables). */
.st [data-l='pa'] { font-family: var(--st-body-pa); } .st :is(.st-h, .st-s) [data-l='pa'] { font-family: var(--st-head-pa); }
.st [data-l='gu'] { font-family: var(--st-body-gu); } .st :is(.st-h, .st-s) [data-l='gu'] { font-family: var(--st-head-gu); }
.st [data-l='bn'] { font-family: var(--st-body-bn); } .st :is(.st-h, .st-s) [data-l='bn'] { font-family: var(--st-head-bn); }
.st [data-l='ur'] { font-family: var(--st-body-ur); } .st :is(.st-h, .st-s) [data-l='ur'] { font-family: var(--st-head-ur); }
.st [data-l='ml'] { font-family: var(--st-body-ml); } .st :is(.st-h, .st-s) [data-l='ml'] { font-family: var(--st-head-ml); }
.st [data-l='ta'] { font-family: var(--st-body-ta); } .st :is(.st-h, .st-s) [data-l='ta'] { font-family: var(--st-head-ta); }
.st :is(.st-btn, .st-op-hint, .st-b) [data-l='pa'] { font-family: var(--st-body-pa); }
.st :is(.st-btn, .st-op-hint, .st-b) [data-l='gu'] { font-family: var(--st-body-gu); }
.st :is(.st-btn, .st-op-hint, .st-b) [data-l='bn'] { font-family: var(--st-body-bn); }
.st :is(.st-btn, .st-op-hint, .st-b) [data-l='ur'] { font-family: var(--st-body-ur); }
.st :is(.st-btn, .st-op-hint, .st-b) [data-l='ml'] { font-family: var(--st-body-ml); }
.st :is(.st-btn, .st-op-hint, .st-b) [data-l='ta'] { font-family: var(--st-body-ta); }
.st .st-op-hint [data-l]:not([data-l='en']) { font-size: .95rem; letter-spacing: .02em; }
/* Urdu reads right to left; Nastaliq needs tall lines. */
.st [data-l='ur'] { direction: rtl; unicode-bidi: isolate; line-height: 2.05; }
.st :is(.st-h, .st-s) [data-l='ur'] { line-height: 1.95; }
.st :is(.st-names, .st-person-name, .st-event-title, .st-thanks-names, .st-op-names) [data-l='ur'] { font-size: .66em; line-height: 1.9; }
.st .st-heading [data-l='ur'] { font-size: .74em; }
.st.st-align-left[data-lang^='ur'] .st-body { text-align: right; }
/* Malayalam and Tamil words run long: headings sit a little smaller. */
.st :is(.st-names, .st-person-name, .st-event-title, .st-op-names, .st-thanks-names) :is([data-l='ml'], [data-l='ta']) { font-size: .66em; line-height: 1.5; }
.st .st-heading :is([data-l='ml'], [data-l='ta']) { font-size: .7em; }
.st .st-sch-name :is([data-l='ml'], [data-l='ta']) { font-size: .64em; }
/* A line of Arabic calligraphy (Bismillah) above a Nikah invitation. */
.st .st-calligraphy { display: block; margin: 0 0 8px; font-family: 'Aref Ruqaa', 'Amiri', serif; font-size: 1.6rem; line-height: 1.5; direction: rtl; color: var(--st-accent); }

/* ---------- Card shapes ---------- */
.st.st-surface-card.st-card-arch .st-card:not(.st-cover-card) { border-radius: 999px 999px var(--st-radius) var(--st-radius) / 150px 150px var(--st-radius) var(--st-radius); padding-top: 58px; }
.st.st-surface-card.st-card-arch .st-card:not(.st-cover-card)::before { border-radius: 999px 999px calc(var(--st-radius) - 6px) calc(var(--st-radius) - 6px) / 144px 144px calc(var(--st-radius) - 6px) calc(var(--st-radius) - 6px); }
.st.st-surface-card.st-card-ticket .st-card:not(.st-cover-card) {
    border-radius: 12px; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--st-orn) 35%, transparent);
    -webkit-mask: radial-gradient(circle 14px at 0 64%, #0000 97%, #000) left / 51% 100% no-repeat, radial-gradient(circle 14px at 100% 64%, #0000 97%, #000) right / 51% 100% no-repeat;
    mask: radial-gradient(circle 14px at 0 64%, #0000 97%, #000) left / 51% 100% no-repeat, radial-gradient(circle 14px at 100% 64%, #0000 97%, #000) right / 51% 100% no-repeat;
}
.st.st-surface-card.st-card-ticket .st-card:not(.st-cover-card)::before { border-style: dashed; }
.st.st-surface-card.st-card-ticket .st-card:not(.st-cover-card)::after { content: ''; position: absolute; left: 18px; right: 18px; top: 64%; border-top: 2px dashed color-mix(in srgb, var(--st-orn) 55%, transparent); pointer-events: none; }
.st.st-surface-card:is(.st-card-stamp, .st-card-scallop) .st-card:not(.st-cover-card) { --r: 7px; border-radius: 0; box-shadow: none; }
.st.st-surface-card.st-card-stamp .st-card:not(.st-cover-card) {
    -webkit-mask: radial-gradient(var(--r), #0000 97%, #000) round calc(-1.5 * var(--r)) calc(-1.5 * var(--r)) / calc(3 * var(--r)) calc(3 * var(--r)), linear-gradient(#000 0 0) no-repeat 50% / calc(100% - 3 * var(--r)) calc(100% - 3 * var(--r));
    mask: radial-gradient(var(--r), #0000 97%, #000) round calc(-1.5 * var(--r)) calc(-1.5 * var(--r)) / calc(3 * var(--r)) calc(3 * var(--r)), linear-gradient(#000 0 0) no-repeat 50% / calc(100% - 3 * var(--r)) calc(100% - 3 * var(--r));
}
.st.st-surface-card.st-card-scallop .st-card:not(.st-cover-card) {
    --r: 9px;
    -webkit-mask: radial-gradient(var(--r), #000 97%, #0000) round calc(-1 * var(--r)) calc(-1 * var(--r)) / calc(2 * var(--r)) calc(2 * var(--r)), linear-gradient(#000 0 0) no-repeat 50% / calc(100% - 2 * var(--r)) calc(100% - 2 * var(--r));
    mask: radial-gradient(var(--r), #000 97%, #0000) round calc(-1 * var(--r)) calc(-1 * var(--r)) / calc(2 * var(--r)) calc(2 * var(--r)), linear-gradient(#000 0 0) no-repeat 50% / calc(100% - 2 * var(--r)) calc(100% - 2 * var(--r));
}
.st.st-surface-card:is(.st-card-stamp, .st-card-scallop) .st-card:not(.st-cover-card)::before { inset: 16px; border-radius: 2px; }
.st.st-surface-card.st-card-square .st-card:not(.st-cover-card) { border-radius: 0; }
.st.st-surface-card.st-card-square .st-card:not(.st-cover-card)::before { inset: 8px; border: 3px double color-mix(in srgb, var(--st-orn) 70%, transparent); border-radius: 0; }

/* ---------- Cover: magazine ---------- */
.st.st-hero-magazine .st-cover-photo { display: block; position: absolute; inset: 0; z-index: 2; overflow: hidden; }
.st.st-hero-magazine .st-cover-photo .st-photo { width: 100%; height: 100%; object-fit: cover; }
.st.st-hero-magazine .st-cover-photo::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, color-mix(in srgb, var(--st-bg) 70%, transparent), transparent 26%, transparent 48%, color-mix(in srgb, var(--st-bg) 88%, transparent) 78%, var(--st-bg)); }
.st.st-hero-magazine .st-cover { justify-content: space-between; padding: 26px 18px 44px; }
.st.st-hero-magazine .st-cover .st-body { max-width: none; flex: 1; display: flex; }
.st.st-hero-magazine .st-cover-card { flex: 1; display: flex; flex-direction: column; padding: 0 !important; background: transparent !important; box-shadow: none !important; --st-head: var(--st-bg-head); --st-ink: var(--st-bg-ink); color: var(--st-ink); }
.st.st-hero-magazine .st-cover-card::before { display: none; }
.st.st-hero-magazine .st-eyebrow { order: -2; margin: 0; font-size: 3.3rem; line-height: .92; letter-spacing: -.01em; color: var(--st-bg-head); }
.st.st-hero-magazine .st-eyebrow [data-l]:not([data-l='en']) { font-size: .62em; line-height: 1.3; }
.st.st-hero-magazine .st-kicker { order: -1; margin: 10px 0 0; padding: 6px 0; border-top: 1px solid var(--st-line); border-bottom: 1px solid var(--st-line); font-size: .66rem; letter-spacing: .34em; }
.st.st-hero-magazine .st-names { margin-top: auto; font-size: 3rem; text-align: left; }
.st.st-hero-magazine .st-names > span { display: block; }
.st.st-hero-magazine .st-cover .st-div, .st.st-hero-magazine .st-cover .st-art, .st.st-hero-magazine .st-cover .st-frame { display: none; }
.st.st-hero-magazine .st-date { text-align: left; font-size: .86rem; letter-spacing: .28em; }
.st.st-hero-magazine .st-line { text-align: left; font-size: .95rem; max-width: 300px; }

/* ---------- Cover: postcard ---------- */
.st.st-hero-postcard .st-cover-photo { display: block; position: relative; z-index: 4; width: 296px; height: 206px; margin: 0 auto -30px; border: 9px solid #fffdf7; border-bottom-width: 9px; box-shadow: 0 18px 40px rgba(0, 0, 0, .3); transform: rotate(-3deg); overflow: hidden; }
.st.st-hero-postcard .st-cover-photo .st-photo { width: 100%; height: 100%; object-fit: cover; }
.st.st-hero-postcard .st-cover .st-body { margin-top: 0; }
.st.st-hero-postcard .st-cover-card { padding: 52px 26px 30px; background: #fffdf7 !important; color: #3a3226; --st-head: color-mix(in srgb, var(--st-head) 85%, #000); border-radius: 4px !important; transform: rotate(1.2deg); }
.st.st-hero-postcard .st-cover-card::before { inset: 10px; border: 1.5px dashed color-mix(in srgb, var(--st-accent) 55%, transparent); border-radius: 2px; }
.st.st-hero-postcard .st-medal { display: grid; place-items: center; position: absolute; top: -22px; right: 14px; width: 78px; height: 92px; margin: 0; background: var(--st-surface); box-shadow: 0 6px 14px rgba(0, 0, 0, .2); transform: rotate(6deg);
    -webkit-mask: radial-gradient(4px, #0000 97%, #000) round -6px -6px / 12px 12px, linear-gradient(#000 0 0) no-repeat 50% / calc(100% - 12px) calc(100% - 12px);
    mask: radial-gradient(4px, #0000 97%, #000) round -6px -6px / 12px 12px, linear-gradient(#000 0 0) no-repeat 50% / calc(100% - 12px) calc(100% - 12px); }
.st.st-hero-postcard .st-medal .st-orn { position: absolute; inset: 10px; }
.st.st-hero-postcard .st-medal .st-medal-art { width: 58%; height: 58%; }
.st.st-hero-postcard .st-medal .st-mono { font-size: 1.5rem; }
.st.st-hero-postcard .st-cover-card::after { content: ''; position: absolute; top: 18px; right: 70px; width: 70px; height: 70px; border-radius: 50%; border: 2px solid color-mix(in srgb, var(--st-accent) 50%, transparent); box-shadow: inset 0 0 0 6px transparent, inset 0 0 0 7px color-mix(in srgb, var(--st-accent) 35%, transparent); pointer-events: none; }
.st.st-hero-postcard .st-kicker { text-align: left; }
.st.st-hero-postcard .st-cover .st-art:not(.st-front) { opacity: .5; }

/* ======================================================================
   Cultural openings. Same contract as studio.css: #door-overlay.open on the link,
   --door-start and --door-dur in the video.
   ====================================================================== */
.st.st-open-drape .st-op-drape, .st.st-open-window .st-op-window, .st.st-open-pearls .st-op-pearls, .st.st-open-slide .st-op-slide,
.st.st-open-emblem .st-op-emblem, .st.st-open-cathedral .st-op-cathedral, .st.st-open-kolam .st-op-kolam, .st.st-open-paan .st-op-paan,
.st.st-open-leaves .st-op-leaves, .st.st-open-mist .st-op-mist, .st.st-open-tiles .st-op-tiles, .st.st-open-vilakku .st-op-vilakku,
.st.st-open-stamp .st-op-stamp, .st.st-open-portal .st-op-portal, .st.st-open-editorial .st-op-editorial { display: block; }
/* A centred label on a panel, for openings that fill the screen with pattern. */
.st.st-open-tiles .st-op-label, .st.st-open-stamp .st-op-label { top: 33%; bottom: auto; left: 30px; right: 30px; padding: 26px 16px 22px; border-radius: 6px; background: var(--st-surface); box-shadow: 0 20px 50px rgba(0, 0, 0, .35), inset 0 0 0 6px var(--st-surface), inset 0 0 0 7px var(--st-line); color: var(--st-head); }

/* Embroidered veil (phulkari, bandhani, kasavu) */
.st.st-open-drape #door-overlay { --op-out: 1.55s; }
.st .st-drape { position: absolute; left: -6%; right: -6%; top: -2%; bottom: 0; transform-origin: 50% 0; }
.st .st-drape-cloth { position: absolute; inset: 0 0 52px; background-color: var(--st-drape, var(--st-accent)); background-image: var(--st-pattern, none), linear-gradient(180deg, rgba(255, 255, 255, .1), transparent 30%, rgba(0, 0, 0, .28)); background-size: 76px 76px, auto; }
.st .st-drape-cloth::after { content: ''; position: absolute; inset: 0; background: repeating-linear-gradient(90deg, rgba(0, 0, 0, .16) 0, transparent 6%, rgba(255, 255, 255, .08) 12%, transparent 18%); }
.st .st-drape-band { position: absolute; left: 0; right: 0; bottom: 22px; height: 32px; padding: 3px 0; color: var(--st-orn); background: color-mix(in srgb, var(--st-drape, var(--st-accent)) 72%, #000); box-shadow: 0 -2px 0 var(--st-orn), 0 2px 0 var(--st-orn); }
.st .st-drape-tassels { position: absolute; left: 0; right: 0; bottom: 0; height: 24px; background: radial-gradient(circle at 50% 70%, var(--st-orn) 0 4.5px, transparent 5px) 0 0 / 26px 24px repeat-x, linear-gradient(90deg, transparent 12px, color-mix(in srgb, var(--st-orn) 80%, #000) 12px 14px, transparent 14px) 0 0 / 26px 16px repeat-x; }
.st .st-drape-art { position: absolute; left: 50%; top: 14%; width: 72%; translate: -50% 0; opacity: .95; }
.st.st-open-drape .st-op-label { top: 52%; bottom: auto; color: var(--st-op-ink, #fff); text-shadow: 0 2px 12px rgba(0, 0, 0, .5); }
.st.st-open-drape .st-op-label :is(.st-op-kicker, .st-op-hint) { color: var(--st-orn); }
@keyframes st-drape-idle { 0%, 100% { transform: rotate(-.5deg); } 50% { transform: rotate(.5deg); } }
@keyframes st-drape-lift { 0% { transform: none; } 28% { transform: translateY(-4%) rotate(-1.2deg) scaleY(.98); } 100% { transform: translateY(-115%) rotate(3deg) scaleY(.82); } }
.st #door-overlay:not(.open) .st-drape { animation: st-drape-idle 5s ease-in-out infinite; }
.st #door-overlay.open .st-drape { animation: st-drape-lift 1.8s cubic-bezier(.6, .05, .3, 1) both; }
html.sb-film .st .st-drape { animation: st-drape-lift calc(var(--door-dur) * .6) cubic-bezier(.6, .05, .3, 1) var(--door-start) both; }

/* Window shutters (jharokha, Goan louvres) */
.st.st-open-window #door-overlay { --op-out: 1.95s; }
.st .st-op-window { background: radial-gradient(110% 70% at 50% 40%, color-mix(in srgb, var(--st-bg) 80%, #fff), var(--st-bg) 75%); }
.st .st-win { position: absolute; left: 50%; top: 43%; width: 300px; height: 470px; margin: -235px 0 0 -150px; perspective: 1200px; }
.st .st-win-light { position: absolute; inset: 62px 18px 10px; border-radius: 50% 50% 4px 4px / 30% 30% 4px 4px; background: radial-gradient(circle at 50% 42%, #fffaf0, color-mix(in srgb, var(--st-orn) 45%, #fff) 45%, color-mix(in srgb, var(--st-surface) 60%, var(--st-orn)) 85%); opacity: .25; }
.st .st-win-shutters { position: absolute; inset: 62px 18px 10px; display: flex; }
.st .st-shutter { position: relative; width: 50%; height: 100%; overflow: hidden; color: var(--st-orn); background: linear-gradient(90deg, color-mix(in srgb, var(--st-shutter, var(--st-accent)) 80%, #000), var(--st-shutter, var(--st-accent)) 40%, color-mix(in srgb, var(--st-shutter, var(--st-accent)) 85%, #000)); box-shadow: inset 0 0 26px rgba(0, 0, 0, .35); }
.st .st-shutter-l { transform-origin: left center; border-top-left-radius: 100% 30%; }
.st .st-shutter-r { transform-origin: right center; border-top-right-radius: 100% 30%; }
.st .st-shutter .st-orn { position: absolute; inset: 0; }
.st .st-shutter-r .st-orn { transform: scaleX(-1); }
.st .st-win-frame { position: absolute; inset: -6px -22px -14px; color: var(--st-orn); pointer-events: none; filter: drop-shadow(0 8px 16px rgba(0, 0, 0, .3)); }
.st.st-open-window .st-op-label { bottom: 3.5%; }
@keyframes st-shut-l { 0% { transform: none; opacity: 1; } 75% { opacity: 1; } 100% { transform: rotateY(-108deg); opacity: 0; } }
@keyframes st-shut-r { 0% { transform: none; opacity: 1; } 75% { opacity: 1; } 100% { transform: rotateY(108deg); opacity: 0; } }
@keyframes st-win-glow { from { opacity: .25; } to { opacity: 1; } }
@keyframes st-zoom-through { 0% { transform: none; opacity: 1; } 100% { transform: scale(2.6); opacity: 0; } }
.st #door-overlay.open .st-shutter-l { animation: st-shut-l 1.4s cubic-bezier(.45, .05, .35, 1) .05s both; }
.st #door-overlay.open .st-shutter-r { animation: st-shut-r 1.4s cubic-bezier(.45, .05, .35, 1) .12s both; }
.st #door-overlay.open .st-win-light { animation: st-win-glow .9s ease .4s both; }
.st #door-overlay.open .st-win { animation: st-zoom-through 1s cubic-bezier(.5, 0, .7, .4) 1.15s both; }
html.sb-film .st .st-shutter-l { animation: st-shut-l 1.4s cubic-bezier(.45, .05, .35, 1) calc(var(--door-start) + .05s) both; }
html.sb-film .st .st-shutter-r { animation: st-shut-r 1.4s cubic-bezier(.45, .05, .35, 1) calc(var(--door-start) + .12s) both; }
html.sb-film .st .st-win-light { animation: st-win-glow .9s ease calc(var(--door-start) + .4s) both; }
html.sb-film .st .st-win { animation: st-zoom-through 1s cubic-bezier(.5, 0, .7, .4) calc(var(--door-start) + 1.15s) both; }

/* Pearl strings (mundavalya) */
.st.st-open-pearls #door-overlay { --op-out: 1.45s; }
.st .st-pearl-bar { position: absolute; z-index: 3; left: -2%; right: -2%; top: 0; height: 30px; color: color-mix(in srgb, var(--st-orn) 40%, #000); background: linear-gradient(180deg, color-mix(in srgb, var(--st-orn) 55%, #fff), var(--st-orn) 55%, color-mix(in srgb, var(--st-orn) 65%, #000)); box-shadow: 0 6px 16px rgba(0, 0, 0, .35); }
.st .st-pearl-bar .st-orn { position: absolute; inset: 2px 0; }
.st .st-strand { position: absolute; z-index: 2; top: 24px; left: var(--x); width: 14px; height: var(--len); margin-left: -7px; transform-origin: 50% 0;
    background: radial-gradient(circle at 42% 36%, #fff 0 1.4px, #f6f1e6 2.6px, #d9cfbb 5.3px, rgba(0, 0, 0, .18) 6.2px, transparent 6.8px) 50% 0 / 14px 14.5px repeat-y; }
.st .st-strand::after { content: ''; position: absolute; left: 50%; bottom: -16px; width: 13px; height: 19px; margin-left: -6.5px; border-radius: 50% 50% 50% 50% / 62% 62% 38% 38%; background: radial-gradient(circle at 40% 32%, #fff6cc, var(--st-orn) 55%, color-mix(in srgb, var(--st-orn) 60%, #000)); }
.st .st-pearl-seal { position: absolute; z-index: 4; left: 50%; top: 42%; width: 136px; height: 136px; margin: -68px 0 0 -68px; display: grid; place-items: center; border-radius: 50%; color: var(--st-head); background: radial-gradient(circle, var(--st-surface), color-mix(in srgb, var(--st-surface) 80%, var(--st-orn))); box-shadow: 0 14px 34px rgba(0, 0, 0, .4), 0 0 0 3px var(--st-orn); }
.st .st-pearl-seal .st-orn { position: absolute; inset: 6px; }
.st .st-pearl-seal .st-s { position: relative; font-size: 2rem; }
.st.st-open-pearls .st-op-label { bottom: 6%; }
@keyframes st-strand-sway { 0%, 100% { transform: rotate(-1.2deg); } 50% { transform: rotate(1.2deg); } }
@keyframes st-strand-part { 0% { transform: none; opacity: 1; } 70% { opacity: 1; } 100% { transform: translateX(calc(var(--side) * 230px)) rotate(calc(var(--side) * 16deg)); opacity: 0; } }
.st #door-overlay:not(.open) .st-strand { animation: st-strand-sway 4.6s ease-in-out calc(var(--n) * -.37s) infinite; }
.st #door-overlay.open .st-strand { animation: st-strand-part 1.25s cubic-bezier(.5, .05, .4, 1) calc(.25s + var(--d)) both; }
.st #door-overlay.open .st-pearl-seal { animation: st-seal-away .55s ease both; }
html.sb-film .st .st-strand { animation: st-strand-part 1.25s cubic-bezier(.5, .05, .4, 1) calc(var(--door-start) + .25s + var(--d)) both; }
html.sb-film .st .st-pearl-seal { animation: st-seal-away .55s ease var(--door-start) both; }

/* Sliding lattice screens (jaali, art deco) */
.st.st-open-slide #door-overlay { --op-out: 1.4s; }
.st .st-screen { position: absolute; top: 0; bottom: 0; width: 50.6%; overflow: hidden; color: var(--st-orn); background: radial-gradient(120% 80% at 50% 50%, color-mix(in srgb, var(--st-screen, var(--st-bg)) 88%, #fff), var(--st-screen, var(--st-bg)) 70%); box-shadow: inset 0 0 70px rgba(0, 0, 0, .45); }
.st .st-screen-l { left: 0; border-right: 2px solid var(--st-line); } .st .st-screen-r { right: 0; border-left: 2px solid var(--st-line); }
.st .st-screen .st-orn { position: absolute; inset: 0; opacity: .9; }
.st .st-screen-seal { position: absolute; z-index: 4; left: 50%; top: 40%; width: 140px; height: 140px; margin: -70px 0 0 -70px; display: grid; place-items: center; border-radius: 50%; color: var(--st-head); background: radial-gradient(circle, var(--st-surface), color-mix(in srgb, var(--st-surface) 80%, var(--st-orn))); box-shadow: 0 14px 40px rgba(0, 0, 0, .45), 0 0 0 3px var(--st-orn); }
.st .st-screen-seal .st-orn { position: absolute; inset: 6px; }
.st .st-screen-seal .st-s { position: relative; font-size: 2rem; }
.st.st-open-slide .st-op-label { bottom: 10%; }
@keyframes st-slide-l { from { transform: none; } to { transform: translateX(-102%); } }
@keyframes st-slide-r { from { transform: none; } to { transform: translateX(102%); } }
.st #door-overlay.open .st-screen-seal { animation: st-seal-away .5s ease both; }
.st #door-overlay.open .st-screen-l { animation: st-slide-l 1.25s cubic-bezier(.7, 0, .25, 1) .25s both; }
.st #door-overlay.open .st-screen-r { animation: st-slide-r 1.25s cubic-bezier(.7, 0, .25, 1) .25s both; }
html.sb-film .st .st-screen-seal { animation: st-seal-away .5s ease var(--door-start) both; }
html.sb-film .st .st-screen-l { animation: st-slide-l 1.25s cubic-bezier(.7, 0, .25, 1) calc(var(--door-start) + .25s) both; }
html.sb-film .st .st-screen-r { animation: st-slide-r 1.25s cubic-bezier(.7, 0, .25, 1) calc(var(--door-start) + .25s) both; }

/* Emblem glowing (crescent, dhol, Dhamma chakra, topor, nettipattam, garbo) */
.st.st-open-emblem #door-overlay { --op-out: 1.85s; }
.st .st-op-emblem { background: radial-gradient(100% 70% at 50% 40%, color-mix(in srgb, var(--st-bg) 78%, #fff), var(--st-bg) 72%); }
.st .st-emb-rays { position: absolute; left: 50%; top: 40%; width: 560px; height: 560px; margin: -280px 0 0 -280px; opacity: .5;
    background: repeating-conic-gradient(from 0deg, color-mix(in srgb, var(--st-orn) 30%, transparent) 0 5deg, transparent 5deg 15deg);
    -webkit-mask: radial-gradient(circle, #000 14%, transparent 60%); mask: radial-gradient(circle, #000 14%, transparent 60%); animation: st-spin 80s linear infinite; }
.st .st-emb-ring { position: absolute; left: 50%; top: 40%; width: 200px; height: 200px; margin: -100px 0 0 -100px; border-radius: 50%; border: 1.5px solid var(--st-orn); opacity: 0; }
.st .st-emb { position: absolute; z-index: 3; left: 50%; top: 40%; width: 190px; height: 190px; margin: -95px 0 0 -95px; display: grid; place-items: center; color: var(--st-orn); }
.st .st-emb > .st-orn { position: absolute; inset: 0; }
.st .st-emb .st-medal-art { position: relative; width: 60%; height: 60%; }
.st .st-emb .st-s { position: relative; font-size: 2.6rem; color: var(--st-bg-head); }
.st .st-emb-art { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 12px 26px rgba(0, 0, 0, .35)); }
.st .st-emb-sparks i { position: absolute; left: calc(50% + var(--x)); top: calc(40% + var(--y)); width: 14px; height: 14px; margin: -7px 0 0 -7px; background: url('art/p-sparkle.svg') center / contain no-repeat; opacity: 0; animation: st-twinkle 2.8s ease-in-out calc(var(--n) * .31s) infinite; }
.st .st-op-emblem .st-bloom { top: 40%; }
.st.st-open-emblem .st-op-label { bottom: 9%; }
@keyframes st-emb-pulse { 0% { opacity: .7; transform: scale(.85); } 100% { opacity: 0; transform: scale(1.9); } }
@keyframes st-emb-beat { 0%, 46%, 100% { transform: scale(1); } 8% { transform: scale(1.09) rotate(-2deg); } 16% { transform: scale(.98); } 26% { transform: scale(1.06) rotate(2deg); } 34% { transform: scale(1); } }
@keyframes st-emb-sway { 0%, 100% { transform: rotate(-7deg); } 50% { transform: rotate(7deg); } }
@keyframes st-emb-rise { 0% { opacity: 0; transform: translateY(40px) scale(.6); } 25% { opacity: 1; } 100% { opacity: 0; transform: translateY(-120px) scale(1); } }
@keyframes st-emb-open { 0% { transform: none; opacity: 1; } 22% { transform: scale(1.14); opacity: 1; } 100% { transform: scale(2.6); opacity: 0; } }
@keyframes st-rays-out { from { opacity: .5; transform: none; } to { opacity: 0; transform: scale(2.2) rotate(40deg); } }
.st #door-overlay:not(.open) .st-emb-ring { animation: st-emb-pulse 3s ease-out calc(var(--n, 0) * 1s) infinite; }
.st #door-overlay:not(.open) .st-emb-glow .st-emb, .st #door-overlay:not(.open) .st-emb-rise .st-emb { animation: st-pulse 4s ease-in-out infinite; }
.st #door-overlay:not(.open) .st-emb-beat .st-emb { animation: st-emb-beat 1.3s ease-in-out infinite; }
.st #door-overlay:not(.open) .st-emb-beat .st-emb-ring { animation-duration: 1.3s; }
.st #door-overlay:not(.open) .st-emb-spin .st-emb > * { animation: st-spin 26s linear infinite; }
.st #door-overlay:not(.open) .st-emb-sway .st-emb { transform-origin: 50% 0; animation: st-emb-sway 2.6s ease-in-out infinite; }
.st .st-emb-rise .st-emb-sparks i { left: calc(50% + var(--x) * .35); top: calc(40% + 50px); animation-name: st-emb-rise; animation-duration: 3.2s; animation-timing-function: ease-in; }
.st #door-overlay.open .st-emb { animation: st-emb-open 1.4s cubic-bezier(.4, 0, .3, 1) both; }
.st #door-overlay.open .st-emb-rays { animation: st-rays-out 1.6s ease-in .2s both; }
.st #door-overlay.open .st-op-emblem .st-bloom { animation: st-bloom 1.5s cubic-bezier(.5, 0, .3, 1) .5s both; }
html.sb-film .st .st-emb { animation: st-emb-open 1.4s cubic-bezier(.4, 0, .3, 1) var(--door-start) both; }
html.sb-film .st .st-emb-rays { animation: st-rays-out 1.6s ease-in calc(var(--door-start) + .2s) both; }
html.sb-film .st .st-op-emblem .st-bloom { animation: st-bloom 1.5s cubic-bezier(.5, 0, .3, 1) calc(var(--door-start) + .5s) both; }

/* Cathedral doors */
.st.st-open-cathedral #door-overlay { --op-out: 2s; }
.st .st-op-cathedral { background: radial-gradient(110% 70% at 50% 42%, color-mix(in srgb, var(--st-bg) 82%, #fff), color-mix(in srgb, var(--st-bg) 85%, #000) 80%); }
.st .st-cath-light, .st .st-cath-doors { position: absolute; left: 50%; top: 46%; width: 270px; height: 430px; margin: -200px 0 0 -135px; }
.st .st-cath-light { border-radius: 135px 135px 4px 4px / 120px 120px 4px 4px; background: radial-gradient(70% 45% at 50% 30%, #fffdf5, color-mix(in srgb, var(--st-orn) 40%, #fff) 50%, color-mix(in srgb, var(--st-orn) 35%, var(--st-surface)) 90%); box-shadow: 0 0 90px color-mix(in srgb, var(--st-orn) 55%, transparent); }
.st .st-cath-doors { display: flex; perspective: 1100px; }
.st .st-cath-door { position: relative; width: 50%; height: 100%; overflow: hidden; color: color-mix(in srgb, var(--st-orn) 80%, #000); background: linear-gradient(90deg, color-mix(in srgb, var(--st-door, #5a3a26) 80%, #000), var(--st-door, #5a3a26) 45%, color-mix(in srgb, var(--st-door, #5a3a26) 85%, #000)); box-shadow: inset 0 0 30px rgba(0, 0, 0, .45); }
.st .st-cath-l { transform-origin: left center; border-top-left-radius: 100% 28%; }
.st .st-cath-r { transform-origin: right center; border-top-right-radius: 100% 28%; }
.st .st-cath-door .st-orn { position: absolute; inset: 0; }
.st .st-cath-r .st-orn { transform: scaleX(-1); }
.st .st-cath-arch { position: absolute; z-index: 2; left: 50%; top: 46%; width: 330px; height: 488px; margin: -258px 0 0 -165px; color: var(--st-orn); pointer-events: none; }
.st.st-open-cathedral .st-op-label { bottom: 3.5%; }
@keyframes st-cath-l { 0% { transform: none; opacity: 1; } 78% { opacity: 1; } 100% { transform: rotateY(-100deg); opacity: 0; } }
@keyframes st-cath-r { 0% { transform: none; opacity: 1; } 78% { opacity: 1; } 100% { transform: rotateY(100deg); opacity: 0; } }
@keyframes st-cath-glow { 0% { transform: none; opacity: 1; } 100% { transform: scale(3.4); opacity: 1; } }
.st #door-overlay.open .st-cath-l { animation: st-cath-l 1.8s cubic-bezier(.45, .05, .35, 1) both; }
.st #door-overlay.open .st-cath-r { animation: st-cath-r 1.8s cubic-bezier(.45, .05, .35, 1) .1s both; }
.st #door-overlay.open .st-cath-light { animation: st-cath-glow 1.2s ease-in 1.05s both; }
.st #door-overlay.open .st-cath-arch { animation: st-zoom-through 1s ease-in 1.05s both; }
html.sb-film .st .st-cath-l { animation: st-cath-l 1.8s cubic-bezier(.45, .05, .35, 1) var(--door-start) both; }
html.sb-film .st .st-cath-r { animation: st-cath-r 1.8s cubic-bezier(.45, .05, .35, 1) calc(var(--door-start) + .1s) both; }
html.sb-film .st .st-cath-light { animation: st-cath-glow 1.2s ease-in calc(var(--door-start) + 1.05s) both; }
html.sb-film .st .st-cath-arch { animation: st-zoom-through 1s ease-in calc(var(--door-start) + 1.05s) both; }

/* Kolam / alpana drawn ring by ring (recoloured with --st-kolam) */
.st.st-open-kolam #door-overlay { --op-out: 2.3s; }
.st .st-op-kolam { background: radial-gradient(100% 70% at 50% 42%, color-mix(in srgb, var(--st-bg) 85%, #fff), var(--st-bg) 75%); }
.st .st-kolam { position: absolute; left: 50%; top: 41%; width: 310px; height: 310px; margin: -155px 0 0 -155px; }
.st .st-kolam-ring, .st .st-kolam-dots { position: absolute; inset: 0; background: var(--st-kolam, var(--st-surface)); -webkit-mask: var(--src) center / contain no-repeat; mask: var(--src) center / contain no-repeat; }
.st .st-kolam-ring { opacity: 0; transform: scale(.82) rotate(-24deg); }
.st #door-overlay:not(.open) .st-kolam-ring:nth-of-type(2) { opacity: 1; transform: none; }
.st #door-overlay:not(.open) .st-kolam { animation: st-bud 4s ease-in-out infinite; }
.st.st-open-kolam .st-op-label { bottom: 7%; }
@keyframes st-kolam-draw { from { opacity: 0; transform: scale(.82) rotate(-24deg); } to { opacity: 1; transform: none; } }
@keyframes st-kolam-out { from { transform: none; opacity: 1; } to { transform: scale(2.8) rotate(20deg); opacity: 0; } }
.st #door-overlay.open .st-kolam-ring { animation: st-kolam-draw .55s cubic-bezier(.2, .8, .3, 1) calc(var(--n) * .32s) both; }
.st #door-overlay.open .st-kolam { animation: st-kolam-out 1s cubic-bezier(.5, 0, .7, .3) 1.35s both; }
html.sb-film .st .st-kolam-ring { animation: st-kolam-draw .55s cubic-bezier(.2, .8, .3, 1) calc(var(--door-start) + var(--n) * .32s) both; }
html.sb-film .st .st-kolam { animation: st-kolam-out 1s cubic-bezier(.5, 0, .7, .3) calc(var(--door-start) + 1.35s) both; }

/* Betel leaves (Shubho Drishti) */
.st.st-open-paan #door-overlay { --op-out: 1.45s; }
.st .st-paan-glow { position: absolute; left: 50%; top: 40%; width: 320px; margin: -160px 0 0 -160px; opacity: .4; transform: scale(.6); }
.st .st-paan { position: absolute; z-index: 2; left: 50%; top: 40%; width: 200px; margin-top: -170px; filter: drop-shadow(0 16px 24px rgba(0, 0, 0, .35)); }
.st .st-paan-l { margin-left: -172px; transform-origin: 50% 95%; transform: rotate(-9deg); }
.st .st-paan-r { margin-left: -28px; transform-origin: 50% 95%; transform: scaleX(-1) rotate(-9deg); }
.st.st-open-paan .st-op-label { bottom: 8%; }
@keyframes st-paan-l-idle { 0%, 100% { transform: rotate(-9deg); } 50% { transform: rotate(-7.5deg); } }
@keyframes st-paan-r-idle { 0%, 100% { transform: scaleX(-1) rotate(-9deg); } 50% { transform: scaleX(-1) rotate(-7.5deg); } }
@keyframes st-paan-l { from { transform: rotate(-9deg); opacity: 1; } to { transform: translate(-150px, 170px) rotate(-48deg); opacity: 0; } }
@keyframes st-paan-r { from { transform: scaleX(-1) rotate(-9deg); opacity: 1; } to { transform: translate(150px, 170px) scaleX(-1) rotate(-48deg); opacity: 0; } }
.st #door-overlay:not(.open) .st-paan-l { animation: st-paan-l-idle 3.4s ease-in-out infinite; }
.st #door-overlay:not(.open) .st-paan-r { animation: st-paan-r-idle 3.4s ease-in-out -.6s infinite; }
.st #door-overlay.open .st-paan-l { animation: st-paan-l 1.2s cubic-bezier(.5, .05, .4, 1) .1s both; }
.st #door-overlay.open .st-paan-r { animation: st-paan-r 1.2s cubic-bezier(.5, .05, .4, 1) .1s both; }
.st #door-overlay.open .st-paan-glow { animation: st-glow-big 1.4s ease-in .4s both; }
html.sb-film .st .st-paan-l { animation: st-paan-l 1.2s cubic-bezier(.5, .05, .4, 1) calc(var(--door-start) + .1s) both; }
html.sb-film .st .st-paan-r { animation: st-paan-r 1.2s cubic-bezier(.5, .05, .4, 1) calc(var(--door-start) + .1s) both; }
html.sb-film .st .st-paan-glow { animation: st-glow-big 1.4s ease-in calc(var(--door-start) + .4s) both; }

/* Leaves in the wind (chinar, bodhi) */
.st.st-open-leaves #door-overlay { --op-out: 1.45s; }
.st .st-op-leaves { background: radial-gradient(100% 70% at 50% 40%, color-mix(in srgb, var(--st-bg) 75%, #fff), var(--st-bg) 75%); }
.st .st-gust { position: absolute; left: var(--x); top: var(--y); width: calc(118px * var(--s)); margin: calc(-59px * var(--s)) 0 0 calc(-59px * var(--s)); transform: rotate(var(--r)); filter: drop-shadow(0 6px 8px rgba(0, 0, 0, .22)); }
.st.st-open-leaves .st-op-label { top: 30%; bottom: auto; padding: 22px 26px; background: radial-gradient(closest-side, color-mix(in srgb, var(--st-bg) 92%, transparent) 55%, transparent); }
@keyframes st-gust-idle { 0%, 100% { transform: rotate(var(--r)); } 50% { transform: rotate(calc(var(--r) + 5deg)) translateY(-3px); } }
@keyframes st-gust-away { from { transform: rotate(var(--r)); opacity: 1; } to { transform: translate(calc(380px + var(--n) * 8px), calc(-240px - var(--n) * 9px)) rotate(calc(var(--r) + 240deg)); opacity: 0; } }
.st #door-overlay:not(.open) .st-gust { animation: st-gust-idle 3.8s ease-in-out calc(var(--n) * -.29s) infinite; }
.st #door-overlay.open .st-gust { animation: st-gust-away 1.35s cubic-bezier(.5, 0, .8, .3) calc(var(--n) * .035s) both; }
html.sb-film .st .st-gust { animation: st-gust-away 1.35s cubic-bezier(.5, 0, .8, .3) calc(var(--door-start) + var(--n) * .035s) both; }

/* Morning mist over the valley */
.st.st-open-mist #door-overlay { --op-out: 1.85s; }
.st .st-op-mist { background: linear-gradient(180deg, color-mix(in srgb, var(--st-bg) 55%, #fff) 0%, color-mix(in srgb, var(--st-bg) 85%, #fff) 55%, var(--st-bg) 100%); }
.st .st-mist-sun { position: absolute; left: 50%; top: 26%; width: 170px; height: 170px; margin: -85px 0 0 -85px; border-radius: 50%; background: radial-gradient(circle, #fffaf0 0 30%, color-mix(in srgb, var(--st-orn) 40%, #fff) 48%, transparent 70%); }
.st .st-mist-hills { position: absolute; left: 0; bottom: 18%; width: 100%; }
.st .st-mist { position: absolute; left: -30%; width: 160%; }
.st .st-mist-1 { top: 34%; } .st .st-mist-2 { top: 50%; opacity: .9; } .st .st-mist-3 { top: 64%; }
.st.st-open-mist .st-op-label { bottom: 9%; }
@keyframes st-mist-drift { 0%, 100% { transform: translateX(-14px); } 50% { transform: translateX(14px); } }
@keyframes st-mist-l { from { transform: none; opacity: 1; } to { transform: translateX(-62%); opacity: 0; } }
@keyframes st-mist-r { from { transform: none; opacity: 1; } to { transform: translateX(62%); opacity: 0; } }
@keyframes st-sun-up { from { transform: none; } to { transform: translateY(-30px) scale(3.2); } }
.st #door-overlay:not(.open) .st-mist { animation: st-mist-drift 9s ease-in-out infinite; }
.st #door-overlay:not(.open) .st-mist-2 { animation-delay: -4s; }
.st #door-overlay.open .st-mist-1, .st #door-overlay.open .st-mist-3 { animation: st-mist-l 1.7s cubic-bezier(.45, .05, .35, 1) both; }
.st #door-overlay.open .st-mist-2 { animation: st-mist-r 1.7s cubic-bezier(.45, .05, .35, 1) .08s both; }
.st #door-overlay.open .st-mist-sun { animation: st-sun-up 1.7s ease-in .3s both; }
.st #door-overlay.open .st-mist-hills { animation: st-fade-out 1.2s ease .7s both; }
html.sb-film .st .st-mist-1, html.sb-film .st .st-mist-3 { animation: st-mist-l 1.7s cubic-bezier(.45, .05, .35, 1) var(--door-start) both; }
html.sb-film .st .st-mist-2 { animation: st-mist-r 1.7s cubic-bezier(.45, .05, .35, 1) calc(var(--door-start) + .08s) both; }
html.sb-film .st .st-mist-sun { animation: st-sun-up 1.7s ease-in calc(var(--door-start) + .3s) both; }
html.sb-film .st .st-mist-hills { animation: st-fade-out 1.2s ease calc(var(--door-start) + .7s) both; }

/* Tiles turning (azulejo, ralli patchwork) */
.st.st-open-tiles #door-overlay { --op-out: 1.95s; }
.st .st-tiles { position: absolute; inset: 0; display: grid; grid-template-columns: repeat(6, 1fr); grid-template-rows: repeat(9, 1fr); perspective: 900px; }
.st .st-tiles i { background: var(--tile) center / cover no-repeat; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .28), inset 0 0 0 2px rgba(0, 0, 0, .06); }
@keyframes st-tile-turn { from { transform: none; opacity: 1; } to { transform: rotateY(92deg) scale(.7); opacity: 0; } }
.st #door-overlay.open .st-tiles i { animation: st-tile-turn .6s ease-in calc(.15s + (var(--r) + var(--c)) * .07s) both; }
html.sb-film .st .st-tiles i { animation: st-tile-turn .6s ease-in calc(var(--door-start) + .15s + (var(--r) + var(--c)) * .07s) both; }

/* Temple lamp (nilavilakku) */
.st.st-open-vilakku #door-overlay { --op-out: 2.05s; }
.st .st-op-vilakku { background: radial-gradient(90% 60% at 50% 36%, color-mix(in srgb, var(--st-bg) 70%, #5a3a10), color-mix(in srgb, var(--st-bg) 70%, #000) 78%); }
.st .st-vil { position: absolute; left: 50%; top: 13%; width: 200px; height: 440px; margin-left: -100px; }
.st .st-vil-lamp { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 2; }
.st .st-vil-glow { position: absolute; z-index: 1; left: -70%; top: -40%; width: 240%; opacity: .22; transform: scale(.55); }
.st .st-vil-flame { position: absolute; z-index: 3; left: var(--x); top: var(--y); width: 24px; height: 42px; margin: -40px 0 0 -12px; transform-origin: 50% 100%; opacity: 0; transform: scale(.2); }
.st .st-vil-flame img { display: block; width: 100%; height: 100%; }
.st #door-overlay:not(.open) .st-vil-flame:nth-of-type(1) { opacity: 1; transform: none; }
.st .st-op-vilakku .st-bloom { top: calc(13% + 44px); }
.st.st-open-vilakku .st-op-label { bottom: 6%; color: var(--st-op-ink, var(--st-bg-head)); }
.st #door-overlay.open .st-vil-flame { animation: st-ignite .5s ease-out calc(var(--n) * .22s) both; }
.st #door-overlay.open .st-vil-glow { animation: st-glow-in 1.2s ease-out .2s both; }
.st #door-overlay.open .st-op-vilakku .st-bloom { animation: st-bloom 1.5s cubic-bezier(.5, 0, .3, 1) 1.05s both; }
html.sb-film .st .st-vil-flame { animation: st-ignite .5s ease-out calc(var(--door-start) + var(--n) * .22s) both; }
html.sb-film .st .st-vil-glow { animation: st-glow-in 1.2s ease-out calc(var(--door-start) + .2s) both; }
html.sb-film .st .st-op-vilakku .st-bloom { animation: st-bloom 1.5s cubic-bezier(.5, 0, .3, 1) calc(var(--door-start) + 1.05s) both; }

/* Block printing (ajrak, Parsi chalk) */
.st.st-open-stamp #door-overlay { --op-out: 2.15s; }
.st .st-op-stamp { background: var(--st-cloth, color-mix(in srgb, var(--st-surface) 90%, #b89a6a)); }
.st .st-cloth { position: absolute; inset: 0; display: grid; grid-template-columns: repeat(5, 1fr); grid-template-rows: repeat(8, 1fr); background: url('art/paper-grain.png') repeat; background-size: 200px; }
.st .st-cloth i { background: var(--stamp) center / 94% no-repeat; opacity: 0; }
.st #door-overlay:not(.open) .st-cloth i:nth-child(3n + 1) { opacity: 1; }
@keyframes st-stamp-in { from { opacity: 0; transform: scale(1.3); } to { opacity: 1; transform: none; } }
@keyframes st-cloth-lift { from { transform: none; } to { transform: translateY(-104%); } }
.st #door-overlay.open .st-cloth i { animation: st-stamp-in .3s cubic-bezier(.2, 1.5, .4, 1) calc(var(--o) * .028s) both; }
.st #door-overlay.open .st-cloth { animation: st-cloth-lift .95s cubic-bezier(.6, 0, .4, 1) 1.25s both; }
html.sb-film .st .st-cloth i { animation: st-stamp-in .3s cubic-bezier(.2, 1.5, .4, 1) calc(var(--door-start) + var(--o) * .028s) both; }
html.sb-film .st .st-cloth { animation: st-cloth-lift .95s cubic-bezier(.6, 0, .4, 1) calc(var(--door-start) + 1.25s) both; }

/* Through the gateway (Sanchi torana) */
.st.st-open-portal #door-overlay { --op-out: 1.65s; }
.st .st-op-portal { background: linear-gradient(180deg, color-mix(in srgb, var(--st-bg) 70%, #fff), var(--st-bg) 90%); }
.st .st-portal-light { position: absolute; left: 50%; top: 56%; width: 170px; height: 250px; margin: -125px 0 0 -85px; border-radius: 85px 85px 8px 8px; background: radial-gradient(circle at 50% 40%, #fffdf3, color-mix(in srgb, var(--st-orn) 35%, #fff) 60%, transparent 76%); }
.st .st-portal-gate { position: absolute; left: 50%; top: 50%; width: 350px; margin: -250px 0 0 -175px; transform-origin: 50% 64%; filter: drop-shadow(0 18px 30px rgba(0, 0, 0, .25)); }
.st.st-open-portal .st-op-label { bottom: 5%; }
@keyframes st-portal-through { 0% { transform: none; opacity: 1; } 70% { opacity: 1; } 100% { transform: scale(4.4); opacity: 0; } }
@keyframes st-portal-light { from { transform: none; } to { transform: scale(5); } }
.st #door-overlay:not(.open) .st-portal-gate { animation: st-pulse 5s ease-in-out infinite; }
.st #door-overlay.open .st-portal-gate { animation: st-portal-through 1.6s cubic-bezier(.5, 0, .7, .4) both; }
.st #door-overlay.open .st-portal-light { animation: st-portal-light 1.6s cubic-bezier(.5, 0, .7, .4) both; }
html.sb-film .st .st-portal-gate { animation: st-portal-through 1.6s cubic-bezier(.5, 0, .7, .4) var(--door-start) both; }
html.sb-film .st .st-portal-light { animation: st-portal-light 1.6s cubic-bezier(.5, 0, .7, .4) var(--door-start) both; }

/* Magazine cover (page turn) */
.st.st-open-editorial #door-overlay { --op-out: 1.45s; }
.st .st-op-editorial { perspective: 1600px; }
.st .st-ed-page { position: absolute; inset: 0; display: flex; flex-direction: column; padding: 30px 22px 26px; background: var(--st-surface); transform-origin: left center; box-shadow: 0 0 50px rgba(0, 0, 0, .3); }
.st .st-ed-mast { margin: 0; font-size: 3.6rem; line-height: .9; letter-spacing: -.015em; text-transform: uppercase; text-align: center; color: var(--st-head); }
.st .st-ed-mast [data-l]:not([data-l='en']) { font-size: .62em; line-height: 1.25; }
.st .st-ed-photo { flex: 1; margin: 16px 0 12px; background: var(--st-soft) center / cover no-repeat; }
.st .st-ed-line { margin: 0; font-size: .78rem; letter-spacing: .3em; text-transform: uppercase; text-align: center; color: var(--st-accent); }
.st.st-open-editorial .st-op-label { bottom: 15%; color: #fff; text-shadow: 0 2px 18px rgba(0, 0, 0, .55); }
.st.st-open-editorial .st-op-label .st-op-kicker { display: none; }
.st.st-open-editorial .st-op-label .st-op-hint { color: #fff; }
@keyframes st-ed-turn { 0% { transform: none; opacity: 1; } 80% { opacity: 1; } 100% { transform: rotateY(-112deg); opacity: 0; } }
.st #door-overlay.open .st-ed-page { animation: st-ed-turn 1.25s cubic-bezier(.6, .05, .3, 1) .1s both; }
html.sb-film .st .st-ed-page { animation: st-ed-turn 1.25s cubic-bezier(.6, .05, .3, 1) calc(var(--door-start) + .1s) both; }

/* First scene timing in the video after each cultural opening. */
html.sb-film body:is(.st-open-drape, .st-open-pearls, .st-open-slide, .st-open-paan, .st-open-leaves, .st-open-editorial) #entry { --sb-base: 2s; }
html.sb-film body:is(.st-open-window, .st-open-emblem, .st-open-cathedral, .st-open-mist, .st-open-tiles, .st-open-portal) #entry { --sb-base: 2.4s; }
html.sb-film body:is(.st-open-kolam, .st-open-vilakku, .st-open-stamp) #entry { --sb-base: 2.8s; }

/* Gold foil on the darker cultural openings. */
.st.st-foil.st-tone-dark:is(.st-open-emblem, .st-open-vilakku, .st-open-slide, .st-open-window, .st-open-cathedral) .st-op-names {
    background: linear-gradient(180deg, #fff6d0 0%, color-mix(in srgb, var(--st-orn) 60%, #fff) 30%, var(--st-orn) 62%, color-mix(in srgb, var(--st-orn) 70%, #000) 82%, #fff0b5 100%);
    -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent;
}
.st.st-foil.st-tone-dark:is(.st-open-emblem, .st-open-vilakku, .st-open-slide, .st-open-window, .st-open-cathedral) .st-op-names > * { -webkit-text-fill-color: transparent; }

/* ---------- More floating decorations ---------- */
.st.st-part-chinar .st-fall i { background-image: url('art/p-chinar.svg'); width: 22px; height: 22px; }
.st.st-part-chinar .st-fall i:nth-child(even) { background-image: url('art/p-chinar-2.svg'); }
.st.st-part-shiuli .st-fall i { background-image: url('art/p-shiuli.svg'); }
.st.st-part-frangipani .st-fall i { background-image: url('art/p-frangipani.svg'); width: 20px; height: 20px; }
.st.st-part-leaves .st-fall i { background-image: url('art/p-bodhi.svg'); width: 18px; height: 18px; }
.st.st-part-snow .st-fall i { background-image: url('art/p-snow.svg'); animation-duration: 15s; }
.st.st-part-lanterns .st-fall i { background-image: url('art/p-lantern.svg'); top: auto; bottom: -40px; width: 20px; height: 26px; animation-name: st-rise-up; animation-duration: 16s; }
@media (prefers-reduced-motion: reduce) {
    html:not(.sb-film) .st :is(.st-emb-rays, .st-emb-ring, .st-emb-sparks i, .st-strand, .st-gust, .st-mist, .st-drape) { animation: none !important; }
}

/* Programme cards: long ritual names (Tamil, Malayalam) wrap instead of widening the grid. */
.st.st-sch-cards .st-schedule { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.st .st-sch-item { min-width: 0; overflow-wrap: anywhere; }
