@media (max-width: 900px) {
  html.android-library-note-open body > .app-header,
  html.android-library-note-open body > .app-shell,
  html.android-library-note-open body > .mobile-tabbar,
  html.android-library-note-open body > .listen-backdrop { filter: blur(5px); }
  .android-library-note-actions { display: flex; justify-content: flex-end; margin-top: 2px; }
  .android-library-note-button {
    display: flex; align-items: center; justify-content: center; min-height: 44px; padding: 6px 10px;
    border: 1px solid transparent; border-radius: 8px; background: transparent; color: var(--accent-dark);
    font: inherit; font-size: 12px; font-weight: 600; cursor: pointer;
  }
  .android-library-note-button svg { flex: none; width: 18px; height: 18px; margin-right: 6px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
  .android-library-note-button.has-notes,
  .android-library-note-button[aria-expanded="true"] { background: var(--accent-soft); border-color: var(--line); }
  .android-library-note-button:focus-visible { outline: 2px solid var(--accent-dark); outline-offset: 2px; }
  html:root .library-screen .library-song-entry {
    padding: 10px; margin-bottom: 10px; border: 1px solid var(--line); border-radius: 8px;
    background: var(--panel); box-shadow: 0 2px 8px rgba(0,0,0,.035);
  }
  html:root .library-screen .library-song-entry .mobile-list-main { min-height: 62px; padding-right: 40px; }
  html:root .library-screen .library-song-layout {
    grid-template-columns: 56px minmax(0,1fr); grid-template-rows: auto;
    grid-column-gap: 10px; min-height: 62px;
  }
  html:root .library-screen .library-song-entry .mobile-list-art {
    grid-column: 1; grid-row: 1; width: 56px; height: 56px; border: 0; border-radius: 6px;
  }
  html:root .library-screen .library-song-entry .mobile-list-copy { grid-column: 2; grid-row: 1; }
  html:root .library-screen .library-song-entry .mobile-list-copy strong {
    font-size: 16px; line-height: 1.35; word-wrap: break-word;
  }
  html:root .library-screen .library-song-entry .mobile-list-copy small {
    margin-top: 3px; font-size: 14px; line-height: 1.4; word-wrap: break-word;
  }
  html:root .library-screen .library-song-entry .mobile-list-more {
    top: 0; right: 5px; width: 44px; height: 44px; border-radius: 6px; color: var(--muted);
  }
  html:root .library-screen .android-library-note-actions {
    position: static; display: flex; justify-content: flex-end;
    align-items: center; margin: 2px 0 0; padding: 0; border: 0;
  }
  html:root .library-screen .library-song-entry .mobile-list-copy .mobile-list-meta {
    display: block; max-width: none; margin: 5px 0 0;
    color: var(--muted); font-size: 9px; line-height: 1.4; text-align: left; word-wrap: break-word;
  }
  html:root .library-screen #libraryCapacity {
    margin: 8px 4px 10px; color: var(--muted); font-size: 11px; font-weight: 600; line-height: 1.4; text-align: right;
  }
  html:root .library-screen .android-library-note-actions .android-library-note-button {
    position: relative; width: 82px; min-width: 82px; min-height: 44px; padding: 0 7px;
    border: 0; border-radius: 6px; background: transparent; color: var(--accent-dark); font-size: 10px; font-weight: 600;
  }
  html:root .library-screen .android-library-note-button::before {
    position: absolute; top: 50%; right: 0; left: 0; height: 28px; transform: translateY(-50%);
    border: 1px solid rgba(230,124,36,.18); border-radius: 6px; background: var(--accent-soft); content: "";
  }
  html:root .library-screen .android-library-note-button > svg,
  html:root .library-screen .android-library-note-button > span { position: relative; }
  html:root .library-screen .android-library-note-button > span { white-space: nowrap; }
  html:root .library-screen .android-library-note-button svg { width: 14px; height: 14px; margin-right: 4px; stroke-width: 1.6; }
  html:root .library-screen .android-library-note-button.has-notes::before { border-color: rgba(230,124,36,.25); }
  html:root .library-screen .android-library-collection-button {
    position: relative; display: flex; align-items: center; justify-content: center;
    flex: none; min-width: 82px; min-height: 44px; padding: 0 7px; margin-right: 6px;
    border: 0; border-radius: 6px; background: transparent; color: var(--muted);
    font: inherit; font-size: 10px; font-weight: 600; cursor: pointer;
  }
  html:root .library-screen .android-library-collection-button::before {
    position: absolute; top: 50%; right: 0; left: 0; height: 28px; transform: translateY(-50%);
    border: 1px solid var(--line); border-radius: 6px; background: var(--panel-strong); content: "";
  }
  html:root .library-screen .android-library-collection-button > svg,
  html:root .library-screen .android-library-collection-button > span { position: relative; }
  html:root .library-screen .android-library-collection-button svg {
    flex: none; width: 14px; height: 14px; margin-right: 4px; fill: none; stroke: currentColor;
    stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round;
  }
  html:root .library-screen .android-library-collection-button[data-list-action="favorite"] { width: 44px; min-width: 44px; padding: 0; }
  html:root .library-screen .android-library-collection-button[data-list-action="favorite"] svg { width: 17px; height: 17px; margin: 0; }
  html:root .library-screen .android-library-collection-button[aria-pressed="true"] { color: var(--accent-dark); }
  html:root .library-screen .android-library-collection-button[aria-pressed="true"]::before { border-color: rgba(230,124,36,.25); background: var(--accent-soft); }
  html:root .library-screen .android-library-collection-button[data-list-action="favorite"][aria-pressed="true"] svg { fill: currentColor; }
  html:root .library-screen .android-library-collection-button:focus-visible { outline: 2px solid var(--accent-dark); outline-offset: 2px; }
  html:root .library-screen .android-library-collection-button:disabled { opacity: .5; cursor: default; }
  html:root .library-screen .android-library-collection-button:active::before { background: var(--accent-soft); }
  html:root .library-screen .android-library-note-button:active::before,
  html:root .library-screen .mobile-list-more:active { background: var(--panel-strong); }
  .android-library-note-dialog:not([open]) { display: none; }
  .android-library-note-dialog[open] {
    position: fixed; top: 50%; right: auto; bottom: auto; left: 50%; z-index: 500;
    width: calc(100% - 28px); max-width: 420px; max-height: calc(100vh - 28px);
    margin: 0; padding: 14px; overflow-y: auto; transform: translate(-50%, -50%);
    border: 1px solid var(--line); border-radius: 14px; background: var(--panel); color: var(--text);
    box-shadow: 0 18px 60px rgba(0,0,0,.24);
  }
  .android-library-note-dialog::backdrop { background: rgba(12,20,25,.42); }
  .android-note-backdrop-art { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; opacity: .07; pointer-events: none; border-radius: 13px; }
  :root[data-theme="dark"] .android-note-backdrop-art { opacity: .13; }
  .android-library-note-dialog form { position: relative; display: grid; grid-row-gap: 10px; }
  .android-library-note-dialog header { display: flex; align-items: center; }
  .android-note-heading-icon { position: relative; display: flex; align-items: center; justify-content: center; flex: none; width: 60px; height: 60px; margin-right: 12px; border-radius: 9px; overflow: hidden; background: var(--accent-soft); color: var(--accent-dark); }
  .android-note-cover { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: contain; background: var(--panel); }
  .android-library-note-dialog svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
  .android-library-note-dialog header > div { flex: 1; min-width: 0; }
  .android-library-note-dialog h2 { margin: 0 0 4px; color: var(--accent-dark); font-size: 11px; font-weight: 750; }
  .android-library-note-dialog header p { margin: 3px 0 0; color: var(--muted); font-size: 12px; line-height: 1.4; overflow-wrap: anywhere; }
  .android-library-note-dialog #androidLibraryNoteSong { margin: 0; color: var(--text); font-size: 17px; font-weight: 750; line-height: 1.25; word-wrap: break-word; }
  .android-library-note-dialog #androidLibraryNoteArtist { word-wrap: break-word; }
  .android-library-note-dialog button { display: flex; align-items: center; justify-content: center; min-height: 44px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel-strong); color: var(--text); padding: 8px 12px; font: inherit; font-size: 12px; font-weight: 650; cursor: pointer; }
  .android-library-note-dialog .android-note-close { flex: none; width: 44px; margin-left: 8px; padding: 0; border: 0; background: transparent; color: var(--muted); }
  .android-library-note-dialog textarea { display: block; width: 100%; min-width: 0; min-height: 132px; max-height: 40vh; padding: 10px; resize: vertical; border: 1px solid var(--line); border-radius: 8px; background: var(--field); color: var(--text); font: inherit; font-size: 15px; line-height: 1.6; }
  :root[data-theme="light"] .android-library-note-dialog textarea { background: rgba(255,255,255,.78); }
  :root[data-theme="dark"] .android-library-note-dialog textarea { background: rgba(11,16,21,.82); }
  .android-library-note-dialog textarea::placeholder { color: var(--muted); }
  .android-library-note-dialog textarea:focus { outline: 2px solid var(--focus-ring); border-color: var(--accent-dark); }
  #androidLibraryNoteStatus { min-height: 16px; margin: 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
  #androidLibraryNoteStatus:empty { display: none; }
  .android-library-note-dialog footer { display: flex; align-items: center; }
  .android-library-note-dialog output { flex: 1; color: var(--muted); font-size: 10px; }
  .android-library-note-dialog footer button { margin-left: 7px; }
  .android-library-note-dialog .android-note-save { border-color: var(--accent); background: var(--accent); color: #211007; }
  .android-note-save svg { width: 17px; height: 17px; margin-right: 5px; }
  .android-library-note-dialog button:disabled { opacity: .5; cursor: default; }
  .android-library-note-dialog [hidden] { display: none !important; }
  .android-library-note-dialog button:focus-visible { outline: 2px solid var(--accent-dark); outline-offset: 2px; }
}
