@import "tailwindcss";

@theme {
  --color-primary: #0439C7;
  --color-background: #050505;
  --color-surface: #0F0F0F;

  --font-display: "Sora", sans-serif;
  --font-handwriting: "Delicious Handrawn", cursive;

  --animate-liquid: liquid 15s ease-in-out infinite;
  --animate-scroll: scroll 40s linear infinite;

  @keyframes liquid {

    0%,
    100% {
      transform: translate3d(0, 0, 0) scale(1);
    }

    50% {
      transform: translate3d(35px, -35px, 0) scale(1.08);
    }
  }

  @keyframes scroll {
    from {
      transform: translateX(0);
    }

    to {
      transform: translateX(-50%);
    }
  }
}

/* Optimized Scroll Animations */
@layer utilities {
  .reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
    will-change: opacity, transform;
    /* Hardware acceleration hint */
  }

  .reveal.active {
    opacity: 1;
    transform: translateY(0);
  }

  /* Stagger delays for children */
  .reveal-delay-100 {
    transition-delay: 100ms;
  }

  .reveal-delay-200 {
    transition-delay: 200ms;
  }

  .reveal-delay-300 {
    transition-delay: 300ms;
  }

  /* Modal Animations */
  .animate-fade-in {
    animation: fadeIn 0.3s ease-out;
  }

  .animate-scale-in {
    animation: scaleIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  }

  @keyframes fadeIn {
    from {
      opacity: 0;
    }

    to {
      opacity: 1;
    }
  }

  @keyframes scaleIn {
    from {
      opacity: 0;
      transform: scale(0.9);
    }

    to {
      opacity: 1;
      transform: scale(1);
    }
  }
}

/* Smooth Scrolling for Anchor Links */
html {
  scroll-behavior: smooth;
}

/* Custom Styles moved from index.html */
:root {
  --primary: #FACC15;
  --background: #050505;
  --surface: #0F0F0F;
}

body {
  font-family: 'Sora', sans-serif;
}

.font-handwriting {
  font-family: 'Delicious Handrawn', cursive;
}

/* Design System Classes */

.neon-border {
  border: 1px solid rgba(128, 198, 253, 0.3);
  box-shadow: 0 0 20px rgba(128, 198, 253, 0.15);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.neon-border:hover {
  border-color: #80C6FD;
  box-shadow: 0 0 40px rgba(128, 198, 253, 0.4);
  transform: translateY(-2px);
}

.glass-card {
  background: rgba(15, 15, 15, 0.7);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(250, 204, 21, 0.1);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

.highlight-text {
  background: linear-gradient(180deg, #6090FF 0%, #0439C7 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 15px rgba(4, 57, 199, 0.3));
}

.cta-glow {
  box-shadow: 0 0 25px rgba(128, 198, 253, 0.5);
}

.cta-glow:hover {
  box-shadow: 0 0 40px rgba(128, 198, 253, 0.7);
}

/* Section Background Glow */
.section-glow {
  position: relative;
}

.section-glow::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80%;
  height: 80%;
  background: radial-gradient(circle, rgba(250, 204, 21, 0.04) 0%, transparent 70%);
  pointer-events: none;
  z-index: -1;
}

/* Lightweight YouTube embed */
.lite-youtube {
  border-radius: 2rem;
  background: radial-gradient(circle at top, rgba(4, 57, 199, 0.25), rgba(5, 5, 5, 0.9));
}

.lite-youtube__poster {
  position: relative;
  width: 100%;
  height: 100%;
  border: 0;
  padding: 0;
  cursor: pointer;
  display: block;
  background: transparent;
}

.lite-youtube__poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.lite-youtube__poster:hover img {
  transform: scale(1.03);
}

.lite-youtube__scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.15), rgba(0, 0, 0, 0.65));
  pointer-events: none;
}

.lite-youtube__play {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
}

.lite-youtube__play-btn {
  width: 88px;
  height: 62px;
  border-radius: 999px;
  background: linear-gradient(135deg, #ff4d4d, #c80000);
  box-shadow: 0 12px 40px rgba(255, 0, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.lite-youtube__play-icon {
  width: 0;
  height: 0;
  border-top: 12px solid transparent;
  border-bottom: 12px solid transparent;
  border-left: 20px solid #fff;
  margin-left: 4px;
}

.lite-youtube__poster:hover .lite-youtube__play-btn {
  transform: scale(1.05);
  box-shadow: 0 18px 50px rgba(255, 0, 0, 0.55);
}

@media (prefers-reduced-motion: reduce) {
  .lite-youtube__poster img,
  .lite-youtube__play-btn {
    transition: none;
  }
}

/* ── STICKY BOTTOM BAR ── */
.sticky-bottom {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 450;
  background: rgba(15, 15, 15, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 -4px 30px rgba(0, 0, 0, 0.4);
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  font-family: 'Sora', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  transform: translateY(100%);
  animation: sb-slide-up 0.5s ease 1.5s forwards;
}

@keyframes sb-slide-up {
  to { transform: translateY(0); }
}

.sb-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sb-label {
  font-size: 13px;
  font-weight: 700;
  color: #94A3B8;
  white-space: nowrap;
}

.sb-timer {
  display: flex;
  align-items: center;
  gap: 4px;
}

.sb-timer-seg {
  font-size: 18px;
  font-weight: 800;
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  padding: 4px 8px;
  min-width: 36px;
  text-align: center;
  transition: color 0.3s, border-color 0.3s;
}

.sb-timer-colon {
  font-size: 18px;
  font-weight: 800;
  color: #64748B;
}

.sb-timer.urgent .sb-timer-seg {
  color: #F43F5E;
  border-color: rgba(244, 63, 94, 0.4);
}
.sb-timer.urgent .sb-timer-colon {
  color: #F43F5E;
}

.sb-viewers {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #94A3B8;
}

.sb-viewers-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4ADE80;
  animation: sb-blink 1s ease infinite;
}

@keyframes sb-blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.sb-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #FACC15;
  color: #000;
  font-size: 14px;
  font-weight: 800;
  padding: 10px 24px;
  border-radius: 9999px;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 0 20px rgba(250, 204, 21, 0.3);
  white-space: nowrap;
  animation: sb-cta-pulse 2.5s ease infinite;
}

.sb-cta:hover {
  transform: scale(1.04);
  box-shadow: 0 0 40px rgba(250, 204, 21, 0.5);
}

@keyframes sb-cta-pulse {
  0%, 100% { box-shadow: 0 0 20px rgba(250, 204, 21, 0.3); }
  50%      { box-shadow: 0 0 35px rgba(250, 204, 21, 0.5); }
}

body { padding-bottom: 80px; }

@media (max-width: 600px) {
  .sticky-bottom { gap: 10px; padding: 10px 14px; }
  .sb-label { font-size: 11px; white-space: normal; }
  .sb-timer-seg { font-size: 15px; padding: 3px 6px; min-width: 30px; }
  .sb-timer-colon { font-size: 15px; }
  .sb-cta { font-size: 12px; padding: 8px 16px; }
  .sb-viewers { display: none; }
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #0F0F0F;
}

::-webkit-scrollbar-thumb {
  background: #333;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #FACC15;
}