.cd-shell {
  --cd-bg: #100e17;
  --cd-panel: #181320;
  --cd-line: #302637;
  --cd-muted: #ada2b8;
  --cd-accent: #dfb5fa;
  --cd-pink: #f5a2cf;
  min-height: 100svh;
  background: var(--cd-bg);
  color: #f5effa;
  font-family: 'Public Sans Variable', system-ui, sans-serif;
  color-scheme: dark;
  font-size: 14px;
}
.cd-shell * {
  box-sizing: border-box;
}
.cd-shell button,
.cd-shell input,
.cd-shell textarea,
.cd-shell select {
  font: inherit;
}
.cd-shell button,
.cd-shell a {
  touch-action: manipulation;
}
.cd-shell button {
  cursor: pointer;
}
.cd-shell button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.cd-shell a {
  text-decoration: none;
  color: inherit;
}
.cd-shell :is(a, button, input, select, textarea):focus-visible {
  outline: 2px solid #eeaede;
  outline-offset: 4px;
}
.cd-shell button {
  border: 0;
}
.cd-shell .cd-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  background: linear-gradient(115deg, #e8c4ff, #f5b4d4);
  color: #301c3b;
  border-radius: 10px;
  padding: 13px 20px;
  font-size: 13px;
  font-weight: 700;
  transition: filter 0.2s;
}
.cd-primary:hover {
  filter: brightness(1.1);
}
.cd-skip {
  position: fixed;
  z-index: 100;
  left: 12px;
  top: -80px;
  background: #dcb7f8;
  padding: 12px;
  color: #1c1522 !important;
}
.cd-skip:focus {
  top: 12px;
}
.cd-sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 232px;
  z-index: 40;
  background: #15101d;
  border-right: 1px solid #2a2032;
  display: flex;
  flex-direction: column;
  padding: 30px 18px 16px;
  overflow-y: auto;
}
.cd-brand-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 0 2px 42px;
}
.cd-brand {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 20px;
  letter-spacing: -1.1px;
  font-weight: 750;
}
.cd-brand-mark {
  display: grid;
  place-items: center;
  width: 32px;
  height: 34px;
  color: #f1b4df;
}
.cd-brand-dot {
  color: #efa5d8;
  margin-left: -8px;
}
.cd-nav-caption {
  font-size: 9px;
  letter-spacing: 1.7px;
  font-weight: 700;
  color: #90819e;
  margin: 0 12px 15px;
}
.cd-nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.cd-nav > a {
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 44px;
  padding: 12px;
  border-radius: 10px;
  color: #b6aabe;
  font-size: 12px;
  font-weight: 500;
  transition:
    background 0.15s,
    color 0.15s;
}
.cd-nav > a:hover {
  background: #281e33;
  color: #f3e7fc;
}
.cd-nav > a.is-active {
  background: linear-gradient(100deg, #382347, #2b1e36);
  color: #eac5fc;
  box-shadow: inset 3px 0 #c58ee6;
}
.cd-nav-new {
  font-size: 9px;
  font-weight: 650;
  border: 1px solid #755289;
  border-radius: 5px;
  padding: 2px 5px;
  margin-left: auto;
}
.cd-nav > a.cd-create-nav {
  margin-top: 10px;
  border: 1px solid #66466e;
  background: #251a2e;
  color: #e8bde8;
}
.cd-nav-end {
  margin-left: auto;
  color: #786b85;
}
.cd-nav-bottom {
  margin-top: auto;
  padding-top: 36px;
}
.cd-unlimit {
  padding: 18px 14px;
  border: 1px solid #594062;
  border-radius: 13px;
  background:
    radial-gradient(ellipse at 90% 0, #51304f, transparent 75%), #25192e;
}
.cd-unlimit > svg {
  color: #e2a8e9;
  margin-bottom: 11px;
}
.cd-unlimit strong {
  display: block;
  font-size: 13px;
  line-height: 1.7;
}
.cd-unlimit p {
  font-size: 11px;
  line-height: 1.8;
  color: #c0adcc;
  margin: 6px 0 14px;
}
.cd-unlimit a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  color: #f0b9e3;
  font-weight: 650;
}
.cd-profile {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 21px 2px 16px;
  min-width: 0;
}
.cd-avatar {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border: 1px solid #5c3b66;
  border-radius: 50%;
  background: #2b1b39;
  color: #e2b3ed;
  flex-shrink: 0;
}
.cd-profile > span:nth-child(2) {
  min-width: 0;
  flex: 1;
}
.cd-profile strong,
.cd-profile small {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cd-profile strong {
  font-size: 10px;
}
.cd-profile small {
  font-size: 9px;
  color: #a595b1;
  margin-top: 5px;
}
.cd-safety {
  font-size: 10px;
  color: #9685a4 !important;
  display: flex;
  align-items: center;
  gap: 6px;
  padding-left: 4px;
}
.cd-content {
  margin-left: 232px;
  min-width: 0;
}
.cd-header {
  height: 76px;
  padding: 0 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #251e2c;
  gap: 12px;
}
.cd-header-left,
.cd-header-right {
  display: flex;
  align-items: center;
  gap: 17px;
  min-width: 0;
}
.cd-header-label {
  font-size: 11px;
  color: #b5a5c2;
  letter-spacing: 0.2px;
}
.cd-fiction-label {
  font-size: 10px;
  color: #8f809d;
}
.cd-header .cd-header-login {
  padding: 9px 13px;
  border: 1px solid #4c3659;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 11px;
  font-weight: 600;
  background: #24192e;
}
.cd-header button {
  color: #c5b2d4;
}
.cd-main {
  max-width: 1530px;
  margin: 0 auto;
  padding: 28px 34px 20px;
  outline: none;
}
.cd-hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 280px;
  overflow: hidden;
  border: 1px solid #503555;
  border-radius: 17px;
  background:
    radial-gradient(ellipse at 92% 70%, #684051 0, transparent 50%),
    linear-gradient(110deg, #2d1c42, #281a38 48%, #3c2448);
  padding: 32px 36px;
}
.cd-hero-copy {
  position: relative;
  z-index: 2;
  width: 55%;
  max-width: 490px;
}
.cd-eyebrow {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 9px;
  letter-spacing: 1.9px;
  color: #d3a9e3;
  font-weight: 650;
}
.cd-eyebrow > span {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #efb7db;
}
.cd-hero h1 {
  font-size: 45px;
  letter-spacing: -2.2px;
  line-height: 1.14;
  font-weight: 700;
  margin: 15px 0 12px;
}
.cd-hero h1 span {
  display: block;
  color: #f0a8d3;
}
.cd-hero-copy > p {
  max-width: 300px;
  font-size: 12px;
  line-height: 1.9;
  color: #cdbed8;
  margin: 0 0 20px;
}
.cd-hero .cd-primary {
  font-size: 11px;
  padding: 11px 15px;
  gap: 22px;
}
.cd-hero-footnote {
  display: block;
  font-size: 9px;
  color: #a48bb5;
  margin-top: 12px;
}
.cd-hero-art {
  position: absolute;
  inset: 0 0 0 49%;
  pointer-events: none;
}
.cd-hero-portrait {
  position: absolute;
  width: 184px;
  height: 265px;
  border: 5px solid #644e72;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 15px 45px #120c2777;
  background: #312641;
}
.cd-hero-portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.cd-hero-portrait > span {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 30px 14px 12px;
  background: linear-gradient(transparent, #130e25);
  font-size: 13px;
  font-weight: 600;
  display: flex;
  justify-content: space-between;
}
.cd-hero-portrait > span > span {
  color: #e0bbef;
}
.cd-hero-kai {
  top: 12px;
  left: 14%;
  transform: rotate(-13deg);
}
.cd-hero-luna {
  top: 57px;
  left: 46%;
  transform: rotate(11deg);
  border-color: #a67c9e;
}
.cd-orbit {
  position: absolute;
  border: 1px solid #cb8cbe3d;
  width: 410px;
  height: 410px;
  border-radius: 50%;
  top: -58px;
  left: 13%;
}
.cd-orbit-two {
  width: 500px;
  height: 500px;
  left: 4%;
  top: -102px;
}
.cd-spark-one {
  position: absolute;
  top: 33px;
  right: 13%;
  width: 30px;
  height: 30px;
  color: #f0bddc;
  transform: rotate(12deg);
}
.cd-hero-bubble {
  position: absolute;
  bottom: 22px;
  left: 7%;
  display: flex;
  gap: 8px;
  align-items: center;
  border: 1px solid #926981;
  background: #42263edb;
  backdrop-filter: blur(12px);
  padding: 12px 17px;
  border-radius: 10px;
  font-size: 10px;
  transform: rotate(-5deg);
  box-shadow: 0 5px 20px #170d2266;
  color: #ffe0ef;
}
.cd-hero-bubble svg {
  color: #f3a7cc;
}
.cd-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin: 34px 0 21px;
}
.cd-section-heading h2 {
  margin: 0;
  font-size: 22px;
  font-weight: 650;
  letter-spacing: -0.7px;
}
.cd-section-heading p {
  margin: 8px 0 0;
  color: #a797b6;
  font-size: 11px;
  line-height: 1.7;
}
.cd-editorial-label {
  color: #baa0ce;
  font-size: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.cd-controls {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 22px;
}
.cd-categories {
  display: flex;
  gap: 5px;
  overflow-x: auto;
  scrollbar-width: none;
  min-width: 0;
  flex: 1;
  padding: 4px;
}
.cd-categories::-webkit-scrollbar {
  display: none;
}
.cd-categories button {
  display: flex;
  gap: 6px;
  align-items: center;
  white-space: nowrap;
  background: transparent;
  color: #a998b8;
  padding: 10px 13px;
  border-radius: 9px;
  font-size: 11px;
  font-weight: 550;
}
.cd-categories button:hover {
  background: #211a2a;
  color: #ebd6fa;
}
.cd-categories button.is-active {
  color: #e7c5f8;
  background: #342341;
  box-shadow: inset 0 0 0 1px #66467a;
}
.cd-search {
  display: flex;
  align-items: center;
  gap: 9px;
  background: #1c1625;
  border: 1px solid #32283e;
  border-radius: 9px;
  padding: 10px 12px;
  width: 248px;
  flex-shrink: 0;
  color: #9a85ad;
}
.cd-search input {
  width: 100%;
  min-width: 0;
  color: #e9d8f5;
  background: transparent;
  border: 0;
  outline: none;
  font-size: 10px;
}
.cd-search input::placeholder {
  color: #a38ab5;
}
.cd-search button {
  display: flex;
  color: #c8b2da;
  background: none;
  padding: 0;
}
.cd-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}
.cd-card {
  position: relative;
  border-radius: 13px;
  border: 1px solid #443348;
  background: #1e1728;
  overflow: hidden;
  min-width: 0;
  transition:
    transform 0.2s,
    border-color 0.2s;
}
.cd-card:hover {
  transform: translateY(-4px);
  border-color: #b17cab;
}
.cd-card-open {
  width: 100%;
  display: block;
  position: relative;
  text-align: left;
  color: inherit;
  padding: 0;
  background: none;
  aspect-ratio: 3/4.5;
  min-height: 318px;
}
.cd-card-open > img {
  display: block;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 30%;
  transition: transform 0.5s;
}
.cd-card:hover .cd-card-open > img {
  transform: scale(1.04);
}
.cd-card-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    transparent 28%,
    #110d1a22 40%,
    #110d1ae8 75%,
    #110d1a 100%
  );
}
.cd-card-copy {
  position: absolute;
  inset: auto 15px 16px;
}
.cd-character-kind {
  display: inline-block;
  font-size: 8px;
  letter-spacing: 0.8px;
  color: #e2c4ed;
  margin-bottom: 7px;
}
.cd-card h3 {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 21px;
  font-weight: 650;
  letter-spacing: -0.5px;
  margin: 0 0 5px;
}
.cd-card h3 svg {
  color: #b09cba;
  opacity: 0.7;
}
.cd-card-subtitle {
  font-size: 10px;
  font-weight: 550;
  line-height: 1.6;
  margin: 0 0 8px;
  color: #ead6f1;
}
.cd-card-description {
  font-size: 10px;
  line-height: 1.75;
  color: #b3a1be;
  margin: 0 0 11px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.cd-tags {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}
.cd-tags > span {
  font-size: 8px;
  background: #45334d99;
  color: #dac0e6;
  padding: 4px 7px;
  border-radius: 5px;
  border: 1px solid #7d5d822e;
}
.cd-favorite {
  position: absolute;
  right: 10px;
  top: 11px;
  display: grid;
  place-items: center;
  width: 31px;
  height: 31px;
  border-radius: 50%;
  background: #170f285c !important;
  backdrop-filter: blur(8px);
  color: #e9d8ec;
  border: 1px solid #d7adcf45 !important;
}
.cd-favorite.is-favorite {
  color: #f6afd5;
  background: #442741 !important;
}
.cd-empty {
  min-height: 280px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  text-align: center;
  color: #b9a4ca;
  padding: 24px;
}
.cd-empty h3,
.cd-empty h2 {
  color: #eddbf7;
  font-size: 22px;
  margin: 0;
}
.cd-empty p {
  max-width: 390px;
  line-height: 1.8;
}
.cd-bottom-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  border: 1px solid #402c4b;
  border-radius: 12px;
  margin-top: 29px;
  padding: 22px 23px;
  background: linear-gradient(100deg, #24182e, #1b1523);
}
.cd-bottom-banner > div {
  display: flex;
  align-items: center;
  gap: 15px;
  color: #d6a2ee;
}
.cd-bottom-banner strong {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #f0dbfa;
}
.cd-bottom-banner small {
  display: block;
  font-size: 10px;
  color: #a991bb;
  margin-top: 6px;
  line-height: 1.7;
}
.cd-bottom-banner > a {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 11px;
  white-space: nowrap;
  color: #e8b6f0;
}
.cd-footer {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 9px;
  color: #8c799b;
  padding-top: 27px;
  line-height: 1.8;
}
.cd-footer > span:nth-child(2) {
  margin-left: auto;
}
.cd-icon-button {
  background: transparent;
  color: #c8afd9;
  padding: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
}
.cd-icon-button:hover {
  background: #37253f;
}
.cd-menu-close,
.cd-mobile-toggle {
  display: none;
}
.cd-conversation {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 275px;
  gap: 24px;
  height: calc(100svh - 128px);
  min-height: 550px;
}
.cd-chat-main {
  display: flex;
  flex-direction: column;
  border: 1px solid #3a2b45;
  border-radius: 16px;
  overflow: hidden;
  background: #18121f;
  min-width: 0;
  min-height: 0;
}
.cd-chat-header {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 15px 18px;
  border-bottom: 1px solid #33233e;
}
.cd-chat-header > img {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  object-fit: cover;
}
.cd-chat-header h1 {
  font-size: 16px;
  margin: 0;
  overflow-wrap: anywhere;
}
.cd-chat-header > div {
  min-width: 0;
}
.cd-chat-header > button {
  flex-shrink: 0;
}
.cd-profile-toggle {
  margin-left: auto;
}
.cd-profile-toggle + .cd-reset {
  margin-left: 0;
}
.cd-chat-header span {
  font-size: 10px;
  color: #b19cc2;
  display: block;
  margin-top: 4px;
}
.cd-reset {
  margin-left: auto;
}
.cd-chat-log {
  overflow-y: auto;
  overscroll-behavior: contain;
  flex: 1;
  min-height: 0;
  padding: 24px 28px;
  scrollbar-width: thin;
  scrollbar-color: #5f426c transparent;
}
.cd-chat-intro {
  text-align: center;
  margin: 4px 0 30px;
}
.cd-chat-intro > img {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #674279;
}
.cd-chat-intro > .cd-eyebrow {
  justify-content: center;
  margin-top: 16px;
}
.cd-chat-intro h2 {
  font-size: 26px;
  margin: 8px 0;
}
.cd-chat-intro p {
  font-size: 12px;
  color: #b59cc8;
  margin: 0;
}
.cd-message {
  max-width: 88%;
  margin: 0 0 18px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.cd-message > span {
  display: block;
  color: #a98fbf;
  font-size: 10px;
  margin-bottom: 8px;
}
.cd-message p {
  padding: 14px 17px;
  background: #281d33;
  border: 1px solid #3e2c4b;
  border-radius: 2px 14px 14px 14px;
  line-height: 1.85;
  font-size: 13px;
  margin: 0;
  color: #e3d5ed;
}
.cd-message-user {
  margin-left: auto;
}
.cd-message-user > span {
  text-align: right;
}
.cd-message-user p {
  background: #422b51;
  border-color: #5d3b70;
  border-radius: 14px 2px 14px 14px;
}
.cd-message-error p {
  color: #ffbfd7;
  border-color: #9b4c6d;
}
.cd-message > button {
  color: #f1c5e8;
  background: #42263f;
  border-radius: 6px;
  padding: 7px 12px;
  margin-top: 8px;
}
.cd-composer-area {
  padding: 15px 22px;
  border-top: 1px solid #31213e;
  max-height: 55%;
  display: flex;
  flex-direction: column;
  min-height: 0;
  flex-shrink: 0;
  scrollbar-width: thin;
}
.cd-chat-controls {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
}
.cd-chat-controls:empty {
  display: none;
}
.cd-composer-area > .cd-composer,
.cd-composer-area > .cd-chat-note {
  flex-shrink: 0;
}
.cd-composer {
  display: flex;
  gap: 12px;
  align-items: flex-end;
  background: #22192d;
  border: 1px solid #574066;
  border-radius: 12px;
  padding: 10px;
}
.cd-composer textarea {
  width: 100%;
  background: none;
  border: 0;
  resize: none;
  padding: 3px 4px;
  font-size: 13px;
  min-height: 44px;
  max-height: 140px;
  color: #eedcf9;
  line-height: 1.6;
}
.cd-send {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 35px;
  height: 35px;
  border-radius: 9px;
  background: #e2b3eb;
  color: #3a1e4b;
}
.cd-chat-note {
  font-size: 9px;
  color: #a68bb9;
  text-align: center;
  line-height: 1.6;
  margin: 11px 0 0;
}
.cd-model-label {
  display: flex;
  gap: 9px;
  align-items: center;
  font-size: 10px;
  color: #bca5cd;
  margin-bottom: 11px;
  flex-wrap: wrap;
}
.cd-model-label select {
  max-width: 200px;
  background: #281b34;
  border: 1px solid #50375f;
  border-radius: 6px;
  padding: 4px 7px;
  font-size: 10px;
  color: #ebd1f5;
}
.cd-model-label a {
  margin-left: auto;
  text-decoration: underline;
}
.cd-chat-auth {
  display: flex;
  align-items: center;
  flex-direction: column;
  gap: 12px;
  padding: 5px 0;
}
.cd-chat-auth > p {
  font-size: 12px;
  color: #cbb2d9;
  margin: 0;
}
.cd-chat-auth > a:last-child {
  font-size: 10px;
  text-decoration: underline;
  color: #c9abd9;
  line-height: 1.8;
  text-align: center;
}
.cd-character-profile {
  border: 1px solid #3a2a45;
  border-radius: 16px;
  overflow-y: auto;
  background: #211629;
  scrollbar-width: thin;
}
.cd-character-profile > img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  object-position: 50% 25%;
}
.cd-character-profile > div {
  padding: 24px;
}
.cd-character-profile h2 {
  font-size: 26px;
  margin: 10px 0;
}
.cd-character-profile p {
  font-size: 12px;
  line-height: 1.9;
  color: #c0a7d0;
}
.cd-character-profile .cd-tags {
  margin-top: 20px;
}
.cd-character-profile hr {
  border: 0;
  border-top: 1px solid #4b3256;
  margin: 24px 0;
}
.cd-profile-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.cd-profile-note svg {
  flex-shrink: 0;
  margin-top: 4px;
}
.cd-inline-notice {
  border: 1px solid #67476b;
  background: #322039;
  padding: 12px;
  font-size: 12px;
  line-height: 1.7;
}
.cd-inline-notice p {
  margin: 0 0 8px;
}
.cd-inline-notice button {
  background: #d6a9e5;
  color: #2b1837;
  padding: 6px 12px;
  margin: 0 8px 0 0;
  border-radius: 5px;
}
.cd-creator {
  max-width: 850px;
  margin: auto;
}
.cd-creator h1 {
  font-size: 32px;
  letter-spacing: -1px;
  line-height: 1.3;
  margin: 15px 0;
}
.cd-character-form {
  padding: 28px;
  border: 1px solid #44304f;
  background: #1b1323;
  border-radius: 15px;
}
.cd-character-form fieldset {
  border: 0;
  padding: 0;
  margin: 0 0 25px;
}
.cd-character-form legend {
  font-size: 12px;
  margin-bottom: 14px;
}
.cd-portrait-upload {
  display: grid;
  gap: 12px;
  margin-bottom: 16px;
}
.cd-portrait-upload > p {
  margin: 0;
  color: #b9a7c2;
  font-size: 12px;
}
.cd-portrait-preview {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid #b889ac22;
  background: #0b081080;
}
.cd-portrait-preview img {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #efb4e4;
}
.cd-portrait-preview > div {
  display: grid;
  gap: 8px;
  justify-items: start;
  font-size: 12px;
  color: #cbb6ce;
}
.cd-portrait-preview button {
  padding: 6px 11px;
  border-radius: 8px;
  border: 1px solid #6d4f6b;
  background: transparent;
  color: #e8d6e4;
  font-size: 11px;
  cursor: pointer;
}
.cd-portrait-preview button:disabled {
  opacity: 0.45;
  cursor: default;
}
.cd-portrait-picker {
  display: grid;
  gap: 6px;
  font-size: 12px;
  color: #d8c4d4;
}
.cd-portrait-picker input[type='file'] {
  width: 100%;
  padding: 10px;
  border-radius: 10px;
  border: 1px dashed #805c7d;
  background: #120d18;
  color: #cbb6ce;
  font-size: 12px;
  cursor: pointer;
}
.cd-portrait-picker input[type='file']:focus-visible {
  outline: 2px solid #efb4e4;
  outline-offset: 2px;
}
.cd-portrait-picker small {
  color: #9c8c9f;
  font-size: 11px;
  line-height: 1.6;
}
.cd-portrait-options {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 10px;
}
.cd-portrait-options label {
  position: relative;
}
.cd-portrait-options img {
  aspect-ratio: 1/1.3;
  border-radius: 9px;
  border: 2px solid transparent;
  width: 100%;
  object-fit: cover;
}
.cd-portrait-options input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}
.cd-portrait-options input:checked + img {
  border-color: #efb4e4;
  box-shadow: 0 0 0 2px #50305e;
}
.cd-portrait-options input:focus-visible + img {
  outline: 2px solid #efb4e4;
  outline-offset: 4px;
}
.cd-form-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 19px;
}
.cd-form-fields label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 12px;
}
.cd-form-fields label:has(textarea) {
  grid-column: 1/-1;
}
.cd-form-fields input,
.cd-form-fields textarea,
.cd-form-fields select {
  background: #24192d;
  border: 1px solid #51365e;
  padding: 12px;
  color: #efd9fb;
  border-radius: 8px;
  width: 100%;
  resize: vertical;
}
.cd-form-fields [aria-invalid='true'] {
  border-color: #ed86b3;
}
.cd-checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: #cbb2d8;
  margin: 23px 0;
}
.cd-checkbox input {
  accent-color: #d49eea;
  width: 16px;
  height: 16px;
}
.cd-field-error {
  font-size: 11px;
  color: #ffadce;
  line-height: 1.7;
}
.cd-character-form > .cd-primary {
  margin-top: 8px;
}
@media (min-width: 1600px) {
  .cd-card-open {
    aspect-ratio: 3/4;
  }
  .cd-hero {
    min-height: 310px;
  }
  .cd-hero h1 {
    font-size: 54px;
  }
  .cd-hero-portrait {
    width: 208px;
    height: 290px;
  }
  .cd-hero-luna {
    top: 60px;
    left: 48%;
  }
}
@media (max-width: 1200px) {
  .cd-sidebar {
    width: 210px;
    padding-left: 13px;
    padding-right: 13px;
  }
  .cd-brand {
    font-size: 18px;
  }
  .cd-content {
    margin-left: 210px;
  }
  .cd-main {
    padding: 24px;
  }
  .cd-header {
    padding: 0 24px;
  }
  .cd-grid {
    gap: 13px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .cd-hero {
    padding: 28px;
  }
  .cd-hero h1 {
    font-size: 40px;
  }
  .cd-hero-portrait {
    width: 156px;
    height: 237px;
  }
  .cd-hero-kai {
    left: 8%;
    top: 18px;
  }
  .cd-hero-luna {
    left: 43%;
    top: 70px;
  }
  .cd-hero-bubble {
    left: 1%;
    font-size: 8px;
    padding: 10px;
  }
  .cd-controls {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  .cd-search {
    width: 100%;
  }
  .cd-categories {
    flex: none;
  }
  .cd-fiction-label {
    display: none;
  }
  .cd-conversation {
    grid-template-columns: minmax(0, 1fr) 220px;
    gap: 16px;
  }
  .cd-character-profile > div {
    padding: 18px;
  }
}
@media (max-width: 900px) {
  .cd-sidebar {
    width: 220px;
    transform: translateX(-100%);
    visibility: hidden;
    transition:
      transform 0.2s,
      visibility 0.2s;
  }
  .cd-sidebar.is-open {
    transform: translateX(0);
    visibility: visible;
  }
  .cd-menu-close,
  .cd-mobile-toggle {
    display: flex;
  }
  .cd-brand-row {
    gap: 5px;
  }
  .cd-brand {
    font-size: 18px;
    gap: 4px;
  }
  .cd-menu-close {
    padding: 4px;
  }
  .cd-content {
    margin-left: 0;
  }
  .cd-header {
    height: 64px;
  }
  .cd-main {
    padding: 24px;
  }
  .cd-backdrop {
    position: fixed;
    inset: 0;
    z-index: 35;
    background: #08050caa;
    backdrop-filter: blur(4px);
  }
  .cd-conversation {
    height: calc(100svh - 110px);
    min-height: 480px;
  }
  .cd-editorial-label {
    font-size: 9px;
  }
}
@media (max-width: 600px) {
  .cd-header {
    padding: 0 16px;
    height: 62px;
  }
  .cd-header-left {
    gap: 6px;
  }
  .cd-header-label {
    font-size: 9px;
    max-width: 125px;
    line-height: 1.6;
  }
  .cd-header-right {
    gap: 8px;
  }
  .cd-header .cd-header-login {
    gap: 8px;
    padding: 8px 10px;
    font-size: 10px;
  }
  .cd-main {
    padding: 16px 15px 24px;
  }
  .cd-hero {
    min-height: 300px;
    padding: 25px 22px;
    align-items: flex-start;
  }
  .cd-hero-copy {
    width: 69%;
  }
  .cd-hero h1 {
    font-size: 34px;
    letter-spacing: -1.5px;
    margin-top: 15px;
  }
  .cd-hero .cd-eyebrow {
    font-size: 7px;
    letter-spacing: 1.2px;
  }
  .cd-hero-copy > p {
    font-size: 11px;
    max-width: 194px;
    line-height: 1.7;
  }
  .cd-hero-art {
    left: 50%;
    opacity: 0.75;
  }
  .cd-hero-portrait {
    width: 115px;
    height: 177px;
    border-width: 3px;
    border-radius: 12px;
  }
  .cd-hero-kai {
    left: 0;
    top: 40px;
    transform: rotate(-14deg);
  }
  .cd-hero-luna {
    left: 31%;
    top: 135px;
    transform: rotate(10deg);
  }
  .cd-hero-portrait > span {
    font-size: 10px;
  }
  .cd-hero-bubble {
    display: none;
  }
  .cd-spark-one {
    top: 30px;
    right: 13%;
    width: 23px;
  }
  .cd-hero-footnote {
    font-size: 8px;
    max-width: 140px;
    line-height: 1.7;
  }
  .cd-hero .cd-primary {
    font-size: 10px;
    padding: 11px 12px;
    gap: 12px;
  }
  .cd-orbit {
    width: 270px;
    height: 270px;
    top: 35px;
    left: -40%;
  }
  .cd-orbit-two {
    width: 340px;
    height: 340px;
    top: 0;
    left: -60%;
  }
  .cd-section-heading {
    margin: 27px 0 14px;
    gap: 8px;
  }
  .cd-section-heading h2 {
    font-size: 20px;
    line-height: 1.4;
    letter-spacing: -0.6px;
  }
  .cd-section-heading p {
    font-size: 10px;
    line-height: 1.7;
    margin-top: 5px;
  }
  .cd-editorial-label {
    display: none;
  }
  .cd-controls {
    gap: 10px;
    margin-bottom: 17px;
  }
  .cd-categories button {
    font-size: 10px;
    padding: 9px 11px;
  }
  .cd-search {
    padding: 11px;
  }
  .cd-search input {
    font-size: 11px;
  }
  .cd-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }
  .cd-card-open {
    min-height: 278px;
    aspect-ratio: 3/5;
  }
  .cd-card-copy {
    inset: auto 11px 12px;
  }
  .cd-card h3 {
    font-size: 20px;
  }
  .cd-character-kind {
    font-size: 7px;
    letter-spacing: 0.4px;
  }
  .cd-card-subtitle {
    font-size: 9px;
    line-height: 1.6;
    min-height: 29px;
    margin-bottom: 5px;
  }
  .cd-card-description {
    font-size: 9px;
    line-height: 1.7;
    margin-bottom: 8px;
  }
  .cd-tags > span {
    font-size: 7px;
    padding: 4px 5px;
  }
  .cd-favorite {
    width: 29px;
    height: 29px;
    right: 8px;
    top: 8px;
  }
  .cd-bottom-banner {
    padding: 19px 16px;
    align-items: flex-start;
    flex-direction: column;
  }
  .cd-bottom-banner strong {
    font-size: 12px;
  }
  .cd-bottom-banner small {
    font-size: 10px;
  }
  .cd-bottom-banner > a {
    padding-left: 37px;
    font-size: 10px;
  }
  .cd-footer {
    flex-wrap: wrap;
    font-size: 8px;
    gap: 8px 16px;
    padding-top: 20px;
  }
  .cd-footer > span:nth-child(2) {
    margin-left: 0;
    flex-basis: 100%;
    order: 3;
  }
  .cd-footer > a:nth-last-child(2) {
    margin-left: auto;
  }
  .cd-conversation {
    display: block;
    height: calc(100svh - 94px);
    min-height: 420px;
  }
  .cd-chat-main {
    height: 100%;
  }
  .cd-chat-header {
    padding: 12px;
  }
  .cd-chat-log {
    padding: 20px 16px;
  }
  .cd-chat-intro {
    margin-bottom: 23px;
  }
  .cd-chat-intro > img {
    width: 72px;
    height: 72px;
  }
  .cd-message {
    max-width: 94%;
  }
  .cd-message p {
    font-size: 12px;
    padding: 12px;
  }
  .cd-composer-area {
    padding: 13px;
  }
  .cd-model-label select {
    max-width: 150px;
  }
  .cd-chat-note {
    font-size: 8px;
  }
  .cd-composer textarea {
    font-size: 16px;
  }
  .cd-creator h1 {
    font-size: 27px;
  }
  .cd-character-form {
    padding: 18px;
  }
  .cd-portrait-options {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
  }
  .cd-form-fields {
    grid-template-columns: 1fr;
  }
  .cd-form-fields input,
  .cd-form-fields textarea,
  .cd-form-fields select {
    font-size: 16px;
  }
  .cd-checkbox {
    font-size: 11px;
    align-items: flex-start;
    line-height: 1.8;
  }
  .cd-checkbox input {
    flex-shrink: 0;
  }
  .cd-creator .cd-primary {
    width: 100%;
  }
}
@media (prefers-reduced-motion: reduce) {
  .cd-shell * {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}

/* Make portrait introductions centered despite the global image reset. */
.cd-chat-intro > img {
  margin-inline: auto;
}
.cd-character-kind {
  line-height: 1.6;
  padding-block: 2px;
}
.cd-card-copy {
  line-height: 1.6;
}
@media (max-width: 600px) {
  .cd-hero-art {
    inset-inline-start: 59%;
    opacity: 0.65;
  }
  .cd-hero-luna {
    inset-inline-start: 24%;
  }
}

/* Collection v2: quiet plum surfaces, rose accents, image-first composition. */
.cd-shell {
  --cd-bg: #110f18;
  --cd-panel: #1b1724;
  --cd-line: #352a40;
  --cd-muted: #b8aabd;
  --cd-accent: #d9b5ff;
  --cd-pink: #edb1ce;
  background:
    radial-gradient(ellipse at 70% 0, #271c302e, transparent 48%), var(--cd-bg);
}
.cd-sidebar {
  background: #17121e;
  border-color: #302637;
  padding-top: 25px;
}
.cd-brand-row {
  margin-bottom: 30px;
}
.cd-nav a {
  border-radius: 12px;
  font-size: 13px;
}
.cd-header {
  height: 68px;
  background: #110f18aa;
}
.cd-header-label {
  font-size: 12px;
}
.cd-main {
  padding-top: 24px;
}
.cd-hero {
  min-height: 266px;
  padding: 30px 36px;
  border-color: #59415c;
  background:
    radial-gradient(ellipse at 75% 70%, #77536b55, transparent 65%),
    linear-gradient(115deg, #30203f, #231a30 55%, #493044);
}
.cd-hero h1 {
  font-size: clamp(38px, 4vw, 56px);
  letter-spacing: -2.4px;
  line-height: 1.03;
}
.cd-hero h1 span {
  color: #f3b8d7;
}
.cd-hero-copy > p {
  font-size: 13px;
  line-height: 1.7;
  max-width: 330px;
}
.cd-hero .cd-primary {
  font-size: 12px;
  padding: 12px 19px;
}
.cd-hero-portrait {
  width: 190px;
  height: 262px;
  border-width: 3px;
  border-color: #a18bb2;
  box-shadow: 0 16px 40px #09061077;
}
.cd-hero-portrait img {
  object-position: center 25%;
}
.cd-hero-kai {
  top: 4px;
  transform: rotate(-9deg);
}
.cd-hero-luna {
  top: 32px;
  transform: rotate(8deg);
}
.cd-hero-bubble {
  font-size: 11px;
  bottom: 15px;
}
.cd-section-heading {
  margin: 28px 0 16px;
}
.cd-section-heading h2 {
  font-size: 24px;
}
.cd-section-heading p {
  font-size: 12px;
}
.cd-controls {
  gap: 14px;
  margin-bottom: 16px;
}
.cd-categories button {
  font-size: 12px;
  border-radius: 20px;
  padding: 9px 13px;
}
.cd-categories button.is-active {
  background: #493157;
  color: #f6ddff;
  box-shadow: inset 0 0 0 1px #785885;
}
.cd-search {
  border-radius: 24px;
  background: #211a2a;
}
.cd-search input {
  font-size: 12px;
}
.cd-grid {
  gap: 16px;
}
.cd-card {
  border-color: #3d3045;
  border-radius: 15px;
  box-shadow: 0 7px 24px #08060d25;
}
.cd-card-open {
  aspect-ratio: 3/4.4;
}
.cd-card-open > img {
  object-position: center 20%;
  filter: none;
  transition: transform 0.45s ease;
}
.cd-card:hover .cd-card-open > img {
  transform: scale(1.035);
}
.cd-card-shade {
  background: linear-gradient(
    180deg,
    transparent 20%,
    #17111c0d 35%,
    #17111cba 64%,
    #17111cf5 88%,
    #17111c
  );
}
.cd-card-copy {
  padding: 18px 15px 16px;
}
.cd-card-copy h3 {
  font-size: 23px;
  letter-spacing: -0.5px;
}
.cd-card-subtitle {
  font-size: 12px;
  color: #fae9f6;
}
.cd-card-description {
  font-size: 11px;
  color: #d3c3d6;
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.cd-character-kind {
  font-size: 9px;
  letter-spacing: 1px;
  color: #e1c5e8;
}
.cd-tags span {
  border: 1px solid #ffffff15;
  background: #b78ac621;
  color: #ebdced;
  border-radius: 15px;
  font-size: 10px;
}
.cd-favorite {
  top: 11px;
  right: 11px;
  width: 33px;
  height: 33px;
  background: #1b142766;
  backdrop-filter: blur(12px);
  border: 1px solid #fff4;
}
.cd-card-actions,
.cd-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 12px 0 20px;
}
.cd-card-actions > span {
  font-size: 12px;
  color: var(--cd-muted);
}
.cd-page-intro {
  padding: 32px 0 24px;
  max-width: 850px;
}
.cd-page-intro h1 {
  font-size: clamp(30px, 4vw, 46px);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -1.6px;
  margin: 15px 0;
}
.cd-page-intro > p {
  max-width: 670px;
  color: #c5b5d0;
  line-height: 1.8;
  margin: 0 0 20px;
}
.cd-community-notice {
  border: 1px solid #51405e;
  border-radius: 12px;
  padding: 14px 18px;
  background: #2b2135;
  color: #d6c5e1;
  font-size: 13px;
  line-height: 1.7;
  margin: 0 0 22px;
}
.cd-community > .cd-categories {
  margin: 0 0 20px;
}
.cd-benefit-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin: 0 0 30px;
}
.cd-benefit-grid article {
  background: #21192c;
  border: 1px solid #45324f;
  border-radius: 16px;
  padding: 25px;
}
.cd-benefit-grid svg {
  color: #ecb2d6;
}
.cd-benefit-grid h3 {
  margin: 14px 0 9px;
  font-size: 16px;
  font-weight: 650;
}
.cd-benefit-grid p {
  font-size: 13px;
  line-height: 1.8;
  color: #bfb0ca;
}
.cd-member-gate {
  border: 1px solid #61496d;
  border-radius: 20px;
  padding: 40px;
  background:
    radial-gradient(ellipse at top right, #70476555, transparent), #251d30;
  text-align: center;
}
.cd-member-gate h2 {
  font-size: 28px;
  font-weight: 650;
}
.cd-member-gate p {
  color: #c5b4d1;
  max-width: 580px;
  margin: 15px auto 22px;
  line-height: 1.8;
}
.cd-member-gate > a:last-child {
  display: block;
  margin-top: 20px;
  color: #edb5da;
  font-size: 13px;
}
.cd-payment-faq {
  margin: 36px 0;
  max-width: 850px;
}
.cd-payment-faq h2 {
  font-size: 22px;
  margin-bottom: 16px;
  font-weight: 600;
}
.cd-payment-faq details {
  border-bottom: 1px solid #3b2c45;
  padding: 18px 0;
}
.cd-payment-faq summary {
  cursor: pointer;
  font-weight: 600;
}
.cd-payment-faq p {
  color: #c4b4ce;
  line-height: 1.8;
  margin: 15px 0 0;
}
.cd-wallet-content {
  --background: #17121f;
  --foreground: #f3eaf8;
  --card: #221a2e;
  --card-foreground: #f3eaf8;
  --popover: #251c31;
  --popover-foreground: #f3eaf8;
  --primary: #dab3f1;
  --primary-foreground: #2c1a38;
  --secondary: #382845;
  --secondary-foreground: #eddef6;
  --muted: #30243b;
  --muted-foreground: #bdaccb;
  --border: #4b3657;
  --input: #4b3657;
  --ring: #d9a5ed;
  border: 1px solid #463451;
  border-radius: 20px;
  padding: 12px;
  background: #17121f;
}
.cd-wallet-content main {
  overflow: visible;
}
.cd-wallet-content button {
  border-style: solid;
}
.cd-visibility {
  margin: 24px 0;
}
.cd-visibility legend {
  font-weight: 600;
  margin-bottom: 12px;
}
.cd-visibility label {
  display: flex;
  gap: 12px;
  padding: 16px;
  margin-bottom: 12px;
  border: 1px solid #50385d;
  border-radius: 12px;
  cursor: pointer;
}
.cd-visibility input {
  accent-color: #e6b4ed;
}
.cd-visibility strong,
.cd-visibility small {
  display: block;
}
.cd-visibility small {
  margin-top: 6px;
  color: #bba9c9;
  line-height: 1.7;
}
.cd-social-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 20px;
}
.cd-card-actions button,
.cd-social-actions button,
.cd-pagination button,
.cd-review button,
.cd-delete-character button {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  padding: 9px 13px;
  border-radius: 9px;
  background: #3b2948;
  color: #edc8f7;
  font-size: 12px;
}
.cd-social-actions form {
  width: 100%;
}
.cd-social-actions textarea {
  display: block;
  width: 100%;
  min-height: 90px;
  border: 1px solid #624974;
  background: #1e1627;
  border-radius: 8px;
  padding: 10px;
  margin: 10px 0;
}
.cd-review {
  padding: 16px;
  background: #271c32;
  border-radius: 0 0 12px 12px;
}
.cd-review p {
  max-height: 140px;
  overflow: auto;
  white-space: pre-wrap;
  font-size: 12px;
  margin-bottom: 10px;
}
.cd-review button {
  margin-right: 8px;
}
.cd-delete-character {
  margin-top: 28px;
}
.cd-delete-character p {
  margin-bottom: 12px;
  color: #f0b7ca;
}
.cd-delete-character button {
  margin-right: 12px;
}
@media (min-width: 1600px) {
  .cd-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}
@media (max-width: 1050px) {
  .cd-benefit-grid {
    grid-template-columns: 1fr;
  }
  .cd-hero-portrait {
    width: 156px;
    height: 224px;
  }
  .cd-hero-luna {
    left: 45%;
    top: 50px;
  }
}
@media (max-width: 700px) {
  .cd-main {
    padding: 16px 14px;
  }
  .cd-hero {
    padding: 24px 22px;
    min-height: 248px;
  }
  .cd-hero h1 {
    font-size: 38px;
    letter-spacing: -1.6px;
  }
  .cd-hero-copy > p {
    font-size: 12px;
    max-width: 215px;
  }
  .cd-hero-portrait {
    width: 130px;
    height: 190px;
  }
  .cd-hero-art {
    inset: 0 -35px 0 56%;
    opacity: 0.8;
  }
  .cd-hero-luna {
    left: 23%;
    top: 74px;
  }
  .cd-hero-kai {
    left: 0;
    top: 5px;
  }
  .cd-card-open {
    aspect-ratio: 3/4.8;
  }
  .cd-card-copy {
    padding: 12px 10px;
  }
  .cd-card-copy h3 {
    font-size: 19px;
  }
  .cd-card-description {
    font-size: 10px;
  }
  .cd-card-subtitle {
    font-size: 10px;
  }
  .cd-grid {
    gap: 12px;
  }
  .cd-page-intro {
    padding: 20px 0;
  }
  .cd-member-gate {
    padding: 24px 18px;
  }
  .cd-wallet-content {
    padding: 0;
    border-radius: 12px;
  }
  .cd-section-heading h2 {
    font-size: 21px;
  }
  .cd-benefit-grid article {
    padding: 20px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .cd-card-open > img {
    transition: none;
  }
}

.cd-card-copy {
  inset: auto 0 0;
}

@media (max-width: 700px) {
  .cd-hero {
    min-height: 380px;
    padding-bottom: 170px;
  }
  .cd-hero-copy {
    width: 100%;
    max-width: 100%;
  }
  .cd-hero h1 {
    font-size: 40px;
  }
  .cd-hero h1 span {
    display: inline;
  }
  .cd-hero-copy > p {
    max-width: 100%;
  }
  .cd-hero-art {
    inset: auto 0 0 0;
    height: 155px;
    opacity: 1;
  }
  .cd-hero-portrait {
    width: 130px;
    height: 175px;
  }
  .cd-hero-kai {
    left: 38%;
    top: 4px;
    transform: rotate(-8deg);
  }
  .cd-hero-luna {
    left: 65%;
    top: 18px;
    transform: rotate(9deg);
  }
  .cd-hero-footnote {
    max-width: 170px;
  }
  .cd-card-shade {
    background: linear-gradient(
      180deg,
      transparent 25%,
      #17111c55 48%,
      #17111ce8 75%,
      #17111c
    );
  }
  .cd-card-description {
    display: none;
  }
  .cd-card-open {
    aspect-ratio: 3/4.6;
  }
  .cd-character-kind {
    font-size: 8px;
  }
  .cd-card-copy h3 {
    font-size: 20px;
  }
  .cd-card-subtitle {
    font-size: 11px;
    line-height: 1.4;
  }
}

/* Crawlable collection links stay on one scrollable row at narrow widths. */
.cd-topic-nav {
  display: flex;
  gap: 8px;
  padding: 13px 32px;
  overflow-x: auto;
  max-width: 100%;
  border-bottom: 1px solid var(--cd-line);
  scrollbar-width: thin;
  scroll-padding: 24px;
  background: #17121e;
}
.cd-topic-nav a {
  flex: 0 0 auto;
  padding: 9px 14px;
  border: 1px solid #382c42;
  border-radius: 999px;
  color: #d5c9df;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.cd-topic-nav a:hover,
.cd-topic-nav a[aria-current='page'] {
  color: #fce8ff;
  background: #3b2949;
  border-color: #9f71b8;
}
.cd-topic-shell {
  min-width: 0;
}
.cd-topic-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  max-width: 1240px;
  margin: auto;
  padding: 22px 32px;
}
.cd-topic-header > div {
  display: flex;
  align-items: center;
  gap: 20px;
}
.cd-topic-shell > .cd-topic-nav {
  justify-content: safe center;
}
.cd-topic-main {
  max-width: 1240px;
  margin: auto;
  padding: 24px 32px 40px;
}
.cd-breadcrumbs {
  color: var(--cd-muted);
  font-size: 12px;
}
.cd-topic-intro {
  padding: 44px 0;
  max-width: 830px;
}
.cd-topic-intro h1 {
  font-size: clamp(32px, 4.2vw, 56px);
  font-weight: 700;
  line-height: 1.13;
  letter-spacing: -1.5px;
  margin: 18px 0;
}
.cd-topic-intro p {
  color: #c3b7ce;
  line-height: 1.85;
  font-size: 16px;
  margin-bottom: 26px;
}
.cd-topic-shell .cd-card h2 {
  font-size: 25px;
  font-weight: 700;
}
.cd-topic-starters,
.cd-topic-faq {
  margin-top: 44px;
}
.cd-topic-starters h2,
.cd-topic-faq h2 {
  font-size: 25px;
  font-weight: 650;
  margin-bottom: 14px;
}
.cd-topic-starters p,
.cd-topic-faq p {
  color: #c3b7ce;
  line-height: 1.8;
}
.cd-topic-starters ul {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  list-style: none;
  padding: 20px 0;
}
.cd-topic-starters li {
  padding: 24px;
  border: 1px solid var(--cd-line);
  background: var(--cd-panel);
  border-radius: 16px;
  line-height: 1.8;
}
.cd-topic-faq details {
  border-bottom: 1px solid var(--cd-line);
  padding: 20px 0;
}
.cd-topic-faq summary {
  cursor: pointer;
  font-weight: 600;
}
.cd-topic-faq p {
  margin-top: 14px;
  max-width: 850px;
}
@media (max-width: 700px) {
  .cd-topic-nav {
    padding: 12px 18px;
  }
  .cd-topic-header,
  .cd-topic-main {
    padding-left: 18px;
    padding-right: 18px;
  }
  .cd-topic-header > div > a:first-child {
    display: none;
  }
  .cd-topic-header .cd-brand {
    font-size: 18px;
  }
  .cd-topic-intro {
    padding: 30px 0;
  }
  .cd-topic-starters ul {
    grid-template-columns: 1fr;
  }
}
.cd-creator-starters {
  margin: 0 0 28px;
}
.cd-creator-starters > p {
  color: var(--cd-muted);
  line-height: 1.6;
  margin: 10px 0 14px;
}
.cd-creator-starters > div {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}
.cd-creator-starters button {
  text-align: left;
  background: #241b30;
  border: 1px solid #44324f;
  color: #f1e4fa;
  padding: 15px;
  border-radius: 12px;
}
.cd-creator-starters small {
  display: block;
  color: #bfa7cb;
  margin-top: 7px;
}
.cd-creator-starters:disabled button {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Memory remains reachable inside chat on desktop and mobile. */
.cd-memory-panel {
  flex: none;
  border-bottom: 1px solid var(--cd-line, #40304b);
  padding: 12px 18px;
  background: var(--cd-panel, #201727);
  font-size: 13px;
}
.cd-memory-panel[open] {
  max-height: min(52svh, 480px);
  overflow-y: auto;
}
.cd-memory-panel summary {
  cursor: pointer;
  font-weight: 600;
  color: #f1d6f5;
}
.cd-memory-panel summary span {
  margin-left: 8px;
  color: #d7bdde;
}
.cd-memory-panel p,
.cd-memory-panel small {
  display: block;
  margin: 10px 0;
  color: #d7c8de;
}
.cd-memory-panel label {
  display: block;
  margin-top: 12px;
}
.cd-memory-panel textarea {
  width: 100%;
  display: block;
  margin: 6px 0;
  padding: 9px;
  border: 1px solid #65516e;
  border-radius: 8px;
  background: #1b1322;
  color: #f4eaf7;
  resize: vertical;
  min-height: 54px;
}
.cd-memory-panel ul {
  list-style: none;
  padding: 0;
}
.cd-memory-panel li {
  padding: 8px 0;
  border-bottom: 1px solid #40304b;
}
.cd-memory-panel button {
  border: 1px solid #80618d;
  border-radius: 8px;
  padding: 7px 10px;
  margin: 5px 8px 5px 0;
  color: #f2def7;
}
.cd-memory-panel button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.cd-memory-panel :focus-visible {
  outline: 2px solid #e5a7f1;
  outline-offset: 3px;
}

/* Kirie: one focused encounter, not a dashboard of relationship mechanics. */
.cd-kirie-conversation {
  gap: 0;
  grid-template-columns: minmax(0, 1fr) minmax(270px, 32%);
  border: 1px solid #3b2c42;
  border-radius: 22px;
  overflow: hidden;
  background: #17111d;
}
.cd-kirie-conversation .cd-chat-main {
  border: 0;
  border-radius: 0;
  background:
    radial-gradient(ellipse at 70% 0, #39223765, transparent 70%), #17111d;
}
.cd-kirie-conversation .cd-chat-header {
  border-color: #b889ac18;
}
.cd-kirie-conversation .cd-chat-log {
  padding: 24px clamp(20px, 3vw, 48px);
}
.cd-kirie-conversation .cd-chat-intro {
  margin: 8px 0 26px;
}
.cd-kirie-conversation .cd-chat-intro > img {
  width: 68px;
  height: 68px;
  border: 1px solid #c5a0bd66;
}
.cd-kirie-conversation .cd-chat-intro h2 {
  font-size: 26px;
  letter-spacing: 0.04em;
}
.cd-kirie-conversation .cd-chat-intro .cd-eyebrow {
  color: #b9a4b5;
  font-size: 10px;
}
.cd-encounter-summary {
  padding: 17px 20px;
  margin-bottom: 28px;
  border-radius: 14px;
  background: #08070b45;
  border: 1px solid #b889ac15;
}
.cd-encounter-summary h3 {
  display: block;
  margin: 0 0 4px;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #eedce8;
}
.cd-encounter-summary h3 + .cd-story-blocks {
  margin-top: 12px;
}
.cd-encounter-summary p {
  margin: 8px 0 0;
  white-space: pre-line;
  color: #bcaebe;
  line-height: 1.9;
  font-size: 13px;
}
.cd-story-blocks {
  display: grid;
  gap: 13px;
}
.cd-story-block + .cd-story-block {
  border-top: 1px solid #b889ac12;
  padding-top: 14px;
}
.cd-story-block h4 {
  margin: 0;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #e6cfe0;
}
.cd-story-block p {
  margin: 6px 0 0;
  font-size: 12.5px;
  line-height: 1.85;
}
.cd-story-blocks + h3 {
  margin-top: 24px;
}
.cd-story-state {
  display: grid;
  gap: 8px;
  margin: 12px 0 0;
  padding: 13px 15px;
  border-radius: 10px;
  background: #0b081080;
  border: 1px solid #b889ac14;
}
.cd-story-state > div {
  display: grid;
  grid-template-columns: minmax(6em, 8.5em) 1fr;
  gap: 12px;
  align-items: baseline;
}
.cd-story-state dt {
  margin: 0;
  color: #b79cae;
  font-size: 11px;
  letter-spacing: 0.02em;
}
.cd-story-state dd {
  margin: 0;
  color: #dccdd8;
  font-size: 12.5px;
  line-height: 1.7;
}
@media (max-width: 600px) {
  .cd-story-state > div {
    grid-template-columns: 1fr;
    gap: 1px;
  }
  .cd-story-state dt {
    color: #a98fbf;
  }
}
.cd-story-profile > p {
  margin: 0;
}
.cd-story-profile dl {
  display: grid;
  gap: 10px;
  margin: 14px 0 0;
}
.cd-story-profile dt {
  color: #b79cae;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.cd-story-profile dd {
  margin: 3px 0 0;
  color: #d8c8d3;
  font-size: 12px;
  line-height: 1.7;
}
.cd-kirie-conversation .cd-message {
  max-width: 100%;
  margin-bottom: 26px;
}
.cd-kirie-conversation .cd-message > span {
  color: #b49cab;
  font-size: 11px;
}
.cd-kirie-conversation .cd-scene-prose {
  padding: 6px 0 8px 17px;
  border-left: 2px solid #b783ac50;
}
.cd-kirie-conversation .cd-scene-prose p {
  margin: 0 0 14px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  color: #e8dbe6;
  font-size: 14px;
  line-height: 1.95;
}
.cd-kirie-conversation .cd-scene-prose p:last-child {
  margin-bottom: 0;
}
.cd-kirie-conversation .cd-scene-prose .cd-scene-narration {
  color: #b9abbc;
  font-style: italic;
}
.cd-scene-speech {
  font-weight: 550;
  color: #f5dce9;
}
.cd-kirie-conversation .cd-message-user {
  max-width: 86%;
}
.cd-kirie-conversation .cd-message-user p {
  background: #4b314a75;
  border-color: #ac759d40;
  color: #f0e2ec;
}
.cd-kirie-conversation .cd-composer-area {
  border-color: #b889ac18;
  padding: 14px 22px;
}
.cd-kirie-conversation .cd-composer {
  background: #312332;
  border-color: #70526770;
  border-radius: 24px;
}
.cd-kirie-conversation .cd-send {
  background: #e5b1cc;
  color: #2d1828;
  border-radius: 50%;
}
.cd-kirie-conversation .cd-character-profile {
  position: relative;
  border: 0;
  border-radius: 0;
  overflow-y: auto;
  background: #231724;
}
.cd-kirie-conversation .cd-character-profile > img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  object-position: 50% 22%;
}
.cd-kirie-conversation .cd-character-profile > div {
  padding: 20px 24px 26px;
  background: #231724;
}
.cd-kirie-conversation .cd-character-profile h2 {
  font-size: 30px;
}
.cd-kirie-conversation .cd-character-profile > div > .cd-eyebrow {
  display: none;
}
.cd-kirie-conversation .cd-character-profile p {
  color: #d7c0d2;
}
.cd-kirie-conversation .cd-character-profile .cd-profile-note {
  font-size: 10px;
  color: #b5a0b0;
}
.cd-kirie-replies {
  display: grid;
  gap: 7px;
  margin: 0 0 12px;
}
.cd-reply-options {
  display: grid;
  gap: inherit;
}
.cd-kirie-replies > span {
  font-size: 11px;
  color: #bc9fb6;
}
.cd-kirie-replies button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 15px;
  border: 1px solid #8a617c30;
  border-radius: 12px;
  background: #352532a8;
  text-align: left;
  color: #eedce7;
  font-size: 13px;
  line-height: 1.5;
}
.cd-kirie-replies button:hover:not(:disabled) {
  background: #4c3347;
  border-color: #bd8eaa75;
}
.cd-kirie-replies button:focus-visible {
  outline: 2px solid #edb1ce;
  outline-offset: 3px;
}
.cd-kirie-replies button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.cd-kirie-replies button > span:first-child {
  min-width: 0;
  overflow-wrap: anywhere;
}
.cd-kirie-replies button > span:last-child {
  color: #c497b4;
}
.cd-kirie-replies small {
  color: #a795a5;
  font-size: 10px;
  line-height: 1.6;
}
@media (max-width: 900px) {
  .cd-kirie-conversation {
    display: block;
    border-radius: 16px;
  }
  .cd-kirie-conversation .cd-chat-main {
    height: 100%;
  }
  .cd-kirie-conversation .cd-chat-log {
    padding: 18px;
  }
  .cd-kirie-conversation .cd-chat-intro {
    margin: 4px 0 20px;
  }
  .cd-kirie-conversation .cd-scene-prose p {
    font-size: 14px;
    line-height: 1.85;
  }
  .cd-kirie-conversation .cd-composer-area {
    padding: 12px;
  }
  .cd-kirie-replies {
    gap: 5px;
  }
  .cd-kirie-replies button {
    padding: 9px 12px;
    font-size: 12px;
  }
}

/* Relationship meter: five bands, filled up to the committed tier. */
.cd-affection {
  display: grid;
  gap: 8px;
  margin: 18px 0;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
}
.cd-affection-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.cd-affection-head strong {
  font-size: 0.95rem;
  letter-spacing: 0.02em;
}
.cd-affection-bar {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 6px;
}
.cd-affection-bar span {
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
}
.cd-affection-bar span.cd-affection-fill {
  background: linear-gradient(90deg, #f0a6c8, #d05a92);
}
.cd-affection-hint {
  margin: 0;
  font-size: 0.82rem;
  opacity: 0.72;
  line-height: 1.5;
}

/* Scene media: preview stays pixelated until an active subscription. */
.cd-scene-media {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}
.cd-media-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.cd-media-grid li {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  aspect-ratio: 3 / 4;
  background: rgba(255, 255, 255, 0.05);
}
.cd-media-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.cd-media-lock {
  position: absolute;
  inset: auto 0 0 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px;
  font-size: 0.72rem;
  text-decoration: none;
  color: #fff;
  background: rgba(12, 10, 16, 0.78);
  backdrop-filter: blur(4px);
}
.cd-media-generate {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: transparent;
  color: inherit;
  cursor: pointer;
}
.cd-media-generate:disabled {
  opacity: 0.55;
  cursor: progress;
}

/* Quote step: the price is shown before anything is reserved. */
.cd-media-quote {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.cd-media-quote p {
  flex: 1 1 100%;
  margin: 0;
  font-size: 0.82rem;
  opacity: 0.78;
}
.cd-media-quote button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: transparent;
  color: inherit;
  cursor: pointer;
}
.cd-media-quote button:disabled {
  opacity: 0.55;
  cursor: progress;
}

/* Media controls: kind switch, model picker, adult toggle, unlock gate. */
.cd-media-kinds {
  display: inline-flex;
  gap: 6px;
}
.cd-media-kinds button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: transparent;
  color: inherit;
  font-size: 0.78rem;
  cursor: pointer;
}
.cd-media-kinds button[aria-pressed='true'] {
  background: rgba(240, 166, 200, 0.18);
  border-color: rgba(240, 166, 200, 0.5);
}
.cd-media-adult {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  opacity: 0.8;
}
.cd-scene-media select {
  max-width: 140px;
  padding: 4px 6px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: transparent;
  color: inherit;
  font-size: 0.74rem;
}
.cd-media-open {
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: zoom-in;
}
.cd-media-gate {
  display: grid;
  gap: 8px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(240, 166, 200, 0.35);
  background: rgba(240, 166, 200, 0.08);
}
.cd-media-gate p {
  margin: 0;
  font-size: 0.82rem;
}
.cd-media-gate button {
  justify-self: start;
  padding: 6px 10px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: transparent;
  color: inherit;
  cursor: pointer;
}

/* Side lines: fork the current line, switch back later. */
.cd-branches {
  display: grid;
  gap: 8px;
  margin: 12px 0;
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
}
.cd-branches button {
  padding: 5px 9px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: transparent;
  color: inherit;
  font-size: 0.76rem;
  cursor: pointer;
}
.cd-branches ul {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
  max-height: 200px;
  overflow-y: auto;
  overflow-wrap: anywhere;
}
.cd-branches li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
}
.cd-branches li small {
  opacity: 0.6;
}
.cd-media-grid video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Keep a single profile mounted, in the grid on desktop and in a modal on mobile. */
.cd-profile-panel {
  padding: 0;
  border: 1px solid #594062;
  border-radius: 16px;
  background: #211629;
  color: #eedcf9;
}
.cd-profile-panel[data-inline='true'] {
  position: static;
  margin: 0;
  width: auto;
  height: 100%;
  max-width: none;
  max-height: none;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  border: 0;
}
.cd-profile-panel[data-inline='true'] > .cd-character-profile {
  height: 100%;
}
.cd-profile-panel[data-inline='false'] {
  width: min(440px, calc(100% - 24px));
  max-height: calc(100dvh - 32px);
  margin: auto;
  overflow-y: auto;
}
.cd-profile-panel::backdrop,
.cd-media-dialog::backdrop {
  background: #120c1fbc;
  backdrop-filter: blur(5px);
}
.cd-profile-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  position: sticky;
  top: 0;
  z-index: 1;
  background: #211629;
  border-bottom: 1px solid #4b3256;
}
.cd-profile-panel-header h2 {
  margin: 0;
  font-size: 15px;
}
.cd-profile-panel[data-inline='false'] .cd-character-profile {
  border: 0;
}
.cd-story-settings > summary,
.cd-model-settings > summary {
  cursor: pointer;
  padding: 6px 0;
  color: #c7acd4;
  font-size: 12px;
}
.cd-branches button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.cd-scene-media .cd-affection-head {
  flex-wrap: wrap;
  gap: 8px;
}
.cd-scene-media select {
  min-width: 0;
  max-width: 100%;
}
.cd-media-dialog {
  max-width: min(900px, calc(100% - 24px));
  max-height: calc(100dvh - 32px);
  padding: 14px;
  margin: auto;
  border: 1px solid #705267;
  border-radius: 16px;
  background: #231724;
  color: #f0e2ec;
}
.cd-media-dialog[open] {
  display: grid;
  gap: 12px;
}
.cd-media-dialog > img {
  max-width: 100%;
  max-height: calc(100dvh - 130px);
  object-fit: contain;
  margin: auto;
}
.cd-media-dismiss {
  padding: 8px 14px;
  border: 1px solid #705267;
  border-radius: 8px;
  cursor: pointer;
}

/* Size chat from the real header/navigation height; keep the input in view. */
.cd-shell-chat > .cd-content {
  height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.cd-shell-chat .cd-header,
.cd-shell-chat .cd-topic-nav {
  flex-shrink: 0;
}
.cd-shell-chat .cd-main {
  flex: 1;
  min-height: 0;
  width: 100%;
}
.cd-shell-chat .cd-conversation {
  height: 100%;
  min-height: 0;
}
@media (max-width: 600px) {
  .cd-reply-options {
    display: flex;
    overflow-x: auto;
    gap: 8px;
    padding-bottom: 4px;
    scrollbar-width: thin;
  }
  .cd-reply-options > button {
    flex: 0 0 85%;
    max-width: 85%;
  }
  .cd-kirie-replies small {
    display: none;
  }
}
.cd-profile-panel button:focus-visible,
.cd-media-dialog button:focus-visible,
.cd-media-dialog a:focus-visible,
.cd-story-settings > summary:focus-visible {
  outline: 2px solid #e5b1cc;
  outline-offset: 3px;
}
.cd-voice-reply {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem 0.75rem;
  margin-top: 0.85rem;
}
.cd-voice-reply button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.8rem;
  border: 1px solid color-mix(in srgb, currentColor 20%, transparent);
  border-radius: 999px;
  font: inherit;
  color: inherit;
  background: color-mix(in srgb, #a580dd 12%, transparent);
  cursor: pointer;
}
.cd-voice-reply small {
  opacity: 0.7;
  font-size: 0.72rem;
}
.cd-voice-reply p {
  flex-basis: 100%;
}
.cd-chat-media {
  width: min(100%, 42rem);
  margin: 1.25rem 0;
  border: 1px solid color-mix(in srgb, #b78be2 26%, transparent);
  border-radius: 1rem;
  background: color-mix(in srgb, #c18bd5 6%, transparent);
}
.cd-chat-media > summary {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.8rem 1rem;
  cursor: pointer;
  font-size: 0.86rem;
}
.cd-chat-media > summary:focus-visible,
.cd-voice-reply button:focus-visible {
  outline: 2px solid #b78be2;
  outline-offset: 3px;
}
.cd-scene-media-inline {
  margin: 0;
  padding: 0.5rem 1rem 1rem;
}
.cd-scene-media-inline .cd-affection-head {
  flex-wrap: wrap;
  gap: 0.65rem;
}
.cd-scene-media-inline select {
  min-width: 0;
  max-width: 100%;
}
.cd-scene-media-inline .cd-media-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.cd-media-invitation {
  margin: 0 0 1rem;
  font-style: italic;
  line-height: 1.7;
}
@media (max-width: 480px) {
  .cd-scene-media-inline .cd-media-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Story intro reads as prose; the state is a single muted line. */
.cd-encounter-summary .cd-story-blocks p {
  margin: 0 0 0.9em;
  line-height: 1.75;
}
.cd-story-state-line {
  margin: 0.4em 0 0;
  font-size: 0.8rem;
  opacity: 0.66;
}
