/* ============================================
   Yantrik - Shared Styles
   Dark theme with teal accent
   ============================================ */

/* CSS Variables */
:root {
  /* Colors */
  --bg-primary: #0a0a0f;
  --bg-secondary: #11131a;
  --bg-card: #14161f;
  --bg-card-hover: #1a1d28;
  --accent: #2dd4bf;
  --accent-dim: rgba(45, 212, 191, 0.15);
  --accent-glow: rgba(45, 212, 191, 0.3);
  --text-primary: #f2f5fa;
  --text-secondary: #a7b0c8;
  --text-muted: #6b7280;
  --border: rgba(242, 245, 250, 0.08);
  --border-strong: rgba(242, 245, 250, 0.15);
  
  /* Typography */
  --font-display: 'Space Grotesk', 'Sora', sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;
  --font-mono: 'IBM Plex Mono', 'Fira Code', monospace;
  
  /* Spacing */
  --section-padding: 6rem;
  --container-max: 1400px;
  
  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-base: 0.25s ease;
  --transition-slow: 0.4s ease;
  
  /* Shadows */
  --shadow-card: 0 18px 50px rgba(0, 0, 0, 0.55);
  --shadow-glow: 0 10px 30px rgba(45, 212, 191, 0.1);
  --shadow-glow-strong: 0 0 40px rgba(45, 212, 191, 0.2);
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
}

/* Background Grid Pattern */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    linear-gradient(rgba(45, 212, 191, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(45, 212, 191, 0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
  z-index: -2;
}

/* Grain Overlay */
body::after {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  opacity: 0.04;
  pointer-events: none;
  z-index: -1;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

h1 {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
}

h2 {
  font-size: clamp(2rem, 3.5vw, 3rem);
}

h3 {
  font-size: clamp(1.25rem, 2vw, 1.5rem);
}

p {
  color: var(--text-secondary);
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--accent);
}

/* Container */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ============================================
   Navigation
   ============================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 1rem 0;
  background: rgba(10, 10, 15, 0.8);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  transition: all var(--transition-base);
}

.navbar.scrolled {
  padding: 0.75rem 0;
  background: rgba(10, 10, 15, 0.95);
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.logo-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}

.logo-icon img {
  width: 32px;
  height: 32px;
  object-fit: contain;
  display: block;
}

.logo-img {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  object-fit: contain;
  object-position: center;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width var(--transition-base);
}

.nav-links a:hover {
  color: var(--text-primary);
}

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

.nav-cta {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 5px;
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  transition: all var(--transition-base);
}

/* ============================================
   Buttons
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: 12px;
  cursor: pointer;
  transition: all var(--transition-base);
  border: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: var(--bg-primary);
  box-shadow: var(--shadow-glow);
}

.btn-primary:hover {
  background: #5eead4;
  box-shadow: var(--shadow-glow-strong);
  transform: translateY(-2px);
  color: var(--bg-primary);
}

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-strong);
}

.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

.btn-outline {
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
}

.btn-outline:hover {
  background: var(--accent-dim);
  transform: translateY(-2px);
}

.btn-large {
  padding: 1rem 2rem;
  font-size: 1rem;
}

.btn-icon {
  width: 20px;
  height: 20px;
}

/* ============================================
   Cards
   ============================================ */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.5rem;
  transition: all var(--transition-base);
}

.card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-strong);
  transform: translateY(-4px);
  box-shadow: var(--shadow-card);
}

.card-glow:hover {
  border-color: rgba(45, 212, 191, 0.3);
  box-shadow: 0 0 30px rgba(45, 212, 191, 0.1);
}

/* ============================================
   Chips / Tags
   ============================================ */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.9rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: var(--accent-dim);
  color: var(--accent);
  border-radius: 999px;
  border: 1px solid rgba(45, 212, 191, 0.2);
}

.chip-small {
  padding: 0.25rem 0.6rem;
  font-size: 0.65rem;
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 0.7rem;
  font-size: 0.75rem;
  font-weight: 500;
  background: var(--bg-secondary);
  color: var(--text-secondary);
  border-radius: 6px;
  border: 1px solid var(--border);
}

/* ============================================
   Feature Cards (for Features page)
   ============================================ */
.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 2rem;
  transition: all var(--transition-base);
  height: 100%;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.feature-card:hover {
  background: var(--bg-card-hover);
  border-color: rgba(45, 212, 191, 0.25);
  transform: translateY(-6px);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 30px rgba(45, 212, 191, 0.08);
}

.feature-icon {
  width: 48px;
  height: 48px;
  background: var(--accent-dim);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.feature-icon svg {
  width: 24px;
  height: 24px;
}

.feature-card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.25rem;
}

.feature-card p {
  font-size: 0.9rem;
  line-height: 1.6;
  flex-grow: 1;
}

/* ============================================
   Pricing Cards
   ============================================ */
.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 2.5rem 2rem;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.pricing-card:hover {
  transform: translateY(-8px);
  border-color: rgba(45, 212, 191, 0.3);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5), 0 0 40px rgba(45, 212, 191, 0.1);
}

.pricing-card.featured {
  border-color: var(--accent);
  background: linear-gradient(180deg, var(--bg-card) 0%, rgba(45, 212, 191, 0.05) 100%);
}

.pricing-card.featured::before {
  content: 'Most Popular';
  position: absolute;
  top: 0;
  right: 0;
  background: var(--accent);
  color: var(--bg-primary);
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.4rem 1rem;
  border-bottom-left-radius: 12px;
}

.pricing-header {
  margin-bottom: 1.5rem;
}

.pricing-name {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.pricing-price {
  display: flex;
  align-items: baseline;
  gap: 0.25rem;
}

.pricing-price .currency {
  font-size: 1.25rem;
  color: var(--accent);
}

.pricing-price .amount {
  font-size: 3rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
}

.pricing-price .period {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.pricing-features {
  list-style: none;
  margin: 1.5rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.pricing-features li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.pricing-features li::before {
  content: '✓';
  width: 20px;
  height: 20px;
  background: var(--accent-dim);
  color: var(--accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  flex-shrink: 0;
}

/* ============================================
   Banner
   ============================================ */
.banner {
  background: linear-gradient(90deg, rgba(45, 212, 191, 0.15), rgba(45, 212, 191, 0.05));
  border: 1px solid rgba(45, 212, 191, 0.25);
  border-radius: 12px;
  padding: 1rem 1.5rem;
  text-align: center;
  margin-bottom: 2rem;
}

.banner-text {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent);
  font-weight: 500;
}

/* ============================================
   Countdown
   ============================================ */
.countdown {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin: 2rem 0;
}

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

.countdown-value {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
  min-width: 60px;
}

.countdown-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-top: 0.5rem;
}

/* ============================================
   Forum / Project Cards
   ============================================ */
.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.25rem;
  transition: all var(--transition-base);
}

.project-card:hover {
  border-color: rgba(45, 212, 191, 0.25);
  transform: translateY(-3px);
}

.project-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.project-name {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
}

.project-status {
  width: 8px;
  height: 8px;
  background: #22c55e;
  border-radius: 50%;
  box-shadow: 0 0 8px #22c55e;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.project-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 1rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.project-meta span {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

/* ============================================
   Footer
   ============================================ */
.footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 4rem 0 2rem;
  margin-top: 4rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-brand p {
  margin-top: 1rem;
  font-size: 0.9rem;
  max-width: 280px;
}

.footer-links h4 {
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.footer-links ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.footer-links a {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.footer-links a:hover {
  color: var(--accent);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}

.footer-bottom p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ============================================
   Animations
   ============================================ */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

@keyframes glow {
  0%, 100% { box-shadow: 0 0 20px rgba(45, 212, 191, 0.2); }
  50% { box-shadow: 0 0 40px rgba(45, 212, 191, 0.4); }
}

.animate-fade-in-up {
  animation: fadeInUp 0.6s ease forwards;
}

.animate-fade-in {
  animation: fadeIn 0.5s ease forwards;
}

.animate-slide-in-left {
  animation: slideInLeft 0.6s ease forwards;
}

.animate-slide-in-right {
  animation: slideInRight 0.6s ease forwards;
}

.animate-float {
  animation: float 3s ease-in-out infinite;
}

/* Stagger delays */
.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }
.delay-500 { animation-delay: 0.5s; }

/* Initial state for scroll animations */
.scroll-animate {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.scroll-animate.visible {
  opacity: 1;
  transform: translateY(0);
}

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

.text-accent { color: var(--accent); }
.text-muted { color: var(--text-muted); }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.mb-5 { margin-bottom: 3rem; }

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mt-5 { margin-top: 3rem; }

.hidden { display: none; }

/* ============================================
   Section Styles
   ============================================ */
.section {
  padding: var(--section-padding) 0;
}

.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 3rem;
}

.section-header h2 {
  margin-bottom: 1rem;
}

.section-header p {
  font-size: 1.1rem;
}

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 80px;
  position: relative;
  overflow: hidden;
}

.hero-glow {
  position: absolute;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(45, 212, 191, 0.15) 0%, transparent 70%);
  border-radius: 50%;
  top: 50%;
  right: 10%;
  transform: translateY(-50%);
  pointer-events: none;
  z-index: -1;
}

.hero-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.hero-text h1 {
  font-size: clamp(2.8rem, 5.5vw, 5rem);
  font-weight: 800;
  line-height: 1.05;
  margin-bottom: 1.5rem;
  text-transform: uppercase;
}

.hero-text .tagline {
  font-size: clamp(1.1rem, 1.5vw, 1.35rem);
  color: var(--text-secondary);
  margin-bottom: 2rem;
  max-width: 500px;
  line-height: 1.6;
}

.hero-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 2.5rem;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.hero-visual {
  position: relative;
}

.hero-image {
  width: 100%;
  border-radius: 16px;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border);
}

/* Features Grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

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

.features-grid-4 {
  grid-template-columns: repeat(4, 1fr);
}

/* Pricing Grid */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  max-width: 1100px;
  margin: 0 auto;
}

/* Download Section */
.download-section {
  min-height: 80vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 6rem 1.5rem;
}

.download-icon {
  width: 120px;
  height: 120px;
  background: linear-gradient(135deg, var(--accent), #14b8a6);
  border-radius: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 2rem;
  box-shadow: var(--shadow-glow-strong);
}

.download-icon svg {
  width: 60px;
  height: 60px;
  color: var(--bg-primary);
}

.download-section h1 {
  margin-bottom: 1rem;
}

.download-section .version {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
}

.download-section .release-notes {
  font-size: 0.9rem;
  color: var(--text-secondary);
  max-width: 500px;
  margin: 1.5rem auto;
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 1024px) {
  .features-grid-3,
  .features-grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .pricing-grid {
    grid-template-columns: 1fr;
    max-width: 400px;
  }
  
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-secondary);
    flex-direction: column;
    padding: 1.5rem;
    gap: 1rem;
    border-bottom: 1px solid var(--border);
  }
  
  .nav-links.active {
    display: flex;
  }
  
  .menu-toggle {
    display: flex;
  }
  
  .nav-cta {
    display: none;
  }
  
  .hero-content {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .hero-text .tagline {
    margin-left: auto;
    margin-right: auto;
  }
  
  .hero-chips {
    justify-content: center;
  }
  
  .hero-ctas {
    justify-content: center;
  }
  
  .hero-visual {
    order: -1;
  }
  
  .features-grid,
  .features-grid-3,
  .features-grid-4 {
    grid-template-columns: 1fr;
  }
  
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .footer-bottom {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
  
  .countdown {
    gap: 1rem;
  }
  
  .countdown-value {
    font-size: 2rem;
    min-width: 50px;
  }
}

@media (max-width: 480px) {
  .hero-text h1 {
    font-size: 2.2rem;
  }
  
  .btn {
    width: 100%;
  }
  
  .hero-ctas {
    flex-direction: column;
  }
  
  .countdown-value {
    font-size: 1.5rem;
    min-width: 40px;
  }
}