/*
Theme Name: Sage and Spines
Theme URI: https://example.com/sage-and-spines
Author: SweetSage
Description: A cozy cottagecore book blog theme with a hint of witchy: sage and moss greens, wisteria and rose florals, candle-gold accents, hand-drawn app-style icons, ribbon bookmarks and a candlelight mode. Built for book reviews, ARC reviews, monthly TBRs, favorites, bookstore visits with a map, author interviews and personal posts.
Version: 2.2.0
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: sage-and-spines
*/

/* ---------- Tokens ---------- */
/* Palette: dark green, moss, cream, rosy brown and midnight teal, with wisteria and wood. */
:root {
  --night: #0A3323;
  --night-2: #124A36;
  --teal: #105666;
  --moss: #839958;
  --moss-deep: #5E7440;
  --moss-tint: #E4E9C6;
  --sage: #839958;
  --sage-deep: #5E7440;
  --mist: #F7F4D5;
  --paper: #FFFCEE;
  --wisteria: #6F5A94;
  --wisteria-tint: #E9E3EF;
  --rose: #B0605A;
  --rose-soft: #D3968C;
  --rose-tint: #F4E1DB;
  --candle: #E2B85C;
  --accent: #D3968C;
  --moon: #F7F4D5;
  --ink: #1F2B22;
  --muted: #5A6650;
  --line: #D8D2A4;
  --star: #C9962B;
  --tagline: #D6DDB0;
  --on-dark: #D5DDB5;
  --on-dark-2: #A9B984;
  --bar-end: var(--rose-soft);
  --heading: var(--night);
  --link: #105666;
  --link-hover: #B0605A;
  --btn: var(--night);
  --btn-text: var(--moon);
  --wood-1: #A98561;
  --wood-2: #7A5C45;
  --wood-3: #5B4433;
  --wood-4: #3F2F24;
  --arch-ring: rgba(255,255,255,.6);
  --display: 'IM Fell English', Georgia, 'Times New Roman', serif;
  --body: 'Literata', Georgia, 'Times New Roman', serif;
  --script: 'Caveat', 'Segoe Script', cursive;
  --wrap: 1120px;
}

/* Candlelight mode (dark). Toggled by the candle button in the header. */
:root[data-theme="night"] {
  --night: #03120C;
  --night-2: #0B2A1D;
  --mist: #07170F;
  --paper: #0F2A1D;
  --ink: #E9E7C9;
  --muted: #A9B58F;
  --line: #1F4430;
  --moss-tint: #1B3324;
  --wisteria-tint: #241F38;
  --rose-tint: #33231F;
  --star: #E0AE3C;
  --heading: #F7F4D5;
  --link: #8FD3DA;
  --link-hover: #E6A99F;
  --btn: #B9CB8A;
  --btn-text: #0A2417;
  --arch-ring: rgba(255,255,255,.08);
  color-scheme: dark;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--mist);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; }
a { color: var(--link); text-underline-offset: .2em; text-decoration-thickness: 1px; }
a:hover { color: var(--link-hover); }
:focus-visible { outline: 3px solid var(--link); outline-offset: 3px; border-radius: 2px; }
.masthead :focus-visible, .colophon :focus-visible, .grimoire :focus-visible { outline-color: var(--accent); }
.screen-reader-text {
  position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link { position: absolute; left: -999px; top: 0; background: var(--paper); padding: .6rem 1rem; z-index: 100; }
.skip-link:focus { left: .5rem; top: .5rem; }
.wrap { width: min(100% - 2.5rem, var(--wrap)); margin-inline: auto; }
.wrap--narrow { width: min(100% - 2.5rem, 46rem); }
.masthead .wrap { position: relative; }
h1, h2, h3, h4 { font-family: var(--display); font-weight: 400; color: var(--heading); line-height: 1.15; text-wrap: balance; }

/* ---------- Masthead ---------- */
.masthead { position: relative; z-index: 3; background: var(--night); color: var(--moon); }
.masthead::after {
  content: ""; position: absolute; left: 0; right: 0; top: calc(100% - 38px); height: 210px; pointer-events: none;
  background: url('assets/img/garland.svg') repeat-x center top / 2560px 210px;
}
.masthead__inner { padding: 1.7rem 0 1.2rem; text-align: center; }
.brand { display: inline-block; font-family: var(--display); font-size: clamp(2.1rem, 5.5vw, 3.3rem); line-height: 1.1; color: var(--moon); text-decoration: none; }
.brand:hover { color: var(--accent); }
.brand img { display: block; max-height: 84px; width: auto; }
.tagline { margin: .15rem 0 0; font-family: var(--display); font-style: italic; font-size: 1.15rem; color: var(--tagline); }
.nav-toggle {
  margin-top: 1rem; padding: .45rem 1.1rem; border-radius: 999px; border: 1px solid rgba(255,255,255,.45);
  background: transparent; color: var(--moon); font: inherit; font-size: .95rem; cursor: pointer;
}
.nav { margin-top: 1.1rem; }
.nav ul { display: flex; flex-wrap: wrap; justify-content: center; align-items: flex-start; gap: .5rem 1.6rem; margin: 0; padding: 0; list-style: none; }
.nav a { display: flex; flex-direction: column; align-items: center; gap: .4rem; padding: .15rem 0; color: var(--moon); text-decoration: none; font-size: .9rem; line-height: 1.2; }
.nav a:hover { color: var(--accent); }
.nav__icon { display: block; width: 56px; height: 56px; border-radius: 22%; box-shadow: 0 8px 12px -8px rgba(0,0,0,.6); transition: transform .2s ease; }
.nav a:hover .nav__icon { transform: translateY(-3px) rotate(-1.5deg); }
.nav .current-menu-item > a, .nav .current_page_item > a { color: var(--accent); }
.nav .current-menu-item > a .nav__icon, .nav .current_page_item > a .nav__icon { outline: 2px solid var(--accent); outline-offset: 3px; }
.nav .current-menu-item > a .nav__label, .nav .current_page_item > a .nav__label { border-bottom: 2px solid var(--accent); }

/* ---------- Layout ---------- */
.site-main { padding: 9rem 0 1rem; }
.section { padding: 2.75rem 0; }
.section__head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin-bottom: 1.9rem; }
.section__title { margin: 0; font-size: clamp(1.9rem, 3.6vw, 2.5rem); }
.section__more { font-size: .95rem; }
.divider { height: 40px; margin: 1.5rem auto; background: url('assets/img/divider.svg') center / 360px 40px no-repeat; }
.empty { padding: 2.5rem 1.5rem; text-align: center; color: var(--muted); font-style: italic; border: 1px dashed var(--sage); border-radius: 12px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; padding: .6rem 1.35rem; border-radius: 999px; border: 2px solid var(--btn);
  background: var(--btn); color: var(--btn-text); font: inherit; font-weight: 600; font-size: .95rem; text-decoration: none; line-height: 1.4; cursor: pointer;
}
.btn:hover { background: var(--wisteria); border-color: var(--wisteria); color: #fff; }
.btn--ghost { background: transparent; color: var(--heading); }
.btn--ghost:hover { background: var(--btn); border-color: var(--btn); color: var(--btn-text); }
.btn--candle { background: var(--accent); border-color: var(--accent); color: var(--night); }
.btn--candle:hover { background: var(--moon); border-color: var(--moon); color: var(--night); }
.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.75rem; }

/* ---------- Hero ---------- */
.hero { padding: 1rem 0 2.5rem; }
.hero__grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 3.5rem; align-items: center; }
.hero__title { margin: 0 0 1.1rem; font-size: clamp(2.8rem, 6.4vw, 4.7rem); line-height: 1.02; }
.hero__lede { max-width: 32rem; font-size: 1.12rem; color: var(--muted); }
.hero__lede p { margin: 0 0 1em; }
.hero__lede p:last-child { margin-bottom: 0; }
.reading {
  display: inline-block; margin-top: 1.5rem; padding: .45rem 1.1rem; border-radius: 999px;
  background: var(--wisteria-tint); color: var(--link); font-size: .95rem; font-weight: 600;
}
.reading::before { content: "\2726"; margin-right: .55rem; color: var(--star); }

.arch {
  position: relative; max-width: 380px; margin-inline: auto; padding: 3.6rem 2.4rem 1.8rem; text-align: center;
  background: linear-gradient(180deg, var(--wisteria-tint), var(--rose-tint));
  border-radius: 999px 999px 16px 16px;
  box-shadow: inset 0 0 0 2px var(--arch-ring), 0 18px 34px -18px rgba(0,0,0,.45);
}
.arch .card__frame { width: min(100%, 250px); margin: 0 auto; }
.arch .card__title { font-size: 1.45rem; margin-top: 1.1rem; }

/* ---------- Shelf and cards ---------- */
.shelf { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 2.9rem 2rem; margin: 0; padding: 0; list-style: none; }
.shelf--small { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 2rem 1.4rem; }
.card { position: relative; }
.card__frame { position: relative; }
.card__cover {
  position: relative; display: block; aspect-ratio: 2 / 3; border-radius: 3px 9px 9px 3px; background: var(--wisteria-tint);
  box-shadow: 0 2px 0 rgba(31,46,39,.08), 0 14px 22px -10px rgba(31,46,39,.45); transition: transform .2s ease;
}
.card__cover img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.card__cover::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(90deg, rgba(0,0,0,.24) 0, rgba(0,0,0,0) 4.5%, rgba(255,255,255,.14) 5.5%, rgba(0,0,0,0) 8%);
}
.card:hover .card__cover { transform: translateY(-4px); }
.card__cover--empty { display: grid; place-items: center; padding: 1.1rem; background: linear-gradient(160deg, var(--night-2), var(--night)); color: var(--moon); }
.card__cover--empty::before { content: "\2726"; position: absolute; top: .9rem; left: 0; right: 0; text-align: center; color: var(--candle); font-size: .95rem; }
.card__ph { font-family: var(--display); font-size: 1.2rem; line-height: 1.2; text-align: center; }
.card__title { margin: 1rem 0 .15rem; font-size: 1.2rem; line-height: 1.2; }
.card__title a { color: var(--heading); text-decoration: none; }
.card__title a:hover { color: var(--link); }
.card__author { margin: 0; font-size: .9rem; font-style: italic; color: var(--muted); }
.card__meta { display: flex; flex-wrap: wrap; align-items: center; justify-content: inherit; gap: .15rem .6rem; margin-top: .35rem; font-size: .85rem; color: var(--muted); }
.arch .card__meta { justify-content: center; }

.stars {
  font-size: 1rem; letter-spacing: .08em; line-height: 1;
  background: linear-gradient(90deg, var(--star) var(--pct, 0%), var(--line) var(--pct, 0%));
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent;
}

/* Ribbon bookmarks hanging from the top of a cover */
.ribbons { position: absolute; top: -5px; right: 11%; z-index: 2; display: flex; gap: 5px; }
.ribbon {
  display: block; min-width: 1.75rem; padding: .6rem .35rem 1.05rem; text-align: center;
  font-size: .68rem; font-weight: 700; line-height: 1; color: #fff;
  clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 80%, 0 100%);
}
.ribbon--arc { background: var(--wisteria); }
.ribbon--fav { background: var(--rose); font-size: .8rem; }

/* ---------- Grimoire panel (monthly TBR) and bands ---------- */
.grimoire {
  position: relative; padding: 2.75rem 2.75rem 3rem; border-radius: 18px; background: var(--night); color: var(--moon);
  outline: 1px solid rgba(226,184,92,.55); outline-offset: -12px;
}
.grimoire__head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1.25rem 2rem; margin-bottom: 2.25rem; }
.grimoire__head > div { flex: 1 1 22rem; }
.grimoire h2 { margin: 0 0 1rem; color: var(--moon); font-size: clamp(1.9rem, 3.6vw, 2.5rem); }
.grimoire .challenge { max-width: 30rem; margin: 0; }
.grimoire .challenge__text { color: var(--on-dark); }
.grimoire .challenge__text strong { color: var(--moon); }
.grimoire .challenge__bar { background: rgba(255,255,255,.18); }
.grimoire .shelf { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 2rem 1.25rem; }
.grimoire .card__title { color: var(--moon); font-size: 1.05rem; }
.grimoire .card__title a { color: var(--moon); }
.grimoire .card__title a:hover { color: var(--accent); }
.grimoire .card__author, .grimoire .card__series, .grimoire .card__meta { color: var(--on-dark); }
.grimoire .card__review { color: var(--accent); }
.grimoire .stars { background-image: linear-gradient(90deg, var(--star) var(--pct, 0%), rgba(255,255,255,.24) var(--pct, 0%)); }
.tbr-shelf { margin-top: 2.5rem; }
.tbr-note { margin: 3rem auto 0; }
.archive-list__note { color: var(--muted); font-size: .92rem; white-space: nowrap; }
.card__series { margin: 0; font-size: .85rem; color: var(--muted); }
.card__review { font-size: .88rem; font-weight: 600; }
.ribbon--reading { background: var(--accent); color: var(--night); }
.ribbon--done { background: var(--sage-deep); }
.ribbon--dnf { background: #6B706B; }
.band { margin: 2.5rem 0; padding: 3.25rem 0; background: var(--wisteria-tint); }

/* ---------- Page and archive heads ---------- */
.page-head { padding: 0 0 2.25rem; text-align: center; }
.page-head h1 { margin: 0; font-size: clamp(2.4rem, 5.5vw, 3.6rem); }
.page-head .lede { max-width: 36rem; margin: .9rem auto 0; color: var(--muted); }
.pagination { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem; margin-top: 3.25rem; }
.pagination .page-numbers { padding: .4rem .95rem; border-radius: 999px; background: var(--paper); color: var(--heading); text-decoration: none; border: 1px solid var(--line); }
.pagination .page-numbers.current, .pagination .page-numbers:hover { background: var(--btn); border-color: var(--btn); color: var(--btn-text); }
.archive-list { margin: 2rem 0 0; padding: 0; list-style: none; }
.archive-list li { display: flex; justify-content: space-between; gap: 1rem; padding: .75rem 0; border-bottom: 1px solid var(--line); }
.archive-list time { color: var(--muted); font-size: .92rem; white-space: nowrap; }
.tbr-current { margin-bottom: 1rem; }
.tbr-current__title { font-size: clamp(1.8rem, 4vw, 2.6rem); margin: 0 0 .25rem; }
.tbr-current__date { margin: 0 0 1.5rem; color: var(--muted); font-style: italic; }
.tbr-current__image { max-width: 100%; border-radius: 14px; margin-bottom: 1.75rem; }

/* ---------- Reading typography ---------- */
.prose { max-width: 42rem; }
.prose > * { margin-top: 0; }
.prose p, .prose ul, .prose ol, .prose figure, .prose blockquote { margin-bottom: 1.3em; }
.prose h2 { margin: 2.2em 0 .6em; font-size: 2rem; }
.prose h3 { margin: 1.9em 0 .5em; font-size: 1.5rem; }
.prose ul li::marker { color: var(--sage-deep); }
.prose blockquote { margin-inline: 0; padding: .1rem 0 .1rem 1.25rem; border-left: 3px solid var(--sage); font-style: italic; color: var(--muted); }
.prose img { border-radius: 8px; }
.prose hr { border: 0; height: 40px; margin: 2.5rem 0; background: url('assets/img/divider.svg') center / 360px 40px no-repeat; }
.alignleft { float: left; margin: .3rem 1.5rem 1rem 0; }
.alignright { float: right; margin: .3rem 0 1rem 1.5rem; }
.aligncenter { display: block; margin-inline: auto; }
.wp-caption-text, figcaption { font-size: .9rem; color: var(--muted); text-align: center; }

/* ---------- Single review ---------- */
.entry__head { margin-bottom: 2.25rem; }
.entry__title { margin: 0 0 .5rem; font-size: clamp(2.3rem, 5.4vw, 3.6rem); line-height: 1.05; }
.entry__by { margin: 0; font-size: 1.25rem; font-style: italic; color: var(--muted); }
.entry__series { margin: .1rem 0 0; color: var(--muted); }
.entry__rating { display: flex; align-items: center; gap: .7rem; margin-top: .9rem; }
.entry__rating .stars { font-size: 1.35rem; }
.entry__rating span:last-child { font-weight: 600; color: var(--heading); }
.entry__date { margin: .5rem 0 0; font-size: .92rem; color: var(--muted); }
.entry__grid { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 3.5rem; align-items: start; }
.entry--plain .wrap { width: min(100% - 2.5rem, 46rem); }
.entry__aside { position: sticky; top: 1.5rem; }
.entry__image { width: 100%; margin-bottom: 2rem; border-radius: 14px; }
.facts { margin: 1.75rem 0 0; padding: 1.1rem 1.2rem .6rem; background: var(--paper); border: 1px solid var(--line); border-radius: 12px; font-size: .92rem; line-height: 1.5; }
.facts dt { font-weight: 700; color: var(--heading); }
.facts dd { margin: 0 0 .8rem; }
.facts + .btn { margin-top: 1rem; }
.disclosure { max-width: 42rem; margin: 0 0 2rem; padding: 1rem 1.25rem; border-radius: 12px; background: var(--wisteria-tint); font-size: .95rem; font-style: italic; }
.cw { max-width: 42rem; margin: 2.5rem 0 0; padding: 1rem 1.25rem; background: var(--paper); border: 1px solid var(--line); border-radius: 12px; }
.cw summary { cursor: pointer; font-weight: 700; color: var(--link); }
.cw p { margin: .8rem 0 0; }
.entry-tags { margin: 2rem 0 0; font-size: .92rem; color: var(--muted); }
.post-navigation { margin-top: 3.5rem; padding-top: 2rem; border-top: 1px solid var(--line); }
.post-navigation .nav-links { display: flex; justify-content: space-between; gap: 2rem; }
.post-navigation .nav-title { font-family: var(--display); font-size: 1.2rem; }
.comments-area { max-width: 42rem; margin-top: 3.5rem; }
.comments-area input[type="text"], .comments-area input[type="email"], .comments-area input[type="url"], .comments-area textarea, .search-field {
  width: 100%; padding: .65rem .85rem; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); font: inherit;
}
.comments-area .submit, .search-submit { padding: .6rem 1.35rem; border: 2px solid var(--btn); border-radius: 999px; background: var(--btn); color: var(--btn-text); font: inherit; font-weight: 600; cursor: pointer; }
.comments__title { margin: 0 0 1.25rem; font-size: 1.8rem; }
.comment-list { margin: 0 0 2rem; padding: 0; list-style: none; }
.comment-list .children { margin: 0; padding-left: 1.75rem; list-style: none; }
.comment-body { padding: 1rem 0; border-bottom: 1px solid var(--line); }
.comment-author .avatar { float: left; margin-right: .9rem; border-radius: 50%; }
.comment-metadata, .comment-metadata a { font-size: .85rem; color: var(--muted); }
.comment-reply-title { font-family: var(--display); font-size: 1.6rem; font-weight: 400; color: var(--heading); }
.search-form { display: flex; gap: .6rem; max-width: 28rem; margin: 1.5rem auto 0; }

/* ---------- Footer ---------- */
.colophon { margin-top: 4rem; padding: 2.5rem 0 2.75rem; background: var(--night); color: var(--moon); text-align: center; }
.colophon::before { content: ""; display: block; height: 40px; margin-bottom: 1.25rem; background: url('assets/img/divider.svg') center / 360px 40px no-repeat; }
.colophon a { color: var(--moon); text-decoration-color: rgba(255,255,255,.4); }
.colophon a:hover { color: var(--accent); }
.colophon__brand { font-family: var(--display); font-size: 1.9rem; color: var(--moon); }
.colophon__about { max-width: 30rem; margin: .4rem auto 1.4rem; color: var(--tagline); font-style: italic; }
.colophon ul { display: flex; flex-wrap: wrap; justify-content: center; gap: .3rem 1.6rem; margin: 0 0 1.1rem; padding: 0; list-style: none; }
.colophon__small { margin: 1.4rem 0 0; font-size: .85rem; color: var(--on-dark-2); }

/* ---------- Navigation dropdown and candlelight toggle ---------- */
/* The icon menu is one flat row: dropdown children sit beside their parent. */
.nav .menu-item-has-children, .nav .sub-menu { display: contents; }
.nav a { max-width: 6rem; text-align: center; }


/* ---------- Journal cards (bookstores, interviews, life) ---------- */
.journal { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2.9rem 2rem; margin: 0; padding: 0; list-style: none; }
.jcard__image {
  position: relative; display: block; aspect-ratio: 3 / 2; overflow: hidden; border-radius: 16px;
  background: linear-gradient(160deg, var(--night-2), var(--night)); box-shadow: 0 14px 22px -12px rgba(0,0,0,.45);
}
.jcard__image img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.jcard:hover .jcard__image img { transform: scale(1.03); }
.jcard__image--empty .jcard__pic::before { content: "\2726"; position: absolute; inset: 0; display: grid; place-items: center; color: var(--candle); font-size: 1.7rem; }
.jcard__meta { display: flex; flex-wrap: wrap; gap: .1rem .9rem; margin: 1rem 0 .25rem; font-size: .88rem; color: var(--muted); }
.jcard__title { margin: 0 0 .5rem; font-size: 1.55rem; line-height: 1.15; }
.jcard__title a { color: var(--heading); text-decoration: none; }
.jcard__title a:hover { color: var(--link); }
.jcard .stars { display: inline-block; margin-bottom: .5rem; }
.jcard__excerpt { margin: 0; font-size: .98rem; color: var(--muted); }

/* ---------- Bookstore map and stats ---------- */
.stats { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem 3rem; margin: 0 0 1.75rem; padding: 0; list-style: none; }
.stats li { text-align: center; }
.stats strong { display: block; font-family: var(--display); font-size: 2.6rem; font-weight: 400; line-height: 1; color: var(--heading); }
.stats span { font-size: .92rem; color: var(--muted); }
.sn-map { position: relative; z-index: 0; height: 440px; margin-bottom: 3rem; overflow: hidden; border: 2px solid var(--line); border-radius: 18px; background: var(--wisteria-tint); }
.sn-map--small { height: 260px; margin: 1.25rem 0 0; }
.sn-map .leaflet-tile-pane { filter: sepia(.25) saturate(.75) hue-rotate(55deg) brightness(1.03); }
[data-theme="night"] .sn-map .leaflet-tile-pane { filter: invert(1) hue-rotate(160deg) saturate(.45) brightness(.85) contrast(.9); }
.sn-pin-wrap { background: transparent; border: 0; }
.sn-pin { position: relative; display: block; width: 26px; height: 26px; border: 3px solid #fff; border-radius: 50% 50% 50% 0; background: var(--wisteria); box-shadow: 0 4px 8px rgba(0,0,0,.35); transform: rotate(-45deg); }
.sn-pin::after { content: ""; position: absolute; top: 7px; left: 7px; width: 8px; height: 8px; border-radius: 50%; background: var(--candle); }
.leaflet-popup-content-wrapper { border-radius: 12px; font-family: var(--body); color: #26302A; }
.leaflet-popup-content a { color: #6F5A94; }
.sn-popup strong { display: block; font-family: var(--display); font-size: 1.15rem; font-weight: 400; }
.sn-popup span { display: block; font-size: .85rem; color: #55645A; }
.visit { margin: 0 0 2rem; padding: 1.25rem 1.4rem; background: var(--paper); border: 1px solid var(--line); border-radius: 14px; }
.visit dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .9rem 1.5rem; margin: 0; font-size: .95rem; line-height: 1.5; }
.visit dt { font-weight: 700; color: var(--heading); }
.visit dd { margin: 0; }

/* ---------- Reading challenge ---------- */
.challenge { max-width: 34rem; margin: 0 auto; }
.challenge__text { display: flex; justify-content: space-between; gap: 1rem; margin-bottom: .55rem; font-size: .95rem; color: var(--muted); }
.challenge__text strong { color: var(--heading); font-weight: 600; }
.challenge__bar { height: .9rem; overflow: hidden; border-radius: 999px; background: var(--line); }
.challenge__fill { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--sage-deep), var(--sage) 55%, var(--bar-end)); }

/* ---------- Socials ---------- */
.socials { display: flex; flex-wrap: wrap; justify-content: center; gap: .6rem 1.5rem; margin: 0; padding: 0; list-style: none; }
.social { display: inline-flex; align-items: center; gap: .5rem; text-decoration: none; }
.social svg { width: 1.3rem; height: 1.3rem; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- About me ---------- */
.about { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 4rem; align-items: start; }
.portrait {
  position: relative; max-width: 360px; margin-inline: auto; aspect-ratio: 3 / 4; overflow: hidden; border-radius: 999px 999px 18px 18px;
  background: linear-gradient(180deg, var(--wisteria-tint), var(--rose-tint));
  box-shadow: inset 0 0 0 2px var(--arch-ring), 0 18px 34px -18px rgba(0,0,0,.45);
}
.portrait img { display: block; width: 100%; height: 100%; object-fit: cover; }
.portrait--empty::before { content: "\263E"; position: absolute; inset: 0; display: grid; place-items: center; color: var(--star); font-size: 4rem; }
.about__links { margin-top: 2.25rem; }
.about__links .socials { justify-content: flex-start; }
.about .challenge { margin: 2rem 0 0; max-width: none; }
.home-widgets .widget-title { font-family: var(--display); font-weight: 400; font-size: 1.6rem; }

/* ---------- Illustrated icons ---------- */
.page-head__icon { display: block; width: 96px; height: 96px; margin: 0 auto 1.1rem; border-radius: 22%; box-shadow: 0 12px 20px -10px rgba(31,46,39,.55); }
.hero__socials { margin-top: 1.9rem; }
.hero__socials .socials { justify-content: flex-start; }
.socials--tiles { gap: 1rem 1.75rem; }
.social--tile { flex-direction: column; gap: .45rem; font-size: .92rem; text-align: center; color: var(--heading); }
.social--tile .social__tile { display: block; width: 72px; height: 72px; border-radius: 22%; box-shadow: 0 10px 16px -10px rgba(31,46,39,.55); transition: transform .2s ease; }
.social--tile:hover .social__tile { transform: translateY(-3px) rotate(-1.5deg); }

/* ---------- Dynamic home page features ---------- */
.fireflies { position: fixed; inset: 0; z-index: 1; overflow: hidden; pointer-events: none; }
.firefly {
  position: absolute; left: var(--x); top: var(--y); width: 5px; height: 5px; border-radius: 50%; opacity: 0;
  background: #F6DE9A; box-shadow: 0 0 8px 3px rgba(246,222,154,.65);
  animation: firefly-drift var(--t) ease-in-out var(--d) infinite alternate, firefly-blink var(--b) ease-in-out var(--d) infinite;
}
@keyframes firefly-drift { to { transform: translate(var(--dx), var(--dy)); } }
@keyframes firefly-blink { 0%, 100% { opacity: 0; } 50% { opacity: .9; } }

.reading-card {
  display: flex; align-items: center; gap: 1rem; max-width: 26rem; margin-top: 1.6rem; padding: .9rem 1.15rem;
  background: var(--paper); border: 1px solid var(--line); border-radius: 16px;
}
.reading-card__cover { flex: none; width: 64px; height: 96px; object-fit: cover; border-radius: 3px 7px 7px 3px; box-shadow: 0 8px 12px -6px rgba(31,46,39,.5); }
.reading-card__body { min-width: 0; }
.reading-card__label { margin: 0; font-size: .82rem; color: var(--muted); }
.reading-card__title { margin: .1rem 0 0; font-family: var(--display); font-size: 1.3rem; line-height: 1.15; color: var(--heading); }
.reading-card__author { margin: .15rem 0 0; font-size: .9rem; font-style: italic; color: var(--muted); }
.reading-card__pages { margin: .3rem 0 0; font-size: .82rem; color: var(--muted); }
.mini-bar { height: .55rem; margin-top: .65rem; overflow: hidden; border-radius: 999px; background: var(--line); }
.mini-bar span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--sage-deep), var(--sage) 60%, var(--bar-end)); }

.stats__title { margin: 0 0 1.1rem; text-align: center; font-size: 1.7rem; }
.stats__wide strong { max-width: 18rem; margin-inline: auto; padding-top: .35rem; font-size: 1.45rem; line-height: 1.2; }

.soon { display: inline-block; padding: .1rem .65rem; border-radius: 999px; background: var(--wisteria-tint); color: var(--link); font-size: .82rem; font-weight: 600; }
.soon--today { background: var(--candle); color: #1F2E27; }

.deck__head { text-align: center; }
.deck__head .section__title { margin-bottom: .4rem; }
.deck__lede { margin: 0; color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem; margin-top: 1.25rem; }
.chip {
  padding: .4rem 1.05rem; border: 1.5px solid var(--sage-deep); border-radius: 999px; background: transparent;
  color: var(--heading); font: inherit; font-size: .92rem; cursor: pointer;
}
.chip:hover { background: var(--wisteria-tint); }
.chip[aria-pressed="true"] { background: var(--btn); border-color: var(--btn); color: var(--btn-text); }
.deck__row { display: grid; grid-template-columns: repeat(3, minmax(0, 200px)); justify-content: center; gap: 2rem; margin-top: 1.75rem; }
.tslot[hidden] { display: none; }
.tcard { display: block; width: 100%; aspect-ratio: 2 / 3; padding: 0; border: 0; background: none; perspective: 900px; cursor: pointer; }
.tcard:disabled { cursor: default; }
.tcard__inner { position: relative; display: block; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform .7s ease; }
.tcard.is-flipped .tcard__inner { transform: rotateY(180deg); }
.tcard:not(.is-flipped):hover .tcard__inner { transform: translateY(-6px) rotate(-1.5deg); }
.tcard__face { position: absolute; inset: 0; overflow: hidden; border-radius: 12px; backface-visibility: hidden; box-shadow: 0 14px 22px -10px rgba(31,46,39,.55); }
.tcard__back { background: url('assets/img/card-back.svg') center / cover no-repeat; }
.tcard__front { transform: rotateY(180deg); background: var(--wisteria-tint); }
.tcard__front img { display: block; width: 100%; height: 100%; object-fit: cover; }
.tcard__ph { display: grid; place-items: center; width: 100%; height: 100%; padding: 1rem; font-family: var(--display); font-size: 1.2rem; text-align: center; color: var(--heading); }
.tslot__cap { margin-top: 1rem; text-align: center; }
.tslot__title { display: block; font-family: var(--display); font-size: 1.2rem; line-height: 1.2; }
.tslot__by { margin: .15rem 0 .3rem; font-size: .9rem; font-style: italic; color: var(--muted); }
.deck__actions { margin: 2rem 0 0; text-align: center; }

.quotes__stage { min-height: 9.5rem; text-align: center; }
.quote { margin: 0; opacity: 0; transition: opacity .35s ease; }
.quote.is-active { opacity: 1; }
.quote[hidden] { display: none; }
.quote blockquote { margin: 0; padding: 0; border: 0; font-family: var(--display); font-size: clamp(1.5rem, 3vw, 2.1rem); line-height: 1.35; color: var(--heading); font-style: normal; }
.quote blockquote p { margin: 0; }
.quote blockquote p::before { content: "\201C"; }
.quote blockquote p::after { content: "\201D"; }
.quote figcaption { margin-top: 1rem; font-size: .95rem; color: var(--muted); }
.quote figcaption .stars { margin-left: .6rem; vertical-align: middle; }
.quotes__dots { display: flex; justify-content: center; gap: .55rem; margin-top: 1.25rem; }
.quotes__dot { width: .7rem; height: .7rem; padding: 0; border: 1.5px solid var(--sage-deep); border-radius: 50%; background: transparent; cursor: pointer; }
.quotes__dot.is-active { background: var(--sage-deep); }

/* ---------- Countdown clock and Coming soon ---------- */
.clock { display: flex; flex-wrap: wrap; gap: .6rem; }
.clock__cell {
  display: flex; flex-direction: column; align-items: center; min-width: 4.3rem; padding: .7rem .5rem .55rem;
  background: var(--night); color: var(--moon); border-radius: 12px; outline: 1px solid rgba(226,184,92,.5); outline-offset: -4px;
}
.clock__num { font-family: var(--body); font-weight: 700; font-size: 1.95rem; line-height: 1; font-variant-numeric: lining-nums tabular-nums; }
.clock__label { margin-top: .35rem; font-size: .72rem; color: var(--on-dark); }
.clock--sm { gap: .4rem; }
.clock--sm .clock__cell { min-width: 3.4rem; padding: .5rem .3rem .4rem; border-radius: 10px; outline-offset: -3px; }
.clock--sm .clock__num { font-size: 1.4rem; }
.clock--sm .clock__label { margin-top: .25rem; font-size: .64rem; }
.clock__done { font-family: var(--display); font-size: 1.5rem; color: var(--heading); }
.upcoming__list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.75rem 2rem; margin: 0; padding: 0; list-style: none; }
.upcoming__item { display: flex; align-items: flex-start; gap: 1.25rem; padding: 1.25rem; background: var(--paper); border: 1px solid var(--line); border-radius: 18px; }
.upcoming__cover { flex: none; width: 110px; }
.upcoming__body { min-width: 0; }
.upcoming__title { margin: 0; font-size: 1.4rem; line-height: 1.15; }
.upcoming__title a { color: var(--heading); text-decoration: none; }
.upcoming__title a:hover { color: var(--link); }
.upcoming__by { margin: .2rem 0 0; font-size: .92rem; font-style: italic; color: var(--muted); }
.upcoming__date { margin: .15rem 0 .85rem; font-size: .88rem; color: var(--muted); }
.release-clock { max-width: 42rem; margin: 0 0 2rem; padding: 1.25rem 1.4rem 1.4rem; background: var(--wisteria-tint); border-radius: 14px; }
.release-clock__label { margin: 0 0 .85rem; font-family: var(--display); font-size: 1.3rem; line-height: 1.2; color: var(--heading); }

/* ---------- Responsive ---------- */
@media (min-width: 761px) { .nav-toggle { display: none; } }
@media (max-width: 760px) {
  .nav { display: none; }
  .nav.is-open { display: block; }
  .nav ul { gap: 1rem 1.1rem; }
}
@media (max-width: 860px) {
  .hero__grid, .entry__grid { grid-template-columns: 1fr; }
  .hero__grid { gap: 2.75rem; }
  .entry__aside { position: static; max-width: 260px; }
  .grimoire { padding: 2.25rem 1.75rem; }
  .grimoire .shelf { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .site-main { padding-top: 6.8rem; }
  .masthead::after { height: 123px; background-size: 1500px 123px; top: calc(100% - 22px); }
  .shelf { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .shelf--small { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .journal { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .about { grid-template-columns: 1fr; gap: 2.5rem; }
  .upcoming__list { grid-template-columns: 1fr; }
  .visit dl { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .shelf { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2.25rem 1.25rem; }
  .shelf--small { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .grimoire .shelf { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .journal { grid-template-columns: 1fr; }
  .sn-map { height: 340px; }
  .upcoming__item { padding: 1rem; gap: 1rem; }
  .upcoming__cover { width: 88px; }
  .clock__cell { min-width: 3.6rem; }
  .clock__num { font-size: 1.6rem; }
  .deck__row { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .9rem; }
  .tslot__title { font-size: 1rem; }
  .tslot__by { font-size: .82rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
  .fireflies { display: none; }
}

/* =====================================================================
   Design v3: cream paper, olive bands, hand-drawn doodles, wood and wisteria
   ===================================================================== */
body { background-image: url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 width=%27220%27 height=%27220%27%3E%3Cfilter id=%27n%27%3E%3CfeTurbulence type=%27fractalNoise%27 baseFrequency=%27.8%27 numOctaves=%272%27 stitchTiles=%27stitch%27/%3E%3CfeColorMatrix values=%270 0 0 0 .38  0 0 0 0 .32  0 0 0 0 .16  0 0 0 .07 0%27/%3E%3C/filter%3E%3Crect width=%27220%27 height=%27220%27 filter=%27url%28%23n%29%27/%3E%3C/svg%3E"); }
[data-theme="night"] body { background-image: none; }

/* Hand-drawn doodles: black line art recolored with currentColor-style backgrounds */
.doodle { display: inline-block; width: 1em; height: 1em; background-color: currentColor; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; -webkit-mask-position: center; mask-position: center; -webkit-mask-size: contain; mask-size: contain; }
.doodle--book { -webkit-mask-image: url('assets/doodles/book.svg'); mask-image: url('assets/doodles/book.svg'); }
.doodle--scrolls { -webkit-mask-image: url('assets/doodles/scrolls.svg'); mask-image: url('assets/doodles/scrolls.svg'); }
.doodle--heart { -webkit-mask-image: url('assets/doodles/heart.svg'); mask-image: url('assets/doodles/heart.svg'); }
.doodle--basket { -webkit-mask-image: url('assets/doodles/basket.svg'); mask-image: url('assets/doodles/basket.svg'); }
.doodle--cottage { -webkit-mask-image: url('assets/doodles/cottage.svg'); mask-image: url('assets/doodles/cottage.svg'); }
.doodle--teacup { -webkit-mask-image: url('assets/doodles/teacup.svg'); mask-image: url('assets/doodles/teacup.svg'); }
.doodle--mug { -webkit-mask-image: url('assets/doodles/mug.svg'); mask-image: url('assets/doodles/mug.svg'); }
.doodle--wildflowers { -webkit-mask-image: url('assets/doodles/wildflowers.svg'); mask-image: url('assets/doodles/wildflowers.svg'); }
.doodle--hat { -webkit-mask-image: url('assets/doodles/hat.svg'); mask-image: url('assets/doodles/hat.svg'); }
.doodle--mushrooms { -webkit-mask-image: url('assets/doodles/mushrooms.svg'); mask-image: url('assets/doodles/mushrooms.svg'); }
.doodle--frame { -webkit-mask-image: url('assets/doodles/frame.svg'); mask-image: url('assets/doodles/frame.svg'); }
.doodle--candle-jar { -webkit-mask-image: url('assets/doodles/candle-jar.svg'); mask-image: url('assets/doodles/candle-jar.svg'); }
.doodle--bow { -webkit-mask-image: url('assets/doodles/bow.svg'); mask-image: url('assets/doodles/bow.svg'); }
.doodle--flourish-heart { -webkit-mask-image: url('assets/doodles/flourish-heart.svg'); mask-image: url('assets/doodles/flourish-heart.svg'); }
.doodle--flourish { -webkit-mask-image: url('assets/doodles/flourish.svg'); mask-image: url('assets/doodles/flourish.svg'); }
.doodle--swirl { -webkit-mask-image: url('assets/doodles/swirl.svg'); mask-image: url('assets/doodles/swirl.svg'); }
.doodle--corner-vine { -webkit-mask-image: url('assets/doodles/corner-vine.svg'); mask-image: url('assets/doodles/corner-vine.svg'); }
.doodle--bee { -webkit-mask-image: url('assets/doodles/bee.svg'); mask-image: url('assets/doodles/bee.svg'); }
.doodle--snail { -webkit-mask-image: url('assets/doodles/snail.svg'); mask-image: url('assets/doodles/snail.svg'); }
.doodle--moth { -webkit-mask-image: url('assets/doodles/moth.svg'); mask-image: url('assets/doodles/moth.svg'); }
.doodle--rabbit { -webkit-mask-image: url('assets/doodles/rabbit.svg'); mask-image: url('assets/doodles/rabbit.svg'); }
.doodle--sprig { -webkit-mask-image: url('assets/doodles/sprig.svg'); mask-image: url('assets/doodles/sprig.svg'); }
.ico { display: inline-grid; place-items: center; }

/* Script accents */
.tagline { font-family: var(--script); font-style: normal; font-weight: 500; font-size: 1.6rem; line-height: 1.1; }
.reading-card__label, .deck__lede { font-family: var(--script); font-weight: 500; font-size: 1.25rem; color: var(--moss-deep); }

/* Header: icon menu as cream stickers, with a wooden branch below and flowers hanging from it */
.masthead__inner { padding-bottom: 3.7rem; }
.masthead::before { content: ""; position: absolute; left: 0; right: 0; top: calc(100% - 52px); height: 100px; z-index: 4; pointer-events: none; background: url('assets/img/branch.svg') repeat-x center top / 2560px 100px; }
.nav__icon { width: 60px; height: 60px; border-radius: 50%; background: var(--moon); box-shadow: 0 0 0 2px rgba(247,244,213,.28), 0 8px 12px -8px rgba(0,0,0,.6); }
.nav__icon .doodle { width: 66%; height: 66%; background-color: var(--night); }
.nav a:hover .nav__icon { background: var(--accent); }
.nav .current-menu-item > a .nav__icon, .nav .current_page_item > a .nav__icon { background: var(--accent); outline: 2px solid var(--moon); outline-offset: 3px; }

/* Doodle icons above page titles and on the social links */
.page-head__icon, .social--tile .social__tile { display: grid; place-items: center; border-radius: 50%; background: var(--moss-tint); box-shadow: 0 0 0 2px var(--paper), 0 0 0 3px var(--line); }
.page-head__icon { width: 92px; height: 92px; margin: 0 auto 1.1rem; }
.social--tile .social__tile { width: 72px; height: 72px; }
.page-head__icon .doodle, .social__tile .doodle { width: 62%; height: 62%; background-color: var(--night); }
.social--tile:hover .social__tile { background: var(--rose-soft); }
.page-head h1::after { content: ""; display: block; width: min(240px, 60%); height: 28px; margin: .6rem auto 0; background-color: var(--moss); -webkit-mask: url('assets/doodles/flourish-heart.svg') center / contain no-repeat; mask: url('assets/doodles/flourish-heart.svg') center / contain no-repeat; }
.section__title::after { content: ""; display: block; width: 130px; height: 20px; margin-top: .4rem; background-color: var(--moss); -webkit-mask: url('assets/doodles/flourish.svg') left center / contain no-repeat; mask: url('assets/doodles/flourish.svg') left center / contain no-repeat; }
.deck__head .section__title::after, .stats__title::after { margin-inline: auto; -webkit-mask-position: center; mask-position: center; }
.stats__title::after { content: ""; display: block; width: 130px; height: 20px; margin-top: .3rem; background-color: var(--moss); -webkit-mask: url('assets/doodles/flourish.svg') center / contain no-repeat; mask: url('assets/doodles/flourish.svg') center / contain no-repeat; }

/* The featured book: a wooden arched window with wisteria and a bow */
.arch { max-width: 400px; padding: 3.9rem 3.2rem 3.5rem; border-radius: 0; box-shadow: none; background: url('assets/img/frame-featured.svg') center / 100% 100% no-repeat, radial-gradient(ellipse 62% 56% at 50% 46%, var(--wisteria-tint) 0, var(--rose-tint) 68%, transparent 100%); }
[data-theme="night"] .arch { background-image: url('assets/img/frame-featured-night.svg'), radial-gradient(ellipse 62% 56% at 50% 46%, rgba(111,90,148,.28) 0, rgba(176,96,90,.16) 68%, transparent 100%); }
.arch::before { content: ""; position: absolute; left: -144px; top: -38px; width: 280px; height: 380px; z-index: 6; pointer-events: none; background: url('assets/img/arch-wisteria.svg') no-repeat left top / contain; }
.arch::after { content: ""; position: absolute; left: 50%; top: -30px; width: 66px; height: 62px; transform: translateX(-50%); z-index: 7; pointer-events: none; background-color: var(--rose-soft); -webkit-mask: url('assets/doodles/bow.svg') center / contain no-repeat; mask: url('assets/doodles/bow.svg') center / contain no-repeat; }

/* Critters from the doodle set wandering around the hero */
.hero__grid { position: relative; }
.hero__grid::before { content: ""; position: absolute; left: 47%; top: 1%; width: 56px; height: 56px; transform: rotate(-12deg); background-color: var(--moss-deep); pointer-events: none; -webkit-mask: url('assets/doodles/bee.svg') center / contain no-repeat; mask: url('assets/doodles/bee.svg') center / contain no-repeat; }
.hero__grid::after { content: ""; position: absolute; left: 3%; bottom: -6%; width: 62px; height: 40px; background-color: var(--rose); opacity: .8; pointer-events: none; -webkit-mask: url('assets/doodles/snail.svg') center / contain no-repeat; mask: url('assets/doodles/snail.svg') center / contain no-repeat; }

/* Books stand on wooden shelves */
.shelf .card__frame::after { content: ""; position: absolute; left: -1.1rem; right: -1.1rem; bottom: -15px; height: 16px; z-index: 0; border-radius: 3px; background: repeating-linear-gradient(90deg, rgba(0,0,0,.07) 0 2px, transparent 2px 13px), linear-gradient(var(--wood-1) 0, var(--wood-2) 32%, var(--wood-3) 100%); box-shadow: 0 12px 12px -6px rgba(31,22,16,.5), inset 0 1px 0 rgba(255,255,255,.32), inset 0 -2px 0 rgba(0,0,0,.28); }
.shelf .card__cover { z-index: 1; }
.shelf .ribbons { z-index: 3; }
.shelf .card__title { margin-top: 1.55rem; }

/* The TBR panel in a wooden frame */
.grimoire { outline: none; box-shadow: 0 0 0 10px var(--wood-2), 0 0 0 12px var(--wood-4), inset 0 0 0 1px rgba(226,184,92,.5), 0 26px 30px -14px rgba(0,0,0,.45); }

/* Bands with scalloped edges */
.band { --band: var(--wisteria-tint); position: relative; margin: 4rem 0; padding: 3.5rem 0; background: var(--band); }
.band::before, .band::after { content: ""; position: absolute; left: 0; right: 0; height: 16px; background: var(--band); -webkit-mask: radial-gradient(circle at 50% 100%, #000 9.5px, transparent 10px) 0 0 / 22px 16px repeat-x; mask: radial-gradient(circle at 50% 100%, #000 9.5px, transparent 10px) 0 0 / 22px 16px repeat-x; }
.band::before { top: -15px; }
.band::after { bottom: -15px; transform: scaleY(-1); }
.band--moss { --band: var(--moss); }
.band--moss .section__title, .band--moss .section__more { color: var(--night); }
.band--moss .section__more { text-decoration-color: rgba(10,51,35,.4); }
.band--moss .section__title::after { background-color: var(--moon); }

/* Polaroid-style photos on journal cards */
.jcard__image { display: block; padding: 10px 10px 40px; overflow: visible; aspect-ratio: auto; border-radius: 3px; background: #FFFDF2; box-shadow: 0 12px 18px -8px rgba(31,22,16,.45); transform: rotate(-1.2deg); }
.jcard:nth-child(even) .jcard__image { transform: rotate(1deg); }
.jcard__image::before { content: ""; position: absolute; top: -11px; left: 50%; width: 76px; height: 22px; transform: translateX(-50%) rotate(-3deg); background: rgba(211,150,140,.6); box-shadow: 0 1px 2px rgba(0,0,0,.12); }
.jcard__pic { position: relative; display: block; aspect-ratio: 3 / 2; overflow: hidden; background: linear-gradient(160deg, var(--night-2), var(--night)); }
.jcard__pic img { display: block; width: 100%; height: 100%; object-fit: cover; }
.jcard:hover .jcard__image { transform: rotate(0deg) translateY(-3px); }
.jcard__image { transition: transform .2s ease; }

/* A meadow at the bottom of the page and a wooden floor */
.site-main { position: relative; overflow-x: clip; padding-top: 9rem; }
.colophon { position: relative; margin-top: 7rem; border-top: 16px solid var(--wood-2); box-shadow: inset 0 5px 0 var(--wood-1); }
.colophon::before { content: ""; position: absolute; left: 0; right: 0; top: -164px; height: 150px; margin: 0; display: block; background: url('assets/img/grass.svg') repeat-x center bottom / 2560px 150px; pointer-events: none; }
.divider { height: 44px; margin: 1.5rem auto; width: min(300px, 70%); background: var(--moss); -webkit-mask: url('assets/doodles/flourish-heart.svg') center / contain no-repeat; mask: url('assets/doodles/flourish-heart.svg') center / contain no-repeat; }
.prose hr { border: 0; height: 44px; margin: 2.5rem auto; width: min(300px, 70%); background: var(--moss); -webkit-mask: url('assets/doodles/flourish-heart.svg') center / contain no-repeat; mask: url('assets/doodles/flourish-heart.svg') center / contain no-repeat; }

/* Buttons and links in the new palette */
.btn--candle { background: var(--accent); border-color: var(--accent); color: var(--night); }
.btn--candle:hover { background: var(--moon); border-color: var(--moon); }
.soon--today { color: var(--night); }

@media (max-width: 860px) {
  .arch::before { display: none; }
  .hero__grid::before, .hero__grid::after { display: none; }
  .site-main { padding-top: 6.8rem; }
  .masthead__inner { padding-bottom: 3.2rem; }
  .band { margin: 3.25rem 0; padding: 2.5rem 0; }
  .colophon::before { top: -108px; height: 94px; background-size: 1600px 94px; }
  .colophon { margin-top: 5rem; }
}
@media (max-width: 760px) {
  .nav__icon { width: 56px; height: 56px; }
}

/* Candlelight mode touches for the new design */
[data-theme="night"] .band--moss { --band: #12351F; }
[data-theme="night"] .band--moss .section__title, [data-theme="night"] .band--moss .section__more { color: var(--heading); }
[data-theme="night"] .page-head__icon .doodle, [data-theme="night"] .social__tile .doodle { background-color: var(--moon); }
[data-theme="night"] .page-head__icon, [data-theme="night"] .social--tile .social__tile { background: var(--night-2); box-shadow: 0 0 0 2px var(--line); }
[data-theme="night"] .jcard__image, [data-theme="night"] .snl-photo { background: #E9E4C6; }

/* Candlelight button: the candelabra doodle on a cream sticker, lit and glowing in dark mode */
.doodle--candelabra { -webkit-mask-image: url('assets/doodles/candelabra.svg'); mask-image: url('assets/doodles/candelabra.svg'); }
.mode-toggle {
  position: absolute; top: 1.1rem; right: 0; display: grid; place-items: center; width: 4rem; height: 4rem; padding: 0;
  border: 0; border-radius: 50%; background: var(--moon); color: var(--night); cursor: pointer;
  box-shadow: 0 0 0 2px rgba(247,244,213,.28), 0 8px 12px -8px rgba(0,0,0,.6); transition: background .2s ease, transform .2s ease;
}
.mode-toggle .doodle { width: auto; height: 80%; aspect-ratio: .56; background-color: var(--night); filter: drop-shadow(0 0 .5px var(--night)); }
.mode-toggle:hover { background: var(--accent); transform: translateY(-2px) rotate(-3deg); }
[data-theme="night"] .mode-toggle { background: rgba(226,184,92,.14); box-shadow: 0 0 0 2px var(--candle), 0 0 18px 2px rgba(226,184,92,.35); }
[data-theme="night"] .mode-toggle .doodle { background-color: var(--candle); filter: drop-shadow(0 0 4px rgba(226,184,92,.95)); animation: candelabra-glow 2.8s ease-in-out infinite; }
@keyframes candelabra-glow { 0%, 100% { opacity: 1; filter: drop-shadow(0 0 4px rgba(226,184,92,.95)); } 35% { opacity: .88; filter: drop-shadow(0 0 7px rgba(226,184,92,1)); } 65% { opacity: 1; filter: drop-shadow(0 0 3px rgba(226,184,92,.8)); } }
@media (max-width: 760px) { .mode-toggle { top: .9rem; width: 3.3rem; height: 3.3rem; } }

/* Reading challenge and numbers: a little envelope on a pastel pink band */
.doodle--rose { -webkit-mask-image: url('assets/doodles/rose.svg'); mask-image: url('assets/doodles/rose.svg'); }
.doodle--flower { -webkit-mask-image: url('assets/doodles/flower.svg'); mask-image: url('assets/doodles/flower.svg'); }
.doodle--leaves { -webkit-mask-image: url('assets/doodles/leaves.svg'); mask-image: url('assets/doodles/leaves.svg'); }
.band--pink { --band: #F5E0D8; }
.letter-band { margin: 4.5rem 0 4rem; padding: 4rem 0 4.25rem; }
.letter-band .wrap { position: relative; }
.letter { position: relative; padding: 7.6rem 3rem 2.8rem; background: var(--paper); border: 2px solid var(--rose); border-radius: 12px 12px 18px 18px; box-shadow: 0 24px 30px -22px rgba(120,60,50,.55); }
.letter__flap { position: absolute; left: -2px; right: -2px; top: -2px; height: 5.6rem; background: url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 100 100%27 preserveAspectRatio=%27none%27%3E%3Cpath d=%27M0 0 L50 100 L100 0 Z%27 fill=%27%23EBCFC3%27 stroke=%27%23B0605A%27 stroke-width=%272%27 vector-effect=%27non-scaling-stroke%27 stroke-linejoin=%27round%27/%3E%3C/svg%3E") center / 100% 100% no-repeat; }
.letter__seal { position: absolute; left: 50%; top: 3.5rem; width: 72px; height: 68px; transform: translateX(-50%); background-color: var(--rose); filter: drop-shadow(0 2px 0 rgba(255,252,238,.9)); }
.letter .challenge { margin: 0 0 2rem; }
.letter .stats__title { margin-top: 0; }
.letter__deco { position: absolute; bottom: -18px; width: 130px; height: 130px; background-color: var(--rose); opacity: .85; pointer-events: none; }
.letter__deco--l { left: -170px; } .letter__deco--r { right: -160px; -webkit-mask-image: url('assets/doodles/wildflowers.svg'); mask-image: url('assets/doodles/wildflowers.svg'); height: 190px; width: 120px; bottom: -8px; background-color: var(--moss-deep); }
[data-theme="night"] .band--pink { --band: #2A1D1F; }
[data-theme="night"] .letter { border-color: var(--rose-soft); }
[data-theme="night"] .letter__flap { background-image: url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 100 100%27 preserveAspectRatio=%27none%27%3E%3Cpath d=%27M0 0 L50 100 L100 0 Z%27 fill=%27%233A2A2A%27 stroke=%27%23D3968C%27 stroke-width=%272%27 vector-effect=%27non-scaling-stroke%27 stroke-linejoin=%27round%27/%3E%3C/svg%3E"); }
[data-theme="night"] .letter__seal, [data-theme="night"] .letter__deco { background-color: var(--rose-soft); }
@media (max-width: 1250px) { .letter__deco { display: none; } }
@media (max-width: 640px) { .letter { padding: 6rem 1.25rem 2rem; } .letter-band { padding: 3rem 0 3.25rem; } }
