| 1 |
@import url('https://fonts.googleapis.com/css2?family=VT323&display=swap'); |
| 2 |
|
| 3 |
* { |
| 4 |
margin: 0; |
| 5 |
padding: 0; |
| 6 |
box-sizing: border-box; |
| 7 |
} |
| 8 |
|
| 9 |
body { |
| 10 |
font-family: 'VT323', monospace; |
| 11 |
background: #000; |
| 12 |
color: #0f0; |
| 13 |
min-height: 100vh; |
| 14 |
display: flex; |
| 15 |
flex-direction: column; |
| 16 |
text-shadow: 0 0 5px #0f0; |
| 17 |
overflow-x: hidden; |
| 18 |
} |
| 19 |
|
| 20 |
body::before { |
| 21 |
content: ''; |
| 22 |
position: fixed; |
| 23 |
top: 0; |
| 24 |
left: 0; |
| 25 |
width: 100%; |
| 26 |
height: 100%; |
| 27 |
background: repeating-linear-gradient( |
| 28 |
0deg, |
| 29 |
rgba(0, 0, 0, 0.15), |
| 30 |
rgba(0, 0, 0, 0.15) 1px, |
| 31 |
transparent 1px, |
| 32 |
transparent 2px |
| 33 |
); |
| 34 |
pointer-events: none; |
| 35 |
z-index: 1; |
| 36 |
} |
| 37 |
|
| 38 |
.container { |
| 39 |
position: relative; |
| 40 |
z-index: 2; |
| 41 |
} |
| 42 |
|
| 43 |
header { |
| 44 |
padding: 2rem; |
| 45 |
text-align: center; |
| 46 |
border-bottom: 2px solid #0f0; |
| 47 |
} |
| 48 |
|
| 49 |
.ascii-title { |
| 50 |
font-size: 1.5rem; |
| 51 |
line-height: 1.2; |
| 52 |
white-space: pre; |
| 53 |
color: #0f0; |
| 54 |
margin-bottom: 1rem; |
| 55 |
overflow-x: auto; |
| 56 |
} |
| 57 |
|
| 58 |
@media (max-width: 768px) { |
| 59 |
.ascii-title { |
| 60 |
font-size: 0.7rem; |
| 61 |
} |
| 62 |
} |
| 63 |
|
| 64 |
.subtitle { |
| 65 |
font-size: 1.5rem; |
| 66 |
color: #0a0; |
| 67 |
animation: blink 1s infinite; |
| 68 |
} |
| 69 |
|
| 70 |
@keyframes blink { |
| 71 |
0%, |
| 72 |
50% { |
| 73 |
opacity: 1; |
| 74 |
} |
| 75 |
51%, |
| 76 |
100% { |
| 77 |
opacity: 0.3; |
| 78 |
} |
| 79 |
} |
| 80 |
|
| 81 |
.controls { |
| 82 |
display: flex; |
| 83 |
justify-content: center; |
| 84 |
gap: 1rem; |
| 85 |
padding: 2rem; |
| 86 |
flex-wrap: wrap; |
| 87 |
font-size: 1.2rem; |
| 88 |
} |
| 89 |
|
| 90 |
@media (max-width: 768px) { |
| 91 |
.controls { |
| 92 |
padding: 1rem; |
| 93 |
gap: 0.5rem; |
| 94 |
} |
| 95 |
} |
| 96 |
|
| 97 |
button { |
| 98 |
background: #000; |
| 99 |
color: #0f0; |
| 100 |
border: 2px solid #0f0; |
| 101 |
padding: 0.5rem 1rem; |
| 102 |
font-family: 'VT323', monospace; |
| 103 |
font-size: 1.2rem; |
| 104 |
cursor: pointer; |
| 105 |
transition: all 0.1s ease; |
| 106 |
text-transform: uppercase; |
| 107 |
position: relative; |
| 108 |
text-shadow: 0 0 5px #0f0; |
| 109 |
} |
| 110 |
|
| 111 |
@media (max-width: 768px) { |
| 112 |
button { |
| 113 |
padding: 0.4rem 0.6rem; |
| 114 |
font-size: 1rem; |
| 115 |
border-width: 1px; |
| 116 |
} |
| 117 |
} |
| 118 |
|
| 119 |
button::before { |
| 120 |
content: '[ '; |
| 121 |
} |
| 122 |
|
| 123 |
button::after { |
| 124 |
content: ' ]'; |
| 125 |
} |
| 126 |
|
| 127 |
button:hover { |
| 128 |
background: #0f0; |
| 129 |
color: #000; |
| 130 |
text-shadow: none; |
| 131 |
box-shadow: 0 0 10px #0f0; |
| 132 |
} |
| 133 |
|
| 134 |
button:active { |
| 135 |
transform: translate(2px, 2px); |
| 136 |
} |
| 137 |
|
| 138 |
button:disabled { |
| 139 |
color: #030; |
| 140 |
border-color: #030; |
| 141 |
cursor: not-allowed; |
| 142 |
text-shadow: none; |
| 143 |
} |
| 144 |
|
| 145 |
button:disabled:hover { |
| 146 |
background: #000; |
| 147 |
color: #030; |
| 148 |
} |
| 149 |
|
| 150 |
.algorithm-btn.active { |
| 151 |
background: #0f0; |
| 152 |
color: #000; |
| 153 |
text-shadow: none; |
| 154 |
animation: pulse 0.5s infinite alternate; |
| 155 |
} |
| 156 |
|
| 157 |
@keyframes pulse { |
| 158 |
from { |
| 159 |
box-shadow: 0 0 5px #0f0; |
| 160 |
} |
| 161 |
to { |
| 162 |
box-shadow: 0 0 20px #0f0; |
| 163 |
} |
| 164 |
} |
| 165 |
|
| 166 |
.visualization-container { |
| 167 |
flex: 1; |
| 168 |
padding: 2rem; |
| 169 |
font-family: monospace; |
| 170 |
font-size: 14px; |
| 171 |
line-height: 1.2; |
| 172 |
white-space: pre; |
| 173 |
display: flex; |
| 174 |
flex-direction: column; |
| 175 |
align-items: center; |
| 176 |
justify-content: center; |
| 177 |
overflow-x: auto; |
| 178 |
} |
| 179 |
|
| 180 |
@media (max-width: 768px) { |
| 181 |
.visualization-container { |
| 182 |
padding: 1rem; |
| 183 |
font-size: 10px; |
| 184 |
} |
| 185 |
} |
| 186 |
|
| 187 |
.ascii-display { |
| 188 |
text-align: left; |
| 189 |
padding: 1rem; |
| 190 |
border: 2px solid #0f0; |
| 191 |
background: #000; |
| 192 |
box-shadow: 0 0 20px rgba(0, 255, 0, 0.3); |
| 193 |
overflow-x: auto; |
| 194 |
max-width: 100%; |
| 195 |
} |
| 196 |
|
| 197 |
@media (max-width: 768px) { |
| 198 |
.ascii-display { |
| 199 |
padding: 0.5rem; |
| 200 |
border-width: 1px; |
| 201 |
font-size: 0.8rem; |
| 202 |
} |
| 203 |
} |
| 204 |
|
| 205 |
.bar-row { |
| 206 |
color: #0f0; |
| 207 |
transition: all 0.3s ease; |
| 208 |
} |
| 209 |
|
| 210 |
.bar-row.comparing { |
| 211 |
color: #ff0; |
| 212 |
text-shadow: 0 0 10px #ff0; |
| 213 |
} |
| 214 |
|
| 215 |
.bar-row.sorted { |
| 216 |
color: #0ff; |
| 217 |
text-shadow: 0 0 10px #0ff; |
| 218 |
} |
| 219 |
|
| 220 |
.stats { |
| 221 |
display: flex; |
| 222 |
justify-content: center; |
| 223 |
gap: 3rem; |
| 224 |
padding: 2rem; |
| 225 |
border-top: 2px solid #0f0; |
| 226 |
font-size: 1.2rem; |
| 227 |
} |
| 228 |
|
| 229 |
@media (max-width: 768px) { |
| 230 |
.stats { |
| 231 |
gap: 1rem; |
| 232 |
padding: 1rem; |
| 233 |
font-size: 1rem; |
| 234 |
border-width: 1px; |
| 235 |
} |
| 236 |
} |
| 237 |
|
| 238 |
.stat { |
| 239 |
text-align: center; |
| 240 |
} |
| 241 |
|
| 242 |
.stat-label { |
| 243 |
color: #0a0; |
| 244 |
} |
| 245 |
|
| 246 |
@media (max-width: 768px) { |
| 247 |
.stat-label { |
| 248 |
font-size: 0.9rem; |
| 249 |
} |
| 250 |
} |
| 251 |
|
| 252 |
.stat-value { |
| 253 |
font-size: 2rem; |
| 254 |
color: #0f0; |
| 255 |
text-shadow: 0 0 10px #0f0; |
| 256 |
} |
| 257 |
|
| 258 |
@media (max-width: 768px) { |
| 259 |
.stat-value { |
| 260 |
font-size: 1.5rem; |
| 261 |
} |
| 262 |
} |
| 263 |
|
| 264 |
.speed-control { |
| 265 |
display: flex; |
| 266 |
align-items: center; |
| 267 |
gap: 1rem; |
| 268 |
} |
| 269 |
|
| 270 |
input[type='range'] { |
| 271 |
width: 150px; |
| 272 |
height: 8px; |
| 273 |
background: #030; |
| 274 |
border: 1px solid #0f0; |
| 275 |
outline: none; |
| 276 |
cursor: pointer; |
| 277 |
} |
| 278 |
|
| 279 |
input[type='range']::-webkit-slider-thumb { |
| 280 |
-webkit-appearance: none; |
| 281 |
width: 16px; |
| 282 |
height: 16px; |
| 283 |
background: #0f0; |
| 284 |
border: 2px solid #000; |
| 285 |
cursor: pointer; |
| 286 |
box-shadow: 0 0 10px #0f0; |
| 287 |
} |
| 288 |
|
| 289 |
.glitch { |
| 290 |
animation: glitch 2s infinite; |
| 291 |
} |
| 292 |
|
| 293 |
@keyframes glitch { |
| 294 |
0%, |
| 295 |
90%, |
| 296 |
100% { |
| 297 |
transform: translate(0); |
| 298 |
} |
| 299 |
91% { |
| 300 |
transform: translate(-2px, 2px); |
| 301 |
} |
| 302 |
92% { |
| 303 |
transform: translate(2px, -1px); |
| 304 |
} |
| 305 |
93% { |
| 306 |
transform: translate(-1px, 1px); |
| 307 |
} |
| 308 |
} |
| 309 |
|
| 310 |
.ascii-title { |
| 311 |
font-size: 1.5rem; |
| 312 |
line-height: 1.2; |
| 313 |
white-space: pre; |
| 314 |
color: #0f0; |
| 315 |
margin-bottom: 1rem; |
| 316 |
overflow-x: auto; |
| 317 |
text-align: center; |
| 318 |
display: inline-block; |
| 319 |
margin-left: auto; |
| 320 |
margin-right: auto; |
| 321 |
} |
| 322 |
|
| 323 |
header { |
| 324 |
padding: 2rem; |
| 325 |
text-align: center; |
| 326 |
border-bottom: 2px solid #0f0; |
| 327 |
display: flex; |
| 328 |
flex-direction: column; |
| 329 |
align-items: center; |
| 330 |
} |