* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #fff;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.header {
    background: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.nav-logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: #333;
    font-weight: 600;
    font-size: 1.2rem;
}

.nav-logo img {
    width: 32px;
    height: 32px;
    margin-right: 10px;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-link {
    text-decoration: none;
    color: #666;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-link:hover,
.nav-link.active {
    color: #4a90e2;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: #333;
    margin: 3px 0;
    transition: 0.3s;
}

/* Main content */
main {
    margin-top: 70px;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 80px 0;
}

.hero-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.hero-text h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero-text p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.hero-image img {
    width: 100%;
    max-width: 500px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border: none;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 1rem;
}

.btn-primary {
    background: #4a90e2;
    color: white;
}

.btn-primary:hover {
    background: #357abd;
    transform: translateY(-2px);
}

.btn-secondary {
    background: #f8f9fa;
    color: #333;
    border: 1px solid #ddd;
}

.btn-secondary:hover {
    background: #e9ecef;
}

/* Featured Books */
.featured-books {
    padding: 80px 0;
    background: #f8f9fa;
}

.featured-books h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 50px;
    color: #333;
}

.books-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.book-card {
    background: white;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    text-decoration: none;
    color: inherit;
}

.book-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
}

.book-image {
    text-align: center;
    margin-bottom: 20px;
}

.book-image img {
    width: 120px;
    height: 160px;
    border-radius: 5px;
}

.book-card h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: #333;
}

.book-author {
    color: #666;
    font-style: italic;
    margin-bottom: 15px;
}

.book-category {
    background: #4a90e2;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    display: inline-block;
    margin-bottom: 15px;
}

.book-description {
    color: #666;
    line-height: 1.6;
}

/* Categories Preview */
.categories-preview {
    padding: 80px 0;
}

.categories-preview h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 50px;
    color: #333;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.category-card {
    background: white;
    border: 2px solid #f0f0f0;
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s;
}

.category-card:hover {
    border-color: #4a90e2;
    transform: translateY(-3px);
}

.category-card h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: #333;
}

.category-card p {
    color: #666;
}

/* Search and Filter */
.search-filter {
    background: #f8f9fa;
    padding: 30px 0;
}

.search-controls {
    display: flex;
    gap: 20px;
    max-width: 800px;
    margin: 0 auto;
    flex-wrap: wrap;
}

.search-input {
    flex: 1;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    min-width: 200px;
}

.filter-select {
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    background: white;
    min-width: 150px;
}

/* Book Details */
.book-details {
    padding: 50px 0;
}

.book-detail-content {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 50px;
    max-width: 1000px;
    margin: 0 auto;
}

.book-detail-image img {
    width: 100%;
    border-radius: 10px;
}

.book-detail-info h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.book-detail-author {
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 20px;
}

.book-meta {
    margin-bottom: 30px;
}

.book-meta span {
    display: inline-block;
    margin-right: 20px;
    color: #666;
}

.book-description {
    margin-bottom: 30px;
    font-size: 1.1rem;
    line-height: 1.7;
}

.key-takeaways {
    margin-bottom: 30px;
}

.key-takeaways h3 {
    margin-bottom: 15px;
}

.key-takeaways ul {
    list-style: none;
    padding-left: 0;
}

.key-takeaways li {
    padding: 8px 0;
    padding-left: 20px;
    position: relative;
}

.key-takeaways li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #4a90e2;
    font-weight: bold;
}

.external-links {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.disclaimer-note {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 5px;
    border-left: 4px solid #4a90e2;
    font-style: italic;
    color: #666;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
}

.form-group textarea {
    height: 120px;
    resize: vertical;
}

/* Content Pages */
.content-page {
    padding: 50px 0;
    max-width: 800px;
    margin: 0 auto;
}

.content-page h1 {
    font-size: 2.5rem;
    margin-bottom: 30px;
    color: #333;
}

.content-page h2 {
    font-size: 1.8rem;
    margin: 30px 0 15px;
    color: #333;
}

.content-page h3 {
    font-size: 1.4rem;
    margin: 25px 0 10px;
    color: #333;
}

.content-page p {
    margin-bottom: 20px;
    line-height: 1.7;
}

.content-page ul {
    margin-bottom: 20px;
    padding-left: 30px;
}

.content-page li {
    margin-bottom: 10px;
}

/* Footer */
.footer {
    background: #333;
    color: white;
    padding: 50px 0 20px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 20px;
    color: white;
}

.footer-section p {
    color: #ccc;
    line-height: 1.6;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: #4a90e2;
}

.footer-bottom {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #555;
    color: #ccc;
}

/* Cookie Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #333;
    color: white;
    padding: 20px;
    z-index: 1001;
    transform: translateY(100%);
    transition: transform 0.3s;
}

.cookie-banner.show {
    transform: translateY(0);
}

.cookie-banner.hidden {
    display: none;
}

.cookie-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.cookie-content p {
    margin: 0;
    flex: 1;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: white;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0,0,0,0.05);
        padding: 20px 0;
        gap: 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-menu li {
        margin: 15px 0;
    }

    .nav-toggle {
        display: flex;
    }

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 30px;
    }

    .hero-text h1 {
        font-size: 2.2rem;
    }

    .books-grid {
        grid-template-columns: 1fr;
    }

    .book-detail-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .search-controls {
        flex-direction: column;
    }

    .external-links {
        flex-direction: column;
    }

    .cookie-content {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .hero-text h1 {
        font-size: 1.8rem;
    }

    .hero {
        padding: 50px 0;
    }

    .featured-books,
    .categories-preview {
        padding: 50px 0;
    }

    .book-card {
        padding: 20px;
    }

    .content-page {
        padding: 30px 20px;
    }
}

/* RTL Support */
[dir="rtl"] {
    text-align: right;
}

[dir="rtl"] .nav-menu {
    flex-direction: row-reverse;
}

[dir="rtl"] .hero-content {
    grid-template-columns: 1fr 1fr;
}

[dir="rtl"] .book-detail-content {
    grid-template-columns: 1fr 300px;
}

[dir="rtl"] .key-takeaways li {
    padding-left: 0;
    padding-right: 20px;
}

[dir="rtl"] .key-takeaways li:before {
    left: auto;
    right: 0;
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.mb-20 {
    margin-bottom: 20px;
}

.mb-30 {
    margin-bottom: 30px;
}

.hidden {
    display: none;
}