/* Enhanced Base Styles */
:root {
    --primary-color: #f59e0b;
    --primary-dark: #d97706;
    --secondary-color: #4f46e5;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --bg-primary: #f8fafc;
    --bg-secondary: #f1f5f9;
}

body { 
    background-color: #ffffff;
    font-family: 'Inter', sans-serif;
    scroll-behavior: smooth;
    overflow-y: scroll !important;
}

.hero-section {
    background-color: #f1f5f9;
    background-image: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%), url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='40' viewBox='0 0 40 40'%3E%3Cg fill-rule='evenodd'%3E%3Cg fill='%2394a3b8' fill-opacity='0.1'%3E%3Cpath d='M0 38.59l2.83-2.83 1.41 1.41L1.41 40H0v-1.41zM0 1.4l2.83 2.83 1.41-1.41L1.41 0H0v1.41zM38.59 40l-2.83-2.83 1.41-1.41L40 38.59V40h-1.41zM40 1.41l-2.83 2.83-1.41-1.41L38.59 0H40v1.41zM20 18.6l2.83-2.83 1.41 1.41L21.41 20l2.83 2.83-1.41 1.41L20 21.41l-2.83 2.83-1.41-1.41L18.59 20l-2.83-2.83 1.41-1.41L20 18.59z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

/* Animations */
@keyframes fadeInUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
.animate-fadeInUp { animation: fadeInUp 1.2s cubic-bezier(0.4, 0, 0.2, 1) forwards; }
@keyframes slideIn { from { opacity: 0; transform: translateX(-20px); } to { opacity: 1; transform: translateX(0); } }
.animate-slideIn { animation: slideIn 0.5s ease-out forwards; }
@keyframes slideInFromTop { from { opacity: 0; transform: translateY(-50px); } to { opacity: 1; transform: translateY(0); } }
.animate-slideInFromTop { animation: slideInFromTop 0.8s ease-out forwards; }

/* Special Animated Gradient Text */
.animated-gradient-text {
    background: linear-gradient(90deg, #f59e0b, #d946ef, #f59e0b);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradient-animation 4s linear infinite;
}

@keyframes gradient-animation {
    to {
        background-position: 200% center;
    }
}

/* Live Filter Styles */
.filter-btn {
    padding: 10px 24px;
    border: 2px solid #e2e8f0;
    border-radius: 9999px;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.5px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    color: #475569;
    cursor: pointer;
    background-color: #ffffff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.filter-btn:hover {
    background-color: #fca5a5;
    border-color: #f87171;
    color: #7f1d1d;
}
.filter-btn.active {
    background-color: #ef4444;
    color: #ffffff;
    border-color: #ef4444;
    transform: scale(1.05);
    box-shadow: 0 4px 14px rgba(239, 68, 68, 0.3);
}

.service-card.hidden-by-filter {
    transform: scale(0.9);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
    pointer-events: none;
}

/* Enhanced Flipkart-Style Mobile Menu */
.mobile-menu-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 85%;
    max-width: 320px;
    height: 100vh;
    background: linear-gradient(180deg, #ffffff 0%, #f8f9fa 100%);
    z-index: 1000;
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.15);
    overflow-y: auto;
    transform: translateX(-100%);
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    backdrop-filter: blur(10px);
    border-right: 1px solid #e2e8f0;
}

.mobile-menu-container.show {
    transform: translateX(0);
}

.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.4));
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s ease;
    backdrop-filter: blur(2px);
}

.mobile-menu-overlay.show {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-content {
    padding: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
}

/* --- Styling for Mobile Menu User Profile --- */
.user-profile-section {
    background: #ffffff;
    padding: 20px 16px;
    border-bottom: 1px solid #e2e8f0;
}

.user-avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background-color: #f59e0b;
    border-radius: 50%;
}

.user-info h3 {
    font-size: 1.125rem;
    font-weight: 700;
    color: #0c0d0dff;
    margin: 0;
    line-height: 1.2;
}

.user-info p {
    font-size: 0.875rem;
    color: #0c0d0dff;
    margin: 0;
}

/* Enhanced Menu Items */
.menu-items {
    flex: 1;
    padding: 0;
    background: white;
}

.menu-section-title {
    padding: 16px 20px 8px;
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid #f1f5f9;
    background: #f8f9fa;
}

.menu-item {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    color: #1f2937;
    text-decoration: none;
    border-bottom: 1px solid #f1f5f9;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    font-weight: 500;
    position: relative;
    transform: translateX(-10px);
    opacity: 0;
}

.mobile-menu-container.show .menu-item {
    animation: slideInMenuLeft 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.menu-item:hover {
    background: linear-gradient(135deg, #fef3c7, #fbbf24);
    color: #92400e;
    transform: translateX(5px);
    box-shadow: inset 4px 0 #f59e0b;
}

.menu-item.active {
    background: linear-gradient(135deg, #fef3c7, #fbbf24);
    color: #92400e;
    border-left: 4px solid #f59e0b;
    box-shadow: 0 2px 10px rgba(245, 158, 11, 0.2);
}

.menu-item-icon {
    margin-right: 16px;
    color: #6b7280;
    transition: all 0.3s ease;
    width: 20px;
    height: 20px;
}

.menu-item:hover .menu-item-icon,
.menu-item.active .menu-item-icon {
    color: #d97706;
    transform: scale(1.1);
}

.menu-item-text {
    flex: 1;
    font-size: 15px;
}

.menu-item-arrow {
    width: 16px;
    height: 16px;
    color: #9ca3af;
    transition: transform 0.3s ease;
}

.menu-item:hover .menu-item-arrow {
    transform: translateX(3px);
    color: #d97706;
}

@keyframes slideInMenuLeft {
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Staggered Animation Delays */
.menu-item:nth-child(1) { animation-delay: 0.1s; }
.menu-item:nth-child(2) { animation-delay: 0.15s; }
.menu-item:nth-child(3) { animation-delay: 0.2s; }
.menu-item:nth-child(4) { animation-delay: 0.25s; }
.menu-item:nth-child(5) { animation-delay: 0.3s; }
.menu-item:nth-child(6) { animation-delay: 0.35s; }
.menu-item:nth-child(7) { animation-delay: 0.4s; }
.menu-item:nth-child(8) { animation-delay: 0.45s; }

/* Enhanced Mobile Header Layout */
@media (max-width: 768px) {
    .mobile-header-layout { display: flex; align-items: center; width: 100%; gap: 6px; }
    .mobile-menu-btn { flex-shrink: 0; order: 1; padding: 8px; border-radius: 6px; transition: all 0.2s ease; }
    .mobile-logo { flex-shrink: 0; order: 2; margin-left: 2px; }
    .mobile-logo svg { width: 18px; height: 18px; }
    .mobile-logo span { font-size: 15px; }
    .mobile-search-btn { flex-shrink: 0; order: 3; padding: 6px; margin-left: auto; border-radius: 4px; transition: background-color 0.15s ease; }
    .mobile-search-btn:hover { background-color: rgba(245, 158, 11, 0.1); }
    .mobile-login { flex-shrink: 0; order: 4; padding: 6px 10px; border-radius: 4px; transition: background-color 0.15s ease; font-size: 11px; }
    .mobile-login:hover { background-color: rgba(245, 158, 11, 0.1); }
    .mobile-cart { flex-shrink: 0; order: 5; padding: 6px; border-radius: 4px; transition: background-color 0.15s ease; }
    .mobile-cart:hover { background-color: rgba(245, 158, 11, 0.1); }
}

/* Search Bar */
#mobile-search-bar { transition: all 0.3s ease-in-out; }
#mobile-search-bar.show { display: block !important; }
body.menu-open { overflow: hidden; }

/* Cart Styles */
.add-to-cart .tick { font-size: 1.2em; margin-left: 5px; }
.add-to-cart { transition: all 0.3s ease; }

/* Enhanced Security Overlay */
.overlay {
    display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6); z-index: 999; opacity: 0;
    transition: opacity 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    backdrop-filter: blur(2px);
}
.overlay.show { display: block; opacity: 1; }

/* Enhanced Service Popup with Security */
.service-popup {
    display: none; position: fixed; z-index: 1000; overflow-y: auto; border: none;
    opacity: 0; transition: all 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    will-change: transform, opacity; transform-origin: center center; overscroll-behavior: contain;
}
.service-popup.show { display: block; opacity: 1; }

/* Desktop Animation */
@media (min-width: 769px) {
    .service-popup {
        background: white; box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15); padding: 0;
        border-radius: 16px; max-width: 90%; width: 600px; max-height: 90vh;
        top: 50%; left: 50%; transform: translate(-50%, -50%) scale(0.8);
    }
    .service-popup.show { transform: translate(-50%, -50%) scale(1); }
    .service-popup.closing { transform: translate(-50%, -50%) scale(0.9); opacity: 0; }
}

/* Enhanced Mobile Animation */
@media (max-width: 768px) {
    .service-popup {
        background: #ffffff; box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.15);
        width: 100%; max-width: 100%; left: 0; bottom: 0; border-radius: 24px 24px 0 0;
        padding: 0; padding-top: 12px; max-height: 75vh; transform: translateY(100%);
        transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    }
    .service-popup.show { transform: translateY(0); }
    .service-popup.closing { transform: translateY(100%); }
    .service-popup::before {
        content: ''; position: absolute; top: 8px; left: 50%;
        transform: translateX(-50%); width: 50px; height: 5px;
        background-color: #cbd5e1; border-radius: 3px;
    }
}

/* Enhanced Close Button with Security */
.service-popup .close-btn {
    position: absolute; top: 12px; right: 12px; background: #f1f5f9; color: #475569;
    border-radius: 50%; cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    z-index: 10; display: flex; align-items: center; justify-content: center;
    width: 36px; height: 36px; border: none;
}
.service-popup .close-btn:hover { background: #e2e8f0; transform: rotate(90deg) scale(1.1); }

/* POPUP CONTENT STYLES */
.popup-content-area { padding: 1rem 1.5rem 1.5rem; }
.popup-section { padding: 1.5rem 0; border-bottom: 1px solid #e2e8f0; }
.popup-section:last-child { border-bottom: none; }
#review-wrapper .popup-section:last-child { border-bottom: 1px solid #e2e8f0 !important; }
#review-list-container { transition: opacity 0.4s ease-in-out; }
.popup-section-title { font-size: 1.5rem; font-weight: 700; color: #1e293b; margin-bottom: 1.5rem; font-family: 'Poppins', sans-serif; }
.process-step { display: flex; position: relative; padding-left: 2.5rem; padding-bottom: 1.5rem; }
.process-step:last-child { padding-bottom: 0; }
.process-step-number { position: absolute; left: 0; top: 0; width: 32px; height: 32px; background-color: #f1f5f9; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 600; color: #475569; border: 1px solid #e2e8f0; }
.process-step::before { content: ''; position: absolute; left: 15px; top: 32px; bottom: 0; width: 2px; background-color: #e2e8f0; }
.process-step:last-child::before { display: none; }
.process-step-title { font-size: 1rem; font-weight: 600; color: #1e293b; margin-bottom: 0.25rem; }
.process-step-desc { font-size: 0.9rem; color: #64748b; line-height: 1.5; }
.faq-item { border-bottom: 1px solid #e2e8f0; }
.faq-item:last-child { border-bottom: none; }
.faq-question { display: flex; align-items: center; justify-content: space-between; cursor: pointer; padding: 0.5rem 0; font-size: 1rem; font-weight: 500; color: #1e293b; }
.faq-question:hover { background-color: #f8fafc; }
.faq-toggle { transition: transform 0.3s ease; width: 20px; height: 20px; color: #64748b; }
.faq-toggle.open { transform: rotate(180deg); }
.faq-answer { display: none; padding-bottom: 0.75rem; font-size: 0.9rem; color: #4a5568; line-height: 1.6; }
.faq-answer.show { display: block; }

/* Floating Cart */
#floating-cart { position: fixed; bottom: 0; left: 0; right: 0; z-index: 999; transition: transform 0.3s ease-in-out; transform: translateY(100%); }
#floating-cart.show { transform: translateY(0); }
@media (max-width: 320px) { .mobile-menu-container { width: 100%; } }

/* REVIEW STYLES */
.review-summary-header { display: flex; align-items: center; gap: 1rem; margin-bottom: 1rem; }
.review-summary-header .avg-rating { font-size: 2.5rem; font-weight: 700; color: #1e293b; }
.review-summary-header .total-reviews { font-size: 1rem; color: #64748b; }
.rating-breakdown .rating-row { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 4px; }
.rating-breakdown .rating-label { font-size: 0.875rem; color: black; width: 45px; display: flex; align-items: center; }
.rating-breakdown .bar-container { flex: 1; background-color: #e2e8f0; border-radius: 999px; height: 8px; overflow: hidden; }
.rating-breakdown .bar { height: 100%; border-radius: 999px; width: 0; transition: width 0.8s cubic-bezier(0.25, 1, 0.5, 1); }
.bar.rating-5 { background-color: #22c55e; }
.bar.rating-4 { background-color: #84cc16; }
.bar.rating-3 { background-color: #f59e0b; }
.bar.rating-2 { background-color: #f97316; }
.bar.rating-1 { background-color: #ef4444; }
.rating-breakdown .rating-count { font-size: 0.875rem; color: #475569; width: 30px; text-align: right; }
.review-card { padding: 1.5rem 0; border-bottom: 1px solid #e2e8f0; }
.review-card:last-child { border-bottom: none; padding-bottom: 0; }
.review-card-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 0.75rem; }
.review-card .reviewer-info { display: flex; align-items: center; gap: 0.75rem; }
.review-card .reviewer-avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }
.review-card .reviewer-name { font-size: 1rem; font-weight: 600; color: #1e293b; }
.review-card .review-meta { font-size: 0.8rem; color: #64748b; margin-top: 2px; }
.rating-badge { display: flex; align-items: center; gap: 4px; color: white; padding: 4px 8px; border-radius: 999px; font-size: 0.8rem; font-weight: 600; }
.rating-badge svg { width: 14px; height: 14px; }
.rating-badge.good { background-color: #22c55e; }
.rating-badge.average { background-color: #f59e0b; }
.rating-badge.poor { background-color: #ef4444; }
#reviews-sort-options { transition: all 0.2s ease-out; }
#reviews-sort-options.hidden { transform: scale(0.95); opacity: 0; pointer-events: none; }