/* 咨询按钮样式 */
.consult-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 70px;
    height: 70px;
    background-color: #0e81b0;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.4);
    transition: all 0.3s ease;
    z-index: 1000;
}

.consult-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 20px rgba(52, 152, 219, 0.6);
}

.consult-btn i {
    font-size: 1.8rem;
    color: white;
}

.consult-btn .pulse {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: rgba(52, 152, 219, 0.4);
    animation: pulse 2s infinite;
    z-index: -1;
}

@keyframes pulse {
    0% {
        transform: scale(0.8);
        opacity: 0.8;
    }
    100% {
        transform: scale(1.4);
        opacity: 0;
    }
}

/* 弹窗样式 */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 20000;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: white;
    width: 90%;
    max-width: 500px;
    border-radius: 20px;
    overflow: hidden;
    transform: translateY(-50px);
    transition: transform 0.5s ease;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.modal-overlay.active .modal {
    transform: translateY(0);
}

.modal-header {
    background-color: #0e81b0;
    padding: 25px;
    color: white;
    text-align: center;
    position: relative;
}

.modal-header h2 {
    font-size: 1.8rem;
    margin-bottom: 8px;
}

.modal-header p {
    font-size: 1rem;
    opacity: 0.9;
}

.close-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(255, 255, 255, 0.2);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: background 0.3s ease;
}

.close-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

.close-btn i {
    color: white;
    font-size: 1.2rem;
}

.modal-content {
    padding: 30px;
    text-align: center;
}

.qrcode-container {
    width: 220px;
    height: 220px;
    margin: 0 auto 25px;
    padding: 15px;
    border-radius: 12px;
    background: #f8f9fa;
    border: 1px solid #eaeaea;
    display: flex;
    justify-content: center;
    align-items: center;
}

.qrcode {
    width: 190px;
    height: 190px;
    background: #f0f0f0;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1rem;
    color: #7f8c8d;
    position: relative;
    overflow: hidden;
}

/* .qrcode::before {
    content: "";
    position: absolute;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(45deg, transparent 45%, #3498db 50%, transparent 55%),
        linear-gradient(-45deg, transparent 45%, #3498db 50%, transparent 55%),
        repeating-linear-gradient(90deg, #f0f0f0 0px, #f0f0f0 10px, #e0e0e0 10px, #e0e0e0 20px),
        repeating-linear-gradient(0deg, #f0f0f0 0px, #f0f0f0 10px, #e0e0e0 10px, #e0e0e0 20px);
    background-size: 100% 100%, 100% 100%, 100% 100%, 100% 100%;
    background-position: center;
} */

.qrcode::after {
    /* content: "扫码咨询"; */
    position: absolute;
    bottom: 15px;
    font-weight: bold;
    color: #2c3e50;
    font-size: 1.1rem;
}

.modal-text {
    color: #555;
    line-height: 1.6;
    margin-bottom: 20px;
    font-size: 1.05rem;
}

.instruction {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 10px;
    color: #666;
    font-size: 0.95rem;
    margin-top: 20px;
    border-left: 4px solid #0e81b0;
}


/* 针对较小屏幕的示例 */
@media screen and (max-width: 1200px) {
  .consult-btn {
    width: 60px; /* 减小按钮宽度 */
    height: 60px; /* 减小按钮高度 */
    bottom: 20px; /* 调整底部位置 */
    right: 20px; /* 调整右侧位置 */
  }

  .consult-btn i {
    font-size: 1.5rem; /* 减小图标大小 */
  }

  .modal {
    width: 95%; /* 增加模态框宽度 */
    max-width: 90%; /* 调整最大宽度 */
  }

  .modal-header {
    padding: 20px; /* 减小内边距 */
  }

  .modal-header h2 {
    font-size: 1.5rem; /* 减小标题字体大小 */
  }

  .modal-header p {
    font-size: 0.9rem; /* 减小段落字体大小 */
  }

  .close-btn {
    width: 30px; /* 减小关闭按钮宽度 */
    height: 30px; /* 减小关闭按钮高度 */
  }

  .close-btn i {
    font-size: 1rem; /* 减小图标大小 */
  }

  .modal-content {
    padding: 20px; /* 减小内边距 */
  }

  .qrcode-container {
    width: 180px; /* 减小二维码容器宽度 */
    height: 180px; /* 减小二维码容器高度 */
  }

  .qrcode {
    width: 150px; /* 减小二维码宽度 */
    height: 150px; /* 减小二维码高度 */
  }

  .modal-text {
    font-size: 0.95rem; /* 减小文本字体大小 */
  }

  .instruction {
    font-size: 0.9rem; /* 减小说明文本字体大小 */
  }
}

@media screen and (max-width: 480px) {
  .consult-btn {
    width: 50px; /* 进一步减小按钮宽度 */
    height: 50px; /* 进一步减小按钮高度 */
    bottom: 15px; /* 进一步调整底部位置 */
    right: 15px; /* 进一步调整右侧位置 */
  }

  .consult-btn i {
    font-size: 1.2rem; /* 进一步减小图标大小 */
  }

  .modal {
    width: 100%; /* 全屏宽度 */
    max-width: 100%; /* 调整最大宽度 */
    border-radius: 0; /* 移除圆角 */
  }

  .modal-header {
    padding: 15px; /* 进一步减小内边距 */
  }

  .modal-header h2 {
    font-size: 1.3rem; /* 进一步减小标题字体大小 */
  }

  .modal-header p {
    font-size: 0.8rem; /* 进一步减小段落字体大小 */
  }

  .close-btn {
    width: 25px; /* 进一步减小关闭按钮宽度 */
    height: 25px; /* 进一步减小关闭按钮高度 */
  }

  .close-btn i {
    font-size: 0.9rem; /* 进一步减小图标大小 */
  }

  .modal-content {
    padding: 15px; /* 进一步减小内边距 */
  }

  .qrcode-container {
    width: 150px; /* 进一步减小二维码容器宽度 */
    height: 150px; /* 进一步减小二维码容器高度 */
  }

  .qrcode {
    width: 120px; /* 进一步减小二维码宽度 */
    height: 120px; /* 进一步减小二维码高度 */
  }

  .modal-text {
    font-size: 0.9rem; /* 进一步减小文本字体大小 */
  }

  .instruction {
    font-size: 0.85rem; /* 进一步减小说明文本字体大小 */
  }
}