/* css/mozorro.css */
body{
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--text-dark);
  background: #fff;
}
:root{
  --ui-border: rgba(0,0,0,.10);
  --ui-shadow: 0 18px 55px rgba(0,0,0,.14);
}

.mozorro-debugbox{
  margin: 12px auto;
  width: min(1200px, 92vw);
  padding: 10px 12px;
  border: 2px dashed rgba(200,0,0,.6);
  background: rgba(255,255,255,.95);
  color: #000;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 12px;
  line-height: 1.35;
}

.page-mozorro .mozorro-page{
  width: min(1200px, 92vw);
  margin: 0 auto;
  padding: 24px 0 0px;
}

.mozorro-shell{
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 18px;
  align-items: stretch;
  margin-top: 18px;
}

.mozorro-sidebar{
  background: #fff;
  box-shadow: 0 10px 30px rgba(0,0,0,.08);
  overflow: hidden;
  border: 1px solid rgba(0,0,0,.06);
  min-height: 520px;
  display: flex;
  flex-direction: column;
}

.mozorro-sidebar__head{
  padding: 16px 16px 10px;
  border-bottom: 1px solid rgba(0,0,0,.06);
  background: linear-gradient(180deg, rgba(110,46,160,.08), rgba(110,46,160,0));
}

.mozorro-sidebar__head h2{
  margin: 0;
  font-size: 18px;
}

.mozorro-sidebar__hint{
  margin: 6px 0 0;
  font-size: 13px;
  opacity: .8;
}

.mozorro-list{
  list-style: none;
  padding: 10px;
  margin: 0;
  overflow: auto;
}

.mozorro-item{
padding-bottom:3px;
}

.mozorro-link{
  display: grid;
  gap: 2px;
  padding: 10px 10px;
  text-decoration: none;
  color: inherit;
  border: 1px solid transparent;
}

.mozorro-link__title{ font-weight: 700; font-size: 14px; }
.mozorro-link__meta{ font-size: 12px; opacity: .7; }

/* ITEM SELECCIONADO – borde y sombra morada */
.mozorro-item.is-active .mozorro-link{
  background: rgba(110,46,160,.10);
  border: 2px solid #6e2ea0;
  box-shadow: 0 6px 18px rgba(110,46,160,.35);
}

/* Hover (más suave que el activo) */
.mozorro-link:hover{
  background: rgba(110,46,160,.06);
  border-color: rgba(110,46,160,.35);
}


.mozorro-viewer{
  background: #fff;
  box-shadow: 0 10px 30px rgba(0,0,0,.08);
  border: 1px solid rgba(0,0,0,.06);
  overflow: hidden;
  min-height: 520px;
  display: flex;
  flex-direction: column;
}

.mozorro-viewer__bar{
  padding: 12px 14px;
  border-bottom: 1px solid rgba(0,0,0,.06);
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}

.mozorro-viewer__title{
  font-weight: 800;
  font-size: 14px;
  line-height: 1.2;
}

.mozorro-viewer__actions{
  display: flex;
  gap: 10px;
  align-items: center;
}

.mozorro-btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 10px;
  font-size: 13px;
  text-decoration: none;
  background: #6e2ea0;
  color: #fff;
  border: 1px solid rgba(110,46,160,.35);
}

/* BOTÓN DESCARGAR – morado, borde y negrita */
.mozorro-btn--ghost{
  font-weight: 600;
  border: 2px solid #6e2ea0;
  color: #6e2ea0;
  background: transparent;
}

.mozorro-btn--ghost:hover{
  background: rgba(110,46,160,.08);
}

.mozorro-iframe{
  width: 100%;
  height: 74vh;
  min-height: 520px;
  border: 0;
  background: #f6f6f8;
}

@media (max-width: 980px){
  .mozorro-shell{ grid-template-columns: 1fr; }
  .mozorro-iframe{ height: 70vh; }
}
.mozorro-sidebar{max-height:600px;overflow-y:auto;}

/* Alertas OK / Error */
.mozorro-alert{
  width: min(1200px, 92vw);
  margin: 12px auto 0;
  padding: 12px 14px;
  border: 1px solid rgba(0,0,0,.08);
  background: #fff;
  box-shadow: 0 10px 30px rgba(0,0,0,.06);
  font-size: 14px;
}
.mozorro-alert ul{ margin: 8px 0 0; padding-left: 18px; }
.mozorro-alert--error{
  border-color: rgba(200,0,0,.35);
  background: rgba(255,0,0,.04);
}
.mozorro-alert--ok{
  border-color: rgba(0,160,90,.35);
  background: rgba(0,160,90,.06);
}

/* Bloque "Subir revista" */
.mozorro-upload{
  margin-top: 10px;
}
.mozorro-upload__summary{
  cursor: pointer;
  user-select: none;
  display: inline-flex;
  gap: 8px;
  align-items: center;
  padding: 8px 10px;
  border: 2px solid rgba(110,46,160,.45);
  color: #6e2ea0;
  font-weight: 800;
  background: rgba(110,46,160,.06);
}
.mozorro-upload[open] .mozorro-upload__summary{
  box-shadow: 0 6px 18px rgba(110,46,160,.25);
}

.mozorro-upload__form{
  margin-top: 10px;
  display: grid;
  gap: 10px;
}

.mozorro-field{
  display: grid;
  gap: 6px;
  font-size: 13px;
}
.mozorro-field span{
  font-weight: 700;
  opacity: .85;
}
.mozorro-field input[type="number"],
.mozorro-field input[type="file"]{
  width: 100%;
  padding: 9px 10px;
  border: 1px solid rgba(0,0,0,.18);
  outline: none;
}
.mozorro-field input[type="number"]:focus,
.mozorro-field input[type="file"]:focus{
  border-color: rgba(110,46,160,.6);
  box-shadow: 0 0 0 3px rgba(110,46,160,.12);
}

.mozorro-btn--upload{
  font-weight: 800;
}

.mozorro-upload__note{
  font-size: 12px;
  opacity: .8;
}
