/* 基础样式重置 */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Segoe UI', system-ui, sans-serif;
}

body {
  width: 100%;
  min-height: 100vh;
  padding: 30px 20px;
  background: linear-gradient(135deg, #f0f4f8 0%, #dfe8f3 100%);
  color: #2d3748;
}

.container {
  max-width: 800px;
  margin: 0 auto;
}

h1 {
  text-align: center;
  font-size: 28px;
  color: #2c5282;
  margin-bottom: 25px;
  font-weight: 600;
}

h2 {
  font-size: 22px;
  color: #2b6cb0;
  margin: 25px 0 15px;
  padding-bottom: 8px;
  border-bottom: 2px solid #cbd5e0;
  font-weight: 500;
}

/* 分区样式 */
.section {
  background: white;
  border-radius: 14px;
  padding: 25px;
  margin-bottom: 30px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
}

/* 输入组样式 */
.input-group {
  margin-bottom: 20px;
}

label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  color: #4a5568;
}

textarea, input[type="file"] {
  width: 100%;
  padding: 14px;
  border: 2px solid #cbd5e0;
  border-radius: 10px;
  font-size: 16px;
  transition: border-color 0.3s;
  background: #f7fafc;
}

textarea {
  min-height: 120px;
  resize: vertical;
}

textarea:focus {
  border-color: #4299e1;
  outline: none;
  box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.2);
}

/* 控制组样式 */
.controls {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin: 25px 0;
}

.control {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* 滑块样式 */
input[type="range"] {
  width: 100%;
  height: 8px;
  border-radius: 4px;
  background: #cbd5e0;
  outline: none;
  -webkit-appearance: none;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #4299e1;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

select {
  padding: 10px 14px;
  border: 2px solid #cbd5e0;
  border-radius: 10px;
  font-size: 16px;
  background: #f7fafc;
  width: 100%;
}

/* 按钮样式 */
#generate-btn {
  padding: 14px 24px;
  background: #4299e1;
  color: white;
  border: none;
  border-radius: 10px;
  font-size: 18px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  display: block;
  width: 100%;
  max-width: 300px;
  margin: 20px auto;
  box-shadow: 0 4px 8px rgba(66, 153, 225, 0.3);
}

#generate-btn:hover {
  background: #3182ce;
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(66, 153, 225, 0.4);
}

/* 二维码展示区 */
#generated-qr {
  min-height: 250px;
  display: flex;
  justify-content: center;
  align-items: center;
  background: #f8fafc;
  border-radius: 12px;
  margin: 20px 0;
  padding: 20px;
  border: 2px dashed #cbd5e0;
}

/* 操作按钮 */
.actions {
  display: flex;
  gap: 15px;
  justify-content: center;
  margin-top: 20px;
}

.actions button {
  padding: 12px 22px;
  border: none;
  border-radius: 10px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  flex: 1;
  max-width: 180px;
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.1);
}

#download-generated {
  background: #38a169;
  color: white;
}

#download-generated:hover {
  background: #2f855a;
}

#copy-generated {
  background: #ed8936;
  color: white;
}

#copy-generated:hover {
  background: #dd6b20;
}

/* 解析结果样式 */
#parsed-result {
  margin-top: 25px;
  padding-top: 20px;
}

#result-content {
  background: #f7fafc;
  border-radius: 10px;
  padding: 20px;
  margin-top: 15px;
  border: 2px solid #e2e8f0;
  min-height: 120px;
  font-size: 16px;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-all;
}

/* 分隔线 */
.divider {
  height: 1px;
  background: linear-gradient(to right, transparent, #cbd5e0, transparent);
  margin: 25px 0;
}