/* ============================================================
   CREEPY — decoração no escuro, sustos e cenas dos cards
   (elementos montados pelo creepy.js e pelo fx.js; motion em WAAPI)
   ============================================================ */

/* Vão entre os lotes e as atrações: era 128 + 128px */
.tickets-section { padding-bottom: clamp(40px, 5vw, 64px); }
.attractions-section { padding-top: clamp(56px, 8vw, 116px); }

.section > .container { position: relative; z-index: 1; }
.decor { position: absolute; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.decor > * { position: absolute; }

/* Cartaz de desaparecido */
.poster {
  width: 168px; padding: 12px 12px 16px; rotate: var(--r, -5deg); pointer-events: auto;
  background:
    radial-gradient(60% 40% at 30% 20%, rgba(90, 70, 40, 0.35), transparent 70%),
    radial-gradient(40% 30% at 80% 85%, rgba(60, 40, 20, 0.4), transparent 70%),
    linear-gradient(180deg, #6f6551, #5d5442);
  color: #1a1410; box-shadow: 0 18px 40px rgba(0, 0, 0, 0.7);
  clip-path: polygon(0 0, 100% 0, 100% 92%, 94% 96%, 86% 93%, 77% 99%, 66% 95%, 55% 100%, 44% 94%, 33% 98%, 22% 93%, 12% 99%, 0 95%);
  filter: brightness(0.82);
}
.poster .tape { position: absolute; top: -6px; width: 46px; height: 16px; background: rgba(200, 190, 160, 0.35); }
.poster .tape.t1 { left: -8px; rotate: -24deg; }
.poster .tape.t2 { right: -8px; rotate: 22deg; }
.poster-title { font-family: 'Special Elite', monospace; font-size: 21px; letter-spacing: 0.04em; text-align: center; line-height: 1; margin-bottom: 8px; color: #2a0c08; }
.poster-photo { position: relative; aspect-ratio: 100 / 110; background: #2b2620; overflow: hidden; outline: 1px solid rgba(0, 0, 0, 0.5); }
.poster-photo svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.poster-photo .scary { opacity: 0; }
.poster-photo::after { content: ''; position: absolute; inset: 0; background: repeating-linear-gradient(0deg, rgba(0, 0, 0, 0.18) 0 1px, transparent 1px 3px); }
.poster-lines { display: grid; gap: 5px; margin: 10px 0 8px; }
.poster-lines i { display: block; height: 4px; background: rgba(26, 20, 16, 0.55); border-radius: 2px; }
.poster-lines i:nth-child(2) { width: 82%; }
.poster-lines i:nth-child(3) { width: 64%; }
.poster-foot { font-family: 'Special Elite', monospace; font-size: 10.5px; text-align: center; letter-spacing: 0.03em; }

/* Recorte de jornal antigo */
.paper {
  width: 230px; padding: 12px 14px 18px; rotate: var(--r, 4deg);
  background:
    radial-gradient(50% 40% at 70% 30%, rgba(70, 55, 30, 0.35), transparent 70%),
    linear-gradient(180deg, #5f5848, #514a3b);
  color: #15110c; box-shadow: 0 18px 40px rgba(0, 0, 0, 0.7);
  clip-path: polygon(2% 1%, 30% 0, 52% 2%, 78% 0, 99% 2%, 100% 40%, 98% 70%, 100% 99%, 70% 97%, 45% 100%, 20% 97%, 0 99%, 1% 60%, 0 30%);
  filter: brightness(0.78);
}
.paper-mast { font-family: 'UnifrakturMaguntia', serif; font-size: 25px; text-align: center; line-height: 1; border-bottom: 2px solid rgba(21, 17, 12, 0.7); padding-bottom: 5px; }
.paper-date { font-family: 'Special Elite', monospace; font-size: 9px; text-align: center; padding: 3px 0; border-bottom: 1px solid rgba(21, 17, 12, 0.6); letter-spacing: 0.06em; }
.paper-head { font-family: Georgia, 'Times New Roman', serif; font-weight: 900; font-size: 21px; line-height: 1; text-align: center; margin: 8px 0; letter-spacing: -0.01em; }
.paper-body { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.paper-photo { aspect-ratio: 1; background: #2a261e; position: relative; overflow: hidden; }
.paper-photo svg { width: 100%; height: 100%; display: block; }
.paper-photo::after { content: ''; position: absolute; inset: 0; background-image: radial-gradient(rgba(0, 0, 0, 0.45) 0.8px, transparent 1.2px); background-size: 3px 3px; }
.paper-cols { display: grid; gap: 4px; align-content: start; }
.paper-cols i { display: block; height: 3px; background: rgba(21, 17, 12, 0.5); }
.paper-cols i:nth-child(4n) { width: 70%; }

/* Lustre */
.chandelier { width: 210px; transform-origin: 50% 0; will-change: transform; }
.chandelier svg { width: 100%; height: auto; overflow: visible; display: block; }
.chandelier .metal { fill: none; stroke: #3a3028; stroke-width: 3; stroke-linecap: round; }
.chandelier .metal-fill { fill: #3a3028; }
.chandelier .wax { fill: #cfc2a8; }
.chandelier .strand { fill: none; stroke: rgba(216, 205, 184, 0.28); stroke-width: 0.8; }
.ch-flame {
  position: absolute; width: 9px; height: 14px; margin: -14px 0 0 -4.5px;
  border-radius: 50% 50% 45% 45% / 65% 65% 35% 35%;
  background: radial-gradient(ellipse at 50% 75%, #fff4d6 0 22%, var(--ember) 42%, var(--pumpkin) 78%, rgba(255, 107, 26, 0) 100%);
  transform-origin: 50% 100%; will-change: transform, opacity;
}
.ch-glow {
  position: absolute; left: 50%; top: 40%; width: 560px; height: 440px; translate: -50% -30%;
  background: radial-gradient(50% 50% at 50% 40%, rgba(255, 150, 60, 0.14), rgba(255, 150, 60, 0.04) 50%, rgba(255, 150, 60, 0) 75%);
  will-change: opacity; pointer-events: none;
}

/* Morcegos, olhos e teias */
.hang-bat { width: 22px; transform-origin: 50% 0; will-change: transform, opacity; }
.hang-bat svg { width: 100%; height: auto; fill: #070605; display: block; }
.hang-bat .glint { fill: #d9ef6b; }
.hang-bat-thread { position: absolute; left: 50%; bottom: 100%; width: 1px; height: 600px; background: rgba(216, 205, 184, 0.1); }
.fly-bat { width: 40px; fill: #050403; will-change: transform; }
.fly-bat.pale { fill: #3a3028; }
.dark-eyes { width: 44px; will-change: transform, opacity; }
.dark-eyes .iris { fill: #d9ef6b; }
.dark-eyes .iris.red { fill: #ff3b1f; }
.dark-eyes .pupil { fill: #0b0908; }
.corner-web { width: 190px; }
.corner-web path { fill: none; stroke: rgba(216, 205, 184, 0.2); stroke-width: 1; }

/* Sustos */
.scare-dark { position: fixed; inset: 0; z-index: 90; background: #000; pointer-events: none; opacity: 0; display: grid; place-items: center; }
.scare-dark svg { width: min(260px, 50vw); opacity: 0; }
.drop-spider { position: fixed; top: 0; left: 0; z-index: 85; width: 40px; pointer-events: none; }
.drop-spider .thread { position: absolute; left: 20px; top: 0; width: 1px; height: 100vh; background: rgba(216, 205, 184, 0.55); transform-origin: top; transform: scaleY(0); }
.drop-spider svg { position: absolute; left: 0; top: -40px; width: 40px; will-change: transform; }

@media (max-width: 900px) {
  .poster, .paper { scale: 0.72; opacity: 0.55; }
  .chandelier { width: 150px; }
}

/* ============================================================
   Cards: cenas extras
   ============================================================ */
.attr { will-change: transform; }

.spots { position: absolute !important; inset: -40px 0 0; pointer-events: none; z-index: 0 !important; }
.spots i {
  position: absolute; top: 0; width: 150px; height: 340px; transform-origin: 50% 0; will-change: transform;
  background: linear-gradient(180deg, rgba(255, 210, 140, 0.26), rgba(255, 210, 140, 0.02) 85%);
  clip-path: polygon(44% 0, 56% 0, 100% 100%, 0 100%);
}
.spots i:first-child { left: 6%; }
.spots i:last-child { right: 6%; }
.podium { position: relative; }
.crown { position: absolute; left: 50%; top: -14px; width: 34px; margin-left: -17px; fill: var(--ember); z-index: 2; will-change: transform; }
.podium-col { position: relative; z-index: 1; }

.cauldron { position: absolute !important; right: 18px; bottom: 6px; width: 120px; z-index: 0 !important; }
.cauldron svg { width: 100%; height: auto; overflow: visible; display: block; position: relative; }
.cauldron .pot { fill: #0e0b09; stroke: #3a3028; stroke-width: 2; }
.cauldron .brew { fill: #7fbf4a; }
.brew-glow { position: absolute; left: 50%; top: 20%; width: 220px; height: 130px; translate: -50% -50%; background: radial-gradient(closest-side, rgba(127, 191, 74, 0.3), rgba(127, 191, 74, 0)); will-change: opacity; }
.pop { position: absolute; width: 10px; height: 10px; border-radius: 50%; background: #9bd06b; top: 16%; will-change: transform, opacity; opacity: 0; }
.steam { position: absolute; left: 50%; top: 0; width: 64px; height: 64px; margin-left: -32px; border-radius: 50%; background: radial-gradient(closest-side, rgba(200, 230, 170, 0.16), rgba(200, 230, 170, 0)); will-change: transform, opacity; opacity: 0; }
.attr-drinks .chips { max-width: calc(100% - 128px); }
@media (max-width: 520px) { .attr-drinks .chips { max-width: none; } .cauldron { width: 86px; opacity: 0.6; } }

.deco-spider { position: absolute !important; right: 54px; top: 0; width: 26px; z-index: 0 !important; transform-origin: 50% 0; will-change: transform; }
.deco-spider line { stroke: rgba(216, 205, 184, 0.45); stroke-width: 1; }
.deco-spider .b { fill: #cfc2a8; }
.deco-spider .l { fill: none; stroke: #cfc2a8; stroke-width: 1.4; stroke-linecap: round; }
.flash { position: absolute !important; inset: 0; z-index: 0 !important; background: rgba(220, 230, 255, 0.45); opacity: 0; pointer-events: none; }

.notes { position: absolute !important; right: 60px; top: 70px; width: 1px; height: 1px; z-index: 2 !important; pointer-events: none; }
.notes span { position: absolute; font-size: 22px; color: var(--ember); will-change: transform, opacity; opacity: 0; font-family: system-ui, sans-serif; }
.dance-ghost { position: absolute !important; left: 250px; bottom: 26px; width: 40px; z-index: 1; will-change: transform; }
@media (max-width: 520px) { .dance-ghost { left: auto; right: 24px; } }

/* ============================================================
   Local da festa
   ============================================================ */
.location { display: grid; gap: 20px; grid-template-columns: 1fr; }
@media (min-width: 900px) { .location { grid-template-columns: 1fr 1.15fr; align-items: stretch; } }
.loc-card { padding: clamp(22px, 3vw, 32px); border-radius: 16px; background: var(--night-2); border: 1px solid var(--line); display: flex; flex-direction: column; gap: 22px; }
.loc-access { position: relative; overflow: hidden; padding: 22px 22px 20px; border-radius: 14px; background: var(--pumpkin); color: var(--night); }
.loc-access-title { font-family: 'Creepster', cursive; font-size: clamp(40px, 5vw, 58px); line-height: 0.95; letter-spacing: 0.04em; margin-bottom: 14px; }
.loc-access ul { list-style: none; display: grid; gap: 10px; }
.loc-access li { display: flex; align-items: center; gap: 12px; font-size: clamp(16px, 1.7vw, 19px); font-weight: 800; line-height: 1.3; }
.loc-access li .ic { width: 26px; height: 26px; }
.loc-access mark { background: var(--night); color: var(--pumpkin); padding: 1px 8px; border-radius: 6px; white-space: nowrap; }
.loc-access-sweep { position: absolute; top: 0; bottom: 0; left: 0; width: 40%; background: linear-gradient(100deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.28), rgba(255, 255, 255, 0)); transform: translateX(-120%) skewX(-12deg); pointer-events: none; will-change: transform; }
.loc-address { display: flex; gap: 12px; align-items: flex-start; }
.loc-address .ic { color: var(--pumpkin); margin-top: 3px; }
.loc-address div { display: grid; gap: 2px; font-size: 15px; color: var(--bone-dim); }
.loc-address strong { font-size: 19px; font-weight: 800; color: var(--bone); }
.loc-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: auto; }
.loc-map { position: relative; min-height: 340px; border-radius: 16px; overflow: hidden; border: 1px solid var(--line); background: var(--night-2); }
.loc-map iframe {
  position: absolute; inset: 0; width: 100%; height: 100%; border: 0;
  filter: invert(0.92) hue-rotate(180deg) saturate(0.5) sepia(0.35) brightness(0.85) contrast(1.05);
}
.loc-pin { position: absolute; left: 50%; top: 50%; width: 0; height: 0; pointer-events: none; }
.loc-pin i { position: absolute; left: -40px; top: -40px; width: 80px; height: 80px; border-radius: 50%; border: 2px solid var(--pumpkin); will-change: transform, opacity; opacity: 0; }

/* Inclinação 3D escreve transform a cada quadro: transition em transform faria o card arrastar */
.attr { transition: border-color .45s var(--ease); }
.ticket { transition: background-color .4s var(--ease); }

/* Transição entre seções: a decoração não é cortada em cima nem embaixo (só nas laterais),
   para não desenhar uma linha reta na emenda dos blocos */
.decor { overflow-x: clip; overflow-y: visible; }
.chandelier::before {
  content: ''; position: absolute; left: 50%; bottom: 100%; width: 2px; height: 260px; margin-left: -1px;
  background: linear-gradient(to top, #3a3028, rgba(58, 48, 40, 0));
}
.hang-bat-thread { height: 260px; background: linear-gradient(to top, rgba(216, 205, 184, 0.16), rgba(216, 205, 184, 0)); }
@media (max-width: 1360px) { .poster { scale: 0.82; transform-origin: left top; } .paper { scale: 0.85; } }
.decor > .poster[style*="right"] { transform-origin: right top; }
