/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
    position: relative;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
}

/* Christmas-themed offer card */
.offer-card.featured-offer.christmas {
    background: linear-gradient(135deg, #8e0a0a 0%, #c0392b 50%, #16a085 100%);
    color: #fff;
    border: 2px solid rgba(255,255,255,0.12);
    box-shadow: 0 8px 30px rgba(192, 57, 43, 0.18);
    padding: 1.2rem;
    border-radius: 12px;
    position: relative;
    overflow: hidden;
}

.offer-card.featured-offer.christmas .offer-header i {
    background: rgba(255,255,255,0.08);
    padding: 10px;
    border-radius: 50%;
    color: #fff;
    font-size: 1.25rem;
    margin-right: 0.6rem;
}

.offer-card.featured-offer.christmas .offer-code {
    font-weight: 800;
    background: rgba(255,255,255,0.12);
    padding: 6px 10px;
    border-radius: 8px;
    display: inline-block;
    margin-top: 0.6rem;
    color: #fff;
    letter-spacing: 1px;
}

.offer-card.featured-offer.christmas p {
    margin-top: 0.6rem;
    color: rgba(255,255,255,0.95);
}

.offer-card.featured-offer.christmas::before {
    content: "";
    position: absolute;
    top: -40px;
    right: -40px;
    width: 140px;
    height: 140px;
    background: rgba(255,255,255,0.05);
    transform: rotate(25deg);
    border-radius: 10px;
}

.offer-card.featured-offer.christmas:hover {
    transform: translateY(-6px);
    transition: transform 0.25s ease;
    box-shadow: 0 12px 36px rgba(192, 57, 43, 0.24);
}


/* Header */
.header {
    background: #2c3e50;
    color: white;
    padding: 1rem 0;
    position: relative; /* changed from fixed to relative so header participates in normal flow */
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Reversed Navigation Layout (180 degree flip) */
.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    position: relative;
    width: 100%;
    min-width: 1000px;
    overflow-x: auto;
        flex-direction: row;
}

/* Left Section: Brand & Location (Now on Right) */
.nav-left {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    flex-shrink: 0;
    min-width: 200px;
        order: 1;
}

    /* Ensure the right-side controls stay visually on the right despite row-reverse on container */
    .nav-right { order: 2; }

/* Left-side action buttons container */
.left-actions {
    display: flex;
    gap: 0.4rem;
    margin-bottom: 6px;
    align-items: center;
    justify-content: flex-end;
}

.left-actions .action-btn {
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.12);
    color: white;
}

/* Right aligned small CTA inside nav-left */
.header-cta-right {
    margin-left: 0;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    width: 100%;
}

.contact-cta-right {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 36px;
    border-radius: 8px;
    background: rgba(255,255,255,0.08);
    color: #fff;
    margin-left: 12px;
    text-decoration: none;
    border: 1px solid rgba(255,255,255,0.06);
}

.contact-cta-right:hover { background: rgba(255,255,255,0.12); }

/* Page Toggles (vertical bar) */
.page-toggles {
    position: fixed;
    right: 12px;
    top: 120px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 4000;
}

.toggle-btn {
    background: rgba(0,0,0,0.6);
    color: white;
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.35);
}

.toggle-btn:hover { background: rgba(0,0,0,0.75); }

.count-badge {
    position: absolute;
    top: -6px;
    right: -6px;
    background: #e74c3c;
    color: #fff;
    min-width: 18px;
    height: 18px;
    border-radius: 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    padding: 0 4px;
}

.toggle-panel {
    display: none;
    position: absolute;
    right: 54px;
    top: 0;
    width: 320px;
    background: white;
    color: #333;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
    padding: 12px;
}

.toggle-panel h4 { margin: 0 0 8px 0; font-size: 1.05rem; }
.toggle-panel .panel-footer { margin-top: 10px; text-align: right; }
.toggle-panel .panel-action { background: #3498db; color: white; border: none; padding: 8px 12px; border-radius: 6px; }

/* Ensure panels stack and don't overflow on small screens */
@media (max-width: 900px) {
    .page-toggles { right: 8px; top: 90px; }
    .toggle-panel { right: 50px; width: 260px; }
}

/* Delivery status styles */
.order-item { padding: 8px 6px; border-bottom: 1px solid #eee; }
.order-item strong { display:block; margin-bottom:6px; }
.status-badge { display:inline-block; padding:4px 8px; border-radius:12px; font-size:0.8rem; color:#fff; }
.status-pending { background:#f39c12; }
.status-dispatched { background:#3498db; }
.status-out { background:#9b59b6; }
.status-delivered { background:#27ae60; }

.delivery-steps { display:flex; gap:8px; align-items:center; margin-top:8px; }
.delivery-step { flex:1; height:8px; background:#eee; border-radius:4px; position:relative; }
.delivery-step.active { background: linear-gradient(90deg,#3498db,#9b59b6); }
.delivery-controls { margin-top:8px; display:flex; gap:8px; }
.delivery-controls button { padding:6px 8px; border-radius:6px; border:none; cursor:pointer; }
.delivery-controls .btn-next { background:#3498db; color:#fff; }
.delivery-controls .btn-reset { background:#e74c3c; color:#fff; }

.shipping-info { display:grid; grid-template-columns: 1fr 1fr; gap:8px; margin-top:8px; align-items:center; }
.shipping-info label { display:flex; flex-direction:column; font-size:0.85rem; color:#444; }
.shipping-info input, .shipping-info select { padding:6px 8px; border-radius:6px; border:1px solid #ddd; font-size:0.9rem; }
.delivery-controls .btn-save { background:#27ae60; color:#fff; }


/* Ensure the left actions collapse on small screens */
@media (max-width: 768px) {
    .left-actions { display: none; }
}

.nav-brand {
    display: flex;
    align-items: center;
    font-size: 1.4rem;
    font-weight: 700;
    color: #e74c3c;
    margin-bottom: 2px;
}

.nav-brand i {
    margin-right: 8px;
    font-size: 1.5rem;
}

.location-info {
    display: flex;
    align-items: center;
    font-size: 0.7rem;
    color: #bdc3c7;
    font-weight: 400;
    cursor: pointer;
    padding: 2px 6px;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.location-info:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.location-info i {
    margin-right: 3px;
    font-size: 0.65rem;
}

.location-refresh {
    margin-left: 4px;
    margin-right: 0;
    opacity: 0.7;
    transition: all 0.3s ease;
}

.location-refresh:hover {
    opacity: 1;
    transform: rotate(180deg);
}

.location-refresh.spinning {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Center Section: Main Navigation */
.nav-center {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-grow: 1;
    max-width: 600px;
    order: 2;
    flex-direction: row-reverse;
}

.nav-link {
    color: white;
    text-decoration: none;
    font-weight: 500;
    padding: 0.4rem 0.8rem;
    border-radius: 5px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.9rem;
    white-space: nowrap;
}

.nav-link:hover {
    color: #e74c3c;
    background: rgba(255, 255, 255, 0.1);
}

.deals-link {
    background: linear-gradient(135deg, #e74c3c, #c0392b) !important;
    color: white !important;
    font-weight: 600;
}

.deals-link:hover {
    background: linear-gradient(135deg, #c0392b, #a93226) !important;
    color: white !important;
    transform: translateY(-1px);
}

/* Right Section: Search & Actions (Now on Left) */
.nav-right {
    display: flex !important;
    align-items: center;
    justify-content: flex-end;
    gap: 0.75rem;
    flex-shrink: 0;
    min-width: 450px;
    overflow: visible;
    order: 1;
    flex-direction: row-reverse;
}

.search-container {
    position: relative;
    min-width: 180px;
    max-width: 220px;
}

/* Compact pill for header action toggles (cart, wishlist, compare, notifications) */
.quick-pill {
    position: absolute;
    right: 48px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(44,62,80,0.95);
    border-radius: 26px;
    padding: 6px 10px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.3);
}

.quick-pill .pill-inner { display:flex; align-items:center; gap:8px; }
.quick-pill .pill-icons { display:flex; gap:8px; align-items:center; }

.pill-btn {
    background: rgba(255,255,255,0.06);
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    color: #fff;
    position: relative;
    cursor: pointer;
}

.pill-btn i { font-size: 1rem; }

.badge {
    position: absolute;
    top: -6px;
    right: -6px;
    width: 18px;
    height: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 0.7rem;
    color: white;
    font-weight: 700;
}

.badge.orange { background: #f1c40f; color: #2c3e50; }
.badge.pink { background: #ff4081; }
.badge.purple { background: #ab47bc; }
.badge.red { background: #e74c3c; }

@media (max-width: 820px) {
    .quick-pill { right: 16px; }
}

.nav-actions {
    display: flex !important;
    align-items: center;
    gap: 0.4rem;
    flex-shrink: 0;
    min-width: 300px;
}

/* Header panels for cart/wishlist/compare/notifications */
.header-panel {
    position: absolute;
    top: 70px;
    right: 20px;
    width: 320px;
    max-height: 420px;
    background: #fff;
    color: #333;
    border-radius: 8px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
    padding: 0.8rem;
    overflow-y: auto;
    display: none;
    z-index: 2000;
}

.header-panel h4 {
    margin: 0 0 0.5rem 0;
    font-size: 1rem;
}

.header-panel .cart-extras {
    margin-top: 0.8rem;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.delivery-status {
    font-size: 0.95rem;
}

.shipping-methods select {
    width: 100%;
    padding: 0.45rem;
    border-radius: 6px;
    border: 1px solid #ddd;
}

/* Responsive tweak: panel width on small screens */
@media (max-width: 820px) {
    .header-panel { right: 10px; left: 10px; width: auto; }
}

.action-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.4rem 0.6rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    display: flex !important;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.85rem;
    white-space: nowrap;
    visibility: visible;
    opacity: 1;
}

.action-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

.count-badge {
    background: #e74c3c;
    color: white;
    border-radius: 50%;
    padding: 1px 4px;
    font-size: 0.65rem;
    font-weight: 600;
    min-width: 14px;
    height: 14px;
    text-align: center;
    line-height: 12px;
    position: absolute;
    top: -6px;
    right: -6px;
    display: block !important;
}

.mini-cart-item, .mini-wish-item, .mini-compare-item {
    padding: 0.6rem 0.4rem;
    border-bottom: 1px solid #eee;
    font-size: 0.95rem;
}

.mini-cart-item:last-child, .mini-wish-item:last-child, .mini-compare-item:last-child {
    border-bottom: none;
}

.nav-actions { position: relative; }
.nav-actions .action-btn { position: relative; }
.notification-count { display: inline-flex; align-items: center; justify-content: center; min-width: 18px; height: 18px; border-radius: 50%; background: #e74c3c; color: white; font-weight: 700; font-size: 0.75rem; position: absolute; top: -6px; right: -6px; }

.auth-btn {
    min-width: 70px;
    justify-content: center;
}

/* Header toggle-specific selectors removed after UI simplification */

.user-menu {
    position: relative;
    display: block !important;
}

/* .nav-actions styling kept out; header actions simplified in HTML */

/* Debug: Make buttons more visible */
.action-btn {
    background: rgba(255, 255, 255, 0.15) !important;
    border: 1px solid rgba(255, 255, 255, 0.3) !important;
    min-height: 36px;
    min-width: 36px;
}

/* Mobile Menu Toggle (Hidden on Desktop) */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
}

.currency-selector select {
    background: #34495e;
    color: white;
    border: 1px solid #5a6c7d;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.9rem;
    cursor: pointer;
    outline: none;
}

.currency-selector select:hover {
    background: #4a5f7a;
}

/* ===== NAVIGATION RESPONSIVE STYLES ===== */

/* Tablet Navigation */
@media (max-width: 1200px) {
    .header .container {
        gap: 0.75rem;
    }
    
    .nav-left {
        min-width: 180px;
    }
    
    .nav-center {
        gap: 1rem;
        max-width: 500px;
    }
    
    .nav-right {
        min-width: 350px;
    }
    
    .search-container {
        min-width: 150px;
        max-width: 170px;
    }
    
    .nav-actions {
        gap: 0.3rem;
    }
    
    /* Ensure all action buttons are visible */
    .action-btn {
        display: flex !important;
        visibility: visible !important;
    }
    
    .count-badge {
        display: block !important;
    }
}

@media (max-width: 1024px) {
    .nav-center {
        gap: 0.75rem;
    }
    
    .nav-link {
        padding: 0.35rem 0.6rem;
        font-size: 0.85rem;
    }
    
    .nav-right {
        min-width: 300px;
    }
    
    .search-container {
        min-width: 120px;
        max-width: 150px;
    }
}

/* Mobile Landscape Navigation */
@media (max-width: 768px) {
    .header {
        padding: 0.75rem 0;
    }
    
    .header .container {
        display: flex;
        justify-content: space-between;
        align-items: center;
        grid-template-columns: none;
    }
    
    .nav-center {
        display: none;
    }
    
    .nav-right {
        gap: 0.4rem;
        min-width: auto;
        flex-shrink: 0;
    }
    
    .search-container {
        display: none;
    }
    
    .currency-selector {
        order: 1;
    }
    
    .currency-selector select {
        padding: 0.25rem 0.5rem;
        font-size: 0.75rem;
        min-width: 80px;
    }
    
    .nav-actions {
        gap: 0.25rem;
        display: flex;
        align-items: center;
        order: 2;
    }
    
    .action-btn {
        padding: 0.35rem;
        font-size: 0.8rem;
        min-width: auto;
        border-radius: 4px;
    }
    
    .action-btn span:not(.count-badge) {
        display: none;
    }
    
    .count-badge {
        display: block !important;
        position: absolute;
        top: -4px;
        right: -4px;
        font-size: 0.6rem;
        padding: 1px 3px;
        min-width: 12px;
        height: 12px;
        line-height: 10px;
    }
    
    .mobile-menu-toggle {
        display: block;
        order: 3;
    }
}

/* Mobile Portrait Navigation */
@media (max-width: 480px) {
    .header .container {
        flex-direction: column;
        gap: 0.75rem;
        padding: 0.5rem;
    }
    
    .nav-left {
        align-self: flex-start;
        width: 100%;
    }
    
    .nav-right {
        width: 100%;
        justify-content: space-between;
    }
    
    .nav-actions {
        flex: 1;
        justify-content: flex-end;
    }
    
    .mobile-menu-toggle {
        position: absolute;
        top: 50%;
        right: 1rem;
        transform: translateY(-50%);
    }
    
    .location-info {
        font-size: 0.7rem;
    }
    
    .nav-brand {
        font-size: 1.3rem;
    }
    
    .action-btn {
        padding: 0.3rem;
    }
    
    .count-badge {
        font-size: 0.6rem;
        padding: 1px 4px;
    }
}

.deals-link {
    background: linear-gradient(135deg, #e74c3c, #c0392b) !important;
    color: white !important;
    padding: 0.5rem 1rem !important;
    border-radius: 20px !important;
    font-weight: 600 !important;
    animation: pulse-deals 2s infinite;
}

@keyframes pulse-deals {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.notifications-btn {
    position: relative;
    background: #f39c12;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.notifications-btn:hover {
    background: #e67e22;
}

.notification-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #e74c3c;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 0.7rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.search-container {
    position: relative;
}

.search-input {
    padding: 0.5rem 2.5rem 0.5rem 1rem;
    border: none;
    border-radius: 20px;
    outline: none;
    width: 220px;
}

/* Ensure search input leaves room for the pill icons on the right */
/* search input padding restored to default */
.search-input { padding-right: 34px; }

/* header-right layout: search and account inline */
.nav-right {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.75rem;
}

.search-container {
    background: rgba(0,0,0,0.25);
    padding: 6px 10px;
    border-radius: 28px;
}

.search-input {
    background: transparent;
    color: #fff;
    width: auto;
    min-width: 140px;
    max-width: 260px;
    flex: 0 1 220px;
    border-radius: 20px;
    padding: 6px 28px 6px 8px; /* leave room for icon positioned inside */
}

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

.search-icon { color: rgba(255,255,255,0.8); }

.search-icon {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255,255,255,0.8);
    z-index: 3;
}

.search-container { position: relative; }
.search-container .search-input { padding-right: 34px; }

.cart-btn, .wishlist-btn, .compare-btn, .auth-btn {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.wishlist-btn {
    background: #e91e63;
}

.compare-btn {
    background: #9c27b0;
}

.cart-btn:hover, .wishlist-btn:hover, .compare-btn:hover, .auth-btn:hover {
    background: #c0392b;
    transform: translateY(-2px);
}

.wishlist-btn:hover {
    background: #ad1457;
}

.compare-btn:hover {
    background: #7b1fa2;
}

.cart-count, .wishlist-count, .compare-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background: #f39c12;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.wishlist-count {
    background: #ff4081;
}

.compare-count {
    background: #ab47bc;
}

/* User Menu */
.user-menu {
    position: relative;
}

.user-menu .action-btn, .auth-btn {
    background: rgba(255,255,255,0.06);
    color: #fff;
    border-radius: 22px;
    padding: 8px 12px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 1px solid rgba(255,255,255,0.08);
}

.user-menu .action-btn i { color: #fff; }

/* Ensure header right elements don't overflow on small screens */
@media (max-width: 820px) {
    .search-input { width: 140px; }
    .nav-right { gap: 0.5rem; }
}

/* Quick actions block (moved from header) */
.quick-actions {
    margin: 1rem auto;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 0.6rem;
}

.quick-actions .nav-actions {
    display: flex;
    gap: 0.6rem;
    align-items: center;
}

.quick-actions .action-btn {
    background: rgba(44,62,80,0.9);
    color: #fff;
    padding: 0.6rem;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow: 0 2px 8px rgba(0,0,0,0.25);
}

.quick-actions .action-btn i { font-size: 1.05rem; }

.quick-actions .count-badge { top: -6px; right: -6px; }

@media (max-width: 560px) {
    .search-input { display: none; }
    .user-menu .action-btn { padding: 6px 10px; }
}

.user-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    min-width: 200px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    border-radius: 8px;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
}

.user-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-dropdown a {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 1rem 1.2rem;
    color: #333;
    text-decoration: none;
    transition: background 0.3s ease;
    border-bottom: 1px solid #eee;
}

.user-dropdown a:last-child {
    border-bottom: none;
}

.user-dropdown a:hover {
    background: #f8f9fa;
    color: #e74c3c;
}

/* Search Suggestions */
.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
}

.search-suggestions.show {
    display: block;
}

.search-suggestion {
    padding: 0.8rem 1rem;
    cursor: pointer;
    border-bottom: 1px solid #eee;
    transition: background 0.3s ease;
}

.search-suggestion:hover {
    background: #f8f9fa;
}

.search-suggestion:last-child {
    border-bottom: none;
}

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

.hero-content h1 {
    font-size: 3rem;
    font-family: 'Playfair Display', serif;
    margin-bottom: 1rem;
    animation: fadeInUp 1s ease;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    opacity: 0.9;
    animation: fadeInUp 1s ease 0.2s both;
}

.hero-content p:first-of-type {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #f39c12, #e74c3c, #3498db);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
    animation: fadeInUp 1s ease 0.4s both;
}

.cta-btn {
    border: none;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cta-btn.primary {
    background: linear-gradient(135deg, #f39c12, #e67e22);
    color: white;
}

.cta-btn.primary:hover {
    background: linear-gradient(135deg, #e67e22, #d35400);
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(243, 156, 18, 0.3);
}

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

.cta-btn.secondary:hover {
    background: white;
    color: #2c3e50;
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(231, 76, 60, 0.3);
}

@media (max-width: 768px) {
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .cta-btn {
        width: 250px;
        justify-content: center;
    }
    
    .hero-content h1 {
        font-size: 2.2rem;
    }
    
    .hero-content p:first-of-type {
        font-size: 1.1rem;
    }
}

/* Featured Psychology & Finance Books Section */
.featured-psychology-section {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    position: relative;
    overflow: hidden;
}

.featured-psychology-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="brain" patternUnits="userSpaceOnUse" width="100" height="100"><circle cx="50" cy="50" r="2" fill="%23f39c12" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23brain)"/></svg>');
    pointer-events: none;
}

.psychology-highlights {
    position: relative;
    z-index: 2;
}

.highlight-card {
    display: grid;
    grid-template-columns: 80px 1fr 200px;
    gap: 2rem;
    align-items: center;
    background: white;
    padding: 2rem;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    margin-bottom: 3rem;
    position: relative;
    overflow: hidden;
}

.highlight-card.featured {
    border: 3px solid #f39c12;
    transform: scale(1.02);
}

.highlight-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 5px;
    height: 100%;
    background: linear-gradient(to bottom, #f39c12, #e67e22);
}

.highlight-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #f39c12, #e67e22);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-10px); }
    60% { transform: translateY(-5px); }
}

.highlight-content h3 {
    color: #2c3e50;
    margin: 0 0 0.5rem 0;
    font-size: 1.4rem;
    font-weight: 700;
}

.highlight-content p {
    color: #7f8c8d;
    margin: 0.5rem 0;
    line-height: 1.6;
}

.highlight-price {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin: 1rem 0;
}

.highlight-price .price {
    color: #27ae60;
    font-size: 1.5rem;
    font-weight: 700;
}

.highlight-price .original-price {
    color: #95a5a6;
    text-decoration: line-through;
    font-size: 1.1rem;
}

.highlight-price .discount {
    background: #e74c3c;
    color: white;
    padding: 0.2rem 0.5rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
}

.highlight-btn {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.highlight-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(52, 152, 219, 0.3);
}

.highlight-image img {
    width: 180px;
    height: 250px;
    object-fit: cover;
    border-radius: 10px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    transition: transform 0.3s ease;
}

.highlight-image img:hover {
    transform: scale(1.05) rotate(2deg);
}

.bestsellers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.bestseller-item {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.bestseller-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 3px;
    background: linear-gradient(to right, #f39c12, #e67e22);
    transition: left 0.3s ease;
}

.bestseller-item:hover::before {
    left: 0;
}

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

.bestseller-item img {
    width: 100px;
    height: 140px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 1rem;
    transition: transform 0.3s ease;
}

.bestseller-item:hover img {
    transform: scale(1.1);
}

.bestseller-item h4 {
    color: #2c3e50;
    font-size: 1rem;
    margin: 0.5rem 0;
    line-height: 1.3;
}

.bestseller-item p {
    color: #7f8c8d;
    font-size: 0.9rem;
    margin: 0.25rem 0;
}

.bestseller-item .rating {
    color: #f39c12;
    font-size: 0.9rem;
    margin: 0.5rem 0;
    font-weight: 600;
}

.bestseller-item .price {
    color: #27ae60;
    font-size: 1.1rem;
    font-weight: 700;
    margin-top: 0.5rem;
}

/* Responsive Psychology Section */
@media (max-width: 768px) {
    .highlight-card {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 1.5rem;
    }
    
    .highlight-image {
        order: -1;
    }
    
    .bestsellers-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .bestseller-item img {
        width: 80px;
        height: 110px;
    }
}

/* Books Section */
.books-section {
    padding: 80px 0;
}

/* Breadcrumb */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 2rem;
    font-size: 0.9rem;
}

.breadcrumb a {
    color: #3498db;
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: #2980b9;
}

.breadcrumb-separator {
    color: #bdc3c7;
}

.breadcrumb-current {
    color: #7f8c8d;
    font-weight: 500;
}

/* Section Header */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.section-header h2 {
    font-size: 2.5rem;
    color: #2c3e50;
    font-family: 'Playfair Display', serif;
    margin: 0;
}

.view-options {
    display: flex;
    gap: 0.5rem;
}

.view-btn {
    background: #f8f9fa;
    border: 2px solid #dee2e6;
    color: #6c757d;
    padding: 0.5rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.view-btn:hover, .view-btn.active {
    background: #3498db;
    border-color: #3498db;
    color: white;
}

/* Advanced Filters */
.advanced-filters {
    background: #f8f9fa;
    padding: 2rem;
    border-radius: 12px;
    margin-bottom: 2rem;
    border: 1px solid #dee2e6;
}

.filter-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.filter-row:last-child {
    margin-bottom: 0;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.filter-group label {
    font-weight: 500;
    color: #495057;
    font-size: 0.9rem;
}

.filter-select {
    padding: 0.7rem 1rem;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    outline: none;
    background: white;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.filter-select:focus {
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.price-range-container {
    position: relative;
    display: block;
    width: 100%;
    padding: 0.5rem 0;
}

/* Make the two range inputs visually merge into one thin rounded track */
.price-range-container .price-slider {
    -webkit-appearance: none;
    appearance: none;
    position: absolute;
    left: 0;
    right: 0;
    width: 100%;
    height: 8px;
    margin: 0;
    background: transparent; /* background will be painted via gradient set in JS */
    pointer-events: none; /* allow clicks to pass to the top-most thumb only */
}

.price-range-container .price-slider.top {
    pointer-events: auto; /* the top slider accepts pointer events */
}

/* visible track for both (fallback) */
.price-slider::-webkit-slider-runnable-track {
    height: 8px;
    border-radius: 8px;
    background: #e6e6e6;
}

.price-slider::-moz-range-track {
    height: 8px;
    border-radius: 8px;
    background: #e6e6e6;
}

.price-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #ffffff;
    border: 3px solid #666; /* subtle outline like screenshot */
    box-shadow: 0 2px 6px rgba(0,0,0,0.25);
    cursor: pointer;
    margin-top: -4px; /* center the thumb vertically on the track */
}

.price-slider::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #fff;
    border: 3px solid #666;
    box-shadow: 0 2px 6px rgba(0,0,0,0.25);
    cursor: pointer;
}

/* Hide visible scrollbars while keeping scroll functionality */
/* WebKit browsers (Chrome, Safari, Edge Chromium) */
::-webkit-scrollbar {
    display: none;
}

/* Firefox */
html {
    scrollbar-width: none; /* hide scrollbar */
    -ms-overflow-style: none; /* hide scrollbar in IE 10+ */
}

.clear-filters-btn {
    background: #dc3545;
    color: white;
    border: none;
    padding: 0.7rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: auto;
}

.clear-filters-btn:hover {
    background: #c82333;
    transform: translateY(-2px);
}

/* Results Info */
.results-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding: 1rem 0;
    border-bottom: 2px solid #dee2e6;
}

.items-per-page {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.items-per-page label {
    font-weight: 500;
    color: #495057;
}

.items-per-page select {
    padding: 0.5rem;
    border: 2px solid #dee2e6;
    border-radius: 6px;
    outline: none;
    cursor: pointer;
}

/* Books Grid */
.books-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.book-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    border: 2px solid transparent;
}

.book-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.2);
    border-color: #3498db;
}

.book-card.in-wishlist {
    border-color: #e91e63;
}

.book-card.in-compare {
    border-color: #9c27b0;
}

/* List View Styles */
.books-grid.list-view {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.books-grid.list-view .book-card {
    display: flex;
    flex-direction: row;
    max-width: none;
    height: 200px;
    padding: 1rem;
    align-items: center;
}

.books-grid.list-view .book-image-container {
    width: 150px;
    min-width: 150px;
    height: 180px;
    margin-right: 1.5rem;
}

.books-grid.list-view .book-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.books-grid.list-view .book-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 180px;
    padding: 0.5rem 0;
}

.books-grid.list-view .book-actions {
    flex-direction: row;
    gap: 0.5rem;
    width: auto;
    margin-top: 1rem;
}

.books-grid.list-view .book-title {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}

.books-grid.list-view .book-author {
    font-size: 1rem;
    margin-bottom: 0.8rem;
}

.books-grid.list-view .book-price {
    font-size: 1.4rem;
    margin-bottom: 0.8rem;
}

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

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

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

.book-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #e74c3c;
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
}

.book-info {
    padding: 1.5rem;
}

.book-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #2c3e50;
}

.book-author {
    color: #7f8c8d;
    margin-bottom: 1rem;
}

.book-rating {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.stars {
    color: #f39c12;
}

.book-price {
    font-size: 1.3rem;
    font-weight: 700;
    color: #e74c3c;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.stock-status {
    font-size: 0.8rem;
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
    font-weight: 500;
}

.stock-status.in-stock {
    background: #d4edda;
    color: #155724;
}

.stock-status.low-stock {
    background: #fff3cd;
    color: #856404;
}

.stock-status.out-of-stock {
    background: #f8d7da;
    color: #721c24;
}

.book-origin, .book-language {
    font-size: 0.75rem;
    padding: 0.2rem 0.5rem;
    border-radius: 10px;
    margin-bottom: 0.3rem;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-weight: 500;
    margin-right: 0.5rem;
}

.book-origin {
    background: #e8f5e8;
    color: #2e7d2e;
}

.book-language {
    background: #e3f2fd;
    color: #1565c0;
}

.stock-status.out-of-stock {
    background: #f8d7da;
    color: #721c24;
}

.book-actions {
    display: flex;
    gap: 0.5rem;
    width: 100%;
}

.add-to-cart {
    flex: 1;
    background: #2c3e50;
    color: white;
    border: none;
    padding: 0.8rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.add-to-cart:hover {
    background: #34495e;
    transform: translateY(-2px);
}

.add-to-wishlist, .add-to-compare {
    background: #f8f9fa;
    color: #495057;
    border: 2px solid #dee2e6;
    padding: 0.8rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
}

.add-to-wishlist:hover {
    background: #e91e63;
    color: white;
    border-color: #e91e63;
}

.add-to-compare:hover {
    background: #9c27b0;
    color: white;
    border-color: #9c27b0;
}

.add-to-wishlist.active {
    background: #e91e63;
    color: white;
    border-color: #e91e63;
}

.add-to-compare.active {
    background: #9c27b0;
    color: white;
    border-color: #9c27b0;
}

/* Quick Actions */
.book-quick-actions {
    position: absolute;
    top: 10px;
    left: 10px;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.book-card:hover .book-quick-actions {
    opacity: 1;
}

.quick-action-btn {
    background: rgba(255,255,255,0.9);
    border: none;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    color: #495057;
}

.quick-action-btn:hover {
    background: white;
    transform: scale(1.1);
}

.quick-action-btn.wishlist:hover {
    color: #e91e63;
}

.quick-action-btn.compare:hover {
    color: #9c27b0;
}

.quick-action-btn.review:hover {
    color: #f39c12;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
}

.page-btn {
    background: transparent;
    border: 2px solid #3498db;
    color: #3498db;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.page-btn:hover, .page-btn.active {
    background: #3498db;
    color: white;
}

/* Sidebar Styles */
.sidebar {
    position: fixed;
    top: 0;
    right: -450px;
    width: 450px;
    height: 100vh;
    background: white;
    box-shadow: -5px 0 25px rgba(0,0,0,0.15);
    transition: right 0.3s ease;
    z-index: 1001;
    display: flex;
    flex-direction: column;
}

.sidebar.open {
    right: 0;
}

/* Place compare sidebar on the left so it doesn't clash with cart/wishlist on the right */
.compare-sidebar {
    /* override default right placement */
    right: auto;
    left: -350px;
    width: 350px;
    box-shadow: 5px 0 25px rgba(0,0,0,0.12);
    transition: left 0.28s ease;
}

.compare-sidebar.open {
    left: 0;
}

/* Slightly reduce width for wishlist/cart to avoid overlap */
.cart-sidebar,
.wishlist-sidebar {
    width: 380px;
}

/* Notification Styles */
.notification {
    position: fixed;
    top: 20px;
    right: -300px;
    background: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    display: flex;
    align-items: center;
    gap: 1rem;
    z-index: 9999;
    transition: right 0.3s ease;
    min-width: 250px;
}

.notification.show {
    right: 20px;
}

.notification.success {
    border-left: 4px solid #27ae60;
}

.notification.error {
    border-left: 4px solid #e74c3c;
}

.notification.info {
    border-left: 4px solid #3498db;
}

.notification i {
    font-size: 1.2rem;
    color: #27ae60;
}

.notification.error i {
    color: #e74c3c;
}

.notification.info i {
    color: #3498db;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.loading-overlay.show {
    opacity: 1;
    visibility: visible;
}

.loading-spinner {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    text-align: center;
    color: #2c3e50;
    min-width: 200px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-spinner p {
    margin: 0;
    font-weight: 500;
    font-size: 1.1rem;
}

/* Page Loading Screen */
.page-loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 1;
    visibility: visible;
    transition: all 0.8s ease;
}

.page-loading.hide {
    opacity: 0;
    visibility: hidden;
}

.page-loading-content {
    text-align: center;
    color: white;
}

.book-loader {
    margin-bottom: 2rem;
}

.book-pages {
    position: relative;
    width: 80px;
    height: 100px;
    margin: 0 auto;
}

.page {
    position: absolute;
    width: 60px;
    height: 80px;
    background: white;
    border-radius: 3px;
    transform-origin: left center;
    animation: pageFlip 2s infinite;
}

.page:nth-child(1) {
    animation-delay: 0s;
    z-index: 3;
}

.page:nth-child(2) {
    animation-delay: 0.3s;
    z-index: 2;
    left: 10px;
}

.page:nth-child(3) {
    animation-delay: 0.6s;
    z-index: 1;
    left: 20px;
}

@keyframes pageFlip {
    0%, 50% {
        transform: rotateY(0deg);
    }
    75%, 100% {
        transform: rotateY(-180deg);
    }
}

.page-loading h2 {
    font-family: 'Playfair Display', serif;
    font-size: 3rem;
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.page-loading p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* loading progress bar styles removed */

/* Book Card Loading States */
.book-card.loading {
    opacity: 0.6;
    pointer-events: none;
}

.book-card.loading .book-image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
}

.book-card.loading .book-image::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    z-index: 1;
}

/* Button Loading States */
.btn.loading {
    position: relative;
    pointer-events: none;
    opacity: 0.7;
}

.btn.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 16px;
    height: 16px;
    border: 2px solid transparent;
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.btn.loading .btn-text {
    opacity: 0;
}

/* Skeleton Loading for Book Cards */
.skeleton-loader {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    padding: 2rem 0;
}

.skeleton-book {
    background: white;
    border-radius: 15px;
    padding: 1.5rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.skeleton-image {
    width: 100%;
    height: 300px;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.skeleton-text {
    height: 20px;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
    border-radius: 4px;
    margin-bottom: 0.5rem;
}

.skeleton-text.short {
    width: 60%;
}

.skeleton-text.medium {
    width: 80%;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 2px solid #eee;
    background: #f8f9fa;
}

.sidebar-header h3 {
    margin: 0;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.close-sidebar {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
    padding: 0.5rem;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.close-sidebar:hover {
    background: #dee2e6;
    color: #e74c3c;
}

.sidebar-content {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
}

.sidebar-footer {
    padding: 1.5rem;
    border-top: 2px solid #eee;
    background: #f8f9fa;
}

/* Cart Specific Styles */
.cart-summary {
    background: white;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.summary-line {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    color: #495057;
}

.summary-line.total {
    font-size: 1.2rem;
    color: #2c3e50;
    padding-top: 0.5rem;
    border-top: 2px solid #dee2e6;
    margin-top: 1rem;
}

/* Wishlist Specific Styles */
.wishlist-item, .compare-item {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    border: 2px solid #f8f9fa;
    border-radius: 8px;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.wishlist-item:hover, .compare-item:hover {
    border-color: #dee2e6;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.wishlist-item-image, .compare-item-image {
    width: 60px;
    height: 80px;
    object-fit: cover;
    border-radius: 6px;
}

.wishlist-item-info, .compare-item-info {
    flex: 1;
}

.wishlist-item-title, .compare-item-title {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #2c3e50;
}

.wishlist-item-author, .compare-item-author {
    color: #7f8c8d;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.wishlist-item-price, .compare-item-price {
    color: #e74c3c;
    font-weight: 600;
}

.wishlist-item-actions, .compare-item-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.move-to-cart-btn, .remove-wishlist-btn, .remove-compare-btn {
    padding: 0.4rem 0.8rem;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.3s ease;
}

.move-to-cart-btn {
    background: #27ae60;
    color: white;
}

.move-to-cart-btn:hover {
    background: #229954;
}

.remove-wishlist-btn, .remove-compare-btn {
    background: #e74c3c;
    color: white;
}

.remove-wishlist-btn:hover, .remove-compare-btn:hover {
    background: #c0392b;
}

.clear-wishlist-btn, .clear-compare-btn {
    width: 100%;
    background: #6c757d;
    color: white;
    border: none;
    padding: 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.clear-wishlist-btn:hover, .clear-compare-btn:hover {
    background: #5a6268;
}

.compare-btn-full {
    width: 100%;
    background: #9c27b0;
    color: white;
    border: none;
    padding: 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.compare-btn-full:hover {
    background: #7b1fa2;
}

.cart-item {
    display: flex;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid #eee;
}

.cart-item-image {
    width: 60px;
    height: 80px;
    object-fit: cover;
    border-radius: 5px;
}

.cart-item-info {
    flex: 1;
}

.cart-item-title {
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.cart-item-price {
    color: #e74c3c;
    font-weight: 500;
}

.quantity-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.quantity-btn {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    width: 30px;
    height: 30px;
    border-radius: 5px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.remove-item {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 0.3rem 0.8rem;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.8rem;
}

.cart-footer {
    padding: 1.5rem;
    border-top: 1px solid #eee;
}

.cart-total {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    text-align: center;
}

.checkout-btn {
    width: 100%;
    background: #27ae60;
    color: white;
    border: none;
    padding: 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 600;
    transition: background 0.3s ease;
}

.checkout-btn:hover {
    background: #229954;
}

/* Recently Viewed */
.recently-viewed {
    background: #f8f9fa;
    padding: 2rem 0;
    margin-top: 3rem;
    border-top: 2px solid #dee2e6;
}

.recently-viewed h3 {
    color: #2c3e50;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.recently-viewed-items {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
}

.recently-viewed-item {
    background: white;
    border-radius: 8px;
    padding: 1rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.recently-viewed-item:hover {
    transform: translateY(-5px);
    border-color: #3498db;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.recently-viewed-image {
    width: 80px;
    height: 120px;
    object-fit: cover;
    border-radius: 6px;
    margin-bottom: 0.5rem;
}

.recently-viewed-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.25rem;
}

.recently-viewed-price {
    color: #e74c3c;
    font-weight: 600;
    font-size: 0.9rem;
}

/* Modals */
.modal {
    display: none;
    position: fixed;
    z-index: 1002;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    animation: fadeIn 0.3s ease;
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: slideIn 0.3s ease;
}

.modal-content.large-modal {
    max-width: 900px;
    width: 90%;
}

/* Profile Modal */
.profile-container {
    width: 100%;
}

.profile-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.profile-section {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid #dee2e6;
}

.profile-section h4 {
    color: #2c3e50;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #dee2e6;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.profile-form input {
    padding: 0.8rem;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    outline: none;
    transition: border-color 0.3s ease;
}

.profile-form input:focus {
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    cursor: pointer;
    margin-bottom: 0.8rem;
    padding: 0.5rem;
    border-radius: 6px;
    transition: background 0.3s ease;
}

.checkbox-label:hover {
    background: rgba(52, 152, 219, 0.1);
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.save-profile-btn {
    background: #27ae60;
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.save-profile-btn:hover {
    background: #229954;
    transform: translateY(-2px);
}

/* Order History Modal */
.order-history-container {
    width: 100%;
}

.order-filters {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.order-filters select,
.order-filters input {
    padding: 0.7rem;
    border: 2px solid #dee2e6;
    border-radius: 6px;
    outline: none;
}

.orders-list {
    max-height: 500px;
    overflow-y: auto;
}

.order-item {
    background: white;
    border: 2px solid #f8f9fa;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.order-item:hover {
    border-color: #3498db;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
}

.order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #eee;
}

.order-number {
    font-weight: 600;
    color: #2c3e50;
}

.order-status {
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
}

.order-status.pending {
    background: #fff3cd;
    color: #856404;
}

.order-status.processing {
    background: #cce5ff;
    color: #004085;
}

.order-status.shipped {
    background: #d4edda;
    color: #155724;
}

.order-status.delivered {
    background: #d1ecf1;
    color: #0c5460;
}

.order-status.cancelled {
    background: #f8d7da;
    color: #721c24;
}

.order-items {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.order-item-detail {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid #f8f9fa;
}

.order-total {
    font-weight: 600;
    font-size: 1.1rem;
    color: #2c3e50;
    text-align: right;
}

/* Comparison Modal */
.compare-container {
    width: 100%;
}

.comparison-table {
    overflow-x: auto;
    margin-bottom: 2rem;
}

.comparison-grid {
    display: grid;
    grid-template-columns: 150px repeat(auto, 1fr);
    gap: 1rem;
    min-width: 600px;
}

.comparison-header {
    font-weight: 600;
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 8px;
    color: #2c3e50;
    display: flex;
    align-items: center;
    justify-content: center;
}

.comparison-cell {
    padding: 1rem;
    border: 2px solid #f8f9fa;
    border-radius: 8px;
    text-align: center;
    background: white;
}

.comparison-book-image {
    width: 100px;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 1rem;
}

/* Review Modal */
.review-container {
    width: 100%;
    max-width: 500px;
}

.review-book-info {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.review-book-image {
    width: 80px;
    height: 120px;
    object-fit: cover;
    border-radius: 6px;
}

.rating-input {
    margin-bottom: 1.5rem;
}

.star-rating {
    display: flex;
    gap: 0.25rem;
    margin-top: 0.5rem;
}

.star-rating i {
    font-size: 1.5rem;
    color: #ddd;
    cursor: pointer;
    transition: color 0.3s ease;
}

.star-rating i:hover,
.star-rating i.active {
    color: #f39c12;
}

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

.review-form input,
.review-form textarea {
    padding: 0.8rem;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    outline: none;
    transition: border-color 0.3s ease;
}

.review-form input:focus,
.review-form textarea:focus {
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.review-options {
    margin: 1rem 0;
}

.submit-review-btn {
    background: #f39c12;
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.submit-review-btn:hover {
    background: #e67e22;
    transform: translateY(-2px);
}

/* Settings Modal */
.settings-container {
    width: 100%;
}

.settings-tabs {
    display: flex;
    margin-bottom: 2rem;
    border-bottom: 2px solid #dee2e6;
}

.settings-tab {
    flex: 1;
    background: transparent;
    border: none;
    padding: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    color: #6c757d;
    font-weight: 500;
}

.settings-tab.active {
    color: #3498db;
    border-bottom: 3px solid #3498db;
}

.settings-content {
    position: relative;
}

.settings-panel {
    display: none;
}

.settings-panel.active {
    display: block;
}

.setting-item {
    margin-bottom: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.setting-item label {
    font-weight: 500;
    color: #495057;
}

.setting-item input,
.setting-item select {
    padding: 0.7rem;
    border: 2px solid #dee2e6;
    border-radius: 6px;
    outline: none;
    transition: border-color 0.3s ease;
}

.setting-item input:focus,
.setting-item select:focus {
    border-color: #3498db;
}

.save-settings-btn {
    background: #17a2b8;
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 2rem;
}

.save-settings-btn:hover {
    background: #138496;
    transform: translateY(-2px);
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.loading-overlay.show {
    opacity: 1;
    visibility: visible;
}

.loading-spinner {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    color: #2c3e50;
}

.loading-spinner i {
    font-size: 2rem;
    color: #3498db;
    margin-bottom: 1rem;
}

.loading-spinner p {
    margin: 0;
    font-weight: 500;
}

.close-modal {
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 2rem;
    cursor: pointer;
    color: #666;
}

/* Book Details Modal */
.book-details {
    display: flex;
    gap: 2rem;
    align-items: start;
}

.book-details-image {
    width: 200px;
    height: 300px;
    object-fit: cover;
    border-radius: 10px;
}

.book-details-info h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: #2c3e50;
}

.book-details-info p {
    margin-bottom: 1rem;
    line-height: 1.6;
}

.book-details-price {
    font-size: 1.5rem;
    color: #e74c3c;
    font-weight: 700;
    margin: 1rem 0;
}

/* Auth Modal */
.auth-container {
    width: 100%;
    max-width: 400px;
}

.auth-tabs {
    display: flex;
    margin-bottom: 2rem;
}

.auth-tab {
    flex: 1;
    background: transparent;
    border: none;
    padding: 1rem;
    cursor: pointer;
    border-bottom: 2px solid #eee;
    transition: all 0.3s ease;
}

.auth-tab.active {
    border-bottom-color: #3498db;
    color: #3498db;
}

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

.auth-form.hidden {
    display: none;
}

.auth-form h3 {
    text-align: center;
    margin-bottom: 1.5rem;
    color: #2c3e50;
}

.auth-form input {
    padding: 1rem;
    border: 2px solid #eee;
    border-radius: 8px;
    outline: none;
    transition: border-color 0.3s ease;
}

.auth-form input:focus {
    border-color: #3498db;
}

.auth-form button {
    background: #3498db;
    color: white;
    border: none;
    padding: 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: background 0.3s ease;
}

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

/* Checkout Modal */
.checkout-container {
    width: 100%;
    max-width: 500px;
}

.checkout-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.checkout-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.checkout-section h4 {
    color: #2c3e50;
    border-bottom: 2px solid #eee;
    padding-bottom: 0.5rem;
}

.checkout-section input {
    padding: 1rem;
    border: 2px solid #eee;
    border-radius: 8px;
    outline: none;
    transition: border-color 0.3s ease;
}

.checkout-section input:focus {
    border-color: #3498db;
}

.card-details {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1rem;
}

.order-summary {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
}

.order-summary h4 {
    margin-bottom: 1rem;
    color: #2c3e50;
}

.checkout-item {
    display: flex;
    justify-content: between;
    margin-bottom: 0.5rem;
}

.total {
    font-size: 1.2rem;
    font-weight: 700;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 2px solid #dee2e6;
}

.place-order-btn {
    background: #27ae60;
    color: white;
    border: none;
    padding: 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 600;
    transition: background 0.3s ease;
}

.place-order-btn:hover {
    background: #229954;
}

/* Toast Notification */
.toast {
    position: fixed;
    top: 100px;
    right: 20px;
    background: #27ae60;
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    transform: translateX(400px);
    transition: transform 0.3s ease;
    z-index: 1003;
}

.toast.show {
    transform: translateX(0);
}

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

/* Deals & Discounts Section */
.deals-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, #fff5f5 0%, #ffe8e8 100%);
}

.discount-banner {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    border-radius: 20px;
    padding: 3rem;
    margin-bottom: 3rem;
    color: white;
    overflow: hidden;
    position: relative;
}

.discount-banner::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 200px;
    height: 200px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
}

.banner-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 2;
}

.discount-badge {
    background: #f39c12;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    font-weight: bold;
    font-size: 0.9rem;
    display: inline-block;
    margin-bottom: 1rem;
}

.banner-content h3 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.banner-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

.countdown-timer {
    display: flex;
    gap: 1rem;
}

.timer-unit {
    background: rgba(255,255,255,0.2);
    padding: 1rem;
    border-radius: 10px;
    text-align: center;
    min-width: 80px;
}

.timer-number {
    display: block;
    font-size: 2rem;
    font-weight: bold;
}

/* small pop effect when countdown numbers change */
.timer-number.pop {
    transform: scale(1.18);
    color: #e74c3c;
    transition: transform 180ms ease, color 220ms ease;
}

.timer-label {
    font-size: 0.8rem;
    opacity: 0.9;
}

.discount-categories h3,
.special-offers h3 {
    text-align: center;
    font-size: 2rem;
    color: #2c3e50;
    margin: 3rem 0 2rem 0;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.category-deal {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    border: 2px solid transparent;
}

.category-deal:hover {
    transform: translateY(-5px);
    border-color: #e74c3c;
}

.category-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem auto;
    font-size: 2rem;
    color: white;
}

.discount-percent {
    background: #27ae60;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    font-weight: bold;
    display: inline-block;
    margin: 1rem 0;
    font-size: 1.1rem;
}

.shop-category-btn {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 0.8rem 2rem;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.shop-category-btn:hover {
    background: #c0392b;
    transform: scale(1.05);
}

.offers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.offer-card {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    text-align: center;
    border: 2px solid #f8f9fa;
    transition: all 0.3s ease;
}

.offer-card:hover {
    border-color: #e74c3c;
    transform: translateY(-3px);
}

.offer-card.featured-offer {
    border-color: #f39c12;
    background: linear-gradient(135deg, #fff9e6 0%, #ffeaa7 100%);
    position: relative;
}

.offer-card.featured-offer::before {
    content: '🌟 FEATURED';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    background: #f39c12;
    color: white;
    padding: 0.3rem 1rem;
    border-radius: 15px;
    font-size: 0.7rem;
    font-weight: bold;
}

.offer-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.offer-header i {
    font-size: 1.5rem;
    color: #e74c3c;
}

.offer-code {
    background: #2c3e50;
    color: white;
    padding: 1rem;
    border-radius: 10px;
    font-family: 'Courier New', monospace;
    font-weight: bold;
    font-size: 1.2rem;
    margin: 1rem 0;
    letter-spacing: 2px;
}

.copy-code-btn {
    background: #27ae60;
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.copy-code-btn:hover {
    background: #219a52;
    transform: scale(1.05);
}

.loyalty-program {
    background: linear-gradient(135deg, #2c3e50, #34495e);
    color: white;
    padding: 3rem;
    border-radius: 20px;
    margin-top: 3rem;
}

.loyalty-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 3rem;
    align-items: center;
}

.loyalty-info h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: #f39c12;
}

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

.benefit {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
}

.benefit i {
    color: #f39c12;
    font-size: 1.2rem;
}

.join-rewards-btn {
    background: #f39c12;
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.join-rewards-btn:hover {
    background: #e67e22;
    transform: scale(1.05);
}

.loyalty-tiers {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.tier {
    background: rgba(255,255,255,0.1);
    padding: 1.5rem;
    border-radius: 15px;
    text-align: center;
    transition: all 0.3s ease;
}

.tier.active {
    background: rgba(243,156,18,0.2);
    border: 2px solid #f39c12;
}

.tier-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 0.5rem auto;
    font-size: 1.5rem;
}

.tier-icon.bronze {
    background: linear-gradient(135deg, #cd7f32, #b8860b);
}

.tier-icon.silver {
    background: linear-gradient(135deg, #c0c0c0, #a8a8a8);
}

.tier-icon.gold {
    background: linear-gradient(135deg, #ffd700, #ffb347);
}

/* Branches Section */
.branches-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, #f1f3f4 0%, #e8eaf6 100%);
}

.branches-container {
    max-width: 1400px;
    margin: 0 auto;
}

.country-section {
    margin-bottom: 3rem;
}

.country-section h3 {
    font-size: 1.8rem;
    color: #2c3e50;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 3px solid #e74c3c;
    width: fit-content;
}

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

.branch-card {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    border-left: 4px solid #e74c3c;
}

.branch-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}

.branch-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    color: white;
    border-radius: 50%;
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.branch-card h4 {
    font-size: 1.3rem;
    color: #2c3e50;
    margin-bottom: 1rem;
    font-weight: 600;
}

.branch-card p {
    color: #6c757d;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.branch-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.branch-features .feature {
    background: #f8f9fa;
    color: #495057;
    padding: 0.3rem 0.7rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
}

.branch-features-section {
    background: white;
    padding: 3rem;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    margin-top: 3rem;
}

.branch-features-section h3 {
    text-align: center;
    font-size: 2rem;
    color: #2c3e50;
    margin-bottom: 2rem;
}

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

.feature-item {
    text-align: center;
    padding: 1.5rem;
}

.feature-item i {
    font-size: 2.5rem;
    color: #e74c3c;
    margin-bottom: 1rem;
    display: block;
}

.feature-item h4 {
    font-size: 1.2rem;
    color: #2c3e50;
    margin-bottom: 1rem;
}

.feature-item p {
    color: #6c757d;
    line-height: 1.6;
}

/* Notifications Dropdown */
.notifications-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    width: 400px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.2);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    max-height: 500px;
    overflow: hidden;
}

.notifications-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.notifications-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #e9ecef;
}

.notifications-header h4 {
    color: #2c3e50;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.mark-all-read {
    background: none;
    border: none;
    color: #e74c3c;
    font-size: 0.9rem;
    cursor: pointer;
    padding: 0.3rem 0.6rem;
    border-radius: 5px;
    transition: background 0.3s ease;
}

.mark-all-read:hover {
    background: #f8f9fa;
}

.notifications-list {
    max-height: 350px;
    overflow-y: auto;
}

.notification-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #f8f9fa;
    transition: background 0.3s ease;
    cursor: pointer;
}

.notification-item:hover {
    background: #f8f9fa;
}

.notification-item.unread {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeeba 100%);
    border-left: 4px solid #f39c12;
}

.notification-item.unread::before {
    content: '';
    width: 8px;
    height: 8px;
    background: #e74c3c;
    border-radius: 50%;
    position: absolute;
    right: 1rem;
    top: 1.5rem;
}

.notification-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: white;
    flex-shrink: 0;
}

.notification-icon.order {
    background: linear-gradient(135deg, #3498db, #2980b9);
}

.notification-icon.discount {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
}

.notification-icon.wishlist {
    background: linear-gradient(135deg, #e91e63, #ad1457);
}

.notification-icon.review {
    background: linear-gradient(135deg, #f39c12, #e67e22);
}

.notification-icon.announcement {
    background: linear-gradient(135deg, #9c27b0, #7b1fa2);
}

.notification-content {
    flex: 1;
}

.notification-content h5 {
    margin: 0 0 0.5rem 0;
    color: #2c3e50;
    font-size: 0.95rem;
    font-weight: 600;
}

.notification-content p {
    margin: 0 0 0.5rem 0;
    color: #6c757d;
    font-size: 0.85rem;
    line-height: 1.4;
}

.notification-time {
    font-size: 0.75rem;
    color: #95a5a6;
}

.notification-actions {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.notification-actions button {
    padding: 0.3rem 0.8rem;
    border: none;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.track-btn, .shop-now-btn, .buy-now-btn {
    background: #e74c3c;
    color: white;
}

.review-btn, .learn-more-btn {
    background: #f39c12;
    color: white;
}

.notification-actions button:hover {
    transform: scale(1.05);
}

.notifications-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid #e9ecef;
    text-align: center;
}

.view-all-notifications {
    background: #2c3e50;
    color: white;
    border: none;
    padding: 0.8rem 2rem;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.view-all-notifications:hover {
    background: #34495e;
}

/* Notifications Modal */
.notifications-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e9ecef;
}

.notification-filters {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.notification-filters select {
    padding: 0.5rem 1rem;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: white;
}

.clear-notifications-btn {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.notifications-modal-list {
    max-height: 600px;
    overflow-y: auto;
    padding-right: 1rem;
}

.notifications-modal-list .notification-item {
    margin-bottom: 1rem;
    border: 1px solid #e9ecef;
    border-radius: 10px;
    padding: 1.5rem;
}

.load-more-notifications {
    text-align: center;
    padding: 2rem 0;
}

.load-more-btn {
    background: #6c757d;
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.load-more-btn:hover {
    background: #5a6268;
}

/* About Section */
.about-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.about-header {
    text-align: center;
    margin-bottom: 3rem;
}

.about-header h2 {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    color: #2c3e50;
    margin-bottom: 1rem;
}

.about-header p {
    font-size: 1.2rem;
    color: #6c757d;
}

.about-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 4rem;
    align-items: start;
}

.about-text {
    display: grid;
    gap: 2rem;
}

.about-item {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
}

.about-icon {
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    background: #3498db;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
}

.about-info h3 {
    font-size: 1.3rem;
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

.about-info p {
    color: #6c757d;
    line-height: 1.6;
}

.about-stats {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    display: grid;
    gap: 1.5rem;
}

.stat {
    text-align: center;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: #3498db;
    margin-bottom: 0.5rem;
}

.stat-label {
    color: #6c757d;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Footer */
.footer {
    background: #2c3e50;
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-brand {
    display: flex;
    align-items: center;
    font-size: 1.5rem;
    font-weight: 700;
    color: #e74c3c;
    margin-bottom: 1rem;
}

.footer-brand i {
    margin-right: 10px;
}

.footer-section h4 {
    margin-bottom: 1rem;
    color: #ecf0f1;
}

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

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: #bdc3c7;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section ul li a:hover {
    color: #e74c3c;
}

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

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: #34495e;
    color: white;
    border-radius: 50%;
    text-decoration: none;
    transition: background 0.3s ease;
}

.social-links a:hover {
    background: #e74c3c;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #34495e;
    color: #bdc3c7;
}

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

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

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

/* Enhanced Responsive Design */
@media (max-width: 1200px) {
    .container {
        padding: 0 1rem;
    }
    
    .books-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 1.5rem;
    }
    
    .sidebar {
        width: 350px;
    }
    
    .modal-content.large-modal {
        width: 95%;
        max-width: 700px;
    }
}

@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
        gap: 1rem;
    }
    
    .nav-actions {
        order: -1;
        width: 100%;
        justify-content: space-between;
    }
    
    .search-input {
        width: 200px;
    }
    
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .books-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 1rem;
    }
    
    .sidebar {
        width: 100%;
        max-width: none;
    }
    
    .book-details {
        flex-direction: column;
        text-align: center;
    }
    
    .modal-content {
        margin: 1rem;
        max-width: calc(100% - 2rem);
        padding: 1.5rem;
    }
    
    .card-details {
        grid-template-columns: 1fr;
    }
    
    .filters {
        grid-template-columns: 1fr;
        gap: 1rem;
        justify-content: center;
    }
    
    .price-slider {
        width: 250px;
    }
    
    .view-options {
        gap: 0.5rem;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .comparison-grid {
        grid-template-columns: 100px repeat(auto, 1fr);
    }
    
    .order-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .settings-tabs {
        flex-direction: column;
    }
    
    .recently-viewed-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
    
    .breadcrumb {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .nav-left {
        gap: 1rem;
    }
    
    .nav-right {
        gap: 1rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .hero-content h1 {
        font-size: 1.8rem;
    }
    
    .books-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
    
    .book-details-image {
        width: 150px;
        height: 225px;
    }
    
    .book-card {
        padding: 1rem;
    }
    
    .book-actions {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .recently-viewed-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 0.8rem;
    }
    
    .sidebar-header {
        padding: 1rem;
    }
    
    .sidebar-content {
        padding: 1rem;
    }
    
    .logo {
        font-size: 1.2rem;
    }
    
    .search-container {
        min-width: 200px;
    }
    
    .hero {
        padding: 3rem 0;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
}

/* Print Styles */
@media print {
    .sidebar,
    .modal,
    .loading-overlay,
    header,
    footer,
    .floating-cart,
    .book-actions,
    .filters,
    .view-options {
        display: none !important;
    }
    
    .books-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .book-card {
        break-inside: avoid;
        border: 1px solid #ddd;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .book-card,
    .modal-content,
    .sidebar {
        border: 2px solid #000;
    }
    
    .btn {
        border: 2px solid;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    :root {
        --bg-color: #1a1a1a;
        --text-color: #ffffff;
        --card-bg: #2d2d2d;
        --border-color: #404040;
    }
    
    body {
        background: var(--bg-color);
        color: var(--text-color);
    }
    
    .book-card,
    .modal-content,
    .sidebar {
        background: var(--card-bg);
        border-color: var(--border-color);
    }
    
    .search-input,
    .filter-select {
        background: var(--card-bg);
        color: var(--text-color);
        border-color: var(--border-color);
    }
}

/* Focus Visible Support */
.btn:focus-visible,
.search-input:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
.user-menu-toggle:focus-visible {
    outline: 2px solid #3498db;
    outline-offset: 2px;
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Contact Section */
.contact-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header h2 {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    color: #2c3e50;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.section-header p {
    font-size: 1.2rem;
    color: #6c757d;
}

.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
}

.contact-info {
    display: grid;
    gap: 2rem;
}

.contact-card {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    text-align: center;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.contact-card:hover {
    transform: translateY(-5px);
    border-color: #3498db;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.contact-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #3498db, #2980b9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    color: white;
    font-size: 1.5rem;
}

.contact-card h3 {
    font-size: 1.3rem;
    color: #2c3e50;
    margin-bottom: 1rem;
}

.contact-card p {
    color: #6c757d;
    line-height: 1.6;
}

.contact-form-container {
    background: white;
    padding: 2.5rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.contact-form h3 {
    font-size: 1.5rem;
    color: #2c3e50;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

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

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    outline: none;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.form-group textarea {
    resize: vertical;
    font-family: inherit;
}

.contact-submit-btn {
    width: 100%;
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.contact-submit-btn:hover {
    background: linear-gradient(135deg, #2980b9, #1f4e79);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.3);
}

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

/* Contact Section Responsive */
@media (max-width: 768px) {
    .contact-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .contact-form-container {
        padding: 2rem;
    }
    
    .contact-card {
        padding: 1.5rem;
    }
}

/* Enhanced Notification Styles */
.notification {
    position: fixed;
    top: 20px;
    right: -350px;
    background: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
    display: flex;
    align-items: center;
    gap: 1rem;
    z-index: 9999;
    transition: right 0.3s ease;
    min-width: 300px;
    max-width: 350px;
}

.notification.show {
    right: 20px;
}

.notification.success {
    border-left: 4px solid #27ae60;
}

.notification.error {
    border-left: 4px solid #e74c3c;
}

.notification.info {
    border-left: 4px solid #3498db;
}

.notification i {
    font-size: 1.2rem;
    color: #27ae60;
    flex-shrink: 0;
}

.notification.error i {
    color: #e74c3c;
}

.notification.info i {
    color: #3498db;
}

.notification span {
    font-weight: 500;
    color: #2c3e50;
    line-height: 1.4;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a1a1a1;
}

/* ===== COMPREHENSIVE RESPONSIVE DESIGN FIXES ===== */

/* Base responsive container */
html, body {
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
}

/* Fix all containers to prevent horizontal overflow */
.container,
.hero-container,
.books-grid,
.featured-books-container {
    max-width: 100%;
    overflow-x: hidden;
    box-sizing: border-box;
    padding-left: 1rem;
    padding-right: 1rem;
}

/* ===== DESKTOP / LAPTOP (1024px and up) ===== */
@media (min-width: 1024px) {
    .container {
        max-width: 1200px;
        padding: 0 2rem;
    }
    
    .hero-content {
        padding: 0 2rem;
    }
    
    .books-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 2rem;
    }
    
    .featured-books-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* ===== TABLET (768px - 1023px) ===== */
@media (max-width: 1023px) and (min-width: 769px) {
    .container {
        max-width: 95%;
        padding: 0 1.5rem;
    }
    
    .header .container {
        padding: 0 1rem;
    }
    
    .books-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem;
    }
    
    .featured-books-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .highlight-card {
        grid-template-columns: 60px 1fr 150px;
        padding: 1.5rem;
    }
}

/* ===== MOBILE LANDSCAPE (481px - 768px) ===== */
@media (max-width: 768px) and (min-width: 481px) {
    .container {
        padding: 0 1rem;
    }
    
    .header .container {
        flex-direction: column;
        gap: 1rem;
        padding: 1rem;
    }
    
    .nav-menu {
        order: 2;
        width: 100%;
    }
    
    .nav-menu ul {
        justify-content: center;
        flex-wrap: wrap;
        gap: 1rem;
    }
    
    .nav-menu li a {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
    
    .books-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .featured-books-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .hero-content {
        text-align: center;
        padding: 1rem;
    }
    
    .hero-content h1 {
        font-size: 2rem;
        line-height: 1.2;
    }
    
    .highlight-card {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 1rem;
    }
    
    .highlight-price {
        justify-self: center;
    }
}

/* ===== MOBILE PORTRAIT (320px - 480px) ===== */
@media (max-width: 480px) {
    /* Base layout fixes */
    .container {
        padding: 0 0.75rem;
        width: 100%;
    }
    
    .header {
        padding: 0.5rem 0;
    }
    
    .header .container {
        flex-direction: column;
        gap: 0.75rem;
        padding: 0.5rem;
    }
    
    /* Navigation fixes */
    .nav-brand {
        font-size: 1.25rem;
        text-align: center;
    }
    
    .nav-menu {
        width: 100%;
        order: 2;
    }
    
    .nav-menu ul {
        justify-content: center;
        flex-wrap: wrap;
        gap: 0.5rem;
        margin: 0;
        padding: 0;
    }
    
    .nav-menu li {
        margin: 0;
    }
    
    .nav-menu li a {
        padding: 0.4rem 0.8rem;
        font-size: 0.85rem;
        white-space: nowrap;
    }
    
    /* Hero section fixes */
    .hero-section {
        padding-top: 140px;
        padding-bottom: 2rem;
    }
    
    .hero-content {
        text-align: center;
        padding: 0.5rem;
    }
    
    .hero-content h1 {
        font-size: 1.75rem;
        line-height: 1.3;
        margin-bottom: 1rem;
    }
    
    .hero-content p {
        font-size: 0.95rem;
        margin-bottom: 1.5rem;
    }
    
    /* Buttons */
    .hero-buttons {
        flex-direction: column;
        gap: 1rem;
        align-items: center;
    }
    
    .cta-btn {
        width: 100%;
        max-width: 280px;
        padding: 0.875rem 1rem;
        font-size: 0.95rem;
    }
    
    /* Books grid */
    .books-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
        padding: 0 0.5rem;
    }
    
    .featured-books-grid {
        grid-template-columns: 1fr;
    }
    
    /* Book cards */
    .book-card {
        max-width: 100%;
        margin: 0 auto;
    }
    
    .book-card img {
        max-width: 120px;
        height: auto;
    }
    
    /* Highlight cards */
    .highlight-card {
        grid-template-columns: 1fr;
        padding: 1rem;
        text-align: center;
        gap: 1rem;
    }
    
    .highlight-icon {
        justify-self: center;
        margin-bottom: 0.5rem;
    }
    
    .highlight-price {
        justify-self: center;
        margin-top: 0.5rem;
    }
    
    /* Search and filters */
    .search-controls {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
    }
    
    .search-box,
    .filter-select {
        width: 100%;
    }
    
    /* Sidebars */
    .sidebar {
        width: 100%;
        max-width: 100vw;
        height: 100vh;
        border-radius: 0;
    }
    
    .sidebar-content {
        padding: 1rem;
        height: calc(100vh - 80px);
        overflow-y: auto;
    }
    
    /* Notifications */
    .notification {
        right: -100%;
        left: 10px;
        right: 10px;
        max-width: none;
        min-width: auto;
    }
    
    .notification.show {
        right: 10px;
    }
}

/* ===== EXTRA SMALL SCREENS (below 320px) ===== */
@media (max-width: 319px) {
    .container {
        padding: 0 0.5rem;
    }
    
    .hero-content h1 {
        font-size: 1.5rem;
    }
    
    .nav-menu li a {
        padding: 0.3rem 0.6rem;
        font-size: 0.8rem;
    }
    
    .cta-btn {
        padding: 0.75rem;
        font-size: 0.9rem;
    }
}

/* ===== LANDSCAPE ORIENTATION FIXES ===== */
@media (orientation: landscape) and (max-height: 500px) {
    .hero-section {
        padding-top: 100px;
        padding-bottom: 1rem;
    }
    
    .hero-content h1 {
        font-size: 1.8rem;
        margin-bottom: 0.5rem;
    }
    
    .hero-content p {
        font-size: 0.9rem;
        margin-bottom: 1rem;
    }
    
    .hero-buttons {
        gap: 0.75rem;
    }
}

/* ===== PREVENT HORIZONTAL SCROLL ===== */
* {
    max-width: 100%;
    box-sizing: border-box;
}

img {
    max-width: 100%;
    height: auto;
}

/* Fix any elements that might cause overflow */
.hero-content,
.books-section,
.featured-psychology-section,
.contact-section {
    width: 100%;
    overflow-x: hidden;
}