/* ai777 — «Студия» (studiochat.js): режим основной области приложения чата — рядом тот же сайдбар.
   Основа — классы чата из style.css (.main, .bar, .scroll, .thread, .msg, .composer, .chip, .send, .thumbs, .hero, .starters, .mc*). */
.app > .main[hidden] { display: none; }
.st-view .bar .ttl { color: var(--text); }
.st-view .bar .ttl small { font: 11px var(--mono); margin-left: 6px; }
.st-view .bar .acts { margin-left: auto; }
/* активный пункт сайдбара — «Студия», подсветка текущего чата гаснет */
.app.studio-on .side .chat.on { background: none; box-shadow: none; color: var(--text-2); }
.app .side .studio-link.on { background: var(--accent-soft); border-color: color-mix(in oklch, var(--accent) 50%, transparent); color: var(--accent-text); }

/* ── лента ── */
.msg.user .tag.st-tag { color: var(--text-3); }
.msg.user .st-noimg { font: 11px var(--mono); color: var(--text-3); margin-bottom: 6px; display: inline-flex; gap: 5px; align-items: center; }
.msg.user .st-noimg svg { width: 12px; height: 12px; }
.st-view .msg.ai .body { min-width: 0; }
.st-meta { font: 11px var(--mono); color: var(--text-3); margin-top: 8px; display: flex; gap: 6px; flex-wrap: wrap; }
.st-cmp { margin-top: 8px; max-width: 560px; }
.st-cmp summary { cursor: pointer; font-size: 12.5px; color: var(--text-3); list-style: none; display: inline-flex; gap: 6px; align-items: center; }
.st-cmp summary::-webkit-details-marker { display: none; }
.st-cmp summary:hover { color: var(--text); }
.st-cmp summary svg { width: 14px; height: 14px; }
.st-ba { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
.st-ba figure { margin: 0; display: grid; gap: 4px; min-width: 0; }
.st-ba img { width: 100%; aspect-ratio: 1; object-fit: contain; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); display: block; }
.st-ba figcaption { font: 500 10.5px var(--mono); text-transform: uppercase; letter-spacing: .06em; color: var(--text-3); text-align: center; }
.st-more { text-align: center; font: 11.5px var(--mono); color: var(--text-3); padding: 0 0 22px; }

/* ── пустое состояние ── */
.hero .st-sub { max-width: 560px; margin: 0 auto; }
.starters.st-starters button { max-width: 100%; }
.starters.st-starters button span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ── композер ── */
.st-view .composer .tools .chip.on { background: var(--accent-soft); border-color: color-mix(in oklch, var(--accent) 50%, transparent); color: var(--accent-text); }
.st-view .composer .tools .chip svg { width: 15px; height: 15px; }
.st-modes { display: inline-flex; gap: 4px; flex-wrap: wrap; }
.st-sel { appearance: none; -webkit-appearance: none; height: 32px; padding: 0 26px 0 11px; border-radius: 99px; border: 1px solid var(--line); cursor: pointer; font-size: 13px; color: var(--text-2);
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238a8c82' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 9px center / 12px;
  max-width: 210px; outline: none; }
.st-sel:hover { background-color: var(--surface-2); color: var(--text); }
.st-sel:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.st-sel option { background: var(--surface); color: var(--text); }
/* песня: необязательный свой текст — под основным полем, помельче */
.st-view .composer textarea.st-lyrics { font-size: 13.5px; line-height: 1.5; padding: 8px 20px 6px; margin: 0 0 2px; border-top: 1px dashed var(--line); max-height: 220px; }
.st-view .foot-note { display: flex; gap: 7px; justify-content: center; align-items: center; flex-wrap: wrap; }
.st-view .foot-note .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--live); flex: none; }
.st-view .foot-note.off { color: var(--warn); } .st-view .foot-note.off .dot { background: var(--warn); }

@media (max-width: 860px) {
  .st-view .thread { padding: 8px 16px 24px; }
  .st-view .composer-wrap { padding: 0 10px 10px; }
  .st-view .hero { padding: 0 16px 18px; } .st-view .starters { padding: 0 16px; }
  .st-view .bar .ttl small { display: none; }
}
@media (max-width: 480px) {
  .st-view .composer .tools .st-modes .chip { padding: 0 9px; gap: 5px; }
  .st-view .composer .tools .st-modes .chip:not(.on) span { display: none; }   /* узко: неактивные режимы — только иконки (подпись в title) */
  .st-sel { max-width: 150px; }
  .st-view .msg.user .imgs img { width: 96px; height: 96px; }
}
