:root {
    --primary-color: #2c3e50;
    --accent-color: #3498db;
    --text-light: #ecf0f1;
    --text-dark: #2c3e50;
    --background-color: #f8f9fa;
    --success-color: #2ecc71;
    --warning-color: #f1c40f;
    --error-color: #e74c3c;
    --border-radius: 4px;
    --transition: 0.3s ease;
    --nav-bg: #1a1a1a;
    --nav-link-hover: #3498db;
    --secondary-color: #e74c3c;
    --max-width: 1400px;
}

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

body {
    font-family: 'Abyssinica SIL', serif;
    line-height: 1.6;
    color: #333;
    padding-top: 70px;
    background-color: #e2e8f0;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
}

.modal-content {
    position: relative;
    background-color: #fefefe;
    margin: 5% auto;
    padding: 0;
    border: 1px solid #888;
    width: 80%;
    max-width: 800px;
    max-height: 85vh;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal-header {
    position: sticky;
    top: 0;
    background-color: white;
    z-index: 2;
    padding: 20px;
    border-bottom: 1px solid #ddd;
}

.modal-image-container {
    position: sticky;
    top: 0;
    width: 100%;
    background-color: white;
    z-index: 1;
    padding: 0 20px;
}

.modal-image-container img {
    width: 100%;
    max-height: 300px;
    object-fit: cover;
    border-radius: 8px;
}

.modal-body {
    padding: 20px;
    overflow-y: auto;
    flex-grow: 1;
}

.modal-text-content {
    line-height: 1.6;
    color: #333;
}

.close {
    position: absolute;
    right: 1rem;
    top: 1rem;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
}

.close:hover {
    color: #000;
}

.modal h2 {
    margin-bottom: 1.5rem;
    color: var(--primary-color);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: #333;
}

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

.form-group input:focus {
    border-color: var(--primary-color);
    outline: none;
}

.submit-btn {
    width: 100%;
    padding: 1rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.submit-btn:hover {
    background: var(--primary-dark);
}

.form-footer {
    margin-top: 1rem;
    text-align: center;
    color: #666;
}

.form-footer a {
    color: var(--primary-color);
    text-decoration: none;
}

.form-footer a:hover {
    text-decoration: underline;
}

/* Search Modal */
.search-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.search-modal.active {
    display: flex;
    opacity: 1;
}

.search-modal-content {
    width: 100%;
    max-width: 600px;
    margin: 80px auto 0;
    padding: 0 20px;
}

.search-modal-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 30px;
}

.search-modal-input {
    flex: 1;
    background: transparent;
    border: none;
    border-bottom: 2px solid rgba(255, 255, 255, 0.2);
    padding: 15px 0;
    color: #fff;
    font-size: 1.5rem;
    transition: border-color 0.3s ease;
}

.search-modal-input:focus {
    border-color: var(--accent-color);
    outline: none;
}

.search-modal-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.search-modal-close {
    background: transparent;
    border: none;
    color: #fff;
    font-size: 1.5rem;
    padding: 10px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.search-modal-close:hover {
    color: var(--accent-color);
}

.search-modal-results {
    color: #fff;
    max-height: calc(100vh - 200px);
    overflow-y: auto;
}

/* Cart Sidebar */
.cart-sidebar {
    position: fixed;
    top: 0;
    right: -350px;
    width: 350px;
    height: 100vh;
    background-color: white;
    box-shadow: -2px 0 5px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    transform: translateX(0);
}

.cart-sidebar.open {
    transform: translateX(-350px);
}

.cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1999;
    display: none;
}

.cart-overlay.show {
    display: block;
}

.cart-header {
    padding: 20px;
    background-color: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cart-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #6c757d;
}

.cart-items {
    flex-grow: 1;
    overflow-y: auto;
    padding: 20px;
}

.cart-item {
    display: flex;
    gap: 15px;
    padding: 10px 0;
    border-bottom: 1px solid #dee2e6;
}

.cart-item-image {
    width: 80px;
    height: 100px;
    object-fit: contain;
    background-color: #f8f9fa;
}

.cart-item-details {
    flex-grow: 1;
}

.cart-item-title {
    margin: 0 0 5px 0;
    font-size: 1rem;
}

.cart-item-price {
    color: #28a745;
    font-weight: bold;
}

.cart-item-quantity {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
}

.quantity-btn {
    background-color: #e9ecef;
    border: none;
    padding: 5px 10px;
    border-radius: 4px;
    cursor: pointer;
}

.cart-footer {
    padding: 20px;
    background-color: #f8f9fa;
    border-top: 1px solid #dee2e6;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    font-weight: bold;
}

.checkout-btn {
    width: 100%;
    padding: 10px;
    background-color: #28a745;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
}

.checkout-btn:hover {
    background-color: #218838;
}

/* Navbar Improvements */
.navbar {
    background-color: var(--nav-bg);
    padding: 0.6rem 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 85px;
    padding: 0 2rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 1.4rem;
    padding: 0.5rem 0;
    text-decoration: none;
    color: var(--text-light);
    transition: color 0.3s ease;
}

@keyframes logoGlow {
    0% {
        filter: brightness(1) drop-shadow(0 0 8px rgba(255, 255, 255, 0.3));
    }
    50% {
        filter: brightness(1.1) drop-shadow(0 0 12px rgba(255, 255, 255, 0.5));
    }
    100% {
        filter: brightness(1) drop-shadow(0 0 8px rgba(255, 255, 255, 0.3));
    }
}

.logo-image {
    height: 75px;
    width: auto;
    object-fit: contain;
    animation: logoGlow 3s ease-in-out infinite;
    transition: all 0.3s ease;
}

.logo:hover .logo-image {
    transform: scale(1.05);
    filter: brightness(1.3) drop-shadow(0 0 15px rgba(255, 255, 255, 0.7))
           drop-shadow(0 0 25px rgba(52, 152, 219, 0.5));
}

.logo span {
    font-size: 1.7rem;
    font-weight: bold;
    color: inherit;
    white-space: nowrap;
    transition: all 0.3s ease;
}

.logo:hover span {
    color: var(--nav-link-hover);
    text-shadow: 0 0 10px rgba(52, 152, 219, 0.3);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-light);
    text-decoration: none;
    font-size: 1rem;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    transition: all 0.3s ease;
}

.nav-link i {
    font-size: 1.1rem;
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent-color);
    background-color: rgba(255, 255, 255, 0.1);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 15px;
    z-index: 100;
}

.login-btn {
    background-color: #3498db;
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 25px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.login-btn:hover {
    background-color: #2980b9;
    transform: translateY(-2px);
}

.cart-btn {
    position: relative;
    padding: 8px 15px;
    background-color: #28a745;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    z-index: 1000;
    min-width: 40px;
    min-height: 40px;
    justify-content: center;
}

.cart-btn:hover {
    background-color: #218838;
    transform: translateY(-2px);
}

.cart-btn:active {
    transform: translateY(0);
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: #dc3545;
    color: white;
    border-radius: 50%;
    padding: 2px;
    min-width: 18px;
    height: 18px;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
}

/* Hero Section Improvements */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--text-light);
    margin-top: -70px;
    background: linear-gradient(rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.75)), url('https://images.unsplash.com/photo-1507842217343-583bb7270b66?q=80');
    background-size: cover;
    background-position: center;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url("./images/hero-bg.jpg");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0.25;
    z-index: -1;
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.75));
    z-index: -1;
}

.hero-content {
    position: relative;
    max-width: 800px;
    padding: 2rem;
    z-index: 2;
    color: white;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.6);
}

.hero-title {
    font-size: 3.5rem;
    margin-bottom: 2rem;
    color: white;
}

.hero-subtitle {
    font-size: 2rem;
    margin-bottom: 3rem;
    color: white;
}

.sub-text {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2rem;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.3);
}

.hero-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    margin-top: 2rem;
}

.hero-btn {
    padding: 0.8rem 2rem;
    font-size: 1.1rem;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.hero-btn.primary-btn {
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 25px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.hero-btn.primary-btn:hover {
    background-color: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.hero-btn.secondary {
    background-color: transparent;
    color: white;
    border: 2px solid white;
}

.hero-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.hero-btn i {
    font-size: 1.2rem;
    transition: transform 0.3s ease;
}

.hero-btn:hover i {
    transform: translateX(3px);
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.scroll-indicator:hover {
    opacity: 1;
}

.mouse {
    width: 26px;
    height: 40px;
    border: 2px solid var(--text-light);
    border-radius: 20px;
    position: relative;
    margin: 0 auto 10px;
}

.wheel {
    width: 4px;
    height: 8px;
    background-color: var(--text-light);
    border-radius: 2px;
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    animation: scroll 1.5s infinite;
}

.arrows {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.arrows span {
    display: block;
    width: 10px;
    height: 10px;
    border-right: 2px solid var(--text-light);
    border-bottom: 2px solid var(--text-light);
    transform: rotate(45deg);
    animation: arrows 1.5s infinite;
}

.arrows span:nth-child(2) {
    animation-delay: 0.2s;
}

.arrows span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes scroll {
    0% {
        opacity: 1;
        transform: translateY(0);
    }
    100% {
        opacity: 0;
        transform: translateY(15px);
    }
}

@keyframes arrows {
    0% {
        opacity: 0;
        transform: rotate(45deg) translate(-5px, -5px);
    }
    50% {
        opacity: 1;
    }
    100% {
        opacity: 0;
        transform: rotate(45deg) translate(5px, 5px);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
        margin-bottom: 2rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        gap: 1rem;
    }
    
    .hero-btn {
        width: 100%;
        justify-content: center;
        padding: 0.8rem 1.5rem;
        font-size: 1rem;
    }
    
    .scroll-indicator {
        bottom: 20px;
    }
}

@media (max-width: 768px) {
    .hero {
        min-height: 70vh;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
}

/* Books Section */
.books-section {
    padding: 4rem 2rem;
    background: var(--background-color);
}

.section-title {
    text-align: center;
    margin-bottom: 2rem;
    color: var(--text-dark);
    font-size: 2rem;
}

.search-container {
    max-width: 800px;
    margin: 0 auto 2rem;
    padding: 0 1rem;
}

.search-box {
    position: relative;
    width: 100%;
    background: white;
    border-radius: 50px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.search-input {
    width: 100%;
    padding: 1.2rem 1.2rem 1.2rem 3.5rem;
    border: 2px solid #e0e0e0;
    border-radius: 50px;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.search-input:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.1);
}

.search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #4a90e2;
    font-size: 1.2rem;
}

/* Book Grid */
.book-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    min-height: 200px; /* Ensure minimum height even when empty */
}

.book-card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.book-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.book-image {
    width: 100%;
    height: 300px; /* Reduced height */
    object-fit: contain; /* Changed to contain */
    background-color: #f8f9fa;
    padding: 10px;
}

.book-info {
    padding: 15px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.book-title {
    margin: 0 0 10px 0;
    font-size: 1.1rem;
    color: #333;
}

.book-author {
    color: #666;
    margin-bottom: 8px;
    font-size: 0.9rem;
}

.book-price {
    font-weight: bold;
    color: #28a745;
    margin-bottom: 8px;
}

.book-stock {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 15px;
}

.add-to-cart-btn {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background-color 0.3s ease;
    width: 100%;
    margin-top: auto;
}

.add-to-cart-btn:hover {
    background-color: #218838;
}

.add-to-cart-btn i {
    font-size: 1rem;
}

@media (max-width: 768px) {
    .book-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        padding: 1rem;
        gap: 1rem;
    }

    .book-image {
        height: 250px;
    }

    .book-info {
        padding: 1rem;
    }
}

/* Category Pills */
.category-pill {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    background: #edf2f7;
    color: #4a5568;
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .book-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 1.5rem;
        padding: 1rem;
    }

    .book-card img {
        height: 280px;
    }

    .book-info h3 {
        font-size: 1.1rem;
    }
}

/* Category Section */
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.category-card {
    background-color: white;
    padding: 2rem;
    text-align: center;
    border-radius: var(--border-radius);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform var(--transition);
}

.category-card:hover {
    transform: translateY(-5px);
}

.category-card i {
    font-size: 2.5rem;
    color: var(--accent-color);
    margin-bottom: 1rem;
}

.category-card h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.category-card p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Footer */
.footer {
    background-color: var(--primary-color);
    color: white;
    padding: 3rem 0;
    margin-top: 4rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 2rem;
}

.footer-section {
    flex: 1;
}

.footer-section h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: white;
}

.footer-section p {
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.8);
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-links a {
    color: white;
    font-size: 1.5rem;
    transition: color 0.3s ease;
}

.social-links a:hover {
    color: var(--accent-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    margin-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        text-align: center;
    }

    .social-links {
        justify-content: center;
    }
}

/* Section Styles */
section {
    padding: 4rem 2rem;
}

section h2 {
    text-align: center;
    margin-bottom: 3rem;
    font-size: 2.5rem;
    color: var(--primary-color);
}

/* Featured Section */
.featured {
    padding: 4rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.featured h2 {
    text-align: center;
    margin-bottom: 2rem;
    color: var(--primary-color);
}

/* New Releases Section */
.new-releases {
    padding: 4rem 2rem;
    background-color: var(--text-light);
}

.book-slider {
    max-width: 1200px;
    margin: 0 auto;
    overflow: hidden;
}

/* Categories Section */
.categories {
    padding: 4rem 2rem;
    background-color: white;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.category-card {
    background-color: white;
    padding: 2rem;
    text-align: center;
    border-radius: var(--border-radius);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform var(--transition);
}

.category-card:hover {
    transform: translateY(-5px);
}

.category-card i {
    font-size: 2.5rem;
    color: var(--accent-color);
    margin-bottom: 1rem;
}

/* About Section */
.about {
    padding: 6rem 0;
    background: linear-gradient(to bottom, #f8f9fa, #fff);
}

.about-section {
    padding: 6rem 0;
    background: linear-gradient(to bottom, #f8f9fa, #fff);
}

.about-section .section-title {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    color: var(--text-dark);
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 2rem;
}

.about-content p {
    font-size: 1.2rem;
    line-height: 1.8;
    color: var(--text-dark);
    text-align: center;
}

/* Newsletter Section */
.newsletter {
    padding: 4rem 2rem;
    background-color: var(--primary-color);
    color: white;
}

.newsletter-content {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
}

.newsletter form {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.newsletter input {
    flex: 1;
    padding: 1rem;
    border: none;
    border-radius: var(--border-radius);
}

.newsletter button {
    padding: 1rem 2rem;
    background-color: var(--secondary-color);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: background-color var(--transition);
}

.newsletter button:hover {
    background-color: #c0392b;
}

/* Contact Section */
.contact {
    padding: 4rem 2rem;
}

.contact-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 4rem;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.contact-item {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.contact-item i {
    font-size: 1.5rem;
    color: var(--accent-color);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-form input,
.contact-form textarea {
    padding: 1rem;
    border: 1px solid var(--text-light);
    border-radius: var(--border-radius);
}

.contact-form textarea {
    height: 150px;
    resize: vertical;
}

.contact-form button {
    padding: 1rem;
    background-color: var(--accent-color);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: background-color var(--transition);
}

.contact-form button:hover {
    background-color: var(--accent-hover);
}

/* Image Upload Styles */
.image-upload-container {
    position: relative;
    width: 100%;
    margin-top: 0.5rem;
}

.image-upload-container input[type="file"] {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    z-index: 2;
}

.image-preview {
    width: 100%;
    height: 200px;
    border: 2px dashed #ccc;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #f8f9fa;
    margin-top: 10px;
    position: relative;
    overflow: hidden;
}

.image-preview:hover {
    border-color: #007bff;
    background: #f1f3f5;
}

.image-preview.dragover {
    border-color: #28a745;
    background: #e8f5e9;
}

.image-preview i {
    font-size: 3rem;
    color: #6c757d;
    margin-bottom: 10px;
}

.image-preview p {
    color: #6c757d;
    margin: 0;
    text-align: center;
}

.image-preview.has-image {
    border: none;
    padding: 0;
}

.image-preview.has-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.image-preview.has-image i,
.image-preview.has-image p {
    display: none;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-toggle {
        display: block;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: white;
        flex-direction: column;
        padding: 1rem;
        text-align: center;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    }

    .nav-links.active {
        display: flex;
    }

    .hero-content h2 {
        font-size: 2rem;
    }

    .hero-content p {
        font-size: 1.2rem;
    }

    .newsletter form {
        flex-direction: column;
    }

    .contact-container {
        grid-template-columns: 1fr;
    }

    .cart-sidebar {
        width: 100%;
        right: -100%;
    }

    .search-modal-content {
        margin-top: 60px;
    }
    
    .search-modal-input {
        font-size: 1.2rem;
    }
}

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

.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mt-3 { margin-top: 3rem; }
.mt-4 { margin-top: 4rem; }

.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }
.mb-3 { margin-bottom: 3rem; }
.mb-4 { margin-bottom: 4rem; }

/* Admin Styles */
.admin-container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 2rem;
    background: linear-gradient(to bottom right, #ffffff, #f8f9fa);
    border-radius: 15px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.admin-nav {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    padding: 1rem;
    border-bottom: 2px solid #eee;
}

.nav-btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    background: #f8f9fa;
    color: #495057;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-btn i {
    font-size: 1.1rem;
}

.nav-btn:hover {
    background: #e9ecef;
    transform: translateY(-2px);
}

.nav-btn.active {
    background: #007bff;
    color: white;
}

.admin-section {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    margin-bottom: 2rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.admin-section h2 {
    color: #343a40;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 3px solid #007bff;
}

/* Form Styles */
.form-group {
    margin-bottom: 1.5rem;
}

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

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

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

.admin-button {
    background: var(--accent-color);
    color: white;
    padding: 0.8rem 1.5rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    transition: background 0.3s ease;
}

.admin-button:hover {
    background: #2980b9;
}

.article-list {
    margin-top: 3rem;
}

.article-item {
    padding: 1rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 1rem;
    position: relative;
}

.article-item h4 {
    margin: 0 0 0.5rem 0;
    color: #2c3e50;
}

.article-meta {
    font-size: 0.9rem;
    color: #666;
    margin-top: 0.5rem;
}

.article-meta span {
    margin-right: 1rem;
}

.delete-button {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: #e74c3c;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.delete-button:hover {
    background: #c0392b;
}

/* Navigation Buttons */
.nav-buttons {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.nav-btn {
    padding: 0.5rem 1rem;
    text-decoration: none;
    color: #333;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-btn i {
    font-size: 1.1rem;
}

.nav-btn:hover {
    background: #e9ecef;
    transform: translateY(-2px);
}

.nav-btn.active {
    background: #007bff;
    color: white;
}

.content-section {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
    color: var(--text-dark);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .nav-buttons {
        margin: 1rem;
        flex-direction: row;
    }

    .nav-btn {
        padding: 0.8rem 1rem;
        font-size: 1rem;
    }
}

/* Video Grid */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    padding: 2rem;
}

.video-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.video-card:hover {
    transform: translateY(-5px);
}

.video-thumbnail {
    position: relative;
    padding-top: 56.25%; /* 16:9 aspect ratio */
    background: #f5f5f5;
}

.video-thumbnail img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 3rem;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.video-card:hover .play-icon {
    opacity: 1;
}

.video-card h3 {
    padding: 1rem;
    margin: 0;
    font-size: 1.1rem;
}

/* Article Grid */
.article-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    padding: 2rem;
}

.article-card {
    background: white;
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.article-card:hover {
    transform: translateY(-5px);
}

.article-card h3 {
    margin: 0 0 1rem 0;
    font-size: 1.2rem;
    color: var(--text-dark);
}

.article-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.article-meta span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #666;
    font-size: 0.9rem;
}

.article-meta i {
    color: var(--primary-color);
}

.article-summary {
    color: #444;
    margin-bottom: 1.5rem;
    line-height: 1.5;
    flex: 1;
}

.read-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background-color: #007bff;
    color: white !important;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    margin-top: 1rem;
    transition: background-color 0.3s ease;
    text-decoration: none;
}

.read-more-btn:hover {
    background-color: #0056b3;
    color: white !important;
}

.read-more-btn i {
    transition: transform 0.3s ease;
}

.read-more-btn:hover i {
    transform: translateX(3px);
}

@media (max-width: 768px) {
    .article-grid {
        grid-template-columns: 1fr;
        padding: 1rem;
    }

    .article-card {
        max-width: 500px;
        margin: 0 auto;
    }
}

/* Hero Section Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes scaleIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes gradientFlow {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.hero-section {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.75)), url('https://images.unsplash.com/photo-1507842217343-583bb7270b66?q=80');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url("./images/hero-bg.jpg");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0.25;
    z-index: -1;
}

.hero-content {
    position: relative;
    max-width: 800px;
    padding: 2rem;
    animation: fadeIn 1s ease-out;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: bold;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    animation: slideUp 1s ease-out 0.3s both;
}

.hero-subtitle {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
    animation: slideUp 1s ease-out 0.6s both;
}

.hero-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    animation: slideUp 1s ease-out 0.9s both;
}

.hero-btn {
    padding: 1rem 2rem;
    font-size: 1.1rem;
    border-radius: 50px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.hero-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.hero-btn:hover::before {
    width: 300px;
    height: 300px;
}

.primary-btn {
    background-color: var(--accent-color);
    color: var(--text-light);
    border: none;
    border-radius: 5px;
    transform: scale(1);
    transition: transform 0.3s ease;
}

.primary-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.secondary-btn {
    background-color: transparent;
    color: var(--text-light);
    border: 2px solid var(--text-light);
}

.hero-btn i {
    font-size: 1.2rem;
    transition: transform 0.3s ease;
}

.hero-btn:hover i {
    transform: translateX(3px);
}

/* Scroll Indicator Animation */
@keyframes scrollIndicator {
    0% {
        transform: translateY(0);
        opacity: 1;
    }
    50% {
        transform: translateY(10px);
        opacity: 0.5;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: white;
    cursor: pointer;
    animation: fadeIn 1s ease-out 1.2s both;
}

.mouse {
    width: 30px;
    height: 50px;
    border: 2px solid white;
    border-radius: 20px;
    position: relative;
}

.wheel {
    width: 4px;
    height: 8px;
    background-color: white;
    border-radius: 2px;
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    animation: scrollIndicator 2s ease-in-out infinite;
}

.arrows {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
}

.arrows span {
    width: 10px;
    height: 10px;
    border: 2px solid white;
    border-left: 0;
    border-top: 0;
    transform: rotate(45deg);
    animation: scrollIndicator 2s ease-in-out infinite;
}

.arrows span:nth-child(2) {
    animation-delay: 0.2s;
}

.arrows span:nth-child(3) {
    animation-delay: 0.4s;
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1.2rem;
    }

    .hero-buttons {
        flex-direction: column;
        gap: 1rem;
    }

    .hero-btn {
        width: 100%;
        justify-content: center;
    }
}

/* Animated Title Styles */
@keyframes textShine {
    0%, 100% {
        transform: translateY(0);
        color: #ffffff;
        text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    }
    50% {
        transform: translateY(-5px);
        color: #fff;
        text-shadow: 
            0 0 5px rgba(255, 255, 255, 0.8),
            0 0 10px rgba(255, 255, 255, 0.5),
            0 0 15px rgba(255, 215, 0, 0.5),
            0 0 20px rgba(255, 215, 0, 0.3);
    }
}

.hero-title {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    font-size: 3.5rem;
    font-weight: bold;
    margin-bottom: 1.5rem;
    line-height: 1.4;
    perspective: 1000px;
}

.animate-text {
    display: inline-block;
    animation: textShine 2.5s ease-in-out infinite;
    white-space: nowrap;
    transition: all 0.3s ease;
    position: relative;
}

.animate-text::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(255, 255, 255, 0.8), 
        transparent
    );
    transform: scaleX(0);
    transform-origin: center;
    transition: transform 0.5s ease;
}

.animate-text:hover::after {
    transform: scaleX(1);
}

.animate-text:nth-child(1) { animation-delay: 0.0s; }
.animate-text:nth-child(2) { animation-delay: 0.1s; }
.animate-text:nth-child(3) { animation-delay: 0.2s; }
.animate-text:nth-child(4) { animation-delay: 0.3s; }
.animate-text:nth-child(5) { animation-delay: 0.4s; }
.animate-text:nth-child(6) { animation-delay: 0.5s; }

@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
        gap: 0.3rem;
    }
    
    .animate-text {
        animation: textShine 2.5s ease-in-out infinite;
    }
}

/* Add a subtle gradient background animation */
.hero-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        45deg,
        rgba(0, 0, 0, 0.7),
        rgba(0, 0, 0, 0.5),
        rgba(0, 0, 0, 0.7)
    );
    background-size: 200% 200%;
    animation: gradientMove 15s ease infinite;
    pointer-events: none;
}

@keyframes gradientMove {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.cart-item-remove {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    background: none;
    border: none;
    color: #ff4444;
    cursor: pointer;
    padding: 0.5rem;
    transition: color 0.3s ease;
    opacity: 0.7;
}

.cart-item-remove:hover {
    color: #cc0000;
    opacity: 1;
}

.checkout-btn:hover {
    background-color: var(--primary-dark);
    color: #ffffff;
}

.search-container {
    width: 100%;
    max-width: 600px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.search-box {
    position: relative;
    width: 100%;
}

.search-input {
    width: 100%;
    padding: 1rem 1rem 1rem 3rem;
    font-size: 1rem;
    border: 2px solid var(--primary-color);
    border-radius: 50px;
    background: #ffffff;
    color: #333333;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.search-input::placeholder {
    color: #888888;
}

.search-input:focus {
    outline: none;
    box-shadow: 0 0 15px rgba(74, 144, 226, 0.3);
    border-color: #4a90e2;
}

.search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #4a90e2;
    font-size: 1.2rem;
}

.add-to-cart-btn {
    width: 100%;
    padding: 0.8rem;
    background: linear-gradient(135deg, #4a90e2, #357abd);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.add-to-cart-btn i {
    font-size: 1.1rem;
}

.add-to-cart-btn:hover {
    background: linear-gradient(135deg, #357abd, #2868a9);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(74, 144, 226, 0.3);
}

.add-to-cart-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(74, 144, 226, 0.2);
}

.no-results-message {
    text-align: center;
    padding: 2rem;
    color: var(--text-light);
    font-size: 1.1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    margin: 2rem auto;
    max-width: 600px;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.main-content {
    display: flex;
    gap: 2rem;
    padding: 2rem;
    max-width: var(--max-width);
    margin: 0 auto;
}

.videos-section,
.articles-section {
    flex: 1;
    min-width: 0;
}

@media (max-width: 768px) {
    .main-content {
        flex-direction: column;
    }
}

.content-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}

.content-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.content-card:hover {
    transform: translateY(-5px);
}

.content-thumbnail {
    position: relative;
    width: 100%;
    height: 250px;
    overflow: hidden;
}

.content-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.content-text {
    padding: 1.5rem;
}

.content-text h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: #333;
}

.content-text p {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.content-meta {
    display: flex;
    gap: 1rem;
    color: #888;
    font-size: 0.8rem;
}

.content-meta span {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.content-meta i {
    font-size: 0.9rem;
}

.videos-section h2,
.articles-section h2 {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: #333;
    text-align: center;
}

.play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 50px;
    height: 50px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.content-card:hover .play-button {
    background: rgba(0, 0, 0, 0.9);
}

@media (max-width: 768px) {
    .content-grid {
        grid-template-columns: 1fr;
    }
}

/* Admin Panel Buttons */
.admin-btn {
    background-color: #4CAF50;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s ease;
    margin: 5px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.admin-btn:hover {
    background-color: #45a049;
    transform: translateY(-2px);
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.admin-btn i {
    margin-right: 5px;
}

.delete-btn {
    background-color: #ff4444;
    color: white;
    padding: 8px 16px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.delete-btn:hover {
    background-color: #cc0000;
}

.edit-btn {
    background-color: #2196F3;
    color: white;
    padding: 8px 16px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.edit-btn:hover {
    background-color: #0b7dda;
}

.nav-btn {
    background-color: #f8f9fa;
    color: #333;
    padding: 12px 24px;
    border: 2px solid #ddd;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0 5px;
}

.nav-btn:hover {
    background-color: #e9ecef;
    border-color: #adb5bd;
}

.nav-btn.active {
    background-color: #4CAF50;
    color: white;
    border-color: #4CAF50;
}

.nav-btn i {
    font-size: 18px;
}

/* Admin Panel Layout */
.admin-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.admin-nav {
    display: flex;
    justify-content: center;
    margin-bottom: 30px;
    padding: 15px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.admin-section {
    background-color: #fff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.admin-form {
    display: grid;
    gap: 20px;
    max-width: 800px;
    margin: 0 auto;
}

.form-group {
    display: grid;
    gap: 8px;
}

.form-group label {
    font-weight: 500;
    color: #333;
}

.form-group input,
.form-group textarea,
.form-group select {
    padding: 10px;
    border: 2px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    border-color: #4CAF50;
    outline: none;
}

.image-upload-container {
    border: 2px dashed #ddd;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.image-upload-container:hover {
    border-color: #4CAF50;
    background-color: #f8f9fa;
}

.image-preview {
    max-width: 300px;
    margin: 10px auto;
}

.image-preview img {
    max-width: 100%;
    border-radius: 4px;
}

/* Book and Blog Lists */
.book-list,
.blog-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.book-item,
.blog-card {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: transform 0.3s ease;
}

.book-item:hover,
.blog-card:hover {
    transform: translateY(-5px);
}

.book-item img,
.blog-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.book-details,
.blog-card > div {
    padding: 15px;
}

.empty-message {
    text-align: center;
    padding: 20px;
    color: #666;
    font-style: italic;
    grid-column: 1 / -1;
}

/* Notification Styles */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 10px 20px;
    border-radius: 4px;
    color: white;
    font-size: 0.9rem;
    opacity: 0;
    transform: translateY(-20px);
    transition: all 0.3s ease;
    z-index: 1000;
    max-width: 300px;
}

.notification.success {
    background-color: rgba(40, 167, 69, 0.9);
}

.notification.error {
    background-color: rgba(220, 53, 69, 0.9);
}

.notification.info {
    background-color: rgba(23, 162, 184, 0.9);
}

.notification.show {
    opacity: 1;
    transform: translateY(0);
}

/* Admin Header Styles */
.admin-header {
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 15px 0;
    margin-bottom: 30px;
}

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

.admin-top-nav {
    display: flex;
    align-items: center;
    gap: 20px;
}

.admin-top-nav .nav-link {
    color: #333;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.admin-top-nav .nav-link:hover {
    background-color: #f8f9fa;
    color: #4CAF50;
}

.admin-top-nav .nav-link i {
    font-size: 18px;
}

#logoutBtn {
    background-color: #ff4444;
}

#logoutBtn:hover {
    background-color: #cc0000;
}

.reset-btn {
    background-color: #6c757d;
}

.reset-btn:hover {
    background-color: #5a6268;
}

.form-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
}

/* Image Upload Styles */
.image-upload-container {
    margin-bottom: 20px;
}

.image-preview-area {
    width: 100%;
    height: 200px;
    border: 2px dashed #ccc;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background-color: #f8f9fa;
    position: relative;
    overflow: hidden;
}

.image-preview-area:hover {
    border-color: #007bff;
    background-color: #f1f8ff;
}

.image-preview-area.dragover {
    border-color: #28a745;
    background-color: #e8f5e9;
}

.image-preview-area i {
    font-size: 48px;
    color: #6c757d;
    margin-bottom: 10px;
}

.image-preview-area p {
    margin: 0;
    color: #6c757d;
    text-align: center;
    padding: 0 20px;
}

.image-preview-area.has-image {
    padding: 0;
}

.image-preview-area.has-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.image-hint {
    display: block;
    margin-top: 8px;
    color: #6c757d;
    font-size: 0.875rem;
}

/* Form Actions */
.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.submit-btn, .reset-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.submit-btn {
    background-color: #28a745;
    color: white;
}

.submit-btn:hover {
    background-color: #218838;
}

.reset-btn {
    background-color: #6c757d;
    color: white;
}

.reset-btn:hover {
    background-color: #5a6268;
}

.submit-btn i, .reset-btn i {
    font-size: 1rem;
}

/* Notification Styles */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 25px;
    border-radius: 4px;
    color: white;
    opacity: 0;
    transform: translateY(-20px);
    transition: all 0.3s ease;
    z-index: 1000;
}

.notification.show {
    opacity: 1;
    transform: translateY(0);
}

.notification.success {
    background-color: #28a745;
}

.notification.error {
    background-color: #dc3545;
}

.notification.info {
    background-color: #17a2b8;
}

/* Category and Tag Filters */
.category-filter {
    margin: 20px auto;
    max-width: 1200px;
    padding: 0 20px;
}

.category-filter select {
    padding: 8px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    background-color: white;
    cursor: pointer;
}

.tag-filter {
    margin: 10px auto;
    max-width: 1200px;
    padding: 0 20px;
}

.active-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tag {
    background-color: #e9ecef;
    color: #495057;
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 14px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    transition: background-color 0.2s;
}

.tag:hover {
    background-color: #dee2e6;
}

.tag .remove {
    margin-left: 5px;
    font-weight: bold;
    color: #6c757d;
}

.tag .remove:hover {
    color: #dc3545;
}

/* Blog Form Styles */
.blog-section {
    display: none;
    padding: 20px;
}

.admin-form {
    max-width: 800px;
    margin: 0 auto;
}

.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.submit-btn, .reset-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 16px;
    transition: all 0.3s ease;
}

.submit-btn {
    background-color: #28a745;
    color: white;
}

.submit-btn:hover {
    background-color: #218838;
}

.reset-btn {
    background-color: #6c757d;
    color: white;
}

.reset-btn:hover {
    background-color: #5a6268;
}

.article-card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 20px;
    overflow: hidden;
    display: flex;
    gap: 20px;
    padding: 15px;
}

.article-image {
    width: 200px;
    height: 150px;
    overflow: hidden;
}

.article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.article-content {
    flex: 1;
}

.article-content h3 {
    margin: 0 0 10px 0;
    color: #333;
}

.article-meta {
    display: flex;
    gap: 15px;
    color: #666;
    margin-top: 10px;
}

.article-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.article-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.article-actions button {
    padding: 8px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    color: white;
}

.edit-btn {
    background-color: #17a2b8;
}

.delete-btn {
    background-color: #dc3545;
}

.empty-message {
    text-align: center;
    color: #666;
    margin: 20px 0;
    font-style: italic;
}

/* Blog Section Styles */
.blog-section {
    padding: 40px 0;
    background-color: #f8f9fa;
}

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

.blog-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.blog-card:hover {
    transform: translateY(-5px);
}

.blog-image {
    height: 200px;
    overflow: hidden;
}

.blog-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.blog-content {
    padding: 20px;
}

.blog-content h3 {
    margin: 0 0 10px 0;
    font-size: 1.5rem;
    color: #333;
}

.blog-author {
    color: #666;
    font-style: italic;
    margin: 5px 0;
}

.blog-excerpt {
    color: #555;
    margin: 10px 0;
    line-height: 1.6;
}

.blog-meta {
    display: flex;
    gap: 15px;
    color: #888;
    font-size: 0.9rem;
}

.blog-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.blog-meta i {
    color: #666;
}

/* Blog Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    overflow: hidden;
}

.modal-content {
    position: relative;
    background-color: #fefefe;
    margin: 5% auto;
    width: 90%;
    max-width: 800px;
    max-height: 85vh;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.modal-header {
    position: sticky;
    top: 0;
    background-color: white;
    padding: 15px;
    border-bottom: 1px solid #ddd;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-image-container {
    position: sticky;
    top: 0;
    width: 100%;
    background-color: white;
    z-index: 1;
    max-height: 300px;
    overflow: hidden;
}

.modal-image-container img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 8px;
    margin: 1rem 0;
}

.modal-body {
    padding: 20px;
    overflow-y: auto;
    max-height: calc(85vh - 400px);
}

.modal-text-content {
    line-height: 1.6;
    color: #333;
}

.modal-text-content h2 {
    margin-bottom: 15px;
    color: #2c3e50;
}

.close {
    color: #666;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    padding: 0 10px;
}

.close:hover {
    color: #000;
}

/* Make sure the modal is responsive */
@media (max-width: 768px) {
    .modal-content {
        width: 95%;
        margin: 2% auto;
    }

    .modal-image-container {
        max-height: 200px;
    }

    .modal-image-container img {
        height: 200px;
    }

    .modal-body {
        max-height: calc(85vh - 300px);
    }
}

/* Blog Articles Styles */
.content-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    padding: 2rem;
}

.content-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.content-card:hover {
    transform: translateY(-5px);
}

.content-thumbnail {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.content-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.content-card:hover .content-thumbnail img {
    transform: scale(1.05);
}

.content-text {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.content-text h3 {
    color: var(--text-dark);
    margin-bottom: 1rem;
    font-size: 1.4rem;
    line-height: 1.4;
}

.blog-excerpt {
    color: #666;
    margin-bottom: 1.5rem;
    line-height: 1.6;
    flex-grow: 1;
}

.content-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    color: #777;
}

.content-meta span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.content-meta i {
    color: var(--accent-color);
}

.read-more-btn {
    background-color: var(--accent-color);
    color: white;
    padding: 0.8rem 1.5rem;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: background-color 0.3s ease;
    font-size: 1rem;
}

.read-more-btn:hover {
    background-color: #2980b9;
}

.empty-message {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
    color: #666;
    font-size: 1.2rem;
}

/* Blog Modal Styles */
.modal-image-container img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 8px;
    margin: 1rem 0;
}

.blog-meta {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2rem;
    color: #666;
    flex-wrap: wrap;
}

.blog-meta span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.blog-meta i {
    color: var(--accent-color);
}

.blog-content {
    line-height: 1.8;
    color: #333;
}

.blog-content p {
    margin-bottom: 1.5rem;
}

.admin-actions {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
    padding: 1rem;
    border-top: 1px solid #eee;
}

.action-button {
    padding: 0.8rem 1.5rem;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1rem;
    transition: all 0.3s ease;
    background-color: var(--accent-color);
    color: white;
}

.action-button.delete-all {
    background-color: var(--error-color);
}

.action-button:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

.action-button i {
    font-size: 1.1rem;
}

/* Admin Panel Blog Articles */
.articles-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding: 1rem;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.articles-count {
    font-size: 1.1rem;
    color: #666;
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.article-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.article-card:hover {
    transform: translateY(-5px);
}

.article-image {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.article-card:hover .article-image img {
    transform: scale(1.05);
}

.article-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.article-content h4 {
    color: var(--text-dark);
    margin-bottom: 1rem;
    font-size: 1.4rem;
    line-height: 1.4;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    color: #777;
}

.article-meta span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.article-meta i {
    color: var(--accent-color);
}

.article-excerpt {
    color: #666;
    margin-bottom: 1.5rem;
    line-height: 1.6;
    flex-grow: 1;
}

.article-actions {
    display: flex;
    gap: 1rem;
    margin-top: auto;
}

.article-actions button {
    flex: 1;
    padding: 0.8rem;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.article-actions .edit-btn {
    background-color: var(--accent-color);
    color: white;
}

.article-actions .delete-btn {
    background-color: var(--error-color);
    color: white;
}

.article-actions button:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

.empty-message {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
    color: #666;
    font-size: 1.2rem;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}
