.gantt-focus .project-heading,
.gantt-focus .metrics {
  display: none;
}
.gantt-focus main {
  padding-top: 12px;
}
.gantt-focus .view-toolbar {
  margin-bottom: 22px;
}
.gantt-focus .page-footer {
  margin-top: 18px;
}
.gantt-focus #external-schedule-content,
.gantt-focus #pricing-content {
  display: none;
}
#schedule-content {
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}
.gantt-focus #schedule-content {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}
.external-stage-row {
  display: flex;
  height: 46px;
  border-bottom: 1px solid #e8eee6;
}
.external-stage-row:last-of-type {
  border-bottom: 0;
}
.external-schedule .asset-fixed-cell {
  grid-template-columns: minmax(0, 1fr);
}
.external-schedule .calendar-fixed {
  display: flex;
  justify-content: space-between;
}
.external-schedule .calendar-fixed > span:last-child {
  display: block;
}
.external-stage-name {
  display: grid;
  grid-template-columns: var(--ext-cols);
  align-items: center;
  gap: 8px;
  min-width: 0;
  width: 100%;
  border: 0;
  background: none;
  text-align: left;
  padding: 0;
  font-size: 12.5px;
  color: #526b5c;
}
.external-stage-name > span {
  min-width: 0;
  overflow-wrap: anywhere;
}
.external-stage-name .legend-dot {
  flex-shrink: 0;
}
.external-stage-label {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.external-stage-days {
  text-align: right;
  font-weight: 550;
  font-variant-numeric: tabular-nums;
}
.external-stage-name small {
  text-align: right;
  flex-shrink: 0;
  font-size: 11.5px;
  color: #69786f;
}
.external-stage-bar {
  position: absolute;
  top: 10px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  min-width: 0;
  border: 1px solid var(--phase);
  border-radius: 3px;
  background: color-mix(in srgb, var(--phase) 12%, white);
  color: var(--phase);
  padding: 0 5px;
  z-index: 3;
  font-size: 11.5px;
  overflow: hidden;
}
.external-stage-bar > span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.external-stage-bar small {
  font-size: 11px;
  flex-shrink: 0;
}
.external-stage-bar:hover {
  background: color-mix(in srgb, var(--phase) 22%, white);
}
.schedule-comparison {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 16px;
  margin: 0 0 18px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}
.schedule-comparison dt {
  font-size: 11.5px;
  color: #68776e;
  margin-bottom: 7px;
}
.schedule-comparison dd {
  margin: 0;
  font-size: 17px;
  color: #3b6256;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
.schedule-comparison small {
  font-size: 11.5px;
  color: #68776e;
}
.gantt-toolbar-actions {
  flex-wrap: wrap;
}
@media (max-width: 1050px) {
  .schedule-comparison {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .asset-gantt-toolbar {
    flex-wrap: wrap;
  }
}
@media (max-width: 540px) {
  .schedule-comparison {
    gap: 16px 10px;
  }
  .schedule-comparison dd {
    font-size: 15.5px;
  }
  .schedule-comparison dt {
    font-size: 11px;
  }
}
.asset-gantt-workspace {
  min-width: 0;
}
.asset-gantt-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  margin-bottom: 20px;
}
.gantt-title h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 19px;
  font-weight: 600;
  margin: 0 0 6px;
}
.gantt-title > span {
  font-size: 12.5px;
  color: #69786f;
}
.gantt-title i {
  font-style: normal;
  color: #c3cec6;
  padding: 0 9px;
}
.gantt-toolbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.gantt-toolbar-actions .segmented button {
  padding: 5px 10px;
}
.person-pool {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 22px;
  padding: 17px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.person-pool-heading {
  flex: 0 0 53px;
  font-size: 12.5px;
  color: #68796e;
}
.person-pool-heading small {
  display: block;
  color: #657a6c;
  font-size: 11px;
  margin-top: 5px;
}
.person-pool-list {
  display: flex;
  gap: 11px;
  flex: 1;
  min-width: 0;
  flex-wrap: wrap;
}
.gantt-person-source {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 9px 10px 9px 6px;
  background: white;
  border: 1px solid #e0e8e1;
  border-radius: 5px;
  touch-action: none;
  user-select: none;
  cursor: grab;
  min-width: 158px;
  flex: 1;
  max-width: 245px;
  min-height: 55px;
  text-align: left;
}
.gantt-person-source:hover {
  border-color: #94b3a1;
  background: #f8fbf8;
}
.gantt-person-source > svg {
  width: 12px;
  height: 15px;
  color: #b7c4ba;
}
.gantt-person-source .avatar {
  width: 29px;
  height: 29px;
}
.gantt-person-source b {
  font-size: 12.5px;
  font-weight: 550;
  display: block;
}
.gantt-person-source b small {
  display: inline;
  font-size: 11px;
  color: #69796d;
  font-weight: 400;
  margin-left: 6px;
}
.gantt-person-source span > small {
  display: block;
  font-size: 11px;
  color: #69786d;
  margin-top: 3px;
}
.gantt-person-source .pool-rate {
  font-size: 11.5px;
  color: #66786c;
  margin-left: auto;
  text-align: right;
}
.pool-rate small {
  display: block;
  font-size: 10.5px;
  color: #6c786e;
}
.person-drag-ghost {
  position: fixed;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 13px;
  background: #fff;
  box-shadow: 0 5px 20px #1d3d2530;
  border: 1px solid #8fab98;
  border-radius: 5px;
  pointer-events: none;
  z-index: 200;
  font-size: 13.5px;
}
.asset-gantt-scroll {
  overflow: auto;
  border: 1px solid #dee6df;
  border-radius: 5px;
  position: relative;
  max-height: max(560px, calc(100vh - 150px));
  background: white;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: #c8d3cb #f6f8f5;
}
.asset-gantt-canvas {
  position: relative;
  min-width: 100%;
}
/* 日期滑块：时间轴宽于视口时显示在甘特图下方，拖动滑块或点击轨道换到对应日期。 */
.gantt-pan {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}
.gantt-pan[hidden] {
  display: none;
}
.gantt-pan-step {
  flex: 0 0 auto;
  width: 28px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid #d2dcd4;
  border-radius: 4px;
  background: #fff;
  color: #405145;
  cursor: pointer;
}
.gantt-pan-step:hover {
  background: #eef3ef;
  color: #1d3d25;
  border-color: #b9c9bd;
}
.gantt-pan-step i {
  width: 15px;
  height: 15px;
}
.gantt-pan-track {
  position: relative;
  flex: 1 1 auto;
  height: 24px;
  border: 1px solid #dee6df;
  border-radius: 4px;
  background: #f6f8f5;
  overflow: hidden;
  cursor: pointer;
}
.gantt-pan-phase {
  position: absolute;
  top: 0;
  bottom: 0;
  opacity: 0.3;
}
.gantt-pan-thumb {
  position: absolute;
  top: 0;
  bottom: 0;
  min-width: 24px;
  border: 1px solid #2c6b52;
  border-radius: 4px;
  background: #ffffffd9;
  box-shadow: 0 1px 3px #1d3d2533;
  cursor: grab;
  touch-action: none;
}
.gantt-pan-thumb::after {
  content: '';
  position: absolute;
  top: 7px;
  bottom: 7px;
  left: 50%;
  width: 7px;
  transform: translateX(-50%);
  background: repeating-linear-gradient(90deg, #2c6b52 0 1px, transparent 1px 3px);
}
.gantt-pan-thumb:focus-visible {
  outline: 2px solid #226b58;
  outline-offset: 1px;
}
.gantt-pan.panning .gantt-pan-thumb {
  cursor: grabbing;
  background: #fff;
  box-shadow: 0 2px 6px #1d3d2540;
}
.gantt-pan-range {
  flex: 0 0 auto;
  min-width: 104px;
  text-align: right;
  font-size: 12.5px;
  color: #4c5b51;
  font-variant-numeric: tabular-nums;
}
.asset-calendar-header {
  height: 96px;
  display: flex;
  position: sticky;
  top: 0;
  z-index: 6;
  background: white;
  border-bottom: 1px solid #dce6de;
}
.asset-fixed-cell {
  position: sticky;
  left: 0;
  width: var(--label-width);
  flex: 0 0 var(--label-width);
  display: grid;
  grid-template-columns: minmax(0, 1fr) 34px 70px;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  border-right: 1px solid #dce6df;
  background: white;
  z-index: 4;
  font-size: 12.5px;
}
.asset-fixed-cell > span {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.asset-calendar-header .calendar-fixed {
  align-items: end;
  padding-bottom: 11px;
  color: #68776c;
  font-size: 11.5px;
  background: #fbfcfa;
}
.asset-calendar {
  width: var(--timeline-width);
  flex: 0 0 var(--timeline-width);
  position: relative;
}
.asset-phase-header {
  height: 44px;
  position: relative;
  background: #fbfcfa;
}
.asset-phase-band {
  position: absolute;
  height: 44px;
  background: color-mix(in srgb, var(--phase) 7%, white);
  border-right: 1px solid color-mix(in srgb, var(--phase) 30%, white);
}
.phase-caption {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1px;
  width: 100%;
  height: 44px;
  padding: 0 2px;
  background: transparent;
  border: 0;
  color: var(--phase);
  white-space: nowrap;
}
.phase-caption b {
  font-weight: 550;
  font-size: 11.5px;
}
.phase-caption small {
  font-size: 10.5px;
  opacity: 0.8;
}
.phase-caption:hover {
  background: #ffffff65;
}
.milestone-handle {
  position: absolute;
  right: -8px;
  bottom: -8px;
  width: 16px;
  height: 16px;
  display: grid;
  place-items: center;
  z-index: 5;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: ew-resize;
  touch-action: none;
}
.milestone-handle > span {
  width: 7px;
  height: 7px;
  background: var(--phase);
  border: 1px solid white;
  transform: rotate(45deg);
  pointer-events: none;
}
.milestone-handle:hover > span,
.milestone-handle.dragging > span {
  width: 10px;
  height: 10px;
}
.calendar-months {
  display: flex;
  height: 24px;
  background: #fbfcfa;
  border-top: 1px solid #e5ebe5;
  border-bottom: 1px solid #e5ebe5;
}
.calendar-months > span {
  padding: 4px 6px;
  color: #67766c;
  font-size: 11px;
  overflow: hidden;
  white-space: nowrap;
  border-right: 1px solid #dce5dd;
  flex-shrink: 0;
}
.calendar-days {
  display: flex;
  height: 28px;
}
.calendar-days > span {
  width: var(--day-width);
  flex: 0 0 var(--day-width);
  font-size: 11px;
  color: #69796e;
  text-align: center;
  display: grid;
  place-items: center;
  border-right: 1px solid #edf1ec;
}
.calendar-days .weekend {
  background: #f2f5f0;
  color: #69786a;
}
.asset-summary-row {
  display: flex;
  height: 49px;
  border-bottom: 1px solid #e1e9e1;
}
.asset-summary-row .asset-fixed-cell {
  background: #f7faf6;
}
.asset-summary-row .asset-fixed-cell > div {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}
.asset-summary-row strong {
  font-size: 11.5px;
  font-weight: 550;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.asset-summary-row svg {
  width: 13px;
  height: 13px;
  color: #617967;
}
.asset-summary-row .asset-fixed-cell > span {
  font-size: 11.5px;
}
.asset-project-track,
.person-track,
.gantt-new-track {
  width: var(--timeline-width);
  flex: 0 0 var(--timeline-width);
  position: relative;
  background-image: linear-gradient(to right, transparent calc(100% - 1px), #edf1eb 0);
  background-size: var(--day-width) 100%;
  min-width: 0;
}
.asset-project-bar {
  position: absolute;
  top: 14px;
  height: 20px;
  border-radius: 3px;
  background: #527e97;
  color: white;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  padding: 0 10px;
  z-index: 2;
}
.asset-project-bar small {
  font-size: 10.5px;
  opacity: 0.8;
}
.calendar-weekend {
  position: absolute;
  top: 0;
  bottom: 0;
  background: repeating-linear-gradient(
    130deg,
    #a8b9a808 0px,
    #a8b9a808 3px,
    #d3ddd326 3px,
    #d3ddd326 4px
  );
  pointer-events: none;
}
.asset-person-row {
  display: flex;
  border-bottom: 1px solid #e8eee6;
  position: relative;
}
.gantt-person-label {
  display: flex;
  gap: 7px;
  align-items: center;
  min-width: 0;
}
.gantt-person-label .avatar {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
}
.gantt-person-label b {
  font-size: 12.5px;
  font-weight: 550;
  white-space: nowrap;
}
.gantt-person-label small {
  display: block;
  font-size: 10.5px;
  color: #69796d;
  white-space: nowrap;
}
.gantt-person-days {
  font-size: 12.5px;
}
.gantt-person-days small {
  display: block;
  font-size: 10.5px;
  color: #69796e;
}
.gantt-person-cost {
  font-size: 11.5px;
  color: #65776b;
}
.allocation-bar {
  position: absolute;
  min-width: 12px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid color-mix(in srgb, var(--phase) 45%, white);
  background: color-mix(in srgb, var(--phase) 17%, white);
  color: var(--phase);
  border-radius: 4px;
  cursor: grab;
  touch-action: none;
  user-select: none;
  z-index: 3;
  outline-offset: 2px;
  box-shadow: 0 1px 1px #1d4a2210;
}
.allocation-bar:hover {
  filter: brightness(0.97);
  border-color: var(--phase);
  z-index: 5;
}
.allocation-bar.dragging {
  z-index: 10;
  cursor: grabbing;
  box-shadow: 0 3px 10px #18382525;
}
.allocation-bar.allocation-warning {
  border-bottom: 2px solid #c77756;
}
/* 单击选中的排期条：加深描边并抬高层级，双击才打开编辑面板。 */
.allocation-bar.bar-selected,
.external-stage-bar.bar-selected {
  outline: 2px solid #1d5c46;
  outline-offset: 1px;
  box-shadow: 0 2px 9px #1d3d2540;
  z-index: 7;
}
.allocation-bar.bar-selected {
  background: color-mix(in srgb, var(--phase) 30%, white);
}
.external-stage-bar.bar-selected {
  background: color-mix(in srgb, var(--phase) 26%, white);
}
.bar-selected .bar-copy,
.bar-selected .stage-bar-name {
  font-weight: 600;
}
.bar-copy {
  pointer-events: none;
  font-size: 11.5px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  padding: 0 6px;
}
.resize-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 7px;
  cursor: ew-resize;
  z-index: 2;
  touch-action: none;
}
.resize-handle.left {
  left: -1px;
}
.resize-handle.right {
  right: -1px;
}
.resize-handle:after {
  content: '';
  position: absolute;
  width: 1px;
  height: 10px;
  top: 8px;
  background: var(--phase);
  opacity: 0;
}
.resize-handle.left:after {
  left: 3px;
}
.resize-handle.right:after {
  right: 3px;
}
.allocation-bar:hover .resize-handle:after {
  opacity: 0.7;
}
.asset-drop-row {
  display: flex;
  height: 60px;
}
.asset-drop-row .asset-fixed-cell {
  display: flex;
}
.gantt-new-track {
  display: flex;
  align-items: center;
}
.gantt-new-track > span {
  display: inline-flex;
  gap: 5px;
  align-items: center;
  font-size: 11.5px;
  color: #657968;
  margin-left: 20px;
  pointer-events: none;
}
.gantt-new-track svg {
  width: 13px;
  height: 13px;
}
.drop-active {
  outline: 2px dashed #6ca287;
  outline-offset: -4px;
  background-color: #edf6ef !important;
}
.shared-milestone-lines {
  position: absolute;
  left: var(--label-width);
  width: var(--timeline-width);
  top: 44px;
  bottom: 0;
  pointer-events: none;
  z-index: 2;
}
.shared-milestone-line {
  position: absolute;
  top: 0;
  bottom: 0;
  border-left: 1px dashed;
  opacity: 0.5;
}
.gantt-bottom-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 18px;
  font-size: 11.5px;
  color: #68786d;
}
.gantt-bottom-line > span {
  display: flex;
  align-items: center;
  gap: 5px;
}
.gantt-bottom-line svg {
  width: 13px;
  height: 13px;
}
.gantt-bottom-line > div {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}
.gantt-bottom-line b {
  font-size: 13.5px;
  color: #587161;
  font-weight: 550;
  margin-left: 5px;
}
.gantt-bottom-line .gantt-budget-profit b {
  color: var(--green);
}
.gantt-floating-info {
  display: none;
  position: fixed;
  bottom: 25px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 13.5px;
  padding: 11px 20px;
  border: 1px solid #d6e3d8;
  border-radius: 5px;
  box-shadow: 0 4px 20px #1a3d2515;
  background: white;
  color: #496352;
  z-index: 100;
  pointer-events: none;
  max-width: calc(100vw - 25px);
}
.gantt-floating-info.visible {
  display: block;
}
.gantt-warning-summary {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #a87943;
  background: #fcf7ef;
  border: 1px solid #eee2cc;
  padding: 7px 12px;
  border-radius: 4px;
  margin-bottom: 12px;
  font-size: 12.5px;
}
.gantt-warning-summary svg {
  width: 14px;
  height: 14px;
}
.gantt-warning-summary .button {
  margin-left: auto;
  color: #a87943;
}
.milestone-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px 16px;
}
.milestone-fields label > span {
  display: flex;
  align-items: center;
  gap: 7px;
}
.milestone-fields .field {
  margin-bottom: 15px;
}
.milestone-summary {
  font-size: 12.5px;
  color: #6a786e;
  border-top: 1px solid var(--line);
  padding-top: 12px;
  line-height: 1.8;
}
.warning-list {
  padding: 0;
  list-style: none;
  max-height: 45vh;
  overflow: auto;
}
.warning-list li {
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: 12.5px;
  color: #68796d;
}
.warning-list strong {
  color: #526b5c;
  font-weight: 550;
}
.bar-copy {
  padding: 0 4px;
}
.calendar-days > span {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  line-height: 12px;
}
.calendar-days b {
  font-weight: 400;
}
.calendar-days small {
  font-size: 10.5px;
  line-height: 10px;
}
.calendar-days .calendar-weekend {
  position: static;
  background: #f2f5f0;
  color: #69776b;
}
.calendar-days .calendar-holiday {
  background: #f8eae7;
  color: #b06559;
}
.calendar-days .calendar-makeup {
  background: #e6f1f8;
  color: #397797;
}
.calendar-days .calendar-unknown {
  background: #f5f0e2;
  color: #9b8137;
}
.calendar-weekend.calendar-holiday {
  background: repeating-linear-gradient(
    130deg,
    #c786710b 0px,
    #c786710b 3px,
    #e7b8a92b 3px,
    #e7b8a92b 4px
  );
}
.calendar-weekend.calendar-makeup {
  background: #e6f1f83b;
}
.calendar-weekend.calendar-unknown {
  background: #f5f0e255;
}
.bar-rest-days {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: 3px;
  pointer-events: none;
}
.bar-rest-days > span {
  position: absolute;
  inset-block: 0;
  background: repeating-linear-gradient(
    130deg,
    #ffffff90 0px,
    #ffffff90 3px,
    #ffffff30 3px,
    #ffffff30 5px
  );
}
.bar-copy {
  position: relative;
  z-index: 1;
}
.participation-production {
  background: var(--phase);
  border-color: var(--phase);
  color: white;
}
.participation-primary {
  background: white;
  border: 2px solid var(--phase);
  color: var(--phase);
}
.participation-secondary {
  background: color-mix(in srgb, var(--phase) 5%, white);
  border: 2px dashed var(--phase);
  color: var(--phase);
}
.allocation-bar.allocation-warning {
  border-bottom-width: 2px;
  box-shadow: 0 3px 0 #c77756;
}
.participation-production .bar-rest-days > span {
  background: repeating-linear-gradient(
    130deg,
    #ffffff30 0px,
    #ffffff30 3px,
    #ffffff08 3px,
    #ffffff08 5px
  );
}
.participation-production .resize-handle:after {
  background: white;
}
.participation-label {
  display: block;
  margin-top: 3px;
  font-size: 11px;
  font-weight: 400;
  color: #68776f;
}
.drawer #editor-content {
  height: 100%;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.drawer .drawer-header,
.drawer .drawer-actions {
  flex-shrink: 0;
}
.drawer #allocation-form {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
}
.drawer .drawer-body {
  flex: 1;
  overflow-y: auto;
  min-height: 0;
}
.phase-caption b {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.milestone-fields.milestone-name-fields {
  display: block;
}
.milestone-name-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 12px;
}
.milestone-name-row .field {
  min-width: 0;
}
.milestone-name-row input {
  font-size: 13.5px;
}
.stage-label > div {
  min-width: 0;
}
.stage-name,
.drawer-header p {
  overflow-wrap: anywhere;
}
.milestone-name-row.milestone-with-actions {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 26px;
  gap: 8px;
}
.node-row-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding-bottom: 10px;
  gap: 2px;
}
.node-row-actions .icon-button {
  width: 26px;
  height: 26px;
  min-width: 26px;
  padding: 4px;
}
.node-row-actions .icon-button svg {
  width: 14px;
  height: 14px;
}
.milestone-editor #append-node {
  margin: 0 0 15px;
}
.milestone-editor .modal-actions {
  position: sticky;
  bottom: 0;
  background: white;
  border-top: 1px solid var(--line);
  padding: 14px 0 0;
  margin-top: 16px;
  z-index: 2;
}
.plan-details {
  margin-top: 24px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  scroll-margin-top: 20px;
}
.plan-details > summary {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 54px;
  cursor: pointer;
  list-style: none;
  color: #526b5c;
  font-size: 13.5px;
}
.plan-details > summary::-webkit-details-marker {
  display: none;
}
.plan-details > summary > span:first-child {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 550;
}
.plan-details > summary svg {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
}
.plan-details > summary > svg {
  transition: transform 0.15s;
}
.plan-details[open] > summary > svg {
  transform: rotate(180deg);
}
#plan-details-summary {
  margin-left: auto;
  color: #69766e;
  font-size: 12.5px;
}
#budget-content {
  padding: 14px 0 22px;
}
.plan-view .project-heading {
  margin-bottom: 18px;
}
.plan-view .metrics {
  padding: 17px 0;
  margin-bottom: 14px;
}
.plan-view .view-toolbar {
  margin-bottom: 18px;
}
.plan-view .asset-gantt-toolbar {
  margin-bottom: 14px;
}
.plan-view .person-pool {
  padding: 12px 0;
  margin-bottom: 14px;
}
@media (max-width: 540px) {
  .plan-details > summary {
    gap: 8px;
    font-size: 12.5px;
  }
  .plan-details > summary > span:first-child {
    gap: 5px;
  }
  #plan-details-summary {
    font-size: 11px;
  }
  .plan-view .view-tabs {
    justify-content: flex-start;
    gap: 26px;
  }
}
.calendar-source-button {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: none;
  border: 0;
  color: #567b6c;
  padding: 3px 0;
  font-size: 11.5px;
  text-align: left;
  cursor: pointer;
}
.calendar-source-button:hover {
  color: var(--green);
  text-decoration: underline;
}
.calendar-source {
  display: grid;
  grid-template-columns: 65px minmax(0, 1fr);
  gap: 10px;
  font-size: 12.5px;
  line-height: 1.6;
}
.calendar-source dt {
  color: #6b776f;
}
.calendar-source dd {
  margin: 0;
  color: #476354;
}
.calendar-source a {
  color: #337b73;
  overflow-wrap: anywhere;
}
.calendar-source a svg {
  display: inline;
  width: 11px;
  height: 11px;
  margin-left: 3px;
}
.calendar-source small {
  display: block;
  color: #6b766f;
  margin-top: 4px;
}
.holiday-table {
  border-collapse: collapse;
  width: 100%;
  table-layout: fixed;
  font-size: 11.5px;
  margin-top: 22px;
}
.holiday-table caption {
  text-align: left;
  font-size: 13.5px;
  color: #476354;
  margin-bottom: 9px;
}
.holiday-table th,
.holiday-table td {
  padding: 9px 3px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  font-weight: 400;
  overflow-wrap: anywhere;
}
.holiday-table th:first-child {
  width: 19%;
}
.holiday-table thead {
  color: #6b766f;
}
.holiday-table tbody {
  color: #5a6e62;
}
.calendar-version {
  font-size: 11px;
  color: #6b766f;
  overflow-wrap: anywhere;
}
.gantt-person-label .remove-scheduled-person {
  width: 24px;
  min-width: 24px;
  height: 28px;
  padding: 4px;
  margin-left: auto;
  color: #6a766f;
  flex-shrink: 0;
}
.gantt-person-label .remove-scheduled-person svg {
  width: 13px;
  height: 13px;
}
.gantt-person-label .remove-scheduled-person:hover {
  color: #b85d4c;
  background: #fcf0ed;
}
.person-pool-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.person-pool-list .gantt-person-source {
  max-width: none;
  min-width: 0;
  width: 100%;
}
@media (min-width: 1600px) {
  .person-pool-list {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
}
@media (max-width: 1050px) {
  .gantt-person-source {
    min-width: 142px;
  }
  .gantt-person-source .pool-rate {
    display: none;
  }
  .person-pool {
    gap: 12px;
  }
  .gantt-toolbar-actions {
    gap: 5px;
  }
  .gantt-title h2 {
    font-size: 16.5px;
  }
  .gantt-title > span {
    font-size: 11.5px;
  }
  .gantt-bottom-line {
    align-items: flex-start;
    flex-direction: column;
  }
}
@media (max-width: 650px) {
  .asset-gantt-toolbar {
    align-items: flex-start;
    flex-direction: column;
    gap: 15px;
  }
  .gantt-toolbar-actions {
    width: 100%;
    justify-content: flex-end;
  }
  .gantt-toolbar-actions > [data-gantt-undo] {
    margin-right: auto;
  }
  .person-pool {
    align-items: flex-start;
    padding: 14px 0;
    gap: 10px;
  }
  .person-pool-heading {
    flex-basis: 37px;
    font-size: 11.5px;
    padding-top: 5px;
  }
  .person-pool-heading small {
    font-size: 10.5px;
  }
  .person-pool-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 7px;
  }
  .gantt-person-source {
    min-width: 0;
    width: 100%;
    gap: 4px;
    padding: 6px 5px 6px 1px;
    min-height: 49px;
  }
  .gantt-person-source b {
    font-size: 11.5px;
  }
  .gantt-person-source b small {
    font-size: 10.5px;
    margin-left: 3px;
  }
  .gantt-person-source span > small {
    font-size: 10.5px;
  }
  .gantt-person-source .avatar {
    width: 24px;
    height: 24px;
  }
  .gantt-person-source > svg {
    width: 10px;
  }
  .asset-fixed-cell {
    grid-template-columns: minmax(0, 1fr) 30px;
    gap: 3px;
    padding: 0 8px;
  }
  .asset-fixed-cell > span:last-child {
    display: none;
  }
  .gantt-person-label {
    gap: 3px;
  }
  .gantt-person-label small {
    font-size: 10.5px;
  }
  .gantt-person-label .avatar {
    width: 23px;
    height: 23px;
  }
  .gantt-person-label b {
    font-size: 11.5px;
  }
  .gantt-bottom-line > div {
    gap: 10px;
    font-size: 11px;
  }
  .gantt-bottom-line b {
    font-size: 12.5px;
    margin-left: 2px;
  }
  .gantt-warning-summary {
    font-size: 11.5px;
    gap: 5px;
  }
  .gantt-warning-summary .button {
    font-size: 11px;
  }
  .milestone-fields {
    gap: 4px 10px;
  }
  .gantt-focus main {
    padding-top: 6px;
  }
  .gantt-focus .view-toolbar {
    margin-bottom: 17px;
  }
  .asset-gantt-scroll {
    max-height: max(470px, 72vh);
  }
}

.gantt-focus .asset-gantt-scroll {
  max-height: max(470px, calc(100vh - 110px));
}
.calendar-days .calendar-provisional {
  background: repeating-linear-gradient(135deg, #fbf6ea 0 3px, #fff 3px 6px);
  color: #a0843f;
}
.calendar-provisional-badge {
  display: inline-flex;
  align-items: center;
  margin-left: 8px;
  font-size: 11.5px;
  color: #94773c;
  background: #f6f1e5;
  padding: 2px 7px;
  border-radius: 3px;
}

.gantt-hover-card {
  position: fixed;
  z-index: 120;
  pointer-events: none;
  background: white;
  border: 1px solid #d6e3d8;
  border-radius: 6px;
  box-shadow: 0 6px 24px #1a3d251f;
  padding: 9px 12px;
  font-size: 12.5px;
  color: #50655a;
  display: flex;
  flex-direction: column;
  gap: 3px;
  max-width: 280px;
  line-height: 1.5;
}
.gantt-hover-card b {
  color: var(--ink);
  font-weight: 600;
  font-size: 13.5px;
}
.gantt-hover-card > span {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
}
.gantt-hover-card em {
  font-style: normal;
  color: var(--red);
}
.gantt-hover-card small {
  color: #6b786f;
  font-size: 11.5px;
  margin-top: 2px;
}
.participation-sample {
  display: inline-block;
  width: 16px;
  height: 8px;
  border-radius: 2px;
  background: #5e8a78;
  border: 1.5px solid #5e8a78;
}
.participation-sample.participation-primary {
  background: white;
}
.participation-sample.participation-secondary {
  background: white;
  border-style: dashed;
}
.schedule-comparison-line {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 22px;
  margin: 0 0 16px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
  font-size: 12.5px;
  color: #69776e;
}
.schedule-comparison-line b {
  color: #3b6256;
  font-weight: 600;
  font-size: 14.5px;
  font-variant-numeric: tabular-nums;
  margin-left: 3px;
}
.schedule-comparison-line b.late,
.schedule-comparison dd.late {
  color: var(--red);
}
.schedule-comparison-line small {
  font-size: 11.5px;
  color: #6c786f;
  margin-left: auto;
}
.gantt-toolbar-actions .button.small svg {
  width: 14px;
  height: 14px;
}
@media (max-width: 760px) {
  .gantt-toolbar-actions .label-text {
    display: none;
  }
  .schedule-comparison-line small {
    margin-left: 0;
  }
}

.external-stage-bar {
  cursor: grab;
  touch-action: none;
  user-select: none;
}
.external-stage-bar.dragging {
  cursor: grabbing;
  box-shadow: 0 2px 10px #1a3d2522;
  z-index: 5;
}
.external-stage-bar .resize-handle {
  background: transparent;
}
.external-stage-bar:hover .resize-handle:after,
.external-stage-bar:focus-visible .resize-handle:after {
  opacity: 0.8;
}
.external-stage-bar .stage-bar-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
/* 紧凑间距：缩短对外排期与内部排期之间、对照栏与人员池之间的留白 */
.gantt-bottom-line {
  margin-top: 10px;
}
#schedule-content {
  margin-top: 14px;
  padding-top: 16px;
}
.plan-view .asset-gantt-toolbar {
  margin-bottom: 8px;
}
.schedule-comparison-line {
  margin: 0 0 8px;
  padding: 7px 0;
}
.person-pool {
  margin-bottom: 12px;
  padding: 10px 0;
}
.gantt-focus #schedule-content {
  margin-top: 0;
  padding-top: 0;
}
.gantt-bottom-line {
  font-size: 12.5px;
}
.gantt-bottom-line b {
  font-size: 13.5px;
}
.asset-fixed-cell {
  font-size: 13px;
}
.calendar-days > span {
  font-size: 11px;
}
.calendar-days small {
  font-size: 9.5px;
}
.phase-caption b {
  font-size: 12.5px;
}
.phase-caption small {
  font-size: 10.5px;
}
.external-stage-bar,
.bar-copy {
  font-size: 12px;
}
.gantt-person-label b {
  font-size: 13.5px;
}
.gantt-person-label small {
  font-size: 11.5px;
}
/* 视觉优化：卡片内边距（覆盖早期规则） */
#budget-content,
#pricing-content,
#external-schedule-content,
#schedule-content {
  padding: 20px 22px;
}
@media (max-width: 760px) {
  #budget-content,
  #pricing-content,
  #external-schedule-content,
  #schedule-content {
    padding: 14px 12px;
  }
}

/* 表头：阶段区间做成真正的列组标题，左侧固定列与三行表头逐行对齐 */
.asset-calendar-header .calendar-fixed,
.external-schedule .asset-calendar-header .calendar-fixed {
  display: grid;
  grid-template-rows: 44px 24px 28px;
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
  gap: 0;
  padding: 0;
  background: #fbfcfa;
}
.calendar-fixed-band {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 12px;
  background: #e9efe9;
  border-bottom: 1px solid #d3ded6;
  color: #33423a;
  font-size: 12.5px;
  font-weight: 650;
  letter-spacing: 0.02em;
}
.calendar-fixed-band i {
  width: 14px;
  height: 14px;
  color: #5b6d61;
}
.calendar-fixed-month {
  display: flex;
  align-items: center;
  padding: 0 12px;
  font-size: 11.5px;
  color: #6b7a70;
  border-bottom: 1px solid #e5ebe5;
}
.calendar-fixed-cols {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 34px 70px;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  font-size: 11.5px;
  color: #5d6b61;
  font-weight: 550;
}
.calendar-fixed-cols > span {
  text-align: right;
}
.calendar-fixed-cols > span:first-child {
  text-align: left;
}
/* 对外排期左列三栏：交付阶段 / 报价人天 / 节点日期，表头与行用同一套列宽。 */
.external-schedule {
  --ext-cols: minmax(0, 1fr) 52px 46px;
}
.external-schedule .calendar-fixed-cols {
  display: grid;
  grid-template-columns: var(--ext-cols);
}
.asset-phase-header {
  background: #e9efe9;
  border-bottom: 1px solid #d3ded6;
}
.asset-phase-band {
  background: color-mix(in srgb, var(--phase) 13%, white);
  border-right: 1px solid color-mix(in srgb, var(--phase) 42%, white);
  box-shadow: inset 0 3px 0 var(--phase);
}
.phase-caption {
  padding-top: 3px;
}
.phase-caption b {
  font-size: 13px;
  font-weight: 700;
  color: color-mix(in srgb, var(--phase) 70%, #1d2a22);
}
.phase-caption small {
  font-size: 11px;
  color: #57655c;
  opacity: 1;
  font-variant-numeric: tabular-nums;
}
.calendar-months > span {
  font-size: 11.5px;
  color: #4d5c52;
  font-weight: 550;
}
.calendar-months > span.month-year-start {
  border-left: 2px solid #b9c7bd;
  color: #2f3d34;
  font-weight: 700;
}
/* 时间轴跨两年后横向滚动很长，月份与阶段标题在各自区间内吸附，滚到区间中段仍能看到标题 */
.calendar-months > span {
  overflow: visible;
  padding: 0;
  display: flex;
  align-items: center;
}
.calendar-months > span > i {
  position: sticky;
  left: calc(var(--label-width) + 8px);
  font-style: normal;
  padding: 0 6px;
  white-space: nowrap;
}
.phase-caption {
  justify-content: center;
}
.phase-caption-inner {
  position: sticky;
  left: calc(var(--label-width) + 8px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  max-width: 100%;
  padding: 0 4px;
}

/* 内部资产总条可拖动：整条平移、两端等比缩放内部节点（对外那条不可拖） */
.asset-project-bar.adjustable {
  cursor: grab;
  touch-action: none;
  user-select: none;
}
.asset-project-bar.adjustable:hover {
  filter: brightness(1.08);
}
.asset-project-bar.adjustable .resize-handle {
  top: 0;
  bottom: 0;
}
.asset-project-bar.adjustable:focus-visible {
  outline: 2px solid var(--fs-blue, #1456f0);
  outline-offset: 2px;
}
