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

:root {
  --bg:        #07060f;
  --surface:   #100e1d;
  --card:      rgba(20, 17, 36, 0.85);
  --card-hov:  rgba(26, 22, 46, 0.95);
  --border:    rgba(255, 255, 255, 0.06);
  --border-hov:rgba(140, 77, 255, 0.25);
  --text:      #ece9f8;
  --muted:     rgba(236, 233, 248, 0.48);
  --muted2:    rgba(236, 233, 248, 0.28);
  --accent1:   #8c4dff;
  --accent2:   #f24fb8;
  --green:     #32dc78;
  --grad:      linear-gradient(135deg, #8c4dff 0%, #f24fb8 100%);
  --grad-soft: linear-gradient(135deg, rgba(140,77,255,0.15) 0%, rgba(242,79,184,0.10) 100%);

  --radius-card: 22px;
  --radius-sm:   12px;

  --transition: 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  --transition-fast: 0.20s cubic-bezier(0.22, 1, 0.36, 1);
}

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

body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Inter', sans-serif;
  line-height: 1.72;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ─────────────────────────────────────────
   Canvas background
───────────────────────────────────────── */
#bg-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.55;
}

/* ─────────────────────────────────────────
   Animated Blobs
───────────────────────────────────────── */
.blobs {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(130px);
  will-change: transform;
}

.blob-1 {
  width: 700px; height: 700px;
  background: radial-gradient(circle, rgba(140,77,255,0.35), transparent 70%);
  top: -220px; left: -180px;
  animation: blob-float1 20s ease-in-out infinite alternate;
}

.blob-2 {
  width: 550px; height: 550px;
  background: radial-gradient(circle, rgba(242,79,184,0.28), transparent 70%);
  bottom: -160px; right: -120px;
  animation: blob-float2 24s ease-in-out infinite alternate;
}

.blob-3 {
  width: 450px; height: 450px;
  background: radial-gradient(circle, rgba(77,140,255,0.20), transparent 70%);
  top: 45%; left: 45%;
  animation: blob-float3 28s ease-in-out infinite alternate;
}

@keyframes blob-float1 {
  0%   { transform: translate(0, 0) scale(1); }
  50%  { transform: translate(60px, 40px) scale(1.1); }
  100% { transform: translate(20px, -60px) scale(0.92); }
}
@keyframes blob-float2 {
  0%   { transform: translate(0, 0) scale(1); }
  50%  { transform: translate(-50px, -40px) scale(1.08); }
  100% { transform: translate(30px, 70px) scale(0.95); }
}
@keyframes blob-float3 {
  0%   { transform: translate(0, 0) scale(1); }
  50%  { transform: translate(-70px, 50px) scale(1.12); }
  100% { transform: translate(50px, -30px) scale(0.88); }
}

/* ─────────────────────────────────────────
   Navbar
───────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 0 24px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translateY(-100%);
  opacity: 0;
  transition: transform 0.5s cubic-bezier(0.22,1,0.36,1),
              opacity 0.5s ease,
              background 0.3s ease,
              backdrop-filter 0.3s ease;
  pointer-events: none;
}

.navbar.visible {
  transform: translateY(0);
  opacity: 1;
  pointer-events: all;
}

.navbar.scrolled {
  background: rgba(7, 6, 15, 0.75);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: 780px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px; height: 32px;
  background: var(--grad);
  border-radius: 9px;
  font-family: 'SF Mono', 'Fira Code', monospace;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
}

.nav-title {
  font-size: 15px;
  font-weight: 650;
  letter-spacing: -0.2px;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-badge {
  font-size: 12px;
  color: var(--muted);
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 4px 12px;
}

/* Language toggle */
.lang-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(140,77,255,0.10);
  border: 1px solid rgba(140,77,255,0.22);
  border-radius: 100px;
  padding: 5px 13px;
  cursor: pointer;
  transition: background var(--transition-fast), border-color var(--transition-fast), transform var(--transition-fast);
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.3px;
  font-family: inherit;
}

.lang-toggle:hover {
  background: rgba(140,77,255,0.22);
  border-color: rgba(140,77,255,0.45);
  transform: scale(1.04);
}

.lang-toggle:active {
  transform: scale(0.97);
}

.lang-flag { font-size: 15px; line-height: 1; }
.lang-label { color: #c9a8ff; }

/* ─────────────────────────────────────────
   Layout
───────────────────────────────────────── */
.wrapper {
  position: relative;
  z-index: 1;
  max-width: 780px;
  margin: 0 auto;
  padding: 0 24px 100px;
}

/* ─────────────────────────────────────────
   Hero
───────────────────────────────────────── */
.hero {
  position: relative;
  text-align: center;
  padding: 110px 0 72px;
  overflow: hidden;
}

.hero-glow {
  position: absolute;
  top: 20%;
  left: 50%;
  transform: translateX(-50%);
  width: 500px; height: 200px;
  background: radial-gradient(ellipse, rgba(140,77,255,0.20) 0%, transparent 70%);
  pointer-events: none;
  animation: hero-pulse 4s ease-in-out infinite alternate;
}

@keyframes hero-pulse {
  0%   { opacity: 0.6; transform: translateX(-50%) scaleY(1); }
  100% { opacity: 1;   transform: translateX(-50%) scaleY(1.4); }
}

.app-icon {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 88px; height: 88px;
  background: var(--grad);
  border-radius: 26px;
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.12),
    0 20px 60px rgba(140,77,255,0.50),
    0 8px 24px rgba(242,79,184,0.30);
  margin-bottom: 28px;
  cursor: default;
  transition: transform var(--transition), box-shadow var(--transition);
  animation: icon-float 3.5s ease-in-out infinite alternate;
}

.app-icon:hover {
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.18),
    0 28px 80px rgba(140,77,255,0.65),
    0 12px 32px rgba(242,79,184,0.40);
}

.app-icon span {
  font-family: 'SF Mono', 'Fira Code', 'Consolas', monospace;
  font-size: 34px;
  font-weight: 700;
  color: #fff;
  letter-spacing: -1px;
}

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

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(140,77,255,0.10);
  border: 1px solid rgba(140,77,255,0.22);
  border-radius: 100px;
  padding: 6px 16px;
  font-size: 12px;
  font-weight: 500;
  color: #c9a8ff;
  margin-bottom: 22px;
  letter-spacing: 0.2px;
}

.live-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--accent1);
  animation: live 2.2s ease-in-out infinite;
}

@keyframes live {
  0%, 100% { opacity: 1; transform: scale(1); box-shadow: 0 0 0 0 rgba(140,77,255,0.6); }
  50%       { opacity: 0.7; transform: scale(0.85); box-shadow: 0 0 0 5px rgba(140,77,255,0); }
}

.hero-title {
  font-size: clamp(38px, 6vw, 58px);
  font-weight: 750;
  letter-spacing: -1.5px;
  line-height: 1.1;
  margin-bottom: 14px;
  color: var(--text);
}

.grad-text {
  background: var(--grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-sub {
  font-size: 16px;
  color: var(--muted);
  font-weight: 500;
  margin-bottom: 14px;
}

.hero-desc {
  font-size: 16px;
  color: var(--muted2);
  max-width: 480px;
  margin: 0 auto;
  line-height: 1.7;
}

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

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* ─────────────────────────────────────────
   Cards
───────────────────────────────────────── */
.card {
  position: relative;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: 28px 28px 30px;
  margin-bottom: 14px;
  overflow: hidden;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  transition:
    background var(--transition),
    border-color var(--transition),
    transform var(--transition),
    box-shadow var(--transition);
}

.card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--grad-soft);
  opacity: 0;
  border-radius: inherit;
  transition: opacity var(--transition);
  pointer-events: none;
}

.card:hover {
  background: var(--card-hov);
  border-color: var(--border-hov);
  transform: translateY(-3px);
  box-shadow:
    0 12px 50px rgba(140,77,255,0.14),
    0 4px 16px rgba(0,0,0,0.4);
}

.card:hover::before {
  opacity: 1;
}

/* Shimmer line on top */
.card::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: var(--grad);
  opacity: 0;
  transition: opacity var(--transition);
  border-radius: var(--radius-card) var(--radius-card) 0 0;
}

.card:hover::after {
  opacity: 0.6;
}

.card-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 18px;
}

.card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px; height: 50px;
  border-radius: 15px;
  background: color-mix(in srgb, var(--c) 14%, transparent);
  font-size: 22px;
  flex-shrink: 0;
  border: 1px solid color-mix(in srgb, var(--c) 22%, transparent);
  transition: transform var(--transition), box-shadow var(--transition);
}

.card:hover .card-icon {
  transform: scale(1.08) rotate(-4deg);
  box-shadow: 0 8px 24px color-mix(in srgb, var(--c) 30%, transparent);
}

.card h2 {
  font-size: 18px;
  font-weight: 680;
  letter-spacing: -0.3px;
  color: var(--text);
  line-height: 1.25;
}

.card-sub {
  font-size: 12px;
  color: var(--muted2);
  margin-top: 2px;
  font-weight: 400;
}

.card p {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.78;
  margin-bottom: 12px;
}

.card p:last-child { margin-bottom: 0; }

.card strong { color: var(--text); font-weight: 600; }

code {
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.08);
  padding: 2px 7px;
  border-radius: 6px;
  font-family: 'SF Mono', 'Fira Code', monospace;
  font-size: 13px;
  color: #c9a8ff;
}

/* ─────────────────────────────────────────
   Callout
───────────────────────────────────────── */
.callout {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: rgba(140,77,255,0.08);
  border: 1px solid rgba(140,77,255,0.18);
  border-radius: 14px;
  padding: 16px 18px;
  margin-top: 16px;
}

.callout-icon {
  font-size: 18px;
  flex-shrink: 0;
  margin-top: 1px;
}

.callout p {
  margin: 0;
  font-size: 14px;
  color: #cbb8f4;
  line-height: 1.65;
}

.callout strong { color: #e0d0ff; }

/* ─────────────────────────────────────────
   Check grid
───────────────────────────────────────── */
.check-grid {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 6px;
}

@media (max-width: 500px) {
  .check-grid { grid-template-columns: 1fr; }
}

.check-grid li {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: var(--radius-sm);
  padding: 11px 14px;
  font-size: 14px;
  color: var(--muted);
  transition: background var(--transition-fast), border-color var(--transition-fast), transform var(--transition-fast);
}

.check-grid li:hover {
  background: rgba(50,220,120,0.06);
  border-color: rgba(50,220,120,0.18);
  transform: scale(1.02);
}

.tick {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px; height: 22px;
  min-width: 22px;
  background: rgba(50,220,120,0.14);
  border: 1px solid rgba(50,220,120,0.25);
  border-radius: 7px;
  font-size: 11px;
  color: var(--green);
  font-weight: 700;
}

/* ─────────────────────────────────────────
   Dot list
───────────────────────────────────────── */
.dot-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 14px;
}

.dot-list li {
  display: flex;
  gap: 12px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.65;
  align-items: flex-start;
}

.dot-list li::before {
  content: '';
  display: block;
  width: 7px; height: 7px;
  min-width: 7px;
  border-radius: 50%;
  background: var(--grad);
  margin-top: 9px;
}

/* ─────────────────────────────────────────
   Contact Card
───────────────────────────────────────── */
.contact-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
  font-size: 15px;
  font-weight: 550;
  padding: 14px 22px;
  background: rgba(140,77,255,0.10);
  border: 1px solid rgba(140,77,255,0.22);
  border-radius: 14px;
  margin-top: 16px;
  transition: background var(--transition), border-color var(--transition), transform var(--transition), box-shadow var(--transition);
  position: relative;
  overflow: hidden;
}

.contact-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--grad);
  opacity: 0;
  transition: opacity var(--transition);
}

.contact-btn:hover {
  border-color: rgba(140,77,255,0.45);
  transform: translateY(-3px);
  box-shadow: 0 12px 40px rgba(140,77,255,0.30);
}

.contact-btn:hover::before {
  opacity: 0.12;
}

.contact-btn-icon { font-size: 17px; }
.contact-btn-arrow {
  margin-left: auto;
  color: var(--accent1);
  font-size: 17px;
  transition: transform var(--transition);
}

.contact-btn:hover .contact-btn-arrow {
  transform: translateX(4px);
}

/* ─────────────────────────────────────────
   Footer
───────────────────────────────────────── */
footer {
  text-align: center;
  padding: 64px 0 0;
  color: var(--muted2);
  font-size: 14px;
  opacity: 0;
  animation: fade-in 0.8s ease forwards 0.6s;
}

.footer-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px; height: 44px;
  background: var(--grad);
  border-radius: 13px;
  font-family: 'SF Mono', 'Fira Code', monospace;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 18px;
  box-shadow: 0 8px 30px rgba(140,77,255,0.35);
}

footer .grad-text { font-weight: 650; }

.footer-sub {
  margin-top: 6px;
  font-size: 13px;
  opacity: 0.65;
}

/* ─────────────────────────────────────────
   Animations
───────────────────────────────────────── */
@keyframes fade-in {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ─────────────────────────────────────────
   Hero entrance (JS adds .loaded to body)
───────────────────────────────────────── */
body .hero .app-icon,
body .hero .hero-tag,
body .hero .hero-title,
body .hero .hero-sub,
body .hero .hero-desc {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.65s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.65s cubic-bezier(0.22, 1, 0.36, 1);
}

body.loaded .hero .app-icon   { opacity: 1; transform: translateY(0); transition-delay: 0.05s; }
body.loaded .hero .hero-tag   { opacity: 1; transform: translateY(0); transition-delay: 0.15s; }
body.loaded .hero .hero-title { opacity: 1; transform: translateY(0); transition-delay: 0.25s; }
body.loaded .hero .hero-sub   { opacity: 1; transform: translateY(0); transition-delay: 0.35s; }
body.loaded .hero .hero-desc  { opacity: 1; transform: translateY(0); transition-delay: 0.43s; }

/* ─────────────────────────────────────────
   Scrollbar
───────────────────────────────────────── */
::-webkit-scrollbar       { width: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: rgba(140,77,255,0.40);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(140,77,255,0.65);
}

/* ─────────────────────────────────────────
   Responsive
───────────────────────────────────────── */
@media (max-width: 600px) {
  .card { padding: 22px 20px 24px; border-radius: 18px; }
  .hero { padding: 90px 0 56px; }
  .hero-title { letter-spacing: -1px; }
}

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