/* Luxury HouseWorks hub. Black / white / grey palette taken from the logo and paperwork, Basecamp-style layout:
   centered column, top nav, project pages made of tool cards. */

@font-face { font-family: 'Source Serif 4'; src: url('/assets/fonts/serif-roman.woff2') format('woff2'); font-weight: 200 900; font-display: swap; }
@font-face { font-family: 'Source Serif 4'; src: url('/assets/fonts/serif-italic.woff2') format('woff2'); font-weight: 200 900; font-style: italic; font-display: swap; }
@font-face { font-family: 'Source Sans 3'; src: url('/assets/fonts/sans-roman.woff2') format('woff2'); font-weight: 200 900; font-display: swap; }
@font-face { font-family: 'Source Sans 3'; src: url('/assets/fonts/sans-italic.woff2') format('woff2'); font-weight: 200 900; font-style: italic; font-display: swap; }

:root {
  /* Luxury HouseWorks: the logo is black and white, so the interface is too.
     Label colors (clay/rose/twilight/sky/sage) stay for folders and docs. */
  --primary: #111111; --primary-deep: #000000; --primary-soft: #45474B; --primary-faint: #8E9095;
  --bg: #F4F4F2; --bg-deep: #E6E6E4; --surface: #FFFFFF; --surface-soft: #FAFAF9;
  --ink: #161616; --ink-soft: #47494D; --ink-mute: #7C7E83;
  --line: #DADAD8; --line-soft: #EAEAE8; --brass-line: rgba(255,255,255,.14);
  --accent: #111111; --accent-deep: #5B5D62; --gold: #8E9095; --tint: #F6F6F4;
  --ok: #15803D; --warn: #B08D57; --bad: #DC2626; --sunset: #2563EB;
  --clay: #B66C51; --rose: #B8526B; --twilight: #6B4566; --sky: #5F8FA6; --sage: #6E8A6B;
  --serif: 'Source Serif 4', Georgia, serif;
  --sans: 'Source Sans 3', system-ui, -apple-system, sans-serif;
  --r: 12px; --r-sm: 8px;
  --shadow: 0 1px 2px rgba(30,32,35,.04), 0 10px 24px -14px rgba(30,32,35,.18);
  --maxw: 1120px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.5 var(--sans); min-height: 100dvh; }
body.bare { background: var(--primary); color: var(--bg); }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 600; line-height: 1.2; margin: 0 0 .4em; letter-spacing: -.01em; }
h1, .h1 { font-size: 2rem; } h2, .h2 { font-size: 1.5rem; } h3, .h3 { font-size: 1.2rem; } .h4 { font-size: 1.05rem; font-family: var(--serif); font-weight: 600; margin: 0 0 .5em; }
p { margin: 0 0 1em; }
a { color: var(--primary); text-decoration-color: var(--primary-faint); text-underline-offset: 2px; }
a:hover { color: var(--accent); }
.mute { color: var(--ink-mute); } .small { font-size: .875rem; } .center { text-align: center; }
.row { display: flex; align-items: center; flex-wrap: wrap; } .gap { gap: .6rem; } .between { justify-content: space-between; }
.skip { position: absolute; left: -999px; } .skip:focus { left: 8px; top: 8px; background: var(--surface); padding: 6px 10px; z-index: 99; }

/* Top bar ---------------------------------------------------------------- */
.topbar { background: var(--primary); color: var(--bg); position: sticky; top: 0; z-index: 20; padding-top: env(safe-area-inset-top); border-bottom: 1px solid var(--brass-line); }
.topbar-in { max-width: var(--maxw); margin: 0 auto; padding: 0 16px; display: flex; align-items: center; gap: 1rem; height: 56px; }
.brand { color: var(--surface); text-decoration: none; font-family: var(--serif); font-weight: 600; font-size: 1.1rem; display: flex; align-items: center; gap: .5rem; white-space: nowrap; }
.brand { letter-spacing: .2em; text-transform: uppercase; font-family: var(--sans); font-size: .95rem; gap: .65rem; }
.brand:hover { color: #fcc200; }
.brand-mark { width: 26px; height: 28px; flex: none; display: block; }
.brand-mark.lg { width: 84px; height: 92px; margin: 0 auto; }
.brand .brand-sub { font: 500 .72rem var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--primary-faint); display: block; line-height: 1; margin-top: 2px; }
.topnav { display: flex; gap: .15rem; margin-left: auto; margin-right: auto; }
.topnav a { color: var(--bg); text-decoration: none; white-space: nowrap; padding: 6px 12px; border-radius: 999px; font-weight: 600; font-size: .95rem; }
.topnav a:hover { background: rgba(255,255,255,.08); color: #fff; }
.topnav a.is-active { background: rgba(255,255,255,.14); color: #fff; }
.badge { background: var(--sunset); color: #fff; font-size: .72rem; padding: 1px 7px; border-radius: 999px; font-weight: 700; vertical-align: 1px; }
.topbar-right { margin-left: auto; }
.menu { position: relative; } .menu > summary { list-style: none; cursor: pointer; display: flex; } .menu > summary::-webkit-details-marker { display: none; }
.menu-pop { position: absolute; right: 0; top: calc(100% + 8px); background: var(--surface); color: var(--ink); border-radius: var(--r); box-shadow: var(--shadow); min-width: 230px; padding: .4rem 0; z-index: 30; }
.menu-pop a, .menu-pop button { display: block; width: 100%; text-align: left; padding: .5rem 1rem; color: var(--ink); text-decoration: none; background: none; border: 0; font: inherit; cursor: pointer; }
.menu-pop a:hover, .menu-pop button:hover { background: var(--bg); }
.menu-head { padding: .6rem 1rem; border-bottom: 1px solid var(--line-soft); font-size: .9rem; }

/* Page ------------------------------------------------------------------- */
.page { max-width: var(--maxw); margin: 0 auto; padding: 1.5rem 16px 5rem; }
.page.narrow, .narrow { max-width: 720px; }
.flash { max-width: var(--maxw); margin: 1rem auto -0.5rem; padding: .7rem 1rem; border-radius: var(--r-sm); background: var(--primary); color: var(--surface); font-weight: 600; }
.flash-error { background: var(--bad); } .flash.inline { margin: 0 0 1rem; }
.card { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); border: 1px solid var(--line-soft); padding: 1.25rem; margin-bottom: 1rem; }
.card.soft { background: var(--surface-soft); box-shadow: none; border: 1px solid var(--line-soft); }
.page-title { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem; }
.page-title h1 { margin: 0; }
.empty { color: var(--ink-mute); background: var(--surface-soft); border: 1px dashed var(--line); border-radius: var(--r); padding: 1.25rem; text-align: center; }
.client-bar { position: fixed; bottom: 0; left: 0; right: 0; background: var(--bg-deep); border-top: 1px solid var(--line); color: var(--ink); text-align: center; padding: .4rem 1rem calc(.4rem + env(safe-area-inset-bottom)); font-size: .9rem; font-weight: 600; z-index: 15; }

/* Buttons / forms --------------------------------------------------------- */
.btn { display: inline-flex; align-items: center; gap: .4rem; background: var(--primary); color: var(--surface); border: 0; border-radius: 999px; padding: .55rem 1.1rem; font: 600 .95rem var(--sans); cursor: pointer; text-decoration: none; line-height: 1.2; }
.btn:hover { background: var(--primary-deep); color: #fff; }
.btn.secondary { background: var(--bg-deep); color: var(--primary); } .btn.secondary:hover { background: var(--line); }
.btn.accent { background: var(--accent); } .btn.accent:hover { background: var(--accent-deep); }
.btn.sm { padding: .35rem .8rem; font-size: .85rem; } .btn.block { width: 100%; justify-content: center; }
.btn.danger { background: transparent; color: var(--bad); border: 1px solid var(--line); } .btn.danger:hover { background: #FEE2E2; }
.linklike { background: none; border: 0; padding: 0; font: inherit; color: var(--primary); cursor: pointer; text-decoration: underline; text-decoration-color: var(--primary-faint); }
.inline { display: inline; }
label.field, .field { display: block; margin-bottom: .9rem; }
.field > span, .field > label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: .25rem; }
input[type=text], input[type=search], input[type=email], input[type=password], input[type=date], input[type=time], input[type=url], input[type=number], textarea, select {
  width: 100%; border: 1px solid var(--line); border-radius: var(--r-sm); padding: .55rem .7rem; font: inherit; background: #fff; color: var(--ink); }
textarea { resize: vertical; min-height: 2.6em; }
input:focus, textarea:focus, select:focus { outline: 2px solid var(--primary-faint); outline-offset: 1px; border-color: var(--primary-soft); }
.check { display: flex; align-items: center; gap: .5rem; font-size: .95rem; cursor: pointer; } .check input { width: 18px; height: 18px; accent-color: var(--primary); }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-actions { display: flex; gap: .6rem; align-items: center; margin-top: 1rem; flex-wrap: wrap; }
.file-btn { display: inline-flex; align-items: center; cursor: pointer; } .file-btn input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.file-btn span { border: 1px dashed var(--line); border-radius: 999px; padding: .4rem .9rem; font-size: .9rem; color: var(--ink-soft); } .file-btn:hover span { border-color: var(--primary-soft); color: var(--primary); }
.file-btn.has-files span { border-style: solid; background: var(--surface-soft); }
.picker legend { font-weight: 600; font-size: .9rem; margin-bottom: .3rem; padding: 0; } .picker { border: 0; padding: 0; margin: 0 0 .9rem; }
.picker-grid { display: flex; flex-wrap: wrap; gap: .4rem; }
.picker-item { display: inline-flex; align-items: center; gap: .4rem; border: 1px solid var(--line); border-radius: 999px; padding: .25rem .7rem .25rem .3rem; cursor: pointer; font-size: .9rem; background: #fff; }
.picker-item input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.picker-item.is-on, .picker-item:has(input:checked) { background: var(--primary); color: var(--surface); border-color: var(--primary); }
.pill { display: inline-flex; align-items: center; gap: .4rem; border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: .3rem .75rem; font: 600 .85rem var(--sans); color: var(--ink-soft); cursor: pointer; }
.pill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--line); }
.pill-on { border-color: var(--primary-soft); color: var(--primary); background: #E8E9EB; } .pill-on .dot { background: var(--primary-soft); }
.item-tools { display: flex; gap: .5rem; flex-wrap: wrap; margin: 1rem 0; }
.tag { display: inline-block; font-size: .75rem; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; padding: 2px 8px; border-radius: 999px; background: var(--bg-deep); color: var(--ink-soft); }
.tag-sun { background: var(--bg-deep); color: var(--ink-soft); } .tag-ok { background: #DCFCE7; color: #166534; } .tag-bad { background: #FEE2E2; color: #991B1B; } .tag-sage { background: #E8E9EB; color: var(--primary); } .tag-rose { background: #F3DDE3; color: var(--rose); }

/* Avatars ---------------------------------------------------------------- */
.avatar { --av: var(--primary-soft); display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 50%; background: var(--av); color: #fff; font: 700 .8rem var(--sans); flex: none; letter-spacing: .02em; }
.avatar-sm { width: 26px; height: 26px; font-size: .65rem; } .avatar-lg { width: 48px; height: 48px; font-size: 1rem; }
.avatar-row { display: flex; } .avatar-row .avatar { margin-right: -6px; border: 2px solid var(--surface); }

/* Home ------------------------------------------------------------------- */
.projects-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 1rem; } .project-card { min-width: 0; }
.project-card { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); border: 1px solid var(--line-soft); padding: 1.1rem 1.2rem; display: flex; flex-direction: column; gap: .5rem; min-height: 150px; text-decoration: none; color: inherit; position: relative; transition: transform .12s, box-shadow .12s; overflow: hidden; }
.project-card:hover { transform: translateY(-2px); color: inherit; box-shadow: 0 2px 4px rgba(30,32,35,.05), 0 16px 32px -16px rgba(30,32,35,.28); }
.project-card h3 { margin: 0; font-size: 1.15rem; } .project-card .desc { color: var(--ink-soft); font-size: .92rem; margin: 0; flex: 1; }
.project-card .foot { display: flex; align-items: center; justify-content: space-between; gap: .5rem; font-size: .8rem; color: var(--ink-mute); }
.project-card .pin { position: absolute; top: 10px; right: 10px; }
.pin button { background: none; border: 0; cursor: pointer; font-size: 1rem; color: var(--line); padding: 4px; line-height: 1; } .pin button.on, .pin button:hover { color: var(--ink); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin: 1.5rem 0 .75rem; } .section-head h2 { margin: 0; }
.strip { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.mini-list { list-style: none; margin: 0; padding: 0; } .mini-list li { display: flex; gap: .6rem; padding: .45rem 0; border-top: 1px solid var(--line-soft); font-size: .93rem; align-items: baseline; }
.mini-list li:first-child { border-top: 0; } .mini-list .when { color: var(--ink-mute); flex: none; min-width: 5.5em; font-size: .85rem; }

/* Project ---------------------------------------------------------------- */
.project-head { margin-bottom: 1rem; }
.crumbs { font-size: .9rem; color: var(--ink-mute); margin-bottom: .5rem; } .crumbs a { color: var(--ink-soft); text-decoration: none; } .crumbs a:hover { text-decoration: underline; }
.tooltabs { display: flex; gap: .2rem; overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid var(--line); -webkit-overflow-scrolling: touch; }
.tooltabs::-webkit-scrollbar { display: none; }
.tooltabs a { white-space: nowrap; padding: .5rem .8rem; text-decoration: none; color: var(--ink-soft); font-weight: 600; border-bottom: 3px solid transparent; margin-bottom: -1px; }
.tooltabs a.is-active { color: var(--primary); border-color: var(--accent); }
.project-hero { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.25rem; }
.project-hero h1 { margin-bottom: .2rem; } .project-hero .desc { color: var(--ink-soft); max-width: 60ch; margin: 0; }
.tool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1rem; } .tool-card { min-width: 0; }
.tool-card { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); border: 1px solid var(--line-soft); padding: 1.1rem 1.2rem; min-height: 190px; display: flex; flex-direction: column; }
.tool-card h2 { font-size: 1.2rem; margin: 0 0 .6rem; display: flex; align-items: center; gap: .5rem; } .tool-card h2 a { text-decoration: none; }
.tool-card .ico { width: 28px; height: 28px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; color: #fff; font-size: .9rem; font-weight: 800; flex: none; }
.ico-todos { background: var(--primary-soft); } .ico-schedule { background: var(--sky); } .ico-docs { background: var(--twilight); } .ico-approvals { background: var(--sage); } .ico-checkins { background: var(--gold); }
.tool-card ul { list-style: none; margin: 0; padding: 0; font-size: .93rem; } .tool-card li { padding: .35rem 0; border-top: 1px solid var(--line-soft); display: flex; gap: .5rem; align-items: center; }
.tool-card li a { text-decoration: none; color: var(--ink); flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tool-card .more { margin-top: auto; padding-top: .6rem; font-size: .85rem; }
.tool-card .blurb { color: var(--ink-mute); font-size: .9rem; }
.people-strip { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.side { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 1.25rem; align-items: start; } .side > * { min-width: 0; }

/* Lists / to-dos ---------------------------------------------------------- */
.todolist { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); padding: 1rem 1.2rem; margin-bottom: 1rem; }
.todolist-head { display: flex; align-items: center; gap: .75rem; margin-bottom: .4rem; } .todolist-head h2 { margin: 0; font-size: 1.2rem; flex: 1; } .todolist-head h2 a { text-decoration: none; }
.progress { width: 30px; height: 30px; flex: none; }
.todos { list-style: none; margin: 0; padding: 0; }
.todo { display: flex; align-items: flex-start; gap: .6rem; padding: .45rem 0; border-top: 1px solid var(--line-soft); }
.todo:first-child { border-top: 0; }
.todo .box { margin-top: 3px; width: 18px; height: 18px; accent-color: var(--primary); flex: none; cursor: pointer; }
.todo .text { flex: 1; min-width: 0; } .todo .text a { text-decoration: none; color: var(--ink); }
.todo.is-done .text a { text-decoration: line-through; color: var(--ink-mute); }
.todo .meta { display: inline-flex; gap: .45rem; align-items: center; margin-left: .4rem; font-size: .8rem; color: var(--ink-mute); vertical-align: middle; flex-wrap: wrap; }
.todo .meta .late { color: var(--bad); font-weight: 700; } .todo .meta .today { color: var(--ink); font-weight: 700; }
.todo .grip { cursor: grab; color: var(--line); user-select: none; padding: 2px 4px; margin-top: 1px; } .todo.dragging { opacity: .4; }
.todo-group { margin-top: 1.1rem; }
.todo-group-head, .todo-group h3 { display: flex; align-items: center; gap: .5rem; font: 700 .9rem var(--sans); text-transform: uppercase; letter-spacing: .06em; color: var(--ink); background: var(--surface-soft); border-left: 4px solid var(--hc, var(--accent)); border-radius: 8px; padding: .5rem .75rem; margin: 0 0 .35rem; }
.todo-group-head .n { font-weight: 600; font-size: .75rem; letter-spacing: 0; text-transform: none; color: var(--ink-mute); background: var(--surface); border: 1px solid var(--line-soft); border-radius: 999px; padding: 0 .5rem; }
.todo-group-head .menu { margin-left: auto; text-transform: none; letter-spacing: 0; font-weight: 400; }
.todos .todo-group-row { list-style: none; margin: .7rem 0 .2rem; padding: 0; border: 0; }
.todos .todo-group-row:first-child { margin-top: .2rem; }
.add-todo { margin-top: .6rem; }
.add-todo .quick { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; } .add-todo .quick input[type=text] { flex: 1 1 200px; min-width: 0; }
.add-todo .quick input[type=date] { flex: 0 0 auto; width: auto; padding: .45rem .55rem; font-size: .9rem; } .add-todo .quick select { flex: 0 0 auto; width: auto; padding: .45rem 1.8rem .45rem .55rem; font-size: .9rem; }
.add-todo .quick-hint { margin: .3rem 0 0; display: none; } .add-todo:focus-within .quick-hint { display: block; }
.todo .meta .cadence { color: var(--accent-deep); font-weight: 600; }
.quick-card { border-left: 4px solid var(--accent); }
.card-quick { margin-top: .6rem; } .card-quick .quick select { max-width: 9rem; }
.add-todo details { margin-top: .5rem; } .add-todo summary { cursor: pointer; font-size: .9rem; color: var(--ink-soft); }
.list-desc { color: var(--ink-soft); margin: 0 0 .6rem; }
.done-toggle { margin-top: .8rem; font-size: .9rem; }
.item-head { display: flex; align-items: flex-start; gap: .75rem; margin-bottom: .5rem; } .item-head h1 { margin: 0; font-size: 1.6rem; flex: 1; }
.item-meta { color: var(--ink-mute); font-size: .9rem; margin-bottom: 1rem; display: flex; flex-wrap: wrap; gap: .3rem 1rem; }
.item-meta strong { color: var(--ink-soft); }
.prose { line-height: 1.6; } .prose h2, .prose h3, .prose h4 { margin-top: 1.2em; } .prose ul, .prose ol { padding-left: 1.4em; } .prose blockquote { border-left: 3px solid var(--line); margin: 0; padding: .2rem 1rem; color: var(--ink-soft); }
.prose code { background: var(--bg-deep); padding: 1px 5px; border-radius: 4px; font-size: .9em; } .prose p:last-child { margin-bottom: 0; }
.mention { background: #E8E9EB; color: var(--primary); border-radius: 4px; padding: 0 3px; font-weight: 600; }

/* Comments / attachments ------------------------------------------------- */
.comments { margin-top: 1.5rem; border-top: 1px solid var(--line); padding-top: 1rem; }
.comment { display: flex; gap: .75rem; padding: .8rem 0; border-bottom: 1px solid var(--line-soft); } .comment-body { flex: 1; min-width: 0; }
.comment-meta { font-size: .9rem; margin-bottom: .2rem; display: flex; gap: .6rem; align-items: baseline; flex-wrap: wrap; }
.comment-form { display: flex; gap: .75rem; padding-top: 1rem; } .comment-form textarea { margin-bottom: .5rem; }
.attachments { display: flex; flex-wrap: wrap; gap: .5rem; margin: .6rem 0; }
.attach { display: inline-flex; align-items: center; gap: .4rem; border: 1px solid var(--line); border-radius: var(--r-sm); padding: .35rem .6rem; font-size: .88rem; text-decoration: none; background: #fff; max-width: 100%; }
.attach-img { padding: 0; overflow: hidden; } .attach-img img { display: block; max-height: 160px; max-width: 240px; object-fit: cover; }
.file-ico { width: 14px; height: 18px; border: 2px solid var(--ink-mute); border-radius: 2px; display: inline-block; position: relative; flex: none; }

/* Schedule --------------------------------------------------------------- */
.cal-head { display: flex; align-items: center; justify-content: space-between; gap: .5rem; margin-bottom: .6rem; flex-wrap: wrap; } .cal-head h2 { margin: 0; }
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 2px; background: var(--line-soft); border: 1px solid var(--line-soft); border-radius: var(--r); overflow: hidden; }
.cal .dow { background: var(--bg-deep); font-size: .75rem; text-transform: uppercase; letter-spacing: .05em; padding: .3rem; text-align: center; color: var(--ink-soft); font-weight: 700; }
.cal .day { background: var(--surface); min-width: 0; overflow: hidden; min-height: 92px; padding: .3rem .35rem; font-size: .8rem; position: relative; }
.cal .day.pad { background: var(--surface-soft); } .cal .day.today .n { background: var(--accent); color: #fff; }
.cal .n { display: inline-block; width: 22px; height: 22px; line-height: 22px; text-align: center; border-radius: 50%; font-weight: 700; margin-bottom: .2rem; }
.cal .ev { display: block; background: #E8E9EB; color: var(--primary); border-radius: 4px; padding: 1px 5px; margin-bottom: 2px; text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.cal .ev.timed { background: transparent; border-left: 3px solid var(--accent); border-radius: 0; padding-left: 4px; }
.cal .ev.td { background: var(--bg-deep); color: var(--ink-soft); }
.cal .day.add { cursor: pointer; } .cal .day.add:hover { outline: 2px solid var(--primary-faint); outline-offset: -2px; }
.agenda { list-style: none; margin: 0; padding: 0; } .agenda li { display: flex; gap: 1rem; padding: .6rem 0; border-top: 1px solid var(--line-soft); align-items: baseline; }
.agenda .d { flex: none; width: 7.5em; color: var(--ink-mute); font-size: .9rem; } .agenda a { text-decoration: none; font-weight: 600; }
.event-date { font-family: var(--serif); font-size: 1.1rem; color: var(--ink-soft); }

/* Docs & Files ---------------------------------------------------------------- */
.docs-bar { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; margin-bottom: 1rem; }
.docs-bar .spacer { flex: 1; }
.docs-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: .8rem; }
.doc-tile { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); padding: .9rem; text-decoration: none; color: var(--ink); display: flex; flex-direction: column; gap: .4rem; min-height: 130px; position: relative; overflow: hidden; }
.doc-tile:hover { color: var(--ink); transform: translateY(-2px); }
.doc-tile .kind { font-size: .7rem; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-mute); font-weight: 700; }
.doc-tile .t { font-weight: 600; line-height: 1.25; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; }
.doc-tile .thumb { height: 70px; background-size: cover; background-position: center; border-radius: 6px; margin: -.2rem 0 .1rem; background-color: var(--bg-deep); }
.doc-tile .foot { margin-top: auto; font-size: .78rem; color: var(--ink-mute); }
.doc-tile.folder { background: var(--surface-soft); border: 1px solid var(--line-soft); box-shadow: none; }
.doc-tile.folder .t::before { content: '📁 '; }
.doc-tile .swatch { position: absolute; top: 0; left: 0; right: 0; height: 5px; }
.c-sage { background: var(--sage); } .c-sun { background: #B08D57; } .c-clay { background: var(--clay); } .c-rose { background: var(--rose); } .c-twilight { background: var(--twilight); } .c-sky { background: var(--sky); }
.docs-list { list-style: none; margin: 0; padding: 0; background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); }
.docs-list li { display: flex; gap: .8rem; align-items: center; padding: .6rem 1rem; border-top: 1px solid var(--line-soft); } .docs-list li:first-child { border-top: 0; }
.docs-list a { text-decoration: none; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.doc-view img.full { max-width: 100%; border-radius: var(--r-sm); }
.doc-view iframe { width: 100%; height: 75vh; border: 1px solid var(--line); border-radius: var(--r-sm); background: #fff; }
.editor { font-family: var(--sans); min-height: 50vh; line-height: 1.6; }
.md-help { font-size: .82rem; color: var(--ink-mute); }

/* Check-ins -------------------------------------------------------------- */
.question-card { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); padding: 1.1rem 1.2rem; margin-bottom: 1rem; }
.question-card h2 { font-size: 1.25rem; margin: 0 0 .25rem; } .question-card h2 a { text-decoration: none; }
.question-card .sched { color: var(--ink-mute); font-size: .9rem; }
.answer { display: flex; gap: .8rem; padding: 1rem 0; border-top: 1px solid var(--line-soft); } .answer-body { flex: 1; min-width: 0; }
.answer .who { font-weight: 600; } .answer .who small { color: var(--ink-mute); font-weight: 400; }
.answer-form textarea { min-height: 7em; }
.date-tabs { display: flex; gap: .3rem; flex-wrap: wrap; margin-bottom: 1rem; }
.date-tabs a { font-size: .85rem; padding: .25rem .7rem; border-radius: 999px; background: var(--bg-deep); text-decoration: none; color: var(--ink-soft); }
.date-tabs a.is-active { background: var(--primary); color: var(--surface); }
.days-pick { display: flex; gap: .3rem; flex-wrap: wrap; } .days-pick label { border: 1px solid var(--line); border-radius: 999px; padding: .25rem .7rem; cursor: pointer; font-size: .9rem; background: #fff; }
.days-pick label:has(input:checked) { background: var(--primary); color: var(--surface); border-color: var(--primary); } .days-pick input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.pending-ask { background: var(--bg-deep); border-radius: var(--r); padding: 1rem 1.2rem; margin-bottom: 1rem; }

/* Hey / activity / my stuff --------------------------------------------- */
.notifs { list-style: none; margin: 0; padding: 0; background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); }
.notifs li { display: flex; gap: .8rem; align-items: flex-start; padding: .8rem 1rem; border-top: 1px solid var(--line-soft); } .notifs li:first-child { border-top: 0; }
.notifs li.unread { background: #F6F2EA; } .notifs .t { flex: 1; min-width: 0; } .notifs .t a { text-decoration: none; }
.notifs .t .ctx { display: block; font-size: .82rem; color: var(--ink-mute); }
.day-head { font-family: var(--sans); font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-mute); margin: 1.4rem 0 .4rem; }
.activity { list-style: none; margin: 0; padding: 0; background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); }
.activity li { display: flex; gap: .7rem; padding: .6rem 1rem; border-top: 1px solid var(--line-soft); align-items: flex-start; font-size: .95rem; } .activity li:first-child { border-top: 0; }
.activity li a { text-decoration: none; }
.subnav { display: flex; gap: .3rem; flex-wrap: wrap; margin-bottom: 1rem; }
.subnav a { padding: .35rem .9rem; border-radius: 999px; text-decoration: none; font-weight: 600; color: var(--ink-soft); background: var(--bg-deep); font-size: .92rem; }
.subnav a.is-active { background: var(--primary); color: var(--surface); }
.group-head { font-family: var(--sans); font-size: .95rem; margin: 1.2rem 0 .4rem; display: flex; align-items: center; gap: .5rem; } .group-head .n { background: var(--bg-deep); border-radius: 999px; padding: 0 8px; font-size: .8rem; }
.group-head.late { color: var(--bad); }
.find-form { display: flex; gap: .5rem; margin-bottom: 1.5rem; } .find-form input { flex: 1; font-size: 1.1rem; }

/* Adminland / people ----------------------------------------------------------- */
.people-table { width: 100%; border-collapse: collapse; background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden; font-size: .93rem; }
.people-table th, .people-table td { padding: .6rem .9rem; text-align: left; border-top: 1px solid var(--line-soft); vertical-align: middle; }
.people-table th { background: var(--bg-deep); border-top: 0; font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-soft); }
.people-table tr.archived td { opacity: .5; }
.person-row { display: flex; align-items: center; gap: .6rem; }
.invite-link { background: var(--surface-soft); border: 1px dashed var(--line); padding: .6rem .8rem; border-radius: var(--r-sm); font-family: ui-monospace, monospace; font-size: .85rem; word-break: break-all; }
.person-pick { display: flex; align-items: center; gap: .6rem; padding: .5rem .6rem; border-radius: var(--r-sm); cursor: pointer; } .person-pick:hover { background: var(--surface-soft); }
.person-pick input { width: 18px; height: 18px; accent-color: var(--primary); }
.person-pick .nm { flex: 1; } .person-pick small { display: block; color: var(--ink-mute); }

/* Sign-in -------------------------------------------------------------------- */
.bare-wrap { max-width: 420px; margin: 0 auto; padding: 8vh 16px 3rem; }
.bare-brand { text-align: center; margin-bottom: 1.75rem; color: #fff; }
.bare-brand h1 { color: #fff; font: 600 1.15rem/1.3 var(--sans); letter-spacing: .32em; text-transform: uppercase; margin: 1.1rem 0 .35rem; padding-left: .32em; }
.bare-tagline { font: italic 300 .82rem var(--sans); letter-spacing: .22em; text-transform: uppercase; color: #B9BBBF; margin: 0; padding-left: .22em; }
.bare-app { font: 600 .72rem var(--sans); letter-spacing: .2em; text-transform: uppercase; color: var(--primary-faint); margin: 1.4rem 0 0; }
.bare-contact { text-align: center; color: #B9BBBF; font-size: .85rem; margin: 1.5rem 0 0; } .bare-contact a { text-decoration: none; white-space: nowrap; }
.bare .card { color: var(--ink); }
.bare-foot { text-align: center; color: var(--primary-faint); font-size: .85rem; margin-top: 2rem; }
.bare a { color: var(--bg); }
.bare .card a { color: var(--primary); }

/* Responsive ------------------------------------------------------------------ */
@media (max-width: 760px) {
  .topbar-in { height: auto; flex-wrap: wrap; padding: .5rem 16px; gap: .5rem; }
  .topnav { order: 3; width: 100%; justify-content: flex-start; gap: .1rem; margin: 0; overflow-x: auto; scrollbar-width: none; }
  .topnav a { padding: 6px 8px; font-size: .9rem; }
  .side, .strip, .grid-2 { grid-template-columns: 1fr; }
  .cal .day { min-height: 60px; padding: .2rem; } .cal .ev { font-size: .68rem; padding: 0 3px; }
  .comment-form .avatar, .comment .avatar { display: none; }
  .page { padding-top: 1rem; }
  h1, .h1 { font-size: 1.6rem; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* Calendar (shared + per-household) ------------------------------------------ */
.cal-top { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: .75rem; }
.cal-title { display: flex; align-items: baseline; gap: .6rem; } .cal-title h1 { margin: 0; }
.cal-controls { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.seg { display: inline-flex; background: var(--bg-deep); border-radius: 999px; padding: 3px; }
.seg a { padding: .45rem .95rem; border-radius: 999px; text-decoration: none; font-weight: 600; color: var(--ink-soft); font-size: .92rem; min-height: 36px; display: inline-flex; align-items: center; }
.seg a.is-active { background: var(--surface); color: var(--primary); box-shadow: var(--shadow); }
.hh-filter { display: flex; gap: .4rem; flex-wrap: wrap; margin-bottom: .9rem; }
.hh-chip { --hc: var(--primary-soft); display: inline-flex; align-items: center; gap: .45rem; border: 1px solid var(--line); border-radius: 999px; padding: .35rem .8rem; text-decoration: none; color: var(--ink-soft); font-size: .88rem; font-weight: 600; background: var(--surface); min-height: 36px; }
.hh-chip .dot, .hh-dot, .day-group .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--hc); display: inline-block; flex: none; }
.hh-dot { margin-right: .4rem; vertical-align: 1px; }
.hh-chip.is-on { background: var(--primary); color: var(--surface); border-color: var(--primary); }
.hh-chip.is-on .dot { box-shadow: 0 0 0 2px var(--surface); }
.cal-head h2 { font-size: 1.3rem; }
.cal .day { min-height: 118px; padding: .35rem .4rem; }
.cal .day .n { text-decoration: none; color: var(--ink); } .cal .day.pad .n { color: var(--ink-mute); }
.cal .day.today .n { background: var(--accent); color: #fff; }
.cal .day .more { display: block; font-size: .75rem; color: var(--ink-mute); text-decoration: none; padding: 1px 5px; } .cal .day .more:hover { color: var(--primary); }
.chip { --hc: var(--primary-soft); display: block; max-width: 100%; border-radius: 5px; padding: 2px 6px 2px 8px; margin-bottom: 3px; text-decoration: none; font-size: .8rem; font-weight: 600; color: var(--ink); line-height: 1.3; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; border-left: 4px solid var(--hc); background: color-mix(in srgb, var(--hc) 14%, #fff); }
.chip:hover { background: color-mix(in srgb, var(--hc) 26%, #fff); color: var(--ink); }
.chip-timed { background: var(--surface); border-left-width: 2px; padding-left: 9px; } .chip-timed b { color: var(--hc); font-weight: 700; margin-right: 2px; }
.chip-todo { background: transparent; border-left-style: dotted; font-weight: 500; color: var(--ink-soft); }
.chip .box-ico { display: inline-block; width: 10px; height: 10px; border: 1.5px solid var(--hc); border-radius: 2px; margin-right: 5px; vertical-align: -1px; }
.chip-sub { display: block; font-size: .76rem; font-weight: 500; color: var(--ink-mute); white-space: normal; }
.cal-week { grid-template-columns: repeat(7, minmax(0, 1fr)); }
.wday { background: var(--surface); min-width: 0; min-height: 50vh; display: flex; flex-direction: column; }
.wday.today .wday-head .n { background: var(--accent); color: #fff; }
.wday-head { display: flex; flex-direction: column; align-items: center; padding: .5rem 0 .35rem; text-decoration: none; color: var(--ink); border-bottom: 1px solid var(--line-soft); background: var(--surface-soft); }
.wday-head .wd { font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-mute); font-weight: 700; }
.wday-head .n { font-family: var(--serif); font-size: 1.3rem; font-weight: 600; width: 34px; height: 34px; line-height: 34px; text-align: center; border-radius: 50%; }
.wday-body { padding: .4rem .4rem; flex: 1; }
.wday-body .chip { white-space: normal; padding: .4rem .5rem .4rem .6rem; margin-bottom: .4rem; font-size: .86rem; }
.wday-empty { color: var(--line); display: block; text-align: center; padding-top: 1rem; }
.cal-day { max-width: 760px; }
.day-group { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); padding: 1rem 1.1rem; margin-bottom: .9rem; }
.day-group h3 { font-family: var(--sans); font-size: .95rem; display: flex; align-items: center; gap: .5rem; margin: 0 0 .6rem; } .day-group h3 a { text-decoration: none; color: var(--ink); }
.day-group .chip, .list-day .chip { white-space: normal; padding: .55rem .7rem .55rem .8rem; margin-bottom: .45rem; font-size: .95rem; }
.cal-list { max-width: 760px; } .list-day { margin-bottom: .4rem; }
.cal-legend { margin-top: .5rem; }
.swatches { display: flex; gap: .5rem; flex-wrap: wrap; }
.swatch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.swatch span { display: block; width: 34px; height: 34px; border-radius: 50%; background: var(--hc); border: 3px solid transparent; box-shadow: 0 0 0 1px var(--line); cursor: pointer; }
.swatch input:checked + span { border-color: var(--surface); box-shadow: 0 0 0 2.5px var(--hc); }
.project-card { border-top: 7px solid var(--hc, var(--line)); }
.project-hero h1::before { content: ''; display: inline-block; width: 12px; height: 12px; border-radius: 50%; background: var(--hc, transparent); margin-right: .5rem; vertical-align: 2px; }

/* Touch + iPad ---------------------------------------------------------------- */
.btn, .pill, .seg a, .hh-chip, .tooltabs a, .topnav a, .subnav a { min-height: 40px; }
.todo .box, .check input { width: 20px; height: 20px; }
@media (hover: none) { .todo .grip { display: none; } .project-card:hover, .doc-tile:hover { transform: none; } }
/* iPad portrait (834) through landscape (1024-1366): comfortable, not cramped */
@media (min-width: 761px) and (max-width: 1100px) {
  .page { padding-left: 20px; padding-right: 20px; }
  .side { grid-template-columns: minmax(0, 1fr) 260px; }
  .cal .day { min-height: 104px; } .chip { font-size: .76rem; }
  .projects-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tool-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1101px) { .cal .day { min-height: 130px; } .wday { min-height: 56vh; } }
@media (max-width: 760px) {
  .cal-week { grid-template-columns: 1fr; } .wday { min-height: 0; } .wday-head { flex-direction: row; gap: .6rem; justify-content: flex-start; padding: .5rem .8rem; } .wday-empty { display: none; } .wday:not(.today) .wday-body:has(> .wday-empty) { display: none; }
  .cal-month .day { min-height: 64px; padding: .2rem; } .cal-month .chip { font-size: .62rem; padding: 0 3px; border-left-width: 3px; } .cal-month .chip b { display: none; }
  .cal-top { align-items: flex-start; } .seg a { padding: .45rem .7rem; }
}

/* Questionnaire (/questionnaire) */
.q-banner { display: flex; align-items: center; gap: 1rem; justify-content: space-between; background: var(--surface); border-left: 5px solid var(--accent); border-radius: var(--r); box-shadow: var(--shadow); padding: .9rem 1.1rem; margin: 0 0 1.25rem; text-decoration: none; color: var(--ink); line-height: 1.4; }
.q-banner:hover { color: var(--ink); box-shadow: 0 6px 18px rgba(0,0,0,.08); }
.q-banner .btn { flex: none; }
.q-page .lede { font-size: 1.05rem; color: var(--ink-soft); margin-bottom: 1.25rem; }
.q-section h2 { margin-top: 0; }
.q { padding: 1rem 0; border-top: 1px solid var(--line-soft); }
.q:first-of-type { border-top: 0; }
.q-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; }
.q-label { font-weight: 600; font-size: 1rem; display: flex; gap: .55rem; align-items: baseline; }
.q-num { color: var(--accent); font: 700 .8rem var(--sans); min-width: 1.4em; }
.q-help { margin: .25rem 0 .6rem 2em; }
.q input[type=text], .q textarea { width: 100%; margin-top: .4rem; font-size: 1rem; }
.q textarea { min-height: 5.5em; }
.q-checks { display: grid; grid-template-columns: 1fr 1fr; gap: .35rem 1rem; margin-top: .5rem; }
.q-checks .check { padding: .3rem 0; min-height: 40px; }
.q-saved { font-size: .78rem; color: var(--sage, #5F7B59); font-weight: 600; opacity: 0; transition: opacity .3s; white-space: nowrap; }
.q-saved.is-on { opacity: 1; }
.q-grid-wrap { overflow-x: auto; margin-top: .5rem; }
.q-grid { width: 100%; border-collapse: collapse; font-size: .92rem; }
.q-grid th, .q-grid td { padding: .45rem .5rem; border-top: 1px solid var(--line-soft); text-align: center; }
.q-grid thead th { border-top: 0; font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-mute); }
.q-grid tbody th { text-align: left; font-weight: 500; }
.q-grid td label { display: flex; justify-content: center; align-items: center; min-height: 40px; cursor: pointer; }
.q-grid input[type=radio] { width: 20px; height: 20px; accent-color: var(--primary); }
@media (max-width: 640px) { .q-checks { grid-template-columns: 1fr; } .q-banner { flex-direction: column; align-items: flex-start; } }
.q-others ul.plain { list-style: none; margin: .5rem 0; padding: 0; }
.q-others li { display: flex; align-items: center; gap: .75rem; padding: .4rem 0; border-bottom: 1px solid var(--line); }
.q-others li:last-child { border-bottom: 0; }
.q-others li .btn { margin-left: auto; }


/* Round one: house pages, vendors, approvals, today -------------------------- */
.eyebrow { font: 600 .78rem var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--accent-deep); margin-bottom: .15rem; }

/* House hero: the photo (or the household colour) as a banner. */
.house-hero { --hc: var(--primary-soft); position: relative; border-radius: var(--r); margin-bottom: 1.25rem; overflow: hidden; background: linear-gradient(135deg, color-mix(in srgb, var(--hc) 22%, #fff), color-mix(in srgb, var(--hc) 6%, var(--surface))); border: 1px solid color-mix(in srgb, var(--hc) 30%, var(--line-soft)); }
.house-hero.has-photo { background: var(--photo) center/cover no-repeat; min-height: 260px; display: flex; align-items: flex-end; color: #fff; }
.house-hero.has-photo::before { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20,22,25,.05) 0%, rgba(20,22,25,.35) 45%, rgba(20,22,25,.82) 100%); }
.house-hero-in { position: relative; display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding: 1.4rem 1.5rem; width: 100%; }
.house-hero h1 { margin: 0 0 .25rem; font-size: 2.1rem; line-height: 1.1; }
.house-hero .desc { max-width: 60ch; margin: .2rem 0 .5rem; color: var(--ink-soft); }
.house-hero.has-photo .desc, .house-hero.has-photo .house-addr { color: rgba(255,255,255,.85); }
.house-hero.has-photo h1 { text-shadow: 0 2px 12px rgba(0,0,0,.35); }
.house-addr { font: 600 .8rem var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--accent-deep); margin-bottom: .3rem; }
.house-hero.has-photo .pill { background: rgba(255,255,255,.92); }
.house-hero.has-photo .btn.secondary { background: rgba(255,255,255,.92); color: var(--primary); }
.house-hero .tag-sun { background: rgba(255,255,255,.85); }
.hero-actions { align-self: flex-end; }

/* About this home */
.house-sections { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1rem 1.5rem; margin-top: .8rem; }
.house-section .h4 { color: var(--accent-deep); font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; font-family: var(--sans); font-weight: 700; margin-bottom: .4rem; border-bottom: 1px solid var(--line-soft); padding-bottom: .3rem; }
.house-dl { margin: 0; display: grid; gap: .35rem; } .house-dl > div { display: grid; grid-template-columns: minmax(90px, 38%) 1fr; gap: .5rem; font-size: .93rem; align-items: baseline; }
.house-dl dt { color: var(--ink-mute); font-weight: 500; } .house-dl dd { margin: 0; overflow-wrap: anywhere; }
.house-dl dt .tag { font-size: .6rem; padding: 0 5px; vertical-align: 1px; }
.secret { display: inline-flex; align-items: center; gap: .5rem; } .secret-val { font-family: 'JetBrains Mono', ui-monospace, monospace; font-size: .9rem; letter-spacing: .08em; background: var(--surface-soft); border: 1px dashed var(--line); border-radius: 6px; padding: 0 .45rem; }
.secret.is-open .secret-val { border-style: solid; background: #FBF5E8; letter-spacing: .04em; }
.app-chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.app-chip { display: inline-flex; align-items: center; gap: .5rem; padding: .35rem .8rem .35rem .4rem; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; color: var(--ink); font-weight: 600; font-size: .9rem; background: var(--surface); transition: border-color .12s, transform .12s; }
.app-chip:hover { border-color: var(--accent); transform: translateY(-1px); color: var(--ink); }
.app-chip.static { font-weight: 500; color: var(--ink-soft); }
.app-mark { width: 24px; height: 24px; border-radius: 50%; background: var(--primary-soft); color: #fff; display: inline-flex; align-items: center; justify-content: center; font: 700 .8rem var(--serif); }

/* Edit "About this home" */
.hf-rows { display: grid; gap: .4rem; }
.hf-row { display: grid; grid-template-columns: minmax(110px, 1.1fr) minmax(140px, 2fr) 120px auto 28px; gap: .4rem; align-items: center; }
.hf-row input[type=text], .hf-row select { padding: .4rem .55rem; font-size: .92rem; }
.hf-vis { display: inline-flex; align-items: center; gap: .3rem; font-size: .8rem; color: var(--ink-mute); white-space: nowrap; cursor: pointer; }
.hf-del { border: 0; background: transparent; color: var(--ink-mute); font-size: 1.2rem; cursor: pointer; line-height: 1; padding: 0; } .hf-del:hover { color: var(--bad); }
@media (max-width: 640px) { .hf-row { grid-template-columns: 1fr 1fr; } .hf-row .hf-value { grid-column: 1 / -1; } }

/* Vendors */
.vendor-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: .75rem; }
.vendor-card { display: flex; gap: .8rem; align-items: flex-start; background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--r); padding: .9rem 1rem; text-decoration: none; color: inherit; box-shadow: var(--shadow); transition: transform .12s; }
.vendor-card:hover { transform: translateY(-2px); color: inherit; }
.vendor-body { display: flex; flex-direction: column; gap: .1rem; min-width: 0; flex: 1; }
.vendor-mark { width: 36px; height: 36px; border-radius: 10px; background: var(--primary); color: #fff; display: inline-flex; align-items: center; justify-content: center; font: 700 1.1rem var(--serif); flex: none; }
.vendor-mark.lg { width: 48px; height: 48px; font-size: 1.5rem; border-radius: 12px; }
.vendor-list { list-style: none; margin: .6rem 0 0; padding: 0; } .vendor-list li { display: flex; align-items: center; gap: .75rem; padding: .55rem 0; border-top: 1px solid var(--line-soft); }
.vendor-list li:first-child { border-top: 0; } .vendor-list .vendor-body strong a { text-decoration: none; }

/* Approvals */
.approvals { list-style: none; margin: 0; padding: 0; }
.approval-row { display: flex; gap: .75rem; align-items: flex-start; padding: .7rem 0; border-top: 1px solid var(--line-soft); } .approval-row:first-child { border-top: 0; }
.approval-row .text { flex: 1; min-width: 0; } .approval-row .text > a { text-decoration: none; font-weight: 600; }
.approval-row .meta { display: flex; flex-wrap: wrap; gap: .3rem .8rem; font-size: .85rem; color: var(--ink-mute); margin-top: .15rem; }
.ap-badge { width: 28px; height: 28px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-weight: 800; flex: none; background: var(--bg-deep); color: var(--ink-soft); }
.status-approved .ap-badge { background: #DCFCE7; color: #166534; } .status-declined .ap-badge { background: #FEE2E2; color: #991B1B; }
.ap-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--gold); flex: none; } .ap-dot.ap-approved { background: var(--ok); } .ap-dot.ap-declined { background: var(--bad); }
.ap-status { display: flex; align-items: center; gap: .6rem; margin-bottom: .3rem; }
.ap-amount { font: 700 1.4rem var(--serif); color: var(--accent-deep); }
.ap-note { margin: .5rem 0 1rem; padding: .6rem .9rem; border-left: 3px solid var(--accent); background: var(--surface-soft); border-radius: 0 var(--r-sm) var(--r-sm) 0; }
.ap-decide { margin: 1rem 0; padding: 1rem; border: 1px solid var(--brass-line); border-radius: var(--r); background: var(--tint); }
.approval-view.status-approved { border-top: 4px solid var(--ok); } .approval-view.status-declined { border-top: 4px solid var(--bad); } .approval-view.status-pending { border-top: 4px solid var(--primary-faint); }

/* Today, at a glance */
.today-strip { background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--r); margin-bottom: 1.5rem; }
.today-sum { display: flex; align-items: center; flex-wrap: wrap; gap: .35rem 1.4rem; padding: .7rem 1.1rem; min-height: 48px; list-style: none; font-size: .93rem; color: var(--ink-soft); }
.today-sum::-webkit-details-marker { display: none; } summary.today-sum { cursor: pointer; } summary.today-sum:hover { background: var(--surface-soft); border-radius: var(--r); }
.today-label { font: 700 .76rem var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--ink); }
.today-stat { white-space: nowrap; } .today-stat b { color: var(--ink); font-weight: 700; } .today-stat.is-zero, .today-stat.is-zero b { color: var(--ink-mute); font-weight: 400; }
.today-stat .late, .mini-list .when.late { color: var(--bad); font-weight: 700; font-style: normal; } .today-stat .late::before { content: '· '; color: var(--ink-mute); font-weight: 400; }
.today-toggle { margin-left: auto; font-size: .85rem; color: var(--ink-mute); white-space: nowrap; } .today-toggle::after { content: 'Show ▾'; } .today-strip[open] .today-toggle::after { content: 'Hide ▴'; }
.today-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: .8rem 1.75rem; padding: .8rem 1.1rem 1rem; border-top: 1px solid var(--line-soft); }
.today-cols > div { min-width: 0; } .today-more { font-size: .85rem; margin: .35rem 0 0; }
.mini-list.tight li { padding: .3rem 0; font-size: .9rem; border-top: 0; } .mini-list.tight .when { min-width: 4.8em; font-size: .82rem; }
.mini-list.tight .what { min-width: 0; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-decoration: none; } .mini-list.tight .what .mute { font-size: .82rem; margin-left: .3rem; }
.today-cols .h4 { color: var(--accent-deep); font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; font-family: var(--sans); font-weight: 700; margin-bottom: .2rem; }

/* Home cards with a house photo */
.project-card .card-photo { display: block; height: 110px; margin: -1.1rem -1.2rem .4rem; background: var(--bg-deep) center/cover no-repeat; border-bottom: 1px solid var(--line-soft); }
.project-card .card-addr { margin-top: -.3rem; }
.project-card.has-photo .pin { top: 8px; right: 8px; } .project-card.has-photo .pin button { background: rgba(255,255,255,.85); border-radius: 50%; width: 28px; height: 28px; }

/* Owner-added dates on the calendar */
.chip-owner { border-left-style: dashed; background: var(--tint); } .chip-owner::after { content: 'owners'; font: 600 .62rem var(--sans); letter-spacing: .06em; text-transform: uppercase; color: var(--accent-deep); margin-left: .4rem; }

/* Vendor directory */
.vendor-search input { min-width: 260px; }
@media (min-width: 761px) { .vendors-layout { grid-template-columns: minmax(0, 1fr) 320px; } }
.vendor-dir { padding: .4rem 1.25rem; }
.vendor-trade { padding: .6rem 0 .4rem; border-top: 1px solid var(--line-soft); } .vendor-trade:first-child { border-top: 0; }
.vendor-trade-h { font: 700 .78rem var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--accent-deep); margin: .2rem 0 .3rem; }
.vendor-trade-h .mute { font-weight: 500; letter-spacing: 0; margin-left: .3rem; }
.vendor-row { display: grid; grid-template-columns: 36px minmax(140px, 1.3fr) minmax(130px, 1fr) minmax(160px, 1.4fr); gap: .4rem 1rem; align-items: center; padding: .5rem 0; border-top: 1px dashed var(--line-soft); }
.vendor-row:first-of-type { border-top: 0; }
.vendor-who { display: flex; flex-direction: column; min-width: 0; } .vendor-name { font-weight: 600; text-decoration: none; }
.vendor-contact { display: flex; flex-direction: column; min-width: 0; } .vendor-contact a { text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vendor-houses { display: flex; flex-wrap: wrap; gap: .3rem; justify-content: flex-end; }
.house-chip { font-size: .78rem; font-weight: 600; padding: 2px 9px; border-radius: 999px; background: var(--surface-soft); border: 1px solid var(--line); color: var(--ink-soft); text-decoration: none; white-space: nowrap; }
.house-chip:hover { border-color: var(--accent); color: var(--ink); }
a.vendor-mark { text-decoration: none; }
@media (max-width: 760px) {
  .vendor-row { grid-template-columns: 36px 1fr; } .vendor-contact, .vendor-houses { grid-column: 2; justify-content: flex-start; }
  .vendor-search input { min-width: 0; flex: 1; }
}

/* House or client */
.kind-pick { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: .6rem; }
.kind-opt { display: flex; gap: .6rem; align-items: flex-start; border: 1px solid var(--line); border-radius: var(--r-sm); padding: .7rem .8rem; cursor: pointer; background: var(--surface); }
.kind-opt:has(input:checked) { border-color: var(--accent); background: var(--tint); box-shadow: inset 0 0 0 1px var(--accent); }
.kind-opt input { margin-top: 3px; accent-color: var(--primary); } .kind-opt small { display: block; color: var(--ink-mute); font-weight: 400; }

/* Company footer ------------------------------------------------------------ */
.site-foot { max-width: var(--maxw); margin: 0 auto; padding: 0 16px 4.5rem; color: var(--ink-mute); font-size: .82rem; display: flex; flex-wrap: wrap; gap: .3rem 1.2rem; align-items: center; }
.site-foot .co { font-weight: 600; letter-spacing: .16em; text-transform: uppercase; font-size: .72rem; color: var(--ink-soft); display: inline-flex; align-items: center; gap: .5rem; }
.site-foot .co .brand-mark { width: 15px; height: 16px; }
.site-foot a { color: inherit; text-decoration: none; white-space: nowrap; } .site-foot a:hover { color: var(--ink); }
.page { padding-bottom: 2.5rem; }

/* Brand: larger mark and name ------------------------------------------------ */
.brand { font-size: 1.05rem; letter-spacing: .22em; } .brand .brand-mark { width: 30px; height: 33px; }
.topnav-home { opacity: .75; }
.menu > summary { position: relative; }
.menu-dot { position: absolute; top: -2px; right: -2px; width: 11px; height: 11px; border-radius: 50%; background: var(--sunset); border: 2px solid var(--primary); }
.menu-pop .badge { float: right; }

/* Owners' view: unmistakable on every page ------------------------------------ */
.topbar.is-preview { border-bottom: 0; }
.preview-bar { position: sticky; top: calc(56px + env(safe-area-inset-top)); z-index: 19; display: flex; align-items: center; justify-content: center; gap: .6rem; padding: .55rem 16px; background: #FACC15; color: #1B1B1B; font-size: .93rem; text-align: center; background-image: repeating-linear-gradient(135deg, rgba(0,0,0,.05) 0 12px, transparent 12px 24px); border-bottom: 1px solid #CA9A04; }
.preview-eye { font-size: 1.1rem; line-height: 1; }
.preview-exit { background: #FACC15; color: #1B1B1B; } .preview-exit:hover { background: #FDE047; color: #000; }
body.in-preview .page { outline: 0; } body.in-preview { box-shadow: inset 0 0 0 4px #FACC15; }

/* Household cards: whole card opens the house --------------------------------- */
.project-card { position: relative; min-height: 0; gap: .6rem; cursor: pointer; transition: transform .15s ease, box-shadow .15s ease; }
.project-card h3 { font-size: 1.35rem; font-weight: 700; letter-spacing: -.015em; }
.project-card h3 a { text-decoration: none; color: var(--ink); }
.project-card .card-link::after { content: ''; position: absolute; inset: 0; border-radius: var(--r); }
.project-card .card-link:focus-visible::after { outline: 3px solid var(--primary-faint); outline-offset: 2px; }
.project-card .pin, .project-card .arrange-tools { z-index: 2; }
.project-card .card-photo { height: 96px; }
.project-card .foot { min-height: 24px; }
.know-pill { background: var(--sunset); color: #fff; font: 700 .74rem var(--sans); letter-spacing: .03em; padding: 3px 9px; border-radius: 999px; }
.arrange-tools { display: flex; align-items: center; justify-content: space-between; gap: .5rem; position: relative; border-top: 1px dashed var(--line); padding-top: .5rem; }
.arrange-tools[hidden] { display: none; }
.arrange-tools button { width: 44px; height: 40px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface-soft); font-size: 1.1rem; cursor: pointer; }
.is-arranging .project-card { cursor: grab; outline: 2px dashed var(--line); outline-offset: 3px; } .is-arranging .project-card .card-link::after { display: none; } .is-arranging .project-card .card-link { pointer-events: none; }
.is-arranging .project-card.dragging { opacity: .45; }
#arrange-toggle[aria-pressed="true"] { background: var(--primary); color: #fff; }

/* People: contact cards -------------------------------------------------------- */
.person-chips { display: flex; flex-wrap: wrap; gap: .6rem; }
.person-chip { display: inline-flex; align-items: center; gap: .6rem; min-height: 52px; padding: .4rem 1rem .4rem .45rem; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font: inherit; color: var(--ink); cursor: pointer; text-align: left; transition: transform .12s ease, border-color .12s ease, box-shadow .12s ease; }
.person-chip:hover { border-color: var(--primary-faint); transform: translateY(-1px); box-shadow: var(--shadow); }
.person-chip strong { display: block; font-size: .95rem; line-height: 1.2; } .person-chip small { display: block; color: var(--ink-mute); font-size: .78rem; }
.person-mark { width: 38px; height: 38px; border-radius: 50%; background: var(--hc, var(--primary)); color: #fff; display: inline-flex; align-items: center; justify-content: center; font: 700 1rem var(--serif); flex: none; }
.person-mark.lg { width: 56px; height: 56px; font-size: 1.5rem; }
dialog.contact-card { border: 0; border-radius: 18px; padding: 1.4rem 1.5rem 1.2rem; width: min(430px, calc(100vw - 32px)); box-shadow: 0 24px 60px -12px rgba(0,0,0,.4); color: var(--ink); }
dialog.contact-card::backdrop { background: rgba(17,17,17,.45); backdrop-filter: blur(2px); }
.dialog-x { position: absolute; top: 10px; right: 12px; width: 40px; height: 40px; border: 0; background: none; font-size: 1.6rem; line-height: 1; color: var(--ink-mute); cursor: pointer; border-radius: 50%; } .dialog-x:hover { background: var(--bg); color: var(--ink); }
.contact-top { display: flex; align-items: center; gap: .9rem; margin-bottom: 1rem; } .contact-top h3 { margin: 0; font-size: 1.35rem; }
.contact-dl { margin: 0; } .contact-dl > div { display: grid; grid-template-columns: 7em minmax(0, 1fr); gap: .5rem; padding: .55rem 0; border-top: 1px solid var(--line-soft); }
.contact-dl dt { color: var(--ink-mute); font-size: .88rem; } .contact-dl dd { margin: 0; overflow-wrap: anywhere; }
.contact-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-top: 1rem; }
.person-edit { border: 1px solid var(--line-soft); border-radius: var(--r); padding: .9rem 1rem .7rem; margin-bottom: .8rem; background: var(--surface-soft); }
.person-edit-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 1rem; }
@media (max-width: 640px) { .person-edit-grid { grid-template-columns: 1fr; } }

/* In the Know -------------------------------------------------------------------- */
.know-card { border-left: 4px solid var(--sunset); }
.know-list { list-style: none; margin: .5rem 0 0; padding: 0; } .know-list li { border-top: 1px solid var(--line-soft); } .know-list li:first-child { border-top: 0; }
.know-item { display: block; width: 100%; text-align: left; background: none; border: 0; padding: .55rem 0; font: inherit; font-size: .92rem; color: var(--ink); cursor: pointer; } .know-item:hover span { text-decoration: underline; }
.know-item small { display: block; font-size: .8rem; }

/* Access & Codes ------------------------------------------------------------------- */
.code-list { list-style: none; margin: 0; padding: 0; } .code-list li { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding: .8rem 0; border-top: 1px solid var(--line-soft); } .code-list li:first-child { border-top: 0; }
.code-label { font-weight: 600; } .code-value { font-size: 1.05rem; } .code-value .secret { display: inline-flex; align-items: center; gap: .7rem; } .code-value .secret-val { font-family: ui-monospace, monospace; letter-spacing: .08em; }

/* Vendor documents, email ------------------------------------------------------- */
.file-list { list-style: none; margin: 0 0 1rem; padding: 0; } .file-list li { display: flex; align-items: center; gap: .8rem; flex-wrap: wrap; padding: .6rem 0; border-top: 1px solid var(--line-soft); } .file-list li:first-child { border-top: 0; }
.file-type { font: 700 .72rem var(--sans); letter-spacing: .06em; text-transform: uppercase; background: var(--primary); color: #fff; border-radius: 6px; padding: 3px 8px; white-space: nowrap; }
.file-main { flex: 1; min-width: 180px; } .file-main a { font-weight: 600; overflow-wrap: anywhere; } .file-main small { display: block; }
.tag-warn { background: #FBF0D0; color: #7A5A00; }
.upload-row { display: flex; align-items: flex-end; gap: .8rem; flex-wrap: wrap; border-top: 1px solid var(--line-soft); padding-top: .9rem; } .upload-row .field { margin: 0; } .upload-row .file-btn, .upload-row .btn { margin-bottom: 2px; }
.mail-row { padding: .8rem 1.1rem; margin-bottom: .6rem; } .mail-row > summary { display: flex; justify-content: space-between; gap: 1rem; cursor: pointer; list-style: none; align-items: center; flex-wrap: wrap; } .mail-row > summary::-webkit-details-marker { display: none; }
.mail-to { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; } .mail-body { background: var(--surface-soft); border-radius: var(--r-sm); padding: .8rem 1rem; font-size: .95rem; }

/* Softer, friendlier surfaces -------------------------------------------------- */
:root { --r: 16px; --r-sm: 10px; }
.btn, .pill, .person-chip, .app-chip { transition: transform .12s ease, background-color .12s ease, box-shadow .12s ease; }
.btn:active, .person-chip:active, .project-card:active { transform: scale(.98); }
.btn.danger { background: transparent; }
@media (max-width: 760px) { .preview-bar { top: 0; position: static; font-size: .85rem; } }

.projects-grid { align-items: start; }

/* A long household menu scrolls sideways instead of running off the bar. */
.topnav { min-width: 0; overflow-x: auto; scrollbar-width: none; } .topnav::-webkit-scrollbar { display: none; } .topbar-right { flex: none; }

/* Yes is green, no is red, wherever a decision is asked for. */
.btn.go { background: var(--ok); color: #fff; } .btn.go:hover { background: #166534; color: #fff; }
.btn.stop { background: var(--bad); color: #fff; } .btn.stop:hover { background: #B91C1C; color: #fff; }

/* Waiting is amber, between the green yes and the red no. */
.status-pending .ap-badge { background: #FBF0D0; color: #7A5A00; }
.ap-dot { background: #EAB308; }
.approval-view.status-pending { border-top-color: #EAB308; }
/* A finished to-do ticks green. */
.todo .box:checked, .todo.is-done .box { accent-color: var(--ok); }

/* Today stands out on the calendar: a tinted box with a bold frame and a label. */
.cal .day.today, .wday.today { background: #FFF8DB; box-shadow: inset 0 0 0 3px var(--accent); position: relative; z-index: 1; }
.cal .day.today .n, .wday.today .wday-head .n { font-weight: 800; }
.cal .day.today .n::after, .wday.today .wday-head .n::after { content: 'Today'; position: absolute; margin-left: 1.9em; font: 800 .68rem var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--ink); line-height: inherit; white-space: nowrap; }
.wday.today .wday-head { background: transparent; }

/* The owners' week at a glance on their house page. */
.week-strip-wrap { margin-bottom: 1.25rem; }
.week-strip { --hc: var(--accent); display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: .5rem; }
.week-day { background: var(--surface); border: 1px solid var(--line-soft); border-radius: 14px; padding: .55rem .5rem .6rem; min-height: 104px; min-width: 0; }
.week-day.is-empty { background: var(--surface-soft); }
.week-day.is-today { background: #FFF8DB; box-shadow: inset 0 0 0 2px var(--accent); }
.week-head { display: flex; align-items: baseline; justify-content: space-between; gap: .3rem; margin-bottom: .4rem; }
.week-head .dow { font: 700 .7rem var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--ink-mute); } .week-day.is-today .dow { color: var(--ink); }
.week-head .n { font: 700 1.15rem var(--serif); color: var(--ink); } .week-day.is-empty .n { color: var(--ink-mute); }
.week-ev { display: block; background: color-mix(in srgb, var(--hc) 12%, #fff); border-left: 3px solid var(--hc); border-radius: 6px; padding: 3px 6px; margin-top: 4px; font-size: .8rem; font-weight: 600; line-height: 1.25; color: var(--ink); text-decoration: none; overflow-wrap: anywhere; }
.week-ev b { font-weight: 700; color: var(--ink-soft); white-space: nowrap; } .week-ev:hover { background: color-mix(in srgb, var(--hc) 22%, #fff); color: var(--ink); }
/* Phones: all seven days stay in one row (day and number, a dot when something is on), with the events listed underneath. */
.week-head .tight, .week-agenda { display: none; }
@media (max-width: 760px) {
  .week-strip { gap: .25rem; }
  .week-day { min-height: 0; padding: .45rem .1rem .5rem; border-radius: 10px; text-align: center; position: relative; }
  .week-day .week-ev { display: none; }
  .week-head { flex-direction: column; align-items: center; gap: .1rem; margin: 0; }
  .week-head .wide { display: none; } .week-head .tight { display: inline; }
  .week-head .dow { font-size: .62rem; letter-spacing: .06em; } .week-head .n { font-size: 1.05rem; line-height: 1.1; }
  .week-day.has-ev::after { content: ''; display: block; width: 6px; height: 6px; border-radius: 50%; background: var(--hc); margin: .25rem auto 0; }
  .week-day.is-empty::after { content: ''; display: block; height: 6px; margin-top: .25rem; }
  .week-agenda { display: block; margin-top: .7rem; }
  .wa-day + .wa-day { margin-top: .6rem; }
  .wa-date { font: 700 .72rem var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-mute); margin-bottom: .1rem; }
  .week-agenda .week-ev { display: block; font-size: .9rem; padding: 6px 9px; }
}

/* The grid of tool cards keeps the same gap below it as between its cards. */
.tool-grid { margin-bottom: 1rem; }

/* Calendar chips: a to-do is a checkbox with no bar; an owners' date carries a label, not a dashed edge. */
.chip-todo { border-left-color: transparent; border-left-style: solid; padding-left: 4px; }
.chip-owner { border-left-style: solid; background: color-mix(in srgb, var(--hc) 14%, #fff); }
.chip-owner::after { content: none; } .chip-owner::before { content: 'owners'; font: 700 .6rem var(--sans); letter-spacing: .06em; text-transform: uppercase; background: var(--ink); color: #fff; border-radius: 3px; padding: 1px 4px; margin-right: .35rem; vertical-align: 1px; }
.cal-legend { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem 1.1rem; margin: .8rem 0 1rem; }
.cal-legend .key { display: inline-flex; align-items: center; } .key-chip { --hc: var(--ink-mute); display: inline-block; margin: 0; pointer-events: none; overflow: visible; }

/* Vendor area */
.week-todo { background: transparent; border-left-color: transparent; font-weight: 500; }
.week-todo .box-ico { display: inline-block; width: 10px; height: 10px; border: 1.5px solid var(--hc); border-radius: 2px; margin-right: 5px; vertical-align: -1px; }
.mini-list .ctx { color: var(--ink-mute); font-size: .85rem; margin-left: .5rem; }
.work-item h1 { font-size: 1.7rem; }
.hf-section[data-section="access"] .hf-row { grid-template-columns: minmax(110px, 1.1fr) minmax(140px, 2fr) 120px auto auto 28px; }
@media (max-width: 640px) { .hf-section[data-section="access"] .hf-row { grid-template-columns: 1fr 1fr; } }

/* New to-do window */
dialog.todo-dialog { border: 0; border-radius: 18px; padding: 1.4rem 1.5rem 1.2rem; width: min(560px, calc(100vw - 24px)); max-height: calc(100vh - 32px); overflow-y: auto; box-shadow: 0 24px 60px -12px rgba(0,0,0,.4); color: var(--ink); text-align: left; }
dialog.todo-dialog::backdrop { background: rgba(17,17,17,.45); backdrop-filter: blur(2px); }
.todo-dialog-title { font: 600 1.15rem var(--serif); margin: 0 0 1rem; padding: .55rem .8rem; background: var(--surface-soft); border-radius: 10px; overflow-wrap: anywhere; }
.todo-dialog .field > span { display: block; font-weight: 600; font-size: .9rem; margin-bottom: .3rem; }
.date-chips { display: flex; flex-wrap: wrap; gap: .35rem; margin-bottom: .5rem; } .date-chips .pill { cursor: pointer; } .date-chips .pill.is-on { background: var(--ink); color: #fff; border-color: var(--ink); }
.todo-more { margin: .2rem 0 .4rem; } .todo-more summary { cursor: pointer; font-size: .9rem; color: var(--ink-soft); }
.card-quick .add-todo { margin-top: 0; }

/* The hidden attribute always wins, whatever layout a block uses. */
[hidden] { display: none !important; }

/* Household page: one centered column the full width of the banner. */
.house-main > .card, .house-main > section { margin-left: 0; margin-right: 0; }
.week-card { margin-bottom: 1rem; }

/* Repeats, with a custom every-so-often cadence */
.repeat-custom { display: flex; align-items: center; gap: .5rem; margin-top: .5rem; flex-wrap: wrap; }
.repeat-custom input[type=number] { width: 5.2rem; } .repeat-custom select { width: auto; min-width: 7rem; }
.repeat-until { display: block; margin-top: .6rem; } .repeat-until input { max-width: 14rem; }
.series-scope .check { display: flex; margin-top: .3rem; }
.birthday-pick select { width: auto; }
.form-part { font: 700 .8rem var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-mute); margin: 1.6rem 0 .6rem; }
.house-profile .house-people { margin-top: .8rem; } .house-profile-notes { margin-top: 1rem; }
/* Docs: list view with tick boxes and a bar to move what is ticked */
.docs-list li .pick { flex: 0 0 auto; width: 18px; height: 18px; accent-color: var(--primary); }
.docs-list li .row-act { flex: 0 0 auto; font-weight: 500; font-size: .85rem; }
.docs-move { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; margin-top: .8rem; padding: .7rem 1rem; background: var(--surface-soft); border: 1px solid var(--line-soft); border-radius: var(--r); }
.docs-move select { width: auto; max-width: 16rem; }
.doc-quick { display: flex; flex-wrap: wrap; gap: .6rem; align-items: end; margin: .2rem 0 1rem; padding: .8rem 1rem; background: var(--surface-soft); border-radius: var(--r); }
.doc-quick .field { margin: 0; flex: 1 1 12rem; }
@media (max-width: 640px) { .docs-list li .meta-x { display: none; } }
.doc-tools { margin: .2rem 0 .6rem; } .doc-tools > summary { cursor: pointer; color: var(--ink-soft); display: inline-block; }
.doc-tools[open] > summary { margin-bottom: .5rem; }
.mail-log { list-style: none; margin: 0; padding: 0; } .mail-log li { display: flex; gap: .7rem; align-items: baseline; padding: .45rem 0; border-top: 1px solid var(--line-soft); font-size: .9rem; } .mail-log li:first-child { border-top: 0; }
.mail-log li > span:nth-child(2) { flex: 1; min-width: 0; overflow-wrap: anywhere; } .mail-log .tag { flex: 0 0 auto; }

/* Calendar on your phone */
.setup-tiles { display: grid; gap: 1rem; margin-top: 1.2rem; }
.setup-tile.is-this { order: -1; outline: 2px solid var(--primary); outline-offset: -2px; }
.btn.big { display: block; text-align: center; padding: .95rem 1.2rem; font-size: 1.05rem; }
.steps { margin: 1rem 0 .8rem; padding: 0; list-style: none; counter-reset: step; display: grid; gap: .55rem; }
.steps li { counter-increment: step; position: relative; padding-left: 2.3rem; min-height: 1.7rem; font-size: .95rem; line-height: 1.7rem; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 1.7rem; height: 1.7rem; border-radius: 50%; background: var(--bg-deep); color: var(--ink-soft); font-weight: 600; font-size: .85rem; display: grid; place-items: center; line-height: 1; }
.steps[hidden] { display: none; }
.plain-list { margin: 0; padding-left: 1.1rem; display: grid; gap: .35rem; }
.phone-cta { margin-top: 1rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.phone-cta > div { display: grid; gap: .1rem; }
.phone-cta .btn { white-space: nowrap; flex: none; }
