/* =============================================
   Coyn — Budget & Expense Tracker
   Design: Deep Violet (2026 Dark Luxury)
   ============================================= */

:root {
  --bg-0: #07040F;
  --bg-1: #0D0A1A;
  --bg-2: #160F2E;
  --bg-3: #1E1640;
  --bg-card: #120E22;
  --bg-card2: #1A1430;

  --accent: #7C3AED;
  --accent-2: #9B5CF6;
  --accent-light: #A78BFA;
  --accent-glow: rgba(124, 58, 237, 0.35);
  --accent-glow2: rgba(167, 139, 250, 0.15);

  --teal: #2DD4BF;
  --teal-dim: rgba(45, 212, 191, 0.7);
  --red: #F87171;
  --green: #4ADE80;

  --text-primary: #FFFFFF;
  --text-secondary: #C4B5FD;
  --text-muted: #7C6EAA;
  --text-dimmer: #4A3F6B;

  --border: rgba(124, 58, 237, 0.2);
  --border-light: rgba(167, 139, 250, 0.1);

  --radius: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;

  --shadow: 0 4px 24px rgba(0,0,0,0.4);
  --shadow-glow: 0 0 40px var(--accent-glow);

  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --max-width: 1200px;
  --nav-height: 72px;
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--bg-0);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }

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

/* ============ TYPOGRAPHY ============ */
.gradient-text {
  background: linear-gradient(135deg, var(--accent-light) 0%, var(--teal) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ============ BUTTONS ============ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 100px;
  font-size: 15px;
  font-weight: 600;
  transition: all 0.25s ease;
  white-space: nowrap;
  cursor: pointer;
}
.btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
  color: #fff;
  box-shadow: 0 4px 20px var(--accent-glow);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(124,58,237,0.55);
}
.btn-ghost {
  color: var(--text-secondary);
  border: 1px solid var(--border);
  background: transparent;
}
.btn-ghost:hover {
  background: var(--border-light);
  color: var(--text-primary);
  border-color: var(--accent-light);
}
.btn-nav {
  padding: 9px 22px;
  font-size: 14px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
  color: #fff;
  border-radius: 100px;
}
.btn-nav:hover {
  box-shadow: 0 4px 16px var(--accent-glow);
  transform: translateY(-1px);
}
.btn-large {
  padding: 18px 40px;
  font-size: 17px;
}

/* ============ HEADER ============ */
.header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-height);
  transition: background 0.3s ease, backdrop-filter 0.3s ease, box-shadow 0.3s ease;
}
.header.scrolled {
  background: rgba(7, 4, 15, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 1px 0 var(--border);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--nav-height);
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
}
.nav-logo-img {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  flex-shrink: 0;
}
.nav-logo-text {
  font-size: 20px;
  font-weight: 800;
  background: linear-gradient(135deg, #fff 0%, var(--accent-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-links li a {
  padding: 8px 14px;
  font-size: 15px;
  color: var(--text-secondary);
  border-radius: 8px;
  transition: color 0.2s;
}
.nav-links li a:hover {
  color: var(--text-primary);
}
.burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  border-radius: 8px;
}
.burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-secondary);
  border-radius: 2px;
  transition: all 0.3s ease;
}
.burger.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.burger.active span:nth-child(2) { opacity: 0; }
.burger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ============ HERO ============ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: calc(var(--nav-height) + 60px) 0 80px;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 70% 40%, rgba(124,58,237,0.18) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 20% 80%, rgba(45,212,191,0.08) 0%, transparent 60%),
    linear-gradient(180deg, var(--bg-1) 0%, var(--bg-0) 100%);
  z-index: 0;
}
.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(124,58,237,0.12);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 13px;
  font-weight: 500;
  color: var(--accent-light);
  margin-bottom: 24px;
}
.badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 6px var(--teal);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}
.hero-title {
  font-size: clamp(40px, 5.5vw, 72px);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
}
.hero-subtitle {
  font-size: 18px;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 500px;
  margin-bottom: 36px;
}
.hero-cta {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 48px;
}
.hero-stats {
  display: flex;
  align-items: center;
  gap: 24px;
}
.stat {
  display: flex;
  flex-direction: column;
}
.stat-value {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
}
.stat-label {
  font-size: 12px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.stat-divider {
  width: 1px;
  height: 36px;
  background: var(--border);
}

/* Phone mockup */
.hero-phone {
  display: flex;
  justify-content: center;
  align-items: center;
}
.phone-mockup {
  position: relative;
}
.phone-glow {
  position: absolute;
  inset: -40px;
  background: radial-gradient(ellipse 60% 70% at 50% 50%, var(--accent-glow), transparent 70%);
  z-index: -1;
  filter: blur(20px);
}
.phone-frame {
  width: 280px;
  background: var(--bg-card);
  border-radius: 44px;
  border: 2px solid rgba(124,58,237,0.3);
  overflow: hidden;
  box-shadow:
    0 0 0 8px rgba(7,4,15,0.8),
    0 40px 80px rgba(0,0,0,0.7),
    0 0 60px var(--accent-glow);
}
.phone-screen {
  width: 100%;
  display: block;
  border-radius: 42px;
}

/* Hero scroll indicator */
.hero-scroll-indicator {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  z-index: 1;
}
.scroll-line {
  width: 1px;
  height: 32px;
  background: linear-gradient(to bottom, var(--text-muted), transparent);
  animation: scrollAnim 1.8s ease-in-out infinite;
}
@keyframes scrollAnim {
  0% { transform: scaleY(0); transform-origin: top; opacity: 1; }
  50% { transform: scaleY(1); transform-origin: top; opacity: 1; }
  100% { transform: scaleY(1); transform-origin: bottom; opacity: 0; }
}

/* ============ SECTION HEADERS ============ */
.section-header {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 60px;
}
.section-tag {
  display: inline-block;
  padding: 6px 14px;
  background: rgba(124,58,237,0.12);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 13px;
  font-weight: 500;
  color: var(--accent-light);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 16px;
}
.section-title {
  font-size: clamp(28px, 3.5vw, 44px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.025em;
  margin-bottom: 16px;
}
.section-subtitle {
  font-size: 17px;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ============ FEATURES ============ */
.features {
  padding: 100px 0;
  background: linear-gradient(180deg, var(--bg-0) 0%, var(--bg-1) 50%, var(--bg-0) 100%);
}
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
}
.feature-card:hover {
  border-color: var(--border);
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0,0,0,0.3), 0 0 20px var(--accent-glow2);
}
.feature-icon {
  width: 56px;
  height: 56px;
  background: rgba(124,58,237,0.15);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-light);
  margin-bottom: 20px;
}
.feature-card h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--text-primary);
}
.feature-card p {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ============ SCREENSHOTS ============ */
.screenshots {
  padding: 100px 0;
  overflow: hidden;
}
.screenshots-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 20px 0;
  margin: 0 -24px;
}
.screenshots-scroll::-webkit-scrollbar { display: none; }
.screenshots-track {
  display: flex;
  gap: 24px;
  padding: 0 24px;
  width: max-content;
}
.screenshot-item {
  flex-shrink: 0;
  text-align: center;
}
.screenshot-item img {
  width: 220px;
  border-radius: 28px;
  border: 2px solid rgba(124,58,237,0.2);
  box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 20px var(--accent-glow2);
  transition: transform 0.3s, box-shadow 0.3s;
}
.screenshot-item:hover img {
  transform: translateY(-6px);
  box-shadow: 0 30px 80px rgba(0,0,0,0.6), 0 0 30px var(--accent-glow);
}
.screenshot-item figcaption {
  margin-top: 14px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ============ CTA SECTION ============ */
.cta-section {
  padding: 100px 0;
  background: var(--bg-1);
}
.cta-card {
  position: relative;
  background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-card2) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 80px 40px;
  text-align: center;
  overflow: hidden;
}
.cta-glow {
  position: absolute;
  top: -60px;
  left: 50%;
  transform: translateX(-50%);
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, var(--accent-glow), transparent 70%);
  pointer-events: none;
}
.cta-content {
  position: relative;
  z-index: 1;
}
.cta-icon {
  width: 80px;
  height: 80px;
  border-radius: 20px;
  margin: 0 auto 24px;
  box-shadow: 0 8px 32px var(--accent-glow);
}
.cta-card h2 {
  font-size: clamp(26px, 3vw, 40px);
  font-weight: 800;
  letter-spacing: -0.025em;
  margin-bottom: 16px;
}
.cta-card p {
  font-size: 18px;
  color: var(--text-secondary);
  max-width: 480px;
  margin: 0 auto 36px;
}
.cta-note {
  font-size: 13px !important;
  color: var(--text-muted) !important;
  margin-top: 16px !important;
  margin-bottom: 0 !important;
}

/* ============ FOOTER ============ */
.footer {
  background: var(--bg-0);
  border-top: 1px solid var(--border-light);
  padding: 60px 0 32px;
}
.footer-top {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 60px;
  margin-bottom: 48px;
}
.footer-brand p {
  font-size: 14px;
  color: var(--text-muted);
  margin-top: 12px;
  max-width: 260px;
  line-height: 1.6;
}
.footer-nav {
  display: flex;
  gap: 48px;
}
.footer-nav-col {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer-nav-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 4px;
}
.footer-nav-col a {
  font-size: 14px;
  color: var(--text-secondary);
  transition: color 0.2s;
}
.footer-nav-col a:hover {
  color: var(--accent-light);
}
.footer-bottom {
  border-top: 1px solid var(--border-light);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.footer-bottom p {
  font-size: 13px;
  color: var(--text-muted);
}
.footer-bottom a {
  color: var(--text-muted);
  transition: color 0.2s;
}
.footer-bottom a:hover {
  color: var(--accent-light);
}

/* ============ PAGE HERO (inner pages) ============ */
.page-hero {
  padding: calc(var(--nav-height) + 60px) 0 60px;
  background: linear-gradient(180deg, var(--bg-1) 0%, var(--bg-0) 100%);
  border-bottom: 1px solid var(--border-light);
}
.page-hero h1 {
  font-size: clamp(32px, 4vw, 52px);
  font-weight: 800;
  letter-spacing: -0.025em;
  margin-bottom: 12px;
}
.page-hero .last-updated {
  font-size: 14px;
  color: var(--text-muted);
  margin-top: 8px;
}

/* ============ PROSE (legal/support pages) ============ */
.prose-section {
  padding: 80px 0 100px;
}
.prose {
  max-width: 760px;
  margin: 0 auto;
}
.prose h2 {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 44px 0 14px;
  letter-spacing: -0.01em;
}
.prose h2:first-child { margin-top: 0; }
.prose h3 {
  font-size: 17px;
  font-weight: 600;
  color: var(--text-secondary);
  margin: 28px 0 10px;
}
.prose p {
  font-size: 16px;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 16px;
}
.prose ul, .prose ol {
  padding-left: 24px;
  margin-bottom: 16px;
}
.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }
.prose li {
  font-size: 16px;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 8px;
}
.prose a {
  color: var(--accent-light);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.prose a:hover { color: var(--teal); }
.prose strong { color: var(--text-primary); font-weight: 600; }
.prose hr {
  border: none;
  border-top: 1px solid var(--border-light);
  margin: 40px 0;
}

/* ============ BLOG ============ */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  margin-top: 60px;
}
.blog-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: border-color 0.3s, transform 0.3s;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.blog-card:hover {
  border-color: var(--border);
  transform: translateY(-3px);
}
.blog-tag {
  display: inline-block;
  padding: 4px 12px;
  background: rgba(124,58,237,0.12);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 12px;
  font-weight: 500;
  color: var(--accent-light);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  width: fit-content;
}
.blog-card h3 {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text-primary);
}
.blog-card p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
  flex: 1;
}
.blog-meta {
  font-size: 13px;
  color: var(--text-dimmer);
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
}
.coming-soon-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: rgba(45,212,191,0.08);
  border: 1px solid rgba(45,212,191,0.2);
  border-radius: 100px;
  font-size: 12px;
  font-weight: 600;
  color: var(--teal);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ============ SUPPORT ============ */
.support-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin-bottom: 60px;
}
.support-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: border-color 0.25s, transform 0.25s;
}
.support-card:hover {
  border-color: var(--border);
  transform: translateY(-2px);
}
.support-icon {
  width: 48px;
  height: 48px;
  background: rgba(124,58,237,0.15);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-light);
  margin-bottom: 16px;
}
.support-card h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}
.support-card p {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 16px;
}
.support-card a.btn {
  width: 100%;
  justify-content: center;
}
.faq-list {
  max-width: 760px;
  margin: 0 auto;
}
.faq-item {
  border-bottom: 1px solid var(--border-light);
  padding: 24px 0;
}
.faq-item:first-child { padding-top: 0; }
.faq-question {
  font-size: 17px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 10px;
}
.faq-answer {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ============ FADE-IN ANIMATION ============ */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============ RESPONSIVE ============ */
@media (max-width: 1024px) {
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .blog-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  :root { --nav-height: 64px; }

  /* Nav */
  .burger { display: flex; }
  .nav-links {
    display: none;
    position: fixed;
    top: var(--nav-height);
    left: 0; right: 0;
    background: rgba(7,4,15,0.97);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    flex-direction: column;
    padding: 20px 24px 32px;
    gap: 4px;
    border-bottom: 1px solid var(--border);
    z-index: 99;
  }
  .nav-links.open { display: flex; }
  .nav-links li { width: 100%; }
  .nav-links li a {
    display: block;
    padding: 12px 16px;
    font-size: 16px;
  }
  .btn-nav {
    display: block;
    text-align: center;
    margin-top: 8px;
    padding: 14px;
  }

  /* Hero */
  .hero { padding: calc(var(--nav-height) + 40px) 0 60px; }
  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 48px;
  }
  .hero-content { order: 1; }
  .hero-phone { order: 2; }
  .hero-badge { margin: 0 auto 24px; }
  .hero-subtitle { margin-left: auto; margin-right: auto; }
  .hero-cta { justify-content: center; }
  .hero-stats { justify-content: center; }
  .phone-frame { width: 220px; }

  /* Features */
  .features-grid { grid-template-columns: 1fr; gap: 16px; }
  .features { padding: 72px 0; }

  /* Screenshots */
  .screenshots { padding: 72px 0; }
  .screenshot-item img { width: 160px; }

  /* CTA */
  .cta-section { padding: 72px 0; }
  .cta-card { padding: 56px 24px; border-radius: var(--radius-lg); }

  /* Footer */
  .footer-top { grid-template-columns: 1fr; gap: 40px; }
  .footer-nav { flex-wrap: wrap; gap: 32px; }
  .footer-bottom { flex-direction: column; text-align: center; }

  /* Blog */
  .blog-grid { grid-template-columns: 1fr; }

  /* Support */
  .support-grid { grid-template-columns: 1fr; }

  /* Prose section */
  .prose-section { padding: 60px 0 80px; }

  /* Page hero */
  .page-hero { padding: calc(var(--nav-height) + 40px) 0 48px; }
}

@media (max-width: 480px) {
  .hero-title { font-size: 36px; }
  .hero-cta { flex-direction: column; }
  .hero-cta .btn { width: 100%; justify-content: center; }
  .section-title { font-size: 26px; }
  .btn-large { padding: 16px 28px; font-size: 15px; }
}
