/* ===================== ROOT & GLOBAL ===================== */

:root {
  --bg-indigo: #1C2330;
  --text-main: #ECEBE7;
--text-subtle: #AFC4E2;

  --accent-gold: #F5DFA8;
  --accent-vermillion: #C63A1E;
  --card-border: rgba(255, 255, 255, 0.06);
  --pill-bg: rgba(236, 235, 231, 0.08);
  --shadow-soft: 0 18px 45px rgba(0, 0, 0, 0.45);
  --radius-xl: 1.75rem;
  --radius-lg: 1.25rem;
  --radius-pill: 999px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
}

/* ===================== BACKGROUND ===================== */

/* Soft blended indigo wash, similar spirit to Room 1 */
body {
  font-family: 'Georgia', serif;
  /* Softer indigo wash with gentle blending */
  background:
    radial-gradient(circle at 20% -20%,
      rgba(70, 94, 140, 0.85) 0%,
      rgba(23, 30, 48, 0.0) 55%),
    radial-gradient(circle at 80% 120%,
      rgba(10, 16, 30, 0.9) 0%,
      rgba(5, 7, 13, 0.0) 70%),
    linear-gradient(to bottom,
      #181f30 0%,
      #131a29 45%,
      #080c16 100%);
  color: var(--text-main);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

html {
  scroll-behavior: smooth;
}

/* ===================== ROOM CONTAINER & HEADER ===================== */

.room-container {
  max-width: 1080px;
  margin: auto;
  padding: 2rem 1.5rem 4rem 1.5rem;
  text-align: center;
}

.room-title {
  position: relative;
  display: inline-block;
}

.room-title h1 {
  font-size: 2rem;
  font-weight: bold;
  margin-bottom: 0.4rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}

/* tagline – visible and prominent */
.subtitle {
  margin: 0;
  font-size: 1.05rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-gold);
}

/* glow line under room title */
.room-title::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -0.6rem;
  width: 180px;
  height: 3px;
  border-radius: 999px;
  transform: translateX(-50%);
  background: radial-gradient(circle at 50% 50%,
              rgba(245, 223, 168, 0.95),
              rgba(245, 223, 168, 0.35),
              rgba(245, 223, 168, 0.0));
  box-shadow:
    0 0 16px rgba(245, 223, 168, 0.9),
    0 0 32px rgba(245, 223, 168, 0.6);
}

/* nav */

.room-nav {
  margin: 1.6rem auto 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.8rem;
  justify-content: center;
}

.room-nav a {
  font-size: 0.8rem;
  text-decoration: none;
  padding: 0.25rem 0.9rem;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: var(--text-subtle);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.room-nav a:hover {
  background: rgba(245, 223, 168, 0.18);
  border-color: rgba(245, 223, 168, 0.75);
  color: var(--accent-gold);
}

/* ===================== MOONLIGHT OVERLAY ===================== */

#room2 {
  position: relative;
  min-height: 100vh;
  padding-bottom: 6rem;
  z-index: 0;
}

#room2::before {
  content: "";
  position: fixed;
  inset: -20%;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% -10%, rgba(245, 223, 168, 0.20), transparent 70%),
    radial-gradient(circle at 12% 95%, rgba(143, 167, 199, 0.16), transparent 65%),
    radial-gradient(circle at 88% 110%, rgba(245, 223, 168, 0.12), transparent 70%);
  mix-blend-mode: soft-light;
  opacity: 0.5;
  animation: moonShimmer 34s ease-in-out infinite alternate;
}

@keyframes moonShimmer {
  0% {
    transform: translate3d(0, 0, 0) scale(1.01);
    opacity: 0.46;
  }
  40% {
    transform: translate3d(-1.5%, 1.5%, 0) scale(1.03);
    opacity: 0.56;
  }
  70% {
    transform: translate3d(1.5%, -1.2%, 0) scale(1.02);
    opacity: 0.52;
  }
  100% {
    transform: translate3d(-0.8%, 0.8%, 0) scale(1.01);
    opacity: 0.55;
  }
}

.section-inner,
.room-title,
.room-nav,
.back-pill,
.closing-inner {
  position: relative;
  z-index: 1;
}

/* ===================== BACK PILL ===================== */

.back-pill {
  position: fixed;
  bottom: 1.5rem;
  right: 1.75rem;
  z-index: 30;
  padding: 0.6rem 1.3rem;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(245, 223, 168, 0.8);
  background: radial-gradient(circle at top left, rgba(245, 223, 168, 0.25), rgba(12, 18, 30, 0.98));
  color: var(--accent-gold);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.55);
  transition: transform 0.14s ease, box-shadow 0.14s ease, background 0.14s ease;
}

.back-pill:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6);
}

.back-pill:active {
  transform: translateY(1px);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.5);
}

/* ===================== SECTIONS & HEADERS ===================== */

.section {
  padding: 4.5rem 0 4rem 0;
}

.section-inner {
  max-width: 1080px;
  margin: 0 auto;
}

.section-header {
  text-align: center;
  margin: 0 0 1.9rem;
}

.section-header h2 {
  margin: 0;
  font-size: clamp(1.5rem, 2.0vw, 2rem);
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  position: relative;
  display: inline-block;
  padding-bottom: 0.6rem;
}

/* stronger glowing line under section titles */
.section-header h2::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 140px;
  height: 3px;
  border-radius: 999px;
  transform: translateX(-50%);
  background: radial-gradient(circle at 50% 50%,
              rgba(245, 223, 168, 0.95),
              rgba(245, 223, 168, 0.35),
              rgba(245, 223, 168, 0.0));
  box-shadow:
    0 0 14px rgba(245, 223, 168, 0.85),
    0 0 26px rgba(245, 223, 168, 0.55);
}

.section-header p.section-subtitle {
  margin: 0.7rem auto 0;
  font-size: 0.86rem;
  color: var(--text-subtle);
  max-width: 40rem;
}

/* ===================== TEXT BODY ===================== */

.text-body p {
  margin: 0 0 0.85rem;
  font-size: 0.95rem;
  line-height: 1.7;
}

/* ===================== CARDS ===================== */

.text-card {
  background:
    radial-gradient(circle at 10% 0%, rgba(245, 223, 168, 0.08), transparent 55%),
    radial-gradient(circle at 90% 120%, rgba(10, 14, 24, 0.95), rgba(6, 9, 18, 0.98));
  border-radius: var(--radius-xl);
  border: 1px solid rgba(255, 255, 255, 0.04);
  padding: 1.6rem 1.5rem 1.5rem;
  box-shadow: 0 22px 55px rgba(0, 0, 0, 0.55);
  position: relative;
  overflow: hidden;
  text-align: left;
}

.text-card h3 {
  margin: 0 0 0.2rem;
  font-size: 1.05rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.meta-line {
  margin: 0 0 1rem;
  font-size: 0.78rem;
  color: var(--text-subtle);
}

/* stanza card (Stillness as Fullness) */

.stanza-card {
  max-width: 720px;
  margin: 2rem auto 0 auto;
}

.stanza-body p {
  margin: 0.12rem 0;
}

/* grids */

.foundations-grid {
  margin-top: 2.4rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .foundations-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* ===================== ENTRY ===================== */

.entry-section {
  padding-top: 3.5rem;
}

.entry-inner {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.entry-plaque {
  align-self: center;
  text-align: center;
}

/* opening plaque – no label */

.entry-mantra-block {
  display: inline-block;
  padding: 0.85rem 2.6rem;
  border-radius: 999px;
  border: 1px solid rgba(245, 223, 168, 0.85);
  background:
    radial-gradient(circle at 50% 0%, rgba(245, 223, 168, 0.32), rgba(10, 14, 24, 0.96));
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.75);
}

.entry-mantra-line {
  margin: 0.08rem 0;
  font-size: 0.98rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-gold);
}

/* luminous stanza */

.stanza-block {
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
}

.stanza-heading {
  margin: 0 0 0.75rem;
  font-size: 0.9rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-subtle);
}

/* ===================== HAIKU ===================== */

.haiku-section {
  padding-top: 4rem;
  padding-bottom: 3.5rem;
}

.haiku-card {
  margin: 2rem auto 0;
  background:
    radial-gradient(circle at 50% 0%, rgba(245, 223, 168, 0.26), rgba(236, 235, 231, 0.06));
  border-radius: var(--radius-xl);
  border: 1px solid rgba(245, 223, 168, 0.55);
  padding: 2rem 1.6rem;
  max-width: 520px;
  box-shadow: var(--shadow-soft);
}

.haiku-line {
  margin: 0.25rem 0;
  font-size: 1rem;
  text-align: center;
}

/* ===================== PILLS & PAGER ===================== */

.pill {
  display: inline-flex;
  align-items: center;
  border-radius: var(--radius-pill);
  font-size: 0.75rem;
  padding: 0.18rem 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.pill-soft {
  background: var(--pill-bg);
  color: var(--text-subtle);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.pager {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

.pager-btn {
  width: 1.9rem;
  height: 1.9rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.26);
  background: rgba(16, 23, 35, 0.9);
  color: var(--text-main);
  font-size: 0.85rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, transform 0.12s ease, border-color 0.15s ease;
}

.pager-btn:hover {
  background: rgba(245, 223, 168, 0.22);
  border-color: rgba(245, 223, 168, 0.8);
}

.pager-btn:active {
  transform: translateY(1px);
}

.pager-status {
  font-size: 0.78rem;
  color: var(--text-subtle);
}

/* ===================== GALLERY ===================== */

.gallery-shell {
  margin-top: 2.4rem;
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.gallery-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.gallery-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.4rem;
}

@media (min-width: 600px) {
  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 900px) {
  .gallery-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.gallery-item {
  background:
    radial-gradient(circle at 10% 0%, rgba(245, 223, 168, 0.08), transparent 55%),
    radial-gradient(circle at 90% 120%, rgba(10, 14, 24, 0.96), rgba(6, 9, 18, 0.98));
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.04);
  padding: 1.1rem 1.2rem 1.2rem;
  box-shadow: var(--shadow-soft);
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.gallery-item img {
  width: 100%;
  border-radius: 1rem;
  display: block;
}

.gallery-item-title {
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0;
}

.gallery-item-meta {
  font-size: 0.8rem;
  color: var(--text-subtle);
}

.gallery-item-caption {
  font-size: 0.88rem;
}

.gallery-note {
  margin: 0.4rem 0 0;
  font-size: 0.8rem;
  color: var(--text-subtle);
}

/* ===================== SUPPORT / DONATION ===================== */

.support-section {
  padding-top: 4.5rem;
}

.support-inner {
  max-width: 1080px;
}

.support-main {
  margin-top: 2.3rem;
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 2rem;
  align-items: center;
}

@media (max-width: 820px) {
  .support-main {
    grid-template-columns: 1fr;
  }
}

.support-left p {
  margin: 0 0 0.85rem;
  font-size: 0.93rem;
  line-height: 1.7;
}

.support-details {
  margin-top: 1.1rem;
  margin-bottom: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.support-line {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  font-size: 0.88rem;
}

.support-line .label {
  min-width: 3.2rem;
  color: var(--text-subtle);
}

.support-line .value {
  font-family: "SF Mono", ui-monospace, Menlo, Monaco, monospace;
  font-size: 0.83rem;
}

.support-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-bottom: 0.4rem;
}

.primary-btn,
.ghost-btn {
  border-radius: var(--radius-pill);
  padding: 0.55rem 1.3rem;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease, transform 0.12s ease;
}

.primary-btn {
  border: 1px solid rgba(245, 223, 168, 0.9);
  background: radial-gradient(circle at 50% 0%, rgba(245, 223, 168, 0.24), rgba(12, 18, 30, 0.96));
  color: var(--accent-gold);
  box-shadow: var(--shadow-soft);
}

.primary-btn:hover {
  background: radial-gradient(circle at 50% 0%, rgba(245, 223, 168, 0.32), rgba(12, 18, 30, 0.98));
}

.ghost-btn {
  border: 1px solid rgba(255, 255, 255, 0.32);
  background: transparent;
  color: var(--text-subtle);
}

.ghost-btn:hover {
  border-color: rgba(245, 223, 168, 0.8);
  color: var(--accent-gold);
}

.primary-btn:active,
.ghost-btn:active {
  transform: translateY(1px);
}

.support-note {
  font-size: 0.8rem;
  color: var(--text-subtle);
  min-height: 1.1rem;
}

.support-right {
  justify-self: center;
  text-align: center;
}

/* QR card – light so code is readable on dark background */

.qr-frame {
  padding: 0.85rem 1rem;
  border-radius: 1.5rem;
  background:
    radial-gradient(circle at 50% 30%, #f7f5ee 0, #e2dfd4 65%, #d6d2c7 100%);
  border: 1px solid rgba(0, 0, 0, 0.12);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
}

.qr-frame img {
  display: block;
  width: 140px;
  height: 140px;
  max-width: 100%;
  border-radius: 0.75rem;
  background: #ffffff;
}

.qr-caption {
  margin: 0.7rem 0 0;
  font-size: 0.8rem;
  color: var(--text-subtle);
}

.support-footer {
  margin-top: 0.8rem;
  text-align: center;
}

.support-mantra-block {
  display: inline-block;
  padding: 0.85rem 2.4rem;
  border-radius: 999px;
  border: 1px solid rgba(245, 223, 168, 0.8);
  background:
    radial-gradient(circle at 50% 0%, rgba(245, 223, 168, 0.30), rgba(10, 14, 24, 0.96));
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.7);
  margin-bottom: 1.4rem;
}

/* use updated text in HTML: Built In Silence / Sealed In Light */

.support-mantra-line {
  margin: 0.08rem 0;
  font-size: 0.95rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-gold);
}

/* ===================== CLOSING ===================== */

.closing-section {
  padding-top: 1.2rem;
  padding-bottom: 4.5rem;
}

.closing-inner {
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}

.closing-mantra {
  margin-bottom: 2.4rem;
}

/* final line under seal */

.closing-final-line {
  margin: 0.25rem 0;
  font-size: 0.85rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-vermillion);
}

/* spacing between seal and vow block */
.closing-vow {
  margin-top: 2.8rem;  /* adjust this value up/down to taste */
}


/* ===================== SIGNATURE BLOCKS ===================== */

@keyframes signatureFade {
  0% {
    opacity: 0;
    transform: translateY(10px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.signature-block {
  opacity: 0;
  animation: signatureFade 1.8s ease-out 1s forwards;
  text-align: center;
  margin-top: 1.5rem;
  font-size: 1.1rem;
  line-height: 1.6;
}

.seal-image {
  width: 80px;
  margin-top: 0.5rem;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

/* inline variant for My Life Journey, Zen Moon, Illumination, Nirvana */

.signature-inline {
  animation: none;
  opacity: 1;
  margin-top: 1.4rem;
  font-size: 0.9rem;
}

.signature-inline .seal-image {
  width: 70px;
}

/* ===================== LINKS & SMALL SCREENS ===================== */

a {
  color: var(--accent-gold);
}

a:hover {
  text-decoration: underline;
}

@media (max-width: 480px) {
  .room-container {
    padding: 1.5rem 1rem 3rem 1rem;
  }

  .entry-mantra-block {
    padding-inline: 1.4rem;
  }

  .back-pill {
    right: 1.1rem;
    bottom: 1.1rem;
  }
}

/* ===================== ROOM TOOLBAR (Magnifier + Audio) ===================== */

.room-toolbar {
  margin: 1.2rem auto 0;
  display: flex;
  justify-content: center;
  gap: 0.75rem;
}

/* pill-style buttons for magnifier + audio */

.icon-pill {
  border-radius: 999px;
  border: 1px solid rgba(245, 223, 168, 0.8);
  background: radial-gradient(circle at 50% 0%, rgba(245, 223, 168, 0.24), rgba(12, 18, 30, 0.98));
  color: var(--accent-gold);
  padding: 0.4rem 1.1rem;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.55);
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
}

.icon-pill:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.6);
}

.icon-pill:active {
  transform: translateY(1px);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.5);
}

/* ===================== Room 2 – Magnifier & Mute (match Room 1) ===================== */

/* Magnifier – top-right, fixed, circular */
.magnifier {
  position: fixed;
  top: 18px;
  right: 18px;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  font-size: 20px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 999px;
  backdrop-filter: blur(6px);
  cursor: pointer;
  z-index: 10001;
  transition: transform 180ms ease;
}

/* When magnifier is active, rotate to indicate zoom-on */
.magnifier.is-on {
  transform: rotate(180deg);
}

/* Zoom behavior – same pattern as Room 1 */
:root {
  --font-scale-normal: 1;
  --font-scale-zoomed: 1.12;
}

/* base font scale */
body {
  font-size: calc(18px * var(--font-scale-normal));
}

/* zoomed state */
body.zoom-on {
  font-size: calc(18px * var(--font-scale-zoomed));
}


/* Mute button – bottom-right circular, like Room 1 */
.mute-toggle,
#mute-button {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: rgba(255, 255, 255, 0.7);
  border: none;
  padding: 10px;
  font-size: 1.2rem;
  border-radius: 50%;
  cursor: pointer;
  z-index: 10005;
  transition: background 0.3s;
  pointer-events: auto;
}

.mute-toggle:hover,
#mute-button:hover {
  background: rgba(255, 255, 255, 0.9);
}

/* Back to Chamber — raised gold pill */
.back-link{
  display:inline-flex;
  align-items:center;
  gap:.5rem;

  padding: 10px 14px;
  min-height: 38px;
  border-radius: 999px;

  background: linear-gradient(180deg, #f8e3ba 0%, #e7bf7a 100%);
  color: #2c1a00;
  font-weight: 700;
  text-decoration: none;
  letter-spacing:.12px;

  border: 1px solid rgba(176,108,45,.35);
  box-shadow:
    0 10px 22px rgba(161,35,0,.18),
    0 2px  0 rgba(255,255,255,.55) inset,
    0 -1px 0 rgba(0,0,0,.06) inset;

  backdrop-filter: blur(4px) saturate(110%);
  transition: transform .15s ease, box-shadow .15s ease, filter .15s ease;
}

/* Hover & active */
.back-link:hover{
  transform: translateY(-1px);
  box-shadow:
    0 14px 28px rgba(161,35,0,.26),
    0 2px  0 rgba(255,255,255,.65) inset,
    0 -1px 0 rgba(0,0,0,.08) inset;
  filter: saturate(1.05);
}
.back-link:active{
  transform: translateY(0);
  box-shadow:
    0 8px 18px rgba(161,35,0,.16),
    0 1px 0 rgba(255,255,255,.5) inset,
    0 -1px 0 rgba(0,0,0,.08) inset;
}

/* Focus ring */
.back-link:focus-visible{
  outline: 3px solid #c41219;
  outline-offset: 2px;
}

/* Add chevron automatically */
.back-link::before{
  content: "←";
  display: inline-block;
  margin-right: .45rem;
  transform: translateY(-1px);
  opacity: .9;
}

/* Desktop: inline in header */
.back-link{
  position: static;
}

/* Mobile: float at bottom-left and auto-hide */
@media (max-width: 720px){
  .back-link{
    position: fixed;
    left:  max(12px, env(safe-area-inset-left));
    bottom: max(12px, env(safe-area-inset-bottom));
    top: auto;
    z-index: 10006;
    transition:
      transform .28s cubic-bezier(.16,.84,.44,1),
      opacity   .28s linear,
      box-shadow .20s ease;
  }
  .back-link.is-hidden{
    transform: translateY(120%);
    opacity: .35;
    box-shadow: none;
  }
}

@media (max-width: 480px){
  .back-link{
    font-size: .85rem;
    padding: 8px 10px;
    max-width: 180px;
    text-align: center;
  }
}

/* Print: hide back link */
@media print {
  .back-link { display: none !important; }
}

/* Zoom panel tucked under the magnifier */
.zoom-panel{
  position: fixed;
  top: 68px;
  right: 12px;
  width: 180px;
  padding: 10px;
  border-radius: 12px;
  background: rgba(0,0,0,0.55);
  border: 1px solid rgba(255,255,255,0.35);
  color: #fff;
  z-index: 10000;
  backdrop-filter: blur(8px) saturate(120%);
  box-shadow: 0 8px 24px rgba(0,0,0,.25);
  display: grid;
  gap: 8px;
}
.zoom-row{
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
}
.zoom-label{ text-align: center; font-weight: 600; min-width: 48px; }
.zoom-slider{
  width: 100%;
  accent-color: #c41219;
}
.zoom-panel button{
  appearance: none;
  border: 1px solid rgba(255,255,255,.35);
  background: rgba(255,255,255,.10);
  color: #fff;
  border-radius: 999px;
  padding: 6px 10px;
  font-weight: 600;
  cursor: pointer;
}
.zoom-panel button:hover{ background: rgba(255,255,255,.18); }
.zoom-panel .zoom-reset{ justify-self: center; padding: 6px 12px; }

@media (max-width: 480px){
  .zoom-panel{ width: 160px; right: 8px; top: 64px; }
}

/* show panel only when zoom is active */
.zoom-panel{ display: none; }
body.zoom-on .zoom-panel{ display: grid; }

.zoom-panel button:focus-visible,
.zoom-panel .zoom-slider:focus-visible {
  outline: 2px solid #c41219;
  outline-offset: 2px;
}

/* sr-only helper (if not already defined) */
.sr-only{
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
/* ===================== Room 2 – Deep Bowl Light Resonance ===================== */

/* Deep, slow resonance – inspired by Tibetan bowl */
@keyframes room2DeepBowl {
  0% {
    /* almost full from the start */
    opacity: 0.70;
    transform: translate(-50%, -40%) scale(0.98);
    box-shadow: 0 0 55px rgba(175, 210, 255, 0.55);
  }
  20% {
    /* peak illumination – full moon at its brightest */
    opacity: 0.92;
    transform: translate(-50%, -41%) scale(1.06);
    box-shadow: 0 0 90px rgba(190, 220, 255, 0.80);
  }
  50% {
    /* gentle settle, still very luminous */
    opacity: 0.82;
    transform: translate(-50%, -39%) scale(1.03);
    box-shadow: 0 0 75px rgba(150, 190, 255, 0.65);
  }
  80% {
    /* soft second swell, like a slow breath */
    opacity: 0.88;
    transform: translate(-50%, -40%) scale(1.05);
    box-shadow: 0 0 85px rgba(180, 210, 255, 0.75);
  }
  100% {
    /* returns to steady bright glow, not dim */
    opacity: 0.78;
    transform: translate(-50%, -40%) scale(1.0);
    box-shadow: 0 0 60px rgba(150, 190, 255, 0.60);
  }
}

/* A centered bowl of light in the upper-middle of the page */
.room2-zen-wash {
  position: fixed;
  left: 50%;
  top: 45%;
  width: 420px;
  height: 420px;
  transform: translate(-50%, -40%);
  pointer-events: none;
  z-index: 1;            /* bump above background */

  border-radius: 50%;    /* perfect circle bowl */

  background:
    radial-gradient(circle,
      rgba(180, 210, 255, 0.55) 0%,
      rgba(120, 160, 230, 0.38) 32%,
      rgba(42, 54, 90, 0.16) 60%,
      transparent 78%);

  /* 🔥 KEY PART: always glowing + radiating */
  opacity: 0.5;
  animation: room2DeepBowl 12s ease-in-out infinite;
  will-change: opacity, transform, box-shadow;
}

/* My Interpretation – longer subtitle lines */
.interpretation-section .section-subtitle-long {
  font-size: 1rem;            /* larger than default subtitle */
  line-height: 1.7;           /* more breathing room vertically */
  max-width: 44rem;           /* keeps lines from stretching too wide */
  margin-top: 0.5rem;
  margin-left: auto;
  margin-right: auto;
}

/* Room 2 – My Interpretation: title + haiku layout override */

/* Try to normalize the entry title above the card */
#mi-entry-title,
.mi-entry-title,
.interpretation-title {
  text-align: center;
  font-size: 1.35rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: none; /* remove forced ALL CAPS if present */
}

/* Haiku block */
.room2-haiku {
  text-align: center;
  margin: 2rem 0 1.8rem;
}

/* Haiku lines – larger and more open */
.room2-haiku .haiku-line {
  font-size: 1.1rem;
  line-height: 1.7;
  margin: 0.35rem 0;
}

/* Signature under haiku */
.signature-block.signature-inline {
  text-align: center;
  font-size: 0.95rem;
}

/* Metadata line under signature */
.meta-line {
  margin-top: 0.5rem;
  font-size: 0.85rem;
  text-align: center;
}

/* Final override for My Interpretation title + meta line */

/* Stop ALL CAPS and center the title above the card */
#mi-entry-title,
.mi-entry-title,
.interpretation-title,
.room2-entry-title,
.room2-entry-title span,
.room2-card h2,
.room2-card h2 span {
  text-transform: none !important;   /* show: Timeless Memory Stream */
  text-align: center;
  font-size: 1.4rem;
  font-weight: 500;
  letter-spacing: 0.06em;
}

/* Make the metadata line bigger and centered */
.meta-line {
  margin-top: 0.5rem;
  font-size: 1rem;                   /* larger than before */
  text-align: center;
}

/* Special style for Timeless Memory Stream haiku title (MI-02 only) */
.mi-title-haiku {
  text-transform: none !important;  /* keep mixed case */
  font-size: 1.05rem;               /* smaller than section headers */
  font-weight: 500;
  letter-spacing: 0.03em;
  text-align: center;
}

/* My Interpretation – base title style (MI-01 and others) */
#interpretation-title {
  text-align: center;
  margin: 0 0 1.1rem;      /* space under title */
  font-size: 1.1rem;       /* slightly larger than body */
  letter-spacing: 0.18em;
  text-transform: uppercase;
}


/* Center titles for foundational cards only */
.foundations-grid .text-card h3,
.stanza-card .text-card h3 {
  text-align: center;
}

/* Center the Stillness As Fullness stanza title only */
.stanza-card h3,
.stanza-card .text-card h3 {
  text-align: center;
}

/* Center inner title for Nirvana card */
.nirvana-card h3 {
  text-align: center;
}

/* Slightly narrower text column for Stillness As Fullness */
.stanza-card .stanza-body {
  max-width: 40rem;   /* or 36rem if you want tighter */
  margin: 0 auto;
}

/* Interpretation category bar */

.interpretation-category-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem auto 1.25rem auto;
  justify-content: center;
}

.interpretation-category-btn {
  border: 1px solid #8FA7C7; /* mist blue */
  background: transparent;
  color: #ECEBE7; /* moon white */
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  transition:
    background 160ms ease-out,
    border-color 160ms ease-out,
    color 160ms ease-out,
    box-shadow 160ms ease-out;
}

.interpretation-category-btn.is-active {
  border-color: #F5DFA8; /* lunar gold */
  background: rgba(245, 223, 168, 0.12);
  color: #F5DFA8;
  box-shadow: 0 0 0 1px rgba(245, 223, 168, 0.18),
              0 6px 18px rgba(0, 0, 0, 0.35);
}

.interpretation-category-btn:focus-visible {
  outline: 2px solid #F5DFA8;
  outline-offset: 2px;
}

.room2-index-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
  z-index: 9998;
}

.room2-index-drawer {
  position: fixed;
  top: 0;
  right: 0;
  height: 100vh;
  width: min(420px, 92vw);
  background: rgba(10,10,10,0.98);
  border-left: 1px solid rgba(255,255,255,0.12);
  transform: translateX(100%);
  transition: transform 180ms ease;
  z-index: 9999;
  display: flex;
  flex-direction: column;
}

.room2-index-item.is-current {
  border-color: rgba(245,223,168,0.55);
  background: rgba(245,223,168,0.06);
}


.room2-index-blurb {
  margin-top: 6px;
  font-size: 12px;
  color: rgba(255,255,255,0.70);
  line-height: 1.35;
}


.room2-index-overlay.is-open {
  opacity: 1;
  pointer-events: auto;
}

.room2-index-drawer.is-open {
  transform: translateX(0);
}

.room2-index-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 14px 10px;
  border-bottom: 1px solid rgba(255,255,255,0.10);
}

.room2-index-title {
  font-size: 14px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.88);
}

.room2-index-close {
  background: transparent;
  color: rgba(255,255,255,0.82);
  border: 1px solid rgba(255,255,255,0.16);
  border-radius: 10px;
  padding: 6px 10px;
  cursor: pointer;
}

.room2-index-controls {
  padding: 12px 14px;
  border-bottom: 1px solid rgba(255,255,255,0.10);
}

.room2-index-search {
  width: 100%;
  padding: 10px 10px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.14);
  background: rgba(255,255,255,0.04);
  color: rgba(255,255,255,0.92);
  outline: none;
}

.room2-index-meta {
  margin-top: 8px;
  font-size: 12px;
  color: rgba(255,255,255,0.70);
}

.room2-index-list {
  padding: 10px 8px 14px;
  overflow: auto;
  flex: 1;
}

.room2-index-item {
  display: block;
  width: 100%;
  text-align: left;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 14px;
  padding: 10px 10px;
  margin: 8px 6px;
  cursor: pointer;
}

.room2-index-item:hover {
  border-color: rgba(255,255,255,0.22);
  background: rgba(255,255,255,0.03);
}

.room2-index-row {
  display: flex;
  gap: 10px;
  align-items: baseline;
  justify-content: space-between;
}

.room2-index-token {
  font-size: 12px;
  color: rgba(255,255,255,0.78);
}

.room2-index-cat {
  font-size: 11px;
  color: rgba(255,255,255,0.62);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.room2-index-titleline {
  margin-top: 6px;
  font-size: 13px;
  color: rgba(255,255,255,0.92);
  line-height: 1.35;
}



/* ===================== OpenSea Link – Room 2 ===================== */

/* Base OpenSea spacing for prose cards (My Life Journey, Zen Moon, Nirvana, etc.) */
.room2-opensea-wrapper {
  margin-top: 2.4rem;      /* space between signature and button */
  margin-bottom: 1.6rem;   /* space before card edge / next section */
  text-align: left;        /* align with prose text by default */
}

/* Button style */
.room2-opensea-link {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text", sans-serif;
  font-size: 0.9rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  text-decoration: none;

  padding: 0.45rem 0.9rem;
  border-radius: 999px;

  border: 1px solid #F5DFA8; /* Lunar Gold */
  color: #F5DFA8;
  background: transparent;

  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
}

.room2-opensea-link::before {
  content: "◆";
  font-size: 0.8rem;
}

.room2-opensea-link:hover {
  background: rgba(245, 223, 168, 0.08);
}

.room2-opensea-link:focus-visible {
  outline: 2px solid #F5DFA8;
  outline-offset: 2px;
}

/* Haiku sections (Illumination 2401, Awakening Light 2402):
   center under the pill, slightly tighter vertical rhythm */
.haiku-section .room2-opensea-wrapper {
  margin-top: 1.4rem;      /* closer to haiku pill */
  margin-bottom: 1.8rem;   /* gentle space before signature */
  text-align: center;      /* center under the haiku card */
}

/* Luminous Stillness – poem:
   center the button and reduce the gap before Foundational Writings */

   /* Luminous Stillness – button centered with tight stack */
/* Luminous Stillness – button tucked a bit closer to poem */
.stanza-luminous + .room2-opensea-wrapper {
  text-align: center;
  margin-top: 0.25rem;   /* closer to the bottom of the circle/poem */
  margin-bottom: 0.3rem;/* keep tight lead-in to Foundational Writings */
}

/* Entry section – tighter bottom padding so Foundational Writings sits closer */
.entry-section {
  padding-bottom: 1.6rem;
}

/* First section after Entry (Foundational Writings) – reduce top padding */
.entry-section + .section {
  padding-top: 2.2rem; /* was 4rem via .section */
}

.sig3-series {
  text-align: center;
  letter-spacing: 0.08em;
}
