

/* CDI extra table */
.cdi-extra-table{
  width:100%;
  border-collapse:collapse;
  background:#fff;
}
.cdi-extra-table thead th{
  background: var(--accent-light);
  color: var(--accent2);
  font-weight:700;
  font-size:13px;
  padding:10px 8px;
  text-align:center;
  border-bottom:2px solid var(--accent);
}
.cdi-extra-table tbody td{
  padding:12px 8px;
  text-align:center;
  border-bottom:1px solid #f1f5f9;
  font-size:13px;
}

/* Risk weight indicators */
.risk-indicator {
  font-size: 10px;
  margin-left: 4px;
  vertical-align: middle;
}
.risk-critical { color: #ef4444; }
.risk-severe { color: #f97316; }
.risk-significant { color: #facc15; }
.risk-psychological { color: #2563eb; }
.protect-strong { color: #16a34a; }

.risk-legend {
  margin-top: 20px;
  padding: 12px 16px;
  background: #ffffff;
  border-radius: 8px;
  border: 1px solid var(--line);
  font-size: 11px;
  line-height: 1.8;
}
.risk-legend-title {
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 6px;
}
.legend-item {
  display: inline-block;
  margin-left: 16px;
}


  :root {
    --bg: #ffffff;
    --card: #ffffff;
    --ink: #1e293b;
    --muted: #64748b;
    --line: #B7DEE8;
    --accent: #215967;
    --accent2: #31869B;
    --accent-light: #DAEEF3;
    --accent-verylight: #F3FAFC;
    --danger: #D07876;
    --warn: #d97706;
  }
  body {
    margin: 0; padding: 24px;
    font-family: "Segoe UI", Tahoma, Arial, sans-serif;
    color: var(--ink);
    background: var(--bg);
  }
  .wrap { max-width: 1150px; margin: 0 auto; }
  h1 { 
    margin: 0 0 20px; 
    font-size: 24px; 
    color: var(--accent2);
    font-weight: 700;
  }
  h2 { 
    margin: 28px 0 12px; 
    font-size: 17px; 
    color: #fff;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent2) 100%);
    padding: 12px 18px;
    border-radius: 10px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(15, 118, 110, 0.15);
  }
  /* כותרות בממצאים - בהיר בימין וכהה בשמאל */
  #pane-findings h2 {
    background: linear-gradient(270deg, var(--accent2) 0%, var(--accent) 100%);
    color: #fff;
  }
  /* כותרת רמת הסיכון האובדני - אפור כהה */
  #pane-findings h2.risk-main-header {
    background: #374151;
    color: #fff;
    border-radius: 10px 10px 0 0;
    text-align: center;
    margin-bottom: 0;
  }
  .note { color: var(--muted); font-size: 13px; line-height: 1.5; }
  .card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
  }
  table {
    width: 100%;
    border-collapse: collapse;
    overflow: hidden;
    background: #fff;
  }
  thead th {
    background: var(--accent-light);
    color: var(--accent2);
    font-weight: 600;
    font-size: 13px;
    padding: 12px 10px;
    text-align: center;
    border-bottom: 2px solid var(--accent);
  }
  tbody td {
    padding: 12px 10px;
    vertical-align: top;
    font-size: 13px;
    border-bottom: 1px solid #f1f5f9;
  }
  tbody tr:last-child td { border-bottom: none; }
  tbody tr:hover { background: #fafbfc; }
  
  /* Columbia summary - Table 3 value row background */
  #columbia-components-table .cs-value{
    background: var(--accent-verylight);
  }
  #columbia-components-table .cs-values-row:hover td{
    background: var(--accent-verylight);
  }
.col-num { width: 40px; text-align: center; font-weight: 600; color: var(--accent2); }
  .col-q { min-width: 200px; }
  .col-q .muted { text-align: justify; font-size: 12px; }
  .col-small { width: 140px; }
.col-risk { font-size: 12px; line-height: 1.2; }
  .col-mini { width: 120px; }
  .muted { color: var(--muted); font-size: 12px; }
  select, input[type="text"], input[type="number"], textarea {
    width: 100%;
    box-sizing: border-box;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 8px 10px;
    font-size: 12px;
    outline: none;
    background: #fff;
    transition: border-color 0.2s, box-shadow 0.2s;
  }
  select.yn { font-size: 12px; }
  textarea { min-height: 56px; resize: vertical; }
  select:focus, input:focus, textarea:focus { 
    border-color: var(--accent); 
    box-shadow: 0 0 0 3px rgba(33, 89, 103, 0.15); 
  }
  .tight { margin-top: 8px; }
  .hidden { display: none !important; }
  .divider { height: 1px; background: var(--line); margin: 14px 0; }
  .kicker { font-size: 12px; color: var(--muted); }

  /* סגנון מיוחד לתיבות הממצאים */
  .interpretation-box {
    margin-top: 16px;
    padding: 14px;
    background: #EAF6F8;
    border-radius: 10px;
    border-right: 4px solid var(--accent);
  }
  .interpretation-box b {
    color: var(--accent2);
    font-size: 13px;
  }
  
  /* הסרת פונט מוטה כללי */
  i, em {
    font-style: normal;
  }
  
  /* שורות סינון בצהוב בהיר */
  .filterRow td {
    background: #FFFAEF;
  }

  

  /* CDI alert (yellow strip) */
  .cdi-alert{
    margin: 0 0 14px;
    padding: 12px 14px;
    border-radius: 10px;
    background: #FFFAEF;
    border-right: 4px solid #F59E0B;
    border-left: 4px solid #F59E0B;
    color: #92400E;
    font-size: 13px;
    line-height: 1.6;
  }

/* Tabs */
  .tabs {
    display: flex;
    gap: 6px;
    justify-content: space-between;
    align-items: stretch;
    margin-bottom: 14px;
    flex-wrap: nowrap;
  }
  .tab-btn{
    flex: 1 1 0;
    border: 0;
    cursor: pointer;
    padding: 12px 14px;
    border-radius: 12px;
    background: var(--accent);
    color: #fff;
    font-weight: 700;
    font-size: 13px;
    box-shadow: 0 2px 8px rgba(15, 118, 110, 0.12);
    transition: transform .06s ease, filter .2s ease, background .2s ease;
    white-space: nowrap;
    text-align: center;
  }
  
  /* Responsive tabs for smaller screens */
  @media (max-width: 900px) {
    .tabs {
      gap: 4px;
    }
    .tab-btn {
      padding: 10px 8px;
      font-size: 11px;
    }
  }
  @media (max-width: 700px) {
    .tabs {
      flex-wrap: wrap;
      gap: 6px;
    }
    .tab-btn {
      flex: 1 1 calc(33% - 6px);
      padding: 10px 6px;
      font-size: 11px;
    }
  }
  @media (max-width: 500px) {
    .tab-btn {
      flex: 1 1 calc(50% - 6px);
      font-size: 10px;
    }
  }
  
  .tab-btn:hover{ filter: brightness(1.05); }
  .tab-btn:active{ transform: translateY(1px); }
  .tab-btn.active{
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent2) 100%);
  }
  .tab-pane{ display:none; }
  .tab-pane.active{ display:block; }

  /* כפתורי פעולה */
  .action-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-bottom: 16px;
  }
  .mini-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 8px 16px;
    min-width: 90px;
    border-radius: 15px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    border: none;
    background: linear-gradient(135deg, #5bc0de 0%, #31869B 100%);
    color: #fff;
    box-shadow: 0 2px 6px rgba(49, 134, 155, 0.25);
  }
  .mini-btn:hover {
    background: linear-gradient(135deg, #31869B 0%, #215967 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(49, 134, 155, 0.4);
  }
  .mini-btn:active {
    transform: translateY(0);
  }
  .mini-btn.clear { }
  .mini-btn.clear:hover { }
  .mini-btn.print { }
  .mini-btn.save { }
  .mini-btn.save:hover { }
  @media print {
    .action-buttons { display: none !important; }
  }



/* Columbia summary tables: center headers and numeric columns */
#columbia-summary-card table thead th{
  text-align:center !important;
}
#columbia-summary-card table tbody td{
  vertical-align:top;
}
#columbia-summary-table th.col-small,
#columbia-summary-table td.col-small,
#columbia-injury-table th.col-mini,
#columbia-injury-table td.col-mini,
#columbia-injury-table th.col-small,
#columbia-injury-table td.col-small,
#columbia-components-table th,
#columbia-components-table td{
  text-align:center;
}
#columbia-summary-table th.col-q,
#columbia-summary-table td.col-q,
#columbia-injury-table th.col-q,
#columbia-injury-table td.col-q,
#columbia-components-table th.col-q,
#columbia-components-table td.col-q{
  text-align:right;
}


/* --- Columbia summary aesthetics --- */
.columbia-summary-wrap{margin-top:14px;}
.columbia-summary-wrap .section-title{
  margin:18px 0 10px;
  font-size:18px;
  font-weight:700;
}
.columbia-summary-wrap .card{
  margin-top:10px;
}
.columbia-summary-wrap table{
  width:100%;
  border-collapse:collapse;
  table-layout:fixed;
}
.columbia-summary-wrap th, .columbia-summary-wrap td{
  padding:10px 10px;
  border-bottom:1px solid var(--line);
}
.columbia-summary-wrap thead th{
  font-weight:700;
  background:rgba(0,0,0,0.03);
}
.columbia-summary-wrap tbody tr:last-child td{border-bottom:none;}
/* Column widths for symmetry */
#columbia-summary-table th.col-q, #columbia-summary-table td.col-q{width:42%;}
#columbia-summary-table th.col-small, #columbia-summary-table td.col-small{width:19.33%;}
#columbia-injury-table th.col-q, #columbia-injury-table td.col-q{width:42%;}
#columbia-injury-table th.col-mini, #columbia-injury-table td.col-mini{width:14%;}
#columbia-injury-table th.col-small, #columbia-injury-table td.col-small{width:16%;}
#columbia-components-table th.col-q, #columbia-components-table td.col-q{width:34%;}
#columbia-components-table th.col-mini, #columbia-components-table td.col-mini{width:16.5%;}
#columbia-components-table th.col-small, #columbia-components-table td.col-small{width:17%;}
/* Make the overall box match cards */
#cs-overall-box{
  margin-top:10px;
  padding:14px 14px;
  border:1px solid var(--line);
  border-radius:12px;
  background:rgba(0,0,0,0.02);
}
/* Ensure center alignment for headings already requested */
.columbia-summary-wrap table thead th{text-align:center !important;}


/* Center headers and data for Columbia tables */
.columbia-summary table thead th,
.columbia-summary table tbody td{
  text-align:center !important;
}
.columbia-summary table th.col-q,
.columbia-summary table td.col-q{
  text-align:right !important;
}


.columbia-summary-wrap{margin-top:18px;}
.columbia-summary-wrap > h2{margin-bottom:14px;}
.columbia-summary-wrap .card{margin-bottom:20px;}
.columbia-summary-wrap table{width:100%; table-layout:fixed;}
.columbia-summary-wrap thead th{text-align:center;}
.columbia-summary-wrap tbody td{text-align:center;}
.columbia-summary-wrap th.col-q,
.columbia-summary-wrap td.col-q{text-align:right;}
#cs-overall-box{
  margin-top:12px;
  padding:16px;
  border:1px solid var(--line);
  border-radius:12px;
  background:rgba(0,0,0,0.03);
}

.columbia-summary-wrap .card{margin-bottom:20px;}
.columbia-summary-wrap table thead th{text-align:center;}
.columbia-summary-wrap table tbody td{text-align:center;}
.columbia-summary-wrap th.col-q,
.columbia-summary-wrap td.col-q{text-align:right;}

/* COLUMBIA_REDESIGN_V1 */
.columbia-summary-wrap{margin-top:18px;}
.columbia-summary-wrap .section-title{margin:18px 0 12px; font-size:18px; font-weight:800;}
.columbia-summary-wrap .card{margin:0 0 18px; padding:0; overflow:hidden; border-radius:14px; border:1px solid var(--line); background:#fff;}
.columbia-summary-wrap table{width:100%; border-collapse:collapse; table-layout:fixed;}
.columbia-summary-wrap thead th{padding:10px 10px; text-align:center; font-weight:800; background:rgba(0,0,0,0.03); border-bottom:1px solid var(--line);}
.columbia-summary-wrap tbody td{padding:10px 10px; text-align:center; border-bottom:1px solid var(--line); vertical-align:top;}
.columbia-summary-wrap tbody tr:last-child td{border-bottom:none;}
.columbia-summary-wrap th.col-q,.columbia-summary-wrap td.col-q{text-align:right;}
#columbia-summary-table th.col-q,#columbia-summary-table td.col-q{width:42%;}
#columbia-summary-table th.col-small,#columbia-summary-table td.col-small{width:19.33%;}
#columbia-injury-table th.col-q,#columbia-injury-table td.col-q{width:42%;}
#columbia-injury-table th.col-mini,#columbia-injury-table td.col-mini{width:14%;}
#columbia-injury-table th.col-small,#columbia-injury-table td.col-small{width:16%;}
#columbia-components-table th.col-q,#columbia-components-table td.col-q{width:34%;}
#columbia-components-table th.col-mini,#columbia-components-table td.col-mini{width:16.5%;}
#columbia-components-table th.col-small,#columbia-components-table td.col-small{width:17%;}
#cs-overall-box{margin-top:4px; padding:16px; border:1px solid var(--line); border-radius:14px; background:rgba(0,0,0,0.03);}

/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}




  /* Tabs palette */
  .tabbar{
    margin-bottom: 18px;
  }
  .tab-btn{
    background: #B7DEE8 !important; /* inactive */
    color: #215967 !important;      /* dark teal text */
    border: 1px solid #92CDDC !important;
    box-shadow: 0 1px 0 rgba(0,0,0,0.03);
  }
  .tab-btn:hover{
    background: #92CDDC !important;
  }
  .tab-btn.active{
    background: linear-gradient(135deg, #215967 0%, #31869B 100%) !important; /* active */
    color: #ffffff !important;
    border-color: #215967 !important;
  }

/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}




  /* CDI compact layout */
  .cdi-item{ padding: 10px 10px !important; }
  .cdi-item-top{ margin-bottom: 6px !important; }
  .cdi-opts{ gap: 6px !important; }
  .cdi-opt{ padding: 8px 10px !important; }
  .cdi-num{ height: 30px !important; min-width: 40px !important; }
  .cdi-small{ font-size: 11px !important; }
  .cdi-opt b{ min-width: 22px !important; }

/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}




  /* Two-column layout for CDI questions */
  .cdi-grid{
    display: grid !important;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
  }

  /* On narrow screens, fall back to single column */
  @media (max-width: 900px){
    .cdi-grid{
      grid-template-columns: 1fr;
    }
  }

/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}




  /* Safety Plan */
  .sp-grid{
    display:grid;
    gap:10px;
  }
  .sp-row{
    display:grid;
    grid-template-columns: 48px 1fr 44px;
    gap:10px;
    align-items:center;
  }
  .sp-num{
    height: 38px;
    border-radius:10px;
    display:flex;
    align-items:center;
    justify-content:center;
    background: var(--accent-light);
    color: var(--accent);
    font-weight:800;
    border: 1px solid var(--line);
  }
  .sp-del{
    height:38px;
    border-radius:10px;
    border:1px solid var(--line);
    background:#fff;
    cursor:pointer;
    font-weight:800;
    color: var(--danger);
  }
  .sp-del:hover{ filter: brightness(0.98); }
  @media (max-width: 900px){
    #pane-safety .card > div[style*="grid-template-columns: 1fr 1fr"]{
      grid-template-columns: 1fr !important;
    }
  }

  @media print{
    body{ padding: 0 !important; }
    .tabs{ display:none !important; }
    .tab-pane{ display:none !important; }
    #pane-safety{ display:block !important; }
    #pane-safety .tab-btn{ display:none !important; }
    #pane-safety .card{ box-shadow:none !important; }
  }

  /* Safety Plan add-row button (not a tab button) */
  .sp-add-btn{
    border: 1px solid var(--line);
    background: var(--accent-light);
    color: var(--accent);
    cursor: pointer;
    padding: 10px 12px;
    border-radius: 12px;
    font-weight: 800;
    font-size: 13px;
    box-shadow: 0 1px 0 rgba(0,0,0,0.03);
    transition: transform .06s ease, filter .2s ease, background .2s ease;
  }
  .sp-add-btn:hover{ filter: brightness(0.98); }
  .sp-add-btn:active{ transform: translateY(1px); }


/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}





/* Safety Plan: unify 'הוספת שורה' button font */
#pane-safety button.sp-add,
#pane-safety button.add-row,
#pane-safety button.addRow,
#pane-safety button[data-action="add-row"]{
  font-family: "Segoe UI", Tahoma, Arial, sans-serif !important;
}


/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}





/* Safety Plan: smaller font for 'הוספת שורה' */
#pane-safety button.sp-add,
#pane-safety button.add-row,
#pane-safety button.addRow,
#pane-safety button[data-action="add-row"]{
  font-size: 12px !important;
}


/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}





@media print{
  /* Hide add-row UI in Safety Plan */
  #pane-safety button.sp-add,
  #pane-safety button.add-row,
  #pane-safety button.addRow,
  #pane-safety button[data-action="add-row"]{
    display: none !important;
  }

  /* Hide any helper/instruction text in Safety Plan */
  #pane-safety .sp-instructions,
  #pane-safety .note.sp-instructions,
  #pane-safety [data-sp-instructions="1"]{
    display:none !important;
  }
}


@media print{
  #pane-safety .sp-add-label{ display:none !important; }
}


/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}





@media print{
  #pane-safety [data-sp-instructions-container="1"]{
    display:none !important;
  }
}


/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}




/* Factor grouped cards */
.factor-grid{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:14px;
}
@media (max-width: 900px){
  .factor-grid{ grid-template-columns: 1fr; }
}
.factor-card{
  background:#fff;
  border:1px solid var(--line);
  border-radius:14px;
  overflow:hidden;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}
.factor-head{
  background: var(--accent-light);
  color: var(--accent2);
  font-weight:800;
  padding:12px 12px;
  border-bottom:1px solid var(--line);
}
.factor-list{
  list-style:none;
  margin:0;
  padding:8px 10px 12px;
  display:grid;
  gap:8px;
}
.factor-row{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  padding:10px 10px;
  border:1px solid #e2e8f0;
  border-radius:12px;
  background:#fafafa;
  cursor:pointer;
  transition: filter .15s ease, transform .06s ease, border-color .15s ease;
}
.factor-row:hover{
  filter: brightness(1.02);
  border-color: var(--line);
}
.factor-row:active{ transform: translateY(1px); }
.factor-text{
  font-size:13px;
  line-height:1.45;
  color: var(--ink);
}
.factor-row input[type="checkbox"]{
  margin-top:2px;
  width:18px; height:18px;
  accent-color: var(--accent2);
  cursor:pointer;
}

/* Findings 3-column table */
.findings-grid{
  display:grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap:14px;
}
@media (max-width: 1000px){
  .findings-grid{ grid-template-columns: 1fr; }
}
.findings-col{
  background:#fff;
  border:1px solid var(--line);
  border-radius:14px;
  overflow:hidden;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}
.findings-col-head{
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent2) 100%);
  color:#fff;
  padding:12px 12px;
  font-weight:900;
}
.findings-body{
  padding:10px 12px 12px;
}
.findings-cat{
  margin:10px 0 6px;
  font-weight:800;
  color: var(--accent2);
  font-size:13px;
}
.findings-item{
  padding:8px 10px;
  border:1px solid #e2e8f0;
  border-radius:12px;
  background:#fafafa;
  margin-bottom:8px;
  font-size:13px;
  line-height:1.45;
}
.findings-empty{
  color: var(--muted);
  font-size:13px;
  padding:6px 2px;
}

/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}




.linear-section{ margin-bottom:16px; }
.linear-head{
  font-weight:700;
  font-size:13px;
  color:var(--accent2);
  border-bottom:2px solid var(--line);
  padding-bottom:4px;
  margin-bottom:8px;
}
.linear-list{
  display:grid;
  gap:5px;
}
.linear-item{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:10px;
  padding:6px 10px;
  border:1px solid #e2e8f0;
  border-radius:8px;
  background:#fafafa;
  cursor:pointer;
  font-size:12px;
}
.linear-item:hover{ filter:brightness(1.02); }
.linear-item input{ margin-top:2px; width:14px; height:14px; accent-color:var(--accent2); }

/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}




.other-row{
  display:flex;
  gap:10px;
  align-items:center;
}
.other-input{
  flex:1;
  padding:10px;
  border:1px solid #e2e8f0;
  border-radius:10px;
}
.other-del{
  border:1px solid #e2e8f0;
  background:#fff;
  color:#b91c1c;
  border-radius:10px;
  padding:8px 10px;
  cursor:pointer;
}
.other-add{
  margin-top:6px;
  align-self:flex-start;
  border:1px solid var(--line);
  background:var(--accent-light);
  color:var(--accent);
  border-radius:12px;
  padding:8px 12px;
  cursor:pointer;
}

.other-list{
  position:relative;
}
.other-add{
  font-size:12px;
  padding:6px 10px;
  border-radius:999px;
  position:relative;
  float:right;
}

/* Manual 'Other' rows layout */
.other-row{
  display:grid;
  grid-template-columns: 28px 1fr 42px;
  gap:10px;
  align-items:center;
}
.other-check{
  display:flex;
  align-items:center;
  justify-content:center;
}
.other-check input{
  width:18px; height:18px;
  accent-color: var(--accent2);
}
.other-input{
  width:100%;
  box-sizing:border-box;
  padding:10px 12px;
  border:1px solid #e2e8f0;
  border-radius:12px;
  background:#fff;
}
.other-controls{
  display:flex;
  justify-content:flex-end;
  margin-top:6px;
}
.other-add{
  font-size:12px;
  padding:6px 10px;
  border-radius:999px;
  border:1px solid var(--line);
  background:var(--accent-light);
  color:var(--accent);
  cursor:pointer;
}
.other-add:hover{ filter:brightness(0.98); }
.other-del{
  height:38px;
  border-radius:12px;
  border:1px solid #e2e8f0;
  background:#fff;
  cursor:pointer;
  font-weight:900;
  color: var(--danger);
}

/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}




/* COLUMBIA_REDESIGN_V2 — professional separation for the 3 summary tables */
.columbia-summary-wrap .cs-card{
  border-radius:16px;
  overflow:hidden;
  border:1px solid var(--line);
  background:#fff;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}
.columbia-summary-wrap .cs-card-head{
  padding:12px 14px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent2) 100%);
  color:#fff;
  font-weight:900;
  font-size:14px;
}
.columbia-summary-wrap .cs-card-body{
  padding:0;
  overflow-x:auto;
}
.columbia-summary-wrap .cs-card-body table{
  margin:0;
}
.columbia-summary-wrap .cs-card tbody tr:nth-child(even) td{
  background: rgba(218, 238, 243, 0.25);
}
.columbia-summary-wrap .cs-card td.col-q{
  font-weight:800;
  color: var(--accent);
  background: rgba(218, 238, 243, 0.45);
}
.columbia-summary-wrap .cs-card thead th{
  background: var(--accent-light) !important;
  color: var(--accent2) !important;
  border-bottom: 2px solid var(--accent) !important;
}
.columbia-summary-wrap .cs-card th, 
.columbia-summary-wrap .cs-card td{
  border-bottom: 1px solid #eaf2f5 !important;
}
.columbia-summary-wrap .cs-card tbody tr:last-child td{ border-bottom:none !important; }
.columbia-summary-wrap .cs-card + .cs-card{ margin-top:16px; }

.columbia-summary-wrap .section-title{ text-align:center; }
.columbia-summary-wrap .cs-card tbody td:first-child{ background: var(--accent-light) !important; font-weight:800; }
.columbia-summary-wrap .cs-card tbody td:not(:first-child){ background: var(--accent-verylight) !important; }

/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}





/* AUTHORITATIVE: Table 3 (components) – set entire 2nd row to #DAEEF3 */
#columbia-components-table tbody tr:nth-child(2) td,
#columbia-components-table tbody tr.cs-values-row td{
  background: #DAEEF3 !important;
  background-color: #DAEEF3 !important;
  color: var(--ink) !important;
}
#columbia-components-table tbody tr:nth-child(2):hover td,
#columbia-components-table tbody tr.cs-values-row:hover td{
  background: #DAEEF3 !important;
  background-color: #DAEEF3 !important;
}




/* Findings tab - Table 3: lighter 2nd row under headers */
#columbia-components-table tbody tr:nth-child(2) td,
#columbia-components-table tbody tr.cs-values-row td{
  background: var(--accent-verylight) !important;
  background-color: var(--accent-verylight) !important;
  color: var(--ink) !important;
}
#columbia-components-table tbody tr:nth-child(2):hover td,
#columbia-components-table tbody tr.cs-values-row:hover td{
  background: var(--accent-verylight) !important;
  background-color: var(--accent-verylight) !important;
}



/* AUTHORITATIVE: Columbia Summary Table 1 column widths (shrink category, widen month/life, widen risk text col) */
#columbia-summary-table{ table-layout: fixed !important; }
#columbia-summary-table thead th:nth-child(2),
#columbia-summary-table tbody td:nth-child(2){ width: 18% !important; }
#columbia-summary-table thead th:nth-child(3),
#columbia-summary-table tbody td:nth-child(3){ width: 18% !important; }
#columbia-summary-table thead th:nth-child(4),
#columbia-summary-table tbody td:nth-child(4){ width: 34% !important; } /* risk column */
#columbia-summary-table thead th:nth-child(1),
#columbia-summary-table tbody td:nth-child(1){ width: 30% !important; } /* category column */



/* Findings: CDI copy table under Table 3 — keep symmetric 6 columns */
##cdi-extra-table-copy{
  width:100%;
  table-layout:fixed;
  border-collapse:collapse;
}
#cdi-extra-table-copy thead th,
#cdi-extra-table-copy tbody td{
  text-align:center;
}
#cdi-extra-table-copy thead th{ width:16.66%; }



/* PATCH v60: CDI copy table - make value row light and non-bold (including מצב רוח נגטיבי <br><span>(A)</span>) */
#cdi-extra-table-copy tbody td{
  background: var(--accent-verylight) !important;
  font-weight: normal !important;
  color: var(--ink) !important;
}
#cdi-extra-table-copy tbody td.muted{
  color: var(--muted) !important;
}

/* PATCH v60: Match category column widths between Columbia Table 1 and Table 2, and widen last (text) column */
#columbia-summary-table{ table-layout: fixed !important; }
#columbia-summary-table th:nth-child(1), #columbia-summary-table td:nth-child(1){ width: 26% !important; }
#columbia-summary-table th:nth-child(2), #columbia-summary-table td:nth-child(2){ width: 18% !important; }
#columbia-summary-table th:nth-child(3), #columbia-summary-table td:nth-child(3){ width: 18% !important; }
#columbia-summary-table th:nth-child(4), #columbia-summary-table td:nth-child(4){ width: 38% !important; }

#columbia-injury-table{ table-layout: fixed !important; }
#columbia-injury-table th:nth-child(1), #columbia-injury-table td:nth-child(1){ width: 26% !important; }
#columbia-injury-table th:nth-child(2), #columbia-injury-table td:nth-child(2){ width: 14% !important; }
#columbia-injury-table th:nth-child(3), #columbia-injury-table td:nth-child(3){ width: 14% !important; }
#columbia-injury-table th:nth-child(4), #columbia-injury-table td:nth-child(4){ width: 14% !important; }
#columbia-injury-table th:nth-child(5), #columbia-injury-table td:nth-child(5){ width: 32% !important; }




/* Header alignment & sizing */
.columbia-summary-wrap .section-title{
  font-size: 14px !important; /* match CDI card head */
  text-align: center !important;
}
.columbia-summary-wrap .cs-card-head{
  text-align: center !important;
}




/* Match category column width between Columbia table 1 and table 2 */
#columbia-summary-table th:nth-child(1),
#columbia-summary-table td:nth-child(1){
  width:26% !important;
}



/* Findings tab: force identical category column widths for Table 1 + Table 2 */
#pane-findings #columbia-summary-table,
#pane-findings #columbia-injury-table{
  table-layout: fixed !important;
}

/* Category column (קטגוריה) */
#pane-findings #columbia-summary-table th.col-q,
#pane-findings #columbia-summary-table td.col-q,
#pane-findings #columbia-injury-table th.col-q,
#pane-findings #columbia-injury-table td.col-q{
  width:26% !important;
}

/* Table 1 (Summary) – distribute remaining width */
#pane-findings #columbia-summary-table th.col-small,
#pane-findings #columbia-summary-table td.col-small{
  width:auto !important;
}
#pane-findings #columbia-summary-table thead th:nth-child(2),
#pane-findings #columbia-summary-table tbody td:nth-child(2){ width:18% !important; }
#pane-findings #columbia-summary-table thead th:nth-child(3),
#pane-findings #columbia-summary-table tbody td:nth-child(3){ width:18% !important; }
#pane-findings #columbia-summary-table thead th:nth-child(4),
#pane-findings #columbia-summary-table tbody td:nth-child(4){ width:38% !important; } /* text-rich risk col */



/* Findings - Table 1: add 'Examiner feelings' column */
#pane-findings #columbia-summary-table{ table-layout: fixed !important; }
#pane-findings #columbia-summary-table th.col-notes,
#pane-findings #columbia-summary-table td.col-notes{
  width: 30% !important;
  text-align: right !important;
  vertical-align: top !important;
}
#pane-findings #columbia-summary-table td.col-notes textarea{
  min-height: 160px;
  resize: vertical;
}



#pane-findings th{
  white-space: normal !important;
  line-height: 1.3;
}



#pane-findings #columbia-summary-table th.col-notes{
  text-align:center !important;
}
#pane-findings #columbia-summary-table,
#pane-findings #columbia-injury-table{
  table-layout: fixed !important;
}
#pane-findings #columbia-summary-table thead th,
#pane-findings #columbia-injury-table thead th{
  white-space: normal !important;
  line-height: 1.25;
}



#pane-findings #columbia-summary-table,
#pane-findings #columbia-injury-table{
  table-layout: fixed !important;
  width:100% !important;
}

/* Force exact same widths column-by-column */
#pane-findings #columbia-summary-table col,
#pane-findings #columbia-injury-table col{
  width:20% !important;
  max-width:20% !important;
  min-width:20% !important;
}



/* Findings: now only 2 visible tables (components + injury) */
#pane-findings #columbia-components-table,
#pane-findings #columbia-injury-table{
  width:100%;
  table-layout: fixed;
}

/* Components table: 6 equal-ish columns; last (verbal) a bit wider */
#pane-findings #columbia-components-table colgroup{ display:none; } /* if any stray */
#pane-findings #columbia-components-table thead th{
  white-space: normal;
  line-height: 1.25;
}
#pane-findings #columbia-components-table th:nth-child(1),
#pane-findings #columbia-components-table td:nth-child(1){ width:16%; }
#pane-findings #columbia-components-table th:nth-child(2),
#pane-findings #columbia-components-table td:nth-child(2){ width:14%; }
#pane-findings #columbia-components-table th:nth-child(3),
#pane-findings #columbia-components-table td:nth-child(3){ width:14%; }
#pane-findings #columbia-components-table th:nth-child(4),
#pane-findings #columbia-components-table td:nth-child(4){ width:14%; }
#pane-findings #columbia-components-table th:nth-child(5),
#pane-findings #columbia-components-table td:nth-child(5){ width:14%; }
#pane-findings #columbia-components-table th:nth-child(6),
#pane-findings #columbia-components-table td:nth-child(6){ width:28%; }

/* Metrics row label cells */
#pane-findings #columbia-components-table .cs-label{
  font-weight: 600;
  color: var(--muted);
  background: var(--accent-verylight);
}
#pane-findings #columbia-components-table .cs-metric{
  background: var(--accent-verylight);
}

/* Injury table: allow header wrapping */
#pane-findings #columbia-injury-table thead th{
  white-space: normal;
  line-height: 1.25;
}



/* Lighter header divider for findings tables */
#pane-findings table thead th{
  border-bottom: 1px solid #E5EEF3 !important;
}



/* Dark header style for risk table title */
.risk-header-dark{
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent2) 100%);
  color:#fff !important;
  font-weight:700;
  font-size:15px;
  padding:12px 14px;
  text-align:center;
}



/* Light header style for findings sections (match CDI light header) */
.findings-head-light{
  background: var(--accent-light) !important;
  color: var(--accent2) !important;
  font-size:13px !important;
  font-weight:700 !important;
  padding:10px 12px !important;
}



/* Findings: subheaders of first & second tables – light style like 'מצב רוח נגטיבי (A)' */
#pane-findings table thead th{
  background: var(--accent-light) !important;
  color: var(--accent2) !important;
  font-size:13px !important;
  font-weight:700 !important;
  border-bottom: 1px solid var(--line) !important;
}



.risk-main-header{
  margin: 28px 0 14px;
  padding: 14px 18px;
  background: #374151;
  color: #ffffff;
  font-size: 18px;
  font-weight: 700;
  border-radius: 12px;
  text-align: center;
}



/* FORCE remove any divider or border below footer text */
#pane-findings .divider:last-of-type{ display:none !important; }
#pane-findings div[style*="border-bottom"]{ border-bottom:none !important; }
#pane-findings .footer-note{ border-bottom:none !important; }



/* Hide fatal-attempts table by default */
#columbia-injury-table.hidden { display: none !important; }



/* Sticky tabs */
.tabs{
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--bg);
  padding-top: 8px;
  padding-bottom: 8px;
}

/* prevent content jump */
.wrap{
  scroll-margin-top: 90px;
}

/* Disable sticky in print */
@media print{
  .tabs{
    position: static !important;
  }
}



/* Force very light turquoise for Q1–Q2 rows (override filterRow yellow) */
#ideation-row-1 td,
#ideation-row-2 td{
  background: var(--accent-verylight) !important;
}



.dual-sev-wrap{
  display:flex;
  justify-content: space-between;
  align-items: stretch;
  gap: 14px;
  margin: 14px 0 18px 0;
}
.dual-sev-box{
  flex: 0 0 calc(50% - 7px);
  border: 1px solid rgba(0,0,0,0.12);
  border-radius: 14px;
  padding: 14px 16px;
  background: #fff;
  text-align: center;
}
.dual-sev-box .t{
  font-size: 15px;
  font-weight: 800;
  color:#111;
  line-height: 1.25;
}
.dual-sev-box .s{
  font-size: 12px;
  color:#6b7280;
  margin-top: 4px;
}
.dual-sev-box .v{
  margin-top: 10px;
  font-size: 20px;
}
@media (max-width: 900px){
  .dual-sev-wrap{ flex-direction: column; }
  .dual-sev-box{ flex: 1 1 auto; max-width: 100% !important; width: 100%; }
}



/* FIX: keep dual severity boxes inside form and perfectly aligned */
.dual-sev-wrap{
  width:100%;
  max-width:100%;
  box-sizing:border-box;
}
.dual-sev-box{
  flex: 1 1 0;
  max-width: calc(50% - 7px);
  box-sizing: border-box;
}
@media (max-width: 900px){
  .dual-sev-box{
    max-width: 100%;
    width: 100%;
  }
}



/* Refinements requested */
.dual-sev-box{
  padding: 10px 14px !important; /* slightly lower height */
}
.dual-sev-box .t{
  color: var(--accent2) !important; /* turquoise like table subheaders */
}
.dual-sev-box .v{
  font-size: 17px !important; /* smaller than before */
  margin-top: 8px !important;
}



/* Sync font sizes with table subheader (e.g., 'כוונה') */
.dual-sev-box .t{
  font-size: 13px !important;
  font-weight: 700 !important;
}
.dual-sev-box .v{
  font-size: 13px !important;
}



.dual-sev-box .v{
  color:#000;
  font-weight:400;
}
.dual-sev-box .v.has-value{
  font-weight:700;
}



/* Force identical red for 'גבוהה מאוד!' in intensity box */
#intensity_section *:contains("גבוהה מאוד!"),
#intensity_section span,
#intensity_section div{
  color: #ef4444 !important;
}



/* FIX: Intensity box 'גבוהה מאוד!' must be RED (same as 'גבוהה'), not dark red */
#pane-findings .dual-sev-wrap .dual-sev-box.intensity .v,
#pane-findings #intensity_section .v,
#pane-findings #intensity_section .value,
#pane-findings #intensity_section [data-role="intensity-value"]{
  color: #ef4444 !important;
  font-weight: 700 !important;
}



/* AUTHORITATIVE FIX:
   Force 'גבוהה מאוד!' in INTENSITY box to regular red (not dark red) */

/* Remove any dark-red influence */
#pane-findings #intensity_section *{
  text-shadow: none !important;
}

/* Force color explicitly */
#pane-findings #intensity_section .v,
#pane-findings #intensity_section span,
#pane-findings #intensity_section div{
  color: #ef4444 !important; /* regular red */
  font-weight: 700 !important;
}



/* Align severity with intensity:
   'גבוהה ביותר!' in SEVERITY box should be dark red */

/* Dark red tone */
#pane-findings #severity_section .v,
#pane-findings #severity_section span,
#pane-findings #severity_section div{
  color: #7f1d1d !important; /* dark red */
  font-weight: 700 !important;
}



/* Very high level styling – light red background + red border */
.dual-sev-box.very-high{
  border: 2px solid #ef4444 !important; /* red border */
  background: #fdecec !important;       /* very light red background */
}

/* Red text inside */
.dual-sev-box.very-high .v,
.dual-sev-box.very-high .alert-text{
  color: #ef4444 !important;
  font-weight: 700 !important;
}

/* Alert line under intensity */
.dual-sev-box .alert-text{
  margin-top: 6px;
  font-size: 12px;
}



/* Findings box: uniform text size (except the label 'ממצאים:') */
.interpretation-box{
  font-size: 11px !important;
  line-height: 1.5 !important;
}
.interpretation-box .kicker,
.interpretation-box div{
  font-size: 11px !important;
  font-weight: 400 !important;
}
/* Inner bold labels (שכיחות, משך, etc.) stay small but bold */
.interpretation-box .kicker b,
.interpretation-box div b{
  font-size: 11px !important;
  font-weight: 700 !important;
}
/* Keep only the main title label emphasized at original size */
.interpretation-box > b{
  font-size: 13px !important;
  font-weight: 700 !important;
}



/* Intensity findings box: force exactly 2 lines */
#intensity_section #interp_text .intensity-line1,
#intensity_section #interp_text .intensity-line2{
  display:block;
}
#intensity_section #interp_text .intensity-line2{
  white-space: nowrap;          /* keep deterrents+reasons together */
  overflow: hidden;
  text-overflow: ellipsis;      /* if too long, cut gracefully instead of wrapping to 3rd line */
}



/* Findings: emphasize VERY HIGH severity & intensity boxes with red border + glow */
#pane-findings .dual-sev-box.very-high{
  border: 2px solid #ef4444 !important;
  box-shadow:
    0 0 0 2px rgba(220,38,38,0.25),
    0 4px 12px rgba(220,38,38,0.35) !important;
}



/* Make VERY HIGH boxes look like Columbia findings box (light pink bg + side stripe) */
#pane-findings .dual-sev-box.very-high{
  background: #fdecec !important;              /* light pink */
  border: 1px solid #f3b6b6 !important;
  border-right: 4px solid #ef4444 !important;  /* side stripe */
  box-shadow: none !important;
}



/* Aesthetic override: VERY HIGH boxes – subtle light red, clean side stripe, gentle emphasis */
#pane-findings .dual-sev-box.very-high{
  background: #fff5f5 !important;              /* very light red */
  border: 1px solid #f2c2c2 !important;        /* soft red border */
  border-right: 4px solid #ef4444 !important;  /* clear side stripe */
  box-shadow: 0 1px 3px rgba(0,0,0,0.04),
              0 0 0 1px rgba(220,38,38,0.10) inset !important;
}
#pane-findings .dual-sev-box.very-high .t{
  color: var(--accent2) !important;            /* keep header turquoise like rest */
}
#pane-findings .dual-sev-box.very-high .v{
  color: #ef4444 !important;                   /* red value text */
  font-weight: 700 !important;
}



/* Base style: dual severity boxes – clean side stripe like Columbia findings */
#pane-findings .dual-sev-box{
  position: relative;
}



/* Clean, continuous side stripe (like Columbia findings box) */
#pane-findings .dual-sev-box{
  border-right: 4px solid var(--accent2) !important; /* turquoise */
}

/* VERY HIGH: red side stripe */
#pane-findings .dual-sev-box.very-high{
  border-right-color: #ef4444 !important;
}



/* Clean continuous side stripes on BOTH sides (like Columbia findings, mirrored) */
#pane-findings .dual-sev-box{
  border-right: 4px solid var(--accent2) !important; /* turquoise */
  border-left: 4px solid var(--accent2) !important;  /* turquoise */
}

/* VERY HIGH: both stripes turn red */
#pane-findings .dual-sev-box.very-high{
  border-right-color: #ef4444 !important;
  border-left-color: #ef4444 !important;
}



/* FIX: keep identical stripe width on both sides when VERY HIGH */
#pane-findings .dual-sev-box{
  box-sizing: border-box;
}

#pane-findings .dual-sev-box.very-high{
  border-left-width: 4px !important;
  border-right-width: 4px !important;
}



/* When VERY HIGH: make box titles black */
#pane-findings .dual-sev-box.very-high .t{
  color: #000000 !important;
}



/* Findings: behavior table matches Columbia summary tables */
#pane-findings #columbia-behavior-table{
  width:100%;
  table-layout: fixed;
  margin-top: 0;
}
#pane-findings #columbia-behavior-table thead th{
  white-space: normal !important;
  line-height: 1.25;
}
#pane-findings #columbia-behavior-table tbody td{
  text-align:center;
  background: var(--accent-verylight) !important;
  color: var(--ink) !important;
}
#pane-findings #columbia-behavior-table tbody td.muted{
  color: var(--muted) !important;
}



#pane-findings #behavior-risk-alert{
  font-size: 13px !important;
  font-weight: 600 !important;
  line-height: 1.6 !important;
}



/* Findings tab: add breathing room between the red interpretation box and the next attempts table */
#pane-findings #behavior-risk-alert{ margin-bottom: 16px !important; }
#pane-findings #columbia-injury-table{ margin-top: 16px !important; }



#pane-findings #columbia-injury-table{
  width:100% !important;
  table-layout: fixed !important;
}
#pane-findings #columbia-injury-table thead th,
#pane-findings #columbia-injury-table tbody td{
  text-align:center;
}
#pane-findings #columbia-injury-table th.col-q,
#pane-findings #columbia-injury-table td.col-q{
  text-align:right;
}



/* Columbia TOC: behavior subcategories (smaller + not bold) */
#cs-toc .cs-toc-subcats{ margin-top:6px; margin-bottom:6px; }
#cs-toc .cs-toc-subcat{
  font-size: 12px !important;
  font-weight: 400 !important;
  opacity: 0.95;
}



#pane-columbia #cs-toc{ width:200px !important; flex:0 0 200px !important; }

/* main categories – smaller font, bold */
#pane-columbia #cs-toc a.cs-toc-link{
  font-size:11px !important;
  font-weight:700 !important;
}

/* subcategories */
#pane-columbia #cs-toc .cs-toc-subcat,
#pane-columbia #cs-toc .cs-toc-sublink{
  font-size:11px !important;
  font-weight:400 !important;
}

/* tighter spacing */
#pane-columbia #cs-toc .cs-toc-subcats{
  margin-top:2px !important;
  margin-bottom:3px !important;
}



#pane-personal .personal-input,
#pane-personal .personal-select,
#pane-personal .personal-textarea {
  width: 100%;
  box-sizing: border-box;
  border: 1.5px solid var(--line);
  border-radius: 8px;
  padding: 7px 10px;
  font-size: 12px;
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
  color: var(--ink);
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}
#pane-personal .personal-input:focus,
#pane-personal .personal-select:focus,
#pane-personal .personal-textarea:focus {
  border-color: var(--accent2);
  box-shadow: 0 0 0 3px rgba(49, 134, 155, 0.13);
}
#pane-personal .personal-label {
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--accent);
  font-size: 11.5px;
  display: block;
}
#pane-personal .personal-textarea {
  min-height: 220px;
  resize: vertical;
  text-align: justify;
  line-height: 1.8;
  font-size: 13px;
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
}
#pane-personal .personal-textarea::placeholder {
  font-size: 11px;
  color: #b0bec5;
}
#pane-personal .personal-input::placeholder,
#pane-personal .personal-select::placeholder {
  font-size: 11px;
  color: #b0bec5;
}



#pane-columbia #cs-layout{display:flex; gap:16px; align-items:flex-start; flex-direction:row-reverse;}
#pane-columbia #cs-content{flex:1; min-width:0;}
#pane-columbia #cs-toc{width:200px; flex:0 0 200px; position:sticky; top:92px; align-self:flex-start; max-height: calc(100vh - 120px); overflow:auto;}
#pane-columbia #cs-toc .cs-toc-card{border:1px solid rgba(0,0,0,0.08); border-radius:14px; padding:12px 16px 12px 12px; background: rgba(255,255,255,0.85); backdrop-filter: blur(6px);}
#pane-columbia #cs-toc .cs-toc-title{font-weight:900; font-size:14px; margin-bottom:8px; color: var(--accent2); padding-right:0; padding-bottom:8px; border-bottom:1px solid var(--line);}
#pane-columbia #cs-toc .cs-toc-nav{display:flex; flex-direction:column; gap:2px;}
#pane-columbia #cs-toc a.cs-toc-link{display:block; text-decoration:none; padding:6px 0; border-radius:10px; color: var(--accent2); font-weight:800; font-size:11px;}
#pane-columbia #cs-toc .cs-toc-sub{display:flex; flex-direction:column; gap:0px; padding:2px 0 4px 0;}
#pane-columbia #cs-toc .cs-toc-sublink{font-weight:700; font-size:12.5px; padding:4px 0; color: var(--accent2); text-decoration:none; border-bottom:none;}
#pane-columbia #cs-toc .cs-toc-sublink::before{content:"●"; font-size:6px; margin-left:6px; vertical-align:middle;}
#pane-columbia #cs-toc a:hover{background: rgba(0, 166, 170, 0.10);}
#pane-columbia #cs-toc a.cs-toc-disabled{opacity:0.35; pointer-events:none; background: transparent; color: rgba(17,24,39,0.55);}
@media (max-width: 1100px){
  #pane-columbia #cs-toc{width:200px; flex:0 0 200px; position:sticky; top:92px; align-self:flex-start; max-height: calc(100vh - 120px); overflow:auto;}
  #pane-columbia #cs-layout{display:flex; gap:16px; align-items:flex-start; flex-direction:row-reverse;}
}
@media (max-width: 800px){
  #pane-columbia #cs-toc{display:none;}
  #pane-columbia #cs-layout{display:block;}
  #pane-columbia #cs-content{width:100%;}
}



  .cdi-wrap{ margin-top: 6px; }
  .cdi-header{
    display:flex; gap:12px; flex-wrap:wrap; align-items:center; justify-content:space-between;
    margin-bottom: 12px;
  }
  .cdi-score{
    display:flex; gap:10px; align-items:center; flex-wrap:wrap;
    padding:10px 12px; border:1px solid var(--line); border-radius:12px; background:#fff;
  }
  .cdi-pill{
    display:inline-flex; align-items:center; gap:8px;
    padding:8px 10px; border-radius:999px; background: var(--accent-light);
    color: var(--accent); font-weight:700; font-size:13px;
    border: 1px solid var(--line);
  }
  .cdi-grid{ display:grid; gap:12px; }
  .cdi-item{
    border:1px solid var(--line);
    border-radius:14px;
    padding:12px 12px;
    background:#fff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
    transition: background 0.2s ease;
  }
  .cdi-item.answered{
    background: var(--accent-light);
  }
  .cdi-item-top{
    display:flex; align-items:flex-start; justify-content:space-between; gap:10px; margin-bottom:8px;
  }
  .cdi-num{
    min-width:44px; height:34px;
    display:flex; align-items:center; justify-content:center;
    border-radius:10px;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent2) 100%);
    color:#fff; font-weight:800;
  }
  .cdi-opts{ display:grid; gap:8px; margin-top: 6px; }
  .cdi-opt{
    display:flex; gap:10px; align-items:flex-start;
    padding:10px 10px;
    border:1px solid #e2e8f0;
    border-radius:12px;
    background:#fafafa;
    cursor:pointer;
    transition: transform .04s ease, filter .15s ease, border-color .15s ease, background .15s ease;
  }
  .cdi-opt:hover{ filter: brightness(1.02); border-color: var(--line); }
  .cdi-opt:active{ transform: translateY(1px); }
  .cdi-opt input{ margin-top: 3px; }
  .cdi-opt b{
    color: var(--accent2);
    min-width: 26px;
    text-align:center;
    display:inline-block;
  }
  .cdi-footnote{
    margin-top: 10px;
    color: var(--muted);
    font-size: 12px;
    line-height:1.6;
  }
  .cdi-actions{ display:flex; gap:10px; flex-wrap:wrap; align-items:center; }
  .cdi-btn{
    border:0; cursor:pointer;
    padding:10px 12px;
    border-radius:12px;
    background: var(--accent);
    color:#fff;
    font-weight:700;
    font-size:13px;
    box-shadow: 0 2px 8px rgba(15, 118, 110, 0.12);
  }
  .cdi-btn.secondary{ background:#7fd1c7; }
  .cdi-btn:active{ transform: translateY(1px); }
  .cdi-summary{
    margin-top: 12px;
    padding: 12px;
    border-radius: 12px;
    background: #EAF6F8;
    border-right: 4px solid var(--accent);
    border: 1px solid var(--line);
  }
  

  /* CDI findings severity colors */
  .cdi-find-none{
    background:#ECFDF5 !important;
    border-right-color:#22C55E !important;
    color:#065F46 !important;
  }
  .cdi-find-mild{
    background:#FFFBEB !important;
    border-right-color:#F59E0B !important;
    color:#92400E !important;
  }
  .cdi-find-mod{
    background:#FFF7ED !important;
    border-right-color:#FB923C !important;
    color:#9A3412 !important;
  }
  .cdi-find-sev{
    background:#FEF2F2 !important;
    border-right-color:#EF4444 !important;
    color:#991B1B !important;
  }
  
  /* סגנון תא הערכה מילולית CDI בממצאים */
  #cdi-extra-table-copy tbody td#cdi_verbal_eval {
    color: #000 !important;
  }
  /* צבעי רקע לתא לפי רמת דיכאון + bold */
  #cdi-extra-table-copy tbody td#cdi_verbal_eval.cdi-eval-none { background-color: #d1fae5 !important; font-weight: 700; }
  #cdi-extra-table-copy tbody td#cdi_verbal_eval.cdi-eval-mild { background-color: #fef3c7 !important; font-weight: 700; }
  #cdi-extra-table-copy tbody td#cdi_verbal_eval.cdi-eval-mod { background-color: #fed7aa !important; font-weight: 700; }
  #cdi-extra-table-copy tbody td#cdi_verbal_eval.cdi-eval-sev { background-color: #fecaca !important; font-weight: 700; }

.cdi-summary b{ color: var(--accent2); }
  .cdi-small{ font-size: 12px; color: var(--muted); }

  /* Findings tile: make the light-blue box fill the entire tile */
  .cdi-item.cdi-findings{ display:flex; }
  .cdi-item.cdi-findings .cdi-opts{ flex:1; display:flex; margin-top:0; }
  .cdi-item.cdi-findings .cdi-summary{
    flex:1;
    margin:0;
    display:flex;
    flex-direction:column;
    justify-content:flex-start; /* top */
    align-items:flex-start;     /* right in RTL */
    text-align:right;
  }


/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}





/* CDI extra-compact tuning */
.cdi-item{
  padding:8px 10px !important;
}
.cdi-item-top{
  margin-bottom:4px !important;
}
.cdi-num{
  min-width:36px !important;
  height:28px !important;
  font-size:13px !important;
}
.cdi-small{
  font-size:11px !important;
}
.cdi-opt{
  padding:6px 8px !important;
}
.cdi-opt b{
  min-width:20px !important;
  font-size:12px !important;
}
.cdi-opt div{
  font-size:12px !important;
  line-height:1.35 !important;
}


/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}




#cdi_findings_box{
  display:flex;
  align-items:center;
  justify-content:center;
}
#cdi_findings_text{
  text-align:center;
  font-weight:600;
}

/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}




#cdi_findings_box{ text-align:center; }

/* Columbia table 3 – uniform value row */
#columbia-components-table .light-row td {
  background: var(--accent-verylight);
  color: var(--muted);
  font-weight: normal;
}


/* Fix: password modal input - placeholder centered, typing LTR */
/* Password modal input: placeholder centered (RTL Hebrew), typed text LTR */
#enc-modal-password {
  direction: ltr;
  text-align: center;
}
#enc-modal-password::placeholder {
  direction: rtl;
  text-align: center;
  color: #9ca3af;
}

/* ==========================================
   FINDINGS PANE — NEW DESIGN (v2)
   ========================================== */

/* Section shell */
.f-section {
  background: #fff;
  border-radius: 12px;
  border: 1px solid #d1dce0;
  margin-bottom: 12px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0,0,0,0.07);
}
.f-section-head {
  padding: 11px 18px;
  display: flex;
  align-items: center;
  gap: 9px;
  background: #D4E8EE;
  border-bottom: 1px solid #a8cdd8;
}
.f-section-head .f-icon {
  font-size: 16px; flex-shrink: 0;
}
.f-section-head .f-title {
  font-size: 13px; font-weight: 700; color: #215967;
}
.f-section-body { padding: 16px 18px; }

/* Risk section — matches other sections, body color set dynamically by JS */
.f-section.f-risk-section { border: 1px solid #d1dce0; }
.f-section.f-risk-section .f-section-head {
  background: #D4E8EE;
  border-bottom: 1px solid #a8cdd8;
  justify-content: flex-start;
}
.f-section.f-risk-section .f-title {
  font-size: 13px; color: #215967; letter-spacing: 0;
}
.f-risk-body-wrap {
  transition: background 0.4s ease;
  border-radius: 0 0 12px 12px;
}

/* Columbia section body inner shadow */
.f-section:first-of-type .f-section-body,
.f-columbia-body {
  background: #fafcfd;
}
.f-col-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 7px;
  margin-bottom: 8px;
}
.f-col-cell {
  background: #e8f4f7;
  border-radius: 8px;
  padding: 8px 6px;
  text-align: center;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}
.f-col-cell .f-cell-label {
  font-size: 10px; color: #6b7280; font-weight: 600; margin-bottom: 3px;
}
/* ALL cell values — uniform: teal bold */
.f-col-cell .f-cell-val,
.f-col-cell .f-cell-val.muted,
.f-col-cell .f-cell-val.f-unk,
.f-col-cell .cs-value {
  font-size: 11px; color: #31869B; font-weight: 700;
  font-family: inherit;
}
.f-col-cell .f-cell-val.f-pos { color: #ef4444; font-weight: 700; }

/* Eval row — centered, label above value */
.f-col-eval-row {
  background: #e8f4f7;
  border-radius: 8px;
  padding: 8px 12px;
  margin-bottom: 12px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
}
.f-col-eval-label {
  font-size: 10px; color: #6b7280; font-weight: 600;
}
.f-col-eval-val {
  font-size: 11px; color: #31869B; font-weight: 700;
}

/* Severity meter boxes */
.f-sev-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.f-sev-box {
  border: 1px solid #e2e8ec;
  border-radius: 8px;
  padding: 10px 12px;
  background: #fff;
  box-shadow: 0 1px 5px rgba(0,0,0,0.08);
}
.f-sev-label { font-size: 10px; color: #6b7280; font-weight: 600; margin-bottom: 6px; }
.f-meter-bar {
  height: 8px; background: #e5e7eb;
  border-radius: 4px; overflow: hidden; margin-bottom: 5px;
}
.f-meter-fill {
  height: 100%; border-radius: 4px;
  transition: width 0.5s ease;
  background: linear-gradient(90deg, #f87171, #ef4444);
}
.f-sev-val { font-size: 11px; font-weight: 700; }

/* Behavior dashed card */
.f-beh-card {
  margin-top: 12px;
  border: 1.5px dashed #92CDDC;
  border-radius: 10px;
  padding: 12px 14px;
  background: #f7fbfd;
}
.f-beh-header {
  font-size: 10px; font-weight: 700; color: #31869B;
  text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 8px;
}
.f-beh-alert {
  background: #fef2f2; border: 1px solid #fca5a5;
  border-right: 3px solid #ef4444;
  border-radius: 8px; padding: 7px 12px;
  font-size: 11.5px; color: #7f1d1d; font-weight: 600; margin-bottom: 8px;
}
.f-beh-grid {
  display: grid; grid-template-columns: repeat(5,1fr);
  gap: 5px; margin-bottom: 8px;
}
.f-beh-cell {
  background: #fff; border: 1px solid #e2e8ec;
  border-radius: 7px; padding: 6px 5px; text-align: center;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
}
.f-beh-lbl { font-size: 9.5px; color: #6b7280; font-weight: 600; margin-bottom: 3px; }
.f-beh-val { font-size: 11.5px; font-weight: 700; }
.f-beh-val.f-danger { color: #ef4444; }
.f-beh-val.f-ok { color: #9ca3af; font-weight: 400; }
.f-leth-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 5px; }

/* CDI bar chart */
.f-cdi-bars { display: flex; flex-direction: column; gap: 7px; margin-bottom: 12px; }
.f-cdi-row { display: flex; align-items: center; gap: 8px; }
.f-cdi-name {
  font-size: 11px; color: #6b7280; font-weight: 600;
  width: 150px; flex-shrink: 0; text-align: right;
}
.f-cdi-track {
  flex: 1; height: 7px; background: #e5e7eb;
  border-radius: 4px; overflow: hidden;
}
.f-cdi-fill {
  height: 100%; border-radius: 4px; width: 0%;
  transition: width 0.5s ease;
}
.f-cdi-fill.f-ok     { background: linear-gradient(90deg,#34d399,#059669); }
.f-cdi-fill.f-warn   { background: linear-gradient(90deg,#f59e0b,#d97706); }
.f-cdi-fill.f-danger { background: linear-gradient(90deg,#f87171,#ef4444); }
.f-cdi-num { font-size: 11px; font-weight: 700; width: 28px; text-align: left; }
.f-cdi-num.f-ok     { color: #059669; }
.f-cdi-num.f-warn   { color: #d97706; }
.f-cdi-num.f-danger { color: #ef4444; }

.f-cdi-verdict {
  background: #fef9c3; border-radius: 8px;
  padding: 8px 12px; font-size: 12px;
  font-weight: 700; color: #854d0e;
  text-align: center; margin-bottom: 8px;
}
.f-cdi-note {
  background: #fffaef; border: 1px solid #fde68a;
  border-right: 3px solid #f59e0b;
  border-radius: 7px; padding: 7px 11px;
  font-size: 11px; color: #78350f; line-height: 1.5;
}

/* Warnings / Risk / Protect — teal only */
.f-wrf-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; }
.f-wrf-col { border-radius: 10px; overflow: hidden; border: 1px solid #c8dfe6; box-shadow: 0 2px 6px rgba(0,0,0,0.07); }
.f-wrf-head {
  padding: 8px 12px; font-size: 11.5px; font-weight: 700;
  background: #e8f4f7; color: #215967;
  border-bottom: 1px solid #c8dfe6;
}
.f-wrf-body { padding: 8px 12px; background: #fff; min-height: 60px; }
/* findings-body items inside new columns */
.f-wrf-body .findings-item {
  font-size: 11.5px; padding: 4px 8px;
  border-radius: 6px; margin-bottom: 3px;
  background: #e8f4f7; color: #215967;
}

/* Risk — new layout */
.f-risk-row { display: flex; align-items: stretch; gap: 12px; }
.f-risk-badge {
  min-width: 120px; border-radius: 10px;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding: 16px 12px; text-align: center;
  background: #fee2e2; flex-shrink: 0;
  box-shadow: 0 3px 10px rgba(239,68,68,0.2);
}
.f-risk-level { font-size: 28px; font-weight: 900; color: #ef4444; line-height: 1; }
.f-risk-sub { font-size: 10px; color: #b91c1c; font-weight: 600; margin-top: 4px; }
.f-risk-rationale {
  flex: 1; font-size: 12.5px; color: #374151;
  line-height: 1.7; padding: 12px 14px;
  background: #f9fafb; border-radius: 8px;
  border: 1px solid #e2e8ec;
  box-shadow: 0 1px 5px rgba(0,0,0,0.06);
}

/* Recommendations — numbered style */
.f-rec-list { display: flex; flex-direction: column; gap: 7px; }
.f-rec-item {
  display: flex; align-items: flex-start; gap: 9px;
  padding: 8px 12px; background: #e8f4f7;
  border-radius: 8px; font-size: 13px; color: #1a2332; line-height: 1.6;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
}
.f-rec-num {
  background: #31869B; color: #fff;
  width: 20px; height: 20px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 10px; font-weight: 800; flex-shrink: 0; margin-top: 2px;
}

/* Risk + Recommendations side by side */
.f-risk-rec-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}
.f-risk-rec-row .f-section {
  margin-bottom: 0;
}
@media (max-width: 700px) {
  .f-risk-rec-row { grid-template-columns: 1fr; }
}

/* Per-section header colors */
/* all section heads use base #D4E8EE from .f-section-head */

/* Risk section icon — red by default, turns white on dark badge levels */
#risk-section-icon {
  font-size: 18px;
  transition: filter 0.3s;
}
.f-risk-icon-white #risk-section-icon {
  filter: brightness(0) invert(1);
}

/* Enforce equal header height for risk+recs side-by-side */
.f-risk-rec-row .f-section-head {
  min-height: 50px;
}
