/* ==========================================================================
   Polar Metal — site styles
   Dark graphite, teal accent, technical type.
   ========================================================================== */

@font-face {
  font-family: 'Archivo';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/assets/fonts/archivo-400_700.woff2') format('woff2');
}

@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/assets/fonts/plexmono-400.woff2') format('woff2');
}

@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/assets/fonts/plexmono-500.woff2') format('woff2');
}

:root {
  --ink: #0c0f11;
  --ink-soft: #12171a;
  --ink-2: #171d21;
  --paper: #f2f2ee;
  --paper-2: #e7e7e1;
  --teal: #00a5b9;
  --teal-bright: #2cc4d6;
  --teal-dark: #007f8f;
  --text: #e9eceb;
  --muted: rgba(233, 236, 235, 0.62);
  --line: rgba(255, 255, 255, 0.14);
  --max: 1280px;
  --gutter: clamp(20px, 4vw, 48px);
  --header-h: 76px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 24px);
}

body {
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font-family: 'Archivo', 'Helvetica Neue', Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

body.menu-open {
  overflow: hidden;
}

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

h1,
h2,
h3,
p,
ul,
ol,
dl,
dd,
figure {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

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

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

::selection {
  background: var(--teal);
  color: #04181b;
}

:focus-visible {
  outline: 2px solid var(--teal-bright);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 200;
  transform: translateY(-200%);
  background: var(--teal);
  color: #04181b;
  padding: 10px 16px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  transition: transform 0.2s var(--ease);
}

.skip-link:focus {
  transform: translateY(0);
}

/* --------------------------------------------------------------------------
   Typography helpers
   -------------------------------------------------------------------------- */

.mono {
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--teal-bright);
}

.section--paper .eyebrow,
.page-hero--paper .eyebrow {
  color: var(--teal-dark);
}

.eyebrow .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--teal);
  flex: none;
}

.display {
  font-size: clamp(2.7rem, 6.4vw, 5.4rem);
  font-weight: 700;
  line-height: 0.94;
  letter-spacing: -0.04em;
  margin-top: 22px;
}

.display--sm {
  font-size: clamp(2.2rem, 4.6vw, 3.9rem);
  line-height: 1;
}

.display .accent {
  color: var(--teal-bright);
}

:lang(es) .display {
  letter-spacing: -0.045em;
}

.lead {
  margin-top: 26px;
  max-width: 58ch;
  font-size: clamp(1rem, 1.4vw, 1.15rem);
  line-height: 1.6;
  color: var(--muted);
}

.section-title {
  font-size: clamp(2rem, 4vw, 3.3rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.03em;
  margin-top: 16px;
}

.section-lead {
  margin-top: 20px;
  max-width: 58ch;
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.6;
}

/* --------------------------------------------------------------------------
   Layout
   -------------------------------------------------------------------------- */

.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  padding-block: clamp(72px, 9vw, 124px);
}

.section--tight {
  padding-block: clamp(48px, 6vw, 80px);
}

.section--paper {
  --text: #0c0f11;
  --muted: rgba(12, 15, 17, 0.6);
  --line: rgba(12, 15, 17, 0.14);
  background: var(--paper);
  color: var(--text);
}

.section--ink {
  background: var(--ink);
  color: var(--text);
}

.section-head {
  margin-bottom: clamp(40px, 5vw, 64px);
  max-width: 780px;
}

.section-head--split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: end;
  gap: 24px 64px;
  max-width: none;
}

.section-head--split .section-lead {
  margin-top: 0;
}

.section-foot {
  margin-top: 44px;
}

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 26px;
  border: 1px solid transparent;
  border-radius: 2px;
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: background 0.25s var(--ease), color 0.25s var(--ease),
    border-color 0.25s var(--ease), transform 0.25s var(--ease);
}

.btn svg {
  width: 15px;
  height: 15px;
}

.btn--primary {
  background: var(--teal);
  border-color: var(--teal);
  color: #04181b;
}

.btn--primary:hover {
  background: var(--teal-bright);
  border-color: var(--teal-bright);
}

.btn--ghost {
  border-color: var(--line);
  color: inherit;
  background: transparent;
}

.btn--ghost:hover {
  border-color: var(--teal);
  color: var(--teal-bright);
}

.section--paper .btn--ghost:hover {
  color: var(--teal-dark);
}

.btn--dark {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

.btn--dark:hover {
  background: #04181b;
}

.btn--sm {
  padding: 10px 16px;
  font-size: 0.8rem;
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 28px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--teal-bright);
  border-bottom: 1px solid transparent;
  padding-bottom: 3px;
  transition: border-color 0.25s var(--ease), gap 0.25s var(--ease);
}

.link-arrow:hover {
  border-color: currentColor;
  gap: 16px;
}

.link-arrow svg {
  width: 14px;
  height: 14px;
}

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--line);
  background: rgba(12, 15, 17, 0.82);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  transition: background 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.site-header.is-scrolled {
  background: rgba(12, 15, 17, 0.96);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.4);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: var(--header-h);
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex: none;
}

.brand-star {
  width: 10px;
  height: 26px;
  color: var(--teal);
  transition: color 0.25s var(--ease);
}

.brand:hover .brand-star {
  color: var(--teal-bright);
}

.brand-word {
  font-size: 15px;
  font-weight: 300;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #fff;
  white-space: nowrap;
}

.brand-word b {
  font-weight: 700;
}

.nav {
  display: flex;
  align-items: center;
  gap: clamp(18px, 3vw, 36px);
  margin-left: auto;
}

.nav-link {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  padding-block: 6px;
  position: relative;
  transition: color 0.2s var(--ease);
}

.nav-link::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: var(--teal);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s var(--ease);
}

.nav-link:hover {
  color: #fff;
}

.nav-link:hover::after,
.nav-link[aria-current='page']::after {
  transform: scaleX(1);
}

.nav-link[aria-current='page'] {
  color: #fff;
}

.header-tools {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-left: clamp(8px, 2vw, 24px);
}

.lang-switch {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 2px;
  overflow: hidden;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.08em;
}

.lang-switch a {
  padding: 5px 8px;
  color: var(--muted);
  transition: background 0.2s var(--ease), color 0.2s var(--ease);
}

.lang-switch a:hover {
  color: #fff;
}

.lang-switch a[aria-current='true'] {
  background: var(--teal);
  color: #04181b;
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: transparent;
  cursor: pointer;
  position: relative;
}

.nav-toggle span {
  position: absolute;
  left: 11px;
  width: 18px;
  height: 1px;
  background: #fff;
  transition: transform 0.3s var(--ease), opacity 0.2s var(--ease);
}

.nav-toggle span:nth-child(1) {
  top: 17px;
}

.nav-toggle span:nth-child(2) {
  top: 23px;
}

.nav-toggle[aria-expanded='true'] span:nth-child(1) {
  transform: translateY(3px) rotate(45deg);
}

.nav-toggle[aria-expanded='true'] span:nth-child(2) {
  transform: translateY(-3px) rotate(-45deg);
}

/* Mobile menu ------------------------------------------------------------- */

.mobile-menu {
  position: fixed;
  inset: var(--header-h) 0 0;
  z-index: 99;
  background: var(--ink);
  padding: 40px var(--gutter) 32px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-8px);
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
}

.mobile-menu.is-open {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.mobile-menu[hidden] {
  display: none;
}

.mobile-link {
  display: flex;
  align-items: baseline;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  font-size: clamp(1.5rem, 6vw, 2rem);
  font-weight: 600;
  letter-spacing: -0.02em;
}

.mobile-num {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--teal);
  width: 20px;
  flex: none;
}

.mobile-link[aria-current='page'] {
  color: var(--teal-bright);
}

.mobile-foot {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-top: 24px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
  position: relative;
  overflow: hidden;
  padding-block: clamp(56px, 8vw, 104px) clamp(56px, 7vw, 88px);
  border-bottom: 1px solid var(--line);
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 72px 72px;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 25% 30%, #000 20%, transparent 78%);
  mask-image: radial-gradient(ellipse 80% 70% at 25% 30%, #000 20%, transparent 78%);
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  top: -30%;
  right: -10%;
  width: 60vw;
  height: 60vw;
  background: radial-gradient(circle, rgba(0, 165, 185, 0.16), transparent 62%);
  pointer-events: none;
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  align-items: center;
  gap: clamp(40px, 5vw, 72px);
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.hero-copy {
  max-width: 660px;
}

.hero .actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.spec-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 32px;
  margin-top: clamp(40px, 5vw, 60px);
  border-top: 1px solid var(--line);
}

.spec-list > div {
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

.spec-list dt {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.spec-list dd {
  margin-top: 5px;
  font-size: 13.5px;
  color: #dfe3e2;
}

.hero-figure {
  position: relative;
}

.frame {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--ink-2);
}

.frame::after {
  content: '';
  position: absolute;
  top: 10px;
  left: 10px;
  width: 8px;
  height: 8px;
  border-top: 1px solid var(--teal);
  border-left: 1px solid var(--teal);
  pointer-events: none;
}

.frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-figure .frame {
  aspect-ratio: 4 / 3;
}

.hero-figure figcaption,
.about-figure figcaption {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 10px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   Capability strip
   -------------------------------------------------------------------------- */

.strip {
  border-bottom: 1px solid var(--line);
  background: var(--ink);
}

.strip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 0;
  max-width: var(--max);
  margin-inline: auto;
  padding: 18px var(--gutter);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.strip-list li {
  display: flex;
  align-items: center;
}

.strip-list li::after {
  content: '/';
  margin-inline: 14px;
  color: var(--teal);
  opacity: 0.7;
}

.strip-list li:last-child::after {
  display: none;
}

/* --------------------------------------------------------------------------
   Services list (home)
   -------------------------------------------------------------------------- */

.service-list {
  border-top: 1px solid var(--line);
}

.service-row {
  display: grid;
  grid-template-columns: 52px 56px minmax(0, 1fr) 32px;
  align-items: center;
  gap: 20px;
  padding: 26px 6px;
  border-bottom: 1px solid var(--line);
  color: inherit;
  transition: background 0.3s var(--ease), padding-left 0.3s var(--ease);
}

.service-row:hover {
  background: rgba(12, 15, 17, 0.035);
  padding-left: 18px;
}

.service-num {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.service-icon {
  display: block;
  flex: none;
  width: 40px;
  height: 40px;
  color: var(--ink);
  transition: color 0.3s var(--ease);
}

.service-icon svg {
  width: 100%;
  height: 100%;
}

.service-row:hover .service-icon {
  color: var(--teal-dark);
}

.service-title {
  display: block;
  font-size: clamp(1.15rem, 2vw, 1.5rem);
  font-weight: 600;
  letter-spacing: -0.015em;
}

.service-short {
  display: block;
  margin-top: 5px;
  font-size: 14px;
  color: var(--muted);
}

.service-arrow {
  width: 18px;
  height: 18px;
  color: var(--muted);
  justify-self: end;
  transition: color 0.25s var(--ease), transform 0.25s var(--ease);
}

.service-arrow svg {
  width: 100%;
  height: 100%;
}

.service-row:hover .service-arrow {
  color: var(--teal-dark);
  transform: translate(3px, -3px);
}

/* --------------------------------------------------------------------------
   Work / cards
   -------------------------------------------------------------------------- */

.work-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(28px, 3vw, 40px) clamp(18px, 2vw, 28px);
}

.card {
  display: flex;
  flex-direction: column;
  color: inherit;
}

.card-media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  border: 1px solid var(--line);
  background: var(--ink-2);
}

.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s var(--ease);
}

.card:hover .card-media img {
  transform: scale(1.035);
}

.card-tag {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 5px 9px;
  background: rgba(12, 15, 17, 0.74);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #fff;
}

.card--feature {
  grid-column: 1 / -1;
  margin-bottom: 8px;
}

.card--feature .card-media {
  aspect-ratio: 16 / 9;
}

.card--feature .card-title-row h3 {
  font-size: clamp(1.4rem, 2.4vw, 2rem);
}

.card-body {
  padding-top: 16px;
}

.card-title-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

.card-title-row h3 {
  font-size: 1.12rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.25;
}

.card-year {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: var(--muted);
  flex: none;
}

.card-body p {
  margin-top: 7px;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--muted);
}

.card-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal-bright);
  transition: gap 0.25s var(--ease);
}

.card-link svg {
  width: 13px;
  height: 13px;
}

.card:hover .card-link {
  gap: 14px;
}

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

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 36px;
}

.filter {
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: transparent;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  cursor: pointer;
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease),
    background 0.2s var(--ease);
}

.filter:hover {
  color: #fff;
  border-color: var(--teal);
}

.filter.is-active {
  background: var(--teal);
  border-color: var(--teal);
  color: #04181b;
}

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

.grid-empty {
  padding: 40px 0;
  color: var(--muted);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
}

/* --------------------------------------------------------------------------
   Process
   -------------------------------------------------------------------------- */

.process {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(20px, 2.5vw, 36px);
  border-top: 1px solid var(--line);
}

.process-step {
  position: relative;
  padding-top: 26px;
}

.process-step::before {
  content: '';
  position: absolute;
  top: -1px;
  left: 0;
  width: 34px;
  height: 2px;
  background: var(--teal);
}

.process-num {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--teal-dark);
}

.process-step h3 {
  margin: 14px 0 8px;
  font-size: 1.12rem;
  font-weight: 600;
}

.process-step p {
  font-size: 14px;
  line-height: 1.55;
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   About teaser
   -------------------------------------------------------------------------- */

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  align-items: center;
  gap: clamp(40px, 6vw, 88px);
}

.about-copy .section-lead {
  max-width: 54ch;
}

.ticks {
  margin-top: 28px;
}

.ticks li {
  position: relative;
  padding-left: 22px;
  margin-block: 11px;
  font-size: 14.5px;
  color: #cfd5d4;
}

.ticks li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 7px;
  height: 7px;
  background: var(--teal);
}

.section--paper .ticks li {
  color: rgba(12, 15, 17, 0.78);
}

.about-figure .frame {
  aspect-ratio: 4 / 5;
}

/* --------------------------------------------------------------------------
   CTA band
   -------------------------------------------------------------------------- */

.cta {
  background: var(--teal);
  color: #04181b;
  padding-block: clamp(52px, 7vw, 80px);
}

.cta-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 32px 64px;
}

.cta h2 {
  font-size: clamp(1.7rem, 3.4vw, 2.6rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.03em;
  max-width: 20ch;
}

.cta p {
  margin-top: 14px;
  max-width: 56ch;
  color: rgba(4, 24, 27, 0.76);
  font-size: 1rem;
}

.cta .actions {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.cta-direct {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.06em;
  border-bottom: 1px solid rgba(4, 24, 27, 0.35);
  padding-bottom: 2px;
}

.cta-direct:hover {
  border-color: currentColor;
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--ink);
  padding-top: clamp(52px, 6vw, 80px);
}

.footer-top {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
  gap: 40px clamp(24px, 4vw, 56px);
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.footer-brand img {
  width: 210px;
  height: auto;
  opacity: 0.92;
}

.footer-brand p {
  margin-top: 18px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted);
}

.footer-col h2 {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 16px;
}

.footer-col li {
  margin-block: 9px;
  font-size: 14px;
}

.footer-col a {
  color: #dfe3e2;
  transition: color 0.2s var(--ease);
}

.footer-col a:hover {
  color: var(--teal-bright);
}

.footer-col .muted {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 24px;
  max-width: var(--max);
  margin: clamp(40px, 5vw, 64px) auto 0;
  padding: 20px var(--gutter) 28px;
  border-top: 1px solid var(--line);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.footer-legal a:hover {
  color: #fff;
}

/* --------------------------------------------------------------------------
   Inner page hero
   -------------------------------------------------------------------------- */

.page-hero {
  position: relative;
  padding-block: clamp(56px, 7vw, 96px) clamp(44px, 5vw, 64px);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}

.page-hero::before {
  content: '';
  position: absolute;
  top: -40%;
  right: -5%;
  width: 40vw;
  height: 40vw;
  background: radial-gradient(circle, rgba(0, 165, 185, 0.12), transparent 65%);
  pointer-events: none;
}

.page-hero .wrap {
  position: relative;
  z-index: 1;
}

.page-hero .lead {
  max-width: 66ch;
}

/* --------------------------------------------------------------------------
   Services page
   -------------------------------------------------------------------------- */

.service-block {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(32px, 5vw, 80px);
  padding-block: clamp(44px, 5vw, 72px);
  border-top: 1px solid var(--line);
}

.service-block:first-child {
  border-top: 0;
  padding-top: 0;
}

.service-block-head {
  position: sticky;
  top: calc(var(--header-h) + 32px);
  align-self: start;
}

.service-block-head h2 {
  margin-top: 18px;
  font-size: clamp(1.6rem, 3vw, 2.3rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.025em;
}

.service-icon--lg {
  width: 56px;
  height: 56px;
  color: var(--teal);
  margin-top: 22px;
}

.service-lead {
  font-size: clamp(1rem, 1.3vw, 1.1rem);
  line-height: 1.7;
  color: #cfd5d4;
}

.service-meta {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
  gap: 28px 48px;
  margin-top: 36px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.service-meta h3 {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal-bright);
  margin-bottom: 14px;
}

.service-meta p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   Project detail
   -------------------------------------------------------------------------- */

.detail-head {
  padding-block: clamp(40px, 5vw, 64px) clamp(32px, 4vw, 48px);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.breadcrumb a:hover {
  color: var(--teal-bright);
}

.detail-head .display {
  margin-top: 26px;
}

.meta-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
  margin-top: clamp(32px, 4vw, 48px);
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.meta-list dt {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--muted);
}

.meta-list dd {
  margin-top: 7px;
  font-size: 14px;
  line-height: 1.5;
  color: #dfe3e2;
}

.meta-list dd a:hover {
  color: var(--teal-bright);
}

.detail-media {
  padding-bottom: 0;
}

.detail-section {
  padding-bottom: 0;
}

.detail-media .frame img {
  aspect-ratio: 16 / 9;
}

.detail-body {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(0, 0.55fr);
  gap: clamp(32px, 5vw, 72px);
  padding-block: 0 clamp(40px, 5vw, 64px);
}

.detail-text p {
  max-width: 66ch;
  margin-bottom: 20px;
  font-size: 1.03rem;
  line-height: 1.75;
  color: #cfd5d4;
}

.detail-aside {
  align-self: start;
  padding-left: 28px;
  border-left: 1px solid var(--line);
}

.detail-aside .mono {
  margin-top: 12px;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.6;
}

.detail-aside .btn {
  margin-top: 28px;
}

.next-project {
  border-top: 1px solid var(--line);
  padding-block: clamp(40px, 5vw, 64px);
}

.next-link {
  display: block;
}

.next-title {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 12px;
  font-size: clamp(1.4rem, 3vw, 2.3rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  transition: color 0.25s var(--ease);
}

.next-title svg {
  width: 24px;
  height: 24px;
  flex: none;
}

.next-link:hover .next-title {
  color: var(--teal-bright);
}

/* --------------------------------------------------------------------------
   About page
   -------------------------------------------------------------------------- */

.about-body {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(40px, 6vw, 80px);
  align-items: start;
}

.about-text p {
  max-width: 62ch;
  margin-bottom: 22px;
  font-size: clamp(1rem, 1.3vw, 1.1rem);
  line-height: 1.75;
  color: #cfd5d4;
}

.about-side .frame {
  aspect-ratio: 4 / 5;
  position: sticky;
  top: calc(var(--header-h) + 32px);
}

.values {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 40px);
  margin-top: 44px;
}

.value {
  border-top: 1px solid var(--line);
  padding-top: 24px;
}

.value-num {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--teal-dark);
}

.value h3 {
  margin: 14px 0 8px;
  font-size: 1.15rem;
  font-weight: 600;
}

.value p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
}

.location-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: start;
}

.location-grid .section-lead {
  margin-top: 14px;
}

.location-grid .meta-list {
  margin-top: 0;
  border-top: 0;
  padding-top: 0;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

/* --------------------------------------------------------------------------
   Contact page
   -------------------------------------------------------------------------- */

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.65fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}

.form-title {
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: -0.015em;
  margin-bottom: 28px;
}

.field-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 20px;
}

.field {
  display: block;
  margin-bottom: 20px;
}

.field > span {
  display: block;
  margin-bottom: 8px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.field > span em,
.check em {
  font-style: normal;
  color: var(--teal-bright);
}

.field > span small {
  text-transform: none;
  letter-spacing: 0;
  font-size: 10px;
  opacity: 0.75;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 13px 14px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 2px;
  font-size: 15px;
  color: var(--text);
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.field textarea {
  resize: vertical;
  min-height: 130px;
  line-height: 1.55;
}

.field input::placeholder,
.field textarea::placeholder {
  color: rgba(233, 236, 235, 0.34);
}

.field select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 12px) 50%;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

.field select option {
  background: var(--ink-2);
  color: var(--text);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(0, 165, 185, 0.16);
}

.field-error {
  display: none;
  margin-top: 6px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.04em;
  color: #ff8a75;
}

.field.is-invalid input,
.field.is-invalid textarea,
.field.is-invalid select {
  border-color: #e2604a;
}

.field.is-invalid .field-error {
  display: block;
}

.check {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 26px 0 22px;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--muted);
  cursor: pointer;
}

.check input {
  width: 18px;
  height: 18px;
  margin-top: 1px;
  flex: none;
  accent-color: var(--teal);
}

.form-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 24px;
}

.form-note {
  max-width: 36ch;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 9.5px;
  line-height: 1.6;
  color: var(--muted);
}

.form-status {
  min-height: 18px;
  margin-top: 20px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--teal-bright);
}

.form-status.is-error {
  color: #ff8a75;
}

.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.contact-aside {
  padding-left: clamp(0px, 3vw, 40px);
  border-left: 1px solid var(--line);
}

.contact-aside .meta-list {
  grid-template-columns: 1fr;
  gap: 22px;
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.contact-aside dd a {
  color: var(--teal-bright);
}

.contact-aside dd a:hover {
  text-decoration: underline;
}

.response {
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  line-height: 1.6;
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   Privacy / 404
   -------------------------------------------------------------------------- */

.prose {
  max-width: 68ch;
}

.prose p {
  margin-bottom: 20px;
  font-size: 1.02rem;
  line-height: 1.75;
  color: #cfd5d4;
}

.notfound {
  min-height: 62vh;
  display: flex;
  align-items: center;
  border-bottom: 0;
}

.notfound .lead {
  margin-bottom: 32px;
}

/* --------------------------------------------------------------------------
   Reveal animation
   -------------------------------------------------------------------------- */

@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
  }

  .reveal.is-visible {
    opacity: 1;
    transform: none;
  }

  .hero-copy > * {
    animation: rise 0.8s var(--ease) backwards;
  }

  .hero-copy > *:nth-child(2) {
    animation-delay: 0.06s;
  }

  .hero-copy > *:nth-child(3) {
    animation-delay: 0.12s;
  }

  .hero-copy > *:nth-child(4) {
    animation-delay: 0.18s;
  }

  .hero-copy > *:nth-child(5) {
    animation-delay: 0.24s;
  }

  .hero-figure {
    animation: rise 1s var(--ease) 0.15s backwards;
  }

  @keyframes rise {
    from {
      transform: translateY(22px);
    }
    to {
      transform: none;
    }
  }
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 1080px) {
  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 48px;
  }

  .hero-copy {
    max-width: none;
  }

  .hero-figure .frame {
    aspect-ratio: 16 / 9;
  }

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

  .card--feature .card-media {
    aspect-ratio: 16 / 9;
  }

  .about-grid,
  .about-body,
  .contact-grid,
  .location-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .contact-aside {
    padding-left: 0;
    border-left: 0;
    border-top: 1px solid var(--line);
    padding-top: 40px;
  }

  .about-side .frame {
    position: static;
    aspect-ratio: 4 / 5;
    max-width: 520px;
  }

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

  .service-block-head {
    position: static;
  }

  .detail-body {
    grid-template-columns: minmax(0, 1fr);
  }

  .detail-aside {
    padding-left: 0;
    border-left: 0;
    padding-top: 24px;
    border-top: 1px solid var(--line);
  }

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

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

@media (max-width: 860px) {
  .nav {
    display: none;
  }

  .nav-toggle {
    display: block;
  }

  .header-tools {
    margin-left: auto;
  }

  .section-head--split {
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
  }

  .section-head--split .section-lead {
    margin-top: 0;
  }

  .cta-inner {
    grid-template-columns: minmax(0, 1fr);
  }

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

  .values {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
  }

  .value {
    padding-block: 22px;
  }
}

@media (max-width: 640px) {
  :root {
    --header-h: 66px;
  }

  .brand-word {
    font-size: 13px;
    letter-spacing: 0.12em;
  }

  .header-cta {
    display: none;
  }

  .header-inner {
    gap: 12px;
  }

  .hero .actions .btn,
  .section-foot .btn {
    flex: 1 1 auto;
  }

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

  .work-grid,
  .work-grid--all {
    grid-template-columns: minmax(0, 1fr);
  }

  .card--feature .card-media {
    aspect-ratio: 4 / 3;
  }

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

  .process-step {
    padding-block: 22px;
    border-bottom: 1px solid var(--line);
  }

  .process-step::before {
    top: 0;
  }

  .field-row {
    grid-template-columns: minmax(0, 1fr);
  }

  .meta-list,
  .location-grid .meta-list {
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
  }

  .footer-top {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }

  .footer-brand img {
    width: 180px;
  }

  .form-foot .btn {
    width: 100%;
  }

  .strip-list {
    gap: 8px 0;
  }

  .strip-list li {
    white-space: normal;
  }

  .service-row {
    grid-template-columns: 34px minmax(0, 1fr) 24px;
    gap: 14px;
    padding-block: 22px;
  }

  .service-icon {
    display: none;
  }

  .service-block {
    padding-block: 40px;
  }

  .cta h2 {
    max-width: none;
  }

  .next-title {
    gap: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* --------------------------------------------------------------------------
   Render cards & project gallery
   -------------------------------------------------------------------------- */

.card--contain .card-media {
  background: #fff;
}

.card--contain .card-media img {
  object-fit: contain;
}

.project-gallery {
  padding-block: 0 clamp(48px, 6vw, 80px);
}

.gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(16px, 2vw, 24px);
}

.gallery .frame {
  aspect-ratio: 4 / 3;
  background: #fff;
}

.gallery .frame img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.gallery .frame--wide {
  grid-column: 1 / -1;
  aspect-ratio: 21 / 9;
}

.gallery .frame--wide img {
  object-fit: cover;
}

@media (max-width: 640px) {
  .gallery {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* --------------------------------------------------------------------------
   Coverage badge (hero)
   -------------------------------------------------------------------------- */

.coverage-line {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 24px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 2px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  line-height: 1.45;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: #cfd5d4;
}

.coverage-line svg {
  width: 15px;
  height: 15px;
  flex: none;
  color: var(--teal-bright);
}

.footer-coverage {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  max-width: 300px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 9.5px;
  line-height: 1.6;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.footer-coverage svg {
  width: 13px;
  height: 13px;
  flex: none;
  margin-top: 1px;
  color: var(--teal-bright);
}

/* Low-resolution or technical images: keep them legible */
.detail-media.is-narrow .wrap {
  max-width: 940px;
}

.detail-media.is-narrow .frame img {
  aspect-ratio: 4 / 3;
}

.detail-media.is-contain .frame {
  background: #fff;
}

.detail-media.is-contain .frame img {
  object-fit: contain;
  aspect-ratio: 4 / 3;
}

.detail-media.is-4x3 .frame img {
  aspect-ratio: 4 / 3;
}
