/* Section pages: a calm reading surface laid over the room photograph. */
#section { z-index: 20; display: flex; flex-direction: column; background: linear-gradient(180deg, #0f1f1dee, #0f1f1df7); backdrop-filter: blur(14px) saturate(.9); opacity: 0; transform: translateY(10px); transition: opacity .45s var(--ease-out), transform .45s var(--ease-out); }
#section.in { opacity: 1; transform: none; }
.section-bar { flex: none; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: calc(14px + var(--safe-t)) calc(18px + var(--safe-r)) 10px calc(18px + var(--safe-l)); }
.section-crumbs { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: calc(13px * var(--text-scale)); color: var(--cream-soft); }
.section-crumbs button { min-height: 44px; padding: 0 12px; border: 1px solid var(--line); border-radius: 999px; background: transparent; color: var(--cream); }
.section-crumbs button:hover { border-color: var(--gold); }
.section-crumbs [aria-current] { padding: 0 6px; }
.section-x { width: 46px; height: 46px; border-radius: 50%; border: 1px solid #f3d29a88; background: #142725; color: var(--cream); font-size: 22px; flex: none; }
.section-x:hover { border-color: var(--gold); background: #1f3835; }
.section-scroll { flex: 1; overflow: auto; overscroll-behavior: contain; padding: 6px calc(18px + var(--safe-r)) calc(48px + var(--safe-b)) calc(18px + var(--safe-l)); }
.section-body { width: min(1040px, 100%); margin: 0 auto; }
.section-body > header { text-align: center; padding: 10px 0 26px; }
.section-body > header h1 { font-size: clamp(38px, 6vw, 62px); margin: 10px 0 12px; color: #fff3da; }
.section-body > header h1:focus { outline: none; }
.section-body .lede { max-width: 60ch; margin: 0 auto; color: var(--cream-soft); font-size: calc(17px * var(--text-scale)); }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.center { justify-content: center; text-align: center; }
.prose { max-width: 62ch; color: var(--cream-soft); margin-top: 12px; }
.linklike { border: 0; background: none; padding: 0; color: var(--gold); text-decoration: underline; text-underline-offset: 3px; min-height: 24px; }
.panel { padding: clamp(18px, 3vw, 30px); border-radius: 16px; border: 1px solid var(--line); background: #1c2b29cc; }
.fine { font-size: calc(13px * var(--text-scale)); color: var(--cream-soft); margin-top: 22px; text-align: center; }

/* Coming soon */
.soon { position: relative; text-align: center; padding: clamp(26px, 5vw, 52px) clamp(18px, 4vw, 48px); border-radius: 20px; border: 1px solid #f3d29a55; background: radial-gradient(120% 90% at 50% 0%, #2a4340 0%, #1c2b29 55%, #172624 100%); overflow: hidden; }
.soon::before { content: ''; position: absolute; inset: 0; background: radial-gradient(60% 40% at 50% -5%, #f3d29a2e, transparent 70%); pointer-events: none; }
.soon-mark { display: inline-grid; place-items: center; width: 54px; height: 54px; border-radius: 50%; border: 1px solid #f3d29a88; color: var(--gold); font-size: 24px; animation: breathe 5s ease-in-out infinite; }
@keyframes breathe { 0%, 100% { box-shadow: 0 0 0 0 #f3d29a00; } 50% { box-shadow: 0 0 0 10px #f3d29a14; } }
.soon h2 { font-size: clamp(30px, 4.6vw, 46px); margin: 12px 0 10px; color: #fff3da; }
.soon > p { max-width: 54ch; margin: 0 auto; color: var(--cream-soft); }
.soon-list { list-style: none; padding: 0; margin: 24px auto 26px; display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); max-width: 820px; text-align: left; }
.soon-list li { padding: 14px 16px; border-radius: 12px; background: #0f1f1d99; border: 1px solid var(--line); font-size: calc(14.5px * var(--text-scale)); color: var(--cream); }
.soon-list li::before { content: '✧'; color: var(--gold); margin-right: 8px; }
.soon .row { justify-content: center; }

/* tabs */
.tabs { display: flex; justify-content: center; gap: 6px; margin-bottom: 22px; }
.tabs button { min-height: 46px; padding: 0 22px; border-radius: 999px; border: 1px solid var(--line); background: transparent; color: var(--cream); font-weight: 500; }
.tabs button[aria-selected='true'] { background: var(--gold); color: var(--ink); border-color: var(--gold); }
.ask-form { max-width: 640px; margin: 0 auto 22px; text-align: left; opacity: .8; }
.ask-form .btn { margin-top: 18px; }
.shelf { display: flex; justify-content: center; align-items: flex-end; gap: 10px; height: 190px; margin: 6px auto 0; padding: 0 16px 12px; border-bottom: 10px solid #5b3e25; box-shadow: 0 10px 14px -6px #0009; max-width: 520px; }
.spine { width: 46px; border-radius: 4px 4px 2px 2px; background: linear-gradient(90deg, #00000033, transparent 30%, #ffffff14 60%, #00000040), var(--c, #6b2f2a); display: grid; place-items: center; box-shadow: inset 0 0 0 1px #00000040; }
.spine span { writing-mode: vertical-rl; transform: rotate(180deg); font: 500 13px/1 var(--display); letter-spacing: .08em; color: #f6e3bf; white-space: nowrap; }

/* podcast */
.episodes { display: grid; gap: 14px; list-style: none; padding: 0; margin: 0; }
.episode { display: grid; grid-template-columns: 92px 1fr; gap: 18px; padding: 18px; border-radius: 16px; border: 1px solid var(--line); background: #1c2b29cc; }
.episode-art { width: 92px; height: 92px; border-radius: 12px; object-fit: cover; background: linear-gradient(135deg, #2a4340, #5b3e25); display: grid; place-items: center; color: var(--gold); font-size: 30px; }
.episode h2 { font-size: calc(25px * var(--text-scale)); color: #fff3da; }
.episode-meta { font-size: calc(13px * var(--text-scale)); color: var(--cream-soft); margin: 4px 0 8px; }
.episode p { color: var(--cream-soft); }
.player { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 14px; padding: 8px 12px; border-radius: 999px; background: #0f1f1dcc; border: 1px solid var(--line); }
.player button { min-width: 44px; min-height: 44px; border-radius: 999px; border: 1px solid transparent; background: transparent; color: var(--cream); font-weight: 500; }
.player button:hover { border-color: var(--line); }
.player .play { background: var(--gold); color: var(--ink); width: 46px; height: 46px; font-size: 16px; }
.player input[type='range'] { flex: 1; min-width: 120px; width: auto; }
.player time { font-variant-numeric: tabular-nums; font-size: calc(13px * var(--text-scale)); color: var(--cream-soft); min-width: 92px; text-align: center; }
.episode-links { margin-top: 10px; font-size: calc(14px * var(--text-scale)); }
.embed { position: relative; aspect-ratio: 16 / 9; margin-top: 14px; border-radius: 12px; overflow: hidden; background: #050807; }
.embed iframe, .embed video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* news feed */
.news-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.news-card { display: flex; flex-direction: column; border-radius: 16px; overflow: hidden; border: 1px solid var(--line); background: #1c2b29cc; color: var(--cream); text-decoration: none; transition: transform .35s var(--ease-out), border-color .3s; }
.news-card:hover { transform: translateY(-4px); border-color: var(--gold); color: var(--cream); }
.news-card img, .news-thumb { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: linear-gradient(135deg, #2f5a45, #6a8f58 55%, #d8c283); display: block; }
.news-thumb { display: grid; place-items: center; font-size: 34px; color: #fff3dacc; }
.news-card div { padding: 16px 18px 18px; display: grid; gap: 8px; }
.news-card small { color: var(--gold); letter-spacing: .06em; font-size: calc(12px * var(--text-scale)); text-transform: uppercase; }
.news-card h2 { font-size: calc(23px * var(--text-scale)); color: #fff3da; }
.news-card p { color: var(--cream-soft); font-size: calc(14.5px * var(--text-scale)); }
.news-card b { font-weight: 500; font-size: calc(13.5px * var(--text-scale)); color: var(--gold); }

/* quiet bench */
.bench { max-width: 720px; margin: 0 auto; text-align: center; padding: clamp(26px, 5vw, 54px) clamp(20px, 5vw, 60px); border-radius: 20px; background: var(--paper); color: var(--paper-ink); box-shadow: 0 30px 60px #0008; }
.bench .eyebrow { color: #7a5a22; }
.bench h2 { font-size: clamp(30px, 4.4vw, 42px); margin: 10px 0 20px; color: #2b2118; }
.bench blockquote { margin: 0; font: 500 clamp(22px, 3vw, 29px)/1.45 var(--display); color: #2b2118; }
.bench cite { display: block; margin-top: 14px; font: 500 calc(14px * var(--text-scale))/1.3 var(--body); font-style: normal; letter-spacing: .08em; text-transform: uppercase; color: #6b4d1c; }
.bench hr { width: 64px; border: 0; border-top: 1px solid #b9a078; margin: 28px auto; }
.bench .prayer { font-size: calc(17.5px * var(--text-scale)); line-height: 1.7; color: #3c2f22; max-width: 52ch; margin: 0 auto; }
.bench .row { justify-content: center; margin-top: 28px; }
.bench .btn { color: #2b2118; border-color: #8a6a2c; }
.bench .btn:hover { background: #8a6a2c1f; color: #2b2118; }
.bench .btn-solid { background: #2b2118; color: #fbe9c9; border-color: #2b2118; }
.bench .btn-solid:hover { background: #45352a; color: #fbe9c9; }
.bench :focus-visible { outline-color: #6b4d1c; }
.bench-nav { display: flex; justify-content: center; gap: 10px; margin-top: 18px; }

/* reading retreat */
.book-card { display: grid; grid-template-columns: minmax(150px, 220px) 1fr; gap: clamp(18px, 4vw, 44px); align-items: center; }
.book-cover { aspect-ratio: 2 / 3; border-radius: 6px 12px 12px 6px; background: linear-gradient(90deg, #00000055, transparent 9%, #ffffff12 12%, transparent 16%), linear-gradient(160deg, #24393a, #0f1f1d 60%, #3a2a17); border: 1px solid #f3d29a66; display: grid; align-content: center; justify-items: center; gap: 10px; padding: 18px; text-align: center; box-shadow: 14px 18px 30px #0009; }
.book-cover small { font-size: 10px; letter-spacing: .2em; text-transform: uppercase; color: var(--gold); }
.book-cover strong { font: 500 clamp(22px, 3vw, 30px)/1.05 var(--display); color: #fff3da; }
.book-card h2 { font-size: clamp(30px, 4.4vw, 46px); color: #fff3da; margin: 8px 0; }
.reader { margin-top: 26px; border-radius: 18px; background: var(--paper); color: var(--paper-ink); padding: clamp(20px, 4vw, 48px); box-shadow: 0 30px 60px #0008; }
.reader.dark { background: #171310; color: #eadfcb; }
.reader small { letter-spacing: .16em; text-transform: uppercase; font-size: 11px; color: #7a5a22; }
.reader.dark small { color: #d7b77a; }
.reader h2 { font-size: clamp(28px, 4vw, 40px); margin: 8px 0 18px; }
.reader-text { max-width: 64ch; margin: 0 auto; font: 500 calc(20px * var(--text-scale))/1.75 var(--display); }
.reader.large .reader-text { font-size: calc(25px * var(--text-scale)); }
.reader-text p + p { margin-top: 1em; }
.reader-controls { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; align-items: center; margin-top: 28px; padding-top: 18px; border-top: 1px solid #b9a07866; }
.reader .btn { color: inherit; border-color: #8a6a2c; }
.reader .btn:hover { background: #8a6a2c26; color: inherit; }
.reader :focus-visible { outline-color: #8a6a2c; }
.reader-status { text-align: center; font-size: calc(13.5px * var(--text-scale)); margin-top: 12px; min-height: 1.4em; }
.dev-note { margin-top: 18px; padding: 12px 14px; border: 1px dashed #f3d29a88; border-radius: 10px; font-size: calc(13px * var(--text-scale)); color: var(--cream-soft); }

/* private cinema */
.cinema { border-radius: 20px; padding: clamp(14px, 3vw, 30px); background: repeating-linear-gradient(90deg, #2b1216 0 46px, #3a1a20 46px 60px, #2b1216 60px 110px), #2b1216; border: 1px solid #f3d29a44; box-shadow: inset 0 40px 80px #000a, inset 0 -30px 60px #0008; }
.screen { position: relative; aspect-ratio: 16 / 9; max-width: 900px; margin: 0 auto; border-radius: 6px; background: #050807; border: 6px solid #15110d; box-shadow: 0 0 0 1px #f3d29a33, 0 30px 80px #000c, 0 0 90px #f3d29a12; overflow: hidden; }
.screen iframe, .screen video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #000; }
.screen-idle { position: absolute; inset: 0; display: grid; place-content: center; gap: 8px; text-align: center; padding: 20px; }
.screen-idle strong { font: 500 clamp(24px, 4vw, 44px)/1.1 var(--display); color: #fff3da; }
.screen-idle span { color: var(--cream-soft); font-size: calc(14px * var(--text-scale)); }
.now-showing { text-align: center; margin: 14px 0 4px; min-height: 1.5em; color: var(--cream-soft); font-size: calc(14px * var(--text-scale)); }
.filters { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin: 18px 0; }
.filters button { min-height: 44px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); background: #0f1f1d99; color: var(--cream); }
.filters button[aria-pressed='true'] { background: var(--gold); color: var(--ink); border-color: var(--gold); font-weight: 600; }
.films { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); }
.film { display: grid; gap: 8px; padding: 0 0 12px; border-radius: 12px; overflow: hidden; border: 1px solid #f3d29a33; background: #150b0dcc; color: var(--cream); text-align: left; transition: transform .35s var(--ease-out), border-color .3s; }
.film:hover { transform: translateY(-4px); border-color: var(--gold); }
.film[aria-current='true'] { border-color: var(--gold); box-shadow: 0 0 0 2px #f3d29a55; }
.film img, .film .poster { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: linear-gradient(135deg, #3a1a20, #15110d); display: grid; place-items: center; color: var(--gold); font-size: 28px; }
.film strong { padding: 0 12px; font: 500 calc(20px * var(--text-scale))/1.15 var(--display); color: #fff3da; }
.film small { padding: 0 12px; color: var(--cream-soft); font-size: calc(12.5px * var(--text-scale)); }

/* story engine (dev demo) */
.story-card { max-width: 680px; margin: 0 auto; text-align: center; }
.story-card h2 { font-size: clamp(28px, 4vw, 40px); margin: 8px 0 12px; color: #fff3da; }
.story-card .choices { display: grid; gap: 10px; margin-top: 22px; }

/* gathering table: calendar */
.cal-wrap { position: relative; }
.cal-wrap.empty .cal { filter: saturate(.5) brightness(.6); pointer-events: none; user-select: none; }
.cal-overlay { position: absolute; inset: 0; display: grid; place-items: center; padding: 16px; z-index: 2; }
.cal-overlay .soon { max-width: 640px; box-shadow: 0 30px 80px #000c; }
.cal-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.cal-head h2 { font-size: clamp(26px, 3.6vw, 36px); color: #fff3da; min-width: 220px; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-dow { text-align: center; padding: 8px 0; font-size: calc(12px * var(--text-scale)); letter-spacing: .12em; text-transform: uppercase; color: var(--cream-soft); }
.cal-day { position: relative; min-height: clamp(52px, 9vw, 96px); padding: 6px 8px; border-radius: 10px; border: 1px solid #d1b58d26; background: #1c2b2999; color: var(--cream); text-align: left; display: flex; flex-direction: column; gap: 4px; font-size: calc(13px * var(--text-scale)); }
.cal-day.out { opacity: .35; }
.cal-day.today { border-color: var(--gold); }
.cal-day.today .n { background: var(--gold); color: var(--ink); border-radius: 999px; padding: 0 7px; font-weight: 600; }
button.cal-day { cursor: pointer; }
button.cal-day:hover, .cal-day[aria-pressed='true'] { border-color: var(--gold); background: #2a4340; }
.cal-day .n { align-self: flex-start; }
.cal-ev { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 2px 6px; border-radius: 6px; background: #f3d29a2e; border-left: 3px solid var(--gold); font-size: calc(12px * var(--text-scale)); }
.agenda { display: grid; gap: 12px; margin-top: 18px; list-style: none; padding: 0; }
.agenda li { display: grid; grid-template-columns: 74px 1fr; gap: 16px; padding: 16px; border-radius: 14px; border: 1px solid var(--line); background: #1c2b29cc; }
.agenda .date { text-align: center; border-right: 1px solid var(--line); padding-right: 12px; }
.agenda .date b { display: block; font: 500 34px/1 var(--display); color: #fff3da; }
.agenda .date span { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); }
.agenda h3 { font-size: calc(24px * var(--text-scale)); color: #fff3da; }
.agenda p { color: var(--cream-soft); font-size: calc(14.5px * var(--text-scale)); margin-top: 4px; }
.agenda img { width: 100%; max-height: 180px; object-fit: cover; border-radius: 10px; margin-top: 10px; }

/* resource shelves: the corkboard */
.cork { position: relative; padding: clamp(26px, 5vw, 54px) clamp(16px, 4vw, 44px); border-radius: 16px; border: 14px solid #5b3e25; box-shadow: inset 0 0 0 2px #3a2716, inset 0 0 60px #0007, 0 24px 60px #0009;
  background: radial-gradient(#00000022 1px, transparent 1.6px) 0 0 / 9px 9px, radial-gradient(#ffffff14 1px, transparent 1.5px) 4px 5px / 13px 13px, linear-gradient(135deg, #b98d5a, #a57746 60%, #b08552); }
.cork-grid { display: grid; gap: clamp(22px, 4vw, 40px); grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.note { position: relative; display: block; padding: 34px 22px 22px; background: #fbf4e4; color: #2b2118; text-decoration: none; border-radius: 3px; box-shadow: 3px 10px 18px #0007; transform: rotate(var(--tilt, -1.5deg)); transform-origin: 50% 12px; transition: transform .5s var(--ease-out), box-shadow .5s var(--ease-out); }
.note:nth-child(2n) { --tilt: 1.8deg; background: #f6ecd2; }
.note:nth-child(3n) { --tilt: -0.6deg; background: #fdf8ee; }
.note:hover, .note:focus-visible { transform: rotate(0deg) translateY(-4px); box-shadow: 6px 18px 26px #0008; color: #2b2118; }
.note small { font-size: calc(11.5px * var(--text-scale)); letter-spacing: .14em; text-transform: uppercase; color: #7a5a22; }
.note strong { display: block; font: 600 calc(29px * var(--text-scale))/1.08 var(--display); margin: 6px 0 8px; color: #2b2118; }
.note span { display: block; font-size: calc(15px * var(--text-scale)); line-height: 1.5; color: #3c2f22; }
.note b { display: block; margin-top: 12px; font-weight: 600; font-size: calc(13.5px * var(--text-scale)); color: #6b3a1c; }
.tack { position: absolute; left: 50%; top: -9px; width: 30px; height: 34px; margin-left: -15px; transform-origin: 50% 85%; animation: tack-in .7s var(--ease-out) both; animation-delay: var(--d, 0s); filter: drop-shadow(2px 5px 3px #0006); }
.note:hover .tack, .note:focus-visible .tack { animation: tack-wiggle .7s ease-in-out; }
@keyframes tack-in { 0% { transform: translateY(-26px) scale(1.25); opacity: 0; } 60% { transform: translateY(2px) scale(.96); opacity: 1; } 100% { transform: none; opacity: 1; } }
@keyframes tack-wiggle { 0%, 100% { transform: rotate(0); } 20% { transform: rotate(-11deg); } 45% { transform: rotate(9deg); } 70% { transform: rotate(-5deg); } 85% { transform: rotate(3deg); } }

/* dialogs content */
.map-grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); margin-top: 20px; }
.map-room { border: 1px solid var(--line); border-radius: 14px; background: #0f1f1d80; overflow: hidden; }
.map-room-head { display: grid; gap: 4px; width: 100%; text-align: left; padding: 16px; border: 0; background: #24393a; color: var(--cream); }
.map-room-head:hover { background: #2f4a47; }
.map-room-head strong { font: 500 calc(27px * var(--text-scale))/1.05 var(--display); color: #fff3da; }
.map-room-head small { color: var(--cream-soft); font-size: calc(12.5px * var(--text-scale)); }
.map-room ul, .journey-list ul { list-style: none; margin: 0; padding: 6px; display: grid; gap: 2px; }
.map-room li button, .journey-list li button { display: grid; gap: 1px; width: 100%; min-height: 48px; padding: 7px 10px; text-align: left; border: 0; border-radius: 8px; background: transparent; color: var(--cream); }
.map-room li button:hover, .journey-list li button:hover { background: #24393a; }
.map-room li small, .journey-list li small { color: var(--cream-soft); font-size: calc(12px * var(--text-scale)); }
.journey-count { margin-top: 14px; font-size: calc(17px * var(--text-scale)); } .journey-count strong { font: 500 calc(30px * var(--text-scale))/1 var(--display); color: var(--gold); }
.journey-bar { height: 8px; border-radius: 99px; background: #0f1f1d; border: 1px solid var(--line); margin-top: 10px; overflow: hidden; } .journey-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--gold-deep), var(--gold)); transition: width .8s var(--ease-out); }
.journey-list { display: grid; gap: 8px 18px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); margin-top: 20px; }
.journey-list h3 { font-size: calc(22px * var(--text-scale)); color: #fff3da; padding: 0 10px; }
.journey-list li button { grid-template-columns: 22px 1fr; column-gap: 6px; } .journey-list li small { grid-column: 2; }
.journey-list li.seen span:first-child { color: var(--gold); }
.sheet .row { margin-top: 20px; }
.turnstile-box { margin-top: 14px; min-height: 0; }
