/* ==========================================================================
   LucrativeTECH — site styles
   One stylesheet, no framework. Sections: fonts → tokens → base → layout →
   type → buttons → header → components (by page section) → forms → legal →
   motion.
   ========================================================================== */

/* Fonts (self-hosted, latin subset, OFL) ---------------------------------- */
@font-face {
  font-family: "DM Sans";
  src: url("../fonts/dm-sans-latin.woff2") format("woff2");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Marcellus";
  src: url("../fonts/marcellus-latin.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* Tokens ------------------------------------------------------------------ */
:root {
  /* Neutrals: warm, slightly off-white paper and near-black ink */
  --ink: #121211;
  --ink-2: #2b2b29;
  --text: #3b3b37;
  --muted: #66655e;
  --line: #e6e4dc;
  --line-strong: #d3d0c4;
  --paper: #fafaf7;
  --surface: #ffffff;
  --sand: #f3f2ec;

  /* Brand accent — used as a fill (with ink text) or as text on dark only */
  --lime: #bff747;
  --lime-hover: #b0ea33;

  /* Dark surfaces */
  --dark: #121211;
  --dark-2: #1b1b19;
  --dark-line: #2c2c29;
  --on-dark: #f3f3ee;
  --on-dark-muted: #a6a59d;

  /* Product colours */
  --churchly: #2f3f9f;
  --keza: #f59e0b;
  --farm: #15803d;

  --danger: #b42318;
  --danger-bg: #fef3f2;
  --success: #067647;

  --font-sans: "DM Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "Marcellus", ui-serif, Georgia, "Times New Roman", serif;

  /* Type scale (fluid between ~360px and ~1280px viewports) */
  --fs-xs: 0.8125rem;
  --fs-sm: 0.9375rem;
  --fs-base: 1.0625rem;
  --fs-lead: clamp(1.125rem, 1.05rem + 0.35vw, 1.3125rem);
  --fs-h3: clamp(1.25rem, 1.15rem + 0.4vw, 1.5rem);
  --fs-h2: clamp(2rem, 1.45rem + 2.3vw, 3.25rem);
  --fs-h1: clamp(2.625rem, 1.6rem + 4.4vw, 5.25rem);
  --fs-stat: clamp(2.5rem, 2rem + 2vw, 3.75rem);

  /* Spacing: 4px base */
  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px; --s-5: 24px;
  --s-6: 32px; --s-7: 48px; --s-8: 64px; --s-9: 96px;
  --gutter: clamp(16px, 4vw, 32px);
  --section: clamp(72px, 9vw, 128px);
  --header-h: 72px;

  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;

  --shadow-sm: 0 1px 2px rgb(18 18 17 / 0.06);
  --shadow: 0 1px 2px rgb(18 18 17 / 0.04), 0 10px 28px -12px rgb(18 18 17 / 0.16);
  --shadow-lg: 0 2px 4px rgb(18 18 17 / 0.04), 0 28px 56px -20px rgb(18 18 17 / 0.28);

  /* Motion: ease-out that decelerates like an object coming to rest */
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  --dur-fast: 160ms;
  --dur: 240ms;
  --dur-slow: 640ms;

  color-scheme: light;
}

@media (max-width: 899px) {
  :root { --header-h: 64px; }
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 16px);
}
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: var(--fs-base);
  line-height: 1.6;
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

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

h1, h2, h3, h4, p, ul, ol, dl, dd, figure, blockquote { margin: 0; }
ul[role="list"], ol[role="list"] { list-style: none; padding: 0; }

a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.2em; }

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

::selection { background: var(--lime); color: var(--ink); }

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
  border-radius: 4px;
}
.on-dark :focus-visible { outline-color: var(--lime); }

.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 12px; left: 12px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  background: var(--ink);
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform var(--dur) var(--ease-out);
}
.skip-link:focus-visible { transform: none; outline-color: var(--lime); }

.icon {
  width: 1.125em;
  height: 1.125em;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.icon--fill { fill: currentColor; stroke: none; }

/* Layout ------------------------------------------------------------------ */
.container {
  width: 100%;
  max-width: 1240px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.container--narrow { max-width: 860px; }

.section { padding-block: var(--section); }
.section--tight { padding-block: calc(var(--section) * 0.6); }
.section--white { background: var(--surface); }
.section--sand { background: var(--sand); }
.section--rule { border-top: 1px solid var(--line); }

.on-dark {
  background: var(--dark);
  color: var(--on-dark-muted);
}
.on-dark :is(h1, h2, h3, h4, strong) { color: var(--on-dark); }

.section-head {
  display: grid;
  gap: var(--s-4);
  margin-bottom: clamp(40px, 5vw, 64px);
  max-width: 760px;
}
.section-head--split {
  max-width: none;
  grid-template-columns: 1fr;
  align-items: end;
}
@media (min-width: 900px) {
  .section-head--split { grid-template-columns: 1.2fr 1fr; gap: var(--s-7); }
}

/* Type -------------------------------------------------------------------- */
.h1, .h2, .h3, .display {
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 400;
  text-wrap: balance;
}
.h1 { font-size: var(--fs-h1); line-height: 1.02; letter-spacing: -0.02em; }
.h2 { font-size: var(--fs-h2); line-height: 1.08; letter-spacing: -0.015em; }
.h3 { font-size: var(--fs-h3); line-height: 1.25; letter-spacing: -0.005em; }
.h4 {
  color: var(--ink);
  font-size: var(--fs-base);
  font-weight: 600;
  line-height: 1.35;
}

.lead {
  font-size: var(--fs-lead);
  line-height: 1.55;
  color: var(--text);
  max-width: 62ch;
  text-wrap: pretty;
}
.on-dark .lead { color: var(--on-dark-muted); }
.muted { color: var(--muted); }
.small { font-size: var(--fs-sm); }
p { text-wrap: pretty; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.eyebrow::before {
  content: "";
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: 0 0 0 1px rgb(18 18 17 / 0.12) inset;
}
.on-dark .eyebrow { color: var(--on-dark-muted); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
}
.link-arrow .icon { transition: transform var(--dur) var(--ease-out); }
.on-dark .link-arrow { color: var(--on-dark); }
@media (hover: hover) and (pointer: fine) {
  .link-arrow:hover { text-decoration: underline; }
  .link-arrow:hover .icon,
  .card-link:hover .link-arrow .icon { transform: translateX(3px); }
}

/* Buttons ----------------------------------------------------------------- */
.btn {
  --btn-bg: transparent;
  --btn-fg: var(--ink);
  --btn-border: transparent;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid var(--btn-border);
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-size: var(--fs-sm);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.005em;
  text-decoration: none;
  white-space: nowrap;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  transition:
    background-color var(--dur-fast) var(--ease-out),
    border-color var(--dur-fast) var(--ease-out),
    color var(--dur-fast) var(--ease-out),
    transform var(--dur-fast) var(--ease-out);
}
.btn:active:not(:disabled) { transform: scale(0.97); }
.btn:disabled { cursor: not-allowed; opacity: 0.7; }
.btn .icon { transition: transform var(--dur) var(--ease-out); }

.btn--primary { --btn-bg: var(--lime); --btn-fg: var(--ink); }
.btn--dark { --btn-bg: var(--ink); --btn-fg: #fff; }
.btn--ghost { --btn-border: var(--line-strong); }
.on-dark .btn--ghost { --btn-border: var(--dark-line); --btn-fg: var(--on-dark); }
.btn--sm { min-height: 44px; padding: 0 18px; }
.btn--block { width: 100%; }

@media (hover: hover) and (pointer: fine) {
  .btn--primary:hover { --btn-bg: var(--lime-hover); }
  .btn--dark:hover { --btn-bg: #000; }
  .btn--ghost:hover { --btn-border: var(--ink); --btn-bg: var(--surface); }
  .on-dark .btn--ghost:hover { --btn-border: var(--on-dark-muted); --btn-bg: var(--dark-2); }
  .btn:hover .icon-arrow-right { transform: translateX(3px); }
  .btn:hover .icon-arrow-up-right { transform: translate(2px, -2px); }
}

.actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* Header ------------------------------------------------------------------ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: rgb(250 250 247 / 0.86);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--dur) var(--ease-out), background-color var(--dur) var(--ease-out);
}
.site-header.is-scrolled { border-bottom-color: var(--line); }
.menu-open .site-header { background: var(--paper); border-bottom-color: var(--line); }

.header-inner {
  display: flex;
  align-items: center;
  gap: var(--s-5);
  height: 100%;
}
.brand { display: inline-flex; flex: none; border-radius: 6px; }
.brand img { width: auto; height: 30px; }
@media (max-width: 899px) { .brand img { height: 27px; } }

.nav { margin-left: auto; }
.nav-list { display: flex; gap: 4px; margin: 0; padding: 0; list-style: none; }
.nav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 44px;
  padding: 0 12px;
  border-radius: 999px;
  color: var(--ink-2);
  font-size: var(--fs-sm);
  font-weight: 500;
  text-decoration: none;
  transition: color var(--dur-fast) var(--ease-out), background-color var(--dur-fast) var(--ease-out);
}
.nav-link .icon { width: 14px; height: 14px; color: var(--muted); }
.nav-link[aria-current="page"] { color: var(--ink); font-weight: 600; }
.nav-link[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 12px; right: 12px; bottom: 6px;
  height: 2px;
  border-radius: 2px;
  background: var(--lime);
  box-shadow: 0 0 0 0.5px rgb(18 18 17 / 0.15);
}
@media (hover: hover) and (pointer: fine) {
  .nav-link:hover { background: rgb(18 18 17 / 0.05); color: var(--ink); }
}

.header-cta { flex: none; }

.menu-toggle {
  display: none;
  position: relative;
  width: 44px; height: 44px;
  margin-left: auto;
  margin-right: -10px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  -webkit-tap-highlight-color: transparent;
}
.menu-toggle .bar {
  position: absolute;
  left: 12px; right: 12px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform var(--dur) var(--ease-out);
}
.menu-toggle .bar:nth-child(1) { top: 17px; }
.menu-toggle .bar:nth-child(2) { top: 25px; }
.menu-toggle[aria-expanded="true"] .bar:nth-child(1) { transform: translateY(4px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] .bar:nth-child(2) { transform: translateY(-4px) rotate(-45deg); }

/* Six links + CTA need ~1040px; below that the menu button takes over. */
@media (max-width: 1079px) {
  .nav, .header-cta { display: none; }
  .menu-toggle { display: block; }
}
@media (min-width: 1080px) and (max-width: 1199px) {
  .nav-link { padding: 0 10px; }
  .header-inner { gap: var(--s-4); }
}

/* Mobile menu: a sheet under the header */
.mobile-menu {
  position: fixed;
  inset: var(--header-h) 0 0 0;
  z-index: 49;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: var(--s-5) var(--gutter) calc(var(--s-6) + env(safe-area-inset-bottom));
  background: var(--paper);
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity var(--dur) var(--ease-out), transform var(--dur) var(--ease-out);
}
.mobile-menu[hidden] { display: none; }
.mobile-menu.is-open { opacity: 1; transform: none; }
.mobile-menu__list { margin: 0; padding: 0; list-style: none; }
.mobile-menu__list li {
  border-bottom: 1px solid var(--line);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity var(--dur) var(--ease-out), transform var(--dur-slow) var(--ease-out);
  transition-delay: calc(var(--i, 0) * 35ms + 40ms);
}
.mobile-menu.is-open .mobile-menu__list li { opacity: 1; transform: none; }
.menu-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 60px;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.75rem;
  line-height: 1.1;
  text-decoration: none;
}
.menu-link .icon { width: 20px; height: 20px; color: var(--muted); }
.menu-link[aria-current="page"]::after {
  content: "";
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: 0 0 0 1px rgb(18 18 17 / 0.15) inset;
}
.mobile-menu__foot { display: grid; gap: var(--s-4); margin-top: var(--s-6); }
.mobile-menu__contact { display: grid; gap: 2px; color: var(--muted); font-size: var(--fs-sm); }
.mobile-menu__contact a { display: flex; align-items: center; min-height: 44px; color: var(--ink); text-decoration: none; }
.menu-open { overflow: hidden; }

/* Hero (home) ------------------------------------------------------------- */
.hero {
  position: relative;
  padding-block: clamp(48px, 7vw, 104px) clamp(64px, 8vw, 120px);
  overflow: clip;
}
.hero::before {
  /* faint grid, fades out — texture without decoration */
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgb(18 18 17 / 0.045) 1px, transparent 1px),
    linear-gradient(to bottom, rgb(18 18 17 / 0.045) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 70% 60% at 30% 20%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 30% 20%, #000 20%, transparent 75%);
  pointer-events: none;
}
.hero-grid {
  position: relative;
  display: grid;
  gap: clamp(48px, 6vw, 72px);
  align-items: center;
}
@media (min-width: 1024px) {
  .hero-grid { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); }
}
.hero-copy { display: grid; gap: var(--s-5); justify-items: start; }
.hero-copy .h1 { max-width: 12ch; font-size: clamp(2.625rem, 1.5rem + 4vw, 4.75rem); }
.hero-copy .actions { margin-top: var(--s-2); }

.hero-facts {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-5) var(--s-6);
  margin-top: var(--s-4);
  padding-top: var(--s-5);
  border-top: 1px solid var(--line);
}
.hero-facts div { display: grid; gap: 2px; }
.hero-facts dt { order: 2; color: var(--muted); font-size: var(--fs-xs); }
.hero-facts dd { order: 1; color: var(--ink); font-size: var(--fs-sm); font-weight: 600; }

/* Hero stage: a browser window and two phones, all real product screens */
.hero-stage {
  position: relative;
  aspect-ratio: 1 / 0.86;
  width: 100%;
}
.hero-stage::before {
  /* soft lime glow behind the devices */
  content: "";
  position: absolute;
  inset: 12% 8% 4% 18%;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgb(191 247 71 / 0.38), transparent);
  filter: blur(24px);
  pointer-events: none;
}
.hero-stage .frame--web {
  position: absolute;
  top: 0;
  right: 0;
  width: 90%;
}
.hero-stage .phone-wrap { position: absolute; }
.hero-stage .phone-wrap--a { left: 0; bottom: 0; width: 27%; }
.hero-stage .phone-wrap--b { right: 5%; bottom: 4%; width: 24%; }
@media (max-width: 1023px) {
  .hero-stage { max-width: 680px; }
}
@media (max-width: 639px) {
  .hero-stage { aspect-ratio: 1 / 0.92; }
  .hero-stage .frame--web { width: 96%; }
  .hero-stage .phone-wrap--a { width: 34%; }
  .hero-stage .phone-wrap--b { display: none; }
}

/* Caption under the hero devices: which projects are shown */
.stage-caption {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 20px;
  margin: var(--s-6) 0 0;
  padding: 0;
  list-style: none;
  color: var(--ink);
  font-size: var(--fs-xs);
  font-weight: 600;
}
.stage-caption li { display: inline-flex; align-items: center; gap: 8px; }
.stage-caption img { width: 24px; height: 24px; border-radius: 7px; box-shadow: 0 0 0 1px var(--line); }
.stage-caption span { color: var(--muted); font-weight: 500; }
.stage-caption span::before { content: "· "; }
@media (prefers-reduced-motion: no-preference) {
  .js .stage-caption { animation: rise 700ms var(--ease-out) 420ms both; }
}

/* Phone frame */
.phone {
  padding: 5px;
  border-radius: 26px;
  background: #121211;
  box-shadow: 0 2px 4px rgb(18 18 17 / 0.08), 0 30px 60px -18px rgb(18 18 17 / 0.45);
}
.phone__screen {
  overflow: hidden;
  aspect-ratio: 390 / 800;
  border-radius: 21px;
  background: #fff;
}
.phone__screen img { width: 100%; height: 100%; object-fit: cover; object-position: top; }

/* Load-in: devices settle into place, one after another */
@media (prefers-reduced-motion: no-preference) {
  .js .hero-stage > .frame--web,
  .js .hero-stage > .phone-wrap { animation: settle 900ms var(--ease-out) both; }
  .js .hero-stage > .phone-wrap--a { animation-delay: 140ms; }
  .js .hero-stage > .phone-wrap--b { animation-delay: 260ms; }
  .js .hero-copy > * { animation: rise 700ms var(--ease-out) both; }
  .js .hero-copy > :nth-child(2) { animation-delay: 60ms; }
  .js .hero-copy > :nth-child(3) { animation-delay: 120ms; }
  .js .hero-copy > :nth-child(4) { animation-delay: 180ms; }
  .js .hero-copy > :nth-child(5) { animation-delay: 240ms; }
}
@keyframes settle { from { opacity: 0; transform: translateY(24px) scale(0.98); } to { opacity: 1; transform: none; } }

/* Browser frame */
.frame {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
}
.frame__bar {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 34px;
  padding-inline: 12px;
  border-bottom: 1px solid var(--line);
  background: #f7f6f2;
}
.frame__bar i {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: #dedcd3;
}
.frame__url {
  margin-inline: auto;
  padding: 2px 12px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
  transform: translateX(-16px);
}
.frame img { width: 100%; }
.frame figcaption { display: none; }

/* Client logo wall (full colour) ------------------------------------------ */
.clients { padding-block: var(--s-7) var(--s-8); }
.clients__label { margin-bottom: var(--s-5); color: var(--muted); font-size: var(--fs-sm); text-align: center; }
.logo-wall {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}
@media (min-width: 640px) { .logo-wall { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1000px) { .logo-wall { grid-template-columns: repeat(5, 1fr); } }
.logo-wall li {
  display: grid;
  place-items: center;
  min-height: 104px;
  padding: var(--s-4);
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.client-logo { width: auto; max-width: 100%; height: var(--h, 30px); object-fit: contain; }

/* Product cards ----------------------------------------------------------- */
.product-grid {
  display: grid;
  gap: var(--s-5);
  margin: 0;
  padding: 0;
  list-style: none;
}
@media (min-width: 760px) { .product-grid { grid-template-columns: repeat(3, 1fr); } }

.card-link {
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  color: inherit;
  text-decoration: none;
  transition:
    transform var(--dur) var(--ease-out),
    box-shadow var(--dur) var(--ease-out),
    border-color var(--dur) var(--ease-out);
}
.card-link:active { transform: scale(0.99); }
@media (hover: hover) and (pointer: fine) {
  .card-link:hover {
    transform: translateY(-3px);
    border-color: var(--line-strong);
    box-shadow: var(--shadow);
  }
}

.product-card__media {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 10;
  background:
    radial-gradient(circle at 50% 120%, color-mix(in srgb, var(--accent) 22%, transparent), transparent 60%),
    color-mix(in srgb, var(--accent) 7%, var(--surface));
  border-bottom: 1px solid var(--line);
}
.product-card__media::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(color-mix(in srgb, var(--accent) 28%, transparent) 1px, transparent 1.2px);
  background-size: 18px 18px;
  mask-image: radial-gradient(circle at 50% 50%, #000 0, transparent 70%);
  -webkit-mask-image: radial-gradient(circle at 50% 50%, #000 0, transparent 70%);
  opacity: 0.6;
}
.product-card__body { display: grid; gap: var(--s-3); padding: var(--s-5); flex: 1; align-content: start; }
.product-card__body .link-arrow { margin-top: auto; padding-top: var(--s-2); }
.product-card__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  color: var(--muted);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* App marks */
.mark {
  position: relative;
  display: grid;
  place-items: center;
  width: var(--size, 76px);
  height: var(--size, 76px);
  border-radius: 24%;
  box-shadow: 0 1px 1px rgb(0 0 0 / 0.06), 0 10px 24px -10px rgb(0 0 0 / 0.35);
}
.mark img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.mark--churchly { background: #fff; }
.mark--churchly img { inset: 13%; width: 74%; height: 74%; }
.mark--keza { background: linear-gradient(180deg, #fbbf24, #f59e0b 55%, #ea8a05); }
.mark--keza::after {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 22%;
  border-radius: 24% 24% 0 0;
  background: linear-gradient(180deg, rgb(255 255 255 / 0.45), rgb(255 255 255 / 0.12));
}
.mark--farm { background: linear-gradient(180deg, #22a35a, #15803d); color: #fff; }
.mark--farm .icon { width: 56%; height: 56%; stroke-width: 1.5; }

.status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--sand);
  color: var(--ink-2);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  white-space: nowrap;
}
.status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--muted); }
.status--live::before { background: #16a34a; box-shadow: 0 0 0 3px rgb(22 163 74 / 0.15); }

/* Services list (home) ---------------------------------------------------- */
.service-list { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.service-row {
  display: grid;
  gap: var(--s-3) var(--s-6);
  padding: var(--s-6) var(--s-2);
  border-bottom: 1px solid var(--line);
  color: inherit;
  text-decoration: none;
  transition: background-color var(--dur) var(--ease-out);
}
@media (min-width: 900px) {
  .service-row { grid-template-columns: 64px minmax(0, 1fr) minmax(0, 1.1fr) 28px; align-items: start; }
}
.service-row__num { color: var(--muted); font-size: var(--fs-sm); font-variant-numeric: tabular-nums; padding-top: 6px; }
.service-row .h3 { font-size: clamp(1.5rem, 1.3rem + 0.8vw, 2rem); }
.service-row__arrow { color: var(--muted); padding-top: 8px; transition: transform var(--dur) var(--ease-out), color var(--dur) var(--ease-out); }
.service-row__arrow .icon { width: 22px; height: 22px; }
@media (max-width: 899px) { .service-row__arrow { display: none; } }
@media (hover: hover) and (pointer: fine) {
  .service-row:hover { background: var(--surface); }
  .service-row:hover .service-row__arrow { color: var(--ink); transform: translate(3px, -3px); }
}

.tags { display: flex; flex-wrap: wrap; gap: 6px; margin: var(--s-3) 0 0; padding: 0; list-style: none; }
.tags li {
  padding: 4px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink-2);
  font-size: var(--fs-xs);
  font-weight: 500;
}
.on-dark .tags li { background: transparent; border-color: var(--dark-line); color: var(--on-dark); }

/* Work / case studies ----------------------------------------------------- */
.work-grid { display: grid; gap: var(--s-6); }
@media (min-width: 900px) { .work-grid { grid-template-columns: 1fr 1fr; gap: var(--s-5); } }
.work-card { display: grid; gap: var(--s-4); align-content: start; }
.work-card__media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--sand);
}
.work-card__media img { width: 100%; height: 100%; object-fit: cover; object-position: left top; }
.work-card__meta { color: var(--muted); font-size: var(--fs-sm); }

.video-facade {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: #000;
}
.video-facade img { width: 100%; height: 100%; object-fit: cover; opacity: 0.92; transition: opacity var(--dur) var(--ease-out), transform var(--dur-slow) var(--ease-out); }
.video-facade__play {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
}
.video-facade__play span {
  display: grid;
  place-items: center;
  width: 72px; height: 72px;
  border-radius: 50%;
  background: var(--lime);
  color: var(--ink);
  box-shadow: 0 8px 28px -8px rgb(0 0 0 / 0.5);
  transition: transform var(--dur) var(--ease-out);
}
.video-facade__play .icon { width: 26px; height: 26px; margin-left: 3px; }
.video-facade:active .video-facade__play span { transform: scale(0.94); }
@media (hover: hover) and (pointer: fine) {
  .video-facade:hover img { opacity: 1; transform: scale(1.015); }
  .video-facade:hover .video-facade__play span { transform: scale(1.06); }
}
.video-embed { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* Stats ------------------------------------------------------------------- */
.stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--s-6) var(--s-5);
  margin: 0;
}
@media (min-width: 900px) { .stats { grid-template-columns: repeat(4, 1fr); } }
.stats div { display: grid; gap: var(--s-2); padding-top: var(--s-5); border-top: 1px solid var(--dark-line); }
.stats dt { order: 2; font-size: var(--fs-sm); }
.stats dd {
  order: 1;
  margin: 0;
  color: var(--lime);
  font-family: var(--font-display);
  font-size: var(--fs-stat);
  line-height: 1;
  font-variant-numeric: lining-nums;
}
.stats--light div { border-top-color: var(--line); }
.stats--light dd { color: var(--ink); }
.stats--light dt { color: var(--muted); }

/* Process ----------------------------------------------------------------- */
.steps { display: grid; gap: var(--s-6); margin: 0; padding: 0; list-style: none; counter-reset: step; }
@media (min-width: 900px) { .steps { grid-template-columns: repeat(3, 1fr); gap: var(--s-5); } }
.step {
  display: grid;
  gap: var(--s-3);
  align-content: start;
  padding-top: var(--s-5);
  border-top: 1px solid var(--line);
  counter-increment: step;
}
.step::before {
  content: counter(step, decimal-leading-zero);
  color: var(--muted);
  font-size: var(--fs-sm);
  font-variant-numeric: tabular-nums;
}
.on-dark .step { border-top-color: var(--dark-line); }

/* Split (text + image) ---------------------------------------------------- */
.split { display: grid; gap: clamp(40px, 6vw, 88px); align-items: center; }
@media (min-width: 900px) {
  .split { grid-template-columns: 1fr 1fr; }
  .split--reverse > :first-child { order: 2; }
}
.split__copy { display: grid; gap: var(--s-5); justify-items: start; }
.photo {
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--sand);
}
.photo img { width: 100%; height: 100%; object-fit: cover; }
.photo--portrait { aspect-ratio: 4 / 5; }
.photo--landscape { aspect-ratio: 3 / 2; }

.photo-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: var(--s-4); }
.photo-grid .photo:first-child { grid-row: span 2; aspect-ratio: auto; min-height: 100%; }
.photo-grid .photo { aspect-ratio: 1 / 1; }

.values { display: grid; gap: var(--s-5); margin: 0; padding: 0; list-style: none; }
@media (min-width: 640px) { .values { grid-template-columns: 1fr 1fr; } }
.values li { display: grid; gap: var(--s-2); padding-top: var(--s-4); border-top: 1px solid var(--line); }

/* FAQ --------------------------------------------------------------------- */
.faq { border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-5);
  min-height: 72px;
  padding-block: var(--s-4);
  color: var(--ink);
  font-size: clamp(1.0625rem, 1rem + 0.3vw, 1.25rem);
  font-weight: 600;
  line-height: 1.35;
  list-style: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 32px; height: 32px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  color: var(--ink);
  transition: transform var(--dur) var(--ease-out), background-color var(--dur) var(--ease-out), border-color var(--dur) var(--ease-out);
}
.faq-icon .icon { width: 16px; height: 16px; }
.faq-item[open] .faq-icon { transform: rotate(45deg); background: var(--lime); border-color: var(--lime); }
@media (hover: hover) and (pointer: fine) {
  .faq-item summary:hover .faq-icon { border-color: var(--ink); }
}
.faq-answer { padding: 0 56px var(--s-5) 0; max-width: 72ch; }
@media (max-width: 639px) { .faq-answer { padding-right: 0; } }

@supports (interpolate-size: allow-keywords) {
  .faq-item { interpolate-size: allow-keywords; }
  .faq-item::details-content {
    block-size: 0;
    overflow: hidden;
    transition: block-size var(--dur) var(--ease-out), content-visibility var(--dur) allow-discrete;
  }
  .faq-item[open]::details-content { block-size: auto; }
}

/* CTA band + footer ------------------------------------------------------- */
.cta-band { padding-block: clamp(72px, 9vw, 120px); border-bottom: 1px solid var(--dark-line); }
.cta-band__inner { display: grid; gap: var(--s-6); align-items: end; }
@media (min-width: 900px) { .cta-band__inner { grid-template-columns: 1.4fr 1fr; } }
.cta-band .h2 { font-size: clamp(2.25rem, 1.5rem + 3.2vw, 4.25rem); max-width: 14ch; }
.cta-band__side { display: grid; gap: var(--s-5); justify-items: start; }
@media (min-width: 900px) { .cta-band__side { justify-items: end; text-align: right; } }
.cta-band__mail { color: var(--on-dark); font-size: var(--fs-lead); text-decoration: none; border-bottom: 1px solid var(--dark-line); padding-bottom: 2px; transition: border-color var(--dur) var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .cta-band__mail:hover { border-color: var(--lime); } }

.site-footer { padding-block: var(--s-8) calc(var(--s-6) + env(safe-area-inset-bottom)); }
.footer-grid { display: grid; gap: var(--s-7) var(--s-5); grid-template-columns: repeat(2, minmax(0, 1fr)); }
.footer-brand { grid-column: 1 / -1; display: grid; gap: var(--s-4); align-content: start; max-width: 340px; }
@media (min-width: 1000px) {
  .footer-grid { grid-template-columns: 1.6fr repeat(4, minmax(0, 1fr)); }
  .footer-brand { grid-column: auto; }
}
.footer-brand img { height: 30px; width: auto; }
.footer-col h2 {
  margin-bottom: var(--s-4);
  color: var(--on-dark);
  font-size: var(--fs-sm);
  font-weight: 600;
}
.footer-col ul { display: grid; gap: 2px; margin: 0; padding: 0; list-style: none; }
.footer-col a, .footer-col address a {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 36px;
  color: var(--on-dark-muted);
  font-size: var(--fs-sm);
  text-decoration: none;
  transition: color var(--dur-fast) var(--ease-out);
}
.footer-col address { font-style: normal; font-size: var(--fs-sm); display: grid; gap: 2px; }
.footer-col address span { padding-top: 8px; line-height: 1.5; }
.footer-col .icon { width: 13px; height: 13px; }
@media (hover: hover) and (pointer: fine) { .footer-col a:hover { color: var(--on-dark); } }

.socials { display: flex; gap: 8px; margin: 0; padding: 0; list-style: none; }
.socials a {
  display: grid;
  place-items: center;
  width: 44px; height: 44px;
  border: 1px solid var(--dark-line);
  border-radius: 50%;
  color: var(--on-dark);
  transition: background-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out);
}
.socials .icon { width: 17px; height: 17px; }
@media (hover: hover) and (pointer: fine) {
  .socials a:hover { background: var(--lime); border-color: var(--lime); color: var(--ink); }
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--s-3);
  margin-top: var(--s-8);
  padding-top: var(--s-5);
  border-top: 1px solid var(--dark-line);
  font-size: var(--fs-xs);
}

/* Inner-page hero --------------------------------------------------------- */
.page-hero { padding-block: clamp(48px, 7vw, 104px) clamp(40px, 5vw, 72px); }
.page-hero__inner { display: grid; gap: var(--s-5); justify-items: start; max-width: 900px; }
.page-hero .h1 { font-size: clamp(2.5rem, 1.6rem + 3.8vw, 4.5rem); }

.chip-nav { display: flex; flex-wrap: wrap; gap: 8px; margin: var(--s-2) 0 0; padding: 0; list-style: none; }
.chip-nav a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 16px 0 8px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
  font-size: var(--fs-sm);
  font-weight: 600;
  text-decoration: none;
  transition: border-color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.chip-nav a:active { transform: scale(0.97); }
.chip-nav .mark { --size: 28px; border-radius: 30%; box-shadow: none; }
@media (hover: hover) and (pointer: fine) { .chip-nav a:hover { border-color: var(--ink); } }

/* Product detail ---------------------------------------------------------- */
.product {
  display: grid;
  gap: clamp(40px, 5vw, 72px);
  padding-block: var(--section);
  border-top: 1px solid var(--line);
}
@media (min-width: 1024px) {
  .product { grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr); align-items: start; }
  .product--flip > .product__visual { order: -1; }
  .product__visual { position: sticky; top: calc(var(--header-h) + 32px); }
}
.product__copy { display: grid; gap: var(--s-5); justify-items: start; }
.product__head { display: flex; align-items: center; gap: var(--s-4); }
.product__head .mark { --size: 56px; }
.product__name { color: var(--ink); font-size: var(--fs-h3); font-weight: 600; line-height: 1.2; }
.product__kind { color: var(--muted); font-size: var(--fs-sm); }

.feature-list { display: grid; gap: var(--s-3) var(--s-5); margin: 0; padding: 0; list-style: none; width: 100%; }
@media (min-width: 640px) { .feature-list { grid-template-columns: 1fr 1fr; } }
.feature-list li { display: grid; grid-template-columns: 22px 1fr; gap: 10px; align-items: start; color: var(--ink-2); font-size: var(--fs-sm); line-height: 1.5; }
.feature-list .icon { width: 18px; height: 18px; margin-top: 2px; color: var(--success); stroke-width: 2.25; }

.spec { display: grid; gap: 0; margin: 0; width: 100%; border-top: 1px solid var(--line); }
.spec div { display: grid; grid-template-columns: 140px 1fr; gap: var(--s-4); padding-block: var(--s-3); border-bottom: 1px solid var(--line); font-size: var(--fs-sm); }
.spec dt { color: var(--muted); }
.spec dd { margin: 0; color: var(--ink-2); }
@media (max-width: 479px) { .spec div { grid-template-columns: 1fr; gap: 0; } }

.module-panel {
  display: grid;
  gap: var(--s-5);
  padding: clamp(24px, 4vw, 40px);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 100% 0%, color-mix(in srgb, var(--farm) 14%, transparent), transparent 55%),
    var(--surface);
  box-shadow: var(--shadow);
}
.module-panel__head { display: flex; align-items: center; gap: var(--s-4); }
.module-panel__head .mark { --size: 52px; }
.module-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--s-3); margin: 0; padding: 0; list-style: none; }
@media (min-width: 640px) { .module-grid { grid-template-columns: repeat(3, 1fr); } }
.module-grid li {
  display: grid;
  gap: var(--s-3);
  padding: var(--s-4);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  color: var(--ink);
  font-size: var(--fs-sm);
  font-weight: 600;
  line-height: 1.3;
}
.module-grid .icon { width: 22px; height: 22px; color: var(--farm); }

/* Service detail ---------------------------------------------------------- */
.service-detail {
  display: grid;
  gap: var(--s-6);
  padding-block: clamp(56px, 7vw, 96px);
  border-top: 1px solid var(--line);
}
@media (min-width: 900px) { .service-detail { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: var(--s-8); } }
.service-detail__head { display: grid; gap: var(--s-4); align-content: start; }
.service-detail__num { color: var(--muted); font-size: var(--fs-sm); font-variant-numeric: tabular-nums; }
.service-detail__body { display: grid; gap: var(--s-5); align-content: start; }
.service-detail__body h3 { color: var(--ink); font-size: var(--fs-sm); font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; }

.stack-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; margin: 0; padding: 0; list-style: none; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--line); }
@media (min-width: 640px) { .stack-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1000px) { .stack-grid { grid-template-columns: repeat(4, 1fr); } }
.stack-grid li { display: grid; gap: 2px; padding: var(--s-5); background: var(--surface); }
.stack-grid strong { color: var(--ink); font-weight: 600; }
.stack-grid span { color: var(--muted); font-size: var(--fs-xs); }

.engage { display: grid; gap: var(--s-4); margin: 0; padding: 0; list-style: none; }
@media (min-width: 900px) { .engage { grid-template-columns: repeat(3, 1fr); } }
.engage li { display: grid; gap: var(--s-3); align-content: start; padding: var(--s-6); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); }

/* Contact ----------------------------------------------------------------- */
.contact-layout { display: grid; gap: var(--s-7); align-items: start; }
@media (min-width: 1000px) { .contact-layout { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: var(--s-8); } }

.form-card {
  position: relative;
  padding: clamp(20px, 4vw, 40px);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.form { display: grid; gap: var(--s-5); }
.form-row { display: grid; gap: var(--s-5); }
@media (min-width: 640px) { .form-row { grid-template-columns: 1fr 1fr; } }

.field { display: grid; gap: var(--s-2); }
.field label { color: var(--ink); font-size: var(--fs-sm); font-weight: 600; }
.field .optional { color: var(--muted); font-weight: 400; }
.input {
  width: 100%;
  min-height: 52px;
  padding: 13px 16px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: var(--surface);
  color: var(--ink);
  font-size: 1rem; /* ≥16px stops iOS focus zoom */
  line-height: 1.5;
  transition: border-color var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
  -webkit-appearance: none;
  appearance: none;
}
.input::placeholder { color: #9a988f; opacity: 1; }
.input:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 4px rgb(191 247 71 / 0.55); }
@media (hover: hover) and (pointer: fine) { .input:hover:not(:focus) { border-color: #b9b6a9; } }
textarea.input { min-height: 160px; resize: vertical; }
select.input {
  padding-right: 44px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23121211' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 18px;
  cursor: pointer;
}
.input[aria-invalid="true"] { border-color: var(--danger); }
.input[aria-invalid="true"]:focus { box-shadow: 0 0 0 4px rgb(180 35 24 / 0.14); }
.field-error {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--danger);
  font-size: var(--fs-xs);
  font-weight: 500;
}
.field-error .icon { width: 14px; height: 14px; }
.field-error[hidden] { display: none; }

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

.form-foot { display: grid; gap: var(--s-4); }
.form-note { color: var(--muted); font-size: var(--fs-xs); }
.form-note a { color: var(--ink-2); }

.btn .spinner {
  display: none;
  width: 18px; height: 18px;
  border: 2px solid rgb(255 255 255 / 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 700ms linear infinite;
}
.btn[aria-busy="true"] .spinner { display: block; }
.btn[aria-busy="true"] .icon { display: none; }
@keyframes spin { to { transform: rotate(360deg); } }

.alert {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 10px;
  padding: 14px 16px;
  border: 1px solid #fecdca;
  border-radius: 12px;
  background: var(--danger-bg);
  color: #7a271a;
  font-size: var(--fs-sm);
  line-height: 1.5;
}
.alert .icon { width: 20px; height: 20px; color: var(--danger); }
.alert a { color: inherit; font-weight: 600; }
.form-status:empty { display: none; }

.form-success { display: grid; gap: var(--s-4); justify-items: start; padding-block: var(--s-6); }
.form-success[hidden] { display: none; }
.form-success:focus { outline: none; }
.success-icon {
  display: grid;
  place-items: center;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--lime);
  color: var(--ink);
}
.success-icon .icon { width: 26px; height: 26px; stroke-width: 2.5; }
.form-success.is-in .success-icon { animation: pop 420ms var(--ease-out) both; }
.form-success.is-in > :not(.success-icon) { animation: rise 420ms var(--ease-out) both; animation-delay: 60ms; }
@keyframes pop { from { transform: scale(0.6); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes rise { from { transform: translateY(8px); opacity: 0; } to { transform: none; opacity: 1; } }

.contact-aside { display: grid; gap: var(--s-6); align-content: start; }
.contact-list { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.contact-list li { display: grid; grid-template-columns: 40px 1fr; gap: var(--s-4); align-items: start; padding-block: var(--s-4); border-bottom: 1px solid var(--line); }
.contact-list .icon-wrap { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: var(--sand); color: var(--ink); }
.contact-list .icon { width: 18px; height: 18px; }
.contact-list strong { display: block; color: var(--ink); font-size: var(--fs-sm); font-weight: 600; }
.contact-list a, .contact-list span { color: var(--text); font-size: var(--fs-sm); }
.contact-list a { text-decoration: none; }
@media (hover: hover) and (pointer: fine) { .contact-list a:hover { text-decoration: underline; } }

.note-card { display: grid; gap: var(--s-3); padding: var(--s-5); border-radius: var(--radius); background: var(--sand); font-size: var(--fs-sm); }
.socials--light a { border-color: var(--line-strong); color: var(--ink); }
@media (hover: hover) and (pointer: fine) { .socials--light a:hover { background: var(--ink); border-color: var(--ink); color: #fff; } }

/* Legal ------------------------------------------------------------------- */
.legal { display: grid; gap: var(--s-7); padding-bottom: var(--section); }
@media (min-width: 1000px) { .legal { grid-template-columns: 240px minmax(0, 1fr); gap: var(--s-8); } }
.toc { align-self: start; font-size: var(--fs-sm); }
@media (min-width: 1000px) { .toc { position: sticky; top: calc(var(--header-h) + 32px); } }
.toc h2 { margin-bottom: var(--s-3); color: var(--ink); font-size: var(--fs-xs); font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; }
.toc ol { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; border-left: 1px solid var(--line); }
.toc a { display: block; padding: 6px 0 6px 14px; margin-left: -1px; border-left: 1px solid transparent; color: var(--muted); text-decoration: none; line-height: 1.4; transition: color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out); }
.toc a[aria-current="true"] { color: var(--ink); border-left-color: var(--ink); }
@media (hover: hover) and (pointer: fine) { .toc a:hover { color: var(--ink); } }
@media (max-width: 999px) {
  .toc { padding: var(--s-5); border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
}

.prose { max-width: 70ch; color: var(--text); }
.prose > * + * { margin-top: 1em; }
.prose h2 {
  margin-top: 2.4em;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 1.3rem + 0.8vw, 1.875rem);
  font-weight: 400;
  line-height: 1.2;
}
.prose h2:first-child { margin-top: 0; }
.prose h3 { margin-top: 1.6em; color: var(--ink); font-size: var(--fs-base); font-weight: 600; }
.prose ul, .prose ol { padding-left: 1.25em; }
.prose li + li { margin-top: 0.4em; }
.prose li::marker { color: var(--muted); }
.prose a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--line-strong); }
@media (hover: hover) and (pointer: fine) { .prose a:hover { text-decoration-color: var(--ink); } }
.prose strong { color: var(--ink); }
.prose .callout { padding: var(--s-5); border-radius: var(--radius); background: var(--sand); }

/* 404 --------------------------------------------------------------------- */
.not-found { min-height: calc(100svh - var(--header-h)); display: grid; align-items: center; padding-block: var(--s-8); }
.not-found__code { color: var(--muted); font-size: var(--fs-sm); font-variant-numeric: tabular-nums; }

/* Motion: reveal on scroll (JS adds .js to <html>) ------------------------ */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity var(--dur-slow) var(--ease-out), transform var(--dur-slow) var(--ease-out);
  transition-delay: var(--d, 0ms);
}
.js [data-reveal].is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 1ms !important;
    transition-delay: 0ms !important;
  }
  .js [data-reveal] { opacity: 1; transform: none; }
  .btn .spinner { animation: spin 1.4s linear infinite !important; }
}
.section-head--split > .section-head { margin: 0; }
.chip-nav a:not(:has(.mark)) { padding-left: 16px; }
@media (max-width: 999px) { .footer-col--contact { grid-column: 1 / -1; } }
.footer-col address a { overflow-wrap: anywhere; }
@media (max-width: 759px) { .product-card__media { aspect-ratio: 2 / 1; } }

/* Portfolio ---------------------------------------------------------------- */
.brand-logo { width: auto; max-width: 100%; height: var(--h, 28px); object-fit: contain; }
.brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  font-size: calc(var(--h, 44px) * 0.42);
  font-weight: 700;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.brand-lockup .brand-logo { height: var(--h); }
.brand-lockup .mark { --size: var(--h, 44px); box-shadow: none; }
.mark--tamid { background: linear-gradient(180deg, #2b2b29, #121211); color: #fff; font-weight: 700; font-size: calc(var(--size, 76px) * 0.5); line-height: 1; }

.kind {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
  white-space: nowrap;
}
.kind--product { background: rgb(191 247 71 / 0.45); color: #2a3d00; }
.kind--client { background: var(--sand); color: var(--ink-2); }
.status--dev::before { background: #f59e0b; box-shadow: 0 0 0 3px rgb(245 158 11 / 0.18); }

/* Homepage: compact, logo-first cards */
.pf-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-3); margin: 0; padding: 0; list-style: none; }
@media (min-width: 760px) { .pf-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-4); } }
@media (min-width: 1100px) { .pf-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.pf-grid > li { display: flex; }
.pf-card {
  display: flex;
  flex-direction: column;
  width: 100%;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  color: inherit;
  text-decoration: none;
  transition: transform var(--dur) var(--ease-out), box-shadow var(--dur) var(--ease-out), border-color var(--dur) var(--ease-out);
}
.pf-card:active { transform: scale(0.985); }
@media (hover: hover) and (pointer: fine) {
  .pf-card:hover { transform: translateY(-3px); border-color: var(--line-strong); box-shadow: var(--shadow); }
  .pf-card:hover .pf-card__plate .brand-logo,
  .pf-card:hover .pf-card__plate .brand-lockup { transform: scale(1.04); }
}
.pf-card__plate {
  display: grid;
  place-items: center;
  height: clamp(96px, 12vw, 132px);
  padding: var(--s-4) var(--s-5);
  border-bottom: 1px solid var(--line);
  background: radial-gradient(circle at 50% 0%, #ffffff 0%, #f7f6f1 100%);
}
.pf-card__plate .brand-logo,
.pf-card__plate .brand-lockup { max-width: 86%; transition: transform var(--dur-slow) var(--ease-out); }
@media (max-width: 759px) {
  .pf-card__plate .brand-logo { height: calc(var(--h) * 0.82); }
  .pf-card__plate .brand-lockup { --h: 36px !important; font-size: 14px; }
}
.pf-card__body { display: grid; gap: 4px; align-content: start; padding: var(--s-4); flex: 1; }
.pf-card__name { color: var(--ink); font-size: var(--fs-sm); font-weight: 600; line-height: 1.3; }
.pf-card__cat { color: var(--muted); font-size: var(--fs-xs); line-height: 1.4; }
.pf-card__meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: var(--s-2); }
.pf-card__meta .status { padding: 3px 9px; font-size: 12px; }

/* Portfolio page: filters + rich cards */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: var(--s-6); }
.filter {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
  font-size: var(--fs-sm);
  font-weight: 600;
  transition: background-color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
  -webkit-tap-highlight-color: transparent;
}
.filter:active { transform: scale(0.97); }
.filter__count { min-width: 22px; padding: 1px 7px; border-radius: 999px; background: var(--sand); color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.filter[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.filter[aria-pressed="true"] .filter__count { background: rgb(255 255 255 / 0.16); color: #fff; }
@media (hover: hover) and (pointer: fine) { .filter:hover:not([aria-pressed="true"]) { border-color: var(--ink); } }

.project-grid { display: grid; gap: var(--s-5); }
@media (min-width: 800px) { .project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1200px) { .project-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.project {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  scroll-margin-top: calc(var(--header-h) + 24px);
}
.project[hidden] { display: none; }
.project.is-entering { animation: rise 420ms var(--ease-out) both; }
.project:target { border-color: var(--ink); box-shadow: 0 0 0 3px rgb(191 247 71 / 0.7); }
.project__media { position: relative; aspect-ratio: 16 / 10; overflow: hidden; border-bottom: 1px solid var(--line); background: var(--sand); }
.project__shot { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.project__badge {
  position: absolute;
  left: 12px;
  bottom: 12px;
  display: inline-flex;
  align-items: center;
  max-width: calc(100% - 24px);
  padding: 8px 12px;
  border-radius: 12px;
  background: rgb(255 255 255 / 0.96);
  box-shadow: var(--shadow);
}
.project__badge .brand-lockup { font-size: 14px; gap: 8px; }
.project__placeholder {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(color-mix(in srgb, var(--ink) 9%, transparent) 1px, transparent 1.2px) 0 0 / 18px 18px,
    radial-gradient(circle at 50% 40%, #ffffff, #f3f2ec 75%);
}
.project__body { display: grid; gap: var(--s-2); align-content: start; padding: var(--s-5); flex: 1; }
.project__body .link-arrow { margin-top: var(--s-2); justify-self: start; }
.project__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: var(--s-1); }
.project__meta .status { padding: 3px 9px; font-size: 12px; }
.project__cat { color: var(--muted); font-size: var(--fs-sm); }
.tags .tag--note { border-style: dashed; color: var(--muted); }

/* Products: coming-soon cards + Farm RMS screens */
.soon-grid { display: grid; gap: var(--s-5); }
@media (min-width: 800px) { .soon-grid { grid-template-columns: 1fr 1fr; } }
.soon-card { display: grid; gap: var(--s-4); align-content: start; padding: clamp(24px, 4vw, 36px); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); }
.soon-card__logo { display: flex; align-items: center; min-height: 56px; }
.screens { position: relative; padding-bottom: 18%; }
.screens .frame--small { position: absolute; right: -4%; bottom: 0; width: 52%; }
@media (max-width: 639px) { .screens { padding-bottom: 0; } .screens .frame--small { display: none; } }
.mark--img { background: #fff; }
.mark--round { border-radius: 50%; box-shadow: 0 1px 1px rgb(0 0 0 / 0.06), 0 10px 24px -10px rgb(0 0 0 / 0.35); }
@media (min-width: 1024px) { .product--stack { grid-template-columns: 1fr; } }
/* Keep the eyebrow dot on the first line when the label wraps */
.eyebrow { align-items: flex-start; }
.eyebrow::before { flex: none; margin-top: 0.42em; }
.nowrap { white-space: nowrap; }
