:root {
  color-scheme: dark;

  --background: #10111a;
  --surface: rgba(28, 31, 47, 0.86);
  --surface-soft: rgba(255, 255, 255, 0.045);
  --surface-hover: rgba(255, 255, 255, 0.08);

  --text: #f7f8ff;
  --text-soft: #b8bdd1;
  --text-muted: #858ba4;

  --accent: #8d7cff;
  --accent-strong: #705eff;
  --accent-soft: rgba(141, 124, 255, 0.18);

  --border: rgba(255, 255, 255, 0.1);
  --danger: #ff7084;
  --success: #4bd7a6;
  --warning: #f6bf5e;

  --radius-large: 24px;
  --radius-medium: 16px;
  --radius-small: 12px;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.3);

  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-width: 320px;
  min-height: 100%;
  margin: 0;
  background: var(--background);
}

body {
  color: var(--text);
}

button,
input,
textarea,
select {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

audio {
  width: min(100%, 560px);
  height: 38px;
  margin-top: 12px;
}

textarea {
  min-height: 150px;
  resize: vertical;
}

.hidden {
  display: none !important;
}

.app-background {
  position: fixed;
  z-index: -1;
  inset: 0;
  background:
    radial-gradient(
      circle at 10% 15%,
      rgba(125, 101, 255, 0.2),
      transparent 28rem
    ),
    radial-gradient(
      circle at 90% 80%,
      rgba(65, 190, 204, 0.1),
      transparent 28rem
    ),
    linear-gradient(145deg, #10121d, #171329 45%, #0f1620);
}

.screen {
  min-height: 100vh;
}

.center-screen,
.login-screen {
  display: grid;
  place-items: center;
  padding: 24px;
}

.center-screen {
  text-align: center;
}

.brand-mark {
  display: grid;
  width: 62px;
  height: 62px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 21px;
  color: white;
  font-size: 2rem;
  background: linear-gradient(145deg, #a391ff, #6250e9);
  box-shadow: 0 16px 38px rgba(103, 85, 255, 0.35);
}

.brand-mark.small {
  width: 34px;
  height: 34px;
  border-radius: 11px;
  font-size: 1rem;
}

.login-card {
  width: min(100%, 430px);
  padding: 38px;
  border: 1px solid var(--border);
  border-radius: var(--radius-large);
  background: rgba(25, 28, 42, 0.88);
  box-shadow: var(--shadow);
  backdrop-filter: blur(24px);
}

.login-card .brand-mark {
  margin-bottom: 24px;
}

.login-card h1 {
  margin: 0 0 10px;
  font-size: 2rem;
  letter-spacing: -0.05em;
}

.muted {
  color: var(--text-soft);
}

.form-stack {
  display: grid;
  gap: 18px;
}

.login-card .form-stack {
  margin-top: 30px;
}

.field {
  display: grid;
  gap: 8px;
  color: var(--text-soft);
  font-size: 0.93rem;
}

.field small {
  color: var(--text-muted);
  line-height: 1.45;
}

.field input,
.field textarea,
.field select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-small);
  outline: none;
  color: var(--text);
  background: rgba(8, 10, 17, 0.45);
}

.field input[type="range"] {
  padding: 0;
  accent-color: var(--accent);
}

.field input:focus,
.field textarea:focus,
.field select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}

.field-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.text-help-button {
  padding: 4px 9px;
  border: 1px solid rgba(141, 124, 255, 0.35);
  border-radius: 8px;
  color: #cec7ff;
  background: rgba(141, 124, 255, 0.1);
  font-size: 0.8rem;
}

.text-help-button:hover {
  background: rgba(141, 124, 255, 0.2);
}

.experimental-badge {
  display: inline-flex;
  margin-left: 5px;
  padding: 2px 6px;
  border-radius: 999px;
  color: #ffe3a5;
  background: rgba(246, 191, 94, 0.14);
  font-size: 0.72rem;
  font-weight: 700;
}

.second-part-details {
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-small);
  background: rgba(255, 255, 255, 0.025);
}

.second-part-details summary {
  cursor: pointer;
  color: #c7c0ff;
  font-weight: 650;
}

.second-part-details .field {
  margin-top: 15px;
}

.helper {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.87rem;
  line-height: 1.55;
}

.button {
  display: inline-flex;
  min-height: 43px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 16px;
  border: 1px solid transparent;
  border-radius: var(--radius-small);
  color: var(--text);
  font-weight: 650;
  text-decoration: none;
  transition: 150ms ease;
}

.button:hover:not(:disabled) {
  transform: translateY(-1px);
}

.button-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  box-shadow: 0 10px 24px rgba(107, 88, 255, 0.23);
}

.button-secondary {
  border-color: var(--border);
  background: rgba(255, 255, 255, 0.06);
}

.button-secondary:hover:not(:disabled),
.button-ghost:hover:not(:disabled) {
  background: var(--surface-hover);
}

.button-danger {
  border-color: rgba(255, 112, 132, 0.25);
  color: #ffd8df;
  background: rgba(255, 112, 132, 0.09);
}

.button-ghost {
  color: var(--text-soft);
  background: transparent;
}

.button-small {
  min-height: 35px;
  padding: 0 11px;
  font-size: 0.84rem;
}

.form-error {
  margin: 0;
  color: var(--danger);
}

.topbar {
  display: flex;
  min-height: 66px;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  border-bottom: 1px solid var(--border);
  background: rgba(17, 19, 30, 0.73);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-size: 1.05rem;
  font-weight: 750;
  letter-spacing: -0.025em;
}

.brand-button {
  padding: 0;
  border: 0;
  background: transparent;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.application-layout {
  display: grid;
  min-height: calc(100vh - 66px);
  grid-template-columns: 235px minmax(0, 1fr);
}

.sidebar {
  display: grid;
  align-content: start;
  gap: 6px;
  padding: 22px 14px;
  border-right: 1px solid var(--border);
  background: rgba(15, 17, 28, 0.45);
}

.nav-item {
  display: flex;
  min-height: 45px;
  align-items: center;
  gap: 12px;
  padding: 0 13px;
  border: 1px solid transparent;
  border-radius: 12px;
  color: var(--text-soft);
  background: transparent;
  text-align: left;
}

.nav-item:hover {
  background: var(--surface-soft);
  color: var(--text);
}

.nav-item.active {
  border-color: rgba(143, 126, 255, 0.25);
  color: white;
  background: var(--accent-soft);
}

.content-area {
  width: min(100%, 1320px);
  margin: 0 auto;
  padding: 44px;
}

.page {
  display: none;
}

.page.active {
  display: block;
}

.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 30px;
}

.eyebrow {
  margin: 0 0 8px;
  color: #a99eff;
  font-size: 0.78rem;
  font-weight: 750;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  margin: 0;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  letter-spacing: -0.055em;
}

h2 {
  margin: 0;
  font-size: 1.45rem;
  letter-spacing: -0.04em;
}

h3 {
  margin: 0;
}

.page-description {
  max-width: 760px;
  margin: 12px 0 0;
  color: var(--text-soft);
  line-height: 1.6;
}

.statistics-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin: 28px 0;
}

.stat-card {
  display: grid;
  gap: 7px;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius-medium);
  background: var(--surface);
}

.stat-card span,
.stat-card small {
  color: var(--text-muted);
}

.stat-card strong {
  font-size: 1.45rem;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.dashboard-card {
  display: flex;
  min-height: 245px;
  flex-direction: column;
  align-items: flex-start;
  padding: 25px;
  border: 1px solid var(--border);
  border-radius: var(--radius-medium);
  background: var(--surface);
}

.dashboard-card.featured {
  border-color: rgba(145, 127, 255, 0.3);
  background: linear-gradient(
    145deg,
    rgba(126, 104, 255, 0.2),
    rgba(27, 29, 45, 0.88)
  );
}

.card-icon,
.item-card-icon {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 13px;
  color: #ded9ff;
  font-size: 1.3rem;
  background: rgba(151, 136, 255, 0.16);
}

.dashboard-card h3 {
  margin: 20px 0 9px;
}

.dashboard-card p {
  flex: 1;
  margin: 0 0 22px;
  color: var(--text-soft);
  line-height: 1.55;
}

.cards-list {
  display: grid;
  gap: 14px;
}

.item-card {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 22px;
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius-medium);
  background: var(--surface);
}

.item-card-main {
  display: flex;
  min-width: 0;
  flex: 1;
  gap: 15px;
}

.item-card-content {
  min-width: 0;
  flex: 1;
}

.item-card-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.item-card-title-row h3 {
  font-size: 1.08rem;
}

.meta {
  margin: 7px 0 0;
  color: var(--text-muted);
  font-size: 0.88rem;
}

.text-preview,
.transcript-preview {
  max-width: 850px;
  margin: 13px 0 0;
  color: var(--text-soft);
  line-height: 1.55;
  white-space: normal;
}

.transcript-preview {
  padding: 10px 12px;
  border-left: 2px solid rgba(141, 124, 255, 0.55);
  background: rgba(255, 255, 255, 0.035);
}

.compact-text {
  white-space: normal;
}

.line-clamp-3 {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.part-count {
  margin: 9px 0 0;
  color: #b9b0ff;
  font-size: 0.84rem;
}

.audio-details,
.cost-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 15px;
  margin-top: 13px;
  color: var(--text-muted);
  font-size: 0.86rem;
}

.item-card-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.status {
  display: inline-flex;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 0.73rem;
  font-weight: 750;
  white-space: nowrap;
}

.status-ready {
  color: #caffec;
  background: rgba(75, 215, 166, 0.14);
}

.status-processing,
.status-queued {
  color: #ffe4ab;
  background: rgba(246, 191, 94, 0.14);
}

.status-error {
  color: #ffd5dc;
  background: rgba(255, 112, 132, 0.14);
}

.mix-status {
  font-weight: 650;
}

.mix-status-none {
  color: var(--text-muted);
}

.mix-status-working {
  color: #ffe4a7;
}

.mix-status-ready {
  color: #aef4d8;
}

.mix-status-error {
  color: #ffb0bc;
}

.empty-state {
  padding: 62px 25px;
  border: 1px dashed rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-medium);
  color: var(--text-soft);
  text-align: center;
}

.empty-state h3 {
  margin: 15px 0 8px;
  color: var(--text);
}

.empty-state p {
  max-width: 480px;
  margin: 0 auto;
  line-height: 1.55;
}

.empty-icon {
  color: #b5abff;
  font-size: 2rem;
}

.back-link {
  display: inline-flex;
  margin: 0 0 18px;
  padding: 0;
  border: 0;
  color: #b8b0ff;
  background: transparent;
  font-size: 0.92rem;
}

.back-link:hover {
  color: #fff;
}

.detail-card {
  padding: 26px;
  border: 1px solid var(--border);
  border-radius: var(--radius-large);
  background: var(--surface);
}

.detail-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.detail-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.detail-player {
  width: 100%;
  height: 48px;
  margin-top: 26px;
}

.detail-info-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 24px;
}

.detail-info-grid > div {
  display: grid;
  gap: 6px;
  min-height: 82px;
  padding: 15px;
  border: 1px solid var(--border);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.035);
}

.detail-info-grid span {
  color: var(--text-muted);
  font-size: 0.82rem;
}

.detail-info-grid strong {
  line-height: 1.35;
}

.detail-section {
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.detail-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  margin-bottom: 12px;
}

.full-text {
  padding: 16px;
  border-radius: 13px;
  color: var(--text-soft);
  background: rgba(0, 0, 0, 0.18);
  line-height: 1.68;
  white-space: pre-wrap;
}

.detail-generation-id {
  display: grid;
  gap: 7px;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.detail-generation-id code {
  overflow-wrap: anywhere;
  color: #c7c1ff;
  white-space: pre-wrap;
}

.detail-message {
  margin-top: 26px;
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 22px;
  color: var(--text-soft);
  font-size: 0.9rem;
}

.modal {
  width: min(100% - 32px, 700px);
  max-height: min(90dvh, 850px);
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius-large);
  color: var(--text);
  background: #1c1f2f;
  box-shadow: var(--shadow);
}

.modal::backdrop {
  background: rgba(4, 5, 10, 0.66);
  backdrop-filter: blur(4px);
}

.help-modal {
  width: min(100% - 32px, 760px);
  max-height: min(90dvh, 850px);
  overflow: hidden;
}

.modal-content {
  max-height: min(90dvh, 850px);
  padding: 24px;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 23px;
}

.icon-button {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 0;
  border-radius: 10px;
  color: var(--text-soft);
  font-size: 1.7rem;
  background: transparent;
}

.icon-button:hover {
  color: var(--text);
  background: var(--surface-hover);
}

.modal-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
}

.confirmation-content {
  display: grid;
  gap: 14px;
}

.confirmation-content p {
  margin: 0;
  color: var(--text-soft);
  line-height: 1.6;
}

.help-content {
  display: grid;
  gap: 22px;
  color: var(--text-soft);
  line-height: 1.65;
}

.help-content section {
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.help-content section:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.help-content h3 {
  margin-bottom: 10px;
  color: var(--text);
}

.help-content p {
  margin: 0;
}

.help-content ul {
  display: grid;
  gap: 7px;
  margin: 0;
  padding-left: 20px;
}

.help-content code {
  padding: 2px 5px;
  border-radius: 5px;
  color: #d7d1ff;
  background: rgba(141, 124, 255, 0.12);
}

.help-content pre {
  overflow-x: auto;
  margin: 12px 0 0;
  padding: 14px;
  border-radius: 12px;
  color: #dcd8ff;
  background: rgba(0, 0, 0, 0.25);
  font: 0.88rem/1.55 ui-monospace, SFMono-Regular, Menlo, monospace;
  white-space: pre-wrap;
}

.toast-container {
  position: fixed;
  z-index: 30;
  right: 20px;
  bottom: 20px;
  display: grid;
  width: min(390px, calc(100% - 40px));
  gap: 10px;
}

.toast {
  padding: 14px 16px;
  border: 1px solid rgba(75, 215, 166, 0.3);
  border-radius: 13px;
  color: #ddfff3;
  background: rgba(25, 59, 53, 0.95);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.28);
}

.toast-error {
  border-color: rgba(255, 112, 132, 0.33);
  color: #ffe0e5;
  background: rgba(86, 33, 44, 0.95);
}

@media (max-width: 1050px) {
  .statistics-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .application-layout {
    grid-template-columns: 1fr;
  }

  .sidebar {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    padding: 9px;
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .nav-item {
    justify-content: center;
    padding: 0 8px;
  }

  .nav-item span:last-child {
    display: none;
  }

  .content-area {
    padding: 30px 20px;
  }
}

@media (max-width: 820px) {
  .detail-heading {
    flex-direction: column;
  }

  .detail-actions {
    justify-content: flex-start;
  }

  .detail-info-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .topbar {
    padding: 0 15px;
  }

  .topbar-actions .muted {
    display: none;
  }

  .page-header,
  .item-card {
    flex-direction: column;
  }

  .page-header > .button {
    width: 100%;
  }

  .item-card-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .statistics-grid {
    grid-template-columns: 1fr 1fr;
  }

  .content-area {
    padding: 24px 15px;
  }

  .login-card {
    padding: 28px 22px;
  }
}

@media (max-width: 560px) {
  .detail-card {
    padding: 18px;
  }

  .detail-info-grid {
    grid-template-columns: 1fr;
  }

  .detail-section-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .pagination {
    flex-wrap: wrap;
  }

  .field-label-row {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* -------------------------------------------------------------------------- */
/*                            Голоса и рекомендации                           */
/* -------------------------------------------------------------------------- */

.voice-tip {
  display: flex;
  gap: 14px;
  margin-bottom: 18px;
  padding: 16px 18px;
  border: 1px solid rgba(141, 124, 255, 0.25);
  border-radius: var(--radius-medium);
  background: rgba(141, 124, 255, 0.09);
}

.voice-tip-icon {
  color: #c1b9ff;
  font-size: 1.35rem;
}

.voice-tip strong {
  color: var(--text);
}

.voice-tip p {
  margin: 6px 0 0;
  color: var(--text-soft);
  line-height: 1.55;
}

/* -------------------------------------------------------------------------- */
/*                      Вторая текстовая часть и пресеты                      */
/* -------------------------------------------------------------------------- */

.compact-field {
  gap: 6px;
  margin-top: 2px;
}

.text-tools {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.text-help-danger {
  border-color: rgba(255, 112, 132, 0.32);
  color: #ffcbd4;
  background: rgba(255, 112, 132, 0.1);
}

.second-part-container {
  display: grid;
  gap: 10px;
  padding: 15px;
  border: 1px solid rgba(141, 124, 255, 0.22);
  border-radius: var(--radius-small);
  background: rgba(141, 124, 255, 0.06);
}

/* -------------------------------------------------------------------------- */
/*                     Расшифровка голоса только для чтения                  */
/* -------------------------------------------------------------------------- */

.readonly-transcript {
  min-height: 110px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-small);
  color: var(--text-soft);
  background: rgba(0, 0, 0, 0.18);
  line-height: 1.55;
  white-space: pre-wrap;
}

/* -------------------------------------------------------------------------- */
/*                            Модальное подтверждение                         */
/* -------------------------------------------------------------------------- */

.confirm-modal {
  width: min(100% - 32px, 520px);
  max-height: min(90dvh, 520px);
  overflow: hidden;
}

/* -------------------------------------------------------------------------- */
/*                                 Адаптация                                  */
/* -------------------------------------------------------------------------- */

@media (max-width: 560px) {
  .voice-tip {
    align-items: flex-start;
  }

  .text-tools {
    width: 100%;
    justify-content: flex-start;
  }
}

/*
  Поле режиссёрской подачи должно быть компактным:
  примерно три строки, независимо от общего textarea-правила.
*/
#delivery-instructions {
  min-height: 82px;
}

/* -------------------------------------------------------------------------- */
/*                  Оценка стоимости будущей генерации                        */
/* -------------------------------------------------------------------------- */

.price-estimate {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-top: 2px;
  padding: 11px 13px;
  border: 1px solid rgba(141, 124, 255, 0.2);
  border-radius: 10px;
  color: var(--text-soft);
  background: rgba(141, 124, 255, 0.07);
  font-size: 0.88rem;
  line-height: 1.45;
}

.price-estimate strong {
  color: #dfdbff;
}

/* -------------------------------------------------------------------------- */
/*                         Запись голоса с микрофона                          */
/* -------------------------------------------------------------------------- */

.voice-source-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 22px;
  padding: 5px;
  border: 1px solid var(--border);
  border-radius: 13px;
  background: rgba(0, 0, 0, 0.14);
}

.voice-source-tab {
  min-height: 38px;
  flex: 1;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: 9px;
  color: var(--text-soft);
  background: transparent;
  font-size: 0.88rem;
  font-weight: 650;
}

.voice-source-tab:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
}

.voice-source-tab.active {
  border-color: rgba(141, 124, 255, 0.25);
  color: #fff;
  background: rgba(141, 124, 255, 0.17);
}

.voice-source-panel {
  min-width: 0;
}

.recording-card {
  display: grid;
  gap: 16px;
  padding: 18px;
  border: 1px solid rgba(141, 124, 255, 0.24);
  border-radius: var(--radius-medium);
  background:
    radial-gradient(
      circle at 95% 0%,
      rgba(141, 124, 255, 0.14),
      transparent 13rem
    ),
    rgba(255, 255, 255, 0.025);
}

.recording-status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.recording-status-row > div {
  display: grid;
  gap: 5px;
}

.recording-status {
  color: var(--text-soft);
  font-size: 0.86rem;
}

.recording-timer {
  color: #f1efff;
  font-size: 1.8rem;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
}

.recording-indicator {
  color: #ff8c9c;
  font-size: 0.83rem;
  font-weight: 750;
  animation: recording-pulse 1.2s ease-in-out infinite;
}

.recording-wave {
  display: flex;
  height: 42px;
  align-items: center;
  justify-content: center;
  gap: 5px;
  overflow: hidden;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.18);
}

.recording-wave span {
  width: 4px;
  height: 10px;
  border-radius: 999px;
  background: rgba(177, 165, 255, 0.65);
  animation: recording-wave 1.2s ease-in-out infinite;
}

.recording-wave span:nth-child(2) {
  animation-delay: 0.1s;
}

.recording-wave span:nth-child(3) {
  animation-delay: 0.2s;
}

.recording-wave span:nth-child(4) {
  animation-delay: 0.3s;
}

.recording-wave span:nth-child(5) {
  animation-delay: 0.4s;
}

.recording-wave span:nth-child(6) {
  animation-delay: 0.5s;
}

.recording-wave span:nth-child(7) {
  animation-delay: 0.6s;
}

.recording-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

#recording-preview-container {
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-small);
  background: rgba(255, 255, 255, 0.025);
}

#recording-preview-container audio {
  width: 100%;
  margin-top: 8px;
}

@keyframes recording-pulse {
  0%,
  100% {
    opacity: 0.45;
  }

  50% {
    opacity: 1;
  }
}

@keyframes recording-wave {
  0%,
  100% {
    height: 9px;
    opacity: 0.45;
  }

  50% {
    height: 32px;
    opacity: 1;
  }
}

@media (max-width: 560px) {
  .voice-source-tabs {
    flex-direction: column;
  }

  .recording-status-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .recording-actions .button {
    width: 100%;
  }
}