/* Effect Web — 喜庆明亮·贴纸感
   视觉参考 uiverse.io（MIT 许可的开源 UI 元素库）里常见的做法：发光渐变按钮、渐变描边卡片、分段开关、动画复选框、趣味加载动画。
   样式按本站配色重新写；颜色/圆角/动效都集中在下面的变量里，想换风格先改这里。 */

@property --a { syntax: '<angle>'; inherits: false; initial-value: 0deg; }

:root {
  --bg: #fff6ee;
  --surface: #fff;
  --ink: #2b1b16;
  --ink2: #6e5a50;
  --ink3: #9b8a80;
  --line: rgba(70, 35, 20, .1);
  --line2: rgba(70, 35, 20, .17);
  --red: #ff3b5c;
  --red-d: #d4143a;
  --orange: #ff7a3d;
  --gold: #ffb627;
  --pink: #ff6b9d;
  --teal: #14b8a6;
  --grad: linear-gradient(135deg, #ff3b5c 0%, #ff7a3d 55%, #ffb627 100%);
  --grad-soft: linear-gradient(135deg, #ffe3e9 0%, #fff0d9 100%);
  --sh-1: 0 1px 2px rgba(120, 50, 20, .06), 0 6px 18px rgba(120, 50, 20, .08);
  --sh-2: 0 2px 4px rgba(120, 50, 20, .08), 0 20px 44px rgba(255, 59, 92, .2);
  --ease: cubic-bezier(.2, .8, .2, 1);
  --spring: cubic-bezier(.34, 1.56, .64, 1);
  --top: 64px;
  --font-brand: 'Fredoka', 'Noto Serif Khmer', 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'PingFang SC', 'Microsoft YaHei', sans-serif; /* 只给 logo 旁边的网站名用 */
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--top) + 12px); }
body {
  margin: 0;
  min-height: 100dvh;
  color: var(--ink);
  /* 顺序别随便改：苹果 Safari 里的 system-ui / -apple-system 自带一套苹果高棉字体，排在前面时会抢在 Noto Serif Khmer 之前，
     手机上就和电脑不一样。所以英文用点名的字体，Noto Serif Khmer 必须排在 system-ui 前面。 */
  font-family: 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Serif Khmer', 'PingFang SC', 'Microsoft YaHei', 'Khmer UI', -apple-system, system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  background:
    radial-gradient(900px 480px at 88% -6%, #ffd8c0 0%, transparent 60%),
    radial-gradient(760px 460px at -8% 4%, #ffd0dc 0%, transparent 58%),
    var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
/* 固定背景在手机上滚动会卡（很多安卓机尤其明显），只给鼠标设备用 */
@media (hover: hover) and (pointer: fine) { body { background-attachment: fixed; } }
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image: radial-gradient(rgba(229, 23, 63, .1) 1.2px, transparent 1.3px);
  background-size: 22px 22px;
  -webkit-mask-image: linear-gradient(#000, transparent 65%);
  mask-image: linear-gradient(#000, transparent 65%);
}
html[lang='km'] body { line-height: 1.9; }
html[lang='km'] h1, html[lang='km'] h2, html[lang='km'] h3 { line-height: 1.55; letter-spacing: 0; }
html[lang='km'] .btn { line-height: 1.5; }

h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(28px, 5.4vw, 46px); line-height: 1.16; font-weight: 800; letter-spacing: -.02em; text-wrap: balance; }
h2 { font-size: clamp(22px, 3.4vw, 32px); line-height: 1.2; font-weight: 800; letter-spacing: -.01em; text-wrap: balance; }
h3 { font-size: 17px; font-weight: 700; }
h1, h2, h3, p, li, a, span, summary { overflow-wrap: anywhere; }
a { color: var(--red-d); }
img { max-width: 100%; }
button { font-family: inherit; }
.i { width: 1.2em; height: 1.2em; flex: none; vertical-align: -.2em; }
:focus-visible { outline: 3px solid rgba(255, 59, 92, .55); outline-offset: 3px; border-radius: 10px; }
::selection { background: rgba(255, 59, 92, .22); }
[hidden] { display: none !important; }

.skip { position: fixed; left: 12px; top: -60px; z-index: 300; padding: 10px 16px; border-radius: 12px; background: var(--ink); color: #fff; text-decoration: none; transition: top .2s; }
.skip:focus { top: 12px; }
.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 16px; }

/* ── 公告条 ─────────────────────────────── */
.banner { display: flex; align-items: center; gap: 10px; justify-content: center; padding: 9px 44px 9px 16px; position: relative; background: var(--grad); color: #fff; font-size: 14px; font-weight: 700; text-align: center; }
.banner-ico { display: inline-flex; animation: twinkle 2.2s ease-in-out infinite; }
.banner-x { position: absolute; right: 8px; top: 50%; translate: 0 -50%; width: 30px; height: 30px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .22); color: #fff; display: grid; place-items: center; cursor: pointer; }
.banner-x .i { width: 16px; height: 16px; }

/* ── 顶栏 ───────────────────────────────── */
.top { position: sticky; top: 0; z-index: 50; padding-top: env(safe-area-inset-top); background: rgba(255, 246, 238, .78); -webkit-backdrop-filter: saturate(1.6) blur(14px); backdrop-filter: saturate(1.6) blur(14px); border-bottom: 1px solid var(--line); transition: box-shadow .25s; }
.top.stuck { box-shadow: 0 8px 24px rgba(120, 50, 20, .1); }
.top-in { max-width: 1120px; height: var(--top); margin: 0 auto; padding: 0 16px; display: flex; align-items: center; gap: 12px; }
.top-in > :not(.brand) { flex: none; }
.top-link { white-space: nowrap; }
.brand { display: flex; align-items: center; gap: 8px; min-width: 0; margin-right: auto; text-decoration: none; }
.brand-text { display: flex; flex-direction: column; min-width: 0; }
.brand .logo { flex: none; }
/* 网站名称在后台可以改，太长时用省略号，别把语言开关和登录按钮挤出屏幕。
   上下的 padding + 负 margin 给高棉语的上下叠字留位置，省略号的裁切框才不会切掉它们 */
.brand-text b, .brand-text small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; line-height: 1.15; padding-block: .25em; margin-block: -.25em; }
/* 字标：圆体 Fredoka，网站名最后一个词橙红色（高棉语名字自动用 Noto Serif Khmer） */
.brand-text b, .brand-text small, .foot-logo b, .foot-logo small, .wm { font-family: var(--font-brand); letter-spacing: 0; }
.brand-text b { color: var(--ink); font-size: 21px; font-weight: 600; }
.brand-text small { margin-top: calc(2px - .25em); color: var(--ink3); font-size: 11.5px; font-weight: 500; letter-spacing: .02em; }
.wm { font-weight: 600; }
.wm-accent { color: #ff5a3d; }
.logo { width: 40px; height: 40px; filter: drop-shadow(0 2px 3px rgba(150, 60, 25, .2)); transition: transform .4s var(--spring); }
.brand:hover .logo { transform: rotate(-6deg) scale(1.08); }
.icon-btn { flex: none; width: 40px; height: 40px; display: grid; place-items: center; border: 0; border-radius: 50%; background: #fff; color: var(--ink); box-shadow: var(--sh-1); cursor: pointer; transition: transform .25s var(--spring); }
.icon-btn:hover { transform: scale(1.08); }
.icon-btn:active { transform: scale(.94); }
.top-nav { display: none; gap: 4px; }
.top-link { padding: 8px 14px; border-radius: 999px; color: var(--ink2); font-weight: 700; font-size: 15px; text-decoration: none; transition: background .2s, color .2s; }
.top-link:hover { background: rgba(255, 255, 255, .8); color: var(--ink); }
.top-link.on { color: var(--red-d); background: #fff; box-shadow: var(--sh-1); }

/* 语言分段开关（滑块） */
.seg { position: relative; display: grid; grid-template-columns: repeat(var(--n), 1fr); padding: 3px; border-radius: 999px; background: rgba(255, 255, 255, .85); box-shadow: inset 0 0 0 1px var(--line2); }
.seg-thumb { position: absolute; top: 3px; bottom: 3px; left: 3px; width: calc((100% - 6px) / var(--n)); border-radius: 999px; background: var(--grad); box-shadow: 0 4px 10px -2px rgba(255, 70, 60, .55); transform: translateX(calc(var(--i) * 100%)); transition: transform .4s var(--spring); }
.seg-opt { position: relative; z-index: 1; padding: 6px 11px; border-radius: 999px; color: var(--ink2); font-size: 13px; font-weight: 700; line-height: 1.5; text-align: center; text-decoration: none; white-space: nowrap; transition: color .25s; }
.seg-opt.on { color: #fff; }

/* ── 底部标签栏（手机）───────────────────── */
.tabbar { position: fixed; left: 12px; right: 12px; bottom: calc(10px + env(safe-area-inset-bottom)); z-index: 60; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 4px; max-width: 460px; margin: 0 auto; padding: 6px; border-radius: 26px; background: rgba(255, 255, 255, .9); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); box-shadow: 0 10px 30px rgba(120, 50, 20, .2), inset 0 0 0 1px rgba(255, 255, 255, .8); }
.tab { display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 0; padding: 8px 1px 7px; border-radius: 20px; color: var(--ink3); font-size: 11px; font-weight: 700; line-height: 1.35; text-decoration: none; transition: color .2s, background .25s, transform .25s var(--spring); }
.tab .i { width: 22px; height: 22px; }
/* 一格一行字；上下的 padding + 负 margin 给高棉语的上下叠字留位置，别被省略号的裁切框切掉 */
.tab span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding-block: .25em; margin-block: -.25em; }
@media (max-width: 359px) {
  .tabbar { left: 8px; right: 8px; gap: 2px; padding: 5px; }
  .tab { font-size: 9.5px; }
}
.tab:active { transform: scale(.94); }
.tab.on { color: #fff; background: var(--grad); box-shadow: 0 6px 14px -4px rgba(255, 70, 60, .6); }
/* 页脚总是接在 main 后面，给标签栏让位只靠页脚的下边距；main 再留一份就成了一大块空白 */
body:has(.tabbar) .foot { padding-bottom: calc(92px + env(safe-area-inset-bottom)); }

/* ── 按钮（发光渐变）──────────────────────── */
.btn { --h: 50px; position: relative; isolation: isolate; overflow: hidden; display: inline-flex; align-items: center; justify-content: center; gap: .5em; min-height: var(--h); padding: 0 1.4em; border: 0; border-radius: 999px; background: var(--grad); color: #fff; font-family: inherit; font-size: 16px; font-weight: 700; line-height: 1.2; text-align: center; text-decoration: none; text-shadow: 0 1px 0 rgba(150, 20, 30, .25); cursor: pointer; -webkit-tap-highlight-color: transparent; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .5), inset 0 -2px 0 rgba(160, 20, 40, .16), 0 10px 22px -6px rgba(255, 70, 60, .55); transition: transform .3s var(--spring), box-shadow .3s var(--ease), filter .2s, opacity .2s; }
.btn::after { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .55) 48%, transparent 66%); transform: translateX(-130%); transition: transform .8s var(--ease); }
.btn:hover { transform: translateY(-2px); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .55), inset 0 -2px 0 rgba(160, 20, 40, .16), 0 16px 30px -6px rgba(255, 70, 60, .7); }
.btn:hover::after { transform: translateX(130%); }
.btn:active { transform: translateY(0) scale(.97); }
.btn[disabled], .btn[aria-disabled='true'] { filter: grayscale(.75); opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }
.btn[disabled]::after { display: none; }
.btn.ghost { background: #fff; color: var(--red-d); text-shadow: none; box-shadow: inset 0 0 0 2px rgba(255, 59, 92, .35), 0 4px 12px rgba(120, 50, 20, .06); }
.btn.ghost:hover { box-shadow: inset 0 0 0 2px var(--red), 0 12px 22px -8px rgba(255, 59, 92, .45); }
.btn.soft { background: var(--grad-soft); color: var(--red-d); text-shadow: none; box-shadow: inset 0 0 0 1px rgba(255, 59, 92, .18); }
.btn.light { background: #fff; color: var(--red-d); text-shadow: none; box-shadow: 0 10px 24px -8px rgba(0, 0, 0, .3); }
.btn.sm { --h: 38px; padding: 0 1.05em; font-size: 14px; }
.btn.lg { --h: 56px; padding: 0 1.8em; font-size: 17px; }
.btn.block { display: flex; width: 100%; }
.btn[aria-busy='true'] { pointer-events: none; }
.btn .i { width: 1.15em; height: 1.15em; }
.link { display: inline-flex; align-items: center; gap: 6px; padding: 8px 4px; border: 0; background: none; color: var(--ink2); font-size: 14px; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.link.danger { color: #b4232f; }

/* ── 通用区块 ───────────────────────────── */
.section { padding-top: 34px; padding-bottom: 10px; }
.section-head { margin-bottom: 18px; }
.section-head p { margin-top: 6px; color: var(--ink2); }
.section-head.center { text-align: center; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border-radius: 999px; background: #fff; color: var(--red-d); font-size: 13px; font-weight: 700; box-shadow: var(--sh-1); }
.grad-text { font-style: normal; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tag { padding: 4px 12px; border-radius: 999px; background: #fff; color: var(--ink2); font-size: 12.5px; font-weight: 700; box-shadow: inset 0 0 0 1px var(--line2); }
.empty-note { padding: 40px 0; color: var(--ink2); text-align: center; }

/* ── 首页 hero ──────────────────────────── */
.hero { display: grid; gap: 26px; align-items: center; padding-top: 26px; padding-bottom: 8px; }
.hero h1 { margin: 14px 0 12px; font-size: clamp(30px, 4.8vw, 46px); }
.hero h1 em { display: block; }
.hero-sub { max-width: 34em; color: var(--ink2); font-size: clamp(16px, 2.3vw, 19px); }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 22px 0 18px; }
.perks { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 0; padding: 0; list-style: none; color: var(--ink2); font-size: 14px; font-weight: 600; }
.perks li { display: flex; align-items: center; gap: 6px; }
.perks .i { color: var(--orange); }
.hero-stat { display: inline-flex; align-items: center; gap: 8px; margin-top: 14px; padding: 6px 14px; border-radius: 999px; background: rgba(255, 255, 255, .8); color: var(--ink2); font-size: 13.5px; font-weight: 700; box-shadow: inset 0 0 0 1px var(--line); }
.hero-stat .i { color: var(--red); }
.hero-art { position: relative; height: clamp(300px, 78vw, 400px); }
.fan { position: absolute; display: block; overflow: hidden; width: min(38%, 200px); height: auto; border: 6px solid #fff; border-radius: 22px; background: #fff; box-shadow: 0 18px 40px rgba(120, 40, 20, .28); transform: rotate(var(--r)); animation: float 6s ease-in-out infinite; transition: scale .3s var(--spring); }
.fan img { display: block; width: 100%; height: auto; }
.fan-0 { left: 4%; top: 18%; z-index: 1; animation-delay: -2s; }
.fan-1 { left: 50%; top: 0; z-index: 3; width: min(44%, 232px); translate: -50% 0; }
.fan-2 { right: 4%; top: 22%; z-index: 2; animation-delay: -4s; }
/* 三张大图可以点（进对应模板）。浮动动画用的是 transform，这里的放大用独立的 scale 属性，两者不打架 */
@media (hover: hover) { a.fan:hover { z-index: 4; scale: 1.05; } }
a.fan:active { scale: .97; }
a.fan:focus-visible { z-index: 4; outline: 3px solid var(--red); outline-offset: 3px; }
.spark { position: absolute; width: 20px; height: 20px; background: var(--gold); clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%); animation: twinkle 2.4s ease-in-out infinite; }
.spark.s1 { left: 0; top: 6%; }
.spark.s2 { right: 2%; top: 4%; width: 28px; height: 28px; background: var(--pink); animation-delay: -.8s; }
.spark.s3 { right: 22%; bottom: 2%; background: var(--teal); animation-delay: -1.6s; }
@media (min-width: 860px) {
  .hero { grid-template-columns: 1.05fr .95fr; gap: 40px; padding-top: 52px; }
  .hero-art { height: 460px; }
}
/* 手机首页：内容和电脑一样（角标、标题、两个按钮、卖点、做过的人数、三张大图），只是字小一点、间距紧一点 */
@media (max-width: 719px) {
  .hero { gap: 14px; padding-top: 12px; padding-bottom: 0; }
  .hero .eyebrow { padding: 4px 12px; font-size: 12px; }
  .hero h1 { margin: 8px 0 4px; font-size: clamp(23px, 6.6vw, 30px); }
  .hero-sub { font-size: 13.5px; line-height: 1.6; }
  html[lang='km'] .hero-sub { line-height: 1.75; }
  .hero-cta { gap: 8px; margin: 12px 0 10px; }
  .hero .hero-cta .btn { --h: 46px; flex: 1 1 auto; padding: 0 14px; font-size: 14px; }
  .hero .perks { gap: 2px 12px; font-size: 12px; }
  .hero .perks li { gap: 4px; }
  .hero-stat { margin-top: 8px; padding: 4px 12px; font-size: 12.5px; }
  /* 三张大图和电脑一样完整显示（不裁图）：并排互相压住一点，区域高度跟着最高的那张走，什么比例的模板都放得下 */
  .hero-art { display: flex; align-items: flex-start; justify-content: center; width: 100%; max-width: 440px; height: auto; margin: 0 auto; padding: 4px 0 14px; }
  .hero-art .fan { position: relative; inset: auto; flex: none; width: 38%; border-width: 4px; border-radius: 16px; }
  .hero-art .fan-0 { margin: 12% -14% 0 0; }
  .hero-art .fan-1 { width: 44%; translate: none; }
  .hero-art .fan-2 { margin: 15% 0 0 -14%; }
  .hero-art .spark { scale: .75; }
  .hero + .section, .hot + .section { padding-top: 8px; }
  .hot + .section { padding-top: 14px; }
  .hero + .section .section-head, .hot + .section .section-head { margin-bottom: 8px; }
  .hero + .section h2, .hot + .section h2 { font-size: 18px; }
  .hero + .section .chips, .hot + .section .chips { margin-bottom: 12px; }
}

/* ── 首页热门模板行（views.js 的 hotRow，挑选规则在 server/hot.js）──
   手机、平板左右滑动看全部；≥1024px 一行正好排 6 个 */
.hot { padding-top: 10px; }
.hot-panel { position: relative; overflow: hidden; padding: 12px 0; border-radius: 24px; background: linear-gradient(135deg, #ff3b5c 0%, #ff7a3d 58%, #ffb627 100%); box-shadow: 0 18px 34px -18px rgba(255, 70, 60, .8); }
.hot-panel::before { content: ''; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(rgba(255, 255, 255, .28) 1.2px, transparent 1.4px) 0 0 / 16px 16px; -webkit-mask-image: linear-gradient(#000, transparent 55%); mask-image: linear-gradient(#000, transparent 55%); }
.hot-head { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 0 14px 6px; }
.hot-head h2 { display: flex; align-items: center; gap: 7px; min-width: 0; color: #fff; font-size: 18px; }
.hot-head h2 .i { flex: none; width: 22px; height: 22px; }
.hot-n { flex: none; padding: 3px 10px; border-radius: 999px; background: #fff; color: #e8284a; font: 800 12px/1.5 Arial, sans-serif; }
.hot-n.is-wide { display: none; }
/* 上下留几像素：悬停上浮和键盘焦点框不会被滚动容器切掉 */
.hot-row { position: relative; display: flex; gap: 10px; margin: 0; padding: 4px 14px; list-style: none; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scroll-padding-inline: 14px; scrollbar-width: none; }
.hot-row::-webkit-scrollbar { display: none; }
.hot-row li { flex: 0 0 118px; min-width: 0; scroll-snap-align: start; }
.hot-card { display: block; color: #fff; text-decoration: none; -webkit-tap-highlight-color: transparent; }
.hot-card:focus-visible { outline: none; }
.hot-media { position: relative; display: block; aspect-ratio: 3 / 4; overflow: hidden; border: 3px solid #fff; border-radius: 18px; background: var(--grad-soft); box-shadow: 0 10px 18px -8px rgba(80, 20, 0, .55); transition: transform .35s var(--spring); }
.hot-media img { display: block; width: 100%; height: 100%; object-fit: cover; }
@media (hover: hover) { .hot-card:hover .hot-media { transform: translateY(-3px) rotate(-1deg); } }
.hot-card:active .hot-media { transform: scale(.97); }
.hot-card:focus-visible .hot-media { box-shadow: 0 0 0 3px var(--ink); }
.hot-rank { position: absolute; left: 0; top: 0; display: grid; place-items: center; min-width: 34px; height: 31px; padding: 0 6px; border-radius: 0 0 14px 0; background: var(--ink); color: #fff; font-family: var(--font-brand); font-size: 17px; font-weight: 600; line-height: 1; }
.hot-rank.r1 { background: linear-gradient(135deg, #ffd43b 10%, #ff9500); text-shadow: 0 1px 2px rgba(120, 60, 0, .45); }
.hot-rank.r2 { background: linear-gradient(135deg, #cfd8e6 10%, #8391a8); text-shadow: 0 1px 2px rgba(30, 40, 60, .45); }
.hot-rank.r3 { background: linear-gradient(135deg, #eba873 10%, #ad5a26); text-shadow: 0 1px 2px rgba(70, 30, 0, .45); }
.hot-count { position: absolute; left: 6px; bottom: 6px; display: inline-flex; align-items: center; gap: 3px; padding: 1px 8px 1px 6px; border-radius: 999px; background: rgba(255, 255, 255, .95); color: #e8284a; font: 800 12px/1.6 Arial, sans-serif; }
.hot-count .i { width: 13px; height: 13px; }
.hot-name { display: block; overflow: hidden; margin-top: 4px; font-size: 13px; font-weight: 800; text-overflow: ellipsis; text-shadow: 0 1px 2px rgba(80, 20, 0, .35); white-space: nowrap; }
@media (min-width: 720px) {
  .hot { padding-top: 26px; }
  .hot + .section { padding-top: 22px; }
  .hot-panel { padding: 16px 0 14px; }
  .hot-head { padding: 0 22px 10px; }
  .hot-head h2 { font-size: 22px; }
  .hot-row { gap: 16px; padding: 4px 22px; scroll-padding-inline: 22px; }
  .hot-row li { flex-basis: 150px; }
}
/* 平板竖屏（顶部还是上下排）：歪着的大图会低出图区一截，热门行多让开一点，别压在一起 */
@media (min-width: 720px) and (max-width: 859px) { .hero + .hot { padding-top: 58px; } }
@media (min-width: 1024px) {
  .hot-row { overflow: visible; }
  .hot-row li { flex-basis: calc((100% - 5 * 16px) / 6); }
  .hot-row li:nth-child(n+7) { display: none; }
  .hot-n.is-narrow { display: none; }
  .hot-n.is-wide { display: inline-block; }
}

/* 筛选标签 */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.chip { padding: 8px 18px; border: 0; border-radius: 999px; background: #fff; color: var(--ink2); font-size: 14px; font-weight: 700; cursor: pointer; box-shadow: inset 0 0 0 1px var(--line2); transition: transform .25s var(--spring), background .2s, color .2s, box-shadow .2s; }
.chip:hover { transform: translateY(-2px); }
.chip.on { background: var(--grad); color: #fff; box-shadow: 0 8px 16px -6px rgba(255, 70, 60, .6); }

/* ── 模板卡片（整齐的网格 + 渐变描边）───────────
   手机 2 列；≥720px 一排 4 张。所有卡片统一 2:3 的画框（封面用 object-fit: cover 居中裁切），一行里高度对齐。 */
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
@media (min-width: 720px) { .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; } }
.card { position: relative; display: flex; flex-direction: column; border-radius: 22px; background: #fff; color: inherit; text-decoration: none; box-shadow: var(--sh-1); transition: transform .4s var(--spring), box-shadow .35s var(--ease); }
.card::before { content: ''; position: absolute; inset: -2px; padding: 2px; border-radius: 24px; background: conic-gradient(from var(--a), #ff3b5c, #ffb627, #ff6b9d, #14b8a6, #ff3b5c); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); opacity: 0; transition: opacity .3s; pointer-events: none; animation: spin 3.4s linear infinite; }
.card:hover, .card:focus-visible { transform: translateY(-6px) rotate(-.6deg); box-shadow: var(--sh-2); }
.card:hover::before, .card:focus-visible::before { opacity: 1; }
.card:active { transform: scale(.98); }
.card[hidden] { display: none; }
.card.pop { animation: pop .5s var(--spring) both; }
.card-media { position: relative; flex: none; overflow: hidden; border-radius: 22px 22px 0 0; background: var(--grad-soft); aspect-ratio: 2 / 3; }
.card-media img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .7s var(--ease); }
.card:hover .card-media img { transform: scale(1.07); }
.card-body { display: flex; flex: 1; flex-direction: column; justify-content: space-between; gap: 8px; padding: 12px 14px 14px; }
.card-body h3 { font-size: 15px; line-height: 1.4; }
@media (max-width: 719px) { .card-body { padding: 10px 12px 12px; } .card-body h3 { font-size: 14px; } .card-cta { font-size: 13px; } }
.card-cta { display: inline-flex; align-items: center; gap: 6px; color: var(--red-d); font-size: 14px; font-weight: 800; }
.card-cta .i { transition: transform .3s var(--spring); }
.card:hover .card-cta .i { transform: translateX(5px); }
.badge { position: absolute; left: 10px; top: 10px; z-index: 2; display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px 4px 8px; border-radius: 999px; background: var(--grad); color: #fff; font-size: 12px; font-weight: 800; box-shadow: 0 6px 14px -4px rgba(255, 70, 60, .6); }
.badge.new { background: linear-gradient(135deg, #14b8a6, #38bdf8); box-shadow: 0 6px 14px -4px rgba(20, 184, 166, .6); }
.badge .i { width: 13px; height: 13px; }
.count { position: absolute; right: 10px; bottom: 10px; z-index: 2; display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px 3px 8px; border-radius: 999px; background: rgba(43, 27, 22, .55); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); color: #fff; font-size: 12px; font-weight: 700; }
.count .i { width: 12px; height: 12px; color: var(--gold); }

/* ── 三步 / 行动条 ───────────────────────── */
.steps { display: grid; gap: 14px; margin: 0; padding: 0; list-style: none; }
.step { display: flex; align-items: center; gap: 14px; padding: 16px 18px; border-radius: 20px; background: #fff; box-shadow: var(--sh-1); }
.step h3 { font-size: 16px; }
.step p { color: var(--ink2); font-size: 14px; }
.step-n { flex: none; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 14px; background: var(--grad); color: #fff; font-size: 18px; font-weight: 800; box-shadow: 0 8px 16px -6px rgba(255, 70, 60, .6); transform: rotate(-6deg); }
.step:nth-child(2) .step-n { transform: rotate(5deg); }
@media (min-width: 760px) { .steps:not(.compact) { grid-template-columns: repeat(3, 1fr); } .steps:not(.compact) .step { flex-direction: column; align-items: flex-start; padding: 22px; } }
.steps.compact .step { padding: 12px 14px; box-shadow: none; background: rgba(255, 255, 255, .7); }
.steps.compact .step-n { width: 34px; height: 34px; font-size: 15px; border-radius: 11px; }
.cta-band { position: relative; overflow: hidden; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; margin: 34px 0 6px; padding: 28px clamp(20px, 5vw, 44px); border-radius: 30px; background: var(--grad); color: #fff; box-shadow: var(--sh-2); }
.cta-band::before, .cta-band::after { content: ''; position: absolute; border-radius: 50%; background: rgba(255, 255, 255, .16); }
.cta-band::before { width: 220px; height: 220px; right: -60px; top: -90px; }
.cta-band::after { width: 130px; height: 130px; right: 24%; bottom: -76px; }
.cta-band > * { position: relative; z-index: 1; }
.cta-band h2 { color: #fff; }
.cta-band p { margin-top: 4px; opacity: .92; }

/* ── 模板详情 ───────────────────────────── */
.tpl { display: grid; gap: 22px; padding-top: 18px; }
.tpl-visual { position: relative; display: grid; place-items: center; padding: 18px 0 8px; }
.frame { position: relative; width: min(100%, calc(62vh * var(--ar, .5625))); max-width: 420px; aspect-ratio: var(--ar); border: 8px solid #fff; border-radius: 30px; overflow: hidden; background: var(--grad-soft); box-shadow: 0 24px 56px rgba(120, 40, 20, .28); transform: rotate(-1.5deg); transition: transform .5s var(--spring); }
.frame:hover { transform: rotate(0) scale(1.02); }
.frame img { display: block; width: 100%; height: 100%; object-fit: cover; }
.float-chip { position: absolute; z-index: 2; display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 999px; background: #fff; color: var(--ink); font-size: 13px; font-weight: 800; box-shadow: var(--sh-2); animation: float 5s ease-in-out infinite; }
.float-chip .i { color: var(--orange); }
.float-chip.c1 { left: max(4%, calc(50% - 250px)); top: 14%; --r: -4deg; }
.float-chip.c2 { right: max(4%, calc(50% - 250px)); bottom: 12%; --r: 4deg; animation-delay: -2.5s; }
.float-chip.c3 { left: max(4%, calc(50% - 250px)); bottom: 7%; --r: 3deg; animation-delay: -1.3s; }
.float-chip.c3 .i { color: var(--red); }
.tpl-info { display: flex; flex-direction: column; gap: 14px; }
.lead { color: var(--ink2); font-size: 17px; }
.facts { display: flex; flex-wrap: wrap; gap: 8px 10px; margin: 0; padding: 0; list-style: none; }
.facts li { display: inline-flex; align-items: center; gap: 6px; padding: 7px 13px; border-radius: 999px; background: #fff; color: var(--ink2); font-size: 13.5px; font-weight: 700; box-shadow: inset 0 0 0 1px var(--line); }
.facts .i { color: var(--orange); }
.note { display: flex; gap: 8px; align-items: flex-start; color: var(--ink3); font-size: 13.5px; }
.note .i { margin-top: .3em; color: var(--gold); }
.minis { display: flex; gap: 14px; overflow-x: auto; padding: 4px 2px 18px; scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch; }
.mini { flex: none; width: 128px; display: flex; flex-direction: column; gap: 8px; color: var(--ink); font-size: 13px; font-weight: 700; text-align: center; text-decoration: none; scroll-snap-align: start; }
.mini img { width: 100%; aspect-ratio: var(--ar); object-fit: cover; border: 4px solid #fff; border-radius: 18px; box-shadow: var(--sh-1); transition: transform .3s var(--spring); }
.mini:hover img { transform: translateY(-4px) rotate(-1.5deg); }
.sticky-cta { position: sticky; bottom: 0; z-index: 40; padding: 14px 16px calc(14px + env(safe-area-inset-bottom)); background: linear-gradient(to top, var(--bg) 55%, transparent); }
.sticky-cta .btn { max-width: 560px; margin: 0 auto; }
.desk-only { display: none; }
@media (min-width: 860px) {
  .tpl { grid-template-columns: .9fr 1.1fr; gap: 48px; align-items: center; padding-top: 36px; }
  .tpl-info h1 { font-size: clamp(32px, 4vw, 46px); }
  .desk-only { display: flex; }
  .mob-only { display: none; }
}

/* ── 上传页 ─────────────────────────────── */
.stepper { display: flex; align-items: center; justify-content: center; gap: 0; margin: 18px auto 22px; padding: 0; list-style: none; max-width: 420px; }
.stepper li { position: relative; flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; color: var(--ink3); font-size: 12.5px; font-weight: 700; }
.stepper li:not(:last-child)::after { content: ''; position: absolute; left: calc(50% + 22px); right: calc(-50% + 22px); top: 15px; height: 3px; border-radius: 3px; background: var(--line2); }
.stepper li.done:not(:last-child)::after { background: var(--grad); }
.stepper .dot { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: #fff; box-shadow: inset 0 0 0 2px var(--line2); font-size: 14px; transition: all .3s var(--spring); }
.stepper .dot .i { width: 16px; height: 16px; stroke-width: 3; }
.stepper li.on { color: var(--red-d); }
.stepper li.on .dot { background: var(--grad); color: #fff; box-shadow: 0 8px 16px -6px rgba(255, 70, 60, .6); transform: scale(1.12); }
.stepper li.done { color: var(--ink2); }
.stepper li.done .dot { background: #fff; color: var(--red-d); box-shadow: inset 0 0 0 2px var(--red); }
.make-grid { display: grid; gap: 18px; }
.tpl-mini { display: flex; align-items: center; gap: 12px; padding: 10px 14px 10px 10px; border-radius: 20px; background: #fff; color: inherit; text-decoration: none; box-shadow: var(--sh-1); }
.tpl-mini img { width: 54px; aspect-ratio: var(--ar); object-fit: cover; border: 3px solid #fff; border-radius: 12px; box-shadow: var(--sh-1); }
.tpl-mini small { display: block; color: var(--ink3); font-size: 12px; font-weight: 700; }
.tpl-mini strong { font-size: 15px; line-height: 1.35; }
.make-main h1 { font-size: clamp(26px, 4.6vw, 38px); }
.make-main .sub { margin: 4px 0 16px; color: var(--ink2); }
@media (min-width: 860px) {
  .make-grid { grid-template-columns: 260px 1fr; gap: 32px; align-items: start; }
  .make-tpl { position: sticky; top: calc(var(--top) + 18px); }
}

.drop { position: relative; display: grid; min-height: 320px; overflow: hidden; border: 3px dashed rgba(255, 59, 92, .45); border-radius: 28px; background: rgba(255, 255, 255, .8); cursor: pointer; transition: transform .35s var(--spring), border-color .25s, background .25s, box-shadow .3s; animation: breathe 3.2s ease-in-out infinite; }
.drop:hover, .drop.is-over { border-color: var(--red); background: #fff; transform: scale(1.012); box-shadow: 0 18px 40px -14px rgba(255, 59, 92, .45); animation: none; }
.drop.is-over { border-style: solid; }
.drop.has-photo { border: 3px solid #fff; background: #1c1210; box-shadow: var(--sh-2); animation: none; cursor: default; }
.drop.has-photo:hover { transform: none; }
.drop-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 28px 18px; text-align: center; }
.drop-ico { display: grid; place-items: center; width: 76px; height: 76px; margin-bottom: 6px; border-radius: 26px; background: var(--grad); color: #fff; box-shadow: 0 14px 28px -8px rgba(255, 70, 60, .6); transform: rotate(-6deg); animation: bob 2.8s ease-in-out infinite; }
.drop-ico .i { width: 36px; height: 36px; }
.drop-empty strong { font-size: 18px; }
.drop-sub { color: var(--ink3); font-size: 14px; }
.drop-btns { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 12px; }
.touch-only { display: none; }
@media (hover: none) and (pointer: coarse) { .touch-only { display: inline-flex; } .drop-sub { display: none; } }
.drop-preview { position: relative; display: grid; background: #1c1210; }
.drop-preview img { display: block; width: 100%; max-height: 62vh; min-height: 320px; object-fit: contain; }
.drop-bar { position: absolute; inset: auto 0 0 0; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px; background: linear-gradient(to top, rgba(0, 0, 0, .6), transparent); }
.photo-ok { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px 5px 8px; border-radius: 999px; background: rgba(255, 255, 255, .92); color: #1a7f4b; font-size: 12.5px; font-weight: 800; }
.photo-ok .i { width: 16px; height: 16px; stroke-width: 3; }
.dds { display: grid; gap: 12px; margin: 18px 0 4px; }
@media (min-width: 520px) { .dds { grid-template-columns: 1fr 1fr; } }
.dd { padding: 14px 16px; border-radius: 20px; background: rgba(255, 255, 255, .8); box-shadow: inset 0 0 0 1px var(--line); }
.dd h3 { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; font-size: 14.5px; }
.dd.do h3 { color: #1a7f4b; }
.dd.dont h3 { color: #b4232f; }
.dd ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 5px; color: var(--ink2); font-size: 14px; }
.dd li { position: relative; padding-left: 16px; }
.dd li::before { content: ''; position: absolute; left: 0; top: .75em; width: 7px; height: 7px; border-radius: 50%; background: currentColor; opacity: .5; }

.check { display: flex; align-items: flex-start; gap: 12px; margin: 18px 0 6px; color: var(--ink2); font-size: 14px; cursor: pointer; }
.check input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.check .box { flex: none; display: grid; place-items: center; width: 26px; height: 26px; margin-top: 2px; border: 2px solid var(--line2); border-radius: 9px; background: #fff; color: #fff; transition: all .3s var(--spring); }
.check .box .i { width: 16px; height: 16px; stroke-width: 3.2; stroke-dasharray: 24; stroke-dashoffset: 24; transition: stroke-dashoffset .35s .08s var(--ease); }
.check:hover .box { border-color: var(--red); }
.check input:checked + .box { border-color: transparent; background: var(--grad); transform: scale(1.1); box-shadow: 0 6px 14px -4px rgba(255, 70, 60, .6); }
.check input:checked + .box .i { stroke-dashoffset: 0; }
.check input:focus-visible + .box { outline: 3px solid rgba(255, 59, 92, .45); outline-offset: 2px; }
.error { margin: 12px 0 0; padding: 12px 16px; border-radius: 16px; background: #ffe9ea; color: #b4232f; font-size: 14.5px; font-weight: 700; animation: shake .45s; }
/* 渐变只在上边留白里做：剩余次数那行字下面必须是实底，小屏上才不会和后面的内容叠在一起 */
.make-bar { position: sticky; bottom: 0; z-index: 40; margin-top: 18px; padding: 14px 0 calc(14px + env(safe-area-inset-bottom)); background: linear-gradient(to top, var(--bg) calc(100% - 14px), transparent); }
.make-bar-in { max-width: 560px; margin: 0 auto; }
.quota { margin: 0 0 8px; color: var(--ink2); font-size: 13.5px; font-weight: 700; text-align: center; }
@media (min-width: 860px) { .make-bar-in { margin-left: 292px; max-width: none; } .make-bar .btn { max-width: 420px; } }

/* ── 结果页 ─────────────────────────────── */
.result { max-width: 560px; padding-bottom: 30px; text-align: center; }
.working { display: flex; flex-direction: column; align-items: center; padding-top: 12px; }
.working h1 { margin-top: 10px; font-size: clamp(24px, 5vw, 32px); }
.stage { margin-top: 6px; color: var(--ink2); font-weight: 600; transition: opacity .3s; }
.loader { position: relative; width: 150px; height: 140px; margin: 6px auto 0; }
.loader i { position: absolute; left: 50%; top: 50%; width: 84px; height: 84px; margin: -42px 0 0 -42px; border: 5px solid #fff; border-radius: 30%; box-shadow: 0 12px 26px rgba(120, 40, 20, .28); animation: shuffle 2.4s var(--ease) infinite; }
.loader i::after { content: ''; position: absolute; inset: 22px; background: rgba(255, 255, 255, .92); clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%); animation: twinkle 1.6s ease-in-out infinite; }
.loader i:nth-child(1) { background: linear-gradient(135deg, #ff3b5c, #ff7a3d); }
.loader i:nth-child(2) { background: linear-gradient(135deg, #ffb627, #ffd86b); animation-delay: -.8s; }
.loader i:nth-child(3) { background: linear-gradient(135deg, #ff6b9d, #c084fc); animation-delay: -1.6s; }
.bar { position: relative; width: min(100%, 360px); height: 12px; margin: 22px auto 10px; overflow: hidden; border-radius: 999px; background: rgba(255, 59, 92, .13); }
.bar i { position: relative; display: block; width: 0; height: 100%; overflow: hidden; border-radius: inherit; background: var(--grad); transition: width 1s linear; }
.bar i::after { content: ''; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .65) 50%, transparent 70%); animation: shimmer 1.4s linear infinite; }
.eta { color: var(--ink3); font-size: 13.5px; font-weight: 600; }
.tip { min-height: 3.4em; max-width: 30em; margin-top: 18px; padding: 12px 18px; border-radius: 18px; background: rgba(255, 255, 255, .85); color: var(--ink2); font-size: 14.5px; box-shadow: inset 0 0 0 1px var(--line); transition: opacity .35s, transform .35s; }
.tip.swap { opacity: 0; transform: translateY(6px); }
.leave { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 14px; color: var(--ink3); font-size: 13px; }

.done-head { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 2px 0 16px; }
.done-head h1 { font-size: clamp(28px, 6vw, 38px); background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.done-ico { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--grad); color: #fff; box-shadow: 0 10px 20px -6px rgba(255, 70, 60, .6); animation: pop-in .6s var(--spring) both; }
.done-ico .i { width: 24px; height: 24px; stroke-width: 3.2; }
.shot { position: relative; width: min(100%, calc(66vh * 0.6)); max-width: 100%; margin: 0 auto 18px; aspect-ratio: var(--ar); border: 8px solid #fff; border-radius: 30px; overflow: hidden; background: var(--grad-soft); box-shadow: 0 26px 60px rgba(120, 40, 20, .32); animation: reveal .8s var(--spring) both; }
.shot img { display: block; width: 100%; height: 100%; object-fit: cover; }
.shine { position: absolute; inset: 0; background: linear-gradient(110deg, transparent 38%, rgba(255, 255, 255, .6) 50%, transparent 62%); transform: translateX(-130%); animation: shine-once 1.4s .7s var(--ease) both; pointer-events: none; }
.demo { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 0 0 14px; padding: 9px 14px; border-radius: 14px; background: #fff3d6; color: #8a5a00; font-size: 13px; text-align: left; }
.actions { display: grid; gap: 12px; margin: 0 auto; max-width: 420px; }
@media (min-width: 520px) { .actions { grid-template-columns: 1fr 1fr; max-width: 480px; } .fail .actions { max-width: 480px; } }
/* 手机结果页：“保存 / 分享”钉在屏幕底部，一打开就按得到；图片按屏幕高度缩小一点，不被按钮挡住。
   做好之后那排“1 2 3 步骤条”只是装饰，手机上收起来省地方 */
@media (max-width: 719px) {
  .result[data-status='done'] .stepper { display: none; }
  .result[data-status='done'] .done-head { margin: 14px 0 12px; }
  .result[data-status='done'] .done-head h1 { font-size: 25px; }
  .result[data-status='done'] .done-ico { width: 36px; height: 36px; }
  .result[data-status='done'] .done-ico .i { width: 20px; height: 20px; }
  .result[data-status='done'] .shot { width: min(100%, max(220px, calc((100vh - 240px) * var(--ar)))); margin-bottom: 6px; }
  @supports (height: 100svh) {
    .result[data-status='done'] .shot { width: min(100%, max(220px, calc((100svh - 240px) * var(--ar)))); }
  }
  .result[data-status='done'] .actions { position: sticky; bottom: 0; z-index: 40; grid-template-columns: 1.35fr 1fr; gap: 10px; max-width: none; margin: 0 -16px; padding: 14px 16px calc(12px + env(safe-area-inset-bottom)); background: linear-gradient(to top, var(--bg) calc(100% - 14px), rgba(255, 246, 238, 0)); }
  .result[data-status='done'] .actions .btn { padding: 0 12px; }
}
@media (max-width: 359px) {
  .result[data-status='done'] .actions .btn { gap: .35em; padding: 0 8px; font-size: 15px; }
}
.actions2 { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 14px; }
.vote { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px; margin-top: 18px; color: var(--ink2); font-size: 14px; font-weight: 700; }
.vote button { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border: 0; border-radius: 999px; background: #fff; color: var(--ink2); font-size: 13.5px; font-weight: 700; cursor: pointer; box-shadow: inset 0 0 0 1px var(--line2); transition: transform .25s var(--spring), background .2s, color .2s; }
.vote button:hover { transform: translateY(-2px); }
.vote button.on { background: var(--grad); color: #fff; box-shadow: 0 6px 14px -4px rgba(255, 70, 60, .6); }
.vote.voted button:not(.on) { opacity: .4; pointer-events: none; }
/* 通过转发链接来看作品的人：引导他们也做一张 */
.viewer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 16px; max-width: 480px; margin: 18px auto 0; padding: 16px 18px; border-radius: 22px; background: var(--grad-soft); box-shadow: inset 0 0 0 1px rgba(255, 59, 92, .15); text-align: left; }
.viewer > div { flex: 1 1 200px; }
.viewer strong, .viewer span { display: block; }
.viewer span { color: var(--ink2); font-size: 14px; }
.hint { margin-top: 16px; color: var(--ink3); font-size: 13.5px; }
.hint.warn { padding: 10px 14px; border-radius: 14px; background: #fff3d6; color: #8a5a00; }
.expire { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 10px; color: var(--ink3); font-size: 13px; }
.result .note { justify-content: center; margin-top: 4px; }
.result .link { margin-top: 8px; }
.fail { padding-top: 8px; }
.illus { display: block; width: 132px; height: 132px; margin: 0 auto 8px; filter: drop-shadow(0 12px 18px rgba(120, 40, 20, .2)); animation: bob 3.2s ease-in-out infinite; }
.fail h1 { font-size: clamp(26px, 5vw, 34px); }
.fail-msg { margin: 8px 0 18px; color: var(--ink2); font-size: 17px; font-weight: 600; }
.tips-box { margin: 0 auto 22px; padding: 16px 20px; max-width: 420px; border-radius: 20px; background: #fff; box-shadow: var(--sh-1); text-align: left; }
.tips-box h3 { margin-bottom: 8px; font-size: 15px; }
.tips-box ul { display: grid; gap: 6px; margin: 0; padding-left: 20px; color: var(--ink2); font-size: 14.5px; }

/* 分享面板（原生 <dialog>）*/
.sheet { width: min(100%, 520px); max-width: 100%; max-height: 88dvh; margin: auto auto 0; padding: 8px 20px calc(22px + env(safe-area-inset-bottom)); border: 0; border-radius: 30px 30px 0 0; background: #fff; color: var(--ink); box-shadow: 0 -12px 50px rgba(0, 0, 0, .3); animation: sheet-up .4s var(--spring); }
.sheet::backdrop { background: rgba(43, 27, 22, .5); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); animation: fade .25s both; }
@media (min-width: 640px) { .sheet { margin: auto; border-radius: 30px; padding-bottom: 24px; } }
.sheet-grab { width: 44px; height: 5px; margin: 4px auto 10px; border-radius: 5px; background: var(--line2); }
.sheet-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.sheet-head h2 { font-size: 20px; }
.share-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 14px; }
.share-opt { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 10px 0; overflow-wrap: normal; word-break: normal; letter-spacing: -.01em; border: 0; border-radius: 18px; background: none; color: var(--ink2); font-size: 12.5px; font-weight: 700; line-height: 1.3; text-align: center; text-decoration: none; cursor: pointer; transition: transform .25s var(--spring), background .2s; }
.share-opt:hover { background: #fff6ee; transform: translateY(-3px); }
.share-opt:active { transform: scale(.94); }
.share-opt > span { display: grid; place-items: center; width: 54px; height: 54px; border-radius: 50%; color: #fff; box-shadow: 0 10px 20px -8px rgba(0, 0, 0, .45); }
.share-opt .i { width: 26px; height: 26px; }
.share-opt.fb > span { background: #1877f2; }
.share-opt.tg > span { background: #229ed9; }
.share-opt.ms > span { background: linear-gradient(135deg, #0a7cff, #a334fa 55%, #ff5c87); }
.share-opt.cp > span { background: var(--ink); }

/* 五彩纸屑 */
.confetti { position: fixed; inset: 0; z-index: 400; width: 100%; height: 100%; pointer-events: none; }

/* 过期 / 删掉的作品链接：说明缩小一点，下面直接给当初那个模板的“做同款”和几个别的模板 */
.expired { padding-top: 14px; padding-bottom: 20px; }
.expired-head { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; }
.expired-head .illus { width: 84px; height: 84px; margin: 0; }
.expired-head h1 { font-size: clamp(21px, 5.2vw, 32px); }
.expired-head p { max-width: 30em; color: var(--ink2); font-size: 14.5px; }
.same { display: flex; align-items: center; gap: 14px; max-width: 480px; margin: 14px auto 0; padding: 12px; border-radius: 26px; background: #fff; box-shadow: var(--sh-2); animation: pop .5s var(--spring) both; }
.same-img { flex: none; width: 36%; max-width: 150px; }
.same-img img { display: block; width: 100%; height: auto; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 18px; }
.same-text { display: flex; flex: 1; flex-direction: column; gap: 8px; min-width: 0; text-align: left; }
.same-text strong { font-size: 17px; line-height: 1.45; }
.same-text span { color: var(--ink2); font-size: 14px; }
.same-text .btn { width: 100%; padding: 0 12px; }
.expired .section { padding-top: 24px; }
.expired-home { display: flex; justify-content: center; margin-top: 20px; }

/* ── 我的作品 ───────────────────────────── */
.my { padding-top: 22px; }
.my-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
@media (min-width: 760px) { .my-grid { grid-template-columns: repeat(4, 1fr); gap: 18px; } }
.work { position: relative; display: flex; flex-direction: column; overflow: hidden; border-radius: 22px; background: #fff; box-shadow: var(--sh-1); transition: transform .35s var(--spring), box-shadow .3s; animation: pop .5s var(--spring) both; }
.work:hover { transform: translateY(-5px); box-shadow: var(--sh-2); }
.work-media { position: relative; display: block; aspect-ratio: var(--ar, 9/16); background: var(--grad-soft); overflow: hidden; }
.work-media img { display: block; width: 100%; height: 100%; object-fit: cover; }
.work.gone .work-media img { filter: grayscale(1) blur(3px); opacity: .45; }
.work-status { position: absolute; left: 10px; top: 10px; display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border-radius: 999px; background: rgba(43, 27, 22, .62); color: #fff; font-size: 12px; font-weight: 800; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.work-status.ok { background: rgba(26, 127, 75, .85); }
.work-status .spin { width: 12px; height: 12px; border: 2px solid rgba(255, 255, 255, .45); border-top-color: #fff; border-radius: 50%; animation: rot .8s linear infinite; }
.work-body { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 12px; }
.work-title { font-size: 13.5px; font-weight: 700; line-height: 1.35; }
.work-body time { display: block; color: var(--ink3); font-size: 12px; font-weight: 600; }
.work-x { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border: 0; border-radius: 50%; background: #fff6ee; color: var(--ink2); cursor: pointer; transition: background .2s, color .2s, transform .25s var(--spring); }
.work-x:hover { background: #ffe0e3; color: #b4232f; transform: scale(1.1); }
.my-foot { display: flex; justify-content: center; margin-top: 22px; }
.empty-state { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 56px 16px 40px; text-align: center; }
.empty-state p { max-width: 28em; color: var(--ink2); }
.empty-state .btn { margin-top: 12px; }
.empty-state h1, .empty-state h2 { font-size: clamp(24px, 5vw, 34px); }

/* ── FAQ / 条款 ─────────────────────────── */
.faq, .legal { max-width: 780px; padding-top: 24px; }
.qas { display: grid; gap: 12px; }
.qa { border-radius: 20px; background: #fff; box-shadow: var(--sh-1); transition: box-shadow .3s; }
.qa[open] { box-shadow: var(--sh-2); }
.qa summary { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 16px 18px; font-size: 16px; font-weight: 700; list-style: none; cursor: pointer; }
.qa summary::-webkit-details-marker { display: none; }
.chev { display: grid; place-items: center; flex: none; width: 30px; height: 30px; border-radius: 50%; background: var(--grad-soft); color: var(--red-d); transition: transform .35s var(--spring), background .2s, color .2s; }
.chev .i { width: 16px; height: 16px; }
.qa[open] .chev { transform: rotate(180deg); background: var(--grad); color: #fff; }
.qa-a { padding: 0 18px 18px; color: var(--ink2); animation: fade-down .35s var(--ease) both; }
.qa-a p + p, .qa-a p + ul, .qa-a ul + p { margin-top: 8px; }
.qa-a ul { display: grid; gap: 6px; margin: 0; padding-left: 22px; }
.faq-cta { display: flex; justify-content: center; margin-top: 28px; }
.legal-sec { margin-bottom: 22px; padding: 20px 22px; border-radius: 22px; background: #fff; box-shadow: var(--sh-1); }
.legal-sec h2 { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; font-size: 19px; }
.legal-sec h2 span { display: grid; place-items: center; flex: none; width: 30px; height: 30px; border-radius: 10px; background: var(--grad); color: #fff; font-size: 14px; }
.legal-sec p { color: var(--ink2); }
.legal-sec p + p, .legal-sec p + ul { margin-top: 8px; }
.legal-sec ul { display: grid; gap: 8px; margin: 0; padding-left: 22px; color: var(--ink2); }
.legal-sec ul + p, .legal-sec ul + ul { margin-top: 8px; }
.legal-contact { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 10px; font-weight: 700; }
.legal-contact a { min-width: 0; overflow-wrap: anywhere; }

/* ── 页脚（浅色卡片：品牌 + 联系按钮、三栏链接、三条保证；下面版权、一句话、语言）──
   手机：链接三栏、保证横排、版权和语言开关同一行 */
.foot { margin-top: 32px; padding: 0 14px 24px; color: var(--ink2); font-size: 14px; }
.foot-in { max-width: 1088px; margin: 0 auto; }
.foot-card { position: relative; overflow: hidden; padding: 22px 14px 14px; border-radius: 22px; background: #fff; box-shadow: 0 24px 50px -30px rgba(120, 40, 20, .35), 0 0 0 1px rgba(70, 35, 20, .07); }
.foot-card::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 5px; background: var(--grad); }
.foot-top { display: grid; gap: 16px; }
.foot-brand { min-width: 0; }
.foot-logo { display: inline-flex; align-items: center; gap: 10px; max-width: 100%; color: inherit; text-decoration: none; }
.foot-logo .logo { flex: none; width: 40px; height: 40px; }
.foot-logo > span { min-width: 0; }
.foot-logo b, .foot-logo small { display: block; overflow-wrap: anywhere; }
.foot-logo b { color: var(--ink); font-size: 20px; font-weight: 600; line-height: 1.35; }
.foot-logo small { color: var(--ink3); font-size: 12px; font-weight: 500; line-height: 1.4; }
.foot-tag { max-width: 24em; margin-top: 6px; font-size: 13px; line-height: 1.75; }
.foot-social { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 10px; }
.foot-social a { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: #fff1ec; color: #ff4a4a; transition: transform .25s var(--spring), background .2s; }
.foot-social a:hover { transform: translateY(-2px); background: #ffe3e9; }
.foot-social .i { width: 20px; height: 20px; }
.foot-cols { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr) minmax(0, .85fr); align-content: start; gap: 0 10px; padding-top: 14px; border-top: 1px solid rgba(70, 35, 20, .08); }
.foot-h { display: block; margin-bottom: 4px; color: var(--ink); font-size: 12.5px; font-weight: 800; }
.foot-cols a { display: block; padding: 3px 0; color: var(--ink2); font-size: 12.5px; line-height: 1.7; text-decoration: none; }
.foot-cols a:hover { color: var(--red-d); }
.foot-trust { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 14px 0 0; padding: 0; list-style: none; }
.foot-trust li { display: flex; flex-direction: column; align-items: center; gap: 6px; min-width: 0; padding: 10px 5px; border-radius: 14px; background: #fff7f1; color: #4a3329; font-size: 11px; font-weight: 700; line-height: 1.7; text-align: center; }
.foot-trust-ico { display: grid; place-items: center; flex: none; width: 32px; height: 32px; border-radius: 10px; background: #fff; color: #ff5a3d; box-shadow: 0 4px 10px -6px rgba(120, 40, 20, .4); }
.foot-trust .i { width: 17px; height: 17px; }
.foot-trust li > span:last-child { text-wrap: balance; }
.foot-bottom { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 12px 2px 0; color: var(--ink3); font-size: 11.5px; text-align: center; }
.foot-copy { min-width: 0; }
.foot-made { display: flex; align-items: center; justify-content: center; gap: 6px; }
.foot-made .i { flex: none; color: var(--red); }
.foot-made .i path { fill: currentColor; }
@media (max-width: 359px) { .foot-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 8px; } }
@media (min-width: 720px) {
  .foot { margin-top: 44px; padding: 0 16px 20px; }
  .foot-card { padding: 34px 36px 26px; border-radius: 26px; }
  .foot-top { grid-template-columns: 1.25fr 1.75fr; gap: 40px; }
  .foot-logo .logo { width: 46px; height: 46px; }
  .foot-logo b { font-size: 21px; }
  .foot-tag { margin-top: 10px; font-size: 13.5px; }
  .foot-social { margin-top: 14px; }
  .foot-cols { gap: 18px 14px; padding-top: 0; border-top: 0; }
  .foot-h { margin-bottom: 8px; font-size: 13px; }
  .foot-cols a { padding: 4px 0; font-size: 13.5px; }
  .foot-trust { margin-top: 20px; }
  .foot-trust li { flex-direction: row; gap: 10px; padding: 10px 12px; font-size: 13px; text-align: left; }
  .foot-bottom { flex-direction: row; justify-content: space-between; gap: 16px; padding-top: 18px; font-size: 12px; }
}

/* ── Toast ──────────────────────────────── */
.toasts { position: fixed; left: 0; right: 0; bottom: calc(96px + env(safe-area-inset-bottom)); z-index: 500; display: grid; justify-items: center; gap: 8px; padding: 0 16px; pointer-events: none; }
.toast { display: flex; align-items: center; gap: 8px; max-width: min(92vw, 440px); padding: 12px 18px; border-radius: 999px; background: rgba(43, 27, 22, .95); color: #fff; font-size: 14px; font-weight: 700; box-shadow: 0 12px 30px rgba(0, 0, 0, .3); pointer-events: auto; animation: toast-in .4s var(--spring) both; }
.toast .i { color: var(--gold); }
.toast.out { animation: toast-out .25s ease both; }

/* ── 账号 / 登录（Google）──────────────────────
   顶栏：没登录是“登录”按钮（手机上只剩图标）；登录了是首字母头像 + 下拉菜单（原生 <details>，没有 JS 也能展开）。 */
.acct-login { flex: none; display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 14px; border-radius: 999px; background: #fff; color: var(--ink); font-size: 14px; font-weight: 700; line-height: 1; text-decoration: none; box-shadow: var(--sh-1), inset 0 0 0 1px var(--line); transition: transform .25s var(--spring), box-shadow .25s; }
.acct-login:hover { transform: translateY(-2px); box-shadow: var(--sh-2); }
.acct-login .i { width: 18px; height: 18px; color: var(--red-d); }
@media (max-width: 519px) {
  .acct-login { width: 40px; padding: 0; justify-content: center; }
  .acct-login span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; } /* 图标按钮：文字只留给读屏软件 */
}
.avatar { display: grid; place-items: center; flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--grad); color: #fff; font-size: 16px; font-weight: 800; line-height: 1; box-shadow: 0 6px 14px -4px rgba(255, 70, 60, .55), inset 0 0 0 2px #fff; }
.avatar.lg { width: 60px; height: 60px; font-size: 26px; }
.acct { position: relative; flex: none; }
.acct-btn { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; list-style: none; cursor: pointer; -webkit-tap-highlight-color: transparent; transition: transform .25s var(--spring); }
.acct-btn::-webkit-details-marker { display: none; }
.acct-btn .avatar { width: 40px; height: 40px; }
.acct-btn:hover { transform: scale(1.06); }
.acct[open] .acct-btn { transform: scale(1.06); }
.acct-menu { position: absolute; right: 0; top: calc(100% + 10px); z-index: 90; width: min(260px, calc(100vw - 24px)); padding: 8px; border-radius: 20px; background: #fff; box-shadow: 0 18px 44px rgba(120, 50, 20, .28), inset 0 0 0 1px var(--line); animation: fade-down .25s var(--ease) both; }
.acct-who { padding: 10px 12px 12px; margin-bottom: 4px; border-bottom: 1px solid var(--line); }
.acct-who strong, .acct-who small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acct-who small { color: var(--ink3); font-size: 12.5px; }
.acct-menu a, .acct-menu button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 11px 12px; border: 0; border-radius: 12px; background: none; color: var(--ink); font: inherit; font-size: 15px; font-weight: 700; text-align: left; text-decoration: none; cursor: pointer; }
.acct-menu a:hover, .acct-menu button:hover { background: #fff3ea; }
.acct-menu .i { color: var(--orange); }
.acct-menu form { margin: 0; }

/* “使用 Google 登录”按钮：白底 + 四色 G（Google 品牌规范的样式） */
.btn.google { background: #fff; color: #1f1f1f; text-shadow: none; box-shadow: inset 0 0 0 1px #dadce0, 0 8px 18px -10px rgba(60, 64, 67, .45); }
.btn.google::after { display: none; }
.btn.google:hover { background: #f8f9fa; box-shadow: inset 0 0 0 1px #c6c9cc, 0 14px 24px -12px rgba(60, 64, 67, .55); }
.g-ico { flex: none; width: 20px; height: 20px; }

/* 上传页挡住上传框的卡片（要登录 / 张数用完）：在选照片之前就挡住，别让人选好照片又被带去登录页 */
.gate { display: flex; flex-direction: column; align-items: center; gap: 12px; margin: 6px 0 14px; padding: 30px 22px 24px; border-radius: 28px; background: #fff; box-shadow: var(--sh-2); text-align: center; animation: pop .5s var(--spring) both; }
.gate-ico { display: grid; place-items: center; width: 68px; height: 68px; border-radius: 24px; background: var(--grad); color: #fff; box-shadow: 0 14px 28px -8px rgba(255, 70, 60, .6); transform: rotate(-6deg); }
.gate-ico .i { width: 32px; height: 32px; }
.gate h2 { font-size: clamp(22px, 4.6vw, 28px); }
.gate p { max-width: 30em; color: var(--ink2); }
.gate small { max-width: 30em; color: var(--ink3); font-size: 12.5px; line-height: 1.6; }
.make.is-gated .drop, .make.is-gated .dds, .make.is-gated .check, .make.is-gated #error, .make.is-gated .make-bar { display: none; }
.gate .forgot-links { justify-content: center; }

/* 发放账号：剩余张数（右上角菜单、账号页） */
.acct-who small.acct-bal { display: flex; align-items: center; gap: 6px; margin-top: 8px; color: var(--ink); font-weight: 800; white-space: normal; }
.acct-who small.acct-bal.none { color: #b4232f; }
.acct-bal .i { flex: none; width: 15px; height: 15px; }
.no-balance { display: grid; gap: 10px; justify-items: center; margin-top: 12px; padding: 14px 16px; border-radius: 20px; background: #fff4dc; color: #855600; font-weight: 700; text-align: center; }
.no-balance .forgot-links { justify-content: center; }

/* 结果页 / 我的作品页：“登录后永久保存”卡片，和已保存提示 */
.save-prompt, .keep-card { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 14px; margin: 18px auto 0; max-width: 480px; padding: 16px 18px; border-radius: 22px; background: var(--grad-soft); box-shadow: inset 0 0 0 1px rgba(255, 59, 92, .15); text-align: left; }
.keep-card { max-width: none; margin: 0 0 20px; }
.sp-ico { display: grid; place-items: center; flex: none; width: 44px; height: 44px; border-radius: 14px; background: var(--grad); color: #fff; box-shadow: 0 8px 16px -6px rgba(255, 70, 60, .6); transform: rotate(-5deg); }
.sp-ico .i { width: 24px; height: 24px; }
.sp-text { flex: 1 1 180px; }
.sp-text strong, .sp-text span { display: block; }
.sp-text span { color: var(--ink2); font-size: 14px; }
.save-prompt .btn { flex: 1 1 100%; }
@media (min-width: 560px) { .keep-card .btn { flex: none; } }
.saved-note { display: flex; align-items: center; justify-content: center; gap: 8px; width: fit-content; max-width: 100%; margin: 14px auto 0; padding: 8px 16px; border-radius: 999px; background: #e7f7ee; color: #1a7f4b; font-size: 14px; font-weight: 700; }
.saved-note a { color: inherit; }
.saved-note .i { width: 20px; height: 20px; flex: none; }

/* 在 Facebook、TikTok 等内置网页里点登录 → 教客户换到 Chrome / Safari */
.openin { max-width: 520px; padding-top: 18px; padding-bottom: 30px; }
.openin-card { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 24px 18px 18px; border-radius: 28px; background: #fff; box-shadow: var(--sh-2); text-align: center; animation: pop .5s var(--spring) both; }
.openin-ico { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 22px; background: var(--grad); color: #fff; box-shadow: 0 14px 28px -8px rgba(255, 70, 60, .6); transform: rotate(-6deg); }
.openin-ico .i { width: 32px; height: 32px; }
.openin h1 { font-size: clamp(21px, 5.6vw, 28px); }
.openin-sub { max-width: 30em; color: var(--ink2); }
.openin-carry { display: flex; align-items: flex-start; gap: 8px; width: 100%; padding: 10px 14px; border-radius: 16px; background: #e7f7ee; color: #1a7f4b; font-size: 14px; font-weight: 700; text-align: left; }
.openin-carry .i { flex: none; width: 20px; height: 20px; margin-top: .2em; }
.openin-step { width: 100%; padding: 12px 14px; border-radius: 16px; background: var(--grad-soft); font-size: 15px; font-weight: 700; }
.openin-alt { display: grid; gap: 10px; width: 100%; }
.openin-alt p { color: var(--ink2); font-size: 14px; }
.openin .loader { margin-top: -4px; }

/* 账号页 */
.acct-page { max-width: 640px; padding-top: 24px; }
.acct-card { display: flex; align-items: center; gap: 16px; padding: 18px 20px; border-radius: 24px; background: #fff; box-shadow: var(--sh-1); }
.acct-card strong { display: block; font-size: 18px; line-height: 1.4; }
.acct-card div > span { display: block; color: var(--ink2); font-size: 14px; overflow-wrap: anywhere; }
.acct-facts { display: grid; gap: 10px; margin: 14px 0 0; padding: 0; list-style: none; }
.acct-facts li { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-radius: 20px; background: #fff; box-shadow: var(--sh-1); }
.acct-facts li span { flex: 1; color: var(--ink2); font-weight: 600; }
.acct-facts li b { font-weight: 800; }
.acct-facts .i { color: var(--orange); }
.acct-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 18px 0 28px; }
.acct-actions form { margin: 0; }
.danger-zone { padding: 18px 20px; border-radius: 22px; background: #fff5f5; box-shadow: inset 0 0 0 1px rgba(180, 35, 47, .2); }
.danger-zone h2 { color: #b4232f; font-size: 18px; }
.danger-zone p { margin: 6px 0 14px; color: var(--ink2); font-size: 14.5px; }
.btn.ghost.danger { color: #b4232f; box-shadow: inset 0 0 0 2px rgba(180, 35, 47, .4); }
.btn.ghost.danger:hover { box-shadow: inset 0 0 0 2px #b4232f, 0 12px 22px -8px rgba(180, 35, 47, .35); }
.toast.bad { background: rgba(122, 22, 32, .96); }

/* 登录页 / 注册页 */
.auth { max-width: 480px; padding-top: 18px; padding-bottom: 20px; }
.auth-card { display: flex; flex-direction: column; gap: 14px; padding: 24px 20px; border-radius: 28px; background: #fff; box-shadow: var(--sh-2); animation: pop .5s var(--spring) both; }
.auth h1 { font-size: clamp(24px, 6.4vw, 30px); text-align: center; }
.auth .sub { margin-top: -8px; color: var(--ink2); text-align: center; }
.auth-or { display: flex; align-items: center; gap: 12px; color: var(--ink3); font-size: 13px; font-weight: 700; text-align: center; }
.auth-or::before, .auth-or::after { content: ''; flex: 1; height: 1px; background: var(--line2); }
.auth-switch { color: var(--ink2); font-size: 14.5px; text-align: center; }
.auth-switch a { display: inline-block; padding: 4px; font-weight: 800; }
.auth-tip { margin-top: -6px; color: var(--ink2); font-size: 13.5px; text-align: center; }
.auth-agree { color: var(--ink3); font-size: 12.5px; text-align: center; }
.forgot { text-align: center; font-size: 14px; }
.forgot summary { display: inline-block; padding: 4px 8px; color: var(--ink2); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; list-style: none; cursor: pointer; }
.forgot summary::-webkit-details-marker { display: none; }
.forgot > div { display: grid; gap: 10px; margin-top: 10px; padding: 14px 16px; border-radius: 16px; background: var(--grad-soft); color: var(--ink2); text-align: left; animation: fade-down .3s var(--ease) both; }
.forgot-links { display: flex; flex-wrap: wrap; gap: 8px; }
.forgot-links .btn { max-width: 100%; }
.need-account { display: grid; gap: 10px; justify-items: center; padding-top: 14px; border-top: 1px solid var(--line); color: var(--ink2); font-size: 14.5px; text-align: center; }
.need-account .forgot-links { justify-content: center; }

/* 表单（登录、注册、账号页）。输入框字号 16px：再小的话苹果手机点进去会自动放大页面 */
.auth-form { position: relative; display: grid; gap: 14px; margin: 0; }
.fld { display: grid; gap: 6px; text-align: left; }
.fld label { font-size: 14.5px; font-weight: 700; }
.inp { display: flex; align-items: center; min-width: 0; border-radius: 16px; background: #fffaf6; box-shadow: inset 0 0 0 1.5px var(--line2); transition: box-shadow .2s, background .2s; }
.inp:focus-within { background: #fff; box-shadow: inset 0 0 0 2px var(--red), 0 0 0 4px rgba(255, 59, 92, .12); }
.inp input { flex: 1; width: 100%; min-width: 0; height: 52px; padding: 0 16px; border: 0; border-radius: 16px; background: none; color: var(--ink); font: inherit; font-size: 16px; outline: 0; }
.inp input::placeholder { color: var(--ink3); opacity: .75; }
.inp-pre { flex: none; padding-left: 16px; color: var(--ink2); font-weight: 700; }
.inp-pre + input { padding-left: 10px; }
.pw-eye { flex: none; display: grid; place-items: center; width: 44px; height: 44px; margin-right: 4px; border: 0; border-radius: 12px; background: none; color: var(--ink3); cursor: pointer; -webkit-tap-highlight-color: transparent; }
.pw-eye .i { width: 21px; height: 21px; }
.pw-eye .off, .pw-eye.shown .on { display: none; }
.pw-eye.shown { color: var(--red-d); }
.pw-eye.shown .off { display: block; }
.fld.bad .inp { background: #fff5f5; box-shadow: inset 0 0 0 2px #d92d45; }
.fld-err { color: #b4232f; font-size: 13.5px; font-weight: 700; }
.fld-hint { color: var(--ink3); font-size: 12.5px; }
.notice { display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; border-radius: 16px; font-size: 14.5px; font-weight: 700; text-align: left; }
.notice .i { width: 20px; height: 20px; margin-top: .2em; }
.notice.ok { background: #e7f7ee; color: #1a7f4b; }
.notice.bad { background: #fdecee; color: #a61b2b; }
.notice.warn { background: #fff4dc; color: #855600; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; opacity: 0; }

/* 账号页：改密码 / 改联系方式（折叠）、绑定 Google */
.acct-page > .notice { margin-bottom: 12px; }
.acct-sec { margin-bottom: 12px; border-radius: 20px; background: #fff; box-shadow: var(--sh-1); }
.acct-sec summary { display: flex; align-items: center; gap: 10px; padding: 13px 14px 13px 18px; font-weight: 800; list-style: none; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.acct-sec summary::-webkit-details-marker { display: none; }
.acct-sec summary > .i { color: var(--orange); }
.acct-sec summary > span { flex: 1; }
.acct-sec[open] .chev { transform: rotate(180deg); background: var(--grad); color: #fff; }
.acct-sec-body { padding: 4px 18px 18px; animation: fade-down .3s var(--ease) both; }
.acct-google { display: grid; gap: 8px; margin: 6px 0 18px; text-align: center; }
.acct-google.linked { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-radius: 20px; background: #fff; box-shadow: var(--sh-1); font-weight: 700; text-align: left; }
.acct-google.linked span { flex: 1; }
.acct-google.linked .i { width: 20px; height: 20px; color: #1a7f4b; }
.acct-facts li { flex-wrap: wrap; }
.acct-facts li span { flex: 1 1 auto; } /* 邮箱很长时整个换到下一行，别把左边的名称挤成一竖条 */
.acct-facts li b { min-width: 0; max-width: 100%; margin-left: auto; text-align: right; }
.acct-facts li b.off { color: var(--ink3); font-weight: 600; }

/* 上传页的登录引导里有两个按钮：一样宽 */
.gate > .btn { width: 100%; max-width: 330px; }
.gate .auth-switch { margin: 0; }

/* ── 分页条（首页模板、我的作品、后台列表）───── */
.pager { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px; margin-top: 22px; }
.pg { display: inline-grid; place-items: center; min-width: 40px; height: 40px; padding: 0 10px; border: 0; border-radius: 999px; background: #fff; color: var(--ink2); font: inherit; font-size: 15px; font-weight: 800; line-height: 1; text-decoration: none; cursor: pointer; box-shadow: inset 0 0 0 1px var(--line2); transition: transform .25s var(--spring), box-shadow .2s, color .2s; -webkit-tap-highlight-color: transparent; }
a.pg:hover, button.pg:hover { transform: translateY(-2px); color: var(--red-d); box-shadow: inset 0 0 0 1px var(--red), 0 8px 16px -8px rgba(255, 59, 92, .45); }
.pg.on { background: var(--grad); color: #fff; box-shadow: 0 8px 16px -6px rgba(255, 70, 60, .6); cursor: default; }
.pg.off { opacity: .35; cursor: default; }
.pg.gap { min-width: 18px; padding: 0; background: none; box-shadow: none; color: var(--ink3); cursor: default; }
.pg .i { width: 18px; height: 18px; }

/* “同意展示我的作品”开关（结果页，默认打开）和上传页的一行说明 */
.check.share-check { max-width: 480px; margin: 18px auto 0; padding: 14px 16px; border-radius: 20px; background: rgba(255, 255, 255, .88); box-shadow: inset 0 0 0 1px var(--line); text-align: left; }
.share-check .check-text strong { display: block; color: var(--ink); font-size: 14.5px; line-height: 1.5; }
.share-check .check-text small { display: block; margin-top: 2px; color: var(--ink3); font-size: 12.5px; line-height: 1.6; }
.share-check input:disabled + .box { opacity: .6; }
.consent-note { display: flex; gap: 8px; align-items: flex-start; margin: 4px 0 0 38px; color: var(--ink3); font-size: 12.5px; line-height: 1.6; }
.consent-note .i { flex: none; width: 15px; height: 15px; margin-top: .25em; color: var(--orange); }
.make.is-gated .consent-note { display: none; }

/* ── 关于我们（/about，贴纸全家福）───────── */
.about { max-width: 940px; margin: 0 auto; padding: 22px 16px 0; text-align: center; overflow-x: clip; }
.about-eyebrow { display: inline-flex; align-items: center; gap: 7px; padding: 5px 16px; border-radius: 999px; background: #fff; box-shadow: var(--sh-1); color: #e5173f; font-size: 14px; font-weight: 800; }
.about-eyebrow .i { width: 16px; height: 16px; fill: currentColor; }
.about-head h1 { margin: 14px 0 4px; font-size: clamp(27px, 4.4vw, 44px); }
.about-head h1 em { padding: 0 2px; font-style: normal; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.about-sub { max-width: 620px; margin: 0 auto; color: var(--ink2); font-size: clamp(15px, 2vw, 19px); font-weight: 600; }
/* --ar = 照片的宽 ÷ 高：换成竖图时相框跟着变窄，照片高度不会超过约 640px */
.about-photo { position: relative; max-width: min(820px, calc(640px * var(--ar, 1.5) + 20px)); margin: 26px auto 0; padding: 10px; border-radius: 30px; background: #fff; box-shadow: var(--sh-2); transform: rotate(-.8deg); }
.about-photo img { display: block; width: 100%; height: auto; border-radius: 22px; }
.about-tape { position: absolute; top: 12px; z-index: 1; width: 108px; height: 28px; border-radius: 3px; }
.about-tape.l { left: -26px; background: rgba(255, 190, 80, .75); transform: rotate(-34deg); }
.about-tape.r { right: -26px; background: rgba(255, 120, 140, .65); transform: rotate(34deg); }
/* 名字标签的左右位置对着默认全家福里的三个人 */
.about-chip { position: absolute; bottom: 5.5%; padding: 4px 16px; border: 3px solid #fff; border-radius: 999px; color: #fff; font-size: 15px; font-weight: 800; line-height: 1.7; white-space: nowrap; box-shadow: 0 8px 16px -8px rgba(40, 20, 10, .5); transform: translateX(-50%) rotate(-2deg); }
.about-chip.mom { left: 20.5%; background: #27407c; }
.about-chip.baby { left: 50%; background: #1f7fe0; transform: translateX(-50%) rotate(2deg); }
.about-chip.dad { left: 79.5%; background: #a8213f; }
.about-story { max-width: 700px; margin: 28px auto 0; font-size: clamp(15.5px, 1.9vw, 18px); line-height: 1.85; text-wrap: pretty; }
html[lang='km'] .about-story { line-height: 2.1; }
.about-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 54px 0 0; padding: 0; list-style: none; }
.about-card { --c: #a8213f; display: flex; flex-direction: column; align-items: center; padding: 0 16px 18px; border-bottom: 5px solid var(--c); border-radius: 24px; background: #fff; box-shadow: var(--sh-1); }
.about-card.mom { --c: #27407c; }
.about-card.baby { --c: #1f7fe0; }
.about-card > div { min-width: 0; }
.about-card img { width: 112px; height: 112px; margin-top: -34px; border: 5px solid #fff; border-radius: 36px; background: #fff; object-fit: cover; box-shadow: 0 0 0 3px var(--c), 0 10px 20px -10px rgba(40, 20, 10, .5); }
.about-card h2 { margin: 12px 0 4px; color: var(--c); font-size: 19px; letter-spacing: 0; }
.about-card p { color: var(--ink2); font-size: 14.5px; }
.about-bye { position: relative; margin-top: 24px; padding: 28px 18px; border-radius: 28px; background: var(--grad); color: #fff; }
/* 两边留出星星和爱心的位置，字改长了也不会压到它们（手机上它们挪到字的上面） */
.about-bye p { max-width: min(620px, calc(100% - 76px)); margin: 0 auto 18px; font-size: clamp(18px, 2.6vw, 24px); font-weight: 800; text-wrap: balance; }
.about-star { position: absolute; left: 22px; top: 16px; width: 30px; height: 30px; fill: #ffd25e; stroke: #ffd25e; stroke-width: 1.5; stroke-linejoin: round; transform: rotate(-14deg); }
.i.about-heart { position: absolute; right: 26px; top: 18px; width: 26px; height: 26px; transform: rotate(16deg); }
.about-btns { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.about-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 20px; border-radius: 999px; background: #fff; color: var(--red-d); font-size: 15px; font-weight: 800; text-decoration: none; box-shadow: 0 8px 18px -8px rgba(0, 0, 0, .35); transition: transform .3s var(--spring); }
.about-btn:hover { transform: translateY(-2px); }
.about-btn .i { width: 20px; height: 20px; }
.about-btn.telegram { color: #1786bd; }
.about-btn.whatsapp { color: #178a42; }
.about-btn.facebook { color: #1a62c9; }
.btn.about-cta { --h: 48px; background: var(--ink); font-size: 15px; box-shadow: 0 8px 18px -8px rgba(0, 0, 0, .45); }
.about-bye a:focus-visible { outline-color: #fff; }
@media (max-width: 719px) {
  .about { padding-top: 14px; }
  .about-photo { margin-top: 20px; padding: 6px; border-radius: 22px; }
  .about-photo img { border-radius: 17px; }
  .about-tape { top: 8px; width: 64px; height: 18px; }
  .about-tape.l { left: -12px; }
  .about-tape.r { right: -12px; }
  .about-chip { bottom: 1%; padding: 1px 9px; border-width: 2px; font-size: 11px; }
  .about-story { margin-top: 20px; }
  .about-cards { grid-template-columns: 1fr; gap: 12px; margin-top: 22px; }
  .about-card { flex-direction: row; gap: 14px; padding: 14px; border-bottom: 0; border-left: 5px solid var(--c); text-align: left; }
  .about-card img { flex: none; width: 82px; height: 82px; margin: 0; border-width: 3px; border-radius: 26px; box-shadow: 0 0 0 2px var(--c); }
  .about-card h2 { margin: 0 0 2px; font-size: 17px; }
  .about-card p { font-size: 13.5px; }
  .about-bye { padding: 46px 14px 20px; }
  .about-bye p { max-width: 100%; }
  .about-star { left: 14px; top: 10px; }
  .i.about-heart { right: 16px; top: 12px; }
  .btn.about-cta { width: 100%; }
}
@media (max-width: 359px) {
  .about-btn { padding: 0 13px; font-size: 14px; }
}

/* ── 动画 ───────────────────────────────── */
@keyframes spin { to { --a: 360deg; } }
@keyframes rot { to { transform: rotate(360deg); } }
@keyframes float { 0%, 100% { transform: translateY(0) rotate(var(--r, 0deg)); } 50% { transform: translateY(-10px) rotate(calc(var(--r, 0deg) + 1.5deg)); } }
@keyframes bob { 0%, 100% { transform: translateY(0) rotate(-6deg); } 50% { transform: translateY(-8px) rotate(-2deg); } }
.illus { --r: 0deg; }
.illus { animation-name: bob2; }
@keyframes bob2 { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes twinkle { 0%, 100% { transform: scale(1) rotate(0); opacity: 1; } 50% { transform: scale(.6) rotate(25deg); opacity: .6; } }
@keyframes breathe { 0%, 100% { box-shadow: 0 0 0 0 rgba(255, 59, 92, .0); } 50% { box-shadow: 0 0 0 8px rgba(255, 59, 92, .08); } }
@keyframes pop { from { opacity: 0; transform: translateY(14px) scale(.94); } to { opacity: 1; transform: none; } }
@keyframes pop-in { from { transform: scale(0) rotate(-40deg); } to { transform: scale(1) rotate(0); } }
@keyframes reveal { from { opacity: 0; transform: translateY(26px) scale(.9) rotate(-3deg); } to { opacity: 1; transform: none; } }
@keyframes shine-once { to { transform: translateX(130%); } }
@keyframes shimmer { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
@keyframes shuffle {
  0% { transform: translate(-34px, 8px) rotate(-14deg) scale(.88); z-index: 1; }
  33% { transform: translate(0, -10px) rotate(0) scale(1.06); z-index: 3; }
  66% { transform: translate(34px, 8px) rotate(14deg) scale(.88); z-index: 2; }
  100% { transform: translate(-34px, 8px) rotate(-14deg) scale(.88); z-index: 1; }
}
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes fade-down { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
@keyframes sheet-up { from { transform: translateY(100%); } to { transform: none; } }
@keyframes toast-in { from { opacity: 0; transform: translateY(16px) scale(.9); } to { opacity: 1; transform: none; } }
@keyframes toast-out { to { opacity: 0; transform: translateY(10px) scale(.95); } }

/* 滚动进入动画：只在支持“滚动驱动动画”的浏览器里启用，不支持就直接显示 */
@supports (animation-timeline: view()) {
  .step, .qa, .legal-sec, .cta-band { animation: reveal-view linear both; animation-timeline: view(); animation-range: entry 0% entry 55%; }
  @keyframes reveal-view { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
}

@media (min-width: 820px) {
  .tabbar { display: none; }
  .top-nav { display: flex; }
  body:has(.tabbar) .foot { padding-bottom: 20px; }
  .toasts { bottom: 32px; }
}
/* 刚够显示顶部导航的宽度（平板竖屏、小窗口）：高棉语的四个导航项很长，收紧一点，网站名别被截掉 */
@media (min-width: 820px) and (max-width: 939px) {
  .top-in { gap: 8px; }
  .top-nav { gap: 2px; }
  .top-link { padding-inline: 9px; font-size: 14.5px; }
}
/* 常见手机宽 390–430：有返回键 + 登录图标时，“Effect Web” 也要完整显示，别截成 “Effect W…” */
@media (max-width: 430px) {
  .top-in { gap: 8px; padding: 0 12px; }
  .brand { gap: 6px; }
  .brand-text b { font-size: 20px; }
  .logo { width: 38px; height: 38px; }
}
@media (max-width: 380px) {
  .seg-opt { padding: 6px 8px; font-size: 12px; }
  .brand { gap: 6px; }
  .brand-text b { font-size: 18px; }
  .logo { width: 36px; height: 36px; }
}
/* 很窄的手机（320px）：返回键 + logo + 语言开关 + 登录图标要挤在一行，别让 “Effect Web” 折成两行 */
.brand-text b { white-space: nowrap; }
@media (max-width: 345px) {
  .top-in { gap: 8px; padding: 0 10px; }
  .brand { gap: 4px; }
  .logo { width: 32px; height: 32px; }
  .brand-text b { font-size: 15.5px; }
  .brand-text small { font-size: 10px; }
  .icon-btn { width: 36px; height: 36px; }
  .acct-login { width: 36px; height: 36px; }
  .acct-btn, .acct-btn .avatar { width: 36px; height: 36px; }
  .seg-opt { padding: 5px 7px; }
}
/* ── 节日专区（首页最上面，后台“节日活动”开关）+ 飘雪花 + logo 圣诞帽 ───── */
.fest { padding-top: 14px; }
.fest-card { position: relative; overflow: hidden; display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; padding: 18px 14px 16px; border: 3px solid #ffd36b; border-radius: 26px; background: radial-gradient(120% 90% at 80% 0%, #d9263b 0%, #a50f25 45%, #6d0716 100%); color: #fff; box-shadow: 0 14px 30px rgba(140, 10, 35, .28); }
.fest-deco { position: absolute; inset: 0; pointer-events: none; }
.fest-deco i { position: absolute; font-style: normal; line-height: 1; }
.fest-deco i::before, .snow i::before { content: '\2744\FE0E'; }
.fest-head, .fest-row, .fest-acts { position: relative; min-width: 0; }
.fest-tag { display: inline-block; padding: 3px 12px; border-radius: 999px; background: #fff3d6; color: #8a0c1f; font-size: 12px; font-weight: 800; }
.fest-card h2 { margin: 10px 0 2px; color: #fff; font-size: clamp(23px, 6.2vw, 33px); text-shadow: 0 2px 0 rgba(0, 0, 0, .2); }
.fest-sub { font-size: 14px; opacity: .94; }
.fest-count { display: inline-block; margin-top: 10px; padding: 4px 14px; border-radius: 14px; background: #0f6b3f; font-size: 13.5px; font-weight: 700; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .2); }
.fest-count b { margin-inline: 2px; color: #ffe08a; font-size: 22px; font-weight: 800; }
.fest-row { display: flex; gap: 10px; margin: 0 -14px; padding: 2px 14px 0; list-style: none; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x proximity; scroll-padding-inline: 14px; scrollbar-width: none; }
.fest-row::-webkit-scrollbar { display: none; }
.fest-row li { flex: 0 0 108px; min-width: 0; scroll-snap-align: start; }
.fest-row a { display: block; color: #fff; text-decoration: none; }
.fest-row img { display: block; width: 100%; height: auto; aspect-ratio: 2 / 3; object-fit: cover; border: 3px solid #fff; border-radius: 16px; background: #7d0a1c; transition: transform .3s var(--spring); }
.fest-row span { display: block; overflow: hidden; font-size: 12.5px; font-weight: 700; line-height: 2.1; text-align: center; text-overflow: ellipsis; white-space: nowrap; }
.fest-card a:focus-visible { outline-color: #ffe08a; outline-offset: 0; }
.fest-acts { display: grid; gap: 10px; }
.fest-btn { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 8px 18px; border-radius: 999px; background: linear-gradient(90deg, #ffcf4d, #ff9f1c); color: #5a1500; font-size: 15px; font-weight: 800; line-height: 1.5; text-align: center; text-decoration: none; box-shadow: 0 8px 18px -6px rgba(0, 0, 0, .45); transition: transform .3s var(--spring), filter .2s; }
.fest-contact { display: grid; justify-items: center; gap: 8px; font-size: 13px; text-align: center; }
.fest-contact .forgot-links { justify-content: center; }
.fest-contact .btn.soft { background: #fff; color: #a50f25; }
@media (hover: hover) { .fest-row a:hover img { transform: translateY(-3px) rotate(-1.5deg); } .fest-btn:hover { transform: translateY(-2px); filter: brightness(1.05); } }
/* 鼠标设备：模板多到一行放不下时要看得见滚动条（没有手指可以滑） */
@media (hover: hover) and (pointer: fine) { .fest-row { padding-bottom: 6px; scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, .45) transparent; } .fest-row::-webkit-scrollbar { display: block; } }
@media (min-width: 860px) {
  .fest { padding-top: 22px; }
  .fest-card { grid-template-columns: minmax(0, 360px) minmax(0, 1fr); grid-template-rows: auto 1fr; grid-template-areas: 'head row' 'acts row'; column-gap: 26px; row-gap: 16px; padding: 28px 26px; }
  .fest-head { grid-area: head; }
  .fest-row { grid-area: row; align-self: center; margin: 0; padding-inline: 3px; scroll-padding-inline: 3px; }
  .fest-row li { flex-basis: 146px; }
  .fest-row span { font-size: 13.5px; }
  .fest-acts { grid-area: acts; align-self: end; justify-items: start; }
  .fest-btn { padding-inline: 28px; }
  .fest-contact { justify-items: start; text-align: left; }
  .fest-contact .forgot-links { justify-content: flex-start; }
}
/* 飘雪花：铺在页面上面、顶栏下面，不挡点击 */
.snow { position: fixed; inset: 0; z-index: 45; overflow: hidden; pointer-events: none; }
.snow i { position: absolute; top: -30px; left: var(--x); color: #86bdee; font-size: var(--s); font-style: normal; line-height: 1; opacity: .75; text-shadow: 0 0 3px #fff; animation: snow-fall var(--d) linear var(--w) infinite; }
.snow i:nth-child(3n) { color: #f09fb0; }
.snow i:nth-child(4n) { color: #fff; opacity: .95; text-shadow: 0 0 2px #6fa9de, 0 1px 3px rgba(60, 110, 170, .65); }
@keyframes snow-fall {
  0% { transform: translate3d(0, 0, 0) rotate(0deg); }
  50% { transform: translate3d(var(--dx), 55vh, 0) rotate(160deg); }
  100% { transform: translate3d(0, calc(100vh + 60px), 0) rotate(340deg); }
}
/* logo 圣诞帽 */
.logo-wrap { position: relative; display: flex; flex: none; }
.santa-hat { position: absolute; left: -7px; top: -9px; width: 28px; height: 22px; filter: drop-shadow(0 1px 1px rgba(90, 20, 10, .25)); pointer-events: none; transform: rotate(-18deg); transition: transform .4s var(--spring); }
.brand:hover .santa-hat { transform: rotate(-27deg) translate(-2px, -1px); }
@media (max-width: 380px) { .santa-hat { left: -6px; top: -8px; width: 25px; height: 20px; } }
@media (max-width: 345px) { .santa-hat { left: -5px; top: -7px; width: 22px; height: 18px; } }
.lite .snow { display: none; }
@media (prefers-reduced-motion: reduce) { .snow { display: none; } }
/* 低端手机 / 省流量模式 / 2G（app.js 会给 <html> 加 .lite）：去掉毛玻璃、固定背景和无限动画，滚动更顺 */
.lite body::before { display: none; }
.lite .top { background: #fff6ee; -webkit-backdrop-filter: none; backdrop-filter: none; }
.lite .tabbar { background: #fff; -webkit-backdrop-filter: none; backdrop-filter: none; }
.lite .count, .lite .work-status, .lite .sheet::backdrop { -webkit-backdrop-filter: none; backdrop-filter: none; }
.lite .fan, .lite .float-chip, .lite .spark, .lite .drop-ico, .lite .illus, .lite .drop, .lite .banner-ico, .lite .card::before { animation: none; }
.lite .card:hover, .lite .btn:hover { transform: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
}
