/* 维修侠 · 商厨维修 —— 手机 App 样式
   视觉基线：用户提供的手机原型图（iOS 状态栏 / 实景 hero / 实心彩色图标块 /
   带「›」的分类卡 / 图标化底部导航）。 */

*{box-sizing:border-box}
html,body{margin:0}
body{
  background:#e9eef7;color:#16233a;font-size:14px;line-height:1.45;
  font-family:-apple-system,BlinkMacSystemFont,"PingFang SC","Microsoft YaHei",sans-serif;
  -webkit-text-size-adjust:100%;
  -webkit-font-smoothing:antialiased;
}
img{max-width:100%}
button{font:inherit;color:inherit}
svg{display:block}

.app{
  position:relative;max-width:430px;margin:auto;min-height:100vh;background:#f4f7fc;
  padding-bottom:96px;overflow-x:hidden;
}

/* ---------- 预览外壳（手机外观只在桌面/预览时出现） ---------- */
.statusbar,.homebar{display:none}
html.preview body{background:radial-gradient(120% 90% at 50% 0%,#e7eefb,#d7e0ee 70%,#cfd9e9)}
html.preview .app{
  min-height:calc(100vh - 60px);margin:26px auto 34px;border-radius:42px;overflow:hidden;
  box-shadow:0 30px 70px #22375b33,0 2px 0 #ffffff inset;
}
html.preview .statusbar{
  display:flex;align-items:center;justify-content:space-between;
  height:44px;padding:0 26px;background:#fff;font-size:14px;font-weight:700;letter-spacing:.2px;
}
html.preview .statusbar .sb-icons{display:flex;align-items:center;gap:5px;color:#16233a}
html.preview .statusbar .sb-icons svg{height:11px;width:auto}
html.preview .statusbar .sb-icons svg:first-child{width:17px}
html.preview .statusbar .sb-icons svg:nth-child(2){width:15px}
html.preview .statusbar .sb-icons svg:last-child{width:25px}
html.preview .homebar{display:block;height:26px;background:#f4f7fc;position:relative}
html.preview .homebar i{
  position:absolute;left:50%;bottom:8px;transform:translateX(-50%);
  width:134px;height:5px;border-radius:5px;background:#101828;
}
html.preview .homebar{display:none!important}
html.preview .bottom{
  position:absolute;bottom:0;left:0;transform:none;width:100%;
  border-radius:0;padding-bottom:24px;
}
html.preview .bottom:after{
  content:"";position:absolute;left:50%;bottom:7px;transform:translateX(-50%);
  width:134px;height:5px;border-radius:5px;background:#101828;
}

/* ---------- 顶部 ---------- */
.top{
  display:flex;align-items:center;justify-content:space-between;gap:10px;
  padding:14px 16px 10px;background:#f4f7fc;position:sticky;top:0;z-index:4;
}
.brand{display:flex;gap:10px;align-items:center;min-width:0}
.logo{
  width:42px;height:42px;border-radius:13px;flex:0 0 auto;display:grid;place-items:center;
  background:linear-gradient(150deg,#3d9bff,#1668d8);
  box-shadow:0 6px 14px #1668d83d;
}
.logo svg{width:24px;height:24px}
.brand h1{font-size:18px;margin:0 0 2px;letter-spacing:.2px}
.brand small{color:#8593a8;font-size:11px}
.topacts{display:flex;align-items:center;gap:8px;flex:0 0 auto}
.pillbtn{
  display:inline-flex;align-items:center;gap:5px;border:0;background:#fff;
  border-radius:20px;padding:8px 12px;font-size:12.5px;color:#2c3d57;
  box-shadow:0 2px 10px #22375b14;white-space:nowrap;
}
.pillbtn svg{width:14px;height:14px;color:#3d7ef0}
.iconbtn{
  width:36px;height:36px;border:0;background:#fff;border-radius:50%;
  display:grid;place-items:center;color:#63748c;box-shadow:0 2px 10px #22375b14;
}
.iconbtn svg{width:19px;height:19px}

/* ---------- Hero ---------- */
.hero{
  position:relative;margin:2px 14px 14px;height:150px;border-radius:18px;overflow:hidden;
  background:linear-gradient(100deg,#e9f3ff 0%,#d7e9ff 46%,#c7ddf7 100%);
  box-shadow:0 8px 22px #1b5caa17;
}
.hero-photo{
  position:absolute;top:0;right:0;width:62%;height:100%;
  background-image:url("assets/kitchen-hero.jpg");
  background-size:cover;background-position:right center;
  -webkit-mask-image:linear-gradient(90deg,transparent 0%,#000 42%);
  mask-image:linear-gradient(90deg,transparent 0%,#000 42%);
  filter:saturate(.75) contrast(1.02);
  opacity:.95;
}
.hero-photo:after{
  content:"";position:absolute;inset:0;
  background:linear-gradient(110deg,#cfe4ff8c 0%,#a9cbf0a6 40%,#7fb0e0a8 100%);
  mix-blend-mode:multiply;
}
.hero-body{position:relative;z-index:1;height:100%;padding:20px 18px;display:flex;flex-direction:column;justify-content:center;max-width:76%}
.hero h2{
  margin:0 0 8px;font-size:22px;line-height:1.32;letter-spacing:.2px;color:#10243f;
  text-shadow:0 1px 0 #ffffff7a;
}
.hero h2 em{font-style:normal;color:#1268dd}
.hero p{margin:0;color:#48627f;font-size:12px}
.hero-more{
  position:absolute;right:16px;bottom:18px;z-index:2;border:0;color:#fff;
  background:linear-gradient(135deg,#3d9bff,#1668d8);border-radius:14px;
  padding:7px 12px;font-size:11.5px;font-weight:600;box-shadow:0 6px 14px #1668d83d;
}

/* ---------- 搜索 ---------- */
.search{
  margin:0 14px 16px;background:#fff;border-radius:26px;padding:6px 6px 6px 14px;
  display:flex;gap:8px;align-items:center;box-shadow:0 6px 18px #22375b12;
}
.search .si{width:18px;height:18px;color:#98a6ba;flex:0 0 auto}
.search input{border:0;outline:0;flex:1;min-width:0;font-size:13.5px;background:transparent;color:#16233a}
.search input::placeholder{color:#a7b3c4}
.search button{
  border:0;background:linear-gradient(135deg,#3d9bff,#1668d8);color:#fff;
  border-radius:22px;padding:10px 18px;font-weight:600;font-size:13px;
  box-shadow:0 6px 14px #1668d833;
}

/* ---------- 通用分节 ---------- */
.section{margin:0 14px 14px}
.card{background:#fff;border-radius:18px;padding:14px 13px;box-shadow:0 6px 20px #22375b0d}
.sechead{display:flex;align-items:center;justify-content:space-between;margin:0 2px 12px}
.sechead h3{margin:0;font-size:15px;font-weight:700;display:flex;align-items:center;gap:7px;letter-spacing:.2px}
.sechead .bar{width:3px;height:14px;border-radius:2px;background:linear-gradient(#4aa3ff,#1668d8);display:inline-block}
.more{color:#93a1b4;font-size:12px;white-space:nowrap}

/* ---------- 分类六宫格 ---------- */
.cats{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}
.cat{
  border-radius:16px;padding:13px 8px 11px;text-align:center;min-height:112px;
  cursor:pointer;transition:transform .12s ease;
}
.cat:active{transform:scale(.97)}
.cat .tile{
  width:42px;height:42px;border-radius:13px;margin:0 auto 9px;display:grid;place-items:center;
  color:#fff;box-shadow:0 6px 13px #22375b1f;
}
.cat .tile svg{width:23px;height:23px}
.cat b{display:block;font-size:13px;font-weight:700;letter-spacing:.1px}
.cat small{display:flex;align-items:center;justify-content:center;gap:2px;color:#8794a8;font-size:10px;margin-top:5px}
.chev{font-style:normal;color:#b3bfd0;font-size:12px;line-height:1}
.c1{background:#eaf2fe}.c2{background:#e9f8f0}.c3{background:#fdf2e5}
.c4{background:#f2ecff}.c5{background:#e9f8ef}.c6{background:#e9f3fe}
.c1 .tile{background:linear-gradient(150deg,#5aabff,#1768dd)}
.c2 .tile{background:linear-gradient(150deg,#5ed3a3,#23a97a)}
.c3 .tile{background:linear-gradient(150deg,#ffbe64,#ef8b1f)}
.c4 .tile{background:linear-gradient(150deg,#ae94ff,#7c5cf0)}
.c5 .tile{background:linear-gradient(150deg,#5ad3a9,#1fa97a)}
.c6 .tile{background:linear-gradient(150deg,#5cb7ff,#2a83e4)}

/* ---------- 快捷工具 ---------- */
.toolgrid{display:grid;grid-template-columns:repeat(5,1fr);gap:2px;text-align:center}
.tool{cursor:pointer;padding:2px 0 4px}
.tool:active{opacity:.72}
.tool .tile{
  width:46px;height:46px;border-radius:14px;margin:0 auto 7px;display:grid;place-items:center;
  color:#fff;box-shadow:0 6px 13px #22375b1c;
}
.tool .tile svg{width:24px;height:24px}
.t1{background:linear-gradient(150deg,#ffc067,#f08a1e)}
.t2{background:linear-gradient(150deg,#5aabff,#1768dd)}
.t3{background:linear-gradient(150deg,#5ed3a3,#23a97a)}
.t4{background:linear-gradient(150deg,#ae94ff,#7c5cf0)}
.t5{background:linear-gradient(150deg,#5cb7ff,#2a83e4)}
.tool b{font-size:11px;font-weight:500;color:#43536b}

/* ---------- 热门推荐 / 列表行 ---------- */
.article{display:flex;gap:11px;padding:11px 0;border-bottom:1px solid #f1f4f9;cursor:pointer;align-items:flex-start}
.article:last-child{border-bottom:0;padding-bottom:2px}
.article:active{opacity:.75}
.thumb{
  width:86px;height:64px;border-radius:11px;flex-shrink:0;overflow:hidden;
  background:linear-gradient(135deg,#e8f1fb,#cbdcef);display:grid;place-items:center;font-size:26px;
}
.thumb img{width:100%;height:100%;object-fit:cover;display:block}
.article .info{flex:1;min-width:0}
.article h4{margin:0 0 6px;font-size:13.5px;line-height:1.38;font-weight:600;letter-spacing:.1px;
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.tags{display:flex;gap:5px;flex-wrap:wrap}
.tags span{background:#f2f5f9;color:#7b8a9f;border-radius:7px;padding:2px 7px;font-size:10px}
.meta{display:flex;gap:12px;color:#9aa8ba;font-size:10.5px;margin-top:7px;align-items:center}
.meta i{display:inline-flex;align-items:center;gap:3px;font-style:normal}
.meta svg{width:11px;height:11px}
.status{
  margin-left:auto;align-self:center;white-space:nowrap;font-size:10px;font-weight:600;
  padding:4px 8px;border-radius:9px;color:#12a06a;background:#e6f8ee;
}
.status.ok:before{content:"✓ "}
.status.warn{color:#cf8213;background:#fff3e0}
.status.info{color:#1f6fe0;background:#e9f2ff}
.status.wait{color:#7c5cd0;background:#f1ecff}

/* ---------- 底部导航 ---------- */
.bottom{
  position:fixed;bottom:0;left:50%;transform:translateX(-50%);width:min(430px,100%);
  display:grid;grid-template-columns:repeat(5,1fr);
  background:#fff;border-top:1px solid #eef2f8;
  padding:8px 4px max(8px,env(safe-area-inset-bottom));z-index:6;
  box-shadow:0 -6px 20px #22375b0f;
}
.tab{
  display:flex;flex-direction:column;align-items:center;gap:3px;
  color:#98a4b6;font-size:10px;cursor:pointer;padding:2px 0;
}
.tab svg{width:22px;height:22px}
.tab.active{color:#1668d8;font-weight:600}
.tab.active svg{stroke-width:2.1}

/* ---------- 子页 / 导航条 ---------- */
.page{display:none;padding-top:12px}
.page.active{display:block;animation:fade .16s ease}
@keyframes fade{from{opacity:.5;transform:translateY(3px)}to{opacity:1;transform:none}}
.subhead{padding:2px 16px 13px}
.subhead h2{font-size:20px;margin:0 0 4px;letter-spacing:.2px}
.subhead p{color:#8593a8;margin:0;font-size:12px;line-height:1.6}

.navbar{
  position:sticky;top:0;z-index:5;display:flex;align-items:center;gap:10px;
  padding:10px 14px;background:#f4f7fce8;backdrop-filter:blur(10px);
  border-bottom:1px solid #e9eef6;
}
.navbar button{
  border:0;background:#fff;width:34px;height:34px;border-radius:12px;color:#3c5170;
  font-size:17px;line-height:1;box-shadow:0 2px 10px #22375b12;flex:0 0 auto;
}
.navbar .navtitle{font-size:15px;font-weight:600;flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.navbar .navact{
  border:0;background:#e9f2ff;color:#1668d8;border-radius:12px;padding:8px 11px;
  font-size:12px;font-weight:600;flex:0 0 auto;white-space:nowrap;width:auto;height:auto;
}

/* ---------- 列表卡 ---------- */
.listcard{background:#fff;border-radius:16px;margin:0 14px 10px;padding:14px;cursor:pointer;
  box-shadow:0 4px 16px #22375b0d}
.listcard.flat{margin:0 0 10px;box-shadow:none;background:#f8fafe}
.listcard:active{opacity:.82}
.listcard h4{margin:0 0 6px;font-size:14px;line-height:1.45;font-weight:600}
.listcard p{margin:0;color:#7b8a9f;font-size:12px;line-height:1.6}
.pill{display:inline-block;background:#edf3fd;color:#2f6fd0;padding:3px 8px;border-radius:8px;
  font-size:10px;margin:8px 5px 0 0;white-space:nowrap}
.pill.ok{background:#e6f8ee;color:#12805a}
.pill.warn{background:#fff3e0;color:#b06915}
.pill.wait{background:#f1ecff;color:#7752a8}
.pill.dim{background:#f2f5f9;color:#7c8ba1}
.empty{padding:28px;text-align:center;color:#8b98aa;font-size:12px;line-height:1.7}

/* ---------- 表单 ---------- */
.formbox{margin:0 14px 14px;background:#fff;padding:15px;border-radius:16px;box-shadow:0 6px 20px #22375b0d}
.formbox label{display:block;font-size:12px;color:#697a92;margin-top:2px}
.formbox input,.formbox textarea,.formbox select{
  width:100%;padding:12px;border:1px solid #e6ecf5;border-radius:11px;margin:6px 0 12px;
  font:inherit;background:#fafcff;color:#16233a;
}
.formbox textarea{min-height:80px;resize:vertical}
.formbox input:focus,.formbox textarea:focus,.formbox select:focus{outline:2px solid #d7e8ff;border-color:#a9cdf7}
.formbox .primary{width:100%;margin-top:4px}
.formbox .hint{font-size:11px;color:#8b98aa;line-height:1.6;margin:-6px 0 10px}
.primary{border:0;background:linear-gradient(135deg,#3d9bff,#1668d8);color:#fff;border-radius:12px;
  padding:12px 17px;font-weight:600;box-shadow:0 6px 16px #1668d833}

/* ---------- chips ---------- */
.chips{display:flex;gap:8px;overflow-x:auto;padding:0 14px 12px;scrollbar-width:none}
.chips::-webkit-scrollbar{display:none}
.chip{
  flex:0 0 auto;border:1px solid #e6ecf5;background:#fff;color:#5d6f88;border-radius:20px;
  padding:7px 13px;font-size:12px;white-space:nowrap;
}
.chip.on{background:linear-gradient(135deg,#3d9bff,#1668d8);border-color:#1668d8;color:#fff;font-weight:600}

/* ---------- 详情 ---------- */
.detail{padding-bottom:24px}
.dhead{margin:0 14px 12px;background:#fff;border-radius:18px;padding:16px;box-shadow:0 6px 20px #22375b0d}
.dhead h2{margin:0 0 8px;font-size:18.5px;line-height:1.42;letter-spacing:.1px}
.dtags{display:flex;gap:5px;flex-wrap:wrap;margin-bottom:8px}
.dtags span{background:#f2f5f9;color:#6d7c93;border-radius:8px;padding:3px 7px;font-size:10px}
.dhead .sub{color:#7b8a9f;font-size:12px;line-height:1.7;margin:0}
.block{margin:0 14px 12px;background:#fff;border-radius:16px;padding:14px 15px;box-shadow:0 4px 16px #22375b0d}
.block h3{margin:0 0 10px;font-size:14px;display:flex;align-items:center;gap:6px}
.block h3 .count{color:#93a1b3;font-weight:400;font-size:11px}
.block p{margin:0 0 8px;color:#5d6c82;font-size:12.5px;line-height:1.75}
.block p:last-child{margin-bottom:0}
.note{background:#f7fafe;border-left:3px solid #cfe3ff;border-radius:0 10px 10px 0;padding:10px 12px;color:#5a6c85;font-size:12px;line-height:1.75}
.note.warn{background:#fff9ef;border-left-color:#f3c68f;color:#8a6320}
.note.ok{background:#f2fbf7;border-left-color:#9fe0c4;color:#1f6b51}
.kv{display:grid;grid-template-columns:78px 1fr;gap:6px 10px;font-size:12px;color:#5d6c82;line-height:1.65}
.kv b{color:#8b98aa;font-weight:500}
.mono{font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;font-size:11px;word-break:break-all}

/* ---------- 视频 ---------- */
.videobox{background:#0e1520;border-radius:15px;overflow:hidden;position:relative;margin-bottom:10px}
.videobox video{display:block;width:100%;max-height:62vh;background:#000;object-fit:contain}
.speeds{display:flex;gap:6px;padding:8px 2px 2px;align-items:center;flex-wrap:wrap}
.speeds .lb{font-size:11px;color:#8b98aa;margin-right:2px}
.speeds button{border:1px solid #e6ecf5;background:#fff;color:#5d6f88;border-radius:9px;padding:5px 9px;font-size:11px}
.speeds button.on{background:#e9f2ff;border-color:#bcd9fb;color:#1668d8;font-weight:600}

/* ---------- 图片 ---------- */
.gallery{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.shot{background:#f4f8fd;border-radius:11px;overflow:hidden;cursor:zoom-in;margin:0}
.shot img{width:100%;height:104px;object-fit:cover;display:block}
.shot figcaption{font-size:10px;color:#77869c;line-height:1.5;padding:7px 8px}
.shot.missing{display:grid;place-items:center;height:104px;color:#a4b0c1;font-size:11px}

.lightbox{position:fixed;inset:0;background:#0b1220f2;display:none;z-index:20;align-items:center;justify-content:center;padding:18px}
.lightbox.on{display:flex}
.lightbox img{max-width:100%;max-height:78vh;border-radius:12px}
.lightbox .cap{position:absolute;bottom:24px;left:0;right:0;text-align:center;color:#dbe6f5;font-size:12px;padding:0 24px;line-height:1.6}
.lbnav{position:absolute;top:50%;transform:translateY(-50%);width:42px;height:42px;border:0;border-radius:50%;background:#ffffff26;color:#fff;font-size:26px;line-height:1;display:grid;place-items:center;cursor:pointer;padding:0}
.lbnav.prev{left:10px}
.lbnav.next{right:10px}
.lbnav[hidden]{display:none}
.lbclose{position:absolute;top:12px;right:12px;width:36px;height:36px;border:0;border-radius:50%;background:#ffffff1f;color:#fff;font-size:20px;line-height:1;padding:0;cursor:pointer}
.lbcount{position:absolute;top:20px;left:0;right:0;text-align:center;color:#cfe0f7;font-size:12px;letter-spacing:.04em}
.lbcount[hidden]{display:none}

/* ---------- 步骤 ---------- */
.progress{margin:0 0 10px;display:flex;align-items:center;gap:9px}
.bar-track{flex:1;height:6px;border-radius:6px;background:#eef2f8;overflow:hidden}
.bar-track i{display:block;height:100%;width:0;background:linear-gradient(90deg,#5aa6ff,#1668d8);border-radius:6px;transition:width .25s}
.progress span{font-size:11px;color:#8b98aa;white-space:nowrap}
.steplist{list-style:none;margin:0;padding:0}
.step{display:flex;gap:10px;padding:10px 0;border-bottom:1px solid #f3f6fb}
.step:last-child{border-bottom:0}
.step .box{
  flex:0 0 auto;width:22px;height:22px;border-radius:7px;border:1.6px solid #cfd9e6;background:#fff;
  display:grid;place-items:center;color:transparent;font-size:13px;margin-top:1px;cursor:pointer;
}
.step.done .box{background:linear-gradient(135deg,#3d9bff,#1668d8);border-color:#1668d8;color:#fff}
.step.done .txt{color:#93a1b3;text-decoration:line-through}
.step .txt{font-size:12.5px;line-height:1.7;color:#3f5068}
.step .num{color:#a9b5c5;font-size:11px;margin-right:4px}

/* ---------- 表格 / 覆盖 ---------- */
.tbl{width:100%;border-collapse:collapse;font-size:12px}
.tbl th{text-align:left;color:#8b98aa;font-weight:500;font-size:11px;padding:6px 8px;border-bottom:1px solid #eef2f8}
.tbl td{padding:9px 8px;border-bottom:1px solid #f3f6fb;color:#42536b;line-height:1.6;vertical-align:top}
.tbl tr:last-child td{border-bottom:0}
.tbl .code{font-family:ui-monospace,Menlo,Consolas,monospace;color:#1668d8;font-weight:600}

/* ---------- KPI ---------- */
.kpis{display:grid;grid-template-columns:repeat(4,1fr);gap:9px;margin:0 14px 14px}
.kpi{background:#fff;border-radius:15px;padding:12px 6px;text-align:center;box-shadow:0 4px 14px #22375b0d}
.kpi b{display:block;font-size:19px;color:#1668d8;line-height:1.2;letter-spacing:.2px}
.kpi small{display:block;color:#8b98aa;font-size:10px;margin-top:3px}

.cov{display:flex;gap:9px;padding:9px 0;border-bottom:1px solid #f3f6fb;font-size:12px}
.cov:last-child{border-bottom:0}
.cov .dim{color:#a9b5c5;font-size:11px;width:20px;flex:0 0 auto;padding-top:1px}
.cov .body{flex:1;min-width:0}
.cov .t{color:#33455f;line-height:1.6}
.cov .r{color:#8b98aa;font-size:11px;line-height:1.6;margin-top:3px}
.cov .st{flex:0 0 auto;align-self:flex-start}

/* ---------- 工具条 / toast / lightbox ---------- */
.actions{display:flex;gap:8px;margin:0 14px 14px;flex-wrap:wrap}
.actions button{
  flex:1;min-width:120px;border:1px solid #e6ecf5;background:#fff;color:#41546e;
  border-radius:12px;padding:11px;font-size:12px;font-weight:600;
}
.actions button.primary{border-color:transparent;background:linear-gradient(135deg,#3d9bff,#1668d8);color:#fff}
.actions button:active{opacity:.82}
#toast{
  position:fixed;left:50%;bottom:110px;transform:translate(-50%,14px);z-index:30;
  background:#16233aeb;color:#fff;font-size:12px;padding:10px 16px;border-radius:20px;
  opacity:0;pointer-events:none;transition:.22s;max-width:80vw;text-align:center;line-height:1.5;
}
#toast.on{opacity:1;transform:translate(-50%,0)}
.hidden{display:none!important}
