* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: #f1f2f3;
}

.container {
  box-sizing: border-box;
  width: 100%;
  max-width: 1600px;
  min-width: 1240px;
  margin: 20px auto;
  color: #333;
}

.container *{
  box-sizing: border-box;
}

header {
  text-align: center;
  margin-bottom: 25px;
}

h1 {
  font-size: 2.2rem;
  margin-bottom: 5px;
}

.description {
  font-size: 1rem;
  opacity: 0.9;
  max-width: 95%;
  margin: 0 auto;
}


.main-content {
  padding: 20px;
  background: #fff;
  border-radius: 12px;
  margin-bottom: 25px;
}

.container textarea,
.container input {
  width: 100%;
  padding: 15px;
  border: 2px solid #e1e5eb;
  border-radius: 10px;
  font-size: 1rem;
  transition: all 0.3s ease;
  background-color: #f8f9fa;
}

.container textarea:focus,
.container input:focus {
  outline: none;
  border-color: #4d90fe;
  box-shadow: 0 0 0 2px rgba(77, 144, 254, 0.2);
  background-color: white;
}

.container textarea {
  min-height: 150px;
  resize: vertical;
}


.options-group {
  width: 100%;
  display: flex;
  flex-flow: wrap;
  gap: 20px;
}

.option-select {
  width: 100%;
  padding: 12px 15px;
  border: 2px solid #e1e5eb;
  border-radius: 10px;
  font-size: 1rem;
  background-color: #f8f9fa;
  transition: all 0.3s ease;
}

.option-select:focus {
  outline: none;
  border-color: #4d90fe;
  box-shadow: 0 0 0 2px rgba(77, 144, 254, 0.2);
  background-color: white;
}

.input-group {
  margin-bottom: 25px;
}

.options-group .input-group {
  width: calc(25% - 15px);
  margin-bottom: 0;
}

#ivGroup{
  display: flex;
  gap: 20px;
  width: calc(50% - 10px);
}

.options-group #ivGroup .input-group {
  width: calc(50% - 10px);
}

.input-group label {
  display: block;
  margin-bottom: 10px;
  font-weight: 600;
  font-size: 1.1rem;
  color: #2c3e50;
  line-height: 1;
}

.input-group input {
  padding: 12.75px 15px;
}

.key-note {
  font-size: 0.8rem;
  margin-top: 4px;
}

#keyFormatInfo {
  font-weight: 600;
  color: #2980b9;
}

#keyStatus.valid {
  color: #2ecc71;
}

#keyStatus.invalid {
  color: #e74c3c;
}

.key-input {
  display: flex;
  gap: 15px;
  align-items: center;
}

.key-input input {
  flex: 1;
}

.button-group {
  display: flex;
  gap: 20px;
  margin: 25px 0;
  flex-wrap: wrap;
}

.btn {
  padding: 14px 28px;
  min-width: 150px;
  border: none;
  border-radius: 8px;
  font-size: 1.05rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn:active {
  transform: translateY(2px);
}

.btn-encrypt {
  background: linear-gradient(to right, #3498db, #2c80c9);
  color: white;
}

.btn-decrypt {
  background: linear-gradient(to right, #2ecc71, #27ae60);
  color: white;
}

.btn-copy {
  background: linear-gradient(to right, #9b59b6, #8e44ad);
  color: white;
}

.btn-clear {
  background: linear-gradient(to right, #e74c3c, #c0392b);
  color: white;
}

.btn:hover {
  opacity: 0.9;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.result-container{
  margin-bottom: 25px;
}

.result-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 15px;
}

.result-title {
  font-size: 1.4rem;
  font-weight: 600;
  color: #2c3e50;
}

.result-box {
  background-color: #f8f9fa;
  border: 2px solid #e1e5eb;
  border-radius: 10px;
  padding: 20px;
  min-height: 150px;
  font-size: 1.05rem;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-all;
}

.notification {
  position: fixed;
  top: 60px;
  right: 30px;
  padding: 15px 25px;
  background-color: #fff;
  color: #666;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  font-weight: 500;
  transform: translateX(200%);
  transition: transform 0.3s ease;
  z-index: 1000;
}

.notification.show {
  transform: translateX(0);
}

.notification.success {
  background-color: #2ecc71; /* 绿色背景 */
  color: white;
}

.notification.error {
  background-color: #e74c3c; /* 红色背景 */
  color: white;
}

footer {
  text-align: center;
  color: #7f8c8d;
  font-size: 0.95rem;
}

.algorithm-info {
  background-color: #f0f7ff;
  border-left: 4px solid #3498db;
  padding: 20px;
  border-radius: 0 8px 8px 0;
}

.algorithm-info h3 {
  margin-bottom: 10px;
  color: #2980b9;
}

.algorithm-info p {
  margin-top: 6px;
  line-height: 1.6;
}
