/* Créditos laterales y acabados de la interfaz móvil. */
.btn-creditos {
  display: grid;
  place-items: center;
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  padding: 7px;
  border: 1px solid rgba(218, 182, 112, .35);
  border-radius: 10px;
  background: rgba(255, 255, 255, .05);
  color: var(--header-text);
}
.btn-creditos svg { width: 21px; height: 21px; }
.btn-creditos:hover, .btn-creditos[aria-expanded="true"] { background: rgba(218, 182, 112, .17); }
.btn-creditos:focus-visible, .panel-creditos button:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.modal-creditos { padding: 0; align-items: stretch; justify-content: flex-start; }
.panel-creditos {
  width: min(340px, calc(100vw - 28px));
  margin: 0;
  flex-shrink: 0;
  height: 100%;
  max-height: 100vh;
  max-height: 100dvh;
  padding: 22px 20px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  border-radius: 0 20px 20px 0;
  border-left: 0;
  overflow-x: hidden;
  overscroll-behavior-y: contain;
}
.creditos-cabecera { display: flex; align-items: center; justify-content: space-between; }
.creditos-cabecera > img { width: 44px; height: 44px; object-fit: contain; }
.btn-cerrar-creditos { display: grid; place-items: center; width: 34px; height: 34px; padding: 7px; border: 1px solid var(--line); border-radius: 50%; background: var(--surface); color: var(--primary); }
.btn-cerrar-creditos svg { width: 19px; height: 19px; }
.creditos-etiqueta { margin: 26px 0 6px; color: var(--gold-2); font-size: 11px; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; }
.panel-creditos h2 { margin: 0 0 7px; font-size: 25px; line-height: 1.15; }
.creditos-autor { margin: 0; color: var(--text-soft); font-size: 14px; line-height: 1.5; }
.creditos-autor strong { color: var(--primary); }
.creditos-imagen { margin: 26px 0 16px; padding: 12px; border: 1px solid var(--line); border-radius: 18px; background: #f8eddc; text-align: center; }
.creditos-imagen img { display: block; width: 100%; height: auto; max-height: 34vh; object-fit: contain; }
.creditos-imagen figcaption { margin: 9px 0 2px; color: var(--primary); font-size: 21px; line-height: 1.2; font-weight: 800; }
.btn-volver-trabajo { min-height: 38px; border-radius: 10px; background: var(--primary); color: #fff8ef; font-size: 13px; font-weight: 700; }
.creditos-pie { margin-top: auto; padding-top: 28px; color: var(--text-soft); font-size: 11.5px; line-height: 1.6; text-align: center; }
.modal-creditos:not(.oculto) { animation: creditos-fondo .18s ease-out both; }
.modal-creditos:not(.oculto) .panel-creditos { animation: creditos-entrada .22s ease-out both; }
.modal-creditos.cerrando { animation: creditos-fondo .18s ease-in reverse both; }
.modal-creditos.cerrando .panel-creditos { animation: creditos-salida .18s ease-in both; }
@keyframes creditos-fondo { from { opacity: 0; } to { opacity: 1; } }
@keyframes creditos-entrada { from { transform: translateX(-100%); } to { transform: translateX(0); } }
@keyframes creditos-salida { from { transform: translateX(0); } to { transform: translateX(-100%); } }
.solo-lector { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.categorias-ventana { flex: 1; min-width: 0; }
.categorias-indicador { display: none; }
.btn-cat-nav svg { width: 14px; height: 14px; }

@media (max-width: 768px) {
  .encabezado-marca { gap: 6px; }
  .btn-creditos { flex-basis: 32px; width: 32px; height: 34px; padding: 6px; }
  #nuevo-presentaciones .nuevo-precio::placeholder,
  #edit-presentaciones .input-precio::placeholder,
  #edit-presentaciones .input-precio-nuevo::placeholder { font-size: 11.5px; letter-spacing: 0; }

  .categorias-nav-wrapper {
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr) 30px;
    align-items: start;
    gap: 4px;
    padding: 4px;
    margin-bottom: 12px;
    border: 1px solid var(--line);
    border-radius: 13px;
    background: rgba(255, 253, 249, .7);
    box-shadow: 0 2px 5px rgba(61, 42, 30, .04);
  }
  .categorias-ventana { position: relative; height: 36px; overflow: hidden; }
  .barra-categorias {
    height: 32px;
    align-items: center;
    gap: 6px;
    padding: 0;
    scrollbar-width: none;
    scroll-snap-type: x proximity;
    scroll-padding-inline: 2px;
    overscroll-behavior-x: contain;
    overscroll-behavior-y: auto;
  }
  .barra-categorias::-webkit-scrollbar { display: none; }
  .barra-categorias .pill-categoria {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 32px;
    min-height: 32px;
    padding: 0 11px;
    border-width: 1px;
    border-radius: 9px;
    font-size: 12.5px;
    line-height: 1;
    scroll-snap-align: start;
    box-shadow: none;
  }
  .barra-categorias .pill-categoria:hover { transform: none; }
  .barra-categorias .pill-categoria.activa { box-shadow: 0 1px 3px rgba(78, 52, 46, .12); }
  .categorias-nav-wrapper .btn-cat-nav {
    width: 30px;
    height: 32px;
    min-height: 32px;
    margin: 0;
    padding: 0;
    border-width: 1px;
    border-radius: 9px;
    box-shadow: none;
    background: var(--surface);
  }
  .categorias-nav-wrapper .btn-cat-nav:hover { transform: none; background: #f2e5d3; }
  .categorias-nav-wrapper .btn-cat-nav:disabled { opacity: .3; cursor: default; background: transparent; }
  .categorias-nav-wrapper button:focus-visible { outline: 2px solid var(--gold); outline-offset: -2px; }
  .categorias-ventana::before, .categorias-ventana::after { content: ''; position: absolute; top: 0; width: 14px; height: 32px; z-index: 1; pointer-events: none; opacity: 0; transition: opacity .15s; }
  .categorias-ventana::before { left: 0; background: linear-gradient(90deg, #fbf6ef, transparent); }
  .categorias-ventana::after { right: 0; background: linear-gradient(-90deg, #fbf6ef, transparent); }
  [data-puede-prev="true"] .categorias-ventana::before, [data-puede-next="true"] .categorias-ventana::after { opacity: 1; }
  .categorias-indicador { display: block; position: absolute; bottom: 0; left: 4px; right: 4px; height: 2px; border-radius: 99px; background: #eadfce; overflow: hidden; }
  .categorias-indicador[hidden] { display: none; }
  .categorias-progreso { position: absolute; top: 0; height: 2px; border-radius: 99px; background: #b28a5c; }
}
@media (max-width: 480px) {
  .titulo-marca h1 { font-size: 13.5px; line-height: 1.15; white-space: normal; text-overflow: clip; }
  .titulo-marca h1 span { display: block; }
}
@media (prefers-reduced-motion: reduce) {
  .modal-creditos, .modal-creditos .panel-creditos { animation: none !important; }
  .barra-categorias { scroll-behavior: auto; }
  .categorias-ventana::before, .categorias-ventana::after { transition: none; }
}
