PricingChart.css 3.77 KB
Newer Older
1
.pricing-chart {
fisherdaddy's avatar
fisherdaddy committed
2 3 4 5 6 7 8
  padding: 2.5rem;
  background: linear-gradient(145deg, rgba(255,255,255,0.05) 0%, rgba(240,242,245,0.1) 100%);
  border-radius: 16px;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.1);
  box-shadow: 0 8px 32px rgba(0,0,0,0.1);
  margin-bottom: 2rem;
9 10 11
}

.chart-title {
fisherdaddy's avatar
fisherdaddy committed
12 13 14 15 16
  font-size: 1.75rem;
  background: linear-gradient(90deg, #4285f4, #7c4dff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 1rem;
17 18 19
}

.chart-subtitle {
fisherdaddy's avatar
fisherdaddy committed
20 21 22
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
23 24 25 26 27 28 29 30 31 32 33 34
}

.legend {
  display: flex;
  gap: 2rem;
  margin-bottom: 1rem;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
fisherdaddy's avatar
fisherdaddy committed
35 36 37 38 39 40 41 42 43
  background: rgba(255,255,255,0.1);
  padding: 0.5rem 1rem;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.legend-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100
}

.legend-color {
  width: 20px;
  height: 20px;
  border-radius: 4px;
}

.input-color {
  background-color: #4285f4;
}

.output-color {
  background-color: #7c4dff;
}

.chart-area {
  display: flex;
}

.y-axis {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 300px;
  margin-right: 10px;
}

.y-axis-label {
  font-size: 0.75rem;
  text-align: right;
}

.chart-container {
  display: flex;
  align-items: flex-end;
  gap: 0.5rem; /* 减小柱状图之间的间距 */
  height: 300px;
  position: relative;
  padding-bottom: 80px;
  width: 100%; /* 确保容器占满可用宽度 */
  overflow: visible; /* 移除水平滚动 */
}

.grid-lines {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  bottom: 80px;
  z-index: 1;
}

.grid-line {
  position: absolute;
  left: 0;
  right: 0;
fisherdaddy's avatar
fisherdaddy committed
101
  border-top: 1px dashed rgba(224,224,224,0.3);
102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127
}

.chart-column {
  position: relative;
  flex: 1; /* 使柱状图列可伸缩 */
  /* max-width: 60px; */ /* 移除这行 */
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* 让.bar根据可用空间调整宽度 */
.bars-container {
  display: flex;
  gap: 2px;
  align-items: flex-end;
  height: 100%;
  justify-content: center;
  flex-grow: 1; /* 新增 */
}

.bar {
  width: 15px; /* 减小柱状图的宽度 */
  position: relative;
  border-radius: 4px 4px 0 0;
fisherdaddy's avatar
fisherdaddy committed
128 129 130
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: linear-gradient(180deg, rgba(66,133,244,0.9), rgba(66,133,244,0.7));
  box-shadow: 0 4px 12px rgba(66,133,244,0.2);
131 132 133
}

.input-bar {
fisherdaddy's avatar
fisherdaddy committed
134
  background: linear-gradient(180deg, #4285f4, #2b579a);
135 136 137
}

.output-bar {
fisherdaddy's avatar
fisherdaddy committed
138
  background: linear-gradient(180deg, #7c4dff, #4a2b9a);
139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164
  margin-left: 5px;
}

.price-label {
  position: absolute;
  top: -20px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.65rem; /* 减小价格标签的字体大小 */
  white-space: nowrap;
}

.provider-info {
  position: absolute;
  bottom: -70px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.provider-logo {
  width: 20px; /* 缩小Logo尺寸 */
  height: 20px;
  object-fit: contain;
fisherdaddy's avatar
fisherdaddy committed
165 166 167 168 169 170
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
  transition: transform 0.3s ease;
}

.provider-logo:hover {
  transform: scale(1.1);
171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189
}

.provider-name {
  font-size: 13px;
  transform: translate(-18px, 36px) rotate(-77deg);
  transform-origin: top center;
  /* white-space: nowrap; */
  /* margin-top: 35px; */
  line-height: 16px;
  padding-top: -11px;
  width: 80px;
  text-align: right;
  height: 40px;
  word-break: break-all;
  white-space: break-spaces;
  padding-right: 18px;
}

.pricing-charts-container {
fisherdaddy's avatar
fisherdaddy committed
190 191 192
  padding: 2rem;
  background: var(--bg-primary);
  min-height: 100vh;
193 194 195
}

.update-time {
fisherdaddy's avatar
fisherdaddy committed
196 197 198 199 200
  background: rgba(255,255,255,0.05);
  padding: 0.5rem 1rem;
  border-radius: 8px;
  margin-bottom: 2rem;
  display: inline-block;
201
}