/* ============================================================
   炉石传说名人堂：无限 — 香草年代风格
   素材：炉石传说名人堂_透明PNG素材包（透明 PNG，全部在 /assets/）
   标题艺术字、小图标用 CSS 绘制；牌匾/面板/按钮/职业图标用素材
   ============================================================ */

:root {
  --gold: #d9b45c;
  --gold-bright: #f7e59b;
  --gold-deep: #8a6520;
  --gold-line: #b8912f;

  --ink: #2b1d0c;
  --ink-soft: #57432a;

  --red: #8f1d1d;
  --blue: #1e4d7a;

  --dark: #0b0906;
  --dark-2: #17120d;
  --parchment: #e9dcb8;

  --shadow-deep: 0 10px 28px rgba(0, 0, 0, 0.72);
}

* { box-sizing: border-box; }

/* 关键：作者样式里的 display 会覆盖浏览器默认的 [hidden] { display: none }。
   本页 .lightbox / .modal-mask / .upload-placeholder 自带 display:grid|flex，
   若不加这条会无视 hidden 一直显示（灯箱黑屏铺满且关不掉）。 */
[hidden] { display: none !important; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100vh;
  font-family: "Noto Serif SC", "Cinzel", "Microsoft YaHei", "PingFang SC", serif;
  color: var(--parchment);
  background: #080604;
}

/* ---------------- 滚动条：暗金风格 ----------------
   Firefox 用 scrollbar-width/color（这两个属性可继承，写在 html 上即可全局生效）；
   Chrome/Edge 用 ::-webkit-scrollbar 伪元素，裸选择器对页面内所有滚动容器生效。 */
html {
  scrollbar-width: thin;
  scrollbar-color: #8a6520 #12100c;
}
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track {
  background: #12100c;
  border-radius: 5px;
  box-shadow: inset 0 0 4px rgba(0, 0, 0, 0.9);
}
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #e6c877 0%, #b8912f 48%, #8a6520 100%);
  border: 1px solid #2b1d0c;
  border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #f7e59b 0%, #d9b45c 50%, #a87a14 100%);
}
::-webkit-scrollbar-corner { background: #12100c; }

/* 弹窗里的滚动条再细一点，避免压住面板边框 */
.modal { scrollbar-width: thin; scrollbar-color: #8a6520 #17120d; }
.modal::-webkit-scrollbar { width: 8px; }
.modal::-webkit-scrollbar-track { background: #17120d; }
body { position: relative; padding-bottom: 22px; }

/* ---------------- 页面背景（复用横幅风景，压暗做底） ---------------- */
.page-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  background: #0a0806 url("/assets/header-banner.png") center / cover no-repeat;
}
.page-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 78% 52% at 50% 0%, rgba(150, 92, 26, 0.30), transparent 70%),
    linear-gradient(180deg,
      rgba(8, 6, 4, 0.84) 0%,
      rgba(8, 6, 4, 0.93) 46%,
      rgba(8, 6, 4, 0.97) 100%);
}

/* ============================================================
   顶部横幅
   ============================================================ */
.banner {
  position: relative;
  margin: 16px 20px 0;
  min-height: 188px;
  border-radius: 8px;
  overflow: hidden;
  background: #100c08 url("/assets/header-banner.png") center 52% / cover no-repeat;
  box-shadow:
    0 0 0 2px #241a0f,
    0 0 0 3px rgba(184, 145, 47, 0.5),
    var(--shadow-deep);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px 168px;
}

/* 左侧公会旗帜 */
.banner-flag {
  position: absolute;
  left: 30px;
  top: 0;
  height: 90%;
  width: auto;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.8));
  pointer-events: none;
}

.banner-center {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

/* ---------- 标题牌匾 + CSS 艺术字 ---------- */
/* .title-wrap 的尺寸 = 牌匾尺寸，这样标题里的百分比定位才能对上牌匾像素 */
.title-wrap {
  position: relative;
  width: clamp(320px, 52vw, 720px);
  display: grid;
  place-items: center;
}
.title-plaque {
  grid-area: 1 / 1;
  width: 100%;
  height: auto;
  display: block;
  filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.8));
}

/* ---------- 标题艺术字（纯 CSS 绘制，不用烘焙文字的图片） ----------
   注意：background-clip:text 与 text-shadow 不能同时用在同一元素上——
   Chrome 会把 text-shadow 画在裁切后的背景之上，整行字会糊成一团深褐色。
   描边/发光一律改用 filter: drop-shadow()（作用于渲染结果，不会盖住渐变）。 */
.site-title {
  /* 关键：牌匾素材的「暗色内场」（两只狮头之间那块深色面）中心并不在图片几何中心，
     实测在 658x140 画布上是 (333, 74)，即 50.6% / 52.9%，比画布中心右 4px、下 4px。
     文字若按图片中心居中，看上去就会偏左上。这里直接按内场中心定位。 */
  position: absolute;
  left: 50.6%;
  top: 57.5%;
  transform: translate(-50%, -50%);
  z-index: 1;
  margin: 0;
  font-family: "Cinzel", "Noto Serif SC", "Microsoft YaHei", serif;
  font-size: clamp(19px, 2.5vw, 37px);
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: 0.04em;
  white-space: nowrap;

  /* 金色渐变填充 */
  background-image: linear-gradient(180deg,
    #fffdf0 0%,
    #ffeeb4 18%,
    #f6d372 38%,
    #cf9f26 58%,
    #a87a14 74%,
    #e6c463 88%,
    #fff6d4 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;

  filter:
    drop-shadow(0 2px 3px rgba(0, 0, 0, 0.95))
    drop-shadow(0 0 14px rgba(255, 190, 60, 0.45));
}

/* ---------- 分隔线 + 副标题 ---------- */
.banner-sub {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: -4px;
}
.banner-divider {
  width: clamp(170px, 24vw, 286px);
  height: auto;
  display: block;
  opacity: 0.95;
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.8));
}
.banner-sub p {
  margin: -10px 0 0;
  font-size: clamp(11px, 1.05vw, 14px);
  letter-spacing: 0.34em;
  text-indent: 0.34em;
  color: #e8d7a8;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.95), 0 0 12px rgba(0, 0, 0, 0.8);
}

/* ============================================================
   名人堂主面板（暗金属面板素材做 9 宫格）
   ============================================================ */
.hall-panel {
  position: relative;
  margin: 18px 20px 0;
  padding: 28px 26px 20px;
  border: 30px solid transparent;
  /* 用长写：简写里 `... / 30px / stretch` 的 stretch 会落到 outset 位置导致整条失效 */
  border-image-source: url("/assets/dark-metal-panel.png");
  border-image-slice: 36 fill;
  border-image-width: 30px;
  border-image-repeat: stretch;
  border-radius: 4px;
  box-shadow: var(--shadow-deep);
}

/* ---------------- 堂头 ---------------- */
.hall-head {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  padding-bottom: 16px;
  margin-bottom: 4px;
  border-bottom: 2px solid rgba(217, 180, 92, 0.26);
}

.hall-skull {
  width: 66px;
  height: 66px;
  object-fit: contain;
  flex: none;
  filter: drop-shadow(0 0 12px rgba(217, 180, 92, 0.4));
}

.hall-titles { flex: 1; min-width: 180px; }

.hall-title {
  margin: 0;
  font-family: "Cinzel", "Noto Serif SC", serif;
  font-size: 29px;
  font-weight: 900;
  letter-spacing: 7px;
  background-image: linear-gradient(180deg, #fff6d2 0%, #f3d98a 40%, #b98c25 70%, #f7e59b 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.9));
}

.hall-sub {
  margin: 5px 0 0;
  font-size: 12px;
  letter-spacing: 2px;
  color: #b9a173;
}

.hall-tools {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

/* ---------- 搜索框 ---------- */
.search-box {
  display: flex;
  align-items: center;
  gap: 9px;
  height: 44px;
  min-width: 300px;
  padding: 0 13px;
  border-radius: 5px;
  border: 2px solid #6d5424;
  background: linear-gradient(180deg, #191410, #0d0a07);
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.85), 0 0 0 1px #3a2c16;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.search-box:focus-within {
  border-color: var(--gold);
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.85), 0 0 12px rgba(217, 180, 92, 0.45);
}
.search-ico {
  width: 22px;
  height: 22px;
  object-fit: contain;
  flex: none;
  opacity: 0.9;
}
.search-box input {
  flex: 1;
  min-width: 0;
  height: 100%;
  border: none;
  outline: none;
  background: transparent;
  color: #eadfc0;
  font-size: 13px;
  font-family: inherit;
}
.search-box input::placeholder { color: #7d6a48; }

/* ============================================================
   按钮（素材包的绶带底板：蓝 / 金 / 红）
   ============================================================ */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 44px;
  padding: 0 30px;
  border: none;
  background-color: transparent;
  background-position: center;
  background-repeat: no-repeat;
  background-size: 100% 100%;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 2px;
  color: #fff8e6;
  cursor: pointer;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.95), 0 0 8px rgba(0, 0, 0, 0.65);
  transition: filter 0.15s, transform 0.1s;
}
.btn--add   { background-image: url("/assets/button-blue.png"); }
.btn--edit  { background-image: url("/assets/button-gold.png"); }
.btn--del   { background-image: url("/assets/button-red.png"); }
.btn--plain { background-image: url("/assets/button-gold.png"); }

.btn:hover:not(:disabled) { filter: brightness(1.16); }
.btn:active:not(:disabled) { transform: translateY(1px); }
.btn:disabled { filter: grayscale(0.7) brightness(0.68); cursor: not-allowed; }

/* letter-spacing 会在最后一个字后面也留出间距，使文字盒比可见字墨宽 2px，
   居中时整组内容看起来会偏左。这里用负右外边距把这段空白还回去。 */
.btn-txt { margin-right: -2px; }

.btn-link {
  background: none;
  border: none;
  color: #b9a173;
  font-size: 12px;
  font-family: inherit;
  cursor: pointer;
  padding: 4px 2px;
  text-decoration: underline;
}
.btn-link:hover { color: var(--gold-bright); }

/* ---------- CSS 绘制的按钮小图标（素材包里没有独立的小图标） ---------- */
.ico { width: 17px; height: 17px; position: relative; display: block; flex: none; }

/* 圆圈加号 */
.ico--plus { border: 2px solid #fff6e2; border-radius: 50%; }
.ico--plus::before,
.ico--plus::after {
  content: "";
  position: absolute;
  background: #fff6e2;
  border-radius: 1px;
}
.ico--plus::before { left: 50%; top: 3px; bottom: 3px; width: 2px; transform: translateX(-50%); }
.ico--plus::after  { top: 50%; left: 3px; right: 3px; height: 2px; transform: translateY(-50%); }

/* 铅笔（斜置，左下为笔尖） */
.ico--pencil::before {
  content: "";
  position: absolute;
  inset: 0;
  background: #fff6e2;
  clip-path: polygon(0 100%, 19% 60%, 77% 3%, 97% 23%, 39% 80%);
}

/* 垃圾桶：提手 + 桶盖 + 桶身 */
.ico--trash { background: linear-gradient(#fff6e2, #fff6e2) center top / 6px 2px no-repeat; }
.ico--trash::before {
  content: "";
  position: absolute;
  left: 0; right: 0; top: 3px; height: 2px;
  background: #fff6e2;
  border-radius: 1px;
}
.ico--trash::after {
  content: "";
  position: absolute;
  left: 1.5px; right: 1.5px; top: 6px; bottom: 1px;
  background: #fff6e2;
  clip-path: polygon(0 0, 100% 0, 87% 100%, 13% 100%);
}

/* ============================================================
   表格（羊皮纸面板素材做底图）
   ============================================================ */
.table-wrap {
  margin-top: 16px;
  border: 22px solid transparent;
  /* 羊皮纸面板素材：fill 让中间的羊皮纸铺满表格底 */
  border-image-source: url("/assets/parchment-panel.png");
  border-image-slice: 26 fill;
  border-image-width: 22px;
  border-image-repeat: stretch;
  border-radius: 4px;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.55);
  overflow: hidden;
}

.hall-table {
  width: 100%;
  border-collapse: collapse;
  color: var(--ink);
  font-size: 13.5px;
}

.hall-table thead th {
  padding: 13px 10px;
  text-align: left;
  font-family: "Cinzel", "Noto Serif SC", serif;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 2px;
  color: #f6ecd2;
  background: linear-gradient(180deg, #40301a 0%, #241a0d 100%);
  border-bottom: 2px solid #6b4f1c;
  text-shadow: 0 1px 2px #000;
  white-space: nowrap;
}
.hall-table thead th.col-check { width: 40px; text-align: center; }
.hall-table thead th.col-id { width: 56px; text-align: center; }
.hall-table thead th.col-cls { width: 134px; text-align: left; }
.hall-table thead th.col-time { width: 130px; }
.hall-table thead th.col-shot { width: 214px; text-align: center; }
.hall-table thead th.col-act { width: 92px; text-align: center; }

.hall-table tbody tr { transition: background 0.15s; }
.hall-table tbody tr:nth-child(odd)  { background: rgba(255, 253, 244, 0.42); }
.hall-table tbody tr:nth-child(even) { background: rgba(176, 142, 82, 0.12); }
.hall-table tbody tr:hover { background: rgba(217, 180, 92, 0.45); }

.hall-table tbody td {
  padding: 8px 10px;
  border-bottom: 1px solid rgba(120, 84, 30, 0.26);
  vertical-align: middle;
}
.hall-table tbody td.col-check,
.hall-table tbody td.col-id,
.hall-table tbody td.col-shot,
.hall-table tbody td.col-act { text-align: center; }

.hall-table input[type="checkbox"] {
  appearance: none;
  width: 17px; height: 17px;
  border: 2px solid #8a6a2c;
  border-radius: 3px;
  background: #f4e9cb;
  cursor: pointer;
  position: relative;
  vertical-align: middle;
}
.hall-table input[type="checkbox"]:checked { background: #6d5424; }
.hall-table input[type="checkbox"]:checked::after {
  content: "✓";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #ffeec0;
  font-size: 12px;
  font-weight: 900;
}

/* 职业图标（wowhandbook_class_icons 的 56×56 JPG：正方形、四角不透明、本身无画框，
   所以这里补一圈「深色内描边 + 古铜外框」，视觉上接近原型图的方块图标） */
.cls-icon {
  width: 34px;
  height: 34px;
  object-fit: contain;
  display: block;
  flex: none;
  border-radius: 3px;
  box-shadow:
    0 0 0 1px #241a0d,
    0 0 0 2px #8a6a2c,
    0 2px 4px rgba(0, 0, 0, 0.45);
}

/* 职业单元格：图标 + 职业名 */
.cls-cell {
  display: inline-flex;
  align-items: center;
  gap: 9px;
}
.cls-label {
  font-weight: 700;
  color: #2b1d0c;
  letter-spacing: 1px;
  white-space: nowrap;
}

.cell-name { font-weight: 700; color: #2b1d0c; letter-spacing: 1px; white-space: nowrap; }
.cell-reason { color: #4a3820; line-height: 1.55; max-width: 380px; word-break: break-word; }
.cell-time { font-family: "Cinzel", monospace; font-size: 12px; color: #5b4527; white-space: nowrap; }

/* 一行排 3 张（62×3 + 4×2 gap = 194px，列宽留 214px）；
   超过 3 张自动换行，不做折叠，最多 9 张 = 3 行 */
.cell-shot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 4px;
}
.shot-thumb {
  position: relative;
  display: block;
  flex: none;
  width: 62px;
  height: 36px;
}
.cell-shot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 2px solid #6d5424;
  border-radius: 3px;
  cursor: zoom-in;
  transition: transform 0.15s, box-shadow 0.15s;
}
.cell-shot img:hover {
  transform: scale(1.08);
  box-shadow: 0 0 12px rgba(217, 180, 92, 0.8);
}
.no-shot { color: #a08654; font-size: 12px; }

/* 行内操作按钮（素材：圆形金框铅笔 / 红框垃圾桶） */
.row-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.icon-btn {
  width: 30px; height: 30px;
  padding: 0;
  border: none;
  background: none;
  display: inline-grid;
  place-items: center;
  cursor: pointer;
  transition: filter 0.15s, transform 0.1s;
}
.icon-btn img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}
.icon-btn:hover { filter: brightness(1.2); transform: translateY(-1px); }
.icon-btn:active { transform: translateY(0); }

/* ---------- 空状态 ---------- */
.empty-state { text-align: center; padding: 40px 20px 44px; color: #5b4527; }
.empty-state p { margin: 12px 0 0; font-size: 14px; }
.empty-skull {
  width: 88px; height: 88px;
  object-fit: contain;
  opacity: 0.8;
  filter: drop-shadow(0 3px 8px rgba(0, 0, 0, 0.25));
}

.table-footer {
  display: flex;
  justify-content: flex-end;
  padding: 10px 6px 0;
}
.table-count { font-size: 12px; color: #b9a173; letter-spacing: 1px; }

/* ============================================================
   底部装饰（透明 PNG，无需混合处理）
   ============================================================ */
.page-footer {
  display: flex;
  justify-content: center;
  margin-top: 20px;
  padding: 0 0 6px;
}
.footer-ornament {
  width: min(400px, 58vw);
  height: auto;
  filter: drop-shadow(0 0 16px rgba(217, 180, 92, 0.35));
}

/* ============================================================
   模态框
   ============================================================ */
.modal-mask {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(0, 0, 0, 0.76);
  backdrop-filter: blur(2px);
}

.modal {
  width: min(560px, 100%);
  max-height: 92vh;
  overflow-y: auto;
  padding: 8px 14px 14px;
  border: 26px solid transparent;
  border-image-source: url("/assets/dark-metal-panel.png");
  border-image-slice: 36 fill;
  border-image-width: 26px;
  border-image-repeat: stretch;
  border-radius: 4px;
  box-shadow: var(--shadow-deep);
}
.modal--sm { width: min(420px, 100%); }

.modal-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-bottom: 12px;
  margin-bottom: 16px;
  border-bottom: 2px solid rgba(217, 180, 92, 0.26);
}
.modal-header h3 {
  flex: 1;
  margin: 0;
  font-family: "Cinzel", "Noto Serif SC", serif;
  font-size: 19px;
  font-weight: 900;
  letter-spacing: 3px;
  color: var(--gold-bright);
  text-shadow: 0 2px 4px #000;
}
.modal-icon { width: 30px; height: 30px; object-fit: contain; flex: none; }

.modal-close {
  width: 30px; height: 30px;
  padding: 0;
  border: none;
  background: none;
  cursor: pointer;
  flex: none;
  transition: filter 0.15s, transform 0.15s;
}
.modal-close img { width: 100%; height: 100%; display: block; object-fit: contain; }
.modal-close:hover { filter: brightness(1.2); transform: rotate(90deg); }

.modal-body { padding: 0; }
.modal-body p { margin: 0; color: #e6d7b0; line-height: 1.7; }

.form-row { margin-bottom: 16px; }
.form-row > label {
  display: block;
  margin-bottom: 7px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--gold-bright);
}
.form-row .req { color: #ff8080; }
.form-row .hint { color: #a08750; font-weight: 400; font-size: 11px; }

.form-row input[type="text"],
.form-row textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 4px;
  border: 2px solid #6d5424;
  background: linear-gradient(180deg, #191410, #0d0a07);
  color: #eadfc0;
  font-size: 13.5px;
  font-family: inherit;
  outline: none;
  resize: vertical;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.form-row input[type="text"]:focus,
.form-row textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 10px rgba(217, 180, 92, 0.4);
}
.form-row input::placeholder,
.form-row textarea::placeholder { color: #7d6a48; }

/* ---------- 职业选择网格 ---------- */
.cls-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
}
.cls-option {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 7px 4px;
  border-radius: 4px;
  border: 2px solid transparent;
  background: rgba(0, 0, 0, 0.32);
  cursor: pointer;
  transition: all 0.15s;
}
.cls-option:hover { background: rgba(217, 180, 92, 0.16); }
.cls-option.is-active {
  border-color: var(--gold-bright);
  background: rgba(243, 217, 138, 0.18);
  box-shadow: 0 0 12px rgba(217, 180, 92, 0.45);
}
.cls-option img {
  width: 40px; height: 40px;
  object-fit: contain;
  display: block;
  border-radius: 3px;
  box-shadow:
    0 0 0 1px #241a0d,
    0 0 0 2px #8a6a2c,
    0 2px 5px rgba(0, 0, 0, 0.5);
}
.cls-option .cls-name { font-size: 11px; color: #e6d7b0; letter-spacing: 1px; }

/* ---------- 截图走马灯（编辑/新增弹窗） ---------- */
.shot-gallery {
  padding: 12px;
  border-radius: 4px;
  border: 2px dashed #6d5424;
  background: rgba(0, 0, 0, 0.28);
}

.shot-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 120px;
  color: #a08750;
  font-size: 13px;
  text-align: center;
  /* 空态不可点：上传一律走下方「上传截图」按钮 */
  cursor: default;
}
.shot-empty small { color: #7d6a48; font-size: 11px; }
.upload-ico {
  display: grid;
  place-items: center;
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 2px solid #6d5424;
  color: var(--gold);
  font-size: 20px;
  line-height: 1;
}

.shot-stage {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 140px;
}
/* 包住图片的框：定位基点相对图片本身，而不是 stage 容器，
   这样不管图片高矮，X 按钮都贴在图片右上角，不会随 stage 高度变化跑偏 */
.shot-frame {
  position: relative;
  display: inline-block;
  line-height: 0;
  max-width: 100%;
}
.shot-img {
  display: block;
  max-width: 100%;
  max-height: 240px;
  border-radius: 3px;
  border: 2px solid #6d5424;
  background: #0d0a07;
  cursor: zoom-in;
}

/* 左右翻页箭头（暗金小牌） */
.shot-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 32px; height: 54px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 2px solid var(--gold-deep);
  border-radius: 4px;
  background: linear-gradient(180deg, #241a0d, #14100a);
  color: var(--gold-bright);
  font-size: 24px;
  font-family: inherit;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
  transition: filter 0.15s, background 0.15s;
}
.shot-nav:hover { filter: brightness(1.28); background: linear-gradient(180deg, #3a2b15, #1d1710); }
.shot-nav--prev { left: 2px; }
.shot-nav--next { right: 2px; }

/* 移除当前这张：相对 .shot-frame（图片本身）定位，top/right 取负值让它压在图片角上。
   ⚠️ 里面的 X 用 CSS 画两条斜线，不要用 ✕ 字符——字符会 fallback 到系统字体，
   字形的 ink 并不在行盒中心（实测在 26px 圆里偏下 3px），换字体就会跑偏。 */
.shot-del {
  position: absolute;
  top: -10px; right: -10px;
  width: 26px; height: 26px;
  padding: 0;
  border: 2px solid #8f2b2b;
  border-radius: 50%;
  background: linear-gradient(180deg, #3a1210, #1c0908);
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
  transition: filter 0.15s, transform 0.1s;
}
.shot-del::before,
.shot-del::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 13px;
  height: 2px;
  border-radius: 1px;
  background: #ffc9c9;
}
.shot-del::before { transform: translate(-50%, -50%) rotate(45deg); }
.shot-del::after  { transform: translate(-50%, -50%) rotate(-45deg); }
.shot-del:hover { filter: brightness(1.35); transform: scale(1.08); }

.shot-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 10px;
}
.shot-dots { display: flex; align-items: center; gap: 7px; }
.shot-dot {
  width: 9px; height: 9px;
  padding: 0;
  border: 1px solid var(--gold-deep);
  border-radius: 50%;
  background: #241a0d;
  cursor: pointer;
  transition: background 0.15s;
}
.shot-dot.is-active {
  background: var(--gold-bright);
  box-shadow: 0 0 7px rgba(247, 229, 155, 0.85);
}
.shot-counter {
  font-family: "Cinzel", monospace;
  font-size: 12px;
  letter-spacing: 1px;
  color: #b9a173;
}

.shot-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 10px;
}
.btn--sm { height: 36px; padding: 0 18px; font-size: 13px; }
.shot-hint { margin-top: 6px; font-size: 11px; color: #a08750; }

.form-error {
  margin-bottom: 14px;
  padding: 9px 12px;
  border-radius: 4px;
  border: 1px solid #8f2b2b;
  background: rgba(143, 29, 29, 0.22);
  color: #ffb4b4;
  font-size: 13px;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  padding-top: 14px;
  margin-top: 4px;
  border-top: 2px solid rgba(217, 180, 92, 0.22);
}

/* ============================================================
   Toast
   ============================================================ */
.toast {
  position: fixed;
  left: 50%;
  bottom: 42px;
  transform: translateX(-50%);
  z-index: 2000;
  padding: 11px 22px;
  border-radius: 4px;
  border: 2px solid var(--gold-deep);
  background: linear-gradient(180deg, #241a0d, #14100a);
  color: #f0e2bd;
  font-size: 14px;
  letter-spacing: 1px;
  box-shadow: var(--shadow-deep);
  animation: toast-in 0.22s ease-out;
}
.toast--ok { border-color: #6a8f2b; color: #d8f0b4; }
.toast--err { border-color: #8f2b2b; color: #ffc0c0; }
@keyframes toast-in {
  from { opacity: 0; transform: translate(-50%, 12px); }
  to   { opacity: 1; transform: translate(-50%, 0); }
}

/* ============================================================
   灯箱
   ============================================================ */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: grid;
  place-items: center;
  padding: 56px 92px 78px;
  background: rgba(0, 0, 0, 0.94);
  cursor: zoom-out;
}
.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 54px; height: 96px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 2px solid var(--gold-deep);
  border-radius: 6px;
  background: rgba(20, 16, 10, 0.86);
  color: var(--gold-bright);
  font-size: 34px;
  font-family: inherit;
  line-height: 1;
  cursor: pointer;
  transition: filter 0.15s, background 0.15s;
}
.lightbox-nav:hover { filter: brightness(1.25); background: rgba(58, 43, 21, 0.92); }
.lightbox-nav--prev { left: 14px; }
.lightbox-nav--next { right: 14px; }
.lightbox-counter {
  position: absolute;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  padding: 5px 16px;
  border-radius: 3px;
  border: 1px solid var(--gold-deep);
  background: rgba(20, 16, 10, 0.86);
  color: var(--gold-bright);
  font-family: "Cinzel", monospace;
  font-size: 13px;
  letter-spacing: 1px;
  cursor: default;
}
.lightbox img {
  max-width: 100%;
  max-height: 100%;
  border: 3px solid var(--gold-deep);
  border-radius: 4px;
  box-shadow: 0 0 34px rgba(217, 180, 92, 0.45);
}
.lightbox-close {
  position: absolute;
  top: 18px; right: 18px;
  width: 42px; height: 42px;
  padding: 0;
  border: none;
  background: none;
  cursor: pointer;
  transition: filter 0.15s, transform 0.1s;
}
.lightbox-close img { width: 100%; height: 100%; display: block; object-fit: contain; }
.lightbox-close:hover { filter: brightness(1.2); transform: scale(1.08); }

/* ============================================================
   响应式
   ============================================================ */
@media (max-width: 1180px) {
  .banner { padding: 14px 130px; }
  .banner-flag { left: 18px; }
  .hall-panel { padding: 24px 20px 18px; border-width: 24px; }
  .hall-title { font-size: 24px; letter-spacing: 4px; }
  .search-box { min-width: 220px; }
}

/* 平板及以上：表格模式 + 最小宽度 + 横向滚动，保证所有列（含截图）都看得到 */
@media (min-width: 781px) {
  .table-wrap { overflow-x: auto; overflow-y: hidden; }
  .hall-table { min-width: 900px; }
}

@media (max-width: 780px) {
  .banner { margin: 10px 10px 0; padding: 12px 14px 12px 88px; min-height: 150px; }
  .banner-flag { left: 8px; height: 84%; }
  .banner-divider { width: 150px; }
  .banner-sub p { font-size: 10px; letter-spacing: 0.2em; }
  .hall-panel { margin: 12px 10px 0; padding: 20px 14px 14px; border-width: 18px; }
  .hall-head { gap: 10px; }
  .hall-tools { width: 100%; }
  .search-box { flex: 1; min-width: 0; }
  .btn { padding: 0 18px; }
  .btn-txt { display: none; }
  .cls-grid { grid-template-columns: repeat(3, 1fr); }

  /* 窄屏：表格转为卡片，所有字段（含拉黑原因、截图）都完整展示，不再隐藏列 */
  .table-wrap { overflow: hidden; }
  .hall-table, .hall-table tbody { display: block; width: 100%; min-width: 0; }
  .hall-table thead { display: none; }
  .hall-table tbody tr {
    display: block;
    margin: 0 0 12px;
    padding: 10px 12px;
    border: 2px solid rgba(140, 105, 40, 0.55);
    border-radius: 4px;
    background: linear-gradient(180deg, rgba(255, 252, 240, 0.62), rgba(206, 174, 112, 0.30));
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.35);
  }
  .hall-table tbody tr:last-child { margin-bottom: 0; }
  .hall-table tbody td {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 3px 0;
    border: none;
    text-align: left;
  }
  .hall-table tbody td::before {
    content: attr(data-label);
    flex: none;
    width: 46px;
    text-align: right;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    line-height: 1.65;
    color: #7a5c22;
  }
  /* 复选框与 ID 挤在同一行，省一条 */
  .hall-table tbody td.col-check,
  .hall-table tbody td.col-id { display: inline-flex; align-items: center; width: auto; }
  .hall-table tbody td.col-check { margin-right: 12px; }
  /* 复选框不需要前置文字 */
  .hall-table tbody td.col-check::before { content: ''; display: none; }
  .hall-table tbody td.col-act { padding-top: 6px; }

  .cell-name { white-space: normal; word-break: break-word; }
  .cell-reason { max-width: none; width: 100%; }
  /* 卡片里同样一行 3 张，缩略图略放大方便点按 */
  .cell-shot { justify-content: flex-start; }
  .shot-thumb { width: 66px; height: 38px; }

  .shot-stage { min-height: 120px; }
  .shot-img { max-height: 180px; }
  .lightbox { padding: 48px 10px 74px; }
  .lightbox-nav { width: 40px; height: 74px; font-size: 26px; }
  .lightbox-nav--prev { left: 4px; }
  .lightbox-nav--next { right: 4px; }
}
