/* Heritage section layouts (shared site chrome: assets/css/site.css) */

.heritage-accent--saffron {
  --heritage-accent: var(--saffron);
  --heritage-accent-deep: var(--saffron-deep);
}

.heritage-accent--blue {
  --heritage-accent: var(--blue-rich);
  --heritage-accent-deep: var(--blue-mid);
}

.heritage-accent--ink {
  --heritage-accent: #1a1a1a;
  --heritage-accent-deep: var(--jet);
}

.heritage-page .heritage-main {
  max-width: 1120px;
  width: 100%;
  min-width: 0;
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
  flex: 1;
}

.heritage-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.heritage-page-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 700;
  margin: 0 0 0.5rem;
  color: var(--jet);
}

.heritage-lead {
  font-size: 1.125rem;
  color: var(--text-muted-light);
  max-width: 52ch;
  margin: 0 0 2rem;
}

.heritage-filters {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: 1.25rem;
  row-gap: 1rem;
  width: 100%;
  max-width: 100%;
  margin-bottom: 2rem;
  padding: 1.25rem;
  background: var(--pearl-soft);
  border-radius: 12px;
  border: 1px solid rgba(12, 45, 92, 0.08);
  box-sizing: border-box;
  align-items: end;
}

.heritage-filters__row--controls {
  display: contents;
}

.heritage-filters__row--search {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 1rem;
  width: 100%;
  min-width: 0;
}

.heritage-filters label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted-light);
  min-width: 0;
}

.heritage-filters select {
  width: 100%;
  min-width: 0;
  padding: 0.5rem 0.65rem;
  font-family: var(--font-body);
  font-size: 1rem;
  border: 1px solid rgba(10, 10, 10, 0.15);
  border-radius: 8px;
  background: #fff;
}

.heritage-filters__search {
  flex: 1 1 16rem;
  min-width: 0;
  max-width: none;
}

.heritage-filters__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
  margin-left: auto;
}

@media (max-width: 700px) {
  .heritage-filters {
    grid-template-columns: 1fr;
  }

  .heritage-filters__row--search {
    flex-direction: column;
    align-items: stretch;
  }

  .heritage-filters__actions {
    margin-left: 0;
    justify-content: flex-start;
  }
}

.heritage-filters__search input[type="search"] {
  width: 100%;
  padding: 0.5rem 0.65rem;
  font-family: var(--font-body);
  font-size: 1rem;
  border: 1px solid rgba(10, 10, 10, 0.15);
  border-radius: 8px;
  background: #fff;
}

.heritage-filters__search input[type="search"]::placeholder {
  color: rgba(61, 61, 61, 0.55);
}

.heritage-btn {
  display: inline-block;
  padding: 0.55rem 1.1rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: 8px;
  border: none;
  background: var(--heritage-accent);
  color: #fff;
  cursor: pointer;
  text-decoration: none;
}

.heritage-btn--clear {
  background: #3d3d3d;
  text-align: center;
}

.heritage-btn--clear:hover {
  filter: brightness(1.08);
}

.heritage-btn--clear-slot {
  visibility: hidden;
  pointer-events: none;
  user-select: none;
  cursor: default;
}

.heritage-btn:hover {
  filter: brightness(0.95);
}

.heritage-article-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1rem;
}

.heritage-article-card {
  background: #fff;
  border: 1px solid rgba(10, 10, 10, 0.08);
  border-radius: 12px;
  padding: 1.25rem 1.35rem;
  box-shadow: 0 8px 24px rgba(10, 10, 10, 0.05);
}

.heritage-article-card a {
  color: var(--jet);
  text-decoration: none;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
}

.heritage-article-card a:hover {
  color: var(--heritage-accent-deep);
}

.heritage-meta {
  margin-top: 0.5rem;
  font-size: 0.88rem;
  color: var(--text-muted-light);
  overflow-wrap: anywhere;
}

.heritage-meta span {
  margin-right: 0.75rem;
}

.heritage-type-badge {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: rgba(12, 45, 92, 0.08);
  color: var(--blue-rich);
}

.heritage-article-head {
  margin-bottom: 1.5rem;
}

.heritage-kicker {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--heritage-accent-deep);
  margin: 0 0 0.35rem;
}

.heritage-article-head h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.85rem);
  font-weight: 700;
  margin: 0 0 0.75rem;
  line-height: 1.15;
}

.heritage-summary {
  font-size: 1.15rem;
  color: var(--text-muted-light);
  margin: 0;
  max-width: 65ch;
}

.heritage-body {
  max-width: 65ch;
}

.heritage-body p {
  margin: 0 0 1rem;
}

.heritage-facts {
  margin: 1.25rem 0;
  padding: 1rem 1.25rem;
  background: var(--pearl-soft);
  border-radius: 8px;
  border-left: 4px solid var(--heritage-accent);
}

.heritage-facts dt {
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted-light);
  margin-top: 0.75rem;
}

.heritage-facts dt:first-child {
  margin-top: 0;
}

.heritage-facts dd {
  margin: 0.25rem 0 0;
}

/* Merged person pages: one section per Guru era */
.heritage-person-period {
  margin: 2.25rem 0;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(12, 45, 92, 0.12);
}

.heritage-person-period:first-of-type {
  margin-top: 0.5rem;
  padding-top: 0;
  border-top: none;
}

.heritage-person-period__heading {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 1rem;
  color: var(--heritage-accent-deep);
}

.heritage-facts--period {
  margin: 1rem 0 1.25rem;
}

.heritage-empty {
  padding: 2rem;
  text-align: center;
  color: var(--text-muted-light);
  background: var(--pearl-soft);
  border-radius: 12px;
}

.heritage-error {
  padding: 2rem;
  background: #fff5f5;
  border: 1px solid #f5c2c2;
  border-radius: 12px;
  color: #7f1d1d;
}
