:root {
  --bg: #ffffff;
  --bg-soft: #f5f5f5;
  --surface: #ffffff;
  --surface-strong: #f0f0f0;
  --text: #090909;
  --muted: #5f6368;
  --line: rgba(9, 9, 9, 0.12);
  --accent: #111111;
  --accent-contrast: #ffffff;
  --success: #16a34a;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.1);
  --radius-lg: 32px;
  --radius-md: 22px;
  --container: 1180px;
}

:root[data-theme="dark"] {
  --bg: #050505;
  --bg-soft: #0f0f0f;
  --surface: #111111;
  --surface-strong: #181818;
  --text: #f7f7f7;
  --muted: #a3a3a3;
  --line: rgba(255, 255, 255, 0.14);
  --accent: #ffffff;
  --accent-contrast: #050505;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Poppins, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
  transition: background 220ms ease, color 220ms ease;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(circle at 12% 8%, color-mix(in srgb, var(--accent) 11%, transparent), transparent 30rem),
    radial-gradient(circle at 86% 20%, color-mix(in srgb, var(--accent) 7%, transparent), transparent 28rem),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-soft) 48%, var(--bg) 100%);
  content: "";
}

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

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

button,
input,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.site-shell {
  min-height: 100vh;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 1rem;
  width: min(1240px, calc(100% - 2rem));
  margin: 0.75rem auto 0;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.6rem;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.06);
  backdrop-filter: blur(18px);
}

.brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  min-width: max-content;
  padding-right: 0.3rem;
}

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-contrast);
  font-weight: 950;
  letter-spacing: -0.08em;
}

.brand-lockup strong,
.brand-lockup small {
  display: block;
  line-height: 1.1;
}

.brand-lockup strong {
  font-size: 0.98rem;
  letter-spacing: -0.04em;
}

.brand-lockup small {
  margin-top: 0.15rem;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  min-width: 0;
}

.site-nav a {
  border-radius: 999px;
  padding: 0.7rem 0.82rem;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 800;
  white-space: nowrap;
}

.site-nav a:hover {
  background: var(--surface-strong);
  color: var(--text);
}

.header-actions,
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.55rem;
}

.toggle-button,
.button,
form button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 999px;
  padding: 0.72rem 1rem;
  font-weight: 900;
  white-space: nowrap;
  transition: transform 180ms ease, background 180ms ease, border-color 180ms ease, color 180ms ease;
}

.toggle-button {
  gap: 0.45rem;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text);
}

.toggle-button span {
  display: inline-grid;
  place-items: center;
  min-width: 1.8rem;
  height: 1.8rem;
  border-radius: 999px;
  background: var(--surface-strong);
  color: var(--text);
  font-size: 0.76rem;
}

.button,
form button {
  border: 1px solid var(--accent);
  background: var(--accent);
  color: var(--accent-contrast);
}

.button:hover,
form button:hover,
.toggle-button:hover {
  transform: translateY(-2px);
}

.button-small {
  min-height: 40px;
  padding: 0.62rem 0.9rem;
  font-size: 0.9rem;
}

.button-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--line);
}

.button-ghost:hover {
  background: var(--surface-strong);
}

.hero-section {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.82fr);
  gap: clamp(1.4rem, 5vw, 4.5rem);
  align-items: center;
  padding-block: clamp(4.5rem, 9vw, 8rem) clamp(2rem, 6vw, 4rem);
}

.eyebrow,
.card-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  font-weight: 950;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.eyebrow {
  margin-bottom: 1rem;
  border: 1px solid var(--line);
  padding: 0.42rem 0.7rem;
  background: var(--surface);
  color: var(--muted);
  font-size: 0.75rem;
}

.card-kicker {
  color: var(--muted);
  font-size: 0.72rem;
}

.hero-copy h1,
.section-heading h2,
.contact-copy h2 {
  margin: 0;
  color: var(--text);
  font-weight: 950;
  letter-spacing: -0.075em;
}

.hero-copy h1 {
  max-width: 880px;
  font-size: clamp(3rem, 8vw, 6.7rem);
  line-height: 0.9;
}

.hero-copy p {
  max-width: 720px;
  margin: 1.35rem 0 0;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.18rem);
}

.hero-actions {
  justify-content: flex-start;
  margin-top: 2rem;
}

.profile-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.profile-card img {
  width: 100%;
  height: min(62vh, 600px);
  min-height: 420px;
  object-fit: cover;
  filter: grayscale(1) contrast(1.05);
}

.profile-card::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 36%, rgba(0, 0, 0, 0.82));
  content: "";
}

.availability,
.profile-info {
  position: absolute;
  z-index: 2;
}

.availability {
  top: 1rem;
  left: 1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  border-radius: 999px;
  padding: 0.55rem 0.75rem;
  background: rgba(255, 255, 255, 0.9);
  color: #090909;
  font-size: 0.82rem;
  font-weight: 900;
}

.availability span {
  width: 0.62rem;
  height: 0.62rem;
  border-radius: 999px;
  background: var(--success);
}

.profile-info {
  right: 1rem;
  bottom: 1rem;
  left: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 24px;
  padding: 1rem;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  backdrop-filter: blur(10px);
}

.profile-info h2 {
  margin: 0 0 0.2rem;
  font-size: clamp(1.6rem, 4vw, 2.8rem);
  letter-spacing: -0.06em;
}

.profile-info p {
  margin: 0;
  color: rgba(255, 255, 255, 0.75);
}

.stats-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.8rem;
  padding-bottom: clamp(2.8rem, 7vw, 5rem);
}

.stats-strip div {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: clamp(1.1rem, 3vw, 1.6rem);
  background: var(--surface);
}

.stats-strip strong {
  display: block;
  color: var(--text);
  font-size: clamp(2rem, 4vw, 3.2rem);
  line-height: 1;
  letter-spacing: -0.07em;
}

.stats-strip span {
  display: block;
  margin-top: 0.5rem;
  color: var(--muted);
  font-weight: 800;
}

.section-block {
  padding-block: clamp(3.6rem, 8vw, 6.5rem);
}

.section-heading {
  margin-bottom: clamp(1.8rem, 4vw, 3rem);
}

.section-heading.centered {
  max-width: 850px;
  margin-inline: auto;
  text-align: center;
}

.section-heading.centered .eyebrow {
  margin-inline: auto;
}

.section-heading h2,
.contact-copy h2 {
  font-size: clamp(2.2rem, 5vw, 4.6rem);
  line-height: 0.98;
}

.section-heading p,
.contact-copy p,
.service-card p,
.project-body p,
.demo-card p,
.process-list p {
  color: var(--muted);
}

.section-heading p,
.contact-copy p {
  max-width: 720px;
  margin: 1rem 0 0;
  font-size: 1.02rem;
}

.section-heading.centered p {
  margin-inline: auto;
}

.split-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.68fr);
  align-items: end;
  gap: 2rem;
}

.split-heading p {
  margin-bottom: 0.2rem;
}

.service-grid,
.project-grid,
.demo-grid,
.process-list {
  display: grid;
  gap: 1rem;
}

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

.service-card,
.project-card,
.demo-card,
.process-list article,
.contact-section form {
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.service-card {
  min-height: 230px;
  border-radius: var(--radius-lg);
  padding: clamp(1.2rem, 3vw, 1.8rem);
}

.service-card h3,
.project-body h3,
.demo-card h3,
.process-list h3 {
  margin: 0 0 0.6rem;
  color: var(--text);
  letter-spacing: -0.045em;
}

.service-card h3 {
  font-size: 1.35rem;
}

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

.project-card {
  display: grid;
  overflow: hidden;
  border-radius: var(--radius-lg);
}

.project-card.featured {
  grid-column: span 2;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
}

.project-media {
  min-height: 240px;
  background: var(--surface-strong);
}

.project-media img {
  width: 100%;
  height: 100%;
  min-height: 240px;
  object-fit: cover;
}

.project-body {
  display: grid;
  align-content: start;
  padding: clamp(1.15rem, 3vw, 1.6rem);
}

.project-body h3,
.demo-card h3 {
  font-size: 1.38rem;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 1rem 0 1.15rem;
}

.tag-list span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.32rem 0.55rem;
  background: var(--surface-strong);
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 850;
}

.text-link {
  width: fit-content;
  color: var(--text);
  font-weight: 950;
}

.text-link:hover {
  text-decoration: underline;
  text-underline-offset: 0.25rem;
}

.demo-section {
  border-block: 1px solid var(--line);
  background: var(--surface-strong);
}

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

.demo-card {
  overflow: hidden;
  border-radius: var(--radius-lg);
}

.demo-card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  filter: grayscale(0.2);
}

.demo-card div {
  display: grid;
  align-content: start;
  gap: 0.65rem;
  padding: 1.2rem;
}

.demo-card .button {
  width: fit-content;
}

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

.process-list article {
  border-radius: var(--radius-md);
  padding: 1.2rem;
  box-shadow: none;
}

.process-list span {
  display: inline-flex;
  margin-bottom: 1rem;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 950;
}

.contact-section {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(320px, 1.08fr);
  gap: clamp(1.4rem, 5vw, 4rem);
  align-items: start;
  padding-block: clamp(3.6rem, 8vw, 6.5rem);
}

.contact-section form {
  display: grid;
  gap: 0.95rem;
  border-radius: var(--radius-lg);
  padding: clamp(1.1rem, 3vw, 1.8rem);
}

label {
  display: grid;
  gap: 0.42rem;
  color: var(--text);
  font-weight: 900;
}

input,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 0.88rem 0.95rem;
  background: var(--bg);
  color: var(--text);
  outline: none;
}

textarea {
  min-height: 130px;
  resize: vertical;
}

input:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 14%, transparent);
}

.form-status {
  min-height: 1.4rem;
  margin: 0;
  color: var(--success);
  font-weight: 900;
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  border-top: 1px solid var(--line);
  padding-block: 2rem;
  color: var(--muted);
}

.site-footer span {
  color: var(--text);
  font-weight: 950;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 1100px) {
  .site-header {
    grid-template-columns: 1fr auto;
    border-radius: 28px;
  }

  .site-nav {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-content: flex-start;
    overflow-x: auto;
    padding-top: 0.15rem;
  }

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

  .project-card.featured {
    grid-column: span 2;
    grid-template-columns: 1fr;
  }

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

@media (max-width: 760px) {
  .container,
  .site-header {
    width: min(100% - 1rem, var(--container));
  }

  .site-header {
    grid-template-columns: 1fr;
    align-items: start;
    margin-top: 0.5rem;
    border-radius: 24px;
    padding: 0.7rem;
  }

  .brand-lockup {
    width: 100%;
  }

  .site-nav {
    width: 100%;
    gap: 0.25rem;
    padding-bottom: 0.1rem;
  }

  .site-nav a {
    padding: 0.62rem 0.72rem;
    font-size: 0.84rem;
  }

  .header-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .header-cta {
    width: 100%;
  }

  .hero-section {
    padding-top: 3.4rem;
  }

  .hero-copy h1 {
    font-size: clamp(2.65rem, 16vw, 4.4rem);
  }

  .hero-actions .button {
    width: 100%;
  }

  .profile-card img {
    min-height: 360px;
  }

  .stats-strip,
  .service-grid,
  .project-grid,
  .demo-grid,
  .process-list {
    grid-template-columns: 1fr;
  }

  .project-card.featured {
    grid-column: span 1;
  }

  .section-heading.centered {
    text-align: left;
  }

  .section-heading.centered .eyebrow,
  .section-heading.centered p {
    margin-inline: 0;
  }

  .section-heading h2,
  .contact-copy h2 {
    font-size: clamp(2rem, 12vw, 3.2rem);
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 420px) {
  .toggle-button {
    flex: 1 1 auto;
  }

  .brand-lockup small {
    display: none;
  }
}

.slider-shell {
  position: relative;
}

.slider-controls {
  display: flex;
  justify-content: flex-end;
  gap: 0.6rem;
  margin-bottom: 1rem;
}

.slider-button {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font-size: 1.05rem;
  font-weight: 950;
  transition: transform 180ms ease, background 180ms ease;
}

.slider-button:hover {
  transform: translateY(-2px);
  background: var(--surface-strong);
}

.project-grid.slider-track,
.demo-grid.slider-track {
  display: flex;
  grid-template-columns: none;
  gap: 1rem;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  padding: 0.2rem 0.1rem 1.1rem;
  scroll-padding-inline: 0.1rem;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
}

.slider-track::-webkit-scrollbar {
  height: 10px;
}

.slider-track::-webkit-scrollbar-track {
  background: var(--surface-strong);
  border-radius: 999px;
}

.slider-track::-webkit-scrollbar-thumb {
  background: var(--line);
  border-radius: 999px;
}

.slider-track > .project-card,
.slider-track > .demo-card {
  flex: 0 0 clamp(280px, 38vw, 460px);
  scroll-snap-align: start;
}

.slider-track > .project-card.featured {
  grid-column: auto;
  grid-template-columns: 1fr;
}

.slider-track > .demo-card {
  flex-basis: clamp(280px, 32vw, 390px);
}

@media (min-width: 1101px) {
  .slider-track > .project-card.featured {
    flex-basis: 540px;
  }
}

@media (max-width: 760px) {
  .slider-controls {
    justify-content: flex-start;
  }

  .project-grid.slider-track,
  .demo-grid.slider-track {
    margin-inline: -0.25rem;
    padding-inline: 0.25rem;
  }

  .slider-track > .project-card,
  .slider-track > .demo-card,
  .slider-track > .project-card.featured {
    flex-basis: min(88vw, 360px);
  }
}

/* Mobile organization pass */
@media (max-width: 760px) {
  html,
  body {
    overflow-x: hidden;
  }

  body::before {
    background:
      radial-gradient(circle at 50% 0%, color-mix(in srgb, var(--accent) 10%, transparent), transparent 18rem),
      linear-gradient(180deg, var(--bg) 0%, var(--bg-soft) 52%, var(--bg) 100%);
  }

  .container,
  .site-header {
    width: min(100% - 1.1rem, var(--container));
  }

  .site-header {
    gap: 0.65rem;
    padding: 0.62rem;
    border-radius: 22px;
  }

  .brand-lockup {
    gap: 0.6rem;
  }

  .brand-mark {
    width: 40px;
    height: 40px;
  }

  .site-nav {
    display: flex;
    margin-inline: -0.2rem;
    overflow-x: auto;
    padding: 0.1rem 0.2rem 0.2rem;
    scrollbar-width: none;
  }

  .site-nav::-webkit-scrollbar {
    display: none;
  }

  .site-nav a {
    flex: 0 0 auto;
    border: 1px solid var(--line);
    background: var(--surface);
    padding: 0.6rem 0.72rem;
    font-size: 0.8rem;
  }

  .header-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem;
  }

  .toggle-button,
  .header-cta {
    width: 100%;
    min-height: 42px;
    padding: 0.62rem 0.7rem;
    font-size: 0.84rem;
  }

  .header-cta {
    grid-column: 1 / -1;
  }

  .hero-section {
    gap: 1.4rem;
    padding-block: 2.6rem 2rem;
  }

  .eyebrow {
    margin-bottom: 0.75rem;
    padding: 0.36rem 0.58rem;
    font-size: 0.66rem;
  }

  .hero-copy h1 {
    max-width: 12ch;
    font-size: clamp(2.45rem, 15vw, 4rem);
    line-height: 0.94;
  }

  .hero-copy p {
    margin-top: 1rem;
    font-size: 0.98rem;
    line-height: 1.65;
  }

  .hero-actions {
    gap: 0.55rem;
    margin-top: 1.35rem;
  }

  .profile-card {
    border-radius: 24px;
  }

  .profile-card img {
    height: 340px;
    min-height: 0;
  }

  .availability {
    top: 0.75rem;
    left: 0.75rem;
    max-width: calc(100% - 1.5rem);
    font-size: 0.75rem;
  }

  .profile-info {
    right: 0.75rem;
    bottom: 0.75rem;
    left: 0.75rem;
    border-radius: 18px;
    padding: 0.85rem;
  }

  .profile-info h2 {
    font-size: 1.55rem;
  }

  .profile-info p {
    font-size: 0.86rem;
    line-height: 1.45;
  }

  .stats-strip {
    gap: 0.55rem;
    padding-bottom: 2.4rem;
  }

  .stats-strip div,
  .service-card,
  .process-list article,
  .contact-section form {
    border-radius: 20px;
  }

  .stats-strip strong {
    font-size: 2rem;
  }

  .stats-strip span {
    font-size: 0.9rem;
  }

  .section-block,
  .contact-section {
    padding-block: 2.9rem;
  }

  .section-heading {
    margin-bottom: 1.35rem;
  }

  .section-heading h2,
  .contact-copy h2 {
    font-size: clamp(1.95rem, 11vw, 3rem);
    line-height: 1;
  }

  .section-heading p,
  .contact-copy p {
    font-size: 0.96rem;
    line-height: 1.65;
  }

  .service-card {
    min-height: 0;
    padding: 1.05rem;
  }

  .service-card h3,
  .project-body h3,
  .demo-card h3,
  .process-list h3 {
    font-size: 1.2rem;
  }

  .slider-controls {
    justify-content: space-between;
    margin-bottom: 0.75rem;
  }

  .slider-button {
    width: 42px;
    height: 42px;
  }

  .project-grid.slider-track,
  .demo-grid.slider-track {
    gap: 0.75rem;
    margin-inline: -0.55rem;
    padding-inline: 0.55rem;
    padding-bottom: 0.9rem;
    scroll-padding-inline: 0.55rem;
  }

  .slider-track > .project-card,
  .slider-track > .demo-card,
  .slider-track > .project-card.featured {
    flex-basis: calc(100vw - 2.2rem);
    max-width: 390px;
  }

  .project-card,
  .demo-card {
    border-radius: 22px;
  }

  .project-media img {
    height: 190px;
    min-height: 190px;
  }

  .demo-card img {
    height: 185px;
  }

  .project-body,
  .demo-card div {
    padding: 1rem;
  }

  .tag-list {
    gap: 0.35rem;
    margin: 0.8rem 0 0.95rem;
  }

  .tag-list span {
    font-size: 0.7rem;
  }

  .process-list article {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    column-gap: 0.9rem;
    padding: 1rem;
  }

  .process-list article span {
    grid-row: span 2;
    margin: 0;
  }

  .process-list article h3,
  .process-list article p {
    margin: 0;
  }

  .contact-section {
    gap: 1.2rem;
  }

  .contact-section form {
    gap: 0.85rem;
    padding: 1rem;
  }

  label {
    font-size: 0.88rem;
  }

  input,
  textarea {
    border-radius: 14px;
    padding: 0.82rem 0.85rem;
    font-size: 0.95rem;
  }

  textarea {
    min-height: 112px;
  }

  .site-footer {
    padding-block: 1.4rem;
    font-size: 0.9rem;
  }
}

@media (max-width: 420px) {
  .brand-lockup strong {
    font-size: 0.92rem;
  }

  .toggle-button {
    min-width: 0;
  }

  .toggle-button span {
    min-width: 1.55rem;
    height: 1.55rem;
  }

  .hero-copy h1 {
    max-width: 11ch;
  }
}
