:root {
  /* Existing global theme */
  --bg: #f7f4ee;
  --bg-soft: #fffaf1;
  --ink: #123847;
  --muted: #61737d;
  --line: rgba(18, 56, 71, 0.12);
  --card: rgba(255, 255, 255, 0.75);
  --card-strong: rgba(255, 255, 255, 0.92);
  --teal: #1f7d78;
  --blue: #123847;
  --gold: #b58b5a;
  --shadow: 0 28px 80px rgba(18, 56, 71, 0.10);
  --radius-xl: 28px;
  --radius-lg: 20px;

  /* Spiral section palettes */
  --education-bg: #D3E1FC;
  --education-soft: #8FABCD;
  --education-accent: #8FABCD;

  --projects-bg: #D9E6CF;
  --projects-soft: #A0BAC1;
  --projects-accent: #A0BAC1;

  --publications-bg: #b8e8e1;
  --publications-soft: #63d8c6;
  --publications-accent: #38897b;

  --aiweb-bg: #ECF9FF;
  --aiweb-soft: #FEE7CD;
  --aiweb-accent: #F9CAA6;

  --experience-bg: #FFF7F1;
  --experience-soft: #FFE4C9;
  --experience-accent: #E88896;

  --skills-bg: #F7EAF1;
  --skills-soft: #C9C2DF;
  --skills-accent: #8F84AA;

  --awards-bg: #FFFAF9;
  --awards-soft: #FFC1CF;
  --awards-accent: #E88896;

  --languages-bg: #D3E1FC;
  --languages-soft: #FDF9D9;
  --languages-accent: #8FABCD;
}

/* =========================
   Spiral section cards
   ========================= */

.spiral-card {
  --card-bg: var(--bg-soft);
  --card-soft: rgba(255, 255, 255, 0.6);
  --card-accent: var(--teal);

  background:
    radial-gradient(circle at 16% 18%, var(--card-soft), transparent 34%),
    radial-gradient(circle at 86% 82%, color-mix(in srgb, var(--card-accent) 18%, transparent), transparent 34%),
    linear-gradient(135deg, var(--card-bg), rgba(255, 255, 255, 0.88));

  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
  color: var(--ink);
  overflow: hidden;
}

.spiral-card .eyebrow,
.spiral-card .section-label {
  color: var(--card-accent);
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.spiral-card h2,
.spiral-card h3 {
  color: var(--ink);
}

.spiral-card p,
.spiral-card li {
  color: var(--muted);
}

.spiral-illustration {
  width: min(280px, 42vw);
  max-height: 320px;
  object-fit: contain;
  filter: drop-shadow(0 14px 22px rgba(18, 56, 71, 0.10));
}



.education-card {
  --card-bg: var(--education-bg);
  --card-soft: var(--education-soft);
  --card-accent: var(--education-accent);
}

.projects-card {
  --card-bg: var(--projects-bg);
  --card-soft: var(--projects-soft);
  --card-accent: var(--projects-accent);
}

.publications-card {
  --card-bg: var(--publications-bg);
  --card-soft: var(--publications-soft);
  --card-accent: var(--publications-accent);
}

.aiweb-card {
  --card-bg: var(--aiweb-bg);
  --card-soft: var(--aiweb-soft);
  --card-accent: var(--aiweb-accent);
}

.experience-card {
  --card-bg: var(--experience-bg);
  --card-soft: var(--experience-soft);
  --card-accent: var(--experience-accent);
}

.skills-card {
  --card-bg: var(--skills-bg);
  --card-soft: var(--skills-soft);
  --card-accent: var(--skills-accent);
}

.awards-card {
  --card-bg: var(--awards-bg);
  --card-soft: var(--awards-soft);
  --card-accent: var(--awards-accent);
}

.languages-card {
  --card-bg: var(--languages-bg);
  --card-soft: var(--languages-soft);
  --card-accent: var(--languages-accent);
}


.spiral-illustration {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 155px;
  padding: 0.25rem 0 0.45rem;
}

.spiral-doodle {
  width: min(185px, 78%);
  max-height: 180px;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 12px 18px rgba(18, 56, 71, 0.08));
}








* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 15% 12%, rgba(59, 140, 125, 0.11), transparent 26rem),
    radial-gradient(circle at 88% 18%, rgba(181, 139, 90, 0.10), transparent 24rem),
    linear-gradient(180deg, var(--bg), #f6f2ea 50%, #f8f7f2);
  line-height: 1.65;
  overflow-x: hidden;
}

body.section-open {
  overflow: hidden;
}

a { color: inherit; text-decoration: none; }
p { margin: 0 0 1rem; }

#path-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
  opacity: 0.42;
  pointer-events: none;
}

.page {
  min-height: 100vh;
  position: relative;
}

.page-landing {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.2rem;
}

.landing-inner {
  width: min(1180px, 100%);
  margin: 0 auto;
  position: relative;
  padding: 1rem 0 5rem;
}

.eyebrow {
  color: var(--teal);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-weight: 760;
  font-size: 0.80rem;
  margin-bottom: 1rem;
}

.main-name {
  margin: 0;
  line-height: 0.92;
  letter-spacing: -0.06em;
  color: var(--blue);
  font-size: clamp(4rem, 12vw, 9rem);
}

.main-name span { display: block; }

.main-subtitle {
  margin: 1.25rem 0 1.5rem;
  color: #6f8088;
  font-weight: 560;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  letter-spacing: -0.03em;
}

.landing-summary {
  width: min(1100px, 100%);
  max-width: 1050px;
  font-size: clamp(1.25rem, 2.1vw, 1.9rem);
  color: #314950;
  line-height: 1.75;
  padding-right: 1rem;
}

.scroll-arrow {
  position: absolute;
  left: 50%;
  bottom: 0.5rem;
  transform: translateX(-50%);
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  color: var(--teal);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 0.76rem;
  animation: arrowFloat 2.4s ease-in-out infinite;
}

.arrow-icon {
  font-size: 2rem;
  line-height: 1;
}

.page-story {
  padding: 3rem 1.2rem 1rem;
}

.story-stage {
  max-width: 1180px;
  margin: 0 auto;
  position: relative;
  min-height: 100vh;
}

.story-layout {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 2rem;
  align-items: start;
  padding-top: 4rem;
}

.story-card-slot {
  position: relative;
  min-height: 380px;
}

.pinned-card-shell {
  position: sticky;
  top: 6rem;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.pinned-card-shell.visible {
  opacity: 1;
  transform: translateY(0);
}

.pinned-card {
  width: 280px;
  border: none;
  background: none;
  padding: 0;
  cursor: pointer;
  perspective: 1600px;
  position: relative;
}

.card-tip {
  position: absolute;
  top: 0.9rem;
  left: 0.9rem;
  z-index: 4;
  padding: 0.42rem 0.64rem;
  border-radius: 999px;
  background: rgba(18, 56, 71, 0.78);
  color: #fff;
  font-size: 0.76rem;
  font-weight: 700;
  box-shadow: 0 8px 20px rgba(18, 56, 71, 0.18);
  animation: pillPulse 2.2s ease-in-out infinite;
}

.pinned-card-inner,
.floating-card {
  position: relative;
  width: 100%;
  aspect-ratio: 5 / 6;
  transform-style: preserve-3d;
  transition: transform 0.65s cubic-bezier(0.3, 0.9, 0.2, 1);
}

.pinned-card.is-flipped .pinned-card-inner,
.floating-card.is-flipped {
  transform: rotateY(180deg);
}

.card-face {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  overflow: hidden;
  border-radius: 22px;
  border: 1px solid rgba(18, 56, 71, 0.12);
  box-shadow: 0 24px 60px rgba(18, 56, 71, 0.13);
  background: white;
}

.card-face img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background: #efefef;
}

.card-back {
  transform: rotateY(180deg);
}

.floating-card-wrap {
  position: absolute;
  left: 50%;
  top: 24vh;
  width: 280px;
  transform: translate(-50%, 0);
  opacity: 0;
  pointer-events: none;
  z-index: 20;
}

.floating-card-wrap.animate-in {
  opacity: 1;
  animation: throwIn 1s cubic-bezier(0.2, 0.95, 0.26, 1.08) forwards;
}

.floating-card-wrap.move-to-corner {
  animation: moveToCorner 1.15s cubic-bezier(0.18, 0.88, 0.22, 1) forwards;
}

.story-copy {
  max-width: 740px;
  padding-top: 0rem;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.85s ease, transform 0.85s ease;
}

.story-copy.visible {
  opacity: 1;
  transform: translateY(0);
}

.story-copy h2,
.hub-title h2,
.section-page-heading h2,
.contact-card h2 {
  line-height: 1.12;
  letter-spacing: -0.04em;
}

.story-copy h2 {
  font-size: clamp(2rem, 4vw, 4rem);
  margin: 0 0 1.1rem;
}

.story-copy p {
  color: #395159;
  font-size: 1.06rem;
}

.story-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 1rem;
}

.story-tags span {
  display: inline-flex;
  padding: 0.45rem 0.68rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255,255,255,0.58);
  color: var(--muted);
  font-size: 0.83rem;
}

.story-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 1.4rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0.76rem 1.08rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-weight: 680;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.button:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(18, 56, 71, 0.10);
}

.button.primary {
  background: var(--ink);
  color: white;
}

.button.secondary {
  background: rgba(255,255,255,0.72);
}

/* =========================
   Page 3 central spiral hub
========================= */

.page-explore {
  min-height: 100vh;
  position: relative;
  padding: 3rem 1.2rem 2rem;
  overflow: hidden;
}

.hub-shell {
  max-width: 1280px;
  min-height: calc(100vh - 5rem);
  margin: 0 auto;
  position: relative;
  transition:
    opacity 0.55s ease,
    transform 0.65s cubic-bezier(0.2, 0.84, 0.22, 1),
    filter 0.55s ease;
}

.hub-shell.leaving {
  opacity: 0;
  transform: scale(0.92) translateY(-18px);
  filter: blur(6px);
}

.hub-shell.returning {
  animation: hubReturn 0.75s cubic-bezier(0.2, 0.9, 0.22, 1) both;
}

.hub-topbar {
  display: flex;
  justify-content: center;
  margin-bottom: 0.6rem;
}

.hub-mode {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: #50616a;
}

.layout-toggle {
  border: none;
  background: none;
  cursor: pointer;
  font-size: 1rem;
  color: #7a878d;
  padding: 0.2rem 0.1rem;
  transition: color 0.2s ease;
}

.layout-toggle.is-active {
  color: var(--ink);
  font-weight: 700;
}

.toolbar-dot {
  color: #94a2a8;
}

.hub-title {
  max-width: 850px;
  margin: 0 auto;
  text-align: center;
  position: relative;
  z-index: 3;
}

.hub-title h2 {
  font-size: clamp(2rem, 4vw, 4.4rem);
  margin: 0 0 0.7rem;
}

.hub-title p:last-child {
  color: var(--muted);
  max-width: 760px;
  margin: 0 auto;
}

.spiral-scene {
  position: relative;
  width: min(1080px, 100%);
  height: 650px;
  margin: 0 auto;
  perspective: 1900px;
  transform-style: preserve-3d;
  overflow: hidden;
  border-radius: 42px;
}

.spiral-scene::before {
  content: "";
  position: absolute;
  inset: 2rem 0 0;
  background-image:
    linear-gradient(rgba(18,56,71,0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(18,56,71,0.055) 1px, transparent 1px);
  background-size: 34px 34px;
  mask-image: radial-gradient(circle at center, black 35%, transparent 76%);
  pointer-events: none;
}

.spiral-track {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
}

.spiral-card {
  position: absolute;
  left: 50%;
  top: 51%;
  width: 230px;
  height: 300px;
  margin-left: -115px;
  margin-top: -150px;
  border: none;
  padding: 0;
  background: none;
  cursor: pointer;
  transform-style: preserve-3d;
  transition:
    transform 0.6s ease,
    opacity 0.45s ease,
    filter 0.45s ease;
}

.spiral-card.active {
  z-index: 80 !important;
}

.spiral-card-shell {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 30px;
  overflow: hidden;
  box-shadow: 0 28px 72px rgba(18,56,71,0.20);
  border: 1px solid rgba(255,255,255,0.20);
}

/* =========================
   Stronger spiral card colours
   ========================= */

.spiral-card-surface {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    radial-gradient(circle at 18% 15%, var(--card-soft) 0%, transparent 42%),
    radial-gradient(circle at 90% 85%, var(--card-accent) 0%, transparent 42%),
    linear-gradient(135deg, var(--card-bg) 0%, var(--card-soft) 55%, var(--card-bg) 100%);
  opacity: 1;
  pointer-events: none;
}

.spiral-card.theme-skills .spiral-card-surface { background: linear-gradient(145deg, #90f3d5, #5cbbe0); }
.spiral-card.theme-education .spiral-card-surface { background: linear-gradient(145deg, #a7c3ff, #8e90ff); }
.spiral-card.theme-projects .spiral-card-surface { background: linear-gradient(145deg, #c6ffb2, #8dc9e8); }
.spiral-card.theme-publications .spiral-card-surface { background: linear-gradient(145deg, #9297ff, #483cff); }
.spiral-card.theme-languages .spiral-card-surface { background: linear-gradient(145deg, #ffd9e8, #fbbf72); }
.spiral-card.theme-hobbies .spiral-card-surface { background: linear-gradient(145deg, #78ecf4, #77c1ff); }

.spiral-card-content {
  position: absolute;
  inset: 0;
  padding: 0.9rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.card-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  color: rgba(18,56,71,0.72);
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 700;
}

.card-dotmenu {
  font-size: 1rem;
  letter-spacing: 0;
}

.spiral-illustration {
  position: relative;
  flex: 1;
  margin: 0.55rem 0 0.35rem;
  border-radius: 21px;
  overflow: hidden;
  background: rgba(255,255,255,0.25);
}

.spiral-illustration img.spiral-danqi {
  position: absolute;
  left: 0.16rem;
  bottom: 0;
  width: 68%;
  height: 85%;
  object-fit: contain;
  filter: drop-shadow(0 10px 16px rgba(18,56,71,0.15));
}

.spiral-cat {
  position: absolute;
  right: 0.65rem;
  bottom: 0.5rem;
  font-size: 2rem;
  filter: drop-shadow(0 6px 12px rgba(18,56,71,0.12));
}

.spiral-prop {
  position: absolute;
  right: 0.7rem;
  top: 0.65rem;
  padding: 0.36rem 0.52rem;
  border-radius: 999px;
  background: rgba(255,255,255,0.55);
  color: #123847;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.spiral-card-caption {
  padding: 0.78rem 0.15rem 0.08rem;
  color: #0e3340;
}

.spiral-card-caption strong {
  display: block;
  font-size: 1.14rem;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 0.35rem;
}

.spiral-card-caption span {
  display: block;
  font-size: 0.84rem;
  line-height: 1.35;
  color: rgba(14,51,64,0.82);
}

.spiral-center-label {
  position: absolute;
  left: 50%;
  top: 53%;
  transform: translate(-50%, -50%);
  z-index: 1;
  text-align: center;
  pointer-events: none;
  color: rgba(18,56,71,0.22);
}

.spiral-center-label span {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 800;
}

.spiral-center-label strong {
  display: block;
  font-size: clamp(2rem, 5vw, 5rem);
  letter-spacing: -0.06em;
  line-height: 0.9;
}

/* =========================
   New section page overlay
========================= */

.section-page {
  position: fixed;
  inset: 0;
  z-index: 100;
  background:
    radial-gradient(circle at 16% 10%, rgba(31,125,120,0.14), transparent 24rem),
    radial-gradient(circle at 90% 24%, rgba(181,139,90,0.12), transparent 24rem),
    linear-gradient(180deg, #f8f6ef, #fbfaf5);
  opacity: 0;
  pointer-events: none;
  transform: translateY(28px) scale(1.02);
  filter: blur(3px);
  transition:
    opacity 0.6s ease,
    transform 0.7s cubic-bezier(0.19, 0.9, 0.22, 1),
    filter 0.6s ease;
  overflow-y: auto;
}

.section-page.open {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0) scale(1);
  filter: blur(0);
}

.section-page.closing {
  opacity: 0;
  transform: translateY(18px) scale(0.985);
  filter: blur(4px);
}

.section-close {
  position: fixed;
  right: 2rem;
  top: 1.6rem;
  z-index: 130;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 1px solid rgba(18,56,71,0.12);
  background: rgba(255,255,255,0.82);
  color: #66767d;
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 16px 40px rgba(18,56,71,0.10);
  transition: transform 0.2s ease, background 0.2s ease;
}

.section-close:hover {
  transform: scale(1.06) rotate(8deg);
  background: white;
}

.section-page-inner {
  width: min(1180px, calc(100% - 2.4rem));
  margin: 0 auto;
  padding: 6rem 0 4rem;
}

.section-page-heading {
  max-width: 920px;
  margin-bottom: 2rem;
  opacity: 0;
  transform: translateY(38px);
}

.section-page.open .section-page-heading {
  animation: contentRise 0.75s 0.1s cubic-bezier(0.2,0.9,0.2,1) forwards;
}

.section-page-heading h2 {
  font-size: clamp(3rem, 7vw, 7rem);
  line-height: 0.95;
  margin: 0 0 1rem;
}

.section-page-heading p:last-child {
  color: #50646d;
  font-size: clamp(1.05rem, 1.5vw, 1.28rem);
  max-width: 800px;
}

.section-content-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.content-card {
  min-height: 310px;
  border-radius: 34px;
  padding: 1.45rem;
  border: 1px solid rgba(18,56,71,0.10);
  background: rgba(255,255,255,0.76);
  box-shadow: 0 26px 65px rgba(18,56,71,0.09);
  backdrop-filter: blur(18px);
  opacity: 0;
  transform: translateY(56px);
}

.section-page.open .content-card {
  animation: cardRise 0.78s cubic-bezier(0.2,0.9,0.2,1) forwards;
}

.content-card:nth-child(1) { animation-delay: 0.16s; }
.content-card:nth-child(2) { animation-delay: 0.24s; }
.content-card:nth-child(3) { animation-delay: 0.32s; }
.content-card:nth-child(4) { animation-delay: 0.40s; }
.content-card:nth-child(5) { animation-delay: 0.48s; }
.content-card:nth-child(6) { animation-delay: 0.56s; }

.content-card-kicker {
  color: var(--gold);
  font-weight: 800;
  font-size: 0.86rem;
  margin-bottom: 1rem;
}

.content-card h3 {
  margin: 0 0 0.85rem;
  font-size: clamp(1.35rem, 2vw, 2rem);
  line-height: 1.12;
  letter-spacing: -0.035em;
}

.content-card p {
  color: #40575e;
  font-size: 1rem;
}

.content-card ul {
  margin: 1rem 0 0;
  padding-left: 1.1rem;
  color: #40575e;
}

.content-card li {
  margin: 0.55rem 0;
}

.content-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 1rem;
}

.content-tags span {
  display: inline-flex;
  padding: 0.38rem 0.58rem;
  border-radius: 999px;
  background: rgba(31,125,120,0.10);
  color: #1b625f;
  font-weight: 650;
  font-size: 0.76rem;
}

/* Contact */
.section {
  max-width: 1180px;
  margin: 0 auto;
  padding: 6rem 1.2rem;
}

.contact-section {
  padding-bottom: 4rem;
}

.contact-card {
  max-width: 900px;
  margin: 0 auto;
  padding: 1.65rem;
  text-align: center;
  background: var(--card-strong);
  border: 1px solid rgba(18, 56, 71, 0.12);
  box-shadow: 0 28px 80px rgba(18, 56, 71, 0.10);
  backdrop-filter: blur(18px);
  border-radius: 28px;
}

.contact-card h2 {
  font-size: clamp(2rem, 4vw, 3.5rem);
  margin: 0 0 1rem;
}

.contact-card p {
  max-width: 690px;
  margin-left: auto;
  margin-right: auto;
  color: #40575e;
}

.contact-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  margin-top: 1.8rem;
}

.contact-links a {
  padding: 0.72rem 0.95rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.72);
  font-weight: 680;
  transition: transform 0.2s ease, background 0.2s ease;
}

.contact-links a:hover {
  transform: translateY(-2px);
  background: white;
}

.small-note {
  font-size: 0.82rem;
  margin-top: 1rem;
  color: var(--muted) !important;
}

.site-footer {
  text-align: center;
  padding: 2rem 1rem;
  color: var(--muted);
  border-top: 1px solid rgba(18, 56, 71, 0.08);
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@keyframes arrowFloat {
  0%, 100% { transform: translateX(-50%) translateY(0); opacity: 0.92; }
  50% { transform: translateX(-50%) translateY(8px); opacity: 1; }
}

@keyframes pillPulse {
  0%, 100% { transform: translateY(0); opacity: 0.95; }
  50% { transform: translateY(-2px); opacity: 1; }
}

@keyframes throwIn {
  0% { transform: translate(-50%, 220px) scale(0.65) rotate(-18deg); opacity: 0; }
  55% { transform: translate(-50%, 0) scale(1.04) rotate(8deg); opacity: 1; }
  100% { transform: translate(-50%, 0) scale(1) rotate(0deg); opacity: 1; }
}

@keyframes moveToCorner {
  0% { left: 50%; top: 24vh; width: 280px; transform: translate(-50%, 0) scale(1); opacity: 1; }
  100% { left: 0; top: 4rem; width: 280px; transform: translate(0, 0) scale(1); opacity: 0; }
}

@keyframes hubReturn {
  from { opacity: 0; transform: scale(0.94) translateY(18px); filter: blur(7px); }
  to { opacity: 1; transform: scale(1) translateY(0); filter: blur(0); }
}

@keyframes contentRise {
  from { opacity: 0; transform: translateY(38px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes cardRise {
  from { opacity: 0; transform: translateY(56px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (max-width: 980px) {
  .story-layout {
    grid-template-columns: 1fr;
  }

  .story-card-slot {
    min-height: auto;
  }

  .pinned-card-shell {
    position: relative;
    top: auto;
    width: 280px;
    margin-bottom: 1rem;
  }

  .story-copy {
    padding-top: 0.5rem;
  }

  .section-content-grid {
    grid-template-columns: 1fr 1fr;
  }

  .spiral-card {
    width: 190px;
    height: 252px;
    margin-left: -95px;
    margin-top: -126px;
  }

  .spiral-scene {
    height: 610px;
  }
}

@media (max-width: 680px) {
  .landing-summary {
    font-size: 1.1rem;
    line-height: 1.8;
  }

  .main-subtitle {
    font-size: 1.32rem;
  }

  .floating-card-wrap,
  .pinned-card,
  .pinned-card-shell {
    width: min(76vw, 280px);
  }

  .page-story {
    padding-top: 2rem;
  }

  .page-explore {
    padding: 2.2rem 0.8rem 1rem;
  }

  .hub-title h2 {
    font-size: 2.35rem;
  }

  .spiral-scene {
    height: 560px;
    border-radius: 28px;
  }

  .spiral-card {
    width: 158px;
    height: 216px;
    margin-left: -79px;
    margin-top: -108px;
  }

  .spiral-cat {
    font-size: 1.45rem;
  }

  .spiral-card-caption strong {
    font-size: 0.94rem;
  }

  .spiral-card-caption span {
    font-size: 0.7rem;
  }

  .section-close {
    right: 1rem;
    top: 1rem;
    width: 48px;
    height: 48px;
  }

  .section-page-inner {
    width: min(100% - 1.4rem, 1180px);
    padding-top: 5.2rem;
  }

  .section-page-heading h2 {
    font-size: 3rem;
  }

  .section-content-grid {
    grid-template-columns: 1fr;
  }

  .content-card {
    min-height: auto;
  }
}


/* =========================
   v7 refinements
   - Central spiral only
   - Faster/smoother rotation
   - Back buttons instead of scroll-return
========================= */

.page-back {
  position: absolute;
  left: 1.35rem;
  top: 1.35rem;
  z-index: 90;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 42px;
  padding: 0.55rem 0.85rem;
  border-radius: 999px;
  border: 1px solid rgba(18, 56, 71, 0.12);
  background: rgba(255, 255, 255, 0.78);
  color: var(--ink);
  font-weight: 760;
  cursor: pointer;
  backdrop-filter: blur(16px);
  box-shadow: 0 12px 32px rgba(18, 56, 71, 0.08);
  transition: transform 0.2s ease, background 0.2s ease, opacity 0.2s ease;
}

.page-back:hover {
  transform: translateX(-2px);
  background: rgba(255, 255, 255, 0.96);
}

.page-explore {
  height: 100vh;
  min-height: 100vh;
  padding: 0 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hub-shell {
  width: min(1280px, 100%);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hub-topbar {
  position: absolute;
  top: 1.15rem;
  left: 0;
  right: 0;
  z-index: 8;
  margin: 0;
}

.hub-title {
  display: none !important;
}

.spiral-scene {
  width: min(1180px, 100%);
  height: min(82vh, 760px);
  margin: 0 auto;
  border-radius: 42px;
}

.spiral-track {
  height: 100%;
}

.spiral-card {
  will-change: transform, opacity;
  transition: opacity 0.18s ease;
}

.spiral-card-shell {
  will-change: transform;
}

.spiral-card.active .spiral-card-shell {
  outline: 2px solid rgba(18, 56, 71, 0.25);
  outline-offset: 2px;
}

.spiral-center-label {
  opacity: 0.82;
}

.spiral-center-label strong {
  font-size: clamp(2.8rem, 7vw, 7.5rem);
}

.section-page {
  z-index: 200;
}

.section-close {
  z-index: 240;
}

body.nav-locked {
  overscroll-behavior: none;
}

@media (max-width: 680px) {
  .page-back {
    left: 0.85rem;
    top: 0.85rem;
    min-height: 38px;
    padding: 0.48rem 0.7rem;
    font-size: 0.9rem;
  }

  .page-explore {
    padding: 0 0.75rem;
  }

  .hub-topbar {
    top: 0.9rem;
  }

  .spiral-scene {
    height: 78vh;
    border-radius: 28px;
  }
}


/* =========================
   v8 fixes
   - Remove Profile Hub watermark
   - Remove grid/web background inside spiral scene
   - Keep the spiral itself as the only focus
   - Fix first-entry rotation smoothness
========================= */

.spiral-center-label {
  display: none !important;
}

.spiral-scene::before {
  display: none !important;
}

.spiral-scene {
  background: transparent !important;
  overflow: visible;
}

.spiral-card {
  will-change: transform, opacity;
  backface-visibility: hidden;
  transform-style: preserve-3d;
}

.spiral-card-shell {
  will-change: transform;
  transform: translateZ(0);
}

.hub-shell {
  transform: translateZ(0);
}


/* =========================
   v9 refinements
   - Diagonal landing name
   - Right-edge Enter / Explore controls
   - Paper-tear transition from landing to About
   - About image clean flip indicator
========================= */

.page-landing {
  overflow: hidden;
}

.landing-inner {
  min-height: calc(100vh - 4rem);
  padding: 3.5rem 0 3rem;
}

.main-name {
  position: absolute;
  inset: 0;
  pointer-events: none;
  font-size: clamp(4.2rem, 12vw, 11rem);
  z-index: 1;
}

.main-name span:first-child {
  position: absolute;
  left: 0;
  top: 12vh;
}

.main-name span:last-child {
  position: absolute;
  right: 0;
  bottom: 7vh;
  text-align: right;
}

.main-subtitle {
  position: relative;
  z-index: 2;
  max-width: 850px;
  margin-top: 31vh;
  margin-bottom: 1.35rem;
}

.landing-summary {
  position: relative;
  z-index: 2;
  max-width: 880px;
  font-size: clamp(1.08rem, 1.75vw, 1.48rem);
  line-height: 1.75;
}

.edge-enter {
  position: absolute;
  right: -0.15rem;
  top: 50%;
  z-index: 15;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.75rem 0.9rem 0.75rem 1.05rem;
  border-radius: 999px 0 0 999px;
  border: 1px solid rgba(18,56,71,0.12);
  border-right: none;
  background: rgba(255,255,255,0.78);
  color: var(--teal);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  font-weight: 850;
  box-shadow: 0 18px 45px rgba(18,56,71,0.10);
  backdrop-filter: blur(18px);
  transition: transform 0.22s ease, background 0.22s ease;
}

.edge-enter:hover {
  transform: translateY(-50%) translateX(-4px);
  background: rgba(255,255,255,0.96);
}

.edge-arrow {
  font-size: 1.15rem;
  line-height: 1;
  letter-spacing: 0;
  animation: edgeArrowPulse 1.6s ease-in-out infinite;
}

.edge-explore {
  position: fixed;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
}

.edge-explore:hover {
  transform: translateY(-50%) translateX(-4px);
}

.story-back {
  left: auto !important;
  right: 1.35rem;
}

.card-tip {
  display: none !important;
}

.flip-rotate-indicator {
  width: 42px;
  height: 42px;
  margin: 1rem auto 0;
  border-radius: 50%;
  border: 1px solid rgba(18,56,71,0.12);
  background: rgba(255,255,255,0.74);
  color: var(--teal);
  display: grid;
  place-items: center;
  box-shadow: 0 14px 34px rgba(18,56,71,0.08);
  pointer-events: auto;
  cursor: pointer;
  user-select: none;
}

.flip-rotate-indicator span {
  display: block;
  font-size: 1.75rem;
  line-height: 1;
  animation: none !important;
  transform: none !important;
}

.tear-transition {
  position: fixed;
  inset: 0;
  z-index: 999;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
}

.tear-transition.active {
  opacity: 1;
  visibility: visible;
}

.tear-panel {
  position: absolute;
  left: 0;
  width: 0;
  height: 50%;
  background:
    radial-gradient(circle at 20% 10%, rgba(31,125,120,0.12), transparent 24rem),
    linear-gradient(180deg, #f8f5ed, #fffdf7);
  box-shadow: 0 0 40px rgba(18,56,71,0.06);
}

.tear-panel-top {
  top: 0;
  clip-path: polygon(
    0 0, 0 100%,
    8% 94%, 16% 100%, 24% 93%, 32% 100%,
    40% 94%, 48% 100%, 56% 92%, 64% 100%,
    72% 94%, 80% 100%, 88% 93%, 100% 100%,
    100% 0
  );
}

.tear-panel-bottom {
  bottom: 0;
  clip-path: polygon(
    0 0,
    8% 6%, 16% 0, 24% 7%, 32% 0,
    40% 6%, 48% 0, 56% 8%, 64% 0,
    72% 6%, 80% 0, 88% 7%, 100% 0,
    100% 100%, 0 100%
  );
}

.tear-line {
  position: absolute;
  top: 50%;
  left: -8vw;
  width: 16vw;
  height: 4px;
  transform: translateY(-50%);
  background: linear-gradient(90deg, transparent, rgba(18,56,71,0.38), transparent);
  filter: blur(0.2px);
  opacity: 0;
}

.tear-transition.active .tear-panel {
  animation: tearReveal 0.92s cubic-bezier(0.72,0.01,0.24,1) forwards;
}

.tear-transition.active .tear-panel-top {
  animation-name: tearRevealTop;
}

.tear-transition.active .tear-panel-bottom {
  animation-name: tearRevealBottom;
}

.tear-transition.active .tear-line {
  animation: tearLineMove 0.92s cubic-bezier(0.72,0.01,0.24,1) forwards;
}

@keyframes tearRevealTop {
  0% {
    width: 0;
    transform: translateY(0) rotate(0deg);
  }
  55% {
    width: 100%;
    transform: translateY(-8px) rotate(-0.3deg);
  }
  100% {
    width: 100%;
    transform: translateY(-105%) rotate(-1.6deg);
  }
}

@keyframes tearRevealBottom {
  0% {
    width: 0;
    transform: translateY(0) rotate(0deg);
  }
  55% {
    width: 100%;
    transform: translateY(8px) rotate(0.3deg);
  }
  100% {
    width: 100%;
    transform: translateY(105%) rotate(1.6deg);
  }
}

@keyframes tearLineMove {
  0% {
    left: -10vw;
    opacity: 0;
  }
  12% {
    opacity: 1;
  }
  68% {
    left: 100vw;
    opacity: 1;
  }
  100% {
    left: 108vw;
    opacity: 0;
  }
}

@keyframes edgeArrowPulse {
  0%, 100% { transform: translateX(0); opacity: 0.82; }
  50% { transform: translateX(5px); opacity: 1; }
}

@keyframes rotateHint {
  to { transform: rotate(360deg); }
}

@media (max-width: 680px) {
  .main-name {
    font-size: clamp(4.2rem, 20vw, 6.8rem);
  }

  .main-name span:first-child {
    top: 13vh;
  }

  .main-name span:last-child {
    bottom: 13vh;
  }

  .main-subtitle {
    margin-top: 34vh;
    font-size: 1.18rem;
  }

  .landing-summary {
    font-size: 0.98rem;
    line-height: 1.65;
    max-width: 72vw;
  }

  .edge-enter {
    right: -0.2rem;
    padding: 0.65rem 0.72rem 0.65rem 0.86rem;
    font-size: 0.68rem;
  }

  .story-back {
    right: 0.85rem;
  }

  .flip-rotate-indicator {
    width: 50px;
    height: 50px;
  }
}


/* =========================
   v10 landing refinement
   - Higher top label
   - Wider summary line
   - Two-row perforation guide
   - Tear transition follows guide line
========================= */

:root {
  --tear-y: 56%;
}

.landing-inner {
  width: min(100vw - 1.4rem, 1680px);
  min-height: calc(100vh - 2rem);
  padding: 1.1rem 0 2.2rem;
}

.page-landing .eyebrow {
  position: absolute;
  top: 0.25rem;
  left: 0;
  z-index: 5;
  margin: 0;
}

.main-name span:first-child {
  top: 9.2vh;
}

.main-name span:last-child {
  bottom: 4.8vh;
}

.main-subtitle {
  margin-top: 33vh;
  margin-bottom: 1.05rem;
}

.tear-guide {
  position: relative;
  z-index: 3;
  width: calc(100vw - 2.6rem);
  margin: 0.7rem 0 0.9rem;
  display: grid;
  gap: 0.42rem;
}

.tear-guide span {
  display: block;
  width: 100%;
  height: 2px;
  background-image: linear-gradient(90deg, rgba(31,125,120,0.45) 0 10px, transparent 10px 22px);
  background-size: 22px 2px;
  opacity: 0.9;
}

.landing-summary {
  max-width: none !important;
  width: calc(100vw - 2.6rem) !important;
  padding-right: 0 !important;
  font-size: clamp(1.14rem, 1.65vw, 1.58rem);
  line-height: 1.75;
}

/* Override v9 tear animation: now it opens along the dotted perforation guide */
.tear-transition {
  --tear-y-local: var(--tear-y);
}

.tear-panel {
  left: 0;
  width: 100%;
  background:
    radial-gradient(circle at 20% 10%, rgba(31,125,120,0.12), transparent 24rem),
    linear-gradient(180deg, #f8f5ed, #fffdf7);
  box-shadow: 0 0 40px rgba(18,56,71,0.06);
}

.tear-panel-top {
  top: 0;
  height: var(--tear-y-local);
  clip-path: none;
}

.tear-panel-bottom {
  top: var(--tear-y-local);
  bottom: auto;
  height: calc(100% - var(--tear-y-local));
  clip-path: none;
}

.tear-panel-top::after,
.tear-panel-bottom::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background-image: linear-gradient(90deg, rgba(18,56,71,0.42) 0 10px, transparent 10px 22px);
  background-size: 22px 2px;
  opacity: 0.95;
}

.tear-panel-top::after {
  bottom: 0.16rem;
}

.tear-panel-bottom::before {
  top: 0.16rem;
}

.tear-line {
  top: var(--tear-y-local);
  left: -10vw;
  width: 14vw;
  height: 56px;
  transform: translateY(-50%);
  background:
    linear-gradient(90deg, transparent, rgba(31,125,120,0.70), transparent),
    repeating-linear-gradient(
      90deg,
      rgba(18,56,71,0.44) 0 10px,
      transparent 10px 22px
    );
  background-size: 100% 3px, 22px 2px;
  background-repeat: no-repeat, repeat-x;
  background-position: center center, center center;
  filter: none;
  opacity: 0;
}

.tear-transition.active .tear-panel-top {
  animation: perforationTop 1.02s cubic-bezier(0.78,0.01,0.24,1) forwards;
}

.tear-transition.active .tear-panel-bottom {
  animation: perforationBottom 1.02s cubic-bezier(0.78,0.01,0.24,1) forwards;
}

.tear-transition.active .tear-line {
  animation: perforationLine 1.02s cubic-bezier(0.78,0.01,0.24,1) forwards;
}

@keyframes perforationTop {
  0% {
    clip-path: inset(0 100% 0 0);
    transform: translateY(0);
  }
  48% {
    clip-path: inset(0 0 0 0);
    transform: translateY(0);
  }
  100% {
    clip-path: inset(0 0 0 0);
    transform: translateY(-110%);
  }
}

@keyframes perforationBottom {
  0% {
    clip-path: inset(0 100% 0 0);
    transform: translateY(0);
  }
  48% {
    clip-path: inset(0 0 0 0);
    transform: translateY(0);
  }
  100% {
    clip-path: inset(0 0 0 0);
    transform: translateY(110%);
  }
}

@keyframes perforationLine {
  0% {
    left: -12vw;
    opacity: 0;
  }
  10% {
    opacity: 1;
  }
  62% {
    left: 100vw;
    opacity: 1;
  }
  100% {
    left: 112vw;
    opacity: 0;
  }
}

@media (max-width: 680px) {
  .landing-inner {
    width: calc(100vw - 1.2rem);
    padding-top: 1rem;
  }

  .page-landing .eyebrow {
    top: 0.15rem;
    font-size: 0.62rem;
    letter-spacing: 0.12em;
  }

  .main-name span:first-child {
    top: 11vh;
  }

  .main-name span:last-child {
    bottom: 11vh;
  }

  .main-subtitle {
    margin-top: 34vh;
  }

  .tear-guide {
    width: calc(100vw - 1.8rem);
    gap: 0.34rem;
  }

  .landing-summary {
    width: calc(100vw - 1.8rem) !important;
    max-width: none !important;
    font-size: 0.98rem;
    line-height: 1.65;
  }
}


/* =========================
   v11 transition refinement
   Reference-inspired zipper/perforation tear
   - controlled horizontal tear
   - black slit opens left-to-right
   - puller moves along the guide
   - top/bottom paper separate only after the slit is opened
========================= */

.zip-transition {
  --tear-y-local: var(--tear-y);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 999;
  overflow: hidden;
}

.zip-transition.active {
  opacity: 1;
  visibility: visible;
}

.zip-transition .tear-panel,
.zip-transition .tear-line {
  display: none !important;
}

.zip-paper {
  position: absolute;
  left: 0;
  width: 100%;
  background:
    radial-gradient(circle at 18% 16%, rgba(31,125,120,0.10), transparent 24rem),
    radial-gradient(circle at 86% 14%, rgba(181,139,90,0.09), transparent 23rem),
    linear-gradient(180deg, rgba(248,245,237,0.98), rgba(255,253,247,0.98));
  box-shadow: 0 0 45px rgba(18,56,71,0.05);
  will-change: transform;
}

.zip-paper-top {
  top: 0;
  height: var(--tear-y-local);
}

.zip-paper-bottom {
  top: var(--tear-y-local);
  height: calc(100% - var(--tear-y-local));
}

.zip-guide {
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background-image: linear-gradient(90deg, rgba(18,56,71,0.48) 0 9px, transparent 9px 22px);
  background-size: 22px 2px;
  opacity: 0;
  z-index: 4;
}

.zip-guide-top {
  top: calc(var(--tear-y-local) - 8px);
}

.zip-guide-bottom {
  top: calc(var(--tear-y-local) + 8px);
}

.zip-opening {
  position: absolute;
  left: 0;
  top: calc(var(--tear-y-local) - 13px);
  width: 0;
  height: 26px;
  background:
    linear-gradient(180deg, transparent 0 6px, rgba(12,18,21,0.94) 6px 20px, transparent 20px 26px);
  z-index: 6;
  box-shadow:
    0 6px 18px rgba(18,56,71,0.18),
    inset 0 1px 0 rgba(255,255,255,0.12);
  transform-origin: left center;
  will-change: width;
}

.zip-puller {
  position: absolute;
  left: -64px;
  top: calc(var(--tear-y-local) - 52px);
  width: 92px;
  height: 92px;
  z-index: 9;
  opacity: 0;
  will-change: transform, opacity;
}

.zip-puller-tab {
  position: absolute;
  left: 22px;
  top: 4px;
  width: 42px;
  height: 68px;
  border-radius: 14px;
  background:
    linear-gradient(145deg, #cfb58a, #ead8b8 42%, #b99562);
  transform: rotate(38deg);
  box-shadow: 0 14px 28px rgba(18,56,71,0.22);
}

.zip-puller-tab::before {
  content: "";
  position: absolute;
  left: 11px;
  top: 9px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid rgba(18,56,71,0.34);
  background: rgba(255,255,255,0.28);
}

.zip-puller-head {
  position: absolute;
  left: 6px;
  top: 42px;
  width: 58px;
  height: 26px;
  border-radius: 0 10px 10px 0;
  background: #0e1518;
  box-shadow: 0 10px 24px rgba(18,56,71,0.26);
}

.zip-puller-head::after {
  content: "";
  position: absolute;
  right: -13px;
  top: 5px;
  width: 20px;
  height: 16px;
  background: #0e1518;
  clip-path: polygon(0 0, 100% 50%, 0 100%);
}

.zip-transition.active .zip-guide {
  animation: zipGuideIn 1.18s cubic-bezier(0.76,0.02,0.22,1) forwards;
}

.zip-transition.active .zip-opening {
  animation: zipOpening 1.18s cubic-bezier(0.76,0.02,0.22,1) forwards;
}

.zip-transition.active .zip-puller {
  animation: zipPullerMove 1.18s cubic-bezier(0.76,0.02,0.22,1) forwards;
}

.zip-transition.active .zip-paper-top {
  animation: zipPaperTop 1.28s cubic-bezier(0.76,0.02,0.22,1) forwards;
}

.zip-transition.active .zip-paper-bottom {
  animation: zipPaperBottom 1.28s cubic-bezier(0.76,0.02,0.22,1) forwards;
}

@keyframes zipGuideIn {
  0% { opacity: 0; }
  8% { opacity: 0.9; }
  72% { opacity: 0.9; }
  100% { opacity: 0; }
}

@keyframes zipOpening {
  0% {
    width: 0;
    opacity: 0;
  }
  8% {
    opacity: 1;
  }
  72% {
    width: 100vw;
    opacity: 1;
  }
  100% {
    width: 100vw;
    opacity: 0;
  }
}

@keyframes zipPullerMove {
  0% {
    transform: translateX(0) rotate(-2deg);
    opacity: 0;
  }
  7% {
    opacity: 1;
  }
  72% {
    transform: translateX(calc(100vw + 88px)) rotate(2deg);
    opacity: 1;
  }
  100% {
    transform: translateX(calc(100vw + 120px)) rotate(3deg);
    opacity: 0;
  }
}

@keyframes zipPaperTop {
  0% {
    transform: translateY(0) rotate(0deg);
  }
  70% {
    transform: translateY(0) rotate(0deg);
  }
  100% {
    transform: translateY(-105%) rotate(-0.55deg);
  }
}

@keyframes zipPaperBottom {
  0% {
    transform: translateY(0) rotate(0deg);
  }
  70% {
    transform: translateY(0) rotate(0deg);
  }
  100% {
    transform: translateY(105%) rotate(0.55deg);
  }
}

@media (max-width: 680px) {
  .zip-puller {
    width: 76px;
    height: 76px;
    top: calc(var(--tear-y-local) - 43px);
  }

  .zip-puller-tab {
    width: 34px;
    height: 54px;
  }

  .zip-puller-head {
    width: 48px;
    height: 22px;
    top: 36px;
  }
}


/* =========================
   v12 refinement
   - Replace dense ugly guide with two light sparse dashed divider lines
   - Leave a cleaner gap between subtitle and summary
   - Transition now tears the subtitle block and summary block apart
========================= */

:root {
  --tear-y: 56%;
  --tear-guide-gap: 20px;
  --tear-dash-color: rgba(31, 125, 120, 0.28);
  --tear-dash-segment: 11px;
  --tear-dash-step: 34px;
}

.tear-guide {
  position: relative;
  z-index: 3;
  width: calc(100vw - 2.6rem);
  margin: 0.95rem 0 1rem;
  display: grid;
  gap: var(--tear-guide-gap);
}

.tear-guide-line {
  display: block;
  width: 100%;
  height: 2px;
  background-image: linear-gradient(
    90deg,
    var(--tear-dash-color) 0 var(--tear-dash-segment),
    transparent var(--tear-dash-segment) var(--tear-dash-step)
  );
  background-size: var(--tear-dash-step) 2px;
  background-repeat: repeat-x;
  opacity: 1;
}

.main-subtitle {
  margin-bottom: 0.95rem;
}

.landing-summary {
  margin-top: 0.1rem;
  max-width: none !important;
  width: calc(100vw - 2.6rem) !important;
  padding-right: 0 !important;
}

/* v12 overrides for zipper transition alignment and line style */
.zip-transition {
  --tear-y-local: var(--tear-y);
}

.zip-guide {
  width: 100%;
  height: 2px;
  background-image: linear-gradient(
    90deg,
    rgba(18,56,71,0.22) 0 11px,
    transparent 11px 34px
  );
  background-size: 34px 2px;
  background-repeat: repeat-x;
  opacity: 0;
  z-index: 5;
}

.zip-guide-top {
  top: calc(var(--tear-y-local) - (var(--tear-guide-gap) / 2));
}

.zip-guide-bottom {
  top: calc(var(--tear-y-local) + (var(--tear-guide-gap) / 2));
}

.zip-opening {
  position: absolute;
  left: 0;
  top: calc(var(--tear-y-local) - 10px);
  width: 0;
  height: 20px;
  background:
    linear-gradient(180deg,
      rgba(0,0,0,0) 0 2px,
      rgba(15, 21, 24, 0.92) 2px 18px,
      rgba(0,0,0,0) 18px 20px);
  z-index: 6;
  box-shadow:
    0 8px 18px rgba(18,56,71,0.16),
    inset 0 1px 0 rgba(255,255,255,0.09);
  transform-origin: left center;
  will-change: width;
}

.zip-puller {
  top: calc(var(--tear-y-local) - 47px);
}

/* Make the top and bottom papers separate more gently,
   so it feels like the intro is being torn apart rather than exploding */
@keyframes zipPaperTop {
  0% {
    transform: translateY(0) rotate(0deg);
  }
  70% {
    transform: translateY(0) rotate(0deg);
  }
  100% {
    transform: translateY(calc(-100% - 10px)) rotate(-0.25deg);
  }
}

@keyframes zipPaperBottom {
  0% {
    transform: translateY(0) rotate(0deg);
  }
  70% {
    transform: translateY(0) rotate(0deg);
  }
  100% {
    transform: translateY(calc(100% + 10px)) rotate(0.25deg);
  }
}

@media (max-width: 680px) {
  :root {
    --tear-guide-gap: 16px;
    --tear-dash-segment: 9px;
    --tear-dash-step: 28px;
  }

  .tear-guide {
    width: calc(100vw - 1.8rem);
    margin: 0.8rem 0 0.9rem;
  }

  .landing-summary {
    width: calc(100vw - 1.8rem) !important;
  }

  .zip-guide {
    background-image: linear-gradient(
      90deg,
      rgba(18,56,71,0.2) 0 9px,
      transparent 9px 28px
    );
    background-size: 28px 2px;
  }
}


/* =========================
   v13
   - One divider above subtitle and one below summary
   - Tear happens only in the intro strip region
   - Torn strip becomes black and morphs into the portrait flip card
========================= */

:root {
  --strip-top: 40%;
  --strip-bottom: 66%;
  --strip-center: 53%;
}

.tear-guide-top-wrap,
.tear-guide-bottom-wrap {
  width: calc(100vw - 2.6rem);
  margin: 0;
  display: block;
}

.tear-guide-top-wrap {
  margin-top: 2.1rem;
  margin-bottom: 1rem;
}

.tear-guide-bottom-wrap {
  margin-top: 1rem;
}

.tear-guide {
  gap: 0;
}

.tear-guide-line {
  height: 1px;
  background-image: linear-gradient(
    90deg,
    rgba(31, 125, 120, 0.22) 0 12px,
    transparent 12px 38px
  );
  background-size: 38px 1px;
  background-repeat: repeat-x;
  opacity: 1;
}

.main-subtitle {
  margin-top: 0;
  margin-bottom: 0.9rem;
  position: relative;
  z-index: 2;
}

.landing-summary {
  margin-bottom: 0;
  position: relative;
  z-index: 2;
}

/* New strip transition */
.strip-transition {
  position: fixed;
  inset: 0;
  z-index: 999;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
}

.strip-transition.active {
  opacity: 1;
  visibility: visible;
}

.strip-transition-overlay {
  position: absolute;
  inset: 0;
  background: transparent;
}

.strip-tear-band {
  position: absolute;
  left: 0;
  right: 0;
  top: var(--strip-top);
  height: calc(var(--strip-bottom) - var(--strip-top));
  overflow: hidden;
  z-index: 2;
}

.strip-band-copy {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 16%, rgba(31,125,120,0.10), transparent 24rem),
    radial-gradient(circle at 86% 14%, rgba(181,139,90,0.09), transparent 23rem),
    linear-gradient(180deg, rgba(248,245,237,0.99), rgba(255,253,247,0.99));
}

.strip-band-copy::before,
.strip-band-copy::after {
  content: "";
  position: absolute;
  left: 0;
  width: 100%;
  height: 1px;
  background-image: linear-gradient(
    90deg,
    rgba(31,125,120,0.28) 0 12px,
    transparent 12px 38px
  );
  background-size: 38px 1px;
  background-repeat: repeat-x;
}

.strip-band-copy::before { top: 0; }
.strip-band-copy::after { bottom: 0; }

.strip-black-slit {
  position: absolute;
  left: 0;
  top: 50%;
  width: 0;
  height: 26px;
  transform: translateY(-50%);
  background: linear-gradient(180deg, transparent 0 3px, rgba(7,10,11,0.96) 3px 23px, transparent 23px 26px);
  box-shadow:
    0 12px 25px rgba(0,0,0,0.18),
    inset 0 1px 0 rgba(255,255,255,0.10);
  z-index: 5;
}

.strip-band-edge {
  position: absolute;
  left: 0;
  width: 100%;
  height: 50%;
  background:
    radial-gradient(circle at 18% 16%, rgba(31,125,120,0.10), transparent 24rem),
    radial-gradient(circle at 86% 14%, rgba(181,139,90,0.09), transparent 23rem),
    linear-gradient(180deg, rgba(248,245,237,0.995), rgba(255,253,247,0.995));
  z-index: 4;
}

.strip-band-edge-top {
  top: 0;
  transform-origin: center bottom;
  clip-path: polygon(0 0, 100% 0, 100% 80%, 93% 84%, 86% 79%, 78% 86%, 69% 80%, 60% 88%, 51% 80%, 43% 86%, 34% 80%, 26% 87%, 17% 80%, 9% 85%, 0 80%);
}

.strip-band-edge-bottom {
  bottom: 0;
  transform-origin: center top;
  clip-path: polygon(0 20%, 9% 15%, 17% 20%, 26% 13%, 34% 20%, 43% 14%, 51% 20%, 60% 12%, 69% 20%, 78% 14%, 86% 21%, 93% 16%, 100% 20%, 100% 100%, 0 100%);
}

.strip-card-transform {
  position: fixed;
  left: 50%;
  top: 50%;
  width: 280px;
  aspect-ratio: 5 / 6;
  transform: translate(-50%, -50%) scale(0.55);
  opacity: 0;
  z-index: 8;
  perspective: 1600px;
}

.strip-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
}

.strip-card-transform.is-visible {
  opacity: 1;
}

.strip-card-transform.is-flip .strip-card-inner {
  animation: stripCardFlip 0.72s cubic-bezier(0.3, 0.9, 0.2, 1) 1;
}

.strip-card-face {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  overflow: hidden;
  border-radius: 22px;
  border: 1px solid rgba(18, 56, 71, 0.12);
  box-shadow: 0 24px 60px rgba(18, 56, 71, 0.18);
  background: white;
}

.strip-card-face img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.strip-card-back {
  transform: rotateY(180deg);
}

.strip-transition.active .strip-black-slit {
  animation: stripSlitOpen 0.75s cubic-bezier(0.72,0.01,0.24,1) forwards;
}

.strip-transition.active .strip-band-edge-top {
  animation: stripTopPeel 1.25s cubic-bezier(0.72,0.01,0.24,1) forwards;
}

.strip-transition.active .strip-band-edge-bottom {
  animation: stripBottomPeel 1.25s cubic-bezier(0.72,0.01,0.24,1) forwards;
}

.strip-transition.active .strip-tear-band.is-collapsing {
  animation: stripBandCollapse 0.82s cubic-bezier(0.23, 0.88, 0.22, 1) forwards;
}

.strip-transition.active .strip-card-transform.is-visible {
  animation: stripCardArrive 0.82s cubic-bezier(0.23, 0.88, 0.22, 1) forwards;
}

@keyframes stripSlitOpen {
  0% { width: 0; opacity: 0; }
  8% { opacity: 1; }
  100% { width: 100vw; opacity: 1; }
}

@keyframes stripTopPeel {
  0%, 55% {
    transform: translateY(0) rotateX(0deg);
    opacity: 1;
  }
  100% {
    transform: translateY(-54px) rotateX(72deg);
    opacity: 0;
  }
}

@keyframes stripBottomPeel {
  0%, 55% {
    transform: translateY(0) rotateX(0deg);
    opacity: 1;
  }
  100% {
    transform: translateY(54px) rotateX(-72deg);
    opacity: 0;
  }
}

@keyframes stripBandCollapse {
  0% {
    left: 0;
    right: 0;
    top: var(--strip-top);
    height: calc(var(--strip-bottom) - var(--strip-top));
    border-radius: 0;
    opacity: 1;
    transform: none;
  }
  100% {
    left: 50%;
    right: auto;
    top: 50%;
    width: 280px;
    height: 336px;
    transform: translate(-50%, -50%) scale(0.02);
    border-radius: 22px;
    opacity: 0;
  }
}

@keyframes stripCardArrive {
  0% {
    transform: translate(-50%, -50%) scale(0.48);
    opacity: 0;
  }
  60% {
    transform: translate(-50%, -50%) scale(1.04);
    opacity: 1;
  }
  100% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }
}

@keyframes stripCardFlip {
  0%   { transform: rotateY(0deg); }
  100% { transform: rotateY(180deg); }
}

@media (max-width: 680px) {
  .tear-guide-top-wrap,
  .tear-guide-bottom-wrap,
  .landing-summary {
    width: calc(100vw - 1.8rem) !important;
  }

  .tear-guide-top-wrap {
    margin-top: 1.6rem;
  }

  .strip-card-transform {
    width: min(76vw, 280px);
  }
}


/* =========================
   v14 critical fix
   - True screen-based navigation
   - No wheel/touch/page scroll between screens
   - Fix v13 landing overlap
========================= */

html,
body {
  width: 100%;
  height: 100%;
  overflow: hidden !important;
  overscroll-behavior: none;
}

body {
  position: fixed;
  inset: 0;
}

/* Main becomes a locked viewport. Pages are switched by JS classes. */
main {
  position: relative;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
}

main > .page {
  position: absolute !important;
  inset: 0;
  width: 100vw;
  height: 100vh;
  min-height: 100vh;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(20px) scale(0.995);
  transition:
    opacity 0.55s ease,
    transform 0.65s cubic-bezier(0.2, 0.86, 0.22, 1),
    visibility 0s linear 0.65s;
  overflow: hidden;
}

main > .page.is-current {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
  transition:
    opacity 0.55s ease,
    transform 0.65s cubic-bezier(0.2, 0.86, 0.22, 1),
    visibility 0s linear 0s;
}

/* Prevent non-screen content from appearing in the locked viewport. */
.contact-section,
.site-footer {
  display: none !important;
}

/* Landing layout repair */
.page-landing {
  display: flex;
  align-items: stretch;
  justify-content: center;
  overflow: hidden;
}

.landing-inner {
  position: relative;
  width: min(calc(100vw - 1.4rem), 1680px);
  height: 100vh;
  min-height: 100vh;
  padding: 0;
  margin: 0 auto;
}

.page-landing .eyebrow {
  position: absolute;
  top: 1.05rem;
  left: 0;
  z-index: 8;
  margin: 0;
}

.main-name {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  font-size: clamp(4.2rem, 12vw, 11rem);
}

.main-name span:first-child {
  position: absolute;
  left: 0;
  top: 11.5vh;
}

.main-name span:last-child {
  position: absolute;
  right: 0;
  bottom: 4.2vh;
  text-align: right;
}

/* The intro band should sit between Danqi and Zhuang, not overlap Danqi. */
.tear-guide-top-wrap {
  position: relative;
  z-index: 5;
  width: calc(100vw - 2.6rem);
  margin-top: 39vh;
  margin-bottom: 1rem;
}

.main-subtitle {
  position: relative;
  z-index: 5;
  margin: 0 0 0.8rem 0;
  max-width: calc(100vw - 2.6rem);
}

.landing-summary {
  position: relative;
  z-index: 5;
  margin: 0;
  max-width: none !important;
  width: calc(100vw - 2.6rem) !important;
  padding-right: 0 !important;
  font-size: clamp(1.08rem, 1.55vw, 1.42rem);
  line-height: 1.7;
}

.tear-guide-bottom-wrap {
  position: relative;
  z-index: 5;
  width: calc(100vw - 2.6rem);
  margin-top: 1rem;
}

.tear-guide-line {
  height: 1px;
  background-image: linear-gradient(
    90deg,
    rgba(31, 125, 120, 0.22) 0 12px,
    transparent 12px 38px
  );
  background-size: 38px 1px;
  background-repeat: repeat-x;
  opacity: 1;
}

/* Keep the Enter button vertically aligned with the intro strip. */
.edge-enter {
  top: 53%;
}

/* About page remains a locked screen but can fit content safely. */
.page-story {
  height: 100vh;
  overflow: hidden;
}

.story-stage {
  height: 100vh;
  min-height: 100vh;
  display: flex;
  align-items: center;
}

.story-layout {
  width: 100%;
  padding-top: 0;
}

/* Hub page is also fully locked. */
.page-explore {
  height: 100vh;
  min-height: 100vh;
  overflow: hidden;
}

/* Section overlay can still scroll internally if content is tall. */
.section-page {
  overflow-y: auto;
  overscroll-behavior: contain;
}

/* Ensure the transition overlays use the locked viewport, not document scroll. */
.strip-transition,
.tear-transition,
.zip-transition {
  position: fixed;
  inset: 0;
}

@media (max-width: 680px) {
  .page-landing .eyebrow {
    top: 0.85rem;
    font-size: 0.62rem;
    letter-spacing: 0.12em;
  }

  .main-name {
    font-size: clamp(4.2rem, 20vw, 6.8rem);
  }

  .main-name span:first-child {
    top: 12vh;
  }

  .main-name span:last-child {
    bottom: 11vh;
  }

  .tear-guide-top-wrap {
    width: calc(100vw - 1.8rem);
    margin-top: 38vh;
  }

  .main-subtitle {
    max-width: calc(100vw - 1.8rem);
    font-size: 1.18rem;
  }

  .landing-summary {
    width: calc(100vw - 1.8rem) !important;
    font-size: 0.95rem;
    line-height: 1.55;
  }

  .tear-guide-bottom-wrap {
    width: calc(100vw - 1.8rem);
  }
}


/* =========================
   v15 critical fixes
   - Enter button works again
   - Zhuang no longer clipped
   - Hide native scrollbar in locked screen mode
========================= */

html,
body {
  overflow: hidden !important;
  scrollbar-width: none;
}

html::-webkit-scrollbar,
body::-webkit-scrollbar {
  width: 0 !important;
  height: 0 !important;
  display: none !important;
}

/* Keep the huge diagonal name inside the locked viewport. */
.main-name {
  font-size: clamp(4rem, 10.8vw, 9.6rem) !important;
}

.main-name span:first-child {
  top: 10.2vh !important;
}

.main-name span:last-child {
  bottom: 15vh !important;
  right: 0.35rem !important;
}

/* Make sure the landing content sits above the decorative big name. */
.page-landing .eyebrow,
.tear-guide-top-wrap,
.main-subtitle,
.landing-summary,
.tear-guide-bottom-wrap,
.edge-enter {
  z-index: 20 !important;
}

/* Ensure Enter is clickable and not blocked by overlaying text layers. */
.edge-enter {
  pointer-events: auto !important;
}

/* The big name should never intercept clicks. */
.main-name,
.main-name span {
  pointer-events: none !important;
}

/* Small-screen safety. */
@media (max-width: 680px) {
  .main-name {
    font-size: clamp(3.8rem, 18vw, 6.2rem) !important;
  }

  .main-name span:first-child {
    top: 11vh !important;
  }

  .main-name span:last-child {
    bottom: 13vh !important;
  }
}


/* =========================
   v16 transition polish
   - Hide visible dashed guide lines, but keep same measured tear range
   - Add a left-to-right curling paper roll
   - Roll reaches right edge, then card appears/ flips into About page
   - Enter button: arrow only by default; label appears near hover
========================= */

/* Hide the guide lines visually but preserve their layout so the tear range stays unchanged. */
.tear-guide-top-wrap,
.tear-guide-bottom-wrap {
  opacity: 0 !important;
}

/* Arrow-only entry control. */
.edge-enter {
  width: 58px;
  height: 58px;
  padding: 0 !important;
  justify-content: center;
  gap: 0;
  overflow: hidden;
  border-radius: 999px 0 0 999px;
  transition:
    width 0.28s cubic-bezier(0.2, 0.86, 0.22, 1),
    transform 0.22s ease,
    background 0.22s ease,
    box-shadow 0.22s ease;
}

.edge-enter .edge-label {
  max-width: 0;
  opacity: 0;
  transform: translateX(12px);
  white-space: nowrap;
  overflow: hidden;
  transition:
    max-width 0.28s cubic-bezier(0.2, 0.86, 0.22, 1),
    opacity 0.2s ease,
    transform 0.28s cubic-bezier(0.2, 0.86, 0.22, 1);
}

.edge-enter:hover,
.edge-enter:focus-visible {
  width: 160px;
  padding: 0.75rem 0.9rem 0.75rem 1.05rem !important;
  justify-content: center;
  gap: 0.7rem;
  box-shadow: 0 22px 55px rgba(18,56,71,0.16);
}

.edge-enter:hover .edge-label,
.edge-enter:focus-visible .edge-label {
  max-width: 90px;
  opacity: 1;
  transform: translateX(0);
}

/* Explore keeps same right-edge style but also benefits from the hover-reveal behaviour. */
.edge-explore {
  width: 58px;
}

.edge-explore:hover,
.edge-explore:focus-visible {
  width: 215px;
}

/* New smoother strip tear. */
.strip-transition {
  --strip-mid: var(--strip-center);
}

.strip-tear-band {
  perspective: 1600px;
  transform-style: preserve-3d;
}

.strip-band-copy {
  opacity: 0;
}

/* The dark interior is slimmer and opens more smoothly. */
.strip-black-slit {
  height: 34px;
  top: 50%;
  background:
    radial-gradient(ellipse at center, rgba(0,0,0,0.98) 0 44%, rgba(0,0,0,0.80) 55%, transparent 78%);
  filter: blur(0.15px);
  box-shadow:
    0 16px 28px rgba(0,0,0,0.18),
    inset 0 1px 0 rgba(255,255,255,0.08);
  transform: translateY(-50%) scaleY(0.6);
}

/* Instead of two big paper blocks flying away, make the torn edges curl. */
.strip-band-edge {
  background:
    radial-gradient(circle at 18% 16%, rgba(31,125,120,0.08), transparent 24rem),
    radial-gradient(circle at 86% 14%, rgba(181,139,90,0.08), transparent 23rem),
    linear-gradient(180deg, rgba(248,245,237,0.98), rgba(255,253,247,0.98));
  box-shadow: 0 10px 28px rgba(18,56,71,0.08);
  backface-visibility: hidden;
}

.strip-band-edge-top {
  clip-path: polygon(0 0, 100% 0, 100% 86%, 0 86%);
}

.strip-band-edge-bottom {
  clip-path: polygon(0 14%, 100% 14%, 100% 100%, 0 100%);
}

/* Travelling paper curl/roll. */
.strip-curl-roll {
  position: absolute;
  left: -110px;
  top: 50%;
  width: 118px;
  height: calc(100% + 34px);
  transform: translateY(-50%) rotateY(0deg);
  z-index: 10;
  opacity: 0;
  pointer-events: none;
  will-change: transform, opacity;
}

.curl-paper-face {
  position: absolute;
  inset: 0;
  border-radius: 42px 10px 10px 42px;
  background:
    linear-gradient(90deg,
      rgba(231,224,210,0.98) 0%,
      rgba(255,253,247,1) 18%,
      rgba(223,214,197,0.96) 34%,
      rgba(255,253,247,0.98) 52%,
      rgba(201,190,171,0.82) 70%,
      rgba(255,253,247,0.95) 100%);
  box-shadow:
    22px 0 40px rgba(18,56,71,0.16),
    inset 18px 0 18px rgba(255,255,255,0.65),
    inset -18px 0 22px rgba(18,56,71,0.10);
  transform-origin: 22% center;
}

.curl-paper-face::before,
.curl-paper-face::after {
  content: "";
  position: absolute;
  left: 18px;
  right: 12px;
  height: 1px;
  background-image: linear-gradient(
    90deg,
    rgba(31,125,120,0.22) 0 12px,
    transparent 12px 38px
  );
  background-size: 38px 1px;
  background-repeat: repeat-x;
}

.curl-paper-face::before { top: 18px; }
.curl-paper-face::after { bottom: 18px; }

.curl-shadow {
  position: absolute;
  right: -28px;
  top: 16px;
  bottom: 16px;
  width: 32px;
  border-radius: 50%;
  background: rgba(0,0,0,0.16);
  filter: blur(16px);
}

.strip-card-transform {
  transform: translate(-50%, -50%) scale(0.42) rotateZ(-2deg);
}

/* Override previous active animations with smoother sequence. */
.strip-transition.active .strip-black-slit {
  animation: v16SlitOpen 0.96s cubic-bezier(0.68, 0, 0.16, 1) forwards;
}

.strip-transition.active .strip-curl-roll {
  animation: v16CurlRoll 1.08s cubic-bezier(0.62, 0.02, 0.18, 1) forwards;
}

.strip-transition.active .curl-paper-face {
  animation: v16CurlPulse 1.08s cubic-bezier(0.62, 0.02, 0.18, 1) forwards;
}

.strip-transition.active .strip-band-edge-top {
  animation: v16TopCurl 1.1s cubic-bezier(0.62, 0.02, 0.18, 1) forwards;
}

.strip-transition.active .strip-band-edge-bottom {
  animation: v16BottomCurl 1.1s cubic-bezier(0.62, 0.02, 0.18, 1) forwards;
}

.strip-transition.active .strip-tear-band.is-collapsing {
  animation: v16BandToRightCard 0.86s cubic-bezier(0.2, 0.88, 0.18, 1) forwards;
}

.strip-transition.active .strip-card-transform.is-visible {
  animation: v16CardFromRight 0.86s cubic-bezier(0.2, 0.88, 0.18, 1) forwards;
}

@keyframes v16SlitOpen {
  0% {
    width: 0;
    opacity: 0;
    transform: translateY(-50%) scaleY(0.15);
  }
  12% {
    opacity: 1;
  }
  100% {
    width: 100vw;
    opacity: 1;
    transform: translateY(-50%) scaleY(1);
  }
}

@keyframes v16CurlRoll {
  0% {
    left: -130px;
    opacity: 0;
    transform: translateY(-50%) rotateZ(-5deg) rotateY(0deg) scaleX(0.7);
  }
  10% {
    opacity: 1;
  }
  68% {
    left: calc(100vw - 88px);
    opacity: 1;
    transform: translateY(-50%) rotateZ(2deg) rotateY(18deg) scaleX(1);
  }
  100% {
    left: calc(100vw + 24px);
    opacity: 0;
    transform: translateY(-50%) rotateZ(4deg) rotateY(32deg) scaleX(0.62);
  }
}

@keyframes v16CurlPulse {
  0% {
    transform: rotateY(0deg) scaleX(0.85);
    border-radius: 22px 8px 8px 22px;
  }
  50% {
    transform: rotateY(28deg) scaleX(1);
    border-radius: 48px 10px 10px 48px;
  }
  100% {
    transform: rotateY(58deg) scaleX(0.72);
    border-radius: 60px 8px 8px 60px;
  }
}

@keyframes v16TopCurl {
  0%, 42% {
    transform: translateY(0) rotateX(0deg);
    opacity: 1;
  }
  100% {
    transform: translateY(-18px) rotateX(38deg);
    opacity: 0;
  }
}

@keyframes v16BottomCurl {
  0%, 42% {
    transform: translateY(0) rotateX(0deg);
    opacity: 1;
  }
  100% {
    transform: translateY(18px) rotateX(-38deg);
    opacity: 0;
  }
}

/* The torn band now collapses toward the right edge first,
   matching the roll direction, then the card arrives from that side. */
@keyframes v16BandToRightCard {
  0% {
    left: 0;
    right: 0;
    top: var(--strip-top);
    height: calc(var(--strip-bottom) - var(--strip-top));
    border-radius: 0;
    opacity: 1;
    transform: none;
  }
  100% {
    left: calc(100vw - 160px);
    right: auto;
    top: 50%;
    width: 120px;
    height: 160px;
    transform: translate(-50%, -50%) scale(0.08) rotateZ(8deg);
    border-radius: 22px;
    opacity: 0;
  }
}

@keyframes v16CardFromRight {
  0% {
    left: calc(100vw - 150px);
    top: 50%;
    transform: translate(-50%, -50%) scale(0.36) rotateZ(8deg);
    opacity: 0;
  }
  58% {
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) scale(1.05) rotateZ(-1deg);
    opacity: 1;
  }
  100% {
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) scale(1) rotateZ(0deg);
    opacity: 1;
  }
}

@media (max-width: 680px) {
  .edge-enter {
    width: 52px;
    height: 52px;
  }

  .edge-enter:hover,
  .edge-enter:focus-visible {
    width: 132px;
  }

  .edge-explore:hover,
  .edge-explore:focus-visible {
    width: 180px;
  }

  .strip-curl-roll {
    width: 92px;
    left: -96px;
  }
}


/* =========================
   v17: full-page paper-roll reveal transition
   Based on the latest reference video.
   The old strip/slit transition is disabled.
========================= */

/* Hide leftover guide/perforation visuals; layout can remain but nothing visible. */
.tear-guide-top-wrap,
.tear-guide-bottom-wrap,
.tear-guide,
.tear-guide-line {
  opacity: 0 !important;
  visibility: hidden !important;
}

/* Arrow-only Enter: show label only on hover/focus. */
.edge-enter {
  width: 58px;
  height: 58px;
  padding: 0 !important;
  justify-content: center;
  gap: 0;
  overflow: hidden;
  border-radius: 999px 0 0 999px;
  transition:
    width 0.28s cubic-bezier(0.2, 0.86, 0.22, 1),
    transform 0.22s ease,
    background 0.22s ease,
    box-shadow 0.22s ease;
}

.edge-enter .edge-label {
  max-width: 0;
  opacity: 0;
  transform: translateX(12px);
  white-space: nowrap;
  overflow: hidden;
  transition:
    max-width 0.28s cubic-bezier(0.2, 0.86, 0.22, 1),
    opacity 0.2s ease,
    transform 0.28s cubic-bezier(0.2, 0.86, 0.22, 1);
}

.edge-enter:hover,
.edge-enter:focus-visible {
  width: 160px;
  padding: 0.75rem 0.9rem 0.75rem 1.05rem !important;
  justify-content: center;
  gap: 0.7rem;
  box-shadow: 0 22px 55px rgba(18,56,71,0.16);
}

.edge-enter:hover .edge-label,
.edge-enter:focus-visible .edge-label {
  max-width: 90px;
  opacity: 1;
  transform: translateX(0);
}

/* Disable older transition layers if they remain in CSS cascade. */
.strip-transition,
.tear-transition,
.zip-transition {
  display: none !important;
}

/* Full-page roll reveal layer. */
.paper-roll-transition {
  position: fixed;
  inset: 0;
  z-index: 999;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  overflow: hidden;
  perspective: 1800px;
}

.paper-roll-transition.active {
  opacity: 1;
  visibility: visible;
}

/* A subtle veil prevents a hard flash while About page is prepared behind the sheet. */
.paper-reveal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(248, 245, 237, 0.18);
  opacity: 0;
}

.paper-roll-transition.active .paper-reveal-backdrop {
  animation: paperBackdropFade 1.32s ease forwards;
}

/* The sheet is the part of the paper that remains unrolled.
   It is clipped from left to right, revealing the About page underneath. */
.paper-sheet {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 17% 14%, rgba(31,125,120,0.075), transparent 25rem),
    radial-gradient(circle at 86% 22%, rgba(181,139,90,0.080), transparent 25rem),
    linear-gradient(180deg, rgba(248,245,237,1), rgba(255,253,247,1));
  box-shadow:
    inset 0 0 80px rgba(255,255,255,0.65),
    inset 0 -18px 45px rgba(18,56,71,0.03);
  clip-path: inset(0 0 0 0);
  will-change: clip-path;
}

.paper-sheet::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.22;
  background:
    linear-gradient(90deg, transparent 0 50%, rgba(18,56,71,0.022) 50% 51%, transparent 51% 100%),
    linear-gradient(180deg, transparent 0 50%, rgba(18,56,71,0.018) 50% 51%, transparent 51% 100%);
  background-size: 84px 84px;
}

.paper-roll-transition.active .paper-sheet {
  animation: paperSheetReveal 1.34s cubic-bezier(0.62, 0.02, 0.12, 1) forwards;
}

/* The vertical roll / curled paper edge. */
.paper-roll {
  position: absolute;
  left: -72px;
  top: 50%;
  width: 122px;
  height: 116vh;
  transform: translateY(-50%);
  z-index: 5;
  opacity: 0;
  will-change: transform, opacity, left;
}

.paper-roll-body {
  position: absolute;
  inset: 0;
  border-radius: 62px 18px 18px 62px;
  background:
    linear-gradient(
      90deg,
      #b8ad9e 0%,
      #f9f7f1 9%,
      #d8cec0 19%,
      #ffffff 31%,
      #efe8db 44%,
      #c6b9a6 58%,
      #fffdf8 76%,
      #d6cabb 100%
    );
  box-shadow:
    28px 0 48px rgba(18,56,71,0.22),
    inset 22px 0 24px rgba(255,255,255,0.68),
    inset -22px 0 28px rgba(18,56,71,0.15);
  transform-origin: 20% center;
}

.paper-roll-body::before {
  content: "";
  position: absolute;
  inset: 3% 14% 3% 16%;
  border-radius: inherit;
  background:
    repeating-linear-gradient(
      90deg,
      rgba(18,56,71,0.025) 0 1px,
      transparent 1px 14px
    );
  opacity: 0.55;
}

.paper-roll-edge {
  position: absolute;
  right: -9px;
  top: 0;
  bottom: 0;
  width: 18px;
  border-radius: 50%;
  background:
    linear-gradient(90deg, rgba(255,255,255,0.4), rgba(111,103,92,0.45));
  filter: blur(0.4px);
}

.paper-roll-shadow {
  position: absolute;
  right: -60px;
  top: 5%;
  bottom: 5%;
  width: 76px;
  border-radius: 50%;
  background: rgba(18,56,71,0.22);
  filter: blur(24px);
  opacity: 0.72;
}

.paper-roll-transition.active .paper-roll {
  animation: paperRollMove 1.34s cubic-bezier(0.62, 0.02, 0.12, 1) forwards;
}

.paper-roll-transition.active .paper-roll-body {
  animation: paperRollCurl 1.34s cubic-bezier(0.62, 0.02, 0.12, 1) forwards;
}

/* A brief final flash where the roll leaves the right edge. */
.paper-roll-transition::after {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  width: 16vw;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.72));
  opacity: 0;
  transform: translateX(100%);
}

.paper-roll-transition.active::after {
  animation: paperEdgeFlash 1.34s cubic-bezier(0.62, 0.02, 0.12, 1) forwards;
}

@keyframes paperSheetReveal {
  0% {
    clip-path: inset(0 0 0 0);
  }
  8% {
    clip-path: inset(0 0 0 0);
  }
  88% {
    clip-path: inset(0 0 0 100%);
  }
  100% {
    clip-path: inset(0 0 0 100%);
  }
}

@keyframes paperRollMove {
  0% {
    left: -86px;
    opacity: 0;
    transform: translateY(-50%) rotateZ(-1.4deg) scaleX(0.96);
  }
  7% {
    opacity: 1;
  }
  84% {
    left: calc(100vw - 58px);
    opacity: 1;
    transform: translateY(-50%) rotateZ(0.8deg) scaleX(1.02);
  }
  100% {
    left: calc(100vw + 120px);
    opacity: 0;
    transform: translateY(-50%) rotateZ(1.4deg) scaleX(0.82);
  }
}

@keyframes paperRollCurl {
  0% {
    transform: rotateY(0deg) scaleX(0.88);
    border-radius: 46px 14px 14px 46px;
  }
  42% {
    transform: rotateY(22deg) scaleX(1);
    border-radius: 68px 18px 18px 68px;
  }
  84% {
    transform: rotateY(42deg) scaleX(0.86);
    border-radius: 78px 16px 16px 78px;
  }
  100% {
    transform: rotateY(58deg) scaleX(0.58);
    border-radius: 88px 12px 12px 88px;
  }
}

@keyframes paperBackdropFade {
  0% { opacity: 0; }
  8% { opacity: 1; }
  72% { opacity: 0.65; }
  100% { opacity: 0; }
}

@keyframes paperEdgeFlash {
  0%, 68% {
    opacity: 0;
    transform: translateX(100%);
  }
  83% {
    opacity: 0.72;
    transform: translateX(-12%);
  }
  100% {
    opacity: 0;
    transform: translateX(-120%);
  }
}

@media (max-width: 680px) {
  .edge-enter {
    width: 52px;
    height: 52px;
  }

  .edge-enter:hover,
  .edge-enter:focus-visible {
    width: 132px;
  }

  .paper-roll {
    width: 94px;
    left: -64px;
  }

  .paper-roll-shadow {
    right: -44px;
    width: 58px;
  }
}


/* =========================
   v18: band-only paper roll transition
   Only the subtitle + summary region rolls.
   The rest of the landing page stays still.
========================= */

/* Disable v17 full-screen paper roll layer if any old markup/CSS remains. */
.paper-roll-transition {
  display: none !important;
}

/* Band-only overlay. */
.band-roll-transition {
  position: fixed;
  left: 0;
  top: var(--band-roll-top, 42%);
  width: 100vw;
  height: var(--band-roll-height, 180px);
  z-index: 999;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  overflow: visible;
  perspective: 1600px;
}

.band-roll-transition.active {
  opacity: 1;
  visibility: visible;
}

/* The sheet covers only the intro band. As it clips left-to-right, the original
   landing page underneath is revealed again, so only this band appears to roll. */
.band-paper-sheet {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 20%, rgba(31,125,120,0.075), transparent 20rem),
    radial-gradient(circle at 86% 30%, rgba(181,139,90,0.075), transparent 22rem),
    linear-gradient(180deg, rgba(248,245,237,0.995), rgba(255,253,247,0.995));
  box-shadow:
    0 18px 48px rgba(18,56,71,0.08),
    inset 0 0 48px rgba(255,255,255,0.62);
  clip-path: inset(0 0 0 0);
  will-change: clip-path;
}

/* Give the band a subtle paper texture, but not a visible full-page wipe. */
.band-paper-sheet::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      90deg,
      rgba(18,56,71,0.018) 0 1px,
      transparent 1px 18px
    );
  opacity: 0.42;
}

.band-roll-transition.active .band-paper-sheet {
  animation: bandSheetReveal 1.18s cubic-bezier(0.62, 0.02, 0.12, 1) forwards;
}

/* The moving curled edge is only as tall as the intro band. */
.band-paper-roll {
  position: absolute;
  left: -74px;
  top: 50%;
  width: 116px;
  height: calc(100% + 26px);
  transform: translateY(-50%);
  z-index: 5;
  opacity: 0;
  will-change: left, opacity, transform;
}

.band-paper-roll-body {
  position: absolute;
  inset: 0;
  border-radius: 58px 15px 15px 58px;
  background:
    linear-gradient(
      90deg,
      #b8ad9e 0%,
      #f9f7f1 10%,
      #d8cec0 20%,
      #ffffff 33%,
      #efe8db 45%,
      #c6b9a6 60%,
      #fffdf8 78%,
      #d6cabb 100%
    );
  box-shadow:
    24px 0 44px rgba(18,56,71,0.20),
    inset 20px 0 22px rgba(255,255,255,0.66),
    inset -20px 0 26px rgba(18,56,71,0.14);
  transform-origin: 20% center;
}

.band-paper-roll-body::before {
  content: "";
  position: absolute;
  inset: 5% 14% 5% 16%;
  border-radius: inherit;
  background:
    repeating-linear-gradient(
      90deg,
      rgba(18,56,71,0.025) 0 1px,
      transparent 1px 14px
    );
  opacity: 0.5;
}

.band-paper-roll-edge {
  position: absolute;
  right: -8px;
  top: 0;
  bottom: 0;
  width: 16px;
  border-radius: 50%;
  background:
    linear-gradient(90deg, rgba(255,255,255,0.42), rgba(111,103,92,0.42));
  filter: blur(0.35px);
}

.band-paper-roll-shadow {
  position: absolute;
  right: -52px;
  top: 8%;
  bottom: 8%;
  width: 62px;
  border-radius: 50%;
  background: rgba(18,56,71,0.18);
  filter: blur(20px);
  opacity: 0.7;
}

.band-roll-transition.active .band-paper-roll {
  animation: bandRollMove 1.18s cubic-bezier(0.62, 0.02, 0.12, 1) forwards;
}

.band-roll-transition.active .band-paper-roll-body {
  animation: bandRollCurl 1.18s cubic-bezier(0.62, 0.02, 0.12, 1) forwards;
}

/* The landing text remains readable until the roll passes over it. */
.intro-roll-target {
  will-change: opacity;
}

body.band-rolling .intro-roll-target {
  animation: introBandTextFade 1.18s cubic-bezier(0.62, 0.02, 0.12, 1) forwards;
}

@keyframes bandSheetReveal {
  0% {
    clip-path: inset(0 0 0 0);
  }
  8% {
    clip-path: inset(0 0 0 0);
  }
  90% {
    clip-path: inset(0 0 0 100%);
  }
  100% {
    clip-path: inset(0 0 0 100%);
  }
}

@keyframes bandRollMove {
  0% {
    left: -86px;
    opacity: 0;
    transform: translateY(-50%) rotateZ(-1.4deg) scaleX(0.96);
  }
  7% {
    opacity: 1;
  }
  84% {
    left: calc(100vw - 58px);
    opacity: 1;
    transform: translateY(-50%) rotateZ(0.8deg) scaleX(1.02);
  }
  100% {
    left: calc(100vw + 120px);
    opacity: 0;
    transform: translateY(-50%) rotateZ(1.4deg) scaleX(0.82);
  }
}

@keyframes bandRollCurl {
  0% {
    transform: rotateY(0deg) scaleX(0.88);
    border-radius: 44px 14px 14px 44px;
  }
  42% {
    transform: rotateY(22deg) scaleX(1);
    border-radius: 64px 18px 18px 64px;
  }
  84% {
    transform: rotateY(42deg) scaleX(0.86);
    border-radius: 74px 16px 16px 74px;
  }
  100% {
    transform: rotateY(58deg) scaleX(0.58);
    border-radius: 84px 12px 12px 84px;
  }
}

@keyframes introBandTextFade {
  0%, 12% {
    opacity: 1;
  }
  88%, 100% {
    opacity: 0.08;
  }
}

@media (max-width: 680px) {
  .band-paper-roll {
    width: 92px;
    left: -64px;
  }

  .band-paper-roll-shadow {
    right: -42px;
    width: 54px;
  }
}


/* =========================
   v19 transition correction
   - Rolled-away area becomes black
   - Original intro text is hidden immediately during roll
   - The intro text is copied onto the rolling paper sheet
   - Left side no longer shows stale page text after the roll passes
========================= */

.band-roll-transition {
  overflow: hidden;
  border-radius: 0;
}

/* Black base exposed after paper has rolled away. */
.band-paper-black {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 40% 50%, rgba(0,0,0,0.96), rgba(0,0,0,0.92) 48%, rgba(0,0,0,0.88) 100%);
  box-shadow:
    inset 0 20px 42px rgba(0,0,0,0.55),
    inset 0 -18px 38px rgba(0,0,0,0.50),
    0 16px 40px rgba(0,0,0,0.16);
  opacity: 0;
}

.band-roll-transition.active .band-paper-black {
  animation: v19BlackBaseIn 1.16s ease forwards;
}

/* The sheet now contains a copy of the subtitle + summary.
   It is clipped from left to right, revealing black underneath. */
.band-paper-sheet {
  z-index: 2;
  overflow: hidden;
  display: block;
  transform: translateZ(0);
  backface-visibility: hidden;
}

/* Paper surface polish */
.band-paper-sheet::before {
  opacity: 0.30;
}

.band-paper-sheet::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255,255,255,0.04), transparent 20%, transparent 80%, rgba(18,56,71,0.05));
}

/* Copied text on the moving sheet */
.band-sheet-content {
  position: absolute;
  inset: 0;
  padding-left: var(--band-content-left, 0px);
  padding-right: var(--band-content-right, 24px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.72rem;
  color: var(--ink);
  pointer-events: none;
  white-space: normal;
}

.band-sheet-title {
  margin: 0;
  color: #75848b;
  font-size: clamp(1.55rem, 2.5vw, 2.75rem);
  line-height: 1.15;
  font-weight: 560;
  letter-spacing: -0.03em;
}

.band-sheet-summary {
  margin: 0;
  color: #30484f;
  font-size: clamp(1.02rem, 1.45vw, 1.34rem);
  line-height: 1.65;
  max-width: none;
}

/* Hide original landing band instantly once roll starts.
   This fixes the bug where the left side still showed the old information. */
body.band-rolling .intro-roll-target {
  animation: none !important;
  opacity: 0 !important;
}

/* Keep other landing elements visible and still. */
body.band-rolling .main-name,
body.band-rolling .page-landing .eyebrow,
body.band-rolling .edge-enter {
  opacity: 1;
}

/* Roll edge should sit above both black base and sheet. */
.band-paper-roll {
  z-index: 6;
  height: calc(100% + 34px);
}

/* Stronger contact shadow at the rolling boundary */
.band-paper-roll-shadow {
  background: rgba(0,0,0,0.26);
  filter: blur(22px);
  opacity: 0.86;
}

/* Make the sheet movement smoother and make black visible immediately behind it. */
.band-roll-transition.active .band-paper-sheet {
  animation: v19BandSheetReveal 1.20s cubic-bezier(0.58, 0.02, 0.12, 1) forwards;
}

.band-roll-transition.active .band-paper-roll {
  animation: v19BandRollMove 1.20s cubic-bezier(0.58, 0.02, 0.12, 1) forwards;
}

.band-roll-transition.active .band-paper-roll-body {
  animation: v19BandRollCurl 1.20s cubic-bezier(0.58, 0.02, 0.12, 1) forwards;
}

@keyframes v19BlackBaseIn {
  0% {
    opacity: 0;
    transform: scaleY(0.72);
  }
  7% {
    opacity: 1;
    transform: scaleY(1);
  }
  88% {
    opacity: 1;
  }
  100% {
    opacity: 0.96;
  }
}

@keyframes v19BandSheetReveal {
  0% {
    clip-path: inset(0 0 0 0);
    filter: brightness(1);
  }
  6% {
    clip-path: inset(0 0 0 0);
  }
  86% {
    clip-path: inset(0 0 0 100%);
    filter: brightness(1.02);
  }
  100% {
    clip-path: inset(0 0 0 100%);
    filter: brightness(1.02);
  }
}

@keyframes v19BandRollMove {
  0% {
    left: -84px;
    opacity: 0;
    transform: translateY(-50%) rotateZ(-1.1deg) scaleX(0.96);
  }
  6% {
    opacity: 1;
  }
  84% {
    left: calc(100vw - 56px);
    opacity: 1;
    transform: translateY(-50%) rotateZ(0.8deg) scaleX(1.02);
  }
  100% {
    left: calc(100vw + 126px);
    opacity: 0;
    transform: translateY(-50%) rotateZ(1.5deg) scaleX(0.78);
  }
}

@keyframes v19BandRollCurl {
  0% {
    transform: rotateY(0deg) scaleX(0.86);
    border-radius: 42px 14px 14px 42px;
  }
  38% {
    transform: rotateY(20deg) scaleX(1);
    border-radius: 64px 18px 18px 64px;
  }
  82% {
    transform: rotateY(43deg) scaleX(0.84);
    border-radius: 76px 16px 16px 76px;
  }
  100% {
    transform: rotateY(60deg) scaleX(0.56);
    border-radius: 86px 12px 12px 86px;
  }
}

/* During roll, prevent text selection or accidental hover artifacts. */
body.band-rolling {
  user-select: none;
}

@media (max-width: 680px) {
  .band-sheet-content {
    gap: 0.48rem;
  }

  .band-sheet-title {
    font-size: 1.18rem;
  }

  .band-sheet-summary {
    font-size: 0.92rem;
    line-height: 1.48;
  }
}


/* =========================
   v20 polish
   - Enter starts as a small circled arrow
   - Hover/focus reveals Enter text
   - Band-roll transition connects into a large flip-card reveal
   - Card starts oversized, flips while scaling down, stops on sketch side,
     moves left, then About text slides up on the right
========================= */

/* Small circled arrow by default. */
.edge-enter {
  width: 56px !important;
  height: 56px !important;
  min-height: 56px !important;
  padding: 0 !important;
  border-radius: 999px !important;
  border: 1px solid rgba(18, 56, 71, 0.16) !important;
  border-right: 1px solid rgba(18, 56, 71, 0.16) !important;
  background: rgba(255, 255, 255, 0.82) !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0 !important;
  overflow: hidden !important;
  box-shadow: 0 16px 42px rgba(18,56,71,0.12) !important;
  backdrop-filter: blur(18px);
  transition:
    width 0.32s cubic-bezier(0.2, 0.86, 0.22, 1),
    border-radius 0.32s cubic-bezier(0.2, 0.86, 0.22, 1),
    transform 0.22s ease,
    background 0.22s ease,
    box-shadow 0.22s ease !important;
}

.edge-enter::before {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  border: 1px solid rgba(31, 125, 120, 0.22);
  opacity: 1;
  transition: opacity 0.2s ease, transform 0.32s cubic-bezier(0.2, 0.86, 0.22, 1);
  pointer-events: none;
}

.edge-enter .edge-label {
  order: 1;
  max-width: 0;
  opacity: 0;
  transform: translateX(14px);
  white-space: nowrap;
  overflow: hidden;
  transition:
    max-width 0.32s cubic-bezier(0.2, 0.86, 0.22, 1),
    opacity 0.22s ease,
    transform 0.32s cubic-bezier(0.2, 0.86, 0.22, 1);
}

.edge-enter .edge-arrow {
  order: 2;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  font-size: 1.1rem;
  font-weight: 900;
  line-height: 1;
  color: var(--teal);
  animation: none !important;
  transform: translateX(0);
  transition: transform 0.32s cubic-bezier(0.2, 0.86, 0.22, 1);
}

.edge-enter:hover,
.edge-enter:focus-visible {
  width: 154px !important;
  border-radius: 999px 0 0 999px !important;
  gap: 0.68rem !important;
  transform: translateY(-50%) translateX(-4px) !important;
  background: rgba(255,255,255,0.96) !important;
  box-shadow: 0 22px 55px rgba(18,56,71,0.18) !important;
}

.edge-enter:hover::before,
.edge-enter:focus-visible::before {
  opacity: 0;
  transform: scale(0.72);
}

.edge-enter:hover .edge-label,
.edge-enter:focus-visible .edge-label {
  max-width: 86px;
  opacity: 1;
  transform: translateX(0);
}

.edge-enter:hover .edge-arrow,
.edge-enter:focus-visible .edge-arrow {
  transform: translateX(2px);
}

/* Explore Profile uses the same reveal behaviour but has more text. */
.edge-explore:hover,
.edge-explore:focus-visible {
  width: 220px !important;
}

/* Make the band transition end more softly so it can connect to the card reveal. */
.band-roll-transition.active .band-paper-black {
  animation-duration: 1.04s;
}

.band-roll-transition.active .band-paper-sheet,
.band-roll-transition.active .band-paper-roll,
.band-roll-transition.active .band-paper-roll-body {
  animation-duration: 1.08s;
}

/* About screen: put the floating card in the true centre first. */
.floating-card-wrap {
  left: 50% !important;
  top: 50% !important;
  width: min(64vw, 680px) !important;
  transform: translate(-50%, -50%) scale(1.28) !important;
  opacity: 0;
  z-index: 60;
  pointer-events: none;
  perspective: 1800px;
}

.floating-card {
  transition: none !important;
  transform: rotateY(0deg) scale(1.42);
  transform-origin: center center;
}

/* Stage 1: the card is huge at first, then gradually becomes fully visible in the centre
   while flipping toward the sketch side. */
.floating-card-wrap.animate-in {
  opacity: 1;
  animation: v20CardFrameArrive 1.85s cubic-bezier(0.16, 0.92, 0.18, 1) forwards !important;
}

.floating-card-wrap.animate-in .floating-card {
  animation: v20CardFlipZoom 1.85s cubic-bezier(0.16, 0.92, 0.18, 1) forwards !important;
}

/* Override the ordinary class-based flip while the intro animation is running. */
.floating-card.is-flipped {
  transform: rotateY(180deg);
}

/* Stage 2: after stopping on sketch side, the card moves to the left slot. */
.floating-card-wrap.move-to-corner {
  animation: v20CardMoveLeft 1.05s cubic-bezier(0.2, 0.88, 0.2, 1) forwards !important;
}

/* Pinned card final appearance on the left. */
.pinned-card-shell {
  opacity: 0;
  transform: translateY(18px) scale(0.96);
}

.pinned-card-shell.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition: opacity 0.42s ease, transform 0.48s cubic-bezier(0.2, 0.88, 0.22, 1);
}

/* Make sure the pinned card is on the sketch side by default after the intro. */
.pinned-card.is-flipped .pinned-card-inner {
  transform: rotateY(180deg);
}

/* Right-side text comes from the bottom after the card settles left. */
.story-copy {
  opacity: 0;
  transform: translateY(105px);
  transition:
    opacity 0.82s ease,
    transform 0.86s cubic-bezier(0.2, 0.86, 0.22, 1);
}

.story-copy.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Slightly improve the locked About layout so the left card and right text feel balanced. */
.story-stage {
  max-width: 1240px;
}

.story-layout {
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 2.8rem;
  align-items: center;
}

/* Card becomes less visually cropped on the final left side. */
.pinned-card {
  width: 300px;
}

@keyframes v20CardFrameArrive {
  0% {
    width: min(88vw, 940px);
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.48) rotateZ(-3deg);
    filter: blur(8px);
  }
  12% {
    opacity: 1;
  }
  55% {
    width: min(72vw, 760px);
    transform: translate(-50%, -50%) scale(1.05) rotateZ(1.2deg);
    filter: blur(0px);
  }
  100% {
    width: min(48vw, 420px);
    transform: translate(-50%, -50%) scale(1) rotateZ(0deg);
    opacity: 1;
    filter: blur(0px);
  }
}

@keyframes v20CardFlipZoom {
  0% {
    transform: rotateY(0deg) scale(1.85);
  }
  35% {
    transform: rotateY(74deg) scale(1.38);
  }
  72% {
    transform: rotateY(168deg) scale(1.06);
  }
  100% {
    transform: rotateY(180deg) scale(1);
  }
}

@keyframes v20CardMoveLeft {
  0% {
    left: 50%;
    top: 50%;
    width: min(48vw, 420px);
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }
  72% {
    left: 0;
    top: 50%;
    width: 300px;
    transform: translate(0, -50%) scale(1);
    opacity: 1;
  }
  100% {
    left: 0;
    top: 50%;
    width: 300px;
    transform: translate(0, -50%) scale(1);
    opacity: 0;
  }
}

@media (max-width: 980px) {
  .story-layout {
    grid-template-columns: 1fr;
    gap: 1.4rem;
  }

  .floating-card-wrap {
    width: min(80vw, 560px) !important;
  }

  .pinned-card {
    width: min(76vw, 300px);
  }

  @keyframes v20CardMoveLeft {
    0% {
      left: 50%;
      top: 50%;
      width: min(60vw, 420px);
      transform: translate(-50%, -50%) scale(1);
      opacity: 1;
    }
    72% {
      left: 50%;
      top: 31%;
      width: min(76vw, 300px);
      transform: translate(-50%, -50%) scale(1);
      opacity: 1;
    }
    100% {
      left: 50%;
      top: 31%;
      width: min(76vw, 300px);
      transform: translate(-50%, -50%) scale(1);
      opacity: 0;
    }
  }
}

@media (max-width: 680px) {
  .edge-enter {
    width: 52px !important;
    height: 52px !important;
    min-height: 52px !important;
  }

  .edge-enter:hover,
  .edge-enter:focus-visible {
    width: 132px !important;
  }

  .edge-explore:hover,
  .edge-explore:focus-visible {
    width: 184px !important;
  }

  @keyframes v20CardFrameArrive {
    0% {
      width: 118vw;
      opacity: 0;
      transform: translate(-50%, -50%) scale(1.35) rotateZ(-3deg);
      filter: blur(8px);
    }
    12% {
      opacity: 1;
    }
    60% {
      width: 92vw;
      transform: translate(-50%, -50%) scale(1.03) rotateZ(1deg);
      filter: blur(0px);
    }
    100% {
      width: min(76vw, 320px);
      transform: translate(-50%, -50%) scale(1) rotateZ(0deg);
      opacity: 1;
      filter: blur(0px);
    }
  }
}


/* =========================
   v21 refinement
   - Softer, lower-opacity arrow cue
   - Remove heavy black tear feeling
   - Transition becomes a light paper-ribbon roll into the flip-card sequence
========================= */

/* Right-edge trigger: small, quiet hint by default. */
.edge-enter {
  width: 42px !important;
  height: 42px !important;
  min-height: 42px !important;
  padding: 0 !important;
  border-radius: 999px !important;
  border: 1px solid rgba(18, 56, 71, 0.10) !important;
  border-right: 1px solid rgba(18, 56, 71, 0.10) !important;
  background: rgba(255, 255, 255, 0.42) !important;
  opacity: 1 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0 !important;
  overflow: hidden !important;
  box-shadow: 0 10px 26px rgba(18, 56, 71, 0.055) !important;
  backdrop-filter: blur(12px);
  transition:
    width 0.30s cubic-bezier(0.2, 0.86, 0.22, 1),
    opacity 0.22s ease,
    border-radius 0.30s cubic-bezier(0.2, 0.86, 0.22, 1),
    transform 0.22s ease,
    background 0.22s ease,
    box-shadow 0.22s ease !important;
}

.edge-enter::before {
  content: "";
  position: absolute;
  inset: 5px;
  border-radius: 50%;
  border: 1px solid rgba(31, 125, 120, 0.16);
  opacity: 0.8;
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.30s cubic-bezier(0.2, 0.86, 0.22, 1);
}

.edge-enter .edge-label {
  order: 1;
  max-width: 0;
  opacity: 0;
  transform: translateX(10px);
  white-space: nowrap;
  overflow: hidden;
  transition:
    max-width 0.30s cubic-bezier(0.2, 0.86, 0.22, 1),
    opacity 0.22s ease,
    transform 0.30s cubic-bezier(0.2, 0.86, 0.22, 1);
}

.edge-enter .edge-arrow {
  order: 2;
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  font-size: 0.95rem;
  font-weight: 900;
  line-height: 1;
  color: rgba(31, 125, 120, 0.62);
  animation: none !important;
  transform: translateX(0);
  transition: color 0.22s ease, transform 0.30s cubic-bezier(0.2, 0.86, 0.22, 1);
}

.edge-enter:hover,
.edge-enter:focus-visible {
  width: 136px !important;
  height: 46px !important;
  min-height: 46px !important;
  opacity: 0.94 !important;
  border-radius: 999px 0 0 999px !important;
  gap: 0.58rem !important;
  transform: translateY(-50%) translateX(-3px) !important;
  background: rgba(255, 255, 255, 0.88) !important;
  box-shadow: 0 16px 42px rgba(18, 56, 71, 0.12) !important;
}

.edge-enter:hover::before,
.edge-enter:focus-visible::before {
  opacity: 0;
  transform: scale(0.78);
}

.edge-enter:hover .edge-label,
.edge-enter:focus-visible .edge-label {
  max-width: 78px;
  opacity: 1;
  transform: translateX(0);
}

.edge-enter:hover .edge-arrow,
.edge-enter:focus-visible .edge-arrow {
  color: var(--teal);
  transform: translateX(2px);
}

/* Wider label for Explore Profile while keeping the same quiet cue behaviour. */
.edge-explore:hover,
.edge-explore:focus-visible {
  width: 205px !important;
}

/* The roll should feel like a pale paper ribbon, not a black tear. */
.band-roll-transition {
  mix-blend-mode: normal;
}

/* Replace the heavy black base with a very soft inner shadow / negative space. */
.band-paper-black {
  background:
    radial-gradient(ellipse at 45% 50%, rgba(18, 56, 71, 0.075), rgba(18, 56, 71, 0.052) 54%, rgba(18, 56, 71, 0.035) 100%) !important;
  box-shadow:
    inset 0 14px 28px rgba(18, 56, 71, 0.06),
    inset 0 -12px 24px rgba(18, 56, 71, 0.045),
    0 14px 32px rgba(18, 56, 71, 0.06) !important;
}

.band-roll-transition.active .band-paper-black {
  animation: v21SoftBaseIn 1.02s ease forwards !important;
}

/* Softer sheet surface. */
.band-paper-sheet {
  background:
    radial-gradient(circle at 18% 20%, rgba(31, 125, 120, 0.055), transparent 20rem),
    radial-gradient(circle at 86% 30%, rgba(181, 139, 90, 0.055), transparent 22rem),
    linear-gradient(180deg, rgba(250, 247, 239, 0.995), rgba(255, 253, 247, 0.995)) !important;
  box-shadow:
    0 12px 34px rgba(18, 56, 71, 0.055),
    inset 0 0 44px rgba(255, 255, 255, 0.66) !important;
}

.band-paper-sheet::after {
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.05), transparent 24%, transparent 84%, rgba(18, 56, 71, 0.035)) !important;
}

/* Paper content should fade with the ribbon, not abruptly disappear. */
.band-sheet-title {
  color: rgba(95, 115, 124, 0.92) !important;
}

.band-sheet-summary {
  color: rgba(48, 72, 79, 0.92) !important;
}

/* The original text still hides immediately so there is no stale text after the roll passes. */
body.band-rolling .intro-roll-target {
  animation: none !important;
  opacity: 0 !important;
}

/* Slimmer, more delicate roll. */
.band-paper-roll {
  width: 92px !important;
  left: -72px;
  height: calc(100% + 22px);
  opacity: 0;
}

.band-paper-roll-body {
  border-radius: 48px 13px 13px 48px !important;
  background:
    linear-gradient(
      90deg,
      rgba(190, 181, 165, 0.88) 0%,
      rgba(252, 249, 242, 1) 12%,
      rgba(222, 214, 200, 0.92) 24%,
      rgba(255, 255, 255, 0.98) 39%,
      rgba(237, 230, 218, 0.94) 54%,
      rgba(206, 196, 178, 0.76) 70%,
      rgba(255, 253, 247, 0.96) 100%
    ) !important;
  box-shadow:
    18px 0 34px rgba(18, 56, 71, 0.14),
    inset 16px 0 18px rgba(255, 255, 255, 0.62),
    inset -15px 0 20px rgba(18, 56, 71, 0.10) !important;
}

.band-paper-roll-edge {
  width: 12px !important;
  right: -6px !important;
  opacity: 0.72;
}

.band-paper-roll-shadow {
  right: -42px !important;
  width: 50px !important;
  background: rgba(18, 56, 71, 0.13) !important;
  filter: blur(16px) !important;
  opacity: 0.68 !important;
}

/* Use a single softer animation set and override previous v19/v20 animation names. */
.band-roll-transition.active .band-paper-sheet {
  animation: v21RibbonReveal 1.04s cubic-bezier(0.58, 0.02, 0.12, 1) forwards !important;
}

.band-roll-transition.active .band-paper-roll {
  animation: v21RibbonRollMove 1.04s cubic-bezier(0.58, 0.02, 0.12, 1) forwards !important;
}

.band-roll-transition.active .band-paper-roll-body {
  animation: v21RibbonCurl 1.04s cubic-bezier(0.58, 0.02, 0.12, 1) forwards !important;
}

@keyframes v21SoftBaseIn {
  0% {
    opacity: 0.55;
    transform: scaleY(1);
  }
  100% {
    opacity: 0.55;
    transform: scaleY(1);
  }
}

@keyframes v21RibbonReveal {
  0%, 7% {
    clip-path: inset(0 0 0 0);
    filter: brightness(1);
  }
  84% {
    clip-path: inset(0 0 0 100%);
    filter: brightness(1);
  }
  100% {
    clip-path: inset(0 0 0 100%);
    filter: brightness(1);
  }
}

@keyframes v21RibbonRollMove {
  0% {
    left: -78px;
    opacity: 0;
    transform: translateY(-50%) rotateZ(-0.7deg) scaleX(0.96);
  }
  7% {
    opacity: 0.96;
  }
  82% {
    left: calc(100vw - 48px);
    opacity: 0.95;
    transform: translateY(-50%) rotateZ(0.55deg) scaleX(1.0);
  }
  100% {
    left: calc(100vw + 88px);
    opacity: 0;
    transform: translateY(-50%) rotateZ(1.1deg) scaleX(0.76);
  }
}

@keyframes v21RibbonCurl {
  0% {
    transform: rotateY(0deg) scaleX(0.90);
    border-radius: 42px 12px 12px 42px;
  }
  40% {
    transform: rotateY(18deg) scaleX(1);
    border-radius: 56px 15px 15px 56px;
  }
  80% {
    transform: rotateY(36deg) scaleX(0.88);
    border-radius: 66px 14px 14px 66px;
  }
  100% {
    transform: rotateY(52deg) scaleX(0.64);
    border-radius: 74px 11px 11px 74px;
  }
}

/* Make the first card reveal less abrupt after the ribbon transition. */
.floating-card-wrap {
  filter: none !important;
}

.floating-card-wrap.animate-in {
  animation-duration: 1.72s !important;
}

.floating-card-wrap.animate-in .floating-card {
  animation-duration: 1.72s !important;
}

@media (max-width: 680px) {
  .edge-enter {
    width: 38px !important;
    height: 38px !important;
    min-height: 38px !important;
  }

  .edge-enter .edge-arrow {
    width: 16px;
    height: 16px;
    font-size: 0.86rem;
    font-weight: 900;
  }

  .edge-enter:hover,
  .edge-enter:focus-visible {
    width: 116px !important;
    height: 42px !important;
    min-height: 42px !important;
  }

  .edge-explore:hover,
  .edge-explore:focus-visible {
    width: 170px !important;
  }

  .band-paper-roll {
    width: 74px !important;
    left: -58px;
  }

  .band-paper-roll-shadow {
    right: -34px !important;
    width: 42px !important;
  }
}


/* =========================
   v22 fixes and polish
   - One circled arrow only
   - Default cue opacity +20% from v21
   - Hover reveals text
   - First Enter reliably triggers card animation
   - Center card flips rapidly multiple times while shrinking
========================= */

/* Single circled arrow: remove the second inner circle from v21. */
.edge-enter::before {
  display: none !important;
}

/* Default state: one circle around the arrow, slightly more visible than v21. */
.edge-enter {
  width: 42px !important;
  height: 42px !important;
  min-height: 42px !important;
  padding: 0 !important;
  border-radius: 999px !important;
  border: 1px solid rgba(18, 56, 71, 0.16) !important;
  border-right: 1px solid rgba(18, 56, 71, 0.16) !important;
  background: rgba(255, 255, 255, 0.52) !important;
  opacity: 1 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0 !important;
  overflow: hidden !important;
  box-shadow: 0 10px 26px rgba(18, 56, 71, 0.07) !important;
  backdrop-filter: blur(12px);
  transition:
    width 0.30s cubic-bezier(0.2, 0.86, 0.22, 1),
    opacity 0.22s ease,
    border-radius 0.30s cubic-bezier(0.2, 0.86, 0.22, 1),
    transform 0.22s ease,
    background 0.22s ease,
    box-shadow 0.22s ease !important;
}

.edge-enter .edge-arrow {
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  font-size: 0.95rem;
  line-height: 1;
  font-weight: 900;
  color: rgba(31, 125, 120, 0.74) !important;
  animation: none !important;
  transform: translateX(0);
  transition: color 0.22s ease, transform 0.30s cubic-bezier(0.2, 0.86, 0.22, 1);
}

.edge-enter .edge-label {
  max-width: 0;
  opacity: 0;
  transform: translateX(10px);
  white-space: nowrap;
  overflow: hidden;
  transition:
    max-width 0.30s cubic-bezier(0.2, 0.86, 0.22, 1),
    opacity 0.22s ease,
    transform 0.30s cubic-bezier(0.2, 0.86, 0.22, 1);
}

/* Hover/focus expands into label. */
.edge-enter:hover,
.edge-enter:focus-visible {
  width: 136px !important;
  height: 46px !important;
  min-height: 46px !important;
  opacity: 0.98 !important;
  border-radius: 999px 0 0 999px !important;
  gap: 0.58rem !important;
  transform: translateY(-50%) translateX(-3px) !important;
  background: rgba(255, 255, 255, 0.92) !important;
  box-shadow: 0 16px 42px rgba(18, 56, 71, 0.14) !important;
}

.edge-enter:hover .edge-label,
.edge-enter:focus-visible .edge-label {
  max-width: 80px;
  opacity: 1;
  transform: translateX(0);
}

.edge-enter:hover .edge-arrow,
.edge-enter:focus-visible .edge-arrow {
  color: var(--teal) !important;
  transform: translateX(2px);
}

/* About page right-side Explore Profile: default is also just ->, hover expands text. */
.edge-explore {
  width: 42px !important;
  height: 42px !important;
  min-height: 42px !important;
}

.edge-explore:hover,
.edge-explore:focus-visible {
  width: 205px !important;
}

/* Back button text has been changed in HTML; keep it on the top-right. */
.story-back {
  font-weight: 760;
}

/* Faster multiple-flip centre-card sequence.
   Ends at 900deg = sketch/back side, while scaling down to full view. */
.floating-card-wrap.animate-in {
  animation: v22CardFrameArrive 1.68s cubic-bezier(0.16, 0.92, 0.18, 1) forwards !important;
}

.floating-card-wrap.animate-in .floating-card {
  animation: v22CardMultiFlipZoom 1.68s cubic-bezier(0.16, 0.92, 0.18, 1) forwards !important;
}

@keyframes v22CardFrameArrive {
  0% {
    width: min(92vw, 980px);
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.52) rotateZ(-3deg);
    filter: blur(7px);
  }
  10% {
    opacity: 1;
  }
  42% {
    width: min(78vw, 800px);
    transform: translate(-50%, -50%) scale(1.16) rotateZ(1.2deg);
    filter: blur(0);
  }
  72% {
    width: min(60vw, 560px);
    transform: translate(-50%, -50%) scale(1.04) rotateZ(-0.6deg);
    filter: blur(0);
  }
  100% {
    width: min(48vw, 420px);
    transform: translate(-50%, -50%) scale(1) rotateZ(0deg);
    opacity: 1;
    filter: blur(0);
  }
}

@keyframes v22CardMultiFlipZoom {
  0% {
    transform: rotateY(0deg) scale(1.92);
  }
  16% {
    transform: rotateY(180deg) scale(1.62);
  }
  32% {
    transform: rotateY(360deg) scale(1.38);
  }
  50% {
    transform: rotateY(540deg) scale(1.20);
  }
  68% {
    transform: rotateY(720deg) scale(1.08);
  }
  100% {
    transform: rotateY(900deg) scale(1);
  }
}

/* Preserve the final sketch state after keyframe ends. */
.floating-card.is-flipped {
  transform: rotateY(180deg) scale(1) !important;
}

/* Ensure the pinned card final state is sketch side. */
.pinned-card.is-flipped .pinned-card-inner {
  transform: rotateY(180deg) !important;
}

@media (max-width: 680px) {
  .edge-enter,
  .edge-explore {
    width: 38px !important;
    height: 38px !important;
    min-height: 38px !important;
  }

  .edge-enter .edge-arrow {
    width: 16px;
    height: 16px;
    font-size: 0.86rem;
    font-weight: 900;
  }

  .edge-enter:hover,
  .edge-enter:focus-visible {
    width: 116px !important;
    height: 42px !important;
    min-height: 42px !important;
  }

  .edge-explore:hover,
  .edge-explore:focus-visible {
    width: 170px !important;
  }

  @keyframes v22CardFrameArrive {
    0% {
      width: 120vw;
      opacity: 0;
      transform: translate(-50%, -50%) scale(1.38) rotateZ(-3deg);
      filter: blur(7px);
    }
    10% {
      opacity: 1;
    }
    55% {
      width: 96vw;
      transform: translate(-50%, -50%) scale(1.08) rotateZ(1deg);
      filter: blur(0);
    }
    100% {
      width: min(76vw, 320px);
      transform: translate(-50%, -50%) scale(1) rotateZ(0deg);
      opacity: 1;
      filter: blur(0);
    }
  }
}


/* =========================
   v23 card animation fix
   - JS drives the multi-flip + shrink sequence directly
   - avoids CSS transform overrides
   - card pauses at centre before moving left
========================= */

/* Disable previous CSS keyframe-based flip on the floating card. */
.floating-card-wrap.animate-in,
.floating-card-wrap.animate-in .floating-card,
.floating-card-wrap.move-to-corner,
.floating-card-wrap.move-to-corner .floating-card {
  animation: none !important;
}

/* Centre overlay state used by v23 JS. */
.floating-card-wrap.v23-center-card {
  position: absolute !important;
  left: 50% !important;
  top: 50% !important;
  width: min(56vw, 520px) !important;
  transform: translate(-50%, -50%) scale(1) rotateZ(0deg) !important;
  opacity: 1;
  z-index: 70;
  pointer-events: none;
  perspective: 1800px;
  transition: opacity 0.22s ease;
}

.floating-card-wrap.v23-center-card .floating-card {
  transition: none !important;
  transform-style: preserve-3d;
  will-change: transform;
}

/* Once JS adds .is-flipped, keep it exactly on sketch side. */
.floating-card.is-flipped {
  transform: rotateY(180deg) scale(1) !important;
}

/* Move from centre to left after the centre pause. */
.floating-card-wrap.v23-center-card.v23-move-left {
  animation: v23MoveCardLeft 1s cubic-bezier(0.2, 0.88, 0.2, 1) forwards !important;
}

@keyframes v23MoveCardLeft {
  0% {
    left: 50%;
    top: 50%;
    width: min(56vw, 520px);
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }
  72% {
    left: 0;
    top: 50%;
    width: 300px;
    transform: translate(0, -50%) scale(1);
    opacity: 1;
  }
  100% {
    left: 0;
    top: 50%;
    width: 300px;
    transform: translate(0, -50%) scale(1);
    opacity: 0;
  }
}

/* Pinned left card must appear on sketch side. */
.pinned-card.is-flipped .pinned-card-inner {
  transform: rotateY(180deg) !important;
}

/* Make the final left card align with the moving overlay. */
.pinned-card {
  width: 300px;
}

/* About text remains bottom-slide. */
.story-copy {
  opacity: 0;
  transform: translateY(105px);
  transition:
    opacity 0.82s ease,
    transform 0.86s cubic-bezier(0.2, 0.86, 0.22, 1);
}

.story-copy.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 980px) {
  .floating-card-wrap.v23-center-card {
    width: min(76vw, 420px) !important;
  }

  @keyframes v23MoveCardLeft {
    0% {
      left: 50%;
      top: 50%;
      width: min(76vw, 420px);
      transform: translate(-50%, -50%) scale(1);
      opacity: 1;
    }
    72% {
      left: 50%;
      top: 31%;
      width: min(76vw, 300px);
      transform: translate(-50%, -50%) scale(1);
      opacity: 1;
    }
    100% {
      left: 50%;
      top: 31%;
      width: min(76vw, 300px);
      transform: translate(-50%, -50%) scale(1);
      opacity: 0;
    }
  }
}

@media (max-width: 680px) {
  .floating-card-wrap.v23-center-card {
    width: min(82vw, 340px) !important;
  }
}


/* =========================
   v24 card animation refinement
   - More flips than v23
   - Flip speed starts fast and slows down
   - Card size decreases with flip count
   - Final centre size equals the left pinned-card size
   - Then it slides left without further shrinking
========================= */

/* About right-edge text shortened from Explore Profile to Explore. */
.edge-explore:hover,
.edge-explore:focus-visible {
  width: 148px !important;
}

/* Disable previous v23 animation state when v24 state is used. */
.floating-card-wrap.v24-center-card {
  position: absolute !important;
  left: 50% !important;
  top: 50% !important;
  width: 300px !important;
  transform: translate(-50%, -50%) scale(1) rotateZ(0deg) !important;
  opacity: 1;
  z-index: 70;
  pointer-events: none;
  perspective: 1800px;
  transition: opacity 0.22s ease;
}

.floating-card-wrap.v24-center-card .floating-card {
  transition: none !important;
  transform-style: preserve-3d;
  will-change: transform;
}

/* Keep final sketch side after JS finishes. */
.floating-card.is-flipped {
  transform: rotateY(180deg) scale(1) !important;
}

/* Slide left at exactly the same size as the final display card. */
.floating-card-wrap.v24-center-card.v24-move-left {
  animation: v24MoveCardLeftSameSize 0.86s cubic-bezier(0.2, 0.88, 0.2, 1) forwards !important;
}

@keyframes v24MoveCardLeftSameSize {
  0% {
    left: 50%;
    top: 50%;
    width: 300px;
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }
  72% {
    left: 0;
    top: 50%;
    width: 300px;
    transform: translate(0, -50%) scale(1);
    opacity: 1;
  }
  100% {
    left: 0;
    top: 50%;
    width: 300px;
    transform: translate(0, -50%) scale(1);
    opacity: 0;
  }
}

/* Pinned left card uses the same width as the final centre card. */
.pinned-card {
  width: 300px !important;
}

.pinned-card.is-flipped .pinned-card-inner {
  transform: rotateY(180deg) !important;
}

@media (max-width: 980px) {
  .floating-card-wrap.v24-center-card {
    width: min(76vw, 300px) !important;
  }

  @keyframes v24MoveCardLeftSameSize {
    0% {
      left: 50%;
      top: 50%;
      width: min(76vw, 300px);
      transform: translate(-50%, -50%) scale(1);
      opacity: 1;
    }
    72% {
      left: 50%;
      top: 31%;
      width: min(76vw, 300px);
      transform: translate(-50%, -50%) scale(1);
      opacity: 1;
    }
    100% {
      left: 50%;
      top: 31%;
      width: min(76vw, 300px);
      transform: translate(-50%, -50%) scale(1);
      opacity: 0;
    }
  }
}

@media (max-width: 680px) {
  .edge-explore:hover,
  .edge-explore:focus-visible {
    width: 128px !important;
  }
}


/* =========================
   v25 refinements
   - About card reduced by 30%
   - Final flip-card size matches reduced left card
   - Pinned left card flip bug fixed with JS + inline transform
   - Flip icon centred under card and made subtle like the right arrow
   - Spiral page Back moved to top-right
   - Spiral rotation speed reduced in script.js
========================= */

:root {
  --about-card-width: 210px;
}

/* About layout tightened after reducing card size. */
.story-layout {
  grid-template-columns: 260px minmax(0, 1fr) !important;
  gap: 2.4rem !important;
  align-items: center !important;
}

.story-card-slot {
  display: flex;
  justify-content: center;
  min-height: 320px !important;
}

.pinned-card-shell {
  width: var(--about-card-width) !important;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.pinned-card {
  width: var(--about-card-width) !important;
}

/* Keep direct inline transform from JS, but preserve transition. */
.pinned-card-inner {
  transition: transform 0.62s cubic-bezier(0.26, 0.86, 0.22, 1) !important;
  transform-style: preserve-3d;
}

.pinned-card.is-flipped .pinned-card-inner {
  transform: rotateY(180deg);
}

/* Floating centre card ends at exactly the new left-card size. */
.floating-card-wrap.v24-center-card {
  width: var(--about-card-width) !important;
}

/* Slide from centre to left without changing the new size. */
@keyframes v24MoveCardLeftSameSize {
  0% {
    left: 50%;
    top: 50%;
    width: var(--about-card-width);
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }
  72% {
    left: 0;
    top: 50%;
    width: var(--about-card-width);
    transform: translate(0, -50%) scale(1);
    opacity: 1;
  }
  100% {
    left: 0;
    top: 50%;
    width: var(--about-card-width);
    transform: translate(0, -50%) scale(1);
    opacity: 0;
  }
}

/* Centre card can still look large initially because the JS scales its inner card. */
.floating-card-wrap.v24-center-card .floating-card {
  will-change: transform;
}

/* Flip icon: centred under card, lower opacity, matching the subtle next-arrow cue. */
.flip-rotate-indicator {
  width: 30px !important;
  height: 30px !important;
  min-width: 30px !important;
  min-height: 30px !important;
  margin: 0.82rem auto 0 !important;
  align-self: center !important;
  border-radius: 50% !important;
  border: 1px solid rgba(18, 56, 71, 0.16) !important;
  background: rgba(255, 255, 255, 0.52) !important;
  color: rgba(31, 125, 120, 0.74) !important;
  opacity: 0.58 !important;
  box-shadow: 0 10px 26px rgba(18, 56, 71, 0.07) !important;
  display: grid !important;
  place-items: center !important;
  pointer-events: none;
}

.flip-rotate-indicator span {
  font-size: 1rem !important;
  line-height: 1 !important;
  opacity: 0.9 !important;
}

/* Move Spiral page Back to top-right. */
.hub-back {
  left: auto !important;
  right: 1.35rem !important;
}

/* About page Back already belongs on the right; keep consistency. */
.story-back {
  left: auto !important;
  right: 1.35rem !important;
}

/* About text can use the recovered space. */
.story-copy h2 {
  font-size: clamp(2rem, 3.65vw, 3.7rem) !important;
}

/* Explore cue remains short after rename. */
.edge-explore:hover,
.edge-explore:focus-visible {
  width: 148px !important;
}

@media (max-width: 980px) {
  :root {
    --about-card-width: min(66vw, 210px);
  }

  .story-layout {
    grid-template-columns: 1fr !important;
    gap: 1.1rem !important;
  }

  .story-card-slot {
    min-height: 260px !important;
  }

  @keyframes v24MoveCardLeftSameSize {
    0% {
      left: 50%;
      top: 50%;
      width: var(--about-card-width);
      transform: translate(-50%, -50%) scale(1);
      opacity: 1;
    }
    72% {
      left: 50%;
      top: 31%;
      width: var(--about-card-width);
      transform: translate(-50%, -50%) scale(1);
      opacity: 1;
    }
    100% {
      left: 50%;
      top: 31%;
      width: var(--about-card-width);
      transform: translate(-50%, -50%) scale(1);
      opacity: 0;
    }
  }
}

@media (max-width: 680px) {
  .hub-back,
  .story-back {
    right: 0.85rem !important;
  }

  .flip-rotate-indicator {
    width: 38px !important;
    height: 38px !important;
    min-width: 38px !important;
    min-height: 38px !important;
  }

  .flip-rotate-indicator span {
    font-size: 1.2rem !important;
  }
}

.flip-rotate-indicator {
  pointer-events: auto !important;
  cursor: pointer !important;
  user-select: none !important;
}

.flip-rotate-indicator * {
  pointer-events: none !important;
}


.band-paper-black {
  background: rgba(18, 56, 71, 0.42) !important;
  box-shadow: inset 0 10px 24px rgba(18, 56, 71, 0.12) !important;
  clip-path: inset(0 100% 0 0) !important;
  opacity: 1 !important;
}

.band-roll-transition.active .band-paper-black {
  animation: v26DarkRevealOnlyTornArea 1.04s cubic-bezier(0.58, 0.02, 0.12, 1) forwards !important;
}

.band-paper-sheet {
  background: transparent !important;
  box-shadow: none !important;
}

.band-paper-sheet::after {
  background: transparent !important;
}

.band-roll-transition.active .band-paper-sheet {
  animation: v26RibbonRevealNoFlash 1.04s cubic-bezier(0.58, 0.02, 0.12, 1) forwards !important;
}

@keyframes v26DarkRevealOnlyTornArea {
  0%, 7% {
    clip-path: inset(0 100% 0 0);
  }

  84% {
    clip-path: inset(0 0 0 0);
  }

  100% {
    clip-path: inset(0 0 0 0);
  }
}

@keyframes v26RibbonRevealNoFlash {
  0%, 7% {
    clip-path: inset(0 0 0 0);
    filter: none;
  }

  84% {
    clip-path: inset(0 0 0 100%);
    filter: none;
  }

  100% {
    clip-path: inset(0 0 0 100%);
    filter: none;
  }
}


/* Force About-page Explore arrow to align with Page1 Enter arrow */
#story > #goToHub.edge-explore,
#goToHub.edge-explore {
  position: fixed !important;
  left: auto !important;
  right: 0.85rem !important;
  top: 60vh !important;
  bottom: auto !important;
  transform: translateY(-50%) !important;
  margin: 0 !important;
  z-index: 9999 !important;
}

#goToHub.edge-explore:hover,
#goToHub.edge-explore:focus-visible {
  transform: translateY(-50%) translateX(-3px) !important;
}




/* Compact full-screen layout for Spiral detail pages */
.section-page {
  height: 100vh !important;
  overflow: hidden !important;
}

.section-page-inner {
  width: min(1180px, calc(100% - 2.4rem)) !important;
  height: 100vh !important;
  box-sizing: border-box !important;
  padding: 4.4rem 0 1.2rem !important;

  display: grid !important;
  grid-template-rows: auto 1fr !important;
  gap: 1rem !important;
}

.section-page-heading {
  margin-bottom: 0 !important;
  max-width: 920px !important;
}

.section-page-heading h2 {
  font-size: clamp(3rem, 5.6vw, 5.6rem) !important;
  line-height: 0.92 !important;
  margin: 0 0 0.55rem !important;
}

.section-page-heading p:last-child {
  font-size: clamp(0.95rem, 1.12vw, 1.08rem) !important;
  line-height: 1.35 !important;
  margin: 0 !important;
  max-width: 820px !important;
}

.section-content-grid {
  min-height: 0 !important;
  height: 100% !important;
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 0.85rem !important;
}

.content-card {
  min-height: 0 !important;
  height: 100% !important;
  padding: 1rem 1.1rem !important;
  border-radius: 26px !important;
  overflow: hidden !important;
}

.content-card-kicker {
  font-size: 0.78rem !important;
  margin-bottom: 0.5rem !important;
}

.content-card h3 {
  font-size: clamp(1.12rem, 1.55vw, 1.55rem) !important;
  line-height: 1.08 !important;
  margin: 0 0 0.55rem !important;
}

.content-card p {
  font-size: 0.9rem !important;
  line-height: 1.42 !important;
  margin: 0.35rem 0 !important;
}

.content-card ul {
  margin: 0.55rem 0 0 !important;
  padding-left: 0.95rem !important;
}

.content-card li {
  font-size: 0.86rem !important;
  line-height: 1.35 !important;
  margin: 0.32rem 0 !important;
}

.content-tags {
  margin-top: 0.55rem !important;
  gap: 0.32rem !important;
}

.content-tags span {
  font-size: 0.68rem !important;
  padding: 0.24rem 0.42rem !important;
}


/* Subtle first-page Enter hint */
#enterToStory.edge-enter {
  animation: enterHintPulse 2.4s ease-in-out infinite;
}

#enterToStory.edge-enter .edge-arrow {
  animation: enterArrowNudge 1.6s ease-in-out infinite !important;
}

#enterToStory.edge-enter:hover,
#enterToStory.edge-enter:focus-visible {
  animation: none;
}

#enterToStory.edge-enter:hover .edge-arrow,
#enterToStory.edge-enter:focus-visible .edge-arrow {
  animation: none !important;
}

@keyframes enterHintPulse {
  0%, 100% {
    opacity: 0.52;
    box-shadow: 0 10px 26px rgba(18, 56, 71, 0.07);
  }

  50% {
    opacity: 0.86;
    box-shadow: 0 14px 34px rgba(31, 125, 120, 0.16);
  }
}

@keyframes enterArrowNudge {
  0%, 100% {
    transform: translateX(0);
  }

  50% {
    transform: translateX(4px);
  }
}


#enterToStory.edge-enter .edge-arrow {
  font-size: 1.18rem !important;
  font-weight: 900 !important;
  color: rgba(31, 125, 120, 0.92) !important;
  text-shadow:
    0.35px 0 rgba(31, 125, 120, 0.92),
    -0.35px 0 rgba(31, 125, 120, 0.92);
}


#goToHub.edge-explore .edge-arrow {
  font-size: 1.18rem !important;
  font-weight: 900 !important;
  color: rgba(31, 125, 120, 0.92) !important;
  text-shadow:
    0.35px 0 rgba(31, 125, 120, 0.92),
    -0.35px 0 rgba(31, 125, 120, 0.92);
}


/* =========================
   Spiral card theme fix
   ========================= */

.spiral-card {
  background: transparent;
  border: none;
  box-shadow: none;
}

.spiral-card-shell {
  position: relative;
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.spiral-card-surface {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    radial-gradient(circle at 15% 18%, var(--card-soft), transparent 34%),
    linear-gradient(135deg, var(--card-bg), rgba(255, 255, 255, 0.72));
  pointer-events: none;
}

.spiral-card-content {
  position: relative;
  z-index: 1;
}

.spiral-illustration {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 155px;
  padding: 0.25rem 0 0.45rem;
  background: transparent;
}

.spiral-doodle {
  width: min(185px, 78%);
  max-height: 180px;
  object-fit: contain;
  display: block;
  background: transparent;
}



/* =========================
   Stronger spiral card theme
   ========================= */

.spiral-card {
  background: transparent;
  border: none;
  box-shadow: none;
}

.spiral-card-shell {
  position: relative;
  background: var(--card-bg);
  border: 1px solid rgba(18, 56, 71, 0.10);
  border-radius: var(--radius-xl);
  box-shadow: 0 24px 70px rgba(18, 56, 71, 0.12);
  overflow: hidden;
}

.spiral-card-surface {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    radial-gradient(circle at 18% 16%, var(--card-soft) 0%, transparent 42%),
    radial-gradient(circle at 88% 82%, var(--card-accent) 0%, transparent 40%),
    linear-gradient(135deg, var(--card-bg) 0%, var(--card-soft) 100%);
  opacity: 0.72;
  pointer-events: none;
}

.spiral-card-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}


/* =========================
   Spiral illustration alignment
   ========================= */

.spiral-illustration {
  width: 100%;
  min-height: 180px;
  display: grid;
  place-items: center;
  padding: 0.45rem 0 0.65rem;
  margin: 0 auto;
  background: transparent !important;
}

.spiral-doodle {
  width: min(220px, 82%);
  max-height: 205px;
  object-fit: contain;
  object-position: center;
  display: block;
  margin: 0 auto;
  background: transparent !important;
}


/* =========================
   Make spiral cards smaller
   ========================= */

.spiral-card {
  width: 200px !important;
  min-height: 200px !important;
  max-height: 400px !important;
}

.spiral-card-shell {
  width: 100%;
  min-height: 330px;
}

.spiral-card-content {
  padding: 1rem 1rem 1.15rem;
}

.spiral-illustration {
  min-height: 145px;
  padding: 0.25rem 0 0.4rem;
}

.spiral-doodle {
  width: min(175px, 78%);
  max-height: 165px;
}



/* Hide the top label on spiral cards */
.card-topline {
  display: none !important;
}



/* Compact spiral cards after shortening captions */
.spiral-card-shell,
.spiral-card-content {
  min-height: 165px !important;
  max-height: 165px !important;
}

.spiral-card-content {
  padding: 0.7rem 0.75rem 0.65rem !important;
  display: flex !important;
  flex-direction: column !important;
  justify-content: center !important;
  gap: 0.55rem !important;
}

.spiral-illustration {
  min-height: 72px !important;
  max-height: 82px !important;
  margin: 0 !important;
}

.spiral-doodle {
  max-height: 78px !important;
  width: auto !important;
  object-fit: contain !important;
}

.spiral-card-caption {
  margin-top: 0 !important;
}

.spiral-card-caption strong {
  font-size: 0.92rem !important;
  line-height: 1.05 !important;
  margin-bottom: 0.18rem !important;
}

.spiral-card-caption span {
  font-size: 0.62rem !important;
  line-height: 1.14 !important;
}


/* Remove shadow/reflection from Page 3 spiral cards */
.spiral-card,
.spiral-card-shell,
.spiral-card-surface,
.spiral-card-content {
  box-shadow: none !important;
}

.spiral-card::before,
.spiral-card::after,
.spiral-card-shell::before,
.spiral-card-shell::after,
.spiral-card-surface::before,
.spiral-card-surface::after,
.spiral-card-content::before,
.spiral-card-content::after {
  box-shadow: none !important;
}



/* Enlarge only the illustration inside each spiral card */
.spiral-illustration {
  min-height: 115px !important;
  max-height: 135px !important;
}

.spiral-doodle {
  max-height: 122px !important;
  width: auto !important;
  transform: scale(1.25);
  transform-origin: center center;
}


/* Hide description text under spiral card titles */
.spiral-card-caption span {
  display: none !important;
}


/* Page 3 card gradient colours */

/* Education: soft blue */
.education-card .spiral-card-shell,
.education-card .spiral-card-surface {
  background: linear-gradient(to bottom right, #f6f8d4 0%, #aee6e6 100%) !important;
}

/* Ongoing Projects: soft mint */
.projects-card .spiral-card-shell,
.projects-card .spiral-card-surface {
  background: linear-gradient(to bottom right, #fff5e8 0%, #ffc2cb 100%) !important;
}

/* Publications: blue-grey */
.publications-card .spiral-card-shell,
.publications-card .spiral-card-surface {
  background: linear-gradient(to bottom right, #bbdefb 0%, #ffcdd2 100%) !important;
}

/* AI & Web Projects: cream peach */
.aiweb-card .spiral-card-shell,
.aiweb-card .spiral-card-surface {
  background: linear-gradient(to bottom right, #fbfff7 0%, #ffd8bd 100%) !important;
}

/* Internships: warm peach-pink */
.experience-card .spiral-card-shell,
.experience-card .spiral-card-surface {
  background: linear-gradient(to bottom right, #def8ff 0%, #f6aeb4 100%) !important;
}

/* Skills: soft lavender */
.skills-card .spiral-card-shell,
.skills-card .spiral-card-surface {
  background: linear-gradient(to bottom right, #e9ffc2 0%, #c9b7e8 100%) !important;
}

/* Awards: soft rose */
.awards-card .spiral-card-shell,
.awards-card .spiral-card-surface {
  background: linear-gradient(to bottom right, #fbfecf 0%, #f5a8bf 100%) !important;
}

/* Languages: soft blue */
.languages-card .spiral-card-shell,
.languages-card .spiral-card-surface {
  background: linear-gradient(to bottom right, #ccfbff 0%, #ef96c5 100%) !important;
}



/* Responsive viewport baseline */
html,
body,
main,
.page {
  width: 100vw;
  height: 100dvh;
  min-height: 100dvh;
}




/* Large desktop optimisation */
@media (min-width: 1500px) {
  .landing-inner {
    max-width: 1320px !important;
    margin: 0 auto !important;
  }

  .main-name {
    font-size: clamp(7rem, 8.6vw, 11rem) !important;
  }

  .main-subtitle {
    font-size: clamp(1.35rem, 1.45vw, 2rem) !important;
  }

  .landing-summary {
    font-size: clamp(0.95rem, 0.95vw, 1.25rem) !important;
    max-width: 1180px !important;
  }
}



/* Mobile landing layout */
@media (max-width: 680px) {
  .landing-inner {
    width: 100vw !important;
    height: 100dvh !important;
    padding: 1.15rem 1rem !important;
    box-sizing: border-box !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    gap: 1.1rem !important;
  }

  .page-landing .eyebrow {
    font-size: 0.56rem !important;
    line-height: 1.45 !important;
    letter-spacing: 0.12em !important;
    max-width: 92vw !important;
  }

  .main-name {
    font-size: clamp(3.4rem, 17vw, 5.2rem) !important;
    line-height: 0.88 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 0.35rem !important;
  }

  .main-name span {
    position: static !important;
    transform: none !important;
    display: block !important;
  }

  .main-subtitle {
    font-size: clamp(1rem, 5vw, 1.45rem) !important;
    line-height: 1.15 !important;
    max-width: 92vw !important;
  }

  .landing-summary {
    font-size: 0.86rem !important;
    line-height: 1.5 !important;
    max-width: 92vw !important;
  }

  #enterToStory.edge-enter {
    right: 0.65rem !important;
    top: 68vh !important;
  }
}