/* ============================================
   Product Detail Page CSS
   Cangzhou Xinghui Pipeline Equipment Co., Ltd.
   ============================================ */

/* Breadcrumb Navigation */
.xinghui-breadcrumb {
    background: #f8f9fa;
    padding: 15px 0;
    border-bottom: 1px solid #e8ecef;
}

.xinghui-breadcrumb-list {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.xinghui-breadcrumb-list li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: #666;
}

.xinghui-breadcrumb-list li a {
    color: #1e3c72;
    transition: color 0.3s ease;
}

.xinghui-breadcrumb-list li a:hover {
    color: #2a5298;
    text-decoration: underline;
}

.xinghui-breadcrumb-list li i {
    font-size: 12px;
    color: #999;
}

.xinghui-breadcrumb-list li:last-child {
    color: #333;
    font-weight: 500;
}

/* Product Detail Section */
.xinghui-product-detail {
    padding: 40px 0 60px;
    background: #fff;
}

/* Product Main Layout */
.xinghui-product-main {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    margin-bottom: 60px;
}

/* Product Gallery */
.xinghui-product-gallery {
    position: sticky;
    top: 100px;
}

.xinghui-gallery-main {
    position: relative;
    border: 1px solid #e8ecef;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    margin-bottom: 15px;
}

.xinghui-gallery-main-image {
    width: 100%;
    height: 450px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: zoom-in;
    position: relative;
    overflow: hidden;
}

.xinghui-gallery-main-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.xinghui-gallery-main-image:hover img {
    transform: scale(1.05);
}

.xinghui-gallery-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: #fff;
    padding: 6px 15px;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 600;
    z-index: 2;
}

.xinghui-gallery-zoom-hint {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.xinghui-gallery-main-image:hover .xinghui-gallery-zoom-hint {
    opacity: 1;
}

.xinghui-gallery-thumbs {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 10px;
}

.xinghui-gallery-thumb {
    border: 2px solid #e8ecef;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    height: 80px;
    background: #fff;
}

.xinghui-gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.xinghui-gallery-thumb:hover {
    border-color: #2a5298;
}

.xinghui-gallery-thumb:hover img {
    transform: scale(1.05);
}

.xinghui-gallery-thumb.xinghui-active {
    border-color: #1e3c72;
    box-shadow: 0 0 10px rgba(30, 60, 114, 0.3);
}

/* Product Info */
.xinghui-product-info {
    display: flex;
    flex-direction: column;
}

.xinghui-product-category {
    font-size: 14px;
    color: #2a5298;
    font-weight: 500;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.xinghui-product-title {
    font-size: 28px;
    color: #1e3c72;
    font-weight: 700;
    margin-bottom: 15px;
    line-height: 1.4;
}

.xinghui-product-subtitle {
    font-size: 16px;
    color: #666;
    margin-bottom: 25px;
    line-height: 1.6;
}

.xinghui-product-meta {
    background: linear-gradient(135deg, #f8f9fa 0%, #e8ecf1 100%);
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 30px;
}

.xinghui-product-price-wrapper {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e0e0e0;
}

.xinghui-product-price-label {
    font-size: 14px;
    color: #666;
    margin-bottom: 8px;
}

.xinghui-product-price {
    display: flex;
    align-items: baseline;
    gap: 10px;
}

.xinghui-product-price-current {
    font-size: 36px;
    font-weight: 700;
    color: #e74c3c;
}

.xinghui-product-price-currency {
    font-size: 18px;
    color: #e74c3c;
}

.xinghui-product-price-unit {
    font-size: 14px;
    color: #999;
    margin-left: 5px;
}

.xinghui-product-price-old {
    font-size: 18px;
    color: #999;
    text-decoration: line-through;
    margin-left: 10px;
}

.xinghui-product-specs {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.xinghui-product-spec {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.xinghui-product-spec-label {
    font-size: 13px;
    color: #999;
}

.xinghui-product-spec-value {
    font-size: 15px;
    color: #333;
    font-weight: 500;
}

/* Product Options */
.xinghui-product-options {
    margin-bottom: 30px;
}

.xinghui-product-option-group {
    margin-bottom: 25px;
}

.xinghui-product-option-label {
    font-size: 14px;
    color: #333;
    font-weight: 500;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.xinghui-product-option-label span {
    color: #e74c3c;
}

.xinghui-product-option-values {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.xinghui-product-option-btn {
    padding: 10px 20px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    background: #fff;
    color: #333;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.xinghui-product-option-btn:hover {
    border-color: #2a5298;
    color: #2a5298;
}

.xinghui-product-option-btn.xinghui-selected {
    border-color: #1e3c72;
    background: linear-gradient(135deg, rgba(30, 60, 114, 0.05) 0%, rgba(42, 82, 152, 0.05) 100%);
    color: #1e3c72;
    font-weight: 600;
}

.xinghui-product-option-btn.xinghui-disabled {
    opacity: 0.4;
    cursor: not-allowed;
    text-decoration: line-through;
}

.xinghui-product-quantity {
    display: flex;
    align-items: center;
    gap: 15px;
}

.xinghui-product-quantity-label {
    font-size: 14px;
    color: #333;
    font-weight: 500;
}

.xinghui-quantity-input {
    display: flex;
    align-items: center;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    overflow: hidden;
}

.xinghui-quantity-btn {
    width: 40px;
    height: 40px;
    background: #f8f9fa;
    border: none;
    color: #333;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.xinghui-quantity-btn:hover {
    background: #1e3c72;
    color: #fff;
}

.xinghui-quantity-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.xinghui-quantity-btn:disabled:hover {
    background: #f8f9fa;
    color: #333;
}

.xinghui-quantity-value {
    width: 60px;
    height: 40px;
    border: none;
    text-align: center;
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.xinghui-quantity-value:focus {
    outline: none;
}

.xinghui-product-stock {
    font-size: 13px;
    color: #27ae60;
    display: flex;
    align-items: center;
    gap: 5px;
}

.xinghui-product-stock i {
    font-size: 10px;
}

/* Product Actions */
.xinghui-product-actions {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
}

.xinghui-btn-inquiry {
    flex: 1;
    padding: 16px 30px;
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    position: relative;
    overflow: hidden;
}

.xinghui-btn-inquiry::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.xinghui-btn-inquiry:hover::before {
    left: 100%;
}

.xinghui-btn-inquiry:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(231, 76, 60, 0.4);
}

.xinghui-btn-download {
    flex: 1;
    padding: 16px 30px;
    background: #fff;
    color: #1e3c72;
    border: 2px solid #1e3c72;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.xinghui-btn-download:hover {
    background: #1e3c72;
    color: #fff;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(30, 60, 114, 0.3);
}

/* Product Features */
.xinghui-product-features {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
}

.xinghui-product-feature-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e0e0e0;
}

.xinghui-product-feature-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.xinghui-product-feature-icon {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}

.xinghui-product-feature-text {
    flex: 1;
}

.xinghui-product-feature-text strong {
    display: block;
    font-size: 14px;
    color: #333;
    margin-bottom: 3px;
}

.xinghui-product-feature-text span {
    font-size: 13px;
    color: #666;
}

/* Product Tabs Section */
.xinghui-product-tabs-section {
    background: #fff;
    padding: 0 0 60px;
}

.xinghui-product-tabs-wrapper {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 40px;
}

.xinghui-product-tabs-left {
    min-width: 0;
}

.xinghui-product-tabs-right {
    position: sticky;
    top: 100px;
    height: fit-content;
}

.xinghui-product-tabs {
    display: flex;
    border-bottom: 2px solid #e8ecef;
    margin-bottom: 40px;
}

.xinghui-product-tab {
    padding: 15px 30px;
    font-size: 16px;
    font-weight: 500;
    color: #666;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    border: none;
    background: none;
}

.xinghui-product-tab::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    transition: width 0.3s ease;
}

.xinghui-product-tab:hover {
    color: #1e3c72;
}

.xinghui-product-tab.xinghui-active {
    color: #1e3c72;
    font-weight: 600;
}

.xinghui-product-tab.xinghui-active::after {
    width: 100%;
}

.xinghui-product-tab-content {
    display: none;
    animation: xinghui-fadeIn 0.5s ease;
}

.xinghui-product-tab-content.xinghui-active {
    display: block;
}

/* Product Description */
.xinghui-product-description {
    max-width: 900px;
}

.xinghui-product-description h3 {
    font-size: 24px;
    color: #1e3c72;
    margin-bottom: 20px;
    font-weight: 600;
    position: relative;
    padding-bottom: 15px;
}

.xinghui-product-description h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
}

.xinghui-product-description p {
    font-size: 15px;
    color: #555;
    line-height: 1.8;
    margin-bottom: 15px;
}

.xinghui-product-description img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 20px 0;
}

.xinghui-product-description ul {
    margin: 20px 0;
    padding-left: 25px;
}

.xinghui-product-description ul li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 12px;
    color: #555;
    font-size: 15px;
    line-height: 1.6;
}

.xinghui-product-description ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 8px;
    width: 8px;
    height: 8px;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    border-radius: 50%;
}

/* Specifications Table */
.xinghui-product-specs-table {
    width: 100%;
    max-width: 900px;
    border-collapse: collapse;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
}

.xinghui-product-specs-table thead {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: #fff;
}

.xinghui-product-specs-table thead th {
    padding: 18px 20px;
    font-size: 15px;
    font-weight: 600;
    text-align: left;
}

.xinghui-product-specs-table tbody tr {
    border-bottom: 1px solid #e8ecef;
    transition: background 0.3s ease;
}

.xinghui-product-specs-table tbody tr:hover {
    background: #f8f9fa;
}

.xinghui-product-specs-table tbody td {
    padding: 15px 20px;
    font-size: 14px;
    color: #555;
}

.xinghui-product-specs-table tbody td:first-child {
    font-weight: 500;
    color: #333;
    width: 200px;
    background: #f8f9fa;
}

/* Applications */
.xinghui-product-applications-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    max-width: 900px;
}

.xinghui-product-application-card {
    background: #fff;
    border-radius: 8px;
    padding: 25px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border-left: 4px solid #1e3c72;
}

.xinghui-product-application-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(30, 60, 114, 0.15);
}

.xinghui-product-application-card h4 {
    font-size: 18px;
    color: #1e3c72;
    margin-bottom: 10px;
    font-weight: 600;
}

.xinghui-product-application-card p {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
}

/* Certifications */
.xinghui-product-certifications {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    max-width: 900px;
}

.xinghui-certification-badge {
    background: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px 30px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: all 0.3s ease;
}

.xinghui-certification-badge:hover {
    border-color: #1e3c72;
    box-shadow: 0 5px 15px rgba(30, 60, 114, 0.1);
}

.xinghui-certification-badge i {
    font-size: 32px;
    color: #1e3c72;
}

.xinghui-certification-badge span {
    font-size: 14px;
    color: #333;
    font-weight: 500;
}

/* Inquiry Modal */
.xinghui-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.xinghui-modal-overlay.xinghui-active {
    opacity: 1;
    visibility: visible;
}

.xinghui-inquiry-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    z-index: 10000;
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.xinghui-modal-overlay.xinghui-active .xinghui-inquiry-modal {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
}

.xinghui-inquiry-header {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: #fff;
    padding: 25px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.xinghui-inquiry-header h3 {
    font-size: 20px;
    font-weight: 600;
    margin: 0;
}

.xinghui-inquiry-close {
    background: none;
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    padding: 5px;
    transition: all 0.3s ease;
}

.xinghui-inquiry-close:hover {
    transform: rotate(90deg);
}

.xinghui-inquiry-body {
    padding: 30px;
}

.xinghui-inquiry-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.xinghui-inquiry-form .xinghui-form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.xinghui-inquiry-form label {
    font-size: 14px;
    color: #333;
    font-weight: 500;
}

.xinghui-inquiry-form label span {
    color: #e74c3c;
}

.xinghui-inquiry-form input,
.xinghui-inquiry-form textarea,
.xinghui-inquiry-form select {
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    transition: all 0.3s ease;
}

.xinghui-inquiry-form input:focus,
.xinghui-inquiry-form textarea:focus,
.xinghui-inquiry-form select:focus {
    outline: none;
    border-color: #2a5298;
    box-shadow: 0 0 0 3px rgba(42, 82, 152, 0.1);
}

.xinghui-inquiry-form textarea {
    min-height: 100px;
    resize: vertical;
}

.xinghui-inquiry-product-info {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    display: flex;
    gap: 15px;
    align-items: center;
}

.xinghui-inquiry-product-info img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 6px;
}

.xinghui-inquiry-product-details h4 {
    font-size: 15px;
    color: #1e3c72;
    margin-bottom: 5px;
    font-weight: 600;
}

.xinghui-inquiry-product-details p {
    font-size: 13px;
    color: #666;
}

.xinghui-inquiry-submit {
    padding: 14px 30px;
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.xinghui-inquiry-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(231, 76, 60, 0.4);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .xinghui-product-main {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .xinghui-product-gallery {
        position: static;
    }

    .xinghui-gallery-main-image {
        height: 400px;
    }

    .xinghui-product-title {
        font-size: 24px;
    }

    .xinghui-product-price-current {
        font-size: 32px;
    }

    .xinghui-product-specs {
        grid-template-columns: 1fr;
    }

    .xinghui-product-tabs-wrapper {
        grid-template-columns: 1fr;
    }

    .xinghui-product-tabs-right {
        position: static;
        order: -1;
    }
}

@media (max-width: 768px) {
    .xinghui-product-detail {
        padding: 30px 0 50px;
    }

    .xinghui-gallery-main-image {
        height: 350px;
    }

    .xinghui-gallery-thumbs {
        grid-template-columns: repeat(4, 1fr);
    }

    .xinghui-gallery-thumb {
        height: 70px;
    }

    .xinghui-product-title {
        font-size: 22px;
    }

    .xinghui-product-actions {
        flex-direction: column;
    }

    .xinghui-product-tabs {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .xinghui-product-tab {
        padding: 12px 20px;
        font-size: 14px;
        white-space: nowrap;
    }

    .xinghui-product-applications-grid {
        grid-template-columns: 1fr;
    }

    .xinghui-product-specs-table {
        font-size: 13px;
    }

    .xinghui-product-specs-table thead th,
    .xinghui-product-specs-table tbody td {
        padding: 12px 15px;
    }

    .xinghui-product-specs-table tbody td:first-child {
        width: 150px;
    }

    .xinghui-inquiry-modal {
        width: 95%;
        max-height: 85vh;
    }

    .xinghui-inquiry-header {
        padding: 20px;
    }

    .xinghui-inquiry-body {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .xinghui-breadcrumb-list {
        font-size: 12px;
    }

    .xinghui-gallery-main-image {
        height: 280px;
    }

    .xinghui-gallery-thumbs {
        grid-template-columns: repeat(4, 1fr);
        gap: 8px;
    }

    .xinghui-gallery-thumb {
        height: 60px;
    }

    .xinghui-product-meta {
        padding: 20px;
    }

    .xinghui-product-price-current {
        font-size: 28px;
    }

    .xinghui-product-option-btn {
        padding: 8px 15px;
        font-size: 13px;
    }

    .xinghui-quantity-btn {
        width: 35px;
        height: 35px;
    }

    .xinghui-quantity-value {
        width: 50px;
        height: 35px;
    }

    .xinghui-product-features {
        padding: 15px;
    }

    .xinghui-product-feature-item {
        padding-bottom: 12px;
        margin-bottom: 12px;
    }

    .xinghui-certification-badge {
        padding: 15px 20px;
    }

    .xinghui-certification-badge i {
        font-size: 24px;
    }
}
