/**
 * ClaseTube User Panel - Estilos principales
 * Estilos base minimalistas con diseño moderno
 */

/* ========================================
   VARIABLES DE DISEÑO
   ======================================== */
:root {
    --clt-primary-color: #FF003C;
    --clt-secondary-color: #222;
    --clt-border-color: #212121;
    --clt-bg-light: #f8f9fa;
    --clt-text-primary: #fff;
    --clt-text-secondary: #ccc;
    --clt-border-radius: 16px;
    --clt-box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    --clt-transition: all 0.3s ease;
    --clt-card-bg: rgba(33, 33, 33, 0.6);
}

/* ========================================
   CONTENEDOR PRINCIPAL DEL PANEL
   ======================================== */

.clt-user-panel {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    color: var(--clt-text-primary);
}

/* ========================================
   ENCABEZADO DEL PANEL
   ======================================== */

.clt-panel-header {
    text-align: center;
    margin-bottom: 50px;
}

.clt-panel-title {
    font-size: 36px;
    font-weight: 300;
    margin: 0;
    color: var(--clt-text-primary);
}

.clt-panel-subtitle {
    font-size: 16px;
    color: var(--clt-text-secondary);
    margin: 0;
}

/* ========================================
   CONTENEDOR DE TARJETAS - GRID CENTRADO
   ======================================== */

.clt-panels-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    margin-bottom: 30px;
}

/* Tarjeta que ocupa todo el ancho */
.clt-card-full {
    grid-column: 1 / -1;
}

/* ========================================
   TARJETAS (CARDS)
   ======================================== */

.clt-card {
    background-color: var(--clt-card-bg);
    border: 1px solid var(--clt-border-color);
    border-radius: var(--clt-border-radius);
    padding: 30px;
    box-shadow: var(--clt-box-shadow);
    transition: var(--clt-transition);
    backdrop-filter: blur(10px);
}

.clt-card:hover {
    box-shadow: 0 8px 24px rgba(255, 0, 60, 0.15);
}

.clt-card-title {
    font-size: 20px;
    font-weight: 600;
    margin: 0 0 20px 0;
    color: var(--clt-text-primary);
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.clt-card-content {
    display: flex;
    flex-direction: column;
}

/* ========================================
   INFORMACIÓN DEL EMAIL (INFORMATIVA)
   ======================================== */

.clt-email-info {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 15px;
    background: rgba(255, 0, 60, 0.1);
    border: 1px solid rgba(255, 0, 60, 0.3);
    border-radius: 8px;
    margin-bottom: 20px;
}

.clt-email-icon {
    width: 20px;
    height: 20px;
    color: var(--clt-primary-color);
    flex-shrink: 0;
}

.clt-email-text {
    flex: 1;
    font-size: 14px;
    color: var(--clt-text-primary);
}

/* ========================================
   SECCIÓN DE AVATAR
   ======================================== */

.clt-avatar-display {
    text-align: center;
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 140px;
}

.clt-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 4px solid var(--clt-primary-color);
    object-fit: cover;
    display: block;
    margin: 0 auto;
}

/* Icono de usuario de FontAwesome */
.clt-avatar-icon {
    font-size: 64px;
    color: var(--clt-primary-color);
    line-height: 1;
}

/* Imagen del avatar del usuario */
.clt-avatar-image {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 4px solid var(--clt-primary-color);
    object-fit: cover;
    display: block;
    margin: 0 auto;
}

/* Placeholder cuando no hay avatar */
.clt-avatar-placeholder {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 4px dashed var(--clt-primary-color);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    background: rgba(255, 20, 147, 0.05);
    gap: 8px;
}

.clt-avatar-placeholder i {
    font-size: 32px;
    color: var(--clt-primary-color);
}

.clt-avatar-placeholder span {
    font-size: 12px;
    color: var(--clt-primary-color);
    font-weight: 600;
    text-align: center;
}

/* ========================================
   FORMULARIOS Y CAMPOS
   ======================================== */

.clt-form-group {
    margin-bottom: 18px;
    display: flex;
    flex-direction: column;
}

.clt-form-label {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--clt-text-primary);
    display: block;
}

.clt-form-input {
    padding: 12px 15px;
    border: 1px solid var(--clt-border-color);
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    transition: var(--clt-transition);
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--clt-text-primary);
}

.clt-form-input:focus {
    outline: none;
    border-color: var(--clt-primary-color);
    background-color: rgba(255, 255, 255, 0.08);
}

.clt-form-input[type="file"] {
    padding: 8px 0;
    cursor: pointer;
}

.clt-form-help {
    font-size: 12px;
    color: var(--clt-text-secondary);
    margin-top: 6px;
    display: block;
}

/* Nota sobre recuperación de contraseña */
.clt-password-note {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--clt-border-color);
    text-align: center;
}

.clt-password-note small {
    font-size: 13px;
    color: var(--clt-text-secondary);
}

.clt-password-note a {
    color: var(--clt-primary-color);
    text-decoration: none;
    font-weight: 600;
}

.clt-password-note a:hover {
    text-decoration: underline;
}

/* Campo de nombre actual (solo lectura) */
.clt-current-name-display {
    padding: 12px 16px;
    background: rgba(255, 20, 147, 0.05);
    border: 2px solid var(--clt-primary-color);
    border-radius: 8px;
    font-weight: 600;
    color: var(--clt-primary-color);
    text-align: center;
    font-size: 16px;
    margin-bottom: 10px;
}

/* ========================================
   BOTONES
   ======================================== */

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

.clt-btn {
    padding: 14px 28px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--clt-transition);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: inherit;
    width: 100%;
}

.clt-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 0, 60, 0.4);
}

.clt-btn:active {
    transform: translateY(0);
}

.clt-btn-primary {
    background-color: var(--clt-primary-color);
    color: #fff;
}

.clt-btn-primary:hover {
    background-color: #cc0030;
}

.clt-btn-logout {
    background-color: var(--clt-primary-color);
    color: #fff;
}

.clt-btn-logout:hover {
    background-color: #cc0030;
}

/* ========================================
   INPUT FILE PERSONALIZADO
   ======================================== */

.clt-file-input-wrapper {
    position: relative;
    width: 100%;
}

.clt-file-input-wrapper input[type="file"] {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.clt-file-input-label {
    display: block;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    text-align: center;
    cursor: pointer;
    transition: var(--clt-transition);
    color: var(--clt-text-primary);
    font-size: 14px;
}

.clt-file-input-label:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--clt-primary-color);
}

/* ========================================
   DESCRIPCIONES Y MENSAJES
   ======================================== */

.clt-logout-description {
    color: var(--clt-text-secondary);
    margin: 0 0 20px 0;
    font-size: 14px;
    line-height: 1.6;
}

.clt-message {
    margin-top: 15px;
    padding: 12px 15px;
    border-radius: 8px;
    font-size: 14px;
    display: none;
}

.clt-message.clt-success {
    background-color: rgba(76, 175, 80, 0.2);
    color: #81c784;
    border: 1px solid rgba(76, 175, 80, 0.3);
    display: block;
}

.clt-message.clt-error {
    background-color: rgba(244, 67, 54, 0.2);
    color: #ef5350;
    border: 1px solid rgba(244, 67, 54, 0.3);
    display: block;
}

/* ========================================
   MENSAJE DE NO SESIÓN INICIADA
   ======================================== */

.clt-panel-not-logged-in {
    text-align: center;
    padding: 40px 20px;
    background-color: var(--clt-card-bg);
    border-radius: var(--clt-border-radius);
    color: var(--clt-text-secondary);
    font-size: 16px;
    border: 1px solid var(--clt-border-color);
}

/* ========================================
   MODAL DE CONFIRMACIÓN
   ======================================== */

.clt-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.clt-modal-overlay.active {
    display: flex;
}

.clt-modal {
    background: var(--clt-card-bg);
    border-radius: var(--clt-border-radius);
    border: 1px solid var(--clt-border-color);
    padding: 40px;
    max-width: 400px;
    width: 90%;
    text-align: center;
}

.clt-modal h3 {
    font-size: 24px;
    margin-bottom: 15px;
    color: var(--clt-text-primary);
}

.clt-modal p {
    color: var(--clt-text-secondary);
    margin-bottom: 30px;
    font-size: 14px;
}

.clt-modal-buttons {
    display: flex;
    gap: 15px;
}

.clt-modal-buttons button,
.clt-modal-buttons form {
    flex: 1;
    display: flex;
}

.clt-modal-buttons button {
    padding: 14px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--clt-transition);
}

.clt-modal-buttons form button {
    width: 100%;
    justify-content: center;
}

.clt-modal-btn-yes {
    background: var(--clt-primary-color);
    color: white;
}

.clt-modal-btn-yes:hover {
    background: #cc0030;
    transform: translateY(-2px);
}

.clt-modal-btn-no {
    background: rgba(255, 255, 255, 0.1);
    color: var(--clt-text-primary);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.clt-modal-btn-no:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

/* ========================================
   SHORTCODE UNIFICADO: [clasetube_lesson] - MEJORADO
   ======================================== */

.clt-lesson-progress-unified {
    margin: 30px 0;
    overflow: visible;
}

.clt-unified-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 50px;
    background: rgba(33, 33, 33, 0.6);
    border: 1px solid #212121;
    border-radius: 16px;
    padding: 40px;
    backdrop-filter: blur(10px);
    align-items: center;
    overflow: visible;
}

/* Columna Izquierda - Progreso Circular */
.clt-progress-column {
    display: flex;
    align-items: center;
    gap: 35px;
    width: 100%;
    overflow: visible;
}

.clt-circular-progress {
    width: 150px;
    height: 150px;
    position: relative;
    flex-shrink: 0;
    overflow: visible;
    margin: 10px;
}

.clt-circular-progress svg {
    transform: rotate(-90deg);
    width: 100%;
    height: 100%;
    overflow: visible;
}

.clt-circular-progress circle {
    fill: none;
}

.clt-circle-bg {
    stroke: rgba(255, 255, 255, 0.05);
    stroke-width: 12;
}

.clt-circle-fill {
    stroke: #FF003C;
    stroke-linecap: round;
    stroke-width: 14;
    filter: drop-shadow(0 0 15px rgba(255, 0, 60, 0.8)) drop-shadow(0 0 30px rgba(255, 0, 60, 0.5));
    transition: stroke-dashoffset 0.8s ease;
}

.clt-circular-percentage {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #FF003C;
    font-size: 36px;
    font-weight: 700;
    text-shadow: 0 0 25px rgba(255, 0, 60, 0.6);
    line-height: 1;
}

.clt-progress-details {
    flex: 1;
    min-width: 0;
}

.clt-progress-title {
    color: #fff;
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.clt-progress-stats {
    color: #aaa;
    font-size: 14px;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.clt-stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.clt-stat-item:last-child {
    border-bottom: none;
}

.clt-stat-label {
    color: #999;
    font-size: 14px;
}

.clt-stat-value {
    color: #fff;
    font-weight: 600;
    font-size: 15px;
}

/* Columna Derecha - Botón */
.clt-button-column {
    display: flex;
    align-items: center;
    justify-content: center;
    border-left: 1px solid rgba(255, 255, 255, 0.1);
    padding-left: 40px;
    overflow: visible;
    height: 100%;
}

/* Botón Neón */
.clt-btn-neon {
    background: rgba(255, 0, 60, 0.1);
    color: #FF003C;
    border: 2px solid #FF003C;
    padding: 16px 40px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 0 15px rgba(255, 0, 60, 0.3);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    white-space: nowrap;
    min-width: 200px;
}

.clt-btn-neon:hover {
    background: #FF003C;
    color: #fff;
    box-shadow: 0 0 30px rgba(255, 0, 60, 0.8), 0 0 60px rgba(255, 0, 60, 0.4);
    transform: scale(1.05);
}

.clt-btn-neon:active {
    transform: scale(0.98);
}

.clt-btn-neon.completed {
    background: #FF003C;
    color: #fff;
    border-color: #FF003C;
    box-shadow: 0 0 20px rgba(255, 0, 60, 0.6);
}

.clt-btn-neon.completed:hover {
    background: #cc0030;
    border-color: #cc0030;
    box-shadow: 0 0 30px rgba(204, 0, 48, 0.8);
}

.clt-btn-neon i {
    font-size: 18px;
}

.clt-btn-text {
    display: inline;
}

.clt-button-message {
    margin-top: 10px;
    padding: 12px;
    border-radius: 8px;
    font-size: 13px;
    animation: slideDown 0.3s ease;
    text-align: center;
    max-width: 100%;
}

.clt-button-message.success {
    background: rgba(34, 197, 94, 0.2);
    border: 1px solid rgba(34, 197, 94, 0.5);
    color: #22c55e;
}

.clt-button-message.error {
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.5);
    color: #ef4444;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   RESPONSIVE
   ======================================== */

/* Tablet/Mobile - 1024px y menos */
@media (max-width: 1024px) {
    .clt-unified-layout {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 30px;
    }

    .clt-button-column {
        border-left: none;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        padding-left: 0;
        padding-top: 30px;
    }

    .clt-progress-column {
        justify-content: center;
    }

    .clt-btn-neon {
        width: 100%;
    }
}

/* Mobile - 768px y menos */
@media (max-width: 768px) {
    .clt-user-panel {
        padding: 30px 15px;
    }

    .clt-panel-title {
        font-size: 28px;
    }

    .clt-panels-container {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .clt-card {
        padding: 20px;
    }

    .clt-btn {
        width: 100%;
        justify-content: center;
    }

    /* Unified shortcode mobile adjustments */
    .clt-unified-layout {
        padding: 25px;
    }

    .clt-progress-column {
        flex-direction: column;
        text-align: center;
        gap: 25px;
    }

    .clt-circular-progress {
        width: 130px;
        height: 130px;
        margin: 8px;
    }

    .clt-circular-percentage {
        font-size: 32px;
    }

    .clt-progress-title {
        font-size: 18px;
    }

    .clt-stat-item {
        padding: 10px 0;
    }

    .clt-stat-label,
    .clt-stat-value {
        font-size: 13px;
    }

    .clt-btn-neon {
        padding: 14px 30px;
        font-size: 14px;
    }

    .clt-form-actions {
        flex-direction: column;
    }

    .clt-modal-buttons {
        flex-direction: column;
    }

    .clt-modal-buttons button {
        width: 100%;
    }

    .clt-modal-buttons form {
        width: 100%;
    }

    .clt-modal-buttons form button {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .clt-user-panel {
        padding: 20px 10px;
    }

    .clt-panel-title {
        font-size: 22px;
    }

    .clt-card-title {
        font-size: 18px;
    }

    .clt-avatar {
        width: 100px;
        height: 100px;
    }

    /* Unified shortcode - extra small screens */
    .clt-unified-layout {
        padding: 20px;
        gap: 20px;
    }

    .clt-progress-column {
        gap: 20px;
    }

    .clt-circular-progress {
        width: 110px;
        height: 110px;
    }

    .clt-circular-percentage {
        font-size: 28px;
    }

    .clt-progress-title {
        font-size: 16px;
        margin-bottom: 15px;
    }

    .clt-stat-item {
        padding: 8px 0;
    }

    .clt-stat-label,
    .clt-stat-value {
        font-size: 12px;
    }

    .clt-btn-neon {
        width: 100%;
        padding: 12px 25px;
        font-size: 13px;
    }
}

/* ========================================
   SEGUIMIENTO DE PROGRESO DE LECCIONES
   ======================================== */

/* Contenedor para marcar lección */
.clt-mark-lesson-container {
    margin: 20px 0;
    display: inline-block;
}

/* Botón para marcar lección como completada */
.clt-mark-lesson-btn {
    display: inline-flex !important;
    align-items: center;
    gap: 10px;
    padding: 12px 24px !important;
    background-color: #1a1a1a !important;
    border: 2px solid #333 !important;
    border-radius: 8px;
    color: #888 !important;
    font-size: 14px !important;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-decoration: none !important;
}

.clt-mark-lesson-btn:hover {
    background-color: #252525 !important;
    color: #fff !important;
    border-color: #444 !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.clt-mark-lesson-btn.completed {
    background-color: rgba(255, 0, 60, 0.15) !important;
    color: #FF003C !important;
    border-color: rgba(255, 0, 60, 0.3) !important;
}

.clt-mark-lesson-btn.completed:hover {
    background-color: rgba(255, 0, 60, 0.25) !important;
    color: #fff !important;
    border-color: rgba(255, 0, 60, 0.5) !important;
}

.clt-mark-lesson-btn.loading {
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
}

.clt-mark-lesson-btn i {
    font-size: 16px;
    display: inline-block;
}

.clt-mark-lesson-text {
    display: inline;
}

/* Mensaje de estado */
.clt-mark-lesson-message {
    margin-top: 10px;
    padding: 12px;
    border-radius: 8px;
    font-size: 13px;
    animation: slideDown 0.3s ease;
}

.clt-mark-lesson-message.success {
    background-color: rgba(76, 175, 80, 0.15);
    color: #4caf50;
    border-left: 3px solid #4caf50;
}

.clt-mark-lesson-message.error {
    background-color: rgba(244, 67, 54, 0.15);
    color: #f44336;
    border-left: 3px solid #f44336;
}

/* ========================================
   CARD FLOTANTE DE PROGRESO PARA SIDEBAR
   ======================================== */

/* Contenedor principal del sidebar */
.ct-sidebar-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Card flotante de progreso */
.ct-progress-floating-card {
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 8px;
    padding: 15px;
    transition: all 0.3s ease;
}

.ct-progress-floating-card:hover {
    border-color: #FF003C;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 0, 60, 0.15);
}

/* Header del progreso en card flotante */
.ct-progress-floating-card .ct-progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.ct-progress-label {
    font-size: 0.8rem;
    color: #888;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.ct-progress-percentage {
    font-size: 0.8rem;
    color: #FF003C;
    font-weight: 600;
}

/* Barra de progreso en card flotante */
.ct-progress-floating-card .ct-progress-bar-wrapper {
    height: 6px;
    background: #2a2a2a;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 8px;
}

.ct-progress-floating-card .ct-progress-bar-fill {
    height: 100%;
    background: #FF003C;
    border-radius: 10px;
    transition: width 0.5s ease;
}

/* Estadísticas del progreso en card flotante */
.ct-progress-floating-card .ct-progress-stats {
    font-size: 0.75rem;
    color: #666;
    text-align: center;
}

/* Responsive para card flotante */
@media (max-width: 768px) {
    .ct-sidebar-container {
        gap: 12px;
    }
    
    .ct-progress-floating-card {
        padding: 12px;
    }
    
    .ct-progress-label,
    .ct-progress-percentage {
        font-size: 0.75rem;
    }
    
    .ct-progress-floating-card .ct-progress-stats {
        font-size: 0.7rem;
    }
}

/* ========================================
   BARRA DE PROGRESO MINIMALISTA
   ======================================== */

.ct-progress-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 25px 0;
    padding: 16px 20px;
    background: rgba(15, 15, 15, 0.8);
    border-radius: 12px;
    border: 1px solid #2a2a2a;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.ct-progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
}

.ct-progress-title {
    font-size: 1.2rem !important;
    color: #666;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.ct-progress-stats {
    font-size: 1.2rem !important;
    color: #FF003C;
    font-weight: 600;
    white-space: nowrap;
}

.ct-progress-bar-wrapper {
    height: 8px;
    background: #1a1a1a;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid #2a2a2a;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}

.ct-progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #FF003C 0%, #ff4d6d 100%);
    border-radius: 10px;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 0 10px rgba(255, 0, 60, 0.5);
    position: relative;
}

.ct-progress-bar-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100%;
    background: linear-gradient(90deg, 
        rgba(255, 255, 255, 0.3) 0%, 
        rgba(255, 255, 255, 0.1) 50%, 
        rgba(255, 255, 255, 0.3) 100%);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* Responsive */
@media (max-width: 768px) {
    .ct-progress-container {
        padding: 12px 16px;
        gap: 10px;
    }
    
    .ct-progress-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
    
    .ct-progress-title,
    .ct-progress-stats {
        font-size: 0.75rem;
    }
    
    .ct-progress-bar-wrapper {
        height: 6px;
    }
}

/* ========================================
   VERSIONES ANTIGUAS DE PROGRESO (MANTENER POR COMPATIBILIDAD)
   ======================================== */

/* Contenedor de progreso del curso */
.clt-course-progress-container {
    background-color: var(--clt-card-bg);
    border: 1px solid var(--clt-border-color);
    border-radius: var(--clt-border-radius);
    padding: 30px;
    margin: 20px 0;
    backdrop-filter: blur(10px);
}

/* Encabezado de progreso */
.clt-progress-header {
    margin-bottom: 20px;
}

.clt-progress-title {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 15px 0;
    color: var(--clt-text-primary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Estadísticas de progreso */
.clt-progress-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 15px;
    background-color: rgba(255, 0, 60, 0.05);
    border-radius: 8px;
}

.clt-progress-text {
    flex: 1;
}

.clt-progress-lesson-count {
    font-size: 14px;
    color: var(--clt-text-primary);
    font-weight: 500;
}

.clt-progress-percentage {
    text-align: right;
}

.clt-progress-percent-number {
    font-size: 24px;
    font-weight: 700;
    color: var(--clt-primary-color);
}

/* Barra de progreso */
.clt-progress-bar-container {
    margin: 25px 0;
}

.clt-progress-bar {
    width: 100%;
    height: 12px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid var(--clt-border-color);
}

.clt-progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--clt-primary-color), #ff4d6d);
    border-radius: 10px;
    transition: width 0.5s ease;
    box-shadow: 0 0 10px rgba(255, 0, 60, 0.5);
}

/* Mensaje de completitud */
.clt-progress-completed-message {
    background-color: rgba(76, 175, 80, 0.15);
    border: 1px solid rgba(76, 175, 80, 0.3);
    border-radius: 8px;
    padding: 15px;
    color: #4caf50;
    text-align: center;
    font-weight: 600;
    margin-top: 20px;
    animation: slideUp 0.5s ease;
}

.clt-progress-completed-message i {
    margin-right: 8px;
    font-size: 18px;
}

/* Animaciones */
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   INDICADORES EN ÍNDICE DE LECCIONES
   ======================================== */

/* Checkmark para lecciones completadas en el índice */
.lesson-item-compact .clt-lesson-completion-indicator {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    margin-left: 8px;
    color: var(--clt-primary-color);
    font-size: 12px;
    font-weight: 700;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lesson-item-compact.completed .clt-lesson-completion-indicator {
    opacity: 1;
}

/* Responsive para indicadores */
@media (max-width: 768px) {
    .clt-mark-lesson-btn {
        padding: 10px 16px;
        font-size: 12px;
        width: 100%;
        justify-content: center;
    }

    .clt-progress-stats {
        flex-direction: column;
        gap: 15px;
    }

    .clt-progress-percentage {
        text-align: left;
    }

    .clt-course-progress-container {
        padding: 20px;
    }
}

/* ========================================
   VERSIÓN 3 - FLAT CON NÚMERO INTEGRADO
   (v1.4.0 - Shortcode [clasetube_course_progress])
   ======================================== */

/* Botón Marcar Lección - Full Width */
.clt-mark-lesson-container {
    width: 100%;
}

.clt-mark-lesson-btn {
    width: 100% !important;
    padding: 12px 20px !important;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.clt-mark-lesson-container {
    width: 100%;
}
.clt-course-progress-container {
    background: transparent;
    padding: 20px;
    margin: 20px 0;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
}

/* Header */
.clt-progress-header-v3 {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    flex-wrap: wrap;
    gap: 10px;
}

.clt-progress-title-v3 {
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.clt-progress-stats-v3 {
    color: #999;
    font-size: 14px;
}

.clt-progress-lesson-count-v3 {
    display: inline-block;
}

/* Barra de Progreso Flat - Versión 3 */
.clt-progress-bar-wrapper-v3 {
    height: 40px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    margin-bottom: 15px;
}

.clt-progress-bar-fill-v3 {
    height: 100%;
    background: #FF003C;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 15px;
    transition: width 1s ease;
    position: relative;
    min-width: 40px;
}

/* Número de porcentaje integrado */
.clt-progress-percentage-v3 {
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    white-space: nowrap;
}

/* Mensaje de finalización */
.clt-progress-completed-message-v3 {
    background: rgba(76, 175, 80, 0.1);
    border: 1px solid rgba(76, 175, 80, 0.3);
    color: #4CAF50;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    margin-top: 15px;
}

.clt-progress-completed-message-v3 i {
    margin-right: 8px;
}

/* Responsive - Versión 3 */
@media (max-width: 768px) {
    .clt-progress-header-v3 {
        flex-direction: column;
        align-items: flex-start;
        margin-bottom: 12px;
    }

    .clt-progress-title-v3 {
        font-size: 14px;
    }

    .clt-progress-stats-v3 {
        font-size: 13px;
    }

    .clt-progress-bar-wrapper-v3 {
        height: 35px;
        margin-bottom: 12px;
    }

    .clt-progress-percentage-v3 {
        font-size: 16px;
    }

    .clt-progress-completed-message-v3 {
        font-size: 12px;
        padding: 10px 12px;
    }

    .clt-course-progress-container {
        padding: 16px;
    }
}

@media (max-width: 480px) {
    .clt-progress-bar-wrapper-v3 {
        height: 32px;
    }

    .clt-progress-bar-fill-v3 {
        padding-right: 12px;
    }

    .clt-progress-percentage-v3 {
        font-size: 14px;
    }

    .clt-progress-title-v3 {
        font-size: 13px;
    }
}

/* ========================================
   WATCH LATER - Estilos Mínimos
   ======================================== */

/**
 * Botón "Ver más tarde"
 * Estilo idéntico al botón Completada (.clt-btn-neon)
 */
.clasetube-watch-later-button-wrapper {
    display: inline-block;
    margin: 10px 0;
}

/* Botón Ver Más Tarde - Estilo idéntico al botón Completada */
.clasetube-wl-btn {
    background: rgba(255, 0, 60, 0.1);
    color: #FF003C;
    border: 2px solid #FF003C;
    padding: 16px 40px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 0 15px rgba(255, 0, 60, 0.3);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    white-space: nowrap;
    min-width: 200px;
}

.clasetube-wl-btn:hover {
    background: #FF003C;
    color: #fff;
    box-shadow: 0 0 30px rgba(255, 0, 60, 0.8), 0 0 60px rgba(255, 0, 60, 0.4);
    transform: scale(1.05);
}

.clasetube-wl-btn:active {
    transform: scale(0.98);
}

.clasetube-wl-btn.saved {
    background: #FF003C;
    color: #fff;
    border-color: #FF003C;
    box-shadow: 0 0 20px rgba(255, 0, 60, 0.6);
}

.clasetube-wl-btn.saved:hover {
    background: #cc0030;
    border-color: #cc0030;
    box-shadow: 0 0 30px rgba(204, 0, 48, 0.8);
}

.clasetube-wl-btn i {
    font-size: 18px;
}

.wl-btn-text {
    display: inline;
}

/**
 * Lista "Ver más tarde"
 * Estilos funcionales mínimos - personalizar con Bricks
 */
.clasetube-watch-later-wrapper {
    display: block;
    width: 100%;
}

.watch-later-item {
    display: block;
    margin-bottom: 15px;
}

.watch-later-lesson-title {
    display: block;
    margin: 0 0 8px 0;
    padding: 0;
}

.watch-later-link {
    display: inline;
    text-decoration: none;
    color: inherit;
}

.watch-later-link:hover {
    text-decoration: underline;
}

.watch-later-course-name {
    display: block;
    margin: 0 0 4px 0;
    padding: 0;
}

.watch-later-duration {
    display: block;
    margin: 0 0 8px 0;
    padding: 0;
}

.watch-later-remove-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    border: none;
    background: none;
    padding: 0;
    font-family: inherit;
    font-size: inherit;
    color: inherit;
}

.watch-later-remove-btn:focus {
    outline: none;
}

.watch-later-remove-btn i {
    display: inline-block;
}

.watch-later-empty-message {
    display: block;
    text-align: center;
    padding: 20px;
}

.watch-later-empty-message p {
    margin: 0;
}

/* ========================================
   CERTIFICADOS
   ======================================== */

.clasetube-certificate-wrapper {
    display: inline-block;
    margin: 10px 0;
}

/* Botón de certificado disponible (curso completo, listo para generar) */
.clasetube-certificate-wrapper .clt-btn-neon:not(.disabled):not(.generated):not(.loading),
.clasetube-certificate-wrapper .clt-btn-neon.cert-link-available {
    background: #FF003C;
    color: #fff;
    border-color: #FF003C;
    box-shadow: 0 0 20px rgba(255, 0, 60, 0.6);
    text-decoration: none;
}

.clasetube-certificate-wrapper .clt-btn-neon:not(.disabled):not(.generated):not(.loading):hover,
.clasetube-certificate-wrapper .clt-btn-neon.cert-link-available:hover {
    background: #cc0030;
    border-color: #cc0030;
    box-shadow: 0 0 30px rgba(204, 0, 48, 0.8);
}

/* Botón deshabilitado (curso incompleto) */
.clasetube-certificate-wrapper .clt-btn-neon.disabled {
    background: rgba(255, 255, 255, 0.05);
    color: #666;
    border-color: #333;
    box-shadow: none;
    cursor: not-allowed;
    opacity: 0.6;
}

/* Estado generado (certificado descargable) - Aplica color sólido */
.clasetube-certificate-wrapper .clt-btn-neon.generated {
    background: #FF003C;
    color: #fff;
    box-shadow: 0 0 20px rgba(255, 0, 60, 0.6);
}

.clasetube-certificate-wrapper .clt-btn-neon.generated:hover {
    background: #cc0030;
    box-shadow: 0 0 30px rgba(204, 0, 48, 0.8);
}

/* Estado loading (generando certificado) */
.clasetube-certificate-wrapper .clt-btn-neon.loading {
    background: #FF003C;
    color: #fff;
    box-shadow: 0 0 20px rgba(255, 0, 60, 0.6);
    cursor: wait;
    opacity: 0.8;
}

/* Texto helper (curso incompleto) */
.cert-helper-text {
    display: block;
    font-size: 12px;
    color: #999;
    margin-top: 8px;
    text-align: center;
    font-style: italic;
}

/* Texto de fecha (certificado generado) */
.cert-date-text {
    display: block;
    font-size: 12px;
    color: #999;
    margin-top: 8px;
    text-align: center;
}

/* Error state */
.cert-error-message {
    display: block;
    color: #ff6b6b;
    font-size: 13px;
    margin-top: 8px;
    text-align: center;
}

/* Success message */
.cert-success-message {
    display: block;
    color: #51cf66;
    font-size: 13px;
    margin-top: 8px;
    text-align: center;
}

/* ========================================
   MENSAJE DE RECARGA PARA CERTIFICADO
   ======================================== */

.clt-certificate-reload-message {
    background: linear-gradient(135deg, #FF003C 0%, #cc0030 100%);
    color: white;
    padding: 15px 20px;
    border-radius: 12px;
    margin-top: 20px;
    text-align: center;
    font-size: 15px;
    line-height: 1.5;
    box-shadow: 0 4px 15px rgba(255, 0, 60, 0.3);
    animation: slideInDown 0.5s ease-out;
}

.clt-certificate-reload-message i {
    margin-right: 8px;
    font-size: 18px;
    animation: pulse 2s ease-in-out infinite;
}

.clt-certificate-reload-message strong {
    font-weight: bold;
    text-decoration: underline;
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* ========================================
   MODAL DE COMPLETACIÓN DE CURSO (LEGACY - puede eliminarse)
   ======================================== */

.clt-completion-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.clt-completion-modal.active {
    opacity: 1;
    visibility: visible;
}

.clt-completion-modal-content {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    border: 2px solid var(--clt-primary-color);
    border-radius: 20px;
    padding: 40px;
    max-width: 500px;
    width: 90%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(255, 0, 60, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.clt-completion-modal.active .clt-completion-modal-content {
    transform: scale(1);
}

.clt-completion-icon {
    font-size: 80px;
    margin-bottom: 20px;
    animation: celebration 1s ease-in-out infinite alternate;
}

@keyframes celebration {
    0% { transform: scale(1) rotate(0deg); }
    100% { transform: scale(1.1) rotate(5deg); }
}

.clt-completion-title {
    font-size: 32px;
    font-weight: bold;
    color: var(--clt-primary-color);
    margin: 0 0 20px 0;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.clt-completion-message {
    font-size: 16px;
    line-height: 1.6;
    color: var(--clt-text-secondary);
    margin-bottom: 30px;
}

.clt-completion-message strong {
    color: var(--clt-text-primary);
    display: block;
    margin-top: 15px;
    font-size: 18px;
}

.clt-completion-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.clt-btn-reload {
    background: linear-gradient(135deg, var(--clt-primary-color) 0%, #cc0030 100%);
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: 16px;
    font-weight: bold;
    border-radius: 12px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 0, 60, 0.4);
}

.clt-btn-reload:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 0, 60, 0.6);
}

.clt-btn-reload i {
    font-size: 18px;
}

.clt-btn-close-modal {
    background: transparent;
    color: var(--clt-text-secondary);
    border: 2px solid var(--clt-border-color);
    padding: 15px 30px;
    font-size: 16px;
    font-weight: bold;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.clt-btn-close-modal:hover {
    border-color: var(--clt-primary-color);
    color: var(--clt-text-primary);
}

/* ============================================
   PÁGINA MIS CERTIFICADOS
   ============================================ */

.clasetube-certificates-page {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

.certificates-header {
    text-align: center;
    margin-bottom: 50px;
    padding-bottom: 30px;
    border-bottom: 2px solid rgba(255, 0, 60, 0.2);
}

.certificates-header h2 {
    font-size: 42px;
    color: #FF003C;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.certificates-header .user-name {
    font-size: 18px;
    color: #888;
}

/* Sin certificados */
.no-certificates {
    text-align: center;
    padding: 80px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px dashed rgba(255, 0, 60, 0.3);
    border-radius: 12px;
}

.no-certificates i {
    font-size: 80px;
    color: rgba(255, 0, 60, 0.3);
    margin-bottom: 20px;
}

.no-certificates p {
    font-size: 18px;
    color: #888;
    margin: 10px 0;
}

.no-certificates .helper-text {
    font-size: 14px;
    color: #666;
}

.not-logged-in-message {
    text-align: center;
    padding: 40px;
    font-size: 18px;
    color: #888;
    background: rgba(255, 0, 60, 0.1);
    border-radius: 8px;
}

/* Grid de certificados */
.certificates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 30px;
    margin-bottom: 50px;
}

@media (max-width: 768px) {
    .certificates-grid {
        grid-template-columns: 1fr;
    }
}

/* Tarjeta de certificado */
.certificate-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 0, 60, 0.3);
    border-radius: 12px;
    padding: 30px;
    transition: all 0.3s ease;
    display: flex;
    gap: 20px;
    backdrop-filter: blur(10px);
}

.certificate-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(255, 0, 60, 0.3);
    border-color: #FF003C;
}

.certificate-icon {
    flex-shrink: 0;
}

.certificate-icon i {
    font-size: 60px;
    color: #FF003C;
    opacity: 0.8;
}

.certificate-info {
    flex: 1;
}

.certificate-info .course-name {
    font-size: 22px;
    color: #fff;
    margin-bottom: 20px;
    font-weight: bold;
}

.certificate-meta {
    margin-bottom: 25px;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    font-size: 14px;
    color: #888;
}

.meta-item i {
    color: #FF003C;
    width: 16px;
}

.certificate-actions {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.download-cert-btn,
.generate-cert-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: bold;
    text-decoration: none;
}

.generate-cert-btn {
    background: #FF003C;
    color: #fff;
    border: 2px solid #FF003C;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 0 20px rgba(255, 0, 60, 0.4);
}

.generate-cert-btn:hover {
    background: #cc0030;
    border-color: #cc0030;
    box-shadow: 0 0 30px rgba(204, 0, 48, 0.6);
    transform: translateY(-2px);
}

.generate-cert-btn:disabled,
.generate-cert-btn.loading {
    opacity: 0.7;
    cursor: wait;
}

.clt-btn-regenerate {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    font-size: 13px;
    font-weight: bold;
    background: rgba(255, 255, 255, 0.05);
    color: #888;
    border: 2px solid #444;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.clt-btn-regenerate:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-color: #666;
}

.clt-btn-regenerate:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.cert-message-container {
    margin-top: 15px;
}

.cert-success-message {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 15px;
    background: rgba(40, 167, 69, 0.2);
    border: 1px solid rgba(40, 167, 69, 0.5);
    border-radius: 6px;
    color: #28a745;
    font-size: 13px;
}

.cert-error-message {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 15px;
    background: rgba(220, 53, 69, 0.2);
    border: 1px solid rgba(220, 53, 69, 0.5);
    border-radius: 6px;
    color: #dc3545;
    font-size: 13px;
}

.view-course-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: #888;
    font-size: 14px;
    text-decoration: none;
    transition: color 0.3s ease;
}

.view-course-link:hover {
    color: #FF003C;
}

.view-course-link i {
    font-size: 12px;
}

/* Footer */
.certificates-footer {
    text-align: center;
    padding: 30px;
    background: rgba(255, 0, 60, 0.05);
    border-radius: 8px;
}

.certificates-footer .total-count {
    font-size: 18px;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.certificates-footer .total-count i {
    color: #FF003C;
    font-size: 24px;
}

.certificates-footer .total-count strong {
    color: #FF003C;
    font-size: 24px;
}

/* ========================================
   BOTONES CONTINUAR Y RECOMENDADA - WRAPPER
   ======================================== */

.clasetube-buttons-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 20px 0;
}

@media (max-width: 768px) {
    .clasetube-buttons-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}

/* ========================================
   TRES CARDS (CONTINUAR + RECOMENDADA + TEST)
   ======================================== */

.clasetube-three-cards-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin: 30px 0;
}

@media (max-width: 1024px) {
    .clasetube-three-cards-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}
