.causal-header{background:white;padding:24px 28px 0;border-bottom:1px solid var(--line)}.causal-heading{display:flex;align-items:center;justify-content:space-between;gap:24px}.causal-heading h1{font-family:Manrope,sans-serif;font-size:26px;letter-spacing:-.9px;margin:8px 0 5px;line-height:1.35}.causal-heading p{font-size:13px;color:#8b9882;margin:0 0 17px}.causal-heading>.actions{flex-wrap:wrap}.causal-tabs{display:flex;align-items:center;gap:27px;overflow:auto}.causal-tabs button{display:flex;align-items:center;gap:7px;padding:13px 0 15px;color:#8a9782;font-size:13px;white-space:nowrap;border-bottom:2px solid transparent}.causal-tabs button.active{color:#386a43;border-color:#386a43;font-weight:600}.causal-tabs .icon{width:16px;height:16px}.causal-canvas-actions{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 19px;background:#fff;border-bottom:1px solid var(--line);min-height:53px}.causal-canvas-actions>span{font-size:11px;color:#93a088}.causal-canvas-actions .btn{font-size:11px;padding:6px 9px}.causal-canvas-actions .btn .icon{width:15px;height:15px}.causal-canvas-actions .active{background:#eaf3e3}.causal-header~.editor-layout{height:calc(100dvh - 324px);min-height:410px}.causal-header~.editor-layout .canvas-wrap{min-height:290px}.causal-header~.editor-layout .graph{min-height:290px}.causal-header~.editor-layout .editor-main{min-height:0}.causal-header~.editor-layout .analysis{min-height:132px}.causal-header~.dag-variable-tray{height:42px}.dag-focus .causal-canvas-actions{height:55px;flex-shrink:0}.dag-focus .editor-layout{height:auto}.causal-empty{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);z-index:2;text-align:center;width:min(580px,87%);background:#fcfdfbf2;padding:24px;border:1px solid #ecf0e6;border-radius:12px}.causal-empty h2{font-family:Manrope,sans-serif;font-size:29px;letter-spacing:-1px;line-height:1.3;margin:17px 0 12px}.causal-empty>p{font-size:14px;line-height:1.8;color:#8b9a7f;margin:0 0 22px}.empty-entry-options{display:grid;grid-template-columns:1fr 1fr;gap:13px}.empty-entry-options button{background:white;border:1px solid #dce6d3;border-radius:8px;padding:20px 12px;display:flex;flex-direction:column;align-items:center;gap:9px;transition:box-shadow .2s,border-color .2s}.empty-entry-options button:hover{border-color:#8fac78;box-shadow:0 5px 20px #3569250c}.empty-entry-options button>.icon{color:#71905a;width:23px;height:23px}.empty-entry-options strong{font-size:15px;font-weight:600}.empty-entry-options span{font-size:11px;color:#93a484}.causal-empty>.text-link{margin:16px auto 0}.editable-inventory input,.editable-inventory textarea,.editable-inventory select{border:1px solid transparent;background:transparent;padding:7px 8px;font-size:14px;min-width:95px;width:100%;border-radius:5px}.editable-inventory textarea{min-height:55px;resize:vertical}.editable-inventory input:hover,.editable-inventory textarea:hover,.editable-inventory select:hover{border-color:#dce8d1;background:#fbfdf8}.editable-inventory input:focus,.editable-inventory textarea:focus,.editable-inventory select:focus{border-color:#a8bf98;background:white}.editable-inventory td{padding:12px 13px;vertical-align:top}.editable-inventory td small{padding-left:8px}.editable-inventory th:nth-child(1){width:22%}.editable-inventory th:nth-child(2){width:37%}.editable-inventory th:nth-child(3){width:16%}.quick-form .form-grid label{margin-top:14px}.quick-form label>input,.quick-form label>select{margin-top:7px}.quick-form details{margin:20px 0}.quick-form summary{font-size:13px}.quick-form .checkbox-line{margin-top:20px}.review-dialog{width:min(1330px,96vw);max-height:94dvh}.review-dialog .modal-body{padding:23px 25px 15px}.review-dialog .modal-footer{position:sticky;bottom:0;background:white;z-index:2}.review-summary{display:flex;align-items:center;justify-content:space-between;gap:20px}.review-summary h3{font-family:Manrope,sans-serif;font-size:23px;letter-spacing:-.7px;margin:12px 0 6px}.review-summary p{margin:0 0 18px;font-size:13px}.review-metric{text-align:center;min-width:90px}.review-metric strong{font-family:Manrope;font-size:38px;font-weight:500;color:#73955c;display:block}.review-metric span{font-size:11px;color:#96a488}.review-controls{display:flex;align-items:flex-end;gap:14px;padding:17px;background:#f5f8f0;border:1px solid #e2ead9;border-radius:8px}.review-controls label{margin:0;flex:1;font-size:11px;color:#8b9d7b}.review-controls label:nth-child(2){flex:1.6}.review-controls label:nth-child(3){flex:0 0 90px}.review-controls select,.review-controls input{display:block;width:100%;margin-top:7px;padding:8px 9px;border:1px solid #dce6d1;border-radius:5px;background:white;font-size:12px}.review-controls .btn{height:35px}.review-notice{display:flex;align-items:flex-start;gap:9px;margin:17px 0 20px;color:#829b6d;font-size:12px;line-height:1.7}.review-notice .icon{flex-shrink:0;margin-top:1px;width:17px}.review-table-bar{display:flex;align-items:center;justify-content:space-between;margin:13px 0;font-size:12px}.review-table-bar strong{font-weight:550}.review-table-bar button{font-size:11px;color:#64874f;padding:4px 8px}.variable-review-table{border:1px solid #e1e9d8;border-radius:7px;overflow:auto;max-height:49dvh}.variable-review-table table{table-layout:fixed;min-width:1060px}.variable-review-table th{position:sticky;top:0;z-index:1;padding:11px 9px;font-size:9px;letter-spacing:.7px}.variable-review-table th:nth-child(1){width:42px}.variable-review-table th:nth-child(2){width:19%}.variable-review-table th:nth-child(3){width:25%}.variable-review-table th:nth-child(4){width:16%}.variable-review-table th:nth-child(5){width:13%}.variable-review-table th:nth-child(6){width:23%}.variable-review-table td{padding:13px 8px;vertical-align:top;font-size:12px}.variable-review-table td>input:not([type=checkbox]),.variable-review-table textarea,.variable-review-table select{font-size:12px;width:100%;border:1px solid #e3eadb;padding:8px;border-radius:5px;margin-bottom:6px;background:#fff;line-height:1.5}.variable-review-table input[type=checkbox]{accent-color:#477c37;width:15px;height:15px;cursor:pointer;margin-top:11px}.variable-review-table textarea{min-height:74px;resize:vertical}.variable-review-table .source-id{font-family:ui-monospace,monospace;color:#8b9d7c;font-size:10px!important;background:#f8fbf3!important}.variable-review-table small{font-size:10px;color:#9caa8e}.variable-review-table p{font-size:11px;line-height:1.75;margin:0 0 8px;color:#8a9b7b}.variable-review-table details summary{font-size:11px;color:#9e844a;line-height:1.5}.variable-review-table details ul{padding-left:15px;margin:7px 0;font-size:11px;color:#a49068;line-height:1.75}.variable-review-table .excluded{background:#f7f9f3}.variable-review-table .excluded td:not(:first-child){opacity:.5}.review-bottom{display:flex;align-items:center;justify-content:space-between;gap:20px;margin:13px 0 0}.review-bottom label{font-size:12px}.review-bottom>span{font-size:11px;color:#9dac8e}.review-steps{display:flex;gap:12px;justify-content:space-between;padding:20px 0 5px;color:#7a9367;font-size:11px}.causal-header .btn{font-size:13px}.causal-header~.workflow-body .intro-row h2{font-size:27px}.causal-header .causal-tabs .count{font-size:10px}@media(max-width:1150px){.causal-heading h1{font-size:23px}.causal-heading>.actions{gap:7px}.causal-heading .btn{font-size:12px;padding:8px 10px}.causal-tabs{gap:22px}.causal-canvas-actions>span{display:none}.causal-canvas-actions{justify-content:flex-end}.causal-empty h2{font-size:25px}.causal-empty{padding:20px}.causal-heading p{font-size:12px}.causal-header{padding:21px 23px 0}}@media(max-width:700px){.causal-header{padding:18px 16px 0}.causal-heading{display:block}.causal-heading h1{font-size:22px}.causal-heading>.actions{margin:13px 0}.causal-heading p{font-size:11px}.causal-tabs{gap:22px}.causal-tabs button{font-size:12px}.causal-canvas-actions{padding:8px 10px;justify-content:flex-start;overflow-x:auto}.causal-canvas-actions .actions{gap:5px}.causal-canvas-actions .btn{font-size:10px;white-space:nowrap;padding:6px}.causal-canvas-actions .icon{display:none}.causal-header~.editor-layout{height:calc(100dvh - 352px);min-height:420px;display:block}.causal-header~.editor-layout .editor-main{height:100%}.causal-empty{width:92%;padding:19px 12px;top:55%}.causal-empty h2{font-size:22px;margin:13px 0}.causal-empty>p{font-size:12px;line-height:1.7;margin-bottom:15px}.empty-entry-options{gap:8px}.empty-entry-options button{padding:14px 6px}.empty-entry-options strong{font-size:12px}.empty-entry-options span{font-size:10px;line-height:1.6}.causal-empty>.tag{font-size:9px}.dag-variable-tray .micro{display:none}.review-dialog{width:98vw;max-height:96dvh}.review-dialog .modal-body{padding:17px 12px}.review-summary h3{font-size:18px}.review-summary p{font-size:12px}.review-metric strong{font-size:28px}.review-controls{display:grid;grid-template-columns:1fr 1fr;padding:12px;gap:10px}.review-controls label:nth-child(2){grid-column:2}.review-bottom{display:block}.review-bottom>span{display:block;margin-top:9px}.review-notice{font-size:11px}.review-steps{font-size:10px;gap:8px}.review-dialog .modal-footer{padding:13px}.review-dialog .modal-footer .btn{font-size:12px}.dag-focus .causal-canvas-actions{height:auto;min-height:50px}.dag-focus .causal-empty{top:50%}}@media print{.causal-header,.causal-canvas-actions,.dag-variable-tray,.causal-empty{display:none!important}}

/* Outcome-first setup and typed variable definitions. */
.setup-card{width:min(450px,86%);padding:23px 30px;text-align:left;box-shadow:0 12px 45px #31572a0b}
.setup-card h2{font-size:25px;margin:13px 0 8px}.setup-card>p{font-size:13px;line-height:1.6;margin-bottom:13px}.setup-card label{font-size:12px;margin:10px 0 6px;display:block}.setup-card input,.setup-card select{width:100%;background:white}.setup-card form>.btn{width:100%;justify-content:center;margin-top:12px}.setup-card>.text-link{justify-content:center;font-size:12px;margin-top:13px}.setup-card .error:empty{display:none}.quick-form #role-help{line-height:1.6;background:#f5f8ef;border-radius:6px;padding:10px 12px}.quick-form #coding-editor{margin:18px 0}.coding-heading{display:flex;justify-content:space-between;align-items:center}.coding-heading label{margin:0}.coding-labels,.coding-row{display:grid;grid-template-columns:90px minmax(0,1fr) 28px;gap:9px;align-items:center}.coding-labels{font-size:11px;color:#7f9073;margin:10px 0 7px}.coding-row{margin:7px 0}.coding-row input{min-width:0;width:100%}.quick-form .form-grid{gap:12px}.quick-form input[type=url]{min-width:0;width:100%}.panel-content>.section .text-link{margin:10px 0}.panel-content a.text-link{overflow-wrap:anywhere}.setup-card input:disabled{opacity:.5}@media(max-width:700px){.setup-card{padding:17px 20px}.setup-card h2{font-size:21px}.setup-card>p{font-size:12px}.quick-form .form-grid{grid-template-columns:1fr}.coding-labels,.coding-row{grid-template-columns:72px minmax(0,1fr) 25px}}

/* Role labels keep color meaning readable without relying on hue alone. */
.canvas-bottom .legend{flex-wrap:wrap;gap:7px 13px;max-width:calc(100% - 155px);max-height:66px;overflow:auto;font-size:12px;color:#53634e}.canvas-bottom .legend i{width:9px;height:9px;flex-shrink:0}.canvas-bottom{align-items:flex-end}.node.selected .node-box{stroke-width:2.6;filter:drop-shadow(0 0 5px #315a4740)}

/* Progressive detail keeps quick DAG creation lightweight. */
.variable-dialog[open]{display:flex;flex-direction:column;width:min(740px,calc(100vw - 28px));max-height:91dvh}.variable-dialog .modal-head,.variable-dialog .modal-footer{flex-shrink:0;background:white}.variable-dialog .modal-body{overflow-y:auto;min-height:0;padding:20px 25px}.variable-dialog .modal-footer{padding:15px 25px}.variable-dialog .quick-form label{font-size:14px}.variable-dialog .input,.variable-dialog textarea,.variable-dialog select{font-size:14px}.variable-dialog .micro{font-size:12px;line-height:1.6}.variable-basics{padding-bottom:7px}.variable-basics>#role-help{background:none;padding:0;margin:12px 0;color:#6b7963}.quick-form .optional-variable-section{border:1px solid #dce5d7;border-radius:9px;margin:13px 0;overflow:hidden}.optional-variable-section>summary{padding:16px;background:#f7faf4;cursor:pointer;font-size:15px;font-weight:600;list-style:none;display:flex;align-items:center;gap:10px}.optional-variable-section>summary:before{content:'›';font-size:20px;line-height:1;transition:transform .15s}.optional-variable-section[open]>summary:before{transform:rotate(90deg)}.optional-variable-section>summary::-webkit-details-marker{display:none}.optional-label{font-size:12px;font-weight:400;color:#738568;margin-left:auto}.optional-section-content{padding:0 18px 18px}.optional-section-content .section-explanation{font-size:14px;line-height:1.65;color:#68785f;margin:15px 0}.variable-dialog textarea{min-height:76px}.reference-entry,.source-mapping-entry{border-bottom:1px solid #e3eadf;padding:13px 0 17px;margin-bottom:11px}.entry-heading{display:flex;align-items:center;justify-content:space-between;font-size:12px;color:#697d5e}.reference-entry .form-grid label{margin-top:5px}.source-variable-row,.timepoint-entry{display:flex;align-items:center;gap:8px;margin:8px 0}.source-variable-row .input,.timepoint-entry .input{min-width:0;flex:1}.timepoint-entry .btn{white-space:nowrap}.analytic-timepoints{display:flex;flex-wrap:wrap;gap:7px;margin:12px 0}.analytic-timepoints label{display:flex;align-items:center;gap:8px;margin:0!important;padding:7px 11px;border:1px solid #d6e2cd;border-radius:6px;background:#f5f9f0}.analytic-timepoints input{width:auto;accent-color:#386a43}.representation-note{font-size:12px!important;line-height:1.6!important;color:#54774b!important;padding:10px 12px;background:#f1f7eb;border-radius:6px;margin-top:14px!important}.inventory-specification{text-align:left;font-size:13px;line-height:1.6;width:100%;padding:7px 8px;border-radius:5px}.inventory-specification:hover{background:#eef5e8}.inventory-specification small{padding-left:0!important;display:block}.specification-read{padding:14px 0;border-bottom:1px solid #e5ebdf}.specification-read .field-label{font-size:11px;letter-spacing:.5px}.specification-read .field-read{overflow-wrap:anywhere;white-space:normal}.plan-variable{border-top:1px solid #dce5d6;padding:20px 0}.plan-variable h4{font-size:17px;margin:0 0 6px}.plan-variable .specification-read{padding:9px 0;border:0}.plan-variable .field-label{font-weight:600;font-size:12px}.plan-variable .field-read{margin:4px 0;font-size:13px;line-height:1.7}.variable-dialog .text-link{font-size:13px}@media(max-width:700px){.variable-dialog .modal-body{padding:15px}.optional-section-content{padding:0 13px 14px}.optional-variable-section>summary{padding:13px;font-size:14px}.timepoint-entry{align-items:stretch;flex-direction:column}.variable-dialog .modal-head{padding:17px}.variable-dialog .modal-footer{padding:13px 15px}}

.feedback-banner{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:12px 20px;background:#edf4e8;border-bottom:1px solid #ccdcc2;color:#3b5933}.feedback-banner>div:first-child{display:flex;flex-direction:column;gap:3px}.feedback-banner strong{font-size:14px}.feedback-banner span{font-size:12px;line-height:1.5}.feedback-banner .actions{flex-shrink:0}.feedback-banner a{text-decoration:none}.feedback-preview .causal-header~.editor-layout{height:calc(100dvh - 400px)}.feedback-preview.dag-focus .editor-layout{height:auto}@media(max-width:900px){.feedback-banner{display:block;padding:12px 15px}.feedback-banner .actions{margin-top:9px;flex-wrap:wrap}.feedback-banner .btn{font-size:12px}.feedback-preview .causal-header~.editor-layout{height:auto;min-height:420px}}

.variable-dialog .field-example{font-size:13px;line-height:1.6;margin:6px 0 16px;color:#6a795f}.field-example>span{font-weight:600;color:#566e49}.variable-core-label{margin:0 0 9px;font-size:12px}.additional-variable-details>.optional-section-content{padding:0 13px 3px}.additional-subsection>summary{background:white;font-size:14px;font-weight:500}.additional-subsection .optional-section-content{padding:0 14px 15px}.additional-subsection .reference-entry:first-child{padding-top:4px}.additional-subsection .reference-entry:last-child{border-bottom:0}.additional-variable-details .section-explanation{font-size:13px}

.study-variable-choices{display:flex;flex-wrap:wrap;gap:7px;margin:10px 0}.study-variable-choices label{display:flex;gap:8px;align-items:center;padding:7px 10px;border:1px solid #dce5d7;border-radius:6px;margin:0!important;font-size:13px!important}.study-variable-choices input{width:auto;accent-color:#386a43}.source-mapping-entry .entry-heading strong{font-size:14px;color:#405a35}.timepoint-entry select{min-width:0;flex:1}
/* Variable editor: one decision per section, with editable study suggestions. */
.variable-dialog{width:min(740px,calc(100vw - 32px))}.variable-section{padding:23px 0;border-top:1px solid #e2e7de}.variable-section h3{font-size:15px;margin:22px 0 9px}.variable-section .section-kicker{margin-bottom:12px}.variable-section label,.variable-section input,.variable-section textarea,.variable-section select{max-width:100%}.variable-section .section-explanation{margin:8px 0 14px}.required-label{font-size:10px;color:#708266;font-weight:500;margin-left:5px}.analysis-row-head,.timepoint-fields{display:grid;grid-template-columns:1fr 1.7fr 32px;gap:10px;align-items:center}.analysis-row-head{font-size:11px;color:#6a7863;margin:15px 0 6px}.analysis-measure-row{padding:12px;background:#f6f8f3;border:1px solid #e0e6d9;border-radius:9px;margin-bottom:10px}.analysis-measure-row .input,.analysis-measure-row select{background:#fff}.analysis-measure-row .existing-variable-picker{font-size:11px;margin-top:9px}.analysis-measure-row .row-description{font-size:11px;margin-top:8px}.analysis-measure-row .row-description input{margin-top:4px}.existing-variable-picker select{margin:5px 0 8px}.construction-examples{margin:10px 0;color:#67745f;font-size:12px}.construction-examples summary{cursor:pointer}.temporal-review-banner{display:flex;align-items:center;justify-content:space-between;gap:15px;padding:12px 18px;background:#fff6df;border-bottom:1px solid #e6d7ae;color:#715726;font-size:12px}.temporal-review-banner p{margin:0}.arrow-review-row{border:1px solid #e3e6dd;border-radius:9px;padding:16px;margin:12px 0}.arrow-review-row h3{font-size:14px}.arrow-review-row .actions{margin-top:12px}.arrow-review-row select{max-width:100%}@media(max-width:600px){.timepoint-fields,.analysis-row-head{grid-template-columns:1fr 1.35fr 28px;gap:6px}.variable-dialog{width:calc(100vw - 16px)}.temporal-review-banner{align-items:flex-start;flex-direction:column}.analysis-measure-row .form-grid{grid-template-columns:1fr}}
/* Free text and known measures share one accessible, searchable name field. */
.variable-autocomplete{display:block;position:relative;min-width:0}.variable-autocomplete>.input{width:100%;box-sizing:border-box}.variable-suggestions{display:block;position:absolute;top:100%;left:0;right:0;min-width:min(340px,65vw);z-index:20;max-height:250px;overflow-y:auto;background:#fff;border:1px solid #cdd8c4;border-radius:8px;box-shadow:0 10px 26px #27372020;padding:5px;margin-top:4px;text-align:left;font-weight:400}.variable-suggestions[hidden]{display:none}.variable-suggestion{display:block;padding:10px 11px;border-radius:5px;cursor:pointer;font-size:13px;line-height:1.5;white-space:normal;overflow-wrap:anywhere;color:#475640}.variable-suggestion:hover,.variable-suggestion[aria-selected="true"]{background:#eef4e8;color:#2c4324}.variable-suggestion strong{font-size:14px;color:#2f4228}.variable-suggestion small{display:block;margin-top:3px;color:#77816f;font-size:11px}.analysis-measure-row:focus-within{position:relative;z-index:2}@media(max-width:600px){.variable-suggestions{min-width:0;max-height:210px}.timepoint-fields .variable-suggestions{left:auto;width:min(300px,70vw)}}
/* Compact specification form: a quarter-width name beside its description. */
.measure-definition-row{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,3fr);gap:14px;align-items:start;margin-top:18px}.measure-definition-row>div{min-width:0}.measure-definition-row label{display:block;min-height:34px;margin:0 0 6px}.measure-definition-row .input,.measure-definition-row textarea{margin:0;min-height:42px;height:42px;box-sizing:border-box}.measure-definition-row textarea{resize:vertical}.variable-dialog input::placeholder{color:#9a9fa5;opacity:1}.construction-variable-matrix{width:100%;table-layout:fixed;border-collapse:separate;border-spacing:0 8px;margin:8px 0}.construction-variable-matrix .source-name-column{width:25%}.construction-variable-matrix .source-remove-column{width:32px}.construction-variable-matrix th{font-size:12px;font-weight:600;text-align:left;text-transform:none;letter-spacing:0;background:transparent;padding:0 10px 2px 0;border:0}.construction-variable-matrix td{padding:0 10px 0 0;border:0;background:transparent;vertical-align:top;min-width:0}.construction-variable-matrix td:last-child{padding:0}.construction-variable-matrix input{width:100%;margin:0;min-height:42px}.construction-variable-matrix tr:hover td{background:transparent}.construction-variable-matrix .variable-autocomplete:focus-within{z-index:3}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}@media(max-width:540px){.measure-definition-row{grid-template-columns:minmax(0,1fr) minmax(0,3fr);gap:8px}.measure-definition-row label{font-size:12px;min-height:38px}.construction-variable-matrix .source-name-column{width:32%}.construction-variable-matrix th,.construction-variable-matrix td{padding-right:6px}}

.timepoint-variable-matrix .timepoint-column{width:18%}.timepoint-variable-matrix .timepoint-name-column{width:28%}
