/* Product Detail Page Specific Styles */

/* Product Detail Section */
.product-detail {
    padding: 100px 0;
    background-color: var(--light);
    margin-top: 70px;
}

.product-detail-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    margin-bottom: 80px;
}

/* Product Images */
.product-images {
    display: flex;
    flex-direction: column;
}

.main-image {
    width: 100%;
    height: 500px;
    overflow: hidden;
    border-radius: 8px;
    margin-bottom: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.main-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.image-thumbnails {
    display: flex;
    gap: 10px;
}

.thumbnail {
    width: 80px;
    height: 80px;
    border-radius: 4px;
    overflow: hidden;
    cursor: pointer;
    opacity: 0.7;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.thumbnail:hover,
.thumbnail.active {
    opacity: 1;
    border-color: var(--primary);
}

.thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Product Info */
.product-info h1 {
    font-size: 2.2rem;
    margin-bottom: 10px;
    color: var(--text);
}

.product-brand {
    color: var(--secondary);
    font-weight: 500;
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.product-rating {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.product-rating .stars {
    color: #FFD700;
    margin-right: 10px;
}

.rating-count {
    color: var(--secondary);
    font-size: 0.9rem;
}

.product-price {
    display: flex;
    align-items: center;
    margin-bottom: 25px;
}

.current-price {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary);
    margin-right: 15px;
}

.original-price {
    font-size: 1.4rem;
    text-decoration: line-through;
    color: var(--secondary);
    margin-right: 15px;
}

.discount {
    background-color: #e74c3c;
    color: white;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.9rem;
    font-weight: 500;
}

.product-description {
    margin-bottom: 25px;
}

.product-description p {
    line-height: 1.8;
    color: var(--text);
}

.product-features {
    margin-bottom: 30px;
}

.product-features h3 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: var(--text);
}

.product-features ul {
    list-style: none;
}

.product-features li {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    color: var(--text);
}

.product-features i {
    color: var(--primary);
    margin-right: 10px;
}

.product-actions {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
}

.product-actions .btn-primary,
.product-actions .btn-secondary {
    padding: 15px 30px;
}

.product-actions .btn-secondary {
    background-color: transparent;
    color: var(--primary);
    border: 1px solid var(--primary);
}

.product-actions .btn-secondary:hover {
    background-color: var(--primary);
    color: var(--accent);
}

.product-meta {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.meta-item {
    display: flex;
    align-items: center;
    color: var(--text);
}

.meta-item i {
    color: var(--primary);
    margin-right: 10px;
    width: 20px;
}

/* Product Tabs */
.product-tabs {
    margin-bottom: 80px;
}

.tab-headers {
    display: flex;
    border-bottom: 1px solid var(--secondary);
    margin-bottom: 30px;
}

.tab-header {
    background: none;
    border: none;
    padding: 15px 25px;
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    font-weight: 500;
    color: var(--text);
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.tab-header::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 0;
    height: 3px;
    background-color: var(--primary);
    transition: width 0.3s ease;
}

.tab-header:hover::after,
.tab-header.active::after {
    width: 100%;
}

.tab-header.active {
    color: var(--primary);
}

.tab-pane {
    display: none;
}

.tab-pane.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.tab-pane h3 {
    font-size: 1.4rem;
    margin-bottom: 20px;
    color: var(--text);
}

.tab-pane p {
    line-height: 1.8;
    margin-bottom: 20px;
    color: var(--text);
}

.tab-pane ul {
    margin-left: 20px;
    margin-bottom: 20px;
}

.tab-pane li {
    margin-bottom: 10px;
    color: var(--text);
}

/* Specifications */
.specs-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.spec-item {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid var(--secondary);
}

.spec-label {
    font-weight: 500;
    color: var(--text);
}

.spec-value {
    color: var(--text);
}

/* Reviews */
.reviews-summary {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 40px;
    margin-bottom: 40px;
    padding: 25px;
    background-color: var(--accent);
    border-radius: 8px;
}

.overall-rating {
    text-align: center;
}

.average-rating {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 10px;
}

.overall-rating .stars {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.overall-rating p {
    color: var(--secondary);
    margin: 0;
}

.rating-bars {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.rating-bar {
    display: flex;
    align-items: center;
    gap: 15px;
}

.star-count {
    width: 60px;
    color: var(--text);
    font-size: 0.9rem;
}

.bar {
    flex-grow: 1;
    height: 8px;
    background-color: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
}

.fill {
    height: 100%;
    background-color: var(--primary);
    border-radius: 4px;
}

.percentage {
    width: 40px;
    text-align: right;
    color: var(--text);
    font-size: 0.9rem;
}

.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.review {
    padding: 25px;
    background-color: var(--accent);
    border-radius: 8px;
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    flex-wrap: wrap;
    gap: 10px;
}

.reviewer {
    font-weight: 600;
    color: var(--text);
}

.review-date {
    color: var(--secondary);
    font-size: 0.9rem;
}

.review-rating {
    color: #FFD700;
}

.review-title {
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--text);
}

.review-content p {
    margin: 0;
    line-height: 1.6;
    color: var(--text);
}

/* Related Products */
.related-products {
    margin-bottom: 50px;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
    margin-top: 50px;
}

.product-card {
    background-color: var(--light);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
}

.product-image {
    position: relative;
    overflow: hidden;
    height: 250px;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.product-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(44, 62, 80, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.product-card:hover .product-overlay {
    opacity: 1;
}

.view-btn {
    background-color: var(--accent);
    color: var(--primary);
    padding: 10px 20px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.view-btn:hover {
    background-color: var(--primary);
    color: var(--accent);
}

.product-info {
    padding: 20px;
    text-align: center;
}

.product-info h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: var(--text);
}

.brand {
    color: var(--secondary);
    font-weight: 400;
    margin-bottom: 10px;
    display: block;
}

.price {
    font-weight: 600;
    color: var(--primary);
    font-size: 1.1rem;
}

.original-price {
    text-decoration: line-through;
    color: var(--secondary);
    font-size: 0.9rem;
    margin-left: 8px;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 992px) {
    .product-detail-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .specs-grid {
        grid-template-columns: 1fr;
    }
    
    .reviews-summary {
        grid-template-columns: 1fr;
    }
    
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .product-actions {
        flex-direction: column;
    }
    
    .tab-headers {
        flex-wrap: wrap;
    }
    
    .tab-header {
        padding: 10px 15px;
        font-size: 0.9rem;
    }
    
    .review-header {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 576px) {
    .product-detail {
        padding: 80px 0;
    }
    
    .main-image {
        height: 350px;
    }
    
    .image-thumbnails {
        flex-wrap: wrap;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .product-info h1 {
        font-size: 1.8rem;
    }
    
    .current-price {
        font-size: 1.5rem;
    }
}