.jpp-site .jpp-map-panel {margin-block: 24px 42px; padding: clamp(18px, 3vw, 30px); background: #151518; border: 1px solid #333237; border-radius: 16px; color: #f2f0eb; scroll-margin-top: 100px;}
.jpp-site .jpp-map-panel [hidden] {display: none !important;}
.jpp-site .jpp-map-heading {display: flex; align-items: center; justify-content: space-between; gap: 24px;}
.jpp-site .jpp-map-heading h2 {margin: 6px 0 9px; font-size: clamp(23px, 2.5vw, 31px); line-height: 1.6;}
.jpp-site .jpp-map-heading p {color: #b8b5b0; margin: 0; max-width: 560px; line-height: 1.9;}
.jpp-site .jpp-map-actions {display: flex; flex-wrap: wrap; gap: 10px; flex-shrink: 0;}
.jpp-site .jpp-map-actions .jpp-button {font: inherit; min-height: 48px; padding: 11px 17px; cursor: pointer;}
.jpp-site .jpp-map-privacy {font-size: 12px; line-height: 1.95; color: #a7a3a0; margin: 17px 0 0; max-width: 900px;}
.jpp-site .jpp-map-toolbar {display: flex; align-items: center; gap: 18px; flex-wrap: wrap; padding-block-start: 25px; border-top: 1px solid #303034; margin-block-start: 24px;}
.jpp-site .jpp-map-toolbar > p {flex: 1; margin: 0; line-height: 1.8;}
.jpp-site .jpp-map-toolbar label {display: flex; align-items: center; gap: 9px; font-size: 13px;}
.jpp-site .jpp-map-toolbar select {font: inherit; color: #f3f1ec; background: #232326; border: 1px solid #504d46; min-height: 44px; padding: 8px 11px; border-radius: 7px;}
.jpp-site .jpp-map-close {font: inherit; min-height: 44px; padding: 8px 12px; color: #eee; border: 1px solid #504d46; border-radius: 7px; cursor: pointer; background: transparent;}
.jpp-site .jpp-map-hint {font-size: 12px; color: #bdb8ac; line-height: 1.9; margin: 12px 0 18px;}
.jpp-site .jpp-map-warning {background: #332a1c; color: #f9dca3; border: 1px solid #705936; padding: 12px 16px; border-radius: 8px; line-height: 1.85; font-size: 13px;}
.jpp-site .jpp-map-layout {display: grid; grid-template-columns: minmax(0, 1fr) minmax(240px, .49fr); gap: 18px; direction: ltr; align-items: start;}
.jpp-site .jpp-map-canvas {height: 460px; min-width: 0; border-radius: 10px; background: #282a2d; border: 1px solid #3d3e42; z-index: 0; direction: ltr; font-family: JPPVazir, Tahoma, sans-serif;}
.jpp-site .jpp-map-canvas:focus-visible {outline: 3px solid #f4c84a; outline-offset: 3px;}
.jpp-site .jpp-map-canvas[hidden] + .jpp-map-results {grid-column: 1 / -1; max-height: none;}
.jpp-site .jpp-map-results {direction: rtl; min-width: 0; max-height: 460px; overflow: auto; scrollbar-width: thin; scrollbar-color: #66615a #18181c;}
.jpp-site .jpp-map-results h3 {font-size: 14px; margin: 2px 0 12px; color: #c6c2b9;}
.jpp-site .jpp-map-results ul {list-style: none; margin: 0; padding: 0; display: grid; gap: 9px;}
.jpp-site .jpp-map-item {padding: 15px; border: 1px solid #39373c; border-radius: 9px; background: #1c1c20;}
.jpp-site .jpp-map-item > a {color: #fff3cc; font-weight: 700; font-size: 15px; text-decoration: none;}
.jpp-site .jpp-map-item > a:hover {text-decoration: underline;}
.jpp-site .jpp-map-item p {font-size: 12px; line-height: 1.8; color: #b5b0a8; margin: 8px 0; overflow-wrap: anywhere;}
.jpp-site .jpp-map-distance {display: block; font-size: 12px; color: #ebcc72; line-height: 1.8;}
.jpp-site .jpp-map-item-actions {display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; margin-top: 7px;}
.jpp-site .jpp-map-item-actions a, .jpp-site .jpp-map-item-actions button {font: inherit; font-size: 12px; color: #eecb64; background: transparent; border: 0; min-height: 44px; padding: 10px 0; display: inline-flex; align-items: center; cursor: pointer; text-decoration: none;}
.jpp-site .jpp-map-item-actions a:hover, .jpp-site .jpp-map-item-actions button:hover {text-decoration: underline;}
.jpp-site .jpp-map-item-actions span {font-size: 11px; color: #aaa49a;}
.jpp-site .jpp-map-results > p {line-height: 1.9; font-size: 13px; color: #c3bdb2;}
.jpp-site .jpp-map-more {display: flex; gap: 12px; flex-wrap: wrap; align-items: center; margin-top: 18px;}
.jpp-site .jpp-map-more > a {margin-inline-start: auto; color: #bdb7aa; font-size: 12px; padding: 12px 0;}
.jpp-site .jpp-map-more button {font: inherit; cursor: pointer;}
.jpp-site .jpp-map-panel button:disabled {opacity: .55; cursor: wait;}
.jpp-site .jpp-map-panel button:focus-visible, .jpp-site .jpp-map-panel a:focus-visible, .jpp-site .jpp-map-panel select:focus-visible {outline: 3px solid #f3ce60; outline-offset: 3px;}
.jpp-site .jpp-map-pin {display: grid; place-items: start center; padding-top: 3px; box-sizing: border-box; background: none; border: none;}
.jpp-site .jpp-map-pin::before {content: ''; position: absolute; width: 29px; height: 29px; top: 1px; left: 7px; border-radius: 50% 50% 2px 50%; transform: rotate(45deg); background: #f5c746; border: 2px solid #35280b; box-shadow: 0 2px 10px #0005;}
.jpp-site .jpp-map-pin > span {position: relative; z-index: 1; color: #1c170a; font-family: inherit; font-size: 14px; font-weight: 700; line-height: 29px;}
.jpp-site .jpp-map-canvas .leaflet-control-attribution {background: #fffd; color: #333; font-size: 11px; padding: 3px 6px; max-width: calc(100vw - 80px); white-space: normal;}
.jpp-site .jpp-map-canvas .leaflet-control-attribution a {color: #124c68;}
.jpp-site .jpp-map-canvas .leaflet-control-zoom a {width: 42px; height: 42px; line-height: 42px; color: #24231e;}
.jpp-site .jpp-map-canvas .leaflet-popup-close-button {width: 40px; height: 40px; line-height: 40px;}
.jpp-site .jpp-map-canvas .leaflet-popup-content {margin: 22px 24px 18px; max-height: 240px; overflow: auto;}
.jpp-site .jpp-map-popup {font-family: JPPVazir, Tahoma, sans-serif; min-width: 140px; max-width: 240px;}
.jpp-site .jpp-map-popup p {margin: 5px 0; line-height: 1.9; border-bottom: 1px solid #eee; padding: 5px 0;}
.jpp-site .jpp-map-popup a {color: #4b390b; font-weight: 700;}
@media (max-width: 1000px) {
  .jpp-site .jpp-map-heading {align-items: start; flex-direction: column; gap: 17px;}
  .jpp-site .jpp-map-layout {grid-template-columns: minmax(0, 1fr) minmax(220px, .65fr);}
}
@media (max-width: 680px) {
  .jpp-site .jpp-map-panel {padding: 16px; border-radius: 11px;}
  .jpp-site .jpp-map-heading h2 {font-size: 23px;}
  .jpp-site .jpp-map-actions {width: 100%;}
  .jpp-site .jpp-map-actions .jpp-button {width: 100%; justify-content: center;}
  .jpp-site .jpp-map-toolbar {gap: 10px;}
  .jpp-site .jpp-map-toolbar > p {flex-basis: 100%;}
  .jpp-site .jpp-map-close {margin-inline-start: auto;}
  .jpp-site .jpp-map-layout {grid-template-columns: 1fr;}
  .jpp-site .jpp-map-canvas {height: 360px;}
  .jpp-site .jpp-map-results {max-height: 370px;}
  .jpp-site .jpp-map-more > a {margin-inline-start: 0;}
}


/* Full canonical game cards below the map, with no nested scrolling. */
.jpp-site .jpp-map-layout{grid-template-columns:minmax(0,1fr);direction:rtl}
.jpp-site .jpp-map-results{max-height:none;overflow:visible}
.jpp-site .jpp-map-results ul{grid-template-columns:repeat(2,minmax(0,1fr));gap:20px}
.jpp-site .jpp-map-item{min-width:0;padding:0;overflow:hidden}
.jpp-site .jpp-map-item>.jpp-card-wrap{width:100%}
.jpp-site .jpp-map-item>.jpp-card-wrap>.jlp-game-card{margin:0;width:100%!important;max-width:none!important;height:100%}
.jpp-site .jpp-map-item>p,.jpp-site .jpp-map-item>.jpp-map-distance,.jpp-site .jpp-map-item>.jpp-map-item-actions{margin:10px 16px}
@media(max-width:680px){.jpp-site .jpp-map-results ul{grid-template-columns:minmax(0,1fr)}}

/* Each game keeps its own poster; co-located games expand without changing coordinates. */
.jpp-site .jpp-map-poster-pin{background:none;border:0;cursor:pointer;box-sizing:border-box}
.jpp-site .jpp-map-poster-pin:focus-visible{outline:3px solid #fff;outline-offset:5px;border-radius:8px}
.jpp-site .jpp-map-poster-single,.jpp-site .jpp-map-poster-fan{position:relative;width:100%;height:100%;filter:drop-shadow(0 3px 5px #0008)}
.jpp-site .jpp-map-poster-face{position:relative;display:block;overflow:hidden;background:#29252d;border-radius:6px;box-sizing:border-box}
.jpp-site .jpp-map-poster-face img{display:block;position:absolute;inset:0;width:100%;height:100%;object-fit:cover;max-width:none;margin:0}
.jpp-site .jpp-map-poster-fallback{display:flex;align-items:center;justify-content:center;height:100%;padding:5px;box-sizing:border-box;color:#f8e7b2;text-align:center;font:700 11px/1.6 JPPVazir,Tahoma,sans-serif;overflow-wrap:anywhere}
.jpp-site .jpp-map-poster-single>.jpp-map-poster-face{width:56px;height:72px;border:2px solid #f0c75b}
.jpp-site .jpp-map-poster-fan>.jpp-map-poster-face{position:absolute;width:48px;height:65px;left:28px;top:4px;border:2px solid #f0c75b;transform:translateX(calc((var(--poster-order) - (var(--poster-count) - 1)/2)*24px)) rotate(calc((var(--poster-order) - (var(--poster-count) - 1)/2)*14deg));transform-origin:50% 100%}
.jpp-site .jpp-map-poster-label{position:absolute;bottom:2px;left:2px;right:2px;display:block;box-sizing:border-box;min-height:20px;padding:2px 3px;background:#151318ed;color:#fff6d5;border-radius:0 0 4px 4px;text-align:center;direction:rtl;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font:700 10px/16px JPPVazir,Tahoma,sans-serif}
.jpp-site .jpp-map-poster-fan>.jpp-map-poster-label{left:18px;right:18px;bottom:7px;border:1px solid #f0c75b;border-radius:12px;font-size:11px}
.jpp-site .jpp-map-poster-pin:not(.is-expanded)>div::after{content:'';position:absolute;bottom:-7px;left:calc(50% - 6px);border-left:6px solid transparent;border-right:6px solid transparent;border-top:8px solid #f0c75b}
.jpp-site .jpp-map-canvas .leaflet-popup-content{max-height:320px}
.jpp-site .jpp-map-game-popup{width:210px;min-width:0}
.jpp-site .jpp-map-game-popup>a:first-child{display:block}
.jpp-site .jpp-map-game-popup .jpp-map-poster-face{height:132px;background:#1b191e;margin-bottom:8px}
.jpp-site .jpp-map-game-popup .jpp-map-poster-face img{object-fit:contain}
.jpp-site .jpp-map-popup-title{display:block;font-size:15px;line-height:1.7;text-decoration:none}
.jpp-site .jpp-map-game-popup p{font-size:11px;line-height:1.7;color:#555;border:0;margin:4px 0 8px;padding:0}
.jpp-site .jpp-map-popup a.jpp-map-popup-book{display:flex;align-items:center;justify-content:center;min-height:44px;border-radius:6px;background:#29232b;color:#fff1bf;text-decoration:none;font-size:13px}
.jpp-site .jpp-map-gallery{display:grid;gap:10px;width:210px}
.jpp-site .jpp-map-gallery>a{display:flex;align-items:center;gap:12px;text-decoration:none;min-height:64px}
.jpp-site .jpp-map-gallery .jpp-map-poster-face{width:48px;height:64px;flex-shrink:0}
