/* Reference Teamwork layout. Presentation only; existing records and actions are unchanged. */
html body main:has(>:is(#tasksView,#boardsView,#galleryView,#teamsView,#usersView).active){max-width:none;width:100%;margin:0;padding:0}
:is(#tasksView,#boardsView,#galleryView,#teamsView,#usersView).tw-reference{border:0;border-radius:0;box-shadow:none;min-height:calc(100dvh - var(--tbh,78px));background:var(--cc-bg)}
:is(#tasksView,#boardsView,#galleryView,#teamsView,#usersView).tw-reference.active{display:grid;grid-template-columns:minmax(0,1fr) auto;grid-template-rows:auto minmax(0,1fr);align-content:start}
:is(#tasksView,#boardsView,#galleryView,#teamsView,#usersView).tw-reference>.cc-pagehead{grid-area:1/2;min-height:56px;margin:0;padding:7px 24px 7px 12px;justify-content:flex-end;gap:10px;border-bottom:1px solid var(--cc-line);background:var(--cc-surface)}
:is(#tasksView,#boardsView,#galleryView,#teamsView,#usersView).tw-reference>.cc-pagehead[hidden]{display:none}
:is(#tasksView,#boardsView,#galleryView,#teamsView,#usersView).tw-reference>.pg-tabs.cc-tabs{grid-area:1/1;display:flex;align-items:stretch;min-height:56px;min-width:0;gap:30px;padding:0 24px;flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none;background:var(--cc-surface)}
:is(#tasksView,#boardsView,#galleryView,#teamsView,#usersView).tw-reference>.cc-pagehead[hidden]+.pg-tabs{grid-column:1/-1}
:is(#tasksView,#boardsView,#galleryView,#teamsView,#usersView).tw-reference>.pg-tabs.cc-tabs button{display:inline-flex;align-items:center;flex:none;padding:0 0 1px;min-height:56px;font-size:15px;white-space:nowrap;border-bottom-width:3px}
:is(#tasksView,#boardsView,#galleryView,#teamsView,#usersView).tw-reference>:not(.cc-pagehead):not(.pg-tabs){grid-column:1/-1;min-width:0}
#tasksView.tw-reference>.cc-pagehead .cc-btn{font-size:14px;min-height:42px;padding:9px 16px;border-radius:7px;white-space:nowrap}
#tasksView.tw-reference-chat.active{height:calc(100dvh - var(--tbh,78px));min-height:0;overflow:hidden}
#tasksView.tw-reference-chat>.cc-workspace{grid-area:2/1/3/-1;grid-template-columns:clamp(270px,25.5%,390px) minmax(0,1fr);grid-template-rows:minmax(0,1fr);min-height:0;overflow:hidden}
#tasksView.tw-reference-chat .cc-contacts{display:block;min-height:0;padding:16px 12px 24px;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;background:linear-gradient(140deg,var(--cc-surface),color-mix(in srgb,var(--cc-bg) 55%,var(--cc-surface)))}
#tasksView.tw-reference-chat .cc-list-title{padding:0 12px 18px;font-size:20px;font-weight:600}
#tasksView.tw-reference-chat .cc-list-title .cc-count{font-size:12px;border-radius:20px;min-width:24px;line-height:24px;padding:0 5px}
#tasksView.tw-reference-chat .cc-search{min-height:48px;margin:0 4px 22px;padding:10px 15px;border-radius:28px;background:var(--cc-bg)}
#tasksView.tw-reference-chat .cc-search input{font-size:16px}
#tasksView.tw-reference-chat .cc-section-label{font-size:11px;letter-spacing:1.1px;padding:0 12px;margin:20px 0 12px}
#tasksView.tw-reference-chat .cc-person{align-items:center;gap:14px;min-height:80px;padding:12px;margin:0 0 6px;border-radius:12px}
#tasksView.tw-reference-chat .cc-person .cc-avatar{width:54px;height:54px;border-radius:50%;flex:none;font-size:17px}
#tasksView.tw-reference-chat .cc-person-name{font-size:16px;line-height:1.4;font-weight:600}
#tasksView.tw-reference-chat .cc-person-message{font-size:14px;line-height:1.45;margin-top:5px}
#tasksView.tw-reference-chat .cc-person-time{font-size:11px;flex:none}
#tasksView.tw-reference-chat .cc-selected{background:var(--cc-mint);border-color:color-mix(in srgb,var(--cc-green) 18%,transparent)}
#tasksView.tw-reference-chat .cc-list-foot{font-size:12px;line-height:1.6;margin:24px 12px 0;padding-top:18px}
#tasksView.tw-reference-chat .cc-chat{min-height:0;overflow:hidden;border-radius:0;background:var(--cc-bg)}
#tasksView.tw-reference-chat .cc-chathead{flex:none;min-height:74px;padding:10px 24px;gap:12px;background:var(--cc-surface)}
#tasksView.tw-reference-chat .cc-chathead>.cc-flex{gap:15px;min-width:0}
#tasksView.tw-reference-chat .cc-chathead .cc-avatar{width:54px;height:54px;border-radius:50%;font-size:18px;flex:none}
#tasksView.tw-reference-chat .cc-chathead h2{font-size:20px;font-weight:600;line-height:1.35}
#tasksView.tw-reference-chat .cc-chathead small{display:block;font-size:14px;line-height:1.5;margin-top:2px}
#tasksView.tw-reference-chat .cc-direct-label{font-size:14px;white-space:nowrap}
#tasksView.tw-reference-chat .cc-context{flex:none;min-height:48px;padding:11px 24px;font-size:14px;background:var(--cc-surface)}
#tasksView.tw-reference-chat .cc-context .cc-icon{width:19px;height:19px}
#tasksView.tw-reference-chat .cc-thread{flex:1;min-height:0;overflow:hidden}
#tasksView.tw-reference-chat .cc-thread>.cc-messages{flex:1 1 0%;min-height:80px;padding:24px 24px 18px;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;gap:18px;background:linear-gradient(145deg,color-mix(in srgb,var(--cc-surface) 28%,var(--cc-bg)),var(--cc-bg))}
#tasksView.tw-reference-chat .cc-date{font-size:13px;gap:20px}
#tasksView.tw-reference-chat .conv-empty.cc-empty{font-size:15px;line-height:1.8;margin:auto 0;padding:24px 12px}
#tasksView.tw-reference-chat .cc-thread .cc-message-author{font-size:13px}
#tasksView.tw-reference-chat .cc-message .cc-bubble{font-size:16px;line-height:1.6;padding:11px 15px}
#tasksView.tw-reference-chat .cc-message-action{font-size:13px}
#tasksView.tw-reference-chat .cc-compose-wrap{display:flex;flex-direction:column;flex:0 1 auto;min-height:0;max-height:65%;padding:17px 24px 20px;border-top:1px solid var(--cc-line);overflow-y:auto;overscroll-behavior:contain;background:linear-gradient(145deg,var(--cc-surface),color-mix(in srgb,var(--cc-bg) 40%,var(--cc-surface)))}
#tasksView.tw-reference-chat .cc-chat .cc-compose{display:flex;flex-direction:column;flex:1;min-height:0;border:0;border-radius:0;box-shadow:none;padding:0;background:transparent}
#tasksView.tw-reference-chat .cc-type-tabs{flex:none;gap:8px;margin:0 0 10px;flex-wrap:wrap}
#tasksView.tw-reference-chat .cc-type{font-size:14px;min-height:38px;padding:7px 10px;border-radius:8px;gap:7px}
#tasksView.tw-reference-chat .cc-type .cc-icon{width:18px;height:18px}
#tasksView.tw-reference-chat .cc-compose .conv-box textarea{font-size:16px;line-height:1.6;min-height:64px;max-height:140px}
#tasksView.tw-reference-chat .cc-compose .cc-input{font-size:14px;min-height:40px;padding:9px 11px}
#tasksView.tw-reference-chat .cc-compose .cc-send{font-size:14px;min-height:40px;padding:8px 15px}
#tasksView.tw-reference-chat .cc-compose .conv-note{font-size:12px}
#tasksView.tw-reference-chat .cc-compose-wrap:has([data-tw-kind="all-tasks"][aria-pressed="true"]){flex:0 0 65%;min-height:280px;max-height:75%;overflow:hidden}
#tasksView.tw-reference-chat .tw-all-tasks{flex:1;max-height:none;margin:0;gap:12px;font-size:14px}
#tasksView.tw-reference-chat .tw-all-tasks-head{position:relative;min-height:0;height:0}
#tasksView.tw-reference-chat .tw-all-tasks-head :is(h3,p){display:none}
#tasksView.tw-reference-chat .tw-all-tasks-head>.cc-count{position:absolute;right:0;top:0;font-size:12px}
#tasksView.tw-reference-chat .tw-all-tasks-filters{gap:10px;padding-bottom:12px}
#tasksView.tw-reference-chat .tw-all-task-statuses{gap:7px;padding-right:50px}
#tasksView.tw-reference-chat .tw-all-tasks-filters [data-tw-all-status]{font-size:13px;min-height:36px;padding:7px 10px}
#tasksView.tw-reference-chat .tw-all-tasks-filters :is(input,select){font-size:14px;min-height:42px;padding:10px 12px}
#tasksView.tw-reference-chat .tw-all-task-list{flex:1;min-height:0;padding:5px 2px 0}
#tasksView.tw-reference-chat .tw-all-tasks-empty{font-size:14px;min-height:130px}
#tasksView.tw-reference-chat .tw-all-task-card [data-tw-all-open]{font-size:15px}
#tasksView.tw-reference-chat .tw-all-task-detail{font-size:13px}
#tasksView.tw-reference-chat .cc-task-fields :is(input,select){font-size:14px!important;min-height:40px}
#tasksView.tw-reference-chat .cc-field label{font-size:12px}
#tasksView.tw-reference-chat>.cc-inbox{position:absolute;right:16px;top:64px;z-index:10;width:min(440px,calc(100% - 32px));max-height:calc(100% - 80px);overflow:auto;border:1px solid var(--cc-line);border-radius:10px;box-shadow:var(--shadow-pop)}
@media(max-width:1100px){
  #tasksView.tw-reference-chat>.cc-workspace{grid-template-columns:270px minmax(0,1fr)}
  #tasksView.tw-reference-chat .cc-person{gap:10px;padding:10px 8px}
  #tasksView.tw-reference-chat .cc-person .cc-avatar{width:44px;height:44px;font-size:15px}
  #tasksView.tw-reference-chat .cc-person-name{font-size:15px}
  #tasksView.tw-reference-chat .cc-person-message{font-size:13px}
}
@media(min-width:701px){#tasksView.tw-reference-chat .cc-mobile-list-only .cc-chat{display:flex}}
@media(max-height:760px){#tasksView.tw-reference-chat .tw-all-tasks-empty{min-height:72px;padding:10px 12px}}
@media(max-width:700px){
  :is(#tasksView,#boardsView,#galleryView,#teamsView,#usersView).tw-reference>.cc-pagehead{padding:7px 12px}
  :is(#tasksView,#boardsView,#galleryView,#teamsView,#usersView).tw-reference>.pg-tabs.cc-tabs{gap:18px;padding:0 14px}
  :is(#tasksView,#boardsView,#galleryView,#teamsView,#usersView).tw-reference>.pg-tabs.cc-tabs button{font-size:13px}
  #tasksView.tw-reference-chat{grid-template-columns:minmax(0,1fr);grid-template-rows:auto auto minmax(0,1fr)}
  #tasksView.tw-reference-chat>.cc-pagehead{grid-area:1/1;border-bottom:0;min-height:48px}
  #tasksView.tw-reference-chat>.pg-tabs.cc-tabs{grid-area:2/1;min-height:44px}
  #tasksView.tw-reference-chat>.pg-tabs.cc-tabs button{min-height:44px}
  #tasksView.tw-reference-chat>.cc-workspace{grid-area:3/1;grid-template-columns:minmax(0,1fr)}
  #tasksView.tw-reference-chat .cc-contacts{display:none}
  #tasksView.tw-reference-chat .cc-mobile-list-only .cc-contacts{display:block}
  #tasksView.tw-reference-chat .cc-mobile-list-only .cc-chat{display:none}
  #tasksView.tw-reference-chat .cc-mobile-back{display:inline-flex;flex:none}
  #tasksView.tw-reference-chat .cc-chathead{min-height:64px;padding:10px 14px}
  #tasksView.tw-reference-chat .cc-chathead .cc-avatar{width:42px;height:42px;font-size:15px}
  #tasksView.tw-reference-chat .cc-chathead h2{font-size:17px}
  #tasksView.tw-reference-chat .cc-chathead small{font-size:12px}
  #tasksView.tw-reference-chat .cc-direct-label{display:none}
  #tasksView.tw-reference-chat .cc-context{min-height:40px;padding:8px 14px;font-size:12px}
  #tasksView.tw-reference-chat .cc-thread>.cc-messages{padding:16px 14px;min-height:60px}
  #tasksView.tw-reference-chat .cc-compose-wrap{padding:10px 12px;max-height:66%}
  #tasksView.tw-reference-chat .cc-compose-wrap:has([data-tw-kind="all-tasks"][aria-pressed="true"]){flex-basis:60%;min-height:180px;overflow-y:auto}
  #tasksView.tw-reference-chat .tw-all-tasks{flex:none;min-height:270px}
  #tasksView.tw-reference-chat .cc-type{font-size:12px;padding:5px 7px;gap:4px}
  #tasksView.tw-reference-chat .tw-all-tasks-filters :is(#twAllTaskSearch,#twAllTaskOwner){flex-basis:140px;width:auto}
}
