/* ==========================================================================
   AETHEREAL FORGE — site layer
   Built on aethereal-forge-theme.css (tokens, atmosphere, base components).
   ========================================================================== */

:root {
  --header-h: 72px;
  --status-live: #7ff0ea;
  --status-testing: #f2c078;
  --status-prototype: #9db9ff;
  --status-concept: #c3b2ff;
  --ease: cubic-bezier(.22, .61, .36, 1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 { font-weight: 720; }

p { text-wrap: pretty; }

svg { flex: none; }

ul, ol { margin: 0; padding: 0; }

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

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 100;
  padding: 12px 18px;
  border-radius: 10px;
  background: var(--af-teal);
  color: #061317;
  font-weight: 700;
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform 160ms ease;
}

.skip-link:focus-visible { transform: translateY(0); }

#top, #collection, #catalog, #testing { scroll-margin-top: calc(var(--header-h) + 24px); }

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid transparent;
  background: rgba(8, 13, 21, .55);
  backdrop-filter: blur(18px) saturate(130%);
  -webkit-backdrop-filter: blur(18px) saturate(130%);
  transition: background 220ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.site-header.is-scrolled {
  border-bottom-color: var(--af-border);
  background: rgba(7, 12, 19, .86);
  box-shadow: 0 12px 34px rgba(0, 0, 0, .28);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--af-teal);
  text-decoration: none;
  flex: none;
}

.brand-mark { width: 27px; height: 27px; }

.brand-word {
  color: var(--af-text);
  font-size: .78rem;
  font-weight: 760;
  letter-spacing: .17em;
  white-space: nowrap;
}

.brand-word-accent { color: var(--af-teal); margin-left: .4em; }

.site-nav {
  display: flex;
  align-items: center;
  gap: 2px;
  flex: 1;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.site-nav::-webkit-scrollbar { display: none; }

.site-nav a {
  flex: none;
  padding: 8px 11px;
  border-radius: 999px;
  color: var(--af-muted);
  font-size: .86rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: color 160ms ease, background 160ms ease;
}

.site-nav a:hover {
  color: var(--af-text);
  background: rgba(114, 228, 224, .08);
}

.search-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: none;
  height: 38px;
  padding: 0 8px 0 12px;
  border: 1px solid var(--af-border);
  border-radius: 999px;
  background: rgba(12, 22, 34, .65);
  color: var(--af-muted);
  font-size: .82rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 160ms ease, color 160ms ease, background 160ms ease;
}

.search-trigger:hover {
  border-color: var(--af-border-strong);
  background: rgba(17, 31, 47, .85);
  color: var(--af-text);
}

.search-trigger svg { width: 16px; height: 16px; }

.search-trigger kbd {
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border: 1px solid rgba(114, 228, 224, .22);
  border-radius: 6px;
  background: rgba(8, 13, 21, .8);
  color: var(--af-subtle);
  font: 600 .72rem/1 ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding-block: clamp(56px, 8vw, 104px) clamp(48px, 7vw, 84px);
  border-bottom: 1px solid var(--af-border);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(114, 228, 224, .045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(114, 228, 224, .045) 1px, transparent 1px);
  background-size: 76px 76px;
  mask-image: radial-gradient(ellipse at 62% 22%, #000 10%, transparent 68%);
  -webkit-mask-image: radial-gradient(ellipse at 62% 22%, #000 10%, transparent 68%);
  pointer-events: none;
}

.hero::after {
  content: "";
  position: absolute;
  z-index: -1;
  width: 46rem;
  height: 46rem;
  top: -22rem;
  right: -12rem;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(78, 208, 216, .16), transparent 62%);
  pointer-events: none;
}

.hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, .92fr);
  align-items: center;
  gap: clamp(36px, 5.5vw, 76px);
}

.hero-copy { min-width: 0; }

.hero h1 {
  max-width: 12ch;
  margin: 18px 0 22px;
  font-size: clamp(3rem, 6.9vw, 5.9rem);
  font-weight: 780;
  line-height: .93;
  letter-spacing: -.065em;
  text-wrap: balance;
}

.hero h1 .accent {
  background: linear-gradient(100deg, var(--af-teal) 4%, #9cf3ff 40%, var(--af-blue) 76%, var(--af-violet) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-lede {
  max-width: 54ch;
  margin: 0;
  color: var(--af-muted);
  font-size: clamp(1rem, 1.35vw, 1.14rem);
  line-height: 1.72;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin: 34px 0 0;
  padding: 0;
  list-style: none;
  color: var(--af-subtle);
  font-size: .74rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.hero-meta li { display: inline-flex; align-items: center; gap: 8px; }

.hero-meta li::before {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--af-teal);
  opacity: .85;
}

/* Buttons, tuned on top of the theme component */
.af-btn {
  min-height: 50px;
  padding: 0 20px;
  border-radius: 10px;
  font-size: .93rem;
  letter-spacing: .005em;
  gap: 10px;
}

.af-btn svg { width: 16px; height: 16px; }

.af-btn-primary {
  box-shadow: 0 12px 32px rgba(63, 206, 218, .22), inset 0 1px 0 rgba(255, 255, 255, .35);
}

.af-btn-primary:hover {
  box-shadow: 0 16px 40px rgba(63, 206, 218, .3), inset 0 1px 0 rgba(255, 255, 255, .4);
}

.af-btn:disabled,
.af-btn[disabled] {
  opacity: .5;
  cursor: not-allowed;
}

.af-btn:disabled:hover,
.af-btn[disabled]:hover {
  transform: none;
  border-color: var(--af-border-strong);
  color: var(--af-text);
}

/* Hero artwork panel */
.hero-visual {
  position: relative;
  aspect-ratio: 4 / 4.45;
  min-height: 320px;
  border: 1px solid var(--af-border);
  border-radius: 24px;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 50% 42%, rgba(64, 209, 216, .16), transparent 58%),
    linear-gradient(155deg, #0d1b2a, #070c14 78%);
  box-shadow:
    0 34px 80px rgba(0, 0, 0, .4),
    0 0 70px rgba(50, 180, 197, .08),
    inset 0 0 90px rgba(67, 197, 220, .05);
}

.hero-visual canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.hero-visual::before,
.hero-visual::after {
  content: "";
  position: absolute;
  z-index: 2;
  width: 24px;
  height: 24px;
  border: 1px solid rgba(114, 228, 224, .5);
  pointer-events: none;
}

.hero-visual::before {
  top: 14px;
  left: 14px;
  border-right: 0;
  border-bottom: 0;
  border-top-left-radius: 7px;
}

.hero-visual::after {
  right: 14px;
  bottom: 14px;
  border-left: 0;
  border-top: 0;
  border-bottom-right-radius: 7px;
}

.frame-label {
  position: absolute;
  top: 24px;
  left: 27px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: rgba(169, 189, 202, .8);
  font: 600 .6rem/1 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .22em;
}

.frame-label::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--af-teal);
  box-shadow: 0 0 10px var(--af-teal);
}

.hero-feature {
  position: absolute;
  left: 20px;
  bottom: 58px;
  z-index: 3;
  display: flex;
  flex-direction: column;
  gap: 3px;
  max-width: calc(100% - 40px);
  padding: 12px 15px;
  border: 1px solid rgba(114, 228, 224, .3);
  border-radius: 13px;
  background: rgba(7, 13, 21, .72);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  color: var(--af-text);
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 14px 34px rgba(0, 0, 0, .3);
  transition: transform 200ms var(--ease), border-color 200ms ease, background 200ms ease;
}

.hero-feature:hover {
  transform: translateY(-2px);
  border-color: var(--af-teal);
  background: rgba(10, 20, 30, .88);
}

.hero-feature-kicker {
  color: var(--af-teal);
  font-size: .58rem;
  font-weight: 750;
  letter-spacing: .18em;
  text-transform: uppercase;
}

.hero-feature-title {
  font-size: 1rem;
  font-weight: 650;
  letter-spacing: -.01em;
}

.hero-caption {
  position: absolute;
  left: 22px;
  right: 22px;
  bottom: 19px;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  color: rgba(139, 165, 180, .9);
  font-size: .67rem;
  letter-spacing: .03em;
  text-shadow: 0 1px 6px rgba(0, 0, 0, .6);
}

.pulse-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--af-teal);
  animation: pulse 2.4s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(114, 228, 224, .5); }
  50% { box-shadow: 0 0 0 6px rgba(114, 228, 224, 0); }
}

/* --------------------------------------------------------------------------
   Pathways
   -------------------------------------------------------------------------- */

.pathways-section {
  padding-block: 26px 0;
  border-bottom: 1px solid rgba(114, 228, 224, .1);
  background: linear-gradient(180deg, rgba(11, 19, 30, .55), transparent 90%);
}

.pathways {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  list-style: none;
  padding-bottom: 26px;
}

.pathway {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 100%;
  padding: 15px 16px;
  border: 1px solid var(--af-border);
  border-radius: 14px;
  background: linear-gradient(150deg, rgba(17, 31, 46, .82), rgba(9, 15, 24, .62));
  color: var(--af-text);
  text-decoration: none;
  transition: transform 200ms var(--ease), border-color 200ms ease, box-shadow 200ms ease;
}

.pathway:hover {
  transform: translateY(-3px);
  border-color: var(--af-border-strong);
  box-shadow: 0 16px 34px rgba(0, 0, 0, .22), 0 0 26px rgba(63, 206, 218, .08);
}

.pathway-index {
  align-self: flex-start;
  margin-top: 2px;
  color: var(--af-subtle);
  font: 600 .66rem/1.4 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .06em;
}

.pathway-body { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }

.pathway-label { font-size: .95rem; font-weight: 650; letter-spacing: -.01em; }

.pathway-desc { color: var(--af-subtle); font-size: .76rem; line-height: 1.45; }

.pathway-count {
  flex: none;
  padding: 1px 8px;
  border: 1px solid rgba(114, 228, 224, .2);
  border-radius: 999px;
  color: var(--af-teal);
  font-size: .68rem;
  font-variant-numeric: tabular-nums;
}

.pathway-arrow {
  width: 17px;
  height: 17px;
  flex: none;
  color: var(--af-subtle);
  transition: transform 200ms ease, color 200ms ease;
}

.pathway:hover .pathway-arrow { transform: translateX(2px); color: var(--af-teal); }

/* --------------------------------------------------------------------------
   Sections
   -------------------------------------------------------------------------- */

.section { padding-block: clamp(52px, 7vw, 92px); }

.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 28px;
}

.section-heading-copy { min-width: 0; }

.section-heading h2 {
  margin: 12px 0 0;
  font-size: clamp(1.9rem, 3.4vw, 2.85rem);
  letter-spacing: -.048em;
  line-height: 1.08;
  text-wrap: balance;
}

.section-heading p {
  max-width: 62ch;
  margin: 12px 0 0;
  color: var(--af-muted);
}

.section-heading-actions {
  display: flex;
  align-items: center;
  gap: 18px;
  flex: none;
  padding-bottom: 4px;
}

.text-link {
  color: var(--af-teal);
  font-size: .87rem;
  font-weight: 650;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 160ms ease;
}

.text-link:hover { border-bottom-color: currentColor; }

.shelf-controls { display: flex; gap: 8px; }

.icon-button {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid var(--af-border);
  border-radius: 50%;
  background: rgba(12, 22, 34, .7);
  color: var(--af-muted);
  cursor: pointer;
  transition: color 160ms ease, border-color 160ms ease, background 160ms ease, opacity 160ms ease;
}

.icon-button svg { width: 18px; height: 18px; }

.icon-button:hover:not(:disabled) {
  color: var(--af-text);
  border-color: var(--af-border-strong);
  background: rgba(20, 38, 55, .9);
}

.icon-button:disabled { opacity: .32; cursor: default; }

/* --------------------------------------------------------------------------
   Project cards & shelf
   -------------------------------------------------------------------------- */

.shelf-wrap { position: relative; }

.project-shelf {
  grid-auto-columns: clamp(278px, 28.5vw, 352px);
  gap: 18px;
  padding: 6px 2px 20px;
}

.af-shelf:focus-visible { outline: 2px solid var(--af-teal); outline-offset: 3px; }

@media (min-width: 1100px) {
  .shelf-wrap::before,
  .shelf-wrap::after {
    content: "";
    position: absolute;
    top: 0;
    bottom: 22px;
    z-index: 2;
    width: 40px;
    pointer-events: none;
  }

  .shelf-wrap::before {
    left: -2px;
    background: linear-gradient(90deg, var(--af-bg) 8%, transparent);
  }

  .shelf-wrap::after {
    right: -2px;
    background: linear-gradient(-90deg, var(--af-bg) 8%, transparent);
  }
}

.p-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--af-border);
  border-radius: 16px;
  background: linear-gradient(160deg, rgba(17, 31, 47, .96), rgba(9, 15, 24, .99));
  box-shadow: 0 18px 38px rgba(0, 0, 0, .22);
  transition: transform 240ms var(--ease), border-color 240ms ease, box-shadow 240ms ease;
}

.p-card:hover {
  transform: translateY(-5px);
  border-color: var(--af-border-strong);
  box-shadow: 0 28px 56px rgba(0, 0, 0, .34), 0 0 36px rgba(63, 206, 218, .13);
}

.p-card:has(.p-open:focus-visible) {
  border-color: var(--af-teal);
  box-shadow: 0 0 0 3px rgba(114, 228, 224, .28), 0 24px 50px rgba(0, 0, 0, .3);
}

.p-art {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-bottom: 1px solid var(--af-border);
  background: #09111c;
}

.p-art canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  transition: transform 600ms var(--ease);
}

.p-card:hover .p-art canvas { transform: scale(1.035); }

.p-art::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  box-shadow: inset 0 0 46px rgba(4, 9, 15, .65);
  background: linear-gradient(180deg, rgba(5, 10, 16, .25), transparent 38%, rgba(5, 10, 16, .35));
  pointer-events: none;
}

.p-kicker,
.p-status {
  position: absolute;
  top: 11px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.p-kicker {
  left: 11px;
  border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(5, 11, 18, .55);
  color: rgba(230, 246, 250, .85);
}

.p-status {
  right: 11px;
  border: 1px solid currentColor;
  background: rgba(5, 11, 18, .55);
}

.p-status::before {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 8px currentColor;
}

.status-live { color: var(--status-live); }
.status-testing { color: var(--status-testing); }
.status-prototype { color: var(--status-prototype); }
.status-concept { color: var(--status-concept); }

.p-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 9px;
  padding: 18px 18px 16px;
}

.p-title {
  margin: 0;
  font-size: 1.16rem;
  font-weight: 690;
  letter-spacing: -.025em;
  line-height: 1.25;
}

.p-tagline {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
  color: var(--af-muted);
  font-size: .88rem;
  line-height: 1.58;
}

.p-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: auto 0 0;
  padding: 11px 0 0;
  border-top: 1px solid rgba(114, 228, 224, .1);
  list-style: none;
}

.p-tags li {
  padding: 3px 8px;
  border: 1px solid rgba(114, 228, 224, .14);
  border-radius: 999px;
  color: var(--af-subtle);
  font-size: .68rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.p-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--af-teal);
  font-size: .78rem;
  font-weight: 650;
}

.p-foot svg { width: 14px; height: 14px; transition: transform 200ms ease; }

.p-card:hover .p-foot svg { transform: translate(2px, -2px); }

.p-open {
  position: absolute;
  inset: 0;
  z-index: 3;
  padding: 0;
  border: 0;
  border-radius: inherit;
  background: transparent;
  cursor: pointer;
}

.p-open:focus { outline: none; }

/* --------------------------------------------------------------------------
   Catalog
   -------------------------------------------------------------------------- */

.catalog-toolbar {
  display: grid;
  grid-template-columns: minmax(240px, 340px) minmax(0, 1fr);
  align-items: center;
  gap: 14px 20px;
  margin-bottom: 26px;
}

.search-field {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  height: 48px;
  padding: 0 8px 0 14px;
  border: 1px solid var(--af-border);
  border-radius: 12px;
  background: rgba(11, 20, 32, .82);
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.search-field:focus-within {
  border-color: rgba(114, 228, 224, .6);
  box-shadow: 0 0 0 4px rgba(114, 228, 224, .1);
}

.search-field > svg { width: 17px; height: 17px; color: var(--af-subtle); }

.search-field input {
  flex: 1;
  min-width: 0;
  height: 100%;
  border: 0;
  background: transparent;
  color: var(--af-text);
  font-size: .92rem;
  outline: none;
}

.search-field input::placeholder { color: var(--af-subtle); }

.search-field input::-webkit-search-cancel-button { display: none; }

.search-clear {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--af-muted);
  cursor: pointer;
  transition: background 160ms ease, color 160ms ease;
}

.search-clear:hover { background: rgba(114, 228, 224, .1); color: var(--af-text); }

.search-clear svg { width: 14px; height: 14px; }

.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.filter-chip {
  height: 38px;
  padding: 0 14px;
  border: 1px solid var(--af-border);
  border-radius: 999px;
  background: rgba(12, 21, 33, .6);
  color: var(--af-muted);
  font-size: .82rem;
  font-weight: 600;
  cursor: pointer;
  transition: color 160ms ease, border-color 160ms ease, background 160ms ease;
}

.filter-chip:hover { color: var(--af-text); border-color: var(--af-border-strong); }

.filter-chip[aria-pressed="true"] {
  color: #b6fffb;
  border-color: rgba(114, 228, 224, .55);
  background: rgba(114, 228, 224, .13);
  box-shadow: inset 0 0 20px rgba(114, 228, 224, .08);
}

.result-count {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--af-subtle);
  font-size: .73rem;
  font-weight: 600;
  letter-spacing: .13em;
  text-transform: uppercase;
}

.catalog-grid {
  grid-template-columns: repeat(auto-fill, minmax(268px, 1fr));
  gap: 18px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: clamp(38px, 6vw, 64px) 22px;
  border: 1px dashed rgba(114, 228, 224, .28);
  border-radius: 18px;
  background: radial-gradient(ellipse at 50% 0%, rgba(50, 180, 197, .08), transparent 70%);
  text-align: center;
}

.empty-state[hidden] { display: none; }

.empty-state h3 {
  margin: 4px 0 0;
  font-size: 1.4rem;
  letter-spacing: -.03em;
}

.empty-state p { max-width: 46ch; margin: 0; color: var(--af-muted); }

.empty-state .af-btn { margin-top: 12px; }

/* --------------------------------------------------------------------------
   Testing
   -------------------------------------------------------------------------- */

.testing {
  border-top: 1px solid var(--af-border);
  background: radial-gradient(ellipse at 8% 0%, rgba(44, 157, 174, .09), transparent 52%);
}

.testing-grid {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  align-items: start;
  gap: clamp(28px, 5vw, 72px);
}

.testing-copy h2 {
  margin: 12px 0 0;
  font-size: clamp(2rem, 3.6vw, 3rem);
  letter-spacing: -.05em;
  line-height: 1.05;
}

.testing-copy > p { margin: 18px 0 0; color: var(--af-muted); max-width: 48ch; }

.af-note { margin-top: 24px; font-size: .87rem; }

.testing-list {
  list-style: none;
  border-top: 1px solid var(--af-border);
}

.testing-item {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 17px 4px;
  border-bottom: 1px solid var(--af-border);
  transition: padding 200ms ease, background 200ms ease;
}

.testing-item:hover { padding-inline: 12px; background: rgba(114, 228, 224, .045); }

.testing-index {
  color: var(--af-subtle);
  font: 600 .7rem/1.4 ui-monospace, SFMono-Regular, Menlo, monospace;
}

.testing-title {
  margin: 0;
  font-size: 1.02rem;
  font-weight: 650;
  letter-spacing: -.015em;
}

.testing-desc { margin: 3px 0 0; color: var(--af-subtle); font-size: .82rem; }

.testing-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border: 1px solid rgba(242, 192, 120, .45);
  border-radius: 999px;
  background: rgba(242, 192, 120, .08);
  color: var(--status-testing);
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  white-space: nowrap;
}

.testing-chip::before {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: currentColor;
}

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

.site-footer {
  border-top: 1px solid var(--af-border);
  padding-block: clamp(40px, 6vw, 64px) 26px;
  background: linear-gradient(180deg, #0a131f, #070c13 80%);
}

.footer-top {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 40px;
  padding-bottom: 34px;
  border-bottom: 1px solid rgba(114, 228, 224, .12);
}

.footer-brand p {
  max-width: 40ch;
  margin: 16px 0 0;
  color: var(--af-muted);
  font-size: .9rem;
}

.footer-nav {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  justify-self: end;
  width: min(100%, 420px);
}

.footer-nav h2 {
  margin: 0 0 10px;
  color: var(--af-subtle);
  font-size: .69rem;
  font-weight: 700;
  letter-spacing: .17em;
  text-transform: uppercase;
}

.footer-nav a {
  display: block;
  padding: 4px 0;
  color: var(--af-muted);
  font-size: .87rem;
  text-decoration: none;
  transition: color 160ms ease;
}

.footer-nav a:hover { color: var(--af-teal); }

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px 24px;
  padding-top: 22px;
  color: var(--af-subtle);
  font-size: .75rem;
}

.footer-bottom p { margin: 0; }

/* --------------------------------------------------------------------------
   Project dialog
   -------------------------------------------------------------------------- */

.project-dialog {
  width: min(880px, calc(100vw - 28px));
  max-height: min(88vh, 920px);
  padding: 0;
  overflow: auto;
  border: 1px solid rgba(114, 228, 224, .3);
  border-radius: 20px;
  background: linear-gradient(160deg, #111f2f, #080e17 82%);
  color: var(--af-text);
  box-shadow: 0 44px 120px rgba(0, 0, 0, .65);
}

.project-dialog::backdrop {
  background: rgba(3, 7, 12, .74);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.project-dialog[open] { animation: dialogIn 220ms var(--ease); }

@keyframes dialogIn {
  from { opacity: 0; transform: translateY(14px) scale(.985); }
  to { opacity: 1; transform: none; }
}

.dialog-shell { position: relative; }

.dialog-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 4;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255, 255, 255, .2);
  border-radius: 50%;
  background: rgba(6, 12, 19, .62);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: #e6f6fa;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease;
}

.dialog-close:hover { background: rgba(15, 28, 42, .9); border-color: var(--af-teal); }

.dialog-close svg { width: 16px; height: 16px; }

.dialog-art {
  position: relative;
  aspect-ratio: 21 / 9;
  min-height: 170px;
  overflow: hidden;
  border-bottom: 1px solid var(--af-border);
  background: #09121d;
}

.dialog-art canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }

.dialog-status {
  position: absolute;
  left: 20px;
  bottom: 16px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border: 1px solid currentColor;
  border-radius: 999px;
  background: rgba(5, 11, 18, .6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.dialog-status::before {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: currentColor;
}

.dialog-body { padding: clamp(22px, 4vw, 34px); }

.dialog-body h2 {
  margin: 10px 0 0;
  font-size: clamp(1.6rem, 3.4vw, 2.25rem);
  letter-spacing: -.045em;
  line-height: 1.1;
}

.dialog-tagline { margin: 12px 0 0; color: #cfe2ec; font-size: 1rem; }

.dialog-description { max-width: 66ch; margin: 14px 0 0; color: var(--af-muted); }

.dialog-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}

.dialog-tags li {
  padding: 3px 9px;
  border: 1px solid rgba(114, 228, 224, .18);
  border-radius: 999px;
  color: var(--af-muted);
  font-size: .7rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.dialog-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 26px;
  padding-top: 20px;
  border-top: 1px solid rgba(114, 228, 224, .14);
}

.dialog-link-state { color: var(--af-subtle); font-size: .8rem; }

.dialog-note { margin: 16px 0 0; color: rgba(120, 147, 165, .9); font-size: .72rem; }

html.dialog-open,
html.dialog-open body { overflow: hidden; }

/* --------------------------------------------------------------------------
   Scroll reveal
   -------------------------------------------------------------------------- */

.reveal-pending {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 620ms var(--ease), transform 620ms var(--ease);
}

.reveal-pending.is-in { opacity: 1; transform: none; }

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 1120px) {
  .pathways { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .catalog-toolbar { grid-template-columns: minmax(220px, 300px) minmax(0, 1fr); }
}

@media (max-width: 980px) {
  :root { --header-h: 66px; }

  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero h1 { max-width: 15ch; }
  .hero-visual { aspect-ratio: 16 / 10; min-height: 280px; max-height: 420px; }

  .catalog-toolbar {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .search-field { max-width: none; }
  .filter-row { justify-content: flex-start; }

  .testing-grid { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; gap: 30px; }
  .footer-nav { justify-self: start; }
}

@media (max-width: 860px) {
  .header-inner { gap: 12px; }
  .brand-word { font-size: .7rem; letter-spacing: .13em; }
  .brand-mark { width: 24px; height: 24px; }
  .site-nav a { padding: 7px 9px; font-size: .8rem; }
  .search-trigger { width: 38px; padding: 0; justify-content: center; }
  .search-trigger span, .search-trigger kbd { display: none; }
}

@media (max-width: 760px) {
  .section-heading {
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
  }

  .section-heading-actions { width: 100%; justify-content: space-between; }

  .pathways { grid-template-columns: 1fr; }
  .pathway { padding: 13px 15px; }

  .project-shelf { grid-auto-columns: min(82vw, 330px); }

  .footer-bottom { flex-direction: column; }
}

@media (max-width: 640px) {
  :root { --header-h: 104px; }

  .header-inner {
    flex-wrap: wrap;
    row-gap: 0;
    padding-block: 6px 0;
  }

  .brand { margin-right: auto; }
  .search-trigger { order: 2; }

  .site-nav {
    order: 3;
    flex: 1 1 100%;
    padding-block: 2px 8px;
  }

  .site-nav { gap: 0; }
  .site-nav a { padding: 6px 7px; font-size: .79rem; }
}

@media (max-width: 560px) {
  .hero { padding-block: 44px 46px; }
  .hero h1 { font-size: clamp(2.7rem, 12.5vw, 4rem); }
  .hero-actions .af-btn { flex: 1 1 100%; }
  .hero-meta { gap: 8px 16px; font-size: .68rem; }
  .hero-visual { min-height: 250px; border-radius: 18px; }
  .hero-feature { left: 14px; bottom: 52px; padding: 10px 12px; }
  .hero-caption { left: 16px; right: 16px; font-size: .62rem; }

  .catalog-grid { grid-template-columns: 1fr; }
  .filter-row { gap: 6px; }
  .filter-chip { height: 34px; padding: 0 11px; font-size: .78rem; }

  .testing-item { grid-template-columns: 24px minmax(0, 1fr); row-gap: 8px; }
  .testing-chip { grid-column: 2; justify-self: start; }

  .dialog-art { aspect-ratio: 16 / 10; }
  .dialog-actions { flex-direction: column; align-items: flex-start; }
  .dialog-actions .af-btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  .pulse-dot { animation: none !important; }
  .project-dialog[open] { animation: none !important; }
  .reveal-pending { opacity: 1; transform: none; }
  .p-card:hover { transform: none; }
  .p-card:hover .p-art canvas { transform: none; }
  .hero-feature:hover, .pathway:hover { transform: none; }
}
