/* HomeGrip charcoal: quiet neutral surfaces, the existing lime-green brand,
   open content rails and a bright accent reserved for action and status. */
.hg-shell {
  color-scheme: var(--hg-color-scheme);
  --hg-color-scheme: dark;
  --hg-canvas: #0f0f10;
  --hg-ink: #f3f3f1;
  --hg-ink-2: #c4c4c8;
  --hg-muted: #9a9a9f;
  --hg-accent: #d7f068;
  --hg-accent-strong: #e5ff8d;
  --hg-accent-soft: #25291b;
  --hg-on-accent: #141a12;
  --hg-surface: #171718;
  --hg-surface-2: #1f1f21;
  --hg-surface-3: #2a2a2d;
  --hg-line: #2a2a2e;
  --hg-line-strong: #68686e;
  --hg-amber-soft: #30291a;
  --hg-amber-ink: #edc77c;
  --hg-red: #ff9a8d;
  --hg-red-soft: #34221f;
  --hg-coral: #f5ac85;
  --hg-coral-soft: #30251e;
  --hg-pet-soft: #292335;
  --hg-pet-ink: #ccbbec;
  --hg-radius-lg: 16px;
  --hg-shadow-sm: none;
  --hg-shadow-md: 0 20px 60px rgba(0, 0, 0, 0.38);
  --hg-topbar: rgba(15, 15, 16, 0.96);
  --hg-dialog-backdrop: rgba(0, 0, 0, 0.72);
  --hg-info: #9bb43a;
}

html[data-theme="light"] .hg-shell {
  --hg-color-scheme: light;
  --hg-canvas: #f7f8f5;
  --hg-ink: #17211c;
  --hg-ink-2: #39483f;
  --hg-muted: #5b685f;
  --hg-accent: #2f6b4f;
  --hg-accent-strong: #24563f;
  --hg-accent-soft: #e8efdc;
  --hg-on-accent: #ffffff;
  --hg-surface: #ffffff;
  --hg-surface-2: #eef1ec;
  --hg-surface-3: #e1e7df;
  --hg-line: #d7ded7;
  --hg-line-strong: #7f8c83;
  --hg-amber-soft: #f7edd8;
  --hg-amber-ink: #775313;
  --hg-red: #a2392e;
  --hg-red-soft: #f8e8e5;
  --hg-coral: #954e2f;
  --hg-coral-soft: #f8e9e0;
  --hg-pet-soft: #eee9f6;
  --hg-pet-ink: #584575;
  --hg-shadow-md: 0 20px 60px rgba(31, 43, 36, 0.16);
  --hg-topbar: rgba(247, 248, 245, 0.96);
  --hg-dialog-backdrop: rgba(18, 27, 22, 0.48);
  --hg-info: #52712d;
}

html[data-theme="dark"] { color-scheme: dark; background: #0f0f10; }
html[data-theme="light"] { color-scheme: light; background: #f7f8f5; }

/* Base */
.hg-shell, .hg-shell *, .hg-shell *::before, .hg-shell *::after { box-sizing: border-box; }
body.hg-shell { margin: 0; min-height: 100dvh; display: flex; flex-direction: column; background: var(--hg-canvas); color: var(--hg-ink); font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif; font-size: 16px; line-height: 1.5; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
.hg-shell h1, .hg-shell h2, .hg-shell h3, .hg-shell h4 { margin: 0; font-weight: 700; line-height: 1.2; letter-spacing: -0.02em; overflow-wrap: anywhere; }
.hg-shell p { margin: 0; }
:where(.hg-shell) a { color: var(--hg-ink-2); text-underline-offset: 3px; }
:where(.hg-shell) button, :where(.hg-shell) input, :where(.hg-shell) select, :where(.hg-shell) textarea { font: inherit; color: inherit; }
.hg-shell button { cursor: pointer; }
.hg-shell :focus-visible { outline: 2px solid var(--hg-accent); outline-offset: 3px; border-radius: 4px; }
.hg-shell summary { list-style: none; }
.hg-shell summary::-webkit-details-marker { display: none; }
.hg-sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.hg-skip-link { position: absolute; top: -100px; left: 16px; z-index: 100; padding: 10px 14px; border-radius: 10px; background: var(--hg-surface-3); color: var(--hg-ink); font-weight: 600; text-decoration: none; }
.hg-skip-link:focus { top: 12px; }
.hg-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.hg-icon { width: 18px; height: 18px; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.hg-icon-chevron { width: 16px; height: 16px; transition: transform 0.15s ease; }

/* Topbar */
.hg-topbar { position: sticky; top: 0; z-index: 20; background: var(--hg-topbar); backdrop-filter: saturate(160%) blur(10px); -webkit-backdrop-filter: saturate(160%) blur(10px); border-bottom: 1px solid var(--hg-line); }
.hg-topbar-inner { display: flex; align-items: center; gap: 12px; width: 100%; max-width: 1120px; min-height: 64px; margin: 0 auto; padding: 8px 24px; }
.hg-brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: var(--hg-ink); text-decoration: none; }
.hg-brand-mark {
  display: block;
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  background: var(--hg-accent);
  -webkit-mask: url("branding/homegrip-hand-house-mark.2ee6cf32a057.png") center / contain no-repeat;
  mask: url("branding/homegrip-hand-house-mark.2ee6cf32a057.png") center / contain no-repeat;
}
.hg-brand-name { font-size: 17px; font-weight: 700; letter-spacing: -0.02em; }
.hg-switcher { margin-left: 4px; min-width: 0; flex-shrink: 1; }
.hg-brand, .hg-account, .hg-nav { flex-shrink: 0; }
.hg-switcher > summary { display: flex; min-width: 0; width: 100%; }
.hg-switcher-button > .hg-icon { flex-shrink: 0; }
.hg-switcher-button { color: var(--hg-ink); }
.hg-switcher-button > .hg-icon:first-child { color: var(--hg-accent); }
.hg-nav { display: flex; align-items: center; gap: 2px; margin-left: 8px; }
.hg-nav a { display: inline-flex; align-items: center; min-height: 40px; padding: 0 12px; border-radius: 10px; color: var(--hg-ink-2); font-size: 14px; font-weight: 600; text-decoration: none; }
.hg-nav a:hover { background: var(--hg-surface-2); color: var(--hg-ink); }
.hg-nav a[aria-current] { background: var(--hg-surface-3); color: var(--hg-ink); }
.hg-account { margin-left: 0; }
.hg-account-button { padding-left: 6px; }
.hg-theme-toggle { display: inline-grid; place-items: center; flex: 0 0 44px; width: 44px; height: 44px; margin-left: auto; padding: 0; border: 1px solid transparent; border-radius: 12px; background: transparent; color: var(--hg-ink-2); }
.hg-theme-toggle:hover { border-color: var(--hg-line); background: var(--hg-surface-2); color: var(--hg-ink); }
.hg-theme-toggle .hg-icon { width: 19px; height: 19px; }
.hg-theme-icon-dark { display: none; }
html[data-theme="light"] .hg-theme-icon-light { display: none; }
html[data-theme="light"] .hg-theme-icon-dark { display: block; }

/* Popovers (details-based menus) */
.hg-popover { position: relative; }
.hg-popover > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 4px 8px; border-radius: 12px; }
.hg-popover > summary::-webkit-details-marker { display: none; }
.hg-popover > summary:hover { background: var(--hg-surface-2); }
.hg-popover[open] > summary .hg-icon-chevron { transform: rotate(180deg); }
.hg-popover form { margin: 0; }
.hg-switcher-name { min-width: 0; max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; font-weight: 600; }
.hg-popover-panel { position: absolute; top: calc(100% + 8px); left: 0; z-index: 30; min-width: 268px; max-width: min(360px, calc(100vw - 32px)); padding: 8px; background: var(--hg-surface); border: 1px solid var(--hg-line); border-radius: 16px; box-shadow: var(--hg-shadow-md); }
.hg-popover-right { left: auto; right: 0; }
.hg-account .hg-popover-panel { max-height: calc(100dvh - 80px); overflow-y: auto; overscroll-behavior: contain; }
.hg-popover-title { overflow-wrap: anywhere; margin: 0; padding: 8px 10px 6px; font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--hg-muted); }
.hg-popover-row { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px; padding: 6px 10px; border: 0; border-radius: 10px; background: transparent; color: var(--hg-ink); font-size: 14px; text-align: left; text-decoration: none; cursor: pointer; }
.hg-popover-row:hover { background: var(--hg-surface-2); }
.hg-popover-row.is-current { color: var(--hg-accent); font-weight: 600; cursor: default; }
.hg-popover-row.is-current .hg-icon { margin-left: auto; }
.hg-popover-row-label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hg-popover-quiet { color: var(--hg-muted); }
.hg-popover-divider { height: 1px; margin: 6px 4px; background: var(--hg-line); }
.hg-popover-note { margin: 0; padding: 2px 10px 8px; font-size: 13px; color: var(--hg-muted); }
.hg-popover-create { display: flex; gap: 8px; margin-top: 6px; padding: 10px 6px 4px; border-top: 1px solid var(--hg-line); }
.hg-popover-create input { flex: 1; min-width: 0; }
.hg-popover-mobile-only { display: none; }

/* Avatars, tags */
.hg-avatar { width: 32px; height: 32px; border-radius: 50%; display: inline-grid; place-items: center; flex-shrink: 0; background: var(--hg-surface-3); color: var(--hg-ink-2); font-size: 13px; font-weight: 700; }
.hg-avatar-home { border-radius: 10px; background: var(--hg-accent-soft); color: var(--hg-ink); }
.hg-avatar-more { background: var(--hg-surface-3); color: var(--hg-ink-2); font-size: 12px; }
.hg-avatar-stack { display: inline-flex; }
.hg-avatar-stack .hg-avatar { box-shadow: 0 0 0 2px var(--hg-canvas); }
.hg-avatar-stack .hg-avatar + .hg-avatar { margin-left: -8px; }
.hg-member-list { list-style: none; margin: 0; padding: 0 2px; }
.hg-member-list li { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 4px 8px; font-size: 14px; }
.hg-member-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hg-tag { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px; background: var(--hg-surface-3); color: var(--hg-ink-2); font-size: 11px; font-weight: 700; letter-spacing: 0.02em; white-space: nowrap; }
.hg-tag-good { background: var(--hg-surface-2); color: var(--hg-ink-2); }
.hg-tag-warn { background: var(--hg-amber-soft); color: var(--hg-amber-ink); }
.hg-tag .hg-icon { width: 12px; height: 12px; stroke-width: 2.2; }

/* Main, notices, footer */
.hg-main { flex: 1; width: 100%; max-width: 1120px; margin: 0 auto; padding: 32px 24px 72px; }
.hg-notices { display: grid; gap: 10px; margin-bottom: 24px; }
.hg-notice { display: flex; align-items: center; gap: 12px; padding: 10px 8px 10px 16px; border-radius: 12px; border-left: 4px solid var(--hg-ink-2); background: var(--hg-surface-2); }
.hg-notice p { flex: 1; margin: 0; font-size: 14px; }
.hg-notice.success { background: var(--hg-accent-soft); border-color: var(--hg-accent); }
.hg-notice.info { background: var(--hg-accent-soft); border-color: var(--hg-info); }
.hg-notice.warning { background: var(--hg-amber-soft); border-color: var(--hg-amber-ink); }
.hg-notice.error { background: var(--hg-red-soft); border-color: var(--hg-red); }
.hg-footer { width: 100%; max-width: 1120px; margin: 0 auto; padding: 16px 24px 32px; display: flex; gap: 20px; font-size: 13px; color: var(--hg-muted); }
.hg-footer a { display: inline-flex; align-items: center; min-height: 44px; color: var(--hg-muted); text-decoration: none; }
.hg-footer a:hover { color: var(--hg-ink); }
.hg-footer span { display: inline-flex; align-items: center; margin-left: auto; }

/* Buttons */
.hg-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px; border: 1px solid transparent; border-radius: 12px; font-size: 15px; font-weight: 600; text-decoration: none; white-space: nowrap; cursor: pointer; transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.15s ease; }
.hg-btn:active { transform: translateY(1px); }
.hg-btn-primary { background: var(--hg-accent); color: var(--hg-on-accent); }
.hg-btn-primary:hover { background: var(--hg-accent-strong); }
.hg-btn-secondary { background: var(--hg-surface); color: var(--hg-ink); border-color: var(--hg-line-strong); }
.hg-btn-secondary:hover { background: var(--hg-surface-2); }
.hg-btn-ghost { background: transparent; color: var(--hg-ink-2); }
.hg-btn-ghost:hover { background: var(--hg-surface-2); color: var(--hg-ink); }
.hg-btn-danger { background: var(--hg-surface); color: var(--hg-red); border-color: var(--hg-red-soft); }
.hg-btn-danger:hover { background: var(--hg-red-soft); }
.hg-btn-small { min-height: 36px; padding: 6px 12px; border-radius: 10px; font-size: 14px; }
.hg-btn[aria-disabled="true"] { opacity: 0.7; pointer-events: none; }
.hg-link-button { padding: 0; min-height: 0; border: 0; background: none; color: var(--hg-ink-2); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.hg-icon-btn { width: 40px; height: 40px; border: 0; border-radius: 10px; background: transparent; color: var(--hg-muted); display: inline-grid; place-items: center; cursor: pointer; }
.hg-icon-btn:hover { background: var(--hg-surface-2); color: var(--hg-ink); }
.hg-shell .loading-spinner { display: inline-block; width: 14px; height: 14px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: hg-spin 0.8s linear infinite; }
.hg-shell .is-loading { opacity: 0.75; }
@keyframes hg-spin { to { transform: rotate(360deg); } }

/* First use */
.hg-welcome { max-width: 720px; margin: 24px auto 0; display: grid; gap: 28px; }
.hg-spark-badge { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px 6px 8px; border-radius: 999px; background: var(--hg-accent-soft); color: var(--hg-ink); font-size: 13px; font-weight: 600; }
.hg-spark-badge .hg-icon { color: var(--hg-accent); }
.hg-welcome h1 { margin: 18px 0 14px; font-size: clamp(36px, 6vw, 60px); line-height: 1.02; letter-spacing: -0.035em; }
.hg-lede { margin: 0; max-width: 58ch; font-size: 18px; line-height: 1.5; color: var(--hg-ink-2); }
.hg-starters { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.hg-starter { display: grid; gap: 4px; min-height: 44px; padding: 16px; border: 1px solid var(--hg-line); border-radius: 16px; background: var(--hg-surface); color: var(--hg-ink); text-align: left; cursor: pointer; transition: border-color 0.15s ease, background-color 0.15s ease, transform 0.15s ease; }
.hg-starter:hover { border-color: var(--hg-line-strong); background: var(--hg-surface-2); transform: translateY(-1px); }
.hg-starter .hg-icon { width: 22px; height: 22px; margin-bottom: 6px; color: var(--hg-accent); }
.hg-starter strong { font-size: 15px; letter-spacing: -0.01em; }
.hg-starter span { font-size: 13px; line-height: 1.4; color: var(--hg-muted); }
.hg-welcome-aside { display: grid; gap: 14px; padding-top: 20px; border-top: 1px solid var(--hg-line); }
.hg-sample { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin: 0; padding: 18px 20px; border-radius: 16px; background: var(--hg-surface-2); }
.hg-sample strong { display: block; font-size: 15px; }
.hg-sample p { margin: 4px 0 0; max-width: 48ch; font-size: 13px; color: var(--hg-muted); }
.hg-welcome-note { margin: 0; font-size: 13px; color: var(--hg-muted); }

/* Dashboard overview */
.hg-overview { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin: 4px 0 32px; }
.hg-eyebrow { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 8px; margin: 0 0 8px; font-size: 13px; font-weight: 600; color: var(--hg-muted); }
.hg-eyebrow .hg-icon { width: 16px; height: 16px; }
.hg-overview h1 { max-width: 900px; font-size: clamp(30px, 4vw, 44px); line-height: 1.08; letter-spacing: -0.03em; text-wrap: balance; }
.hg-overview-sub { margin: 10px 0 0; font-size: 16px; color: var(--hg-ink-2); }
.hg-overview-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px; }
.hg-stat { display: inline-flex; align-items: center; min-height: 36px; padding: 0; background: transparent; color: var(--hg-ink-2); font-size: 13px; font-weight: 600; }
.hg-stat-issue { background: transparent; color: var(--hg-coral); }
.hg-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 36px; align-items: start; }
.hg-main-col { display: grid; gap: 36px; min-width: 0; }
.hg-side-col { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 32px; min-width: 0; }

/* Groups and rows */
.hg-group { min-width: 0; }
.hg-group-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 6px; }
.hg-group-head h2 { display: inline-flex; align-items: center; gap: 10px; font-size: 20px; letter-spacing: -0.02em; }
.hg-count { padding: 2px 9px; border-radius: 999px; background: var(--hg-surface-2); color: var(--hg-muted); font-size: 13px; font-weight: 600; }
.hg-group-sub { margin: 0 0 10px; font-size: 14px; color: var(--hg-muted); }
.hg-rows { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--hg-line); }
.hg-row { display: flex; align-items: center; gap: 14px; min-width: 0; padding: 14px 0; border-bottom: 1px solid var(--hg-line); }
.hg-row[hidden] { display: none; }
.hg-row form { margin: 0; }
.hg-row-icon { width: 38px; height: 38px; border-radius: 12px; display: inline-grid; place-items: center; flex-shrink: 0; background: var(--hg-surface-2); color: var(--hg-ink-2); }
.hg-row-icon .hg-icon { width: 20px; height: 20px; }
.hg-kind-service { background: var(--hg-accent-soft); color: var(--hg-accent); }
.hg-kind-chore { background: var(--hg-accent-soft); color: var(--hg-accent); }
.hg-kind-maintenance { background: var(--hg-amber-soft); color: var(--hg-amber-ink); }
.hg-kind-pet { background: var(--hg-pet-soft); color: var(--hg-pet-ink); }
.hg-kind-issue { background: var(--hg-coral-soft); color: var(--hg-coral); }
.hg-row-body { flex: 1; min-width: 0; }
.hg-row-title { display: block; color: var(--hg-ink); font-size: 15px; font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }
.hg-row-title:hover { text-decoration: underline; text-underline-offset: 3px; }
.hg-row-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 2px 0 0; font-size: 13px; color: var(--hg-muted); overflow-wrap: anywhere; }
.hg-row-missing { color: var(--hg-amber-ink); }
.hg-dot { width: 3px; height: 3px; border-radius: 50%; background: currentColor; opacity: 0.6; flex-shrink: 0; }
.hg-row-side { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.hg-when { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--hg-muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.hg-when .hg-icon { width: 14px; height: 14px; }
.hg-when-due { color: var(--hg-coral); font-weight: 600; }
.hg-row.is-done .hg-row-title { color: var(--hg-muted); text-decoration: line-through; }
.hg-row.is-done .hg-row-icon { opacity: 0.55; }
.hg-done-btn .hg-icon { width: 16px; height: 16px; stroke-width: 2.2; }
.hg-done-list { margin-top: 4px; }
.hg-done-list > summary { list-style: none; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; color: var(--hg-muted); font-size: 14px; font-weight: 600; cursor: pointer; }
.hg-done-list > summary::-webkit-details-marker { display: none; }
.hg-done-list[open] > summary .hg-icon-chevron { transform: rotate(180deg); }
.hg-filters { display: flex; flex-wrap: wrap; gap: 6px; margin: 2px 0 12px; }
.hg-filters[hidden] { display: none; }
.hg-filters button { min-height: 36px; padding: 0 12px; border: 1px solid var(--hg-line); border-radius: 999px; background: var(--hg-surface); color: var(--hg-ink-2); font-size: 13px; font-weight: 600; cursor: pointer; }
.hg-filters button:hover { background: var(--hg-surface-2); }
.hg-filters button[aria-pressed="true"] { background: var(--hg-surface-3); color: var(--hg-ink); border-color: var(--hg-ink); }
.hg-empty { padding: 28px 24px; border-radius: 16px; background: var(--hg-surface-2); text-align: center; }
.hg-empty h3 { margin-bottom: 6px; font-size: 17px; letter-spacing: -0.01em; }
.hg-empty p { margin: 0; font-size: 14px; color: var(--hg-muted); }
.hg-footnote { margin: 14px 0 0; font-size: 13px; color: var(--hg-muted); }
.hg-status { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 14px; background: var(--hg-amber-soft); color: var(--hg-amber-ink); }
.hg-status p { flex: 1; margin: 0; font-size: 14px; color: var(--hg-ink); }
.hg-status form { margin: 0; }
.hg-status-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 12px; }

/* Review of suggestions */
.hg-review { padding: 0; border-radius: 0; background: transparent; }
.hg-review-head { display: flex; align-items: flex-start; gap: 14px; margin-bottom: 18px; }
.hg-review-head .hg-eyebrow { margin-bottom: 2px; color: var(--hg-accent); }
.hg-review-head h2 { font-size: 22px; letter-spacing: -0.02em; }
.hg-review-head p:not(.hg-eyebrow) { margin: 4px 0 0; font-size: 14px; color: var(--hg-ink-2); }
.hg-spark { width: 40px; height: 40px; border-radius: 12px; display: inline-grid; place-items: center; flex-shrink: 0; background: var(--hg-surface-2); color: var(--hg-accent); }
.hg-suggestions { list-style: none; margin: 0; padding: 0; display: grid; border-top: 1px solid var(--hg-line); }
.hg-suggestion { padding: 18px 0; border-bottom: 1px solid var(--hg-line); background: transparent; transition: opacity 0.15s ease; }
.hg-suggestion.is-off { opacity: 0.55; }
.hg-suggestion.has-errors { box-shadow: 0 0 0 2px var(--hg-red); }
.hg-suggestion-row { display: flex; align-items: center; gap: 12px; }
.hg-checkbox { width: 22px; height: 22px; margin: 0; flex-shrink: 0; accent-color: var(--hg-accent); cursor: pointer; }
.hg-suggestion-label { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 0; cursor: pointer; }
.hg-suggestion-text { min-width: 0; }
.hg-suggestion-text strong { display: block; font-size: 15px; overflow-wrap: anywhere; }
.hg-suggestion-edit { margin: 4px 0 0 34px; }
.hg-suggestion-edit > summary { list-style: none; }
.hg-suggestion-edit > summary::-webkit-details-marker { display: none; }
.hg-suggestion-edit[open] > summary .hg-icon-chevron { transform: rotate(180deg); }
.hg-suggestion-edit .hg-fields { margin-top: 10px; padding: 14px 0 4px; border-top: 1px solid var(--hg-line); }
.hg-review-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-top: 18px; }
.hg-review-skip { margin: 12px 0 0; text-align: center; }
.hg-review-skip .hg-link-button { min-height: 44px; color: var(--hg-muted); }
.hg-callout { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 14px; background: var(--hg-amber-soft); }
.hg-callout p { flex: 1; margin: 0; min-width: 200px; font-size: 14px; }
.hg-callout form { margin: 0; }

/* Forms */
.hg-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; align-items: start; }
.hg-fields [hidden] { display: none !important; }
.hg-field { display: grid; gap: 6px; min-width: 0; }
.hg-field-title, .hg-field-notes, .hg-field-name, .hg-field-address, .hg-field-participants, .hg-field-person-picker, .hg-field-chore_mode, .hg-field-assignee, .hg-item-provider-fields, .hg-item-schedule { grid-column: 1 / -1; }
.hg-field label { font-size: 13px; font-weight: 600; color: var(--hg-ink-2); }
.hg-field legend { padding: 0; font-size: 13px; font-weight: 600; color: var(--hg-ink-2); }
.hg-field-notes label span { color: var(--hg-muted); font-weight: 500; }
.hg-field small { font-size: 12px; color: var(--hg-muted); }
.hg-field input, .hg-field select, .hg-field textarea, .hg-popover-create input, .hg-fields-plain input, .hg-fields-plain select, .hg-fields-plain textarea { width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid var(--hg-line-strong); border-radius: 11px; background: var(--hg-surface); font-size: 15px; }
.hg-field textarea, .hg-fields-plain textarea { min-height: 88px; resize: vertical; }
.hg-field input:focus, .hg-field select:focus, .hg-field textarea:focus, .hg-popover-create input:focus, .hg-fields-plain input:focus, .hg-fields-plain select:focus, .hg-fields-plain textarea:focus { outline: none; border-color: var(--hg-accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--hg-accent) 16%, transparent); }
.hg-field:has(.errorlist) input, .hg-field:has(.errorlist) select, .hg-field:has(.errorlist) textarea { border-color: var(--hg-red); }
.hg-fields-plain { display: grid; gap: 14px; }
.hg-fields-plain p { display: grid; gap: 6px; margin: 0; min-width: 0; }
.hg-person-field { display: grid; gap: 6px; min-width: 0; }
.hg-fields-plain label { font-size: 13px; font-weight: 600; color: var(--hg-ink-2); }
.hg-fields-plain .helptext { font-size: 12px; color: var(--hg-muted); }
.hg-shell .errorlist { list-style: none; margin: 0; padding: 0; color: var(--hg-red); font-size: 13px; font-weight: 600; }
.hg-shell .errorlist.nonfield { margin-bottom: 4px; }
.hg-form-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; }
.hg-field-participants { padding: 0; border: 0; }
.hg-field-participants > div { display: flex; flex-wrap: wrap; gap: 8px; }
.hg-field-participants > div > div label, .hg-field-chore_mode > div > div label { display: inline-flex; align-items: center; gap: 8px; min-height: 42px; padding: 8px 12px; border: 1px solid var(--hg-line-strong); border-radius: 999px; background: var(--hg-surface-2); color: var(--hg-ink); cursor: pointer; }
.hg-field-participants label:has(input:checked), .hg-field-chore_mode label:has(input:checked) { border-color: var(--hg-accent); background: color-mix(in srgb, var(--hg-accent) 10%, var(--hg-surface-2)); }
.hg-field-participants label:has(input:focus-visible), .hg-field-chore_mode label:has(input:focus-visible) { outline: 2px solid var(--hg-accent); outline-offset: 2px; }
.hg-field-participants input, .hg-field-chore_mode input { width: 18px; min-height: 18px; margin: 0; accent-color: var(--hg-accent); }
.hg-field-chore_mode { padding: 0; border: 0; }
.hg-field-chore_mode > div { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.hg-field-chore_mode > div > div label { width: 100%; border-radius: 11px; }
.hg-item-provider-fields, .hg-item-schedule-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; }
.hg-item-schedule { padding: 0; border-top: 1px solid var(--hg-line); border-bottom: 1px solid var(--hg-line); }
.hg-item-schedule > summary { display: flex; align-items: center; justify-content: space-between; min-height: 48px; list-style: none; color: var(--hg-ink); font-size: 14px; font-weight: 700; cursor: pointer; }
.hg-item-schedule > summary::-webkit-details-marker { display: none; }
.hg-item-schedule > summary span { color: var(--hg-muted); font-size: 12px; font-weight: 500; }
.hg-item-schedule > summary span::after { content: "⌄"; display: inline-block; margin-left: 8px; font-size: 15px; transition: transform 0.15s ease; }
.hg-item-schedule[open] > summary span::after { transform: rotate(180deg); }
.hg-item-schedule-fields { padding: 4px 0 16px; }

/* Composer */
.hg-composer { margin: 0; }
.hg-composer > label { display: block; margin: 6px 0 8px; font-size: 14px; font-weight: 600; }
.hg-composer-box { padding: 14px 14px 10px; border: 1.5px solid var(--hg-line-strong); border-radius: 18px; background: var(--hg-surface); transition: border-color 0.15s ease, box-shadow 0.15s ease; }
.hg-composer-box:has(textarea:focus) { border-color: var(--hg-accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--hg-accent) 12%, transparent); }
.hg-composer textarea { display: block; width: 100%; min-height: 96px; max-height: 360px; padding: 4px 2px; border: 0; background: transparent; resize: none; font-size: 17px; line-height: 1.5; outline: none; }
.hg-composer textarea:focus, .hg-composer textarea:focus-visible { border: 0; outline: 0; box-shadow: none; }
.hg-composer-hero textarea { min-height: 128px; }
.hg-composer-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 6px; }
.hg-composer-hint { font-size: 12px; color: var(--hg-muted); }
.hg-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.hg-chips button { min-height: 36px; padding: 0 12px; border: 1px solid var(--hg-line); border-radius: 999px; background: var(--hg-surface); color: var(--hg-ink-2); font-size: 13px; cursor: pointer; }
.hg-chips button:hover { background: var(--hg-surface-2); color: var(--hg-ink); }

/* Cards, chat, projects */
.hg-card { min-width: 0; padding: 20px; border: 1px solid var(--hg-line); border-radius: var(--hg-radius-lg); background: var(--hg-surface); box-shadow: var(--hg-shadow-sm); }
.hg-card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 4px; }
.hg-card-head h2 { display: inline-flex; align-items: center; gap: 8px; font-size: 17px; letter-spacing: -0.01em; }
.hg-card-sub { margin: 0 0 14px; font-size: 13px; color: var(--hg-muted); }
.hg-chat .hg-composer-box { padding: 10px 10px 8px; border-radius: 14px; }
.hg-chat .hg-composer textarea { min-height: 44px; font-size: 15px; transition: min-height .16s ease; }
.hg-chat .hg-composer textarea:focus { min-height: 88px; }
.hg-thread { display: flex; flex-direction: column; gap: 12px; max-height: 360px; margin-bottom: 8px; padding: 4px 2px 14px; overflow: auto; scrollbar-width: thin; }
.hg-msg { max-width: 92%; font-size: 14px; line-height: 1.5; overflow-wrap: anywhere; }
.hg-msg p { margin: 0; }
.hg-msg-you { align-self: flex-end; padding: 10px 14px; border-radius: 16px 16px 4px 16px; background: var(--hg-surface-3); color: var(--hg-ink); }
.hg-msg-ai { align-self: flex-start; display: flex; gap: 10px; }
.hg-msg-ai > div { min-width: 0; padding: 10px 14px; border-radius: 4px 16px 16px 16px; background: var(--hg-surface-2); }
.hg-msg-ai .hg-tag { margin-top: 8px; }
.hg-msg-mark { width: 26px; height: 26px; margin-top: 2px; border-radius: 9px; display: inline-grid; place-items: center; flex-shrink: 0; background: var(--hg-surface-2); color: var(--hg-accent); }
.hg-msg-mark .hg-icon { width: 14px; height: 14px; }
.hg-card-head .hg-msg-mark { margin-top: 0; }
.hg-conversation-page { width: min(820px, 100%); margin: 0 auto; }
.hg-conversation-back { margin-bottom: 28px; }
.hg-conversation-heading { margin-bottom: 28px; }
.hg-conversation-heading h1 { margin: 0; font-size: clamp(34px, 5vw, 52px); line-height: 1.04; letter-spacing: -0.035em; }
.hg-conversation-heading p { max-width: 62ch; margin: 12px 0 0; color: var(--hg-ink-2); font-size: 16px; line-height: 1.55; }
.hg-conversation-page > .hg-chat { padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
.hg-conversation-page > .hg-chat .hg-card-head { margin-bottom: 6px; }
.hg-conversation-page > .hg-chat .hg-thread { max-height: min(52dvh, 560px); padding: 8px 2px 20px; }
.hg-conversation-review-link { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin: 0 0 28px; padding: 18px 0; border-top: 1px solid var(--hg-line); border-bottom: 1px solid var(--hg-line); }
.hg-conversation-review-link strong { display: block; font-size: 15px; }
.hg-conversation-review-link p { margin: 4px 0 0; color: var(--hg-muted); font-size: 13px; }
.hg-thread > .hg-tag { align-self: flex-end; }
.hg-thread-earlier { font-size: 13px; }
.hg-thread-earlier > summary { display: inline-flex; align-items: center; min-height: 36px; color: var(--hg-muted); font-weight: 600; cursor: pointer; }
.hg-thread-earlier > div { display: flex; flex-direction: column; gap: 12px; margin-top: 10px; }
.hg-list-plain { list-style: none; margin: 0; padding: 0; }
.hg-list-plain a { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 44px; padding: 6px 0; border-top: 1px solid var(--hg-line); color: var(--hg-ink); font-size: 14px; font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }
.hg-list-plain a:hover { color: var(--hg-accent); }
.hg-list-plain .hg-icon { width: 16px; height: 16px; color: var(--hg-muted); }

/* Dialogs */
.hg-dialog { width: min(560px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); padding: 0; border: 0; border-radius: 20px; background: var(--hg-surface); color: var(--hg-ink); box-shadow: var(--hg-shadow-md); }
.hg-dialog-wide { width: min(800px, calc(100vw - 32px)); max-width: calc(100vw - 32px); }
.hg-dialog::backdrop { background: var(--hg-dialog-backdrop); }
.hg-dialog form { display: grid; gap: 18px; margin: 0; padding: 24px; }
.hg-person-dialog-body { display: grid; gap: 18px; margin: 0; padding: 24px; }
.hg-dialog-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.hg-dialog-head h2 { font-size: 22px; letter-spacing: -0.02em; }
.hg-dialog-sub { margin: -10px 0 0; font-size: 14px; color: var(--hg-muted); }
.hg-dialog-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px; }
.hg-dialog-aside { margin-right: auto; min-height: 44px; font-size: 14px; color: var(--hg-muted); }
.hg-completion-copy { margin: 0; color: var(--hg-ink-2); line-height: 1.5; }
.hg-completion-copy strong { color: var(--hg-ink); }
.hg-completion-note { margin: 0; color: var(--hg-muted); font-size: 13px; line-height: 1.5; }
.hg-dialog[open]:not(:modal) { position: relative; margin: 24px 0 0; border: 1px solid var(--hg-line); box-shadow: none; }
#hg-add-dialog > form { display: flex; flex-direction: column; max-height: calc(100dvh - 32px); overflow: hidden; }
#hg-add-dialog > form > .hg-fields { min-height: 0; overflow-y: auto; padding-right: 4px; }
#hg-add-dialog > form > .hg-dialog-actions { flex: 0 0 auto; padding-top: 14px; border-top: 1px solid var(--hg-line); background: var(--hg-surface); }
.hg-add-dialog-body { display: flex; flex-direction: column; gap: 18px; max-height: calc(100dvh - 32px); padding: 24px; overflow: hidden; }
.hg-add-tabs { display: grid; grid-template-columns: 1fr 1fr; padding: 4px; border-radius: 13px; background: var(--hg-surface-2); }
.hg-add-tabs button { min-height: 42px; padding: 8px 12px; border: 0; border-radius: 10px; background: transparent; color: var(--hg-muted); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; }
.hg-add-tabs button[aria-selected="true"] { background: var(--hg-surface); color: var(--hg-ink); box-shadow: 0 1px 4px rgba(0, 0, 0, .12); }
.hg-add-dialog-body [role="tabpanel"] { min-width: 0; min-height: 0; overflow-y: auto; padding: 10px 2px 2px; }
.hg-add-dialog-body [role="tabpanel"][hidden] { display: none; }
.hg-add-dialog-body [role="tabpanel"] > .hg-dialog-sub { margin: 0 0 16px; }
.hg-add-dialog-body form { grid-template-columns: minmax(0, 1fr); width: 100%; min-width: 0; max-width: 100%; padding: 0; }
.hg-add-describe-form { margin-top: 18px !important; }
.hg-add-describe-form .hg-composer-box { min-height: 132px; }
.hg-add-describe-form textarea { box-sizing: border-box; width: 100%; max-width: 100%; min-height: 108px; border: 0 !important; outline: 0 !important; box-shadow: none !important; }
.hg-add-details-form > .hg-fields { padding-right: 4px; }
.hg-add-dialog-body .hg-dialog-actions { padding-top: 14px; border-top: 1px solid var(--hg-line); }
.hg-intro-dialog-body { position: relative; display: grid; gap: 16px; padding: 26px; }
.hg-intro-dialog-body .hg-dialog-head { display: block; min-width: 0; padding-right: 44px; margin-bottom: -11px; }
.hg-intro-dialog-body .hg-dialog-head .hg-icon-btn { position: absolute; top: 16px; right: 16px; width: 44px; height: 44px; }
.hg-intro-dialog-body .hg-dialog-head .hg-eyebrow { margin: 0; }
.hg-intro-dialog-body h2 { margin: 0; font-size: clamp(28px, 5vw, 38px); line-height: 1.05; letter-spacing: -.035em; }
.hg-intro-dialog-body > p { margin: 0; color: var(--hg-ink-2); line-height: 1.55; }
.hg-intro-dialog-body .hg-next-question { color: var(--hg-ink); font-weight: 700; }
.hg-intro-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.hg-intro-note { font-size: 12px; color: var(--hg-muted) !important; }
@media (min-width: 861px) {
  .hg-dialog-wide > form,
  .hg-dialog-wide > .hg-add-dialog-body { padding: 32px; }
}

/* Item edit page */
.hg-narrow { max-width: 640px; margin: 0 auto; }
.hg-back { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; color: var(--hg-muted); font-size: 14px; font-weight: 600; text-decoration: none; }
.hg-back:hover { color: var(--hg-ink); }
.hg-edit-head { display: flex; align-items: flex-start; gap: 16px; margin: 8px 0 24px; }
.hg-edit-head > div { min-width: 0; }
.hg-edit-head .hg-row-icon { width: 48px; height: 48px; border-radius: 15px; }
.hg-edit-head .hg-row-icon .hg-icon { width: 24px; height: 24px; }
.hg-edit-head h1 { font-size: clamp(26px, 4vw, 36px); line-height: 1.1; letter-spacing: -0.03em; overflow-wrap: anywhere; }
.hg-edit-meta { margin-top: 8px; font-size: 14px; }
.hg-meta-unit { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.hg-edit-form { display: grid; gap: 18px; padding: 24px; }
.hg-edit-aside { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-top: 20px; }
.hg-edit-aside form { margin: 0; }
.hg-danger > summary { list-style: none; display: inline-flex; align-items: center; min-height: 44px; color: var(--hg-muted); font-size: 14px; font-weight: 600; cursor: pointer; }
.hg-danger > summary::-webkit-details-marker { display: none; }
.hg-danger p { margin: 8px 0 12px; font-size: 14px; color: var(--hg-ink-2); }

/* Responsive */
@media (max-width: 1000px) {
  .hg-area-groups { grid-template-columns: 1fr 1fr; }
  .hg-area-group:last-child { grid-column: 1 / -1; }
}
@media (max-width: 860px) {
  .hg-account-button .hg-avatar-stack > .hg-avatar:not(:first-child) { display: none; }
  .hg-grid { grid-template-columns: 1fr; gap: 32px; }
  .hg-side-col { grid-template-columns: 1fr; }
  .hg-overview { flex-direction: column; align-items: flex-start; }
  .hg-overview-actions { justify-content: flex-start; }
}
@media (max-width: 720px) {
  .hg-nav { display: none; }
  .hg-switcher-button > .hg-icon:first-child { display: none; }
  .hg-popover-mobile-only { display: flex; }
  .hg-topbar-inner, .hg-main, .hg-footer { padding-left: 16px; padding-right: 16px; }
  .hg-main { padding-top: 24px; }
  .hg-brand-name { font-size: 15px; }
  .hg-switcher-name { max-width: 110px; }
  .hg-popover-panel { position: fixed; top: 64px; left: 12px; right: 12px; max-width: none; }
  .hg-welcome { margin-top: 8px; gap: 22px; }
  .hg-welcome h1 { font-size: clamp(32px, 9vw, 44px); }
  .hg-lede { font-size: 16px; }
  .hg-starters { grid-template-columns: 1fr; }
  .hg-sample { flex-direction: column; align-items: stretch; }
  .hg-composer-hint { display: none; }
  .hg-fields { grid-template-columns: 1fr; }
  .hg-field-chore_mode > div { grid-template-columns: 1fr; }
  .hg-item-provider-fields, .hg-item-schedule-fields { grid-template-columns: 1fr; }
  .hg-review { padding: 0; }
  .hg-suggestion-edit { margin-left: 0; }
  .hg-card { padding: 16px; }
  .hg-done-btn { width: 44px; min-height: 44px; padding: 0; }
  .hg-done-btn span { display: none; }
  .hg-row { gap: 12px; }
  .hg-row-side { gap: 8px; }
  .hg-edit-aside { flex-direction: column; align-items: stretch; }
  .hg-edit-aside .hg-btn { width: 100%; }
  .hg-footer { flex-wrap: wrap; gap: 4px 20px; }
  .hg-footer span { width: 100%; margin-left: 0; }
}
@media (max-width: 310px) {
  .hg-brand-name { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .hg-shell *, .hg-shell *::before, .hg-shell *::after { transition: none !important; animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
}

/* A recognizable first-use moment without putting another empty dashboard beside the chat. */
.hg-welcome-intro { position: relative; padding-right: 160px; }
.hg-welcome-intro h1 { max-width: 570px; }
.hg-brand-scene { position: absolute; top: 25px; right: -35px; width: 180px; height: 190px; transform: rotate(3deg); pointer-events: none; }
@media(min-width:1100px) { .hg-brand-scene { right:-82px; width:210px; } }
@media(max-width:720px) { .hg-welcome-intro { padding-right:0; } .hg-brand-scene { display:none; } }

.hg-thread-author { display:block; font-size:11px; font-weight:600; opacity:.8; margin-bottom:5px; }

/* Native controls and secondary panels share the same neutral dark foundation. */
.hg-shell input, .hg-shell select, .hg-shell textarea { color-scheme: var(--hg-color-scheme); }
.hg-shell input::placeholder, .hg-shell textarea::placeholder { color: var(--hg-muted); opacity: 1; }
.hg-shell input:-webkit-autofill { -webkit-text-fill-color: var(--hg-ink); caret-color: var(--hg-ink); box-shadow: 0 0 0 1000px var(--hg-surface) inset; }
.hg-side-col > .hg-card { padding: 20px 0; border: 0; border-top: 1px solid var(--hg-line); border-radius: 0; background: transparent; box-shadow: none; }
.hg-side-col > .hg-chat { padding-top: 0; border-top: 0; }
.hg-edit-form.hg-card { padding: 0; border: 0; background: transparent; box-shadow: none; }
.hg-shell ::selection { background: var(--hg-accent); color: var(--hg-on-accent); }

/* Accent belongs to the action, not every navigational detail. */
.hg-kind-service, .hg-kind-chore, .hg-kind-maintenance, .hg-kind-pet { background: var(--hg-surface-2); color: var(--hg-ink-2); }
.hg-done-btn { border-color: var(--hg-line); color: var(--hg-ink-2); }
.hg-done-btn:hover { border-color: var(--hg-line-strong); color: var(--hg-ink); }
.hg-person-picker { display: grid; justify-items: start; gap: 8px; }
.hg-add-person-button { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0; border: 0; background: transparent; color: var(--hg-accent); font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; }
.hg-add-person-button[hidden], .hg-person-pending[hidden] { display: none; }
.hg-add-person-button .hg-icon { width: 15px; height: 15px; }
.hg-add-person-button:hover { color: var(--hg-accent-strong); }
.hg-person-pending { display: flex; align-items: center; gap: 8px; margin: 0; color: var(--hg-ink-2); font-size: 13px; }
.hg-person-pending::before { content: ""; width: 7px; height: 7px; border-radius: 999px; background: var(--hg-accent); }
.hg-person-pending button { min-height: 36px; padding: 0; border: 0; background: transparent; color: var(--hg-muted); font: inherit; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.hg-person-privacy { margin: 0; color: var(--hg-muted); font-size: 13px; line-height: 1.5; }
.hg-person-invite label { display:flex; align-items:flex-start; gap:10px; cursor:pointer; line-height:1.45; }
.hg-person-invite input { flex:0 0 auto; width:18px; height:18px; margin-top:1px; accent-color:var(--hg-accent); }
@media (max-width: 560px) {
  .hg-person-dialog { width: 100%; max-width: none; max-height: calc(100dvh - 12px); margin: auto 0 0; border-radius: 22px 22px 0 0; }
  .hg-person-dialog-body { padding: 22px 18px calc(18px + env(safe-area-inset-bottom)); }
  .hg-person-dialog .hg-dialog-actions { display: grid; grid-template-columns: 1fr 1fr; }
  .hg-person-dialog .hg-btn { width: 100%; }
}
.hg-shell:has(.hg-review) .hg-chat .hg-btn-primary { background: var(--hg-surface); color: var(--hg-ink); border-color: var(--hg-line-strong); }
.hg-shell:has(.hg-review) .hg-chat .hg-btn-primary:hover { background: var(--hg-surface-3); }
@media (max-width: 720px) { .hg-composer-actions { justify-content: flex-end; } }

.hg-profile-link { margin-left:12px; min-height:32px; font-size:13px; font-weight:500; }

/* The dashboard uses one compact home-management rail and one working surface. */
.hg-brand-grip { color: var(--hg-accent); }
.hg-dashboard-layout { display: grid; grid-template-columns: 288px minmax(0, 1fr); gap: 80px; align-items: start; }
.hg-home-rail { grid-column: 1; grid-row: 1; min-width: 0; }
.hg-workspace-col { grid-column: 2; grid-row: 1; display: grid; gap: 32px; min-width: 0; }
.hg-workspace-col > .hg-card { padding: 24px 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
.hg-workspace-col > .hg-chat { padding-top: 0; border-top: 0; }
.hg-workspace-col .hg-thread { max-height: clamp(260px, 46dvh, 520px); }
#household, #hg-review-heading, #projects { scroll-margin-top: 88px; }

.hg-home-plan { border-top: 0; }
.hg-home-plan-disclosure > summary { display: none; }
.hg-home-plan-head { padding: 18px 0 10px; }
.hg-home-plan-head .hg-eyebrow { margin-bottom: 3px; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; }
.hg-home-plan-head h2 { font-size: 18px; letter-spacing: -.015em; }
.hg-area-groups { display: grid; grid-template-columns: 1fr; gap: 16px; }
.hg-area-group { min-width: 0; padding: 4px 10px 4px 20px; border-radius: 15px; background: var(--hg-surface-2); }
.hg-area-group[open] { padding-bottom: 8px; }
.hg-area-group-summary { display: flex; align-items: center; justify-content: space-between; min-height: 44px; padding: 0; color: var(--hg-accent); font-size: 11px; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; cursor: pointer; }
.hg-area-group-summary:hover { color: var(--hg-accent-strong); }
.hg-area-end { display: inline-grid; place-items: center; flex: 0 0 40px; width: 40px; height: 40px; }
.hg-area-end .hg-icon { width: 14px; height: 14px; }
.hg-area-group[open] > .hg-area-group-summary .hg-icon-chevron { transform: rotate(180deg); }
.hg-area-list { display: grid; gap: 0; padding-left: 0; border-top: 0; }
.hg-area-row { display: block; border-bottom: 0; }
.hg-area-row + .hg-area-row { border-top: 1px solid var(--hg-line); }
.hg-area-row-summary { display: grid; grid-template-columns: minmax(0, 1fr) auto 40px; align-items: center; gap: 10px; min-height: 44px; padding: 0; }
details.hg-area-row > .hg-area-row-summary { cursor: pointer; }
details.hg-area-row > .hg-area-row-summary:hover .hg-area-copy strong { color: var(--hg-accent); }
.hg-area-copy { min-width: 0; }
.hg-area-copy strong, .hg-area-copy small { display: block; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hg-area-copy strong { color: var(--hg-ink); font-size: 14px; line-height: 1.25; }
details.hg-area-row > .hg-area-row-summary:focus-visible .hg-area-copy strong { color: var(--hg-accent); }
.hg-area-copy small { margin-top: 2px; color: var(--hg-muted); font-size: 11px; line-height: 1.25; }
.hg-area-label { color: var(--hg-muted); font-size: 10px; font-weight: 650; white-space: nowrap; }
.hg-area-needs_attention .hg-area-label { color: var(--hg-amber-ink); }
.hg-area-tracking .hg-area-label { color: var(--hg-ink-2); }
.hg-area-row-summary > .hg-area-end { color: var(--hg-muted); }
.hg-area-row[open] > .hg-area-row-summary > .hg-area-end .hg-icon-chevron { transform: rotate(180deg); }
.hg-area-row-body { padding: 1px 0 12px; }
.hg-area-items { display: grid; gap: 6px; margin: 0 0 9px; padding: 0; list-style: none; }
.hg-area-items li { display: flex; flex-wrap: wrap; gap: 4px 8px; color: var(--hg-muted); font-size: 11px; line-height: 1.35; }
.hg-area-items a { width: 100%; color: var(--hg-ink); font-size: 12px; font-weight: 650; text-decoration: none; }
.hg-area-items a:hover { text-decoration: underline; }
.hg-area-add { min-height: 32px; font-size: 12px; }
.hg-area-detail-actions { display: flex; flex-wrap: wrap; gap: 6px 12px; }
.hg-area-row-actions { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 0 0 11px; }
.hg-area-row-actions form { margin: 0; }
.hg-area-row-actions .hg-link-button { min-height: 32px; font-size: 12px; }
.hg-area-draft .hg-area-row-actions { padding-bottom: 4px; }
.hg-area-na { color: var(--hg-muted); font-size: 11px !important; }
.hg-area-unconfigured-line { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 10px; min-height: 44px; padding: 0; }
.hg-area-name-link { min-width: 0; overflow: hidden; color: var(--hg-ink); font-size: 14px; font-weight: 700; line-height: 1.25; text-decoration: none; text-overflow: ellipsis; white-space: nowrap; }
.hg-area-name-link:hover, .hg-area-name-link:focus-visible { color: var(--hg-accent); }
.hg-area-unconfigured-actions { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 2px; white-space: nowrap; }
.hg-area-unconfigured-actions form { flex: 0 0 auto; margin: 0; }
.hg-area-setup { display: inline-flex; flex: 0 0 auto; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; font-size: 12px; line-height: 1; text-decoration: none; }
.hg-area-setup:hover, .hg-area-setup:focus-visible { color: var(--hg-accent); }
.hg-area-exclude { display: inline-grid; place-items: center; width: 40px; height: 40px; padding: 0; border: 0; border-radius: 10px; background: transparent; color: var(--hg-muted); cursor: pointer; }
.hg-area-exclude:hover { background: var(--hg-surface-2); color: var(--hg-ink); }
.hg-area-group .hg-area-exclude:hover { background: var(--hg-surface-3); }
.hg-area-exclude .hg-icon { width: 14px; height: 14px; }
.hg-excluded-areas { border-bottom: 0; }
.hg-excluded-areas > summary { display: flex; align-items: center; gap: 8px; min-height: 46px; color: var(--hg-muted); font-size: 11px; font-weight: 650; cursor: pointer; }
.hg-excluded-areas > summary > span { display: inline-grid; place-items: center; min-width: 19px; height: 19px; border-radius: 999px; background: var(--hg-surface-2); font-size: 10px; }
.hg-excluded-areas > summary .hg-icon { width: 14px; height: 14px; margin-left: auto; }
.hg-excluded-areas[open] > summary .hg-icon-chevron { transform: rotate(180deg); }
.hg-excluded-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 46px; padding-left: 15px; border-top: 0; color: var(--hg-ink-2); font-size: 12px; }
.hg-excluded-row form { margin: 0; }
.hg-excluded-row .hg-link-button { min-height: 32px; font-size: 11px; }
.hg-home-plan-actions { display: grid; justify-items: start; gap: 8px; margin-top: 20px; padding-left: 10px; }
.hg-home-plan-actions .hg-btn { min-height: 42px; }
.hg-home-plan-actions .hg-link-button { min-height: 42px; font-size: 12px; }
.hg-mobile-add-home { display: none; }
.hg-home-identity { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; }
.hg-home-identity .hg-eyebrow { margin: 0; }
.hg-home-edit { min-height: 32px; font-size: 12px; }
.hg-home-activity { display: grid; gap: 18px; }
.hg-home-activity > .hg-group-head { margin-bottom: -4px; }
.hg-home-activity-empty { gap: 8px; }
.hg-home-activity-empty > p { max-width: 52ch; margin: 0; color: var(--hg-muted); font-size: 14px; line-height: 1.5; }
.hg-activity-block { display: grid; gap: 8px; }
.hg-activity-block h3 { display: flex; align-items: center; gap: 8px; color: var(--hg-muted); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; }
.hg-field-area { grid-column: span 1; }
.hg-area-setup-fields > .hg-field-title,
.hg-area-setup-fields > .hg-field-kind,
.hg-area-setup-fields > .hg-field-area,
.hg-area-setup-fields .hg-field-provider_phone,
.hg-area-setup-fields .hg-field-provider_email,
.hg-area-setup-fields .hg-field-provider_website { display: none; }
.hg-area-setup-fields:not(.hg-area-setup-laundry):not(.hg-area-setup-dishes) > .hg-field-responsibility,
.hg-area-setup-fields:not(.hg-area-setup-laundry):not(.hg-area-setup-dishes) > .hg-field-assignee,
.hg-area-setup-fields:not(.hg-area-setup-laundry):not(.hg-area-setup-dishes) > .hg-field-person-picker,
.hg-area-setup-fields:not(.hg-area-setup-laundry):not(.hg-area-setup-dishes) > .hg-item-provider-fields { display: none; }
.hg-item-provider { grid-column: 1 / -1; border-top: 1px solid var(--hg-line); }
.hg-item-provider > summary, .hg-business-finder > summary { display: flex; align-items: center; justify-content: space-between; min-height: 46px; color: var(--hg-ink-2); font-size: 13px; font-weight: 700; cursor: pointer; }
.hg-item-provider > summary span { color: var(--hg-muted); font-size: 11px; font-weight: 500; }
.hg-item-provider .hg-item-provider-fields { padding: 2px 0 10px; }
.hg-business-finder { margin-top: 18px; border-top: 1px solid var(--hg-line); }
.hg-business-finder-body { padding: 2px 0 4px; }
.hg-business-finder-body > p { margin: 0 0 14px; color: var(--hg-muted); font-size: 13px; line-height: 1.5; }
.hg-business-search-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 10px; }
.hg-business-search-row .hg-field { margin: 0; }
.hg-business-results { display: grid; gap: 0; margin: 16px 0 0; padding: 0; list-style: none; border-top: 1px solid var(--hg-line); }
.hg-business-results li { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--hg-line); }
.hg-business-results strong { display: block; color: var(--hg-ink); font-size: 14px; }
.hg-business-results p { margin: 3px 0; color: var(--hg-muted); font-size: 12px; line-height: 1.4; }
.hg-business-results a { color: var(--hg-accent-strong); font-size: 12px; }
.hg-business-error { color: var(--hg-red) !important; }
.hg-business-selected { color: var(--hg-ink-2) !important; }

@media (min-width: 861px) and (min-height: 900px) {
  .hg-home-rail { position: sticky; top: 80px; }
}

@media (min-width: 861px) {
  .hg-workspace-col > .hg-chat:first-child { padding-top: 24px; }
  .hg-workspace-col > .hg-home-activity:first-child { padding-top: 24px; }
}

@media (max-width: 860px) {
  .hg-dashboard-layout { grid-template-columns: 1fr; gap: 28px; }
  .hg-home-rail { grid-column: 1; grid-row: auto; order: -1; }
  .hg-workspace-col { grid-column: 1; grid-row: auto; }
  .hg-home-plan { border-top: 0; }
  .hg-home-plan-disclosure > summary.hg-home-plan-mobile-summary { display: flex; align-items: center; justify-content: space-between; min-height: 52px; padding: 0 2px; border-top: 0; border-bottom: 1px solid var(--hg-line); cursor: pointer; }
  .hg-home-plan-mobile-summary > span { display: grid; }
  .hg-home-plan-mobile-summary strong { font-size: 15px; }
  .hg-home-plan-mobile-summary small { color: var(--hg-muted); font-size: 11px; }
  .hg-home-plan-mobile-summary .hg-icon { color: var(--hg-muted); }
  .hg-home-plan-disclosure[open] > .hg-home-plan-mobile-summary .hg-icon-chevron { transform: rotate(180deg); }
  .hg-home-plan-content { padding-top: 10px; }
  .hg-home-plan-head { display: none; }
  .hg-area-row-summary { min-height: 44px; }
  .hg-home-plan-actions { padding-bottom: 10px; }
  .hg-home-plan-actions { display: none; }
  .hg-mobile-add-home { display: inline-flex; width: 100%; margin-top: 12px; }
}

@media (max-width: 560px) {
  .hg-workspace-col { gap: 28px; }
  .hg-workspace-col > .hg-card { padding: 20px 0; }
  .hg-conversation-back { margin-bottom: 22px; }
  .hg-conversation-heading { margin-bottom: 24px; }
  .hg-conversation-review-link { align-items: flex-start; flex-direction: column; gap: 12px; }
  .hg-conversation-review-link .hg-btn { width: 100%; }
  .hg-status { align-items: flex-start; flex-wrap: wrap; }
  .hg-status-actions { width: 100%; justify-content: space-between; }
  .hg-area-label { font-size: 9px; }
  .hg-area-row-summary { grid-template-columns: minmax(0, 1fr) auto 40px; gap: 7px; }
  .hg-business-search-row, .hg-business-results li { grid-template-columns: 1fr; align-items: stretch; }
  .hg-business-search-row .hg-btn, .hg-business-results .hg-btn { width: 100%; }
}

/* Household projects are a separate home-scoped workspace from operator research. */
.hg-project-page { width: min(1080px, 100%); margin: 0 auto; }
.hg-project-page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 28px; margin: 12px 0 56px; }
.hg-project-page-head > div { min-width: 0; }
.hg-project-page-head h1, .hg-project-form-head h1, .hg-project-detail-head h1 { margin: 3px 0 0; font-size: clamp(38px, 6vw, 64px); line-height: 1.01; letter-spacing: -.045em; overflow-wrap: anywhere; }
.hg-project-page-head p:last-child, .hg-project-form-head > p:last-child, .hg-project-detail-head > div > p:last-child { max-width: 62ch; margin: 14px 0 0; color: var(--hg-ink-2); font-size: 16px; line-height: 1.55; }
.hg-project-section { margin-top: 36px; }
.hg-project-section-head { display: flex; align-items: center; gap: 10px; padding-bottom: 12px; border-bottom: 1px solid var(--hg-line); }
.hg-project-section-head h2 { font-size: 18px; }
.hg-project-section-head span, .hg-project-done summary span, .hg-project-legacy summary span { display: inline-grid; place-items: center; min-width: 22px; height: 22px; border-radius: 999px; background: var(--hg-surface-2); color: var(--hg-muted); font-size: 11px; font-weight: 700; }
.hg-project-list { margin: 0; padding: 0; list-style: none; }
.hg-project-row { border-bottom: 1px solid var(--hg-line); }
.hg-project-row > a { display: grid; grid-template-columns: minmax(0, 1fr) auto 24px; align-items: center; gap: 20px; min-height: 78px; padding: 12px 0; color: var(--hg-ink); text-decoration: none; }
.hg-project-row > a:hover strong { color: var(--hg-accent-strong); }
.hg-project-row-main { display: grid; gap: 5px; min-width: 0; }
.hg-project-row-main strong { font-size: 16px; overflow-wrap: anywhere; }
.hg-project-row-main > span { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; color: var(--hg-muted); font-size: 12px; }
.hg-project-row-main .hg-dot { display: inline-block; }
.hg-project-row-date { color: var(--hg-ink-2); font-size: 13px; white-space: nowrap; }
.hg-project-row > a > .hg-icon { width: 18px; height: 18px; color: var(--hg-muted); }
.hg-project-empty { max-width: 600px; margin: 28px 0 48px; padding: 28px 0; border-top: 1px solid var(--hg-line); border-bottom: 1px solid var(--hg-line); }
.hg-project-empty h2 { font-size: 20px; }
.hg-project-empty p { margin: 8px 0 16px; color: var(--hg-muted); line-height: 1.55; }
.hg-project-done, .hg-project-legacy { margin-top: 28px; border-top: 1px solid var(--hg-line); }
.hg-project-done > summary, .hg-project-legacy > summary { display: flex; align-items: center; gap: 10px; min-height: 58px; color: var(--hg-ink); font-size: 15px; font-weight: 700; cursor: pointer; }
.hg-project-done > summary .hg-icon, .hg-project-legacy > summary .hg-icon { width: 16px; height: 16px; margin-left: auto; color: var(--hg-muted); }
.hg-project-done[open] > summary .hg-icon, .hg-project-legacy[open] > summary .hg-icon { transform: rotate(180deg); }
.hg-project-legacy > div { padding: 2px 0 22px; }
.hg-project-legacy > div > p { margin: 0 0 14px; color: var(--hg-muted); font-size: 13px; }
.hg-project-form-page { width: min(860px, 100%); }
.hg-project-form-page > .hg-back, .hg-project-detail-page > .hg-back { margin-bottom: 24px; }
.hg-project-form-head { margin-bottom: 30px; }
.hg-project-tabs { max-width: 500px; margin-bottom: 30px; }
.hg-project-form-page [role="tabpanel"][hidden] { display: none; }
.hg-project-tab-copy { max-width: 64ch; margin: 0 0 22px; color: var(--hg-ink-2); line-height: 1.55; }
.hg-project-tab-copy + form, .hg-project-reply + form, .hg-project-you-said + form { padding-top: 12px; }
.hg-project-describe { display: grid; gap: 10px; }
.hg-project-describe > label { font-size: 14px; font-weight: 700; }
.hg-project-describe textarea { min-height: 150px; }
.hg-project-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 20px; }
.hg-project-field-wide { grid-column: 1 / -1; }
.hg-project-fields .hg-field input, .hg-project-fields .hg-field select, .hg-project-fields .hg-field textarea { width: 100%; min-height: 46px; padding: 10px 12px; border: 1px solid var(--hg-line-strong); border-radius: 11px; background: var(--hg-surface); color: var(--hg-ink); font: inherit; }
.hg-project-fields .hg-field textarea { min-height: 104px; resize: vertical; }
.hg-project-form-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; margin-top: 26px; padding-top: 20px; border-top: 1px solid var(--hg-line); }
.hg-project-you-said { margin: 0 0 26px; padding: 18px 0; border-top: 1px solid var(--hg-line); border-bottom: 1px solid var(--hg-line); }
.hg-project-you-said strong { display: block; margin-bottom: 5px; color: var(--hg-muted); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; }
.hg-project-you-said p, .hg-project-reply { margin: 0; line-height: 1.55; }
.hg-project-reply { margin-bottom: 24px; color: var(--hg-ink-2); }
.hg-project-dismiss { margin-top: 18px; }
.hg-project-processing-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.hg-project-processing-actions form { margin: 0; }
.hg-project-find-help { margin-top: 30px; padding-top: 28px; border-top: 1px solid var(--hg-line); }
.hg-project-find-help > div:first-child h3 { margin: 3px 0 0; font-size: 19px; }
.hg-project-find-help > div:first-child > p:last-child { max-width: 62ch; margin: 8px 0 0; color: var(--hg-muted); font-size: 13px; line-height: 1.5; }
.hg-project-search-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 12px; margin-top: 18px; }
.hg-project-search-row .hg-field { min-width: 0; }
.hg-project-search-row input { width: 100%; min-height: 46px; }
.hg-project-business-results, .hg-project-research-links { margin: 18px 0 0; padding: 0; list-style: none; }
.hg-project-business-results li { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 0; border-bottom: 1px solid var(--hg-line); }
.hg-project-business-results li > div { min-width: 0; }
.hg-project-business-results strong { display: block; overflow-wrap: anywhere; }
.hg-project-business-results p { margin: 5px 0; color: var(--hg-muted); font-size: 13px; line-height: 1.45; }
.hg-project-business-results a, .hg-project-research-links a { color: var(--hg-accent-strong); }
.hg-project-search-empty { margin: 18px 0 0; color: var(--hg-muted); }
.hg-project-selected-source { margin: 14px 0 0; color: var(--hg-muted); font-size: 13px; }
.hg-project-selected-source a { color: var(--hg-accent-strong); }
.hg-project-research { margin-top: 22px; border-top: 1px solid var(--hg-line); }
.hg-project-research > summary { display: flex; align-items: center; justify-content: space-between; min-height: 58px; font-weight: 700; cursor: pointer; }
.hg-project-research > summary .hg-icon { width: 16px; height: 16px; color: var(--hg-muted); }
.hg-project-research[open] > summary .hg-icon { transform: rotate(180deg); }
.hg-project-research > p { max-width: 66ch; margin: 0 0 16px; color: var(--hg-muted); font-size: 13px; line-height: 1.5; }
.hg-project-research-links { margin-bottom: 16px; }
.hg-project-research-links li + li { margin-top: 8px; }
.hg-project-detail-page { width: min(920px, 100%); }
.hg-project-detail-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 30px; margin-bottom: 36px; }
.hg-project-detail-head > div:first-child { min-width: 0; }
.hg-project-status-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px; }
.hg-project-status-actions form { margin: 0; }
.hg-project-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; margin: 0 0 34px; padding: 18px 0; border-top: 1px solid var(--hg-line); border-bottom: 1px solid var(--hg-line); }
.hg-project-facts > div { min-width: 0; padding: 4px 18px; border-left: 1px solid var(--hg-line); }
.hg-project-facts > div:first-child { padding-left: 0; border-left: 0; }
.hg-project-facts dt { margin-bottom: 5px; color: var(--hg-muted); font-size: 11px; text-transform: uppercase; letter-spacing: .05em; }
.hg-project-facts dd { margin: 0; color: var(--hg-ink); font-size: 14px; overflow-wrap: anywhere; }
.hg-project-notes { margin: 28px 0; }
.hg-project-notes h2 { margin-bottom: 8px; font-size: 16px; }
.hg-project-notes p { margin: 0; color: var(--hg-ink-2); line-height: 1.6; }
.hg-project-edit { margin-top: 36px; border-top: 1px solid var(--hg-line); }
.hg-project-edit > summary { display: flex; align-items: center; justify-content: space-between; min-height: 58px; font-weight: 700; cursor: pointer; }
.hg-project-edit > summary .hg-icon { width: 16px; height: 16px; color: var(--hg-muted); }
.hg-project-edit[open] > summary .hg-icon { transform: rotate(180deg); }
.hg-project-edit > form { padding: 12px 0 18px; }
.hg-project-remove { margin-top: 12px; }
.hg-project-dashboard-meta { margin-left: auto; color: var(--hg-muted); font-size: 11px; font-weight: 500; }
.hg-project-done-link { margin-top: 12px; }
.hg-project-helper { margin: 10px 0 0; color: var(--hg-muted); font-size: 12px; line-height: 1.45; }
.hg-project-helper a { color: var(--hg-accent-strong); }
.hg-project-completion-date { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; }
.hg-project-completion-date .hg-link-button { min-height: 40px; white-space: nowrap; }
.hg-project-clear-cost { display: inline-flex; align-items: center; gap: 9px; min-height: 40px; }
.hg-project-clear-cost input { width: 18px; min-height: 18px; margin: 0; accent-color: var(--hg-accent); }
.hg-project-clear-cost label { cursor: pointer; }

/* Shared household project coordination */
.hg-coordination-page { width: min(940px, 100%); margin: 0 auto; }
.hg-coordination-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 28px; margin: 18px 0 30px; }
.hg-coordination-head h1 { max-width: 760px; margin: 4px 0 9px; font-size: clamp(32px, 5vw, 54px); }
.hg-coordination-head p:last-child { max-width: 62ch; color: var(--hg-muted); }
.hg-coordination-status { flex: 0 0 auto; padding: 7px 11px; border-radius: 999px; background: var(--hg-accent-soft); color: var(--hg-accent-strong); font-size: 12px; font-weight: 700; }
.hg-coordination-status.is-warning, .hg-coordination-row-status.is-warning { background: var(--hg-amber-soft); color: var(--hg-amber-ink); }
.hg-coordination-status.is-active, .hg-coordination-row-status.is-active { background: var(--hg-accent-soft); color: var(--hg-accent-strong); }
.hg-coordination-tabs { display: flex; gap: 22px; overflow-x: auto; border-bottom: 1px solid var(--hg-line); }
.hg-coordination-tabs a { display: inline-flex; align-items: center; gap: 7px; min-height: 48px; border-bottom: 2px solid transparent; color: var(--hg-muted); font-size: 14px; font-weight: 700; text-decoration: none; white-space: nowrap; }
.hg-coordination-tabs a[aria-current="page"] { border-color: var(--hg-accent); color: var(--hg-ink); }
.hg-coordination-tabs span { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 999px; background: var(--hg-accent-soft); color: var(--hg-accent-strong); font-size: 11px; }
.hg-coordination-conversation, .hg-coordination-section { padding: 30px 0 8px; }
.hg-coordination-section-head { margin-bottom: 22px; }
.hg-coordination-section-head h2 { margin: 3px 0 7px; font-size: 26px; }
.hg-coordination-section-head p { max-width: 66ch; color: var(--hg-muted); }
.hg-coordination-thread { display: grid; gap: 12px; max-height: 520px; overflow-y: auto; padding: 2px 4px 20px; scroll-behavior: smooth; }
.hg-coordination-bubble { width: fit-content; max-width: min(640px, 86%); padding: 14px 16px 9px; border-radius: 16px; background: var(--hg-surface-2); }
.hg-coordination-bubble.is-inbound { justify-self: end; background: var(--hg-accent-soft); }
.hg-coordination-bubble p { white-space: pre-wrap; }
.hg-coordination-bubble small { display: block; margin-top: 6px; color: var(--hg-muted); font-size: 11px; }
.hg-coordination-compose { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 10px; margin-top: 18px; padding: 8px; border: 1px solid var(--hg-line); border-radius: 16px; background: var(--hg-surface); }
.hg-coordination-compose:focus-within { border-color: var(--hg-accent); box-shadow: 0 0 0 1px var(--hg-accent); }
.hg-coordination-compose textarea { width: 100%; min-height: 66px; max-height: 180px; padding: 9px; resize: vertical; border: 0; outline: 0; background: transparent; }
.hg-coordination-compose textarea:focus-visible { outline: 0; }
.hg-coordination-call-list, .hg-coordination-findings { display: grid; gap: 0; margin: 0 0 24px; padding: 0; list-style: none; }
.hg-coordination-call-list > li, .hg-coordination-findings > li { padding: 20px 0; border-bottom: 1px solid var(--hg-line); }
.hg-coordination-call-list label { display: flex; align-items: flex-start; gap: 12px; min-height: 44px; cursor: pointer; }
.hg-coordination-call-list input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--hg-accent); }
.hg-coordination-call-list label span span, .hg-coordination-call-list small { display: block; color: var(--hg-muted); }
.hg-coordination-call-list > li > div { margin: 14px 0 0 32px; color: var(--hg-ink-2); font-size: 13px; }
.hg-coordination-call-list ol { margin: 6px 0 0; padding-left: 20px; }
.hg-coordination-timing { display: flex; flex-wrap: wrap; gap: 12px 26px; margin: 0 0 22px; padding: 0; border: 0; }
.hg-coordination-timing legend { width: 100%; margin-bottom: 7px; font-weight: 700; }
.hg-coordination-timing label { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; }
.hg-coordination-empty { padding: 24px 0; color: var(--hg-muted); }
.hg-coordination-empty h3 { margin-bottom: 7px; color: var(--hg-ink); }
.hg-coordination-empty .hg-btn { margin-top: 16px; }
.hg-coordination-empty.is-warning { color: var(--hg-ink-2); }
.hg-coordination-findings > li > div { display: flex; align-items: center; gap: 10px; }
.hg-coordination-findings h3 { margin: 10px 0; font-size: 18px; }
.hg-coordination-findings dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 24px; margin: 0; }
.hg-coordination-findings dl div { min-width: 0; }
.hg-coordination-findings dt { color: var(--hg-muted); font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.hg-coordination-findings dd { margin: 3px 0 0; overflow-wrap: anywhere; }
.hg-coordination-archive { display: flex; align-items: center; gap: 12px; margin-top: 34px; padding-top: 20px; border-top: 1px solid var(--hg-line); color: var(--hg-muted); font-size: 13px; }
.hg-project-research form > .hg-field { display: grid; gap: 7px; max-width: 680px; margin: 0 0 14px; font-size: 13px; font-weight: 700; }
.hg-project-research textarea { width: 100%; min-height: 92px; padding: 11px 12px; border: 1px solid var(--hg-line-strong); border-radius: 11px; background: var(--hg-surface); resize: vertical; font-weight: 400; }
.hg-project-research-links a { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 48px; text-decoration: none; }
.hg-coordination-row-status { display: inline-flex; align-items: center; flex: 0 0 auto; min-height: 26px; padding: 3px 9px; border-radius: 999px; background: var(--hg-surface-2); color: var(--hg-muted); font-size: 12px; font-weight: 700; text-decoration: none; }
.hg-coordination-row-link { text-decoration: none; }
.hg-coordination-row-link > span { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; min-width: 0; }

@media (max-width: 720px) {
  .hg-project-page-head, .hg-project-detail-head { align-items: stretch; flex-direction: column; margin-bottom: 36px; }
  .hg-project-page-head > .hg-btn, .hg-project-status-actions .hg-btn, .hg-project-status-actions form { width: 100%; }
  .hg-project-status-actions { width: 100%; }
  .hg-project-row > a { grid-template-columns: minmax(0, 1fr) 18px; gap: 10px; min-height: 70px; }
  .hg-project-row-date { grid-column: 1; grid-row: 2; margin-top: -8px; }
  .hg-project-row > a > .hg-icon { grid-column: 2; grid-row: 1 / span 2; }
  .hg-project-fields { grid-template-columns: 1fr; }
  .hg-project-field-wide { grid-column: auto; }
  .hg-project-form-actions { align-items: stretch; flex-direction: column-reverse; }
  .hg-project-form-actions .hg-btn { width: 100%; }
  .hg-project-facts { grid-template-columns: 1fr 1fr; }
  .hg-project-facts > div { padding: 12px 0; border-left: 0; border-top: 1px solid var(--hg-line); }
  .hg-project-facts > div:nth-child(-n+2) { border-top: 0; }
  .hg-project-dashboard-meta { display: none; }
  .hg-project-completion-date { grid-template-columns: 1fr; gap: 4px; }
  .hg-project-completion-date .hg-link-button { justify-self: start; }
  .hg-project-search-row { grid-template-columns: 1fr; align-items: stretch; }
  .hg-project-search-row .hg-btn { width: 100%; }
  .hg-project-business-results li { align-items: stretch; flex-direction: column; }
  .hg-project-business-results .hg-btn { width: 100%; }
  .hg-coordination-head { align-items: flex-start; flex-direction: column; gap: 14px; }
  .hg-coordination-head h1 { font-size: 36px; }
  .hg-coordination-tabs { gap: 16px; }
  .hg-coordination-compose { grid-template-columns: 1fr; }
  .hg-coordination-compose .hg-btn { width: 100%; }
  .hg-coordination-bubble { max-width: 92%; }
  .hg-coordination-findings dl { grid-template-columns: 1fr; }
  .hg-coordination-archive { align-items: flex-start; flex-direction: column; }
}
