.fme {
  --fme-leftw: 180px;
  --fme-rightw: 360px;
  --fme-map-bg: #f3f5f7;
}

/* Hard override for replace behavior */
.fme.is-detail .fme-map-wrap { display: none !important; }
.fme.is-detail .fme-detail   { display: grid !important; }

/* Map */
.fme-map-wrap { margin-bottom: 14px; }
.fme-map { position: relative; width: 100%; overflow: hidden; background: var(--fme-map-bg); }
.fme-map img { display:block; width:100%; height:auto; max-height:inherit; object-fit:contain; }

/* Hotspots */
.fme-hotspot {
  position:absolute; transform: translate(-50%, -50%);
  border: none; background: transparent; cursor: pointer;
  display: inline-flex; align-items:center; justify-content:center;
  min-width:44px; min-height:44px; padding:0;
}
.fme-hotspot-dot {
  width:100%; height:100%;
  border: 2px solid transparent;
  background: #0b5cff;
  box-shadow: 0 6px 18px rgba(0,0,0,0.18);
  display:block;
}

/* Detail */
.fme-detail {
  display:none;
  grid-template-columns: var(--fme-leftw) minmax(0, 1fr) var(--fme-rightw);
  gap: 16px;
  align-items: stretch;
  overflow: hidden;
}
.fme-leftnav, .fme-center, .fme-right { min-height: 0; overflow: auto; }

/* Left nav */
.fme-leftnav { display:flex; flex-direction:column; gap:10px; }
.fme-leftnav-items { display:flex; flex-direction:column; gap:10px; }

.fme-back-btn {
  width:100%; min-height:44px;
  display:inline-flex; align-items:center; gap:10px;
  padding:10px 12px;
  border:2px solid rgba(0,0,0,0.10);
  background:#fff;
  cursor:pointer;
}
.fme-back-label { font-weight: 600; }

/* Left thumbs */
.fme-section-thumb {
  width:100%;
  border: 2px solid rgba(0,0,0,0.08);
  background: #fff;
  overflow:hidden;
  cursor:pointer;
  padding:10px;
  display:grid;
  gap:8px;
  justify-items:start;
}
.fme-section-thumb img { width:100%; height:72px; object-fit:cover; display:block; }
.fme-thumb-placeholder { width:100%; height:72px; background:#e8edf2; display:block; }
.fme-section-thumb.is-active { border-color:#00b894; }
.fme-section-title { font-size:13px; line-height:1.2; color: inherit; }

/* Center */
.fme-center { min-width:0; }
.fme-center-image { width:100%; overflow:hidden; background:#101820; }
.fme-center-image img { display:block; width:100%; height:100%; object-fit:cover; }

/* Gallery */
.fme-gallery-wrap { margin-top:12px; }
.fme-gallery-label { font-size:13px; margin-bottom:8px; }
.fme-gallery { display:flex; gap:10px; overflow-x:auto; padding-bottom:6px; -webkit-overflow-scrolling: touch; }

.fme-gallery-thumb {
  border: 2px solid rgba(0,0,0,0.10);
  background:#fff;
  padding:0;
  cursor:pointer;
  min-width:44px; min-height:44px;
  flex: 0 0 auto;
}
.fme-gallery-thumb img { width:72px; height:72px; object-fit:cover; display:block; }
.fme-gallery-thumb.is-active { border-color:#00b894; }

/* Right */
.fme-right { background:#fff; padding:16px; }
.fme-right-inner { min-height: 240px; }

/* Responsive */
@media (max-width:1024px) {
  .fme-detail { grid-template-columns: 1fr; }
  .fme-leftnav-items { flex-direction:row; overflow-x:auto; padding-bottom:6px; -webkit-overflow-scrolling:touch; }
  .fme-section-thumb { width:160px; flex:0 0 auto; }
  .fme-center-image img { max-height: 60vh; }
}