:root {
  --bg: #03101d;
  --bg-deep: #020a12;
  --surface: #071827;
  --surface-2: #0a2033;
  --surface-3: #0d2940;
  --text: #f5f8fb;
  --muted: #a8b7c9;
  --muted-2: #7f93a8;
  --cyan: #00d7e9;
  --cyan-soft: #69edf7;
  --blue: #0a66c2;
  --line: rgba(89, 178, 255, 0.18);
  --line-strong: rgba(0, 215, 233, 0.32);
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
  --radius: 18px;
  --container: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scrollbar-gutter: stable; }
body {
  margin: 0;
  min-width: 0;
  background:
    radial-gradient(circle at 88% 5%, rgba(10,102,194,.14), transparent 26rem),
    linear-gradient(180deg, var(--bg) 0%, #041321 45%, var(--bg-deep) 100%);
  color: var(--text);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; }
a { color: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
svg { display: block; }

.skip-link {
  position: fixed;
  top: .75rem;
  left: .75rem;
  z-index: 9999;
  padding: .65rem .9rem;
  border-radius: 10px;
  background: #fff;
  color: #071827;
  transform: translateY(-180%);
  transition: transform .2s ease;
}
.skip-link:focus { transform: translateY(0); }

.container {
  width: min(calc(100% - 2.5rem), var(--container));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid rgba(112,179,255,.13);
  background: rgba(2, 11, 20, .84);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.nav-shell {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  text-decoration: none;
  white-space: nowrap;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-text strong { font-size: .94rem; letter-spacing: .08em; text-transform: uppercase; }
.brand-text .brand-sub { margin-top: .27rem; color: var(--muted-2); font-size: .69rem; letter-spacing: .035em; }
.brand-person { color: #b9c9d8; font-weight: 650; }
.brand-role { color: var(--muted-2); }

.nav-links {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: .3rem;
  flex-wrap: nowrap;
}
.nav-links a {
  position: relative;
  padding: .7rem .78rem .78rem;
  border-radius: 10px;
  color: #c9d5e1;
  text-decoration: none;
  font-size: .9rem;
  font-weight: 600;
  text-align: center;
  white-space: nowrap;
  transition: color .2s ease;
}
.nav-links a:hover,
.nav-links a[aria-current] { color: #fff; }
.nav-links a::after {
  content: "";
  position: absolute;
  left: .8rem;
  right: .8rem;
  bottom: .3rem;
  height: 2px;
  border-radius: 999px;
  background: var(--cyan);
  box-shadow: 0 0 10px rgba(0,215,233,.5);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .2s ease;
}
.nav-links a:hover::after,
.nav-links a[aria-current]::after { transform: scaleX(1); }

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: rgba(255,255,255,.03);
  color: var(--text);
  cursor: pointer;
}
.nav-toggle span,
.nav-toggle::before,
.nav-toggle::after {
  content: "";
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  border-radius: 999px;
  background: currentColor;
  transition: transform .2s ease, opacity .2s ease;
}
.nav-toggle[aria-expanded="true"] span { opacity: 0; }
.nav-toggle[aria-expanded="true"]::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"]::after { transform: translateY(-7px) rotate(-45deg); }

.hero {
  position: relative;
  min-height: 620px;
  display: grid;
  align-items: center;
  isolation: isolate;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -3;
  background:
    radial-gradient(circle at 80% 18%, rgba(0, 215, 233, .12), transparent 18rem),
    radial-gradient(circle at 92% 38%, rgba(10,102,194,.18), transparent 26rem),
    linear-gradient(102deg, #02101d 0%, #041524 55%, #03111d 100%);
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, rgba(3,16,29,1) 0%, rgba(3,16,29,.98) 44%, rgba(3,16,29,.6) 70%, rgba(3,16,29,.18) 100%);
}
.hero-art {
  position: absolute;
  z-index: -2;
  right: clamp(-28px, -1.8vw, 2px);
  top: 50%;
  width: min(46vw, 840px);
  height: auto;
  max-height: 94%;
  transform: translateY(-50%);
  object-fit: contain;
  object-position: right center;
  opacity: .98;
  filter: saturate(1.08) contrast(1.08) brightness(1.03);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, rgba(0,0,0,.22) 8%, rgba(0,0,0,.8) 20%, #000 34%, #000 100%);
  mask-image: linear-gradient(to right, transparent 0%, rgba(0,0,0,.22) 8%, rgba(0,0,0,.8) 20%, #000 34%, #000 100%);
  pointer-events: none;
}
.hero-content { max-width: 760px; padding-block: 6.3rem 5.6rem; }
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  margin: 0 0 1.1rem;
  color: var(--cyan-soft);
  font-size: .77rem;
  font-weight: 750;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.eyebrow::before {
  content: "";
  width: 28px;
  height: 1px;
  background: var(--cyan);
  box-shadow: 0 0 10px rgba(0,215,233,.65);
}
h1, h2, h3 { margin-top: 0; line-height: 1.13; letter-spacing: -.025em; }
h1 {
  max-width: 720px;
  margin-bottom: .9rem;
  font-size: clamp(2.55rem, 4.1vw, 3.65rem);
  font-weight: 560;
}
.hero-subtitle {
  margin: 0;
  color: var(--cyan);
  font-size: clamp(1.05rem, 1.7vw, 1.28rem);
  font-weight: 560;
  letter-spacing: -.01em;
}
.hero-copy {
  max-width: 700px;
  margin: 1.65rem 0 0;
  color: #c1cfdb;
  font-size: clamp(1rem, 1.2vw, 1.08rem);
}
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2rem; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: .76rem 1.08rem;
  border: 1px solid transparent;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 720;
  font-size: .92rem;
  transition: transform .18s ease, background .18s ease, border-color .18s ease;
}
.button:hover { transform: translateY(-1px); }
.button-primary { background: var(--cyan); color: #02121d; box-shadow: 0 12px 32px rgba(0,215,233,.12); }
.button-primary:hover { background: #57eaf3; }
.button-secondary { border-color: var(--line-strong); background: rgba(255,255,255,.025); color: #eaf4fb; }
.button-secondary:hover { background: rgba(0,215,233,.07); border-color: rgba(0,215,233,.55); }

.hero-tags { display: flex; flex-wrap: wrap; gap: .55rem; margin-top: 2.1rem; }
.hero-tags span,
.chip {
  padding: .38rem .65rem;
  border: 1px solid rgba(109,183,255,.17);
  border-radius: 999px;
  background: rgba(5,28,45,.7);
  color: #b8c9d8;
  font-size: .82rem;
  line-height: 1.2;
}

.section { padding-block: clamp(4.5rem, 8vw, 7.2rem); }
.section-tight { padding-block: clamp(3.8rem, 6vw, 5.6rem); }
.section-border { border-top: 1px solid var(--line); }
.section-alt { background: linear-gradient(180deg, rgba(10,32,51,.62), rgba(5,19,32,.34)); }
.section-head { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 3rem; align-items: end; margin-bottom: 2.7rem; }
.section-head h2 { margin-bottom: 0; font-size: clamp(1.85rem, 3vw, 2.4rem); font-weight: 580; }
.section-head-simple { grid-template-columns: 1fr; margin-bottom: 1.6rem; }
.section-head p { margin: 0; color: var(--muted); max-width: 650px; justify-self: end; }
.kicker { margin-bottom: .7rem; color: var(--cyan); font-size: .76rem; font-weight: 760; letter-spacing: .14em; text-transform: uppercase; }

.grid { display: grid; gap: 1rem; }
.services-grid { grid-template-columns: repeat(3, 1fr); }
.card {
  position: relative;
  padding: 1.45rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(145deg, rgba(12,39,61,.84), rgba(5,21,35,.82));
  box-shadow: inset 0 1px rgba(255,255,255,.018);
}
.card::before {
  content: "";
  position: absolute;
  inset: 0 auto auto 1.45rem;
  width: 34px;
  height: 2px;
  background: linear-gradient(90deg, var(--cyan), transparent);
  box-shadow: 0 0 10px rgba(0,215,233,.35);
}
.card h3 { margin: .8rem 0 .65rem; font-size: 1.1rem; font-weight: 680; }
.card p { margin: 0; color: var(--muted); font-size: .97rem; }
.card-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  margin-top: .3rem;
  color: var(--cyan-soft);
  border: 1px solid rgba(0,215,233,.18);
  border-radius: 12px;
  background: rgba(0,215,233,.045);
}
.card-icon svg { width: 22px; height: 22px; }

.projects-grid { grid-template-columns: repeat(2, 1fr); }
.project-card {
  display: flex;
  flex-direction: column;
  min-height: 270px;
  padding: 1.5rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(5,24,39,.66);
  transition: border-color .2s ease, transform .2s ease, background .2s ease;
}
.project-card:hover { transform: translateY(-2px); border-color: rgba(0,215,233,.34); background: rgba(8,31,50,.78); }
.project-meta { display: flex; justify-content: space-between; gap: 1rem; color: var(--cyan-soft); font-size: .75rem; font-weight: 720; letter-spacing: .07em; text-transform: uppercase; }
.project-card h3 { margin: .85rem 0 .75rem; font-size: 1.28rem; font-weight: 650; }
.project-card p { margin: 0 0 1.15rem; color: var(--muted); }
.project-tags { display: flex; flex-wrap: wrap; gap: .45rem; margin-top: auto; }
.project-tags span { color: #b8c8d8; font-size: .81rem; }

.profile-strip {
  display: grid;
  grid-template-columns: 1.18fr .82fr;
  gap: 1rem;
}
.profile-panel,
.fact-panel {
  padding: clamp(1.5rem, 3vw, 2.2rem);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(5,24,39,.7);
}
.profile-panel h2 { font-size: clamp(1.8rem, 3vw, 2.35rem); font-weight: 590; }
.profile-panel p { color: var(--muted); }
.fact-list { display: grid; gap: 1rem; margin: 0; }
.fact-row { padding-bottom: 1rem; border-bottom: 1px solid var(--line); }
.fact-row:last-child { padding-bottom: 0; border-bottom: 0; }
.fact-row dt { color: var(--muted-2); font-size: .73rem; letter-spacing: .11em; text-transform: uppercase; }
.fact-row dd { margin: .28rem 0 0; color: #e7f0f7; font-weight: 570; }

.tech-groups { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.tech-group { padding: 1.25rem; border-top: 1px solid var(--line-strong); background: rgba(255,255,255,.018); }
.tech-group h3 { margin-bottom: .85rem; color: #eaf3f9; font-size: .95rem; }
.tech-list { display: flex; flex-wrap: wrap; gap: .45rem; }

.cta-panel {
  position: relative;
  overflow: hidden;
  padding: clamp(2rem, 5vw, 4rem);
  border: 1px solid var(--line-strong);
  border-radius: 24px;
  background: linear-gradient(115deg, rgba(9,36,57,.95), rgba(3,18,30,.94));
  box-shadow: var(--shadow);
}
.cta-panel::after {
  content: "";
  position: absolute;
  width: 420px;
  aspect-ratio: 1;
  right: -170px;
  top: -190px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0,215,233,.16), transparent 67%);
  pointer-events: none;
}
.cta-panel h2 { max-width: 760px; margin-bottom: .8rem; font-size: clamp(1.85rem, 3vw, 2.45rem); font-weight: 580; }
.cta-panel p { max-width: 730px; color: var(--muted); }

.page-hero { padding: clamp(5.8rem, 10vw, 8rem) 0 3.5rem; border-bottom: 1px solid var(--line); background: radial-gradient(circle at 80% 20%, rgba(10,102,194,.14), transparent 28rem); }
.page-hero h1 { font-size: clamp(2.35rem, 4vw, 3.25rem); font-weight: 560; }
.page-hero p { max-width: 860px; color: var(--muted); font-size: 1.02rem; }

.content-grid { display: grid; grid-template-columns: .72fr 1.28fr; gap: 1rem; align-items: start; }
.side-nav { position: sticky; top: 96px; padding: 1.2rem; border: 1px solid var(--line); border-radius: var(--radius); background: rgba(5,24,39,.68); }
.side-nav a { display: block; padding: .62rem .72rem; border-radius: 9px; color: var(--muted); text-decoration: none; font-size: .94rem; }
.side-nav a:hover { color: #fff; background: rgba(255,255,255,.04); }
.prose-panel { padding: clamp(1.4rem, 3vw, 2.2rem); border: 1px solid var(--line); border-radius: var(--radius); background: rgba(5,24,39,.68); }
.prose-panel + .prose-panel { margin-top: 1rem; }
.prose-panel h2 { font-size: 1.55rem; font-weight: 640; }
.prose-panel h3 { font-size: 1.08rem; font-weight: 690; }
.prose-panel p, .prose-panel li { color: var(--muted); }
.clean-list { margin: .6rem 0 0; padding-left: 1.1rem; }
.clean-list li + li { margin-top: .45rem; }

.contact-grid { display: grid; grid-template-columns: .95fr 1.05fr; gap: 1rem; }
.contact-single { max-width: 760px; }
.contact-card { padding: 1.5rem; border: 1px solid var(--line); border-radius: var(--radius); background: rgba(5,24,39,.72); }
.contact-card p { color: var(--muted); }
.contact-item { display: grid; gap: .2rem; padding: 1rem 0; border-bottom: 1px solid var(--line); }
.contact-item:last-child { border-bottom: 0; }
.contact-item span { color: var(--muted-2); font-size: .73rem; letter-spacing: .09em; text-transform: uppercase; }
.contact-item a, .contact-item strong { color: #eef6fb; text-decoration: none; font-weight: 590; word-break: break-word; }
.contact-item a:hover { color: var(--cyan-soft); }

.legal h2 { margin-top: 2rem; font-size: 1.25rem; }
.legal p, .legal li { color: var(--muted); }
.legal a { color: var(--cyan-soft); }

.site-footer { border-top: 1px solid var(--line); background: rgba(1,8,15,.7); }
.footer-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 2rem; padding-block: 2.5rem; }
.footer-brand p { max-width: 580px; margin: .7rem 0 0; color: var(--muted-2); font-size: .88rem; }
.footer-links { display: flex; justify-content: flex-end; align-items: start; flex-wrap: wrap; gap: .45rem 1.1rem; }
.footer-links a { color: var(--muted); text-decoration: none; font-size: .88rem; }
.footer-links a:hover { color: #fff; }
.footer-bottom { padding: 1rem 0 1.5rem; border-top: 1px solid rgba(112,179,255,.09); color: #6f8498; font-size: .78rem; }

.not-found { min-height: 70vh; display: grid; place-items: center; text-align: center; }
.not-found h1 { font-size: clamp(4rem, 12vw, 8rem); margin-bottom: .3rem; color: var(--cyan); }
.not-found p { color: var(--muted); }

@media (max-width: 980px) {
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .tech-groups { grid-template-columns: repeat(2, 1fr); }
  .hero { min-height: 590px; }
  .hero-art { width: min(50vw, 710px); right: -2vw; opacity: .9; }
  .hero::after { background: linear-gradient(90deg, rgba(3,16,29,1) 0%, rgba(3,16,29,.98) 58%, rgba(3,16,29,.68) 82%, rgba(3,16,29,.4) 100%); }
  .section-head { grid-template-columns: 1fr; gap: 1rem; align-items: start; }
  .section-head p { justify-self: start; }
  .profile-strip, .contact-grid, .content-grid { grid-template-columns: 1fr; }
  .side-nav { position: static; }
}

@media (max-width: 820px) {
  .container { width: min(calc(100% - 1.5rem), var(--container)); }
  .nav-shell { min-height: 64px; }
  .brand-role { display: none; }
  .nav-toggle { display: block; }
  .nav-links {
    position: absolute;
    top: calc(100% + 1px);
    left: .75rem;
    right: .75rem;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: .65rem;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: rgba(3,16,29,.98);
    box-shadow: 0 18px 55px rgba(0,0,0,.32);
  }
  .nav-links[data-open="true"] { display: flex; }
  .nav-links a { padding: .76rem .85rem; text-align: left; }
  .nav-links a::after { display: none; }
  .nav-links a[aria-current] { color: var(--cyan-soft); background: rgba(0,215,233,.07); }
  .hero { min-height: auto; }
  .hero-content { padding-block: 5.4rem 4.8rem; }
  .hero-art { width: min(62vw, 620px); right: -4vw; top: 50%; opacity: .42; }
  .hero::after { background: linear-gradient(90deg, rgba(3,16,29,.985) 0%, rgba(3,16,29,.95) 68%, rgba(3,16,29,.62) 100%); }
  .projects-grid { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  body { font-size: 16px; }
  .brand-text strong { font-size: .82rem; }
  .hero-content { padding-block: 4.6rem 4.2rem; }
  h1 { font-size: clamp(2.25rem, 10vw, 3rem); }
  .hero-subtitle { max-width: 360px; font-size: 1.02rem; line-height: 1.55; }
  .hero-copy { font-size: .98rem; max-width: 400px; }
  .hero-actions { align-items: stretch; }
  .button { width: 100%; }
  .hero-tags { gap: .42rem; }
  .hero-art { width: 82vw; right: -22vw; top: 50%; opacity: .18; }
  .services-grid, .tech-groups { grid-template-columns: 1fr; }
  .section { padding-block: 4.1rem; }
  .section-tight { padding-block: 3.5rem; }
  .project-card { min-height: auto; }
  .project-meta { flex-direction: column; gap: .25rem; }
  .footer-grid { grid-template-columns: 1fr; gap: 1.3rem; }
  .footer-links { justify-content: flex-start; }
  .page-hero { padding-top: 4.5rem; }
}

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