/* Termin Buchung Plugin Styles */

/* Button */
.tb-button {
    background-color: #0073aa;
    color: #ffffff;
    border: none;
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.tb-button:hover {
    background-color: #005a87;
}

.tb-button:active {
    background-color: #004368;
}

/* SweetAlert2 Container Anpassungen */
.swal2-container {
    z-index: 999999;
}

.swal2-popup {
    width: 90% !important;
    max-width: 900px;
    padding: 20px;
}

/* Standort Container */
.tb-standort-container {
    margin-bottom: 30px;
}

.tb-standort-container:last-child {
    margin-bottom: 0;
}

/* Standort Header */
.tb-standort-header {
    background-color: #f8f9fa;
    padding: 15px 20px;
    border-left: 4px solid #0073aa;
    margin-bottom: 15px;
    border-radius: 4px;
}

.tb-standort-title {
    font-size: 20px;
    font-weight: 700;
    color: #333;
    margin: 0 0 8px 0;
}

.tb-standort-address {
    font-size: 14px;
    color: #666;
    margin: 0;
    line-height: 1.5;
}

/* Termine Grid */
.tb-termine-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

/* Termin Card */
.tb-termin-card {
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    background-color: #ffffff;
    position: relative;
}

.tb-termin-card:hover:not(.disabled) {
    border-color: #0073aa;
    box-shadow: 0 4px 8px rgba(0, 115, 170, 0.15);
    transform: translateY(-2px);
}

.tb-termin-card.selected {
    border-color: #0073aa;
    background-color: #f0f8ff;
    box-shadow: 0 4px 12px rgba(0, 115, 170, 0.25);
}

.tb-termin-card.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background-color: #f5f5f5;
}

.tb-termin-card.gebucht {
    border-color: #28a745;
    border-width: 3px;
    background-color: #f0fff4;
}

/* Checkbox Container */
.tb-checkbox-container {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

/* Custom Checkbox */
.tb-checkbox {
    width: 24px;
    height: 24px;
    border: 2px solid #ccc;
    border-radius: 50%;
    flex-shrink: 0;
    position: relative;
    transition: all 0.3s ease;
    margin-top: 2px;
}

.tb-termin-card.selected .tb-checkbox {
    border-color: #0073aa;
    background-color: #0073aa;
}

.tb-termin-card.selected .tb-checkbox::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 16px;
    font-weight: bold;
}

.tb-termin-card.disabled .tb-checkbox {
    border-color: #d0d0d0;
    background-color: #f0f0f0;
}

.tb-termin-card.gebucht .tb-checkbox {
    border-color: #28a745;
    background-color: #28a745;
}

/* Termin Content */
.tb-termin-content {
    flex: 1;
}

.tb-termin-datum {
    font-size: 16px;
    font-weight: 700;
    color: #333;
    margin: 0 0 8px 0;
}

.tb-termin-uhrzeit {
    font-size: 14px;
    color: #666;
    margin: 0 0 8px 0;
}

.tb-termin-teilnehmer {
    font-size: 14px;
    color: #555;
    margin: 0;
    font-weight: 500;
}

.tb-termin-teilnehmer.ausgebucht {
    color: #dc3545;
    font-weight: 700;
}

/* Badge für gebuchten Termin */
.tb-gebucht-badge {
    display: inline-block;
    background-color: #28a745;
    color: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    margin-top: 8px;
}

/* Button Container */
.tb-button-container {
    margin-top: 25px;
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
}

/* Buchungs-Button */
.tb-book-button {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 14px 32px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.tb-book-button:hover:not(:disabled) {
    background-color: #218838;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    transform: translateY(-1px);
}

.tb-book-button:disabled {
    background-color: #cccccc;
    color: #666666;
    cursor: not-allowed;
    opacity: 0.6;
    box-shadow: none;
}

/* Info Text */
.tb-info-text {
    font-size: 13px;
    color: #666;
    margin-top: 15px;
    font-style: italic;
    text-align: center;
}

.tb-warning-text {
    color: #dc3545;
    font-weight: 600;
}

/* Bereits gebucht Hinweis */
.tb-bereits-gebucht {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 20px;
    text-align: center;
}

.tb-bereits-gebucht h3 {
    color: #155724;
    margin: 0 0 8px 0;
    font-size: 18px;
}

.tb-bereits-gebucht p {
    color: #155724;
    margin: 0;
    font-size: 14px;
}

/* Loading State */
.tb-loading {
    text-align: center;
    padding: 40px 20px;
}

.tb-spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #0073aa;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: tb-spin 1s linear infinite;
    margin: 0 auto 15px;
}

@keyframes tb-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive */
@media (max-width: 768px) {
    .swal2-popup {
        width: 95%;
        padding: 15px;
    }
    
    .tb-termine-grid {
        grid-template-columns: 1fr;
    }
    
    .tb-standort-title {
        font-size: 18px;
    }
    
    .tb-book-button {
        width: 100%;
    }
}

/* Zusätzliche SweetAlert2 Anpassungen */
.swal2-html-container {
    max-height: 70vh;
    overflow-y: auto;
    text-align: center;
}

.swal2-confirm {
    background-color: #0073aa !important;
}

.swal2-cancel {
    background-color: #6c757d !important;
}