/* My Investigation workbench, 0.1.120 */

/* The participant hub and workbench share one wide desktop frame. */
body.cdse-my-investigation-page .cd-investigations {
    width: calc(100% - 40px) !important;
    max-width: 1180px !important;
    margin: 28px auto 22px !important;
}

/* Starting context remains available without taking over the returning-user view. */
body.cdse-my-investigation-page .cd-starting-investigation-compact {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}
body.cdse-my-investigation-page .cd-starting-investigation-compact > summary {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 4px 0;
    color: #3040b0;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    list-style: none;
}
body.cdse-my-investigation-page .cd-starting-investigation-compact > summary::-webkit-details-marker { display: none; }
body.cdse-my-investigation-page .cd-starting-investigation-compact > summary::before {
    content: "▸";
    margin-right: 7px;
    font-size: 11px;
    transition: transform .15s ease;
}
body.cdse-my-investigation-page .cd-starting-investigation-compact[open] > summary::before { transform: rotate(90deg); }
body.cdse-my-investigation-page .cd-starting-investigation-body { padding: 12px 0 2px; }
body.cdse-my-investigation-page .cd-starting-investigation-body .cd-starting-grid { margin-top: 8px; }
body.cdse-my-investigation-page .cd-starting-investigation-body .cd-starting-question { margin-top: 9px; }
body.cdse-my-investigation-page .cd-starting-brief-full { margin-top: 14px; }
body.cdse-my-investigation-page .cd-starting-brief-full .cd-artifact-brief { margin-bottom: 2px; }

/* Main desktop workbench: adaptive Next Move workspace first, optional Guided Path second. */
body.cdse-my-investigation-page .cdse-investigation-workbench {
    width: calc(100% - 40px);
    max-width: 1180px;
    margin: 0 auto 42px;
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(320px, .78fr);
    gap: 24px;
    align-items: start;
}
body.cdse-my-investigation-page .cdse-workbench-main,
body.cdse-my-investigation-page .cdse-decision-rail,
body.cdse-my-investigation-page .cdse-workspace-panel { min-width: 0; }
body.cdse-my-investigation-page .cdse-decision-rail { grid-column: 1; grid-row: 1; }
body.cdse-my-investigation-page .cdse-workbench-main { grid-column: 2; grid-row: 1; }
body.cdse-my-investigation-page .cdse-workbench-tabs { display: none; }

/* The legacy Sprint renderer is now the guided evidence column, not a second page header. */
body.cdse-my-investigation-page .cd-sprint-wrap {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
}
body.cdse-my-investigation-page .cd-sprint-header,
body.cdse-my-investigation-page .cd-current-path { display: none !important; }
body.cdse-my-investigation-page .cd-next-day:not(.cd-sprint-complete) { display: none !important; }

body.cdse-my-investigation-page .cdse-evidence-heading { margin: 2px 0 14px; }
body.cdse-my-investigation-page .cdse-evidence-heading span {
    display: block;
    margin-bottom: 5px;
    color: #3040b0;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .09em;
    text-transform: uppercase;
}
body.cdse-my-investigation-page .cdse-evidence-heading h2 {
    margin: 0;
    color: #182230;
    font-size: 25px;
    line-height: 1.2;
    letter-spacing: -.02em;
}
body.cdse-my-investigation-page .cdse-evidence-heading p {
    margin: 6px 0 0 !important;
    color: #667085;
    font-size: 14px;
    line-height: 1.45;
}
body.cdse-my-investigation-page .cd-day-card {
    margin-bottom: 18px;
    padding: 24px;
}

/* Coach is the bridge between the guided steps and the evidence-based Decision Workspace. */
body.cdse-my-investigation-page .cdse-decision-rail .cdse-coach-card {
    width: 100%;
    max-width: none;
    margin: 0 0 16px;
    padding: 20px;
}
body.cdse-my-investigation-page .cdse-decision-rail .cdse-coach-card h2 { font-size: 23px; }
body.cdse-my-investigation-page .cdse-decision-rail .cdse-coach-message {
    max-width: none;
    margin: 8px 0 14px;
    font-size: 14px;
}
body.cdse-my-investigation-page .cdse-coach-decision-focus {
    margin-top: 16px;
    padding: 14px;
    border: 1px solid #d9e4ff;
    border-radius: 10px;
    background: #f5f7ff;
}
body.cdse-my-investigation-page .cdse-coach-decision-focus > span {
    display: block;
    margin-bottom: 4px;
    color: #3040b0;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .09em;
}
body.cdse-my-investigation-page .cdse-coach-decision-focus > strong {
    display: block;
    color: #182230;
    font-size: 16px;
    line-height: 1.3;
}
body.cdse-my-investigation-page .cdse-coach-decision-focus p {
    margin: 6px 0 8px !important;
    color: #475467;
    font-size: 13px;
    line-height: 1.45;
}
body.cdse-my-investigation-page .cdse-coach-decision-focus a {
    color: #3040b0;
    font-size: 13px;
    font-weight: 750;
    text-decoration: none;
}
body.cdse-my-investigation-page .cdse-coach-decision-focus a:hover,
body.cdse-my-investigation-page .cdse-coach-decision-focus a:focus { text-decoration: underline; }
body.cdse-my-investigation-page .cdse-decision-rail .cdse-coach-commitment { margin-top: 15px; padding-top: 13px; }
body.cdse-my-investigation-page .cdse-decision-rail .cdse-coach-commitment-actions { gap: 6px; }
body.cdse-my-investigation-page .cdse-decision-rail .cdse-coach-choice,
body.cdse-my-investigation-page .cdse-decision-rail .cdse-coach-pick-date > summary { font-size: 12px !important; }

/* Counselor assignment stays next to the Coach because both are intervention layers. */
body.cdse-my-investigation-page .cdse-decision-rail .cdse-managed-assignment {
    width: 100%;
    max-width: none;
    margin: 0 0 16px;
    padding: 16px;
}
body.cdse-my-investigation-page .cdse-decision-rail .cdse-managed-assignment h3 { font-size: 18px; }
body.cdse-my-investigation-page .cdse-decision-rail .cdse-managed-task { font-size: 14px; }

/* Decision Workspace is no longer hidden or labelled Advanced. */
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-shell {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 20px;
    border-radius: 14px;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-head {
    gap: 12px;
    margin-bottom: 14px;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-head h2 {
    margin-bottom: 5px;
    font-size: 22px;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-head p {
    font-size: 13px;
    line-height: 1.45;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-confidence {
    min-width: 94px;
    padding: 10px;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-confidence strong { font-size: 23px; }
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-stats {
    grid-template-columns: repeat(3, minmax(0,1fr));
    gap: 6px;
    margin: 12px 0 14px;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-stats > div { padding: 9px; }
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-stats strong { font-size: 17px; }

/* NEXT is surfaced as Decision Focus in the integrated Coach, avoiding duplicate instructions. */
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-next-step { display: none; }

body.cdse-my-investigation-page .cdse-workspace-panel .cdse-dialogue {
    margin: 14px 0 0;
    padding: 16px;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-dialogue-head h3 { font-size: 18px; }
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-dialogue-question {
    margin: 10px 0 12px;
    font-size: 15px;
    line-height: 1.45;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-dialogue-row { grid-template-columns: 1fr; }
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-checkin-options-grid { grid-template-columns: 1fr; }
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-checkin-submit { margin-top: 9px; }

/* Show the full interactive workspace in the rail without a second disclosure gate. */
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-mobile-disclosure {
    margin-top: 14px;
    border: 0;
    background: transparent;
    overflow: visible;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-mobile-disclosure > summary { display: none !important; }
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-mobile-disclosure-body {
    display: block;
    padding: 0;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-profile-form,
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-trail,
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-card {
    margin: 10px 0 0;
    padding: 14px;
    border-radius: 11px;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-profile-row,
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-form-two,
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-grid {
    grid-template-columns: 1fr;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-grid { margin-top: 0; }
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-card-head h3 { font-size: 17px; }
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-card-intro { margin-bottom: 9px; }
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-item {
    display: block;
    padding: 10px;
    font-size: 13px;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-pill {
    display: inline-flex;
    width: auto;
    max-width: 100%;
    margin-top: 7px;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-add-box > summary,
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-experiment details > summary {
    min-height: 38px;
    display: flex;
    align-items: center;
}
body.cdse-my-investigation-page .cdse-workspace-panel .cdse-trail { margin-top: 10px; }
body.cdse-my-investigation-page .cdse-workspace-panel input,
body.cdse-my-investigation-page .cdse-workspace-panel textarea,
body.cdse-my-investigation-page .cdse-workspace-panel select { max-width: 100%; }

/* Mobile/tablet modes: Coach stays visible; the user switches the larger content below it. */
@media (max-width: 980px) {
    body.cdse-my-investigation-page .cd-investigations {
        width: calc(100% - 32px) !important;
        max-width: 900px !important;
        margin-top: 22px !important;
    }
    body.cdse-my-investigation-page .cdse-investigation-workbench {
        width: calc(100% - 32px);
        max-width: 900px;
        display: flex;
        flex-direction: column;
        gap: 0;
    }
    body.cdse-my-investigation-page .cdse-workbench-tabs {
        order: 1;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 5px;
        margin: 0 0 14px;
        padding: 4px;
        border: 1px solid #dfe6ee;
        border-radius: 10px;
        background: #f4f6fa;
    }
    body.cdse-my-investigation-page .cdse-workbench-tab {
        min-height: 42px;
        border: 0;
        border-radius: 7px;
        background: transparent;
        color: #475467;
        font: inherit;
        font-size: 14px;
        font-weight: 750;
        cursor: pointer;
    }
    body.cdse-my-investigation-page .cdse-workbench-tab.is-active {
        background: #fff;
        color: #3040b0;
        box-shadow: 0 1px 3px rgba(23,32,59,.10);
    }
    body.cdse-my-investigation-page .cdse-workbench-tab:focus-visible {
        outline: 2px solid #3040b0;
        outline-offset: 2px;
    }

    body.cdse-my-investigation-page .cdse-decision-rail { display: contents; }
    body.cdse-my-investigation-page .cdse-decision-rail .cdse-coach-card {
        order: 2;
        width: 100%;
        margin: 0 0 16px;
    }
    body.cdse-my-investigation-page .cdse-decision-rail .cdse-managed-assignment {
        order: 3;
        margin: 0 0 16px;
    }
    body.cdse-my-investigation-page .cdse-workbench-main {
        order: 4;
        width: 100%;
    }
    body.cdse-my-investigation-page .cdse-workspace-panel {
        order: 5;
        width: 100%;
    }
    body.cdse-my-investigation-page .cdse-investigation-workbench.is-investigation-view .cdse-workspace-panel { display: none; }
    body.cdse-my-investigation-page .cdse-investigation-workbench.is-workspace-view .cdse-workbench-main { display: none; }
    body.cdse-my-investigation-page .cdse-investigation-workbench.is-workspace-view .cdse-workspace-panel { display: block; }
    body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-shell { padding: 20px; }
}

@media (max-width: 760px) {
    body.cdse-my-investigation-page .cd-investigations {
        width: calc(100% - 28px) !important;
        margin-top: 18px !important;
        padding: 19px 18px 16px !important;
    }
    body.cdse-my-investigation-page .cdse-investigation-workbench {
        width: calc(100% - 28px);
        margin-bottom: 30px;
    }
    body.cdse-my-investigation-page .cdse-evidence-heading h2 { font-size: 22px; }
    body.cdse-my-investigation-page .cd-day-card {
        padding: 19px;
        margin-bottom: 14px;
    }
    body.cdse-my-investigation-page .cdse-decision-rail .cdse-coach-card,
    body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-shell {
        padding: 18px;
    }
    body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-head h2 { font-size: 21px; }
    body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-head p { display: block; }
    body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-stats {
        display: grid;
        grid-template-columns: repeat(3, minmax(0,1fr));
    }
    body.cdse-my-investigation-page .cdse-workspace-panel .cdse-mobile-disclosure {
        border: 0;
        border-radius: 0;
        background: transparent;
    }
    body.cdse-my-investigation-page .cdse-workspace-panel .cdse-mobile-disclosure-body { padding: 0; }
}

@media (max-width: 430px) {
    body.cdse-my-investigation-page .cdse-workbench-tab { font-size: 13px; }
    body.cdse-my-investigation-page .cdse-workspace-panel .cdse-decision-stats { grid-template-columns: repeat(2, minmax(0,1fr)); }
    body.cdse-my-investigation-page .cdse-decision-rail .cdse-coach-commitment-actions { align-items: stretch; }
}

/* 0.1.176: next move is primary, seven-step path is optional structure. */
body.cdse-my-investigation-page .cdse-decision-rail .cdse-coach-loop-note { max-width: none; }
body.cdse-my-investigation-page .cdse-decision-rail .cdse-coach-guided-path { margin-top: 15px; padding-top: 13px; }
@media (max-width: 980px) {
    body.cdse-my-investigation-page .cdse-workbench-tab { padding-left: 8px; padding-right: 8px; }
}
