/* Homepage hero only. Each animated transform has a separate owner. */
@font-face {
  font-family: "Cormorant Hero";
  src: url("assets/fonts/cormorant-garamond-regular.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Cormorant Hero";
  src: url("assets/fonts/cormorant-garamond-italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
.home .site-header {
  position: absolute;
  inset: 0 0 auto;
  background: transparent;
  border: 0;
}
.home .header-inner {
  min-height: 90px;
  width: calc(100% - 112px);
  max-width: 1500px;
}
.home .identity img {
  width: 63px;
  height: 47px;
}
.home .header-descriptor {
  display: block;
  font-size: 15px;
  color: #203e51;
  letter-spacing: 0.015em;
}
.home nav {
  gap: 60px;
}
.home nav a {
  color: #203e51;
}
.home nav a > span {
  display: none;
}
.story-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: max(860px, 100svh);
  background: #a4d5de;
  color: #12354b;
  padding: clamp(265px, 29vh, 330px) 6% 68px 65%;
}
.story-environment {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}
.story-water {
  position: absolute;
  inset: 0;
  background: url("assets/hero/water-v2.webp") center/100% 100% no-repeat;
}
.story-rays {
  position: absolute;
  inset: 12% 0 0;
  background: radial-gradient(ellipse at 78% 25%, #e9f4dd40, transparent 45%);
  animation: water-light 17s ease-in-out infinite alternate;
}
.story-depth {
  position: absolute;
  inset: 50% 0 0;
  background: linear-gradient(transparent, #174c831a);
  pointer-events: none;
}
.story-wake {
  position: absolute;
  top: 13%;
  left: 29%;
  width: 14%;
  height: 12px;
  border: 1px solid #fff5dc80;
  border-radius: 50%;
  animation: wake-settle 2s ease-out both;
}
.story-guide {
  position: absolute;
  left: 19%;
  top: 34%;
  width: clamp(400px, 42vw, 620px);
  transform: none;
  will-change: transform;
}
.story-diver {
  position: relative;
  isolation: isolate;
  animation: quiet-entry 1.2s both;
}
.story-swimmer {
  position: relative;
  z-index: 1;
  animation: quiet-idle 8s ease-in-out infinite both paused;
}
.story-character {
  display: block;
  width: 100%;
  overflow: visible;
  transform: rotate(35deg);
}
.story-tail {
  transform-origin: 224px 292px;
}
.story-body-form,
.story-fin {
  transform: none;
}
.story-eye {
  transform-box: fill-box;
  transform-origin: center;
}
.story-local-light {
  position: absolute;
  inset: -10%;
  z-index: -2;
  background: radial-gradient(ellipse closest-side, #e4f2cc12, transparent);
}
.story-caustic {
  animation: character-light 10s ease-in-out infinite;
  opacity: 0.35;
}
.story-bubbles {
  position: absolute;
  left: 7%;
  top: 12%;
  width: 61%;
  height: 77%;
}
.story-bubble,
.story-trail i,
.story-burst {
  position: absolute;
  border-radius: 48% 52% 51% 49%;
  border: 1px solid #fdf7e5a6;
  background:
    radial-gradient(circle at 28% 18%, #fff6ddcc, transparent 22%),
    radial-gradient(circle at 65% 76%, #f7bfa53d, transparent 42%);
  box-shadow:
    inset -1px -2px 2px #4c94b526,
    inset 1px 1px 2px #fff5;
  pointer-events: none;
}
.story-bubble {
  width: var(--size, 12px);
  height: var(--size, 12px);
  left: var(--x);
  top: var(--y);
  opacity: 0.5;
  animation: bubble-rise var(--duration, 10s) ease-in-out var(--delay, 0s)
    infinite;
}
.story-bubble:nth-child(3n) {
  opacity: 0.25;
  filter: blur(0.5px);
}
.story-bubble:nth-child(7n) {
  width: 31px;
  height: 31px;
  filter: blur(0.4px);
  animation-duration: 14s;
}
.story-trail {
  position: absolute;
  left: 22%;
  top: 19%;
  width: 40%;
  height: 57%;
  pointer-events: none;
}
.story-trail-back {
  z-index: 0;
  opacity: 0.38;
}
.story-trail-front {
  z-index: 2;
  left: 53%;
  top: 55%;
  opacity: 0.65;
}
.story-trail i {
  left: calc(var(--n) * 17%);
  top: calc(var(--n) * 13%);
  width: calc(8px + var(--n) * 2px);
  height: calc(8px + var(--n) * 2px);
  animation: trail-rise 5.5s ease-out both;
  animation-delay: calc(0.2s + var(--n) * 0.13s);
}
.story-trail-front i:nth-child(even) {
  filter: blur(0.5px);
}
.story-burst {
  z-index: 2;
  left: 32%;
  top: 26%;
  width: 8px;
  height: 8px;
  animation: stroke-bubble 1.8s ease-out both;
}
.story-margin-note {
  position: absolute;
  left: 4%;
  top: 15%;
  font-size: 18px;
  line-height: 1.55;
  letter-spacing: 0.23em;
  text-transform: uppercase;
  color: #21495f;
  margin: 0;
}
.story-margin-note:after {
  content: "";
  display: block;
  width: 51px;
  height: 1px;
  margin-top: 23px;
  background: #315f7780;
}
.story-depth-note {
  position: absolute;
  bottom: 7%;
  left: 4.7%;
  color: #eaf6f8;
  font-size: 11px;
  line-height: 1.65;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  margin: 0;
}
.story-depth-note span {
  display: inline-block;
  width: 45px;
  height: 1px;
  background: #eaf6f89c;
  margin-left: 20px;
}
.story-content {
  position: relative;
  max-width: 470px;
}
.story-content h1 {
  font-family: "Cormorant Hero", Georgia, serif;
  font-size: clamp(82px, 7.6vw, 116px);
  font-weight: 400;
  line-height: 0.86;
  letter-spacing: -0.04em;
  margin: 0 0 29px -7px;
}
.story-content h1 > span {
  padding-left: 8%;
  white-space: nowrap;
}
.story-content em {
  font-weight: 400;
  color: #447c99;
}
.story-subtitle {
  font-size: clamp(16px, 1.45vw, 23px);
  letter-spacing: 0.16em;
  line-height: 1.6;
  white-space: nowrap;
  margin: 0 0 32px;
  color: #21495f;
}
.story-copy {
  font-size: 13px;
  line-height: 1.85;
  color: #204458;
  max-width: 375px;
}
.story-copy p {
  margin: 0 0 18px;
}
.story-scroll {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: max-content;
  margin: 55px auto 0;
  gap: 14px;
  font-size: 12px;
  color: #183f56;
  padding: 5px 12px;
}
.story-scroll > span {
  font-size: 40px;
  font-family: "Cormorant Hero", serif;
  line-height: 1;
  animation: invite 4s ease-in-out 2s infinite;
}
@keyframes quiet-entry {
  0% {
    transform: translate(-43px, -43px) rotate(3deg);
    opacity: 0.65;
    animation-timing-function: cubic-bezier(0.35, 0.05, 0.25, 1);
  }
  80% {
    transform: translate(3px, 3px);
    opacity: 1;
    animation-timing-function: ease-out;
  }
  100% {
    transform: none;
    opacity: 1;
  }
}
@keyframes quiet-idle {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-3px) rotate(0.8deg);
  }
}
@keyframes water-light {
  to {
    transform: translate(1%, 1%);
    opacity: 0.6;
  }
}
@keyframes character-light {
  0%,
  100% {
    transform: translate(-8px, -30px);
    opacity: 0.2;
  }
  55% {
    transform: translate(12px, 40px);
    opacity: 0.4;
  }
}
@keyframes bubble-rise {
  0% {
    transform: translate(0, 25px);
    opacity: 0;
  }
  25% {
    opacity: 0.55;
  }
  60% {
    transform: translate(var(--sway), -30px);
    opacity: 0.4;
  }
  100% {
    transform: translate(2px, -100px);
    opacity: 0;
  }
}
@keyframes trail-rise {
  0% {
    transform: translate(0, 12px);
    opacity: 0;
  }
  20% {
    opacity: 0.6;
  }
  100% {
    transform: translate(-18px, -80px);
    opacity: 0;
  }
}
@keyframes stroke-bubble {
  0% {
    opacity: 0;
    transform: translate(0, 0);
  }
  15% {
    opacity: 0.65;
  }
  100% {
    opacity: 0;
    transform: translate(var(--bubble-x), -72px);
  }
}
@keyframes wake-settle {
  0% {
    transform: scale(0.5);
    opacity: 0;
  }
  30% {
    opacity: 0.5;
  }
  100% {
    transform: scale(1.5);
    opacity: 0;
  }
}
@keyframes invite {
  0%,
  65%,
  100% {
    transform: translateY(0);
  }
  35% {
    transform: translateY(5px);
  }
}
.story-hero.is-away * {
  animation-play-state: paused !important;
}
@media (min-width: 1600px) {
  .story-hero {
    padding-right: 8%;
  }
  .story-guide {
    left: 23%;
    width: 580px;
  }
}
@media (max-width: 1250px) {
  .home .header-inner {
    width: calc(100% - 80px);
  }
  .home nav {
    gap: 40px;
  }
  .story-hero {
    padding-left: 61%;
    padding-right: 5%;
    min-height: 900px;
  }
  .story-content h1 {
    font-size: 92px;
  }
  .story-subtitle {
    font-size: 17px;
    letter-spacing: 0.11em;
  }
  .story-guide {
    left: 17%;
    top: 36%;
    width: 450px;
  }
  .story-margin-note {
    font-size: 16px;
  }
  .story-scroll {
    margin-top: 48px;
  }
}
@media (max-width: 1050px) {
  .story-hero {
    padding: 265px 5% 60px 57%;
    min-height: 920px;
  }
  .story-content h1 {
    font-size: 86px;
  }
  .story-guide {
    left: 12%;
    top: 39%;
    width: 430px;
  }
  .story-copy {
    font-size: 13px;
  }
  .story-margin-note {
    font-size: 15px;
    top: 17%;
  }
  .story-subtitle {
    font-size: 16px;
    letter-spacing: 0.08em;
  }
}
@media (max-width: 850px) {
  .home .header-inner {
    width: calc(100% - 48px);
    min-height: 86px;
    gap: 12px;
  }
  .home .header-descriptor {
    font-size: 14px;
  }
  .home nav {
    gap: 25px;
  }
  .story-hero {
    padding-left: 52%;
    padding-top: 280px;
    min-height: 980px;
  }
  .story-content h1 {
    font-size: 76px;
  }
  .story-subtitle {
    font-size: 14px;
    letter-spacing: 0.055em;
  }
  .story-guide {
    left: 8%;
    top: 42%;
    width: 350px;
  }
  .story-margin-note {
    left: 5%;
    font-size: 13px;
  }
  .story-copy {
    font-size: 12px;
  }
  .story-depth-note {
    font-size: 10px;
  }
}
@media (max-width: 600px) {
  .home .header-inner {
    width: calc(100% - 32px);
    min-height: 76px;
    gap: 8px;
  }
  .home .identity img {
    width: 43px;
    height: 34px;
  }
  .home .header-descriptor {
    font-size: 12px;
    white-space: nowrap;
  }
  .home nav {
    gap: 13px;
  }
  .home nav a {
    font-size: 11px;
  }
  .story-hero {
    padding: 475px 28px 42px;
    min-height: 100svh;
    background: #c0e2e5;
  }
  .story-water {
    background-size: auto 100%;
    background-position: 40% top;
  }
  .story-environment:after {
    content: "";
    position: absolute;
    inset: 390px 0 0;
    background: linear-gradient(#c9e7e600, #cbe6e8e8 110px, #a4d0def2);
    z-index: 0;
  }
  .story-rays {
    inset: 10% 0 0;
  }
  .story-guide {
    left: 14%;
    top: 205px;
    width: 285px;
    z-index: 1;
  }
  .story-margin-note {
    top: 127px;
    left: 7%;
    font-size: 10px;
    line-height: 1.8;
    letter-spacing: 0.18em;
  }
  .story-margin-note:after {
    width: 30px;
    margin-top: 12px;
  }
  .story-bubbles {
    left: 8%;
    top: 12%;
    width: 80%;
    height: 40%;
  }
  .story-depth-note {
    display: none;
  }
  .story-content {
    max-width: 410px;
    margin: auto;
  }
  .story-content h1 {
    font-size: 82px;
    margin: 0 0 22px;
    line-height: 0.88;
  }
  .story-subtitle {
    font-size: 16px;
    letter-spacing: 0.075em;
    margin-bottom: 27px;
  }
  .story-content em {
    color: #356b87;
  }
  .story-copy {
    font-size: 13px;
    line-height: 1.8;
  }
  .story-scroll {
    margin-top: 30px;
    gap: 9px;
    font-size: 12px;
  }
}
@media (max-width: 380px) {
  .home .header-inner {
    width: calc(100% - 24px);
    gap: 7px;
  }
  .home .identity img {
    width: 35px;
  }
  .home .header-descriptor {
    font-size: 11px;
  }
  .home nav {
    gap: 10px;
  }
  .home nav a {
    font-size: 10px;
  }
  .story-hero {
    padding-inline: 22px;
    padding-top: 448px;
  }
  .story-guide {
    left: 11%;
    width: 265px;
    top: 198px;
  }
  .story-content h1 {
    font-size: 72px;
  }
  .story-subtitle {
    font-size: 14px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .story-hero *,
  .story-hero *:before,
  .story-hero *:after {
    animation: none !important;
    transition: none !important;
  }
  .story-guide,
  .story-diver,
  .story-swimmer,
  .story-tail,
  .story-pupil {
    transform: none !important;
  }
  .story-diver {
    opacity: 1;
  }
  .story-wake,
  .story-burst {
    display: none;
  }
  .story-bubble {
    opacity: 0.45;
  }
  .story-trail i {
    opacity: 0.4;
  }
}

/* The idle tail rests between brief active strokes; no body deformation. */
.story-hero:not(.is-swimming) .story-tail {
  animation: tail-rest 7s ease-in-out infinite;
}
@keyframes tail-rest {
  0%,
  100% {
    transform: rotate(-1deg);
  }
  50% {
    transform: rotate(1.4deg);
  }
}
/* Final approved composition: calm surface/header, centered invitation. */
.home .site-header {
  z-index: 20;
}
.home .header-inner {
  min-height: 112px;
  width: calc(100% - 120px);
}
.home .identity img {
  width: 67px;
  height: auto;
}
.home nav {
  margin-left: auto;
  gap: 42px;
}
.story-hero {
  width: 100%;
  min-height: max(900px, 100svh);
  padding-top: clamp(300px, 34vh, 390px);
  padding-bottom: 190px;
  background: linear-gradient(#eef9f7, #8bd9e8 50%, #167ca8);
}
.story-water {
  top: 70px;
  background-size: 100% 100%;
  background-position: center;
  mask-image: linear-gradient(transparent, #000 80px);
}
.story-environment:before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 190px;
  background: linear-gradient(
    #f4f8ee,
    #e7f5f2ed 70px,
    #e0f3f46b 130px,
    transparent
  );
  z-index: 3;
}
.story-rays {
  background: radial-gradient(
    ellipse at 80% 48%,
    rgba(225, 247, 247, 0.42),
    transparent 52%
  );
}
.story-depth {
  background: linear-gradient(transparent, rgba(14, 112, 157, 0.2));
}
.story-bubbles {
  top: 22%;
  height: 66%;
}
.story-margin-note {
  left: 6%;
  top: 27%;
  font-size: clamp(16px, 1.3vw, 24px);
  letter-spacing: 0.18em;
  line-height: 1.5;
}
.story-margin-note:after {
  width: 58px;
}
.story-content h1 {
  font-size: clamp(64px, 6.3vw, 112px);
  line-height: 0.93;
}
.story-subtitle {
  font-size: clamp(16px, 1.3vw, 21.6px);
  letter-spacing: 0.18em;
}
.story-copy {
  max-width: 460px;
  font-size: 14px;
  line-height: 1.65;
  color: #163b52;
}
.story-content:before {
  content: "";
  position: absolute;
  inset: -75px -65px -65px;
  background: radial-gradient(
    ellipse,
    rgba(225, 247, 247, 0.28),
    transparent 70%
  );
  z-index: -1;
  pointer-events: none;
}
.story-scroll {
  position: absolute;
  left: 50%;
  bottom: clamp(28px, 5vh, 60px);
  transform: translateX(-50%);
  margin: 0;
  font-size: 16px;
  color: #f1fbf9;
  gap: 12px;
  text-align: center;
}
.story-scroll > span {
  font-size: 36px;
  animation: none;
  transition: transform 0.25s;
}
.story-scroll:hover {
  opacity: 0.85;
}
.story-scroll:hover > span {
  transform: translateY(4px);
}
.home nav a:focus-visible,
.home .identity:focus-visible,
.story-scroll:focus-visible {
  outline: 2px solid #153a52;
  outline-offset: 7px;
  border-radius: 2px;
}
.story-scroll:focus-visible {
  outline-color: #f1fbf9;
}
.story-tail {
  transform-origin: 230px 288px;
}
@keyframes quiet-entry {
  from {
    transform: translate(-32px, -32px) rotate(2deg);
    opacity: 0.65;
  }
  to {
    transform: none;
    opacity: 1;
  }
}
.story-diver {
  animation: quiet-entry 1s cubic-bezier(0.25, 0.1, 0.25, 1) both;
}
@media (max-width: 1250px) {
  .story-hero {
    padding-top: 310px;
    padding-bottom: 190px;
  }
  .story-content h1 {
    font-size: 82px;
  }
  .story-subtitle {
    font-size: 16px;
    letter-spacing: 0.12em;
  }
  .story-margin-note {
    top: 25%;
  }
}
@media (max-width: 1050px) {
  .story-hero {
    padding-top: 300px;
    min-height: 960px;
  }
  .story-content h1 {
    font-size: 78px;
  }
  .story-copy {
    font-size: 14px;
  }
  .story-subtitle {
    font-size: 15px;
    letter-spacing: 0.08em;
  }
  .story-margin-note {
    top: 24%;
  }
}
@media (max-width: 850px) {
  .home .header-inner {
    min-height: 100px;
    width: calc(100% - 64px);
  }
  .home nav {
    gap: 30px;
  }
  .story-hero {
    padding-top: 310px;
    min-height: 1000px;
  }
  .story-content h1 {
    font-size: 72px;
  }
  .story-copy {
    font-size: 13px;
  }
  .story-subtitle {
    font-size: 14px;
    letter-spacing: 0.06em;
  }
  .story-margin-note {
    font-size: 14px;
    top: 23%;
  }
}
@media (max-width: 600px) {
  .home .header-inner {
    min-height: 88px;
    width: calc(100% - 40px);
  }
  .home .identity img {
    width: 51px;
  }
  .home nav {
    gap: 24px;
  }
  .home nav a {
    font-size: 12px;
  }
  .story-hero {
    padding: 500px 28px 168px;
    min-height: 100svh;
  }
  .story-water {
    top: 50px;
    background-size: auto 100%;
    mask-image: linear-gradient(transparent, #000 60px);
  }
  .story-environment:before {
    height: 150px;
    background: linear-gradient(#f4f8ee, #e7f5f2ee 55px, transparent);
  }
  .story-environment:after {
    background: linear-gradient(
      transparent,
      #cbe6e8e8 140px,
      #afd6e0ed 67%,
      #247fa9e6
    );
    inset: 400px 0 0;
  }
  .story-margin-note {
    top: 149px;
    left: 7%;
    font-size: 13px;
  }
  .story-margin-note:after {
    width: 50px;
    margin-top: 15px;
  }
  .story-guide {
    top: 232px;
  }
  .story-bubbles {
    top: 24%;
    height: 33%;
  }
  .story-content h1 {
    font-size: 78px;
  }
  .story-subtitle {
    font-size: 15px;
    letter-spacing: 0.09em;
  }
  .story-copy {
    font-size: 14px;
    line-height: 1.65;
  }
  .story-scroll {
    bottom: 34px;
    font-size: 15px;
  }
  .story-content:before {
    display: none;
  }
}
@media (max-width: 380px) {
  .home .header-inner {
    width: calc(100% - 32px);
  }
  .home nav {
    gap: 19px;
  }
  .home nav a {
    font-size: 11px;
  }
  .story-hero {
    padding-top: 470px;
    padding-inline: 22px;
  }
  .story-guide {
    top: 220px;
  }
  .story-content h1 {
    font-size: 69px;
  }
  .story-subtitle {
    font-size: 14px;
    letter-spacing: 0.06em;
  }
}
/* A blue water wash keeps the centered invitation legible over caustics. */
.story-depth {
  background:
    radial-gradient(
      ellipse at 50% 100%,
      rgba(13, 94, 139, 0.58),
      transparent 45%
    ),
    linear-gradient(transparent, rgba(14, 112, 157, 0.2));
}
/* Rendered approved character: retain its native pose and aspect ratio. */
.story-character {
  width: 100%;
  height: auto;
  transform: none;
}
.story-guide {
  width: clamp(340px, 34vw, 510px);
  left: 24%;
  top: 30%;
  transform: none;
}
.story-diver {
  --entry-x: calc(-24vw - 440px);
  --entry-y: -360px;
  animation: none;
  transform: translate3d(var(--entry-x), var(--entry-y), 0px);
}
@media (max-width: 600px) {
  .story-diver { --entry-x: -240px; --entry-y: -210px; }
}
@media (max-width: 1250px) {
  .story-guide {
    width: 390px;
    left: 18%;
    top: 34%;
  }
}
@media (max-width: 1050px) {
  .story-guide {
    width: 350px;
    left: 13%;
    top: 37%;
  }
}
@media (max-width: 850px) {
  .story-guide {
    width: 300px;
    left: 9%;
    top: 39%;
  }
}
@media (max-width: 600px) {
  .story-guide {
    width: 240px;
    left: 22%;
    top: 221px;
  }
}
@media (max-width: 380px) {
  .story-guide {
    width: 220px;
    left: 20%;
    top: 218px;
  }
}

/* Original PNG stays in layout and is the neutral/reduced-motion fallback. */
.story-articulation {
  position: absolute;
  left: -6.060606%;
  top: -5.797101%;
  width: 112.121212%;
  height: 111.594203%;
  pointer-events: none;
}
.story-articulation[hidden] { display: none; }
@media (prefers-reduced-motion: reduce) {
  .story-articulation { display: none !important; }
  img.fish-character { visibility: visible !important; }
}
/* Keep the existing placement/motion, with a 20% smaller character. */
.story-diver { aspect-ratio: 528 / 552; opacity: 1; }
.story-swimmer {
  position: absolute;
  width: 56.32%;
  left: 21.84%;
  top: 21.84%;
  scale: none;
  transform-origin: center;
}
.story-margin-note { color: #FFFFFF; }
.story-margin-note:after { background: #FFFFFF; }

.story-hero.has-arrived .story-swimmer { animation-play-state: running; }

.cursor-bubbles {
  position: fixed;
  inset: 0;
  z-index: 20;
  pointer-events: none;
  overflow: hidden;
}
.cursor-bubbles i {
  position: absolute;
  pointer-events: none;
  border: 1px solid rgb(218 249 255 / 30%);
  border-radius: 50%;
  background: radial-gradient(circle at 28% 24%, rgb(255 255 255 / 48%) 0 6%, transparent 21%);
  box-shadow: inset -1px -1px 2px rgb(185 239 250 / 10%), 0 0 3px rgb(222 251 255 / 10%);
  animation: cursor-bubble-rise 2s ease-out both;
}
@keyframes cursor-bubble-rise {
  0% { opacity: 0; transform: translate(0, 0) scale(.92); }
  15% { opacity: .65; }
  100% { opacity: 0; transform: translate(var(--drift), calc(-1 * var(--rise))) scale(1.08); }
}
@media (prefers-reduced-motion: reduce), (pointer: coarse), (hover: none) {
  .cursor-bubbles { display: none; }
}
