/* ===== BMI 計算頁（版型併自 toolboy_bmi 設計稿）=====
   頁首/頁尾使用共用母版（layout.js 注入、style.css 樣式），
   其餘選擇器全部掛在 body.bmi-page 底下，避免與其他頁互相影響。 */
body.bmi-page{--ink:#10203a;--muted:#68758a;--line:#dfe7ef;--brand:#ffbd24;--brand2:#ffd86b;--green:#22b66f;--green2:#e9fbf1;--blue:#62b9ed;--red:#ff776d;--paper:#fff;--soft:#f7fafc;--shadow:0 16px 45px rgba(20,45,80,.08);--radius:22px;margin:0;font-family:"Noto Sans TC","PingFang TC","Microsoft JhengHei",system-ui,sans-serif;color:var(--ink);background:#fff}
.bmi-page .bmi-hero{padding-top:20px}
.bmi-page button,.bmi-page input,.bmi-page select{font:inherit}
.bmi-page main a{color:inherit;text-decoration:none}
.bmi-page .hidden{display:none!important}

/* --- Hero：麵包屑（左）＋分類徽章（右）＋標題 --- */
.bmi-page .bmi-hero{padding:34px 0 18px}
.bmi-page .crumb-row{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:18px}
.bmi-page .crumb{display:flex;gap:8px;font-size:14px;color:var(--muted)}
.bmi-page .crumb a{color:#2563eb;font-weight:700}
.bmi-page .crumb a:hover{text-decoration:underline}
.bmi-page .tag{display:inline-flex;background:#fff3cf;color:#9b6700;padding:7px 13px;border-radius:999px;font-weight:800;font-size:13px}
.bmi-page h1{font-size:40px;line-height:1.2;margin:18px 0 8px;letter-spacing:-.03em}
.bmi-page .lead{color:var(--muted);font-size:16px}

/* --- 計算器版面 --- */
.bmi-page .calculator-grid{display:grid;grid-template-columns:.86fr 1.55fr;gap:22px;margin-top:30px}
.bmi-page .card{background:var(--paper);border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow)}
.bmi-page .input-card{padding:24px}
.bmi-page .tabs{display:grid;grid-template-columns:1fr 1fr;border:1px solid var(--line);border-radius:13px;overflow:hidden;margin-bottom:22px}
.bmi-page .tab{border:0;padding:13px;background:#fff;font-weight:900;cursor:pointer}
.bmi-page .tab.active{background:linear-gradient(135deg,var(--brand),var(--brand2))}
.bmi-page .field{margin:18px 0}
.bmi-page .field label{display:block;font-weight:900;margin-bottom:9px}
.bmi-page .input-shell{display:flex;align-items:center;border:1px solid #cfdae5;border-radius:12px;overflow:hidden;background:#fff}
.bmi-page .input-shell .ico{width:46px;text-align:center;font-size:22px}
.bmi-page .input-shell input{width:100%;border:0;outline:0;padding:14px 12px;font-size:18px}
.bmi-page .unit{padding:0 14px;color:#34445c;font-weight:800}
.bmi-page .subnote{font-size:13px;color:#8a95a6;margin:7px 0 0 47px}
.bmi-page .duo{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.bmi-page .seg{display:flex;gap:10px}
.bmi-page .seg button{flex:1;padding:11px 8px;border:1px solid var(--line);background:#fff;border-radius:11px;font-weight:900;cursor:pointer}
.bmi-page .seg button.active{background:#fff0bd;border-color:#f2c44d}
.bmi-page .input-card select{width:100%;padding:13px;border:1px solid var(--line);border-radius:11px;background:#fff}
.bmi-page .actions{display:grid;grid-template-columns:1.3fr .8fr;gap:10px;margin-top:24px}
.bmi-page .primary,.bmi-page .secondary{border:0;border-radius:12px;padding:14px;font-weight:900;cursor:pointer}
.bmi-page .primary{background:linear-gradient(135deg,var(--brand),#ffd65e)}
.bmi-page .secondary{background:#fff;border:1px solid var(--line)}
.bmi-page .disclaimer{font-size:12px;color:#718197;margin-top:14px}

/* --- 結果卡片 --- */
.bmi-page .result-card{overflow:hidden;border-color:#bde8cf;background:linear-gradient(180deg,#f2fff7,#fff)}
.bmi-page .result-top{min-height:310px;padding:28px 32px;position:relative;background:linear-gradient(180deg,#effcf5,#e7f8df)}
.bmi-page .result-value{font-size:68px;line-height:1;color:#15a866;font-weight:950;margin:6px 0}
.bmi-page .status-pill{display:inline-block;background:#1fb76c;color:#fff;padding:8px 16px;border-radius:10px;font-weight:900}
.bmi-page .speech{position:absolute;left:40%;top:62px;background:#fff;border:1px solid #dfe8e3;border-radius:50%;padding:24px 28px;text-align:center;font-weight:900;line-height:1.65;box-shadow:0 10px 30px rgba(0,0,0,.06)}
.bmi-page .mascot{position:absolute;right:16px;bottom:0;width:260px;max-height:250px;object-fit:contain;mix-blend-mode:multiply}
.bmi-page .result-bottom{padding:24px 28px 28px}
.bmi-page .scale-labels{display:flex;justify-content:space-between;font-weight:800;color:#5d6978;font-size:14px}
.bmi-page .scale{position:relative;height:12px;border-radius:999px;margin:12px 0 4px;background:linear-gradient(90deg,#66bdf0 0 28%,#25be77 28% 58%,#ffc447 58% 76%,#ff7f72 76%)}
.bmi-page .pointer{position:absolute;top:50%;left:45%;width:24px;height:24px;background:#17aa64;border:4px solid #fff;border-radius:50%;transform:translate(-50%,-50%);box-shadow:0 3px 10px rgba(0,0,0,.15);transition:left .45s}
.bmi-page .ticks{display:flex;justify-content:space-around;color:#657487;font-size:13px;margin-bottom:22px}
.bmi-page .result-info{display:grid;grid-template-columns:repeat(3,1fr);gap:14px}
.bmi-page .mini{padding:20px;border:1px solid var(--line);border-radius:15px;background:#fff}
.bmi-page .mini h3{margin:0 0 8px}
.bmi-page .healthy{font-size:28px;color:#1aa766;font-weight:950}
.bmi-page .waist{margin:6px 0 0;font-size:13px;color:#8a95a6}
.bmi-page .delta{margin-top:8px;padding:6px 10px;border-radius:9px;background:#f2fbf6;color:#1f7a4d;font-size:13px;font-weight:800}
.bmi-page .related-tools{margin-top:18px;color:var(--muted);font-size:14px}
.bmi-page .related-tools a{color:#2563eb;font-weight:700}
.bmi-page .related-tools a:hover{text-decoration:underline}

/* --- 特色列與內容區 --- */
.bmi-page .feature-strip{display:grid;grid-template-columns:repeat(4,1fr);gap:0;margin:26px 0;padding:20px 10px}
.bmi-page .feature{display:flex;gap:12px;align-items:center;padding:8px 22px;border-right:1px solid var(--line)}
.bmi-page .feature:last-child{border:0}
.bmi-page .feature .round{width:48px;height:48px;border-radius:50%;display:grid;place-items:center;background:#fff6d7;font-size:23px}
.bmi-page .bmi-block{padding:34px 0}
.bmi-page .section-title{text-align:center;font-size:30px;margin:0 0 26px}
.bmi-page .steps{display:grid;grid-template-columns:repeat(4,1fr);gap:16px}
.bmi-page .step{padding:23px;text-align:center;min-height:210px}
.bmi-page .step .num{width:30px;height:30px;border-radius:50%;display:grid;place-items:center;background:#28b875;color:#fff;font-weight:900;margin:0 auto 10px}
.bmi-page .step .emoji{font-size:54px;margin-top:18px}
.bmi-page .content-grid{display:grid;grid-template-columns:1fr 1fr;gap:22px}
.bmi-page .content-card{padding:26px}
.bmi-page .formula{background:#edf9eb;padding:14px 16px;border-radius:10px;color:#287248;font-weight:800}
.bmi-page .content-card table{width:100%;border-collapse:collapse;margin-top:16px}
.bmi-page .content-card td,.bmi-page .content-card th{border:1px solid var(--line);padding:11px;text-align:left}
.bmi-page .content-card details{border:1px solid var(--line);border-radius:11px;padding:13px 15px;margin-bottom:10px;background:#fff}
.bmi-page .content-card summary{font-weight:800;cursor:pointer}
.bmi-page .guide-art{width:170px;float:right;margin-top:8px;mix-blend-mode:multiply}
.bmi-page .keywords{display:flex;flex-wrap:wrap;gap:10px}
.bmi-page .keyword{padding:9px 14px;border:1px solid #bfe1cb;border-radius:999px;color:#277b4c;background:#fbfffc}
.bmi-page .backtop{position:fixed;right:24px;bottom:24px;width:48px;height:48px;border-radius:50%;border:1px solid #bfe7ce;background:#fff;color:#198c55;font-weight:900;cursor:pointer;z-index:30}

/* --- RWD --- */
@media (max-width:900px){
  .bmi-page .calculator-grid,.bmi-page .content-grid{grid-template-columns:1fr}
  .bmi-page .feature-strip,.bmi-page .steps{grid-template-columns:1fr 1fr}
  .bmi-page .result-top{min-height:330px}
  .bmi-page .speech{left:30%;top:85px}
  .bmi-page .mascot{width:220px}
}
@media (max-width:560px){
  .bmi-page h1{font-size:31px}
  .bmi-page .calculator-grid{margin-top:20px}
  .bmi-page .input-card{padding:18px}
  .bmi-page .result-top{padding:23px;min-height:360px}
  .bmi-page .result-value{font-size:58px}
  .bmi-page .speech{position:relative;left:auto;top:auto;width:62%;margin-top:18px;padding:16px}
  .bmi-page .mascot{width:180px;right:-8px}
  .bmi-page .result-info{grid-template-columns:1fr}
  .bmi-page .steps,.bmi-page .feature-strip{grid-template-columns:1fr}
  .bmi-page .feature{border-right:0;border-bottom:1px solid var(--line)}
  .bmi-page .feature:last-child{border-bottom:0}
  .bmi-page .crumb-row{flex-wrap:wrap}
}
