/* =========================================================
   Agile Bridge — shared styles
   ========================================================= */

:root {
  --paper: #EEF1F6;
  --paper-soft: #E0E6EF;
  --deep: #0A1B33;
  --deep-soft: #15273F;
  --ink: #0E1B30;
  --ink-soft: #3E4B61;
  --ink-quiet: #7B8494;
  --rule: #C4CBD6;
  --rule-soft: #D8DEE6;
  --accent: #1E4D8B;
  --accent-dark: #133461;
  --accent-bright: #5B9AE0;
  --glow-a: rgba(30, 77, 139, 0.28);
  --glow-b: rgba(91, 154, 224, 0.22);

  --max: 1280px;
  --pad: clamp(1.25rem, 4vw, 3rem);

  --f-display: "Fraunces", "Times New Roman", serif;
  --f-body: "Instrument Sans", -apple-system, "Segoe UI", sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, "Consolas", monospace;

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

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 17px;
  line-height: 1.55;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* subtle grain overlay for paper feel */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100;
  opacity: 0.35;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.06 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}

::selection { background: var(--accent); color: var(--paper); }

/* ---------- Layout ---------- */
.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
}

/* ---------- Header ---------- */
.site-header {
  padding: 1.25rem 0 1rem;
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--paper);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease);
}

.site-header.scrolled {
  border-color: var(--rule-soft);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  color: var(--ink);
}

.wordmark img {
  display: block;
  height: 192px;
  width: auto;
  /* crop the empty grey padding baked into the PNG */
  clip-path: inset(18% 8% 18% 8%);
  margin: -35px -23px;
  transition: transform 0.4s var(--ease);
}

.wordmark:hover img { transform: scale(1.03); }

.site-nav {
  display: flex;
  align-items: center;
  gap: 2.25rem;
}

.site-nav a {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  color: var(--ink-soft);
  text-decoration: none;
  letter-spacing: 0.02em;
  position: relative;
  padding-bottom: 2px;
  transition: color 0.2s var(--ease);
}

.site-nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s var(--ease);
}

.site-nav a:hover { color: var(--ink); }
.site-nav a:hover::after { transform: scaleX(1); }
.site-nav a.active { color: var(--ink); }
.site-nav a.active::after { transform: scaleX(1); background: var(--accent); }

/* mobile nav collapse */
@media (max-width: 640px) {
  .site-nav { gap: 1.1rem; }
  .site-nav a { font-size: 0.7rem; }
  .wordmark img { height: 128px; margin: -23px -15px; }
}

/* ---------- Meta labels / section numbers ---------- */
.meta {
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-quiet);
}

.meta .idx {
  color: var(--accent);
}

/* ---------- Rule / bridge ---------- */
.rule {
  height: 1px;
  background: var(--rule);
  width: 100%;
  transform-origin: left;
  animation: ruleGrow 0.9s var(--ease) both;
}

.rule.accent { background: var(--accent); }
.rule.short { width: 48px; }

@keyframes ruleGrow {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}

/* ---------- Hero ---------- */
.hero {
  padding-top: clamp(3rem, 6vw, 5rem);
  padding-bottom: clamp(2rem, 4vw, 3.5rem);
  position: relative;
  overflow: hidden;
  min-height: 58vh;
  display: flex;
  align-items: center;
}

.hero .wrap { position: relative; z-index: 2; width: 100%; }

.hero-atmosphere {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.hero-atmosphere::before,
.hero-atmosphere::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  will-change: transform;
}

.hero-atmosphere::before {
  width: 720px;
  height: 720px;
  background: radial-gradient(circle, var(--glow-a), transparent 62%);
  top: -20%;
  right: -10%;
  opacity: 0.85;
  animation: glowDrift 22s ease-in-out infinite alternate;
}

.hero-atmosphere::after {
  width: 560px;
  height: 560px;
  background: radial-gradient(circle, var(--glow-b), transparent 65%);
  bottom: -25%;
  left: -8%;
  opacity: 0.75;
  animation: glowDrift 28s ease-in-out infinite alternate-reverse;
}

@keyframes glowDrift {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(60px, -40px) scale(1.12); }
}

/* subtle architectural grid line pattern */
.hero-grid-bg {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(30, 77, 139, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(30, 77, 139, 0.04) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 900px) {
  .hero-grid {
    grid-template-columns: 2fr 1fr;
    gap: 3.5rem;
  }
}

.hero h1 {
  font-family: var(--f-display);
  font-weight: 400;
  font-variation-settings: "opsz" 144, "SOFT" 30, "WONK" 0;
  font-size: clamp(3rem, 9vw, 8.5rem);
  line-height: 0.96;
  letter-spacing: -0.035em;
  color: var(--ink);
  margin-top: 1rem;
}

.hero h1 em {
  font-style: italic;
  font-variation-settings: "opsz" 144, "SOFT" 100;
  color: var(--accent);
  position: relative;
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-bright) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-side {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 1rem;
  padding-top: 0.5rem;
}

.hero-side p {
  font-size: 1rem;
  color: var(--ink-soft);
  line-height: 1.6;
  max-width: 34ch;
}

/* Stagger reveal on load */
.reveal > * {
  opacity: 0;
  transform: translateY(14px);
  animation: revealUp 0.8s var(--ease) forwards;
}
.reveal > *:nth-child(1) { animation-delay: 0.05s; }
.reveal > *:nth-child(2) { animation-delay: 0.18s; }
.reveal > *:nth-child(3) { animation-delay: 0.32s; }
.reveal > *:nth-child(4) { animation-delay: 0.44s; }
.reveal > *:nth-child(5) { animation-delay: 0.56s; }

@keyframes revealUp {
  to { opacity: 1; transform: translateY(0); }
}

/* ---------- Section frame ---------- */
section {
  padding-top: clamp(1.75rem, 3.5vw, 2.75rem);
  padding-bottom: clamp(1.75rem, 3.5vw, 2.75rem);
}

.section-head {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

@media (min-width: 900px) {
  .section-head {
    grid-template-columns: 180px 1fr;
    gap: 2.5rem;
    align-items: baseline;
  }
}

.section-head h2 {
  font-family: var(--f-display);
  font-weight: 400;
  font-variation-settings: "opsz" 96, "SOFT" 20;
  font-size: clamp(1.8rem, 4vw, 2.85rem);
  line-height: 1.1;
  letter-spacing: -0.015em;
  color: var(--ink);
  max-width: 22ch;
}

.section-head h2 em {
  font-style: italic;
  color: var(--accent);
}

/* ---------- Practice blocks (Home) ---------- */
.practices {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border-top: 1px solid var(--rule);
}

.practice {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--rule);
  position: relative;
  text-decoration: none;
  color: var(--ink);
  transition: background 0.4s var(--ease);
}

@media (min-width: 900px) {
  .practice {
    grid-template-columns: 1.1fr 1.3fr 80px;
    gap: 2rem;
    align-items: start;
    padding: 1.75rem 0;
  }
}

.practice::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0;
  background: var(--accent);
  transition: width 0.5s var(--ease);
}

.practice:hover {
  background: linear-gradient(90deg, rgba(30,77,139,0.04), rgba(91,154,224,0.06) 50%, transparent);
}

.practice:hover::before { width: 3px; }

.practice:hover .practice-title { transform: translateX(8px); }
.practice:hover .practice-arrow {
  transform: translate(8px, -8px) rotate(-8deg);
  color: var(--accent);
}

.practice-title {
  transition: transform 0.45s var(--ease);
}
.practice-arrow {
  transition: transform 0.45s var(--ease), color 0.35s var(--ease);
}

.practice-title {
  font-family: var(--f-display);
  font-weight: 400;
  font-variation-settings: "opsz" 96, "SOFT" 20;
  font-size: clamp(1.75rem, 3.6vw, 2.6rem);
  line-height: 1.08;
  letter-spacing: -0.015em;
  color: var(--ink);
}

.practice-title em {
  font-style: italic;
  color: var(--accent);
}

.practice-blurb {
  color: var(--ink-soft);
  font-size: 1.02rem;
  line-height: 1.6;
  max-width: 52ch;
}

.practice-arrow {
  font-family: var(--f-display);
  font-size: 2rem;
  line-height: 1;
  color: var(--ink);
  transition: transform 0.35s var(--ease);
  align-self: start;
  justify-self: end;
}

/* ---------- Principles list ---------- */
.principles {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border-top: 1px solid var(--rule);
}

@media (min-width: 700px) {
  .principles { grid-template-columns: 1fr 1fr; }
}

.principle {
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--rule);
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.5rem;
  align-items: start;
  position: relative;
}

.principle::before {
  content: "";
  display: block;
  width: 24px;
  height: 2px;
  background: var(--accent);
  margin-bottom: 0.25rem;
}

@media (min-width: 700px) {
  .principle {
    padding: 1.35rem 2.25rem 1.35rem 0;
  }
  .principle:nth-child(even) {
    padding-right: 0;
    padding-left: 2.25rem;
    border-left: 1px solid var(--rule);
  }
}

.principle-num {
  font-family: var(--f-mono);
  font-size: 0.75rem;
  color: var(--accent);
  letter-spacing: 0.05em;
  padding-top: 0.35rem;
}

.principle h3 {
  font-family: var(--f-display);
  font-weight: 500;
  font-size: 1.35rem;
  line-height: 1.2;
  margin-bottom: 0.6rem;
  letter-spacing: -0.01em;
}

.principle p {
  color: var(--ink-soft);
  font-size: 0.98rem;
  line-height: 1.6;
}

/* ---------- Areas grid (data / automation pages) ---------- */
.areas {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border-top: 1px solid var(--rule);
}

.area {
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--rule);
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
}

@media (min-width: 900px) {
  .area {
    grid-template-columns: 1fr 1.2fr;
    gap: 2.5rem;
    padding: 1.5rem 0;
    align-items: baseline;
  }
}

.area::before {
  content: "";
  display: block;
  width: 24px;
  height: 2px;
  background: var(--accent);
  grid-column: 1 / -1;
  margin-bottom: 0.1rem;
}

.area-label {
  font-family: var(--f-mono);
  font-size: 0.75rem;
  color: var(--ink-quiet);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.area-label .idx { color: var(--accent); }

.area h3 {
  font-family: var(--f-display);
  font-weight: 500;
  font-variation-settings: "opsz" 72, "SOFT" 20;
  font-size: clamp(1.4rem, 2.4vw, 1.85rem);
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--ink);
}

.area h3 em {
  font-style: italic;
  color: var(--accent);
}

.area p {
  color: var(--ink-soft);
  font-size: 1rem;
  line-height: 1.65;
  max-width: 52ch;
}

/* ---------- Body prose ---------- */
.prose p {
  font-size: 1.08rem;
  line-height: 1.65;
  color: var(--ink-soft);
  max-width: 62ch;
  margin-bottom: 1.25rem;
}

.prose p strong { color: var(--ink); font-weight: 500; }
.prose p em { color: var(--accent); font-style: italic; font-family: var(--f-display); }

/* ---------- Pull quote / principle statement ---------- */
.pullquote {
  margin: clamp(1.5rem, 3vw, 2.25rem) 0;
  padding: clamp(1.25rem, 2.5vw, 2rem) 0;
  border-top: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
  position: relative;
}

.pullquote-mark {
  position: absolute;
  top: -0.9rem;
  left: 0;
  background: var(--paper);
  padding-right: 1rem;
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
}

.pullquote p {
  font-family: var(--f-display);
  font-weight: 400;
  font-variation-settings: "opsz" 120, "SOFT" 50;
  font-size: clamp(1.5rem, 3.6vw, 2.4rem);
  line-height: 1.2;
  letter-spacing: -0.015em;
  color: var(--ink);
  max-width: 28ch;
}

.pullquote p em {
  font-style: italic;
  color: var(--accent);
}

/* ---------- Dark section ---------- */
.dark {
  background: var(--deep);
  color: var(--paper);
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.dark::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 70% at 80% 15%, rgba(91,154,224,0.28), transparent 60%),
    radial-gradient(ellipse 60% 70% at 10% 85%, rgba(30,77,139,0.35), transparent 55%);
  pointer-events: none;
  z-index: 0;
}

.dark::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse at center, #000 20%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at center, #000 20%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.dark .wrap { position: relative; z-index: 1; }
.dark .meta { color: rgba(255,255,255,0.55); }
.dark .meta .idx { color: var(--accent-bright); }
.dark h2 em,
.dark h1 em { color: var(--accent-bright); background: none; -webkit-text-fill-color: currentColor; }
.dark .rule { background: rgba(255,255,255,0.2); }
.dark .rule.accent { background: var(--accent-bright); }

/* ---------- CTA block ---------- */
.cta {
  padding: clamp(2.5rem, 5vw, 4rem) 0 clamp(3rem, 5.5vw, 4.5rem);
  border-top: 1px solid transparent;
}

.cta.dark {
  border-top: none;
}

.cta.dark h2 {
  color: var(--paper);
}

.cta.dark h2 em {
  color: var(--accent-bright);
  background: none;
  -webkit-text-fill-color: currentColor;
}

.cta-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.75rem;
  align-items: end;
}

@media (min-width: 900px) {
  .cta-grid {
    grid-template-columns: 1fr auto;
    gap: 3rem;
  }
}

.cta h2 {
  font-family: var(--f-display);
  font-weight: 400;
  font-variation-settings: "opsz" 144, "SOFT" 40;
  font-size: clamp(2.2rem, 5.5vw, 4.25rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
  max-width: 14ch;
}

.cta h2 em {
  font-style: italic;
  color: var(--accent);
}

.email-link {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--f-display);
  font-size: clamp(1.1rem, 2vw, 1.5rem);
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
  padding: 1.1rem 1.75rem 1.1rem 2rem;
  border: 1px solid var(--ink);
  border-radius: 999px;
  background: transparent;
  transition: background 0.35s var(--ease), color 0.35s var(--ease), transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
  white-space: nowrap;
  position: relative;
}

.email-link .arrow {
  display: inline-block;
  transition: transform 0.35s var(--ease);
}

.email-link:hover {
  background: var(--ink);
  color: var(--paper);
  transform: translateY(-3px);
  box-shadow: 0 20px 50px -20px var(--accent);
}
.email-link:hover .arrow { transform: translate(4px, -4px); }

.dark .email-link {
  color: var(--paper);
  border-color: var(--paper);
  background: rgba(255,255,255,0.04);
  backdrop-filter: blur(4px);
  box-shadow: 0 0 0 0 var(--accent-bright);
}

.dark .email-link:hover {
  background: var(--paper);
  color: var(--deep);
  box-shadow: 0 20px 60px -15px var(--accent-bright), 0 0 40px -5px rgba(91,154,224,0.5);
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--rule);
  padding: 1.75rem 0 1.5rem;
}

.site-footer .wrap {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

@media (min-width: 700px) {
  .site-footer .wrap {
    grid-template-columns: 1fr 1fr 1fr;
    align-items: end;
  }
}

.footer-wordmark {
  font-family: var(--f-display);
  font-weight: 500;
  font-size: 1rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink);
}

.footer-tag {
  font-family: var(--f-mono);
  font-size: 0.75rem;
  color: var(--ink-quiet);
  letter-spacing: 0.03em;
}

.footer-mail {
  font-family: var(--f-mono);
  font-size: 0.8rem;
  color: var(--ink-soft);
  text-decoration: none;
  justify-self: start;
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s var(--ease), color 0.2s var(--ease);
}
.footer-mail:hover { color: var(--ink); border-color: var(--ink); }

@media (min-width: 700px) {
  .footer-mail { justify-self: end; }
  .footer-tag { text-align: center; }
}

/* ---------- Page intro (internal pages) ---------- */
.page-intro {
  padding-top: clamp(2.5rem, 4.5vw, 3.75rem);
  padding-bottom: clamp(1.75rem, 3vw, 2.5rem);
  position: relative;
  overflow: hidden;
  min-height: 44vh;
  display: flex;
  align-items: center;
}

.page-intro .wrap { position: relative; z-index: 2; width: 100%; }

.page-intro .meta {
  margin-bottom: 1.25rem;
}

.page-intro h1 {
  font-family: var(--f-display);
  font-weight: 400;
  font-variation-settings: "opsz" 144, "SOFT" 30;
  font-size: clamp(2.8rem, 8vw, 6.5rem);
  line-height: 0.98;
  letter-spacing: -0.03em;
  margin-bottom: 1.25rem;
  max-width: 14ch;
}

.page-intro h1 em {
  font-style: italic;
  font-variation-settings: "opsz" 144, "SOFT" 100;
  color: var(--accent);
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-bright) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.page-intro-lede {
  font-size: 1.2rem;
  line-height: 1.55;
  color: var(--ink-soft);
  max-width: 58ch;
  font-weight: 400;
}

.page-intro-lede em {
  font-style: italic;
  color: var(--accent);
  font-family: var(--f-display);
}

/* ---------- Contact page ---------- */
.contact-main {
  padding-top: clamp(2.5rem, 5vw, 4rem);
  padding-bottom: clamp(2rem, 4vw, 3rem);
  min-height: 50vh;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
}

.contact-main .wrap { position: relative; z-index: 2; }

.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 900px) {
  .contact-grid {
    grid-template-columns: 1.2fr 1fr;
    gap: 3.5rem;
  }
}

.contact-heading h1 {
  font-family: var(--f-display);
  font-weight: 400;
  font-variation-settings: "opsz" 144, "SOFT" 40;
  font-size: clamp(3.2rem, 9vw, 7rem);
  line-height: 0.96;
  letter-spacing: -0.035em;
  margin-bottom: 1.25rem;
}

.contact-heading h1 em {
  font-style: italic;
  font-variation-settings: "opsz" 144, "SOFT" 100;
  color: var(--accent);
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-bright) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.contact-heading p {
  color: var(--ink-soft);
  font-size: 1.1rem;
  line-height: 1.55;
  max-width: 42ch;
  margin-bottom: 1.75rem;
}

.contact-email-block {
  padding: 1.5rem 0;
  border-top: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
  display: grid;
  gap: 0.75rem;
}

.contact-email-block .meta { color: var(--accent); }

.contact-email {
  font-family: var(--f-display);
  font-size: clamp(1.6rem, 4vw, 2.6rem);
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.01em;
  position: relative;
  align-self: start;
  justify-self: start;
  word-break: break-all;
}

.contact-email::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 2px;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s var(--ease);
}
.contact-email:hover::after { transform: scaleX(1); }

.contact-aside h3 {
  font-family: var(--f-mono);
  font-size: 0.75rem;
  color: var(--ink-quiet);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.contact-aside ul {
  list-style: none;
  display: grid;
  gap: 0.65rem;
}

.contact-aside li {
  padding-left: 1.25rem;
  position: relative;
  color: var(--ink-soft);
  line-height: 1.55;
  font-size: 1rem;
}

.contact-aside li::before {
  content: "—";
  position: absolute;
  left: 0;
  color: var(--accent);
}

/* ---------- Infographics ---------- */
.figure {
  padding-top: clamp(0.5rem, 1vw, 1rem);
  padding-bottom: clamp(0.5rem, 1vw, 1rem);
}

.figure-frame {
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding: clamp(1rem, 2vw, 1.5rem) 0;
  position: relative;
}

.figure-frame .caption {
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-quiet);
  margin-bottom: 0.75rem;
  display: flex;
  gap: 0.5rem;
  align-items: center;
}
.figure-frame .caption .idx { color: var(--accent); }

.concept-strip,
.dashboard-mock,
.process-flow {
  width: 100%;
  height: auto;
  display: block;
  color: var(--ink-soft);
}

/* Dots scatter */
.svg-scatter circle {
  opacity: 0;
  animation: dotFade 0.5s var(--ease) forwards;
}
.svg-scatter circle:nth-child(1)  { animation-delay: 0.10s; }
.svg-scatter circle:nth-child(2)  { animation-delay: 0.16s; }
.svg-scatter circle:nth-child(3)  { animation-delay: 0.22s; }
.svg-scatter circle:nth-child(4)  { animation-delay: 0.28s; }
.svg-scatter circle:nth-child(5)  { animation-delay: 0.34s; }
.svg-scatter circle:nth-child(6)  { animation-delay: 0.40s; }
.svg-scatter circle:nth-child(7)  { animation-delay: 0.46s; }
.svg-scatter circle:nth-child(8)  { animation-delay: 0.52s; }
.svg-scatter circle:nth-child(9)  { animation-delay: 0.58s; }
.svg-scatter circle:nth-child(10) { animation-delay: 0.64s; }
.svg-scatter circle:nth-child(11) { animation-delay: 0.70s; }
.svg-scatter circle:nth-child(12) { animation-delay: 0.76s; }
.svg-scatter circle:nth-child(13) { animation-delay: 0.82s; }
.svg-scatter circle:nth-child(14) { animation-delay: 0.88s; }

@keyframes dotFade {
  to { opacity: 0.55; }
}

/* Sparkline draw-in */
.svg-sparkline {
  stroke-dasharray: 1200;
  stroke-dashoffset: 1200;
  animation: drawLine 2s var(--ease) forwards 0.3s;
}
@keyframes drawLine {
  to { stroke-dashoffset: 0; }
}

.svg-sparkdot {
  opacity: 0;
  animation: dotFade 0.4s var(--ease) forwards;
}
.svg-sparkdot:nth-of-type(1) { animation-delay: 0.6s; }
.svg-sparkdot:nth-of-type(2) { animation-delay: 0.8s; }
.svg-sparkdot:nth-of-type(3) { animation-delay: 1.0s; }
.svg-sparkdot:nth-of-type(4) { animation-delay: 1.2s; }
.svg-sparkdot:nth-of-type(5) { animation-delay: 1.4s; }
.svg-sparkdot:nth-of-type(6) { animation-delay: 1.6s; }
.svg-sparkdot:nth-of-type(7) { animation-delay: 1.8s; }

/* Nodes */
.svg-node {
  opacity: 0;
  animation: nodeIn 0.5s var(--ease) forwards;
}
.svg-node:nth-of-type(1) { animation-delay: 1.3s; }
.svg-node:nth-of-type(2) { animation-delay: 1.5s; }
.svg-node:nth-of-type(3) { animation-delay: 1.7s; }
.svg-node:nth-of-type(4) { animation-delay: 1.9s; }
.svg-node:nth-of-type(5) { animation-delay: 2.1s; }

@keyframes nodeIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Dashboard bars: grow up */
.svg-bar {
  transform-origin: bottom;
  transform: scaleY(0);
  animation: barGrow 0.8s var(--ease) forwards;
}
.svg-bar:nth-of-type(1) { animation-delay: 0.3s; }
.svg-bar:nth-of-type(2) { animation-delay: 0.4s; }
.svg-bar:nth-of-type(3) { animation-delay: 0.5s; }
.svg-bar:nth-of-type(4) { animation-delay: 0.6s; }
.svg-bar:nth-of-type(5) { animation-delay: 0.7s; }
.svg-bar:nth-of-type(6) { animation-delay: 0.8s; }
.svg-bar:nth-of-type(7) { animation-delay: 0.9s; }

@keyframes barGrow {
  to { transform: scaleY(1); }
}

/* KPI tile reveal */
.svg-tile {
  opacity: 0;
  animation: tileIn 0.6s var(--ease) forwards;
}
.svg-tile:nth-of-type(1) { animation-delay: 0.1s; }
.svg-tile:nth-of-type(2) { animation-delay: 0.2s; }
.svg-tile:nth-of-type(3) { animation-delay: 0.3s; }

@keyframes tileIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Subtle live pulse on one KPI dot */
.svg-pulse {
  animation: pulse 2.2s ease-in-out infinite;
  transform-origin: center;
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: 0.4; transform: scale(1.5); }
}

/* Flow connecting line draws in */
.svg-flowline {
  stroke-dasharray: 1400;
  stroke-dashoffset: 1400;
  animation: drawLine 1.8s var(--ease) forwards 0.1s;
}

/* Marching-ants flow (source to destination) */
.svg-flowline-a {
  stroke-dasharray: 5 5;
  animation: flowMarch 4s linear infinite;
}
@keyframes flowMarch {
  to { stroke-dashoffset: -40; }
}

/* Pulse ring at the gather point */
.svg-gather-ring {
  transform-origin: center;
  animation: gatherPulse 2.4s ease-in-out infinite;
}
@keyframes gatherPulse {
  0%, 100% { opacity: 0.4; transform: scale(1); }
  50%      { opacity: 0.1; transform: scale(1.5); }
}

/* Honour reduced motion */
@media (prefers-reduced-motion: reduce) {
  .svg-scatter circle,
  .svg-sparkline,
  .svg-sparkdot,
  .svg-node,
  .svg-bar,
  .svg-tile,
  .svg-flowline {
    animation: none !important;
    opacity: 1;
    stroke-dashoffset: 0;
    transform: none;
  }
  .svg-pulse { animation: none !important; }
}

/* ---------- Image break (full-bleed photography) ---------- */
.image-break {
  padding: 0;
  margin: clamp(0.75rem, 1.5vw, 1.5rem) 0;
}

.image-break figure {
  position: relative;
  margin: 0;
  aspect-ratio: 21 / 9;
  overflow: hidden;
  background: var(--deep);
}

@media (max-width: 700px) {
  .image-break figure { aspect-ratio: 4 / 3; }
}

.image-break img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(0.82) brightness(0.88);
  transition: transform 1.2s var(--ease), filter 0.6s var(--ease);
}

.image-break:hover img {
  transform: scale(1.03);
  filter: saturate(0.95) brightness(0.95);
}

/* blue wash + vignette gradient */
.image-break figure::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10,27,51,0.1) 0%, rgba(10,27,51,0.55) 100%);
  z-index: 1;
  pointer-events: none;
}

.image-break figure::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(30, 77, 139, 0.18);
  mix-blend-mode: multiply;
  z-index: 1;
  pointer-events: none;
}

.image-break figcaption {
  position: absolute;
  inset: auto 0 0 0;
  z-index: 2;
  padding: clamp(1.5rem, 3vw, 2.5rem);
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 2rem;
  color: var(--paper);
}

@media (max-width: 700px) {
  .image-break figcaption { flex-direction: column; align-items: flex-start; gap: 1rem; }
}

.image-break .caption-quote {
  font-family: var(--f-display);
  font-weight: 400;
  font-variation-settings: "opsz" 120, "SOFT" 40;
  font-size: clamp(1.4rem, 3vw, 2.2rem);
  line-height: 1.15;
  letter-spacing: -0.015em;
  max-width: 28ch;
}

.image-break .caption-quote em {
  font-style: italic;
  color: var(--accent-bright);
}

.image-break .caption-meta {
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.7);
  text-align: right;
  line-height: 1.6;
  flex-shrink: 0;
}

.image-break .caption-meta .idx { color: var(--accent-bright); }

/* Small corner marks on the photo frame */
.image-break figure > .corner {
  position: absolute;
  width: 20px;
  height: 20px;
  border-color: var(--accent-bright);
  pointer-events: none;
  z-index: 3;
}
.image-break figure > .corner.tl { top: 14px; left: 14px; border-top: 2px solid; border-left: 2px solid; }
.image-break figure > .corner.br { bottom: 14px; right: 14px; border-bottom: 2px solid; border-right: 2px solid; }

/* ---------- Scroll reveals ---------- */
.will-reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}
.will-reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .will-reveal { opacity: 1 !important; transform: none !important; }
  .hero-atmosphere::before,
  .hero-atmosphere::after { animation: none !important; }
}

/* ---------- Frame corner marks on figures ---------- */
.figure-frame {
  position: relative;
}
.figure-frame::before,
.figure-frame::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  border-color: var(--accent);
  pointer-events: none;
}
.figure-frame::before {
  top: -1px; left: 0;
  border-top: 2px solid;
  border-left: 2px solid;
}
.figure-frame::after {
  bottom: -1px; right: 0;
  border-bottom: 2px solid;
  border-right: 2px solid;
}

/* ---------- Misc ---------- */
.noscript-fallback .reveal > * { opacity: 1; transform: none; animation: none; }
