/* midnightsun.web.id
   Glass system: light warm-gray canvas by day, ink night canvas by toggle;
   one giant orange-to-magenta orb pinned to the right edge, frosted-glass
   surfaces. Theme switches via [data-theme="dark"] on <html> (toggle in nav,
   persisted in localStorage, defaults to the system preference).
   Shape rule: containers 20px radius, interactive elements and chips pill.
   Accent rule: one accent family (the orb gradient, orange #ff9a3e to magenta
   #f0308f); --accent-ink is its text-safe tone per theme. No second accent. */

/* ---------- Fonts ---------- */
@font-face {
  font-family: "Bricolage Grotesque";
  src: url("../fonts/bricolage-grotesque-var.woff2") format("woff2-variations");
  font-weight: 200 800;
  font-display: swap;
}
@font-face {
  font-family: "Instrument Sans";
  src: url("../fonts/instrument-sans-var.woff2") format("woff2-variations");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Instrument Sans";
  src: url("../fonts/instrument-sans-var-italic.woff2") format("woff2-variations");
  font-weight: 400 700;
  font-style: italic;
  font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
  --canvas: #e7e6e4;          /* light warm gray, the Glass Shine backdrop */
  --canvas-deep: #dbd9d6;     /* lower edge of the page gradient */
  --ink: #17161c;             /* primary text */
  --ink-2: #56525e;           /* secondary text */
  --grad-a: #ffb257;          /* orb top */
  --grad-b: #ff7847;          /* orb mid */
  --grad-c: #f0308f;          /* orb low */
  --accent-ink: #b0135f;      /* gradient family, dark enough for text on canvas */
  --orb-gradient: linear-gradient(160deg, var(--grad-a) 0%, var(--grad-b) 45%, var(--grad-c) 100%);

  --canvas-hi: #ecebe9;       /* top of the page gradient */
  --glass-bg: rgb(255 255 255 / 0.42);
  --glass-bg-strong: rgb(255 255 255 / 0.6);
  --glass-border: rgb(255 255 255 / 0.75);
  --glass-inner: inset 0 1px 0 rgb(255 255 255 / 0.85);
  --glass-shadow: 0 18px 44px rgb(23 22 28 / 0.10);
  --line: rgb(23 22 28 / 0.14);
  --line-soft: rgb(23 22 28 / 0.08);
  --nav-bg: rgb(255 255 255 / 0.55);
  --shine: rgb(255 255 255 / 0.55);
  --num-stroke: rgb(23 22 28 / 0.10);
  --media-bg: rgb(255 255 255 / 0.3);
  --btn-hover: #2b2933;

  --font-display: "Bricolage Grotesque", "Avenir Next", "Segoe UI", sans-serif;
  --font-body: "Instrument Sans", "Segoe UI", system-ui, sans-serif;

  --step-hero: clamp(2.5rem, 1rem + 7.5vw, 5.4rem);
  --step-title: clamp(1.9rem, 1.1rem + 3.4vw, 3.4rem);
  --step-tagline: clamp(1.2rem, 1rem + 1.2vw, 1.7rem);
  --step-h3: clamp(1.1rem, 1rem + 0.6vw, 1.35rem);
  --step-body: 1rem;
  --step-small: 0.875rem;

  --container: 72rem;
  --gutter: clamp(1.25rem, 5vw, 4rem);
  --section-gap: clamp(6rem, 12vw, 10rem);

  --radius-card: 20px;
  --radius-pill: 999px;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
}

/* Night mode: same orb, same gradient accent family, ink canvas.
   Composed, not mechanically inverted: glass goes translucent-white-on-dark,
   the accent text tone shifts to the gradient's orange end for contrast. */
[data-theme="dark"] {
  --canvas: #141118;
  --canvas-deep: #0d0b11;
  --canvas-hi: #191521;
  --ink: #f2eee6;
  --ink-2: #aaa5b3;
  --accent-ink: #ffa068;
  --glass-bg: rgb(255 255 255 / 0.055);
  --glass-bg-strong: rgb(255 255 255 / 0.09);
  --glass-border: rgb(255 255 255 / 0.14);
  --glass-inner: inset 0 1px 0 rgb(255 255 255 / 0.10);
  --glass-shadow: 0 18px 44px rgb(0 0 0 / 0.5);
  --line: rgb(242 238 230 / 0.16);
  --line-soft: rgb(242 238 230 / 0.09);
  --nav-bg: rgb(20 17 24 / 0.62);
  --shine: rgb(255 255 255 / 0.14);
  --num-stroke: rgb(242 238 230 / 0.13);
  --media-bg: rgb(255 255 255 / 0.05);
  --btn-hover: #ffffff;
}

/* ---------- Reset-ish ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  transition: background-color 0.3s ease, color 0.3s ease;
  font-family: var(--font-body);
  font-size: var(--step-body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img, svg, video { max-width: 100%; height: auto; display: block; }
h1, h2, h3, h4, p, dl, dd, figure { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
a { color: inherit; }
::selection { background: var(--grad-c); color: #fff; }

:focus-visible {
  outline: 2px solid var(--accent-ink);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  top: -3rem;
  left: 1rem;
  z-index: 100;
  padding: 0.6rem 1.1rem;
  background: var(--ink);
  color: var(--canvas);
  border-radius: var(--radius-pill);
  text-decoration: none;
  font-weight: 600;
  transition: top 0.2s var(--ease-out);
}
.skip-link:focus-visible { top: 1rem; }

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ---------- Backdrop: light canvas + the orb ---------- */
.backdrop {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.backdrop-base {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, var(--canvas-hi) 0%, var(--canvas) 40%, var(--canvas-deep) 100%);
  transition: background 0.3s ease;
}
/* CSS orb: always present; the shader canvas fades in above it when ready.
   Sized against the viewport height, hanging off the right edge so roughly a
   third of it is on screen. */
.orb-fallback {
  position: absolute;
  top: 50%;
  left: 100%;
  width: 160vh;
  height: 160vh;
  transform: translate(-33%, -50%) translate(var(--orb-out, 0vh), var(--orb-shift, 0vh));
  border-radius: 50%;
  background:
    radial-gradient(circle at 38% 30%, rgb(255 224 174 / 0.9) 0%, transparent 32%),
    linear-gradient(160deg, var(--grad-a) 0%, var(--grad-b) 42%, var(--grad-c) 78%, #c22377 100%);
  /* soft edge lives in the mask, not in filter: blur(), which Safari clips
     against the viewport and leaves a straight fringe on the visible edge */
  -webkit-mask-image: radial-gradient(closest-side, #000 96.5%, transparent 100%);
  mask-image: radial-gradient(closest-side, #000 96.5%, transparent 100%);
}
#orb-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1.2s ease;
}
#orb-canvas.is-live { opacity: 1; }
#orb-canvas.is-live ~ .orb-fallback,
.backdrop:has(#orb-canvas.is-live) .orb-fallback { visibility: hidden; }

/* grain sits on the fixed backdrop only: no scroll repaints */
.backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}

main, .nav, .footer { position: relative; z-index: 1; }

/* ---------- Glass primitives ---------- */
.glass {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-card);
  box-shadow: var(--glass-inner), var(--glass-shadow);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
}
/* the Glass Shine sweep: a soft diagonal highlight that crosses on hover */
.glass::before {
  content: "";
  position: absolute;
  top: 100%;
  left: -100%;
  width: 65%;
  height: 220%;
  z-index: 0;
  transform: rotate(25deg);
  background: linear-gradient(90deg, transparent, var(--shine), transparent);
  pointer-events: none;
  opacity: 0;
}
@media (hover: hover) and (pointer: fine) {
  .glass:hover::before {
    opacity: 1;
    animation: shine 0.9s var(--ease-out) forwards;
  }
}
@keyframes shine {
  0% { top: 100%; left: -100%; }
  100% { top: -60%; left: 120%; }
}
.glass > * { position: relative; z-index: 1; }
@media (prefers-reduced-transparency: reduce) {
  .glass {
    background: rgb(255 255 255 / 0.92);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
}

/* ---------- Nav ---------- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 4rem;
  padding-inline: var(--gutter);
  transition: background-color 0.3s ease, backdrop-filter 0.3s ease, box-shadow 0.3s ease;
}
.nav.is-scrolled {
  background: var(--nav-bg);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  border-bottom: 1px solid var(--glass-border);
  box-shadow: 0 8px 30px rgb(23 22 28 / 0.06);
}
.nav-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--font-display);
  font-weight: 640;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
  text-decoration: none;
}
.nav-orb {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--orb-gradient);
  box-shadow: 0 2px 8px rgb(240 48 143 / 0.4);
}
.nav-right {
  display: inline-flex;
  align-items: center;
  gap: 1.4rem;
}
.nav-progress {
  font-variant-numeric: tabular-nums;
  font-size: var(--step-small);
  color: var(--ink-2);
  letter-spacing: 0.06em;
  padding: 0.4rem 0.9rem;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-pill);
  background: var(--nav-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.3rem;
  height: 2.3rem;
  padding: 0;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-pill);
  background: var(--nav-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: var(--ink);
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease, transform 0.15s var(--ease-out);
}
.theme-toggle:active { transform: scale(0.94); }
@media (hover: hover) and (pointer: fine) {
  .theme-toggle:hover { border-color: var(--accent-ink); color: var(--accent-ink); }
}
.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }
[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
[data-theme="dark"] .theme-toggle .icon-moon { display: none; }

.nav-contact {
  font-size: var(--step-small);
  font-weight: 600;
  text-decoration: none;
  padding: 0.45rem 1.05rem;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-pill);
  background: var(--nav-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: border-color 0.2s ease, color 0.2s ease;
}
@media (hover: hover) and (pointer: fine) {
  .nav-contact:hover { border-color: var(--accent-ink); color: var(--accent-ink); }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1.75rem;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  white-space: nowrap;
  transition: transform 0.15s var(--ease-out), background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}
.btn:active { transform: translateY(1px) scale(0.98); }
.btn-primary {
  background: var(--ink);
  color: var(--canvas);
  box-shadow: 0 10px 24px rgb(0 0 0 / 0.22);
}
.btn-ghost {
  border: 1px solid var(--glass-border);
  color: var(--ink);
  background: var(--glass-bg-strong);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: var(--glass-inner);
}
@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover { background: var(--btn-hover); box-shadow: 0 12px 30px rgb(0 0 0 / 0.3); }
  .btn-ghost:hover { border-color: var(--accent-ink); color: var(--accent-ink); }
}

/* ---------- Hero ---------- */
.hero {
  min-height: 100dvh;
  display: flex;
  align-items: flex-end;
  padding-bottom: clamp(4rem, 12vh, 8rem);
  padding-top: 6rem;
}
.hero-eyebrow { margin-bottom: 1rem; }
.eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent-ink);
}
.hero-title {
  font-family: var(--font-display);
  font-weight: 680;
  font-size: var(--step-hero);
  line-height: 1.04;
  letter-spacing: -0.025em;
}
.hero-title em {
  font-style: normal;
  background: var(--orb-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-title .line {
  display: block;
  overflow: clip;
  padding-bottom: 0.08em;
}
.hero-title .line > span { display: inline-block; }
.hero-sub {
  margin-top: 1.5rem;
  max-width: 44ch;
  font-size: clamp(1.05rem, 1rem + 0.5vw, 1.25rem);
  color: var(--ink-2);
}
.hero-ctas {
  margin-top: 2.25rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
}

/* ---------- Sections ---------- */
.section { padding-block: calc(var(--section-gap) / 2); }
.section:last-of-type { padding-bottom: var(--section-gap); }

.section-head {
  position: relative;
  margin-bottom: clamp(2.5rem, 6vw, 4rem);
  max-width: 46rem;
}
.section-num {
  position: absolute;
  top: -0.55em;
  right: calc(-1 * clamp(0rem, 4vw, 3rem));
  z-index: -1;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(5rem, 14vw, 11rem);
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1px var(--num-stroke);
  user-select: none;
}
.section-head .eyebrow { margin-bottom: 0.9rem; }
.section-title {
  font-family: var(--font-display);
  font-weight: 660;
  font-size: var(--step-title);
  line-height: 1.06;
  letter-spacing: -0.02em;
}
.section-tagline {
  margin-top: 0.9rem;
  font-size: var(--step-tagline);
  line-height: 1.4;
  color: var(--ink-2);
  font-weight: 450;
}

/* ---------- Flagship sections ---------- */
.flagship-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: start;
}
.flagship-grid-alt { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
.flagship-copy p + p { margin-top: 1rem; }
.flagship-copy { max-width: 58ch; color: var(--ink-2); }
.flagship-copy strong, .facts strong { color: var(--ink); }

.media img, .media video {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}
.media figcaption {
  padding: 0.8rem 1.1rem;
  font-size: var(--step-small);
  color: var(--ink-2);
  border-top: 1px solid var(--line-soft);
}

.stats {
  margin-top: clamp(2.5rem, 6vw, 4rem);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line);
}
.stat {
  padding: 1.5rem 1.25rem 0 0;
}
.stat + .stat { border-left: 1px solid var(--line-soft); padding-left: 1.5rem; }
.stat dt {
  font-size: var(--step-small);
  color: var(--ink-2);
  order: 2;
}
.stat dd {
  font-family: var(--font-display);
  font-weight: 660;
  font-size: clamp(1.9rem, 1.2rem + 2.6vw, 3.2rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  margin-bottom: 0.35rem;
}
.stat-suffix, .stat-prefix {
  background: var(--orb-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.chips {
  margin-top: clamp(2rem, 5vw, 3rem);
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}
.chips li {
  padding: 0.45rem 1rem;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-pill);
  font-size: var(--step-small);
  color: var(--ink-2);
  background: var(--glass-bg);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: var(--glass-inner);
  transition: border-color 0.2s ease, color 0.2s ease;
}
@media (hover: hover) and (pointer: fine) {
  .chips li:hover { border-color: var(--accent-ink); color: var(--ink); }
}

.facts { margin-top: 1.5rem; display: grid; gap: 0.8rem; color: var(--ink-2); }
.facts li { padding-left: 1.1rem; position: relative; }
.facts li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 0.45rem;
  height: 2px;
  background: var(--accent-ink);
}

.callouts {
  margin-top: clamp(2rem, 5vw, 3rem);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(1rem, 3vw, 2rem);
}
.callout {
  padding: clamp(1.4rem, 3vw, 2rem);
}
.callout h3 {
  font-family: var(--font-display);
  font-weight: 640;
  font-size: var(--step-h3);
  letter-spacing: -0.01em;
  margin-bottom: 0.7rem;
}
.callout p { color: var(--ink-2); }

/* ---------- Projects ---------- */
.projects {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(1.5rem, 4vw, 2.5rem);
}
.project {
  display: flex;
  flex-direction: column;
}
.project-wide {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
}
.project-wide .project-media { border-bottom: 0; }
.project-media {
  border-bottom: 1px solid var(--line-soft);
  background: var(--media-bg);
}
.project-media img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; height: 100%; }
.project-body {
  padding: clamp(1.4rem, 3vw, 2rem);
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  align-items: flex-start;
}
.project-cat {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-ink);
}
.project-name {
  font-family: var(--font-display);
  font-weight: 650;
  font-size: clamp(1.3rem, 1.1rem + 1vw, 1.7rem);
  letter-spacing: -0.015em;
  line-height: 1.15;
}
.project-tag { color: var(--ink-2); font-style: italic; }
.project-body > p:not(.project-cat):not(.project-tag) { color: var(--ink-2); }
.project-points { display: grid; gap: 0.45rem; color: var(--ink-2); font-size: var(--step-small); }
.project-points li { padding-left: 1.1rem; position: relative; }
.project-points li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 0.45rem;
  height: 2px;
  background: var(--accent-ink);
}
.project-link {
  margin-top: auto;
  padding-top: 0.5rem;
  font-weight: 600;
  color: var(--accent-ink);
  text-decoration: none;
}
@media (hover: hover) and (pointer: fine) {
  .project-link:hover { text-decoration: underline; text-underline-offset: 4px; }
}
.project-pair-head {
  grid-column: 1 / -1;
  max-width: 52ch;
  margin-top: clamp(1rem, 3vw, 2rem);
  display: grid;
  gap: 0.6rem;
}
.project-pair-head p:last-child { color: var(--ink-2); }

/* ---------- Principles ---------- */
.principles {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  border-top: 1px solid var(--line);
}
.principle {
  padding: clamp(1.6rem, 4vw, 2.6rem) clamp(0rem, 3vw, 2.6rem) clamp(1.6rem, 4vw, 2.6rem) 0;
  border-bottom: 1px solid var(--line-soft);
}
.principle:nth-child(even) {
  border-left: 1px solid var(--line-soft);
  padding-left: clamp(1.2rem, 3vw, 2.6rem);
}
.principle:nth-last-child(-n+2) { border-bottom: 0; }
.principle h3 {
  font-family: var(--font-display);
  font-weight: 640;
  font-size: var(--step-h3);
  letter-spacing: -0.01em;
  margin-bottom: 0.7rem;
}
.principle p { color: var(--ink-2); max-width: 46ch; }

/* ---------- About ---------- */
.about { max-width: 60ch; display: grid; gap: 1.1rem; }
.about-lead {
  font-size: clamp(1.15rem, 1rem + 0.8vw, 1.45rem);
  line-height: 1.5;
}
.about p:not(.about-lead) { color: var(--ink-2); }
.about a { color: var(--accent-ink); text-decoration: none; font-weight: 600; }
@media (hover: hover) and (pointer: fine) {
  .about a:hover { text-decoration: underline; text-underline-offset: 4px; }
}
.invite {
  margin-top: clamp(3.5rem, 8vw, 6rem);
  padding-top: clamp(2rem, 5vw, 3rem);
  border-top: 1px solid var(--line);
}
.invite-title {
  font-family: var(--font-display);
  font-weight: 660;
  font-size: clamp(1.7rem, 1.1rem + 2.8vw, 3rem);
  line-height: 1.12;
  letter-spacing: -0.02em;
  max-width: 22ch;
}
.invite-link {
  display: inline-block;
  margin-top: 1.4rem;
  font-family: var(--font-display);
  font-weight: 640;
  font-size: clamp(1.15rem, 1rem + 0.8vw, 1.5rem);
  background: var(--orb-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: var(--accent-ink);
  -webkit-text-fill-color: transparent;
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: border-color 0.2s ease;
  padding-bottom: 0.1em;
}
@media (hover: hover) and (pointer: fine) {
  .invite-link:hover { border-bottom-color: var(--grad-c); }
}

/* ---------- Contact ---------- */
.contact-list { border-top: 1px solid var(--line); }
.contact-item {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding: clamp(1.4rem, 4vw, 2.2rem) 0;
  border-bottom: 1px solid var(--line-soft);
  text-decoration: none;
  transition: padding-left 0.25s var(--ease-out);
}
.contact-label {
  font-size: var(--step-small);
  color: var(--ink-2);
}
.contact-value {
  font-family: var(--font-display);
  font-weight: 650;
  font-size: clamp(1.5rem, 1rem + 2.6vw, 2.8rem);
  letter-spacing: -0.02em;
  line-height: 1.1;
  overflow-wrap: anywhere;
  transition: color 0.2s ease;
}
@media (hover: hover) and (pointer: fine) {
  .contact-item:hover { padding-left: 0.8rem; }
  .contact-item:hover .contact-value { color: var(--accent-ink); }
}

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--line-soft);
  padding-block: 2rem;
}
.footer .container {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: var(--step-small);
  color: var(--ink-2);
}
.footer p { margin: 0; }

/* ---------- Motion (JS-gated: initial states only when html[data-motion] is set) ---------- */
html[data-motion] .hero-title .line > span { transform: translateY(110%); }
html[data-motion] .hero-sub,
html[data-motion] .hero-ctas,
html[data-motion] .hero-eyebrow { opacity: 0; }
html[data-motion] [data-reveal] { opacity: 0; transform: translateY(26px); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ---------- Responsive ---------- */
@media (max-width: 880px) {
  .flagship-grid,
  .flagship-grid-alt,
  .callouts,
  .projects,
  .principles { grid-template-columns: minmax(0, 1fr); }
  .project-wide { grid-template-columns: minmax(0, 1fr); }
  .project-wide .project-media { border-bottom: 1px solid var(--line-soft); }
  .flagship-grid .media { order: -1; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(3) { border-left: 0; padding-left: 0; }
  .stat { border-bottom: 1px solid var(--line-soft); padding-bottom: 1.25rem; }
  .stat:nth-last-child(-n+2) { border-bottom: 0; padding-bottom: 0; }
  .principle { border-left: 0 !important; padding-left: 0 !important; }
  .principle:nth-last-child(-n+2):not(:last-child) { border-bottom: 1px solid var(--line-soft); }
  .section-num { right: 0; }
  .orb-fallback {
    width: 130vh;
    height: 130vh;
    transform: translate(-10%, -50%) translate(var(--orb-out, 0vh), var(--orb-shift, 0vh));
  }
  /* where the headline can graze the orb, a soft canvas-colored halo keeps it legible */
  .hero-title em { filter: drop-shadow(0 0 14px var(--canvas)); }
  .hero-sub { text-shadow: 0 1px 12px var(--canvas); }
}
@media (max-width: 480px) {
  .nav-progress { display: none; }
  .stats { grid-template-columns: 1fr; }
  .stat + .stat { border-left: 0; padding-left: 0; }
  .stat { border-bottom: 1px solid var(--line-soft); padding-bottom: 1.1rem; }
  .stat:last-child { border-bottom: 0; }
  .hero-ctas .btn { flex: 1 1 100%; }
}
