/* ==========================================================================
   Shared styles: the Dalai Lamas, Buddhist countries, claims
   ========================================================================== */

/* ---- the lineage list --------------------------------------------------- */
.dls { display: grid; gap: 0; border-top: 1px solid var(--rule); }
.dl {
  display: grid; gap: .6rem 2rem; padding: clamp(1.3rem,2.4vw,1.9rem) 0;
  border-bottom: 1px solid var(--rule); scroll-margin-top: 6rem;
}
@media (min-width: 780px) { .dl { grid-template-columns: 5rem 1fr; } }
.dl__n span {
  display: inline-grid; place-items: center;
  width: 3.1rem; height: 3.1rem; border-radius: 50%;
  background: var(--ground-2); color: var(--red);
  font-family: var(--f-display); font-size: 1rem; font-weight: 500;
}
.dl:last-child .dl__n span { background: var(--red); color: #fff; }
.dl h3 { font-size: 1.3rem; margin: 0 0 .3rem; }
.dl h3 em { font-family: var(--f-body); font-style: normal; font-size: .62em; color: var(--tx-faint); margin-left: .5em; letter-spacing: .01em; }
.dl__one { font-size: .93rem; color: var(--red); margin: 0 0 .6rem; max-width: none; }
.dl__text { font-size: .93rem; line-height: 1.68; color: var(--tx-soft); max-width: none; margin: 0; }

.methods { margin: 1rem 0 1.5rem; padding-left: 1.1rem; }
.methods li { font-size: .93rem; line-height: 1.6; color: var(--tx-soft); margin-bottom: .6rem; }
.dark .methods li { color: rgba(244,236,224,.8); }

/* ---- countries ---------------------------------------------------------- */
.ctries { display: grid; gap: clamp(.9rem, 1.8vw, 1.4rem); }
@media (min-width: 900px) { .ctries { grid-template-columns: 1fr 1fr; } }
.ctry {
  background: var(--paper); border: 1px solid var(--rule-soft);
  border-top: 3px solid var(--red); border-radius: 13px;
  padding: clamp(1.2rem,2.2vw,1.7rem);
}
.ctry__head { display: flex; flex-wrap: wrap; gap: .4rem 1rem; align-items: baseline; justify-content: space-between; margin-bottom: .5rem; }
.ctry h3 { font-size: 1.35rem; margin: 0; }
.ctry__tag {
  font-size: .6rem; letter-spacing: .16em; text-transform: uppercase; font-weight: 600;
  color: var(--saffron); white-space: nowrap;
}
.ctry__one { font-family: var(--f-display); font-size: 1.04rem; line-height: 1.4; color: var(--tx); margin: 0 0 .8rem; max-width: none; }
.ctry__text { font-size: .9rem; line-height: 1.68; color: var(--tx-soft); margin: 0; max-width: none; }

.obriefs { display: grid; gap: 0; border-top: 1px solid var(--rule); }
.obrief {
  display: grid; gap: .3rem 2.5rem; padding: 1.15rem 0; border-bottom: 1px solid var(--rule-soft);
}
@media (min-width: 780px) { .obrief { grid-template-columns: 13rem 1fr; align-items: start; } }
.obrief h4 { font-family: var(--f-display); font-size: 1.08rem; font-weight: 500; margin: 0; }
.obrief span { font-size: .68rem; letter-spacing: .14em; text-transform: uppercase; color: var(--saffron); }
.obrief p { font-size: .9rem; line-height: 1.65; color: var(--tx-soft); margin: 0; max-width: none; }

/* ---- claims ------------------------------------------------------------- */
.callout {
  background: var(--ground-2); border-radius: 14px; padding: clamp(1.3rem,2.4vw,1.9rem);
  border-left: 4px solid var(--saffron);
}
.callout h3 { font-size: 1.25rem; margin: 0 0 .7rem; }
.callout p { font-size: .92rem; line-height: 1.68; color: var(--tx-soft); max-width: none; }

.signs {
  display: grid; gap: .8rem;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr));
}
.sign {
  background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.11);
  border-left: 3px solid var(--gold-lt); border-radius: 12px; padding: 1.1rem 1.2rem;
}
.sign h4 {
  font-family: var(--f-display); font-size: 1.05rem; font-weight: 500; color: #fff;
  margin: 0 0 .45rem; letter-spacing: -.005em;
}
.sign p { font-size: .86rem; line-height: 1.6; color: rgba(244,236,224,.78); margin: 0; max-width: none; }

/* ---- changelog ---------------------------------------------------------- */
.rels { display: grid; gap: 0; border-top: 1px solid var(--rule); }
.rel {
  display: grid; gap: 1rem 3rem; padding: clamp(1.8rem,3.5vw,3rem) 0;
  border-bottom: 1px solid var(--rule);
}
@media (min-width: 860px) { .rel { grid-template-columns: 13rem 1fr; } }
.rel__v {
  font-family: var(--f-display); font-size: 2.2rem; line-height: 1; color: var(--red);
  margin: 0 0 .3rem;
}
.rel__meta time { font-size: .82rem; color: var(--tx-faint); font-variant-numeric: tabular-nums; }
.rel__label { font-size: .88rem; color: var(--tx-soft); margin: .4rem 0 0; max-width: none; }
.rel__intro { font-size: 1.02rem; line-height: 1.6; color: var(--tx); max-width: none; margin-bottom: 1.6rem; }
.rel__group { margin-bottom: 1.6rem; }
.rel__group h4 {
  font-family: var(--f-body); font-size: .65rem; letter-spacing: .2em; text-transform: uppercase;
  color: var(--saffron); margin: 0 0 .7rem;
}
.rel__group ul { margin: 0; padding: 0; list-style: none; display: grid; gap: .5rem; }
.rel__group li {
  position: relative; padding-left: 1.2rem; font-size: .9rem; line-height: 1.6; color: var(--tx-soft);
}
.rel__group li::before {
  content: ""; position: absolute; left: 0; top: .55rem;
  width: 5px; height: 5px; border-radius: 50%; background: var(--rule);
}

/* ---- portrait thumbnails ------------------------------------------------ */
.dl__n { display: grid; gap: .8rem; justify-items: start; }
@media (min-width: 780px) { .dl { grid-template-columns: 9.5rem 1fr; } }
.dl__portrait { margin: 0; width: 100%; max-width: 8.6rem; }
.dl__portrait img {
  width: 100%; height: auto; border-radius: 9px;
  border: 1px solid var(--rule);
  background: var(--ground-2);
  box-shadow: 0 12px 26px -20px rgba(43,26,18,.7);
}
.dl__portrait figcaption {
  font-size: .58rem; line-height: 1.35; color: var(--tx-faint);
  margin-top: .4rem; letter-spacing: .01em;
}

/* ---- FAQ ---------------------------------------------------------------- */
.faqsec { padding-block: clamp(2rem, 4vw, 3.2rem); }
.faqsec:nth-of-type(even) { background: var(--ground-2); }
.faqs { display: grid; gap: 0; border-top: 1px solid var(--rule); margin-top: 1.2rem; }
.faq { border-bottom: 1px solid var(--rule); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; align-items: flex-start; gap: .9rem;
  padding: 1.05rem 0; font-family: var(--f-display); font-size: clamp(1.05rem,.98rem+.45vw,1.3rem);
  line-height: 1.32; color: var(--tx); transition: color .2s;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before {
  content: ""; flex: none; width: 9px; height: 9px; margin-top: .45em;
  border-right: 2px solid var(--red); border-bottom: 2px solid var(--red);
  transform: rotate(-45deg); transition: transform .3s var(--ease);
}
.faq[open] summary::before { transform: rotate(45deg); }
.faq summary:hover { color: var(--red); }
.faq__body { padding: 0 0 1.3rem 1.9rem; max-width: 62ch; }
.faq__body p { font-size: .94rem; line-height: 1.7; color: var(--tx-soft); max-width: none; }
.faq__src {
  font-size: .78rem; color: var(--tx-faint); margin: 1rem 0 0 !important;
  padding-top: .7rem; border-top: 1px solid var(--rule-soft);
}
.faq__src a { color: var(--red); text-decoration: none; border-bottom: 1px dotted currentColor; }
.faq__src a:hover { border-bottom-style: solid; }

/* ---- What happens at a teaching --------------------------------------- */
.evlist { display: grid; gap: clamp(1.5rem, 3vw, 2.4rem); margin-top: 2.5rem; }
.ev {
  display: grid; grid-template-columns: auto 1fr; gap: 1rem clamp(1rem, 2.5vw, 2rem);
  padding-top: 1.8rem; border-top: 1px solid var(--rule-soft);
}
.ev:first-child { border-top: 0; padding-top: 0; }
.ev__n {
  font-family: var(--f-display); font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.4rem);
  line-height: 1; color: var(--saffron); font-weight: 500;
}
.ev__body h3 { margin: 0 0 .6em; font-size: clamp(1.15rem, 1rem + .6vw, 1.5rem); }
.ev__body p { max-width: 62ch; }
.ev__liturgy { margin: 1rem 0 1.2rem; padding-left: 1.3rem; display: grid; gap: .35rem; }
.ev__liturgy li { font-size: .93rem; line-height: 1.5; color: var(--tx-soft); }
.ev__liturgy li strong { color: var(--tx); }
.ev__tip {
  margin-top: 1.1rem; padding: .7rem .9rem; border-radius: 8px;
  background: rgba(28, 111, 102, .07); border-left: 3px solid var(--turquoise);
  font-size: .88rem; line-height: 1.55;
}
.ev__tip span {
  display: block; font-size: .68rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--turquoise); margin-bottom: .2rem; font-weight: 600;
}
@media (max-width: 560px) { .ev { grid-template-columns: 1fr; gap: .3rem; } }

.qalist { display: grid; gap: .6rem; margin-top: 1.8rem; }
.qa { border: 1px solid var(--rule-soft); border-radius: 10px; background: var(--paper); }
.qa summary {
  cursor: pointer; padding: .9rem 1.1rem; font-weight: 500;
  font-family: var(--f-display); font-size: 1.02rem; list-style: none;
  display: flex; justify-content: space-between; gap: 1rem; align-items: center;
}
.qa summary::-webkit-details-marker { display: none; }
.qa summary::after { content: "+"; color: var(--red); font-size: 1.3rem; line-height: 1; flex: none; }
.qa[open] summary::after { content: "\2212"; }
.qa__a { padding: 0 1.1rem 1.1rem; }
.qa__a p { margin: 0; font-size: .93rem; line-height: 1.65; color: var(--tx-soft); max-width: 62ch; }

/* ---- sitemap.html ------------------------------------------------------- */
.smgroups {
  display: grid; gap: clamp(1.6rem, 3vw, 2.6rem); margin-top: 2.4rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
}
.smgroup h2 {
  font-size: .72rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--red); margin: 0 0 1rem; font-family: var(--f-body); font-weight: 600;
}
.smlist { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; }
.smlist li { display: grid; gap: .15rem; }
.smlist a {
  text-decoration: none; color: var(--tx);
  display: inline-flex; align-items: baseline; gap: .35rem;
}
.smlist a strong { font-family: var(--f-display); font-weight: 500; font-size: 1.02rem; }
.smlist a .ar { flex: none; opacity: .5; }
.smlist a:hover strong, .smlist a:focus-visible strong { color: var(--red); text-decoration: underline; text-underline-offset: 3px; }
.smlist span { font-size: .84rem; line-height: 1.5; color: var(--tx-soft); max-width: 52ch; }
.smlist--arts { margin-top: 2rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 1.2rem 2rem; }
.smlist--arts time { color: var(--tx-faint); }

.drawer__h {
  font-size: .64rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--gold); margin: 1.6rem 0 .5rem; font-weight: 600;
}
.drawer__h:first-child { margin-top: 0; }

/* ---------- a plain data table (who.html) -------------------------------
   The seven incarnations. Tables are the one thing allowed to be wider than
   the page, so the wrapper scrolls sideways on a phone rather than forcing
   the whole body to. */
.tablewrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.tbl { border-collapse: collapse; width: 100%; min-width: 34rem; font-size: .95rem; }
.tbl th, .tbl td { text-align: left; vertical-align: top; padding: .85rem 1rem .85rem 0; border-bottom: 1px solid var(--rule); }
.tbl thead th { font-family: var(--f-body); font-size: .7rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--tx-faint); border-bottom-color: var(--tx-faint); }
.tbl td:first-child { font-family: var(--f-display); color: var(--red); white-space: nowrap; }
.tbl td:nth-child(3) { white-space: nowrap; color: var(--tx-soft); }
.tbl td:last-child { color: var(--tx-soft); line-height: 1.55; min-width: 18rem; }
.tbl em { font-style: normal; font-size: .82rem; color: var(--tx-faint); }
.cyr { font-weight: 600; }
