/* cards.css —— 考点卡的“框” + 所有卡片控件
   同一套框，内容块自己决定排版：横图通栏、竖图右浮、方图居中。 */

#card::after { content: ""; display: block; clear: both; }

/* 默认版式：图在右、文字从左侧绕排（打制石器那种，全站优先用） */
#card figure {
  float: right;
  width: min(46%, 240px);
  margin: 2px 0 14px 18px;
}
#card figure img { width: 100%; height: auto; }

/* 横图：仍靠右，但给宽一点，避免压扁 */
#card figure.fig-wide { width: min(56%, 330px); }

/* 竖图：窄一点、高一点 */
#card figure.fig-portrait { width: min(42%, 220px); }

/* 方图：稍微加宽 */
#card figure.fig-square { width: min(50%, 260px); }

/* 表格块（接口先留） */
#card table.ptable {
  width: 100%;
  border-collapse: collapse;
  margin: 12px 0 16px;
  font-size: 13px;
}
#card table.ptable th,
#card table.ptable td {
  border: 1px solid rgba(233,226,211,.16);
  padding: 7px 9px;
  text-align: left;
}
#card table.ptable th { color: var(--gold); font-weight: 500; }

/* ---------- 右上角关闭叉 ---------- */
#card { position: relative; }
#card .card-x, #card .x {
  position: absolute;
  top: 8px;
  right: 10px;
  width: 30px;
  height: 30px;
  line-height: 26px;
  padding: 0;
  font-size: 20px;
  text-align: center;
  color: var(--gold);
  background: transparent;
  border: 1px solid rgba(200,160,99,.45);
  border-radius: 50%;
  cursor: pointer;
  transition: .2s;
  z-index: 5;
}
#card .card-x:hover, #card .x:hover,
#card .x:focus {
  color: #f0d9ae;
  border-color: var(--gold);
  background: rgba(200,160,99,.12);
}

/* ---------- 对话框滚动条：统一暗金 ---------- */
#card,
.ix-card,
.ix-body {
  scrollbar-width: thin;
  scrollbar-color: #a8865a rgba(255,255,255,.06);
}
#card::-webkit-scrollbar,
.ix-card::-webkit-scrollbar,
.ix-body::-webkit-scrollbar { width: 8px; height: 8px; }
#card::-webkit-scrollbar-track,
.ix-card::-webkit-scrollbar-track,
.ix-body::-webkit-scrollbar-track { background: rgba(255,255,255,.06); }
#card::-webkit-scrollbar-thumb,
.ix-card::-webkit-scrollbar-thumb,
.ix-body::-webkit-scrollbar-thumb {
  background: #a8865a;
  border-radius: 4px;
}
#card::-webkit-scrollbar-thumb:hover,
.ix-card::-webkit-scrollbar-thumb:hover,
.ix-body::-webkit-scrollbar-thumb:hover { background: #c8a063; }
#card::-webkit-scrollbar-corner,
.ix-card::-webkit-scrollbar-corner { background: transparent; }
