:root {
  --ink: #071b31;
  --ink-soft: #18344f;
  --paper: #f4f8fc;
  --white: #ffffff;
  --line: #c9d8e6;
  --blue: #206bff;
  --cyan: #3ee1d1;
  --orange: #ff7347;
  --muted: #60768b;
  --display: "Space Grotesk", sans-serif;
  --body: "DM Sans", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--paper); font-family: var(--body); font-size: 1rem; line-height: 1.6; }
a { color: inherit; text-decoration: none; }
button, a { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; }
.skip-link { position: fixed; z-index: 100; top: 1rem; left: 1rem; padding: .7rem 1rem; color: white; background: var(--ink); transform: translateY(-200%); }
.skip-link:focus { transform: translateY(0); }

.site-header { position: absolute; z-index: 20; inset: 0 0 auto; height: 88px; max-width: 1440px; margin: auto; padding: 0 clamp(1.25rem, 4vw, 4.5rem); display: flex; align-items: center; justify-content: space-between; color: white; }
.brand { display: flex; align-items: center; gap: .75rem; font-family: var(--display); font-weight: 600; }
.brand-mark { display: grid; place-items: center; width: 38px; height: 38px; color: var(--ink); background: var(--cyan); border-radius: 50%; font-size: .82rem; font-weight: 700; }
nav { display: flex; gap: clamp(1.25rem, 3vw, 2.5rem); }
nav a, .header-cta { font-size: .92rem; font-weight: 600; }
nav a { color: #c6d4e0; }
nav a:hover { color: white; }
.header-cta { padding: .68rem 1rem; border: 1px solid rgba(255,255,255,.35); border-radius: 4px; }
.header-cta:hover { background: white; color: var(--ink); }
.menu-button, .mobile-menu { display: none; }

.hero { min-height: 780px; padding: 10rem max(1.25rem, calc((100vw - 1300px) / 2)) 6.5rem; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(420px, .95fr); align-items: center; gap: clamp(3rem, 7vw, 7rem); color: white; background: var(--ink); overflow: hidden; }
.hero-copy { max-width: 690px; }
.availability { display: flex; align-items: center; gap: .6rem; margin: 0 0 1.5rem; color: #bed0df; font-weight: 600; }
.availability span { width: 9px; height: 9px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 0 6px rgba(62,225,209,.12); }
h1, h2, h3 { margin: 0; font-family: var(--display); line-height: 1.05; letter-spacing: -.035em; }
h1 { max-width: 700px; font-size: clamp(3rem, 6.8vw, 6.7rem); }
.hero-intro { max-width: 630px; margin: 1.75rem 0 0; color: #c7d5e1; font-size: clamp(1.08rem, 1.6vw, 1.32rem); line-height: 1.55; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2.2rem; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 50px; padding: .8rem 1.2rem; border: 1px solid transparent; border-radius: 4px; font-weight: 700; transition: transform .2s, background .2s, color .2s; }
.button:hover { transform: translateY(-2px); }
.button-primary { color: var(--ink); background: var(--cyan); }
.button-primary:hover { background: white; }
.button-secondary { color: white; border-color: #536a80; }
.button-secondary:hover { border-color: white; }
.quick-facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin: 3.8rem 0 0; padding: 0; list-style: none; }
.quick-facts li { padding-top: .9rem; border-top: 1px solid #395068; }
.quick-facts strong, .quick-facts span { display: block; }
.quick-facts strong { font-family: var(--display); font-size: 1rem; }
.quick-facts span { margin-top: .25rem; color: #9fb3c5; font-size: .82rem; line-height: 1.4; }

.system-board { width: min(100%, 570px); justify-self: end; border: 1px solid #3a526a; background: #0b233b; box-shadow: 24px 24px 0 rgba(32,107,255,.16); transform: rotate(1.5deg); }
.board-header { height: 44px; padding: 0 1rem; display: flex; align-items: center; justify-content: space-between; color: #a9bdce; border-bottom: 1px solid #3a526a; font-size: .78rem; }
.pulse { display: flex; align-items: center; gap: .35rem; color: var(--cyan); }
.pulse i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.board-canvas { position: relative; aspect-ratio: 1.28; min-height: 420px; overflow: hidden; }
.board-canvas::before { content: ""; position: absolute; inset: 0; opacity: .22; background-image: linear-gradient(#3b536a 1px, transparent 1px), linear-gradient(90deg, #3b536a 1px, transparent 1px); background-size: 28px 28px; }
.connectors { position: absolute; inset: 0; width: 100%; height: 100%; }
.connectors path { fill: none; stroke: #607990; stroke-width: 2; }
.connectors .active-line { stroke: var(--cyan); stroke-dasharray: 5 8; animation: flow 8s linear infinite; }
.node { position: absolute; z-index: 2; width: 150px; padding: .72rem .85rem; border: 1px solid #486078; background: #102b44; box-shadow: 5px 5px 0 #071b31; }
.node span, .node strong { display: block; }
.node span { color: #83a0b8; font-size: .68rem; }
.node strong { margin-top: .15rem; color: white; font-family: var(--display); font-size: .79rem; }
.node-product { top: 8%; left: 50%; transform: translateX(-50%); border-color: var(--cyan); }
.node-api { top: 40%; left: 4%; }
.node-realtime { top: 40%; right: 4%; border-color: var(--blue); }
.node-data { bottom: 13%; left: 9%; }
.node-ai { bottom: 13%; right: 9%; border-color: var(--orange); }
.board-note { position: absolute; z-index: 3; left: 50%; bottom: 1rem; width: 80%; margin: 0; color: #8ea6ba; transform: translateX(-50%); text-align: center; font-size: .72rem; }
@keyframes flow { to { stroke-dashoffset: -120; } }

.marquee { padding: 1.05rem 0; overflow: hidden; color: var(--ink); background: var(--cyan); }
.marquee-track { width: max-content; display: flex; align-items: center; animation: marquee 26s linear infinite; }
.marquee span { padding: 0 1.3rem; font-family: var(--display); font-weight: 700; }
.marquee i { width: 5px; height: 5px; border-radius: 50%; background: var(--ink); }
@keyframes marquee { to { transform: translateX(-50%); } }

.section { padding: clamp(5rem, 9vw, 8.5rem) max(1.25rem, calc((100vw - 1300px) / 2)); }
.section-heading { display: grid; grid-template-columns: .35fr 1fr 1fr; align-items: start; gap: 2rem; margin-bottom: 3.5rem; }
.section-heading > p:first-child, .section-label { margin: .25rem 0 0; color: var(--blue); font-weight: 700; }
.section-heading h2, .about h2, .contact h2 { font-size: clamp(2.2rem, 4.5vw, 4.6rem); }
.section-heading > p:last-child { max-width: 440px; margin: .25rem 0 0; color: var(--muted); font-size: 1.08rem; }
.featured-project { display: grid; grid-template-columns: 1.04fr .96fr; min-height: 580px; color: white; background: var(--blue); }
.project-copy { padding: clamp(2rem, 5vw, 4.6rem); }
.project-type { font-weight: 700; color: #dce7ff; }
.project-copy h3 { max-width: 720px; margin-top: 1.4rem; font-size: clamp(2rem, 4vw, 4rem); }
.project-copy > p { max-width: 650px; margin: 1.5rem 0; color: #e1e9ff; font-size: 1.08rem; }
.project-outcomes { margin: 1.8rem 0; padding: 0; list-style: none; }
.project-outcomes li { position: relative; margin: .65rem 0; padding-left: 1.3rem; }
.project-outcomes li::before { content: ""; position: absolute; left: 0; top: .67rem; width: 6px; height: 6px; background: var(--cyan); border-radius: 50%; }
.tag-row { display: flex; flex-wrap: wrap; gap: .45rem; margin-top: 1.5rem; }
.tag-row span { padding: .3rem .55rem; border: 1px solid currentColor; border-radius: 3px; font-size: .72rem; font-weight: 700; }
.portfolio-visual { position: relative; margin: 2.25rem 2.25rem 2.25rem 0; padding: 1.5rem; color: var(--ink); background: var(--white); box-shadow: 14px 14px 0 rgba(7,27,49,.28); }
.visual-top, .visual-footer { display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: .75rem; }
.visual-top span:first-child { color: var(--ink); font-weight: 700; }
.allocation-ring { position: relative; display: grid; place-items: center; width: 200px; height: 200px; margin: 2.5rem auto; border-radius: 50%; background: conic-gradient(var(--blue) 0 68%, #e2eaf2 68%); }
.allocation-ring::before { content: ""; position: absolute; inset: 26px; border-radius: 50%; background: white; }
.allocation-ring div { z-index: 1; text-align: center; }
.allocation-ring strong, .allocation-ring span { display: block; }
.allocation-ring strong { font: 700 2.4rem var(--display); }
.allocation-ring span { color: var(--muted); font-size: .78rem; }
.order-list { border-top: 1px solid var(--line); }
.order-list > div { display: grid; grid-template-columns: 12px 1fr auto; gap: .7rem; align-items: center; padding: .75rem 0; border-bottom: 1px solid var(--line); font-size: .82rem; }
.order-list i { width: 8px; height: 8px; border-radius: 50%; }
.order-list .buy { background: var(--blue); }.order-list .sell { background: var(--orange); }.order-list .sync { background: var(--cyan); }
.order-list strong { font-size: .72rem; }
.visual-footer { margin-top: 1.2rem; }

.project-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.3rem; margin-top: 1.3rem; }
.project-card { min-height: 520px; padding: clamp(1.5rem, 4vw, 3rem); display: flex; flex-direction: column; border: 1px solid var(--line); background: white; }
.project-card-dark { color: white; background: var(--ink); border-color: var(--ink); }
.card-top { display: flex; justify-content: space-between; color: var(--muted); font-size: .75rem; font-weight: 700; }
.project-card-dark .card-top { color: #91a9bc; }
.project-card h3 { margin-top: auto; font-size: clamp(1.8rem, 3vw, 3rem); }
.project-card p { max-width: 650px; color: var(--muted); }
.project-card-dark p { color: #b6c7d4; }
.project-card a { align-self: flex-start; margin-top: 1.8rem; padding-bottom: .2rem; border-bottom: 1px solid currentColor; font-weight: 700; }
.rag-orbit { position: relative; width: 180px; height: 180px; margin: 2rem auto; border: 1px solid #34516c; border-radius: 50%; }
.rag-orbit::before, .rag-orbit::after { content: ""; position: absolute; inset: 28px; border: 1px solid #34516c; border-radius: 50%; }
.rag-orbit::after { inset: 58px; background: var(--blue); border: 0; }
.rag-orbit b { position: absolute; z-index: 2; inset: 0; display: grid; place-items: center; font: 700 1rem var(--display); }
.rag-orbit i { position: absolute; z-index: 3; width: 10px; height: 10px; border-radius: 50%; background: var(--cyan); }
.rag-orbit i:nth-child(1) { top: 18px; left: 40px; }.rag-orbit i:nth-child(2) { top: 96px; right: -4px; background: var(--orange); }.rag-orbit i:nth-child(3) { bottom: 4px; left: 70px; }
.metric-visual { margin: 3.8rem 0; }
.metric-visual strong, .metric-visual span { display: block; }
.metric-visual strong { color: var(--blue); font: 700 clamp(5rem, 11vw, 10rem)/.8 var(--display); letter-spacing: -.08em; }
.metric-visual span { max-width: 170px; margin-top: 1.2rem; color: var(--muted); font-size: .8rem; }
.project-card-wide { grid-column: 1 / -1; min-height: 400px; display: grid; grid-template-columns: 1fr .8fr; gap: 3rem; overflow: hidden; }
.project-card-wide > div:first-child { display: flex; flex-direction: column; }
.grid-visual { align-self: stretch; min-height: 320px; background-color: #e9f0f7; background-image: linear-gradient(90deg, transparent 24px, #c5d5e4 25px), linear-gradient(transparent 24px, #c5d5e4 25px); background-size: 25px 25px; clip-path: polygon(10% 0, 100% 0, 100% 90%, 0 100%, 0 15%); position: relative; }
.grid-visual::after { content: ""; position: absolute; width: 68%; height: 12px; left: 13%; top: 58%; background: var(--blue); box-shadow: 25px -25px 0 var(--blue), 50px -50px 0 var(--blue), 75px -75px 0 var(--orange); }

.experience { color: white; background: var(--ink); }
.section-heading-light > p:first-child { color: var(--cyan); }
.section-heading-light > p:last-child { color: #9cb2c5; }
.timeline { border-top: 1px solid #3e566d; }
.timeline article { display: grid; grid-template-columns: .7fr 1fr 1.25fr; gap: 2rem; padding: 2.5rem 0; border-bottom: 1px solid #3e566d; }
.timeline-meta span { display: block; color: #96acbe; font-size: .85rem; }
.timeline h3 { font-size: clamp(1.4rem, 2.5vw, 2.2rem); }
.company { margin: .35rem 0 0; color: var(--cyan); font-weight: 700; }
.timeline article > p { margin: 0; color: #b9c8d4; }

.about { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(3rem, 8vw, 8rem); }
.about-main > p:not(.section-label) { max-width: 690px; color: var(--muted); font-size: 1.12rem; }
.about h2 { max-width: 750px; margin: 1rem 0 2rem; }
.about-links { display: flex; flex-wrap: wrap; gap: 1.5rem; margin-top: 2.5rem; }
.about-links a { padding-bottom: .2rem; border-bottom: 1px solid var(--ink); font-weight: 700; }
.toolbox { padding: 2rem; border: 1px solid var(--line); background: white; }
.toolbox h3 { margin-bottom: 1.5rem; font-size: 1.6rem; }
.toolbox div { padding: 1.1rem 0; border-top: 1px solid var(--line); }
.toolbox span { color: var(--blue); font-size: .78rem; font-weight: 700; }
.toolbox p { margin: .3rem 0 0; }

.contact { color: white; text-align: center; background: var(--blue); }
.contact > p { margin: 0 0 1rem; font-weight: 700; }
.contact h2 { font-size: clamp(3.2rem, 9vw, 8.5rem); }
.button-light { margin-top: 2.5rem; color: var(--ink); background: white; }
.button-light:hover { background: var(--cyan); }
.contact-meta { display: flex; justify-content: space-between; margin-top: 5rem; padding-top: 1.3rem; border-top: 1px solid rgba(255,255,255,.35); font-size: .85rem; }
footer { max-width: 1440px; margin: auto; padding: 2rem clamp(1.25rem, 4vw, 4.5rem); display: flex; justify-content: space-between; color: var(--muted); font-size: .82rem; }
footer a { color: var(--ink); font-weight: 700; }

@media (max-width: 1040px) {
  .site-header nav, .header-cta { display: none; }
  .menu-button { width: 42px; height: 42px; padding: 0; display: grid; place-content: center; gap: 6px; border: 1px solid #526980; border-radius: 4px; background: transparent; }
  .menu-button span:not(.sr-only) { width: 20px; height: 2px; background: white; }
  .mobile-menu { position: absolute; top: 76px; right: 1.25rem; width: min(300px, calc(100vw - 2.5rem)); padding: 1rem; flex-direction: column; gap: .2rem; color: var(--ink); background: white; box-shadow: 0 18px 45px rgba(0,0,0,.2); }
  .mobile-menu:not([hidden]) { display: flex; }
  .mobile-menu a { padding: .75rem; font-weight: 700; }
  .hero { grid-template-columns: 1fr; padding-top: 9rem; }
  .system-board { justify-self: start; width: min(100%, 650px); transform: none; }
  .section-heading { grid-template-columns: 1fr 2fr; }
  .section-heading > p:last-child { grid-column: 2; }
  .featured-project { grid-template-columns: 1fr; }
  .portfolio-visual { min-height: 520px; margin: 0 2.25rem 2.25rem; }
  .about { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  h1 { font-size: clamp(3rem, 15vw, 5rem); }
  .hero { min-height: auto; padding-bottom: 4rem; }
  .quick-facts { grid-template-columns: 1fr; }
  .system-board { box-shadow: 10px 10px 0 rgba(32,107,255,.16); }
  .board-canvas { min-height: 390px; }
  .node { width: 132px; }
  .node-api { left: 2%; }.node-realtime { right: 2%; }.node-data { left: 4%; }.node-ai { right: 4%; }
  .section-heading { grid-template-columns: 1fr; gap: 1rem; }
  .section-heading > p:last-child { grid-column: auto; }
  .featured-project { min-height: auto; }
  .portfolio-visual { min-height: auto; margin: 0 1rem 1rem; }
  .project-grid { grid-template-columns: 1fr; }
  .project-card-wide { grid-column: auto; grid-template-columns: 1fr; }
  .project-card { min-height: 480px; }
  .timeline article { grid-template-columns: 1fr; gap: 1rem; }
  .timeline article > p { margin-top: .5rem; }
  .contact-meta, footer { flex-direction: column; align-items: center; gap: .7rem; }
}

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