body {
    background:
        linear-gradient(to bottom, rgba(250,246,236,0.9), rgba(245,241,232,0.96)),
        repeating-linear-gradient(
            to bottom,
            rgba(255,255,255,0.55) 0,
            rgba(255,255,255,0.55) 2px,
            rgba(245,241,232,0.55) 2px,
            rgba(245,241,232,0.55) 6px
        );
}

#conteneur_detail {
    max-width: 1240px;
    margin: 0 auto;
    padding: 10px 24px 34px;
}

#conteneur_detail > #fildariane {
    margin-top: -2px;
    margin-bottom: 16px;
}

/* Layout */
.lg-detail {
    display: flex;
    gap: 34px;
    align-items: flex-start;
}

.lg-detail-left,
.lg-detail-right {
    min-width: 0;
}

/* Image */
.lg-detail-left {
    flex: 1;
}

.lg-oeuvre-img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
}

/* Infos */
.lg-detail-right {
    flex: 1;
}

.lg-oeuvre-title {
    font-size: 28px;
    line-height: 1.15;
    margin: 4px 0 10px;
    color: #1f1a12;
    letter-spacing: -0.02em;
}

.lg-oeuvre-artist {
    margin-bottom: 16px;
    font-size: 15px;
    color: #6f5a31;
}

.lg-oeuvre-artist a {
    color: #7b5513;
    font-weight: 700;
    text-decoration: none;
    border-bottom: 1px solid rgba(123, 85, 19, 0.25);
}

.lg-oeuvre-artist a:hover {
    color: #9b6912;
    border-bottom-color: rgba(155, 105, 18, 0.55);
}

/* Meta */
.lg-oeuvre-meta {
    margin: 18px 0 0;
    font-size: 15px;
    line-height: 1.7;
    color: #2f281d;
}

.lg-oeuvre-meta strong {
    color: #6f4d14;
}

/* Description */
.lg-oeuvre-description {
    position: relative;
    font-size: 15px;
    line-height: 1.85;
    color: #43392b;
}

/* Certif */
.lg-certif-btn {
    display: inline-block;
    margin-top: 20px;
    padding: 10px 16px;
    border-radius: 999px;
    background: linear-gradient(180deg, #d9b36a, #b98b34);
    color: #fff;
    text-decoration: none;
    font-weight: bold;
}

/* Responsive */
@media (max-width: 900px) {
    .lg-detail {
        flex-direction: column;
    }
}

/* Bloc infos global */
.lg-oeuvre-panel {
    margin-top: 16px;
    background: linear-gradient(to bottom, #ffffff 0%, #fcfaf6 100%);
    border-radius: 18px;
    border: 1px solid #eadfc7;
    padding: 20px 22px;
    box-shadow:
        0 18px 40px rgba(88, 68, 28, 0.08),
        0 2px 8px rgba(88, 68, 28, 0.04);
}

.lg-oeuvre-status {
    padding-bottom: 14px;
    margin-bottom: 14px;
    border-bottom: 1px solid #ece7da;
}

.lg-oeuvre-status-line {
    margin-bottom: 8px;
    font-size: 15px;
    line-height: 1.5;
}

.lg-price {
    font-weight: bold;
    color: #a06f12;
}

.lg-oeuvre-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
}

.lg-action-btn {
    display: inline-block;
    padding: 10px 14px;
    border-radius: 999px;
    background: #f4efe4;
    border: 1px solid #dccba6;
    color: #5f4717;
    text-decoration: none;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.18s ease;
}

.lg-action-btn:hover {
    background: #efe4cc;
    text-decoration: none;
}

.lg-action-btn-primary {
    background: linear-gradient(180deg, #d9b36a, #b98b34);
    color: #fff;
    border-color: #a57a2a;
    position: relative;
    overflow: hidden;
}

.lg-action-btn-primary:hover,
.lg-action-btn-trade:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(0,0,0,0.18);
    filter: brightness(1.08);
}

.lg-action-btn-trade {
    background: linear-gradient(180deg, #334766, #243654);
    border-color: #1f2f49;
    color: #fff;
}

.lg-action-btn-trade:hover {
    background: linear-gradient(180deg, #3b5276, #2a3f60);
    color: #fff;
    text-decoration: none;
}

.lg-action-btn-primary.lg-action-btn-trade {
    background: linear-gradient(180deg, #3a5075, #243654);
    border-color: #1f2f49;
    color: #fff;
}

.lg-action-btn-primary::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, transparent, rgba(255,255,255,0.35), transparent);
    opacity: 0;
    transition: opacity 0.25s ease;
}

.lg-action-btn-primary:hover::after {
    opacity: 1;
}

/* Galerie secondaire */
.lg-related-gallery {
    margin-top: 36px;
    background: linear-gradient(to bottom, #ffffff 0%, #fcfaf6 100%);
    border-radius: 18px;
    border: 1px solid #eadfc7;
    padding: 20px 20px 18px;
    box-shadow:
        0 18px 40px rgba(88, 68, 28, 0.08),
        0 2px 8px rgba(88, 68, 28, 0.04);
}

.lg-related-head {
    margin-bottom: 14px;
}

.lg-related-title {
    margin: 0;
    font-size: 20px;
    line-height: 1.2;
    color: #221b12;
    letter-spacing: -0.01em;
}

.lg-related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
    gap: 12px;
}

.lg-related-item {
    display: block;
    background: linear-gradient(to bottom, #fbfbfb 0%, #f4f1eb 100%);
    border-radius: 12px;
    padding: 6px;
    border: 2px solid transparent;
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
    text-decoration: none;
}

.lg-related-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 18px rgba(0,0,0,0.10);
}

.lg-related-item.is-active {
    border-color: #c89b3c;
    box-shadow: 0 0 0 3px rgba(200,155,60,0.16);
    background: #fffaf0;
}

.lg-related-item img {
    width: 100%;
    height: 86px;
    object-fit: cover;
    display: block;
    border-radius: 7px;
}

@media (max-width: 900px) {
    .lg-related-gallery {
        margin-top: 24px;
        padding: 14px;
    }

    .lg-related-title {
        font-size: 19px;
    }

    .lg-related-grid {
        grid-template-columns: repeat(auto-fill, minmax(82px, 1fr));
        gap: 10px;
    }

    .lg-related-item img {
        height: 76px;
    }
}

/* Zoom image */
.lg-oeuvre-image-wrap {
    position: relative;
}

.lg-oeuvre-img.is-zoomable {
    cursor: zoom-in;
}

.lg-image-watermark {
    position: absolute;
    left: 16px;
    bottom: 14px;
    margin: 0;
    padding: 6px 10px;
    font-size: 12px;
    line-height: 1.25;
    color: #fff;
    background: rgba(0,0,0,0.42);
    border-radius: 999px;
    pointer-events: none;
}

/* Bandeau sous image */
.lg-oeuvre-card {
    background: linear-gradient(to bottom, #ffffff 0%, #fcfaf6 100%);
    padding: 12px;
    border-radius: 18px;
    border: 1px solid #eadfc7;
    box-shadow:
        0 18px 42px rgba(88, 68, 28, 0.10),
        0 2px 8px rgba(88, 68, 28, 0.05);
    overflow: hidden;
}

.lg-oeuvre-image-wrap {
    border-radius: 12px;
    overflow: hidden;
}

.lg-image-meta-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 12px;
    padding: 14px 4px 4px;
    border-top: 1px solid #eadfc7;
}

.lg-image-meta-left,
.lg-image-meta-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.lg-image-meta-left {
    flex: 1 1 auto;
}

.lg-image-meta-right {
    flex: 0 0 auto;
}

.lg-image-views {
    font-size: 14px;
    color: #6d5a33;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
}

/* Bouton horodatage */
.lg-stamp-inline-wrap {
    display: inline-flex;
    align-items: center;
}

.lg-stamp-tooltip-box {
    position: relative;
    display: inline-block;
}

.lg-stamp-inline-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 4px 10px;
    border: 1px solid #d6c6a3;
    background: #f7f2e7;
    border-radius: 8px;
    text-decoration: none;
    color: #7b4d00;
    font-size: 11px;
    font-weight: bold;
    transition: all 0.2s ease;
    cursor: pointer;
}

.lg-stamp-inline-link:hover {
    background: #f0e6d3;
    border-color: #c9b48a;
    box-shadow: 0 1px 3px rgba(0,0,0,0.15);
    transform: translateY(-1px);
    text-decoration: none;
}

.lg-stamp-inline-text {
    white-space: nowrap;
}

.lg-stamp-inline {
    height: 36px;
    width: auto;
    position: relative;
}

.lg-stamp-tooltip {
    position: absolute;
    right: 0;
    bottom: 100%;
    margin-bottom: 8px;
    padding: 6px 9px;
    background: #333;
    color: #fff;
    font-size: 11px;
    line-height: 1.2;
    white-space: nowrap;
    border-radius: 4px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(4px);
    transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s ease;
    z-index: 50;
    box-shadow: 0 2px 6px rgba(0,0,0,0.18);
}

.lg-stamp-tooltip::after {
    content: "";
    position: absolute;
    top: 100%;
    right: 18px;
    border-width: 5px;
    border-style: solid;
    border-color: #333 transparent transparent transparent;
}

.lg-stamp-tooltip-box:hover .lg-stamp-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

@media (max-width: 900px) {
    .lg-image-meta-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        padding: 12px 0 2px;
    }

    .lg-image-meta-left,
    .lg-image-meta-right {
        justify-content: center;
    }

    .lg-certif-btn-under-image {
        text-align: center;
    }
}

.lg-copyright-badge {
    width: 40px;
    height: 40px;
    border: 1px solid #d5c29a;
    border-radius: 999px;
    background: #f7f0df;
    color: #6b4b12;
    font-size: 20px;
    font-weight: bold;
    cursor: pointer;
}

.lg-copyright-badge:hover {
    background: #efe4cc;
}

/* Bloc infos plus sobre */
.lg-oeuvre-status {
    padding-bottom: 10px;
    margin-bottom: 12px;
    border-bottom: 1px solid #ece7da;
}

.lg-popup[hidden] {
    display: none;
}

.lg-popup {
    position: fixed;
    inset: 0;
    z-index: 9999;
}

.lg-popup-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.72);
}

.lg-popup-dialog {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.lg-popup-dialog img {
    max-width: 96vw;
    max-height: 94vh;
    border-radius: 10px;
    box-shadow: 0 18px 50px rgba(0,0,0,0.35);
    cursor: zoom-out;
}

/* Lignes statut / prix */
.lg-status-row {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.lg-status-text {
    font-size: 15px;
    line-height: 1.4;
}

.lg-status-action {
    flex: 0 0 auto;
}

.lg-status-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 12px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 14px;
    line-height: 1;
}

.lg-status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex: 0 0 auto;
}

.lg-status-pill.is-available {
    background: #eef8ef;
    color: #2f6b35;
    border: 1px solid #b9d9bc;
}

.lg-status-pill.is-available .lg-status-dot {
    background: #38a24b;
}

.lg-status-pill.is-unavailable {
    background: #fff1ef;
    color: #9a3a2f;
    border: 1px solid #efc1bb;
}

.lg-status-pill.is-unavailable .lg-status-dot {
    background: #d65245;
}

.lg-status-pill.is-unknown {
    background: #f5f2ea;
    color: #7a6842;
    border: 1px solid #ddd0b4;
}

.lg-status-pill.is-unknown .lg-status-dot {
    background: #b59755;
}

/* Description tronquée */
.lg-oeuvre-description-wrap {
    margin-top: 18px;
}

.lg-oeuvre-description {
    position: relative;
    font-size: 14px;
    line-height: 1.75;
}

.lg-oeuvre-description.is-collapsed {
    max-height: 235px;
    overflow: hidden;
}

.lg-oeuvre-description.is-collapsed::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 70px;
    background: linear-gradient(to bottom, rgba(255,255,255,0), rgba(255,255,255,1));
}

.lg-description-toggle {
    margin-top: 12px;
    padding: 9px 14px;
    border: 1px solid #dccba6;
    border-radius: 999px;
    background: #f7f0df;
    color: #6a4b14;
    font-weight: 700;
    cursor: pointer;
}

.lg-description-toggle:hover {
    background: #efe4cc;
}

@media (max-width: 900px) {
    .lg-status-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .lg-status-action {
        width: 100%;
    }

    .lg-status-action .lg-action-btn,
    .lg-status-action .lg-action-btn-primary {
        width: 100%;
        text-align: center;
    }
}

/* MODALE */
.lg-modal[hidden] {
    display: none;
}

.lg-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
}

.lg-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.65);
}

.lg-modal-dialog {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.lg-modal-content {
    position: relative;
    background: #fff;
    border-radius: 14px;
    padding: 24px;
    max-width: 560px;
    width: 100%;
    box-shadow: 0 20px 60px rgba(0,0,0,0.25);
    z-index: 2;
}

.lg-modal-close {
    position: absolute;
    top: 12px;
    right: 14px;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 999px;
    background: #f4efe4;
    color: #5f4717;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    z-index: 3;
}

.lg-modal-close:hover {
    background: #efe4cc;
}

.lg-modal-headline h2 {
    margin: 0 0 6px;
    font-size: 24px;
}

.lg-modal-headline p {
    margin: 0 0 18px;
    color: #6f6758;
    font-size: 14px;
}

.lg-modal-field {
    margin-bottom: 16px;
}

.lg-modal-field label {
    display: block;
    margin-bottom: 6px;
    font-weight: 700;
    color: #5f4717;
}

.lg-modal-field input,
.lg-modal-field select {
    width: 100%;
    padding: 11px 12px;
    border: 1px solid #d8c8a4;
    border-radius: 10px;
    font-size: 15px;
    box-sizing: border-box;
}

.lg-modal-field small {
    display: block;
    margin-top: 6px;
    color: #7a6b50;
}

.lg-modal-readonly {
    padding: 11px 12px;
    background: #f8f4ea;
    border: 1px solid #e6d8b8;
    border-radius: 10px;
}

.lg-modal-actions {
    margin-top: 20px;
    display: flex;
    justify-content: flex-end;
}

.lg-modal-success {
    padding: 14px 16px;
    background: #edf8ee;
    border: 1px solid #b8d9ba;
    border-radius: 10px;
    color: #245a2a;
    line-height: 1.5;
}

.lg-modal-error {
    padding: 14px 16px;
    background: #fff3f1;
    border: 1px solid #efc2bc;
    border-radius: 10px;
    color: #8a2b1d;
    line-height: 1.5;
    margin-bottom: 16px;
}

.lg-modal-notice,
.lg-modal-copy {
    line-height: 1.65;
    color: #4e463a;
}

@media (max-width: 980px) {
    #conteneur_detail {
        padding: 10px 16px 28px;
    }

    .lg-detail {
        gap: 24px;
    }

    .lg-oeuvre-title {
        font-size: 24px;
    }

    .lg-oeuvre-panel,
    .lg-related-gallery,
    .lg-oeuvre-card {
        border-radius: 16px;
    }
}