.detail-layout {
    display: flex;
    gap: 30px;
    align-items: flex-start;
    position: relative;
}

.detail-left {
    flex: 0 0 62%;
    max-width: 62%;
    min-width: 0;
}

.detail-right {
    flex: 0 0 38%;
    max-width: 38%;
    position: relative;
    top: auto;
}

.detail-right-sticky-placeholder {
    flex: 0 0 0;
    width: 0;
    max-width: 0;
    min-width: 0;
    display: none;
    overflow: hidden;
}

.detail-gallery {
    display: flex;
    gap: 15px;
    align-items: stretch;
    margin-bottom: 24px;
}

.detail-gallery-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    width: 56px;
    flex: 0 0 56px;
}

.detail-gallery-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border: none;
    background: transparent;
    color: #666;
    font-size: 18px;
    cursor: pointer;
}

.detail-gallery-thumbs {
    width: 56px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 460px;
    overflow-y: auto;
    scrollbar-width: none;
}

.detail-gallery-thumbs::-webkit-scrollbar {
    display: none;
}

.thumb-item {
    width: 56px;
    height: 56px;
    border-radius: 4px;
}

.detail-gallery-stage {
    display: block;
    flex: 1;
    min-width: 0;
    position: relative;
    overflow: visible;
}

.detail-gallery-main {
    flex: none;
    width: 100%;
    min-width: 0;
    height: 460px;
    padding: 0;
    position: relative;
}

.detail-gallery-main::before,
.detail-gallery-main::after {
    content: none;
}

.detail-gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
    position: relative;
    z-index: 1;
}

.detail-gallery-mask {
    position: absolute;
    inset: 0;
    border-radius: 12px;
    background: rgba(11, 43, 71, 0.22);
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    z-index: 2;
    transition: opacity 0.15s ease;
}

.detail-gallery-mask.is-visible {
    opacity: 1;
    visibility: visible;
}

.detail-gallery-lens {
    position: absolute;
    width: 120px;
    height: 120px;
    border: 1px solid rgba(255, 255, 255, 0.95);
    background: rgba(255, 255, 255, 0.28);
    box-shadow: 0 0 0 1px rgba(11, 43, 71, 0.12);
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    z-index: 3;
}

.detail-gallery-lens.is-visible {
    opacity: 1;
    visibility: visible;
}

.detail-gallery-zoom {
    position: absolute;
    top: -24px;
    left: calc(100% + 12px);
    width: 640px;
    height: 620px;
    border: 1px solid #e8e8e8;
    border-radius: 4px;
    background-color: #fff;
    background-repeat: no-repeat;
    background-position: center;
    background-size: 280%;
    overflow: hidden;
    z-index: 50;
    opacity: 0;
    visibility: hidden;
    box-shadow: 0 10px 30px rgba(11, 43, 71, 0.12);
    transition: opacity 0.15s ease;
}

.detail-gallery-zoom-empty {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    font-size: 14px;
    background: rgba(255, 255, 255, 0.98);
}

.detail-gallery-zoom.is-active .detail-gallery-zoom-empty {
    display: none;
}

.detail-gallery-zoom.is-active {
    opacity: 1;
    visibility: visible;
}

.detail-sidebar-buttons .btn-inquire-now {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 12px;
    background: var(--primary);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    border: 1px solid var(--primary);
    border-radius: 30px;
    transition: background 0.2s ease, color 0.2s ease;
}

.detail-sidebar {
    padding: 22px 24px;
}

.detail-sidebar-title {
    font-size: 24px;
    margin-bottom: 16px;
}

.detail-sidebar-desc {
    margin-bottom: 22px;
    padding-bottom: 18px;
}

.detail-contact-row + .detail-contact-row {
    padding-top: 14px;
    border-top: 1px dotted #e0e0e0;
}

.detail-contact-text,
.contact-text {
    min-width: 0;
}

.detail-sidebar .contact-label {
    margin: 0 0 4px;
}

.detail-sidebar .contact-value {
    line-height: 1.3;
}

.detail-sidebar-certs {
    margin: 22px 0;
}

.detail-sidebar-certs img {
    display: block;
    max-width: 100%;
    height: auto;
}

.detail-sidebar-buttons {
    flex-direction: row;
    gap: 14px;
    margin: 20px 0 18px;
}

.detail-sidebar-buttons .btn-inquire-now,
.detail-sidebar-buttons .btn-related {
    flex: 1;
    min-width: 0;
}

.detail-sidebar-hint {
    font-size: 15px;
    margin-bottom: 18px;
    padding-bottom: 18px;
}

.detail-sidebar-hint strong {
    color: var(--primary);
}

.detail-sidebar-category {
    margin-top: 0;
    padding-top: 0;
}

.detail-sidebar-tags {
    margin-top: 18px;
}

.sidebar-section-label {
    font-size: 15px;
    margin-bottom: 10px;
}

.sidebar-category-links a,
.sidebar-tag-list span {
    background: #f4f5f7;
    border-radius: 8px;
    color: #333;
    font-size: 13px;
}

.sidebar-category-links a {
    padding: 10px 14px;
}

.sidebar-tag-list {
    gap: 10px;
}

.sidebar-tag-list span {
    padding: 10px 14px;
}

.detail-sidebar-buttons .btn-inquire-now:hover {
    background: var(--primary-dark);
}

.product-empty-note {
    padding: 20px;
    background: #f8f8f8;
    border: 1px dashed #d9d9d9;
    border-radius: 8px;
    color: #666;
}

.detail-sidebar {
    position: relative;
    top: 0;
    width: 100%;
}

.detail-right.is-fixed {
    position: fixed;
    top: var(--detail-right-top, 130px);
    left: var(--detail-right-left);
    width: var(--detail-right-width);
    flex: none;
    max-width: none;
    z-index: 25;
}

.detail-right.is-bottom {
    position: absolute;
    top: var(--detail-right-bottom-top);
    right: 0;
    width: var(--detail-right-width);
    flex: none;
    max-width: none;
}

@media (max-width: 1100px) {
    .detail-layout {
        flex-direction: column;
    }

    .detail-left,
    .detail-right {
        width: 100%;
        max-width: none;
        flex: none;
        align-self: auto;
    }

    .detail-gallery-main {
        width: 100%;
    }

    .detail-sidebar {
        position: static;
        top: auto;
        width: auto;
    }

    .detail-right.is-fixed,
    .detail-right.is-bottom {
        position: static;
        top: auto;
        left: auto;
        right: auto;
        width: auto;
        max-width: none;
    }
}

@media (max-width: 919px) {
    body.deye-product-detail .body-overflow-box {
        padding-top: 40px !important;
    }
}

@media (max-width: 767px) {
    .deye-product-detail .detail-main {
        padding-top: 0;
    }

    .detail-layout {
        display: grid;
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .detail-left {
        display: contents;
    }

    .detail-gallery {
        flex-direction: column;
        max-width: none;
        order: 1;
    }

    .detail-gallery-nav {
        width: 100%;
        flex: none;
        order: 2;
    }

    .detail-gallery-arrow {
        display: none;
    }

    .detail-gallery-thumbs {
        width: 100%;
        max-height: none;
        overflow-x: auto;
        overflow-y: hidden;
        flex-direction: row;
    }

    .thumb-item {
        flex: 0 0 56px;
    }

    .detail-gallery-stage {
        order: 1;
    }

    .detail-gallery-main {
        height: auto;
    }

    .detail-gallery-main img {
        height: auto;
    }

    .detail-right {
        max-width: none;
        order: 2;
        margin-bottom: 0;
        position: static;
        top: auto;
    }

    .detail-tabs {
        order: 3;
    }

    .detail-gallery-lens,
    .detail-gallery-zoom {
        display: none;
    }

    .detail-sidebar-buttons {
        flex-direction: column;
    }
}
