/* MotoJungla — catálogo público de motos (resultados + ficha opción A) */
.mjm {
  --a: var(--wp--preset--color--lime, #c6f154);
  --bg: #0b1115; --card: #141c21; --line: #2a3840; --muted: #a9b7bd; --text: #f2f5f2;
  color: var(--text); font-size: 14px; line-height: 1.4; margin: 0 auto; padding: 0 20px 40px;
}
body.mjm-page .wp-block-post-content { max-width: none !important; }
body.mjm-page .mj-main { padding-left: 0 !important; padding-right: 0 !important; padding-top: 0 !important; margin-top: 0 !important; }
body.mjm-page .mj-main > .wp-block-post-content > * { margin-block-start: 0; }
/* Cabecera compacta solo en esta página (el resto del sitio no cambia). */
body.mjm-page .mj-header { padding-left: 20px !important; padding-right: 20px !important; }
body.mjm-page .mj-header-inner { max-width: none !important; padding-block: 4px !important; }
body.mjm-page .mj-logo, body.mjm-page .mj-logo a { height: auto !important; }
body.mjm-page .mj-logo img { max-height: 50px !important; width: auto !important; }
body.mjm-page .mj-home-nav-primary > a, body.mjm-page .mj-home-nav-primary > details > summary { display: inline-flex !important; flex-direction: row !important; align-items: center; gap: 6px; font-size: 14px; }
body.mjm-page .mj-home-nav-primary .dashicons { margin: 0 !important; }
.wp-site-blocks .mjm.alignfull { box-sizing: border-box; max-width: none; margin-left: auto !important; margin-right: auto !important; width: 100%; }
.mjm *, .mjm *::before, .mjm *::after { box-sizing: border-box; }
.mjm a { color: inherit; }
.mjm button, .mjm input, .mjm select { font: inherit; }
.mjm :focus-visible { outline: 3px solid var(--a); outline-offset: 2px; }
.mjm .screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mjm-btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; min-height: 46px; padding: 0 1.2rem; border-radius: .7rem;
  background: var(--a); color: #10180a !important; font-weight: 800; text-decoration: none; border: 0; cursor: pointer; }

/* ---------- Cabecera y barra ---------- */
.mjm-head { display: flex; align-items: baseline; gap: .8rem; flex-wrap: wrap; margin: 14px 0 10px; }
.mjm-head h1 { margin: 0; font-size: clamp(22px, 1.6vw, 27px); line-height: 1.15; font-weight: 650; letter-spacing: -.01em; }
.mjm-total { margin: 0; color: var(--muted); border-left: 1px solid var(--line); padding-left: .9rem; }
.mjm-total { font-size: 14px; }
.mjm-total strong { color: var(--text); font-weight: 650; }
.mjm-toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.mjm-search { flex: 1 1 320px; }
.mjm-search input, .mjm-sort select, .mjm-filters input, .mjm-filters select {
  width: 100%; min-height: 40px; padding: 0 .75rem; border-radius: .55rem; border: 1px solid var(--line); background: var(--card); color: var(--text); font-size: 14px; }
.mjm-search input { padding-left: 2.4rem; background: var(--card) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' fill='none' stroke='%23a9b7bd' stroke-width='2'%3E%3Ccircle cx='8' cy='8' r='6'/%3E%3Cpath d='m13 13 4 4'/%3E%3C/svg%3E") no-repeat .8rem 50%; }
.mjm-sort { flex: 0 0 auto; min-width: 210px; }
.mjm-open-filters { display: none; min-height: 44px; padding: 0 1rem; border-radius: .6rem; border: 1.5px solid var(--a); background: transparent; color: var(--a); font-weight: 700; cursor: pointer; }
.mjm-view { display: flex; border: 1px solid var(--line); border-radius: .6rem; overflow: hidden; }
.mjm-view a { width: 42px; height: 38px; display: grid; place-items: center; }
.mjm-view a::before { content: ""; width: 18px; height: 18px; background: var(--muted);
  -webkit-mask: var(--i) center/contain no-repeat; mask: var(--i) center/contain no-repeat; }
.mjm-view .is-grid { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 18 18'%3E%3Cpath d='M1 1h7v7H1zm9 0h7v7h-7zM1 10h7v7H1zm9 0h7v7h-7z'/%3E%3C/svg%3E"); }
.mjm-view .is-list { --i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 18 18'%3E%3Cpath d='M1 2h3v3H1zm5 0h11v3H6zM1 8h3v3H1zm5 0h11v3H6zm-5 6h3v3H1zm5 0h11v3H6z'/%3E%3C/svg%3E"); }
.mjm-view a[aria-current] { background: var(--a); }
.mjm-view a[aria-current]::before { background: #10180a; }

.mjm-chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 0 0 12px; }
.mjm-chip { display: inline-flex; gap: .4rem; align-items: center; min-height: 30px; padding: 0 .7rem; border: 1px solid var(--a); color: var(--a) !important; border-radius: 999px; text-decoration: none; font-size: 13px; font-weight: 500; }
.mjm-chip span { font-size: 1.1em; line-height: 1; }
.mjm-clear { color: var(--a) !important; font-size: 13px; }

/* ---------- Layout con filtros ---------- */
.mjm-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 16px; align-items: start; }
/* Una sola zona desplazable: la barra lateral. «Filtros» y «Limpiar» quedan fijos arriba. */
.mjm-aside { position: sticky; top: 12px; max-height: calc(100vh - 24px); overflow-y: auto; overscroll-behavior: contain; border: 1px solid var(--line); border-radius: .8rem; background: var(--card);
  scrollbar-width: thin; scrollbar-color: #4a5c64 transparent; }
.mjm-aside::-webkit-scrollbar { width: 8px; }
.mjm-aside::-webkit-scrollbar-thumb { background: #4a5c64; border-radius: 8px; border: 2px solid var(--card); }
.mjm-aside::-webkit-scrollbar-track { background: transparent; }
.mjm-aside:focus-visible { outline: 2px solid var(--a); outline-offset: -2px; }
.mjm-filters { padding: 0 14px 14px; font-size: 13.5px; }
.mjm-filters-head { position: sticky; top: 0; z-index: 2; background: var(--card); display: flex; align-items: center; justify-content: space-between; gap: .5rem; padding: 12px 0 10px; border-bottom: 1px solid var(--line); }
.mjm-filters-head h2 { margin: 0; font-size: 15px; font-weight: 650; }
.mjm-filters-head .mjm-clear { margin-left: auto; }
.mjm-close { display: none; background: none; border: 0; color: var(--text); font-size: 1.8rem; cursor: pointer; }
.mjm-fgroup { border-bottom: 1px solid var(--line); padding: 6px 0; }
.mjm-fgroup:last-of-type { border-bottom: 0; }
.mjm-fgroup summary { cursor: pointer; font-weight: 600; font-size: 14px; list-style: none; display: flex; justify-content: space-between; align-items: center; min-height: 32px; }
.mjm-fgroup summary::-webkit-details-marker { display: none; }
.mjm-fgroup summary::after { content: "⌄"; color: var(--muted); }
.mjm-fgroup[open] summary::after { content: "⌃"; }
.mjm-fgroup > div { padding: 4px 0 6px; display: grid; gap: 6px; }
.mjm-checks { display: grid; gap: 0; }
.mjm-checks label { display: flex; align-items: center; gap: .55rem; min-height: 30px; cursor: pointer; font-size: 13.5px; }
.mjm-checks input { width: 16px; height: 16px; min-height: 0; margin: 0; accent-color: var(--a); flex: none; }
.mjm-checks label.is-filtered-out { display: none; }
.mjm-more-opts summary { cursor: pointer; color: var(--a); font-size: 13px; list-style: none; min-height: 30px; display: flex; align-items: center; gap: .3rem; }
.mjm-more-opts summary::-webkit-details-marker { display: none; }
.mjm-more-opts summary::after { content: "⌄"; }
.mjm-more-opts[open] summary::after { content: "⌃"; }
.mjm-more-opts[open] summary { order: 2; }
.mjm-optsearch input { min-height: 34px; font-size: 13px; }
.mjm-checks span { flex: 1; }
.mjm-checks small { color: var(--muted); font-size: 12px; }
.mjm-pair { display: grid; grid-template-columns: 1fr auto 1fr; gap: .4rem; align-items: center; color: var(--muted); }
.mjm-seg { display: flex; flex-wrap: wrap; gap: .35rem; }
.mjm-seg label { flex: 1 1 auto; }
.mjm-seg input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.mjm-seg span { display: block; text-align: center; padding: 7px 6px; border: 1px solid var(--line); border-radius: .45rem; cursor: pointer; font-size: 13px; }
.mjm-seg input:checked + span { background: var(--a); color: #10180a; border-color: var(--a); font-weight: 600; }
.mjm-seg input:focus-visible + span { outline: 3px solid var(--a); outline-offset: 2px; }
.mjm-inline { display: grid; gap: .3rem; color: var(--muted); font-size: 13px; }
.mjm-empty-opt { color: var(--muted); font-size: .88rem; margin: 0; }
.mjm-filters-foot { padding-top: .8rem; }
.mjm-apply { width: 100%; min-height: 46px; border-radius: .7rem; border: 0; background: var(--a); color: #10180a; font-weight: 700; font-size: 15px; cursor: pointer; }
.js .mjm-aside .mjm-filters-foot { display: none; }

/* ---------- Tarjetas ---------- */
/* Columnas según el ancho real disponible: ~5 a 1900 px, 4 / 3 / 2 al reducirse. */
.mjm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, max(215px, calc((100% - 52px) / 5))), 1fr)); gap: 13px; }
.mjm-card { position: relative; background: var(--card); border: 1px solid var(--line); border-radius: .7rem; overflow: hidden; transition: border-color .15s; }
.mjm-card:hover { border-color: var(--a); }
.mjm-card-link { display: flex; flex-direction: column; text-decoration: none; color: inherit; height: 100%; }
.mjm-card-media { position: relative; aspect-ratio: 1 / 1; background: #1c262c; overflow: hidden; }
.mjm-card-media img, .mjm-main-photo img, .mjm-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mjm-noimg { display: block; width: 100%; height: 100%; background: radial-gradient(circle at 30% 20%, #2b4439, #15252d 70%); }
.mjm-count { position: absolute; left: 8px; top: 8px; display: inline-flex; align-items: center; gap: 4px; background: #000000a8; color: #fff; font-size: 12px; font-weight: 600; padding: 2px 7px; border-radius: 6px; }
.mjm-count::before, .mjm-i-meter::before, .mjm-i-place::before { content: ""; width: 13px; height: 13px; background: currentColor; flex: none;
  -webkit-mask: var(--ico) center/contain no-repeat; mask: var(--ico) center/contain no-repeat; }
.mjm-count { --ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9 3 7.2 5H4a2 2 0 0 0-2 2v11a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2h-3.2L15 3zm3 5a5 5 0 1 1 0 10 5 5 0 0 1 0-10zm0 2a3 3 0 1 0 0 6 3 3 0 0 0 0-6z'/%3E%3C/svg%3E"); }
.mjm-i-meter { --ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M3.5 18a8.5 8.5 0 1 1 17 0'/%3E%3Cpath d='m12 17 4.5-5.5'/%3E%3C/svg%3E"); }
.mjm-i-place { --ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a7 7 0 0 0-7 7c0 5 7 13 7 13s7-8 7-13a7 7 0 0 0-7-7zm0 9.5A2.5 2.5 0 1 1 12 6a2.5 2.5 0 0 1 0 5.5z'/%3E%3C/svg%3E"); }
.mjm-sold { position: absolute; left: 0; right: 0; bottom: 0; background: #b3261ecc; color: #fff; text-align: center; font-weight: 800; padding: .3rem; }
.mjm-card.is-sold img { filter: grayscale(.7); }
.mjm-card-body { padding: 9px 12px 11px; display: flex; flex-direction: column; gap: 2px; flex: 1; }
.mjm-card-price { margin: 0; color: var(--a); font-weight: 700; font-size: 20px; line-height: 1.2; letter-spacing: -.01em; }
.mjm-card-title { margin: 0; font-size: 14.5px; font-weight: 600; line-height: 1.3; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
.mjm-card-meta { margin: 4px 0 0; color: var(--muted); font-size: 12.5px; display: flex; align-items: center; gap: 8px; min-width: 0; }
.mjm-card-meta > span { display: inline-flex; align-items: center; gap: 4px; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mjm-card-meta > span + span { padding-left: 8px; border-left: 1px solid var(--line); }
.mjm-i-meter::before, .mjm-i-place::before { width: 14px; height: 14px; color: #c9d5d9; }
.mjm-card-meta > span.is-empty { color: #7f9096; }
.mjm-card-meta > .mjm-i-meter { flex: none; }
.mjm-verified { margin: 4px 0 0; font-size: 12.5px; font-weight: 500; display: flex; gap: .35rem; align-items: center; }
.mjm-verified::before, .mjm-badge::before { content: "✓"; display: inline-grid; place-items: center; width: 1.1em; height: 1.1em; border-radius: 50%; background: var(--a); color: #10180a; font-size: .8em; font-weight: 900; }
.mjm-fav { position: absolute; right: 8px; top: 8px; width: 36px; height: 36px; border-radius: 50%; border: 0; background: #000000a6; cursor: pointer; display: grid; place-items: center; }
.mjm-fav::before { content: "♡"; color: #fff; font-size: 19px; line-height: 1; }
.mjm-fav[aria-pressed="true"]::before { content: "♥"; color: var(--a); }
.mjm-grid.is-list { grid-template-columns: repeat(auto-fill, minmax(min(100%, 520px), 1fr)); }
.mjm-grid.is-list .mjm-card-link { display: grid; grid-template-columns: 170px 1fr; }
.mjm-grid.is-list .mjm-card-body { align-content: center; padding: 1rem 3.5rem 1rem 1.2rem; }
.mjm-grid.is-list .mjm-fav { top: .8rem; right: .8rem; }

.mjm-empty { text-align: center; padding: 3rem 1rem; border: 1px dashed var(--line); border-radius: 1rem; }
.mjm-empty h2 { margin-top: 0; }
.mjm-empty p { color: var(--muted); }
.mjm-pages { display: flex; flex-wrap: wrap; gap: .4rem; justify-content: center; margin: 2rem 0 0; }
.mjm-pages a, .mjm-pages span { min-width: 42px; min-height: 42px; display: grid; place-items: center; padding: 0 .7rem; border: 1px solid var(--line); border-radius: .5rem; text-decoration: none; }
.mjm-pages [aria-current] { background: var(--a); color: #10180a; border-color: var(--a); font-weight: 800; }

/* ---------- Ficha (opción A) ---------- */
.wp-site-blocks .mjm-detail.alignfull { max-width: 1440px; }
.mjm-crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: .3rem; padding: 0; margin: 1rem 0 .4rem; color: var(--muted); font-size: .9rem; }
.mjm-crumbs li:not(:last-child)::after { content: "›"; margin-left: .3rem; }
.mjm-crumbs a { text-decoration: none; }
.mjm-crumbs a:hover { color: var(--a); }
.mjm-back { display: none; color: var(--a) !important; font-weight: 600; text-decoration: none; }
.mjm-detail h1 { margin: .2rem 0 1rem; font-size: clamp(1.45rem, 2.6vw, 2.2rem); line-height: 1.15; }
.mjm-detail-top { display: grid; grid-template-columns: auto minmax(320px, 440px); gap: 1.5rem; align-items: start; justify-content: space-between; }
.mjm-gallery { display: grid; grid-template-columns: 110px auto; gap: .8rem; align-items: start; }
.mjm-thumbs { display: grid; gap: .6rem; max-height: min(780px, calc(100vh - 170px)); overflow: auto; padding: 2px; align-content: start; }
.mjm-thumb { padding: 0; border: 2px solid transparent; border-radius: .55rem; overflow: hidden; aspect-ratio: 1 / 1; background: #1c262c; cursor: pointer; }
.mjm-thumb[aria-current] { border-color: var(--a); }
.mjm-main-photo { position: relative; padding: 0; border: 0; border-radius: .85rem; overflow: hidden; aspect-ratio: 1 / 1; background: #1c262c; cursor: zoom-in; width: min(780px, calc(100vh - 170px), calc(100vw - 620px)); min-width: 320px; }
.mjm-main-photo.is-empty { display: grid; place-items: center; color: var(--muted); cursor: default; }
.mjm-photo-count { position: absolute; right: .7rem; bottom: .7rem; background: #000000b3; color: #fff; padding: .2rem .6rem; border-radius: .4rem; font-size: .85rem; }
.mjm-panel { display: grid; gap: 1rem; position: sticky; top: 12px; }
.mjm-box { background: var(--card); border: 1px solid var(--line); border-radius: .9rem; padding: 1.2rem; display: grid; gap: .7rem; }
.mjm-price { margin: 0; color: var(--a); font-size: clamp(1.8rem, 3vw, 2.4rem); font-weight: 850; line-height: 1.05; }
.mjm-price del { color: var(--muted); font-size: .5em; font-weight: 500; margin-right: .3rem; }
.mjm-subtitle { margin: 0; font-size: 1.25rem; font-weight: 750; }
.mjm-facts { margin: 0; color: var(--muted); }
.mjm-seller { display: flex; align-items: center; gap: .75rem; border-top: 1px solid var(--line); padding-top: .8rem; }
.mjm-seller > div { display: grid; gap: .2rem; }
.mjm-avatar { width: 44px; height: 44px; border-radius: 50%; background: #2a3840; display: grid; place-items: center; font-weight: 800; }
.mjm-badge { display: inline-flex; gap: .35rem; align-items: center; color: var(--a); font-size: .85rem; font-weight: 700; }
.mjm-seller small { color: var(--muted); }
.mjm-note { margin: 0; color: var(--muted); font-size: .88rem; font-style: italic; }
.mjm-wa { width: 100%; }
.mjm-wa::before { content: ""; width: 20px; height: 20px; background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a10 10 0 0 0-8.6 15.1L2 22l5-1.3A10 10 0 1 0 12 2zm5.3 14.2c-.2.6-1.3 1.2-1.8 1.2-.5.1-1 .1-3.3-.8-2.8-1.1-4.6-4-4.7-4.2-.1-.2-1.1-1.5-1.1-2.9s.7-2 1-2.3c.2-.3.5-.3.7-.3h.5c.2 0 .4 0 .6.5l.8 2c.1.2.1.3 0 .5l-.4.6-.4.4c-.1.2-.3.3-.1.6.2.3.8 1.3 1.7 2.1 1.2 1 2.1 1.3 2.4 1.5.3.1.5.1.6-.1l.9-1.1c.2-.3.4-.2.7-.1l1.9.9c.3.1.5.2.5.3.1.2.1.7-.1 1.2z'/%3E%3C/svg%3E") center/contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a10 10 0 0 0-8.6 15.1L2 22l5-1.3A10 10 0 1 0 12 2zm5.3 14.2c-.2.6-1.3 1.2-1.8 1.2-.5.1-1 .1-3.3-.8-2.8-1.1-4.6-4-4.7-4.2-.1-.2-1.1-1.5-1.1-2.9s.7-2 1-2.3c.2-.3.5-.3.7-.3h.5c.2 0 .4 0 .6.5l.8 2c.1.2.1.3 0 .5l-.4.6-.4.4c-.1.2-.3.3-.1.6.2.3.8 1.3 1.7 2.1 1.2 1 2.1 1.3 2.4 1.5.3.1.5.1.6-.1l.9-1.1c.2-.3.4-.2.7-.1l1.9.9c.3.1.5.2.5.3.1.2.1.7-.1 1.2z'/%3E%3C/svg%3E") center/contain no-repeat; }
.mjm-actions { display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; }
.mjm-actions button { min-height: 44px; border-radius: .7rem; border: 1px solid var(--line); background: transparent; color: var(--text); font-weight: 650; cursor: pointer; }
.mjm-fav-wide { position: static; width: auto; height: auto; display: flex; gap: .4rem; justify-content: center; align-items: center; }
.mjm-fav-wide::before { font-size: 1.1rem; }
.mjm-sold-note { margin: 0; background: #b3261e; color: #fff; padding: .5rem .8rem; border-radius: .5rem; font-weight: 700; }
.mjm-check h2 { margin: 0; font-size: 1.1rem; }
.mjm-check a { color: var(--a) !important; font-weight: 650; }
.mjm-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 0; margin: 1.5rem 0; background: var(--card); border: 1px solid var(--line); border-radius: .9rem; }
.mjm-strip > div { padding: .9rem 1.1rem; border-right: 1px solid var(--line); }
.mjm-strip > div:last-child { border-right: 0; }
.mjm-strip dt { color: var(--muted); font-size: .85rem; }
.mjm-strip dd { margin: .15rem 0 0; font-weight: 750; }
.mjm-desc, .mjm-specs { background: var(--card); border: 1px solid var(--line); border-radius: .9rem; padding: 1.1rem 1.3rem; margin: 0 0 1.2rem; }
.mjm-desc h2, .mjm-specs h2, .mjm-related h2 { margin: 0 0 .6rem; font-size: 1.15rem; }
.mjm-desc-text { overflow-wrap: anywhere; }
.mjm-desc-text.is-clamped { max-height: 9.5em; overflow: hidden; -webkit-mask-image: linear-gradient(#000 60%, transparent); mask-image: linear-gradient(#000 60%, transparent); }
.mjm-more { background: none; border: 0; color: var(--a); font-weight: 700; cursor: pointer; padding: .3rem 0; }
.mjm-specs dl { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: .2rem 1.5rem; margin: 0 0 .6rem; }
.mjm-specs dl > div { display: flex; justify-content: space-between; gap: 1rem; border-bottom: 1px solid var(--line); padding: .45rem 0; }
.mjm-specs dt { color: var(--muted); }
.mjm-specs dd { margin: 0; font-weight: 650; text-align: right; }
.mjm-related { margin-top: 2rem; }
.mjm-related .mjm-grid { grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); }

/* Visor ampliado */
.mjm-lightbox { border: 0; padding: 0; background: #000000f0; color: #fff; width: 100vw; height: 100vh; max-width: none; max-height: none; }
.mjm-lightbox::backdrop { background: #000000e6; }
.mjm-lightbox[open] { display: grid; place-items: center; }
.mjm-lightbox img { max-width: min(92vw, 92vh); max-height: 92vh; aspect-ratio: 1 / 1; object-fit: cover; border-radius: .5rem; }
.mjm-lightbox button { position: absolute; background: #ffffff1f; color: #fff; border: 0; border-radius: 50%; width: 52px; height: 52px; font-size: 2rem; cursor: pointer; }
.mjm-lb-close { top: 1rem; right: 1rem; }
.mjm-lb-prev { left: 1rem; top: 50%; transform: translateY(-50%); }
.mjm-lb-next { right: 1rem; top: 50%; transform: translateY(-50%); }
.mjm-lb-count { position: absolute; bottom: 1rem; left: 0; right: 0; text-align: center; margin: 0; }
.mjm-sticky { display: none; }

/* ---------- Portátil y tableta ---------- */
@media (max-width: 1180px) {
  .mjm-layout { grid-template-columns: 240px minmax(0, 1fr); }
  .mjm-detail-top { grid-template-columns: auto 340px; }
  .mjm-main-photo { width: min(700px, calc(100vh - 170px), calc(100vw - 520px)); }
}
@media (max-width: 900px) {
  .mjm-detail-top { grid-template-columns: 1fr; }
  .mjm-panel { position: static; }
  .mjm-gallery { grid-template-columns: 1fr; }
  .mjm-gallery .mjm-thumbs { order: 2; grid-auto-flow: column; grid-auto-columns: 72px; max-height: none; overflow-x: auto; }
  .mjm-main-photo { width: 100%; min-width: 0; }
}

/* ---------- Móvil: filtros en panel, 2 columnas ---------- */
@media (max-width: 800px) {
  .mjm-layout { grid-template-columns: 1fr; }
  .mjm-open-filters { display: inline-flex; align-items: center; flex: 1 1 0; justify-content: center; }
  .mjm-sort { flex: 1 1 0; min-width: 0; }
  .mjm-view { display: none; }
  .mjm-search { flex-basis: 100%; }
  .mjm-head { margin: .6rem 0 .5rem; justify-content: space-between; }
  .mjm-total { border: 0; padding: 0; }
  .mjm-aside { display: none; }
  .mjm-aside.is-open { display: block; position: fixed; inset: 0; z-index: 100000; max-height: none; border-radius: 0; border: 0; top: 0; overflow: auto; }
  .mjm-aside.is-open .mjm-filters { padding-bottom: 90px; }
  .mjm-close { display: block; }
  .js .mjm-aside .mjm-filters-foot { display: block; position: fixed; left: 0; right: 0; bottom: 0; padding: .8rem 1rem; background: var(--card); border-top: 1px solid var(--line); }
  .mjm { padding: 0 12px 32px; }
  .mjm-main .mjm-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .mjm-card-body { padding: 7px 8px 9px; }
  .mjm-card-price { font-size: 17px; }
  .mjm-card-title { font-size: 13.5px; }
  .mjm-card-meta, .mjm-verified { font-size: 11.5px; gap: 6px; }
  .mjm-card-meta > span + span { padding-left: 6px; }
  .mjm-fav { width: 34px; height: 34px; }
  .mjm-grid.is-list .mjm-card-link { grid-template-columns: 1fr; }
  .mjm-related .mjm-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .mjm-back { display: inline-block; margin-top: .6rem; }
  .mjm-crumbs { display: none; }
  .mjm-strip > div { border-right: 0; border-bottom: 1px solid var(--line); }
  .mjm-sticky { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 9999; gap: .8rem; align-items: center; justify-content: space-between;
    padding: .6rem 1rem; background: #0b1115f2; border-top: 1px solid var(--line); }
  .mjm-sticky strong { color: var(--a); font-size: 1.2rem; }
  .mjm-sticky .mjm-btn { width: auto; flex: 0 0 auto; }
  .mjm-detail { padding-bottom: 80px; }
}
@media (max-width: 340px) { .mjm-main .mjm-grid { grid-template-columns: 1fr; } }
body.mjm-noscroll { overflow: hidden; }

/* ===================== Ficha del clasificado (diseño 2026-11) =====================
   PC/tablet (>900 px): galería sticky a la izquierda (~46 %) y columna de lectura a la derecha.
   Móvil: flujo vertical, galería compacta sticky al leer y barra inferior con WhatsApp.
   --mjd-top la calcula marketplace.js: alto de lo fijo arriba (barra de WordPress) + barra compacta. */
.mjd { --d-accent:#d7ff00; --d-line:#2b3f45; --d-card:#0f1e23; --d-muted:#b9c7ca; --mjd-top:0px; --mjd-bar:0px;
    max-width:1180px; margin:0 auto; padding:0 clamp(16px,3vw,24px) 3rem; box-sizing:border-box; color:#f2f5f5; }
.wp-site-blocks .mjm.mjd.alignfull { max-width:1180px!important; width:100%; margin-inline:auto!important; }
.mjd .mjd-icon { width:1.3rem; height:1.3rem; flex:none; }
.mjd-crumbs ol { display:flex; flex-wrap:wrap; gap:.35rem; margin:.9rem 0 1rem; padding:0; list-style:none; font-size:.9rem; color:#dfe7e8; }
.mjd-crumbs li + li::before { content:"›"; margin-right:.35rem; color:#9fb0b3; }
.mjd-crumbs a { color:#dfe7e8; text-decoration:none; }
.mjd-crumbs a:hover { color:var(--d-accent); }

.mjd-layout { display:grid; grid-template-columns:minmax(0,46fr) minmax(0,54fr); gap:1.8rem; align-items:start; }
.mjd-media { position:relative; min-width:0; align-self:stretch; }
.mjd-content { display:grid; gap:1.1rem; min-width:0; }
.mjd-gallery { position:sticky; top:calc(var(--mjd-top) + var(--mjd-bar) + 14px); display:grid; gap:.65rem; margin-inline:auto;
    width:min(100%, max(280px, calc(100vh - var(--mjd-top) - var(--mjd-bar) - 130px))); transition:top .2s; }
.mjd-main { position:relative; display:block; width:100%; padding:0; border:0; border-radius:.9rem; overflow:hidden; background:#0a1417; cursor:zoom-in; aspect-ratio:1; }
.mjd-main img { width:100%; height:100%; object-fit:cover; display:block; }
.mjd-main:focus-visible, .mjd-thumb:focus-visible, .mjd-minibar button:focus-visible { outline:3px solid var(--d-accent); outline-offset:2px; }
.mjd-main.is-empty { display:grid; place-items:center; color:var(--d-muted); cursor:default; }
.mjd-zoom { position:absolute; top:.7rem; right:.7rem; display:grid; place-items:center; width:2.5rem; height:2.5rem; border-radius:50%; background:#0b1418cc; color:#fff; }
.mjd-count { position:absolute; left:.7rem; bottom:.7rem; display:inline-flex; align-items:center; gap:.35rem; padding:.28rem .6rem; border-radius:.55rem; background:#0b1418cc; color:#fff; font-weight:700; font-size:.88rem; }
.mjd-count .mjd-icon { width:1rem; height:1rem; }
.mjd-thumbs { display:flex; gap:.5rem; overflow-x:auto; padding:.15rem .1rem .3rem; scrollbar-width:thin; }
.mjd-thumb { flex:0 0 auto; width:4rem; aspect-ratio:1; padding:0; border:2px solid transparent; border-radius:.55rem; overflow:hidden; background:#0a1417; cursor:pointer; opacity:.8; }
.mjd-thumb img { width:100%; height:100%; object-fit:cover; display:block; }
.mjd-thumb[aria-current] { border-color:var(--d-accent); opacity:1; }
.mjd-thumb:hover { opacity:1; }

.mjd-panel { display:flex; flex-direction:column; gap:.8rem; padding:1.2rem 1.3rem; border:1px solid var(--d-line); border-radius:1rem; background:var(--d-card); min-width:0; }
.mjd-title { margin:0; font-size:clamp(1.55rem,2.2vw,2.05rem); font-weight:800; line-height:1.12; color:#fff; }
.mjd-price { margin:-.25rem 0 0; font-size:clamp(1.65rem,2.3vw,2.15rem); font-weight:800; color:var(--d-accent); line-height:1.1; }
.mjd-price del { font-size:.55em; color:#9fb0b3; font-weight:500; }
.mjd-subtitle { margin:-.45rem 0 0; color:#dfe7e8; font-size:1.02rem; }
.mjd-seller { border:1px solid var(--d-line); border-radius:.75rem; background:#0b181c; }
.mjd-seller summary { display:flex; align-items:center; gap:.75rem; padding:.6rem .85rem; cursor:pointer; list-style:none; }
.mjd-seller summary::-webkit-details-marker { display:none; }
.mjd-avatar { display:grid; place-items:center; width:2.2rem; height:2.2rem; border-radius:50%; background:#26393f; color:#fff; font-weight:800; flex:none; }
.mjd-seller-name { display:inline-flex; align-items:center; gap:.4rem; flex:1; font-weight:800; font-size:1.05rem; min-width:0; overflow-wrap:anywhere; }
.mjd-verified { color:var(--d-accent); display:inline-flex; }
.mjd-seller[open] summary > .mjd-icon { transform:rotate(90deg); }
.mjd-seller-more { padding:0 .85rem .75rem 3.8rem; color:var(--d-muted); font-size:.92rem; }
.mjd-seller-more p { margin:.2rem 0; }
.mjd-seller-more a { color:var(--d-accent); margin-right:.6rem; }
.mjd-facts { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:.6rem; margin:0; }
.mjd-fact { display:flex; align-items:center; gap:.7rem; padding:.55rem .8rem; border:1px solid var(--d-line); border-radius:.7rem; background:#0b181c; min-width:0; }
.mjd-fact .mjd-icon { width:1.5rem; height:1.5rem; color:#e9f0f0; }
.mjd-fact dt { font-size:.82rem; color:var(--d-muted); }
.mjd-fact dd { margin:0; font-weight:800; font-size:1rem; overflow-wrap:anywhere; }
.mjd-fact dd.is-empty { font-weight:600; color:#9fb0b3; }
.mjd .mjd-wa { display:flex; align-items:center; justify-content:center; gap:.55rem; min-height:48px; padding:.55rem 1rem; border-radius:.7rem; background:var(--d-accent); color:#111a00; font-weight:800; font-size:1.06rem; text-decoration:none; }
.mjd .mjd-wa:hover { filter:brightness(1.06); }
.mjd .mjd-wa .mjd-icon { width:1.4rem; height:1.4rem; }
.mjd-actions { display:grid; grid-template-columns:1fr 1fr; gap:.6rem; }
.mjd .mjd-ghost { display:inline-flex; align-items:center; justify-content:center; gap:.5rem; min-height:42px; padding:.45rem; border:1px solid #44595f; border-radius:.7rem; background:transparent; color:#fff; font-weight:700; font-size:.98rem; cursor:pointer; }
.mjd .mjd-ghost:hover { border-color:var(--d-accent); }
.mjd .mjd-fav[aria-pressed="true"] .mjd-icon { fill:var(--d-accent); color:var(--d-accent); }
.mjd-note { margin:0; color:var(--d-muted); font-size:.9rem; }
.mjd-sold { margin:0; padding:.5rem .8rem; border-radius:.6rem; background:#3a1d1d; color:#ffd0d0; font-weight:700; }

.mjd-card { display:grid; gap:.75rem; padding:clamp(1rem,2vw,1.25rem); border:1px solid var(--d-line); border-radius:1rem; background:var(--d-card); min-width:0; scroll-margin-top:calc(var(--mjd-top) + var(--mjd-bar) + 16px); }
.mjd-card > header { display:flex; align-items:center; gap:.65rem; flex-wrap:wrap; }
.mjd-card > header .mjd-icon { width:1.7rem; height:1.7rem; color:var(--d-accent); }
.mjd-card h2 { margin:0; font-size:1.25rem; font-weight:800; flex:1; }
.mjd-chip { display:inline-flex; align-items:center; gap:.3rem; padding:.3rem .7rem; border:1px solid #44595f; border-radius:999px; color:var(--d-accent); font-size:.85rem; font-weight:700; text-decoration:none; }
.mjd-chip .mjd-icon { width:.95rem; height:.95rem; }
.mjd-check-body { display:flex; align-items:flex-end; justify-content:space-between; gap:.8rem; flex-wrap:wrap; }
.mjd-check-body > p { margin:0; color:#dfe7e8; font-size:1rem; }
.mjd-how summary { display:inline-flex; align-items:center; gap:.3rem; padding:.4rem .85rem; border:1px solid #44595f; border-radius:.6rem; font-weight:700; font-size:.88rem; cursor:pointer; list-style:none; }
.mjd-how summary::-webkit-details-marker { display:none; }
.mjd-how summary .mjd-icon { width:1rem; height:1rem; }
.mjd-how p { margin:.6rem 0 0; color:var(--d-muted); font-size:.9rem; }
.mjd-history { display:grid; gap:.4rem; margin:0; padding:0; list-style:none; scroll-margin-top:calc(var(--mjd-top) + var(--mjd-bar) + 16px); }
.mjd-history li { display:flex; justify-content:space-between; gap:1rem; padding:.45rem .6rem; border-radius:.5rem; background:#0b181c; font-size:.92rem; }
.mjd-history span { color:var(--d-muted); }
.mjd-desc-text { color:#e6ecec; }
.mjd-desc-text p { margin:0 0 .55rem; }
.mjd-spec-table { display:grid; margin:0; }
.mjd-spec-table > div { display:grid; grid-template-columns:minmax(0,40%) minmax(0,1fr); gap:1rem; padding:.5rem .2rem; border-bottom:1px solid var(--d-line); }
.mjd-spec-table > div:last-child { border-bottom:0; }
.mjd-spec-table dt { color:var(--d-muted); }
.mjd-spec-table dd { margin:0; font-weight:700; }
.mjd-end { height:1px; }
.mjd + .mjm-related, .mjd .mjm-related { margin-top:2.2rem; }

/* Barra compacta de PC al leer: título · precio · WhatsApp (debajo de lo fijo de arriba, sin tapar el menú). */
.mjd-topbar { position:fixed; left:0; right:0; top:var(--mjd-top); z-index:60; background:#0b1418f5; border-bottom:1px solid var(--d-line); backdrop-filter:blur(6px); transform:translateY(-110%); transition:transform .2s; }
.mjd-topbar.is-on { transform:none; }
.mjd-topbar[hidden] { display:none; }
.mjd-topbar-in { max-width:1180px; margin:0 auto; padding:.45rem clamp(16px,3vw,24px); display:flex; align-items:center; gap:1rem; box-sizing:border-box; }
.mjd-topbar-title { flex:1; min-width:0; font-size:1.05rem; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.mjd-topbar-price { color:var(--d-accent); font-weight:800; font-size:1.2rem; white-space:nowrap; }
.mjd .mjd-topbar .mjd-wa { min-height:40px; padding:.35rem 1rem; font-size:.95rem; }

/* Galería compacta de móvil (oculta en PC). */
.mjd-minibar { display:none; }
.mjd-sticky { display:none; }

@media (max-width:900px) {
    .mjd { padding-bottom:calc(5.5rem + env(safe-area-inset-bottom)); }
    .mjd-layout { display:flex; flex-direction:column; gap:1rem; }
    .mjd-media { align-self:auto; }
    .mjd-gallery { position:static; width:100%; max-width:560px; }
    .mjd-panel { padding:0; border:0; background:none; gap:.75rem; }
    .mjd-panel > .mjd-wa, .mjd-panel > .mjd-note { display:none; }
    .mjd-topbar { display:none!important; }
    .mjd-thumb { width:3.6rem; }
    .mjd-minibar { position:fixed; left:0; right:0; top:var(--mjd-top); z-index:60; display:flex; align-items:center; gap:.65rem; height:84px; box-sizing:border-box;
        padding:.5rem max(12px, env(safe-area-inset-left)); background:#0b1418f7; border-bottom:1px solid var(--d-line); backdrop-filter:blur(6px);
        transform:translateY(-110%); transition:transform .2s; }
    .mjd-minibar.is-on { transform:none; }
    .mjd-minibar[hidden] { display:none; }
    .mjd-mini-thumb { flex:none; width:68px; height:68px; padding:0; border:2px solid var(--d-accent); border-radius:.55rem; overflow:hidden; background:#0a1417; cursor:zoom-in; }
    .mjd-mini-thumb img { width:100%; height:100%; object-fit:cover; display:block; }
    .mjd-mini-text { flex:1; min-width:0; display:grid; gap:.15rem; }
    .mjd-mini-text strong { font-size:.98rem; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
    .mjd-mini-text > span { display:inline-flex; align-items:center; gap:.3rem; color:#dfe7e8; font-size:.85rem; font-weight:700; }
    .mjd-mini-text .mjd-icon { width:.95rem; height:.95rem; }
    .mjd-mini-nav { display:flex; gap:.35rem; flex:none; }
    .mjd .mjd-mini-nav button { display:grid; place-items:center; width:38px; height:38px; padding:0; border:1px solid #556b71; border-radius:50%; background:transparent; color:#fff; font-size:1.3rem; line-height:1; cursor:pointer; }
    .mjd .mjd-mini-nav button .mjd-icon { width:1.05rem; height:1.05rem; }
    .mjd-sticky { position:fixed; left:0; right:0; bottom:0; z-index:50; display:flex; align-items:center; justify-content:space-between; gap:.8rem;
        padding:.6rem max(14px, env(safe-area-inset-right)) calc(.6rem + env(safe-area-inset-bottom)) max(14px, env(safe-area-inset-left)); background:#0b1418f5; border-top:1px solid var(--d-line); backdrop-filter:blur(6px); }
    .mjd-sticky strong { color:var(--d-accent); font-size:1.3rem; font-weight:800; white-space:nowrap; }
    .mjd-sticky .mjd-wa { min-height:46px; padding:.45rem 1rem; font-size:.98rem; }
}
@media (max-width:380px) {
    .mjd-sticky strong { font-size:1.12rem; }
    .mjd-sticky .mjd-wa { font-size:.9rem; padding:.45rem .75rem; }
    .mjd .mjd-mini-nav button { width:34px; height:34px; }
}
.mjd-safety ul { margin:0; padding-left:1.2rem; display:grid; gap:.3rem; color:#e6ecec; }
.mjd-safety a { color:var(--d-accent); }
.mjd-report summary { display:inline-block; color:#c9d6d8; font-size:.9rem; text-decoration:underline; cursor:pointer; }
.mjd-report form { display:grid; gap:.6rem; margin-top:.7rem; max-width:420px; }
.mjd-report label { display:grid; gap:.3rem; font-size:.9rem; color:#dfe7e8; }
.mjd-report select, .mjd-report textarea { width:100%; box-sizing:border-box; padding:.5rem .6rem; border:1px solid #44595f; border-radius:.5rem; background:#0b181c; color:#f2f5f5; font:inherit; }
.mjd-report button { justify-self:start; padding:.45rem 1rem; }
.mjd-hp { position:absolute!important; left:-9999px!important; width:1px; height:1px; overflow:hidden; }
.mjd-reported { margin:0; padding:.5rem .75rem; border-radius:.6rem; background:#16301f; color:#e1f7b0; }
