/* ============================================================
   ALGAL ACTION
   ============================================================ */

:root {
  --paper:        #f4efe1;
  --paper-2:      #efe8d6;
  --paper-shadow: #d9cfb4;
  --ink:          #2b3a2f;   /* dark pencil green-black */
  --ink-soft:     #4d5b4a;
  --pencil:       #6b7563;
  --line-blue:    #b9c8cf;   /* graph paper lines */
  --algae:        #4f7f3f;
  --algae-deep:   #2f5a2a;
  --algae-bright: #7bb661;
  --algae-glow:   #a7d98a;
  --water:        #6fa8b0;
  --water-deep:   #3d6b73;
  --highlight:    #d8f36a;   /* highlighter yellow-green */
  --tape:         rgba(210, 224, 150, 0.5);
  --red-pen:      #b8503f;
  --stamp-col:    #4f7f3f;
  --shadow:       rgba(43, 58, 47, 0.22);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'Kalam', 'Comic Sans MS', cursive;
  color: var(--ink);
  background: var(--paper);
  overflow-x: hidden;
  cursor: default;
  min-height: 100vh;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

mark.hl {
  background: linear-gradient(180deg, transparent 55%, var(--highlight) 55%, var(--highlight) 92%, transparent 92%);
  color: inherit;
  padding: 0 .15em;
  border-radius: 2px;
}

em { font-style: italic; color: var(--algae-deep); }

/* ============================================================
   LIVING BACKGROUND LAYERS
   ============================================================ */

.bg-graph, .bg-water, .bg-particles, .bg-edge-algae, .cursor-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

/* graph paper */
.bg-graph {
  background-color: var(--paper);
  background-image:
    linear-gradient(var(--line-blue) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-blue) 1px, transparent 1px),
    radial-gradient(circle at 20% 30%, rgba(123,182,97,.08), transparent 40%),
    radial-gradient(circle at 85% 70%, rgba(111,168,176,.10), transparent 45%);
  background-size: 26px 26px, 26px 26px, 100% 100%, 100% 100%;
  opacity: .55;
}
.bg-graph::after { /* aged paper vignette */
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at center, transparent 55%, var(--paper-shadow) 140%);
  mix-blend-mode: multiply;
  opacity: .5;
}

/* faint water ripples */
.bg-water { overflow: hidden; opacity: .5; }
.ripple-static {
  position: absolute;
  border-radius: 50%;
  border: 1.5px solid var(--water);
  opacity: .0;
  animation: waterPulse 9s ease-out infinite;
}
.ripple-static.r1 { width: 40vmax; height: 40vmax; left: 10%;  top: 20%; animation-delay: 0s; }
.ripple-static.r2 { width: 55vmax; height: 55vmax; left: 60%;  top: 55%; animation-delay: 3s; }
.ripple-static.r3 { width: 30vmax; height: 30vmax; left: 35%;  top: 75%; animation-delay: 6s; }
@keyframes waterPulse {
  0%   { transform: scale(.4); opacity: .0; }
  40%  { opacity: .18; }
  100% { transform: scale(1.15); opacity: 0; }
}

/* floating particles injected by JS */
.bg-particles { overflow: hidden; }
.particle {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, var(--algae-glow), var(--algae) 70%);
  opacity: .0;
  box-shadow: 0 0 6px rgba(123,182,97,.5);
  animation: floatUp linear infinite;
}
@keyframes floatUp {
  0%   { transform: translateY(20px) translateX(0) scale(.6); opacity: 0; }
  10%  { opacity: .5; }
  50%  { transform: translateY(-45vh) translateX(14px) scale(1); }
  90%  { opacity: .45; }
  100% { transform: translateY(-95vh) translateX(-10px) scale(.7); opacity: 0; }
}

/* algae slowly growing along the screen edges */
.bg-edge-algae .edge {
  position: absolute;
  background-repeat: repeat-x;
  opacity: .0;
  transition: opacity 2s ease;
  --leaf: radial-gradient(ellipse 8px 16px at 50% 100%, var(--algae) 0 60%, transparent 62%);
}
.bg-edge-algae.grown .edge { opacity: .38; }
.edge-top, .edge-bottom { left: 0; right: 0; height: 60px; background-image:
    radial-gradient(ellipse 10px 26px at 6% 0%, var(--algae-deep) 0 55%, transparent 58%),
    radial-gradient(ellipse 8px 20px at 14% 0%, var(--algae) 0 55%, transparent 58%),
    radial-gradient(ellipse 12px 30px at 22% 0%, var(--algae-bright) 0 55%, transparent 58%);
  background-size: 90px 60px; }
.edge-top { top: -6px; transform: scaleY(-1); }
.edge-bottom { bottom: -6px; }
.edge-left, .edge-right { top: 0; bottom: 0; width: 60px;
  background-repeat: repeat-y;
  background-image:
    radial-gradient(ellipse 26px 10px at 0% 8%, var(--algae-deep) 0 55%, transparent 58%),
    radial-gradient(ellipse 20px 8px at 0% 16%, var(--algae) 0 55%, transparent 58%),
    radial-gradient(ellipse 30px 12px at 0% 24%, var(--algae-bright) 0 55%, transparent 58%);
  background-size: 60px 90px; }
.edge-left { left: -6px; }
.edge-right { right: -6px; transform: scaleX(-1); }

/* cursor water-ripple trail */
.cursor-layer { z-index: 9999; }
.cursor-ripple {
  position: absolute;
  width: 14px; height: 14px;
  margin: -7px 0 0 -7px;
  border-radius: 50%;
  border: 1.5px solid var(--water);
  animation: cursorRipple .7s ease-out forwards;
}
@keyframes cursorRipple {
  0%   { transform: scale(.3); opacity: .6; }
  100% { transform: scale(2.6); opacity: 0; }
}
.cursor-dot {
  position: absolute; width: 6px; height: 6px; margin: -3px 0 0 -3px;
  border-radius: 50%; background: var(--algae-glow);
  box-shadow: 0 0 8px var(--algae-bright);
  animation: dotFade 1.1s ease-out forwards;
}
@keyframes dotFade { to { opacity: 0; transform: scale(.4) translateY(8px); } }

/* ink sketch color */
.ink { color: var(--pencil); }
.ink.faded { opacity: .45; }

/* ============================================================
   HOMEPAGE COVER
   ============================================================ */
.cover {
  position: relative;
  z-index: 5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 5vh 6vw;
  transition: transform 1s cubic-bezier(.6,.05,.3,1), opacity .8s ease;
  transform-origin: left center;
}
.cover.opened {
  transform: perspective(1600px) rotateY(-105deg);
  opacity: 0;
  pointer-events: none;
}
.cover-page {
  position: relative;
  background: linear-gradient(180deg, var(--paper) 0%, var(--paper-2) 100%);
  border-radius: 6px;
  padding: clamp(2rem, 5vw, 4rem) clamp(1.5rem, 6vw, 5rem);
  max-width: 620px;
  width: 100%;
  text-align: center;
  box-shadow: 0 18px 50px -18px var(--shadow), inset 0 0 0 1px rgba(43,58,47,.06);
  border: 1px solid rgba(43,58,47,.10);
}
.cover-page::before { /* hand-drawn double border */
  content: "";
  position: absolute; inset: 12px;
  border: 2px solid var(--ink-soft);
  border-radius: 8px;
  opacity: .28;
  -webkit-mask: linear-gradient(#000,#000);
  clip-path: polygon(1% 2%, 99% 0, 100% 98%, 2% 100%);
  pointer-events: none;
}
.cover-label {
  font-family: 'Special Elite', monospace;
  letter-spacing: .32em;
  font-size: .78rem;
  color: var(--pencil);
  margin: 0 0 .4rem;
}
.cover-title {
  font-family: 'Caveat', cursive;
  font-size: clamp(3.2rem, 11vw, 5.6rem);
  line-height: .9;
  margin: .2rem 0 .6rem;
  color: var(--algae-deep);
  text-shadow: 1px 1px 0 rgba(123,182,97,.35);
  font-weight: 700;
}
.cover-sketch { display: flex; align-items: flex-end; justify-content: center; gap: 1.5rem; height: 120px; margin: .3rem 0 1rem; }
.cover-sketch svg { height: 120px; width: auto; }
.cover-sketch svg:last-child { height: 60px; }
.cover-tagline {
  font-size: clamp(1.05rem, 2.6vw, 1.3rem);
  color: var(--ink-soft);
  line-height: 1.55;
  max-width: 30ch;
  margin: 0 auto 1.4rem;
}
.margin-note {
  font-family: 'Caveat', cursive;
  color: var(--red-pen);
  font-size: 1.25rem;
  transform: rotate(-4deg);
}
.note-cover { display: inline-flex; align-items: center; gap: .3rem; margin: 0 0 1.6rem; }
.mini-arrow { width: 54px; height: 34px; color: var(--red-pen); }
.mini-arrow.up { transform: rotate(6deg); }

.scroll-hint {
  font-family: 'Caveat', cursive;
  color: var(--pencil);
  margin-top: 2rem;
  opacity: .7;
  animation: bob 2.4s ease-in-out infinite;
}
@keyframes bob { 50% { transform: translateY(6px); } }

/* buttons */
.btn {
  position: relative;
  font-family: 'Kalam', cursive;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--paper);
  background: var(--algae);
  border: none;
  padding: .85em 1.6em;
  border-radius: 40px 38px 40px 36px / 38px 40px 36px 40px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: .5em;
  box-shadow: 0 6px 0 var(--algae-deep), 0 10px 20px -6px var(--shadow);
  overflow: hidden;
  transition: transform .12s ease, box-shadow .12s ease, background .3s ease;
  isolation: isolate;
}
.btn:hover { transform: translateY(-2px); background: var(--algae-bright); box-shadow: 0 8px 0 var(--algae-deep), 0 14px 26px -8px var(--shadow); }
.btn:active { transform: translateY(3px); box-shadow: 0 3px 0 var(--algae-deep); }
.btn .arrow { transition: transform .25s ease; }
.btn:hover .arrow { transform: translateX(5px); }
.btn-open { font-size: 1.2rem; padding: 1em 2em; }

/* ripple + particle burst inside buttons (JS injected) */
.btn-ripple {
  position: absolute; border-radius: 50%;
  background: rgba(255,255,255,.5);
  transform: scale(0); pointer-events: none;
  animation: btnRipple .6s ease-out forwards; z-index: -1;
}
@keyframes btnRipple { to { transform: scale(3.4); opacity: 0; } }
.btn-spore {
  position: absolute; width: 7px; height: 7px; border-radius: 50%;
  background: var(--algae-glow); box-shadow: 0 0 6px var(--algae-glow);
  pointer-events: none; z-index: 5;
  animation: sporeFly .7s ease-out forwards;
}
@keyframes sporeFly { to { transform: translate(var(--dx), var(--dy)) scale(.2); opacity: 0; } }

/* ============================================================
   NAVIGATION
   ============================================================ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  background: rgba(244,239,225,.9);
  backdrop-filter: blur(6px);
  border-bottom: 2px solid var(--ink-soft);
  transform: translateY(-120%);
  transition: transform .6s cubic-bezier(.6,.05,.3,1);
}
.nav.show { transform: translateY(0); }
.nav-inner {
  max-width: 1100px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: .55rem 1.2rem;
}
.nav-brand { display: flex; align-items: center; gap: .5rem; text-decoration: none; color: var(--algae-deep); }
.brand-mark { font-size: 1.5rem; animation: wobble 5s ease-in-out infinite; display: inline-block; }
@keyframes wobble { 25% { transform: rotate(-8deg); } 75% { transform: rotate(8deg); } }
.brand-text { font-family: 'Caveat', cursive; font-weight: 700; font-size: 1.7rem; }
.nav-links {
  display: flex; gap: .3rem; list-style: none; margin: 0; padding: 0;
}
.nav-links a {
  font-family: 'Kalam', cursive; font-weight: 700;
  text-decoration: none; color: var(--ink); padding: .4em .8em;
  border-radius: 20px; position: relative; transition: color .2s ease;
}
.nav-links a::after {
  content: ""; position: absolute; left: 12%; right: 12%; bottom: 4px; height: 8px;
  background: var(--highlight); border-radius: 6px; transform: scaleX(0);
  transform-origin: left; transition: transform .25s ease; z-index: -1; opacity: .8;
}
.nav-links a:hover { color: var(--algae-deep); }
.nav-links a:hover::after, .nav-links a.active::after { transform: scaleX(1); }
.nav-links a.active { color: var(--algae-deep); }

.nav-toggle { display: none; flex-direction: column; gap: 4px; background: none; border: none; cursor: pointer; padding: 6px; }
.nav-toggle span { width: 24px; height: 2.5px; background: var(--ink); border-radius: 2px; transition: .3s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* algae strands growing under the nav */
.nav-algae { position: absolute; left: 0; right: 0; bottom: -4px; height: 0; overflow: visible; pointer-events: none; }
.nav-algae .strand {
  position: absolute; bottom: 0; width: 34px; height: 60px; color: var(--algae);
  transform-origin: bottom center; transform: scaleY(0);
  transition: transform 1.4s cubic-bezier(.34,1.56,.64,1);
}
.nav.grown .strand { transform: scaleY(1); }
.nav-algae .s1 { left: 18%; transition-delay: .1s; color: var(--algae-deep); }
.nav-algae .s2 { left: 52%; transition-delay: .35s; height: 46px; }
.nav-algae .s3 { left: 81%; transition-delay: .55s; color: var(--algae-bright); height: 52px; }

/* ============================================================
   NOTEBOOK SHEETS
   ============================================================ */
.notebook { position: relative; z-index: 5; }
.sheet {
  position: relative;
  max-width: 1000px;
  margin: 2.5rem auto;
  padding: clamp(1.5rem, 4vw, 3rem);
  background: linear-gradient(180deg, var(--paper) 0%, var(--paper-2) 100%);
  border-radius: 4px 14px 6px 12px;
  box-shadow: 0 14px 40px -20px var(--shadow), inset 0 0 0 1px rgba(43,58,47,.05);
  /* red margin line, like a real notebook */
  border-left: 2px solid rgba(184,80,63,.35);
  opacity: 0;
  transform: translateY(40px) rotate(.4deg);
  transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.3,1);
}
.sheet.in { opacity: 1; transform: translateY(0) rotate(0); }
.sheet-alt { transform: translateY(40px) rotate(-.4deg); }
.sheet::before { /* spiral binding holes */
  content: "";
  position: absolute; left: -1px; top: 24px; bottom: 24px; width: 20px;
  background-image: radial-gradient(circle at 10px 12px, var(--paper-shadow) 0 4px, transparent 5px);
  background-size: 20px 34px; opacity: .8;
}
.sheet-inner { padding-left: 1.4rem; position: relative; z-index: 2; }
.sheet:first-of-type { margin-top: 90px; }

.sheet-head { margin-bottom: 1.8rem; }
.entry-tag {
  font-family: 'Special Elite', monospace;
  letter-spacing: .22em; font-size: .74rem; color: var(--pencil);
  margin: 0 0 .3rem;
}
.sheet-title {
  font-family: 'Caveat', cursive; font-weight: 700;
  font-size: clamp(2.4rem, 6vw, 3.4rem); line-height: 1;
  margin: 0; color: var(--algae-deep);
}
.sheet-title::after {
  content: ""; display: block; width: 130px; height: 10px; margin-top: .2rem;
  background: var(--highlight); border-radius: 8px 12px 8px 14px; opacity: .75;
  transform: rotate(-1deg);
}
.sheet-sub { font-family: 'Shadows Into Light', cursive; font-size: 1.3rem; color: var(--ink-soft); margin: .6rem 0 0; }

/* creeping vine between sections */
.vine {
  position: absolute; left: 8%; top: -34px; width: 3px; height: 40px;
  background: linear-gradient(var(--algae-deep), var(--algae));
  transform-origin: top; transform: scaleY(0);
  border-radius: 3px; z-index: 1;
}
.vine::before, .vine::after {
  content: ""; position: absolute; width: 14px; height: 22px; border-radius: 0 80% 0 80%;
  background: var(--algae-bright); top: 12px;
}
.vine::before { left: 3px; transform: rotate(20deg); }
.vine::after  { right: 3px; top: 22px; transform: rotate(-160deg) scaleX(-1); background: var(--algae); }
.sheet.in .vine { animation: vineGrow 1.2s ease forwards .2s; }
@keyframes vineGrow { to { transform: scaleY(1); } }

.handwrite { font-size: 1.18rem; line-height: 1.7; color: var(--ink); margin: 0 0 1rem; }
.handwrite.drop::first-letter {
  font-family: 'Caveat', cursive; font-size: 3.2rem; float: left;
  line-height: .8; padding: .05em .12em 0 0; color: var(--algae);
}
.inline-note {
  display: inline-block; position: relative;
  font-family: 'Caveat', cursive; color: var(--red-pen); font-size: 1.1rem;
  transform: rotate(-2deg); margin: 0 .2em;
}
.inline-note .mini-arrow { position: absolute; right: -46px; top: -6px; }

.note-block { margin: 1.5rem 0; padding-left: 1rem; border-left: 3px dashed rgba(79,127,63,.4); }
.note-h {
  font-family: 'Caveat', cursive; font-size: 1.7rem; color: var(--algae-deep);
  margin: 0 0 .2rem;
}
.check-list { list-style: none; padding: 0; margin: 0; }
.check-list li { position: relative; padding-left: 1.8rem; margin-bottom: .55rem; font-size: 1.12rem; line-height: 1.5; }
.check-list li::before {
  content: "✓"; position: absolute; left: 0; top: -2px;
  color: var(--algae); font-weight: 700; font-size: 1.2rem;
  transform: rotate(-8deg);
}

/* ------- About layout ------- */
.about-grid { display: grid; grid-template-columns: 1.7fr 1fr; gap: 2.2rem; align-items: start; }
.about-side { position: relative; padding-top: 1rem; }

.polaroid {
  background: #fff; padding: 10px 10px 42px; border-radius: 2px;
  box-shadow: 0 10px 26px -12px var(--shadow); margin: 0;
  position: relative; max-width: 260px;
}
.polaroid::before { /* tape on top */
  content: ""; position: absolute; top: -12px; left: 50%; transform: translateX(-50%) rotate(-3deg);
  width: 80px; height: 26px; background: var(--tape);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.4);
}
.polaroid-photo {
  aspect-ratio: 4/3; border-radius: 1px; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(160deg, #cfe3d6, #a9c9c0);
}
.polaroid figcaption { font-family: 'Shadows Into Light', cursive; text-align: center; margin-top: .5rem; color: var(--ink-soft); font-size: 1.05rem; }
.tilt-r { transform: rotate(3deg); transition: transform .3s ease; }
.tilt-r:hover { transform: rotate(0) scale(1.03); }
.lake-photo svg { width: 90%; color: var(--water-deep); }

.note-scribble { display: block; margin: 1.4rem 0 0; transform: rotate(-3deg); }
.note-scribble.note-2 { transform: rotate(2deg); color: var(--algae-deep); }

/* ------- Presentations / Field Reports ------- */
.reports-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 1.8rem 2rem; margin-top: 1rem; }
.report-card {
  position: relative; background: #fbf8ee; padding: 1.3rem 1.3rem 1.5rem;
  border: 1px solid rgba(43,58,47,.14); border-radius: 3px;
  box-shadow: 0 8px 20px -12px var(--shadow);
  transform: rotate(var(--tilt, -1.2deg));
  transition: transform .25s ease, box-shadow .25s ease;
}
.report-card::before { /* pin */
  content: ""; position: absolute; top: -9px; left: 50%; transform: translateX(-50%);
  width: 16px; height: 16px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #e97c6a, var(--red-pen));
  box-shadow: 0 3px 5px -1px rgba(0,0,0,.35);
}
.report-card:hover { transform: rotate(0) translateY(-4px) scale(1.02); box-shadow: 0 16px 30px -14px var(--shadow); }
.report-num { font-family: 'Special Elite', monospace; font-size: .72rem; letter-spacing: .18em; color: var(--pencil); }
.report-topic { font-family: 'Caveat', cursive; font-size: 1.85rem; color: var(--algae-deep); line-height: 1; margin: .2rem 0 .8rem; }
.report-line { font-size: 1rem; margin: .35rem 0; color: var(--ink); }
.report-line b { font-family: 'Special Elite', monospace; font-size: .68rem; letter-spacing: .1em; color: var(--pencil); display: block; }
.report-status { margin-top: .8rem; font-family: 'Kalam', cursive; font-weight: 700; color: var(--algae); display: inline-flex; align-items: center; gap: .3em; }
.report-status .chk { color: var(--algae); }
.report-card .diatom { position: absolute; right: 8px; bottom: 6px; width: 42px; height: 42px; color: rgba(79,127,63,.3); }

/* ------- Impact / Growth Log ------- */
.growth-log { display: flex; flex-direction: column; gap: 1.6rem; margin-top: 1rem; max-width: 640px; }
.growth-item { }
.growth-label { display: flex; justify-content: space-between; align-items: baseline; font-family: 'Special Elite', monospace; letter-spacing: .12em; font-size: .8rem; color: var(--ink-soft); margin-bottom: .4rem; }
.growth-value { font-family: 'Caveat', cursive; font-size: 1.9rem; color: var(--algae-deep); line-height: 1; }
.growth-track {
  position: relative; height: 26px; border-radius: 14px;
  background: repeating-linear-gradient(90deg, rgba(43,58,47,.06) 0 12px, transparent 12px 24px), var(--paper-2);
  box-shadow: inset 0 2px 5px -2px var(--shadow); overflow: hidden;
  border: 1px solid rgba(43,58,47,.1);
}
.growth-fill {
  position: absolute; left: 0; top: 0; bottom: 0; width: 0;
  background: linear-gradient(90deg, var(--algae-deep), var(--algae), var(--algae-bright));
  border-radius: 14px;
  transition: width 1.6s cubic-bezier(.3,.8,.3,1);
  box-shadow: 0 0 12px rgba(123,182,97,.6);
}
.growth-fill::after { /* bubbly algae texture on the fill edge */
  content: ""; position: absolute; right: 0; top: 0; bottom: 0; width: 26px;
  background: radial-gradient(circle at 60% 30%, var(--algae-glow) 0 3px, transparent 4px),
              radial-gradient(circle at 30% 70%, var(--algae-glow) 0 2px, transparent 3px);
  opacity: .8;
}
.sheet.in .growth-fill { width: var(--pct); }

/* ------- Team / Research Crew ------- */
.crew-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 2rem; margin-top: 1rem; }
.crew-card {
  background: #fbf8ee; border-radius: 3px; padding: 1rem 1rem 1.3rem;
  border: 1px solid rgba(43,58,47,.14);
  box-shadow: 0 8px 20px -12px var(--shadow);
  transform: rotate(var(--tilt, 1deg));
  transition: transform .25s ease;
  position: relative;
}
.crew-card::after { content: ""; position: absolute; top: -10px; right: 18px; width: 60px; height: 22px; background: var(--tape); transform: rotate(6deg); }
.crew-card:hover { transform: rotate(0) translateY(-4px); }
.crew-avatar {
  aspect-ratio: 1; border-radius: 2px; margin-bottom: .7rem;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(160deg, #dce9d6, #b7d1b0);
  border: 1px solid rgba(43,58,47,.1);
}
.crew-avatar svg { width: 62%; color: var(--algae-deep); }
.crew-name { font-family: 'Caveat', cursive; font-size: 1.7rem; color: var(--algae-deep); line-height: 1; margin: 0; }
.crew-role { font-family: 'Special Elite', monospace; font-size: .68rem; letter-spacing: .1em; color: var(--pencil); margin: .25rem 0; }
.crew-spec { font-size: 1rem; color: var(--ink); margin: .3rem 0; }
.crew-spec b { font-family: 'Special Elite', monospace; font-size: .62rem; letter-spacing: .1em; color: var(--pencil); display: block; }
.crew-fact { font-family: 'Shadows Into Light', cursive; font-size: 1.05rem; color: var(--water-deep); margin: .6rem 0 0; padding-top: .5rem; border-top: 1px dashed rgba(43,58,47,.2); }
.crew-fact::before { content: "\201C"; }
.crew-fact::after { content: "\201D"; }

/* ------- Contact / Field Request ------- */
.contact-wrap { display: grid; grid-template-columns: 1.6fr 1fr; gap: 2.5rem; align-items: start; }
.field-form {
  position: relative; background: #fbf8ee;
  padding: 2rem 2rem 2.4rem; border-radius: 3px;
  box-shadow: 0 12px 30px -16px var(--shadow);
  border: 1px solid rgba(43,58,47,.12);
  background-image: repeating-linear-gradient(transparent 0 37px, rgba(111,168,176,.18) 37px 38px);
}
.letter-open { font-family: 'Caveat', cursive; font-size: 1.7rem; color: var(--algae-deep); margin: 0 0 1rem; }
.letter-close { font-family: 'Caveat', cursive; font-size: 1.4rem; color: var(--ink-soft); margin: 1rem 0 1.4rem; }
.form-row { margin-bottom: 1.2rem; }
.form-row label { display: block; font-family: 'Shadows Into Light', cursive; font-size: 1.15rem; color: var(--ink-soft); margin-bottom: .2rem; }
.field-form input, .field-form textarea {
  width: 100%; font-family: 'Kalam', cursive; font-size: 1.1rem; color: var(--ink);
  background: transparent; border: none; border-bottom: 2px dashed rgba(43,58,47,.35);
  padding: .3rem .2rem; resize: vertical;
  transition: border-color .25s ease;
}
.field-form input:focus, .field-form textarea:focus {
  outline: none; border-bottom-color: var(--algae); border-bottom-style: solid;
}
.field-form input::placeholder, .field-form textarea::placeholder { color: var(--pencil); opacity: .6; }
.field-form input.invalid, .field-form textarea.invalid { border-bottom-color: var(--red-pen); }

/* lab stamp */
.stamp {
  position: absolute; top: 40%; left: 50%;
  transform: translate(-50%,-50%) rotate(-14deg) scale(.4);
  border: 4px double var(--stamp-col); border-radius: 8px;
  padding: .5rem 1.4rem; text-align: center; color: var(--stamp-col);
  opacity: 0; pointer-events: none; mix-blend-mode: multiply;
  box-shadow: 0 0 0 2px rgba(79,127,63,.2) inset;
}
.stamp.show { animation: stampIn .5s cubic-bezier(.2,1.4,.4,1) forwards; }
@keyframes stampIn {
  0%   { opacity: 0; transform: translate(-50%,-50%) rotate(-14deg) scale(1.8); }
  60%  { opacity: 1; }
  100% { opacity: .92; transform: translate(-50%,-50%) rotate(-14deg) scale(1); }
}
.stamp-top { display: block; font-family: 'Special Elite', monospace; font-size: 1.7rem; letter-spacing: .1em; font-weight: 700; }
.stamp-bottom { display: block; font-family: 'Special Elite', monospace; font-size: .74rem; letter-spacing: .22em; }

.contact-side { padding-top: 1rem; }
.scope-sketch { width: 120px; margin-top: 1.4rem; color: var(--pencil); }

/* margin note placements */
.note-center { text-align: center; display: block; margin: 2rem auto 0; }
.note-right { text-align: right; display: block; margin-top: 1.5rem; }

/* ------- footer ------- */
.foot { text-align: center; padding: 3rem 1rem 5rem; color: var(--ink-soft); font-family: 'Caveat', cursive; font-size: 1.3rem; }
.foot-small { font-size: 1.05rem; color: var(--pencil); }

/* ============================================================
   ALGAE MASCOT
   ============================================================ */
.mascot { position: fixed; right: 22px; bottom: 22px; z-index: 300; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.mascot-bubble {
  max-width: 190px; background: #fff; color: var(--ink);
  font-family: 'Shadows Into Light', cursive; font-size: 1.05rem; line-height: 1.3;
  padding: .55rem .8rem; border-radius: 14px 14px 4px 14px;
  box-shadow: 0 8px 20px -10px var(--shadow); border: 1.5px solid var(--algae);
  opacity: 0; transform: translateY(8px) scale(.9); transform-origin: bottom right;
  transition: opacity .3s ease, transform .3s ease; pointer-events: none; text-align: center;
}
.mascot-bubble.show { opacity: 1; transform: translateY(0) scale(1); }
.mascot-body {
  width: 64px; height: 64px; border: none; background: none; cursor: pointer; padding: 0;
  filter: drop-shadow(0 6px 10px rgba(43,58,47,.3));
  animation: mascotFloat 3.5s ease-in-out infinite;
}
@keyframes mascotFloat { 50% { transform: translateY(-8px) rotate(-4deg); } }
.mascot-body:hover { animation-play-state: paused; }
.mascot-body svg { width: 100%; height: 100%; overflow: visible; }
.m-blob { fill: var(--algae-bright); }
.m-outline { fill: none; stroke: var(--algae-deep); stroke-width: 2.5; }
.m-eye { fill: #fff; stroke: var(--algae-deep); stroke-width: 1.5; }
.m-pupil { fill: var(--ink); }
.m-smile { fill: none; stroke: var(--algae-deep); stroke-width: 2.5; stroke-linecap: round; }
.m-sprout { fill: var(--algae); stroke: var(--algae-deep); stroke-width: 1.2; }
.mascot-body:active { transform: scale(.9); }

/* page-turn overlay flash */
.turn-overlay {
  position: fixed; inset: 0; z-index: 400; pointer-events: none;
  background: linear-gradient(120deg, rgba(244,239,225,0) 40%, rgba(217,207,180,.9) 50%, rgba(244,239,225,0) 60%);
  transform: translateX(-120%); opacity: 0;
}
.turn-overlay.flip { animation: pageFlip .7s ease forwards; }
@keyframes pageFlip {
  0% { transform: translateX(-120%); opacity: 1; }
  100% { transform: translateX(120%); opacity: 1; }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 760px) {
  .nav-toggle { display: flex; }
  .nav-links {
    position: absolute; top: 100%; right: 8px; left: 8px;
    flex-direction: column; background: var(--paper);
    border: 2px solid var(--ink-soft); border-radius: 10px; padding: .6rem;
    box-shadow: 0 14px 30px -16px var(--shadow);
    max-height: 0; overflow: hidden; opacity: 0; transition: max-height .35s ease, opacity .3s ease; margin-top: 8px;
  }
  .nav-links.open { max-height: 340px; opacity: 1; }
  .about-grid, .contact-wrap { grid-template-columns: 1fr; }
  .about-side { display: flex; flex-wrap: wrap; gap: 1rem; align-items: flex-start; }
  .sheet:first-of-type { margin-top: 80px; }
  .mascot { right: 12px; bottom: 12px; }
  .mascot-bubble { max-width: 150px; font-size: .95rem; }
}
@media (max-width: 460px) {
  .cover-page { padding: 2rem 1.4rem; }
  .inline-note .mini-arrow { display: none; }
}
