/* Who we help (plan.md). Layout D: the words centered on the paper, the clip (a customer nearby smiling at her phone
   as she walks, two calm stretches in the kit's rotate) as a wide rounded band under them with `trade-type` on glass
   over its left side (the clip drawn 120% from its top left corner, so her face sits right of the scene); the six
   kinds as six of the logo's rising bars and a brass seventh for "yours"; the buyers on the designed ground; the chat
   in a phone over the florist; the split close. Tokens only. */

/* ---------- the header ---------- */
.whh { padding-block: clamp(1.75rem, 1rem + 3vh, 3rem) clamp(3.5rem, 2rem + 6vh, 6rem); }
.whh__words { max-width: 56rem; margin-inline: auto; }
.whh__band { position: relative; isolation: isolate; margin-top: clamp(2rem, 1rem + 3vh, 3.25rem); height: clamp(440px, 58vh, 520px); overflow: hidden; border-radius: var(--radius-l); background: var(--c-paper-alt); box-shadow: var(--shadow-l); }
.whh__media { position: absolute; inset: 0; z-index: -2; overflow: hidden; }
.whh__zoom { position: absolute; left: 0; top: 0; width: 120%; height: 120%; }

/* the kit's header (kit.md), as it gives it */
[data-kit-scene="rotate"] [data-kit-slide] { position: absolute; inset: 0; margin: 0; visibility: hidden; overflow: hidden; }
[data-kit-scene="rotate"] [data-kit-slide][data-kit-on] { visibility: visible; z-index: 2; opacity: var(--kit-move, 1); transform: translateX(var(--kit-glide, calc((1 - var(--kit-move, 1)) * 4%))); }
[data-kit-scene="rotate"]:not(:has([data-kit-slide][data-prev])) [data-kit-slide][data-kit-on] { transform: none; opacity: 1; }
[data-kit-scene="rotate"] [data-kit-slide][data-prev] { visibility: visible; z-index: 1; }
[data-kit-scene="rotate"] [data-kit-slide] video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: var(--pos, 50% 50%); }
[data-kit-scene="rotate"]:not(:has([data-kit-slide][data-kit-on])) [data-kit-slide]:not([data-kit-slide] ~ [data-kit-slide]) { visibility: visible; }
[data-kit-scene="rotate"] [data-kit-slide] video { inset: -1px; width: calc(100% + 2px); height: calc(100% + 2px); max-width: none; clip-path: inset(2px); }
[data-kit-scene="rotate"] [data-kit-slide] video[data-kit-shown] { clip-path: none; }
[data-kit-scene="rotate"] [data-kit-slide][data-prev] { opacity: clamp(0, (1 - var(--kit-move, 0)) * 1000, 1); }

/* the grade: one still layer, a soft navy at the left under the glass */
.whh__shade { position: absolute; inset: 0; z-index: -1; pointer-events: none; background: linear-gradient(90deg, color-mix(in srgb, var(--c-brand) 34%, transparent) 0%, color-mix(in srgb, var(--c-brand) 12%, transparent) 40%, transparent 58%); }
.whh__stop { top: 16px; right: 16px; }
.scene.whh__scene { position: absolute; left: clamp(16px, 3vw, 40px); top: 50%; translate: 0 -50%; width: min(560px, 50%); height: 420px; }

/* ---------- the kinds (the signature): seven rising bars ---------- */
.kinds .head { margin-inline: auto; }
.kinds__stage { position: relative; }
.kinds__stop { top: -10px; right: 0; }
.kinds__list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)) minmax(0, 1.55fr); gap: clamp(.6rem, .3rem + .6vw, 1rem); align-items: end; border-bottom: 2px solid var(--c-line); }
.kind { position: relative; display: flex; flex-direction: column; min-height: calc(410px + var(--step) * 34px); overflow: hidden; border-radius: var(--radius-m) var(--radius-m) 0 0; background: var(--c-card); box-shadow: var(--shadow-m); }
.kind__photo { position: relative; flex: none; margin: 0; aspect-ratio: 4 / 5; overflow: hidden; background: var(--c-paper-alt); }
.kind__chip { position: absolute; z-index: 2; left: 8px; bottom: 8px; display: inline-flex; align-items: center; gap: .35rem; padding: .3rem .6rem .3rem .3rem; border-radius: 999px; background: var(--c-card); box-shadow: var(--shadow-m); font: 600 .76rem/1.2 var(--font-text); color: var(--c-brand); white-space: nowrap; }
.kind__chip svg { flex: none; width: 18px; height: 18px; padding: 3.5px; border-radius: 50%; background: var(--c-accent); fill: none; stroke: var(--c-on-accent); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.kind__body { flex: 1; display: flex; flex-direction: column; gap: .4rem; padding: .9rem .85rem 1rem; }
.kind__name { font-size: 1.06rem; line-height: 1.2; }
.kind__fields { font-size: .84rem; line-height: 1.4; color: var(--c-ink-soft); }
.kind__links { margin-top: auto; padding-top: .3rem; display: flex; flex-wrap: wrap; gap: .25rem .75rem; font: 600 .84rem/1.3 var(--font-text); }
.kind__links a { color: var(--c-brand); text-decoration: underline; text-decoration-color: var(--c-accent); text-underline-offset: 3px; }
/* the seventh bar, the tallest, in brass: yours */
.kind--yours { min-height: calc(410px + 6 * 34px + 24px); background: var(--c-accent); color: var(--c-on-accent); box-shadow: var(--shadow-l); }
.kind--yours .kind__body { justify-content: flex-end; gap: .7rem; padding: 1.5rem 1.3rem 1.6rem; }
.kind__label { font: 500 var(--fs-ui)/1.2 var(--font-ui); letter-spacing: .08em; text-transform: uppercase; }
.kind--yours .kind__name { font-size: var(--fs-h2); line-height: 1.05; color: var(--c-on-accent); }
.kind--yours .kind__name em { color: var(--c-on-accent); }
.kind--yours .kind__fields { font-size: .95rem; color: var(--c-on-accent); }
.kind--yours .button { align-self: flex-start; margin-top: .4rem; padding-inline: 1.1rem; background: var(--c-brand); color: var(--c-on-brand); white-space: nowrap; }
.kind--yours .button:hover { background: var(--c-navy-lifted); }

/* ---------- the buyers, on the paper-alt with the motif faint beside the headline ---------- */
.buyers.motif-bars::before { right: auto; bottom: auto; left: 2%; top: 7%; width: min(14vw, 200px); }
.buyers .head { margin-inline: auto; }
.buyers__stage { position: relative; max-width: 1100px; margin-inline: auto; }
.buyers__stop { top: -10px; right: 0; }
.scene.buyers__scene { position: relative; min-height: 460px; }

/* ---------- a way in for everyone else: the chat in a phone over the florist ---------- */
.anyway__grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); align-items: center; gap: clamp(2rem, 1rem + 3vw, 4rem); }
.anyway__head { margin-bottom: 0; }
.anyway__frame { position: relative; min-height: 640px; }
.anyway__media { position: absolute; inset: 0 120px 0 0; overflow: hidden; border-radius: var(--radius-l); box-shadow: var(--shadow-m); background: var(--c-paper-alt); }
.anyway__stop { top: 14px; left: 14px; right: auto; }
.anyway__phone { position: absolute; right: 0; top: 50%; translate: 0 -50%; width: 344px; }
.phone { position: relative; width: min(100%, 344px); margin-inline: auto; border-radius: 44px; padding: 10px; background: var(--c-ink); box-shadow: 0 50px 90px -40px rgba(0, 0, 0, .75), inset 0 0 0 1px color-mix(in srgb, var(--c-on-ink) 14%, transparent); }
.phone__top { display: flex; align-items: center; gap: .7rem; padding: 16px 16px 12px; background: var(--c-card); border-radius: 34px 34px 0 0; border-bottom: 1px solid var(--c-line); color: var(--c-ink); }
.phone__avatar { width: 40px; height: 40px; border-radius: 12px; }
.phone__top b { display: block; font: 600 .98rem/1.2 var(--font-text); color: var(--c-brand); }
.phone__top small { display: block; font-size: .84rem; color: var(--c-ink-soft); }
.phone__screen { height: clamp(390px, 100svh - 360px, 470px); display: flex; flex-direction: column; justify-content: flex-end; gap: 8px; padding: 14px 12px 16px; overflow: hidden; background: var(--c-paper); border-radius: 0 0 34px 34px; color: var(--c-ink); }
.msg {
  max-width: 86%; align-self: flex-start; padding: .62rem .85rem; border-radius: 16px 16px 16px 5px; background: var(--c-card); box-shadow: var(--shadow-s);
  font-size: .93rem; line-height: 1.4; color: var(--c-ink);
  opacity: calc(var(--kit-in, 1) * (1 - var(--kit-out, 0))); transform: translateY(calc((1 - var(--kit-in, 1)) * 10px));
}
.msg--me { align-self: flex-end; border-radius: 16px 16px 5px 16px; background: var(--c-brand); color: var(--c-on-brand); }
.msg--typing { display: flex; gap: 5px; padding: .75rem .9rem; }
.msg--typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--c-ink-soft); animation: msg-dot 1.1s infinite ease-in-out; }
.msg--typing i:nth-child(2) { animation-delay: .15s; } .msg--typing i:nth-child(3) { animation-delay: .3s; }
@keyframes msg-dot { 0%, 60%, 100% { transform: translateY(0); opacity: .45; } 30% { transform: translateY(-4px); opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .msg--typing i { animation: none; } }
.msg__found { display: block; margin-bottom: .2rem; font-weight: 600; color: var(--c-brand); }
.msg--bar { display: grid; gap: .55rem; width: 86%; }
.msg--bar span { font-weight: 600; color: var(--c-brand); }
.msg--bar i { display: block; height: 6px; border-radius: 6px; background: linear-gradient(90deg, var(--c-accent) calc(var(--kit-fill, 0) * 100%), var(--c-paper-alt) 0); }
.msg--plan { width: 92%; max-width: 92%; display: grid; gap: .35rem; padding: .85rem .95rem; border: 1px solid var(--c-line); }
.msg__label { font: 500 var(--fs-ui)/1 var(--font-ui); letter-spacing: .08em; text-transform: uppercase; color: var(--c-accent-text); }
.msg__name { font: 600 1.2rem/1.15 var(--font-display); color: var(--c-brand); }
.msg__from { font-size: .86rem; color: var(--c-ink-soft); border-top: 1px solid var(--c-line); padding-top: .45rem; margin-top: .15rem; }

/* ---------- the close ---------- */
.closer--split .who__card { --card-l: 5%; --card-b: 6%; }

/* ---------- narrower ---------- */
@media (max-width: 1099.98px) {
  /* three kinds to a row, the brass bar a full row under them */
  .kinds__list { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: stretch; border-bottom: 0; }
  .kind { min-height: 0; border-radius: var(--radius-m); }
  .kind__photo { aspect-ratio: 4 / 3; }
  .kind--yours { grid-column: 1 / -1; min-height: 0; }
  .kind--yours .kind__body { padding: 1.4rem 1.3rem; }
}
@media (max-width: 899.98px) {
  /* a tall slice of the photo: her face above the phone, the phone over her counter (most of it on the photo) */
  .anyway__grid { grid-template-columns: minmax(0, 1fr); }
  .anyway__frame { min-height: 0; padding-bottom: 180px; }
  .anyway__media { position: relative; inset: auto; height: 860px; --pos: 23% 50% !important; }
  .anyway__phone { top: 548px; right: 0; translate: none; width: min(100%, 344px); }
  .anyway__phone .phone__screen { height: 400px; }
  .anyway__stop { top: 500px; left: auto; right: 14px; }
}
@media (max-width: 759.98px) {
  /* the phone: her face in the band's top, the scene on its glass over her phone and the pavement at the foot */
  .whh__band { height: 576px; overflow: visible; margin-bottom: 140px; }
  .whh__media, .whh__shade { border-radius: inherit; }
  .whh__zoom { width: 100%; height: 100%; }
  .whh__shade { background: linear-gradient(0deg, color-mix(in srgb, var(--c-brand) 30%, transparent) 0%, transparent 50%); }
  /* the glass over the band's foot (her face ends at 45% of the band), hanging a little onto the paper */
  .scene.whh__scene { left: 0; top: 390px; translate: none; width: 100%; height: 316px; }
  .kinds__list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kind__photo { aspect-ratio: 1; }
  .kind__body { padding: .8rem .75rem .9rem; }
  /* the cards open and fold at different heights: the column hangs from the top and its line stands at the foot, so
     nothing moves under the words being read (finding of step 13) */
  .scene.buyers__scene { min-height: 840px; }
  .scene.buyers__scene .tb { align-self: start; }
  .scene.buyers__scene .tb-foot { position: absolute; left: 20px; right: 20px; bottom: 12px; }
}
