/* ── Varuolo shared design — Signal + Tech ── */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=Inter:wght@300;400;500;600;700&display=swap');

:root {
  --bg0: #060e1f;
  --bg1: #0a1628;
  --bg2: #0e1d35;
  --accent1: #3b7dff;
  --accent2: #0dc5e0;
  --accent3: #1ae8c0;
  --accent4: #6e6ef7;
  --text: #e4ecff;
  --muted: rgba(228,236,255,0.60);
  --dim: rgba(228,236,255,0.38);
  --border: rgba(255,255,255,0.07);
  --glass: rgba(10,22,40,0.65);
  --max: 980px;
  --r: 22px;
  --headerH: 72px;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }

body {
  color: var(--text);
  background: var(--bg0);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
a:focus { outline: 2px solid rgba(59,125,255,0.8); outline-offset: 3px; border-radius: 10px; }

/* ── Canvas + ambient ── */
canvas#bg { position: fixed; inset: 0; z-index: -2; width: 100%; height: 100%; }

.ambient {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(ellipse 600px 400px at 20% 25%, rgba(59,125,255,0.06), transparent 70%),
    radial-gradient(ellipse 500px 350px at 75% 20%, rgba(110,110,247,0.04), transparent 70%),
    radial-gradient(ellipse 600px 400px at 55% 85%, rgba(13,197,224,0.03), transparent 70%);
}

.grain {
  position: fixed; inset: 0; pointer-events: none; z-index: 0; opacity: 0.028;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 512 512' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  background-size: 200px 200px;
}

/* ── Header ── */
.header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 2000;
  padding: 10px 16px; pointer-events: none;
}

.headerInner {
  position: relative;
  width: min(var(--max), 100%);
  margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 9px 18px;
  border-radius: 999px;
  background: rgba(6,14,31,0.6);
  border: 1px solid rgba(255,255,255,0.05);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 6px 28px rgba(0,0,0,0.35);
  pointer-events: auto;
  transition: all 280ms ease;
}

.header.scrolled .headerInner {
  background: rgba(6,14,31,0.82);
  border-color: rgba(255,255,255,0.07);
  box-shadow: 0 10px 36px rgba(0,0,0,0.45);
}

.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; flex-shrink: 0; }

.logo {
  width: 36px; height: 36px; border-radius: 10px; flex-shrink: 0;
  background: linear-gradient(145deg, #0a1628, #0e1d35);
  border: 1px solid rgba(59,125,255,0.2);
  box-shadow: 0 0 16px rgba(59,125,255,0.12);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; position: relative;
}

.logo svg { width: 28px; height: 28px; position: relative; z-index: 1; }

.logo::after {
  content: ""; position: absolute; inset: -60%;
  background: linear-gradient(120deg, transparent 30%, rgba(13,197,224,0.08) 50%, transparent 70%);
  animation: sheen 5s ease-in-out infinite;
}

@keyframes sheen {
  0% { transform: translateX(-90%) rotate(18deg); }
  100% { transform: translateX(90%) rotate(18deg); }
}

.wordmark {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 600; font-size: 16px; letter-spacing: 0.4px;
  background: linear-gradient(90deg, #fff, var(--accent2));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

.submark {
  font-size: 11px; color: var(--dim); letter-spacing: 1.8px;
  text-transform: uppercase; margin-top: -2px;
}

.navlinks, nav {
  display: flex; align-items: center; gap: 3px;
  overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.navlinks::-webkit-scrollbar, nav::-webkit-scrollbar { display: none; }

.pill {
  display: inline-flex; padding: 6px 13px; border-radius: 999px;
  font-size: 13px; font-weight: 500; color: rgba(228,236,255,0.65);
  white-space: nowrap; border: 1px solid transparent;
  text-decoration: none; transition: all 180ms ease;
}

.pill:hover { color: #fff; background: rgba(255,255,255,0.05); border-color: rgba(255,255,255,0.07); }
.pill.active { color: #fff; background: rgba(59,125,255,0.12); border-color: rgba(59,125,255,0.25); box-shadow: 0 0 10px rgba(59,125,255,0.1); }

.navSep { width: 1px; height: 15px; background: rgba(255,255,255,0.08); margin: 0 4px; flex-shrink: 0; }

/* ── Page layout ── */
.page-main {
  position: relative; z-index: 1;
  padding: calc(var(--headerH) + 28px) 16px 40px 16px;
}

.panel {
  max-width: var(--max);
  margin: 0 auto;
  padding: 40px 36px 36px 36px;
  border-radius: var(--r);
  border: 1px solid var(--border);
  background: var(--glass);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  position: relative; overflow: hidden;
}

.panel::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.06), transparent);
}

.page-subtitle {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 11px; font-weight: 600; letter-spacing: 2.5px;
  text-transform: uppercase; color: var(--accent2); margin-bottom: 6px;
}

.page-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(28px, 4vw, 42px); font-weight: 700;
  line-height: 1.1; margin: 0 0 16px 0; color: #fff;
}

.page-lead {
  max-width: 64ch; color: var(--muted); font-size: 16px;
  line-height: 1.7; margin-bottom: 28px;
}

.section-heading {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 18px; font-weight: 600; margin: 28px 0 10px 0;
  color: #fff; letter-spacing: -0.01em;
  padding-top: 20px; border-top: 1px solid rgba(255,255,255,0.05);
}

.section-heading:first-of-type { border-top: none; padding-top: 0; }

.text-block {
  color: var(--muted); font-size: 15px; line-height: 1.7;
  max-width: 72ch; margin-bottom: 12px;
}

.text-block strong { color: rgba(228,236,255,0.85); }

/* ── Cards ── */
.card-grid {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: 12px; margin: 16px 0;
}

.info-card {
  padding: 20px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: rgba(8,15,34,0.5);
  transition: all 200ms ease;
}

.info-card:hover {
  border-color: rgba(59,125,255,0.15);
  background: rgba(8,15,34,0.7);
}

.info-card h3 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 15px; font-weight: 600; margin: 0 0 6px 0; color: #fff;
}

.info-card p {
  margin: 0; color: var(--muted); font-size: 14px; line-height: 1.6;
}

/* ── Info grid (key-value) ── */
.info-grid {
  display: grid; grid-template-columns: 110px 1fr;
  gap: 6px 16px; margin: 12px 0 20px 0;
  font-size: 15px;
}

.info-label { color: var(--dim); font-weight: 500; }
.info-value { color: rgba(228,236,255,0.85); }

/* ── Badges ── */
.badge-row { display: flex; flex-wrap: wrap; gap: 7px; margin: 12px 0; }

.badge {
  display: inline-flex; padding: 5px 12px; border-radius: 999px;
  font-size: 12px; font-weight: 500; color: rgba(228,236,255,0.6);
  border: 1px solid rgba(255,255,255,0.06);
  background: rgba(255,255,255,0.02);
}

/* ── Lists ── */
.styled-list {
  padding: 0; margin: 12px 0; list-style: none;
}

.styled-list li {
  position: relative; padding-left: 16px; margin: 8px 0;
  color: var(--muted); font-size: 14.5px; line-height: 1.6;
}

.styled-list li::before {
  content: ""; position: absolute; left: 0; top: 9px;
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--accent2); opacity: 0.4;
  box-shadow: 0 0 5px rgba(13,197,224,0.2);
}

.styled-list li strong { color: rgba(228,236,255,0.85); }

/* ── Footer ── */
.page-footer {
  position: relative; z-index: 1;
  max-width: var(--max); margin: 16px auto 32px auto;
  padding: 0 20px;
  display: flex; justify-content: space-between; flex-wrap: wrap;
  gap: 10px; color: var(--dim); font-size: 13px;
}

.page-footer a { text-decoration: none; border-bottom: 1px solid rgba(255,255,255,0.08); }
.page-footer a:hover { border-color: var(--accent2); }
.footer-links { display: flex; gap: 14px; flex-wrap: wrap; }

/* ── Responsive ── */
@media (max-width: 700px) {
  .card-grid { grid-template-columns: 1fr; }
  .panel { padding: 28px 18px 24px 18px; }
  .brand .brandText, .brand > div:last-child { display: none; }
  .info-grid { grid-template-columns: 1fr; gap: 2px 0; }
  .info-label { margin-top: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  .logo::after { animation: none; }
}
