/* Scilla Design System — Slide Deck */

:root {
  --sc-ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ─── Deck Container ─── */

.sc-deck {
  width: 100vw;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sc-slide-frame {
  position: relative;
  width: min(100vw, 177.78vh);
  height: min(56.25vw, 100vh);
  overflow: hidden;
  background: var(--sc-pink-moon);
}

/* ─── Slides ─── */

.sc-slide {
  position: absolute;
  inset: 0;
  background: var(--sc-pink-moon);
  color: var(--sc-blue-monday);
  padding: 5% 6%;
  display: flex;
  flex-direction: column;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}

.sc-slide.active {
  opacity: 1;
  pointer-events: auto;
}

/* ─── Entrance Animation (staggered children) ─── */

@keyframes sc-revealUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.sc-slide.active .sc-slide-body > *:nth-child(1) {
  animation: sc-revealUp 0.6s var(--sc-ease-expo) 0.07s both;
}

.sc-slide.active .sc-slide-body > *:nth-child(2) {
  animation: sc-revealUp 0.6s var(--sc-ease-expo) 0.13s both;
}

.sc-slide.active .sc-slide-body > *:nth-child(3) {
  animation: sc-revealUp 0.6s var(--sc-ease-expo) 0.19s both;
}

.sc-slide.active .sc-slide-body > *:nth-child(4) {
  animation: sc-revealUp 0.6s var(--sc-ease-expo) 0.25s both;
}

.sc-slide.active .sc-slide-body > *:nth-child(5) {
  animation: sc-revealUp 0.6s var(--sc-ease-expo) 0.31s both;
}

.sc-slide.active .sc-slide-body > *:nth-child(6) {
  animation: sc-revealUp 0.6s var(--sc-ease-expo) 0.37s both;
}

/* ─── Slide Chrome ─── */

.sc-slide-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 4%;
}

.sc-logo {
  font-size: 0.8em;
  font-weight: 700;
  opacity: 0.35;
}

.sc-slide-number {
  font-size: 0.75em;
  font-weight: 600;
  opacity: 0.2;
}

.sc-slide-body {
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* ─── Slide Types ─── */

.sc-slide-title {
  color: var(--sc-blue-monday);
  background: var(--sc-pink-moon);
}

.sc-slide-title::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 80% 80%, rgba(0, 34, 255, 0.06) 0%, transparent 60%);
  pointer-events: none;
}

.sc-slide-section {
  background: var(--sc-blue-monday);
  color: white;
  justify-content: center;
}

.sc-slide-section::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 20% 20%, rgba(255, 255, 255, 0.08) 0%, transparent 60%);
  pointer-events: none;
}

/* ─── Progress Dots ─── */

.sc-progress-dots {
  position: absolute;
  bottom: 3%;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 5px;
  z-index: 10;
}

.sc-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  border: none;
  padding: 0;
  background: rgba(0, 34, 255, 0.18);
  cursor: pointer;
  transition: background var(--sc-transition-normal), transform var(--sc-transition-normal);
}

.sc-dot.active {
  background: var(--sc-blue-monday);
  transform: scale(1.5);
}

.sc-slide-frame[data-theme="dark"] .sc-dot {
  background: rgba(255, 255, 255, 0.25);
}

.sc-slide-frame[data-theme="dark"] .sc-dot.active {
  background: white;
}

/* ─── Navigation ─── */

.sc-nav {
  position: fixed;
  bottom: 2vh;
  right: 2vw;
  display: flex;
  gap: 8px;
  z-index: 100;
}

.sc-nav button {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1.5px solid var(--sc-color-border-light);
  background: var(--sc-color-bg-card);
  color: var(--sc-blue-monday);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--sc-transition-normal), border-color var(--sc-transition-normal);
}

.sc-nav button:hover {
  border-color: var(--sc-blue-monday);
  background: rgba(0, 34, 255, 0.04);
}

/* ─── Step Reveals ─── */

.sc-step {
  opacity: 0;
  pointer-events: none;
  transition: opacity 2s var(--sc-ease-expo), transform 2s var(--sc-ease-expo);
  transform: translateY(14px);
}

.sc-step[data-step-from="down"] {
  transform: translateY(-14px);
}

.sc-step[data-step-from="left"] {
  transform: translateX(-22px);
}

.sc-step[data-step-from="right"] {
  transform: translateX(22px);
}

.sc-step[data-step-from="fade"] {
  transform: none;
}

.sc-step.revealed {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

/* Prevent stagger animation from overriding step reveals */
.sc-slide.active .sc-slide-body > .sc-step {
  animation: none;
}
