/* Task details in Insights. Scoped to the detail dialog. */
.ai-detail-backdrop{position:fixed;inset:0;z-index:100000;display:flex;align-items:center;justify-content:center;padding:24px;background:rgba(12,27,48,.58)}
.ai-detail-dialog{display:flex;flex-direction:column;width:min(1080px,100%);max-height:min(900px,calc(100dvh - 48px));overflow:hidden;background:#fff;border:1px solid #d8e0ea;border-radius:14px;box-shadow:0 24px 70px rgba(8,25,48,.28);color:#24334a;font-family:inherit}
.ai-detail-header{display:flex;justify-content:space-between;align-items:flex-start;gap:24px;padding:25px 30px 19px}
.ai-detail-heading{min-width:0;flex:1}
.ai-detail-heading h2{margin:0;color:#14233d;font-size:clamp(20px,2vw,25px);font-weight:700;line-height:1.3;overflow-wrap:anywhere}
.ai-detail-reference{display:flex;flex-wrap:wrap;gap:8px 16px;margin-bottom:8px;color:#63748b;font-size:12px;font-weight:600;overflow-wrap:anywhere}
.ai-detail-badges{display:flex;flex-wrap:wrap;gap:8px;margin-top:13px}
.ai-detail-badge{display:inline-flex;align-items:center;gap:6px;padding:4px 10px;border:1px solid transparent;border-radius:999px;font-size:12px;line-height:1.35;font-weight:650}
.ai-detail-badge-complete{color:#12683c;background:#e8f6ee;border-color:#c9ead5}.ai-detail-badge-open{color:#805000;background:#fff5e2;border-color:#f5d9a2}.ai-detail-badge-open span{font-size:9px}.ai-detail-badge-neutral{color:#3c4c63;background:#f2f5f8;border-color:#dfe5ed}
.ai-detail-actions{display:flex;align-items:center;gap:9px;flex-shrink:0}.ai-detail-dialog .ai-detail-asana,.ai-detail-dialog .ai-detail-close{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-height:38px;border:1px solid #b9cbe0;border-radius:7px;background:#fff;color:#005eb8;font-size:13px;font-weight:650;line-height:1;text-decoration:none;cursor:pointer}.ai-detail-dialog .ai-detail-asana{padding:0 13px}.ai-detail-dialog .ai-detail-close{width:38px;padding:0;color:#43546a;border-color:transparent}.ai-detail-dialog .ai-detail-asana:hover,.ai-detail-dialog .ai-detail-close:hover{background:#edf5fc;color:#003f7d}.ai-detail-icon{width:16px;height:16px;flex-shrink:0}
.ai-detail-dialog :is(button,a):focus-visible{outline:3px solid #f9b000;outline-offset:2px}
.ai-detail-tabs{display:flex;flex-shrink:0;gap:3px;padding:0 29px;border-bottom:1px solid #dfe5ed;overflow-x:auto}.ai-detail-dialog .ai-detail-tab{position:relative;display:inline-flex;align-items:center;gap:7px;flex-shrink:0;padding:12px 15px 13px;border:0;border-bottom:3px solid transparent;background:transparent;color:#56677d;font-size:13px;font-weight:650;cursor:pointer}.ai-detail-dialog .ai-detail-tab:hover{color:#005eb8;background:#f5f9fd}.ai-detail-dialog .ai-detail-tab.is-active{color:#005eb8;border-bottom-color:#005eb8}.ai-detail-count,.ai-detail-section-count{display:inline-flex;align-items:center;justify-content:center;min-width:20px;height:20px;padding:0 6px;border-radius:999px;background:#e8f2fc;color:#005eb8;font-size:11px;font-weight:700}
.ai-detail-content{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain}.ai-detail-grid{display:grid;grid-template-columns:minmax(0,1fr) 260px;gap:0;min-height:320px}.ai-detail-main{min-width:0;padding:26px 30px 32px}.ai-detail-sidebar{min-width:0;padding:26px 28px 32px;background:#f8fafc;border-left:1px solid #e3e9f0}.ai-detail-section+.ai-detail-section{margin-top:32px}.ai-detail-dialog .ai-detail-section h3{margin:0 0 14px;color:#14233d;font-size:16px;line-height:1.35;font-weight:700}.ai-detail-description-text{color:#34445a;font-size:14px;line-height:1.65;white-space:pre-wrap;overflow-wrap:anywhere;word-break:break-word}.ai-detail-description-text a{color:#005eb8;text-decoration:underline;text-underline-offset:2px;overflow-wrap:anywhere;word-break:break-word}.ai-detail-muted{color:#68798f;font-size:13px}.ai-detail-progress{margin:0 0 12px}.ai-detail-side-section+.ai-detail-side-section{margin-top:22px;padding-top:20px;border-top:1px solid #e1e7ee}.ai-detail-dialog .ai-detail-side-section h3{margin:0 0 10px;color:#40516a;font-size:12px;font-weight:700;line-height:1.4}.ai-detail-person{display:flex;align-items:center;gap:9px;min-width:0;color:#27384e;font-size:13px;font-weight:600;overflow-wrap:anywhere}.ai-detail-person img,.ai-detail-person>div{width:24px;height:24px;flex-shrink:0}.ai-detail-followers{display:grid;gap:9px}.ai-detail-dates{display:grid;gap:9px;margin:0;font-size:13px}.ai-detail-dates>div{display:flex;justify-content:space-between;gap:12px}.ai-detail-dates dt{color:#68798f}.ai-detail-dates dd{margin:0;text-align:right;color:#27384e;font-weight:600}.ai-detail-projects{display:grid;gap:6px;margin:0;padding:0;list-style:none;color:#27384e;font-size:13px;overflow-wrap:anywhere}.ai-detail-existing-panel{padding:26px 30px 32px;overflow-wrap:anywhere}.ai-detail-existing-panel a{overflow-wrap:anywhere;word-break:break-word}
@media(max-width:700px){.ai-detail-backdrop{padding:0;align-items:stretch}.ai-detail-dialog{width:100%;max-height:100dvh;min-height:100dvh;border:0;border-radius:0}.ai-detail-header{gap:12px;padding:20px 18px 16px}.ai-detail-heading h2{font-size:19px}.ai-detail-actions{gap:2px}.ai-detail-dialog .ai-detail-asana{font-size:12px;padding:0 8px}.ai-detail-tabs{padding:0 10px}.ai-detail-dialog .ai-detail-tab{padding-left:10px;padding-right:10px}.ai-detail-grid{grid-template-columns:minmax(0,1fr)}.ai-detail-main{padding:22px 20px 26px}.ai-detail-sidebar{border-left:0;border-top:1px solid #e3e9f0;padding:22px 20px 28px}.ai-detail-existing-panel{padding:22px 20px 28px}}

/* AI summary inside the Insights task detail dialog. */
.ai-summary{padding:28px 30px 34px;max-width:900px}.ai-summary-header{display:flex;align-items:flex-start;justify-content:space-between;gap:20px}.ai-detail-dialog .ai-summary h3{margin:0;color:#14233d;font-size:18px;line-height:1.35;font-weight:700}.ai-summary-header p{margin:7px 0 0;color:#62738b;font-size:13px;line-height:1.5}.ai-summary-header .ai-summary-updated{font-size:12px}.ai-detail-dialog .ai-summary-generate{display:inline-flex;align-items:center;justify-content:center;gap:8px;flex-shrink:0;min-height:40px;padding:0 15px;border:1px solid #005eb8;border-radius:7px;background:#005eb8;color:#fff;font-size:13px;line-height:1.2;font-weight:700;cursor:pointer}.ai-detail-dialog .ai-summary-generate:hover:not(:disabled){background:#004b92}.ai-detail-dialog .ai-summary-generate:disabled{opacity:.62;cursor:wait}.ai-summary-note{margin:20px 0 0;color:#68798f;font-size:12px;line-height:1.5}.ai-summary-content,.ai-summary-empty,.ai-summary-state,.ai-summary-error,.ai-summary-saved{margin:18px 0 0;padding:15px 17px;border:1px solid #dfe7f0;border-radius:8px;font-size:14px;line-height:1.65}.ai-summary-content{color:#34445a;background:#f8fafc;white-space:pre-wrap;overflow-wrap:anywhere}.ai-summary-empty,.ai-summary-state{color:#5d7087;background:#f8fafc}.ai-summary-error{color:#a32626;background:#fff4f3;border-color:#f1cfca}.ai-summary-saved{color:#12683c;background:#eff9f2;border-color:#c9ead5;padding:8px 12px;font-size:13px}.ai-summary-spinner{width:15px;height:15px;border:2px solid rgba(255,255,255,.45);border-top-color:#fff;border-radius:50%;animation:ai-summary-spin .8s linear infinite}@keyframes ai-summary-spin{to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){.ai-summary-spinner{animation:none}}@media(max-width:700px){.ai-summary{padding:22px 20px 28px}.ai-summary-header{flex-direction:column;gap:14px}.ai-detail-dialog .ai-summary-generate{width:100%}}
