/* ============================================================
   Culpic Pitch Deck - Custom Theme for Reveal.js
   ============================================================ */

/* --- Google Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

/* --- Global Box Sizing Reset --- */
*, *::before, *::after {
  box-sizing: border-box;
}

/* --- Design Tokens --- */
:root {
  --brand-purple-900: #581C87;
  --brand-purple-700: #7E22CE;
  --brand-purple-600: #9333EA;
  --brand-purple-500: #A855F7;
  --brand-purple-400: #C084FC;
  --brand-indigo-600: #4F46E5;
  --brand-indigo-500: #6366F1;
  --brand-gradient: linear-gradient(135deg, #9333EA 0%, #4F46E5 100%);
  --brand-gradient-hover: linear-gradient(135deg, #A855F7 0%, #6366F1 100%);
  --brand-gradient-vivid: linear-gradient(135deg, #A855F7 0%, #9333EA 40%, #4F46E5 100%);
  --bg-dark: #0f0a1a;
  --bg-dark-alt: #1a1030;
  --bg-card: rgba(147,51,234,0.08);
  --bg-card-border: rgba(147,51,234,0.18);
  --text-primary: #f8fafc;
  --text-secondary: #b4a9c9;
  --text-muted: #7a6f96;
  --glow-purple: 0 0 40px rgba(147,51,234,0.15), 0 0 80px rgba(147,51,234,0.05);
  --glow-purple-strong: 0 0 30px rgba(147,51,234,0.25), 0 0 60px rgba(147,51,234,0.1);
  --font-main: 'Inter', system-ui, -apple-system, sans-serif;
}

/* --- Reveal.js Theme Override --- */
.reveal-viewport {
  background: var(--bg-dark);
  font-family: var(--font-main);
}

.reveal {
  font-family: var(--font-main);
  font-size: 32px;
  color: var(--text-primary);
}

.reveal h1, .reveal h2, .reveal h3, .reveal h4, .reveal h5, .reveal h6 {
  font-family: var(--font-main);
  font-weight: 700;
  color: var(--text-primary);
  text-transform: none;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.reveal h1 { font-size: 3.2em; }
.reveal h2 { font-size: 2em; }
.reveal h3 { font-size: 1.4em; }
.reveal h4 { font-size: 1.1em; }

.reveal p {
  line-height: 1.6;
  color: var(--text-secondary);
}

.reveal strong {
  color: var(--text-primary);
}

/* --- Gradient Text --- */
.gradient-text {
  background: var(--brand-gradient-vivid);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.gradient-text-wide {
  background: linear-gradient(90deg, #A855F7 0%, #9333EA 30%, #4F46E5 60%, #06B6D4 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- Slide Backgrounds --- */
.reveal .slide-background {
  background: var(--bg-dark);
}

/* Ambient purple glow on default slides */
.reveal .slides > section:not([data-background]) {
  background: radial-gradient(ellipse 70% 50% at 50% 30%, rgba(147,51,234,0.06) 0%, transparent 70%);
}

section[data-background-gradient] {
  color: white;
}

/* --- Layout Classes --- */
.two-column,
.two-column-wide,
.three-column,
.four-column,
.five-column,
.store-layout {
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
}

.two-column {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
  text-align: left;
}

.two-column-wide {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2rem;
  align-items: center;
  text-align: left;
}

.three-column {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.2rem;
  text-align: center;
}

.four-column {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  text-align: center;
}

.five-column {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.8rem;
  text-align: center;
}

.content-left { text-align: left; }

/* --- Cards --- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  border-radius: 16px;
  padding: 1.5rem;
  backdrop-filter: blur(10px);
  box-sizing: border-box;
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 4px 20px rgba(147,51,234,0.06);
}

.card:hover {
  transform: translateY(-4px);
  border-color: var(--brand-purple-500);
  box-shadow: var(--glow-purple-strong);
}

/* Card text: single line */
.three-column .card h4,
.three-column .card p {
  white-space: normal;
  overflow-wrap: break-word;
}

/* Prevent grid children from overflowing their 1fr cells */
.three-column > * {
  min-width: 0;
}

.card-sm {
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  border-radius: 12px;
  padding: 1.2rem;
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 12px rgba(147,51,234,0.05);
}

/* --- Category Colors --- */
.cat-creator { border-left: 4px solid #9333EA; background: rgba(147,51,234,0.1); border-color: rgba(147,51,234,0.25); }
.cat-technical { border-left: 4px solid #06B6D4; background: rgba(6,182,212,0.08); border-color: rgba(6,182,212,0.2); }
.cat-facility { border-left: 4px solid #F59E0B; background: rgba(245,158,11,0.08); border-color: rgba(245,158,11,0.2); }
.cat-production { border-left: 4px solid #EF4444; background: rgba(239,68,68,0.08); border-color: rgba(239,68,68,0.2); }
.cat-consumer { border-left: 4px solid #10B981; background: rgba(16,185,129,0.08); border-color: rgba(16,185,129,0.2); }

.cat-icon-creator { color: #A855F7; }
.cat-icon-technical { color: #22D3EE; }
.cat-icon-facility { color: #FBBF24; }
.cat-icon-production { color: #F87171; }
.cat-icon-consumer { color: #34D399; }

/* --- Badge --- */
.badge {
  display: inline-block;
  padding: 0.25em 0.75em;
  border-radius: 9999px;
  font-size: 0.55em;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-purple { background: rgba(147,51,234,0.25); color: #C084FC; border: 1px solid rgba(147,51,234,0.3); }
.badge-cyan { background: rgba(6,182,212,0.2); color: #22D3EE; border: 1px solid rgba(6,182,212,0.25); }
.badge-amber { background: rgba(245,158,11,0.2); color: #FBBF24; border: 1px solid rgba(245,158,11,0.25); }
.badge-red { background: rgba(239,68,68,0.2); color: #F87171; border: 1px solid rgba(239,68,68,0.25); }
.badge-green { background: rgba(16,185,129,0.2); color: #34D399; border: 1px solid rgba(16,185,129,0.25); }

/* --- Screenshot Device Mockup --- */
.device-mockup {
  position: relative;
  perspective: 1000px;
}

.device-mockup img {
  border-radius: 12px;
  box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5), 0 0 30px rgba(147,51,234,0.1);
  border: 1px solid rgba(147,51,234,0.15);
  transition: transform 0.5s ease, box-shadow 0.5s ease;
  max-width: 100%;
  height: auto;
}

.device-mockup-tilted img {
  transform: perspective(1000px) rotateY(-5deg) rotateX(2deg);
  border-radius: 12px;
  box-shadow: 20px 25px 50px -12px rgba(0,0,0,0.5), 0 0 40px rgba(147,51,234,0.12);
}

.device-mockup-tilted:hover img {
  transform: perspective(1000px) rotateY(0deg) rotateX(0deg);
}

/* Screenshot placeholder when image is missing */
.screenshot-placeholder {
  background: linear-gradient(135deg, var(--bg-dark-alt) 0%, #2d1b4e 50%, rgba(147,51,234,0.15) 100%);
  border: 2px dashed rgba(147,51,234,0.4);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-purple-400);
  font-size: 0.6em;
  min-height: 300px;
  width: 100%;
  box-shadow: inset 0 0 40px rgba(147,51,234,0.05);
}

/* --- Counter Animation --- */
.counter-value {
  font-size: 3.5em;
  font-weight: 800;
  line-height: 1;
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.counter-label {
  font-size: 0.6em;
  color: var(--text-secondary);
  margin-top: 0.5em;
}

/* --- Comparison Table --- */
.comparison-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.55em;
}

.comparison-table th {
  background: rgba(147,51,234,0.2);
  padding: 0.8em 1em;
  text-align: left;
  font-weight: 600;
  color: var(--text-primary);
  border-bottom: 2px solid rgba(147,51,234,0.4);
}

.comparison-table th:first-child {
  border-radius: 12px 0 0 0;
}

.comparison-table th:last-child {
  border-radius: 0 12px 0 0;
}

.comparison-table td {
  padding: 0.7em 1em;
  border-bottom: 1px solid rgba(147,51,234,0.1);
  color: var(--text-secondary);
}

.comparison-table tr:last-child td:first-child {
  border-radius: 0 0 0 12px;
}

.comparison-table tr:last-child td:last-child {
  border-radius: 0 0 12px 0;
}

.comparison-table .highlight {
  color: var(--brand-purple-400);
  font-weight: 600;
}

/* --- Timeline / Roadmap --- */
.timeline {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  position: relative;
  padding: 2rem 0;
  margin-top: 2rem;
}

.timeline::before {
  content: '';
  position: absolute;
  top: 2.5rem;
  left: 5%;
  right: 5%;
  height: 3px;
  background: linear-gradient(90deg, var(--brand-purple-600), var(--brand-indigo-600), #06B6D4);
  border-radius: 2px;
}

.timeline-item {
  flex: 1;
  text-align: center;
  position: relative;
  z-index: 1;
  padding: 0 0.5rem;
}

.timeline-dot {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--brand-gradient-vivid);
  margin: 0 auto 1rem;
  position: relative;
  box-shadow: 0 0 0 4px var(--bg-dark), 0 0 0 6px var(--brand-purple-600), 0 0 15px rgba(147,51,234,0.25);
}

.timeline-dot.active {
  width: 24px;
  height: 24px;
  box-shadow: 0 0 0 4px var(--bg-dark), 0 0 0 6px var(--brand-purple-500), 0 0 30px rgba(147,51,234,0.5), 0 0 60px rgba(147,51,234,0.15);
}

.timeline-phase {
  font-size: 0.45em;
  font-weight: 700;
  color: var(--brand-purple-400);
  margin-bottom: 0.3em;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.timeline-title {
  font-size: 0.55em;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.2em;
}

.timeline-desc {
  font-size: 0.4em;
  color: var(--text-muted);
}

/* --- CTA Section --- */
.cta-section {
  text-align: center;
}

.cta-button {
  display: inline-block;
  padding: 1em 2.5em;
  background: var(--brand-gradient-vivid);
  color: white;
  font-size: 0.7em;
  font-weight: 700;
  border-radius: 12px;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(147,51,234,0.5), 0 0 40px rgba(147,51,234,0.15);
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(147,51,234,0.6), 0 0 60px rgba(147,51,234,0.2);
}

.cta-secondary {
  display: inline-block;
  padding: 0.8em 2em;
  background: transparent;
  color: var(--brand-purple-400);
  font-size: 0.6em;
  font-weight: 600;
  border: 2px solid var(--brand-purple-600);
  border-radius: 12px;
  text-decoration: none;
  margin-left: 1rem;
  transition: all 0.3s ease;
}

.cta-secondary:hover {
  background: rgba(147,51,234,0.1);
}

/* --- SVG Line Drawing Animation --- */
.draw-line {
  stroke-dasharray: 1000;
  stroke-dashoffset: 1000;
  animation: drawLine 2s ease forwards;
}

@keyframes drawLine {
  to { stroke-dashoffset: 0; }
}

/* --- Ecosystem Diagram --- */
.ecosystem-svg {
  max-width: 500px;
  margin: 0 auto;
}

.ecosystem-svg .node-circle {
  transition: transform 0.3s ease;
}

/* --- Feature List --- */
.feature-list {
  list-style: none;
  padding: 0;
  margin: 0;
  text-align: left;
}

.feature-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.8em;
  margin-bottom: 0.8em;
  font-size: 0.6em;
  color: var(--text-secondary);
  line-height: 1.5;
  white-space: nowrap;
}

.feature-list li::before {
  content: '✦';
  color: var(--brand-purple-400);
  font-size: 0.8em;
  flex-shrink: 0;
  margin-top: 0.15em;
}

/* --- Check List --- */
.check-list {
  list-style: none;
  padding: 0;
  text-align: left;
}

.check-list li {
  display: flex;
  align-items: center;
  gap: 0.6em;
  margin-bottom: 0.6em;
  font-size: 0.6em;
  color: var(--text-secondary);
  white-space: nowrap;
}

.check-list li .check {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(16,185,129,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #34D399;
  font-size: 0.8em;
}

/* --- Question Cards (Section 2) --- */
.question-card {
  background: rgba(147,51,234,0.12);
  border: 1px solid rgba(147,51,234,0.28);
  border-radius: 16px;
  padding: 1.2rem 1.5rem;
  font-size: 0.65em;
  color: var(--text-primary);
  font-weight: 500;
  text-align: left;
  box-shadow: 0 4px 16px rgba(147,51,234,0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.question-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(147,51,234,0.15);
}

.question-card .q-icon + span,
.question-card {
  white-space: nowrap;
}

.question-card .q-icon {
  color: var(--brand-purple-400);
  font-size: 1.2em;
  margin-right: 0.5em;
  text-shadow: 0 0 10px rgba(147,51,234,0.5);
}

/* --- Product Type Grid --- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.product-type {
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  border-radius: 12px;
  padding: 0.8rem;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-type:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(147,51,234,0.12);
}

.product-type-icon {
  font-size: 1.5em;
  margin-bottom: 0.3em;
}

.product-type-name {
  font-size: 0.55em;
  font-weight: 600;
  color: var(--text-primary);
}

.product-type-desc {
  font-size: 0.4em;
  color: var(--text-muted);
  margin-top: 0.2em;
  white-space: nowrap;
}

/* --- Chart Container --- */
.chart-container {
  position: relative;
  max-width: 100%;
  margin: 0 auto;
}

.chart-container canvas {
  max-width: 100%;
}

/* --- Store Layout (2-column for Section 7) --- */
.store-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  align-items: center;
}

.store-chart-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* --- Slide-specific Styles --- */

/* Title slide */
.title-slide h1 {
  font-size: 3.5em;
  margin-bottom: 0.2em;
}

.title-slide .tagline {
  font-size: 0.7em;
  color: var(--text-secondary);
  font-weight: 400;
}

/* Section divider */
.section-label {
  font-size: 0.5em;
  font-weight: 600;
  color: var(--brand-purple-400);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin-bottom: 0.5em;
  text-shadow: 0 0 20px rgba(147,51,234,0.4);
}

/* Small text */
.small-text {
  font-size: 0.5em;
  color: var(--text-muted);
}

.smaller-text {
  font-size: 0.4em;
  color: var(--text-muted);
}

/* Value proposition cards */
.value-card {
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  border-radius: 16px;
  padding: 2rem;
  text-align: left;
  box-shadow: 0 4px 20px rgba(147,51,234,0.06);
}

.value-card h3 {
  font-size: 0.8em;
  margin-bottom: 0.5em;
}

.value-card p {
  font-size: 0.55em;
  line-height: 1.5;
}

/* --- Responsive Tweaks --- */
@media (max-width: 1024px) {
  .two-column, .two-column-wide {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .five-column {
    grid-template-columns: repeat(3, 1fr);
  }

  .four-column {
    grid-template-columns: repeat(2, 1fr);
  }

  .timeline {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
  }

  .timeline::before {
    top: 0;
    bottom: 0;
    left: 1rem;
    right: auto;
    width: 3px;
    height: auto;
  }

  .timeline-item {
    text-align: left;
    padding-left: 3rem;
  }
}

/* ============================================================
   Kiosk Mode - Background Gradient Animation
   ============================================================ */
.kiosk-bg {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  z-index: -1;
  background: linear-gradient(
    135deg,
    #0f0a1a 0%,
    #1a0533 20%,
    #2d1054 40%,
    #581C87 60%,
    #2d1054 80%,
    #0f0a1a 100%
  );
  background-size: 400% 400%;
  animation: gradientShift 20s ease infinite;
}

@keyframes gradientShift {
  0%   { background-position: 0% 50%; }
  25%  { background-position: 100% 0%; }
  50%  { background-position: 100% 100%; }
  75%  { background-position: 0% 100%; }
  100% { background-position: 0% 50%; }
}

/* Kiosk mode: make viewport transparent so .kiosk-bg gradient shows through */
.kiosk-mode .reveal-viewport {
  background: transparent;
}

/* Kiosk mode: slide backgrounds become slightly transparent */
.kiosk-mode .reveal .slide-background-content {
  opacity: 0.85;
}

/* ============================================================
   Kiosk Mode - Interstitial Overlay
   ============================================================ */
.kiosk-interstitial {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  z-index: 100;
  background: radial-gradient(ellipse 80% 60% at 50% 45%, rgba(147,51,234,0.25) 0%, transparent 60%),
              linear-gradient(135deg, #0f0a1a 0%, #1a0533 40%, #0f0a1a 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.8s ease;
}

.interstitial-content {
  text-align: center;
  max-width: 800px;
  padding: 2rem;
}

.interstitial-logo {
  height: 70px;
  margin-bottom: 2rem;
  filter: drop-shadow(0 0 30px rgba(147,51,234,0.5));
}

.interstitial-message {
  font-size: 2.2em;
  font-weight: 700;
  color: #f8fafc;
  line-height: 1.3;
  margin-bottom: 1.5rem;
  text-shadow: 0 0 40px rgba(147,51,234,0.3);
}

.interstitial-tagline {
  font-size: 0.9em;
  color: #7a6f96;
  font-weight: 400;
  letter-spacing: 0.1em;
}

/* --- Interstitial Animation 1: Fade + Scale --- */
.anim-fade-scale .interstitial-logo,
.anim-fade-scale .interstitial-message,
.anim-fade-scale .interstitial-tagline {
  animation: fadeScale 1s ease-out both;
}
.anim-fade-scale .interstitial-message { animation-delay: 0.2s; }
.anim-fade-scale .interstitial-tagline { animation-delay: 0.4s; }

@keyframes fadeScale {
  from { opacity: 0; transform: scale(0.8); }
  to   { opacity: 1; transform: scale(1); }
}

/* --- Interstitial Animation 2: Slide Up --- */
.anim-slide-up .interstitial-logo,
.anim-slide-up .interstitial-message,
.anim-slide-up .interstitial-tagline {
  animation: slideUp 0.8s ease-out both;
}
.anim-slide-up .interstitial-message { animation-delay: 0.15s; }
.anim-slide-up .interstitial-tagline { animation-delay: 0.3s; }

@keyframes slideUp {
  from { opacity: 0; transform: translateY(60px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* --- Interstitial Animation 3: Blur In --- */
.anim-blur-in .interstitial-logo,
.anim-blur-in .interstitial-message,
.anim-blur-in .interstitial-tagline {
  animation: blurIn 1s ease-out both;
}
.anim-blur-in .interstitial-message { animation-delay: 0.2s; }
.anim-blur-in .interstitial-tagline { animation-delay: 0.4s; }

@keyframes blurIn {
  from { opacity: 0; filter: blur(20px); }
  to   { opacity: 1; filter: blur(0); }
}

/* --- Interstitial Animation 4: Zoom + Rotate --- */
.anim-zoom-rotate .interstitial-logo,
.anim-zoom-rotate .interstitial-message,
.anim-zoom-rotate .interstitial-tagline {
  animation: zoomRotate 0.9s ease-out both;
}
.anim-zoom-rotate .interstitial-message { animation-delay: 0.2s; }
.anim-zoom-rotate .interstitial-tagline { animation-delay: 0.4s; }

@keyframes zoomRotate {
  from { opacity: 0; transform: scale(0.5) rotate(-5deg); }
  to   { opacity: 1; transform: scale(1) rotate(0deg); }
}

/* --- Interstitial Animation 5: Split Reveal --- */
.anim-split-reveal .interstitial-logo,
.anim-split-reveal .interstitial-message,
.anim-split-reveal .interstitial-tagline {
  animation: splitReveal 0.8s ease-out both;
}
.anim-split-reveal .interstitial-logo { animation-name: splitFromLeft; }
.anim-split-reveal .interstitial-message { animation-name: splitFromRight; animation-delay: 0.15s; }
.anim-split-reveal .interstitial-tagline { animation-name: splitFromLeft; animation-delay: 0.3s; }

@keyframes splitFromLeft {
  from { opacity: 0; transform: translateX(-80px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes splitFromRight {
  from { opacity: 0; transform: translateX(80px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* --- Interstitial Animation 6: Glow Pulse --- */
.anim-glow-pulse .interstitial-logo,
.anim-glow-pulse .interstitial-message,
.anim-glow-pulse .interstitial-tagline {
  animation: glowPulse 1.2s ease-out both;
}
.anim-glow-pulse .interstitial-message { animation-delay: 0.2s; }
.anim-glow-pulse .interstitial-tagline { animation-delay: 0.4s; }

@keyframes glowPulse {
  0%   { opacity: 0; text-shadow: 0 0 0 rgba(147,51,234,0); }
  50%  { opacity: 1; text-shadow: 0 0 60px rgba(147,51,234,0.8), 0 0 120px rgba(147,51,234,0.4); }
  100% { opacity: 1; text-shadow: 0 0 20px rgba(147,51,234,0.3); }
}

/* --- Interstitial Animation 7: Typewriter (clip-path) --- */
.anim-typewriter .interstitial-logo {
  animation: fadeScale 0.8s ease-out both;
}
.anim-typewriter .interstitial-message {
  animation: typewriterReveal 1.5s steps(30, end) both;
  animation-delay: 0.3s;
  overflow: hidden;
  white-space: nowrap;
}
.anim-typewriter .interstitial-tagline {
  animation: fadeScale 0.8s ease-out both;
  animation-delay: 1.5s;
}

@keyframes typewriterReveal {
  from { clip-path: inset(0 100% 0 0); opacity: 1; }
  to   { clip-path: inset(0 0 0 0); opacity: 1; }
}

/* --- Interstitial Animation 8: Wave --- */
.anim-wave .interstitial-logo,
.anim-wave .interstitial-message,
.anim-wave .interstitial-tagline {
  animation: waveIn 1s ease-out both;
}
.anim-wave .interstitial-message { animation-delay: 0.2s; }
.anim-wave .interstitial-tagline { animation-delay: 0.4s; }

@keyframes waveIn {
  0%   { opacity: 0; transform: translateY(40px) scaleY(0.6); }
  60%  { transform: translateY(-10px) scaleY(1.05); }
  100% { opacity: 1; transform: translateY(0) scaleY(1); }
}

/* --- Interstitial Animation 9: Bounce In --- */
.anim-bounce-in .interstitial-logo,
.anim-bounce-in .interstitial-message,
.anim-bounce-in .interstitial-tagline {
  animation: bounceIn 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}
.anim-bounce-in .interstitial-message { animation-delay: 0.15s; }
.anim-bounce-in .interstitial-tagline { animation-delay: 0.3s; }

@keyframes bounceIn {
  from { opacity: 0; transform: scale(0.3); }
  to   { opacity: 1; transform: scale(1); }
}

/* --- Interstitial Animation 10: Cinematic --- */
.anim-cinematic .interstitial-content {
  animation: cinematicBars 1.2s ease-out both;
}
.anim-cinematic .interstitial-logo,
.anim-cinematic .interstitial-message,
.anim-cinematic .interstitial-tagline {
  animation: cinematicFade 1s ease-out both;
}
.anim-cinematic .interstitial-message { animation-delay: 0.4s; }
.anim-cinematic .interstitial-tagline { animation-delay: 0.7s; }

@keyframes cinematicBars {
  from { clip-path: inset(45% 0 45% 0); }
  to   { clip-path: inset(0 0 0 0); }
}

@keyframes cinematicFade {
  from { opacity: 0; transform: scale(1.1); }
  to   { opacity: 1; transform: scale(1); }
}

/* ============================================================
   Title Slide - Entrance Animations
   ============================================================ */
.title-anim {
  opacity: 0;
  animation-fill-mode: both;
  animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
}

/* 1) Logo: soft fade + drop down */
.title-anim-1 {
  animation: titleDropIn 0.9s 0.2s both;
}

/* 2) H1: fade up with slight scale */
.title-anim-2 {
  animation: titleRiseIn 1s 0.55s both;
}

/* 3) Tagline: gentle fade up */
.title-anim-3 {
  animation: titleFadeUp 0.9s 0.95s both;
}

/* 4) Badge: pop in */
.title-anim-4 {
  animation: titlePopIn 0.7s 1.3s both;
}

@keyframes titleDropIn {
  0%   { opacity: 0; transform: translateY(-30px) scale(0.9); filter: blur(6px); }
  100% { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}

@keyframes titleRiseIn {
  0%   { opacity: 0; transform: translateY(40px) scale(0.97); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes titleFadeUp {
  0%   { opacity: 0; transform: translateY(25px); }
  100% { opacity: 1; transform: translateY(0); }
}

@keyframes titlePopIn {
  0%   { opacity: 0; transform: scale(0.5); }
  60%  { opacity: 1; transform: scale(1.08); }
  100% { opacity: 1; transform: scale(1); }
}

/* ============================================================
   Slide Entrance Animation System
   ============================================================ */
@keyframes slideEnterUp {
  from { opacity: 0; transform: translateY(25px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes slideEnterScale {
  from { opacity: 0; transform: scale(0.92); }
  to   { opacity: 1; transform: scale(1); }
}

/* Animation ready state (hidden) */
.slide-anim-ready {
  opacity: 0;
  transform: translateY(25px);
  transition: none;
}

/* Animation enter state (visible with animation) */
.slide-anim-ready.slide-anim-enter {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.9s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
}

/* --- Print Support --- */
@media print {
  .reveal-viewport {
    background: white;
  }

  .reveal {
    color: #1e293b;
  }

  .reveal h1, .reveal h2, .reveal h3 {
    color: #1e293b;
  }

  .card {
    border: 1px solid #e2e8f0;
    background: #f8fafc;
  }
}

/* --- Fragment animation enhancements --- */
.reveal .fragment.fade-up {
  transform: translateY(20px);
  opacity: 0;
  transition: all 0.5s ease;
}

.reveal .fragment.fade-up.visible {
  transform: translateY(0);
  opacity: 1;
}

/* --- Slide section containment --- */
.reveal .slides section {
  padding: 1.5rem 3rem;
  box-sizing: border-box;
  overflow: hidden;
}

/* Stack wrappers (vertical slide containers) must NOT have padding */
.reveal .slides section.stack {
  padding: 0 !important;
}

/* Force all direct children to stay within section bounds */
.reveal .slides section > * {
  max-width: 100%;
  box-sizing: border-box;
}

/* --- Stat grid --- */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
  box-sizing: border-box;
}

.stat-item {
  text-align: center;
}

/* ============================================================
   Responsive Breakpoints
   Reveal.js scales the entire slide to fit the viewport.
   These media queries fine-tune content layout at different
   actual viewport widths for better readability.
   ============================================================ */

/* Tablet / Small laptop (≤1024px viewport) */
@media screen and (max-width: 1024px) {
  .reveal { font-size: 28px; }

  .two-column,
  .two-column-wide {
    gap: 1.5rem;
  }

  .three-column {
    gap: 1rem;
  }

  .card {
    padding: 1.2rem;
  }

  .store-layout {
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
  }

  .store-chart-panel {
    grid-column: 1 / -1;
    justify-self: center;
  }

  .device-mockup-tilted {
    transform: perspective(800px) rotateY(-5deg);
  }
}

/* Mobile / Very small viewport (≤768px) */
@media screen and (max-width: 768px) {
  .reveal { font-size: 24px; }

  .reveal .slides section {
    padding: 1rem 1.5rem;
  }

  .two-column,
  .two-column-wide {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .three-column {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .four-column {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.8rem;
  }

  .five-column {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.8rem;
  }

  .store-layout {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .stat-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .device-mockup-tilted {
    transform: none;
  }

  .product-grid {
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem;
  }
}
