/* Mayonis Space: shared story effects + site chrome (Site/story-effects.css).
   Tidied 8 Nov 2026 (Eunice: "tidy up the website, fix mobile responsive, consistent font"):
   - ONE FONT SYSTEM for the whole site: Poppins for every line of text, Playfair Display Italic for the second
     headline line (Home, Me, About, Skills, Portfolio, Contact) and for the Portfolio channel names. Abuget is no
     longer used anywhere. Fonts + OFL licences: Fonts/Headline-Typography-v1/.
   - the superseded headline layers (Didot / Bodoni / size steps) are folded into one block; dead Home rules
     (about-me link, chat CTA, disciplines line, caption) and the unused chapter dissolve are gone.
   - new mobile bar + full-screen chapter menu (phones and tablets had no navigation at all).
   Backup of the previous files: Checkpoints/Before-Tidy-Mobile-Fonts-v1/. */

/* ---- Fonts ---- */
@font-face{font-family:Poppins;src:url('../Fonts/Headline-Typography-v1/Poppins-300-latin.woff2') format('woff2');font-weight:300;font-display:swap}
@font-face{font-family:Poppins;src:url('../Fonts/Headline-Typography-v1/Poppins-400-latin.woff2') format('woff2');font-weight:400;font-display:swap}
@font-face{font-family:Poppins;src:url('../Fonts/Headline-Typography-v1/Poppins-500-latin.woff2') format('woff2');font-weight:500;font-display:swap}
@font-face{font-family:Poppins;src:url('../Fonts/Headline-Typography-v1/Poppins-600-latin.woff2') format('woff2');font-weight:600;font-display:swap}
@font-face{font-family:'Playfair Display';src:url('../Fonts/Headline-Typography-v1/PlayfairDisplay-400-900-latin.woff2') format('woff2');font-weight:400 900;font-display:swap}
@font-face{font-family:'Playfair Display';src:url('../Fonts/Headline-Typography-v1/PlayfairDisplay-Italic-400-900-latin.woff2') format('woff2');font-weight:400 900;font-style:italic;font-display:swap}
:root{--text:Poppins,Arial,sans-serif;--head-1:Poppins,Arial,sans-serif;--head-2:'Playfair Display',Georgia,serif}
/* No bold text (7 Nov 2026, Eunice: "text except headlines, all don't bold"): everything is regular weight except the
   italic second headline line. !important so it also beats the section stylesheets that load after this one. */
body *:not(.headline-line):not(.step-title):not(.m-name){font-weight:400!important}

/* ---- Scroll reveals (text in a section fades up when the section scrolls in; only with .js-reveal) ---- */
.js-reveal [data-reveal]{opacity:0;translate:0 16px;transition:opacity .8s ease,translate .8s ease;transition-delay:var(--reveal-delay,0s)}
.js-reveal .is-revealed [data-reveal]{opacity:1;translate:0 0}
@media(prefers-reduced-motion:reduce){.js-reveal [data-reveal]{translate:none}}   /* 25 Nov 2026, gentle motion: fade in place, no rise (was opacity:1;translate:none;transition:none) */

/* ---- Scroll cues: the mouse-and-chevron icon at the bottom of every chapter except Contact (links to the next one) ---- */
.scroll-cue{position:absolute;left:50%;bottom:clamp(36px,5vh,56px);z-index:3;display:flex;flex-direction:column;align-items:center;gap:4px;transform:translateX(-50%);color:#fff;text-decoration:none;filter:drop-shadow(0 2px 8px rgba(12,42,72,.45))}
.scroll-cue.scroll-mouse{pointer-events:auto}
.story-next{z-index:5}
.story-next.scroll-mouse{z-index:6}
/* Skills' cue is moved into the departure extension by nightfall-section.js; it sits above the foreground grass. */
.nf-departure-extension>.nf-next-cue{bottom:calc(100% + clamp(36px,5vh,56px));z-index:6;pointer-events:auto}
.scroll-mouse .mouse{position:relative;display:block;width:26px;height:40px;border:2px solid #fff;border-radius:15px;transition:transform .3s ease}
.scroll-mouse .wheel{position:absolute;left:50%;top:7px;width:4px;height:9px;margin-left:-2px;border-radius:2px;background:#fff;animation:mouse-wheel 1.9s cubic-bezier(.6,0,.4,1) infinite}
.scroll-mouse .chev{display:flex;flex-direction:column;align-items:center}
.scroll-mouse .chev i{display:block;width:10px;height:10px;margin-top:-2px;border-right:2px solid #fff;border-bottom:2px solid #fff;rotate:45deg;opacity:0;animation:mouse-chev 1.9s ease-in-out infinite}
.scroll-mouse .chev i:nth-child(2){animation-delay:.2s}
.scroll-mouse:hover .mouse,.scroll-mouse:focus-visible .mouse{transform:translateY(-3px)}
@keyframes mouse-wheel{0%{opacity:0;translate:0 -3px}20%{opacity:1}70%{opacity:1;translate:0 11px}100%{opacity:0;translate:0 13px}}
@keyframes mouse-chev{0%{opacity:0;translate:0 -4px}40%{opacity:1}80%,100%{opacity:0;translate:0 5px}}
/* 25 Nov 2026, gentle motion: kept with Reduce Motion on (small, in place); was a reduced-motion off rule */
@media(max-width:820px){.scroll-cue{display:none}}

/* ---- Intro breeze: code-drawn petals and leaves drifting behind the Intro text (story-effects.js) ---- */
.hero-breeze{position:absolute;inset:0;z-index:-1;pointer-events:none;overflow:hidden}
.hero-bit{position:absolute;left:0;top:0;opacity:0;will-change:transform,opacity;filter:drop-shadow(0 1px 1.5px rgba(30,60,30,.2))}
.hero-bit svg{display:block;width:100%;height:100%;overflow:visible}
@media(prefers-reduced-motion:reduce){.hero-breeze{display:none}}

/* ---- Screen-reader-only text + the Home headline slot (one set now: "Explore / the uncharted") ---- */
.sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}
.hero-rotator{display:grid}
.hero-set{grid-area:1/1;visibility:hidden}
.hero-set.is-on{visibility:visible}

/* ---- Headlines: one system for every chapter ----
   Line 1 = Poppins caps with tight tracking; line 2 = Playfair Display Italic, lowercase, pulled up close
   (Eunice's choices, 7-8 Nov 2026, ref "MAKE IT / unexpected."). story-effects.js then balances the two lines to
   the same width (up to 1.6x on Home and data-balance="full" headings, 1.35x in the About/Portfolio columns). */
.hero .hero-set .kicker,.story-step .step-kicker{display:block;margin:0;font-family:var(--head-1);font-weight:400;letter-spacing:-.025em;line-height:.9;text-indent:0;text-transform:uppercase}
.hero .hero-set .headline-line,.story-step .step-title{display:block;margin:-.1em 0 0;font-family:var(--head-2);font-style:italic;font-weight:500;letter-spacing:-.01em;line-height:1;text-transform:lowercase}
.hero .headline{margin:0}
.hero .hero-set .headline-line{text-shadow:0 1px 2px rgba(12,42,72,.45),0 3px 18px rgba(12,42,72,.35)}
.story-step .step-kicker{font-size:clamp(26px,2.5vw,42px)}
.story-step .step-title{font-size:clamp(34px,3.4vw,58px)}
.story-step .step-sub{margin:.55em 0 0;font-size:clamp(15px,1.25vw,19px);line-height:1.45}
@media not all and (max-width:820px){
  .hero .hero-set .kicker,.hero .hero-set .headline-line{font-size:calc(64 * var(--u))}   /* 8 Nov 2026: Home headline 20% smaller (80 -> 64) */
}
@media(max-width:820px){
  .hero .hero-set .kicker{font-size:clamp(24px,4dvh,34px)}
  .hero .hero-set .headline-line{font-size:clamp(30px,5dvh,44px)}
  .story-step .step-kicker{font-size:clamp(24px,7vw,34px)}
  .story-step .step-title{font-size:clamp(30px,9vw,42px)}
  .story-step .step-sub{font-size:15px}
}

/* ---- Chapter eyebrows: one small label style above every chapter headline (Eunice, 7 Nov 2026) ---- */
.hero .hero-eyebrow,#me .me-eyebrow,#about .about-eyebrow,#nightfall .nf-eyebrow,#portfolio .pf-eyebrow,#contact .contact-eyebrow{margin:0 0 12px;font:400 11px/1.3 var(--text);letter-spacing:.28em;text-transform:uppercase}
.hero .hero-eyebrow,#me .me-eyebrow,#nightfall .nf-eyebrow{text-indent:.28em}   /* centred labels: the tracking's trailing space is balanced */
.hero .hero-eyebrow{margin-bottom:calc(16 * var(--u));color:#fff;text-shadow:0 1px 2px rgba(12,42,72,.75),0 2px 12px rgba(12,42,72,.45)}
#me .me-eyebrow,#nightfall .nf-eyebrow{margin-bottom:18px}
@media(max-width:820px){.hero .hero-eyebrow,#me .me-eyebrow,#about .about-eyebrow,#nightfall .nf-eyebrow,#portfolio .pf-eyebrow,#contact .contact-eyebrow{font-size:10px}.hero .hero-eyebrow{margin-bottom:10px}}

/* ---- Home: "Meet Mayonis" top right is the same size as the bottom-left footer text (Eunice, 8 Nov 2026) ---- */
@media not all and (max-width:820px){
  .top-cta{font-size:clamp(10px,calc(12 * min(100vw / 1440,100vh / 1080)),14px);font-size:clamp(10px,calc(12 * min(100vw / 1440,100dvh / 1080)),14px)}
}

/* ---- Home greeting button (8 Nov 2026, Eunice): "I'm Mayonis, nice to meet you" under the headline links to her
   LinkedIn profile as a FILLED white pill (her explicit exception to the no-boxes rule). The pill fades up, its letters
   rise in one by one (spans by story-effects.js), then a soft wave ripples through them every ~7s. ---- */
.hero-actions{display:flex;flex-direction:column;align-items:center;margin-top:calc(30 * var(--u))}
.hero-hello{display:inline-flex;align-items:center;gap:calc(14 * var(--u));padding:calc(8 * var(--u)) calc(8 * var(--u)) calc(8 * var(--u)) calc(26 * var(--u));border-radius:999px;background:#fff;color:#493365;text-decoration:none;font-family:Poppins,Arial,sans-serif;font-size:calc(18 * var(--u));line-height:1.2;letter-spacing:.01em;text-shadow:none;box-shadow:0 10px 30px rgba(12,42,72,.26),0 1px 3px rgba(12,42,72,.2);transition:translate .35s cubic-bezier(.22,1,.36,1),box-shadow .35s ease,background .3s ease,opacity .5s ease}
.hero-hello:hover,.hero-hello:focus-visible{translate:0 -2px;background:#fff;box-shadow:0 14px 36px rgba(12,42,72,.32),0 2px 4px rgba(12,42,72,.2)}
.hero-hello:focus-visible{outline:2px solid #fff;outline-offset:4px}
.hero-hello-icon{display:grid;place-items:center;width:calc(36 * var(--u));height:calc(36 * var(--u));flex:none;border-radius:50%;background:#493365;color:#fff;transition:background .3s ease}
.hero-hello-icon svg{width:52%;height:52%;transition:translate .3s ease}
.hero-hello:hover .hero-hello-icon svg,.hero-hello:focus-visible .hero-hello-icon svg{translate:0 2px}   /* 9 Nov 2026: down arrow, it now leads to the next chapter */
.hero-hello.hello-wait{opacity:0;translate:0 12px}
.hello-word{display:inline-block;white-space:nowrap}
.hero-hello.hello-wait .hello-ch,.hero-hello.is-in .hello-ch{display:inline-block;opacity:0;translate:0 .55em;filter:blur(4px)}
.hero-hello.is-in .hello-ch{animation:hello-in .75s cubic-bezier(.22,1,.36,1) forwards,hello-wave 7s ease-in-out infinite;animation-delay:calc(120ms + var(--i) * 34ms),calc(2.6s + var(--i) * 45ms)}
@keyframes hello-in{to{opacity:1;translate:0 0;filter:blur(0)}}
@keyframes hello-wave{0%,14%,100%{translate:0 0}7%{translate:0 -.2em}}
@media(max-width:820px){.hero-actions{margin-top:16px}.hero-hello{font-size:14px;gap:10px;padding:6px 6px 6px 18px}.hero-hello-icon{width:30px;height:30px}}
/* 25 Nov 2026, gentle motion: kept with Reduce Motion on (small, in place); was a reduced-motion off rule */

/* ---- Story steps + mini sliders (7 Nov 2026, Eunice's About and Portfolio briefs): a section's copy shows step 1,
   then swaps once to step 2 (story-effects.js); a mini slider shows image cards (placeholders until Eunice adds images). ---- */
.story-steps{display:grid}
.story-step{grid-area:1/1;align-self:start;min-width:0;visibility:hidden}
.story-step.is-on{visibility:visible}
.step-nav{display:flex;gap:24px;margin-top:16px}
.step-nav button,.mini-tabs button{position:relative;border:0;background:none;padding:4px 0;color:inherit;font:400 11.5px/1.2 var(--text);letter-spacing:.18em;text-transform:uppercase;text-shadow:inherit;opacity:.6;cursor:pointer;transition:opacity .25s}
.step-nav button::after,.mini-tabs button::after{content:"";position:absolute;left:0;right:0;bottom:-3px;height:2px;border-radius:2px;background:currentColor;transform:scaleX(0);transform-origin:left;transition:transform .3s ease}
.step-nav button:hover,.mini-tabs button:hover,.step-nav button[aria-current=true],.mini-tabs button[aria-pressed=true]{opacity:1}
.step-nav button[aria-current=true]::after,.mini-tabs button[aria-pressed=true]::after{transform:scaleX(1)}
.mini-slider{--gap:14px;margin-top:18px}
.mini-head{display:flex;align-items:center;justify-content:space-between;gap:12px 18px;margin-bottom:10px}
.mini-slider .mini-label{margin:0;font:400 11.5px/1.2 var(--text);letter-spacing:.18em;text-transform:uppercase}
.mini-tabs{display:flex;flex-wrap:wrap;gap:4px 16px;min-width:0}
.mini-nav{display:flex;align-items:center;gap:10px;flex-shrink:0}
.mini-nav button{display:grid;place-items:center;width:32px;height:32px;padding:0;border:1.5px solid currentColor;border-radius:50%;background:none;color:inherit;cursor:pointer;transition:opacity .25s,transform .25s}
.mini-nav button:hover:not(:disabled){transform:scale(1.08)}
.mini-nav button:disabled{opacity:.3;cursor:default}
.mini-nav svg{width:13px;height:13px}
.mini-dots{display:flex;gap:6px}
.mini-dots i{width:6px;height:6px;border-radius:50%;background:currentColor;opacity:.35;transition:opacity .25s,transform .25s}
.mini-dots i.on{opacity:1;transform:scale(1.3)}
.mini-track{display:flex;gap:var(--gap);overflow-x:auto;scroll-snap-type:x mandatory;scroll-behavior:smooth;scrollbar-width:none;overscroll-behavior-x:contain;outline-offset:4px}
.mini-track::-webkit-scrollbar{display:none}
.mini-card{flex:0 0 calc((100% - var(--gap) * (var(--per,2) - 1)) / var(--per,2));margin:0;scroll-snap-align:start}
.mini-card[hidden]{display:none}
.mini-media{position:relative;display:grid;place-items:center;aspect-ratio:4/3;border-radius:14px;overflow:hidden}
.mini-media img,.mini-media video{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.mini-card.is-placeholder .mini-media{background:color-mix(in srgb,currentColor 12%,transparent);border:1.5px dashed color-mix(in srgb,currentColor 50%,transparent)}
.mini-media svg{width:22%;max-width:54px;opacity:.8}
.mini-card figcaption{margin-top:8px;font:400 13px/1.35 var(--text)}
.mini-tag{display:block;font-size:10.5px;letter-spacing:.18em;text-transform:uppercase;opacity:.8}
@media(prefers-reduced-motion:reduce){.mini-track{scroll-behavior:auto}}

/* ---- Floating chapter nav (7 Nov 2026, Eunice): desktop only, built by story-effects.js ---- */
.dot-nav{display:none}
/* Restyled 7 Nov 2026 (Eunice: "tidy up the styling to match the page"): same look as the page's own controls (the Intro
   "About me" round arrow and the header links): round buttons with a fine ring, a soft glassy tint of the scene's colour and a soft shadow; the
   current one filled. The buttons are white. The first three chapters use violet icons. Portfolio and Contact use brown icons. */
@media not all and (max-width:820px){
  html.has-dotnav .header .nav{display:none}
  .dot-nav{--ink:#fff;--ink-soft:rgba(255,255,255,.7);--glow:rgba(12,42,72,.45);--tint:rgba(31,90,126,.3);--on-bg:#fff;--on-ink:#1f5a7e;--label-shadow:0 1px 2px rgba(12,42,72,.6),0 2px 12px rgba(12,42,72,.4);
    display:block;position:fixed;right:clamp(16px,2vw,32px);top:50%;z-index:50;transform:translateY(-50%);width:46px;pointer-events:none}
  .dot-nav[data-tone=violet]{--ink:#fff;--ink-soft:#ffffffa8;--glow:#33244b66;--tint:#fff;--on-bg:#fff;--on-ink:#493365;--label-shadow:0 1px 3px #241734,0 2px 9px #241734}
  .dot-nav[data-tone=brown]{--tint:#fff;--on-ink:#4b3026;--glow:#4b302666}
  .dot-nav ol{position:relative;z-index:1;display:flex;flex-direction:column;align-items:center;gap:30px;margin:0;padding:0;list-style:none}
  .dot-line,.dot-fill{position:absolute;left:50%;width:1.5px;margin-left:-.75px;border-radius:2px;pointer-events:none}
  .dot-line{top:var(--line-top,0);bottom:var(--line-bottom,0);background:var(--ink-soft);box-shadow:0 0 6px var(--glow);transition:background .5s}
  .dot-fill{top:var(--line-top,0);height:var(--fill,0px);background:var(--ink);transition:height .6s cubic-bezier(.22,1,.36,1),background .5s}
  .dot-nav li{position:relative;display:grid;place-items:center;width:46px;height:46px}
  /* 10 Nov 2026 (Zen): plain dots. Each chapter is a small filled dot; only the current one and the one under the
     mouse (or keyboard focus) grow into a round button and show their icon. The ::after pad keeps a comfortable
     ~40px hit area round each small dot (the li stays 46px, so the line and the fill are unchanged). */
  .dot-nav a{position:relative;display:grid;place-items:center;width:11px;height:11px;border-radius:50%;border:1.5px solid var(--ink);background:var(--ink);color:var(--ink);box-shadow:0 1px 8px var(--glow);pointer-events:auto;
    transition:width .45s cubic-bezier(.22,1,.36,1),height .45s cubic-bezier(.22,1,.36,1),background .4s,border-color .4s,color .4s,box-shadow .4s}
  .dot-nav a::after{content:"";position:absolute;inset:-15px;border-radius:50%}
  .dot-nav a svg{width:18px;height:18px;opacity:0;scale:.4;filter:drop-shadow(0 1px 2px var(--glow));transition:width .45s,height .45s,opacity .25s,scale .45s cubic-bezier(.22,1,.36,1)}
  .dot-nav a:is(:hover,:focus-visible){width:38px;height:38px;background:var(--tint);-webkit-backdrop-filter:blur(5px);backdrop-filter:blur(5px);box-shadow:0 2px 12px var(--glow)}
  .dot-nav a:is(:hover,:focus-visible) svg,.dot-nav a[aria-current=true] svg{opacity:1;scale:1}
  .dot-nav a[aria-current=true]{width:44px;height:44px;border-color:var(--on-bg);background:var(--on-bg);color:var(--on-ink);box-shadow:0 0 0 5px color-mix(in srgb,var(--on-bg) 20%,transparent),0 4px 16px var(--glow)}
  .dot-nav a[aria-current=true] svg{width:20px;height:20px;filter:none}
  .dot-label{position:absolute;right:calc(100% + 14px);top:50%;translate:8px -50%;opacity:0;transition:opacity .25s ease,translate .25s ease}
  .dot-nav a:hover .dot-label,.dot-nav a:focus-visible .dot-label{opacity:1;translate:0 -50%}
  .dot-nav:is([data-tone=violet],[data-tone=brown]) a:is(:hover,:focus-visible){color:var(--on-ink)}
  .dot-nav a:focus-visible{outline:2px solid var(--ink);outline-offset:4px}
}
/* 25 Nov 2026, gentle motion: kept with Reduce Motion on (small, in place); was a reduced-motion off rule */
/* Nav icon animations (7 Nov 2026, Eunice: animate on hover; Home is now a house, was a cloud). They loop while the button is hovered or focused. */
.dot-nav svg *{transform-box:fill-box;transform-origin:center}
.dot-nav .i-smoke,.dot-nav .i-line{stroke-dasharray:1;stroke-dashoffset:1}
.dot-nav .i-hill{stroke-dasharray:1;stroke-dashoffset:0}
.dot-nav .i-pen{transform-origin:0% 100%}
.dot-nav .i-house{transform-origin:50% 100%}
.dot-nav a:is(:hover,:focus-visible) .i-house{animation:i-hop 1.4s ease-in-out infinite}
.dot-nav a:is(:hover,:focus-visible) .i-smoke{animation:i-smoke 1.4s ease-out infinite}
.dot-nav a:is(:hover,:focus-visible) .i-star{animation:i-spark 1.3s cubic-bezier(.45,0,.3,1.4) infinite}
.dot-nav a:is(:hover,:focus-visible) .i-twinkle{animation:i-twinkle 1.3s ease-in-out infinite}
.dot-nav a:is(:hover,:focus-visible) .i-sun{animation:i-pop 1.6s cubic-bezier(.3,1.6,.5,1) infinite}
.dot-nav a:is(:hover,:focus-visible) .i-hill{animation:i-redraw 1.6s ease-in-out infinite}
.dot-nav a:is(:hover,:focus-visible) .i-pen{animation:i-write 1.2s ease-in-out infinite}
.dot-nav a:is(:hover,:focus-visible) .i-line{animation:i-draw 1.2s ease-in-out infinite}
/* Me (7 Nov 2026): a smiley face; on hover it blinks and the smile widens. */
.dot-nav a:is(:hover,:focus-visible) .i-eyes{animation:i-blink 1.6s ease-in-out infinite}
.dot-nav a:is(:hover,:focus-visible) .i-grin{animation:i-grin 1.6s ease-in-out infinite}
/* Nightfall (8 Nov 2026): a crescent moon with a small star; on hover the moon rocks and the star twinkles. */
.dot-nav .i-moon{transform-origin:60% 60%}
.dot-nav a:is(:hover,:focus-visible) .i-moon{animation:i-rock 1.8s ease-in-out infinite}
.dot-nav a:is(:hover,:focus-visible) .i-star2{animation:i-twinkle 1.3s ease-in-out infinite}
@keyframes i-rock{0%,100%{transform:rotate(0)}30%{transform:rotate(-16deg)}65%{transform:rotate(9deg)}}
@keyframes i-blink{0%,38%,58%,100%{transform:scaleY(1)}46%,50%{transform:scaleY(.12)}}
@keyframes i-grin{0%,100%{transform:scale(1)}55%{transform:scale(1.22,1.3)}}
@keyframes i-hop{0%,100%{transform:translateY(0) scale(1,1)}18%{transform:translateY(0) scale(1.07,.88)}42%{transform:translateY(-1.8px) scale(.96,1.06)}66%{transform:translateY(0) scale(1.03,.97)}82%{transform:translateY(0) scale(1,1)}}
@keyframes i-smoke{0%,30%{stroke-dashoffset:1;opacity:0;transform:translateY(0)}45%{opacity:1}75%{stroke-dashoffset:0;opacity:1}100%{stroke-dashoffset:0;opacity:0;transform:translateY(-1.2px)}}
@keyframes i-draw{0%{stroke-dashoffset:1}45%,70%{stroke-dashoffset:0}100%{stroke-dashoffset:-1}}
@keyframes i-spark{0%,100%{transform:scale(1) rotate(0)}35%{transform:scale(.72) rotate(-14deg)}65%{transform:scale(1.14) rotate(8deg)}}
@keyframes i-twinkle{0%,100%{transform:scale(1);opacity:1}30%{transform:scale(0);opacity:0}60%{transform:scale(1.45);opacity:1}}
@keyframes i-pop{0%,100%{transform:translateY(0) scale(1)}30%{transform:translateY(-1.8px) scale(1.3)}55%{transform:translateY(0) scale(1)}}
@keyframes i-redraw{0%,15%{stroke-dashoffset:0}35%{stroke-dashoffset:1}75%,100%{stroke-dashoffset:0}}
@keyframes i-write{0%,100%{transform:rotate(0) translate(0,0)}25%{transform:rotate(-12deg) translate(-1px,0)}50%{transform:rotate(5deg) translate(1.2px,0)}75%{transform:rotate(-7deg) translate(.4px,0)}}
/* 25 Nov 2026, gentle motion: kept with Reduce Motion on (small, in place); was a reduced-motion off rule */

/* ---- Floating top logo (7 Nov 2026, Eunice): from the second chapter on, the Mayonis logo floats at the top centre
   (the big Intro logo glides up into it; story-effects.js). Desktop only; the header logo is hidden there. ---- */
.float-logo{display:none}
@media not all and (max-width:820px){
  html.has-floatlogo .header .wordmark{visibility:hidden}
  .float-logo{display:block;position:fixed;left:50%;top:14px;z-index:52;width:58px;height:58px;margin-left:-29px;opacity:0;pointer-events:none;transition:opacity .3s ease;
    filter:drop-shadow(0 0 8px rgba(255,255,255,.55)) drop-shadow(0 3px 10px rgba(12,42,72,.3))}
  .float-logo.is-on{opacity:1;pointer-events:auto}
  .float-logo img{display:block;width:100%;height:100%;animation:float-bob 6s ease-in-out infinite}
  .float-logo.is-on{animation:float-glow 4.5s ease-in-out infinite}
  .float-logo:focus-visible{outline:2px solid #fff;outline-offset:6px;border-radius:50%}
}
@keyframes float-bob{0%,100%{translate:0 0}50%{translate:0 -5px}}
@keyframes float-glow{0%,100%{filter:drop-shadow(0 0 8px rgba(255,255,255,.55)) drop-shadow(0 3px 10px rgba(12,42,72,.3))}50%{filter:drop-shadow(0 0 18px rgba(255,255,255,.9)) drop-shadow(0 3px 10px rgba(12,42,72,.3))}}
/* 25 Nov 2026, gentle motion: kept with Reduce Motion on (small, in place); was a reduced-motion off rule */

/* ---- Mobile bar + chapter menu (8 Nov 2026, tidy pass): phones and tablets had no navigation (the header links and
   the dot nav are desktop only). story-effects.js builds a fixed bar (logo left, round menu button right) and a
   full-screen chapter menu in the dusk colours of the Me chapter; both exist only at 820px and below. The hero's
   own header is hidden there (its "Meet Mayonis" link lives in the menu). ---- */
.m-bar,.m-menu{display:none}
@media(max-width:820px){
  html.has-mbar .hero .header{display:none}
  .m-bar{display:flex;position:fixed;left:0;right:0;top:0;z-index:90;align-items:center;justify-content:space-between;padding:12px 16px;pointer-events:none;background-color:rgba(0,0,0,.008)}   /* 25 Nov 2026: a background too faint to see (2/255). Safari on iOS 26 colours the strip behind the clock from the fixed bar at the top; with no background it sampled once and kept the Intro blue, with this it follows the page colour. */
  .m-bar>*{pointer-events:auto}
  .m-logo{display:block;width:38px;height:38px;filter:drop-shadow(0 0 6px rgba(255,255,255,.5)) drop-shadow(0 2px 8px rgba(12,42,72,.35))}
  .m-logo img{display:block;width:100%;height:100%}
  .m-toggle{display:grid;place-items:center;width:42px;height:42px;padding:0;border:1.5px solid rgba(255,255,255,.9);border-radius:50%;background:rgba(31,90,126,.28);-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);color:#fff;box-shadow:0 2px 12px rgba(12,42,72,.35);cursor:pointer;transition:background .3s ease}
  .m-toggle svg{width:18px;height:18px;filter:drop-shadow(0 1px 2px rgba(12,42,72,.5))}
  .m-toggle .m-x{display:none}
  html.menu-open .m-toggle{background:rgba(255,255,255,.18)}
  html.menu-open .m-toggle .m-burger{display:none}
  html.menu-open .m-toggle .m-x{display:block}
  html.menu-open{overflow:hidden}
  .m-menu{display:flex;position:fixed;inset:0;z-index:80;flex-direction:column;justify-content:center;padding:84px 28px 36px;background:linear-gradient(180deg,rgba(63,86,138,.97),rgba(107,94,152,.97) 55%,rgba(138,106,156,.97));color:#fff;opacity:0;visibility:hidden;transition:opacity .35s ease,visibility 0s .35s}
  html.menu-open .m-menu{opacity:1;visibility:visible;transition:opacity .35s ease}
  .m-menu ol{margin:0;padding:0;list-style:none}
  .m-menu li+li{margin-top:12px}
  .m-menu ol a{display:flex;align-items:baseline;gap:14px;color:#fff;text-decoration:none;opacity:0;translate:0 10px;transition:opacity .4s ease,translate .4s ease}
  html.menu-open .m-menu ol a{opacity:1;translate:0 0;transition-delay:calc(.08s + var(--i,0) * .05s)}
  .m-num{font:400 11px/1 var(--text);letter-spacing:.28em;min-width:2.4em;opacity:.75}
  .m-name{font:italic 500 clamp(30px,8.5vw,42px)/1.05 var(--head-2);text-transform:lowercase}
  .m-menu a[aria-current=true] .m-name{color:#ffe2ae;text-shadow:0 0 20px #fff4d433}
  .m-foot{display:flex;flex-direction:column;gap:12px;margin-top:40px;font-size:13px;line-height:1.4}
  .m-foot a{display:inline-block;align-self:flex-start;color:#fff;text-decoration:none;transition:translate .2s ease}.m-foot a:is(:hover,:focus-visible){translate:3px 0}
  .m-menu a:focus-visible{outline:2px solid #fff;outline-offset:4px}
}
/* 25 Nov 2026, gentle motion: kept with Reduce Motion on (small, in place); was a reduced-motion off rule */

/* ---- Floating "Mayonis Space · Say hello" (9 Nov 2026, Eunice: "floating at all time"). It used to sit in the Intro's
   footer; now it stays at the bottom left on every chapter and every screen size (links to Contact). The Intro's
   "Pause scene" control stays in the Intro footer, on the right. Hidden while the phone menu is open. ---- */
.hero .footer{justify-content:flex-end}
.float-foot{position:fixed;left:clamp(22px,3vw,50px);bottom:20px;z-index:70;margin:0;font:400 clamp(10px,calc(12 * min(100vw / 1440,100vh / 1080)),14px)/1.3 var(--text);color:#fffef8;text-shadow:0 1px 2px rgba(12,30,40,.6),0 1px 8px rgba(12,30,40,.45);transition:opacity .3s ease,visibility .3s}
@media(max-width:820px){.float-foot{left:22px;bottom:16px;font-size:10px}html.menu-open .float-foot{opacity:0;visibility:hidden}}

/* 9 Nov 2026 (Eunice: "snap is needed and can apply on mobile?"): chapter snap on phones. The desktop glide script
   (above 820px) works by taking over wheel events, which touch scrolling never sends, so phones use native CSS scroll
   snap instead: each chapter start is a snap point, a hard flick stops at the next chapter (scroll-snap-stop), and a
   chapter taller than the screen (About, Portfolio, Contact) still scrolls freely inside before snapping on. Kept to
   the same 820px gate as the script so the two never fight (the script's own eased scrollTo would be re-snapped). */
/* 25 Nov 2026 (Zen, video of an iPad held sideways: 'The touch scroll on iPad is off ... It feel okay on iPhone'):
   a sideways iPad is wider than 820px, so it got the desktop glide script, which only hears wheel and trackpad
   events, and no snap; a finger flick then scrolled freely with its momentum (Intro straight to Contact) or stopped
   between chapters. Touch-first screens of any width (primary pointer coarse: phones and iPads) now snap like phones;
   the glide script in story-effects.js is off for them, so the two still never both run. */
@media(max-width:820px),(pointer:coarse){
  html{scroll-snap-type:y mandatory}
  main.hero,#me,#about,#nightfall,#portfolio,#contact{scroll-snap-align:start;scroll-snap-stop:always}
}

/* Controls for the scene clips. */
.scene-toggle{display:grid;place-items:center;width:44px;height:44px;padding:0;border:0;background:none;color:#fff;cursor:pointer}
.scene-toggle[hidden],.scene-toggle .pause-icon,.scene-toggle[data-playing=true] .play-icon{display:none}
.scene-toggle[data-playing=true] .pause-icon{display:block}
.scene-toggle svg{width:17px;height:17px;filter:drop-shadow(0 1px 4px #241b28b3)}
.scene-toggle:focus-visible{outline:2px solid currentColor;outline-offset:-4px;border-radius:4px}
.hero .footer{bottom:7px}

:root{--chapter-kicker:clamp(27px,2.75vw,47px);--chapter-title:clamp(35px,3.45vw,57px)}
[data-heading-scale=shared] .step-kicker{font-size:var(--chapter-kicker)}
[data-heading-scale=shared] .step-title{font-size:var(--chapter-title)}
@media(max-width:820px){
 :root{--chapter-kicker:clamp(24px,6.8vw,34px);--chapter-title:clamp(30px,8.9vw,42px)}
}

/* The chapter links and AhSok tool names share the same speech bubble. */
.dot-label,.ahsok-speech{width:max-content;padding:6px 11px;border-radius:12px;background:#fff3db;color:#3c2b37;font:400 12px/1.25 var(--text);text-align:center;text-shadow:none;box-shadow:0 4px 14px #140b2570;white-space:nowrap;pointer-events:none}
.dot-label::after,.ahsok-speech::after{content:"";position:absolute;right:100%;top:50%;translate:0 -50%;border:5px solid transparent;border-right-color:#fff3db}

/* When the desktop buddy speaks, the menu keeps its accessible link labels. */
.ahsok-nav-speech .dot-nav .dot-label{visibility:hidden}

html:has(.dot-nav a[href="#contact"][aria-current="true"]) .foot-greeting{display:none}
