:root {
  --bg: #07111f;
  --bg-deep: #050b14;
  --surface: #0d1a2b;
  --surface-2: #111f33;
  --surface-3: #14253c;
  --text: #f1f5f9;
  --muted: #94a3b8;
  --muted-2: #64748b;
  --accent: #38bdf8;
  --accent-2: #2dd4bf;
  --border: #22324a;
  --border-light: rgba(148, 163, 184, 0.18);
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.28);
  --radius: 18px;
  --radius-sm: 12px;
  --max-width: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--text);
  background: var(--bg);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
}

body::selection { background: rgba(56, 189, 248, 0.28); }
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
button, input, textarea { font: inherit; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 1000;
  transform: translateY(-150%);
  padding: 0.75rem 1rem;
  color: var(--bg-deep);
  background: var(--accent);
  border-radius: 8px;
  font-weight: 700;
}
.skip-link:focus { transform: translateY(0); }

.container {
  width: min(calc(100% - 2rem), var(--max-width));
  margin: 0 auto;
}

.section-pad { padding: 7rem 0; }
.section { position: relative; }
.alt-section { background: rgba(13, 26, 43, 0.62); border-block: 1px solid var(--border-light); }

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 100;
  padding: 1rem 0;
  transition: background 180ms ease, border-color 180ms ease, backdrop-filter 180ms ease;
}
.site-header.scrolled {
  background: rgba(5, 11, 20, 0.78);
  border-bottom: 1px solid var(--border-light);
  backdrop-filter: blur(18px);
}

.nav-wrap { display: flex; align-items: center; justify-content: space-between; gap: 2rem; }
.brand { display: inline-flex; align-items: center; gap: 0.7rem; font-weight: 800; letter-spacing: 0.055em; }
.brand-mark {
  display: grid;
  place-items: center;
  width: 2rem;
  aspect-ratio: 1;
  border: 1px solid rgba(56, 189, 248, 0.55);
  border-radius: 8px;
  color: var(--accent);
  background: rgba(56, 189, 248, 0.09);
  box-shadow: inset 0 0 22px rgba(56, 189, 248, 0.08);
}
.brand-accent { color: var(--accent); }
.site-nav { display: flex; align-items: center; gap: 0.35rem; }
.site-nav a {
  padding: 0.55rem 0.85rem;
  color: var(--muted);
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  transition: color 160ms ease, background 160ms ease;
}
.site-nav a:hover, .site-nav a:focus-visible, .site-nav a.active { color: var(--text); background: rgba(148, 163, 184, 0.08); }
.menu-toggle { display: none; border: 0; background: transparent; padding: 0.5rem; cursor: pointer; }
.menu-toggle span:not(.sr-only) { display: block; width: 24px; height: 2px; margin: 5px 0; background: var(--text); border-radius: 999px; }

.hero { position: relative; min-height: 100vh; display: grid; align-items: center; overflow: hidden; padding-top: 9.5rem; }
.grid-overlay {
  position: absolute;
  inset: 0;
  opacity: 0.15;
  background-image: linear-gradient(rgba(56, 189, 248, 0.08) 1px, transparent 1px), linear-gradient(90deg, rgba(56, 189, 248, 0.08) 1px, transparent 1px);
  background-size: 54px 54px;
  mask-image: linear-gradient(to bottom, black, transparent 92%);
}
.hero-glow { position: absolute; border-radius: 50%; filter: blur(90px); opacity: 0.18; }
.hero-glow-one { width: 420px; height: 420px; background: var(--accent); top: 3%; right: 8%; }
.hero-glow-two { width: 320px; height: 320px; background: var(--accent-2); bottom: 4%; left: -8%; opacity: 0.11; }
.hero-grid { position: relative; display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 5rem; align-items: center; }
.eyebrow {
  margin: 0 0 1rem;
  color: var(--accent);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.status-dot { display: inline-block; width: 8px; height: 8px; margin-right: 0.55rem; border-radius: 50%; background: var(--accent-2); box-shadow: 0 0 0 5px rgba(45, 212, 191, 0.1); }
h1, h2, h3 { margin: 0; line-height: 1.08; letter-spacing: -0.035em; }
h1 { max-width: 760px; font-size: clamp(3rem, 6.3vw, 5.6rem); }
h1 span { color: transparent; background: linear-gradient(105deg, var(--accent), #8bdcff 62%, var(--accent-2)); background-clip: text; -webkit-background-clip: text; }
h2 { font-size: clamp(2.15rem, 4vw, 3.6rem); }
h3 { font-size: clamp(1.35rem, 2.2vw, 2rem); }
.hero-text { max-width: 670px; margin: 1.6rem 0 2rem; color: var(--muted); font-size: 1.08rem; }
.button-row { display: flex; flex-wrap: wrap; gap: 0.85rem; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.78rem 1.1rem;
  border: 1px solid transparent;
  border-radius: 10px;
  font-weight: 750;
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}
.button:hover { transform: translateY(-2px); }
.button-primary { color: #03111b; background: linear-gradient(135deg, var(--accent), #79d8ff); box-shadow: 0 12px 36px rgba(56, 189, 248, 0.19); }
.button-primary:hover { box-shadow: 0 16px 45px rgba(56, 189, 248, 0.28); }
.button-secondary { color: var(--text); border-color: var(--border); background: rgba(17, 31, 51, 0.58); }
.button-secondary:hover { border-color: rgba(56, 189, 248, 0.5); background: rgba(17, 31, 51, 0.86); }
.quick-facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; margin-top: 3.1rem; padding-top: 1.6rem; border-top: 1px solid var(--border-light); }
.quick-facts div { display: grid; gap: 0.2rem; }
.quick-facts strong { font-size: 0.95rem; }
.quick-facts span { color: var(--muted-2); font-size: 0.78rem; line-height: 1.4; }

.hero-visual {
  position: relative;
  min-height: 520px;
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-radius: 22px;
  background: linear-gradient(145deg, rgba(17, 31, 51, 0.92), rgba(7, 17, 31, 0.86));
  box-shadow: var(--shadow), inset 0 0 70px rgba(56, 189, 248, 0.035);
  overflow: hidden;
}
.hero-visual::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(56, 189, 248, 0.14) 1px, transparent 1px); background-size: 22px 22px; mask-image: linear-gradient(to bottom, black, transparent 86%); }
.visual-topbar, .visual-footer { position: relative; z-index: 2; display: flex; align-items: center; justify-content: space-between; padding: 1rem 1.2rem; color: var(--muted-2); font-family: "SFMono-Regular", Consolas, monospace; font-size: 0.7rem; letter-spacing: 0.13em; }
.visual-topbar { border-bottom: 1px solid var(--border-light); }
.visual-footer { border-top: 1px solid var(--border-light); }
.live-label { display: flex; align-items: center; gap: 0.45rem; color: var(--accent-2); }
.live-label span { width: 7px; height: 7px; border-radius: 50%; background: var(--accent-2); box-shadow: 0 0 12px var(--accent-2); animation: pulse 1.8s infinite; }
.visual-footer { justify-content: space-around; }
.network-map { position: relative; width: 100%; height: 430px; }
.map-lines path { fill: none; stroke: url(#lineGradient); stroke-width: 2; stroke-dasharray: 9 10; animation: dash 12s linear infinite; }
.data-pulses circle { fill: var(--accent-2); }
.node text { fill: var(--muted); font-family: "SFMono-Regular", Consolas, monospace; font-size: 12px; letter-spacing: 0.14em; text-anchor: middle; }
.node path { fill: none; stroke: var(--accent); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.node-ring { fill: rgba(56, 189, 248, 0.035); stroke: rgba(56, 189, 248, 0.22); stroke-width: 1.5; }
.node-core { fill: rgba(9, 24, 40, 0.95); stroke: rgba(56, 189, 248, 0.45); stroke-width: 1.5; }
.central-node .node-ring { animation: ringPulse 3.2s ease-in-out infinite; }
.muted-node { opacity: 0.5; }

.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 2rem; margin-bottom: 2.2rem; }
.text-link { color: var(--muted); font-weight: 700; }
.text-link:hover { color: var(--accent); }
.featured-card { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 0; border: 1px solid var(--border); border-radius: var(--radius); background: linear-gradient(135deg, rgba(17, 31, 51, 0.92), rgba(10, 22, 37, 0.96)); overflow: hidden; box-shadow: 0 24px 80px rgba(0, 0, 0, 0.2); }
.featured-copy { padding: clamp(2rem, 4vw, 3.4rem); }
.tag-row { display: flex; flex-wrap: wrap; gap: 0.55rem; margin-bottom: 2.4rem; }
.tag { padding: 0.35rem 0.65rem; border: 1px solid var(--border); border-radius: 999px; color: var(--muted); background: rgba(148, 163, 184, 0.035); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.055em; text-transform: uppercase; }
.tag-active { color: var(--accent-2); border-color: rgba(45, 212, 191, 0.3); background: rgba(45, 212, 191, 0.07); }
.project-number { margin: 0 0 0.7rem; color: var(--muted-2); font-family: "SFMono-Regular", Consolas, monospace; font-size: 0.72rem; letter-spacing: 0.15em; }
.featured-copy > p:not(.project-number) { color: var(--muted); max-width: 680px; }
.project-details { display: grid; gap: 0.85rem; margin: 2rem 0 2.2rem; }
.project-details div { display: grid; grid-template-columns: 90px 1fr; gap: 1rem; padding-bottom: 0.75rem; border-bottom: 1px solid var(--border-light); }
.project-details dt { color: var(--muted-2); font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; }
.project-details dd { margin: 0; color: var(--text); }
.featured-panel { position: relative; display: grid; grid-template-rows: auto 1fr auto; min-height: 490px; padding: 1.5rem; border-left: 1px solid var(--border); background: radial-gradient(circle at center, rgba(56, 189, 248, 0.09), transparent 56%), rgba(5, 13, 23, 0.6); overflow: hidden; }
.featured-panel::before { content: ""; position: absolute; inset: 0; opacity: 0.18; background-image: linear-gradient(rgba(56, 189, 248, 0.09) 1px, transparent 1px), linear-gradient(90deg, rgba(56, 189, 248, 0.09) 1px, transparent 1px); background-size: 35px 35px; }
.mini-map-label { position: relative; z-index: 2; display: flex; align-items: center; gap: 0.5rem; color: var(--muted); font-family: "SFMono-Regular", Consolas, monospace; font-size: 0.7rem; letter-spacing: 0.12em; }
.mini-map-label span { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 12px rgba(56, 189, 248, 0.8); }
.mini-map { position: relative; min-height: 320px; }
.mini-core, .mini-site { position: absolute; z-index: 2; display: grid; place-items: center; border-radius: 50%; font-family: "SFMono-Regular", Consolas, monospace; font-size: 0.75rem; font-weight: 700; }
.mini-core { width: 92px; height: 92px; left: 50%; top: 50%; transform: translate(-50%, -50%); color: var(--accent); border: 1px solid rgba(56, 189, 248, 0.55); background: rgba(7, 17, 31, 0.95); box-shadow: 0 0 40px rgba(56, 189, 248, 0.12); }
.mini-site { width: 60px; height: 60px; color: var(--muted); border: 1px solid var(--border); background: rgba(13, 26, 43, 0.96); }
.site-a { left: 8%; top: 18%; }.site-b { right: 8%; top: 20%; }.site-c { left: 50%; bottom: 0; transform: translateX(-50%); }
.mini-line { position: absolute; z-index: 1; height: 1px; background: linear-gradient(90deg, transparent, var(--accent), transparent); transform-origin: left center; opacity: 0.55; }
.line-a { width: 42%; left: 19%; top: 36%; transform: rotate(18deg); }
.line-b { width: 40%; left: 52%; top: 48%; transform: rotate(-24deg); }
.line-c { width: 32%; left: 51%; top: 58%; transform: rotate(90deg); }
.mini-stats { position: relative; z-index: 2; display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.7rem; }
.mini-stats div { padding: 0.8rem; border: 1px solid var(--border-light); border-radius: 10px; color: var(--muted-2); background: rgba(7, 17, 31, 0.6); font-size: 0.7rem; text-align: center; }
.mini-stats span { display: block; margin-bottom: 0.15rem; color: var(--text); font-size: 1rem; font-weight: 800; }

.process-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.info-card { min-height: 220px; padding: 1.6rem; border: 1px solid var(--border); border-radius: var(--radius-sm); background: linear-gradient(145deg, rgba(17, 31, 51, 0.72), rgba(13, 26, 43, 0.78)); transition: transform 180ms ease, border-color 180ms ease, background 180ms ease; }
.info-card:hover { transform: translateY(-5px); border-color: rgba(56, 189, 248, 0.32); background: rgba(17, 31, 51, 0.92); }
.card-index { display: inline-flex; margin-bottom: 3.1rem; color: var(--accent); font-family: "SFMono-Regular", Consolas, monospace; font-size: 0.75rem; }
.info-card p { margin-bottom: 0; color: var(--muted); }

.contact-cta { padding-top: 5.5rem; }
.cta-box { display: flex; align-items: center; justify-content: space-between; gap: 2rem; padding: clamp(2rem, 5vw, 4rem); border: 1px solid rgba(56, 189, 248, 0.22); border-radius: var(--radius); background: radial-gradient(circle at 15% 20%, rgba(56, 189, 248, 0.1), transparent 34%), linear-gradient(135deg, rgba(17, 31, 51, 0.9), rgba(7, 17, 31, 0.96)); }
.cta-box h2 { max-width: 800px; font-size: clamp(1.8rem, 3.5vw, 3rem); }
.cta-box p:not(.eyebrow) { max-width: 720px; color: var(--muted); }

.site-footer { padding: 2.5rem 0; border-top: 1px solid var(--border-light); background: var(--bg-deep); }
.footer-wrap { display: grid; grid-template-columns: 1fr auto; gap: 2rem; align-items: end; }
.footer-brand { margin-bottom: 0.8rem; }
.footer-wrap p { margin: 0; color: var(--muted-2); font-size: 0.85rem; }
.footer-links { display: flex; gap: 1.2rem; color: var(--muted); font-size: 0.9rem; }
.footer-links a:hover { color: var(--accent); }
.copyright { grid-column: 1 / -1; padding-top: 1.4rem; border-top: 1px solid var(--border-light); }

/* Inner pages */
.page-hero { position: relative; padding: 10.5rem 0 5rem; overflow: hidden; border-bottom: 1px solid var(--border-light); }
.page-hero::before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 75% 10%, rgba(56, 189, 248, 0.14), transparent 32%); }
.page-hero .container { position: relative; }
.page-hero h1 { max-width: 900px; font-size: clamp(2.8rem, 6vw, 5rem); }
.page-hero p:not(.eyebrow) { max-width: 740px; color: var(--muted); font-size: 1.08rem; }
.content-section { padding: 5.5rem 0; }
.project-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.2rem; }
.project-card { display: flex; flex-direction: column; min-height: 420px; padding: 1.6rem; border: 1px solid var(--border); border-radius: var(--radius); background: linear-gradient(145deg, rgba(17, 31, 51, 0.86), rgba(8, 20, 34, 0.94)); transition: transform 180ms ease, border-color 180ms ease; }
.project-card:hover { transform: translateY(-5px); border-color: rgba(56, 189, 248, 0.35); }
.project-card-visual { position: relative; min-height: 200px; margin-bottom: 1.4rem; border: 1px solid var(--border-light); border-radius: 12px; background: radial-gradient(circle, rgba(56, 189, 248, 0.16), transparent 52%), rgba(5, 13, 23, 0.9); overflow: hidden; }
.project-card-visual::before { content: ""; position: absolute; inset: 0; opacity: 0.25; background-image: linear-gradient(rgba(56, 189, 248, 0.08) 1px, transparent 1px), linear-gradient(90deg, rgba(56, 189, 248, 0.08) 1px, transparent 1px); background-size: 28px 28px; }
.project-card h2 { font-size: 1.65rem; }
.project-card p { color: var(--muted); }
.project-card .text-link { margin-top: auto; }
.project-card-topology span { position: absolute; z-index: 2; display: grid; place-items: center; width: 54px; height: 54px; border: 1px solid rgba(56, 189, 248, 0.36); border-radius: 50%; color: var(--accent); background: #0b1726; font-size: 0.7rem; font-weight: 700; }
.project-card-topology span:nth-child(1) { left: 50%; top: 50%; transform: translate(-50%, -50%); width: 72px; height: 72px; }
.project-card-topology span:nth-child(2) { left: 12%; top: 20%; }
.project-card-topology span:nth-child(3) { right: 12%; top: 22%; }
.project-card-topology span:nth-child(4) { left: 50%; bottom: 8%; transform: translateX(-50%); }
.project-card-topology::after { content: ""; position: absolute; left: 20%; right: 20%; top: 50%; height: 1px; background: var(--accent); box-shadow: 0 -75px 0 rgba(56, 189, 248, 0.3), 0 65px 0 rgba(56, 189, 248, 0.3); opacity: 0.5; }
.placeholder-card { opacity: 0.48; }
.placeholder-card .project-card-visual { display: grid; place-items: center; color: var(--muted-2); font-family: "SFMono-Regular", Consolas, monospace; font-size: 0.78rem; letter-spacing: 0.12em; }

.two-column { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(260px, 0.55fr); gap: 4rem; align-items: start; }
.prose h2 { margin-top: 3.2rem; font-size: 2rem; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { margin-top: 2rem; font-size: 1.25rem; }
.prose p, .prose li { color: var(--muted); }
.prose ul { padding-left: 1.2rem; }
.prose li + li { margin-top: 0.55rem; }
.sidebar-card { position: sticky; top: 7.5rem; padding: 1.4rem; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); }
.sidebar-card h2 { margin-bottom: 1.1rem; font-size: 1rem; letter-spacing: 0; }
.sidebar-list { display: grid; gap: 0.9rem; margin: 0; }
.sidebar-list div { padding-bottom: 0.8rem; border-bottom: 1px solid var(--border-light); }
.sidebar-list div:last-child { padding-bottom: 0; border: 0; }
.sidebar-list dt { color: var(--muted-2); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; }
.sidebar-list dd { margin: 0.2rem 0 0; color: var(--text); }
.site-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.9rem; margin-top: 1.4rem; }
.site-list article { padding: 1rem; border: 1px solid var(--border); border-radius: 10px; background: rgba(17, 31, 51, 0.52); }
.site-list span { color: var(--accent); font-family: "SFMono-Regular", Consolas, monospace; font-size: 0.68rem; letter-spacing: 0.1em; }
.site-list h3 { margin-top: 0.55rem; font-size: 1rem; }
.site-list p { margin-bottom: 0; font-size: 0.85rem; }
.callout { margin: 2rem 0; padding: 1.2rem 1.3rem; border-left: 3px solid var(--accent); border-radius: 0 10px 10px 0; background: rgba(56, 189, 248, 0.07); color: var(--muted); }
.contact-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.contact-card { min-height: 180px; padding: 1.4rem; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); }
.contact-card span { color: var(--accent); font-family: "SFMono-Regular", Consolas, monospace; font-size: 0.72rem; letter-spacing: 0.1em; }
.contact-card h2 { margin-top: 1.5rem; font-size: 1.3rem; }
.contact-card p { color: var(--muted); }
.contact-card a { color: var(--accent); font-weight: 700; }

.reveal { opacity: 0; transform: translateY(18px); transition: opacity 600ms ease, transform 600ms ease; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

@keyframes pulse { 0%, 100% { opacity: 0.45; transform: scale(0.8); } 50% { opacity: 1; transform: scale(1.15); } }
@keyframes dash { to { stroke-dashoffset: -190; } }
@keyframes ringPulse { 0%, 100% { r: 60; opacity: 0.58; } 50% { r: 66; opacity: 0.2; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
  .reveal { opacity: 1; transform: none; }
}

@media (max-width: 980px) {
  .hero-grid, .featured-card, .two-column { grid-template-columns: 1fr; }
  .hero-grid { gap: 3.5rem; }
  .hero-visual { min-height: auto; }
  .featured-panel { min-height: 430px; border-left: 0; border-top: 1px solid var(--border); }
  .two-column { gap: 2.5rem; }
  .sidebar-card { position: static; }
}

@media (max-width: 760px) {
  .section-pad { padding: 5rem 0; }
  .site-header { padding: 0.8rem 0; }
  .menu-toggle { display: block; }
  .site-nav { position: absolute; top: calc(100% + 0.4rem); left: 1rem; right: 1rem; display: none; flex-direction: column; align-items: stretch; padding: 0.8rem; border: 1px solid var(--border); border-radius: 12px; background: rgba(5, 11, 20, 0.96); backdrop-filter: blur(18px); }
  .site-nav.open { display: flex; }
  .site-nav a { padding: 0.8rem 0.9rem; }
  .hero { min-height: auto; padding-top: 8.5rem; }
  .hero-grid { gap: 3rem; }
  h1 { font-size: clamp(2.7rem, 12vw, 4.5rem); }
  .quick-facts, .process-grid, .project-grid, .contact-grid, .site-list { grid-template-columns: 1fr; }
  .hero-visual { min-height: 450px; }
  .network-map { height: 360px; }
  .section-heading { align-items: start; flex-direction: column; }
  .cta-box { align-items: flex-start; flex-direction: column; }
  .footer-wrap { grid-template-columns: 1fr; align-items: start; }
  .footer-links { flex-wrap: wrap; }
  .project-details div { grid-template-columns: 1fr; gap: 0.2rem; }
}
