body {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    color: #2d3436;
    margin: 0;
    padding: 20px;
}

h1 {
    font-weight: 800;
    letter-spacing: -1px;
    color: #2d3436;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.05);
    text-align: center;
    margin-bottom: 30px;
}

.card-form {
    border: none;
    border-radius: 15px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    padding: 25px;
    margin: 0 auto 40px auto;
    max-width: 900px;
}

.form-control {
    border-radius: 10px;
    border: 1px solid #dfe6e9;
    padding: 12px 15px;
}

.form-control:focus {
    box-shadow: 0 0 0 3px rgba(9, 132, 227, 0.2);
    border-color: #0984e3;
    outline: none;
}

.btn-generate {
    background: linear-gradient(to right, #0984e3, #6c5ce7);
    border: none;
    border-radius: 10px;
    font-weight: 600;
    color: white;
    padding: 12px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-generate:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(108, 92, 231, 0.4);
}

.table-container {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    max-width: 1300px;
    margin: 0 auto;
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table thead {
    background: #2d3436;
    color: white;
}

.table th {
    padding: 15px;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1px;
}

.table td {
    vertical-align: top !important; 
    padding: 25px 15px !important;
    border-bottom: 1px solid #eee;
}

.col-product {
    width: 15%;
    font-weight: 800;
    color: #2d3436;
    text-transform: uppercase;
    padding-top: 35px !important; /* Pour aligner avec le texte de l'IA */
}

.description-cell {
    width: 60%;
}

.col-date {
    width: 140px;
    padding-top: 35px !important;
}

.col-action {
    width: 140px;
    text-align: center;
    padding-top: 35px !important;
}



/* Le jour reste sobre */
.date-day {
    font-weight: 600;
    color: #2d3436;
    margin-right: 10px;
}

/* L'heure qui ressort grave (Style Badge dans le Badge) */
.date-time {
    background-color: #0984e3; /* Un bleu pro et vif */
    color: white !important;
    padding: 4px 8px;
    border-radius: 4px;
    font-weight: 700;
    letter-spacing: 0.5px;
}
.btn-delete {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background-color: #ff4757; 
    color: white !important;
    border: none;
    padding: 10px 15px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    transition: 0.3s;
}

.btn-delete:hover {
    background-color: #ff6b81;
    transform: scale(1.05);
}

.md-render {
    line-height: 1.6;
    font-size: 0.95rem;
    text-align: left;
    white-space: pre-wrap;
}

.md-render h3 {
    color: #d63384;
    font-size: 1.2rem;
    margin-top: 0;
    margin-bottom: 15px;
}

.md-render p { 
    margin-bottom: 15px; 
}

.md-render strong {
    color: #0d6efd;
    background: #f0f7ff;
    padding: 2px 5px;
    border-radius: 4px;
}

/* Listes avec éclairs */
.md-render ul { 
    margin-top: 10px; 
    margin-bottom: 15px;
    padding-left: 0;
    list-style-type: none;
}

.md-render li { 
    margin-bottom: 5px !important;
    line-height: 1.4 !important;
    padding-left: 25px;
    position: relative;
}

.md-render li::before {
    content: "⚡";
    position: absolute;
    left: 0;
    color: #ffa502;
}

/* On garde aussi ces classes au cas où ton code PHP les utilise toujours */
.description-text { @extend .md-render; }
.markdown-content { @extend .md-render; }

.description-cell { transition: all 0.3s ease; }
.md-render { font-size: 0.95rem; line-height: 1.6; }
.hidden-row { display: none; }

/* Style pour le texte tronqué (Mode Aperçu) */
.truncate-text {
    max-width: 400px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: inline-block;
    vertical-align: middle;
}

.btn-view-modal { color: #0d6efd; cursor: pointer; text-decoration: underline; margin-left: 5px; font-size: 0.9rem; }

/* Mode Exploration (Tout afficher) */
.mode-exploration .truncate-text {
    max-width: none;
    white-space: normal;
    display: block;
}

.mode-exploration .btn-view-modal { display: none; }

.md-render { font-size: 0.95rem; line-height: 1.6; }
.date-pill { background: #f0f2f5; padding: 4px 8px; border-radius: 20px; font-size: 0.85rem; white-space: nowrap; }
.hidden-section { display: none; }

/* Style spécifique pour la liste du Mode Aperçu */
.preview-item { 
    background: #fff; 
    border: 1px solid #dee2e6; 
    transition: transform 0.2s;
    cursor: default; 
}

.preview-item:hover { transform: translateY(-2px); box-shadow: 0 4px 8px rgba(0,0,0,0.1); }

.modal-body { max-height: 75vh; overflow-y: auto; }

#loader-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(255,255,255,0.8); backdrop-filter: blur(5px);
    z-index: 9999; display: none; flex-direction: column;
    justify-content: center; align-items: center;
}

.swal-bootstrap-modal .modal-content {
    background: white !important;
    border-radius: 16px !important;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4) !important;
}

.swal-bootstrap-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 2.5rem;
    font-weight: bold;
}

.swal-bootstrap-warning {
    border: 4px solid #ffc107;
    color: #ffc107;
    animation: swal-pulse-icon 2s infinite ease-in-out;
}

.swal-btn-confirm {
    color: white !important;
    border: none !important;
    border-radius: 6px !important;
    transition: background 0.2s ease;
}

.swal-btn-cancel {
    color: #fff !important;
    border: none !important;
    border-radius: 6px !important;
    transition: background 0.2s ease;
}

/* Animation de pulsation  */
@keyframes swal-pulse-icon {
    0%, 100% { transform: scale(1); box-shadow: 0 0 0 rgba(255, 193, 7, 0); }
    50% { transform: scale(1.05); box-shadow: 0 0 15px rgba(255, 193, 7, 0.3); }
}

.swal-bootstrap-success {
    border: 4px solid #1ed760;
    color: #1ed760;
    animation: swal-pulse-success 2s infinite ease-in-out;
}

.swal-bootstrap-danger {
    border: 4px solid #dc3545;
    color: #dc3545;
    animation: swal-pulse-danger 2s infinite ease-in-out;
}

.swal-btn-close {
    background-color: #0d6efd !important;
    color: #fff !important;
    border: none !important;
    border-radius: 6px !important;
    transition: background 0.2s ease;
}
.swal-btn-close:hover {
    background-color: #0b5ed7 !important;
}

.swal-btn-danger {
    background-color: #dc3545 !important;
    color: #fff !important;
    border: none !important;
    border-radius: 6px !important;
    text-decoration: none !important;
    display: inline-block;
    transition: background 0.2s ease;
}
.swal-btn-danger:hover {
    background-color: #bb2d3b !important;
}

/* Animations de pulsations spécifiques */
@keyframes swal-pulse-success {
    0%, 100% { transform: scale(1); box-shadow: 0 0 0 rgba(30, 215, 96, 0); }
    50% { transform: scale(1.05); box-shadow: 0 0 15px rgba(30, 215, 96, 0.3); }
}

@keyframes swal-pulse-danger {
    0%, 100% { transform: scale(1); box-shadow: 0 0 0 rgba(220, 53, 69, 0); }
    50% { transform: scale(1.05); box-shadow: 0 0 15px rgba(220, 53, 69, 0.3); }
}