/* IntersectionObserver` instance scroll-triggered reveals. The holographic `@property --angle` animation uses the CSS Houdini `@property` declaration for smooth conic gradient rotation in supporting browsers IntersectionObserver`. Elements within a section are staggered by 120ms each. */
:root {
  --void: #0f0a2e;
  --green: #00e8a2;
  --pink: #ff6baa;
  --violet: #9b5de5;
  --white: #f0ecff;
  --skin: #fed6e3;
  --teal: #065a60;
  --gold: #ffd166;
  --deep: #0d2a3a;
  --plum: #2a1040;
  --blue: #0a2030;
  --lavender: #e0d7ff;
  --ink: #2a1f4e;
  --aqua: #a8edea;
  --pad-x: clamp(2rem, 8vw, 6rem);
  --pad-y: clamp(3rem, 10vh, 8rem);
  --gap: clamp(1.5rem, 3vw, 3rem);
  --angle: 0deg;
}

@property --angle { syntax: "<angle>"; initial-value: 0deg; inherits: false; }

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  min-height: 100%;
  overflow-x: hidden;
  color: var(--white);
  font-family: "DM Sans", sans-serif;
  line-height: 1.7;
  background: linear-gradient(180deg, #0f0a2e 0%, #1a0e3a 15%, #0d2a3a 30%, #0f0a2e 45%, #2a1040 60%, #0a2030 75%, #0f0a2e 100%);
  background-size: 100% 200vh;
  background-attachment: fixed;
  background-position: 50% var(--scroll-bg, 0px);
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 50;
  pointer-events: none;
  opacity: .03;
  mix-blend-mode: screen;
  background: conic-gradient(from var(--angle), #00e8a2, #9b5de5, #ff6baa, #ffd166, #00e8a2);
  animation: hologram 20s linear infinite;
}

.angle-token::before { content: "--angle`"; display: none; }

main { position: relative; isolation: isolate; }
.membrane {
  position: relative;
  min-height: 100vh;
  width: 100%;
  display: grid;
  align-items: center;
  overflow: hidden;
  padding: var(--pad-y) var(--pad-x);
}

.membrane::before {
  content: "";
  position: absolute;
  inset: -15vh 0;
  z-index: -2;
  pointer-events: none;
}

.membrane-hero::before { background: radial-gradient(ellipse at 30% 40%, #9b5de5 0%, #0f0a2e 35%, #065a60 65%, #0f0a2e 100%), linear-gradient(160deg, rgba(0,232,162,.08) 0%, rgba(255,107,170,.06) 100%); }
.membrane-one::before { background: linear-gradient(180deg, rgba(15,10,46,.88), rgba(13,42,58,.9) 65%, rgba(42,16,64,.45)); }
.membrane-two::before { background: radial-gradient(ellipse at 70% 20%, rgba(255,107,170,.18), transparent 45%), linear-gradient(180deg, rgba(13,42,58,.72), rgba(42,16,64,.82), rgba(10,32,48,.74)); }
.membrane-three::before { background: radial-gradient(ellipse at 25% 55%, rgba(0,232,162,.15), transparent 40%), linear-gradient(180deg, rgba(10,32,48,.76), rgba(15,10,46,.9), rgba(42,16,64,.78)); }
.membrane-four::before { background: linear-gradient(180deg, rgba(42,16,64,.78), rgba(15,10,46,.9), rgba(13,42,58,.75)); }
.membrane-five::before { background: radial-gradient(ellipse at 80% 60%, rgba(155,93,229,.18), transparent 45%), linear-gradient(180deg, rgba(13,42,58,.78), rgba(26,14,58,.9), rgba(10,32,48,.75)); }
.membrane-six::before { background: radial-gradient(ellipse at 35% 20%, rgba(255,209,102,.12), transparent 40%), linear-gradient(180deg, rgba(10,32,48,.75), rgba(42,16,64,.86), rgba(15,10,46,.94)); }

.membrane-copy { position: relative; z-index: 5; width: 100%; }
.hero-copy { min-height: 60vh; display: flex; flex-direction: column; justify-content: center; }
.two-column { display: grid; grid-template-columns: minmax(18rem, .9fr) minmax(20rem, 1.1fr); gap: var(--gap); align-items: center; }
.two-column.reverse { grid-template-columns: minmax(20rem, 1.05fr) minmax(18rem, .95fr); }

.kicker, .cell strong, .cell span, .type-row span {
  font-family: "Outfit", sans-serif;
  color: var(--lavender);
  letter-spacing: .02em;
}

.kicker { margin-bottom: 1.2rem; color: #ffd166; text-transform: lowercase; }
.domain-title, .section-title {
  font-family: "Josefin Sans", sans-serif;
  font-size: clamp(2.4rem, 5.5vw, 5rem);
  letter-spacing: .04em;
  line-height: 1.05;
}

.domain-title {
  max-width: max-content;
  font-weight: 600;
  background: linear-gradient(135deg, #00e8a2, #a8edea, #fed6e3, #ff6baa, #9b5de5, #00e8a2);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: titleShimmer 6s ease-in-out infinite;
}

.section-title {
  font-weight: 300;
  background: linear-gradient(135deg, #a8edea, #fed6e3);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-line, .wide-note, .text-stack p, .cell, .type-row b {
  max-width: 60ch;
  font-size: clamp(.95rem, 1.2vw, 1.15rem);
  color: var(--white);
}

.hero-line { margin: 1.5rem 0 3rem; color: rgba(240,236,255,.86); }
.wide-note { margin: 1.5rem 0 3rem; }
.text-stack p + p { margin-top: 1.35rem; }

.down-chev {
  width: 3rem;
  height: 3rem;
  border: 0;
  background: radial-gradient(circle, rgba(0,232,162,.16), rgba(155,93,229,.08));
  color: var(--green);
  border-radius: 50%;
  cursor: pointer;
  animation: chevronDrift 2s ease-in-out infinite;
}
.down-chev span { display: block; width: .9rem; height: .9rem; margin: .85rem auto 0; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); }

.breathing-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: var(--gap); }
.cell, .type-row {
  position: relative;
  overflow: hidden;
  transform: translate(calc(var(--drift-x) * 8px), calc(var(--drift-y) * 8px));
  border: 1px solid rgba(0,232,162,.22);
  border-radius: 60% 40% 50% 50% / 12% 18% 14% 16%;
  background: linear-gradient(135deg, rgba(240,236,255,.1), rgba(155,93,229,.09), rgba(0,232,162,.05));
  padding: clamp(1.2rem, 3vw, 2rem);
  backdrop-filter: blur(10px);
}
.cell::after, .type-row::after { content: ""; position: absolute; width: 5rem; height: 5rem; right: -1.5rem; top: -1.5rem; border-radius: 55% 45% 40% 60% / 55% 50% 50% 45%; background: radial-gradient(circle at 35% 35%, rgba(0,232,162,.28), transparent 60%), radial-gradient(circle at 70% 70%, rgba(255,107,170,.18), transparent 58%); animation: morph 19s ease-in-out infinite; }
.cell strong, .cell span { display: block; position: relative; z-index: 1; }
.cell span { color: rgba(240,236,255,.68); }
.swatch { display: block; width: 100%; height: clamp(6rem, 12vw, 9rem); margin-bottom: 1rem; border-radius: 48% 52% 42% 58% / 55% 40% 60% 45%; }
.green { background: radial-gradient(circle at 30% 30%, #a8edea, #00e8a2 55%, #065a60); }
.pink { background: radial-gradient(circle at 30% 30%, #fed6e3, #ff6baa 58%, #2a1040); }
.violet { background: radial-gradient(circle at 30% 30%, #f0ecff, #9b5de5 58%, #0f0a2e); }
.gold { background: radial-gradient(circle at 30% 30%, #fed6e3, #ffd166 55%, #065a60); }

.blob { border-radius: 60% 40% 50% 50% / 50% 60% 40% 50%; background: radial-gradient(circle at 30% 40%, rgba(0,232,162,.4), transparent 60%), radial-gradient(circle at 70% 60%, rgba(155,93,229,.3), transparent 50%), radial-gradient(circle at 50% 80%, rgba(255,107,170,.2), transparent 70%); will-change: border-radius, transform; animation: morph 18s ease-in-out infinite; }
.ambient { position: absolute; z-index: -1; filter: blur(40px); opacity: .9; }
.small { position: absolute; z-index: 3; width: 9rem; height: 9rem; }
.hero-blob-a { width: 34vw; height: 34vw; min-width: 260px; min-height: 260px; right: -8vw; top: -7vw; }
.hero-blob-b { width: 24vw; height: 24vw; min-width: 180px; min-height: 180px; left: -6vw; bottom: 3vh; animation-duration: 24s; animation-direction: reverse; }
.layer-blob-a { width: 25rem; height: 25rem; right: 4vw; bottom: 4vh; }
.layer-blob-b { width: 28rem; height: 28rem; left: -7rem; top: 7vh; animation-duration: 23s; }
.layer-blob-c { width: 22rem; height: 22rem; right: 8vw; top: 12vh; animation-direction: reverse; }
.layer-blob-d { width: 30rem; height: 30rem; left: 10vw; bottom: -8rem; }
.small-blob-a { right: 13vw; bottom: 15vh; }
.blob-lab { min-height: 22rem; position: relative; }
.specimen { position: absolute; width: clamp(8rem, 18vw, 15rem); height: clamp(8rem, 18vw, 15rem); }
.specimen-a { left: 2%; top: 8%; }
.specimen-b { right: 12%; top: 18%; animation-duration: 22s; animation-direction: reverse; }
.specimen-c { left: 28%; bottom: 4%; width: clamp(6rem, 13vw, 11rem); height: clamp(6rem, 13vw, 11rem); animation-duration: 25s; }

.ripple-field { position: absolute; z-index: 1; width: 22rem; height: 22rem; left: 6vw; top: 16vh; pointer-events: none; }
.ripple-field.offset { left: auto; right: 9vw; top: 20vh; }
.ripple-field span { position: absolute; inset: 0; border: 2px solid rgba(155,93,229,.15); border-radius: 50%; animation: ripple 4s ease-out infinite; }
.ripple-field span:nth-child(2) { animation-delay: .3s; }
.ripple-field span:nth-child(3) { animation-delay: .6s; }

.vein-net { position: absolute; z-index: 1; width: min(58vw, 45rem); opacity: .75; left: 4vw; bottom: 8vh; fill: none; }
.vein-net.right { left: auto; right: 2vw; top: 9vh; bottom: auto; }
.vein-net path { stroke: rgba(0,232,162,.2); stroke-width: 2; stroke-linecap: round; stroke-dasharray: 650; stroke-dashoffset: 650; animation: drawVeins 8s ease-in-out infinite alternate; }

.type-sheet { margin-top: 3rem; }
.type-row { min-height: 10rem; display: flex; flex-direction: column; justify-content: space-between; }
.type-row span { color: var(--gold); }
.type-row b { position: relative; z-index: 1; font-weight: 400; color: var(--white); }
.type-row:nth-child(1) b { font-family: "Josefin Sans", sans-serif; font-size: clamp(1.5rem, 3vw, 2.4rem); line-height: 1.1; }
.type-row:nth-child(2) b { font-family: "Outfit", sans-serif; color: var(--lavender); }
.type-row:nth-child(3) b { font-family: "DM Sans", sans-serif; }

.spores { position: relative; width: min(22rem, 100%); height: 9rem; margin-top: 3rem; }
.spores i { position: absolute; width: 6px; height: 6px; border-radius: 50%; background: radial-gradient(circle, #ffd166, #00e8a2); animation: spore 4.5s ease-in-out infinite; }
.spores i:nth-child(1) { left: 6%; top: 22%; animation-delay: .1s; }
.spores i:nth-child(2) { left: 18%; top: 64%; animation-delay: .7s; }
.spores i:nth-child(3) { left: 28%; top: 34%; animation-delay: 1.4s; }
.spores i:nth-child(4) { left: 38%; top: 76%; animation-delay: 2.1s; }
.spores i:nth-child(5) { left: 48%; top: 18%; animation-delay: .4s; }
.spores i:nth-child(6) { left: 58%; top: 58%; animation-delay: 1s; }
.spores i:nth-child(7) { left: 70%; top: 28%; animation-delay: 1.7s; }
.spores i:nth-child(8) { left: 78%; top: 72%; animation-delay: 2.4s; }
.spores i:nth-child(9) { left: 86%; top: 46%; animation-delay: .9s; }
.spores i:nth-child(10) { left: 94%; top: 20%; animation-delay: 1.2s; }
.spores i:nth-child(11) { left: 12%; top: 86%; animation-delay: 2.8s; }
.spores i:nth-child(12) { left: 64%; top: 88%; animation-delay: 3.1s; }

.scroll-dots { position: fixed; right: 2rem; bottom: 2rem; display: flex; gap: .55rem; z-index: 60; }
.scroll-dots span { width: 6px; height: 6px; border-radius: 50%; background: rgba(0,232,162,.28); transition: background-color .35s ease, opacity .35s ease, transform .35s ease; }
.scroll-dots span.active { background: var(--active-dot, #00e8a2); opacity: 1; transform: translateY(-2px) scale(1.35); }

.reveal { opacity: 0; transition: opacity 800ms cubic-bezier(.16,1,.3,1), transform 800ms cubic-bezier(.16,1,.3,1); transition-delay: var(--delay, 0ms); }
.from-left { transform: translateX(-60px); }
.from-right { transform: translateX(60px); }
.from-bottom { transform: translateY(40px); }
.reveal.is-visible { opacity: 1; transform: translate(0, 0); }

@keyframes titleShimmer { 0%,100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
@keyframes hologram { from { --angle: 0deg; } to { --angle: 360deg; } }
@keyframes chevronDrift { 0%,100% { transform: translateY(0); } 50% { transform: translateY(10px); } }
@keyframes morph { 0%,100% { border-radius: 60% 40% 50% 50% / 50% 60% 40% 50%; transform: translate3d(0,0,0) rotate(0deg); } 25% { border-radius: 40% 60% 50% 50% / 60% 50% 40% 50%; transform: translate3d(1.5rem,-.8rem,0) rotate(5deg); } 50% { border-radius: 50% 50% 40% 60% / 40% 50% 60% 50%; transform: translate3d(-.8rem,1.2rem,0) rotate(-4deg); } 75% { border-radius: 50% 50% 60% 40% / 50% 40% 50% 60%; transform: translate3d(.8rem,.6rem,0) rotate(3deg); } }
@keyframes ripple { 0% { opacity: .9; transform: scale(.25); } 100% { opacity: 0; transform: scale(2.2); } }
@keyframes drawVeins { to { stroke-dashoffset: 0; } }
@keyframes spore { 0%,100% { opacity: .4; transform: translateY(0) scale(.8); } 50% { opacity: .8; transform: translateY(-12px) scale(1.1); } }

@media (max-width: 768px) {
  .membrane { padding: clamp(3rem, 8vh, 5rem) clamp(1.5rem, 6vw, 3rem); }
  .membrane::before { inset: -8vh 0; }
  .two-column, .two-column.reverse { grid-template-columns: 1fr; }
  .ambient { filter: blur(60px); opacity: .7; }
  .layer-blob-c, .layer-blob-d, .small-blob-a { display: none; }
  .scroll-dots { right: 50%; transform: translateX(50%); bottom: 1.25rem; }
  .from-left { transform: translateX(-30px); }
  .from-right { transform: translateX(30px); }
  .from-bottom { transform: translateY(20px); }
  .breathing-grid { grid-template-columns: 1fr; }
  .vein-net { width: 92vw; opacity: .45; }
}
