* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  background: #f5f5f5;
  color: #333;
}

.navbar {
  background: #fff;
  padding: 15px 30px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  margin-bottom: 20px;
}

.navbar a {
  margin-right: 20px;
  text-decoration: none;
  color: #333;
  font-weight: 500;
}

.navbar a:hover {
  color: #ff2442;
}

.container {
  display: flex;
  gap: 20px;
  padding: 0 20px;
  max-width: 1400px;
  margin: 0 auto;
}

.left-panel {
  width: 400px;
  background: #fff;
  padding: 20px;
  border-radius: 8px;
  height: fit-content;
}

.right-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.top-section, .bottom-section {
  background: #fff;
  padding: 20px;
  border-radius: 8px;
}

.top-section {
  flex: 0 0 auto;
}

.bottom-section {
  flex: 1;
}

h3 {
  margin-bottom: 15px;
  color: #ff2442;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
}

.radio-group-inline {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

.radio-group-inline label {
  display: flex;
  align-items: center;
  margin-bottom: 0;
  font-weight: normal;
}

.radio-group-three-columns {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.radio-group-three-columns label {
  display: flex;
  align-items: center;
  margin-bottom: 0;
  font-weight: normal;
}

.checkbox-group-two-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.checkbox-group-two-columns label {
  display: flex;
  align-items: center;
  font-weight: normal;
}

.form-group input[type="radio"],
.form-group input[type="checkbox"] {
  margin-right: 8px;
}

textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
  resize: vertical;
}

.btn-primary {
  width: 100%;
  padding: 12px;
  background: #ff2442;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
}

.btn-primary:hover:not(:disabled) {
  background: #e61e3a;
}

.btn-primary:disabled {
  background: #ccc;
  cursor: not-allowed;
}

.btn-secondary {
  padding: 8px 16px;
  background: #fff;
  color: #ff2442;
  border: 1px solid #ff2442;
  border-radius: 4px;
  cursor: pointer;
  margin-right: 10px;
}

.btn-secondary:hover {
  background: #fff5f7;
}

.result-box {
  padding: 15px;
  background: #f9f9f9;
  border-radius: 4px;
  min-height: 150px;
}

.result-box p {
  line-height: 1.8;
  margin-bottom: 15px;
}

.result-actions {
  margin-top: 15px;
}

.placeholder {
  padding: 40px;
  text-align: center;
  color: #999;
}

/* 设定页面 */
.settings-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.settings-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.tabs {
  background: #fff;
  padding: 10px;
  border-radius: 8px 8px 0 0;
  display: flex;
  gap: 10px;
}

.tabs button {
  padding: 10px 20px;
  border: none;
  background: transparent;
  cursor: pointer;
  border-radius: 4px;
  font-size: 14px;
}

.tabs button.active {
  background: #ff2442;
  color: #fff;
}

.tab-content {
  background: #fff;
  padding: 30px;
  border-radius: 0 0 8px 8px;
  min-height: 500px;
}

.list-item, .disturbance-item {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
  align-items: center;
}

.list-input {
  flex: 1;
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.short-input {
  width: 80px;
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.medium-input {
  width: 150px;
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.long-input {
  flex: 1;
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.btn-delete, .btn-delete-small {
  padding: 6px 12px;
  background: #ff4d4f;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
}

.btn-delete:hover, .btn-delete-small:hover {
  background: #ff7875;
}

.btn-add {
  padding: 8px 16px;
  background: #52c41a;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  margin-top: 10px;
}

.btn-add:hover {
  background: #73d13d;
}

.btn-danger {
  padding: 10px 20px;
  background: #ff4d4f;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

.btn-danger:hover {
  background: #ff7875;
}

/* 历史页面 */
.history-container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 20px;
}

.history-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.empty-state {
  text-align: center;
  padding: 60px;
  color: #999;
  background: #fff;
  border-radius: 8px;
}

.history-card {
  background: #fff;
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 15px;
}

.history-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
  padding-bottom: 10px;
  border-bottom: 1px solid #f0f0f0;
}

.history-id {
  font-weight: bold;
  color: #ff2442;
}

.history-time {
  color: #999;
  font-size: 14px;
}

.history-info {
  margin-bottom: 15px;
  font-size: 14px;
  line-height: 1.8;
}

.history-text {
  background: #f9f9f9;
  padding: 15px;
  border-radius: 4px;
  margin-bottom: 15px;
}

.history-text p {
  line-height: 1.8;
  margin-top: 10px;
}

.history-actions {
  display: flex;
  gap: 10px;
}

/* 模态框 */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.modal-content {
  background: #fff;
  padding: 30px;
  border-radius: 8px;
  max-width: 800px;
  max-height: 80vh;
  overflow-y: auto;
  width: 90%;
}

.detail-section {
  margin-bottom: 20px;
}

.detail-section h4 {
  margin-bottom: 10px;
  color: #333;
}

.detail-section ul {
  padding-left: 20px;
}

.detail-section li {
  margin-bottom: 5px;
}

.detail-section pre {
  background: #f5f5f5;
  padding: 15px;
  border-radius: 4px;
  overflow-x: auto;
  white-space: pre-wrap;
  font-size: 12px;
  line-height: 1.6;
}
