/* Calendar Tareas Simple - CSS */

.ctareas-container {
    max-width: 100%;
    padding: 20px;
    font-family: Arial, sans-serif;
}

.ctareas-header {
    margin-bottom: 20px;
}

.ctareas-header h2 {
    margin: 0 0 15px 0;
    color: #333;
}

.ctareas-controls {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

#search-input {
    flex: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    min-width: 200px;
}

.btn {
    padding: 10px 15px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    white-space: nowrap;
}

.btn-green {
    background: #4CAF50;
    color: white;
}

.btn-green:hover {
    background: #45a049;
}

.btn-blue {
    background: #2196F3;
    color: white;
}

.btn-blue:hover {
    background: #0b7dda;
}

.btn-red {
    background: #f44336;
    color: white;
}

.btn-red:hover {
    background: #da190b;
}

.btn-sm {
    padding: 5px 10px;
    font-size: 14px;
}

.ctareas-toolbar {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
}

#current-month {
    font-size: 18px;
    font-weight: bold;
    min-width: 150px;
    text-align: center;
}

/* Calendario */
.ctareas-calendar {
    background: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}

.calendar-header {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    background: #f5f5f5;
}

.calendar-header div {
    padding: 10px;
    text-align: center;
    font-weight: bold;
    border-right: 1px solid #ddd;
}

.calendar-header div:last-child {
    border-right: none;
}

.calendar-body {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
}

.calendar-day {
    min-height: 100px;
    border: 1px solid #ddd;
    padding: 10px;
    background: white;
    cursor: pointer;
    transition: background 0.2s;
}

.calendar-day:hover {
    background: #f9f9f9;
}

.calendar-day-header {
    font-weight: bold;
    color: #666;
    margin-bottom: 5px;
}

.calendar-day.other-month .calendar-day-header {
    color: #ccc;
}

.calendar-day.today {
    background: #ffffcc;
}

.day-task {
    background: #4CAF50;
    color: white;
    padding: 5px;
    margin: 5px 0;
    border-radius: 3px;
    font-size: 12px;
    cursor: pointer;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.day-task:hover {
    background: #45a049;
}

/* Modal */
.modal {
    position: fixed;
    z-index: 999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: white;
    padding: 30px;
    border-radius: 8px;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.close {
    position: absolute;
    right: 15px;
    top: 10px;
    font-size: 28px;
    cursor: pointer;
    color: #666;
}

.close:hover {
    color: #333;
}

.modal-content h3 {
    margin-top: 0;
    color: #333;
    border-bottom: 2px solid #4CAF50;
    padding-bottom: 10px;
}

#modal-message {
    display: none;
    padding: 10px;
    margin-bottom: 15px;
    border-radius: 4px;
    font-weight: bold;
    text-align: center;
}

#modal-message.success {
    background: #d4edda;
    color: #155724;
}

#modal-message.error {
    background: #f8d7da;
    color: #721c24;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #333;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: Arial, sans-serif;
    font-size: 14px;
    box-sizing: border-box;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #4CAF50;
    box-shadow: 0 0 5px rgba(76, 175, 80, 0.3);
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.form-actions button {
    flex: 1;
}

/* Responsive */
@media (max-width: 768px) {
    .ctareas-controls {
        flex-direction: column;
    }

    #search-input,
    .btn {
        width: 100%;
    }

    .calendar-day {
        min-height: 80px;
        font-size: 12px;
    }

    .day-task {
        font-size: 11px;
        padding: 3px;
    }
}
