/* ═══════════════════════════════════════════════════════════════════════════════
   Foretell Technologies — Corporate Website
   Dark theme · Blue-violet accents · Premium fintech aesthetic
   ═══════════════════════════════════════════════════════════════════════════════ */

:root {
  --bg: #07070D;
  --bg-alt: #0C0C16;
  --surface: rgba(99, 102, 241, 0.06);
  --surface-hover: rgba(99, 102, 241, 0.10);
  --border: rgba(99, 102, 241, 0.12);
  --border-bright: rgba(99, 102, 241, 0.25);
  --text: #EEEEF4;
  --text-muted: #8B8BA3;
  --text-dim: #5C5C7A;
  --accent: #818CF8;
  --accent-bright: #A5B4FC;
  --accent-dim: rgba(129, 140, 248, 0.15);
  --gradient: linear-gradient(135deg, #818CF8, #6366F1, #8B5CF6);
  --gradient-text: linear-gradient(135deg, #A5B4FC, #818CF8, #C084FC);
  --shadow: 0 0 80px rgba(99, 102, 241, 0.08);
  --radius: 12px;
  --radius-lg: 20px;
  --max-width: 1200px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; color-scheme: dark; }

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }

/* ─── Navigation ───────────────────────────────────────────────────────────── */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(7, 7, 13, 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 20px;
}

.logo-icon {
  font-size: 24px;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

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

.nav-links {
  display: flex;
  gap: 32px;
}

.nav-links a {
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  transition: color 0.2s;
}

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

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: 0.3s;
}

/* ─── Hero ─────────────────────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 120px 24px 80px;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.grid-overlay {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(99, 102, 241, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(99, 102, 241, 0.03) 1px, transparent 1px);
  background-size: 60px 60px;
}

.glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
}

.glow-1 {
  width: 600px;
  height: 600px;
  background: rgba(99, 102, 241, 0.12);
  top: -200px;
  right: -100px;
}

.glow-2 {
  width: 400px;
  height: 400px;
  background: rgba(139, 92, 246, 0.08);
  bottom: -100px;
  left: -100px;
}

.hero-content {
  text-align: center;
  max-width: 800px;
  position: relative;
  z-index: 1;
}

.hero-badge {
  display: inline-block;
  padding: 6px 16px;
  border-radius: 99px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 32px;
  letter-spacing: 0.5px;
}

.hero-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(40px, 7vw, 72px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 24px;
}

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

.hero-sub {
  font-size: 18px;
  line-height: 1.7;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 40px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 60px;
}

.btn {
  display: inline-flex;
  align-items: center;
  padding: 14px 28px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
}

.btn-primary {
  background: var(--gradient);
  color: #fff;
  box-shadow: 0 4px 20px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
  box-shadow: 0 4px 30px rgba(99, 102, 241, 0.5);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border-bright);
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: 40px;
  align-items: center;
}

.stat { text-align: center; }

.stat-value {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 28px;
  font-weight: 700;
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.stat-label {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 4px;
}

.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--border);
}

/* ─── Sections ─────────────────────────────────────────────────────────────── */
.section {
  padding: 100px 0;
}

.section-alt {
  background: var(--bg-alt);
}

.section-header {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 60px;
}

.section-tag {
  display: inline-block;
  padding: 4px 14px;
  border-radius: 99px;
  border: 1px solid var(--border);
  background: var(--accent-dim);
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 20px;
}

.section-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}

.section-sub {
  font-size: 16px;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ─── About ────────────────────────────────────────────────────────────────── */
.about-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.about-card {
  padding: 36px 28px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--surface);
  transition: all 0.3s;
}

.about-card:hover {
  border-color: var(--border-bright);
  background: var(--surface-hover);
  transform: translateY(-2px);
}

.about-icon {
  font-size: 32px;
  margin-bottom: 16px;
}

.about-card h3 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 12px;
}

.about-card p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ─── Services ─────────────────────────────────────────────────────────────── */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.service-card {
  padding: 32px 24px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: rgba(7, 7, 13, 0.5);
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gradient);
  opacity: 0;
  transition: opacity 0.3s;
}

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

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

.service-number {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 36px;
  font-weight: 700;
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  opacity: 0.4;
  margin-bottom: 16px;
}

.service-card h3 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 10px;
}

.service-card p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ─── Products ─────────────────────────────────────────────────────────────── */
.products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.product-card {
  padding: 32px 24px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--surface);
  position: relative;
  transition: all 0.3s;
}

.product-card:hover {
  border-color: var(--border-bright);
  transform: translateY(-2px);
}

.product-featured {
  border-color: rgba(99, 102, 241, 0.3);
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(139, 92, 246, 0.05));
}

.product-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 6px;
  background: rgba(52, 211, 153, 0.15);
  color: #34D399;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
}

.product-badge-soon {
  background: var(--accent-dim);
  color: var(--accent);
}

.product-icon {
  font-size: 36px;
  margin-bottom: 12px;
}

.product-card h3 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 4px;
}

.product-tagline {
  font-size: 13px;
  color: var(--accent);
  font-weight: 500;
  margin-bottom: 12px;
}

.product-card > p:last-of-type {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 16px;
}

.product-tech {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.product-tech span {
  padding: 3px 10px;
  border-radius: 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 500;
}

/* ─── Technology ───────────────────────────────────────────────────────────── */
.tech-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.tech-category {
  padding: 28px 24px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: rgba(7, 7, 13, 0.5);
}

.tech-category h4 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--accent-bright);
}

.tech-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.tech-tags span {
  padding: 6px 14px;
  border-radius: 8px;
  background: var(--accent-dim);
  border: 1px solid var(--border);
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 500;
  transition: all 0.2s;
}

.tech-tags span:hover {
  background: var(--surface-hover);
  color: var(--text);
  border-color: var(--border-bright);
}

/* ─── Contact ──────────────────────────────────────────────────────────────── */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  max-width: 800px;
  margin: 0 auto;
}

.contact-card {
  text-align: center;
  padding: 32px 20px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--surface);
}

.contact-icon {
  font-size: 28px;
  margin-bottom: 12px;
}

.contact-card h4 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 8px;
}

.contact-card a {
  color: var(--accent);
  font-size: 14px;
  transition: color 0.2s;
}

.contact-card a:hover { color: var(--accent-bright); }

.contact-card p {
  font-size: 14px;
  color: var(--text-muted);
}

.contact-muted {
  font-size: 12px !important;
  color: var(--text-dim) !important;
  margin-top: 4px;
}

/* ─── Footer ───────────────────────────────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--border);
  padding: 48px 0;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 600;
}

.footer-links {
  display: flex;
  gap: 28px;
}

.footer-links a {
  font-size: 14px;
  color: var(--text-muted);
  transition: color 0.2s;
}

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

.footer-legal {
  text-align: center;
}

.footer-legal p {
  font-size: 12px;
  color: var(--text-dim);
  line-height: 1.6;
}

/* ─── Responsive ───────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: rgba(7, 7, 13, 0.96);
    backdrop-filter: blur(20px);
    padding: 20px 24px;
    gap: 16px;
    border-bottom: 1px solid var(--border);
  }
  .nav-toggle { display: flex; }

  .hero { padding: 100px 20px 60px; }
  .hero-title { font-size: 36px; }
  .hero-sub { font-size: 16px; }
  .hero-stats { gap: 20px; }
  .stat-value { font-size: 22px; }

  .section { padding: 60px 0; }
  .about-grid,
  .services-grid,
  .products-grid,
  .contact-grid { grid-template-columns: 1fr; }
  .tech-grid { grid-template-columns: 1fr; }

  .footer-links { flex-wrap: wrap; justify-content: center; gap: 16px; }
}

@media (max-width: 480px) {
  .hero-title { font-size: 30px; }
  .hero-actions { flex-direction: column; align-items: center; }
  .hero-stats { flex-direction: column; gap: 16px; }
  .stat-divider { width: 40px; height: 1px; }
}

/* ─── Animations ───────────────────────────────────────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.hero-content > * {
  animation: fadeUp 0.6s ease-out both;
}

.hero-badge { animation-delay: 0.1s; }
.hero-title { animation-delay: 0.2s; }
.hero-sub { animation-delay: 0.3s; }
.hero-actions { animation-delay: 0.4s; }
.hero-stats { animation-delay: 0.5s; }
