/* Floating Message Widget — clone du look chezlouis */
.msg-widget-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}
.msg-widget-overlay.active {
    opacity: 1;
    visibility: visible;
}
.msg-widget {
    position: fixed;
    bottom: 30px;
    right: 0; /* Collé au bord droit comme chez Louis */
    z-index: 9999;
    opacity: 0;
    visibility: hidden; /* caché tant que pas lancé */
    pointer-events: none;
}
/* L'entrée : glisse depuis la droite après 4s, comme chez Louis */
.msg-widget.visible {
    visibility: visible;
    pointer-events: auto;
    animation: slideInBouton 1.2s ease-out forwards;
    animation-delay: 4s;
}
@keyframes slideInBouton {
    from { right: -300px; opacity: 0; }
    to { right: 0px; opacity: 1; }
}
.msg-widget-toggle {
    background: var(--accent-color);
    color: #fff;
    border: none;
    padding: 15px 25px;
    border-radius: 10px 0 0 10px; /* arrondi chic à gauche, collé à droite */
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    box-shadow: -5px 5px 15px rgba(0,0,0,0.3);
    transition: background 0.3s, padding-right 0.3s, filter 0.3s;
    border: none;
    margin-left: auto;
}
.msg-widget-toggle:hover { filter: brightness(0.88); padding-right: 35px; }
.msg-widget-toggle .mw-icon-default { display: flex; }
.msg-widget-toggle .sep {
    width: 1px;
    height: 20px;
    background: rgba(255,255,255,0.4);
}
.msg-widget-toggle .mw-icon-close { display: none; margin-left: 8px; }
.msg-widget.active .msg-widget-toggle .mw-icon-default,
.msg-widget.active .msg-widget-toggle .sep,
.msg-widget.active .msg-widget-toggle .mw-btn-text {
    display: none;
}
.msg-widget.active .msg-widget-toggle .mw-icon-close { display: flex; }
.msg-widget.active .msg-widget-toggle { padding-right: 12px; border-radius: 10px; }
.msg-widget-panel {
    position: absolute;
    bottom: 75px;
    right: 0;
    width: 380px;
    max-width: calc(100vw - 40px);
    max-height: calc(100vh - 120px);
    background: var(--accent-color);
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    overflow: hidden;
    display: none;
    flex-direction: column;
}
.msg-widget.active .msg-widget-panel { display: flex; }
.msg-widget-body {
    padding: 20px 20px 20px;
    overflow-y: auto;
    flex: 1;
}
.mw-logo {
    text-align: center;
    padding: 4px 0 14px;
}
.mw-logo img {
    display: inline-block;
    max-height: 90px;
    max-width: 100%;
    filter: drop-shadow(0 2px 6px rgba(0,0,0,0.15));
}
.mw-title {
    font-size: 17px;
    font-weight: 700;
    color: #fff;
    text-align: center;
    margin-bottom: 2px;
}
.mw-subtitle {
    font-size: 12.5px;
    color: rgba(255,255,255,0.9);
    text-align: center;
    margin-bottom: 16px;
}

/* Accordeons */
.msg-widget-body .accordion {
    width: 100%;
    background: rgba(255,255,255,0.16);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    border: 1px solid rgba(255,255,255,0.35);
    border-left: 4px solid rgba(255,255,255,0.9);
    border-radius: 8px;
    padding: 13px 14px;
    margin-bottom: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    text-align: left;
    transition: background 0.2s;
}
.msg-widget-body .accordion:hover { background: rgba(255,255,255,0.26); }
.msg-widget-body .accordion i:first-child { color: #fff; }
.mw-arrow {
    margin-left: auto;
    font-size: 12px;
    color: rgba(255,255,255,0.9);
    transition: transform 0.3s;
}
.msg-widget-body .accordion.active .mw-arrow { transform: rotate(180deg); }
.msg-widget-body .accordion.active { background: rgba(255,255,255,0.28); }
.msg-widget-body .panel {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
    padding: 0 4px;
}
.msg-widget-body .panel.open { max-height: 320px; }

/* Champs avec icone */
.form-group {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255,255,255,0.94);
    border: 1px solid rgba(255,255,255,0.7);
    border-radius: 8px;
    padding: 10px 12px;
    margin-bottom: 10px;
}
.form-group i { color: var(--accent-color); font-size: 15px; width: 18px; text-align: center; }
.form-group input,
.form-group textarea {
    flex: 1;
    border: none;
    outline: none;
    font-size: 13.5px;
    color: #222;
    background: transparent;
    font-family: inherit;
}
.form-group input::placeholder,
.form-group textarea::placeholder { color: #9a9a9a; }
.form-group textarea { resize: none; min-height: 70px; }

/* Bouton envoyer */
.reserve {
    width: 100%;
    padding: 12px;
    background: #fff;
    color: var(--accent-color);
    border: 2px solid #fff;
    border-radius: 8px;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    margin-top: 6px;
    box-shadow: 0 0 12px rgba(255,255,255,0.3);
    transition: background 0.3s, box-shadow 0.3s;
}
.reserve:hover { background: rgba(255,255,255,0.85); box-shadow: 0 0 16px rgba(255,255,255,0.7); }
.reserve:disabled { opacity: 0.65; cursor: wait; }
#form-msg {
    margin-top: 10px;
    font-size: 13px;
    text-align: center;
    min-height: 18px;
}
#form-msg.ok { color: #27ae60; }
#form-msg.err { color: #e74c3c; }

/* ─── Réservation : grilles couverts / horaires ─── */
.button-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 6px;
    padding: 4px 0 10px;
}
.button-grid button {
    padding: 10px 0;
    border: 1px solid rgba(255,255,255,0.7);
    border-radius: 8px;
    background: rgba(255,255,255,0.18);
    color: #fff;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}
.button-grid button:hover { border-color: #fff; background: rgba(255,255,255,0.3); }
.button-grid button.selected {
    background: #fff;
    border-color: #fff;
    color: var(--accent-color);
}

/* Date : boutons horizontaux */
.horizontal-buttons {
    display: flex;
    gap: 6px;
    padding: 4px 0 8px;
}
.horizontal-buttons button {
    flex: 1;
    padding: 9px 0;
    border: 1px solid rgba(255,255,255,0.7);
    border-radius: 8px;
    background: rgba(255,255,255,0.18);
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}
.horizontal-buttons button:hover { border-color: #fff; background: rgba(255,255,255,0.3); }
.horizontal-buttons button.selected {
    background: #fff;
    border-color: #fff;
    color: var(--accent-color);
}
.other-date-field {
    width: 100%;
    padding: 9px 12px;
    border: 1px solid rgba(255,255,255,0.65);
    border-radius: 8px;
    font-size: 13px;
    background: rgba(255,255,255,0.92);
    color: #222;
    margin-bottom: 8px;
}
.other-date-field:focus { border-color: #fff; outline: none; }

/* Newsletter */
.checkbox-news {
    padding: 4px 0;
    margin-bottom: 8px;
}
.checkbox-news label {
    font-size: 12.5px;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}
.checkbox-news input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--accent-color);
    cursor: pointer;
}

/* Accordeon une couleur douce sur l'état actif */
.msg-widget-body .accordion.active { background: rgba(255,255,255,0.28); }

@media (max-width: 480px) {
    .msg-widget { bottom: 16px; right: 0; }
    .msg-widget-toggle { padding: 14px 18px; font-size: 14px; gap: 9px; }
    .msg-widget-panel { width: calc(100vw - 32px); max-height: calc(100vh - 80px); }
}