.complete-page[hidden] { display: none; }
.module-heading { margin: 8px 0 24px; display: flex; align-items: flex-end; justify-content: space-between; gap: 22px; }
.module-heading h1 { margin: 9px 0 8px; font-size: clamp(34px,3.7vw,52px); line-height: 1.05; letter-spacing: -.05em; }
.module-heading p:last-child { max-width: 680px; margin: 0; color: var(--muted); font-size: 15px; line-height: 1.65; }
.module-grid { display: grid; grid-template-columns: repeat(12,1fr); gap: 12px; align-items: start; }
.module-main { grid-column: span 8; }
.module-side { grid-column: span 4; display: grid; gap: 12px; }
.module-half { grid-column: span 6; }
.module-full { grid-column: 1 / -1; }
.module-form { display: grid; gap: 11px; }
.module-form-row { display: grid; grid-template-columns: repeat(2,1fr); gap: 9px; }
.module-form-row.three { grid-template-columns: repeat(3,1fr); }
.module-form label { display: grid; gap: 6px; color: var(--muted); font-size: 12px; }
.module-form input, .module-form select, .module-form textarea { width: 100%; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,.68); color: var(--text); outline: none; font: inherit; font-size: 14px; }
.module-form input, .module-form select { height: 42px; padding: 0 12px; }
.module-form textarea { min-height: 94px; resize: vertical; padding: 12px; line-height: 1.6; }
.module-form input:focus, .module-form select:focus, .module-form textarea:focus { border-color: rgba(98,119,147,.52); box-shadow: 0 0 0 3px var(--accent-soft); }
.form-actions { display: flex; justify-content: flex-end; gap: 8px; }
.record-box { height: 340px; overflow: auto; overscroll-behavior: contain; scrollbar-gutter: stable; padding-right: 3px; }
.record-box.compact { height: 220px; }
.record-box.tall { height: 470px; }
.record-manager { margin:2px 0 8px; border-top:1px solid transparent; }
.record-manager > summary { width:max-content; max-width:100%; min-height:30px; display:flex; align-items:center; gap:7px; color:#858b93; font-size:11px; cursor:pointer; list-style:none; user-select:none; }
.record-manager > summary::-webkit-details-marker { display:none; }
.record-manager > summary::before { content:'•••'; font-size:11px; letter-spacing:1px; color:#a2a7ae; }
.record-manager > summary span { color:#a0a5ac; font-size:10px; }
.record-manager[open] > summary { color:#555c65; }
.record-toolbar { min-height: 43px; margin: 2px 0 0; padding: 7px 9px; display: flex; align-items: center; justify-content: space-between; gap: 9px; border-radius: 12px; background: var(--soft); }
.record-toolbar label { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 12px; cursor: pointer; }
.record-toolbar input, .record-check { width: 17px; height: 17px; accent-color: var(--accent); }
.record-toolbar div { display: flex; gap: 6px; }
.record-toolbar button { min-height: 32px; border: 1px solid var(--line); border-radius: 9px; background: rgba(255,255,255,.68); color: #555b63; padding: 0 10px; font-size: 11px; cursor: pointer; }
.record-toolbar button.danger { color: #765d5d; }
.record-toolbar button:disabled { opacity: .4; cursor: default; }
.record-row { min-height: 64px; display: grid; grid-template-columns: 20px minmax(0,1fr) 30px; align-items: center; gap: 10px; padding: 9px 5px; border-bottom: 1px solid var(--line); }
.record-row:last-child { border-bottom: 0; }
.record-row strong, .record-row small { display: block; }
.record-row strong { font-size: 14px; }
.record-row small { margin-top: 5px; color: var(--muted); font-size: 11px; line-height: 1.45; }
.record-delete { width: 30px; height: 30px; display: grid; place-items: center; border: 0; border-radius: 9px; background: transparent; color: #9ca2aa; font-size: 18px; cursor: pointer; }
.record-delete:hover { color: #43484f; background: var(--soft); }
.record-empty { min-height: 170px; display: grid; place-content: center; text-align: center; color: var(--muted); }
.record-empty strong { color: #43484f; font-size: 13px; }
.record-empty span { max-width: 330px; margin-top: 7px; font-size: 10px; line-height: 1.55; }
.summary-strip { display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; margin-bottom: 12px; }
.summary-strip article { min-height: 105px; padding: 15px; display: flex; flex-direction: column; justify-content: space-between; border: 1px solid rgba(255,255,255,.82); border-radius: 18px; background: rgba(255,255,255,.55); }
.summary-strip span { color: var(--muted); font-size: 10px; }
.summary-strip strong { font-size: 26px; letter-spacing: -.04em; }
.summary-strip small { color: #a0a5ac; font-size: 8px; }
.goal-row { min-height: 74px; grid-template-columns: 20px minmax(0,1fr) auto 30px; }
.goal-progress { min-width: 64px; text-align: right; color: var(--accent-deep); font-size: 10px; }
.goal-progress button { display: block; margin: 5px 0 0 auto; border: 0; border-radius: 8px; background: var(--accent-soft); color: var(--accent-deep); padding: 5px 9px; font-size: 9px; cursor: pointer; }
.mood-history-row { align-items: start; }
.mood-badge { display: inline-flex; margin-right: 6px; padding: 3px 7px; border-radius: 99px; background: var(--accent-soft); color: var(--accent-deep); font-size: 9px; }
.flash-type { color: var(--accent-deep); font-size: 9px; font-weight: 700; }
.journal-mode-tabs, .filter-tabs { display: flex; gap: 4px; padding: 3px; border-radius: 11px; background: var(--soft); }
.journal-mode-tabs button, .filter-tabs button { border: 0; border-radius: 8px; background: transparent; padding: 7px 10px; color: var(--muted); font-size: 10px; cursor: pointer; }
.journal-mode-tabs button.active, .filter-tabs button.active { background: white; color: #30343a; box-shadow: 0 1px 5px rgba(0,0,0,.06); }
.journal-canvas-wrap { display: none; }
.journal-canvas-wrap.active { display: block; }
#journalCanvas { width: 100%; height: 220px; touch-action: none; border: 1px solid var(--line); border-radius: 14px; background: white; }
.journal-preview { max-width: 100%; max-height: 180px; margin-top: 8px; border-radius: 12px; object-fit: cover; }
.review-completion { margin-top:4px; padding:16px; border:1px solid var(--line); border-radius:16px; background:rgba(246,248,250,.72); }
.review-completion-head { display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:start; gap:18px; }
.review-score { min-width:112px; padding:11px 13px; border-radius:13px; background:white; text-align:right; box-shadow:0 4px 14px rgba(23,29,38,.04); }
.review-score strong, .review-score span { display:block; }
.review-score strong { font-size:28px; letter-spacing:-.05em; color:#4f657f; }
.review-score span { margin-top:4px; color:var(--muted); font-size:10px; white-space:nowrap; }
.review-tree { min-height: 230px; display: grid; place-content: center; justify-items: center; border-radius: 18px; background: linear-gradient(145deg, rgba(237,240,244,.72), rgba(255,255,255,.58)); }
.review-tree .tree-art { width:210px; height:170px; }
.review-tree strong { margin-top: 16px; font-size: 14px; }
.review-tree > small { margin-top:5px; color:var(--muted); font-size:10px; }
.review-layout { align-items:start; }
.review-editor-card,.review-tree-side { height:auto!important; }
.review-tree-side { align-self:start; }
.review-other { display:grid; gap:10px; padding:14px; border:1px solid var(--line); border-radius:16px; background:rgba(246,248,250,.48); }
#reviewOtherList { display:grid; gap:5px; }
.review-other-row { min-height:38px; display:grid; grid-template-columns:minmax(0,1fr) 30px; align-items:center; gap:8px; border-bottom:1px solid var(--line); color:#4e555d; font-size:12px; }
.review-other-row:last-child { border-bottom:0; }
.review-other-row button { width:30px; height:30px; border:0; border-radius:9px; background:transparent; color:#8b9199; font-size:18px; cursor:pointer; }
.review-archive-card { min-width:0; height:auto!important; }
.forest-intro { max-width:560px; margin:7px 0 0; color:var(--muted); font-size:11px; line-height:1.55; }
.forest-controls { display:flex; align-items:center; justify-content:space-between; gap:12px; margin:4px 0 10px; padding:9px 11px; border:1px solid var(--line); border-radius:13px; background:rgba(245,247,249,.76); color:#68717a; font-size:10px; }
.forest-controls > div { display:flex; align-items:center; gap:5px; }
.forest-controls button { min-width:30px; height:30px; border:1px solid var(--line); border-radius:9px; background:white; color:#505861; cursor:pointer; }
.forest-controls output { min-width:44px; text-align:center; font-variant-numeric:tabular-nums; }
.forest-viewport { min-height:235px; overflow-x:auto; overflow-y:hidden; overscroll-behavior-inline:contain; scroll-snap-type:x proximity; touch-action:pan-x; border-radius:18px; background:linear-gradient(180deg,rgba(247,249,249,.75),rgba(229,235,231,.82)); scrollbar-color:#9aa9a0 transparent; }
.forest-track { --forest-scale:1; min-width:100%; width:max-content; min-height:235px; display:flex; align-items:flex-end; gap:calc(12px * var(--forest-scale)); padding:20px 24px 16px; background:radial-gradient(ellipse at 50% 100%,rgba(153,177,157,.2),transparent 62%); }
.forest-tree-card { position:relative; flex:0 0 calc(156px * var(--forest-scale)); width:calc(156px * var(--forest-scale)); scroll-snap-align:center; }
.forest-tree-card > .record-check { position:absolute; z-index:3; left:9px; top:9px; }
.forest-tree-button { width:100%; min-height:calc(195px * var(--forest-scale)); display:flex; flex-direction:column; align-items:center; justify-content:flex-end; border:1px solid rgba(121,145,128,.2); border-radius:18px; background:rgba(255,255,255,.76); padding:10px; color:#3c4640; cursor:pointer; box-shadow:0 10px 24px rgba(62,78,67,.07); }
.forest-tree-button:hover,.forest-tree-button:focus-visible { border-color:rgba(92,124,101,.48); box-shadow:0 13px 28px rgba(62,78,67,.12); outline:none; }
.forest-tree-visual { display:block; width:calc(135px * var(--forest-scale)); height:calc(115px * var(--forest-scale)); }
.forest-tree-button strong { margin-top:4px; font-size:13px; }
.forest-tree-button small { margin-top:3px; color:var(--muted); font-size:9px; }
.forest-tree-card .review-week-delete { position:absolute; z-index:3; right:5px; top:5px; background:rgba(255,255,255,.82); }
.review-week-card { min-width:0; min-height:82px; display:grid; grid-template-columns:18px minmax(0,1fr) 28px; align-items:center; gap:7px; padding:10px; border:1px solid var(--line); border-radius:15px; background:rgba(255,255,255,.5); }
.review-week-card > button[data-review-week] { min-width:0; min-height:54px; border:0; border-radius:11px; background:linear-gradient(145deg,rgba(232,237,243,.78),rgba(255,255,255,.8)); color:#39434f; cursor:pointer; }
.review-week-card > button[data-review-week] strong { font-size:15px; letter-spacing:-.02em; white-space:nowrap; }
.review-week-delete { width:28px; height:28px; border:0; border-radius:8px; background:transparent; color:#9298a0; font-size:17px; cursor:pointer; }
.review-week-delete:hover { background:var(--soft); color:#535a63; }
.forest-empty { width:min(520px,calc(100vw - 90px)); min-height:200px; margin:auto; display:grid; place-content:center; gap:7px; padding:26px; color:var(--muted); text-align:center; font-size:11px; line-height:1.65; }
.forest-empty strong { color:#505a54; font-size:15px; }
.forest-empty span { display:block; }
.review-detail-dialog { width:min(760px,calc(100% - 28px)); }
.review-detail-shell { padding:24px; }
.review-detail-meta { margin:-8px 0 18px; color:var(--muted); font-size:11px; line-height:1.6; }
.review-detail-groups { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
.review-detail-group { min-width:0; padding:13px; border:1px solid var(--line); border-radius:14px; background:rgba(255,255,255,.58); }
.review-detail-group header { display:grid; grid-template-columns:9px minmax(0,1fr) auto; align-items:center; gap:7px; }
.review-detail-group header span { width:9px; height:9px; border-radius:50%; background:#78927e; }
.review-detail-group.movement header span { background:#5f84aa; }
.review-detail-group.growth header span { background:#b99a4f; }
.review-detail-group.other header span { background:#8e949b; }
.review-detail-group header strong { font-size:13px; }
.review-detail-group header em { color:var(--muted); font-size:10px; font-style:normal; }
.review-detail-group ul { margin:11px 0 0; padding:0; list-style:none; }
.review-detail-group li { padding:8px 0; border-top:1px solid var(--line); color:#464d55; font-size:12px; line-height:1.45; }
.review-detail-group li small { display:block; margin-top:3px; color:var(--muted); font-size:9px; }
.review-detail-group p { margin:12px 0 0; color:var(--muted); font-size:10px; }
.review-detail-keep { margin-top:12px; padding:13px; border-radius:14px; background:var(--soft); }
.review-detail-keep strong { font-size:12px; }
.review-detail-keep p { margin:6px 0 0; color:#59616a; font-size:12px; line-height:1.6; }
.install-help-shell { padding:24px; }
.install-steps { display:grid; gap:9px; }
.install-steps section { padding:13px; border:1px solid var(--line); border-radius:13px; background:rgba(255,255,255,.55); }
.install-steps strong { font-size:13px; }
.install-steps p { margin:5px 0 0; color:var(--muted); font-size:11px; line-height:1.65; }
.install-help-shell menu,.review-detail-shell menu { margin:18px 0 0; padding:0; display:flex; justify-content:flex-end; }
.finance-amount.income { color: #526b5c; }
.finance-amount.expense { color: #735e5e; }
[data-record-kind="finance"] { grid-template-columns: 20px minmax(0,1fr) auto 30px; }
.settings-actions { display: grid; gap: 9px; }
.settings-actions button, .settings-actions label { min-height: 46px; display: flex; align-items: center; justify-content: space-between; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,.58); padding: 0 13px; color: #4d535b; font-size: 12px; cursor: pointer; }
.settings-actions input[type=file] { display: none; }
.settings-note { margin: 11px 0 0; color: var(--muted); font-size: 10px; line-height: 1.6; }
.standalone-sync-form { display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:end; gap:10px; margin-top:14px; }
.standalone-sync-form label { display:grid; gap:7px; min-width:0; color:var(--muted); font-size:10px; }
.standalone-sync-form input { width:100%; min-width:0; height:44px; border:1px solid var(--line); border-radius:12px; background:white; padding:0 12px; color:var(--text); }
.standalone-sync-form button { min-height:44px; }
.body-primary-fields { display:grid; grid-template-columns:1.15fr 1fr 1fr; gap:9px; }
.body-more { padding:0 12px; border:1px solid var(--line); border-radius:14px; background:rgba(255,255,255,.38); }
.body-more > summary { min-height:44px; display:flex; align-items:center; justify-content:space-between; color:#626972; font-size:12px; cursor:pointer; list-style:none; }
.body-more > summary::-webkit-details-marker { display:none; }
.body-more > summary::after { content:'＋'; color:#9298a0; font-size:16px; }
.body-more[open] > summary::after { content:'−'; }
.body-more .body-extra-fields { padding:2px 0 11px; }
.body-more > label { padding:0 0 12px; }
.home-record-panel { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.home-record-panel .record-box { height: 172px; }
.home-record-panel .record-row { min-height: 58px; }
.movement-history { height: 190px; overflow-y: auto; overscroll-behavior: contain; }
.movement-history .record-row { grid-template-columns: 20px 34px minmax(0,1fr) 30px; }
.movement-history .record-row > button:last-child { justify-self: end; }
.batch-check-inline { display: flex; align-items: center; justify-content: center; }
.batch-enhanced { position: relative; }
.legacy-select-row { padding-left: 38px !important; }
.legacy-select-row > .record-check { position: absolute; left: 10px; top: 50%; z-index: 2; transform: translateY(-50%); }
.schedule-item.legacy-select-row { padding-left: 34px !important; }
.schedule-item.legacy-select-row > .record-check { left: 8px; }
.legacy-batch-bar { margin: 9px 0; }
#workTaskList, #courseList { max-height: 560px; overflow-y: auto; overscroll-behavior: contain; scrollbar-gutter: stable; padding-right: 4px; }
#scheduleWeek { max-height:620px; overflow-y:auto; overflow-x:hidden; overscroll-behavior:contain; scrollbar-gutter:stable; }
#focusHistory { max-height: 310px; overflow-y: auto; overscroll-behavior: contain; scrollbar-gutter: stable; }
.search-dialog { width: min(720px, calc(100vw - 28px)); max-height: min(760px, calc(100vh - 40px)); border: 1px solid rgba(255,255,255,.9); border-radius: 24px; padding: 0; background: rgba(248,249,250,.94); box-shadow: 0 28px 90px rgba(18,22,28,.2); backdrop-filter: blur(28px); }
.search-dialog::backdrop { background: rgba(21,24,29,.2); backdrop-filter: blur(5px); }
.search-shell { padding: 20px; }
.search-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.search-head h2 { margin: 5px 0 16px; font-size: 24px; }
.search-head > button { width: 36px; height: 36px; border: 0; border-radius: 11px; background: var(--soft); color: var(--muted); font-size: 22px; cursor: pointer; }
#globalSearchInput { width: 100%; height: 50px; margin-bottom: 12px; border: 1px solid var(--line); border-radius: 14px; padding: 0 15px; background: white; color: var(--text); font: inherit; font-size: 15px; outline: none; }
#globalSearchResults { height: 430px; }
.search-result { width: 100%; min-height: 66px; display: flex; align-items: center; justify-content: space-between; gap: 14px; border: 0; border-bottom: 1px solid var(--line); background: transparent; padding: 10px 7px; text-align: left; color: var(--text); cursor: pointer; }
.search-result:hover { background: rgba(255,255,255,.55); }
.search-result strong, .search-result small { display: block; }
.search-result strong { font-size: 14px; }
.search-result small { margin-top: 5px; color: var(--muted); font-size: 11px; }
.search-result em { flex: 0 0 auto; border-radius: 99px; background: var(--soft); padding: 5px 8px; color: var(--muted); font-style: normal; font-size: 10px; }
.assistant-body { min-height: 0; display: flex; flex-direction: column; }
.assistant-thread { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; padding-right: 3px; }
.assistant-message.user { margin-left: auto; border-radius: 16px 16px 5px 16px; background: #272a2f; color: white; }
.assistant-chatgpt-link { align-self: flex-start; margin-top: 2px; border: 1px solid var(--line); border-radius: 999px; padding: 8px 11px; background: rgba(255,255,255,.62); color: #555b63; font-size: 10px; text-decoration: none; }
@media (max-width: 1100px) { .module-main, .module-side, .module-half { grid-column: 1 / -1; } }
@media (max-width: 620px) {
  .module-heading { align-items: flex-start; }
  .module-heading h1 { font-size: 34px; }
  .module-form-row, .module-form-row.three { grid-template-columns: 1fr; }
  .summary-strip { grid-template-columns: repeat(3,1fr); gap: 6px; }
  .summary-strip article { min-height: 94px; padding: 12px 9px; }
  .summary-strip strong { font-size: 21px; }
  .record-box { height: 310px; }
  .record-toolbar { align-items: stretch; flex-direction: column; }
  .record-toolbar div { justify-content: flex-end; }
}
/* Horizontal home cards retain the original monochrome glass surfaces. */
.page-home .metric-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
.page-home .metric-card { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:10px 20px; min-height:88px; align-items:center; }
.page-home .metric-card .progress, .page-home .metric-card .tiny-caption { grid-column:1/-1; }
.page-home .dashboard-grid { grid-template-columns:minmax(0,1fr); }
.page-home .dashboard-grid > .card { grid-column:1/-1; display:grid; grid-template-columns:minmax(180px,.7fr) minmax(0,1.7fr); gap:14px 28px; align-items:start; padding:22px 26px; }
.page-home .dashboard-grid > .card > .card-head { grid-column:1; grid-row:1; margin:0; flex-wrap:wrap; }
.page-home .dashboard-grid > .card > :not(.card-head) { grid-column:2; }
.page-home .movement-card .movement-content { grid-row:1; min-height:80px; }
.page-home .movement-card .ring { width:76px; height:76px; }
.page-home .movement-card .segmented-actions { grid-column:1!important; grid-row:2; grid-template-columns:repeat(2,minmax(0,1fr)); }
.page-home .movement-card .movement-history-head { grid-column:2; grid-row:2; }
.page-home .movement-card #movementHomeBatch { grid-column:2; grid-row:3; margin:0; }
.page-home .movement-card .movement-history { grid-column:2; grid-row:4; height:172px; }
.page-home .mood-card { grid-template-columns:minmax(300px,.92fr) minmax(0,1.55fr); column-gap:36px; }
.page-home .mood-card .card-head { grid-column:1/-1!important; grid-row:1; }
.page-home .mood-card .mood-scale { grid-column:1!important; grid-row:2; min-width:0; }
.page-home .mood-card .mood-note { grid-column:2!important; grid-row:2; min-width:0; margin:0; padding-left:28px; border-top:0; border-left:1px solid var(--line); }
.page-home .mood-card .mood-note textarea { min-width:100%; max-width:100%; min-height:126px; max-height:360px; resize:vertical; }
.mood-weekly-summary { margin-top:12px; padding:12px; display:grid; grid-template-columns:auto minmax(0,1fr); align-items:center; gap:16px; border-radius:13px; background:rgba(239,242,246,.72); }
.mood-weekly-summary strong,.mood-weekly-summary small { display:block; }
.mood-weekly-summary strong { font-size:12px; }
.mood-weekly-summary small { margin-top:4px; color:var(--muted); font-size:9px; }
.mood-mini-trend { min-width:0; display:flex; justify-content:flex-end; gap:7px; overflow-x:auto; padding:3px 0; }
.mood-trend-dot { flex:0 0 auto; display:grid; justify-items:center; gap:4px; color:var(--muted); }
.mood-trend-dot i { width:11px; height:11px; border-radius:50%; background:#a9afb6; opacity:.45; }
.mood-trend-dot.level-2 i { opacity:.58; }
.mood-trend-dot.level-3 i { opacity:.7; }
.mood-trend-dot.level-4 i { opacity:.84; background:#7f93aa; }
.mood-trend-dot.level-5 i { opacity:1; background:#627c99; }
.mood-trend-dot small { font-size:8px; white-space:nowrap; }
.mood-trend-empty { color:var(--muted); font-size:10px; }
.page-home .mood-card .home-record-panel { grid-column:1/-1!important; }
.page-home .flash-card .flash-form { grid-row:1; }
.page-home .flash-card .home-record-panel { grid-column:1/-1!important; }
.page-home .tree-preview { grid-template-columns:150px minmax(0,1fr); min-height:126px; gap:18px; }
.page-home .tree-art { transform:none; width:150px; height:122px; }
.page-home .tree-copy { min-width:0; }
.home-leaf-count { width:max-content; display:inline-flex; align-items:baseline; gap:5px; padding:6px 10px; border:1px solid rgba(115,137,119,.18); border-radius:999px; background:rgba(229,237,230,.7); color:#607965; }
.home-leaf-count span { font-size:18px; line-height:1; font-weight:760; }
.home-leaf-count small { font-size:10px; letter-spacing:.08em; }
.work-heading { align-items:flex-start; }
.work-heading > div:first-child { min-width:0; flex:1; }
.work-heading-actions { display:flex; align-items:center; flex-direction:column; gap:10px; flex:0 0 auto; }
.work-heading-actions .work-ring { width:112px; height:112px; margin:0; }
.work-heading-actions .work-ring strong { font-size:24px; }
.work-heading-actions .work-ring span { font-size:9px; }
.work-heading-actions .primary-button { min-height:40px; }
.editable-quote { white-space:pre-line; overflow-wrap:anywhere; cursor:text; touch-action:pan-y; }
.editable-quote:focus-visible { outline:2px solid var(--accent); outline-offset:5px; border-radius:5px; }
.quote-edit-button { display:inline-flex; align-items:center; border:0; border-radius:8px; padding:4px 7px; background:transparent; color:#8d939b; font-size:10px; margin-top:7px; cursor:pointer; }
.quote-edit-button::before { content:'✎'; margin-right:4px; font-size:11px; }
.quote-edit-button:hover, .quote-edit-button:focus-visible { color:#4f5d6d; background:rgba(255,255,255,.55); }
.quick-dialog { max-height:calc(100dvh - 28px); overflow-y:auto; }
.quick-dialog textarea { width:100%; border:1px solid var(--line); border-radius:12px; background:white; padding:12px; color:var(--text); font:inherit; resize:vertical; }
#recordEditFields { display:grid; gap:12px; }
#reviewChecklist { display:grid; gap:8px; max-height:240px; overflow:auto; margin:12px 0; }
#reviewChecklist label { display:flex; align-items:flex-start; gap:10px; color:var(--text); }
#reviewChecklist input { width:18px; height:18px; margin:2px 0 0; flex:0 0 auto; }
.review-completion h3 { font-size:15px; margin-bottom:6px; }
.review-completion p, #reviewCountBasis { font-size:12px; line-height:1.6; color:var(--muted); }
#bodyBMI { color:var(--accent-deep); font-weight:600; font-size:14px; }
.record-edit { border:1px solid var(--line); border-radius:8px; padding:5px 7px; color:var(--muted); background:transparent; font-size:10px; cursor:pointer; }
.record-row:has(.record-edit) { grid-template-columns:20px minmax(0,1fr) 30px 42px; }
.goal-row:has(.record-edit), [data-record-kind="finance"]:has(.record-edit) { grid-template-columns:20px minmax(0,1fr) auto 30px 42px; }
.record-row strong, .record-row small, .card, .module-form label, .module-grid > *, .module-form-row > *, .search-result > span { min-width:0; overflow-wrap:anywhere; }
.module-grid { grid-template-columns:repeat(12,minmax(0,1fr)); }
.record-toolbar { flex-wrap:wrap; }
.record-toolbar div { flex-wrap:wrap; }
.work-task-row:has(.record-edit) { grid-template-columns:32px minmax(0,1fr) auto 28px 42px; }
.schedule-item .record-edit { top:auto; right:40px; bottom:9px; margin:0; padding:0; border:0; font-size:0; }
.schedule-item .record-edit::before { content:'✎'; font-size:14px; line-height:1; }
.schedule-item [data-schedule-delete] { right:8px; }
.course-row .record-edit { margin-top:8px; }
#focusHistory .record-row { display:grid; }
@media(max-width:1200px) {
  .page-home .mood-card { grid-template-columns:minmax(250px,.82fr) minmax(0,1.4fr); column-gap:28px; }
}
@media(max-width:760px) {
  .page-home .dashboard-grid > .card { grid-template-columns:minmax(0,1fr); padding:20px; gap:14px; }
  .page-home .dashboard-grid > .card > * { grid-column:1!important; grid-row:auto!important; }
  .page-home .metric-grid { grid-template-columns:minmax(0,1fr); }
  .work-heading { flex-wrap:wrap; gap:16px; }
  .work-heading-actions { flex-direction:row; width:100%; justify-content:space-between; }
  .work-heading-actions .work-ring { width:92px; height:92px; }
  .work-heading-actions .work-ring strong { font-size:20px; }
  .work-heading-actions .primary-button { font-size:12px; width:auto; padding:0 16px; }
  .work-heading h1 { font-size:32px; }
  .module-heading h1 { font-size:32px; }
  .body-primary-fields { grid-template-columns:1fr; }
  .review-completion-head { grid-template-columns:1fr; }
  .review-score { width:100%; text-align:left; }
  .record-row { gap:6px; }
  .record-row strong { font-size:12px; }
  .goal-row:has(.record-edit) { grid-template-columns:20px minmax(0,1fr) 30px 42px; }
  .goal-row .goal-progress { grid-column:2; grid-row:2; text-align:left; }
  .goal-progress button { margin-left:0; }
  [data-record-kind="finance"]:has(.record-edit) { grid-template-columns:20px minmax(0,1fr) 30px 42px; }
  [data-record-kind="finance"] .finance-amount { grid-column:2; grid-row:2; }
  .page-home .dashboard-grid > .mood-card { grid-template-columns:minmax(136px,.86fr) minmax(0,1.24fr); gap:14px; padding:18px 16px; }
  .page-home .dashboard-grid > .mood-card > .card-head { grid-column:1/-1!important; grid-row:1!important; }
  .page-home .dashboard-grid > .mood-card > .mood-scale { grid-column:1!important; grid-row:2!important; }
  .page-home .dashboard-grid > .mood-card > .mood-note { grid-column:2!important; grid-row:2!important; padding:0 0 0 14px; border-top:0; border-left:1px solid var(--line); }
  .page-home .dashboard-grid > .mood-card > .home-record-panel { grid-column:1/-1!important; }
  .page-home .mood-card .mood-scale { grid-template-columns:repeat(2,minmax(0,1fr)); align-content:start; gap:10px 6px; min-height:0; padding-top:3px; }
  .page-home .mood-card .mood-scale button { min-width:0; padding:2px 1px; gap:6px; }
  .page-home .mood-card .mood-scale button:last-child { grid-column:1/-1; justify-self:center; width:58px; }
  .page-home .mood-card .mood-scale button small { font-size:10px; }
  .page-home .mood-card .mood-note-footer { flex-wrap:wrap; }
}

/* Release 19: controls remain visible; cards align without clipping. */
.module-grid { align-items:stretch; }
.module-grid > .card,.module-grid > .module-side { min-width:0; height:100%; }
.module-side > .card { min-width:0; }
.module-half { height:100%; }
.record-manager { display:grid; grid-template-columns:minmax(0,1fr); gap:5px; margin:6px 0 10px; padding:8px 9px; border-radius:12px; background:var(--soft); }
.record-manager-label { min-width:0; color:#666d76; font-size:11px; white-space:nowrap; writing-mode:horizontal-tb; word-break:keep-all; }
.record-toolbar { width:100%; min-height:34px; margin:0; padding:0; background:transparent; flex-direction:row!important; }
.record-toolbar label,.record-toolbar button { white-space:nowrap; writing-mode:horizontal-tb; word-break:keep-all; }
.record-toolbar button { background:rgba(255,255,255,.75); }
.body-more { padding:11px 12px; }
.body-more-label { margin-bottom:9px; color:#626972; font-size:12px; font-weight:650; }
.body-more .body-extra-fields { padding:0 0 11px; }
.body-more > label { padding:0; }
.body-form label { min-width:0; writing-mode:horizontal-tb; word-break:keep-all; }
.body-form input { min-width:0; width:100%; max-width:100%; }
#bodyDate { display:block; min-width:0; width:100%; max-width:100%; overflow:hidden; white-space:nowrap; }
#bodyDate::-webkit-date-and-time-value { min-width:0; text-align:left; }
#bodyDate::-webkit-datetime-edit { min-width:0; padding:0; }
#bodyDate::-webkit-calendar-picker-indicator { flex:0 0 auto; margin-left:4px; }
.body-primary-fields > label { min-width:0; overflow:visible; }
.body-primary-fields input { box-sizing:border-box; -webkit-appearance:none; appearance:none; border:1px solid var(--line)!important; background:#fff; }
#bodyDate { overflow:visible; }
.fitness-hub-card { padding:0; overflow:hidden; }
.fitness-hub-grid { display:grid; grid-template-columns:minmax(0,1.55fr) minmax(260px,.75fr); min-height:390px; }
.fitness-log-pane,.fitness-quick-pane { min-width:0; padding:28px; }
.fitness-quick-pane { border-left:1px solid var(--line); background:linear-gradient(150deg,rgba(235,239,244,.82),rgba(248,249,250,.52)); }
.fitness-quick-pane > p { margin:0 0 18px; color:var(--muted); font-size:11px; line-height:1.6; }
.fitness-quick-actions { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:9px; }
.fitness-quick-actions button { min-height:54px; border:1px solid var(--line); border-radius:13px; background:rgba(255,255,255,.8); color:var(--text); cursor:pointer; }
.fitness-quick-actions button small { display:block; margin-top:4px; color:var(--muted); font-size:9px; }
.fitness-quick-actions .custom-movement-buttons { display:contents; }
.fitness-quick-actions .movement-type-add { grid-column:1/-1; border-style:dashed; }
#fitnessMovementList { height:250px; overflow-y:auto; overscroll-behavior:contain; scrollbar-gutter:stable; }
.body-metrics-card .body-form { max-width:none; }
.custom-movement-buttons { display:contents; }
.segmented-actions .movement-type-add { border-style:dashed; color:#747b84; }
.dialog-note { margin:-4px 0 16px; color:var(--muted); font-size:11px; line-height:1.6; }
.custom-movement-type-list { display:grid; gap:6px; margin-top:14px; }
.custom-movement-type-list > p { margin:0; color:var(--muted); font-size:10px; }
.custom-movement-type { min-height:38px; display:flex; align-items:center; justify-content:space-between; gap:8px; padding:0 8px 0 12px; border:1px solid var(--line); border-radius:11px; background:rgba(255,255,255,.5); color:#555d66; font-size:12px; }
.custom-movement-type button { width:28px; height:28px; border:0; border-radius:8px; background:transparent; color:#8b9199; font-size:18px; cursor:pointer; }
.review-planner { display:grid; gap:10px; padding:14px; border:1px solid var(--line); border-radius:16px; background:rgba(246,248,250,.72); }
.review-plan-add { display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:end; gap:9px; }
.review-plan-add .secondary-button { height:42px; }
.review-check-row { min-width:0; display:grid; grid-template-columns:minmax(0,1fr) 32px; align-items:center; gap:8px; border-bottom:1px solid var(--line); }
.review-check-row:last-child { border-bottom:0; }
.review-check-row label { min-width:0; min-height:48px; display:flex!important; align-items:center; grid-template-columns:none!important; gap:9px; color:var(--text); cursor:pointer; }
.review-check-row input { flex:0 0 auto; width:18px; height:18px; accent-color:var(--accent-deep); }
.review-check-row span { min-width:0; overflow-wrap:anywhere; }
.review-check-row button { width:32px; height:32px; border:0; border-radius:9px; background:transparent; color:#8b9199; font-size:18px; cursor:pointer; }
.tree-legend { display:flex; flex-wrap:wrap; gap:12px; color:var(--muted); font-size:11px; }
.tree-legend span::before { content:''; display:inline-block; width:9px; height:9px; margin-right:6px; border-radius:50%; background:#78927e; }
.tree-legend .growth::before { background:#b99a4f; }
.tree-legend .movement::before { background:#5f84aa; }
.tree-legend .other::before { background:#8e949b; }
@media(max-width:1180px) {
  .module-half { grid-column:1/-1; }
  .body-primary-fields { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .body-extra-fields.module-form-row { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .fitness-hub-grid { grid-template-columns:minmax(0,1.35fr) minmax(240px,.8fr); }
}
@media(max-width:760px) {
  .record-manager { align-items:stretch; flex-direction:column; }
  .record-toolbar { width:100%; flex-wrap:wrap; }
  .record-toolbar > div { flex-wrap:wrap; justify-content:flex-end; }
  .body-primary-fields,.body-extra-fields.module-form-row { grid-template-columns:minmax(0,1fr); }
  .fitness-hub-grid { grid-template-columns:minmax(0,1fr); }
  .fitness-log-pane,.fitness-quick-pane { padding:20px 16px; }
  .fitness-quick-pane { border-left:0; border-top:1px solid var(--line); }
  #fitnessMovementList { height:238px; }
  .review-plan-add { grid-template-columns:minmax(0,1fr); }
  .review-plan-add .secondary-button { width:100%; }
  .review-detail-groups { grid-template-columns:minmax(0,1fr); }
  .standalone-sync-form { grid-template-columns:minmax(0,1fr); }
}
.home-card-icon { width:22px; height:22px; fill:none; stroke:currentColor; stroke-width:1.5; color:var(--muted); vertical-align:middle; flex:0 0 auto; }
.metric-label { display:flex; align-items:center; gap:9px; flex-wrap:wrap; }
.page-home .card-head > div { display:grid; grid-template-columns:26px minmax(0,1fr); align-items:center; column-gap:9px; }
.page-home .card-head > .capture-tabs { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); width:100%; min-width:0; column-gap:4px; }
.page-home .card-head > .capture-tabs button { white-space:nowrap; word-break:keep-all; writing-mode:horizontal-tb; }
.page-home .card-head > div .home-card-icon { grid-row:1/3; }
.page-home .card-head > div .section-kicker, .page-home .card-head > div h2 { grid-column:2; }
#historyReviewChecks label { display:flex; gap:9px; align-items:center; margin-top:9px; }
#historyReviewChecks input { width:18px; height:18px; }
@media(max-width:620px) {
 .work-task-row:has(.record-edit) { grid-template-columns:28px minmax(0,1fr) 28px 40px; gap:6px; padding-left:32px!important; }
 .work-task-row:has(.record-edit) .priority-tag { grid-column:2; grid-row:2; }
 .work-task-row:has(.record-edit) .work-task-delete { grid-column:3; grid-row:1; }
 .work-task-row:has(.record-edit) .record-edit { grid-column:4; grid-row:1; }
 .schedule-item { overflow-wrap:normal; }
}
.removed-module { display:none!important; }
#profileForm { display:grid; gap:12px; }
#profileForm .dialog-head { margin-bottom:0; }
.notification-head { display:flex; justify-content:space-between; gap:10px; align-items:center; }
.notification-head button { background:transparent; border:0; font-size:22px; color:var(--muted); cursor:pointer; }
.notification-task { width:100%; display:grid; gap:5px; text-align:left; background:transparent; border:0; border-bottom:1px solid var(--line); padding:10px 0; cursor:pointer; }
.notification-task small { color:var(--muted); }
.notification-panel { max-height:min(400px,80dvh); overflow-y:auto; }
.notification-dot[hidden] { display:none; }
[data-record-kind="flash"]:has(.flash-to-task) { grid-template-columns:20px minmax(0,1fr) 30px 42px; }
.flash-to-task { grid-column:2/-1; justify-self:start; margin-bottom:3px; }
.page-home .home-task-empty { min-height:85px; }
.page-home .priorities-card #addTaskButton { grid-column:1; grid-row:2; }
.page-home .habit-list { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:0 24px; }
.page-home .habit-row { min-height:78px; }
.page-home .empty-schedule { min-height:118px; padding:16px; display:grid; grid-template-columns:42px minmax(0,1fr) auto; gap:8px 12px; text-align:left; }
.page-home .empty-schedule .calendar-glyph { grid-row:1/3; margin:0; }
.page-home .empty-schedule strong { grid-column:2; }
.page-home .empty-schedule p { grid-column:2; margin:0; }
.page-home .empty-schedule > .secondary-button { grid-column:3; grid-row:1/3; }
.page-home .empty-schedule:has(.home-schedule-list) { grid-template-columns:minmax(0,1fr) auto; }
.page-home .empty-schedule .home-schedule-list { grid-column:1; }
.install-card > p { max-width:720px; margin:0 0 14px; color:var(--muted); font-size:12px; line-height:1.65; }
.install-card .settings-actions { max-width:560px; }
.action-confirm-dialog { width:min(92vw,440px); max-width:440px; padding:0; border:0; border-radius:22px; background:transparent; color:var(--text); box-shadow:0 28px 80px rgba(24,30,38,.28); }
.action-confirm-dialog::backdrop { background:rgba(21,27,34,.42); backdrop-filter:blur(5px); -webkit-backdrop-filter:blur(5px); }
.action-confirm-shell { display:grid; gap:18px; padding:24px; border:1px solid rgba(255,255,255,.72); border-radius:22px; background:rgba(250,251,252,.98); }
.action-confirm-shell .dialog-head { margin:0; align-items:flex-start; }
.action-confirm-shell .dialog-head button { width:34px; height:34px; border:0; border-radius:10px; background:#eef1f4; color:#69717a; font-size:22px; line-height:1; cursor:pointer; }
.action-confirm-shell p { margin:0; color:#59616b; font-size:13px; line-height:1.7; overflow-wrap:anywhere; }
.action-confirm-shell menu { display:flex; justify-content:flex-end; gap:9px; margin:0; padding:0; }
.action-confirm-shell menu button { min-width:96px; min-height:42px; border-radius:12px; cursor:pointer; }
.danger-button { border:1px solid #25292e; background:#17191c; color:#fff; }
@media(max-width:760px) {
 .page-home .habit-list { grid-template-columns:minmax(0,1fr); }
 .page-home .empty-schedule { grid-template-columns:34px minmax(0,1fr); }
 .page-home .empty-schedule > .secondary-button { grid-column:2; grid-row:3; justify-self:start; }
 .page-home .empty-schedule:has(.home-schedule-list) { grid-template-columns:minmax(0,1fr); }
 .page-home .empty-schedule:has(.home-schedule-list) > .secondary-button { grid-column:1; }
 .mood-weekly-summary { grid-template-columns:minmax(0,1fr); gap:10px; }
 .mood-mini-trend { justify-content:flex-start; }
 .action-confirm-dialog { width:calc(100vw - 28px); }
 .action-confirm-shell { padding:20px 18px; }
 .action-confirm-shell menu { display:grid; grid-template-columns:1fr 1fr; }
 .page-home .tree-preview { grid-template-columns:112px minmax(0,1fr); gap:10px; }
 .page-home .tree-art { width:112px; height:100px; margin-left:0; }
 .review-tree .tree-art { width:180px; height:150px; transform:none; margin:0 auto; }
 .review-archive-card .card-head { align-items:flex-start; }
 .review-archive-card .card-meta { white-space:normal; text-align:right; }
 .forest-controls { align-items:flex-start; }
 .forest-controls > div { flex-wrap:wrap; justify-content:flex-end; }
 .forest-viewport,.forest-track { min-height:215px; }
}
@media(max-width:430px) {
 .page-home .tree-preview { grid-template-columns:minmax(0,1fr); }
 .page-home .tree-art { width:150px; height:118px; margin:0 auto; }
 .page-home .tree-copy { text-align:center; }
 .page-home .home-leaf-count { margin-inline:auto; }
 .forest-controls > span { display:none; }
 .forest-controls { justify-content:flex-end; }
 .forest-track { padding-inline:15px; }
}
