/**
 * @file web/src/components/changelog/ChangelogView.module.css
 * @description Two-phase changelog modal styles (TUI parity).
 */

.backdrop {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  width: 100%;
  padding: 24px;
}

.modal {
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  background: var(--color-bg-card, #080908);
  border: 1px solid var(--color-border, #161a16);
  border-radius: 14px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  flex: 1;
  min-height: 0;
}

.header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--color-border);
}

.titleRow {
  display: flex;
  align-items: center;
  gap: 12px;
}

.title {
  font-size: 16px;
  font-weight: 700;
  margin: 0;
  color: var(--color-text);
  flex: 1;
  min-width: 0;
}

.backBtn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  background: var(--color-surface);
  color: var(--color-text);
  border: 1px solid var(--color-border);
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  font-family: var(--font-sans);
  white-space: nowrap;
}
.backBtn:hover { background: var(--color-bg-hover); border-color: var(--color-text-muted); }

.closeBtn {
  background: transparent;
  border: none;
  color: var(--color-text-muted);
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.closeBtn:hover { color: var(--color-text); background: var(--color-bg-hover); }

.body {
  flex: 1;
  overflow-y: auto;
  padding: 16px 20px 20px;
}

.indexWrap {}
.indexHint {
  margin: 0 0 12px;
  font-size: 11px;
  color: var(--color-text-muted);
}

.versionList {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.versionBtn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  padding: 8px 12px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 6px;
  cursor: pointer;
  text-align: left;
  transition: all 100ms;
  font-family: var(--font-sans);
}
.versionBtn:hover { background: var(--color-bg-hover); border-color: var(--color-text-muted); }
.versionLabel {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  color: var(--color-text);
}
.versionSummary {
  font-size: 11px;
  color: var(--color-text-muted);
}

.details { display: flex; flex-direction: column; gap: 14px; }
.section {}
.sectionTitle {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--color-text-muted);
  margin: 0 0 6px;
}
.itemList {
  list-style: disc;
  padding-left: 20px;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.item {
  font-size: 12px;
  color: var(--color-text);
  line-height: 1.55;
  word-break: break-word;
}

.empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--color-text-dim);
  font-size: 13px;
}
