/**
 * CSS - Recette du Jour v2.6 (Homepage)
 * Design épuré avec mise en avant des étapes illustrées
 * Modales interactives pour panier et planning
 * Support dark mode natif
 * 
 * @version 2.6
 * @date 2025-01-25
 */

/* ============================================
   CARTE PRINCIPALE
   ============================================ */

.rdj-card {
    display: grid;
    grid-template-columns: 1fr;
    margin-top: 20px;
    background: linear-gradient(135deg, #ffffff 0%, #fff5f5 100%);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 40px;
    transition: box-shadow 0.3s ease;
}

/* IMPORTANT : sans min-width:0, les enfants grid (et notamment .rdj-content
   qui contient un swiper) débordent du gabarit 1fr 1fr et écrasent la
   colonne de l'image principale. */
.rdj-card > * {
    min-width: 0;
}

.rdj-card:hover {
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.15);
}

/* Dark mode */
[data-theme="dark"] .rdj-card,
.dark-mode .rdj-card {
    background: linear-gradient(135deg, #232a2e 0%, #2f2929 100%) !important;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .rdj-card:hover,
.dark-mode .rdj-card:hover {
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.5);
}

@media (min-width: 768px) {
    .rdj-card {
        grid-template-columns: 1fr 1fr;
        gap: 20px;
    }
}

/* ============================================
   IMAGE PRINCIPALE - Pleine hauteur
   ============================================ */

.rdj-image-wrapper {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 4 / 3;
}

.rdj-image-link {
    display: block;
    width: 100%;
    height: 100%;
}

/* Bouton Favori (style identique aux vignettes recettes) */
.rdj-favorite-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(45, 55, 72, 0.7);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 15;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(4px);
}

.rdj-favorite-btn:hover {
    background: rgba(45, 55, 72, 0.9);
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Icône coeur - état non liké */
.rdj-favorite-btn .heart-icon {
    font-size: 20px;
    color: rgba(255, 255, 255, 0.9);
    transition: all 0.2s ease;
    margin-top: 1px;
}

/* Icône coeur - état liké */
.rdj-favorite-btn.is-liked .heart-icon {
    color: #ff6b6b;
}

/* Animation au clic */
.rdj-favorite-btn:active {
    transform: scale(0.95);
}

/* Animation de pulsation quand on like */
.rdj-favorite-btn.just-liked .heart-icon {
    animation: heartPulse 0.4s ease;
}

@keyframes heartPulse {
    0% { transform: scale(1); }
    25% { transform: scale(1.3); }
    50% { transform: scale(1); }
    75% { transform: scale(1.15); }
    100% { transform: scale(1); }
}

@media (min-width: 768px) {
    .rdj-image-wrapper {
        aspect-ratio: unset;
        height: 100%;
        min-height: 400px;
    }
}

.rdj-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.rdj-image-wrapper:hover .rdj-image {
    transform: scale(1.05);
}

.rdj-season-badge {
    position: absolute;
    bottom: 16px;
    left: 16px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: linear-gradient(135deg, #27ae60, #2ecc71);
    color: white;
    font-size: 0.85rem;
    font-weight: 600;
    border-radius: 20px;
    box-shadow: 0 2px 10px rgba(39, 174, 96, 0.4);
    z-index: 2;
}

/* ============================================
   TAGS (temps / difficulté / prix)
   Mêmes styles que les .recipe-tag des vignettes recettes.
   Positionnés en haut à gauche de l'image, au-dessus de l'overlay.
   ============================================ */

.rdj-tags {
    position: absolute;
    top: 10px;
    left: 10px;
    right: 60px; /* Laisse la place au bouton favori (40px + marges) */
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    z-index: 2;
}

.rdj-tag {
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    backdrop-filter: blur(8px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
    transition: transform 0.2s ease;
    white-space: nowrap;
}

/* Couleurs — reprises de generateTagsHtmlLatest() dans
   include-page-accueil-dernieres-recettes.php. La home assigne les
   couleurs PAR POSITION (pas par type sémantique) :
     1er tag → vert, 2ème → orange, 3ème → bleu, 4ème → violet.
   On applique la même séquence pour garantir une cohérence visuelle
   parfaite avec les vignettes "Dernières recettes". */
.rdj-tag--temps      { background-color: rgba(46, 213, 115, 0.9); }  /* Vert — 1er */
.rdj-tag--difficulte { background-color: rgba(255, 121, 63, 0.9); }  /* Orange — 2ème */
.rdj-tag--prix       { background-color: rgba(54, 185, 255, 0.9); }  /* Bleu — 3ème */

/* Responsive : tags un peu plus compacts sur mobile, comme les vignettes */
@media (max-width: 600px) {
    .rdj-tags {
        top: 8px;
        left: 8px;
        gap: 4px;
    }
    .rdj-tag {
        padding: 3px 8px;
        font-size: 0.7rem;
    }
}

/* ============================================
   CONTENU
   ============================================ */

.rdj-content {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

@media (min-width: 768px) {
    .rdj-content {
        padding: 20px 25px 20px 10px;
        /* justify-content: center; */
    }
}

.rdj-title-link {
    text-decoration: none;
}

.rdj-title {
    margin: 0;
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary, #2d3436);
    line-height: 1.3;
    transition: color 0.2s ease;
}

.rdj-title-link:hover .rdj-title {
    color: #FF6B6B;
}

[data-theme="dark"] .rdj-title,
.dark-mode .rdj-title {
    color: var(--text-primary, #f0f0f0);
}

@media (min-width: 768px) {
    .rdj-title {
        font-size: 1.5rem;
    }
}

/* ============================================
   SECTION ÉTAPES ILLUSTRÉES
   ============================================ */

.rdj-steps-section {
    border-radius: 12px;
    margin: 4px 0;
    /* Bloque l'expansion en largeur causée par les enfants flex (swiper) */
    min-width: 0;
    max-width: 100%;
}

/* ============================================
   SWIPER ÉTAPES — boucle infinie + ease souple
   ============================================ */

.rdj-steps-swiper.swiper {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    padding: 10px 8px;
    position: relative;
    /* Indispensable pour que Swiper calcule la bonne largeur dans un parent flex/grid */
    box-sizing: border-box;
}

.rdj-steps-swiper .swiper-wrapper {
    display: flex;
    align-items: stretch;
    /* Easing souple pour un avancement doux entre slides */
    transition-timing-function: cubic-bezier(0.25, 0.1, 0.25, 1);
}

.rdj-steps-swiper .swiper-slide {
    /* La largeur est gérée par Swiper via slidesPerView (numérique). */
    height: auto;
    box-sizing: border-box;
}

/* ============================================
   PRÉ-DIMENSIONNEMENT (avant init Swiper)
   Évite le FOUC où la première slide prend 100% de la largeur du wrapper
   flex. Les breakpoints miroitent la config JS (page-accueil-rdj-steps-swiper.js).
   ============================================ */

.rdj-steps-swiper:not(.swiper-initialized) {
    opacity: 0;
    visibility: hidden;
}

.rdj-steps-swiper.swiper-initialized {
    opacity: 1;
    visibility: visible;
    transition: opacity 0.25s ease;
}

.rdj-steps-swiper:not(.swiper-initialized) .swiper-wrapper {
    gap: 12px;
}

/* Par défaut : 3 slides visibles (mobile + desktop étroit) */
.rdj-steps-swiper:not(.swiper-initialized) .swiper-slide {
    flex: 0 0 calc((100% - 12px * 2) / 3);
    max-width: calc((100% - 12px * 2) / 3);
}

@media (min-width: 640px) {
    .rdj-steps-swiper:not(.swiper-initialized) .swiper-slide {
        flex: 0 0 calc((100% - 12px * 3) / 4);
        max-width: calc((100% - 12px * 3) / 4);
    }
}

@media (min-width: 768px) {
    .rdj-steps-swiper:not(.swiper-initialized) .swiper-slide {
        flex: 0 0 calc((100% - 12px * 2) / 3);
        max-width: calc((100% - 12px * 2) / 3);
    }
}

@media (min-width: 1024px) {
    .rdj-steps-swiper:not(.swiper-initialized) .swiper-slide {
        flex: 0 0 calc((100% - 12px * 3) / 4);
        max-width: calc((100% - 12px * 3) / 4);
    }
}

@media (min-width: 1400px) {
    .rdj-steps-swiper:not(.swiper-initialized) .swiper-slide {
        flex: 0 0 calc((100% - 12px * 4) / 5);
        max-width: calc((100% - 12px * 4) / 5);
    }
}

.rdj-step-item {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 1;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.15);
    border: 1px solid transparent;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    cursor: pointer;
}

.rdj-step-item:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

/* Slides inactifs : semi-transparents */
.rdj-steps-swiper .swiper-slide:not(.swiper-slide-active) .rdj-step-item {
    opacity: 0.45;
    border-color: transparent;
}

.rdj-steps-swiper .swiper-slide:not(.swiper-slide-active) .rdj-step-item:hover {
    opacity: 0.75;
}

/* Slide active : bordure épaisse + glow prononcé */
.rdj-steps-swiper .swiper-slide-active .rdj-step-item,
.rdj-steps-swiper .swiper-slide-duplicate-active .rdj-step-item {
    border: 3px solid #FF6B6B;
    box-shadow:
        0 0 0 2px rgba(255, 107, 107, 0.2),
        0 4px 12px rgba(255, 107, 107, 0.35);
    opacity: 1;
}

[data-theme="dark"] .rdj-steps-swiper .swiper-slide-active .rdj-step-item,
.dark-mode .rdj-steps-swiper .swiper-slide-active .rdj-step-item {
    border-color: #ff8a8a;
    box-shadow:
        0 0 0 2px rgba(255, 138, 138, 0.2),
        0 4px 12px rgba(0, 0, 0, 0.4);
}

/* Texte de description sous le swiper */
.rdj-step-description {
    margin: 14px 4px 0;
    padding: 10px 14px;
    font-size: 0.88rem;
    line-height: 1.45;
    color: var(--text-secondary, #555);
    background: rgba(255, 107, 107, 0.06);
    border-left: 3px solid #FF6B6B;
    border-radius: 6px;
    /* Hauteur fixe (~3 lignes) pour éviter le saut des boutons en dessous */
    min-height: calc(1.45em * 3 + 20px);
    box-sizing: border-box;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: opacity 0.25s ease;
}

.rdj-step-description:empty::before {
    content: '\00a0'; /* nbsp pour préserver la hauteur */
}

[data-theme="dark"] .rdj-step-description,
.dark-mode .rdj-step-description {
    color: #d0d0d0;
    background: rgba(255, 138, 138, 0.08);
    border-left-color: #ff8a8a;
}

.rdj-step-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.rdj-step-num {
    position: absolute;
    bottom: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #FF6B6B, #e55a5a);
    color: white;
    font-size: 0.8rem;
    font-weight: 700;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(255, 107, 107, 0.5);
}

@media (max-width: 768px) {
    .rdj-steps-swiper .swiper-slide {
        width: 110px;
    }
}

/* ============================================
   BOUTONS D'ACTION
   ============================================ */

.rdj-actions {
    display: flex;
    align-items: stretch;
    gap: 8px;
    margin-top: 8px;
}

@media (min-width: 500px) {
    .rdj-actions {
        gap: 12px;
    }
}

.rdj-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 24px;
    border: none;
    border-radius: 12px;
    /* Normalisation cross-elements : les 3 boutons sont un mix de <button>
       et <a>. Les user-agent stylesheets imposent au <button> un font-family
       dédié (-webkit-small-control, etc.) et une line-height différente de
       celle héritée par un <a>. Résultat : hauteurs calculées divergentes.
       On force l'héritage + une line-height unitless pour que la hauteur
       dépende uniquement de font-size + padding. */
    font-family: inherit;
    font-size: 0.95rem;
    line-height: 1;
    font-weight: 600;
    box-sizing: border-box;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.rdj-btn--secondary {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    color: var(--text-primary, #2d3436);
    border: 2px solid #dee2e6;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.rdj-btn--secondary:hover {
    background: linear-gradient(135deg, #fff, #f8f9fa);
    border-color: #FF6B6B;
    color: #FF6B6B;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.15);
}

.rdj-btn--secondary i {
    font-size: 1.1rem;
}

[data-theme="dark"] .rdj-btn--secondary,
.dark-mode .rdj-btn--secondary {
    background: linear-gradient(135deg, #2d2d3d, #252535);
    color: var(--text-primary, #e0e0e0);
    border-color: #404050;
}

[data-theme="dark"] .rdj-btn--secondary:hover,
.dark-mode .rdj-btn--secondary:hover {
    background: linear-gradient(135deg, #3d3d4d, #353545);
    border-color: #ff8a8a;
    color: #ff8a8a;
}

.rdj-btn--primary {
    background: linear-gradient(135deg, #FF6B6B, #e55a5a);
    color: white;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
}

.rdj-btn--primary:hover {
    background: linear-gradient(135deg, #e55a5a, #d94a4a);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 107, 0.4);
    color: white;
}

.rdj-btn--primary:focus {
    color: white;
}

/* Boutons d'action (Ajouter, Planifier) — icône + libellé permanent.
   Hérite de .rdj-btn pour padding/font/line-height : garantit la même
   hauteur que le bouton "Voir la recette" (rdj-btn--primary). */
.rdj-btn--action {
    color: #ffffff;
    border: none;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
    white-space: nowrap;
}

.rdj-btn--action i {
    font-size: 1.1rem;
}

.rdj-btn--action:hover {
    transform: translateY(-2px);
    filter: brightness(1.06);
}

/* Panier - Bleu */
.rdj-btn--cart {
    background: linear-gradient(135deg, #4dabf7 0%, #339af0 100%);
    box-shadow: 0 3px 10px rgba(51, 154, 240, 0.3);
}

.rdj-btn--cart:hover {
    box-shadow: 0 6px 18px rgba(51, 154, 240, 0.45);
}

/* Planning - Orange */
.rdj-btn--planning {
    background: linear-gradient(135deg, #ffa94d 0%, #fd7e14 100%);
    box-shadow: 0 3px 10px rgba(253, 126, 20, 0.3);
}

.rdj-btn--planning:hover {
    box-shadow: 0 6px 18px rgba(253, 126, 20, 0.45);
}

/* Favoris (vestige, garde le style coloré si encore utilisé ailleurs) */
.rdj-btn--favorite {
    background: linear-gradient(135deg, #ff6b6b 0%, #f03e3e 100%);
    color: white;
}

.rdj-btn--favorite.is-favorite {
    color: white;
}

/* Dark mode : mêmes dégradés (lisibilité OK sur fond sombre) */
[data-theme="dark"] .rdj-btn--cart,
.dark-mode .rdj-btn--cart,
[data-theme="dark"] .rdj-btn--planning,
.dark-mode .rdj-btn--planning {
    color: #ffffff;
}

/* ============================================
   MODALES
   ============================================ */

.rdj-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

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

.rdj-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    background: var(--bg-primary, #fff);
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    z-index: 9999;
    width: 90%;
    max-width: 340px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

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

.rdj-modal--planning {
    max-width: 380px;
}

[data-theme="dark"] .rdj-modal,
.dark-mode .rdj-modal {
    background: var(--bg-primary, #1e1e2e);
}

.rdj-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color, #eee);
}

.rdj-modal-header h4 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary, #2d3436);
    display: flex;
    align-items: center;
    gap: 10px;
}

.rdj-modal-header h4 i {
    color: #FF6B6B;
}

[data-theme="dark"] .rdj-modal-header,
.dark-mode .rdj-modal-header {
    border-color: var(--border-color, #333);
}

[data-theme="dark"] .rdj-modal-header h4,
.dark-mode .rdj-modal-header h4 {
    color: var(--text-primary, #f0f0f0);
}

.rdj-modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-secondary, #999);
    cursor: pointer;
    padding: 0;
    line-height: 1;
    transition: color 0.2s;
}

.rdj-modal-close:hover {
    color: #FF6B6B;
}

.rdj-modal-body {
    padding: 20px;
}

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

.rdj-modal-field:last-child {
    margin-bottom: 0;
}

.rdj-modal-field label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary, #636e72);
    margin-bottom: 8px;
}

.rdj-modal-field label i {
    margin-right: 6px;
    color: #FF6B6B;
}

[data-theme="dark"] .rdj-modal-field label,
.dark-mode .rdj-modal-field label {
    color: var(--text-secondary, #aaa);
}

.rdj-servings-control {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.rdj-servings-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid #FF6B6B;
    background: transparent;
    color: #FF6B6B;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    transition: all 0.2s;
}

.rdj-servings-btn:hover {
    background: #FF6B6B;
    color: white;
}

.rdj-servings-control input {
    width: 60px;
    text-align: center;
    font-size: 1.2rem;
    font-weight: 700;
    border: 2px solid var(--border-color, #ddd);
    border-radius: 10px;
    padding: 8px;
    color: var(--text-primary, #2d3436);
    background: var(--bg-secondary, #f8f9fa);
}

[data-theme="dark"] .rdj-servings-control input,
.dark-mode .rdj-servings-control input {
    background: var(--bg-secondary, #2d2d3d);
    border-color: var(--border-color, #404050);
    color: var(--text-primary, #f0f0f0);
}

.rdj-modal-field select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border-color, #ddd);
    border-radius: 10px;
    font-size: 1rem;
    color: var(--text-primary, #2d3436);
    background: var(--bg-secondary, #f8f9fa);
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23666' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10l-5 5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
}

[data-theme="dark"] .rdj-modal-field select,
.dark-mode .rdj-modal-field select {
    background-color: var(--bg-secondary, #2d2d3d);
    border-color: var(--border-color, #404050);
    color: var(--text-primary, #f0f0f0);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23aaa' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10l-5 5z'/%3E%3C/svg%3E");
}

.rdj-date-wrapper {
    position: relative;
}

.rdj-date-wrapper input[type="date"] {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border-color, #ddd);
    border-radius: 10px;
    font-size: 1rem;
    color: var(--text-primary, #2d3436);
    background: var(--bg-secondary, #f8f9fa);
}

[data-theme="dark"] .rdj-date-wrapper input[type="date"],
.dark-mode .rdj-date-wrapper input[type="date"] {
    background: var(--bg-secondary, #2d2d3d);
    border-color: var(--border-color, #404050);
    color: var(--text-primary, #f0f0f0);
}

.rdj-date-wrapper .flatpickr-calendar {
    box-shadow: none !important;
    border: 1px solid var(--border-color, #ddd) !important;
    border-radius: 10px !important;
    margin-top: 8px;
}

.rdj-modal-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--border-color, #eee);
}

[data-theme="dark"] .rdj-modal-footer,
.dark-mode .rdj-modal-footer {
    border-color: var(--border-color, #333);
}

.rdj-modal-submit {
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, #FF6B6B, #e55a5a);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.2s;
}

.rdj-modal-submit:hover {
    background: linear-gradient(135deg, #e55a5a, #d94a4a);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
}

.rdj-modal-submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* ============================================
   NOTIFICATION
   ============================================ */

.rdj-notification {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: rgba(0, 0, 0, 0.85);
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 0.9rem;
    z-index: 10001;
    opacity: 0;
    transition: all 0.3s ease;
}

.rdj-notification.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ============================================
   RESPONSIVE TABLETTE / PETIT DESKTOP
   ============================================ */

/* 768–1024px : boutons compacts, icônes masquées */
@media (max-width: 1024px) and (min-width: 768px) {
    .rdj-btn {
        padding: 12px 16px;
        font-size: 0.85rem;
        gap: 0;
    }

    .rdj-btn i {
        display: none;
    }
}

/* ============================================
   RESPONSIVE MOBILE
   ============================================ */

@media (max-width: 480px) {
    .rdj-content {
        padding: 20px 16px;
    }
    
    .rdj-title {
        font-size: 1.25rem;
    }
    
    .rdj-steps-section {
        /* no padding */
    }

    .rdj-step-num {
        width: 22px;
        height: 22px;
        font-size: 0.7rem;
        bottom: 6px;
        right: 6px;
    }
    
    .rdj-actions {
        gap: 8px;
    }
    
    .rdj-btn {
        padding: 12px 18px;
        font-size: 0.9rem;
    }
    
    .rdj-btn--icon {
        width: 42px;
        height: 42px;
        min-width: 42px;
        font-size: 1.05rem;
        border-radius: 10px;
    }
    
    /* Masquer les tooltips sur mobile */
    .rdj-btn--icon::after,
    .rdj-btn--icon::before {
        display: none;
    }
    
    .rdj-modal {
        width: 95%;
        max-width: none;
    }
}
