/* ==========================================================================
   前台样式表（首页 / 创作者主页 / 登录注册）
   想改颜色：看最上面 :root 里那几行
   ========================================================================== */

:root{
  --bg:      #f7f2ea;
  --panel:   rgba(255,255,255,.72);
  --panel2:  rgba(255,255,255,.9);
  --line:    rgba(120,85,50,.16);
  --text:    #2b1f17;
  --muted:   #7d6a5a;
  --brand1:  #e8662a;
  --brand2:  #efa41f;
  --brand3:  #e04456;
  --radius:  18px;
}

*{ margin:0; padding:0; box-sizing:border-box; }
html{ scroll-behavior:smooth; }
body{
  background:var(--bg); color:var(--text);
  font-family:"PingFang SC","Microsoft YaHei","Helvetica Neue",system-ui,-apple-system,sans-serif;
  line-height:1.7; -webkit-font-smoothing:antialiased; overflow-x:hidden;
  -webkit-text-size-adjust:100%; text-size-adjust:100%;
}
a{ color:inherit; text-decoration:none; }
img{ display:block; max-width:100%; }
button{ font-family:inherit; }
::selection{ background:var(--brand1); color:#fff; }

.aurora{
  position:fixed; inset:0; z-index:0; pointer-events:none;
  background:
    radial-gradient(52vw 52vw at 10% -10%, rgba(255,140,70,.1), transparent 65%),
    radial-gradient(42vw 42vw at 92% 6%,  rgba(255,190,90,.08), transparent 62%),
    radial-gradient(58vw 40vw at 50% 110%, rgba(255,110,90,.055), transparent 65%);
}
.wrap{ position:relative; z-index:1; }

/* ---------- 导航 ---------- */
nav{
  position:fixed; top:0; left:0; right:0; z-index:50;
  display:flex; align-items:center; justify-content:space-between; gap:16px;
  padding:15px 30px; border-bottom:1px solid transparent;
  transition:background .3s, backdrop-filter .3s, border-color .3s;
}
nav.scrolled{
  background:rgba(255,252,247,.82);
  backdrop-filter:blur(16px) saturate(160%);
  border-bottom-color:var(--line);
}
.logo{
  display:flex; align-items:center; gap:9px;
  font-weight:800; font-size:17px; letter-spacing:-.02em;
}
.logo .dot{
  width:9px; height:9px; border-radius:50%;
  background:linear-gradient(135deg,var(--brand2),var(--brand1));
  box-shadow:0 0 14px var(--brand2); flex:0 0 auto;
}
.nav-links{ display:flex; gap:6px; align-items:center; }
.nav-links a{
  padding:8px 14px; border-radius:99px; font-size:14.5px;
  color:var(--muted); transition:.25s; white-space:nowrap;
}
.nav-links a:hover{ color:var(--text); background:rgba(255,255,255,.78); }
.nav-cta{
  padding:9px 18px !important; border-radius:99px;
  color:#1a0f06 !important; font-weight:700;
  background:linear-gradient(135deg,var(--brand2),var(--brand1));
}
.nav-cta:hover{ transform:translateY(-1px); box-shadow:0 8px 24px rgba(255,122,61,.4); }
.nav-user{ display:flex; align-items:center; gap:9px; }
.nav-avatar{
  width:30px; height:30px; border-radius:50%; object-fit:cover;
  border:1.5px solid rgba(120,85,50,.26); flex:0 0 auto;
}
.nav-avatar.txt{
  display:flex; align-items:center; justify-content:center;
  background:linear-gradient(135deg,var(--brand1),var(--brand2));
  font-size:13px; font-weight:800; color:#1a0f06;
}

/* ---------- 按钮 ---------- */
.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:9px;
  padding:13px 26px; border-radius:99px; font-size:15px; font-weight:700;
  cursor:pointer; border:1px solid transparent; transition:.28s;
}
.btn-primary{
  color:#1a0f06; background:linear-gradient(135deg,var(--brand2),var(--brand1));
  box-shadow:0 10px 30px rgba(255,122,61,.3);
}
.btn-primary:hover{ transform:translateY(-2px); box-shadow:0 16px 40px rgba(255,122,61,.48); }
.btn-ghost{ color:var(--text); border-color:var(--line); background:rgba(255,255,255,.65); }
.btn-ghost:hover{ background:rgba(255,255,255,.85); transform:translateY(-2px); }
.btn:disabled{ opacity:.55; cursor:not-allowed; transform:none !important; }

/* ---------- 首屏 ---------- */
header.hero{
  display:flex; flex-direction:column; justify-content:center; align-items:center; text-align:center;
  max-width:1120px; margin:0 auto; padding:148px 30px 80px;
}
.hero-pill{
  display:inline-flex; align-items:center; gap:8px; align-self:center;
  padding:6px 15px; border-radius:99px; margin-bottom:24px;
  border:1px solid var(--line); background:rgba(255,255,255,.65);
  font-size:13px; color:var(--muted); letter-spacing:.05em;
}
.hero-pill .live{
  width:7px; height:7px; border-radius:50%; background:#22a559;
  animation:pulse 2.4s infinite;
}
@keyframes pulse{
  0%{ box-shadow:0 0 0 0 rgba(61,220,132,.55); }
  70%{ box-shadow:0 0 0 10px rgba(61,220,132,0); }
  100%{ box-shadow:0 0 0 0 rgba(61,220,132,0); }
}
h1.hero-title{
  font-size:clamp(36px, 6.4vw, 68px); line-height:1.08;
  font-weight:800; letter-spacing:-.045em; margin-bottom:18px;
}
h1.hero-title .grad{
  background:linear-gradient(110deg,#d97706,var(--brand1) 50%,var(--brand3));
  -webkit-background-clip:text; background-clip:text; color:transparent;
}
.hero-tagline{
  font-size:clamp(16px,2vw,21px); color:var(--muted);
  max-width:660px; margin-bottom:34px; white-space:pre-line;
}
.hero-btns{ display:flex; gap:14px; flex-wrap:wrap; justify-content:center; }

/* ---------- 区块 ---------- */
section{ padding:84px 30px; max-width:1120px; margin:0 auto; }
.sec-head{
  display:flex; align-items:center; justify-content:center; text-align:center;
  gap:20px; flex-wrap:wrap; margin-bottom:34px;
}
.sec-kicker{
  font-size:12.5px; font-weight:700; letter-spacing:.22em;
  text-transform:uppercase; color:var(--brand2); margin-bottom:12px;
}
.sec-title{
  font-size:clamp(26px,3.8vw,38px); font-weight:800;
  letter-spacing:-.035em; line-height:1.15;
}
.sec-desc{ color:var(--muted); margin-top:12px; max-width:620px; margin-left:auto; margin-right:auto; }

/* ---------- 分类 / 标签切换 ---------- */
.filters{ display:flex; gap:10px; flex-wrap:wrap; margin-bottom:28px; }
.filter{
  padding:8px 18px; border-radius:99px; font-size:14px;
  color:var(--muted); cursor:pointer; transition:.25s;
  border:1px solid var(--line); background:transparent;
}
.filter:hover{ color:var(--text); border-color:rgba(120,85,50,.3); }
.filter.active{
  color:#1a0f06; font-weight:700; border-color:transparent;
  background:linear-gradient(135deg,var(--brand2),var(--brand1));
}

/* ---------- 创作者卡片 ---------- */
.creators{
  display:grid; gap:16px; justify-content:center;
  grid-template-columns:repeat(auto-fit, minmax(250px, 300px));
}
.creator{
  display:flex; align-items:center; gap:14px; min-width:0;
  padding:18px 20px; border-radius:var(--radius);
  background:var(--panel); border:1px solid var(--line);
  transition:.3s; cursor:pointer;
}
.creator:hover{
  transform:translateY(-4px);
  border-color:rgba(255,122,61,.5);
  background:var(--panel2);
  box-shadow:0 18px 44px rgba(90,60,35,.16);
}
.avatar{
  width:52px; height:52px; border-radius:50%; flex:0 0 auto;
  object-fit:cover; border:2px solid rgba(120,85,50,.2);
}
.avatar.txt{
  display:flex; align-items:center; justify-content:center;
  background:linear-gradient(135deg,var(--brand1),var(--brand2));
  font-size:20px; font-weight:800; color:#1a0f06; letter-spacing:-.02em;
}
.creator-info{ min-width:0; flex:1; }
.creator-name{
  font-size:16px; font-weight:700; letter-spacing:-.02em;
  white-space:nowrap; overflow:hidden; text-overflow:ellipsis;
}
.creator-bio{
  font-size:12.5px; color:var(--muted); margin-top:3px;
  display:-webkit-box; -webkit-line-clamp:1; -webkit-box-orient:vertical;
  overflow:hidden;
}
.creator-count{
  font-size:12px; color:var(--brand2); margin-top:5px; font-weight:600;
}

/* ---------- 作品卡片 ---------- */
.grid{
  display:grid; gap:20px; justify-content:center;
  grid-template-columns:repeat(auto-fit, minmax(300px, 380px));
}
.card{
  position:relative; border-radius:var(--radius); overflow:hidden; min-width:0;
  background:var(--panel); border:1px solid var(--line); cursor:pointer;
  transition:transform .38s cubic-bezier(.2,.8,.2,1), border-color .3s, box-shadow .38s;
  display:flex; flex-direction:column;
}
.card:hover{
  transform:translateY(-6px); border-color:rgba(255,122,61,.55);
  box-shadow:0 22px 55px rgba(90,60,35,.18);
}
.card-cover{
  position:relative; aspect-ratio:16/10; overflow:hidden;
  display:flex; align-items:center; justify-content:center;
  font-size:52px; background:linear-gradient(135deg,#f8f2ea,#efe6da);
  flex:0 0 auto;
}
.card-cover img{ width:100%; height:100%; object-fit:cover; transition:transform .7s cubic-bezier(.2,.8,.2,1); }
.card:hover .card-cover img{ transform:scale(1.06); }
.card-cover::after{
  content:""; position:absolute; inset:0; z-index:1;
  background:linear-gradient(to top, rgba(13,9,6,.8), transparent 60%);
}
.cover-fallback{
  position:absolute; inset:0; z-index:2;
  display:flex; align-items:center; justify-content:center;
}
.cover-fallback span{ font-size:52px; line-height:1; filter:drop-shadow(0 6px 22px rgba(0,0,0,.4)); }
.card-tag{
  position:absolute; top:13px; left:13px; z-index:3;
  padding:4px 11px; border-radius:99px; font-size:11.5px; font-weight:700;
  background:rgba(13,9,6,.66); backdrop-filter:blur(10px);
  border:1px solid rgba(120,85,50,.22);
}
.card-tag.right{ left:auto; right:13px; }
.card-tag.video{ border-color:rgba(255,77,94,.5); color:#c2410c; }
.card-badge{
  position:absolute; top:13px; right:13px; z-index:3;
  display:flex; align-items:center; gap:5px;
  padding:4px 10px; border-radius:99px; font-size:11.5px; font-weight:700;
  background:rgba(13,9,6,.66); backdrop-filter:blur(10px);
  border:1px solid rgba(120,85,50,.22); color:#3a2d24;
}
.card-body{ padding:18px 20px 22px; flex:1; display:flex; flex-direction:column; }
.card-title{
  font-size:17.5px; font-weight:700; letter-spacing:-.02em; margin-bottom:6px;
}
.card-text{ font-size:13.5px; color:var(--muted); line-height:1.6; flex:1; }
.card-foot{
  display:flex; align-items:center; justify-content:space-between;
  gap:10px; margin-top:14px; padding-top:13px;
  border-top:1px solid rgba(255,255,255,.75);
}
.card-owner{ display:flex; align-items:center; gap:7px; font-size:12.5px; color:var(--muted); min-width:0; }
.card-owner .avatar{ width:22px; height:22px; font-size:10px; border-width:1px; }
.card-owner span{ white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.card-views{ font-size:12px; color:#6f5f52; white-space:nowrap; }

.empty{
  padding:70px 24px; text-align:center; color:var(--muted);
  border:1px dashed var(--line); border-radius:var(--radius);
}
.empty .big{ font-size:44px; margin-bottom:14px; opacity:.6; }

.reveal{ opacity:0; transform:translateY(22px); transition:opacity .65s, transform .65s; }
.reveal.in{ opacity:1; transform:none; }

/* ---------- 创作者主页头部 ---------- */
.profile-head{
  max-width:1120px; margin:0 auto; padding:130px 30px 0;
}
.profile-card{
  display:flex; align-items:center; gap:26px; flex-wrap:wrap; min-width:0;
  padding:34px; border-radius:24px;
  background:
    radial-gradient(60% 120% at 0% 0%, rgba(255,122,61,.2), transparent 70%),
    var(--panel);
  border:1px solid var(--line);
}
.profile-card .avatar{ width:96px; height:96px; font-size:36px; border-width:3px; }
.profile-main{ flex:1; min-width:220px; }
.profile-name{
  font-size:clamp(26px,4vw,38px); font-weight:800;
  letter-spacing:-.035em; line-height:1.15;
}
.profile-handle{ color:var(--muted); font-size:14px; margin-top:4px; }
.profile-bio{ color:#4a3b30; margin-top:12px; white-space:pre-line; max-width:640px; }
.profile-stats{ display:flex; gap:34px; flex-wrap:wrap; margin-top:20px; }
.profile-stats .n{
  font-size:23px; font-weight:800; letter-spacing:-.03em;
  background:linear-gradient(135deg,var(--brand1),#b45309);
  -webkit-background-clip:text; background-clip:text; color:transparent;
}
.profile-stats .l{ font-size:12px; color:var(--muted); }

/* ---------- 详情弹窗 ---------- */
.modal{
  position:fixed; inset:0; z-index:100; display:none;
  align-items:center; justify-content:center; padding:22px;
  background:rgba(72,52,34,.4); backdrop-filter:blur(12px);
}
.modal.open{ display:flex; animation:fade .3s; }
@keyframes fade{ from{opacity:0} to{opacity:1} }
.modal-card{
  position:relative; width:100%; max-width:900px; min-width:0; max-height:90vh; overflow-y:auto;
  border-radius:22px; border:1px solid rgba(120,85,50,.2);
  background:#fffdfb; box-shadow:0 40px 100px rgba(90,60,35,.26);
  animation:pop .36s cubic-bezier(.2,.8,.2,1);
}
@keyframes pop{ from{opacity:0; transform:translateY(22px) scale(.97)} to{opacity:1; transform:none} }
.modal-close{
  position:absolute; top:15px; right:15px; z-index:5;
  width:38px; height:38px; border-radius:50%; cursor:pointer;
  border:1px solid rgba(120,85,50,.26); background:rgba(13,9,6,.75);
  color:#fff; font-size:18px; display:flex; align-items:center; justify-content:center;
  backdrop-filter:blur(10px); transition:.25s;
}
.modal-close:hover{ background:var(--brand3); border-color:var(--brand3); transform:rotate(90deg); }
.modal-body{ padding:28px 32px 38px; }
.modal-body h3{ font-size:24px; font-weight:800; letter-spacing:-.03em; margin-bottom:10px; }
.modal-meta{
  display:flex; gap:14px; flex-wrap:wrap; align-items:center;
  font-size:13px; color:var(--muted); margin-bottom:22px;
}
.modal-meta .who{ display:flex; align-items:center; gap:7px; color:var(--text); }
.modal-meta .avatar{ width:24px; height:24px; font-size:11px; border-width:1px; }
.modal-content{
  color:#4a3b30; white-space:pre-wrap; line-height:1.85; font-size:15px;
  margin-bottom:8px;
}

/* ---------- 媒体网格（详情里的图片/视频） ---------- */
.media-grid{
  display:grid; gap:10px; margin-bottom:22px;
  grid-template-columns:repeat(2, 1fr);
}
.media-grid.single{ grid-template-columns:1fr; }
.media-grid.triple{ grid-template-columns:repeat(3, 1fr); }
.media-item{
  position:relative; border-radius:12px; overflow:hidden;
  background:#efe7db; cursor:zoom-in;
}
.media-item img,
.media-item video{
  width:100%; height:auto; display:block;
  max-height:520px; object-fit:cover; background:#150d07;
}
.media-grid.single .media-item img,
.media-grid.single .media-item video{
  max-height:70vh; object-fit:contain; background:#000;
}
.media-item video{ cursor:default; }
.media-play{
  position:absolute; inset:0; display:flex; align-items:center; justify-content:center;
  background:rgba(0,0,0,.28); pointer-events:none;
}
.media-play span{
  width:52px; height:52px; border-radius:50%;
  background:rgba(120,85,50,.22); backdrop-filter:blur(6px);
  border:1.5px solid rgba(255,255,255,.5);
  display:flex; align-items:center; justify-content:center;
  font-size:19px; color:#fff;
}

/* 大图查看 */
.lightbox{
  position:fixed; inset:0; z-index:200; display:none;
  align-items:center; justify-content:center; padding:20px;
  background:rgba(0,0,0,.94);
}
.lightbox.open{ display:flex; }
.lightbox img{ max-width:100%; max-height:92vh; object-fit:contain; border-radius:8px; }
.lightbox video{ max-width:100%; max-height:92vh; border-radius:8px; }
.lightbox .lb-close{
  position:absolute; top:20px; right:24px;
  width:42px; height:42px; border-radius:50%; cursor:pointer;
  border:1px solid rgba(120,85,50,.3); background:rgba(255,255,255,.8);
  color:#fff; font-size:20px;
}

/* ---------- 表单 ---------- */
.field{ margin-bottom:16px; }
.field label{ display:block; font-size:13.5px; color:var(--muted); margin-bottom:7px; }
.field label .req{ color:var(--brand3); }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=date], textarea, select{
  width:100%; padding:12px 15px; border-radius:12px; font-size:15px;
  background:rgba(255,255,255,.7); border:1px solid var(--line);
  color:var(--text); font-family:inherit; transition:.2s;
}
input:focus, textarea:focus, select:focus{
  outline:none; border-color:var(--brand1);
  background:rgba(255,255,255,.8);
  box-shadow:0 0 0 3px rgba(255,122,61,.16);
}
textarea{ resize:vertical; min-height:120px; line-height:1.7; }
.row2{ display:grid; grid-template-columns:1fr 1fr; gap:14px; }
.hint{ font-size:12.5px; color:#6f5f52; margin-top:6px; }

/* ---------- 登录注册页 ---------- */
.auth-wrap{
  min-height:100vh; display:flex; align-items:center; justify-content:center;
  padding:100px 24px 60px;
}
.auth-card{
  position:relative; width:100%; max-width:430px; min-width:0;
  padding:40px 36px; border-radius:24px;
  background:rgba(255,253,251,.95); backdrop-filter:blur(20px);
  border:1px solid rgba(120,85,50,.18);
  box-shadow:0 40px 100px rgba(90,60,35,.2);
}
.auth-card .badge{
  width:52px; height:52px; border-radius:16px; margin-bottom:20px;
  display:flex; align-items:center; justify-content:center; font-size:24px;
  background:linear-gradient(135deg,var(--brand2),var(--brand1));
}
.auth-card h1{ font-size:25px; font-weight:800; letter-spacing:-.03em; margin-bottom:6px; }
.auth-card .sub{ color:var(--muted); font-size:14px; margin-bottom:26px; }
.auth-tabs{
  display:flex; gap:6px; padding:5px; border-radius:14px;
  background:rgba(255,255,255,.7); margin-bottom:24px;
}
.auth-tabs button{
  flex:1; padding:10px; border-radius:10px; font-size:14.5px; font-weight:600;
  background:transparent; border:none; color:var(--muted); cursor:pointer; transition:.24s;
}
.auth-tabs button.active{
  background:linear-gradient(135deg,var(--brand2),var(--brand1));
  color:#1a0f06 !important;
  font-weight:800;
}
.auth-alt{ text-align:center; font-size:13.5px; color:var(--muted); margin-top:18px; }
.auth-alt a{ color:var(--brand2); font-weight:600; }

/* ---------- 留言 ---------- */
.msg-wrap{ max-width:680px; margin:28px auto 0; }

/* ---------- 页脚 ---------- */
footer{
  padding:40px 30px 60px; text-align:center;
  color:#6f5f52; font-size:13px; border-top:1px solid var(--line); margin-top:20px;
}
footer a{ color:var(--muted); }
footer a:hover{ color:var(--brand2); }

/* 备案信息：工信部 ICP 备案号（必显）+ 公安联网备案（通过后启用） */
footer .icp{ margin-top:8px; font-size:12.5px; line-height:1.7; letter-spacing:.2px; }
footer .icp a{ color:#8b7a6a; }
footer .icp a:hover{ color:var(--brand1); text-decoration:underline; }
footer .icp .sep{ margin:0 7px; color:rgba(120,85,50,.28); }

/* ---------- 提示 ---------- */
.toast{
  position:fixed; left:50%; bottom:34px; transform:translate(-50%, 26px);
  padding:13px 26px; border-radius:99px; font-size:14.5px; font-weight:600;
  background:#fffdfb; border:1px solid var(--line); color:var(--text);
  box-shadow:0 18px 50px rgba(90,60,35,.2); z-index:300;
  opacity:0; pointer-events:none; transition:.32s; max-width:90vw;
}
.toast.show{ opacity:1; transform:translate(-50%, 0); }
.toast.ok{ border-color:rgba(61,220,132,.5); }
.toast.err{ border-color:rgba(255,77,94,.5); }

/* ---------- 手机 ---------- */
@media (max-width:860px){
  /* 输入框字号必须是 16px，否则 iPhone 一点输入框就自动放大整个页面 */
  input[type=text], input[type=email], input[type=password], input[type=number],
  input[type=date], input[type=search], textarea, select{
    font-size:16px !important;
  }
  nav{ padding:13px 18px; }
  .nav-links a.hide-sm{ display:none; }
  header.hero{ padding:118px 20px 56px; }
  section{ padding:60px 20px; }
  .profile-head{ padding:110px 18px 0; }
  .profile-card{ padding:24px; gap:18px; }
  .profile-card .avatar{ width:72px; height:72px; font-size:28px; }
  .row2{ grid-template-columns:1fr; }
  .modal-body{ padding:22px 18px 30px; }
  .media-grid{ grid-template-columns:1fr 1fr; }
  .grid{ grid-template-columns:1fr; }
  .creators{ grid-template-columns:1fr; }
  .profile-stats{ gap:24px; }
}