/* ==========================================================================
   Hinários — estante, lista de hinos, leitura da letra e projeção
   ========================================================================== */
.hn-section { padding-top: 48px; }
.hn-wrap { width: min(920px, 92%); margin: 0 auto; }
mark { background: #cfe0ff; color: #0b1a3d; padding: 0 2px; border-radius: 4px; }

.hn-back { display: inline-flex; align-items: center; gap: 9px; margin-bottom: 20px; color: rgba(255, 255, 255, .75); font: 500 13.5px "Inter", sans-serif; text-decoration: none; }
.hn-back:hover { color: #fff; }

/* estante de hinários */
.hn-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.hn-head h2 { margin: 0; font: 500 22px "Manrope", sans-serif; letter-spacing: -.02em; color: #0b1a3d; }
.hn-shelf { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 460px), 1fr)); gap: 22px; }
.hn-book { display: flex; gap: 22px; padding: 22px; border-radius: 28px; background: #fff; border: 1px solid #dfe8fa; transition: transform .45s var(--tx-ease, ease), border-color .35s, box-shadow .35s; }
.hn-book:hover { transform: translateY(-5px); border-color: rgba(0, 87, 229, .45); box-shadow: 0 24px 56px rgba(0, 87, 229, .13); }
.hn-cover { position: relative; flex: none; width: 150px; aspect-ratio: 3 / 4; border-radius: 12px; overflow: hidden; background: linear-gradient(135deg, #0a3fb8, #2f7bff); box-shadow: 0 16px 34px rgba(0, 60, 170, .28); }
.hn-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hn-book-body { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.hn-book-body h3 { margin: 0 0 8px; font: 600 21px/1.25 "Manrope", sans-serif; letter-spacing: -.02em; }
.hn-book-body h3 a { color: #0b1a3d; text-decoration: none; }
.hn-book-body h3 a:hover { color: #0057e5; }
.hn-book-body p { margin: 0 0 12px; color: #4f5d7d; font-size: 14.5px; font-weight: 300; line-height: 1.65; }
.hn-book-body .bib-actions { margin-top: auto; }

/* resultados da pesquisa */
.hn-results { display: grid; gap: 12px; }
.hn-result { display: flex; align-items: center; gap: 18px; padding: 18px 22px; border-radius: 22px; background: #fff; border: 1px solid #dfe8fa; text-decoration: none; color: #0b1a3d; transition: transform .35s var(--tx-ease, ease), border-color .3s, box-shadow .3s; }
.hn-result:hover { transform: translateX(6px); border-color: #0057e5; box-shadow: 0 18px 44px rgba(0, 87, 229, .12); }
.hn-result-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1; }
.hn-result-main strong { font: 600 17px "Manrope", sans-serif; letter-spacing: -.01em; }
.hn-result-main small { color: #5b6b8a; font-size: 13.5px; line-height: 1.5; }
.hn-result-main em { font: 600 11px "Inter", sans-serif; letter-spacing: .12em; text-transform: uppercase; font-style: normal; color: #0057e5; }
.hn-result > i { color: #0057e5; opacity: 0; transition: opacity .3s; }
.hn-result:hover > i { opacity: 1; }
.hn-num { flex: none; min-width: 52px; height: 52px; padding: 0 10px; display: grid; place-items: center; border-radius: 16px; background: linear-gradient(135deg, #2f7bff, #0057e5); color: #fff; font: 700 18px "Manrope", sans-serif; box-shadow: 0 10px 22px rgba(0, 87, 229, .25); }

/* lista de hinos de um hinário */
.hn-hero-row { display: flex; align-items: flex-end; gap: 30px; flex-wrap: wrap; }
.hn-hero-cover { width: 130px; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 12px; box-shadow: 0 24px 50px rgba(2, 10, 40, .5); transform: rotate(-3deg); }
.hn-hero-actions { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 22px; }
.hn-count { color: rgba(255, 255, 255, .8); font: 400 14px "Inter", sans-serif; }
.hn-count i { color: #8fb8ff; margin-right: 6px; }
.hn-toolbar { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 26px; }
.hn-filter { position: relative; flex: 1 1 260px; }
.hn-filter i { position: absolute; left: 18px; top: 50%; transform: translateY(-50%); color: #0057e5; }
.hn-filter input { width: 100%; padding: 14px 18px 14px 46px !important; border-radius: 999px !important; background: #fff !important; }
.hn-deep { display: flex; gap: 10px; align-items: center; flex: 1 1 340px; flex-wrap: wrap; }
.hn-deep input[type="search"] { flex: 1; min-width: 160px; padding: 14px 18px !important; border-radius: 999px !important; background: #fff !important; }
.hn-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; }
.hn-tile { display: flex; align-items: center; gap: 14px; padding: 14px 18px 14px 14px; border-radius: 20px; background: #fff; border: 1px solid #dfe8fa; text-decoration: none; color: #0b1a3d; transition: transform .3s var(--tx-ease, ease), border-color .3s, box-shadow .3s, background .3s; }
.hn-tile[hidden] { display: none; }
.hn-tile .hn-num { min-width: 46px; height: 46px; font-size: 16px; border-radius: 14px; box-shadow: none; }
.hn-tile-t { font: 500 15px/1.35 "Manrope", sans-serif; }
.hn-tile:hover { transform: translateY(-3px); border-color: #0057e5; box-shadow: 0 16px 36px rgba(0, 87, 229, .13); }
.hn-none { text-align: center; color: #5b6b8a; padding: 30px 0; }

/* um hino */
.hn-hino-hero { padding: 130px 0 44px; color: #fff; background: radial-gradient(ellipse 55% 90% at 88% 0%, rgba(47, 123, 255, .5), transparent 62%), linear-gradient(120deg, #061746, #0a2a85); }
.hn-hino-title { display: flex; align-items: center; gap: 22px; }
.hn-bignum { flex: none; min-width: 88px; height: 88px; padding: 0 14px; display: grid; place-items: center; border-radius: 26px; background: #fff; color: #0057e5; font: 700 36px "Manrope", sans-serif; box-shadow: 0 20px 44px rgba(2, 10, 40, .35); }
.hn-hino-title h1 { margin: 0; font: 300 clamp(26px, 3.6vw, 46px)/1.12 "Manrope", sans-serif; letter-spacing: -.04em; color: #fff; }
.hn-reader-sec { padding: 36px 0 90px; background: #f4f8ff; }
.hn-tools { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; margin-bottom: 16px; }
.hn-tools button { display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 999px; background: #fff; border: 1px solid #dfe8fa; color: #34456b; font: 600 13px "Inter", sans-serif; cursor: pointer; transition: all .25s; }
.hn-tools button:hover { background: #0057e5; border-color: #0057e5; color: #fff; }
.hn-tools .hn-project-btn { background: #0057e5; border-color: #0057e5; color: #fff; }
.hn-tools .hn-project-btn:hover { background: #0048c0; }
.hn-lyrics { --hn-fs: 1; padding: 36px clamp(22px, 5vw, 56px); border-radius: 30px; background: #fff; border: 1px solid #dfe8fa; display: grid; gap: 26px; }
.hn-stanza { position: relative; padding-left: 52px; }
.hn-st-n { position: absolute; left: 0; top: 2px; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; background: #eef4ff; color: #0057e5; font: 700 14px "Manrope", sans-serif; }
.hn-stanza p { margin: 0; font: 400 calc(1.2rem * var(--hn-fs))/1.95 "Fraunces", Georgia, serif; font-style: normal; color: #1f2a44; }
.hn-empty { margin: 0; color: #5b6b8a; text-align: center; }
.hn-pager { display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin-top: 28px; }
.hn-pg { text-align: left; }
.hn-pg span { display: flex; flex-direction: column; line-height: 1.25; }
.hn-pg small { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; opacity: .75; }
.hn-reader-sec .bib-btn-g { border-color: #cfe0ff; color: #0057e5; }
.hn-reader-sec .bib-btn-g:hover { background: #0057e5; border-color: #0057e5; color: #fff; }

/* projeção */
.hn-proj { position: fixed; inset: 0; z-index: 10200; display: flex; flex-direction: column; background: #030b26; color: #fff; font-family: "Inter", sans-serif; }
.hn-proj[hidden] { display: none; }
.hn-proj header, .hn-proj footer { flex: none; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 18px; color: rgba(255, 255, 255, .7); font-size: 14px; }
.hn-proj header div { display: flex; gap: 8px; }
.hn-proj button { width: 46px; height: 46px; border: 0; border-radius: 14px; background: rgba(255, 255, 255, .1); color: #fff; cursor: pointer; font-size: 16px; transition: background .25s, color .25s; }
.hn-proj button:hover { background: #fff; color: #0057e5; }
.hn-proj footer { justify-content: center; gap: 22px; }
.hn-proj-body { flex: 1; display: grid; place-items: center; padding: 2vmin 6vw; cursor: pointer; overflow: auto; }
.hn-proj-body p { margin: 0; max-width: 1400px; text-align: center; font: 500 4vmin/1.5 "Manrope", sans-serif; letter-spacing: -.01em; white-space: pre-line; }

@media (max-width: 640px) {
  .hn-book { flex-direction: column; align-items: flex-start; }
  .hn-cover { width: 130px; }
  .hn-hino-hero { padding: 112px 0 32px; }
  .hn-bignum { min-width: 66px; height: 66px; font-size: 28px; border-radius: 20px; }
  .hn-hino-title { gap: 14px; }
  .hn-stanza { padding-left: 0; padding-top: 44px; }
  .hn-tools button span { display: none; }
  .hn-tools .hn-project-btn span { display: inline; }
  .hn-pg { width: 100%; justify-content: center; }
}
@media print {
  .header, .tx-footer, .scroll-top, .tx-consent, .hn-tools, .hn-pager, .hn-back, .hn-proj { display: none !important; }
  .hn-hino-hero { padding: 0 0 10px; background: none !important; color: #000; }
  .hn-hino-title h1 { color: #000 !important; font-size: 22pt; }
  .hn-bignum { box-shadow: none; border: 2px solid #000; color: #000; }
  .hn-reader-sec { background: #fff; padding: 0; }
  .hn-lyrics { border: 0; padding: 0; }
  .hn-stanza p { color: #000; font-size: 14pt; }
}

/* ==========================================================================
   Leitor de hinos tipo aplicação: botões flutuantes, teclado, pesquisa, modo escuro
   ========================================================================== */
.hn-fab { position: fixed; z-index: 9980; right: 18px; bottom: 22px; width: 62px; height: 62px; border: 0; border-radius: 50%; display: grid; place-items: center; cursor: pointer; background: linear-gradient(135deg, #2f7bff, #0057e5); color: #fff; font-size: 24px; box-shadow: 0 16px 36px rgba(0, 87, 229, .45); transition: transform .3s, box-shadow .3s; }
.hn-fab:hover { transform: translateY(-3px) scale(1.04); box-shadow: 0 20px 44px rgba(0, 87, 229, .55); }
.hn-fab-s { bottom: 96px; width: 50px; height: 50px; font-size: 18px; background: #fff; color: #0057e5; box-shadow: 0 12px 28px rgba(2, 10, 40, .22); }
.hn-page .scroll-top { bottom: 170px; }
.hn-page .tx-consent { z-index: 9970; }

.hn-modal { position: fixed; inset: 0; z-index: 10300; display: grid; place-items: center; padding: 16px; background: rgba(2, 8, 30, .66); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); animation: hnFade .25s both; }
.hn-modal[hidden] { display: none; }
.hn-modal-top { align-items: start; padding-top: max(16px, 8vh); }
@keyframes hnFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes hnPop { from { opacity: 0; transform: translateY(14px) scale(.97); } to { opacity: 1; transform: none; } }
.hn-modal-card { width: min(100%, 420px); border-radius: 28px; background: #0c1d55; color: #fff; border: 1px solid rgba(255, 255, 255, .14); box-shadow: 0 40px 90px rgba(0, 0, 0, .55); animation: hnPop .3s var(--tx-ease, ease) both; font-family: "Inter", sans-serif; }

/* teclado numérico */
.hn-keypad { padding: 22px 22px 26px; }
.hn-keypad header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.hn-keypad h2 { margin: 0; font: 500 18px "Manrope", sans-serif; letter-spacing: -.01em; color: #fff; }
.hn-keypad header button { width: 38px; height: 38px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .1); color: #fff; cursor: pointer; }
.hn-kp-display { padding: 14px 8px 18px; text-align: center; min-height: 104px; }
.hn-kp-display strong { display: block; font: 300 56px/1.1 "Manrope", sans-serif; letter-spacing: .04em; color: #fff; }
.hn-kp-display strong.is-bad { color: #ff9b9b; }
.hn-kp-display strong.is-shake { animation: hnShake .4s; }
@keyframes hnShake { 20%, 60% { transform: translateX(-8px); } 40%, 80% { transform: translateX(8px); } }
.hn-kp-display small { display: block; margin-top: 6px; min-height: 20px; font-size: 14px; color: #a9c9ff; }
.hn-kp-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; justify-items: center; }
.hn-kp-grid button { width: 74px; height: 74px; border-radius: 50%; border: 1.5px solid rgba(255, 255, 255, .35); background: transparent; color: #fff; font: 400 28px "Manrope", sans-serif; cursor: pointer; transition: background .2s, transform .15s, border-color .2s; }
.hn-kp-grid button:hover { background: rgba(255, 255, 255, .12); }
.hn-kp-grid button:active { transform: scale(.92); background: rgba(255, 255, 255, .2); }
.hn-kp-grid .hn-kp-x { border-color: rgba(255, 140, 140, .6); color: #ff9b9b; font-size: 22px; }
.hn-kp-grid .hn-kp-ok { border-color: #5ad1c5; color: #5ad1c5; font-size: 24px; }
.hn-kp-grid .hn-kp-ok:hover { background: #5ad1c5; color: #0c1d55; }

/* pesquisa */
.hn-search-card { width: min(100%, 640px); overflow: hidden; }
.hn-search-bar { display: flex; align-items: center; gap: 12px; padding: 16px 18px; border-bottom: 1px solid rgba(255, 255, 255, .12); }
.hn-search-bar > i { color: #8fb8ff; }
.hn-search-bar input { flex: 1; min-width: 0; border: 0 !important; outline: 0 !important; box-shadow: none !important; background: transparent !important; color: #fff !important; font: 400 17px "Inter", sans-serif !important; padding: 8px 0 !important; border-radius: 0 !important; }
.hn-search-bar input::placeholder { color: rgba(255, 255, 255, .5); }
.hn-search-bar button { width: 38px; height: 38px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .1); color: #fff; cursor: pointer; }
.hn-s-list { max-height: min(62vh, 520px); overflow: auto; padding: 8px; }
.hn-s-hint { margin: 0; padding: 26px 16px; text-align: center; color: rgba(255, 255, 255, .6); font-size: 14.5px; }
.hn-s-item { display: flex; align-items: center; gap: 14px; padding: 12px 12px; border-radius: 16px; color: #fff; text-decoration: none; transition: background .2s; }
.hn-s-item:hover, .hn-s-item:focus { background: rgba(255, 255, 255, .1); outline: 0; }
.hn-s-item .hn-num { min-width: 46px; height: 46px; font-size: 15px; border-radius: 14px; box-shadow: none; }
.hn-s-item strong { display: block; font: 600 15.5px "Manrope", sans-serif; letter-spacing: -.01em; }
.hn-s-item small { display: block; margin-top: 2px; color: rgba(255, 255, 255, .62); font-size: 13px; line-height: 1.45; }
.hn-s-item mark { background: rgba(143, 184, 255, .35); color: #fff; }

/* modo escuro na leitura */
.hn-dark .hn-reader-sec { background: #060f33; }
.hn-dark .hn-lyrics { background: #0b1a4d; border-color: rgba(255, 255, 255, .1); }
.hn-dark .hn-stanza p { color: #eef3ff; }
.hn-dark .hn-st-n { background: rgba(255, 255, 255, .1); color: #8fb8ff; }
.hn-dark .hn-tools button:not(.hn-project-btn) { background: #0b1a4d; border-color: rgba(255, 255, 255, .14); color: #dbe7ff; }
.hn-dark .hn-tools button:not(.hn-project-btn):hover { background: #fff; color: #0057e5; }
.hn-dark .hn-reader-sec .bib-btn-g { border-color: rgba(255, 255, 255, .3); color: #fff; }
.hn-dark .hn-empty { color: #a9c9ff; }

@media (max-width: 575px) {
  .hn-fab { right: 14px; bottom: 16px; width: 58px; height: 58px; }
  .hn-fab-s { bottom: 84px; }
  .hn-kp-grid button { width: 68px; height: 68px; font-size: 26px; }
  .hn-modal:not(.hn-modal-top) { align-items: end; padding: 0; }
  .hn-modal:not(.hn-modal-top) .hn-modal-card { width: 100%; border-radius: 28px 28px 0 0; }
}
@media print { .hn-fab, .hn-modal { display: none !important; } }

/* campo de pesquisa do leitor: vence os estilos globais de formulários */
main .hn-search-bar input[type="search"] { background: transparent !important; color: #fff !important; border: 0 !important; box-shadow: none !important; border-radius: 0 !important; padding: 8px 0 !important; font: 400 17px "Inter", sans-serif !important; -webkit-appearance: none; }
main .hn-search-bar input[type="search"]::-webkit-search-cancel-button { display: none; }

/* ── coletâneas, idioma, refrão, favoritos e banner de projeção ── */
.hn-group-title { display: flex; align-items: center; gap: 14px; margin: 44px 0 20px; }
.hn-group-title:first-of-type { margin-top: 8px; }
.hn-group-title i { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 13px; background: #0057e5; color: #fff; }
.hn-group-title h2 { margin: 0; font: 500 26px "Manrope", sans-serif; letter-spacing: -.03em; color: #0b1a3d; }
.hn-group-title span { padding: 4px 12px; border-radius: 999px; background: #e7f0ff; color: #0057e5; font: 700 13px "Inter", sans-serif; }
.hn-book.is-col .hn-cover { background: linear-gradient(135deg, #061746, #0057e5); }
.hn-lang { display: inline-flex; align-items: center; gap: 8px; margin-top: 10px; padding: 6px 14px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .35); color: #fff; font: 600 12px "Inter", sans-serif; letter-spacing: .08em; text-transform: uppercase; }
.hn-stanza.is-chorus { padding: 22px 24px 22px 62px; margin-inline: -8px; border-radius: 22px; background: #eef4ff; border-left: 4px solid #0057e5; }
.hn-stanza.is-chorus .hn-st-n { left: 18px; top: 22px; background: #0057e5; color: #fff; font-size: 13px; }
.hn-stanza.is-chorus p { font-style: italic; font-weight: 500; }
.hn-chorus-l { display: block; margin-bottom: 6px; font: 700 11px "Inter", sans-serif; font-style: normal; letter-spacing: .16em; text-transform: uppercase; color: #0057e5; }
.hn-dark .hn-stanza.is-chorus { background: rgba(255, 255, 255, .07); border-left-color: #8fb8ff; }
.hn-dark .hn-chorus-l { color: #8fb8ff; }
.hn-tools a.hn-project-btn { display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 999px; background: #0057e5; border: 1px solid #0057e5; color: #fff; font: 600 13px "Inter", sans-serif; text-decoration: none; transition: background .25s; }
.hn-tools a.hn-project-btn:hover { background: #0048c0; color: #fff; }
.hn-tools button[aria-pressed="true"]#hn-fav { background: #fff0f3; border-color: #ffb3c2; color: #d6244f; }

.hn-proj-banner { display: flex; align-items: center; gap: 20px; margin: 0 0 34px; padding: 22px 26px; border-radius: 26px; color: #fff; text-decoration: none; position: relative; overflow: hidden; background: radial-gradient(ellipse 60% 120% at 100% 0%, rgba(143, 184, 255, .45), transparent 60%), linear-gradient(120deg, #061746, #0a3fb8 70%, #2f7bff); box-shadow: 0 24px 54px rgba(0, 60, 170, .25); transition: transform .4s var(--tx-ease, ease), box-shadow .4s; }
.hn-proj-banner:hover { transform: translateY(-4px); box-shadow: 0 30px 64px rgba(0, 60, 170, .35); color: #fff; }
.hn-proj-ico { flex: none; width: 60px; height: 60px; display: grid; place-items: center; border-radius: 18px; background: rgba(255, 255, 255, .16); font-size: 24px; }
.hn-proj-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.hn-proj-txt strong { font: 600 19px "Manrope", sans-serif; letter-spacing: -.02em; }
.hn-proj-txt small { color: rgba(255, 255, 255, .8); font-size: 14px; font-weight: 300; line-height: 1.55; }
.hn-proj-go { flex: none; display: inline-flex; align-items: center; gap: 8px; padding: 12px 22px; border-radius: 999px; background: #fff; color: #0057e5; font: 600 14px "Inter", sans-serif; }
.hn-favs { margin-bottom: 36px; padding: 24px; border-radius: 26px; background: #fff; border: 1px solid #dfe8fa; }
.hn-favs[hidden] { display: none; }
.hn-favs .hn-head h2 i { color: #d6244f; margin-right: 8px; }
.hn-fav-row { display: flex; gap: 12px; overflow-x: auto; padding: 4px 2px 8px; }
.hn-fav { flex: 0 0 min(260px, 78%); display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 18px; background: #f4f8ff; border: 1px solid #e3ecfb; text-decoration: none; color: #0b1a3d; }
.hn-fav:hover { border-color: #0057e5; }
.hn-fav .hn-num { min-width: 42px; height: 42px; font-size: 14px; border-radius: 13px; box-shadow: none; }
.hn-fav strong { display: block; font: 600 14.5px "Manrope", sans-serif; }
.hn-fav small { color: #5b6b8a; font-size: 12px; }
@media (max-width: 640px) { .hn-proj-banner { flex-wrap: wrap; } .hn-proj-go { width: 100%; justify-content: center; } }
.hn-tile-lang { display: inline-block; margin-left: 6px; padding: 2px 9px; border-radius: 999px; background: #e7f0ff; color: #0057e5; font: 700 10px "Inter", sans-serif; font-style: normal; letter-spacing: .08em; text-transform: uppercase; vertical-align: middle; }
.hn-app-banner { background: radial-gradient(ellipse 60% 120% at 100% 0%, rgba(90, 209, 197, .35), transparent 60%), linear-gradient(120deg, #061746, #0a3fb8 70%, #2f7bff); margin-top: -14px; }
.hn-app-banner .hn-proj-ico { background: rgba(255, 255, 255, .18); }
