:root {
  --bg: #0b1120;
  --bg-soft: #0f172a;
  --surface: rgba(30, 41, 59, 0.72);
  --surface-solid: #1e293b;
  --text: #f1f5f9;
  --muted: #94a3b8;
  --accent: #22c55e;
  --accent-2: #4ade80;
  --accent-dark: #16a34a;
  --gold: #fbbf24;
  --border: rgba(148, 163, 184, 0.14);
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
  --radius: 18px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  overflow-x: hidden;
}

img {
  max-width: 100%;
}

.container {
  width: min(1020px, 92%);
  margin: 0 auto;
}

/* ===== Animated background ===== */
.bg-effects {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.35;
  animation: blobFloat 18s ease-in-out infinite alternate;
}

.blob-1 {
  width: 480px;
  height: 480px;
  background: radial-gradient(circle, #22c55e, transparent 70%);
  top: -140px;
  left: -120px;
}

.blob-2 {
  width: 420px;
  height: 420px;
  background: radial-gradient(circle, #0ea5e9, transparent 70%);
  bottom: -160px;
  right: -120px;
  animation-delay: -6s;
}

.blob-3 {
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, #a78bfa, transparent 70%);
  top: 45%;
  left: 55%;
  opacity: 0.2;
  animation-delay: -12s;
}

@keyframes blobFloat {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(50px, -40px) scale(1.12); }
  100% { transform: translate(-30px, 40px) scale(0.94); }
}

/* Subtle grid overlay */
.bg-effects::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(148, 163, 184, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at 50% 0%, black 30%, transparent 75%);
}

/* ===== Header / Nav ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(16px) saturate(1.4);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  background: rgba(11, 17, 32, 0.65);
  border-bottom: 1px solid var(--border);
  transition: box-shadow 0.3s;
}

.site-header.scrolled {
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.7rem 0;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: var(--text);
  font-weight: 800;
  font-size: 1.2rem;
  letter-spacing: -0.02em;
}

.brand img {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  object-fit: cover;
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.35);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s;
}

.brand:hover img {
  transform: rotate(-8deg) scale(1.08);
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.6), 0 8px 24px rgba(34, 197, 94, 0.35);
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 0.35rem;
}

.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.93rem;
  font-weight: 500;
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  transition: color 0.2s, background 0.2s, transform 0.2s;
}

.nav-links a:hover {
  color: var(--text);
  background: rgba(148, 163, 184, 0.1);
  transform: translateY(-1px);
}

.nav-links a.active {
  color: #052e16;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  font-weight: 700;
  box-shadow: 0 4px 16px rgba(34, 197, 94, 0.35);
}

/* ===== Hero ===== */
.hero {
  text-align: center;
  padding: 5.5rem 0 4rem;
  position: relative;
}

.hero-logo {
  width: 170px;
  height: 170px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 1.75rem;
  animation: heroFloat 5s ease-in-out infinite, heroGlow 3s ease-in-out infinite alternate;
  box-shadow:
    0 0 0 6px rgba(34, 197, 94, 0.15),
    0 0 60px rgba(34, 197, 94, 0.35),
    0 24px 60px rgba(0, 0, 0, 0.5);
}

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

@keyframes heroGlow {
  from { box-shadow: 0 0 0 6px rgba(34, 197, 94, 0.12), 0 0 40px rgba(34, 197, 94, 0.25), 0 24px 60px rgba(0, 0, 0, 0.5); }
  to   { box-shadow: 0 0 0 8px rgba(34, 197, 94, 0.22), 0 0 80px rgba(34, 197, 94, 0.5), 0 24px 60px rgba(0, 0, 0, 0.5); }
}

.hero h1 {
  font-size: clamp(2.4rem, 6vw, 3.6rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 0.5rem;
  background: linear-gradient(135deg, #fff 30%, var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.tagline {
  color: var(--accent-2);
  font-weight: 600;
  font-size: 1.15rem;
  margin-bottom: 1rem;
}

.hero > p:not(.tagline) {
  color: var(--muted);
  max-width: 560px;
  margin: 0 auto 2rem;
  font-size: 1.05rem;
}

/* Hero entrance animation */
.hero-logo,
.hero h1,
.hero .tagline,
.hero > p,
.hero .download-buttons {
  opacity: 0;
  animation: fadeUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.hero h1 { animation-delay: 0.1s; }
.hero .tagline { animation-delay: 0.2s; }
.hero > p { animation-delay: 0.3s; }
.hero .download-buttons { animation-delay: 0.45s; }

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

/* Scroll reveal (JS adds .revealed) */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

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

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* ===== Store download buttons ===== */
.download-buttons {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.1rem;
  flex-wrap: wrap;
}

.store-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  background: linear-gradient(180deg, #18181b, #09090b);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 16px;
  padding: 0.7rem 1.4rem 0.7rem 1.1rem;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  transition: border-color 0.25s, transform 0.25s, box-shadow 0.25s;
}

.store-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 30%, rgba(255, 255, 255, 0.12) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform 0.6s ease;
}

.store-btn:hover::before {
  transform: translateX(120%);
}

.store-btn:hover {
  border-color: rgba(255, 255, 255, 0.4);
  transform: translateY(-3px);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.05);
}

.store-btn:active {
  transform: translateY(-1px) scale(0.98);
}

.store-btn.disabled,
.store-btn.disabled:hover {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
  border-color: rgba(255, 255, 255, 0.14);
}

.store-btn.disabled::before {
  display: none;
}

.store-icon {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
}

.store-icon.apple-icon {
  width: auto;
  height: 27px;
  color: #fff;
}

.store-thumb {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  object-fit: cover;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.store-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.2;
  font-weight: 700;
  font-size: 1.02rem;
}

.store-text small {
  font-weight: 400;
  font-size: 0.66rem;
  color: #a1a1aa;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-soon {
  position: absolute;
  top: -0.7rem;
  right: 0.7rem;
  background: linear-gradient(135deg, var(--gold), #f59e0b);
  color: #422006;
  font-size: 0.6rem;
  font-weight: 800;
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  box-shadow: 0 4px 12px rgba(251, 191, 36, 0.4);
  animation: badgePulse 2.2s ease-in-out infinite;
}

@keyframes badgePulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.08); }
}

/* ===== Features ===== */
.features {
  padding: 2.5rem 0 5rem;
}

.section-title {
  text-align: center;
  margin-bottom: 2.5rem;
}

.section-title h2 {
  font-size: clamp(1.7rem, 4vw, 2.3rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}

.section-title p {
  color: var(--muted);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
}

.card {
  background: var(--surface);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.6rem 1.4rem;
  position: relative;
  overflow: hidden;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.3s, box-shadow 0.35s;
}

.card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s ease;
}

.card:hover {
  transform: translateY(-8px);
  border-color: rgba(34, 197, 94, 0.4);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35), 0 0 40px rgba(34, 197, 94, 0.08);
}

.card:hover::before {
  transform: scaleX(1);
}

.card-icon {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.25);
  margin-bottom: 1rem;
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.card:hover .card-icon {
  transform: scale(1.12) rotate(-6deg);
}

.card h3 {
  margin-bottom: 0.45rem;
  color: var(--text);
  font-size: 1.08rem;
}

.card p {
  color: var(--muted);
  font-size: 0.94rem;
}

/* ===== CTA strip ===== */
.cta {
  padding: 0 0 5rem;
}

.cta-box {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.16), rgba(14, 165, 233, 0.1));
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: 24px;
  padding: 2.75rem 2rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-box::before {
  content: "";
  position: absolute;
  width: 320px;
  height: 320px;
  background: radial-gradient(circle, rgba(34, 197, 94, 0.25), transparent 70%);
  top: -160px;
  right: -80px;
  animation: blobFloat 12s ease-in-out infinite alternate;
}

.cta-box h2 {
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  font-weight: 800;
  margin-bottom: 0.5rem;
  position: relative;
}

.cta-box p {
  color: var(--muted);
  margin-bottom: 1.5rem;
  position: relative;
}

.cta-box .download-buttons {
  position: relative;
}

/* ===== Legal pages ===== */
.page-content {
  padding: 3.5rem 0 4.5rem;
  max-width: 780px;
  margin: 0 auto;
}

.page-hero {
  text-align: center;
  margin-bottom: 2.5rem;
}

.page-hero .page-icon {
  width: 72px;
  height: 72px;
  border-radius: 20px;
  object-fit: cover;
  margin-bottom: 1rem;
  box-shadow: 0 10px 30px rgba(34, 197, 94, 0.25);
  animation: heroFloat 5s ease-in-out infinite;
}

.page-content h1 {
  font-size: clamp(1.9rem, 4vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 0.4rem;
}

.page-content .updated {
  color: var(--muted);
  font-size: 0.9rem;
}

.page-content .lead {
  color: var(--muted);
  margin-bottom: 1rem;
}

.page-content h2 {
  margin: 2.25rem 0 0.75rem;
  font-size: 1.28rem;
  color: var(--accent-2);
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--border);
}

.page-content h3 {
  margin: 1.4rem 0 0.5rem;
  font-size: 1.05rem;
  color: var(--text);
}

.page-content p,
.page-content li {
  color: var(--muted);
  margin-bottom: 0.75rem;
}

.page-content ul,
.page-content ol {
  padding-left: 1.4rem;
  margin-bottom: 1rem;
}

.page-content li {
  margin-bottom: 0.4rem;
}

.page-content a {
  color: var(--accent-2);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.2s;
}

.page-content a:hover {
  color: #86efac;
}

/* ===== Footer ===== */
.site-footer {
  background: rgba(15, 23, 42, 0.8);
  border-top: 1px solid var(--border);
  padding: 2.25rem 0;
  backdrop-filter: blur(10px);
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.8rem;
  text-align: center;
}

.footer-logo {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  object-fit: cover;
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.3);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.footer-logo:hover {
  transform: rotate(8deg) scale(1.08);
}

.site-footer p {
  color: var(--muted);
  font-size: 0.9rem;
}

.footer-links {
  display: flex;
  list-style: none;
  gap: 1.25rem;
}

.footer-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s, transform 0.2s;
  display: inline-block;
}

.footer-links a:hover {
  color: var(--accent-2);
  transform: translateY(-1px);
}

/* ===== Utilities / buttons ===== */
.btn {
  display: inline-block;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #052e16;
  font-weight: 700;
  padding: 0.8rem 2.1rem;
  border-radius: 999px;
  text-decoration: none;
  transition: transform 0.25s, box-shadow 0.25s, filter 0.25s;
  box-shadow: 0 8px 24px rgba(34, 197, 94, 0.3);
}

.btn:hover {
  transform: translateY(-2px) scale(1.03);
  filter: brightness(1.08);
  box-shadow: 0 12px 32px rgba(34, 197, 94, 0.45);
}

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

  .reveal {
    opacity: 1;
    transform: none;
  }
}

@media (max-width: 600px) {
  .hero {
    padding: 3.5rem 0 3rem;
  }

  .hero-logo {
    width: 130px;
    height: 130px;
  }

  .nav-links {
    gap: 0.15rem;
  }

  .nav-links a {
    padding: 0.4rem 0.65rem;
    font-size: 0.85rem;
  }

  .cta-box {
    padding: 2rem 1.25rem;
  }
}
