/* ─────────────────────────────────────────────────────────
   NEBULAI — Landing Page Styles
   ───────────────────────────────────────────────────────── */

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

/* ── VARIABLES ── */
:root {
  --bg:        #0A0A14;
  --surface:   #10101E;
  --text:      #FFFFFF;
  --muted:     #8B8BA7;
  --cyan:      #70C5AB;
  --purple:    #7B4FA6;
  --border:    rgba(112, 197, 171, 0.12);
  --font:      'Space Grotesk', sans-serif;
  --max-w:     1200px;
  --pad-x:     40px;
  --pad-y:     120px;
}

/* ── BASE ── */
html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-weight: 400;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

/* ── NAVBAR ── */
#navbar {
  position: fixed;
  inset-inline: 0;
  top: 0;
  z-index: 200;
  padding: 0 var(--pad-x);
  border-bottom: 1px solid transparent;
  background: rgba(10, 10, 20, 0.35);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition:
    background    0.35s ease,
    border-color  0.35s ease,
    backdrop-filter 0.35s ease;
}

#navbar.scrolled {
  background: rgba(10, 10, 20, 0.9);
  border-color: var(--border);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

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

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

.nav-logo img,
.nav-logo svg {
  height: 44px;
  width: auto;
  display: block;
  mix-blend-mode: screen;
}

.nav-brand {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: #ffffff;
}

.nav-brand-ai {
  color: var(--cyan);
}

.btn-nav {
  display: inline-flex;
  align-items: center;
  padding: 10px 24px;
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: 3px;
  color: #FFFFFF;
  font-family: var(--font);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.025em;
  text-decoration: none;
  background: transparent;
  white-space: nowrap;
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.btn-nav:hover {
  background: #FFFFFF;
  color: var(--bg);
  border-color: #FFFFFF;
  box-shadow: 0 0 24px rgba(255, 255, 255, 0.2);
}

/* ── HERO ── */
#hero {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}

#hero video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-tagline {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  z-index: 1;
}

.hero-brand {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(3.5rem, 10vw, 8rem);
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.08em;
  text-align: center;
  text-shadow: 0 2px 40px rgba(0,0,0,0.5);
  margin: 0;
  line-height: 1;
}

.brand-ai {
  color: var(--cyan);
}

.hero-tagline p {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1rem, 2.5vw, 1.6rem);
  font-weight: 400;
  color: rgba(255,255,255,0.85);
  letter-spacing: 0.04em;
  text-align: center;
  text-shadow: 0 2px 24px rgba(0,0,0,0.5);
  margin: 0;
}

/* ── SECTION BASE ── */
.section {
  position: relative;
  padding: var(--pad-y) var(--pad-x);
}

.container {
  position: relative;
  z-index: 1;
  max-width: var(--max-w);
  margin: 0 auto;
}

/* Subtle dot-grid atmosphere */
.dot-grid {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(112, 197, 171, 0.065) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
}

/* ── SECTION HEADER ── */
.section-header {
  text-align: center;
  max-width: 840px;
  margin: 0 auto 72px;
}

.section-heading {
  font-size: clamp(1.875rem, 3.2vw, 2.75rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.025em;
  margin-bottom: 20px;
}

.section-sub {
  font-size: clamp(0.9375rem, 1.3vw, 1.0625rem);
  color: var(--muted);
  line-height: 1.75;
  font-weight: 300;
}

/* ── CARDS GRID ── */
/*
  Desktop: 6-column internal grid, each card spans 2 cols.
  Cards 4 & 5 are explicitly placed at cols 2–4 and 4–6,
  leaving col 1 and col 6 empty → visually centered pair.
*/
.cards-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 20px;
}

.card {
  grid-column: span 2;
  background: var(--surface);
  border-top: 3px solid var(--cyan);
  border-radius: 8px;
  padding: 32px 28px 36px;
  position: relative;
  overflow: hidden;
  cursor: default;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* 6 cards fill 2 rows of 3 naturally — no manual placement needed */

/* Radial top-glow on hover */
.card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% -5%, rgba(112, 197, 171, 0.09) 0%, transparent 55%);
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow:
    0 20px 56px rgba(112, 197, 171, 0.1),
    0 0 0 1px rgba(112, 197, 171, 0.16);
}

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

.card-icon {
  color: var(--cyan);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
}

.card-title {
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.3;
  margin-bottom: 12px;
}

.card-body {
  font-size: 0.9375rem;
  color: var(--muted);
  line-height: 1.72;
  font-weight: 300;
}

/* ── SOBRE NEBULAI ── */
#sobre {
  background: linear-gradient(160deg, #0A0A14 0%, #0D0D1C 60%, #0A0A14 100%);
}

.sobre-grid {
  display: grid;
  grid-template-columns: 60fr 40fr;
  gap: 80px;
  align-items: center;
}

.label {
  display: inline-block;
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  color: var(--cyan);
  text-transform: uppercase;
  margin-bottom: 16px;
}

.sobre-text h2 {
  font-size: clamp(2rem, 3.2vw, 3rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 24px;
}

.sobre-text p {
  font-size: 1.0625rem;
  color: var(--muted);
  line-height: 1.78;
  font-weight: 300;
  margin-bottom: 16px;
}

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

/* ── STATS BLOCK ── */
.stats-block {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 40px 36px;
  box-shadow:
    0 0 80px rgba(112, 197, 171, 0.04),
    inset 0 1px 0 rgba(112, 197, 171, 0.08);
}

/* Glowing top line */
.stats-top-glow {
  position: absolute;
  top: -1px;
  left: 20%;
  width: 60%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--cyan), transparent);
  display: block;
}

.stat-item {
  padding: 28px 0;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.stat-item:first-of-type { padding-top: 0; }
.stat-item:last-of-type  { padding-bottom: 0; }

.stat-number {
  font-size: clamp(2.5rem, 3.5vw, 3.75rem);
  font-weight: 700;
  color: var(--cyan);
  letter-spacing: -0.04em;
  line-height: 1;
  text-shadow: 0 0 40px rgba(112, 197, 171, 0.45);
}

.stat-label {
  font-size: 0.875rem;
  color: var(--muted);
  font-weight: 400;
  letter-spacing: 0.01em;
}

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

/* ── FOUNDING CLIENTS ── */
#founding {
  text-align: center;
  overflow: hidden;
}

.founding-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 920px;
  height: 700px;
  background: radial-gradient(ellipse at center,
    rgba(123, 79, 166, 0.22) 0%,
    rgba(112, 197, 171, 0.06) 42%,
    transparent 70%
  );
  pointer-events: none;
}

.founding-inner {
  position: relative;
  z-index: 1;
  max-width: 680px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.founding-inner h2 {
  font-size: clamp(2.25rem, 3.8vw, 3.5rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 24px;
}

.founding-inner p {
  font-size: 1.0625rem;
  color: var(--muted);
  line-height: 1.75;
  font-weight: 300;
  margin-bottom: 40px;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  padding: 16px 36px;
  background: var(--cyan);
  color: var(--bg);
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  text-decoration: none;
  border-radius: 3px;
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow:
    0 0 44px rgba(112, 197, 171, 0.48),
    0 10px 32px rgba(112, 197, 171, 0.22);
}

/* ── FOOTER ── */
#footer {
  position: relative;
  padding: 64px var(--pad-x);
  text-align: center;
}

.footer-line {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg,
    transparent 0%,
    var(--purple) 28%,
    var(--cyan)   50%,
    var(--purple) 72%,
    transparent 100%
  );
}

.footer-inner {
  max-width: 520px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.footer-logo {
  height: 40px;
  width: auto;
  opacity: 0.85;
}

.footer-tagline {
  font-size: 0.9375rem;
  color: var(--muted);
  font-weight: 300;
  letter-spacing: 0.04em;
}

.footer-cta {
  font-size: 0.9375rem;
  color: var(--cyan);
  font-weight: 500;
  text-decoration: none;
  letter-spacing: 0.015em;
  transition: text-shadow 0.2s ease, opacity 0.2s ease;
}

.footer-cta:hover {
  text-shadow: 0 0 28px rgba(112, 197, 171, 0.75);
  opacity: 0.85;
}

.footer-copy {
  font-size: 0.6875rem;
  color: rgba(139, 139, 167, 0.45);
  letter-spacing: 0.02em;
  margin-top: 8px;
}

/* ── SCROLL REVEAL ── */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}

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

/* Staggered entrance for cards */
.cards-grid .card.reveal:nth-child(1) { transition-delay: 0s;    }
.cards-grid .card.reveal:nth-child(2) { transition-delay: 0.09s; }
.cards-grid .card.reveal:nth-child(3) { transition-delay: 0.18s; }
.cards-grid .card.reveal:nth-child(4) { transition-delay: 0.27s; }
.cards-grid .card.reveal:nth-child(5) { transition-delay: 0.36s; }
.cards-grid .card.reveal:nth-child(6) { transition-delay: 0.45s; }

/* Custom solutions card — purple accent */
.card--custom {
  border-top-color: var(--purple);
  background: linear-gradient(160deg, var(--surface) 60%, rgba(123, 79, 166, 0.08) 100%);
}

.card--custom .card-icon { color: var(--purple); }

.card--custom:hover {
  box-shadow:
    0 20px 56px rgba(123, 79, 166, 0.15),
    0 0 0 1px rgba(123, 79, 166, 0.2);
}

.card--custom::after {
  background: radial-gradient(ellipse at 50% -5%, rgba(123, 79, 166, 0.1) 0%, transparent 55%);
}

.card-tag {
  display: inline-block;
  margin-top: 16px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--purple);
  letter-spacing: 0.02em;
}

/* ── UTILITIES ── */
.br-d { display: block; }

/* ── RESPONSIVE: TABLET (≤ 1024px) ── */
@media (max-width: 1024px) {
  .cards-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .card { grid-column: span 1; }

  .sobre-grid { gap: 48px; }
}

/* ── RESPONSIVE: MOBILE (≤ 768px) ── */
@media (max-width: 768px) {
  :root {
    --pad-x: 24px;
    --pad-y: 80px;
  }

  #navbar { padding: 0 24px; }

  .btn-nav {
    font-size: 0.8125rem;
    padding: 9px 16px;
  }

  .br-d { display: none; }

  .section-header { margin-bottom: 48px; }

  /* Cards: single column */
  .cards-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .card {
    grid-column: span 1;
    max-width: 100%;
    margin: 0;
  }

  /* Sobre: stack */
  .sobre-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  /* Stats: horizontal row on mobile */
  .stats-block {
    padding: 24px 20px;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0;
  }

  .stat-item {
    flex: 1;
    padding: 0 12px;
    text-align: center;
    min-width: 0;
  }

  .stat-item:first-of-type { padding-left: 0; }
  .stat-item:last-of-type  { padding-right: 0; }

  .stat-divider {
    width: 1px;
    height: 48px;
    flex-shrink: 0;
  }

  .stat-number {
    font-size: clamp(1.5rem, 6vw, 2.25rem);
  }

  .stat-label {
    font-size: 0.75rem;
  }

  #footer { padding: 56px var(--pad-x); }
}
