:root {
  --nav:#12263f;
  --nav2:#193653;
  --bg:#edf2f9;
  --card:#fff;
  --line:#d9e2ef;
  --text:#1c2b3a;
  --muted:#6c7d90;
  --blue:#2864dc;
  --blue-dark:#194ca8;
  --blue-soft:#eef4ff;
  --yellow:#f3b51b;
  --green:#16855b;
  --red:#c43f4e;
  --radius:8px;
  --shadow:0 2px 8px rgba(0,0,0,.06);
}

* { box-sizing:border-box; }
html, body { margin:0; min-width:1180px; min-height:100%; font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","PingFang SC",sans-serif; color:var(--text); background:var(--bg); }
button, input, textarea, select { font:inherit; }
button:disabled, input:disabled, textarea:disabled, select:disabled { cursor:not-allowed; opacity:.62; }
button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible { outline:2px solid rgba(40,100,220,.3); outline-offset:2px; }

.status-bar { position:fixed; z-index:60; top:0; left:0; right:0; height:28px; border-bottom:1px solid #bcd0e7; background:#e8f0fe; color:#244e80; text-align:center; font-size:12px; line-height:28px; }
.sidebar { position:fixed; z-index:50; top:28px; bottom:0; left:0; width:240px; display:flex; flex-direction:column; background:var(--nav); color:#dce8f5; }
.brand { height:75px; display:flex; align-items:center; gap:10px; padding:0 18px; border-bottom:1px solid rgba(255,255,255,.09); }
.brand-mark { width:34px; height:34px; display:grid; place-items:center; border-radius:6px; background:var(--yellow); color:#17283c; font-weight:800; }
.brand strong, .brand small { display:block; }
.brand strong { font-size:17px; }
.brand small { margin-top:3px; color:#98adc3; font-size:12px; }
.nav-group { padding:15px 14px 4px; color:#7892aa; font-size:12px; text-transform:uppercase; letter-spacing:.1em; }
.nav-item { width:calc(100% - 16px); margin:2px 8px; padding:10px 14px; display:flex; align-items:center; gap:9px; border:0; border-radius:6px; background:transparent; color:#c7d7e7; text-align:left; cursor:pointer; text-decoration:none; font-size:14px; font-weight:500; box-sizing:border-box; }
.nav-item:hover { background:rgba(255,255,255,.07); }
.nav-item.active { background:#2a5275; color:#fff; box-shadow:inset 3px 0 var(--yellow); }
.nav-icon { width:18px; padding:1px; border:1px solid #718aa1; border-radius:4px; text-align:center; font-size:12px; }
.sidebar-foot { margin-top:auto; padding:14px 18px; border-top:1px solid rgba(255,255,255,.09); color:#9fb2c4; font-size:12px; }
.status-dot { width:7px; height:7px; margin-right:5px; display:inline-block; border-radius:50%; background:#42d392; }

.main { min-height:100vh; margin-left:240px; padding-top:28px; }
.topbar { position:sticky; z-index:20; top:28px; min-height:78px; padding:14px 24px; display:flex; align-items:center; justify-content:space-between; gap:18px; border-bottom:1px solid var(--line); background:#fff; box-shadow:0 3px 12px rgba(35,55,77,.04); }
.page-heading { min-width:190px; }
.eyebrow { margin:0 0 3px; color:#71849a; font-size:12px; letter-spacing:.04em; }
h1 { margin:0; color:#172a3d; font-size:22px; font-weight:700; line-height:1.2; }
.page-subtitle { margin:4px 0 0; color:#8492a3; font-size:13px; }
.top-actions, .toolbar { display:flex; align-items:center; gap:8px; }
#content { padding:20px 24px 24px; }

.embedded-tool-card { overflow:hidden; border:1px solid var(--line); border-radius:var(--radius); background:#fff; box-shadow:var(--shadow); }
.embedded-tool-note { min-height:52px; padding:9px 14px; display:flex; align-items:center; justify-content:space-between; gap:16px; border-bottom:1px solid var(--line); background:#f8fbff; }
.embedded-tool-note strong, .embedded-tool-note span { display:block; }
.embedded-tool-note strong { color:#20364d; font-size:14px; }
.embedded-tool-note div > span { margin-top:3px; color:var(--muted); font-size:13px; }
.embedded-tool-frame { width:100%; height:calc(100vh - 190px); min-height:720px; display:block; border:0; background:#edf2f9; }

.btn { min-height:34px; padding:8px 16px; border:1px solid #cbd7e5; border-radius:6px; background:#fff; color:#344b62; font-weight:600; font-size:13px; cursor:pointer; white-space:nowrap; }
.btn:hover { border-color:#8ba8c9; background:#f8fbff; }
.btn.primary { border-color:#1e54c8; background:#2a6df0; color:#fff; box-shadow:0 4px 10px rgba(40,100,220,.25); }
.btn.primary:hover { background:var(--blue-dark); }
.btn.danger { border-color:#e2b8be; color:#aa3342; }
.btn.small { min-height:28px; padding:5px 10px; font-size:12px; }
.btn.icon { min-width:28px; padding:4px; }

.version-strip { height:42px; padding:4px 7px; display:flex; align-items:center; gap:4px; border:1px solid #dce5ef; border-radius:7px; background:#f8fafc; }
.version-item { min-width:78px; padding:2px 9px; border-right:1px solid #e2e8f0; }
.version-item small, .version-item strong { display:block; }
.version-item small { color:#7d8da0; font-size:12px; }
.version-item strong { margin-top:2px; color:#253c55; font-size:13px; }
.save-indicator { padding:5px 8px; display:flex; align-items:center; gap:6px; border-radius:5px; font-size:12px; font-weight:650; }
.save-indicator i { width:7px; height:7px; border-radius:50%; background:currentColor; }
.save-indicator.dirty { background:#fff0e4; color:#a95717; }
.save-indicator.saved { background:#e9f7f1; color:#167251; }

.section-note { margin-bottom:14px; padding:12px 14px; border:1px solid #bcd0e7; border-radius:8px; background:#f5f9fe; color:#44617e; font-size:13px; }
.warning-note { border-color:#edd48a; background:#fff9e8; color:#735e1c; }
.grid { display:grid; gap:16px; }
.grid.metrics { grid-template-columns:repeat(4,1fr); }
.grid.two { grid-template-columns:repeat(2,minmax(0,1fr)); }
.card { border:1px solid var(--line); border-radius:var(--radius); background:var(--card); box-shadow:var(--shadow); }
.card-head { min-height:50px; padding:12px 18px; display:flex; align-items:center; justify-content:space-between; gap:10px; border-bottom:1px solid #e4eaf1; }
.card-head h2, .panel-heading h2 { margin:0; color:#20364d; font-size:16px; font-weight:700; }
.card-head small { display:block; margin-top:3px; color:#8492a3; font-size:13px; }
.card-body { padding:16px 18px; }
.metric { padding:16px; }
.metric small, .metric span { display:block; color:var(--muted); font-size:13px; }
.metric strong { display:block; margin:7px 0; font-size:25px; }
.trend-up { color:var(--green)!important; }
.level-guide { margin-bottom:12px; display:flex; align-items:center; gap:7px; color:#718398; font-size:13px; }
.level-step { padding:5px 8px; border:1px solid #d5dfeb; border-radius:5px; background:#fff; }
.level-step.active { border-color:#9ab8e9; background:#edf4ff; color:#2458ad; }
.level-arrow { color:#a2b0bf; }
.workspace { display:grid; grid-template-columns:260px minmax(520px,1fr) 340px; gap:16px; align-items:start; }
.workspace-column { min-height:470px; }
.module-tree, .component-list { display:flex; flex-direction:column; gap:7px; }
.module-node, .component-row { width:100%; padding:10px; display:grid; align-items:center; gap:9px; border:1px solid #e0e8f1; border-radius:8px; background:#fff; text-align:left; cursor:pointer; }
.module-node { grid-template-columns:28px 1fr auto; }
.component-row { grid-template-columns:1fr auto; }
.module-node:hover, .component-row:hover { border-color:#aabed6; }
.module-node.selected, .component-row.selected { border-color:#78a2e7; background:#f5f8ff; box-shadow:inset 3px 0 var(--blue); }
.tree-index { width:26px; height:26px; display:grid; place-items:center; flex:0 0 auto; border-radius:5px; background:#e8f0fb; color:#345d8b; font-size:12px; font-weight:700; }
.row-title { min-width:0; }
.row-title strong { display:block; overflow:hidden; color:#24364a; font-size:14px; text-overflow:ellipsis; white-space:nowrap; }
.row-title p { margin:3px 0 0; overflow:hidden; color:var(--muted); font-size:13px; text-overflow:ellipsis; white-space:nowrap; }
.count { color:#718398; font-size:13px; }
.component-actions { margin-top:4px; display:flex; gap:4px; }
.empty-state { padding:28px 16px; border:1px dashed #cbd7e5; border-radius:8px; color:var(--muted); text-align:center; font-size:14px; }

.home-editor-shell { min-width:1030px; }
.home-workspace-meta { min-height:40px; margin-bottom:10px; padding:8px 12px; display:flex; align-items:center; justify-content:space-between; gap:16px; border:1px solid #d8e2ee; border-radius:8px; background:#f8fafc; color:#718398; font-size:12px; }
.home-workspace-meta > div { display:flex; align-items:center; gap:7px; min-width:0; }
.home-workspace-meta strong { max-width:150px; overflow:hidden; color:#30485f; font-size:13px; text-overflow:ellipsis; white-space:nowrap; }
.home-workspace-meta i { color:#a6b3c1; font-style:normal; }
.level-kicker { padding:3px 6px; border-radius:4px; background:#e9f0f8; color:#667c93; font-size:12px; }
.home-editor-grid { height:930px; min-height:930px; display:grid; grid-template-columns:280px minmax(450px,1fr) 340px; gap:16px; align-items:stretch; }
.home-library, .home-properties { min-height:0; overflow:hidden; }
.panel-heading { height:52px; padding:10px 14px; display:flex; align-items:center; justify-content:space-between; gap:8px; border-bottom:1px solid #e2e9f1; }
.panel-heading > div { display:flex; align-items:center; gap:8px; }
.panel-index { width:24px; height:24px; display:grid; place-items:center; border-radius:5px; background:#e9f1fc; color:#2d63ac; font-size:12px; font-weight:800; }
.panel-description { margin:0; padding:10px 14px; border-bottom:1px solid #edf1f5; color:#75869a; font-size:13px; line-height:1.5; }
.home-tree-scroll { height:calc(100% - 93px); padding:10px; overflow:auto; background:#f8fafc; }
.home-tree-group { margin-bottom:8px; overflow:hidden; border:1px solid #dce5ef; border-radius:8px; background:#fff; }
.home-tree-group.selected { border-color:#9cb9e8; box-shadow:0 0 0 1px rgba(40,100,220,.08); }
.home-module-heading { width:100%; padding:8px; display:flex; align-items:center; gap:8px; border:0; border-bottom:1px solid transparent; background:#fff; text-align:left; cursor:pointer; }
.home-tree-group.selected .home-module-heading { border-bottom-color:#e4ebf5; background:#f3f7fd; }
.home-module-heading .row-title { flex:1; }
.home-component-thumbs { padding:7px; display:flex; flex-direction:column; gap:6px; }
.home-component-thumb { width:100%; min-height:54px; padding:6px; display:grid; grid-template-columns:66px minmax(0,1fr); align-items:center; gap:8px; border:1px solid transparent; border-radius:6px; background:#fff; text-align:left; cursor:pointer; }
.home-component-thumb:hover { border-color:#c7d6e7; background:#f9fbfd; }
.home-component-thumb.selected { border-color:#6f9ce3; background:#eef5ff; box-shadow:inset 3px 0 var(--blue); }
.thumb-copy { min-width:0; }
.thumb-copy strong, .thumb-copy small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.thumb-copy strong { color:#31475d; font-size:13px; }
.thumb-copy small { margin-top:4px; color:#8090a2; font-size:12px; }
.mini-visual { position:relative; width:66px; height:42px; display:block; overflow:hidden; border:1px solid #cbd9e8; border-radius:5px; background:#edf3fa; }
.mini-visual i, .mini-visual b, .mini-visual em { position:absolute; display:block; border-radius:2px; }
.mini-campaign i { inset:5px 31px 5px 5px; background:linear-gradient(145deg,#f6c86c,#e76d46); }
.mini-campaign span { position:absolute; top:8px; right:5px; width:23px; height:27px; }
.mini-campaign b { top:0; left:0; width:22px; height:5px; background:#7891aa; }
.mini-campaign em { top:10px; left:0; width:17px; height:4px; background:#b6c5d5; }
.mini-qr { background:#fff; }
.mini-qr i { top:5px; left:5px; width:31px; height:31px; background:repeating-linear-gradient(45deg,#29435e 0 3px,#fff 3px 6px); }
.mini-qr b { top:8px; right:6px; width:20px; height:5px; background:#68819b; }
.mini-qr em { top:19px; right:8px; width:18px; height:4px; background:#bdc9d5; }
.mini-hero { background:linear-gradient(135deg,#dce9fb 0 55%,#f5d773 55%); }
.mini-hero i { left:6px; top:9px; width:31px; height:4px; background:#355f8c; }
.mini-hero b { left:6px; top:17px; width:39px; height:3px; background:#8ba1b7; }
.mini-hero em { right:6px; bottom:5px; width:18px; height:18px; border-radius:50%; background:#fff; opacity:.7; }
.mini-tab { padding:8px 4px; display:grid; grid-template-columns:repeat(4,1fr); gap:3px; background:#fff; }
.mini-tab i { position:static; height:25px; background:linear-gradient(#e6effb 0 60%,#8facd1 60%); }
.mini-card { display:flex; align-items:center; gap:5px; padding:5px; background:#fff; }
.mini-card > i { position:static; width:26px; height:30px; background:linear-gradient(145deg,#aac8eb,#f1c85d); }
.mini-card > span { flex:1; }
.mini-card b, .mini-card em { position:static; height:3px; margin:4px 0; background:#5d7690; }
.mini-card em { width:70%; background:#b5c3d1; }
.mini-footer { background:#183651; }
.mini-footer i { left:7px; top:10px; width:31px; height:4px; background:#fff; }
.mini-footer b { left:7px; top:19px; width:45px; height:3px; background:#8da4ba; }
.mini-generic i { left:7px; top:7px; width:50px; height:16px; background:#bdd1e8; }
.mini-generic b { left:7px; bottom:10px; width:38px; height:3px; background:#6b86a1; }
.mini-generic em { left:7px; bottom:5px; width:48px; height:2px; background:#b4c2d0; }

.home-canvas-panel { min-width:450px; overflow:auto; border:1px solid #d4deea; border-radius:7px; background:radial-gradient(circle at 50% 18%,#f8fbff,#dfe8f3 62%,#d5e0eb); box-shadow:inset 0 0 45px rgba(57,83,111,.08); }
.device-stage { height:100%; padding:10px 20px; display:flex; flex-direction:column; align-items:center; }
.device-toolbar { width:420px; margin-bottom:8px; display:flex; justify-content:space-between; color:#687b90; font-size:12px; }
.device-toolbar span { display:flex; align-items:center; gap:5px; }
.canvas-status-dot { width:6px; height:6px; display:inline-block; border-radius:50%; background:#25a372; box-shadow:0 0 0 3px rgba(37,163,114,.12); }
.phone-frame { position:relative; width:390px; height:844px; overflow:hidden; border:8px solid #15283b; border-radius:30px; background:#f5f7fb; box-shadow:0 22px 45px rgba(22,39,57,.25),0 0 0 1px #516171; transition:.2s; }
.previewing .phone-frame { box-shadow:0 26px 55px rgba(21,45,76,.32),0 0 0 4px rgba(40,100,220,.2); transform:scale(1.012); }
.phone-frame::before { content:""; position:absolute; z-index:8; top:5px; left:50%; width:94px; height:20px; border-radius:0 0 13px 13px; background:#15283b; transform:translateX(-50%); }
.phone-status { position:absolute; z-index:7; top:0; left:0; right:0; height:31px; padding:9px 19px 0; display:flex; align-items:flex-start; color:#20364d; font-size:8px; font-weight:800; }
.phone-status span { margin-right:auto; }
.phone-status i, .phone-status b, .phone-status em { width:9px; height:6px; margin-left:3px; border:1px solid #20364d; border-radius:2px; }
.phone-status b { width:7px; border-top:0; border-radius:0; }
.phone-status em { width:12px; background:#20364d; }
.phone-scroll { height:100%; padding:31px 0 20px; overflow:auto; scrollbar-width:none; }
.phone-scroll::-webkit-scrollbar { display:none; }
.phone-block, .phone-tab, .phone-article, .phone-contact { position:relative; border:2px solid transparent; background:none; text-align:left; cursor:pointer; transition:border-color .12s,box-shadow .12s; }
.phone-campaign-card, .phone-campaign-extra, .phone-coupon-link, .phone-contact-block { position:relative; border:2px solid transparent; font:inherit; text-align:left; cursor:pointer; }
.phone-frame [data-canvas-component]:hover { border-color:#8fb3ec; }
.phone-frame [data-canvas-component].selected { z-index:2; border-color:#2768dd; box-shadow:0 0 0 3px rgba(39,104,221,.17); }
.phone-frame [data-canvas-component].selected::after { content:"当前选中"; position:absolute; z-index:8; top:-8px; right:-4px; padding:2px 5px; border-radius:3px; background:#2768dd; color:#fff; font-size:7px; white-space:nowrap; }
.phone-block:hover, .phone-tab:hover, .phone-article:hover, .phone-contact:hover { border-color:#8fb3ec; }
.phone-block.selected, .phone-tab.selected, .phone-article.selected, .phone-contact.selected { z-index:2; border-color:#2768dd; box-shadow:0 0 0 3px rgba(39,104,221,.17); }
.phone-block.selected::after, .phone-tab.selected::after, .phone-article.selected::after, .phone-contact.selected::after { content:"当前选中"; position:absolute; z-index:4; top:-8px; right:-4px; padding:2px 5px; border-radius:3px; background:#2768dd; color:#fff; font-size:7px; white-space:nowrap; }
.phone-block.disabled, .phone-tab.disabled, .phone-article.disabled, .phone-contact.disabled { opacity:.35; }
.phone-hero { width:calc(100% - 24px); min-height:154px; margin:8px 12px 10px; padding:17px 16px; overflow:hidden; border-radius:16px; background:linear-gradient(135deg,#153c6c,#2864ac 64%,#3a78bd); color:#fff; }
.phone-brand { display:flex; align-items:center; gap:5px; color:#dcecff; font-size:9px; }
.phone-brand i { width:19px; height:19px; display:grid; place-items:center; border-radius:6px; background:#f4c64d; color:#163555; font-style:normal; font-weight:900; }
.phone-badge { position:absolute; top:17px; right:15px; padding:3px 6px; border:1px solid rgba(255,255,255,.28); border-radius:99px; color:#d9e9fb; font-size:7px; }
.phone-hero > strong { position:relative; z-index:2; width:210px; margin-top:16px; display:block; font-size:20px; line-height:1.25; }
.phone-hero > p { position:relative; z-index:2; width:230px; margin:8px 0 0; color:#cbdff4; font-size:9px; line-height:1.5; }
.hero-art { position:absolute; right:-6px; bottom:-8px; width:116px; height:91px; }
.hero-art i { position:absolute; right:8px; bottom:4px; width:73px; height:73px; border-radius:50%; background:rgba(245,198,77,.95); }
.hero-art b { position:absolute; right:48px; bottom:18px; width:50px; height:56px; border-radius:15px 15px 8px 8px; background:#fff; transform:rotate(-8deg); }
.hero-art em { position:absolute; right:14px; bottom:20px; width:43px; height:48px; border-radius:8px; background:#dbeaff; transform:rotate(10deg); }
.phone-tabs { margin:0 12px 14px; padding:4px; display:grid; grid-template-columns:repeat(4,1fr); gap:3px; border-radius:12px; background:#fff; box-shadow:0 4px 13px rgba(39,65,93,.08); }
.phone-tab { min-width:0; padding:9px 2px 7px; border-radius:9px; text-align:center; color:#526980; }
.phone-tab:first-child { background:#eaf2ff; color:#1e59b0; }
.phone-tab span, .phone-tab small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.phone-tab span { font-size:8px; font-weight:800; }
.phone-tab small { margin-top:3px; color:#8b9aab; font-size:6px; }
.phone-section-title { margin:0 14px 8px; display:flex; align-items:flex-end; justify-content:space-between; }
.phone-section-title small, .phone-section-title strong { display:block; }
.phone-section-title small { margin-bottom:2px; color:#8796a7; font-size:7px; }
.phone-section-title strong { color:#20364d; font-size:13px; }
.phone-section-title > span { color:#3570c5; font-size:7px; }
.phone-article-grid { margin:0 12px 14px; display:grid; grid-template-columns:repeat(2,1fr); gap:8px; }
.phone-article { min-width:0; padding:0 0 9px; overflow:hidden; border-radius:11px; background:#fff; box-shadow:0 3px 12px rgba(38,62,89,.08); }
.article-cover { position:relative; height:82px; display:block; overflow:hidden; background:linear-gradient(145deg,#a9c8ec,#e1edf9); }
.article-cover.cover-1 { background:linear-gradient(145deg,#f3d486,#fff1c9); }
.article-cover.cover-2 { background:linear-gradient(145deg,#9ed3cb,#dff3ec); }
.article-cover.cover-3 { background:linear-gradient(145deg,#b5b9e8,#e8e8fa); }
.article-cover i { position:absolute; z-index:2; top:7px; left:7px; padding:3px 5px; border-radius:4px; background:rgba(255,255,255,.9); color:#315276; font-size:6px; font-style:normal; font-weight:800; }
.article-cover b { position:absolute; right:18px; bottom:-10px; width:75px; height:75px; border:14px solid rgba(255,255,255,.55); border-radius:50%; }
.article-cover em { position:absolute; right:8px; bottom:10px; width:42px; height:28px; border-radius:6px; background:rgba(255,255,255,.75); transform:rotate(-8deg); }
.phone-article > strong { height:31px; margin:8px 8px 0; display:block; overflow:hidden; color:#263d54; font-size:9px; line-height:1.55; }
.phone-article > p { height:23px; margin:4px 8px 0; overflow:hidden; color:#8492a2; font-size:7px; line-height:1.55; }
.article-link { margin:6px 8px 0; display:flex; justify-content:space-between; color:#2d65b5; font-size:7px; }
.article-link i { font-style:normal; font-size:11px; line-height:7px; }
.phone-contact { width:calc(100% - 24px); margin:0 12px 10px; padding:11px; display:grid; grid-template-columns:34px 1fr auto; align-items:center; gap:9px; border-radius:11px; background:#173653; color:#fff; }
.contact-mark { width:32px; height:32px; display:grid; place-items:center; border-radius:9px; background:#f1c64f; color:#173653; font-size:11px; font-weight:900; }
.phone-contact strong, .phone-contact small { display:block; }
.phone-contact strong { font-size:9px; }
.phone-contact small { margin-top:4px; color:#adc2d5; font-size:7px; }
.phone-contact > i { color:#e5eef7; font-size:15px; font-style:normal; }
.phone-legal { color:#a0acb8; text-align:center; font-size:6px; }
.canvas-tip { margin:8px 0 0; color:#6e8195; font-size:13px; }

.campaign-hero { width:calc(100% - 24px); min-height:142px; margin:8px 12px 12px; padding:17px; overflow:hidden; border-radius:18px; color:#fff; }
.campaign-hero.jd { background:linear-gradient(135deg,#d82d33,#f05b37); }
.campaign-hero.meituan { background:linear-gradient(135deg,#f3a700,#ffd33c); color:#3c2b00; }
.campaign-hero.taobao { background:linear-gradient(135deg,#ff5d26,#ff8b28); }
.campaign-brand { position:relative; z-index:2; font-size:8px; font-weight:800; letter-spacing:.08em; }
.campaign-hero strong { position:relative; z-index:2; margin-top:18px; display:block; font-size:20px; }
.campaign-hero p { position:relative; z-index:2; width:220px; margin:7px 0 0; font-size:9px; line-height:1.5; opacity:.85; }
.campaign-orbit i, .campaign-orbit b { position:absolute; display:block; border-radius:50%; background:rgba(255,255,255,.24); }
.campaign-orbit i { width:105px; height:105px; right:-18px; bottom:-23px; border:22px solid rgba(255,255,255,.22); background:transparent; }
.campaign-orbit b { width:49px; height:49px; right:30px; bottom:25px; }
.phone-category-row { margin:-3px 12px 14px; padding:10px 8px; display:grid; grid-template-columns:repeat(4,1fr); gap:5px; border-radius:12px; background:#fff; box-shadow:0 4px 13px rgba(39,65,93,.08); }
.phone-category-row span { padding-top:25px; position:relative; color:#596b7d; text-align:center; font-size:8px; font-weight:700; }
.phone-category-row span::before { content:""; position:absolute; top:1px; left:50%; width:21px; height:21px; border-radius:8px; background:#ffe1d7; transform:translateX(-50%); }
.phone-campaign-list, .phone-extra-list { margin:0 12px 12px; display:flex; flex-direction:column; gap:8px; }
.phone-campaign-card { min-height:92px; padding:8px; display:grid; grid-template-columns:104px 1fr; gap:10px; border-radius:13px; background:#fff; box-shadow:0 3px 12px rgba(38,62,89,.08); }
.campaign-card-art { position:relative; min-height:72px; overflow:hidden; border-radius:9px; background:linear-gradient(145deg,#f4b3a6,#ffe2c5); }
.campaign-card-art.art-1 { background:linear-gradient(145deg,#f5d36f,#fff0b6); }
.campaign-card-art.art-2 { background:linear-gradient(145deg,#b9dcb7,#e8f5cc); }
.campaign-card-art::after { content:""; position:absolute; width:58px; height:58px; right:-8px; bottom:-13px; border:13px solid rgba(255,255,255,.6); border-radius:50%; }
.campaign-card-art i { position:absolute; z-index:2; top:6px; left:6px; padding:3px 5px; border-radius:5px; background:#fff; color:#a14635; font-size:7px; font-style:normal; }
.phone-campaign-card > span:last-child { min-width:0; }
.phone-campaign-card strong, .phone-campaign-card small { display:block; }
.phone-campaign-card strong { margin-top:3px; color:#293d50; font-size:10px; }
.phone-campaign-card small { height:25px; margin-top:6px; overflow:hidden; color:#7c8c9b; font-size:7px; line-height:1.7; }
.phone-campaign-card em, .phone-campaign-extra em { margin-top:7px; display:inline-block; padding:4px 8px; border-radius:99px; background:#e94b35; color:#fff; font-size:7px; font-style:normal; }
.phone-campaign-card.meituan em { background:#f0ad00; color:#3b2d00; }
.phone-campaign-card.taobao em { background:#ff6429; }
.phone-campaign-extra, .phone-coupon-link { width:100%; padding:11px; display:flex; align-items:center; justify-content:space-between; gap:9px; border-radius:11px; background:#fff; box-shadow:0 3px 12px rgba(38,62,89,.07); }
.phone-campaign-extra strong, .phone-campaign-extra small, .phone-coupon-link strong, .phone-coupon-link small { display:block; }
.phone-campaign-extra strong, .phone-coupon-link strong { font-size:9px; }
.phone-campaign-extra small, .phone-coupon-link small { margin-top:4px; color:#8190a0; font-size:7px; }

.coupon-hero { min-height:116px; background:linear-gradient(135deg,#244a72,#3778a8); }
.coupon-frozen-card { margin:0 12px 10px; padding:12px; border:1px solid #e4e9ef; border-radius:13px; background:#fff; box-shadow:0 3px 12px rgba(38,62,89,.07); }
.coupon-frozen-card label, .coupon-frozen-card h3 { margin:0 0 8px; display:block; color:#30475e; font-size:10px; font-weight:800; }
.coupon-search { display:grid; grid-template-columns:1fr 58px; gap:6px; }
.coupon-search input { min-width:0; padding:8px; border:1px solid #d5dee8; border-radius:7px; color:#8492a0; font-size:7px; }
.coupon-search button, .coupon-result button, .coupon-entry-pair button { border:0; border-radius:7px; background:#d9e2eb; color:#7b8997; font-size:7px; }
.coupon-result { margin-top:9px; padding:9px; display:grid; grid-template-columns:31px 1fr 44px; align-items:center; gap:7px; border-radius:9px; background:#f5f7f9; }
.merchant-logo { width:31px; height:31px; display:grid; place-items:center; border-radius:8px; background:#f0b84a; color:#fff; font-size:10px; font-weight:800; }
.coupon-result strong, .coupon-result small { display:block; }
.coupon-result strong { font-size:8px; }
.coupon-result small { margin-top:3px; color:#8794a1; font-size:6px; }
.coupon-entry-pair { display:grid; grid-template-columns:1fr 1fr; gap:7px; }
.coupon-entry-pair button { min-height:39px; }
.cashback { margin-top:9px; padding:10px; border-radius:9px; background:#fff4e7; }
.cashback span, .cashback strong, .cashback small { display:block; }
.cashback span { color:#a36a27; font-size:7px; }
.cashback strong { margin-top:4px; color:#c15c22; font-size:12px; }
.cashback small { margin-top:3px; color:#a08b77; font-size:6px; }
.phone-coupon-link em { padding:4px 7px; border-radius:99px; background:#e8f0f9; color:#315d8b; font-size:7px; font-style:normal; }
.phone-coupon-link.packet { border-left:4px solid #ef9b36; }
.coupon-readonly-note { margin-bottom:9px; padding:8px; border:1px solid #efd896; border-radius:6px; background:#fff8df; color:#78601b; font-size:8px; line-height:1.5; }

.contact-page-head { margin:8px 12px 12px; padding:19px 16px; border-radius:18px; background:linear-gradient(135deg,#183b59,#286a75); color:#fff; }
.contact-page-head span { font-size:8px; color:#b9d9dc; }
.contact-page-head strong { margin-top:12px; display:block; font-size:21px; }
.contact-page-head p { margin:7px 0 0; color:#c6dce0; font-size:8px; }
.contact-block-list { margin:0 12px 12px; display:flex; flex-direction:column; gap:9px; }
.phone-contact-block { width:100%; padding:11px; display:grid; grid-template-columns:78px 1fr; gap:12px; align-items:center; border-radius:13px; background:#fff; box-shadow:0 3px 12px rgba(38,62,89,.08); }

.phone-contact-block small, .phone-contact-block strong, .phone-contact-block p { display:block; }
.phone-contact-block small { color:#698094; font-size:7px; }
.phone-contact-block strong { margin-top:5px; color:#243c52; font-size:11px; }
.phone-contact-block p { margin:5px 0; color:#81909e; font-size:7px; line-height:1.55; }
.phone-contact-block > span:last-child > em { padding:3px 6px; border-radius:99px; background:#e8f2f1; color:#38726f; font-size:7px; font-style:normal; }

.home-properties { display:flex; flex-direction:column; }
.property-heading { flex:0 0 52px; }
.selected-summary { margin:10px 12px 0; padding:8px; display:grid; grid-template-columns:66px minmax(0,1fr); align-items:center; gap:9px; border:1px solid #d9e5f2; border-radius:7px; background:#f5f9fe; }
.selected-summary div { min-width:0; }
.selected-summary small, .selected-summary strong, .selected-summary span { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.selected-summary small { color:#74879c; font-size:8px; }
.selected-summary strong { margin-top:3px; color:#25415e; font-size:11px; }
.selected-summary span { margin-top:3px; color:#8d9bab; font-size:7px; }
.home-properties > .card-body { padding:11px 12px 14px; overflow:auto; }
.home-properties .editor-grid { grid-template-columns:repeat(2,minmax(0,1fr)); column-gap:9px; }
.home-properties .form-field { margin-bottom:9px; }
.home-properties textarea { min-height:58px; }
.home-properties .editor-footer { align-items:flex-start; flex-direction:column; gap:9px; }
.home-properties .editor-footer .toolbar { width:100%; justify-content:flex-end; flex-wrap:wrap; }

.pill { display:inline-block; padding:3px 8px; border-radius:999px; background:#eaf1fb; color:#3d5e80; font-size:12px; white-space:nowrap; }
.pill.green { background:#e8f7f1; color:#18704f; }
.pill.yellow { background:#fff4cf; color:#785b00; }
.pill.gray { background:#edf0f3; color:#6a7784; }
.pill.red { background:#fae9eb; color:#a62f3e; }
.editor-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); column-gap:16px; }
.form-field { margin-bottom:12px; }
.form-field.full { grid-column:1/-1; }
.form-field label { display:block; margin-bottom:5px; color:#42566d; font-size:14px; font-weight:650; }
.field-help { margin:5px 0 0; color:#7b8b9d; font-size:13px; }
.input, textarea, select { width:100%; padding:8px 10px; border:1px solid #cbd7e5; border-radius:6px; background:#fff; color:var(--text); font-size:14px; }
textarea { min-height:72px; resize:vertical; }
.input[readonly], textarea[readonly] { background:#f2f5f8; color:#66778a; }
.switch-row { grid-column:1/-1; padding:7px 0 10px; display:flex; align-items:center; justify-content:space-between; border-bottom:1px solid #edf1f6; }
.switch-row strong { font-size:14px; }
.switch { position:relative; width:38px; height:21px; }
.switch input { width:0; height:0; opacity:0; }
.slider { position:absolute; inset:0; border-radius:99px; background:#b9c6d3; cursor:pointer; }
.slider::before { content:""; position:absolute; top:3px; left:3px; width:15px; height:15px; border-radius:50%; background:#fff; transition:.15s; }
.switch input:checked + .slider { background:var(--blue); }
.switch input:checked + .slider::before { transform:translateX(17px); }
.image-control { display:grid; grid-template-columns:1fr auto; gap:7px; }
.image-preview { grid-column:1/-1; height:70px; display:flex; align-items:center; justify-content:center; overflow:hidden; border:1px dashed #b9c9da; border-radius:6px; background:linear-gradient(145deg,#e7eff9,#f7e4a8); color:#4c6278; text-align:center; font-size:13px; }
.image-preview img { width:100%; height:100%; object-fit:cover; }
.editor-footer { grid-column:1/-1; margin-top:4px; padding-top:11px; display:flex; align-items:center; justify-content:space-between; border-top:1px solid #e7edf5; }
.draft-state { color:#718398; font-size:13px; }

.locked-list { display:flex; flex-direction:column; gap:8px; }
.locked-row { padding:10px; display:grid; grid-template-columns:1fr auto; gap:8px; border:1px solid #dfe6ef; border-radius:6px; background:#f7f9fb; }
.locked-row strong { font-size:14px; }
.locked-row p { margin:4px 0 0; color:var(--muted); font-size:13px; }
.status-table { width:100%; border-collapse:collapse; font-size:14px; }
.status-table th, .status-table td { padding:9px; border-bottom:1px solid #e5ebf3; text-align:left; min-height:40px; }
.status-table th { background:#f8fafc; color:#617286; font-weight:600; font-size:13px; }
.asset-grid { display:grid; grid-template-columns:repeat(4,1fr); gap:10px; }
.asset { overflow:hidden; border:1px solid #dce4ed; border-radius:6px; }
.asset-image { height:92px; display:grid; place-items:center; background:linear-gradient(145deg,#d9e8fb,#f5cf69); color:#425b72; font-size:13px; }
.asset-meta { padding:8px; font-size:13px; }
.diff { padding:12px; border-radius:8px; background:#172737; color:#cfe0ed; font:13px/1.65 ui-monospace,monospace; }
.plus { color:#75d9a8; }
.minus { color:#ff9a9f; }
.empty-chart { height:170px; padding:14px; display:flex; align-items:flex-end; gap:8px; }
.bar { min-height:20px; flex:1; border-radius:4px 4px 0 0; background:#7da8e9; }

/* Loading & Error states */
.loading-state { display:flex; flex-direction:column; align-items:center; justify-content:center; min-height:300px; gap:16px; color:var(--muted); font-size:13px; }
.spinner { width:36px; height:36px; border:3px solid #dbe5f0; border-top-color:var(--blue); border-radius:50%; animation:spin .8s linear infinite; }
@keyframes spin { to { transform:rotate(360deg); } }
.error-state { padding:32px; display:flex; flex-direction:column; align-items:center; gap:12px; min-height:200px; justify-content:center; }
.error-state strong { color:var(--red); font-size:16px; }
.error-state p { margin:0; color:var(--muted); font-size:13px; max-width:420px; text-align:center; }
.conflict-banner { margin-bottom:12px; padding:10px 14px; border:1px solid #f0d57d; border-radius:8px; background:#fff9e8; color:#745500; font-size:13px; }
.toast { position:fixed; z-index:100; right:20px; bottom:20px; padding:10px 14px; border-radius:6px; background:#1c2c3c; color:#fff; font-size:13px; opacity:0; pointer-events:none; transform:translateY(10px); transition:.2s; }
.toast.show { opacity:1; transform:none; }
/* Ensure status-bar replaces prototype-bar positioning */
.main { padding-top:28px; }
.topbar { top:28px; }
.sidebar { top:28px; }

/* ═══════════════════════════════════════════════════════════════
 *  v2 additions: real page header, bottom nav, tab switcher, lightbox
 * ═══════════════════════════════════════════════════════════════ */

/* Brand header in phone canvas */
.phone-brand-header {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 14px; background: #fff;
  border-bottom: 1px solid #ececec;
}
.phone-brand-header img.brand-logo-img, .phone-brand-header .brand-logo-fallback {
  width: 28px; height: 28px; border-radius: 6px; object-fit: cover;
  background: linear-gradient(135deg, #f5c64d, #e8a520);
  display: grid; place-items: center; color: #fff; font-weight: 900; font-size: 14px;
}
.phone-brand-header .brand-text { display: flex; flex-direction: column; }
.phone-brand-header .brand-text strong { font-size: 13px; color: #1c2b3a; }
.phone-brand-header .brand-text small { font-size: 9px; color: #8492a3; }

/* Bottom 5-tab nav in phone canvas */
.phone-bottom-nav {
  position: absolute; bottom: 0; left: 0; right: 0;
  height: 56px; display: flex; align-items: center; justify-content: space-around;
  background: #fff; border-top: 1px solid #e8e8e8;
  box-shadow: 0 -2px 8px rgba(0,0,0,.04);
}
.phone-bottom-nav .nav-item-mini {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  color: #8492a3; font-size: 8px; cursor: pointer; flex: 1; text-align: center;
}
.phone-bottom-nav .nav-item-mini.active { color: var(--blue); }
.phone-bottom-nav .nav-item-mini .nav-icon-mini {
  width: 20px; height: 20px; display: grid; place-items: center; border-radius: 5px;
  font-size: 11px;
}
.phone-bottom-nav .nav-item-mini.center .nav-icon-mini {
  width: 36px; height: 36px; border-radius: 50%; background: var(--blue); color: #fff;
  margin-top: -10px; box-shadow: 0 2px 8px rgba(40,100,220,.3);
}

/* Home tab bar in canvas */
.phone-tab-bar {
  margin: 0 12px 10px; padding: 4px; display: grid;
  grid-template-columns: repeat(4, 1fr); gap: 3px;
  border-radius: 12px; background: #fff; box-shadow: 0 2px 10px rgba(0,0,0,.06);
}
.phone-tab-bar .canvas-tab {
  padding: 8px 2px; border-radius: 9px; text-align: center;
  font-size: 8px; font-weight: 700; color: #526980; cursor: pointer;
  border: 2px solid transparent; transition: border-color .12s;
}
.phone-tab-bar .canvas-tab.active {
  background: #eaf2ff; color: #1e59b0; border-color: transparent;
}
.phone-tab-bar .canvas-tab:hover { border-color: #8fb3ec; }
.phone-tab-bar .canvas-tab.selected { border-color: #2768dd; box-shadow: 0 0 0 3px rgba(39,104,221,.17); }
.phone-tab-bar .canvas-tab.selected::after {
  content: "选中"; position: absolute; margin-top: -20px; font-size: 7px;
  padding: 1px 4px; border-radius: 3px; background: #2768dd; color: #fff;
}

/* Channel panel */
.phone-channel-panel { margin: 0 12px 10px; }
.phone-channel-panel .channel-title { font-size: 14px; font-weight: 700; color: #20364d; margin-bottom: 8px; }

/* Article card in canvas */
.phone-article-card {
  display: flex; gap: 10px; padding: 10px; border-radius: 12px;
  background: #fff; box-shadow: 0 2px 10px rgba(0,0,0,.05);
  border: 2px solid transparent; cursor: pointer; transition: border-color .12s;
}
.phone-article-card:hover { border-color: #8fb3ec; }
.phone-article-card.selected { border-color: #2768dd; box-shadow: 0 0 0 3px rgba(39,104,221,.17); }
.phone-article-card.selected::after {
  content: "选中"; position: absolute; z-index: 8; top: -8px; right: -4px;
  padding: 2px 5px; border-radius: 3px; background: #2768dd; color: #fff; font-size: 7px;
}
.phone-article-card { position: relative; }
.phone-article-card .card-cover {
  width: 64px; height: 64px; border-radius: 8px; flex-shrink: 0;
  display: grid; place-items: center; font-size: 7px;
}
.phone-article-card .card-cover svg-placeholder {
  width: 100%; height: 100%; border-radius: 8px;
}
.phone-article-card .card-body-mini { flex: 1; min-width: 0; }
.phone-article-card .card-body-mini strong { font-size: 10px; color: #263d54; display: block; }
.phone-article-card .card-body-mini p { margin: 4px 0 0; font-size: 7px; color: #8492a3; line-height: 1.5; }
.phone-article-card .card-tags { display: flex; gap: 4px; margin-top: 6px; }
.phone-article-card .card-tag {
  padding: 2px 5px; border-radius: 4px; font-size: 6px; font-weight: 700;
}
.phone-article-card .card-tag.primary { background: #eef4ff; color: #2864dc; }
.phone-article-card .card-tag.secondary { background: #f0f3f7; color: #6c7d90; }

/* Campaign card for jd/meituan/taobao */
.phone-campaign-card-v2 {
  position: relative; display: flex; gap: 10px; padding: 10px;
  border-radius: 13px; background: #fff; box-shadow: 0 2px 10px rgba(0,0,0,.05);
  border: 2px solid transparent; cursor: pointer; transition: border-color .12s;
  margin-bottom: 8px;
}
.phone-campaign-card-v2:hover { border-color: #8fb3ec; }
.phone-campaign-card-v2.selected { border-color: #2768dd; box-shadow: 0 0 0 3px rgba(39,104,221,.17); }
.phone-campaign-card-v2.selected::after {
  content: "选中"; position: absolute; z-index: 8; top: -8px; right: -4px;
  padding: 2px 5px; border-radius: 3px; background: #2768dd; color: #fff; font-size: 7px;
}
.phone-campaign-card-v2 .card-cover {
  width: 80px; height: 80px; border-radius: 9px; flex-shrink: 0;
  display: grid; place-items: center; overflow: hidden;
}
.phone-campaign-card-v2 .card-cover img-placeholder {
  width: 100%; height: 100%;
}
.phone-campaign-card-v2 .card-body-v2 { flex: 1; min-width: 0; }
.phone-campaign-card-v2 .card-body-v2 strong { font-size: 11px; color: #293d50; display: block; }
.phone-campaign-card-v2 .card-body-v2 p { margin: 5px 0 0; font-size: 8px; color: #7c8c9b; line-height: 1.5; }
.phone-campaign-card-v2 .card-tags { display: flex; gap: 4px; margin-top: 6px; flex-wrap: wrap; }
.phone-campaign-card-v2 .card-tag {
  padding: 2px 6px; border-radius: 4px; font-size: 7px; font-weight: 700;
}
.phone-campaign-card-v2 .card-tag.primary { background: #eef4ff; color: #2864dc; }
.phone-campaign-card-v2 .card-tag.secondary { background: #f0f3f7; color: #6c7d90; }
.phone-campaign-card-v2.unclickable { opacity: .95; }
.phone-campaign-card-v2.unclickable .card-tag.primary { background: #f0f3f7; color: #8492a3; }
.phone-campaign-card-v2.clickable::before {
  content: "可点击"; position: absolute; top: 4px; right: 4px;
  font-size: 6px; color: #16855b; font-weight: 700;
}
.phone-campaign-card-v2.unclickable::before {
  content: "纯展示"; position: absolute; top: 4px; right: 4px;
  font-size: 6px; color: #8492a3; font-weight: 700;
}

/* Coupon canvas v2 */
.phone-coupon-page {
  padding: 0 12px;
}
.phone-coupon-header {
  text-align: center; padding: 20px 16px;
}
.phone-coupon-header .eyebrow { font-size: 7px; color: #8492a3; letter-spacing: .1em; }
.phone-coupon-header h2 { margin: 8px 0 4px; font-size: 18px; color: #1c2b3a; }
.phone-coupon-header p { margin: 0; font-size: 9px; color: #6c7d90; line-height: 1.5; }
.phone-coupon-input-area {
  margin: 12px 0; padding: 14px; border-radius: 12px; background: #fff;
  box-shadow: 0 2px 10px rgba(0,0,0,.04);
}
.phone-coupon-input-area label { font-size: 9px; color: #526980; font-weight: 700; }
.phone-coupon-input-area .hint { font-size: 7px; color: #8492a3; margin: 4px 0 8px; }
.phone-coupon-input-area textarea {
  width: 100%; min-height: 50px; border: 1px solid #e0e8f1; border-radius: 8px;
  padding: 8px; font-size: 8px; color: #b0bcc8; background: #f8fafc;
}
.phone-coupon-input-area .btn-row { display: flex; gap: 6px; margin-top: 8px; }
.phone-coupon-input-area .btn-row .mini-btn {
  padding: 6px 10px; border-radius: 7px; font-size: 7px; font-weight: 700;
  border: 1px solid #d5dee8; background: #fff; color: #526980;
}
.phone-coupon-input-area .btn-row .mini-btn.primary { background: var(--blue); color: #fff; border-color: var(--blue); }

/* Coupon readonly core area */
.coupon-readonly-core {
  margin: 10px 0; padding: 10px; border: 1px dashed #cbd7e5; border-radius: 10px;
  background: #f8fafc; text-align: center;
}
.coupon-readonly-core label { font-size: 8px; color: #8492a3; font-weight: 700; }
.coupon-readonly-core .core-items { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.coupon-readonly-core .core-items span {
  padding: 2px 6px; border-radius: 4px; background: #e8edf3; color: #6c7d90; font-size: 7px;
}

/* Contact page canvas */
.phone-contact-page { padding: 0 12px; }
.phone-contact-head {
  padding: 20px 16px; border-radius: 18px;
  background: linear-gradient(135deg,#183b59,#286a75);
  color: #fff; text-align: center; margin-bottom: 12px;
}
.phone-contact-head strong { display: block; font-size: 18px; margin-top: 8px; }
.phone-contact-head p { margin: 6px 0 0; font-size: 9px; color: #c6dce0; }

.phone-qr-card {
  position: relative; display: flex; gap: 12px; align-items: center;
  padding: 12px; border-radius: 13px; background: #fff;
  box-shadow: 0 2px 10px rgba(0,0,0,.05); margin-bottom: 8px;
  border: 2px solid transparent; cursor: pointer; transition: border-color .12s;
}
.phone-qr-card:hover { border-color: #8fb3ec; }
.phone-qr-card.selected { border-color: #2768dd; box-shadow: 0 0 0 3px rgba(39,104,221,.17); }
.phone-qr-card.selected::after {
  content: "选中"; position: absolute; z-index: 8; top: -8px; right: -4px;
  padding: 2px 5px; border-radius: 3px; background: #2768dd; color: #fff; font-size: 7px;
}
.phone-qr-card .qr-image {
  width: 70px; height: 70px; border: 3px solid #fff; outline: 1px solid #d8e0e8;
  border-radius: 6px; background: #f8fafc;
  display: grid; place-items: center; flex-shrink: 0; overflow: hidden;
}
.phone-qr-card .qr-image .qr-img {
  width: 100%; height: 100%; object-fit: contain;
}
.phone-qr-card .qr-image .qr-load-fail {
  font-size: 6px; color: #c43f4e; text-align: center; line-height: 1.3;
}
.phone-qr-card .qr-body { flex: 1; min-width: 0; }
.phone-qr-card .qr-body .tag-pill {
  display: inline-block; padding: 2px 6px; border-radius: 4px; font-size: 7px; font-weight: 700;
}
.phone-qr-card .qr-body .tag-pill.green { background: #e8f7f1; color: #16855b; }
.phone-qr-card .qr-body .tag-pill.amber { background: #fff4cf; color: #785b00; }
.phone-qr-card .qr-body .tag-pill.blue { background: #eaf1fb; color: #2864dc; }
.phone-qr-card .qr-body strong { display: block; font-size: 11px; color: #243c52; margin: 4px 0; }
.phone-qr-card .qr-body p { margin: 0; font-size: 8px; color: #81909e; line-height: 1.5; }

.phone-contact-tip {
  text-align: center; padding: 8px; font-size: 8px; color: #8492a3;
  border-top: 1px solid #ececec; margin-top: 4px;
}

/* Lightbox indicator */
.phone-lightbox-indicator {
  display: flex; align-items: center; gap: 6px; padding: 8px 12px;
  border: 1px dashed #cbd7e5; border-radius: 8px; background: #f8fafc;
  font-size: 8px; color: #6c7d90; margin-bottom: 8px;
}
.phone-lightbox-indicator .lb-icon {
  width: 20px; height: 20px; display: grid; place-items: center;
  border-radius: 4px; background: #e8edf3; font-size: 10px;
}

/* Section title in canvas */
.phone-section-title-v2 {
  font-size: 15px; font-weight: 700; color: #20364d;
  padding: 12px 0 8px; margin: 0 12px;
  border-bottom: 1px solid #ececec; margin-bottom: 8px;
}

/* Home contact links */
.phone-contact-links {
  display: flex; gap: 8px; padding: 12px; margin: 0 12px 10px;
  border-radius: 12px; background: #f5f7fb;
}
.phone-contact-link-item {
  flex: 1; padding: 10px; border-radius: 9px; background: #fff;
  text-align: center; font-size: 9px; font-weight: 700; color: #526980;
  border: 2px solid transparent; cursor: pointer; transition: border-color .12s;
}
.phone-contact-link-item:hover { border-color: #8fb3ec; }
.phone-contact-link-item.selected { border-color: #2768dd; box-shadow: 0 0 0 3px rgba(39,104,221,.17); }
.phone-contact-link-item .link-icon {
  width: 28px; height: 28px; margin: 0 auto 6px; display: grid; place-items: center;
  border-radius: 8px; background: #eef4ff; color: var(--blue); font-size: 12px;
}

/* Footer contact bar */
.phone-footer-contact {
  display: flex; justify-content: space-around; padding: 10px 12px;
  margin: 0 12px 10px; border-radius: 12px; background: #173653;
}
.phone-footer-contact-item {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  color: #adc2d5; font-size: 8px; cursor: pointer;
  border: 2px solid transparent; border-radius: 8px; padding: 4px 8px;
  transition: border-color .12s;
}
.phone-footer-contact-item:hover { border-color: #8fb3ec; }
.phone-footer-contact-item.selected { border-color: #2768dd; box-shadow: 0 0 0 3px rgba(39,104,221,.17); }
.phone-footer-contact-item .fci-icon {
  width: 24px; height: 24px; display: grid; place-items: center;
  border-radius: 6px; background: rgba(255,255,255,.1); font-size: 11px;
}

/* ── 推客密码 iframe 嵌入 ── */
.tuikemima-frame-section { margin: 0; }
.tuikemima-iframe-wrap { padding: 0; }
.real-canvas-iframe {
  display: block;
  width: 390px;
  height: 844px;
  border: 0;
  border-radius: 0 0 24px 24px;
  background: #fff;
}
.canvas-selector-tree .row-title strong {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 11px;
  overflow-wrap: anywhere;
}
.tuikemima-iframe {
  width: 100%;
  height: calc(100vh - 220px);
  min-height: 700px;
  border: 0;
  display: block;
  background: #f8fafc;
}

.promo-login-card, .promo-subcard { margin-top: 14px; }
.link-config-card { max-width: 1080px; }
.compact-head { min-height: 44px; }
.compact-config-grid { display:flex; flex-direction:column; gap:16px; }
.compact-main-fields { display:flex; flex-direction:column; gap:10px; }
.compact-row { display:grid; grid-template-columns:minmax(0,1fr) 190px; gap:12px; align-items:start; }
.compact-p-row { grid-template-columns:220px; }
.compact-link-field textarea { min-height:72px; }
.compact-p-field { margin-bottom:0; }
.compact-side-actions { display:flex; flex-direction:column; gap:8px; }
.parse-inline-result { min-height:32px; padding:8px 10px; border:1px solid #d7e1ed; border-radius:8px; background:#f7fafe; color:#556a80; font-size:13px; line-height:1.5; }
.compact-footer { margin-top:0; }
.compact-test-card { padding:12px; border:1px solid #dce5ef; border-radius:6px; background:#f8fafc; }
.compact-test-grid { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:12px; align-items:end; }
.compact-test-actions { padding-bottom:12px; }
.compact-result-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:10px; margin-top:12px; }
.compact-result-grid.empty { grid-template-columns:1fr; }
.advanced-settings { border:1px solid #d6e0ec; border-radius:6px; background:#fff; }
.advanced-settings summary { padding:12px 14px; cursor:pointer; color:#284763; font-size:14px; font-weight:700; list-style:none; }
.advanced-settings summary::-webkit-details-marker { display:none; }
.advanced-settings-body { padding:0 14px 14px; display:flex; flex-direction:column; gap:14px; }
.promo-tabbar { display:flex; gap:8px; margin-bottom:14px; }
.promo-tab { min-height:34px; padding:8px 14px; border:1px solid #cbd7e5; border-radius:6px; background:#fff; color:#344b62; font-weight:600; font-size:13px; cursor:pointer; }
.promo-tab.active { border-color:var(--blue); background:var(--blue-soft); color:var(--blue-dark); }
.promo-grid { display:grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap:14px; }
.promo-grid .full-width { grid-column:1 / -1; }
.promo-form-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
.promo-status-grid, .promo-result-grid { display:grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap:12px; margin-top:14px; }
.masked-box { padding:12px; border:1px solid #dce5ef; border-radius:6px; background:#f8fafc; }
.masked-box strong { display:block; margin-bottom:6px; font-size:14px; color:#24364a; }
.masked-box p { margin:0; color:#617286; font-size:13px; line-height:1.6; }
.inline-actions { display:flex; gap:6px; flex-wrap:wrap; }
.selected-row { background:#f5f8ff; }

/* ═══════════════════════════════════════════════════════════════
 * Item 5: Enhanced property editor — navigation + batch edit
 * ═══════════════════════════════════════════════════════════════ */
.canvas-nav-bar { display:flex; align-items:center; justify-content:space-between; gap:8px; padding:8px 12px; border-bottom:1px solid #edf1f5; }
.canvas-nav-pos { font-size:13px; color:#526980; font-weight:600; }
.batch-edit-panel { margin-top:12px; padding:10px; border:1px solid #dce5ef; border-radius:6px; background:#f8fafc; }
.batch-edit-header { display:flex; align-items:center; justify-content:space-between; margin-bottom:8px; }
.batch-edit-header strong { font-size:14px; color:#24364a; }
.batch-edit-list { display:flex; flex-direction:column; gap:6px; max-height:280px; overflow:auto; }
.batch-edit-row { display:grid; grid-template-columns:80px 1fr; gap:6px; align-items:center; }
.batch-edit-row label { font-size:12px; color:#6c7d90; }

/* ═══════════════════════════════════════════════════════════════
 * Items 8/9/11/12: Home management panels
 * ═══════════════════════════════════════════════════════════════ */
.home-mgmt-panels { margin-bottom:14px; display:flex; flex-direction:column; gap:10px; }
.mgmt-card { border:1px solid #d6e0ec; border-radius:7px; background:#fff; overflow:hidden; }
.mgmt-card summary { padding:10px 14px; cursor:pointer; color:#20364d; font-size:14px; font-weight:700; list-style:none; display:flex; align-items:center; gap:6px; }
.mgmt-card summary::before { content:"▸"; font-size:10px; color:#8492a3; transition:transform .15s; }
.mgmt-card[open] summary::before { transform:rotate(90deg); }
.mgmt-card summary::-webkit-details-marker { display:none; }
.mgmt-card .card-body { padding:12px 14px; }
.mgmt-table { font-size:13px; }
.mgmt-table th { font-size:13px; padding:6px; }
.mgmt-table td { padding:6px 8px; }
.mgmt-input { font-size:13px; padding:5px 7px; }

/* Card management */
.card-mgmt-area { display:flex; flex-direction:column; gap:12px; }
.card-mgmt-section { display:flex; flex-direction:column; gap:6px; padding:8px; border:1px solid #eceff3; border-radius:6px; background:#f8fafc; }
.card-mgmt-section strong { font-size:14px; color:#24364a; }
.card-mgmt-row { display:flex; align-items:center; justify-content:space-between; gap:8px; padding:4px 0; font-size:13px; color:#42566d; }
.card-mgmt-row span { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; flex:1; }

/* Asset upload */
.asset-actions { padding:6px 8px 8px; border-top:1px solid #e4eaf1; }
.asset-actions .btn { width:100%; }
.upload-area { padding:10px; border:2px dashed #cbd7e5; border-radius:8px; background:#f8fafc; text-align:center; }
.upload-area label { display:inline-block; }

/* Asset grid wider for actions */
.asset { display:flex; flex-direction:column; }
.asset-meta { flex:1; }

/* ═══════════════════════════════════════════════════════════════
 * Selector tree label styling
 * ═══════════════════════════════════════════════════════════════ */
.canvas-selector-tree .row-title strong { font-family:-apple-system,BlinkMacSystemFont,"PingFang SC",sans-serif; font-size:14px; }
.canvas-selector-tree .row-title p { font-family:ui-monospace,SFMono-Regular,Menlo,monospace; font-size:12px; }

/* ═══════════════════════════════════════════════════════════════
 * Focus states — professional admin feel
 * ═══════════════════════════════════════════════════════════════ */
.input:focus, textarea:focus, select:focus { border-color:var(--blue); outline:0; box-shadow:0 0 0 3px rgba(40,100,220,.14); }

/* ═══════════════════════════════════════════════════════════════
 * Table row min-height — breathing room
 * ═══════════════════════════════════════════════════════════════ */
.status-table tr { min-height:40px; }


/* ── 推客密码原生工作区（拉平嵌套框架） ── */
.tuikemima-native-shell {
  overflow:hidden;
  width:100%;
  min-height:calc(100vh - 150px);
  border:1px solid var(--line);
  border-radius:8px;
  background:#f8fafc;
  box-shadow:0 2px 8px rgba(18,38,63,.05);
}
.tuikemima-native-shell .tuikemima-iframe {
  display:block;
  width:100%;
  height:calc(100vh - 150px);
  min-height:760px;
  border:0;
  background:#f8fafc;
}

/* ═══════════════════════════════════════════════════════════════
 * Real data metrics & degradation styles
 * ═══════════════════════════════════════════════════════════════ */
.metric-na {
  display:inline-block;
  color:var(--muted);
  font-size:13px;
  font-weight:400;
  padding:2px 8px;
  border:1px dashed #c5d0dd;
  border-radius:4px;
  background:#f5f7fa;
}
.metric-source {
  font-size:11px;
  color:#8a9aae;
  margin-top:2px;
}
.metric-updated {
  font-size:11px;
  color:#a0afc1;
}
.degraded-text {
  color:var(--muted);
  font-size:13px;
  padding:8px 0;
  text-align:center;
}

/* ── Lock notice (publish page) ── */
.lock-notice {
  padding:14px 16px;
  border:1px solid #f0dca8;
  border-radius:8px;
  background:#fff9e8;
  color:#6b5818;
}
.lock-notice strong {
  display:block;
  font-size:14px;
  margin-bottom:4px;
}
.lock-notice p {
  margin:0;
  font-size:13px;
  line-height:1.5;
}

/* ── Operations list (dashboard) ── */
.ops-list {
  display:flex;
  flex-direction:column;
  gap:6px;
}
.ops-item {
  display:grid;
  grid-template-columns:120px 100px 1fr;
  gap:8px;
  padding:6px 10px;
  border:1px solid #e4eaf1;
  border-radius:6px;
  background:#f8fafc;
  font-size:13px;
}
.ops-time { color:var(--muted); font-size:12px; }
.ops-action { color:#345d8b; font-weight:600; }
.ops-detail { color:#4a5c6e; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }

/* ── Promo safety card (settings) ── */
.promo-safety-card .card-body {
  position:relative;
}

/* ===== 运营设置布局 ===== */
.ops-settings { width: 100%; }
.ops-layout { display: flex; gap: 18px; align-items: flex-start; }

.ops-left { flex: 0 0 340px; min-width: 300px; }
.ops-right { flex: 1; min-width: 0; position: sticky; top: 8px; }

/* 卡片 */
.ops-card {
  background: #fff; border-radius: 10px; border: 1px solid #e8edf3;
  margin-bottom: 14px; overflow: hidden;
  box-shadow: 0 1px 3px rgba(0,0,0,0.03);
}
.ops-card--hero {
  border: 1px solid #d0d8e4; box-shadow: 0 2px 8px rgba(18,38,63,0.06);
}

/* 卡片头部 */
.ops-card-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px; border-bottom: 1px solid #f0f3f7;
}
.ops-card-head h2 {
  font-size: 14px; font-weight: 700; color: #12263f; margin: 0;
  display: flex; align-items: center; gap: 8px;
}
.ops-card-head h2::before {
  content: ""; width: 3px; height: 14px; background: #12263f; border-radius: 2px;
}

/* 子区块 */
.ops-sub-section { padding: 4px 18px 8px; }

/* 预览框 */
.ops-preview-frame {
  border-radius: 10px; overflow: hidden; border: 1px solid #e8edf3;
  background: #fff; box-shadow: 0 2px 12px rgba(0,0,0,0.06);
  width: fit-content; margin: 0 auto;
}
.ops-preview-header {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 14px; background: #12263f;
}
.ops-preview-dot {
  width: 8px; height: 8px; border-radius: 50%; background: #4ade80;
}
.ops-preview-url { font-size: 12px; color: #c5cdd6; flex: 1; }
.ops-preview-refresh {
  font-size: 15px; color: #c5cdd6; cursor: pointer; user-select: none;
  transition: color 0.15s;
}
.ops-preview-refresh:hover { color: #fff; }
.ops-preview-canvas {
  width: 390px; height: 720px; border: none; display: block; background: #fafbfc; margin: 0 auto;
}

/* 活动卡片区 */
.ops-activities { padding: 0; }
.ops-activities h3 {
  font-size: 12px; font-weight: 600; color: #8a99ab;
  text-transform: uppercase; letter-spacing: 0.5px;
  margin: 0; padding: 12px 18px 6px; border-top: 1px solid #f0f3f7;
}
.ops-activities h3:first-child { border-top: 0; }

/* 保存栏 */
.ops-savebar {
  position: sticky; bottom: 14px;
  display: flex; justify-content: center;
  margin-top: 18px; padding: 10px 0;
}
.ops-savebar .btn.primary {
  background: #12263f; color: #fff; border: none;
  padding: 10px 32px; border-radius: 8px; font-size: 14px; font-weight: 600;
  cursor: pointer; transition: all 0.15s;
  box-shadow: 0 2px 10px rgba(18,38,63,0.25);
}
.ops-savebar .btn.primary:hover { background: #1a3556; transform: translateY(-1px); }

/* 响应式 */
@media (max-width: 1100px) {
  .ops-layout { flex-direction: column; }
  .ops-left { flex: none; min-width: 0; width: 100%; }
  .ops-right { position: static; }
  .ops-preview-canvas { height: 500px; }
}

.safety-note {
  margin-top:12px;
  padding:8px 12px;
  border:1px solid #dde7f0;
  border-radius:6px;
  background:#f5f8fc;
  color:#5d7185;
  font-size:12px;
  line-height:1.5;
}
.safety-note strong {
  color:#3a4d60;
}
.replace-entry-visual-only {
  display:flex;
  align-items:center;
  gap:8px;
  padding:8px 12px;
  border:1px dashed #d0dae5;
  border-radius:6px;
  background:#fafbfc;
}
.replace-entry-visual-only input {
  flex:1;
}

/* ── Production content digest (dashboard) ── */
.prod-content-card {
  margin-top:14px;
}
.prod-content-card .card-body {
  padding:0;
}
.prod-article-row {
  display:grid;
  grid-template-columns:1fr 80px 90px 1fr;
  gap:8px;
  padding:10px 18px;
  border-bottom:1px solid #edf1f5;
  font-size:13px;
}
.prod-article-row:last-child {
  border-bottom:0;
}
.prod-article-row strong {
  color:#24364a;
}
.prod-article-row .prod-host {
  color:var(--muted);
  font-size:12px;
}
.prod-article-row .prod-configured {
  font-size:12px;
}
.prod-article-row .prod-digest {
  color:#5a6c7d;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

/* ── Pill color variants ── */
.pill.red { border-color:#e8b8be; background:#fce8eb; color:#a93342; }
.real-section-gap { margin-top:14px; }

/* ── Detail page styles ── */
.detail-tabs {
  display:flex; gap:0; margin-bottom:12px; border-bottom:2px solid #e8eef5;
}
.detail-tab {
  padding:8px 18px; border:none; background:none; cursor:pointer;
  font-size:14px; color:#5a6c7d; border-bottom:2px solid transparent;
  margin-bottom:-2px; transition:all .15s;
}
.detail-tab:hover { color:#2563eb; }
.detail-tab.active {
  color:#2563eb; border-bottom-color:#2563eb; font-weight:600;
}
.detail-filters {
  display:flex; gap:8px; align-items:center; flex-wrap:wrap; margin-bottom:14px;
}
.detail-filters .input { width:auto; min-width:0; }
.detail-filters .input[type="date"] { width:150px; }
.detail-body { min-height:200px; }
.detail-table { font-size:12px; }
.detail-table th { white-space:nowrap; }
.detail-table td { max-width:200px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.detail-pagination {
  display:flex; align-items:center; gap:10px; margin-top:12px;
  justify-content:flex-end;
}
.detail-pagination .detail-count { color:#5a6c7d; font-size:13px; margin-right:auto; }
.detail-per-page { width:80px; }
.empty-state {
  text-align:center; padding:40px 20px; color:#5a6c7d; font-size:14px;
}
.empty-state .metric-na { font-size:12px; margin-top:6px; }

/* ── Ops Settings page styles ── */
.diagnostic-details {
  border: 1px solid var(--line, #d8e1e9);
  border-radius: 12px;
  background: #fff;
  padding: 0;
}
.diagnostic-details > summary {
  cursor: pointer;
  font-weight: 600;
  padding: 18px 22px;
  font-size: 15px;
  color: #17324d;
  list-style: none;
}
.diagnostic-details > summary::-webkit-details-marker { display: none; }
.diagnostic-details > summary::before {
  content: "\25B8";
  margin-right: 8px;
  transition: transform 0.15s;
  display: inline-block;
}
.diagnostic-details[open] > summary::before { transform: rotate(90deg); }
.diagnostic-details > .card-body { padding: 18px 22px; }

.ops-channels .channel-ops-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 10px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid #e7edf2;
}
.channel-ops-row:last-child { border-bottom: 0; }
.channel-ops-form {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr auto auto auto;
  gap: 8px;
  padding: 10px 0;
  align-items: center;
}
.channel-ops-form .input { border: 1px solid var(--line, #d8e1e9); border-radius: 7px; padding: 8px; }
/* ===== 运营设置 商务蓝灰风格 ===== */
.ops-settings { width: 100%; max-width: none; }

/* 开关 */
.ops-settings .switch { position: relative; width: 40px; height: 22px; display: inline-block; flex-shrink: 0; }
.ops-settings .switch input { opacity: 0; position: absolute; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.ops-settings .switch span {
  position: absolute; inset: 0; background: #c5cdd6; border-radius: 22px; cursor: pointer;
  transition: background 0.2s ease;
}
.ops-settings .switch span::after {
  content: ""; position: absolute; width: 16px; height: 16px; left: 3px; top: 3px;
  border-radius: 50%; background: #fff; transition: transform 0.2s ease;
  box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}
.ops-settings .switch input:checked + span { background: #12263f; }
.ops-settings .switch input:checked + span::after { transform: translateX(18px); }
.ops-settings .switch input:disabled + span { opacity: 0.4; cursor: not-allowed; }

/* 设置行 */
.setting-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 11px 16px; border-bottom: 1px solid #eef2f7;
  transition: background 0.12s;
}
.setting-row:hover { background: #f7f9fb; }
.setting-row:last-child { border-bottom: 0; }
.setting-row b { font-size: 14px; font-weight: 600; color: #1a2b3c; }
.setting-row .muted { color: #8a99ab; font-size: 12px; margin-top: 2px; }

/* 子开关行（首页子分类等） */
.subrows { padding: 0 16px; background: #f9fafc; border-radius: 0 0 8px 8px; }
.subrows .setting-row { padding: 8px 0; border-bottom: 1px solid #f0f3f7; }
.subrows .setting-row:last-child { border-bottom: 0; }
.subrows .setting-row span { font-size: 13px; color: #56657a; }

/* 面板区块 */
.panel-section {
  background: #fff; border-radius: 8px; border: 1px solid #e6ecf2;
  margin-bottom: 14px; overflow: hidden;
}
.panel-section > h2 {
  font-size: 14px; font-weight: 700; color: #12263f;
  margin: 0; padding: 14px 16px 8px;
  display: flex; align-items: center; gap: 8px;
}
.panel-section > h2::before {
  content: ""; display: inline-block; width: 3px; height: 14px;
  background: #12263f; border-radius: 2px;
}
.panel-section > h3 {
  font-size: 13px; font-weight: 600; color: #3a4a5c;
  margin: 0; padding: 10px 16px 6px; border-top: 1px solid #f0f3f7;
}
.panel-section > .muted {
  padding: 0 16px 10px; margin: 0; font-size: 12px; color: #9aa7b5;
}

/* 活动卡行 */
.card-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 16px; border-bottom: 1px solid #f0f3f7;
}
.card-row:last-child { border-bottom: 0; }
.card-row b { font-size: 13px; font-weight: 500; color: #3a4a5c; }

/* 排序按钮 */
.order-actions { display: flex; gap: 4px; }
.order-actions button {
  width: 28px; height: 28px; border: 1px solid #dfe5eb; border-radius: 6px;
  background: #fff; cursor: pointer; font-size: 12px; color: #56657a;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.12s;
}
.order-actions button:hover:not(:disabled) { background: #12263f; color: #fff; border-color: #12263f; }
.order-actions button:disabled { opacity: 0.35; cursor: not-allowed; }

/* 保存栏 */
.savebar {
  position: sticky; bottom: 14px;
  display: flex; justify-content: flex-end;
  margin-top: 18px; padding: 12px 0;
}
.savebar .btn.primary {
  background: #12263f; color: #fff; border: none;
  padding: 10px 28px; border-radius: 8px; font-size: 14px; font-weight: 600;
  cursor: pointer; transition: background 0.15s;
  box-shadow: 0 2px 8px rgba(18,38,63,0.25);
}
.savebar .btn.primary:hover { background: #1a3556; }

.safety-note {
  font-size: 12px;
  color: #6e7f90;
  margin-top: 10px;
  padding: 8px 12px;
  background: #f7f9fb;
  border-radius: 7px;
}

/* === 运营设置：总开关+子开关层级结构 === */
.ops-page-card {
  background: #fff;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  margin-bottom: 14px;
  overflow: hidden;
}
.ops-page-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  background: #f7f9fc;
  border-bottom: 1px solid #e2e8f0;
}
.ops-page-head h2 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  color: #12263f;
}
.ops-page-body {
  padding: 4px 18px 8px;
}
.ops-page-body .setting-row.sub {
  padding: 8px 0;
  border-bottom: 1px solid #f0f3f7;
}
.ops-page-body .setting-row.sub:last-child {
  border-bottom: none;
}
/* 确保所有 .switch 在运营设置中统一渲染 */
.ops-settings .switch {
  position: relative;
  width: 38px;
  height: 21px;
  display: inline-block;
  flex-shrink: 0;
}
.ops-settings .switch input {
  width: 0;
  height: 0;
  opacity: 0;
  position: absolute;
}
.ops-settings .switch span {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: #ccc;
  border-radius: 21px;
  transition: 0.3s;
}
.ops-settings .switch span::before {
  content: "";
  position: absolute;
  height: 17px;
  width: 17px;
  left: 2px;
  bottom: 2px;
  background: #fff;
  border-radius: 50%;
  transition: 0.3s;
}
.ops-settings .switch input:checked + span {
  background: #12263f;
}
.ops-settings .switch input:checked + span::before {
  transform: translateX(17px);
}
.ops-settings .switch input:disabled + span {
  opacity: 0.4;
  cursor: not-allowed;
}

/* === 运营设置右栏：Tab切换 + 推客素材 === */
.ops-tabs {
  display: flex;
  gap: 0;
  border-bottom: 2px solid #e2e8f0;
  margin-bottom: 12px;
}
.ops-tab {
  padding: 8px 18px;
  border: none;
  background: none;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  color: #64748b;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: all 0.2s;
}
.ops-tab.active {
  color: #12263f;
  border-bottom-color: #12263f;
}
.ops-tab:hover { color: #12263f; }
.ops-tab-pane { display: none; }
.ops-tab-pane.active { display: block; }

/* 推客素材筛选栏 */
.tkm-filter-bar {
  display: flex;
  gap: 6px;
  margin-bottom: 10px;
}
.tkm-filter-btn {
  padding: 4px 12px;
  border: 1px solid #d1d9e6;
  border-radius: 14px;
  background: #fff;
  cursor: pointer;
  font-size: 12px;
  color: #475569;
  transition: all 0.2s;
}
.tkm-filter-btn.active {
  background: #12263f;
  color: #fff;
  border-color: #12263f;
}
.tkm-filter-btn:hover { border-color: #12263f; }

/* 推客素材网格 */
.tkm-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  max-height: 600px;
  overflow-y: auto;
}
.tkm-card {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  padding: 8px;
  position: relative;
  transition: border-color 0.2s;
}
.tkm-card:hover { border-color: #94a3b8; }
.tkm-card-img {
  width: 44px;
  height: 44px;
  border-radius: 4px;
  overflow: hidden;
  flex-shrink: 0;
  background: #f1f5f9;
}
.tkm-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.tkm-no-img {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  color: #94a3b8;
}
.tkm-card-info {
  flex: 1;
  min-width: 0;
}
.tkm-card-title {
  font-size: 12px;
  font-weight: 500;
  color: #1e293b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 3px;
}
.tkm-card-meta {
  display: flex;
  gap: 6px;
  align-items: center;
}
.tkm-tag {
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 3px;
  font-weight: 500;
}
.tkm-tag-jd { background: #fee2e2; color: #dc2626; }
.tkm-tag-meituan { background: #fef3c7; color: #d97706; }
.tkm-tag-taobao { background: #fce7f3; color: #db2777; }
.tkm-tag-other { background: #e2e8f0; color: #475569; }
.tkm-card-id { font-size: 10px; color: #94a3b8; }
.tkm-add-btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: none;
  background: #12263f;
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.2s;
}
.tkm-add-btn:hover { background: #1e3a5f; transform: scale(1.1); }
.tkm-add-btn.added { background: #16a34a; }
.tkm-loading, .tkm-empty {
  grid-column: 1/-1;
  text-align: center;
  padding: 30px 0;
  color: #94a3b8;
  font-size: 13px;
}

/* === 右栏并排：预览 + 推客素材 === */
.ops-right-cols {
  display: flex;
  flex-direction: row;
  gap: 14px;
  align-items: flex-start;
}
.ops-right-preview {
  flex: 0 0 410px;
}
.ops-right-materials {
  flex: 1;
  min-width: 0;
  background: #fff;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  padding: 12px;
  max-height: 780px;
  overflow-y: auto;
}
/* 素材网格改单列 */
.ops-right-materials .tkm-grid {
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

/* TKM page selector popup */
.tkm-page-popup{position:fixed;z-index:9999;background:#fff;border:1px solid #12263f;border-radius:8px;box-shadow:0 4px 20px rgba(18,38,63,.18);padding:8px;min-width:160px}
.tkm-popup-title{font-size:12px;color:#12263f;font-weight:600;margin-bottom:6px;padding-bottom:4px;border-bottom:1px solid #e2e8f0}
.tkm-page-opt{display:block;width:100%;text-align:left;padding:7px 10px;border:none;background:#f7f9fc;border-radius:4px;margin-bottom:3px;font-size:13px;color:#12263f;cursor:pointer;transition:background .15s}
.tkm-page-opt:hover{background:#e8eef5}
.tkm-page-opt.tkm-page-disabled{opacity:.5;cursor:not-allowed}
.tkm-added-mark{color:#22c55e;font-size:11px;margin-left:4px}
.tkm-page-cancel{display:block;width:100%;text-align:center;padding:6px;border:none;background:transparent;color:#94a3b8;font-size:12px;cursor:pointer;margin-top:4px}
.tkm-page-cancel:hover{color:#64748b}


/* Bug3 fix: disabled tkm card styling */
.tkm-tree-disabled .row-title strong::after {
  content: ' (已关闭)';
  font-size: 10px;
  color: #e74c3c;
  font-weight: normal;
}


.activity-card-list-page { display:grid; gap:16px; }
.activity-card-list-shell, .activity-preview-card { overflow:hidden; }
.activity-page-head { align-items:flex-start; }
.activity-page-meta { display:flex; gap:8px; flex-wrap:wrap; }
.activity-card-list { display:flex; flex-direction:column; gap:12px; }
.activity-edit-row { display:grid; grid-template-columns:80px minmax(0,1fr) 92px; gap:14px; align-items:center; padding:14px; border:1px solid #d8e2ee; border-radius:10px; background:#fff; }
.activity-edit-row.is-disabled { opacity:.7; background:#f8fafc; }
.activity-edit-row.is-tkm { border-color:#f2c27b; box-shadow:inset 0 0 0 1px rgba(243,181,27,.18); }
.activity-thumb { width:80px; height:80px; overflow:hidden; border-radius:10px; background:#eef3f8; display:grid; place-items:center; }
.activity-thumb img { width:100%; height:100%; object-fit:cover; display:block; }
.activity-thumb-fallback { color:#6f8398; font-size:13px; font-weight:700; }
.activity-edit-main { min-width:0; display:flex; flex-direction:column; gap:10px; }
.activity-field-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px 12px; }
.activity-field-grid label { display:flex; flex-direction:column; gap:6px; color:#5d7187; font-size:12px; font-weight:600; }
.activity-field-grid label.full { grid-column:1 / -1; }
.activity-inline-input { width:100%; }
.activity-tag-row { display:flex; flex-wrap:wrap; gap:8px; }
.activity-chip { display:inline-flex; align-items:center; padding:4px 10px; border-radius:999px; background:#edf4ff; color:#2858a8; font-size:12px; font-weight:700; }
.activity-chip.muted { background:#eef2f6; color:#6f8193; }
.activity-chip.disabled { background:#fff0e4; color:#a95717; }
.activity-chip.tkm { background:#fff3d8; color:#9a5a00; }
.activity-row-actions { display:flex; flex-direction:column; align-items:flex-end; gap:12px; }
.activity-move-buttons { display:flex; gap:8px; }
.switch.compact { transform:scale(.95); transform-origin:right center; }
.activity-preview-frame-wrap { width:390px; max-width:100%; margin:0 auto; border:1px solid #d8e2ee; border-radius:18px; overflow:hidden; background:#f1f5f9; box-shadow:0 10px 24px rgba(21,45,76,.08); }
.activity-preview-iframe { width:390px; height:400px; display:block; border:0; background:#fff; }


.activity-card-list-shell { grid-column: 1; }
.activity-preview-card { grid-column: 2; position: sticky; top: 12px; }
@media (max-width: 1100px) {
  .activity-card-list-page {
    grid-template-columns: 1fr !important;
  }
  .activity-preview-card { position: static; }
}


/* === 三栏：缩略列表 + 预览 + 编辑面板 === */
.act-three-col-page { display: flex; flex-direction: column; gap: 12px; }
.act-page-header { display: flex; justify-content: space-between; align-items: flex-start; padding: 0 4px; }
.act-page-header h2 { margin: 0 0 2px; font-size: 18px; }
.act-page-header small { color: #6b7d92; font-size: 12px; }
.act-page-meta { display: flex; gap: 6px; }

.act-three-col-grid {
  display: grid;
  grid-template-columns: 200px minmax(0,1fr) 300px;
  gap: 14px;
  align-items: start;
}

/* 左栏：缩略列表 */
.act-thumb-list {
  display: flex; flex-direction: column; gap: 6px;
  max-height: 780px; overflow-y: auto;
  padding: 8px; border: 1px solid #dde5ef; border-radius: 10px; background: #f8fafc;
}
.act-thumb-item {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 8px; border: 1px solid transparent; border-radius: 8px;
  background: #fff; cursor: pointer; text-align: left;
  transition: border-color .15s, box-shadow .15s; width: 100%;
}
.act-thumb-item:hover { border-color: #b8c8d8; }
.act-thumb-item.is-tkm { border-color: #f2c27b; }
.act-thumb-item.is-disabled { opacity: .5; }
.act-thumb-item.selected { border-color: #2563eb; box-shadow: 0 0 0 2px rgba(37,99,235,.15); }
.act-thumb-img { width: 36px; height: 36px; border-radius: 6px; overflow: hidden; flex-shrink: 0; background: #eef3f8; display: grid; place-items: center; }
.act-thumb-img img { width: 100%; height: 100%; object-fit: cover; }
.act-thumb-label { font-size: 12px; color: #334155; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.act-thumb-badge { font-size: 9px; background: #f39c12; color: #fff; padding: 1px 4px; border-radius: 4px; flex-shrink: 0; }
.act-thumb-off { font-size: 9px; background: #666; color: #fff; padding: 1px 4px; border-radius: 4px; flex-shrink: 0; }

/* 中栏：预览 */
.act-preview-mid { display: flex; justify-content: center; }
.act-preview-device {
  border: 1px solid #dde5ef; border-radius: 12px; overflow: hidden;
  background: #fff; box-shadow: 0 2px 12px rgba(0,0,0,.06);
}
.act-preview-bar {
  display: flex; justify-content: space-between; align-items: center;
  padding: 6px 12px; background: #f1f5f9; font-size: 11px; color: #64748b;
  border-bottom: 1px solid #e2e8f0;
}
.act-preview-iframe { border: 0; display: block; }

/* 右栏：编辑面板 */
.act-edit-side {
  min-height: 200px;
  padding: 14px; border: 1px solid #dde5ef; border-radius: 10px; background: #fff;
  position: sticky; top: 12px;
}
.act-edit-empty { color: #94a3b8; text-align: center; padding: 40px 0; font-size: 13px; }
.act-edit-panel { display: flex; flex-direction: column; gap: 12px; }
.act-edit-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.act-edit-head strong { font-size: 14px; }
.act-edit-fields { display: flex; flex-direction: column; gap: 8px; }
.act-edit-fields label { display: flex; flex-direction: column; gap: 3px; font-size: 11px; color: #64748b; }
.act-edit-fields .input { font-size: 13px; padding: 6px 8px; }
.act-edit-tagrow { font-size: 11px; color: #64748b; }
.act-edit-actions { display: flex; justify-content: space-between; align-items: center; padding-top: 8px; border-top: 1px solid #eef2f7; }
.act-move-btns { display: flex; gap: 4px; }

@media (max-width: 1200px) {
  .act-three-col-grid { grid-template-columns: 180px 1fr; }
  .act-edit-side { grid-column: 1 / -1; position: static; }
}
@media (max-width: 768px) {
  .act-three-col-grid { grid-template-columns: 1fr; }
}


/* 编辑面板可编辑标签 */
.act-edit-tags { display: flex; gap: 8px; }
.act-edit-tags label { flex: 1; display: flex; flex-direction: column; gap: 3px; font-size: 11px; color: #64748b; }
.act-tag-input { font-size: 12px !important; padding: 5px 8px !important; }
.act-tag-input.tag-primary { border-left: 3px solid #2563eb; }
.act-tag-input.tag-secondary { border-left: 3px solid #64748b; }

.act-save-btn { width: 100%; margin-top: 4px; font-size: 13px; }
