/* styles.css */
body {
    font-family: Arial, sans-serif;
    background-color: #f0f4f8;
    margin: 0;
    padding: 20px;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background-color: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

h1, h2, h3, h4 {
    color: #2c3e50;
}

h1 {
    text-align: center;
    margin-bottom: 30px;
}

h2 {
    border-bottom: 2px solid #3498db;
    padding-bottom: 5px;
    margin-top: 30px;
}

h3 {
    color: #34495e;
    margin-top: 20px;
}

/* Estilo para la barra de progreso general */
.progress-overview {
    margin-bottom: 30px;
    padding: 20px;
    background-color: #ecf0f1;
    border-radius: 6px;
}

.progress-bar-container {
    width: 100%;
    background-color: #bdc3c7;
    border-radius: 10px;
    overflow: hidden;
    height: 24px;
    margin: 10px 0;
    display: flex; /* Para la barra segmentada */
}

/* Estilo para la barra de progreso general segmentada */
.progress-bar-segment {
    height: 100%;
    transition: width 0.4s ease;
    cursor: pointer;
}

.progress-bar-segment:hover {
    opacity: 0.8;
}

/* Estilo para el formulario de resumen */
.summary-form-section {
    margin-bottom: 30px;
    padding: 20px;
    background-color: #e8f4fd;
    border-radius: 6px;
}

.summary-form-section label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.summary-form-section input[type="text"],
.summary-form-section textarea {
    width: 100%;
    padding: 8px;
    margin-bottom: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box;
}

.summary-form-section input[type="checkbox"] {
    margin-right: 8px;
}

.summary-form-section button {
    background-color: #27ae60;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1em;
}

.summary-form-section button:hover {
    background-color: #219653;
}

/* Estilo para el historial de resúmenes */
.summary-history {
    margin-bottom: 30px;
}

.summary-item {
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 10px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.summary-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    border-bottom: 1px solid #eee;
    padding-bottom: 5px;
}

.summary-user {
    font-weight: bold;
    color: #2980b9;
}

.summary-date {
    color: #7f8c8d;
    font-size: 0.9em;
}

.status-badge {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.9em;
    font-weight: bold;
}

.estado-pendiente { background-color: #f39c12; color: white; }
.estado-en_progreso { background-color: #3498db; color: white; }
.estado-completado { background-color: #2ecc71; color: white; }

/* Estilos para el estado de subido/no subido */
.status-subido { background-color: #2ecc71; color: white; }
.status-no_subido { background-color: #e74c3c; color: white; }

/* Estilo para la leyenda */
.legend {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    margin: 20px 0;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 4px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Estilo para botones de añadir/editar/eliminar tareas */
.btn-add-task, .btn-edit-task, .btn-delete-task {
    padding: 4px 8px;
    margin-left: 8px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8em;
    font-weight: bold;
    color: white;
}

.btn-add-task { background-color: #27ae60; }
.btn-add-task:hover { background-color: #219653; }

.btn-edit-task { background-color: #3498db; }
.btn-edit-task:hover { background-color: #2982bd; }

.btn-delete-task { background-color: #e74c3c; }
.btn-delete-task:hover { background-color: #c0392b; }

/* Estilo original para módulos y tareas */
.module {
    margin-bottom: 30px;
    padding: 20px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background-color: #fafafa;
    cursor: pointer;
}

.module:hover {
    background-color: #f1f8ff;
}

.module-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.module-title {
    font-size: 1.5em;
    font-weight: bold;
    color: #34495e;
}

.estado-badge {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.9em;
    font-weight: bold;
}

.task-list {
    margin-top: 15px;
    display: none; /* Oculto por defecto */
}

.task-list.visible {
    display: block; /* Visible cuando el módulo está abierto */
}

.task-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    margin: 5px 0;
    background-color: white;
    border: 1px solid #eee;
    border-radius: 4px;
}

.task-title {
    flex-grow: 1;
}

.task-checkbox {
    margin-right: 10px;
}

.task-status {
    font-size: 0.9em;
    padding: 2px 6px;
    border-radius: 4px;
    margin-right: 8px;
}

.status-hecho { background-color: #e8f5e9; color: #2e7d32; }
.status-no_hecho { background-color: #ffebee; color: #c62828; }