:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --bg: #1e293b;
    --surface: #ffffff;
    --text: #111827;
    --text-light: #6b7280;
    --border: #e5e7eb;
    --success: #10b981;
    --dark-blue: #1e3a8a;
}

* { box-sizing: border-box; margin: 0; padding: 0; font-family: system-ui, -apple-system, sans-serif; }
body { background-color: var(--bg); color: var(--text); padding-bottom: 2rem; min-height: 100vh; }

.container { width: 100%; max-width: 600px; margin: 0 auto; padding: 1rem; }
.hidden { display: none !important; }

/* === LOADING SCREEN === */
.loading-screen {
    position: fixed; inset: 0; background: var(--bg);
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    color: white; gap: 1rem; z-index: 9999;
}
.loading-spinner {
    width: 40px; height: 40px; border: 4px solid rgba(255,255,255,0.2);
    border-top-color: var(--primary); border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* === ALERTAS DE FORMULARIO (errores/mensajes) === */
.form-alert {
    font-size: 0.85rem; padding: 0.6rem 1rem; border-radius: 8px;
    text-align: center; display: none;
}
.form-alert.show { display: block; }
.form-alert.error { background: #fee2e2; color: #b91c1c; }
.form-alert.success { background: #dcfce7; color: #15803d; }

/* === BOTONES DESHABILITADOS (mientras cargan) === */
.btn:disabled { opacity: 0.6; cursor: not-allowed; }

/* === SPLIT AUTH === */
.split-auth-card { display: flex; flex-direction: column; background: var(--surface); border-radius: 20px; overflow: hidden; min-height: 550px; box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.3); margin-top: 2rem; width: 100%; }
.auth-left { flex: 1; padding: 2.5rem 2rem; display: flex; flex-direction: column; align-items: center; background: #ffffff; }
.auth-logo { width: 100%; font-weight: 800; font-size: 1.1rem; color: var(--text); margin-bottom: 2rem; }
.auth-avatar { width: 70px; height: 70px; background: var(--dark-blue); border-radius: 50%; display: flex; align-items: center; justify-content: center; color: white; margin-bottom: 2rem; }
.auth-avatar svg { width: 35px; height: 35px; }
.auth-form { width: 100%; max-width: 300px; display: flex; flex-direction: column; gap: 1rem; }
.input-pill { display: flex; align-items: center; border: 2px solid var(--border); border-radius: 50px; padding: 0.5rem 1rem; background: #fff; }
.input-pill span { margin-right: 0.5rem; font-size: 1.1rem; }
.input-pill input { border: none; outline: none; width: 100%; font-size: 0.85rem; font-weight: 600; color: var(--text); background: transparent; }
.btn-pill { border-radius: 50px !important; margin-top: 0.5rem; }
.btn-dark { background: var(--dark-blue); color: white; }
.auth-right { flex: 1.2; padding: 2.5rem; display: flex; flex-direction: column; justify-content: space-between; background: linear-gradient(135deg, #e5e7ee 0%, #60a5fa 40%, #0f40c5 100%); color: white; text-align: right; }
.hero-content { display: flex; flex-direction: column; justify-content: flex-end; flex-grow: 1; text-align: right; }
.hero-content h2 { font-size: 3rem; font-weight: 900; margin-bottom: 1rem; }

/* === RECUPERAR CONTRASEÑA (tarjeta simple centrada) === */
.simple-auth-card {
    background: var(--surface);
    border-radius: 20px;
    padding: 2.5rem 2rem;
    margin-top: 2rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.simple-auth-card h2 { font-size: 1.4rem; color: var(--text); margin-bottom: 0.5rem; }
.simple-auth-card .subtitle-light { color: var(--text-light); font-size: 0.9rem; margin-bottom: 1.5rem; max-width: 320px; line-height: 1.5; }
.simple-auth-card .auth-form { max-width: 320px; }
.hero-switch-dark { margin-top: 1.5rem; font-size: 0.9rem; color: var(--text-light); }
.hero-switch-dark a { color: var(--primary); font-weight: 700; text-decoration: none; }

/* === APP GENERIC === */
.app-header { background: var(--primary); color: white; padding: 1rem; display: flex; justify-content: space-between; align-items: center; }
.app-header .logo { font-weight: 800; font-size: 1.05rem; cursor: pointer; letter-spacing: 0.01em; }
.nav-right { display: flex; align-items: center; gap: 0.9rem; }
.wallet { font-weight: 700; font-size: 1rem; background: rgba(255, 255, 255, 0.15); padding: 0.35rem 0.8rem; border-radius: 50px; }
.btn-logout {
    background: rgba(255, 255, 255, 0.12);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.35);
    padding: 0.4rem 0.9rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease;
}
.btn-logout:hover { background: rgba(255, 255, 255, 0.25); border-color: rgba(255, 255, 255, 0.6); }
.btn-logout:active { background: rgba(255, 255, 255, 0.35); }

.btn { width: 100%; padding: 0.9rem; border-radius: 8px; font-weight: bold; cursor: pointer; border: none; font-size: 1rem; text-align: center; }
.btn-primary { background: var(--primary); color: white; }
.card { background: var(--surface); padding: 1.25rem; border-radius: 10px; border: 1px solid var(--border); margin-top: 1rem; }
.section-header { display: flex; align-items: center; gap: 1rem; margin-bottom: 1rem; color: white;}
.section-header h2 { font-size: 1.3rem; line-height: 1.3; }
.btn-back { background: none; border: none; color: #60a5fa; font-size: 1rem; cursor: pointer; font-weight: bold; white-space: nowrap; flex-shrink: 0; }

/* === HUB PRINCIPAL === */
.welcome-banner { padding: 2rem 0.25rem 1.5rem; color: white; }
.welcome-banner h2 { font-size: 1.8rem; font-weight: 800; margin-bottom: 0.35rem; }
.welcome-banner p { color: #94a3b8; font-size: 1rem; }

.hub-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.hub-card {
    background: var(--surface);
    border-radius: 14px;
    padding: 1.5rem 1.25rem;
    cursor: pointer;
    border: 1px solid var(--border);
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.hub-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 20px -8px rgba(37, 99, 235, 0.35);
    border-color: var(--primary);
}

.hub-card:active { transform: translateY(-1px); }

.hub-icon {
    font-size: 2rem;
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #eff6ff;
    border-radius: 12px;
    margin-bottom: 0.25rem;
}

.hub-card h3 { font-size: 1.05rem; color: var(--text); }
.hub-card p { font-size: 0.85rem; color: var(--text-light); line-height: 1.4; }

/* === PERFIL ESTILO RED SOCIAL === */
.profile-header { background: #fff; border-radius: 12px; overflow: hidden; margin-bottom: 24px; box-shadow: 0 4px 6px rgba(0,0,0,0.05); }
.cover-photo { height: 180px; background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%); background-size: cover; background-position: center; position: relative; }
.btn-edit-cover { position: absolute; bottom: 10px; right: 15px; background: rgba(0, 0, 0, 0.6); color: white; padding: 6px 12px; border-radius: 6px; font-size: 0.8rem; cursor: pointer; }
.profile-avatar-container { position: relative; margin-top: -60px; margin-left: 20px; display: flex; align-items: flex-end; width: fit-content; }
.profile-avatar { width: 120px; height: 120px; background: #f1f5f9; border: 4px solid #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 2.5rem; font-weight: bold; color: #475569; box-shadow: 0 4px 6px rgba(0,0,0,0.1); background-size: cover; background-position: center; }
.btn-edit-avatar { background: #e2e8f0; border: 2px solid #fff; border-radius: 50%; width: 35px; height: 35px; display: flex; align-items: center; justify-content: center; cursor: pointer; margin-left: -30px; margin-bottom: 5px; box-shadow: 0 2px 4px rgba(0,0,0,0.1); z-index: 2; }
.profile-main-info { padding: 10px 20px 20px 20px; }
.profile-links { display: flex; gap: 10px; margin-top: 15px; flex-wrap: wrap; }
.input-icon-wrapper { display: flex; align-items: center; background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 6px; padding: 0 10px; }
.input-icon-wrapper input { border: none; background: transparent; padding: 8px; outline: none; }
.dashboard-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.skills-container { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 15px; }

/* === BOTONES EXTRA === */
.btn-outline { background: transparent; color: var(--primary); border: 2px solid var(--primary); }
.btn-outline:hover { background: #eff6ff; }
.btn-sm { width: auto; padding: 0.55rem 1rem; font-size: 0.85rem; }

/* === ALERTAS DE ESTADO === */
.alert { padding: 1rem; border-radius: 8px; margin-top: 1rem; font-size: 0.9rem; line-height: 1.5; }
.alert-info { background: #eff6ff; color: #1e40af; border: 1px solid #bfdbfe; }
.alert-success { background: #ecfdf5; color: #047857; border: 1px solid #a7f3d0; font-weight: 600; }

/* === BARRA DE PROGRESO === */
.progress-bar { width: 100%; height: 10px; background: #e2e8f0; border-radius: 50px; overflow: hidden; margin-top: 0.6rem; }
.progress { height: 100%; background: var(--primary); border-radius: 50px; transition: width 0.4s ease; }

/* === CURSOS === */
.course-node h3 { margin: 0.5rem 0 0.25rem; font-size: 1.05rem; }
.course-meta { color: var(--text-light); font-size: 0.8rem; margin-bottom: 0.5rem; }
.course-node .btn { margin-top: 1rem; }
.badge { display: inline-block; font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em; padding: 4px 10px; border-radius: 50px; }
.badge-tech { background: #ede9fe; color: #6d28d9; }
.badge-support { background: #dbeafe; color: #1d4ed8; }
.badge-success { background: #dcfce7; color: #047857; }

/* === TAREAS === */
.subtitle { color: #94a3b8; font-size: 0.9rem; margin-bottom: 1rem; }
.task-card { margin-top: 0; }
.task-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.5rem; }
.task-payout { background: #ecfdf5; color: #047857; font-weight: 700; padding: 4px 10px; border-radius: 50px; font-size: 0.85rem; }
.task-category { color: var(--text-light); font-size: 0.8rem; font-weight: 600; text-transform: uppercase; }
.task-card h3 { margin-bottom: 0.5rem; }
.task-instruction { color: var(--text-light); font-size: 0.9rem; margin-bottom: 0.75rem; }
.task-workground { background: #f8fafc; border: 1px solid var(--border); border-radius: 8px; padding: 0.85rem; margin-bottom: 1rem; font-size: 0.9rem; display: flex; flex-direction: column; gap: 0.5rem; }
.task-actions { display: flex; flex-direction: column; gap: 0.6rem; }
.task-actions label { font-size: 0.9rem; display: flex; align-items: center; gap: 0.5rem; cursor: pointer; }
.task-actions .btn { margin-top: 0.5rem; }

/* === PROGRESO DE TAREAS (15 preguntas) === */
.task-progress-row { margin-bottom: 1rem; }
.task-progress-row span { font-size: 0.85rem; font-weight: 600; color: var(--text-light); }
.task-progress-row .progress-bar { margin-top: 0.4rem; }

.task-complete-card { text-align: center; padding: 2rem 1.5rem; }
.task-complete-card h3 { font-size: 1.2rem; margin-bottom: 0.25rem; }
.task-complete-card .btn { margin-top: 1.25rem; width: auto; padding: 0.8rem 1.5rem; }

/* === TRACCIÓN / HARDWARE === */
.traction-card h3 { margin-bottom: 0.4rem; }
.traction-status { margin-top: 1rem; }
#traction-text { font-size: 0.9rem; font-weight: 600; color: var(--text-light); }

/* === DASHBOARD: ESTADÍSTICAS === */
.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.75rem; margin-top: 1rem; }
.stat-box { text-align: center; background: #f8fafc; border-radius: 10px; padding: 0.85rem 0.5rem; }
.stat-number { display: block; font-size: 1.4rem; font-weight: 800; color: var(--primary); }
.stat-label { font-size: 0.75rem; color: var(--text-light); text-transform: uppercase; letter-spacing: 0.03em; }

/* === FORMULARIOS DE DATOS (billetera, etc.) === */
.data-form { display: flex; flex-direction: column; gap: 0.6rem; margin-top: 0.75rem; }
.data-form label { font-size: 0.85rem; font-weight: 600; color: var(--text-light); margin-top: 0.4rem; }
.data-form input, .select-light {
    padding: 0.7rem 0.9rem; border: 1px solid var(--border); border-radius: 8px;
    font-size: 0.9rem; background: #f8fafc; color: var(--text);
}
.data-form input:focus, .select-light:focus, .input-light:focus { outline: 2px solid var(--primary); outline-offset: 1px; }
.input-light { background: transparent; }
.data-form .btn { margin-top: 0.75rem; }

/* === HISTORIAL DE INGRESOS === */
.history-list { display: flex; flex-direction: column; gap: 0.6rem; margin-top: 0.75rem; }
.history-item { display: flex; justify-content: space-between; align-items: center; padding: 0.75rem; background: #f8fafc; border-radius: 8px; }
.history-details { display: flex; flex-direction: column; }
.history-title { font-size: 0.9rem; font-weight: 600; }
.history-date { font-size: 0.75rem; color: var(--text-light); }
.history-amount { font-weight: 700; font-size: 0.95rem; }
.history-amount.positive { color: var(--success); }

/* === CATÁLOGO DE CURSOS === */
.search-pill { margin-bottom: 1rem; }
.search-pill input { color: var(--text); font-weight: 500; text-transform: none; }

.course-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.course-card-item { margin-top: 0; display: flex; flex-direction: column; }
.course-card-image {
    height: 90px;
    border-radius: 8px;
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    display: flex; align-items: center; justify-content: center;
    font-size: 2rem; margin-bottom: 0.75rem;
}
.course-card-item h3 { font-size: 1rem; margin: 0.5rem 0 0.25rem; }
.course-card-item .course-card-desc { font-size: 0.85rem; color: var(--text-light); margin-bottom: 1rem; flex-grow: 1; }
.course-card-item .btn { margin-top: auto; }
.course-card-item.disabled { opacity: 0.6; }
.course-card-item.disabled .course-card-image { background: #f1f5f9; }

/* === DETALLES DEL CURSO === */
#course-detail-title { margin-bottom: 0.75rem; }
.course-detail-box { background: #f8fafc; border-left: 4px solid var(--primary); border-radius: 8px; padding: 0.85rem 1rem; }
.course-detail-intro { font-weight: 600; margin-bottom: 0.5rem; }
#course-detail-desc { font-size: 0.9rem; color: var(--text-light); }

.lista-modulos { list-style: none; display: flex; flex-direction: column; gap: 0.5rem; margin-top: 0.75rem; }
.lista-modulos li { padding: 0.7rem 0.9rem; background: #f8fafc; border: 1px solid var(--border); border-radius: 8px; font-size: 0.9rem; transition: 0.2s; }
.lista-modulos li:hover { background: #eff6ff; border-color: var(--primary); }

/* Mini editor de código */
.code-preview-card { padding: 0; overflow: hidden; }
.code-window { background: #1e1e2f; }
.code-window-bar { display: flex; justify-content: space-between; align-items: center; padding: 0.6rem 1rem; background: #2c2c3e; color: #ccc; font-size: 0.75rem; }
.window-controls { display: flex; gap: 6px; }
.window-controls .dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.dot-red { background: #ff5f56; } .dot-yellow { background: #ffbd2e; } .dot-green { background: #27c93f; }
.code-window-body { padding: 1rem; color: #d4d4d4; font-size: 0.78rem; line-height: 1.6; font-family: 'Fira Code', monospace; overflow-x: auto; white-space: pre; margin: 0; }
.code-tag { color: #569cd6; }
.code-string { color: #ce9178; }

/* Razones para elegir el curso */
.razones-lista { list-style: none; display: flex; flex-direction: column; gap: 0.6rem; }
.razones-lista li {
    padding: 0.85rem 1rem; background: #f8fafc; border: 1px solid var(--border);
    border-left: 4px solid var(--primary); border-radius: 8px; cursor: pointer;
    display: flex; flex-direction: column; transition: 0.2s;
}
.razones-lista li:hover { background: #eff6ff; }
.razones-lista .razon-header { display: flex; align-items: center; gap: 0.85rem; font-weight: 600; font-size: 0.9rem; }
.razones-lista .razon-desc {
    font-size: 0.82rem; color: var(--text-light); margin-top: 0; max-height: 0; overflow: hidden;
    transition: max-height 0.25s ease, margin-top 0.25s ease; line-height: 1.5;
}
.razones-lista li.expanded .razon-desc { max-height: 100px; margin-top: 0.6rem; }

/* === HORARIO === */
.form-group { margin-bottom: 1rem; }
.form-group:last-child { margin-bottom: 0; }
.form-group label { display: block; font-size: 0.85rem; font-weight: 600; color: var(--text-light); margin-bottom: 0.4rem; }
.schedule-select { width: 100%; }
.schedule-table-card h3 { font-size: 0.95rem; margin-bottom: 0.75rem; }
.schedule-table-wrapper { overflow-x: auto; }
.schedule-table { width: 100%; border-collapse: collapse; font-size: 0.8rem; min-width: 480px; }
.schedule-table th { background: #f8fafc; color: var(--text-light); padding: 0.6rem 0.4rem; font-size: 0.7rem; text-transform: uppercase; border: 1px solid var(--border); }
.schedule-table td { padding: 0.6rem 0.4rem; border: 1px solid var(--border); text-align: center; transition: background 0.2s; }
.schedule-table tr.fila-hora { cursor: pointer; }
.schedule-table tr.fila-hora:hover td { background: #eff6ff; }
.schedule-table tr.fila-hora.seleccionada td:first-child { background: #dbeafe; font-weight: 600; }
.schedule-table td.dia-marcado { background: var(--primary) !important; color: white; font-weight: 700; }

/* === CONFIRMACIÓN DE INSCRIPCIÓN === */
.confirmation-card { text-align: center; max-width: 420px; margin: 2rem auto 0; padding: 2rem 1.5rem; }
.confirmation-icon {
    width: 64px; height: 64px; border-radius: 50%; background: #dcfce7; color: var(--success);
    font-size: 2rem; font-weight: 800; display: flex; align-items: center; justify-content: center;
    margin: 0 auto 1rem;
}
.confirmation-card h2 { font-size: 1.3rem; }
.confirmation-info { background: #f8fafc; border: 1px solid var(--border); border-radius: 10px; padding: 1rem; margin: 1.25rem 0; text-align: left; }
.confirmation-info-item { display: flex; align-items: flex-start; gap: 0.75rem; font-size: 0.85rem; color: var(--text-light); margin-bottom: 0.75rem; }
.confirmation-info-item:last-child { margin-bottom: 0; }
.confirmation-info-item .icono { font-size: 1.2rem; }

/* ============================================================
   MI APRENDIZAJE
   ============================================================ */
.learning-tabs { display: flex; gap: 0.4rem; margin-bottom: 1rem; }
.learning-tab {
    flex: 1; min-width: 0; padding: 0.6rem 0.4rem; border-radius: 10px;
    border: 1px solid var(--border); background: var(--surface); color: var(--text-light);
    font-weight: 600; font-size: 0.75rem; cursor: pointer; transition: 0.2s; text-align: center; line-height: 1.3;
}
.learning-tab.active { background: var(--primary); color: white; border-color: var(--primary); }
.learning-tab-panel.hidden { display: none; }

/* Tarjeta de horario */
.schedule-item-card { display: flex; gap: 1rem; align-items: center; }
.schedule-item-icon {
    width: 48px; height: 48px; border-radius: 10px; background: #eff6ff; color: var(--primary);
    display: flex; align-items: center; justify-content: center; font-size: 1.4rem; flex-shrink: 0;
}
.schedule-item-info h3 { font-size: 1rem; margin-bottom: 0.3rem; }
.schedule-item-info p { font-size: 0.85rem; color: var(--text-light); margin: 0; }
.schedule-item-info p + p { margin-top: 0.15rem; }

/* Tarjeta de curso inscrito */
.enrolled-course-card { display: flex; flex-direction: column; gap: 0.6rem; }
.enrolled-course-card .top-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 0.5rem; }
.enrolled-course-card h3 { font-size: 1rem; }
.enrolled-course-card .progress-bar { margin-top: 0.4rem; }
.enrolled-course-card .progress-label { font-size: 0.8rem; color: var(--text-light); margin-top: 0.3rem; }

/* Tarjeta de calificación */
.grade-item-card { display: flex; justify-content: space-between; align-items: center; gap: 0.75rem; }
.grade-item-info h3 { font-size: 0.95rem; margin-bottom: 0.2rem; }
.grade-item-info p { font-size: 0.8rem; color: var(--text-light); margin: 0; }
.grade-status { padding: 4px 10px; border-radius: 50px; font-size: 0.75rem; font-weight: 700; white-space: nowrap; text-align: center; }
.grade-status.pendiente { background: #fef3c7; color: #b45309; }
.grade-status.calificado { background: #dcfce7; color: #047857; }
.grade-value { font-size: 1.3rem; font-weight: 800; color: var(--primary); text-align: right; }

.empty-state { text-align: center; padding: 2rem 1rem; color: var(--text-light); }
.empty-state .empty-icon { font-size: 2.5rem; display: block; margin-bottom: 0.5rem; }

/* ============================================================
   BOOTCAMP / CURSO 2
   ============================================================ */
.progress-container p { font-size: 0.9rem; color: var(--text-light); margin-bottom: 0.5rem; }
.course2-progress { background: var(--success); }

.course2-modules-list { display: flex; flex-direction: column; gap: 0.6rem; }
.module-card-item {
    padding: 0.9rem 1rem; border-radius: 8px; border-left: 5px solid #bdc3c7;
    background: #f8fafc; font-size: 0.9rem; transition: 0.2s;
}
.module-card-item.completed { border-left-color: var(--success); background: #ecfdf5; cursor: pointer; }
.module-card-item.active { border-left-color: var(--primary); box-shadow: 0 2px 8px rgba(37,99,235,0.15); cursor: pointer; }
.module-card-item.active:hover, .module-card-item.completed:hover { transform: translateX(4px); }
.module-card-item.locked { opacity: 0.6; cursor: not-allowed; }

/* Calendario */
.calendar-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; margin-top: 0.75rem; }
.calendar-day {
    aspect-ratio: 1; display: flex; align-items: center; justify-content: center;
    border-radius: 6px; background: #f8fafc; font-size: 0.75rem; color: var(--text-light); position: relative;
}
.calendar-day.event { background: var(--primary); color: white; font-weight: 700; }
.calendar-day .event-dot { position: absolute; bottom: 3px; width: 5px; height: 5px; border-radius: 50%; background: white; }

/* Tareas */
.task-group h4 { font-size: 0.85rem; color: var(--text-light); margin-bottom: 0.5rem; text-transform: uppercase; letter-spacing: 0.02em; }
.task-group { margin-bottom: 1rem; }
.task-group:last-child { margin-bottom: 0; }
.task-list { list-style: none; display: flex; flex-direction: column; gap: 0.4rem; }
.task-list li { padding: 0.6rem 0.85rem; border-radius: 8px; font-size: 0.85rem; }
.task-list.completed li { background: #ecfdf5; color: #047857; }
.task-list.pending li { background: #fef3c7; color: #b45309; }
.task-list .task-empty { background: #f8fafc !important; color: var(--text-light) !important; font-style: italic; }

/* Historial de entregas */
.submission-item { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 0.5rem 0.75rem; padding: 0.75rem; background: #f8fafc; border-radius: 8px; margin-bottom: 0.5rem; }
.submission-item:last-child { margin-bottom: 0; }
.submission-info { flex: 1; min-width: 0; }
.submission-info p { margin: 0; }
.submission-info .file-name { font-weight: 600; font-size: 0.9rem; word-break: break-word; }
.submission-info .file-meta { font-size: 0.75rem; color: var(--text-light); }
.submission-item .grade-status { flex-shrink: 0; }

/* ============================================================
   LECCIÓN (Clase 1)
   ============================================================ */
.lesson-subtitle { color: var(--text-light); font-style: italic; margin-bottom: 0.5rem; }
.lesson-step-list { list-style: none; display: flex; flex-direction: column; gap: 0.6rem; margin-top: 0.75rem; }
.lesson-step-list.numbered { list-style: decimal; padding-left: 1.25rem; gap: 0.4rem; }
.lesson-step-list li { display: flex; align-items: flex-start; gap: 0.75rem; padding: 0.75rem; background: #f8fafc; border-radius: 8px; border-left: 4px solid var(--success); font-size: 0.9rem; line-height: 1.5; }
.lesson-step-list.numbered li { display: list-item; background: none; border-left: none; padding: 0.2rem 0; }
.lesson-icon { font-size: 1.2rem; flex-shrink: 0; }

.lesson-tool-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; margin-top: 0.75rem; }
.lesson-tool-card { background: #f8fafc; border: 2px solid var(--border); border-radius: 12px; padding: 1.25rem 1rem; text-align: center; transition: 0.2s; }
.lesson-tool-card:hover { border-color: var(--success); transform: translateY(-4px); }
.lesson-emoji { font-size: 2.2rem; display: block; margin-bottom: 0.5rem; }
.lesson-tool-card h4 { margin-bottom: 0.4rem; font-size: 0.95rem; }
.lesson-tool-card p { font-size: 0.8rem; color: var(--text-light); }

.element-box {
    display: flex; justify-content: center; align-items: center; gap: 0.75rem; flex-wrap: wrap;
    background: #f8fafc; padding: 1.5rem; border: 3px dashed var(--success); border-radius: 10px; margin: 0.75rem 0;
}
.tag-label-lesson { font-family: monospace; font-weight: 700; color: var(--success); background: #fff; padding: 4px 10px; border-radius: 5px; border: 1px solid var(--success); }
.element-content { font-weight: 600; }

.debug-tip { background: #1e293b; color: white; padding: 1rem; border-radius: 10px; margin-top: 1rem; font-size: 0.9rem; line-height: 1.5; }
.debug-tip strong { color: #fbbf24; }
.debug-tip p { margin: 0; }
.debug-tip p + p { margin-top: 0.5rem; }

.hierarchy-demo { background: #f8fafc; padding: 1rem; border-radius: 10px; border: 1px solid var(--border); margin-top: 0.75rem; }
.hierarchy-level { margin: 0.6rem 0; padding-left: 0.85rem; border-left: 5px solid #cbd5e1; }
.hierarchy-level h1, .hierarchy-level h2, .hierarchy-level h3, .hierarchy-level p { color: var(--text); }

/* ============================================================
   SUBIR TAREA
   ============================================================ */
.drop-zone {
    border: 2px dashed var(--border); border-radius: 10px; padding: 1.5rem; text-align: center;
    cursor: pointer; transition: 0.2s; background: #f8fafc;
}
.drop-zone:hover { border-color: var(--primary); background: #eff6ff; }
.drop-zone-icon { font-size: 2rem; margin-bottom: 0.5rem; }
.drop-zone p { font-size: 0.85rem; color: var(--text-light); margin: 0; word-break: break-all; }

/* ============================================================
   PANEL DE ADMINISTRADOR
   ============================================================ */
.hub-card-admin { border: 2px solid #1e293b; background: #f8fafc; }
.hub-card-admin .hub-icon { background: #1e293b; color: white; }

.admin-stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.75rem; margin-bottom: 1rem; }
.admin-stat-box { margin-top: 0 !important; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 0.2rem; }
.admin-stat-icon { font-size: 1.4rem; }
.admin-stat-number { font-size: 1.3rem; font-weight: 800; color: var(--primary); }
.admin-stat-label { font-size: 0.75rem; color: var(--text-light); text-transform: uppercase; letter-spacing: 0.02em; }

.admin-filter-row { display: flex; gap: 0.5rem; margin-bottom: 1rem; overflow-x: auto; }
.admin-filter-btn {
    white-space: nowrap; padding: 0.5rem 1rem; border-radius: 50px; border: 1px solid var(--border);
    background: var(--surface); color: var(--text-light); font-weight: 600; font-size: 0.8rem; cursor: pointer;
}
.admin-filter-btn.active { background: var(--primary); color: white; border-color: var(--primary); }

.admin-user-card { display: flex; align-items: center; gap: 0.85rem; cursor: pointer; transition: 0.15s; }
.admin-user-card:hover { border-color: var(--primary); transform: translateX(2px); }
.admin-user-avatar {
    width: 44px; height: 44px; border-radius: 50%; background: var(--dark-blue); color: white;
    display: flex; align-items: center; justify-content: center; font-weight: 700; flex-shrink: 0; font-size: 0.9rem;
}
.admin-user-info { flex: 1; min-width: 0; }
.admin-user-info h3 { font-size: 0.95rem; margin-bottom: 0.15rem; }
.admin-user-info p { font-size: 0.8rem; color: var(--text-light); margin: 0; }
.admin-user-meta { text-align: right; flex-shrink: 0; }
.admin-user-meta .courses-count { font-size: 0.8rem; font-weight: 700; color: var(--primary); }
.admin-user-meta .wallet-amount { font-size: 0.75rem; color: var(--text-light); }

.admin-user-header { display: flex; align-items: center; gap: 1rem; }
.admin-user-header .admin-user-avatar { width: 60px; height: 60px; font-size: 1.2rem; }
.admin-user-header h3 { font-size: 1.1rem; }

.admin-course-progress-item { padding: 0.85rem; background: #f8fafc; border-radius: 8px; margin-bottom: 0.6rem; }
.admin-course-progress-item:last-child { margin-bottom: 0; }
.admin-course-progress-item h4 { font-size: 0.9rem; margin-bottom: 0.4rem; }
.admin-course-progress-item .progress-bar { margin-top: 0.4rem; }
.admin-course-progress-item .progress-label { font-size: 0.75rem; color: var(--text-light); margin-top: 0.25rem; }

.admin-submission-card { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 0.6rem; }
.admin-submission-info h4 { font-size: 0.9rem; margin-bottom: 0.2rem; }
.admin-submission-info p { font-size: 0.78rem; color: var(--text-light); margin: 0; }
.admin-submission-actions { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; }

/* Modal de calificación */
.modal-overlay {
    position: fixed; inset: 0; background: rgba(15, 23, 42, 0.6); z-index: 1000;
    display: flex; align-items: center; justify-content: center; padding: 1rem;
}
.modal-overlay.hidden { display: none; }
.modal-box { background: var(--surface); border-radius: 14px; padding: 1.5rem; width: 100%; max-width: 380px; }
.modal-box h3 { margin-bottom: 0.3rem; }
.modal-box-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.3rem; }
.modal-box-header h3 { margin: 0; }

/* Campo de monto a acreditar */
.credit-amount-box { background: #ecfdf5; border: 1px solid #a7f3d0; border-radius: 10px; padding: 1rem; margin-bottom: 1rem; }
.credit-amount-box label { font-size: 0.85rem; font-weight: 700; color: #047857; display: block; margin-bottom: 0.4rem; }
.credit-amount-box input { background: white; border-color: #a7f3d0; }
.credit-note { font-size: 0.75rem; color: #047857; margin: 0.3rem 0 0; }

/* Badge de precio en el catálogo */
.course-price-badge { background: #fef3c7; color: #b45309; font-size: 0.75rem; font-weight: 800; padding: 3px 8px; border-radius: 50px; }

/* Banner de precio en detalles del curso */
.course-price-banner { background: #eff6ff; border: 2px solid var(--primary); border-radius: 10px; padding: 1rem; text-align: center; margin-bottom: 1rem; }
.course-price-banner .price { font-size: 1.8rem; font-weight: 900; color: var(--primary); }
.course-price-banner p { font-size: 0.82rem; color: var(--text-light); margin: 0.2rem 0 0; }

/* Botón de eliminar (ícono de papelera) */
.btn-delete-icon {
    background: #fee2e2;
    color: #b91c1c;
    border: none;
    border-radius: 8px;
    width: 36px;
    height: 36px;
    font-size: 1.1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.15s;
}
.btn-delete-icon:hover { background: #fecaca; }

/* Botón eliminar en tarjetas de la lista */
.btn-delete-text {
    background: none;
    border: 1px solid #fecaca;
    color: #b91c1c;
    border-radius: 6px;
    padding: 0.35rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s;
    white-space: nowrap;
}
.btn-delete-text:hover { background: #fee2e2; }
.data-form-input {
    width: 100%; padding: 0.7rem 0.9rem; border: 1px solid var(--border); border-radius: 8px;
    font-size: 0.9rem; background: #f8fafc; color: var(--text); margin-top: 0.3rem; margin-bottom: 0.9rem;
    font-family: inherit;
}
.modal-box label { font-size: 0.85rem; font-weight: 600; color: var(--text-light); }
.modal-actions { display: flex; gap: 0.6rem; }
.modal-actions .btn { width: auto; flex: 1; }

/* ============================================================
   VERIFICACIÓN DE IDENTIDAD
   ============================================================ */
.verif-checkbox-label {
    display: flex; align-items: flex-start; gap: 0.5rem; font-size: 0.85rem;
    color: var(--text-light); font-weight: 500; margin: 0.5rem 0 1rem; line-height: 1.4; cursor: pointer;
}
.verif-checkbox-label input { margin-top: 0.2rem; flex-shrink: 0; }

.verif-status-card { text-align: center; max-width: 420px; margin: 2rem auto 0; padding: 2rem 1.5rem; }
.verif-status-icon {
    width: 64px; height: 64px; border-radius: 50%; font-size: 2rem;
    display: flex; align-items: center; justify-content: center; margin: 0 auto 1rem;
    background: #fef3c7; color: #b45309;
}
.verif-status-icon.rejected { background: #fee2e2; color: #b91c1c; }
.verif-status-card h2 { font-size: 1.3rem; }

/* Badge de pestaña con conteo */
.tab-badge {
    background: #ef4444; color: white; font-size: 0.65rem; font-weight: 800;
    padding: 1px 6px; border-radius: 50px; margin-left: 4px;
}

/* Tarjeta de verificación dentro del detalle del usuario (admin) */
.verif-card-header { display: flex; justify-content: space-between; align-items: center; }
.verif-card-header h3 { margin: 0; }
.verif-badge { font-size: 0.75rem; font-weight: 700; padding: 4px 10px; border-radius: 50px; white-space: nowrap; }
.verif-badge.no_solicitado { background: #f1f5f9; color: var(--text-light); }
.verif-badge.pendiente { background: #fef3c7; color: #b45309; }
.verif-badge.verificado { background: #dcfce7; color: #047857; }
.verif-badge.rechazado { background: #fee2e2; color: #b91c1c; }

.verif-data-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; margin-top: 0.85rem; }
.verif-data-item { background: #f8fafc; border-radius: 8px; padding: 0.6rem 0.75rem; }
.verif-data-item .label { font-size: 0.7rem; color: var(--text-light); text-transform: uppercase; letter-spacing: 0.02em; display: block; }
.verif-data-item .value { font-size: 0.9rem; font-weight: 600; margin-top: 0.1rem; }
.verif-data-item.full-width { grid-column: 1 / -1; }
.verif-data-item.warning .value { color: #b91c1c; }

/* Tarjeta en la lista de Verificaciones pendientes (admin) */
.admin-verif-card { display: flex; flex-direction: column; gap: 0.6rem; }
.admin-verif-card .top-row { display: flex; justify-content: space-between; align-items: center; }
.admin-verif-card h3 { font-size: 0.95rem; }

/* ============================================================
   PAGOS: DATOS BANCARIOS DE LA EMPRESA + FORMULARIO DE COMPROBANTE
   ============================================================ */
.company-bank-card { border: 2px dashed var(--primary); }
.bank-data-note { font-size: 0.75rem; color: var(--text-light); font-style: italic; margin-top: 0.75rem; text-align: center; }

.payment-bank-card { border: 2px dashed var(--primary); }
.payment-bank-note { font-size: 0.75rem; color: var(--text-light); font-style: italic; margin-top: 0.75rem; text-align: center; }
.bank-data-subhead { font-size: 0.85rem; font-weight: 700; color: var(--text); margin: 1rem 0 0.5rem; }
.bank-data-subhead:first-of-type { margin-top: 0.5rem; }
.payment-form-card { border: 1px solid var(--border); }
.bank-section-title { font-size: 0.8rem; font-weight: 700; color: var(--primary); text-transform: uppercase; letter-spacing: 0.02em; margin: 1rem 0 0.5rem; }
.bank-section-title:first-of-type { margin-top: 0.75rem; }

.payout-method-selector { display: flex; gap: 0.5rem; margin-bottom: 1rem; }
.method-btn {
    flex: 1; padding: 0.7rem 0.5rem; border-radius: 8px; border: 2px solid var(--border);
    background: var(--surface); color: var(--text-light); font-weight: 600; font-size: 0.85rem; cursor: pointer; transition: 0.2s;
}
.method-btn.active { border-color: var(--primary); background: #eff6ff; color: var(--primary); }

/* Tarjeta de comprobante en historial / admin */
.receipt-item-card { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 0.6rem; }
.receipt-item-info h4 { font-size: 0.9rem; margin-bottom: 0.2rem; }
.receipt-item-info p { font-size: 0.78rem; color: var(--text-light); margin: 0; }
.receipt-status { padding: 4px 10px; border-radius: 50px; font-size: 0.75rem; font-weight: 700; white-space: nowrap; }
.receipt-status.pendiente { background: #fef3c7; color: #b45309; }
.receipt-status.aprobado { background: #dcfce7; color: #047857; }
.receipt-status.rechazado { background: #fee2e2; color: #b91c1c; }

/* Tarjeta de comprobante en lista de admin con botón */
.admin-payment-card { display: flex; flex-direction: column; gap: 0.6rem; }
.admin-payment-card .top-row { display: flex; justify-content: space-between; align-items: center; }
.admin-payment-card h3 { font-size: 0.95rem; }





/* ============================================================
   RESPONSIVE — MÓVIL PRIMERO
   El diseño "split" (formulario + panel azul lado a lado)
   solo aplica en pantallas >= 560px. En móvil el panel azul
   se convierte en un banner compacto arriba del formulario.
   ============================================================ */

/* --- Pantallas angostas: móvil (< 560px) --- */
@media (max-width: 559px) {

    /* Contenedor sin padding lateral excesivo */
    .container { padding: 0.75rem; }

    /* Auth: apilado vertical, el panel azul arriba como banner */
    .split-auth-card {
        flex-direction: column;
        margin-top: 1rem;
        min-height: unset;
        border-radius: 16px;
    }

    /* Panel izquierdo (formulario): full width */
    .auth-left {
        padding: 1.75rem 1.5rem 1.5rem;
        order: 2;
    }

    /* Panel derecho (azul): banner compacto arriba */
    .auth-right {
        order: 1;
        padding: 1rem 1.25rem 1.25rem;
        min-height: 140px;
        flex-direction: column;
        justify-content: space-between;
        align-items: flex-start;
        text-align: left;
    }

    .hero-nav {
        display: flex;
        gap: 0.75rem;
        align-self: flex-end;
        margin-bottom: 0.5rem;
    }
    .hero-nav a { font-size: 0.72rem; opacity: 0.9; }

    .hero-content {
        text-align: left;
        flex-grow: 0;
        justify-content: center;
    }

    .hero-content h2 { font-size: 2rem; margin-bottom: 0.25rem; }
    .hero-content p { font-size: 0.8rem; line-height: 1.4; }
    .hero-switch { font-size: 0.78rem; }
    .hero-switch a { font-weight: 700; }

    /* Auth: avatar más pequeño en móvil */
    .auth-avatar { width: 56px; height: 56px; margin-bottom: 1.25rem; }
    .auth-avatar svg { width: 28px; height: 28px; }
    .auth-logo { font-size: 1rem; margin-bottom: 1.25rem; }
    .auth-dots { margin-top: 1rem; }

    /* Hub: tarjetas en 1 columna siempre */
    .hub-grid { grid-template-columns: 1fr !important; gap: 0.75rem; }
    .course-grid { grid-template-columns: 1fr !important; }
    .lesson-tool-cards { grid-template-columns: 1fr; }

    /* Pestañas del admin más compactas */
    .learning-tab { font-size: 0.68rem; padding: 0.5rem 0.3rem; }

    /* Stats del admin: 2 columnas */
    .admin-stats-grid { grid-template-columns: repeat(2, 1fr); }

    /* Datos bancarios: 1 columna */
    .verif-data-grid { grid-template-columns: 1fr; }

    /* Perfil */
    .dashboard-grid { grid-template-columns: 1fr; }
    .profile-links { flex-direction: column; align-items: stretch; }
    .profile-header { text-align: center; }
    .profile-avatar-container { margin-left: auto; margin-right: auto; justify-content: center; }

    /* Calendario del bootcamp */
    .calendar-grid { gap: 3px; }
    .calendar-day { font-size: 0.65rem; border-radius: 4px; }

    /* Historial */
    .grade-item-card { flex-wrap: wrap; }
    .grade-value { width: 100%; text-align: left; }

    /* Confirmación */
    .confirmation-card { padding: 1.5rem 1rem; }
}

/* --- Pantallas medianas (560px – 800px): dos columnas lado a lado --- */
@media (min-width: 560px) and (max-width: 800px) {
    .split-auth-card {
        flex-direction: row;
        margin-top: 1.5rem;
    }
    .auth-right { min-width: 200px; }
    .hub-grid { grid-template-columns: repeat(2, 1fr); }
}

/* --- Contenedor base: nunca más de 600px de ancho en desktop --- */
@media (min-width: 800px) {
    .container { max-width: 600px; }
    .dashboard-grid { grid-template-columns: 1fr 1fr; }
}

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

/* ============================================================
   VISTA ABOUT / CONTACT
   ============================================================ */
.about-card {
    background: var(--surface);
    border-radius: 20px;
    overflow: hidden;
    margin-top: 1.5rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.3);
}

.about-header {
    background: linear-gradient(135deg, #e5e7ee 0%, #60a5fa 40%, #0f40c5 100%);
    padding: 2.5rem 1.5rem 2rem;
    text-align: center;
    color: white;
}

.about-logo {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.about-title {
    font-size: 2rem;
    font-weight: 900;
    margin-bottom: 0.4rem;
    letter-spacing: -0.02em;
}

.about-tagline {
    font-size: 0.95rem;
    opacity: 0.9;
    line-height: 1.4;
}

.about-body {
    padding: 1.75rem 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.about-body > p {
    font-size: 0.95rem;
    color: var(--text-light);
    line-height: 1.6;
}

.about-features {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.about-feature {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    background: #f8fafc;
    border-radius: 12px;
    padding: 1rem 1.1rem;
    border-left: 4px solid var(--primary);
}

.about-icon { font-size: 1.6rem; flex-shrink: 0; }

.about-feature h3 {
    font-size: 0.95rem;
    margin-bottom: 0.25rem;
    color: var(--text);
}

.about-feature p {
    font-size: 0.83rem;
    color: var(--text-light);
    line-height: 1.5;
    margin: 0;
}

.about-contact {
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: 12px;
    padding: 1.25rem;
    text-align: center;
}

.about-contact h3 {
    font-size: 1rem;
    color: var(--text);
    margin-bottom: 0.4rem;
}

.about-contact p {
    font-size: 0.85rem;
    color: var(--text-light);
    line-height: 1.5;
    margin-bottom: 1rem;
}

.btn-facebook {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    background: #1877f2;
    color: white;
    font-weight: 700;
    font-size: 0.95rem;
    padding: 0.8rem 1.5rem;
    border-radius: 10px;
    text-decoration: none;
    transition: background 0.2s ease, transform 0.1s ease;
}

.btn-facebook:hover { background: #1464d8; }
.btn-facebook:active { transform: scale(0.97); }

.about-back-btn {
    margin: 0 1.5rem 1.5rem;
    width: calc(100% - 3rem);
    text-align: center;
}

