/* Darbalreef Task UI — reference implementation 2026-09-03 */
:root{--tr-ink:#0f172a;--tr-muted:#667085;--tr-line:#e4e7ec;--tr-soft:#f8fafc;--tr-primary:#3157ff;--tr-primary2:#5b5cff;--tr-danger:#ef3340;--tr-orange:#f97316;--tr-amber:#e5a000;--tr-green:#16a34a;--tr-blue:#2563eb;--tr-radius:16px;--tr-shadow:0 16px 50px rgba(15,23,42,.13)}
.task-ref-create{--bs-offcanvas-width:min(1040px,calc(100vw - 32px));top:50%!important;left:50%!important;right:auto!important;bottom:auto!important;width:var(--bs-offcanvas-width)!important;height:min(94vh,1080px)!important;border:1px solid #dde3ee!important;border-radius:20px!important;background:#fff!important;box-shadow:var(--tr-shadow)!important;overflow:hidden!important;transform:translate(calc(-50% + 120vw),-50%)!important;transition:transform .28s ease!important}
.task-ref-create.show,.task-ref-create.showing{transform:translate(-50%,-50%)!important}.task-ref-create.hiding{transform:translate(calc(-50% + 120vw),-50%)!important}
.task-ref-create-form{height:100%;display:flex;flex-direction:column;background:#fff}.task-ref-create-header{display:grid;grid-template-columns:58px 58px 1fr auto;align-items:center;gap:14px;padding:28px 30px;border-bottom:1px solid #eef1f5;background:linear-gradient(100deg,#f8fbff 0%,#fff 48%,#fdf8ff 100%)}
.task-ref-icon-button{width:52px;height:52px;border:1px solid #dce3ee;border-radius:14px;background:#fff;color:var(--tr-ink);display:inline-flex;align-items:center;justify-content:center;font-size:27px;transition:.16s ease}.task-ref-icon-button:hover{border-color:#bdc7d6;background:#f8fafc}.task-ref-create-heading-icon,.task-ref-details-title-icon{width:58px;height:58px;border-radius:15px;display:flex;align-items:center;justify-content:center;color:#4f46e5;font-size:31px;border:1px solid #d9ddff;background:linear-gradient(145deg,#f7f8ff,#ecebff);box-shadow:0 9px 20px rgba(79,70,229,.10)}
.task-ref-create-heading-copy h2{margin:0;color:var(--tr-ink);font-size:31px;font-weight:750;letter-spacing:-.02em}.task-ref-create-heading-copy p{margin:4px 0 0;color:#667085;font-size:16px}.task-ref-close{margin-inline-start:16px}.task-ref-create-body{padding:34px 28px 28px;overflow:auto;flex:1}.task-ref-form-grid{display:grid;grid-template-columns:1.35fr .95fr;gap:28px 34px}.task-ref-field{min-width:0}.task-ref-field>label,.task-ref-field>h3{display:block;margin:0 0 11px;color:#101828;font-size:17px;font-weight:650}.task-ref-muted{color:#79839a;font-weight:400}.task-ref-input-wrap,.task-ref-select-shell,.task-ref-date-input{height:58px;border:1.5px solid #d7deea;border-radius:13px;background:#fff;display:flex;align-items:center;padding:0 16px;gap:12px;transition:.16s ease}.task-ref-input-wrap:focus-within,.task-ref-select-shell:focus-within,.task-ref-date-input:focus-within,.task-ref-input-focus{border-color:#5b5cff;box-shadow:0 0 0 3px rgba(91,92,255,.08)}.task-ref-input-wrap>i,.task-ref-select-shell>i,.task-ref-date-input>i{font-size:22px;color:#596579;flex:0 0 auto}.task-ref-input,.task-ref-input-wrap input,.task-ref-date-input input{border:0!important;outline:0!important;box-shadow:none!important;background:transparent!important;width:100%;height:100%;font-size:16px;color:#111827;padding:0!important}.task-ref-select-shell>.ts-wrapper,.task-ref-assignee-field>.ts-wrapper{width:100%}.task-ref-select-shell .ts-control,.task-ref-assignee-field .ts-control{border:0!important;box-shadow:none!important;min-height:52px!important;background:transparent!important;padding:13px 8px!important;font-size:15px}.task-ref-select-shell .ts-dropdown,.task-ref-assignee-field .ts-dropdown{border-radius:12px!important;border-color:#e0e5ee!important;box-shadow:0 16px 35px rgba(15,23,42,.12)!important}.task-ref-project-field{margin-top:26px}.task-ref-system-fields{position:absolute!important;width:1px!important;height:1px!important;overflow:hidden!important;opacity:0!important;pointer-events:none!important}.task-ref-system-fields .ts-wrapper{display:none!important}.task-ref-description-field{margin-top:30px}.task-ref-editor{border:1.5px solid #d9dee8;border-radius:14px;overflow:hidden;background:#fff}.task-ref-editor-toolbar{min-height:60px;display:flex;align-items:center;gap:7px;padding:10px 14px;border-bottom:1px solid #e6eaf0;background:#fff;flex-wrap:wrap}.task-ref-editor-toolbar>button{width:38px;height:38px;border:0;border-radius:9px;background:transparent;color:#111827;font-size:20px;display:inline-flex;align-items:center;justify-content:center}.task-ref-editor-toolbar>button:hover{background:#f2f4f7}.task-ref-editor-toolbar>span{width:1px;height:30px;background:#e5e7eb;margin:0 3px}.task-ref-ai-tools{margin-inline-start:auto;display:flex;align-items:center;gap:8px}.task-ref-ai-toggle{display:flex;align-items:center;gap:6px;font-size:12px;color:#667085;margin:0}.task-ref-ai-button{width:36px!important;height:36px!important;color:#4f46e5!important;background:#f1f0ff!important}.task-ref-ai-tools .spinner-border{width:18px;height:18px}.task-ref-custom-prompt{padding:10px 14px;border-bottom:1px solid #eef1f5;background:#fbfcfe}.task-ref-custom-prompt textarea{width:100%;border:1px solid #d7deea;border-radius:10px;padding:10px 12px;resize:vertical}.task-ref-editor-textarea{width:100%;min-height:150px;border:0!important;outline:0!important;box-shadow:none!important;resize:vertical;padding:20px 22px!important;font-size:16px;line-height:1.65;color:#1d2939;background:#fff!important}.task-ref-split-row{display:grid;grid-template-columns:.9fr 1.1fr;gap:36px;margin-top:32px}.task-ref-priority-cards{display:grid;grid-template-columns:repeat(4,minmax(74px,1fr));gap:12px}.task-ref-priority-card{min-height:128px;border:1.5px solid #d9dee8;border-radius:12px;background:#fff;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:11px;padding:12px 8px;color:#344054;font-size:14px;font-weight:650;transition:.16s ease}.task-ref-priority-card i{font-size:30px}.task-ref-priority-card.tone-danger,.task-ref-priority-card.tone-red{border-color:#ff878d;color:#df2330;background:#fffafa}.task-ref-priority-card.tone-warning,.task-ref-priority-card.tone-orange{border-color:#ffad78;color:#ea5d0b;background:#fffaf6}.task-ref-priority-card.tone-success,.task-ref-priority-card.tone-green{border-color:#f3c759;color:#c68800;background:#fffdf5}.task-ref-priority-card.tone-primary,.task-ref-priority-card.tone-info,.task-ref-priority-card.tone-blue,.task-ref-priority-card.tone-secondary{border-color:#7aa0ff;color:#2459e8;background:#f8fbff}.task-ref-priority-card.is-active{box-shadow:0 0 0 3px rgba(49,87,255,.12);transform:translateY(-1px)}.task-ref-source-select+.ts-wrapper,.task-ref-source-select{position:absolute!important;left:-9999px!important;width:1px!important;height:1px!important;opacity:0!important;pointer-events:none!important}.task-ref-assignee-toolbar{display:flex;align-items:center;justify-content:space-between;margin-bottom:12px}.task-ref-segmented{display:inline-flex;border:1px solid #e2e7ef;border-radius:11px;background:#f8fafc;padding:3px}.task-ref-segmented button{height:38px;padding:0 15px;border:0;background:transparent;border-radius:8px;color:#667085;font-weight:600}.task-ref-segmented button.active{background:#fff;color:#2459e8;box-shadow:0 2px 7px rgba(15,23,42,.08)}.task-ref-segmented button i{margin-inline-end:6px}.task-ref-assignee-field>.ts-wrapper{border:1.5px solid #d9dee8;border-radius:13px;min-height:58px;background:#fff}.task-ref-assignee-field .ts-control .item{border-radius:999px!important;background:#f5f7fb!important;color:#1f2937!important;padding:5px 9px!important}.task-ref-deadline-field{margin-top:32px;max-width:560px}.task-ref-deadline-shell{display:grid;grid-template-columns:minmax(280px,1fr) auto;gap:28px;align-items:center}.task-ref-all-day,.task-ref-switch-row{display:flex;align-items:center;gap:12px;margin:0;color:#344054}.task-ref-all-day input,.task-ref-switch-row input{position:absolute;opacity:0;pointer-events:none}.task-ref-all-day span,.task-ref-switch-row span{width:52px;height:30px;border-radius:999px;background:#d0d5dd;position:relative;transition:.2s}.task-ref-all-day span:after,.task-ref-switch-row span:after{content:"";position:absolute;width:24px;height:24px;border-radius:50%;background:#fff;top:3px;left:3px;box-shadow:0 2px 5px rgba(15,23,42,.2);transition:.2s}.task-ref-all-day input:checked+span,.task-ref-switch-row input:checked+span{background:#3157ff}.task-ref-all-day input:checked+span:after,.task-ref-switch-row input:checked+span:after{left:25px}.task-ref-attachments-field{margin-top:32px}.task-ref-attachments-box{border:1.5px solid #d9dee8;border-radius:14px;padding:24px;background:#fff}.task-ref-upload-row{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.task-ref-upload-button,.task-ref-file-chip{min-height:46px;border:1px solid #d7deea;border-radius:10px;background:#fff;color:#101828;display:inline-flex;align-items:center;gap:8px;padding:0 16px;font-weight:650;text-decoration:none!important;cursor:pointer}.task-ref-upload-button i,.task-ref-file-chip i{font-size:20px}.task-ref-file-chip.pdf{color:#d92732;background:#fff5f5;border-color:#ffc6c9}.task-ref-file-chip.sheet{color:#0e8b32;background:#f2fbf5;border-color:#c6ebd0}.task-ref-file-chip.doc{color:#1556a8;background:#f3f8ff;border-color:#c7dcf7}.task-ref-file-chip.image{color:#6d37d6;background:#f8f4ff;border-color:#ddcdfb}.task-ref-max-size{margin-inline-start:auto}.task-ref-selected-files{display:flex;gap:8px;flex-wrap:wrap;margin-top:12px}.task-ref-selected-files span{font-size:12px;padding:5px 8px;border-radius:7px;background:#f2f4f7;color:#475467}.task-ref-link-caption{font-size:14px;color:#667085;margin:22px 0 10px}.task-ref-link-row{display:grid;grid-template-columns:1fr auto;gap:12px}.task-ref-add-link{border:1px solid #d7deea;border-radius:11px;background:#fff;color:#344054;font-weight:650;padding:0 18px}.task-ref-link-name{margin-top:12px}.task-ref-pending-links{margin-top:12px;display:grid;gap:8px}.task-ref-pending-link{display:flex;align-items:center;gap:8px;padding:9px 11px;background:#f8fafc;border:1px solid #e5e9f0;border-radius:9px;font-size:13px}.task-ref-pending-link button{margin-inline-start:auto;border:0;background:transparent;color:#d92d20}.task-ref-more-settings{margin-top:28px;border-top:1px solid #eef1f5;padding-top:20px}.task-ref-more-settings summary{list-style:none;cursor:pointer;color:#344054;font-weight:650;display:inline-flex;align-items:center;gap:8px}.task-ref-more-settings summary::-webkit-details-marker{display:none}.task-ref-more-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px 24px;margin-top:18px}.task-ref-wide{grid-column:1/-1}.task-ref-nested-settings{margin-top:12px;display:grid;grid-template-columns:repeat(2,1fr);gap:12px}.task-ref-custom-fields{margin-top:18px}.task-ref-create-footer{display:grid;grid-template-columns:auto auto 1fr;gap:18px;padding:24px 28px;border-top:1px solid #e8ecf2;background:#fff;align-items:center}.task-ref-secondary-btn,.task-ref-draft-btn,.task-ref-primary-btn{min-height:56px;border-radius:12px;padding:0 28px;font-size:16px;font-weight:700;display:inline-flex;align-items:center;justify-content:center;gap:8px}.task-ref-secondary-btn{border:1px solid #d9dee8;background:#fff;color:#101828}.task-ref-draft-btn{border:1px solid #e2e7ef;background:#f8fafc;color:#475467}.task-ref-primary-btn{border:0;background:linear-gradient(135deg,#3157ff,#1461ee);color:#fff;box-shadow:0 10px 24px rgba(49,87,255,.22);justify-self:end}.task-ref-primary-btn:hover{filter:brightness(.98)}
/* Task details */
.task-ref-details-page{padding:28px 24px 40px!important;max-width:1320px;margin:0 auto}.task-ref-details-shell{border:1px solid #dfe5ee;border-radius:18px;background:#fff;box-shadow:0 14px 40px rgba(15,23,42,.08);overflow:hidden}.task-ref-details-header{display:grid;grid-template-columns:52px 58px minmax(0,1fr) auto;gap:16px;align-items:start;padding:30px 28px 20px;background:linear-gradient(100deg,#f8fbff,#fff 52%,#fdf8ff);border-bottom:1px solid #eef1f5}.task-ref-details-title-copy h1{margin:0;color:#101828;font-size:29px;line-height:1.05;font-weight:760;letter-spacing:-.02em}.task-ref-details-title-copy h1 span{font-size:27px}.task-ref-status-chip{display:inline-flex;align-items:center;gap:7px;margin-top:12px;padding:6px 11px;border-radius:7px;background:#dff5fa;color:#195a68;font-size:14px}.task-ref-details-head-actions{display:flex;gap:12px;align-items:center}.task-ref-outline-btn{min-height:48px;border:1px solid #d5dce6;border-radius:11px;background:#fff;color:#101828;padding:0 18px;font-weight:650;display:inline-flex;align-items:center;gap:7px}.task-ref-details-grid{display:grid;grid-template-columns:minmax(0,1.45fr) minmax(330px,.8fr)}.task-ref-details-main{padding:28px 28px 34px;border-inline-end:1px solid #e5e9f0}.task-ref-task-facts{display:grid;gap:12px;margin-bottom:26px;font-size:16px}.task-ref-task-facts span{display:inline-block;min-width:62px;color:#101828}.task-ref-task-facts strong{font-weight:650}.task-ref-section{margin-top:28px}.task-ref-section:first-of-type{margin-top:0}.task-ref-section h3{font-size:16px;margin:0 0 12px;color:#101828;font-weight:650}.task-ref-view-editor{border:1.5px solid #d9dee8;border-radius:13px;overflow:hidden}.task-ref-editor-toolbar-view{min-height:52px;background:#fff}.task-ref-editor-toolbar-view button{pointer-events:none}.task-ref-description-content{min-height:130px;padding:18px 20px;color:#1f2937;font-size:15px;line-height:1.7}.task-ref-description-content.is-empty{color:#98a2b3;font-style:italic}.task-ref-priority-badge{display:inline-flex;align-items:center;gap:8px;border-radius:8px;padding:8px 12px;font-weight:700;background:#fff1f1;color:#cb2631;border:1px solid #f0b3b8}.task-ref-priority-badge.tone-warning,.task-ref-priority-badge.tone-orange{background:#fff7ed;color:#c5550b;border-color:#fdc48f}.task-ref-priority-badge.tone-success,.task-ref-priority-badge.tone-green{background:#f0fdf4;color:#15803d;border-color:#b7e4c2}.task-ref-priority-badge.tone-primary,.task-ref-priority-badge.tone-info,.task-ref-priority-badge.tone-blue,.task-ref-priority-badge.tone-secondary{background:#eff6ff;color:#1d4ed8;border-color:#b7d2ff}.task-ref-deadline-value{display:flex;align-items:center;gap:10px;color:#101828}.task-ref-deadline-value i{font-size:24px}.task-ref-section-title-row{display:flex;align-items:center;justify-content:space-between;gap:16px}.task-ref-link-btn{border:0;background:transparent;color:#1d4ed8;font-weight:650}.task-ref-assignee-list{display:flex;align-items:center;gap:16px;flex-wrap:wrap}.task-ref-person-chip{display:inline-flex;align-items:center;gap:8px;text-decoration:none!important;color:#101828}.task-ref-person-chip img{width:43px;height:43px;border-radius:50%;object-fit:cover;border:1px solid #e2e8f0}.task-ref-detail-attachments{border:1px solid #dfe5ee;border-radius:12px;background:#fbfcfe;padding:18px;display:flex;align-items:center;gap:10px;flex-wrap:wrap}.task-ref-reference-links{margin-top:12px;display:grid;gap:10px}.task-ref-reference-link{min-height:48px;border:1px solid #dfe5ee;border-radius:10px;display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:10px;padding:0 14px;color:#475467}.task-ref-reference-link a{color:#101828;font-weight:650;text-decoration:none}.task-ref-details-aside{background:#fff;min-width:0}.task-ref-aside-topbar{display:flex;justify-content:flex-end;padding:16px 20px;border-bottom:1px solid #e7ebf1}.task-ref-aside-section{padding:20px;border-bottom:1px solid #e7ebf1}.task-ref-aside-section h3{margin:0 0 14px;font-size:18px;color:#101828}.task-ref-status-form label{display:block;margin:12px 0 8px;color:#1f2937;font-weight:600}.task-ref-status-select{width:100%;height:56px;border:1.5px solid #8aa0ff;border-radius:12px;background:#fff;padding:0 14px;font-size:16px;outline:0;box-shadow:0 0 0 3px rgba(49,87,255,.07)}.task-ref-note-wrap{position:relative}.task-ref-note-wrap textarea,.task-ref-quick-comment textarea{width:100%;border:1px solid #d7dee8;border-radius:12px;padding:14px;resize:vertical;outline:0;color:#101828;min-height:110px}.task-ref-note-wrap small{position:absolute;right:12px;bottom:8px;color:#667085}.is-rtl .task-ref-note-wrap small{right:auto;left:12px}.task-ref-status-submit{width:100%;margin-top:12px;min-height:48px}.task-ref-comment-list{display:grid;gap:22px}.task-ref-comment-item{display:grid;grid-template-columns:42px 1fr;gap:12px}.task-ref-comment-item>img{width:42px;height:42px;border-radius:50%;object-fit:cover}.task-ref-comment-meta{display:flex;justify-content:space-between;gap:12px;font-size:14px}.task-ref-comment-meta strong{color:#101828}.task-ref-comment-meta time{color:#667085;font-size:12px}.task-ref-comment-text{margin-top:4px;color:#101828;line-height:1.45;font-size:14px}.task-ref-empty-comments{color:#98a2b3;text-align:center;padding:20px 0}.task-ref-quick-comment{margin-top:24px;padding-top:18px;border-top:1px solid #edf0f4}.task-ref-comment-submit{margin-top:10px;margin-inline-start:auto;min-height:44px;padding:0 18px;border:1px solid #d7deea;border-radius:10px;background:#f7f9fc;color:#344054;font-weight:650;display:flex;align-items:center;gap:8px}.task-ref-advanced{max-width:1320px;margin-inline:auto!important;border-radius:16px!important}.task-ref-advanced .card-body{padding:22px!important}
@media(max-width:991.98px){.task-ref-create{top:12px!important;left:12px!important;right:12px!important;bottom:12px!important;width:calc(100vw - 24px)!important;height:calc(100dvh - 24px)!important;transform:translateX(110vw)!important;border-radius:16px!important}.task-ref-create.show,.task-ref-create.showing{transform:translateX(0)!important}.task-ref-create.hiding{transform:translateX(110vw)!important}.task-ref-create-header{grid-template-columns:48px 48px 1fr 48px;padding:20px;gap:10px}.task-ref-icon-button{width:46px;height:46px}.task-ref-create-heading-icon{width:48px;height:48px;font-size:25px}.task-ref-create-heading-copy h2{font-size:24px}.task-ref-create-heading-copy p{font-size:13px}.task-ref-create-body{padding:22px 20px}.task-ref-form-grid,.task-ref-split-row,.task-ref-details-grid{grid-template-columns:1fr}.task-ref-details-main{border-inline-end:0;border-bottom:1px solid #e5e9f0}.task-ref-priority-cards{grid-template-columns:repeat(2,1fr)}.task-ref-create-footer{grid-template-columns:1fr 1fr;padding:18px 20px}.task-ref-primary-btn{grid-column:1/-1;width:100%;justify-self:stretch}.task-ref-details-header{grid-template-columns:48px 50px 1fr;gap:10px;padding:20px}.task-ref-details-head-actions{grid-column:1/-1;justify-content:flex-end}.task-ref-details-title-copy h1,.task-ref-details-title-copy h1 span{font-size:22px}.task-ref-details-page{padding:14px!important}}
@media(max-width:575.98px){.task-ref-create{top:0!important;left:0!important;right:0!important;bottom:0!important;width:100vw!important;height:100dvh!important;border-radius:0!important}.task-ref-create-header{grid-template-columns:42px 42px 1fr 42px;padding:14px 12px}.task-ref-icon-button{width:40px;height:40px;border-radius:10px;font-size:22px}.task-ref-create-heading-icon{width:42px;height:42px;border-radius:11px;font-size:22px}.task-ref-create-heading-copy h2{font-size:20px}.task-ref-create-heading-copy p{display:none}.task-ref-create-body{padding:18px 14px}.task-ref-deadline-shell{grid-template-columns:1fr}.task-ref-upload-row{align-items:stretch}.task-ref-upload-button,.task-ref-file-chip{min-height:42px;padding:0 11px;font-size:13px}.task-ref-max-size{width:100%;margin:0}.task-ref-link-row{grid-template-columns:1fr}.task-ref-add-link{min-height:48px}.task-ref-more-grid,.task-ref-nested-settings{grid-template-columns:1fr}.task-ref-create-footer{gap:10px;padding:14px}.task-ref-secondary-btn,.task-ref-draft-btn,.task-ref-primary-btn{min-height:50px;padding:0 14px;font-size:14px}.task-ref-details-page{padding:0!important}.task-ref-details-shell{border-radius:0;border-inline:0}.task-ref-details-header{padding:16px 14px}.task-ref-details-main,.task-ref-aside-section{padding:20px 16px}.task-ref-assignee-list{gap:10px}.task-ref-person-chip span{font-size:13px}}
[dir="rtl"] .task-ref-back i,[dir="rtl"] .task-ref-details-header>.task-ref-icon-button:first-child i{transform:rotate(180deg)}
.task-ref-group-picker{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin-top:10px;max-height:220px;overflow:auto}.task-ref-group-option{cursor:pointer}.task-ref-group-option input{position:absolute;opacity:0;pointer-events:none}.task-ref-group-option span{display:flex;align-items:center;gap:9px;padding:11px 12px;border:1px solid #dfe4ef;border-radius:12px;background:#fff;transition:.18s}.task-ref-group-option span i{font-size:20px;color:#5963ff}.task-ref-group-option span b{font-size:13px}.task-ref-group-option span small{margin-inline-start:auto;color:#929bad;font-size:11px}.task-ref-group-option input:checked+span{border-color:#5a61ff;background:#f2f3ff;box-shadow:0 0 0 2px rgba(90,97,255,.1)}.task-ref-time-input{max-width:145px}@media(max-width:700px){.task-ref-group-picker{grid-template-columns:1fr}.task-ref-time-input{max-width:none;width:100%}}
.task-ref-group-dot{width:30px;height:30px;border-radius:50%;background:#eef0ff;color:#5660ff;display:grid;place-items:center}.task-ref-comment-actions{display:flex;justify-content:flex-end;align-items:center;gap:8px;margin-top:8px}.task-ref-comment-attach{width:40px;height:40px;border:1px solid #dfe3ed;border-radius:10px;display:grid;place-items:center;cursor:pointer;font-size:20px;color:#5460ff}

/* DARBAREEF TASK REFERENCE UI — COMPACT + SOLID PRIORITY 2026-09-03 */
@media(min-width:992px){
.task-ref-create{--bs-offcanvas-width:min(860px,calc(100vw - 44px));height:min(88vh,860px)!important;border-radius:15px!important}
}
.task-ref-create-header{grid-template-columns:44px 46px 1fr auto;gap:11px;padding:17px 20px!important}
.task-ref-icon-button{width:42px!important;height:42px!important;border-radius:10px!important;font-size:22px!important}
.task-ref-create-heading-icon,.task-ref-details-title-icon{width:46px!important;height:46px!important;border-radius:11px!important;font-size:25px!important}
.task-ref-create-heading-copy h2{font-size:24px!important}.task-ref-create-heading-copy p{font-size:13px!important;margin-top:2px!important}
.task-ref-create-body{padding:20px 20px 18px!important}.task-ref-form-grid{gap:18px 22px!important}.task-ref-field>label,.task-ref-field>h3{margin-bottom:7px!important;font-size:14px!important}
.task-ref-input-wrap,.task-ref-select-shell,.task-ref-date-input{height:46px!important;border-radius:10px!important;padding:0 12px!important;gap:8px!important}.task-ref-input,.task-ref-input-wrap input,.task-ref-date-input input{font-size:14px!important}.task-ref-select-shell .ts-control,.task-ref-assignee-field .ts-control{min-height:42px!important;padding:9px 6px!important;font-size:13px!important}
.task-ref-description-field{margin-top:20px!important}.task-ref-editor{border-radius:11px!important}.task-ref-editor-toolbar{min-height:46px!important;padding:6px 10px!important}.task-ref-editor-toolbar>button{width:32px!important;height:32px!important;font-size:17px!important}.task-ref-editor-textarea{min-height:112px!important;padding:13px 15px!important;font-size:14px!important}
.task-ref-split-row{gap:22px!important;margin-top:21px!important}.task-ref-priority-cards{gap:8px!important}.task-ref-priority-card{min-height:88px!important;border-radius:10px!important;gap:7px!important;padding:9px 6px!important;font-size:12px!important;border:0!important}.task-ref-priority-card i{font-size:23px!important}
.task-ref-priority-card.tone-danger,.task-ref-priority-card.tone-red{background:#dc2626!important;color:#fff!important}.task-ref-priority-card.tone-warning,.task-ref-priority-card.tone-orange{background:#facc15!important;color:#171717!important}.task-ref-priority-card.tone-success,.task-ref-priority-card.tone-green{background:#16a34a!important;color:#fff!important}.task-ref-priority-card.tone-primary,.task-ref-priority-card.tone-info,.task-ref-priority-card.tone-blue,.task-ref-priority-card.tone-secondary{background:#2563eb!important;color:#fff!important}.task-ref-priority-card.is-active{box-shadow:0 0 0 3px #fff,0 0 0 6px rgba(49,87,255,.28)!important;transform:none!important}
.task-ref-assignee-toolbar{margin-bottom:8px!important}.task-ref-segmented button{height:32px!important;padding:0 11px!important;font-size:12px!important}.task-ref-assignee-field>.ts-wrapper{min-height:46px!important;border-radius:10px!important}.task-ref-deadline-field,.task-ref-attachments-field{margin-top:21px!important}.task-ref-deadline-shell{gap:18px!important}.task-ref-all-day span,.task-ref-switch-row span{width:44px!important;height:26px!important}.task-ref-all-day span:after,.task-ref-switch-row span:after{width:20px!important;height:20px!important}.task-ref-all-day input:checked+span:after,.task-ref-switch-row input:checked+span:after{left:21px!important}
.task-ref-attachments-box{border-radius:11px!important;padding:15px!important}.task-ref-upload-row{gap:8px!important}.task-ref-upload-button,.task-ref-file-chip{min-height:38px!important;border-radius:8px!important;padding:0 12px!important;font-size:12px!important}.task-ref-link-caption{margin:14px 0 7px!important;font-size:12px!important}.task-ref-link-row{gap:8px!important}.task-ref-add-link{border-radius:9px!important;padding:0 13px!important;font-size:12px!important}.task-ref-link-name{margin-top:8px!important}.task-ref-more-settings{margin-top:18px!important;padding-top:14px!important}.task-ref-more-grid{gap:12px 16px!important;margin-top:12px!important}
.task-ref-create-footer{gap:10px!important;padding:13px 20px!important}.task-ref-secondary-btn,.task-ref-draft-btn,.task-ref-primary-btn{min-height:42px!important;border-radius:9px!important;padding:0 18px!important;font-size:13px!important}
/* Compact task details */
.task-ref-details-page{padding:18px 16px 26px!important;max-width:1120px!important}.task-ref-details-shell{border-radius:14px!important}.task-ref-details-header{grid-template-columns:42px 46px minmax(0,1fr) auto!important;gap:11px!important;padding:18px 20px 14px!important}.task-ref-details-title-copy h1{font-size:23px!important}.task-ref-details-title-copy h1 span{font-size:20px!important}.task-ref-status-chip{margin-top:8px!important;padding:5px 9px!important;font-size:12px!important}.task-ref-outline-btn{min-height:38px!important;border-radius:9px!important;padding:0 13px!important;font-size:12px!important}.task-ref-details-grid{grid-template-columns:minmax(0,1.5fr) minmax(285px,.72fr)!important}.task-ref-details-main{padding:18px 20px 22px!important}.task-ref-task-facts{gap:8px!important;margin-bottom:18px!important;font-size:13px!important}.task-ref-section{margin-top:18px!important}.task-ref-section h3{font-size:13px!important;margin-bottom:8px!important}.task-ref-view-editor{border-radius:10px!important}.task-ref-editor-toolbar-view{min-height:42px!important}.task-ref-description-content{min-height:96px!important;padding:12px 14px!important;font-size:13px!important;line-height:1.55!important}.task-ref-priority-badge{border-radius:7px!important;padding:6px 10px!important;font-size:12px!important}.task-ref-deadline-value i{font-size:20px!important}.task-ref-assignee-list{gap:11px!important}.task-ref-person-chip img{width:34px!important;height:34px!important}.task-ref-person-chip span{font-size:12px!important}.task-ref-detail-attachments{border-radius:10px!important;padding:12px!important;gap:7px!important}.task-ref-reference-links{gap:7px!important}.task-ref-reference-link{min-height:40px!important;border-radius:8px!important;padding:0 10px!important;font-size:12px!important}.task-ref-aside-topbar{padding:11px 13px!important}.task-ref-aside-section{padding:14px!important}.task-ref-aside-section h3{margin-bottom:9px!important;font-size:14px!important}.task-ref-status-form label{margin:9px 0 6px!important;font-size:12px!important}.task-ref-status-select{height:44px!important;border-radius:9px!important;padding:0 10px!important;font-size:13px!important}.task-ref-note-wrap textarea,.task-ref-quick-comment textarea{border-radius:9px!important;padding:10px!important;min-height:78px!important;font-size:12px!important}.task-ref-status-submit{margin-top:8px!important;min-height:38px!important}.task-ref-comment-list{gap:14px!important}.task-ref-comment-item{grid-template-columns:34px 1fr!important;gap:8px!important}.task-ref-comment-item>img{width:34px!important;height:34px!important}.task-ref-comment-meta{font-size:12px!important}.task-ref-comment-text{font-size:12px!important}.task-ref-quick-comment{margin-top:15px!important;padding-top:13px!important}.task-ref-comment-submit{min-height:36px!important;padding:0 13px!important}.task-ref-advanced{max-width:1120px!important;border-radius:12px!important}.task-ref-advanced .card-body{padding:14px!important}
/* Task details priority: clear 100% color marker in header + solid badge. */
.task-ref-details-priority-danger{border-top:5px solid #dc2626!important}.task-ref-details-priority-warning{border-top:5px solid #facc15!important}.task-ref-details-priority-success{border-top:5px solid #16a34a!important}.task-ref-details-priority-info{border-top:5px solid #2563eb!important}.task-ref-priority-badge.tone-danger,.task-ref-priority-badge.tone-red{background:#dc2626!important;color:#fff!important;border-color:#dc2626!important}.task-ref-priority-badge.tone-warning,.task-ref-priority-badge.tone-orange{background:#facc15!important;color:#171717!important;border-color:#eab308!important}.task-ref-priority-badge.tone-success,.task-ref-priority-badge.tone-green{background:#16a34a!important;color:#fff!important;border-color:#16a34a!important}.task-ref-priority-badge.tone-primary,.task-ref-priority-badge.tone-info,.task-ref-priority-badge.tone-blue,.task-ref-priority-badge.tone-secondary{background:#2563eb!important;color:#fff!important;border-color:#2563eb!important}
@media(max-width:991.98px){.task-ref-create-header{padding:14px!important}.task-ref-create-body{padding:16px 14px!important}.task-ref-details-page{padding:10px!important}.task-ref-details-header{grid-template-columns:40px 42px 1fr!important;padding:14px!important}.task-ref-details-main{padding:15px!important}.task-ref-aside-section{padding:13px!important}}
@media(max-width:575.98px){.task-ref-create-body{padding:14px 11px!important}.task-ref-priority-card{min-height:76px!important}.task-ref-create-footer{padding:10px!important}.task-ref-details-page{padding:0!important}.task-ref-details-main,.task-ref-aside-section{padding:14px 12px!important}}

/* V4 numeric containment */
.task-ref-details-shell,.task-ref-details-grid,.task-ref-details-main,.task-ref-details-aside,.task-ref-create-form,.task-ref-create-body,.task-ref-field{min-width:0}.task-ref-status-chip,.task-ref-priority-badge,.task-ref-deadline-value,.task-ref-selected-files span{max-width:100%;overflow:hidden;text-overflow:ellipsis}.task-ref-status-chip,.task-ref-priority-badge{white-space:nowrap}.task-ref-deadline-value{overflow-wrap:anywhere}.task-ref-create input[type="number"],.task-ref-details-page input[type="number"]{max-width:100%;min-width:0}

/* ============================================================================
   TASK REFERENCE UI RESPONSIVE CLOSURE V6 — 2026-09-08
   ============================================================================ */
.task-ref-create{max-width:calc(100vw - 24px)!important;max-height:calc(100dvh - 24px)!important}
.task-ref-create-heading-icon i,.task-ref-ai-button i{display:inline-flex!important;align-items:center!important;justify-content:center!important;line-height:1!important}
.task-ref-file-chip{cursor:pointer;user-select:none;transition:transform .15s ease,box-shadow .15s ease,border-color .15s ease}
.task-ref-file-chip:hover,.task-ref-upload-button:hover{transform:translateY(-1px);box-shadow:0 4px 12px rgba(15,23,42,.07)}
.task-ref-file-chip:focus-within,.task-ref-upload-button:focus-within{outline:3px solid rgba(49,87,255,.12);outline-offset:2px}
.task-ref-selected-files{display:grid!important;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:8px!important}
.task-ref-selected-file{min-width:0;max-width:100%!important;display:grid!important;grid-template-columns:24px minmax(0,1fr) auto;align-items:center;gap:7px!important;padding:8px 10px!important;border:1px solid #e4e8f0;border-radius:9px!important;background:#fafbfe!important;color:#344054!important}
.task-ref-selected-file i{font-size:18px}.task-ref-selected-file b{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:11px;font-weight:650}.task-ref-selected-file small{white-space:nowrap;color:#8a94a6;font-size:9.5px}.task-ref-selected-file.pdf i{color:#d92732}.task-ref-selected-file.sheet i{color:#0e8b32}.task-ref-selected-file.doc i{color:#1556a8}.task-ref-selected-file.image i{color:#6d37d6}

@media(min-width:1200px){
  .task-ref-create{--bs-offcanvas-width:min(1040px,calc(100vw - 64px))!important;width:var(--bs-offcanvas-width)!important;height:min(92dvh,920px)!important}
  .task-ref-create-body{padding-inline:24px!important}
}
@media(min-width:992px) and (max-width:1199.98px){
  .task-ref-create{--bs-offcanvas-width:min(900px,calc(100vw - 36px))!important;width:var(--bs-offcanvas-width)!important;height:min(92dvh,900px)!important}
}
@media(max-width:991.98px){
  .task-ref-create{max-width:none!important;max-height:none!important}
  .task-ref-form-grid,.task-ref-split-row{grid-template-columns:1fr!important}
  .task-ref-project-field{margin-top:18px!important}
  .task-ref-description-field{margin-top:18px!important}
  .task-ref-deadline-shell{grid-template-columns:minmax(0,1fr) auto!important;gap:14px!important}
  .task-ref-upload-row{align-items:stretch!important}
  .task-ref-max-size{width:100%;margin-inline-start:0!important;padding-top:2px}
}
@media(max-width:767.98px){
  .task-ref-create{
    top:0!important;left:0!important;right:0!important;bottom:0!important;
    width:100vw!important;height:100dvh!important;max-width:100vw!important;max-height:100dvh!important;
    border:0!important;border-radius:0!important;
    transform:translateX(105%)!important;
  }
  [dir="rtl"] .task-ref-create{transform:translateX(-105%)!important}
  .task-ref-create.show,.task-ref-create.showing{transform:translateX(0)!important}
  .task-ref-create.hiding{transform:translateX(105%)!important}
  [dir="rtl"] .task-ref-create.hiding{transform:translateX(-105%)!important}
  .task-ref-create-header{grid-template-columns:40px 40px minmax(0,1fr) 40px!important;gap:8px!important;padding:11px 12px!important;position:sticky;top:0;z-index:4}
  .task-ref-icon-button{width:38px!important;height:38px!important;font-size:21px!important}
  .task-ref-create-heading-icon{width:40px!important;height:40px!important;font-size:21px!important}
  .task-ref-create-heading-copy h2{font-size:19px!important}.task-ref-create-heading-copy p{font-size:11.5px!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .task-ref-create-body{padding:15px 12px 96px!important}
  .task-ref-field>label,.task-ref-field>h3{font-size:13px!important}
  .task-ref-input-wrap,.task-ref-select-shell,.task-ref-date-input{height:48px!important}
  .task-ref-editor-toolbar{gap:4px!important;padding:6px!important}
  .task-ref-editor-toolbar>button{width:34px!important;height:34px!important}
  .task-ref-ai-tools{width:auto;max-width:100%;margin-inline-start:auto!important;gap:5px!important}
  .task-ref-ai-toggle{font-size:11px!important;white-space:nowrap}
  .task-ref-editor-textarea{min-height:126px!important}
  .task-ref-priority-cards{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .task-ref-priority-card{min-height:76px!important}
  .task-ref-assignee-toolbar{overflow-x:auto;scrollbar-width:none}.task-ref-assignee-toolbar::-webkit-scrollbar{display:none}.task-ref-segmented{white-space:nowrap}
  .task-ref-deadline-shell{grid-template-columns:1fr!important;align-items:stretch!important}
  .task-ref-time-input{width:100%!important;max-width:none!important}
  .task-ref-upload-row{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:8px!important}
  .task-ref-upload-button{grid-column:1/-1!important;justify-content:center!important}
  .task-ref-file-chip{width:100%!important;justify-content:center!important;padding-inline:8px!important}
  .task-ref-max-size{grid-column:1/-1!important;text-align:center}
  .task-ref-selected-files{grid-template-columns:1fr!important}
  .task-ref-link-row{grid-template-columns:1fr!important}.task-ref-add-link{min-height:44px!important}
  .task-ref-create-footer{position:sticky!important;bottom:0!important;z-index:5!important;display:grid!important;grid-template-columns:1fr 1fr!important;gap:8px!important;padding:10px 12px!important;background:rgba(255,255,255,.96)!important;backdrop-filter:blur(12px);border-top:1px solid #e7eaf0}
  .task-ref-primary-btn{grid-column:1/-1!important;width:100%!important}
  .task-ref-secondary-btn,.task-ref-draft-btn,.task-ref-primary-btn{min-height:46px!important;padding-inline:10px!important}
}
@media(max-width:480px){
  .task-ref-create-header{grid-template-columns:38px 1fr 38px!important}
  .task-ref-create-heading-icon{display:none!important}
  .task-ref-back{grid-column:1}.task-ref-create-heading-copy{grid-column:2}.task-ref-close{grid-column:3;margin-inline-start:0!important}
  .task-ref-create-heading-copy p{display:none!important}
  .task-ref-create-body{padding-inline:10px!important}
  .task-ref-editor-toolbar>span{display:none!important}
  .task-ref-ai-tools{width:100%!important;margin-inline-start:0!important;justify-content:flex-end;border-top:1px solid #eef1f5;padding-top:5px}
  .task-ref-upload-row{grid-template-columns:1fr 1fr!important}
}
@media(max-width:360px){
  .task-ref-upload-row{grid-template-columns:1fr!important}
  .task-ref-upload-button,.task-ref-max-size{grid-column:1!important}
  .task-ref-create-footer{grid-template-columns:1fr!important}
  .task-ref-primary-btn{grid-column:1!important}
}
