:root {
  --bg: #f7f7f5;
  --surface: #ffffff;
  --text: #1c1c1a;
  --muted: #6b6b66;
  --border: #e4e4df;
  --accent: #0f766e;
  --accent-text: #ffffff;
  --wa: #1fa855;
  --wa-hover: #188a45;
  --reserved: #b45309;
  --sold: #b91c1c;
  --stock: #facc15;
  --stock-soft: #fef9c3;
  --stock-text: #422006;
  /* La cinta es un dorado más oscuro que el recuadro para que la letra blanca se lea. */
  --stock-ribbon: #e0a000;
  --stock-card: #fffbe6;
  --radius: 12px;
  --shadow: 0 1px 2px rgb(0 0 0 / 0.06), 0 2px 8px rgb(0 0 0 / 0.04);
  color-scheme: light;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent);
}

[hidden] {
  display: none !important;
}

.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 16px;
  flex: 1;
}

.container.narrow {
  max-width: 640px;
}

/* Encabezado y pie */
.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 6px 16px;
  position: sticky;
  top: 0;
  z-index: 10;
}

.brand {
  display: inline-block;
  line-height: 0;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--text);
  text-decoration: none;
}

/* Logo: el archivo es del doble del tamaño en que se muestra, para que se vea nítido. */
.brand-logo {
  height: 56px;
  width: auto;
}

@media (min-width: 640px) {
  .brand-logo {
    height: 64px;
  }
}

.site-footer {
  color: var(--muted);
  font-size: 0.85rem;
  text-align: center;
  padding: 24px 16px;
}

/* Filtros */
.filters {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.8rem;
  color: var(--muted);
  min-width: 0;
}

.field select,
.field input {
  font: inherit;
  font-size: 1rem;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 10px;
  width: 100%;
  min-width: 0;
}

.sizes {
  grid-column: 1 / -1;
  border: 0;
  margin: 0;
  padding: 0;
}

.sizes legend {
  font-size: 0.8rem;
  color: var(--muted);
  padding: 0;
  margin-bottom: 6px;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.chip input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.chip span {
  display: inline-block;
  min-width: 42px;
  text-align: center;
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg);
  cursor: pointer;
  user-select: none;
}

.chip input:checked + span {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-text);
}

.chip input:focus-visible + span {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* «Solo en stock»: amarillo, como el recuadro de los productos en stock. */
.chip-stock span {
  border-color: var(--stock);
  background: var(--stock-soft);
  color: var(--stock-text);
  font-weight: 600;
}

.chip-stock input:checked + span {
  background: var(--stock);
  border-color: var(--stock);
  color: var(--stock-text);
}

.chip-stock input:checked + span::before {
  content: "✓ ";
}

.filter-actions {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.filter-buttons {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-left: auto;
}

.link-muted {
  color: var(--muted);
  font-size: 0.9rem;
}

.result-count {
  color: var(--muted);
  font-size: 0.9rem;
  margin: 14px 2px 8px;
}

.empty {
  text-align: center;
  color: var(--muted);
  padding: 32px 0;
}

/* Grilla de productos */
.grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  /* Deja lugar para la cinta «En stock», que sale del borde izquierdo de la tarjeta. */
  gap: 14px;
}

/* Sin overflow: hidden, para que la cinta «En stock» pueda salir del borde; la foto se recorta en .card-media. */
.card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
}

.card-link {
  color: inherit;
  text-decoration: none;
  flex: 1;
}

.card-media {
  position: relative;
  aspect-ratio: 1 / 1;
  background: var(--border);
  border-radius: calc(var(--radius) - 1px) calc(var(--radius) - 1px) 0 0;
  overflow: hidden;
}

.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.no-photo {
  display: grid;
  place-items: center;
  height: 100%;
  min-height: 160px;
  color: var(--muted);
  font-size: 0.85rem;
}

.badge {
  position: absolute;
  top: 8px;
  left: 8px;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 999px;
  color: #fff;
}

.badge-reserved {
  background: var(--reserved);
}

/*
 * Producto en stock: recuadro amarillo de 3 px (1 de borde + 2 de sombra, para no mover el contenido),
 * fondo apenas amarillento y una cinta «EN STOCK» que sale por el borde izquierdo,
 * escrita de abajo hacia arriba.
 */
.card-stock {
  background: var(--stock-card);
  border-color: var(--stock);
  box-shadow: 0 0 0 2px var(--stock), var(--shadow);
}

.card-stock .tag {
  background: var(--surface);
}

.stock-tag {
  position: absolute;
  z-index: 2;
  top: 14px;
  /* Sale 7 px por fuera del recuadro; entra en el espacio entre tarjetas (14 px en el celular). */
  left: -10px;
  writing-mode: vertical-rl;
  background: var(--stock-ribbon);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
  padding: 10px 5px;
  border-radius: 4px;
  box-shadow: 2px 2px 4px rgb(0 0 0 / 0.25);
}

/* Solo el texto va girado 180°, para que se lea de abajo hacia arriba sin dar vuelta la sombra de la cinta. */
.stock-tag > span {
  display: block;
  transform: rotate(180deg);
  /* Por el giro, «-1px» queda hacia abajo en pantalla. */
  text-shadow: 0 -1px 1px rgb(0 0 0 / 0.35);
}

.card-body {
  padding: 10px 10px 4px;
}

.card-title {
  font-size: 0.95rem;
  font-weight: 500;
  margin: 0 0 4px;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.price {
  font-weight: 700;
  margin: 0;
  white-space: nowrap;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 6px 0 0;
}

.tag {
  font-size: 0.75rem;
  color: var(--muted);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0 6px;
}

.tag-order {
  color: var(--text);
  font-weight: 600;
}

/* Botones */
.btn,
.btn-wa {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  border: 0;
  border-radius: 10px;
  padding: 12px 18px;
  cursor: pointer;
}

.btn {
  background: var(--accent);
  color: var(--accent-text);
}

.btn-wa {
  background: var(--wa);
  color: #fff;
  width: 100%;
}

.btn-wa:hover {
  background: var(--wa-hover);
}

.btn-small {
  margin: 8px 10px 10px;
  width: auto;
  padding: 8px 10px;
  font-size: 0.9rem;
}

.icon {
  flex: none;
}

/* Página de producto */
.product-layout {
  display: grid;
  gap: 16px;
}

.gallery {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 8px;
  border-radius: var(--radius);
  -webkit-overflow-scrolling: touch;
}

.gallery img {
  flex: 0 0 100%;
  width: 100%;
  max-height: 75vh;
  object-fit: contain;
  background: var(--border);
  scroll-snap-align: center;
  border-radius: var(--radius);
}

.gallery-hint {
  color: var(--muted);
  font-size: 0.8rem;
  margin: -8px 0 0;
  text-align: center;
}

.product-info h1 {
  font-size: 1.4rem;
  line-height: 1.25;
  margin: 0 0 6px;
}

.price-big {
  font-size: 1.5rem;
  margin-bottom: 12px;
}

/* «En stock» o «Por encargo» en la página del producto, con lo que significa para el comprador. */
.availability {
  margin: 0 0 14px;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 0.95rem;
}

.availability strong {
  display: block;
}

.availability-stock {
  background: var(--stock-card);
  border: 2px solid var(--stock);
}

.availability-order {
  background: var(--bg);
  border: 1px solid var(--border);
}

.facts {
  list-style: none;
  padding: 0;
  margin: 0 0 16px;
  border-top: 1px solid var(--border);
}

.facts li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
}

.facts li span {
  color: var(--muted);
}

.description {
  white-space: pre-line;
  margin: 0 0 20px;
}

.banner {
  font-weight: 600;
  padding: 10px 12px;
  border-radius: 10px;
  margin: 0 0 12px;
  color: #fff;
}

.banner-sold {
  background: var(--sold);
}

.banner-reserved {
  background: var(--reserved);
}

/* Página de vendedora */
.seller-head {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 8px 0 16px;
}

.seller-head h1 {
  font-size: 1.4rem;
  line-height: 1.25;
  margin: 0;
}

.seller-photo {
  width: 96px;
  height: 96px;
  flex: none;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--border);
}

.seller-initial {
  display: grid;
  place-items: center;
  background: var(--accent);
  color: var(--accent-text);
  font-size: 2.4rem;
  font-weight: 600;
}

.seller-sales {
  color: var(--muted);
  margin: 2px 0 0;
}

.seller-actions {
  display: grid;
  gap: 10px;
  margin: 0 0 20px;
}

.seller-actions .btn {
  text-align: center;
}

.seller-help {
  text-align: center;
  margin: 24px 0 0;
}

@media (min-width: 640px) {
  .filters {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .grid {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
  }
}

@media (min-width: 900px) {
  .product-layout {
    grid-template-columns: 3fr 2fr;
    align-items: start;
  }

  .gallery-hint {
    grid-column: 1;
  }

  .product-info {
    grid-column: 2;
    grid-row: 1 / span 2;
    position: sticky;
    top: 92px;
  }
}

/* Página de carga (/admin) */
.admin h1 {
  font-size: 1.3rem;
  margin: 0;
}

.admin-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}

.link-button {
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  text-decoration: underline;
  font: inherit;
}

.admin-hint {
  color: var(--muted);
  font-size: 0.9rem;
  margin: 0 0 12px;
}

.admin-login {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.admin-error {
  color: var(--sold);
  margin: 0;
}

.chat-log {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
}

.bubble {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  padding: 10px 12px;
  border-radius: 12px;
  max-width: 92%;
  font-size: 0.95rem;
}

.bubble-me {
  align-self: flex-end;
  background: #dcf3ee;
}

.bubble-bot {
  align-self: flex-start;
  background: var(--surface);
  border: 1px solid var(--border);
}

.quick-commands {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

.chip-button {
  font: inherit;
  font-size: 0.85rem;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
}

.admin-form {
  display: grid;
  gap: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px;
}

.admin-form textarea {
  font: inherit;
  font-size: 1rem;
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px;
  background: var(--bg);
  color: var(--text);
  resize: vertical;
}

.preview {
  display: flex;
  gap: 6px;
  overflow-x: auto;
}

.preview img {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 8px;
  flex: none;
}

.admin-actions {
  display: flex;
  gap: 10px;
}

.admin-actions .btn {
  flex: 1;
}

.btn-secondary {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn:disabled {
  opacity: 0.6;
}

.admin-status {
  color: var(--muted);
  font-size: 0.85rem;
  margin: 0;
  min-height: 1.2em;
}

/* Panel de administración: pestañas, listas y mensajes */
.admin-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 14px;
}

.admin-tabs a {
  padding: 10px 12px;
  color: var(--muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  font-weight: 500;
}

.admin-tabs a.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.admin-logout {
  margin-left: auto;
}

.admin h2 {
  font-size: 1.1rem;
  margin: 20px 0 10px;
}

.flash {
  border-radius: 10px;
  padding: 10px 12px;
  margin-bottom: 14px;
  font-size: 0.95rem;
}

.flash p {
  margin: 0 0 4px;
}

.flash-ok {
  background: #e6f6ef;
  border: 1px solid #b9e5d1;
}

.flash-error {
  background: #fdecec;
  border: 1px solid #f4c2c2;
}

.telegram-hint {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin-top: 6px;
  font-size: 0.85rem;
  color: var(--muted);
}

.telegram-hint code {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1px 6px;
  color: var(--text);
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.segmented {
  display: flex;
  gap: 6px;
  margin-bottom: 10px;
}

.segmented a {
  flex: 1;
  text-align: center;
  padding: 8px;
  border: 1px solid var(--border);
  border-radius: 8px;
  text-decoration: none;
  color: var(--text);
  background: var(--surface);
}

.segmented a.active {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-text);
}

.admin-search {
  width: 100%;
  font: inherit;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 10px;
  background: var(--surface);
}

.admin-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 10px;
}

.admin-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px;
}

.admin-item-main {
  display: flex;
  gap: 10px;
  color: inherit;
  text-decoration: none;
}

.admin-item-main img,
.admin-item-main .no-photo {
  width: 64px;
  height: 64px;
  min-height: 0;
  object-fit: cover;
  border-radius: 8px;
  flex: none;
  background: var(--border);
}

.admin-item-title {
  font-weight: 600;
  margin: 0;
}

.admin-item-meta {
  color: var(--muted);
  font-size: 0.85rem;
  margin: 2px 0 4px;
}

.admin-item-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.admin-item-actions form {
  margin: 0;
}

.admin-item-actions a.chip-button {
  text-decoration: none;
}

.badge-inline {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 1px 8px;
  border-radius: 999px;
  color: #fff;
  background: var(--accent);
}

.badge-inline.status-reservado {
  background: var(--reserved);
}

.badge-inline.status-vendido {
  background: var(--sold);
}

.chip-button.status-vendido {
  border-color: #f4c2c2;
}

.chip-button.status-reservado {
  border-color: #f3d3a8;
}

.admin-edit .field select,
.admin-edit .field input,
.admin-edit .field textarea {
  font: inherit;
  font-size: 1rem;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 10px;
  width: 100%;
}

.admin-form .field input {
  font: inherit;
  font-size: 1rem;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
}

.inline-form {
  display: flex;
  gap: 6px;
  margin-top: 6px;
}

.inline-form input {
  flex: 1;
  min-width: 0;
  font: inherit;
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
}
/* Botones del borrador: atenuados hasta que hay borrador; Publicar resaltado solo cuando está listo */
.draft-actions {
  margin-top: 14px;
}

.draft-actions-title {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0 0 6px;
}

.draft-button {
  opacity: 0.45;
}

.draft-button.is-active {
  opacity: 1;
  border-color: var(--accent);
  color: var(--accent);
  font-weight: 600;
}

.draft-button.draft-publish.is-active {
  background: var(--accent);
  color: var(--accent-text);
}

.draft-help {
  margin-left: auto;
}
.category-form {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 6px;
  align-items: end;
  margin-top: 8px;
}

.category-form .field input {
  font: inherit;
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
  width: 100%;
}

@media (max-width: 480px) {
  .category-form {
    grid-template-columns: 1fr;
  }
}
/* Borrado: botones de peligro y confirmación */
.btn-danger {
  background: var(--sold);
  color: #fff;
  width: 100%;
}

.btn-danger-outline {
  background: transparent;
  color: var(--sold);
  border: 1px solid var(--sold);
}

.link-danger {
  display: inline-block;
  margin-top: 8px;
  font-size: 0.85rem;
  color: var(--sold);
}

.danger-zone {
  margin-top: 28px;
  padding-top: 14px;
  border-top: 1px dashed var(--border);
}

.danger-zone p {
  color: var(--muted);
  font-size: 0.85rem;
  margin: 0 0 8px;
}

.flash-warning {
  background: #fff5e6;
  border: 1px solid #f3d3a8;
}

.confirm-form {
  flex: 1;
  margin: 0;
}
/* Fotos del producto en «Editar», con su número y el botón Quitar */
.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
  gap: 8px;
  margin: 10px 0;
}

.photo-item {
  margin: 0;
}

.photo-item img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 8px;
  background: var(--border);
}

.photo-item figcaption {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 2px;
}

.photo-item form {
  margin: 0;
}

.photo-item .link-danger {
  margin: 0;
}
/* Agregar fotos y elegir portada en «Editar» */
.photo-cover {
  font-size: 0.75rem;
  padding: 0;
  margin-top: 2px;
}

.add-photos {
  margin: 4px 0 12px;
}

.add-photos .btn {
  width: 100%;
}
/* Tipo de producto y talles múltiples en «Editar» */
.badge-kind {
  background: #4b5563;
}

.sizes-field,
.stock-field {
  border: 0;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 6px;
}

.sizes-field legend,
.stock-field legend {
  font-size: 0.8rem;
  color: var(--muted);
  padding: 0;
  margin-bottom: 4px;
}

.check {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
}

/* Casillas y botones de opción dentro de un campo: no se estiran como los cuadros de texto. */
.field .check input[type="checkbox"],
.field .check input[type="radio"] {
  width: auto;
  flex: none;
  margin: 0;
  padding: 0;
}

/* Las opciones de stock son largas: el texto se acomoda en varias líneas junto al botón. */
.stock-field .check {
  align-items: flex-start;
}

.stock-field .check input[type="radio"] {
  margin-top: 3px;
}

/* Stock en el panel: «En stock» en amarillo, como la cinta del catálogo; «Por encargo» en gris. */
.badge-inline.stock-yes {
  background: var(--stock);
  color: var(--stock-text);
}

.badge-inline.stock-no {
  background: #e5e7eb;
  color: #374151;
}

.chip-button.stock-yes {
  border-color: var(--stock);
}

/* Pregunta «¿Sigue habiendo stock?» después de vender un recargable. */
.stock-question {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed #b9e5d1;
}

.stock-question .admin-item-actions {
  margin-top: 4px;
}

/* «Llegó stock» / «Se terminó el stock» en un recargable con varios talles: se abre para elegir los talles. */
.stock-sizes > summary {
  list-style: none;
  display: inline-block;
}

.stock-sizes > summary::-webkit-details-marker {
  display: none;
}

.stock-sizes > summary::after {
  content: " ▾";
}

.stock-sizes[open] {
  flex-basis: 100%;
}

.stock-sizes[open] > summary::after {
  content: " ▴";
}

.stock-sizes form {
  display: grid;
  gap: 8px;
  margin-top: 8px;
  padding: 10px;
  border: 1px dashed var(--border);
  border-radius: 8px;
}

.stock-sizes .admin-hint {
  margin: 0;
}
/* Ayuda de formato en «Cargar» */
.caption-help {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 12px;
  margin-bottom: 12px;
}

.caption-help summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--accent);
}

.caption-examples {
  display: grid;
  gap: 10px;
  margin-top: 10px;
}

@media (min-width: 640px) {
  .caption-examples {
    grid-template-columns: 1fr 1fr;
  }
}

.caption-example {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px;
  background: var(--bg);
}

.caption-example-title {
  font-weight: 600;
  margin: 0;
}

.caption-example .admin-hint {
  margin: 2px 0 6px;
}

.caption-example pre {
  white-space: pre-wrap;
  font-size: 0.85rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px;
  margin: 0 0 8px;
}

.caption-notes {
  margin: 10px 0 0;
  padding-left: 18px;
  font-size: 0.9rem;
  display: grid;
  gap: 4px;
}

.caption-notes code {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 0 4px;
}