/* ========================================
   workyoo Marketing Website — Custom Styles
   ======================================== */

/* --- Base --- */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 5rem;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
    Oxygen, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* --- Scroll Reveal Animation --- */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Staggered children */
.stagger-children > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

.stagger-children.visible > * {
  opacity: 1;
  transform: translateY(0);
}

.stagger-children.visible > *:nth-child(1)  { transition-delay: 0.00s; }
.stagger-children.visible > *:nth-child(2)  { transition-delay: 0.05s; }
.stagger-children.visible > *:nth-child(3)  { transition-delay: 0.10s; }
.stagger-children.visible > *:nth-child(4)  { transition-delay: 0.15s; }
.stagger-children.visible > *:nth-child(5)  { transition-delay: 0.20s; }
.stagger-children.visible > *:nth-child(6)  { transition-delay: 0.25s; }
.stagger-children.visible > *:nth-child(7)  { transition-delay: 0.30s; }
.stagger-children.visible > *:nth-child(8)  { transition-delay: 0.35s; }
.stagger-children.visible > *:nth-child(9)  { transition-delay: 0.40s; }
.stagger-children.visible > *:nth-child(10) { transition-delay: 0.45s; }

/* --- Screenshot Frame --- */
.screenshot-frame {
  background: linear-gradient(135deg, #e0e7ff 0%, #dbeafe 50%, #ede9fe 100%);
  border-radius: 12px;
  position: relative;
  overflow: hidden;
}

.dark .screenshot-frame {
  background: linear-gradient(135deg, #1e293b 0%, #1e3a5f 50%, #312e81 100%);
}

/* macOS window dots */
.screenshot-frame::before {
  content: '';
  position: absolute;
  top: 16px;
  left: 20px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #ef4444;
  box-shadow: 20px 0 0 #eab308, 40px 0 0 #22c55e;
}

/* --- Timeline (Changelog) --- */
.timeline-line {
  position: absolute;
  left: 19px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, #3b82f6, #6366f1);
}

.dark .timeline-line {
  background: linear-gradient(to bottom, #60a5fa, #818cf8);
}

.timeline-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #3b82f6;
  border: 3px solid #fff;
  position: relative;
  z-index: 1;
  flex-shrink: 0;
}

.dark .timeline-dot {
  background: #60a5fa;
  border-color: #1e293b;
}

/* Pulse animation for latest entry */
.timeline-dot-pulse {
  animation: dot-pulse 2s ease-in-out infinite;
}

@keyframes dot-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.5); }
  50%      { box-shadow: 0 0 0 8px rgba(59, 130, 246, 0); }
}

/* --- Navigation --- */
.nav-transparent {
  background: transparent;
}

.nav-solid {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.dark .nav-solid {
  background: rgba(15, 23, 42, 0.95);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

/* Active nav link */
.nav-link {
  position: relative;
  transition: color 0.2s;
}

.nav-link.active {
  color: #2563eb;
}

.dark .nav-link.active {
  color: #60a5fa;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: #2563eb;
  transition: width 0.3s;
  border-radius: 1px;
}

.dark .nav-link::after {
  background: #60a5fa;
}

.nav-link.active::after,
.nav-link:hover::after {
  width: 100%;
}

/* --- Pricing Card Hover --- */
.pricing-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.pricing-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.15);
}

.dark .pricing-card:hover {
  box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.4);
}

/* --- Feature Card --- */
.feature-card {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px -4px rgba(0, 0, 0, 0.1);
}

.dark .feature-card:hover {
  box-shadow: 0 8px 24px -4px rgba(0, 0, 0, 0.3);
}

/* --- News Article Card --- */
.news-card {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.news-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px -8px rgba(0, 0, 0, 0.12);
}

.dark .news-card:hover {
  box-shadow: 0 12px 32px -8px rgba(0, 0, 0, 0.35);
}

/* --- Custom Scrollbar --- */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

.dark ::-webkit-scrollbar-thumb {
  background: #475569;
}

.dark ::-webkit-scrollbar-thumb:hover {
  background: #64748b;
}

/* --- Utility --- */
.text-balance {
  text-wrap: balance;
}

/* View label pills in showcase */
.view-pill {
  transition: background-color 0.2s, color 0.2s;
}

.view-pill:hover {
  background-color: #2563eb;
  color: #fff;
}

.dark .view-pill:hover {
  background-color: #3b82f6;
}

/* Mobile menu animation */
.mobile-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out;
}

.mobile-menu.open {
  max-height: 400px;
}
