/* Global Styles */
:root {
    --primary-color: #2C3E50;    /* Deep Blue */
    --secondary-color: #E74C3C;  /* Coral Red */
    --accent-color: #3498DB;     /* Bright Blue */
    --text-color: #2C3E50;       /* Dark Blue */
    --light-bg: #ECF0F1;         /* Light Gray */
    --gradient-start: #2C3E50;   /* Deep Blue */
    --gradient-end: #3498DB;     /* Bright Blue */
    --button-gradient-start: #3498DB;  /* Bright Blue */
    --button-gradient-end: #2C3E50;    /* Deep Blue */
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--light-bg);
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', serif;
}

/* Page Header */
.page-header {
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end)),
                                url('../images/bg-image.jpg');
    background-size: cover;
    background-position: center;
    background-blend-mode: overlay;
    padding: 120px 0 60px;
    color: white;
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(44, 62, 80, 0.9), rgba(52, 152, 219, 0.9));
    z-index: 1;
}

.page-header .container {
    position: relative;
    z-index: 2;
}

/* Search Box */
.search-box {
    position: relative;
    margin: 2rem 0;
}

.search-box input {
    padding: 1rem 3rem 1rem 1.5rem;
    border-radius: 50px;
    border: 2px solid rgba(0,0,0,0.1);
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.search-box input:focus {
    border-color: var(--accent-color);
    box-shadow: 0 5px 20px rgba(52, 152, 219, 0.2);
}

.search-box i {
    position: absolute;
    right: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--accent-color);
}

/* Book Cards */
.book-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 2rem;
}

.book-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.book-cover-wrapper {
    position: relative;
    overflow: hidden;
    padding-top: 150%;
}

.book-cover {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.book-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.book-card:hover .book-overlay {
    opacity: 1;
}

.book-info {
    padding: 1.5rem;
}

.book-info h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

.book-info .author {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.rating {
    color: #FFD700;
    font-size: 0.9rem;
}

.rating span {
    color: #666;
    margin-left: 0.5rem;
}

/* Detailed Reviews */
.review-section {
    background: white;
    border-radius: 20px;
    padding: 3rem;
    margin-bottom: 3rem;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

.book-cover-large {
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.review-content h2 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.review-content .lead {
    color: #666;
    margin-bottom: 1.5rem;
}

.key-takeaways {
    background: var(--light-bg);
    padding: 1.5rem;
    border-radius: 10px;
    margin: 1.5rem 0;
}

.key-takeaways h4 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.key-takeaways ul {
    margin-bottom: 0;
    padding-left: 1.5rem;
}

.key-takeaways li {
    margin-bottom: 0.5rem;
}

.review-meta {
    margin-top: 1.5rem;
}

.review-meta .badge {
    margin-right: 0.5rem;
    padding: 0.5rem 1rem;
    font-weight: 500;
}

/* Navigation */
.navbar {
    background: linear-gradient(to right, var(--primary-color), var(--accent-color)) !important;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
    padding: 1rem 0;
}

.navbar-brand {
    font-family: 'Playfair Display', serif;
    font-weight: bold;
    font-size: 1.5rem;
    color: white !important;
}

.nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    transition: color 0.3s ease;
    font-weight: 500;
}

.nav-link:hover {
    color: var(--secondary-color) !important;
}

/* Footer */
footer {
    background: linear-gradient(to right, var(--primary-color), var(--accent-color));
    color: white;
    padding: 4rem 0 2rem;
}

footer h5 {
    font-family: 'Playfair Display', serif;
    margin-bottom: 1.5rem;
}

footer a {
    color: rgba(255, 255, 255, 0.9) !important;
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--secondary-color) !important;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.book-card, .review-section {
    animation: fadeIn 0.5s ease-out;
}

/* Responsive Design */
@media (max-width: 768px) {
    .page-header {
        padding: 100px 0 40px;
        text-align: center;
    }
    
    .book-cover-wrapper {
        padding-top: 120%;
    }
    
    .review-section {
        padding: 2rem;
    }
    
    .book-cover-large {
        margin-bottom: 2rem;
    }
}

/* Book Details Page */
.book-details {
    padding: 2rem 0;
}

.book-details .review-section {
    margin-bottom: 4rem;
    padding: 2rem;
    background: white;
    border-radius: 20px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    transition: transform 0.3s ease;
}

.book-details .review-section:hover {
    transform: translateY(-5px);
}

.book-details .book-cover-large {
    position: relative;
    overflow: hidden;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.book-details .book-cover-large img {
    width: 100%;
    height: auto;
    transition: transform 0.3s ease;
}

.book-details .review-section:hover .book-cover-large img {
    transform: scale(1.02);
}

.book-details .review-content {
    padding: 1rem;
}

.book-details .review-content h2 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: 2.5rem;
}

.book-details .review-content .lead {
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 1.5rem;
}

.book-details .key-takeaways {
    background: var(--light-bg);
    padding: 2rem;
    border-radius: 15px;
    margin: 1.5rem 0;
}

.book-details .key-takeaways h4 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

.book-details .key-takeaways ul {
    margin-bottom: 0;
    padding-left: 1.5rem;
}

.book-details .key-takeaways li {
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.book-details .book-summary {
    margin: 2rem 0;
    padding: 2rem;
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.book-details .book-summary h4 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

.book-details .book-summary p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #555;
}

.book-details .review-meta {
    margin-top: 2rem;
}

.book-details .review-meta .badge {
    padding: 0.8rem 1.5rem;
    font-size: 1rem;
    margin-right: 1rem;
    border-radius: 50px;
}

/* Responsive Design for Book Details */
@media (max-width: 768px) {
    .book-details .review-section {
        padding: 1.5rem;
    }

    .book-details .review-content h2 {
        font-size: 2rem;
    }

    .book-details .book-cover-large {
        margin-bottom: 2rem;
    }

    .book-details .key-takeaways,
    .book-details .book-summary {
        padding: 1.5rem;
    }
}

/* Books Horizontal Scroll */
.books-scroll-container {
    width: 100%;
    overflow: hidden;
    position: relative;
    padding: 20px 0;
}

.books-scroll {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 20px 0;
}

/* Horizontal Book Card */
.book-card-horizontal {
    display: flex;
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 200px;
}

.book-card-horizontal:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.book-card-horizontal .book-image {
    flex: 0 0 150px;
    position: relative;
    overflow: hidden;
}

.book-card-horizontal .book-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.book-card-horizontal:hover .book-image img {
    transform: scale(1.05);
}

.book-card-horizontal .book-content {
    flex: 1;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.book-card-horizontal .book-content h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

.book-card-horizontal .book-content .author {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.book-card-horizontal .book-content .rating {
    color: #FFD700;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.book-card-horizontal .book-content .book-description {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.book-card-horizontal .book-action {
    flex: 0 0 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background: var(--light-bg);
}

.book-card-horizontal .book-action .btn {
    width: 100%;
    padding: 0.75rem 1rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.book-card-horizontal .book-action .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

/* Responsive adjustments for horizontal cards */
@media (max-width: 768px) {
    .book-card-horizontal {
        height: auto;
        flex-direction: column;
    }

    .book-card-horizontal .book-image {
        flex: 0 0 200px;
    }

    .book-card-horizontal .book-content {
        padding: 1rem;
    }

    .book-card-horizontal .book-action {
        flex: 0 0 auto;
        padding: 1rem;
    }
}

/* Books Table View */
.books-table {
    width: 100%;
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    overflow: hidden;
}

.book-row {
    display: flex;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid #eee;
    transition: background-color 0.3s ease;
}

.book-row:last-child {
    border-bottom: none;
}

.book-row:hover {
    background-color: #f8f9fa;
}

.book-row .book-image {
    flex: 0 0 100px;
    margin-right: 1.5rem;
}

.book-row .book-image img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
}

.book-row .book-content {
    flex: 1;
    padding-right: 1.5rem;
}

.book-row .book-content h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

.book-row .book-content .author {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.book-row .book-content .rating {
    color: #FFD700;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.book-row .book-content .book-description {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.book-row .book-action {
    flex: 0 0 120px;
    text-align: center;
}

.book-row .book-action .btn {
    width: 100%;
    padding: 0.75rem 1rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.book-row .book-action .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

/* Responsive adjustments for table view */
@media (max-width: 768px) {
    .book-row {
        flex-direction: column;
        text-align: center;
        padding: 1rem;
    }

    .book-row .book-image {
        margin: 0 0 1rem 0;
    }

    .book-row .book-content {
        padding-right: 0;
        margin-bottom: 1rem;
    }

    .book-row .book-action {
        width: 100%;
    }
}

/* Custom Button Styles */
.btn-primary {
    background: linear-gradient(135deg, var(--button-gradient-start), var(--button-gradient-end));
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 50px;
    font-weight: 500;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.2);
    position: relative;
    overflow: hidden;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.3);
    background: linear-gradient(135deg, var(--button-gradient-end), var(--button-gradient-start));
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        120deg,
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    transition: 0.5s;
}

.btn-primary:hover::before {
    left: 100%;
}

/* Buy Now Button Styles */
.btn-buy {
    background: linear-gradient(45deg, #ff4b2b, #ff416c);
    color: white;
    padding: 12px 30px;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 75, 43, 0.3);
    position: relative;
    overflow: hidden;
    display: inline-block;
}

.btn-buy:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 75, 43, 0.4);
    color: white;
    background: linear-gradient(45deg, #ff416c, #ff4b2b);
}

.btn-buy:active {
    transform: translateY(1px);
}

.btn-buy::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        120deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent
    );
    transition: 0.5s;
}

.btn-buy:hover::before {
    left: 100%;
}

.btn-buy i {
    margin-right: 8px;
    font-size: 1.1em;
    vertical-align: middle;
}

/* Book Action Buttons Container */
.book-action-buttons {
    display: flex;
    gap: 15px;
    align-items: center;
    margin: 25px 0;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .btn-buy {
        padding: 10px 25px;
        font-size: 0.9em;
    }
    
    .book-action-buttons {
        flex-direction: column;
        align-items: stretch;
    }
}

/* Animation for button hover */
@keyframes pulse {
    0% {
        box-shadow: 0 4px 15px rgba(255, 75, 43, 0.3);
    }
    50% {
        box-shadow: 0 6px 20px rgba(255, 75, 43, 0.4);
    }
    100% {
        box-shadow: 0 4px 15px rgba(255, 75, 43, 0.3);
    }
}

.btn-buy:hover {
    animation: pulse 1.5s infinite;
} 