/* Community Library page (library.php) */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- hero ---------- */
.lb-hero { position: relative; padding: 56px 0 96px; color: #fff; overflow: hidden; background:
  radial-gradient(720px 420px at 12% -10%, rgba(251, 191, 36, .18), transparent 70%),
  radial-gradient(640px 420px at 100% 100%, rgba(74, 222, 128, .14), transparent 70%),
  linear-gradient(155deg, var(--b900, #052e16), var(--b800, #14532d) 55%, var(--b700, #166534)); }
.lb-hero::after { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background-image: radial-gradient(rgba(255, 255, 255, .09) 1px, transparent 1px); background-size: 22px 22px; mask-image: linear-gradient(180deg, #000, transparent 85%); -webkit-mask-image: linear-gradient(180deg, #000, transparent 85%); }
.lb-hero-in { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 40px; align-items: center; }
.lb-hero-text { min-width: 0; display: grid; gap: 22px; justify-items: start; }
.lb-kicker { display: inline-flex; align-items: center; gap: 8px; margin: 0; padding: 7px 16px; border: 1px solid rgba(255, 255, 255, .25); border-radius: 999px; font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--o400, #fbbf24); background: rgba(255, 255, 255, .05); }
.lb-kicker .ico { width: 16px; height: 16px; }

.lb-plaque { position: relative; width: 100%; padding: 30px 30px 28px; border: 1px solid rgba(251, 191, 36, .45); border-radius: 22px; background: linear-gradient(160deg, rgba(255, 255, 255, .09), rgba(255, 255, 255, .03)); backdrop-filter: blur(4px); }
.lb-plaque::before { content: ""; position: absolute; inset: 8px; border: 1px solid rgba(251, 191, 36, .2); border-radius: 16px; pointer-events: none; }
.lb-ded { margin: 0 0 10px; font-size: .8rem; letter-spacing: .16em; text-transform: uppercase; color: rgba(255, 255, 255, .78); }
.lb-plaque h1 { margin: 0; font-family: Georgia, "Times New Roman", serif; font-weight: 700; font-size: clamp(1.7rem, 3.6vw, 2.75rem); line-height: 1.12; letter-spacing: .03em; text-transform: uppercase; color: #fff; text-wrap: balance; }
.lb-years { display: flex; align-items: center; gap: 12px; margin: 12px 0 0; font-family: Georgia, serif; font-size: 1.1rem; color: var(--o400, #fbbf24); }
.lb-years span { height: 1px; width: 44px; background: linear-gradient(90deg, transparent, rgba(251, 191, 36, .8)); }
.lb-years span:last-child { background: linear-gradient(90deg, rgba(251, 191, 36, .8), transparent); flex: 1; max-width: 160px; }
.lb-plaque blockquote, .lb-close blockquote { margin: 16px 0 0; padding: 0; border: 0; font-family: Georgia, "Times New Roman", serif; font-style: italic; font-size: clamp(1.02rem, 1.9vw, 1.22rem); line-height: 1.55; color: rgba(255, 255, 255, .92); text-wrap: balance; }

.lb-search { display: flex; align-items: center; gap: 8px; width: 100%; max-width: 560px; padding: 6px 6px 6px 16px; border-radius: 16px; background: #fff; box-shadow: 0 14px 34px rgba(0, 0, 0, .25); }
.lb-search > .ico { flex: none; width: 20px; height: 20px; color: #64748b; }
.lb-search input { flex: 1; min-width: 0; height: 46px; border: 0; background: transparent; font: inherit; color: #1c1917; outline: none; }
.lb-search:focus-within { outline: 3px solid var(--o400, #fbbf24); outline-offset: 2px; }
.lb-search .btn { flex: none; height: 46px; padding: 0 22px; justify-content: center; }

.lb-cta { display: flex; flex-wrap: wrap; gap: 10px; }
.lb-cta .btn { display: inline-flex; align-items: center; gap: 8px; }
.lb-cta .btn .ico { width: 18px; height: 18px; flex: none; }
.lb-cta-left { margin-top: 20px; }

/* fanned stack of real covers */
.lb-stack { position: relative; height: 360px; min-width: 0; }
.lb-stack img { position: absolute; left: 50%; top: 50%; width: 170px; height: 255px; object-fit: cover; border-radius: 5px 10px 10px 5px; background: #0f3a22; box-shadow: 0 18px 40px rgba(0, 0, 0, .45), inset 4px 0 0 rgba(255, 255, 255, .12); transition: transform .35s ease; }
.lb-stack-1 { transform: translate(-50%, -50%) rotate(0deg); z-index: 5; width: 190px !important; height: 285px !important; }
.lb-stack-2 { transform: translate(-112%, -46%) rotate(-9deg); z-index: 4; }
.lb-stack-3 { transform: translate(12%, -46%) rotate(9deg); z-index: 4; }
.lb-stack-4 { transform: translate(-160%, -38%) rotate(-17deg); z-index: 3; opacity: .92; }
.lb-stack-5 { transform: translate(60%, -38%) rotate(17deg); z-index: 3; opacity: .92; }
.lb-stack:hover .lb-stack-2 { transform: translate(-120%, -48%) rotate(-11deg); }
.lb-stack:hover .lb-stack-3 { transform: translate(20%, -48%) rotate(11deg); }
.lb-stack:hover .lb-stack-4 { transform: translate(-172%, -40%) rotate(-20deg); }
.lb-stack:hover .lb-stack-5 { transform: translate(72%, -40%) rotate(20deg); }

/* ---------- figures ---------- */
.lb-stats-sec { padding: 0; margin-top: -48px; position: relative; z-index: 2; }
.lb-stats { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.lb-stats li { display: flex; align-items: center; gap: 14px; padding: 18px; background: #fff; border: 1px solid #E3EAE5; border-radius: 20px; box-shadow: 0 12px 30px rgba(11, 74, 34, .09); min-width: 0; }
.lb-stat-ico { flex: none; width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; background: var(--b50, #f0fdf4); color: var(--b600, #15803d); }
.lb-stat-ico.is-gold { background: var(--o50, #fffbeb); color: var(--o600, #d97706); }
.lb-stat-ico .ico { width: 22px; height: 22px; }
.lb-stats div { min-width: 0; }
.lb-stats strong { display: block; font-size: clamp(1.5rem, 2.6vw, 2rem); line-height: 1.1; color: var(--b800, #14532d); font-variant-numeric: tabular-nums; }
.lb-stats div > span { display: block; font-size: .86rem; font-weight: 600; color: var(--s600, #57534e); line-height: 1.3; }

/* ---------- sections ---------- */
.lb-sec { padding: 60px 0; }
.lb-tint { background: var(--b50, #f0fdf4); }
.lb-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.lb-head h2 { margin: 6px 0 0; font-size: clamp(1.45rem, 2.8vw, 2rem); text-wrap: balance; }
.lb-head-center { justify-content: center; text-align: center; }
.lb-link { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; color: var(--b700, #166534); text-decoration: none; }
.lb-link .ico { width: 16px; height: 16px; }
.lb-link:hover { text-decoration: underline; }

/* covers strip */
.lb-shelf-sec { padding-bottom: 44px; }
.lb-shelf { list-style: none; margin: 0 -16px; padding: 6px 16px 18px; display: grid; grid-auto-flow: column; grid-auto-columns: 148px; gap: 18px; overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: thin; }
.lb-shelf li { scroll-snap-align: start; min-width: 0; }
.lb-shelf a { display: grid; gap: 4px; color: inherit; text-decoration: none; }
.lb-shelf img { width: 100%; height: auto; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 4px 9px 9px 4px; background: #eef2ef; box-shadow: 0 8px 18px rgba(15, 23, 42, .18); transition: transform .25s ease, box-shadow .25s ease; margin-bottom: 6px; }
.lb-shelf a:hover img, .lb-shelf a:focus-visible img { transform: translateY(-5px); box-shadow: 0 16px 28px rgba(15, 23, 42, .26); }
.lb-shelf strong { font-size: .9rem; line-height: 1.3; color: var(--s900, #1c1917); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.lb-shelf span { font-size: .8rem; color: var(--s500, #78716c); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* subjects */
.lb-subjects { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(215px, 1fr)); gap: 10px; }
.lb-subjects a { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 13px 16px; border-radius: 14px; background: #fff; border: 1px solid #DCE9E0; color: var(--s900, #1c1917); font-weight: 600; text-decoration: none; transition: border-color .2s, transform .2s, box-shadow .2s; }
.lb-subjects a:hover, .lb-subjects a:focus-visible { border-color: var(--b600, #15803d); transform: translateY(-2px); box-shadow: 0 8px 18px rgba(11, 74, 34, .1); }
.lb-subjects span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb-subjects b { flex: none; min-width: 34px; text-align: center; padding: 2px 9px; border-radius: 999px; background: var(--b100, #dcfce7); color: var(--b800, #14532d); font-size: .82rem; font-variant-numeric: tabular-nums; }

/* story */
.lb-story { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 44px; align-items: center; }
.lb-story-photo { position: relative; min-width: 0; }
.lb-story-photo::before { content: ""; position: absolute; inset: 18px -14px -14px 18px; border-radius: 26px; background: var(--o100, #fef3c7); z-index: 0; }
.lb-story-photo img, .lb-story-photo .ph { position: relative; z-index: 1; width: 100%; height: auto; display: block; border-radius: 22px; object-fit: cover; box-shadow: 0 16px 36px rgba(15, 23, 42, .16); }
.lb-story h2 { margin: 6px 0 14px; font-size: clamp(1.45rem, 2.8vw, 2rem); }
.lb-story p { color: var(--s700, #44403c); line-height: 1.75; margin: 0 0 14px; }

.lb-fac { list-style: none; margin: 0 0 14px; padding: 0; display: grid; gap: 10px; }
.lb-fac-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 18px; }
.lb-fac li { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: 14px; background: var(--s50, #fafaf9); border: 1px solid var(--s200, #e7e5e4); color: var(--s800, #292524); line-height: 1.5; min-width: 0; }
.lb-fac .ico { flex: none; width: 20px; height: 20px; margin-top: 2px; color: var(--b600, #15803d); }

/* steps */
.lb-dark { color: #fff; background: linear-gradient(160deg, var(--b900, #052e16), var(--b800, #14532d)); }
.lb-dark .eyebrow { color: var(--o400, #fbbf24); }
.lb-dark h2 { color: #fff; }
.lb-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; counter-reset: none; }
.lb-steps li { position: relative; padding: 26px 22px 22px; border-radius: 20px; border: 1px solid rgba(255, 255, 255, .16); background: rgba(255, 255, 255, .06); min-width: 0; }
.lb-steps li > span { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: var(--o400, #fbbf24); color: #3b2a00; font-weight: 800; font-size: 1.1rem; margin-bottom: 14px; }
.lb-steps h3 { margin: 0 0 6px; color: #fff; font-size: 1.15rem; }
.lb-steps p { margin: 0 0 14px; color: rgba(255, 255, 255, .8); line-height: 1.6; }
.lb-steps a { display: inline-flex; align-items: center; gap: 6px; color: var(--o400, #fbbf24); font-weight: 700; text-decoration: none; }
.lb-steps a:hover { text-decoration: underline; }
.lb-steps a .ico { width: 16px; height: 16px; }

/* hours and rules */
.lb-two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; align-items: stretch; }
.lb-card { min-width: 0; padding: 30px; background: #fff; border: 1px solid #E3EAE5; border-radius: 24px; box-shadow: 0 8px 24px rgba(11, 74, 34, .05); }
.lb-card h2 { margin: 4px 0 14px; font-size: clamp(1.35rem, 2.6vw, 1.75rem); text-wrap: balance; }
.lb-card p { margin: 0 0 14px; color: var(--s700, #44403c); line-height: 1.7; }
.lb-now { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 999px; font-weight: 700; font-size: .9rem; }
.lb-now i { width: 9px; height: 9px; border-radius: 50%; background: currentColor; }
.lb-now.is-open { background: #DCFCE7; color: #166534; }
.lb-now.is-closed { background: #F5F5F4; color: #57534E; }
.lb-hours { width: 100%; border-collapse: collapse; margin-bottom: 18px; }
.lb-hours th, .lb-hours td { padding: 13px 12px; border-bottom: 1px solid var(--s200, #e7e5e4); font-size: 1rem; }
.lb-hours th { text-align: left; font-weight: 600; color: var(--s800, #292524); }
.lb-hours td { text-align: right; font-weight: 700; color: var(--b800, #14532d); font-variant-numeric: tabular-nums; white-space: nowrap; }
.lb-hours tr.off td { color: var(--s500, #78716c); }
.lb-hours tr.today th, .lb-hours tr.today td { background: var(--b50, #f0fdf4); }
.lb-hours tr.today th { border-radius: 10px 0 0 10px; } .lb-hours tr.today td { border-radius: 0 10px 10px 0; }
.lb-hours em { font-style: normal; margin-left: 8px; padding: 1px 8px; border-radius: 999px; background: var(--b600, #15803d); color: #fff; font-size: .7rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; vertical-align: 2px; }
.lb-hours tr:last-child th, .lb-hours tr:last-child td { border-bottom: 0; }
.lb-addr { display: flex; gap: 10px; align-items: flex-start; margin: 0 !important; font-size: .95rem; }
.lb-addr .ico { flex: none; width: 20px; height: 20px; margin-top: 3px; color: var(--o600, #d97706); }
.lb-addr a { font-weight: 700; color: var(--b700, #166534); }
.lb-free { padding: 12px 16px; border-radius: 14px; background: var(--o50, #fffbeb); border: 1px solid var(--o100, #fef3c7); }
.lb-free strong { color: var(--o700, #b45309); }

/* closing dedication */
.lb-close { padding: 60px 0; text-align: center; color: #fff; background: var(--b900, #052e16); }
.lb-close-ico { display: inline-grid; place-items: center; width: 54px; height: 54px; border-radius: 50%; border: 1px solid rgba(251, 191, 36, .5); color: var(--o400, #fbbf24); margin-bottom: 14px; }
.lb-close-ico .ico { width: 24px; height: 24px; }
.lb-close-name { margin: 0; font-family: Georgia, serif; font-size: clamp(1.3rem, 3vw, 1.8rem); font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--o400, #fbbf24); }
.lb-close-addr { margin: 10px 0 0; color: rgba(255, 255, 255, .78); }
.lb-close-ded { margin: 18px 0 0; font-weight: 600; color: #fff; }
.lb-close p, .lb-close blockquote { max-width: 46em; margin-left: auto; margin-right: auto; }
.lb-close blockquote { margin-top: 10px; }

/* ---------- smaller screens ---------- */
@media (max-width: 1020px) {
  .lb-hero-in { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .lb-hero-text { justify-items: center; text-align: center; }
  .lb-years { justify-content: center; } .lb-years span:last-child { flex: none; width: 44px; }
  .lb-cta { justify-content: center; }
  .lb-stack { height: 250px; order: -1; margin-bottom: 4px; }
  .lb-stack img { width: 112px; height: 168px; }
  .lb-stack-1 { width: 128px !important; height: 192px !important; }
  .lb-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lb-story { grid-template-columns: minmax(0, 1fr); gap: 34px; }
  .lb-story-photo { max-width: 560px; }
}
@media (max-width: 860px) {
  .lb-two, .lb-steps { grid-template-columns: minmax(0, 1fr); }
  .lb-card { padding: 24px 20px; }
  .lb-cta-left { justify-content: flex-start; }
}
@media (max-width: 560px) {
  .lb-hero { padding: 36px 0 76px; }
  .lb-plaque { padding: 24px 18px 22px; }
  .lb-stack { height: 200px; }
  .lb-stack img { width: 92px; height: 138px; }
  .lb-stack-1 { width: 104px !important; height: 156px !important; }
  .lb-stack-4, .lb-stack-5 { display: none; }
  .lb-search { padding: 5px 5px 5px 12px; }
  .lb-search .btn { padding: 0 16px; }
  .lb-cta .btn { width: 100%; justify-content: center; }
  .lb-stats { gap: 8px; }
  .lb-stats li { padding: 12px; gap: 10px; border-radius: 16px; flex-direction: column; align-items: flex-start; }
  .lb-stat-ico { width: 38px; height: 38px; border-radius: 12px; }
  .lb-sec { padding: 44px 0; }
  .lb-shelf { grid-auto-columns: 124px; gap: 14px; }
  .lb-subjects { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lb-subjects a { padding: 11px 12px; font-size: .9rem; }
  .lb-fac-2 { grid-template-columns: minmax(0, 1fr); }
  .lb-hours th, .lb-hours td { padding: 12px 8px; font-size: .95rem; }
  .lb-hours td { white-space: normal; }
}
@media (max-width: 380px) { .lb-subjects { grid-template-columns: minmax(0, 1fr); } }
@media (prefers-reduced-motion: reduce) { .lb-stack img, .lb-shelf img, .lb-subjects a { transition: none; } }

/* the site-wide animated link underline (motion.css) must not draw on these card-style links */
main .lb-shelf li a:not(.btn), main .lb-steps li a:not(.btn) { background: none; padding-bottom: 0; }
main .lb-subjects li a:not(.btn) { background: #fff; padding: 13px 16px; }
main .lb-subjects li a:not(.btn):hover { background: #fff; }
@media (max-width: 560px) { main .lb-subjects li a:not(.btn) { padding: 11px 12px; } }
.lb-dark .eyebrow { background: rgba(255, 255, 255, .08); border-color: rgba(251, 191, 36, .45); color: var(--o400, #fbbf24); }
@media (min-width: 900px) { .lb-subjects { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); } }
