/* 「客来盈」共享样式 */
:root {
  --brand: #ff5a3c;
  --brand2: #ff8a3d;
  --grad: linear-gradient(135deg, #ff6a3d, #ff3d6e);
  --bg: #fff7f3;
  --card: #ffffff;
  --ink: #2b2320;
  --sub: #8a7a72;
  --line: #f3e4dc;
  --ok: #2bb673;
  --radius: 16px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: var(--bg); color: var(--ink); font-size: 15px;
  min-height: 100vh;
}
a { color: var(--brand); text-decoration: none; }
button { font-family: inherit; }

.topbar {
  background: #fff; border-bottom: 1px solid var(--line);
  padding: 12px 20px; display: flex; align-items: center; gap: 14px;
  position: sticky; top: 0; z-index: 100;
}
.topbar .logo { font-weight: 800; font-size: 18px; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.topbar .spacer { flex: 1; }
.topbar .who { color: var(--sub); font-size: 13px; }

.wrap { max-width: 1000px; margin: 0 auto; padding: 22px 16px 60px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: none; cursor: pointer; border-radius: 12px; font-size: 14px;
  padding: 10px 20px; background: #f4ede9; color: var(--ink); transition: .15s;
}
.btn:hover { filter: brightness(.96); }
.btn.primary { background: var(--grad); color: #fff; font-weight: 600; box-shadow: 0 4px 14px rgba(255,90,60,.35); }
.btn.ghost { background: transparent; border: 1px solid var(--brand); color: var(--brand); }
.btn.small { padding: 6px 12px; font-size: 13px; border-radius: 9px; }
.btn.danger { background: #fff1f0; color: #e5533d; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

.card { background: var(--card); border-radius: var(--radius); padding: 18px; box-shadow: 0 2px 10px rgba(80,40,20,.06); }
.grid2 { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }

h2.sec { font-size: 17px; margin: 26px 0 12px; display: flex; align-items: center; gap: 8px; }
h2.sec::before { content: ''; width: 4px; height: 16px; border-radius: 2px; background: var(--grad); }

input, select {
  width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px;
  font-size: 14px; outline: none; background: #fff; font-family: inherit;
}
input:focus, select:focus { border-color: var(--brand); }
label { font-size: 13px; color: var(--sub); display: block; margin: 10px 0 4px; }

table { width: 100%; border-collapse: collapse; font-size: 13.5px; background: #fff; }
th, td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--line); }
th { color: var(--sub); font-weight: 600; background: #fffaf7; }
tr:last-child td { border-bottom: none; }

.badge { display: inline-block; padding: 2px 9px; border-radius: 20px; font-size: 12px; }
.badge.none { background: #f0ebe8; color: #9b8d86; }
.badge.testing { background: #fff4dd; color: #c8891a; }
.badge.published { background: #e5f8ee; color: #1a9e64; }
.badge.expired { background: #fdeaea; color: #d54941; }
.badge.used { background: #f0ebe8; color: #9b8d86; }
.badge.unused { background: #e5f8ee; color: #1a9e64; }

.modal-mask {
  position: fixed; inset: 0; background: rgba(40,20,10,.45); z-index: 500;
  display: flex; align-items: center; justify-content: center; padding: 16px;
}
.modal { background: #fff; border-radius: 18px; width: 100%; max-width: 520px; max-height: 88vh; overflow: auto; padding: 22px; }
.modal h3 { margin-bottom: 6px; }
.modal .close { float: right; border: none; background: none; font-size: 20px; cursor: pointer; color: var(--sub); }

.tabs { display: flex; gap: 6px; margin: 18px 0; background: #fff; padding: 6px; border-radius: 14px; border: 1px solid var(--line); overflow-x: auto; }
.tabs button {
  flex: 1; border: none; background: none; padding: 9px 14px; border-radius: 10px;
  cursor: pointer; font-size: 14px; color: var(--sub); white-space: nowrap;
}
.tabs button.on { background: var(--grad); color: #fff; font-weight: 600; }

.empty { text-align: center; color: var(--sub); padding: 34px 0; font-size: 14px; }

/* 落地页 */
.hero { text-align: center; padding: 54px 16px 30px; }
.hero h1 { font-size: 34px; letter-spacing: 1px; margin-bottom: 12px; }
.hero h1 span { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p { color: var(--sub); font-size: 15px; max-width: 560px; margin: 0 auto 26px; line-height: 1.8; }
.hero .cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.feature { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; margin-top: 30px; }
.feature .card { text-align: center; padding: 22px 16px; }
.feature .ic { font-size: 34px; margin-bottom: 8px; }
.authbox { max-width: 400px; margin: 26px auto; }
.demo-tip { font-size: 12.5px; color: var(--sub); background: #fff3ec; border: 1px dashed #ffc7b0; border-radius: 10px; padding: 8px 12px; margin-top: 12px; line-height: 1.7; }

/* 活动页 */
.actpage { max-width: 480px; margin: 0 auto; padding-bottom: 70px; }
.acthead { text-align: center; padding: 26px 16px 8px; }
.acthead .store { color: var(--brand); font-size: 14px; font-weight: 600; letter-spacing: 2px; }
.acthead h1 { font-size: 24px; margin: 6px 0 4px; }
.acthead .wel { color: var(--sub); font-size: 14px; }
.demo-watermark { position: fixed; right: -34px; top: 46%; transform: rotate(45deg); background: rgba(255,90,60,.85); color: #fff; padding: 6px 40px; font-size: 13px; z-index: 300; pointer-events: none; }

/* 大转盘 */
.wheelbox { position: relative; width: 300px; height: 300px; margin: 22px auto; }
.wheelbox canvas { border-radius: 50%; box-shadow: 0 8px 30px rgba(255,90,60,.3); }
.wheel-pointer {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%,-50%);
  width: 72px; height: 72px; border-radius: 50%; background: var(--grad); color: #fff;
  border: 5px solid #fff; box-shadow: 0 4px 14px rgba(0,0,0,.2);
  display: flex; align-items: center; justify-content: center; flex-direction: column;
  font-size: 13px; font-weight: 700; cursor: pointer; z-index: 5; user-select: none;
}

/* 刮刮卡 */
.scratchbox { position: relative; width: 320px; height: 130px; margin: 22px auto; border-radius: 14px; overflow: hidden; box-shadow: 0 6px 24px rgba(255,90,60,.25); }
.scratch-under { position: absolute; inset: 0; background: var(--grad); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 20px; font-weight: 700; letter-spacing: 1px; }
#scratchCanvas { position: absolute; inset: 0; cursor: crosshair; }

/* 九宫格 */
.gridbox { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; width: 320px; margin: 22px auto; }
.gridcell { aspect-ratio: 1; background: #fff; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 13px; text-align: center; padding: 6px; color: var(--sub); box-shadow: 0 2px 8px rgba(80,40,20,.08); transition: .15s; }
.gridcell.hit { background: var(--grad); color: #fff; font-weight: 700; transform: scale(1.05); }
.gridcell.go { background: #fff3ec; color: var(--brand); font-weight: 700; cursor: pointer; box-shadow: 0 4px 14px rgba(255,90,60,.3); }

.coupon {
  background: #fff; border: 2px dashed var(--brand); border-radius: 14px; padding: 18px;
  text-align: center; max-width: 340px; margin: 18px auto;
}
.coupon .code { font-size: 26px; font-weight: 800; letter-spacing: 3px; color: var(--brand); font-family: monospace; margin: 8px 0; }
.rules { font-size: 12.5px; color: var(--sub); line-height: 1.8; background: #fff; border-radius: 12px; padding: 14px; max-width: 420px; margin: 20px auto 0; }

.stat-mini { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 12px; margin-bottom: 14px; }
.stat-mini .card { text-align: center; padding: 14px; }
.stat-mini b { font-size: 22px; color: var(--brand); display: block; }
.stat-mini span { font-size: 12.5px; color: var(--sub); }

.price-tag { color: var(--brand); font-weight: 700; }
@media (max-width: 560px) {
  .wrap { padding: 14px 10px 50px; }
  .hero h1 { font-size: 26px; }
  table { font-size: 12px; }
  th, td { padding: 7px 6px; }
}
