/* 节日装扮（skin.js）：<html data-skin="birthday|christmas|newyear|spring|valentine|…">，只在那几天有。
   只是装扮：顶栏下沿挂的一串、头像戴的、首页底片上的，都点不到、不盖字；读全文的页面不装扮。
   节日的颜色只换首页的签名和大字（--sun 还管着分类的颜色，不动它） */
:root[data-skin="birthday"] { --sk: #e2557f; --sk-soft: #ffe2eb; }
:root[data-skin="christmas"] { --sk: #c8372d; --sk-soft: #fde4e0; }
:root[data-skin="newyear"] { --sk: #b5831f; --sk-soft: #f9eed4; }
:root[data-skin="spring"] { --sk: #cc2b2b; --sk-soft: #fde2da; }
:root[data-skin="valentine"] { --sk: #cf3a5a; --sk-soft: #fde3e8; }
:root[data-skin="yuanxiao"] { --sk: #cf4a2a; --sk-soft: #fde6d6; }
:root[data-skin="duanwu"] { --sk: #2f7a4a; --sk-soft: #e2f1e3; }
:root[data-skin="qixi"] { --sk: #c4507a; --sk-soft: #fbe3ec; }
:root[data-skin="midautumn"] { --sk: #b07d1e; --sk-soft: #fbf0d6; }
:root[data-theme="dark"][data-skin="birthday"] { --sk: #ff8fb0; --sk-soft: rgba(255, 143, 176, .1); }
:root[data-theme="dark"][data-skin="christmas"] { --sk: #ff6f61; --sk-soft: rgba(255, 111, 97, .1); }
:root[data-theme="dark"][data-skin="newyear"] { --sk: #f2c35b; --sk-soft: rgba(242, 195, 91, .1); }
:root[data-theme="dark"][data-skin="spring"] { --sk: #ff6655; --sk-soft: rgba(255, 102, 85, .11); }
:root[data-theme="dark"][data-skin="valentine"] { --sk: #ff8aa3; --sk-soft: rgba(255, 138, 163, .1); }
:root[data-theme="dark"][data-skin="yuanxiao"] { --sk: #ff9a5e; --sk-soft: rgba(255, 154, 94, .1); }
:root[data-theme="dark"][data-skin="duanwu"] { --sk: #7fd18f; --sk-soft: rgba(127, 209, 143, .1); }
:root[data-theme="dark"][data-skin="qixi"] { --sk: #f39cc0; --sk-soft: rgba(243, 156, 192, .1); }
:root[data-theme="dark"][data-skin="midautumn"] { --sk: #f5c86a; --sk-soft: rgba(245, 200, 106, .1); }
:root[data-skin] .kicker, :root[data-skin] .film-title span:last-child { color: var(--sk); }
:root[data-skin] .film { --hero-glow: var(--sk-soft); }

/* ── 顶栏下沿挂的一串 ── */
.skin-garland { position: absolute; left: 0; right: 0; top: 100%; height: 60px; overflow: hidden; pointer-events: none; }
.skin-garland svg { display: block; overflow: visible; }
/* 生日：三角彩旗和卷曲的飘带 */
.sk-string { fill: none; stroke: var(--ink-3); stroke-width: .8; }
.sk-flag { stroke: rgba(21, 23, 27, .16); stroke-width: .5; stroke-linejoin: round; }
.sk-flag.f1 { fill: #f59fb8; } .sk-flag.f2 { fill: #8fd3b6; } .sk-flag.f3 { fill: #ffd36b; } .sk-flag.f4 { fill: #7fc4dc; } .sk-flag.f5 { fill: #ffb38a; }
.sk-ribbon { fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transform-box: fill-box; transform-origin: 50% 0; animation: sk-sway 3.4s ease-in-out infinite alternate; }
.sk-ribbon.r0 { stroke: #f59fb8; } .sk-ribbon.r1 { stroke: #7fc4dc; animation-delay: -1.2s; } .sk-ribbon.r2 { stroke: #ffd36b; animation-delay: -2.1s; }
@keyframes sk-sway { from { transform: rotate(-4deg); } to { transform: rotate(4deg); } }
/* 圣诞：红绿彩带、一闪一闪的小灯（灯的颜色 .b1–.b4 和页底小屋那串一样） */
.sk-tinsel { fill: none; stroke: #2f7a52; stroke-width: 4.5; stroke-linecap: round; }
.sk-tinsel-r { fill: none; stroke: #d23a2c; stroke-width: 2.2; stroke-linecap: round; stroke-dasharray: 3 5; }
.sk-cap { fill: #7a7f86; }
.sk-bulb { animation: sk-tw 1.8s ease-in-out infinite alternate; animation-delay: calc(var(--i) * -.37s); }
@keyframes sk-tw { from { opacity: 1; } to { opacity: .45; } }
:root[data-theme="dark"] .sk-bulb { filter: drop-shadow(0 0 2px rgba(255, 236, 190, .95)); }
/* 跨年：金、银飘带和小星 */
.sk-gold, .sk-silver { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.sk-gold { stroke: #d6a43a; stroke-width: 2.4; }
.sk-silver { stroke: #aeb9c4; stroke-width: 2; }
.sk-twinkle { fill: #f2c35b; animation: sk-tw 1.6s ease-in-out infinite alternate; }
:root[data-theme="dark"] .sk-gold, :root[data-theme="dark"] .sk-twinkle { filter: drop-shadow(0 0 2px rgba(255, 214, 120, .7)); }
/* 春节：两只红灯笼（和页底小屋门边那只一样） */
.sk-swing { transform-box: fill-box; transform-origin: 50% 0; animation: sk-swing 3.2s ease-in-out infinite alternate; }
@keyframes sk-swing { from { transform: rotate(-5deg); } to { transform: rotate(5deg); } }
.sk-lstring { stroke: #8a5a2b; stroke-width: 1; }
.sk-lbody { fill: #d8342b; stroke: rgba(80, 10, 0, .5); stroke-width: .8; }
.sk-lrib { fill: none; stroke: #a5231c; stroke-width: .8; }
.sk-lcap { fill: #e0a63a; }
.sk-tassel { fill: none; stroke: #e0a63a; stroke-width: 1; stroke-linecap: round; }
:root[data-theme="dark"] .sk-lbody { fill: #ef4a36; filter: drop-shadow(0 0 4px rgba(255, 110, 70, .7)); }
/* 中秋：几枝桂花，细枝、深绿的长叶、一簇簇金黄的小花 */
.sk-otwig { fill: none; stroke: #7a5a3a; stroke-width: 1.1; stroke-linecap: round; }
.sk-oleaf { fill: #2f6b45; stroke: #1f4a30; stroke-width: .4; }
.sk-osm { fill: #f2b33d; } .sk-osm.b { fill: #e89a2a; }
:root[data-theme="dark"] .sk-oleaf { fill: #4f8a5f; } :root[data-theme="dark"] .sk-osm { fill: #ffc65a; filter: drop-shadow(0 0 1.5px rgba(255, 200, 90, .8)); }
/* 七夕：一串喜鹊飞过（黑背白肚，夜里描一道浅边才看得见），翅膀一上一下，轻轻起伏 */
.sk-fly { animation: sk-fly 2.6s ease-in-out infinite alternate; animation-delay: calc(var(--i) * -.7s); }
@keyframes sk-fly { from { transform: translateY(-1.4px); } to { transform: translateY(1.4px); } }
.sk-mbody, .sk-mtail { fill: #1d2530; }
.sk-mtail { fill: #2f5f78; }
.sk-mbelly { fill: #fffdf8; }
.sk-mwing { fill: none; stroke: #fffdf8; stroke-width: .9; stroke-linecap: round; }
.sk-mbeak { fill: #1d2530; }
.sk-meye { fill: #fff; }
.sk-twinkle.qx { fill: #e8a3bd; }
:root[data-theme="dark"] .sk-mbody, :root[data-theme="dark"] .sk-mtail, :root[data-theme="dark"] .sk-mbeak { fill: #2a3646; stroke: rgba(225, 235, 245, .75); stroke-width: .5; }
:root[data-theme="dark"] .sk-twinkle.qx { fill: #fff3c4; }
/* 端午：五彩绳（五股颜色一段一段错开，像拧在一起）、两头倒挂的艾草和菖蒲 */
.sk-wc { fill: none; stroke-width: 2.4; stroke-dasharray: 3 12; }
.sk-wc.c1 { stroke: #2f6fd1; } .sk-wc.c2 { stroke: #d8342b; } .sk-wc.c3 { stroke: #f2b33d; } .sk-wc.c4 { stroke: #f4efe4; } .sk-wc.c5 { stroke: #2b2b2b; }
:root[data-theme="dark"] .sk-wc.c5 { stroke: #8b96a0; }
.sk-htie { fill: none; stroke: #c8283c; stroke-width: 1.2; }
.sk-hknot { fill: #d8342b; }
.sk-pu { fill: none; stroke: #3d7a3a; stroke-width: 2.2; stroke-linecap: round; }
.sk-ai { fill: #7d9a6a; stroke: #4f6b41; stroke-width: .5; }
:root[data-theme="dark"] .sk-pu { stroke: #5fa35a; } :root[data-theme="dark"] .sk-ai { fill: #93b082; }
/* 元宵：一根红绳上一串小灯笼，红的、金的相间（灯笼画法和春节那两只一样） */
.sk-cord { fill: none; stroke: #b3312a; stroke-width: 1; }
.sk-lbody.gold { fill: #f2b33d; stroke: rgba(120, 70, 0, .5); }
:root[data-theme="dark"] .sk-lbody.gold { fill: #ffc65a; filter: drop-shadow(0 0 4px rgba(255, 200, 90, .7)); }
/* 情人节：一根细藤上开着玫瑰（头像耳边那朵用同一套颜色） */
.sk-vine { fill: none; stroke: #4f8a5a; stroke-width: 1.2; stroke-linecap: round; }
.sk-vleaf { fill: #3f8a57; stroke: #24583a; stroke-width: .4; }
.sk-vrose { fill: #d2304a; stroke: #7d1020; stroke-width: .5; }
.sk-vrose.r2 { fill: #e9708a; stroke: #9c2c46; } .sk-vrose.r3 { fill: #b81f3a; }
.sk-vswirl { fill: none; stroke: #7d1020; stroke-width: .75; stroke-linecap: round; }
.sk-vrose.r2 + .sk-vswirl { stroke: #a13552; }
:root[data-theme="dark"] .sk-vrose { filter: drop-shadow(0 0 2px rgba(255, 120, 150, .55)); }

/* ── 头像戴的：顶栏的头像、节日相册最后一页的头像（fest.css .pt-me）共用这一套 ── */
:root[data-skin] nav.top .brand { position: relative; }
.skin-hat { position: absolute; left: 0; top: calc(50% - 16px); width: 32px; height: 32px; pointer-events: none; }
@media (max-width: 640px) { .skin-hat { top: calc(50% - 14px); width: 28px; height: 28px; } }
.sk-hat { display: block; width: 100%; height: 100%; overflow: visible; }
.sk-crown { fill: #ffd24d; stroke: #8a5a10; stroke-width: .7; stroke-linejoin: round; }
.sk-band { fill: #f4b632; }
.sk-gem.g1 { fill: #f2557f; } .sk-gem.g2 { fill: #59b8ff; } .sk-gem.g3 { fill: #4fcf86; }
.sk-tip { fill: #fff3b0; stroke: #8a5a10; stroke-width: .5; }
.sk-santa { fill: #d8342b; stroke: #6b120c; stroke-width: .6; stroke-linejoin: round; }
.sk-fur { fill: #fffdf8; stroke: rgba(21, 23, 27, .35); stroke-width: .5; }
.sk-party { fill: #f2c35b; stroke: #8a5a10; stroke-width: .6; stroke-linejoin: round; }
.sk-party-s { fill: none; stroke: #fff6d6; stroke-width: 1.4; stroke-linecap: round; }
.sk-star { fill: #fff0a8; stroke: #8a5a10; stroke-width: .4; stroke-linejoin: round; }
.sk-petal { fill: #e0302a; stroke: #8a1410; stroke-width: .4; }
.sk-heart { fill: #ffd34d; }
.sk-bead { stroke: #e0a63a; stroke-width: .7; }
.sk-eband { fill: none; stroke: #f4b6c8; stroke-width: 1.6; stroke-linecap: round; }
.sk-ear { fill: #fffdf8; stroke: rgba(21, 23, 27, .4); stroke-width: .5; }
.sk-ear-in { fill: #f7b6c8; }
.sk-xcord { fill: none; stroke: #2f6fd1; stroke-width: .8; stroke-linecap: round; }
.sk-xnang { fill: #d8342b; stroke: #7d1010; stroke-width: .5; }
.sk-xflower { fill: #f2c14e; stroke: #b8862a; stroke-width: .4; }
.sk-xtassel { fill: none; stroke: #e0a63a; stroke-width: .8; stroke-linecap: round; }
.sk-rbody { fill: #fffaf2; stroke: #a5231c; stroke-width: .5; }
.sk-rstripe { fill: none; stroke: #e0412f; stroke-width: .8; stroke-linecap: round; }
.sk-rear { fill: #fffaf2; stroke: #a5231c; stroke-width: .5; }
.sk-reye { fill: #e0302a; }
.sk-rwheel { fill: #e0a63a; stroke: #8a5a10; stroke-width: .4; }
:root[data-theme="dark"] .sk-yuanxiao { filter: drop-shadow(0 0 3px rgba(255, 190, 110, .8)); }

/* ── 首页底片 ── */
/* 圣诞：每格顶上一道红，连起来是缠在底片上的红丝带，第一格打个蝴蝶结 */
:root[data-skin="christmas"] .film-cell { box-shadow: inset 0 5px 0 #c8372d; }
.skin-bow { position: absolute; z-index: 2; left: -8px; top: -13px; width: 46px; pointer-events: none; }
.skin-bow svg { display: block; width: 100%; }
.sk-bow { fill: #d8342b; stroke: #7a1610; stroke-width: .8; stroke-linejoin: round; }
/* 生日：最后那格空底片，插一支蜡烛，写「今天」——这一格从今天开始拍 */
.skin-today { position: absolute; left: 0; right: 0; top: 36%; display: grid; justify-items: center; gap: 6px; pointer-events: none; color: #fff3e2; font: 600 11px/1 var(--mono); letter-spacing: .24em; }
.skin-today svg { width: 13px; height: 24px; overflow: visible; }
.sk-flame { fill: #ffb547; transform-box: fill-box; transform-origin: 50% 100%; animation: sk-flick 1.2s ease-in-out infinite alternate; filter: drop-shadow(0 0 3px rgba(255, 190, 90, .9)); }
@keyframes sk-flick { from { transform: scale(1, 1); } to { transform: scale(.88, 1.1); } }
.sk-stick { fill: #f59fb8; }
.sk-stripe { fill: none; stroke: #fff; stroke-width: 1.1; }
:root[data-skin="birthday"] .film-frame.blank .film-shot .mono { transform: translateY(26px); } /* 「下一站 →」让到蜡烛底下 */
/* 春节：两朵红剪纸雪花（窗花），贴在首页右上 */
:root[data-skin="spring"] .page.film { position: relative; }
.skin-cut { position: absolute; z-index: 0; width: 56px; pointer-events: none; }
.skin-cut.a { right: calc(var(--pad) + 6px); top: 14px; transform: rotate(8deg); }
.skin-cut.b { right: calc(var(--pad) + 66px); top: 62px; width: 34px; transform: rotate(-14deg); }
.skin-cut svg { display: block; width: 100%; }
.sk-cut path, .sk-cut circle { fill: #d23a2c; }
.sk-cut .sk-cut-hole { fill: var(--paper); }
@media (max-width: 640px) { .skin-cut.a { width: 40px; top: 8px; } .skin-cut.b { display: none; } }

/* ── 春节宽屏：左右两边垂一副春联，顶栏中间贴横批 ── */
.skin-dui, .skin-top { display: none; }
@media (min-width: 1200px) {
  .skin-dui, .skin-top { display: block; }
  .skin-dui p, .skin-top p { margin: 0; background: #d23a2c; color: #2a120c; box-shadow: inset 0 0 0 1.5px rgba(255, 214, 120, .6), 0 3px 10px rgba(80, 10, 0, .16);
    font-family: "Kaiti SC", "STKaiti", "KaiTi", "Kaiti TC", "BiauKai", "AR PL UKai CN", "Songti SC", serif; font-weight: 700; pointer-events: none; }
  .skin-dui p { position: fixed; z-index: 15; top: calc(var(--nav-h) + 54px); padding: .45em .26em; writing-mode: vertical-rl; text-orientation: upright; font-size: 22px; line-height: 1.25; letter-spacing: .16em; }
  .sd-l { left: 14px; } .sd-r { right: 14px; } /* 上联在左、下联在右，横批从左往右读 */
  .skin-top { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); pointer-events: none; }
  .skin-top p { padding: .16em .5em .16em .8em; font-size: 17px; line-height: 1.3; letter-spacing: .3em; white-space: nowrap; }
}

@media (prefers-reduced-motion: reduce) {
  .sk-ribbon, .sk-bulb, .sk-twinkle, .sk-swing, .sk-flame, .sk-fly { animation: none; }
}
