/* Before We Dream: brand page. Uses the shared tokens in bwd.css. */

.brand-page main > section { position: relative; }

/* ---------- 1. Ident hero ---------- */
.b-hero {
  min-height: 100svh;
  display: grid;
  grid-template-rows: 1fr auto;
  justify-items: center;
  padding: calc(var(--header-h) + 2svh) 1.5rem 2.2rem;
  overflow: clip;
}
.b-hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(60% 55% at 50% 46%, #3a1f52b3, transparent 70%);
}
.b-hero-stage {
  position: relative;
  align-self: center;
  display: grid; justify-items: center;
  gap: clamp(1rem, 2.6svh, 1.6rem);
  width: min(100%, 40rem);
  text-align: center;
}
.b-hero-halo {
  position: absolute; z-index: -1; left: 50%; top: 22%;
  width: min(80vw, 34rem); aspect-ratio: 1; border-radius: 50%;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, #f6bf782e, #f6bf7800 62%);
  filter: blur(6px);
}
.brand-mark { width: min(52vw, 15.5rem, 34svh); }
.word-split { width: min(86vw, 33rem); height: auto; overflow: visible; color: var(--ivory); }
.b-tagline {
  margin: .2rem 0 0; padding-left: .42em;
  color: var(--lamplight);
  font: 600 clamp(.68rem, 1.3vw, .8rem)/1 var(--sans);
  letter-spacing: .42em; text-transform: uppercase;
}
.b-hero-foot { display: grid; justify-items: center; gap: 1.2rem; }
.b-scroll {
  display: grid; justify-items: center; gap: .55rem;
  color: #d6c3e1; font-size: .82rem; font-weight: 600; letter-spacing: .04em; text-decoration: none;
}
.b-scroll::after {
  content: ""; width: 1px; height: 2.6rem;
  background: linear-gradient(#f6bf78, transparent);
  transform-origin: top;
}
html[data-motion="on"] .b-scroll::after { animation: cue-drop 2.4s var(--ease-soft) infinite; }
@keyframes cue-drop { 0% { transform: scaleY(0); opacity: 1; } 60% { transform: scaleY(1); opacity: 1; } 100% { transform: scaleY(1); opacity: 0; } }

/* ---------- 2. The idea ---------- */
.b-idea { padding: clamp(4rem, 12svh, 8rem) 0; }
.b-idea-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(2rem, 6vw, 6rem); align-items: center; }
.anatomy { position: relative; margin: 0; }
.anatomy-halo {
  position: absolute; inset: 4% 8% 10%; z-index: -1; border-radius: 50%;
  background: radial-gradient(circle at 42% 45%, #f6bf7826, transparent 65%);
}
.anatomy-mark { width: 100%; }
.anatomy-mark .bwd-moon, .anatomy-mark .bwd-glow, .anatomy-mark .bwd-book, .anatomy-mark .bwd-star {
  transition: opacity .6s var(--ease-soft), filter .6s var(--ease-soft);
}
.anatomy[data-focus="moon"] .bwd-book, .anatomy[data-focus="moon"] .bwd-star,
.anatomy[data-focus="book"] .bwd-moon, .anatomy[data-focus="book"] .bwd-glow, .anatomy[data-focus="book"] .bwd-star,
.anatomy[data-focus="star"] .bwd-moon, .anatomy[data-focus="star"] .bwd-glow, .anatomy[data-focus="star"] .bwd-book { opacity: .16; }
.anatomy-pin {
  position: absolute; display: grid; place-items: center;
  width: 1.9rem; height: 1.9rem; margin: -.95rem 0 0 -.95rem; border-radius: 50%;
  background: #1d1030d9; color: var(--lamp-hot);
  box-shadow: inset 0 0 0 1.5px #f6bf7899;
  font: 700 .82rem/1 var(--sans);
  transition: background .4s, color .4s, box-shadow .4s;
}
.anatomy-pin--moon { left: 16.5%; top: 31%; }
.anatomy-pin--book { left: 8.5%; top: 88%; }
.anatomy-pin--star { left: 91%; top: 8%; }
.anatomy[data-focus="moon"] .anatomy-pin--moon,
.anatomy[data-focus="book"] .anatomy-pin--book,
.anatomy[data-focus="star"] .anatomy-pin--star { background: var(--lamplight); color: var(--ink); box-shadow: 0 0 0 .45rem #f6bf7830, 0 0 1.6rem #f6bf7899; }
.anatomy-list { list-style: none; margin: 2rem 0 0; padding: 0; display: grid; gap: .6rem; }
.anatomy-list button {
  display: grid; grid-template-columns: auto 1fr; gap: 1rem; align-items: start;
  width: 100%; padding: 1rem 1.15rem; border: 0; border-radius: 1rem;
  background: #ffffff07; box-shadow: inset 0 0 0 1px #ffffff10;
  text-align: left; color: #e2d3ea; cursor: pointer;
  transition: background .4s, box-shadow .4s, transform .5s var(--ease-out);
}
.anatomy-list b {
  display: grid; place-items: center; width: 1.7rem; height: 1.7rem; border-radius: 50%;
  box-shadow: inset 0 0 0 1.5px #f6bf7880; color: var(--lamp-hot); font-size: .78rem;
  transition: background .4s, color .4s;
}
.anatomy-list strong { display: block; margin-bottom: .2rem; color: var(--ivory); font: 400 1.22rem/1.25 var(--serif); }
.anatomy-list button:hover, .anatomy-list button.is-active { background: #ffffff10; box-shadow: inset 0 0 0 1px #f6bf7850; }
.anatomy-list button.is-active { transform: translateX(.35rem); }
.anatomy-list button.is-active b { background: var(--lamplight); color: var(--ink); }

/* ---------- 3. Logo files ---------- */
.b-logos { padding: clamp(3rem, 8svh, 6rem) 0 clamp(4rem, 10svh, 7rem); }
.lockups { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.2rem; scroll-margin-top: calc(var(--header-h) + 2rem); }
.lockup, .mark-card {
  position: relative; margin: 0; border-radius: 1.4rem; overflow: hidden;
  background: #ffffff08; box-shadow: inset 0 0 0 1px #ffffff12, 0 1.4rem 3rem -2rem #000;
  transition: box-shadow .5s var(--ease-out);
}
.lockup:hover, .mark-card:hover { box-shadow: inset 0 0 0 1px #f6bf7844, 0 1.8rem 3.4rem -1.8rem #000; }
.lockup-art { position: relative; display: grid; place-items: center; aspect-ratio: 16 / 8; overflow: hidden; }
.lockup--dark .lockup-art, .mark-art--dark {
  background:
    radial-gradient(1px 1px at 12% 22%, #ffffffa0 50%, transparent),
    radial-gradient(1px 1px at 27% 74%, #ffffff80 50%, transparent),
    radial-gradient(1.6px 1.6px at 41% 13%, #ffe9c2d0 50%, transparent),
    radial-gradient(1px 1px at 63% 84%, #ffffff70 50%, transparent),
    radial-gradient(1.6px 1.6px at 81% 26%, #ffffffc0 50%, transparent),
    radial-gradient(1px 1px at 90% 66%, #ffffff90 50%, transparent),
    radial-gradient(1px 1px at 7% 58%, #ffffff70 50%, transparent),
    radial-gradient(1px 1px at 55% 30%, #ffffff60 50%, transparent),
    radial-gradient(60% 80% at 50% 45%, #4a2c5e8c, transparent 72%),
    linear-gradient(180deg, #24123a, #170c25);
}
.lockup--light .lockup-art, .mark-art--ivory {
  background:
    radial-gradient(70% 90% at 50% 40%, #fffaf0, transparent 75%),
    linear-gradient(180deg, #fff3e2, #f7e5cf);
}
.lockup-art::after {
  /* a slow sheen, like light across paper */
  content: ""; position: absolute; inset: -30% auto -30% -40%; width: 30%;
  background: linear-gradient(100deg, transparent, #ffffff1f, transparent);
  transform: skewX(-16deg) translateX(-150%);
  pointer-events: none;
}
.lockup--light .lockup-art::after { background: linear-gradient(100deg, transparent, #ffffff99, transparent); }
.lockup:hover .lockup-art::after { transition: transform 1.3s var(--ease-out); transform: skewX(-16deg) translateX(560%); }
.lockup--wide .lockup-art img { width: min(76%, 30rem); }
.lockup--tall .lockup-art img { width: min(58%, 22rem); }
.lockup-meta, .mark-card { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.lockup-meta { padding: 1rem 1.25rem 1.1rem; }
.lockup-meta h3, .mark-card h3 { font-size: 1.15rem; }
.lockup-meta p, .mark-dl { display: flex; gap: .45rem; margin: 0; }
.lockup-meta a, .mark-dl a, .extra a {
  display: inline-flex; align-items: center; gap: .35rem;
  padding: .42rem .8rem; border-radius: 999px;
  background: #ffffff0d; box-shadow: inset 0 0 0 1px #ffffff1c;
  color: var(--ivory); font-size: .78rem; font-weight: 700; letter-spacing: .04em; text-decoration: none;
  transition: background .3s, box-shadow .3s, color .3s;
}
.lockup-meta a::before, .mark-dl a::before, .extra a::before {
  content: ""; width: .7rem; height: .7rem;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M6 1v6.5M3 5l3 3 3-3M1.5 10.5h9' fill='none' stroke='%23000' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M6 1v6.5M3 5l3 3 3-3M1.5 10.5h9' fill='none' stroke='%23000' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
}
.lockup-meta a:hover, .mark-dl a:hover, .extra a:hover { background: var(--lamplight); color: var(--ink); box-shadow: none; }

.marks { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.2rem; margin-top: 1.2rem; }
.mark-card { flex-direction: column; align-items: stretch; gap: 0; padding-bottom: 1.15rem; }
.mark-art { display: grid; place-items: center; aspect-ratio: 1.25; margin-bottom: 1rem; }
.mark-art img { width: 46%; transition: transform .8s var(--ease-out); }
.mark-card:hover .mark-art img { transform: translateY(-4%) scale(1.05); }
.mark-art--plum { background: radial-gradient(70% 80% at 50% 40%, #5b3775, #2f1a42 75%); }
.mark-card h3, .mark-card p { margin-inline: 1.15rem; }
.mark-card p { margin-top: .35rem; margin-bottom: 0; color: #d9c8e3; font-size: .9rem; line-height: 1.45; }
.mark-card .mark-dl { margin-top: .9rem; }

.extras { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2.2fr); gap: 1.2rem; margin-top: 1.2rem; }
.extra {
  display: grid; align-content: center; justify-items: center; gap: 1.1rem; margin: 0;
  padding: 1.6rem; border-radius: 1.4rem;
  background: #ffffff08; box-shadow: inset 0 0 0 1px #ffffff12;
}
.extra--icon > img { width: 7.5rem; border-radius: 22.5%; box-shadow: 0 1rem 2rem -1rem #000, inset 0 0 0 1px #fff2; }
.tab-mock { width: min(100%, 17rem); border-radius: .8rem .8rem .5rem .5rem; overflow: hidden; background: #0f0818; box-shadow: inset 0 0 0 1px #ffffff14; }
.tab-mock-tab {
  position: relative; display: flex; align-items: center; gap: .5rem; width: 78%; margin: .45rem 0 0 .45rem;
  padding: .5rem .7rem; border-radius: .55rem .55rem 0 0; background: #2a1838;
  color: #eadcf2; font-size: .78rem; font-weight: 600; white-space: nowrap;
}
.tab-mock-tab img { width: 1rem; height: 1rem; }
.tab-mock-tab i { margin-left: auto; width: .55rem; height: .55rem; opacity: .5; background: linear-gradient(45deg, transparent 44%, #fff 44% 56%, transparent 56%), linear-gradient(-45deg, transparent 44%, #fff 44% 56%, transparent 56%); }
.tab-mock-bar { display: block; height: 1.7rem; margin: 0; background: #2a1838; box-shadow: inset 0 -1px 0 #ffffff10; }
.extra--social img { width: 100%; border-radius: .9rem; box-shadow: 0 1.2rem 2.6rem -1.4rem #000; }
.extra figcaption { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .6rem 1rem; color: #e6d8ef; font-size: .92rem; text-align: center; }
.extra figcaption strong { flex-basis: 100%; font: 400 1.1rem/1.2 var(--serif); color: var(--ivory); }

/* ---------- 4. Using it well ---------- */
.b-rules { padding: clamp(3rem, 8svh, 6rem) 0; }
.b-rules-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(2rem, 5vw, 5rem); align-items: center; }
.b-rules-copy p:not(.kicker) { color: #e2d3ea; max-width: 32rem; }
.b-rules-copy h2 { margin-bottom: 1rem; }
.space-demo { display: grid; place-items: center; padding: clamp(1.5rem, 4vw, 3rem); border-radius: 1.4rem; background: #ffffff06; box-shadow: inset 0 0 0 1px #ffffff10; }
.space-box { --gap: clamp(1.4rem, 3vw, 2.4rem); position: relative; padding: var(--gap); outline: 1px dashed #f6bf7866; outline-offset: 0; width: 100%; }
.space-box img { width: 100%; }
.space-box i { position: absolute; background: repeating-linear-gradient(135deg, #f6bf7833 0 6px, transparent 6px 12px); }
.space-x { top: 0; bottom: 0; left: 0; width: var(--gap); }
.space-x--r { left: auto; right: 0; }
.space-y { left: var(--gap); right: var(--gap); top: 0; height: var(--gap); }
.space-y--b { top: auto; bottom: 0; }
.donts { grid-column: 1 / -1; list-style: none; margin: 1rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.2rem; }
.donts li { margin: 0; }
.donts li > p { margin: .8rem .2rem 0; color: #e2d3ea; font-size: .92rem; line-height: 1.45; }
.dont-art {
  position: relative; display: grid; place-items: center; aspect-ratio: 16 / 9; overflow: hidden;
  border-radius: 1.1rem; background: linear-gradient(180deg, #24123a, #170c25); box-shadow: inset 0 0 0 1px #ffffff12;
}
.dont-art::after {
  content: ""; position: absolute; top: .7rem; right: .7rem; width: 1.5rem; height: 1.5rem; border-radius: 50%;
  background:
    linear-gradient(45deg, transparent calc(50% - 1px), #ff9b8b calc(50% - 1px) calc(50% + 1px), transparent calc(50% + 1px)),
    #3a1a2c;
  box-shadow: inset 0 0 0 1.5px #ff9b8b;
}
.dont-art img { width: 74%; }
.dont-art img.dont-stretch { width: 58%; transform: scale(1.32, .7); }
.dont-recolour { filter: hue-rotate(150deg) saturate(1.7); }
.dont-mixed { margin: 0; color: var(--ivory); font-size: clamp(1.1rem, 1.8vw, 1.45rem); white-space: nowrap; }
.dont-mixed span { font-family: var(--serif); }
.dont-mixed em { font-family: Georgia, serif; font-style: italic; font-weight: 700; }
.dont-mixed b { font-family: var(--sans); font-weight: 800; letter-spacing: .2em; }
.dont-art--busy { background: url("../assets/santa-papercut-room.webp") center / cover; }

/* ---------- 5. Colour ---------- */
.b-colour { padding: clamp(4rem, 10svh, 7rem) 0; }
.swatches { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1rem; }
.swatches > :nth-child(6) { grid-column: 1 / span 2; }
.swatch {
  position: relative;
  display: grid; grid-template-rows: auto auto auto 1fr; align-content: start;
  padding: 0 0 1rem; border: 0; border-radius: 1.2rem; overflow: hidden;
  background: #ffffff08; box-shadow: inset 0 0 0 1px #ffffff12;
  text-align: left; cursor: pointer;
  transition: box-shadow .4s, background .4s;
}
.swatch--hero { grid-column: span 2; }
.swatch:hover { background: #ffffff0f; box-shadow: inset 0 0 0 1px #ffffff2e, 0 1.2rem 2.4rem -1.6rem #000; }
.swatch-chip { height: 7rem; margin-bottom: .9rem; background: var(--c); box-shadow: inset 0 -1px 0 #ffffff14, inset 0 0 0 1px #ffffff0d; transition: filter .4s; }
.swatch:hover .swatch-chip { filter: brightness(1.08) saturate(1.05); }
.swatch[data-hex="#FFF1DB"] .swatch-chip, .swatch[data-hex="#C9B0DC"] .swatch-chip, .swatch[data-hex="#FFD99C"] .swatch-chip { box-shadow: inset 0 -1px 0 #0002; }
.swatch-name { padding: 0 1rem; color: var(--ivory); font: 400 1.18rem/1.2 var(--serif); }
.swatch-hex { padding: .25rem 1rem 0; color: var(--lamplight); font: 700 .78rem/1.3 ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: .06em; }
.swatch-role { padding: .35rem 1rem 0; color: #d4c2df; font-size: .84rem; line-height: 1.4; }
.swatch.is-copied .swatch-hex { color: #8be3ad; }
.swatch-hint { margin-top: 1.4rem; }

/* ---------- 6. Type ---------- */
.b-type { padding: clamp(4rem, 10svh, 7rem) 0; }
.b-type-grid { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(2rem, 6vw, 6rem); align-items: center; }
.type-specimen {
  position: relative; padding: clamp(1.6rem, 4vw, 3rem); border-radius: 1.6rem; overflow: hidden;
  background: radial-gradient(80% 70% at 30% 20%, #4a2c5e99, transparent 70%), #ffffff06;
  box-shadow: inset 0 0 0 1px #ffffff12;
}
.type-aa {
  margin: 0; font: 400 clamp(6rem, 14vw, 11rem)/.9 var(--serif); letter-spacing: -.02em;
  background: linear-gradient(170deg, #ffe9c2, #f6bf78 50%, #e58f58);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.type-name { margin: .8rem 0 1.4rem; color: var(--lamplight); font: 600 .74rem/1.2 var(--sans); letter-spacing: .24em; text-transform: uppercase; }
.type-sample { margin: 0; font: 400 clamp(1.9rem, 3.4vw, 2.9rem)/1.06 var(--serif); letter-spacing: -.012em; color: var(--ivory); text-wrap: balance; }
.type-sample--wrap { margin-top: 1rem; max-width: 11em; color: #eadcf2; }
.type-copy .lede { max-width: 32rem; }
.type-body { margin-top: 2rem; padding-top: 1.6rem; border-top: 1px solid #ffffff14; color: #e2d3ea; }
.type-name--sans { margin: 0 0 .6rem; }
.type-body p { margin: 0 0 .8rem; max-width: 32rem; }
.type-label { color: var(--lamplight); font: 600 .74rem/1.2 var(--sans); letter-spacing: .24em; text-transform: uppercase; }

/* ---------- 7. Voice ---------- */
.b-voice { padding: clamp(4rem, 10svh, 7rem) 0; }
.voice-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.2rem; }
.voice-card {
  margin: 0; padding: 2rem 1.6rem 1.5rem; border-radius: 1.4rem;
  background: linear-gradient(180deg, #ffffff0c, #ffffff05); box-shadow: inset 0 0 0 1px #ffffff12;
}
.voice-card p { margin: 0; font: 400 clamp(1.45rem, 2.1vw, 1.8rem)/1.2 var(--serif); color: var(--ivory); text-wrap: balance; }
.voice-card p::before { content: "“"; display: block; height: .55em; color: var(--lamplight); font-size: 2.2em; line-height: 1; }
.voice-card footer { margin-top: 1.2rem; color: #cdb9d8; font-size: .86rem; }
.voice-rules { list-style: none; margin: 2.2rem auto 0; padding: 0; display: grid; gap: .8rem; max-width: 40rem; }
.voice-rules li { display: flex; align-items: baseline; gap: .8rem; color: #e2d3ea; }
.voice-rules .sparkle { flex: none; width: .7rem; height: .7rem; color: var(--lamplight); transform: translateY(.05rem); }

/* ---------- 8. Motion ---------- */
.b-motion { padding: clamp(4rem, 10svh, 7rem) 0; }
.motion-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.2rem; }
.motion-card { margin: 0; }
.motion-card h3 { margin-top: 1rem; font-size: 1.28rem; }
.motion-card p { margin: .4rem 0 0; color: #d9c8e3; font-size: .92rem; line-height: 1.5; }
.motion-demo { position: relative; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 1.2rem; background: #1b0e2a; box-shadow: inset 0 0 0 1px #ffffff12, 0 1.2rem 2.6rem -1.8rem #000; isolation: isolate; }
.motion-demo > img { position: absolute; max-width: none; }

.demo-alive > img { inset: 0; width: 100%; height: 100%; object-fit: cover; filter: brightness(.8); }
.demo-alive i {
  position: absolute; width: .7rem; height: .7rem; background: #ffeccc;
  clip-path: polygon(50% 0, 61% 39%, 100% 50%, 61% 61%, 50% 100%, 39% 61%, 0 50%, 39% 39%);
  filter: drop-shadow(0 0 .3rem #ffd99c);
  opacity: .8;
}
.demo-alive i:nth-of-type(1) { left: 14%; top: 18%; }
.demo-alive i:nth-of-type(2) { left: 38%; top: 34%; width: .45rem; height: .45rem; }
.demo-alive i:nth-of-type(3) { left: 62%; top: 14%; width: .55rem; height: .55rem; }
.demo-alive i:nth-of-type(4) { left: 24%; top: 58%; width: .4rem; height: .4rem; }
.demo-alive i:nth-of-type(5) { left: 82%; top: 46%; width: .5rem; height: .5rem; }
.demo-alive i:nth-of-type(6) { left: 50%; top: 66%; width: .35rem; height: .35rem; }
.demo-moon {
  position: absolute; right: 16%; top: 16%; width: 2.6rem; height: 2.6rem; border-radius: 50%;
  box-shadow: inset -.75rem .35rem 0 0 #f8c27c;
  filter: drop-shadow(0 0 .8rem #f6bf7899);
  transform: rotate(-20deg);
}
html[data-motion="on"] .demo-alive i { animation: twinkle 3.2s ease-in-out infinite; }
html[data-motion="on"] .demo-alive i:nth-of-type(2) { animation-delay: -.8s; animation-duration: 2.6s; }
html[data-motion="on"] .demo-alive i:nth-of-type(3) { animation-delay: -1.7s; }
html[data-motion="on"] .demo-alive i:nth-of-type(4) { animation-delay: -2.3s; animation-duration: 3.8s; }
html[data-motion="on"] .demo-alive i:nth-of-type(5) { animation-delay: -1.1s; animation-duration: 2.9s; }
html[data-motion="on"] .demo-alive i:nth-of-type(6) { animation-delay: -.3s; animation-duration: 3.5s; }
html[data-motion="on"] .demo-moon { animation: moon-breathe 5.5s ease-in-out infinite; }
@keyframes twinkle { 0%, 100% { opacity: .25; transform: scale(.6) rotate(0); } 50% { opacity: 1; transform: scale(1.15) rotate(45deg); } }
@keyframes moon-breathe { 0%, 100% { filter: drop-shadow(0 0 .6rem #f6bf7866); transform: rotate(-20deg) translateY(0); } 50% { filter: drop-shadow(0 0 1.3rem #f6bf78cc); transform: rotate(-16deg) translateY(-.25rem); } }

.dp-stage { position: absolute; left: 50%; top: 50%; height: 100%; aspect-ratio: 16 / 9; transform: translate(-50%, -50%); }
.dp-stage > img { position: absolute; max-width: none; }
.demo-paper .dp-sky { left: -4%; top: -32%; width: 108%; height: 136%; object-fit: cover; }
.demo-paper .dp-ridge { left: -10%; top: 47.5%; width: 125%; height: 31.5%; object-fit: fill; filter: brightness(.86); -webkit-mask-image: linear-gradient(#000 62%, transparent); mask-image: linear-gradient(#000 62%, transparent); }
.demo-paper .dp-shore { left: -8%; top: 46.5%; width: 119.5%; height: 59%; object-fit: fill; filter: brightness(.92) drop-shadow(0 -.2rem .4rem #150d23a8); }
.demo-paper .dp-front { left: -13%; top: 62%; width: 127%; height: 48.5%; object-fit: fill; filter: brightness(.82) drop-shadow(0 -.2rem .3rem #1a1124c9); }
html[data-motion="on"] .demo-paper .dp-sky { animation: pan-sky 7s ease-in-out infinite alternate; }
html[data-motion="on"] .demo-paper .dp-ridge { animation: pan-ridge 7s ease-in-out infinite alternate; }
html[data-motion="on"] .demo-paper .dp-shore { animation: pan-shore 7s ease-in-out infinite alternate; }
html[data-motion="on"] .demo-paper .dp-front { animation: pan-front 7s ease-in-out infinite alternate; }
@keyframes pan-sky { from { transform: scale(1.06) translateX(1%); } to { transform: scale(1.06) translateX(-1%); } }
@keyframes pan-ridge { from { transform: translateX(2%); } to { transform: translateX(-2%); } }
@keyframes pan-shore { from { transform: translateX(4%); } to { transform: translateX(-4%); } }
@keyframes pan-front { from { transform: translateX(7.5%); } to { transform: translateX(-7.5%); } }

.demo-glow { display: grid; place-items: center; background: radial-gradient(70% 70% at 50% 50%, #3a2050, #1b0e2a 75%); }
.demo-btn {
  position: relative; overflow: hidden; padding: .85rem 1.4rem; border-radius: 999px;
  background: linear-gradient(180deg, #ffd796, #f2b066); color: #2a1530;
  font: 650 .95rem/1 var(--sans); white-space: nowrap;
  box-shadow: 0 .1rem 0 #fff3 inset, 0 -.18rem 0 #c07a3c55 inset, 0 .8rem 2rem -.6rem #f6a94f90;
}
.demo-btn::after {
  content: ""; position: absolute; inset: -20% auto -20% -60%; width: 45%;
  background: linear-gradient(100deg, transparent, #fffbe9cc, transparent);
  transform: skewX(-18deg) translateX(-120%);
}
html[data-motion="on"] .demo-btn::after { animation: sweep 3.6s var(--ease-soft) infinite; }
html[data-motion="on"] .demo-btn { animation: btn-glow 3.6s var(--ease-soft) infinite; }
@keyframes sweep { 0%, 35% { transform: skewX(-18deg) translateX(-120%); } 75%, 100% { transform: skewX(-18deg) translateX(520%); } }
@keyframes btn-glow { 0%, 100% { box-shadow: 0 .1rem 0 #fff3 inset, 0 -.18rem 0 #c07a3c55 inset, 0 .8rem 2rem -.6rem #f6a94f70; } 55% { box-shadow: 0 .1rem 0 #fff3 inset, 0 -.18rem 0 #c07a3c55 inset, 0 1rem 2.6rem -.4rem #f6a94fc0; } }

.demo-flow > img:not(.df-cloud) { inset: 0; width: 100%; height: 100%; object-fit: cover; }
.demo-flow .df-b { opacity: 0; }
.demo-flow .df-cloud { top: 50%; left: 0; width: 290%; height: auto; transform: translate(110%, -50%); filter: brightness(1.05); }
html[data-motion="on"] .demo-flow .df-b { animation: flow-b 9s ease-in-out infinite; }
html[data-motion="on"] .demo-flow .df-cloud { animation: flow-cloud 9s linear infinite; }
@keyframes flow-b { 0%, 34% { opacity: 0; } 46%, 82% { opacity: 1; } 94%, 100% { opacity: 0; } }
@keyframes flow-cloud {
  0%, 22% { transform: translate(40%, -50%); }
  58% { transform: translate(-100%, -50%); }
  58.01%, 70% { transform: translate(40%, -50%); }
  100% { transform: translate(-100%, -50%); }
}
html[data-motion="off"] .demo-flow .df-cloud { display: none; }

/* ---------- Close ---------- */
.b-close { padding: clamp(4rem, 12svh, 8rem) 0 clamp(2rem, 6svh, 4rem); text-align: center; }
.b-close-inner { display: grid; justify-items: center; }
.b-close-mark { width: 6.5rem; margin-bottom: 1.6rem; overflow: visible; }
html[data-motion="on"] .b-close-mark { animation: mark-float 6s ease-in-out infinite; }
@keyframes mark-float { 0%, 100% { transform: translateY(0) rotate(-1.5deg); } 50% { transform: translateY(-.6rem) rotate(1.5deg); } }

/* ---------- Copy toast ---------- */
.b-toast {
  position: fixed; z-index: 120; left: 50%; bottom: 1.6rem;
  padding: .7rem 1.1rem; border-radius: 999px;
  background: #fff1db; color: var(--ink); font-size: .88rem; font-weight: 700;
  box-shadow: 0 1rem 2rem -1rem #000;
  transform: translate(-50%, 160%); opacity: 0;
  transition: transform .5s var(--ease-out), opacity .4s;
  pointer-events: none;
}
.b-toast.is-on { transform: translate(-50%, 0); opacity: 1; }

/* ---------- Static first paint for the hero (JS plays it in) ---------- */
html.js[data-motion="on"] .b-hero-stage { visibility: hidden; animation: stage-fallback 0s 2.5s forwards; }
@keyframes stage-fallback { to { visibility: visible; } }
html.js[data-motion="on"] .b-hero-stage.is-ready { visibility: visible; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .marks { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .motion-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .swatches { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .swatches > :nth-child(6) { grid-column: span 2; }
  .donts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .b-idea-grid, .b-rules-grid, .b-type-grid { grid-template-columns: minmax(0, 1fr); }
  .anatomy { width: min(100%, 26rem); margin-inline: auto; }
  .lockups { grid-template-columns: minmax(0, 1fr); }
  .extras { grid-template-columns: minmax(0, 1fr); }
  .voice-grid { grid-template-columns: minmax(0, 1fr); }
  .anatomy-list button.is-active { transform: none; }
}
@media (max-width: 560px) {
  .marks, .motion-grid { grid-template-columns: minmax(0, 1fr); }
  .swatches { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .swatch--hero, .swatches > :nth-child(6) { grid-column: span 2; }
  .donts { grid-template-columns: minmax(0, 1fr); }
  .lockup-meta { flex-direction: column; align-items: flex-start; gap: .6rem; }
}
