mirror of
https://github.com/Coldsmiles/infstarweb.git
synced 2026-04-23 02:30:41 +08:00
- Introduced fund_progress.txt to track server upgrade funding and vehicle replacement costs. - Created sponsors.txt to log sponsorship contributions with details including name, project, amount, and date. - Developed components.js for reusable UI components including navbar and footer. - Implemented data_utils.js for parsing sponsor data and calculating totals. - Added script.js for managing server status, crowdfunding display, and sponsor data fetching. - Created sponsor_script.js for detailed sponsor data management, filtering, and UI interactions. - Developed stats_script.js for player statistics display, including leaderboards and detailed player stats in a modal.
457 lines
7.9 KiB
CSS
457 lines
7.9 KiB
CSS
/* Specific styles for stats page override/additions */
|
|
.stats-hero {
|
|
height: 40vh;
|
|
min-height: 300px;
|
|
}
|
|
|
|
.stats-hero-bg {
|
|
background-image: url('https://img.lunadeer.cn/i/2025/11/26/69267755e14e3.png');
|
|
}
|
|
|
|
.stats-main-section {
|
|
background: var(--bg-color);
|
|
}
|
|
|
|
.stats-grid {
|
|
display: grid;
|
|
grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
|
|
gap: 20px;
|
|
margin-top: 30px;
|
|
}
|
|
|
|
.player-card {
|
|
background: var(--card-bg);
|
|
border-radius: var(--radius-medium);
|
|
padding: 20px;
|
|
text-align: center;
|
|
transition: var(--transition);
|
|
cursor: pointer;
|
|
box-shadow: 0 4px 6px rgba(0,0,0,0.02);
|
|
position: relative;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.player-card:hover {
|
|
transform: translateY(-5px);
|
|
box-shadow: 0 10px 20px rgba(0,0,0,0.05);
|
|
}
|
|
|
|
.player-card img {
|
|
width: 80px;
|
|
height: 80px;
|
|
border-radius: 10px;
|
|
margin-bottom: 15px;
|
|
box-shadow: 0 2px 10px rgba(0,0,0,0.1);
|
|
}
|
|
|
|
.player-card h3 {
|
|
font-size: 16px;
|
|
margin-bottom: 5px;
|
|
white-space: nowrap;
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
}
|
|
|
|
.player-card .p-uuid {
|
|
font-size: 12px;
|
|
color: var(--text-secondary);
|
|
margin-bottom: 10px;
|
|
font-family: monospace;
|
|
}
|
|
|
|
/* Leaderboard Cards */
|
|
.leaderboard-grid {
|
|
display: grid;
|
|
grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
|
|
gap: 20px;
|
|
margin-bottom: 60px;
|
|
}
|
|
|
|
.lb-card {
|
|
background: white;
|
|
border-radius: var(--radius-medium);
|
|
padding: 25px;
|
|
box-shadow: 0 4px 20px rgba(0,0,0,0.05);
|
|
position: relative;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.lb-card.gold {
|
|
border-top: 4px solid #FFD700;
|
|
}
|
|
|
|
.lb-card.silver {
|
|
border-top: 4px solid #C0C0C0;
|
|
}
|
|
|
|
.lb-card.bronze {
|
|
border-top: 4px solid #CD7F32;
|
|
}
|
|
|
|
.lb-card.red {
|
|
border-top: 4px solid #ff3b30;
|
|
}
|
|
|
|
.lb-card.purple {
|
|
border-top: 4px solid #9b59b6;
|
|
}
|
|
|
|
.lb-card.kill-red {
|
|
border-top: 4px solid #e74c3c;
|
|
}
|
|
|
|
.lb-header {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 10px;
|
|
margin-bottom: 20px;
|
|
}
|
|
|
|
.lb-icon {
|
|
width: 40px;
|
|
height: 40px;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
border-radius: 10px;
|
|
background: var(--bg-color);
|
|
color: var(--text-primary);
|
|
font-size: 20px;
|
|
}
|
|
|
|
.lb-title {
|
|
font-weight: 600;
|
|
font-size: 18px;
|
|
}
|
|
|
|
.lb-top-player {
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
margin-bottom: 20px;
|
|
padding-bottom: 20px;
|
|
border-bottom: 1px solid #f0f0f0;
|
|
}
|
|
|
|
.lb-top-player img {
|
|
width: 64px;
|
|
height: 64px;
|
|
border-radius: 8px;
|
|
margin-bottom: 10px;
|
|
}
|
|
|
|
.lb-top-data {
|
|
font-size: 24px;
|
|
font-weight: 700;
|
|
color: var(--accent-color);
|
|
}
|
|
|
|
.lb-top-name {
|
|
font-weight: 700;
|
|
margin-bottom: 4px;
|
|
}
|
|
|
|
.lb-list {
|
|
list-style: none;
|
|
}
|
|
|
|
.lb-item {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
padding: 8px 0;
|
|
font-size: 14px;
|
|
border-bottom: 1px dashed #eee;
|
|
}
|
|
|
|
.lb-item-main {
|
|
display: flex;
|
|
align-items: center;
|
|
}
|
|
|
|
.lb-item-name {
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
white-space: nowrap;
|
|
max-width: 100px;
|
|
}
|
|
|
|
.lb-item:last-child {
|
|
border-bottom: none;
|
|
}
|
|
|
|
.lb-rank {
|
|
width: 24px;
|
|
height: 24px;
|
|
background: #eee;
|
|
border-radius: 50%;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
font-size: 12px;
|
|
font-weight: 700;
|
|
margin-right: 8px;
|
|
}
|
|
|
|
/* Search Box */
|
|
.search-container {
|
|
max-width: 600px;
|
|
margin: 0 auto 40px;
|
|
position: relative;
|
|
}
|
|
|
|
.search-input {
|
|
width: 100%;
|
|
padding: 15px 20px 15px 45px;
|
|
border: 1px solid rgba(0,0,0,0.1);
|
|
border-radius: 15px;
|
|
font-size: 16px;
|
|
outline: none;
|
|
transition: var(--transition);
|
|
background: white;
|
|
}
|
|
|
|
.search-input:focus {
|
|
border-color: var(--accent-color);
|
|
box-shadow: 0 0 0 3px rgba(0, 113, 227, 0.1);
|
|
}
|
|
|
|
.search-icon {
|
|
position: absolute;
|
|
left: 15px;
|
|
top: 50%;
|
|
transform: translateY(-50%);
|
|
color: #ccc;
|
|
}
|
|
|
|
/* Stats Modal Override */
|
|
.stat-row {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
padding: 10px 0;
|
|
border-bottom: 1px solid #eee;
|
|
}
|
|
|
|
.stat-label {
|
|
color: var(--text-secondary);
|
|
}
|
|
|
|
.stat-value {
|
|
font-weight: 600;
|
|
}
|
|
|
|
.loading-text {
|
|
text-align: center;
|
|
padding: 40px;
|
|
color: var(--text-secondary);
|
|
font-size: 18px;
|
|
}
|
|
|
|
.loading-details-text {
|
|
text-align: center;
|
|
padding: 20px;
|
|
color: #888;
|
|
}
|
|
|
|
.load-more-container {
|
|
text-align: center;
|
|
margin-top: 40px;
|
|
}
|
|
|
|
.load-more-btn {
|
|
background: white;
|
|
border: 1px solid #ddd;
|
|
padding: 12px 30px;
|
|
border-radius: 20px;
|
|
cursor: pointer;
|
|
font-weight: 600;
|
|
transition: var(--transition);
|
|
}
|
|
|
|
.load-more-btn:hover {
|
|
background: #f9f9f9;
|
|
transform: translateY(-2px);
|
|
}
|
|
|
|
/* Modal Redesign */
|
|
.modal-content.expanded-modal {
|
|
max-width: 800px;
|
|
width: 90%;
|
|
display: flex;
|
|
flex-direction: column;
|
|
max-height: 90vh;
|
|
overflow-y: auto;
|
|
}
|
|
|
|
/* Custom Scrollbar for Modal */
|
|
.modal-content.expanded-modal::-webkit-scrollbar {
|
|
width: 6px;
|
|
}
|
|
|
|
.modal-content.expanded-modal::-webkit-scrollbar-track {
|
|
background: transparent;
|
|
margin: 10px 0;
|
|
}
|
|
|
|
.modal-content.expanded-modal::-webkit-scrollbar-thumb {
|
|
background: rgba(0, 0, 0, 0.15);
|
|
border-radius: 10px;
|
|
}
|
|
|
|
.modal-content.expanded-modal::-webkit-scrollbar-thumb:hover {
|
|
background: rgba(0, 0, 0, 0.25);
|
|
}
|
|
|
|
.modal-top-section {
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
gap: 20px;
|
|
margin-bottom: 20px;
|
|
}
|
|
|
|
.modal-identity {
|
|
flex: 1;
|
|
min-width: 200px;
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
justify-content: center;
|
|
text-align: center;
|
|
}
|
|
|
|
.modal-identity img {
|
|
width: 100px;
|
|
height: 100px;
|
|
border-radius: 12px;
|
|
box-shadow: 0 4px 15px rgba(0,0,0,0.1);
|
|
margin-bottom: 15px;
|
|
}
|
|
|
|
#modal-name {
|
|
margin: 5px 0;
|
|
font-size: 24px;
|
|
}
|
|
|
|
#modal-uuid {
|
|
font-size: 12px;
|
|
color: #999;
|
|
font-family: monospace;
|
|
word-break: break-all;
|
|
}
|
|
|
|
.stats-list-container.compact-stats {
|
|
flex: 1;
|
|
min-width: 250px;
|
|
display: flex;
|
|
flex-direction: column;
|
|
justify-content: center;
|
|
background: #f9f9f9;
|
|
padding: 15px;
|
|
border-radius: 12px;
|
|
}
|
|
|
|
.modal-divider {
|
|
border: 0;
|
|
border-top: 1px solid #eee;
|
|
margin: 10px 0 20px;
|
|
}
|
|
|
|
/* Accordion Styles */
|
|
.accordion {
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 10px;
|
|
}
|
|
|
|
.accordion-item {
|
|
border: 1px solid #eee;
|
|
border-radius: 8px;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.accordion-header {
|
|
background: #fdfdfd;
|
|
padding: 12px 15px;
|
|
cursor: pointer;
|
|
font-weight: 600;
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
transition: background 0.2s;
|
|
}
|
|
|
|
.accordion-header:hover {
|
|
background: #f0f0f0;
|
|
}
|
|
|
|
.accordion-header .icon {
|
|
margin-right: 8px;
|
|
width: 20px;
|
|
text-align: center;
|
|
color: var(--text-secondary);
|
|
}
|
|
|
|
.accordion-header .arrow {
|
|
transition: transform 0.3s;
|
|
}
|
|
|
|
.accordion-header.active .arrow {
|
|
transform: rotate(180deg);
|
|
}
|
|
|
|
.accordion-header.active {
|
|
background: #f0f0f0;
|
|
color: var(--accent-color);
|
|
}
|
|
|
|
.accordion-content {
|
|
display: none;
|
|
padding: 15px;
|
|
background: white;
|
|
border-top: 1px solid #eee;
|
|
}
|
|
|
|
.accordion-content.show {
|
|
display: block;
|
|
}
|
|
|
|
/* Grid for stats inside accordion */
|
|
.detail-stats-grid {
|
|
display: grid;
|
|
grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
|
|
gap: 10px;
|
|
}
|
|
|
|
.detail-stat-item {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
font-size: 13px;
|
|
padding: 4px 0;
|
|
border-bottom: 1px dashed #f5f5f5;
|
|
}
|
|
|
|
.detail-stat-label {
|
|
color: #666;
|
|
margin-right: 10px;
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
white-space: nowrap;
|
|
}
|
|
|
|
.detail-stat-value {
|
|
font-weight: 600;
|
|
font-family: monospace;
|
|
}
|
|
|
|
/* Mobile Adjustments */
|
|
@media (max-width: 600px) {
|
|
.modal-top-section {
|
|
flex-direction: column;
|
|
}
|
|
|
|
.modal-identity,
|
|
.stats-list-container.compact-stats {
|
|
width: 100%;
|
|
}
|
|
}
|