@import url("https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@500;600&family=Libre+Baskerville:wght@400;700&display=swap");

body {
  padding: 0;
  margin: 0;
}

@font-face {
  font-family: "Ringbearer";
  src: url("../assets/ringbearer.TTF") format("truetype");
}

html, body, #map {
  height: 100%;
  font: 10pt "Libre Baskerville", Georgia, serif;
}

body,
button,
input,
label,
table,
td,
th,
p {
  font-family: "Libre Baskerville", Georgia, serif;
}

h1,
h2,
h3,
.sidebar-header,
.polygon-label {
  font-family: "Cormorant Garamond", Georgia, serif;
  letter-spacing: 0.02em;
}

.sidebar-tabs a,
.atlas-map-nav__link {
  font-family: "Ringbearer", Georgia, serif;
}

.map-title,
.brand-mark,
.ringbearer-accent {
  font-family: "Ringbearer", "Cormorant Garamond", Georgia, serif;
}

.lorem {
  font-style: italic;
  color: #AAA;
}

#settlementsSection, #pathsSection, #geographySection, #battlesSection, #itemsSection, #campsSection, #regionsSection {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 16px;
}

#regionsSection h1,
#campsSection h1,
#itemsSection h1,
#settlementsSection h1,
#pathsSection h1,
#geographySection h1,
#battlesSection h1 {
  font-size: 18px;
  font-weight: 600;
  margin: 2px 0;
  padding-top: 2px;
  color: #444;
  text-align: left;
}

#settlementsSection label, #pathsSection label, #geographySection label, #battlesSection label, #itemsSection label #pathsSection label, #itemsSection label, #campsSection label, #regionsSection label {
  display: flex;
  align-items: center;
  cursor: pointer;
  font-size: 15px;
  line-height: 1.45;
}

#regionsSection input[type="checkbox"],
#itemsSection input[type="checkbox"],
#itemsSection input[type="checkbox"],
#battlesSection input[type="checkbox"],
#settlementsSection input[type="checkbox"],
#geographySection input[type="checkbox"] {
  margin-right: 8px;
}

.sidebar-tabs .material-icons {
  position: relative;
  top: 10px;
}

.sidebar-tabs .material-symbols-outlined {
  position: relative;
  top: 10px;
}

.polygon-label {
  border: 2px solid black;
  border-radius: 5px;
  padding: 2px 6px;
  font-size: 18px;
  color: black;
  font-weight: 600;
  text-align: center;
  pointer-events: none;
}

#campsSection, #pathsSection {
  padding-top: 0;
}

#campsSection h3,
#pathsSection h3 {
  margin-top: 0;
}

#campsSection label, #pathsSection label {
  margin-top: 0;
}

.campsite-popup {
  min-width: 260px;
  max-width: 320px;
  color: #38291a;
}

.campsite-popup-shell .leaflet-popup-content-wrapper {
  padding: 0;
  background: transparent;
  box-shadow: none;
}

.campsite-popup-shell .leaflet-popup-content {
  margin: 0;
}

.campsite-popup-shell .leaflet-popup-tip {
  background: #fefaf0;
  box-shadow: none;
}

.lore-popup-shell .leaflet-popup-content-wrapper {
  padding: 0;
  background: transparent;
  box-shadow: none;
}

.lore-popup-shell .leaflet-popup-content {
  margin: 0;
}

.lore-popup-shell .leaflet-popup-tip {
  background: #fefaf0;
  box-shadow: none;
}

.campsite-popup__frame {
  padding: 16px;
  border: 1px solid #8f7650;
  border-radius: 10px;
  background: #fefaf0;
  box-shadow: inset 0 0 0 1px rgba(255, 248, 224, 0.45);
}

.campsite-popup__title {
  margin: 0;
  font-size: 28px;
  line-height: 1;
  color: #2d2013;
}

.campsite-popup__subtitle {
  margin: 6px 0 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(111, 83, 40, 0.35);
  font-size: 15px;
  font-style: italic;
  color: #5e4727;
}

.campsite-popup__details {
  display: grid;
  gap: 8px;
}

.campsite-popup__row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 4px 0;
  border-bottom: 1px dashed rgba(111, 83, 40, 0.2);
}

.campsite-popup__label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #755a32;
}

.campsite-popup__value {
  font-size: 14px;
  text-align: right;
  color: #2c2218;
}

.campsite-popup__notes {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(111, 83, 40, 0.35);
}

.campsite-popup__notes-label {
  margin: 0 0 6px;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 18px;
  color: #41301c;
}

.campsite-popup__notes-text {
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
  color: #38291a;
}

.lore-popup {
  min-width: 260px;
  max-width: 440px;
  color: #38291a;
}

.lore-popup__frame {
  padding: 16px;
  border: 1px solid #8f7650;
  border-radius: 10px;
  background: #fefaf0;
  box-shadow: inset 0 0 0 1px rgba(255, 248, 224, 0.45);
}

.lore-popup__title {
  margin: 0;
  font-size: 28px;
  line-height: 1;
  color: #2d2013;
}

.lore-popup__sections {
  display: grid;
  gap: 8px;
  margin-top: 4px;
}

.lore-popup__section {
  padding-bottom: 6px;
  border-bottom: 1px dashed rgba(111, 83, 40, 0.2);
}

.lore-popup__section-title {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 22px;
  line-height: 1.05;
  color: #41301c;
}

.lore-popup__section-text {
  margin: 1px 0 0;
  font-size: 14px;
  line-height: 1.6;
  color: #38291a;
}

.lore-popup__notes {
  margin-top: 8px;
  padding-top: 6px;
  border-top: 1px solid rgba(111, 83, 40, 0.35);
}

.lore-popup__notes-text {
  margin: 1px 0 0;
  font-size: 14px;
  line-height: 1.6;
  color: #38291a;
}

.lore-popup__link {
  display: table;
  margin-top: 14px;
  margin-left: auto;
  margin-right: auto;
  padding: 8px 12px;
  border: 1px solid #8f7650;
  border-radius: 999px;
  background: rgba(126, 102, 59, 0.12);
  color: #4d371a;
  text-decoration: none;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 18px;
}

.lore-popup__link:hover,
.lore-popup__link:focus-visible {
  background: rgba(126, 102, 59, 0.2);
}

.atlas-map-nav {
  position: absolute;
  top: 18px;
  right: 18px;
  left: auto;
  transform: none;
  z-index: 900;
  display: flex;
  flex-direction: row;
  gap: 10px;
  align-items: flex-start;
  justify-content: center;
  flex-wrap: wrap;
  max-width: calc(100vw - 24px);
  pointer-events: auto;
}

.atlas-map-nav__menu {
  position: relative;
}

.atlas-map-nav__toggle {
  list-style: none;
  cursor: pointer;
}

.atlas-map-nav__toggle::-webkit-details-marker {
  display: none;
}

.atlas-map-nav__link {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: flex-start;
  padding: 10px 14px;
  border: 1px solid rgba(218, 184, 112, 0.55);
  border-radius: 999px;
  background: rgba(31, 22, 13, 0.88);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
  color: #f5e6c8;
  text-decoration: none;
  font-family: Arial, sans-serif;
  font-size: 14px;
  line-height: 1;
}

.atlas-map-nav__dropdown {
  display: grid;
  gap: 8px;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  left: auto;
  transform: none;
  width: max-content;
  min-width: max-content;
  max-width: calc(100vw - 24px);
  z-index: 901;
}

.atlas-map-nav__toggle {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  padding: 10px 14px;
  border: 1px solid rgba(218, 184, 112, 0.55);
  border-radius: 999px;
  background: rgba(31, 22, 13, 0.88);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
  color: #f5e6c8;
  font-family: Arial, sans-serif;
  font-size: 14px;
  line-height: 1;
}

.atlas-map-nav__toggle-label {
  display: flex;
  align-items: center;
  gap: 8px;
}

.atlas-map-nav__link > span,
.atlas-map-nav__toggle-label > span {
  font-family: inherit;
  flex: initial;
}

.atlas-map-nav__link .material-icons,
.atlas-map-nav__toggle .material-icons {
  font-size: 20px;
}

.atlas-map-nav__link--home {
  background: rgba(31, 22, 13, 0.88);
}

.atlas-map-nav__link--current {
  background: rgba(111, 72, 32, 0.92);
}

.atlas-map-nav__menu[open] .atlas-map-nav__chevron {
  transform: rotate(180deg);
}

.atlas-map-nav__link:hover,
.atlas-map-nav__link:focus-visible,
.atlas-map-nav__toggle:hover,
.atlas-map-nav__toggle:focus-visible {
  transform: none;
  background: rgba(47, 33, 18, 0.95);
}

@media (max-width: 720px) {
  .atlas-map-nav {
    top: 12px;
    right: 12px;
    left: auto;
    bottom: auto;
    transform: none;
    width: auto;
  }

  .atlas-map-nav__link,
  .atlas-map-nav__toggle {
    justify-content: flex-start;
    font-size: 18px;
  }
}
