/* ============================================================
   lore-locations.css — Atlas Ulvenoru: themed pages for places
   Cartography aesthetic — compass rose hero, marker pins,
   atlas info card, parchment-style sections
   ============================================================ */

/* ── Local palette tokens ──
   --t-accent-rgb is the comma-separated RGB triple driving every gold tint
   on the page. Per-location themes (see bottom of file) override it together
   with --gold / --gold-light to swap the page's mood without touching markup. */
.lore-content {
  --imp-legendary: #d3a44b;
  --imp-major:     #a78a4a;
  --imp-minor:     #6e5e3d;
  --imp-legendary-soft: rgba(211, 164, 75, 0.18);
  --imp-major-soft:     rgba(167, 138, 74, 0.16);
  --imp-minor-soft:     rgba(110,  94, 61, 0.16);
  --status-active: #6dbf7c;
  --status-ruined: #b85b3c;
  --status-lost:   #8a8aa8;

  /* Theming knobs — defaults match the original imperial gold look */
  --t-accent-rgb: 201, 162, 39;
  --t-hero-radius: 14px;
  --t-card-radius: 10px;
  --t-section-radius: 8px;
  --t-ambient: none;
  --t-hooks-rgb: 192, 57, 43;
  --t-hooks-stripe-rgb: 139, 26, 26;
  --t-hooks-title-rgb: 192, 57, 43;
}

/* ============================================================
   SIDEBAR EXTRAS
   ============================================================ */
.loc-nav__count {
  margin-left: auto;
  font-size: 0.72rem;
  color: var(--text-dim);
  background: rgba(var(--t-accent-rgb), 0.08);
  border: 1px solid rgba(var(--t-accent-rgb), 0.2);
  border-radius: 999px;
  padding: 0.05rem 0.45rem;
  line-height: 1.4;
}
.loc-nav__name {
  font-size: 0.85rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ============================================================
   LIST PAGE — Hero with compass rose
   ============================================================ */
.loc-hero {
  display: flex;
  align-items: center;
  gap: 2rem;
  flex-wrap: wrap;
  padding: 1.5rem 0 2rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid rgba(var(--t-accent-rgb), 0.2);
}
.loc-hero__text {
  flex: 1 1 320px;
  min-width: 0;
}
.loc-hero__title {
  font-family: 'Cinzel', serif;
  font-size: 2.1rem;
  margin: 0 0 0.5rem;
  color: var(--gold);
  letter-spacing: 0.04em;
  text-shadow: 0 0 20px rgba(var(--t-accent-rgb), 0.18);
}
.loc-hero__subtitle {
  font-family: 'Crimson Text', serif;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-muted);
  font-style: italic;
  margin: 0 0 1.2rem;
  max-width: 60ch;
}
.loc-hero__stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}
.loc-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 84px;
  padding: 0.55rem 0.85rem;
  background: rgba(var(--t-accent-rgb), 0.06);
  border: 1px solid rgba(var(--t-accent-rgb), 0.25);
  border-radius: 8px;
}
.loc-stat__value {
  font-family: 'Cinzel', serif;
  font-size: 1.35rem;
  color: var(--gold-light);
  line-height: 1.1;
}
.loc-stat__label {
  font-family: 'Crimson Text', serif;
  font-size: 0.72rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  margin-top: 0.15rem;
  text-align: center;
}

/* ── Compass rose ── */
.loc-compass {
  flex: 0 0 280px;
  width: 280px;
  height: 280px;
  margin: 0;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  filter: drop-shadow(0 4px 16px rgba(0, 0, 0, 0.55));
}
.loc-compass__svg {
  width: 100%;
  height: auto;
  animation: loc-compass-spin 360s linear infinite;
}
@keyframes loc-compass-spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
.loc-compass__svg:hover { animation-play-state: paused; }

.loc-compass__letter {
  font-family: 'Cinzel', serif;
  font-size: 14px;
  font-weight: 700;
  fill: var(--gold-light);
  letter-spacing: 0.05em;
}
.loc-compass__glyph {
  font-size: 14px;
  fill: var(--gold-light);
}
.loc-compass__caption {
  font-family: 'Crimson Text', serif;
  font-size: 0.78rem;
  font-style: italic;
  color: var(--text-dim);
  letter-spacing: 0.05em;
  text-align: center;
}

/* ============================================================
   CATEGORIES & GRID
   ============================================================ */
.loc-category {
  margin: 2rem 0 2.5rem;
  scroll-margin-top: 80px;
}
.loc-category__head {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  margin-bottom: 1.1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(var(--t-accent-rgb), 0.18);
}
.loc-category__seal {
  font-size: 1.1rem;
  color: var(--gold);
  text-shadow: 0 0 8px rgba(var(--t-accent-rgb), 0.3);
}
.loc-category__title {
  font-family: 'Cinzel', serif;
  font-size: 1.4rem;
  color: var(--gold);
  margin: 0;
  letter-spacing: 0.03em;
}
.loc-category__count {
  margin-left: auto;
  font-family: 'Crimson Text', serif;
  font-style: italic;
  font-size: 0.85rem;
  color: var(--text-dim);
}

.loc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 1.1rem;
}

/* ============================================================
   LOCATION CARD
   ============================================================ */
.loc-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--border-dim);
  border-radius: 10px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease, border-color 0.2s, box-shadow 0.2s;
  position: relative;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.3);
}
.loc-card:hover {
  transform: translateY(-3px);
  border-color: var(--gold);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.5),
              0 0 0 1px rgba(var(--t-accent-rgb), 0.25);
}
.loc-card--legendary { border-left: 3px solid var(--imp-legendary); }
.loc-card--major     { border-left: 3px solid var(--imp-major); }
.loc-card--minor     { border-left: 3px solid var(--imp-minor); }

.loc-card__media {
  position: relative;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, rgba(var(--t-accent-rgb),0.05) 0%, rgba(0,0,0,0.4) 100%);
  overflow: hidden;
}
.loc-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease, filter 0.4s;
  filter: saturate(0.85) contrast(1.05);
}
.loc-card:hover .loc-card__media img {
  transform: scale(1.05);
  filter: saturate(1) contrast(1.05);
}
.loc-card__media-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3.5rem;
  color: rgba(var(--t-accent-rgb), 0.35);
}

/* Pin marker — top-left of media */
.loc-card__pin {
  position: absolute;
  top: 0.55rem;
  left: 0.55rem;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(13, 13, 26, 0.85);
  border: 1px solid var(--gold);
  border-radius: 50%;
  font-size: 1rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

/* Importance badge — top-right */
.loc-card__importance {
  position: absolute;
  top: 0.55rem;
  right: 0.55rem;
  font-family: 'Cinzel', serif;
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  border: 1px solid;
  background: rgba(13, 13, 26, 0.78);
  backdrop-filter: blur(2px);
}
.loc-card__importance--legendary {
  color: var(--imp-legendary);
  border-color: var(--imp-legendary);
  background: rgba(211, 164, 75, 0.12);
}
.loc-card__importance--major {
  color: var(--imp-major);
  border-color: var(--imp-major);
}
.loc-card__importance--minor {
  color: var(--imp-minor);
  border-color: var(--imp-minor);
}

.loc-card__body {
  padding: 0.95rem 1.1rem 1.05rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex: 1;
}
.loc-card__head { display: flex; flex-direction: column; gap: 0.15rem; }
.loc-card__name {
  font-family: 'Cinzel', serif;
  font-size: 1.1rem;
  margin: 0;
  color: var(--gold-light);
  line-height: 1.25;
}
.loc-card__alt {
  font-family: 'Crimson Text', serif;
  font-size: 0.78rem;
  font-style: italic;
  color: var(--text-dim);
}
.loc-card__meta {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  align-items: center;
  font-size: 0.78rem;
  color: var(--text-muted);
}
.loc-card__type {
  font-family: 'Cinzel', serif;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 0.7rem;
  color: var(--gold);
  background: rgba(var(--t-accent-rgb), 0.07);
  border: 1px solid rgba(var(--t-accent-rgb), 0.25);
  border-radius: 4px;
  padding: 0.1rem 0.45rem;
}
.loc-card__region {
  color: var(--text-dim);
  font-style: italic;
}
.loc-card__desc {
  font-family: 'Crimson Text', serif;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--text-dim);
  margin: 0;
}
.loc-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-top: auto;
  padding-top: 0.3rem;
}
.loc-card__tag {
  font-size: 0.7rem;
  padding: 0.1rem 0.45rem;
  background: rgba(var(--t-accent-rgb), 0.06);
  border: 1px solid rgba(var(--t-accent-rgb), 0.18);
  border-radius: 999px;
  color: var(--text-muted);
}
.loc-card__tag--more {
  background: transparent;
  border-color: rgba(var(--t-accent-rgb), 0.4);
  color: var(--gold);
}

/* ============================================================
   DETAIL PAGE — Hero with full image background
   ============================================================ */
.loc-detail-hero {
  position: relative;
  border-radius: var(--t-hero-radius);
  overflow: hidden;
  margin-bottom: 1.5rem;
  border: 1px solid var(--border-dim);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.55);
  isolation: isolate;
}
.loc-detail-hero--has-img { min-height: 360px; }
.loc-detail-hero__media {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.loc-detail-hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.95) contrast(1.05);
}
.loc-detail-hero__veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg,
      rgba(8, 8, 15, 0.25) 0%,
      rgba(8, 8, 15, 0.55) 55%,
      rgba(8, 8, 15, 0.92) 100%),
    radial-gradient(circle at 20% 80%, rgba(var(--t-accent-rgb), 0.15) 0%, transparent 60%);
}
.loc-detail-hero__inner {
  position: relative;
  z-index: 1;
  padding: 2.2rem 2rem 1.8rem;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  min-height: inherit;
}
.loc-detail-hero--has-img .loc-detail-hero__inner {
  padding-top: 220px;
}
.loc-detail-hero__topline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  font-family: 'Cinzel', serif;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}
.loc-detail-hero__pin {
  font-size: 1.1rem;
  margin-right: 0.15rem;
}
.loc-detail-hero__type {
  text-transform: uppercase;
  color: var(--gold);
}
.loc-detail-hero__sep { color: rgba(var(--t-accent-rgb), 0.45); }
.loc-detail-hero__region { font-style: italic; color: var(--text); font-family: 'Crimson Text', serif; letter-spacing: 0.02em; }
.loc-detail-hero__title {
  font-family: 'Cinzel', serif;
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  font-weight: 700;
  color: var(--gold-light);
  margin: 0;
  line-height: 1.1;
  letter-spacing: 0.03em;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.7), 0 0 24px rgba(var(--t-accent-rgb), 0.18);
}
.loc-detail-hero__alt {
  font-family: 'Crimson Text', serif;
  font-style: italic;
  color: var(--text-muted);
  font-size: 0.95rem;
  margin: 0;
}
.loc-detail-hero__alt em { color: rgba(var(--t-accent-rgb), 0.6); font-style: normal; }
.loc-detail-hero__desc {
  font-family: 'Crimson Text', serif;
  font-size: 1.05rem;
  line-height: 1.55;
  color: var(--text);
  margin: 0;
  max-width: 75ch;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.55);
}
.loc-detail-hero__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.4rem;
}

/* ── Status & importance pills ── */
.loc-status, .loc-importance {
  font-family: 'Cinzel', serif;
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  border: 1px solid currentColor;
  background: rgba(13, 13, 26, 0.55);
}
.loc-status--active { color: var(--status-active); }
.loc-status--ruined { color: var(--status-ruined); }
.loc-status--lost   { color: var(--status-lost); }
.loc-importance--legendary { color: var(--imp-legendary); }
.loc-importance--major     { color: var(--imp-major); }
.loc-importance--minor     { color: var(--imp-minor); }

.loc-tag {
  display: inline-block;
  font-family: 'Crimson Text', serif;
  font-size: 0.78rem;
  padding: 0.18rem 0.55rem;
  background: rgba(var(--t-accent-rgb), 0.08);
  border: 1px solid rgba(var(--t-accent-rgb), 0.22);
  border-radius: 999px;
  color: var(--text);
}
.loc-tag--small { font-size: 0.72rem; padding: 0.1rem 0.45rem; color: var(--text-muted); }

/* ============================================================
   ATLAS CARD — cartographer's notebook
   ============================================================ */
.loc-atlas {
  background: linear-gradient(180deg, rgba(var(--t-accent-rgb), 0.04) 0%, rgba(13, 13, 26, 0.4) 100%);
  border: 1px solid var(--border-dim);
  border-radius: 10px;
  padding: 1.2rem 1.5rem 1.3rem;
  margin-bottom: 1.5rem;
  box-shadow: inset 0 0 30px rgba(var(--t-accent-rgb), 0.04);
  scroll-margin-top: 80px;
}
.loc-atlas__header {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 1rem;
}
.loc-atlas__seal {
  font-size: 1.3rem;
  color: var(--gold);
  text-shadow: 0 0 12px rgba(var(--t-accent-rgb), 0.4);
}
.loc-atlas__title {
  font-family: 'Cinzel', serif;
  font-size: 1.1rem;
  color: var(--gold-light);
  margin: 0;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.loc-atlas__line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(var(--t-accent-rgb), 0.4) 0%, transparent 100%);
}
.loc-atlas__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.7rem 1.2rem;
  margin-bottom: 0.9rem;
}
.loc-atlas__cell {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.5rem 0.7rem;
  background: rgba(13, 13, 26, 0.5);
  border: 1px solid rgba(var(--t-accent-rgb), 0.12);
  border-radius: 6px;
  border-left: 2px solid var(--gold);
}
.loc-atlas__cell--wide { grid-column: span 2; }
@media (max-width: 600px) {
  .loc-atlas__cell--wide { grid-column: auto; }
}
.loc-atlas__label {
  font-family: 'Cinzel', serif;
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-dim);
}
.loc-atlas__value {
  font-family: 'Crimson Text', serif;
  font-size: 0.95rem;
  color: var(--text);
  line-height: 1.4;
}

.loc-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  margin-top: 0.6rem;
  padding: 0.5rem 0;
  border-top: 1px dashed rgba(var(--t-accent-rgb), 0.12);
}
.loc-chips__label {
  font-family: 'Cinzel', serif;
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-right: 0.3rem;
}
.loc-chip {
  font-family: 'Crimson Text', serif;
  font-size: 0.78rem;
  padding: 0.18rem 0.6rem;
  border-radius: 4px;
  background: rgba(13, 13, 26, 0.55);
  border: 1px solid rgba(var(--t-accent-rgb), 0.18);
  color: var(--text);
}
.loc-chip--terrain { color: #b8a878; border-color: rgba(184, 168, 120, 0.3); }
.loc-chip--people  { color: #c5a4d6; border-color: rgba(197, 164, 214, 0.3); }
.loc-chip--region  { color: #8eb5c5; border-color: rgba(142, 181, 197, 0.3); }

/* ============================================================
   SCROLL — summary block
   ============================================================ */
.loc-scroll {
  margin: 1.5rem 0;
}
.loc-scroll__block {
  background: var(--bg-card);
  border: 1px solid var(--border-dim);
  border-left: 3px solid var(--gold);
  border-radius: 8px;
  padding: 1.2rem 1.5rem;
}
.loc-scroll__heading {
  font-family: 'Cinzel', serif;
  font-size: 1rem;
  color: var(--gold-light);
  margin: 0 0 0.6rem;
  letter-spacing: 0.04em;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.loc-scroll__icon { font-size: 1rem; }
.loc-scroll__text {
  font-family: 'Crimson Text', serif;
  font-size: 1.02rem;
  line-height: 1.7;
  color: var(--text);
  margin: 0;
  text-align: justify;
  hyphens: auto;
  -webkit-hyphens: auto;
}

/* ============================================================
   SECTIONS — numbered chronicle blocks
   ============================================================ */
.loc-sections {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin: 2rem 0;
}
.loc-section-block {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 1rem;
  padding: 1.1rem 1.3rem 1.2rem;
  background: var(--bg-card);
  border: 1px solid var(--border-dim);
  border-radius: var(--t-section-radius);
  scroll-margin-top: 80px;
  position: relative;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.loc-section-block:hover {
  border-color: rgba(var(--t-accent-rgb), 0.45);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
}
.loc-section-block__rail {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.45rem;
  padding-top: 0.1rem;
}
.loc-section-block__rail::after {
  content: '';
  flex: 1;
  width: 1px;
  background: linear-gradient(180deg, rgba(var(--t-accent-rgb), 0.4) 0%, rgba(var(--t-accent-rgb), 0.05) 100%);
  margin-top: 0.2rem;
}
.loc-section-block__num {
  font-family: 'Cinzel', serif;
  font-size: 1.55rem;
  font-weight: 700;
  color: var(--gold);
  line-height: 1;
  letter-spacing: 0.04em;
  text-shadow: 0 0 10px rgba(var(--t-accent-rgb), 0.3);
}
.loc-section-block__body {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  min-width: 0;
}
.loc-section-block__title {
  font-family: 'Cinzel', serif;
  font-size: 1.15rem;
  margin: 0 0 0.25rem;
  color: var(--gold-light);
  letter-spacing: 0.03em;
  line-height: 1.3;
  border-bottom: 1px solid rgba(var(--t-accent-rgb), 0.12);
  padding-bottom: 0.4rem;
}
.loc-section-block__paragraph {
  font-family: 'Crimson Text', serif;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-dim);
  margin: 0;
  text-align: justify;
  hyphens: auto;
  -webkit-hyphens: auto;
}

/* ============================================================
   SUB-LOCATIONS
   ============================================================ */
.loc-sublocations {
  margin: 2rem 0;
  scroll-margin-top: 80px;
}
.loc-sublocations__list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.loc-sub {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 0;
  background: var(--bg-card);
  border: 1px solid var(--border-dim);
  border-radius: 10px;
  overflow: hidden;
  transition: border-color 0.2s, transform 0.2s;
}
.loc-sub:not(:has(.loc-sub__media)) { grid-template-columns: 1fr; }
.loc-sub:hover { border-color: rgba(var(--t-accent-rgb), 0.5); }
.loc-sub--detailed { border-left: 3px solid var(--gold); }

.loc-sub__media {
  position: relative;
  background: rgba(0, 0, 0, 0.4);
  overflow: hidden;
  min-height: 180px;
}
.loc-sub__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.85) contrast(1.05);
}
.loc-sub__media .loc-sub__pin {
  position: absolute;
  top: 0.5rem;
  left: 0.5rem;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(13, 13, 26, 0.85);
  border: 1px solid var(--gold);
  border-radius: 50%;
  font-size: 0.95rem;
}
.loc-sub__pin--inline {
  display: inline-flex;
  width: 28px;
  height: 28px;
  align-items: center;
  justify-content: center;
  background: rgba(var(--t-accent-rgb), 0.1);
  border: 1px solid rgba(var(--t-accent-rgb), 0.4);
  border-radius: 50%;
  margin-right: 0.4rem;
  font-size: 0.9rem;
  flex: 0 0 auto;
}

.loc-sub__body {
  padding: 1rem 1.3rem 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.loc-sub__title-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.loc-sub__name {
  font-family: 'Cinzel', serif;
  font-size: 1.15rem;
  margin: 0;
  color: var(--gold-light);
  letter-spacing: 0.03em;
}
.loc-sub__name a { color: inherit; }
.loc-sub__name a:hover { color: var(--gold); }
.loc-sub__meta {
  display: flex;
  gap: 0.55rem;
  flex-wrap: wrap;
  align-items: center;
  font-size: 0.78rem;
  color: var(--text-muted);
}
.loc-sub__type {
  font-family: 'Cinzel', serif;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 0.7rem;
  color: var(--gold);
  background: rgba(var(--t-accent-rgb), 0.07);
  border: 1px solid rgba(var(--t-accent-rgb), 0.22);
  border-radius: 4px;
  padding: 0.1rem 0.4rem;
}
.loc-sub__alt { font-style: italic; color: var(--text-dim); }
.loc-sub__short {
  font-family: 'Crimson Text', serif;
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--text);
  margin: 0;
}
.loc-sub__summary {
  font-family: 'Crimson Text', serif;
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--text-dim);
  margin: 0;
  font-style: italic;
}
.loc-sub__tags { display: flex; flex-wrap: wrap; gap: 0.3rem; }

.loc-sub__details {
  margin-top: 0.4rem;
  border-top: 1px dashed rgba(var(--t-accent-rgb), 0.18);
  padding-top: 0.6rem;
}
.loc-sub__details-summary {
  cursor: pointer;
  font-family: 'Cinzel', serif;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold);
  padding: 0.3rem 0;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.loc-sub__details-summary::-webkit-details-marker { display: none; }
.loc-sub__details-summary::before {
  content: '▸';
  display: inline-block;
  transition: transform 0.2s;
  color: var(--gold);
}
.loc-sub__details[open] .loc-sub__details-summary::before {
  transform: rotate(90deg);
}
.loc-sub__details-summary:hover { color: var(--gold-light); }
.loc-sub__details-body {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-top: 0.7rem;
  padding-left: 0.6rem;
  border-left: 2px solid rgba(var(--t-accent-rgb), 0.2);
}
.loc-sub__section-title {
  font-family: 'Cinzel', serif;
  font-size: 0.95rem;
  color: var(--gold-light);
  margin: 0 0 0.3rem;
  letter-spacing: 0.02em;
}
.loc-sub__section-paragraph {
  font-family: 'Crimson Text', serif;
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--text-dim);
  margin: 0 0 0.5rem;
  text-align: justify;
  hyphens: auto;
}
.loc-sub__section-paragraph:last-child { margin-bottom: 0; }

@media (max-width: 720px) {
  .loc-sub { grid-template-columns: 1fr; }
  .loc-sub__media { min-height: 200px; aspect-ratio: 16/9; }
}

/* ============================================================
   HISTORY TIMELINE
   ============================================================ */
.loc-history {
  margin: 2rem 0;
  scroll-margin-top: 80px;
}
.loc-history__list {
  display: flex;
  flex-direction: column;
}
.loc-history__entry {
  display: grid;
  grid-template-columns: 90px 22px 1fr;
  column-gap: 0;
}
.loc-history__year {
  text-align: right;
  padding-right: 0.7rem;
  padding-top: 0.7rem;
  font-family: 'Crimson Text', serif;
  font-size: 0.9rem;
  font-style: italic;
  color: var(--text-dim);
  white-space: nowrap;
}
.loc-history__spine {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 0.95rem;
}
.loc-history__dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid var(--gold);
  background: var(--bg-deep);
  box-shadow: 0 0 8px rgba(var(--t-accent-rgb), 0.4);
  z-index: 2;
}
.loc-history__connector {
  position: absolute;
  top: 1.2rem;
  bottom: -0.8rem;
  left: 50%;
  width: 2px;
  background: linear-gradient(180deg,
    rgba(var(--t-accent-rgb), 0.5) 0%,
    rgba(var(--t-accent-rgb), 0.1) 100%);
  transform: translateX(-50%);
}
.loc-history__card {
  margin: 0.4rem 0 1.3rem;
  padding: 0.85rem 1.1rem;
  background: var(--bg-card);
  border: 1px solid var(--border-dim);
  border-left: 2px solid var(--gold);
  border-radius: 7px;
  transition: border-color 0.2s;
}
.loc-history__card:hover { border-color: rgba(var(--t-accent-rgb), 0.55); }
.loc-history__name {
  font-family: 'Cinzel', serif;
  font-size: 0.95rem;
  color: var(--gold-light);
  margin: 0 0 0.25rem;
  letter-spacing: 0.02em;
}
.loc-history__desc {
  font-family: 'Crimson Text', serif;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--text-dim);
  margin: 0;
}

/* ============================================================
   ADVENTURE HOOKS — DM box
   ============================================================ */
.loc-hooks {
  margin: 2rem 0;
  scroll-margin-top: 80px;
  background:
    repeating-linear-gradient(
      0deg,
      rgba(var(--t-hooks-stripe-rgb), 0.04) 0px,
      rgba(var(--t-hooks-stripe-rgb), 0.04) 1px,
      transparent 1px,
      transparent 6px),
    linear-gradient(180deg, rgba(var(--t-hooks-stripe-rgb), 0.06) 0%, rgba(13, 13, 26, 0.4) 100%);
  border: 1px solid rgba(var(--t-hooks-rgb), 0.35);
  border-radius: 12px;
  padding: 1.4rem 1.6rem 1.6rem;
  position: relative;
}
.loc-hooks::before {
  content: '';
  position: absolute;
  inset: 4px;
  border: 1px dashed rgba(var(--t-hooks-rgb), 0.25);
  border-radius: 10px;
  pointer-events: none;
}
.loc-hooks__head {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin-bottom: 1rem;
  align-items: flex-start;
  position: relative;
}
.loc-hooks__seal {
  font-size: 1.5rem;
  color: rgb(var(--t-hooks-title-rgb));
  text-shadow: 0 0 12px rgba(var(--t-hooks-rgb), 0.5);
}
.loc-hooks__title {
  font-family: 'Cinzel', serif;
  font-size: 1.3rem;
  color: rgb(var(--t-hooks-title-rgb));
  margin: 0;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.loc-hooks__lead {
  font-family: 'Crimson Text', serif;
  font-style: italic;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin: 0;
  max-width: 70ch;
}
.loc-hooks__list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 0.85rem;
  position: relative;
}
.loc-hook {
  position: relative;
  padding: 0.95rem 1.1rem 1rem;
  background: rgba(13, 13, 26, 0.7);
  border: 1px solid rgba(var(--t-hooks-rgb), 0.25);
  border-radius: 7px;
  transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
}
.loc-hook:hover {
  transform: translateY(-2px);
  border-color: rgba(var(--t-hooks-rgb), 0.6);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45);
}
.loc-hook__rune {
  position: absolute;
  top: 0.55rem;
  right: 0.7rem;
  color: rgba(var(--t-hooks-rgb), 0.6);
  font-size: 0.95rem;
}
.loc-hook__title {
  font-family: 'Cinzel', serif;
  font-size: 1rem;
  color: var(--gold-light);
  margin: 0 0 0.4rem;
  letter-spacing: 0.02em;
  padding-right: 1.2rem;
}
.loc-hook__desc {
  font-family: 'Crimson Text', serif;
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--text-dim);
  margin: 0;
}

/* ============================================================
   CONNECTIONS BLOCK
   ============================================================ */
.loc-connections {
  margin: 2rem 0;
  scroll-margin-top: 80px;
}
.loc-connections__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}
.loc-conn-block {
  background: var(--bg-card);
  border: 1px solid var(--border-dim);
  border-radius: 8px;
  padding: 0.95rem 1.1rem 1rem;
}
.loc-conn-block__title {
  font-family: 'Cinzel', serif;
  font-size: 0.9rem;
  color: var(--gold-light);
  margin: 0 0 0.6rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  border-bottom: 1px solid rgba(var(--t-accent-rgb), 0.15);
  padding-bottom: 0.4rem;
}
.loc-conn-block__icon { font-size: 1rem; color: var(--gold); }
.loc-conn-block__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}
.loc-conn-pill {
  display: inline-block;
  padding: 0.22rem 0.6rem;
  background: rgba(var(--t-accent-rgb), 0.07);
  border: 1px solid rgba(var(--t-accent-rgb), 0.22);
  border-radius: 4px;
  color: var(--text);
  font-size: 0.85rem;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s, color 0.15s, transform 0.15s;
}
.loc-conn-pill--link:hover {
  background: rgba(var(--t-accent-rgb), 0.16);
  border-color: var(--gold);
  color: var(--gold-light);
  transform: translateY(-1px);
}
.loc-chip--link {
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s, transform 0.15s;
}
.loc-chip--link:hover {
  background: rgba(var(--t-accent-rgb), 0.16);
  border-color: var(--gold) !important;
  color: var(--gold-light);
  transform: translateY(-1px);
}
.loc-atlas__link {
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px dashed rgba(var(--t-accent-rgb), 0.45);
  transition: color 0.15s, border-color 0.15s;
}
.loc-atlas__link:hover {
  color: var(--gold-light);
  border-bottom-color: var(--gold);
}

/* ============================================================
   PER-LOCATION THEMES
   ------------------------------------------------------------
   Each location gets its own palette + a subtle layout tell so
   that switching between detail pages feels like turning the
   page in a chronicle, not reskinning a single template.

   Themes redefine three things:
     • --gold / --gold-light          → all primary text/border accents
     • --t-accent-rgb                 → all rgba() tints (borders, glows…)
     • --t-hooks-rgb / -title-rgb     → DM hook box accents
   Plus optional structural knobs:
     • --t-hero-radius / -section-radius → corner language (round/sharp)
     • --t-ambient                       → ambient background overlay
   ============================================================ */

/* Ambient overlay layer — uses an absolutely-positioned ::before */
.lore-content[data-loc-theme] {
  position: relative;
}
.lore-content[data-loc-theme]::before {
  content: '';
  position: absolute;
  inset: -40px 0 0;
  z-index: -1;
  background: var(--t-ambient);
  pointer-events: none;
  opacity: 0.55;
}

/* Detail-hero veil retint: every theme contributes its accent to the radial */
.lore-content[data-loc-theme] .loc-detail-hero__veil {
  background:
    linear-gradient(180deg,
      rgba(8, 8, 15, 0.25) 0%,
      rgba(8, 8, 15, 0.55) 55%,
      rgba(8, 8, 15, 0.92) 100%),
    radial-gradient(circle at 20% 80%,
      rgba(var(--t-accent-rgb), 0.18) 0%,
      transparent 60%);
}

/* ─────────────────────────────────────────────────────────────
   1. magnur — Imperial gold & ivory marble (default polished)
   Vibe: regal, classical, columns of light. Sharp corners stay
   default, but the hero radius softens slightly — like the
   moulding of a senate hall.
   ───────────────────────────────────────────────────────────── */
.lore-content[data-loc-theme="magnur"] {
  --gold:       #e7c66a;
  --gold-light: #fadf94;
  --t-accent-rgb: 231, 198, 106;
  --t-hooks-rgb: 200, 80, 60;
  --t-hooks-stripe-rgb: 150, 50, 40;
  --t-hooks-title-rgb: 230, 110, 80;
  --t-hero-radius: 18px;
  --t-section-radius: 10px;
  --t-ambient:
    radial-gradient(ellipse 60% 40% at 50% 0%,
      rgba(231, 198, 106, 0.08) 0%, transparent 70%);
}

/* ─────────────────────────────────────────────────────────────
   2. stredozemi_magnuru — Warm heartland, wheat & terracotta
   Vibe: harvest sun, ochre fields. Slightly warmer than Magnur,
   no marble glow — more clay, more grain.
   ───────────────────────────────────────────────────────────── */
.lore-content[data-loc-theme="stredozemi_magnuru"] {
  --gold:       #d39a3c;
  --gold-light: #efc26e;
  --t-accent-rgb: 211, 154, 60;
  --t-hooks-rgb: 178, 86, 44;
  --t-hooks-stripe-rgb: 130, 60, 30;
  --t-hooks-title-rgb: 220, 130, 70;
  --t-hero-radius: 14px;
  --t-section-radius: 8px;
  --t-ambient:
    repeating-linear-gradient(135deg,
      rgba(211, 154, 60, 0.04) 0px,
      rgba(211, 154, 60, 0.04) 2px,
      transparent 2px,
      transparent 18px),
    radial-gradient(ellipse at 70% 10%,
      rgba(211, 154, 60, 0.06) 0%, transparent 60%);
}

/* ─────────────────────────────────────────────────────────────
   3. velka_elfi_rise — Emerald forest, ancient & organic
   Vibe: leaves, moss, silver dapples. Border-radius runs soft
   and round, like a clearing's edge.
   ───────────────────────────────────────────────────────────── */
.lore-content[data-loc-theme="velka_elfi_rise"] {
  --gold:       #6cbb86;
  --gold-light: #b3dec0;
  --t-accent-rgb: 108, 187, 134;
  --t-hooks-rgb: 168, 124, 196;
  --t-hooks-stripe-rgb: 90, 60, 130;
  --t-hooks-title-rgb: 190, 150, 220;
  --t-hero-radius: 22px;
  --t-section-radius: 14px;
  --t-ambient:
    radial-gradient(circle at 15% 25%,
      rgba(108, 187, 134, 0.10) 0%, transparent 35%),
    radial-gradient(circle at 85% 70%,
      rgba(108, 187, 134, 0.07) 0%, transparent 40%),
    radial-gradient(circle at 50% 110%,
      rgba(168, 220, 180, 0.04) 0%, transparent 50%);
}
.lore-content[data-loc-theme="velka_elfi_rise"] .loc-card,
.lore-content[data-loc-theme="velka_elfi_rise"] .loc-sub,
.lore-content[data-loc-theme="velka_elfi_rise"] .loc-history__card,
.lore-content[data-loc-theme="velka_elfi_rise"] .loc-conn-block,
.lore-content[data-loc-theme="velka_elfi_rise"] .loc-atlas,
.lore-content[data-loc-theme="velka_elfi_rise"] .loc-hooks {
  border-radius: 16px;
}

/* ─────────────────────────────────────────────────────────────
   4. albarit — Blood, dragons, the forbidden east
   Vibe: cracked basalt, embers in the dark. Crimson accents,
   tight sharp corners, faint scale-pattern ambient.
   ───────────────────────────────────────────────────────────── */
.lore-content[data-loc-theme="albarit"] {
  --gold:       #c44758;
  --gold-light: #ee7a8a;
  --t-accent-rgb: 196, 71, 88;
  --t-hooks-rgb: 156, 36, 50;
  --t-hooks-stripe-rgb: 100, 20, 28;
  --t-hooks-title-rgb: 220, 90, 105;
  --t-hero-radius: 6px;
  --t-section-radius: 4px;
  --t-ambient:
    repeating-linear-gradient(45deg,
      rgba(196, 71, 88, 0.05) 0px,
      rgba(196, 71, 88, 0.05) 1px,
      transparent 1px,
      transparent 14px),
    radial-gradient(ellipse 70% 40% at 50% 8%,
      rgba(196, 71, 88, 0.10) 0%, transparent 70%);
}
.lore-content[data-loc-theme="albarit"] .loc-detail-hero__title {
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.85),
               0 0 24px rgba(196, 71, 88, 0.30);
}

/* ─────────────────────────────────────────────────────────────
   5. umbra_profunda — Violet shadow desert, starlit sand
   Vibe: deep dusk, distant constellations, dunes. Soft round
   corners and a starfield-like dotted ambient.
   ───────────────────────────────────────────────────────────── */
.lore-content[data-loc-theme="umbra_profunda"] {
  --gold:       #a986d4;
  --gold-light: #cdb2e8;
  --t-accent-rgb: 169, 134, 212;
  --t-hooks-rgb: 200, 110, 80;
  --t-hooks-stripe-rgb: 130, 60, 40;
  --t-hooks-title-rgb: 230, 150, 110;
  --t-hero-radius: 20px;
  --t-section-radius: 12px;
  --t-ambient:
    radial-gradient(1px 1px at 20% 12%, rgba(220, 200, 250, 0.45) 50%, transparent 100%),
    radial-gradient(1px 1px at 65% 32%, rgba(220, 200, 250, 0.35) 50%, transparent 100%),
    radial-gradient(1px 1px at 88% 18%, rgba(220, 200, 250, 0.5)  50%, transparent 100%),
    radial-gradient(1px 1px at 42% 8%,  rgba(220, 200, 250, 0.4)  50%, transparent 100%),
    radial-gradient(1px 1px at 78% 55%, rgba(220, 200, 250, 0.35) 50%, transparent 100%),
    radial-gradient(1px 1px at 15% 70%, rgba(220, 200, 250, 0.4)  50%, transparent 100%),
    radial-gradient(ellipse 80% 60% at 50% 0%,
      rgba(120, 80, 180, 0.10) 0%, transparent 70%);
}

/* ─────────────────────────────────────────────────────────────
   6. zmrzle_kameny — Frozen north, ice-blue & glacier white
   Vibe: cold light, crystalline edges. Sharp angular corners,
   faint crystalline ambient gradient.
   ───────────────────────────────────────────────────────────── */
.lore-content[data-loc-theme="zmrzle_kameny"] {
  --gold:       #8fc8e3;
  --gold-light: #c3e3f1;
  --t-accent-rgb: 143, 200, 227;
  --t-hooks-rgb: 90, 140, 190;
  --t-hooks-stripe-rgb: 50, 90, 140;
  --t-hooks-title-rgb: 140, 200, 235;
  --t-hero-radius: 3px;
  --t-section-radius: 2px;
  --t-ambient:
    linear-gradient(135deg,
      rgba(143, 200, 227, 0.06) 0%, transparent 40%),
    linear-gradient(45deg,
      rgba(143, 200, 227, 0.04) 0%, transparent 35%),
    radial-gradient(ellipse 60% 30% at 50% 0%,
      rgba(195, 227, 241, 0.06) 0%, transparent 70%);
}
.lore-content[data-loc-theme="zmrzle_kameny"] .loc-detail-hero__title {
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.7),
               0 0 18px rgba(143, 200, 227, 0.45);
}

/* ─────────────────────────────────────────────────────────────
   7. hroidetur — Mountain stone, slate & weathered bronze
   Vibe: granite, eagles, wind-scoured cliffs. Muted bronze
   accent with vertical striation ambient — strata of rock.
   ───────────────────────────────────────────────────────────── */
.lore-content[data-loc-theme="hroidetur"] {
  --gold:       #c4a572;
  --gold-light: #ddc59a;
  --t-accent-rgb: 196, 165, 114;
  --t-hooks-rgb: 156, 88, 56;
  --t-hooks-stripe-rgb: 100, 56, 36;
  --t-hooks-title-rgb: 200, 130, 80;
  --t-hero-radius: 8px;
  --t-section-radius: 5px;
  --t-ambient:
    repeating-linear-gradient(90deg,
      rgba(196, 165, 114, 0.025) 0px,
      rgba(196, 165, 114, 0.025) 1px,
      transparent 1px,
      transparent 24px),
    radial-gradient(ellipse at 50% 0%,
      rgba(196, 165, 114, 0.06) 0%, transparent 60%);
}

/* ─────────────────────────────────────────────────────────────
   8. daleky_vychod — Volcanic east, teal lakes & ember sky
   Vibe: steam over water, basalt rims of dormant calderas.
   Teal primary, ember-orange DM hooks.
   ───────────────────────────────────────────────────────────── */
.lore-content[data-loc-theme="daleky_vychod"] {
  --gold:       #5fb5ad;
  --gold-light: #93cec7;
  --t-accent-rgb: 95, 181, 173;
  --t-hooks-rgb: 210, 110, 50;
  --t-hooks-stripe-rgb: 140, 60, 25;
  --t-hooks-title-rgb: 240, 140, 70;
  --t-hero-radius: 12px;
  --t-section-radius: 7px;
  --t-ambient:
    radial-gradient(ellipse 50% 30% at 18% 12%,
      rgba(95, 181, 173, 0.10) 0%, transparent 70%),
    radial-gradient(ellipse 40% 25% at 82% 6%,
      rgba(210, 110, 50, 0.07) 0%, transparent 70%);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 760px) {
  .loc-hero { gap: 1.2rem; padding-top: 1rem; }
  .loc-compass { flex: 0 0 220px; width: 220px; height: 220px; }
  .loc-detail-hero--has-img .loc-detail-hero__inner { padding-top: 160px; }
  .loc-detail-hero__inner { padding: 1.4rem 1.2rem 1.3rem; }
  .loc-section-block { grid-template-columns: 44px 1fr; gap: 0.8rem; padding: 0.95rem 1.1rem; }
  .loc-section-block::before { left: 44px; }
  .loc-section-block__num { font-size: 1.2rem; }
  .loc-history__entry { grid-template-columns: 70px 18px 1fr; }
}
