/* NUMA — sections 1, 2, 4 ported from the Lovable project; section 3 is the scroll-driven hills. */

:root {
  --background: #A6C6AD;
  --foreground: oklch(0.17 0.018 255);
  --primary-foreground: oklch(0.984 0.003 247.858);
  --font-sans: "Montserrat", "Avenir Next", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--background);
  color: var(--foreground);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
}
img, video { max-width: none; }
button { font: inherit; cursor: pointer; }
.br-sm { display: none; }
@media (min-width: 640px) { .br-sm { display: block; } }

/* small reset matching the shadcn buttons used in Lovable */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  white-space: nowrap; border-radius: 0.375rem; font-size: 0.875rem; font-weight: 500;
  border: 0; background: transparent; color: inherit; transition: background-color .15s, color .15s;
}
.btn:focus-visible { outline: 1px solid currentColor; outline-offset: 2px; }
.btn svg { width: 1rem; height: 1rem; flex-shrink: 0; pointer-events: none; }

@keyframes natural-wind {
  0%, 100% { transform: rotate(-0.65deg) translate3d(-1px, 0, 0); }
  24% { transform: rotate(1.25deg) translate3d(3px, 1px, 0); }
  49% { transform: rotate(-0.35deg) translate3d(0, 0, 0); }
  72% { transform: rotate(0.85deg) translate3d(2px, 1px, 0); }
}

/* ---------- shared section titles (same system as section 4) ---------- */
.eyebrow { margin: 0 0 0.9rem; font-size: 0.62rem; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; }
.section-title { margin: 0; font-size: clamp(1.35rem, 2vw, 2.1rem); font-weight: 500; letter-spacing: 0.14em; line-height: 1; text-transform: uppercase; text-wrap: balance; }
.section-lead {
  display: block; margin: 1.2rem 0 0; color: color-mix(in oklab, currentColor 66%, transparent);
  font-size: clamp(0.66rem, 0.82vw, 0.8rem); font-weight: 500; letter-spacing: 0.08em; line-height: 1.6;
}
.opening-copy .eyebrow { opacity: .85; text-shadow: 0 1px 10px rgb(0 0 0 / .5); }
@media (max-width: 640px) { .section-lead { font-size: .62rem; } }

/* ---------- 1 · opening ---------- */
.opening-scene {
  position: relative; height: 100svh; min-height: 30rem; overflow: hidden;
  background: var(--foreground); color: var(--primary-foreground); isolation: isolate;
}
.opening-video, .opening-shade { position: absolute; inset: 0; width: 100%; height: 100%; }
.opening-video { z-index: -2; object-fit: cover; object-position: center; background: var(--foreground) url("assets/lovable/numa-hero-origami-poster.webp") center / cover no-repeat; }
.opening-shade {
  z-index: -1;
  background:
    radial-gradient(ellipse 60% 45% at 50% 50%, color-mix(in oklab, var(--foreground) 30%, transparent), transparent 75%),
    linear-gradient(to bottom, color-mix(in oklab, var(--foreground) 24%, transparent), transparent 38%, color-mix(in oklab, var(--foreground) 30%, transparent));
}
.opening-header {
  position: absolute; z-index: 3; top: 0; right: 0; left: 0;
  display: flex; align-items: flex-start; justify-content: space-between;
  padding: clamp(1.25rem, 2.8vw, 2.75rem) clamp(1.25rem, 3.5vw, 4rem);
}
.numa-logo { width: clamp(58px, 6vw, 92px); height: auto; filter: drop-shadow(0 2px 12px color-mix(in oklab, var(--foreground) 24%, transparent)); }
.opening-menu-button {
  width: 42px; height: 42px; border-radius: 999px; color: var(--primary-foreground);
  background: color-mix(in oklab, var(--foreground) 14%, transparent); backdrop-filter: blur(8px);
}
.opening-menu-button:hover { background: color-mix(in oklab, var(--foreground) 28%, transparent); }
.opening-menu-button svg { width: 21px; height: 21px; }
.opening-menu { position: absolute; z-index: 2; top: clamp(5.3rem, 8vw, 7.5rem); right: clamp(1.25rem, 3.5vw, 4rem); }
.opening-menu[hidden] { display: none; }
.opening-menu button {
  height: 2.25rem; padding: 0 1rem;
  border: 1px solid color-mix(in oklab, var(--primary-foreground) 35%, transparent);
  color: var(--primary-foreground); background: color-mix(in oklab, var(--foreground) 36%, transparent); backdrop-filter: blur(12px);
}
.opening-copy {
  position: absolute; inset: 0; z-index: 2;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 6rem clamp(1.25rem, 6vw, 4rem); text-align: center; pointer-events: none;
}
.opening-copy > * { pointer-events: auto; max-width: min(42rem, 100%); }
.opening-copy h1 {
  margin: 0; font-size: clamp(1rem, 1.85vw, 1.75rem); font-weight: 500; letter-spacing: 0.18em; line-height: 1.42;
  text-transform: uppercase; text-shadow: 0 2px 18px color-mix(in oklab, var(--foreground) 70%, transparent);
}
.opening-cta {
  min-width: 9.5rem; height: 2.35rem; margin-top: 1.4rem; padding: 0 1rem;
  border: 1px solid color-mix(in oklab, var(--primary-foreground) 55%, transparent); border-radius: 999px;
  background: color-mix(in oklab, var(--foreground) 16%, transparent); color: var(--primary-foreground);
  font-size: 0.62rem; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; backdrop-filter: blur(6px);
}
.opening-cta:hover { background: color-mix(in oklab, var(--primary-foreground) 90%, transparent); color: var(--foreground); }

/* ---------- 2 · collection ---------- */
.collection-scene {
  position: relative; display: grid; grid-template-columns: minmax(430px, 44vw) 1fr;
  min-height: 100svh; overflow: hidden; background: var(--background);
}
.collection-model { position: relative; z-index: 3; align-self: end; height: 100svh; pointer-events: none; }
.collection-model :is(img, video) {
  position: absolute; left: -6.5vw; bottom: 5vh; width: min(58vw, 920px); height: 92%;
  object-fit: contain; object-position: left bottom;
  transition: opacity .42s ease, transform .42s ease;
}
.collection-model .is-entering { opacity: 0; transform: translate3d(-8px, 0, 0); animation: none; }
.collection-model .is-leaving { opacity: 0; animation: none; }
@keyframes model-change { from { opacity: 0; transform: translate3d(-8px, 0, 0); } to { opacity: 1; transform: translate3d(0, 0, 0); } }
.collection-content { position: relative; z-index: 2; display: grid; grid-template-rows: 37% 50% 13%; min-width: 0; }
.collection-copy { align-self: start; justify-self: end; padding: 12vh 6vw 0 0; text-align: right; }
.clothesline { position: relative; display: flex; align-items: flex-start; min-width: 0; }
.clothesline .rope {   /* sagging cord, drawn by main.js so the clothes can ride along its curve */
  position: absolute; top: -40px; left: -22vw; width: calc(100% + 24vw); height: 160px; overflow: visible; pointer-events: none;
  transform-origin: right center;
}
.clothesline .rope path { stroke: #839C89; stroke-width: 1.6; }
.garment-row { display: flex; align-items: start; width: max-content; will-change: transform;
  /* clothes disappear behind the middle of the model: hidden left of --clip-x (set by main.js every frame), short soft edge; the rope is not masked */
  -webkit-mask: linear-gradient(to right, transparent var(--clip-x, 0px), #000 calc(var(--clip-x, 0px) + 2.5vw));
  mask: linear-gradient(to right, transparent var(--clip-x, 0px), #000 calc(var(--clip-x, 0px) + 2.5vw)); margin-left: -12vw; padding-right: 6vw; padding-bottom: 14vh; }   /* bottom room: pieces hang lower where the rope sags, and the mask must cover them */
.garment {
  --gh: min(40vh, 470px, 23vw);   /* garment height — width and spacing follow it, so the rhythm is the same on every screen */
  position: relative; flex: 0 0 calc(var(--gh) * .72); height: var(--gh); width: auto; min-width: 0;
  padding: 0; border: 0; border-radius: 0; background: transparent; color: inherit; margin: 0;
  margin-right: calc(var(--gh) * -.19);
}
.garment-sway {
  filter: blur(calc(var(--dof, 0) * 4.5px)) saturate(calc(1 - var(--dof, 0) * .35)) opacity(calc(1 - var(--dof, 0) * .3));
  position: relative; display: block; width: 100%; height: 100%; transform-origin: 50% 2%;
  animation: natural-wind 6.2s cubic-bezier(0.45, 0, 0.55, 1) infinite; animation-delay: var(--wind-delay); will-change: transform;
}
.garment:focus-visible { outline: 1px solid var(--foreground); outline-offset: -3px; }
.garment[aria-pressed="true"]::after {
  position: absolute; right: 15%; bottom: 4%; width: 6px; height: 6px; border-radius: 999px; background: var(--foreground); content: "";
}
.garment:nth-child(odd) { z-index: 2; }
.garment:nth-child(even) { z-index: 1; }
.garment:nth-child(even) .garment-sway { animation-duration: 7.1s; }
.garment:nth-child(3n) { z-index: 3; }
.garment:nth-child(3n) .garment-sway { animation-duration: 5.7s; }
.garment img { display: block; width: 112%; height: 100%; margin-left: -6%; object-fit: contain; object-position: center top; }
.collection-pagination { display: flex; align-items: center; justify-content: flex-end; gap: .9rem; padding: 0 6vw 4.5vh 0; }
.collection-count { display: flex; align-items: center; gap: .9rem; margin: 0 1.6rem 0 0; font-size: .7rem; font-weight: 500; letter-spacing: .18em; font-variant-numeric: tabular-nums; }
.collection-count i { width: 4.5rem; height: 1px; background: color-mix(in oklab, var(--foreground) 45%, transparent); }
.round-btn { display: grid; width: 52px; height: 52px; place-items: center; border: 1px solid var(--foreground); border-radius: 999px; background: transparent; color: var(--foreground);
  cursor: pointer; transition: background .25s, color .25s; }
.round-btn:hover, .round-btn:focus-visible { background: var(--foreground); color: var(--background); }
.round-btn svg { width: 18px; height: 18px; }

/* ---------- 3 · about (scroll-driven hills) ---------- */
.numa-hills { position: relative; height: 340vh; background: #a3b5cc; color: var(--foreground); }
.numa-hills__sticky { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; }
.numa-hills__scene {
  position: absolute; left: 50%; bottom: min(0px, calc((190svh - 100vw) / 1.958));   /* extra-wide screens: sit lower rather than cover the heading */
  width: max(100%, 125svh);   /* phones: crop sides; wide screens: always edge to edge, no side fades */
  aspect-ratio: 3830 / 1956; transform: translateX(-50%); overflow: hidden;
}
.numa-hills__layer { position: absolute; display: block; transform: translate3d(0, 120%, 0); }
.numa-hills__layer img, .numa-hills__layer canvas { display: block; width: 100%; height: 100%; }
.numa-hills__fx { opacity: 0; pointer-events: none; }
.numa-hills__float { width: 100%; height: 100%; animation: numa-float 7s ease-in-out infinite alternate; }
.numa-hills__drift { width: 100%; height: 100%; animation: numa-drift 14s ease-in-out infinite alternate; }
@keyframes numa-float { from { transform: translate(-1.5%, 0); } to { transform: translate(1.5%, -4%); } }
@keyframes numa-drift { from { transform: translateX(-4%); } to { transform: translateX(4%); } }
.numa-hills__copy {
  position: absolute; z-index: 2; top: clamp(2.5rem, 7vh, 5rem); left: 50%;
  width: min(46rem, calc(100% - 2.5rem)); transform: translateX(-50%); text-align: center;
}

/* ---------- 4 · process: folded pattern sheet ---------- */
.process-scene { position: relative; background: #ccb6d3; color: var(--foreground); }
.process-sticky {
  position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden;
  display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); align-items: center;
  gap: clamp(1.5rem, 4vw, 5rem); padding: 0 clamp(1.5rem, 7vw, 7rem);
}
.process-copy { max-width: 26rem; }
.process-steps { display: grid; gap: 0; margin: clamp(1.6rem, 4vh, 2.8rem) 0 0; padding: 0; list-style: none; }
.process-steps li {
  display: grid; grid-template-columns: 2.4rem 1fr; align-items: baseline; row-gap: .2rem;
  padding: .85rem 0; border-top: 1px solid color-mix(in oklab, var(--foreground) 22%, transparent);
  opacity: .38; transition: opacity .5s ease, transform .5s cubic-bezier(.16,1,.3,1);
}
.process-steps li:last-child { border-bottom: 1px solid color-mix(in oklab, var(--foreground) 22%, transparent); }
.process-steps li.is-active { opacity: 1; transform: translateX(.6rem); }
.process-steps li.is-done { opacity: .7; }
.process-steps b { font-size: .62rem; font-weight: 700; letter-spacing: .16em; }
.process-steps strong { font-size: clamp(1rem, 1.5vw, 1.35rem); font-weight: 500; letter-spacing: .14em; text-transform: uppercase; }
.process-steps small { grid-column: 2; color: color-mix(in oklab, var(--foreground) 62%, transparent); font-size: .66rem; letter-spacing: .07em; }

/* the folded sheet: 4 strips nested inside each other so each fold hinges on the one above */
.fold-stage { position: relative; height: 100%; display: grid; place-items: center; perspective: 1700px; }
.fold { position: relative; width: var(--w); height: calc(var(--w) * 1.3); transform-style: preserve-3d; }
.fold-strip { position: absolute; left: 0; top: 0; width: 100%; height: 25%; transform-origin: 50% 0; transform-style: preserve-3d; }
.fold-strip .fold-strip { top: 100%; height: 100%; }
.fold-face { position: absolute; inset: 0; overflow: hidden; backface-visibility: hidden; background: #f6f4ef; }
.fold-face .sheet-svg { position: absolute; left: 0; width: 100%; height: 400%; display: block; }
.fold-shade { position: absolute; inset: 0; pointer-events: none; }
.fold-back { position: absolute; inset: 0; transform: rotateX(180deg); backface-visibility: hidden;
  background: repeating-linear-gradient(115deg, #9da3b4 0 7px, #a9aebd 7px 14px); }

/* stage styling driven by --sketch / --cut / --fill / --stitch / --finish (0 → 1) set from main.js */
.st-sketch path { stroke-dasharray: 1; stroke-dashoffset: calc(1 - var(--sketch, 0)); }
.st-sketch { opacity: calc(1 - var(--fill, 0)); }
.st-fabric, .st-finish { transition: none; }
.fold .st-fabric { opacity: calc(var(--fill, 0) * var(--art, 1)); }
.fold .st-finish { opacity: var(--art, 1); }
.st-cut { opacity: calc(var(--cut, 0) * (1 - var(--fill, 0) * .85)); }
.st-cut .piece { fill: none; stroke: #3b3f4d; stroke-width: 1.1; }
.st-cut .cutline { fill: none; stroke: #3b3f4d; stroke-width: .8; stroke-dasharray: 5 3.5; }
.st-cut .grain, .st-cut .notch { fill: none; stroke: #3b3f4d; stroke-width: .8; }
.pc { transition: none; }
.pc-bib { transform: translate(0, calc(var(--spread, 0) * -26px)); }
.pc-band { transform: translate(0, calc(var(--spread, 0) * -12px)); }
.pc-skirt { transform: translate(0, calc(var(--spread, 0) * 18px)); }
.pc-pocket { transform: translate(calc(var(--spread, 0) * 44px), calc(var(--spread, 0) * 6px)); }
.st-fabric { opacity: var(--fill, 0); }
.stitch-reveal { stroke-dasharray: 1; stroke-dashoffset: calc(1 - var(--stitch, 0)); }
.st-finish .rope { stroke-dasharray: 1; stroke-dashoffset: calc(1 - var(--finish, 0)); }
.st-finish .rope-twist { stroke-dasharray: .012 .018; stroke-dashoffset: 0; opacity: var(--finish, 0); }
.st-finish .knots, .st-finish .tag { opacity: clamp(0, calc(var(--finish, 0) * 3 - 1.6), 1); }
.st-finish .patch { opacity: clamp(0, calc(var(--finish, 0) * 3 - 1), 1);
  transform-box: fill-box; transform-origin: center; transform: scale(calc(.4 + .6 * clamp(0, calc(var(--finish, 0) * 3 - 1), 1))) rotate(calc((1 - clamp(0, calc(var(--finish, 0) * 3 - 1), 1)) * -40deg)); }
.st-finish .cube { opacity: clamp(0, calc(var(--finish, 0) * 3 - 2), 1); }

/* 05 · wear: the real pinafore lifts off the paper and turns in 3D */
.dress3d { position: absolute; left: 50%; top: 50%; width: var(--w); height: calc(var(--w) * 1.3);
  transform: translate(-50%, -50%); pointer-events: none; perspective: 1100px; }
.fold-stage { --w: min(36vw, 62svh, 470px); }
.dress3d__spin { position: absolute; left: 19.5%; top: 11.6%; width: 61%; aspect-ratio: 830 / 1525;
  transform-style: preserve-3d; opacity: var(--wear, 0);
  transform: translateZ(calc(var(--lift, 0) * 120px)) translateY(calc(var(--lift, 0) * -4%)) rotateY(calc(var(--turn, 0) * 1deg)) scale(calc(1 + var(--lift, 0) * .06)); }
.dress3d__spin img { display: block; width: 100%; height: auto;
  filter: drop-shadow(calc(var(--turn, 0) * -.25px) 6px 6px rgb(0 0 0 / .25)); }
.dress3d__sheen { position: absolute; inset: 0; mix-blend-mode: soft-light; pointer-events: none;
  -webkit-mask: url(assets/dress.webp) center / 100% 100% no-repeat; mask: url(assets/dress.webp) center / 100% 100% no-repeat;
  background: linear-gradient(100deg, rgb(0 0 0 / .45) 0%, transparent calc(30% + var(--turn, 0) * 1%), rgb(255 255 255 / .55) calc(50% + var(--turn, 0) * 1%), transparent calc(72% + var(--turn, 0) * 1%), rgb(0 0 0 / .35) 100%); }
.dress3d__shadow { position: absolute; left: 22%; right: 22%; bottom: 3%; height: 6%; border-radius: 50%;
  background: radial-gradient(closest-side, rgb(40 30 60 / .45), transparent); filter: blur(4px);
  opacity: calc(var(--wear, 0) * var(--lift, 0)); transform: scaleX(calc(1 - var(--lift, 0) * .25)); }
.process-defs { position: absolute; width: 0; height: 0; overflow: hidden; }

@media (max-width: 760px) {
  .process-sticky { grid-template-columns: 1fr; grid-template-rows: auto 1fr; align-items: start; padding: 4.5rem 1.25rem 1.5rem; gap: 1rem; }
  .process-copy .process-lead { display: none; }
  .process-steps { grid-template-columns: repeat(5, 1fr); margin-top: 1rem; gap: .4rem; }
  .process-steps li { grid-template-columns: 1fr; padding: .5rem 0 0; border-bottom: 0 !important; }
  .process-steps li.is-active { transform: none; }
  .process-steps small { display: none; grid-column: 1; }
  .process-steps strong { font-size: .72rem; letter-spacing: .1em; }
  .fold-stage { --w: min(80vw, 52svh); }
}

/* ---------- section transitions ---------- */
/* 1 → 2: normal scroll; section 2 builds itself up as it arrives (see .collection-scene.is-in below).
   2 → 3 and 3 → 4: the next section slides up over the previous one, which stays pinned and drifts up slowly. */
.collection-scene { position: sticky; top: 0; z-index: 2; height: 100svh; }
:root { --hold: 80vh; }   /* pause between sections: how long each finished section stays on screen before the next slides in */
.numa-hills { z-index: 3; height: calc(440vh + var(--hold)); margin-top: calc(var(--hold) + var(--rail, 0px)); }   /* --rail (set by main.js) = extra scroll while the clothesline slides sideways */   /* hold for section 2 · 340vh of hills · hold for the finished hills · one screen for section 4 to slide over */
.process-scene { z-index: 4; margin-top: -100svh; height: 660vh; }   /* + one screen at the end for section 5 to slide over */   /* first screen = slide-over, then the sheet opens and the dress is made */
.collection-scene { will-change: transform; }

/* section 2 entrance: heading rises, rope draws across, garments drop onto the line one by one, model steps in */
.collection-copy, .rope, .garment, .collection-model, .collection-pagination {
  transition: opacity .9s cubic-bezier(.16,1,.3,1), transform 1.1s cubic-bezier(.16,1,.3,1);
}
.collection-scene:not(.is-in) .collection-copy { opacity: 0; transform: translateY(28px); }
.collection-scene:not(.is-in) .rope { transform: scaleX(0); }
.rope { transition-duration: 1.3s; transition-delay: .15s; }
.collection-scene:not(.is-in) .garment { opacity: 0; transform: translateY(-60px); }
.garment:nth-child(1) { transition-delay: .35s; } .garment:nth-child(2) { transition-delay: .45s; }
.garment:nth-child(3) { transition-delay: .55s; } .garment:nth-child(4) { transition-delay: .65s; }
.garment:nth-child(5) { transition-delay: .75s; } .garment:nth-child(n+6) { transition-delay: .85s; }
.collection-scene:not(.is-in) .collection-model { opacity: 0; transform: translateX(-40px); }
.collection-model { transition-delay: .2s; transition-duration: 1.2s; }
.collection-scene:not(.is-in) .collection-pagination { opacity: 0; }
.collection-pagination { transition-delay: 1s; }

/* clothespins: one on each strap, clamped on the rope (strap x from the garment images; all images share one aspect ratio) */
.garment { transform-origin: 50% 0; }   /* main.js tilts each piece (rotate) to follow the slope of the rope */
.pin { position: absolute; z-index: 2; top: 0; left: calc(var(--gh) * (.0873 + .545 * var(--p1))); width: calc(var(--gh) * .03); aspect-ratio: 10 / 34;
  translate: -50% -46%; background: url(assets/clothespin.svg) center / contain no-repeat; rotate: -3deg; pointer-events: none; }
.pin--2 { left: calc(var(--gh) * (.0873 + .545 * var(--p2))); rotate: 4deg; }

/* ---------- responsive ---------- */
@media (min-width: 1200px) {   /* big screens: the model leads, the clothes step back a little */
  .collection-model :is(img, video) { bottom: 3vh; height: 96%; width: min(62vw, 1000px); }
  .garment { --gh: min(36vh, 430px, 23vw); }
}
@media (max-width: 900px) {
  .collection-scene { grid-template-columns: 38vw 1fr; }
  .collection-model :is(img, video) { left: -17vw; width: 72vw; }
  .collection-copy { padding-right: 5vw; padding-left: 5vw; }
  .garment-row { margin-left: -17vw; }
}
@media (max-width: 640px) {
  .opening-copy { padding: 5rem 1.25rem; }
  .opening-copy h1 { font-size: 0.9rem; line-height: 1.5; }
  .opening-header { padding: 1.2rem; }
  .opening-menu { top: 4.5rem; right: 1.2rem; }
  .collection-scene { display: block; min-height: 100svh; }
  .collection-model { position: absolute; inset: 0 auto 0 -8vw; width: 76vw; height: 100%; opacity: 0.96; }
  .collection-model :is(img, video) { left: -8vw; width: 106vw; height: 100%; }
  .collection-content { grid-template-rows: 34svh 51svh 15svh; min-height: 100svh; }
  .collection-copy { align-self: center; justify-self: stretch; padding: 3rem 1.25rem 0 34vw; text-align: right; }
  .collection-copy .section-title { font-size: 1.05rem; }
  .clothesline { align-items: flex-start; overflow: hidden; }

  .garment-row { width: max-content; margin-left: 23vw; padding-right: 6vw; }
  .garment { --gh: min(27svh, 46vw); }
  .collection-pagination { justify-content: flex-end; padding: 0 5vw 1.2rem 0; gap: .6rem; }
  .collection-count { display: none; } .round-btn { width: 42px; height: 42px; }
  .pagination-dots { gap: 0.75rem; }
  .collection-scene { height: 100svh; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .opening-video { display: none; }
  .opening-scene { background: var(--foreground) url("assets/lovable/numa-hero-origami-poster.webp") center / cover no-repeat; }
  .garment-sway, .collection-model :is(img, video), .numa-hills__float, .numa-hills__drift { animation: none; }
}

/* ---------- 2 · grid-paper price tag ---------- */
.tag-string { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; z-index: 6; }
.tag-string--back { z-index: 4; }   /* the half of the loop that goes behind the tag */
.price-tag {   /* left/top/width are set by main.js so the hole always sits at the end of the string */
  position: absolute; z-index: 5; left: 0; top: 0; width: 124px; aspect-ratio: 0.5;
  pointer-events: auto; container-type: inline-size; transform-origin: 50% 8%;   /* = centre of the hole */
  transform: perspective(700px) rotate(10deg) rotateY(-14deg); animation: tag-sway 5.5s ease-in-out infinite alternate;
}
.price-tag::before {   /* grid paper with a pinking-shear top edge */
  content: ""; position: absolute; inset: 0;
  background:   /* soft bend: light catches the left side, the right side turns away */
    linear-gradient(90deg, rgb(255 255 255 / .38) 0%, rgb(255 255 255 / 0) 34%, rgb(0 0 0 / 0) 58%, rgb(90 80 60 / .13) 100%),
    linear-gradient(180deg, rgb(90 80 60 / 0) 62%, rgb(90 80 60 / .07) 100%),
    url(assets/grid-paper.png) center / 70% auto, #ebe7dc;
  -webkit-mask: radial-gradient(circle at 50% 16cqw, transparent 6cqw, #000 6.3cqw); mask: radial-gradient(circle at 50% 16cqw, transparent 6cqw, #000 6.3cqw);
  clip-path: polygon(0.00% 2.6%, 6.25% 0%, 12.50% 2.6%, 18.75% 0%, 25.00% 2.6%, 31.25% 0%, 37.50% 2.6%, 43.75% 0%, 50.00% 2.6%, 56.25% 0%, 62.50% 2.6%, 68.75% 0%, 75.00% 2.6%, 81.25% 0%, 87.50% 2.6%, 93.75% 0%, 100% 2.6%, 100.00% 100.00%, 98.33% 99.07%, 96.67% 100.00%, 95.00% 99.06%, 93.33% 100.00%, 91.67% 99.10%, 90.00% 100.00%, 88.33% 99.20%, 86.67% 100.00%, 85.00% 98.89%, 83.33% 99.94%, 81.67% 98.84%, 80.00% 99.75%, 78.33% 98.69%, 76.67% 99.68%, 75.00% 98.94%, 73.33% 99.80%, 71.67% 98.82%, 70.00% 99.73%, 68.33% 98.52%, 66.67% 99.54%, 65.00% 98.64%, 63.33% 99.63%, 61.67% 98.70%, 60.00% 99.66%, 58.33% 98.38%, 56.67% 99.59%, 55.00% 98.63%, 53.33% 99.58%, 51.67% 98.45%, 50.00% 99.61%, 48.33% 98.46%, 46.67% 99.81%, 45.00% 98.83%, 43.33% 99.76%, 41.67% 98.67%, 40.00% 99.95%, 38.33% 98.85%, 36.67% 100.00%, 35.00% 99.04%, 33.33% 99.98%, 31.67% 98.95%, 30.00% 100.00%, 28.33% 99.03%, 26.67% 100.00%, 25.00% 99.05%, 23.33% 100.00%, 21.67% 99.00%, 20.00% 100.00%, 18.33% 99.27%, 16.67% 100.00%, 15.00% 99.26%, 13.33% 100.00%, 11.67% 99.19%, 10.00% 100.00%, 8.33% 99.11%, 6.67% 100.00%, 5.00% 99.09%, 3.33% 100.00%, 1.67% 99.07%, 0.00% 100.00%);
}
.price-tag__hole {   /* real punched hole with a metal eyelet */
  position: absolute; left: 50%; top: 6.6cqw; width: 18.8cqw; aspect-ratio: 1; transform: translateX(-50%); border-radius: 50%; z-index: 1;
  background: conic-gradient(from 200deg, #f1eee7, #9c968b, #e4e0d6, #6f6a61, #cfcac0, #8a857b, #f1eee7);
  -webkit-mask: radial-gradient(circle, transparent 0 31%, #000 33%); mask: radial-gradient(circle, transparent 0 31%, #000 33%); }
.price-tag__hole::after { content: ""; position: absolute; inset: 0; border-radius: 50%;
  background: radial-gradient(circle, transparent 0 31%, rgb(0 0 0 / .35) 33%, transparent 42%, transparent 88%, rgb(0 0 0 / .25) 100%); }
.price-tag__body { position: relative; z-index: 1; height: 100%; display: flex; flex-direction: column;
  padding: 34cqw 11cqw 19cqw; color: #2a2c30; text-align: left; font-family: "Space Mono", ui-monospace, monospace; }
.price-tag__head { display: flex; justify-content: space-between; margin: 0; padding-bottom: 5cqw; font-size: 7cqw; font-weight: 700; letter-spacing: .14em;
  border-bottom: 1px dashed currentColor; }
.price-tag__name { margin: 0; padding: 7cqw 0; font-family: Montserrat, sans-serif; font-size: 10.4cqw; font-weight: 600; letter-spacing: .05em; line-height: 1.18;
  text-transform: uppercase; overflow-wrap: break-word; border-bottom: 1px dashed currentColor; }
.price-tag__row { display: flex; justify-content: space-between; align-items: baseline; margin: 0; padding-top: 5cqw; font-size: 7cqw; }
.price-tag__row span:last-child { font-size: 13.5cqw; font-weight: 700; font-variant-numeric: tabular-nums; }
.price-tag__btn { margin-top: auto; display: block; padding: 6.2cqw 2cqw; border-radius: 999px; background: #1c1d22; color: #f3f1ec;
  font-family: Montserrat, sans-serif; font-size: 7cqw; font-weight: 600; letter-spacing: .1em; text-align: center; text-transform: uppercase; text-decoration: none;
  border: 1px solid #1c1d22; transition: background .2s, color .2s; }
.price-tag__btn:hover, .price-tag__btn:focus-visible { background: transparent; color: #1c1d22; }
.price-tag.is-flipping { animation: tag-flip .5s cubic-bezier(.3,.7,.3,1); }
@keyframes tag-sway { from { transform: perspective(700px) rotate(8deg) rotateY(-18deg); } to { transform: perspective(700px) rotate(13deg) rotateY(-9deg); } }
@keyframes tag-flip { 0% { transform: perspective(700px) rotate(10deg) rotateY(-14deg); } 50% { transform: perspective(700px) rotate(10deg) rotateY(90deg); } 100% { transform: perspective(700px) rotate(10deg) rotateY(-14deg); } }
.collection-scene:not(.is-in) .price-tag, .collection-scene:not(.is-in) .tag-string { opacity: 0; }
.price-tag, .tag-string { transition: opacity .8s ease .9s; }
@media (prefers-reduced-motion: reduce) { .price-tag { animation: none; transform: perspective(700px) rotate(10deg) rotateY(-14deg); } }

/* wide screens: keep the process list and the pattern sheet together as one centred group */
@media (min-width: 1100px) {
  .process-sticky { grid-template-columns: 26rem calc(var(--w, 470px) + 6vw); justify-content: center; gap: clamp(3rem, 5vw, 6rem); }
  .process-sticky { --w: min(36vw, 62svh, 470px); }
}

/* ---------- 5 · NUMA Collective: community events ---------- */
.collective { position: relative; z-index: 5; margin-top: -100svh; height: 240vh; background: #8fb4d9; color: var(--foreground); }
.collective__sticky { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden;
  display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); align-items: center; gap: clamp(1.5rem, 4vw, 5rem); padding: 0 clamp(1.5rem, 7vw, 7rem);
  --w: min(36vw, 62svh, 470px);
  background: radial-gradient(120% 90% at 80% 10%, #a3c3e3 0%, #8fb4d9 55%, #86abd1 100%); }
.collective__copy { position: relative; z-index: 3; }
.collective__ticket { display: inline-grid; grid-auto-flow: column; align-items: center; gap: .8rem; margin: 0 0 1.4rem; padding: .55rem .9rem .55rem .8rem; rotate: -3deg;
  font-family: "Space Mono", monospace; font-size: .62rem; letter-spacing: .14em; text-transform: uppercase; color: #2a2c30;
  background: url(assets/grid-paper.png) center / 140px auto, #ebe7dc; box-shadow: 0 6px 14px -8px rgb(30 40 70 / .45);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 6px 50%); }
.collective__ticket b { font-size: .8rem; letter-spacing: .08em; }
.collective__title { margin: 0; font-size: clamp(1.9rem, 3.6vw, 3.4rem); font-weight: 500; letter-spacing: .12em; line-height: 1.05; text-transform: uppercase; }
.collective__sub { margin: 1rem 0 0; font-size: clamp(.82rem, 1vw, .95rem); font-weight: 600; letter-spacing: .08em; }
.collective__lead { margin-top: .7rem; max-width: 24rem; }
.collective__steps { margin: 1.6rem 0 0; padding: 0; list-style: none; }
.collective__steps li { display: grid; grid-template-columns: 2.6rem 1fr; align-items: baseline; padding: .7rem 0; border-top: 1px solid color-mix(in oklab, var(--foreground) 22%, transparent);
  transition: opacity .4s, transform .4s; }
.collective__steps li:last-child { border-bottom: 1px solid color-mix(in oklab, var(--foreground) 22%, transparent); }
.collective__steps b { font-size: .62rem; font-weight: 700; letter-spacing: .16em; }
.collective__steps strong { font-size: clamp(.9rem, 1.3vw, 1.15rem); font-weight: 500; letter-spacing: .14em; text-transform: uppercase; }
.collective.has-js .collective__steps li { opacity: .38; }
.collective.has-js .collective__steps li.is-on { opacity: 1; transform: translateX(6px); }
.collective__foot { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.6rem; margin-top: 1.6rem; }
.collective__meta { display: flex; align-items: center; gap: .7rem; margin: 0; font-family: "Space Mono", monospace; font-size: .68rem; letter-spacing: .1em; text-transform: uppercase; }
.collective__meta i { width: 4px; height: 4px; border-radius: 999px; background: currentColor; }
.collective__cta { height: 48px; padding: 0 1.4rem 0 1.6rem; gap: .7rem; border-radius: 999px; background: #111214; color: #f4f1ea; font-size: .64rem; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; text-decoration: none; }
.collective__cta svg { transition: translate .2s; }
.collective__cta:hover { background: #2b2d33; } .collective__cta:hover svg { translate: 4px 0; }

/* the studio: a grid-paper bandana on a little clothesline, coffees to paint with */
.collective__art { --p: 1; position: relative; margin: 0; z-index: 2; display: grid; justify-items: center; align-content: center; gap: clamp(1rem, 2.4vh, 1.6rem); padding-top: 2vh; }
.studio-rope { position: absolute; left: -16%; right: -16%; top: 2vh; width: 132%; -webkit-mask: linear-gradient(to right, transparent, #000 14%, #000 86%, transparent); mask: linear-gradient(to right, transparent, #000 14%, #000 86%, transparent); height: clamp(50px, 9vh, 90px); overflow: visible; }
.studio-rope path { stroke: #839C89; stroke-width: 1.8; vector-effect: non-scaling-stroke; }
.bandana-wrap { --bw: min(calc(var(--w) * .88), 52svh); position: relative; width: var(--bw); margin-top: calc(clamp(50px, 9vh, 90px) * .53 - 6px);
  transform-origin: 50% 0; }
.bandana { display: block; width: 100%; height: auto; overflow: visible; cursor: none; touch-action: none; transform-origin: 50% 0;
  animation: natural-wind 6.4s cubic-bezier(.45, 0, .55, 1) infinite; filter: drop-shadow(0 18px 22px rgb(30 45 80 / .28)); }
.bandana-pin { position: absolute; z-index: 2; top: 0; width: calc(var(--bw) * .045); aspect-ratio: 10 / 34; translate: -50% -42%; background: url(assets/clothespin.svg) center / contain no-repeat; }
.bandana-pin--l { left: 14%; rotate: -4deg; } .bandana-pin--r { left: 86%; rotate: 5deg; }
.bd-tag { font: 700 9px "Space Mono", monospace; letter-spacing: .12em; fill: #2a2c30; opacity: .55; pointer-events: none; }
.bandana-hint { position: absolute; left: 50%; top: 46%; translate: -50% -50%; margin: 0; padding: .45rem .8rem; border-radius: 999px; background: rgb(255 255 255 / .82); pointer-events: none;
  font-family: "Space Mono", monospace; font-size: .62rem; letter-spacing: .08em; text-transform: uppercase; white-space: nowrap; color: #2a2c30; transition: opacity .4s; }
.bandana-wrap.is-painted .bandana-hint { opacity: 0; }
.brush-ring { --d: 34px; position: fixed; z-index: 50; left: 0; top: 0; width: var(--d); height: var(--d); margin: calc(var(--d) / -2) 0 0 calc(var(--d) / -2); border-radius: 999px; border: 1.5px solid var(--c, #2a2c30); background: color-mix(in oklab, var(--c, #2a2c30) 30%, transparent); pointer-events: none; opacity: 0; transition: opacity .2s, scale .15s; }
.brush-ring.is-on { opacity: 1; } .brush-ring.is-down { background: color-mix(in oklab, var(--c, #2a2c30) 45%, transparent); }

.tastes { display: flex; justify-content: center; flex-wrap: wrap; gap: clamp(.4rem, 1.2vw, 1rem); }
/* colour beans: small matte coffee beans, each dyed with its flavour */
.tastes { gap: clamp(1.6rem, 3.4vw, 3rem); margin-top: clamp(.6rem, 2vh, 1.4rem); }
.taste { position: relative; display: grid; justify-items: center; gap: 2px; width: auto; padding: 0 0 .3rem; border: 0; background: transparent; color: var(--foreground); }
.bean { position: relative; display: block; width: clamp(20px, 1.8vw, 26px); aspect-ratio: 1 / 1.32; margin-bottom: .55rem; border-radius: 50%;
  rotate: -14deg;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='60' height='60'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='1.4' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .55 0'/%3E%3C/filter%3E%3Crect width='60' height='60' filter='url(%23n)'/%3E%3C/svg%3E"),
    radial-gradient(ellipse 80% 70% at 38% 32%, color-mix(in oklab, var(--c) 80%, #fff) 0%, var(--c) 48%, color-mix(in oklab, var(--c) 62%, #000) 100%);
  background-blend-mode: multiply;
  box-shadow: inset -2px -3px 5px rgb(0 0 0 / .28), inset 2px 2px 3px rgb(255 255 255 / .08), 0 5px 7px -3px rgb(25 30 50 / .4);
  transition: transform .35s cubic-bezier(.3, 1.4, .5, 1), box-shadow .3s; }
/* the centre crease: a dark S-curve with a soft lighter ridge beside it */
.bean::before { content: ""; position: absolute; left: 30%; top: 10%; width: 40%; height: 80%; border-radius: 50%;
  border-right: 2px solid color-mix(in oklab, var(--c) 35%, #000); rotate: 8deg; filter: blur(.3px); }
.bean::after { content: ""; position: absolute; left: 34%; top: 14%; width: 40%; height: 72%; border-radius: 50%;
  border-right: 1.5px solid color-mix(in oklab, var(--c) 70%, #fff); opacity: .35; rotate: 8deg; }
.taste b { font-size: .52rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; opacity: .55; transition: opacity .2s; }
.taste small { font-family: "Space Mono", monospace; font-size: .52rem; opacity: .45; transition: opacity .2s; }
.taste::after { content: ""; position: absolute; left: 50%; bottom: -4px; width: 0; height: 1.5px; translate: -50% 0; background: var(--foreground); transition: width .3s; }
.taste:hover .bean { transform: translateY(-3px) rotate(12deg); }
.taste:hover b, .taste:hover small { opacity: .85; }
.taste[aria-checked="true"] .bean { transform: translateY(-5px) scale(1.12); box-shadow: inset -2px -3px 5px rgb(0 0 0 / .28), 0 12px 12px -6px rgb(25 30 50 / .45); }
.taste[aria-checked="true"] b, .taste[aria-checked="true"] small { opacity: 1; }
.taste[aria-checked="true"]::after { width: 70%; }
.taste:focus-visible { outline: 1.5px solid var(--foreground); outline-offset: 4px; border-radius: 6px; }
.studio-tools { display: flex; gap: 1.4rem; }
.studio-tools button { padding: 0; border: 0; background: none; color: var(--foreground); font-family: "Space Mono", monospace; font-size: .64rem; letter-spacing: .1em; text-transform: uppercase; text-decoration: underline; text-underline-offset: 4px; }
.studio-tools button:hover { text-decoration-thickness: 2px; }

/* things escaping the frame: grid-paper petals and coffee beans, each drifting at its own speed */
.collective__float { --s: 0; position: absolute; inset: -6% -4%; pointer-events: none; z-index: -1; }
.collective__float > i { margin: calc(var(--dy, 0) * 1px) 0 0 calc(var(--dx, 0) * 1px); transition: margin .6s cubic-bezier(.2, .8, .3, 1); }
.c-bean { position: absolute; display: block; animation: c-bob 6s ease-in-out infinite; }
.c-bean { width: clamp(14px, 1.6vw, 24px); aspect-ratio: 1 / 1.35; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #a0643a, #5a2f17 60%, #3a1d0e);
  box-shadow: inset -2px -2px 3px rgb(0 0 0 / .3), 0 6px 8px -3px rgb(30 20 10 / .35); }
.c-bean::after { content: ""; position: absolute; left: 48%; top: 12%; bottom: 12%; width: 2px; border-radius: 2px; background: #2a1408; rotate: 8deg; }
.c-bean--1 { right: 18%; top: -2%; rotate: 30deg; transform: translateY(calc(var(--s) * 260px)); }
.c-bean--2 { right: -1%; top: 46%; rotate: -20deg; transform: translateY(calc(var(--s) * 160px)); animation-delay: -1.5s; }
.c-bean--3 { left: 22%; top: -6%; rotate: 60deg; transform: translateY(calc(var(--s) * 340px)); animation-delay: -3s; }
.c-bean--4 { left: 96%; bottom: 26%; rotate: -50deg; transform: translateY(calc(var(--s) * -140px)); animation-delay: -4.5s; }
.c-bean--5 { left: 4%; top: 30%; rotate: 15deg; transform: translateY(calc(var(--s) * 200px)); animation-delay: -2.2s; }
.c-bean--6 { right: -2%; bottom: 40%; rotate: 75deg; transform: translateY(calc(var(--s) * -260px)); animation-delay: -3.6s; }
@keyframes c-bob { 0%, 100% { translate: 0 0; } 50% { translate: 0 -10px; } }

@media (max-width: 760px) {
  .collective { height: auto; }
  .collective__sticky { position: relative; height: auto; min-height: 100svh; grid-template-columns: 1fr; align-content: start; gap: 2rem; padding: 4.5rem 1.25rem 3rem; }
  .collective__title { font-size: 1.9rem; }
  .bandana-wrap { --bw: min(76vw, 360px); }
  .studio-rope { left: -6%; width: 112%; }
  .collective__float { inset: -4% -2%; }
}
@media (prefers-reduced-motion: reduce) { .c-bean { animation: none; } }

.bandana:focus { outline: none; }
.bandana:focus-visible { outline: 1.5px dashed var(--foreground); outline-offset: 6px; }
@media (max-width: 760px) { .c-bean--4, .c-bean--6 { display: none; } }
@media (max-width: 760px) { .tastes { gap: 1.2rem; flex-wrap: nowrap; } .taste b { font-size: .48rem; letter-spacing: .1em; } .taste small { font-size: .48rem; } }

/* 4 → 5: the white dot patch lifts off the pinafore and flies up to become the bandana */
.patch-hole { position: absolute; left: 36.27%; top: 23.54%; width: 19.04%; height: 10.75%; pointer-events: none;
  background: url(assets/patch-under.webp) center / 100% 100%; opacity: var(--lifted, 0); transition: opacity .25s;
  box-shadow: inset 0 0 0 1px rgb(255 255 255 / .25); }
.patch-hole::after { content: ""; position: absolute; inset: 3px; border: 1px dashed rgb(255 255 255 / .55); }
.patch-flyer { position: fixed; z-index: 20; left: 0; top: 0; width: 0; height: 0; pointer-events: none; opacity: 0; will-change: left, top, width, height, transform;
  transform-origin: 50% 0; box-shadow: 0 calc(var(--h, 0) * 30px) calc(var(--h, 0) * 40px) calc(var(--h, 0) * -10px) rgb(25 35 65 / .45); }
.patch-flyer i { position: absolute; inset: 0; }
.pf-dots { background: url(assets/patch-dots.webp) center / 100% 100%; opacity: calc(1 - var(--m, 0)); }
.pf-grid { opacity: var(--m, 0);
  background: linear-gradient(#a9acc6 1px, transparent 1px) 0 0 / 4% 4%, linear-gradient(90deg, #a9acc6 1px, transparent 1px) 0 0 / 4% 4%, #f6f3ec; }

/* section 5 shares section 4's layout on wide screens: same column widths, gap and centring */
@media (min-width: 1100px) {
  .collective__sticky { grid-template-columns: 26rem calc(var(--w) + 6vw); justify-content: center; gap: clamp(3rem, 5vw, 6rem); }
}

/* ---------- utilities ---------- */
.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; }

/* ---------- 6 · Letters: the paper bird drags a sage band across ---------- */
.news { position: relative; z-index: 6; background: #0b1118; color: var(--foreground); overflow-x: clip; }
.news__band { --x: 1; --lag: 0px; position: relative; background: #a6c6ad; padding: clamp(3.5rem, 9vh, 5.5rem) clamp(1.5rem, 7vw, 7rem);
  clip-path: polygon(0 0, calc(var(--x) * 100%) 0, calc(var(--x) * 100% - var(--lag)) 100%, 0 100%); }
.news.is-pending .news__band { --x: 0; }
.news__band.is-full { clip-path: none; box-shadow: 0 -1px 0 #a6c6ad; }
.news__inner { position: relative; z-index: 2; max-width: 1080px; margin: 0 auto;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: end; gap: clamp(1.5rem, 5vw, 5rem);
  transition: opacity .7s ease, translate .9s cubic-bezier(.2,.7,.2,1); }
.news.is-pending .news__inner { opacity: 0; translate: -40px 0; }
.news__eyebrow { margin: 0 0 .9rem; }
.news__title { margin: 0; font-size: clamp(1.6rem, 2.8vw, 2.5rem); font-weight: 500; letter-spacing: .12em; line-height: 1.1; text-transform: uppercase; }
.news__sub { margin: .8rem 0 0; max-width: 24rem; font-size: .88rem; line-height: 1.65; color: #263038; }
.news__form { margin: 0; }
.news__field { display: flex; align-items: center; gap: .4rem; padding: .35rem .35rem .35rem 1.3rem; border: 1px solid var(--foreground); border-radius: 999px;
  background: transparent; transition: box-shadow .25s; }
.news__field:focus-within { box-shadow: 0 0 0 1px var(--foreground); }
.news__field input { flex: 1; min-width: 0; border: 0; outline: 0; background: none; padding: .7rem 0; color: var(--foreground);
  font: 500 .9rem var(--font-sans); letter-spacing: .02em; }
.news__field input::placeholder { color: rgb(11 17 24 / .5); }
.news__btn { flex: none; padding: .95rem 1.5rem; border: 0; border-radius: 999px; background: var(--foreground); color: #f1efe9; cursor: pointer;
  font: 600 .64rem/1 var(--font-sans); letter-spacing: .16em; text-transform: uppercase; transition: background .2s, transform .2s; }
.news__btn:hover, .news__btn:focus-visible { background: #1f2c3a; outline: none; }
.news__btn:active { transform: scale(.97); }
.news__msg { min-height: 1.3em; margin: .8rem 0 0 1.3rem; font-family: "Space Mono", monospace; font-size: .64rem; letter-spacing: .06em; color: #263038; }
.news.is-error .news__field { animation: news-nudge .4s ease-in-out; border-color: #8a2d22; }
@keyframes news-nudge { 25% { translate: -6px 0; } 50% { translate: 5px 0; } 75% { translate: -3px 0; } }
.news.is-sent .news__field { opacity: .55; pointer-events: none; }

/* the bird is positioned by script: while dragging, its beak holds the band's top corner; afterwards it rests at the perch */
.news__bird { --bw: clamp(130px, 15vw, 230px); position: absolute; z-index: 3; left: 0; top: 0; width: var(--bw); pointer-events: none;
  filter: drop-shadow(0 22px 18px rgb(20 40 30 / .28)); will-change: transform; }
.news__bird img { display: block; width: 100%; height: auto; }
.news__bird .bird-rest { position: absolute; inset: 0; opacity: 0; }
.news__bird.is-rest .bird-fly { opacity: 0; }
.news__bird.is-rest .bird-rest { opacity: 1; }
.news__bird { transform-origin: 0 0; }
.news__bird.is-flip img { transform: scaleX(-1); }
.news__bird.is-flap img { animation: bird-hop 1.2s ease-in-out infinite; }
@keyframes bird-hop { 0%, 100% { translate: 0 0; } 40% { translate: 0 -12%; } 70% { translate: 0 -5%; } }
@media (prefers-reduced-motion: reduce) { .news__bird.is-flap img { animation: none; } }
.news__note { position: absolute; left: 82%; top: 33%; width: 22%; aspect-ratio: 1.45; opacity: 0; rotate: 18deg;
  background: linear-gradient(135deg, transparent 49%, rgb(0 0 0 / .14) 50%, transparent 51%), linear-gradient(45deg, transparent 49%, rgb(0 0 0 / .14) 50%, transparent 51%),
    url(assets/grid-paper.png) center / 90px auto, #f4f1ea;
  box-shadow: 0 3px 6px rgb(0 0 0 / .2); border-radius: 1px; }
.news__bird.has-note .news__note { opacity: 1; }
.news__flying-note { position: fixed; z-index: 60; left: 0; top: 0; width: 44px; aspect-ratio: 1.45; pointer-events: none; border-radius: 1px;
  background: linear-gradient(135deg, transparent 49%, rgb(0 0 0 / .14) 50%, transparent 51%), linear-gradient(45deg, transparent 49%, rgb(0 0 0 / .14) 50%, transparent 51%),
    url(assets/grid-paper.png) center / 90px auto, #f4f1ea; box-shadow: 0 6px 12px rgb(0 0 0 / .25); }

@media (max-width: 760px) {
  .news__band { padding: 5.5rem 1.25rem 3rem; }
  .news__inner { grid-template-columns: 1fr; gap: 1.6rem; }
  .news__title { font-size: 1.6rem; }
  .news__bird { --bw: 120px; }
  .news__btn { padding: .9rem 1.1rem; }
}

/* ---------- footer: the NUMA logo builds itself ---------- */
.site-foot { position: relative; z-index: 7; background: #0b1118; color: #f1efe9; padding: clamp(4rem, 10vh, 6.5rem) clamp(1.5rem, 7vw, 7rem) 1.6rem; }
.foot__main { max-width: 1080px; margin: 0 auto; display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(2.5rem, 6vw, 6rem); align-items: start; }
.foot__logo { --s: .2; position: relative; width: min(100%, 170px); aspect-ratio: 1920 / 1420; }
.fl-stage { position: absolute; left: 0; top: 0; width: 1920px; height: 1420px; transform-origin: 0 0; transform: scale(var(--s)); transform-style: preserve-3d; }
/* each cube is a real 3D box; --M is the exact projection of the logo, so at rest it lands on the logo's shapes */
.fl-cube { --drop: 0px; --spin: 0deg; --turn: 0; position: absolute; width: 100px; height: 100px; transform-style: preserve-3d; cursor: pointer;
  transform: translateY(var(--drop)) var(--M) rotateX(var(--spin)) rotateY(calc(var(--turn) * 180deg));
  transition: transform .9s cubic-bezier(.3,1.35,.45,1); }
.fl-face { position: absolute; inset: -1px; backface-visibility: hidden; outline: 1px solid transparent; }
.fl-face--blue { background: #0270ba; transform: rotateY(180deg) translateZ(50px); }
.fl-face--print { transform: translateZ(50px); display: grid; place-items: center; }
.fl-face--cyan { background: #6dd8e6; }
.fl-face--cyan.l { transform: rotateY(-90deg) translateZ(50px); } .fl-face--cyan.r { transform: rotateY(90deg) translateZ(50px); }
.fl-face--mint { background: #acf5e0; }
.fl-face--mint.b { transform: rotateX(-90deg) translateZ(50px); } .fl-face--mint.t { transform: rotateX(90deg) translateZ(50px); }
.fl-face--print span { position: absolute; left: 50%; top: 50%; width: 150px; height: 150px; margin: -75px; display: grid; place-items: center;
  background: #f4f0e6; color: #0b1118; font: 500 104px/1 var(--font-sans); box-shadow: 0 4px 10px rgb(0 0 0 / .25); }
.fl-cube[data-print="gingham"] .fl-face--print { background: linear-gradient(90deg, rgb(2 112 186 / .55) 50%, transparent 0) 0 0 / 20px 100%, linear-gradient(0deg, rgb(2 112 186 / .55) 50%, transparent 0) 0 0 / 100% 20px, #f4f0e6; }
.fl-cube[data-print="dots"] .fl-face--print { background: radial-gradient(circle, #f4f0e6 22%, transparent 24%) 0 0 / 18px 18px, #e2735c; }
.fl-cube[data-print="stripes"] .fl-face--print { background: repeating-linear-gradient(90deg, #0b1118 0 7px, #f4f0e6 0 14px); }
.fl-cube[data-print="grid"] .fl-face--print { background: url(assets/grid-paper.png) center / 140px auto, #ebe7dc; }
/* letters and ribbon: the exact shapes from the logo file, laid over the cubes */
.fl-over { position: absolute; inset: 0; width: 1920px; height: 1420px; overflow: visible; pointer-events: none; transform: translateZ(400px); }
.fl-letter { transition: opacity .25s ease; }
.fl-letter.is-off { opacity: 0; transition: opacity .15s ease; }
.foot__tag { margin: 1.6rem 0 0; max-width: 22rem; font-size: .8rem; line-height: 1.7; color: rgb(241 239 233 / .7); }
.foot__nav { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.5rem; padding-top: .5rem; }
.foot__nav h3 { margin: 0 0 1rem; font-family: "Space Mono", monospace; font-size: .6rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: #a6c6ad; }
.foot__nav a { display: block; width: fit-content; padding: .32rem 0; color: rgb(241 239 233 / .82); text-decoration: none; font-size: .8rem; font-weight: 500;
  background: linear-gradient(currentColor, currentColor) bottom left / 0% 1px no-repeat; transition: background-size .35s ease, color .2s; }
.foot__nav a:hover, .foot__nav a:focus-visible { color: #fff; background-size: 100% 1px; outline: none; }
.foot__bar { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; max-width: 1080px; margin: clamp(3.5rem, 9vh, 5.5rem) auto 0; padding-top: 1.2rem;
  border-top: 1px solid rgb(241 239 233 / .14); font-family: "Space Mono", monospace; font-size: .58rem; letter-spacing: .12em; text-transform: uppercase; color: rgb(241 239 233 / .6); }
.foot__bar p { margin: 0; }
.foot__clock { display: inline-flex; align-items: center; gap: .5rem; }
.foot__clock time { color: #f1efe9; }
.foot__clock i { width: 6px; height: 6px; border-radius: 50%; background: #6b6e75; }
.foot__clock.is-open i { background: #acf5e0; animation: open-pulse 2.4s infinite; }
@keyframes open-pulse { 0% { box-shadow: 0 0 0 0 rgb(172 245 224 / .6); } 70%, 100% { box-shadow: 0 0 0 7px rgb(172 245 224 / 0); } }
.foot__up { color: #f1efe9; text-decoration: none; }
.foot__up span { display: inline-block; transition: translate .3s; }
.foot__up:hover span { translate: 0 -3px; }
@media (max-width: 900px) {
  .foot__main { grid-template-columns: 1fr; }
  .foot__logo { width: min(42vw, 150px); }
  .foot__nav { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 2rem; }
  .foot__bar { flex-direction: column; align-items: flex-start; }
}
@media (prefers-reduced-motion: reduce) { .news__inner { transition: none; } .fl-cube, .fl-letter, .fl-ribbon-mask { transition: none !important; } }
