/* Diplomado LAF: TODO lo de este archivo aplica solo dentro del curso del diplomado (body.course-3).
   El resto del Moodle (portada, otros cursos, administración) se ve como Moodle normal.
   Se carga en <head>, así que la página ya pinta con el diseño: sin el salto de «primero sin estilo». */

/* ---------- sin salto: mientras el script arma la página, se ve el fondo oscuro de la marca ---------- */
html:has(body.course-3) { background: #0A110D; }
body.course-3 { background: #0A110D !important; }
body.course-3 #page-wrapper { opacity: 0; animation: laf-mostrar 0.01s linear 2.5s forwards; }      /* si el script fallara, igual aparece a los 2,5 s */
body.course-3.laf-listo #page-wrapper { opacity: 1 !important; animation: none !important; }
@keyframes laf-mostrar { to { opacity: 1; } }
@keyframes laf-entrar { from { opacity: 0; } to { opacity: 1; } }

/* ---------- barra superior del curso ---------- */
body.course-3 .navbar.fixed-top { background: #0A110D !important; border-bottom: 0 !important; box-shadow: none !important; }
body.course-3 .navbar.fixed-top::after { content: ''; position: absolute; left: 0; right: 0; bottom: -4px; height: 4px; background: repeating-linear-gradient(90deg, #00A859 0 8px, #fff 8px 16px); }
body.course-3 .navbar.fixed-top .nav-link, body.course-3 .navbar.fixed-top .navbar-brand, body.course-3 .navbar.fixed-top .usermenu .login, body.course-3 .navbar.fixed-top .usermenu .login a,
body.course-3 .navbar.fixed-top .btn-open-drawer, body.course-3 .navbar.fixed-top .popover-region-toggle, body.course-3 .navbar.fixed-top .usertext, body.course-3 .navbar.fixed-top .icon { color: #fff !important; }
body.course-3 .navbar.fixed-top .primary-navigation .nav-link { border-radius: 0; background: transparent !important; }
body.course-3 .navbar.fixed-top .primary-navigation .nav-link:hover, body.course-3 .navbar.fixed-top .primary-navigation .nav-link:focus { background: rgba(255, 255, 255, 0.10) !important; }
body.course-3 .navbar.fixed-top .primary-navigation .nav-link.active { border-bottom: 3px solid #00A859; background: transparent !important; }
body.course-3 .navbar.fixed-top .usermenu .login a:hover { color: #00C468 !important; }
body.course-3 .laf-navlogo { height: 46px; width: auto; }

/* ---------- panel lateral (índice del curso): oscuro, legible, con los módulos como «fechas» ---------- */
body.course-3 .drawer.drawer-left { background: #0F1A14 !important; border-right: 1px solid #1F2E25 !important; color: #DCEBE2; font-family: 'Plus Jakarta Sans', system-ui, sans-serif; }
body.course-3 .drawer.drawer-left .drawerheader { background: #0F1A14; border-bottom: 1px solid #1F2E25; }
body.course-3 .drawer.drawer-left .drawerheader .btn, body.course-3 .drawer.drawer-left .drawerheader .icon { color: #9FB5A8 !important; }
body.course-3 .drawer.drawer-left::before { content: 'Ruta del diplomado'; display: block; padding: 18px 22px 6px; font: 800 italic 1.15rem/1 'Barlow Condensed', sans-serif; text-transform: uppercase; color: #00A859; }
body.course-3 .courseindex .courseindex-section { margin: 0 10px 2px; border-radius: 0; }
body.course-3 .courseindex .courseindex-section-title { padding: 10px 12px; }
body.course-3 .courseindex .courseindex-section-title a, body.course-3 .courseindex .courseindex-section-title .courseindex-link { color: #DCEBE2 !important; font-weight: 700; font-size: 0.9rem; }
body.course-3 .courseindex .courseindex-section-title .icon { color: #6F8577 !important; }
body.course-3 .courseindex .courseindex-item { padding: 8px 12px 8px 30px; border-radius: 0; }
body.course-3 .courseindex .courseindex-item .courseindex-link, body.course-3 .courseindex .courseindex-item a { color: #9FB5A8 !important; font-size: 0.86rem; }
body.course-3 .courseindex .courseindex-item:hover, body.course-3 .courseindex .courseindex-section-title:hover { background: #17251D !important; }
body.course-3 .courseindex .courseindex-item.pageitem, body.course-3 .courseindex .courseindex-section-title.pageitem { background: #005C30 !important; }
body.course-3 .courseindex .courseindex-item.pageitem a, body.course-3 .courseindex .courseindex-section-title.pageitem a { color: #fff !important; }
body.course-3 .courseindex .dimmed, body.course-3 .courseindex .dimmed a { color: #4F6457 !important; }
body.course-3 .courseindex .completioninfo .icon, body.course-3 .courseindex .courseindex-chevron .icon { color: #00A859 !important; }
body.course-3 .drawer-left .drawercontent { scrollbar-width: thin; scrollbar-color: #2E4236 transparent; }
body.course-3 .drawer-toggler .btn, body.course-3 .drawer-toggles .btn { background: #0F1A14 !important; color: #fff !important; border: 1px solid #2E4236 !important; border-radius: 0 !important; }

/* ---------- menú del curso (Curso, Participantes, Calificaciones, Informes…): pestañas modernas ---------- */
body.course-3 .secondary-navigation { background: #0A110D; border-bottom: 1px solid #1F2E25; margin: 0 !important; padding: 0 40px !important; }
body.course-3 .secondary-navigation .nav-tabs { border: 0; gap: 4px; max-width: 1240px; margin: 0 auto; }
body.course-3 .secondary-navigation .nav-link { color: #9FB5A8 !important; border: 0 !important; border-bottom: 3px solid transparent !important; border-radius: 0 !important; background: transparent !important; font-weight: 600; padding: 14px 16px; }
body.course-3 .secondary-navigation .nav-link:hover { color: #fff !important; }
body.course-3 .secondary-navigation .nav-link.active { color: #fff !important; border-bottom-color: #00A859 !important; }
body.course-3 .secondary-navigation .dropdown-menu { background: #0F1A14; border: 1px solid #1F2E25; border-radius: 0; }
body.course-3 .secondary-navigation .dropdown-item { color: #DCEBE2; } body.course-3 .secondary-navigation .dropdown-item:hover { background: #17251D; color: #fff; }

/* ---------- páginas que no son la ruta ni una actividad del módulo (participantes, calificaciones…): coherentes con la marca ---------- */
body.course-3 #page, body.course-3 #topofscroll { background: #0A110D !important; }
body.course-3 #region-main { background: #fff; border: 0; border-radius: 0; }
body.course-3 .page-header-headings h1, body.course-3 h1.h2 { font-family: 'Barlow Condensed', sans-serif; font-style: italic; font-weight: 900; text-transform: uppercase; color: #fff; }
body.course-3 #page-header { color: #DCEBE2; }
body.course-3 #page-header .breadcrumb a { color: #00C468; }
body.course-3 .btn-primary { background: #00894A !important; border-color: #00894A !important; border-radius: 0 !important; }
body.course-3 .btn-primary:hover { background: #005C30 !important; }
body.course-3 a { color: #00894A; }

/* panel: título dentro de la cabecera y jerarquía (módulos como títulos, actividades con sangría y punto) */
body.course-3 .drawer.drawer-left::before { display: none !important; }
body.course-3 .drawer.drawer-left .drawerheader { position: relative; }
body.course-3 .drawer.drawer-left .drawerheader::after { content: 'Ruta del diplomado'; position: absolute; left: 58px; top: 50%; transform: translateY(-50%); font: 800 italic 1.1rem/1 'Barlow Condensed', sans-serif; text-transform: uppercase; color: #fff; pointer-events: none; }
body.course-3 .courseindex .courseindex-section { border-left: 3px solid transparent; }
body.course-3 .courseindex .courseindex-section:has(.pageitem) { border-left-color: #00A859; }
body.course-3 .courseindex .courseindex-section-title a { white-space: normal !important; line-height: 1.3; }
body.course-3 .courseindex .courseindex-item { position: relative; padding-left: 40px !important; }
body.course-3 .courseindex .courseindex-item::before { content: ''; position: absolute; left: 24px; top: 50%; width: 6px; height: 6px; margin-top: -3px; border-radius: 50%; background: #3B5446; }
body.course-3 .courseindex .courseindex-item.pageitem::before { background: #fff; }
body.course-3 .courseindex .courseindex-item a { white-space: normal !important; line-height: 1.35; }
body.course-3 .courseindex .courseindex-section-title::before, body.course-3 .courseindex .courseindex-section > .courseindex-item::before { display: none; } body.course-3 .courseindex .courseindex-sectioncontent .courseindex-item::before { display: block; } body.course-3 .courseindex .courseindex-section-title { padding-left: 12px !important; }
