.md-filter-dependent {
    visibility: hidden;
}

/* These intermediate wrappers preserve the theme's flex/grid layout. */
[data-md-filter-view="rank"] [data-md-filter-results],
[data-md-filter-view="library-desktop"] [data-md-filter-results] {
    display: contents;
}

[data-md-filter-results].md-filter-pending > :not(.md-filter-skeleton) {
    display: none !important;
}

.md-filter-skeleton {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 8px;
    padding: 10px 8px;
    color: rgba(135, 135, 145, .18);
}

.md-filter-skeleton > span {
    display: block;
    aspect-ratio: 16 / 10;
    border-radius: 5px;
    background: linear-gradient(to bottom, currentColor 78%, transparent 78%,
        transparent 87%, currentColor 87%, currentColor 95%, transparent 95%);
}

[data-md-filter-view="library-desktop"] .md-filter-skeleton {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    padding: 12px 0;
}

[data-md-filter-view="rank"] .md-filter-skeleton {
    max-width: 600px;
    margin: auto;
    padding-top: 18px;
}

[data-md-filter-view="drama-desktop"] .md-filter-skeleton { padding: 0; }
[data-md-filter-view="drama-desktop"] .md-filter-skeleton > span { aspect-ratio: 3 / 4; }
@media (min-width: 680px) {
    [data-md-filter-view="drama-desktop"] .md-filter-skeleton { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
    [data-md-filter-view="drama-desktop"] .md-filter-skeleton { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}
