/* --- CSS Cho Dropdown Thuộc tính --- */
.product-option-group {
    padding: 1rem 0;
    border-bottom: 1px solid #e5e7eb;
}

.option-label {
    display: block;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.custom-select-wrapper {
    position: relative;
    display: inline-block;
    width: 100%;
    /* Hoặc một độ rộng cố định nếu bạn muốn */
    max-width: 300px;
}

.product-option-select {
    display: block;
    width: 100%;
    padding: 10px 35px 10px 15px;
    font-size: 1rem;
    line-height: 1.5;
    color: #495057;
    background-color: #fff;
    border: 1px solid #ced4da;
    border-radius: 4px;
    appearance: none;
    /* Ẩn mũi tên mặc định của trình duyệt */
    -webkit-appearance: none;
    -moz-appearance: none;
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.product-option-select:focus {
    border-color: #80bdff;
    outline: 0;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

/* Mũi tên tùy chỉnh */
.select-arrow {
    position: absolute;
    top: 50%;
    right: 12px;
    transform: translateY(-50%);
    color: #6c757d;
    pointer-events: none;
    /* Đảm bảo bạn vẫn có thể click vào select */
    font-size: 0.8rem;
}


/* --- CSS Cho Chia sẻ (Tối ưu hóa từ ký tự sang Font Awesome) --- */
.share-label {
    font-weight: 600;
    color: #333;
    margin-right: 15px;
}

.social-icons {
    display: flex;
    gap: 10px;
    padding-top: 5px;
    align-items: center;
}

.social-link {
    font-size: 1.2rem;
    color: #555;
    transition: color 0.2s;
}

.social-link.facebook:hover {
    color: #3b5998;
}

.social-link.twitter:hover {
    color: #1da1f2;
}

.social-link.pinterest:hover {
    color: #bd081c;
}

.social-link.email:hover {
    color: #dc3545;
}






/*LAYOUT PRODUCT DETAIL*/
/* --- Global Reset & Container --- */
.product-detail-section {
    padding: 3rem 0;
    /* Optional: Remove border-bottom if not needed, as per the original code */
}

.product-detail-layout {
    /* Đảm bảo khoảng cách giữa các cột được kiểm soát tốt */
    --bs-gutter-x: 30px;
    margin-left: calc(-1 * var(--bs-gutter-x) / 2);
    margin-right: calc(-1 * var(--bs-gutter-x) / 2);
    display: flex;
    flex-wrap: wrap;
}

/* --- Product Gallery Column --- */
.product-gallery-col {
    margin-bottom: 2rem;
    /* learts-mb-40 equivalent */
}

.product-images-wrap {
    position: relative;
    /* Tối ưu hóa không gian cho gallery chính và thumbnail */
}

.product-gallery-popup {
    position: absolute;
    top: 15px;
    right: 15px;
    z-index: 5;
    background-color: rgba(255, 255, 255, 0.8);
    border: 1px solid #ccc;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 16px;
    color: #333;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
}

.product-gallery-popup:hover {
    background-color: #333;
    color: #fff;
}

/* Các lớp cho Slider ảnh chính và Thumbnail (giả định dùng thư viện như Slick/Owl Carousel) */
/* Cần đảm bảo thư viện slider được khởi tạo trên các lớp .product-gallery-slider và .product-thumb-slider */

/* --- Product Summery Column --- */
.product-summery-col {
    margin-bottom: 2rem;
    /* learts-mb-40 equivalent */
    padding-left: 15px;
    /* Thêm khoảng đệm cho cột tóm tắt */
}

.product-title {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #222;
}

.product-price {
    font-size: 1.8rem;
    font-weight: bold;
    color: #e67e22;
    /* Màu cam nổi bật cho giá */
    margin-bottom: 1.5rem;
}

/* Product Navigation */
.product-nav {
    display: flex;
    justify-content: flex-end;
    /* Căn phải hoặc căn đều tùy ý */
    gap: 10px;
    margin-bottom: 1rem;
}

.nav-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 35px;
    height: 35px;
    border: 1px solid #ccc;
    border-radius: 50%;
    color: #333;
    transition: all 0.2s;
    text-decoration: none;
}

.nav-arrow:hover {
    background-color: #333;
    color: #fff;
    border-color: #333;
}

.nav-arrow.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    color: #999;
}

/* Product Ratings */
.product-ratings {
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.review-link {
    color: #007bff;
    text-decoration: none;
    font-size: 0.9rem;
}

/* --- Description & View More --- */
.product-summery-meta-box {
    background-color: #fff;
    padding: 15px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    font-family: 'AIAEverest-Regular', sans-serif;
    line-height: 1.6;
    color: #333;
    margin-bottom: 1.5rem;
}

.short-description-content {
    max-height: 400px;
    overflow: hidden;
    position: relative;
}

.fade-overlay-style {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 50px;
    /* Sử dụng màu nền của container để tạo hiệu ứng mờ dần */
    background: linear-gradient(transparent, #fff);
}

.view-more-container {
    text-align: right;
    margin-top: 5px;
    padding-top: 5px;
    /* Thêm chút khoảng đệm */
}

.view-more-btn {
    background: none;
    border: none;
    color: #007bff;
    cursor: pointer;
    font-weight: bold;
    padding: 5px 0;
    transition: color 0.2s;
}

.view-more-btn:hover {
    color: #0056b3;
}

/* --- Quantity & Action Buttons --- */
.action-block-container {
    padding: 1.5rem;
}

.quantity-control-wrap {
    margin-bottom: 1.5rem;
}

.qty-label {
    display: block;
    width: 100%;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
}

.qty-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.qty-btn {
    background-color: #f5f5f5;
    padding: 0.5rem 1rem;
    border: 1px solid #ccc;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s;
}

.qty-btn:hover {
    background-color: #e0e0e0;
}

.qty-input {
    width: 4rem;
    text-align: center;
    border: 1px solid #ccc;
    border-radius: 0.375rem;
    padding: 0.5rem 0.25rem;
    outline: none;
}

.product-actions-form {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    align-items: stretch;
    /* Đảm bảo các nút có cùng chiều cao */
}

.action-btn {
    background-color: #f5f5f5;
    border: 1px solid #333;
    padding: 0.75rem;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s;
}

.wishlist-btn,
.compare-btn {
    width: 50px;
    /* Kích thước cố định cho nút tròn */
    height: 50px;
}

.add-to-cart-btn {
    flex: 1;
    /* Chiếm hết không gian còn lại */
    background-color: #333;
    color: #fff;
    padding: 0.75rem 1rem;
    border-radius: 0.375rem;
    border: 1px solid #333;
    font-weight: 600;
}

.add-to-cart-btn:hover {
    background-color: #555;
}

.cart-icon {
    margin-right: 0.5rem;
}

/* --- Options and Share --- */
.product-options-meta-group {
    padding-top: 1rem;
    border-top: 1px solid #e5e7eb;
    margin-top: 1rem;
}

.product-option-group {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
}

.option-label {
    font-weight: 600;
    color: #333;
    width: 100px;
    /* Cố định chiều rộng nhãn */
    flex-shrink: 0;
}

.custom-select-wrapper {
    position: relative;
    flex-grow: 1;
}

.product-option-select {
    width: 100%;
    padding: 0.5rem 2rem 0.5rem 0.75rem;
    border: 1px solid #ccc;
    border-radius: 0.375rem;
    appearance: none;
    /* Ẩn mũi tên mặc định của trình duyệt */
    -webkit-appearance: none;
    background-color: #fff;
    cursor: pointer;
}

.select-arrow {
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    color: #333;
    pointer-events: none;
    /* Đảm bảo click vào select box */
}

.share-group {
    display: flex;
    align-items: center;
    gap: 15px;
}

.social-icons {
    display: flex;
    gap: 8px;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: #f5f5f5;
    color: #333;
    transition: background-color 0.2s, color 0.2s;
}

.social-link:hover {
    background-color: #333;
    color: #fff;
}

/* === Cải thiện bố cục tab ở mobile === */
@media (max-width: 767px) {

    /* Tab list chuyển sang dạng cuộn ngang nếu dài */
    .product-info-tab-list {
        display: flex;
        overflow-x: auto;
        white-space: nowrap;
        border-bottom: 1px solid #ddd;
        padding-bottom: 6px;
        margin-bottom: 15px;
        gap: 12px;
        -webkit-overflow-scrolling: touch;
    }

    .product-info-tab-list li {
        flex: 0 0 auto;
        list-style: none;
    }

    .product-info-tab-list a {
        display: inline-block;
        padding: 8px 16px;
        font-size: 14px;
        border-radius: 20px;
        border: 1px solid #ddd;
        background-color: #f8f8f8;
        color: #333;
    }

    .product-info-tab-list a.active {
        background-color: #523f31 !important;
        color: #fff;
        border-color: #523f31 !important;
    }

    /* Nội dung tab: thêm padding và căn chữ dễ đọc */
    .product-infor-tab-content {
        padding: 10px 5px 20px 5px;
        font-size: 15px;
        line-height: 1.6;
    }

    /* Mô tả ngắn */
    .short-description-content {
        font-size: 15px;
        line-height: 1.7;
        margin-bottom: 12px;
    }

    /* Nút Xem thêm */
    .view-more-btn {
        display: block;
        width: 100%;
        text-align: center;
        padding: 10px;
        border-radius: 6px;
        background-color: #f0f0f0;
        font-weight: 500;
        transition: background-color 0.2s;
    }

    .view-more-btn:hover {
        background-color: #ddd;
    }

    /* Hình trong tab Brand co theo chiều ngang */
    .tab-pane img {
        max-width: 100%;
        height: auto;
    }

    /* Reviews dễ đọc hơn */
    .product-review-wrapper .content p {
        font-size: 14px;
        line-height: 1.6;
    }
}

/* Banner mặc định (desktop) */
.page-title-section {
    background-repeat: no-repeat;
    background-position: calc(100% - 280px) calc(100% - 60px);
    background-size: 300px auto;
    background-color: #f8f7f7;
    padding: 80px 0;
}

/* Căn giữa chữ trong banner */
.page-title {
    text-align: left;
}

.page-title .title {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 10px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    font-size: 14px;
    justify-content: left;
}

/* === Responsive (mobile) === */
@media (max-width: 768px) {

    .page-title-section {
        background-position: center bottom;
        /* căn giữa ảnh */
        background-size: 180px auto;
        /* ảnh nhỏ hơn */
        padding: 60px 0 100px 0;
        /* thêm không gian dưới để ảnh không đè text */
        text-align: center;
        /* chữ giữa */
    }

    .page-title {
        text-align: center;
    }

    .page-title .title {
        font-size: 28px;
        /* nhỏ hơn cho mobile */
        margin-bottom: 8px;
    }

    .breadcrumb {
        justify-content: center;
        font-size: 13px;
    }
}

.add-to-cart-btn {
    display: inline-flex;
    /* icon và text cùng hàng */
    align-items: center;
    /* căn giữa dọc */
    justify-content: center;
    gap: 6px;
    /* khoảng cách icon và chữ */
    font-size: 15px;
    padding: 10px 18px;
    border-radius: 6px;
    background-color: #b46a32;
    color: #fff;
    font-weight: 500;
    border: none;
    transition: background-color 0.2s ease;
}

.add-to-cart-btn:hover {
    background-color: #a15e2c;
}

/* === Responsive: thu nhỏ cho mobile === */
@media (max-width: 768px) {
    .add-to-cart-btn {
        width: 100%;
        /* full width để dễ bấm */
        font-size: 13.5px;
        /* nhỏ hơn chút */
        padding: 8px 14px;
        border-radius: 5px;
        gap: 5px;
    }

    .add-to-cart-btn i {
        font-size: 14px;
        /* icon nhỏ hơn */
    }
}

/* === KHU VỰC BIẾN THỂ + GIỎ HÀNG === */
.action-block-container {
    padding: 20px 0;
    /* dãn đều trên và dưới */
}

.action-block-container .product-summery-meta-box {
    margin-bottom: 25px;
}

/* Tiêu đề trong từng mục */
.action-block-container h5,
.action-block-container h6 {
    margin-bottom: 10px;
}

/* Nút chọn vật liệu, hoàn thiện, kích thước */
.action-block-container .btn {
    padding: 8px 14px;
    border-radius: 6px;
}

/* Ô số lượng */
.quantity-control-wrap {
    margin-top: 15px;
    margin-bottom: 25px;
    padding: 10px 0;
}

/* Hàng con trong cart-buttons */
.cart-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Hàng nút giỏ hàng */
.cart-buttons {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    margin-bottom: 20px;
}

/* Các nút tròn */
.cart-buttons .circle-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #f3f3f3;
    color: #555;
    font-size: 16px;
    border: 1px solid #ddd;
    transition: all 0.2s ease;
}

.cart-buttons .circle-btn:hover {
    background: #b46a32;
    color: #fff;
}

/* Nút Thêm giỏ hàng */
.add-to-cart-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-size: 15px;
    padding: 10px 18px;
    border-radius: 6px;
    background-color: #b46a32;
    color: #fff;
    border: none;
    transition: background-color 0.2s;
}

.add-to-cart-btn:hover {
    background-color: #a25e2d;
}

/* === Responsive mobile === */
@media (max-width: 768px) {
    .action-block-container {
        padding: 15px 5px;
    }

    .add-to-cart-btn {
        width: 100%;
        font-size: 13.5px;
        padding: 9px 14px;
    }

    .cart-buttons {
        flex-wrap: wrap;
        gap: 10px;
    }

    .cart-buttons .circle-btn {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }
}



/* ==== Giá sản phẩm dạng nút ==== */
#priceButton {
    cursor: default !important;
    font-size: 1.05rem;
    border: none;
    background-color: #ffc107 !important;
    /* vàng sáng nổi bật */
    color: #212529 !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
    transition: all 0.25s ease;
}

#priceButton:hover {
    background-color: #ffca2c !important;
    transform: translateY(-1px);
}

#priceButton:disabled {
    opacity: 1;
}

/* Bọc tổng → để label và cụm nút nằm cùng hàng */
.quantity-control-wrap {
    display: flex;
    align-items: center;
    /* ✅ Canh giữa theo chiều dọc */
    gap: 12px;
    /* ✅ Khoảng cách giữa chữ và nút */
    max-width: 225px;
    /* Tùy chỉnh chiều rộng tổng thể */
    margin: 0;
    text-align: left;
    margin-left: 20px;
    margin-bottom: 12px;
}

/* Nhóm nút + input */
.qty-controls {
    display: flex;
    align-items: center;
    /* ✅ Canh giữa nút và ô nhập */
    gap: 6px;
}

/* Nút + và - */
.qty-btn {
    width: 10px;
    height: 30px;
    border-radius: 50%;
    font-size: 18px;
    line-height: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    /* ✅ Icon nằm giữa tròn nút */
}

/* Ô số lượng */
.qty-input {
    width: 60px;
    text-align: right;
    margin-right: 2px;
}

/* Mobile (≤ 768px) => center */
@media (max-width: 768px) {
    .qty-input {
        text-align: center;
    }
}



.cart-buttons {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    max-width: 360px;
    margin-left: 20px;
}

/* ==== Hàng chứa nút ==== */
.cart-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    width: 100%;
}

/* ==== Nút tròn 2 bên ==== */
.circle-btn {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 1px solid #ccc;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.3s;
}

.circle-btn:hover {
    border-color: #000;
    color: #000;
}

/* ==== Mua ngay ==== */
.buy-now-btn {
    flex: 0.63;
    border-radius: 75px !important;
    padding: 12px 25px;
    font-size: 16px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    transition: all 0.3s;
}

.buy-now-btn:hover {
    transform: translateY(-1px);
    opacity: 0.9;
}

/* ==== Thêm giỏ hàng ==== */
.add-to-cart-btn {
    width: 100%;
    background: #000;
    color: #fff;
    border: none;
    border-radius: 75px !important;
    padding: 14px 25px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s;
}

.add-to-cart-btn:hover {
    background: #222;
    transform: translateY(-1px);
}

/* ==== Mobile: Stack gọn lại ==== */
@media (max-width: 767px) {
    .cart-buttons {
        max-width: 100%;
        margin-left: 0;
    }

    .cart-row {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 8px;
    }

    .add-to-cart-btn {
        flex: 1;
        border-radius: 0 !important;
    }

    .circle-btn {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }

}