/* ==========================================================================
   Grow With Abdul Rehman — growwithabdulrehman.com
   Single-page portfolio. Mobile-first. No frameworks.

   Contents
   01. Design tokens
   02. Reset & base
   03. Layout primitives (container, section, section heads)
   04. Typography helpers
   05. Buttons & links
   06. Header / navigation
   07. Hero (copy + portrait)
   08. Problems I Solve
   09. What I Build
   10. Selected Work (dark): screenshot galleries + lightbox
   11. Why work with me
   12. Technology stack
   13. Process timeline
   14. About (short)
   15. Final CTA
   16. Footer
   17. Reveal animations & reduced motion
   ========================================================================== */

/* ==========================================================================
   01. DESIGN TOKENS
   Change the brand colour in one place.
   ========================================================================== */
:root {
  /* Brand */
  --brand:        #008000;
  --brand-hover:  #006b00;
  --brand-press:  #005700;
  --brand-tint:   #e8f3e8;
  --brand-tint-2: #f3f8f3;
  --brand-ring:   rgba(0, 128, 0, 0.26);
  --brand-glow:   #5fc25f;   /* the brand colour, lightened for use on dark surfaces */

  /* Neutrals (very slightly green-tinted so they sit with the brand) */
  --ink:         #0d130f;
  --ink-soft:    #27312b;
  --muted:       #56615a;    /* 6:1 on white */
  --muted-2:     #66716a;    /* 4.7:1 on the alt background */
  --line:        #e1e7e2;
  --line-soft:   #edf1ee;
  --line-strong: #cfd9d1;
  --bg:          #ffffff;
  --bg-alt:      #f6f8f6;

  /* Dark surfaces */
  --dark:        #0b100d;
  --dark-2:      #111813;
  --dark-line:   rgba(255, 255, 255, 0.11);
  --dark-muted:  rgba(255, 255, 255, 0.7);

  /* Type: one neutral sans for text, its tighter display cut for headings. */
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-head: "Inter Tight", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  /* Radii & shadow */
  --r-sm: 6px;
  --r-md: 8px;
  --r-lg: 12px;
  --r-xl: 14px;
  --shadow-sm: 0 1px 2px rgba(13, 19, 15, 0.05);
  --shadow-md: 0 10px 28px -14px rgba(13, 19, 15, 0.22);
  --shadow-lg: 0 30px 70px -34px rgba(13, 19, 15, 0.38);

  /* Rhythm */
  --container: 1160px;
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --section-y: clamp(3.5rem, 8vw, 7rem);
  --header-h: 68px;

  /* Motion */
  --ease: cubic-bezier(0.22, 0.8, 0.3, 1);
  --t-fast: 0.18s;
  --t-med: 0.32s;

  /* 3D depth: the local perspective distance used wherever a tilt or
     parallax transform is applied (CSS and JS share this number). */
  --tilt-depth: 1000px;
}

/* ==========================================================================
   02. RESET & BASE
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 12px);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.65;
  font-feature-settings: "cv11", "ss03";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

body.nav-open { overflow: hidden; }

h1, h2, h3, h4 {
  margin: 0 0 0.5em;
  font-family: var(--font-head);
  line-height: 1.12;
  letter-spacing: -0.005em;
  font-weight: 600;
  color: var(--ink);
  text-wrap: balance;
}

p { margin: 0 0 1rem; }
p:last-child { margin-bottom: 0; }

ul, ol, dl, dd { margin: 0; padding: 0; }
li { list-style: none; }

img, svg { display: block; max-width: 100%; }
img { height: auto; }

a { color: inherit; text-decoration: none; }

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 3px;
  border-radius: 4px;
}
.section-dark :focus-visible { outline-color: #fff; }

.skip-link {
  position: absolute;
  left: 50%;
  top: 0;
  transform: translate(-50%, -120%);
  z-index: 200;
  padding: 0.6rem 1.1rem;
  background: var(--ink);
  color: #fff;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0 0 var(--r-sm) var(--r-sm);
  transition: transform var(--t-fast) var(--ease);
}
.skip-link:focus { transform: translate(-50%, 0); }

/* Inline SVG sprite lives at the top of <body>. */
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

/* Default size for icons that use the sprite. */
.ico { width: 20px; height: 20px; flex: none; }

/* ==========================================================================
   03. LAYOUT PRIMITIVES
   ========================================================================== */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Anchor offset comes from scroll-padding-top on <html>. Adding scroll-margin
   here as well would apply both and overshoot by the header height. */
.section { padding-block: var(--section-y); }

.section-alt { background: var(--bg-alt); }

.section-dark {
  position: relative;
  background: var(--dark);
  color: #fff;
}
.section-dark h1, .section-dark h2, .section-dark h3 { color: #fff; }

.sec-head {
  max-width: 44rem;
  margin-bottom: clamp(2.25rem, 4.5vw, 3.5rem);
}

/* ==========================================================================
   04. TYPOGRAPHY HELPERS
   ========================================================================== */
.kicker {
  margin: 0 0 0.85rem;
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0;
  color: var(--brand);
}
.section-dark .kicker { color: var(--brand-glow); }

.sec-head h2,
.why-head h2,
.about-copy h2,
.cta h2 {
  font-size: clamp(1.875rem, 1.2rem + 2.3vw, 2.875rem);
  letter-spacing: -0.012em;
  line-height: 1.1;
}

.sec-intro {
  margin-top: 1rem;
  max-width: 34rem;
  font-size: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
  line-height: 1.6;
  color: var(--muted);
}
.section-dark .sec-intro { color: var(--dark-muted); }

.eyebrow {
  margin: 0 0 1.1rem;
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: 0;
  color: var(--brand);
}

.dot { color: var(--brand); padding-inline: 0.2em; }

.hl { color: var(--brand); }

/* ==========================================================================
   05. BUTTONS & LINKS
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.8rem 1.4rem;
  border: 1px solid transparent;
  border-radius: var(--r-md);
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: -0.005em;
  white-space: nowrap;
  cursor: pointer;
  transform-origin: 50% 100%;
  transition: background var(--t-fast) var(--ease),
              border-color var(--t-fast) var(--ease),
              color var(--t-fast) var(--ease),
              transform var(--t-fast) var(--ease),
              box-shadow var(--t-fast) var(--ease);
}
.btn .ico { width: 18px; height: 18px; transition: transform var(--t-fast) var(--ease); }
.btn:hover .ico { transform: translateX(3px); }

.btn-primary {
  background: var(--brand);
  color: #fff;
  box-shadow: 0 1px 2px rgba(0, 80, 0, 0.2);
}
.btn-primary:hover {
  background: var(--brand-hover);
  transform: translateY(-1px) perspective(var(--tilt-depth)) rotateX(-4deg);
  box-shadow: 0 10px 22px -10px rgba(0, 110, 0, 0.6);
}
.btn-primary:active { background: var(--brand-press); transform: translateY(0) perspective(var(--tilt-depth)) rotateX(0deg); }

/* A soft breathing glow on the two main calls to action (not the small header
   one, which is on screen too constantly for a pulse to stay pleasant). */
.btn-primary.btn-lg, .btn-primary.btn-xl { animation: btnGlow 2.8s ease-in-out infinite; }
.btn-primary.btn-lg:hover, .btn-primary.btn-xl:hover,
.btn-primary.btn-lg:active, .btn-primary.btn-xl:active { animation: none; }
@keyframes btnGlow {
  0%, 100% { box-shadow: 0 1px 2px rgba(0, 80, 0, 0.2), 0 0 0 0 rgba(0, 128, 0, 0.35); }
  50%      { box-shadow: 0 1px 2px rgba(0, 80, 0, 0.2), 0 0 16px 4px rgba(0, 128, 0, 0.28); }
}

.btn-ghost {
  background: #fff;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); transform: translateY(-1px) perspective(var(--tilt-depth)) rotateX(-4deg); }
.btn-ghost:active { transform: translateY(0) perspective(var(--tilt-depth)) rotateX(0deg); }

.btn-sm { padding: 0.55rem 1rem; font-size: 0.875rem; border-radius: var(--r-md); }
.btn-lg { padding: 0.95rem 1.65rem; font-size: 1rem; }
.btn-xl { padding: 1.1rem 2rem; font-size: 1.0625rem; border-radius: 10px; }

.section-dark .btn-primary:hover { background: #0a950a; }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--brand);
}
.link-arrow .ico { width: 18px; height: 18px; transition: transform var(--t-fast) var(--ease); }
.link-arrow:hover .ico { transform: translateX(4px); }

/* ==========================================================================
   06. HEADER / NAVIGATION
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  /* Above .nav-backdrop: the header is a stacking context, so the drawer
     nested inside it cannot outrank the backdrop on its own. */
  z-index: 110;
  /* Deliberately a solid background, not backdrop-filter: a filtered header
     becomes the containing block for the fixed mobile drawer inside it,
     which collapses the drawer to the header's own height. */
  background: #fff;
  border-bottom: 1px solid transparent;
  transition: border-color var(--t-med) var(--ease), box-shadow var(--t-med) var(--ease);
}
.site-header.is-scrolled {
  border-bottom-color: var(--line);
  box-shadow: 0 1px 12px -6px rgba(13, 19, 15, 0.16);
}

.nav-inner {
  min-height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  flex: none;
}
.brand-mark { width: 40px; height: 40px; flex: none; transition: transform var(--t-fast) var(--ease); }
.brand:hover .brand-mark { transform: perspective(var(--tilt-depth)) rotateY(14deg) scale(1.05); }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-pre { font-size: 0.75rem; font-weight: 500; letter-spacing: 0.01em; color: var(--muted); }
.brand-name {
  font-family: var(--font-head);
  font-size: 1.1875rem;
  font-weight: 700;
  letter-spacing: -0.005em;
  color: var(--ink);
}

/* --- Mobile drawer (default) --- */
.nav {
  position: fixed;
  inset: 0 0 0 auto;
  width: min(86vw, 340px);
  z-index: 110;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: calc(var(--header-h) + 1.5rem) 1.5rem 2rem;
  background: #fff;
  border-left: 1px solid var(--line);
  box-shadow: var(--shadow-lg);
  transform: translateX(101%);
  visibility: hidden;
  transition: transform var(--t-med) var(--ease), visibility var(--t-med) linear;
}
.nav.is-open { transform: translateX(0); visibility: visible; }

.nav-list { display: flex; flex-direction: column; }
.nav-link {
  display: block;
  padding: 0.85rem 0;
  font-size: 1.0625rem;
  font-weight: 500;
  color: var(--ink-soft);
  border-bottom: 1px solid var(--line-soft);
  transition: color var(--t-fast) var(--ease);
}
.nav-link:hover, .nav-link.is-active { color: var(--brand); }

.nav-cta { margin-top: 1.5rem; align-self: stretch; }

.nav-toggle {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-right: -8px;
  border-radius: var(--r-md);
  color: var(--ink);
  z-index: 120;
  transition: background var(--t-fast) var(--ease);
}
.nav-toggle:hover { background: var(--brand-tint); }
.nav-toggle-bars { display: block; width: 20px; height: 14px; position: relative; }
.nav-toggle-bars i {
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform var(--t-med) var(--ease), opacity var(--t-fast) var(--ease);
}
.nav-toggle-bars i:nth-child(1) { top: 0; }
.nav-toggle-bars i:nth-child(2) { top: 6px; }
.nav-toggle-bars i:nth-child(3) { top: 12px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars i:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars i:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars i:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.nav-backdrop {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(13, 19, 15, 0.42);
  opacity: 0;
  transition: opacity var(--t-med) var(--ease);
}
.nav-backdrop.is-open { opacity: 1; }

/* --- Desktop nav --- */
@media (min-width: 940px) {
  .nav {
    position: static;
    width: auto;
    flex-direction: row;
    align-items: center;
    gap: 1.75rem;
    padding: 0;
    background: none;
    border: 0;
    box-shadow: none;
    transform: none;
    visibility: visible;
  }
  .nav-list { flex-direction: row; gap: 1.4rem; }
  .nav-link {
    position: relative;
    padding: 0.35rem 0;
    font-size: 0.9375rem;
    border-bottom: 0;
    color: var(--muted);
  }
  .nav-link::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 100%;
    height: 2px;
    background: var(--brand);
    border-radius: 2px;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--t-med) var(--ease);
  }
  .nav-link.is-active { color: var(--ink); }
  .nav-link.is-active::after, .nav-link:hover::after { transform: scaleX(1); }
  .nav-cta { margin: 0; align-self: auto; }
  .nav-toggle { display: none; }
  .nav-backdrop { display: none; }
}
@media (min-width: 1100px) {
  .nav { gap: 2.25rem; }
  .nav-list { gap: 1.9rem; }
}

/* ==========================================================================
   07. HERO
   Deliberately plain: type, the real photograph, one identity card.
   ========================================================================== */
.hero {
  padding-block: clamp(1.25rem, 5vw, 4.5rem) clamp(2.5rem, 8vw, 6.5rem);
  overflow: hidden;
}

/* Text left, portrait right, on every screen size: mobile keeps the same
   two columns as desktop (just narrower), so both are visible together
   as soon as the page opens, with no scrolling needed. */
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: clamp(0.75rem, 4vw, 4.5rem);
  align-items: center;
}

@media (min-width: 940px) {
  .hero-grid { grid-template-columns: minmax(0, 1.16fr) minmax(0, 0.84fr); }
}

.hero-title {
  margin: 0 0 1.25rem;
  max-width: 14em;
  font-size: clamp(2.375rem, 1rem + 3.7vw, 3.75rem);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.07;
}

.hero-sub {
  margin: 0 0 1.1rem;
  font-size: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  font-weight: 600;
  color: var(--ink-soft);
}

.hero-lead {
  max-width: 33rem;
  margin: 0 0 2.25rem;
  font-size: clamp(1.0625rem, 1rem + 0.35vw, 1.1875rem);
  line-height: 1.65;
  color: var(--muted);
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

/* Below 940px the hero is a narrow two-column row, so type and spacing
   scale down to fit both the copy and the portrait side by side.
   (Placed after the base rules above so it wins the cascade.) */
@media (max-width: 939px) {
  .hero-grid { align-items: start; }
  .eyebrow { font-size: 0.75rem; margin-bottom: 0.5rem; }
  .hero-title { font-size: clamp(1.25rem, 5.5vw, 1.875rem); margin-bottom: 0.6rem; line-height: 1.15; }
  .hero-sub { font-size: 0.8125rem; margin-bottom: 0.6rem; }
  .hero-lead { font-size: 0.8125rem; line-height: 1.5; margin-bottom: 1rem; }
  .hero-actions { flex-direction: column; align-items: stretch; gap: 0.6rem; }
  .hero-actions .btn { width: 100%; }
}

/* --- Portrait ---
   The photo is shot on a white background and used exactly as supplied. It is
   blended onto the tinted panel with multiply, so the white takes on the panel
   colour. Nothing is drawn on or around it. */
.hero-visual { display: flex; justify-content: center; }

.stage { position: relative; width: 100%; max-width: 360px; margin: 0 auto; }
.stage-fig { position: relative; margin: 0; }

.stage-frame {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  background: linear-gradient(165deg, #f8fbf8 0%, #e8f0e9 100%);
  box-shadow: var(--shadow-lg);
}
.stage-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: 50% 0;
  mix-blend-mode: multiply;
}

.stage-id {
  position: absolute;
  left: -16px;
  bottom: 28px;
  display: flex;
  flex-direction: column;
  padding: 0.8rem 1.2rem 0.8rem 1rem;
  background: #fff;
  border: 1px solid var(--line);
  border-left: 3px solid var(--brand);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-md);
}
.stage-id-name { font-size: 1.0625rem; font-weight: 600; letter-spacing: 0; color: var(--ink); line-height: 1.3; }
.stage-id-role { font-size: 0.875rem; font-weight: 500; color: var(--muted); }

/* On a fine pointer, main.js drives this card's tilt per animation frame
   (see .has-tilt). Everywhere else — touch devices above all — it gets a
   gentle ambient float instead, so the hero still carries a 3D feel without
   a mouse to drive it. An animation on `transform` outranks an inline style
   in the cascade, so the two must never run on the same device at once. */
html:not(.has-tilt) .stage-id { animation: floatCard 5.5s ease-in-out infinite; }
@keyframes floatCard {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-7px) rotate(1deg); }
}

@media (max-width: 939px) {
  .stage-id { left: -6px; bottom: 10px; padding: 0.45rem 0.6rem 0.45rem 0.55rem; }
  .stage-id-name { font-size: 0.6875rem; }
  .stage-id-role { font-size: 0.5625rem; }
}

/* ==========================================================================
   08. PROBLEMS I SOLVE
   One bordered panel divided into cells (no stack of separate rounded cards).
   ========================================================================== */
.problem-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1px;
  overflow: hidden;
  background: var(--line-strong);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-lg);
}
@media (min-width: 640px)  { .problem-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .problem-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.problem {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 1.1rem;
  align-items: start;
  padding: 1.5rem 1.4rem;
  background: #fff;
  transition: background var(--t-med) var(--ease);
}
/* A green rule draws across the top of the cell on hover. */
.problem::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 2px;
  background: var(--brand);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--t-med) var(--ease);
}
.problem:hover { background: #fbfdfb; }
.problem:hover::before { transform: scaleX(1); }

.problem-ico { color: var(--ink); transition: color var(--t-med) var(--ease); }
.problem-ico .ico { width: 26px; height: 26px; stroke-width: 1.5; }
.problem:hover .problem-ico { color: var(--brand); }

.problem h3 { margin-bottom: 0.4rem; font-size: 1.0625rem; font-weight: 600; letter-spacing: 0; line-height: 1.3; }
.problem p { margin: 0; font-size: 0.9375rem; line-height: 1.6; color: var(--muted); }

@media (min-width: 1024px) {
  .problem { display: block; min-height: 15rem; padding: 1.9rem 1.7rem 2rem; }
  .problem-ico { margin-bottom: 2.1rem; }
  .problem h3 { font-size: 1.125rem; }
}

/* Transition into the solution. */
.bridge {
  display: grid;
  gap: 1.5rem;
  margin-top: clamp(2.75rem, 6vw, 4.5rem);
}
.bridge-text {
  margin: 0;
  max-width: 32ch;
  font-family: var(--font-head);
  font-size: clamp(1.5rem, 1rem + 1.9vw, 2.25rem);
  font-weight: 500;
  letter-spacing: -0.012em;
  line-height: 1.22;
  color: var(--ink);
  text-wrap: balance;
}
@media (min-width: 860px) {
  .bridge { grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 3rem; }
}

/* ==========================================================================
   09. WHAT I BUILD
   Each card leads with a real image of the kind of system it describes.
   ========================================================================== */
.build-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 680px)  { .build-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1040px) { .build-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.5rem; } }

.build-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  transition: border-color var(--t-med) var(--ease), box-shadow var(--t-med) var(--ease), transform var(--t-med) var(--ease);
}
.build-card:hover {
  transform: translateY(-3px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-md);
}

.build-media {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--brand-tint-2);
  border-bottom: 1px solid var(--line-soft);
}
.build-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease);
}
.build-card:hover .build-media img { transform: scale(1.03); }

.build-body { display: flex; flex-direction: column; flex: 1; padding: 1.5rem 1.6rem 1.7rem; }
.build-card h3 { margin-bottom: 0.45rem; font-size: 1.1875rem; font-weight: 600; letter-spacing: 0; }
.build-card p { margin: 0 0 1.15rem; font-size: 0.9375rem; line-height: 1.6; color: var(--muted); }

.build-list { display: grid; gap: 0.5rem; margin-top: auto; padding-top: 1.05rem; border-top: 1px solid var(--line-soft); }
.build-list li {
  position: relative;
  padding-left: 1.4rem;
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--ink-soft);
}
.build-list li::before {
  content: "";
  position: absolute;
  left: 0.15rem;
  top: 0.38em;
  width: 0.62rem;
  height: 0.34rem;
  border-left: 1.8px solid var(--brand);
  border-bottom: 1.8px solid var(--brand);
  transform: rotate(-45deg);
}

/* Phones: the six cards become a swipeable rail, which keeps the page short
   without hiding the imagery. */
@media (max-width: 679px) {
  .build-grid {
    display: flex;
    gap: 0.9rem;
    margin-inline: calc(var(--gutter) * -1);
    padding: 0.25rem var(--gutter) 0.75rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: var(--gutter);
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .build-grid::-webkit-scrollbar { display: none; }
  .build-card { flex: 0 0 82%; scroll-snap-align: start; }
  .build-card:hover { transform: none; }
  .build-body { padding: 1.2rem 1.25rem 1.35rem; }
  .build-card p { margin: 0; }
  .build-list { display: none; }
}

/* ==========================================================================
   10. SELECTED WORK (dark)
   ========================================================================== */
.work-list { display: grid; gap: 1.5rem; }

.work-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--dark-2);
  border: 1px solid var(--dark-line);
  border-radius: var(--r-xl);
  overflow: clip; /* clip, not hidden: hidden would stop the gallery below from sticking */
  transition: border-color var(--t-med) var(--ease);
}
.work-card:hover { border-color: rgba(255, 255, 255, 0.22); }

.work-visual { padding: 1rem; border-bottom: 1px solid var(--dark-line); }
.work-main { display: flex; flex-direction: column; flex: 1; padding: clamp(1.35rem, 2.6vw, 2rem); }

.work-meta { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.1rem; }
.status {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.28rem 0.7rem;
  border: 1px solid rgba(95, 194, 95, 0.4);
  border-radius: 999px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--brand-glow);
}
.status i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brand-glow);
  box-shadow: 0 0 0 0 rgba(95, 194, 95, 0.6);
  animation: statusPulse 2.4s ease-out infinite;
}
@keyframes statusPulse {
  0%   { box-shadow: 0 0 0 0 rgba(95, 194, 95, 0.55); }
  70%  { box-shadow: 0 0 0 6px rgba(95, 194, 95, 0); }
  100% { box-shadow: 0 0 0 0 rgba(95, 194, 95, 0); }
}
.work-idx { font-size: 0.8125rem; font-weight: 500; color: rgba(255, 255, 255, 0.62); }

.work-card h3 { margin-bottom: 0.25rem; font-size: clamp(1.5rem, 1.2rem + 1vw, 1.875rem); font-weight: 600; letter-spacing: -0.01em; }
.work-sub { margin: 0 0 1.4rem; font-size: 0.9375rem; color: var(--dark-muted); }

.work-facts { margin-bottom: 1.25rem; }
.work-fact {
  display: grid;
  grid-template-columns: 4.75rem minmax(0, 1fr);
  gap: 0.9rem;
  padding: 0.85rem 0;
  border-top: 1px solid var(--dark-line);
}
.work-fact dt { padding-top: 0.12rem; font-size: 0.875rem; font-weight: 600; color: var(--brand-glow); }
.work-fact dd { font-size: 0.9375rem; line-height: 1.55; color: rgba(255, 255, 255, 0.86); }

.tags { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.tags li {
  padding: 0.2rem 0.65rem;
  border: 1px solid var(--dark-line);
  border-radius: 999px;
  font-size: 0.8125rem;
  line-height: 1.5;
  color: #fff;
}

.work-points { display: grid; gap: 0.5rem; margin-bottom: 1.4rem; }
.work-points li {
  position: relative;
  padding-left: 1.45rem;
  font-size: 0.9375rem;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.8);
}
.work-points li::before {
  content: "";
  position: absolute;
  left: 0.15rem;
  top: 0.45em;
  width: 0.65rem;
  height: 0.35rem;
  border-left: 1.8px solid var(--brand-glow);
  border-bottom: 1.8px solid var(--brand-glow);
  transform: rotate(-45deg);
}

.work-value {
  margin: 0 0 1.5rem;
  padding: 0.9rem 1rem;
  border-left: 2px solid var(--brand-glow);
  border-radius: 0 var(--r-sm) var(--r-sm) 0;
  background: rgba(0, 128, 0, 0.14);
  font-size: 0.9375rem;
  line-height: 1.5;
  color: #fff;
}
.work-value span { display: block; margin-bottom: 0.15rem; font-size: 0.8125rem; font-weight: 600; color: var(--brand-glow); }

.work-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  align-self: flex-start;
  margin-top: auto;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--brand-glow);
}
.work-cta .ico { width: 18px; height: 18px; transition: transform var(--t-fast) var(--ease); }
.work-cta:hover .ico { transform: translateX(4px); }
.work-cta:hover { color: #fff; }

.work-row { display: grid; gap: 1.5rem; }

.work-note { margin-top: clamp(1.75rem, 3vw, 2.5rem); max-width: 46rem; font-size: 0.9375rem; line-height: 1.6; color: var(--dark-muted); }

/* Wide cards: a large gallery beside the text, so the screens stay readable. */
@media (min-width: 760px) {
  .work-card { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); }
  .work-visual { display: flex; align-items: flex-start; padding: 1.75rem; border-bottom: 0; border-right: 1px solid var(--dark-line); }
  /* The gallery follows you down while the longer text beside it scrolls past. */
  .shots { position: sticky; top: calc(var(--header-h) + 1.5rem); }
}

/* --- Screenshot gallery ------------------------------------------------ */
.shots { display: flex; flex-direction: column; gap: 0.8rem; width: 100%; }
.shot-slides { position: relative; }
.shot { display: none; margin: 0; }
.shot.is-active { display: block; }
html:not(.js) .shot { display: block; margin-bottom: 0.8rem; }

.shot-open {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  padding: 0;
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--r-md);
  box-shadow: 0 22px 44px -26px rgba(0, 0, 0, 0.85);
  cursor: zoom-in;
}
.shot-open img { width: 100%; height: 100%; object-fit: cover; object-position: top left; transition: transform 0.5s var(--ease); }
.shot-open:hover img { transform: scale(1.015); }

.shot-cap {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin: 0.6rem 0.1rem 0;
  font-size: 0.8125rem;
  line-height: 1.4;
  color: var(--dark-muted);
}
.shot-cap b { font-weight: 600; color: #fff; }

.shot-thumbs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.6rem; }
html:not(.js) .shot-thumbs { display: none; }
.shot-thumb {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  padding: 0;
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--r-sm);
  opacity: 0.55;
  transition: opacity var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease);
}
.shot-thumb img { width: 100%; height: 100%; object-fit: cover; object-position: top left; }
.shot-thumb:hover { opacity: 0.9; }
.shot-thumb.is-active { opacity: 1; border-color: var(--brand-glow); box-shadow: 0 0 0 1px var(--brand-glow); }

/* Phones: the gallery becomes a swipeable strip of full-size shots. */
@media (max-width: 759px) {
  .shot-slides {
    display: flex;
    gap: 0.6rem;
    margin-inline: -0.75rem;
    padding-inline: 0.75rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 0.75rem;
    scrollbar-width: none;
  }
  .shot-slides::-webkit-scrollbar { display: none; }
  .shot, .shot.is-active { display: block; flex: 0 0 88%; scroll-snap-align: start; }
  .shot-thumbs { display: none; }
  .shot-cap { flex-direction: column; gap: 0.1rem; }
  .work-main { padding: 1.25rem 1.2rem 1.4rem; }
  .work-card h3 { font-size: 1.5rem; }
  .work-sub { margin-bottom: 1rem; }
  .work-meta { margin-bottom: 0.9rem; }
  .work-fact { grid-template-columns: 4.25rem minmax(0, 1fr); gap: 0.75rem; padding: 0.7rem 0; }
  .work-fact dd { font-size: 0.9rem; }
  .work-points { margin-bottom: 1.1rem; }
  .work-points li { font-size: 0.9rem; }
  .work-points li:nth-child(n+4) { display: none; }
  .work-value { margin-bottom: 1.1rem; font-size: 0.9rem; }
}

/* --- Lightbox ---------------------------------------------------------- */
.lightbox {
  width: min(1200px, 94vw);
  max-width: none;
  max-height: 94vh;
  padding: 0;
  overflow: visible;
  background: transparent;
  border: 0;
  color: #fff;
}
.lightbox::backdrop { background: rgba(5, 9, 6, 0.86); }
.lightbox-img {
  width: 100%;
  height: auto;
  max-height: 82vh;
  object-fit: contain;
  background: #fff;
  border-radius: var(--r-md);
  box-shadow: 0 40px 90px -30px rgba(0, 0, 0, 0.9);
}
.lightbox-cap { margin: 0.85rem 0 0; font-size: 0.9375rem; color: rgba(255, 255, 255, 0.82); }
.lightbox-close {
  position: absolute;
  right: -0.25rem;
  top: -2.9rem;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  transition: background var(--t-fast) var(--ease);
}
.lightbox-close:hover { background: rgba(255, 255, 255, 0.24); }
.lightbox-close .ico { width: 20px; height: 20px; }
.lightbox :focus-visible { outline-color: #fff; }

/* ==========================================================================
   11. WHY WORK WITH ME
   ========================================================================== */
.why-grid { display: grid; gap: clamp(2rem, 5vw, 3.5rem); }
.why-head .sec-intro { margin-bottom: 1.5rem; }

.why-list { border-top: 1px solid var(--line-strong); }
.why-item {
  display: grid;
  grid-template-columns: 2.5rem minmax(0, 1fr);
  gap: 1rem;
  padding: 1.5rem 0.5rem;
  border-bottom: 1px solid var(--line);
  transition: background var(--t-fast) var(--ease), padding var(--t-med) var(--ease);
}
.why-item:hover { background: var(--brand-tint-2); padding-left: 1rem; }
.why-num { padding-top: 0.2rem; font-size: 0.9375rem; font-weight: 600; color: var(--brand); font-variant-numeric: tabular-nums; }
.why-item h3 { margin-bottom: 0.35rem; font-size: clamp(1.1875rem, 1rem + 0.5vw, 1.375rem); font-weight: 600; letter-spacing: 0; }
.why-item p { margin: 0; max-width: 38rem; font-size: 1rem; color: var(--muted); }

@media (min-width: 940px) {
  .why-grid { grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: 5rem; align-items: start; }
  .why-head { position: sticky; top: calc(var(--header-h) + 2.5rem); }
}

/* ==========================================================================
   12. TECHNOLOGY STACK
   ========================================================================== */
.stack { border-top: 1px solid var(--line-strong); }
.stack-row {
  display: grid;
  gap: 0.9rem;
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--line);
}
.stack-label { margin: 0; font-family: var(--font-sans); font-size: 0.9375rem; font-weight: 600; letter-spacing: 0; color: var(--ink-soft); }
.stack-chips { display: flex; flex-wrap: wrap; gap: 0.5rem; }

/* Each row's chips pop in on their own stagger once the stack section
   reveals — a livelier entrance than fading the whole block in at once. */
.js .stack-chips li {
  opacity: 0;
  transform: perspective(var(--tilt-depth)) scale(0.82) translateY(10px) rotateX(14deg);
  transition: opacity 0.4s var(--ease), transform 0.4s var(--ease);
}
.js .stack.is-visible .stack-chips li { opacity: 1; transform: none; }
.js .stack-chips li:nth-child(1)  { transition-delay: 0ms; }
.js .stack-chips li:nth-child(2)  { transition-delay: 35ms; }
.js .stack-chips li:nth-child(3)  { transition-delay: 70ms; }
.js .stack-chips li:nth-child(4)  { transition-delay: 105ms; }
.js .stack-chips li:nth-child(5)  { transition-delay: 140ms; }
.js .stack-chips li:nth-child(6)  { transition-delay: 175ms; }
.js .stack-chips li:nth-child(7)  { transition-delay: 210ms; }
.js .stack-chips li:nth-child(n+8) { transition-delay: 245ms; }
.stack-chips li {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.45rem 0.85rem 0.45rem 0.65rem;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ink-soft);
  transition: border-color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
.tl { width: 18px; height: 18px; flex: none; color: var(--muted-2); transition: color var(--t-fast) var(--ease); }
.stack-chips li:hover {
  border-color: var(--line-strong);
  transform: translateY(-1px) perspective(var(--tilt-depth)) rotateX(10deg);
  box-shadow: var(--shadow-sm);
}
.stack-chips li:hover .tl { color: var(--c, var(--brand)); }

@media (max-width: 859px) {
  .stack-row { gap: 0.7rem; padding: 1.1rem 0; }
  .stack-chips { gap: 0.4rem; }
  .stack-chips li { gap: 0.45rem; padding: 0.35rem 0.65rem 0.35rem 0.5rem; font-size: 0.8125rem; }
  .tl { width: 16px; height: 16px; }
}
@media (min-width: 860px) {
  .stack-row { grid-template-columns: 13.5rem minmax(0, 1fr); gap: 2rem; align-items: center; padding: 1.5rem 0; }
}

/* ==========================================================================
   13. PROCESS TIMELINE
   Vertical on phones and tablets, horizontal from 1000px.
   ========================================================================== */
.timeline { position: relative; display: grid; max-width: 40rem; }

.timeline::before,
.timeline::after {
  content: "";
  position: absolute;
  left: 7px;
  top: 0.5rem;
  bottom: 1.25rem;
  width: 2px;
  border-radius: 2px;
}
.timeline::before { background: var(--line); }
.timeline::after  { background: var(--brand); transform-origin: top; transition: transform 1.5s var(--ease) 0.25s; }
.js .timeline:not(.is-visible)::after { transform: scaleY(0); }
.js .timeline:not(.is-visible) .tl-dot { transform: scale(0.25); }

.tl-step { position: relative; padding: 0 0 1.9rem 2.5rem; }
.tl-step:last-child { padding-bottom: 0; }
.tl-dot {
  position: absolute;
  left: 0;
  top: 0.15rem;
  width: 16px;
  height: 16px;
  z-index: 1; /* above the rail, which would otherwise draw through the dot */
  border: 2px solid var(--brand);
  border-radius: 50%;
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
  background: #fff;
}
.tl-num { display: block; margin-bottom: 0.25rem; font-size: 0.875rem; font-weight: 600; color: var(--brand); font-variant-numeric: tabular-nums; }
.tl-step h3 { margin-bottom: 0.3rem; font-size: 1.25rem; font-weight: 600; letter-spacing: 0; }
.tl-step p { margin: 0; max-width: 26rem; font-size: 0.9375rem; color: var(--muted); }

@media (min-width: 1000px) {
  .timeline {
    max-width: none;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 1.5rem;
    padding-top: 2.4rem;
  }
  .timeline::before,
  .timeline::after { left: 0; right: 0; top: 7px; bottom: auto; width: auto; height: 2px; }
  .timeline::after { transform-origin: left; }
  .js .timeline:not(.is-visible)::after { transform: scaleX(0); }

  .tl-step { padding: 0; }
  .tl-dot { top: -2.4rem; }
  .tl-step h3 { font-size: 1.125rem; }
  .tl-step p { font-size: 0.875rem; }
}

/* ==========================================================================
   14. ABOUT (short)
   ========================================================================== */
.about-card {
  display: grid;
  gap: 1.75rem;
  padding: clamp(1.5rem, 4vw, 2.75rem);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
}
.about-photo {
  width: min(170px, 52%);
  aspect-ratio: 1 / 1;
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: linear-gradient(165deg, #f8fbf8 0%, #e8f0e9 100%);
}
.about-photo img {
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  mix-blend-mode: multiply;
}

.about-copy h2 { font-size: clamp(1.625rem, 1.2rem + 1.6vw, 2.25rem); margin-bottom: 0.9rem; }
.about-text { max-width: 40rem; font-size: clamp(1.0625rem, 1rem + 0.25vw, 1.15rem); color: var(--ink-soft); }
.about-meta { margin: 1rem 0 0; font-size: 0.9375rem; font-weight: 500; color: var(--muted); }

.social { display: flex; flex-wrap: wrap; gap: 0.55rem; margin-top: 1.6rem; }
.social a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 0.95rem;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ink-soft);
  transition: color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.social a .ico { width: 17px; height: 17px; color: var(--brand); }
.social a:hover { color: var(--brand); border-color: var(--brand-ring); transform: translateY(-2px); }

/* --- Email copy confirmation ---
   A mailto: link only opens a mail app if the visitor's device has one
   configured; clicking it otherwise looks like it "does nothing". This
   toast gives visible proof the click registered either way, and copies
   the address so it can be pasted even with no mail app at all. */
.social-email { position: relative; }
.copy-msg {
  position: absolute;
  left: 0;
  top: calc(100% + 6px);
  background: var(--ink);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.35rem 0.65rem;
  border-radius: var(--r-sm);
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-4px);
  transition: opacity var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
  z-index: 5;
}
.copy-msg.is-visible { opacity: 1; transform: translateY(0); }

@media (min-width: 760px) {
  .about-card { grid-template-columns: 200px minmax(0, 1fr); gap: 3rem; align-items: center; }
  .about-photo { width: 100%; }
}

/* ==========================================================================
   15. FINAL CTA
   ========================================================================== */
.cta { overflow: hidden; }
.cta-inner { display: grid; gap: 2.5rem; align-items: center; }
.cta h2 { margin-bottom: 1.1rem; max-width: 15em; font-size: clamp(2.125rem, 1.2rem + 3.3vw, 3.5rem); letter-spacing: -0.015em; }
.cta-sub { max-width: 30rem; font-size: clamp(1.0625rem, 1rem + 0.3vw, 1.25rem); color: var(--dark-muted); }

.cta-action { display: flex; flex-direction: column; align-items: flex-start; gap: 1rem; }
.cta-note { margin: 0; max-width: 22rem; font-size: 0.9375rem; color: var(--dark-muted); }

/* --- Contact form --- */
.cta-form { display: flex; flex-direction: column; gap: 1.1rem; width: 100%; max-width: 30rem; }
.form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.1rem; }
.form-field { display: flex; flex-direction: column; gap: 0.5rem; }
.form-label { font-size: 0.875rem; font-weight: 600; color: rgba(255, 255, 255, 0.86); }
.form-optional { font-weight: 500; color: var(--dark-muted); }
.form-input {
  width: 100%;
  padding: 0.75rem 0.9rem;
  background: var(--dark-2);
  border: 1px solid var(--dark-line);
  border-radius: var(--r-md);
  color: #fff;
  font: inherit;
  font-size: 16px;
  transition: border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
.form-input::placeholder { color: rgba(255, 255, 255, 0.4); }
.form-input:focus { outline: none; border-color: var(--brand-glow); box-shadow: 0 0 0 3px rgba(95, 194, 95, 0.22); }
.form-textarea { resize: vertical; min-height: 6.5rem; }
/* Visually hidden from sighted users but still in the tab order for bots that
   blindly fill every field — real visitors never see or reach it. */
.form-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* --- Inline validation --- */
.field-error { display: none; font-size: 0.8125rem; color: #ff9a90; }
.form-field.is-invalid .form-input { border-color: #ff6b6b; }
.form-field.is-invalid .form-input:focus { box-shadow: 0 0 0 3px rgba(255, 107, 107, 0.22); }
.form-field.is-invalid .field-error { display: block; }

@media (max-width: 559px) {
  .form-row { grid-template-columns: minmax(0, 1fr); }
}
.cta-alt {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--brand-glow);
  border-bottom: 1px solid transparent;
  transition: border-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.cta-alt .ico { width: 16px; height: 16px; }
.cta-alt:hover { color: #fff; border-bottom-color: currentColor; }

@media (min-width: 940px) {
  .cta-inner { grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr); gap: 5rem; }
}
@media (max-width: 479px) {
  .cta-action .btn { width: 100%; }
}

/* ==========================================================================
   16. FOOTER
   ========================================================================== */
.site-footer {
  padding-block: clamp(2.5rem, 5vw, 3.5rem);
  background: var(--dark);
  border-top: 1px solid var(--dark-line);
  color: var(--dark-muted);
}
.footer-inner { display: grid; gap: 1.75rem; align-items: center; }
@media (min-width: 900px) {
  .footer-inner { grid-template-columns: auto minmax(0, 1fr) auto; gap: 2rem; }
  .footer-nav { justify-content: center; }
  .footer-copy { grid-column: 1 / -1; }
}

.brand--footer .brand-pre { color: rgba(255, 255, 255, 0.7); }
.brand--footer .brand-name { color: #fff; }
.footer-tag { margin: 0.75rem 0 0; font-size: 0.875rem; color: rgba(255, 255, 255, 0.6); }
.site-footer .dot { color: var(--brand-glow); }

.footer-nav { display: flex; flex-wrap: wrap; gap: 0 1.5rem; }
.footer-nav a {
  padding-block: 0.5rem;
  font-size: 0.875rem;
  color: var(--dark-muted);
  transition: color var(--t-fast) var(--ease);
}
.footer-nav a:hover { color: var(--brand-glow); }

.footer-social { display: flex; gap: 0.5rem; }
.footer-social a {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--dark-line);
  border-radius: var(--r-md);
  color: var(--dark-muted);
  transition: color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.footer-social a .ico { width: 18px; height: 18px; }
.footer-social a:hover { color: var(--brand-glow); border-color: rgba(95, 194, 95, 0.45); transform: translateY(-2px); }

.footer-copy {
  margin: 0;
  padding-top: 1.5rem;
  border-top: 1px solid var(--dark-line);
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.55);
}

/* ==========================================================================
   17. REVEAL ANIMATIONS & REDUCED MOTION
   Reveal styles apply only when JS is running (html.js), so the page is
   fully readable with JavaScript disabled.
   ========================================================================== */
.js [data-reveal] {
  opacity: 0;
  transform: perspective(var(--tilt-depth)) translateY(16px) rotateX(7deg);
  transform-origin: 50% 100%;
  transition: opacity 0.55s var(--ease), transform 0.55s var(--ease);
  will-change: opacity, transform;
}
.js [data-reveal].is-visible {
  opacity: 1;
  transform: none;
  will-change: auto;
}
.js [data-reveal][data-delay="1"] { transition-delay: 70ms; }
.js [data-reveal][data-delay="2"] { transition-delay: 140ms; }
.js [data-reveal][data-delay="3"] { transition-delay: 210ms; }
.js [data-reveal][data-delay="4"] { transition-delay: 280ms; }
.js [data-reveal][data-delay="5"] { transition-delay: 350ms; }

/* Revealed cards must not wait on the reveal delay when hovered. */
.js .problem.is-visible,
.js .build-card.is-visible,
.js .work-card.is-visible { transition-delay: 0ms; }
.js .build-card[data-reveal] {
  transition: opacity 0.55s var(--ease), transform 0.55s var(--ease),
              border-color var(--t-med) var(--ease), box-shadow var(--t-med) var(--ease);
}
/* min-width guard: below it, cards sit in the swipe rail and are forced
   visible unconditionally further down — this must never outrank that. */
@media (min-width: 680px) {
  .js .build-card[data-reveal]:not(.is-visible) {
    transform: perspective(var(--tilt-depth)) translateY(26px) rotateX(10deg) scale(0.94);
  }
}
.js .build-card.is-visible:hover { transform: translateY(-3px); }

/* The three row cards in Selected Work lean out of alternating sides as
   they reveal, instead of all rising the same way. */
.js .work-card[data-reveal]:not(.is-visible)      { transform: perspective(var(--tilt-depth)) translateY(24px) rotateX(8deg) rotateY(-5deg); }
.js .work-card--rev[data-reveal]:not(.is-visible) { transform: perspective(var(--tilt-depth)) translateY(24px) rotateX(8deg) rotateY(5deg); }

/* Once a tilt-enabled card has revealed, main.js drives `transform` itself,
   per animation frame, to track the cursor — hand it full control so the
   reveal's own transition doesn't fight (and lag behind) every frame. */
.has-tilt.js .build-card[data-reveal].is-visible {
  transition: border-color var(--t-med) var(--ease), box-shadow var(--t-med) var(--ease);
}

/* Cards inside the phone swipe rail are off-screen sideways, so they never
   "intersect" until swiped. Show them straight away. */
@media (max-width: 679px) {
  .js .build-card[data-reveal] { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js [data-reveal] { opacity: 1; transform: none; transition: none; }
  .js .timeline:not(.is-visible)::after { transform: none; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
