/**
 * annonce_modifier.css
 * Styles compacts & responsives pour le formulaire de modification d'annonce
 * LeTrocRoyal.com — Version 3.0 (Avril 2026)
 */

/* ============================================================
   RESET & BASE
   ============================================================ */
/*
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Segoe UI', Arial, Helvetica, sans-serif;
    font-size: 13px;
    color: #333;
    background: linear-gradient(135deg, #f0f2f5 0%, #e2e6ea 100%);
    min-height: 100vh;
    padding: 20px;
    line-height: 1.4;
}
*/

/* CARD photo modifier annonce */
/* Masquage accessible pour inputs file */
.sr-only-file {
    position: absolute !important;
    left: -9999px !important;
    top: -9999px !important;
    opacity: 0 !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    pointer-events: auto !important; /* ✅ Autorise les clics programmatiques */
}

/* ============================================================
   CONTENEUR PRINCIPAL
   ============================================================ */
.mod-wrapper {
    max-width: 900px;
    margin: 0 auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.08), 0 1px 4px rgba(0,0,0,0.04);
    overflow: hidden;
}

.mod-header {
    background: linear-gradient(135deg, #7a1b2d 0%, #5a1020 100%);
    color: #fff;
    padding: 16px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.mod-header h1 {
    font-size: 17px;
    font-weight: 700;
}

.mod-header .ref-badge {
    font-size: 11px;
    background: rgba(255,255,255,0.15);
    padding: 4px 12px;
    border-radius: 20px;
    font-family: monospace;
}

.mod-body {
    padding: 0;
}

/* ============================================================
   FORMULAIRE COMPACT (GRID)
   ============================================================ */
.compact-form {
    --gap: 10px;
    --h: 34px;
    --r: 6px;
    --border: 1px solid #e0e0e0;
    --focus: #7a1b2d;
    
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--gap);
    padding: 18px 20px;
}

.compact-form .full-width {
    grid-column: 1 / -1;
}

.compact-form .half-width {
    grid-column: span 1;
}

@media (max-width: 600px) {
    .compact-form {
        grid-template-columns: 1fr;
        padding: 14px;
    }
    .compact-form .half-width {
        grid-column: 1 / -1;
    }
}

/* Labels */
.compact-form label.cl {
    font-size: 10.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    color: #5a5a5a;
    margin-bottom: 3px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.compact-form label.cl em {
    font-weight: 400;
    text-transform: none;
    font-size: 10px;
    color: #999;
}

.compact-form .req {
    color: #d32f2f;
    font-size: 11px;
}

/* Inputs, Selects, Textareas */
.compact-form input,
.compact-form select,
.compact-form textarea {
    height: var(--h);
    padding: 0 10px;
    font-size: 13px;
    border: var(--border);
    border-radius: var(--r);
    background: #fafafa;
    transition: all 0.2s ease;
    width: 100%;
    font-family: inherit;
    color: #333;
}

.compact-form input:focus,
.compact-form select:focus,
.compact-form textarea:focus {
    outline: none;
    border-color: var(--focus);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(122,27,45,0.08);
}

.compact-form textarea {
    height: auto;
    min-height: 52px;
    resize: vertical;
    padding: 8px 10px;
    line-height: 1.45;
}

.compact-form select {
    cursor: pointer;
}

/* ============================================================
   SECTION TITRE
   ============================================================ */
.section-title-modifie {
    grid-column: 1 / -1;
    font-size: 12px;
    font-weight: 700;
    color: #7a1b2d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding-bottom: 4px;
    border-bottom: 2px solid #7a1b2d;
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.section-title-modifie .icon {
    font-size: 14px;
}

/* ============================================================
   DESCRIPTIONS - MISE EN VALEUR OPTIMISÉE
   ============================================================ */
.desc-highlight-section {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 16px;
    background: linear-gradient(135deg, #fdfbf9 0%, #f8f6f2 100%);
    border: 1px solid #e8e2d9;
    border-radius: 10px;
    padding: 16px;
    margin-top: 4px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.03);
}

@media (max-width: 650px) {
    .desc-highlight-section {
        grid-template-columns: 1fr;
    }
}

.desc-card {
    display: flex;
    flex-direction: column;
    position: relative;
    width:330px;
}

.desc-card .cl {
    font-size: 11.5px;
    color: #7a1b2d;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 6px;
    text-transform: none;
    letter-spacing: 0;
}

.desc-card .cl .arrow-icon {
    font-size: 15px;
}

.desc-card .cl em {
    font-weight: 400;
    font-size: 10px;
    color: #888;
    text-transform: none;
}

.desc-card textarea {
    min-height: 85px;
    background: #ffffff;
    border: 1.5px solid #d1c7b7;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 13.5px;
    line-height: 1.55;
    color: #2d2a26;
    resize: vertical;
    transition: all 0.25s ease;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.04);
}

.desc-card textarea:focus {
    outline: none;
    border-color: #7a1b2d;
    box-shadow: 0 0 0 4px rgba(122,27,45,0.08), inset 0 1px 3px rgba(0,0,0,0.04);
    background: #fff;
}

.desc-card textarea::placeholder {
    color: #a89f91;
    font-style: italic;
}

.desc-hint {
    font-size: 10.5px;
    color: #7a7062;
    margin-top: 5px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.desc-hint::before {
    content: "💡";
    font-size: 11px;
}

.char-counter {
    position: absolute;
    bottom: 8px;
    right: 10px;
    font-size: 10px;
    color: #999;
    background: rgba(255,255,255,0.9);
    padding: 1px 6px;
    border-radius: 10px;
    pointer-events: none;
}

/* ============================================================
   PHOTOS COMPACTES
   ============================================================ */
.photos-row {
    grid-column: 1 / -1;
    display: flex;
    gap: 10px;
    align-items: flex-start;
    flex-wrap: wrap;
}


.photo-card {
    position: relative; /* Indispensable pour positionner les enfants */
    width: 80px; height: 80px;
    border: 2px dashed #ddd;
    border-radius: 8px;
    overflow: hidden;
    background: #f8f8f8;
    display: flex; align-items: center; justify-content: center;
    transition: all 0.2s;
}
/* L'input file devient un calque transparent au-dessus de la carte */
.photo-card input[type="file"] {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;         /* Invisible */
    cursor: pointer;    /* Curseur main */
    z-index: 20;        /* Au-dessus de l'image et du texte */
    font-size: 0;       /* Évite certains bugs navigateur */
}

.photo-card:hover {
    border-color: #7a1b2d;
    background: #fff5f5;
}

.photo-card.has-img {
    border-style: solid;
    border-color: #ccc;
    cursor: default;
}

.photo-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}

.photo-card.has-img img {
    display: block;
}

.photo-card .plus {
    font-size: 24px;
    color: #bbb;
    font-weight: 300;
}

.photo-card.has-img .plus {
    display: none;
}

.photo-card .label-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0,0,0,0.55);
    color: #fff;
    font-size: 8px;
    text-align: center;
    padding: 2px 0;
    font-weight: 600;
}

.photo-card .remove-btn {
    position: absolute;
    top: 4px; right: 4px;
    width: 20px; height: 20px;
    background: rgba(220, 53, 69, 0.9); /* Rouge bien visible */
    color: #fff;
    border: none;
    border-radius: 50%;
    font-size: 14px;
    cursor: pointer;
    z-index: 9990;         /* ✅ AU-DESSUS de l'input (10) */
    pointer-events: auto; /* ✅ Réactive le clic spécifiquement ici */
    display: none;       /* Caché par défaut */
    align-items: center;
    justify-content: center;
    line-height: 1;
}


.photo-card.has-img .remove-btn {
    display: flex;
}


/* ============================================================
   SOULTE (Pliable)
   ============================================================ */
.soulte-toggle {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: #f5f0eb;
    border-radius: var(--r);
    cursor: pointer;
    user-select: none;
}

.soulte-toggle input[type="checkbox"] {
    accent-color: #7a1b2d;
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.soulte-toggle span {
    font-size: 12px;
    font-weight: 600;
    color: #5a3020;
}

.soulte-panel {
    grid-column: 1 / -1;
    display: none;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: var(--gap);
    padding: 12px;
    background: #faf6f2;
    border-radius: var(--r);
    border: 1px solid #e8ddd4;
}

.soulte-panel.open {
    display: grid;
}

.montant-row {
    display: flex;
    gap: 6px;
    align-items: center;
}

.montant-row input {
    flex: 1;
}

.montant-row .sep {
    color: #999;
    font-weight: 700;
}

.montant-row .euro {
    color: #7a1b2d;
    font-weight: 700;
    font-size: 14px;
}

/* ============================================================
   LOCALISATION
   ============================================================ */
.region-display {
    background: #f0f0f0 !important;
    color: #666 !important;
    font-weight: 600;
}

/* Barre de progression CP */
.cp-progress {
    display: flex;
    gap: 2px;
    height: 3px;
    margin-top: 4px;
}

.cp-progress .seg {
    flex: 1;
    border-radius: 2px;
    background: #ddd;
    transition: background 0.3s;
}

.cp-progress .seg.filled-main {
    background: #7a1b2d;
}

.cp-progress .seg.filled-user {
    background: #4caf50;
}

/* ============================================================
   PRIORITÉ
   ============================================================ */
.priorite-row {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.priorite-row select {
    max-width: 220px;
}

.priorite-info {
    font-size: 11px;
    padding: 4px 10px;
    border-radius: 20px;
    border: 1px solid #e0e0e0;
    background: #f9f9f9;
    transition: all 0.3s;
    color: gray;
    font-weight: 900;
}

/* ============================================================
   VÉRIFICATION D'IDENTITÉ
   ============================================================ */
.auth-card {
    grid-column: 1 / -1;
    margin-top: 10px;
    border-radius: var(--r);
    overflow: hidden;
    border: 1px solid #e0e0e0;
}

.auth-header {
    background: linear-gradient(135deg, #7a1b2d 0%, #5a1020 100%);
    color: #fff;
    padding: 10px 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.auth-header .icon {
    font-size: 16px;
}

.auth-header span {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.auth-body {
    background: #fafafa;
    padding: 14px;
}

.auth-body p {
    font-size: 12px;
    color: #555;
    margin: 0 0 10px 0;
}

.auth-input-wrap {
    position: relative;
    max-width: 280px;
    margin-bottom: 10px;
}

.auth-input-wrap input {
    padding-right: 40px;
    font-size: 14px;
}

.auth-toggle-btn {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
}

.auth-warning {
    padding: 8px 10px;
    background: #fff8e1;
    border-left: 3px solid #ffc107;
    border-radius: 4px;
    font-size: 11px;
    color: #856404;
    margin-bottom: 8px;
}

.auth-footer {
    font-size: 10px;
    color: #777;
    line-height: 1.5;
    padding-left: 4px;
}

/* ============================================================
   DERNIÈRE MODIFICATION
   ============================================================ */
.last-mod {
    grid-column: 1 / -1;
    font-size: 11px;
    color: #888;
    display: flex;
    align-items: center;
    gap: 6px;
    padding-top: 6px;
    border-top: 1px dashed #e0e0e0;
}

.last-mod .icon {
    font-size: 14px;
}

/* ============================================================
   BOUTONS
   ============================================================ */
.form-actions {
    grid-column: 1 / -1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 12px;
    border-top: 2px solid #eee;
    margin-top: 4px;
}

.btn {
    height: 34px;
    padding: 0 18px;
    font-size: 12.5px;
    font-weight: 700;
    border: none;
    border-radius: var(--r);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
    font-family: inherit;
}

.btn:active {
    transform: scale(0.97);
}

.btn-history {
    background: #f0f0f0;
    color: #555;
}

.btn-history:hover {
    background: #e0e0e0;
}

.btn-submit {
    background: linear-gradient(135deg, #7a1b2d 0%, #5a1020 100%);
    color: #fff;
    box-shadow: 0 2px 8px rgba(122,27,45,0.25);
}

.btn-submit:hover {
    box-shadow: 0 4px 12px rgba(122,27,45,0.35);
    transform: translateY(-1px);
}

/* ============================================================
   FEEDBACK VISUEL
   ============================================================ */
.valid {
    border-color: #4caf50 !important;
    background: #f0fff0 !important;
}

.warning {
    border-color: #ff9800 !important;
    background: #fffef0 !important;
}

.error {
    border-color: #d32f2f !important;
    background: #fff0f0 !important;
}

/* Tooltip */
.cp-hint {
    grid-column: 1 / -1;
    font-size: 10px;
    color: #999;
    margin-top: 1px;
    margin-left:120px;
}

/* ============================================================
   MODAL FEEDBACK
   ============================================================ */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

.modal-overlay.active {
    display: flex;
}

.modal-box {
    background: #fff;
    padding: 30px;
    border-radius: 12px;
    max-width: 400px;
    width: 90%;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.modal-box h2 {
    margin: 10px 0;
    color: #7a1b2d;
}

.modal-box p {
    color: #555;
    margin-bottom: 20px;
}

.modal-box .btn {
    width: 100%;
    justify-content: center;
}

/* ============================================================
   TOPBAR & BADGES
   ============================================================ */
.secure-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 20px;
    background: #fff;
    border-bottom: 1px solid #e0e0e0;
    border-left: 1px solid #e0e0e0;
    box-shadow: 2px 6px 4px rgba(0, 0, 0, 0.25), inset 3px 2px 6px rgba(215, 210, 210, 0.5);
}

.secure-topbar__left {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: #555;
}

.secure-topbar__check {
    color: #4caf50;
    font-weight: 700;
}

.secure-topbar__ref {
    font-family: monospace;
    color: #7a1b2d;
    background: #fff5f5;
    padding: 2px 8px;
    border-radius: 4px;
}

.secure-topbar__badges {
    display: flex;
    gap: 8px;
}

.badge-secure {
    font-size: 10px;
    padding: 4px 10px;
    border-radius: 12px;
    font-weight: 600;
}

.badge-secure--gold {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffc107;
}

.badge-secure--white {
    background: #f8f9fa;
    color: #555;
    border: 1px solid #dee2e6;
}

/* ============================================================
   CARDS & SECTIONS
   ============================================================ */
.card {
    background: #fff;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    margin-bottom: 16px;
}

.card__header {
    padding: 12px 16px;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card__header-title {
    font-size: 13px;
    font-weight: 700;
    color: #333;
}

.card__header-dots {
    display: flex;
    gap: 4px;
}

.card__header-dots span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #7a1b2d;
    opacity: 0.6;
}

.card__body {
    padding: 16px;
}

/* ============================================================
   PAGE HERO & BREADCRUMB
   ============================================================ */
   /*
.page-hero {
    padding: 16px 20px;
    background: #fff;
    border-bottom: 1px solid #e0e0e0;
}

.page-hero__breadcrumb {
    font-size: 11px;
    color: #6c757d;
}

.page-hero__breadcrumb a {
    color: #7a1b2d;
    text-decoration: none;
}

.page-hero__breadcrumb a:hover {
    text-decoration: underline;
}

.page-hero__breadcrumb .sep {
    margin: 0 6px;
    color: #adb5bd;
}
*/
/* ===== 5. HERO SECTION ===== */
.page-hero {
    /*padding: 32px 32px 16px;*/
    max-width: 1280px;
    margin: 0 auto;
}

.page-hero__breadcrumb {
    font-size: 12.5px;
    color: var(--color-text-light);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.page-hero__breadcrumb a { color: var(--color-primary); text-decoration: none; }
.page-hero__breadcrumb a:hover { text-decoration: underline; }
.page-hero__breadcrumb .sep { color: var(--color-gray-mid); }

.page-hero__title {
    font-family: var(--font-primary);
    font-size: 38px;
    font-weight: 700;
    color: var(--color-primary);
    line-height: 1.15;
    letter-spacing: -.02em;
}

.page-hero__subtitle {
    font-size: 16px;
    color: var(--color-text-mid);
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.page-hero__subtitle .arrow { color: var(--color-gold); font-weight: 700; }


/* ===== 21. MESSAGES D'ERREUR / SUCCÈS ===== */
.form-feedback {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    font-size: 13.5px;
    line-height: 1.5;
    margin-bottom: 16px;
}

.form-feedback--error {
    background: var(--color-warning-bg);
    border-left: 3px solid var(--color-warning);
    color: var(--color-warning);
}

.form-feedback--success {
    background: var(--color-success-bg);
    border-left: 3px solid var(--color-success);
    color: var(--color-success);
}

/* ============================================================
   LAYOUT MAIN
   ============================================================ */
/* ===== 6. LAYOUT PRINCIPAL ===== */
.layout-main {
    max-width: 1280px;
    margin: 0 auto;
    /*padding: 20px 32px 60px;*/
    padding: 0px 5px 5px;
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 24px;
    align-items: start;
    background-color: white;
    box-shadow: -6px 7px 4px rgba(0, 0, 0, 0.25), inset 4px -1px 6px rgba(215, 210, 210, 0.5);		
    border-bottom-right-radius: 10px;
    border-bottom-left-radius: 10px;
    border:0px solid gray;
}
/*
.layout-main {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 24px;
    padding: 20px;
}*/

@media (max-width: 900px) {
    .layout-main {
        grid-template-columns: 1fr;
    }
}

.form-column {
    min-width: 0;
}

.sidebar {
    position: sticky;
    top: 20px;
    height: fit-content;
}

/* ============================================================
   IDENTITY CARD (Sidebar)
   ============================================================ */
.identity-card {
    background: #fff;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
}

.identity-card__header {
    padding: 12px 16px;
    background: linear-gradient(135deg, #7a1b2d 0%, #5a1020 100%);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
    border-radius: 8px 8px 0 0;
}

.identity-card__body {
    padding: 16px;
}

.identity-card__subtitle {
    font-size: 12px;
    color: #555;
    margin-bottom: 12px;
}

.input-wrapper {
    position: relative;
}

.input-icon-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
}

.input-icon-btn svg {
    display: block;
    color: #666;
}

.input-icon-btn svg[data-icon-hide] {
    display: none;
}

.attempts-warning {
    padding: 8px 10px;
    background: #fff8e1;
    border-left: 3px solid #ffc107;
    border-radius: 4px;
    font-size: 11px;
    color: #856404;
    margin: 12px 0;
}

.btn-full {
    width: 100%;
    justify-content: center;
}


/* ===== 18. MODALE SUCCÈS ===== */
.modal-overlay {
    display: none;  /* Caché par défaut */
    position: fixed;
    inset: 0;
    background: rgba(30,15,10,.55);
    backdrop-filter: blur(4px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity .3s ease;
}

.modal-overlay.active {
    display: flex;  /* Affiché quand .active est ajouté */
    opacity: 1;
    pointer-events: all;
}

.modal-modifie {
    background: #fff;
    border-radius: var(--radius-xl);
    box-shadow: 0 24px 80px rgba(30,15,10,.25);
    padding: 48px 36px 36px;
    max-width: 420px;
    width: 100%;
    text-align: center;
    transform: translateY(20px) scale(.97);
    transition: transform .3s cubic-bezier(.34,1.56,.64,1);
    position: relative;
}

.modal-overlay.active .modal-modifie {
    transform: translateY(0) scale(1);
}

.modal__close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: var(--color-gray-light);
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    cursor: pointer;
    color: var(--color-text-mid);
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition);
}

.modal__close:hover { background: var(--color-gray-mid); color: var(--color-text-dark); }

.modal__icon {
    width: 72px;
    height: 72px;
    background: linear-gradient(135deg, var(--color-success-bg) 0%, #D4EDDA 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    border: 3px solid var(--color-success);
    color: var(--color-success);
    font-size: 32px;
}

.modal__title {
    font-family: var(--font-primary);
    font-size: 32px;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 10px;
}

.modal__message {
    font-size: 15px;
    color: var(--color-text-mid);
    margin-bottom: 28px;
    line-height: 1.6;
}

/* ===== 19. MODALE HISTORIQUE ===== */
/*
.history-modal .modal-modifie { max-width: 600px; padding: 32px; text-align: left; }

.history-table { width: 100%; border-collapse: collapse; margin-top: 14px; }

.history-table th {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--color-text-light);
    padding: 8px 12px;
    border-bottom: 2px solid var(--color-border);
}

.history-table td {
    padding: 10px 12px;
    font-size: 13px;
    color: var(--color-text-dark);
    border-bottom: 1px solid var(--color-border);
    vertical-align: top;
}

.history-table tr:last-child td { border-bottom: none; }
.history-table tr:hover td { background: var(--color-gray-light); }


.btn-loader {
    display: none;
    margin-left: 6px;
    animation: spin 1s linear infinite;
}

.btn.loading .btn-text {
    display: none;
}

.btn.loading .btn-loader {
    display: inline;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}
*/
/* ============================================================
 ===== 19. MODALE HISTORIQUE (Scrollable) ===== 
 ============================================================ */
.history-modal .modal-modifie {
    max-width: 600px;
    padding: 32px;
    text-align: left;
    
    /* 🆕 Ajouts pour gérer le scroll interne */
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* 🆕 Fixe le titre en haut (il ne scrollera pas) */
.history-modal .modal-modifie > h2,
.history-modal .modal-modifie > p:first-of-type {
    flex-shrink: 0;
    margin-bottom: 16px;
}

.history-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 14px;
    
    /* 🆕 Rend le tableau scrollable */
    flex: 1;
    overflow-y: auto;
    display: block;          /* Indispensable pour overflow-y sur un <table> */
    min-height: 0;           /* Bugfix Flexbox */
    table-layout: auto;      /* Conserve le redimensionnement naturel des colonnes */
}

.history-table th {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--color-text-light);
    padding: 8px 12px;
    border-bottom: 2px solid var(--color-border);
    
    /* 🆕 Garde les en-têtes visibles pendant le scroll */
    position: sticky;
    top: 0;
    background: #fff;        /* Évite la superposition du texte pendant le scroll */
    z-index: 2;
}

.history-table td {
    padding: 10px 12px;
    font-size: 13px;
    color: var(--color-text-dark);
    border-bottom: 1px solid var(--color-border);
    vertical-align: top;
}

.history-table tr:last-child td { border-bottom: none; }
.history-table tr:hover td { background: var(--color-gray-light); }

/* 🆕 Style de la barre de défilement (optionnel mais recommandé) */
.history-table::-webkit-scrollbar { width: 6px; }
.history-table::-webkit-scrollbar-track { background: #f1f1f1; border-radius: 4px; }
.history-table::-webkit-scrollbar-thumb { background: #ccc; border-radius: 4px; }
.history-table::-webkit-scrollbar-thumb:hover { background: #aaa; }
/* ============================================================
   UTILITIES
   ============================================================ */
.text-center { text-align: center; }
.text-right { text-align: right; }
.mt-1 { margin-top: 4px; }
.mt-2 { margin-top: 8px; }
.mb-1 { margin-bottom: 4px; }
.mb-2 { margin-bottom: 8px; }
.hidden { display: none !important; }

/* ============================================================
   PRINT STYLES
   ============================================================ */
@media print {
    body {
        background: #fff;
        padding: 0;
    }
    .mod-wrapper {
        box-shadow: none;
        border: 1px solid #ddd;
    }
    .btn, .auth-card, .soulte-toggle, .photo-card .remove-btn {
        display: none !important;
    }
}


.privacy-warning-box {
    grid-column: 1 / -1;
    padding: 10px 12px;
    border-radius: 6px;
    border: 1px solid #dc3545;
    background: linear-gradient(135deg, #fff5f5 0%, #ffe5e5 100%);
    margin-top: 8px;
    box-shadow: 0 1px 3px rgba(220, 53, 69, 0.1);
}

.privacy-warning-box small {
    color: #dc3545;
    font-size: 11px;
    line-height: 1.5;
    display: block;
}

.privacy-warning-box strong {
    font-weight: 700;
    text-transform: uppercase;
    font-size: 10px;
    letter-spacing: 0.3px;
}