.story-page--chat-v3 .form-card--chat{
  border-color:rgba(255,133,205,.32);
}

.story-page--chat-v3 .chat-welcome{
  margin-bottom:18px;
}

.story-page--chat-v3.identity-page .identity-side{
  display:none;
}

.story-page--chat-v3 .v3-source-fields{
  display:none!important;
}

.story-page--chat-v3 .wizard--chat .wizstep[hidden]{
  display:none!important;
}

.story-page--chat-v3 [data-v3-source][hidden],
.story-page--chat-v3 [data-v3-actions][hidden]{
  display:none!important;
}

.chat-v3-booting .story-page--chat-v3 .wizard--chat,
.chat-v3-booting .story-page--chat-v3 .story-form>.actions{
  visibility:hidden;
}

.story-page--chat-v3 .v3-conversation{
  display:grid;
  gap:14px;
  min-width:0;
}

.story-page--chat-v3 .chat-history__archive:not([open]) > .chat-history__turns{
  display:none!important;
}

.story-page--chat-v3 .v3-server-state{
  display:contents;
}

.story-page--chat-v3 .v3-live-turn{
  display:grid;
}

.story-page--chat-v3 .v3-live-question{
  display:grid;
  gap:6px;
  margin:0;
}

.story-page--chat-v3 .v3-live-question strong{
  color:#fff;
  font-size:1.05rem;
  line-height:1.42;
}

.story-page--chat-v3 .v3-live-question span{
  color:var(--chat-muted);
  font-size:.9rem;
  line-height:1.45;
}

.story-page--chat-v3 .v3-live-composer{
  position:sticky;
  bottom:10px;
  z-index:8;
  display:grid;
  grid-template-columns:minmax(0,1fr) 48px;
  align-items:center;
  justify-self:end;
  width:min(72%,620px);
  margin:16px 0 2px;
  padding:5px;
  border:1px solid rgba(255,122,202,.38);
  border-radius:10px;
  background:rgba(19,14,42,.96);
  box-shadow:0 16px 38px rgba(0,0,0,.34),0 0 0 4px rgba(180,69,241,.08);
  backdrop-filter:blur(16px);
}

.story-page--chat-v3 .v3-live-composer[hidden]{display:none!important}

.story-page--chat-v3 .v3-live-input{
  width:100%;
  min-width:0;
  height:50px;
  padding:0 14px;
  border:0;
  outline:0;
  color:#fff;
  background:transparent;
  font:inherit;
  font-size:1rem;
}

.story-page--chat-v3 .v3-live-input::placeholder{color:#928aa8}

.story-page--chat-v3 .v3-live-send{
  width:44px;
  min-width:44px;
  height:44px;
  min-height:44px;
  padding:0;
  border-radius:50%;
  font-size:1.25rem;
  line-height:1;
  box-shadow:0 8px 24px rgba(219,62,213,.28);
}

.story-page--chat-v3 .v3-live-send:disabled{opacity:.55;cursor:wait}

.story-page--chat-v3 .v3-live-typing{
  margin:0;
}

.story-page--chat-v3 .v3-live-teaser{
  display:grid!important;
}

.story-page--chat-v3 .chat-v3-ready .wizard--chat .v3-field,
.story-page--chat-v3 .chat-v3-ready .v3-validation-row{
  display:none;
}

.story-page--chat-v3 .chat-v3-ready .wizard--chat .v3-field.v3-field--active,
.story-page--chat-v3 .chat-v3-ready .wizard--chat .v3-field.v3-field--complete,
.story-page--chat-v3 .chat-v3-ready .v3-validation-row.is-active{
  display:grid;
}

.story-page--chat-v3 .v3-field--active{
  animation:v3-question-in .24s ease both;
}

.story-page--chat-v3 .v3-field--complete .field__input,
.story-page--chat-v3 .v3-field--complete .ac-wrap{
  display:none!important;
}

.story-page--chat-v3 .v3-validation-row{
  justify-items:end;
  align-items:center;
  width:min(72%,620px);
  height:56px;
  margin:-66px 0 10px auto;
  padding-right:6px;
  position:relative;
  z-index:4;
  pointer-events:none;
}

.story-page--chat-v3 .v3-validate{
  width:44px;
  min-width:44px;
  height:44px;
  min-height:44px;
  padding:0;
  border-radius:50%;
  pointer-events:auto;
  font-size:1.25rem;
  line-height:1;
  box-shadow:0 8px 24px rgba(219,62,213,.28);
}

.story-page--chat-v3 .v3-field--active .field__input{padding-right:64px}

.story-page--chat-v3 .v3-answer{
  margin:0 0 6px auto;
  animation:v3-answer-in .22s ease both;
}

.story-page--chat-v3 .v3-field-error{
  display:block;
  width:min(72%,620px);
  margin:-6px 0 2px auto;
  color:#ffb2ca;
  font-size:.82rem;
  font-weight:750;
  text-align:right;
}

.story-page--chat-v3 .v3-actions-managed{
  display:none!important;
}

@keyframes v3-question-in{
  from{opacity:0;transform:translateY(10px)}
  to{opacity:1;transform:none}
}

@keyframes v3-answer-in{
  from{opacity:0;transform:translateY(8px) scale(.985)}
  to{opacity:1;transform:none}
}

@media(max-width:720px){
  .story-page--chat-v3 .form-shell{
    width:calc(100% - 24px)!important;
  }
  .story-page--chat-v3 .form-card--chat{
    width:100%;
    margin-inline:0;
    backdrop-filter:none!important;
  }
  .story-page--chat-v3 .v3-validation-row,
  .story-page--chat-v3 .v3-field-error{
    width:88%;
  }
  .story-page--chat-v3 .v3-validate{
    width:44px;
    min-width:44px;
  }
  .story-page--chat-v3 .v3-answer{
    max-width:88%;
  }
  .story-page--chat-v3 .v3-live-composer{
    position:fixed;
    left:50%;
    bottom:calc(var(--v3-keyboard-offset,0px) + max(8px,env(safe-area-inset-bottom)));
    width:min(620px,calc(100vw - 28px));
    margin:0;
    transform:translateX(-50%);
  }
  .story-page--chat-v3 .v3-conversation{
    padding-bottom:92px;
    scroll-margin-bottom:92px;
  }
  .story-page--chat-v3 .v3-live-turn,
  .story-page--chat-v3 .v3-answer{
    scroll-margin-bottom:92px;
  }
  .story-page--chat-v3 .story-form{padding-bottom:112px}
  .story-page--chat-v3 .v3-live-question strong{font-size:.98rem}
  .story-page--chat-v3 .v3-live-question span{font-size:.84rem}
}

@media(prefers-reduced-motion:reduce){
  .story-page--chat-v3 .v3-field--active,
  .story-page--chat-v3 .v3-answer{animation:none}
}
