/* ============================================================
   找好服 www.ZhaoHF123.com - 传奇私服发布网 全站样式
   暗黑红金国风主题 · 自适应 PC / 手机
   ============================================================ */

/* ---------- 设计变量 ---------- */
:root {
  --gold: #ffd24a;
  --gold-2: #ffb800;
  --gold-3: #ff9d00;
  --red: #e0261a;
  --red-2: #a3121f;
  --bg: #100a10;
  --panel: rgba(25, 14, 18, .92);
  --panel-2: rgba(31, 17, 22, .95);
  --line: rgba(255, 190, 60, .20);
  --line-soft: rgba(255, 255, 255, .08);
  --text: #f2e8d8;
  --muted: #b8a795;
  --dim: #8d7e6f;
  --grad-gold: linear-gradient(135deg, #ffd24a, #ff9d00);
  --grad-red: linear-gradient(135deg, #e0261a, #7a0f18);
  --shadow: 0 10px 34px rgba(0, 0, 0, .5);
  --radius: 12px;
}

/* ---------- 基础重置 ---------- */
* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: "Microsoft YaHei", "微软雅黑", "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", sans-serif;
  font-size: 15px;
  line-height: 1.7;
  color: var(--text);
  background-color: var(--bg);
  background-image: url("../images/bj.png");
  background-size: cover;
  background-attachment: fixed;
  background-position: center top;
  background-repeat: no-repeat;
  min-height: 100vh;
}

/* 背景遮罩，保证文字可读性 */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(10, 5, 9, .78) 0%, rgba(14, 7, 11, .82) 45%, rgba(9, 5, 9, .9) 100%);
  pointer-events: none;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
input, select { font-family: inherit; }

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;
}

/* ============================================================
   顶部 / 导航
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: linear-gradient(180deg, #1d0f15 0%, #140a10 100%);
  border-bottom: 2px solid var(--line);
  box-shadow: 0 4px 22px rgba(0, 0, 0, .45);
}

.topbar { border-bottom: 1px solid rgba(255, 255, 255, .06); }
.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 10px;
  padding-bottom: 10px;
  gap: 14px;
}

.brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.brand-logo {
  width: 62px;
  height: 62px;
  border-radius: 10px;
  box-shadow: 0 0 18px rgba(255, 178, 0, .35), inset 0 0 0 1px rgba(255, 210, 74, .5);
}
.brand-text { line-height: 1.35; }
.brand-text strong {
  display: block;
  font-size: 26px;
  font-weight: 800;
  letter-spacing: 2px;
  background: linear-gradient(180deg, #ffe9a3, #ffb800 55%, #ff7a00);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 22px rgba(255, 180, 40, .25);
}
.brand-text em {
  display: block;
  font-style: normal;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 1px;
}

.top-search { display: flex; align-items: center; gap: 8px; }
.top-search input {
  width: 220px;
  padding: 9px 14px;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, .45);
  color: var(--text);
  outline: none;
  transition: border-color .25s;
}
.top-search input:focus { border-color: var(--gold-2); }
.top-search button {
  padding: 9px 18px;
  border-radius: 20px;
  background: var(--grad-gold);
  color: #2a1700;
  font-weight: 700;
  transition: transform .2s, box-shadow .2s;
}
.top-search button:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(255, 170, 0, .4); }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.nav-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--gold);
  border-radius: 2px;
  transition: transform .3s, opacity .3s;
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.main-nav { border-top: 1px solid rgba(255, 255, 255, .05); }
.nav-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2px;
}
.nav-inner a {
  position: relative;
  display: block;
  padding: 10px 9px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  transition: color .2s, background .2s;
}
.nav-inner a::after {
  content: "";
  position: absolute;
  left: 9px;
  right: 9px;
  bottom: 4px;
  height: 2px;
  border-radius: 2px;
  background: var(--grad-gold);
  transform: scaleX(0);
  transition: transform .25s;
}
.nav-inner a:hover { color: var(--gold); }
.nav-inner a:hover::after,
.nav-inner a.active::after { transform: scaleX(1); }
.nav-inner a.active { color: var(--gold); }

/* ============================================================
   横幅 / 广告位
   ============================================================ */
.hero-banner {
  margin: 16px auto 0;
  max-width: 1200px;
  padding: 0 16px;
}
.hero-banner img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: var(--shadow), 0 0 0 1px var(--line);
}

.ad-slot {
  max-width: 1200px;
  margin: 14px auto 0;
  padding: 0 16px;
}
.ad-slot .ad-box {
  min-height: 90px;
  border: 1px dashed var(--line);
  border-radius: 10px;
  background: rgba(10, 6, 10, .6);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* ============================================================
   通用区块
   ============================================================ */
.main { padding: 20px 0 40px; }

.section { margin-bottom: 26px; }

.panel {
  background: var(--panel);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 18px 20px;
  box-shadow: var(--shadow);
}

.section-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  font-size: 20px;
  font-weight: 800;
  color: #fff;
  letter-spacing: 1px;
}
.section-title::before {
  content: "";
  width: 5px;
  height: 22px;
  border-radius: 3px;
  background: var(--grad-gold);
  box-shadow: 0 0 10px rgba(255, 180, 40, .6);
}
.section-title .title-more {
  margin-left: auto;
  font-size: 13px;
  font-weight: 400;
  color: var(--muted);
}
.section-title .title-more:hover { color: var(--gold); }

.sub-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--gold-2);
  margin: 18px 0 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.sub-title::before {
  content: "◆";
  font-size: 12px;
  color: var(--gold-3);
}

/* 面包屑 */
.crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--dim);
  padding: 14px 0 4px;
}
.crumb a:hover { color: var(--gold); }
.crumb .sep { color: var(--dim); opacity: .6; }

/* ============================================================
   开服表
   ============================================================ */
.sf-table-wrap { overflow-x: auto; }
.sf-table { width: 100%; border-collapse: collapse; min-width: 720px; }
.sf-table th {
  background: linear-gradient(180deg, rgba(255, 180, 40, .18), rgba(255, 140, 20, .08));
  color: var(--gold-2);
  font-size: 13px;
  font-weight: 700;
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
.sf-table td {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, .05);
  font-size: 14px;
  vertical-align: middle;
}
.sf-table tbody tr { transition: background .2s; }
.sf-table tbody tr:hover { background: rgba(255, 200, 80, .06); }
.sf-table .sf-name { font-weight: 700; color: #fff; white-space: nowrap; }
.sf-table .sf-name a:hover { color: var(--gold); }
.sf-table .sf-cat { color: var(--gold-2); white-space: nowrap; }
.sf-table .sf-time { color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.sf-table .sf-ratio { color: var(--muted); white-space: nowrap; }
.sf-table .sf-zone { color: var(--muted); white-space: nowrap; }
.sf-table .sf-tags span {
  display: inline-block;
  font-size: 12px;
  padding: 1px 8px;
  margin: 2px 3px 2px 0;
  border-radius: 10px;
  background: rgba(255, 255, 255, .08);
  color: var(--muted);
  white-space: nowrap;
}
.sf-table .sf-score { color: var(--gold); font-weight: 700; white-space: nowrap; }

.badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  padding: 1px 9px;
  border-radius: 10px;
  white-space: nowrap;
}
.badge-hot { background: var(--grad-red); color: #fff; box-shadow: 0 0 10px rgba(224, 38, 26, .5); }
.badge-new { background: linear-gradient(135deg, #2ec27e, #0e9f6e); color: #fff; }
.badge-cd { background: rgba(255, 170, 0, .16); color: var(--gold-2); }
.badge-normal { background: rgba(255, 255, 255, .1); color: var(--muted); }

.btn-dl {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 8px;
  background: var(--grad-gold);
  color: #2a1700;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  transition: transform .2s, box-shadow .2s;
}
.btn-dl:hover { transform: translateY(-1px); box-shadow: 0 6px 16px rgba(255, 170, 0, .45); }

.countdown { color: var(--gold-2); font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.countdown .cd-num {
  display: inline-block;
  min-width: 22px;
  text-align: center;
  background: rgba(255, 170, 0, .14);
  border: 1px solid rgba(255, 190, 60, .35);
  border-radius: 5px;
  padding: 0 4px;
  margin: 0 1px;
}

/* 筛选栏 */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}
.filter-bar select, .filter-bar input {
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, .4);
  color: var(--text);
  outline: none;
  font-size: 14px;
}
.filter-bar input { width: 220px; }
.filter-bar select:focus, .filter-bar input:focus { border-color: var(--gold-2); }
.filter-bar .fbtn {
  padding: 8px 18px;
  border-radius: 8px;
  background: var(--grad-gold);
  color: #2a1700;
  font-weight: 700;
}

/* ============================================================
   卡片 / 网格
   ============================================================ */
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-5 { grid-template-columns: repeat(5, 1fr); }

.game-card {
  position: relative;
  border-radius: var(--radius);
  border: 1px solid var(--line-soft);
  background: var(--panel-2);
  overflow: hidden;
  transition: transform .25s, box-shadow .25s, border-color .25s;
}
.game-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow), 0 0 0 1px var(--line);
  border-color: var(--line);
}
.game-card .card-img { position: relative; overflow: hidden; }
.game-card .card-img img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform .5s;
}
.game-card:hover .card-img img { transform: scale(1.06); }
.game-card .card-mask {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 45%, rgba(10, 5, 8, .88));
}
.game-card .card-body { padding: 12px 14px 14px; }
.game-card .card-title { font-size: 16px; font-weight: 700; color: #fff; margin-bottom: 4px; }
.game-card .card-title a:hover { color: var(--gold); }
.game-card .card-desc {
  font-size: 13px;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.game-card .card-tags { margin-top: 8px; }

/* 版本大分类卡 */
.cat-card .card-img img { aspect-ratio: 4 / 3; }
.cat-card .card-mask {
  background: linear-gradient(180deg, transparent 30%, rgba(8, 4, 7, .92));
}
.cat-card .cat-num {
  position: absolute;
  top: 10px;
  left: 10px;
  font-size: 12px;
  padding: 2px 10px;
  border-radius: 10px;
  background: rgba(0, 0, 0, .55);
  border: 1px solid var(--line);
  color: var(--gold-2);
}

/* 资讯 / 攻略条目 */
.news-list { display: grid; gap: 12px; }
.news-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, .03);
  border: 1px solid transparent;
  transition: background .2s, border-color .2s;
}
.news-item:hover { background: rgba(255, 200, 80, .05); border-color: var(--line-soft); }
.news-item img {
  width: 150px;
  height: 96px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
}
.news-item h3 { font-size: 15px; font-weight: 700; color: #fff; margin-bottom: 4px; }
.news-item h3 a:hover { color: var(--gold); }
.news-item p { font-size: 13px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.news-item .news-meta { margin-top: 6px; font-size: 12px; color: var(--dim); }

/* ============================================================
   搜索 / FAQ / 提示块
   ============================================================ */
.search-block {
  display: flex;
  gap: 10px;
  max-width: 640px;
  margin: 0 auto 6px;
}
.search-block input {
  flex: 1;
  padding: 12px 18px;
  border-radius: 24px;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, .5);
  color: var(--text);
  font-size: 15px;
  outline: none;
}
.search-block input:focus { border-color: var(--gold-2); box-shadow: 0 0 0 3px rgba(255, 180, 40, .15); }
.search-block button {
  padding: 12px 30px;
  border-radius: 24px;
  background: var(--grad-gold);
  color: #2a1700;
  font-size: 15px;
  font-weight: 800;
}
.search-tip { text-align: center; font-size: 12px; color: var(--dim); }
.search-tip a { color: var(--gold-2); }

#searchResult { display: none; }
#searchResult.show { display: block; }

.faq details {
  border: 1px solid var(--line-soft);
  border-radius: 10px;
  background: rgba(255, 255, 255, .03);
  margin-bottom: 10px;
  overflow: hidden;
}
.faq summary {
  cursor: pointer;
  padding: 13px 16px;
  font-weight: 700;
  color: #fff;
  font-size: 15px;
  list-style: none;
  position: relative;
  padding-right: 42px;
  transition: color .2s, background .2s;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 20px;
  color: var(--gold-2);
  transition: transform .25s;
}
.faq details[open] summary { background: rgba(255, 180, 40, .06); color: var(--gold-2); }
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details .faq-a { padding: 4px 16px 14px; font-size: 14px; color: var(--muted); }
.faq details .faq-a a { color: var(--gold-2); }

.alert {
  padding: 14px 18px;
  border-radius: 10px;
  border: 1px solid rgba(255, 190, 60, .3);
  background: rgba(255, 170, 0, .08);
  color: var(--muted);
  font-size: 14px;
}
.alert strong { color: var(--gold-2); }

/* ============================================================
   下载中心
   ============================================================ */
.dl-hero {
  text-align: center;
  padding: 40px 24px;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(255, 160, 30, .16), transparent 60%),
    var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
}
.dl-hero h2 { font-size: 30px; font-weight: 800; color: #fff; margin-bottom: 8px; }
.dl-hero p { color: var(--muted); margin-bottom: 22px; }
.dl-big {
  display: inline-block;
  padding: 16px 58px;
  font-size: 20px;
  font-weight: 800;
  border-radius: 14px;
  background: var(--grad-gold);
  color: #2a1700;
  box-shadow: 0 10px 34px rgba(255, 160, 0, .35);
  transition: transform .2s, box-shadow .25s;
}
.dl-big:hover { transform: translateY(-3px); box-shadow: 0 16px 44px rgba(255, 160, 0, .5); }
.dl-big small { display: block; font-size: 13px; font-weight: 400; margin-top: 4px; opacity: .8; }

/* ============================================================
   关于 / 文本页
   ============================================================ */
.prose { font-size: 15px; color: var(--muted); }
.prose h2 { font-size: 19px; color: var(--gold-2); margin: 20px 0 10px; }
.prose p { margin-bottom: 12px; }
.prose ul { padding-left: 18px; list-style: disc; margin-bottom: 12px; }
.prose li { margin-bottom: 6px; }
.contact-card {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin: 18px 0;
}
.contact-card .cc {
  text-align: center;
  padding: 20px 14px;
  border-radius: 12px;
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, .03);
}
.contact-card .cc strong { display: block; font-size: 15px; color: var(--gold-2); margin-bottom: 6px; }
.contact-card .cc span { font-size: 13px; color: var(--muted); word-break: break-all; }

/* ============================================================
   页脚
   ============================================================ */
.site-footer {
  margin-top: 30px;
  background: linear-gradient(180deg, #160c11, #0d070c);
  border-top: 2px solid var(--line);
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 26px;
  padding: 34px 0 20px;
}
.footer-col h3 {
  font-size: 16px;
  color: var(--gold-2);
  margin-bottom: 12px;
  position: relative;
  padding-left: 12px;
}
.footer-col h3::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  bottom: 4px;
  width: 3px;
  border-radius: 2px;
  background: var(--grad-gold);
}
.footer-col p { font-size: 13px; color: var(--dim); line-height: 1.9; }
.footer-col a {
  display: block;
  font-size: 13px;
  color: var(--muted);
  padding: 3px 0;
  transition: color .2s, padding-left .2s;
}
.footer-col a:hover { color: var(--gold); padding-left: 5px; }
.footer-links {
  padding: 14px 0;
  border-top: 1px solid rgba(255, 255, 255, .06);
  font-size: 13px;
  color: var(--dim);
  line-height: 2;
}
.footer-links a { color: var(--muted); margin-right: 12px; }
.footer-links a:hover { color: var(--gold); }
.footer-copy {
  padding: 16px 0 22px;
  border-top: 1px solid rgba(255, 255, 255, .06);
  text-align: center;
  font-size: 12px;
  color: var(--dim);
  line-height: 2;
}
.footer-copy a { color: var(--gold-2); }

/* ============================================================
   返回顶部 / 浮动元素
   ============================================================ */
.back-top {
  position: fixed;
  right: 22px;
  bottom: 30px;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: var(--grad-gold);
  color: #2a1700;
  font-size: 20px;
  font-weight: 800;
  box-shadow: 0 8px 24px rgba(255, 160, 0, .4);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity .3s, transform .3s, visibility .3s;
  z-index: 90;
}
.back-top.show { opacity: 1; visibility: visible; transform: none; }
.back-top:hover { transform: translateY(-3px); }

/* 滚动显现动画 */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ============================================================
   404
   ============================================================ */
.notfound {
  text-align: center;
  padding: 70px 20px;
}
.notfound .nf-code {
  font-size: 90px;
  font-weight: 900;
  background: var(--grad-gold);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1.2;
}
.notfound p { color: var(--muted); margin: 10px 0 26px; }
.notfound a.btn-dl { font-size: 15px; padding: 10px 30px; }

/* ============================================================
   响应式
   ============================================================ */
@media (max-width: 1024px) {
  .grid-4, .grid-5 { grid-template-columns: repeat(3, 1fr); }
  .top-search input { width: 160px; }
}

@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .main-nav { display: none; }
  .main-nav.open { display: block; }
  .nav-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 6px 0 10px;
  }
  .nav-inner a { padding: 12px 8px; border-bottom: 1px solid rgba(255, 255, 255, .05); }
  .nav-inner a::after { display: none; }
  .top-search { display: none; }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 560px) {
  body { font-size: 14px; }
  .brand-logo { width: 50px; height: 50px; }
  .brand-text strong { font-size: 21px; }
  .brand-text em { font-size: 11px; }
  .section-title { font-size: 17px; }
  .grid-4, .grid-5, .grid-3, .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .panel { padding: 14px; }
  .news-item img { width: 108px; height: 74px; }
  .news-item h3 { font-size: 14px; }
  .contact-card { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 20px; }
  .dl-hero h2 { font-size: 24px; }
  .dl-big { padding: 14px 34px; font-size: 17px; }
  .search-block button { padding: 12px 20px; }
  .back-top { right: 14px; bottom: 18px; }
}
