/* Product Details Page Styles - Using website standard colors */

/* Product Header Section */
.product-header-section {
    background: #ffffff;
    padding: 30px 0;
    border-bottom: 1px solid #e5e7eb;
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
}

.header-main {
    max-width: 800px;
}

.category-tag {
    display: inline-block;
    background: #356DF1;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
    margin-bottom: 12px;
}

.product-header-section .product-title {
    font-size: 32px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 16px 0;
    line-height: 1.3;
}

.instructor-info {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
}

.instructor-label {
    color: #666;
    font-size: 14px;
}

.instructor-link {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: #356DF1;
    font-weight: 500;
}

.instructor-link:hover {
    color: #2563eb;
}

.instructor-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
}

.header-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.header-meta .meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #666;
    font-size: 14px;
}

.header-meta .meta-item svg {
    color: #356DF1;
}

/* Product Details Layout */
.product-details-layout {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 40px;
    padding: 40px 0;
}

/* Product Tabs */
.product-content {
    margin-bottom: 40px;
}

.product-tabs {
    display: flex;
    border-bottom: 1px solid #e5e7eb;
    margin-bottom: 30px;
}

.tab-button {
    padding: 12px 24px;
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    color: #666;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tab-button:hover {
    color: #356DF1;
}

.tab-button.active {
    color: #356DF1;
    border-bottom-color: #356DF1;
}

.tab-panel {
    display: none;
}

.tab-panel.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.section-title {
    font-size: 22px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 20px 0;
}

/* Benefits Section */
.what-youll-learn {
    margin-bottom: 40px;
}

.learn-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.learn-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 16px;
    background: #f8fafc;
    border-radius: 8px;
    transition: all 0.2s;
}

.learn-item:hover {
    background: #f0f4f8;
    transform: translateX(4px);
}

.check-icon {
    flex-shrink: 0;
    margin-top: 2px;
}

.learn-item span {
    color: #333;
    font-size: 15px;
    line-height: 1.5;
}

/* Product Description */
.product-description {
    margin-bottom: 30px;
}

.description-content {
    line-height: 1.8;
    color: #555;
    font-size: 15px;
}

/* Data Structure Section */
.curriculum-section {
    margin-bottom: 20px;
}

.curriculum-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 12px;
}

.curriculum-meta {
    display: flex;
    gap: 8px;
    color: #666;
    font-size: 14px;
}

.curriculum-section-item {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    margin-bottom: 12px;
    overflow: hidden;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    background: #f8fafc;
    border-bottom: 1px solid #e0e0e0;
}

.section-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    background: #356DF1;
    color: white;
    border-radius: 50%;
    font-size: 14px;
    font-weight: 600;
}

.section-header .section-title {
    flex: 1;
    font-size: 16px;
    font-weight: 600;
    margin: 0;
}

.section-lessons-count {
    color: #666;
    font-size: 13px;
}

.section-content {
    background: white;
}

.lesson-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.2s;
}

.lesson-item:last-child {
    border-bottom: none;
}

.lesson-item:hover {
    background: #f8fafc;
}

.lesson-icon {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #356DF1;
}

.lesson-title {
    flex: 1;
    color: #333;
    font-size: 14px;
}

.lesson-duration {
    color: #888;
    font-size: 13px;
    padding: 4px 8px;
    background: #f5f5f5;
    border-radius: 4px;
}

/* Supplier Section */
.instructor-profile {
    display: flex;
    gap: 30px;
    padding: 30px;
    background: #f8fafc;
    border-radius: 12px;
}

.instructor-avatar-large img {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid white;
}

.instructor-info-details {
    flex: 1;
}

.instructor-info-details .instructor-name {
    font-size: 24px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 4px 0;
}

.instructor-title {
    color: #666;
    font-size: 15px;
    margin: 0 0 16px 0;
}

.instructor-bio {
    color: #555;
    line-height: 1.7;
    margin: 0 0 20px 0;
}

.instructor-social {
    display: flex;
    gap: 12px;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: white;
    border-radius: 50%;
    color: #666;
    transition: all 0.2s;
}

.social-link:hover {
    background: #356DF1;
    color: white;
    transform: translateY(-2px);
}

/* Reviews Section */
.reviews-layout {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 40px;
}

.rating-overview {
    background: #f8fafc;
    padding: 24px;
    border-radius: 12px;
    height: fit-content;
}

.rating-big {
    text-align: center;
    margin-bottom: 24px;
}

.rating-big .rating-value {
    font-size: 48px;
    font-weight: 700;
    color: #1a1a1a;
    display: block;
}

.rating-big .rating-stars {
    display: flex;
    justify-content: center;
    gap: 4px;
    margin: 8px 0;
}

.rating-big .rating-count {
    color: #666;
    font-size: 14px;
}

.rating-distribution {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.distribution-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.star-label {
    width: 50px;
    font-size: 13px;
    color: #666;
}

.progress-bar {
    flex: 1;
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #FFB800, #FFC933);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.percentage {
    width: 40px;
    text-align: right;
    font-size: 13px;
    color: #666;
}

.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.review-item {
    padding: 20px;
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
}

.review-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.reviewer-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
}

.reviewer-info {
    flex: 1;
}

.reviewer-name {
    font-size: 16px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 4px 0;
}

.review-rating {
    display: flex;
    gap: 2px;
}

.review-title {
    margin-bottom: 8px;
}

.review-title strong {
    color: #333;
}

.review-date {
    color: #999;
    font-size: 13px;
}

.review-content p {
    color: #555;
    line-height: 1.6;
    margin: 0;
}

.no-reviews {
    text-align: center;
    padding: 40px;
    color: #666;
}

/* Product Sidebar */
.product-sidebar {
    position: relative;
}

.product-card {
    background: #f5f7f8;
    border-radius: 12px;
    overflow: hidden;
    position: sticky;
    top: 20px;
}

.product-image {
    position: relative;
    overflow: hidden;
}

.product-thumbnail {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s;
}

.product-card:hover .product-thumbnail {
    transform: scale(1.05);
}

.product-card-content {
    padding: 24px;
}

.product-price {
    text-align: center;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e0e0e0;
}

.product-price .price {
    font-size: 28px;
    font-weight: 700;
    color: #28a745;
}

.product-price .old-price {
    font-size: 18px;
    font-weight: 400;
    color: #dc3545;
    text-decoration: line-through;
    margin-left: 10px;
}

/* Ẩn phần trăm giảm vì không cần thiết */
.product-price .discount {
    display: none;
}

.btn-order, .btn-cart {
    width: 100%;
    padding: 14px 20px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 10px;
}

.btn-order {
    background: #356DF1;
    color: white;
}

.btn-order:hover {
    background: #000000;
}

.btn-cart {
    background: white;
    color: #356DF1;
    border: 2px solid #356DF1;
}

.btn-cart:hover {
    background: #356DF1;
    color: white;
}

.btn-order.disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Product Meta Info */
.product-meta-info {
    padding: 20px 0;
    border-bottom: 1px solid #e0e0e0;
    margin-bottom: 20px;
}

.meta-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 14px;
}

.meta-row svg {
    color: #356DF1;
    flex-shrink: 0;
}

.meta-row .label {
    color: #666;
    flex: 1;
}

.meta-row .value {
    color: #333;
    font-weight: 500;
}

.product-info h5 {
    font-size: 15px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 12px 0;
}

.product-info ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.product-info li {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    color: #555;
    font-size: 14px;
}

/* Related Products Section */
.related-products-section {
    padding: 60px 0;
    background: #f8fafc;
}

.related-title {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 30px 0;
    text-align: center;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.product-item {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s;
}

.product-item:hover {
    transform: translateY(-4px);
}

.product-item .product-image {
    aspect-ratio: 16/10;
}

.product-item .product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-item .product-content {
    padding: 20px;
}

.product-item .product-title {
    font-size: 16px;
    font-weight: 600;
    margin: 0 0 8px 0;
}

.product-item .product-title a {
    color: #1a1a1a;
    text-decoration: none;
    transition: color 0.2s;
}

.product-item .product-title a:hover {
    color: #356DF1;
}

.product-item .product-excerpt {
    color: #666;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 12px;
}

.product-item .product-price {
    text-align: left;
    padding: 0;
    border: none;
    margin-bottom: 12px;
}

.product-item .product-price .price {
    font-size: 18px;
}

.product-item .product-price .old-price {
    font-size: 14px;
}

.product-button {
    margin-top: 12px;
}

.btn-view-details {
    display: inline-block;
    padding: 10px 20px;
    background: #356DF1;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
}

.btn-view-details:hover {
    background: #2563eb;
}

/* Error Section */
.error-section {
    padding: 80px 0;
    text-align: center;
}

.error-content h1 {
    font-size: 32px;
    color: #333;
    margin-bottom: 16px;
}

.error-content p {
    color: #666;
    margin-bottom: 24px;
}

.btn-back {
    display: inline-block;
    padding: 12px 24px;
    background: #356DF1;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
}

/* Responsive */
@media (max-width: 1024px) {
    .product-details-layout {
        grid-template-columns: 1fr;
    }
    
    .product-sidebar {
        order: -1;
    }
    
    .product-card {
        position: static;
    }
    
    .learn-grid {
        grid-template-columns: 1fr;
    }
    
    .reviews-layout {
        grid-template-columns: 1fr;
    }
    
    .instructor-profile {
        flex-direction: column;
        text-align: center;
    }
    
    .instructor-stats {
        justify-content: center;
    }
    
    .instructor-social {
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .product-header-section .product-title {
        font-size: 24px;
    }
    
    .header-meta {
        flex-direction: column;
        gap: 10px;
    }
    
    .product-tabs {
        flex-wrap: wrap;
    }
    
    .tab-button {
        padding: 10px 16px;
        font-size: 14px;
    }
}
