.rt-tag-book-search {
    position: relative;
    margin: 0 0 18px;
}

.rt-tag-book-search-label {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.rt-tag-book-search-input {
    width: 100%;
    box-sizing: border-box;
    padding: 10px 12px;
    border: 1px solid var(--rt-border);
    border-radius: var(--rt-r2);
    background: var(--rt-card-bg);
    color: var(--rt-text);
    font: inherit;
    font-size: 15px;
}

.rt-tag-book-search-input:focus {
    outline: 2px solid var(--rt-primary);
    outline-offset: 1px;
}

.rt-tag-book-search-results {
    margin-top: 12px;
}

.rt-tag-book-search-status,
.rt-tag-book-search-status-label {
    margin: 0;
    font-size: 13px;
    color: var(--rt-text-muted);
}

.rt-tag-book-search-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.rt-tag-book-search-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 10px;
    border: 1px solid var(--rt-border);
    border-radius: var(--rt-r2);
    background: var(--rt-card-bg);
}

.rt-tag-book-search-cover {
    width: 36px;
    height: 52px;
    flex-shrink: 0;
    border-radius: 4px;
    overflow: hidden;
    background: var(--rt-surface2);
}

.rt-tag-book-search-cover img,
.rt-tag-book-search-ph {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rt-tag-book-search-info {
    flex: 1;
    min-width: 0;
}

.rt-tag-book-search-title {
    font-weight: 600;
    color: var(--rt-text);
    line-height: 1.3;
}

.rt-tag-book-search-author {
    margin-top: 2px;
    font-size: 13px;
    color: var(--rt-text-muted);
}

.rt-tag-book-search-status-label {
    margin-top: 2px;
}

.rt-as-card.rt-tag-book-card {
    position: relative;
    padding-right: 40px;
}

.rt-tag-book-remove {
    position: absolute;
    z-index: 2;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    border: 1px solid var(--rt-border);
    border-radius: 50%;
    background: var(--rt-card-bg);
    color: var(--rt-text);
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    padding: 0;
}

.rt-tag-book-remove:hover:not(:disabled) {
    border-color: var(--rt-primary);
    color: var(--rt-primary);
}

.rt-tag-book-remove:focus {
    outline: 2px solid var(--rt-primary);
    outline-offset: 1px;
}

.rt-tag-book-remove:disabled {
    cursor: not-allowed;
    opacity: 0.4;
}

.rt-tag-books-heading {
    margin: 0 0 8px;
    font-size: 16px;
    color: var(--rt-text);
}

@media (max-width: 600px) {
    .rt-tag-book-search-card {
        flex-wrap: wrap;
    }

    .rt-tag-book-search-card .rt-tag-book-add {
        width: 100%;
    }
}
