/* =========================================================
   创意实验室 · 作品导航
   炫酷但不吃性能：无 backdrop-filter、无大面积混合模式，
   动效只走 transform / opacity 合成层
   ========================================================= */
*,*::before,*::after{ box-sizing:border-box; margin:0; padding:0; }

:root{
  --bg:#05010f;
  --ink:#e8fbff;
  --muted:rgba(178,220,245,.6);
  --dim:rgba(150,200,230,.4);
  --cyan:#4de8ff;
  --violet:#8b5cff;
  --magenta:#ff4d9d;
  --font:"PingFang SC","Hiragino Sans GB","Microsoft YaHei","Noto Sans SC",system-ui,sans-serif;
  --mono:"SFMono-Regular",Consolas,"Liberation Mono",Menlo,monospace;
  --ease:cubic-bezier(.2,.9,.3,1);
}

html{ scroll-behavior:smooth; }
html,body{ min-height:100%; }
body{
  font-family:var(--font);
  color:var(--ink);
  background:
    radial-gradient(90% 55% at 50% -10%, #150a36 0%, rgba(21,10,54,0) 62%),
    radial-gradient(62% 46% at 92% 78%, #250a2e 0%, rgba(37,10,46,0) 64%),
    radial-gradient(58% 44% at 6% 66%, #04162c 0%, rgba(4,22,44,0) 64%),
    linear-gradient(180deg, #060213 0%, #070114 48%, #030010 100%);
  background-attachment:fixed;
  overflow-x:hidden;
  -webkit-font-smoothing:antialiased;
  -webkit-tap-highlight-color:transparent;
}
body::before,
body::after{
  content:""; position:fixed; z-index:0; border-radius:50%; pointer-events:none;
}
body::before{
  width:72vmax; height:72vmax; left:-24vmax; top:-28vmax;
  background:radial-gradient(circle, rgba(102,52,255,.2) 0%, rgba(102,52,255,0) 66%);
}
body::after{
  width:56vmax; height:56vmax; right:-20vmax; bottom:-22vmax;
  background:radial-gradient(circle, rgba(255,60,150,.14) 0%, rgba(255,60,150,0) 66%);
}

/* 动态星空 / 鼠标光斑 / 后期层 */
#field{
  position:fixed; inset:0; z-index:1;
  width:100%; height:100%;
  pointer-events:none;
}
.glow-follow{
  position:fixed; left:0; top:0; z-index:2;
  width:520px; height:520px; margin:-260px 0 0 -260px;
  border-radius:50%; pointer-events:none;
  background:radial-gradient(circle, rgba(77,232,255,.09) 0%, rgba(139,92,255,.05) 46%, rgba(0,0,0,0) 68%);
  transform:translate3d(-999px,-999px,0);
  opacity:0; transition:opacity .6s ease;
  will-change:transform;
}
body.has-fine-pointer .glow-follow{ opacity:1; }
.vignette{
  position:fixed; inset:0; z-index:3; pointer-events:none;
  background:radial-gradient(120% 90% at 50% 42%, rgba(0,0,0,0) 44%, rgba(0,0,0,.58) 100%);
}
.scanlines{
  position:fixed; inset:0; z-index:4; pointer-events:none;
  background:repeating-linear-gradient(180deg, rgba(170,235,255,.026) 0 1px, transparent 1px 3px);
  opacity:.55;
}

/* 页面容器 */
.page{
  position:relative; z-index:5;
  width:min(1180px, 100%);
  margin:0 auto;
  padding:
    calc(env(safe-area-inset-top) + clamp(18px,3vw,32px))
    clamp(16px,4vw,40px)
    calc(env(safe-area-inset-bottom) + 40px);
}

/* ================= 顶栏 ================= */
.masthead{
  display:flex; align-items:center; justify-content:space-between;
  gap:14px;
}
.brand{ display:flex; align-items:center; gap:12px; min-width:0; }
.brand-mark{
  flex:0 0 auto; width:38px; height:38px;
  display:block;
  animation:markFloat 7s ease-in-out infinite;
}
.brand-mark svg{ width:100%; height:100%; display:block; }
.brand-mark circle:first-of-type{
  transform-box:fill-box; transform-origin:center;
  animation:markSpin 26s linear infinite;
}
@keyframes markSpin{ to{ transform:rotate(360deg); } }
@keyframes markFloat{
  0%,100%{ transform:translateY(0); }
  50%{ transform:translateY(-3px); }
}
.brand-text{ display:flex; flex-direction:column; gap:3px; min-width:0; }
.brand-eyebrow{
  font-family:var(--mono); font-size:9px; letter-spacing:.32em;
  color:rgba(150,225,255,.42);
}
.brand-name{
  font-size:14px; font-weight:800; letter-spacing:.18em;
  color:#dff6ff;
  text-shadow:0 0 18px rgba(77,232,255,.35);
}
.meta{
  display:flex; flex-direction:column; align-items:flex-end; gap:4px;
  font-family:var(--mono); font-size:9.5px; letter-spacing:.2em;
  color:var(--dim); white-space:nowrap;
}
.meta b{ color:rgba(120,240,255,.9); font-weight:700; }
.meta-clock{ color:rgba(150,200,230,.3); }

/* ================= Hero ================= */
.hero{ margin:clamp(40px,9vh,88px) 0 clamp(22px,4vh,34px); }
.hero-eyebrow{
  display:flex; align-items:center; gap:10px;
  font-family:var(--mono); font-size:10px; letter-spacing:.38em;
  color:rgba(150,225,255,.42);
}
.hero-eyebrow::before{
  content:""; width:26px; height:1px; flex:0 0 auto;
  background:linear-gradient(90deg, rgba(77,232,255,.8), rgba(77,232,255,0));
}
.hero-title{
  margin-top:16px;
  font-size:clamp(30px, 7.2vw, 62px);
  font-weight:900;
  line-height:1.16;
  letter-spacing:.015em;
}
.title-accent{
  display:inline-block;
  background:linear-gradient(96deg, #eafeff 0%, #8ceaff 30%, #4de8ff 52%, #8b5cff 82%, #ff4d9d 100%);
  -webkit-background-clip:text; background-clip:text; color:transparent;
  filter:drop-shadow(0 0 28px rgba(77,232,255,.26));
}
.hero-sub{
  margin-top:18px;
  max-width:560px;
  font-size:clamp(12px,2.7vw,13.5px);
  line-height:1.95;
  letter-spacing:.04em;
  color:var(--muted);
}

/* ================= 筛选 ================= */
.filters{
  display:flex; flex-wrap:wrap; gap:8px;
  margin:clamp(20px,4vh,32px) 0 clamp(16px,3vh,24px);
}
.filter-btn{
  display:inline-flex; align-items:center;
  padding:8px 15px;
  border-radius:999px;
  font-family:var(--font); font-size:11.5px; letter-spacing:.12em;
  color:rgba(190,230,250,.62);
  background:rgba(9,14,32,.55);
  border:1px solid rgba(120,200,255,.15);
  cursor:pointer;
  transition:color .22s ease, background .22s ease, border-color .22s ease, transform .22s ease, box-shadow .22s ease;
  -webkit-tap-highlight-color:transparent;
}
.filter-btn:hover{
  color:#dffbff; border-color:rgba(77,232,255,.35);
  background:rgba(77,232,255,.08);
  transform:translateY(-1px);
}
.filter-btn.active{
  color:#04121a; font-weight:700;
  background:linear-gradient(180deg, #d7fbff 0%, #4de8ff 100%);
  border-color:transparent;
  box-shadow:0 8px 22px rgba(77,232,255,.26), inset 0 1px 0 rgba(255,255,255,.6);
}
.filter-btn i{
  font-style:normal; margin-left:6px;
  font-family:var(--mono); font-size:9px;
  opacity:.55;
}
.filter-btn.active i{ opacity:.7; }

/* ================= 作品网格 ================= */
.grid{
  display:grid;
  grid-template-columns:repeat(auto-fill, minmax(min(100%, 322px), 1fr));
  gap:clamp(14px,2vw,22px);
}
.cell{
  min-width:0;
}
/* 没有 JS 时卡片直接可见，避免白屏 */
.js .cell{
  opacity:0; transform:translateY(20px);
  transition:opacity .55s ease, transform .6s var(--ease);
}
.js .cell.in{ opacity:1; transform:none; }
.cell.hide{ display:none; }

/* 卡片 */
.card{
  --rgb:77,232,255;
  position:relative;
  display:flex; flex-direction:column; justify-content:flex-end;
  min-height:clamp(228px, 31vh, 286px);
  padding:clamp(18px,2.3vw,25px);
  border-radius:22px;
  overflow:hidden; isolation:isolate;
  text-decoration:none; color:inherit;
  background:
    radial-gradient(130% 92% at 84% 4%, rgba(var(--rgb),.11) 0%, rgba(var(--rgb),0) 58%),
    linear-gradient(165deg, rgba(14,20,44,.9) 0%, rgba(6,8,20,.95) 100%);
  border:1px solid rgba(var(--rgb),.19);
  box-shadow:0 18px 46px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,255,255,.05);
  transform:perspective(1000px) rotateX(var(--rx,0deg)) rotateY(var(--ry,0deg)) translateY(0);
  transform-style:preserve-3d;
  transition:transform .2s ease-out, border-color .3s ease, box-shadow .35s ease;
}
.card:hover{
  transform:perspective(1000px) rotateX(var(--rx,0deg)) rotateY(var(--ry,0deg)) translateY(-6px);
  border-color:rgba(var(--rgb),.44);
  box-shadow:
    0 28px 62px rgba(0,0,0,.56),
    0 24px 60px -22px rgba(var(--rgb),.42),
    inset 0 1px 0 rgba(255,255,255,.08);
}
.card:focus-visible{
  outline:2px solid rgba(var(--rgb),.8);
  outline-offset:3px;
}
/* 跟随鼠标的卡片内光斑 */
.card::before{
  content:""; position:absolute; inset:0; z-index:0; pointer-events:none;
  background:radial-gradient(265px circle at var(--mx,50%) var(--my,6%), rgba(var(--rgb),.16) 0%, rgba(var(--rgb),0) 70%);
  opacity:0; transition:opacity .35s ease;
}
.card:hover::before{ opacity:1; }
/* 顶部发光线 */
.card::after{
  content:""; position:absolute; top:0; left:20%; right:20%; height:1px; z-index:1;
  background:linear-gradient(90deg, rgba(var(--rgb),0), rgba(var(--rgb),.85), rgba(var(--rgb),0));
  opacity:.4; transition:opacity .35s ease;
}
.card:hover::after{ opacity:1; }

.card-no{
  position:absolute; top:16px; left:clamp(18px,2.3vw,25px); z-index:2;
  display:flex; align-items:center; gap:8px;
  font-family:var(--mono); font-size:10.5px; font-weight:700; letter-spacing:.22em;
  color:rgba(var(--rgb),.62);
}
.card-no::before{
  content:""; width:14px; height:1px;
  background:currentColor; opacity:.7;
}

.card-art{
  position:absolute; top:-12px; right:-12px; z-index:1;
  width:clamp(114px, 37%, 156px); aspect-ratio:1;
  opacity:.92; pointer-events:none;
  filter:drop-shadow(0 12px 26px rgba(0,0,0,.42));
  transform:translateZ(22px);
  transition:transform .55s var(--ease), opacity .4s ease;
}
.card-art svg{ width:100%; height:100%; display:block; }
.card:hover .card-art{
  opacity:1;
  transform:translateZ(34px) scale(1.06) rotate(-4deg);
}

.card-body{ position:relative; z-index:2; }
.card-title-row{ display:flex; align-items:center; gap:8px; flex-wrap:wrap; }
.card-title{
  font-size:clamp(19px,2.5vw,23px);
  font-weight:800; letter-spacing:.04em;
}
.badge{
  font-family:var(--mono); font-size:8.5px; letter-spacing:.16em;
  padding:2px 7px; border-radius:5px;
  color:#04121a;
  background:linear-gradient(180deg, #e9feff, #4de8ff);
  box-shadow:0 0 12px rgba(77,232,255,.42);
  animation:badgePulse 2.6s ease-in-out infinite;
}
@keyframes badgePulse{
  0%,100%{ box-shadow:0 0 10px rgba(77,232,255,.3); }
  50%{ box-shadow:0 0 18px rgba(77,232,255,.65); }
}
.card-en{
  margin-top:5px;
  font-family:var(--mono); font-size:9.5px; letter-spacing:.28em;
  color:rgba(var(--rgb),.6);
}
.card-desc{
  margin-top:10px; max-width:34ch;
  font-size:12.5px; line-height:1.85; letter-spacing:.02em;
  color:var(--muted);
}
.card-foot{
  margin-top:16px;
  display:flex; align-items:center; justify-content:space-between; gap:10px;
}
.chips{ display:flex; flex-wrap:wrap; gap:6px; list-style:none; }
.chips li{
  font-family:var(--mono); font-size:9px; letter-spacing:.06em;
  padding:3px 7px; border-radius:6px;
  color:rgba(210,240,255,.6);
  background:rgba(255,255,255,.04);
  border:1px solid rgba(255,255,255,.07);
  white-space:nowrap;
}
.card-go{
  flex:0 0 auto;
  width:32px; height:32px; border-radius:50%;
  display:grid; place-items:center;
  color:rgba(var(--rgb),.95);
  background:rgba(var(--rgb),.08);
  border:1px solid rgba(var(--rgb),.35);
  transition:transform .3s var(--ease), background .3s ease;
}
.card-go svg{ width:14px; height:14px; }
.card:hover .card-go{
  transform:translateX(4px);
  background:rgba(var(--rgb),.2);
}

/* ================= 页脚 ================= */
.foot{
  margin-top:clamp(30px,6vh,56px);
  padding-top:18px;
  border-top:1px solid rgba(120,200,255,.1);
  display:flex; align-items:center; justify-content:space-between;
  gap:14px; flex-wrap:wrap;
  font-family:var(--mono); font-size:10px; letter-spacing:.16em;
  color:var(--dim);
}
.to-top{
  display:inline-flex; align-items:center; gap:8px;
  padding:8px 14px; border-radius:999px;
  font-family:var(--font); font-size:11px; letter-spacing:.12em;
  color:rgba(190,235,255,.72);
  background:rgba(10,16,34,.6);
  border:1px solid rgba(120,200,255,.16);
  cursor:pointer;
  transition:color .22s ease, border-color .22s ease, transform .22s ease, background .22s ease;
  -webkit-tap-highlight-color:transparent;
}
.to-top:hover{
  color:#eafeff;
  border-color:rgba(77,232,255,.42);
  background:rgba(77,232,255,.1);
  transform:translateY(-2px);
}
.to-top svg{ width:13px; height:13px; }

/* ================= 滚动条 ================= */
::-webkit-scrollbar{ width:10px; height:10px; }
::-webkit-scrollbar-track{ background:rgba(4,6,16,.6); }
::-webkit-scrollbar-thumb{
  background:linear-gradient(180deg, rgba(77,232,255,.32), rgba(139,92,255,.32));
  border-radius:99px;
  border:2px solid rgba(4,6,16,.8);
}
::-webkit-scrollbar-thumb:hover{ background:rgba(77,232,255,.5); }

/* ================= 自适应 ================= */
@media (max-width:900px){
  .hero{ margin:clamp(30px,7vh,60px) 0 26px; }
  .grid{ grid-template-columns:repeat(auto-fill, minmax(min(100%, 290px), 1fr)); }
}

@media (max-width:620px){
  body{ background-attachment:scroll; }
  .page{ padding-left:16px; padding-right:16px; }
  .hero-title{ font-size:clamp(27px,8.4vw,38px); }
  .hero-sub{ margin-top:14px; }
  .meta-clock{ display:none; }
  .card{ min-height:214px; }
  .card-art{ width:118px; top:-8px; right:-8px; opacity:.86; }
  .card-desc{ font-size:12px; max-width:30ch; }
  .grid{ gap:14px; }
}

@media (max-width:400px){
  .brand-eyebrow{ display:none; }
  .brand-name{ font-size:13px; letter-spacing:.14em; }
  .brand-mark{ width:32px; height:32px; }
  .card{ padding:16px; min-height:206px; }
  .card-art{ width:104px; opacity:.8; }
  .card-title{ font-size:18px; }
  .chips li{ font-size:8.5px; padding:2px 6px; }
  .filter-btn{ padding:7px 13px; font-size:11px; }
  .foot{ font-size:9px; }
}

@media (max-height:560px) and (orientation:landscape){
  .hero{ margin:22px 0 16px; }
  .hero-title{ font-size:clamp(22px,5.6vh,32px); }
  .hero-sub,.hero-eyebrow{ display:none; }
  .grid{ grid-template-columns:repeat(auto-fill, minmax(min(100%, 296px), 1fr)); }
  .card{ min-height:186px; }
  .card-desc{ display:none; }
  .filters{ margin:14px 0; }
}

@media (hover:none){
  .glow-follow{ display:none; }
  .card-art{ transform:none; }
  .card:hover{ transform:none; }
}

@media (prefers-reduced-motion:reduce){
  html{ scroll-behavior:auto; }
  .brand-mark,.brand-mark circle:first-of-type,.badge{ animation:none; }
  .js .cell{ opacity:1; transform:none; transition:none; }
  .card,.card-art,.card-go{ transition:border-color .2s ease, box-shadow .2s ease, color .2s ease; }
}
