:root {
  --bg: #0a1018;
  --bg-elevated: #0f1724;
  --bg-soft: #121c2b;
  --surface: rgba(16, 24, 36, 0.94);
  --surface-strong: rgba(21, 31, 48, 0.98);
  --surface-muted: rgba(12, 18, 28, 0.88);
  --surface-soft: rgba(255, 255, 255, 0.03);
  --line: rgba(141, 163, 196, 0.16);
  --line-strong: rgba(103, 185, 255, 0.34);
  --text: #edf4ff;
  --text-muted: #a7b4c9;
  --text-soft: #7f8da5;
  --accent: #5fc8ff;
  --accent-strong: #7c85ff;
  --accent-soft: rgba(95, 200, 255, 0.14);
  --accent-soft-strong: rgba(124, 133, 255, 0.18);
  --success: #58d691;
  --shadow-lg: 0 24px 60px rgba(3, 9, 18, 0.34);
  --shadow-md: 0 16px 36px rgba(3, 9, 18, 0.22);
  --radius-2xl: 26px;
  --radius-xl: 22px;
  --radius-lg: 18px;
  --radius-md: 14px;
  --radius-sm: 12px;
  --range-track-height: 6px;
  --range-thumb-size: 16px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  overflow-x: hidden;
}

body {
  font-family: "IBM Plex Sans", "Segoe UI", Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 14% 0%, rgba(95, 200, 255, 0.12), transparent 28%),
    radial-gradient(circle at 88% 4%, rgba(124, 133, 255, 0.12), transparent 24%),
    radial-gradient(circle at 50% 100%, rgba(8, 14, 24, 0.66), transparent 40%),
    linear-gradient(180deg, #09101a 0%, #0d1420 36%, #0a111a 100%);
  padding: 20px 16px 34px;
}

body.has-site-footer {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  padding-bottom: 0;
}

body.has-site-footer .app {
  flex: 1 0 auto;
}

body.sound-studio-page {
  color-scheme: dark;
}

.app {
  width: min(96vw, 1520px);
  margin: 26px auto 40px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(360px, 0.92fr);
  gap: 18px;
  align-items: start;
  margin-bottom: 18px;
}

.hero_copy,
.workflow_strip,
.panel,
.controls_shell {
  border: 1px solid var(--line);
  border-radius: var(--radius-2xl);
  background:
    linear-gradient(180deg, rgba(18, 27, 40, 0.96), rgba(12, 20, 31, 0.96)),
    radial-gradient(circle at 0% 0%, rgba(95, 200, 255, 0.06), transparent 34%),
    radial-gradient(circle at 100% 0%, rgba(124, 133, 255, 0.06), transparent 28%);
  box-shadow: var(--shadow-lg);
}

.hero_copy {
  padding: 22px 24px;
}

.eyebrow,
.panel_kicker,
.section_kicker,
.workflow_label,
.drop_kicker,
.asset_meta_label {
  margin: 0;
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-family: "Sora", "Outfit", Arial, sans-serif;
  font-size: clamp(1.86rem, 3.8vw, 3rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.subtitle {
  max-width: 64ch;
  margin: 14px 0 0;
  color: var(--text-muted);
  font-size: clamp(0.95rem, 1.08vw, 1.05rem);
  line-height: 1.6;
}

.hero_badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.hero_badge {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0.46rem 0.8rem;
  border: 1px solid rgba(141, 163, 196, 0.18);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--text-muted);
  font-size: 0.84rem;
  font-weight: 500;
}

.workflow_strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 14px;
  align-self: start;
  align-content: start;
}

.workflow_step {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  min-height: 56px;
  padding: 9px 10px;
  border: 1px solid rgba(141, 163, 196, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.028);
  align-self: start;
}

.workflow_step--primary {
  border-color: var(--line-strong);
  background:
    linear-gradient(180deg, rgba(95, 200, 255, 0.12), rgba(95, 200, 255, 0.04)),
    rgba(255, 255, 255, 0.03);
}

.workflow_icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.055);
  color: var(--accent);
  font-size: 0.98rem;
}

.workflow_step > div {
  display: grid;
  gap: 1px;
  align-content: center;
}

.workflow_title {
  margin: 0;
  font-family: "Sora", "Outfit", Arial, sans-serif;
  font-size: 0.86rem;
  line-height: 1.08;
  letter-spacing: -0.015em;
}

.studio_workspace {
  display: grid;
  grid-template-columns: minmax(300px, 356px) minmax(520px, 1fr) minmax(320px, 384px);
  gap: 18px;
  align-items: start;
}

.panel,
.controls_shell {
  min-width: 0;
}

.upload_panel,
.preview_panel,
.controls_shell {
  padding: 16px;
}

.upload_panel,
.preview_panel,
.controls_shell,
.preset_section,
.controls_grid,
.preview_stack,
.compare_grid,
.track_card {
  min-height: 0;
}

.panel_head,
.section_head,
.track_head,
.export_head,
.preset_head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.panel_head {
  margin-bottom: 14px;
}

.panel_head h2,
.section_head h2,
.section_head h3,
.preset_head h3,
.track_head h3,
.export_head h3 {
  margin: 4px 0 0;
  font-family: "Sora", "Outfit", Arial, sans-serif;
  font-size: 1.05rem;
  line-height: 1.22;
  letter-spacing: -0.02em;
}

.panel_head p:last-child,
.section_head p:last-child {
  margin: 8px 0 0;
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.54;
}

.active_preset,
.render_state {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0.34rem 0.72rem;
  border-radius: 999px;
  border: 1px solid rgba(141, 163, 196, 0.2);
  background: rgba(255, 255, 255, 0.045);
  color: var(--text);
  font-size: 0.79rem;
  font-weight: 600;
  white-space: nowrap;
}

.render_state {
  color: var(--success);
}

.upload_panel,
.preview_panel {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.preview_panel {
  position: sticky;
  top: 88px;
}

.upload_stack {
  display: grid;
  gap: 12px;
}

.drop_zone {
  position: relative;
  min-height: 176px;
  border: 1px dashed rgba(103, 185, 255, 0.34);
  border-radius: var(--radius-xl);
  background:
    linear-gradient(180deg, rgba(13, 20, 31, 0.98), rgba(16, 24, 36, 0.92)),
    radial-gradient(circle at 50% 0%, rgba(95, 200, 255, 0.08), transparent 38%);
  display: grid;
  place-items: center;
  padding: 18px;
  text-align: center;
  cursor: pointer;
  transition:
    border-color 160ms ease,
    transform 160ms ease,
    background 160ms ease,
    box-shadow 160ms ease;
}

.file_input_proxy {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  border: 0;
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
}

.drop_zone:hover,
.drop_zone:focus-visible,
.drop_zone.is-dragover {
  border-color: rgba(95, 200, 255, 0.6);
  background:
    linear-gradient(180deg, rgba(16, 24, 36, 0.99), rgba(18, 27, 40, 0.94)),
    radial-gradient(circle at 50% 0%, rgba(95, 200, 255, 0.12), transparent 38%);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.drop_inner {
  max-width: 28rem;
}

.drop_inner h2 {
  margin: 8px 0 0;
  font-family: "Sora", "Outfit", Arial, sans-serif;
  font-size: clamp(1.12rem, 1.6vw, 1.42rem);
  line-height: 1.14;
  letter-spacing: -0.02em;
}

.drop_inner p {
  margin: 10px auto 0;
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.52;
}

.primary_button,
.ghost_button,
.preset_chip {
  border: 1px solid transparent;
  font: inherit;
  cursor: pointer;
  transition:
    background 150ms ease,
    border-color 150ms ease,
    color 150ms ease,
    transform 150ms ease,
    box-shadow 150ms ease;
}

.primary_button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 0.7rem 1rem;
  border-radius: 14px;
  border-color: rgba(95, 200, 255, 0.36);
  background: linear-gradient(180deg, rgba(95, 200, 255, 0.2), rgba(69, 147, 255, 0.12));
  color: #f3f9ff;
  font-weight: 600;
  box-shadow: 0 10px 28px rgba(10, 26, 48, 0.18);
}

.drop_inner .primary_button {
  margin-top: 18px;
}

.ghost_button {
  min-height: 38px;
  padding: 0.62rem 0.88rem;
  border-radius: 12px;
  border-color: rgba(141, 163, 196, 0.18);
  background: rgba(255, 255, 255, 0.035);
  color: var(--text);
  font-weight: 500;
}

.primary_button:hover,
.ghost_button:hover,
.preset_chip:hover {
  transform: translateY(-1px);
}

.primary_button:hover {
  border-color: rgba(95, 200, 255, 0.48);
  box-shadow: 0 12px 30px rgba(10, 26, 48, 0.24);
}

.ghost_button:hover,
.preset_chip:hover {
  border-color: rgba(141, 163, 196, 0.28);
  background: rgba(255, 255, 255, 0.05);
}

.primary_button:active,
.ghost_button:active,
.preset_chip:active {
  transform: translateY(0);
}

.primary_button:disabled,
.ghost_button:disabled {
  opacity: 0.48;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.asset_meta,
.preset_section,
.track_card,
.export_card {
  border: 1px solid rgba(141, 163, 196, 0.12);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.028);
}

.asset_meta {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.asset_meta_row {
  display: grid;
  gap: 4px;
}

.asset_meta_row h3,
.asset_meta_row p {
  margin: 0;
}

.asset_meta_row h3 {
  font-size: 0.98rem;
  line-height: 1.4;
}

.asset_meta_row p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.5;
}

.asset_meta_row--status p {
  color: var(--text);
}

.preset_section {
  padding: 14px;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  min-height: 0;
}

.preset_head {
  margin-bottom: 12px;
}

.preset_grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.preset_chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0.65rem 0.78rem;
  border-radius: 12px;
  border-color: rgba(141, 163, 196, 0.14);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-muted);
  font-size: 0.86rem;
  font-weight: 600;
  text-align: center;
}

.preset_chip.is-active {
  border-color: rgba(95, 200, 255, 0.4);
  background:
    linear-gradient(180deg, rgba(95, 200, 255, 0.16), rgba(124, 133, 255, 0.12)),
    rgba(255, 255, 255, 0.04);
  color: var(--text);
}

.preview_stack {
  display: grid;
  gap: 12px;
}

.compare_grid {
  display: grid;
  gap: 12px;
}

.track_card,
.export_card {
  padding: 12px;
}

.track_card {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
}

.track_head,
.export_head {
  align-items: center;
  margin-bottom: 10px;
}

.track_toggle {
  min-width: 96px;
}

.track_surface {
  border: 1px solid rgba(141, 163, 196, 0.12);
  border-radius: 14px;
  background: rgba(7, 12, 20, 0.54);
  padding: 8px 10px 10px;
  min-height: 0;
}

.track_wave {
  min-height: 64px;
}

.track_note,
.render_hint,
.export_text {
  margin: 8px 0 0;
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.48;
}

.track_time,
.render_summary {
  margin: 10px 0 0;
  color: var(--text-soft);
  font-size: 0.82rem;
  font-weight: 600;
}

.export_card {
  background:
    linear-gradient(180deg, rgba(17, 27, 40, 0.98), rgba(12, 20, 31, 0.96)),
    radial-gradient(circle at 100% 0%, rgba(95, 200, 255, 0.08), transparent 32%);
}

.export_actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin-top: 14px;
}

.controls_shell {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.controls_grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.control_section {
  border: 1px solid rgba(141, 163, 196, 0.12);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(180deg, rgba(20, 30, 44, 0.84), rgba(14, 21, 32, 0.9)),
    radial-gradient(circle at 100% 0%, rgba(124, 133, 255, 0.06), transparent 28%);
  padding: 14px;
  min-width: 0;
}

.control_section .section_head {
  padding-bottom: 10px;
  margin-bottom: 10px;
  border-bottom: 1px solid rgba(141, 163, 196, 0.1);
}

.control_section .section_head h3 {
  margin-top: 0;
}

.section_count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 30px;
  min-height: 30px;
  padding: 0 0.56rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--text-soft);
  font-size: 0.78rem;
  font-weight: 700;
}

.control_stack {
  display: grid;
  gap: 8px;
}

.control_row {
  display: grid;
  gap: 8px;
  padding-top: 8px;
}

.control_row + .control_row {
  border-top: 1px solid rgba(141, 163, 196, 0.08);
}

.control_meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.control_label {
  color: var(--text);
  font-size: 0.88rem;
  font-weight: 500;
  line-height: 1.35;
}

.control_value {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 0.14rem 0.5rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--accent);
  font-size: 0.77rem;
  font-weight: 700;
  white-space: nowrap;
}

input[type="range"] {
  width: 100%;
  height: 18px;
  margin: 0;
  -webkit-appearance: none;
  appearance: none;
  background: transparent;
  cursor: pointer;
}

input[type="range"]::-webkit-slider-runnable-track {
  height: var(--range-track-height);
  border-radius: 999px;
  background:
    linear-gradient(
      90deg,
      rgba(95, 200, 255, 0.96) 0%,
      rgba(124, 133, 255, 0.92) var(--range-percent, 50%),
      rgba(255, 255, 255, 0.1) var(--range-percent, 50%),
      rgba(255, 255, 255, 0.06) 100%
    );
  box-shadow: inset 0 0 0 1px rgba(141, 163, 196, 0.14);
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: var(--range-thumb-size);
  height: var(--range-thumb-size);
  margin-top: calc((var(--range-track-height) - var(--range-thumb-size)) / 2);
  border: 2px solid rgba(232, 242, 255, 0.9);
  border-radius: 50%;
  background: linear-gradient(180deg, #f6fbff, #d7e8ff);
  box-shadow: 0 3px 12px rgba(11, 29, 49, 0.28);
}

input[type="range"]::-moz-range-track {
  height: var(--range-track-height);
  border-radius: 999px;
  border: 0;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 0 0 1px rgba(141, 163, 196, 0.14);
}

input[type="range"]::-moz-range-progress {
  height: var(--range-track-height);
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(95, 200, 255, 0.96), rgba(124, 133, 255, 0.92));
}

input[type="range"]::-moz-range-thumb {
  width: var(--range-thumb-size);
  height: var(--range-thumb-size);
  border: 2px solid rgba(232, 242, 255, 0.9);
  border-radius: 50%;
  background: linear-gradient(180deg, #f6fbff, #d7e8ff);
  box-shadow: 0 3px 12px rgba(11, 29, 49, 0.28);
}

:focus-visible {
  outline: 2px solid rgba(95, 200, 255, 0.58);
  outline-offset: 2px;
}

@media (min-width: 1280px) {
  body.sound-studio-page {
    padding: 8px 12px 0;
  }

  body.sound-studio-page .app {
    width: min(96vw, 1500px);
    height: calc(100svh - 8px);
    min-height: calc(100svh - 8px);
    max-height: calc(100svh - 8px);
    margin: 0 auto 16px;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 8px;
    overflow: hidden;
  }

  .hero {
    grid-template-columns: minmax(0, 1.06fr) minmax(400px, 0.94fr);
    gap: 8px;
    align-items: start;
    margin-bottom: 0;
  }

  .hero_copy,
  .workflow_strip,
  .panel,
  .controls_shell {
    border-radius: 18px;
  }

  .hero_copy {
    padding: 11px 14px;
  }

  .eyebrow,
  .panel_kicker,
  .section_kicker,
  .workflow_label,
  .drop_kicker,
  .asset_meta_label {
    font-size: 0.64rem;
    letter-spacing: 0.12em;
  }

  h1 {
    font-size: clamp(1.34rem, 1.72vw, 1.8rem);
    line-height: 1;
  }

  .subtitle {
    margin-top: 6px;
    font-size: 0.8rem;
    line-height: 1.32;
    max-width: 70ch;
  }

  .hero_badges {
    gap: 5px;
    margin-top: 8px;
  }

  .hero_badge {
    min-height: 24px;
    padding: 0.22rem 0.56rem;
    font-size: 0.7rem;
  }

  .workflow_strip {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 5px;
    padding: 4px;
    align-items: start;
    align-content: start;
    align-self: start;
  }

  .workflow_step {
    gap: 6px;
    min-height: 40px;
    padding: 2px 6px;
    border-radius: 10px;
    align-self: start;
  }

  .workflow_icon {
    width: 16px;
    height: 16px;
    border-radius: 6px;
    font-size: 0.62rem;
  }

  .workflow_label {
    font-size: 0.5rem;
    letter-spacing: 0.11em;
  }

  .workflow_title {
    font-size: 0.58rem;
    line-height: 1;
  }

  .studio_workspace {
    height: 100%;
    min-height: 0;
    grid-template-columns: minmax(264px, 314px) minmax(400px, 1fr) minmax(332px, 364px);
    gap: 8px;
    overflow: hidden;
  }

  .upload_panel,
  .preview_panel,
  .controls_shell {
    height: 100%;
    min-height: 0;
    padding: 10px;
    overflow: hidden;
  }

  .upload_panel {
    display: grid;
    grid-template-rows: auto auto minmax(0, 1fr);
    gap: 8px;
  }

  .controls_shell {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 8px;
  }

  .preview_panel {
    position: relative;
    top: auto;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 8px;
  }

  .panel_head,
  .section_head,
  .track_head,
  .export_head,
  .preset_head {
    gap: 8px;
  }

  .panel_head {
    margin-bottom: 0;
  }

  .panel_head h2,
  .section_head h2,
  .section_head h3,
  .preset_head h3,
  .track_head h3,
  .export_head h3 {
    margin-top: 1px;
    font-size: 0.88rem;
    line-height: 1.08;
  }

  .panel_head p:last-child,
  .section_head p:last-child {
    margin-top: 3px;
    font-size: 0.73rem;
    line-height: 1.26;
  }

  .active_preset,
  .render_state {
    min-height: 26px;
    padding: 0.22rem 0.56rem;
    font-size: 0.71rem;
  }

  .upload_stack {
    gap: 7px;
  }

  .drop_zone {
    min-height: 108px;
    padding: 10px;
    border-radius: 14px;
  }

  .drop_inner {
    max-width: 24rem;
  }

  .drop_inner h2 {
    margin-top: 3px;
    font-size: 0.92rem;
  }

  .drop_inner p {
    margin-top: 4px;
    font-size: 0.75rem;
    line-height: 1.24;
  }

  .drop_inner .primary_button {
    margin-top: 9px;
  }

  .primary_button {
    min-height: 32px;
    padding: 0.42rem 0.74rem;
    border-radius: 10px;
    font-size: 0.76rem;
  }

  .ghost_button {
    min-height: 30px;
    padding: 0.36rem 0.68rem;
    border-radius: 10px;
    font-size: 0.75rem;
  }

  .asset_meta {
    gap: 6px;
    padding: 9px;
  }

  .asset_meta_row {
    gap: 2px;
  }

  .asset_meta_row h3 {
    font-size: 0.8rem;
    line-height: 1.18;
  }

  .asset_meta_row p {
    font-size: 0.71rem;
    line-height: 1.22;
  }

  .preset_section {
    padding: 9px;
  }

  .preset_head {
    margin-bottom: 6px;
  }

  .preset_grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 5px;
    overflow: auto;
    padding-right: 2px;
  }

  .preset_chip {
    min-height: 28px;
    padding: 0.26rem 0.45rem;
    border-radius: 9px;
    font-size: 0.7rem;
    line-height: 1.08;
  }

  .controls_grid {
    gap: 7px;
    overflow: auto;
    padding-right: 2px;
    align-content: start;
  }

  .control_section {
    padding: 9px;
    border-radius: 13px;
  }

  .control_section .section_head {
    padding-bottom: 6px;
    margin-bottom: 7px;
  }

  .section_count {
    min-width: 24px;
    min-height: 24px;
    padding: 0 0.42rem;
    font-size: 0.68rem;
  }

  .control_stack {
    gap: 5px;
  }

  .control_row {
    gap: 5px;
    padding-top: 5px;
  }

  .control_label {
    font-size: 0.74rem;
    line-height: 1.14;
  }

  .control_value {
    min-height: 20px;
    padding: 0.08rem 0.42rem;
    font-size: 0.66rem;
  }

  input[type="range"] {
    height: 12px;
  }

  .preview_stack {
    height: 100%;
    min-height: 0;
    grid-template-rows: minmax(0, 1fr) auto;
    gap: 6px;
    overflow: hidden;
  }

  .compare_grid {
    height: 100%;
    min-height: 0;
    grid-template-rows: repeat(2, minmax(0, 1fr));
    gap: 6px;
    overflow: hidden;
  }

  .track_card,
  .export_card {
    padding: 8px;
    border-radius: 13px;
  }

  .track_card {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    gap: 4px;
    overflow: hidden;
  }

  .export_card {
    display: grid;
    align-content: start;
    gap: 4px;
    overflow: hidden;
  }

  .track_head,
  .export_head {
    margin-bottom: 0;
    gap: 6px;
    align-items: flex-start;
  }

  .track_toggle {
    min-width: 76px;
    min-height: 28px;
    padding-inline: 0.52rem;
  }

  .track_surface {
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    gap: 4px;
    min-height: 0;
    padding: 5px 6px 6px;
    border-radius: 10px;
  }

  .track_wave {
    min-height: 0;
    height: 42px;
  }

  .track_note,
  .render_hint,
  .export_text {
    margin-top: 0;
    font-size: 0.7rem;
    line-height: 1.2;
  }

  .track_time,
  .render_summary {
    margin-top: 0;
    font-size: 0.66rem;
    line-height: 1.1;
  }

  .render_state {
    min-height: 24px;
    padding: 0.18rem 0.48rem;
    font-size: 0.66rem;
  }

  .export_actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
    margin-top: 2px;
  }

  .export_actions .primary_button,
  .export_actions .ghost_button {
    min-height: 34px;
    padding: 0.42rem 0.42rem;
    font-size: 0.71rem;
    line-height: 1.15;
    text-align: center;
  }
}

@media (max-width: 1380px) {
  .studio_workspace {
    grid-template-columns: minmax(264px, 310px) minmax(0, 1fr) minmax(324px, 352px);
  }

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

@media (max-width: 1220px) {
  .hero {
    grid-template-columns: 1fr;
  }

  .workflow_strip {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .studio_workspace {
    grid-template-columns: minmax(300px, 0.92fr) minmax(0, 1.08fr);
    grid-template-areas:
      "upload preview"
      "controls preview";
  }

  .upload_panel {
    grid-area: upload;
  }

  .controls_shell {
    grid-area: controls;
  }

  .preview_panel {
    grid-area: preview;
  }
}

@media (max-width: 1024px) {
  body {
    padding: 18px 8px 24px;
  }

  .app {
    width: min(100%, calc(100% - 10px));
    margin-top: 74px;
    margin-bottom: 24px;
  }

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

  .studio_workspace {
    grid-template-columns: 1fr;
    grid-template-areas: none;
  }

  .preview_panel {
    position: static;
  }

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

@media (max-width: 720px) {
  body {
    padding: 16px 4px 22px;
  }

  .app {
    width: min(100%, calc(100% - 8px));
    margin-top: 66px;
  }

  .hero,
  .studio_workspace {
    gap: 14px;
  }

  .hero_copy,
  .workflow_strip,
  .upload_panel,
  .preview_panel,
  .controls_shell {
    padding: 14px;
    border-radius: 20px;
  }

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

  .panel_head,
  .section_head,
  .track_head,
  .export_head,
  .preset_head {
    flex-direction: column;
    align-items: flex-start;
  }

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

  .active_preset,
  .track_toggle,
  .primary_button,
  .ghost_button {
    width: 100%;
  }
}

@media (max-width: 560px) {
  .hero_badges,
  .preset_grid {
    grid-template-columns: 1fr;
  }

  .hero_badges {
    display: grid;
  }

  .preset_grid {
    display: grid;
  }
}
