/* Tambahan CSS Khusus Grid Home Page */
.home-title { text-align: center; margin: 2rem 0; font-family: 'Playfair Display', serif; font-size: 2rem; color: #111827; }
.book-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 20px; margin-bottom: 3rem; }
.book-grid .book-card { display: flex; flex-direction: column; align-items: center; text-align: center; }
.book-grid .book-card img { width: 100%; max-width: 180px; height: auto; border-radius: 6px; box-shadow: 0 4px 6px rgba(0,0,0,0.1); transition: transform 0.2s; }
.book-grid .book-card img:hover { transform: translateY(-4px); }
.book-grid .book-card h4 { margin-top: 12px; font-size: 0.95rem; font-family: 'Inter', sans-serif; color: #374151; }
.book-grid a { text-decoration: none; }

/* Ratings & Reviews Section */
.reviews-section {
    margin-top: 3rem;
    font-family: 'Inter', sans-serif;
}
.reviews-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    color: #1e3a8a; /* Dark blue from the image */
    margin-bottom: 1.5rem;
}

/* Review Input Box */
.review-input-container {
    border: 1px solid #dbeafe;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    background-color: #fff;
}
.review-input-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}
.user-initial-y {
    width: 40px;
    height: 40px;
    background-color: #2563eb;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 1.1rem;
}
.input-header-text {
    display: flex;
    flex-direction: column;
}
.input-header-text span {
    color: #1e3a8a;
    font-weight: 600;
    font-size: 0.9rem;
}
.empty-stars {
    color: #9ca3af;
    font-size: 0.9rem;
    margin-top: 2px;
}
.review-textarea {
    width: 100%;
    border: 1px solid #dbeafe;
    border-radius: 6px;
    padding: 1rem;
    min-height: 90px;
    font-family: inherit;
    resize: vertical;
    margin-bottom: 1rem;
    box-sizing: border-box;
}
.review-textarea::placeholder { color: #9ca3af; }
.review-submit {
    display: flex;
    justify-content: flex-end;
}
.btn-post {
    background-color: #2563eb;
    color: #fff;
    border: none;
    padding: 0.6rem 1.2rem;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: background 0.2s;
}
.btn-post:hover { background-color: #1d4ed8; }

/* Review List Items */
.review-item {
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #f3f4f6;
    margin-bottom: 1.5rem;
}
.review-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.75rem;
}
.review-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}
.review-meta {
    display: flex;
    flex-direction: column;
}
.review-name {
    font-weight: 700;
    color: #1e3a8a;
    font-size: 0.9rem;
}
.review-date {
    color: #60a5fa; /* Light blue date */
    font-size: 0.75rem;
    margin-top: 2px;
}
.review-stars {
    margin-left: auto;
    color: #2563eb;
    font-size: 0.75rem;
}
.review-body {
    color: #4b5563;
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 1rem;
}
.review-actions {
    display: flex;
    gap: 1.5rem;
}
.btn-action {
    background: transparent;
    border: none;
    color: #2563eb;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

/* Load More Button */
.btn-load-more {
    width: 100%;
    background: transparent;
    border: 1px solid #dbeafe;
    color: #2563eb;
    padding: 0.8rem;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    transition: background 0.2s;
}
.btn-load-more:hover { background-color: #f8fafc; }
.review-item.hidden-review {
    display: none;
}

/* =========================================
   RATINGS & REVIEWS SECTION (IMPROVED UI)
   ========================================= */
.reviews-section {
    margin-top: 4rem;
    font-family: 'Inter', sans-serif;
    background: #ffffff;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    border: 1px solid #f3f4f6;
}

.reviews-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    color: #111827;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #f3f4f6;
}

/* Review Input Box (Improved) */
.review-input-container {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 1.25rem;
    margin-bottom: 2.5rem;
    background-color: #f9fafb;
    transition: all 0.2s ease;
}

.review-input-container:focus-within {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    background-color: #ffffff;
}

.review-input-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.user-initial-y {
    width: 42px;
    height: 42px;
    background: linear-gradient(135deg, #2563eb, #1e3a8a);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 1.2rem;
    box-shadow: 0 2px 4px rgba(37, 99, 235, 0.2);
}

.input-header-text {
    display: flex;
    flex-direction: column;
}

.input-header-text span {
    color: #111827;
    font-weight: 600;
    font-size: 0.95rem;
}

.empty-stars {
    color: #d1d5db;
    font-size: 0.9rem;
    margin-top: 4px;
    letter-spacing: 2px;
}

.review-textarea {
    width: 100%;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    padding: 1rem;
    min-height: 100px;
    font-family: inherit;
    font-size: 0.95rem;
    resize: vertical;
    margin-bottom: 1rem;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.review-textarea:focus {
    outline: none;
    border-color: #3b82f6;
}

.review-submit {
    display: flex;
    justify-content: flex-end;
}

.btn-post {
    background-color: #2563eb;
    color: #fff;
    border: none;
    padding: 0.6rem 1.5rem;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s;
    box-shadow: 0 2px 4px rgba(37, 99, 235, 0.2);
}

.btn-post:hover { 
    background-color: #1d4ed8; 
    transform: translateY(-1px);
}

/* Review List Items (Improved) */
.review-item {
    padding: 1.5rem 0;
    border-bottom: 1px solid #f3f4f6;
}

.review-item:last-child {
    border-bottom: none;
}

.review-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.review-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #fff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}

.review-meta {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.review-name {
    font-weight: 600;
    color: #111827;
    font-size: 0.95rem;
}

.review-date {
    color: #6b7280;
    font-size: 0.8rem;
    margin-top: 2px;
}

.review-stars {
    margin-left: auto;
    color: #f59e0b; /* Warna Emas Standar Rating */
    font-size: 0.85rem;
    letter-spacing: 1px;
}

.review-body {
    color: #374151;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1rem;
    margin-left: 3.5rem; /* Menjorok ke dalam sejajar dengan teks nama */
}

.review-actions {
    display: flex;
    gap: 1.5rem;
    margin-left: 3.5rem; /* Menjorok ke dalam */
}

.btn-action {
    background: transparent;
    border: none;
    color: #6b7280;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: color 0.2s;
    padding: 0;
}

.btn-action:hover {
    color: #2563eb;
}

/* Load More Button (Improved) */
.btn-load-more {
    width: 100%;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    color: #334155;
    padding: 0.8rem;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s;
    margin-top: 1rem;
}

.btn-load-more:hover { 
    background-color: #f1f5f9; 
    color: #0f172a;
    border-color: #cbd5e1;
}

.review-item.hidden-review {
    display: none;
}

/* Audiobook Button Style */
.btn-audio {
    background-color: #10b981; /* Warna hijau emerald untuk kesan 'Play/Audio' */
    color: #ffffff;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    margin-top: 0.75rem; /* Memberi jarak dari tombol Download */
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.2);
}

.btn-audio:hover {
    background-color: #059669;
    transform: translateY(-2px);
    color: #ffffff;
}