/* Compact task surface. Brand tokens and the existing icon family are reused. */
.modal:has(.task-create-modal){align-items:center;padding:24px;background:rgba(25,32,20,.28);backdrop-filter:blur(3px)}
.modal #modalForm.task-create-modal{width:min(680px,calc(100vw - 48px));max-width:100%;min-width:0;max-height:calc(100dvh - 48px);height:auto;border-radius:18px;overflow:auto;position:relative}
.modal #modalForm.task-create-modal>header{border:0;padding:0!important;min-height:0}
.task-create-modal>header>div{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
.task-create-modal>header>button{position:absolute;right:16px;top:20px;width:32px;height:32px;z-index:1}
.task-create-modal #modalBody{min-width:0;background:#fff;padding:28px 28px 12px;overflow:visible}
.task-composer{font-size:14px;line-height:1.5;display:grid;gap:16px;min-width:0}
.task-composer input,.task-composer textarea,.task-composer select,.task-composer button{font:inherit;box-sizing:border-box}
.task-composer .task-composer-title{font-size:var(--workspace-title-size,24px);font-weight:700;border:1px solid transparent;border-radius:7px;padding:6px 8px;margin-right:28px;width:calc(100% - 28px);min-height:42px;background:transparent}
.task-composer-title:focus{border-color:var(--accent);outline:2px solid var(--accent-soft);outline-offset:1px;box-shadow:none}
.task-composer .task-composer-description{width:100%;min-height:50px;max-height:180px;resize:vertical;border:1px solid transparent;padding:6px 8px;border-radius:7px;background:transparent;font-weight:400}
.task-composer-row{display:grid;grid-template-columns:160px minmax(0,1fr);gap:16px;align-items:center;min-height:40px;padding-inline:8px}
.task-composer-row>span:first-child,.task-composer-row>label{color:var(--muted);font-size:14px}
.task-composer-row select{min-height:38px;width:100%;border:1px solid var(--line);border-radius:8px;background:var(--surface,#fff);padding:8px}
.task-composer-relation{display:inline-flex;align-items:center;min-width:0;max-width:100%;gap:2px}
.task-composer-relation>button{display:inline-flex;align-items:center;gap:8px;border:0;background:transparent;color:var(--text);border-radius:8px;min-height:38px;padding:6px 8px;min-width:0;max-width:100%;cursor:pointer}
.task-composer-relation>button:hover{background:var(--accent-soft,#f2f7e5)}
.task-composer-relation>button>span{overflow-wrap:anywhere;text-align:left}
.task-composer img,.task-date-dialog img{width:18px;height:18px;flex-shrink:0}
.task-composer-relation [data-task-clear]{padding:5px;min-height:30px}
.task-composer-relation [data-task-clear] img{width:12px;height:12px}
.task-composer-deadline{display:flex;align-items:center;gap:4px;min-width:0}
.task-composer-deadline input{width:100%;min-width:0;border:1px solid transparent;border-radius:8px;background:transparent;padding:7px 8px;min-height:38px}
.task-composer-deadline input:focus,.task-composer-description:focus{border-color:var(--accent);outline:1px solid var(--accent);box-shadow:none}
.task-composer-deadline>button{border:0;background:transparent;width:34px;height:34px;flex-shrink:0;cursor:pointer}
.task-composer-links{display:flex;gap:6px;flex-wrap:wrap;border-top:1px solid var(--line);padding-top:16px}
.task-composer-links>.task-composer-relation{border:1px solid var(--line);border-radius:8px}
.task-composer-context{border-top:1px solid var(--line);padding-top:8px}
.task-composer-context>summary{cursor:pointer;padding:6px 8px;color:var(--muted);font-size:var(--type-body,14px)}
.task-composer-context .task-composer-links{border:0;padding-top:8px}
.task-composer-more{border:0;color:var(--muted)}
.task-composer-more>summary{cursor:pointer;padding:6px 8px;font-size:13px}
.task-composer-extras{display:grid;gap:16px;padding-top:14px;color:var(--text)}
.task-composer-extras>label{display:grid;gap:6px;font-size:13px;margin:0}
.task-composer-extras textarea{width:100%;min-height:65px;border:1px solid var(--line);border-radius:8px;padding:10px}
.task-composer-extras .linked-council-field{margin:0;padding:0;border:0;background:transparent}
.modal #modalForm.task-create-modal>footer{display:flex;gap:12px;align-items:center;border:0;padding:8px 28px 24px!important}
.task-create-modal>footer button{font-size:14px;min-height:40px;border-radius:9px;padding:9px 18px}
.task-create-modal #modalError:not(:empty){padding:0 28px;font-size:13px}
.entity-workspace-layer.entity-picker-layer{inset:0;animation:none;background:#fff;width:640px;max-width:calc(100vw - 32px);height:fit-content;max-height:calc(100dvh - 48px);margin:auto;border-radius:16px}
.entity-picker-layer .entity-layer-content{min-height:0;padding:18px;max-height:65dvh;overflow:auto}
.entity-picker-layer .entity-layer-bar{min-height:44px;padding:8px 16px}
.entity-picker-layer .entity-layer-bar>button:first-child{display:none}
.entity-picker-layer .entity-directory{max-width:none;margin:0}
.entity-picker-layer .entity-directory>header h2{display:none}
.entity-picker-layer .entity-directory-results{max-height:40dvh;overflow:auto}
.entity-picker-layer .entity-directory-pick{padding:12px;text-align:left}
.entity-picker-layer .entity-directory-pick b{font-size:14px;font-weight:500}
.entity-picker-layer .entity-directory-pick small{font-size:12px}
.entity-modal-snapshot{pointer-events:none!important;z-index:70!important}
.entity-modal-snapshot input:disabled,.entity-modal-snapshot textarea:disabled,.entity-modal-snapshot button:disabled{opacity:1;color:inherit;-webkit-text-fill-color:inherit}
.task-date-dialog{border:1px solid var(--line);border-radius:16px;padding:20px;width:500px;max-width:calc(100vw - 24px);background:#fff;color:var(--text);box-shadow:0 12px 50px #0002}
.task-date-dialog::backdrop{background:rgba(0,0,0,.08)}
.task-date-dialog header{display:flex;align-items:center;gap:8px;margin-bottom:15px}
.task-date-dialog header b{flex:1;text-align:center;font-size:15px;font-weight:500}
.task-date-dialog button{cursor:pointer;font:inherit;background:transparent;border:0;border-radius:8px;color:inherit;min-width:32px;min-height:34px}
.task-date-dialog button:hover{background:var(--accent-soft,#f2f7e5)}
.task-date-body{display:grid;grid-template-columns:minmax(0,1fr) 135px;gap:20px}
.task-date-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:3px;text-align:center;font-size:13px}
.task-date-grid>span{color:var(--muted);padding-bottom:8px}
.task-date-grid .adjacent{color:var(--muted);opacity:.55}
.task-date-grid .selected{background:var(--accent);color:#fff}
.task-date-shortcuts{display:grid;align-content:start;gap:8px}
.task-date-shortcuts button{border:1px solid var(--line);text-align:left;padding:8px;font-size:13px}
.task-date-time{display:flex;gap:10px;align-items:center;font-size:13px;margin-top:12px}
.task-date-time input{font:inherit;max-width:115px;border:1px solid var(--line);border-radius:6px;padding:6px}
@media(max-width:600px){.modal:has(.task-create-modal){padding:12px}.modal form.task-create-modal{max-height:calc(100dvh - 24px)}.task-create-modal #modalBody{padding:24px 16px 12px}.task-composer-row{grid-template-columns:105px minmax(0,1fr);gap:6px;padding:0}.task-composer .task-composer-title{font-size:20px}.task-create-modal>footer{padding:10px 16px 20px}.task-date-body{grid-template-columns:1fr}.task-date-shortcuts{grid-template-columns:1fr 1fr}.entity-picker-layer .entity-layer-content{padding:12px}}

.task-composer-deadline input::-webkit-calendar-picker-indicator{display:none}

.entity-picker-layer .entity-layer-content{min-height:0!important}
.modal #modalForm.task-create-modal #modalBody{background:#fff}

.task-composer-row>label{margin:0!important}
.task-composer-deadline>button{order:-1}

.task-date-shortcuts small{display:block;margin-top:3px;font-size:11px;color:var(--muted)}
