/* Alfabeto e páginas de estudo: fonte hebraica local e navegação nativa. */
.he-alphabet {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: .85rem;
  list-style: none;
  padding: 0;
  margin: 1.7rem 0 0;
}
.he-alphabet > li { min-width: 0; margin: 0; padding: 0; }
.he-letter-link {
  display: grid;
  place-items: center;
  min-height: 132px;
  padding: .65rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--he-panel);
  color: var(--gold-soft);
  scroll-margin-top: 110px;
  transition: border-color .18s ease, background-color .18s ease;
}
.he-letter-link .he-text { font-size: 4.25rem; line-height: 1.65; }
.he-letter-link:hover,
.he-letter-link:focus-visible {
  border-color: var(--gold-soft);
  background: rgba(184,154,90,.12);
}
.he-letter-page .he-shell { max-width: 1120px; }
.he-letter-hero {
  display: grid;
  grid-template-columns: minmax(230px, .8fr) minmax(0, 1.4fr);
  gap: clamp(1.7rem, 4vw, 3.5rem);
  align-items: center;
  padding: 1.2rem 0 2.8rem;
}
.he-letter-portrait {
  display: grid;
  place-content: center;
  text-align: center;
  margin: 0;
  padding: 1rem 1.5rem 1.3rem;
  min-height: 300px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: radial-gradient(circle at center, rgba(184,154,90,.09), transparent 72%), var(--he-panel);
}
.he-letter-drawing {
  display: block;
  font-size: clamp(9rem, 17vw, 13rem);
  line-height: 1.45;
  color: var(--gold-soft);
}
.he-letter-portrait figcaption { font-size: .7rem; letter-spacing: .12em; color: var(--text-soft); }
.he-letter-identity { min-width: 0; }
.he-letter-identity .overline { font-size: .68rem; letter-spacing: .14em; }
.he-letter-identity h1 { font-size: clamp(3rem, 6vw, 4.6rem); line-height: 1.1; margin: .5rem 0 1.2rem; }
.he-name-caption { font-size: .72rem; color: var(--text-soft); margin: 0; }
.he-name-hebrew { margin: -.15rem 0 .6rem; }
.he-name-hebrew .he-text { font-size: 2.6rem; color: var(--gold-soft); }
.he-letter-lead { color: var(--text-soft); margin: 0 0 1rem; max-width: 42rem; }
.he-inline-link { color: var(--gold-soft); text-decoration: underline; text-underline-offset: .22em; text-decoration-color: rgba(211,188,133,.45); }
.he-inline-link:hover { text-decoration-color: currentColor; }
.he-letter-identity > .he-inline-link { font-size: .82rem; }
.he-letter-facts {
  display: grid;
  grid-template-columns: 1fr 1fr 1.6fr 1fr;
  margin: 0 0 3rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  background: rgba(184,154,90,.035);
}
.he-letter-facts > div { padding: 1.2rem 1.3rem; min-width: 0; }
.he-letter-facts > div + div { border-left: 1px solid var(--line); }
.he-letter-facts dt { font-size: .72rem; color: var(--text-soft); }
.he-letter-facts dd { margin: .5rem 0 0; color: var(--text); font-size: 2.2rem; line-height: 1.2; }
.he-letter-facts dd small { display: block; margin-top: .5rem; color: var(--text-soft); font-size: .68rem; line-height: 1.5; }
.he-letter-facts .he-value-fact dd { color: var(--gold-soft); }
.he-letter-facts dd.he-fact-sound { font-size: .96rem; line-height: 1.6; margin-top: .65rem; }
.he-letter-facts .he-text { font-size: 2.6rem; line-height: 1.25; }
.he-no-final { font-size: .9rem; }
.he-letter-content .he-section { margin-bottom: 2.7rem; padding-top: 1.5rem; border-top: 1px solid var(--line); }
.he-letter-content .he-section > .overline { font-size: .66rem; }
.he-letter-content .he-box p { font-size: .91rem; }
.he-letter-variants { display: flex; flex-wrap: wrap; gap: .8rem; margin: .7rem 0 1rem; }
.he-letter-variants > div { flex: 1; min-width: 85px; text-align: center; padding: .5rem .7rem; border: 1px solid var(--line); border-radius: 10px; }
.he-letter-variants .he-text { display: block; font-size: 3rem; line-height: 1.7; color: var(--gold-soft); }
.he-letter-variants strong { display: block; font-size: .78rem; }
.he-letter-variants small { display: block; font-size: .75rem; line-height: 1.6; color: var(--text-soft); }
.he-reading-units { display: flex; flex-wrap: wrap; gap: 1rem; margin: 1.5rem 0; }
.he-reading-unit { min-width: 130px; padding: .8rem 1.5rem; border: 1px solid var(--line); border-radius: 14px; background: var(--he-panel); text-align: center; }
.he-reading-unit .he-text { display: block; color: var(--gold-soft); font-size: 3.5rem; line-height: 1.8; }
.he-reading-unit strong { font-size: .85rem; }
.he-letter-words { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.2rem; margin: 1.5rem 0; }
.he-word-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; padding: .3rem 0 .6rem; }
.he-word-pair > div { min-width: 0; }
.he-word-pair small { display: block; font-size: .68rem; color: var(--text-soft); }
.he-letter-words .he-word .he-text { font-size: clamp(1.7rem, 3.6vw, 2.6rem); }
.he-gematria-box { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 1.5rem; align-items: center; margin: 1.4rem 0; }
.he-gematria-value { text-align: center; padding: 1rem; border: 1px solid var(--line); border-radius: 14px; background: rgba(184,154,90,.055); }
.he-gematria-value > span { display: block; font-size: 3.4rem; line-height: 1.3; color: var(--gold-soft); }
.he-gematria-value small { font-size: .75rem; color: var(--text-soft); }
.he-gematria-value .he-text { font-size: 1.7rem; }
.he-gematria-example { padding: 1.4rem; border: 1px solid var(--line); border-radius: 14px; background: var(--he-panel); text-align: center; }
.he-gematria-example h3 { margin: 0; }
.he-gematria-example > p { margin: .4rem 0; font-size: .85rem; }
.he-value-letters { display: flex; gap: .7rem; flex-wrap: wrap; justify-content: center; list-style: none; padding: 0; margin: 1rem 0; }
.he-value-letters li { display: flex; flex-direction: column; min-width: 65px; border: 1px solid var(--line); border-radius: 9px; padding: .25rem .7rem .5rem; }
.he-value-letters .he-text { font-size: 2.5rem; color: var(--gold-soft); }
.he-value-letters li > span { font-size: .8rem; }
.he-gematria-example .he-equation { font-size: 1.25rem; letter-spacing: .06em; }
.he-gematria-example .he-equation strong { color: var(--gold-soft); }
.he-letter-practice { display: grid; grid-template-columns: 1fr 1fr; gap: 1.8rem; align-items: start; }
.he-download-card { padding: 1.5rem; border: 1px solid var(--line); border-radius: 14px; background: rgba(184,154,90,.06); }
.he-download-card .overline { font-size: .65rem; margin: 0; }
.he-download-card h3 { margin-top: .45rem; }
.he-download-card > p:not(.overline) { font-size: .88rem; }
.he-download-card .button { display: flex; flex-direction: column; align-items: center; text-align: center; width: 100%; padding: .8rem 1rem; font-size: .85rem; line-height: 1.5; white-space: normal; }
.he-download-card > .he-inline-link { display: block; font-size: .8rem; margin-top: .9rem; text-align: center; }
.he-new-tab { font-size: .68rem; font-weight: 400; }
.he-letter-pagination { display: grid; grid-template-columns: 1fr auto 1fr; align-items: stretch; gap: .8rem; border-top: 1px solid var(--line); padding-top: 1.5rem; }
.he-letter-pagination > a { padding: .8rem 1rem; min-width: 0; border: 1px solid var(--line); border-radius: 12px; }
.he-letter-pagination > a:hover { border-color: var(--gold-soft); background: rgba(184,154,90,.05); }
.he-letter-pagination a small { display: block; font-size: .7rem; color: var(--text-soft); }
.he-letter-pagination a span { color: var(--gold-soft); font-size: .85rem; }
.he-letter-pagination .he-text { font-size: 1.8rem; vertical-align: middle; margin-right: .35rem; }
.he-letter-pagination [rel="next"] { text-align: right; }
.he-letter-pagination .he-alphabet-back { display: flex; align-items: center; justify-content: center; font-size: .78rem; color: var(--gold-soft); }
@media (max-width: 850px) {
  .he-alphabet { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .he-letter-link { min-height: 115px; }
  .he-letter-link .he-text { font-size: 3.6rem; }
  .he-letter-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .he-letter-facts > div:nth-child(3) { border-left: 0; }
  .he-letter-facts > div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .he-letter-hero { grid-template-columns: minmax(180px, .7fr) minmax(0, 1.3fr); gap: 1.5rem; }
  .he-letter-portrait { min-height: 255px; padding: .7rem 1rem; }
}
@media (max-width: 600px) {
  .he-alphabet { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .55rem; }
  .he-letter-link { min-height: 86px; padding: .35rem; border-radius: 10px; }
  .he-letter-link .he-text { font-size: 3rem; }
  .he-letter-hero { grid-template-columns: 1fr; gap: 1.3rem; padding-top: .9rem; padding-bottom: 1.8rem; }
  .he-letter-portrait { min-height: 0; width: 100%; max-width: 270px; justify-self: center; }
  .he-letter-drawing { font-size: 9.5rem; line-height: 1.45; }
  .he-letter-identity { text-align: center; }
  .he-letter-identity h1 { font-size: 3.1rem; }
  .he-letter-facts { margin-bottom: 1.8rem; }
  .he-letter-facts > div { padding: 1rem; }
  .he-letter-words, .he-letter-practice { grid-template-columns: 1fr; gap: 1rem; }
  .he-letter-words .he-word .he-text { font-size: 2.6rem; }
  .he-gematria-box { grid-template-columns: 1fr; gap: .75rem; }
  .he-gematria-value { max-width: 180px; justify-self: center; width: 100%; }
  .he-reading-unit { flex: 1; min-width: 110px; padding: .6rem 1rem; }
  .he-letter-pagination { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
  .he-letter-pagination .he-alphabet-back { grid-column: 1 / -1; grid-row: 2; }
  .he-letter-pagination > a { padding: .7rem; }
  .he-letter-pagination [rel="next"] { grid-column: 2; grid-row: 1; }
}
@media (max-width: 360px) {
  .he-alphabet { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .he-letter-words .he-word .he-text { font-size: 2.25rem; }
}
@media (prefers-reduced-motion: reduce) {
  .he-letter-link { transition: none; }
}
