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

:root {
  --bg:       #0a0a0f;
  --surface:  #12121a;
  --border:   #1e1e2e;
  --text:     #e0dfe6;
  --text-dim: #7a7a8e;
  --accent:   #6e8efb;
  --accent2:  #a777e3;
  --grad:     linear-gradient(135deg, var(--accent), var(--accent2));
}

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

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

/* ── Canvas Background ───────────────────────────── */
#flow-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  opacity: 0.35;
}

/* ── Navigation ──────────────────────────────────── */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 3rem;
  background: rgba(10, 10, 15, 0.8);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-brand {
  font-size: 1.4rem;
  font-weight: 700;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: 0.04em;
}

.nav-links a {
  color: var(--text-dim);
  text-decoration: none;
  margin-left: 2rem;
  font-size: 0.9rem;
  transition: color 0.3s;
}

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

/* ── Sections ────────────────────────────────────── */
section {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6rem 2rem;
}

.container {
  max-width: 1000px;
  width: 100%;
  margin: 0 auto;
  text-align: center;
}

.section-title {
  font-size: 2.4rem;
  font-weight: 700;
  margin-bottom: 3rem;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ── Hero ─────────────────────────────────────────── */
#hero {
  flex-direction: column;
  text-align: center;
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero-title {
  font-size: clamp(3rem, 8vw, 6rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 1.5rem;
}

.hero-title span {
  display: block;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-dim);
  max-width: 560px;
  margin: 0 auto 2.5rem;
}

.hero-subtitle em {
  color: var(--accent);
  font-style: italic;
}

/* CTA Button */
.cta-btn {
  display: inline-block;
  padding: 0.85rem 2.4rem;
  border-radius: 50px;
  background: var(--grad);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  transition: transform 0.3s, box-shadow 0.3s;
}

.cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(110, 142, 251, 0.3);
}

/* Scroll indicator */
.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
}

.scroll-line {
  width: 2px;
  height: 48px;
  background: var(--grad);
  border-radius: 2px;
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.2; transform: scaleY(0.5); }
  50%      { opacity: 1;   transform: scaleY(1); }
}

/* ── Line-reveal animation ───────────────────────── */
.line-reveal {
  opacity: 0;
  transform: translateY(30px);
  animation: revealUp 0.8s ease forwards;
}

.delay-1 { animation-delay: 0.15s; }
.delay-2 { animation-delay: 0.3s; }
.delay-3 { animation-delay: 0.45s; }

@keyframes revealUp {
  to { opacity: 1; transform: translateY(0); }
}

/* ── Fade-in on scroll ───────────────────────────── */
.fade-in {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── About ───────────────────────────────────────── */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  text-align: left;
}

.about-text p {
  color: var(--text-dim);
  margin-bottom: 1.2rem;
  font-size: 1.05rem;
}

/* Flowing rings visual */
.flow-rings {
  position: relative;
  width: 260px;
  height: 260px;
  margin: 0 auto;
}

.ring {
  position: absolute;
  border: 2px solid transparent;
  border-radius: 50%;
  border-top-color: var(--accent);
  border-right-color: var(--accent2);
}

.ring-1 {
  inset: 0;
  animation: spin 6s linear infinite;
}

.ring-2 {
  inset: 30px;
  animation: spin 4s linear infinite reverse;
  border-top-color: var(--accent2);
  border-right-color: var(--accent);
}

.ring-3 {
  inset: 60px;
  animation: spin 8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ── Services ────────────────────────────────────── */
#services {
  background: var(--surface);
}

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

.service-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2.5rem 2rem;
  text-align: center;
  transition: transform 0.3s, border-color 0.3s;
}

.service-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent);
}

.service-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 1.5rem;
  color: var(--accent);
}

.service-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.8rem;
}

.service-card p {
  color: var(--text-dim);
  font-size: 0.95rem;
}

/* Flow-dash SVG animation */
.flow-dash {
  stroke-dasharray: 8 4;
  animation: dashFlow 2s linear infinite;
}

@keyframes dashFlow {
  to { stroke-dashoffset: -48; }
}

/* ── Contact ─────────────────────────────────────── */
.contact-text {
  color: var(--text-dim);
  font-size: 1.1rem;
  margin-bottom: 2rem;
}

/* ── Footer ──────────────────────────────────────── */
footer {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 2rem;
  color: var(--text-dim);
  font-size: 0.85rem;
  border-top: 1px solid var(--border);
  background: var(--bg);
}

/* ── Responsive ──────────────────────────────────── */
@media (max-width: 768px) {
  nav { padding: 1rem 1.5rem; }
  .nav-links a { margin-left: 1rem; font-size: 0.8rem; }
  .about-grid { grid-template-columns: 1fr; text-align: center; }
  .services-grid { grid-template-columns: 1fr; }
  section { padding: 4rem 1.5rem; }
}
