/* PDF Builder: follows the site's white, monochrome look. */
:root {
  --pb-width: 330px;
  --pb-line: #e4e4e4;
  --pb-muted: #6f6f6f;
}

.pb-launcher,
.pb-panel,
.pb-panel button,
.pb-panel select {
  font-family: Aldrich, Verdana, sans-serif;
}

.pb-launcher {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 9998;
  padding: 13px 20px;
  border: 0;
  background: #000;
  color: #fff;
  font-family: Aldrich, Verdana, sans-serif;
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
}
.pb-launcher:hover { background: #333; }
.pb-launcher {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.pb-launcher::before {
  content: "";
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  margin: -10px -4px -10px -8px;
  background: url("https://andrenunez.com/wp-content/uploads/2026/11/ICONE_PDF-2.png") center / 36px no-repeat;
}
.pb-launcher[hidden] { display: none; }
.pb-open .pb-launcher { display: none; }

.pb-panel {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 9999;
  display: none;
  flex-direction: column;
  width: var(--pb-width);
  border-left: 1px solid var(--pb-line);
  background: #fff;
  color: #000;
  font-size: 12px;
  line-height: 1.5;
  text-align: left;
  box-sizing: border-box;
}
.pb-panel *,
.pb-panel *::before,
.pb-panel *::after { box-sizing: border-box; }
.pb-open .pb-panel { display: flex; }
/* The theme sizes the grid from #pagina's padding, so that is what makes room for the panel. */
.pb-open #pagina { padding-right: calc(35px + var(--pb-width)); }

.pb-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px 6px;
}
.pb-head h2 {
  margin: 0;
  font: 400 17px Aldrich, Verdana, sans-serif;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  outline: none;
}
.pb-close {
  width: 32px;
  height: 32px;
  margin-right: -8px;
  border: 0;
  background: none;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}
.pb-hint {
  margin: 0;
  padding: 0 20px 14px;
  border-bottom: 1px solid var(--pb-line);
  color: var(--pb-muted);
}

.pb-list {
  flex: 1;
  min-height: 0;
  margin: 0;
  padding: 0;
  overflow-y: auto;
  list-style: none;
}
.pb-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 7px 20px;
  border-top: 2px solid transparent;
  border-bottom: 2px solid transparent;
  cursor: grab;
}
.pb-list li:hover { background: #f6f6f6; }
.pb-list li.pb-dragging { opacity: 0.35; }
.pb-list li.pb-drop-before { border-top-color: #000; }
.pb-list li.pb-drop-after { border-bottom-color: #000; }
.pb-num {
  width: 18px;
  color: var(--pb-muted);
  font-variant-numeric: tabular-nums;
  text-align: right;
}
.pb-list img {
  display: block;
  width: 56px;
  height: 56px;
  object-fit: cover;
  pointer-events: none;
}
.pb-actions {
  display: flex;
  margin-left: auto;
}
.pb-actions button {
  width: 30px;
  height: 30px;
  border: 0;
  background: none;
  color: #000;
  font-size: 14px;
  cursor: pointer;
}
.pb-actions button:hover:not(:disabled) { background: #e8e8e8; }
.pb-actions button:disabled { color: #c9c9c9; cursor: default; }

.pb-foot {
  padding: 14px 20px 18px;
  border-top: 1px solid var(--pb-line);
}
.pb-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}
.pb-options label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--pb-muted);
}
.pb-lang {
  padding: 3px;
  border: 1px solid #bbb;
  background: #fff;
  color: #000;
  font-size: 12px;
}
.pb-clear {
  padding: 4px 0;
  border: 0;
  background: none;
  color: var(--pb-muted);
  font-size: 12px;
  text-decoration: underline;
  cursor: pointer;
}
.pb-clear:hover { color: #000; }
.pb-clear[hidden] { display: none; }
.pb-download {
  width: 100%;
  padding: 13px;
  border: 0;
  background: #000;
  color: #fff;
  font-size: 13px;
  cursor: pointer;
}
.pb-download:hover:not(:disabled) { background: #333; }
.pb-download:disabled { background: #cfcfcf; color: #fff; cursor: default; }
.pb-status {
  min-height: 18px;
  margin: 9px 0 0;
  color: var(--pb-muted);
}
.pb-status.pb-error { color: #a4161a; }

.pb-launcher:focus-visible,
.pb-panel button:focus-visible,
.pb-panel select:focus-visible,
.pb-open .portfolio-item a:focus-visible {
  outline: 2px solid #000;
  outline-offset: 2px;
}

/* Gallery while selecting */
.pb-open .portfolio-item a { cursor: copy; }
.portfolio-item.pb-selected a { cursor: pointer; }
.pb-open .portfolio-item { position: relative; }
.pb-open .portfolio-item img { transition: opacity 0.12s; }
.pb-open .portfolio-item:hover img { opacity: 0.8; }
.pb-open .portfolio-item.pb-selected img { opacity: 0.45; }
.pb-open .portfolio-item.pb-selected::after {
  content: attr(data-pb-number);
  position: absolute;
  top: 8px;
  left: 8px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #000;
  color: #fff;
  font: 400 12px/26px Aldrich, Verdana, sans-serif;
  text-align: center;
  pointer-events: none;
}

@media (max-width: 760px) {
  .pb-open #pagina { padding-right: 35px; padding-bottom: 58vh; }
  .pb-panel {
    top: auto;
    left: 0;
    width: auto;
    height: 58vh;
    border-top: 1px solid var(--pb-line);
    border-left: 0;
  }
  .pb-list li { cursor: default; }
  .pb-launcher { right: 12px; bottom: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  .pb-open .portfolio-item img { transition: none; }
}
