/* Products Page Styles */
.page-header {
    background: linear-gradient(135deg, var(--primary-color), var(--text-dark));
    color: white;
    padding: 5rem 0 3rem;
    margin-top: 70px;
    text-align: center;
}

.page-title {
    font-family: 'Playfair Display', serif;
    font-size: 3rem;
    margin-bottom: 1rem;
    animation: fadeInUp 0.8s ease;
}

.page-subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    animation: fadeInUp 0.8s ease 0.2s both;
}

/* Products Section */
.products-section {
    padding: 4rem 0;
}

.products-filter {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 10px 25px;
    background: transparent;
    border: 2px solid var(--border-color);
    border-radius: 25px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.filter-btn:hover {
    border-color: var(--accent-color);
    color: var(--accent-color);
}

.filter-btn.active {
    background: var(--accent-color);
    color: white;
    border-color: var(--accent-color);
}

/* Products Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2.5rem;
}

.product-card {
    background: var(--bg-white);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    position: relative;
    animation: fadeInUp 0.6s ease;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.product-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    background: var(--accent-color);
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    z-index: 2;
}

.product-image {
    height: 280px;
    overflow: hidden;
    background: linear-gradient(135deg, #f5f5f5, #e0e0e0);
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-card:hover .product-image img {
    transform: scale(1.1);
}

.product-content {
    padding: 2rem;
}

.product-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

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

.product-rating i {
    color: var(--accent-color);
    font-size: 0.9rem;
}

.product-rating span {
    margin-left: 0.5rem;
    color: var(--text-light);
    font-weight: 500;
}

.product-description {
    color: var(--text-light);
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.product-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.feature-tag {
    background: var(--bg-light);
    color: var(--text-dark);
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.85rem;
    font-weight: 500;
}

.product-price {
    font-size: 2rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.btn-product {
    display: inline-block;
    width: 100%;
    text-align: center;
    padding: 12px 25px;
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-weight: 500;
    transition: var(--transition);
}

.btn-product:hover {
    background: var(--accent-color);
    color: var(--primary-color);
}

/* Product Card Hiding Animation */
.product-card.hide {
    animation: fadeOut 0.3s ease forwards;
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: scale(0.9);
    }
}

/* Product Modal */
.product-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    overflow-y: auto;
    animation: fadeIn 0.3s ease;
}

.product-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.modal-content {
    background: var(--bg-white);
    border-radius: 20px;
    max-width: 1000px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: slideUp 0.3s ease;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: var(--bg-light);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 2rem;
    cursor: pointer;
    transition: var(--transition);
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.modal-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.modal-image {
    padding: 2rem;
}

.modal-image img {
    width: 100%;
    height: auto;
    border-radius: 15px;
    box-shadow: var(--shadow-sm);
}

.modal-details {
    padding: 2rem;
}

.modal-details h2 {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

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

.modal-rating i {
    color: var(--accent-color);
}

.modal-price {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--accent-color);
    margin-bottom: 2rem;
}

.modal-description,
.modal-features,
.modal-specs {
    margin-bottom: 2rem;
}

.modal-description h3,
.modal-features h3,
.modal-specs h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--border-color);
}

.modal-description p {
    color: var(--text-light);
    line-height: 1.8;
}

.modal-features .feature-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.feature-item i {
    color: var(--accent-color);
}

.modal-specs ul {
    list-style: none;
    padding: 0;
}

.modal-specs li {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-light);
    display: flex;
    justify-content: space-between;
}

.modal-specs li strong {
    color: var(--text-dark);
}

.modal-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.btn-buy,
.btn-wishlist {
    padding: 15px 25px;
    border: none;
    border-radius: 25px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    font-size: 1rem;
}

.btn-buy {
    background: var(--accent-color);
    color: white;
}

.btn-buy:hover {
    background: var(--primary-color);
    transform: translateY(-2px);
}

.btn-wishlist {
    background: transparent;
    border: 2px solid var(--accent-color);
    color: var(--accent-color);
}

.btn-wishlist:hover {
    background: var(--accent-color);
    color: white;
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .modal-body {
        grid-template-columns: 1fr;
    }

    .modal-image {
        padding: 1rem;
    }

    .modal-details {
        padding: 1rem;
    }

    .modal-price {
        font-size: 2rem;
    }

    .modal-actions {
        grid-template-columns: 1fr;
    }

    .modal-features .feature-grid {
        grid-template-columns: 1fr;
    }
}

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

    .page-subtitle {
        font-size: 1rem;
    }

    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 1.5rem;
    }

    .product-content {
        padding: 1.5rem;
    }

    .product-title {
        font-size: 1.3rem;
    }

    .product-price {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .products-filter {
        flex-direction: column;
        align-items: stretch;
    }

    .filter-btn {
        width: 100%;
    }

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

    .product-image {
        height: 250px;
    }
}