:root{--navy:#09234a;--blue:#1674e8;--blue2:#0e5ec4;--ink:#142b4e;--muted:#71829b;--line:#dce7f5;--surface:#fff;--bg:#f3f7fc;--green:#0ca77a;--orange:#ef8c29;--red:#ed4c57;--purple:#7754e8;--shadow:0 8px 24px rgba(24,64,119,.06)}
*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--ink);font-family:'DM Sans',sans-serif;font-size:14px}button,input,select,textarea{font:inherit}button{cursor:pointer}.sidebar{position:fixed;inset:0 auto 0 0;width:232px;background:linear-gradient(165deg,#0b2c5a,#061b3b);color:#fff;padding:23px 14px;display:flex;flex-direction:column;z-index:5}.brand{display:flex;align-items:center;gap:12px;padding:0 12px 30px;font:800 18px Manrope,sans-serif;letter-spacing:-.5px}.brand-icon{height:42px;width:42px;border:1px solid #47b9ff;border-radius:13px;display:grid;place-items:center;font-size:25px;color:#48c4ff;box-shadow:inset 0 0 16px #1473e644}.brand-sub{display:block;font:600 8px 'DM Sans';letter-spacing:1.6px;color:#8bb1db;margin-top:2px}.side-label{padding:0 13px 10px;color:#7291bb;font-size:9px;letter-spacing:1.3px;font-weight:700}.sidebar nav{display:grid;gap:5px}.nav-item{border:0;background:transparent;color:#c3d2e7;text-align:left;padding:12px 14px;border-radius:9px;display:flex;align-items:center;gap:13px;font-weight:600;transition:.2s}.nav-item span{width:19px;text-align:center;font-size:18px}.nav-item:hover{background:#ffffff12;color:white}.nav-item.active{color:#fff;background:linear-gradient(100deg,#187bec,#1261c9);box-shadow:0 5px 14px #0065d244}.sidebar-bottom{margin-top:auto;border-radius:15px;background:linear-gradient(145deg,#0c3972,#071e40);padding:17px 15px;color:#fff}.goal-icon{font-size:27px;color:#4fc6ff;margin-bottom:12px}.sidebar-bottom b{font:700 13px/1.5 Manrope}.sidebar-bottom small{display:block;color:#91afd4;font-size:10px;margin-top:9px}.main-shell{margin-left:232px;min-height:100vh}.topbar{height:76px;background:#fff;border-bottom:1px solid #e2eaf5;display:flex;align-items:center;justify-content:space-between;padding:0 30px;position:sticky;top:0;z-index:4}.page-brand{display:flex;gap:12px;align-items:center}.mini-logo{height:39px;width:39px;display:grid;place-items:center;border-radius:11px;background:#eaf3ff;color:#1170df;font-size:23px}.page-brand b{font:800 17px Manrope;display:block}.page-brand small{color:#68809e;font-size:11px}.top-actions{display:flex;align-items:center;gap:19px}.global-search{height:38px;width:min(330px,28vw);border:1px solid var(--line);border-radius:9px;display:flex;align-items:center;padding:0 11px;gap:8px;color:#6e87a6}.global-search span{font-size:21px}.global-search input{border:0;outline:0;width:100%;font-size:11px;color:var(--ink)}.icon-button{position:relative;border:0;background:#edf5ff;border-radius:50%;height:38px;width:38px;color:#2c67a8;font-size:17px}.icon-button i{position:absolute;right:-3px;top:-4px;background:#f04752;color:#fff;border-radius:20px;font:700 9px 'DM Sans';padding:3px 5px;font-style:normal}.user-pill{display:flex;align-items:center;gap:9px}.user-pill b,.user-pill small{display:block}.user-pill b{font-size:11px}.user-pill small{font-size:9px;color:var(--muted);margin-top:2px}.user-pill>span{color:#788ba4;margin-left:8px}.avatar{width:34px;height:34px;border-radius:50%;display:grid;place-items:center;font-size:10px;font-weight:700;flex:0 0 auto}.avatar-blue{background:linear-gradient(145deg,#d7edff,#8fc6ff);color:#1459a2}.content{padding:25px 29px 40px;max-width:1750px;margin:auto}.heading-row{display:flex;align-items:flex-start;justify-content:space-between;margin-bottom:20px}.heading-row h1{font:800 23px Manrope;margin:0 0 4px;letter-spacing:-.5px}.heading-row p{margin:0;color:#74859b;font-size:12px}.btn{border:1px solid transparent;border-radius:8px;padding:10px 14px;font-weight:700;font-size:11px;display:inline-flex;gap:7px;align-items:center;justify-content:center;transition:.15s}.btn-primary{color:white;background:linear-gradient(110deg,#1680f6,#0e62cf);box-shadow:0 5px 12px #1475e824}.btn-primary:hover{filter:brightness(.96);transform:translateY(-1px)}.btn-light{background:#fff;border-color:var(--line);color:#30537c}.btn-danger{background:#fff2f2;color:#c93e49;border-color:#ffd9dc}.stats-grid{display:grid;grid-template-columns:repeat(5,minmax(130px,1fr));gap:12px;margin-bottom:16px}.stat-card,.panel,.module-card{background:#fff;border:1px solid #e0eaf6;border-radius:12px;box-shadow:var(--shadow)}.stat-card{padding:15px 15px 13px;display:flex;align-items:center;gap:11px}.stat-icon{height:39px;width:39px;border-radius:12px;display:grid;place-items:center;font-size:19px}.tone-blue{background:#e7f2ff;color:#1874e3}.tone-green{background:#e3f8f0;color:#0a9a6f}.tone-orange{background:#fff1df;color:#ea8822}.tone-purple{background:#f0eaff;color:#7754e8}.tone-red{background:#ffeded;color:#e64d57}.stat-card label{color:#6d7f99;font-size:10px;display:block}.stat-card strong{font:800 21px Manrope;display:block;margin-top:1px}.stat-card small{color:#17855f;font-size:9px;display:block;margin-top:3px}.dashboard-grid{display:grid;grid-template-columns:minmax(0,1.55fr) minmax(290px,.85fr);gap:15px}.panel{padding:16px;margin-bottom:15px}.panel-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:12px}.panel-head h2,.module-title{margin:0;font:800 14px Manrope}.panel-head p{margin:3px 0 0;color:var(--muted);font-size:10px}.subtle-link{border:0;background:transparent;color:var(--blue);font-size:10px;font-weight:700}.table-wrap{overflow:auto}.data-table{width:100%;border-collapse:collapse;white-space:nowrap}.data-table th{background:#f5f8fc;color:#667b98;font-weight:700;font-size:9px;text-align:left;padding:10px 9px;border-block:1px solid #e6edf6}.data-table td{padding:10px 9px;border-bottom:1px solid #edf1f7;font-size:10px}.data-table tr:last-child td{border-bottom:0}.project-name{font-weight:700;color:#1d385d}.secondary{display:block;color:#8a99ac;font-size:9px;margin-top:3px}.badge{display:inline-flex;padding:5px 8px;border-radius:20px;font-size:9px;font-weight:700}.badge-green{background:#e0f7ee;color:#07845f}.badge-blue{background:#e5f1ff;color:#1769cd}.badge-purple{background:#eee8ff;color:#6f4bdd}.badge-orange{background:#fff0dc;color:#ca720f}.badge-gray{background:#edf1f5;color:#67798e}.badge-red{background:#ffe9e9;color:#c6424b}.badge-priority{padding:5px 9px;border-radius:6px}.progress-line{height:7px;background:#e8eff8;border-radius:12px;overflow:hidden;min-width:65px}.progress-line i{height:100%;display:block;background:linear-gradient(90deg,#1276e8,#21b999);border-radius:12px}.progress-cell{display:flex;align-items:center;gap:7px}.progress-cell b{font-size:9px}.donut-row{display:flex;align-items:center;gap:22px;padding:4px 4px 12px}.donut{--pct:70;width:145px;height:145px;border-radius:50%;background:conic-gradient(#0ba77b calc(var(--pct)*1%),#1599d1 0 77%,#7754e8 0 90%,#fa9b47 0);position:relative;display:grid;place-items:center;flex:0 0 auto}.donut:before{content:'';position:absolute;inset:17px;background:#fff;border-radius:50%}.donut-center{position:relative;text-align:center}.donut-center b{font:800 22px Manrope;display:block}.donut-center small{color:var(--muted);font-size:9px}.legend{display:grid;gap:11px;width:100%}.legend div{display:flex;align-items:center;justify-content:space-between;gap:10px;font-size:10px}.legend span{display:flex;align-items:center;gap:7px;color:#576b87}.dot{height:8px;width:8px;border-radius:50%;background:#1b91dc}.dot.green{background:#0ba77b}.dot.purple{background:#7754e8}.dot.orange{background:#fa9b47}.legend b{font-size:10px}.phase-list{display:grid;gap:11px}.phase-row label{display:flex;justify-content:space-between;font-size:9px;margin-bottom:5px}.phase-row .progress-line{height:8px}.phase-row .progress-line i{background:linear-gradient(90deg,#197af0,#38b8c2)}.alert-list{display:grid;gap:8px}.alert-item{display:flex;gap:9px;padding:10px;border-radius:9px;background:#fff6f4;border:1px solid #ffe3df}.alert-symbol{color:#e74a50;font-size:16px}.alert-item b{font-size:10px;display:block}.alert-item small{display:block;color:#77869a;font-size:9px;margin-top:3px}.toolbar{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.field-control{border:1px solid var(--line);background:#fff;border-radius:8px;padding:9px 11px;color:#334e70;font-size:10px;outline-color:#88baff}.toolbar input{width:190px}.toolbar select{min-width:125px}.table-panel{padding:0;overflow:hidden}.table-panel .panel-head{padding:15px 16px 7px}.row-project{display:flex;align-items:center;gap:8px}.project-symbol{height:29px;width:29px;display:grid;place-items:center;border-radius:8px;background:#e8f2ff;color:#1674e8}.table-menu{border:0;background:transparent;color:#557399;font-size:18px}.table-footer{padding:12px 16px;color:var(--muted);font-size:10px;border-top:1px solid #edf2f8}.cards-grid{display:grid;grid-template-columns:repeat(3,minmax(220px,1fr));gap:13px}.person-card{padding:16px}.person-top{display:flex;align-items:center;gap:10px}.person-top b{display:block;font-size:12px}.person-top small{color:var(--muted);font-size:9px}.person-meta{display:flex;justify-content:space-between;margin:15px 0 7px;color:#6c7e95;font-size:9px}.kpi-banner{background:linear-gradient(110deg,#0c3670,#1679db);color:#fff;border-radius:13px;padding:17px 20px;margin-bottom:16px;display:flex;align-items:center;justify-content:space-between}.kpi-banner b{font:800 15px Manrope}.kpi-banner small{display:block;color:#c6e1ff;font-size:10px;margin-top:4px}.kpi-banner strong{font:800 24px Manrope}.module-cards{display:grid;grid-template-columns:repeat(3,minmax(200px,1fr));gap:13px}.module-card{padding:16px}.module-card h3{font:800 12px Manrope;margin:0 0 7px}.module-card p{font-size:10px;line-height:1.5;color:#71839c;margin:0}.empty-state{text-align:center;padding:36px;color:var(--muted)}.empty-state b{display:block;color:var(--ink);margin:7px}.modal-backdrop{position:fixed;inset:0;background:#07172c88;z-index:20;display:grid;place-items:center;padding:20px}.modal{width:min(1050px,100%);max-height:94vh;overflow:auto;background:#f6f9fd;border-radius:16px;box-shadow:0 24px 90px #06193455}.modal-head{position:sticky;top:0;background:#fff;padding:16px 20px;border-bottom:1px solid var(--line);display:flex;justify-content:space-between;align-items:center;z-index:1}.modal-head h2{margin:0;font:800 17px Manrope}.modal-head small{color:var(--muted)}.modal-body{padding:15px 18px}.form-grid{display:grid;grid-template-columns:1.15fr .85fr;gap:12px}.form-section{background:#fff;border:1px solid var(--line);border-radius:11px;padding:15px;margin-bottom:12px}.form-section h3{font:800 12px Manrope;margin:0 0 13px;color:#175baf}.form-fields{display:grid;grid-template-columns:1fr 1fr;gap:11px}.form-field{display:grid;gap:5px}.form-field.full{grid-column:1/-1}.form-field label{font-size:9px;font-weight:700;color:#526984}.form-field input,.form-field select,.form-field textarea{border:1px solid #d9e4f2;border-radius:7px;padding:9px 10px;font-size:10px;color:#263f60;background:#fff;outline-color:#8cbaff}.form-field textarea{min-height:65px;resize:vertical}.form-foot{display:flex;justify-content:flex-end;gap:8px;padding:0 18px 17px}.form-note{color:#8291a5;font-size:9px;margin-top:8px}.toast{position:fixed;right:22px;bottom:20px;background:#0d2d57;color:#fff;border-radius:9px;padding:12px 16px;box-shadow:var(--shadow);font-size:11px;opacity:0;transform:translateY(10px);transition:.2s;pointer-events:none;z-index:50}.toast.show{opacity:1;transform:translateY(0)}.toast.error{background:#bd3442}.screen-loading{padding:50px;text-align:center;color:#7c8ba1}
@media(max-width:1200px){.sidebar{width:205px}.main-shell{margin-left:205px}.content{padding:21px}.stats-grid{grid-template-columns:repeat(3,1fr)}.cards-grid,.module-cards{grid-template-columns:repeat(2,minmax(200px,1fr))}.topbar{padding:0 20px}}
@media(max-width:820px){.sidebar{width:65px;padding:15px 7px}.brand{padding:0 3px 23px}.brand>span,.side-label,.nav-item:not(.active){font-size:0}.brand-icon{width:44px}.nav-item{justify-content:center;padding:12px 5px;font-size:0}.nav-item span{font-size:18px}.sidebar-bottom{display:none}.main-shell{margin-left:65px}.topbar{padding:0 13px}.page-brand small,.user-pill>div:not(.avatar),.user-pill>span{display:none}.top-actions{gap:8px}.global-search{width:190px}.content{padding:18px 13px}.dashboard-grid{grid-template-columns:1fr}.form-grid{grid-template-columns:1fr}}
@media(max-width:560px){.topbar{height:64px}.page-brand b{font-size:12px}.global-search{width:35px;border:0;padding:0;justify-content:center}.global-search input{display:none}.global-search span{font-size:23px}.stats-grid{grid-template-columns:repeat(2,1fr);gap:8px}.stat-card{padding:11px 9px}.stat-icon{width:33px;height:33px}.stat-card strong{font-size:17px}.heading-row{gap:10px}.heading-row h1{font-size:19px}.cards-grid,.module-cards{grid-template-columns:1fr}.form-fields{grid-template-columns:1fr}.form-field.full{grid-column:auto}.donut-row{gap:12px}.donut{width:115px;height:115px}.donut:before{inset:14px}.user-pill{display:none}}
.user-menu-wrap{position:relative}.user-pill{border:0;background:transparent;text-align:left;padding:4px;border-radius:10px;color:inherit}.user-pill:hover{background:#f2f7fd}.user-menu{position:absolute;right:0;top:calc(100% + 6px);background:#fff;border:1px solid var(--line);border-radius:10px;box-shadow:0 12px 30px #0c2a5522;min-width:190px;padding:6px;z-index:10}.user-menu button{display:block;width:100%;border:0;background:transparent;text-align:left;padding:9px 11px;border-radius:7px;font-size:11px;color:var(--ink)}.user-menu button:hover{background:#eef5ff}.user-menu[hidden],.nav-item[hidden]{display:none}
.kpi-alt{background:linear-gradient(110deg,#0b6b57,#11a585)}.stats-4{grid-template-columns:repeat(4,1fr)}.inline-muted{font:500 10px 'DM Sans';color:var(--muted)}
button.alert-item{width:100%;text-align:left;font:inherit;color:inherit;cursor:pointer;align-items:center}button.alert-item:hover{border-color:#ffc9c2}.alert-item>div{flex:1}.alert-date{color:#8a99ac;font-size:9px;white-space:nowrap}.alert-ok{background:#effaf5;border-color:#d7f1e4}.alert-ok .alert-symbol{color:#0c9b6e}.text-red{color:#c6424b}
.margin-box{margin-top:12px;display:flex;justify-content:space-between;gap:10px;flex-wrap:wrap;background:#effaf5;border:1px solid #cdeedd;border-radius:9px;padding:11px 13px;font-size:11px;color:#17684f}.margin-box b{font:800 15px Manrope;margin-left:4px}.margin-bad{background:#fff2f2;border-color:#ffd3d6;color:#b8343f;font-weight:700}
.form-foot .spacer{flex:1}.check{display:flex!important;align-items:center;gap:8px;font-size:11px!important}.check input{width:auto}.module-current{border-color:#1674e8;box-shadow:0 0 0 2px #1674e833}.module-cards+.module-cards,.panel+.module-cards{margin-top:14px}.panel .module-cards{margin-top:0}
.form-field input:disabled,.field-control:disabled{background:#f3f6fa;color:#8191a6;cursor:not-allowed}
.login-body{min-height:100vh;display:grid;place-items:center;padding:20px;background:radial-gradient(circle at 15% 20%,#1674e822,transparent 40%),var(--bg)}.login-shell{width:min(920px,100%);display:grid;grid-template-columns:1.1fr .9fr;background:#fff;border-radius:18px;overflow:hidden;box-shadow:0 24px 70px #0c2a5526}.login-hero{background:linear-gradient(165deg,#0b2c5a,#061b3b);color:#fff;padding:34px 30px;display:flex;flex-direction:column;justify-content:space-between;gap:40px;min-height:430px}.login-hero .brand{padding:0}.login-hero h1{font:800 30px/1.25 Manrope;margin:0 0 10px;letter-spacing:-.5px}.login-hero p{color:#9fc0e6;margin:0}.login-hero small{color:#7291bb;font-size:10px}.login-card{padding:40px 34px;display:grid;gap:14px;align-content:center}.login-card h2{font:800 22px Manrope;margin:6px 0 0}.login-card .secondary{margin:0 0 6px;font-size:11px}.login-card .form-field label{font-size:11px}.login-card .form-field input{font-size:13px;padding:11px 12px}.login-card .btn{padding:12px;font-size:13px}.login-card .btn:disabled{opacity:.7;cursor:wait}.login-error{color:#c03844;font-size:11px;font-weight:600;min-height:15px}
@media(max-width:720px){.login-shell{grid-template-columns:1fr}.login-hero{min-height:auto;gap:18px;padding:24px}.login-hero h1{font-size:22px}.login-card{padding:28px 22px}.stats-4{grid-template-columns:repeat(2,1fr)}}
.brand-lft{display:block;padding:0 4px 26px}.brand-plate{background:#fff;border-radius:12px;padding:10px 12px;box-shadow:0 6px 18px #00102a55;display:flex;align-items:center;justify-content:center}.brand-logo{display:block;width:100%;height:auto}.brand-iso{display:none;width:38px;height:38px}.brand-lft .brand-sub{display:block;text-align:center;margin-top:10px;font-size:8px;letter-spacing:1.8px}
.mini-logo img{width:27px;height:27px;display:block}.login-logo{width:190px;height:auto;margin-bottom:4px}.hero-label{font-size:9px;letter-spacing:1.8px}
@media(max-width:820px){.brand-lft{padding:0 0 20px}.brand-plate{padding:6px;border-radius:10px}.brand-logo{display:none}.brand-iso{display:block}.brand-lft .brand-sub{display:none}}

.med-actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap;justify-content:flex-end}.med-sim{padding:7px 10px}.med-note{background:#fff8ec;border:1px solid #ffe2b8;color:#8a5a12;border-radius:10px;padding:10px 14px;font-size:11px;margin:-6px 0 14px}.med-note b{color:#6e4508}
.med-filters{padding:12px 14px}.med-filters .toolbar select{min-width:150px;max-width:210px}.med-crumbs{display:flex;align-items:center;gap:7px;flex-wrap:wrap;font-size:11px;margin-bottom:10px;color:#71829b}.med-crumbs button{border:0;background:#eef5ff;color:#1769cd;border-radius:6px;padding:4px 8px;font-size:11px;font-weight:700}.med-crumbs b{color:var(--ink)}
.med-kpis{grid-template-columns:repeat(6,minmax(140px,1fr))}.med-risk.red{border-color:#ffd3d6;background:#fffafa}.med-risk.orange{border-color:#ffe2b8}.med-risk.green{border-color:#cdeedd}
.med-map-panel{padding-bottom:12px}.med-map{height:470px;border-radius:10px;overflow:hidden;border:1px solid var(--line);background:radial-gradient(circle at 50% 40%,#f4f9ff,#e2edf9);z-index:0}.med-legend{display:grid;grid-template-columns:auto 1fr auto auto;gap:8px;align-items:center;margin-top:10px;font-size:10px;color:#576b87}.med-grad{display:block;height:9px;border-radius:9px;min-width:120px}
.seg{display:inline-flex;background:#f0f5fb;border:1px solid var(--line);border-radius:9px;padding:3px;gap:2px;flex-wrap:wrap}.seg button{border:0;background:transparent;border-radius:7px;padding:6px 10px;font-size:10px;font-weight:700;color:#557399}.seg button.on{background:#fff;color:#1265cf;box-shadow:0 2px 6px #1474e81f}.seg[hidden]{display:none}
.leaflet-tooltip.med-lbl{background:#ffffffe6;border:1px solid #d6e3f3;border-radius:7px;box-shadow:0 2px 8px #0c2a5522;padding:3px 7px;text-align:center;font-family:'DM Sans',sans-serif;color:#142b4e}.leaflet-tooltip.med-lbl::before{display:none}.med-lbl span{display:block;font-size:9px;font-weight:600;color:#5c7090}.med-lbl b{display:block;font:800 12px Manrope}
.med-table tbody tr.med-drill,.data-table tr.med-drill{cursor:pointer}.data-table tr.med-drill:hover td{background:#f6faff}.med-dual{display:flex;align-items:center;gap:7px}.med-dual .progress-line{position:relative;overflow:visible;min-width:90px}.med-dual .progress-line em{position:absolute;top:-3px;width:2px;height:13px;background:#0c2a55;border-radius:2px}.med-dual b{font-size:9px}
.med-bottom{grid-template-columns:minmax(0,1.6fr) minmax(300px,.9fr)}.med-pager{display:flex;justify-content:space-between;align-items:center;gap:10px}.med-pager .btn:disabled{opacity:.45;cursor:default}
.med-detail{display:grid;grid-template-columns:1fr 1fr;gap:10px 18px}.med-detail p{margin:0}.med-detail span{display:block;font-size:9px;color:#8a99ac;font-weight:700;text-transform:uppercase;letter-spacing:.4px}.med-detail b{font-size:12px}
button.kpi-banner{width:100%;border:0;text-align:left;font:inherit;cursor:pointer}.kpi-meduca{background:linear-gradient(110deg,#0b6b57,#1679db)}.kpi-meduca strong{font-size:16px}
@media(max-width:1200px){.med-kpis{grid-template-columns:repeat(3,1fr)}.med-bottom{grid-template-columns:1fr}}
@media(max-width:560px){.med-kpis{grid-template-columns:repeat(2,1fr)}.med-map{height:340px}.med-detail{grid-template-columns:1fr}.med-filters .toolbar select{max-width:none;flex:1 1 140px}}
@media print{.sidebar,.topbar,.med-actions,.med-filters .toolbar,.seg,.med-pager,#medSearch,#medOrden,.leaflet-control-container,.toast{display:none!important}.main-shell{margin:0}.content{padding:0;max-width:none}body{background:#fff}.panel,.stat-card{box-shadow:none;break-inside:avoid}.med-map{height:420px}.dashboard-grid{grid-template-columns:1fr}.med-kpis{grid-template-columns:repeat(3,1fr)}}
.med-map.leaflet-container{background:radial-gradient(circle at 50% 40%,#f4f9ff,#e2edf9);font-family:'DM Sans',sans-serif}.med-map .leaflet-control-attribution{font-size:9px;background:#ffffffb3}
.med-map.has-tiles.leaflet-container{background:#dfe9f3}
/* ===================== Responsive (tablet y móvil) ===================== */
.menu-toggle{display:none;border:1px solid var(--line);background:#fff;border-radius:9px;width:38px;height:38px;font-size:18px;color:#1d3f6b;flex:0 0 auto}
.nav-backdrop{display:none}
.dashboard-grid>*,.med-bottom>*,.form-grid>*{min-width:0}
.table-wrap{-webkit-overflow-scrolling:touch}
@media(max-width:900px){
  body{overflow-x:hidden}
  .menu-toggle{display:grid;place-items:center}
  .sidebar{width:264px;padding:20px 14px;transform:translateX(-105%);transition:transform .25s ease;z-index:40;box-shadow:12px 0 40px #00102a55;overflow-y:auto}
  body.nav-open .sidebar{transform:none}
  body.nav-open .nav-backdrop{display:block;position:fixed;inset:0;background:#07172c80;z-index:35}
  body.nav-open{overflow:hidden}
  .brand>span,.side-label,.nav-item,.nav-item:not(.active){font-size:14px}
  .side-label{font-size:9px}
  .nav-item{justify-content:flex-start;padding:12px 14px}
  .brand-lft{padding:0 4px 22px}.brand-plate{padding:10px 12px}.brand-logo{display:block}.brand-iso{display:none}.brand-lft .brand-sub{display:block}
  .sidebar-bottom{display:none}
  .main-shell{margin-left:0}
  .topbar{padding:0 14px;gap:10px}
  .page-brand{flex:1;min-width:0}.page-brand>div:last-child{min-width:0}.page-brand b{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .content{padding:18px 14px 32px}
  .dashboard-grid,.med-bottom{grid-template-columns:minmax(0,1fr)}
  .stats-grid,.med-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}
  .cards-grid,.module-cards{grid-template-columns:repeat(2,minmax(0,1fr))}
  .heading-row{flex-wrap:wrap;gap:12px}.heading-row>div:first-child{flex:1 1 220px;min-width:0}
  .med-actions{justify-content:flex-start}
  .panel-head{flex-wrap:wrap;gap:10px;align-items:flex-start}.panel-head>div:first-child{min-width:0}
  .toolbar{width:100%}.toolbar input,.toolbar select,.med-filters .toolbar select{flex:1 1 150px;width:auto;min-width:0;max-width:none}
  .kpi-banner{gap:12px;flex-wrap:wrap}
  .form-grid{grid-template-columns:1fr}
  .med-map{height:360px}
}
@media(max-width:560px){
  .topbar{height:60px;padding:0 10px;gap:8px}
  .mini-logo{display:none}
  .page-brand b{font-size:14px}
  .top-actions{gap:6px}
  .global-search{width:38px;height:38px;border:1px solid var(--line);padding:0;justify-content:center;flex:0 0 auto}
  .global-search input{display:block;width:0;padding:0}
  .global-search:focus-within{position:absolute;left:10px;right:10px;top:11px;width:auto;background:#fff;z-index:6;padding:0 11px;justify-content:flex-start;box-shadow:0 8px 24px #0c2a5522}
  .global-search:focus-within input{width:100%;font-size:14px}
  .user-pill{display:flex;padding:2px}.user-pill>div:not(.avatar),.user-pill>span{display:none}
  .content{padding:14px 10px 28px}
  .heading-row h1{font-size:20px}.heading-row .btn{flex:1 1 auto}
  .stats-grid,.med-kpis,.stats-4{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
  .stat-card{padding:11px 10px;gap:8px;align-items:flex-start}.stat-icon{width:32px;height:32px;font-size:16px;border-radius:10px;flex:0 0 auto}.stat-card strong{font-size:17px}.stat-card>div{min-width:0}
  .cards-grid,.module-cards{grid-template-columns:1fr}
  .panel{padding:13px}.table-panel{padding:0}.table-panel .panel-head{padding:13px 13px 6px}
  .data-table td,.data-table th{padding:9px 8px}
  .donut-row{flex-direction:column;align-items:stretch}.donut{margin:0 auto}
  .kpi-banner{padding:14px 16px}.kpi-banner strong{font-size:20px}
  .seg{width:100%}.seg button{flex:1 1 auto}
  .med-map{height:300px}
  .med-legend{grid-template-columns:1fr auto auto}.med-legend>span:first-child{grid-column:1/-1}
  .med-pager{flex-wrap:wrap}
  .med-crumbs{font-size:10px}
  .modal-backdrop{padding:6px;place-items:end center}
  .modal{max-height:96vh;border-radius:14px}
  .modal-head{padding:13px 14px}.modal-head h2{font-size:15px}
  .modal-body{padding:12px 10px}
  .form-fields{grid-template-columns:1fr}.form-field.full{grid-column:auto}
  .form-field input,.form-field select,.form-field textarea{font-size:16px}
  .form-foot{flex-wrap:wrap;padding:0 10px 14px}.form-foot .btn{flex:1 1 auto}.form-foot .spacer{display:none}
  .med-detail{grid-template-columns:1fr}
  .person-meta{flex-wrap:wrap;gap:6px}
  .toast{left:10px;right:10px;bottom:12px;text-align:center}
  .user-menu{right:-4px}
}
@media(max-width:360px){.stats-grid,.med-kpis,.stats-4{grid-template-columns:1fr}}

.team-filters{display:flex;align-items:center;gap:12px;flex-wrap:wrap;padding:12px 14px}.team-filters .toolbar{flex:1}.team-filters .toolbar input{width:240px}
.team-group{margin-bottom:18px}.team-group-head{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:0 2px 10px}.team-group-head h2{font:800 14px Manrope;margin:0}
#repPanels>.panel,#repPanels>.dashboard-grid{margin-bottom:15px}.rep-alerts{padding:0 14px 14px}

.text-green{color:#07845f}.fin-chart svg{width:100%;height:auto;display:block}.fin-chart-sm svg{max-height:200px}
.fin-legend{display:flex;gap:12px;font-size:10px;color:#576b87}.fin-legend span{display:flex;align-items:center;gap:5px}.fin-legend i{width:10px;height:10px;border-radius:3px;display:inline-block}
.fin-concepts td:not(:first-child),.fin-concepts th:not(:first-child){text-align:right}.fin-concepts tr.fin-total td{font-weight:800;background:#f7faff}
.fin-form{grid-template-columns:repeat(4,1fr)}.fin-form .form-field.full{grid-column:span 2}
@media(max-width:900px){.fin-form{grid-template-columns:1fr 1fr}}
@media(max-width:560px){.fin-form{grid-template-columns:1fr}.fin-form .form-field.full{grid-column:auto}}

/* Menú lateral: desplazamiento propio y versión compacta en pantallas bajas */
.sidebar{overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin}.sidebar nav{gap:3px}.nav-item{padding:10px 14px}
.nav-sep{padding:12px 13px 4px}
@media(max-height:900px){.sidebar-bottom{display:none}.brand,.brand-lft{padding-bottom:16px}}
@media(max-height:720px){.nav-item{padding:8px 14px}.side-label{padding-bottom:5px}.nav-sep{padding-top:8px}}
@media(max-height:800px){.brand-plate{padding:6px 10px}.brand-logo{width:150px;margin:0 auto}.brand-lft .brand-sub{margin-top:6px}}

/* Logo institucional (Gobierno Nacional · Ministerio de Educación) */
.gov-brand{display:flex;align-items:center;padding-left:20px;margin-left:20px;margin-right:auto;border-left:1px solid #e2eaf5;height:54px}
.gov-brand img{height:50px;width:auto;display:block}
.gov-brand-side{display:none;width:100%;height:auto;margin:-6px 0 18px;padding:0 4px}
.gov-brand-login{display:block;width:min(340px,100%);height:auto;margin-bottom:14px}
@media(max-width:1280px){.gov-brand img{height:40px}.gov-brand{padding-left:12px;margin-left:12px}}
@media(max-width:1100px){.global-search{width:200px}}
@media(max-width:900px){.gov-brand{display:none}.gov-brand-side{display:block}}
@media(max-width:720px){.gov-brand-login{width:240px}}

/* Ojito de contraseñas y verificación en vivo */
.pw-wrap{position:relative;display:block}.pw-wrap input{width:100%;padding-right:42px!important}
.pw-eye{position:absolute;right:4px;top:50%;transform:translateY(-50%);border:0;background:transparent;width:34px;height:34px;display:grid;place-items:center;color:#5c7090;cursor:pointer;border-radius:7px}
.pw-eye:hover,.pw-eye[aria-pressed="true"]{background:#eef3fb;color:#1d3f6b}.pw-eye svg{width:18px;height:18px}
.pw-reqs{list-style:none;padding:0;margin:0;display:grid;grid-template-columns:1fr 1fr;gap:5px 12px;font-size:10px;color:#7c8ba1}
.pw-reqs li::before{content:'○  '}.pw-reqs li.ok{color:#07845f;font-weight:700}.pw-reqs li.ok::before{content:'✓  '}.pw-reqs li.bad{color:#c6424b;font-weight:700}.pw-reqs li.bad::before{content:'✗  '}
input.pw-mismatch{border-color:#ed4c57!important;box-shadow:0 0 0 3px #ed4c5722}input.pw-match{border-color:#0ca77a!important;box-shadow:0 0 0 3px #0ca77a22}
@media(max-width:560px){.pw-reqs{grid-template-columns:1fr}}

/* Identidad MEDUCA en el menú lateral y el login */
.brand-meduca{display:block;text-align:center;padding:4px 6px 20px}.brand-meduca-logo{display:block;width:100%;max-width:200px;height:auto;margin:0 auto}
.brand-meduca .brand-sub{display:block;margin-top:12px;font-size:8px;letter-spacing:1.8px;color:#8bb1db}
.mini-flag{background:#fff;border:1px solid #e2eaf5}.mini-flag img{width:30px;height:auto}
.login-hero .gov-brand-login{width:min(260px,100%)}.login-card .login-logo{width:min(270px,100%)}
@media(max-height:800px){.brand-meduca-logo{max-width:160px}.brand-meduca{padding-bottom:14px}}
@media(max-width:720px){.login-hero .gov-brand-login{width:190px}}

/* Login: una sola imagen y pie "Desarrollado por" */
.login-body{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:16px}
.login-footer{font-size:11px;color:#71829b;text-align:center}.login-footer a{color:#1674e8;font-weight:700;text-decoration:none}.login-footer a:hover{text-decoration:underline}
