/* DREAMSPIRE 3.1 — Compact chapter navigation; one destination per click. */
body.ds-v3.ds-compact .panel:not(.active){display:none!important}
body.ds-v3.ds-compact:not(.ds-home-active) .ds-about{display:none!important}
body.ds-v3.ds-compact .ds-manifesto{display:none!important}
/* Viewport-sized chapters on desktop; only published media adds intentional scrolling. */
body.ds-v3.ds-compact .panel.home{min-height:min(670px,calc(100svh - 80px));max-height:none}
body.ds-v3.ds-compact .home-content{padding:clamp(36px,5vw,74px) clamp(30px,5.3vw,96px)}
body.ds-v3.ds-compact .hero-photo{min-height:480px;max-height:730px}
body.ds-v3.ds-compact .ds-hero-number{margin-bottom:clamp(14px,3vh,31px)}
body.ds-v3.ds-compact .home h1{font-size:clamp(62px,6vw,108px);margin:11px 0 22px}
body.ds-v3.ds-compact .home-tagline{font-size:clamp(23px,2.25vw,34px);margin-bottom:13px}
body.ds-v3.ds-compact .home-desc{line-height:1.55;margin-bottom:24px}
body.ds-v3.ds-compact .ds-about{padding:35px clamp(24px,6vw,110px);gap:25px;grid-template-columns:minmax(0,1fr) minmax(0,1.35fr)}
body.ds-v3.ds-compact .ds-about-left{gap:8px}
body.ds-v3.ds-compact .ds-about-title{font-size:clamp(26px,3vw,44px)}
body.ds-v3.ds-compact .ds-about-right{gap:5px}
body.ds-v3.ds-compact .ds-about-right p{font-size:clamp(12px,1vw,15px);line-height:1.5}
body.ds-v3.ds-compact .ds-about-foot,body.ds-v3.ds-compact .ds-about-copy2{display:none}
body.ds-v3.ds-compact .chapter-panel{min-height:min(610px,calc(100svh - 80px))}
body.ds-v3.ds-compact .chapter-panel .chapter-copy{min-height:525px;padding:38px clamp(26px,5vw,92px);gap:12px}
body.ds-v3.ds-compact .chapter-copy h2{font-size:clamp(45px,4.4vw,74px)}
body.ds-v3.ds-compact .chapter-picture{min-height:525px;height:auto}
body.ds-v3.ds-compact .care,body.ds-v3.ds-compact .care .chapter-copy,body.ds-v3.ds-compact .faq-card,body.ds-v3.ds-compact .hello,body.ds-v3.ds-compact .hello .chapter-copy{min-height:0}
body.ds-v3.ds-compact .faq-card{padding:35px clamp(25px,4.4vw,82px)}
body.ds-v3.ds-compact .ds-faq-list summary{padding:14px 30px 14px 0;font-size:clamp(16px,1.3vw,20px)}
body.ds-v3.ds-compact .ds-faq-list summary:after{top:11px}
body.ds-v3.ds-compact .ds-faq-list details p{padding-bottom:16px;line-height:1.5}
body.ds-v3.ds-compact .hello-form{margin:24px 0;padding:25px 36px;gap:8px}
body.ds-v3.ds-compact .hello-form textarea{min-height:74px}
body.ds-v3.ds-compact .studio-public-section{padding:24px clamp(20px,5vw,82px) 35px}
body.ds-v3.ds-compact .studio-public-section>h2{font-size:clamp(26px,3vw,42px)}
body.ds-v3.ds-compact .studio-public-section>p{margin:0 0 15px}
/* Swipe through published photos and profiles instead of endless rows. */
body.ds-v3.ds-compact .studio-public-grid{display:grid;grid-auto-flow:column;grid-auto-columns:minmax(190px,min(26vw,290px));grid-template-columns:none;overflow-x:auto;overscroll-behavior-inline:contain;scroll-snap-type:x mandatory;scrollbar-width:thin;padding-bottom:12px;gap:16px}
body.ds-v3.ds-compact .studio-public-card{scroll-snap-align:start}
body.ds-v3.ds-compact .studio-public-card img,body.ds-v3.ds-compact .studio-public-card video{height:210px}
body.ds-v3.ds-compact .footer{padding-block:22px;min-height:0}
body.ds-v3.ds-compact .ds-bottom-rail{padding-block:12px}
@media(max-width:850px){
 body.ds-v3.ds-compact .panel.home{min-height:0}
 body.ds-v3.ds-compact .hero-photo{min-height:0;max-height:none;height:clamp(260px,54vw,475px)}
 body.ds-v3.ds-compact .home-content{padding:42px 30px 38px}
 body.ds-v3.ds-compact .ds-about{padding:25px 30px}
 body.ds-v3.ds-compact .chapter-panel .chapter-copy{min-height:430px;padding:35px}
 body.ds-v3.ds-compact .chapter-picture{min-height:430px}
}
@media(max-width:650px){
 body.ds-v3.ds-compact .panel.home{display:grid;grid-template-columns:1fr;grid-template-rows:auto auto}
 body.ds-v3.ds-compact .home-content{padding:30px 22px 25px}
 body.ds-v3.ds-compact .ds-hero-number{margin-bottom:13px}
 body.ds-v3.ds-compact .home h1{font-size:clamp(54px,13.2vw,77px);margin:10px 0 13px}
 body.ds-v3.ds-compact .home-tagline{font-size:clamp(23px,5.6vw,30px);margin-bottom:8px}
 body.ds-v3.ds-compact .home-desc{font-size:12px;line-height:1.5;margin-bottom:15px}
 body.ds-v3.ds-compact .hero-photo{height:58vw;min-height:210px;max-height:340px}
 body.ds-v3.ds-compact .ds-about{padding:23px 22px;grid-template-columns:1fr;gap:8px}
 body.ds-v3.ds-compact .ds-about-left{gap:5px}
 body.ds-v3.ds-compact .ds-about-title{font-size:32px}
 body.ds-v3.ds-compact .ds-about-right p{font-size:12px}
 body.ds-v3.ds-compact .chapter-panel{grid-template-columns:1fr;grid-template-rows:auto auto;min-height:0}
 body.ds-v3.ds-compact .chapter-panel .chapter-copy,body.ds-v3.ds-compact .diaries .chapter-copy{grid-column:1;grid-row:1;min-height:0;padding:32px 24px 25px;gap:8px}
 body.ds-v3.ds-compact .chapter-copy h2{font-size:clamp(46px,10vw,64px);margin:0}
 body.ds-v3.ds-compact .chapter-copy>p:not(.kicker){font-size:12px;line-height:1.5}
 body.ds-v3.ds-compact .chapter-panel .chapter-picture,body.ds-v3.ds-compact .diaries .chapter-picture{grid-column:1;grid-row:2;min-height:0;height:73vw;max-height:380px}
 body.ds-v3.ds-compact .faq-card{grid-column:1;grid-row:2;padding:8px 25px 32px}
 body.ds-v3.ds-compact .ds-faq-list summary{font-size:16px}
 body.ds-v3.ds-compact .hello-form{grid-column:1;grid-row:2;width:calc(100% - 40px);margin:0 auto 28px;padding:22px}
 body.ds-v3.ds-compact .studio-public-section{padding:20px 18px 30px}
 body.ds-v3.ds-compact .studio-public-grid{grid-auto-columns:minmax(190px,71vw);gap:12px}
 body.ds-v3.ds-compact .studio-public-card img,body.ds-v3.ds-compact .studio-public-card video{height:210px}
}
@media(prefers-reduced-motion:reduce){body.ds-v3.ds-compact .panel{animation:none!important}}

/* Dreamspire 3.2: direct inquiries */
body.ds-v3.ds-compact #hello-form .ds-contact-privacy{line-height:1.5;color:#647083}
body.ds-v3.ds-compact #hello-form button:disabled{opacity:.65;cursor:wait}
body.ds-v3.ds-compact #hello-form #hello-result{display:block;min-height:1.6em;overflow-wrap:anywhere}

/* Dreamspire 3.3: selected reply channel, clear input labels and responsive form. */
body.ds-v3.ds-compact .ds-contact-fields{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.3fr);gap:12px;align-items:end}
body.ds-v3.ds-compact .ds-contact-fields label{min-width:0;display:flex;flex-direction:column;gap:7px}
body.ds-v3.ds-compact .ds-contact-fields input,body.ds-v3.ds-compact .ds-contact-fields select{min-width:0;width:100%}
body.ds-v3.ds-compact .ds-contact-hint{font-size:12px;line-height:1.45;color:#647083}
body.ds-v3.ds-compact .ds-contact-fields input:disabled{opacity:.55;cursor:not-allowed}
@media(max-width:640px){body.ds-v3.ds-compact .ds-contact-fields{grid-template-columns:1fr;gap:7px}body.ds-v3.ds-compact .ds-contact-hint{font-size:11px}}

/* Dreamspire 3.3.2: The bundled sofa portrait displays immediately without Firebase.
   The cream tone is retained behind the photo during the brief network transfer. */
body.ds-v3.ds-compact .panel.home{background:#f6f3ee}

/* Dreamspire 3.3.4: Dreamers chapter photo fills its frame (no letterboxing).
   This intentionally crops the outside edges on mismatched photo ratios.
   Scope only to Dreamers: do not alter the sofa hero, Diaries, or other photos. */
body.ds-v3.ds-compact #panel-kittens .chapter-picture > img {
  object-fit: cover;
  object-position: center 43%;
  background: transparent;
}
body.ds-v3.ds-compact #panel-kittens .chapter-picture:hover > img {
  transform: none;
}

/* Dreamspire 3.3.5: show the entire original Diaries photo, without a text overlay.
   The caption has its own row beneath the image. Keep the full frame across sizes. */
body.ds-v3.ds-compact #panel-diaries .diary-picture {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr) auto;
  align-items: stretch;
  background: #e8e4df;
}
body.ds-v3.ds-compact #panel-diaries .diary-picture > #diary-img {
  position: relative;
  inset: auto;
  grid-column: 1;
  grid-row: 1;
  display: block;
  min-width: 0;
  min-height: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center center;
  transform: none;
  background: #e8e4df;
}
body.ds-v3.ds-compact #panel-diaries .diary-picture:hover > #diary-img {
  transform: none;
}
body.ds-v3.ds-compact #panel-diaries .diary-caption {
  position: relative;
  grid-column: 1;
  grid-row: 2;
  inset: auto;
  left: auto;
  right: auto;
  bottom: auto;
  width: 100%;
  min-width: 0;
  margin: 0;
  padding: 13px clamp(17px, 2.3vw, 30px) 16px;
  border-radius: 0;
  background: #fffaf4;
  backdrop-filter: none;
}
body.ds-v3.ds-compact #panel-diaries .photo-open {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 5;
}
@media (max-width:650px) {
  body.ds-v3.ds-compact #panel-diaries .diary-picture {
    height: auto;
    max-height: none;
    min-height: 0;
    grid-template-rows: minmax(240px, 65vw) auto;
  }
  body.ds-v3.ds-compact #panel-diaries .diary-picture > #diary-img {
    height: 100%;
  }
  body.ds-v3.ds-compact #panel-diaries .diary-caption {
    padding: 12px 18px 15px;
  }
}

/* Dreamspire 3.3.6: Never flash the obsolete illustrative Dreamers cat.
   The selected Studio image is preloaded and revealed only after it is ready. */
body.ds-v3.ds-compact #panel-kittens .chapter-picture {
  background:#f2eeea;
}
body.ds-v3.ds-compact #panel-kittens .chapter-picture::before {
  content:'Loading Dreamspire photo…';
  position:absolute;inset:0;display:grid;place-items:center;
  padding:24px;text-align:center;color:#58677a;
  font:500 13px/1.5 'DM Sans',system-ui,sans-serif;
  z-index:0;pointer-events:none;
}
body.ds-v3.ds-compact #panel-kittens .chapter-picture.ds-image-unavailable::before {
  content:'Photo unavailable right now';
}
body.ds-v3.ds-compact #panel-kittens .chapter-picture.ds-image-ready::before {
  display:none;
}
body.ds-v3.ds-compact #panel-kittens .chapter-picture > img {
  visibility:hidden;opacity:0;transform:none!important;transition:none!important;
  object-fit:cover;object-position:center 43%;
}
body.ds-v3.ds-compact #panel-kittens .chapter-picture.ds-image-ready > img {
  visibility:visible;opacity:1;
}

/* Dreamspire 3.3.7: Do not flash a different embedded/illustrative diary cat.
   Actual published diary media is used; browser cache makes repeat visits quicker. */
body.ds-v3.ds-compact #panel-diaries .diary-picture > #diary-img {
  visibility:hidden; opacity:0; transition:none!important;
}
body.ds-v3.ds-compact #panel-diaries .diary-picture.ds-diary-ready > #diary-img {
  visibility:visible; opacity:1;
}
