/* AMSP 003 · H01.3 frosted-glass Opening Letter candidate. PRIVATE OWNER-REVIEW EXPERIMENT.
   Active only at /003/?candidate=h013 while Layout C is showing. Every selector requires
   .h01-host--c (removed for A/B by letter-cards-h011.js) AND .h01-host--h013 (added by letter-h013-frost.js).
   Builds on H01.2.1 (its seam + phone spacing classes are switched on by the same script) and overrides
   only where the translucent sheet needs it. Draft 009, cards, navigation and "Read as one page" untouched. */

/* ---------- 1 · Material: frosted vellum / acrylic instead of opaque paper ---------- */
.h01-host--c.h01-host--h013 .h01-letter{
  --c-paper-lit:linear-gradient(118deg,rgba(255,255,253,.64) 0%,rgba(255,254,246,.52) 46%,rgba(255,251,232,.44) 100%);
  --c-edge:rgba(255,255,255,.72);
  --c-under-1:rgba(255,255,250,.30);--c-under-2:rgba(255,255,248,.20);
  --c-stack:-3px 4px 0 -1px var(--c-under-1),-3px 4px 0 0 rgba(255,255,255,.42),-6px 8px 0 -2px var(--c-under-2),-6px 8px 0 -1px rgba(255,255,255,.30);
  --c-cast:-12px 22px 38px -22px rgba(74,50,18,.30),-2px 3px 10px rgba(74,50,18,.06);
  --c-frost:blur(16px) saturate(1.35) brightness(1.04);
  --c-text:#1d1623;           /* letter body + headings (not --c-ink: H01.1 uses that name for sheet ink opacity) */
}
.h01-host--c.h01-host--h013 .h01-letter.is-enhanced[data-layout="hybrid"] .h01-card,
.h01-host--c.h01-host--h013 .h01-letter[data-layout="full"] .h01-letter__track{
  background:var(--c-paper-lit);
  -webkit-backdrop-filter:var(--c-frost);backdrop-filter:var(--c-frost);
  border:1px solid var(--c-edge);border-radius:6px;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.85),inset 0 0 0 1px rgba(255,255,255,.22),inset 0 -1px 0 rgba(84,58,22,.05),var(--c-stack),var(--c-cast)}
/* active sheet: keep the H01.2.1 seam (resting on the next sheet), lighter for glass */
.h01-host--c.h01-host--h013 .h01-letter.is-enhanced[data-layout="hybrid"] .h01-card[data-h01-pos="active"]{
  box-shadow:inset 0 1px 0 rgba(255,255,255,.9),inset 0 0 0 1px rgba(255,255,255,.26),inset 0 -1px 0 rgba(84,58,22,.05),
   2px 0 2px rgba(91,65,36,.14),8px 1px 16px -8px rgba(91,65,36,.24),var(--c-stack),var(--c-cast)}
/* waiting / read sheets: thinner, clearer glass */
.h01-host--c.h01-host--h013 .h01-letter.is-enhanced[data-layout="hybrid"] .h01-card:not([data-h01-pos="active"]){
  background:linear-gradient(118deg,rgba(255,255,252,.40) 0%,rgba(255,252,238,.30) 100%);
  -webkit-backdrop-filter:blur(9px) saturate(1.2);backdrop-filter:blur(9px) saturate(1.2)}
.h01-host--c.h01-host--h013 .h01-letter.is-enhanced[data-layout="hybrid"] .h01-card[data-h01-pos="next"]{
  box-shadow:inset 0 1px 0 rgba(255,255,255,.7),-8px 14px 24px -18px rgba(74,50,18,.22)}
/* frost texture: the H01.1 grain, much finer in effect */
.h01-host--c.h01-host--h013 .h01-letter.is-enhanced[data-layout="hybrid"] .h01-card::before,
.h01-host--c.h01-host--h013 .h01-letter[data-layout="full"] .h01-letter__track::before{opacity:.07}
/* light catching the top-left of the sheet */
.h01-host--c.h01-host--h013 .h01-letter.is-enhanced[data-layout="hybrid"] .h01-card::after,
.h01-host--c.h01-host--h013 .h01-letter[data-layout="full"] .h01-card:first-child::after{
  content:"";position:absolute;inset:0;border-radius:inherit;pointer-events:none;z-index:0;
  background:linear-gradient(122deg,rgba(255,255,255,.42) 0%,rgba(255,255,255,.10) 26%,rgba(255,255,255,0) 44%)}
.h01-host--c.h01-host--h013 .h01-card__text,.h01-host--c.h01-host--h013 .h01-card__folio{position:relative;z-index:1}

/* ---------- 2 · Dark text on the light sheet ---------- */
.e003-review .h01-host--c.h01-host--h013 .h01-card__text p,
.e003-review .h01-host--c.h01-host--h013 .h01-card__title{color:var(--c-text)}
.h01-host--c.h01-host--h013 .h01-card__text strong{color:#22162a}
.h01-host--c.h01-host--h013 .h01-card__text em{color:#4a2b58}
.e003-review .h01-host--c.h01-host--h013 .h01-card__tagline strong{color:#462a54;border-color:rgba(70,42,84,.24)}
.h01-host--c.h01-host--h013 .h01-letter.is-enhanced[data-layout="hybrid"] .h01-card__folio{color:#4f3c59}
.h01-host--c.h01-host--h013 .h01-card__sig-name{color:#4a2b58}

/* ---------- 3 · Lemon and sheet: let the photograph show through ---------- */
/* desktop: the lemon sits a little further in, so more of it is behind the glass and more beside it */
@media(min-width:821px){
  .e003-review main>section.intro010.h01-host--c.h01-host--h013 .intro010__sun{right:clamp(-70px,1.2vw,40px)}
}
/* phones: the lemon rises behind the foot of the sheet; the controls ride on a small glass strip above it */
@media(max-width:820px){
  .e003-review .h01-host--c.h01-host--h013 .intro010__content{padding-bottom:calc(min(115vw,590px) * .8 * .5)}
  .h01-host--c.h01-host--h013 .h01-letter[data-layout="hybrid"] .h01-letter__controls{gap:4px}
  .e003-review .h01-host--c.h01-host--h013 .h01-letter__count{white-space:nowrap;margin:0 2px}
  .e003-review .h01-host--c.h01-host--h013 .h01-letter .h01-btn--mode{white-space:nowrap;padding:0 11px}
  .h01-host--c.h01-host--h013 .h01-letter__controls{padding:4px;border-radius:999px;
    background:rgba(255,252,238,.42);-webkit-backdrop-filter:blur(12px) saturate(1.3);backdrop-filter:blur(12px) saturate(1.3);
    box-shadow:inset 0 1px 0 rgba(255,255,255,.7),0 8px 20px -14px rgba(74,50,18,.35)}
}
@media(max-width:450px){
  .e003-review .h01-host--c.h01-host--h013 .intro010__content{padding-bottom:calc(120vw * .8 * .5)}
}
/* one-page mode keeps only "Read as cards": no empty glass strip behind it */
@media(max-width:820px){
  .h01-host--c.h01-host--h013 .h01-letter[data-layout="full"] .h01-letter__controls{background:none;-webkit-backdrop-filter:none;backdrop-filter:none;box-shadow:none;padding:0}
}

/* ---------- 4 · Ambient lemon movement: slow drift and float only ---------- */
@media(prefers-reduced-motion:no-preference){
  .e003-review main>section.intro010.h01-host--c.h01-host--h013 .intro010__sun{animation:h013-drift 26s ease-in-out infinite}
  .e003-review main>section.intro010.h01-host--c.h01-host--h013 .intro010__radiance{animation:h013-breathe 15s ease-in-out infinite}
}
@media(prefers-reduced-motion:no-preference) and (max-width:820px){
  .e003-review main>section.intro010.h01-host--c.h01-host--h013 .intro010__sun{animation:h013-drift-anchored 26s ease-in-out infinite}
}
@keyframes h013-drift{
  0%,100%{transform:translate(0,-50%) rotate(-1.2deg) scale(1)}
  25%{transform:translate(-6px,calc(-50% - 9px)) rotate(.3deg) scale(1.008)}
  50%{transform:translate(-2px,calc(-50% - 15px)) rotate(1.4deg) scale(1.012)}
  75%{transform:translate(5px,calc(-50% - 6px)) rotate(.2deg) scale(1.006)}}
@keyframes h013-drift-anchored{
  0%,100%{transform:translate(0,0) rotate(-1.2deg) scale(1)}
  25%{transform:translate(-5px,-8px) rotate(.3deg) scale(1.008)}
  50%{transform:translate(-2px,-13px) rotate(1.4deg) scale(1.012)}
  75%{transform:translate(4px,-5px) rotate(.2deg) scale(1.006)}}
@keyframes h013-breathe{0%,100%{opacity:1}50%{opacity:.86}}

/* ---------- Fallbacks ---------- */
/* no backdrop-filter support: a firmer sheet keeps the text readable */
@supports not ((backdrop-filter:blur(1px)) or (-webkit-backdrop-filter:blur(1px))){
  .h01-host--c.h01-host--h013 .h01-letter{--c-paper-lit:linear-gradient(118deg,rgba(255,253,244,.9),rgba(255,250,232,.86))}
  .h01-host--c.h01-host--h013 .h01-letter.is-enhanced[data-layout="hybrid"] .h01-card:not([data-h01-pos="active"]){background:rgba(252,246,224,.8)}
}
@media(prefers-reduced-transparency:reduce){
  .h01-host--c.h01-host--h013 .h01-letter{--c-paper-lit:linear-gradient(118deg,#fffcf1,#fff8e4)}
}
@media(forced-colors:active){.h01-host--c.h01-host--h013 .h01-card{background:Canvas!important;-webkit-backdrop-filter:none;backdrop-filter:none}}
