.gantt-wrapper {
  display: flex;
  flex: 1 1 auto;
  width: 100%;
  height: 100%;
  min-height: 0;
  background: white;
  border-radius: 8px;
  font-family: sans-serif;
  overflow: hidden;
  box-sizing: border-box;
  position: relative;
}

/****************************************/
/* 
  height: 100%;
  min-height: 0;
} */
.gantt-wrapper {
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
}
.gantt-flex-container {
  display: flex;
  flex-direction: row;
  flex: 1 1 auto;
  align-items: stretch;
  width: 100%;
  height: 100%;
  min-height: 0;
  overflow: hidden;
  box-sizing: border-box;
}
:root {
  --tr-odd-row-color: #ccc;
  --tr-even-row-color: #ffffff;
}

/* FLEX LAYOUT FOR FROZEN LHS + SCROLLABLE GANTT */
/****************************************/
.gantt-flex-container {
  display: flex;
  flex-direction: row;
  flex: 1 1 auto;
  align-items: flex-start;
  width: 100%;
  height: 100%;
  min-height: 0;
  overflow: hidden;
  box-sizing: border-box;
}
.gantt-lhs-static {
  flex: 0 0 auto;
  background: #fff;
  border-right: 2px solid #e0e0e0;
  z-index: 2;
}
.gantt-lhs-static table {
  border-right: none;
}
.gantt-timeline-scroll {
  flex: 1 1 auto;
  height: 100%;
  min-height: 0;
  overflow-y: auto;
  overflow-x: auto;
  min-width: 0;
  padding-bottom: 16px;
  box-sizing: border-box;
}
.gantt-timeline-scroll .zebra-table {
  height: 100%;
  max-height: 100%;
  box-sizing: border-box;
}
.gantt-timeline-scroll > div {
  width: max-content;
}
.gantt-lhs-static {
  flex: 0 0 auto;
  background: #fff;
  border-right: 2px solid #e0e0e0;
  z-index: 2;
  max-width: 400px;
  width: 100%;
  height: 100%;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  box-sizing: border-box;
}
.gantt-lhs-static .zebra-table {
  height: 100%;
  max-height: 100%;
  box-sizing: border-box;
}
.gantt-lhs-static .zebra-table th,
.gantt-lhs-static .zebra-table td {
  width: 260px;
  min-width: 260px;
  max-width: 260px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  word-break: normal;
  height: var(--gantt-tr-height) !important;
  line-height: var(--gantt-tr-height) !important;
  vertical-align: middle;
}
/* .gantt-lhs-static .zebra-table th:first-child removed for alignment */
.gantt-timeline-scroll .day-cell, .gantt-wrapper .day-cell, .day-cell {
  min-width: 10px !important;
  max-width: 10px !important;
  width: 10px !important;
  height: var(--gantt-tr-height) !important;
  line-height: var(--gantt-tr-height) !important;
  vertical-align: middle;
  padding: 0 !important;
  margin: 0 !important;
  box-sizing: border-box;
}


/****************************************/
/* END FLEX LAYOUT FOR FROZEN LHS + SCROLLABLE GANTT */
/****************************************/

.gantt-unified-table tbody tr:nth-child(odd) { background-color: var(--tr-odd-row-color) !important; color: var(--tr-text-color) !important; }
.gantt-unified-table tbody tr:nth-child(even) { background-color: var(--tr-even-row-color) !important; color: var(--tr-text-color) !important; }
.zebra-table tbody tr:nth-child(odd) { background-color: var(--tr-odd-row-color) !important; color: var(--tr-text-color) !important; }
.zebra-table tbody tr:nth-child(even) { background-color: var(--tr-even-row-color) !important; color: var(--tr-text-color) !important; }

.gantt-page-bg {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
}


.grid-layout {
  display: grid;
  grid-template-areas:
    "header"
    "main"
    "footer";
  grid-template-columns: 1fr;
  grid-template-rows: 50px auto 50px;
  min-height: 95vh;
  gap: 1rem;
  margin:0 auto;
}


header {
  grid-area: header;
}


.gantt-toolbar-container {
/*  width: 100%;
  background: #f4f7fb;
  border-bottom: 10px solid black;
  padding: 0;*/
}

.dashboard-toolbar {
  display: flex;
  align-items: center;
  height: 52px;
  background: transparent;
  width: 100%;
  border:1px solid purple;
  border-radius: 6px;
}


.dashboard-toolbar .menu-item, .dashboard-toolbar a {
  color: #234567 !important;
  margin-right: 24px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  font-size: 1rem;
}
.dashboard-toolbar .menu-item:last-child {
  margin-right: 0;
}




  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  color: inherit !important;
}
.universal-menu, .menu-bar, .menu-item, .menu-item a, .menu-item button {
  color: #234567 !important;
}

.desktop-menu button, .desktop-menu a, .desktop-menu .menu-item {
  color: #234567;
  font-weight: 500;
  text-decoration: none;
  padding: 0 14px;
  transition: color 0.2s;
  align-items: center;
}


.toolbar-secondary-row {
  width: 100%;
/*  display: block;
  margin-top: 0.5rem;*/
  border:0px solid black;
  max-height:300px;
  margin: 0 auto;
  display:flex;
  justify-content: flex-end;

}

#gantt-filter-panel {
  display: none;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s cubic-bezier(.4,0,.2,1), transform 0.3s cubic-bezier(.4,0,.2,1);
  position: fixed;
  top: 48px;
  left: 50%;
  transform: translateX(-50%) scale(0.98);
  width: 80vw;
  max-width: 900px;
  background: #fff;
  border: 10px solid #d2d9e6;
  border-radius: 6px;
  box-shadow: 0 4px 32px rgba(0,0,0,0.18);
  padding: 18px 24px;
  z-index: 2000;
  text-align: left;
}

#gantt-filter-panel.active {
  display: block;
  opacity: 1;
  pointer-events: auto;
  transform: translateX(-50%) scale(1);
}

#gantt-filter-panel .close-btn {
  position: absolute;
  top: 12px;
  right: 16px;
  background: transparent;
  border: none;
  font-size: 1.8rem;
  color: #345678;
  cursor: pointer;
  z-index: 2020;
  padding: 0;
  line-height: 1;
  transition: color 0.2s;
}
#gantt-filter-panel .close-btn:hover {
  color: #d9534f;
}

@media (max-width: 600px) {
  #gantt-filter-panel {
    width: 98vw;
    max-width: 98vw;
    padding: 8px 4vw;
    font-size: 0.98rem;
    border-width: 4px;
  }
  #gantt-filter-panel .close-btn {
    top: 6px;
    right: 8px;
    font-size: 1.2rem;
  }
}




#gantt-filter-panel form {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: flex-start;
  justify-content: flex-start;
  color: #222;
  text-align: left;
  width: 100%;
}

#gantt-filter-panel label {
  font-weight: 600;
  text-align: left;
  display: block;
}

#gantt-filter-panel input[type="checkbox"] {
  margin-right: 6px;
  vertical-align: middle;
}

#gantt-filter-panel div {
  text-align: left;
}
  }
  
  .gantt-wrapper .day-cell {
  background: #eee;
  min-width: var(--gantt-day-width, 32px);
  max-width: var(--gantt-day-width, 32px);
  width: var(--gantt-day-width, 32px);
  height: var(--gantt-row-height) !important;
  padding: 0;
  border: 1px solid #ccc;
  position: relative;
  vertical-align: middle;
  /* overflow: visible; */
}

.gantt-wrapper .day-cell.bar {
  border: none;
}



.gantt-wrapper .day-cell.bar {
  border: none;
}

.gantt-wrapper .bar {
  position: relative;
}

.gantt-wrapper .bar-inner {
  position: relative;
  background: var(--bar-color, #3b82f6);
  /*border: 2px solid var(--bar-color, #3b82f6);*/
  height: calc(var(--gantt-tr-height) - 4px);
  width: 100%;
  left: 0;
  top: 0;
  transform: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 2;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
  font-size: 12px;
  color: #fff;
  margin: 2px 0;
/*  border-bottom-left-radius: 10px;
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;*/
}



.gantt-wrapper .bar-inner.selected {
  outline: 2px solid #f59e0b;
}

.gantt-wrapper tr:hover .bar-inner {
  filter: brightness(1.08);
}

.gantt-wrapper .bar-label {
  white-space: nowrap;
  color: black;
  /* Step label: inline, truncates if too long, never wraps, always beside icon */
  .step-label-text {
    display: inline-block;
    flex: 1 1 auto;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    position: relative;
    max-width: 100%;
    vertical-align: middle;
    padding-right: 1.7em; /* Reserve space for icon */
    cursor: default;
  }

  /* Tooltip icon: always inline, never wraps, pointer cursor */
  .tooltip-icon {
    position: absolute;
    right: 0.2em;
    top: 50%;
    transform: translateY(-50%);
    margin-left: 0;
    white-space: nowrap;
    font-size: 1.3em;
    color: #0ea5e9;
    outline: none;
    transition: color 0.15s;
    cursor: pointer !important;
  }
  vertical-align: middle;
  flex: 1 1 auto;
  min-width: 0;
}

.gantt-wrapper .bar-info-icon {
  display: inline-block;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #234567;
  color: #fff;
  font-size: 12px;
  font-weight: bold;
  text-align: center;
  line-height: 16px;
  cursor: pointer;
  vertical-align: middle;
  position: relative;
  flex: 0 0 auto;
  margin-left: 0;
}

.gantt-wrapper .bar-info-icon:focus {
  outline: 2px solid #56789a;
}
.gantt-wrapper .bar-info-icon[data-tooltip]:hover::after,
.gantt-wrapper .bar-info-icon[data-tooltip]:focus::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 110%;
  top: 50%;
  transform: translateY(-50%);
  background: #234567;
  color: #fff;
  padding: 6px 10px;
  border-radius: 5px;
  white-space: pre-line;
  z-index: 10;
  min-width: 180px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  font-size: 12px;
  pointer-events: none;
}


.gantt-wrapper .bar.start .bar-inner {
  border-top-left-radius: 10px;
  border-bottom-left-radius: 10px;
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}
.gantt-wrapper .bar.start.end .bar-inner {
  border-top-left-radius: 10px;
  border-bottom-left-radius: 10px;
  border-top-right-radius: 10px;
  border-bottom-right-radius: 10px;
}
.gantt-wrapper .bar.end .bar-inner {
  border-top-right-radius: 10px;
  border-bottom-right-radius: 10px;
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}
.gantt-wrapper .bar:not(.start):not(.end) .bar-inner {
  border-radius: 0;
}


.gantt-wrapper .week-header th {
  font-size: 12px;
  background: #e5eaf5;
  color: #345678;
  border-bottom: 1px solid #bbb;
  text-align: center;
  margin: 0;
  padding: 0;
  height: var(--gantt-header-week);
}

:root {
  --gantt-header-week: 24px;
  --gantt-header-day: 24px;
  --gantt-header-week:calc(var(--gantt-header-day) * 2);
  --gantt-header-day: 20px;
  --gantt-row-height: 23.3px;
}

.gantt-wrapper .week-header th {
  height: var(--gantt-header-week);
}

.gantt-wrapper table.timeline-chart {
  border-collapse: separate;
  border-spacing: 0;
  width: 100%;
}

.gantt-wrapper .day-header th {
  font-size: 10px !important;
  font-weight: normal !important;
  min-width: var(--gantt-day-width, 32px);
  max-width: var(--gantt-day-width, 32px);
  width: var(--gantt-day-width, 32px);
  margin: 0;
  padding: 0 2px !important;
  text-align: center !important;
  vertical-align: middle !important;
  background: #f7fafc;
  color: #234567;
  border-bottom: 1.5px solid #56789a;
  height: var(--gantt-header-day);
}

.gantt-wrapper .day-header th {
  height: var(--gantt-header-day);
}

/****************************************/
/* GENERIC TOOLTIP STYLES FOR TABLES */
/****************************************/
/* Tooltip anchor: must be relative to ensure .tooltiptext is placed correctly */
.tooltip { 
  position: relative; 
  display: inline-block; 
  cursor: pointer; 
}

/* Tooltip body: absolutely positioned to the right of the label, vertically centered */
.tooltiptext {
  visibility: hidden;
  opacity: 0;
  min-width: 220px;
  background: #222 !important;
  color: #fff;
  text-align: left;
  border-radius: 6px;
  padding: 8px;
  position: absolute;
  z-index: 10000 !important;
  left: 100%;
  top: 50%;
  transform: translateY(-50%);
  transition: opacity 0.2s;
  font-size: 13px;
  pointer-events: none;
  box-shadow: 0 2px 8px rgba(0,0,0,0.18);
  white-space: pre-line;
}

.tooltip:hover .tooltiptext, .tooltip:focus .tooltiptext, .tooltip:active .tooltiptext {
.tooltip:focus-within .tooltiptext {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
}
/* Ensure Gantt bar info icon tooltip works for both systems */
.gantt-wrapper .bar-info-icon[data-tooltip]:hover::after,
.gantt-wrapper .bar-info-icon[data-tooltip]:focus::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 110%;
  top: 50%;
  transform: translateY(-50%);
  background: #234567;
  color: #fff;
  padding: 6px 10px;
  border-radius: 5px;
  white-space: pre-line;
  z-index: 10;
  min-width: 180px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  font-size: 12px;
  pointer-events: none;
}

/****************************************/
/* END GENERIC TOOLTIP STYLES */

/****************************************/
/* UNIFIED GANTT TABLE STICKY COLUMN STYLES */
.gantt-outer-container {
  width: 100%;
  overflow-x: auto;
  overflow-y: visible;
  background: #fff;
  box-sizing: border-box;
  max-width: 100vw;
}
.gantt-unified-table {
  border-collapse: separate;
  border-spacing: 0;
  width: 100%;
  min-width: 900px;
  font-size: 12px;
  background: #fff;
}
.gantt-unified-table th, .gantt-unified-table td {
  border: 1px solid #ccc;
  padding: 4px 8px;
  text-align: left;
  white-space: nowrap;
  background: #fff;
}
.sticky-col {
  position: sticky;
  left: 0;
  z-index: 2;
  background: #fff;
  box-shadow: 2px 0 4px -2px #eee;
}
.gantt-unified-table thead th.sticky-col {
  z-index: 3;
}
/****************************************/
/* END UNIFIED GANTT TABLE STICKY COLUMN STYLES */


.steps-header-row {
  height: calc(var(--gantt-header-week) + var(--gantt-header-day) - 9px) !important;
  min-height: 45px;
  vertical-align: middle;
  padding-top: 0;
  padding-bottom: 0;
  font-size: 1rem;
  background: #345678;
  color: #fff;
}

/****************************************/
