:root {
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  color: #303b32;
  background: #f6f5f0;
  font-synthesis: none;
  --ink: #303b32;
  --muted: #65715e;
  --green: #445e46;
  --line: #dfe3d6;
  --paper: #fdfcf8;
  --sage: #edf1e5;
  --serif: Georgia, "Times New Roman", serif;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 280px; }
button, input, textarea { font: inherit; }
button, a, input, textarea { -webkit-tap-highlight-color: transparent; }
button, a { touch-action: manipulation; }
button { border: 0; background: none; color: inherit; cursor: pointer; }
button:disabled { cursor: default; opacity: .5; }
a { color: inherit; text-decoration: none; }
button, a { transition: background .18s, color .18s, box-shadow .18s; }
button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible,
summary:focus-visible, [tabindex]:focus-visible { outline: 3px solid #58784e; outline-offset: 4px; }
h1, h2, h3, p { margin: 0; }
p { line-height: 1.65; }
h1, h2 { font-family: var(--serif); font-weight: 400; }
h3 { font-weight: 500; }
.icon { height: 20px; width: 20px; flex-shrink: 0; vertical-align: middle; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; top: 12px; left: 12px; padding: 12px 20px; z-index: 100; border-radius: 6px; background: var(--ink); color: #fff; transform: translateY(-160%); }
.skip-link:focus { transform: translateY(0); }

/* Navigation stays visually separate from the person's current task. */
.sidebar { width: 224px; position: fixed; inset: 0 auto 0 0; border-right: 1px solid var(--line); padding: 36px 22px 24px; display: flex; flex-direction: column; background: #f0f0e8; z-index: 5; overflow-y: auto; }
.workspace-mark { display: flex; align-items: center; gap: 11px; font-weight: 600; font-size: 16px; letter-spacing: -.35px; min-height: 44px; padding: 0 8px; }
.workspace-mark > .icon { width: 30px; height: 30px; stroke-width: 1.1; color: #536a50; }
.nav-label { font-size: 10px; font-weight: 600; letter-spacing: 1.4px; color: var(--muted); margin: 43px 0 16px 12px; }
.sidebar nav { display: flex; flex-direction: column; gap: 6px; margin-top: 42px; }
.nav-label + nav { margin-top: 0; }
.nav-item { display: flex; align-items: center; gap: 11px; min-height: 46px; padding: 12px; border-radius: 8px; font-size: 13px; color: #626e5a; width: 100%; text-align: left; }
.nav-item > .icon { width: 18px; height: 18px; }
.nav-item.selected { background: #e1e7d8; color: #364d37; font-weight: 600; }
.nav-item:hover { background: #e7e9df; }
.nav-count { margin-left: auto; font-size: 11px; background: #d4deca; min-width: 21px; min-height: 21px; display: grid; place-items: center; border-radius: 5px; padding: 0 4px; }
.sidebar-bottom { margin-top: auto; padding-top: 28px; }
.sidebar-note { font: italic 21px/1.55 var(--serif); color: var(--muted); margin: 24px 12px; }
.local-note { display: flex; gap: 7px; align-items: flex-start; font-size: 11px; color: var(--muted); margin: 22px 10px 0; line-height: 1.6; }
.local-note .tiny-dot { margin-top: 6px; }
.tiny-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: #788d63; flex-shrink: 0; }

main { margin-left: 224px; padding: 35px clamp(28px, 4.2vw, 72px) 24px; min-height: 100vh; max-width: 1460px; }
.page-top { display: flex; align-items: center; justify-content: space-between; gap: 20px; color: var(--muted); font-size: 12px; padding-bottom: 30px; min-height: 45px; }
.quiet-label { display: flex; align-items: center; gap: 8px; font-size: 11px; }
.quiet-label .icon { width: 14px; height: 14px; }
.page-intro { margin: 17px 0 30px; }
.eyebrow { font-size: 10px; letter-spacing: 1.6px; font-weight: 600; color: #5d704e; line-height: 1.8; }
.page-intro h1 { font-size: clamp(35px, 3.5vw, 48px); line-height: 1.16; letter-spacing: -1.65px; margin: 10px 0 13px; text-wrap: balance; }
.page-intro > p, .page-intro > div > p { font-size: 14px; color: var(--muted); max-width: 65ch; }
.notice { padding: 14px 18px; border: 1px solid #d7c7a3; background: #f6efdc; color: #746340; font-size: 13px; line-height: 1.6; border-radius: 8px; margin-bottom: 20px; overflow-wrap: anywhere; }

/* The task form is the primary action; the illustration supplies quiet company. */
.focus-card { display: grid; grid-template-columns: minmax(0, .96fr) minmax(0, 1fr); min-height: 398px; border: 1px solid #dce2d1; border-radius: 16px; overflow: hidden; background: var(--paper); box-shadow: 0 5px 24px #45493604; }
.companion-panel { position: relative; background: var(--sage); display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 22px 12px 30px; overflow: hidden; border-right: 1px solid #dce2d1; }
.companion-panel::before { content: ''; position: absolute; inset: 0; pointer-events: none; opacity: .6; background: radial-gradient(ellipse at 45% 35%, #fff7df 0%, transparent 65%); }
.companion-scene { width: 100%; height: auto; max-width: 540px; position: relative; display: block; }
.scene-caption { display: flex; align-items: center; gap: 8px; justify-content: center; font-size: 12px; line-height: 1.6; color: #5f6c53; margin-top: -6px; position: relative; text-align: center; }
.scene-caption .tiny-dot { width: 5px; height: 5px; }
.session-form { padding: 32px; display: flex; flex-direction: column; min-width: 0; }
.session-form h2 { font-size: 28px; line-height: 1.25; letter-spacing: -.6px; margin: 7px 0 23px; }
.task-label { display: block; font-size: 13px; font-weight: 500; color: #52634a; margin-bottom: 9px; }
textarea { resize: vertical; min-height: 82px; max-height: 240px; width: 100%; background: #fbfaf6; border: 1px solid #cbd3c0; border-radius: 8px; color: var(--ink); padding: 12px 14px; line-height: 1.6; font-size: 15px; }
textarea::placeholder { color: #747c6c; opacity: 1; }
textarea:hover { border-color: #aebc9f; }
.input-hint { font-size: 12px; color: var(--muted); margin-top: 8px; line-height: 1.5; }
.duration-field { border: 0; padding: 0; margin: 25px 0 22px; min-width: 0; }
.duration-field legend { font-size: 13px; color: #52634a; margin-bottom: 10px; padding: 0; }
.duration-options { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; }
.duration-option { border: 1px solid #d9dfd0; border-radius: 7px; padding: 9px 6px; min-height: 44px; font-size: 12px; white-space: nowrap; color: #5e6c52; }
.duration-option:hover { background: #f0f2e9; border-color: #b9c6aa; }
.duration-option.selected { color: #354f30; border-color: #8ca47a; background: #e6eddd; box-shadow: inset 0 0 0 1px #8ca47a; font-weight: 600; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 10px; border-radius: 8px; min-height: 46px; padding: 12px 18px; font-size: 14px; font-weight: 500; line-height: 1.4; }
.button .icon { height: 17px; width: 17px; }
.button.primary { background: #496346; color: #fffdf5; border: 1px solid #496346; }
.button.primary:hover { background: #3c553a; border-color: #3c553a; box-shadow: 0 3px 9px #263d291a; }
.button.secondary { border: 1px solid #cdd6c1; background: #fbfaf5; color: #4f6144; }
.button.secondary:hover { background: #edf1e5; border-color: #afbf9f; }
.start-button { width: 100%; justify-content: space-between; padding-left: 19px; padding-right: 19px; }
.form-footnote { font-size: 12px; color: var(--muted); text-align: center; margin-top: 12px; }
.text-button { font-size: 12px; color: #526a43; padding: 6px 0; min-height: 36px; display: inline-flex; align-items: center; gap: 7px; line-height: 1.5; text-align: left; }
.text-button:hover { color: #304d29; text-decoration: underline; text-underline-offset: 4px; }
.text-button .icon { width: 14px; height: 14px; }

/* A short selection of updates, with attribution and actions easy to scan. */
.updates-section { margin-top: 40px; }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.section-heading h2 { font-size: 27px; letter-spacing: -.6px; margin: 5px 0 8px; line-height: 1.25; }
.section-heading p { font-size: 12px; color: var(--muted); max-width: 70ch; }
.selection-label { font-size: 11px; display: flex; align-items: center; gap: 7px; white-space: nowrap; color: #5d704e; }
.selection-label .icon { height: 16px; width: 16px; }
.updates-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.update-card { padding: 20px; background: var(--paper); border: 1px solid var(--line); border-radius: 11px; display: flex; flex-direction: column; min-height: 248px; min-width: 0; transition: border-color .2s, box-shadow .2s; }
.update-card:hover { border-color: #bfcbb0; box-shadow: 0 4px 16px #34492b05; }
.card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: -6px -7px 11px 0; }
.category-mark { display: flex; align-items: center; gap: 7px; text-transform: uppercase; letter-spacing: 1px; font-size: 10px; color: #60774e; font-weight: 600; }
.category-mark .icon { height: 16px; width: 16px; }
.category-learning .category-mark { color: #5d7766; }
.category-helping .category-mark { color: #91634e; }
.category-fixing .category-mark { color: #75733f; }
.icon-button { padding: 10px; display: inline-flex; align-items: center; justify-content: center; border-radius: 7px; min-width: 40px; min-height: 40px; color: #68795a; flex-shrink: 0; }
.icon-button > .icon { height: 18px; width: 18px; }
.icon-button:hover { background: #e9ede0; color: #496346; }
.icon-button.is-saved { background: #e7eddd; color: #496346; }
.update-card h3 { font: 21px/1.35 var(--serif); letter-spacing: -.2px; margin-bottom: 10px; overflow-wrap: anywhere; }
.card-description { font-size: 13px; color: var(--muted); line-height: 1.7; margin-bottom: 20px; overflow-wrap: anywhere; }
.card-source { display: flex; flex-direction: column; gap: 4px; margin-top: auto; font-size: 11px; color: var(--muted); line-height: 1.6; padding-top: 4px; }
.card-source span { overflow-wrap: anywhere; }
.card-source span:first-child { color: #506442; }
.source-link { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 44px; margin-top: 15px; padding-top: 9px; border-top: 1px solid #e2e7d9; font-size: 12px; color: #526b43; }
.source-link .icon { width: 14px; height: 14px; }
.source-link:hover { color: #314b2f; text-decoration: underline; text-underline-offset: 3px; }
.card-evidence { font-size: 11px; align-self: flex-start; color: var(--muted); }
.updates-footnote { display: flex; gap: 20px; justify-content: space-between; align-items: flex-start; color: var(--muted); font-size: 11px; line-height: 1.6; margin-top: 16px; }
.updates-footnote > span { padding-top: 7px; }
.updates-footnote .text-button { font-size: 11px; white-space: nowrap; }
.loading-card, .empty-updates { display: flex; align-items: center; gap: 20px; border: 1px solid #d9e1cc; background: #f0f3e8; border-radius: 10px; padding: 28px; }
.loading-card > .loading-leaf, .empty-updates > .icon { color: #748e5e; }
.loading-card h3, .empty-updates h3 { font: 22px/1.35 var(--serif); margin-bottom: 7px; }
.loading-card p, .empty-updates p { font-size: 13px; color: var(--muted); }
.loading-leaf { animation: breathe 2s ease-in-out infinite; }
.loading-leaf > .icon { width: 27px; height: 27px; }
.page-footer { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-top: 40px; padding-top: 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; }
.page-footer > span { font-family: var(--serif); font-size: 14px; font-style: italic; }
.page-footer button { font-size: 11px; display: flex; align-items: center; gap: 10px; color: var(--muted); min-height: 36px; line-height: 1.6; text-align: right; }
.page-footer .icon { width: 14px; height: 14px; }
.page-footer button:hover { color: #3e5b31; }

/* Session states keep their controls in the same part of the card. */
.active-session { justify-content: center; }
.active-task { overflow-wrap: anywhere; }
.session-form .active-task { font-size: 27px; margin-bottom: 24px; }
.timer { font-family: var(--serif); font-size: clamp(65px, 6.4vw, 86px); line-height: 1; letter-spacing: -3px; font-variant-numeric: tabular-nums; color: #486044; margin: 0 0 15px; overflow-wrap: anywhere; }
.timer-note { font-size: 13px; color: var(--muted); min-height: 34px; }
.session-actions { display: flex; gap: 10px; margin-top: 22px; }
.session-actions .primary { flex: 1; justify-content: space-between; }
.pause-button { min-width: 106px; }
.smaller-step { font-size: 12px; align-self: flex-start; margin-top: 16px; }
.quiet-space { display: flex; align-items: center; gap: 20px; margin: 34px auto; max-width: 540px; }
.quiet-space > .icon { height: 32px; width: 32px; color: #7b906a; stroke-width: 1; }
.quiet-space h3 { font: 21px/1.35 var(--serif); color: #516447; margin-bottom: 7px; }
.quiet-space p { font-size: 13px; color: var(--muted); }
.return-intro { display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.session-pill { display: flex; gap: 8px; align-items: center; border: 1px solid #d4dec7; border-radius: 30px; background: #edf1e5; padding: 10px 14px; color: #5c714c; font-size: 12px; white-space: nowrap; }
.session-pill .icon { width: 15px; height: 15px; }
.return-card { display: flex; gap: 24px; align-items: center; background: #edf0e4; border: 1px solid #d9e2cb; border-radius: 14px; padding: 20px 30px 20px 8px; }
.return-card > div { min-width: 0; }
.return-scene { width: 245px; flex-shrink: 0; }
.return-card h2 { font-size: 28px; line-height: 1.25; margin: 8px 0 10px; overflow-wrap: anywhere; }
.return-card p { font-size: 13px; color: var(--muted); }
.return-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 20px; }
.return-actions .button, .return-actions .text-button { font-size: 12px; }
.saved-grid { row-gap: 20px; }
.empty-page { border: 1px solid #dce3d2; background: #f0f3e8; padding: 55px 24px; text-align: center; border-radius: 14px; min-height: 350px; }
.empty-symbol { display: inline-flex; justify-content: center; align-items: center; background: #e3e9d8; width: 54px; height: 54px; border-radius: 50%; color: #71875c; margin-bottom: 23px; }
.empty-symbol .icon { width: 24px; height: 24px; stroke-width: 1.3; }
.empty-page h2 { font-size: 30px; line-height: 1.3; letter-spacing: -.7px; margin-bottom: 15px; }
.empty-page p { font-size: 14px; color: var(--muted); margin-bottom: 25px; }
.empty-page .button { min-width: 190px; }
.history-list { border: 1px solid #dce3d2; border-radius: 11px; overflow: hidden; background: var(--paper); }
.history-row { display: flex; align-items: center; gap: 18px; width: 100%; text-align: left; padding: 21px 24px; border-bottom: 1px solid #e3e8da; }
.history-row:last-child { border-bottom: 0; }
.history-row:hover { background: #f0f3e9; }
.history-icon { width: 40px; height: 40px; flex-shrink: 0; display: grid; place-items: center; border-radius: 50%; background: #edf0e4; color: #738960; }
.history-detail { display: flex; flex-direction: column; gap: 7px; min-width: 0; flex: 1; }
.history-detail strong { font: 21px/1.35 var(--serif); overflow-wrap: anywhere; }
.history-detail > span, .history-time { font-size: 12px; color: var(--muted); line-height: 1.5; }
.history-row > .icon { width: 17px; height: 17px; color: #738960; }
.subtle-note { font-size: 12px; color: var(--muted); line-height: 1.8; margin-top: 18px; }

/* Dialogs remain readable at enlarged text and short viewport heights. */
dialog { background: var(--paper); border: 1px solid #d1dbc4; border-radius: 15px; color: var(--ink); padding: 30px; width: 520px; max-width: calc(100vw - 32px); max-height: calc(100dvh - 40px); box-shadow: 0 20px 80px #24302426; overflow-wrap: anywhere; }
dialog::backdrop { background: #2d382d55; backdrop-filter: blur(4px); }
.dialog-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.dialog-heading h2 { font-size: 28px; letter-spacing: -.6px; line-height: 1.25; }
.dialog-heading .icon-button { margin-top: -6px; margin-right: -9px; }
dialog > p { font-size: 14px; color: var(--muted); margin: 15px 0; }
.dialog-intro { margin-bottom: 23px; }
.setting-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin: 24px 0; min-height: 44px; cursor: pointer; }
.setting-row strong, .settings-section h3 { font-size: 14px; font-weight: 600; }
.setting-row small { display: block; font-size: 13px; color: var(--muted); margin-top: 7px; line-height: 1.6; }
.setting-row input { accent-color: #496346; width: 21px; height: 21px; flex-shrink: 0; }
.settings-section { margin-top: 25px; border-top: 1px solid #dfe6d5; padding-top: 22px; }
.settings-section p { font-size: 13px; color: var(--muted); margin-top: 10px; }
.settings-buttons { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.import-label { position: relative; cursor: pointer; overflow: hidden; }
.import-label input { position: absolute; inset: 0; opacity: 0; width: 100%; cursor: pointer; }
.import-label:focus-within { outline: 3px solid #58784e; outline-offset: 4px; }
.dialog-feedback { color: #8c624f !important; }
.danger { color: #89553e; font-size: 12px; margin-top: 14px; }
.source-description { border-top: 1px solid #dfe6d5; padding-top: 21px; margin: 21px 0; }
.source-description p { font-size: 13px; color: var(--muted); margin-top: 11px; }
.about-note { background: #edf1e4; border-radius: 9px; padding: 20px; display: flex; gap: 16px; align-items: center; margin: 23px 0; color: #5b754a; font: 20px/1.5 var(--serif); }
.gentle-list { padding-left: 22px; color: #596e4a; font-size: 14px; line-height: 2.2; }
.source-status { margin: 20px 0; font-size: 13px; color: var(--muted); }
.source-status summary { cursor: pointer; padding: 10px 0; line-height: 1.5; }
.source-status ul { padding-left: 17px; line-height: 1.6; }
.source-status li { margin: 12px 0; }
.source-status li span { display: block; color: var(--muted); }
.evidence-list { font-size: 13px; line-height: 1.6; }
.evidence-list dt { color: #546c44; font-weight: 600; margin-top: 17px; }
.evidence-list dd { margin: 5px 0 0; color: var(--muted); overflow-wrap: anywhere; }
.noscript { font-family: var(--serif); padding: 80px 40px; max-width: 600px; margin: auto; }
#toast { position: fixed; bottom: 24px; left: calc(50% + 112px); transform: translate(-50%,20px); opacity: 0; pointer-events: none; z-index: 15; border-radius: 9px; padding: 13px 20px; background: #3f563a; color: #f5f7ed; font-size: 13px; line-height: 1.5; max-width: calc(100vw - 270px); box-shadow: 0 6px 22px #34472920; transition: transform .2s, opacity .2s; }
#toast.visible { transform: translate(-50%,0); opacity: 1; }
@keyframes breathe { 50% { opacity: .45; transform: translateY(-3px); } }

@media (min-width: 1500px) {
  .focus-card { min-height: 450px; }
  .session-form { padding: 40px; }
  .session-form h2 { font-size: 32px; }
  .companion-panel { padding: 24px 20px 32px; }
  .page-intro { margin-top: 25px; margin-bottom: 36px; }
  .update-card { padding: 24px; }
}

@media (max-width: 1150px) {
  .sidebar { width: 196px; padding: 30px 16px 22px; }
  .workspace-mark { font-size: 15px; gap: 9px; }
  .workspace-mark > .icon { width: 27px; height: 27px; }
  .nav-item { font-size: 12px; gap: 10px; }
  .local-note { font-size: 10px; margin-left: 8px; margin-right: 3px; }
  main { margin-left: 196px; padding: 30px; }
  .session-form { padding: 28px; }
  .session-form h2 { font-size: 26px; }
  .duration-options { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .updates-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .return-scene { width: 190px; }
  .return-card { gap: 12px; padding-right: 26px; }
  .session-actions { flex-wrap: wrap; }
  .session-actions .primary, .session-actions .pause-button { min-width: 100%; }
  #toast { left: calc(50% + 98px); max-width: calc(100vw - 235px); }
}

@media (max-width: 900px) {
  .quiet-label { display: none; }
  .focus-card { grid-template-columns: minmax(0, .8fr) minmax(0, 1fr); }
  .session-form { padding: 26px 22px; }
  .companion-panel { padding-left: 0; padding-right: 0; }
  .scene-caption { font-size: 11px; padding: 0 12px; }
  .selection-label { display: none; }
  .updates-footnote { flex-direction: column; gap: 3px; }
  .return-card { gap: 8px; padding-right: 22px; }
  .return-scene { width: 155px; }
  .return-card h2 { font-size: 25px; }
  .page-footer { flex-wrap: wrap; gap: 5px 20px; }
}

@media (max-width: 760px) {
  .sidebar { width: 100%; position: static; padding: 14px 22px 0; display: flex; border-right: 0; border-bottom: 1px solid var(--line); flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; overflow: visible; }
  .workspace-mark { font-size: 16px; padding: 0; gap: 9px; }
  .workspace-mark > .icon { width: 27px; height: 27px; }
  .nav-label, .sidebar-note, .local-note { display: none; }
  .sidebar nav, .nav-label + nav { flex-direction: row; width: 100%; order: 3; gap: 20px; margin-top: 10px; }
  .nav-item { font-size: 13px; gap: 8px; padding: 12px 2px; border-radius: 0; border-bottom: 2px solid transparent; min-height: 46px; white-space: nowrap; }
  .nav-item.selected { background: transparent; border-bottom-color: #607c4b; color: #3e5b35; }
  .nav-item:hover { background: transparent; }
  .sidebar nav .nav-item { width: auto; }
  .sidebar-bottom { margin: 0; padding: 0; display: flex; gap: 4px; }
  .sidebar-bottom .nav-item { min-height: 44px; min-width: 40px; padding: 10px; border: 0; }
  .sidebar-bottom .nav-item span { display: none; }
  .sidebar-bottom .nav-item > .icon { width: 19px; height: 19px; }
  .nav-count { font-size: 10px; min-width: 18px; min-height: 18px; }
  main { margin: 0; padding: 25px 26px; }
  .page-top { padding-bottom: 0; min-height: 20px; }
  .page-intro { margin: 25px 0; }
  .page-intro h1 { font-size: 38px; letter-spacing: -1.3px; }
  .focus-card { grid-template-columns: minmax(0, .85fr) minmax(0, 1fr); }
  .session-form { padding: 28px 24px; }
  #toast { left: 50%; max-width: calc(100vw - 32px); }
}

@media (max-width: 600px) {
  .sidebar { padding-left: 20px; padding-right: 20px; }
  main { padding: 22px 20px; }
  .page-intro { margin: 23px 0; }
  .page-intro h1 { font-size: 35px; line-height: 1.17; }
  .page-intro > p, .page-intro > div > p { font-size: 14px; }
  .focus-card { grid-template-columns: minmax(0, 1fr); }
  .companion-panel { padding: 0 24px 17px; border-right: 0; border-bottom: 1px solid #dce2d1; height: 218px; }
  .companion-panel .companion-scene { width: 280px; max-width: 100%; margin-top: -15px; max-height: 208px; }
  .scene-caption { font-size: 12px; margin-top: -9px; }
  .session-form { padding: 25px 24px; }
  .session-form h2 { font-size: 27px; margin: 5px 0 21px; }
  .session-form h2 br { display: none; }
  textarea { font-size: 16px; min-height: 82px; }
  .duration-options { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .duration-option { font-size: 12px; }
  .duration-field { margin: 23px 0 20px; }
  .button { min-height: 46px; }
  .form-footnote { text-align: left; font-size: 12px; }
  .updates-section { margin-top: 32px; }
  .section-heading { margin-bottom: 18px; }
  .section-heading h2 { font-size: 26px; }
  .updates-grid { grid-template-columns: minmax(0, 1fr); gap: 15px; }
  .update-card { padding: 21px 22px 17px; min-height: 230px; }
  .update-card h3 { font-size: 23px; }
  .card-description { font-size: 14px; margin-bottom: 16px; }
  .category-mark { font-size: 11px; }
  .card-source { font-size: 12px; }
  .source-link, .card-evidence { font-size: 12px; min-height: 44px; }
  .icon-button { min-width: 44px; min-height: 44px; }
  .updates-footnote { font-size: 12px; gap: 4px; }
  .updates-footnote .text-button { font-size: 12px; min-height: 44px; }
  .page-footer { margin-top: 29px; padding-top: 16px; }
  .page-footer button { font-size: 11px; min-height: 44px; text-align: left; }
  .empty-updates, .loading-card { padding: 23px 20px; gap: 15px; align-items: flex-start; }
  .empty-updates > .icon, .loading-leaf { margin-top: 3px; }
  .empty-updates h3, .loading-card h3 { font-size: 21px; }
  .active-card .active-session { order: -1; }
  .active-card .companion-panel { height: 172px; border-top: 1px solid #dce2d1; border-bottom: 0; padding-bottom: 12px; }
  .active-card .companion-scene { width: 215px; max-height: 162px; margin-top: -19px; }
  .active-card .scene-caption { margin-top: -6px; font-size: 11px; }
  .timer { font-size: 76px; margin-bottom: 14px; }
  .session-form .active-task { font-size: 26px; margin-bottom: 22px; }
  .session-actions { flex-wrap: nowrap; margin-top: 18px; }
  .session-actions .primary, .session-actions .pause-button { min-width: 0; }
  .session-actions .pause-button { min-width: 103px; }
  .smaller-step { margin-top: 10px; min-height: 44px; }
  .quiet-space { margin: 28px 3px; gap: 16px; }
  .quiet-space h3 { font-size: 21px; }
  .return-intro { align-items: flex-start; gap: 12px; flex-wrap: wrap; }
  .session-pill { font-size: 12px; padding: 9px 12px; }
  .return-card { flex-direction: column; padding: 0 24px 25px; gap: 0; align-items: flex-start; }
  .return-scene { width: 220px; align-self: center; margin-top: -6px; margin-bottom: -15px; }
  .return-card h2 { font-size: 27px; }
  .return-card p { font-size: 14px; }
  .return-actions { gap: 9px; margin-top: 18px; }
  .return-actions .button, .return-actions .text-button { font-size: 13px; min-height: 44px; }
  .history-row { padding: 19px 17px; gap: 12px; }
  .history-icon { width: 33px; height: 33px; }
  .history-icon .icon { width: 18px; height: 18px; }
  .history-detail strong { font-size: 20px; }
  .history-detail > span, .history-time { font-size: 12px; }
  .history-time { max-width: 65px; text-align: right; }
  .history-row > .icon { display: none; }
  .empty-page { padding: 42px 22px; }
  .empty-page h2 { font-size: 28px; }
  .empty-page p br { display: none; }
  dialog { padding: 25px; max-height: calc(100dvh - 28px); }
  .dialog-heading h2 { font-size: 27px; }
  .settings-buttons .button { flex: 1; }
  #toast { bottom: 16px; width: max-content; white-space: normal; }
}

@media (max-width: 380px) {
  .sidebar { padding-left: 16px; padding-right: 16px; }
  .sidebar nav { gap: 14px; }
  .sidebar nav .nav-item { font-size: 12px; gap: 6px; }
  .sidebar nav .nav-item > .icon { width: 16px; height: 16px; }
  main { padding-left: 16px; padding-right: 16px; }
  .page-intro h1 { font-size: 32px; }
  .session-form { padding: 23px 20px; }
  .duration-options { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .session-actions { flex-wrap: wrap; }
  .session-actions .primary, .session-actions .pause-button { min-width: 100%; }
  .return-card { padding-left: 20px; padding-right: 20px; }
  .return-actions { align-items: stretch; flex-direction: column; width: 100%; }
  .return-card > div:last-child { width: 100%; }
}

@media (max-width: 320px) {
  .sidebar nav { gap: 12px; }
  .sidebar nav .nav-item > .icon { display: none; }
  .workspace-mark { font-size: 15px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
.reduce-motion *, .reduce-motion *::before, .reduce-motion *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }

/* The second-tab notice has no sidebar or writable session controls. */
main.workspace-gate { margin: 0; min-height: 100dvh; padding: 24px; max-width: none; display: grid; place-items: center; }
.workspace-gate .empty-page { width: 100%; max-width: 560px; margin: 0; }
.workspace-gate h1 { font-size: clamp(28px, 5vw, 38px); line-height: 1.2; }
