.shared-chat-management-page {
  display: flex;
  width: 100%;
  height: 100%;
  min-height: 100%;
  min-width: 0;
  flex-direction: column;
  overflow: hidden;
}

.shared-chat-management-page .ant-card,
.shared-chat-management-page__card,
.shared-chat-management-page__card > .ant-card-body {
  width: 100%;
  height: 100%;
  min-height: 100%;
  min-width: 0;
}

.shared-chat-management-page__card {
  flex: 1 1 auto;
}

.shared-chat-management-page .ant-card,
.shared-chat-management-page__card,
.shared-chat-management-page__card > .ant-card-body {
  display: flex;
  flex-direction: column;
}

.shared-chat-management-page__card > .ant-card-body {
  min-height: 0;
  overflow: hidden;
}

.shared-chat-management-page__layout {
  display: grid;
  flex: 1 1 auto;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto minmax(0, 1fr);
  gap: 20px;
  min-height: 0;
  overflow: hidden;
}

.shared-chat-management-page__steps {
  min-height: 0;
  min-width: 0;
  border-bottom: 1px solid #eef2f7;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 12px;
}

.shared-chat-management-page__steps .ant-steps {
  min-width: 640px;
}

.shared-chat-management-page__content {
  display: flex;
  flex: 1 1 auto;
  min-height: 0;
  min-width: 0;
  flex-direction: column;
  gap: 16px;
  overflow: hidden;
}

.shared-chat-management-page__stage {
  display: flex;
  flex: 1 1 auto;
  min-height: 0;
  min-width: 0;
  flex-direction: column;
  gap: 16px;
}

.shared-chat-management-page__stage-body {
  display: flex;
  flex: 1 1 auto;
  min-height: 0;
  min-width: 0;
  flex-direction: column;
  gap: 16px;
  overflow: auto;
  overscroll-behavior: contain;
  padding-right: 4px;
  padding-bottom: 8px;
  -webkit-overflow-scrolling: touch;
}

.shared-chat-management-page__panel {
  flex: 0 0 auto;
  padding: 0;
}

.shared-chat-management-page__panel .ant-card-body {
  padding: 0;
}

.shared-chat-management-page__option-list {
  display: grid;
  gap: 12px;
}

.shared-chat-management-page__option-card {
  display: flex;
  width: 100%;
  min-width: 0;
  flex-direction: column;
  gap: 10px;
  border: 1px solid #d7deea;
  border-radius: 18px;
  background: #fff;
  padding: 16px 18px;
  text-align: left;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.shared-chat-management-page__option-card:hover {
  border-color: #8ab4ff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  transform: translateY(-1px);
}

.shared-chat-management-page__option-card--active {
  border-color: #1d4ed8;
  box-shadow: 0 0 0 3px rgba(29, 78, 216, 0.12);
}

.shared-chat-management-page__option-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.shared-chat-management-page__field-grid,
.shared-chat-management-page__result-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 16px;
}

.shared-chat-management-page__field {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 8px;
}

.shared-chat-management-page__field > span {
  color: #475569;
  font-size: 13px;
  font-weight: 600;
}

.shared-chat-management-page__field--full {
  grid-column: 1 / -1;
}

.shared-chat-management-page__checkbox-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-radius: 16px;
  background: #f8fafc;
  padding: 14px 16px;
}

.shared-chat-management-page__summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  border-radius: 18px;
  background: linear-gradient(135deg, #f8fafc, #eef4ff);
  padding: 16px 18px;
}

.shared-chat-management-page__summary-value {
  margin-top: 6px;
  color: #0f172a;
  font-size: 16px;
  font-weight: 700;
}

.shared-chat-management-page__tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.shared-chat-management-page__actions {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex: 0 0 auto;
  border-top: 1px solid #eef2f7;
  padding-top: 16px;
  padding-bottom: calc(4px + env(safe-area-inset-bottom, 0px));
  background: linear-gradient(180deg, rgba(255, 255, 255, 0), #fff 18px);
}

@media (max-width: 720px) {
  .shared-chat-management-page__card > .ant-card-head {
    padding-inline: 14px;
  }

  .shared-chat-management-page__card > .ant-card-body {
    padding: 14px;
  }

  .shared-chat-management-page__layout {
    gap: 14px;
  }

  .shared-chat-management-page__content {
    gap: 14px;
  }

  .shared-chat-management-page__stage,
  .shared-chat-management-page__stage-body {
    gap: 14px;
  }

  .shared-chat-management-page__stage-body {
    padding-right: 0;
    padding-bottom: 12px;
  }

  .shared-chat-management-page__field-grid,
  .shared-chat-management-page__result-grid,
  .shared-chat-management-page__summary {
    grid-template-columns: 1fr;
  }

  .shared-chat-management-page__actions {
    flex-direction: column;
    padding-top: 14px;
    padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px));
  }

  .shared-chat-management-page__actions .ant-btn {
    width: 100%;
  }
}
