:root{--navy:#071d3a;--navy2:#0c2d56;--blue:#2365c7;--bg:#f4f7fb;--card:#fff;--line:#e1e7f0;--text:#14233a;--muted:#6d7889;--green:#16834e;--red:#c43c36;--orange:#c97818;--purple:#7056c7}
*{box-sizing:border-box}body{margin:0;font-family:Inter,Segoe UI,Arial,sans-serif;background:var(--bg);color:var(--text)}
a{text-decoration:none;color:inherit}.layout{min-height:100vh;display:grid;grid-template-columns:250px 1fr}
.sidebar{background:linear-gradient(180deg,#071d3a,#0a2a50);color:#fff;padding:22px 14px;position:sticky;top:0;height:100vh;overflow:auto}
.admin-brand{display:flex;align-items:center;gap:11px;padding:5px 8px 24px;font-weight:900;line-height:1}.admin-brand img{width:47px;height:47px;border-radius:50%;object-fit:cover;background:#fff}
.side-label{font-size:10px;text-transform:uppercase;letter-spacing:1.3px;color:#89a1bf;margin:18px 12px 8px}
.navlink{display:flex;align-items:center;gap:11px;padding:11px 12px;border-radius:9px;margin:3px 0;color:#dbe6f5;font-size:13px;font-weight:650}.navlink:hover,.navlink.active{background:#17477f;color:#fff}
.side-bottom{margin-top:30px;padding-top:20px;border-top:1px solid rgba(255,255,255,.10);font-size:12px;color:#c5d2e4}.side-bottom b{color:#fff;display:block;margin-bottom:4px}
.content{min-width:0}.topbar{height:76px;background:#fff;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;padding:0 28px;position:sticky;top:0;z-index:20}
.topbar h1{font-size:22px;margin:0}.topbar .sub{font-size:12px;color:var(--muted);margin-top:4px}
.userchip{font-size:12px;color:#526279;text-align:right}.userchip b{display:block;color:#132640}
.page{padding:28px;max-width:1500px;margin:auto}.flash{padding:13px 15px;border-radius:10px;margin-bottom:20px;font-size:13px;font-weight:650}.flash.ok{background:#e9f7ef;color:#116a3d;border:1px solid #cbead8}.flash.err{background:#fff0ef;color:#a62f2a;border:1px solid #f2cfcc}
.cards{display:grid;grid-template-columns:repeat(4,1fr);gap:16px;margin-bottom:22px}.stat{background:#fff;border:1px solid var(--line);border-radius:13px;padding:19px;box-shadow:0 5px 18px rgba(15,43,79,.04)}.stat small{color:#6a7789;font-size:10px;font-weight:800;text-transform:uppercase}.stat strong{font-size:29px;display:block;margin:8px 0 3px}.stat span{font-size:12px;color:#2365c7}
.grid2{display:grid;grid-template-columns:1.2fr .8fr;gap:18px}.grid-half{display:grid;grid-template-columns:1fr 1fr;gap:18px}
.card{background:#fff;border:1px solid var(--line);border-radius:13px;box-shadow:0 5px 18px rgba(15,43,79,.04);overflow:hidden}.card-head{padding:16px 18px;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;gap:12px}.card-head h2{font-size:15px;margin:0}.card-body{padding:18px}
.table-wrap{overflow:auto}table{width:100%;border-collapse:collapse;font-size:12px}th{text-align:left;padding:11px 10px;color:#617086;font-size:10px;text-transform:uppercase;border-bottom:1px solid var(--line);white-space:nowrap}td{padding:12px 10px;border-bottom:1px solid #edf1f6;vertical-align:middle}tr:last-child td{border-bottom:0}
.avatar{width:38px;height:38px;border-radius:50%;object-fit:cover;background:#eaf1fb;display:grid;place-items:center;font-weight:800;color:#2365c7}.person{display:flex;align-items:center;gap:10px}.person b{display:block}.person small{display:block;color:#7b8798;margin-top:2px}
.badge{display:inline-block;padding:5px 8px;border-radius:999px;font-size:10px;font-weight:800;background:#eef3fb;color:#275b9c}.badge.green{background:#e5f5eb;color:#157342}.badge.red{background:#fee9e7;color:#a5332d}.badge.orange{background:#fff0df;color:#a75a0d}.badge.purple{background:#efeafd;color:#6048af}
.btn{display:inline-flex;align-items:center;justify-content:center;gap:7px;border:0;background:#2365c7;color:white;border-radius:8px;padding:10px 13px;font-size:12px;font-weight:800;cursor:pointer}.btn.secondary{background:#fff;color:#214d85;border:1px solid #b9cbe2}.btn.danger{background:#c43c36}.btn.ghost{background:#edf3fb;color:#28598e}.btn.sm{padding:7px 9px;font-size:11px}
.toolbar{display:flex;align-items:center;gap:9px;flex-wrap:wrap}.filters{display:grid;grid-template-columns:2fr repeat(3,1fr);gap:10px;margin-bottom:16px}
input,select,textarea{width:100%;border:1px solid #cfd8e6;border-radius:8px;padding:10px 11px;font:inherit;font-size:13px;background:#fff;color:#17263b;outline:none}input:focus,select:focus,textarea:focus{border-color:#4d82d2;box-shadow:0 0 0 3px rgba(35,101,199,.10)}textarea{min-height:105px;resize:vertical}
label{display:block;font-size:11px;font-weight:800;color:#43526a;margin-bottom:6px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:13px}.form-grid .full{grid-column:1/-1}.form-actions{display:flex;justify-content:flex-end;gap:9px;margin-top:16px;padding-top:15px;border-top:1px solid var(--line)}
.section-note{font-size:12px;color:#6f7c8e;line-height:1.55;margin-top:0}.empty{padding:28px;text-align:center;color:#778499;font-size:13px}
.photo-preview{width:110px;height:110px;border-radius:50%;object-fit:cover;background:#edf3fb;border:4px solid #fff;box-shadow:0 0 0 1px #dce4ef}
.kpi-icon{font-size:22px}.split-list{display:grid;gap:9px}.item{display:flex;justify-content:space-between;gap:12px;align-items:center;padding:11px 0;border-bottom:1px solid #edf1f6}.item:last-child{border-bottom:0}.item b{font-size:12px}.item small{color:#7a8799;font-size:11px;display:block;margin-top:3px}
.login-page{min-height:100vh;display:grid;place-items:center;background:linear-gradient(135deg,#071d3a,#214a86);padding:20px}.login-card{width:min(450px,100%);background:#fff;border-radius:20px;padding:30px;box-shadow:0 25px 70px rgba(0,0,0,.28)}.login-logo{display:flex;align-items:center;gap:14px;margin-bottom:24px}.login-logo img{width:62px;height:62px;border-radius:50%;object-fit:cover}.login-logo h1{font-size:21px;margin:0}.login-logo p{font-size:12px;color:#748196;margin:5px 0 0}.login-card .btn{width:100%;padding:12px;margin-top:7px}
.two-col-form{display:grid;grid-template-columns:minmax(0,1.4fr) minmax(280px,.6fr);gap:18px}
@media(max-width:1050px){.cards{grid-template-columns:repeat(2,1fr)}.grid2,.two-col-form{grid-template-columns:1fr}.filters{grid-template-columns:1fr 1fr}}
@media(max-width:780px){.layout{grid-template-columns:1fr}.sidebar{position:relative;height:auto}.topbar{position:relative;padding:0 16px}.page{padding:16px}.cards,.grid-half,.form-grid,.filters{grid-template-columns:1fr}.form-grid .full{grid-column:auto}.sidebar{display:block}.navlink{display:inline-flex;margin:3px}.side-label{width:100%}}

/* Rich HTML editor + cropper */
.editor-shell{border:1px solid #cfd8e6;border-radius:10px;overflow:hidden;background:#fff}.editor-toolbar{display:flex;gap:5px;flex-wrap:wrap;padding:8px;background:#f4f7fb;border-bottom:1px solid #dfe6f0}.editor-toolbar button{border:1px solid #cbd5e4;background:#fff;color:#24476f;border-radius:6px;padding:6px 8px;font-size:11px;font-weight:800;cursor:pointer}.rich-editor{min-height:300px;padding:17px;outline:none;line-height:1.65;font-size:14px}.rich-editor img{max-width:100%;height:auto;border-radius:10px}.rich-source{min-height:300px;border:0;border-radius:0;font-family:Consolas,monospace;font-size:12px;line-height:1.55}.editor-help{padding:8px 12px;background:#fbfcfe;border-top:1px solid #edf1f6;color:#7a8798;font-size:11px}.permission-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px 14px;padding:12px;background:#f7f9fc;border-radius:10px}.permission-grid label{margin:0;font-weight:650}.danger-note{background:#fff7e7;border:1px solid #f0d89c;padding:11px 13px;border-radius:9px;color:#72500f;font-size:12px;line-height:1.5}.news-card-preview{border:1px solid #e0e7f0;border-radius:12px;overflow:hidden}.news-card-preview img{width:100%;aspect-ratio:3/2;object-fit:cover;display:block}.news-card-preview div{padding:13px}.code-badge{font-family:Consolas,monospace;background:#eaf0f8;padding:2px 6px;border-radius:5px}



/* =========================================================
   PDB IMAGE EDITOR V3.5 — CLEAN
   ÚNICA definición del recortador. No mezclar con V3.1–V3.3.
   ========================================================= */

.editor-page-layout{
  display:grid;
  grid-template-columns:1fr;
  gap:20px;
}

.editor-page-layout > .card{
  min-width:0;
}

.crop-file{
  margin-top:5px;
}

.cover-upload-feedback{
  margin:10px 0 12px;
}

.upload-progress-wrap{
  padding:11px 12px;
  background:#f4f8fd;
  border:1px solid #d9e4f2;
  border-radius:10px;
}

.upload-progress-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  font-size:11px;
  color:#48617e;
  margin-bottom:7px;
}

.upload-progress-track{
  height:9px;
  background:#dfe8f3;
  border-radius:999px;
  overflow:hidden;
}

.upload-progress-bar,
.editor-upload-bar{
  height:100%;
  width:0;
  background:#2365c7;
  border-radius:999px;
  transition:width .12s linear;
}

.upload-success,
.editor-upload-success{
  margin-top:8px;
  padding:9px 11px;
  border-radius:8px;
  background:#e9f7ef;
  border:1px solid #c9ead6;
  color:#126c3d;
  font-size:11px;
  font-weight:750;
}

.upload-error,
.editor-upload-error{
  margin-top:8px;
  padding:9px 11px;
  border-radius:8px;
  background:#fff0ef;
  border:1px solid #efc9c6;
  color:#a52d27;
  font-size:11px;
  font-weight:750;
  white-space:pre-wrap;
}

.editor-upload-feedback{
  padding:0 8px;
  background:#fff;
}

.editor-upload-progress{
  margin:8px 0;
  padding:10px 11px;
  background:#f4f8fd;
  border:1px solid #d9e4f2;
  border-radius:8px;
}

.crop-workspace{
  display:grid;
  grid-template-columns:minmax(0,1fr) 300px;
  gap:18px;
  align-items:start;
  margin-top:12px;
  width:100%;
}

.crop-frame{
  position:relative !important;
  width:100%;
  max-width:760px;
  aspect-ratio:3/2;
  min-height:0;
  overflow:hidden;
  border:2px solid #cfd9e8;
  border-radius:14px;
  background:
    linear-gradient(45deg,#edf2f7 25%,transparent 25%),
    linear-gradient(-45deg,#edf2f7 25%,transparent 25%),
    linear-gradient(45deg,transparent 75%,#edf2f7 75%),
    linear-gradient(-45deg,transparent 75%,#edf2f7 75%);
  background-size:20px 20px;
  background-position:0 0,0 10px,10px -10px,-10px 0;
  cursor:grab !important;
  touch-action:none !important;
  user-select:none !important;
  outline:none;
  isolation:isolate;
}

.crop-frame::after{
  content:none !important;
  display:none !important;
}

.crop-frame:focus{
  border-color:#4d82d2;
  box-shadow:0 0 0 3px rgba(35,101,199,.14);
}

.crop-frame.is-dragging{
  cursor:grabbing !important;
  border-color:#2365c7;
  box-shadow:0 0 0 3px rgba(35,101,199,.14);
}

.crop-frame .crop-image{
  position:absolute !important;
  left:0 !important;
  top:0 !important;
  display:block;
  max-width:none !important;
  max-height:none !important;
  min-width:0 !important;
  min-height:0 !important;
  object-fit:fill !important;
  pointer-events:none !important;
  user-select:none !important;
  will-change:transform,width,height;
  transform-origin:0 0;
  z-index:1;
}

.crop-guide{
  position:absolute;
  inset:0;
  z-index:3;
  pointer-events:none;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.55);
}

.crop-guide::before,
.crop-guide::after{
  content:"";
  position:absolute;
  pointer-events:none;
}

.crop-guide::before{
  left:33.333%;
  right:33.333%;
  top:0;
  bottom:0;
  border-left:1px solid rgba(255,255,255,.50);
  border-right:1px solid rgba(255,255,255,.50);
}

.crop-guide::after{
  top:33.333%;
  bottom:33.333%;
  left:0;
  right:0;
  border-top:1px solid rgba(255,255,255,.50);
  border-bottom:1px solid rgba(255,255,255,.50);
}

.crop-guide span{
  position:absolute;
  right:10px;
  bottom:10px;
  padding:5px 8px;
  border-radius:7px;
  background:rgba(5,28,57,.78);
  color:#fff;
  font-size:10px;
  font-weight:900;
  backdrop-filter:blur(5px);
}

.crop-drag-hint{
  position:absolute;
  left:50%;
  top:50%;
  transform:translate(-50%,-50%);
  z-index:5;
  pointer-events:none;
  padding:8px 12px;
  border-radius:999px;
  background:rgba(5,28,57,.78);
  color:#fff;
  font-size:10px;
  font-weight:900;
  letter-spacing:.8px;
  opacity:.78;
  white-space:nowrap;
  transition:opacity .15s ease;
}

.crop-frame.is-dragging .crop-drag-hint{
  opacity:.15;
}

.crop-nudge{
  position:absolute;
  z-index:8;
  width:40px;
  height:40px;
  padding:0;
  border:1px solid rgba(255,255,255,.82);
  border-radius:50%;
  background:rgba(6,31,63,.88);
  color:#fff;
  font-size:16px;
  line-height:1;
  font-weight:900;
  display:grid;
  place-items:center;
  cursor:pointer;
  box-shadow:0 4px 14px rgba(0,0,0,.22);
  backdrop-filter:blur(5px);
}

.crop-nudge:hover{
  background:#2365c7;
}

.crop-nudge-up{
  top:10px;
  left:50%;
  transform:translateX(-50%);
}

.crop-nudge-down{
  bottom:10px;
  left:50%;
  transform:translateX(-50%);
}

.crop-nudge-left{
  left:10px;
  top:50%;
  transform:translateY(-50%);
}

.crop-nudge-right{
  right:10px;
  top:50%;
  transform:translateY(-50%);
}

.crop-panel{
  min-width:0;
  border:1px solid #e0e6ef;
  border-radius:13px;
  padding:14px;
  background:#fafcff;
}

.crop-status{
  min-height:45px;
  padding:10px;
  border-radius:9px;
  background:#fff;
  border:1px solid #e5ebf3;
  font-size:11px;
  color:#607087;
  line-height:1.55;
  margin-bottom:12px;
}

.crop-warning{
  color:#a75a0d;
  font-weight:850;
}

.crop-move-status{
  color:#2365c7;
  font-weight:800;
}

.crop-row{
  display:grid;
  grid-template-columns:auto 38px minmax(100px,1fr) 38px 54px;
  gap:7px;
  align-items:center;
}

.crop-row label{
  margin:0;
}

.crop-row input[type=range]{
  padding:0;
}

.crop-zoom-btn{
  width:38px;
  height:38px;
  padding:0;
  border:1px solid #c8d4e4;
  border-radius:9px;
  background:#fff;
  color:#214d85;
  font-size:20px;
  font-weight:900;
  cursor:pointer;
}

.crop-zoom-value{
  font-size:11px;
  font-weight:900;
  text-align:right;
  color:#214d85;
}

.crop-actions{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  margin:12px 0;
}

.crop-direct-help{
  display:flex;
  gap:10px;
  align-items:center;
  margin:10px 0 3px;
  padding:11px 12px;
  border-radius:10px;
  background:#eef5ff;
  border:1px solid #d6e5fa;
  color:#315371;
  font-size:11px;
  line-height:1.45;
}

.crop-hand{
  width:36px;
  height:36px;
  flex:0 0 auto;
  border-radius:50%;
  background:#2365c7;
  color:#fff;
  display:grid;
  place-items:center;
  font-size:20px;
  font-weight:900;
}

.crop-help{
  margin:10px 0 0;
  font-size:10px;
  color:#718096;
  line-height:1.55;
}

@media(max-width:1050px){
  .crop-workspace{
    grid-template-columns:1fr;
  }
  .crop-frame{
    max-width:720px;
  }
}

@media(max-width:700px){
  .crop-frame{
    max-width:none;
    border-radius:11px;
  }
  .crop-row{
    grid-template-columns:1fr 38px 38px 54px;
  }
  .crop-row label{
    grid-column:1/-1;
  }
  .crop-nudge{
    width:36px;
    height:36px;
  }
}


/* News editorial list v3.4 */
.news-admin-list{padding:0 18px}
.news-admin-item{
 display:grid;grid-template-columns:150px minmax(0,1fr);gap:18px;
 padding:18px 0;border-bottom:1px solid #dfe6ef;align-items:center
}
.news-admin-item:last-child{border-bottom:0}
.news-admin-thumb{aspect-ratio:3/2;border-radius:10px;overflow:hidden;background:#eef3f9}
.news-admin-thumb img{width:100%;height:100%;display:block;object-fit:cover}
.news-admin-placeholder{width:100%;height:100%;display:grid;place-items:center;background:linear-gradient(135deg,#0a2b55,#214a86);color:#fff;font-size:26px}
.news-admin-main{min-width:0}
.news-admin-meta{display:flex;align-items:center;gap:10px;flex-wrap:wrap;color:#758397;font-size:10px;margin-bottom:6px}
.news-admin-main h3{font-size:16px;line-height:1.25;margin:0 0 6px;color:#102b50}
.news-admin-main p{font-size:12px;line-height:1.55;color:#6f7d90;margin:0 0 9px;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.news-admin-actions{display:flex;gap:7px;align-items:center;flex-wrap:wrap}
@media(max-width:700px){
 .news-admin-item{grid-template-columns:92px minmax(0,1fr);gap:12px}
 .news-admin-main h3{font-size:14px}
}


/* =========================================================
   PDB CMS SLIDER PLUGIN V3.6
   ========================================================= */
.slider-modal[hidden]{display:none!important}
.slider-modal{position:fixed;inset:0;z-index:9999;display:grid;place-items:center;padding:22px}
.slider-modal-backdrop{position:absolute;inset:0;background:rgba(3,17,36,.72);backdrop-filter:blur(4px)}
.slider-dialog{
 position:relative;z-index:1;width:min(1050px,100%);max-height:calc(100vh - 44px);overflow:auto;
 background:#fff;border-radius:18px;box-shadow:0 28px 80px rgba(0,0,0,.34);border:1px solid #dfe6ef
}
.slider-dialog-head{display:flex;justify-content:space-between;gap:18px;padding:20px 22px;border-bottom:1px solid #e3e8ef;background:linear-gradient(180deg,#fbfdff,#f7f9fc)}
.slider-dialog-head h3{font-size:20px;margin:3px 0 5px;color:#0b2a50}.slider-dialog-head p{margin:0;color:#718096;font-size:12px}
.slider-plugin-label{font-size:9px;letter-spacing:1.3px;font-weight:900;color:#2365c7}
.slider-close{width:38px;height:38px;border:1px solid #d3dce8;border-radius:50%;background:#fff;color:#52657e;font-size:23px;cursor:pointer}
.slider-drop-zone{margin:18px 22px 12px;padding:18px;border:1px dashed #9fb6d3;border-radius:13px;background:#f5f9ff;display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.slider-drop-zone span{font-size:11px;color:#6f7f92}
.slider-global-options{display:grid;grid-template-columns:1.15fr 1fr 1fr auto auto;gap:12px;align-items:end;margin:0 22px 15px}
.slider-global-options label{margin:0}.slider-switch-label{display:flex!important;align-items:center;gap:7px;min-height:39px}.slider-switch-label input{width:auto}
.slider-upload-summary{margin:0 22px 8px;font-size:11px;color:#66768a}
.slider-items{padding:0 22px}
.slider-item{display:grid;grid-template-columns:28px 126px minmax(0,1fr) 42px;gap:12px;align-items:center;padding:13px 0;border-bottom:1px solid #e6ebf2}
.slider-item.dragging{opacity:.45}.slider-item-handle{font-size:18px;color:#99a9bb;cursor:grab;text-align:center}
.slider-item-thumb{position:relative;aspect-ratio:3/2;border-radius:9px;overflow:hidden;background:#eef3f9}.slider-item-thumb img{width:100%;height:100%;object-fit:cover;display:block}
.slider-item-number{position:absolute;left:6px;top:6px;background:rgba(5,28,57,.78);color:#fff;border-radius:999px;padding:3px 6px;font-size:9px;font-weight:900}
.slider-item-fields{min-width:0;display:grid;gap:6px}.slider-item-fields input{padding:8px 9px}.slider-file-meta{font-size:10px;color:#8290a2;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.slider-item-progress>div:first-child{display:flex;justify-content:space-between;font-size:10px;color:#5e6f84;margin-bottom:5px}
.slider-item-error{font-size:10px;color:#a52d27;background:#fff0ef;border:1px solid #efc9c6;border-radius:7px;padding:6px 8px}.slider-item-ok{font-size:10px;color:#167245;font-weight:800}
.slider-item-actions{display:grid;gap:5px}.slider-mini-btn{width:34px;height:30px;border:1px solid #ccd7e4;border-radius:7px;background:#fff;color:#345a83;cursor:pointer;font-weight:900}.slider-mini-btn.danger{color:#aa342e}
.slider-preview-wrap{margin:18px 22px 0;padding-top:16px;border-top:1px solid #e3e8ef}.slider-preview-title{font-size:11px;font-weight:900;color:#53657b;margin-bottom:8px}
.slider-preview{max-width:620px;margin:auto}.slider-preview-frame{position:relative;aspect-ratio:16/9;border-radius:13px;overflow:hidden;background:#e9eef5}.slider-preview-frame img{width:100%;height:100%;object-fit:cover}.slider-preview-overlay{position:absolute;left:0;right:0;bottom:0;padding:22px 14px 11px;background:linear-gradient(transparent,rgba(3,18,39,.82));color:#fff;display:flex;justify-content:space-between;gap:12px;font-size:11px}.slider-preview-dots{display:flex;justify-content:center;gap:5px;padding:8px}.slider-preview-dots i{width:6px;height:6px;border-radius:50%;background:#c9d4e1}.slider-preview-dots i.active{background:#2365c7}
.slider-dialog-actions{position:sticky;bottom:0;display:flex;justify-content:flex-end;gap:9px;padding:15px 22px;border-top:1px solid #e3e8ef;background:rgba(255,255,255,.97);backdrop-filter:blur(8px)}
body.slider-modal-open{overflow:hidden}

/* Slider placeholder inside contenteditable */
.rich-editor .pdb-slider{border:2px solid #bdd0e8;border-radius:12px;padding:10px;background:#f6f9fd;position:relative;overflow:hidden}
.rich-editor .pdb-slider::before{content:"🎞️ SLIDER · INTERNO";display:block;font-size:9px;font-weight:900;letter-spacing:1px;color:#2365c7;margin-bottom:7px}.rich-editor .pdb-slider[data-slider-placement="principal"]::before{content:"🎞️ SLIDER · EXTERIOR";color:#9b6a16}
.rich-editor .pdb-slider-stage{display:grid;grid-template-columns:repeat(3,1fr);gap:6px}
.rich-editor .pdb-slide{margin:0;min-width:0}.rich-editor .pdb-slide img{width:100%;aspect-ratio:3/2;object-fit:cover;border-radius:7px}.rich-editor .pdb-slide figcaption{font-size:9px;color:#66768a;margin-top:3px}
.rich-editor .pdb-slider-controls{display:none}

@media(max-width:760px){
 .slider-modal{padding:10px}.slider-dialog{max-height:calc(100vh - 20px);border-radius:13px}
 .slider-global-options{grid-template-columns:1fr 1fr}.slider-item{grid-template-columns:24px 88px minmax(0,1fr)}.slider-item-actions{grid-column:2/-1;display:flex}
 .slider-dialog-actions{flex-wrap:wrap}.slider-dialog-actions .btn{flex:1}
}

/* =========================================================
   PDB V3.7 — Miembros, ministerios múltiples y formaciones
   ========================================================= */
.dashboard-section-title{display:flex;align-items:center;justify-content:space-between;gap:15px;margin:0 0 12px}.dashboard-section-title>div{display:flex;align-items:center;gap:10px}.dashboard-section-title>div>span{width:38px;height:38px;display:grid;place-items:center;border-radius:10px;background:#eaf2ff;font-size:20px}.dashboard-section-title h2{margin:0;font-size:16px;color:#102b50}.dashboard-section-title small{display:block;margin-top:3px;color:#7a8798;font-size:11px}.member-summary{grid-template-columns:repeat(5,1fr)}.stat-link{display:block;transition:transform .15s ease,box-shadow .15s ease,border-color .15s ease}.stat-link:hover{transform:translateY(-2px);border-color:#bfd1ea;box-shadow:0 10px 26px rgba(15,43,79,.09)}.birthday-stat{background:linear-gradient(135deg,#fff,#fff7fb)}
.birthday-list{display:grid;gap:3px}.birthday-item{display:grid;grid-template-columns:38px 1fr auto;gap:10px;align-items:center;padding:10px;border-radius:10px}.birthday-item:hover{background:#f5f8fd}.birthday-icon{width:36px;height:36px;display:grid;place-items:center;border-radius:50%;background:#fff0f6;font-size:18px}.birthday-item b{font-size:12px;display:block}.birthday-item small{font-size:11px;color:#7b8798;display:block;margin-top:2px}.birthday-arrow{font-size:22px;color:#9aa6b6}.dashboard-shortcuts{display:grid;grid-template-columns:1fr 1fr;gap:10px}.dashboard-shortcuts a{border:1px solid #dfe6f0;background:#f8fafd;border-radius:10px;padding:13px;font-size:12px;font-weight:800;color:#244b79}.dashboard-shortcuts a:hover{border-color:#bfd1ea;background:#eef5ff}
.member-filters{grid-template-columns:minmax(220px,2fr) repeat(6,minmax(130px,1fr)) auto auto;align-items:center}.tag-list{display:flex;gap:4px;flex-wrap:wrap;max-width:250px}.mini-tag{display:inline-flex;padding:4px 7px;border-radius:999px;background:#eaf2ff;color:#285d9d;font-size:9px;font-weight:800;white-space:nowrap}.muted-mini{font-size:10px;color:#8a96a7}.label-hint{font-weight:600;color:#8793a4}.field-help{display:block;margin-top:7px;color:#7e8a9b;font-size:10px;line-height:1.4}
.compact-multi{display:flex;gap:7px;flex-wrap:wrap;padding:10px;border:1px solid #dbe3ef;border-radius:10px;background:#f9fbfd;max-height:130px;overflow:auto}.compact-check{display:inline-flex;align-items:center;gap:6px;margin:0;padding:7px 9px;border:1px solid #d7e1ee;border-radius:999px;background:#fff;color:#34506f;font-size:11px;font-weight:750;cursor:pointer}.compact-check:hover{border-color:#a9c2e3}.compact-check input{width:auto;margin:0}.compact-check:has(input:checked){background:#eaf2ff;border-color:#9bbde8;color:#1e5799}
.formation-picker{display:grid;gap:7px;padding:9px;border:1px solid #dbe3ef;border-radius:10px;background:#f9fbfd;max-height:205px;overflow:auto}.formation-option{display:grid;grid-template-columns:minmax(0,1fr) 145px;gap:9px;align-items:center;padding:7px;border-radius:9px;border:1px solid transparent}.formation-option.selected{background:#fff;border-color:#d8e3f0}.formation-option select{padding:7px 8px;font-size:11px}.formation-option select:disabled{opacity:.45}.formation-option .compact-check{border:0;background:transparent;padding:3px 5px}.formation-option .compact-check:has(input:checked){background:transparent}
@media(max-width:1300px){.member-summary{grid-template-columns:repeat(3,1fr)}.member-filters{grid-template-columns:repeat(3,1fr)}.member-filters input[name=q]{grid-column:span 2}}
@media(max-width:900px){.member-summary{grid-template-columns:repeat(2,1fr)}.member-filters{grid-template-columns:1fr 1fr}.member-filters input[name=q]{grid-column:1/-1}.formation-option{grid-template-columns:1fr}}
@media(max-width:600px){.member-summary,.member-filters,.dashboard-shortcuts{grid-template-columns:1fr}.member-filters input[name=q]{grid-column:auto}.dashboard-section-title{align-items:flex-start}.formation-picker{max-height:none}}

/* =========================================================
   PDB V3.8 — Miembros con menú + biblioteca de Formación
   ========================================================= */
.eyebrow{font-size:9px;letter-spacing:1.25px;text-transform:uppercase;font-weight:900;color:#4f78aa;margin-bottom:4px}
.members-page-head,.formation-workspace-head{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-bottom:16px}
.members-page-head h2,.formation-workspace-head h2{font-size:22px;color:#102b50;margin:0 0 5px}.members-page-head p,.formation-workspace-head p{margin:0;color:#748195;font-size:12px;line-height:1.5}
.members-actions{position:relative;flex:0 0 auto}.members-menu-toggle{min-width:180px;justify-content:space-between}.members-menu-panel[hidden]{display:none!important}.members-menu-panel{position:absolute;right:0;top:calc(100% + 8px);z-index:60;width:280px;padding:7px;background:#fff;border:1px solid #dbe4ef;border-radius:12px;box-shadow:0 18px 45px rgba(15,43,79,.16)}
.members-menu-item,.members-menu-coming{display:grid;grid-template-columns:38px minmax(0,1fr);gap:10px;align-items:center;padding:10px;border-radius:9px}.members-menu-item:hover{background:#eef5ff}.menu-item-icon{width:36px;height:36px;display:grid;place-items:center;border-radius:9px;background:#e8f2ff;color:#2365c7;font-size:22px;font-weight:900}.members-menu-item b,.members-menu-coming b{display:block;color:#173b67;font-size:12px}.members-menu-item small,.members-menu-coming small{display:block;color:#8591a1;font-size:10px;margin-top:2px;line-height:1.35}.members-menu-coming{border-top:1px solid #edf1f6;margin-top:5px;color:#8b97a7}.members-menu-coming>span:first-child{font-size:21px;text-align:center;opacity:.65}
.members-list-card{width:100%}.members-filter-body{padding-bottom:12px}.member-form-shell{max-width:1050px;margin:0 auto}.member-form-top{display:flex;align-items:flex-start;justify-content:space-between;gap:20px;margin-bottom:14px}.member-form-top h2{margin:7px 0 5px;color:#102b50;font-size:21px}.member-form-top p{margin:0;color:#758397;font-size:12px}.back-link{font-size:11px;font-weight:850;color:#3b6fae}.member-current-photo{display:inline-flex;align-items:center;gap:9px;padding:7px 10px;background:#f7f9fc;border:1px solid #e0e7f0;border-radius:10px;margin-bottom:14px}.member-current-photo .photo-preview{width:58px;height:58px;object-fit:cover;border-radius:9px}.member-current-photo span{font-size:10px;color:#7c8898;font-weight:800}.member-form-actions{justify-content:flex-end}
.formation-workspace-head{align-items:flex-end}.formation-tabs{display:flex;gap:6px;padding:5px;background:#edf2f8;border-radius:11px;flex-wrap:wrap}.formation-tabs a{display:flex;align-items:center;gap:6px;padding:8px 11px;border-radius:8px;font-size:11px;font-weight:850;color:#60738c}.formation-tabs a.active{background:#fff;color:#235d9d;box-shadow:0 2px 8px rgba(15,43,79,.08)}.formation-tabs a span{min-width:20px;height:20px;padding:0 5px;display:grid;place-items:center;border-radius:999px;background:#dfe9f5;font-size:9px}.formation-tabs a.active span{background:#e9f2ff;color:#2365c7}
.material-count-link{display:inline-flex;align-items:center;gap:4px;padding:5px 8px;border-radius:999px;background:#f0f5fb;color:#35689f;font-size:10px;font-weight:850}.formation-material-layout{display:grid;grid-template-columns:minmax(280px,.34fr) minmax(0,.66fr);gap:16px;align-items:start}.formation-upload-card{position:sticky;top:86px}.formation-library-card .card-head small{display:block;margin-top:3px;color:#8491a2;font-size:10px;font-weight:600}.formation-library-filters form{display:grid;grid-template-columns:minmax(190px,1.5fr) minmax(150px,1fr) auto auto;gap:8px}.compact-empty{padding:20px 12px}.formation-materials-list{padding:0 18px 12px}.material-group-title{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 4px 7px;border-bottom:1px solid #dfe7f1;color:#5d718a}.material-group-title span{font-size:10px;font-weight:900;text-transform:uppercase;letter-spacing:.7px;color:#3970ae}.material-group-title b{font-size:10px;color:#697a90;background:#f0f4f9;padding:4px 7px;border-radius:999px}.material-row{display:grid;grid-template-columns:46px minmax(0,1fr) auto;gap:11px;align-items:center;padding:12px 3px;border-bottom:1px solid #edf1f6}.material-file-icon{width:42px;height:42px;display:grid;place-items:center;border-radius:10px;background:#eef4fb;font-size:20px}.material-file-main{min-width:0}.material-file-main>b{display:block;color:#193b64;font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.material-file-main small{display:block;color:#8a96a5;font-size:9px;margin-top:3px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.material-file-main p{margin:5px 0 0;color:#6f7e91;font-size:10px;line-height:1.4}.material-actions{display:flex;align-items:center;gap:6px}.material-actions form{margin:0}
@media(max-width:1050px){.formation-material-layout{grid-template-columns:1fr}.formation-upload-card{position:relative;top:auto}.formation-library-filters form{grid-template-columns:1fr 1fr}.members-page-head,.formation-workspace-head{align-items:flex-start;flex-direction:column}.members-actions{align-self:stretch}.members-menu-toggle{width:100%}.members-menu-panel{left:0;right:auto;width:min(100%,340px)}}
@media(max-width:650px){.formation-tabs{width:100%}.formation-tabs a{flex:1;justify-content:center}.formation-library-filters form{grid-template-columns:1fr}.material-row{grid-template-columns:40px minmax(0,1fr)}.material-actions{grid-column:2;flex-wrap:wrap}.member-form-top{flex-direction:column}.members-menu-panel{width:100%}}

/* =========================================================
   PDB V3.9 — Programas de culto
   ========================================================= */
.programs-head,.services-head{display:flex;align-items:flex-end;justify-content:space-between;gap:18px;margin-bottom:16px}.programs-head h2,.services-head h2{margin:0 0 5px;color:#102b50;font-size:22px}.programs-head p,.services-head p{margin:0;color:#748195;font-size:12px;line-height:1.5}.program-editor-card{margin-bottom:16px}.program-editor-card .card-head small{display:block;margin-top:4px;color:#8290a2;font-size:10px;font-weight:600}.program-link-notice{margin-bottom:14px;padding:11px 13px;border:1px solid #bfd8f3;background:#eef6ff;border-radius:10px;color:#2d5f91;font-size:11px}.program-meta-grid{margin-bottom:18px}.program-items-head{display:flex;align-items:flex-end;justify-content:space-between;gap:15px;padding:16px 0 9px;border-top:1px solid #e6ecf3}.program-items-head h3{margin:0 0 3px;color:#173b67;font-size:15px}.program-items-head p{margin:0;color:#8290a2;font-size:10px}.program-items{display:grid;gap:9px}.program-edit-row{display:grid;grid-template-columns:28px 150px 105px 105px 78px minmax(220px,1.7fr) minmax(180px,1.2fr) minmax(130px,.8fr) 34px;gap:8px;align-items:start;padding:11px;border:1px solid #dce5ef;border-radius:11px;background:#f9fbfd}.program-edit-row label{font-size:9px;margin-bottom:4px}.program-edit-row input,.program-edit-row select,.program-edit-row textarea{padding:8px 9px;font-size:11px}.program-edit-row textarea{min-height:60px;resize:vertical}.program-row-grip{height:35px;display:grid;place-items:center;color:#9daaba;font-weight:900;cursor:default}.program-row-delete{width:32px;height:32px;margin-top:18px;border:1px solid #efc8c5;border-radius:8px;background:#fff5f4;color:#b03a34;font-size:19px;cursor:pointer}.program-row-delete:hover{background:#ffeceb}.program-save-actions{justify-content:flex-end}.program-pill{display:inline-flex;max-width:220px;align-items:center;gap:5px;padding:5px 8px;border-radius:999px;background:#eaf2ff;color:#2b619f;font-size:9px;font-weight:850;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.service-program-box{padding:12px;border:1px solid #cfe0f2;border-radius:11px;background:#f7fbff}.service-program-box>label{color:#245f9d}.service-program-tools{display:flex;gap:10px;flex-wrap:wrap;align-items:center;margin-top:7px}.service-program-tools span{font-size:9px;color:#7c8999}.service-program-tools a{font-size:9px;font-weight:850;color:#2365c7}.services-head{align-items:center}
@media(max-width:1450px){.program-edit-row{grid-template-columns:28px 140px 100px 100px 72px minmax(200px,1.5fr) minmax(170px,1fr) 34px}.program-notes-field{grid-column:2/8}.program-row-delete{grid-column:8;grid-row:1}}
@media(max-width:1000px){.programs-head,.services-head{align-items:flex-start;flex-direction:column}.program-edit-row{grid-template-columns:28px 1fr 1fr 1fr 70px 34px}.program-activity-field,.program-assigned-field,.program-notes-field{grid-column:2/-1}.program-row-delete{grid-column:6;grid-row:1}.program-items-head{align-items:flex-start}}
@media(max-width:650px){.program-edit-row{grid-template-columns:1fr 1fr;padding:10px}.program-row-grip{display:none}.program-edit-row>div:nth-child(2){grid-column:1/-1}.program-activity-field,.program-assigned-field,.program-notes-field{grid-column:1/-1}.program-row-delete{grid-column:2;grid-row:1;justify-self:end;margin-top:0}.program-items-head{flex-direction:column}.program-items-head .btn{width:100%}.service-program-tools{align-items:flex-start;flex-direction:column}}


/* =========================================================
   PDB V3.10 — Horario inteligente + asistencia formaciones
   ========================================================= */
.program-auto-help{display:flex;align-items:flex-start;gap:7px;padding:9px 11px;margin:0 0 10px;border:1px solid #cfe0f2;border-radius:9px;background:#f4f9ff;color:#54708f;font-size:10px;line-height:1.45}.program-auto-help b{color:#245f9d}.program-edit-row input[name="item_end[]"]{background:#f2f6fb;color:#41617f}.program-edit-row input[name="item_end[]"]:focus{background:#fff}.attendance-head{display:flex;align-items:flex-end;justify-content:space-between;gap:18px;margin-bottom:16px}.attendance-head .back-link{display:block;margin-bottom:8px}.attendance-head h2{margin:0 0 5px;color:#102b50;font-size:22px}.attendance-head p{margin:0;color:#748195;font-size:12px}.attendance-layout{display:grid;grid-template-columns:minmax(300px,.36fr) minmax(0,.64fr);gap:16px;align-items:start;margin-bottom:16px}.attendance-new-card{position:sticky;top:86px}.attendance-new-card .card-head small,.attendance-history-card .card-head small,.attendance-roster-head small{display:block;margin-top:3px;color:#8491a2;font-size:10px;font-weight:600}.attendance-class-form{display:grid;gap:11px}.attendance-class-form .two-col{display:grid;grid-template-columns:1fr 1fr;gap:9px}.attendance-filter select{min-width:180px;padding:7px 9px;font-size:10px}.attendance-session-list{max-height:460px;overflow:auto;padding:4px 14px 14px}.attendance-session-row{display:grid;grid-template-columns:46px minmax(0,1fr) 58px;gap:10px;align-items:center;padding:10px;border-bottom:1px solid #edf1f6;border-radius:9px}.attendance-session-row:hover,.attendance-session-row.active{background:#f1f7ff}.attendance-date-box{width:42px;height:46px;border-radius:9px;background:#e9f2ff;color:#2b619f;display:grid;place-items:center;align-content:center}.attendance-date-box b{font-size:15px;line-height:1}.attendance-date-box span{font-size:8px;font-weight:900;margin-top:3px}.attendance-session-main{min-width:0}.attendance-session-main>b{display:block;color:#173b67;font-size:11px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.attendance-session-main small{display:block;color:#8591a1;font-size:9px;margin-top:3px}.attendance-session-score{text-align:right}.attendance-session-score b{display:block;color:#2b6a52;font-size:12px}.attendance-session-score span{font-size:8px;color:#8b97a6}.attendance-roster-card{scroll-margin-top:18px}.attendance-roster-head{align-items:flex-start}.attendance-summary{display:grid;grid-template-columns:repeat(6,1fr);gap:8px;padding:12px 18px;border-bottom:1px solid #e8edf3}.attendance-summary>div{display:grid;grid-template-columns:28px 1fr;grid-template-rows:auto auto;column-gap:7px;padding:9px;border:1px solid #e0e7f0;border-radius:10px;background:#f8fafc}.attendance-summary span{grid-row:1/3;width:27px;height:27px;display:grid;place-items:center;border-radius:8px;background:#eaf0f7;color:#4e6884;font-weight:900}.attendance-summary b{font-size:14px;color:#173b67}.attendance-summary small{font-size:8px;color:#8290a2}.attendance-summary .ok span{background:#e7f7ef;color:#2b7a55}.attendance-summary .warn span{background:#fff4db;color:#a36b00}.attendance-summary .bad span{background:#ffebe9;color:#b44138}.attendance-table select,.attendance-table input{min-width:150px;padding:7px 8px;font-size:10px}.attendance-save{padding:13px 18px;justify-content:flex-end;border-top:1px solid #e9eef4}
@media(max-width:1100px){.attendance-layout{grid-template-columns:1fr}.attendance-new-card{position:relative;top:auto}.attendance-summary{grid-template-columns:repeat(3,1fr)}}
@media(max-width:700px){.attendance-head{align-items:flex-start;flex-direction:column}.attendance-summary{grid-template-columns:repeat(2,1fr)}.attendance-class-form .two-col{grid-template-columns:1fr}.attendance-session-list{max-height:none}.attendance-roster-head{align-items:flex-start;flex-direction:column}}

/* Pacto de Bendición V3.11 · Orden manual + cronológico en programas */
.program-row-order{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:2px;padding-top:1px}.program-row-order button{width:25px;height:22px;padding:0;border:1px solid #d5e0eb;border-radius:6px;background:#fff;color:#5c718a;font-size:12px;font-weight:900;line-height:1;cursor:pointer}.program-row-order button:hover{background:#eaf3ff;color:#205f9f;border-color:#b9d3ef}.program-row-order .program-row-grip{width:25px;height:22px;display:grid;place-items:center;cursor:grab;touch-action:none;user-select:none}.program-row-order .program-row-grip:active{cursor:grabbing}.program-edit-row.program-row-dragging{opacity:.58;border-color:#8db6e4;background:#eef6ff;box-shadow:0 8px 20px rgba(40,94,151,.12)}
@media(max-width:650px){.program-row-order{grid-column:1;grid-row:1;flex-direction:row;justify-content:flex-start;padding:0}.program-row-order .program-row-grip{display:none}.program-row-order button{width:32px;height:30px}.program-edit-row>div:nth-child(2){grid-column:1/-1;grid-row:2}.program-row-delete{grid-column:2;grid-row:1}}


/* =========================================================
   PDB V3.12 — Adaptación responsive + Dashboard + Cultos
   ========================================================= */
/* Base responsive: evita que controles y tarjetas deformen el contenido */
.page{width:100%;min-width:0}.card,.stat,.grid2>*{min-width:0}.card-head>div{min-width:0}.toolbar>*{flex:0 0 auto}.table-wrap{-webkit-overflow-scrolling:touch}.card-subtitle{display:block;margin-top:4px;color:#8491a2;font-size:10px;font-weight:600;line-height:1.4}

/* Dashboard: resumen de miembros con jerarquía visual estable */
.member-summary{grid-template-columns:repeat(5,minmax(0,1fr));gap:13px}
.member-stat-card{position:relative;display:flex;flex-direction:column;min-height:154px;padding:16px 16px 13px;overflow:hidden;background:#fff}
.member-stat-card::before{content:"";position:absolute;left:0;top:0;bottom:0;width:4px;background:#8ba9ca}
.member-stat-head{display:flex;align-items:center;gap:9px;min-width:0}
.member-stat-head small{font-size:9px;line-height:1.25;letter-spacing:.25px;color:#5f6f83;white-space:normal}
.member-stat-icon{width:35px;height:35px;flex:0 0 35px;display:grid;place-items:center;border-radius:10px;background:#edf3fb;font-size:17px}
.member-stat-number{display:flex;align-items:baseline;gap:6px;margin:13px 0 10px}.member-stat-number strong{display:inline;margin:0;font-size:31px;line-height:1;color:#132b4c}.member-stat-number span{font-size:9px;color:#8a96a5;text-transform:uppercase;font-weight:800}
.member-stat-action{margin-top:auto;padding-top:9px;border-top:1px solid #edf1f6;font-size:10px;font-weight:800;color:#4d6f95;display:flex;align-items:center;justify-content:space-between;gap:8px}.member-stat-action b{font-size:15px}
.member-stat-active::before{background:#2a9b63}.member-stat-active .member-stat-icon{background:#e9f7ef}
.member-stat-inactive::before{background:#8b97a7}.member-stat-inactive .member-stat-icon{background:#f0f2f5}
.member-stat-ministry::before{background:#3778c7}.member-stat-ministry .member-stat-icon{background:#eaf3ff}
.member-stat-visitors::before{background:#725bc5}.member-stat-visitors .member-stat-icon{background:#f0edff}
.member-stat-birthday{background:linear-gradient(145deg,#fff,#fff9fc)}.member-stat-birthday::before{background:#d05a8a}.member-stat-birthday .member-stat-icon{background:#fff0f6}

/* Cultos: listado principal + menú de acciones, igual filosofía que Miembros */
.panel-section-head{align-items:center}.services-actions{position:relative;flex:0 0 auto}.services-menu-toggle{min-width:176px;justify-content:space-between}.services-menu-panel[hidden]{display:none!important}.services-menu-panel{position:absolute;right:0;top:calc(100% + 8px);z-index:60;width:285px;padding:7px;background:#fff;border:1px solid #dbe4ef;border-radius:12px;box-shadow:0 18px 45px rgba(15,43,79,.16)}
.services-menu-item{display:grid;grid-template-columns:38px minmax(0,1fr);gap:10px;align-items:center;padding:10px;border-radius:9px}.services-menu-item:hover{background:#eef5ff}.services-menu-item b{display:block;color:#173b67;font-size:12px}.services-menu-item small{display:block;color:#8591a1;font-size:10px;margin-top:2px;line-height:1.35}
.service-editor-card{margin-bottom:18px;scroll-margin-top:18px}.service-editor-head{align-items:flex-start}.service-editor-head h2{margin:0}.service-editor-head small{display:block;margin-top:4px;color:#8491a2;font-size:10px;font-weight:600}.service-public-field{display:flex;align-items:flex-end}.service-public-field label{padding:10px 11px;border:1px solid #dce5ef;border-radius:9px;background:#f8fafc;width:100%;margin:0}.service-form-actions{gap:8px}.services-list-card{width:100%}.services-table td>small{color:#7c899a}.services-table .toolbar form{margin:0}

/* Ajustes por ancho */
@media(max-width:1320px){.member-summary{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:1050px){.member-summary{grid-template-columns:repeat(2,minmax(0,1fr))}.services-head{align-items:flex-start;flex-direction:column}.services-actions{align-self:stretch}.services-menu-toggle{width:100%}.services-menu-panel{left:0;right:auto;width:min(100%,360px)}}
@media(max-width:780px){
 .topbar{height:auto;min-height:68px;padding:12px 16px}.topbar h1{font-size:19px}.topbar .sub{font-size:10px}.userchip{max-width:42%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
 .page{padding:14px}.card-head{padding:14px;flex-wrap:wrap}.card-body{padding:14px}.dashboard-section-title{align-items:center}.dashboard-section-title .btn{flex:0 0 auto}
 .stat{padding:15px}.member-stat-card{min-height:145px}.member-stat-number strong{font-size:28px}
 .services-table{overflow:visible;padding:8px}.services-table table,.services-table tbody,.services-table tr,.services-table td{display:block;width:100%}.services-table thead{display:none}.services-table tr{margin-bottom:10px;padding:10px 12px;border:1px solid #e0e7f0;border-radius:11px;background:#fff;box-shadow:0 4px 13px rgba(15,43,79,.04)}.services-table tr:last-child{margin-bottom:0}.services-table td{display:grid;grid-template-columns:92px minmax(0,1fr);gap:9px;align-items:start;padding:7px 0;border:0}.services-table td::before{content:attr(data-label);font-size:8px;line-height:1.4;font-weight:900;letter-spacing:.45px;text-transform:uppercase;color:#8290a2}.services-table td[colspan]::before{display:none}.services-table td[colspan]{display:block}.service-actions-cell .toolbar{justify-content:flex-start}.services-table .program-pill{max-width:100%;white-space:normal}.services-table .btn{min-height:34px}
}
@media(max-width:520px){
 .member-summary{grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.member-stat-card{min-height:136px;padding:13px 12px 11px}.member-stat-icon{width:31px;height:31px;flex-basis:31px;font-size:15px}.member-stat-head{gap:7px}.member-stat-head small{font-size:8px}.member-stat-number{margin:11px 0 8px}.member-stat-number strong{font-size:25px}.member-stat-number span{display:none}.member-stat-action{font-size:8.5px}.dashboard-section-title{gap:8px}.dashboard-section-title>div>span{width:34px;height:34px;font-size:17px}.dashboard-section-title h2{font-size:14px}.dashboard-section-title small{font-size:9px}.dashboard-section-title .btn{padding:7px 8px;font-size:9px}
 .services-menu-panel{width:100%}.service-editor-head{flex-direction:column}.service-editor-head .btn{width:100%}.service-form-actions{flex-direction:column-reverse}.service-form-actions .btn{width:100%}.services-table td{grid-template-columns:78px minmax(0,1fr)}
}
@media(max-width:360px){.member-summary{grid-template-columns:1fr}.member-stat-card{min-height:126px}.userchip{display:none}}

/* V3.13 · Asistencia integrada en el módulo de Formaciones */
.attendance-module-actions{display:flex;justify-content:flex-end;margin:-6px 0 12px}
@media(max-width:650px){.attendance-module-actions{justify-content:stretch}.attendance-module-actions .btn{width:100%;justify-content:center}.formation-tabs a{white-space:nowrap}}


/* =========================================================
   PDB V3.18 — Slider visible en Noticias
   ========================================================= */
.editor-toolbar .editor-slider-button{
  background:linear-gradient(135deg,#174f91,#2f78d5);
  border-color:#174f91;color:#fff;padding-left:12px;padding-right:12px;
  box-shadow:0 4px 12px rgba(23,79,145,.14)
}
.editor-toolbar .editor-slider-button:hover{filter:brightness(1.06)}
.editor-slider-callout{
  display:flex;align-items:center;justify-content:space-between;gap:14px;
  padding:10px 12px;background:linear-gradient(90deg,#f3f7fd,#fbfdff);
  border-bottom:1px solid #dfe7f2;color:#274c77
}
.editor-slider-callout>div{min-width:0;display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.editor-slider-callout b{font-size:11px;color:#173f70}
.editor-slider-callout span{font-size:10px;color:#738399}
.editor-slider-callout .btn{flex:0 0 auto}
@media(max-width:700px){
 .editor-slider-callout{align-items:flex-start;flex-direction:column}
 .editor-slider-callout .btn{width:100%}
 .editor-toolbar .editor-slider-button{order:20;flex:1 1 180px}
}

/* =========================================================
   PDB V3.21 — Exterior: Miniatura O Slider + editor interno
   ========================================================= */
.featured-media-box{margin:20px 0 18px;border:1px solid #d9e4f0;border-radius:14px;background:#f9fbfe;overflow:hidden}
.featured-media-heading{padding:14px 16px;border-bottom:1px solid #e3eaf2;background:linear-gradient(90deg,#eef5fd,#fbfdff)}
.featured-media-heading b,.internal-editor-heading b{display:block;color:#173f70;font-size:13px}
.featured-media-heading span,.internal-editor-heading span{display:block;margin-top:4px;color:#738399;font-size:10px;line-height:1.45}
.featured-media-choice{display:grid;grid-template-columns:1fr 1fr;gap:10px;padding:14px 16px}
.featured-choice-card{display:grid;grid-template-columns:auto 36px 1fr;align-items:center;gap:9px;margin:0;padding:12px;border:1px solid #d9e3ee;border-radius:11px;background:#fff;cursor:pointer;transition:.16s ease}
.featured-choice-card:has(input:checked){border-color:#4c89d2;background:#eef6ff;box-shadow:0 0 0 2px rgba(76,137,210,.10)}
.featured-choice-card input{width:17px;height:17px;margin:0}
.featured-choice-icon{font-size:21px}
.featured-choice-card b{display:block;color:#173b67;font-size:11px}.featured-choice-card small{display:block;margin-top:2px;color:#7b899a;font-size:9px}
.featured-media-panel{padding:0 16px 16px}.featured-media-panel[hidden]{display:none!important}
.featured-media-panel>.editor-shell{margin-top:0}
.slider-only-shell .rich-editor{min-height:120px;background:#f6f9fd;cursor:default}
.slider-only-shell .rich-editor:empty::after{content:"Todavía no has creado el slider exterior.";display:grid;place-items:center;min-height:100px;color:#8997a8;font-size:10px;border:1px dashed #cdd9e7;border-radius:10px}
.slider-only-shell .pdb-slider::before{content:"🎞️ SLIDER EXTERIOR"!important;color:#9b6a16!important}
.cover-slider-callout{border:1px solid #dfe7f2;border-radius:10px 10px 0 0}
.internal-editor-heading{margin:20px 0 8px;padding:12px 14px;border-left:4px solid #2f78d5;border-radius:8px;background:#f3f7fd}
.news-admin-thumb{position:relative}.news-admin-slider-badge{position:absolute;z-index:3;left:6px;top:6px;padding:4px 7px;border-radius:999px;background:rgba(9,34,66,.82);color:#fff;font-size:8px;font-weight:800}
@media(max-width:700px){.featured-media-choice{grid-template-columns:1fr}.featured-media-panel{padding-left:10px;padding-right:10px}}


/* PDB V3.23 — Reutilizar el slider exterior dentro de la noticia */
.cover-slider-inside-option{
  display:flex;align-items:flex-start;gap:10px;margin:10px 0 0;padding:12px 13px;
  border:1px solid #cfe0f2;border-radius:11px;background:#f4f9ff;cursor:pointer
}
.cover-slider-inside-option input{width:17px;height:17px;margin:1px 0 0;flex:0 0 auto;accent-color:#2f78d5}
.cover-slider-inside-option span{display:block;min-width:0}
.cover-slider-inside-option b{display:block;color:#173f70;font-size:11px}
.cover-slider-inside-option small{display:block;margin-top:4px;color:#748399;font-size:9.5px;line-height:1.45}
.cover-slider-inside-option:has(input:checked){border-color:#4c89d2;background:#eaf4ff;box-shadow:0 0 0 2px rgba(76,137,210,.08)}

/* V3.24 · Edición posterior de sliders */
.editor-slider-edit-button{border:1px solid #b9cbe2;background:#fff;color:#234d7e;border-radius:8px;padding:7px 10px;font-weight:800;font-size:10px;cursor:pointer}
.editor-slider-edit-button:disabled{opacity:.45;cursor:not-allowed;background:#f4f6f9;color:#8795a7}
.rich-editor .pdb-slider.is-cms-selected-slider{outline:3px solid rgba(47,120,213,.48);outline-offset:4px;box-shadow:0 0 0 7px rgba(47,120,213,.08)}
.rich-editor .pdb-slider{cursor:pointer}
@media(max-width:760px){.editor-slider-edit-button{flex:1 1 190px}}

/* =========================================================
   PDB V3.25 — Destacado multimedia
   ========================================================= */
.multimedia-admin-layout{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:18px;align-items:start}.multimedia-admin-main{min-width:0}.multimedia-admin-help{position:sticky;top:86px}.multimedia-admin-head{align-items:flex-start}.mm-master-switch{display:flex;gap:9px;align-items:flex-start;margin:0;padding:9px 11px;border:1px solid #d7e3ef;border-radius:10px;background:#f8fbff;cursor:pointer}.mm-master-switch input{width:18px;height:18px;margin:1px 0 0;accent-color:#2f78d5}.mm-master-switch b{display:block;color:#174472;font-size:11px}.mm-master-switch small{display:block;margin-top:2px;color:#8190a2;font-size:9px}.mm-section-block{padding:18px 0;border-bottom:1px solid #e6edf5}.mm-section-block:first-child{padding-top:0}.mm-block-title{display:flex;align-items:center;gap:10px;margin-bottom:13px}.mm-block-title>span{width:28px;height:28px;display:grid;place-items:center;border-radius:8px;background:#eaf3ff;color:#2365b5;font-size:11px;font-weight:900}.mm-block-title b{display:block;color:#173f70;font-size:13px}.mm-block-title small{display:block;margin-top:2px;color:#8190a2;font-size:9px}.mm-type-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px}.mm-type-card{display:flex;align-items:center;gap:8px;min-width:0;margin:0;padding:11px;border:1px solid #dbe4ee;border-radius:11px;background:#fff;cursor:pointer}.mm-type-card input{position:absolute;opacity:0;pointer-events:none}.mm-type-icon{width:34px;height:34px;display:grid;place-items:center;flex:0 0 34px;border-radius:9px;background:#eef5fd;color:#2769b7;font-size:17px;font-weight:900}.mm-type-card b{display:block;color:#173b67;font-size:10px}.mm-type-card small{display:block;margin-top:2px;color:#8693a3;font-size:8px;line-height:1.3}.mm-type-card:has(input:checked){border-color:#4c89d2;background:#edf6ff;box-shadow:0 0 0 2px rgba(76,137,210,.08)}.mm-type-card:has(input:checked) .mm-type-icon{background:#2f78d5;color:#fff}.mm-type-panel{padding:14px;border:1px solid #dce6f1;border-radius:12px;background:#fbfdff}.mm-type-panel[hidden]{display:none!important}.mm-facebook-modes{display:grid;grid-template-columns:1fr 1fr;gap:9px;margin:12px 0}.mm-choice-row{display:flex;align-items:flex-start;gap:8px;margin:0;padding:11px;border:1px solid #d9e4ef;border-radius:10px;background:#fff;cursor:pointer}.mm-choice-row input{width:16px;height:16px;margin:1px 0 0;accent-color:#2f78d5}.mm-choice-row b{display:block;color:#174472;font-size:10px}.mm-choice-row small{display:block;color:#8090a2;font-size:8.5px;line-height:1.4;margin-top:2px}.mm-choice-row:has(input:checked){border-color:#5d94d4;background:#eef6ff}.mm-info-note{margin-top:9px;padding:10px 11px;border-left:3px solid #3f7fc8;border-radius:7px;background:#eef6ff;color:#5d7189;font-size:9px;line-height:1.5}.mm-info-note b{color:#174472}.mm-info-note code{font-size:8px}.mm-slider-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px}.mm-slider-toolbar b{display:block;color:#173f70;font-size:11px}.mm-slider-toolbar small{display:block;color:#8190a2;font-size:9px;margin-top:2px}.mm-upload-button{cursor:pointer}.mm-upload-status{min-height:18px;color:#3a6f9f;font-size:9px;font-weight:700}.mm-slider-list{display:grid;gap:8px;margin:4px 0 13px}.mm-slider-empty{padding:22px;border:1px dashed #ccd9e7;border-radius:10px;text-align:center;color:#8a98aa;font-size:9px}.mm-slider-row{display:grid;grid-template-columns:100px minmax(0,1fr) auto;gap:10px;align-items:center;padding:8px;border:1px solid #dbe5ef;border-radius:10px;background:#fff}.mm-slider-row>img{width:100px;aspect-ratio:16/9;object-fit:cover;border-radius:7px;background:#edf2f7}.mm-slider-fields{display:grid;gap:5px;min-width:0}.mm-slider-fields b{color:#173f70;font-size:9px}.mm-slider-fields input{padding:7px 8px;font-size:9px}.mm-slider-actions{display:flex;gap:4px}.mm-slider-actions button{width:30px;height:30px;border:1px solid #d6e0eb;border-radius:8px;background:#f6f9fc;color:#315f91;font-weight:900;cursor:pointer}.mm-slider-actions button[data-remove]{color:#b33d3d;background:#fff5f5}.mm-slider-options{margin-top:8px}.mm-inline-checks{display:flex;gap:16px;flex-wrap:wrap;margin-top:10px}.mm-inline-checks label{display:flex;align-items:center;gap:6px;margin:0;color:#50647c;font-size:9px;font-weight:800}.mm-inline-checks input{width:16px;height:16px;accent-color:#2f78d5}.mm-position-select{font-weight:800;color:#174472}.mm-position-preview{display:flex;align-items:center;gap:5px;flex-wrap:wrap;margin-top:10px;padding:10px;border:1px solid #dce6f1;border-radius:10px;background:#f8fbff}.mm-position-preview span{position:relative;padding:6px 8px;border-radius:7px;background:#e9eff6;color:#6c7d91;font-size:7px;font-weight:900;letter-spacing:.3px}.mm-position-preview span.is-mm-after::after{content:'🎬';position:absolute;right:-13px;top:50%;transform:translateY(-50%);z-index:2;width:22px;height:22px;display:grid;place-items:center;border-radius:50%;background:#2f78d5;color:#fff;box-shadow:0 2px 8px rgba(47,120,213,.25)}.mm-position-preview span.is-mm-before::before{content:'🎬';position:absolute;left:-13px;top:50%;transform:translateY(-50%);z-index:2;width:22px;height:22px;display:grid;place-items:center;border-radius:50%;background:#2f78d5;color:#fff}.mm-savebar{margin-top:18px;justify-content:flex-end}.mm-help-item{display:grid;grid-template-columns:34px minmax(0,1fr);gap:9px;padding:11px 0;border-bottom:1px solid #edf1f6}.mm-help-item:last-child{border-bottom:0}.mm-help-item>span{width:32px;height:32px;display:grid;place-items:center;border-radius:9px;background:#eef5fd;color:#2f6fb6;font-size:16px;font-weight:900}.mm-help-item b{display:block;color:#173f70;font-size:10px}.mm-help-item p{margin:3px 0 0;color:#8190a2;font-size:8.5px;line-height:1.45}
@media(max-width:1180px){.multimedia-admin-layout{grid-template-columns:1fr}.multimedia-admin-help{position:relative;top:auto}.mm-type-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:720px){.mm-type-grid{grid-template-columns:1fr 1fr}.mm-facebook-modes{grid-template-columns:1fr}.multimedia-admin-head{flex-direction:column}.mm-master-switch{width:100%}.mm-slider-row{grid-template-columns:74px minmax(0,1fr)}.mm-slider-row>img{width:74px}.mm-slider-actions{grid-column:2}.mm-savebar{flex-direction:column-reverse}.mm-savebar .btn{width:100%}}
@media(max-width:440px){.mm-type-grid{grid-template-columns:1fr}.mm-slider-toolbar{align-items:flex-start;flex-direction:column}.mm-upload-button{width:100%;justify-content:center}}

/* V3.26 Facebook/Reels */
.mm-facebook-modes{grid-template-columns:repeat(3,minmax(0,1fr))}.mm-type-panel [data-mm-fb-api],.mm-type-panel [data-mm-fb-timeline]{margin-top:12px}.mm-type-panel [data-mm-fb-api][hidden],.mm-type-panel [data-mm-fb-timeline][hidden],.mm-grid-links[hidden]{display:none!important}@media(max-width:1050px){.mm-facebook-modes{grid-template-columns:1fr 1fr}}@media(max-width:720px){.mm-facebook-modes{grid-template-columns:1fr}}

/* PDB panel v4 additions */
.pdb-filter{display:flex;align-items:center;gap:12px;margin-bottom:15px;flex-wrap:wrap}.pdb-filter select{max-width:250px}.pdb-filter label{margin:0}
.pdb-metrics{margin-bottom:18px}.pdb-stage-chips{display:flex;flex-wrap:wrap;gap:9px}
.pdb-calendar{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:7px}.pdb-day{display:block;min-height:74px;padding:10px;border:1px solid #dde6f0;border-radius:10px;text-decoration:none;color:#25415f;background:#fbfdff}.pdb-day:hover{background:#eff5fc}.pdb-day strong{display:block}.pdb-day small{color:#7c8da3}
.pdb-label{font-size:11px;color:#65758a}.pdb-split{display:grid;grid-template-columns:1fr 1fr;gap:16px}.pdb-note{padding:10px 13px;background:#eef5ff;border-radius:9px;margin:12px 0;color:#355676}
@media(max-width:850px){.pdb-split{grid-template-columns:1fr}.pdb-calendar{gap:3px}.pdb-day{min-height:54px;padding:5px;font-size:12px}}

.pdb-member-picker{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;max-height:225px;overflow:auto;padding:10px;background:#f8fbff;border:1px solid #e1e9f3;border-radius:10px}.pdb-member-picker label{font-weight:600;padding:5px;display:block}.pdb-member-picker label[hidden]{display:none}.pdb-member-picker input{width:auto;margin-right:6px}@media(max-width:600px){.pdb-member-picker{grid-template-columns:1fr}}

/* Organizador Web v4.3: menu agrupado y responsive */
.pdb-menu-group{margin:4px 0 7px;border:1px solid rgba(191,212,235,.14);border-radius:10px;overflow:hidden}
.pdb-menu-group summary{padding:11px 12px;color:#cfddf1;font-size:12px;font-weight:800;cursor:pointer;display:flex;justify-content:space-between;gap:8px;list-style:none;align-items:center}
.pdb-menu-group summary::-webkit-details-marker{display:none}
.pdb-menu-group[open] summary{background:rgba(255,255,255,.075);color:#fff}
.pdb-menu-chevron{transition:transform .2s}.pdb-menu-group[open] .pdb-menu-chevron{transform:rotate(180deg)}
.pdb-menu-items{padding:4px 5px 8px}.pdb-menu-items .navlink{font-size:12px;margin:1px 0;padding:9px 10px}
.pdb-org-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px}.pdb-org-items{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.pdb-org-option{display:flex;align-items:center;gap:9px;margin:0;padding:10px;border:1px solid #e1e7f0;border-radius:9px;background:#f9fbfe;font-size:12px;cursor:pointer;font-weight:600}
.pdb-org-option input{width:17px;height:17px;flex:none;margin:0}.pdb-org-option:has(input:checked){background:#eaf2ff;border-color:#9ebbe4}
.pdb-org-line{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(0,1fr) 82px;gap:10px;align-items:center;padding:9px 0;border-bottom:1px solid #e8edf5}
.pdb-org-line label{margin:0}.pdb-org-line select,.pdb-org-line input{padding:8px}
@media(max-width:850px){.pdb-org-grid,.pdb-org-items{grid-template-columns:1fr}.pdb-org-line{grid-template-columns:1fr 1fr}.pdb-org-line label{grid-column:1/-1}}
@media(max-width:780px){.pdb-menu-group{display:block}.pdb-menu-group .navlink{display:flex}.pdb-menu-group summary{display:flex}}

/* Organizador Web 4.4: barra superior adaptable */
.pdb44-global-nav{display:flex;gap:9px;align-items:center;flex-wrap:wrap;padding:12px 24px;background:#fff;border-bottom:1px solid #e2e9f3}
.pdb44-global-nav a{border-radius:9px;color:#214364;text-decoration:none;padding:9px 12px;font-size:13px;font-weight:700;background:#f0f5fb}
.pdb44-global-nav a.sel,.pdb44-global-nav a:hover{background:#154779;color:white}
@media(max-width:700px){.pdb44-global-nav{padding:10px;gap:5px}.pdb44-global-nav a{font-size:12px;padding:8px 10px}}
