/* Halvermere Press: FALL seasonal layer. Loaded only when SEASON = "fall" (data/books.js).
   Decoration only: no text colors are changed below AA, and every ornament is aria-hidden.
   Assets: /img/season/fall/. To swap seasons, see SEASON.md. */
.season-fall{--s-accent:#A8512A;--s-accent-2:#B8862E;--s-wash:#F7EBD8}

/* Soft backgrounds */
.season-fall .band{background:linear-gradient(180deg,#F6EAD6 0%,var(--cream) 60%)}
.season-fall .intro{position:relative}
.season-fall .intro::after{content:"";position:absolute;right:20px;top:30px;width:190px;height:190px;
  background:url(/img/season/fall/leaf-oak.svg) no-repeat center/contain;opacity:.10;transform:rotate(-18deg);pointer-events:none;opacity:.16}
.season-fall .page-head{background:radial-gradient(ellipse at 90% 0%,#F3E2C6 0%,transparent 60%)}

/* Seasonal dividers: a small leaf rule above banded sections and the follow band */
.season-fall .band,.season-fall .follow{position:relative}
.season-fall .band::before,.season-fall .follow::before{content:"";position:absolute;left:50%;top:-16px;width:320px;height:32px;
  transform:translateX(-50%);background:url(/img/season/fall/divider.svg) no-repeat center/contain;pointer-events:none}
.season-fall .section-head{border-bottom-color:#D9BE93}

/* Carousel frame: falling leaves + pumpkins and acorns, behind the slide content */
.season-fall .carousel{overflow:hidden;border-bottom:4px solid #C26A1E}
.season-decor,.season-decor[hidden]{display:block;position:absolute;inset:0;pointer-events:none;z-index:1;overflow:hidden}
.season-fall .slide-inner{position:relative;z-index:2}
.season-decor .leaf{position:absolute;top:-70px;width:38px;height:38px;background:no-repeat center/contain;opacity:.8;
  animation:leaf-fall 16s linear infinite;filter:drop-shadow(0 2px 2px rgba(0,0,0,.25))}
.season-decor .leaf:nth-child(3n+1){background-image:url(/img/season/fall/leaf-maple.svg)}
.season-decor .leaf:nth-child(3n+2){background-image:url(/img/season/fall/leaf-oak.svg)}
.season-decor .leaf:nth-child(3n){background-image:url(/img/season/fall/leaf-burgundy.svg);opacity:.7}
.season-decor .leaf:nth-child(1){left:2%;animation-delay:-2s}
.season-decor .leaf:nth-child(2){left:8%;animation-delay:-9s;animation-duration:20s;width:46px;height:46px}
.season-decor .leaf:nth-child(3){left:14%;animation-delay:-13s;width:30px;height:30px}
.season-decor .leaf:nth-child(4){left:21%;animation-delay:-5s;animation-duration:22s}
.season-decor .leaf:nth-child(5){left:27%;animation-delay:-11s;width:32px;height:32px}
.season-decor .leaf:nth-child(6){left:34%;animation-delay:-1s;animation-duration:19s;width:44px;height:44px}
.season-decor .leaf:nth-child(7){left:40%;animation-delay:-15s}
.season-decor .leaf:nth-child(8){left:47%;animation-delay:-7s;animation-duration:24s;width:30px;height:30px}
.season-decor .leaf:nth-child(9){left:53%;animation-delay:-3s;width:42px;height:42px}
.season-decor .leaf:nth-child(10){left:59%;animation-delay:-12s;animation-duration:18s}
.season-decor .leaf:nth-child(11){left:65%;animation-delay:-6s;width:34px;height:34px}
.season-decor .leaf:nth-child(12){left:71%;animation-delay:-14s;animation-duration:21s;width:46px;height:46px}
.season-decor .leaf:nth-child(13){left:77%;animation-delay:-4s}
.season-decor .leaf:nth-child(14){left:83%;animation-delay:-10s;width:30px;height:30px}
.season-decor .leaf:nth-child(15){left:89%;animation-delay:-8s;animation-duration:23s;width:42px;height:42px}
.season-decor .leaf:nth-child(16){left:95%;animation-delay:-16s}
@keyframes leaf-fall{
  0%{transform:translate(0,0) rotate(0)}
  25%{transform:translate(22px,140px) rotate(80deg)}
  50%{transform:translate(-14px,280px) rotate(170deg)}
  75%{transform:translate(20px,420px) rotate(260deg)}
  100%{transform:translate(0,600px) rotate(350deg)}
}
.season-decor .pumpkin{position:absolute;right:1.5%;bottom:6px;width:170px;height:auto;filter:drop-shadow(0 6px 8px rgba(0,0,0,.35))}
.season-decor .pumpkin-small{right:calc(1.5% + 150px);width:96px;bottom:4px}
.season-decor .acorn{position:absolute;right:calc(1.5% + 238px);bottom:8px;width:50px;height:auto;transform:rotate(-14deg);filter:drop-shadow(0 4px 5px rgba(0,0,0,.3))}
.season-decor .acorn-2{right:calc(1.5% + 280px);bottom:4px;width:38px;transform:rotate(18deg)}

/* Pumpkins near section headers and in the footer */
.season-fall .section-head h2::after{content:"";display:inline-block;width:44px;height:36px;margin-left:14px;vertical-align:-2px;
  background:url(/img/season/fall/pumpkin.svg) no-repeat center/contain}
.season-fall .page-head .display::after{content:"";display:inline-block;width:34px;height:46px;margin-left:12px;vertical-align:0;
  background:url(/img/season/fall/acorn.svg) no-repeat center/contain}
.season-fall .site-footer{position:relative;border-top:4px solid #C26A1E}
.season-fall .site-footer::after{content:"";position:absolute;right:3%;top:-46px;width:190px;height:60px;pointer-events:none;
  background:url(/img/season/fall/acorn.svg) no-repeat 0 100%/34px auto,url(/img/season/fall/pumpkin.svg) no-repeat 44px 100%/76px auto,url(/img/season/fall/acorn.svg) no-repeat 128px 100%/28px auto,url(/img/season/fall/leaf-maple.svg) no-repeat 160px 70%/28px auto}

/* Warmer amber/rust accents (text contrast >= 4.5:1 on every button) */
.season-fall .btn-primary{background:#8A3B12;color:#FFF8EC}
.season-fall .btn-primary:hover{background:#6B2C0B;color:#fff}
.season-fall .btn-quiet{border-color:#B5651D}
.season-fall .tag[aria-pressed="true"]{background:#8A3B12;border-color:#8A3B12;color:#FFF8EC}
.season-fall .band{background:linear-gradient(180deg,#F5DDBA 0%,#F7E9D2 55%,var(--cream) 100%)}
.season-fall .section-head{border-bottom:2px solid #D08A3C}
.season-fall .kicker{color:#8A3B12}
.season-fall .follow{background:linear-gradient(180deg,#2A2433,#1F2A44)}

@media (max-width:700px){
  .season-decor .pumpkin{width:92px;bottom:4px;right:3%}
  .season-decor .pumpkin-small{width:56px;right:calc(3% + 82px)}
  .season-decor .acorn{right:calc(3% + 136px);width:30px}
  .season-decor .acorn-2{display:none}
  .season-decor .leaf:nth-child(n+11){display:none}
  .season-decor .leaf{width:30px;height:30px}
  .season-fall .intro::after{width:90px;height:90px;top:24px;opacity:.1}
  .season-fall .section-head h2::after{width:32px;height:26px}
  .season-fall .site-footer::after{transform:scale(.75);transform-origin:100% 100%}
}
@media (prefers-reduced-motion:reduce){
  .season-decor .leaf{animation:none}
  .season-decor .leaf:nth-child(odd){top:10%}
  .season-decor .leaf:nth-child(even){top:62%}
  .season-decor .leaf:nth-child(4n){top:36%}
}

/* More leaves (24 in the carousel; 17-24 reuse positions offset in time) + page-wide drift */
.season-decor .leaf:nth-child(n+17){animation-duration:25s;opacity:.65}
.season-decor .leaf:nth-child(17){left:5%;animation-delay:-20s}.season-decor .leaf:nth-child(18){left:18%;animation-delay:-3s}
.season-decor .leaf:nth-child(19){left:31%;animation-delay:-17s}.season-decor .leaf:nth-child(20){left:44%;animation-delay:-11s}
.season-decor .leaf:nth-child(21){left:57%;animation-delay:-22s}.season-decor .leaf:nth-child(22){left:69%;animation-delay:-8s}
.season-decor .leaf:nth-child(23){left:80%;animation-delay:-19s}.season-decor .leaf:nth-child(24){left:92%;animation-delay:-13s}
.season-drift{position:fixed;inset:0;pointer-events:none;z-index:0;overflow:hidden}
.season-fall main{position:relative;z-index:1}
.season-fall .season-drift span{position:absolute;top:-50px;width:26px;height:26px;opacity:.38;background:url(/img/season/fall/leaf-maple.svg) no-repeat center/contain;animation:drift 26s linear infinite;will-change:transform}
.season-fall .season-drift span:nth-child(even){background-image:url(/img/season/fall/leaf-oak.svg);animation-duration:32s}
.season-fall .season-drift span:nth-child(3n){background-image:url(/img/season/fall/leaf-burgundy.svg);opacity:.3}
.season-fall .season-drift span:nth-child(1){left:3%;animation-delay:-4s}.season-fall .season-drift span:nth-child(2){left:13%;animation-delay:-18s}.season-fall .season-drift span:nth-child(3){left:24%;animation-delay:-9s}
.season-fall .season-drift span:nth-child(4){left:36%;animation-delay:-25s}.season-fall .season-drift span:nth-child(5){left:47%;animation-delay:-13s}.season-fall .season-drift span:nth-child(6){left:58%;animation-delay:-2s}
.season-fall .season-drift span:nth-child(7){left:69%;animation-delay:-21s}.season-fall .season-drift span:nth-child(8){left:79%;animation-delay:-7s}.season-fall .season-drift span:nth-child(9){left:88%;animation-delay:-16s}.season-fall .season-drift span:nth-child(10){left:96%;animation-delay:-11s}
@keyframes drift{0%{transform:translate(0,0) rotate(0)}25%{transform:translate(40px,28vh) rotate(90deg)}50%{transform:translate(-20px,55vh) rotate(180deg)}75%{transform:translate(36px,82vh) rotate(270deg)}100%{transform:translate(0,110vh) rotate(360deg)}}

/* Wobbling pumpkins */
.season-decor .pumpkin{transform-origin:50% 100%;animation:wobble 4s ease-in-out infinite}
.season-decor .pumpkin-small{animation-duration:3.3s;animation-delay:-1s}
.season-fall .section-head h2::after{transform-origin:50% 100%;animation:wobble 3.6s ease-in-out infinite}
@keyframes wobble{0%,100%{transform:rotate(0)}20%{transform:rotate(-5deg)}40%{transform:rotate(4deg)}60%{transform:rotate(-2deg)}80%{transform:rotate(1deg)}}
@media (max-width:700px){.season-fall .season-drift span:nth-child(n+7){display:none}}
@media (prefers-reduced-motion:reduce){.season-drift{display:none}.season-decor .pumpkin,.season-fall .section-head h2::after{animation:none}}
@media print{.season-drift{display:none}}

@media print{.season-decor,.season-fall .intro::after{display:none}}

.slide{position:relative;overflow:hidden}
.slide-holiday .decor-fall,.slide-holiday .leaf{display:none!important}
