@charset "utf-8";
/* ============================================================
 * 大转盘模块样式（WHEEL_V1）
 *  1) 参与页：转盘 + 面板（电脑端布局/位置/大小可配置，手机端固定）
 *  2) 结果区 / 我的抽奖结果
 *  3) 创建与管理表单（含深色容器 .wh-admin-panel）
 *  4) 后台管理列表 + 弹窗
 * ⚠️ 凡使用 .wh-* 类的页面都必须自行 <link> 本文件（带 filemtime 版本号）
 * ============================================================ */

/* ========== 变量默认值 ========== */
.wh-body,
.wh-root {
  --wh-bg-color: #2a1b6b;
  --wh-fg: #ffffff;
  --wh-size: 420px;
  --wh-ring: #ffd54f;
  --wh-hub: #ff5252;
  --wh-pointer: #ff5252;
  --wh-seg-fs: 0px;
  --wh-seg-fc: #ffffff;
  --wh-maxw: 1080px;
}
/* 独立参与页：清除浏览器默认 body 外边距（8px），否则四周出现白边、无法充满手机屏幕 */
body.wh-body { margin: 0; padding: 0; background: var(--wh-bg-color); }

/* ========== 参与页骨架 ========== */
.wh-root {
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--wh-bg-color);
  color: var(--wh-fg);
  position: relative;
  overflow-x: hidden;
}
.wh-bg {
  position: absolute;
  inset: 0;
  top: 0; right: 0; bottom: 0; left: 0;
  z-index: 0;
  pointer-events: none;
  background-image: var(--wh-bg-image, none);
  background-size: var(--wh-bg-fit, cover);
  background-position: center;
  background-repeat: no-repeat;
}
.wh-bg::after {
  content: "";
  position: absolute;
  inset: 0; top: 0; right: 0; bottom: 0; left: 0;
  background: rgba(0, 0, 0, .38);
}
.wh-page {
  position: relative;
  z-index: 1;
  width: var(--wh-page-w, 100%);
  max-width: var(--wh-page-w, var(--wh-maxw));
  min-height: var(--wh-page-h, auto);
  margin: 0 auto;
  padding: 16px 14px 40px;
  box-sizing: border-box;
}

/* ========== WHEEL_SIZE_PCT_V1：各模块按屏幕百分比设定 宽 / 高 / 水平位置 ==========
   宽 = 占内容区百分比；高 = 占屏幕高度百分比(vh)；水平位置 0=最左 50=居中 100=最右
   后台未配置时全部回退默认（宽 100%、高度自动、居中） */
.wh-page [data-wh-mod] { box-sizing: border-box; }
.wh-page [data-wh-mod="title"] {
  width: var(--wh-title-w, 100%);
  min-height: var(--wh-title-h, auto);
  margin-left: clamp(0%, calc(var(--wh-title-x, 50) * 1% - var(--wh-title-w, 100%) * .5), calc(100% - var(--wh-title-w, 100%)));
  margin-right: auto;
}
.wh-page [data-wh-mod="wheel"] {
  width: var(--wh-wheel-w, 100%);
  min-height: var(--wh-wheel-h, auto);
  margin-left: clamp(0%, calc(var(--wh-wheel-x, 50) * 1% - var(--wh-wheel-w, 100%) * .5), calc(100% - var(--wh-wheel-w, 100%)));
  margin-right: auto;
}
.wh-page [data-wh-mod="win"] {
  width: var(--wh-win-w, 100%);
  min-height: var(--wh-win-h, auto);
  margin-left: clamp(0%, calc(var(--wh-win-x, 50) * 1% - var(--wh-win-w, 100%) * .5), calc(100% - var(--wh-win-w, 100%)));
  margin-right: auto;
}
.wh-page [data-wh-mod="prizes"] {
  width: var(--wh-prizes-w, 100%);
  min-height: var(--wh-prizes-h, auto);
  margin-left: clamp(0%, calc(var(--wh-prizes-x, 50) * 1% - var(--wh-prizes-w, 100%) * .5), calc(100% - var(--wh-prizes-w, 100%)));
  margin-right: auto;
}
.wh-page [data-wh-mod="rules"] {
  width: var(--wh-rules-w, 100%);
  min-height: var(--wh-rules-h, auto);
  margin-left: clamp(0%, calc(var(--wh-rules-x, 50) * 1% - var(--wh-rules-w, 100%) * .5), calc(100% - var(--wh-rules-w, 100%)));
  margin-right: auto;
}
.wh-page [data-wh-mod="description"] {
  width: var(--wh-description-w, 100%);
  min-height: var(--wh-description-h, auto);
  margin-left: clamp(0%, calc(var(--wh-description-x, 50) * 1% - var(--wh-description-w, 100%) * .5), calc(100% - var(--wh-description-w, 100%)));
  margin-right: auto;
}
.wh-page [data-wh-mod="info"] {
  width: var(--wh-info-w, 100%);
  min-height: var(--wh-info-h, auto);
  margin-left: clamp(0%, calc(var(--wh-info-x, 50) * 1% - var(--wh-info-w, 100%) * .5), calc(100% - var(--wh-info-w, 100%)));
  margin-right: auto;
}

/* ========== WHEEL_PLACEHOLDER_V1：占位模块 ==========
   一块完全透明、不含任何内容的区域：只占位置把其它模块撑开，
   让该区域的活动背景图完整露出（常用于避开背景图上的文字/图案，或留出呼吸空白）。
   宽 = 占内容区百分比；高 / 上间距 = 占屏幕高度百分比(vh)；水平位置 0=最左 50=居中 100=最右 */
.wh-ph {
  box-sizing: border-box;
  flex: 0 0 auto;
  width: var(--wh-ph-w, 100%);
  min-height: var(--wh-ph-h, 0px);
  margin-top: var(--wh-ph-mt, 0px);
  margin-left: clamp(0%, calc(var(--wh-ph-x, 50) * 1% - var(--wh-ph-w, 100%) * .5), calc(100% - var(--wh-ph-w, 100%)));
  margin-right: auto;
  padding: 0;
  border: 0;
  background: transparent;
  /* 透明留白不拦交互：占位区域内的点击照常穿透到底层 */
  pointer-events: none;
}

/* ========== 顶部主视觉 ========== */
.wh-hero {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 12px;
  background: linear-gradient(135deg, rgba(255, 255, 255, .16), rgba(0, 0, 0, .18));
  border: 1px solid rgba(255, 255, 255, .18);
}
.wh-hero-img {
  position: absolute;
  left: 0; top: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.wh-hero-veil {
  position: absolute;
  left: 0; top: 0; right: 0; bottom: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, .18), rgba(0, 0, 0, .55));
}
.wh-hero-in {
  position: relative;
  padding: 18px 16px;
  text-align: center;
}
.wh-hero-badge {
  display: inline-block;
  padding: 3px 12px;
  border-radius: 999px;
  font-size: 12px;
  background: rgba(255, 255, 255, .22);
  border: 1px solid rgba(255, 255, 255, .3);
}
.wh-hero-title {
  margin: 8px 0 4px;
  font-size: 22px;
  line-height: 1.4;
  font-weight: 800;
  word-break: break-word;
}
.wh-hero-sub {
  margin: 0;
  font-size: 13px;
  opacity: .88;
}
.wh-clock {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 12px;
  background: rgba(0, 0, 0, .3);
}
.wh-clock-t { font-size: 13px; letter-spacing: .5px; }
.wh-lead {
  margin: 0 0 14px;
  font-size: 13px;
  line-height: 1.8;
  opacity: .9;
  text-align: center;
  white-space: pre-wrap;
}
.wh-info-text {
  margin: 8px 0 0;
  font-size: 13px;
  line-height: 1.8;
  opacity: .9;
  white-space: pre-wrap;
}

/* ========== 主体布局（电脑端可配置） ========== */
.wh-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}
.wh-stage-col { min-width: 0; }
.wh-side { min-width: 0; display: flex; flex-direction: column; gap: 12px; }

/* 转盘居中（默认）：单列，转盘居中，面板落到下方 */
.wh-page.wh-pc-center .wh-grid { grid-template-columns: minmax(0, 1fr); }
.wh-page.wh-pc-center .wh-stage-col { max-width: 100%; }

/* 转盘在左：转盘列在前；转盘在右：转盘列在后 */
.wh-page.wh-pc-left .wh-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); }
.wh-page.wh-pc-right .wh-grid { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); }
.wh-page.wh-pc-right .wh-stage-col { order: 2; }
.wh-page.wh-pc-right .wh-side { order: 1; }
/* 关闭侧边栏时整页单列 */
.wh-page.wh-nopanel .wh-grid { grid-template-columns: minmax(0, 1fr); }
.wh-page.wh-nopanel .wh-side { display: none; }

/* 水平对齐 */
.wh-align-left .wh-wheel-wrap { justify-content: flex-start; }
.wh-align-center .wh-wheel-wrap { justify-content: center; }
.wh-align-right .wh-wheel-wrap { justify-content: flex-end; }

/* ========== 转盘 ========== */
.wh-wheel-wrap {
  display: flex;
  justify-content: center;
  margin: 4px 0 10px;
}
.wh-ring {
  position: relative;
  width: var(--wh-wheel-w, var(--wh-size));
  max-width: min(100%, 92vw);
  height: var(--wh-wheel-h, auto);
  aspect-ratio: var(--wh-wheel-ar, 1 / 1);
  border-radius: 50%;
  padding: 10px;
  box-sizing: border-box;
  background: var(--wh-ring);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .35), inset 0 0 0 4px rgba(255, 255, 255, .22);
}
.wh-ring-inner {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: inset 0 0 0 2px rgba(0, 0, 0, .12);
  /* WHEEL_SIZE_PCT_V1：宽高不等时画布居中，避免转盘被拉成椭圆 */
  display: flex;
  align-items: center;
  justify-content: center;
}
.wh-canvas {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  transform: rotate(0deg);
  transform-origin: 50% 50%;
  will-change: transform;
}
/* 指针（顶部，向下） */
.wh-pointer {
  position: absolute;
  left: 50%;
  top: -4px;
  z-index: 4;
  transform: translateX(-50%);
  width: 0; height: 0;
  border-left: 13px solid transparent;
  border-right: 13px solid transparent;
  border-top: 28px solid var(--wh-pointer);
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, .45));
}
/* 圆心按钮 */
.wh-hub {
  position: absolute;
  left: 50%; top: 50%;
  z-index: 3;
  transform: translate(-50%, -50%);
  width: 21%;
  height: 21%;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, .85);
  background: radial-gradient(circle at 35% 30%, #ffffff 0%, var(--wh-hub) 62%);
  color: #fff;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 1px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .4);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
.wh-hub:active { transform: translate(-50%, -50%) scale(.94); }
.wh-hub[disabled] {
  cursor: default;
  background: radial-gradient(circle at 35% 30%, #dddddd 0%, #9e9e9e 62%);
}
.wh-hub .wh-hub-txt { line-height: 1.15; text-align: center; }

.wh-spin-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 4px;
}
.wh-btn {
  display: inline-block;
  padding: 10px 22px;
  border-radius: 999px;
  border: none;
  background: var(--wh-hub, #ff5252);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  line-height: 1.4;
}
.wh-btn.ghost { background: transparent; border: 1px solid rgba(255, 255, 255, .5); }
.wh-btn[disabled] { opacity: .55; cursor: default; }
.wh-times {
  font-size: 12.5px;
  opacity: .9;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(0, 0, 0, .28);
}
.wh-note-line {
  text-align: center;
  font-size: 12.5px;
  opacity: .85;
  margin-top: 8px;
}

/* ========== 侧边面板 ========== */
.wh-panel {
  background: rgba(255, 255, 255, .12);
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 12px;
  padding: 12px 14px;
  backdrop-filter: blur(2px);
}
.wh-panel-h {
  margin: 0 0 10px;
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}
.wh-panel-h .n { font-size: 12px; font-weight: 400; opacity: .75; }
.wh-prizes {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(112px, 1fr));
  gap: 10px;
}
.wh-pi {
  background: rgba(0, 0, 0, .22);
  border-radius: 10px;
  padding: 9px 8px;
  text-align: center;
  overflow: hidden;
}
.wh-pi-media {
  width: 46px; height: 46px;
  margin: 0 auto 6px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: rgba(0, 0, 0, .2);
}
.wh-pi-img { width: 100%; height: 100%; object-fit: cover; }
.wh-pi-icon { font-size: 24px; }
.wh-pi-no {
  display: inline-block;
  min-width: 18px;
  font-size: 11px;
  opacity: .8;
  margin-bottom: 2px;
}
.wh-pi-name {
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.4;
  word-break: break-word;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.wh-pi-rate { font-size: 11px; opacity: .8; margin-top: 3px; }
.wh-pi-left { font-size: 11px; opacity: .7; margin-top: 2px; }
.wh-rules-d summary { cursor: pointer; font-size: 13px; }
.wh-rules {
  margin-top: 8px;
  font-size: 12.5px;
  line-height: 1.9;
  opacity: .9;
  white-space: pre-wrap;
}
.wh-meta { margin: 0; display: grid; grid-template-columns: 76px 1fr; gap: 6px 10px; font-size: 12.5px; }
.wh-meta dt { opacity: .72; }
.wh-meta dd { margin: 0; }

/* ========== 结果区 ========== */
.wh-result {
  margin-top: 16px;
  border-radius: 14px;
  padding: 16px;
  background: rgba(255, 255, 255, .13);
  border: 1px solid rgba(255, 255, 255, .2);
}
.wh-result.is-win { background: rgba(255, 213, 79, .2); border-color: rgba(255, 213, 79, .5); }
.wh-result.is-miss { background: rgba(255, 255, 255, .1); }
.wh-res-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.wh-res-img {
  width: 64px; height: 64px;
  border-radius: 10px;
  object-fit: cover;
  background: rgba(0, 0, 0, .2);
}
.wh-res-ico { font-size: 40px; }
.wh-res-t { font-size: 17px; font-weight: 800; margin: 0 0 2px; }
.wh-res-s { font-size: 12.5px; opacity: .85; margin: 0; }
.wh-res-code {
  margin-top: 10px;
  display: inline-block;
  padding: 5px 12px;
  border-radius: 8px;
  background: rgba(0, 0, 0, .3);
  font-size: 13px;
  letter-spacing: 1px;
}
.wh-res-form { margin-top: 12px; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.wh-res-form input {
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, .35);
  background: rgba(0, 0, 0, .25);
  color: #fff;
  font-size: 14px;
  min-width: 140px;
}
.wh-res-form input::placeholder { color: rgba(255, 255, 255, .6); }
.wh-myrec-title { margin: 18px 0 10px; font-size: 14px; font-weight: 700; opacity: .9; }
.wh-myrec-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.wh-myrec {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: 10px;
  background: rgba(0, 0, 0, .22);
}
.wh-myrec-media {
  width: 40px; height: 40px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: rgba(0, 0, 0, .25);
  flex: 0 0 auto;
}
.wh-myrec-media img { width: 100%; height: 100%; object-fit: cover; }
.wh-myrec-emoji { font-size: 20px; }
.wh-myrec-main { min-width: 0; }
.wh-myrec-main b { display: block; font-size: 13px; word-break: break-word; }
.wh-myrec-main i { display: block; font-size: 11.5px; font-style: normal; opacity: .8; margin-top: 2px; }
.wh-badge {
  display: inline-block;
  padding: 1px 8px;
  border-radius: 10px;
  font-size: 11px;
  background: rgba(0, 0, 0, .3);
}
.wh-badge.ok { background: rgba(76, 175, 80, .35); }
.wh-badge.wait { background: rgba(255, 152, 0, .35); }
.wh-empty {
  padding: 22px;
  text-align: center;
  font-size: 13px;
  opacity: .8;
  border: 1px dashed rgba(255, 255, 255, .28);
  border-radius: 12px;
}

/* ========== 错误页 ========== */
.wh-err {
  position: relative;
  z-index: 1;
  max-width: 520px;
  margin: 80px auto;
  padding: 30px 24px;
  text-align: center;
  background: rgba(255, 255, 255, .12);
  border-radius: 14px;
}
.wh-err a { color: #ffd54f; }

/* ========== 手机端：固定形式 ==========
   ⚠️ WHEEL_PC_MOBILE_SPLIT_V1：断点统一为 900px，与 play.php 注入的模块顺序规则、
   wheel.js 的 matchMedia('(min-width:900px)') 保持一致，避免 861–900px 区间两端规则打架 */
@media (max-width: 900px) {
  /* 手机端：单列流式；各模块顺序由后台「模块显示位置」配置（play.php 注入 order）决定 */
  .wh-page { padding: 12px max(10px, env(safe-area-inset-right)) 32px max(10px, env(safe-area-inset-left)); display: flex; flex-direction: column; gap: 10px; }
  /* display:contents 让转盘列 / 侧栏内的模块直接参与页面级排序 */
  .wh-page .wh-grid { display: contents; }
  .wh-page .wh-stage-col { order: 1; max-width: 100% !important; }
  .wh-page .wh-side { display: contents; }
  .wh-page .wh-side > * { margin-bottom: 10px; }
  .wh-wheel-wrap { justify-content: center !important; }
  .wh-ring { width: var(--wh-wheel-w, min(var(--wh-size), 92vw)); }
  .wh-hero-title { font-size: 19px; }
  .wh-prizes { grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
  .wh-myrec-list { grid-template-columns: 1fr; }
  .wh-hub { font-size: 13px; }
}

/* ============================================================
 * 表单 / 管理（深色容器，避免后台浅色底上白字不可见）
 * ============================================================ */
.wh-admin-panel {
  background: #1f2233;
  color: #fff;
  border-radius: 12px;
  padding: 16px;
}
.wh-admin-panel .wh-title { margin: 0 0 6px; font-size: 20px; font-weight: 800; }
.wh-admin-panel .wh-desc { margin: 0 0 14px; font-size: 13px; line-height: 1.8; opacity: .82; }
.wh-admin-panel a { color: #ffd54f; }

.wh-wrap { max-width: 900px; margin: 0 auto; padding: 14px 12px 40px; }
.wh-form {
  background: #1f2233;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 12px;
}
.wh-form label { display: block; font-size: 13px; margin: 10px 0 4px; opacity: .9; }
.wh-form input[type="text"],
.wh-form input[type="number"],
.wh-form select,
.wh-form textarea {
  width: 100%;
  padding: 9px 10px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, .22);
  background: rgba(0, 0, 0, .28);
  color: #fff;
  font-size: 14px;
  box-sizing: border-box;
  font-family: inherit;
}
.wh-form input[type="color"] {
  width: 52px; height: 32px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .28);
  border-radius: 6px;
  background: transparent;
}
.wh-form input[type="file"] { color: #fff; font-size: 13px; }
.wh-form textarea { resize: vertical; }
.wh-fieldset {
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 10px;
  padding: 10px 12px 14px;
  margin: 12px 0;
}
.wh-fieldset legend { font-size: 13px; font-weight: 700; padding: 0 6px; }
.wh-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin: 8px 0;
}
.wh-row > label { min-width: 108px; margin: 0; }
.wh-hint { font-size: 12px; opacity: .66; line-height: 1.7; }
.wh-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; }
.wh-grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px 14px; }
.wh-radios { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.wh-radios label { min-width: auto; white-space: nowrap; }
.wh-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 12px; }
.wh-btn-add {
  margin-top: 8px;
  padding: 7px 14px;
  border-radius: 8px;
  border: 1px dashed rgba(255, 255, 255, .4);
  background: transparent;
  color: #fff;
  font-size: 13px;
  cursor: pointer;
}
.wh-qr { margin-top: 12px; display: flex; justify-content: center; }
.wh-qr img, .wh-qr canvas { background: #fff; border-radius: 8px; padding: 6px; }

/* 扇区（奖项）编辑行 */
.wh-seg-list { display: flex; flex-direction: column; gap: 10px; }
.wh-seg-row {
  display: block;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 10px;
  background: rgba(255, 255, 255, .05);
}
.wh-seg-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.wh-seg-no { font-size: 12px; font-weight: 600; opacity: .8; white-space: nowrap; }
.wh-seg-del {
  padding: 4px 10px;
  border-radius: 7px;
  border: 1px solid rgba(255, 82, 82, .5);
  background: rgba(255, 82, 82, .22);
  color: #fff;
  cursor: pointer;
  font-size: 12px;
  line-height: 1.4;
}
.wh-seg-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 12px;
}
.wh-fld { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.wh-fld-name { grid-column: 1 / -1; }
.wh-seg-sub {
  grid-column: 1 / -1;
  display: flex;
  gap: 14px 18px;
  flex-wrap: wrap;
  align-items: flex-start;
}
.wh-fld-lbl { font-size: 12px; font-weight: 600; opacity: .85; }
.wh-fld-tip { font-size: 11px; opacity: .62; line-height: 1.4; }
.wh-fld input[type="text"],
.wh-fld input[type="number"] {
  width: 100%;
  box-sizing: border-box;
  padding: 8px 10px;
  font-size: 14px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, .22);
  background: rgba(0, 0, 0, .28);
  color: #fff;
}
.wh-fld input[type="color"] {
  width: 100%;
  height: 38px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 8px;
  box-sizing: border-box;
}
.wh-blank-chk,
.wh-img-del { display: flex; align-items: center; gap: 5px; font-size: 12px; opacity: .9; white-space: normal; }
.wh-pimg-box {
  width: 42px; height: 42px;
  border-radius: 7px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, .3);
  flex: 0 0 auto;
}
.wh-pimg-box img { width: 100%; height: 100%; object-fit: cover; }
.wh-seg-legend { font-size: 12px; opacity: .7; line-height: 1.8; margin-top: 8px; }
.wh-seg-count { font-size: 12px; opacity: .85; }

/* 后台管理页 */
.wh-adm-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.wh-adm-title { margin: 0 0 4px; font-size: 20px; font-weight: 800; }
.wh-adm-sub { margin: 0 0 8px; font-size: 12.5px; opacity: .72; }
.wh-adm-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.wh-adm-btn {
  display: inline-block;
  padding: 8px 14px;
  border-radius: 8px;
  background: #ff7043;
  color: #fff;
  border: none;
  font-size: 13px;
  cursor: pointer;
  text-decoration: none;
  line-height: 1.4;
}
.wh-adm-btn.ghost { background: transparent; border: 1px solid rgba(255, 255, 255, .35); }
.wh-adm-btn.danger { background: #c62828; }
.wh-adm-card {
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 12px;
  background: rgba(255, 255, 255, .04);
}
.wh-adm-card h3 { margin: 0 0 10px; font-size: 14px; }
.wh-adm-note { font-size: 12px; opacity: .7; line-height: 1.8; margin: 0 0 8px; }
.wh-adm-stats { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.wh-adm-stat {
  flex: 1 1 120px;
  padding: 10px;
  border-radius: 10px;
  background: rgba(255, 255, 255, .07);
  text-align: center;
}
.wh-adm-stat b { display: block; font-size: 20px; }
.wh-adm-stat span { font-size: 12px; opacity: .75; }
.wh-adm-alert { padding: 9px 12px; border-radius: 8px; font-size: 13px; margin-bottom: 10px; }
.wh-adm-alert.ok { background: rgba(76, 175, 80, .22); }
.wh-adm-alert.no { background: rgba(198, 40, 40, .25); }
.wh-adm-win {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border-radius: 9px;
  background: rgba(0, 0, 0, .2);
  margin-bottom: 8px;
  flex-wrap: wrap;
}
.wh-adm-win-img {
  width: 44px; height: 44px;
  border-radius: 8px;
  overflow: hidden;
  flex: 0 0 auto;
  background: rgba(0, 0, 0, .25);
  display: flex;
  align-items: center;
  justify-content: center;
}
.wh-adm-win-img img { width: 100%; height: 100%; object-fit: cover; }
.wh-adm-win .w-body { flex: 1 1 180px; min-width: 0; }
.wh-adm-win .w-prize { font-size: 13.5px; font-weight: 600; }
.wh-adm-win .w-info { font-size: 11.5px; opacity: .75; margin-top: 3px; }
.wh-adm-savebar {
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: flex-end;
  flex-wrap: wrap;
}
.wh-adm-savebar .tip { font-size: 12px; opacity: .7; margin-right: auto; }
.wh-link-btn {
  border: none;
  background: none;
  color: #1a73e8;
  cursor: pointer;
  font-size: 13px;
  padding: 0 6px;
}
.wh-modal {
  display: none;
  position: fixed;
  left: 0; top: 0; right: 0; bottom: 0;
  inset: 0;
  z-index: 999;
  background: rgba(0, 0, 0, .55);
  align-items: center;
  justify-content: center;
  padding: 16px;
  box-sizing: border-box;
}
.wh-modal-box {
  width: 100%;
  max-width: 480px;
  max-height: 88vh;
  overflow-y: auto;
  background: #1f2233;
  color: #fff;
  border-radius: 12px;
  padding: 16px;
}
.wh-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 15px;
  font-weight: 700;
}
.wh-modal-head button {
  border: none;
  background: none;
  color: #fff;
  font-size: 16px;
  cursor: pointer;
}
.wh-link-row { display: flex; gap: 8px; align-items: center; }
.wh-link-row input[type="text"] {
  flex: 1;
  min-width: 0;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, .25);
  background: rgba(0, 0, 0, .28);
  color: #fff;
  font-size: 13px;
}
.wh-list-tile {
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 10px;
  padding: 12px;
  background: rgba(255, 255, 255, .04);
}
.wh-list-tile h3 { margin: 0 0 6px; font-size: 14px; }
.wh-grid-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }

/* 表单手机端：整行 + 16px 输入防 iOS 缩放 */
@media (max-width: 640px) {
  .wh-grid2, .wh-grid3 { grid-template-columns: 1fr; }
  .wh-row > label { min-width: 100%; }
  .wh-form input[type="text"],
  .wh-form input[type="number"],
  .wh-form select,
  .wh-form textarea,
  .wh-seg-row input[type="text"],
  .wh-seg-row input[type="number"] { font-size: 16px; }
  /* 扇区行手机端单列堆叠：每个字段占满宽度、标题清晰 */
  .wh-seg-grid { grid-template-columns: 1fr; gap: 10px; }
  .wh-fld-name { grid-column: auto; }
}
