/* assets/css/style.css */

.pbm-dashboard {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.pbm-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.pbm-stat-card {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    text-align: center;
}

.pbm-stat-card h3 {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.pbm-stat-number {
    font-size: 32px;
    font-weight: bold;
    color: #2196F3;
}

.pbm-book-form {
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.pbm-form-group {
    margin-bottom: 20px;
}

.pbm-form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #333;
}

.pbm-form-group input,
.pbm-form-group select,
.pbm-form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.pbm-form-group textarea {
    height: 100px;
    resize: vertical;
}

.pbm-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.pbm-isbn-search {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.pbm-isbn-search input {
    flex: 1;
}

.pbm-button {
    background: #2196F3;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
}

.pbm-button:hover {
    background: #1976D2;
}

.pbm-button.secondary {
    background: #666;
}

.pbm-button.secondary:hover {
    background: #555;
}

.pbm-search-results {
    display: none;
    background: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 20px;
    margin-bottom: 20px;
}

.pbm-search-result {
    display: flex;
    gap: 15px;
    padding: 15px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
    transition: background-color 0.3s;
}

.pbm-search-result:hover {
    background: #f5f5f5;
}

.pbm-search-result img {
    width: 60px;
    height: 80px;
    object-fit: cover;
}

.pbm-search-result-info h4 {
    margin: 0 0 5px 0;
    color: #333;
}

.pbm-search-result-info p {
    margin: 0;
    color: #666;
    font-size: 13px;
}

.pbm-library {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.pbm-filters {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.pbm-filter-form {
    display: flex;
    gap: 20px;
    align-items: end;
    flex-wrap: wrap;
}

.pbm-filter-group {
    flex: 1;
    min-width: 150px;
}

.pbm-filter-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #333;
}

.pbm-filter-group select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.pbm-filter-button {
    background: #2196F3;
    color: white;
    padding: 8px 16px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    height: fit-content;
}

.pbm-books-grid {
    display: grid;
    gap: 20px;
    margin-bottom: 30px;
}

.pbm-books-grid.grid {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
}

.pbm-books-grid.list {
    grid-template-columns: 1fr;
}

.pbm-book-card {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}

.pbm-book-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.pbm-books-grid.grid .pbm-book-card {
    display: flex;
    flex-direction: column;
}

.pbm-books-grid.list .pbm-book-card {
    display: flex;
    flex-direction: row;
}

.pbm-book-cover {
    flex-shrink: 0;
}

.pbm-books-grid.grid .pbm-book-cover {
    height: 200px;
    overflow: hidden;
}

.pbm-books-grid.list .pbm-book-cover {
    width: 120px;
    height: 160px;
}

.pbm-book-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pbm-book-details {
    padding: 20px;
    flex: 1;
}

.pbm-book-title {
    margin: 0 0 10px 0;
    font-size: 16px;
    color: #333;
    line-height: 1.3;
}

.pbm-book-author {
    margin: 0 0 10px 0;
    color: #666;
    font-size: 14px;
}

.pbm-book-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.pbm-book-status {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.pbm-status-reading {
    background: #E3F2FD;
    color: #1976D2;
}

.pbm-status-completed {
    background: #E8F5E8;
    color: #2E7D32;
}

.pbm-status-want_to_read {
    background: #FFF3E0;
    color: #F57C00;
}

.pbm-status-paused {
    background: #FCE4EC;
    color: #C2185B;
}

.pbm-book-rating {
    display: flex;
    gap: 2px;
}

.pbm-star {
    color: #ddd;
    font-size: 14px;
}

.pbm-star.filled {
    color: #FFD700;
}

.pbm-book-pages {
    margin: 0;
    color: #666;
    font-size: 12px;
}

.pbm-book-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.pbm-book-actions button {
    flex: 1;
    padding: 6px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: white;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.3s;
}

.pbm-book-actions button:hover {
    background: #f5f5f5;
}

.pbm-edit-book {
    background: #2196F3 !important;
    color: white !important;
    border-color: #2196F3 !important;
}

.pbm-edit-book:hover {
    background: #1976D2 !important;
}

.pbm-delete-book {
    background: #f44336 !important;
    color: white !important;
    border-color: #f44336 !important;
}

.pbm-delete-book:hover {
    background: #d32f2f !important;
}

.pbm-no-books {
    text-align: center;
    padding: 60px 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.pbm-no-books p {
    font-size: 18px;
    color: #666;
    margin-bottom: 20px;
}

.pbm-pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
}

.pbm-pagination a,
.pbm-pagination span {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-decoration: none;
    color: #333;
    transition: all 0.3s;
}

.pbm-pagination a:hover {
    background: #f5f5f5;
}

.pbm-pagination .current {
    background: #2196F3;
    color: white;
    border-color: #2196F3;
}

.pbm-statistics {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.pbm-top-author {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 30px;
    text-align: center;
}

.pbm-monthly-chart {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.pbm-note-form {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.pbm-note-form textarea {
    width: 100%;
    height: 80px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    resize: vertical;
}

.pbm-notes-list {
    space-y: 15px;
}

.pbm-note-item {
    background: #fff;
    padding: 15px;
    border-radius: 8px;
    border-left: 4px solid #2196F3;
    margin-bottom: 15px;
}

.pbm-note-item.quote {
    border-left-color: #4CAF50;
}

.pbm-note-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    font-size: 12px;
    color: #666;
}

.pbm-note-content {
    margin: 0;
    color: #333;
    line-height: 1.6;
}

.pbm-note-actions {
    margin-top: 10px;
}

.pbm-note-actions button {
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    font-size: 12px;
    padding: 4px 8px;
    border-radius: 4px;
    transition: background-color 0.3s;
}

.pbm-note-actions button:hover {
    background: #f5f5f5;
}

.pbm-loading {
    text-align: center;
    padding: 20px;
    color: #666;
}

.pbm-error {
    background: #ffebee;
    color: #c62828;
    padding: 15px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.pbm-success {
    background: #e8f5e8;
    color: #2e7d32;
    padding: 15px;
    border-radius: 4px;
    margin-bottom: 20px;
}

@media (max-width: 768px) {
    .pbm-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .pbm-form-row {
        grid-template-columns: 1fr;
    }
    
    .pbm-filter-form {
        flex-direction: column;
    }
    
    .pbm-filter-group {
        min-width: auto;
    }
    
    .pbm-books-grid.grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
    
    .pbm-books-grid.list .pbm-book-card {
        flex-direction: column;
    }
    
    .pbm-books-grid.list .pbm-book-cover {
        width: 100%;
        height: 200px;
    }
    
    .pbm-book-actions {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .pbm-stats-grid {
        grid-template-columns: 1fr;
    }
    
    .pbm-books-grid.grid {
        grid-template-columns: 1fr;
    }
}
