/* ========================================
   PREMIUM DESIGN ENHANCEMENTS
   Inspired by Modern SaaS Design Principles
   ======================================== */

/* 1. Enhanced Spacing & Breathing Room */
.section-ultra-spacing {
  padding: 120px 0;
}

.section-mega-spacing {
  padding: 160px 0;
}

/* 2. Typography Hierarchy Enhancement */
.text-hero {
  font-size: 72px;
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.text-display {
  font-size: 56px;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.025em;
}

.text-headline {
  font-size: 40px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.text-subheadline {
  font-size: 24px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--gray-600);
  max-width: 700px;
}

.text-caption {
  font-size: 13px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--gray-500);
}

/* 3. Glass Morphism Cards */
.glass-card {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 24px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
}

/* 4. Neumorphism Effect */
.neu-card {
  background: #f8f9fa;
  box-shadow: 20px 20px 60px #d1d5db,
              -20px -20px 60px #ffffff;
  border-radius: 24px;
}

/* 5. Gradient Border */
.gradient-border {
  position: relative;
  background: white;
  border-radius: 20px;
}

.gradient-border::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: 22px;
  padding: 2px;
  background: linear-gradient(135deg, #60a5fa, #a78bfa, #f472b6);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.3s;
}

.gradient-border:hover::before {
  opacity: 1;
}

/* 6. Floating Action Button */
.fab {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent-purple));
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  box-shadow: 0 8px 24px rgba(26, 95, 165, 0.4);
  cursor: pointer;
  z-index: 1000;
  transition: all 0.3s;
  animation: fabPulse 2s ease-in-out infinite;
}

.fab:hover {
  transform: scale(1.1) translateY(-4px);
  box-shadow: 0 12px 32px rgba(26, 95, 165, 0.6);
}

@keyframes fabPulse {
  0%, 100% { box-shadow: 0 8px 24px rgba(26, 95, 165, 0.4); }
  50% { box-shadow: 0 8px 24px rgba(26, 95, 165, 0.6), 0 0 0 12px rgba(26, 95, 165, 0.1); }
}

/* 7. Progress Indicator */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--accent-purple));
  z-index: 9999;
  transition: width 0.1s;
}

/* 8. Minimalist Section Dividers */
.section-divider {
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--accent-purple));
  border-radius: 2px;
  margin: 0 auto 40px;
}

/* 9. Asymmetric Grid Layout */
.asymmetric-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 80px;
  align-items: center;
}

.asymmetric-grid.reverse {
  grid-template-columns: 1fr 1.5fr;
}

/* 10. Sticky Section Headers */
.sticky-header {
  position: sticky;
  top: 120px;
  padding: 40px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  z-index: 10;
}

/* 11. Mega Menu Enhancement */
.mega-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  width: 90vw;
  max-width: 1200px;
  background: white;
  border-radius: 24px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
  padding: 48px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-item:hover .mega-menu {
  opacity: 1;
  visibility: visible;
  top: calc(100% + 16px);
}

/* 12. Micro-interactions */
.micro-hover {
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.micro-hover:hover {
  transform: translateY(-2px);
}

.micro-hover:active {
  transform: translateY(0) scale(0.98);
}

/* 13. Badge System */
.badge-new {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-beta {
  background: linear-gradient(135deg, #f59e0b, #d97706);
}

.badge-soon {
  background: linear-gradient(135deg, #6b7280, #4b5563);
}

/* 14. Skeleton Loading */
.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  border-radius: 8px;
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* 15. Enhanced CTA Buttons */
.btn-mega {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 20px 48px;
  font-size: 18px;
  font-weight: 700;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--primary), var(--accent-purple));
  color: white;
  box-shadow: 0 12px 32px rgba(26, 95, 165, 0.4);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.btn-mega::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s;
}

.btn-mega:hover::before {
  left: 100%;
}

.btn-mega:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 16px 48px rgba(26, 95, 165, 0.6);
}

.btn-ghost {
  background: transparent;
  border: 2px solid var(--gray-300);
  color: var(--gray-700);
  box-shadow: none;
}

.btn-ghost:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: rgba(26, 95, 165, 0.05);
}

/* 16. Text Reveal Animation */
.text-reveal {
  overflow: hidden;
}

.text-reveal span {
  display: inline-block;
  transform: translateY(100%);
  animation: revealText 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes revealText {
  to { transform: translateY(0); }
}

/* 17. Image Mask Reveal */
.mask-reveal {
  position: relative;
  overflow: hidden;
}

.mask-reveal::after {
  content: '';
  position: absolute;
  inset: 0;
  background: white;
  transform: scaleX(1);
  transform-origin: right;
  transition: transform 1s cubic-bezier(0.4, 0, 0.2, 1);
}

.mask-reveal.revealed::after {
  transform: scaleX(0);
}

/* 18. Horizontal Scroll Section */
.horizontal-scroll {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 32px;
  padding: 40px 0;
  -webkit-overflow-scrolling: touch;
}

.horizontal-scroll > * {
  scroll-snap-align: start;
  flex-shrink: 0;
}

/* 19. Tooltip Enhancement */
.tooltip {
  position: relative;
}

.tooltip::before {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(-8px);
  padding: 8px 16px;
  background: var(--gray-900);
  color: white;
  border-radius: 8px;
  font-size: 13px;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s;
}

.tooltip:hover::before {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(-4px);
}

/* 20. Section Numbering */
.section-number {
  font-size: 120px;
  font-weight: 900;
  color: var(--gray-200);
  position: absolute;
  top: -40px;
  left: -20px;
  z-index: 0;
  line-height: 1;
}

/* 21. Cursor Enhancement */
.cursor-dot {
  width: 8px;
  height: 8px;
  background: var(--primary);
  border-radius: 50%;
  position: fixed;
  pointer-events: none;
  z-index: 99999;
  transition: transform 0.1s;
}

.cursor-outline {
  width: 40px;
  height: 40px;
  border: 2px solid rgba(26, 95, 165, 0.5);
  border-radius: 50%;
  position: fixed;
  pointer-events: none;
  z-index: 99998;
  transition: all 0.15s ease-out;
}

/* 22. Smooth Page Transitions */
.page-transition {
  animation: pageIn 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* 23. Enhanced Focus States */
.focus-ring:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(26, 95, 165, 0.3);
  ring: 3px solid var(--primary);
}

/* 24. Dark Mode Preparation */
@media (prefers-color-scheme: dark) {
  :root {
    --bg-primary: #0a0a0a;
    --bg-secondary: #1a1a1a;
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
  }
}

/* 25. Responsive Typography */
@media (max-width: 768px) {
  .text-hero {
    font-size: 40px;
  }
  
  .text-display {
    font-size: 36px;
  }
  
  .text-headline {
    font-size: 28px;
  }
  
  .asymmetric-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

/* 26. Print Stylesheet */
@media print {
  .fab, .scroll-progress, .particle-bg {
    display: none;
  }
  
  body {
    background: white;
    color: black;
  }
  
  a {
    text-decoration: underline;
  }
}

/* 27. Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* 28. Utility Classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mx-auto { margin-left: auto; margin-right: auto; }

.space-y-4 > * + * { margin-top: 16px; }
.space-y-8 > * + * { margin-top: 32px; }
.space-y-12 > * + * { margin-top: 48px; }
.space-y-16 > * + * { margin-top: 64px; }

.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }

@media (max-width: 1024px) {
  .grid-3, .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .grid-2, .grid-3, .grid-4 {
    grid-template-columns: 1fr;
  }
}
