/* The Identify and Extend examples: real brands' experiences in HTML, with real text and
   the brands' own photography, in place of the rendered scenes. Behaviour is in
   experience-demos.tsx. Identify: a clothing brand's registration page in a phone beside
   what the brand sees (stacked under a 560px stage). Extend: the rosé house's stories in a
   phone, with buttons beside it to jump to each (styles in extend-stories.css).
   Images: the clothing brand's page from Bart's Figma export with its name and logo left
   out. Display type: Cormorant Garamond, self-hosted (OFL), used only inside the
   examples. Transitions stay between 180 and 250ms. */

html body #jellybean-q-refined .capability-visual.xp-stage {
  --xp-ink: #151b11;
  --xp-muted: #59624f;
  --xp-line: #d8ddcf;
  --xp-olive: #33412a;
  --xp-ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  padding: 26px 26px 22px;
}

/* A label above the demo, so it reads as an example before anyone presses anything. */
html body #jellybean-q-refined .xp-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 30px;
  margin: 0 0 16px;
  padding: 4px 12px 4px 10px;
  border-radius: 10px;
  background: rgb(255 255 255 / 0.75);
  box-shadow: inset 0 0 0 1px rgb(21 27 17 / 0.1);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.35;
  color: var(--xp-ink);
}
html body #jellybean-q-refined .xp-label::before {
  content: "";
  flex: none;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #758c4d;
  box-shadow: 0 0 0 3px #d8f87f;
}

html body #jellybean-q-refined .xp-stage :where(p, dl, dd, ol, fieldset) {
  margin: 0;
}

/* Action beside result */
html body #jellybean-q-refined .xp-pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}
html body #jellybean-q-refined .xp-card {
  container-type: inline-size;
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--pl-hair);
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--pl-card-shadow);
  color: var(--xp-ink);
}

html body #jellybean-q-refined .xp-card-title {
  margin: 16px 0 12px;
  font-size: 19px;
  font-weight: 500;
  line-height: 1.25;
  letter-spacing: -0.01em;
}
html body #jellybean-q-refined .xp-form {
  display: grid;
  gap: 10px;
}

/* Fields: read-only, so nothing a visitor types is ever on the page */
html body #jellybean-q-refined .xp-field {
  display: grid;
  gap: 5px;
}
html body #jellybean-q-refined .xp-field label {
  font-size: 13px;
  font-weight: 500;
  color: var(--xp-muted);
}
html body #jellybean-q-refined .xp-field :is(input, textarea) {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--xp-line);
  border-radius: 10px;
  background: #fafbf7;
  font: inherit;
  font-size: 16px;
  line-height: 1.4;
  color: var(--xp-ink);
  cursor: default;
  resize: none;
}
html body #jellybean-q-refined .xp-field textarea {
  display: block;
}
html body #jellybean-q-refined .xp-field :is(input, textarea):focus-visible {
  outline: 2px solid #6d7f5c;
  outline-offset: 1px;
}
html body #jellybean-q-refined .xp-check {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  font-size: 14px;
  line-height: 1.35;
  cursor: pointer;
}
html body #jellybean-q-refined .xp-check input {
  flex: none;
  width: 20px;
  height: 20px;
  margin: 0;
  accent-color: var(--xp-ink);
  cursor: pointer;
}
html body #jellybean-q-refined .xp-check small {
  font-size: 13px;
  color: var(--xp-muted);
}

html body #jellybean-q-refined .xp-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 46px;
  margin-top: auto;
  padding: 10px 16px;
  border: 0;
  border-radius: 12px;
  background: var(--xp-ink);
  font: inherit;
  font-size: 15px;
  font-weight: 500;
  color: #fff;
  cursor: pointer;
  transition: transform 200ms var(--xp-ease), box-shadow 200ms var(--xp-ease), background-color 200ms var(--xp-ease);
}
html body #jellybean-q-refined .xp-form .xp-button {
  margin-top: 4px;
}
html body #jellybean-q-refined .xp-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 18px -10px rgb(21 27 17 / 0.5);
}
html body #jellybean-q-refined .xp-button:focus-visible {
  outline: 3px solid #b9d94f;
  outline-offset: 2px;
}

/* Result */
html body #jellybean-q-refined .xp-result {
  background: #fcfdf9;
}
html body #jellybean-q-refined .xp-result-title {
  padding-bottom: 12px;
  border-bottom: 1px solid var(--pl-hair);
  font-size: 15px;
  font-weight: 500;
}
/* Before the demo runs, the result shows the shape of what will appear, not a blank. */
html body #jellybean-q-refined .xp-ghost {
  display: grid;
  gap: 12px;
  margin-top: 14px;
  padding: 14px;
  border: 1px dashed #c9d1bd;
  border-radius: 12px;
}
html body #jellybean-q-refined .xp-ghost[hidden] {
  display: none;
}
html body #jellybean-q-refined .xp-ghost i {
  display: block;
  height: 10px;
  border-radius: 5px;
  background: #edf0e6;
}
html body #jellybean-q-refined .xp-ghost-person {
  display: flex;
  align-items: center;
  gap: 12px;
}
html body #jellybean-q-refined .xp-ghost-person > span {
  display: grid;
  flex: 1;
  gap: 8px;
}
html body #jellybean-q-refined .xp-ghost-person > span i:first-child { width: 55%; }
html body #jellybean-q-refined .xp-ghost-person > span i:last-child { width: 80%; }
html body #jellybean-q-refined .xp-ghost .xp-ghost-avatar {
  flex: none;
  width: 42px;
  height: 42px;
  border-radius: 50%;
}
html body #jellybean-q-refined .xp-ghost-facts {
  display: grid;
  gap: 8px;
}
html body #jellybean-q-refined .xp-ghost-facts i:first-child { width: 70%; }
html body #jellybean-q-refined .xp-ghost-facts i:last-child { width: 45%; }
html body #jellybean-q-refined .xp-ghost-note {
  font-size: 14px;
  line-height: 1.4;
  color: var(--xp-muted);
}

/* Under the result: earlier example registrations, or where reviews go */
html body #jellybean-q-refined .xp-earlier {
  padding-top: 18px;
}
html body #jellybean-q-refined .xp-earlier-title {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding-bottom: 6px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--xp-muted);
}
html body #jellybean-q-refined .xp-earlier-title span + span {
  font-weight: 400;
}
html body #jellybean-q-refined .xp-earlier ul {
  margin: 0;
  padding: 0;
  list-style: none;
}
html body #jellybean-q-refined .xp-earlier li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 0;
  border-top: 1px solid var(--pl-hair);
}
html body #jellybean-q-refined .xp-earlier li > span:not(.xp-avatar):not(.xp-when) {
  display: grid;
  flex: 1;
  min-width: 0;
  line-height: 1.3;
}
html body #jellybean-q-refined .xp-earlier strong {
  font-size: 14px;
  font-weight: 500;
}
html body #jellybean-q-refined .xp-earlier li > span > span {
  font-size: 12.5px;
  color: var(--xp-muted);
}
html body #jellybean-q-refined .xp-earlier .xp-avatar {
  width: 30px;
  height: 30px;
  background: #eef1e6;
  font-size: 11px;
}
html body #jellybean-q-refined .xp-when {
  flex: none;
  font-size: 12.5px;
  color: var(--xp-muted);
}

html body #jellybean-q-refined .xp-record {
  display: grid;
  gap: 14px;
  margin-top: 14px;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 220ms var(--xp-ease), transform 220ms var(--xp-ease);
}
html body #jellybean-q-refined .xp-record[hidden] {
  display: none;
}
html body #jellybean-q-refined .xp-record[data-shown] {
  opacity: 1;
  transform: none;
}
html body #jellybean-q-refined .xp-record-kicker {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 12px;
  color: var(--xp-muted);
}
html body #jellybean-q-refined .xp-record-kicker span:first-child {
  padding: 4px 9px;
  border-radius: 999px;
  background: #e8f6bd;
  font-weight: 500;
  color: #263522;
}
html body #jellybean-q-refined .xp-person {
  display: flex;
  align-items: center;
  gap: 12px;
}
html body #jellybean-q-refined .xp-person > span:last-child {
  display: grid;
  min-width: 0;
  line-height: 1.35;
}
html body #jellybean-q-refined .xp-person strong {
  font-size: 17px;
  font-weight: 500;
}
html body #jellybean-q-refined .xp-person > span:last-child > span {
  overflow-wrap: anywhere;
  font-size: 14px;
  color: var(--xp-muted);
}
html body #jellybean-q-refined .xp-avatar {
  display: grid;
  flex: none;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #d8f87f;
  font-size: 14px;
  font-weight: 600;
  color: #263522;
}
html body #jellybean-q-refined .xp-facts {
  display: grid;
  border-top: 1px solid var(--pl-hair);
}
html body #jellybean-q-refined .xp-facts > div {
  display: grid;
  gap: 2px;
  padding: 10px 0;
  border-bottom: 1px solid var(--pl-hair);
}
html body #jellybean-q-refined .xp-facts dt {
  font-size: 12px;
  color: var(--xp-muted);
}
html body #jellybean-q-refined .xp-facts dd {
  font-size: 15px;
  line-height: 1.35;
}
html body #jellybean-q-refined .xp-fine {
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--xp-muted);
}


@font-face {
  font-family: JbDemoCormorant;
  src: url("assets/fonts/cormorant-garamond-500.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}

/* ------------------------------------------------------------ Phone (both examples) */
html body #jellybean-q-refined .mx-phone {
  justify-self: center;
  width: 100%;
  height: 640px;
  padding: 8px;
  border-radius: 42px;
  background: #151b11;
  box-shadow: 0 30px 60px -30px rgb(21 27 17 / 0.45);
}
html body #jellybean-q-refined .mx-screen {
  height: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
  border-radius: 34px;
  scrollbar-width: none;
}

/* Extend's jump buttons */
html body #jellybean-q-refined .mx {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 320px);
  gap: 28px;
  align-items: center;
}
html body #jellybean-q-refined .mx-index-title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 30px;
  padding: 4px 12px 4px 10px;
  border-radius: 10px;
  background: rgb(255 255 255 / 0.75);
  box-shadow: inset 0 0 0 1px rgb(21 27 17 / 0.1);
  font-size: 13px;
  font-weight: 500;
  color: var(--jq-ink);
}
html body #jellybean-q-refined .mx-index-title::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #758c4d;
  box-shadow: 0 0 0 3px #d8f87f;
}
html body #jellybean-q-refined .mx-index-line {
  margin: 14px 0 12px;
  font-size: 15px;
  line-height: 1.45;
  color: var(--jq-muted);
}
html body #jellybean-q-refined .mx-jumps {
  display: grid;
  gap: 8px;
}
html body #jellybean-q-refined .mx-jumps button {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid rgb(21 27 17 / 0.12);
  border-radius: 12px;
  background: rgb(255 255 255 / 0.6);
  font: inherit;
  font-size: 15px;
  font-weight: 500;
  color: var(--jq-ink);
  text-align: left;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 200ms var(--xp-ease), color 200ms var(--xp-ease), border-color 200ms var(--xp-ease);
}
html body #jellybean-q-refined .mx-jumps button:hover {
  background: #fff;
}
html body #jellybean-q-refined .mx-jumps button[aria-pressed="true"] {
  border-color: #33412a;
  background: #33412a;
  color: #fff;
}
html body #jellybean-q-refined :is(.mx-jumps button, .mx-screen, .cl-again):focus-visible {
  outline: 3px solid #b9d94f;
  outline-offset: 2px;
}

/* ------------------------------------------------- Identify: a clothing brand's page */
html body #jellybean-q-refined .cl-pair {
  grid-template-columns: minmax(0, 300px) minmax(0, 1fr);
  align-items: center;
}
html body #jellybean-q-refined .cl-phone {
  height: auto;
}
html body #jellybean-q-refined .cl-screen {
  --cl-ink: #111;
  --cl-soft: #6b6a66;
  --cl-panel: #ede9e6;
  --cl-card: #f6f6f3;
  height: auto;
  min-height: 600px;
  overflow: visible;
  padding: 14px 12px 16px;
  background: #e9e7e2;
  color: var(--cl-ink);
}
html body #jellybean-q-refined .cl-cert {
  padding: 10px;
  background: #fff;
}
html body #jellybean-q-refined .cl-cert-top {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}
html body #jellybean-q-refined .cl-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: #eceae6;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  color: var(--cl-ink);
}
html body #jellybean-q-refined .cl-pill[hidden] {
  display: none;
}
html body #jellybean-q-refined .cl-pill svg {
  width: 11px;
  height: 11px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
html body #jellybean-q-refined .cl-cert-top .cl-pill:last-child {
  margin-left: auto;
}
html body #jellybean-q-refined .cl-pill-dark {
  background: #111;
  color: #fff;
}
html body #jellybean-q-refined .cl-photo {
  display: grid;
  place-items: center;
  aspect-ratio: 1 / 0.92;
  border-radius: 10px;
  background: var(--cl-panel);
  overflow: hidden;
}
html body #jellybean-q-refined .cl-photo img {
  width: auto;
  height: 100%;
}
html body #jellybean-q-refined .cl-name {
  margin-top: 8px;
  padding: 9px 10px;
  background: #111;
  font-family: JbDemoCormorant, Georgia, serif;
  font-size: 17px;
  font-weight: 500;
  line-height: 1.2;
  text-align: center;
  color: #fff;
}
html body #jellybean-q-refined .cl-form,
html body #jellybean-q-refined .cl-closet {
  margin-top: 10px;
  padding: 14px 14px 16px;
  background: #fff;
}
html body #jellybean-q-refined :is(.cl-form, .cl-closet)[hidden] {
  display: none;
}
html body #jellybean-q-refined .cl-title {
  font-family: JbDemoCormorant, Georgia, serif;
  font-size: 23px;
  font-weight: 500;
  line-height: 1.15;
  color: var(--cl-ink);
  outline: none;
}
html body #jellybean-q-refined .cl-form .xp-form {
  gap: 8px;
  margin-top: 10px;
}
html body #jellybean-q-refined .cl-screen .xp-field label {
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--cl-soft);
}
html body #jellybean-q-refined .cl-screen .xp-field input {
  min-height: 40px;
  padding: 6px 0;
  border: 0;
  border-bottom: 1px solid #1112;
  border-radius: 0;
  background: transparent;
  font-size: 16px;
}
html body #jellybean-q-refined .cl-screen .xp-check {
  min-height: 40px;
  font-size: 13px;
}
html body #jellybean-q-refined .cl-screen .xp-check input {
  accent-color: #111;
}
html body #jellybean-q-refined .cl-screen .xp-button {
  min-height: 44px;
  border-radius: 0;
  background: #111;
  font-size: 12.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
html body #jellybean-q-refined .cl-sub {
  margin-top: 2px;
  font-size: 12.5px;
  color: var(--cl-soft);
}
html body #jellybean-q-refined .cl-closet:not([hidden]) {
  animation: xp-fade 220ms var(--xp-ease);
}
/* The closet scrolls sideways, as on the brand's page, so the screen keeps its height. */
html body #jellybean-q-refined .cl-items {
  display: flex;
  gap: 8px;
  margin: 12px -14px 0;
  padding: 0 14px 4px;
  overflow-x: auto;
  list-style: none;
  scrollbar-width: none;
}
html body #jellybean-q-refined .cl-items::-webkit-scrollbar {
  display: none;
}
html body #jellybean-q-refined .cl-items li {
  flex: none;
  width: 108px;
  display: grid;
  justify-items: center;
  gap: 6px;
  padding: 8px 6px 10px;
  border-radius: 10px;
  background: var(--cl-card);
}
html body #jellybean-q-refined .cl-items .cl-new {
  box-shadow: inset 0 0 0 1px #111;
}
html body #jellybean-q-refined .cl-item-img {
  display: grid;
  place-items: center;
  height: 74px;
}
html body #jellybean-q-refined .cl-item-img img {
  width: auto;
  max-width: 100%;
  height: 74px;
  object-fit: contain;
}
html body #jellybean-q-refined .cl-items .cl-new .cl-item-img img {
  border-radius: 6px;
}
html body #jellybean-q-refined .cl-item-name {
  font-size: 11.5px;
  white-space: nowrap;
}
html body #jellybean-q-refined .cl-again {
  display: block;
  width: 100%;
  min-height: 44px;
  margin-top: 12px;
  border: 1px solid #111;
  border-radius: 0;
  background: transparent;
  font: inherit;
  font-size: 12.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #111;
  cursor: pointer;
}

@keyframes xp-fade {
  from { opacity: 0; }
}

/* Narrow stages: the brand's page first, the brand's view under it; the jump buttons sit
   in a row above the phone */
@container scene-stage (max-width: 559px) {
  html body #jellybean-q-refined .xp-pair,
  html body #jellybean-q-refined .cl-pair {
    grid-template-columns: minmax(0, 1fr);
  }
  html body #jellybean-q-refined .cl-phone {
    justify-self: center;
    max-width: 340px;
  }
  html body #jellybean-q-refined :is(.xp-ghost-note, .xp-facts dd) {
    font-size: 16px;
  }
  html body #jellybean-q-refined .mx {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }
  html body #jellybean-q-refined .mx-index-line {
    display: none;
  }
  html body #jellybean-q-refined .mx-jumps {
    display: flex;
    gap: 6px;
    margin: 12px -14px 0;
    padding: 0 14px 4px;
    overflow-x: auto;
    scrollbar-width: none;
  }
  html body #jellybean-q-refined .mx-jumps button {
    flex: none;
    min-height: 40px;
    border-radius: 999px;
    font-size: 14px;
  }
  html body #jellybean-q-refined .mx-phone:not(.cl-phone) {
    max-width: 360px;
    height: 600px;
  }
}
@media (max-width: 680px) {
  html body #jellybean-q-refined .capability-visual.xp-stage {
    padding: 20px 14px 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html body #jellybean-q-refined .xp-record {
    transform: none;
    transition: none;
  }
  html body #jellybean-q-refined .cl-closet:not([hidden]) {
    animation: none;
  }
  html body #jellybean-q-refined :is(.xp-button, .mx-jumps button) {
    transition: none;
  }
  html body #jellybean-q-refined .xp-button:hover {
    transform: none;
  }
}
