/* Matra decorative layer — purely visual, never intercepts clicks or covers content. */
#mx-decor, .mx-scroll, .mx-garland { pointer-events: none; user-select: none; }
#mx-decor { position: absolute; top: 0; left: 0; width: 100%; height: 0; z-index: 40; }

/* ---------- Section garlands (toran) ---------- */
.mx-garland { position: absolute; overflow: visible; will-change: clip-path; }
.mx-garland svg { display: block; width: 100%; height: 100%; overflow: visible; }
.mx-garland .mx-drop { transform-box: fill-box; transform-origin: 50% 0; animation: mxSway 3.6s ease-in-out infinite; }
.mx-garland .mx-drop:nth-child(2n) { animation-duration: 4.2s; animation-delay: -1.3s; }
.mx-garland .mx-drop:nth-child(3n) { animation-duration: 3.1s; animation-delay: -.7s; }
@keyframes mxSway { 0%,100% { transform: rotate(-4deg); } 50% { transform: rotate(4deg); } }

/* ---------- Side scroll banners (wide screens only, in the empty margins) ---------- */
.mx-scroll { position: fixed; top: 92px; width: 52px; z-index: 30; display: none; }
.mx-scroll.left { left: 18px; }
.mx-scroll.right { right: 18px; }
@media (min-width: 1536px) { .mx-scroll { display: block; } }
.mx-rod { position: relative; height: 10px; margin: 0 -8px; border-radius: 6px;
  background: linear-gradient(#f6c453, #c98a1b); box-shadow: 0 2px 4px rgba(120,60,0,.25); }
.mx-rod::before, .mx-rod::after { content: ""; position: absolute; top: -3px; width: 14px; height: 16px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fde68a, #c98a1b 70%); }
.mx-rod::before { left: -8px; } .mx-rod::after { right: -8px; }
.mx-cord { position: absolute; left: 50%; top: -26px; width: 44px; height: 26px; transform: translateX(-50%);
  border: 2px solid #c98a1b; border-bottom: none; border-radius: 22px 22px 0 0; opacity: .7; }
.mx-cloth { position: relative; overflow: hidden; height: 40px; margin-top: -2px;
  background:
    repeating-linear-gradient(180deg, rgba(255,255,255,.07) 0 2px, transparent 2px 6px),
    linear-gradient(180deg, #fb923c, #f97316 45%, #ea580c);
  border-left: 3px solid #fbbf24; border-right: 3px solid #fbbf24;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.18), 0 8px 18px -8px rgba(234,88,12,.45); }
.mx-letters { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 14px 0 70px;
  font-family: "Tiro Devanagari Hindi", serif; color: #fff7ed; font-size: 22px; line-height: 1.25;
  text-shadow: 0 1px 0 rgba(154,52,18,.35); }
.mx-letters span:nth-child(4n+2) { color: #fde68a; }
.mx-letters i { display: block; width: 6px; height: 6px; margin: 2px 0; transform: rotate(45deg); background: #fde68a; opacity: .8; }
.mx-roll { position: relative; height: 16px; margin: -6px -5px 0; border-radius: 8px;
  background: linear-gradient(180deg, #fdba74, #ea580c 55%, #9a3412); box-shadow: 0 4px 8px rgba(154,52,18,.3); }
.mx-tassel { position: absolute; left: 50%; top: 14px; width: 2px; height: 22px; background: #c98a1b; transform: translateX(-50%); }
.mx-tassel::after { content: ""; position: absolute; left: -5px; bottom: -14px; width: 12px; height: 16px;
  border-radius: 40% 40% 50% 50%; background: linear-gradient(#fbbf24, #ea580c); }

@media (prefers-reduced-motion: reduce) {
  .mx-garland .mx-drop { animation: none; }
}

/* ---------- homepage doorway toran ---------- */
.mx-toran { position: absolute; pointer-events: none; }
.mx-toran svg { display: block; width: 100%; height: 100%; overflow: visible; }
.mx-toran .mx-toran-hang { transform-box: fill-box; transform-origin: 50% 0; transition: transform .25s ease-out; }
.mx-toran .mx-tdrop { transform-box: fill-box; transform-origin: 50% 0; animation: mxDrop .9s cubic-bezier(.34,1.45,.5,1) both; }
.mx-toran.shown .mx-tdrop { animation: none; }
.mx-toran .mx-drop { animation-duration: 4.4s; }
@keyframes mxDrop { from { transform: scaleY(0); opacity: 0; } 60% { opacity: 1; } to { transform: scaleY(1); opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .mx-toran .mx-tdrop { animation: none; } }

/* extra headroom above the hero so the doorway toran shows at full size */
#root section.mx-hero-room { padding-top: 11rem; }
@media (min-width: 1024px) { #root section.mx-hero-room { padding-top: 15.5rem; } }

/* ---------- section motifs ---------- */
.mx-motif svg { display: block; width: 100%; height: 100%; overflow: visible; }
.mx-motif .mx-spin { transform-box: fill-box; transform-origin: 50% 50%; animation: mxSpin 48s linear infinite; }
.mx-motif .mx-spin.rev { animation-direction: reverse; animation-duration: 36s; }
@keyframes mxSpin { to { transform: rotate(360deg); } }
.mx-motif .mx-flame { transform-box: fill-box; transform-origin: 50% 100%; animation: mxFlicker 1.4s ease-in-out infinite alternate; }
.mx-motif .mx-glow { transform-box: fill-box; transform-origin: 50% 50%; animation: mxGlow 2.2s ease-in-out infinite alternate; }
@keyframes mxFlicker { 0% { transform: scale(1, 1) rotate(-3deg); } 50% { transform: scale(.94, 1.07) rotate(2deg); } 100% { transform: scale(1.03, .95) rotate(-1deg); } }
@keyframes mxGlow { from { opacity: .12; transform: scale(.9); } to { opacity: .26; transform: scale(1.1); } }
.mx-motif .mx-bloom { transform-box: fill-box; transform-origin: 50% 100%; animation: mxBloom 5s ease-in-out infinite; }
@keyframes mxBloom { 0%,100% { transform: scale(1); } 50% { transform: scale(1.05); } }
.mx-motif .mx-feather { transform-box: fill-box; transform-origin: 0% 50%; animation: mxFeather 4.5s ease-in-out infinite; }
@keyframes mxFeather { 0%,100% { transform: rotate(-2.5deg); } 50% { transform: rotate(2.5deg); } }
@media (prefers-reduced-motion: reduce) {
  .mx-motif .mx-spin, .mx-motif .mx-flame, .mx-motif .mx-glow, .mx-motif .mx-bloom, .mx-motif .mx-feather { animation: none; }
}
