/* ItemDraw GrowthHub — 配色取自 GrowthHub 图片：深海军蓝 / 浅蓝 / 琥珀色 */
:root {
  --navy: #0a3274; --blue: #2156a3; --sky: #e8f0fb; --sky2: #d6e4fa;
  --amber: #f5a623; --amber-soft: #fff4d6; --ink: #1d2433; --muted: #5f6b7a;
  --line: #dfe5ee; --ok: #137333; --ok-soft: #e6f4ea; --err: #b3261e; --err-soft: #fce8e6;
  --radius: 10px; --bg: #f6f8fb;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; }
body { font-family: -apple-system, "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif; font-size: 15px;
       color: var(--ink); background: var(--bg); -webkit-text-size-adjust: 100%; }
.wrap { max-width: 640px; margin: 0 auto; padding: 12px 12px 90px; }
.banner { position: relative; height: 96px; border-radius: var(--radius); overflow: hidden;
          background: var(--navy) url(img/header.webp) center right / cover no-repeat; margin-bottom: 12px; }
.banner::before { content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(10,50,116,.95) 30%, rgba(10,50,116,.35) 62%, rgba(10,50,116,0) 80%); }
.banner .t { position: absolute; z-index: 1; left: 16px; top: 50%; transform: translateY(-50%); color: #fff; }
.banner .t b { display: block; font-size: 19px; letter-spacing: .5px; }
.banner .t span { font-size: 12px; opacity: .85; }
.demo-flag { background: var(--amber-soft); color: #7a4c00; border-radius: 8px; padding: 8px 10px; font-size: 13px; margin-bottom: 10px; }
label { display: block; margin: 10px 0 4px; color: var(--muted); font-size: 13px; }
input, select, textarea { width: 100%; padding: 10px; font-size: 16px; border: 1px solid var(--line);
       border-radius: 8px; background: #fff; color: var(--ink); font-family: inherit; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px var(--sky); }
.row { display: flex; gap: 8px; } .row > * { flex: 1; min-width: 0; }
.btn { display: inline-block; width: 100%; padding: 12px; font-size: 15px; font-weight: 600; border: 0;
       border-radius: 8px; cursor: pointer; text-align: center; font-family: inherit; }
.btn-primary { background: var(--navy); color: #fff; }
.btn-amber { background: var(--amber); color: #2b1a00; }
.btn-ghost { background: var(--sky); color: var(--navy); }
.btn:disabled { opacity: .5; cursor: default; }
.msg { margin-top: 12px; padding: 10px 12px; border-radius: 8px; white-space: pre-line; line-height: 1.5; }
.msg.ok { background: var(--ok-soft); color: var(--ok); }
.msg.warn { background: var(--amber-soft); color: #7a4c00; }
.msg.err { background: var(--err-soft); color: var(--err); }
.card { border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; background: #fff; }
.muted { color: var(--muted); font-size: 12px; }
.req { color: var(--err); }
.seg { display: flex; background: var(--sky); border-radius: 8px; padding: 3px; gap: 3px; }
.seg button { flex: 1; border: 0; background: transparent; padding: 8px 0; border-radius: 6px; font-size: 14px;
              color: var(--navy); cursor: pointer; font-family: inherit; }
.seg button.on { background: #fff; font-weight: 700; box-shadow: 0 1px 2px rgba(10,50,116,.15); }
.empty { text-align: center; padding: 18px 8px; color: var(--muted); }
.empty img { width: 70%; max-width: 240px; }
.chips { display: flex; gap: 6px; margin: 10px 0; }
.chip { flex: 1; border: 1px solid var(--line); background: #fff; border-radius: 18px; padding: 8px 0; font-size: 14px;
        color: var(--navy); cursor: pointer; font-family: inherit; }
.chip.on { background: var(--navy); color: #fff; border-color: var(--navy); }
.item { display: flex; gap: 10px; align-items: center; padding: 10px; border: 1px solid var(--line); border-radius: var(--radius);
        margin-bottom: 8px; cursor: pointer; background: #fff; }
.item:active { background: var(--sky); }
.item img { width: 38px; height: 38px; border-radius: 9px; flex: none; }
.item .n { font-weight: 700; font-size: 15px; }
.item .s { color: var(--muted); font-size: 12px; margin-top: 2px; }
.due { color: #a04a00; font-weight: 600; }
.loading { text-align: center; color: var(--muted); padding: 20px; }
.lead-name { font-size: 19px; font-weight: 700; color: var(--navy); margin: 0 0 4px; word-break: break-word; }
.meta { color: var(--muted); font-size: 13px; line-height: 1.6; }
.meta a { color: var(--blue); text-decoration: none; }
.steps { display: flex; gap: 2px; margin: 12px 0 4px; }
.st { flex: 1; border: 0; background: transparent; padding: 4px 0 2px; border-radius: 8px; cursor: pointer;
      text-align: center; font-family: inherit; opacity: .38; }
.st img { width: 40px; height: 40px; display: block; margin: 0 auto 2px; border-radius: 9px; }
.st span { font-size: 11px; color: var(--navy); white-space: nowrap; }
.st.done { opacity: .85; }
.st.cur { opacity: 1; background: var(--sky); box-shadow: inset 0 0 0 2px var(--blue); }
.st.cur span { font-weight: 700; }
.st.gap { margin-left: 6px; }
.confirm { margin-top: 8px; padding: 10px; border-radius: 8px; background: var(--amber-soft); }
.confirm .row { margin-top: 8px; }
.sec { margin-top: 14px; }
.sec-h { font-size: 12px; color: var(--muted); margin: 0 0 6px; display: flex; justify-content: space-between; align-items: baseline; }
.auto { font-size: 11px; color: var(--blue); }
textarea#letter { height: 240px; line-height: 1.55; font-size: 15px; resize: vertical; }
.actions { display: flex; gap: 8px; margin-top: 10px; } .actions .btn { flex: 1; }
.hint { display: flex; gap: 10px; align-items: center; margin-top: 12px; padding: 10px; background: var(--sky); border-radius: 8px;
        font-size: 12px; color: var(--navy); line-height: 1.5; }
.hint img { width: 56px; flex: none; }
.mock { display: block; margin-top: 8px; font-size: 13px; color: var(--blue); }
.back { background: none; border: 0; color: var(--blue); font-size: 15px; padding: 4px 0 10px; cursor: pointer; font-family: inherit; }
.done-box { text-align: center; }
.done-box img { width: 220px; max-width: 70%; }
.done-box .t { font-size: 18px; font-weight: 700; color: var(--navy); margin: 6px 0 4px; }
.done-box .s { color: var(--muted); white-space: pre-line; line-height: 1.6; }
.tabbar { position: fixed; left: 0; right: 0; bottom: 0; display: flex; background: #fff; border-top: 1px solid var(--line);
          padding: 6px 0 calc(6px + env(safe-area-inset-bottom)); z-index: 10; }
.tabbar button { flex: 1; border: 0; background: none; font-family: inherit; font-size: 12px; color: var(--muted); cursor: pointer; padding: 4px 0; }
.tabbar button b { display: block; font-size: 20px; line-height: 1.2; }
.tabbar button.on { color: var(--navy); font-weight: 700; }
table.res { border-collapse: collapse; width: 100%; font-size: 13px; background: #fff; }
table.res td, table.res th { border: 1px solid var(--line); padding: 5px 6px; vertical-align: top; text-align: left; }
@media (min-width: 900px) { .wrap { max-width: 720px; } }
#msg { position: fixed; left: 12px; right: 12px; bottom: calc(72px + env(safe-area-inset-bottom)); max-width: 616px; margin: 0 auto;
       z-index: 20; box-shadow: 0 4px 16px rgba(10,50,116,.18); }
