:root {
  --bg: #f7f8fa;
  --card: #fff;
  --text: #1a1a1a;
  --text-dim: #6c7480;
  --brand: #3b82f6;
  --brand-grad: linear-gradient(135deg, #3b82f6, #06b6d4);
  --border: #e5e7eb;
  --radius: 12px;
  --shadow: 0 4px 12px rgba(0,0,0,0.05);
  --max-width: 1280px;
}

    html,body{height:100%;}
    body {
      margin: 0; background: var(--bg); color: var(--text);
      font: 14px/1.6 system-ui, -apple-system, Segoe UI, Roboto, PingFang SC, Hiragino Sans GB, "Microsoft YaHei", Helvetica, Arial, sans-serif;
      -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
    }
    *, *::before, *::after { box-sizing: border-box; }
    a { color: inherit; text-decoration: none; }
    img { max-width: 100%; display: block; }

/* 容器 */
.mk-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 16px;
}

/* 顶部 */
.mk-header {
  background: #fff;
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 100;
}
.mk-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 15px;
}
.mk-logo span {
  font-size: 20px;
  font-weight: 700;
  background: var(--brand-grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* 搜索框 */
.mk-search {
  flex: 1;
  max-width: 320px;
  display: flex;
  background: #f1f5f9;
  border-radius: 20px;
  overflow: hidden;
  margin: 0px 20px;
}
.mk-search input {
  flex: 1;
  min-width: 0;
  padding: 8px 12px;
  border: none;
  background: transparent;
  outline: none;
}
.mk-search button {
flex-shrink: 0;
  background: var(--brand-grad);
  color: #fff;
  border: none;
  padding: 0 12px;
  cursor: pointer;
}

/* 导航 */
.mk-nav {
  display: flex;
  gap: 12px;
}
.mk-nav a {
  color: var(--text-dim);
  padding: 6px 10px;
  border-radius: 8px;
}
.mk-nav a:hover,
.mk-nav a.active {
  color: #fff;
  background: var(--brand-grad);
}

@media (min-width: 769px) {
  .mk-nav {
    display: flex !important;
    max-height: none !important;
    flex-direction: row;
    position: static;
    box-shadow: none;
    border-top: none;
    padding: 0;
  }

  .mk-nav a {
    padding: 6px 10px;
    border-bottom: none;
  }
}

.navlist{max-width:1280px; font-size:14px; padding:15px 15px 5px 15px; margin:0 auto; color: #777777;}
.navlist a{font-size:14px; color: #777777;}

/* 手机菜单 */
.mk-menu-btn {
  display: none;
  font-size: 24px;
  cursor: pointer;
}

/* 遮罩层（移动端） */
.mk-nav-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.3);
  z-index: 50; /* 小于菜单 z-index 99 */
}

/* 显示状态 */
.mk-nav-overlay.show {
  display: block;
}

.h1-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 16px; }
.reader { margin-top: 20px; background: var(--bg, #0f1115); }
.reader-title {text-align:center; padding-top:12px; color:#aaa; margin:0 auto;}
.reader-title h1{text-align:center; padding-top:12px; color:#aaa; text-decoration: none; font-size: 16px; color:#aaa;}
.description{max-width:800px; color:#aaa; padding:12px 0; font-size: 14px;margin:0 auto;}

.reader-main {
  display: grid;
  gap: 12px;
  padding-top:12px;
  padding-bottom: 70px;
  justify-items: center;
  overflow: auto;
}

.reader-img { 
  display: block;
  width: 100%; 
  max-width: 800px; 
  height: auto; 
  border-radius: 12px; 
  border: 1px solid #333; 
  background: #0b0d12; 
  margin-bottom: 10px;
  user-drag: none; -webkit-user-drag: none; -moz-user-drag: none; -ms-user-drag: none; 
}

/* 占位动画 */
.reader-img.loading {
  background: #eee;
  animation: pulse 1.5s infinite;
}

@keyframes pulse {
  0% { background-color: #eee; }
  50% { background-color: #ddd; }
  100% { background-color: #eee; }
}

/* 网格 */
.mk-section { margin:30px 0px;}
.mk-section-title { font-size: 18px; font-weight: 700; color: #555;}
.mk-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 16px;
}
.mk-card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform .2s;
}
.mk-card:hover {
  transform: translateY(-4px);
}
.mk-card img {
  width: 100%;
  height: auto;
  display: block;
}
.mk-card h3 {
  font-size: 14px;
  padding: 8px;
  margin: 0;
  display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--text);
  color: #555;
}
.mk-card span {
  font-size: 12px;
  color: var(--text-dim);
  padding: 0 8px 8px;
  display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.vip-bottom-bar {
  width: 100%;
  color: #999;
  text-align: center;
  font-size: 16px;
  padding: 14px 12px 100px 12px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
  border-radius: 10px;
  touch-action: pan-y;
}

.vip-text {
  color: #333;
  font-weight: bold;
  margin: 0 4px;
}

.vip-btn {
  background: linear-gradient(135deg, #ff9f43, #ff6b6b);
  color: #fff;
  font-size: 14px;
  font-weight: bold;
  padding: 6px 14px;
  border-radius: 20px;
  text-decoration: none;
  transition: 0.3s;
  white-space: nowrap;
}
.vip-btn:hover {
  background: linear-gradient(135deg, #ff6b6b, #ff9f43);
}


/* 分页 */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: nowrap;
  gap: 5px;
  padding: 20px 0 40px 0;
}

.pagination a,
.pagination span {
  display: inline-block;
  min-width: 32px;
  height: 32px;
  line-height: 32px;
  text-align: center;
  border: 1px solid #ddd;
  border-radius: 4px;
  color: #333;
  font-size: 14px;
  background: #fff;
  white-space: nowrap;
}

.pagination b{
  display: inline-block;
  min-width: 32px;
  height: 32px;
  line-height: 32px;
  text-align: center;
  border: 1px solid #ddd;
  border-radius: 4px;
  color: #333;
  font-size: 14px;
  background: #fff;
  white-space: nowrap;
  background: #06b6d4;
  color: #fff;
  border-color: #06b6d4;
}

.pagination span.ellipsis {
  border: none;
  background: transparent;
  cursor: default;
}
.prev ,.next{padding: 0 5px;}

/* 底部 */
.mk-footer {
  text-align: center;
  font-size: 12px;
  color: var(--text-dim);
  padding: 40px 0;
  border-top: 1px solid var(--border);
}

/* 响应式 */
@media (max-width: 768px) {
  .mk-nav {
    display: none;  /* 默认隐藏 */
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.3s ease, padding 0.3s ease;
    flex-direction: column;
    position: absolute;
    top: 60px;
    left: 0;
    width: 100%;
    background: #fff;
    border-top: 1px solid var(--border);
    box-shadow: var(--shadow);
    z-index: 99;
  }

  .mk-nav.show {
    display: flex;
    padding: 10px 0;
    max-height: 500px; /* 足够显示全部菜单 */
  }

  .mk-nav.show a {
    padding: 10px 16px;
    border-bottom: 1px solid #eee;
  }

  .mk-nav.show a:last-child {
    border-bottom: none;
  }
  
  .mk-menu-btn { display: block; }

.mk-grid {
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 10px;
}

}

