:root {
  color-scheme: dark;
  --navy: #07111F;
  --navy-2: #030712;
  --gold: #2F6BFF;
  --gold-soft: #6EE7FF;
  --ink: #F8FAFC;
  --muted: #94A3B8;
  --bg: #02050B;
  --surface: #07111F;
  --surface-2: #0B1730;
  --line: rgba(96, 165, 250, 0.22);
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
}

[data-theme="light"] {
  color-scheme: light;
  --ink: #07111F;
  --muted: #475569;
  --bg: #EAF1FB;
  --surface: #FFFFFF;
  --surface-2: #DDE8F7;
  --line: rgba(37, 99, 235, 0.16);
  --shadow: 0 22px 60px rgba(15, 23, 42, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  margin: 0;
  font-family: "Inter", Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  overflow-x: hidden;
}

@media (pointer: fine) {
  body,
  a,
  button,
  input,
  textarea,
  .project-card,
  .stack-card,
  .media-zoom-trigger,
  .image-lightbox button {
    cursor: none;
  }

  .cursor-dot,
  .cursor-ring {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 9999;
    pointer-events: none;
    opacity: 0;
    transform: translate3d(-50%, -50%, 0);
    transition: opacity 160ms ease, width 160ms ease, height 160ms ease, border-color 160ms ease, background 160ms ease;
  }

  .cursor-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--gold);
    box-shadow: 0 0 18px rgba(47, 107, 255, 0.62);
  }

  .cursor-ring {
    width: 34px;
    height: 34px;
    border: 1px solid rgba(110, 231, 255, 0.78);
    border-radius: 50%;
    background: rgba(47, 107, 255, 0.08);
  }

  body.cursor-ready .cursor-dot,
  body.cursor-ready .cursor-ring {
    opacity: 1;
  }

  body.cursor-hover .cursor-ring {
    width: 64px;
    height: 64px;
    border-color: rgba(110, 231, 255, 0.95);
    background: rgba(47, 107, 255, 0.14);
  }

  body.cursor-hover .cursor-dot {
    width: 6px;
    height: 6px;
  }

  body.cursor-press .cursor-ring {
    width: 46px;
    height: 46px;
    background: rgba(47, 107, 255, 0.22);
  }
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(circle at 18% 12%, rgba(47, 107, 255, 0.18), transparent 28%),
    radial-gradient(circle at 78% 18%, rgba(34, 211, 238, 0.12), transparent 26%),
    linear-gradient(225deg, rgba(7, 17, 31, 0.82), transparent 46%);
  pointer-events: none;
}

.ambient-3d {
  position: fixed;
  inset: 0;
  z-index: 2;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.26;
  mix-blend-mode: screen;
}

[data-theme="light"] .ambient-3d {
  opacity: 0.14;
  mix-blend-mode: multiply;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

button,
input,
textarea {
  font: inherit;
}

.shell {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(18px);
}

.nav {
  min-height: 76px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
}

.brand-mark {
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--navy);
  object-fit: cover;
}

.nav-links {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 22px;
  color: var(--muted);
  font-size: 0.94rem;
}

.nav-links a:hover {
  color: var(--gold);
}

.theme-toggle,
.menu-toggle {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  border-radius: 8px;
  cursor: pointer;
}

.theme-toggle {
  width: 46px;
  height: 42px;
  position: relative;
}

.sun,
.moon {
  position: absolute;
  inset: 12px;
  transition: opacity 160ms ease, transform 160ms ease;
}

.sun {
  border: 2px solid var(--gold);
  border-radius: 50%;
}

.moon {
  border-radius: 50%;
  box-shadow: -6px 0 0 var(--gold);
  opacity: 0;
  transform: translateX(4px);
}

[data-theme="light"] .sun {
  opacity: 0;
  transform: translateX(-4px);
}

[data-theme="light"] .moon {
  opacity: 1;
  transform: translateX(0);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 40px;
  margin-left: auto;
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 5px auto;
  background: currentColor;
}

.section {
  padding: 92px 0;
}

.section-band {
  padding: 116px 0 88px;
}

.hero {
  min-height: calc(100vh - 76px);
  display: grid;
  align-items: center;
  background: #02050B;
  border-bottom: 1px solid rgba(96, 165, 250, 0.24);
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(circle at var(--grid-x, 50%) var(--grid-y, 42%), rgba(47, 107, 255, 0.34), transparent 20%),
    radial-gradient(circle at 50% 18%, rgba(110, 231, 255, 0.12), transparent 30%),
    linear-gradient(180deg, rgba(2, 5, 11, 0.36), #02050B 88%);
  pointer-events: none;
  transition: background 160ms ease;
}

.infinite-grid-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 52%, rgba(47, 107, 255, 0.18), transparent 24%),
    radial-gradient(circle at 50% 100%, rgba(34, 211, 238, 0.16), transparent 26%),
    #02050B;
}

.infinite-grid-bg::before,
.infinite-grid-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.infinite-grid-bg::before {
  background-image:
    linear-gradient(rgba(96, 165, 250, 0.2) 1px, transparent 1px),
    linear-gradient(90deg, rgba(96, 165, 250, 0.2) 1px, transparent 1px),
    radial-gradient(circle, rgba(110, 231, 255, 0.32) 1px, transparent 1px);
  background-size: 72px 72px, 72px 72px, 36px 36px;
  opacity: 0.5;
  mask-image: radial-gradient(circle at var(--grid-x, 50%) var(--grid-y, 42%), #000 0 18%, rgba(0, 0, 0, 0.55) 42%, transparent 78%);
  animation: infinite-grid-pan 12s linear infinite;
}

.infinite-grid-bg::after {
  background:
    linear-gradient(180deg, rgba(2, 5, 11, 0.12), rgba(2, 5, 11, 0.72) 58%, #02050B 100%),
    radial-gradient(circle at var(--grid-x, 50%) var(--grid-y, 50%), rgba(110, 231, 255, 0.18), transparent 18%);
  mix-blend-mode: screen;
}

.grid-plane {
  position: absolute;
  left: 50%;
  bottom: -12%;
  width: 150vw;
  height: 86vh;
  transform-origin: 50% 100%;
  transform: translateX(-50%) perspective(760px) rotateX(66deg);
  background-image:
    linear-gradient(rgba(110, 231, 255, 0.4) 1px, transparent 1px),
    linear-gradient(90deg, rgba(110, 231, 255, 0.4) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(0deg, #000 0%, rgba(0, 0, 0, 0.92) 38%, transparent 88%);
}

.grid-plane-back {
  opacity: 0.36;
  filter: blur(0.4px);
  animation: grid-forward 10s linear infinite;
}

.grid-plane-front {
  background-size: 112px 112px;
  opacity: 0.58;
  filter: drop-shadow(0 0 18px rgba(47, 107, 255, 0.42));
  animation: grid-forward 5.5s linear infinite;
}

.grid-verticals {
  position: absolute;
  inset: 0;
  opacity: 0.3;
  background:
    repeating-linear-gradient(90deg, transparent 0 88px, rgba(96, 165, 250, 0.28) 89px, transparent 91px),
    linear-gradient(180deg, transparent 0 34%, rgba(34, 211, 238, 0.12) 45%, transparent 72%);
  mask-image: radial-gradient(ellipse at 50% 54%, #000 0 36%, transparent 72%);
  animation: vertical-pulse 7s ease-in-out infinite;
}

.grid-glow {
  position: absolute;
  left: 50%;
  top: 49%;
  width: min(720px, 88vw);
  aspect-ratio: 1;
  border-radius: 50%;
  border: 1px solid rgba(110, 231, 255, 0.2);
  background:
    radial-gradient(circle, rgba(47, 107, 255, 0.26), rgba(34, 211, 238, 0.08) 42%, transparent 68%);
  transform: translate(-50%, -50%);
  filter: blur(0.2px);
  animation: grid-glow-breathe 7s ease-in-out infinite;
}

.grid-orbit {
  position: absolute;
  left: 50%;
  top: 52%;
  width: min(560px, 78vw);
  aspect-ratio: 1;
  border-radius: 50%;
  border: 1px dashed rgba(110, 231, 255, 0.18);
  transform: translate(-50%, -50%);
}

.grid-orbit-one {
  animation: orbit-spin 28s linear infinite;
}

.grid-orbit-two {
  width: min(380px, 58vw);
  border-color: rgba(47, 107, 255, 0.22);
  animation: orbit-spin 20s linear infinite reverse;
}

.grid-node {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold-soft);
  box-shadow: 0 0 22px rgba(110, 231, 255, 0.95), 0 0 42px rgba(47, 107, 255, 0.52);
  opacity: 0.9;
  animation: node-float 6s ease-in-out infinite;
}

.node-one {
  left: 18%;
  top: 36%;
}

.node-two {
  right: 22%;
  top: 28%;
  animation-delay: -1.8s;
}

.node-three {
  left: 33%;
  bottom: 23%;
  animation-delay: -3.1s;
}

.node-four {
  right: 31%;
  bottom: 18%;
  animation-delay: -4.2s;
}

.hero::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  width: min(1120px, calc(100% - 40px));
  height: 2px;
  z-index: 1;
  background: linear-gradient(90deg, transparent, rgba(110, 231, 255, 0.76), transparent);
  transform: translateX(-50%);
}

[data-theme="light"] .hero {
  background: #EAF1FB;
}

[data-theme="light"] .infinite-grid-bg {
  background:
    radial-gradient(circle at 50% 46%, rgba(37, 99, 235, 0.14), transparent 28%),
    radial-gradient(circle at 50% 100%, rgba(14, 165, 233, 0.12), transparent 30%),
    linear-gradient(180deg, #EAF1FB 0%, #DCE8F8 100%);
}

[data-theme="light"] .hero::before {
  background:
    radial-gradient(circle at var(--grid-x, 50%) var(--grid-y, 42%), rgba(37, 99, 235, 0.12), transparent 18%),
    linear-gradient(180deg, rgba(234, 241, 251, 0.34), #DCE8F8 92%);
}

[data-theme="light"] .grid-plane {
  background-image:
    linear-gradient(rgba(37, 99, 235, 0.32) 1px, transparent 1px),
    linear-gradient(90deg, rgba(37, 99, 235, 0.32) 1px, transparent 1px);
}

[data-theme="light"] .infinite-grid-bg::before {
  opacity: 0.36;
  background-image:
    linear-gradient(rgba(37, 99, 235, 0.18) 1px, transparent 1px),
    linear-gradient(90deg, rgba(37, 99, 235, 0.18) 1px, transparent 1px),
    radial-gradient(circle, rgba(37, 99, 235, 0.28) 1px, transparent 1px);
}

[data-theme="light"] .grid-glow {
  opacity: 0.48;
  background:
    radial-gradient(circle, rgba(37, 99, 235, 0.18), rgba(14, 165, 233, 0.08) 42%, transparent 68%);
}

[data-theme="light"] .grid-node {
  background: #2563EB;
  box-shadow: 0 0 18px rgba(37, 99, 235, 0.55), 0 0 34px rgba(14, 165, 233, 0.3);
}

.hero-center {
  display: grid;
  justify-items: center;
  text-align: center;
  max-width: 940px;
  transform: translateY(-10px);
  position: relative;
  z-index: 2;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  margin: 0 0 24px;
  border: 1px solid rgba(110, 231, 255, 0.42);
  border-radius: 999px;
  padding: 0 18px;
  color: var(--gold-soft);
  background: rgba(47, 107, 255, 0.1);
  box-shadow: inset 0 0 22px rgba(47, 107, 255, 0.12), 0 0 34px rgba(47, 107, 255, 0.12);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.eyebrow {
  margin: 0 0 16px;
  color: var(--gold);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.05;
}

h1 {
  max-width: 850px;
  font-size: clamp(2.8rem, 5.2vw, 4.25rem);
  letter-spacing: 0;
  color: #F8FAFC;
  text-shadow: 0 0 34px rgba(110, 231, 255, 0.14);
}

.hero-center h1 {
  width: 100%;
  max-width: 980px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

h1 span {
  display: block;
}

.mobile-line {
  display: none;
}

.hero-center h1 span {
  display: inline-block;
  width: auto;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
  white-space: nowrap;
}

.hero-center h1 .mobile-line {
  display: none;
}

h1 em {
  color: var(--gold-soft);
  font-style: normal;
  text-shadow: 0 0 28px rgba(110, 231, 255, 0.28);
}

h2 {
  font-size: clamp(2rem, 4vw, 3.55rem);
  letter-spacing: 0;
}

h3 {
  font-size: 1.16rem;
}

.hero-text,
.section-text,
.about-copy p,
.service-card p,
.project-card p,
.process-grid p {
  color: var(--muted);
}

.hero-text {
  max-width: 600px;
  margin: 24px 0 0;
  font-size: 1.13rem;
  color: rgba(226, 232, 240, 0.86);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin: 32px 0 52px;
}

.hero-center .btn {
  min-width: 126px;
}

.hero-center .btn.secondary {
  border-color: rgba(110, 231, 255, 0.52);
  color: var(--gold-soft);
  box-shadow: inset 0 0 18px rgba(47, 107, 255, 0.1);
}

[data-theme="light"] .hero-center .btn.secondary {
  color: var(--navy);
}

.btn {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 18px;
  font-weight: 800;
  cursor: pointer;
}

.btn.primary {
  background: linear-gradient(135deg, #6EE7FF, #2F6BFF);
  color: #02050B;
  border-color: var(--gold);
  box-shadow: 0 18px 42px rgba(47, 107, 255, 0.28);
}

.btn.secondary {
  background: transparent;
  color: var(--ink);
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 150px));
  gap: 28px;
  justify-content: center;
  width: 100%;
}

.hero-stats div {
  display: grid;
  gap: 6px;
}

.hero-stats strong {
  color: var(--gold-soft);
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  line-height: 1;
  text-shadow: 0 0 26px rgba(110, 231, 255, 0.26);
}

.hero-stats span {
  color: rgba(226, 232, 240, 0.76);
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}

[data-theme="light"] .hero-center h1 {
  color: #07111F;
  text-shadow: none;
}

[data-theme="light"] h1 em,
[data-theme="light"] .hero-stats strong {
  color: #2563EB;
  text-shadow: 0 0 18px rgba(37, 99, 235, 0.16);
}

[data-theme="light"] .hero-pill {
  color: #1D4ED8;
  background: rgba(37, 99, 235, 0.1);
  border-color: rgba(37, 99, 235, 0.32);
  box-shadow: none;
}

[data-theme="light"] .hero-text {
  color: rgba(15, 23, 42, 0.78);
}

[data-theme="light"] .hero-stats span {
  color: rgba(15, 23, 42, 0.7);
}

.hero-media {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  background: var(--surface);
}

.portrait-frame {
  position: relative;
  min-height: 560px;
  display: grid;
  place-items: center;
  padding: 18px;
  isolation: isolate;
}

.portrait-backdrop {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(145deg, rgba(33, 48, 77, 0.96), rgba(9, 17, 32, 0.78)),
    url("assets/finance-ai-hero.png") center / cover;
}

.portrait-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(9, 17, 32, 0.06), rgba(9, 17, 32, 0.68));
}

.portrait-photo-shell {
  width: min(82%, 380px);
  justify-self: center;
  align-self: center;
  aspect-ratio: 4 / 5;
  display: grid;
  place-items: end center;
  overflow: hidden;
  border: 1px solid rgba(212, 175, 55, 0.42);
  border-radius: 18px;
  background: #FFFFFF;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.38);
}

.portrait-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 54% top;
  filter: saturate(0.98) contrast(1.03);
  transition: transform 420ms ease;
  transform-origin: center 38%;
}

.portrait-frame:hover .portrait-photo {
  transform: scale(1.045);
}

.portrait-badge {
  position: absolute;
  left: 28px;
  right: 28px;
  bottom: 28px;
  display: grid;
  gap: 2px;
  border: 1px solid rgba(212, 175, 55, 0.36);
  border-radius: 8px;
  padding: 14px 16px;
  background: rgba(9, 17, 32, 0.78);
  color: #F7F4EA;
  backdrop-filter: blur(14px);
}

.portrait-badge span {
  color: var(--gold-soft);
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
}

.portrait-badge strong {
  font-size: 1rem;
  line-height: 1.25;
}

.tech-stack {
  border-block: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 92%, var(--surface) 8%);
}

.section-heading.compact {
  margin-bottom: 24px;
}

.section-heading.compact h2 {
  max-width: 700px;
  font-size: clamp(1.75rem, 3vw, 2.65rem);
}

.stack-marquee {
  overflow: hidden;
  border-block: 1px solid var(--line);
  padding: 14px 0;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.stack-track {
  width: max-content;
  display: flex;
  gap: 14px;
  animation: stack-marquee 58s linear infinite;
}

.stack-marquee:hover .stack-track {
  animation-play-state: paused;
}

.stack-card {
  width: 156px;
  min-height: 116px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px 12px;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  text-align: center;
}

.stack-card img {
  width: 48px;
  height: 48px;
  object-fit: contain;
}

.stack-card strong {
  color: var(--ink);
  font-size: 0.88rem;
  line-height: 1.2;
}

@keyframes stack-marquee {
  from { transform: translateX(0); }
  to { transform: translateX(calc(-50% - 7px)); }
}

@keyframes grid-forward {
  from {
    background-position: 0 0, 0 0;
  }

  to {
    background-position: 0 112px, 112px 0;
  }
}

@keyframes infinite-grid-pan {
  from {
    background-position: 0 0, 0 0, 0 0;
  }

  to {
    background-position: 72px 72px, 72px 72px, 36px 36px;
  }
}

@keyframes star-drift {
  from {
    background-position: 0 0;
  }

  to {
    background-position: 68px 102px;
  }
}

@keyframes vertical-pulse {
  0%,
  100% {
    opacity: 0.18;
    transform: translateY(0);
  }

  50% {
    opacity: 0.38;
    transform: translateY(-10px);
  }
}

@keyframes grid-glow-breathe {
  0%,
  100% {
    opacity: 0.56;
    transform: translate(-50%, -50%) scale(0.96);
  }

  50% {
    opacity: 0.92;
    transform: translate(-50%, -50%) scale(1.06);
  }
}

@keyframes orbit-spin {
  from {
    transform: translate(-50%, -50%) rotate(0deg);
  }

  to {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

@keyframes node-float {
  0%,
  100% {
    transform: translate3d(0, 0, 0) scale(1);
    opacity: 0.62;
  }

  50% {
    transform: translate3d(0, -14px, 0) scale(1.22);
    opacity: 1;
  }
}

@keyframes workflow-preview-pan {
  0% {
    transform: translateX(0) scale(1.08);
  }

  45% {
    transform: translateX(-24%) scale(1.18);
  }

  100% {
    transform: translateX(-42%) scale(1.08);
  }
}

@keyframes workflow-preview-pan-wide {
  0% {
    transform: translateX(0) scale(1.08);
  }

  45% {
    transform: translateX(-30%) scale(1.16);
  }

  100% {
    transform: translateX(-55%) scale(1.08);
  }
}

@media (prefers-reduced-motion: reduce) {
  .grid-plane,
  .infinite-grid-bg::before,
  .grid-verticals,
  .grid-glow,
  .grid-orbit,
  .grid-node {
    animation: none;
  }
}

.section-heading {
  max-width: 780px;
  margin-bottom: 34px;
}

.card-grid {
  display: grid;
  gap: 18px;
}

.card-grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card-grid.four {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.service-card,
.project-card,
.process-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.service-card {
  min-height: 270px;
  padding: 26px;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
  transform-origin: center;
}

.service-card:hover,
.service-card:focus-within {
  transform: translateY(-4px) scale(1.02);
  border-color: color-mix(in srgb, var(--gold) 42%, var(--line));
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.16);
}

.icon-box {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  margin-bottom: 34px;
  border-radius: 8px;
  background: color-mix(in srgb, var(--gold) 16%, transparent);
  color: var(--gold);
  font-weight: 800;
}

.split-section {
  background: color-mix(in srgb, var(--bg) 92%, var(--surface) 8%);
  border-block: 1px solid var(--line);
}

.section-plain {
  position: relative;
}

.section-plain::before {
  content: "";
  position: absolute;
  inset: 0;
  left: 50%;
  width: 100vw;
  z-index: -1;
  background: color-mix(in srgb, var(--bg) 92%, var(--surface) 8%);
  transform: translateX(-50%);
}

#process::after,
#about::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 100vw;
  height: 1px;
  background: var(--line);
  transform: translateX(-50%);
  pointer-events: none;
}

.section-text {
  max-width: 600px;
  margin: 20px 0 0;
}

.featured-projects .section-heading {
  margin-bottom: 28px;
}

.project-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 26px;
}

.filter-pill {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 16px;
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
  font-size: 0.86rem;
  font-weight: 800;
}

.filter-pill.is-active {
  border-color: var(--navy);
  background: var(--navy);
  color: #FFFFFF;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.project-card {
  overflow: hidden;
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.14);
  transition: transform 180ms ease, opacity 180ms ease;
}

.project-card:hover {
  transform: translateY(-3px);
}

.project-card.is-hidden {
  display: none;
}

.project-media {
  height: 172px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: var(--navy);
}

.project-media img,
.project-media video {
  width: 100%;
  height: 100%;
  min-height: 172px;
  object-fit: cover;
  opacity: 0.74;
}

.media-zoom-trigger {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 172px;
  display: block;
  border: 0;
  padding: 0;
  background: #FFFFFF;
  overflow: hidden;
}

.media-zoom-trigger img {
  width: 100%;
  height: 100%;
  min-height: 172px;
  object-fit: cover;
  object-position: center;
  padding: 10px;
  background: #FFFFFF;
  opacity: 1;
  transition: transform 220ms ease;
}

.slideshow-track {
  width: 100%;
  height: 100%;
  display: flex;
  transform: translateX(0);
  transition: transform 720ms cubic-bezier(0.22, 1, 0.36, 1);
}

.slideshow-track > img,
.slideshow-track > video,
.slideshow-track > iframe,
.slideshow-track > .workflow-motion-preview {
  width: 100%;
  height: 100%;
  min-height: 172px;
  flex: 0 0 100%;
  object-fit: contain;
  padding: 8px;
  background: #FFFFFF;
  opacity: 1;
}

.workflow-motion-preview {
  position: relative;
  overflow: hidden;
  padding: 0;
  background: #F5F6F7;
}

.workflow-motion-preview img {
  position: absolute;
  top: 0;
  left: 0;
  width: auto;
  max-width: none;
  min-width: 100%;
  height: 100%;
  min-height: 0;
  padding: 0;
  object-fit: unset;
  object-position: center;
  background: transparent;
  animation: workflow-preview-pan 7.5s ease-in-out infinite alternate;
  transform-origin: center center;
}

.workflow-motion-preview-wide img {
  animation-name: workflow-preview-pan-wide;
}

.slideshow-track iframe {
  border: 0;
  padding: 0;
  background: #FFFFFF;
}

.project-media-slideshow .media-zoom-trigger:hover .slideshow-track img,
.project-media-slideshow .media-zoom-trigger:hover .slideshow-track video,
.project-media-slideshow .media-zoom-trigger:hover .slideshow-track iframe {
  transform: none;
}

.slideshow-dots {
  position: absolute;
  left: 12px;
  bottom: 14px;
  display: inline-flex;
  gap: 6px;
}

.slideshow-dots span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(9, 17, 32, 0.34);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.55);
}

.slideshow-dots span:first-child {
  background: var(--gold-soft);
}

.slideshow-dots span.is-active {
  background: var(--gold-soft);
}

.slideshow-dots span:not(.is-active) {
  background: rgba(9, 17, 32, 0.34);
}

.media-zoom-trigger:hover img {
  transform: scale(1.025);
}

.video-slot {
  position: relative;
}

.media-icon {
  position: absolute;
  min-width: 72px;
  min-height: 38px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: rgba(247, 244, 234, 0.12);
  color: var(--gold-soft);
  padding: 0 14px;
  font-size: 0.88rem;
  font-weight: 800;
  backdrop-filter: blur(8px);
}

.media-zoom-trigger .media-icon {
  right: 12px;
  bottom: 12px;
  background: rgba(9, 17, 32, 0.78);
  color: var(--gold-soft);
}

.image-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9998;
  display: none;
  background: rgba(5, 10, 20, 0.9);
  padding: 80px 24px 24px;
}

.image-lightbox.is-open {
  display: grid;
}

.lightbox-toolbar {
  position: fixed;
  top: 18px;
  left: 50%;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  transform: translateX(-50%);
}

.lightbox-toolbar button {
  min-height: 38px;
  border: 1px solid rgba(212, 175, 55, 0.44);
  border-radius: 8px;
  padding: 0 14px;
  background: var(--navy);
  color: var(--gold-soft);
  font-weight: 800;
}

.lightbox-toolbar .gallery-nav.is-hidden {
  display: none;
}

.lightbox-stage {
  width: 100%;
  height: 100%;
  overflow: auto;
  display: grid;
  place-items: start center;
}

.lightbox-stage img,
.lightbox-stage video,
.lightbox-stage iframe {
  max-width: none;
  width: min(1200px, 96vw);
  height: auto;
  transform-origin: top center;
}

.lightbox-stage video {
  background: #000000;
}

.lightbox-stage iframe {
  width: min(1500px, 96vw);
  height: min(760px, calc(100vh - 128px));
  border: 0;
  border-radius: 8px;
  background: #FFFFFF;
}

.lightbox-stage .is-hidden {
  display: none;
}

body.lightbox-open {
  overflow: hidden;
}

.project-body {
  padding: 20px 22px 22px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.tag-row span {
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 0 9px;
  background: color-mix(in srgb, var(--surface-2) 72%, transparent);
  color: var(--ink);
  font-size: 0.72rem;
  font-weight: 800;
}

.project-body h3 {
  margin-bottom: 10px;
}

.project-body p {
  margin: 0;
  font-size: 0.92rem;
}

.process-grid span {
  display: inline-block;
  margin-bottom: 10px;
  color: var(--gold);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.process-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.process-grid article {
  min-height: 236px;
  padding: 26px;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
  transform-origin: center;
}

.process-grid article:hover,
.process-grid article:focus-within {
  transform: translateY(-4px) scale(1.02);
  border-color: color-mix(in srgb, var(--gold) 42%, var(--line));
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.16);
}

.about-grid,
.contact-section {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 48px;
}

.about-panel {
  border-left: 3px solid var(--gold);
  padding-left: 24px;
}

.about-content {
  display: grid;
  gap: 24px;
}

.about-photo {
  width: min(100%, 520px);
  justify-self: end;
}

.about-copy p:first-child {
  margin-top: 0;
}

.contact-section {
  align-items: start;
}

.contact-details {
  display: grid;
  gap: 28px;
  margin-top: 34px;
}

.contact-method {
  display: grid;
  gap: 10px;
}

.contact-label {
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.contact-method a {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  color: var(--gold);
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.7;
  text-decoration: none;
}

.contact-method a:hover {
  color: var(--ink);
}

.contact-method a span[aria-hidden="true"] {
  display: inline-grid;
  width: 20px;
  height: 20px;
  place-items: center;
  color: var(--gold);
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1;
}

.contact-form,
.calendly-card {
  display: grid;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
  background: var(--surface);
}

.calendly-card {
  min-height: 720px;
  padding: 0;
  overflow: hidden;
}

.calendly-card iframe {
  width: 100%;
  min-height: 720px;
  border: 0;
  background: var(--surface);
}

.contact-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 13px 14px;
  background: var(--bg);
  color: var(--ink);
  resize: vertical;
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 26px 0;
  color: var(--muted);
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  gap: 18px;
}

.footer-grid p {
  margin: 0;
}

.footer-grid a {
  color: var(--gold);
  font-weight: 800;
}

@media (max-width: 860px) {
  .nav {
    position: relative;
    gap: 10px;
  }

  .brand {
    order: 1;
  }

  .menu-toggle {
    display: grid;
    place-items: center;
    order: 3;
    margin-left: 0;
  }

  .theme-toggle {
    display: block;
    margin-left: auto;
    flex: 0 0 auto;
    order: 2;
    margin-right: 8px;
  }

  .nav-links {
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin: 0;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 8px;
    background: var(--surface);
    box-shadow: var(--shadow);
    order: 4;
  }

  .nav-links.is-open {
    display: flex;
  }

  .nav-links a {
    padding: 12px;
  }

  .split-grid,
  .about-grid,
  .contact-section {
    grid-template-columns: 1fr;
  }

  .card-grid.three,
  .card-grid.four,
  .project-grid,
  .process-grid {
    grid-template-columns: 1fr;
  }

  .section,
  .section-band {
    padding: 68px 0;
  }

  .hero-stats {
    grid-template-columns: repeat(2, minmax(0, 150px));
  }

  .about-photo {
    justify-self: start;
  }
}

@media (min-width: 861px) and (max-width: 1180px) {
  h1 {
    font-size: clamp(2.8rem, 5vw, 4rem);
    max-width: 900px;
  }

  .portrait-frame {
    min-height: 560px;
  }

  .portrait-photo-shell {
    width: min(86%, 360px);
  }

  .project-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  html,
  body {
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden;
  }

  body,
  .site-header,
  main,
  .section,
  .section-band,
  .section-plain,
  .site-footer {
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden;
  }

  .section-plain::before,
  #process::after,
  #about::after {
    left: 0;
    width: 100%;
    transform: none;
  }

  .shell {
    width: min(100vw, 430px);
    max-width: 100vw;
    margin-left: auto;
    margin-right: auto;
    padding-left: 14px;
    padding-right: 14px;
  }

  .section-plain.shell {
    width: 100%;
    max-width: 100vw;
    margin-left: 0;
    margin-right: 0;
    padding-left: 14px;
    padding-right: 14px;
  }

  .section-plain > * {
    width: 100%;
    max-width: 430px;
    margin-left: auto;
    margin-right: auto;
  }

  .nav {
    display: flex;
    position: relative;
    min-height: 68px;
    gap: 8px;
  }

  .brand span:last-child {
    display: none;
  }

  .brand {
    grid-column: 1;
  }

  .menu-toggle {
    display: grid !important;
    place-items: center;
    position: relative;
    top: auto;
    right: auto;
    z-index: 1;
    flex: 0 0 auto;
    margin-left: 0;
    order: 3;
    transform: none;
    border-color: var(--gold);
    background: var(--navy);
    color: var(--gold);
  }

  .theme-toggle {
    display: block;
    width: 42px;
    height: 40px;
    margin-left: auto;
    flex: 0 0 auto;
    order: 2;
    border-color: var(--gold);
    background: var(--navy);
    color: var(--gold);
  }

  .nav-links {
    grid-column: 1 / -1;
  }

  h1 {
    font-size: clamp(1.55rem, 7vw, 1.9rem);
  }

  h2 {
    font-size: clamp(1.34rem, 6.4vw, 1.66rem);
    line-height: 1.08;
  }

  h3 {
    font-size: 1rem;
  }

  h1,
  h2,
  h3,
  p,
  a,
  span {
    max-width: 100%;
    overflow-wrap: anywhere;
  }

  .hero {
    min-height: auto;
  }

  .infinite-grid-bg {
    inset: 0;
  }

  .grid-plane {
    width: 220vw;
    height: 58vh;
    bottom: -12%;
    background-size: 42px 42px;
  }

  .grid-plane-front {
    background-size: 84px 84px;
  }

  .grid-verticals {
    opacity: 0.2;
  }

  .grid-orbit {
    width: 92vw;
  }

  .grid-node {
    width: 6px;
    height: 6px;
  }

  .hero-center {
    width: 100%;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
    justify-self: center;
    justify-items: center;
    transform: none;
  }

  .section-heading,
  .section-text {
    width: 100%;
    max-width: 100%;
    text-align: center;
    margin-left: auto;
    margin-right: auto;
  }

  .project-filters {
    justify-content: center;
  }

  .card-grid,
  .project-grid,
  .process-grid {
    justify-items: center;
  }

  .service-card,
  .project-card,
  .process-grid article,
  .about-content,
  .contact-section > div,
  .contact-form,
  .calendly-card {
    width: 100%;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
  }

  .calendly-card,
  .calendly-card iframe {
    min-height: 840px;
  }

  .about-panel,
  .about-copy {
    text-align: center;
  }

  .about-photo {
    justify-self: center;
  }

  .hero-pill {
    max-width: 100%;
    padding: 7px 14px;
    white-space: normal;
  }

  .hero-center h1 span {
    display: block;
    width: 100%;
    max-width: 100%;
    white-space: normal;
    overflow-wrap: normal;
    word-break: normal;
  }

  .hero-center h1 .desktop-line {
    display: none;
  }

  .hero-center h1 .mobile-line {
    display: block;
  }

  .hero-text {
    width: 100%;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
    font-size: 0.88rem;
  }

  .hero-actions {
    width: 100%;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
  }

  .btn {
    width: 100%;
  }

  .hero-stats {
    width: 100%;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px 4px;
  }

  .hero-stats div {
    min-width: 0;
    justify-items: center;
    text-align: center;
  }

  .hero-stats span {
    max-width: 100%;
    font-size: 0.56rem;
    line-height: 1.25;
    white-space: normal;
  }

  .portrait-frame {
    min-height: 540px;
  }

  .portrait-photo-shell {
    width: min(88%, 380px);
  }

  .portrait-badge {
    left: 18px;
    right: 18px;
    bottom: 18px;
  }

  .footer-grid {
    flex-direction: column;
  }
}

