* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, sans-serif;
  background: #3b71f7;
  color: white;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
  overflow: hidden;
  position: relative;
  margin: 0;
}

.water-tracker {
  text-align: center;
  width: 100%;
  max-width: 300px;
  position: relative;
  z-index: 2;
}

/* 设置按钮样式 */
.settings-button {
  position: absolute;
  top: -40px;
  right: 0;
  background: rgba(255, 255, 255, 0.2);
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  backdrop-filter: blur(5px);
  transition: all 0.3s;
  z-index: 10;
}

.settings-button:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: scale(1.1);
}

.settings-button svg {
  color: white;
}

/* 设置面板样式 */
.settings-panel {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  backdrop-filter: blur(5px);
}

.settings-panel.active {
  display: flex;
}

.settings-content {
  background: white;
  border-radius: 20px;
  padding: 30px;
  width: 90%;
  max-width: 400px;
  color: #333;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.settings-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  padding-bottom: 15px;
  border-bottom: 1px solid #eee;
}

.settings-header h3 {
  font-size: 24px;
  font-weight: 600;
  color: #333;
}

.close-button {
  background: none;
  border: none;
  font-size: 28px;
  cursor: pointer;
  color: #999;
  width: 30px;
  height: 30px;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 50%;
  transition: all 0.3s;
}

.close-button:hover {
  background: #f5f5f5;
  color: #333;
}

.setting-item {
  margin-bottom: 25px;
}

.setting-item label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  color: #555;
  font-size: 14px;
}

.setting-item input {
  width: 100%;
  padding: 12px 15px;
  border: 2px solid #e0e0e0;
  border-radius: 10px;
  font-size: 16px;
  transition: all 0.3s;
  background: #f9f9f9;
}

.setting-item input:focus {
  outline: none;
  border-color: #3b71f7;
  background: white;
  box-shadow: 0 0 0 3px rgba(59, 113, 247, 0.1);
}

.setting-actions {
  display: flex;
  gap: 15px;
  margin-top: 30px;
}

.save-button, .reset-button {
  flex: 1;
  padding: 12px 20px;
  border: none;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
}

.save-button {
  background: #3b71f7;
  color: white;
}

.save-button:hover {
  background: #2d5fd8;
  transform: translateY(-2px);
}

.reset-button {
  background: #f5f5f5;
  color: #666;
}

.reset-button:hover {
  background: #e0e0e0;
  color: #333;
}

.current-amount {
  font-size: 100px;
  font-weight: 700;
  line-height: 1;
  color: white;
  position: relative;
  margin-bottom: 30px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.target-container {
  position: relative;
  margin-bottom: 40px;
}

.target-label {
  font-size: 14px;
  opacity: 0.7;
  position: absolute;
  top: -18px;
  left: 50%;
  transform: translateX(-50%);
}

.target-amount {
  font-size: 24px;
  opacity: 0.9;
}

.unit {
  font-size: 24px;
  opacity: 0.7;
  position: relative;
  top: -3px;
  margin-left: 2px;
}

.status {
  font-size: 18px;
  color: white;
  margin-bottom: 30px;
  font-weight: 500;
  opacity: 0.9;
}

.add-button {
  background: rgba(255, 255, 255, 0.2);
  color: white;
  border: none;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  font-size: 30px;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 0 auto;
  backdrop-filter: blur(5px);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  position: relative;
  z-index: 3;
}

.add-button .iconfont {
  display: flex;
}

.iconfont .icon {
  fill: #3a71f7;
  width: 3rem;
  height: 3rem;
}

.iconfont .icon > path{
  fill: #3a71f7 !important;
}

.add-button:hover {
  transform: scale(1.05);
}

.wave-container {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  transform: translateY(100%);
  z-index: 1;
  transition: transform 1.2s ease-in-out;
  pointer-events: none;
  margin: 0;
  padding: 0;
}

.wave-svg {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 200%;
  height: 100%;
  margin: 0;
  padding: 0;
}

.wave-path {
  fill: #d1e6fd;
  opacity: 0.8;
}

.wave-1 {
  animation: waveMove1 12s ease-in-out infinite;
}

.wave-2 {
  animation: waveMove2 8s ease-in-out infinite;
  opacity: 0.6;
}

.wave-3 {
  animation: waveMove3 10s ease-in-out infinite;
  opacity: 0.4;
}

@keyframes waveMove1 {
  0%, 100% {
    transform: translateX(0) translateY(0);
  }
  25% {
    transform: translateX(-25%) translateY(-2px);
  }
  50% {
    transform: translateX(-50%) translateY(0);
  }
  75% {
    transform: translateX(-75%) translateY(2px);
  }
}

@keyframes waveMove2 {
  0%, 100% {
    transform: translateX(0) translateY(0);
  }
  33% {
    transform: translateX(-33%) translateY(1px);
  }
  66% {
    transform: translateX(-66%) translateY(-1px);
  }
}

@keyframes waveMove3 {
  0%, 100% {
    transform: translateX(0) translateY(0);
  }
  50% {
    transform: translateX(-50%) translateY(1px);
  }
}

/* 移动设备特殊处理 */
@media (max-width: 768px) {
  body {
    padding: 10px;
  }
  
  .wave-container {
    width: 100vw;
    height: 100vh;
    bottom: 0;
    left: 0;
  }
  
  .wave-svg {
    width: 200%;
    height: 100%;
  }
}

@media (max-width: 350px) {
  .current-amount {
    font-size: 80px;
  }

  .target-amount {
    font-size: 20px;
  }

  .add-button {
    width: 70px;
    height: 70px;
    font-size: 26px;
  }
  
  .settings-content {
    padding: 20px;
  }
}
