:root {
  --ink: #34373a;
  --soft-ink: #6d7477;
  --muted: #92999b;
  --page: #eef1ef;
  --panel: rgba(248, 249, 246, 0.52);
  --line: rgba(50, 55, 58, 0.14);
  --paper: #f7f2e8;
  --shadow: rgba(42, 50, 55, 0.14);
  color-scheme: light;
}

@font-face {
  font-family: "CollageFangSong";
  src: url("./assets/fonts/HYFangSongS.ttf") format("truetype");
  font-display: swap;
}

* {
  box-sizing: border-box;
}

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

body {
  color: var(--ink);
  font-family: "CollageFangSong", "FangSong", "FangSong_GB2312", "STFangsong", "Songti SC", "Noto Serif SC", serif;
  background:
    linear-gradient(rgba(255, 255, 255, 0.68), rgba(238, 247, 251, 0.68)),
    linear-gradient(90deg, rgba(159, 203, 231, 0.38) 0 50%, transparent 50% 100%),
    linear-gradient(rgba(159, 203, 231, 0.38) 0 50%, transparent 50% 100%),
    #fbfdfb;
  background-attachment: fixed;
  background-position: center;
  background-size: auto, 64px 64px, 64px 64px, auto;
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
}

body::before {
  opacity: 0.36;
  background-image:
    radial-gradient(circle, rgba(35, 39, 42, 0.28) 0 0.42px, transparent 0.78px),
    radial-gradient(circle, rgba(255, 255, 255, 0.85) 0 0.34px, transparent 0.85px);
  background-position: 0 0, 13px 9px;
  background-size: 19px 17px, 29px 31px;
  mix-blend-mode: multiply;
}

body::after {
  opacity: 0.18;
  background-image:
    linear-gradient(100deg, rgba(36, 41, 44, 0.035) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.28) 1px, transparent 1px);
  background-size: 17px 100%, 100% 11px;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  min-height: 100vh;
  padding: 28px;
}

.studio {
  display: grid;
  grid-template-columns: minmax(288px, 372px) minmax(330px, 1fr);
  gap: 34px;
  max-width: 1180px;
  margin: 0 auto;
}

.library-panel,
.canvas-frame,
.export-sheet {
  border: 1px solid var(--line);
  background: var(--panel);
  backdrop-filter: blur(10px);
  box-shadow: 0 22px 58px var(--shadow);
}

.library-panel {
  min-height: calc(100vh - 56px);
  padding: 0;
  overflow: visible;
  border: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

.library-hero-card,
.library-stack-card {
  position: relative;
  filter: drop-shadow(0 18px 22px rgba(42, 50, 55, 0.1));
}

.library-hero-card {
  display: inline-block;
  width: fit-content;
  min-height: 0;
  margin: 0 0 6px;
  padding: 24px 30px 22px 32px;
  background:
    linear-gradient(rgba(220, 212, 198, 0.34) 1px, transparent 1px),
    linear-gradient(90deg, rgba(220, 212, 198, 0.34) 1px, transparent 1px),
    #fbf7f1;
  background-size: 22px 22px, 22px 22px, auto;
  clip-path: polygon(5% 15%, 15% 5%, 18% 10%, 31% 8%, 46% 10%, 61% 8%, 76% 11%, 94% 15%, 96% 84%, 84% 91%, 68% 88%, 52% 91%, 36% 87%, 20% 91%, 5% 86%);
}

.library-hero-card::before,
.library-hero-card::after {
  content: "";
  position: absolute;
  z-index: -1;
  width: 82px;
  height: 24px;
  background: rgba(223, 218, 203, 0.9);
  box-shadow: inset 0 0 0 1px rgba(155, 148, 132, 0.12);
}

.library-hero-card::before {
  left: 14px;
  top: 9px;
  transform: rotate(-32deg);
}

.library-hero-card::after {
  display: none;
}

.library-stack-card {
  min-height: 648px;
  margin: -12px -8px 0;
  padding: 56px 42px 48px;
  background:
    radial-gradient(circle at 30% 16%, rgba(255, 255, 255, 0.86), transparent 15rem),
    radial-gradient(circle at 75% 78%, rgba(230, 235, 233, 0.34), transparent 14rem),
    linear-gradient(90deg, rgba(218, 223, 221, 0.28) 0 1px, transparent 1px calc(100% - 1px), rgba(190, 196, 194, 0.28) calc(100% - 1px)),
    linear-gradient(#fbfcfa, #f4f7f5);
  clip-path: polygon(
    0 9%,
    4% 7.2%,
    9% 8.5%,
    15% 6.2%,
    22% 7.4%,
    29% 5.8%,
    36% 7.1%,
    43% 6.5%,
    51% 7.9%,
    58% 6.4%,
    66% 7.2%,
    74% 6%,
    82% 7.5%,
    90% 6.8%,
    100% 9.2%,
    100% 91.5%,
    94% 92.8%,
    86% 91.4%,
    79% 94%,
    70% 92.5%,
    63% 94.6%,
    55% 92.7%,
    47% 94%,
    39% 91.8%,
    31% 93.6%,
    23% 91.7%,
    16% 93.2%,
    8% 91.9%,
    0 93.6%
  );
  filter: drop-shadow(0 18px 24px rgba(42, 50, 55, 0.14));
}

.library-stack-card::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 28px;
  height: 42px;
  z-index: 0;
  opacity: 0.58;
  background:
    radial-gradient(circle at 2% 70%, rgba(122, 130, 128, 0.28) 0 1px, transparent 2px),
    radial-gradient(circle at 8% 35%, rgba(156, 164, 160, 0.2) 0 1.4px, transparent 2.4px),
    radial-gradient(circle at 17% 66%, rgba(116, 124, 121, 0.24) 0 1px, transparent 2px),
    radial-gradient(circle at 26% 31%, rgba(150, 157, 154, 0.18) 0 1.2px, transparent 2px),
    radial-gradient(circle at 38% 58%, rgba(114, 120, 118, 0.22) 0 1px, transparent 2px),
    radial-gradient(circle at 51% 40%, rgba(150, 156, 154, 0.22) 0 1.2px, transparent 2.2px),
    radial-gradient(circle at 64% 63%, rgba(110, 118, 115, 0.2) 0 1px, transparent 2px),
    radial-gradient(circle at 77% 33%, rgba(154, 160, 158, 0.18) 0 1.3px, transparent 2.4px),
    radial-gradient(circle at 90% 60%, rgba(116, 124, 121, 0.22) 0 1px, transparent 2px);
  background-size: 26px 18px, 34px 21px, 31px 22px, 29px 20px, 37px 24px, 32px 19px, 28px 23px, 35px 22px, 30px 20px;
  pointer-events: none;
}

.library-stack-card::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 34px;
  height: 48px;
  z-index: 0;
  opacity: 0.5;
  background:
    radial-gradient(circle at 5% 35%, rgba(116, 124, 121, 0.23) 0 1px, transparent 2.2px),
    radial-gradient(circle at 14% 68%, rgba(156, 164, 160, 0.19) 0 1.4px, transparent 2.5px),
    radial-gradient(circle at 24% 43%, rgba(118, 126, 123, 0.22) 0 1px, transparent 2px),
    radial-gradient(circle at 34% 76%, rgba(148, 156, 153, 0.2) 0 1.3px, transparent 2.4px),
    radial-gradient(circle at 49% 38%, rgba(116, 124, 121, 0.22) 0 1px, transparent 2px),
    radial-gradient(circle at 63% 70%, rgba(154, 160, 158, 0.18) 0 1.3px, transparent 2.4px),
    radial-gradient(circle at 78% 42%, rgba(110, 118, 115, 0.2) 0 1px, transparent 2px),
    radial-gradient(circle at 92% 64%, rgba(150, 157, 154, 0.18) 0 1.2px, transparent 2.2px);
  background-size: 32px 20px, 28px 22px, 36px 25px, 31px 18px, 35px 23px, 27px 20px, 34px 22px, 29px 19px;
  pointer-events: none;
}

.library-paper-area {
  position: relative;
  z-index: 1;
  height: 354px;
  margin: 0;
  padding: 0 2px;
  background: transparent;
  border: 0;
  box-shadow: none;
  clip-path: none;
}

.library-paper-area::before,
.library-paper-area::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.library-paper-area::before {
  right: 4px;
  top: 62px;
  width: 5px;
  height: 64px;
  z-index: 3;
  background: rgba(82, 89, 91, 0.34);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.38);
}

.library-paper-area::after {
  right: 5px;
  top: 52px;
  bottom: 28px;
  width: 2px;
  z-index: 2;
  background: rgba(82, 89, 91, 0.16);
}

.library-envelope-controls {
  position: relative;
  z-index: 2;
  margin: 8px 0 0;
  padding: 0 2px 6px;
  color: var(--ink);
}

.brand-block {
  padding: 0 0 4px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: clamp(27px, 3.6vw, 40px);
  line-height: 1.08;
  font-weight: 400;
  letter-spacing: 0;
}

.toolbar,
.palette-block,
.canvas-backgrounds,
.canvas-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.toolbar {
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 0;
  margin-top: 12px;
}

.song-search {
  display: flex;
  align-items: center;
  width: 100%;
  gap: 8px;
}

.song-search input {
  min-width: 0;
  width: 100%;
  min-height: 31px;
  padding: 6px 9px;
  border: 1px solid rgba(46, 94, 115, 0.22);
  color: #2e4d5c;
  background: rgba(255, 255, 245, 0.72);
  outline: 0;
}

.text-button,
.upload-button,
.preset,
.primary-button,
.icon-button {
  min-height: 37px;
  border: 1px solid rgba(53, 58, 61, 0.2);
  color: var(--ink);
  background: rgba(255, 255, 252, 0.58);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.48);
  letter-spacing: 0;
}

.text-button,
.upload-button,
.preset,
.primary-button {
  padding: 8px 14px;
}

.song-search .text-button {
  flex: 0 0 auto;
  white-space: nowrap;
}

#shuffleSet,
#songSearchButton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 31px;
  border: 1px solid rgba(53, 58, 61, 0.2);
  color: var(--ink);
  background:
    linear-gradient(rgba(255, 255, 255, 0.5), rgba(238, 241, 239, 0.54)),
    rgba(255, 255, 252, 0.62);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.56),
    0 4px 10px rgba(42, 50, 55, 0.08);
  font-family: "CollageFangSong", "FangSong", "FangSong_GB2312", "STFangsong", "Songti SC", serif;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.2;
  text-align: center;
  text-shadow: none;
}

#shuffleSet {
  width: auto;
  height: auto;
  margin: 0;
  padding: 6px 13px;
  font-size: 14px;
}

#songSearchButton {
  width: auto;
  height: auto;
  padding: 6px 10px;
  font-size: 13px;
  white-space: normal;
}

.upload-button input {
  display: none;
}

.palette-block {
  align-items: center;
  justify-content: space-between;
  margin: 0;
  padding: 0;
  border: 0;
  color: var(--ink);
}

.palette-copy {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 74px;
}

.palette-copy span {
  color: var(--soft-ink);
  font-size: 13px;
  letter-spacing: 0;
  text-shadow: none;
}

.palette-copy small {
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0;
}

.palette-copy em,
.library-hint {
  color: rgba(109, 116, 119, 0.82);
  font-size: 11px;
  font-style: normal;
  line-height: 1.55;
  letter-spacing: 0;
}

.palette-copy em {
  color: rgba(109, 116, 119, 0.82);
  text-shadow: none;
}

.color-wheel {
  position: relative;
  flex: 0 0 auto;
  width: 68px;
  height: 68px;
  border: 1px solid rgba(53, 58, 61, 0.18);
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(248, 244, 235, 0.96) 0 17%, rgba(248, 244, 235, 0.48) 28%, transparent 68%),
    conic-gradient(
      from -20deg,
      #d8b8b1,
      #d8c79e,
      #bec5ad,
      #afc4c7,
      #b9b3c8,
      #d0b2bd,
      #d8b8b1
    );
  box-shadow:
    inset 0 0 0 9px rgba(248, 244, 235, 0.54),
    0 8px 20px rgba(44, 53, 58, 0.12);
  touch-action: none;
}

.color-wheel::after {
  content: "";
  position: absolute;
  inset: 16px;
  border: 1px solid rgba(53, 58, 61, 0.11);
  border-radius: 50%;
}

.wheel-handle {
  position: absolute;
  left: calc(50% - 6px);
  top: calc(50% - 6px);
  width: 12px;
  height: 12px;
  border: 2px solid rgba(255, 252, 244, 0.92);
  border-radius: 50%;
  background: #d8c79e;
  box-shadow: 0 2px 8px rgba(43, 50, 54, 0.24);
  transform: translate(19px, 15px);
}

.swatches {
  display: grid;
  grid-template-columns: repeat(3, 18px);
  gap: 7px;
}

.swatch {
  width: 18px;
  height: 18px;
  border: 1px solid rgba(53, 58, 61, 0.2);
  border-radius: 50%;
  background: var(--swatch);
  box-shadow: inset 0 0 0 4px rgba(255, 255, 255, 0.22);
}

.preset.active {
  background: rgba(74, 82, 86, 0.16);
}

.fragment-library {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 13px;
  max-height: 286px;
  padding: 6px 20px 22px 2px;
  overflow-y: scroll;
  overflow-x: hidden;
  scrollbar-color: rgba(71, 80, 84, 0.38) rgba(71, 80, 84, 0.1);
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}

.fragment-library::after {
  content: "";
  position: sticky;
  bottom: -22px;
  flex: 0 0 34px;
  height: 34px;
  margin-top: -34px;
  z-index: 2;
  background: linear-gradient(rgba(247, 249, 247, 0), rgba(247, 249, 247, 0.9));
  pointer-events: none;
}

.library-hint {
  margin: 0 0 10px;
}

.fragment-library::-webkit-scrollbar {
  width: 9px;
}

.fragment-library::-webkit-scrollbar-track {
  background: rgba(71, 80, 84, 0.1);
}

.fragment-library::-webkit-scrollbar-thumb {
  background: rgba(71, 80, 84, 0.38);
  border: 2px solid rgba(255, 255, 252, 0.52);
}

.strip {
  --strip-bg: var(--paper);
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  max-width: 100%;
  min-height: 38px;
  padding: 9px 15px;
  color: #3d342c;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.34), transparent 22%, rgba(101, 82, 57, 0.035) 72%, transparent),
    linear-gradient(rgba(255, 255, 255, 0.16) 1px, transparent 1px),
    var(--strip-bg);
  background-size: 100% 100%, 100% 7px, 100% 100%;
  box-shadow:
    0 6px 14px rgba(64, 70, 72, 0.13),
    inset 0 0 18px rgba(255, 255, 255, 0.28);
  clip-path: polygon(
    1% 0,
    98% 0,
    100% 9%,
    98.6% 17%,
    100% 28%,
    98.7% 39%,
    100% 50%,
    98.4% 61%,
    100% 73%,
    98.5% 86%,
    100% 100%,
    1.6% 100%,
    0 91%,
    1.3% 81%,
    0 68%,
    1.1% 55%,
    0 43%,
    1.5% 31%,
    0 18%,
    1.2% 8%
  );
  user-select: none;
  touch-action: none;
}

.strip::before,
.strip::after {
  content: "";
  position: absolute;
  top: 4px;
  bottom: 4px;
  width: 8px;
  pointer-events: none;
  opacity: 0.46;
  background:
    radial-gradient(circle, rgba(255, 255, 255, 0.7) 0 0.8px, transparent 1.1px),
    linear-gradient(rgba(93, 77, 56, 0.14), rgba(93, 77, 56, 0));
  background-size: 5px 7px, 100% 100%;
}

.strip::before {
  left: 0;
}

.strip::after {
  right: 0;
}

.strip.selected {
  outline: 1px dashed rgba(70, 78, 82, 0.4);
  outline-offset: 5px;
}

.strip-text {
  position: relative;
  z-index: 1;
  white-space: normal;
  line-height: 1.7;
  font-size: 15px;
  letter-spacing: 0;
  text-shadow: 0 0 0.2px currentColor;
}

.canvas-strip {
  max-width: none;
}

.canvas-strip .strip-text {
  white-space: nowrap;
}

.scissor {
  position: relative;
  z-index: 1;
  flex: 0 0 auto;
  width: 25px;
  height: 25px;
  border: 0;
  color: #7b6654;
  background: transparent;
  font-size: 14px;
  opacity: 0.7;
}

.strip.cutting .strip-text span {
  display: inline-block;
  padding: 0 2px;
  border-right: 1px solid rgba(84, 67, 48, 0.22);
  cursor: col-resize;
}

.canvas-zone {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  min-width: 0;
}

.canvas-frame {
  width: min(76vh, 100%);
  max-width: 620px;
  padding: 20px;
  border-radius: 0;
  background:
    linear-gradient(rgba(255, 255, 255, 0.34), rgba(230, 235, 235, 0.32)),
    rgba(244, 247, 245, 0.5);
}

.poetry-canvas {
  position: relative;
  aspect-ratio: 3 / 4;
  width: 100%;
  overflow: hidden;
  background:
    linear-gradient(rgba(255, 255, 255, 0.04), rgba(240, 243, 241, 0.06)),
    url("./assets/canvas-paper-lined.jpg");
  background-position: center;
  background-size: cover;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.16),
    inset 0 0 64px rgba(27, 33, 36, 0.16);
}

.poetry-canvas[data-bg="lined"] {
  background:
    linear-gradient(rgba(255, 255, 255, 0.04), rgba(240, 243, 241, 0.06)),
    url("./assets/canvas-paper-lined.jpg");
  background-position: center;
  background-size: cover;
}

.poetry-canvas[data-bg="white"] {
  background:
    linear-gradient(rgba(255, 255, 255, 0.05), rgba(240, 243, 241, 0.05)),
    url("./assets/canvas-paper-white.jpg");
  background-position: center;
  background-size: cover;
}

.poetry-canvas[data-bg="black"] {
  background:
    linear-gradient(rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.02)),
    url("./assets/canvas-paper-black.jpg");
  background-position: center;
  background-size: cover;
}

.poetry-canvas.has-image {
  background-position: center;
  background-size: cover;
}

.canvas-credit {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 15px;
  z-index: 1;
  margin: 0;
  color: rgba(245, 246, 242, 0.42);
  text-align: center;
  font-size: 11px;
  letter-spacing: 0;
  pointer-events: none;
}

.poetry-canvas[data-bg="lined"] .canvas-credit,
.poetry-canvas[data-bg="white"] .canvas-credit {
  color: rgba(57, 63, 66, 0.34);
}

.poetry-canvas[data-bg="black"] .canvas-credit {
  color: rgba(245, 246, 242, 0.38);
}

.canvas-strip {
  position: absolute;
  z-index: 2;
  transform-origin: center center;
}

.delete-strip {
  position: absolute;
  top: -11px;
  right: -11px;
  z-index: 2;
  display: none;
  width: 24px;
  height: 24px;
  border: 1px solid rgba(70, 78, 82, 0.28);
  border-radius: 50%;
  color: #596165;
  background: rgba(255, 255, 252, 0.74);
  line-height: 19px;
}

.canvas-strip.selected .delete-strip {
  display: block;
}

.canvas-actions {
  justify-content: center;
}

.canvas-backgrounds {
  justify-content: center;
  flex-wrap: wrap;
}

.canvas-backgrounds .preset {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.canvas-backgrounds .preset::before {
  content: "";
  width: 22px;
  height: 22px;
  border: 1px solid rgba(53, 58, 61, 0.18);
  background-position: center;
  background-size: cover;
}

.canvas-backgrounds .preset[data-bg="lined"]::before {
  background-image: url("./assets/canvas-paper-lined.jpg");
}

.canvas-backgrounds .preset[data-bg="white"]::before {
  background-image: url("./assets/canvas-paper-white.jpg");
}

.canvas-backgrounds .preset[data-bg="black"]::before {
  background-image: url("./assets/canvas-paper-black.jpg");
}

.icon-button {
  width: 38px;
  padding: 0;
  font-size: 22px;
}

.primary-button {
  min-width: 136px;
  color: #f9f9f4;
  background: rgba(65, 73, 77, 0.76);
}

.export-overlay {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: grid;
  place-items: center;
  padding: 22px;
  background: rgba(223, 229, 229, 0.7);
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.export-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.export-sheet {
  position: relative;
  width: min(430px, 92vw);
  padding: 16px;
  background: rgba(250, 251, 247, 0.72);
}

.export-sheet img {
  display: block;
  width: 100%;
  background: #e8ecea;
  -webkit-touch-callout: default;
  user-select: auto;
}

.export-sheet p {
  margin: 12px 0 0;
  color: var(--soft-ink);
  text-align: center;
  font-size: 13px;
  letter-spacing: 0;
}

.close {
  position: absolute;
  top: -13px;
  right: -13px;
}

.side-actions {
  position: fixed;
  right: 20px;
  top: 50%;
  z-index: 20;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transform: translateY(-50%);
}

.side-action {
  width: 58px;
  height: 58px;
  border: 1px solid rgba(53, 58, 61, 0.22);
  border-radius: 50%;
  color: var(--ink);
  background: rgba(255, 255, 252, 0.62);
  box-shadow: 0 10px 24px rgba(42, 50, 55, 0.12);
  font-size: 12px;
  line-height: 1.25;
  white-space: pre-line;
}

.info-overlay {
  position: fixed;
  inset: 0;
  z-index: 35;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(29, 32, 33, 0.46);
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.info-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.info-note {
  position: relative;
  width: min(520px, 94vw);
  min-height: min(560px, 82vh);
  padding: 95px 76px 56px;
  background-image: url("./assets/note-paper-modal.png");
  background-position: center;
  background-repeat: no-repeat;
  background-size: 100% 100%;
  color: #3d342c;
}

.info-note h2 {
  margin: 0 0 18px;
  font-size: 24px;
  font-weight: 400;
  line-height: 1.25;
  letter-spacing: 0;
}

.info-body {
  max-height: 330px;
  overflow: auto;
  padding-right: 6px;
  font-size: 15px;
  line-height: 1.85;
}

.info-body p {
  margin: 0 0 10px;
}

.info-body ol {
  margin: 0 0 18px;
  padding-left: 1.3em;
}

.info-body li {
  margin: 0 0 10px;
}

.info-body .device-lines {
  display: block;
  margin-top: 4px;
  padding-left: 0.5em;
}

.info-body h3 {
  margin: 18px 0 8px;
  font-size: 17px;
  font-weight: 400;
}

.song-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.song-list li {
  overflow-wrap: anywhere;
}

.info-close {
  position: absolute;
  top: 68px;
  right: 58px;
  color: #6d6258;
  background: rgba(255, 255, 252, 0.42);
}

@media (max-width: 820px) {
  .app-shell {
    padding: 12px;
  }

  .studio {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .library-panel {
    min-height: auto;
    padding: 16px 6px 0;
  }

  .library-hero-card {
    margin-bottom: 0;
  }

  .library-stack-card {
    margin: -48px 0 -54px;
    min-height: 596px;
    padding: 44px 38px 30px;
  }

  .library-paper-area {
    height: 316px;
    margin: 0;
  }

  .library-envelope-controls {
    margin: 6px 0 0;
  }

  .library-envelope-controls .song-search {
    width: 100%;
  }

  .palette-block,
  .canvas-backgrounds {
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  .fragment-library {
    max-height: 248px;
  }

  .canvas-frame {
    width: 100%;
    padding: 12px;
  }

  .side-actions {
    right: 10px;
    top: auto;
    bottom: 96px;
    transform: none;
  }

  .side-action {
    width: 52px;
    height: 52px;
    font-size: 11px;
  }

  .info-note {
    min-height: min(520px, 78vh);
    padding: 86px 54px 46px;
  }

  .info-close {
    top: 58px;
    right: 42px;
  }

  .song-list {
    grid-template-columns: 1fr;
  }
}
