/* -----------------------------
           CHAMPS DATE PREMIUM OPENSPLACE
        ------------------------------ */
.op-date-field {
    position: relative;
}

.op-date-field input {
    padding-left: 45px !important;
}

.op-date-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 22px;
    opacity: .8;
}

/* ---------- FLATPICKR OPENSPLACE PREMIUM ---------- */

.flatpickr-calendar {
    border-radius: 18px !important;
    border: 1px solid #e7e0cd !important;
    box-shadow: 0 15px 45px rgba(0,0,0,0.22) !important;
    overflow: hidden !important;
    font-family: system-ui, sans-serif;
}

.flatpickr-innerContainer {
    display: flex !important;
    flex-direction: column !important;
}

.flatpickr-rContainer {
    margin: 0 auto !important;
}

.flatpickr-days {
    margin: 0 auto !important;
}

/* Header mois / année / flèches */
.flatpickr-months {
    background: #0d615a !important;
    color: #fff !important;
    border-bottom: 1px solid #0b514a !important;
    padding: 6px 0;
}

.flatpickr-current-month {
    color: #fff !important;
}

.flatpickr-current-month .cur-month {
    color: #fff !important;
    font-weight: 600;
}

.flatpickr-current-month .numInputWrapper .numInput {
    color: #fff !important;
    font-weight: 600;
}

.flatpickr-prev-month,
.flatpickr-next-month {
    color: #fff !important;
}

    .flatpickr-prev-month svg,
    .flatpickr-next-month svg {
        fill: #fff !important;
    }

.flatpickr-weekday {
    color: #0d615a !important;
    font-weight: 600;
}

.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange {
    background: #0d615a !important;
    border-color: #0d615a !important;
    color: #fff !important;
}

.flatpickr-day.today {
    border-color: #0d615a !important;
}

/* Bloc heures plus visible & lisible */
.flatpickr-time {
    border-top: 1px solid #f0f7f7 !important;
    background: #f0f7f7 !important;
    padding: 14px 16px !important;
    display: flex !important;
    justify-content: center;
    align-items: center;
    gap: 16px;
    box-sizing: border-box;
    min-height: 55px;
}

.flatpickr-time input {
    color: #0d615a !important;
    font-weight: 700;
    font-size: 1.15rem;
    width: 4ch;
    text-align: center;
}

.flatpickr-time .flatpickr-time-separator {
    color: #0d615a !important;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    margin-top: 0 !important;
}

/* Boutons Effacer / Valider */
.op-fp-actions {
    display: flex;
    justify-content: space-between;
    padding: 12px;
    background: #fff;
    border-top: 1px solid #f0f7f7;
}

.op-fp-btn {
    flex: 1;
    margin: 0 6px;
    padding: 10px;
    border-radius: 10px;
    border: none;
    font-weight: 600;
    cursor: pointer;
    font-size: 1rem;
}

.op-fp-clear {
    background: #f0f7f7;
    color: #333;
}

.op-fp-validate {
    background: #0d615a;
    color: white;
}

/* ============================================
   FLATPICKR – STYLE B (GLASSMORPHISM PREMIUM)
   ============================================ */

/* Forcer l’affichage permanent des flèches */
.flatpickr-time .numInputWrapper span {
    opacity: 1 !important;
    visibility: visible !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 19px;
    backdrop-filter: blur(8px);
    background: rgba(255, 255, 255, 0.28);
    border: 1px solid rgba(255, 255, 255, 0.45);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.25s ease-in-out;
}

/* Icônes SVG des flèches */
.flatpickr-time .numInputWrapper span svg {
    width: 15px;
    height: 15px;
    fill: #0d615a !important;
    transition: transform 0.25s ease-in-out;
}

/* Hover moderne */
.flatpickr-time .numInputWrapper span:hover {
    background: rgba(255, 255, 255, 0.45);
    transform: scale(1.08);
}

/* Clic (effet tactile) */
.flatpickr-time .numInputWrapper span:active {
    transform: scale(0.92);
}

/* Mobile : plus grand, plus accessible */
@media (max-width: 600px) {

    .flatpickr-time .numInputWrapper span {
        width: 30px;
        height: 19px;
        border-radius: 12px;
        backdrop-filter: blur(12px);
    }

    .flatpickr-time .numInputWrapper span svg {
        width: 18px;
        height: 18px;
    }
}

/* Mobile : calendrier centré & bloc heure plus grand */
@media (max-width: 600px) {
    .flatpickr-calendar {
        width: 100% !important;
        max-width: 420px;
        left: 50% !important;
        transform: translateX(-50%) !important;
        height: auto !important;
    }

    .flatpickr-days {
        box-sizing: border-box;
    }

    .flatpickr-time {
        padding: 18px 20px !important;
        min-height: 55px;
    }

    .op-fp-actions {
        padding: 16px 14px;
    }
}
