/* 摆烂大学 - 证书生成器UI优化补丁 */

/* 证书容器增强 */
.certificate-preview {
  position: relative;
  background: linear-gradient(135deg, #fff9f0 0%, #fff 50%, #fff9f0 100%);
  border: 8px solid #d4a574;
  border-radius: 12px;
  box-shadow: 
    0 0 0 2px #8b6914,
    0 0 0 4px #d4a574,
    0 10px 40px rgba(0,0,0,0.15);
  padding: 40px;
  max-width: 800px;
  margin: 0 auto;
}

/* 盖章样式 - 提前展示 */
.certificate-stamp {
  position: absolute;
  width: 120px;
  height: 120px;
  right: 60px;
  bottom: 80px;
  background: radial-gradient(circle, rgba(200,50,50,0.9) 0%, rgba(180,40,40,0.95) 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  color: white;
  font-size: 14px;
  text-align: center;
  line-height: 1.3;
  box-shadow: 
    0 0 0 3px rgba(200,50,50,0.3),
    0 4px 15px rgba(0,0,0,0.2),
    inset 0 0 20px rgba(0,0,0,0.1);
  transform: rotate(-15deg);
  animation: stampAppear 0.6s ease-out;
  z-index: 10;
}

.certificate-stamp::before {
  content: '';
  position: absolute;
  inset: 8px;
  border: 2px dashed rgba(255,255,255,0.6);
  border-radius: 50%;
}

.certificate-stamp-text {
  position: relative;
  z-index: 1;
}

/* 盖章动画 */
@keyframes stampAppear {
  0% {
    transform: rotate(-15deg) scale(2);
    opacity: 0;
  }
  50% {
    transform: rotate(-15deg) scale(0.9);
  }
  100% {
    transform: rotate(-15deg) scale(1);
    opacity: 1;
  }
}

/* 证书标题样式 */
.certificate-title {
  font-size: 32px;
  font-weight: bold;
  color: #8b6914;
  text-align: center;
  margin-bottom: 30px;
  font-family: 'SimSun', serif;
  letter-spacing: 8px;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

/* 证书内容样式 */
.certificate-content {
  font-size: 18px;
  line-height: 2;
  color: #333;
  text-align: justify;
  padding: 20px 40px;
}

/* 校长签名区域 */
.certificate-signature {
  margin-top: 40px;
  text-align: right;
  padding-right: 60px;
}

.certificate-signature-name {
  font-size: 20px;
  font-weight: bold;
  color: #333;
  font-family: 'KaiTi', cursive;
}

.certificate-signature-title {
  font-size: 14px;
  color: #666;
  margin-top: 5px;
}

/* 证书标签页优化 */
.certificate-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
  padding: 0 20px;
}

.certificate-tab {
  flex: 1;
  padding: 12px 20px;
  background: linear-gradient(135deg, #f5f5f5 0%, #e8e8e8 100%);
  border: 2px solid #ddd;
  border-radius: 8px;
  cursor: pointer;
  text-align: center;
  font-weight: 500;
  transition: all 0.3s ease;
}

.certificate-tab:hover {
  background: linear-gradient(135deg, #e8e8e8 0%, #d8d8d8 100%);
  transform: translateY(-2px);
}

.certificate-tab.active {
  background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
  color: white;
  border-color: #7c3aed;
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

/* 下载按钮优化 */
.certificate-download-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 30px;
  background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
  color: white;
  border: none;
  border-radius: 25px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(139, 92, 246, 0.3);
}

.certificate-download-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(139, 92, 246, 0.4);
}

/* 证书边框装饰 */
.certificate-border-decoration {
  position: absolute;
  inset: 15px;
  border: 1px solid rgba(139, 105, 20, 0.3);
  border-radius: 8px;
  pointer-events: none;
}

.certificate-border-decoration::before,
.certificate-border-decoration::after {
  content: '🎓';
  position: absolute;
  font-size: 24px;
  opacity: 0.5;
}

.certificate-border-decoration::before {
  top: 10px;
  left: 10px;
}

.certificate-border-decoration::after {
  bottom: 10px;
  right: 10px;
}

/* 证书编号 */
.certificate-number {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 12px;
  color: #999;
  font-family: monospace;
}

/* 响应式优化 */
@media (max-width: 768px) {
  .certificate-preview {
    padding: 20px;
    margin: 10px;
  }
  
  .certificate-stamp {
    width: 80px;
    height: 80px;
    right: 30px;
    bottom: 60px;
    font-size: 10px;
  }
  
  .certificate-title {
    font-size: 24px;
    letter-spacing: 4px;
  }
  
  .certificate-content {
    font-size: 14px;
    padding: 10px 20px;
  }
}
