.codex-diff-previewer {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.codex-diff-previewer__header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  flex-wrap: wrap;
}

.codex-diff-previewer__title {
  font-size: 15px;
  font-weight: 700;
  color: #f5f5f5;
  margin-bottom: 4px;
}

.codex-diff-previewer__stats {
  justify-content: flex-end;
}

.codex-diff-previewer__file-name {
  font-size: 13px;
  font-weight: 600;
  color: #f8fafc;
}

.codex-diff-previewer__file-path {
  font-size: 12px;
  word-break: break-all;
}

.codex-diff-previewer__diff-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.codex-diff-previewer__diff-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.codex-diff-previewer__diff-section {
  position: relative;
  border: 0;
  background: rgba(15, 23, 42, 0.56);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  box-sizing: border-box;
}

.codex-diff-previewer__diff-section--expanded {
  position: fixed;
  inset: 0;
  z-index: 1250;
  border-radius: 0;
  border-inline: 0;
  background: #0f172a;
  box-shadow:
    0 28px 72px rgba(15, 23, 42, 0.38),
    0 12px 28px rgba(15, 23, 42, 0.2);
}

.codex-diff-previewer__diff-toggle {
  width: 100%;
  border: 0;
  background: transparent;
  color: inherit;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 88px 14px 16px;
  text-align: left;
  cursor: pointer;
}

.codex-diff-previewer__diff-toggle:hover {
  background: rgba(13, 49, 60, 0.38);
}

.codex-diff-previewer__diff-toggle-main {
  min-width: 0;
  flex-wrap: wrap;
}

.codex-diff-previewer__diff-body {
  padding: 0;
}

.codex-diff-previewer__diff-section--expanded .codex-diff-previewer__diff-body {
  height: calc(100vh - 60px);
  overflow: auto;
}

.codex-diff-previewer__diff-actions {
  position: absolute;
  top: 10px;
  right: 12px;
  z-index: 1;
}

.codex-diff-previewer__diff-actions .ant-btn {
  color: rgba(226, 232, 240, 0.88);
}

.codex-diff-previewer__diff-actions .ant-btn:hover {
  color: #ffffff;
  background: rgba(148, 163, 184, 0.16);
}

@media (max-width: 960px) {
  .codex-diff-previewer__diff-toggle {
    flex-direction: column;
    align-items: flex-start;
    padding-right: 72px;
  }

  .codex-diff-previewer__diff-actions {
    top: 12px;
    right: 10px;
  }
}
