:root {
  --frame: linear-gradient(to bottom right, hsl(332 100% 78%), hsl(336 82% 60%));
  --entry-frame: linear-gradient(to bottom right, hsl(335 100% 89%), hsl(333 85% 75%));
  --frame-dark: #c97d95;
  --ink: #3b2530;
  --polaroid: #fffdf8;
  --tape: rgba(255, 244, 196, 0.75);
  --bg-blue: #5b8fd6;
}

* { box-sizing: border-box; }

html, body { margin: 0; }

body {
  min-height: 100vh;
  color: var(--ink);
  font-family: "Kalam", "Comic Sans MS", cursive;
  font-size: 1.1rem;
  line-height: 1.6;
}

#bg {
  --bg-h: max(156.25vw, 230vh);
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--bg-h);
  z-index: -1;
  background-color: #f58fc8;
  background-image: url("images/web/newestBackground.webp");
  background-size: cover;
  background-position: center top;
  will-change: transform;
  pointer-events: none;
}

@supports (animation-timeline: scroll()) {
  #bg {
    animation: bg-pan linear both;
    animation-timeline: scroll(root block);
  }
  @keyframes bg-pan {
    from { transform: translate3d(0, 0, 0); }
    to   { transform: translate3d(0, calc(100vh - var(--bg-h)), 0); }
  }
}

@media (prefers-reduced-motion: reduce) {
  #bg { animation: none; transform: none !important; height: 100vh; }
}

.cover {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 5rem 1rem 3.5rem;
  color: #000;
}

.title-box,
.subtitle-box {
  position: relative;
  background: var(--entry-frame);
  border-radius: 3px;
  box-shadow: 3px 6px 0 rgba(0, 0, 0, 0.15);
}

.title-box::after,
.subtitle-box::after {
  content: "";
  position: absolute;
  border: 2px solid rgba(255, 255, 255, 0.75);
  border-radius: 2px;
  pointer-events: none;
  z-index: -1;
}

.title-box {
  padding: 1.4rem 2.4rem 1.9rem;
  transform: rotate(-2deg);
}
.title-box::after { inset: 10px; }

.subtitle-box {
  z-index: 2;
  margin-top: -1.2rem;
  margin-left: clamp(2rem, 18vw, 12rem);
  padding: 0.75rem 1.9rem 0.9rem;
  transform: rotate(2.5deg);
  background: linear-gradient(to top left, hsl(335 100% 89%), hsl(333 85% 75%));
}
.subtitle-box::after { inset: 5px; }

.cover h1,
.cover p {
  font-family: "Caveat Brush", "Caveat", cursive;
  font-weight: 400;
  margin: 0;
  color: #000;
  text-shadow: 1px 2px 0 rgba(255, 255, 255, 0.45);
}

.cover h1 {
  font-size: clamp(2.8rem, 9vw, 5rem);
  line-height: 1;
}

.cover p { font-size: clamp(1.15rem, 3.5vw, 1.5rem); }

.book {
  max-width: 780px;
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
  display: flex;
  flex-direction: column;
  gap: 7.5rem;
}

.entry {
  position: relative;
  background: var(--entry-frame);
  padding: 2.25rem 2rem 2rem;
  border-radius: 3px;
  box-shadow: 3px 6px 0 rgba(0, 0, 0, 0.15);
  transform: rotate(-1.2deg);
  display: flow-root;
  align-self: center;
  width: max(100%, min(calc(100% * var(--wscale, 1)), calc(var(--page-w, 100vw) - 2.5rem)));
}

.entry::after {
  content: "";
  position: absolute;
  inset: 10px;
  border: 2px dashed rgba(255, 255, 255, 0.7);
  border-radius: 2px;
  pointer-events: none;
  z-index: -1;
}

.entry:nth-child(even) { transform: rotate(1.4deg); }
.entry:nth-child(3n)   { transform: rotate(-0.5deg); }

.tape {
  position: absolute;
  top: -14px;
  left: 50%;
  width: 120px;
  height: 30px;
  background: var(--tape-color, var(--tape));
  transform: translateX(-50%) rotate(-3deg);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
  z-index: 2;
}

.entry:nth-child(even) .tape {
  left: auto;
  right: 18px;
  transform: rotate(8deg);
}

.entry h2 {
  font-family: "Dancing Script", cursive;
  font-weight: 600;
  font-size: 2.3rem;
  line-height: 1.1;
  margin: 0;
}

.entry time {
  display: inline-block;
  margin: 0.25rem 0 1rem;
  font-family: "Dancing Script", cursive;
  font-weight: 600;
  font-size: 1.35rem;
  color: #4a1830;
}

.entry p { margin: 0; }
.entry p.center { text-align: center; margin-bottom: 1.3em; }

.photos {
  display: flex;
  justify-content: center;
  gap: 1.25rem;
  margin: 0.5rem 0 1.5rem;
  flex-wrap: wrap;
}

.photo {
  margin: 0;
  background: var(--polaroid);
  padding: 10px 10px 0;
  width: 100%;
  max-width: 260px;
  box-shadow: 2px 4px 8px rgba(0, 0, 0, 0.2);
  transform: rotate(2deg);
  position: relative;
  z-index: 1;
}

.photo:nth-child(2) { transform: rotate(-3deg); }

.photo::before,
.photo::after {
  content: "";
  position: absolute;
  width: 56px;
  height: 18px;
  background: var(--tape);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
  z-index: 2;
  pointer-events: none;
}

.photo::before {
  background: var(--tape-1, var(--tape));
  top: 4px;
  left: -16px;
  transform: rotate(-40deg);
}

.photo::after {
  background: var(--tape-2, var(--tape));
  bottom: 4px;
  right: -16px;
  transform: rotate(-40deg);
}

.photos:has(.photo:nth-child(2)) .photo { max-width: calc(50% - 0.7rem); }

.photo img,
.photo .placeholder {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.photo .placeholder {
  background: #d9d4cc;
  color: #8a837a;
  display: grid;
  place-items: center;
}

.photo figcaption {
  font-family: "Caveat", cursive;
  font-size: 1.3rem;
  text-align: center;
  padding: 0.35rem 0 0.5rem;
}

.photo.float-right {
  float: right;
  width: 42%;
  max-width: 280px;
  margin: 0 0 1rem 1.5rem;
  transform: rotate(var(--tilt, 3deg));
}

.photo.float-left {
  float: left;
  width: 42%;
  max-width: 280px;
  margin: 0.5rem 1.5rem 1rem 0;
  transform: rotate(var(--tilt, -3deg));
}

.photo.float-left img {
  aspect-ratio: auto;
}

.photo.float-right:not(:has(figcaption)),
.photo.float-left:not(:has(figcaption)) {
  padding-bottom: 28px;
}

.photo.float-right img {
  aspect-ratio: auto;
}

.photo-date {
  font-size: 0.8em;
  color: #8a837a;
  margin-left: 0.25em;
}

.sign-off {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 1.25rem 12rem;
  text-align: center;
  color: #fff;
  font-family: "Caveat", cursive;
  font-size: 1.8rem;
  line-height: 1.3;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.sign-off-box {
  position: relative;
  width: 100%;
  max-width: 940px;
  padding: 2.5rem 3.5rem 2.75rem;
  border: 4px dashed #fff;
  border-radius: 4px;
  background: var(--entry-frame);
  box-shadow: 3px 6px 0 rgba(0, 0, 0, 0.15);
  color: #000;
  text-shadow: none;
  overflow-wrap: break-word;
}

.sign-off p { margin: 0; }
.sign-off-text p + p { margin-top: 1.3em; }

.sign-off-text p + p.aka { margin-top: 0; font-style: italic; opacity: 0.6; }

.sign-off-text {
  overflow: hidden;
  transition: filter 1.4s ease, opacity 1.4s ease, max-height 1.6s cubic-bezier(0.45, 0, 0.2, 1);
}

.sign-off-box.locked .sign-off-text {
  max-height: 11em;
  filter: blur(6px);
  opacity: 0.9;
  user-select: none;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(#000 55%, transparent);
          mask-image: linear-gradient(#000 55%, transparent);
}

.sign-off-lock {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  padding: 1.5rem;
  font-family: "Caveat Brush", "Caveat", cursive;
  text-shadow: 1px 2px 0 rgba(255, 255, 255, 0.4);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.sign-off-box:not(.locked) .sign-off-lock {
  opacity: 0;
  transform: scale(0.92);
  pointer-events: none;
}

.lock-label { font-size: 1em; }
.lock-countdown { font-size: 1.5em; line-height: 1.1; }
.lock-countdown .part { white-space: nowrap; }

.sign-off-box.no-anim .sign-off-text,
.sign-off-box.no-anim .sign-off-lock { transition: none; }

.lock-skip {
  margin-top: 0.9rem;
  padding: 0.35rem 1rem;
  font: inherit;
  font-size: 0.6em;
  color: #fff;
  background: rgba(255, 255, 255, 0.15);
  border: 2px solid #fff;
  border-radius: 999px;
  cursor: pointer;
  text-shadow: none;
}
.lock-skip:hover { background: rgba(255, 255, 255, 0.3); }

@media (max-width: 600px) {
  .sign-off { padding-bottom: 10rem; font-size: 1.55rem; }
  .sign-off-box { padding: 1.6rem 1.5rem 1.8rem; }
}



@media (max-width: 480px) {
  .entry { padding: 2rem 1.4rem 1.6rem; }
  .entry h2 { font-size: 2rem; }
  .photos:has(.photo:nth-child(2)) .photo { max-width: 100%; }
  .photo.float-right { width: 48%; margin-left: 1rem; }
  .photo.float-left { width: 48%; margin-right: 1rem; }
}

body.loading { overflow: hidden; }

#loader {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  background: var(--frame);
}

#loader-edge {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: #fff6fa;
  display: none;
}

#loader::after,
#loader-edge::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 0.55 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
  opacity: 0.45;
  pointer-events: none;
}
#loader-edge::after { mix-blend-mode: multiply; opacity: 0.18; }

.loader-inner {
  position: relative;
  z-index: 1;
  width: min(320px, 70vw);
  text-align: center;
  will-change: transform;
}

.loader-text {
  font-family: "Caveat Brush", "Caveat", cursive;
  font-size: 3rem;
  line-height: 1;
  color: #fff;
  margin: 0 0 0.75rem;
  text-shadow: 2px 3px 0 rgba(130, 20, 70, 0.35);
}

.loader-funny {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  margin: 0.6rem 0 0;
  font-family: "Caveat Brush", "Caveat", cursive;
  font-size: 1.5rem;
  color: #fff;
  text-shadow: 2px 2px 0 rgba(130, 20, 70, 0.35);
}
.loader-funny[hidden] { display: none; }

.loader-bar {
  height: 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.3);
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(130, 20, 70, 0.25);
}

.loader-fill {
  height: 100%;
  width: 0%;
  background: #fff;
  border-radius: inherit;
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.9);
}

#confetti {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1001;
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  #loader { transition: opacity 0.5s ease; }
  #loader.done { opacity: 0; }
}

.confetti-btn {
  position: fixed;
  right: calc(1.25rem + env(safe-area-inset-right, 0px));
  bottom: calc(1.25rem + env(safe-area-inset-bottom, 0px));
  z-index: 900;
  width: 68px;
  height: 68px;
  padding: 0;
  border: none;
  border-radius: 4px;
  background: var(--frame);
  box-shadow: 3px 5px 0 rgba(0, 0, 0, 0.18);
  display: grid;
  place-items: center;
  cursor: pointer;
  transform: rotate(-4deg);
  transition: transform 0.2s cubic-bezier(0.3, 1.6, 0.5, 1), box-shadow 0.2s ease;
}

.confetti-btn::after {
  content: "";
  position: absolute;
  inset: 5px;
  border: 2px solid rgba(255, 255, 255, 0.75);
  border-radius: 2px;
  pointer-events: none;
}

.confetti-btn img {
  width: 40px;
  height: 40px;
  display: block;
  pointer-events: none;
}

.confetti-btn:hover { transform: rotate(0deg) scale(1.08); }
.confetti-btn:active { transform: scale(0.92); box-shadow: 1px 2px 0 rgba(0, 0, 0, 0.18); }
.confetti-btn:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }

.confetti-btn.pop { animation: btn-pop 0.45s cubic-bezier(0.3, 1.6, 0.5, 1); }
@keyframes btn-pop {
  0%   { transform: scale(0.9) rotate(0deg); }
  50%  { transform: scale(1.18) rotate(-10deg); }
  100% { transform: scale(1) rotate(-4deg); }
}

.photo {
  transition:
    translate 0.25s cubic-bezier(0.3, 1.5, 0.5, 1),
    scale 0.25s cubic-bezier(0.3, 1.5, 0.5, 1),
    box-shadow 0.25s ease;
}

.photo:has(img) { cursor: var(--photo-cursor, zoom-in); }

@media (hover: hover) {
  .photo:has(img):hover {
    translate: 0 -6px;
    scale: 1.05;
    box-shadow: 4px 12px 18px rgba(0, 0, 0, 0.28);
    z-index: 3;
  }
}

.photo:has(img):focus-visible { outline: 3px solid #fff; outline-offset: 4px; }


.lightbox {
  position: fixed;
  inset: 0;
  z-index: 950;
  display: grid;
  place-items: center;
  padding: 1.5rem;
  cursor: var(--close-cursor, zoom-out);
}

.lightbox[hidden] { display: none; }

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(70, 20, 50, 0.25);
  -webkit-backdrop-filter: blur(8px);
          backdrop-filter: blur(8px);
  opacity: 0;
  transition: opacity 0.35s ease;
}

.lightbox.open .lightbox-backdrop { opacity: 1; }

.lightbox-card {
  position: relative;
  margin: 0;
  background: var(--polaroid);
  padding: 14px 14px 0;
  max-width: min(620px, 88vw);
  box-shadow: 4px 14px 30px rgba(0, 0, 0, 0.35);
  transform: rotate(-1deg);
}

.lightbox-card:has(figcaption[hidden]) { padding-bottom: 14px; }

.lightbox-card img {
  display: block;
  width: auto;
  height: auto;
  object-fit: cover;
  max-width: 100%;
  max-height: 66vh;
}

.lightbox-card figcaption {
  font-family: "Caveat", cursive;
  font-size: 1.8rem;
  text-align: center;
  padding: 0.4rem 0 0.6rem;
  color: var(--ink);
}

.lightbox-card::before,
.lightbox-card::after {
  content: "";
  position: absolute;
  width: 80px;
  height: 24px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
  z-index: 2;
  pointer-events: none;
}

.lightbox-card::before {
  background: var(--tape-1, var(--tape));
  top: 6px;
  left: -22px;
  transform: rotate(-40deg);
}

.lightbox-card::after {
  background: var(--tape-2, var(--tape));
  bottom: 6px;
  right: -22px;
  transform: rotate(-40deg);
}

.scribbles-set {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  padding: 0 1rem;
  margin: 5rem 0 13rem;
}

.scribble-half {
  position: relative;
  width: min(1280px, 100%);
  pointer-events: none;
}

.scribble-half img {
  display: block;
  width: 100%;
  height: auto;
}

.entry.video-entry {
  width: min(1280px, 100%);
  text-align: center;
}

.video-entry h2 { margin-bottom: 1.25rem; }

.video-box {
  position: relative;
  z-index: 1;
  aspect-ratio: 16 / 9;
  width: 100%;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.45);
  border: 3px dashed rgba(255, 255, 255, 0.9);
  border-radius: 6px;
  color: #8a5a72;
  overflow: hidden;
}

.video-box video,
.video-entry > video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 6px;
}

.video-entry > video { aspect-ratio: 16 / 9; height: auto; }

.video-entry .video-desc { margin: 1.25rem auto 0; max-width: 60ch; }

.flower {
  position: absolute;
  width: var(--size);
  height: var(--size);
  transform: translate(-50%, -50%) rotate(var(--rot));
  filter: drop-shadow(1px 2px 1.5px rgba(120, 20, 70, 0.3));
  pointer-events: none;
  z-index: 0;
}
.flower.tiny { filter: drop-shadow(0.5px 1px 0.8px rgba(120, 20, 70, 0.3)); }

.flower-ink {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--petal);
  -webkit-mask: var(--shape) center / contain no-repeat;
          mask: var(--shape) center / contain no-repeat;
}

.flower.v1 { --shape: url("images/web/FL1.webp"); }
.flower.v2 { --shape: url("images/web/FL2.webp"); }

.flower.v1 { --back: url("images/web/FL1-sticker.webp"); }
.flower.v2 { --back: url("images/web/FL2-sticker.webp"); }
.flower-back {
  position: absolute;
  inset: -10%;
  background: #fff;
  -webkit-mask: var(--back) center / contain no-repeat;
          mask: var(--back) center / contain no-repeat;
}
.flower.sticker .flower-ink { position: relative; }

@media (max-width: 600px) {
  .entry { transform: rotate(-0.3deg); }
  .entry:nth-child(even) { transform: rotate(0.35deg); }
  .entry:nth-child(3n) { transform: rotate(-0.15deg); }
}

html, body { overflow-x: clip; }

html { scrollbar-width: none; }
html::-webkit-scrollbar { display: none; }

.keepsakes {
  --ks: clamp(88px, 22vw, 210px);
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, var(--ks));
  justify-content: center;
  align-items: start;
  column-gap: clamp(24px, 6vw, 80px);
  row-gap: clamp(2.6rem, 7vw, 5rem);
  width: 100%;
  padding: 0 0.5rem;
}

.keepsake {
  all: unset;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  width: var(--ks);
  cursor: var(--photo-cursor, zoom-in);
  -webkit-tap-highlight-color: transparent;
}
.keepsake:focus-visible .ks-art { outline: 3px solid #fff; outline-offset: 6px; }

.ks-art {
  position: relative;
  display: grid;
  place-items: center;
  width: var(--ks);
  height: var(--ks);
  transition: transform 0.25s cubic-bezier(0.3, 1.5, 0.5, 1);
}
@media (hover: hover) {
  .keepsake:hover .ks-art { transform: translateY(-6px) scale(1.04) rotate(-1deg); }
  .keepsake[data-open="ks-letter"]:hover .ks-art { transform: none; }
  .keepsake[data-open="ks-letter"]:hover .envelope { transform: translateY(-0.6em) scale(1.05) rotate(0.5deg); }
}
.keepsake .envelope { transition: transform 0.25s cubic-bezier(0.3, 1.5, 0.5, 1); }

.ks-label {
  font-family: "Caveat Brush", "Caveat", cursive;
  font-size: clamp(1rem, 3.4vw, 1.6rem);
  line-height: 1.1;
  color: #fff;
  text-align: center;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
  white-space: nowrap;
}

.notebook-cover {
  width: calc(var(--ks) * 0.8);
  justify-self: center;
  place-items: start center;
  padding: 18% 10% 0 10%;
  box-sizing: border-box;
  background: linear-gradient(160deg, hsl(335 95% 82%), hsl(332 80% 68%));
  border-radius: 4px 10px 10px 4px;
  box-shadow: 3px 6px 0 rgba(0, 0, 0, 0.15), inset -6px 0 10px rgba(255, 255, 255, 0.18);
  transform: rotate(-2deg);
  font-size: calc(var(--ks) / 12);
}
.notebook-cover .nb-cover-title {
  font-family: "Caveat Brush", "Caveat", cursive;
  font-size: 1.55em;
  line-height: 1.05;
  color: #000;
  text-align: center;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.45);
}

.spiral {
  position: absolute;
  top: 3%;
  bottom: 3%;
  left: -0.55em;
  width: 1.6em;
  display: flex;
  flex-direction: column;
  justify-content: space-evenly;
  pointer-events: none;
  z-index: 3;
}
.spiral .ring {
  position: relative;
  height: 0.42em;
}
.spiral .ring::before {
  content: "";
  position: absolute;
  left: 0.9em;
  top: 50%;
  width: 0.42em;
  height: 0.42em;
  margin-top: -0.21em;
  border-radius: 50%;
  background: rgba(70, 20, 45, 0.55);
  box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.4);
}
.spiral .ring::after {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 1.25em;
  height: 0.3em;
  margin-top: -0.15em;
  border-radius: 0.2em;
  background: linear-gradient(to bottom, #fbfbfd, #b4b8c0 45%, #7d828c 60%, #e9ebf0);
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.35);
  transform: rotate(-10deg);
}

.video-icon {
  width: calc(var(--ks) * 0.86);
  height: calc(var(--ks) * 0.86);
  justify-self: center;
  border-radius: 22%;
  background: linear-gradient(150deg, hsl(335 95% 84%), hsl(332 80% 68%));
  box-shadow: 3px 6px 0 rgba(0, 0, 0, 0.15), inset 0 0 0 calc(var(--ks) * 0.03) rgba(255, 255, 255, 0.6);
  transform: rotate(1.5deg);
}
.play-tri {
  width: 0;
  height: 0;
  margin-left: 8%;
  border-top: calc(var(--ks) * 0.15) solid transparent;
  border-bottom: calc(var(--ks) * 0.15) solid transparent;
  border-left: calc(var(--ks) * 0.24) solid #fff;
  filter: drop-shadow(1px 2px 0 rgba(120, 20, 70, 0.3));
}

.env-wrap { position: relative; }
.env-box { position: relative; display: block; }
.keepsake .env-wrap { font-size: calc(var(--ks) / 10.5); }
.env-wrap.big { font-size: min(5.1vw, 52px); }

.envelope {
  position: relative;
  display: block;
  width: 10em;
  height: 6.6em;
  perspective: 40em;
  transform: rotate(2deg);
}
.envelope > span { position: absolute; inset: 0; display: block; }

.env-back {
  background: linear-gradient(hsl(335 70% 74%), hsl(332 70% 68%));
  border-radius: 0.35em;
  box-shadow: 0.08em 0.16em 0 rgba(0, 0, 0, 0.15);
  z-index: 0;
}

.env-paper {
  inset: 0.5em 0.6em auto 0.6em !important;
  height: 5.8em;
  border-radius: 0.15em;
  background:
    repeating-linear-gradient(to bottom, transparent 0 0.62em, rgba(200, 80, 130, 0.3) 0.62em 0.68em),
    linear-gradient(hsl(335 100% 93%), hsl(333 90% 88%));
  z-index: 2 !important;
  transition: transform 0.75s cubic-bezier(0.3, 0.9, 0.3, 1) 0.5s;
}

.env-pocket { z-index: 3; filter: drop-shadow(0 -0.04em 0.06em rgba(120, 30, 70, 0.18)); }
.env-side {
  position: absolute;
  inset: 0;
  border-radius: 0.35em;
  background: linear-gradient(hsl(335 95% 87%), hsl(333 85% 81%));
  clip-path: polygon(0 0, 50% 54%, 100% 0, 100% 100%, 0 100%);
}
.env-fold { z-index: 3; filter: drop-shadow(0 -0.07em 0.08em rgba(120, 30, 70, 0.28)); }
.env-bottom {
  position: absolute;
  inset: 0;
  border-radius: 0.35em;
  background: linear-gradient(hsl(335 95% 85%), hsl(333 85% 77%));
  clip-path: polygon(0 100%, 50% 46%, 100% 100%);
}
.env-flap-wrap {
  z-index: 4;
  transform-origin: 50% 0;
  filter: drop-shadow(0 0.09em 0.1em rgba(120, 30, 70, 0.32));
  transition: transform 0.6s ease-in-out, z-index 0s linear 0.3s;
}
.env-flap {
  position: absolute;
  inset: 0;
  border-radius: 0.35em 0.35em 0 0;
  background: linear-gradient(hsl(335 90% 82%), hsl(333 80% 74%));
  clip-path: polygon(0 0, 100% 0, 50% 58%);
}
.env-seal {
  position: absolute;
  left: 50%;
  top: 58%;
  width: 1.5em;
  height: 1.5em;
  transform: translate(-50%, -62%);
  background: url("images/web/Heart.webp") center / contain no-repeat;
  filter: drop-shadow(0 0.05em 0.08em rgba(100, 20, 50, 0.35));
}
body.letter-unlocked .env-seal { animation: seal-glow 1.6s ease-in-out infinite; }
@keyframes seal-glow { 50% { filter: drop-shadow(0 0 0.3em #fff) drop-shadow(0 0.05em 0.08em rgba(100, 20, 50, 0.35)); } }

.envelope.opening .env-flap-wrap { transform: rotateX(180deg); z-index: 1; }
.envelope.opening .env-seal { opacity: 0; transition: opacity 0.2s; }
.envelope.opening .env-paper { transform: translateY(-62%); }

.ks-modal {
  position: fixed;
  inset: 0;
  z-index: 960;
}
.ks-modal[hidden] { display: none; }
#ks-player { z-index: 970; }

.ks-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(70, 20, 50, 0.28);
  -webkit-backdrop-filter: blur(8px);
          backdrop-filter: blur(8px);
  opacity: 0;
  transition: opacity 0.35s ease;
  cursor: var(--default-cursor, auto);
}
.ks-modal.open .ks-backdrop { opacity: 1; }

.ks-stage {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 1.25rem;
  cursor: var(--default-cursor, auto);
}
.ks-stage > * { grid-area: 1 / 1; cursor: var(--default-cursor, auto); }

.ks-close {
  position: absolute;
  top: 1.6rem;
  right: 1.8rem;
  z-index: 5;
  width: 3.4rem;
  height: 3.4rem;
  border: 3px solid #fff;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  font: 400 2.5rem/1 "Caveat Brush", "Caveat", cursive;
  cursor: var(--touch-cursor, pointer);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}
.ks-close:hover { background: rgba(255, 255, 255, 0.35); }

.ks-panel h3 {
  margin: 0;
  font-family: "Caveat Brush", "Caveat", cursive;
  font-weight: 400;
  color: #000;
  text-align: center;
}
.soon {
  font-family: "Caveat Brush", "Caveat", cursive;
  font-size: 1.4rem;
  color: rgba(80, 20, 50, 0.6);
}

.nb-big {
  position: relative;
  width: min(1000px, 92vw);
  max-height: 90vh;
  box-sizing: border-box;
  padding: 1.6rem 2rem 1.2rem 3.6rem;
  border-radius: 8px 14px 14px 8px;
  background: linear-gradient(160deg, hsl(335 100% 92%), hsl(333 85% 80%));
  box-shadow: 4px 10px 0 rgba(0, 0, 0, 0.15);
  font-size: 22px;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}
.nb-head h3 { font-size: clamp(1.6rem, 3.4vw, 2.4rem); line-height: 1.1; }
.nb-intro {
  margin: 0.15rem 0 0;
  text-align: center;
  font-family: "Caveat", cursive;
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  color: rgba(40, 10, 25, 0.75);
}
.nb-pages { min-height: 0; }
.nb-page {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.1rem 1.4rem;
}
.nb-page[hidden] { display: none; }

.clip {
  all: unset;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  cursor: var(--photo-cursor, zoom-in);
}
.clip-screen {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.55);
  box-shadow: 0 0 0 4px #fff, 2px 5px 8px rgba(0, 0, 0, 0.18);
  transition: transform 0.2s cubic-bezier(0.3, 1.5, 0.5, 1);
}
.clip.empty .clip-screen { box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.9); border: 2px dashed rgba(200, 80, 130, 0.45); }
.clip-screen video { width: 100%; height: 100%; object-fit: cover; display: block; }
@media (hover: hover) { .clip:hover .clip-screen { transform: translateY(-3px) scale(1.02); } }
.play-badge {
  position: absolute;
  width: 3.2rem;
  height: 3.2rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.85);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}
.play-badge::after {
  content: "";
  position: absolute;
  left: 54%;
  top: 50%;
  transform: translate(-50%, -50%);
  border-top: 0.65rem solid transparent;
  border-bottom: 0.65rem solid transparent;
  border-left: 1rem solid hsl(335 80% 60%);
}
.clip-title {
  font-family: "Caveat", cursive;
  font-size: 1.25rem;
  color: rgba(40, 10, 25, 0.8);
  text-align: center;
}

.nb-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.2rem;
  font-family: "Caveat Brush", "Caveat", cursive;
  font-size: 1.4rem;
  color: rgba(40, 10, 25, 0.75);
}
.nb-nav[hidden] { display: none; }
.nb-nav button {
  all: unset;
  width: 2.4rem;
  height: 2.4rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.6);
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
}
.nb-nav button:disabled { opacity: 0.3; cursor: default; }
.nb-nav button:not(:disabled):hover { background: #fff; }

.montage-big,
.player-big {
  width: min(1100px, 94vw);
  box-sizing: border-box;
  padding: 1.2rem 1.4rem 1rem;
  border-radius: 12px;
  background: linear-gradient(160deg, hsl(335 100% 92%), hsl(333 85% 80%));
  box-shadow: 4px 10px 0 rgba(0, 0, 0, 0.15);
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}
.montage-big h3 { font-size: clamp(1.6rem, 3.4vw, 2.4rem); }
.montage-video,
.player-big video {
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: 72vh;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.55);
  overflow: hidden;
}
.player-big video { background: #000; }
.montage-video video { width: 100%; height: 100%; display: block; background: #000; }
.montage-desc,
.player-title {
  margin: 0;
  text-align: center;
  font-family: "Caveat", cursive;
  font-size: clamp(1.15rem, 2.2vw, 1.5rem);
  color: rgba(40, 10, 25, 0.8);
}

.letter-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.6rem;
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.letter-stage.letter-out { opacity: 0; transform: translateY(40px) scale(0.92); pointer-events: none; }
.letter-stage .envelope { cursor: var(--touch-cursor, pointer); }
body:not(.letter-unlocked) .letter-stage .envelope,
body:not(.letter-unlocked) .keepsake[data-open="ks-letter"] .envelope { cursor: var(--no-cursor, not-allowed); }

.env-status {
  text-align: center;
  font-family: "Caveat Brush", "Caveat", cursive;
  color: #fff;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
}
.env-status p { margin: 0; }
.env-status .lock-label { font-size: clamp(1.2rem, 3vw, 1.7rem); }
.env-status .lock-countdown { font-size: clamp(1.7rem, 4.6vw, 2.6rem); line-height: 1.1; }
.env-status .lock-countdown .part { white-space: nowrap; }
.env-ready { display: none; font-size: clamp(1.4rem, 3.6vw, 2rem); }
body.letter-unlocked .env-locked { display: none; }
body.letter-unlocked .env-ready { display: block; }
.env-status .lock-skip {
  margin-top: 0.8rem;
  padding: 0.35rem 1rem;
  font: inherit;
  font-size: 1rem;
  color: #fff;
  background: rgba(255, 255, 255, 0.15);
  border: 2px solid #fff;
  border-radius: 999px;
  cursor: pointer;
  text-shadow: none;
}

.letter-sheet {
  --lh: 2.15rem;
  width: min(760px, 92vw);
  height: min(88vh, 1100px);
  filter: drop-shadow(4px 10px 0 rgba(0, 0, 0, 0.15));
}
.letter-sheet[hidden] { display: none; }
.letter-paper {
  height: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
  border-radius: 6px;
  background:
    linear-gradient(to right, transparent 4.2rem, rgba(225, 80, 130, 0.55) 4.2rem, rgba(225, 80, 130, 0.55) calc(4.2rem + 2px), transparent calc(4.2rem + 2px)),
    repeating-linear-gradient(to bottom, transparent 0 calc(var(--lh) - 1px), rgba(200, 90, 140, 0.32) calc(var(--lh) - 1px) var(--lh)),
    linear-gradient(170deg, hsl(335 100% 95%), hsl(333 95% 89%));
  background-attachment: local, local, local;
  -webkit-mask: radial-gradient(circle at 2rem 50%, transparent 0.55rem, #000 0.62rem) 0 1rem / 100% 4.3rem repeat-y;
          mask: radial-gradient(circle at 2rem 50%, transparent 0.55rem, #000 0.62rem) 0 1rem / 100% 4.3rem repeat-y;
  scrollbar-width: thin;
  scrollbar-color: rgba(200, 80, 130, 0.5) transparent;
}
.letter-text {
  padding: calc(var(--lh) * 2) 2.2rem calc(var(--lh) * 2) 5.2rem;
  font-family: "Caveat", cursive;
  font-size: 1.7rem;
  line-height: var(--lh);
  color: #2a1520;
  text-align: left;
  position: relative;
  top: 0.32rem;
}
.letter-text p { margin: 0; }
.letter-text p + p { margin-top: var(--lh); }
.letter-text p.aka { margin-top: 0; font-style: italic; opacity: 0.6; }

@media (max-width: 600px) {
  .letter-sheet { --lh: 1.8rem; }
  .letter-text { font-size: 1.4rem; padding-left: 4.9rem; padding-right: 1.2rem; }
  .letter-paper { background-size: auto; }
  .nb-big { padding: 1.2rem 1rem 1rem 2.6rem; font-size: 16px; }
  .nb-page { grid-template-columns: 1fr; }
}

.photo.wide-photo {
  clear: both;
  max-width: none;
  width: 100%;
  box-sizing: border-box;
  margin: 1.6rem 0 0.4rem;
  padding-bottom: 10px;
  transform: rotate(var(--tilt, -0.8deg));
}
.photo.wide-photo img { aspect-ratio: auto; height: auto; }

.nb-cover-scribble {
  width: 78%;
  height: auto;
  margin: 4% auto 0;
  pointer-events: none;
  user-select: none;
}

.lightbox-card.wide { max-width: min(1150px, 94vw); width: min(1150px, 94vw); }
.lightbox-card.wide img { width: 100%; max-height: none; }

html { cursor: var(--default-cursor, auto); }
.keepsake[data-open="ks-montage"],
.clip { cursor: var(--play-cursor, pointer) !important; }

.scribbles-set > .scribble-half:first-child { margin-bottom: 4.5rem; }
.ks-banner { margin-bottom: 3.2rem; }
.keepsakes { margin-bottom: 3.5rem; }

.ks-banner {
  position: relative;
  padding: 0.7rem 1.8rem 0.9rem;
  background: var(--entry-frame);
  border-radius: 3px;
  box-shadow: 3px 5px 0 rgba(0, 0, 0, 0.15);
  transform: rotate(-1.5deg);
}
.ks-banner::after {
  content: "";
  position: absolute;
  inset: 6px;
  border: 2px solid rgba(255, 255, 255, 0.75);
  border-radius: 2px;
  pointer-events: none;
  z-index: -1;
}
.ks-banner h2 {
  margin: 0;
  font-family: "Caveat Brush", "Caveat", cursive;
  font-weight: 400;
  font-size: clamp(1.7rem, 5vw, 2.8rem);
  line-height: 1;
  color: #000;
  text-shadow: 1px 2px 0 rgba(255, 255, 255, 0.45);
  white-space: nowrap;
}

.confetti-btn,
.keepsake[data-open="ks-notebook"] { cursor: var(--touch-cursor, pointer); }

.clip { pointer-events: none; }
.clip-screen { pointer-events: auto; }

@media (max-width: 600px) {
  .ks-close { top: 0.9rem; right: 0.9rem; width: 2.9rem; height: 2.9rem; font-size: 2.1rem; }
}

.ks-modal video { cursor: var(--default-cursor, auto); }

.env-wrap.big .env-box { isolation: isolate; }
.env-wrap.big .env-box > .flower { z-index: -1; }

.keepsake[data-open="ks-letter"] { cursor: var(--touch-cursor, pointer); }

.photo-icon {
  width: calc(var(--ks) * 0.86);
  height: calc(var(--ks) * 0.86);
  justify-self: center;
  border-radius: 22%;
  background: linear-gradient(150deg, hsl(335 95% 84%), hsl(332 80% 68%));
  box-shadow: 3px 6px 0 rgba(0, 0, 0, 0.15), inset 0 0 0 calc(var(--ks) * 0.03) rgba(255, 255, 255, 0.6);
  transform: rotate(-1.5deg);
}
.photo-glyph {
  width: 56%;
  height: auto;
  filter: drop-shadow(1px 2px 0 rgba(120, 20, 70, 0.3));
}
.keepsake[data-open="ks-album"] { cursor: var(--touch-cursor, pointer); }

.keepsake[data-open="ks-letter"] { grid-column: 1 / -1; justify-self: center; }
@media (max-width: 560px) { .ks-label { font-size: 0.95rem; } }

.album-big {
  width: min(780px, 92vw);
  height: min(92vh, 1100px);
  height: min(92dvh, 1100px);
  max-height: none;
}
.album-pages {
  position: relative;
  flex: 1;
  min-height: 0;
}
.album-page { position: absolute; inset: 0; }
.album-side { position: absolute; top: 0; bottom: 0; left: 0; right: 0; }
.album-side.left { right: calc(50% + 20px); }
.album-side.right { left: calc(50% + 20px); }
.album-page[hidden] { display: none; }

.photo.album-photo {
  position: absolute;
  width: max-content;
  max-width: none;
  padding: 8px 8px 0;
  z-index: var(--z, 1);
  transform: translate(-50%, -50%) rotate(var(--tilt, 0deg));
}
.photo.album-photo:not(:has(figcaption)) { padding-bottom: 24px; }
.photo.album-photo:hover { z-index: 20; }
.photo.album-photo img {
  aspect-ratio: auto;
  object-fit: cover;
  object-position: 50% 40%;
}
.photo.album-photo { opacity: 0; transition: opacity 0.3s ease; }
.photo.album-photo.ready { opacity: 1; }
.photo.album-photo figcaption {
  max-width: var(--mw);
  font-size: 1.15rem;
  padding: 0.25rem 0 0.4rem;
}
.photo.album-photo::before,
.photo.album-photo::after { width: 44px; height: 15px; }
.album-soon {
  display: grid;
  place-items: center;
  width: min(var(--mw), 200px);
  aspect-ratio: 4 / 3;
  border: 2px dashed rgba(200, 80, 130, 0.45);
  font-family: "Caveat Brush", "Caveat", cursive;
  font-size: 1.3rem;
  color: rgba(80, 20, 50, 0.6);
}

.lightbox { z-index: 990; }

.keepsake { position: relative; }
.ks-lock {
  position: absolute;
  left: 50%;
  top: calc(var(--ks) / 2);
  width: calc(var(--ks) * 0.32);
  z-index: 6;
  pointer-events: none;
  transform: translate(-50%, -50%);
  transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.3, 1.5, 0.5, 1);
}
.ks-lock::before {
  content: "";
  position: absolute;
  inset: -45%;
  z-index: -1;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(70, 10, 45, 0.32), rgba(70, 10, 45, 0.12) 55%, transparent);
}
.ks-lock svg {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 4px 6px rgba(60, 10, 40, 0.45)) drop-shadow(0 10px 18px rgba(60, 10, 40, 0.3));
}

.keepsake .ks-art,
.keepsake .ks-label,
.keepsake .envelope { transition: opacity 0.8s ease, filter 0.8s ease, transform 0.25s cubic-bezier(0.3, 1.5, 0.5, 1); }
body:not(.gifts-unlocked) .keepsake:not([data-open="ks-letter"]) .ks-art,
body:not(.gifts-unlocked) .keepsake:not([data-open="ks-letter"]) .ks-label,
body:not(.letter-unlocked) .keepsake[data-open="ks-letter"] .envelope,
body:not(.letter-unlocked) .keepsake[data-open="ks-letter"] .ks-label {
  opacity: 0.45;
  filter: saturate(0.6);
}
body:not(.gifts-unlocked) .keepsake:not([data-open="ks-letter"]) { cursor: var(--no-cursor, not-allowed) !important; }
@media (hover: hover) {
  body:not(.gifts-unlocked) .keepsake:not([data-open="ks-letter"]):hover .ks-art { transform: none; }
}

body.gifts-unlocked .keepsake:not([data-open="ks-letter"]) .ks-lock,
body.letter-unlocked .keepsake[data-open="ks-letter"] .ks-lock {
  opacity: 0;
  transform: translate(-50%, -80%) scale(1.5) rotate(14deg);
}
body.ks-instant * { transition: none !important; }

.ks-note {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 0.5rem);
  z-index: 8;
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  background: #fff;
  color: #000;
  font-family: "Caveat Brush", "Caveat", cursive;
  font-size: clamp(1rem, 2.6vw, 1.3rem);
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(60, 10, 40, 0.3);
  pointer-events: none;
  transform: translateX(-50%);
}

.vp {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 8px;
  background: #000;
  outline: none;
  cursor: var(--default-cursor, auto);
  user-select: none;
  -webkit-user-select: none;
}
.player-big .vp { aspect-ratio: 16 / 9; height: auto; max-height: 72vh; }
.player-big .vp video { aspect-ratio: auto; max-height: none; }
.vp video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
  border-radius: 0;
}
.vp.fs { border-radius: 0; }
.vp.idle, .vp.idle video { cursor: none; }

.vp-big {
  all: unset;
  position: absolute;
  left: 50%;
  top: 50%;
  width: clamp(3.6rem, 9vw, 5.4rem);
  height: clamp(3.6rem, 9vw, 5.4rem);
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: hsl(335 80% 62%);
  box-shadow: 0 6px 22px rgba(60, 10, 40, 0.45);
  transform: translate(-50%, -50%);
  transition: opacity 0.25s ease, transform 0.25s cubic-bezier(0.3, 1.5, 0.5, 1);
  cursor: var(--play-cursor, pointer) !important;
}
.vp-big svg { width: 46%; margin-left: 8%; fill: currentColor; }
.vp-big:hover { transform: translate(-50%, -50%) scale(1.08); }
.vp:not(.paused) .vp-big { opacity: 0; transform: translate(-50%, -50%) scale(0.7); pointer-events: none; }

.vp-spin {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 3rem;
  height: 3rem;
  margin: -1.5rem 0 0 -1.5rem;
  border-radius: 50%;
  border: 4px solid rgba(255, 255, 255, 0.3);
  border-top-color: hsl(335 90% 75%);
  opacity: 0;
  pointer-events: none;
  animation: vp-spin 0.9s linear infinite;
  transition: opacity 0.2s ease;
}
.vp.loading:not(.paused) .vp-spin { opacity: 1; }
@keyframes vp-spin { to { transform: rotate(360deg); } }

.vp-bar {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  gap: clamp(0.4rem, 1.2vw, 0.85rem);
  padding: 2.4rem clamp(0.6rem, 1.6vw, 1.1rem) clamp(0.45rem, 1.2vw, 0.8rem);
  background: linear-gradient(to top, rgba(45, 8, 30, 0.75), rgba(45, 8, 30, 0.35) 55%, transparent);
  color: #fff;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.vp.idle .vp-bar { opacity: 0; transform: translateY(8px); pointer-events: none; }
.vp-btn {
  all: unset;
  flex: none;
  width: clamp(1.8rem, 3.4vw, 2.3rem);
  height: clamp(1.8rem, 3.4vw, 2.3rem);
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  cursor: var(--touch-cursor, pointer) !important;
  transition: background 0.15s ease, transform 0.15s ease;
}
.vp-btn svg { width: 70%; height: 70%; fill: currentColor; filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.4)); }
.vp-btn:hover { background: rgba(255, 255, 255, 0.18); transform: scale(1.08); }
.vp-btn:focus-visible, .vp-big:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

.vp-track {
  position: relative;
  flex: 1;
  height: 1.6rem;
  cursor: var(--touch-cursor, pointer) !important;
  touch-action: none;
}
.vp-track::before,
.vp-buf,
.vp-fill {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  height: 6px;
  margin-top: -3px;
  border-radius: 99px;
  transition: height 0.15s ease, margin 0.15s ease;
}
.vp-track::before { right: 0; background: rgba(255, 255, 255, 0.3); }
.vp-buf { width: 0; background: rgba(255, 255, 255, 0.45); }
.vp-fill { width: 0; background: linear-gradient(90deg, hsl(330 100% 80%), hsl(335 90% 68%)); }
.vp-knob {
  position: absolute;
  left: 0;
  top: 50%;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 3px hsl(335 90% 68%), 0 2px 6px rgba(0, 0, 0, 0.4);
  transform: translate(-50%, -50%) scale(0.85);
  transition: transform 0.15s ease;
}
.vp-track:hover::before, .vp-track:hover .vp-buf, .vp-track:hover .vp-fill,
.vp.scrubbing .vp-track::before, .vp.scrubbing .vp-buf, .vp.scrubbing .vp-fill { height: 8px; margin-top: -4px; }
.vp-track:hover .vp-knob, .vp.scrubbing .vp-knob { transform: translate(-50%, -50%) scale(1.1); }

.vp-time {
  flex: none;
  font-family: "Caveat Brush", "Caveat", cursive;
  font-size: clamp(1rem, 2vw, 1.3rem);
  font-variant-numeric: tabular-nums;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  white-space: nowrap;
}

.vp-vol {
  --v: 100%;
  flex: none;
  width: clamp(3.5rem, 8vw, 5.5rem);
  height: 6px;
  margin: 0;
  -webkit-appearance: none;
  appearance: none;
  border-radius: 99px;
  background: linear-gradient(90deg, #fff var(--v), rgba(255, 255, 255, 0.3) var(--v));
  cursor: var(--touch-cursor, pointer) !important;
}
.vp-vol::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 3px hsl(335 90% 68%);
}
.vp-vol::-moz-range-thumb {
  width: 13px;
  height: 13px;
  border: none;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 3px hsl(335 90% 68%);
}
@media (hover: none), (max-width: 560px) { .vp-vol { display: none; } }

.vp-fs svg { fill: none; }

.photo.album-photo.fill img { object-position: 50% 50%; }

.album-big.spread {
  width: min(1500px, 94vw);
  height: min(92vh, 1000px);
  height: min(92dvh, 1000px);
  padding: 1.3rem 2rem 1rem;
  border-radius: 14px;
}
.album-big.spread .spiral { left: 50%; margin-left: -0.8em; bottom: 4.6rem; }
.album-big.spread::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 140px;
  margin-left: -70px;
  background: linear-gradient(90deg, transparent, rgba(130, 30, 75, 0.1) 38%, rgba(130, 30, 75, 0.22) 50%, rgba(130, 30, 75, 0.1) 62%, transparent);
  pointer-events: none;
}
.album-big.spread .nb-head { display: grid; grid-template-columns: 1fr 1fr; column-gap: 60px; align-items: center; text-align: center; }
.album-big.spread .nb-intro { margin: 0; padding-right: 2.2rem; }

.album-page-cap {
  margin: 0.15rem 0 0;
  min-height: 1.4em;
  text-align: center;
  font-family: "Caveat Brush", "Caveat", cursive;
  font-size: clamp(1.15rem, 2vw, 1.5rem);
  line-height: 1.3;
  color: hsl(335 60% 42%);
}

body:not(.letter-unlocked) .keepsake[data-open="ks-letter"] { cursor: var(--no-cursor, not-allowed) !important; }

.keepsake.ks-locked .ks-art,
.keepsake.ks-locked .ks-label { opacity: 0.45; filter: saturate(0.6); }
.keepsake.ks-locked { cursor: var(--no-cursor, not-allowed) !important; }
body.gifts-unlocked .keepsake.ks-locked .ks-lock { opacity: 1; transform: translate(-50%, -50%); }
@media (hover: hover) { .keepsake.ks-locked:hover .ks-art { transform: none; } }

.photo.square img { aspect-ratio: 1 / 1; object-position: 50% 35%; }
