/* わんこの台所ツール：テーマと衝突しないよう .wd-root の中だけに効かせる */
.wd-root{--wd-surface:#fff;--wd-bg:#f3f7f5;--wd-ink:#1d2b34;--wd-muted:#56666e;--wd-line:#cbd8d3;--wd-green:#2f6e5c;--wd-green-soft:#dcebe5;--wd-yolk:#e9a81e;--wd-yolk-soft:#fbefd2;--wd-warn:#b3263e;--wd-warn-soft:#f8e3e7;--wd-fridge:#d7eedf;--wd-fridge-ink:#22553f;--wd-freezer:#d8e8f7;--wd-freezer-ink:#1e4a73;--wd-slate:#4f5f80;--wd-slate-soft:#e6eaf3;
  color:var(--wd-ink);line-height:1.75;margin:1.5em 0}
.wd-root *,.wd-root *::before,.wd-root *::after{box-sizing:border-box}
.wd-root input,.wd-root select,.wd-root button{font:inherit;color:inherit}
.wd-root :focus-visible{outline:3px solid var(--wd-yolk);outline-offset:2px}
.wd-form{background:var(--wd-surface);border:1px solid var(--wd-line);border-radius:14px;padding:16px}
.wd-grid{display:grid;gap:12px;margin-bottom:8px}
@media (min-width:600px){.wd-grid{grid-template-columns:1fr 1fr}.wd-grid.wd-three{grid-template-columns:1fr 1fr 1fr}}
.wd-field label{display:block;font-size:.85em;color:var(--wd-muted);margin-bottom:4px}
.wd-field input[type=number],.wd-field select,.wd-planner select{width:100%;padding:8px 10px;border:1px solid var(--wd-line);border-radius:10px;background:var(--wd-bg);min-height:44px;margin:0}
.wd-check{display:flex;align-items:center;gap:8px;min-height:44px;font-size:.95em}
.wd-check input{width:20px;height:20px;margin:0;accent-color:var(--wd-green)}
.wd-hint{font-size:.78em;color:var(--wd-muted);margin-top:4px;line-height:1.5}
.wd-ratio-val{font-weight:700;color:var(--wd-ink);margin-left:4px}
.wd-root input[type=range]{width:100%;accent-color:var(--wd-green);margin:6px 0 0}
.wd-scale{display:flex;justify-content:space-between;font-size:.75em;color:var(--wd-muted)}
.wd-err{color:var(--wd-warn)}
.wd-result{margin-top:14px;background:var(--wd-surface);border:1px solid var(--wd-line);border-radius:14px;padding:16px}
.wd-big{display:flex;gap:18px;flex-wrap:wrap;align-items:flex-end}
.wd-num{font-size:2em;font-weight:700;line-height:1.1}
.wd-num small{font-size:.5em;margin-left:2px;font-weight:500}
.wd-lab{font-size:.82em;color:var(--wd-muted)}
.wd-bar{display:flex;height:12px;border-radius:999px;overflow:hidden;background:var(--wd-line);margin-top:12px}
.wd-kib{background:var(--wd-green)}.wd-top{background:var(--wd-yolk)}
.wd-basis{font-size:.8em;color:var(--wd-muted);margin-top:8px}
.wd-note{margin-top:8px;padding:8px 12px;border-radius:10px;font-size:.88em;background:var(--wd-green-soft)}
.wd-note.wd-warn{background:var(--wd-warn-soft)}
.wd-h{margin:1.6em 0 .3em;font-size:1.15em}
.wd-sub{color:var(--wd-muted);font-size:.92em;margin:0 0 10px;display:block}
.wd-cats{display:flex;gap:6px;flex-wrap:wrap;margin:6px 0 10px}
.wd-cat{min-height:40px;padding:6px 16px;border:1px solid var(--wd-line);border-radius:999px;background:var(--wd-surface);color:var(--wd-ink);font-size:.95em;cursor:pointer}
.wd-cat[aria-pressed="true"]{background:var(--wd-green);border-color:var(--wd-green);color:#fff;font-weight:700}
.wd-more-wrap{display:flex;align-items:center;gap:10px;margin:12px 0 4px}
.wd-more{min-height:40px;padding:6px 16px;border:1px solid var(--wd-green);border-radius:999px;background:var(--wd-green-soft);color:var(--wd-ink);font-weight:700;cursor:pointer}
.wd-more[hidden]{display:none}
.wd-more-count{font-size:.85em;color:var(--wd-muted)}
.wd-root .wd-recipe .wd-toplan{justify-self:start;margin-top:8px;min-height:40px;padding:8px 16px;border:2px solid var(--wd-green);border-radius:999px;background:var(--wd-green-soft);color:#1f4f42;font-size:.9em;font-weight:700;cursor:pointer;line-height:1.3;box-shadow:none;text-shadow:none}
.wd-root .wd-recipe .wd-toplan:hover,.wd-root .wd-recipe .wd-toplan:focus-visible{background:#c6e0d6;color:#1f4f42}
.wd-hint{margin-top:4px;font-size:.85em;color:var(--wd-green);font-weight:700}
.wd-recipes{border-top:1px solid var(--wd-line)}
.wd-rhead{display:flex;gap:12px;align-items:center}
.wd-rimg{width:120px;height:80px;object-fit:cover;border-radius:8px;flex:none;pointer-events:none}
.wd-imgnote{font-size:.72em;color:var(--wd-muted);margin-top:2px}
.wd-recipe{padding:14px 0;border-bottom:1px solid var(--wd-line);display:grid;gap:4px}
@media (min-width:600px){.wd-recipe{grid-template-columns:1fr 150px;column-gap:16px;align-content:start}.wd-recipe .wd-amt{text-align:right;grid-row:1;grid-column:2}.wd-recipe>*:not(.wd-rhead):not(.wd-amt){grid-column:1 / -1}}
/* PCでは2列のカード表示（スマホは1列のまま） */
@media (min-width:900px){.wd-recipes{display:grid;grid-template-columns:1fr 1fr;gap:16px;border-top:0;padding-top:4px}.wd-recipe{border:1px solid var(--wd-line);border-radius:12px;padding:14px 16px;grid-template-columns:1fr auto}.wd-recipe .wd-amt{min-width:96px}}
.wd-kind{font-size:.78em;font-weight:700;color:var(--wd-green)}
.wd-kind.wd-snack{color:#9a6a00}
.wd-rname{font-weight:700;font-size:1.05em}
.wd-parts{font-size:.88em}
.wd-steps{font-size:.92em;margin:0}
.wd-meta{font-size:.85em;color:var(--wd-muted);margin:4px 0 0}
.wd-warn-text{color:var(--wd-warn)}
.wd-off{color:var(--wd-muted);font-size:.9em}
.wd-planner{background:var(--wd-surface);border:1px solid var(--wd-line);border-radius:14px;padding:16px}
.wd-days{display:flex;gap:6px;flex-wrap:wrap;margin:12px 0 4px}
.wd-day{min-width:44px;min-height:40px;border:1px solid var(--wd-line);border-radius:10px;background:var(--wd-bg);cursor:pointer;padding:0 8px}
.wd-day[aria-pressed="true"]{background:var(--wd-ink);color:#fff;border-color:var(--wd-ink)}
.wd-day:disabled{opacity:.35;cursor:not-allowed}
.wd-tray{display:flex;flex-wrap:wrap;gap:8px;background:var(--wd-bg);border-radius:14px;padding:10px;margin-top:10px}
.wd-cube{width:64px;min-height:64px;border-radius:12px;display:flex;flex-direction:column;align-items:center;justify-content:center;font-size:.72em;line-height:1.3;box-shadow:inset 0 -3px 0 rgba(0,0,0,.08)}
.wd-g{font-size:1.4em;font-weight:700}
.wd-fridge{background:var(--wd-fridge);color:var(--wd-fridge-ink)}
.wd-freezer{background:var(--wd-freezer);color:var(--wd-freezer-ink)}
.wd-legend{display:flex;gap:16px;font-size:.82em;color:var(--wd-muted);margin-top:8px;flex-wrap:wrap}
.wd-legend span::before{content:"";display:inline-block;width:12px;height:12px;border-radius:4px;margin-right:6px;vertical-align:-1px}
.wd-lf::before{background:var(--wd-fridge)}.wd-lz::before{background:var(--wd-freezer)}
.wd-shop{margin-top:10px;font-size:.95em}
.wd-shop ul{margin:6px 0 0;padding-left:1.2em}
.wd-table-wrap{overflow-x:auto}
.wd-table{border:none;border-collapse:collapse;width:100%;min-width:420px;background:var(--wd-surface);font-size:.95em;margin:0}
.wd-table th,.wd-table td{padding:8px 10px;border:none;border-bottom:1px solid var(--wd-line);text-align:right;white-space:nowrap}
.wd-table th:first-child,.wd-table td:first-child{text-align:left}
.wd-table thead th{background:var(--wd-green-soft);font-size:.85em}
.wd-mini-out{margin-top:12px;padding-top:12px;border-top:1px dashed var(--wd-line)}
.wd-root .wd-search{width:100%;padding:10px 12px;border:1px solid var(--wd-line);border-radius:12px;background:var(--wd-surface);min-height:48px}
.wd-res{margin-top:10px;padding:10px 14px;border-radius:12px;font-size:.95em}
.wd-res.wd-ng{background:var(--wd-warn-soft);border-left:4px solid var(--wd-warn)}
.wd-res.wd-caution{background:var(--wd-yolk-soft);border-left:4px solid var(--wd-yolk)}
.wd-res.wd-ok{background:var(--wd-green-soft);border-left:4px solid var(--wd-green)}
.wd-res.wd-unknown{background:var(--wd-surface);border:1px solid var(--wd-line)}
.wd-chips{display:flex;flex-wrap:wrap;gap:6px;margin-top:10px;align-items:center}
.wd-chips-lab{font-size:.8em;color:var(--wd-muted);width:100%}
.wd-chip{min-height:36px;padding:4px 12px;border:1px solid var(--wd-line);border-radius:999px;background:var(--wd-surface);color:var(--wd-ink);font-size:.9em;cursor:pointer;line-height:1.4}
.wd-chip:hover{background:var(--wd-green-soft);border-color:var(--wd-green)}
.wd-res-more{margin:10px 0 0;font-size:.9em}
.wd-res-more a{color:var(--wd-green);font-weight:700}
.wd-res-title{margin-left:.5em;font-weight:700}
.wd-res-dl{margin:10px 0 0;padding:0}
.wd-res-dl dt{font-weight:700;font-size:.88em;margin-top:8px}
.wd-res-dl dd{margin:2px 0 0;padding:0}
.wd-res-src{margin-top:10px;padding-top:8px;border-top:1px solid var(--wd-line);font-size:.82em;color:var(--wd-muted)}
.wd-res-src ul{margin:4px 0 0;padding-left:1.2em}
.wd-res-src a{color:var(--wd-green);word-break:break-word}
.wd-admin-error{padding:8px 12px;border:1px dashed #b3263e;color:#b3263e;font-size:.9em}

/* v0.3.8 収録数 */
.wd-counts{display:flex;flex-wrap:wrap;gap:6px;margin:0 0 12px}
.wd-count{display:inline-flex;align-items:baseline;gap:2px;padding:4px 12px;border-radius:999px;font-size:.85em;line-height:1.5}
.wd-count b{font-size:1.25em;margin-left:4px}
.wd-count.wd-ok{background:var(--wd-green-soft);color:#1f4f42}
.wd-count.wd-caution{background:var(--wd-yolk-soft);color:#6b4a07}
.wd-count.wd-ng{background:var(--wd-warn-soft);color:var(--wd-warn)}

/* v0.3.12 活動量のヘルプリンク */
.wd-help{margin-left:8px;font-size:.85em;font-weight:normal}

/* v0.4.0：おすすめしません（4段階目） */
.wd-res.wd-notrec{background:var(--wd-slate-soft);border-left:4px solid var(--wd-slate)}
.wd-count.wd-notrec{background:var(--wd-slate-soft);color:var(--wd-slate)}
/* v0.4.0：この端末への保存 */
.wd-store{margin:10px 0 0;font-size:.8em;color:var(--wd-muted);line-height:1.6}
.wd-store-clear{margin-left:4px;padding:2px 10px;min-height:32px;border:1px solid var(--wd-line);border-radius:999px;background:var(--wd-bg);cursor:pointer;font-size:1em}
.wd-store-clear[hidden]{display:none}
/* v0.4.1：あわせて確認 */
.wd-rel{margin-top:10px}
.wd-rel-lab{margin:0 0 4px;font-size:.82em;font-weight:700;color:var(--wd-muted)}
.wd-rel-item{margin-top:6px;border:1px solid var(--wd-line);border-radius:12px;background:var(--wd-surface);font-size:.92em}
.wd-rel-item summary{cursor:pointer;padding:8px 12px;min-height:44px;display:flex;align-items:center;gap:8px;list-style:none}
.wd-rel-item summary::-webkit-details-marker{display:none}
.wd-rel-item summary::after{content:'＋';margin-left:auto;color:var(--wd-muted)}
.wd-rel-item[open] summary::after{content:'－'}
.wd-rel-body{padding:0 12px 10px}
.wd-tag{display:inline-block;padding:1px 8px;border-radius:999px;font-size:.8em;font-weight:700;white-space:nowrap}
.wd-rel-item.wd-ng .wd-tag{background:var(--wd-warn-soft);color:var(--wd-warn)}
.wd-rel-item.wd-notrec .wd-tag{background:var(--wd-slate-soft);color:var(--wd-slate)}
.wd-rel-item.wd-caution .wd-tag{background:var(--wd-yolk-soft);color:#6b4a07}
.wd-rel-item.wd-ok .wd-tag{background:var(--wd-green-soft);color:#1f4f42}
/* v0.4.2：必ず守ってほしい一点（warn） */
.wd-warn{margin:10px 0 0;padding:6px 10px;border-radius:8px;background:#fff;border:2px solid var(--wd-warn);color:var(--wd-warn);font-weight:700}
/* v0.5.0：栄養表 */
.wd-nut{margin-top:16px;padding:14px 16px;border:1px solid var(--wd-line);border-radius:14px;background:var(--wd-surface)}
.wd-nut-title{margin:0 0 8px;font-weight:700}
.wd-nut-table th{text-align:left;font-weight:600;white-space:nowrap}
.wd-nut-table td{text-align:right;white-space:nowrap}
.wd-nut-table .wd-sub-row th{padding-left:1.6em;font-weight:400;color:var(--wd-muted)}
.wd-nut-sub{margin:14px 0 6px;font-size:.88em;font-weight:700}
.wd-nut-hi{list-style:none;margin:0;padding:0}
.wd-nut-hi li{display:flex;align-items:center;gap:10px;padding:6px 0;border-bottom:1px dashed var(--wd-line)}
.wd-nut-name{font-weight:600}
.wd-nut-rank{padding:1px 8px;border-radius:999px;background:var(--wd-green-soft);color:#1f4f42;font-size:.8em;font-weight:700}
.wd-nut-val{margin-left:auto;color:var(--wd-muted);font-size:.92em}
.wd-nut-note{margin:10px 0 0;font-size:.9em}
/* v0.5.0：早見表の「うちの子」の行 */
.wd-table tr.wd-mine td{background:var(--wd-yolk-soft);font-weight:700}
.wd-mine-tag{margin-left:6px;padding:1px 6px;border-radius:999px;background:var(--wd-yolk);color:#fff;font-size:.75em;vertical-align:1px}
.wd-nut-table{min-width:0}

/* ごはんを食べないときのチェック（v0.6.0）。計算ツールと同じ色・部品（.wd-form、.wd-cat、.wd-more、.wd-res、.wd-recipe）を使い、足りない部分だけここで定義する */
.wd-g-bar{margin:0 0 12px;height:8px}
.wd-g-stage{display:grid;gap:14px}
.wd-g-card{display:grid;gap:10px}
.wd-root .wd-g-q{margin:0;font-size:1.15em;font-weight:700;line-height:1.5}
.wd-root .wd-g-card .wd-sub{margin:0}
.wd-g-list{margin:0;padding-left:1.3em}
.wd-g-list li{margin:2px 0}
.wd-g-opts{display:grid;gap:8px}
.wd-g-yn{grid-template-columns:1fr 1fr}
@media (max-width:420px){.wd-g-yn{grid-template-columns:1fr}}
.wd-root .wd-g-opt{display:block;width:100%;min-height:48px;margin:0;padding:10px 14px;text-align:left;border:1px solid var(--wd-line);border-radius:10px;background:var(--wd-bg);color:var(--wd-ink);font-weight:500;line-height:1.5;cursor:pointer;box-shadow:none;text-shadow:none}
.wd-root .wd-g-opt small{display:block;font-size:.82em;color:var(--wd-muted)}
.wd-root .wd-g-opt:hover,.wd-root .wd-g-opt:focus-visible{background:var(--wd-green-soft);border-color:var(--wd-green);color:var(--wd-ink)}
.wd-root .wd-g-card .wd-cats{margin:0}
.wd-g-row{display:flex;flex-wrap:wrap;gap:10px;justify-content:space-between;align-items:center}
.wd-root .wd-g-row .wd-more{margin:0}
.wd-root .wd-g-back{min-height:40px;margin:0;padding:6px 16px;border:1px solid var(--wd-line);border-radius:999px;background:var(--wd-surface);color:var(--wd-ink);font-size:.95em;cursor:pointer;box-shadow:none;text-shadow:none}
.wd-g-result{display:grid;gap:12px}
.wd-root .wd-g-result .wd-res{margin:0}
.wd-root .wd-g-title{margin:6px 0 4px;font-size:1.1em;font-weight:700;line-height:1.5}
.wd-root .wd-g-p{margin:0}
.wd-res.wd-ok .wd-tag{background:var(--wd-surface);color:#1f4f42}
.wd-res.wd-caution .wd-tag{background:var(--wd-surface);color:#6b4a07}
.wd-res.wd-notrec .wd-tag{background:var(--wd-surface);color:var(--wd-slate)}
.wd-root .wd-g-result .wd-warn,.wd-root .wd-g-result .wd-note{margin:0}
.wd-g-sec{display:grid;gap:4px}
.wd-root .wd-g-result .wd-h{margin:.6em 0 0}
.wd-root .wd-g-result .wd-sub{margin:0}
.wd-root .wd-g-result .wd-res-more{margin:0}
/* v0.6.1：お助けナビへの入口（食材図鑑・計算ツール） */
.wd-root .wd-golink{margin:12px 0 0;padding:10px 14px;border-radius:12px;background:var(--wd-yolk-soft);font-size:.92em;line-height:1.6}
.wd-root .wd-golink a{color:var(--wd-green);font-weight:700}
.wd-golink-wrap{margin:1em 0}
/* v0.6.2：機能の入口カード */
.wd-menu{display:grid;gap:10px}
@media (min-width:760px){.wd-menu{grid-template-columns:repeat(3,1fr)}}
.wd-root .wd-menu-card{display:grid;align-content:start;gap:4px;padding:14px 16px;border:1px solid var(--wd-line);border-radius:14px;background:var(--wd-surface);color:var(--wd-ink);text-decoration:none;box-shadow:none;transition:border-color .15s,background .15s}
.wd-root .wd-menu-card:hover,.wd-root .wd-menu-card:focus-visible{border-color:var(--wd-green);background:var(--wd-green-soft);color:var(--wd-ink)}
.wd-menu-name{font-weight:700;font-size:1.05em;color:var(--wd-green);line-height:1.4}
.wd-menu-lead{font-size:.88em;color:var(--wd-muted);line-height:1.6}
.wd-menu-go{margin-top:4px;font-size:.88em;font-weight:700;color:var(--wd-green)}
.wd-root .wd-menu-cur{background:var(--wd-bg)}
.wd-menu-cur .wd-menu-go{color:var(--wd-muted)}
@media (prefers-reduced-motion:reduce){.wd-root .wd-menu-card{transition:none}}
#wd-calc{scroll-margin-top:72px}  /* 固定ヘッダーの下に隠れないように */
/* v0.6.3：入口カードの1行目に悩みの一言 */
.wd-menu-worry{font-weight:700;font-size:1.05em;line-height:1.5;color:var(--wd-ink)}
.wd-menu-worry+.wd-menu-name{margin-top:6px;font-size:.92em}
.wd-root .wd-menu-card{display:flex;flex-direction:column}
.wd-menu-go{margin-top:auto;padding-top:8px}
.wd-root .wd-cats{scroll-margin-top:72px}  /* v0.7.1：固定ヘッダーの下に隠れないように */

/* v0.8.0 NG食材チェッカー：犬用なら、こんなレシピ */
.wd-root .wd-alt{margin-top:12px;padding:12px;border-radius:14px;background:var(--wd-green-soft,#eef6ef);border:1px solid var(--wd-line)}
.wd-root .wd-alt-lab{margin:0 0 8px;font-size:.88em;font-weight:700;color:var(--wd-green)}
.wd-root .wd-alt-card{padding:10px 12px;border-radius:12px;background:var(--wd-surface);border:1px solid var(--wd-line)}
.wd-root .wd-alt-card+.wd-alt-card{margin-top:8px}
.wd-root .wd-alt-name{font-weight:700}
.wd-root .wd-alt-tag{display:inline-block;margin-top:4px;padding:2px 8px;border-radius:999px;font-size:.78em;background:var(--wd-yolk-soft,#fff4d6);color:var(--wd-ink,#333)}
.wd-root .wd-alt-parts{margin:6px 0;font-size:.86em;color:var(--wd-muted)}
.wd-root .wd-alt-go{display:inline-flex;align-items:center;min-height:44px;font-weight:700;color:var(--wd-green);text-decoration:underline;text-underline-offset:3px}
/* v0.8.0 計算ツール：リンクで開いたレシピを目立たせる */
.wd-root .wd-recipe{scroll-margin-top:72px}
.wd-root .wd-recipe.wd-recipe-focus{outline:3px solid var(--wd-yolk);outline-offset:4px;border-radius:12px}
/* v0.9.2：トッピングの割合が0％のときの案内（レシピ欄・まとめて作る） */
.wd-root .wd-zero{margin-top:0;padding:12px 14px;line-height:1.7}
.wd-root .wd-zero-btn{display:block;margin-top:8px;min-height:40px;padding:8px 16px;border:2px solid var(--wd-green);border-radius:999px;background:#fff;color:#1f4f42;font-size:1em;font-weight:700;cursor:pointer;line-height:1.3;box-shadow:none;text-shadow:none}
.wd-root .wd-zero-btn:hover,.wd-root .wd-zero-btn:focus-visible{background:#c6e0d6}
