/* 天空彩票图库 - 样式（对齐 bob.tkjc.cc 手机版） */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; scroll-behavior: smooth; background: #e9eaee; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", Arial, sans-serif;
  background-color: #f0f2f5;
  color: #333;
  line-height: 1.6;
  min-height: 100vh;
  padding-bottom: 70px;
  max-width: 480px;
  margin: 0 auto;
  box-shadow: 0 0 24px rgba(0,0,0,.12);
}

a { text-decoration: none; color: inherit; }
img { display: block; max-width: 100%; }

/* === Header === */
.site-header {
  background: linear-gradient(135deg, #1a237e 0%, #3f51b5 50%, #1a237e 100%);
  color: #fff;
  box-shadow: 0 2px 12px rgba(0,0,0,.25);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  gap: 12px;
}

.site-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #fff;
}

.site-logo img { height: 40px; width: auto; }

.site-logo-text { font-size: 1.1rem; font-weight: 700; line-height: 1.2; }
.site-logo-text small { display: block; font-size: .7rem; font-weight: 400; opacity: .8; }

.site-nav {
  background: linear-gradient(180deg, #16205c 0%, #1a237e 100%);
  box-shadow: inset 0 -1px 0 rgba(0,0,0,.2);
}
.nav-inner { padding: 8px 12px; }

.nav-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  list-style: none;
  gap: 7px;
}

.nav-list li a {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 7px 13px;
  color: #cfd8ff;
  text-decoration: none;
  font-size: .82rem;
  font-weight: 600;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 20px;
  transition: all .2s ease;
}

.nav-list li a:hover {
  color: #fff;
  background: rgba(255,255,255,.16);
  border-color: rgba(255,255,255,.3);
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(0,0,0,.25);
}

.nav-list li a.active {
  color: #fff;
  background: linear-gradient(135deg, #ff7043 0%, #e84118 100%);
  border-color: transparent;
  box-shadow: 0 3px 10px rgba(232,65,24,.4);
}

/* === Main Content === */
.page-container { padding: 0 12px 12px; }

/* === Section Header === */
.section-header {
  padding: 12px 0 4px;
  font-size: .9rem;
  font-weight: 700;
  color: #333;
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-header::before {
  content: "";
  width: 3px;
  height: 16px;
  background: linear-gradient(to bottom, #3f51b5, #1a237e);
  border-radius: 2px;
  flex-shrink: 0;
}

.section-header .badge {
  background: #e84118;
  color: #fff;
  font-size: .65rem;
  padding: 2px 7px;
  border-radius: 20px;
  font-weight: 600;
}

/* === Hero === */
.hero-banner {
  background: linear-gradient(135deg, #1a237e 0%, #3f51b5 60%, #1a237e 100%);
  color: #fff;
  padding: 28px 12px;
  text-align: center;
  margin-bottom: 12px;
  border-radius: 0 0 12px 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,.2);
}

.hero-banner h1 { font-size: 1.4rem; margin-bottom: 6px; font-weight: 700; }
.hero-banner p { font-size: .82rem; opacity: .85; }
.hero-banner .update-time {
  margin-top: 8px;
  background: rgba(255,255,255,.15);
  display: inline-block;
  padding: 4px 14px;
  border-radius: 20px;
  font-size: .78rem;
}

/* === Category Cards === */
.index-category-section { margin-bottom: 12px; }

.index-category-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.index-cat-card {
  background: linear-gradient(135deg, #1a237e 0%, #3f51b5 50%, #1a237e 100%);
  border: 1px solid rgba(255,255,255,.22);
  border-radius: 8px;
  padding: 10px 8px;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-decoration: none;
  color: #fff;
  transition: all .2s;
  box-shadow: 0 1px 4px rgba(0,0,0,.05);
}

.index-cat-card:hover {
  filter: brightness(1.12);
  border-color: rgba(255,255,255,.45);
  box-shadow: 0 4px 16px rgba(26,35,126,.35);
  transform: translateY(-2px);
}

.index-cat-card .cat-emoji { font-size: 1.3rem; line-height: 1; }
.index-cat-card .cat-name { display: inline; font-size: .8rem; font-weight: 600; color: #fff; white-space: nowrap; }
.index-cat-card .cat-count { display: inline; font-size: .62rem; color: rgba(255,255,255,.85); margin-left: 2px; white-space: nowrap; }

/* === Letter Index (horizontal scroll) === */
.letter-section { margin-bottom: 12px; }

.letter-section-title {
  padding: 12px 0 4px;
  font-size: .9rem;
  font-weight: 700;
  color: #333;
}

.letter-grid {
  display: flex;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  gap: 6px;
  padding: 4px 0 8px;
}
.letter-grid::-webkit-scrollbar { display: none; }

.letter-link {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 7px 12px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 16px;
  text-decoration: none;
  color: #555;
  font-weight: 600;
  font-size: .8rem;
  transition: all .2s;
  box-shadow: 0 1px 3px rgba(0,0,0,.06);
}

.letter-link:hover {
  background: #3f51b5;
  color: #fff;
  border-color: #3f51b5;
  transform: scale(.95);
}

.letter-link.current {
  background: #3f51b5;
  color: #fff;
  border-color: #3f51b5;
}

.letter-btn-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 4px 0 8px;
}

.letter-btn {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 7px 12px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 16px;
  text-decoration: none;
  color: #555;
  font-weight: 600;
  font-size: .8rem;
  transition: all .2s;
}

.letter-btn:hover {
  background: #3f51b5;
  color: #fff;
  border-color: #3f51b5;
  transform: scale(.95);
}

/* === Alert Box === */
.alert-box {
  background: #fff5f5;
  border: 1px solid #fed7d7;
  border-left: 4px solid #e84118;
  border-radius: 6px;
  padding: 10px 12px;
  margin-bottom: 12px;
  font-size: .82rem;
  color: #c0392b;
}

.alert-box strong { display: block; margin-bottom: 4px; font-size: .85rem; }
.alert-box ul { list-style: none; padding-left: 0; }
.alert-box li::before { content: "\26A0\FE0F "; }

/* === 鍥剧墖缃戞牸锛?鍒楋級 === */
.img-list {
  margin-bottom: 12px;
}

.img-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-bottom: 10px;
}

.img-grid-item {
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(0,0,0,.06);
  cursor: pointer;
  transition: transform .15s, opacity .2s;
}

.img-grid-item:active { transform: scale(.95); }

.img-grid-item img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  display: block;
}

.img-grid-item .img-name {
  padding: 4px 6px;
  font-size: .6rem;
  color: #555;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  background: #fff;
}

/* === 鍒嗛〉瀵艰埅 === */
.page-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 10px 0;
}

.page-btn {
  background: #fff;
  border: 1px solid #ddd;
  color: #3f51b5;
  border-radius: 20px;
  padding: 6px 18px;
  font-size: .82rem;
  cursor: pointer;
  transition: all .2s;
  box-shadow: 0 1px 3px rgba(0,0,0,.06);
}

.page-btn:hover { background: #3f51b5; color: #fff; border-color: #3f51b5; }
.page-btn:disabled { opacity: .4; cursor: not-allowed; }

.page-info { font-size: .8rem; color: #888; }

/* === 鍥剧墖鏂囧瓧閾炬帴锛堝師鍒嗛〉鏍峰紡锛?鍒楀崱鐗囷級 === */
.img-link-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-bottom: 12px;
}

.img-link-card {
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(0,0,0,.06);
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  transition: transform .15s;
}

.img-link-card:active { transform: scale(.95); }

.img-link-card img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
}

.img-link-card .img-name {
  padding: 4px 6px;
  font-size: .6rem;
  color: #555;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  background: #fff;
}

/* === 鍥剧墖鏂囧瓧閾炬帴鍒楄〃锛堝崟鍒楋級 === */
.img-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-bottom: 6px;
}

.img-link {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 6px 8px;
  background: #fff;
  border-radius: 6px;
  text-decoration: none;
  color: #3f51b5;
  font-size: .8rem;
  transition: background .15s, color .15s;
  border: 1px solid #e8e8e8;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.img-link:hover { background: #eef3ff; color: #1a237e; }
.img-link .dot { color: #e84118; font-weight: 700; flex-shrink: 0; font-size: .7rem; }
.img-link .title { overflow: hidden; text-overflow: ellipsis; }

/* === 瀛愮珯鍗＄墖 === */
.category-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-bottom: 12px;
  padding: 0;
}

.cat-card {
  background: #fff;
  border: 1px solid #dde2e8;
  border-radius: 8px;
  padding: 12px;
  text-decoration: none;
  color: #333;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all .2s;
  box-shadow: 0 1px 4px rgba(0,0,0,.05);
}

.cat-card:hover {
  border-color: #3f51b5;
  box-shadow: 0 4px 16px rgba(44,82,130,.15);
  transform: translateY(-2px);
}

.cat-icon { font-size: 1.6rem; flex-shrink: 0; }
.cat-text strong { display: block; font-size: .82rem; color: #1a237e; margin-bottom: 2px; }
.cat-text span { font-size: .7rem; color: #888; }

/* === Footer Nav Bar === */
.footer-links {
  background: #fff;
  border: 1px solid #dde2e8;
  border-radius: 6px;
  padding: 8px 12px;
  margin-bottom: 12px;
  text-align: center;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 12px;
  box-shadow: 0 1px 4px rgba(0,0,0,.05);
}

.footer-links a {
  color: #3f51b5;
  text-decoration: none;
  font-size: .82rem;
  padding: 3px 8px;
  border-radius: 4px;
  transition: all .15s;
}

.footer-links a:hover { background: #3f51b5; color: #fff; }
.footer-links span { color: #ccc; }

/* === Site Footer === */
.site-footer {
  text-align: center;
  padding: 14px 12px 6px;
  font-size: .72rem;
  color: #bbb;
}

/* === Breadcrumb === */
.breadcrumb {
  font-size: .78rem;
  color: #888;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.breadcrumb a { color: #3f51b5; text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }
.breadcrumb span { color: #ccc; }

/* === Letter Page Title === */
.letter-section-title2 {
  padding: 12px 0 8px;
  font-size: 1rem;
  font-weight: 700;
  color: #1a237e;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* === 鐏 === */
#lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0,0,0,.92);
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
#lightbox.active { display: flex; }

.lb-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: rgba(0,0,0,.5);
  color: #fff;
  font-size: .82rem;
  z-index: 10;
}

#lb-counter { opacity: .8; }

.lb-img-wrap {
  max-width: 92vw;
  max-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

#lb-img {
  max-width: 92vw;
  max-height: 80vh;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 8px 40px rgba(0,0,0,.6);
  user-select: none;
}

#lb-title {
  margin-top: 8px;
  color: rgba(255,255,255,.75);
  font-size: .78rem;
  text-align: center;
  max-width: 90vw;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 0 12px;
}

.lb-close {
  position: absolute;
  top: 10px;
  right: 12px;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.25);
  color: #fff;
  font-size: 1.2rem;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  transition: background .15s;
  z-index: 11;
}
.lb-close:hover { background: rgba(255,255,255,.25); }

.lb-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.2);
  color: #fff;
  font-size: 1.8rem;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s;
  z-index: 11;
  user-select: none;
}
.lb-nav:hover { background: rgba(255,255,255,.28); }
#lb-prev { left: 10px; }
#lb-next { right: 10px; }

#lightbox .lb-actions { display: flex; justify-content: center; gap: 18px; margin-top: 12px; }
#lightbox .lb-btn { background: rgba(255,255,255,.16); color: #fff; border: 1px solid rgba(255,255,255,.45); border-radius: 22px; padding: 9px 20px; font-size: 14px; cursor: pointer; }
#lightbox .lb-btn:hover { background: rgba(255,255,255,.3); }

/* === Responsive === */
@media (max-width: 600px) {
  .header-inner { flex-direction: column; text-align: center; }
  .nav-list { justify-content: center; }
  .nav-list li a { padding: 8px 10px; font-size: .8rem; }
  .index-category-grid { grid-template-columns: repeat(3, 1fr); }
}
.lightbox .lb-actions{position:absolute;bottom:14px;left:0;right:0;display:flex;justify-content:center;gap:18px;z-index:5}
.lightbox .lb-btn{background:rgba(255,255,255,.16);color:#fff;border:1px solid rgba(255,255,255,.45);border-radius:22px;padding:9px 20px;font-size:14px;cursor:pointer}
.lightbox .lb-btn:hover{background:rgba(255,255,255,.3)}
