.avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #81c784, #2e7d32);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    border: 2px solid #fff;
    box-shadow: 0 3px 8px rgba(0,0,0,0.2);
    cursor: pointer;
}
.equip-badge, .equip-title {
    font-size: 0.75rem;
    font-weight: bold;
    white-space: nowrap;
    cursor: pointer;
    background: none;
    border: none;
    padding: 2px 4px;
}
.player-name {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1b5e20;
    cursor: pointer;
}
.clear-btn-top {
    position: absolute;
    top: 0;
    right: 0;
    background: none;
    border: none;
    font-size: 0.9rem;
    cursor: pointer;
    color: #999;
    padding: 4px 8px;
    border-radius: 20px;
}
.clear-btn-top:hover { color: #e57373; }
.home-title {
    text-align: center;
    font-size: 2rem;
    font-weight: 900;
    background: linear-gradient(180deg, #2e7d32, #1b5e20);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 10px;
}
.big-btn {
    background: linear-gradient(180deg, #66bb6a, #43a047);
    border: none;
    padding: 10px 20px;
    border-radius: 40px;
    font-weight: 700;
    font-size: 0.95rem;
    color: white;
    cursor: pointer;
    margin: 4px;
    box-shadow: 0 6px 12px rgba(0,60,0,0.2);
    transition: 0.15s;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.big-btn:active { transform: scale(0.96); }
.big-btn.small { padding: 6px 14px; font-size: 0.8rem; }
.big-btn.danger { background: linear-gradient(180deg, #ef9a9a, #e57373); }
.big-btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; }
.tool-btn {
    background: #fff;
    border: 2px solid #81c784;
    color: #2e7d32;
    padding: 8px 14px;
    border-radius: 25px;
    display: flex;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    font-weight: 700;
    box-shadow: 0 3px 6px rgba(0,0,0,0.1);
}
.tool-btn:disabled { opacity: 0.4; cursor: not-allowed; }
.pause-btn-corner {
    background: #fff;
    border: 2px solid #43a047;
    font-size: 1.4rem;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.45);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 200;
}
.modal-content {
    background: #f1f8e9;
    padding: 22px;
    border-radius: 30px;
    max-width: 700px;
    width: 90%;
    max-height: 82vh;
    overflow-y: auto;
    border: 2px solid #81c784;
    box-shadow: 0 25px 50px rgba(0,0,0,0.4);
    position: relative;
}
.modal-close-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    background: none;
    border: none;
    font-size: 1.8rem;
    cursor: pointer;
    color: #888;
    line-height: 1;
    z-index: 5;
}
.modal-close-btn:hover { color: #e57373; }
.tab-bar {
    display: flex;
    gap: 4px;
    margin-bottom: 12px;
}
.tab-btn {
    flex: 1;
    padding: 8px;
    border-radius: 20px;
    border: 2px solid #81c784;
    background: #fff;
    color: #2e7d32;
    font-weight: 700;
    cursor: pointer;
    text-align: center;
}
.tab-btn.active {
    background: #4caf50;
    color: #fff;
    border-color: #2e7d32;
}
.sort-bar {
    display: flex;
    gap: 8px;
    margin: 12px 0;
    justify-content: center;
    flex-wrap: wrap;
}
.sort-btn {
    background: #e8f5e9;
    border: 2px solid #81c784;
}
.sort-btn.active {
    background: #4caf50;
    color: white;
}
.progress-bar {
    height: 8px;
    background: #cfd8dc;
    border-radius: 10px;
    margin: 4px 0;
    overflow: hidden;
}
.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #66bb6a, #2e7d32);
    border-radius: 10px;
}
.avatar-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin: 10px 0;
}
.avatar-option {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.7rem;
    cursor: pointer;
    border: 3px solid transparent;
    background: #e8f5e9;
    transition: 0.15s;
}
.avatar-option.selected {
    border-color: #2e7d32;
    background: #c8e6c9;
    transform: scale(1.1);
}
.list-item {
    display: flex;
    flex-direction: column;
    padding: 8px 12px;
    background: #fff;
    border-radius: 12px;
    margin: 6px 0;
}
.list-item .row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.list-item .cond {
    font-size: 0.7rem;
    color: #666;
    margin-top: 2px;
}
.list-item .time {
    font-size: 0.7rem;
    color: #999;
}
.title-text, .badge-text {
    background: none;
    border: none;
    font-weight: bold;
    padding: 2px 4px;
    white-space: nowrap;
    display: inline-block;
}
.reward-toast {
    position: fixed;
    top: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: #2e7d32;
    color: #fff;
    padding: 15px 30px;
    border-radius: 30px;
    font-size: 1.2rem;
    font-weight: bold;
    z-index: 300;
    box-shadow: 0 10px 20px rgba(0,0,0,0.3);
    opacity: 1;
    transition: opacity 0.5s;
    pointer-events: none;
}
.reward-toast.fade-out { opacity: 0; }
.star-container {
    display: flex;
    gap: 4px;
    justify-content: center;
    margin: 8px 0;
}
.star {
    font-size: 1.8rem;
    color: #ffd700;
}
.star.empty { color: #ccc; }
.difficulty-select {
    background: #f1f8e9;
    border: 2px solid #81c784;
    border-radius: 24px;
    padding: 4px 12px;
    font-size: 0.8rem;
    font-weight: bold;
    color: #2e7d32;
    cursor: pointer;
    outline: none;
    transition: 0.2s;
}
.sound-toggle {
    background: #fff;
    border: 2px solid #81c784;
    border-radius: 30px;
    padding: 4px 12px;
    font-size: 0.8rem;
    font-weight: bold;
    cursor: pointer;
    margin-left: 8px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}
.rank-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8rem;
}
.rank-table th, .rank-table td {
    padding: 8px 4px;
    text-align: center;
    border-bottom: 1px solid #c8e6c9;
}
.rank-table th {
    background: #c8e6c9;
    color: #1b5e20;
}
.rank-avatar {
    font-size: 1.3rem;
    margin-right: 5px;
    vertical-align: middle;
}
.level-btn {
    width: 55px;
    height: 55px;
    border-radius: 14px;
    border: 2px solid #81c784;
    background: #fff;
    color: #2e7d32;
    font-weight: bold;
    font-size: 0.9rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.15s;
    position: relative;
}
.level-btn.locked {
    background: #e0e0e0;
    color: #aaa;
    border-color: #ccc;
    cursor: not-allowed;
}
.level-btn.completed { background: #c8e6c9; }
.level-btn .lock-icon { position: absolute; font-size: 1.2rem; }