/* =========
   苍白立方 - Wiki风官网（主页 + 封禁页）
   ========= */
*{ box-sizing: border-box; }
html, body{ height: 100%; }
body{
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", "PingFang SC",
               "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.5;
  background: var(--bg);
  color: var(--text);
}

/* Theme */
:root{
  --bg: #f6f7f9;
  --surface: #ffffff;
  --surface2: #f0f2f5;
  --border: rgba(20, 20, 20, 0.12);
  --text: #1b1f24;
  --muted: rgba(27, 31, 36, 0.72);
  --link: #0b63ce;
  --shadow: 0 10px 30px rgba(0,0,0,0.08);
  --radius: 14px;
  --pad: 18px;
  --maxw: 1120px;
}
html[data-theme="dark"]{
  --bg: #0f1216;
  --surface: #151a21;
  --surface2: #11151b;
  --border: rgba(255, 255, 255, 0.12);
  --text: rgba(255,255,255,0.92);
  --muted: rgba(255,255,255,0.65);
  --link: #7ab7ff;
  --shadow: 0 10px 30px rgba(0,0,0,0.45);
}
html[data-width="wide"]{ --maxw: 1320px; }

.page{ min-height: 100%; }

/* Topbar */
.topbar{
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255,255,255,0.72);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  padding: 10px 16px;
}
html[data-theme="dark"] .topbar{ background: rgba(15,18,22,0.72); }

.topbar__left, .topbar__right{
  display: flex;
  align-items: center;
  gap: 14px;
}
.brand__name{
  font-weight: 800;
  letter-spacing: 0.5px;
  padding: 8px 10px;
  border-radius: 12px;
  color: var(--text);
  text-decoration: none;
}
.brand__name:hover{ background: var(--surface2); }

.topnav{
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

/* Header simple links */
.toplink{
  display: inline-flex;
  align-items: center;
  padding: 8px 10px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  text-decoration: none;
  font-weight: 750;
  font-size: 14px;
}
.toplink:hover{ background: var(--surface2); }
.toplink--active{
  outline: 2px solid var(--border);
  background: var(--surface2);
}

/* Fold (misc) */
.fold{ position: relative; }
.fold__btn{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  border-radius: 12px;
  padding: 8px 10px;
  cursor: pointer;
  font-weight: 800;
  font-size: 15.5px;
}
.fold__btn:hover{ background: var(--surface2); }

.triangle{
  width: 0; height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 7px solid currentColor;
  opacity: 0.85;
  transform: rotate(-90deg);
  transition: transform .15s ease;
}
.fold[aria-expanded="true"] .triangle,
.fold__btn[aria-expanded="true"] .triangle{ transform: rotate(0deg); }

.fold__panel{
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 180px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 8px;
  display: none;
}
.fold[aria-expanded="true"] .fold__panel{ display: block; }

.fold__item{
  display: block;
  padding: 8px 10px;
  border-radius: 10px;
  color: var(--text);
  text-decoration: none;
  font-weight: 650;
}
.fold__item:hover{ background: var(--surface2); }

/* Main */
.main{
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 18px 16px 24px;
}

.hero{
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 16px;
  margin-top: 14px;
}
@media (max-width: 960px){
  .hero{ grid-template-columns: 1fr; }
}
.hero__title{
  margin: 0;
  font-size: 34px;
  letter-spacing: 0.6px;
}
.hero__subtitle{
  margin: 8px 0 14px;
  color: var(--muted);
}

.content{ margin-top: 16px; }
.content__header{
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 14px;
  margin-bottom: 10px;
}
.content__title{ margin: 0; font-size: 22px; }
.content__crumbs{
  color: var(--muted);
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.content__grid{
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 16px;
}
@media (max-width: 960px){
  .content__grid{ grid-template-columns: 1fr; }
}

/* Cards */
.card{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--pad);
  box-shadow: var(--shadow);
}
.card__title{ font-weight: 800; margin-bottom: 10px; }
.card__body{ color: var(--text); }

/* Buttons */
.btn{
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  border-radius: 12px;
  padding: 10px 12px;
  cursor: pointer;
  font-weight: 700;
}
.btn:hover{ filter: brightness(0.98); }
.btn:active{ transform: translateY(1px); }
.btn--ghost{ background: transparent; }

/* KV */
.kv{
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 10px;
  padding: 6px 0;
  align-items: center;
}
.kv__k{ color: var(--muted); font-size: 13px; }
.kv__v code{
  background: rgba(127,127,127,0.14);
  padding: 3px 6px;
  border-radius: 8px;
}
.quickinfo .kv__v{
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

/* Helpers */
.muted{ color: var(--muted); }
.bullets{ margin: 10px 0 0; padding-left: 18px; color: var(--text); }
.bullets li{ margin: 6px 0; }

.miniSection{ margin-bottom: 14px; }
.miniSection__title{ font-weight: 800; margin-bottom: 8px; }
.chipRow{ display: flex; flex-wrap: wrap; gap: 8px; }
.chip{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  cursor: pointer;
  font-weight: 700;
  text-decoration: none;
  color: var(--text);
}
.chip:hover{ background: var(--surface2); }

/* Footer */
.footer{
  margin-top: 18px;
  padding: 18px 0 6px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  color: var(--muted);
}
.footer__link{ color: var(--link); text-decoration: none; font-weight: 700; }
.footer__link:hover{ text-decoration: underline; }
.footer__sep{ opacity: 0.6; }

/* Drawer */
.backdrop{
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.38);
  z-index: 80;
}
.drawer{
  position: fixed;
  top: 0;
  right: 0;
  height: 100%;
  width: min(360px, 92vw);
  background: var(--surface);
  border-left: 1px solid var(--border);
  box-shadow: var(--shadow);
  z-index: 90;
  transform: translateX(100%);
  transition: transform .2s ease;
  display: flex;
  flex-direction: column;
}
.drawer--open{ transform: translateX(0); }
.drawer__header{
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 14px 10px;
  border-bottom: 1px solid var(--border);
}
.drawer__title{ font-weight: 900; font-size: 16px; }
.drawer__content{ padding: 14px; display: grid; gap: 12px; }
.iconBtn{
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  width: 36px;
  height: 36px;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 900;
}
.iconBtn:hover{ background: var(--surface2); }
.settingRow{
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}
.settingRow__label{ color: var(--muted); font-weight: 750; }

.segmented{
  display: inline-flex;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background: var(--surface2);
}
.segmented__btn{
  border: 0;
  background: transparent;
  color: var(--text);
  padding: 8px 10px;
  cursor: pointer;
  font-weight: 800;
}
.segmented__btn[aria-pressed="true"]{ background: var(--surface); }

.hintBox{
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  padding: 12px;
  background: var(--surface2);
}
.hintBox__title{ font-weight: 900; margin-bottom: 6px; }
.hintBox__text{ color: var(--muted); font-size: 13px; }

/* ===== Ban page ===== */
.banChart__head{
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 10px;
}
.banChart__sub{ font-size: 13px; margin-top: 6px; }
.banChart__badge{ display: flex; gap: 8px; flex-wrap: wrap; }
.badge{
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-weight: 800;
  font-size: 12px;
}
.badge--soft{ background: var(--surface2); }

.banChart__canvasWrap{
  border-radius: calc(var(--radius) - 4px);
  border: 1px solid var(--border);
  background: var(--surface);
  overflow: hidden;
  padding: 10px;
}
.banChart__canvas{
  display: block;
  width: 100%;
  height: 320px;
}
.banChart__legend{
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 10px;
  flex-wrap: wrap;
}
.legendItem{ display: inline-flex; align-items: center; gap: 10px; font-weight: 750; }
.legendDot{
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--link);
  border: 1px solid var(--border);
}

.banGrid{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 14px;
}
.banCard{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 12px;
}
.banCard__head{
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}
.banCard__name{ font-weight: 900; }
.banCard__tag{
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-weight: 900;
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface2);
}
.banCard__rows{ display: grid; gap: 8px; padding-top: 2px; }
.banRow{
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 10px;
  align-items: baseline;
}
.banRow__k{ color: var(--muted); font-size: 13px; font-weight: 800; }
.banRow__v{ color: var(--text); font-weight: 650; }

.mono{
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

/* Admin note: reserve 2 lines */
.banNote{
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  line-height: 1.45;
  min-height: calc(1.45em * 2);
}

.banCard__appeal{
  display: inline-flex;
  justify-content: center;
  align-items: center;
  border-radius: 12px;
  padding: 10px 12px;
  text-decoration: none;
  font-weight: 900;
  border: 1px solid var(--border);
  background: var(--surface2);
  color: var(--text);
}
.banCard__appeal:hover{ filter: brightness(0.98); }


/* v3: ban links */
.banCard__link{color:inherit;text-decoration:none;border-bottom:1px dashed rgba(154,164,178,.35)}
.banCard__link:hover{border-bottom-color:rgba(25,195,125,.6)}
