/* TAMPILAN DASAR */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #c4cdda;
    color: #333;
}

header {
    background-color: #e4610f;
    color: white;
    padding: 20px 0;
    text-align: center;
}

.header-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

/* Style Logo */
.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 26px;
    font-weight: bold;
    color: #3498db;
}

.logo svg {
    stroke: #3498db;
}

header p {
    margin: 0;
    font-size: 14px;
    color: #bdc3c7;
}

.container {
    max-width: 950px;
    margin: 20px auto;
    padding: 0 20px;
}

/* Pencarian & Filter Box */
.search-filter-box {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.search-filter-box input {
    flex: 2;
    min-width: 200px;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 15px;
}

.search-filter-box select {
    flex: 1;
    min-width: 150px;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 15px;
    background-color: white;
    cursor: pointer;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.info-count {
    color: #555;
    font-size: 14px;
}

/* Grid & Kartu Buku */
.book-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.book-card {
    background-color: white;
    border-radius: 8px;
    padding: 15px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.08);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
}

/* Gambar Sampul Buku */
.book-cover {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 6px;
    margin-bottom: 12px;
    background-color: #eee;
}

.book-card h3 {
    margin: 8px 0 4px 0;
    color: #2c3e50;
    font-size: 17px;
}

.book-card p {
    color: #666;
    font-size: 13px;
    margin: 0 0 12px 0;
}

/* Badge Kategori & Status */
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.badge {
    display: inline-block;
    background-color: #e0f2fe;
    color: #0369a1;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: bold;
}

.status-badge {
    font-size: 11px;
    font-weight: bold;
    padding: 3px 6px;
    border-radius: 4px;
}

.status-tersedia {
    background-color: #dcfce7;
    color: #15803d;
}

.status-dipinjam {
    background-color: #fee2e2;
    color: #b91c1c;
}

/* Tombol Aksi */
.action-buttons {
    display: flex;
    gap: 8px;
    margin-top: 10px;
}

.btn-pinjam {
    flex: 2;
    background-color: #27ae60;
    color: white;
    border: none;
    padding: 10px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
    font-size: 13px;
}

.btn-pinjam:disabled {
    background-color: #bdc3c7;
    cursor: not-allowed;
}

.btn-detail {
    flex: 1;
    background-color: #3498db;
    color: white;
    border: none;
    padding: 10px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
}

/* Borrowed Section */
.borrowed-section {
    margin-top: 40px;
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.08);
}

.borrowed-list {
    list-style: none;
    padding: 0;
}

.borrowed-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
}

.btn-kembali {
    background-color: #e74c3c;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}

/* Modal Pop-Up */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    justify-content: center;
    align-items: center;
    z-index: 999;
}

.modal-content {
    background-color: white;
    padding: 25px;
    border-radius: 8px;
    max-width: 600px;
    width: 90%;
    position: relative;
}

.modal-body {
    display: flex;
    gap: 20px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.modal-cover {
    width: 140px;
    height: 200px;
    object-fit: cover;
    border-radius: 6px;
}

.modal-info {
    flex: 1;
    min-width: 200px;
}

.close-btn {
    position: absolute;
    right: 15px;
    top: 10px;
    font-size: 24px;
    cursor: pointer;
    color: #888;
}

.ringkasan-text {
    background-color: #f8f9fa;
    padding: 10px;
    border-left: 4px solid #3498db;
    border-radius: 4px;
    font-size: 13px;
    line-height: 1.5;
}