/* /home/e-library.top/public_html/wp-content/themes/astra-child/style.css */

.e-library-search-filter {
    margin-bottom: 20px;
}

.search-row {
    display: flex;
    width: 100%;
    max-width: 700px;
    margin: 0 auto;
    gap: 10px;
    margin-bottom: 15px;
}

.search-row input[type="text"] {
    flex: 1;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box;
}

.search-row button {
    padding: 8px 15px;
    background-color: #0073aa;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.search-row button:hover {
    background-color: #005d82;
}

.filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
}

.filter-row label {
    display: flex;
    align-items: center;
    gap: 5px;
}

.filter-row input[type="checkbox"] {
    margin: 0;
}

/* Đảm bảo full width cho kết quả tìm kiếm */
.library-search-results {
    width: 100%;
    max-width: 100%;
    padding: 20px;
    box-sizing: border-box;
}

/* Căn giữa tiêu đề Search Results */
.search-results-title {
    text-align: center;
    margin-bottom: 20px;
}

/* Định dạng bảng kết quả */
.library-results-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
    font-size: 14px;
}

.library-results-table th,
.library-results-table td {
    padding: 3px;
    text-align: left;
    vertical-align: top;
}

.library-results-table th {
    background-color: #f5f5f5;
    font-weight: bold;
}

/* Xen kẽ màu nền xám nhạt */
.library-results-table tbody tr:nth-child(even) {
    background-color: #ebebeb;
}

/* Định dạng cột Series / Title / ISBN */
.library-results-table .series,
.library-results-table .isbn,
.library-results-table .volume-edition {
    color: #008000; /* Xanh lá cây */
    font-style: italic;
    font-size: 13px;
    line-height: 1.2;
}

.library-results-table .title {
    font-size: 16px; /* Title 12px */
    line-height: 1.4;
}

.library-results-table .title a {
    text-decoration: none;
    color: #0029ff;
}

.library-results-table .title a:hover {
    text-decoration: underline;
}

/* Định dạng phân trang */
.pagination-wrapper {
    text-align: center;
    margin-top: 20px;
}

.pagination-wrapper .nav-links {
    display: inline-block;
}

.pagination-wrapper .page-numbers {
    font-size: 16px;
    font-weight: bold;
    margin: 0 8px;
    text-decoration: none;
    color: #0073aa;
}

.pagination-wrapper .page-numbers.current {
    color: #000;
}

.pagination-wrapper .page-numbers:hover {
    text-decoration: underline;
}

.pagination-wrapper .page-numbers.dots {
    margin: 0 4px;
}

/* border color plugin e-library-search */
.library-results-table,
.library-results-table td,
.library-results-table th {
    border: 1px solid #e9e9e9 !important;
}

@keyframes colorChange {
    0% { color: #ff0000; }   /* Đỏ */
    15% { color: #ff8000; }  /* Cam */
    30% { color: #ffff00; }  /* Vàng */
    45% { color: #80ff00; }  /* Xanh lá non */
    60% { color: #00ffff; }  /* Xanh dương nhạt */
    75% { color: #0080ff; }  /* Xanh dương đậm */
    90% { color: #8000ff; }  /* Tím */
    100% { color: #ff0000; } /* Quay lại đỏ */
}

/* Căn giữa No results found */
.library-search-results p {
    text-align: center;
    margin: 20px 0;
    animation: colorChange 3s infinite alternate;
    font-size: 22px;
}

/* CSS cho search mode và tooltip (tách từ e_library_search_styles) */
.e-library-search-filter .search-mode-row {
    text-align: center;
    margin-bottom: 10px;
}
.e-library-search-filter .search-mode-row label {
    margin: 0 15px;
}
.e-library-search-filter label span[title] {
    cursor: help;
    color: #0073aa;
    margin-left: 5px;
}
.e-library-search-filter label span[title]:hover:after {
    content: attr(title);
    position: absolute;
    background: #333;
    color: #fff;
    padding: 5px;
    border-radius: 3px;
    z-index: 10;
    font-size: 12px;
    white-space: nowrap;
}
.e-library-search-filter .search-row {
    margin-bottom: 10px;
}
.e-library-search-filter .filter-row {
    margin-top: 10px;
}