/* ==========================================================================
   AN Services INC — shared stylesheet
   --------------------------------------------------------------------------
   Brand colors were sampled from the approved logo artwork
   (assets/brand/an-services-logo-concept.png): purple #45358D, green #14BB76.
   Other values are derived shades/neutrals. See README for the full table.

   Typography
   - Display: Nunito 800/900 — rounded terminals echo the "Services" wordmark.
   - Text/UI: Figtree — open-licence geometric sans compatible with Avenir.
   - Avenir LT Std is the reference face but no licensed files were supplied.
     To switch, add @font-face rules for licensed files in assets/fonts/ and
     put "Avenir LT Std" first in --font-body / --font-display.
   ========================================================================== */

:root {
  /* Brand palette */
  --purple-950: #1D1640;
  --purple-900: #2A2163;
  --purple-700: #45358D; /* logo purple */
  --purple-500: #6E5FB8;
  --purple-200: #D9D4EF;
  --purple-100: #EEEBF8;
  --green-500: #14BB76;  /* logo green */
  --green-600: #10A468;
  --green-700: #0B7A4D;  /* green for text on light backgrounds */
  --green-300: #72E2B1;  /* green for text on dark backgrounds */
  --green-100: #DCF5E9;
  --graypurple-500: #8B85A3;
  --graypurple-700: #5C5675;
  --mint-50: #F1F8F4;
  --ink: #1F1936;
  --white: #FFFFFF;

  /* Semantic tokens */
  --color-primary: var(--purple-700);
  --color-primary-strong: var(--purple-900);
  --color-accent: var(--green-500);
  --color-secondary: var(--graypurple-500);
  --color-background: var(--white);
  --color-surface: var(--white);
  --color-surface-alt: var(--mint-50);
  --color-text: var(--ink);
  --color-muted: var(--graypurple-700);
  --color-border: #E3E0EC;
  --color-success: var(--green-700);
  --color-error: #B42318;
  --color-focus: var(--green-700);

  /* Type */
  --font-display: "Nunito", "Avenir LT Std", "Avenir Next", Avenir, "Segoe UI", system-ui, sans-serif;
  --font-body: "Figtree", "Avenir LT Std", "Avenir Next", Avenir, "Segoe UI", system-ui, sans-serif;
  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: clamp(1.18rem, 1.1rem + 0.35vw, 1.35rem);
  --step-2: clamp(1.4rem, 1.22rem + 0.8vw, 1.8rem);
  --step-3: clamp(1.75rem, 1.4rem + 1.6vw, 2.55rem);
  --step-4: clamp(2.2rem, 1.55rem + 3vw, 3.7rem);
  --step-5: clamp(2.7rem, 1.6rem + 5.2vw, 5.6rem);

  /* Space */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4rem;
  --section: clamp(3.25rem, 1.75rem + 6vw, 7.5rem);
  --gutter: clamp(1rem, 0.5rem + 2.5vw, 2.5rem);
  --container: 77.5rem;
  --measure: 38rem;

  /* Shape — the "door" is the green counter inside the logo's A:
     generous rounded top, nearly square base. */
  --radius-sm: 6px;
  --radius: 12px;
  --radius-lg: 20px;
  --door: 999px 999px var(--radius-sm) var(--radius-sm);
  --door-card: 28px 28px var(--radius-sm) var(--radius-sm);
  --door-btn: 16px 16px 6px 6px;

  --shadow-sm: 0 1px 2px rgba(31, 25, 54, 0.06), 0 2px 8px rgba(31, 25, 54, 0.05);
  --shadow: 0 2px 4px rgba(42, 33, 99, 0.06), 0 12px 32px -8px rgba(42, 33, 99, 0.18);
  --shadow-lg: 0 4px 8px rgba(42, 33, 99, 0.08), 0 32px 64px -16px rgba(42, 33, 99, 0.32);

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

/* --------------------------------------------------------------------------
   Base
   -------------------------------------------------------------------------- */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: 6rem;
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--color-background);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.6;
  font-feature-settings: "kern", "liga";
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

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

h1, h2, h3, h4 {
  margin: 0 0 var(--space-4);
  font-family: var(--font-display);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.015em;
  color: var(--color-primary);
  text-wrap: balance;
}

h1 { font-size: var(--step-4); font-weight: 900; letter-spacing: -0.025em; line-height: 1.02; }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-1); line-height: 1.25; letter-spacing: -0.005em; }
h4 { font-size: var(--step-0); line-height: 1.3; letter-spacing: 0; }

p { margin: 0 0 var(--space-4); text-wrap: pretty; }
ul, ol { margin: 0 0 var(--space-4); padding-left: 1.25rem; }
li + li { margin-top: var(--space-2); }

a { color: var(--color-primary); text-decoration-thickness: 1.5px; text-underline-offset: 0.18em; }
a:hover { color: var(--purple-900); text-decoration-color: var(--color-accent); }

strong { font-weight: 700; }

:focus-visible {
  outline: 3px solid var(--color-focus);
  outline-offset: 3px;
  border-radius: 4px;
}

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

.visually-hidden {
  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: absolute;
  left: var(--space-4);
  top: -100px;
  z-index: 100;
  padding: var(--space-3) var(--space-4);
  background: var(--purple-900);
  color: var(--white);
  border-radius: var(--radius-sm);
  font-weight: 600;
}
.skip-link:focus { top: var(--space-4); color: var(--white); }

/* --------------------------------------------------------------------------
   Layout
   Surfaces have one job each: white is the default, mint alternates content
   sections, lavender is reserved for process steps, and dark purple carries
   one statement band on the homepage.
   -------------------------------------------------------------------------- */

.container {
  width: 100%;
  max-width: calc(var(--container) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: var(--section); }
.section--tight { padding-block: calc(var(--section) * 0.6); }
.section--mint { background: var(--color-surface-alt); }
.section--lavender { background: var(--purple-100); }
.section:not(.section--mint):not(.section--lavender):not(.section--dark) + .section:not(.section--mint):not(.section--lavender):not(.section--dark) { padding-top: 0; }

.section--dark {
  background: var(--purple-900);
  color: #E9E6F6;
}
.section--dark h2, .section--dark h3, .section--dark h4 { color: var(--white); }
.section--dark a:not(.btn) { color: var(--green-300); }
.section--dark :focus-visible { outline-color: var(--green-300); }

.section--rule { border-top: 1px solid var(--color-border); }
.section--flush-top { padding-top: 0; }

/* Section heads: "stack" (intro under the heading, optional link at the row's end)
   or "split" (a short intro beside the heading, sharing its baseline). */
.section-head {
  display: grid;
  gap: var(--space-4) var(--space-7);
  margin-bottom: clamp(2rem, 1.5rem + 2vw, 3.25rem);
}
.section-head > *, .section-head__text > * { margin: 0; }
.section-head__text { display: grid; gap: var(--space-3); max-width: 46rem; }
.section-head p { max-width: var(--measure); color: var(--color-muted); font-size: var(--step-1); line-height: 1.5; }
.section-head__link { justify-self: start; white-space: nowrap; }
@media (min-width: 760px) {
  .section-head--stack:has(.section-head__link) { grid-template-columns: minmax(0, 1fr) auto; align-items: end; }
  .section-head--stack .section-head__link { padding-bottom: 0.2rem; }
}
@media (min-width: 900px) {
  .section-head--split { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: last baseline; }
}

.lead { font-size: var(--step-1); line-height: 1.55; color: var(--color-muted); max-width: var(--measure); }
.prose { max-width: 42rem; }
.prose > :last-child { margin-bottom: 0; }

.stack > * + * { margin-top: var(--space-4); }

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

.btn {
  --btn-bg: var(--color-primary);
  --btn-fg: var(--white);
  --btn-border: var(--btn-bg);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  min-height: 3rem;
  padding: 0.75rem 1.4rem;
  border: 2px solid var(--btn-border);
  border-radius: var(--door-btn);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.005em;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s var(--ease-out), box-shadow 0.18s ease;
}
.btn:hover { --btn-bg: var(--purple-900); color: var(--btn-fg); text-decoration: none; transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.btn:active { transform: translateY(1px); box-shadow: none; }
.btn:disabled, .btn[aria-disabled="true"] { opacity: 0.5; cursor: not-allowed; transform: none; box-shadow: none; }

.btn--secondary { --btn-bg: var(--green-500); --btn-fg: var(--ink); }
.btn--secondary:hover { --btn-bg: var(--green-600); }

.btn--tertiary { --btn-bg: transparent; --btn-fg: var(--color-primary); --btn-border: var(--purple-200); }
.btn--tertiary:hover { --btn-bg: var(--purple-100); --btn-fg: var(--purple-900); --btn-border: var(--purple-700); }

.btn--on-dark.btn--tertiary { --btn-fg: var(--white); --btn-border: rgba(255, 255, 255, 0.45); }
.btn--on-dark.btn--tertiary:hover { --btn-bg: rgba(255, 255, 255, 0.1); --btn-fg: var(--white); --btn-border: var(--white); }
.btn--on-dark:focus-visible { outline-color: var(--green-300); }

.btn--small { min-height: 2.5rem; padding: 0.5rem 1rem; font-size: 0.9375rem; }

.btn-row { display: flex; flex-wrap: wrap; gap: var(--space-3); align-items: center; }

/* Door button: a small doorway drawn in the text color whose door swings open
   on hover or focus. Used for the main "Start a project" actions only. */
.btn--door { gap: 0.6em; }
.btn__door {
  position: relative;
  width: 0.72em;
  height: 0.88em;
  flex-shrink: 0;
  border-radius: 0.36em 0.36em 0.08em 0.08em;
  box-shadow: inset 0 0 0 1.5px currentColor;
  perspective: 2.4em;
}
.btn__door::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: currentColor;
  transform-origin: 0 50%;
  transition: transform 0.4s var(--ease-out);
}
.btn--door:hover .btn__door::before, .btn--door:focus-visible .btn__door::before { transform: rotateY(-70deg); }

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  font-weight: 700;
  text-decoration: none;
  color: var(--color-primary);
}
.text-link svg { width: 1.1em; height: 1.1em; transition: transform 0.2s var(--ease-out); }
.text-link:hover { text-decoration: underline; text-decoration-color: var(--color-accent); }
.text-link:hover svg { transform: translateX(3px); }

/* --------------------------------------------------------------------------
   Header & navigation
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.site-header.is-scrolled { border-bottom-color: var(--color-border); box-shadow: 0 6px 20px -16px rgba(42, 33, 99, 0.4); }

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-5);
  min-height: 4.75rem;
}

.brand { display: inline-flex; flex-shrink: 0; border-radius: 4px; }
.brand img { height: 36px; width: auto; }

.nav-toggle {
  display: none;
  align-items: center;
  gap: 0.5rem;
  min-height: 2.75rem;
  padding: 0.5rem 0.9rem;
  border: 2px solid var(--purple-200);
  border-radius: var(--door-btn);
  background: var(--white);
  color: var(--color-primary);
  font: 700 0.9375rem/1 var(--font-body);
  cursor: pointer;
}
.nav-toggle__bars { position: relative; width: 18px; height: 12px; }
.nav-toggle__bars::before, .nav-toggle__bars::after, .nav-toggle__bars span {
  content: "";
  position: absolute;
  left: 0; right: 0;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 0.25s var(--ease-out), opacity 0.2s ease;
}
.nav-toggle__bars::before { top: 0; }
.nav-toggle__bars span { top: 5px; }
.nav-toggle__bars::after { top: 10px; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars::before { transform: translateY(5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars::after { transform: translateY(-5px) rotate(-45deg); }

.site-nav { display: flex; align-items: center; gap: var(--space-5); }
.nav-list { display: flex; align-items: center; gap: var(--space-1); margin: 0; padding: 0; list-style: none; }
.nav-list > li { margin: 0; position: relative; }

.nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  padding: 0.5rem 0.85rem;
  border-radius: var(--radius-sm);
  color: var(--ink);
  font-weight: 600;
  font-size: 0.98rem;
  text-decoration: none;
}
.nav-link:hover { color: var(--color-primary); background: var(--purple-100); }
.nav-link[aria-current="page"], .nav-link.is-active { color: var(--color-primary); }
.nav-link[aria-current="page"]::after, .nav-link.is-active::after {
  content: "";
  width: 7px; height: 7px;
  margin-left: 0.45rem;
  border-radius: 4px 4px 1.5px 1.5px;
  background: var(--color-accent);
}

.has-submenu { display: flex; align-items: center; }
.has-submenu > .nav-link { padding-right: 0.3rem; }
.submenu-toggle {
  display: none;
  width: 2rem; height: 2.75rem;
  padding: 0;
  border: 0;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--ink);
  cursor: pointer;
}
.submenu-toggle svg { width: 16px; height: 16px; margin: auto; transition: transform 0.2s ease; }
.submenu-toggle:hover { color: var(--color-primary); background: var(--purple-100); }
.submenu-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
.js .submenu-toggle { display: inline-flex; }

.submenu {
  position: absolute;
  top: calc(100% + 0.5rem);
  left: -0.5rem;
  width: min(36rem, 90vw);
  padding: var(--space-4);
  margin: 0;
  list-style: none;
  display: none;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-1);
  background: var(--white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}
.submenu li { margin: 0; }
.submenu a {
  display: block;
  padding: 0.7rem 0.85rem;
  border-radius: var(--radius);
  color: var(--ink);
  text-decoration: none;
  line-height: 1.35;
}
.submenu a strong { display: block; color: var(--color-primary); font-size: 0.98rem; }
.submenu a span { display: block; color: var(--color-muted); font-size: 0.875rem; margin-top: 0.15rem; }
.submenu a:hover { background: var(--mint-50); }
.submenu .submenu__all { grid-column: 1 / -1; border-top: 1px solid var(--color-border); margin-top: var(--space-2); padding-top: var(--space-2); }
.submenu .submenu__all a { font-weight: 700; color: var(--color-primary); }

/* Without JS the submenu opens on hover/focus; with JS a toggle button controls it. */
@media (min-width: 1061px) {
  .has-submenu:hover > .submenu,
  html:not(.js) .has-submenu:focus-within > .submenu,
  .submenu-toggle[aria-expanded="true"] + .submenu { display: grid; }
  .has-submenu::after { content: ""; position: absolute; left: 0; right: 0; top: 100%; height: 0.6rem; }
}

@media (max-width: 1060px) {
  .js .nav-toggle { display: inline-flex; }
  .header-inner { flex-wrap: wrap; }
  .js .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    max-height: calc(100vh - 4.75rem);
    max-height: calc(100dvh - 4.75rem);
    overflow-y: auto;
    padding: var(--space-4) var(--gutter) var(--space-6);
    background: var(--white);
    border-bottom: 1px solid var(--color-border);
    box-shadow: var(--shadow-lg);
  }
  .js .site-nav.is-open { display: block; }
  .site-nav { flex-direction: column; align-items: stretch; width: 100%; gap: var(--space-4); }
  html:not(.js) .site-nav { padding-bottom: var(--space-4); }
  .nav-list { flex-direction: column; align-items: stretch; }
  .nav-list > li { border-bottom: 1px solid var(--color-border); }
  .nav-link { width: 100%; min-height: 3.25rem; font-size: 1.05rem; padding-inline: 0.25rem; }
  .nav-link:hover { background: transparent; }
  .has-submenu { flex-wrap: wrap; justify-content: space-between; }
  .has-submenu > .nav-link { width: auto; flex: 1; }
  .submenu-toggle { width: 3rem; height: 3.25rem; }
  .submenu {
    position: static;
    width: 100%;
    grid-template-columns: 1fr;
    padding: 0 0 var(--space-3);
    border: 0;
    box-shadow: none;
    border-radius: 0;
  }
  .submenu-toggle[aria-expanded="true"] + .submenu { display: grid; }
  .submenu a { padding: 0.6rem 0.75rem; }
  .submenu a span { display: none; }
  .site-nav .btn { width: 100%; }
}

@media (max-width: 420px) {
  .brand img { height: 30px; }
  .nav-toggle__label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
}

/* --------------------------------------------------------------------------
   Door shapes (brand device)
   -------------------------------------------------------------------------- */

.door-mark {
  display: inline-block;
  width: 0.62em; height: 0.6em;
  border-radius: 46% 46% 12% 12% / 52% 52% 12% 12%;
  background: var(--color-accent);
  flex-shrink: 0;
}

.door-list { list-style: none; padding: 0; }
.door-list li { position: relative; padding-left: 1.6rem; }
.door-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.42em;
  width: 0.7rem; height: 0.68rem;
  border-radius: 46% 46% 14% 14% / 52% 52% 14% 14%;
  background: var(--color-accent);
}

/* --------------------------------------------------------------------------
   Home hero
   The visual is the logo's A as a doorway: a purple arch whose opening frames
   a storefront for "your brand", with the green door standing at its base.
   -------------------------------------------------------------------------- */

.hero {
  position: relative;
  padding-block: clamp(1.75rem, 0.5rem + 4vw, 4.5rem) clamp(3rem, 1.5rem + 5vw, 6rem);
  overflow: hidden;
}
.hero__grid {
  display: grid;
  gap: clamp(1.75rem, 1rem + 3vw, 3.5rem);
  align-items: center;
}
@media (min-width: 960px) {
  .hero__grid { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); }
}

/* The headline breaks after "Brand" and "Impossible" at every width; its size
   follows the column so the longest line always fits. */
.hero__copy { container-type: inline-size; }
.hero__title {
  margin-bottom: var(--space-5);
  font-size: var(--step-5);
  font-size: min(12cqi, 5.6rem);
  line-height: 0.98;
  letter-spacing: -0.035em;
}
.hero__title span { display: block; white-space: nowrap; }
.hero__lead { max-width: 34rem; margin-bottom: var(--space-6); color: var(--color-muted); font-size: var(--step-1); line-height: 1.55; }

.hero__visual { display: grid; justify-items: center; }
.hero-door { position: relative; width: min(100%, 33rem); aspect-ratio: 1 / 1.06; }
.hero-door__frame {
  position: absolute;
  inset: 0 7%;
  border-radius: var(--door);
  background:
    radial-gradient(110% 55% at 72% 0%, rgba(255, 255, 255, 0.12), transparent 62%),
    var(--purple-700);
  box-shadow: var(--shadow-lg);
}
.hero-door__view {
  position: absolute;
  inset: 6.5% 7.5% 0;
  overflow: hidden;
  container-type: inline-size;
  border-radius: 999px 999px 0 0;
  background: linear-gradient(180deg, var(--mint-50) 0%, #E6F4EC 100%);
}
.hero-door__door {
  position: absolute;
  left: 0; right: 0;
  bottom: 0;
  width: 17%;
  aspect-ratio: 1 / 1.04;
  margin-inline: auto;
  border-radius: 46% 46% 10% 10% / 52% 52% 10% 10%;
  background: var(--green-500);
}

/* The storefront inside the doorway */
.hero-store {
  position: absolute;
  left: 9%; right: 9%;
  top: 19%;
  overflow: hidden;
  border-radius: 0.9em;
  background: var(--white);
  box-shadow: 0 2px 4px rgba(42, 33, 99, 0.06), 0 18px 40px -12px rgba(42, 33, 99, 0.3);
  color: var(--ink);
  font-size: 2.15cqi;
  line-height: 1.25;
}
.hero-store p { margin: 0; }
.hero-store__bar { display: flex; align-items: center; gap: 0.45em; padding: 0.7em 1em; background: #F3F1F8; }
.hero-store__bar i { width: 0.7em; height: 0.7em; border-radius: 50%; background: #D5D2DE; }
.hero-store__bar span { margin-left: 0.8em; padding: 0.3em 0.9em; border-radius: 0.6em; background: var(--white); color: var(--graypurple-700); font-size: 0.85em; white-space: nowrap; }
.hero-store__nav { display: flex; align-items: center; gap: 1.1em; padding: 0.9em 1.3em; border-bottom: 1px solid var(--color-border); font-size: 0.9em; }
.hero-store__nav b { margin-right: auto; color: var(--purple-700); font-family: var(--font-display); font-size: 1.45em; font-weight: 900; letter-spacing: -0.02em; }
.hero-store__bag { width: 1.4em; height: 1.4em; }
.hero-store__hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 1.1em; align-items: center; padding: 1.3em; }
.hero-store__kicker { margin-bottom: 0.5em !important; color: var(--green-700); font-size: 0.85em; font-weight: 700; }
.hero-store__title { margin-bottom: 0.7em !important; color: var(--purple-900); font-family: var(--font-display); font-size: 2em; font-weight: 900; line-height: 1; letter-spacing: -0.02em; }
.hero-store__btn { display: inline-block; padding: 0.65em 1.1em; border-radius: 0.8em 0.8em 0.25em 0.25em; background: var(--green-500); color: var(--ink); font-size: 0.85em; font-weight: 700; }
.hero-store__art { overflow: hidden; aspect-ratio: 1 / 0.92; border-radius: 0.7em; }
.hero-store__art svg { width: 100%; height: 100%; }
.hero-store__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.9em; padding: 0 1.3em 1.4em; font-size: 0.85em; }
.hero-store__grid b { display: block; margin-top: 0.5em; }
.hero-store__grid span:not(.hero-store__tile) { color: var(--graypurple-700); }
.hero-store__tile { display: grid; place-items: center; aspect-ratio: 1 / 0.9; border-radius: 0.6em; background: radial-gradient(85% 70% at 50% 35%, #FFFFFF, var(--purple-100)); }
.hero-store__tile svg { width: 58%; }

/* Notes that name the services each part of the storefront stands for */
.hero-door__note {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.4rem 0.8rem 0.4rem 0.6rem;
  border-radius: var(--door-btn);
  background: var(--white);
  color: var(--purple-900);
  font-size: 0.8125rem;
  font-weight: 700;
  white-space: nowrap;
  box-shadow: var(--shadow);
}
.hero-door__note::before { content: ""; width: 0.6rem; height: 0.58rem; border-radius: 46% 46% 14% 14% / 52% 52% 14% 14%; background: var(--green-500); }
.hero-door__note--seo { top: 17%; right: -3%; }
.hero-door__note--brand { top: 35%; left: -4%; }
.hero-door__note--build { top: 70%; right: -6%; }

@media (max-width: 959px) {
  /* Sized to what's left of a phone's first screen after the copy. */
  .hero-door { width: min(100%, max(16rem, (100svh - 31rem) * 1.08)); max-width: 30rem; aspect-ratio: 1.08 / 1; }
  .hero-door__frame { inset: 0; border-radius: 50% 50% var(--radius-sm) var(--radius-sm) / 42% 42% var(--radius-sm) var(--radius-sm); }
  .hero-door__view { inset: 6% 6% 0; border-radius: 50% 50% 0 0 / 40% 40% 0 0; }
  .hero-store { left: 8%; right: 8%; top: 17%; font-size: 2.3cqi; }
  .hero-store__grid { display: none; }
  .hero-door__door { width: 14%; }
  .hero-door__note { display: none; }
}
@media (max-width: 420px) {
  .hero__lead { margin-bottom: var(--space-5); }
  .hero .btn-row { gap: var(--space-2); }
  .hero .btn { padding-inline: 0.95rem; font-size: 0.95rem; }
}

@media (prefers-reduced-motion: no-preference) {
  .hero-door__frame { animation: arch-rise 0.9s var(--ease-out) both; transform-origin: 50% 100%; }
  .hero-store { animation: slide-up 0.8s var(--ease-out) 0.3s both; }
  .hero-door__door { animation: door-open 0.6s var(--ease-out) 0.75s both; transform-origin: 50% 100%; }
  .hero-door__note { animation: fade 0.5s ease 1.05s both; }
  .hero-door__note--brand { animation-delay: 1.15s; }
  .hero-door__note--build { animation-delay: 1.25s; }
}
@keyframes arch-rise { from { transform: scaleY(0.4); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes door-open { from { transform: scaleY(0); } to { transform: none; } }
@keyframes slide-up { from { transform: translateY(28px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

/* Capability line */
.capabilities { border-block: 1px solid var(--color-border); padding-block: var(--space-5); }
.capabilities__inner { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3) var(--space-7); }
.capabilities__intro { max-width: 21rem; margin: 0; color: var(--ink); font: 700 1rem/1.45 var(--font-body); letter-spacing: 0; }
.capabilities__list { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1.4rem; margin: 0; padding: 0; list-style: none; color: var(--purple-700); font-family: var(--font-display); font-size: 1.0625rem; font-weight: 800; }
.capabilities__list li { display: inline-flex; align-items: center; margin: 0; }
.capabilities__list li::before { content: ""; width: 0.5rem; height: 0.48rem; margin-right: 0.55rem; border-radius: 46% 46% 14% 14% / 52% 52% 14% 14%; background: var(--green-500); }

/* --------------------------------------------------------------------------
   Page hero (interior pages)
   -------------------------------------------------------------------------- */

.page-hero {
  position: relative;
  padding-block: clamp(2.25rem, 1.25rem + 3.5vw, 4.5rem) clamp(2.75rem, 1.75rem + 3.5vw, 5rem);
  background: var(--mint-50);
}
.page-hero h1 { max-width: 18ch; }
.page-hero .lead { margin-bottom: 0; }
.page-hero .btn-row { margin-top: var(--space-6); }

.breadcrumbs { margin-bottom: var(--space-5); font-size: 0.9375rem; }
.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: 0.25rem 0.5rem; margin: 0; padding: 0; list-style: none; }
.breadcrumbs li { margin: 0; display: inline-flex; align-items: center; gap: 0.5rem; color: var(--color-muted); }
.breadcrumbs li + li::before { content: "/"; color: var(--graypurple-500); }
.breadcrumbs a { color: var(--color-muted); }
.breadcrumbs a:hover { color: var(--color-primary); }

/* Service pages: copy beside the service's own visual */
.service-hero { overflow: hidden; }
.service-hero__grid { display: grid; gap: var(--space-7); align-items: center; }
.service-hero__copy h1 { font-size: clamp(2.1rem, 1.5rem + 2.6vw, 3.4rem); }
.service-hero__visual { min-width: 0; }
.nowrap { white-space: nowrap; }
.service-hero__note { margin: var(--space-3) 0 0; color: var(--color-muted); font-size: 0.875rem; }
@media (min-width: 1000px) {
  .service-hero__grid { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: var(--space-8); }
  .service-hero__visual { margin-right: calc(var(--gutter) * -0.5); }
}

/* --------------------------------------------------------------------------
   Project cards (portfolio)
   -------------------------------------------------------------------------- */

.work-grid {
  display: grid;
  gap: clamp(2rem, 1rem + 3vw, 3.5rem) var(--space-6);
}
@media (min-width: 860px) {
  .work-grid { grid-template-columns: repeat(12, minmax(0, 1fr)); }
  .work-grid > :nth-child(4n + 1) { grid-column: span 7; }
  .work-grid > :nth-child(4n + 2) { grid-column: span 5; margin-top: clamp(3rem, 8vw, 7rem); }
  .work-grid > :nth-child(4n + 3) { grid-column: span 5; }
  .work-grid > :nth-child(4n + 4) { grid-column: span 7; margin-top: clamp(-4rem, -5vw, -2rem); }
  .work-grid--even > * { grid-column: span 6 !important; margin-top: 0 !important; }
  .work-grid--single > * { grid-column: 2 / span 10 !important; }
}
/* On phones the homepage shows two projects; the rest are one tap away on Work. */
@media (max-width: 639px) {
  .work-grid--home > :nth-child(n + 3) { display: none; }
}

.project-card { position: relative; display: flex; flex-direction: column; }
.project-card__media {
  position: relative;
  display: grid;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  padding: 7% 7% 0;
  border-radius: var(--door-card);
  background: var(--project-bg, var(--purple-100));
}
.work-grid--single .project-card__media { aspect-ratio: 16 / 9; }
.project-card__media .mock,
.project-card__media .shot {
  align-self: start;
  width: 100%;
  border-radius: 10px 10px 0 0;
  box-shadow: var(--shadow);
  transition: transform 0.5s var(--ease-out);
}
.project-card:hover .project-card__media .mock,
.project-card:hover .project-card__media .shot { transform: translateY(-6px); }
.project-card__body { padding-top: var(--space-5); }
.project-card__meta { margin: 0 0 var(--space-2); color: var(--color-muted); font-size: 0.9375rem; }
.project-card h2, .project-card h3 { font-size: var(--step-2); margin-bottom: var(--space-3); }
.project-card h2 a, .project-card h3 a { color: inherit; text-decoration: none; }
.project-card h2 a::after, .project-card h3 a::after { content: ""; position: absolute; inset: 0; border-radius: var(--door-card); }
.project-card a:focus-visible { outline: none; }
.project-card:focus-within .project-card__media { outline: 3px solid var(--color-focus); outline-offset: 4px; }
.project-card__body p { color: var(--color-muted); max-width: 34rem; }
.project-card .tag-list { margin-bottom: var(--space-4); }
.project-card .text-link { position: relative; }

.tag-list { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0; padding: 0; list-style: none; }
.tag-list li {
  margin: 0;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-sm);
  background: var(--purple-100);
  color: var(--purple-900);
  font-size: 0.8125rem;
  font-weight: 600;
}

.note {
  display: flex;
  gap: var(--space-3);
  align-items: flex-start;
  max-width: 46rem;
  padding: var(--space-4) var(--space-5);
  border-radius: var(--radius);
  background: var(--white);
  border: 1px solid var(--color-border);
  color: var(--color-muted);
  font-size: 0.9375rem;
  line-height: 1.5;
}
.note .door-mark { margin-top: 0.3em; font-size: 1.1rem; }
.note p { margin: 0; }
.note strong { color: var(--ink); }
.note--warning { background: #FFF8E6; border-color: #F0D58A; color: #5C4813; }
.note--warning strong { color: #3D2F08; }
.note--warning .door-mark { background: #C9960C; }

/* Work page: one editorial feature per concept project */
.work-features { display: grid; }
.work-feature { padding-block: clamp(2.5rem, 1.5rem + 4vw, 5rem); background: linear-gradient(180deg, var(--project-bg) 0, var(--project-bg) 100%); }
.work-feature:nth-child(even) { background: color-mix(in srgb, var(--project-bg) 55%, var(--white)); }
.work-feature__inner { display: grid; gap: var(--space-6) var(--space-8); align-items: center; }
@media (min-width: 960px) {
  .work-feature__inner { grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.65fr); }
  .work-feature:nth-child(even) .work-feature__inner { grid-template-columns: minmax(0, 0.65fr) minmax(0, 1.35fr); }
  .work-feature:nth-child(even) .work-feature__stage { order: 2; }
}
.work-feature__stage { position: relative; padding: 0 10% 8% 0; }
.work-feature__desk .mock, .work-feature__desk.shot { border-radius: 12px; box-shadow: var(--shadow-lg); }
.work-feature__phone { position: absolute; right: 0; bottom: 0; width: 25%; filter: drop-shadow(0 18px 30px rgba(31, 25, 54, 0.28)); }
.work-feature__text h2 { font-size: var(--step-3); margin-bottom: var(--space-3); }
.work-feature__idea { margin-bottom: var(--space-4); color: var(--ink); font-family: var(--font-display); font-size: var(--step-1); font-weight: 800; line-height: 1.3; }
.work-feature__text > p:not(.project-card__meta):not(.work-feature__idea) { color: var(--color-muted); }
.work-feature__facts { display: grid; gap: var(--space-3); margin: var(--space-5) 0; padding-block: var(--space-4); border-block: 1px solid color-mix(in srgb, var(--ink) 12%, transparent); font-size: 0.9375rem; }
.work-feature__facts div { display: grid; grid-template-columns: 8.5rem minmax(0, 1fr); gap: var(--space-3); }
.work-feature__facts dt { font-weight: 700; color: var(--ink); }
.work-feature__facts dd { margin: 0; color: var(--color-muted); }
.work-feature__links { display: flex; flex-wrap: wrap; gap: var(--space-3) var(--space-6); margin: 0; }
/* The featured project leads at full width, with its text below the screenshots. */
@media (min-width: 960px) {
  .work-feature--featured .work-feature__inner { grid-template-columns: minmax(0, 1fr); }
  .work-feature--featured .work-feature__stage { max-width: 64rem; padding-right: 12%; }
  .work-feature--featured .work-feature__phone { width: 22%; }
  .work-feature--featured .work-feature__text { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: var(--space-8); align-items: start; }
  .work-feature--featured .work-feature__text > * { grid-column: 2; }
  .work-feature--featured .work-feature__text > .project-card__meta,
  .work-feature--featured .work-feature__text > h2,
  .work-feature--featured .work-feature__text > .work-feature__idea { grid-column: 1; }
  .work-feature--featured .work-feature__text > .project-card__meta { grid-row: 1; }
  .work-feature--featured .work-feature__text > h2 { grid-row: 2; }
  .work-feature--featured .work-feature__text > .work-feature__idea { grid-row: 3; }
  .work-feature--featured .work-feature__text > p:nth-of-type(3) { grid-row: 1 / span 3; align-self: end; }
}

/* --------------------------------------------------------------------------
   Services overview (home + services index)
   -------------------------------------------------------------------------- */

.service-groups { display: grid; gap: var(--space-7); }
@media (min-width: 900px) {
  .service-groups { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; }
  .service-group { padding-inline: var(--space-6); border-left: 1px solid var(--color-border); }
  .service-group:first-child { padding-left: 0; border-left: 0; }
  .service-group:last-child { padding-right: 0; }
}
.service-group__title { font-size: var(--step-2); margin-bottom: var(--space-3); }
.service-group__intro { color: var(--color-muted); margin-bottom: var(--space-5); }
.service-links { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--color-border); }
.service-links li { margin: 0; border-bottom: 1px solid var(--color-border); }
.service-links a {
  display: grid;
  grid-template-columns: 2.5rem 1fr auto;
  gap: var(--space-3);
  align-items: start;
  padding: var(--space-4) 0;
  color: var(--ink);
  text-decoration: none;
}
.service-links .icon-tile { margin-top: 0.1rem; }
.service-links strong { display: block; font-family: var(--font-display); font-size: 1.125rem; font-weight: 800; color: var(--color-primary); line-height: 1.3; }
.service-links span { display: block; color: var(--color-muted); font-size: 0.9375rem; line-height: 1.45; margin-top: 0.2rem; }
.service-links .chev { width: 1.25rem; height: 1.25rem; margin-top: 0.2rem; color: var(--graypurple-500); transition: transform 0.2s var(--ease-out), color 0.2s ease; }
.service-links a:hover strong { text-decoration: underline; text-decoration-color: var(--color-accent); text-decoration-thickness: 2px; text-underline-offset: 0.2em; }
.service-links a:hover .chev { transform: translateX(3px); color: var(--green-700); }

.icon-tile {
  display: grid;
  place-items: center;
  width: 2.5rem; height: 2.5rem;
  border-radius: 12px 12px 5px 5px;
  background: var(--green-100);
  color: var(--green-700);
}
.icon-tile svg { width: 1.3rem; height: 1.3rem; }
.section--dark .icon-tile { background: rgba(114, 226, 177, 0.14); color: var(--green-300); }

/* Detailed service blocks (services index) */
.service-detail {
  display: grid;
  gap: var(--space-5) var(--space-7);
  padding-block: var(--space-7);
  border-top: 1px solid var(--color-border);
}
.service-detail:first-of-type { border-top: 0; padding-top: 0; }
@media (min-width: 900px) {
  .service-detail { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); }
}
.service-detail h3 { font-size: var(--step-2); display: flex; align-items: center; gap: var(--space-3); }
.service-detail h3 a { color: inherit; text-decoration: none; }
.service-detail h3 a:hover { text-decoration: underline; text-decoration-color: var(--color-accent); }
.service-detail__solves { color: var(--color-muted); }
.service-detail__solves h4 { color: var(--ink); font-family: var(--font-body); font-weight: 700; margin-bottom: var(--space-2); }

.group-head { display: grid; gap: var(--space-3); margin-bottom: var(--space-6); max-width: 46rem; }
.group-head h2 { margin: 0; }
.group-head p { margin: 0; color: var(--color-muted); font-size: var(--step-1); }

/* --------------------------------------------------------------------------
   Principles (why work with us)
   -------------------------------------------------------------------------- */

.principles { display: grid; gap: var(--space-7); }
@media (min-width: 960px) { .principles { grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); gap: var(--space-8); } }
.principles__intro h2 { font-size: var(--step-4); font-weight: 900; letter-spacing: -0.03em; line-height: 1.02; }
.principles__intro p { color: #CBC5E6; font-size: var(--step-1); max-width: 30rem; }
.principles__list { display: grid; gap: var(--space-6) var(--space-6); margin: 0; padding: 0; list-style: none; }
@media (min-width: 640px) { .principles__list { grid-template-columns: 1fr 1fr; } }
.principles__list li { margin: 0; padding-top: var(--space-5); border-top: 1px solid rgba(255, 255, 255, 0.18); }
.principles__list h3 { display: flex; align-items: center; gap: 0.6rem; font-size: var(--step-1); margin-bottom: var(--space-3); }
.principles__list h3 .door-mark { font-size: 1.05rem; }
.principles__list p { margin: 0; color: #CBC5E6; }

/* --------------------------------------------------------------------------
   Process (genuine sequence → numbered)
   -------------------------------------------------------------------------- */

.process { margin: 0; padding: 0; list-style: none; counter-reset: step; display: grid; gap: 0; }
.process li { counter-increment: step; position: relative; margin: 0; padding: 0 0 var(--space-6) 4rem; }
.process li::before {
  content: counter(step);
  position: absolute;
  left: 0; top: 0;
  display: grid;
  place-items: center;
  width: 2.75rem; height: 2.75rem;
  border-radius: 16px 16px 6px 6px;
  background: var(--purple-700);
  color: var(--white);
  font: 900 1.125rem/1 var(--font-display);
}
.process li::after {
  content: "";
  position: absolute;
  left: 1.375rem; top: 3.25rem; bottom: 0.5rem;
  width: 2px;
  background: var(--purple-200);
}
.process li:last-child::after { display: none; }
.process li:last-child::before { background: var(--green-500); color: var(--ink); }
.process h3 { font-size: var(--step-1); margin-bottom: var(--space-2); padding-top: 0.45rem; }
.process p { margin: 0; color: var(--color-muted); max-width: 32rem; }

@media (min-width: 1000px) {
  .process--row { grid-template-columns: repeat(var(--steps, 6), minmax(0, 1fr)); gap: var(--space-5); }
  .process--row li { padding: 4rem 0 0; }
  .process--row li::after { left: 3.5rem; right: -0.75rem; top: 1.375rem; bottom: auto; width: auto; height: 2px; }
  .process--row h3 { padding-top: 0; }
}

/* --------------------------------------------------------------------------
   Audiences (who we help): four stages, each marked by a door that grows
   -------------------------------------------------------------------------- */

.stages { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--color-border); }
.stage { margin: 0; padding: var(--space-5) 0; border-bottom: 1px solid var(--color-border); }
.stage__door {
  display: block;
  width: calc(0.9rem + var(--s) * 0.35rem);
  height: calc(1rem + var(--s) * 0.55rem);
  margin-bottom: var(--space-4);
  border-radius: 999px 999px 3px 3px;
  background: var(--green-500);
}
.stage h3 { font-size: var(--step-1); margin-bottom: var(--space-2); }
.stage p { color: var(--color-muted); margin-bottom: var(--space-3); }
.stage .text-link { font-size: 0.98rem; }
@media (min-width: 860px) {
  .stages { grid-template-columns: repeat(4, minmax(0, 1fr)); border-bottom: 1px solid var(--color-border); }
  .stage { display: flex; flex-direction: column; padding: var(--space-6) var(--space-5) var(--space-6) 0; border-bottom: 0; }
  .stage + .stage { padding-left: var(--space-5); border-left: 1px solid var(--color-border); }
  .stage__door { margin-bottom: var(--space-5); align-self: flex-start; min-height: 0; }
  .stage .stage__door { margin-top: calc(2.2rem - var(--s) * 0.55rem); }
  .stage .text-link { margin-top: auto; }
}

/* About: principles as plain statements */
.statements { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--color-border); }
.statements li { display: grid; gap: var(--space-2) var(--space-7); margin: 0; padding: var(--space-5) 0; border-bottom: 1px solid var(--color-border); }
.statements h3 { margin: 0; font-size: var(--step-2); }
.statements p { margin: 0; max-width: 36rem; color: var(--color-muted); font-size: 1.0625rem; }
@media (min-width: 860px) { .statements li { grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); align-items: baseline; } }

/* About: the door in the logo */
.logo-story { display: grid; gap: var(--space-7); align-items: center; }
@media (min-width: 860px) { .logo-story { grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: var(--space-8); } }
.logo-story__art {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 1 / 0.82;
  max-width: 26rem;
  padding: 12% 14%;
  border-radius: var(--door);
  background: var(--white);
  box-shadow: var(--shadow);
}
.logo-story__art img { width: 100%; height: auto; }

/* --------------------------------------------------------------------------
   Article cards & article layout
   One card everywhere; the heading level changes with the page, the look doesn't.
   -------------------------------------------------------------------------- */

.article-grid { display: grid; gap: var(--space-6); }
@media (min-width: 760px) { .article-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 760px) { .article-grid--two { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.article-card { position: relative; display: flex; flex-direction: column; padding-top: var(--space-5); border-top: 2px solid var(--purple-200); }
.article-card__topic { display: flex; align-items: center; gap: 0.5rem; margin: 0 0 var(--space-3); color: var(--green-700); font-size: 0.9375rem; font-weight: 700; }
.article-card__topic::before { content: ""; width: 0.6rem; height: 0.58rem; border-radius: 46% 46% 14% 14% / 52% 52% 14% 14%; background: var(--green-500); }
.article-card__title { font-size: var(--step-2); line-height: 1.15; margin-bottom: var(--space-3); }
.article-card__title a { color: inherit; text-decoration: none; }
.article-card__title a::after { content: ""; position: absolute; inset: 0; }
.article-card:hover .article-card__title a { text-decoration: underline; text-decoration-color: var(--color-accent); text-decoration-thickness: 2px; }
.article-card:hover { border-top-color: var(--green-500); }
.article-card__excerpt { color: var(--color-muted); }
.article-card__more { margin-top: auto; color: var(--color-primary); font-size: 0.98rem; font-weight: 700; }
@media (max-width: 639px) { .article-grid--home .article-card__excerpt { display: none; } }

.more-note { margin: var(--space-7) 0 0; color: var(--color-muted); }

.article-header { padding-block: clamp(2.5rem, 1.5rem + 4vw, 5rem) var(--space-7); background: var(--mint-50); }
.article-header h1 { max-width: 22ch; font-size: var(--step-4); }
.article-header .lead { max-width: 42rem; margin-bottom: var(--space-5); }
.article-meta { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-5); margin: 0; color: var(--color-muted); font-size: 0.9375rem; }
.article-meta dt { font-weight: 700; color: var(--ink); display: inline; }
.article-meta dd { display: inline; margin: 0 0 0 0.3rem; }

.article-layout { display: grid; gap: var(--space-7); padding-block: var(--space-8) var(--section); }
@media (min-width: 1000px) { .article-layout { grid-template-columns: minmax(0, 15rem) minmax(0, 42rem); justify-content: space-between; gap: var(--space-8); } }
.article-layout > * { min-width: 0; }
.article-toc { align-self: start; font-size: 0.9375rem; }
@media (min-width: 1000px) { .article-toc { position: sticky; top: 6.5rem; } }
.article-toc h2 { font: 700 0.9375rem/1.3 var(--font-body); color: var(--ink); margin-bottom: var(--space-3); }
.article-toc ol { margin: 0; padding-left: 1.1rem; color: var(--color-muted); }
.article-toc a { color: var(--color-muted); text-decoration: none; }
.article-toc a:hover { color: var(--color-primary); text-decoration: underline; }

.article-body { font-size: 1.125rem; line-height: 1.7; }
.article-body h2 { font-size: var(--step-2); margin-top: var(--space-7); }
.article-body h2:first-child { margin-top: 0; }
.article-body h3 { margin-top: var(--space-6); }
.article-body li { padding-left: 0.2rem; }
.article-body table { width: 100%; border-collapse: collapse; margin: var(--space-5) 0; font-size: 1rem; line-height: 1.5; }
.article-body th, .article-body td { padding: 0.75rem; border-bottom: 1px solid var(--color-border); text-align: left; vertical-align: top; }
.article-body th { color: var(--ink); background: var(--mint-50); }
.article-body .table-wrap { overflow-x: auto; }
.callout {
  margin: var(--space-6) 0;
  padding: var(--space-5);
  border-radius: var(--door-card);
  background: var(--purple-100);
}
.callout > :last-child { margin-bottom: 0; }
.callout h3 { margin-top: 0; }

/* FAQ topics */
.topic-nav { align-self: start; }
@media (min-width: 900px) { .topic-nav { position: sticky; top: 6.5rem; } }
.topic-nav h2 { margin-bottom: var(--space-3); color: var(--ink); font: 700 1rem/1.3 var(--font-body); }
.topic-nav ul { display: flex; flex-wrap: wrap; gap: var(--space-2); margin: 0; padding: 0; list-style: none; }
@media (min-width: 900px) { .topic-nav ul { flex-direction: column; } }
.topic-nav li { margin: 0; }
.topic-nav a {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 2.75rem;
  padding: 0.4rem 0.9rem;
  border-radius: var(--door-btn);
  background: var(--mint-50);
  color: var(--purple-900);
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 800;
  text-decoration: none;
}
.topic-nav a:hover { background: var(--green-100); }

/* --------------------------------------------------------------------------
   Service page sections
   -------------------------------------------------------------------------- */

.split { display: grid; gap: var(--space-6) var(--space-8); }
@media (min-width: 900px) { .split { grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); } }
.split > :first-child h2 { margin-bottom: var(--space-4); }
.split > :first-child p { color: var(--color-muted); }

/* Who it's for + what you get, side by side */
.fit-grid { display: grid; gap: var(--space-7) var(--space-8); }
@media (min-width: 900px) { .fit-grid { grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); } }
.fit-grid h2 { margin-bottom: var(--space-3); }
.fit-grid__intro { max-width: 34rem; margin-bottom: var(--space-5); color: var(--color-muted); }
.fit-grid ul { margin: 0; }
.deliverables { columns: 2 16rem; column-gap: var(--space-6); }
.deliverables li { break-inside: avoid; margin: 0 0 var(--space-3); }

/* Problems: the problem as a statement, then how we handle it */
.problem-rows { display: grid; margin: 0; padding: 0; list-style: none; border-top: 1px solid #D3E8DC; counter-reset: none; }
.problem-rows li { display: grid; gap: var(--space-2) var(--space-8); margin: 0; padding: var(--space-5) 0; border-bottom: 1px solid #D3E8DC; }
@media (min-width: 860px) { .problem-rows li { grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); align-items: baseline; padding-block: var(--space-6); } }
.problem-rows h3 { margin: 0; font-size: var(--step-2); }
.problem-rows p { margin: 0; max-width: 38rem; color: var(--color-muted); font-size: 1.0625rem; }

.faq-list { display: grid; gap: var(--space-3); max-width: 50rem; }
.faq-item { border: 1px solid var(--color-border); border-radius: var(--radius-lg); background: var(--white); }
.faq-item summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-5);
  cursor: pointer;
  list-style: none;
  font: 800 1.0625rem/1.35 var(--font-display);
  color: var(--color-primary);
  border-radius: var(--radius-lg);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "";
  flex-shrink: 0;
  width: 1.75rem; height: 1.75rem;
  border-radius: 10px 10px 4px 4px;
  background:
    linear-gradient(var(--green-700), var(--green-700)) center / 12px 2px no-repeat,
    linear-gradient(var(--green-700), var(--green-700)) center / 2px 12px no-repeat,
    var(--green-100);
  transition: transform 0.2s ease;
}
.faq-item[open] summary::after { background: linear-gradient(var(--green-700), var(--green-700)) center / 12px 2px no-repeat, var(--green-100); }
.faq-item summary:hover { background: var(--mint-50); }
.faq-item__body { padding: 0 var(--space-5) var(--space-5); color: var(--color-muted); }
.faq-item__body > :last-child { margin-bottom: 0; }

.faq-group + .faq-group { margin-top: var(--space-7); }
.faq-group h2 { font-size: var(--step-2); }

/* Services index: common combinations, in the order they usually run */
.combos { display: grid; gap: var(--space-6) var(--space-7); margin: 0; padding: 0; list-style: none; }
@media (min-width: 860px) { .combos { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.combos > li { margin: 0; }
.combos h3 { margin-bottom: var(--space-2); }
.combos p { color: var(--color-muted); }
.combo-chain { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.combo-chain li { position: relative; margin: 0; padding: 0 0 var(--space-3) 1.6rem; }
.combo-chain li::before { content: ""; position: absolute; left: 0; top: 0.42em; width: 0.7rem; height: 0.68rem; border-radius: 46% 46% 14% 14% / 52% 52% 14% 14%; background: var(--green-500); }
.combo-chain li:not(:last-child)::after { content: ""; position: absolute; left: 0.32rem; top: 1.35em; bottom: 0.15rem; width: 2px; background: var(--purple-200); }
.combo-chain a { font-weight: 700; }

/* --------------------------------------------------------------------------
   Case study
   -------------------------------------------------------------------------- */

.case-hero { padding-block: clamp(2.25rem, 1.25rem + 3.5vw, 4.5rem) 0; background: var(--project-bg, var(--mint-50)); overflow: hidden; }
.case-hero h1 { max-width: 16ch; }
.case-hero .lead { color: var(--ink); opacity: 0.85; }
.case-hero__stage { position: relative; max-width: 66rem; margin: var(--space-7) auto 0; padding-right: 14%; }
.case-hero__desk .mock, .case-hero__desk.shot { border-radius: 14px 14px 0 0; box-shadow: var(--shadow-lg); }
.case-hero__phone { position: absolute; right: 0; bottom: -10%; width: 22%; filter: drop-shadow(0 18px 30px rgba(31, 25, 54, 0.3)); }

.case-facts { display: grid; gap: var(--space-4) var(--space-6); margin: 0; padding: var(--space-6) 0; border-bottom: 1px solid var(--color-border); }
@media (min-width: 720px) { .case-facts { grid-template-columns: repeat(4, minmax(0, 1fr)); } .case-facts--three { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.case-facts div { margin: 0; }
.case-facts dt { font-weight: 700; color: var(--ink); font-size: 0.9375rem; margin-bottom: 0.2rem; }
.case-facts dd { margin: 0; color: var(--color-muted); font-size: 0.98rem; }
.case-facts__note { display: block; margin-top: 0.3rem; font-size: 0.875rem; }

/* Background and challenge read side by side, as the brief */
.case-intro { display: grid; gap: var(--space-6) var(--space-8); padding-block: var(--space-7) var(--space-4); }
@media (min-width: 860px) { .case-intro { grid-template-columns: 1fr 1fr; } }
.case-intro h2 { font-size: var(--step-2); margin-bottom: var(--space-3); }
.case-intro p { margin: 0; color: var(--ink); }

.case-section { display: grid; gap: var(--space-4) var(--space-8); padding-block: var(--space-7); }
@media (min-width: 900px) { .case-section { grid-template-columns: minmax(0, 0.7fr) minmax(0, 1.3fr); } }
.case-section h2 { font-size: var(--step-2); }
.case-section .prose p { color: var(--ink); }

.case-gallery { display: grid; gap: var(--space-6) var(--space-5); padding-block: var(--space-4) var(--space-6); }
@media (min-width: 860px) { .case-gallery { grid-template-columns: repeat(12, minmax(0, 1fr)); } }
.case-gallery figure { margin: 0; display: flex; flex-direction: column; min-width: 0; }
.case-gallery__frame {
  display: grid;
  place-items: center;
  flex: 1;
  padding: clamp(1rem, 3.5vw, 3rem);
  border-radius: var(--door-card);
  background: var(--project-bg, var(--purple-100));
}
.case-gallery figcaption { padding-top: var(--space-3); color: var(--color-muted); font-size: 0.9375rem; }
@media (min-width: 860px) {
  .case-gallery .g-wide { grid-column: span 8; }
  .case-gallery .g-narrow { grid-column: span 4; }
  .case-gallery .g-full { grid-column: 1 / -1; }
}
.case-gallery .mock { width: 100%; box-shadow: var(--shadow); }
.case-gallery .mock--phone { width: min(100%, 15rem); box-shadow: none; filter: drop-shadow(0 14px 24px rgba(31, 25, 54, 0.25)); }
.case-gallery .g-brand .mock { max-width: 52rem; }
@media (min-width: 860px) {
  .case-gallery .g-cart .case-gallery__frame { padding-inline: clamp(0.75rem, 1.5vw, 1.25rem); }
}

.palette-row { display: flex; flex-wrap: wrap; gap: var(--space-3); margin: var(--space-4) 0 0; padding: 0; list-style: none; }
.palette-row li { margin: 0; display: flex; align-items: center; gap: 0.5rem; font-size: 0.9375rem; color: var(--color-muted); }
.palette-row i { width: 1.5rem; height: 1.5rem; border-radius: 8px 8px 3px 3px; box-shadow: inset 0 0 0 1px rgba(31, 25, 54, 0.22); }
.case-type { margin-top: var(--space-4); color: var(--color-muted); font-size: 0.9375rem; }
.case-gallery .shot { width: 100%; box-shadow: var(--shadow); }
.case-gallery__note { grid-column: 1 / -1; margin: 0; color: var(--color-muted); font-size: 0.875rem; }

/* Screenshots of client websites (scripts/lib/templates.js, shot()) */
.shot { overflow: hidden; border-radius: 10px; background: var(--white); }
.shot img { display: block; width: 100%; height: auto; }
.shot--phone { border: 5px solid var(--ink); border-radius: 22px; }
.shot--phone img { border-radius: 16px; }

/* --------------------------------------------------------------------------
   CTA band: the ask on the left, what happens next inside a doorway on the right
   -------------------------------------------------------------------------- */

.cta-band { padding-block: var(--section); }
.section:not(.section--mint):not(.section--lavender):not(.section--dark) + .cta-band,
.article-layout + .cta-band { padding-top: 0; }
.cta-band__inner {
  display: grid;
  gap: var(--space-7);
  align-items: end;
  padding: clamp(2.25rem, 1.5rem + 4vw, 4.5rem) clamp(1.5rem, 1rem + 4vw, 4.5rem) 0;
  border-radius: clamp(28px, 4vw, 48px) clamp(28px, 4vw, 48px) var(--radius) var(--radius);
  background: var(--purple-700);
  color: #E9E6F6;
}
@media (min-width: 900px) { .cta-band__inner { grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr); gap: var(--space-8); } }
.cta-band__copy { padding-bottom: clamp(2.25rem, 1.5rem + 4vw, 4.5rem); }
.cta-band :focus-visible { outline-color: var(--green-300); }
.cta-band h2 { max-width: 15ch; color: var(--white); font-size: var(--step-4); font-weight: 900; letter-spacing: -0.03em; line-height: 1.02; }
.cta-band__copy > p { max-width: 34rem; margin-bottom: var(--space-6); color: #DCD7F0; font-size: var(--step-1); }
.cta-band__related { margin: var(--space-6) 0 0; color: #DCD7F0; font-size: 0.98rem; }
.cta-band__related a { color: var(--white); text-decoration-color: var(--green-300); }
.cta-band__related a:hover { color: var(--green-300); }

.cta-band__door {
  position: relative;
  padding: clamp(2.5rem, 2rem + 3vw, 4rem) clamp(1.5rem, 1rem + 2vw, 2.5rem) clamp(4.5rem, 4rem + 2vw, 5.5rem);
  border-radius: 999px 999px 0 0;
  background: var(--purple-900);
}
@media (min-width: 900px) { .cta-band__door { padding-top: clamp(4rem, 3rem + 3vw, 6rem); } }
.cta-band__door::after {
  content: "";
  position: absolute;
  left: 0; right: 0;
  bottom: 0;
  width: 3.25rem;
  height: 3.3rem;
  margin-inline: auto;
  border-radius: 46% 46% 10% 10% / 52% 52% 10% 10%;
  background: var(--green-500);
}
.cta-band__door h3 { margin-bottom: var(--space-4); color: var(--white); font-size: var(--step-1); text-align: center; }
.cta-band__door ol { display: grid; gap: var(--space-3); margin: 0 auto; padding: 0; max-width: 18rem; list-style: none; counter-reset: next; }
.cta-band__door li { counter-increment: next; position: relative; margin: 0; padding-left: 2.4rem; color: #DCD7F0; font-size: 0.98rem; line-height: 1.45; }
.cta-band__door li::before {
  content: counter(next);
  position: absolute;
  left: 0; top: -0.1rem;
  display: grid;
  place-items: center;
  width: 1.7rem; height: 1.7rem;
  border-radius: 10px 10px 4px 4px;
  background: rgba(255, 255, 255, 0.12);
  color: var(--white);
  font: 900 0.875rem/1 var(--font-display);
}
@media (max-width: 899px) {
  .cta-band__copy { padding-bottom: 0; }
  .cta-band__door { border-radius: 50% 50% 0 0 / 3.5rem 3.5rem 0 0; }
}

/* --------------------------------------------------------------------------
   Forms
   -------------------------------------------------------------------------- */

.contact-layout { display: grid; gap: var(--space-7); }
@media (min-width: 1000px) { .contact-layout { grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.65fr); gap: var(--space-8); } }

.form { display: grid; gap: var(--space-5); }
.form-row { display: grid; gap: var(--space-5); }
@media (min-width: 640px) { .form-row { grid-template-columns: 1fr 1fr; } }

.field { display: grid; gap: 0.4rem; align-content: start; }
.field label, .field legend { font-weight: 700; color: var(--ink); font-size: 0.98rem; }
.field .optional { font-weight: 500; color: var(--color-muted); }
.field .hint { margin: 0; color: var(--color-muted); font-size: 0.9rem; line-height: 1.4; }

.input, .select, .textarea {
  width: 100%;
  min-height: 3rem;
  padding: 0.7rem 0.9rem;
  border: 1.5px solid #CFCBDD;
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  font: 500 1rem/1.4 var(--font-body);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.textarea { min-height: 10rem; resize: vertical; }
.select {
  appearance: none;
  padding-right: 2.5rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2345358D' stroke-width='2.5' 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 0.85rem center;
  background-size: 1.1rem;
}
.input:hover, .select:hover, .textarea:hover { border-color: var(--graypurple-500); }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--purple-700); box-shadow: 0 0 0 3px var(--purple-200); }
.input:focus-visible, .select:focus-visible, .textarea:focus-visible { outline: none; }
.field.has-error .input, .field.has-error .select, .field.has-error .textarea { border-color: var(--color-error); }
.field.has-error .input:focus, .field.has-error .select:focus, .field.has-error .textarea:focus { box-shadow: 0 0 0 3px #F6CFCB; }
.field-error { margin: 0; color: var(--color-error); font-size: 0.9rem; font-weight: 600; display: flex; gap: 0.35rem; align-items: center; }
.field-error:empty { display: none; }
.field-error::before { content: ""; width: 0.95rem; height: 0.95rem; flex-shrink: 0; border-radius: 50%; background: var(--color-error) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round'%3E%3Cpath d='M12 7v6M12 17h.01'/%3E%3C/svg%3E") center / 0.8rem no-repeat; }

/* Status after submitting: a colored edge and a marker say which kind of message it is */
.form-status {
  position: relative;
  padding: var(--space-5) var(--space-5) var(--space-5) calc(var(--space-5) + 2.25rem);
  border: 1px solid var(--color-border);
  border-left: 5px solid var(--purple-700);
  border-radius: var(--radius-sm) var(--radius-lg) var(--radius-lg) var(--radius-sm);
  background: var(--purple-100);
}
.form-status:empty { display: none; }
.form-status::before {
  content: "";
  position: absolute;
  left: var(--space-5);
  top: calc(var(--space-5) + 0.15rem);
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 10px 10px 4px 4px;
  background: var(--purple-700) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M12 11v6M12 7h.01'/%3E%3C/svg%3E") center / 1rem no-repeat;
}
.form-status h3 { font-size: var(--step-1); margin-bottom: var(--space-2); }
.form-status p:last-child { margin-bottom: 0; }
.form-status--error { background: #FEF3F2; border-color: #F6CFCB; border-left-color: var(--color-error); }
.form-status--error::before { background-color: var(--color-error); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M12 7v6M12 17h.01'/%3E%3C/svg%3E"); }
.form-status--error h3 { color: var(--color-error); }
.form-status--success { background: var(--green-100); border-color: #B8E6CF; border-left-color: var(--green-700); }
.form-status--success::before { background-color: var(--green-700); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 12.5 4.5 4.5L19 7.5'/%3E%3C/svg%3E"); }
.form-status--success h3 { color: var(--color-success); }
.form-status--info h3 { color: var(--purple-700); }

.form-footer { display: flex; flex-wrap: wrap; gap: var(--space-4); align-items: center; }
.form-footer .hint { margin: 0; color: var(--color-muted); font-size: 0.9rem; max-width: 26rem; }
@media (max-width: 639px) { .form-footer .btn { width: 100%; } }

.contact-aside { display: grid; gap: var(--space-6); align-content: start; }
.contact-aside section { padding: var(--space-6); border-radius: var(--door-card); background: var(--mint-50); }
.contact-aside h2 { font-size: var(--step-1); }
.contact-aside ol, .contact-aside ul { margin: 0; color: var(--color-muted); }
.contact-aside p { color: var(--color-muted); }
.contact-aside > section > :last-child { margin-bottom: 0; }

/* Placeholder for missing business details */
.tbd {
  display: inline;
  padding: 0.05em 0.4em;
  border: 1.5px dashed var(--graypurple-500);
  border-radius: 4px;
  background: rgba(139, 133, 163, 0.08);
  color: var(--graypurple-700);
  font-size: 0.92em;
  font-weight: 600;
}
.section--dark .tbd, .site-footer .tbd { color: #CBC5E6; border-color: rgba(203, 197, 230, 0.6); background: rgba(255, 255, 255, 0.05); }

/* --------------------------------------------------------------------------
   Legal pages
   -------------------------------------------------------------------------- */

.legal { padding-block: var(--space-7) var(--section); }
.legal .prose h2 { font-size: var(--step-2); margin-top: var(--space-7); }
.legal .prose { max-width: 46rem; }
.legal .note { margin-bottom: var(--space-7); }

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

.site-footer {
  background: var(--purple-950);
  color: #CBC5E6;
  padding-block: var(--space-8) var(--space-6);
  font-size: 0.98rem;
}
.site-footer a { color: #E9E6F6; text-decoration: none; }
.site-footer a:hover { color: var(--green-300); text-decoration: underline; }
.site-footer :focus-visible { outline-color: var(--green-300); }
.footer-grid { display: grid; gap: var(--space-7) var(--space-6); }
@media (min-width: 720px) { .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1060px) { .footer-grid { grid-template-columns: minmax(0, 1.5fr) repeat(4, minmax(0, 1fr)); } }
.footer-brand img { width: 220px; height: auto; margin-bottom: var(--space-5); }
.footer-brand p { max-width: 22rem; }
.site-footer h2 { font: 700 1rem/1.3 var(--font-body); color: var(--white); margin-bottom: var(--space-4); }
.footer-links { margin: 0; padding: 0; list-style: none; }
.footer-links li + li { margin-top: 0.6rem; }
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--space-3);
  margin-top: var(--space-8);
  padding-top: var(--space-5);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 0.9rem;
}
.footer-bottom p { margin: 0; }

/* --------------------------------------------------------------------------
   Misc
   -------------------------------------------------------------------------- */

.error-page { padding-block: var(--section); min-height: 60vh; display: grid; align-items: center; }
.error-page h1 { max-width: 14ch; }

.two-col { display: grid; gap: var(--space-6) var(--space-8); }
@media (min-width: 900px) { .two-col { grid-template-columns: 1fr 1fr; } }

/* Phones: shorter pages without dropping content people came for */
@media (max-width: 639px) {
  .service-groups { gap: var(--space-6); }
  .service-group__intro { display: none; }
  .service-links a { padding-block: var(--space-3); }
  .process li { padding-bottom: var(--space-5); }
  .principles { gap: var(--space-6); }
  .principles__list { gap: var(--space-5); }
  .section-head p { font-size: 1.0625rem; }
  .stage { padding-block: var(--space-4); }
}

.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.center-cta { margin-top: var(--space-7); }

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

@media print {
  .site-header, .site-footer, .cta-band, .nav-toggle { display: none !important; }
  body { color: #000; }
}
