/**
 * Styles pour la sidebar de réservation
 * 
 * Ce fichier contient tous les styles pour la sidebar qui s'ouvre
 * lorsqu'on clique sur une réservation dans le calendrier.
 */

/* Conteneur principal de la sidebar */
.awayout-reservation-sidebar {
    position: fixed;
    top: 48%; /* Position légèrement plus haute pour compenser */
    right: -520px; /* Commence hors de l'écran */
    transform: translateY(-50%); /* Centre verticalement */
    width: 480px;
    height: 95vh; /* Hauteur réduite pour un meilleur centrage */
    background-color: #f9f9fb;
    box-shadow: -5px 0 20px rgba(0, 0, 0, 0.08);
    z-index: 9999;
    transition: right 0.3s ease-in-out;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    font-family: 'Roboto', sans-serif;
    border-radius: 20px;
    margin: 20px;
}

/* Sidebar ouverte */
.awayout-reservation-sidebar.open {
    right: 0;
    box-shadow: -5px 0 25px rgba(0, 0, 0, 0.2);
    z-index: 10000;
}

/* En-tête de la sidebar */
.awayout-reservation-sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #f0f0f0;
    background-color: #fff;
    position: sticky;
    top: 0;
    z-index: 2;
    border-radius: 20px 20px 0 0;
}

.awayout-reservation-sidebar-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 0;
    letter-spacing: 0.2px;
}

.awayout-reservation-sidebar-close {
    background: none;
    border: none;
    font-size: 20px;
    color: #999;
    cursor: pointer;
    transition: color 0.2s;
    padding: 0;
    margin: 0;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.awayout-reservation-sidebar-close:hover {
    color: #F97C5A;
}

/* Corps de la sidebar */
.awayout-reservation-sidebar-body {
    padding: 20px 24px 0 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow-y: auto;
    background-color: #fafafa;
}

/* Informations de séjour */
.reservation-sejour {
    font-size: 14px;
    color: #767676;
    margin-bottom: 15px;
}

/* Nom du client */
.reservation-client {
    font-size: 18px;
    font-weight: 500;
    margin-bottom: 15px;
}

/* Actions client */
.reservation-client-actions {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

.reservation-client-action {
    font-size: 14px;
    color: #F97C5A;
    text-decoration: none;
}

.reservation-client-action:hover {
    text-decoration: underline;
}

/* Photo du client */
.reservation-client-photo {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    overflow: hidden;
    position: absolute;
    right: 20px;
    top: 70px;
}

.reservation-client-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Détails de la réservation */
.reservation-details {
    margin-top: 20px;
}

.reservation-detail-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
}

.reservation-detail-label {
    font-size: 14px;
    color: #484848;
}

.reservation-detail-value {
    font-size: 14px;
    color: #484848;
    font-weight: 500;
    text-align: right;
}

/* Montant total */
.reservation-montant {
    margin-top: 20px;
    margin-bottom: 20px;
}

.reservation-montant-label {
    font-size: 14px;
    color: #484848;
    margin-bottom: 5px;
}

.reservation-montant-value {
    font-size: 18px;
    font-weight: 500;
    color: #484848;
}

/* Note personnelle */
.reservation-note {
    margin-top: 20px;
}

.reservation-note-label {
    font-size: 14px;
    color: #484848;
    margin-bottom: 5px;
}

.reservation-note-content {
    font-size: 14px;
    color: #767676;
    margin-bottom: 10px;
}

.reservation-note-info {
    font-size: 12px;
    color: #767676;
    font-style: italic;
}

.reservation-note-textarea {
    width: 100%;
    min-height: 80px;
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 10px;
    margin-top: 10px;
    resize: vertical;
    font-family: inherit;
    font-size: 14px;
}

/* Conteneur pour le bouton d'action */
.reservation-action-container {
    position: relative;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 15px 20px;
    background-color: white;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    margin-top: 20px;
}

/* Bouton d'action */
.reservation-action-button {
    display: block;
    width: 100%;
    padding: 12px 0;
    background-color: #6c7ae0;
    color: white;
    text-align: center;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.reservation-action-button:hover {
    background-color: #5a68d4;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Statut de la réservation */
.awayout-reservation-status {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 20px;
}

.awayout-reservation-status.confirmed {
    background-color: #a8e6cf;
    color: #2d8a68;
}

.awayout-reservation-status.pending {
    background-color: #f39c12;
    color: white;
}

.awayout-reservation-status.cancelled {
    background-color: #e74c3c;
    color: white;
}

.awayout-reservation-status.external {
    background-color: #3498db;
    color: white;
}

/* Sections d'information */
.awayout-reservation-section {
    margin-bottom: 20px;
    background-color: #fff;
    border-radius: 8px;
    padding: 16px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.awayout-reservation-section-title {
    font-size: 14px;
    font-weight: 500;
    color: #555;
    margin-bottom: 12px;
    padding-bottom: 0;
    letter-spacing: 0.2px;
}

/* Propriété */
.awayout-reservation-property {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    background-color: #f9f9fb;
    border-radius: 8px;
    padding: 12px;
}

.awayout-reservation-property-image {
    width: 50px;
    height: 50px;
    border-radius: 6px;
    background-size: cover;
    background-position: center;
    margin-right: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.awayout-reservation-property-info {
    flex: 1;
}

.awayout-reservation-property-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin-bottom: 5px;
}

.awayout-reservation-property-address {
    font-size: 14px;
    color: #666;
}

/* Informations client */
.awayout-reservation-client {
    margin-bottom: 16px;
    background-color: transparent;
    border-radius: 0;
    padding: 0;
}

.awayout-reservation-client-info {
    display: flex;
    align-items: flex-start;
}

/* Photo de profil du client */
.awayout-reservation-client-avatar {
    width: 50px;
    height: 50px;
    margin-right: 15px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    border: 1px solid #f0f0f0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.awayout-reservation-client-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Détails du client */
.awayout-reservation-client-details {
    flex-grow: 1;
}

.awayout-reservation-client-row {
    display: flex;
    align-items: center;
    margin-bottom: 6px;
    padding-bottom: 6px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.awayout-reservation-client-label {
    width: 70px;
    font-size: 12px;
    color: #999;
    font-weight: 400;
}

.awayout-reservation-client-value {
    font-size: 13px;
    color: #333;
    font-weight: 400;
    flex-grow: 1;
}

/* Détails de la réservation */
.awayout-reservation-details {
    display: flex;
    flex-direction: column;
    gap: 6px;
    background-color: transparent;
    border-radius: 0;
    padding: 0;
}

.awayout-reservation-details-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 6px;
    margin-bottom: 6px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.awayout-reservation-details-label {
    font-size: 12px;
    color: #999;
    font-weight: 400;
}

.awayout-reservation-details-value {
    font-size: 13px;
    color: #333;
    font-weight: 400;
    text-align: right;
}

/* Prix total */
.awayout-reservation-total {
    font-size: 14px;
    font-weight: 500;
    color: #333;
    margin-top: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.awayout-reservation-total-price {
    color: #6c7ae0;
    font-size: 15px;
    font-weight: 600;
}

/* Notes */
.awayout-reservation-notes {
    background-color: #f8f9fa;
    border-radius: 6px;
    padding: 12px;
    font-size: 12px;
    color: #777;
    margin-top: 8px;
    line-height: 1.4;
}

/* Actions */
.awayout-reservation-actions {
    display: flex;
    gap: 12px;
    margin-top: 20px;
    position: sticky;
    bottom: 0;
}

.awayout-reservation-btn {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.awayout-reservation-btn-primary {
    background-color: #6c7ae0;
    color: white;
}

.awayout-reservation-btn-primary:hover {
    background-color: #5a68d4;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.awayout-reservation-btn-secondary {
    background-color: #f0f2f5;
    color: #555;
}

.awayout-reservation-btn-secondary:hover {
    background-color: #e5e8ed;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
}

.awayout-reservation-btn-danger {
    background-color: #ff7a8a;
    color: white;
}

.awayout-reservation-btn-danger:hover {
    background-color: #ff6478;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Conteneur d'action */
.reservation-action-container {
    margin-top: 16px;
    padding: 12px;
    background-color: #fff;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

/* Overlay */
.awayout-reservation-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.awayout-reservation-overlay.open {
    opacity: 1;
    visibility: visible;
    z-index: 9999;
}

/* Responsive */
@media (max-width: 768px) {
    .awayout-reservation-sidebar {
        width: 100%;
        right: -100%;
    }
    
    .awayout-reservation-property {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .awayout-reservation-property-image {
        width: 100%;
        height: 120px;
        margin-right: 0;
        margin-bottom: 15px;
    }
    
    .awayout-reservation-actions {
        flex-direction: column;
    }
}
