.task-progress-layer,
.task-progress-layer * {
  box-sizing: border-box;
}

.tp-v2-context-menu{position:fixed;z-index:100000;min-width:138px;padding:6px;background:#fff;border:1px solid #e2e7ef;border-radius:12px;box-shadow:0 12px 32px rgba(23,32,49,.16)}
.tp-v2-context-menu button{width:100%;padding:10px 12px;border:0;border-radius:8px;background:transparent;text-align:left;color:#42516a;font:inherit;cursor:pointer}
.tp-v2-context-menu button:hover{background:#f1f4f8}
.tp-v2-repeat-editor{width:100%;max-width:440px;margin:0 auto;padding:24px;display:grid;gap:18px}
.tp-v2-repeat-title{margin:0 0 4px;font-weight:700;color:#42516a}
.tp-v2-repeat-editor>label{display:grid;grid-template-columns:92px 1fr;align-items:center;gap:12px;color:#42516a}
.tp-v2-repeat-editor input[type=date],.tp-v2-repeat-editor select{min-width:0;height:44px;padding:0 13px;border:1px solid #dfe5ee;border-radius:12px;background:#fff;color:#42516a;font:inherit}
.tp-v2-repeat-editor fieldset{margin:0;padding:14px;border:1px solid #e3e8f0;border-radius:14px;display:grid;gap:10px}
.tp-v2-repeat-editor legend{padding:0 7px;font-weight:700;color:#42516a}
.tp-v2-repeat-editor fieldset label{display:flex;align-items:center;gap:9px}
.tp-v2-repeat-editor>button{height:44px;margin-top:2px;border:0;border-radius:13px;background:#1d2738;color:#fff;font:inherit;font-weight:700;cursor:pointer}
@media(max-width:520px){.tp-v2-repeat-editor{padding:20px 18px}.tp-v2-repeat-editor>label{grid-template-columns:72px minmax(0,1fr);gap:10px}}

/* Category / dated TO DO / routine workspace */
.task-progress-dialog-backdrop--workspace .task-progress-dialog-panel,
.task-progress-dialog-panel:has(.tp-v2-workspace){width:min(1180px,calc(100vw - 48px));height:min(760px,calc(100vh - 48px));max-width:1180px;max-height:760px}
.task-progress-dialog-panel:has(.tp-v2-workspace) .task-progress-dialog-body{overflow:hidden;min-height:0;padding:0}
.tp-v2-workspace{display:flex;height:100%;min-height:0;flex-direction:column;padding:22px 26px 28px;color:#425069}
.tp-v2-toolbar{position:relative;display:grid;grid-template-columns:minmax(420px,1fr) minmax(360px,.9fr);align-items:center;gap:24px;margin-bottom:18px}.tp-v2-calendar-tools{display:flex;min-width:0;align-items:center;justify-content:flex-start;gap:24px}
.tp-v2-month{display:flex;min-width:0;align-items:center;gap:5px;font-size:20px;white-space:nowrap}.tp-v2-month button{display:grid;width:26px;height:32px;place-items:center;border:0;border-radius:50%;background:transparent;color:inherit;font-size:22px;line-height:1}.tp-v2-month button:hover{background:rgb(66 80 105 / 8%)}.tp-v2-menu-button{width:36px;height:36px;border:1px solid #e5eaf2;border-radius:12px;background:#fff;color:inherit;font-size:17px}
.tp-v2-switch{display:flex;padding:3px;border-radius:999px;background:#f2f4f8}.tp-v2-switch button{border:0;border-radius:999px;background:transparent;padding:7px 14px;color:#7b8493}.tp-v2-switch .is-active{background:#1d2635;color:#fff}
.tp-v2-choice-chips{gap:4px;padding:4px;background:#eef2fa}.tp-v2-choice-chips button{min-width:58px;padding:8px 15px;font-weight:700}.tp-v2-choice-chips .is-active{box-shadow:0 5px 12px rgba(49,79,180,.2)}
.tp-v2-menu-button{justify-self:end}.tp-v2-menu{position:absolute;z-index:3;right:0;top:44px;display:grid;min-width:150px;padding:8px;border:1px solid #e4e8ef;border-radius:14px;background:#fff;box-shadow:0 14px 40px rgba(25,35,50,.14)}.tp-v2-menu[hidden]{display:none}.tp-v2-menu button{border:0;background:#fff;padding:10px 12px;text-align:left;border-radius:8px}.tp-v2-menu button:hover{background:#f5f7fa}
.tp-v2-columns{display:grid;min-height:0;flex:1;grid-template-columns:minmax(420px,1fr) minmax(360px,.9fr);gap:24px}.tp-v2-left,.tp-v2-right{min-width:0;min-height:0}.tp-v2-left{display:flex;flex-direction:column;gap:18px}.tp-v2-right{display:flex;overflow:hidden;flex-direction:column;padding-right:4px}.tp-v2-todo-scroll{min-height:0;overflow-y:auto;padding-right:4px}.tp-v2-routine-list{min-height:0;overflow-y:auto}
.tp-v2-weekdays,.tp-v2-month-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:6px}.tp-v2-weekdays span{padding:7px 0;text-align:center;color:#89909b;font-size:13px}.tp-v2-day{position:relative;min-height:58px;border:0;border-radius:15px;background:transparent;color:#46536a;font-size:15px}.tp-v2-day:hover{background:#f5f7fb}.tp-v2-day.is-selected{background:#1d2635;color:#fff;box-shadow:0 8px 20px rgba(29,38,53,.18)}.tp-v2-day--empty{pointer-events:none}.tp-v2-day small{position:absolute;left:50%;bottom:7px;display:flex;gap:3px;transform:translateX(-50%)}.tp-v2-dot{width:7px;height:7px;border-radius:50%}
.tp-v2-panel-title{display:flex;align-items:center;justify-content:space-between;margin-bottom:12px}.tp-v2-panel-title h3{margin:0;font-size:20px}.tp-v2-panel-title>strong{color:#6f7887;font-size:14px;font-weight:600}.tp-v2-panel-title button{width:32px;height:32px;border:1px solid #e4e9f0;border-radius:50%;background:#fff;font-size:20px}.tp-v2-category header button{width:24px;height:24px;border:1px solid #e4e9f0;border-radius:50%;background:#fff;font-size:16px;line-height:1}
.tp-v2-overall-progress{display:flex;width:100%;height:9px;margin:0 0 17px;overflow:hidden;border-radius:999px;background:#dfe3e9}.tp-v2-progress-block{flex:var(--segment-size) 1 0;min-width:0}.tp-v2-progress-block.is-complete{background:var(--segment-color)}.tp-v2-progress-block.is-pending{background:#dfe3e9}
.tp-v2-category{margin-bottom:14px;padding:17px;border:1px solid #e7ebf1;border-radius:18px;background:#fff;box-shadow:0 5px 18px rgba(30,42,60,.045)}.tp-v2-category header{display:flex;align-items:center;gap:9px}.tp-v2-category header small{margin-left:auto}.tp-v2-category-dot{width:11px;height:11px;border-radius:50%;background:var(--category-color)}.tp-v2-todos{margin-top:12px}.tp-v2-todo{display:grid;grid-template-columns:26px 1fr 26px;align-items:center;gap:8px;min-height:38px;border-top:1px solid #f0f2f5}.tp-v2-todo:first-child{border-top:0}.tp-v2-todo input,.tp-v2-routine input{width:19px;height:19px;accent-color:var(--category-color)}.tp-v2-todo .is-done{text-decoration:line-through;color:#9aa1ab}.tp-v2-todo button{border:0;background:transparent;color:#d54855;font-size:18px}
.tp-v2-category--flat{margin:0;padding:9px 2px;border:0;border-bottom:1px solid #e8ecf2;border-radius:0;background:transparent;box-shadow:none}.tp-v2-category--flat:last-child{border-bottom:0}.tp-v2-category--flat .tp-v2-todos{margin-top:4px}.tp-v2-category--flat .tp-v2-todo{border-top:0;min-height:31px}
.tp-v2-task{padding:0 0 2px}.tp-v2-category--flat .tp-v2-todo{grid-template-columns:26px minmax(0,1fr) auto 24px}.tp-v2-todo[data-todo-collapse]{cursor:pointer}.tp-v2-title-tools{display:flex;min-width:0;align-items:center;gap:6px}.tp-v2-title-toggle{display:inline-flex;min-width:0;align-items:center;gap:7px}.tp-v2-collapse-arrow{display:block;width:0;height:0;flex:0 0 auto;border-top:4.9px solid transparent;border-bottom:4.9px solid transparent;border-left:7px solid #778294;font-style:normal;transform:rotate(90deg);transform-origin:center;transition:transform .14s ease}.tp-v2-collapse-arrow.is-collapsed{transform:rotate(0deg)}.tp-v2-subtodo-count{grid-column:3;display:inline-flex;align-items:center;padding:2px 4px;border:0;background:transparent;font-size:12px;color:#737d8c;font-weight:400}.tp-v2-todo>.tp-v2-row-delete{grid-column:4}.tp-v2-subtodos{display:grid;gap:1px;margin:0 0 1px 34px}.tp-v2-subtodo{display:grid;grid-template-columns:24px minmax(0,1fr) 24px;align-items:center;min-height:30px}.tp-v2-subtodo input{width:17px;height:17px;accent-color:var(--category-color)}.tp-v2-subtodo .is-done{text-decoration:line-through;color:#9aa1ab}.tp-v2-subtodo-add{display:grid;grid-template-columns:minmax(0,1fr);align-items:center;margin-left:34px;color:#7b8492}.tp-v2-subtodo-add[hidden]{display:none}.tp-v2-subtodo-add input{min-width:0;height:30px;border:0;background:transparent;padding:0 4px;color:inherit}.tp-v2-enter-submit{position:absolute!important;width:1px!important;height:1px!important;margin:-1px!important;padding:0!important;overflow:hidden!important;clip:rect(0 0 0 0)!important;white-space:nowrap!important;border:0!important}
[data-todo-content],[data-subtodo-content]{cursor:text;border-radius:5px}[data-inline-content-editing]{min-width:40px;padding:2px 4px;outline:2px solid var(--category-color);background:#fff;text-decoration:none!important}
.tp-v2-subtodos[hidden]{display:none}
.tp-v2-task[hidden],.tp-v2-subtodo[hidden]{display:none}
.tp-v2-inline-add{display:grid;grid-template-columns:1fr auto;gap:7px;margin-top:9px}.tp-v2-inline-add[hidden]{display:none}.tp-v2-inline-add input{min-width:0;height:38px;border:1px solid #dfe5ed;border-radius:10px;padding:0 11px}.tp-v2-inline-add button{border:0;border-radius:10px;background:#1d2635;color:#fff;padding:0 14px}
.tp-v2-category--flat .tp-v2-todos:empty{margin:0;padding:0}.tp-v2-category--flat .tp-v2-inline-add{margin:4px 0 1px}.tp-v2-category--flat .tp-v2-inline-add input{height:34px;border-radius:12px;padding:0 13px;line-height:34px}
.tp-v2-grass{display:grid;grid-template-columns:1fr 1fr;gap:12px}.tp-v2-grass-row{padding:10px 12px;border:1px solid #e8ecf2;border-radius:16px}.tp-v2-grass-row header{display:flex;justify-content:space-between;margin-bottom:9px}.tp-v2-grass-row>div{display:grid;grid-template-columns:repeat(7,16px);gap:7px}.tp-v2-grass-cell{width:16px;height:16px;border-radius:50%;background:#e8ebef}.tp-v2-grass-cell.level-1{background:color-mix(in srgb,var(--grass,#4b8b51) 35%,white)}.tp-v2-grass-cell.level-2{background:color-mix(in srgb,var(--grass,#4b8b51) 55%,white)}.tp-v2-grass-cell.level-3{background:color-mix(in srgb,var(--grass,#4b8b51) 75%,white)}.tp-v2-grass-cell.level-4{background:var(--grass,#4b8b51)}
.tp-v2-routine-list{display:grid;gap:10px}.tp-v2-routine{display:flex;align-items:center;gap:12px;padding:16px;border:1px solid #e7ebf1;border-radius:16px;background:#fff}.tp-v2-routine strong{margin-left:auto;font-size:14px}.tp-v2-empty{padding:30px;text-align:center;color:#9299a5}
.tp-v2-focus-scroll,.tp-v2-routine-scroll{min-height:0;overflow-y:auto;padding-right:4px}.tp-v2-focus-categories{display:grid;gap:11px;margin:0 0 22px;padding:0;list-style:none}.tp-v2-focus-category-label{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:5px;font-size:13px}.tp-v2-focus-category-label strong{font-variant-numeric:tabular-nums}.tp-v2-focus-category-bar{height:5px;border-radius:999px;background:linear-gradient(90deg,var(--category-color) var(--timer-width),#e5e9ef var(--timer-width))}.tp-v2-focus-empty{padding:18px 0;color:#9299a5;text-align:center}.tp-v2-focus-month-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:24px 0 12px}.tp-v2-focus-month-heading h3{margin:0;font-size:16px}.tp-v2-focus-month-heading strong{color:#657083;font-size:13px}.tp-v2-routine-scroll>.tp-v2-routine-list{overflow:visible}.tp-v2-routine-scroll [data-timer-month-region]{padding-top:2px}.tp-v2-focus-scroll .tp-timer-summary strong,.tp-v2-routine-scroll .tp-timer-summary strong{font-size:16px}.tp-v2-focus-scroll .tp-timer-day header,.tp-v2-routine-scroll .tp-timer-month header{margin-bottom:10px}
.tp-v2-editor{width:100%;margin:0;padding:20px 22px}.tp-v2-editor-field{display:grid;gap:8px;margin-bottom:16px;font-weight:600}.tp-v2-category-name,.tp-v2-visibility select{width:100%;height:44px;border:1px solid #dfe5ed;border-radius:12px;background:#fff;padding:0 13px;color:#425069}.tp-v2-editor fieldset{display:grid;grid-template-columns:repeat(8,1fr);gap:14px 10px;margin:18px 0;border:0;padding:0}.tp-v2-editor fieldset legend{margin-bottom:12px;font-weight:600}.tp-v2-editor fieldset label{display:grid;place-items:center}.tp-v2-editor fieldset label i,.tp-v2-manage i{display:block;width:27px;height:27px;border-radius:50%}.tp-v2-editor fieldset input{position:absolute;opacity:0}.tp-v2-editor fieldset input:checked+i{outline:3px solid #1d2635;outline-offset:3px}.tp-v2-editor>div{display:block;margin-top:20px}.tp-v2-editor>div button[type=submit]{width:100%;min-height:48px;border:0;border-radius:12px;background:#1d2635;color:#fff;font-weight:700}
.task-progress-dialog-backdrop.task-progress-dialog-backdrop--workspace.tp-v2-editor-open .task-progress-dialog-panel{width:min(460px,calc(100vw - 32px));max-width:460px;height:auto;max-height:min(650px,calc(100dvh - 32px))}.task-progress-dialog-backdrop.tp-v2-editor-open .task-progress-dialog-body{padding:0;overflow:auto}
.task-progress-dialog-backdrop.tp-v2-workspace-open .task-progress-dialog-header{gap:8px;padding:10px 16px}.task-progress-dialog-backdrop.tp-v2-workspace-open .task-progress-dialog-title{font-size:1rem;line-height:1.2}.task-progress-dialog-backdrop.tp-v2-workspace-open .task-progress-dialog-close{flex-basis:32px;width:32px;min-height:32px;font-size:1.15rem}
.task-progress-dialog-panel:focus{outline:none}
.tp-v2-manage{display:block;width:100%;margin:0;padding:20px 22px}.tp-v2-manage-list{display:grid;gap:8px}.tp-v2-manage-row{display:grid;grid-template-columns:32px minmax(0,1fr) 42px;gap:8px;transition:opacity .14s ease,transform .14s ease}.tp-v2-manage-row.is-dragging{z-index:2;opacity:.55;transform:scale(.99)}.tp-v2-manage button{display:flex;align-items:center;gap:10px;border:1px solid #e5e9ef;border-radius:11px;background:#fff;padding:10px}.tp-v2-manage .tp-v2-drag-handle{justify-content:center;padding:0;cursor:grab;touch-action:none;color:#8992a1;font-size:13px;letter-spacing:-3px}.tp-v2-manage .tp-v2-drag-handle:active{cursor:grabbing}.tp-v2-manage .danger{justify-content:center;color:#d54855}.tp-v2-manage>[data-editor-cancel]{width:100%;justify-content:center;margin-top:8px}
.tp-v2-theme--gray{--workspace-bg:#eef0f3;--day-bg:#fff;--day-fg:#46536a;background:var(--workspace-bg)}.tp-v2-theme--white{--workspace-bg:#fff;--day-bg:#e8ebef;--day-fg:#364257;background:var(--workspace-bg)}
.tp-v2-day{background:var(--day-bg,#fff);color:var(--day-fg,#46536a)}.tp-v2-day--empty{visibility:hidden}.tp-v2-day.is-selected{background:#1d2635;color:#fff}
.tp-v2-category-pill{padding:9px 13px;border-radius:999px;background:color-mix(in srgb,var(--category-color) 14%,white)}.tp-v2-category-pill button{margin-left:auto}
.tp-v2-category--flat{border:0}.tp-v2-category--flat .tp-v2-todos{padding:4px 10px}.tp-v2-subtodo{border:0}.tp-v2-subtodos{gap:0}
.tp-v2-status{appearance:none;width:18px!important;height:18px!important;border:1.5px solid #9aa3af;border-radius:50%;background:transparent}.tp-v2-status:checked{border-color:var(--category-color);background:var(--category-color)}
.tp-v2-day{isolation:isolate;overflow:hidden}
.tp-v2-plus{position:relative;box-sizing:border-box;width:26px;height:26px;display:grid;place-items:center;padding:0;border:1px solid #dfe5ed!important;border-radius:50%!important;background:#fff!important;color:#526078!important;font-size:0!important;font-weight:400;line-height:0}.tp-v2-plus::before,.tp-v2-plus::after{content:"";position:absolute;left:50%;top:50%;width:10px;height:1.5px;border-radius:999px;background:currentColor;transform:translate(-50%,-50%)}.tp-v2-plus::after{transform:translate(-50%,-50%) rotate(90deg)}.tp-v2-category-pill .tp-v2-plus{margin-left:4px}.tp-v2-row-delete{display:grid;width:24px;height:24px;place-items:center;border:0!important;background:transparent!important;padding:0!important;color:#7e8795!important;font-size:13px!important;opacity:0;pointer-events:none;transition:opacity .14s ease,background .14s ease}.tp-v2-todo:hover .tp-v2-row-delete,.tp-v2-subtodo:hover .tp-v2-row-delete,.tp-v2-row-delete:focus-visible{opacity:1;pointer-events:auto}.tp-v2-row-delete:hover{background:#eef1f5!important}
.task-progress-delete-toast{position:absolute;z-index:8;left:50%;bottom:20px;display:flex;align-items:center;gap:12px;transform:translateX(-50%);padding:10px 14px;border-radius:999px;background:#1d2635;color:#fff;box-shadow:0 10px 28px rgba(20,28,40,.24);font-size:13px}.task-progress-delete-toast[hidden]{display:none}.task-progress-delete-toast button{border:0;background:transparent;color:#f0c43c;font:inherit;font-weight:700;cursor:pointer}
.tp-v2-design-settings{padding:20px 22px}.tp-v2-design-settings h3{margin:0 0 16px}.tp-v2-design-settings>div{display:grid;grid-template-columns:1fr 1fr;gap:12px}.tp-v2-design-settings label input{position:absolute;opacity:0}.tp-v2-design-preview{display:grid;height:110px;place-items:end center;border:2px solid transparent;border-radius:16px;padding:12px;background:#eef0f3;color:#425069}.tp-v2-design-preview--white{background:#fff;box-shadow:inset 0 0 0 1px #e3e7ed}.tp-v2-design-settings input:checked+.tp-v2-design-preview{border-color:#1d2635}.tp-v2-design-settings>button{width:100%;height:48px;margin-top:18px;border:0;border-radius:12px;background:#1d2635;color:#fff;font-weight:700}.tp-v2-open-mode{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:0 0 16px;padding:0;border:0}.tp-v2-open-mode legend{grid-column:1/-1;margin-bottom:8px;font-weight:700}.tp-v2-open-mode label{display:flex;align-items:center;justify-content:center;height:40px;border:1px solid #dfe5ed;border-radius:10px;background:#fff}.tp-v2-open-mode label:has(input:checked){border-color:#1d2635;background:#1d2635;color:#fff}.tp-v2-open-mode input{position:absolute;opacity:0}
@media(max-width:820px){.task-progress-dialog-panel:has(.tp-v2-workspace){width:calc(100vw - 18px);height:calc(100vh - 18px);max-height:none}.tp-v2-workspace{padding:16px}.tp-v2-columns{grid-template-columns:1fr}.tp-v2-right{max-height:none}.tp-v2-grass{grid-template-columns:1fr}.tp-v2-toolbar{grid-template-columns:minmax(0,1fr) auto;gap:8px}.tp-v2-calendar-tools{justify-content:flex-start;flex-wrap:wrap}.tp-v2-menu{top:44px}}
@media(max-width:820px){.task-progress-dialog-panel:has(.tp-v2-workspace) .task-progress-dialog-body{overflow:auto}.tp-v2-workspace{height:auto}.tp-v2-right{overflow:visible}.tp-v2-todo-scroll,.tp-v2-routine-list{overflow:visible}}
@media(max-width:820px){.tp-v2-focus-scroll,.tp-v2-routine-scroll{overflow:visible}.tp-v2-choice-chips button{min-width:0;padding:7px 11px}}
@media(hover:none){.tp-v2-row-delete{opacity:1;pointer-events:auto}}

.task-progress-dialog-backdrop,
.task-progress-dialog-backdrop * {
  box-sizing: border-box;
}

.task-progress-layer {
  container-type: inline-size;
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  gap: 10px;
  padding: clamp(10px, 3cqw, 18px);
  overflow: auto;
  color: var(--content-font-color, #24232b);
  font-family: var(--content-font-family, inherit);
}

.task-progress-layer--activity_calendar {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 1rem;
  overflow: hidden;
}

.task-progress-header,
.task-progress-task-heading,
.task-progress-actions,
.task-progress-detail-heading,
.task-progress-detail-progress-text {
  display: flex;
  align-items: center;
  min-width: 0;
}

.task-progress-header {
  justify-content: space-between;
  gap: 8px;
}

.task-progress-layer--activity_calendar .task-progress-header {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) 28px;
  flex: 0 0 auto;
  gap: 2px;
  margin-bottom: 3px;
  padding: 3px 5px;
  text-align: center;
}

.task-progress-header--compact {
  justify-content: flex-end;
  gap: 4px;
}

.task-progress-title {
  min-width: 0;
  margin: 0;
  overflow: hidden;
  font-size: clamp(0.9rem, 5cqw, 1.15rem);
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-progress-layer--activity_calendar .task-progress-title {
  font-size: 0.92rem;
  font-weight: 600;
  text-align: center;
}

.task-progress-workspace-open {
  appearance: none;
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  font: inherit;
}

.task-progress-workspace-task--editable {
  cursor: pointer;
}

.task-progress-month-button,
.task-progress-create,
.task-progress-task,
.task-progress-day,
.task-progress-dialog-close,
.task-progress-chooser-button,
.task-progress-detail-edit,
.task-progress-detail-delete,
.task-progress-retry {
  border: 0;
  color: inherit;
  font: inherit;
  cursor: pointer;
}

.task-progress-month-button,
.task-progress-create,
.task-progress-dialog-close,
.task-progress-detail-edit,
.task-progress-detail-delete,
.task-progress-retry {
  min-height: 34px;
  border: 1px solid var(--container-border-color, #d9d7df);
  border-radius: 9px;
  background: var(--container-bg-color, #fff);
}

.task-progress-month-button {
  appearance: none;
  width: 28px;
  min-width: 28px;
  min-height: 28px;
  border: 0;
  border-radius: 4px;
  padding: 0;
  background: transparent;
  font-size: 1rem;
  line-height: 1;
}

.task-progress-month-button:hover,
.task-progress-month-button:focus-visible {
  background: rgb(from var(--primary-color) r g b / 10%);
}

.task-progress-create,
.task-progress-detail-edit,
.task-progress-detail-delete,
.task-progress-retry {
  padding: 6px 11px;
  white-space: nowrap;
}

.task-progress-actions {
  justify-content: flex-end;
}

[data-task-mutation-busy="1"] {
  cursor: progress;
}

[data-task-mutation-busy="1"] [data-task-progress-todo]:disabled,
[data-task-mutation-busy="1"] [data-task-delete]:disabled,
[data-task-mutation-busy="1"] .task-progress-editor[aria-busy="true"] {
  opacity: 0.65;
}

.task-progress-calendar {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  grid-template-rows: minmax(18px, auto) repeat(6, minmax(0, 1fr));
  grid-auto-rows: minmax(0, 1fr);
  min-width: 0;
  min-height: 0;
  flex: 1 1 0;
  height: auto;
  gap: 1px;
}

.task-progress-weekday {
  align-self: center;
  min-width: 0;
  overflow: hidden;
  color: var(--text-muted, #787580);
  padding: 3px 2px;
  font-size: 11px;
  font-weight: 700;
  text-align: center;
}

.task-progress-day {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  appearance: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 0;
  min-height: 0;
  gap: 2px;
  padding: 2px 1px;
  border: 0;
  border-radius: 4px;
  background: var(--container-bg-color);
  color: var(--content-font-color);
  font-size: 11px;
}

.task-progress-day-gradient,
.tp-v2-day-gradient {
  position: absolute;
  z-index: 0;
  inset: -10%;
  filter: blur(5px);
  transform: scale(1.08);
  opacity: .78;
}

.task-progress-day-number,
.task-progress-day-activity,
.tp-v2-day > span,
.tp-v2-day > small {
  position: relative;
  z-index: 1;
}

.task-progress-day:hover,
.task-progress-day:focus-visible,
.task-progress-task:hover,
.task-progress-task:focus-visible,
.task-progress-chooser-button:hover,
.task-progress-chooser-button:focus-visible {
  background: color-mix(in srgb, var(--accent-color, #7656c8) 10%, transparent);
}

.task-progress-day--today {
  background: var(--accent-color);
  color: var(--white, #fff);
  font-weight: 700;
  box-shadow: 0 2px 4px rgb(from var(--accent-color) r g b / 30%);
}

.task-progress-day--empty {
  pointer-events: none;
}

.task-progress-day-activity {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  gap: 2px;
}

.task-progress-dot {
  display: inline-block;
  flex: 0 0 4px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #7656c8;
}

.task-progress-day-activity .task-progress-dot,
.task-progress-workspace-dots .task-progress-dot {
  flex-basis: 7px;
  width: 7px;
  height: 7px;
}

.task-progress-dot--rose,
.task-progress-bar-fill--rose { background: #d85c78; }
.task-progress-dot--coral,
.task-progress-bar-fill--coral { background: #e8736f; }
.task-progress-dot--purple,
.task-progress-bar-fill--purple { background: #7656c8; }
.task-progress-dot--blue,
.task-progress-bar-fill--blue { background: #3978c5; }
.task-progress-dot--teal,
.task-progress-bar-fill--teal { background: #238c8c; }
.task-progress-dot--green,
.task-progress-bar-fill--green { background: #4b8b51; }
.task-progress-dot--yellow,
.task-progress-bar-fill--yellow { background: #c69422; }
.task-progress-dot--orange,
.task-progress-bar-fill--orange { background: #d06b2c; }
.task-progress-dot--amber,
.task-progress-bar-fill--amber { background: #dfa52b; }
.task-progress-dot--lime,
.task-progress-bar-fill--lime { background: #86a83f; }
.task-progress-dot--mint,
.task-progress-bar-fill--mint { background: #47a27b; }
.task-progress-dot--cyan,
.task-progress-bar-fill--cyan { background: #38a5bc; }
.task-progress-dot--indigo,
.task-progress-bar-fill--indigo { background: #5367c7; }
.task-progress-dot--lavender,
.task-progress-bar-fill--lavender { background: #9a78d3; }
.task-progress-dot--brown,
.task-progress-bar-fill--brown { background: #916b52; }
.task-progress-dot--gray,
.task-progress-bar-fill--gray { background: #777983; }

.task-progress-more {
  min-width: 0;
  color: var(--text-muted, #787580);
  font-size: 0.62rem;
  white-space: nowrap;
}

.task-progress-list,
.task-progress-chooser-list,
.task-progress-detail-todos {
  margin: 0;
  padding: 0;
  list-style: none;
}

.task-progress-list {
  display: grid;
  min-width: 0;
  gap: 6px;
}

.task-progress-task {
  display: grid;
  width: 100%;
  min-width: 0;
  gap: 6px;
  padding: 8px;
  border-radius: 10px;
  background: transparent;
  text-align: left;
}

.task-progress-task-heading {
  gap: 7px;
}

.task-progress-task-title,
.task-progress-chooser-title {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-progress-task-title {
  flex: 1 1 auto;
}

.task-progress-percent,
.task-progress-count,
.task-progress-private {
  flex: 0 0 auto;
  color: var(--text-muted, #787580);
  font-size: 0.75rem;
}

.task-progress-count {
  text-align: right;
}

.task-progress-bar {
  display: block;
  width: 100%;
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--container-border-color, #dedce3);
}

.task-progress-bar-fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  transition: width 160ms ease;
}

.task-progress-empty,
.task-progress-layer-message {
  margin: auto 0;
  color: var(--text-muted, #787580);
  text-align: center;
}

.task-progress-layer-message {
  margin: 0;
  padding: 5px;
  font-size: 0.75rem;
}

.task-progress-dialog-open {
  overflow: hidden;
}

.task-progress-dialog-backdrop {
  position: fixed;
  z-index: 100000;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  max-width: 100vw;
  overflow: hidden;
  background: rgb(20 18 28 / 42%);
}

.task-progress-dialog-backdrop[hidden] {
  display: none;
}

.task-progress-dialog-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  width: min(520px, calc(100vw - 80px));
  max-width: 100%;
  height: auto;
  max-height: min(660px, calc(100dvh - 80px));
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--container-border-color, #dedce3);
  border-radius: 16px;
  background: var(--container-bg-color, #fff);
  color: var(--content-font-color, #24232b);
  box-shadow: 0 18px 48px rgb(20 18 28 / 22%);
  font-family: var(--content-font-family, inherit);
}

.task-progress-dialog-backdrop--workspace .task-progress-dialog-panel {
  width: min(880px, calc(100vw - 80px));
  height: min(660px, calc(100dvh - 80px));
}

.task-progress-dialog-actions {
  display: flex;
  align-items: center;
}

.task-progress-popout {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  margin-right: 8px;
  border: 1px solid var(--container-border-color, #dedce3);
  border-radius: 9px;
  background: var(--container-bg-color, #fff);
  color: inherit;
  font-size: 1.1rem;
  cursor: pointer;
}

.task-progress-popup-mode {
  margin: 0;
  overflow: hidden;
  background: transparent;
}

.task-progress-popup-mode > :not([data-task-progress-dialog]) {
  display: none !important;
}

.task-progress-popup-mode .task-progress-dialog-backdrop {
  padding: 0;
  background: transparent;
}

.task-progress-popup-mode .task-progress-dialog-backdrop--workspace .task-progress-dialog-panel {
  width: 100vw !important;
  max-width: none !important;
  height: 100dvh !important;
  max-height: none !important;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.task-progress-popup-mode .tp-v2-workspace {
  width: min(880px,calc(100vw - 40px));
  margin: 0 auto;
  padding: 20px 0 28px;
}

.task-progress-workspace-create {
  width: 36px;
  height: 36px;
  border: 1px solid var(--container-border-color, #dedce3);
  border-radius: 9px;
  background: var(--container-bg-color, #fff);
  color: inherit;
  font-size: 1.35rem;
  cursor: pointer;
}

.task-progress-workspace {
  display: grid;
  grid-template-columns: minmax(300px, 0.82fr) minmax(360px, 1.18fr);
  min-height: 560px;
  gap: 22px;
}

.task-progress-workspace-calendar,
.task-progress-workspace-list {
  min-width: 0;
}

.task-progress-workspace-calendar > header {
  display: grid;
  grid-template-columns: 36px 1fr 36px;
  align-items: center;
  margin-bottom: 10px;
  text-align: center;
}

.task-progress-workspace-calendar > header button,
.task-progress-workspace-day {
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
}

.task-progress-workspace-calendar > header button {
  height: 36px;
  border-radius: 8px;
  font-size: 1.2rem;
}

.task-progress-workspace-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  grid-template-rows: 24px repeat(6, minmax(44px, 1fr));
  gap: 4px;
}

.task-progress-workspace-weekday {
  align-self: center;
  color: var(--text-muted, #787580);
  font-size: 0.72rem;
  text-align: center;
}

.task-progress-workspace-day {
  display: grid;
  place-items: center;
  min-width: 0;
  min-height: 44px;
  border-radius: 10px;
}

.task-progress-workspace-day:hover,
.task-progress-workspace-day:focus-visible {
  background: color-mix(in srgb, var(--accent-color, #7656c8) 10%, transparent);
}

.task-progress-workspace-day--selected {
  background: var(--accent-color, #7656c8);
  color: #fff;
  font-weight: 700;
}

.task-progress-workspace-dots {
  display: flex;
  min-height: 4px;
  gap: 2px;
}

.task-progress-workspace-list > h3,
.task-progress-workspace-completed-section h4 {
  margin: 0 0 12px;
}

.task-progress-workspace-task {
  margin-bottom: 12px;
  padding: 15px 16px 16px;
  border: 1px solid var(--container-border-color, #dedce3);
  border-radius: 14px;
  background: var(--container-bg-color, #fff);
  box-shadow: 0 3px 12px rgb(20 18 28 / 4%);
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.task-progress-workspace-task--editable {
  cursor: pointer;
}

.task-progress-workspace-task--editable:hover,
.task-progress-workspace-task--editable:focus-within {
  border-color: color-mix(in srgb, var(--text-color, #34313b) 32%, var(--container-border-color, #dedce3));
  box-shadow: 0 7px 20px rgb(20 18 28 / 8%);
  transform: translateY(-1px);
}

.task-progress-workspace-task--highlighted {
  border-color: color-mix(in srgb, var(--text-color, #34313b) 42%, var(--container-border-color, #dedce3));
  box-shadow: 0 0 0 2px rgb(20 18 28 / 7%);
}

.task-progress-workspace-task-header,
.task-progress-workspace-task-title,
.task-progress-workspace-task-actions {
  display: flex;
  align-items: center;
}

.task-progress-workspace-task-header {
  min-width: 0;
  gap: 8px;
  margin-bottom: 12px;
}

.task-progress-workspace-task-title {
  flex: 1 1 auto;
  width: 100%;
  min-width: 0;
  gap: 8px;
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
  font-size: 0.98rem;
  font-weight: 700;
}

.task-progress-workspace-task-title strong {
  margin-left: auto;
  color: inherit;
  font-size: 1.02rem;
  font-variant-numeric: tabular-nums;
}

.task-progress-workspace-task-actions {
  flex: 0 0 auto;
  gap: 5px;
}

.task-progress-workspace-task-actions button {
  display: grid;
  width: 28px;
  min-height: 28px;
  place-items: center;
  border: 0;
  border-radius: 50%;
  padding: 0;
  background: transparent;
  color: #c83b4d;
  font: inherit;
  font-size: 1.05rem;
  line-height: 1;
  cursor: pointer;
}

.task-progress-workspace-task-actions .task-progress-workspace-delete {
  color: #c83b4d;
}

.task-progress-workspace-task-actions button:hover {
  background: rgb(200 59 77 / 8%);
}

.task-progress-workspace-task > .task-progress-bar {
  height: 9px;
  margin-bottom: 13px;
  background: color-mix(in srgb, var(--task-color, #7656c8) 9%, var(--container-border-color, #dedce3));
}

.task-progress-workspace-task-title .task-progress-dot {
  flex-basis: 10px;
  width: 10px;
  height: 10px;
}

.task-progress-workspace-task > .task-progress-bar .task-progress-bar-fill {
  background: var(--task-color, #7656c8);
}

.task-progress-workspace-todos,
.task-progress-workspace-completed {
  display: grid;
  gap: 7px;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
}

.task-progress-workspace-todos li,
.task-progress-workspace-completed li {
  display: flex;
  align-items: flex-start;
  min-width: 0;
  gap: 8px;
}

.task-progress-workspace-todos li {
  align-items: center;
  min-height: 28px;
  gap: 10px;
  line-height: 1.45;
}

.task-progress-workspace-todos input[type="checkbox"] {
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  margin: 0;
  appearance: none;
  border: 2px solid var(--task-color, #7656c8);
  border-radius: 4px;
  background: transparent;
  cursor: pointer;
}

.task-progress-workspace-todos input[type="checkbox"]:checked {
  background: var(--task-color, #7656c8);
}

.task-progress-workspace-todos input[type="checkbox"]:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--task-color, #7656c8) 40%, transparent);
  outline-offset: 2px;
}

.task-progress-workspace-completed li {
  align-items: center;
}

.task-progress-workspace-completed .task-progress-dot {
  flex-basis: 9px;
  width: 9px;
  height: 9px;
}

.task-progress-workspace-completed li > span:nth-child(2) {
  flex: 1 1 auto;
  min-width: 0;
}

.task-progress-workspace-completed-delete {
  flex: 0 0 auto;
  display: grid;
  width: 28px;
  min-height: 28px;
  place-items: center;
  border: 0;
  border-radius: 50%;
  padding: 0;
  background: transparent;
  color: #c83b4d;
  font: inherit;
  font-size: 1.05rem;
  line-height: 1;
  cursor: pointer;
}

.task-progress-workspace-completed-delete:hover {
  background: rgb(200 59 77 / 8%);
}

.task-progress-workspace-todos .is-completed,
.task-progress-workspace-todos input:checked + span {
  color: var(--text-muted, #787580);
  text-decoration: line-through;
}

.task-progress-workspace-completed-section {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--container-border-color, #dedce3);
}

.task-progress-workspace-empty {
  color: var(--text-muted, #787580);
  font-size: 0.86rem;
}

.task-progress-dialog-header {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 12px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--container-border-color, #dedce3);
}

.task-progress-dialog-title {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
  overflow: hidden;
  font-size: 1.2rem;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-progress-dialog-close {
  flex: 0 0 36px;
  width: 36px;
  padding: 0;
  font-size: 1.4rem;
}

.task-progress-dialog-close[hidden] {
  display: none;
}

.task-progress-dialog-back {
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid var(--container-border-color, #dedce3);
  border-radius: 9px;
  background: var(--container-bg-color, #fff);
  color: inherit;
  font: inherit;
  font-size: 1.15rem;
  cursor: pointer;
}

.task-progress-dialog-back[hidden] {
  display: none;
}

.task-progress-dialog-message {
  min-height: 0;
  padding: 0 20px;
  color: var(--text-muted, #787580);
  font-size: 0.82rem;
}

.task-progress-dialog-message:not(:empty) {
  padding-top: 10px;
}

.task-progress-dialog-message--error {
  color: #b23b45;
}

.task-progress-dialog-body {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 0;
  padding: 20px;
  overflow-x: hidden;
  overflow-y: auto;
}

.task-progress-loading,
.task-progress-detail-error,
.task-progress-detail-empty,
.task-progress-chooser-intro {
  color: var(--text-muted, #787580);
}

.task-progress-chooser-list {
  display: grid;
  gap: 8px;
}

.task-progress-chooser-button {
  display: flex;
  align-items: center;
  width: 100%;
  min-width: 0;
  gap: 10px;
  padding: 12px;
  border-radius: 10px;
  background: transparent;
  text-align: left;
}

.task-progress-detail-heading {
  min-height: 34px;
  gap: 8px;
}

.task-progress-detail-heading .task-progress-detail-edit {
  margin-left: auto;
}

.task-progress-detail-delete {
  padding: 6px 11px;
  border-color: color-mix(in srgb, #b23b45 45%, var(--container-border-color, #d9d7df));
  color: #b23b45;
  white-space: nowrap;
}

.task-progress-detail-private {
  padding: 3px 7px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent-color, #7656c8) 12%, transparent);
  color: var(--text-muted, #787580);
  font-size: 0.75rem;
}

.task-progress-detail-dates {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 16px 0;
}

.task-progress-detail-date {
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--container-border-color, #dedce3);
  border-radius: 10px;
}

.task-progress-detail-date dt {
  margin-bottom: 3px;
  color: var(--text-muted, #787580);
  font-size: 0.75rem;
}

.task-progress-detail-date dd {
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-progress-detail-progress {
  display: grid;
  gap: 7px;
}

.task-progress-detail-progress-text {
  justify-content: space-between;
  font-size: 0.85rem;
}

.task-progress-detail-todo-section {
  margin-top: 24px;
}

.task-progress-detail-subtitle {
  margin: 0 0 10px;
  font-size: 0.95rem;
}

.task-progress-detail-todos {
  display: grid;
  gap: 4px;
}

.task-progress-detail-todo,
.task-progress-detail-todo-label {
  display: flex;
  align-items: flex-start;
  min-width: 0;
  gap: 9px;
}

.task-progress-detail-todo {
  padding: 9px 4px;
  border-bottom: 1px solid color-mix(in srgb, var(--container-border-color, #dedce3) 70%, transparent);
}

.task-progress-detail-todo-label {
  width: 100%;
  cursor: pointer;
}

.task-progress-detail-checkbox {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  margin: 1px 0 0;
  accent-color: var(--accent-color, #7656c8);
}

.task-progress-detail-todo-content {
  min-width: 0;
  overflow-wrap: anywhere;
}

.task-progress-detail-todo--completed .task-progress-detail-todo-content {
  color: var(--text-muted, #787580);
  text-decoration: line-through;
}

.task-progress-detail-status {
  flex: 0 0 18px;
  color: var(--accent-color, #7656c8);
  text-align: center;
}

.task-progress-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.task-progress-editor {
  display: grid;
  gap: 18px;
}

.task-progress-editor[aria-busy="true"] {
  cursor: wait;
}

.task-progress-editor[aria-busy="true"] button:disabled,
.task-progress-dialog-close:disabled {
  opacity: 0.55;
  cursor: wait;
}

.task-progress-editor-field {
  display: grid;
  min-width: 0;
  gap: 6px;
}

.task-progress-editor-field label,
.task-progress-editor-label,
.task-progress-editor-colors legend {
  color: var(--text-muted, #787580);
  font-size: 0.78rem;
  font-weight: 700;
}

.task-progress-editor input[type="text"],
.task-progress-editor select,
.task-progress-editor-date-control > button,
.task-progress-editor-actions button,
.task-progress-editor-todo-heading button,
.task-progress-editor-todo-actions button,
.task-progress-date-picker button {
  border: 1px solid var(--container-border-color, #dedce3);
  color: inherit;
  font: inherit;
}

.task-progress-editor input[type="text"],
.task-progress-editor select {
  width: 100%;
  min-height: 40px;
  padding: 8px 10px;
  border-radius: 9px;
  background: var(--container-bg-color, #fff);
}

.task-progress-editor-date-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.task-progress-editor-date-control {
  display: flex;
  min-width: 0;
  gap: 5px;
}

.task-progress-editor-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.task-progress-editor-private {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.82rem;
  font-weight: 500 !important;
  white-space: nowrap;
}

.task-progress-editor-date-control > input {
  flex: 1 1 auto;
  min-width: 0;
}

.task-progress-editor-date-control > button {
  min-height: 40px;
  padding: 7px 9px;
  border-radius: 9px;
  background: var(--container-bg-color, #fff);
  cursor: pointer;
}

.task-progress-editor-date-control > [data-task-date-field] {
  flex: 0 0 40px;
}

.task-progress-editor-date-control > [data-task-date-clear] {
  flex: 0 0 auto;
  color: var(--text-muted, #787580);
  font-size: 0.75rem;
}

.task-progress-editor-error {
  min-height: 1em;
  margin: 0;
  color: #b23b45;
  font-size: 0.75rem;
}

.task-progress-editor-colors {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  border: 0;
}

.task-progress-editor-colors legend {
  width: 100%;
  margin-bottom: 2px;
}

.task-progress-editor-color {
  position: relative;
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--container-border-color, #dedce3);
  border-radius: 50%;
  cursor: pointer;
}

.task-progress-editor-color input {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}

.task-progress-editor-color .task-progress-dot {
  width: 16px;
  height: 16px;
}

.task-progress-editor-color:has(input:checked) {
  border-color: var(--accent-color, #7656c8);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent-color, #7656c8) 20%, transparent);
}

.task-progress-editor-todo-section {
  display: grid;
  gap: 8px;
}

.task-progress-editor-todo-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.task-progress-editor-todo-heading h3 {
  margin: 0;
  font-size: 0.95rem;
}

.task-progress-editor-todo-heading button,
.task-progress-editor-todo-actions button {
  min-width: 32px;
  min-height: 32px;
  border-radius: 8px;
  background: var(--container-bg-color, #fff);
  cursor: pointer;
}

.task-progress-editor-todos {
  display: grid;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.task-progress-editor-todo {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 7px;
}

.task-progress-editor-todo-check {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--accent-color, #7656c8);
}

.task-progress-editor-todo-actions {
  display: flex;
  gap: 3px;
}

.task-progress-editor-todo-actions button:disabled {
  opacity: 0.35;
  cursor: default;
}

.task-progress-editor-actions {
  position: sticky;
  bottom: -20px;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin: 4px -20px -20px;
  padding: 14px 20px 20px;
  border-top: 1px solid var(--container-border-color, #dedce3);
  background: var(--container-bg-color, #fff);
}

.task-progress-editor-actions button {
  min-height: 40px;
  padding: 8px 16px;
  border-radius: 9px;
  background: var(--container-bg-color, #fff);
  cursor: pointer;
}

.task-progress-editor-actions .task-progress-editor-submit {
  border-color: var(--accent-color, #7656c8);
  background: var(--accent-color, #7656c8);
  color: #fff;
}

.task-progress-editor-actions .task-progress-detail-delete {
  margin-right: auto;
}

.task-progress-date-picker {
  position: fixed;
  z-index: 100002;
  width: 280px;
  margin: 0;
  padding: 12px;
  border: 1px solid var(--container-border-color, #dedce3);
  border-radius: 12px;
  background: var(--container-bg-color, #fff);
  box-shadow: 0 12px 30px rgb(20 18 28 / 12%);
}

.task-progress-date-picker[hidden] {
  display: none;
}

.task-progress-date-picker-header {
  display: grid;
  grid-template-columns: 36px 1fr 36px;
  align-items: center;
  gap: 8px;
  text-align: center;
}

.task-progress-date-picker-header button,
.task-progress-date-picker-today {
  min-height: 34px;
  border-radius: 8px;
  background: var(--container-bg-color, #fff);
  cursor: pointer;
}

.task-progress-date-picker-hint {
  margin: 9px 0 2px;
  color: var(--text-muted, #787580);
  font-size: 0.72rem;
  line-height: 1.4;
  text-align: center;
}

.task-progress-date-picker-hint > span {
  display: block;
}

.task-progress-date-picker-today {
  display: block;
  margin: 8px 0 10px auto;
  padding: 4px 12px;
}

.task-progress-date-picker-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 3px;
}

.task-progress-date-picker-weekday {
  padding: 5px 0;
  color: var(--text-muted, #787580);
  font-size: 0.72rem;
  text-align: center;
}

.task-progress-date-picker-empty,
.task-progress-date-picker-day {
  height: 30px;
}

.task-progress-date-picker-day {
  min-width: 0;
  border-color: transparent !important;
  border-radius: 8px;
  background: transparent;
  font-size: 0.78rem;
  cursor: pointer;
}

.task-progress-date-picker-day--range {
  background: color-mix(in srgb, var(--accent-color, #7656c8) 13%, transparent);
}

.task-progress-date-picker-day--start,
.task-progress-date-picker-day--target {
  background: var(--accent-color, #7656c8);
  color: #fff;
  font-weight: 700;
}

.task-progress-date-picker-day--today:not(.task-progress-date-picker-day--start):not(.task-progress-date-picker-day--target) {
  box-shadow: inset 0 0 0 2px var(--accent-color, #7656c8);
}

.task-progress-date-picker-day:disabled {
  color: var(--text-muted, #787580);
  opacity: 0.35;
  cursor: not-allowed;
}

.task-progress-month-button:focus-visible,
.task-progress-create:focus-visible,
.task-progress-task:focus-visible,
.task-progress-day:focus-visible,
.task-progress-dialog-close:focus-visible,
.task-progress-chooser-button:focus-visible,
.task-progress-detail-edit:focus-visible,
.task-progress-detail-delete:focus-visible,
.task-progress-workspace-completed-delete:focus-visible,
.task-progress-retry:focus-visible,
.task-progress-detail-checkbox:focus-visible,
.task-progress-dialog-title:focus-visible,
.task-progress-editor button:focus-visible,
.task-progress-editor input:focus-visible,
.task-progress-editor select:focus-visible,
.task-progress-date-picker button:focus-visible {
  outline: 2px solid var(--accent-color, #7656c8);
  outline-offset: 2px;
}

@media (min-width: 768px) and (max-width: 1023px) {
  .task-progress-dialog-backdrop {
    padding: 16px;
  }

  .task-progress-dialog-panel {
    width: min(520px, calc(100vw - 32px));
    max-height: min(660px, calc(100dvh - 32px));
  }

  .task-progress-dialog-backdrop--workspace .task-progress-dialog-panel {
    width: min(880px, calc(100vw - 32px));
    height: min(660px, calc(100dvh - 32px));
  }
}

@media (max-width: 767px) {
  .task-progress-dialog-backdrop {
    align-items: flex-end;
    padding: 0;
  }

  .task-progress-dialog-panel {
    width: 100%;
    height: auto;
    max-height: 84dvh;
    border-top: 1px solid var(--container-border-color, #dedce3);
    border-left: 0;
    border-radius: 18px 18px 0 0;
    box-shadow: 0 -16px 40px rgb(20 18 28 / 18%);
  }

  .task-progress-dialog-backdrop--workspace .task-progress-dialog-panel {
    width: 100%;
    height: min(88dvh, 760px);
    max-height: 88dvh;
  }

  .task-progress-workspace {
    grid-template-columns: minmax(0, 1fr);
    min-height: 0;
    gap: 24px;
  }

  .task-progress-workspace-grid {
    grid-template-rows: 22px repeat(6, 40px);
  }

  .task-progress-workspace-day {
    min-height: 40px;
  }

  .task-progress-workspace-task {
    padding: 14px 15px 15px;
  }

  .task-progress-dialog-header {
    padding: 14px 16px;
  }

  .task-progress-dialog-body {
    padding: 16px;
    padding-bottom: max(20px, env(safe-area-inset-bottom));
  }

  .task-progress-dialog-message {
    padding-right: 16px;
    padding-left: 16px;
  }

  .task-progress-editor-actions {
    bottom: -16px;
    margin-right: -16px;
    margin-bottom: -16px;
    margin-left: -16px;
    padding-right: 16px;
    padding-bottom: max(20px, env(safe-area-inset-bottom));
    padding-left: 16px;
  }
}

@media (max-width: 359px) {
  .task-progress-layer {
    padding: 8px;
  }

  .task-progress-calendar {
    gap: 1px;
  }

  .task-progress-day {
    min-height: 30px;
  }

  .task-progress-detail-dates {
    grid-template-columns: 1fr;
  }

  .task-progress-editor-date-fields {
    grid-template-columns: 1fr;
  }

  .task-progress-editor-todo {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .task-progress-editor-todo-actions {
    grid-column: 2;
    justify-content: flex-end;
  }
}

@media (prefers-reduced-motion: reduce) {
  .task-progress-bar-fill {
    transition: none;
  }
}

/* Keep category and task add controls at the same approved geometry. */
.tp-v2-plus{width:24px!important;height:24px!important;font-size:0!important;font-weight:400}
.tp-v2-category--flat .tp-v2-todo{grid-template-columns:26px minmax(0,1fr) 24px 24px}
.tp-v2-title-tools .tp-v2-subtodo-count{flex:0 0 auto;grid-column:auto}
.tp-v2-todo>.tp-timer-open{grid-column:3}.tp-v2-todo>.tp-v2-row-delete{grid-column:4}
.tp-v2-columns{grid-template-columns:minmax(0,44fr) minmax(0,56fr)}
.task-progress-popup-mode .task-progress-dialog-body:has(.tp-v2-theme--gray){background:#eef0f3}

/* Timer entry buttons occupy stable row slots without changing the existing add/delete order. */
.tp-v2-subtodo{grid-template-columns:24px minmax(0,1fr) 24px 24px}
.tp-v2-category-timer-total{color:#788294;font-size:12px;font-weight:600;font-variant-numeric:tabular-nums;white-space:nowrap}
