:root {
  /* 统一维护，后面改高度只动这里 */
  --bottom-bar-height: 15vh;
}
/* 1. 全局重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
    font-size: 15px;
}

html,
body {
    height: 100%;
    background: #f5f5f5;
    color: #333;
    line-height: 1.5;
    /*max-width: 100vw;*/
    /*padding-bottom: var(--bottom-bar-height);*/
}
.container{
    height: 85vh;
    overflow: auto;
    padding-bottom: var(--bottom-bar-height);
}

header,
footer {
    flex-shrink: 0;
    background: #fff;
    text-align: center;
    padding: 0;
    font-size: 16px;
    width: 100%;
    box-sizing: border-box;
}
.header img{
    width: 100%;
    height: auto;
    display: block;
    max-width: 100%;
}
/* 定义淡入动画 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.card-left{
    display: flex;
    justify-content: flex-start;
    width: 100%;
    padding-top: 15px;
    align-items: start;
    /* animation: fadeIn 0.5s ease-out; 添加淡入动画，0.5秒完成，使用缓出效果 */
}
.card-right{
    display: flex;
    justify-content: flex-start;
    width: 100%;
    padding-top: 15px;
    align-items: flex-start;
    flex-direction: row-reverse;
    /* animation: fadeIn 0.5s ease-out; 添加淡入动画，0.5秒完成，使用缓出效果 */
}
.card-avatar{  
    width: 17%;    
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    padding: 0px 10px;
}

.card-txt{
    max-width: 65%;
    padding-left: 10px;
    background: #fff;
    border-radius: 8px;
    padding: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .2);
    line-height: 1.9;
    font-weight: 500; /* 将字体粗细从 bold 改为 normal，解决太粗的问题 */
}

.card-avatar img{  
    border-radius: 5px;
    width: 100%;
    object-fit: contain;
}

.bottom-spacer {
  /* 只是一个空盒子，负责把 body 的“底边”往上推 */
  padding-bottom: var(--bottom-bar-height);
}
.btn-wrapper {
  /* 1. 不再 fixed，而是 sticky */
  position: sticky;
  bottom: 0;            /* 关键：粘到底部 */
  z-index: 99;          /* 仍保持在上层 */

  /* 2. 其余布局不变 */
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  height: 15vh;
  background: #fff;
  /*box-shadow: 0 -1px 3px rgba(0,0,0,.12);*/
  /*margin-top: 15vh;*/
}
.btn-wrapper .btn-item{
    min-width: 70px;
    border-radius: 5px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 15px;
    overflow: hidden;
    /*scrollbar-width: none;*/
}
.btn-wrapper .btn-item span{
    padding: 8px;
    border: 0;
    border-radius: 8px;
    text-align: center;
    font-weight: 500;
}
.low-end{
    background-color: rgb(222, 158, 76);
    color: rgb(255, 255, 255);
    width: 80%;
}
.high-end{
    background-color: rgb(34, 212, 111);
    color: rgb(255, 255, 255);
    width: 80%;
}
.btn-whats{
    width: 100%;
    height: 50px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 20px;
    font-weight: 600;
}
.btn-wrapper .btn-whats span{
    padding: 8px;
    border: 0;
    border-radius: 20px;
    text-align: center;
    font-weight: 700;
    font-size: 18px;
}
/* 定义循环放大缩小的动画 */
@keyframes scaleAnimation {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

.WhatsApp{
    width: 70%;
    background-color: rgb(34, 212, 111);
    color: rgb(255, 255, 255);
    font-weight: 700;
    animation: scaleAnimation 1.3s infinite ease-in-out; /* 添加动画效果，2秒完成一次循环，无限循环，使用平滑的缓动函数 */
}

.fade-in-up {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp .3s ease forwards;
}

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