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

body {
  font-family: "Segoe UI", "Microsoft YaHei", sans-serif;
  background: linear-gradient(135deg, #e8eef4 0%, #f5f7fa 100%);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.container {
  width: 100%;
  max-width: 620px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 48, 96, 0.12);
  overflow: hidden;
}

.header {
  background: #1e3a5f;
  color: #fff;
  padding: 20px 24px;
  text-align: center;
}

.header h1 {
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.sub {
  margin-top: 6px;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.78);
}

.main {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 0.9rem;
  font-family: "Consolas", "Monaco", monospace;
  color: #222;
  background: #fff;
  cursor: pointer;
}

select:focus {
  outline: none;
  border-color: #1e3a5f;
  box-shadow: 0 0 0 2px rgba(30, 58, 95, 0.15);
}

.generate-btn {
  width: 100%;
  padding: 14px 24px;
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.generate-btn:hover {
  background: #1d4ed8;
}

.generate-btn:active {
  background: #1e40af;
}

.generate-btn.copied {
  background: #059669;
}

.result-area[hidden] {
  display: none !important;
}

.result-area {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid #eee;
}

.result-area label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #333;
  margin-top: 4px;
}

.result-row {
  display: flex;
  gap: 8px;
}

.result-row input {
  flex: 1;
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 0.82rem;
  font-family: "Consolas", "Monaco", monospace;
  letter-spacing: 0;
  color: #222;
  background: #f8fafc;
}

.result-row input:focus {
  outline: none;
  border-color: #1e3a5f;
  box-shadow: 0 0 0 2px rgba(30, 58, 95, 0.15);
}

.copy-btn {
  padding: 10px 20px;
  background: #1e3a5f;
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: 0.9rem;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.2s;
}

.copy-btn:hover {
  background: #2c5282;
}

.copy-btn.copied {
  background: #059669;
}

.hint {
  min-height: 1.2em;
  font-size: 0.85rem;
  color: #059669;
}

.hint.error {
  color: #b45309;
}
