@font-face {
  font-family: Atkinson;
  src: url('/fonts/atkinson-latin.woff2') format('woff2');
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
}
@font-face {
  font-family: Atkinson;
  src: url('/fonts/atkinson-latin-ext.woff2') format('woff2');
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
:root {
  font-family: Atkinson, 'Arial', sans-serif;
  color: #183047;
  background: #f7fafc;
  font-size: 16px;
  line-height: 1.5;
  --paper: #f7fafc;
  --ink: #183047;
  --muted: #4c6275;
  --blue: #165bd8;
  --amber: #8a5700;
  --red: #b42318;
  --green: #146b48;
  --line: #d7e2e9;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-width: 280px; }
button, input, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .58; }
button:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible {
  outline: 3px solid #165bd8;
  outline-offset: 3px;
}
main { max-width: 860px; margin: 0 auto; padding: 0 24px 80px; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(2.25rem, 5vw, 3.3rem); line-height: 1.06; letter-spacing: -.04em; font-weight: 800; }
h2 { font-size: 1.32rem; line-height: 1.2; letter-spacing: -.02em; }
h3 { font-size: 1.16rem; line-height: 1.25; letter-spacing: -.015em; }
.site-header { background: white; border-bottom: 1px solid var(--line); }
.header-inner { max-width: 1100px; margin: auto; padding: 14px 24px; min-height: 70px; display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.brand, .entry-brand { display: inline-flex; align-items: center; gap: 11px; font-size: 1.06rem; font-weight: 750; letter-spacing: -.02em; }
.brand-mark { display: inline-grid; place-items: center; flex: none; width: 34px; height: 34px; color: white; background: var(--blue); border-radius: 8px; font-size: 1.25rem; line-height: 1; font-weight: 800; }
.header-actions { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; justify-content: flex-end; }
.identity { font-weight: 700; }
.entry-screen { max-width: 520px; margin: clamp(36px, 9vh, 105px) auto 0; }
.entry-brand { margin-bottom: clamp(54px, 10vh, 92px); }
.entry-screen h1 { max-width: 11ch; margin-bottom: 16px; }
.entry-intro { max-width: 34ch; color: var(--muted); font-size: 1.18rem; line-height: 1.45; margin-bottom: 35px; }
.entry-form { padding: 26px; background: white; border: 1px solid var(--line); border-radius: 16px; }
label { display: block; margin-bottom: 8px; font-weight: 700; }
input:not([type=checkbox]), select { display: block; width: 100%; min-height: 52px; padding: 10px 14px; color: var(--ink); background: white; border: 1.5px solid #97a9b7; border-radius: 9px; }
input:not([type=checkbox]):hover, select:hover { border-color: var(--ink); }
form label:not(:first-child) { margin-top: 18px; }
.primary-button, .secondary-button { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 11px 20px; border-radius: 9px; font-weight: 750; border: 1.5px solid transparent; }
.primary-button { color: white; background: var(--blue); }
.primary-button:hover:not(:disabled) { background: #104bb8; }
.secondary-button { color: var(--blue); background: white; border-color: var(--blue); }
.secondary-button:hover { background: #eaf1ff; }
.entry-form .primary-button { width: 100%; margin-top: 22px; }
.link-button, .back-button, .text-button { border: 0; background: transparent; color: var(--blue); font-weight: 750; padding: 8px 0; text-decoration: underline; text-underline-offset: 3px; min-height: 44px; }
.link-button:hover, .back-button:hover, .text-button:hover { color: #10408c; }
.link-button { margin-top: 15px; }
.back-button { margin-bottom: 30px; }
.privacy-note { color: var(--muted); font-size: .9rem; line-height: 1.5; max-width: 56ch; margin-top: 44px; }
.message { max-width: 860px; margin: 22px auto 0; padding: 13px 16px; border-radius: 9px; background: #e9f1ff; color: #154a9f; font-weight: 650; }
.message[data-tone="error"] { background: #fff0ee; color: #9d2118; }
.workspace { padding-top: 58px; }
.page-heading { display: flex; justify-content: space-between; align-items: end; gap: 20px; margin-bottom: 30px; }
.page-heading h1 { margin-bottom: 10px; }
.page-heading p { color: var(--muted); font-size: 1.1rem; margin-bottom: 0; }
.add-button { flex: none; }
.composer { background: white; border: 1px solid var(--line); border-top: 5px solid var(--blue); border-radius: 12px; padding: 25px; margin: 24px 0 30px; }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.composer h2 { margin: 0 0 19px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.check { display: flex; gap: 11px; align-items: flex-start; font-weight: 500; margin: 21px 0 0; }
.check input { width: 22px; height: 22px; flex: none; accent-color: var(--blue); margin: 2px 0 0; }
.composer form > .primary-button { margin-top: 20px; }
.view-nav { display: flex; gap: clamp(14px, 4vw, 36px); border-bottom: 1px solid var(--line); overflow-x: auto; }
.view-nav button { flex: none; border: 0; border-bottom: 3px solid transparent; margin-bottom: -1px; padding: 12px 0 14px; min-height: 48px; color: var(--muted); background: transparent; font-weight: 700; }
.view-nav button[aria-current="page"] { color: var(--blue); border-bottom-color: var(--blue); }
.task-list { margin-top: 6px; }
.task { display: grid; grid-template-columns: 66px minmax(0, 1fr); gap: 20px; padding: 24px 0; border-bottom: 1px solid var(--line); }
.task-date { display: flex; flex-direction: column; align-items: center; justify-content: center; align-self: start; width: 62px; min-height: 76px; border-radius: 10px; color: var(--blue); background: #e9f1ff; font-variant-numeric: tabular-nums; text-decoration: none; }
.task-date strong { font-size: 1.7rem; line-height: 1; font-weight: 800; }
.task-date span { font-size: .88rem; font-weight: 700; }
.task-date small { font-size: .72rem; line-height: 1.15; }
.task.is-overdue .task-date { color: var(--red); background: #ffeae7; }
.task-content { min-width: 0; }
.task h3 { overflow-wrap: anywhere; margin-bottom: 9px; }
.task-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; color: var(--muted); margin-bottom: 0; }
.status { display: inline-flex; align-items: center; min-height: 27px; padding: 2px 9px; border-radius: 6px; font-size: .88rem; font-weight: 750; line-height: 1.2; }
.status[data-state="proposed"], .status[data-state="cancelled"] { background: #e9eef2; color: #344c5b; }
.status[data-state="pending_acceptance"] { background: #fff0cd; color: var(--amber); }
.status[data-state="accepted"] { background: #e9f1ff; color: #154a9f; }
.status[data-state="completed"] { background: #dff4e8; color: var(--green); }
.overdue-label { color: var(--red); font-weight: 750; }
.task-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin-top: 14px; }
.task-actions button, .member-actions button { min-height: 40px; padding: 7px 13px; border: 1px solid var(--blue); border-radius: 7px; background: white; color: var(--blue); font-weight: 750; }
.task-actions button:hover, .member-actions button:hover { background: #e9f1ff; }
.task-actions .quiet-action, .member-actions .quiet-action { border-color: transparent; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }
.admin-tools { margin-top: 15px; color: var(--muted); }
.admin-tools summary { cursor: pointer; width: fit-content; font-weight: 700; min-height: 40px; padding: 8px 0; }
.admin-tools .task-actions { margin-top: 4px; }
.admin-editor, .member-editor { padding: 18px; margin-top: 12px; background: white; border: 1px solid var(--line); border-radius: 10px; }
.admin-editor h4 { font-size: 1.05rem; margin: 0 0 14px; }
.admin-editor label, .member-editor label { max-width: 420px; }
.admin-editor label input, .admin-editor label select, .member-editor label input { margin-top: 7px; }
.editor-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 15px; margin-top: 20px; }
.history-list { padding-left: 20px; font-size: .92rem; color: var(--muted); }
.empty-state { padding: 38px 0; }
.empty-state h2 { margin-bottom: 8px; }
.empty-state p { color: var(--muted); max-width: 40ch; }
.list-heading { margin: 32px 0 10px; }
.member-row { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 14px; padding: 15px 0; border-bottom: 1px solid var(--line); }
.member-row strong { font-size: 1.06rem; }
.member-row .status { margin-left: 10px; }
.member-editor { flex-basis: 100%; margin-top: 0; }
.member-actions { display: flex; gap: 5px; flex-wrap: wrap; }
.inline-form { display: flex; align-items: end; gap: 12px; }
.inline-form > div { flex: 1; }
.admin-next { margin-top: 34px; padding-top: 22px; border-top: 1px solid var(--line); }
.admin-next p { color: var(--muted); margin-bottom: 12px; }
.admin-next select { max-width: 420px; margin-bottom: 14px; }
@media (max-width: 600px) {
  main { padding: 0 18px 64px; }
  .header-inner { padding: 12px 18px; align-items: flex-start; flex-direction: column; gap: 5px; }
  .brand { font-size: .95rem; }
  .header-actions { gap: 2px 12px; font-size: .9rem; justify-content: flex-start; }
  .entry-screen { margin-top: 34px; }
  .entry-brand { margin-bottom: 68px; }
  .entry-form { padding: 20px; }
  .workspace { padding-top: 38px; }
  .page-heading { align-items: stretch; flex-direction: column; margin-bottom: 23px; }
  .add-button { align-self: flex-start; }
  .form-grid { grid-template-columns: 1fr; gap: 0; }
  .task { gap: 13px; grid-template-columns: 52px minmax(0, 1fr); padding: 20px 0; }
  .task-date { width: 50px; min-height: 66px; }
  .task-date strong { font-size: 1.45rem; }
  .task-meta { gap: 7px; }
  .inline-form { align-items: stretch; flex-direction: column; }
  .member-row { align-items: flex-start; flex-direction: column; }
  .member-row .status { margin-left: 0; }
}
