@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;0,700;1,300;1,400&family=Inconsolata:wght@300;400&family=Lora:ital,wght@0,400;0,500;1,400&display=swap');

:root {
    --paper:   #f7f5f1;
    --ink:     oklch(0.22 0.005 60);
    --dark-mid: oklch(0.32 0.005 60);
    --mid:     oklch(0.42 0.005 60);
    --light:   oklch(0.45 0.006 70);
    --whisper: oklch(0.78 0.006 75);
    --faint:   #ece9e3;
    --smudge:  #d8d4cc;
  }

  * { margin: 0; padding: 0; box-sizing: border-box; }
  html { scroll-behavior: smooth; }

  body {
    background: var(--paper);
    color: var(--ink);
    font-family: 'Cormorant Garamond', serif;
    font-weight: 300;
    line-height: 1.75;
    overflow-x: hidden;
    cursor: none;
  }

  /* Paper grain */
  body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='400' height='400'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='400' height='400' filter='url(%23n)' opacity='0.035'/%3E%3C/svg%3E");
    pointer-events: none;
    z-index: 999;
    opacity: 0.45;
    mix-blend-mode: multiply;
  }

  /* Charcoal cursor canvas */
  #charcoal-cursor {
    position: fixed;
    inset: 0;
    z-index: 1000;
    pointer-events: none;
    mix-blend-mode: multiply;
  }

  #crosshair-cursor {
    position: fixed;
    inset: 0;
    z-index: 1001;
    pointer-events: none;
    mix-blend-mode: difference;
  }

  /* ── CURSOR TOGGLE ── */
  .cursor-toggle {
    position: fixed;
    bottom: 1.4rem;
    right: 1.6rem;
    z-index: 2000;
    font-family: 'Inconsolata', monospace;
    font-size: 0.68rem;
    letter-spacing: 0.13em;
    text-transform: uppercase;
    color: var(--mid);
    background: var(--faint);
    border: 1px solid var(--smudge);
    border-radius: 0;
    padding: 0.55em 0.85em 0.45em;
    line-height: 1;
    cursor: auto !important;
    transition: background 0.2s, color 0.2s;
  }
  .cursor-toggle:hover {
    background: var(--smudge);
    color: var(--ink);
  }

  /* When cursor is off — restore system cursor everywhere */
  body.cursor-off { cursor: auto !important; }
  body.cursor-off a,
  body.cursor-off button,
  body.cursor-off .cursor-toggle,
  body.cursor-off .video-thumb,
  body.cursor-off .video-link { cursor: pointer !important; }
  body.cursor-off .gallery-lightbox { cursor: crosshair !important; }
  body.cursor-off #charcoal-cursor,
  body.cursor-off #crosshair-cursor { display: none; }

  /* ── BACKGROUND ── */
  .bg {
    position: fixed;
    top: -10%; left: 0; right: 0;
    height: 120vh;
    z-index: 0;
    pointer-events: none;
  }

  .bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.13;
    mix-blend-mode: multiply;
    -webkit-mask-image: radial-gradient(ellipse 80% 85% at center, black 30%, transparent 100%);
    mask-image: radial-gradient(ellipse 80% 85% at center, black 30%, transparent 100%);
  }

  @media (max-width: 720px) {
    .bg img {
      object-position: center 40%;
      opacity: 0.1;
      -webkit-mask-image: radial-gradient(ellipse 100% 70% at center, black 25%, transparent 100%);
      mask-image: radial-gradient(ellipse 100% 70% at center, black 25%, transparent 100%);
    }
  }

    /* ── STAMP MARK ── */
  .stamp-wrap {
    width: 64px;
    height: 64px;
    flex-shrink: 0;
    margin-top: 0.2rem;
  }

  /* Nav/main/footer cover the bg as content scrolls over it */
  nav, main, footer {
    position: relative;
    z-index: 2;
  }

  /* Nav always covers bg */
  nav { background: var(--paper); }

  /* ── INK SWEEP WRAPPER — constrains and centers sweep width ── */
  .sweep-wrap {
    width: 100%;
    margin: 0 auto;
  }

  /* Ink sweep divider */
  .ink-sweep {
    margin: 1.5rem 0 2rem;
  }
  #sweep-info,
  #sweep-early {
    margin-top: 0.9rem;
    margin-bottom: 1.5rem;
  }

  /* ── OPENING ── */
  .opening {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 6rem clamp(2rem, 5vw, 5rem) 4rem;
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
  }

  .opening-eyebrow {
    font-family: 'Inconsolata', monospace;
    font-size: 0.88rem;
    letter-spacing: 0.38em;
    text-transform: uppercase;
    color: var(--ink);
    margin-bottom: 2.5rem;
    opacity: 0;
    animation: m-fade 1.2s ease-out 0.3s forwards;
  }

  .opening h1 {
    font-weight: 300;
    font-size: clamp(3rem, 9vw, 10rem);
    letter-spacing: -0.01em;
    line-height: 0.95;
    white-space: nowrap;
    opacity: 0;
    animation: m-rise 1.6s ease-out 0.6s forwards;
  }

  .opening h1 em { font-style: italic; }

  /* Flourish canvas sits here */
  .opening-flourish {
    margin: 1.2rem 0 1.8rem -0.3rem;
    opacity: 0;
    animation: m-fade 1.4s ease-out 1.8s forwards;
  }

  .opening-role {
    font-family: 'Inconsolata', monospace;
    font-size: 0.82rem;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: var(--ink);
    opacity: 0;
    animation: m-fade 1.2s ease-out 2.1s forwards;
  }

  .opening-epigraph {
    margin-top: 1.8rem;
    max-width: 72ch;
    font-size: clamp(1.15rem, 1.8vw, 1.45rem);
    line-height: 1.75;
    color: var(--ink);
    font-style: italic;
    letter-spacing: 0.03em;
    opacity: 0;
    animation: m-fade 1.4s ease-out 2.5s forwards;
  }

  @keyframes m-rise {
    from { opacity: 0; transform: translateY(18px); }
    to   { opacity: 1; transform: none; }
  }
  @keyframes m-fade {
    from { opacity: 0; }
    to   { opacity: 1; }
  }

  /* ── NAV ── */
  nav {
    position: sticky;
    top: 0;
    z-index: 40;
    background: var(--faint);
    border: 1px solid var(--smudge);
    border-top: none;
    border-radius: 0 0 6px 6px;
    padding: 0;
  }

  nav ul {
    list-style: none;
    display: flex;
    gap: 0;
    max-width: 1200px;
    margin: 0 auto;
    flex-wrap: wrap;
    padding: 0 clamp(2rem, 5vw, 5rem);
  }

  nav ul li a {
    display: inline-block;
    margin: 0.75rem 0.5rem 0.75rem 0;
    padding: 0.4em 1em;
    font-family: 'Inconsolata', monospace;
    font-size: 0.88rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    line-height: 1;
    color: var(--ink);
    text-decoration: none;
    background: transparent;
    transition: background 0.2s;
  }

  nav ul li a:hover {
    background: var(--smudge);
  }
  a { cursor: none; }

  /* ── FOCUS STYLES — keyboard navigation ── */
  a:focus-visible,
  button:focus-visible {
    outline: 2px solid var(--ink);
    outline-offset: 3px;
    border-radius: 1px;
  }

  /* ── MAIN ── */
  /* Main is full width with solid bg — no gaps for dancer to show through */
  main {
    width: 100%;
  }

  /* Inner wrapper constrains content width and provides margins */
  .content-wrap {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 clamp(2rem, 5vw, 5rem);
  }

  /* Full-width paper wrapper — covers dancer edge to edge */
  .paper-zone {
    background: var(--paper);
    width: 100%;
    padding: 4rem 0 6rem 0;
  }

  .ink-sweep {
    width: 100%;
    margin-left: 0;
  }

  /* ── SECTION HEADER — unified ── */
  .section-head {
    padding: 2rem 0 0;
    display: flex;
    align-items: baseline;
    gap: 1.2rem;
    flex-wrap: wrap;
    scroll-margin-top: 60px; /* adjust to match your nav height */
  }

  .section-head h2 {
    font-size: clamp(2.6rem, 3.8vw, 3.8rem);
    font-weight: 500;
    font-style: italic;
    letter-spacing: 0.04em;
  }

  .section-note {
    font-family: 'Inconsolata', monospace;
    font-size: 0.88rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--light);
  }

  .section-intro {
    font-size: 1.1rem;
    letter-spacing: 0.01em;
    line-height: 1.85;
    color: var(--ink);
    font-family: 'Lora', serif;
    font-weight: 400;
    margin-bottom: 1.5rem;
  }

  /* ── FULL ENTRY — AI Interaction ── */
  .entry-full {
    display: grid;
    grid-template-columns: 52px 1fr;
    gap: 1.8rem 2.5rem;
    align-items: start;
    margin-bottom: 4rem;
    padding-bottom: 4rem;
    border-bottom: 1px solid var(--faint);
  }

  .entry-year {
    font-family: 'Inconsolata', monospace;
    font-size: 0.82rem; 
    letter-spacing: 0.20em; 
    color: var(--light); 
    margin-bottom: 0.5rem;
  }

  .entry-body {
    font-size: 1.1rem;
    letter-spacing: 0.01em;
    line-height: 1.85;
    color: var(--dark-mid);
    font-weight: 400;
    font-family: 'Lora', serif;
  }
  .entry-body p { margin-bottom: 0.8rem; }


  /* Entry header — year + title spans full width above image+text */
  .entry-header {
    margin-bottom: 1.2rem;
  }

  .entry-header h3 {
    font-size: clamp(1.9rem, 2.3vw, 2.3rem);
    font-weight: 500;
    line-height: 1.25;
    margin-top: 0.5rem;
  }

  /* Entry left — just holds the image, no stacking needed anymore */
  .entry-left {
    display: flex;
    flex-direction: column;
  }

  /* Inner content area: image + text side by side, reflection below */
  .entry-content {
    display: flex;
    flex-direction: column;
    gap: 1.0rem;
  }

  .entry-content-row {
    display: grid;
    grid-template-columns: 45fr 55fr;
    gap: 1rem 2rem;
    align-items: start;
  }

  .entry-full.flip .entry-content-row {
    grid-template-columns: 55fr 45fr;
  }

  .entry-full.img-large .entry-content-row {
    grid-template-columns: 57fr 43fr;
  }
  .entry-full.img-large.flip .entry-content-row {
    grid-template-columns: 43fr 57fr;
  }

  .entry-full.flip .entry-content-row .entry-visual {
    order: 2;
  }

  .entry-full.flip .entry-content-row .entry-body {
    order: 1;
  }

  .entry-full .reflection {
    width: 100%;
    max-width: none;
  }

  .entry-visual {
    aspect-ratio: 4/3;
    overflow: hidden;
    display: flex;
    flex-direction: column;
  }

  .entry-visual .img-overlay-wrap,
  .entry-visual > img {
    border: 1px solid rgba(216,212,204,0.55);
  }

  .entry-visual img {
    width: 100%; height: 100%;
    object-fit: cover;
    display: block;
  }

  .image-credit {
    font-family: 'Inconsolata', monospace;
    font-size: 0.58rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    margin-top: 0.4rem;
    margin-left: 0.4em;
    text-align: left;
  }


  .reflection {
    padding: 0.2rem 0.9rem;
    border-left: 1px solid var(--ink);
    font-family: 'Lora', serif;
    font-style: italic;
    font-size: 0.95rem;
    letter-spacing: 0.01em;
    color: var(--dark-mid);
    line-height: 1.8;
  }

  .link-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 0.6rem;
    margin-top: 0.9rem;
  }
  .link-row .entry-link {
    margin-top: 0;
  }

  .entry-link {
    display: inline-block;
    margin-top: 0.9rem;
    font-family: 'Inconsolata', monospace;
    font-size: 0.72rem;
    letter-spacing: 0.13em;
    text-transform: uppercase;
    color: var(--mid);
    text-decoration: none;
    background: var(--faint);
    border: 1px solid var(--smudge);
    border-radius: 0;
    padding: 0.65em 0.85em 0.55em;
    line-height: 1;
    transition: background 0.2s, color 0.2s;
  }
  .entry-link:hover {
    background: var(--smudge);
    color: var(--ink);
  }
  .non-link {
    display: inline-block;
    margin-top: 0.9rem; 
    font-family:'Inconsolata', monospace; 
    font-size:0.74rem; 
    letter-spacing:0.14em; 
    text-transform:uppercase; 
    color:var(--ink); 
    cursor:none;
  }

  /* Text-only entry — no image column */
  .entry-full.text-only .entry-content-row {
    grid-template-columns: 1fr;
  }
  .entry-full.text-only .entry-visual {
    display: none;
  }


  /* ── IMAGE HOVER OVERLAY ── */
  .img-overlay-wrap {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
  }

  .img-overlay-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: opacity 0.4s ease;
  }

  .img-overlay-wrap:hover img {
    opacity: .1;
  }

  .img-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
    padding: 1.5rem;
    text-align: center;
    background: rgba(236,233,227,0.3);
  }

  .img-overlay::before {
    content: '';
    position: absolute; inset: 0;
    background: repeating-linear-gradient(
      -45deg, transparent, transparent 10px,
      rgba(26,24,20,0.03) 10px, rgba(26,24,20,0.03) 11px
    );
  }

  .img-overlay-wrap:hover .img-overlay {
    opacity: 1;
  }

  .img-overlay-label {
    font-family: 'Inconsolata', monospace;
    font-size: 0.9rem;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: var(--dark-mid);
    line-height: 1.8;
    position: relative;
    z-index: 1;
  }

  .img-overlay-mark {
    width: 38px;
    height: 38px;
    opacity: 0.8;
    position: relative;
    z-index: 1;
  }

  /* Keep overlay hidden by default on mobile too */
  @media (hover: none) {
    .img-overlay-wrap .img-overlay {
      transition: opacity 0.3s ease;
    }
  }

  /* ── MARGIN SKETCHES ── */
  /* ── THUMBNAIL CARDS ── */
  .thumbnails-section {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
  }

  .thumbnail-note {
    font-weight: 400;
    font-family: 'Lora', serif;
    background: rgba(251,250,247,0.92);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border: 1px solid rgba(216,212,204,0.55);
    padding: 1.9rem 2rem 1.4rem;
    font-size: 1.0rem;
    letter-spacing: 0.02em;
    line-height: 1.8;
    color: var(--dark-mid);
    font-style: normal;
    display: flex;
    flex-direction: column;
  }

  .thumbnail-note h3 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.6rem;
    font-weight: 500;
    line-height: 1.3;
    color: var(--ink);
  }

  .thumb-action {
    margin-top: auto;
    padding-top: 1rem;
  }
  .thumb-action .entry-link,
  .thumb-action .non-link {
    margin-top: 0;
  }

  .thumb-image {
    padding-top: 0.75rem;
    overflow: hidden;
  }

  .thumb-image img {
    width: 100%;
    display: block;
    object-fit: cover;
    max-height: 220px;
  }

  .thumb-title-row {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    margin-bottom: 0.6rem;
  }

  .thumb-stamp {
    width: 36px;
    height: 36px;
    flex-shrink: 0;
    opacity: 0.7;
  }


    /* ── THUMBNAILS WINDOW — transparent, dancer shows through ── */
  .thumbnails-window {
    position: relative;
    z-index: 2;
    width: 100%;
    padding: 4rem 0 6rem 0;
    background: transparent;
  }

  .thumbnails-window .section-note {
    color: var(--mid);
  }

  .thumb-date {
    display: block;
    font-family: 'Inconsolata', monospace;
    font-size: 0.82rem;
    letter-spacing: 0.20em;
    color: var(--light);
  }

  .content-wrap-inset {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 clamp(2rem, 5vw, 5rem);
  }


  /* ── PATENTS — clean list, no section-head treatment ── */
  .patents { 
    padding: 4rem 0 3rem; 
    margin-bottom: 3rem;
  }
  .patent-list { list-style: none; }
  .patent-list li {
    display: grid;
    grid-template-columns: 90px 1fr;
    gap: 0.75rem;
    padding: 0.9rem 0;
    border-top: 1px solid var(--faint);
    align-items: baseline;
    font-family: 'Lora', serif;
    font-size: 1.0rem;
    letter-spacing: 0.02em;
    color: var(--dark-mid);
    line-height: 1.75;
  }
  .patent-list li:last-child { border-bottom: 1px solid var(--faint); }
  .patent-status {
    font-family: 'Inconsolata', monospace;
    font-size: 0.72rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--mid);
    min-width: 7rem;
    display: inline-block;
  }

  /* ── PATENTS WINDOW — transparent, narrow, centered ── */
  .patents-window {
    position: relative;
    z-index: 2;
    width: 100%;
    padding: 4rem 0 6rem 0;
    background: transparent;
  }

  .patents-window .section-note {
    color: var(--mid);
  }
  
  .patents-inset {
    max-width: 1040px;
    margin: 0 auto;
    padding: 0 clamp(2rem, 5vw, 5rem);
  }

  .patents-window .patents {
    background: rgba(251,250,247,0.92);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border: 1px solid rgba(216,212,204,0.55);
    padding: 2.5rem 3rem;
    border-top: none;
  }

    /* ── TILE GRID — Communication, Visual ── */
  .entries-mid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem 2rem;
    margin-bottom: 3rem;
  }

  .entry-mid { padding-top: 1rem; }

  .entry-mid h3 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.9rem;
    font-weight: 500;
    line-height: 1.3;
    margin-bottom: 0.35rem;
  }

  .entry-mid .mid-visual {
    width: 100%; aspect-ratio: 16/9; overflow: hidden;
    margin-bottom: 0.9rem; background: var(--faint);
    display: flex; align-items: center; justify-content: center;
  }
  .entry-mid .mid-visual img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    display: block; 
  }

  .entry-mid p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--dark-mid);
    font-weight: 400;
    font-family: 'Lora', serif;
  }

  /* ── EARLY WORK CONTEXT LIST ── */
  .early-context-list {
    list-style: none;
    margin-top: 1rem;
    margin-bottom: 3rem;
    background: rgba(251,250,247,0.92);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border: 1px solid rgba(216,212,204,0.55);
    padding: 1.5rem 2.3rem;
  }

  .early-context-list li {
    display: grid;
    grid-template-columns: 50px 1fr auto;
    grid-template-rows: auto auto;
    gap: 0.0rem 2rem;
    padding: 1.1rem 0;
    border-bottom: 1px solid var(--faint);
    align-items: baseline;
  }

  .early-context-list li:last-child {
    border-bottom: none;
  }

  .early-context-stamp {
    width: 36px;
    height: 36px;
    flex-shrink: 0;
    opacity: 0.6;
    grid-column: 1;
    grid-row: 1/3;
    align-self: start;
    margin-top: 0.25rem;
  }

  .early-context-title {
    font-size: 1.6rem;
    font-weight: 500;
    color: var(--ink);
    grid-column: 2; grid-row: 1;
  }

  .early-context-year {
    font-family: 'Inconsolata', monospace;
    font-size: 0.68rem;
    letter-spacing: 0.16em;
    color: var(--light);
    grid-column: 3; grid-row: 1;
    text-align: right;
  }

  .early-context-note {
    font-size: 1.0rem;
    letter-spacing: 0.02em;
    line-height: 1.8;
    color: var(--dark-mid);
    font-weight: 400;
    font-family: 'Lora', serif;
    grid-column: 2 / 4; grid-row: 2;
  }

/* ── DESIGNER'S STATEMENT WINDOW ── */
  .statement-window {
    position: relative;
    z-index: 2;
    width: 100%;
    padding: 6rem 0 4rem;
    background: transparent;
  }

  .statement-window .section-note {
    color: var(--mid);
  }

  .statement-inset {
    max-width: 1040px;
    margin: 0 auto;
    padding: 0 clamp(2rem, 5vw, 5rem);
  }

  .statement-paper {
    background: rgba(251,250,247,0.92);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(216,212,204,0.5);
    padding: 3rem 3.5rem;
    margin-top: 2rem;
  }

  .statement-body {
    font-size: 1.1rem;
    line-height: 1.9;
    color: var(--ink);
    font-weight: 400;
    font-family: 'Lora', serif;
  }

  .statement-body p { margin-bottom: 1.4rem; }

  .statement-close { font-size: 1.1rem; color: var(--ink); }

  .statement-signature { margin-top: 3rem; padding-top: 2rem; }

  .statement-name {
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 300; letter-spacing: -0.01em;
    line-height: 0.95; font-style: normal;
    color: var(--ink); margin-bottom: 1rem;
  }

  .statement-name em { font-style: italic; }

  .statement-flourish { display: block; width: 280px; height: 32px; }


  /* ── FOOTER ── */
  footer {
    width: 100%;
    padding: 0;
    position: relative;
  }

  .footer-left {
    display: flex;
    align-items: center;
    gap: 1.4rem;
    flex-direction: row; /* add this */
  }

  .footer-stamp {
    width: 52px;
    height: 52px;
    flex-shrink: 0;
    opacity: 0.75;
  }

  .footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
  }

  .footer-transparent .footer-inner {
    position: absolute;
    left: clamp(2rem, 5vw, 5rem);
    right: clamp(2rem, 5vw, 5rem);
  }

  .contact {
    display: flex;
    gap: 2.5rem; /* adjust as needed */
  }

  footer .contact a {
    display: inline;
    font-family: 'Inconsolata', monospace;
    font-size: 0.82rem;
    letter-spacing: 0.12em;
    color: var(--dark-mid);
    text-decoration: none;
    line-height: 2.2;
    transition: color 0.2s;
  }

  footer .contact a:hover { 
    color: var(--ink);
    text-decoration: underline;
    text-underline-offset: 8px;
  }

  footer .built {
    font-family: 'Inconsolata', monospace;
    font-size: 0.6rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--light);
    text-align: right;
    line-height: 2;
  }

  footer:not(.footer-transparent) {
    padding: 3rem clamp(2rem, 5vw, 5rem);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 2rem;
  }

    /* ── FOOTER TRANSPARENT — dancer shows through at end ── */
  .footer-transparent {
    background: transparent !important;
    height:250px;
  }

  .footer-transparent .contact a { color: var(--dark-mid); }
  .footer-transparent .contact a:hover { color: var(--ink); }

  /* ── MOBILE NAV HAMBURGER ── */
  .nav-hamburger {
    display: none;
  }

  /* ── MOBILE FULL-SCREEN OVERLAY ── */
  .nav-overlay {
    display: none;
  }

  /* ── REVEAL ── */
  .reveal {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.9s ease, transform 0.9s ease;
  }

  .reveal.visible {
    opacity: 1;
    transform: none;
  }

  /* ── RESPONSIVE ── */
  @media (max-width: 720px) {
    html, body { overflow-x: clip; }

    /* Hide desktop nav links, show hamburger */
    nav ul { display: none; }
    nav.nav-simple ul { display: flex; }

    .nav-hamburger {
      display: flex;
      flex-direction: column;
      justify-content: space-between;
      width: 28px;
      height: 18px;
      background: none;
      border: none;
      cursor: pointer;
      padding: 0;
      margin: 0 auto 0 clamp(1.5rem, 5vw, 5rem);
      align-self: center;
    }

    nav {
      display: flex;
      align-items: center;
      min-height: 52px;
      position: sticky;
      top: 0;
    }

    .nav-hamburger span {
      display: block;
      width: 100%;
      height: 1px;
      background: var(--ink);
      transition: opacity 0.2s;
    }

    /* Full-screen overlay */
    .nav-overlay {
      display: flex;
      flex-direction: column;
      justify-content: center;
      position: fixed;
      inset: 0;
      z-index: 200;
      background: var(--paper);
      padding: 4rem clamp(2rem, 8vw, 5rem);
      opacity: 0;
      pointer-events: none;
      transition: opacity 0.35s ease;
    }

    .nav-overlay.open {
      opacity: 1;
      pointer-events: all;
    }

    .nav-overlay-close {
      position: absolute;
      top: 1.4rem;
      right: clamp(1.5rem, 5vw, 5rem);
      width: 28px;
      height: 28px;
      background: none;
      border: none;
      cursor: pointer;
      padding: 0;
    }

    .nav-overlay-close span {
      display: block;
      position: absolute;
      width: 100%;
      height: 1px;
      background: var(--ink);
      top: 50%;
      left: 0;
    }

    .nav-overlay-close span:first-child { transform: rotate(45deg); }
    .nav-overlay-close span:last-child  { transform: rotate(-45deg); }

    .nav-overlay-nav ol {
      list-style: none;
      padding: 0;
      margin: 0;
    }

    .nav-overlay-nav ol li {
      border-top: 1px solid var(--faint);
      opacity: 0;
      transform: translateY(12px);
      transition: opacity 0.35s ease, transform 0.35s ease;
    }

    .nav-overlay-nav ol li:last-child {
      border-bottom: 1px solid var(--faint);
    }

    .nav-overlay.open .nav-overlay-nav ol li {
      opacity: 1;
      transform: none;
    }

    /* Stagger each link's entrance */
    .nav-overlay.open .nav-overlay-nav ol li:nth-child(1) { transition-delay: 0.05s; }
    .nav-overlay.open .nav-overlay-nav ol li:nth-child(2) { transition-delay: 0.10s; }
    .nav-overlay.open .nav-overlay-nav ol li:nth-child(3) { transition-delay: 0.15s; }
    .nav-overlay.open .nav-overlay-nav ol li:nth-child(4) { transition-delay: 0.20s; }
    .nav-overlay.open .nav-overlay-nav ol li:nth-child(5) { transition-delay: 0.25s; }
    .nav-overlay.open .nav-overlay-nav ol li:nth-child(6) { transition-delay: 0.30s; }

    .nav-overlay-nav ol li a {
      display: block;
      padding: 1.2rem 1rem;
      font-family: 'Cormorant Garamond', serif;
      font-size: clamp(1.6rem, 7vw, 2.4rem);
      font-weight: 300;
      font-style: italic;
      letter-spacing: 0.02em;
      color: var(--ink);
      text-decoration: none;
      cursor: pointer;
    }

    .opening h1 {
      font-size: clamp(2rem, 11vw, 4rem);
      white-space: normal;
    }

    .opening-role {
      font-size: 0.72rem;
      letter-spacing: 0.16em;
    }

    .entry-full, .entry-full.flip {
      grid-template-columns: 1fr;
      gap: 1.5rem;
    }
    .entry-full .stamp-wrap { display: none; }
    .entry-content-row {
      grid-template-columns: 1fr !important;
    }
    .entry-content-row .entry-visual,
    .entry-full.flip .entry-content-row .entry-visual { order: 1; }
    .entry-content-row .entry-body,
    .entry-full.flip .entry-content-row .entry-body   { order: 2; }
    .entry-content .reflection                        { order: 3; }
    .entries-mid { grid-template-columns: 1fr; }

    .entry-mid {
      display: flex;
      flex-direction: column;
      padding-bottom: 2.5rem;
      border-bottom: 1px solid var(--faint);
    }
    .entry-mid:last-child {
      border-bottom: none;
      padding-bottom: 0;
    }
    .entry-mid .entry-year { order: 1; }
    .entry-mid h3          { order: 2; }
    .entry-mid .mid-visual { order: 3; margin-top: 0.8rem; margin-bottom: 0.9rem; }
    .entry-mid p,
    .entry-mid .entry-link,
    .entry-mid .non-link,
    .entry-mid .link-row   { order: 4; }
    .entry-mid .entry-link,
    .entry-mid .non-link   { align-self: flex-start; }

    .entry-link,
    .non-link {
      display: block;
      margin-left: 0 !important;
      width: fit-content;
    }

    .patent-list li {
      grid-template-columns: 1fr;
      gap: 0.25rem;
    }
    .patent-list li:first-child { border-top: none; }
    .patent-list li:last-child  { border-bottom: none; }

    .statement-paper {
      padding: 2rem;
    }

    .patents-window .patents {
      padding: 2rem;
    }

    .footer-transparent,
    footer {
      height: auto;
      padding: 3rem 2rem 2rem;
      position: static;
    }

    .footer-transparent .footer-inner,
    .footer-inner {
      position: static;
      flex-direction: column;
      align-items: flex-start;
      gap: 1.5rem;
    }

    .footer-left {
      flex-direction: column;
      align-items: flex-start;
      gap: 0.8rem;
    }

    .contact {
      flex-direction: column;
      gap: 0.2rem;
    }

    footer .built {
      text-align: left;
      width: 100%;
    }

    .early-context-list {
      padding: 1.5rem 2rem;
    }

    .early-context-list li {
      grid-template-columns: 62px 1fr;
      grid-template-rows: auto auto auto;
      gap: 0.1rem 1rem;
    }
    .early-context-stamp { grid-column: 1; grid-row: 1 / 3; align-self: center; }
    .early-context-year  { grid-column: 2; grid-row: 1; }
    .early-context-title { grid-column: 2; grid-row: 2; }
    .early-context-note  { grid-column: 1 / 3; grid-row: 3; padding-top: 0.4rem; }

    .thumbnail-note {
      display: flex;
      flex-direction: column;
    }
    .thumbnail-note { padding-bottom: 2.2rem; }
    .thumbnail-note .thumb-title-row { order: 1; }
    .thumbnail-note .thumb-image     { order: 2; margin-top: 0.8rem; margin-bottom: 0.8rem; }
    .thumbnail-note .thumb-body      { order: 3; }
    .thumbnail-note .thumb-action    { order: 4; margin-top: 0.5rem; }
    body { cursor: auto; }
    #charcoal-cursor { display: none; }
    #crosshair-cursor { display: none; }
    .cursor-toggle { display: none; }
  }

  /* ── LIGHTBOX ── */
  .gallery-lightbox { cursor: none; }
 
  .lightbox-overlay {
    position: fixed; inset: 0;
    background: rgba(26,24,20,0.88);
    z-index: 3000;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; pointer-events: none;
    transition: opacity 0.3s ease;
    cursor: none;
  }
 
  .lightbox-overlay.active {
    opacity: 1; pointer-events: all;
  }
 
  .lightbox-overlay img {
    max-width: 90vw; max-height: 90vh;
    object-fit: contain;
    box-shadow: 0 12px 60px rgba(0,0,0,0.5);
    cursor: none;
  }
 
  .lightbox-close {
    position: absolute;
    top: 2rem; right: 2.5rem;
    font-family: 'Inconsolata', monospace;
    font-size: 0.7rem; letter-spacing: 0.22em;
    text-transform: uppercase;
    color: rgba(247,245,241,0.6);
    cursor: none;
    transition: color 0.2s;
  }
 
  .lightbox-close:hover { color: rgba(247,245,241,1); }
/* ════════════════════════════════════
   GALLERY PAGE
   ════════════════════════════════════ */

/* ── PROJECT HEADER (gallery + sk pages) ── */
.project-header {
  padding: 5rem 0 1.5rem;
}

.project-eyebrow {
  font-family: 'Inconsolata', monospace;
  font-size: 0.88rem;
  letter-spacing: 0.38em;
  text-transform: uppercase;
  color: var(--ink);
  margin-bottom: 2.5rem;
  opacity: 0;
  animation: m-fade 1.2s ease-out 0.3s forwards;
}

.project-header h1 {
  font-size: clamp(2.2rem, 3.8vw, 3.8rem);
  font-weight: 500;
  font-style: italic;
  letter-spacing: 0.04em; 
  line-height: 1.1;
  margin-bottom: 1.5rem;
  opacity: 0;
  animation: m-rise 1.2s ease-out 0.3s forwards;
}

.project-meta {
  display: flex; gap: 2rem; flex-wrap: wrap;
  margin-bottom: 2rem;
  opacity: 0;
  animation: m-fade 1.2s ease-out 0.6s forwards;
}

.project-meta span {
  font-family: 'Inconsolata', monospace;
  font-size: 0.82rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--dark-mid);
}

.project-description {
  font-family: 'Lora', serif;
  font-weight: 400;
  font-size: 1.1rem;
  line-height: 1.85;
  letter-spacing: 0.01em;
  color: var(--ink);
  margin-bottom: 1.5rem;
  opacity: 0;
  animation: m-fade 1.4s ease-out 0.9s forwards;
}

/* ── GALLERY SECTIONS ── */
.gallery-section {
  padding: 3rem 0 0;
}

.gallery-label {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.9rem;
  font-weight: 500;
  line-height: 1.3;
  color: var(--ink);
  margin-bottom: 2rem;
  display: block;
  opacity: 0;
  animation: m-fade 0.8s ease-out 1.4s forwards;
}

.gallery-grid {
  columns: 2;
  column-gap: 1.5rem;
  margin-bottom: 4rem;
  opacity: 0;
  animation: m-fade 0.6s ease-out 1.2s forwards;
}

.gallery-item {
  break-inside: avoid;
  margin-bottom: 1.5rem;
  display: block;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.gallery-item.visible {
  opacity: 1; transform: none;
}

.gallery-item img {
  width: 100%;
  display: block;
}

.gallery-item .caption {
  padding: 0.6rem 0 0;
  font-family: 'Inconsolata', monospace;
  font-size: 0.74rem; 
  letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--mid);
  line-height: 1.6;
}

.gallery-grid--three {
  columns: 3;
}

@media (max-width: 720px) {
  .gallery-grid--three {
    columns: 1;
  }
}

/* ── GALLERY ROW — equal thirds ── */
.gallery-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.gallery-row .gallery-item {
  margin-bottom: 0;
}

.gallery-row img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  display: block;
}

.gallery-row--square img {
  aspect-ratio: 1/1;
}

@media (max-width: 720px) {
  .gallery-row {
    grid-template-columns: 1fr;
  }
  .gallery-row img {
    aspect-ratio: 16/9;
  }
}

/* ── GALLERY GROUP — hero + 2 supplementals ── */
.gallery-group-label {
  font-family: 'Inconsolata', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--light);
  display: block;
  margin-bottom: 0.6rem;
  margin-top: 2rem;
}

.gallery-group {
  break-inside: avoid;
  display: grid;
  grid-template-columns: 2fr 1fr;
  grid-template-rows: auto auto;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  align-items: stretch;
}

.gallery-group-hero {
  grid-column: 1;
  grid-row: 1 / 3;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.gallery-group-hero img {
  flex: 1;
  width: 100%;
  min-height: 0;
  object-fit: cover;
  display: block;
}

.gallery-group-supp {
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.gallery-group-supp img {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  display: block;
}

/* Square variant — for 1×1 source images */
.gallery-group--square .gallery-group-supp img {
  aspect-ratio: 1/1;
}

.gallery-group--square .gallery-group-hero img {
  aspect-ratio: unset;
}

/* Standalone portrait image */
.gallery-portrait {
  margin-bottom: 4rem;
  display: flex;
  justify-content: center;
}

.gallery-portrait .gallery-item {
  width: 50%;
}

.gallery-portrait img {
  width: 100%;
  display: block;
}

.gallery-group .caption {
  font-family: 'Inconsolata', monospace;
  font-size: 0.74rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--mid);
  padding: 0.4rem 0 0;
  line-height: 1.6;
}

@media (max-width: 720px) {
  .gallery-group {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }
  .gallery-group-hero {
    grid-row: 1;
    grid-column: 1;
  }
  .gallery-group-hero img {
    width: 100%;
    aspect-ratio: 4/3;
  }
}

/* ════════════════════════════════════
   SEMANTIC KERNEL PAGE
   ════════════════════════════════════ */

.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2.5rem 2rem;
  padding: 0rem 0 5rem;
  opacity: 0;
  animation: m-fade 0.6s ease-out 1.2s forwards;
}

.video-item {
  display: flex; flex-direction: column;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.video-item.visible {
  opacity: 1; transform: none;
}

.video-thumb {
  position: relative;
  width: 100%; aspect-ratio: 16/9;
  overflow: hidden; background: var(--faint);
  display: block; text-decoration: none;
  margin-bottom: 0rem;
  cursor: none;
}

.video-thumb img {
  width: 100%; height: 100%;
  object-fit: cover; display: block;
  transition: opacity 0.3s ease;
  filter: saturate(0.65) contrast(1.05);
}

.video-thumb:hover img {
  opacity: 0.8;
}

.video-thumb::after {
  content: '▶';
  position: absolute;
  inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; color: var(--ink);
  opacity: 0;
  transition: opacity 0.25s ease;
  background: rgba(247,245,241,0.5);
}

.video-thumb:hover::after {
  opacity: 1;
}

.video-num {
  font-family: 'Inconsolata', monospace;
  font-size: 0.82rem;
  letter-spacing: 0.20em;
  text-transform: uppercase;
  color: var(--ink);
  margin-bottom: 0.4rem;
}

.video-link {
  display: inline-block;
  align-self: flex-start;
  margin-top: 0.75rem;
  font-family: 'Inconsolata', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--dark-mid);
  text-decoration: none;
  background: var(--faint);
  border: 1px solid var(--smudge);
  border-radius: 0;
  padding: 0.65em 0.85em 0.55em;
  line-height: 1;
  transition: background 0.2s, color 0.2s;
  cursor: none;
}

.video-link:hover {
  background: var(--smudge);
  color: var(--ink);
}

@media (max-width: 720px) {
  .video-grid { grid-template-columns: 1fr; }
}