/* Book pages: reading polish on top of the book renderer's markup. Uses the
   site plugin's --rd-* tokens, with fallbacks. The renderer styles inline, so
   a few rules need !important to win. */

/* Toolbar: search, count, open/close all */
.rd73-poem-tools{display:flex;flex-wrap:wrap;align-items:center;gap:.6rem 1rem;margin:0 0 1.2rem;padding:.9rem 0;border-bottom:1px solid #262626;position:sticky;top:0;z-index:5;background:var(--rd-bg,#0a0a0a)}
.admin-bar .rd73-poem-tools{top:32px}
.rd73-poem-search{flex:1 1 260px;margin:0}
.rd73-poem-search input{width:100%;background:#111!important;color:var(--rd-text,#e8e8e8)!important;border:1px solid #333!important;border-radius:2px!important;padding:.65rem .9rem!important;font-family:var(--rd-body,Lora,serif);font-size:1rem;box-shadow:none!important;transition:border-color .2s}
.rd73-poem-search input:focus{border-color:var(--rd-gold,#d4a017)!important;outline:none}
.rd73-poem-search input::placeholder{color:#777;font-style:italic}
.rd73-poem-count{font-family:var(--rd-ui,Inter,sans-serif);font-size:.8rem;color:var(--rd-dim,#888);min-width:4.5em}
.rd73-poem-all{background:transparent!important;color:var(--rd-gold,#d4a017)!important;border:1px solid #4a3a10!important;border-radius:2px!important;box-shadow:none!important;font-family:var(--rd-head,Cinzel,serif)!important;font-size:.75rem;letter-spacing:.12em;text-transform:uppercase;padding:.5rem .9rem!important;cursor:pointer;transition:border-color .2s,background .2s}
.rd73-poem-all:hover{border-color:var(--rd-gold,#d4a017)!important;background:rgba(212,160,23,.08)!important}
.rd73-poem-none{color:var(--rd-dim,#888);font-style:italic;text-align:center;padding:2rem 0}

/* Poem titles */
.rd73-poem>summary{font-family:var(--rd-head,Cinzel,serif);font-weight:600!important;letter-spacing:.04em;font-size:1.02rem;transition:color .2s,text-shadow .2s}
.rd73-poem>summary::-webkit-details-marker{display:none}
.rd73-poem>summary:hover,.rd73-poem>summary:focus-visible{color:#f0c040!important;text-shadow:0 0 12px rgba(212,160,23,.35);outline:none}
.rd73-poem>summary>span:last-child{transition:transform .25s;display:inline-block}
.rd73-poem[open]>summary>span:last-child{transform:rotate(180deg)}
.rd73-poem{scroll-margin-top:110px}

/* Poem text */
.rd73-poem-body{font-family:var(--rd-body,Lora,serif);font-size:1.06rem;line-height:1.85;color:#e6dfcf;max-width:40em}
/* The renderer nests two .poem-content boxes; keep only the outer frame. */
.rd73-poem>.poem-content>.rd73-poem-body{background:none!important;border:0!important;padding:0!important;margin:0!important;box-shadow:none!important}
.rd73-poem-body p{margin:0 0 1.3em}
.rd73-poem-body .rd73-poem-head{font-family:var(--rd-head,Cinzel,serif);font-size:.86rem;letter-spacing:.14em;text-transform:uppercase;color:#b89c58;line-height:1.6;margin-bottom:1.6em}
.rd73-poem-body .rd73-poem-open::first-letter{font-family:var(--rd-head,Cinzel,serif);color:var(--rd-gold,#d4a017);float:left;font-size:3.2em;line-height:.82;margin:.08em .12em 0 0;text-shadow:0 0 18px rgba(212,160,23,.25)}
.rd73-poem-link{display:inline-block;margin-top:.4em;font-family:var(--rd-ui,Inter,sans-serif);font-size:.75rem;letter-spacing:.06em;color:var(--rd-dim,#888)!important;text-decoration:none!important;border-bottom:1px dotted #555}
.rd73-poem-link:hover{color:var(--rd-gold,#d4a017)!important;border-bottom-color:var(--rd-gold,#d4a017)}

@media (max-width:767px){
  .rd73-poem-tools{position:static}
  .rd73-poem-body{font-size:1rem;line-height:1.75}
  .rd73-poem>.poem-content{padding:1.1rem!important}
}
@media (prefers-reduced-motion:reduce){
  .rd73-poem>summary,.rd73-poem>summary>span:last-child{transition:none}
}
