/* 全局样式 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Microsoft YaHei', '微软雅黑', Arial, sans-serif;
  background: linear-gradient(135deg, #0f2027 0%, #203a43 50%, #2c5364 100%);
  background-attachment: fixed;
  min-height: 100vh;
  color: #333;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Logo区域 */
.logo-section {
  text-align: left;
}

.logo {
  max-width: 100px;
  height: auto;
}


.container {
  max-width: 900px;
  margin: 0 auto;
  padding: 20px;
}

/* 头部样式 */
.header {
  background: rgba(255, 255, 255, 0.98);
  border-radius: 20px;
  padding: 40px 30px;
  margin-bottom: 25px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.25);
  text-align: center;
  backdrop-filter: blur(10px);
}

.header h1 {
  color: #00d4ff;
  font-size: 32px;
  margin-bottom: 15px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
  font-weight: 700;
  letter-spacing: 0.5px;
}

.header .subtitle {
  color: #666;
  font-size: 16px;
  margin-bottom: 12px;
  font-weight: 500;
}

.header .core-info {
  color: #00d4ff;
  font-weight: 600;
  font-size: 15px;
  line-height: 1.6;
}

/* 前言区域 */
.intro-section {
  background: rgba(255, 255, 255, 0.98);
  border-radius: 20px;
  padding: 30px;
  margin-bottom: 25px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(10px);
}

.intro-section h2 {
  color: #00d4ff;
  font-size: 24px;
  margin-bottom: 18px;
  font-weight: 700;
}

.intro-section p {
  color: #555;
  margin-bottom: 15px;
  text-align: justify;
  font-size: 15px;
  line-height: 1.8;
}

.test-info {
  background: linear-gradient(135deg, #e6f7ff 0%, #f0f8ff 100%);
  padding: 20px;
  border-radius: 12px;
  margin-top: 20px;
  border-left: 5px solid #00d4ff;
  box-shadow: 0 2px 8px rgba(0, 212, 255, 0.1);
}

.test-info h3 {
  color: #00d4ff;
  margin-bottom: 12px;
  font-size: 18px;
  font-weight: 700;
}

.test-info p {
  margin: 8px 0;
  color: #333;
  font-size: 15px;
}

/* 答题区域 */
.questions-section {
  background: rgba(255, 255, 255, 0.98);
  border-radius: 20px;
  padding: 35px;
  margin-bottom: 25px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(10px);
}

/* 进度条容器 */
.progress-container {
  margin-bottom: 30px;
  transition: all 0.3s ease;
}

/* 进度条吸顶效果 */
.progress-container.sticky {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  padding: 15px 0;
  animation: slideDown 0.3s ease;
}

@keyframes slideDown {
  from {
    transform: translateY(-100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.progress-wrapper {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 20px;
}

.progress-bar {
  background: #e8e8e8;
  height: 10px;
  border-radius: 10px;
  margin-bottom: 10px;
  overflow: hidden;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.progress-fill {
  background: linear-gradient(90deg, #00d4ff, #0099cc);
  height: 100%;
  width: 0%;
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
}

.progress-text {
  text-align: center;
  color: #666;
  font-size: 15px;
  font-weight: 600;
}

/* 当进度条吸顶时，为内容添加占位空间 */
.progress-placeholder {
  height: 80px;
  display: none;
}

.progress-placeholder.active {
  display: block;
}

.section-title {
  color: #00d4ff;
  font-size: 20px;
  margin: 35px 0 25px 0;
  padding-bottom: 12px;
  border-bottom: 3px solid #00d4ff;
  font-weight: 700;
  position: relative;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -3px;
  left: 0;
  width: 60px;
  height: 3px;
  background: #0099cc;
}

.section-title:first-child {
  margin-top: 0;
}

.question-card {
  background: linear-gradient(135deg, #fafafa 0%, #f5f5f5 100%);
  border-radius: 15px;
  padding: 25px;
  margin-bottom: 20px;
  border: 2px solid #e0e0e0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.question-card:hover {
  border-color: #00d4ff;
  box-shadow: 0 8px 20px rgba(0, 212, 255, 0.15);
  transform: translateY(-2px);
}

.question-number {
  color: #00d4ff;
  font-weight: 700;
  font-size: 17px;
  margin-bottom: 12px;
  display: inline-block;
  padding: 4px 12px;
  background: rgba(0, 212, 255, 0.1);
  border-radius: 6px;
}

.question-text {
  color: #333;
  font-size: 16px;
  margin-bottom: 18px;
  line-height: 1.9;
  font-weight: 500;
}

.options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.option-label {
  display: flex;
  align-items: center;
  padding: 15px 18px;
  background: white;
  border: 2px solid #e0e0e0;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.option-label::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, rgba(0, 212, 255, 0.05), rgba(0, 212, 255, 0.1));
  transition: width 0.3s ease;
}

.option-label:hover {
  border-color: #00d4ff;
  background: #f8fcff;
  transform: translateX(3px);
}

.option-label:hover::before {
  width: 100%;
}

.option-label input[type="radio"] {
  margin-right: 12px;
  cursor: pointer;
  width: 20px;
  height: 20px;
  accent-color: #00d4ff;
}

.option-label span {
  flex: 1;
  font-size: 15px;
  line-height: 1.6;
}

.option-label input[type="radio"]:checked + span {
  color: #00d4ff;
  font-weight: 600;
}

.option-label.selected {
  border-color: #00d4ff;
  background: linear-gradient(135deg, #e6f7ff 0%, #f0f8ff 100%);
  box-shadow: 0 4px 12px rgba(0, 212, 255, 0.2);
}

/* 提交按钮 */
.submit-section {
  text-align: center;
  margin: 35px 0 20px 0;
}

.submit-btn {
  background: linear-gradient(135deg, #00d4ff, #0099cc);
  color: white;
  border: none;
  padding: 16px 60px;
  font-size: 18px;
  font-weight: 600;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 8px 20px rgba(0, 212, 255, 0.4);
  letter-spacing: 0.5px;
}

.submit-btn:hover:not(:disabled) {
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(0, 212, 255, 0.5);
}

.submit-btn:active:not(:disabled) {
  transform: translateY(-1px);
}

.submit-btn:disabled {
  background: linear-gradient(135deg, #ccc, #aaa);
  cursor: not-allowed;
  box-shadow: none;
  opacity: 0.7;
}

/* 结果展示 */
.result-section {
  background: rgba(255, 255, 255, 0.98);
  border-radius: 20px;
  padding: 45px 35px;
  margin-bottom: 25px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(10px);
  display: none;
}

.result-section.show {
  display: block;
  animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.result-header {
  text-align: center;
  margin-bottom: 35px;
  padding-bottom: 25px;
  border-bottom: 2px solid #f0f0f0;
}

.result-header h2 {
  color: #00d4ff;
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 20px;
}

.result-score {
  font-size: 64px;
  font-weight: 800;
  margin: 25px 0;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.1);
  animation: scaleIn 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes scaleIn {
  from {
    transform: scale(0.5);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.result-score.high {
  color: #ffd700;
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.3);
}

.result-score.medium {
  color: #00d4ff;
  text-shadow: 0 0 20px rgba(0, 212, 255, 0.3);
}

.result-score.low {
  color: #ff9800;
  text-shadow: 0 0 20px rgba(255, 152, 0, 0.3);
}

.result-level {
  font-size: 30px;
  font-weight: 700;
  margin-bottom: 15px;
  letter-spacing: 1px;
}

.result-level.high {
  color: #ffd700;
}

.result-level.medium {
  color: #00d4ff;
}

.result-level.low {
  color: #ff9800;
}

.result-content {
  background: linear-gradient(135deg, #fafafa 0%, #f5f5f5 100%);
  padding: 28px;
  border-radius: 15px;
  margin-bottom: 20px;
  border-left: 5px solid #00d4ff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.result-content h3 {
  color: #00d4ff;
  font-size: 22px;
  margin-bottom: 15px;
  font-weight: 700;
}

.result-content p {
  color: #555;
  line-height: 2;
  text-align: justify;
  font-size: 15px;
}

.welfare-section {
  background: linear-gradient(135deg, #00d4ff 0%, #0099cc 100%);
  color: white;
  padding: 35px 30px;
  border-radius: 15px;
  text-align: center;
  box-shadow: 0 8px 24px rgba(0, 212, 255, 0.3);
  margin-top: 30px;
}

.welfare-section h3 {
  font-size: 26px;
  margin-bottom: 18px;
  font-weight: 700;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.welfare-section p {
  margin: 12px 0;
  line-height: 1.9;
  font-size: 16px;
}

.qrcode-container {
  margin: 30px 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

.qrcode-img {
  max-width: 220px;
  width: 100%;
  height: auto;
  border-radius: 15px;
  background: white;
  padding: 15px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease;
}

.qrcode-img:hover {
  transform: scale(1.05);
}

/* 隐藏答题区域 */
.questions-section.hidden {
  display: none;
}

/* 页脚 */
.footer {
  text-align: center;
  color: rgba(255, 255, 255, 0.9);
  padding: 25px 20px;
  font-size: 14px;
  font-weight: 500;
}

/* 加载动画 */
.loading {
  text-align: center;
  padding: 40px 20px;
  color: #00d4ff;
  font-size: 18px;
  font-weight: 600;
}

.loading::after {
  content: '...';
  animation: dots 1.5s steps(4, end) infinite;
}

@keyframes dots {
  0%, 20% {
    content: '.';
  }
  40% {
    content: '..';
  }
  60%, 100% {
    content: '...';
  }
}

/* 响应式设计 - 平板 */
@media (max-width: 768px) {
  .logo-section {
    /* padding: 20px 15px 15px 15px; */
  }

  .logo {
    max-width: 100px;
  }

  .container {
    padding: 15px;
  }

  .progress-wrapper {
    padding: 0 15px;
  }

  .progress-container.sticky {
    padding: 12px 0;
  }

  .header {
    padding: 30px 20px;
    border-radius: 15px;
    margin-bottom: 20px;
  }

  .header h1 {
    font-size: 24px;
    line-height: 1.4;
  }

  .header .subtitle {
    font-size: 14px;
  }

  .header .core-info {
    font-size: 13px;
  }

  .intro-section {
    padding: 25px 20px;
    border-radius: 15px;
  }

  .intro-section h2 {
    font-size: 20px;
  }

  .intro-section p {
    font-size: 14px;
  }

  .questions-section {
    padding: 25px 20px;
    border-radius: 15px;
  }

  .section-title {
    font-size: 18px;
    margin: 25px 0 20px 0;
  }

  .question-card {
    padding: 20px;
  }

  .question-number {
    font-size: 15px;
  }

  .question-text {
    font-size: 15px;
  }

  .option-label {
    padding: 12px 15px;
  }

  .option-label span {
    font-size: 14px;
  }

  .submit-btn {
    padding: 14px 45px;
    font-size: 16px;
    width: 100%;
    max-width: 300px;
  }

  .result-section {
    padding: 35px 25px;
    border-radius: 15px;
  }

  .result-header h2 {
    font-size: 28px;
  }

  .result-score {
    font-size: 48px;
  }

  .result-level {
    font-size: 22px;
  }

  .result-content {
    padding: 20px;
  }

  .result-content h3 {
    font-size: 18px;
  }

  .result-content p {
    font-size: 14px;
  }

  .welfare-section {
    padding: 25px 20px;
  }

  .welfare-section h3 {
    font-size: 20px;
  }

  .welfare-section p {
    font-size: 14px;
  }

  .qrcode-img {
    max-width: 180px;
  }
}

/* 响应式设计 - 手机 */
@media (max-width: 480px) {
  .logo-section {
    /* padding: 15px 10px 10px 10px; */
  }

  .logo {
    max-width: 100px;
  }

  .container {
    padding: 10px;
  }

  .progress-wrapper {
    padding: 0 10px;
  }

  .progress-container.sticky {
    padding: 10px 0;
  }

  .progress-bar {
    height: 8px;
  }

  .progress-text {
    font-size: 13px;
  }

  .header {
    padding: 25px 15px;
    margin-bottom: 15px;
  }

  .header h1 {
    font-size: 20px;
  }

  .header .subtitle {
    font-size: 13px;
  }

  .header .core-info {
    font-size: 12px;
  }

  .intro-section {
    padding: 20px 15px;
    margin-bottom: 15px;
  }

  .intro-section h2 {
    font-size: 18px;
  }

  .intro-section p {
    font-size: 13px;
  }

  .test-info {
    padding: 15px;
  }

  .test-info h3 {
    font-size: 16px;
  }

  .test-info p {
    font-size: 13px;
  }

  .questions-section {
    padding: 20px 15px;
    margin-bottom: 15px;
  }

  .progress-bar {
    height: 8px;
  }

  .progress-text {
    font-size: 13px;
    margin-bottom: 20px;
  }

  .section-title {
    font-size: 16px;
    margin: 20px 0 15px 0;
  }

  .question-card {
    padding: 15px;
    margin-bottom: 15px;
  }

  .question-number {
    font-size: 14px;
    padding: 3px 10px;
  }

  .question-text {
    font-size: 14px;
    margin-bottom: 15px;
  }

  .options {
    gap: 10px;
  }

  .option-label {
    padding: 12px;
  }

  .option-label input[type="radio"] {
    width: 18px;
    height: 18px;
    margin-right: 10px;
  }

  .option-label span {
    font-size: 13px;
  }

  .submit-section {
    margin: 25px 0 15px 0;
  }

  .submit-btn {
    padding: 13px 35px;
    font-size: 15px;
    width: 100%;
  }

  .result-section {
    padding: 25px 15px;
    margin-bottom: 15px;
  }

  .result-header {
    margin-bottom: 25px;
    padding-bottom: 20px;
  }

  .result-header h2 {
    font-size: 24px;
  }

  .result-score {
    font-size: 42px;
    margin: 20px 0;
  }

  .result-level {
    font-size: 19px;
  }

  .result-content {
    padding: 18px;
    margin-bottom: 15px;
  }

  .result-content h3 {
    font-size: 17px;
  }

  .result-content p {
    font-size: 13px;
    line-height: 1.8;
  }

  .welfare-section {
    padding: 20px 15px;
  }

  .welfare-section h3 {
    font-size: 18px;
  }

  .welfare-section p {
    font-size: 13px;
    margin: 10px 0;
  }

  .qrcode-container {
    margin: 20px 0;
  }

  .qrcode-img {
    max-width: 160px;
    padding: 12px;
  }

  .footer {
    padding: 20px 15px;
    font-size: 12px;
  }
}

/* 超小屏幕优化 */
@media (max-width: 360px) {
  .header h1 {
    font-size: 18px;
  }

  .result-score {
    font-size: 36px;
  }

  .qrcode-img {
    max-width: 140px;
  }
}
