/* Eigenständige Ergänzungen für "Im Ort". Das gemeinsame Karten-/Galerie-Layout kommt aus damals-heute.css. */
.im-ort-page .im-ort-hero { background: linear-gradient(135deg, #eef7f7 0%, #fff 74%); }
.im-ort-page .damals-eyebrow,
.im-ort-page .damals-section-kicker { color: #1689bd; }
.im-ort-page .im-ort-search { max-width: 900px; }
.im-ort-page .im-ort-search select { max-width: 220px; min-width: 160px; padding: 10px 30px 10px 10px; border: 0; border-left: 1px solid #e5ebef; outline: 0; color: #4f6471; background: #fff; }
.im-ort-page .im-ort-selected-card { min-height: 550px; }
.im-ort-page .im-ort-info-list { display: grid; gap: 11px; margin-top: 20px; padding-top: 18px; border-top: 1px solid #e8eef1; }
.im-ort-page .im-ort-info-row { display: grid; grid-template-columns: 22px minmax(0,1fr); gap: 10px; align-items: start; color: #6b7b84; }
.im-ort-page .im-ort-info-row > i { margin-top: 3px; color: #1689bd; font-size: 1rem; }
.im-ort-page .im-ort-info-row-content { display: grid; gap: 2px; min-width: 0; }
.im-ort-page .im-ort-info-label { color: #87949b; font-size: .73rem; }
.im-ort-page .im-ort-info-row strong { color: #344b58; font-size: .86rem; font-weight: 620; line-height: 1.5; overflow-wrap: anywhere; }
.im-ort-page .im-ort-info-features { margin-top: 20px; }
.im-ort-page .im-ort-info-features h4 { margin: 0 0 10px; color: #172b3a; font-size: .92rem; font-weight: 740; }
.im-ort-page .im-ort-feature-list { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 13px; }
.im-ort-page .im-ort-feature-list span { display: inline-flex; align-items: center; padding: 6px 9px; border: 1px solid #e2ebef; border-radius: 30px; color: #4c6471; background: #f7fafb; font-size: .74rem; line-height: 1.35; }
.im-ort-page .im-ort-category-pill { display: inline-flex; align-items: center; gap: 6px; width: fit-content; margin-bottom: 11px; padding: 6px 10px; border-radius: 30px; color: #126e98; background: #eaf5fa; font-size: .75rem; font-weight: 720; }
.im-ort-page .im-ort-card .damals-card-meta { align-items: flex-start; }
.im-ort-page .im-ort-card .damals-card-meta span { max-width: 100%; }
.im-ort-page .im-ort-card-links { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.im-ort-page .im-ort-image-count { margin: 12px 0 0; color: #77868f; font-size: .78rem; }
.im-ort-page .im-ort-image-count i { color: #1689bd; margin-right: 5px; }
.im-ort-page .im-ort-gallery-thumbs { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-top: 1px solid #e8eef1; background: #fff; }
.im-ort-page .im-ort-gallery-thumb { width: 62px; height: 48px; flex: 0 0 auto; padding: 0; overflow: hidden; border: 1px solid #e0e8ed; border-radius: 7px; background: #f1f5f7; cursor: zoom-in; }
.im-ort-page .im-ort-gallery-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.im-ort-page .im-ort-gallery-more { display: inline-flex; min-width: 42px; height: 38px; align-items: center; justify-content: center; border-radius: 7px; color: #526874; background: #eef3f5; font-size: .8rem; font-weight: 700; }
.im-ort-page .im-ort-lightbox-inner { position: relative; }
.im-ort-page .im-ort-lightbox-nav { position: absolute; top: 50%; z-index: 3; display: flex; width: 42px; height: 42px; align-items: center; justify-content: center; transform: translateY(-50%); border: 0; border-radius: 50%; color: #fff; background: rgba(7,19,28,.78); font-size: 1.1rem; }
.im-ort-page .im-ort-lightbox-nav:hover { background: #1689bd; }
.im-ort-page .im-ort-lightbox-nav.is-prev { left: 22px; }
.im-ort-page .im-ort-lightbox-nav.is-next { right: 22px; }
.im-ort-page .im-ort-lightbox-nav.is-hidden { display: none; }
.im-ort-page .im-ort-lightbox-count { color: #7d8b94; font-size: .78rem; }
@media (max-width: 991px) {
  .im-ort-page .im-ort-selected-card { min-height: 0; }
}
@media (max-width: 767px) {
  .im-ort-page .im-ort-search { flex-wrap: wrap; }
  .im-ort-page .im-ort-search select { flex: 1 1 100%; max-width: none; border: 0; border-top: 1px solid #e5ebef; padding-left: 0; }
}
@media (max-width: 575px) {
  .im-ort-page .im-ort-gallery-thumb { width: 54px; height: 43px; }
  .im-ort-page .im-ort-lightbox-nav { width: 36px; height: 36px; }
  .im-ort-page .im-ort-lightbox-nav.is-prev { left: 12px; }
  .im-ort-page .im-ort-lightbox-nav.is-next { right: 12px; }
}


/* Kategorienmarker und Kartenlegende: Symbol und Farbe kommen aus der Kategorienverwaltung. */
.im-ort-page .im-ort-leaflet-icon-wrap { background: transparent; border: 0; }
.im-ort-page .im-ort-map-marker,
.im-ort-page .im-ort-map-legend-symbol { display: inline-flex; align-items: center; justify-content: center; border: 3px solid #fff; border-radius: 50%; color: #fff; background: var(--marker-color, #64748b); box-shadow: 0 3px 10px rgba(17,37,51,.30); }
.im-ort-page .im-ort-map-marker { width: 42px; height: 42px; font-size: 17px; transition: transform .16s ease, box-shadow .16s ease; }
.im-ort-page .im-ort-map-marker i, .im-ort-page .im-ort-map-legend-symbol i { color: #fff; line-height: 1; }
.im-ort-page .leaflet-marker-icon:hover .im-ort-map-marker { transform: translateY(-2px) scale(1.08); box-shadow: 0 5px 14px rgba(17,37,51,.38); }
.im-ort-page .im-ort-map-legend { display: flex; align-items: center; flex-wrap: wrap; gap: 9px 15px; padding: 12px 15px; border-top: 1px solid #e7edf0; background: #fff; }
.im-ort-page .im-ort-map-legend-title { color: #7b8a93; font-size: .72rem; font-weight: 750; letter-spacing: .04em; text-transform: uppercase; }
.im-ort-page .im-ort-map-legend-item { display: inline-flex; align-items: center; gap: 6px; color: #526570; font-size: .76rem; line-height: 1.3; }
.im-ort-page .im-ort-map-legend-symbol { width: 25px; height: 25px; border-width: 2px; font-size: 11px; flex: 0 0 auto; }
@media (max-width: 575px) { .im-ort-page .im-ort-map-marker { width: 38px; height: 38px; font-size: 15px; } .im-ort-page .im-ort-map-legend { gap: 8px 11px; padding: 10px; } .im-ort-page .im-ort-map-legend-item { font-size: .7rem; } }


/* Vollständige Angaben aus der Ortsverwaltung: Kurztext, Beschreibung und Zusatzfelder. */
.im-ort-page .im-ort-full-description {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid #e8eef1;
}
.im-ort-page .im-ort-full-description h4,
.im-ort-page .im-ort-gallery-features h4 {
  margin: 0 0 10px;
  color: #172b3a;
  font-size: .96rem;
  font-weight: 740;
}
.im-ort-page .im-ort-rich-description {
  color: #4d606b;
  font-size: .9rem;
  line-height: 1.72;
  overflow-wrap: anywhere;
}
.im-ort-page .im-ort-rich-description > :first-child { margin-top: 0; }
.im-ort-page .im-ort-rich-description > :last-child { margin-bottom: 0; }
.im-ort-page .im-ort-rich-description p { margin: 0 0 12px; }
.im-ort-page .im-ort-rich-description h2,
.im-ort-page .im-ort-rich-description h3,
.im-ort-page .im-ort-rich-description h4,
.im-ort-page .im-ort-rich-description h5 {
  margin: 17px 0 8px;
  color: #263f4d;
  font-size: 1rem;
  font-weight: 740;
}
.im-ort-page .im-ort-rich-description ul,
.im-ort-page .im-ort-rich-description ol { margin: 0 0 13px; padding-left: 1.35rem; }
.im-ort-page .im-ort-rich-description li { margin: 0 0 5px; }
.im-ort-page .im-ort-rich-description blockquote {
  margin: 14px 0;
  padding: 11px 15px;
  border-left: 3px solid #1689bd;
  border-radius: 0 7px 7px 0;
  background: #f2f7f9;
  color: #526874;
}
.im-ort-page .im-ort-rich-description a { color: #1689bd; text-decoration: underline; text-underline-offset: 2px; }
.im-ort-page .im-ort-rich-description table { width: 100%; margin: 12px 0; border-collapse: collapse; font-size: .84rem; }
.im-ort-page .im-ort-rich-description th,
.im-ort-page .im-ort-rich-description td { padding: 7px 9px; border: 1px solid #dce6eb; text-align: left; vertical-align: top; }
.im-ort-page .im-ort-rich-description th { background: #f3f7f9; color: #314c5a; }
.im-ort-page .im-ort-description-details {
  margin: 13px 0 4px;
  border: 1px solid #e5edf1;
  border-radius: 8px;
  background: #fbfcfd;
}
.im-ort-page .im-ort-description-details summary {
  padding: 10px 13px;
  color: #1689bd;
  font-size: .82rem;
  font-weight: 700;
  cursor: pointer;
}
.im-ort-page .im-ort-description-details[open] summary { border-bottom: 1px solid #e5edf1; }
.im-ort-page .im-ort-description-details .im-ort-rich-description { padding: 13px; }
.im-ort-page .im-ort-compact-details {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 15px;
  margin-top: 13px;
  color: #687b85;
  font-size: .78rem;
}
.im-ort-page .im-ort-compact-details span { display: inline-flex; align-items: flex-start; gap: 6px; }
.im-ort-page .im-ort-compact-details i { margin-top: 2px; color: #1689bd; }
.im-ort-page .im-ort-gallery-features { margin-top: 14px; }
.im-ort-page .im-ort-gallery-features .im-ort-feature-list { margin-top: 0; }

/* Interaktive Kategorienfilter für Karte und Galerie. */
.im-ort-page .im-ort-map-legend-item,
.im-ort-page .im-ort-map-legend-all {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 34px;
  padding: 4px 9px;
  border: 1px solid #dce7ec;
  border-radius: 8px;
  color: #405965;
  background: #fff;
  font: inherit;
  font-size: .76rem;
  line-height: 1.25;
  cursor: pointer;
  transition: opacity .15s ease, border-color .15s ease, background .15s ease;
}
.im-ort-page .im-ort-map-legend-item:hover,
.im-ort-page .im-ort-map-legend-all:hover { border-color: #1689bd; background: #f2f9fc; }
.im-ort-page .im-ort-map-legend-item:focus-visible,
.im-ort-page .im-ort-map-legend-all:focus-visible { outline: 3px solid rgba(22,137,189,.25); outline-offset: 2px; }
.im-ort-page .im-ort-map-legend-item.is-inactive { opacity: .45; background: #f3f6f7; text-decoration: line-through; }
.im-ort-page .im-ort-map-legend-item[aria-pressed="true"] { border-color: #cfe2ea; }
.im-ort-page .im-ort-map-legend-count { color: #81919a; font-size: .68rem; font-weight: 700; }
.im-ort-page .im-ort-map-legend-all { color: #087e9a; font-weight: 700; }
.im-ort-page .im-ort-map-filter-count { margin-left: auto; color: #7b8a93; font-size: .72rem; white-space: nowrap; }
.im-ort-page .im-ort-card[hidden] { display: none !important; }
@media (max-width: 575px) {
  .im-ort-page .im-ort-map-filter-count { flex: 1 1 100%; margin-left: 0; }
}


/* Update 09: Kategorienfilter optisch an das bestehende Karten- und Seitendesign anpassen.
   Die Regeln sind bewusst spezifischer, damit globale Button-Styles sie nicht überschreiben. */
.im-ort-page button.im-ort-map-legend-item,
.im-ort-page button.im-ort-map-legend-all {
  appearance: none !important;
  -webkit-appearance: none !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 8px !important;
  min-height: 38px !important;
  padding: 6px 12px !important;
  border: 1px solid #e1eaf0 !important;
  border-radius: 999px !important;
  color: #526875 !important;
  background: #f7fafb !important;
  box-shadow: none !important;
  font-family: inherit !important;
  font-size: .78rem !important;
  font-weight: 600 !important;
  line-height: 1.2 !important;
  text-decoration: none !important;
  text-transform: none !important;
  cursor: pointer !important;
  transition: background-color .18s ease, border-color .18s ease, color .18s ease, opacity .18s ease !important;
}
.im-ort-page button.im-ort-map-legend-item:hover,
.im-ort-page button.im-ort-map-legend-all:hover {
  border-color: #b9dce9 !important;
  color: #087e9a !important;
  background: #eef8fb !important;
}
.im-ort-page button.im-ort-map-legend-item[aria-pressed="true"] {
  border-color: #d8e9ef !important;
  color: #405965 !important;
  background: #f2f8fa !important;
}
.im-ort-page button.im-ort-map-legend-item.is-inactive {
  border-style: dashed !important;
  border-color: #e3e8eb !important;
  color: #8a989f !important;
  background: #f5f7f8 !important;
  opacity: .72 !important;
  text-decoration: none !important;
}
.im-ort-page button.im-ort-map-legend-all {
  border-color: #cce7ed !important;
  color: #087e9a !important;
  background: #edf8fa !important;
  font-weight: 700 !important;
}
.im-ort-page button.im-ort-map-legend-item:focus-visible,
.im-ort-page button.im-ort-map-legend-all:focus-visible {
  outline: 3px solid rgba(22,137,189,.22) !important;
  outline-offset: 2px !important;
}
.im-ort-page .im-ort-map-legend-count {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-width: 19px !important;
  height: 19px !important;
  padding: 0 5px !important;
  border-radius: 999px !important;
  color: #71838d !important;
  background: #e8eff2 !important;
  font-size: .68rem !important;
  font-weight: 700 !important;
}
.im-ort-page .im-ort-map-filter-count {
  color: #71838d !important;
  font-size: .76rem !important;
}
