/* Estilos Generales */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

body {
    background-color: #f0f2f5;
    color: #333;
    line-height: 1.6;
}

/* Contenedor Principal */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Título */
h2 {
    text-align: center;
    margin-bottom: 20px;
    color: #333;
}

/* Estilos para mensajes de retroalimentación */
.feedback {
    width: 100%;
    max-width: 500px;
    margin: 20px auto;
    padding: 12px;
    border-radius: 8px;
    text-align: center;
    font-weight: bold;
    color: white;
}

.feedback.success {
    background-color: #28a745;
}

.feedback.error {
    background-color: #dc3545;
}

/* Estilos del Formulario */
form {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 500px;
    margin: 20px auto;
    padding: 20px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

label {
    font-weight: bold;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="file"],
button {
    padding: 10px;
    font-size: 1rem;
    border-radius: 5px;
    border: 1px solid #ccc;
    width: 100%;
    box-sizing: border-box;
}

button {
    background-color: #007bff;
    color: white;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

button:hover {
    background-color: #0056b3;
}

/* Ajustes para video-list y video-item en pantallas pequeñas */
.video-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    justify-content: center;
}

.video-item {
    width: 100%;
    max-width: 100%;
    background: white;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    text-align: center;
    padding: 10px;
}

.video-item video {
    width: 100%;
    height: auto;
    border-bottom: 1px solid #ddd;
}

.video-item button {
    width: 100%;
    margin-top: 10px;
    padding: 10px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.video-item button:hover {
    background-color: #0056b3;
}

/* Responsividad */
@media (max-width: 768px) {
    .video-list {
        padding: 10px;
    }

    .container {
        padding: 10px;
    }
}

/* Navbar */
.navbar {
    display: flex;
    justify-content: center;
    background-color: #007bff;
    padding: 10px;
    margin-bottom: 20px;
}

.navbar a {
    color: white;
    padding: 10px 15px;
    text-decoration: none;
    font-weight: bold;
}

.navbar a:hover {
    background-color: #0056b3;
    border-radius: 5px;
}

/* Estilos para la tabla de progreso */
.progress-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background-color: #ffffff;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    overflow: hidden;
}

.progress-table thead {
    background-color: #007bff;
    color: #ffffff;
}

.progress-table th, .progress-table td {
    padding: 12px;
    text-align: left;
}

.progress-table tbody tr:nth-child(even) {
    background-color: #f2f2f2;
}

.progress-table tbody tr:hover {
    background-color: #ddd;
}

/* Responsividad para móviles */
@media (max-width: 768px) {
    .video-list {
        flex-direction: column;
        align-items: center;
    }

    .container {
        padding: 10px;
    }

    .progress-table, .progress-table thead, .progress-table tbody, .progress-table th, .progress-table td, .progress-table tr {
        display: block;
        width: 100%;
    }

    .progress-table th {
        display: none;
    }

    .progress-table td {
        padding: 10px;
        position: relative;
    }

    .progress-table td::before {
        content: attr(data-label);
        font-weight: bold;
        width: 100%;
        display: block;
        margin-bottom: 5px;
        color: #007bff;
    }
}

/* Estilos para la línea de tiempo */
.timeline {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 20px;
}

.timeline-item {
    background-color: #ffffff;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s;
}

.timeline-item:hover {
    transform: translateY(-5px);
}

.timeline-item h3 {
    font-size: 1.2em;
    margin-bottom: 5px;
    color: #333;
}

.timeline-item .status {
    color: #007bff;
    font-weight: normal;
    font-size: 0.9em;
}

.timeline-item p {
    color: #555;
    font-size: 0.9em;
}

/* Responsividad para Timeline */
@media (max-width: 768px) {
    .timeline-item h3 {
        font-size: 1em;
    }
    .timeline-item p {
        font-size: 0.85em;
    }
}

/* Estilos para la descripción */
.description {
    text-align: center;
    font-size: 1rem;
    color: #555;
    margin-top: 10px;
    margin-bottom: 20px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

/* Estilos específicos para index.php */
.index-container {
    max-width: 400px;
    margin: 0 auto;
    text-align: center;
    padding: 20px;
    background-color: #f9f9f9;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.index-container h1 {
    color: #333;
    font-size: 1.8em;
    margin-bottom: 10px;
}

.index-intro-text {
    font-size: 1.1em;
    color: #666;
    margin-bottom: 20px;
}

.index-button-group {
    display: flex;
    justify-content: space-around;
}

.index-button {
    display: inline-block;
    padding: 10px 20px;
    font-size: 1em;
    color: white;
    background-color: #007bff;
    border-radius: 5px;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

.index-button:hover {
    background-color: #0056b3;
}

/* Estilo para el texto de bienvenida en la sección de administración */
.welcome-text {
    text-align: center;
    font-size: 1.1em;
    color: #333;
    margin-bottom: 20px;
}

/* Estilo de botones para opciones de administración */
.admin-button {
    display: inline-block;
    padding: 10px 20px;
    margin: 5px;
    font-size: 1em;
    color: white;
    background-color: #007bff;
    border-radius: 5px;
    text-decoration: none;
    transition: background-color 0.3s ease;
    text-align: center;
}

.admin-button:hover {
    background-color: #0056b3;
}

.section-title {
    font-weight: bold;
    font-size: 1.2em;
    color: #333;
    margin-top: 20px;
    margin-bottom: 10px;
}

.admin-container {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
}

.admin-section {
    margin-bottom: 20px;
}

.admin-button {
    display: inline-block;
    padding: 10px 20px;
    font-size: 1em;
    color: white;
    background-color: #007bff;
    border-radius: 5px;
    text-decoration: none;
    transition: background-color 0.3s ease;
    text-align: center;
    width: 200px;
}

.admin-button:hover {
    background-color: #0056b3;
}

.mode-status {
    text-align: center;
    color: #666;
    margin-bottom: 20px;
    font-size: 1em;
}

/* Estilos para el formulario de configuración inicial */
.config-container {
    max-width: 600px;
    margin: 20px auto;
    padding: 20px;
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.config-container h2 {
    text-align: center;
    color: #333;
    margin-bottom: 20px;
}

.config-container label {
    display: block;
    font-weight: bold;
    margin-top: 10px;
    color: #333;
}

.config-container input[type="text"],
.config-container input[type="password"],
.config-container input[type="email"],
.config-container input[type="number"],
.config-container select {
    width: 100%;
    padding: 10px;
    margin-top: 5px;
    border-radius: 5px;
    border: 1px solid #ccc;
}

.config-container button {
    width: 100%;
    padding: 12px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: bold;
    margin-top: 20px;
}

.config-container button:hover {
    background-color: #0056b3;
}

/* Ajuste de contenedor para pantallas pequeñas */
@media (max-width: 768px) {
    .container {
        width: 90%;
        padding: 10px;
        margin: 0 auto;
    }
}

@media (max-width: 768px) {
    h2, h3 {
        font-size: 1.4em;
        text-align: center;
    }

    .admin-button, .feedback, button {
        font-size: 1em;
        padding: 10px 15px;
        width: 100%;
    }
}

@media (max-width: 768px) {
    .video-item video {
        width: 100%;
        height: auto;
    }
    
    form {
        width: 100%;
    }
}

@media (max-width: 768px) {
    .navbar {
        flex-direction: column;
    }

    .navbar a {
        padding: 8px;
        font-size: 1em;
    }
}

/* Estilos Generales del Navbar */
.navbar {
    background-color: #007bff;
    padding: 10px;
    color: white;
}
.navbar-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.navbar-logo {
    font-size: 1.5em;
    color: white;
    text-decoration: none;
}
.navbar-links a {
    color: white;
    padding: 10px 15px;
    text-decoration: none;
    font-weight: bold;
}

/* Botón toggle para dispositivos móviles */
.navbar-toggle {
    display: none;
    font-size: 1.5em;
    background: none;
    color: white;
    border: none;
    cursor: pointer;
}

/* Estilos del Navbar en Pantallas Pequeñas */
@media (max-width: 768px) {
    .navbar-container {
        flex-direction: column;
    }
    .navbar-toggle {
        display: block;
    }
    .navbar-links {
        display: none;
        flex-direction: column;
        width: 100%;
    }
    .navbar-links.active {
        display: flex;
    }
    .navbar-links a {
        padding: 15px;
        text-align: center;
        width: 100%;
        border-top: 1px solid #ccc;
    }
}


/* Spinner de carga */
.spinner {
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-top: 4px solid #007bff;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    margin: 10px auto;
    display: none; /* Oculto por defecto */
}

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

/* Estilo para mensajes de éxito */
.message-success {
    color: #155724;
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    padding: 10px;
    border-radius: 5px;
    margin: 10px 0;
    font-weight: bold;
    text-align: center;
}

/* Estilo para mensajes de error */
.message-error {
    color: #721c24;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    padding: 10px;
    border-radius: 5px;
    margin: 10px 0;
    font-weight: bold;
    text-align: center;
}


 /* Estilos adicionales para dispositivos móviles */
            .video-list {
                display: flex;
                flex-direction: column;
                gap: 20px;
            }
            .video-item {
                width: 100%;
                max-width: 500px;
                margin: 0 auto;
                padding: 15px;
                background: white;
                border-radius: 8px;
                box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
                text-align: center;
            }
            video {
                width: 100%;
                border-radius: 8px;
                margin-bottom: 10px;
            }
            button {
                width: 100%;
                padding: 10px;
                margin-top: 10px;
                background-color: #007bff;
                color: white;
                border: none;
                border-radius: 5px;
                cursor: pointer;
            }
            button:hover {
                background-color: #0056b3;
            }