/* bcedata_grid/styles_final.css */

:root{
  --bg:#f6f7f9;
  --card:#fff;
  --text:#1b1f23;
  --muted:#6b7280;
  --line:#e5e7eb;
  --accent:#0b4aa2;
  --accent2:#0a3f8a;
  --bce-blue-900:#0B3A66;
  --bce-blue-800:#1F3A8A;
  --bce-line:#E6ECF5;
  --bce-text:#0F172A;
  --bce-muted:#64748B;
  --bce-hover:#F8FAFC;
  --bce-active:#F1F5F9;
  --bce-dark:#0B3A66;
  --bce-border:#E6EAF2;
  --bce-head:#F3F6FB;
  --bce-accent:#1F3A8A;
  --focus: rgba(11,100,200,.18);
  --bce-appbar-height:48px;
  --bce-bar-top:0px;
  --bce-overlay-top:48px;
  --bce-shell-top:48px;
  --bce-main-lift:32px;
}

*{box-sizing:border-box}
html,body{height:100%}
html{overflow:hidden;}
body{
  margin:0;
  font-family:system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,Noto Sans,sans-serif;
  color:var(--text);
  background:var(--bg);
  overflow:hidden;
}

/* App Bar */
.bce-appbar{
  position:fixed;
  top:var(--bce-bar-top); left:0; right:0;
  height:var(--bce-appbar-height);
  background:#253A73;
  color:#fff;
  border-bottom:1px solid rgba(255,255,255,.08);
  z-index:50;
}
.bce-appbar__inner{
  height:100%;
  display:flex;
  align-items:center;
  gap:14px;
  padding:0 18px;
}
.bce-appbar__menu{
  width:40px;
  height:40px;
  border-radius:12px;
  border:1px solid rgba(255,255,255,.22);
  background:transparent;
  color:#fff;
  display:grid;
  place-items:center;
  cursor:pointer;
  padding:0;
  outline:none;
}
.bce-appbar__menu:hover{background:rgba(255,255,255,.08)}
.bce-appbar__menu:focus{box-shadow:0 0 0 4px rgba(79,195,247,.22)}
.bce-ico{
  stroke:currentColor;
  stroke-width:2;
  stroke-linecap:round;
  stroke-linejoin:round;
  fill:none;
}
.bce-appbar__brand{
  display:flex;
  flex-direction:column;
  line-height:1.05;
  user-select:none;
}
.bce-appbar__title{
  font-size:20px;
  font-weight:700;
  letter-spacing:0.1px;
}
.bce-appbar__title span{color:#4FC3F7; font-weight:600}
.bce-appbar__subtitle{
  margin-top:2px;
  font-size:11.5px;
  font-weight:500;
  opacity:.85;
  color:#fff;
  letter-spacing:.2px;
}
.bce-appbar__right{
  margin-left:auto;
  display:flex;
  align-items:center;
  gap:10px;
}
.bce-appbar__logos{
  display:flex;
  align-items:center;
  gap:14px;
  min-height:48px;
  padding:0 2px 0 0;
  flex:0 0 auto;
}
.bce-appbar__logo-img{
  width:auto;
  display:block;
}
.bce-appbar__logo-img--primary{
  height:46px;
}
.bce-appbar__logo-img--secondary{
  height:44px;
}
.bce-appbar__badge{
  width:36px;
  height:36px;
  border-radius:10px;
  border:1px solid rgba(255,255,255,.16);
  display:grid;
  place-items:center;
  color:#fff;
}
.bce-appbar__badge svg{
  fill:transparent;
  stroke:currentColor;
  stroke-width:2;
  stroke-linecap:round;
  stroke-linejoin:round;
}

/* Drawer overlay */
.backdrop{
  position:fixed; inset:var(--bce-overlay-top) 0 0 0;
  background:rgba(0,0,0,.20);
  z-index:60;
}
.drawer{
  position:fixed;
  top:var(--bce-overlay-top); left:0; bottom:0;
  width:360px;
  max-width:92vw;
  background:#fff;
  border-right:1px solid #E6EAF2;
  z-index:70;
  overflow:hidden;
  transform:translateX(0);
  transition:transform .18s ease;
  box-shadow:0 12px 28px rgba(15,23,42,.10);
  display:flex;
  flex-direction:column;
}
.drawer-hidden{
  transform:translateX(-103%);
}
.drawer-head{
  padding:14px 16px 12px;
  border-bottom:0;
  background:#fff;
  position:sticky; top:0;
  z-index:2;
  display:flex;
  flex-direction:column;
}
.drawer-head__top{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:10px;
}
.drawer-title{
  margin:6px 0 2px 0;
  font-size:14px;
  font-weight:700;
  letter-spacing:.01em;
  color:var(--bce-blue-900);
  text-transform:uppercase;
  line-height:1.15;
}
.drawer-sub{
  margin:0;
  font-size:12.5px;
  font-weight:500;
  color:var(--bce-muted);
  padding-bottom:10px;
  border-bottom:1px solid var(--bce-line);
}
.drawer-close{
  width:28px;
  height:28px;
  flex:0 0 28px;
  border:1px solid #D8E1EE;
  border-radius:8px;
  background:#fff;
  color:#0B3A66;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  padding:0;
  font-size:20px;
  line-height:1;
  transition:background-color .16s ease, border-color .16s ease, color .16s ease;
}
.drawer-close:hover,
.drawer-close:focus,
.drawer-close:focus-visible{
  background:#EEF4FB;
  border-color:#AFC0DC;
  color:#0A2F52;
  outline:none;
}
.filter-wrap{
  position:relative;
  margin-top:10px;
}
.filter{
  width:100%;
  height:32px;
  padding:0 38px 0 32px;
  border:1px solid var(--bce-line);
  border-radius:10px;
  font-size:12.5px;
  font-weight:600;
  color:var(--bce-text);
  background:#fff;
  outline:none;
  margin-top:0;
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236B7A90' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><circle cx='11' cy='11' r='7'/><path d='M21 21l-4.3-4.3'/></svg>");
  background-repeat:no-repeat;
  background-position:10px center;
  background-size:14px 14px;
}
.drawer-head .filter{
  border-bottom-left-radius:10px;
  border-bottom-right-radius:10px;
}
.filter-clear{
  position:absolute;
  top:50%;
  right:8px;
  transform:translateY(-50%);
  width:20px;
  height:20px;
  border:0;
  border-radius:999px;
  background:#EAF1FB;
  color:#1F3A8A;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:14px;
  line-height:1;
  cursor:pointer;
  padding:0;
}
.filter-clear:hover,
.filter-clear:focus,
.filter-clear:focus-visible{
  background:#DCE8F8;
  color:#0B3A66;
  outline:none;
}
.filter-notice{
  margin-top:8px;
  padding:8px 10px;
  border:1px solid #E8B949;
  border-radius:10px;
  background:#FFF8E1;
  color:#7A5B00;
  font-size:12px;
  font-weight:600;
  line-height:1.3;
}
.drawer-head::after{
  content:'';
  margin-top:10px;
  height:1px;
  background:var(--bce-line);
}
.filter::placeholder{
  color:rgba(107,122,144,.85);
  font-weight:600;
}
.filter:focus{
  border-color:rgba(65,148,233,.60);
  box-shadow:0 0 0 4px rgba(65,148,233,.14);
}
.drawer-tabs{
  display:flex;
  gap:16px;
  padding:8px 16px 6px;
  border-bottom:1px solid var(--bce-line);
  background:#fff;
}
.drawer-tab{
  background:transparent;
  border:0;
  padding:6px 0;
  color:var(--bce-muted);
  font-size:12.5px;
  font-weight:700;
  cursor:pointer;
  border-bottom:2px solid transparent;
  transition:color .16s ease, border-color .16s ease, background-color .16s ease;
}
.drawer-tab:hover,
.drawer-tab:focus,
.drawer-tab:focus-visible{
  color:#0B3A66;
  background:rgba(65,148,233,.10);
  border-bottom-color:#4194E9;
  box-shadow:inset 0 -2px 0 #4194E9;
  outline:none;
}
.drawer-tab.is-active{
  color:var(--bce-blue-900);
  border-bottom-color:#0B3A66;
}
.drawer-tab:hover .tab-count,
.drawer-tab:focus .tab-count,
.drawer-tab:focus-visible .tab-count{
  color:#0B3A66;
}
.drawer-tab .tab-count{
  color:var(--bce-muted);
  font-weight:600;
  margin-left:6px;
}
.drawer-content{
  flex:1;
  overflow:auto;
}
.drawer-pane{display:none;}
.drawer-pane.is-active{display:block;}
.series-results{
  padding:10px 12px 16px;
  display:flex;
  flex-direction:column;
  gap:10px;
}
.series-item{
  display:flex;
  gap:10px;
  align-items:flex-start;
  border:1px solid #E2E8F0;
  border-radius:10px;
  background:#F9FBFF;
  padding:10px 12px;
}
.series-main{flex:1; min-width:0;}
.series-route{
  font-size:12px;
  font-weight:700;
  color:var(--bce-blue-900);
  line-height:1.2;
  word-break:break-word;
}
.series-cuadro{
  margin-top:4px;
  font-size:12px;
  color:var(--bce-muted);
}
.series-actions{
  display:flex;
  flex-direction:column;
  align-items:flex-end;
  gap:6px;
}
.series-actions a{
  font-size:12px;
  font-weight:700;
  color:#0B3A66;
  text-decoration:none;
  padding:4px 0;
}
.series-actions a:hover{ text-decoration:underline; }
.series-cart{
  width:26px;
  height:26px;
  border-radius:8px;
  border:1px solid #E2E8F0;
  background:#F8FAFC;
  color:#7A8CA8;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:0;
}
.series-cart::before{
  content:'';
  width:15px;
  height:15px;
  display:block;
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237A8CA8' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'><path d='M3 5h3l2.2 9.5a2 2 0 0 0 2 1.5h7.5a2 2 0 0 0 2-1.5L22 8H7'/><circle cx='10' cy='20' r='1.5'/><circle cx='18' cy='20' r='1.5'/></svg>");
  background-repeat:no-repeat;
  background-position:center;
  background-size:15px 15px;
}
.series-cart svg{
  display:none;
}
.series-cart:hover{
  background:#F1F5F9;
  border-color:#AFC0DC;
}
.series-cart:focus,
.series-cart:focus-visible,
.series-cart:active{
  background:#EAF1FB;
  border-color:#9EB5DA;
  outline:none;
  box-shadow:none;
}
.series-cart:hover::before,
.series-cart:focus::before,
.series-cart:focus-visible::before,
.series-cart:active::before{
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B3A66' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'><path d='M3 5h3l2.2 9.5a2 2 0 0 0 2 1.5h7.5a2 2 0 0 0 2-1.5L22 8H7'/><circle cx='10' cy='20' r='1.5'/><circle cx='18' cy='20' r='1.5'/></svg>");
}
.series-cart.is-added{
  background:#EAF1FB;
  border-color:#9EB5DA;
  color:#0B3A66;
}
.series-cart.is-added::before{
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B3A66' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'><path d='M3 5h3l2.2 9.5a2 2 0 0 0 2 1.5h7.5a2 2 0 0 0 2-1.5L22 8H7'/><circle cx='10' cy='20' r='1.5'/><circle cx='18' cy='20' r='1.5'/></svg>");
}
.series-empty{
  padding:14px 8px;
  font-size:12.5px;
  color:var(--bce-muted);
}

/* Shell */
.shell{
  position:fixed;
  top:var(--bce-overlay-top);
  left:0;
  right:0;
  bottom:0;
  padding-top:6px;
  overflow:hidden;
  z-index:1;
}
.main{
  height:100%;
  display:grid;
  grid-template-columns: 70% 30%;
  gap:12px;
  padding:0 12px 12px;
  margin-top:0;
}
body.grid-fullscreen .shell{overflow:hidden}
body.grid-fullscreen .main{
  grid-template-columns:1fr;
  padding:0;
  gap:0;
  margin-top:0;
}
body.grid-fullscreen .panel-right{display:none}
body.grid-fullscreen .panel-left{
  position:fixed;
  top:var(--bce-overlay-top); left:0; right:0; bottom:0;
  z-index:110;
  border-radius:0;
}
body.grid-fullscreen .backdrop{z-index:200}
body.grid-fullscreen .drawer{z-index:210}
body.panel-split-fullscreen .main{
  grid-template-columns:1fr;
  padding:0;
  gap:0;
  margin-top:0;
}
body.panel-split-fullscreen .panel-left{
  display:none;
}
body.panel-split-fullscreen .panel-right{
  position:fixed;
  top:var(--bce-overlay-top); left:0; right:0; bottom:0;
  z-index:110;
  border-radius:0;
}

/* Panels */
.panel{
  background:var(--card);
  border:1px solid var(--line);
  border-radius:14px;
  overflow:hidden;
  min-width:0;
  display:flex;
  flex-direction:column;
  min-height:0;
}
.panel-left{
  position:relative;
  overflow:visible;
}
.panel-right{
  background:#F8FAFC;
  border-left:1px solid #E5EAF3;
  position:relative;
  min-height:0;
}
 .panel-left .panel-body{
  overflow:hidden;
  border-bottom-left-radius:14px;
  border-bottom-right-radius:14px;
}
/* Panel Analisis (card institucional) */
.bce-panel{
  background:#FFFFFF;
  border:1px solid #E6EAF2;
  border-radius:12px;
  overflow:hidden;
  display:flex;
  flex-direction:column;
  height:100%;
  min-height:0;
}
.bce-panel__hd{
  padding:12px 16px;
  border-bottom:1px solid #E6EAF2;
  display:flex;
  align-items:center;
  justify-content:space-between;
}
body.admin-bar .bce-panel__hd{
  padding:10px 16px;
}
.bce-panel__actions{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
}
body.admin-bar .bce-panel__actions{
  gap:8px;
}
.bce-segment{
  display:inline-flex;
  align-items:center;
  gap:2px;
  height:32px;
  padding:0 2px;
  border:1px solid #E2E8F0;
  background:#F8FAFC;
  border-radius:8px;
}
.bce-segment__btn{
  border:0;
  background:transparent;
  color:#0F172A;
  font-size:12.5px;
  font-weight:500;
  padding:0 10px;
  height:28px;
  border-radius:7px;
  cursor:pointer;
}
.bce-segment__btn:hover,
.bce-segment__btn:focus,
.bce-segment__btn:focus-visible{
  background:#EEF2FF;
  color:#1F3A8A;
  outline:none;
}
.bce-segment__btn.is-active{
  background:#EEF2FF;
  color:#1F3A8A;
}
.bce-panel__title{
  font-size:17px;
  font-weight:800;
  letter-spacing:.01em;
  color:#0B3A66;
  line-height:1.05;
  text-shadow:0 1px 0 rgba(255,255,255,.45);
}
.bce-panel__title-row{
  display:flex;
  align-items:center;
  gap:8px;
}
.bce-collection-range{
  position:relative;
  display:inline-flex;
  align-items:center;
}
.bce-collection-range .menu{
  left:50%;
  right:auto;
  top:100%;
  margin-left:0;
  margin-top:8px;
  margin-right:0;
  transform:translateX(-50%);
  z-index:300;
}
.bce-panel__meta{
  font-size:12px;
  font-weight:600;
  color:#6B7A90;
}
.bce-controls{
  padding:12px 16px;
  border-bottom:1px solid #E6EAF2;
  display:flex;
  align-items:center;
  justify-content:flex-start;
  gap:6px;
  flex-wrap:wrap;
}
body.admin-bar .bce-controls{
  padding:10px 16px;
}
.bce-panel__body{
  padding:14px 16px 16px;
  min-height:260px;
  display:flex;
  flex-direction:column;
  gap:10px;
  flex:1;
  min-height:0;
  overflow:hidden;
}
body.admin-bar .bce-panel__body{
  padding:8px 14px 10px;
  gap:6px;
}
.bce-empty{
  height:260px;
  border:1px dashed rgba(11,58,102,.18);
  border-radius:12px;
  background:#FBFCFE;
  display:grid;
  place-items:center;
  text-align:center;
  padding:18px;
}
.bce-empty__title{
  font-size:13px;
  font-weight:700;
  color:#0B3A66;
  margin-bottom:6px;
}
.bce-empty__text{
  font-size:12px;
  font-weight:600;
  color:#6B7A90;
  max-width:280px;
}
.panel-left{position:relative}
.grid-logo{
  margin-left:auto;
  height:44px;
  width:auto;
  pointer-events:none;
}
.panel-head{
  padding:12px 12px 10px 12px;
  border-bottom:1px solid var(--line);
  background:#fff;
}
.panel-head.bce-grid-header{
  padding:0;
  border-bottom:0;
}
.panel-body{
  padding:12px;
  flex:1;
  min-height:0;
}
.cuadro-row{
  position:relative;
  z-index:1;
  display:flex;
  align-items:center;
  gap:10px;
  justify-content:space-between;
}
.bce-grid-header{
  background:#fff;
  border:1px solid #e6eaf2;
  border-radius:14px;
  overflow:visible;
  display:grid;
  grid-template-columns:auto auto 1fr auto;
  grid-template-rows:auto auto auto;
  column-gap:12px;
  row-gap:6px;
}
.bce-grid-header__title{
  background:#F6F8FB;
  border-bottom:1px solid #e6eaf2;
  padding:4px 8px 2px;
  gap:1px;
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  align-items:center;
  row-gap:1px;
  row-gap:0;
  align-content:center;
  min-height:28px;
  grid-column:1 / -1;
  grid-row:1;
}
.bce-grid-header__stack{
  grid-row:1;
  align-self:center;
}
.bce-grid-header__title .cuadro-title{
  font-weight:700;
  font-size:15.4px;
  letter-spacing:.2px;
  line-height:1.08;
  margin-top:0;
}
.bce-grid-header__stack{
  display:flex;
  flex-direction:column;
  gap:2px;
  align-items:flex-start;
  justify-content:center;
}
.bce-grid-header__namewrap{
  display:block;
}
.bce-grid-header__title-actions{
  grid-column:2;
  grid-row:1 / span 2;
  display:flex;
  align-items:center;
  gap:6px;
  justify-self:end;
}
.bce-grid-header__unit{
  grid-column:1;
  grid-row:2;
  margin-top:0;
  font-size:11.8px;
  line-height:1.08;
  color:#1F3A8A;
  padding-left:0;
  text-transform:none;
  font-variant:normal;
  font-variant-caps:normal;
}
.bce-grid-header__unit .unit-name{
  text-transform:none;
  font-variant:normal;
  font-variant-caps:normal;
}
.bce-grid-header__unit .unit-name{
  color:#1F3A8A;
  font-weight:650;
}
.bce-grid-header__code{font-weight:750;color:#0b3a66;white-space:nowrap}
.bce-grid-header__sep{color:#6b7a90;font-weight:700}
.bce-grid-header__name{font-weight:650;color:#1F3A8A}
.bce-grid-header__paren{font-weight:600;color:#243574}
.bce-grid-header__meta{
  padding:10px 8px 0 8px;
  color:#6b7a90;
  font-size:9.5px;
  display:grid;
  grid-template-columns:120px 80px 1fr;
  grid-auto-rows:auto;
  row-gap:2px;
  column-gap:16px;
  align-items:start;
  justify-content:start;
  width:100%;
  text-align:left;
  grid-column:1 / -1;
  grid-row:2;
}
.bce-meta-block{
  display:flex;
  flex-direction:column;
  gap:2px;
  padding-right:12px;
  border-right:1px solid #e6eaf2;
}
.bce-meta-block--periodo{
  width:120px;
  min-width:120px;
}
.bce-meta-block--frecuencia{
  width:80px;
  min-width:80px;
}
.bce-meta-block--unidad{
  min-width:0;
}
.bce-meta-label{
  font-size:10.5px;
  font-weight:600;
  color:#475569;
}
.bce-meta-block > :last-child{
  font-size:11px;
  font-weight:500;
  color:#0F172A;
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
}
.bce-meta-block:last-child{
  padding-right:0;
  border-right:0;
}
.bce-grid-header__meta-item strong{color:#0b3a66;font-weight:650}
.bce-grid-header__dot{color:#a7b4c8;font-weight:700}
.bce-grid-header__controls{
  padding:2px 8px 6px 8px;
  display:flex;
  gap:12px;
  align-items:flex-end;
  justify-content:space-between;
  grid-column:1 / -1;
  grid-row:3;
  align-self:end;
  justify-self:stretch;
  width:100%;
}
.bce-grid-header__selectors{
  display:flex;
  gap:8px;
  align-items:flex-end;
  flex-wrap:wrap;
  margin-left:0;
}
.bce-grid-header__control-group{
  display:flex;
  flex-direction:column;
  gap:4px;
  min-width:0;
}
.bce-grid-header__control-group--range{
  min-width:200px;
}
.bce-grid-header__control-label{
  font-size:10px;
  font-weight:600;
  color:#475569;
  line-height:1;
}
.bce-grid-header__range-tools{
  display:flex;
  align-items:center;
  gap:6px;
  min-height:30px;
}
.bce-grid-header__range-value{
  font-size:10.5px;
  font-weight:600;
  color:#0F172A;
  white-space:nowrap;
}
.bce-grid-header__divider{
  width:1px;
  align-self:stretch;
  background:#e6eaf2;
  min-height:34px;
  flex:0 0 1px;
}
.bce-grid-header__controls .bce-select{
  height:27px;
  min-width:130px;
  font-size:11px;
  font-weight:500;
  color:#0F172A;
  background:#F8FAFC;
  border:1px solid #E2E8F0;
  border-radius:7px;
  padding:0 7px;
}
.control-select{
  background:#F8FAFC;
  border:1px solid #E2E8F0;
  border-radius:8px;
  font-size:12.5px;
  font-weight:500;
  color:#0F172A;
}
.bce-grid-header__controls .bce-btn{
  background:#F8FAFC;
  border:1px solid #E2E8F0;
  border-radius:8px;
  color:#0F172A;
  font-weight:500;
}
.bce-grid-header__controls .bce-btn{
  height:28px;
  padding:0 10px;
  font-size:11px;
  gap:4px;
}
.bce-grid-header__controls .bce-caret{
  font-size:9px;
}
.bce-actions{
  display:flex;
  align-items:center;
  gap:8px;
}
.bce-actions__period{
  position:relative;
  display:flex;
  align-items:center;
}
.icon-action{
  width:30px;
  min-width:0;
  height:30px;
  border-radius:7px;
  background:#F8FAFC;
  border:1px solid #E2E8F0;
  color:#1F3A8A;
  display:grid;
  place-items:center;
  padding:0;
  cursor:pointer;
  transition:background-color .16s ease, border-color .16s ease, color .16s ease, box-shadow .16s ease;
}
.icon-action svg{
  width:14px;
  height:14px;
  fill:none;
  stroke:currentColor;
  stroke-width:1.5;
  stroke-linecap:round;
  stroke-linejoin:round;
}
.icon-action:hover{
  background:#EEF2FF;
  border-color:rgba(37,58,115,.28);
  color:#253A73;
}
.icon-action:focus,
.icon-action:focus-visible{
  background:#EEF2FF;
  border-color:#253A73;
  color:#253A73;
  outline:none;
  box-shadow:0 0 0 3px rgba(37,58,115,.16);
}
.icon-action:active,
.icon-action[aria-pressed="true"]{
  background:#253A73;
  border-color:#253A73;
  color:#fff;
  box-shadow:none;
}
.icon-action:disabled{
  opacity:.55;
  cursor:not-allowed;
}
.bce-actions__period .menu{
  left:50%;
  right:auto;
  top:100%;
  margin-left:0;
  margin-top:8px;
  margin-right:0;
  transform:translateX(-50%);
  z-index:300;
}
.bce-ibtn{
  width:30px;
  height:30px;
  border-radius:8px;
  background:#fff;
  border:1px solid var(--bce-border);
  display:grid;
  place-items:center;
  padding:0;
  cursor:pointer;
  transition:background-color .16s ease, border-color .16s ease, box-shadow .16s ease;
}
.bce-ibtn svg{
  fill:none;
  stroke:var(--bce-dark);
  stroke-width:2;
  stroke-linecap:round;
  stroke-linejoin:round;
}
.bce-ibtn:hover{
  background:#EEF2FF;
  border-color:rgba(37,58,115,.28);
}
.bce-ibtn:focus,
.bce-ibtn:focus-visible{
  background:#EEF2FF;
  border-color:#253A73;
  outline:none;
  box-shadow:0 0 0 3px rgba(37,58,115,.16);
}
.bce-ibtn:active,
.bce-ibtn[aria-pressed="true"]{
  background:#253A73;
  border-color:#253A73;
}
.bce-ibtn:active svg,
.bce-ibtn[aria-pressed="true"] svg{
  stroke:#fff;
}
.bce-cart{
  width:30px;
  height:30px;
  border-radius:8px;
  background:var(--bce-accent);
  border:none;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  padding:0;
}
.bce-ibtn svg,
.bce-cart svg{
  width:14px;
  height:14px;
  flex:0 0 14px;
}
.bce-cart svg{
  fill:none;
  stroke:#ffffff;
  stroke-width:2;
  stroke-linecap:round;
  stroke-linejoin:round;
}
.bce-cart:hover{
  background:#18307a;
}
.bce-cart:disabled{
  background:#1185E0;
  cursor:not-allowed;
}
.bce-cart:disabled svg{
  stroke:rgba(255,255,255,.75);
}
.bce-export{
  position:relative;
  font-family:system-ui,-apple-system,"Segoe UI",Roboto,Ubuntu,Cantarell,"Noto Sans",Arial,sans-serif;
  display:inline-block;
}
.bce-export__btn{
  height:36px;
  padding:0 12px;
  border-radius:12px;
  border:1px solid #E6EAF2;
  background:#fff;
  color:#0B3A66;
  font-size:13px;
  font-weight:650;
  display:inline-flex;
  align-items:center;
  gap:8px;
  cursor:pointer;
  user-select:none;
  outline:none;
}
.bce-export__btn:hover{
  background:#F3F6FB;
  border-color:rgba(11,58,102,.18);
}
.bce-export__btn:focus{
  border-color:rgba(11,100,200,.55);
  box-shadow:0 0 0 4px rgba(11,100,200,.18);
}
.bce-export__ico{
  width:18px;
  height:18px;
  display:grid;
  place-items:center;
  color:#243574;
}
.bce-export__caret{
  font-size:11px;
  color:#6B7A90;
  transform:translateY(-1px);
}
.bce-export__menu{
  position:absolute;
  top:calc(100% + 8px);
  left:50%;
  right:auto;
  transform:translateX(-50%);
  min-width:90px;
  background:#f3f6fb;
  border:1px solid #e6eaf2;
  border-radius:12px;
  box-shadow:0 8px 16px rgba(11,58,102,.10);
  padding:6px;
  display:none;
  z-index:60;
}
.bce-export__title{
  font-size:11px;
  font-weight:800;
  color:#6B7A90;
  letter-spacing:.6px;
  text-transform:uppercase;
  padding:2px 8px 8px 8px;
}
.bce-export__sep{
  height:1px;
  background:#E6EAF2;
  margin:6px 0;
}
.bce-export__item{
  width:100%;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:4px 6px;
  border-radius:10px;
  text-decoration:none;
  color:#0B3A66;
  border:1px solid #e6eaf2;
  background:#fff;
  cursor:pointer;
  text-align:center;
  font-size:10px;
  font-weight:600;
}
.bce-export__item:hover{
  background:rgba(65,148,233,.10);
  border-color:rgba(65,148,233,.22);
}
.bce-export__label{
  font-size:12.5px;
  font-weight:600;
}
.cuadro-title{
  font-weight:700;
  font-variant:small-caps;
  font-variant-numeric:oldstyle-nums;
  font-size:16px;
  letter-spacing:.3px;
}
.btn-fullscreen{
  position:relative;
  padding:4px 9px 4px 22px;
  min-width:0;
  font-size:6.8px;
  line-height:1.05;
  border-radius:7px;
  text-transform:none;
  letter-spacing:0;
  color:#253A73;
  background:#fff;
  border:1px solid rgba(37,58,115,.18);
  text-align:right;
  font-weight:500;
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23253A73' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'><path d='M4 10V4h6'/><path d='M20 10V4h-6'/><path d='M4 14v6h6'/><path d='M20 14v6h-6'/></svg>");
  background-repeat:no-repeat;
  background-position:7px center;
  background-size:7px 7px;
  transition:background-color .16s ease, border-color .16s ease, color .16s ease, box-shadow .16s ease;
}
.btn.btn-ghost.btn-fullscreen,
.btn-fullscreen:hover,
.btn-fullscreen:focus,
.btn-fullscreen:focus-visible{
  color:#253A73;
  background-color:#fff;
  border-color:rgba(37,58,115,.24);
  outline:none;
  box-shadow:none;
}
.btn-fullscreen:active,
.btn-fullscreen[aria-pressed="true"]{
  color:#fff;
  background-color:#253A73;
  border-color:#253A73;
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'><path d='M4 10V4h6'/><path d='M20 10V4h-6'/><path d='M4 14v6h6'/><path d='M20 14v6h-6'/></svg>");
}
.btn-fullscreen::before{
  content:none;
}
.cuadro-sub{
  font-size:12px;
  color:var(--muted);
  margin-top:4px;
  display:flex;
  align-items:flex-start;
  gap:10px;
  flex-wrap:nowrap;
  justify-content:flex-start;
  text-align:left;
  align-self:flex-start;
}
.cuadro-sub.bce-grid-header__meta{
  display:grid;
  grid-template-columns:auto auto auto;
  grid-auto-rows:auto;
  row-gap:2px;
  column-gap:16px;
  align-items:start;
  justify-content:start;
  width:100%;
}
.cuadro-sub .kv{
  display:flex;
  flex-direction:column;
  gap:2px;
}
.cuadro-sub .sep{
  display:inline-block;
  width:1px;
  height:26px;
  background:#e5e7eb;
  margin:0 2px;
}

.controls{
  margin-top:10px;
  display:flex;
  gap:10px;
  align-items:flex-end;
  flex-wrap:wrap;
}
.control{display:flex;flex-direction:column;gap:6px}
.control label{font-size:12px;color:var(--muted)}
select,input[type="month"]{
  height:32px;
  font-size:13px;
  font-weight:500;
  padding:8px 10px;
  border:1px solid var(--line);
  border-radius:10px;
  background:#fff;
  outline:none;
}
select:disabled{background:#f3f4f6;color:#9ca3af}
.control.inline{flex-direction:row;align-items:center; position:relative}
.control.inline.right{margin-left:auto}

.btn{
  padding:9px 12px;
  border-radius:10px;
  border:1px solid var(--line);
  background:#fff;
  cursor:pointer;
}
.btn:disabled{opacity:.55;cursor:not-allowed}
.btn-ghost:hover{border-color:#cbd5e1}
.btn-primary{
  background:#0B64C8;
  border-color:#0B64C8;
  color:#fff;
}
.btn-primary:hover{background:#0B64C8; border-color:#0B64C8}

#btnAplicar,
#btnApplyChart{
  height:26px;
  padding:0 8px;
  border-radius:6px;
  background:#0B64C8;
  border-color:#0B64C8;
  color:#fff;
  font-weight:600;
  font-size:11px;
  letter-spacing:.3px;
  text-transform:uppercase;
}
#btnAplicar{
  background:transparent;
  color:#0B64C8;
  text-align:center;
}
#btnTodo{
  background:transparent;
  color:#374151;
  text-align:center;
  text-transform:uppercase;
  font-weight:600;
  font-size:11px;
  letter-spacing:.3px;
}

body.has-inline-msg::before{
  content:'';
  position:fixed;
  inset:0;
  background:rgba(12, 16, 24, .35);
  backdrop-filter:blur(2px);
  z-index:99990;
}
.inline-msg{
  position:fixed;
  top:50%;
  left:50%;
  transform:translate(-50%, -50%);
  width:min(420px, calc(100% - 32px));
  border:1px solid #eab308;
  background:#fff9e6;
  border-radius:14px;
  padding:12px 14px;
  display:flex;
  gap:10px;
  align-items:flex-start;
  color:#7a5b00;
  box-shadow:0 18px 40px rgba(0,0,0,.18);
  z-index:100000;
}
body.panel-split-fullscreen .inline-msg{
  z-index:100000;
}
body.panel-split-fullscreen.has-inline-msg::before{
  z-index:99990;
}
.inline-msg .i{
  font-weight:700;
  width:22px;
  height:22px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:transparent;
  border:0;
  color:#d97706;
  font-size:18px;
  line-height:1;
  flex:0 0 auto;
}
#inlineText{
  font-size:13px;
  line-height:1.35;
}

/* Menu popups */
.menu{
  position:absolute;
  top:0;
  left:100%;
  margin-top:0;
  margin-left:8px;
  background:#fff;
  border:1px solid var(--line);
  border-radius:12px;
  padding:10px;
  box-shadow:0 10px 20px rgba(0,0,0,.08);
  z-index:120;
}
.menu-row{display:flex; align-items:center; justify-content:space-between; gap:10px; margin-bottom:8px}
.menu-row label{font-size:12px;color:var(--muted)}
.menu-item{
  width:100%;
  text-align:left;
  padding:9px 10px;
  border:0;
  border-radius:10px;
  background:#fff;
  cursor:pointer;
}
.menu-item:hover{background:#f3f4f6}

#btnTodo{
  width:18px;
  height:18px;
  accent-color:#0B64C8;
}

.menu .period-card{
  width:180px;
  background:#fff;
  border:1px solid #e6eaf2;
  border-radius:12px;
  box-shadow:0 8px 16px rgba(11,58,102,.10);
  overflow:hidden;
  color:#0b3a66;
}
.menu .period-card__header{
  display:flex;
  align-items:center;
  gap:8px;
  padding:4px 6px;
  background:#f3f6fb;
  border-bottom:1px solid #e6eaf2;
}
.menu .period-card__icon{
  width:18px;height:18px;
  display:grid;
  place-items:center;
  border-radius:6px;
  border:1px solid #e6eaf2;
  background:#fff;
  color:#243574;
  flex:0 0 auto;
}
.menu .period-card__title{
  font-size:9.5px;
  font-weight:650;
  letter-spacing:.2px;
  margin:0;
  color:#0b3a66;
}
.menu .period-card__body{padding:4px}
.menu .period-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:3px;
}
.menu .period-field{
  display:flex;
  flex-direction:column;
  gap:2px;
}
.menu .period-label{
  font-size:9px;
  font-weight:650;
  color:#0b3a66;
}
.menu .period-card select{
  height:18px;
  border:1px solid #e6eaf2;
  border-radius:8px;
  padding:0 4px;
  font-size:9.5px;
  color:#0b3a66;
  background:#fff;
  outline:none;
  appearance:auto;
}
.menu .period-card select:focus{
  border-color:rgba(11,100,200,.45);
  box-shadow:0 0 0 4px rgba(11,100,200,.22);
}
.menu .period-divider{
  height:1px;
  background:#e6eaf2;
  margin:2px 0;
}
.menu .period-radio{
  display:flex;
  align-items:center;
  gap:10px;
  padding:1px 2px 2px 2px;
}
.menu .period-radio input{
  width:11px;
  height:11px;
}
.menu .period-radio label{
  cursor:pointer;
  user-select:none;
  font-size:9px;
  font-weight:600;
  letter-spacing:.2px;
  color:#475569;
  text-transform:uppercase;
}
.menu .period-btn{
  width:100%;
  height:28px;
  padding:0;
  border-radius:6px;
  border:1px solid #1F3A8A;
  background:#1F3A8A;
  color:#fff;
  font-weight:600;
  letter-spacing:.2px;
  font-size:12.5px;
  line-height:1;
  text-transform:uppercase;
  cursor:pointer;
  transition:transform .06s ease, border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.btn#btnApplyChart{
  background:transparent;
  color:#243574;
}
.menu .period-btn:hover{
  border-color:rgba(11,100,200,.45);
  box-shadow:0 0 0 4px rgba(11,100,200,.22);
}
.menu .period-btn:active{transform:translateY(1px)}
.menu .period-btn:focus{
  outline:none;
  border-color:rgba(11,100,200,.55);
  box-shadow:0 0 0 4px rgba(11,100,200,.22);
}

#btnCuadro.menu-open{
  box-shadow:0 0 0 3px rgba(11,100,200,.22);
  border-color:#0B64C8;
}
#btnCollRange.menu-open{
  box-shadow:0 0 0 3px rgba(11,100,200,.22);
  border-color:#0B64C8;
}
#selFreq:focus,
#selUnit:focus{
  border-color:#0B64C8;
  box-shadow:0 0 0 3px rgba(11,100,200,.22);
}

/* Grid */
.grid-wrap{
  height:100%;
  min-height:0;
  background:#fff;
  border:1px solid #E6EAF2;
  border-radius:12px;
  overflow:hidden;
}
.grid-empty{
  height:100%;
  display:flex;
  align-items:center;
  justify-content:center;
  color:var(--muted);
  background:#fafafa;
  border:1px dashed var(--line);
  border-radius:12px;
}
.grid-scroll{
  height:100%;
  overflow:auto;
  background:#fff;
  border:0;
  border-radius:0;
  position:relative;
}
table.grid thead th{
  font-weight:600;
  font-size:10.5px;
  color:#475569;
  text-align:center;
  padding:6px 7px;
  white-space:nowrap;
  z-index:9;
}
table.grid thead{
  background-color:#F3F6FB;
  position:sticky;
  top:0;
  z-index:8;
}
table.grid tbody td{
  font-weight:400;
  font-size:10.2px;
  color:#12385f;
  padding:5px 7px;
  text-align:center;
  font-variant-numeric:tabular-nums;
}
table.grid tbody tr:nth-child(even){
  background-color:#FBFCFE;
}
table.grid tbody tr:hover td{
  background:rgba(11,100,200,.06);
}
table.grid td,
table.grid th{
  border-bottom:1px solid #E6EAF2;
  padding:0;
  font-size:inherit;
  background:transparent;
}
.col-serie{
  font-weight:600;
  font-size:11.2px;
  color:#0B3A66;
  text-align:left;
  padding-left:8px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.col-serie-sub{
  font-weight:500;
  color:#64748B;
  font-size:10.7px;
}
.level-1{padding-left:6px}
.level-2{padding-left:14px}
.level-3{padding-left:22px;color:#6B7A90}
.level-3{padding-right:10px}
table.grid{
  border-collapse:separate;
  border-spacing:0;
  width:max-content;
  letter-spacing:-0.25px;
}
table.grid th, table.grid td{
  border-bottom:1px solid #E6EAF2;
  padding:0;
  font-size:inherit;
  white-space:nowrap;
  background:transparent;
}
table.grid td{ text-align:center; }
table.grid td.sticky{ text-align:left; }
table.grid th{
  position:sticky; top:0;
  z-index:9;
  background:#F3F6FB;
  font-weight:500;
  box-shadow:inset 0 -1px 0 #E6EAF2;
}
table.grid td.sticky, table.grid th.sticky{
  position:sticky; left:0;
  z-index:7;
  background:#fff;
  border-right:1px solid var(--line);
}
table.grid th.sticky{
  top:0;
  background:#F3F6FB;
  z-index:11;
}
table.grid thead th.sticky{
  z-index:12;
}
table.grid tr.row-focus td{
  background:#FFF7D6;
}
table.grid tr.row-focus td.sticky{
  background:#FFF3C4;
}
table.grid tbody tr:nth-child(even) td.sticky{
  background:#FBFCFE;
}
table.grid tbody tr:hover td.sticky{
  background:#F3F6FB;
}
.row-cab td{background:#f7f9fc;font-weight:600}
.row-sep td{
  background:#fff;
  border-bottom:1px solid #E6EAF2;
  padding:5px 7px;
}
.cell-actions{display:flex;align-items:center;gap:6px}
.head-left{display:flex;align-items:center;gap:5px}
.dot{width:7px;height:7px;border-radius:999px;background:#cbd5e1;}
.cell-actions .chk{width:12px;height:12px}
.cell-actions .info{
  width:18px;height:18px;border-radius:6px;
  border:1px solid var(--line); background:#fff;
  cursor:pointer;
  font-size:0;
  padding:0;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  transition:background-color .16s ease, border-color .16s ease, box-shadow .16s ease;
}
.cell-actions .info::before{
  content:'i';
  font-size:10px;
  line-height:1;
  font-weight:700;
  color:#475569;
}
.cell-actions .info:hover,
.cell-actions .info:focus,
.cell-actions .info:focus-visible{
  background:#EEF2FF;
  border-color:rgba(37,58,115,.28);
  outline:none;
}
.cell-actions .info:hover::before,
.cell-actions .info:focus::before,
.cell-actions .info:focus-visible::before{
  color:#253A73;
}
.cell-actions .info:active,
.cell-actions .info[aria-pressed="true"]{
  background:#253A73;
  border-color:#253A73;
}
.cell-actions .info:active::before,
.cell-actions .info[aria-pressed="true"]::before{
  color:#fff;
}
.cell-actions .graph-mini{
  width:18px;height:18px;border-radius:6px;
  border:1px solid var(--line); background:#f8fafc;
  cursor:pointer; padding:0;
  display:inline-flex; align-items:center; justify-content:center;
  transition:background-color .16s ease, border-color .16s ease, box-shadow .16s ease;
}
.cell-actions .graph-mini::before{
  content:'';
  width:11px;height:11px;
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230b4aa2' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='3 16 9 10 13 14 21 6'/><line x1='3' y1='20' x2='21' y2='20'/></svg>");
  background-size:11px 11px;
  background-repeat:no-repeat;
}
.cell-actions .graph-mini:hover,
.cell-actions .graph-mini:focus,
.cell-actions .graph-mini:focus-visible{
  border-color:#253A73;
  background:#EEF2FF;
  outline:none;
  box-shadow:0 0 0 2px rgba(37,58,115,.14);
}
.cell-actions .graph-mini:active,
.cell-actions .graph-mini[aria-pressed="true"]{
  border-color:#253A73;
  background:#253A73;
  box-shadow:none;
}
.cell-actions .graph-mini:active::before,
.cell-actions .graph-mini[aria-pressed="true"]::before{
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='3 16 9 10 13 14 21 6'/><line x1='3' y1='20' x2='21' y2='20'/></svg>");
}
.badge{
  font-size:11px;
  padding:2px 8px;
  border-radius:999px;
  background:#eef2ff;
  color:#3730a3;
  border:1px solid #e0e7ff;
}

/* Tree */
.tree{
  padding:5px 6px 10px 6px;
  overflow:auto;
  background:#fff;
  flex:1;
  min-height:0;
}
.tree::-webkit-scrollbar{width:10px}
.tree::-webkit-scrollbar-track{background:#fff}
.tree::-webkit-scrollbar-thumb{
  background:#D7E1F0;
  border-radius:10px;
  border:2px solid #fff;
}
.tree::-webkit-scrollbar-thumb:hover{background:#C9D6EA}
.node{
  display:flex;
  align-items:center;
  gap:5px;
  padding:4px 6px;
  margin:1px 0;
  border-radius:7px;
  cursor:pointer;
  color:var(--bce-text);
  border:1px solid transparent;
  background:transparent;
  transition:background .12s ease, border-color .12s ease;
}
.node:hover{
  background:var(--bce-hover);
}
.node.active{
  background:var(--bce-active);
  border-color:transparent;
  position:relative;
}
.node.open{
  background:var(--bce-active);
}
.node.open .twisty{
  color:#475569;
}
.node.active::before{
  content:'';
  position:absolute;
  left:0;
  top:6px;
  bottom:6px;
  width:2px;
  border-radius:3px;
  background:var(--bce-blue-800);
}
.node.recent{outline:1px dashed #cbd5e1}
.twisty{
  width:13px;
  height:13px;
  flex:0 0 13px;
  display:grid;
  place-items:center;
  border-radius:5px;
  border:0;
  background:transparent;
  color:#475569;
  font-weight:800;
  font-size:11px;
  line-height:1;
}
.node.active .twisty{
  color:#475569;
}
.label{
  flex:1;
  font-size:11px;
  color:var(--bce-text);
  line-height:1.12;
}
.node.level-1 .label{
  font-size:10.4px;
  font-weight:600;
  letter-spacing:.005em;
  text-transform:uppercase;
  color:var(--bce-blue-900);
}
.node.section{
  margin:10px 4px 6px;
  padding:7px 10px 7px 13px;
  border-radius:7px;
  background:#F1F5FA;
  border:1px solid #D5E0EE;
  box-shadow:none;
  position:relative;
}
.node.section::before{
  content:'';
  position:absolute;
  left:0;
  top:6px;
  bottom:6px;
  width:3px;
  border-radius:3px;
  background:#123F7A;
}
.node.section:hover{
  background:#F1F5FA;
}
.node.level-section .label{
  font-size:10px;
  font-weight:800;
  letter-spacing:.12em;
  text-transform:uppercase;
  color:#123F7A;
  line-height:1.1;
}
.node.section .twisty{
  width:14px;
  height:14px;
  flex:0 0 14px;
  color:#123F7A;
  background:transparent;
  border-radius:0;
  font-size:11px;
}
.node.section.open{
  background:#F1F5FA;
}
.node.section + div{
  padding-left:6px !important;
  margin-bottom:4px;
}
.node.level-2{
  padding-left:15px;
}
.node.level-2 .label{
  font-size:10.7px;
  font-weight:600;
  color:#334155;
}
.node.level-3{
  padding-left:24px;
}
.node.level-3{
  padding-right:10px;
}
.node.level-3 .label{
  font-size:10.7px;
  font-weight:500;
  color:#0F172A;
  text-transform:none;
}
.node.level-4{
  padding-left:32px;
}
.node.level-4{
  padding-right:10px;
}
.node.level-4 .label{
  font-size:10.6px;
  font-weight:500;
  color:#0F172A;
  text-transform:none;
}
.node.group.level-1,
.node.group.level-1.open,
.node.group.level-1:hover{
  background:transparent;
  border-color:transparent;
}
.node.group.level-1 .twisty{
  color:#355070;
}
.node.cuadro .label{
  font-size:10.9px;
  font-weight:500;
  color:#0F172A;
}
.node.cuadro .label::before{
  content:'';
  display:inline-block;
  width:12px;
  height:12px;
  margin-right:4px;
  vertical-align:-1px;
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'><rect x='3' y='3' width='7' height='7'/><rect x='14' y='3' width='7' height='7'/><rect x='3' y='14' width='7' height='7'/><rect x='14' y='14' width='7' height='7'/></svg>");
  background-repeat:no-repeat;
  background-size:contain;
}

.tree-separator{
  height:1px;
  background:var(--bce-line);
  margin:10px 6px;
}

/* Right panel (chart fixed + collection scroll) */
.panel-right .panel-body{
  display:flex;
  flex-direction:column;
  height:100%;
  min-height:0;
}
.right-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom:10px;
}
.right-title{font-weight:700}
.panel-title{
  font-size:14px;
  font-weight:600;
  letter-spacing:.02em;
}
.toggle{display:flex;align-items:center;gap:8px;color:var(--muted);font-size:12px}

#chartBox{
  height:300px;
  flex:0 0 300px;
  border:1px dashed var(--line);
  border-radius:12px;
  background:#fafafa;
  overflow:hidden;
  display:flex;
  align-items:center;
  justify-content:center;
  color:var(--muted);
}
body.admin-bar #chartBox{
  height:208px;
  flex:0 0 208px;
}
#chartBox.chart{padding:10px}
#chartBox.chart{
  border-style:solid;
  background:#fff;
  padding:10px;
  display:block;
  overflow:visible;
}
#chart{
  width:100%;
  height:100%;
}
.collection-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-top:12px;
  padding-top:10px;
  border-top:1px solid var(--line);
}
.collection-title{font-weight:700}
.collection-foot{font-size:12px;color:var(--muted)}
.collection{
  margin-top:8px;
  border:1px solid var(--line);
  border-radius:12px;
  overflow:auto;
  flex:1;
  min-height:0;
  background:#fff;
}
.collection.collection-empty{
  display:flex;
  align-items:center;
  justify-content:center;
  text-align:center;
  color:var(--muted);
  font-size:12px;
  font-weight:600;
  padding:0;
  background:#fafafa;
  border:1px dashed var(--line);
  border-radius:12px;
  min-height:300px;
}
body.admin-bar .collection.collection-empty{
  min-height:132px;
}

/* Panel derecho dividido: coleccion izquierda / grafico derecha */
body.panel-split .panel-right .bce-panel__body{
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(0,1fr);
  grid-template-rows:minmax(0,1fr) auto;
  gap:12px;
}
body.panel-split #chartBox{
  grid-column:2;
  grid-row:1 / span 2;
  height:auto;
  flex:1 1 auto;
}
body.panel-split .collection{
  grid-column:1;
  grid-row:1;
  margin-top:0;
}
body.panel-split .collection-actions{
  grid-column:1;
  grid-row:2;
  margin-top:0;
}
.item{
    display:grid;
    grid-template-columns: 18px 1fr 88px 34px 34px;
    gap:8px;
    align-items:center;
  padding:10px;
  border-bottom:1px solid var(--line);
}
.item b{
  font-size:12px;
  font-weight:600;
}
.item:last-child{border-bottom:0}
.item .series-head{display:flex;align-items:baseline;gap:4px;line-height:1.05;margin-bottom:0}
.item .series-name{font-size:12px;font-weight:400;line-height:1.05}
.item .ruta{font-size:10.5px;color:var(--muted); margin-top:0;line-height:1.1}
.item .cuadro-meta{font-size:9.75px;color:var(--muted); margin-top:1px;line-height:1.15}
.item .meta{font-size:10px;color:var(--muted);line-height:1.05;white-space:nowrap}
.item .unit{font-size:11px;color:#111827; text-align:right}
.item .trash, .item .graphbtn{
  width:32px;height:32px;border-radius:10px;
  border:1px solid var(--line);
  background:#fff;
  cursor:pointer;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:0;
}
.item .trash:hover, .item .graphbtn:hover{border-color:#cbd5e1}
.item .graphbtn.active{
  border-color:var(--accent);
  box-shadow:0 0 0 2px rgba(11,74,162,.12);
}
.item .graphbtn::before{
  content:'';
  width:14px;height:14px;
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230b4aa2' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='3 16 9 10 13 14 21 6'/><line x1='3' y1='20' x2='21' y2='20'/></svg>");
  background-size:14px 14px;
  background-repeat:no-repeat;
}
.item .trash::before{
  content:'';
  width:14px;height:14px;
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='3 6 5 6 21 6'/><path d='M8 6V4h8v2'/><path d='M19 6l-1 14H6L5 6'/><line x1='10' y1='11' x2='10' y2='17'/><line x1='14' y1='11' x2='14' y2='17'/></svg>");
  background-size:14px 14px;
  background-repeat:no-repeat;
}

.collection-actions{
  display:flex;
  gap:8px;
  justify-content:flex-start;
  align-items:center;
  flex-wrap:nowrap;
  overflow-x:auto;
  margin-top:6px;
  padding-bottom:2px;
}
body.admin-bar .collection{
  margin-top:6px;
}
body.admin-bar .collection-actions{
  gap:8px;
  margin-top:6px;
}
.collection-actions__sort{
  min-width:0;
  flex:0 1 auto;
}
.collection-actions__sort .bce-segment{
  gap:4px;
  padding:2px;
  flex-wrap:nowrap;
}
.collection-actions__sort .bce-segment__btn{
  border:1px solid #D8E1EE;
  background:#fff;
  color:#0F172A;
}
.collection-actions__sort .bce-segment__btn:hover,
.collection-actions__sort .bce-segment__btn:focus,
.collection-actions__sort .bce-segment__btn:focus-visible{
  border-color:#AFC0DC;
  background:#F3F7FD;
  color:#1F3A8A;
}
.collection-actions__sort .bce-segment__btn.is-active{
  border-color:#9EB5DA;
  background:#EAF1FB;
  color:#1F3A8A;
}
.collection-actions__buttons{
  display:flex;
  align-items:center;
  justify-content:flex-start;
  gap:8px;
  flex-wrap:nowrap;
  margin-left:0;
  flex:0 0 auto;
}
.chart-quick-range{
  display:flex;
  gap:5px;
  align-items:center;
  position:absolute;
  top:12px;
  right:44px;
  z-index:3;
}
.chart-quick-range.is-disabled{
  opacity:0.45;
  pointer-events:none;
}
.chart-quick-btn{
  border:1px solid #E2E8F0;
  background:#fff;
  color:#0B3A66;
  font-size:10.5px;
  font-weight:600;
  padding:4px 8px;
  border-radius:8px;
  cursor:pointer;
  transition:background-color .16s ease, border-color .16s ease, color .16s ease, box-shadow .16s ease;
}
.chart-quick-btn:hover,
.chart-quick-btn:focus,
.chart-quick-btn:focus-visible{
  background:#EAF1FB;
  border-color:#9EB5DA;
  color:#1F3A8A;
  outline:none;
  box-shadow:0 0 0 3px rgba(31,58,138,.10);
}

#chartBox{ position:relative; }
#btnDownloadSeries,
#btnClearSeries{
  height:32px;
  padding:0 10px;
  font-size:12.5px;
  font-weight:500;
  color:#0F172A;
  background:#F8FAFC;
  border:1px solid #E2E8F0;
  border-radius:8px;
}

/* Responsive */
@media (max-width: 900px) {
  html{
    overflow-y:auto;
  }
  body{
    overflow:visible;
  }
  .shell{
    position:static;
    top:auto;
    left:auto;
    right:auto;
    bottom:auto;
    height:auto;
    min-height:calc(100vh - var(--bce-overlay-top));
    padding-top:6px;
    overflow:visible;
    z-index:auto;
  }
  .main{
    grid-template-columns:1fr;
    height:auto;
  }
  .panel-right{
    order:2;
  }
  .panel-left{
    order:1;
  }
  .panel{
    border-radius:12px;
  }
  #chartBox{
    height:260px;
    flex:0 0 260px;
  }
  .collection{
    max-height:320px;
  }
  body.panel-split .panel-right .bce-panel__body{
    grid-template-columns:1fr;
    grid-template-rows:auto auto auto;
  }
  body.panel-split .collection{
    grid-column:1;
    grid-row:1;
    max-height:none;
  }
  body.panel-split .collection-actions{
    grid-column:1;
    grid-row:2;
  }
  body.panel-split #chartBox{
    grid-column:1;
    grid-row:3;
  }
  .controls{
    gap:8px;
  }
  .control.inline.right{
    margin-left:0;
  }
  .drawer{
    width:100%;
  }

}

@media (max-width: 600px) {
  .bce-appbar__inner{
    align-items:flex-start;
  }
  .bce-appbar__brand{
    align-items:flex-start;
  }
  .bce-grid-header__meta{
    grid-template-columns: repeat(3, minmax(0, 1fr));
    column-gap:8px;
    row-gap:6px;
  }
  .bce-grid-header__stack{
    align-items:flex-start;
  }
  .bce-grid-header__unit{
    grid-column:1 / -1;
    grid-row:2;
    margin-top:4px;
    font-size:10.5px;
    padding-left:0 !important;
    text-align:left;
    justify-self:start;
  }
  .bce-grid-header__selectors{
    margin-left:0;
    width:100%;
    gap:8px;
    align-items:stretch;
  }
  .bce-grid-header__title .cuadro-title{
    line-height:1.2 !important;
    margin-top:0;
  }
  .bce-grid-header__namewrap{
    display:block;
    max-width:100%;
    line-height:1.2;
  }
  .bce-grid-header__code{
    display:block;
    margin-bottom:2px;
    font-size:12px;
    font-weight:700;
  }
  .bce-grid-header__name,
  .bce-grid-header__paren{
    display:-webkit-box;
    -webkit-box-orient:vertical;
    -webkit-line-clamp:2;
    overflow:hidden;
    text-overflow:ellipsis;
    line-height:1.2;
  }
  .bce-grid-header__title .cuadro-title{
    display:block;
    align-items:initial;
  }
  .bce-grid-header__controls{
    flex-direction:column;
    row-gap:8px;
    justify-items:start;
    justify-content:start;
    align-items:stretch;
    grid-column:1 / -1;
    grid-row:3;
  }
  .bce-grid-header__control-group,
  .bce-grid-header__control-group--range{
    width:100%;
  }
  .bce-grid-header__range-tools{
    flex-wrap:wrap;
  }
  .bce-grid-header__range-value{
    white-space:normal;
  }
  .bce-grid-header__divider{
    display:none;
  }
  .bce-grid-header__title-actions{
    justify-self:start;
  }
  .bce-grid-header__title .btn-fullscreen{
    min-width:0;
    padding:3px 6px 3px 17px;
    font-size:6.1px;
    white-space:nowrap;
    justify-self:start;
    grid-column:1;
    grid-row:3;
    background-position:5px center;
    background-size:6px 6px;
  }
  .collection-actions{
    justify-content:flex-start;
    flex-wrap:nowrap;
    overflow-x:auto;
  }
  .collection-actions__sort,
  .collection-actions__buttons{
    width:auto;
    margin-left:0;
    justify-content:flex-start;
  }
  .bce-grid-header__title .btn-fullscreen:hover,
  .bce-grid-header__title .btn-fullscreen:focus,
  .bce-grid-header__title .btn-fullscreen:focus-visible{
    color:#253A73;
  }
  .icon-action,
  .bce-ibtn,
  .bce-cart{
    width:32px;
    height:32px;
    border-radius:8px;
  }
  .main{
    padding:0 10px 10px;
    gap:10px;
    margin-top:-12px;
  }
  .cuadro-row{
    flex-wrap:wrap;
    gap:8px;
  }
  .cuadro-sub{
    display:flex;
    flex-wrap:wrap;
    gap:6px;
  }
  .controls{
    flex-direction:column;
    align-items:stretch;
  }
  .control,
  .control.inline{
    width:100%;
  }
  .control.inline{
    justify-content:space-between;
  }
  .grid-scroll{
    overflow:auto;
    -webkit-overflow-scrolling:touch;
  }
  .item{
    grid-template-columns: 18px 1fr 70px 32px 32px;
  }
  .chart-series{
    height:300px;
  }
  .bce-panel__actions .btn-fullscreen{
    padding:6px 10px;
    min-width:0;
  }
}

/* Modals */
.modal{
  position:fixed;
  inset:0;
  background:rgba(0,0,0,.25);
  display:flex;
  align-items:center;
  justify-content:center;
  z-index:90;
}
body.grid-fullscreen .modal{
  z-index:99999;
}
body.panel-split-fullscreen .modal{
  z-index:99999;
}
.modal-card{
  width:min(560px, calc(100vw - 24px));
  background:#fff;
  border:1px solid var(--line);
  border-radius:10px;
  overflow:hidden;
}
.modal-head{
  padding:7px 9px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  border-bottom:1px solid var(--line);
}
.modal-title{font-weight:700;font-size:12px}
.modal-body{padding:7px 9px}
.chart-modal{width:min(920px, calc(100vw - 24px))}
.chart-toolbar{
  display:flex;
  gap:8px;
  align-items:flex-end;
  flex-wrap:wrap;
  margin-bottom:8px;
}
.chart-field{display:flex;flex-direction:column;gap:4px}
.chart-field label{font-size:10.5px;color:var(--muted)}
.chart-toolbar select,
.chart-toolbar input[type="month"]{
  height:34px;
  font-size:11px;
  padding:6px 9px;
}
#btnApplyChart{
  height:34px;
  padding:0 10px;
  font-size:10px;
}
.chart-series{
  height:360px;
  border:1px solid var(--line);
  border-radius:12px;
  background:#fff;
}
.meta-grid{
    display:grid;
    grid-template-columns: 96px minmax(0, 1fr);
    gap:3px 6px;
  }
.meta-grid .k{color:var(--muted);font-size:8.5px}
.meta-grid .v{font-size:8.5px;font-style:normal;color:#0f172a;line-height:1.25}
.meta-grid .k{
  background:#f3f6fb;
  border-radius:2px;
  padding:1px 3px;
  align-self:start;
}
.meta-def{display:flex;align-items:flex-end;gap:5px}
.meta-def-text{
  flex:1 1 auto;
  min-width:0;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
  text-align:justify;
  line-height:1.18;
}
.meta-def-text--full{
  display:block;
  -webkit-line-clamp:unset;
  -webkit-box-orient:unset;
  overflow:visible;
}
.meta-def-more{
  border:0;
  background:transparent;
  color:#1b4d8a;
  cursor:pointer;
  font-size:9px;
  font-weight:700;
  text-decoration:underline;
  text-underline-offset:1px;
  padding:0;
  white-space:nowrap;
  align-self:flex-end;
}
.meta-def-pop{
    position:absolute;
    z-index:2;
    background:#fff;
    border:1px solid #e5e7eb;
    border-radius:4px;
    box-shadow:0 10px 24px rgba(0,0,0,.12);
    max-height:50vh;
    overflow:auto;
    padding:5px 7px;
    max-width:250px;
  }
.meta-def-pop-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:6px;
  font-weight:600;
  font-size:10px;
  line-height:1.1;
  margin-bottom:2px;
}
.meta-def-pop-close{
  border:0;
  background:transparent;
  cursor:pointer;
  font-size:11px;
  line-height:1;
  width:14px;
  min-width:14px;
  height:14px;
  padding:0;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  color:#334155;
  flex:0 0 14px;
}
.meta-def-pop-body{font-size:9.5px;line-height:1.2;color:#0f172a;text-align:justify}

/* Download panel content */
.dl-grid{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:10px 12px;
}
.dl-row{display:flex;flex-direction:column;gap:6px}
.dl-row label{
  font-size:12px;
  font-weight:600;
  color:#475569;
}
.dl-row select{
  height:34px;
  font-size:12px;
  font-weight:500;
  color:#0F172A;
  border:1px solid #D9E2EF;
  border-radius:10px;
  background:#fff;
  padding:0 36px 0 12px;
}
.dl-row.dl-check{
  grid-column:1 / -1;
  flex-direction:row;
  align-items:center;
}
.dl-row.dl-check label{
  display:flex;
  align-items:center;
  gap:8px;
}
.dl-actions{grid-column:1 / -1; display:flex; justify-content:flex-end; padding-top:6px}
.dl-compact .dl-row-range{display:none}

/* Popover de metadatos (anclado al icono de info) */
.popover{
  position:absolute;
  z-index:60;
  width:min(320px, calc(100vw - 16px));
  min-width:220px;
  max-width:320px;
  background:#fff;
  border:1px solid #e5e7eb;
  border-radius:5px;
  box-shadow:0 10px 30px rgba(0,0,0,.12);
  padding:4px 6px;
  color:#0f172a;
  max-height:calc(100vh - 24px);
  overflow-y:auto;
}
body.grid-fullscreen .popover{
  z-index:99999;
  position:fixed;
}
.popover .t{font-weight:700;font-size:10px;margin-bottom:4px}
.popover .row{display:grid;grid-template-columns:82px 1fr;gap:4px;margin:3px 0}
.popover .k{color:#64748b;font-size:9px}
.popover .v{font-size:9.5px;word-break:break-word}


/* Chart always on: hide toggle */
.toggle { display: none !important; }

/* Metadata popover (sober, Banxico-like) */
.meta-pop .meta-head{
  display:flex; align-items:center; justify-content:space-between;
  gap:6px; margin-bottom:4px;
}
.meta-pop .t{ font-weight:700; font-size:10px; color:#111; letter-spacing:.1px; max-width:210px; }
.meta-pop button.x{
  border:0; background:transparent; cursor:pointer;
  width:16px; height:16px; line-height:16px;
  border-radius:4px; font-size:13px; color:#444;
}
.meta-pop button.x:hover{ background:#f1f3f5; }

.bce-instant-tooltip{
  position:fixed;
  z-index:100000;
  max-width:min(260px, calc(100vw - 16px));
  padding:7px 9px;
  border-radius:8px;
  background:linear-gradient(180deg, #0B3A66 0%, #0A2F52 100%);
  border:1px solid rgba(17, 105, 189, .42);
  color:#F8FBFF;
  font-size:11px;
  line-height:1.2;
  box-shadow:0 10px 24px rgba(11, 58, 102, .22);
  pointer-events:none;
  white-space:normal;
}
.bce-instant-tooltip[hidden]{
  display:none !important;
}


