/* =====================================================
   Single Product Page - single.css
   @version 1.1.3
   ===================================================== */

/* Wrapper chính */
.single-product .site-main,
.page-single-product {
    padding: 30px 0 50px;
    background: #f5f6fa;
}

/* ---- Breadcrumb ---- */
.single-product .woocommerce-breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
    font-size: 13px;
    padding: 0 0 16px;
    color: #888;
}

.single-product .woocommerce-breadcrumb a {
    color: #555;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.single-product .woocommerce-breadcrumb a:hover {
    color: #e53935;
}

.single-product .woocommerce-breadcrumb .breadcrumb-sep {
    color: #ccc;
    font-size: 16px;
    margin: 0 2px;
}

/* ---- Khối sản phẩm chính: 2 cột flex (ảnh | thông tin) ---- */
.single-product div.product {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    background: #ffffff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.07);
    margin-bottom: 30px;
    align-items: start;
}

/* ---- Cột ảnh: 40% ---- */
.single-product div.product .woocommerce-product-gallery {
    width: 40%;
    flex-shrink: 0;
    opacity: unset !important;
}

.single-product .woocommerce-product-gallery__wrapper {
    border-radius: 8px;
    overflow: hidden;
    background: #f9f9f9;
    border: 1px solid #eee;
}

.single-product .woocommerce-product-gallery__wrapper img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
    max-height: 420px;
    padding: 20px;
    background: #fff;
}

/* Thumbnails gallery */
.single-product .flex-control-thumbs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 10px;
    padding: 0;
    list-style: none;
}

.single-product .flex-control-thumbs li {
    width: calc(25% - 6px);
}

.single-product .flex-control-thumbs img {
    border-radius: 6px;
    border: 2px solid #eee;
    cursor: pointer;
    transition: border-color 0.2s;
    width: 100%;
    object-fit: cover;
    height: 70px;
}

.single-product .flex-control-thumbs img:hover,
.single-product .flex-control-thumbs .flex-active {
    border-color: #e53935;
}

/* ---- Cột thông tin: flex:1 ---- */
.single-product div.product .summary.entry-summary {
    flex: 1;
    min-width: 0;
}

/* Tên sản phẩm */
.single-product .product_title {
    font-size: 24px;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.4;
    margin-bottom: 12px;
}

/* SKU / danh mục meta */
.single-product .product_meta {
    font-size: 13px;
    color: #888;
    margin-bottom: 16px;
    border-top: 1px solid #f0f0f0;
    padding-top: 12px;
}

.single-product .product_meta span {
    display: block;
    margin-bottom: 4px;
}

.single-product .product_meta a {
    color: #e53935;
    text-decoration: none;
}

/* Rating */
.single-product .woocommerce-product-rating {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    font-size: 13px;
}

.single-product .star-rating {
    color: #f39c12;
    font-size: 14px;
}

/* Giá */
.single-product .price {
    font-size: 28px;
    font-weight: 700;
    color: #e53935;
    margin-bottom: 16px;
    display: flex;
    align-items: baseline;
    gap: 10px;
    flex-wrap: wrap;
}

.single-product .price del {
    font-size: 18px;
    color: #aaa;
    font-weight: 400;
    text-decoration: line-through;
}

.single-product .price ins {
    text-decoration: none;
}

/* Sale badge */
.single-product .onsale {
    background: #e53935;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 20px;
    display: inline-block;
    margin-bottom: 10px;
}

/* Mô tả ngắn */
.single-product .woocommerce-product-details__short-description {
    font-size: 14px;
    color: #555;
    line-height: 1.7;
    margin-bottom: 20px;
    border-left: 3px solid #e53935;
    padding-left: 12px;
}

/* Form thêm vào giỏ */
.single-product form.cart {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

/* Nút tăng/giảm số lượng */
.single-product .quantity-wrapper {
    display: inline-flex !important;
    align-items: center !important;
    border: 1px solid #ddd !important;
    border-radius: 8px !important;
    overflow: hidden !important;
    height: 44px !important;
    gap: 0 !important;
    /* Override inline gap 5px */
}

.single-product .quantity-wrapper .qty-btn {
    width: 35px !important;
    height: 100% !important;
    background: #f9f9f9 !important;
    border: none !important;
    font-size: 18px !important;
    font-weight: 600 !important;
    color: #555 !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: background 0.2s, color 0.2s;
    padding: 0 !important;
    box-shadow: none !important;
    outline: none !important;
}

.single-product .quantity-wrapper .qty-btn:hover {
    background: #e5e5e5 !important;
    color: #e53935 !important;
}

.single-product .qty {
    width: 50px !important;
    height: 100% !important;
    border: none !important;
    border-left: 1px solid #ddd !important;
    border-right: 1px solid #ddd !important;
    border-radius: 0 !important;
    text-align: center !important;
    font-size: 16px !important;
    padding: 0 !important;
    outline: none !important;
    background: transparent !important;
    box-shadow: none !important;
}

.single-product .qty:focus {
    background: #fff !important;
}

/* Ẩn mũi tên mặc định của input number */
.single-product .qty::-webkit-outer-spin-button,
.single-product .qty::-webkit-inner-spin-button {
    -webkit-appearance: none !important;
    margin: 0 !important;
}

.single-product .qty[type=number] {
    -moz-appearance: textfield !important;
}

.single-product form.cart button[type="submit"],
.single-product form.cart .single_add_to_cart_button {
    background: #f26522;
    color: #ffffff;
    border: none;
    padding: 12px 30px;
    border-radius: 5px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.single-product form.cart button[type="submit"]:hover,
.single-product form.cart .single_add_to_cart_button:hover {
    background: #e05312;
    transform: translateY(-2px);
}

/* Nút thêm vào giỏ / bộ chọn số lượng trên trang chi tiết sản phẩm */
.single-product .summary .product-action-wrapper,
.single-product .product-action-wrapper {
    display: flex !important;
    justify-content: flex-start !important;
    align-items: center !important;
    gap: 12px;
    margin-top: 16px;
    margin-bottom: 24px;
    width: 100%;
}

.single-product .summary .product-qty-selector,
.single-product .product-action-wrapper .product-qty-selector {
    height: 42px;
    width: 140px;
    border-radius: 25px;
    padding: 0 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.single-product .summary .product-qty-selector .qty-btn,
.single-product .product-action-wrapper .product-qty-selector .qty-btn {
    width: 38px;
    height: 100%;
    font-size: 20px;
}

.single-product .summary .product-qty-selector .qty-input,
.single-product .product-action-wrapper .product-qty-selector .qty-input {
    font-size: 16px;
    font-weight: 600;
}

.single-product .summary .product-action-wrapper .btn-buy {
    background: #e53935;
    color: #ffffff;
    border: none;
    padding: 12px 30px;
    border-radius: 25px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.single-product .summary .product-action-wrapper .btn-buy:hover {
    background: #c62828;
    transform: translateY(-2px);
}

/* ---- Tabs mô tả / đánh giá (nằm bên dưới) ---- */
.single-product .woocommerce-tabs {
    width: 100%;
    background: #ffffff;
    border-radius: 10px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.07);
    padding: 0;
    margin-bottom: 30px;
    overflow: hidden;
}

.single-product .woocommerce-tabs ul.tabs {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 0;
    border-bottom: 2px solid #f0f0f0;
    background: #fafafa;
}

.single-product .woocommerce-tabs ul.tabs li {
    margin: 0;
    padding: 0;
}

.single-product .woocommerce-tabs ul.tabs li a {
    display: block;
    padding: 14px 24px;
    font-size: 14px;
    font-weight: 600;
    color: #666;
    text-decoration: none;
    border-bottom: 3px solid transparent;
    transition: color 0.2s, border-color 0.2s;
    margin-bottom: -2px;
}

.single-product .woocommerce-tabs ul.tabs li.active a,
.single-product .woocommerce-tabs ul.tabs li a:hover {
    color: #e53935;
    border-bottom-color: #e53935;
}

.single-product .woocommerce-tabs .panel {
    padding: 24px 30px;
    font-size: 14px;
    color: #444;
    line-height: 1.8;
}

/* Tiêu đề đánh giá */
.single-product .woocommerce-Reviews-title {
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 14px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e53935;
    display: inline-block;
}

/* Chưa có đánh giá */
.single-product .woocommerce-noreviews {
    font-size: 13px;
    color: #999;
    margin-bottom: 12px;
    font-style: italic;
}

/* Form đánh giá sản phẩm */
.single-product #review_form_wrapper {
    margin-top: 8px;
}

.single-product #respond .comment-reply-title {
    font-size: 14px;
    font-weight: 700;
    color: #374151;
    margin-bottom: 12px;
    display: block;
}

.single-product #respond .comment-form-rating {
    margin-bottom: 12px;
}

.single-product #respond .comment-form-rating label {
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    display: block;
    margin-bottom: 6px;
}

.single-product #respond .comment-form-rating select {
    padding: 8px 12px;
    border: 1.5px solid #e5e7eb;
    border-radius: 8px;
    font-size: 13px;
    outline: none;
    background: #fff;
    cursor: pointer;
    color: #374151;
    width: 200px;
}

.single-product #respond .comment-form-rating select:focus {
    border-color: #e53935;
}

.single-product #respond .comment-form-comment label,
.single-product #respond .comment-form-author label,
.single-product #respond .comment-form-email label {
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    display: block;
    margin-bottom: 6px;
}

.single-product #respond textarea,
.single-product #respond input[type="text"],
.single-product #respond input[type="email"] {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid #e5e7eb;
    border-radius: 8px;
    font-size: 13px;
    color: #374151;
    background: #fff;
    outline: none;
    transition: border-color 0.2s;
    font-family: inherit;
    box-sizing: border-box;
    margin-bottom: 12px;
    resize: vertical;
}

.single-product #respond textarea {
    min-height: 100px;
}

.single-product #respond textarea:focus,
.single-product #respond input:focus {
    border-color: #e53935;
}

/* 3 cột Tên/Email/Website */
.single-product #respond .comment-form-author,
.single-product #respond .comment-form-email,
.single-product #respond .comment-form-url {
    display: inline-block;
    width: 32%;
    margin-right: 1.5%;
    vertical-align: top;
}

.single-product #respond .comment-form-url {
    margin-right: 0;
}

.single-product #respond #submit {
    background: #e53935;
    color: #fff;
    border: none;
    padding: 10px 32px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.single-product #respond #submit:hover {
    background: #c62828;
}

.single-product #respond .comment-notes {
    font-size: 12px;
    color: #999;
    margin-bottom: 14px;
}

/* =====================================================
   Sản Phẩm Tương Tự (Related Products) Swiper Slider
   @since 1.0.18
   ===================================================== */
.single-product .related-products-slider-section,
.single-product .related.products {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    margin-top: 35px;
    margin-bottom: 40px;
    background: #ffffff;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 2px 14px rgba(0, 0, 0, 0.05);
}

.related-slider-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid #f1f5f9;
}

.related-slider-header .related-title,
.single-product .related.products>h2 {
    font-size: 20px;
    font-weight: 700;
    color: #1e293b;
    margin: 0;
    padding-bottom: 8px;
    position: relative;
    border-bottom: none;
    display: inline-block;
}

.related-slider-header .related-title::after,
.single-product .related.products>h2::after {
    content: '';
    position: absolute;
    bottom: -14px;
    left: 0;
    width: 65px;
    height: 3px;
    background: #e53935;
    border-radius: 2px;
}

.related-slider-nav {
    display: flex;
    align-items: center;
    gap: 8px;
}

.related-slider-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    color: #475569;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.related-slider-btn:hover {
    background: #e53935;
    border-color: #e53935;
    color: #ffffff;
    box-shadow: 0 4px 10px rgba(229, 57, 53, 0.25);
    transform: translateY(-1px);
}

.related-products-slider {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    padding: 6px 2px 14px;
}

.related-products-slider .swiper-wrapper {
    align-items: stretch;
}

.related-products-slider .swiper-slide {
    height: auto;
    display: flex;
    box-sizing: border-box;
}

/* Card sản phẩm trong slider - Fix triệt để lỗi đè nút mua */
.related-products-slider .swiper-slide .product-card {
    width: 100%;
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border: 1px solid #edf2f7;
    border-radius: 12px;
    overflow: hidden;
    padding: 12px 12px 14px;
    box-sizing: border-box;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
    transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.3s cubic-bezier(0.25, 0.8, 0.25, 1), border-color 0.3s ease;
}

.related-products-slider .swiper-slide .product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
    border-color: #cbd5e1;
}

.related-products-slider .swiper-slide .product-image {
    width: 100%;
    height: 170px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin-bottom: 12px;
    background: #fbfcfd;
    border-radius: 8px;
}

.related-products-slider .swiper-slide .product-image a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

.related-products-slider .swiper-slide .product-image img {
    max-height: 155px;
    max-width: 100%;
    object-fit: contain;
    transition: transform 0.4s ease;
}

.related-products-slider .swiper-slide .product-card:hover .product-image img {
    transform: scale(1.06);
}

.related-products-slider .swiper-slide .product-info {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 0;
}

.related-products-slider .swiper-slide .product-title {
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
    color: #1e293b;
    height: 40px;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.related-products-slider .swiper-slide .product-title a {
    color: #1e293b;
    text-decoration: none;
    transition: color 0.2s;
}

.related-products-slider .swiper-slide .product-title a:hover {
    color: #e53935;
}

.related-products-slider .swiper-slide .product-price {
    font-size: 16px;
    font-weight: 700;
    color: #e53935;
    margin-bottom: 12px;
}

.related-products-slider .swiper-slide .product-action {
    margin-top: auto;
    width: 100%;
    padding-top: 4px;
}

.related-products-slider .swiper-slide .product-action .btn-buy,
.related-products-slider .swiper-slide .product-action .button {
    background: var(--primary-gradient, linear-gradient(135deg, #FF7600 0%, #F26522 100%));
    color: #ffffff;
    padding: 9px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    text-transform: uppercase;
    transition: all 0.25s ease;
    border: none;
    box-shadow: 0 2px 6px rgba(255, 118, 0, 0.25);
}

.related-products-slider .swiper-slide .product-action .btn-buy:hover,
.related-products-slider .swiper-slide .product-action .button:hover {
    background: linear-gradient(135deg, #F26522 0%, #e05312 100%);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(255, 118, 0, 0.35);
    transform: translateY(-1px);
}

.related-products-slider .swiper-slide .product-action .product-qty-selector {
    width: 100%;
    max-width: 120px;
    margin: 0 auto;
    height: 36px;
    border-radius: 20px;
}

/* =====================================================
   Single Post (Bài Viết) Styles
   @version 1.1.0
   ===================================================== */

/* Wrapper trang bài viết */
.single-post-page {
    padding: 40px 0 60px;
    background: #f5f6fa;
}

/* ---- Card bài viết ---- */
.single-post-content {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.07);
    overflow: hidden;
    margin-bottom: 30px;
}

/* Header bài viết */
.single-post-content .entry-header {
    padding: 32px 40px 20px;
    border-bottom: 1px solid #f0f0f0;
}

.single-post-content .entry-title {
    font-size: 28px;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.45;
    margin-bottom: 16px;
}

/* Meta (ngày, tác giả, danh mục) */
.single-post-content .entry-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 13px;
    color: #888;
}

.single-post-content .entry-meta span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.single-post-content .entry-meta i {
    color: #e53935;
    font-size: 12px;
}

.single-post-content .entry-meta a {
    color: #555;
    text-decoration: none;
    transition: color 0.2s;
}

.single-post-content .entry-meta a:hover {
    color: #e53935;
}

/* Ảnh đại diện */
.single-post-content .post-thumbnail {
    width: 100%;
    max-height: 460px;
    overflow: hidden;
}

.single-post-content .post-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Nội dung bài viết */
.single-post-content .entry-content {
    padding: 32px 40px;
    font-size: 16px;
    line-height: 1.85;
    color: #374151;
}

.single-post-content .entry-content h2,
.single-post-content .entry-content h3,
.single-post-content .entry-content h4 {
    font-weight: 700;
    color: #1e293b;
    margin: 28px 0 14px;
}

.single-post-content .entry-content h2 {
    font-size: 22px;
}

.single-post-content .entry-content h3 {
    font-size: 19px;
}

.single-post-content .entry-content h4 {
    font-size: 16px;
}

.single-post-content .entry-content p {
    margin-bottom: 18px;
}

.single-post-content .entry-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 10px 0;
}

.single-post-content .entry-content a {
    color: #e53935;
    text-decoration: underline;
}

.single-post-content .entry-content blockquote {
    border-left: 4px solid #e53935;
    background: #fff8f8;
    padding: 16px 20px;
    margin: 20px 0;
    border-radius: 0 8px 8px 0;
    font-style: italic;
    color: #555;
}

.single-post-content .entry-content ul,
.single-post-content .entry-content ol {
    padding-left: 24px;
    margin-bottom: 18px;
}

.single-post-content .entry-content li {
    margin-bottom: 6px;
}

/* Footer bài viết (tags) */
.single-post-content .entry-footer {
    padding: 16px 40px 24px;
    border-top: 1px solid #f0f0f0;
    font-size: 13px;
    color: #888;
}

.single-post-content .entry-footer .tags-links a {
    color: #e53935;
    text-decoration: none;
}

/* =====================================================
   Comment Section - Khung bình luận
   ===================================================== */

/* Wrapper bình luận & Form (Cho bài viết tĩnh) */
#comments,
#respond {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.07);
    padding: 32px 40px;
    margin-bottom: 30px;
}

/* Loại bỏ nền thừa trong sản phẩm WooCommerce (Vì thẻ cha đã có nền) */
.single-product #comments,
.single-product #respond {
    background: transparent;
    border-radius: 0;
    box-shadow: none;
    padding: 0;
    margin-bottom: 20px;
}

/* Tiêu đề bình luận */
#comments .comments-title,
#respond .comment-reply-title {
    font-size: 20px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 24px;
    padding-bottom: 12px;
    border-bottom: 2px solid #f0f0f0;
    display: block;
}

/* Danh sách bình luận */
.comment-list {
    list-style: none;
    padding: 0;
    margin: 0 0 30px;
}

.comment-list .comment {
    padding: 20px 0;
    border-bottom: 1px solid #f5f5f5;
}

.comment-list .comment:last-child {
    border-bottom: none;
}

/* Avatar */
.comment-list .comment-author img {
    border-radius: 50%;
    width: 48px;
    height: 48px;
    float: left;
    margin-right: 14px;
}

.comment-list .comment-meta {
    font-size: 13px;
    color: #999;
    margin-bottom: 8px;
}

.comment-list .comment-author .fn {
    font-weight: 600;
    color: #333;
    font-size: 15px;
    font-style: normal;
}

.comment-list .comment-body p {
    margin-left: 62px;
    font-size: 14px;
    color: #555;
    line-height: 1.7;
}

/* Reply link */
.comment-list .reply a {
    margin-left: 62px;
    font-size: 12px;
    color: #e53935;
    text-decoration: none;
    font-weight: 500;
}

/* ---- Form bình luận mới ---- */
#respond {
    margin-top: 10px;
}

#respond .comment-reply-title {
    font-size: 18px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 8px;
}

/* Chú thích bắt buộc */
#respond .comment-notes {
    font-size: 13px;
    color: #888;
    margin-bottom: 20px;
}

/* =====================================================
   Review / Đánh giá sản phẩm (WooCommerce Stars)
   ===================================================== */
#respond .comment-form-rating {
    margin-bottom: 20px;
}

/* Ẩn label thừa (vì có 2 label "Đánh giá của bạn") */
#respond .comment-form-rating label[for="rating"] {
    display: none;
}

#respond p.stars {
    margin-top: 10px;
    margin-bottom: 10px;
}

#respond p.stars span {
    display: flex;
    flex-direction: row;
    gap: 4px;
}

#respond p.stars a {
    text-indent: -9999px;
    /* Ẩn text "1 trên 5 sao" */
    width: 24px;
    height: 24px;
    display: inline-block;
    position: relative;
    text-decoration: none !important;
    outline: none;
}

/* Mặc định: Ngôi sao rỗng */
#respond p.stars a::before {
    content: "\f005";
    font-family: "Font Awesome 5 Free";
    font-weight: 400;
    /* 400 là sao viền rỗng (regular) */
    font-size: 20px;
    color: #f39c12;
    /* Màu vàng cam */
    position: absolute;
    top: 0;
    left: 0;
    text-indent: 0;
    line-height: 24px;
    transition: color 0.2s, transform 0.2s;
}

/* 1. Trạng thái đã chọn (Selected): Tô màu TẤT CẢ, sau đó bỏ tô những sao SAU sao được chọn */
#respond p.stars.selected a::before {
    font-weight: 900;
    /* 900 là sao tô kín (solid) */
}

#respond p.stars.selected a.active~a::before {
    font-weight: 400;
}

/* 2. Trạng thái Hover: Hover vào thì tô màu TẤT CẢ, sau đó bỏ tô những sao SAU sao đang hover */
#respond p.stars:hover a::before {
    font-weight: 900 !important;
}

#respond p.stars a:hover~a::before {
    font-weight: 400 !important;
}

#respond p.stars a:hover::before {
    transform: scale(1.15);
}

/* Các field form */
#respond .comment-form-comment label,
#respond .comment-form-author label,
#respond .comment-form-email label,
#respond .comment-form-url label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 6px;
}

#respond textarea,
#respond input[type="text"],
#respond input[type="email"],
#respond input[type="url"] {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
    color: #374151;
    background: #fafafa;
    outline: none;
    transition: border-color 0.2s, background 0.2s;
    font-family: inherit;
    box-sizing: border-box;
    margin-bottom: 16px;
}

#respond textarea {
    min-height: 140px;
    resize: vertical;
}

#respond textarea:focus,
#respond input:focus {
    border-color: #e53935;
    background: #fff;
}

/* Row 3 cột cho name/email/url */
#respond .comment-form-author,
#respond .comment-form-email,
#respond .comment-form-url {
    display: inline-block;
    width: 32%;
    margin-right: 1.5%;
    vertical-align: top;
}

#respond .comment-form-url {
    margin-right: 0;
}

/* Nút gửi bình luận */
#respond #submit {
    background: #e53935;
    color: #ffffff;
    border: none;
    padding: 12px 32px;
    border-radius: 25px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    letter-spacing: 0.3px;
}

#respond #submit:hover {
    background: #c62828;
    transform: translateY(-2px);
}

/* Checkbox chấp thuận */
#respond .comment-form-cookies-consent label {
    font-size: 13px;
    color: #888;
    display: inline;
    font-weight: 400;
}

/* Responsive bài viết */
@media (max-width: 768px) {

    .single-post-content .entry-header,
    .single-post-content .entry-content,
    .single-post-content .entry-footer,
    #comments,
    #respond {
        padding: 20px;
    }

    .single-post-content .entry-title {
        font-size: 22px;
    }

    #respond .comment-form-author,
    #respond .comment-form-email,
    #respond .comment-form-url {
        width: 100%;
        margin-right: 0;
        display: block;
    }
}

/* Nút liên hệ báo giá sản phẩm 0đ */
.product-contact-wrapper {
    margin: 20px 0;
}

.product-contact-wrapper .btn-contact-price {
    background: #e53935;
    color: #ffffff;
    border: none;
    padding: 12px 28px;
    border-radius: 25px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.product-contact-wrapper .btn-contact-price:hover {
    background: #c62828;
    transform: translateY(-2px);
    color: #ffffff;
}

/* Bảng giá theo bậc trên trang chi tiết sản phẩm */
.single-product table.b2bking_tiered_price_table {
    width: 100%;
    max-width: 100%;
    margin: 24px 0 20px;
    border-collapse: collapse;
    table-layout: fixed;
    overflow: hidden;
    border: 1px solid #dce6ef;
    border-radius: 8px;
    background: #ffffff;
}

.single-product table.b2bking_tiered_price_table th,
.single-product table.b2bking_tiered_price_table td {
    width: 33.333%;
    padding: 10px 12px;
    border: 1px solid #dce6ef;
    vertical-align: middle;
    text-align: left;
    line-height: 1.4;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: normal;
    box-sizing: border-box;
}

.single-product table.b2bking_tiered_price_table th {
    background: #f2f7fb;
    color: #1e293b;
    font-size: 14px;
    font-weight: 700;
}

.single-product table.b2bking_tiered_price_table td {
    color: #334155;
    font-size: 14px;
}

.single-product table.b2bking_tiered_price_table tbody tr:nth-child(even) td {
    background: #fbfdff;
}

.single-product table.b2bking_tiered_price_table tbody tr:hover td {
    background: #f0f9ff;
}

.single-product table.b2bking_tiered_price_table tbody td.b2bking_has_color {
    background: #3aaed8;
    color: #ffffff !important;
}

@media (max-width: 600px) {

    .single-product table.b2bking_tiered_price_table th,
    .single-product table.b2bking_tiered_price_table td {
        padding: 8px 7px;
        font-size: 12px;
    }
}

/* Báo cáo sản phẩm */
.single-product .marketking_report_abuse_container {
    margin-top: 24px;
    padding: 20px;
    border: 1px solid #e8edf3;
    border-radius: 12px;
    background: #fff;
    color: #26364a;
}

.single-product .marketking_report_abuse_container>br,
.single-product .marketking_report_abuse_hidden>br,
.single-product .marketking_report_abuse_flagtext .dashicons-flag {
    display: none;
}

.single-product .marketking_report_abuse_flagtext {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
}

.single-product .marketking_report_abuse_flagtext .marketking_report_abuse_text {
    color: var(--primary-color);
    font-size: 14px;
    font-weight: 700;
    transition: color .2s ease;
}

.single-product .marketking_report_abuse_flagtext:hover .marketking_report_abuse_text {
    color: #c65b00;
}

.single-product .marketking_report_abuse_hidden {
    margin-top: 16px;
}

.single-product textarea.marketking_report_abuse_message {
    display: block;
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    min-height: 120px;
    margin: 0 0 14px;
    padding: 12px 14px;
    border: 1px solid #d9e0e8;
    border-radius: 8px;
    background: #fff;
    color: #26364a;
    font: inherit;
    line-height: 1.5;
    resize: vertical;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.single-product textarea.marketking_report_abuse_message:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(255, 118, 0, .14);
}

.single-product .marketking_send_report_abuse {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 10px 20px;
    border: 1px solid var(--primary-color);
    border-radius: 6px;
    background: var(--primary-color);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color .2s ease, border-color .2s ease;
}

.single-product .marketking_send_report_abuse:hover,
.single-product .marketking_send_report_abuse:focus-visible {
    border-color: #e66a00;
    background: #e66a00;
    color: #fff;
}