
.talk-page {
  margin: 0;
  color: #f2f3f8;
  background: #07080d;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "SF Pro Display", "PingFang TC", "Noto Sans TC", sans-serif;
  -webkit-font-smoothing: antialiased;
}
.talk-fx {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
  background: url("/assets/generative/gramo-talk-atmosphere.jpg?v=4") center / cover no-repeat;
}
.talk-fx::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(7, 8, 13, .62);
}
.talk-fx i {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: .5;
}
.talk-fx .a { width: 38vw; height: 38vw; left: -10%; top: 8%; background: rgba(70,217,232,.2); }
.talk-fx .b { width: 32vw; height: 32vw; right: -8%; top: -6%; background: rgba(130,132,255,.16); }
.talk-fx .c { width: 28vw; height: 28vw; left: 40%; bottom: -18%; background: rgba(212,168,83,.1); }
.talk-fx .grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse at 30% 20%, #000 10%, transparent 70%);
}

body.talk-page, body.talk-page * { box-sizing: border-box; }

body.has-gramo-header > main#talk-app {
  padding-top: var(--gramo-header-h, 56px);
}

#talk-app {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr);
  height: 100dvh;
  max-height: 100dvh;
  margin: 0;
  overflow: hidden;
}

.talk-list {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  height: 100%;
  background: rgba(12, 14, 22, .72);
  border-right: 1px solid rgba(255,255,255,.08);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
}
.talk-list-head {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.talk-list-head h1 { margin: 0; font-size: 20px; letter-spacing: -.03em; font-weight: 640; }
.talk-new {
  width: 36px; height: 36px;
  display: grid; place-items: center;
  border: 0;
  border-radius: 99px;
  background: linear-gradient(135deg, #7ef0fb, #46d9e8);
  color: #061016;
  text-decoration: none;
  font-size: 22px;
  line-height: 1;
  box-shadow: 0 0 22px rgba(70,217,232,.35);
  cursor: pointer;
}
.talk-convo-list {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  padding: 8px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: stretch;
  gap: 4px;
  background:
    radial-gradient(ellipse at 20% 0%, rgba(70,217,232,.08), transparent 55%),
    linear-gradient(180deg, rgba(255,255,255,.02), transparent 40%);
}
.talk-item {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) 36px;
  gap: 10px;
  align-items: center;
  align-self: stretch;
  flex: 0 0 68px !important;
  flex-grow: 0 !important;
  flex-shrink: 0 !important;
  height: 68px !important;
  max-height: 68px !important;
  min-height: 68px !important;
  width: 100%;
  overflow: hidden;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 14px;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
}
.talk-item:hover { background: rgba(255,255,255,.05); }
.talk-item.is-on {
  background: linear-gradient(165deg, rgba(70,217,232,.16), rgba(255,255,255,.04));
  border-color: rgba(70,217,232,.3);
  box-shadow: 0 0 24px rgba(70,217,232,.08);
}
.talk-ava {
  width: 44px; height: 44px;
  min-width: 44px; min-height: 44px;
  border-radius: 99px;
  background: radial-gradient(circle at 30% 20%, rgba(70,217,232,.35), #1c2230);
  display: grid; place-items: center;
  color: #7ef0fb;
  font-weight: 700;
  overflow: hidden;
}
.talk-ava img { width: 44px; height: 44px; object-fit: cover; display: block; }
.talk-open {
  border: 0; background: transparent; color: inherit; text-align: left;
  padding: 0; cursor: pointer; min-width: 0; overflow: hidden;
  height: 44px;
}
.talk-item b { display: block; font-size: 14px; font-weight: 650; line-height: 1.2; }
.talk-item small {
  display: block;
  margin-top: 4px;
  color: rgba(180,184,205,.72);
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.talk-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: center;
  gap: 6px;
  height: 44px;
}
.talk-item time { color: rgba(180,184,205,.5); font-size: 11px; }
.talk-del {
  width: 22px; height: 22px;
  border: 0;
  border-radius: 99px;
  background: rgba(255,255,255,.06);
  color: rgba(180,184,205,.75);
  cursor: pointer;
  font-size: 12px;
  line-height: 1;
  opacity: .7;
}
.talk-del:hover { background: rgba(255,90,80,.22); color: #ffb4a8; opacity: 1; }

.talk-main { position: relative; min-width: 0; overflow: hidden; }
.talk-main::before {
  content: "";
  position: absolute;
  width: 420px; height: 420px;
  right: -120px; top: -160px;
  border-radius: 50%;
  background: rgba(70,217,232,.12);
  filter: blur(50px);
  pointer-events: none;
}
.talk-pane { display: none; height: 100%; position: relative; z-index: 1; }
.talk-pane.is-on { display: flex; flex-direction: column; }

.talk-pane.is-on#talk-empty {
  justify-content: center;
  align-items: center;
  padding: 48px 56px;
}

.setup-scroll {
  overflow: auto;
  padding: 16px 28px 28px;
  width: 100%;
  max-width: none;
  box-sizing: border-box;
}
#talk-setup.is-on { justify-content: flex-start; }
.setup-back[hidden] { display: none !important; }
#chat-back { display: none; }
.setup-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  align-items: stretch;
}
.setup-card-wide { margin-top: 14px; }
#setup-form { max-width: none; }
.setup-go {
  width: auto !important;
  min-width: 240px;
  margin-top: 16px !important;
}
.setup-scroll h2 { margin: 0 0 8px; font-size: 30px; letter-spacing: -.045em; font-weight: 640; }
.setup-sub { margin: 0 0 22px; color: rgba(180,184,205,.82); }
.setup-card {
  position: relative;
  margin: 0 0 14px;
  padding: 18px 16px;
  border-radius: 22px;
  background: linear-gradient(165deg, rgba(255,255,255,.08), rgba(255,255,255,.03));
  border: 1px solid rgba(255,255,255,.12);
  box-shadow: 0 18px 50px rgba(0,0,0,.28);
  backdrop-filter: blur(18px);
  overflow: hidden;
}
.setup-card::before {
  content: "";
  position: absolute;
  width: 160px; height: 160px;
  right: -40px; top: -50px;
  border-radius: 50%;
  background: rgba(70,217,232,.16);
  filter: blur(24px);
  pointer-events: none;
}
.setup-card h3 { position: relative; margin: 0 0 14px; font-size: 16px; }
.setup-card label { display: block; margin: 0 0 12px; position: relative; }
.setup-card label span, .setup-row > span { display: block; margin-bottom: 6px; color: rgba(180,184,205,.8); font-size: 13px; }
.setup-card input[type="text"] {
  width: 100%;
  padding: 12px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(4,5,9,.55);
  color: #f2f3f8;
  font: inherit;
}
.setup-row { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; position: relative; }
.setup-row.is-off { display: none !important; }
.setup-pills { display: flex; gap: 8px; flex-wrap: wrap; }
.setup-pills button {
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.03);
  color: rgba(180,184,205,.88);
  border-radius: 999px;
  padding: 7px 14px;
  cursor: pointer;
}
.setup-pills button.is-on {
  background: linear-gradient(135deg, #7ef0fb, #46d9e8);
  color: #061016;
  border-color: transparent;
}
.setup-check { display: flex !important; gap: 10px; align-items: flex-start; font-size: 13px; color: rgba(180,184,205,.86); }
.setup-check a { color: #7ef0fb; }
.setup-note { margin: 0 0 12px; color: rgba(180,184,205,.7); font-size: 13px; }
.setup-photo {
  width: 100%;
  min-height: 96px;
  border-radius: 16px;
  border: 1px dashed rgba(70,217,232,.28);
  background: rgba(4,5,9,.45);
  color: #f2f3f8;
  cursor: pointer;
  overflow: hidden;
}
.setup-photo img { display: block; width: 100%; max-height: 220px; object-fit: cover; }
.setup-go {
  width: 100%;
  margin-top: 8px;
  border: 0;
  border-radius: 999px;
  padding: 15px;
  background: linear-gradient(135deg, #7ef0fb, #46d9e8 55%, #e8c97a);
  color: #061016;
  font-weight: 760;
  font-size: 16px;
  cursor: pointer;
  box-shadow: 0 0 28px rgba(70,217,232,.32);
}
.setup-err { color: #ffb4a8; font-size: 13px; }
.setup-back {
  border: 0; background: transparent; color: #7ef0fb;
  padding: 0 0 12px; cursor: pointer; font: inherit;
}

.chat-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  background: rgba(17,20,28,.72);
  backdrop-filter: blur(16px);
}
.chat-ava {
  width: 40px; height: 40px;
  min-width: 40px;
  border-radius: 99px;
  overflow: hidden;
  display: grid; place-items: center;
  background: radial-gradient(circle at 30% 20%, rgba(70,217,232,.35), #1c2230);
  color: #7ef0fb;
  font-weight: 700;
}
.chat-ava img { width: 40px; height: 40px; object-fit: cover; display: block; }
.chat-who { flex: 1; min-width: 0; }
.chat-who b { display: block; }
.chat-who span { color: rgba(180,184,205,.7); font-size: 12px; }
.chat-row.asst { align-items: flex-start; gap: 8px; }
.chat-row-ava {
  width: 28px; height: 28px;
  min-width: 28px;
  border-radius: 99px;
  overflow: hidden;
  display: grid; place-items: center;
  background: radial-gradient(circle at 30% 20%, rgba(70,217,232,.35), #1c2230);
  color: #7ef0fb;
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 2px;
}
.chat-row-ava img { width: 28px; height: 28px; object-fit: cover; display: block; }
.chat-head-del {
  border: 0;
  background: rgba(255,255,255,.06);
  color: rgba(180,184,205,.86);
  border-radius: 999px;
  padding: 8px 12px;
  cursor: pointer;
  font-size: 13px;
}
.chat-head-del:hover { background: rgba(255,90,80,.2); color: #ffb4a8; }
.chat-thread {
  flex: 1;
  overflow: auto;
  padding: 18px 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.chat-row { display: flex; }
.chat-row.user { justify-content: flex-end; }
.chat-bubble {
  max-width: 76%;
  padding: 10px 14px;
  border-radius: 16px;
  line-height: 1.5;
  font-size: 15px;
  white-space: pre-wrap;
}
.chat-row.user .chat-bubble {
  background: linear-gradient(165deg, rgba(70,217,232,.28), rgba(26,107,114,.7));
  color: #e8fbfe;
  border-bottom-right-radius: 4px;
}
.chat-row.asst .chat-bubble {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.08);
  color: #f2f3f8;
  border-bottom-left-radius: 4px;
}
.chat-row.err .chat-bubble { background: rgba(255,120,100,.12); color: #ffc8bc; }
.chat-compose {
  display: flex;
  gap: 8px;
  padding: 10px 12px 14px;
  background: rgba(17,20,28,.8);
  border-top: 1px solid rgba(255,255,255,.08);
  backdrop-filter: blur(16px);
}
.chat-compose input[type="text"] {
  flex: 1;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 999px;
  padding: 12px 16px;
  background: rgba(4,5,9,.55);
  color: #f2f3f8;
  font: inherit;
}
.chat-send, .chat-attach {
  width: 42px; height: 42px;
  border: 0; border-radius: 99px;
  background: linear-gradient(135deg, #7ef0fb, #46d9e8);
  color: #061016;
  font-size: 18px; font-weight: 800; cursor: pointer;
  box-shadow: 0 0 18px rgba(70,217,232,.3);
}
.chat-attach { background: rgba(255,255,255,.06); color: #f2f3f8; box-shadow: none; }

@media (max-width: 900px) {
  .setup-grid { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  #talk-app { grid-template-columns: 1fr; }
  .talk-list { display: none; }
  body.talk-show-list .talk-list { display: flex; }
  body.talk-show-list .talk-main { display: none; }
  .setup-back, #chat-back { display: inline-block !important; }
}

#talk-kind.is-on, #talk-empty.is-on {
  justify-content: center;
  align-items: center;
  padding: 48px 56px;
}
.kind-kicker {
  margin: 0 0 14px;
  font-size: 11px;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: rgba(232,201,122,.82);
  font-weight: 620;
}
.kind-sheet {
  position: relative;
  width: min(860px, 100%);
  padding: 8px 0 0;
  border-radius: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}
.kind-sheet h2 {
  margin: 0 0 10px;
  font-size: 34px;
  letter-spacing: -.045em;
  font-weight: 560;
  line-height: 1.2;
  color: #f6f7fb;
}
.kind-sub { margin: 0 0 28px; color: rgba(180,184,205,.72); font-size: 15px; }
.kind-close {
  position: absolute;
  top: 16px; right: 16px;
  width: 32px; height: 32px;
  border: 0; border-radius: 99px;
  background: rgba(255,255,255,.08);
  color: #f2f3f8;
  cursor: pointer;
}
.kind-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.kind-card {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  min-height: 168px;
  text-align: left;
  padding: 26px 24px 22px;
  border-radius: 24px;
  border: 1px solid rgba(255,255,255,.12);
  background:
    linear-gradient(165deg, rgba(255,255,255,.07), rgba(255,255,255,.02)),
    rgba(10,12,20,.45);
  color: inherit;
  cursor: pointer;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.kind-card::before {
  content: "";
  position: absolute;
  width: 220px; height: 220px;
  right: -80px; top: -90px;
  border-radius: 50%;
  background: rgba(70,217,232,.18);
  filter: blur(28px);
  pointer-events: none;
}
.kind-card.pet::before { background: rgba(232,201,122,.18); }
.kind-card:hover {
  transform: translateY(-2px);
  border-color: rgba(126,240,251,.38);
  box-shadow: 0 18px 40px rgba(0,0,0,.28);
}
.kind-card.pet:hover { border-color: rgba(232,201,122,.42); }
.kind-ico {
  width: 48px; height: 48px;
  border-radius: 99px;
  display: grid; place-items: center;
  color: #7ef0fb;
  background: rgba(70,217,232,.16);
}
.kind-ico.pet { color: #e8c97a; background: rgba(232,201,122,.16); }
.kind-card b { font-size: 18px; font-weight: 680; }
.kind-card small { color: rgba(180,184,205,.78); font-size: 13px; line-height: 1.45; }
.kind-go {
  position: absolute;
  right: 18px; top: 22px;
  color: rgba(180,184,205,.55);
  font-size: 20px;
}
@media (max-width: 760px) {
  #talk-kind.is-on, #talk-empty.is-on { justify-content: flex-end; padding: 0; }
  .kind-sheet {
    width: 100%;
    border-radius: 24px 24px 0 0;
    padding: 22px 18px 28px;
    background: linear-gradient(180deg, rgba(18,20,28,.92), rgba(10,12,18,.96));
    border: 1px solid rgba(255,255,255,.08);
  }
  .kind-grid { grid-template-columns: 1fr; }
  .kind-sheet h2 { font-size: 22px; }
}


/* talk-setup-gen */
.talk-fx::after { background: rgba(7, 8, 13, .48); }
.talk-list {
  background: rgba(10, 12, 20, .55);
  border-right-color: rgba(255,255,255,.07);
}
.talk-new {
  box-shadow: 0 0 0 1px rgba(255,255,255,.22) inset, 0 8px 20px rgba(70,217,232,.25);
}
.talk-item.is-on {
  background: linear-gradient(165deg, rgba(70,217,232,.18), rgba(255,255,255,.03));
  border-color: rgba(126,240,251,.32);
}

.setup-scroll {
  padding: 28px 36px 40px;
  background:
    radial-gradient(ellipse 50% 40% at 90% 0%, rgba(70,217,232,.08), transparent 60%),
    radial-gradient(ellipse 40% 35% at 10% 80%, rgba(232,201,122,.06), transparent 62%);
}
.setup-scroll .kind-kicker { margin-bottom: 10px; }
.setup-scroll h2 {
  font-size: clamp(28px, 3.2vw, 40px);
  font-weight: 560;
  letter-spacing: -.048em;
  line-height: 1.15;
}
.setup-sub { color: rgba(180,184,205,.7); max-width: 36em; }

.setup-card {
  margin: 0;
  padding: 22px 20px 18px;
  border-radius: 24px;
  background:
    linear-gradient(165deg, rgba(255,255,255,.09), rgba(255,255,255,.025));
  border: 1px solid rgba(255,255,255,.13);
  box-shadow:
    0 20px 50px rgba(0,0,0,.28),
    0 1px 0 rgba(255,255,255,.1) inset;
  backdrop-filter: blur(22px) saturate(1.15);
}
.setup-card::before {
  width: 200px; height: 200px;
  background: rgba(70,217,232,.2);
}
.setup-card:nth-child(2)::before { background: rgba(232,201,122,.16); }
.setup-card-wide { margin-top: 14px; }
.setup-card-wide::before { background: rgba(130,132,255,.14); }
.setup-card h3 {
  font-size: 13px;
  letter-spacing: .14em;
  text-transform: uppercase;
  font-weight: 650;
  color: rgba(232,201,122,.88);
}

.setup-card input[type="text"] {
  padding: 13px 14px;
  border-radius: 14px;
  background: rgba(4,6,12,.5);
  border: 1px solid rgba(255,255,255,.1);
  outline: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.setup-card input[type="text"]:focus {
  border-color: rgba(126,240,251,.4);
  box-shadow: 0 0 0 3px rgba(70,217,232,.12);
}

.setup-pills button {
  background: rgba(255,255,255,.04);
  border-color: rgba(255,255,255,.1);
  padding: 8px 16px;
  transition: transform .12s ease, background .12s ease;
}
.setup-pills button.is-on {
  background: linear-gradient(145deg, #9af4fb, #46d9e8);
  color: #061016;
  box-shadow: 0 0 0 1px rgba(255,255,255,.2) inset;
}
.setup-pills button:hover { transform: translateY(-1px); }

.setup-photo {
  min-height: 120px;
  border-radius: 18px;
  border: 1px dashed rgba(126,240,251,.32);
  background:
    radial-gradient(ellipse at 50% 0%, rgba(70,217,232,.1), transparent 60%),
    rgba(4,6,12,.4);
  transition: border-color .15s ease, background .15s ease;
}
.setup-photo:hover {
  border-color: rgba(126,240,251,.55);
  background:
    radial-gradient(ellipse at 50% 0%, rgba(70,217,232,.16), transparent 60%),
    rgba(4,6,12,.5);
}

.setup-go {
  min-width: 260px !important;
  padding: 14px 28px !important;
  font-weight: 700;
  letter-spacing: -.01em;
  background: linear-gradient(145deg, #b6f7fc 0%, #46d9e8 46%, #e8c97a 120%) !important;
  box-shadow:
    0 0 0 1px rgba(255,255,255,.25) inset,
    0 10px 28px rgba(70,217,232,.22) !important;
}
.setup-go:hover { filter: brightness(1.05); }

.chat-head {
  background: rgba(12,14,22,.55);
  border-bottom-color: rgba(255,255,255,.07);
}
.chat-compose {
  background: rgba(12,14,22,.62);
}
.chat-compose input[type="text"] {
  background: rgba(4,6,12,.5);
  border-color: rgba(255,255,255,.1);
}
.chat-compose input[type="text"]:focus {
  outline: none;
  border-color: rgba(126,240,251,.4);
}

.talk-list-titles { min-width: 0; }
.talk-credits,
.setup-credits,
.chat-credits {
  margin: 0;
  color: rgba(232,201,122,.88);
  font-size: 12px;
  letter-spacing: .02em;
  font-weight: 620;
}
.talk-credits { margin-top: 4px; }
.setup-credits {
  margin: 14px 0 8px;
  color: rgba(180,184,205,.78);
}
.chat-credits {
  flex: 0 0 auto;
  padding: 8px 16px 0;
  color: rgba(180,184,205,.72);
}


.setup-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin: 0 0 22px;
}
.setup-hero .setup-sub { margin: 8px 0 0; }
.setup-credits {
  flex: 0 0 auto;
  margin: 0;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(232,201,122,.1);
  border: 1px solid rgba(232,201,122,.28);
  color: #ead08a;
  white-space: nowrap;
}

.setup-studio {
  display: grid;
  grid-template-columns: minmax(280px, 38%) minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}
.setup-stage {
  position: sticky;
  top: 0;
}
.setup-photo {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 420px;
  height: min(58vh, 560px);
  border-radius: 28px;
  overflow: hidden;
  border: 1px solid rgba(126,240,251,.28);
  background:
    radial-gradient(ellipse at 50% 0%, rgba(70,217,232,.16), transparent 55%),
    radial-gradient(ellipse at 80% 100%, rgba(232,201,122,.1), transparent 50%),
    rgba(6,8,14,.55);
  box-shadow:
    0 24px 60px rgba(0,0,0,.35),
    0 1px 0 rgba(255,255,255,.1) inset;
}
.setup-photo-copy {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: #f2f3f8;
}
.setup-photo-copy small {
  color: rgba(180,184,205,.7);
  font-size: 12px;
}
.setup-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: cover;
}
.setup-photo:has(img:not([hidden])) .setup-photo-copy { display: none; }
.setup-stage .setup-row { margin-top: 12px; }

.setup-fields {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 22px 22px 20px;
  border-radius: 28px;
  background: linear-gradient(165deg, rgba(255,255,255,.08), rgba(255,255,255,.025));
  border: 1px solid rgba(255,255,255,.12);
  box-shadow: 0 20px 50px rgba(0,0,0,.28), 0 1px 0 rgba(255,255,255,.08) inset;
  backdrop-filter: blur(22px) saturate(1.15);
}
.setup-fields section { position: relative; }
.setup-fields h3 {
  margin: 0 0 12px;
  font-size: 12px;
  letter-spacing: .16em;
  text-transform: uppercase;
  font-weight: 650;
  color: rgba(232,201,122,.88);
}
.setup-fields label { display: block; margin: 0 0 12px; }
.setup-fields label span,
.setup-fields .setup-row > span {
  display: block;
  margin-bottom: 6px;
  color: rgba(180,184,205,.78);
  font-size: 13px;
}
.setup-fields input[type="text"] {
  width: 100%;
  padding: 13px 14px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.1);
  background: rgba(4,6,12,.5);
  color: #f2f3f8;
  font: inherit;
  outline: none;
}
.setup-fields input[type="text"]:focus {
  border-color: rgba(126,240,251,.4);
  box-shadow: 0 0 0 3px rgba(70,217,232,.12);
}
.setup-fields .setup-go {
  width: 100% !important;
  min-width: 0 !important;
  margin-top: 4px !important;
}

@media (max-width: 900px) {
  .setup-studio { grid-template-columns: 1fr; }
  .setup-stage { position: static; }
  .setup-photo { height: 280px; min-height: 240px; }
  .setup-hero { flex-direction: column; align-items: flex-start; }
}


.setup-fields {
  position: relative;
  overflow: hidden;
}
.setup-fields::before {
  content: "";
  position: absolute;
  inset: -40% -20% auto auto;
  width: 280px; height: 280px;
  border-radius: 50%;
  background: rgba(70,217,232,.18);
  filter: blur(30px);
  pointer-events: none;
}
.setup-fields::after {
  content: "";
  position: absolute;
  left: -30%; bottom: -40%;
  width: 260px; height: 260px;
  border-radius: 50%;
  background: rgba(232,201,122,.12);
  filter: blur(28px);
  pointer-events: none;
}
.setup-live {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  margin-bottom: 4px;
  border-radius: 20px;
  background: linear-gradient(165deg, rgba(70,217,232,.14), rgba(255,255,255,.04));
  border: 1px solid rgba(126,240,251,.22);
  box-shadow: 0 0 32px rgba(70,217,232,.08);
}
.setup-live-ava {
  width: 56px; height: 56px;
  min-width: 56px;
  border-radius: 99px;
  overflow: hidden;
  display: grid; place-items: center;
  background: radial-gradient(circle at 30% 20%, rgba(70,217,232,.4), #12141c);
  color: #7ef0fb;
  font-size: 22px;
  font-weight: 700;
  box-shadow: 0 0 0 1px rgba(255,255,255,.16), 0 0 24px rgba(70,217,232,.25);
}
.setup-live-ava img { width: 56px; height: 56px; object-fit: cover; display: block; }
.setup-live-who { min-width: 0; }
.setup-live-who b { display: block; font-size: 18px; letter-spacing: -.03em; }
.setup-live-who span { color: rgba(180,184,205,.75); font-size: 13px; }

.setup-fields section {
  position: relative;
  z-index: 1;
  padding: 14px 14px 8px;
  border-radius: 18px;
  background: rgba(4,6,12,.28);
  border: 1px solid rgba(255,255,255,.07);
}
.setup-fields input[type="text"] {
  background: rgba(255,255,255,.03);
  border-color: rgba(255,255,255,.12);
}
.setup-go {
  position: relative;
  z-index: 1;
}


.talk-pins {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 8px 8px 4px;
}
.talk-pin {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 12px;
  gap: 10px;
  align-items: center;
  align-self: stretch;
  flex: 0 0 68px;
  width: 100%;
  height: 68px;
  max-height: 68px;
  min-height: 68px;
  overflow: hidden;
  padding: 8px 10px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,.1);
  background: linear-gradient(165deg, rgba(255,255,255,.07), rgba(255,255,255,.02));
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.talk-pin::after {
  content: "›";
  color: rgba(180,184,205,.45);
  font-size: 22px;
  line-height: 1;
}
.talk-pin img {
  width: 48px; height: 48px;
  border-radius: 14px;
  object-fit: cover;
  display: block;
  box-shadow: 0 0 18px rgba(70,217,232,.16);
}
.talk-pin b { display: block; font-size: 14px; }
.talk-pin small { display: block; margin-top: 3px; color: rgba(180,184,205,.7); font-size: 12px; }
.talk-pin:hover { border-color: rgba(126,240,251,.32); }
.talk-pin.is-on {
  border-color: rgba(126,240,251,.32);
  background: linear-gradient(165deg, rgba(70,217,232,.18), rgba(255,255,255,.03));
  box-shadow: 0 0 24px rgba(70,217,232,.08);
}

.talk-sheet {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: end center;
  background: rgba(4,6,12,.55);
  backdrop-filter: blur(10px);
}
.talk-sheet[hidden] { display: none !important; }
.talk-sheet-card {
  width: min(480px, 100%);
  max-height: min(86dvh, 720px);
  display: flex;
  flex-direction: column;
  padding: 18px 18px 16px;
  border-radius: 24px 24px 0 0;
  background: linear-gradient(180deg, rgba(22,24,34,.96), rgba(10,12,18,.98));
  border: 1px solid rgba(255,255,255,.1);
  box-shadow: 0 -20px 60px rgba(0,0,0,.45);
}
.talk-sheet-card header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.talk-sheet-card h2 { margin: 0; font-size: 20px; letter-spacing: -.03em; }
.help-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 4px 16px 10px;
}
.help-chips button {
  border: 1px solid rgba(126,240,251,.28);
  background: rgba(70,217,232,.08);
  color: #9af4fb;
  border-radius: 999px;
  padding: 7px 12px;
  cursor: pointer;
  font-size: 13px;
}






#talk-pay.talk-pane {
  background: transparent;
}
#talk-pay .chat-thread { background: transparent; }
.pay-widget {
  width: min(860px, 100%);
  margin: 4px auto 8px;
  padding: 4px 8px 8px;
  background: transparent;
  border: 0;
  box-shadow: none;
}
.pay-hero { margin: 4px 4px 16px; }
.pay-bal-kicker {
  display: block;
  margin-bottom: 6px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .16em;
  color: rgba(240,212,138,.88);
}
.pay-bal-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
}
.pay-bal-row b {
  font-size: 72px;
  font-weight: 700;
  letter-spacing: -.06em;
  line-height: .88;
  background: linear-gradient(118deg, #fff6d6 0%, #f0d48a 32%, #7ef0fb 78%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.pay-unit { font-size: 16px; font-weight: 650; color: rgba(242,243,248,.8); }
.pay-hero small {
  display: block;
  margin-top: 8px;
  color: rgba(180,184,205,.58);
  font-size: 12px;
}
.pay-costs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 4px 18px;
}
.pay-costs span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.1);
  background: rgba(255,255,255,.05);
  color: rgba(180,184,205,.86);
  font-size: 12px;
}
.pay-costs b { color: #f2f3f8; font-weight: 650; }
.pay-packs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.pay-pack {
  position: relative;
  overflow: visible;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-height: 0;
  padding: 20px 18px 16px;
  border-radius: 20px;
  border: 1px solid rgba(255,255,255,.1);
  background: rgba(255,255,255,.045);
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: default;
  transition: transform .18s ease, border-color .18s ease;
}
.pay-pack-pts {
  font-size: 44px;
  font-weight: 720;
  letter-spacing: -.05em;
  line-height: .9;
  color: #f7f8ff;
}
.pay-pack-unit {
  margin-top: 6px;
  font-size: 13px;
  color: rgba(180,184,205,.72);
}
.pay-pack-price {
  margin-top: 14px;
  font-size: 14px;
  font-weight: 650;
  color: rgba(240,212,138,.95);
}
.pay-pack {
  cursor: default;
}
.pay-pack-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .04em;
  color: #090a10;
  background: linear-gradient(118deg, #f0d48a 0%, #7ef0fb 100%);
}
.pay-pack-actions {
  margin-top: auto;
  padding-top: 18px;
  align-self: stretch;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.pay-opt {
  display: flex;
  flex-direction: column;
  width: 100%;
  padding: 0;
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,.16);
  background: linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.03));
  color: inherit;
  cursor: pointer;
  font: inherit;
  text-align: center;
  -webkit-tap-highlight-color: transparent;
  transition: transform .14s ease, border-color .14s ease, box-shadow .14s ease, filter .14s ease;
}
.pay-opt.is-alipay {
  border-color: rgba(80,170,255,.5);
  box-shadow: 0 0 0 1px rgba(80,170,255,.12), 0 10px 22px rgba(0,0,0,.22);
}
.pay-opt.is-card {
  border-color: rgba(240,212,138,.42);
  box-shadow: 0 0 0 1px rgba(240,212,138,.1), 0 10px 22px rgba(0,0,0,.22);
}
.pay-opt-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 84px;
  padding: 16px 14px 12px;
}
.pay-opt-logo img {
  display: block;
  width: 100%;
  max-height: 52px;
  object-fit: contain;
  pointer-events: none;
  user-select: none;
  background: transparent;
}
.pay-opt.is-alipay .pay-opt-logo {
  min-height: 96px;
}
.pay-opt.is-alipay .pay-opt-logo img { max-height: 64px; }
.pay-opt-label {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 9px 10px 11px;
  border-top: 1px solid rgba(255,255,255,.1);
  background: rgba(232,214,176,.1);
}
.pay-opt-label b {
  font-size: 13px;
  font-weight: 700;
  color: #f4f1ea;
  letter-spacing: .02em;
}
.pay-opt-label small {
  font-size: 11px;
  color: rgba(210,200,176,.78);
}
.pay-opt:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
}
.pay-opt.is-alipay:hover {
  border-color: rgba(126,210,255,.9);
  box-shadow: 0 12px 26px rgba(70,160,255,.22);
}
.pay-opt.is-card:hover {
  border-color: rgba(240,212,138,.85);
  box-shadow: 0 12px 26px rgba(232,201,122,.2);
}
.pay-opt:active {
  transform: translateY(1px) scale(.98);
  filter: brightness(.92);
}
.pay-opt:focus-visible {
  outline: 2px solid rgba(126,240,251,.8);
  outline-offset: 2px;
}
.pay-pack[data-busy="1"] {
  pointer-events: none;
  opacity: .78;
}
.pay-opt.is-wait {
  filter: brightness(.9);
}
.pay-pack.is-rec {
  border-color: rgba(240,212,138,.55);
  box-shadow: 0 0 28px rgba(232,201,122,.16);
}
.pay-pack:hover {
  transform: translateY(-2px);
  border-color: rgba(126,240,251,.4);
}
.pay-foot {
  margin: 14px 4px 0;
  font-size: 12px;
  color: rgba(180,184,205,.48);
}
@media (max-width: 760px) {
  .pay-packs { grid-template-columns: 1fr; }
  .pay-pack { min-height: 0; }
  .pay-bal-row b { font-size: 52px; }
}





@media (min-width: 761px) {
  .talk-sheet { place-items: center; }
  .talk-sheet-card { border-radius: 24px; }
}


.talk-video {
  width: min(360px, 72%);
  max-height: min(70vh, 620px);
  aspect-ratio: 9 / 16;
  border-radius: 20px;
  overflow: hidden;
  background: #090a10;
  border: 1px solid rgba(126,240,251,.28);
  box-shadow: 0 16px 40px rgba(0,0,0,.35);
}
.talk-video video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  object-position: center top;
}


/* chat digital-human stage + composer photo sheet */
#talk-chat.talk-pane.is-on {
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.chat-stage {
  flex: 1 1 auto;
  position: relative;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.chat-stage .chat-thread {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  position: relative;
  z-index: 1;
}
.chat-dh {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  background: #090a10;
}
.chat-dh[hidden] { display: none !important; }
.chat-dh.is-ready {
  display: grid;
  place-items: center;
  background: #090a10;
}
.chat-dh.is-ready video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  object-position: center center;
}
.chat-dh.is-generating {
  z-index: 2;
  display: grid;
  place-items: center;
  background: rgba(9, 10, 16, .42);
}
.dh-progress {
  width: min(380px, 86%);
  padding: 16px 18px 14px;
  border-radius: 18px;
  background: rgba(18, 20, 28, .78);
  border: 1px solid rgba(255, 255, 255, .14);
  box-shadow:
    0 16px 40px rgba(0, 0, 0, .4),
    0 1px 0 rgba(255, 255, 255, .08) inset;
  backdrop-filter: blur(22px) saturate(1.2);
  -webkit-backdrop-filter: blur(22px) saturate(1.2);
}
.dh-progress-title {
  margin: 0 0 12px;
  color: #fff;
  font-size: 15px;
  font-weight: 650;
  letter-spacing: -.02em;
  text-align: left;
}
.dh-progress-track {
  height: 6px;
  border-radius: 99px;
  overflow: hidden;
  background: rgba(40, 44, 56, .95);
}
.dh-progress-bar {
  display: block;
  height: 100%;
  width: 4%;
  border-radius: 99px;
  background: #7ef0fb;
  box-shadow: 0 0 12px rgba(126, 240, 251, .45);
  transition: width .45s ease;
}
.dh-progress-meta {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-top: 10px;
  font-size: 13px;
  line-height: 1.4;
}
.dh-progress-meta span {
  color: rgba(180, 184, 205, .78);
  text-align: left;
  min-width: 0;
}
.dh-progress-meta b {
  color: #7ef0fb;
  font-weight: 700;
  flex: 0 0 auto;
  margin-left: auto;
}
.chat-stage.is-dh:not(.is-generating) .chat-thread {
  background: transparent;
}

.talk-sheet-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  padding: 0;
  margin: 0;
  background: rgba(0, 0, 0, .45);
  cursor: pointer;
}
.talk-sheet-card {
  position: relative;
  z-index: 1;
}
#dh-sheet.talk-sheet {
  background: rgba(4, 6, 12, .28);
  backdrop-filter: blur(16px) saturate(1.15);
  -webkit-backdrop-filter: blur(16px) saturate(1.15);
}
.dh-sheet-card {
  width: min(560px, calc(100% - 28px));
  max-height: min(90dvh, 760px);
  overflow: auto;
  padding: 22px 22px 24px;
  gap: 0;
  background:
    linear-gradient(180deg, rgba(22, 24, 34, .92), rgba(9, 10, 16, .96));
  border: 1px solid rgba(255, 255, 255, .1);
  box-shadow:
    0 24px 70px rgba(0, 0, 0, .5),
    0 1px 0 rgba(255, 255, 255, .08) inset;
}
.dh-well {
  display: grid;
  place-items: center;
  width: 100%;
  height: min(420px, 56dvh);
  min-height: 240px;
  margin: 0;
  padding: 0;
  border-radius: 24px;
  border: 1px solid rgba(126, 240, 251, .62);
  background:
    radial-gradient(ellipse at 50% 0%, rgba(70,217,232,.16), transparent 55%),
    radial-gradient(ellipse at 80% 100%, rgba(130,132,255,.1), transparent 50%),
    rgba(9, 10, 16, .55);
  color: #f2f3f8;
  font: inherit;
  font-size: 22px;
  font-weight: 620;
  letter-spacing: .04em;
  cursor: pointer;
  box-shadow:
    0 0 0 1px rgba(126, 240, 251, .2),
    0 0 28px rgba(70, 217, 232, .28),
    0 1px 0 rgba(255, 255, 255, .08) inset;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}
.dh-well:hover {
  border-color: rgba(126, 240, 251, .9);
  box-shadow:
    0 0 0 1px rgba(126, 240, 251, .32),
    0 0 36px rgba(70, 217, 232, .36),
    0 1px 0 rgba(255, 255, 255, .1) inset;
}
.dh-well-hint {
  margin: 12px 0 0;
  text-align: center;
  color: rgba(180, 184, 205, .68);
  font-size: 13px;
}
.dh-type {
  margin-top: 18px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}
.dh-type > span {
  color: rgba(180, 184, 205, .8);
  font-size: 13px;
}
.dh-type[hidden],
.dh-type.is-off { display: none !important; }
.dh-type .setup-pills button {
  color: #fff;
  background: transparent;
  border: 1px solid rgba(126, 240, 251, .55);
}
.dh-type .setup-pills button.is-on {
  background: linear-gradient(145deg, #9af4fb, #46d9e8);
  color: #061016;
  border-color: transparent;
}

@media (max-width: 760px) {
  .dh-well { height: min(340px, 46dvh); min-height: 200px; }
}


.chat-thread .talk-video { display: none; }
