/* ── MPB · Gal / Wanessa vibes ── */
:root {
  --cream: #FFF8F0;
  --cream-dark: #F5E6D3;

  --vinho: #6B2D3C;
  --vinho-deep: #4A1F2B;
  --terracota: #C45C3E;
  --coral: #E8634A;
  --dourado: #E8B84A;
  --dourado-light: #F5D78E;
  --ambar: #D4924A;
  --ambar-deep: #8B5A2B;

  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Outfit', system-ui, sans-serif;

  --max-w: 430px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  height: 100%;
  overflow: hidden;
  background: var(--vinho-deep);
}

body {
  height: 100%;
  overflow: hidden;
  font-family: var(--font-body);
  color: var(--cream);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

#app {
  position: relative;
  width: 100%;
  max-width: var(--max-w);
  height: 100%;
  margin: 0 auto;
  overflow: hidden;
  background: var(--vinho-deep);
}

/* ── Progress ── */
.progress {
  position: absolute;
  top: calc(var(--safe-top) + 10px);
  left: 20px;
  right: 20px;
  z-index: 30;
  height: 3px;
  background: rgba(255, 248, 240, 0.15);
  border-radius: 3px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--dourado), var(--coral));
  border-radius: 3px;
  transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ── Slides ── */
.slides {
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow-y: scroll;
  scroll-snap-type: y mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.slides::-webkit-scrollbar { display: none; }

.slide {
  position: relative;
  flex: 0 0 100%;
  height: 100%;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: calc(var(--safe-top) + 44px) 16px calc(var(--safe-bottom) + 28px);
  overflow: hidden;
}

/* fundos por tema */
.slide__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

[data-theme="vinho"] .slide__bg {
  background: linear-gradient(145deg, var(--vinho-deep) 0%, var(--vinho) 45%, #8B3A4A 100%);
}

[data-theme="dourado"] .slide__bg {
  background: linear-gradient(160deg, #5C3D1E 0%, var(--terracota) 40%, var(--dourado) 100%);
}

[data-theme="ambar"] .slide__bg {
  background: linear-gradient(155deg, var(--vinho-deep) 0%, var(--ambar-deep) 35%, var(--ambar) 70%, var(--dourado-light) 100%);
}

[data-theme="terracota"] .slide__bg {
  background: linear-gradient(165deg, var(--vinho-deep) 0%, var(--terracota) 50%, var(--coral) 100%);
}

[data-theme="coral"] .slide__bg {
  background: linear-gradient(150deg, var(--vinho) 0%, var(--coral) 50%, var(--dourado-light) 100%);
}

[data-theme="noite"] .slide__bg {
  background: linear-gradient(180deg, #2A1520 0%, var(--vinho-deep) 40%, #1A0F14 100%);
}

/* orbes decorativos */
.slide__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.45;
  pointer-events: none;
  z-index: 1;
  animation: orb-drift 8s ease-in-out infinite;
}

.slide__orb--1 {
  width: 200px;
  height: 200px;
  top: 10%;
  right: -40px;
  background: var(--dourado);
}

.slide__orb--2 {
  width: 160px;
  height: 160px;
  bottom: 20%;
  left: -30px;
  background: var(--coral);
  animation-delay: -3s;
}

@keyframes orb-drift {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-12px, 16px) scale(1.08); }
}

/* vinil decorativo */
.vinyl {
  position: absolute;
  top: 18%;
  right: -20px;
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, var(--vinho-deep) 18%, transparent 19%),
    repeating-radial-gradient(circle at center, #1a1a1a 0px, #222 2px, #1a1a1a 4px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.35);
  z-index: 1;
  opacity: 0.7;
}

.slide.is-active .vinyl {
  animation: spin 6s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.slide__content {
  position: relative;
  z-index: 2;
  text-align: center;
}

/* ── Tipografia ── */
.tag {
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  opacity: 0.75;
  margin-bottom: 16px;
}

.headline {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 13vw, 4rem);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: -0.03em;
}

.headline em {
  font-style: italic;
  font-weight: 400;
  color: var(--dourado-light);
}

.headline--video {
  margin-bottom: 18px;
}

.headline--love {
  font-size: clamp(3.2rem, 15vw, 4.8rem);
}

.slide--love.is-active .headline--love em {
  animation: smile-glow 3s ease-in-out 1s infinite;
}

.slide--love.is-active .headline--love {
  animation: love-rise 1.2s cubic-bezier(0.4, 0, 0.2, 1) 0.15s both;
}

@keyframes love-rise {
  from {
    opacity: 0;
    transform: translateY(36px) scale(0.92);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* ── E AGORA? (primeiro beijo) ── */
.slide--agora {
  justify-content: center;
}

.agora {
  position: relative;
  z-index: 2;
  text-align: center;
}

.agora__e {
  font-family: var(--font-display);
  font-size: clamp(2rem, 9vw, 2.8rem);
  font-style: italic;
  font-weight: 400;
  opacity: 0.65;
  margin-bottom: 8px;
}

.agora__now {
  font-family: var(--font-display);
  font-size: clamp(3.5rem, 17vw, 5.5rem);
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1;
  color: var(--cream);
}

.slide--agora.is-active .agora__now {
  animation: agora-hit 0.9s cubic-bezier(0.2, 0.9, 0.3, 1) 1.1s both;
  text-shadow: 0 0 60px rgba(245, 215, 110, 0.35);
}

@keyframes agora-hit {
  0% {
    opacity: 0;
    transform: scale(1.15);
    letter-spacing: 0.2em;
  }
  60% {
    opacity: 1;
    transform: scale(0.98);
  }
  100% {
    opacity: 1;
    transform: scale(1);
    letter-spacing: 0.06em;
  }
}

.slide--agora .slide__orb--1 {
  width: 280px;
  height: 280px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: var(--dourado);
  opacity: 0.12;
  animation: agora-glow 4s ease-in-out infinite;
}

@keyframes agora-glow {
  0%, 100% { opacity: 0.1; transform: translate(-50%, -50%) scale(1); }
  50% { opacity: 0.22; transform: translate(-50%, -50%) scale(1.12); }
}

.slide--video.is-active .headline--video em {
  animation: smile-glow 3.5s ease-in-out 1.2s infinite;
}

@keyframes smile-glow {
  0%, 100% {
    color: var(--dourado-light);
    text-shadow: 0 0 24px rgba(245, 215, 110, 0.25);
  }
  50% {
    color: var(--cream);
    text-shadow: 0 0 40px rgba(245, 215, 110, 0.5);
  }
}

.hint {
  margin-top: 28px;
  font-size: 0.8rem;
  font-weight: 300;
  opacity: 0.55;
  animation: pulse 2.5s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 0.8; }
}

/* ── Stat ── */
.stat-num {
  font-family: var(--font-display);
  font-size: clamp(4.5rem, 20vw, 6rem);
  font-weight: 700;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.stat-sub {
  margin-top: 8px;
  font-size: 1.05rem;
  font-weight: 300;
  opacity: 0.85;
}

.stat-date {
  margin-top: 28px;
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-style: italic;
  opacity: 0.7;
}

/* ── Colecionar memórias (toque) ── */
.slide--collect {
  padding-left: 18px;
  padding-right: 18px;
  justify-content: flex-start;
  padding-top: calc(var(--safe-top) + 40px);
}

.collect {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 380px;
  height: 100%;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.collect__intro {
  flex-shrink: 0;
  text-align: left;
  transition: opacity 0.4s, transform 0.4s;
}

.slide--collect.is-active.has-revealed .collect__intro {
  opacity: 0.75;
  transform: scale(0.92);
  transform-origin: top left;
}

.lyric__line {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 5vw, 1.55rem);
  font-weight: 400;
  line-height: 1.35;
  margin-bottom: 4px;
}

.lyric__line--emph {
  font-size: clamp(1.45rem, 6vw, 1.9rem);
  font-style: italic;
  font-weight: 700;
  color: var(--dourado-light);
  margin-bottom: 6px;
}

.lyric__line--trail {
  font-style: italic;
  opacity: 0.8;
  margin-bottom: 0;
}

.collect__stage {
  flex: 1;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 12px 0 8px;
}

.collect__photo {
  width: 100%;
  height: 100%;
  max-height: 42vh;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 18px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.2);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
  opacity: 0;
  transform: scale(0.94);
  transition:
    opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.collect__photo.is-visible {
  opacity: 1;
  transform: scale(1);
}

.collect__photo.is-switching {
  opacity: 0;
  transform: scale(0.97);
}

.collect__photo img {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 42vh;
  object-fit: contain;
  object-position: center;
}

.collect__chips {
  flex-shrink: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  min-height: 36px;
  justify-content: center;
}

.chip {
  display: inline-block;
  padding: 6px 13px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 400;
  line-height: 1.2;
  background: rgba(255, 248, 240, 0.14);
  border: 1px solid rgba(255, 248, 240, 0.25);
  backdrop-filter: blur(4px);
  animation: chip-in 0.45s cubic-bezier(0.4, 0, 0.2, 1) both;
}

@keyframes chip-in {
  from { opacity: 0; transform: translateY(10px) scale(0.88); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.chip--rise {
  animation: chip-rise 0.55s cubic-bezier(0.34, 1.35, 0.64, 1) both;
}

@keyframes chip-rise {
  from { opacity: 0; transform: translateY(36px) scale(0.86); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.slide--collect-chips.has-revealed .collect__intro {
  opacity: 0.7;
  transform: scale(0.94);
  transition: opacity 0.45s ease, transform 0.45s ease;
}

.collect__hint {
  flex-shrink: 0;
  margin-top: 10px;
  text-align: center;
  font-size: 0.75rem;
  font-weight: 300;
  opacity: 0.5;
  animation: pulse 2.5s ease-in-out infinite;
}

.collect__hint.is-done {
  opacity: 0.75;
  animation: none;
}

.slide--collect-chips .collect__stage {
  display: none;
}

.slide--collect-chips .collect__intro {
  text-align: center;
  margin-bottom: 12px;
}

.slide--collect-chips .collect__intro .lyric__line--trail {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 6vw, 1.8rem);
  font-style: italic;
  opacity: 0.85;
}

.slide--collect-chips .collect__chips {
  min-height: 120px;
  align-content: center;
}

/* ── Burst collect (contador + explosão de fotos) ── */
.slide--collect-burst {
  padding-top: calc(var(--safe-top) + 16px);
  padding-bottom: calc(var(--safe-bottom) + 6px);
}

.slide--collect-burst .collect__intro:empty {
  display: none;
}

.slide--collect-burst .collect__stage--burst {
  position: relative;
  flex: 1;
  min-height: 58vh;
  width: 100%;
  overflow: hidden;
}

.slide--collect-burst.has-revealed .collect__chips,
.slide--collect-burst .collect__hint {
  position: relative;
  z-index: 8;
}

.collect__stat-burst {
  position: absolute;
  inset: 0;
  z-index: 6;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  pointer-events: none;
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.collect__stat-burst--label-only .stat-sub {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 6.5vw, 2rem);
  font-style: italic;
  font-weight: 700;
  color: var(--dourado-light);
  opacity: 1;
  margin-top: 0;
}

.slide--collect-burst.is-bursting .collect__stat-burst {
  opacity: 0;
  transform: scale(0.9);
}

.collect__burst {
  position: absolute;
  inset: 0 0 36px;
  z-index: 4;
  overflow: hidden;
}

.burst-photo {
  position: absolute;
  left: 50%;
  top: 50%;
  width: var(--burst-size, clamp(100px, 38vw, 180px));
  opacity: 0;
  transform:
    translate(calc(-50% + 0px), calc(-50% + 0px))
    scale(0.12)
    rotate(0deg);
  transition:
    opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.75s cubic-bezier(0.34, 1.45, 0.64, 1);
  transition-delay: var(--burst-delay, 0ms);
  will-change: transform, opacity;
}

.burst-photo.is-in {
  opacity: 1;
  transform:
    translate(calc(-50% + var(--bx)), calc(-50% + var(--by)))
    scale(1)
    rotate(var(--burst-rot, 0deg));
}

.burst-photo img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 12px;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.38);
  border: 2px solid rgba(255, 248, 240, 0.2);
}

.slide--collect-burst.has-revealed .collect__chips {
  margin-top: 2px;
}

/* ── Sequence collect (vida: tópico no topo + mosaico) ── */
.slide--collect-sequence {
  padding-left: 0;
  padding-right: 0;
  padding-top: calc(var(--safe-top) + 8px);
  padding-bottom: calc(var(--safe-bottom) + 6px);
}

.slide--collect-sequence .collect--sequence {
  max-width: none;
  width: 100%;
  height: 100%;
  padding: 0 10px;
}

.sequence__topic {
  position: absolute;
  left: 50%;
  top: 46%;
  z-index: 12;
  width: 88%;
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.45rem, 6.2vw, 1.95rem);
  font-style: italic;
  font-weight: 700;
  line-height: 1.25;
  text-align: center;
  color: var(--dourado-light);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.94);
  transition:
    opacity 0.55s ease,
    top 0.75s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.75s cubic-bezier(0.4, 0, 0.2, 1),
    font-size 0.75s ease;
  pointer-events: none;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.35);
}

.sequence__topic.is-visible {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.slide--collect-sequence.has-topic-top .sequence__topic.is-at-top {
  top: calc(var(--safe-top) + 52px);
  font-size: clamp(1.05rem, 4.4vw, 1.3rem);
  transform: translate(-50%, 0) scale(1);
}

.sequence__mosaic {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(var(--safe-top) + 88px);
  bottom: calc(var(--safe-bottom) + 40px);
  z-index: 4;
  overflow: hidden;
}

.mosaic-photo {
  position: absolute;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.35) rotate(0deg);
  transition:
    opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.8s cubic-bezier(0.34, 1.45, 0.64, 1);
  transition-delay: var(--mosaic-delay, 0ms);
  will-change: transform, opacity;
}

.mosaic-photo.is-in {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1) rotate(var(--mosaic-rot, 0deg));
}

.mosaic-photo.is-live {
  animation: mosaic-float var(--float-dur, 4.5s) ease-in-out infinite;
  animation-delay: var(--float-delay, 0s);
}

@keyframes mosaic-float {
  0%, 100% {
    transform: translate(-50%, -50%) scale(1) rotate(var(--mosaic-rot, 0deg)) translate(0, 0);
  }
  33% {
    transform: translate(-50%, -50%) scale(1.03) rotate(calc(var(--mosaic-rot, 0deg) + 1.5deg)) translate(3px, -5px);
  }
  66% {
    transform: translate(-50%, -50%) scale(0.98) rotate(calc(var(--mosaic-rot, 0deg) - 1deg)) translate(-4px, 4px);
  }
}

.mosaic-photo img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 14px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4);
  border: 2px solid rgba(255, 248, 240, 0.22);
}

.slide--collect-sequence .collect__hint {
  position: absolute;
  left: 0;
  right: 0;
  bottom: calc(var(--safe-bottom) + 10px);
  z-index: 14;
  margin: 0;
}

/* ── Showcase: slideshow cinematográfico ── */
.slide--showcase {
  padding: 0;
  justify-content: center;
}

.showcase {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.showcase__title {
  position: absolute;
  left: 50%;
  top: calc(var(--safe-top) + 44px);
  z-index: 12;
  width: 88%;
  text-align: center;
  transform: translate(-50%, 0);
  pointer-events: none;
}

.showcase__line {
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 6.8vw, 2.1rem);
  font-weight: 400;
  line-height: 1.2;
  margin-bottom: 2px;
  text-shadow: 0 4px 28px rgba(0, 0, 0, 0.4);
}

.showcase__line--emph {
  font-size: clamp(1.85rem, 8vw, 2.55rem);
  font-style: italic;
  font-weight: 700;
  color: var(--dourado-light);
  margin-bottom: 0;
}

.showcase__stage {
  position: absolute;
  left: 50%;
  top: 54%;
  z-index: 6;
  width: 92%;
  height: min(68vh, 520px);
  transform: translate(-50%, -50%);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.showcase__layer {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.75s ease;
}

.showcase__layer.is-visible {
  opacity: 1;
}

.showcase__layer img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transform: scale(1);
}

.showcase__layer.is-zoom.is-visible img {
  animation: showcase-kenburns 1.5s ease-out forwards;
}

@keyframes showcase-kenburns {
  from { transform: scale(1); }
  to   { transform: scale(1.08); }
}

.showcase__vignette {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.28) 0%, transparent 22%, transparent 78%, rgba(0, 0, 0, 0.38) 100%),
    radial-gradient(ellipse at center, transparent 42%, rgba(0, 0, 0, 0.22) 100%);
}

.slide--showcase .collect__hint {
  position: absolute;
  left: 0;
  right: 0;
  bottom: calc(var(--safe-bottom) + 12px);
  z-index: 14;
  margin: 0;
}

/* ── Texto narrado (parte 2) ── */
.slide--story-text .story-text {
  max-width: 340px;
  margin: 0 auto;
  text-align: center;
}

.story-line {
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 5.5vw, 1.75rem);
  font-weight: 400;
  line-height: 1.35;
  margin-bottom: 6px;
}

.story-line--emph {
  font-size: clamp(1.65rem, 7vw, 2.2rem);
  font-weight: 700;
  color: var(--dourado-light);
}

.story-line--italic {
  font-style: italic;
  font-weight: 400;
}

.story-line--large {
  font-size: clamp(2.4rem, 11vw, 3.4rem);
  font-weight: 600;
  line-height: 1.05;
}

.slide--story-text .tag {
  margin-bottom: 20px;
}

/* ── Slide vídeo ── */
.slide--video {
  justify-content: center;
}

.video-slide {
  width: 100%;
  max-width: 380px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.video-slide__media {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.video-slide__frame {
  width: 100%;
  border-radius: 20px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.35);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.3);
}

.video-slide__frame video {
  display: block;
  width: 100%;
  height: auto;
  max-height: 50vh;
  object-fit: contain;
  background: #1a1512;
}

.video-slide .btn-som {
  position: relative;
  top: auto;
  right: auto;
  padding: 10px 22px;
  font-size: 0.78rem;
}

/* ── Bento mosaic ── */
.slide--mosaic {
  justify-content: flex-start;
  padding-top: calc(var(--safe-top) + 48px);
}

.mosaic-title {
  position: relative;
  z-index: 2;
  width: 100%;
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-style: italic;
  font-weight: 400;
  text-align: left;
  padding: 0 4px 10px;
  opacity: 0.9;
}

.bento {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  grid-template-rows: repeat(4, 1fr);
  gap: 7px;
  width: 100%;
  height: calc(100dvh - var(--safe-top) - var(--safe-bottom) - 130px);
  max-height: 620px;
}

/* posições memórias (6 fotos) */
.bento .tile--lg   { grid-column: 1 / 4; grid-row: 1 / 3; }
.bento .tile--d2   { grid-column: 4 / 7; grid-row: 1 / 2; }
.bento .tile--d3   { grid-column: 4 / 7; grid-row: 2 / 3; }
.bento .tile--d4   { grid-column: 1 / 4; grid-row: 3 / 5; }
.bento .tile--d5   { grid-column: 4 / 6; grid-row: 3 / 5; }
.bento .tile--d6   { grid-column: 6 / 7; grid-row: 3 / 5; }

/* roles + vídeo */
.bento--roles {
  grid-template-rows: repeat(3, 1fr);
  max-height: 580px;
}

.bento--roles .tile--half { grid-row: 1 / 3; }
.bento--roles .tile--d1   { grid-column: 1 / 4; }
.bento--roles .tile--d2   { grid-column: 4 / 7; }
.bento--roles .tile--video { grid-column: 1 / 7; grid-row: 3 / 4; }

/* tile */
.tile {
  position: relative;
  margin: 0;
  border-radius: 14px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.2);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  opacity: 0;
  transform: scale(0.88) translateY(16px);
  transition:
    opacity 0.65s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.65s cubic-bezier(0.4, 0, 0.2, 1);
}

.slide.is-active .tile {
  opacity: 1;
  transform: scale(1) translateY(0);
}

.slide.is-active .tile--d1 { transition-delay: 0.05s; }
.slide.is-active .tile--d2 { transition-delay: 0.12s; }
.slide.is-active .tile--d3 { transition-delay: 0.19s; }
.slide.is-active .tile--d4 { transition-delay: 0.26s; }
.slide.is-active .tile--d5 { transition-delay: 0.33s; }
.slide.is-active .tile--d6 { transition-delay: 0.40s; }

.tile__img {
  flex: 1;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.15);
}

.tile__img img,
.tile__img video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  image-orientation: from-image;
}

/* ken burns ao ativar */
.slide.is-active .tile__img img {
  animation: ken-burns 12s ease-in-out infinite alternate;
}

@keyframes ken-burns {
  from { transform: scale(1); }
  to   { transform: scale(1.08); }
}

.tile figcaption {
  flex-shrink: 0;
  padding: 5px 8px 7px;
  font-family: var(--font-display);
  font-size: 0.58rem;
  font-style: italic;
  line-height: 1.2;
  text-align: center;
  background: rgba(0, 0, 0, 0.35);
  color: var(--cream);
  opacity: 0.9;
}

/* vídeo */
.tile--video .tile__img--video {
  background: #1a1512;
}

.tile--video video {
  max-height: 100%;
  width: auto;
  max-width: 100%;
}

.btn-som {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 18px;
  border: 1px solid rgba(255, 248, 240, 0.3);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(6px);
  color: var(--cream);
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 500;
  cursor: pointer;
}

.btn-som.is-on {
  background: rgba(232, 184, 74, 0.35);
  border-color: var(--dourado);
}

.btn-som:active { transform: scale(0.94); }

.btn-musica {
  position: absolute;
  top: calc(var(--safe-top) + 14px);
  right: 14px;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255, 248, 240, 0.28);
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(6px);
  color: var(--cream);
  font-size: 0.95rem;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  opacity: 0.75;
  transition: opacity 0.2s, background 0.2s, border-color 0.2s;
}

.btn-musica.is-on {
  opacity: 1;
  background: rgba(232, 184, 74, 0.3);
  border-color: var(--dourado);
}

.btn-musica:active { transform: scale(0.92); }

/* ── Animações de entrada ── */
.anim {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity 0.75s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.75s cubic-bezier(0.4, 0, 0.2, 1);
}

.slide.is-active .anim {
  opacity: 1;
  transform: translateY(0);
}

.slide.is-active .anim[data-delay="0"] { transition-delay: 0.08s; }
.slide.is-active .anim[data-delay="1"] { transition-delay: 0.22s; }
.slide.is-active .anim[data-delay="2"] { transition-delay: 0.38s; }
.slide.is-active .anim[data-delay="3"] { transition-delay: 0.52s; }

.slide--agora.is-active .anim[data-delay="0"] { transition-delay: 0.2s; }
.slide--agora.is-active .anim[data-delay="2"] { transition-delay: 0.2s; }
.slide--agora.is-active .agora__now.anim {
  opacity: 0;
  transform: none;
  transition: none;
}
.slide.is-active .anim[data-delay="4"] { transition-delay: 0.66s; }
.slide.is-active .anim[data-delay="5"] { transition-delay: 0.80s; }
.slide.is-active .anim[data-delay="6"] { transition-delay: 0.94s; }
.slide.is-active .anim[data-delay="7"] { transition-delay: 1.08s; }
.slide.is-active .anim[data-delay="8"] { transition-delay: 1.22s; }
