/* Final phone rules: intrinsic sizing must not shrink the whole page. */
@media (max-width: 820px) {
  html:has(body.nasheed-refreshed) {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
  }
  body.nasheed-refreshed {
    width: 100%;
    min-width: 0;
    max-width: 100%;
  }
  .nasheed-refreshed .nsf-workspace {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin-inline: auto;
    padding-inline: 12px;
  }
  .nasheed-refreshed .nsf-library {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    contain: inline-size;
  }
  .nasheed-refreshed .nsf-tab-row {
    flex-wrap: wrap;
    gap: 8px 14px;
  }
  .nasheed-refreshed .nsf-tab-row #browseTabs {
    flex: 1 1 auto;
    min-width: 0;
    max-width: 100%;
  }
  .nasheed-refreshed .list-wrap,
  .nasheed-refreshed .search-wrap,
  .nasheed-refreshed .search-inner {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
  }
  .nasheed-refreshed #searchInput,
  .nasheed-refreshed input:not([type=range]):not([type=checkbox]):not([type=radio]),
  .nasheed-refreshed textarea,
  .nasheed-refreshed select {
    font-size: 16px;
  }
  .nasheed-refreshed .search-inner { min-height: 50px; }
  .nasheed-refreshed .nsf-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
  }
  .nasheed-refreshed .nsf-filters button {
    flex: 0 1 auto;
    max-width: 100%;
    min-height: 44px;
    padding: 10px 13px;
    font-size: 12px;
    line-height: 1.4;
    white-space: normal;
  }
  .nasheed-refreshed .nsf-verified-legend {
    min-width: 0;
    max-width: 100%;
    margin-inline: 0;
  }
  .nasheed-refreshed .nsf-verified-legend summary { gap: 9px; padding: 12px; }
  .nasheed-refreshed .nsf-verified-legend summary strong {
    min-width: 0;
    font-size: 12px;
    overflow-wrap: anywhere;
  }
  .nasheed-refreshed .nsf-verified-legend summary::after { flex: none; }
  .nasheed-refreshed .nsf-verified-legend-body p { font-size: 13px; }
  .nasheed-refreshed .track {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    grid-template-columns: 30px minmax(0, 1fr) 44px;
    gap: 0 9px;
    min-height: 88px;
    padding: 14px 4px;
  }
  .nasheed-refreshed .track-title-wrap { min-width: 0; max-width: 100%; }
  .nasheed-refreshed .track-title {
    font-size: 18px;
    line-height: 1.5;
    white-space: normal;
    overflow-wrap: anywhere;
  }
  .nasheed-refreshed .nsf-track-meta {
    font-size: 12px;
    line-height: 1.65;
    gap: 5px 7px;
    overflow-wrap: anywhere;
  }
  .nasheed-refreshed .nsf-mini {
    box-sizing: border-box;
    min-width: 0;
    max-width: calc(100% - 20px);
  }
  .nasheed-refreshed .nsf-mini-open { min-width: 0; }
  .nasheed-refreshed .nsf-mini-open strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}
