/* The reference arrangement changes only the Shelf controls and cards below
   the original animation. Color selection remains independent of arrangement. */
body[data-page=shelf][data-shelf-layout=reference] {
 --reference-card:var(--surface);
 --reference-card-end:var(--bg);
 --reference-edge:var(--line);
 --reference-shadow:#0002;
 --reference-action:var(--paper);
 --reference-action-ink:var(--paper-ink);
}
:root[data-theme=heirloom_light] body[data-page=shelf][data-shelf-layout=reference] {
 --reference-card:#fbf1df;
 --reference-card-end:#f2e3c7;
 --reference-edge:#b89a65;
 --reference-shadow:#70502516;
 --reference-action:#fff4d9;
 --reference-action-ink:#50361e;
}
body[data-page=shelf][data-shelf-layout=reference] .shelf-actions {
 grid-template-columns:1.22fr 1fr 1fr;
 gap:7px;
 padding:10px 10px 4px;
}
body[data-page=shelf][data-shelf-layout=reference] .shelf-actions .pill {
 min-height:44px;
 padding:6px 8px;
 border-radius:28px;
 border:1px solid var(--reference-edge);
 font:14px/1.2 Georgia,serif;
 background:linear-gradient(var(--reference-card),var(--reference-card-end))!important;
 color:var(--ink);
 --light-text:var(--ink);
 box-shadow:inset 0 1px #fff7,0 2px 5px var(--reference-shadow);
}
body[data-page=shelf][data-shelf-layout=reference] .shelf-actions .pill::before,
body[data-page=shelf][data-shelf-layout=reference] .shelf-actions .pill::after {
 display:none;
}
body[data-page=shelf][data-shelf-layout=reference] .shelf-actions #turn-week {
 background:linear-gradient(120deg,#f5dfa8,#dfba76)!important;
 border-color:#b39150;
 color:#4b3118;
 --light-text:#4b3118;
 box-shadow:inset 0 1px #fff9,0 2px 6px #89652b26;
}
body[data-page=shelf][data-shelf-layout=reference] .shelf-actions .pill.featured:not(#turn-week) {
 background:linear-gradient(var(--reference-card),var(--reference-card-end))!important;
 color:var(--ink);
 --light-text:var(--ink);
 box-shadow:inset 0 1px #fff7,0 2px 5px var(--reference-shadow);
}
body[data-page=shelf][data-shelf-layout=reference] .shelf-actions svg {
 width:18px;
 height:20px;
}
body[data-page=shelf][data-shelf-layout=reference] .shelf-actions .salvation-cross {
 width:14px;
 height:23px;
 fill:currentColor;
 stroke:currentColor;
 filter:none;
}
body[data-page=shelf][data-shelf-layout=reference] .shelf-settings {
 margin:0 10px 8px;
 border-top:0;
 border-bottom:1px solid var(--reference-edge);
}
body[data-page=shelf][data-shelf-layout=reference] .shelf-settings summary {
 min-height:44px;
 font:11px/1.3 system-ui,sans-serif;
 letter-spacing:.01em;
 color:var(--muted);
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards {
 display:flex;
 flex-direction:column;
 gap:7px;
 margin:0 9px;
 padding:0;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards>*,
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .reference-cards>* {
 min-width:0;
 margin:0;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards :is(.illustrated-card,.illustrated-wide,.family-card,.shelf-daily-wisdom,.shortcut-card) {
 --light-text:var(--ink);
 --light-muted:var(--muted);
 color:var(--ink);
 background:url('/assets/images/ae3eecc3329110b3/waymark-surface-grain.svg'),linear-gradient(130deg,var(--reference-card),var(--reference-card-end));
 border:1px solid var(--reference-edge);
 border-radius:9px;
 box-shadow:inset 0 1px #fff7,0 2px 7px var(--reference-shadow);
 text-shadow:none;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards :is(.illustrated-card,.illustrated-wide,.family-card,.shelf-daily-wisdom,.shortcut-card)::before {
 display:none;
}
/* Family remains the existing expandable doorway, with its normal document flow. */
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .family-card {
 position:relative;
 min-height:74px;
 height:auto;
 padding:12px 14px;
 overflow:hidden;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .family-card-art {
 inset:0 0 0 auto;
 width:57%;
 height:100%;
 object-fit:cover;
 object-position:right center;
 mask-image:linear-gradient(90deg,transparent,#000 35%);
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .family-card-copy {
 position:relative;
 width:70%;
 padding:0;
 text-shadow:none;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .family-title {
 font:400 22px/1.1 Georgia,serif;
 margin:0 0 5px;
 color:var(--ink);
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .family-subtitle {
 max-width:210px;
 font:italic 12px/1.3 Georgia,serif;
 color:var(--muted);
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .family-caret {
 position:static;
 margin-left:6px;
 font-size:22px;
 color:var(--gold);
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .family-card[aria-expanded=true] .family-caret {
 transform:rotate(90deg);
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .family-destinations {
 margin-top:6px;
}
/* The live quotation and real Waymark entrance share a balanced two-card row. */
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .reference-cards {
 display:grid;
 grid-template-columns:repeat(2,minmax(0,1fr));
 align-items:stretch;
 gap:7px;
 padding:0;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-cards :is(.shelf-daily-wisdom,.waymark-card) {
 display:flex;
 flex-direction:column;
 min-height:206px;
 padding:9px 8px 7px;
 overflow:visible;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-cards :is(.shelf-daily-wisdom,.waymark-card)>h2 {
 padding:0;
 margin:0 0 7px;
 font:400 clamp(16px,4.5cqw,19px)/1.16 Georgia,serif;
 color:var(--ink);
 text-align:center;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-cards .wisdom-day-label {
 display:block;
 margin:-3px 0 5px;
 font:8px/1.2 Georgia,serif;
 letter-spacing:.1em;
 color:var(--muted);
 --light-text:var(--muted);
}
body[data-page=shelf][data-shelf-layout=reference] .reference-cards [data-wisdom-daily=compact] {
 flex:1;
 display:flex;
 flex-direction:column;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-cards .daily-wisdom-frame {
 flex:1;
 min-height:160px;
 margin:0;
 padding:15% 15% 25%;
 border:0;
 border-image:none;
 background:#f9edda url('/assets/images/38263a9f6c270acd/wisdom-frame.png') center / 100% 100% no-repeat;
 color:#49321d;
 --light-text:#49321d;
 box-shadow:0 2px 7px var(--reference-shadow);
}
body[data-page=shelf][data-shelf-layout=reference] .reference-cards .daily-wisdom-frame blockquote {
 margin:0 0 8px;
 font:italic 13px/1.34 Georgia,serif;
 overflow-wrap:anywhere;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-cards .daily-wisdom-frame figcaption {
 font:9px/1.3 Georgia,serif;
 letter-spacing:.035em;
 overflow-wrap:anywhere;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-cards .waymark-card>p {
 margin:0 1px 7px;
 font:italic 12px/1.34 Georgia,serif;
 text-align:center;
 color:var(--muted);
}
body[data-page=shelf][data-shelf-layout=reference] .reference-cards .waymark-card>.reference-art {
 display:block;
 width:calc(100% + 16px);
 height:auto;
 min-height:90px;
 max-height:138px;
 aspect-ratio:3/2;
 margin:0 -8px;
 flex:1;
 object-fit:cover;
 object-position:center 55%;
}
/* These pills are labels inside the full-card links; the whole cards are the
   touch targets, so no nested interactive control or smaller hit area is added. */
body[data-page=shelf][data-shelf-layout=reference] .reference-cards :is(.wisdom-open,.compact-card-action) {
 display:flex;
 align-items:center;
 justify-content:center;
 min-height:28px;
 margin:8px 0 0;
 padding:5px 7px;
 border:1px solid var(--reference-edge);
 border-radius:20px;
 background:linear-gradient(var(--reference-action),var(--reference-card-end));
 color:var(--reference-action-ink);
 --light-text:var(--reference-action-ink);
 font:13px/1.2 Georgia,serif;
 box-shadow:inset 0 1px #fff9,0 2px 5px var(--reference-shadow);
 text-align:center;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-cards .waymark-card>.compact-card-action {
 margin-top:auto;
}
/* Wide doors use the original pictures on the right, with live text on paper. */
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards>.illustrated-wide {
 position:relative;
 min-height:64px;
 height:auto;
 aspect-ratio:auto;
 overflow:hidden;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards>.secret-card {
 min-height:84px;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards>.illustrated-wide :is(.reference-art,.shelf-keepsake-art) {
 position:absolute;
 inset:0 0 0 auto;
 width:54%;
 height:100%;
 max-width:none;
 object-fit:cover;
 object-position:right 55%;
 mask-image:linear-gradient(90deg,transparent,#000 34%);
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards>.secret-card>.reference-art {
 width:100%;
 object-position:center;
 mask-image:none;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards>[data-shelf-shortcut=albums]>.shelf-keepsake-art {
 width:100%;
 object-position:center;
 mask-image:none;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards>.illustrated-wide .wide-card-copy {
 position:relative;
 inset:auto;
 display:flex;
 flex-direction:column;
 justify-content:center;
 width:74%;
 min-height:64px;
 padding:10px 14px;
 background:linear-gradient(90deg,var(--reference-card) 0%,var(--reference-card) 42%,transparent);
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards>.secret-card .wide-card-copy {
 min-height:84px;
 width:70%;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards>:is(.secret-card,[data-shelf-shortcut=albums]) .wide-card-copy {
 background:linear-gradient(90deg,var(--reference-card),transparent 92%);
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .wide-card-copy h2 {
 margin:0 0 5px;
 color:var(--ink);
 font:400 clamp(19px,5.2cqw,23px)/1.12 Georgia,serif;
 letter-spacing:-.025em;
 white-space:normal;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .wide-card-copy h2>span {
 padding-left:3px;
 font-size:.9em;
}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .wide-card-copy p {
 max-width:220px;
 margin:0;
 color:var(--muted);
 font:italic 12px/1.3 Georgia,serif;
}
body[data-page=shelf][data-shelf-layout=reference] .shelf-shortcut-links {
 margin:7px 10px 0;
 gap:6px;
}
body[data-page=shelf][data-shelf-layout=reference] .home-note {
 margin-top:10px;
}
@media(max-width:350px) {
 body[data-page=shelf][data-shelf-layout=reference] .shelf-actions {gap:5px;padding-inline:8px}
 body[data-page=shelf][data-shelf-layout=reference] .shelf-actions .pill {font-size:12px;padding-inline:5px}
 body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards {margin-inline:8px}
 body[data-page=shelf][data-shelf-layout=reference] .reference-cards :is(.shelf-daily-wisdom,.waymark-card) {padding-inline:6px}
 body[data-page=shelf][data-shelf-layout=reference] .reference-cards .waymark-card>.reference-art {width:calc(100% + 12px);margin-inline:-6px}
 body[data-page=shelf][data-shelf-layout=reference] .reference-cards .daily-wisdom-frame {padding:15% 15% 25%;border:0}
 body[data-page=shelf][data-shelf-layout=reference] .reference-cards .daily-wisdom-frame blockquote {font-size:12.5px}
 body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .family-title {font-size:21px}
 body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .family-card-copy {width:74%}
 body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .wide-card-copy {width:78%;padding-inline:12px}
 body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .wide-card-copy p {font-size:11.5px}
}
/* Keep the Shelf utility links and Family Resources visible below the cards,
   using the same footer arrangement as the dark Shelf. */
:root[data-theme=heirloom_light] body[data-page=shelf] .shelf-shortcut-links {
 --light-text:var(--light-accent);
}
:root[data-theme=heirloom_light] body[data-page=shelf] .family-resources-button {
 background:url('/assets/images/ae3eecc3329110b3/waymark-surface-grain.svg'),linear-gradient(#fff7e9,#f2e3cc)!important;
}
body[data-page=shelf][data-shelf-layout=reference] .shelf-viewing-links{display:flex;flex-wrap:wrap;justify-content:center;gap:6px 16px}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards>.chart-card>.reference-art{width:100%;object-position:right bottom}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards>[data-shelf-shortcut=albums] .wide-card-copy{background:linear-gradient(90deg,var(--reference-card) 0%,var(--reference-card) 45%,transparent 100%)}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards>[data-shelf-shortcut=albums] p{max-width:190px}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .family-card-copy{width:85%}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .family-subtitle{max-width:265px;font-size:11.5px}
body[data-page=shelf][data-shelf-layout=reference] .reference-cards :is(.shelf-daily-wisdom,.waymark-card)>h2{font-size:clamp(14.5px,4.25cqw,18px)}
body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards>.secret-card .wide-card-copy{background:linear-gradient(90deg,var(--reference-card) 0%,#fbf1dff0 50%,transparent 100%)}
@media(max-width:350px){
 body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .family-card-copy{width:75%}
 body[data-page=shelf][data-shelf-layout=reference] .reference-shelf-cards .family-subtitle{max-width:180px}
}
