:root {
  color-scheme: dark;
  --audio-bg: #141414;
  --audio-panel: #1a1a1a;
  --audio-card: rgba(255,255,255,.1);
  --audio-card-deep: #2b2b2b;
  --audio-popup: #181818;
  --audio-control-hover: #373737;
  --audio-line: rgba(255,255,255,.12);
  --audio-text: #fff;
  --audio-muted: rgba(255,255,255,.5);
  --audio-faint: rgba(255,255,255,.36);
  --audio-accent: #e64b22;
  --audio-font-sans: "Roboto Flex", "Noto Sans SC", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
  --audio-font-body: "GRAD" -10, "XOPQ" 96, "XTRA" 468, "YOPQ" 79, "YTAS" 750, "YTDE" -203, "YTFI" 738, "YTLC" 514, "YTUC" 712, "wdth" 115;
  --audio-font-body-strong: "GRAD" 120, "XOPQ" 96, "XTRA" 468, "YOPQ" 79, "YTAS" 750, "YTDE" -203, "YTFI" 738, "YTLC" 514, "YTUC" 712, "wdth" 115;
  --audio-font-small: "GRAD" 0, "XOPQ" 96, "XTRA" 468, "YOPQ" 79, "YTAS" 750, "YTDE" -203, "YTFI" 738, "YTLC" 514, "YTUC" 712, "wdth" 110;
  --audio-font-small-strong: "GRAD" 120, "XOPQ" 96, "XTRA" 468, "YOPQ" 79, "YTAS" 750, "YTDE" -203, "YTFI" 738, "YTLC" 514, "YTUC" 712, "wdth" 120;
  --audio-font-h1: "GRAD" 150, "XOPQ" 96, "XTRA" 468, "YOPQ" 79, "YTAS" 750, "YTDE" -203, "YTFI" 738, "YTLC" 514, "YTUC" 712, "wdth" 120;
  --audio-font-h2: "GRAD" 80, "XOPQ" 96, "XTRA" 468, "YOPQ" 79, "YTAS" 750, "YTDE" -203, "YTFI" 738, "YTLC" 514, "YTUC" 712, "wdth" 115;
  font-family: var(--audio-font-sans);
  background: var(--audio-bg);
  color: var(--audio-text);
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; min-height: 100vh; background: var(--audio-bg); }
button, textarea, input { font: inherit; }
button { color: inherit; }

.audio-auth-gate {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--audio-muted);
  font-size: 13px;
}
.audio-auth-gate[hidden] { display: none; }
.audio-auth-gate__mark {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255,255,255,.16);
  border-top-color: var(--audio-accent);
  border-radius: 50%;
  animation: audio-spin .8s linear infinite;
}
.audio-auth-gate.is-error { flex-direction: column; padding: 24px; text-align: center; }
.audio-auth-gate.is-error .audio-auth-gate__mark { display: none; }
.audio-auth-gate button {
  padding: 9px 16px;
  border: 1px solid var(--audio-line);
  border-radius: 999px;
  background: #272827;
  cursor: pointer;
}

.audio-shell {
  min-height: 100vh;
  padding-left: 60px;
  display: grid;
  grid-template-columns: 350px minmax(0, 1fr);
}
.audio-shell[hidden] { display: none; }

.audio-controls {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 20px 12px 18px;
  display: flex;
  flex-direction: column;
  gap: 9px;
  overflow-y: auto;
  border-right: 0;
  box-shadow: inset -1px 0 0 var(--audio-line);
  background: var(--audio-panel);
  scrollbar-width: none;
}
.audio-controls::-webkit-scrollbar { display: none; }

.audio-model-card,
.audio-speaker-card,
.audio-reference-card,
.audio-prompt-card,
.audio-duration-card {
  width: 100%;
  border: 0;
  border-radius: 24px;
  background: var(--audio-card);
}

.audio-model-card {
  min-height: 64px;
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 14px;
  text-align: left;
  cursor: pointer;
  font-size: 14px;
  line-height: 20px;
  transition: color .2s cubic-bezier(.23,1,.32,1), background-color .2s cubic-bezier(.23,1,.32,1), border-color .2s cubic-bezier(.23,1,.32,1);
}
.audio-model-card:hover,
.audio-model-card.is-open { background: var(--audio-control-hover); }
.audio-speaker-card { position: relative; padding: 12px; }
.audio-speaker-heading { display: flex; align-items: center; gap: 8px; padding: 0 2px 9px; }
.audio-speaker-heading > strong { color: #dededb; font-size: 12px; font-weight: 400; font-variation-settings: var(--audio-font-body-strong); }
.audio-speaker-current {
  width: 100%; min-height: 58px; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 10px 11px; border: 1px solid transparent; border-radius: 15px; color: inherit;
  background: rgba(0,0,0,.2); text-align: left; cursor: pointer;
  transition: color .2s cubic-bezier(.23,1,.32,1), background-color .2s cubic-bezier(.23,1,.32,1), border-color .2s cubic-bezier(.23,1,.32,1);
}
.audio-speaker-current:hover, .audio-speaker-current.is-open { background: var(--audio-control-hover); }
.audio-speaker-current:focus-visible {
  outline: 2px solid var(--audio-accent);
  outline-offset: 2px;
}
.audio-speaker-current span { min-width: 0; display: grid; gap: 3px; }
.audio-speaker-current strong { overflow: hidden; color: #f4f4f1; font-size: 13px; font-weight: 400; text-overflow: ellipsis; white-space: nowrap; font-variation-settings: var(--audio-font-body-strong); }
.audio-speaker-current small { overflow: hidden; color: var(--audio-muted); font-size: 9px; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; font-variation-settings: var(--audio-font-small); }
.audio-speaker-current.is-open .audio-chevron { transform: rotate(90deg); }
.audio-speaker-options {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px;
  max-height: none; overflow: visible; padding: 0;
}
.audio-speaker-option {
  width: 100%; min-height: 76px; display: grid; align-content: start; gap: 5px; padding: 10px 11px;
  border: 1px solid var(--audio-line); border-radius: 14px; color: #e8e8e5;
  background: rgba(255,255,255,.035); text-align: left; cursor: pointer;
  transition: color .18s ease, border-color .18s ease, background-color .18s ease, transform .18s ease;
}
.audio-speaker-option:hover { transform: translateY(-1px); background: rgba(255,255,255,.07); }
.audio-speaker-option.is-selected { color: #fff; border-color: rgba(230,75,34,.74); background: rgba(230,75,34,.11); }
.audio-speaker-option > span { display: flex; justify-content: space-between; gap: 8px; }
.audio-speaker-option strong { font-size: 11px; font-weight: 450; font-variation-settings: var(--audio-font-body-strong); }
.audio-speaker-option small { color: var(--audio-muted); font-size: 9px; }
.audio-speaker-option p { margin: 0; color: #aeb0aa; font-size: 9px; line-height: 1.45; }
.audio-speaker-option .audio-speaker-tags { display: none; }
.audio-speaker-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.audio-speaker-tags i { padding: 2px 5px; border-radius: 999px; color: #d8a18d; background: rgba(230,75,34,.12); font-size: 8px; font-style: normal; }
.audio-ui-icon {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.audio-model-icon { opacity: .92; }
.audio-model-card strong { font-size: 14px; font-weight: 400; line-height: 1.4; letter-spacing: .07px; font-variation-settings: var(--audio-font-body-strong); }
.audio-chevron { width: 17px; height: 17px; margin-left: auto; color: #b4b5b1; }
.audio-model-card.is-open .audio-chevron { transform: rotate(90deg); }
.audio-model-picker {
  position: absolute;
  z-index: 30;
  top: 86px;
  right: 12px;
  left: 12px;
  padding: 10px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 14px;
  background: var(--audio-popup);
  box-shadow: 0 18px 55px rgba(0,0,0,.67);
}
.audio-model-picker > span { display: block; padding: 2px 5px 7px; color: #888a84; font-size: 10px; }
.audio-model-picker > div { display: grid; gap: 4px; }
.audio-model-option {
  width: 100%;
  padding: 10px 11px;
  display: grid;
  gap: 3px;
  border: 0;
  border-radius: 10px;
  text-align: left;
  color: #f5f5f2;
  background: transparent;
  cursor: pointer;
  transition: color .2s cubic-bezier(.23,1,.32,1), background-color .2s cubic-bezier(.23,1,.32,1);
}
.audio-model-option:hover, .audio-model-option.is-selected { color: var(--audio-accent); background: var(--audio-control-hover); }
.audio-model-option strong { font-size: 13px; font-weight: 400; line-height: 1.4; letter-spacing: .065px; font-variation-settings: var(--audio-font-body); }
.audio-model-option small { color: #9d9f99; font-size: 10px; }
.audio-model-option.is-selected small { color: #999; }

.audio-performance-backdrop {
  position: fixed;
  z-index: 55;
  inset: 0 0 0 410px;
  background: rgba(0,0,0,.28);
}
.audio-performance-drawer {
  position: fixed;
  z-index: 60;
  top: 0;
  bottom: 0;
  left: 410px;
  width: min(360px, calc(100vw - 410px));
  padding: 18px 16px 0;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #454545 transparent;
  border-right: 1px solid #303030;
  color: var(--audio-text);
  background: #191919;
  box-shadow: 18px 0 48px rgba(0,0,0,.34);
  transform: translateX(-12px);
  opacity: 0;
  visibility: hidden;
  transition: transform .24s cubic-bezier(.2,.8,.2,1), opacity .18s ease, visibility .18s;
}
.audio-performance-drawer.is-open { transform: translateX(0); opacity: 1; visibility: visible; }
body.audio-performance-open .site-version { opacity: 0; visibility: hidden; }
.audio-performance-drawer__header { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; padding: 2px 0 16px; border-bottom: 1px solid #303030; }
.audio-performance-drawer__header > div > span { color: var(--audio-accent); font-size: 9px; font-weight: 650; letter-spacing: .17em; }
.audio-performance-drawer__header h2 { margin: 0 0 5px; font-size: 16px; font-weight: 600; line-height: 1.4; font-variation-settings: normal; }
.audio-performance-drawer__header p { margin: 0; color: #858585; font-size: 12px; line-height: 1.5; }
.audio-performance-drawer__header button {
  width: 36px; height: 36px; display: grid; place-items: center; flex: 0 0 auto;
  border: 1px solid #303030; border-radius: 11px;
  color: #a1a1a1; background: #202020; cursor: pointer;
  transition: color .18s ease, background-color .18s ease, border-color .18s ease;
}
.audio-performance-drawer__header button:hover { color: #fff; border-color: #444; background: #303030; }
.audio-performance-drawer__header button .audio-ui-icon { width: 17px; height: 17px; }
.audio-performance-section { padding: 16px 0; border-bottom: 1px solid #303030; }
.audio-performance-section__title { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.audio-performance-section__title strong { font-size: 13px; font-weight: 500; font-variation-settings: normal; }
.audio-performance-section__title span { color: #707070; font-size: 11px; }
.audio-performance-presets { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.audio-performance-preset {
  min-height: 66px; padding: 11px 12px; display: grid; align-content: center; gap: 4px; border: 1px solid transparent;
  border-radius: 13px; color: #f3f3f3; background: #303030; text-align: left; cursor: pointer;
  transition: color .18s ease, border-color .18s ease, background-color .18s ease, transform .18s ease;
}
.audio-performance-preset:hover { transform: translateY(-1px); background: #383838; }
.audio-performance-preset.is-selected { color: #fff; border-color: rgba(230,75,34,.6); background: #352b28; }
.audio-performance-preset.is-selected strong { color: var(--audio-accent); }
.audio-performance-preset strong { font-size: 13px; font-weight: 500; }
.audio-performance-preset small { color: #a1a1a1; font-size: 11px; line-height: 1.4; }
.audio-performance-field { display: grid; grid-template-columns: 70px minmax(0, 1fr); align-items: start; gap: 10px; margin-top: 11px; }
.audio-performance-field > span { padding-top: 8px; color: #a1a1a1; font-size: 11px; }
.audio-performance-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.audio-performance-chips button {
  min-height: 32px; padding: 6px 11px; border: 1px solid #303030; border-radius: 999px;
  color: #a1a1a1; background: #202020; font-size: 11px; cursor: pointer;
  transition: color .18s ease, border-color .18s ease, background-color .18s ease;
}
.audio-performance-chips button:hover { color: #fff; background: #303030; }
.audio-performance-chips button.is-selected { color: var(--audio-accent); border-color: rgba(230,75,34,.7); background: #28201e; }
.audio-performance-custom,
.audio-context-editor { display: grid; gap: 8px; padding: 18px 0 0; }
.audio-performance-custom > span,
.audio-context-editor > span { font-size: 12px; font-weight: 500; color: #f3f3f3; }
.audio-performance-custom > span small,
.audio-context-editor > span small { color: #707070; font-size: 10px; font-weight: 400; }
.audio-performance-custom textarea,
.audio-context-editor textarea {
  width: 100%; resize: vertical; border: 1px solid #303030; border-radius: 12px; outline: none;
  color: #f3f3f3; background: #202020; font-size: 13px; line-height: 1.55;
}
.audio-performance-custom textarea,
.audio-context-editor textarea { min-height: 82px; padding: 13px; }
.audio-performance-custom textarea:focus,
.audio-context-editor textarea:focus { border-color: rgba(230,75,34,.72); }
.audio-performance-preview {
  display: grid; gap: 8px; margin-top: 16px; padding: 13px;
  border: 1px solid #303030; border-radius: 12px; background: #202020;
}
.audio-performance-preview > span { color: #f3f3f3; font-size: 12px; font-weight: 500; }
.audio-performance-preview > span small { margin-left: 4px; color: #858585; font-size: 10px; font-weight: 400; }
.audio-performance-preview p { margin: 0; color: #a1a1a1; font-size: 12px; line-height: 1.55; }
.audio-model-guidance {
  display: grid;
  gap: 6px;
  margin: 16px 0 0;
  padding: 12px 13px;
  border: 1px solid #303030;
  border-radius: 12px;
  background: #202020;
}
.audio-model-guidance strong { color: #f3f3f3; font-size: 12px; font-weight: 500; }
.audio-model-guidance p { margin: 0; color: #a1a1a1; font-size: 11px; line-height: 1.55; }
.audio-model-guidance[hidden],
[data-audio-advanced-performance][hidden],
.audio-clone-panel[hidden] { display: none !important; }
.audio-clone-help { margin: 0 0 12px; color: #a1a1a1; font-size: 11px; line-height: 1.55; }
.audio-clone-field { display: grid; gap: 7px; margin-top: 10px; }
.audio-clone-field > span { color: #d0d0cd; font-size: 11px; }
.audio-clone-field small { color: #707070; font-weight: 400; }
.audio-clone-field input,
.audio-clone-field select,
.audio-clone-field textarea {
  width: 100%; min-height: 42px; padding: 10px 12px; border: 1px solid #303030; border-radius: 11px;
  outline: none; color: #f3f3f3; background: #202020; font: inherit; font-size: 12px;
}
.audio-clone-field textarea { min-height: 76px; resize: vertical; line-height: 1.55; }
.audio-clone-field input:focus,
.audio-clone-field select:focus,
.audio-clone-field textarea:focus { border-color: rgba(230,75,34,.72); }
.audio-clone-consent { display: flex; align-items: flex-start; gap: 8px; margin-top: 12px; color: #a1a1a1; font-size: 11px; line-height: 1.45; }
.audio-clone-consent input { margin-top: 1px; accent-color: var(--audio-accent); }
.audio-clone-create {
  width: 100%; min-height: 42px; margin-top: 12px; border: 1px solid #fff; border-radius: 999px;
  color: #141414; background: #fff; font-size: 12px; font-weight: 500; cursor: pointer;
}
.audio-clone-create:hover { background: #ededed; }
.audio-clone-create:disabled { color: #777; background: #d7d7d7; cursor: wait; }
.audio-clone-state { min-height: 17px; margin: 8px 2px 0; color: #a1a1a1; font-size: 10px; line-height: 1.5; }
.audio-performance-drawer__footer {
  position: sticky; bottom: 0; display: grid; grid-template-columns: 1fr 1.5fr; gap: 8px;
  margin: 18px -16px 0; padding: 13px 16px calc(16px + env(safe-area-inset-bottom)); border-top: 1px solid #303030;
  background: #191919;
}
.audio-performance-drawer__footer button {
  min-height: 44px; border: 1px solid #303030; border-radius: 999px;
  color: #d0d0cd; background: #303030; font-size: 13px; font-weight: 500; cursor: pointer;
  transition: color .18s ease, background-color .18s ease, border-color .18s ease, transform .18s ease;
}
.audio-performance-drawer__footer button:hover { transform: translateY(-1px); background: #383838; }
.audio-performance-drawer__footer button:last-child { border-color: #fff; color: #141414; background: #fff; }
.audio-performance-drawer__footer button:last-child:hover { border-color: #ededed; background: #ededed; }

.audio-performance-drawer button:focus-visible,
.audio-performance-drawer textarea:focus-visible {
  outline: 2px solid var(--audio-accent);
  outline-offset: 2px;
}

.audio-speaker-options--drawer .audio-speaker-option {
  min-height: 70px;
  padding: 11px 12px;
  border-color: transparent;
  border-radius: 13px;
  background: #303030;
}
.audio-speaker-options--drawer .audio-speaker-option:hover { background: #383838; }
.audio-speaker-options--drawer .audio-speaker-option.is-selected {
  border-color: rgba(230,75,34,.6);
  background: #352b28;
}
.audio-speaker-options--drawer .audio-speaker-option.is-selected strong { color: var(--audio-accent); }
.audio-speaker-options--drawer .audio-speaker-option > span:not(.audio-speaker-tags) {
  display: grid;
  justify-content: stretch;
  gap: 2px;
}
.audio-speaker-options--drawer .audio-speaker-tags { display: none; }
.audio-speaker-options--drawer .audio-speaker-option strong {
  overflow: hidden;
  font-size: 13px;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.audio-speaker-options--drawer .audio-speaker-option small,
.audio-speaker-options--drawer .audio-speaker-option p {
  overflow: hidden;
  font-size: 11px;
  color: #a1a1a1;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.audio-clone-option { position: relative; }
.audio-clone-option .audio-speaker-option { width: 100%; padding-right: 58px; }
.audio-clone-option__remove {
  position: absolute; top: 10px; right: 10px; min-height: 28px; padding: 5px 8px;
  border: 1px solid #444; border-radius: 999px; color: #a1a1a1; background: #252525;
  font-size: 10px; cursor: pointer;
}
.audio-clone-option__remove:hover { color: #fff; border-color: #666; }
.audio-clone-pending {
  min-height: 62px; padding: 11px 12px; display: grid; gap: 4px; border: 1px dashed #444;
  border-radius: 13px; color: #f3f3f3; background: #242424; text-align: left; cursor: pointer;
}
.audio-clone-pending strong { font-size: 13px; font-weight: 500; }
.audio-clone-pending small { color: #a1a1a1; font-size: 11px; }

.audio-reference-card { padding: 10px 12px 14px; }
.audio-segmented {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  border-radius: 16px;
  background: #1a1a1a;
}
.audio-segmented button {
  height: 31px;
  border: 0;
  border-radius: 14px;
  color: #979993;
  background: transparent;
  font-size: 12px;
  font-weight: 420;
  line-height: 1.3;
  letter-spacing: .036px;
  font-variation-settings: var(--audio-font-small);
}
.audio-segmented button.is-active { color: #fff; background: #050505; font-weight: 400; font-variation-settings: var(--audio-font-small-strong); }
.audio-segmented button { cursor: pointer; transition: color .2s cubic-bezier(.23,1,.32,1), background-color .2s cubic-bezier(.23,1,.32,1), border-color .2s cubic-bezier(.23,1,.32,1); }
.audio-segmented button:not(.is-active):hover { color: #d8d9d4; background: #303030; }
.audio-reference-heading { margin: 12px 7px 9px; color: #bcbdb8; font-size: 11px; }

.audio-reference-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.audio-upload-tile,
.audio-reference-item {
  position: relative;
  min-width: 0;
  aspect-ratio: 1;
  border: 1px dashed rgba(255,255,255,.56);
  border-radius: 13px;
  overflow: hidden;
  background: rgba(0,0,0,.05);
}
.audio-upload-tile {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 5px;
  color: #d2d3cf;
  cursor: pointer;
}
.audio-upload-tile:hover { background: rgba(255,255,255,.045); }
.audio-upload-tile input { position: absolute; inline-size: 1px; block-size: 1px; opacity: 0; }
.audio-upload-tile > span { font-size: 21px; font-weight: 300; }
.audio-upload-tile > small { color: #9b9d97; font-size: 9px; }
.audio-upload-tile.is-uploading { opacity: .5; pointer-events: none; }
.audio-upload-tile.is-hidden { display: none; }

.audio-reference-item {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 9px;
  border-style: solid;
  color: #fff;
  background: linear-gradient(145deg, #444744, #242625);
}
.audio-reference-item strong,
.audio-reference-item small {
  display: -webkit-box;
  min-width: 0;
  overflow: hidden;
  -webkit-box-orient: vertical;
  word-break: break-word;
}
.audio-reference-item strong {
  -webkit-line-clamp: 1;
  font-size: 10px;
  font-weight: 400;
  font-variation-settings: var(--audio-font-small-strong);
}
.audio-reference-item small {
  -webkit-line-clamp: 2;
  margin-top: 3px;
  color: #a9aaa5;
  font-size: 8px;
  line-height: 1.35;
}
.audio-reference-actions {
  position: absolute;
  inset: 6px 6px auto 6px;
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr) 20px;
  align-items: center;
  gap: 4px;
}
.audio-reference-actions button {
  width: 100%;
  height: 24px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 50%;
  background: rgba(0,0,0,.55);
  font-size: 10px;
  cursor: pointer;
}
.audio-reference-actions button { min-width: 0; }
.audio-reference-actions button:hover,
.audio-reference-actions button:focus-visible {
  color: #fff;
  border-color: rgba(239,80,45,.72);
  background: rgba(239,80,45,.88);
  outline: none;
}
.audio-reference-insert {
  width: 100% !important;
  min-width: 0;
  padding: 0 3px;
  border-radius: 999px !important;
  color: #e8e9e4;
  font-size: 9px !important;
}
.audio-reference-actions button:last-child { margin-left: 0; }
.audio-reference-help {
  margin: 11px 7px 0;
  color: #8c8e88;
  font-size: 10px;
  line-height: 1.55;
}
.audio-reference-notice {
  margin: 12px 7px 2px;
  padding: 11px 12px;
  border: 1px solid rgba(239,80,45,.28);
  border-radius: 12px;
  color: #d5a093;
  background: rgba(239,80,45,.06);
  font-size: 11px;
  line-height: 1.55;
}

.audio-prompt-card {
  position: relative;
  min-height: 268px;
  padding: 0;
  overflow: hidden;
}
.audio-prompt-editor {
  position: relative;
  display: block;
  width: 100%;
  height: 268px;
  overflow: hidden;
}
.audio-prompt-highlight,
.audio-prompt-editor textarea {
  position: absolute;
  inset: 0;
  box-sizing: border-box;
  width: 100%;
  height: 100%;
  padding: 42px 20px 38px;
  font-size: 14px;
  line-height: 1.7;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.audio-prompt-highlight {
  z-index: 0;
  overflow: auto;
  color: #fff;
  pointer-events: none;
  scrollbar-width: none;
}
.audio-prompt-highlight::-webkit-scrollbar { display: none; }
.audio-reference-mention {
  padding: 1px 4px;
  border-radius: 5px;
  color: #ff6a45;
  background: rgba(239,80,45,.18);
  box-shadow: inset 0 0 0 1px rgba(239,80,45,.35);
}
.audio-prompt-label {
  position: absolute;
  z-index: 1;
  top: 15px;
  left: 20px;
  color: var(--audio-accent);
  font-size: 9px;
  font-variation-settings: var(--audio-font-small-strong);
  letter-spacing: .1em;
}
.audio-prompt-card textarea {
  z-index: 1;
  resize: none;
  border: 0;
  outline: 0;
  color: transparent;
  caret-color: #fff;
  background: transparent;
}
.audio-prompt-card textarea::placeholder { color: #a7a9a2; }
.audio-char-count {
  position: absolute;
  right: 17px;
  bottom: 14px;
  color: #7e807a;
  font-size: 10px;
}

.audio-duration-card {
  min-height: 58px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 20px;
}
.audio-duration-card strong { font-size: 14px; font-weight: 400; line-height: 1.4; letter-spacing: .07px; font-variation-settings: var(--audio-font-body); }
.audio-duration-card > span:last-child { margin-left: auto; color: #8f918b; font-size: 10px; }
.audio-clock { width: 18px; height: 18px; }

.audio-generate-actions {
  display: block;
}
.audio-generate {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  width: 100%;
  min-height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border: 0;
  border-radius: 999px;
  color: #141414;
  background: #fff;
  font-size: 16px;
  font-weight: 400;
  line-height: 24px;
  letter-spacing: .07px;
  font-variation-settings: var(--audio-font-body);
  cursor: pointer;
  transition: color .2s cubic-bezier(.23,1,.32,1), background-color .2s cubic-bezier(.23,1,.32,1), transform .2s cubic-bezier(.23,1,.32,1), opacity .2s ease;
}
.audio-generate > * {
  position: relative;
  z-index: 2;
}
.audio-generate::before {
  content: "";
  position: absolute;
  z-index: 1;
  inset: -45% -30%;
  pointer-events: none;
  opacity: 0;
  background:
    linear-gradient(
      112deg,
      transparent 22%,
      rgba(230, 56, 0, .28) 38%,
      rgba(255, 119, 0, .34) 46%,
      rgba(255, 218, 56, .25) 52%,
      rgba(33, 65, 235, .24) 61%,
      transparent 78%
    );
  transform: translateX(-70%) skewX(-12deg);
}
.audio-generate:not(:disabled):hover::before,
.audio-generate.is-loading::before {
  animation: audio-generate-sweep 2.5s cubic-bezier(0, 0, .16, .98) forwards;
}
.audio-generate:not(:disabled):hover { transform: translateY(-1px); }
.audio-generate:not(:disabled):active { transform: scale(.98); }
.audio-generate:disabled { color: #7b7b78; background: #fff; cursor: not-allowed; }
.audio-generate.is-loading > .audio-ui-icon:first-child { animation: audio-spin 1s linear infinite; }
@keyframes audio-generate-sweep {
  0% { opacity: 0; transform: translateX(-70%) skewX(-12deg); }
  12% { opacity: 1; }
  82% { opacity: 1; }
  100% { opacity: 0; transform: translateX(70%) skewX(-12deg); }
}
@media (prefers-reduced-motion: reduce) {
  .audio-generate,
  .audio-generate::before,
  .audio-task-card__orbit { animation: none !important; transition: none !important; }
}
.audio-provider-state {
  min-height: 16px;
  margin: 0 8px;
  color: #868882;
  font-size: 9px;
  line-height: 1.5;
  text-align: center;
}
.audio-provider-state.is-ready { color: #86bf98; }
.audio-provider-state.is-error { color: #e9917b; }

.audio-workspace {
  min-width: 0;
  padding: 34px clamp(24px, 4vw, 64px) 60px;
  /* 与图片、视频结果画布一致：保持纯黑，媒体和结果卡片才是视觉焦点。 */
  background: #0b0b0b;
}
.audio-task-section { min-height: calc(100vh - 94px); }
.audio-task-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }

.audio-empty-state {
  grid-column: 1 / -1;
  min-height: min(520px, calc(100vh - 180px));
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  padding: 24px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #d7d7d3;
  text-align: center;
}
.audio-empty-state__icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  margin-bottom: 4px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 12px;
  color: #aaa;
  background: #191919;
}
.audio-empty-state__icon .audio-ui-icon { width: 19px; height: 19px; }
.audio-empty-state strong { font-size: 13px; font-weight: 500; }
.audio-empty-state p { max-width: 280px; margin: 0; color: var(--audio-faint); font-size: 11px; line-height: 1.6; }

.audio-task-card {
  min-height: 180px;
  padding: 18px;
  display: grid;
  gap: 12px;
  border: 1px solid var(--audio-line);
  border-radius: 20px;
  background: var(--audio-panel);
}
.audio-task-card.is-processing {
  grid-column: 1 / -1;
  min-height: min(360px, calc(100vh - 180px));
  place-content: center;
  justify-items: center;
  align-content: center;
  gap: 9px;
  background: #101010;
  text-align: center;
}
.audio-task-card.is-processing > strong { font-size: 15px; font-weight: 560; }
.audio-task-card__orbit {
  width: 52px;
  height: 52px;
  position: relative;
  display: block;
  margin-bottom: 3px;
  border: 1px solid rgba(255,255,255,.24);
  border-radius: 50%;
  animation: audio-task-orbit 3.8s linear infinite;
}
.audio-task-card__orbit::before,
.audio-task-card__orbit::after {
  content: "";
  position: absolute;
  border-radius: 50%;
}
.audio-task-card__orbit::before {
  inset: 11px;
  border: 1px solid rgba(255,255,255,.13);
}
.audio-task-card__orbit::after {
  width: 7px;
  height: 7px;
  top: 3px;
  left: 9px;
  background: var(--audio-accent);
  box-shadow: 0 0 12px rgba(230,75,34,.5);
}
.audio-task-card__processing-copy { color: var(--audio-faint); font-size: 11px; }
.audio-task-card__progress {
  width: min(260px, 56vw);
  height: 3px;
  display: block;
  overflow: hidden;
  margin-top: 4px;
  border-radius: 999px;
  background: rgba(255,255,255,.12);
}
.audio-task-card__progress i {
  height: 100%;
  display: block;
  border-radius: inherit;
  background: var(--audio-accent);
  transition: width .35s ease;
}
.audio-task-card__head { display: flex; justify-content: space-between; gap: 12px; }
.audio-task-card__head strong { font-size: 13px; }
.audio-task-card__head span { color: var(--audio-faint); font-size: 9px; }
.audio-task-card__prompt { margin: 0; color: #989a94; font-size: 10px; line-height: 1.65; }
.audio-task-card audio { width: 100%; height: 34px; }
.audio-task-card__status { display: flex; align-items: center; gap: 8px; color: #aaa; font-size: 10px; }
.audio-task-card__status i {
  width: 12px;
  height: 12px;
  border: 2px solid rgba(255,255,255,.18);
  border-top-color: var(--audio-accent);
  border-radius: 50%;
  animation: audio-spin .8s linear infinite;
}
.audio-task-card__status.is-failed { color: #e9917b; }
.audio-task-card__actions { display: flex; justify-content: flex-end; gap: 7px; }
.audio-task-card__actions a,
.audio-task-card__actions button {
  padding: 7px 10px;
  border: 1px solid var(--audio-line);
  border-radius: 999px;
  color: #ccc;
  background: rgba(255,255,255,.04);
  text-decoration: none;
  font-size: 9px;
  cursor: pointer;
}

.audio-toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 80;
  max-width: 360px;
  padding: 12px 15px;
  border: 1px solid rgba(239,80,45,.35);
  border-radius: 13px;
  color: #f4d4cb;
  background: rgba(53,22,16,.96);
  box-shadow: 0 15px 45px rgba(0,0,0,.35);
  font-size: 11px;
}

@keyframes audio-spin { to { transform: rotate(360deg); } }
@keyframes audio-task-orbit { to { transform: rotate(360deg); } }

@media (max-width: 980px) {
  .audio-shell { grid-template-columns: 330px minmax(0, 1fr); }
  .audio-performance-backdrop { left: 390px; }
  .audio-performance-drawer { left: 390px; width: min(350px, calc(100vw - 390px)); }
  .audio-task-grid { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .audio-shell { padding: 0 0 58px; display: block; }
  .audio-controls { position: relative; width: auto; height: auto; min-height: 0; padding: 14px; border-right: 0; }
  .audio-model-picker { top: 80px; right: 14px; left: 14px; }
  .audio-prompt-card, .audio-prompt-editor, .audio-prompt-card textarea { min-height: 210px; height: 210px; }
  .audio-performance-backdrop { inset: 0; }
  .audio-performance-drawer { top: auto; right: 0; bottom: 0; left: 0; width: 100%; max-height: 88vh; padding: 18px 14px 0; border-radius: 24px 24px 0 0; transform: translateY(28px); }
  .audio-performance-drawer.is-open { transform: translateY(0); }
  .audio-performance-presets { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .audio-performance-drawer__footer { margin-right: -14px; margin-left: -14px; padding-right: 14px; padding-left: 14px; }
  .audio-workspace { padding: 24px 14px 42px; }
}

@media (prefers-reduced-motion: reduce) {
  .audio-performance-drawer,
  .audio-performance-drawer button,
  .audio-performance-preset,
  .audio-speaker-option {
    transition-duration: .01ms !important;
  }
  .audio-performance-preset:hover,
  .audio-speaker-option:hover,
  .audio-performance-drawer__footer button:hover {
    transform: none;
  }
}
