:root {
  color-scheme: light;
  --paper: #f8f7f1;
  --surface: #fffefb;
  --sidebar: #f0f1e8;
  --ink: #24392f;
  --green: #254b3b;
  --green-hover: #173e2e;
  --muted: #53655b;
  --line: #dedfd3;
  --soft-line: #e8e7dd;
  --selected: #dfe8db;
  --heading: "Songti TC", "Noto Serif TC", "PMingLiU", serif;
  --body: Geist, "PingFang TC", "Noto Sans TC", "Microsoft JhengHei", sans-serif;
  font-family: var(--body);
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}

* { box-sizing: border-box; }
body { margin: 0; font-size: 15px; line-height: 1.65; }
h1, h2, h3, p { margin: 0; }
h1 { font: 800 clamp(2rem, 3.4vw, 3.35rem)/1.19 var(--heading); letter-spacing: -.065em; }
h2 { font-size: 1.35rem; line-height: 1.35; letter-spacing: -.025em; }
h3 { font-size: 1.2rem; line-height: 1.34; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
button, select, input { -webkit-tap-highlight-color: transparent; }
button, a { touch-action: manipulation; }
a, button, input, select { outline-offset: 4px; }
:focus-visible { outline: 2px solid #48745c; }
main:focus { outline: none; }
img { display: block; max-width: 100%; }
.icon { display: inline-block; width: 20px; height: 20px; flex: none; vertical-align: middle; }
.sr-only, .skip-link:not(:focus) { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.skip-link:focus { position: fixed; z-index: 30; top: 10px; left: 10px; padding: 10px 16px; background: white; border-radius: 8px; }
.muted { color: var(--muted); }
.nowrap { white-space: nowrap; }
.text-button, .button, .icon-button { font-weight: 650; display: inline-flex; align-items: center; justify-content: center; gap: 7px; vertical-align: middle; line-height: 1.3; min-height: 44px; border: 1px solid transparent; }
.button { border-radius: 11px; padding: 0 15px; white-space: nowrap; }
.button .icon, .text-button .icon { height: 17px; width: 17px; }
.primary { background: var(--green); color: #fff; }
.primary:hover { background: var(--green-hover); }
.secondary { background: var(--surface); border-color: var(--line); }
.secondary:hover { background: #eff2ea; border-color: #c3cdbf; }
.plain, .text-button { background: transparent; color: var(--green); }
.plain:hover, .text-button:hover { text-decoration: underline; text-underline-offset: 4px; }
.text-button { padding: 0; }
.icon-button { width: 44px; padding: 0; border-radius: 12px; background: transparent; }
.icon-button:hover { background: #ecefe5; }
.is-saved .icon { fill: #c6dcc2; stroke: var(--green); }
.kicker { display: flex; align-items: center; gap: 8px; color: var(--green); font-size: .83rem; font-weight: 700; letter-spacing: .08em; }
.kicker .icon { color: #80551b; width: 17px; height: 17px; }
.kicker span { width: 8px; height: 8px; background: #b18a48; border-radius: 50%; }

.brand { width: fit-content; display: flex; align-items: center; gap: 11px; }
.brand-mark { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 14px; background: var(--green); color: #f6f5e8; flex-shrink: 0; }
.brand-mark .icon { width: 24px; height: 24px; }
.brand strong { display: block; font: 800 1.25rem/1.28 var(--heading); letter-spacing: .04em; }
.brand small { display: block; font-size: .68rem; line-height: 1.55; color: var(--muted); letter-spacing: .075em; font-weight: 550; }
.shell { --rail: 230px; min-height: 100svh; padding-left: var(--rail); }
.sidebar { position: fixed; inset: 0 auto 0 0; background: var(--sidebar); width: var(--rail); padding: 29px 19px 24px; border-right: 1px solid var(--line); display: flex; flex-direction: column; }
.sidebar .brand { margin: 0 8px; }
.desktop-nav { display: grid; gap: 6px; margin-top: 53px; }
.nav-link { display: flex; align-items: center; min-height: 48px; padding: 0 13px; gap: 12px; border-radius: 10px; color: var(--muted); font-size: .91rem; font-weight: 650; }
.nav-link:hover { background: #e8ede2; color: var(--green); }
.nav-link.active { background: var(--selected); color: #214b35; }
.nav-link.active::after { content: ""; width: 5px; height: 5px; border-radius: 50%; background: #42684d; margin-left: auto; }
.side-note { display: flex; align-items: center; gap: 10px; margin-top: auto; padding: 12px 10px 8px; background: #e8ebdf; border: 1px solid #dfe3d6; border-radius: 13px; }
.side-icon { display: grid; place-items: center; width: 34px; height: 34px; background: #f8f8f0; border-radius: 9px; color: #406047; flex-shrink: 0; }
.side-icon .icon { width: 17px; height: 17px; }
.side-note strong { display: block; font-size: .75rem; }
.side-note a { display: inline-flex; align-items: center; min-height: 32px; font-size: .72rem; color: var(--muted); }
.side-note a:hover { text-decoration: underline; }
.side-note a .icon { width: 12px; height: 12px; }
.topbar { min-height: 70px; padding: 0 clamp(24px,5vw,74px); display: flex; justify-content: space-between; align-items: center; gap: 12px; border-bottom: 1px solid var(--soft-line); background: #faf9f4; }
.breadcrumb { font-size: .86rem; font-weight: 650; color: var(--muted); }
.top-actions { display: flex; align-items: center; gap: 13px; }
.top-actions .text-button { font-size: .85rem; }
.avatar { display: grid; place-items: center; border: 1px solid #d8e0d3; width: 44px; height: 44px; border-radius: 50%; background: var(--selected); color: var(--green); }
.avatar:hover { background: #d0e0cc; }
.mobile-brand, .mobile-nav { display: none; }
.container { max-width: 1184px; margin: auto; padding: 38px clamp(24px,5vw,74px) 70px; }
.home-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 15px; margin-bottom: 34px; }
.home-heading h1 { margin: 8px 0 11px; }
.home-heading p:not(.kicker), .page-heading > p { color: var(--muted); }
.home-heading .button { flex-shrink: 0; }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 42px; margin-bottom: 10px; }
.section-heading > span { font-size: .83rem; font-weight: 600; color: var(--muted); text-align: right; }
.section-heading .text-button { font-size: .86rem; }
.feature-section .section-heading h2 { flex-shrink: 0; }
.feature-card { display: grid; grid-template-columns: 1.04fr 1fr; overflow: hidden; background: #ebefe2; border: 1px solid #dfe6d7; border-radius: 23px; min-height: 266px; }
.feature-copy { align-self: center; padding: clamp(22px, 3.15vw, 42px); }
.feature-label { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.pill { display: inline-flex; align-items: center; gap: 5px; line-height: 1.2; font-size: .75rem; font-weight: 700; border-radius: 30px; padding: 8px 11px; }
.pill .icon { width: 15px; height: 15px; }
.article-age { color: var(--ink); font-size: .78rem; font-weight: 650; }
.article-tags { display: inline-flex; align-items: center; gap: 4px; }
.article-tag { padding: 1px 6px; border: 1px solid var(--line); border-radius: 6px; color: var(--ink); font-size: .72rem; line-height: 1.45; }
.feature-copy h3 { font: 800 clamp(1.7rem, 2.65vw, 2.6rem)/1.23 var(--heading); letter-spacing: -.055em; margin: 13px 0 8px; }
.feature-copy p { color: #43584a; max-width: 34ch; }
.feature-actions { display: flex; flex-wrap: wrap; gap: 7px; align-items: center; margin-top: 18px; }
.feature-photo { width: 100%; height: 100%; object-fit: cover; object-position: center; aspect-ratio: 1.56; }
.feature-scene { display: grid; place-items: center; min-height: 190px; }
.feature-scene .icon { width: 92px; height: 92px; opacity: .8; stroke-width: 1.1; }
.more-section { margin-top: 25px; }
.resource-picks { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.resource-group + .resource-group { margin-top: 24px; }
.browse-section { margin-top: 29px; }
.card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 13px; }
.resource-card { padding: 15px 16px 8px; border: 1px solid var(--line); background: var(--surface); border-radius: 16px; min-width: 0; display: flex; flex-direction: column; }
.resource-card:hover { border-color: #b4c3b2; }
.card-top { display: flex; align-items: center; gap: 8px; margin-bottom: 9px; color: var(--muted); font-size: .75rem; font-weight: 700; }
.card-top .save-button { margin: 0 -5px 0 auto; }
.category-icon { display: grid; place-items: center; height: 39px; width: 39px; flex-shrink: 0; border-radius: 11px; }
.category-icon .icon { width: 20px; height: 20px; }
.mint { background: #dce8d8; color: #315741; }
.lavender { background: #eae3f2; color: #655073; }
.sand { background: #f5e8ca; color: #684f24; }
.rose { background: #f3e1de; color: #795153; }
.blue { background: #e1ebee; color: #3e5d68; }
.orange { background: #f6e2d4; color: #78462c; }
.resource-card h3 a:hover { text-decoration: underline; text-underline-offset: 4px; }
.resource-card p { flex: 1; margin-top: 5px; color: var(--muted); font-size: .87rem; line-height: 1.6; }
.card-meta { display: flex; align-items: center; gap: 5px; margin-top: 7px; color: var(--muted); font-size: .73rem; font-weight: 600; }
.card-details { display: flex; flex-wrap: wrap; gap: 3px 10px; }
.card-meta .icon { width: 15px; height: 15px; }
.card-meta a { min-width: 44px; min-height: 44px; margin-left: auto; display: grid; place-items: center; color: var(--green); border-radius: 10px; }
.card-meta a:hover { background: #eef2e9; }
.card-meta a .icon { width: 20px; height: 20px; }
.category-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.category-grid a { display: flex; align-items: center; gap: 9px; padding: 10px; border: 1px solid var(--line); border-radius: 13px; background: var(--surface); font-size: .83rem; }
.category-grid a:hover { border-color: #a8bda6; }
.category-grid a small { display: block; margin-top: 3px; color: var(--muted); font-size: .73rem; line-height: 1.4; }
.category-grid a > .icon { width: 15px; height: 15px; margin-left: auto; color: var(--muted); }

.page-heading { margin: 2px 0 26px; }
.page-heading h1 { margin-bottom: 9px; }
.filter-area { margin-bottom: 17px; }
.search-box { display: flex; align-items: center; gap: 12px; min-height: 52px; max-width: 570px; padding: 0 15px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; }
.search-box:focus-within { outline: 2px solid #48745c; outline-offset: 2px; }
.search-box input { flex: 1; width: 100%; min-height: 50px; border: 0; outline: none; background: transparent; font-size: 16px; }
.filter-chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 13px; }
.filter-chip { min-height: 44px; background: var(--surface); border: 1px solid var(--line); border-radius: 30px; padding: 0 12px; font-size: .82rem; font-weight: 650; }
a.filter-chip { display: inline-flex; align-items: center; }
.filter-chip[aria-pressed="true"], .filter-chip[aria-current="page"] { background: var(--selected); color: var(--green); border-color: #b6c7b5; }
.filter-chip:hover { border-color: #849d85; }
.result-count { margin-bottom: 9px; font-size: .86rem; color: var(--muted); }
.empty { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 40px 18px; text-align: center; border: 1px solid var(--line); border-radius: 20px; background: var(--surface); }
.empty > .icon { width: 34px; height: 34px; color: #56775d; margin-bottom: 4px; }
.empty p { color: var(--muted); }
.empty .button { margin-top: 6px; }
.article-page, .settings-list { max-width: 755px; }
.back-link { margin-bottom: 13px; }
.article-heading { padding: clamp(20px,5vw,43px); border-radius: 20px; background: #ebefe2; }
.article-heading h1 { margin: 10px 0 9px; }
.article-heading p { color: var(--muted); max-width: 42ch; }
.article-updated { margin-bottom: 8px; font-size: .88rem; }
.article-summary-link { margin-top: 14px; }
.resource-facts { margin: 16px 0 0; font-size: .9rem; }
.resource-facts > div { display: grid; grid-template-columns: 6.5em minmax(0, 1fr); gap: 4px 12px; padding: 8px 0; border-top: 1px solid #d4dece; }
.resource-facts dt { font-weight: 700; }
.resource-facts dd { margin: 0; overflow-wrap: anywhere; }
.official-links { display: grid; justify-items: start; }
.official-links a { display: flex; align-items: center; gap: 4px; min-height: 44px; color: var(--green); text-decoration: underline; text-underline-offset: 3px; }
.official-links .icon { width: 16px; height: 16px; }
.county-picker { margin-top: 10px; }
.county-picker label { display: block; margin-bottom: 6px; font-weight: 700; }
.county-picker > div { display: flex; flex-wrap: wrap; gap: 8px; }
.county-picker select { min-height: 44px; max-width: 100%; padding: 0 9px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); font-size: 16px; }
.county-entry { scroll-margin-top: 16px; }
.article-actions { display: flex; flex-wrap: wrap; gap: 7px; }
.back-to-top {
  position: fixed;
  z-index: 4;
  right: max(18px, env(safe-area-inset-right));
  bottom: 22px;
  color: var(--green);
  font-size: .85rem;
  box-shadow: 0 3px 12px #1e33251a;
}
.back-to-top[hidden] { display: none; }
.article-section { margin: 27px 0; }
.article-section h2 { margin-bottom: 9px; }
.article-section p, .source-panel p { color: var(--muted); }
.notes-section { padding: clamp(15px, 4vw, 24px); background: var(--surface); border: 1px solid var(--line); border-radius: 16px; }
.note-form { margin-top: 12px; }
.note-template-picker { border: 0; margin: 0 0 12px; padding: 0; min-inline-size: 0; }
.note-template-picker legend, .note-form label { padding: 0; font-weight: 650; }
.note-template-options { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 5px; }
.note-template-options .button[aria-pressed="true"] { background: var(--selected); border-color: var(--green); }
.note-form label { display: block; margin-bottom: 4px; }
.note-form textarea { display: block; width: 100%; min-height: 92px; padding: 11px; resize: vertical; font: inherit; font-size: 16px; color: inherit; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); }
.note-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 8px; }
.note-actions [hidden] { display: none; }
.note-list-title { margin-top: 17px; font-size: 1rem; }
.note-list { list-style: none; padding: 0; margin: 6px 0 0; }
.note-list li { border-top: 1px solid var(--line); padding: 12px 0 0; }
.note-list time { font-size: .8rem; font-weight: 700; color: var(--muted); }
.note-list li p { color: var(--ink); white-space: pre-wrap; overflow-wrap: anywhere; }
.notes-empty { margin-top: 12px; }
.article-body { padding-inline: 3px; }
.article-part { padding: 20px 0; border-bottom: 1px solid var(--line); }
.article-part h2 { font-size: 1.2rem; margin-bottom: 6px; }
.article-part p + p { margin-top: 9px; }
.article-list { margin: 8px 0 0; padding-inline-start: 1.5em; }
.article-list li + li { margin-top: 9px; }
.article-list li::marker { color: var(--green); font-weight: 700; }
.article-part a { color: var(--green); text-decoration: underline; text-underline-offset: 3px; overflow-wrap: anywhere; }
.article-evidence {
  margin-block-start: 14px;
  padding-inline-start: 14px;
  border-inline-start: 3px solid var(--green);
  color: var(--muted);
  font-size: .9rem;
}
.article-experiences { display: grid; gap: 8px; margin-top: 14px; }
.article-experience { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.article-experience summary { display: list-item; padding: 12px 14px; color: var(--green); cursor: pointer; }
.article-experience summary:hover .experience-title { text-decoration: underline; text-underline-offset: 3px; }
.experience-title { font-weight: 700; }
.experience-preview { display: block; margin-top: 4px; color: var(--muted); font-size: .9rem; }
.article-experience:not([open]) .experience-preview { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.experience-detail { padding: 0 14px 12px; font-size: .9rem; }
.experience-detail a { display: inline-flex; align-items: center; gap: 4px; min-height: 44px; }
.experience-detail a .icon { width: 16px; height: 16px; }
.county-entry { display: block; }
.article-part p + p .county-entry { padding-top: 12px; border-top: 1px solid var(--soft-line); }
.county-name { color: var(--ink); font-size: 1.03rem; }
.county-budget { display: inline-block; margin-inline-start: .6em; color: var(--muted); font-size: .88rem; }
.county-benefit { display: grid; grid-template-columns: 3.1em minmax(0, 1fr); gap: .45em; margin-top: .3em; }
.county-benefit > strong { color: var(--green); }
.county-links { display: block; margin-top: .35em; padding-inline-start: 4.18em; font-size: .85em; }
.article-related { padding-inline: 3px; }
.article-related ul { margin: 0; padding: 0; list-style: none; }
.article-related li + li { border-top: 1px solid var(--line); }
.article-related .text-button { text-align: left; justify-content: flex-start; }
.source-panel { margin-top: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 15px; }
.source-panel-toggle { display: flex; align-items: center; gap: 8px; min-height: 50px; padding: 8px 17px; border-radius: 14px; list-style: none; font-weight: 700; cursor: pointer; }
.source-panel-toggle::-webkit-details-marker { display: none; }
.source-panel-toggle:hover { background: #eff2ea; }
.source-panel-toggle .icon { margin-inline-start: auto; color: var(--green); transform: rotate(90deg); }
.source-panel[open] > .source-panel-toggle .icon { transform: rotate(-90deg); }
.source-count { color: var(--muted); font-size: .8rem; font-weight: 400; }
.source-panel-content { padding-inline: 17px; }
.source-panel-content > .article-source-links { border-top: 1px solid var(--line); }
.article-source-links { list-style: none; padding: 0; margin: 0; }
.article-source-links li + li { border-top: 1px solid var(--line); }
.article-source-link { display: flex; flex-direction: column; justify-content: center; min-height: 44px; padding: 6px 0; color: var(--green); font-size: .9rem; font-weight: 650; overflow-wrap: anywhere; }
.article-source-link:hover > span { text-decoration: underline; text-underline-offset: 3px; }
.article-source-link .icon { width: 15px; height: 15px; margin-inline-start: 2px; }
.article-source-link .source-authors { font-weight: 400; }
.source-panel .source-details { margin-top: 0; border-top: 1px solid var(--line); }
.source-panel .source-details summary { display: list-item; min-height: 44px; padding: 10px 0; }
.article-age-note { margin: 10px 0; }
.source-authors { display: block; margin-top: 2px; color: var(--muted); font-size: .8rem; }
.source-details { font-size: .85rem; margin-top: 4px; }
.source-details summary { width: fit-content; padding: 5px 0; color: var(--green); cursor: pointer; }
.source-details summary:hover { text-decoration: underline; }
.source-details small { display: block; color: var(--muted); font-size: inherit; }
.article-source { padding-top: 8px; }
.article-source + .article-source { margin-top: 8px; border-top: 1px solid var(--line); }
.settings-list { display: grid; gap: 14px; }
.settings-card { padding: clamp(16px,3vw,28px); background: var(--surface); border: 1px solid var(--line); border-radius: 17px; }
.settings-card p { margin: 7px 0 10px; color: var(--muted); }
.settings-card h2 .icon { margin-right: 5px; }
.settings-card .form-fields, .settings-card .situation-grid { margin-bottom: 0; }
.settings-data-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.source-license-url { overflow-wrap: anywhere; }

.onboarding { max-width: 1280px; padding: 0 clamp(19px,5.25vw,70px); margin: auto; }
.onboarding-top { display: flex; justify-content: space-between; align-items: center; gap: 6px; min-height: 83px; border-bottom: 1px solid var(--soft-line); }
.welcome { display: grid; grid-template-columns: .93fr 1.07fr; align-items: center; gap: clamp(25px,5.7vw,81px); padding: clamp(35px,8vh,95px) 0 62px; }
.welcome h1 { font-size: clamp(2.6rem,5.5vw,5.2rem); line-height: 1.13; letter-spacing: -.074em; margin: 17px 0; }
.welcome .intro { max-width: 35ch; font-size: clamp(.98rem,1.5vw,1.135rem); line-height: 1.8; color: var(--muted); }
.welcome-visual { position: relative; background: #e8e8d7; border-radius: 26px; overflow: hidden; }
.welcome-photo { width: 100%; height: auto; aspect-ratio: 1.13; object-fit: cover; }
.welcome-actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 27px 0 14px; }
.privacy-line { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: .81rem; font-weight: 600; }
.privacy-line .icon { width: 16px; height: 16px; }
.privacy-line a { color: var(--green); text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
.setup { max-width: 764px; margin: 36px auto 65px; }
.setup-card { padding: clamp(19px,4vw,40px); border: 1px solid var(--line); border-radius: 22px; background: var(--surface); }
.setup-card h1 { font-size: clamp(1.85rem,3.6vw,2.8rem); margin-bottom: 9px; }
.setup .privacy-line { justify-content: center; margin-top: 14px; }
.progress { display: flex; padding: 0; margin: 0 0 15px; list-style: none; gap: 9px; }
.progress li { display: flex; align-items: center; justify-content: center; gap: 6px; flex: 1; min-height: 43px; border-radius: 10px; font-size: .82rem; font-weight: 650; color: var(--muted); border: 1px solid var(--line); }
.progress li.reached { border-color: #cbd9c8; color: var(--green); background: #e8eee2; }
.progress li[aria-current] { background: var(--selected); border-color: #afc4ad; }
.progress li > span { display: grid; place-items: center; width: 23px; height: 23px; border-radius: 50%; background: var(--surface); }
.progress .icon { width: 14px; height: 14px; }
.form-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; margin: 20px 0; }
.form-fields label { display: grid; grid-template-columns: auto 1fr; align-items: center; justify-items: start; gap: 6px 9px; font-weight: 700; align-content: start; }
.form-fields label > span, .form-fields small { color: var(--muted); font-weight: 500; font-size: .79rem; }
.form-fields select, .form-fields small { grid-column: span 2; width: 100%; }
.form-fields select { min-height: 47px; border: 1px solid #cbd3c7; border-radius: 9px; padding: 0 11px; background: var(--surface); font-size: 16px; }
.situation-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; padding: 0; margin: 20px 0; border: 0; min-width: 0; }
.situation { position: relative; display: flex; align-items: center; gap: 9px; padding: 10px; min-height: 67px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; }
.situation:hover { border-color: #9cb29b; }
.situation:has(input:checked) { background: #edf3e9; border-color: #8ba58a; }
.situation:has(input:focus-visible) { outline: 2px solid #48745c; outline-offset: 3px; }
.situation input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.situation i { display: grid; place-items: center; width: 19px; height: 19px; margin-left: auto; border: 1px solid #a7b4a4; border-radius: 5px; flex-shrink: 0; }
.situation i .icon { width: 14px; height: 14px; visibility: hidden; }
.situation input:checked ~ i { color: #fff; background: var(--green); border-color: var(--green); }
.situation input:checked ~ i .icon { visibility: visible; }
.setup-actions { display: flex; justify-content: space-between; align-items: center; gap: 9px; margin: 21px 0 0; }
.situation-grid legend:not(.sr-only) { margin-bottom: 8px; padding: 0; font-weight: 700; }
.profile-summary { margin: 14px 0 0; }
.profile-summary div { display: grid; grid-template-columns: minmax(112px, .55fr) 1fr; gap: 12px; padding: 10px 0; border-top: 1px solid var(--soft-line); }
.profile-summary dt { color: var(--muted); }
.profile-summary dd { margin: 0; font-weight: 650; }

.danger-text { color: #923a35; }
.danger { background: #933c36; color: #fff; }
.danger:hover { background: #792c29; }
dialog { inset: 0; width: min(calc(100% - 36px), 440px); padding: 23px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); border-radius: 17px; box-shadow: 0 12px 90px #1f302d35; }
dialog::backdrop { background: #18261c65; }
dialog p { margin: 8px 0 17px; color: var(--muted); }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; }
.notice { position: fixed; z-index: 10; left: 50%; bottom: 20px; transform: translate(-50%, 7px); opacity: 0; pointer-events: none; color: #fff; background: var(--green); background: color-mix(in srgb, var(--green) 92%, transparent); box-shadow: 0 6px 18px #1e33252a; border-radius: 10px; padding: 10px 15px; transition: opacity .14s, transform .14s; }
.notice.is-visible { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 1120px) {
  .shell { --rail: 202px; }
  .container, .topbar { padding-left: 27px; padding-right: 27px; }
  .category-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 800px) {
  .shell { padding-left: 0; padding-bottom: calc(62px + env(safe-area-inset-bottom)); }
  .sidebar, .breadcrumb, .avatar { display: none; }
  .mobile-brand { display: block; }
  .topbar { min-height: 62px; padding: 0 18px; }
  .brand-mark { width: 36px; height: 36px; border-radius: 11px; }
  .brand-mark .icon { width: 21px; height: 21px; }
  .brand strong { font-size: 1.15rem; }
  .top-actions { gap: 6px; }
  .mobile-nav { position: fixed; z-index: 5; bottom: 0; left: 0; right: 0; padding: 4px 7px calc(4px + env(safe-area-inset-bottom)); background: #fbfaf5; border-top: 1px solid var(--line); display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px; }
  .mobile-nav .nav-link { flex-direction: column; min-height: 54px; justify-content: center; padding: 3px; gap: 2px; font-size: .71rem; line-height: 1.25; }
  .mobile-nav .nav-link.active::after { display: none; }
  .container { padding: 25px 18px 33px; }
  .article-page { padding-bottom: 29px; }
  .back-to-top { bottom: calc(75px + env(safe-area-inset-bottom)); }
  .home-heading { margin-bottom: 22px; }
  .notice { bottom: calc(76px + env(safe-area-inset-bottom)); }
  .onboarding-top { min-height: 66px; }
}
@media (max-width: 590px) {
  .home-heading { display: block; }
  .home-heading .button { margin-top: 11px; }
  .home-heading h1 { font-size: clamp(1.8rem, 7.7vw, 2.6rem); }
  .feature-card { grid-template-columns: 1fr; }
  .feature-copy { padding: 18px; }
  .feature-photo { grid-row: 1; height: auto; aspect-ratio: 1.92; object-position: center 51%; }
  .feature-scene { grid-row: 1; min-height: 100px; }
  .feature-scene .icon { width: 57px; height: 57px; }
  .more-section { margin-top: 18px; }
  .card-grid { grid-template-columns: 1fr; gap: 9px; }
  .category-grid, .form-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .category-grid a { gap: 6px; }
  .category-grid .category-icon { width: 33px; height: 33px; }
  .welcome { grid-template-columns: 1fr; padding: 26px 0 23px; gap: 22px; }
  .welcome h1 { font-size: clamp(2.5rem,10vw,4rem); margin: 11px 0; }
  .welcome-actions { margin: 16px 0 9px; }
  .welcome-photo { aspect-ratio: 1.65; }
  .setup { margin: 25px auto 40px; }
  .situation-grid { grid-template-columns: 1fr; }
  .situation { min-height: 58px; }
}
@media (max-width: 350px) {
  .container { padding-left: 13px; padding-right: 13px; }
  .category-grid { grid-template-columns: 1fr; }
  .setup-card { padding: 15px; }
  .progress li { font-size: .75rem; }
  .resource-facts > div { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
