/* Primum & Terminus - Landing Page Styles */

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

:root {
  --bg: #0a0e1a;
  --surface: #111827;
  --surface-2: #162032;
  --border: #1e2d45;
  --accent: #00d4ff;
  --accent-dim: rgba(0, 212, 255, 0.12);
  --accent-glow: rgba(0, 212, 255, 0.25);
  --purple: #7c3aed;
  --purple-dim: rgba(124, 58, 237, 0.12);
  --text: #f1f5f9;
  --muted: #94a3b8;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* =====================
   LAYOUT
   ===================== */

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

section {
  padding: 96px 0;
}

/* =====================
   NAV
   ===================== */

nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(10, 14, 26, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

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

.nav-logo {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  text-decoration: none;
}

.nav-logo span {
  color: var(--accent);
}

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

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

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

.nav-cta {
  background: var(--accent);
  color: #0a0e1a !important;
  padding: 8px 18px;
  border-radius: 6px;
  font-weight: 600 !important;
  font-size: 14px;
  text-decoration: none;
  transition: opacity 0.2s, box-shadow 0.2s;
}

.nav-cta:hover {
  opacity: 0.9;
  box-shadow: 0 0 16px var(--accent-glow);
  color: #0a0e1a !important;
}

/* =====================
   HERO
   ===================== */

#hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 64px;
  position: relative;
  overflow: hidden;
}

/* CSS-only grid background */
#hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0, 212, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 212, 255, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 40%, black 40%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 40%, black 40%, transparent 100%);
}

/* Radial glow */
#hero::after {
  content: "";
  position: absolute;
  top: 20%;
  left: 50%;
  transform: translateX(-50%);
  width: 700px;
  height: 400px;
  background: radial-gradient(ellipse, rgba(0, 212, 255, 0.08) 0%, transparent 70%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 820px;
  margin: 0 auto;
}

.hero-eyebrow {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid var(--border);
  background: var(--accent-dim);
  padding: 6px 14px;
  border-radius: 100px;
  margin-bottom: 28px;
}

h1 {
  font-size: clamp(42px, 6vw, 72px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.08;
  margin-bottom: 24px;
  color: var(--text);
}

h1 .amp {
  color: var(--accent);
}

.hero-sub {
  font-size: clamp(18px, 2.5vw, 22px);
  color: var(--muted);
  max-width: 580px;
  margin: 0 auto 40px;
  line-height: 1.5;
}

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

.btn-primary {
  display: inline-block;
  background: var(--accent);
  color: #0a0e1a;
  font-weight: 700;
  font-size: 15px;
  padding: 14px 32px;
  border-radius: 8px;
  text-decoration: none;
  transition: opacity 0.2s, box-shadow 0.2s, transform 0.15s;
  letter-spacing: 0.01em;
}

.btn-primary:hover {
  opacity: 0.92;
  box-shadow: 0 0 28px var(--accent-glow);
  transform: translateY(-1px);
}

.btn-secondary {
  display: inline-block;
  background: transparent;
  color: var(--text);
  font-weight: 600;
  font-size: 15px;
  padding: 13px 32px;
  border-radius: 8px;
  border: 1px solid var(--border);
  text-decoration: none;
  transition: border-color 0.2s, background 0.2s, transform 0.15s;
  letter-spacing: 0.01em;
}

.btn-secondary:hover {
  border-color: var(--accent);
  background: var(--accent-dim);
  transform: translateY(-1px);
}

.hero-trust {
  font-size: 13px;
  color: var(--muted);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.hero-trust::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  opacity: 0.8;
}

/* =====================
   SECTION HEADERS
   ===================== */

.section-label {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

h2 {
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.2;
  color: var(--text);
  margin-bottom: 16px;
}

.section-desc {
  font-size: 17px;
  color: var(--muted);
  max-width: 560px;
  line-height: 1.65;
}

/* =====================
   THE PROBLEM
   ===================== */

#problem {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.problem-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.problem-stats {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.stat-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 24px;
  position: relative;
  overflow: hidden;
}

.stat-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
}

.stat-number {
  font-size: 36px;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: -0.03em;
  line-height: 1;
  margin-bottom: 6px;
}

.stat-label {
  font-size: 14px;
  color: var(--muted);
}

/* =====================
   THE STACK
   ===================== */

#stack {
  padding-bottom: 80px;
}

.stack-header {
  text-align: center;
  margin-bottom: 56px;
}

.stack-header .section-desc {
  margin: 0 auto;
}

/* Flow stages bar */
.flow-bar {
  display: flex;
  align-items: stretch;
  gap: 0;
  margin-bottom: 48px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.flow-stage {
  flex: 1;
  min-width: 130px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 14px 12px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  position: relative;
  cursor: default;
  transition: color 0.2s, background 0.2s;
}

.flow-stage:first-child {
  border-radius: 8px 0 0 8px;
}

.flow-stage:last-child {
  border-radius: 0 8px 8px 0;
}

.flow-stage:not(:first-child) {
  border-left: none;
  margin-left: 0;
}

/* Arrow divider via clip-path on a pseudo element */
.flow-stage:not(:last-child)::after {
  content: "";
  position: absolute;
  right: -14px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-top: 22px solid transparent;
  border-bottom: 22px solid transparent;
  border-left: 14px solid var(--border);
  z-index: 2;
}

.flow-stage:not(:last-child)::before {
  content: "";
  position: absolute;
  right: -12px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-top: 21px solid transparent;
  border-bottom: 21px solid transparent;
  border-left: 13px solid var(--surface);
  z-index: 3;
}

.flow-stage.active {
  color: var(--accent);
  background: var(--accent-dim);
}

/* Product cards grid */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.product-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 24px;
  transition: border-color 0.25s, transform 0.2s, box-shadow 0.25s;
  position: relative;
  overflow: hidden;
}

.product-card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--accent);
  opacity: 0;
  transition: opacity 0.25s;
}

.product-card:hover {
  border-color: rgba(0, 212, 255, 0.35);
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

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

.product-stage-tag {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-dim);
  border: 1px solid rgba(0, 212, 255, 0.2);
  padding: 3px 8px;
  border-radius: 100px;
  display: inline-block;
  margin-bottom: 12px;
}

.product-name {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 8px;
}

.product-name span {
  color: var(--accent);
}

.product-desc {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.55;
}

/* =====================
   WHY P&T
   ===================== */

#why {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.why-header {
  text-align: center;
  margin-bottom: 56px;
}

.why-header .section-desc {
  margin: 0 auto;
}

.differentiators {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.diff-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 32px;
  transition: border-color 0.25s;
}

.diff-card:hover {
  border-color: rgba(124, 58, 237, 0.4);
}

.diff-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--purple-dim);
  border: 1px solid rgba(124, 58, 237, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  font-size: 20px;
}

.diff-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.diff-body {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.6;
}

.diff-detail {
  font-size: 12px;
  color: var(--purple);
  margin-top: 10px;
  font-weight: 500;
}

/* =====================
   INDUSTRIES
   ===================== */

#industries {
  text-align: center;
}

.industries-header {
  margin-bottom: 56px;
}

.industries-header .section-desc {
  margin: 0 auto;
}

.industries-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
}

.industry-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 32px 16px;
  transition: border-color 0.25s, transform 0.2s;
}

.industry-card:hover {
  border-color: rgba(0, 212, 255, 0.3);
  transform: translateY(-2px);
}

.industry-icon {
  font-size: 32px;
  margin-bottom: 14px;
  display: block;
  filter: grayscale(0.2);
}

.industry-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.3;
}

/* =====================
   CTA SECTION
   ===================== */

#cta {
  text-align: center;
  padding: 120px 0;
  position: relative;
  overflow: hidden;
}

#cta::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 300px;
  background: radial-gradient(ellipse, rgba(124, 58, 237, 0.1) 0%, transparent 70%);
  pointer-events: none;
}

.cta-content {
  position: relative;
  z-index: 1;
}

.cta-content h2 {
  font-size: clamp(30px, 4.5vw, 48px);
  margin-bottom: 16px;
}

.cta-content .section-desc {
  margin: 0 auto 40px;
  font-size: 18px;
}

.cta-actions {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
  align-items: center;
}

.cta-email {
  font-size: 15px;
  color: var(--muted);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  padding-bottom: 2px;
  transition: color 0.2s, border-color 0.2s;
}

.cta-email:hover {
  color: var(--accent);
  border-color: var(--accent);
}

/* =====================
   FOOTER
   ===================== */

footer {
  border-top: 1px solid var(--border);
  padding: 40px 0;
  background: var(--surface);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-brand {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
}

.footer-brand span {
  color: var(--accent);
}

.footer-sub {
  font-size: 13px;
  color: var(--muted);
  margin-top: 4px;
}

.footer-copy {
  font-size: 13px;
  color: var(--muted);
}

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

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

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

/* =====================
   COMPLIANCE BADGE ROW
   ===================== */

.compliance-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 48px;
  justify-content: center;
}

.compliance-badge {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  border: 1px solid var(--border);
  padding: 6px 12px;
  border-radius: 6px;
  background: var(--surface);
}

/* =====================
   RESPONSIVE
   ===================== */

@media (max-width: 900px) {
  .problem-inner {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .differentiators {
    grid-template-columns: 1fr;
  }

  .industries-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .nav-links {
    display: none;
  }
}

@media (max-width: 600px) {
  section {
    padding: 64px 0;
  }

  .industries-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .flow-bar {
    gap: 4px;
  }

  .flow-stage:not(:last-child)::after,
  .flow-stage:not(:last-child)::before {
    display: none;
  }

  .flow-stage {
    border-radius: 6px;
    border: 1px solid var(--border) !important;
    margin-left: 0;
    font-size: 11px;
    padding: 10px 8px;
  }

  .footer-inner {
    flex-direction: column;
    text-align: center;
  }

  .footer-links {
    justify-content: center;
  }
}
