@import url('https://fonts.googleapis.com/css2?family=Bitter:wght@600;700&family=Work+Sans:wght@400;500;600&display=swap');

:root {
  --mind-midnight: #0F172A;
  --synapse-purple: #9333EA;
  --thought-cyan: #22D3EE;
  --neural-grey: #334155;
  --text-light: #F1F5F9;
  --text-muted: #94A3B8;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Work Sans', sans-serif;
  background: var(--mind-midnight);
  color: var(--text-light);
  line-height: 1.6;
}

h1, h2, h3, h4 {
  font-family: 'Bitter', serif;
  line-height: 1.2;
}

a { color: var(--thought-cyan); text-decoration: none; }
a:hover { color: #67E8F9; }

img { max-width: 100%; height: auto; display: block; }

.container { width: min(1140px, 92%); margin: 0 auto; }

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--neural-grey);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 4%;
  max-width: 1140px;
  margin: 0 auto;
}

.logo {
  font-family: 'Bitter', serif;
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-light);
}

.logo span { color: var(--synapse-purple); }

.nav-main { display: flex; align-items: center; gap: 1.75rem; }

.nav-main a {
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.95rem;
}

.nav-main a:hover, .nav-main a.active { color: var(--thought-cyan); }

.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  border: none;
  cursor: pointer;
  transition: all 0.35s ease;
  text-align: center;
}

.btn-primary {
  background: linear-gradient(135deg, var(--synapse-purple), var(--thought-cyan));
  color: #fff;
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--thought-cyan), var(--synapse-purple));
  color: #fff;
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--synapse-purple);
  color: var(--text-light);
}

.btn-outline:hover {
  background: var(--synapse-purple);
  color: #fff;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-light);
  font-size: 1.5rem;
  cursor: pointer;
}

main { padding-top: 72px; }

/* Hero */
.hero {
  min-height: 88vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
  padding: 4rem 4% 3rem;
  max-width: 1140px;
  margin: 0 auto;
  position: relative;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 10% 20%;
  background: radial-gradient(ellipse, rgba(147, 51, 234, 0.25), transparent 70%);
  pointer-events: none;
}

.hero-content { position: relative; z-index: 1; }

.hero h1 {
  font-size: clamp(2rem, 5vw, 3.25rem);
  margin-bottom: 1rem;
}

.hero-tagline { color: var(--thought-cyan); font-size: 1.1rem; margin-bottom: 1.25rem; }

.hero p { color: var(--text-muted); margin-bottom: 1.75rem; max-width: 520px; }

.hero-visual {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--neural-grey);
  box-shadow: 0 0 40px rgba(147, 51, 234, 0.35), 0 0 60px rgba(34, 211, 238, 0.15);
}

.hero-visual img { width: 100%; aspect-ratio: 4/3; object-fit: cover; }

.node-pulse {
  animation: nodePulse 0.5s ease-in-out infinite alternate;
}

@keyframes nodePulse {
  from { box-shadow: 0 0 20px rgba(147, 51, 234, 0.4); }
  to { box-shadow: 0 0 35px rgba(34, 211, 238, 0.5); }
}

/* Stats */
.stats-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  padding: 3rem 4%;
  max-width: 1140px;
  margin: 0 auto;
}

.stat-item {
  text-align: center;
  padding: 1.5rem;
  background: rgba(51, 65, 85, 0.4);
  border-radius: 12px;
  border: 1px solid var(--neural-grey);
}

.stat-item strong {
  display: block;
  font-family: 'Bitter', serif;
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  color: var(--thought-cyan);
}

.stat-item span { color: var(--text-muted); font-size: 0.9rem; }

/* Cards */
.section { padding: 4rem 0; }

.section-title {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  text-align: center;
  margin-bottom: 0.5rem;
}

.section-sub {
  text-align: center;
  color: var(--text-muted);
  margin-bottom: 2.5rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}

.glass-card {
  background: rgba(30, 41, 59, 0.65);
  backdrop-filter: blur(10px);
  border: 1px solid var(--neural-grey);
  border-radius: 14px;
  padding: 1.75rem;
  transition: transform 0.35s ease, box-shadow 0.35s ease;
  position: relative;
  overflow: hidden;
}

.glass-card::before {
  content: attr(data-layer);
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--synapse-purple);
  opacity: 0.8;
}

.glass-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 32px rgba(147, 51, 234, 0.35), 0 0 24px rgba(34, 211, 238, 0.2);
}

.glass-card h3 { margin-bottom: 0.75rem; color: var(--text-light); }

.glass-card .price {
  font-family: 'Bitter', serif;
  font-size: 1.35rem;
  color: var(--thought-cyan);
  margin: 1rem 0;
}

.glass-card p { color: var(--text-muted); font-size: 0.95rem; }

/* Neural stack */
.neural-stack {
  background: linear-gradient(90deg, rgba(147, 51, 234, 0.15), rgba(34, 211, 238, 0.1));
  padding: 2.5rem 4%;
  border-top: 1px solid var(--neural-grey);
  border-bottom: 1px solid var(--neural-grey);
}

.stack-items {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  max-width: 900px;
  margin: 0 auto;
}

.stack-pill {
  padding: 0.6rem 1.25rem;
  background: var(--neural-grey);
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 500;
}

/* Node grid */
.node-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.node-item {
  padding: 1.5rem;
  border-left: 3px solid var(--synapse-purple);
  background: rgba(51, 65, 85, 0.3);
  border-radius: 0 10px 10px 0;
}

.node-item h4 { margin-bottom: 0.5rem; color: var(--thought-cyan); }

/* Full bleed CTA band */
.full-bleed {
  background: url('/images/connection-map-visual.jpg') center/cover no-repeat;
  position: relative;
  min-height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.full-bleed::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.82);
}

.full-bleed .container {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 3rem 1rem;
}

/* Testimonials */
.testimonial-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.testimonial {
  background: rgba(30, 41, 59, 0.8);
  padding: 1.75rem;
  border-radius: 12px;
  border: 1px solid var(--neural-grey);
}

.testimonial blockquote {
  font-style: italic;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.testimonial cite { color: var(--thought-cyan); font-size: 0.9rem; font-style: normal; }

/* CTA section */
.cta-gradient {
  text-align: center;
  padding: 4rem 4%;
  background: linear-gradient(135deg, var(--synapse-purple), #6D28D9, var(--thought-cyan));
}

.cta-gradient h2 { margin-bottom: 1rem; color: #fff; }

.cta-gradient p { margin-bottom: 1.5rem; color: rgba(255,255,255,0.9); }

.cta-gradient .btn-primary {
  background: #fff;
  color: var(--synapse-purple);
}

.cta-gradient .btn-primary:hover {
  background: var(--mind-midnight);
  color: #fff;
}

/* Footer */
.site-footer {
  background: #0a0f1a;
  padding: 3rem 4% 1.5rem;
  border-top: 1px solid var(--neural-grey);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 2rem;
  max-width: 1140px;
  margin: 0 auto 2rem;
}

.footer-grid h4 { color: var(--thought-cyan); margin-bottom: 1rem; font-size: 1rem; }

.footer-grid p, .footer-grid li { color: var(--text-muted); font-size: 0.9rem; }

.footer-grid ul { list-style: none; }

.footer-grid ul li { margin-bottom: 0.4rem; }

.footer-bottom {
  text-align: center;
  padding-top: 1.5rem;
  border-top: 1px solid var(--neural-grey);
  color: var(--text-muted);
  font-size: 0.85rem;
  max-width: 1140px;
  margin: 0 auto;
}

/* Page hero */
.page-hero {
  padding: 3rem 4%;
  text-align: center;
  background: linear-gradient(180deg, rgba(147, 51, 234, 0.2), transparent);
}

.page-hero h1 { font-size: clamp(1.75rem, 4vw, 2.75rem); }

/* Collection */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  margin-bottom: 2rem;
}

.filter-btn {
  padding: 0.5rem 1rem;
  background: var(--neural-grey);
  border: none;
  border-radius: 6px;
  color: var(--text-light);
  cursor: pointer;
  font-family: inherit;
  font-size: 0.9rem;
}

.filter-btn.active, .filter-btn:hover {
  background: var(--synapse-purple);
  color: #fff;
}

.catalog-card {
  background: rgba(30, 41, 59, 0.7);
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--neural-grey);
}

.catalog-card img { width: 100%; height: 200px; object-fit: cover; }

.catalog-body { padding: 1.5rem; }

.catalog-card .ref { font-size: 0.8rem; color: var(--synapse-purple); margin-bottom: 0.5rem; }

.catalog-card .cat-tag {
  display: inline-block;
  background: rgba(34, 211, 238, 0.15);
  color: var(--thought-cyan);
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  font-size: 0.75rem;
  margin-bottom: 0.75rem;
}

.catalog-meta { font-size: 0.85rem; color: var(--text-muted); margin: 0.75rem 0; }

.catalog-meta dt { font-weight: 600; color: var(--text-light); display: inline; }
.catalog-meta dd { display: inline; margin-right: 1rem; }

/* Forms */
.form-section { max-width: 640px; margin: 0 auto; }

.form-group { margin-bottom: 1.25rem; }

.form-group label {
  display: block;
  margin-bottom: 0.4rem;
  font-weight: 500;
  color: var(--text-light);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--neural-grey);
  border-radius: 8px;
  background: rgba(30, 41, 59, 0.8);
  color: var(--text-light);
  font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--synapse-purple);
  box-shadow: 0 0 0 3px rgba(147, 51, 234, 0.25);
}

.field-error {
  color: #F87171;
  font-size: 0.85rem;
  margin-top: 0.35rem;
  display: none;
}

.field-error.visible { display: block; }

.form-success {
  display: none;
  padding: 2rem;
  text-align: center;
  background: rgba(34, 211, 238, 0.1);
  border: 1px solid var(--thought-cyan);
  border-radius: 12px;
}

.form-success.visible {
  display: block;
  animation: depthFade 0.65s ease;
}

@keyframes depthFade {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Legal */
.legal-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem 4% 4rem;
}

.legal-content h2 { margin: 2rem 0 1rem; font-size: 1.35rem; color: var(--thought-cyan); }

.legal-content p, .legal-content li { color: var(--text-muted); margin-bottom: 1rem; }

.legal-content ul { padding-left: 1.5rem; }

/* Cookie banner */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(15, 23, 42, 0.98);
  border-top: 1px solid var(--synapse-purple);
  padding: 1rem 4%;
  z-index: 2000;
  display: none;
}

.cookie-banner.visible { display: block; }

.cookie-inner {
  max-width: 1140px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.cookie-inner p { color: var(--text-muted); font-size: 0.9rem; flex: 1; min-width: 240px; }

/* Scroll animations */
.slide-up, .fade-in {
  opacity: 1;
  transform: none;
  transition: opacity 0.4s ease, transform 0.4s ease;
}

html.js .slide-up, html.js .fade-in {
  opacity: 0;
  transform: translateY(28px);
}

html.js .slide-up.visible, html.js .fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

html.js .depth-fade {
  opacity: 0;
  transition: opacity 0.65s ease;
}

html.js .depth-fade.visible { opacity: 1; }

/* About / services */
.service-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
  margin-bottom: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid var(--neural-grey);
}

.service-block:nth-child(even) { direction: rtl; }
.service-block:nth-child(even) > * { direction: ltr; }

.team-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.team-card {
  text-align: center;
  padding: 1.5rem;
  background: rgba(51, 65, 85, 0.35);
  border-radius: 12px;
}

.contact-info {
  background: rgba(51, 65, 85, 0.4);
  padding: 2rem;
  border-radius: 12px;
  margin-bottom: 2rem;
}

.contact-info p { margin-bottom: 0.5rem; color: var(--text-muted); }

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .stats-bar { grid-template-columns: repeat(2, 1fr); }
  .node-grid, .testimonial-grid, .footer-grid, .service-block { grid-template-columns: 1fr; }
  .service-block:nth-child(even) { direction: ltr; }
  .nav-main {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--mind-midnight);
    padding: 1rem;
    border-bottom: 1px solid var(--neural-grey);
  }
  .nav-main.open { display: flex; }
  .nav-toggle { display: block; }
}
