/* ═══════════════════════════════════════════
   GRIDGATE — Shared Styles
   Dark editorial aesthetic · Cyan + Amber accents
   ═══════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400&family=Instrument+Serif:ital@0;1&display=swap');

:root {
  --black: #0a0a0a;
  --dark: #111111;
  --card: #161616;
  --card-hover: #1a1a1a;
  --border: #222222;
  --border-light: #2a2a2a;
  --border-active: #333333;
  --text-muted: #666666;
  --text-secondary: #999999;
  --text-primary: #e0e0e0;
  --text-bright: #f5f5f5;
  --white: #ffffff;
  --cyan: #00e5cc;
  --cyan-dim: #00c4ae;
  --cyan-glow: rgba(0, 229, 204, 0.12);
  --cyan-glow-strong: rgba(0, 229, 204, 0.2);
  --amber: #f5a623;
  --amber-dim: rgba(245, 166, 35, 0.12);
  --amber-glow: rgba(245, 166, 35, 0.08);
  --red-dim: rgba(220, 60, 60, 0.12);
  --serif: 'Instrument Serif', Georgia, serif;
  --sans: 'DM Sans', -apple-system, sans-serif;
  --container: 1200px;
  --container-narrow: 800px;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  background: var(--black);
  color: var(--text-primary);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}

::selection { background: var(--cyan); color: var(--black); }

/* Noise texture overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
}

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

.container { max-width: var(--container); margin: 0 auto; padding: 0 3rem; }
.container-narrow { max-width: var(--container-narrow); margin: 0 auto; padding: 0 3rem; }

/* ═══════════════════════════════════════════
   NAVIGATION
   ═══════════════════════════════════════════ */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 0 3rem;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(10, 10, 10, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
  color: var(--text-bright);
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
}

.nav-logo .mark {
  width: 28px; height: 28px;
  background: var(--cyan);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 800;
  color: var(--black);
  letter-spacing: 0;
  flex-shrink: 0;
}

.nav-center {
  display: flex;
  align-items: center;
  gap: 2.25rem;
  list-style: none;
}

.nav-center a {
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color 0.2s;
  letter-spacing: 0.005em;
  position: relative;
}

.nav-center a:hover, .nav-center a.active { color: var(--text-bright); }

.nav-center a.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0; right: 0;
  height: 1.5px;
  background: var(--cyan);
  border-radius: 1px;
}

.nav-right { display: flex; align-items: center; gap: 1rem; }

.nav-cta {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--black);
  background: var(--cyan);
  padding: 0.5rem 1.25rem;
  border-radius: 6px;
  transition: all 0.2s;
}

.nav-cta:hover { background: var(--white); transform: translateY(-1px); }

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

.nav-hamburger span {
  width: 22px; height: 1.5px;
  background: var(--text-primary);
  transition: all 0.3s;
}

/* ═══════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════ */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.8rem;
  background: var(--cyan);
  color: var(--black);
  font-size: 0.88rem;
  font-weight: 600;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: all 0.25s;
  font-family: var(--sans);
  text-decoration: none;
}

.btn-primary:hover {
  background: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 229, 204, 0.15);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.8rem;
  background: transparent;
  color: var(--text-primary);
  font-size: 0.88rem;
  font-weight: 500;
  border-radius: 8px;
  border: 1px solid var(--border-light);
  cursor: pointer;
  transition: all 0.25s;
  font-family: var(--sans);
  text-decoration: none;
}

.btn-secondary:hover { border-color: var(--text-secondary); color: var(--text-bright); }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--cyan);
  font-size: 0.88rem;
  font-weight: 600;
  transition: gap 0.2s;
  text-decoration: none;
}

.btn-ghost:hover { gap: 0.65rem; }

/* ═══════════════════════════════════════════
   TYPOGRAPHY UTILITIES
   ═══════════════════════════════════════════ */
.section-label {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.73rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--cyan);
  margin-bottom: 1.5rem;
}

.section-label::before {
  content: '';
  width: 16px; height: 1px;
  background: var(--cyan);
}

.section-heading {
  font-family: var(--serif);
  font-size: clamp(2.2rem, 4vw, 3.5rem);
  font-weight: 400;
  line-height: 1.12;
  color: var(--text-bright);
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
}

.section-heading em { font-style: italic; color: var(--cyan); }

.section-desc {
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--text-secondary);
  max-width: 600px;
}

/* ═══════════════════════════════════════════
   PAGE SECTIONS
   ═══════════════════════════════════════════ */
.page-section {
  padding: 6rem 3rem;
}

.page-section.dark { background: var(--dark); }
.page-section.black { background: var(--black); }

.page-section.bordered {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

/* Page header (used on inner pages) */
.page-header {
  padding: 8rem 3rem 4rem;
  background: var(--dark);
  border-bottom: 1px solid var(--border);
}

.page-header .section-label { margin-bottom: 1.25rem; }

.page-header h1 {
  font-family: var(--serif);
  font-size: clamp(2.8rem, 5.5vw, 4.5rem);
  font-weight: 400;
  line-height: 1.08;
  color: var(--text-bright);
  letter-spacing: -0.025em;
  max-width: 750px;
  margin-bottom: 1.5rem;
}

.page-header h1 em { font-style: italic; color: var(--cyan); }

.page-header p {
  font-size: 1.1rem;
  line-height: 1.75;
  color: var(--text-secondary);
  max-width: 600px;
}

/* ═══════════════════════════════════════════
   CARDS
   ═══════════════════════════════════════════ */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2.25rem;
  transition: all 0.3s ease;
}

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

.card-icon {
  width: 44px; height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
  font-size: 1.2rem;
}

.card-icon.cyan { background: var(--cyan-glow); }
.card-icon.amber { background: var(--amber-dim); }
.card-icon.red { background: var(--red-dim); }

.card h3 {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-bright);
  margin-bottom: 0.75rem;
  letter-spacing: -0.01em;
}

.card p {
  font-size: 0.88rem;
  line-height: 1.7;
  color: var(--text-muted);
}

.card-tag {
  display: inline-block;
  font-size: 0.67rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 0.3rem 0.7rem;
  border-radius: 4px;
  margin-bottom: 1.25rem;
}

.card-tag.cyan { color: var(--cyan); background: var(--cyan-glow); }
.card-tag.amber { color: var(--amber); background: var(--amber-dim); }

/* ═══════════════════════════════════════════
   GRID LAYOUTS
   ═══════════════════════════════════════════ */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}

/* ═══════════════════════════════════════════
   STATS BAR
   ═══════════════════════════════════════════ */
.stats-bar {
  display: flex;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.stat-item {
  flex: 1;
  padding: 2.25rem 3rem;
  border-right: 1px solid var(--border);
}

.stat-item:last-child { border-right: none; }

.stat-number {
  font-family: var(--serif);
  font-size: 2.4rem;
  font-weight: 400;
  color: var(--text-bright);
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 0.35rem;
}

.stat-number span { color: var(--cyan); }

.stat-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 500;
  line-height: 1.5;
}

/* ═══════════════════════════════════════════
   TABLE
   ═══════════════════════════════════════════ */
.data-table {
  width: 100%;
  border-collapse: collapse;
}

.data-table th {
  text-align: left;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  padding: 0 1rem 1rem;
  border-bottom: 1px solid var(--border);
}

.data-table th.highlight { color: var(--cyan); }

.data-table td {
  padding: 1rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

.data-table td:first-child { font-weight: 600; color: var(--text-primary); }
.data-table .check { color: var(--cyan); font-weight: 700; }
.data-table .dash { color: var(--text-muted); }
.data-table .roadmap { color: var(--amber); font-size: 0.78rem; font-weight: 500; }

/* ═══════════════════════════════════════════
   FORMS
   ═══════════════════════════════════════════ */
.form-group { margin-bottom: 1.25rem; }

.form-group label {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.85rem 1rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-primary);
  font-family: var(--sans);
  font-size: 0.9rem;
  transition: border-color 0.2s;
  outline: none;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-muted);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--cyan);
}

.form-group textarea { resize: vertical; min-height: 120px; }
.form-group select option { background: var(--card); }

/* ═══════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════ */
footer {
  padding: 4rem 3rem 3rem;
  border-top: 1px solid var(--border);
  background: var(--black);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-brand .nav-logo { margin-bottom: 1rem; }

.footer-brand p {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.6;
  max-width: 300px;
}

.footer-col h4 {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

.footer-col ul { list-style: none; }

.footer-col li { margin-bottom: 0.6rem; }

.footer-col a {
  font-size: 0.85rem;
  color: var(--text-muted);
  transition: color 0.2s;
}

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

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-bottom .copy {
  font-size: 0.76rem;
  color: var(--text-muted);
}

.footer-bottom .socials {
  display: flex;
  gap: 1.5rem;
  list-style: none;
}

.footer-bottom .socials a {
  font-size: 0.78rem;
  color: var(--text-muted);
  transition: color 0.2s;
}

.footer-bottom .socials a:hover { color: var(--cyan); }

/* ═══════════════════════════════════════════
   ANIMATIONS
   ═══════════════════════════════════════════ */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
  0% { opacity: 0.35; transform: scale(1); }
  100% { opacity: 0.6; transform: scale(1.12); }
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.stagger-1 { transition-delay: 0.05s; }
.stagger-2 { transition-delay: 0.1s; }
.stagger-3 { transition-delay: 0.15s; }
.stagger-4 { transition-delay: 0.2s; }
.stagger-5 { transition-delay: 0.25s; }
.stagger-6 { transition-delay: 0.3s; }

/* ═══════════════════════════════════════════
   PILL / TAG LIST
   ═══════════════════════════════════════════ */
.pill-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1.25rem;
}

.pill-list li {
  font-size: 0.76rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: rgba(255,255,255,0.04);
  padding: 0.4rem 0.85rem;
  border-radius: 100px;
  border: 1px solid var(--border);
}

/* ═══════════════════════════════════════════
   PROSE (for long-form text blocks)
   ═══════════════════════════════════════════ */
.prose { max-width: 680px; }

.prose p {
  font-size: 1.02rem;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.prose p strong { color: var(--text-primary); font-weight: 600; }

.prose h3 {
  font-family: var(--serif);
  font-size: 1.6rem;
  font-weight: 400;
  color: var(--text-bright);
  margin: 2.5rem 0 1rem;
  letter-spacing: -0.01em;
}

/* ═══════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════ */
@media (max-width: 1024px) {
  nav { padding: 0 1.5rem; }
  .container, .container-narrow { padding: 0 1.5rem; }
  .page-section, .page-header { padding-left: 1.5rem; padding-right: 1.5rem; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .grid-4 { grid-template-columns: 1fr 1fr; }
  .two-col { grid-template-columns: 1fr; gap: 3rem; }
}

@media (max-width: 768px) {
  nav { padding: 0 1rem; }
  .nav-center { display: none; }
  .nav-hamburger { display: flex; }
  .nav-center.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 64px; left: 0; right: 0;
    background: var(--dark);
    border-bottom: 1px solid var(--border);
    padding: 1.5rem;
    gap: 1rem;
  }
  .page-header { padding: 7rem 1.5rem 3rem; }
  .page-section { padding: 4rem 1.5rem; }
  .stats-bar { flex-direction: column; }
  .stat-item { border-right: none; border-bottom: 1px solid var(--border); padding: 1.5rem; }
  .stat-item:last-child { border-bottom: none; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .two-col { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; gap: 1rem; text-align: center; }
  footer { padding: 3rem 1.5rem 2rem; }
}
