<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title></title>
</head>
<style>
    * {
        padding: 0;
        margin: 0;
    }

    .flex-2 {
        flex: 2;
    }

    .flex-3 {
        flex: 3;
    }

    .flex-4 {
        flex: 4;
    }

    .flex-8 {
        flex: 8;
    }

    .flex-10 {
        flex: 10;
    }

    .main-content {
        width: 1000px;
        font-size: 30px;
        font-family: "Microsoft YaHei";
        font-weight: bold;
    }

    .page-box {
        width: 1000px;
        display: flex;
        flex-direction: column;
    }

    .page-header {
        display: flex;
        flex-direction: column;
    }

    .clan-user-server {
        height: 120px;
        text-align: center;
        font-size: 45px;
        line-height: 120px;
    }

    .clan {
        display: inline-block;
        padding-right: 10px;
        height: 120px;
    }

    .user {
        display: inline-block;
        height: 120px;
    }

    .server {
        display: inline-block;
        padding-left: 10px;
    }

    .server-border {
        width: 200px;
        height: 50px;
        line-height: 50px;
        text-align: center;
        background-color: #F2F2F2;
        border-radius: 25px;
        font-size: 35px;
    }

    .ship-bar {
        height: 80px;
        font-size: 40px;
        line-height: 80px;
        text-align: center;
        display: flex;
    }

    .ship-level {
        flex: 1;
        text-align: right;
        margin-right: 30px;
    }

    .ship-icon {
        flex: 1;
        text-align: left;
        margin-left: 30px;
    }

    .ship-icon img {
        width: 80px;
        height: 80px;
    }

    .pr {
        display: flex;
        height: 100px;
        font-weight: bold;
        line-height: 60px;
        padding: 0 50px;
    }

    .pr-bar-bg {
        position: relative;
        flex: 1;
        line-height: 80px;
        background-color: #A6A6A6;
        height: 80px;
        border-radius: 40px;
        margin-top: 10px;
        text-align: center;
        color: #FFFFFF;
    }

    .pr-bar {
        position: absolute;
        top: 0;
        left: 0;
        height: 80px;
        z-index: 1;
        border-radius: 40px;
    }

    .pr-number {
        z-index: 99;
        position: absolute;
        left: 0px;
        right: 0px;
        font-size: 35px;
        font-weight: bold;
    }

    .recnet-time {
        text-align: center;
        font-weight: normal;
    }

    .overview-change {
        display: flex;
        margin-top: 30px;
        padding: 0 30px;
        height: 300px;
    }

    .overview-change-item {
        flex: 1;
        display: flex;
        flex-direction: column;
        margin: 0 20px;

    }

    .item-top {
        flex: 5;
        background-color: #F2F2F2;
        border-radius: 16px;
    }

    .item-bottom {
        display: flex;
        flex: 4;
        margin-top: 20px;
    }

    .left-item-bottom {
        background-color: #F2F2F2;
        border-radius: 16px;
    }

    .bottom-mini-item-left {
        flex: 1;
        margin-right: 10px;
        background-color: #F2F2F2;
        border-radius: 16px;
    }

    .bottom-mini-item-right {
        flex: 1;
        margin-left: 10px;
        background-color: #F2F2F2;
        border-radius: 16px;
    }

    .item-top {
        display: flex;
        flex-direction: column;
    }

    .item-top div {
        height: 80px;
        text-align: center;
        font-size: 40px;
    }

    .item-top-top {
        color: #606266;
        font-weight: normal;
        line-height: 100px;
    }

    .item-top-bottom {
        line-height: 60px;
    }

    .left-item-bottom {
        display: flex;
        flex-direction: column;
    }

    .change-pr-title {
        color: #606266;
        height: 60px;
        display: flex;
        font-weight: normal;
        line-height: 70px;
    }

    .change-pr {
        height: 60px;
        line-height: 50px;
        text-align: center;
        font-size: 30px;
    }

    .change-pr-title-left {
        flex: 1;
        font-size: 35px;
        text-align: right;
        margin-right: 30px;
    }

    .change-pr-title-right {
        flex: 1;
        font-size: 20px;
    }

    .bottom-mini-item-left,
    .bottom-mini-item-right {
        display: flex;
        flex-direction: column;
    }

    .mini-item-top {
        color: #606266;
        font-weight: normal;
        line-height: 70px;
    }

    .mini-item-bottom {
        line-height: 45px;
        font-size: 27px;
    }

    .bottom-mini-item-left div,
    .bottom-mini-item-right div {
        height: 60px;
        text-align: center;
    }

    .information-header,
    .day-header {
        margin: 0 200px;
        margin-top: 30px;
        height: 60px;
        line-height: 60px;
        border-radius: 16px;
        background-color: #D9D9D9;
        text-align: center;
    }

    .information-body {
        margin: 0 50px;
        margin-top: 30px;
        display: flex;
        flex-direction: column;
        background-color: #F2F2F2;
        border-radius: 16px;
    }

    .information-col {
        height: 60px;
        display: flex;
        line-height: 60px;
    }

    .information-col-item,
    .day-col-item {
        flex: 1;
        text-align: center;
    }

    .information-table-header {
        color: #606266;
    }

    .information-type {
        color: #909399;
    }

    .day-body {
        margin: 0 50px;
        margin-top: 30px;
    }

    .day-table-header {
        height: 60px;
        line-height: 60px;
        background-color: #D9D9D9;
        display: flex;
        border-radius: 16px;
        color: #606266;
    }

    .date {
        background-color: #D9D9D9;
        width: 300px;
        height: 40px;
        line-height: 40px;
        text-align: center;
        border-radius: 20px;
        margin-top: 10px;
    }

    .day-col {
        display: flex;
        height: 60px;
        line-height: 60px;
        background-color: #F2F2F2;
        border-radius: 30px;
        margin: 10px 0;
    }

    .footer {
        margin-top: 30px;
        text-align: center;
        font-weight: bold;
        font-size: 24px;
        color: #909399;
        margin-bottom: 20px;
    }
</style>
<body>
<div class="main-content">
    <div class="page-box">
        <div class="page-header">
            <div class="clan-user-server">
                {% if data['userInfo']['clanInfo']['tag'] %}
                    <div class="clan" style="color: {{ data['userInfo']['clanInfo']['color'] }};">[{{ data['userInfo']['clanInfo']['tag'] }}]</div>
                {% endif %}
                <div class="user">{{ data['userInfo']['userName'] }}</div>
                <div class="server">
                    <div class="server-border">
                        {{ data['userInfo']['serverCn'] }}
                    </div>
                </div>
            </div>
        </div>

        <div class="ship-bar">
            <div class="ship-level">{{ data['recentInfo'][0]['shipInfoBattleList'][0]['shipInfo']['level'] }}</div>
            <div class="ship-name">{{ data['recentInfo'][0]['shipInfoBattleList'][0]['shipInfo']['nameCn'] }}</div>

            <div class="ship-icon"><img
                    src={% if data['recentInfo'][0]['shipInfoBattleList'][0]['shipInfo']['shipType'] == 'Destroyer' %} "https://hikari-resource.oss-cn-shanghai.aliyuncs.com/shipType_Icon/icon_sunk_destroyer.png"
                    {% elif data['recentInfo'][0]['shipInfoBattleList'][0]['shipInfo']['shipType'] == 'Cruiser' %} "https://hikari-resource.oss-cn-shanghai.aliyuncs.com/shipType_Icon/icon_sunk_cruiser.png"
                    {% elif data['recentInfo'][0]['shipInfoBattleList'][0]['shipInfo']['shipType'] == 'Battleship' %} "https://hikari-resource.oss-cn-shanghai.aliyuncs.com/shipType_Icon/icon_sunk_battleship.png"
                    {% elif data['recentInfo'][0]['shipInfoBattleList'][0]['shipInfo']['shipType'] == 'AirCarrier' %} "https://hikari-resource.oss-cn-shanghai.aliyuncs.com/shipType_Icon/icon_sunk_aircarrier.png"
                    {% else %} "https://hikari-resource.oss-cn-shanghai.aliyuncs.com/shipType_Icon/icon_sunk_submarine.png"
                    {% endif %} />
            </div>
        </div>

        <div class="pr">
            <!-- 动态设置长度及颜色，填写PR即可 -->
            <div class="pr-bar-bg">
                {% if data['battleTypeInfoList']['PVP']['prInfo']['color'] != '#828282' %}
                    <span class="pr-number">{{ data['battleTypeInfoList']['PVP']['prInfo']['value'] }}&nbsp;&nbsp;&nbsp;&nbsp;<span class="pr-text"></span></span>
                {% else %}
                    <span class="pr-number">{{ data['battleTypeInfoList']['RANK_SOLO']['prInfo']['value'] }}&nbsp;&nbsp;&nbsp;&nbsp;<span class="pr-text"></span></span>
                {% endif %}
                <div class="pr-bar"></div>
            </div>
        </div>

        <div class="recnet-time">
            <span>记录时间：</span><span>{{ time.strftime('%Y-%m-%d %H:%M',time.localtime(int(abs(data['recentInfo'][0]['recordTime']/1000)))) }}—{{ time.strftime('%Y-%m-%d %H:%M',time.localtime(time.time())) }}</span>
        </div>

        {% if data['battleTypeInfoList']['PVP']['battle'] %}
            <div class="overview-change">
                <div class="overview-change-item left-item">
                    <div class="left-item-top item-top">
                        <div class="overview-count-title item-top-top">场次</div>
                        <div class="overview-count item-top-bottom">{{ data['battleTypeInfoList']['PVP']['battleInfo']['battleInfo']['battle'] }}</div>
                    </div>
                    <div class="left-item-bottom item-bottom">
                        <div class="change-avgdmg-box bottom-mini-item-left">
                            {% if data['battleTypeInfoList']['PVP']['battleInfo']['avgInfo']['basicXp'] %}
                                <div class="mini-item-top">基础经验</div>
                                <div class="mini-item-bottom change-avgdmg">{{ data['battleTypeInfoList']['PVP']['battleInfo']['avgInfo']['basicXp'] }}</div>
                            {% else %}
                                <div class="mini-item-top">加成经验</div>
                                <div class="mini-item-bottom change-win">{{ data['battleTypeInfoList']['PVP']['battleInfo']['avgInfo']['xp'] }}</div>
                            {% endif %}
                        </div>

                    </div>
                </div>
                <div class="overview-change-item mid-item">
                    <div class="mid-item-top item-top">
                        <div class="overview-win-title item-top-top">胜率</div>
                        <div class="overview-win item-top-bottom" style="color: {{ data['battleTypeInfoList']['PVP']['battleInfo']['avgInfo']['winsData']['color'] }};">{{ data['battleTypeInfoList']['PVP']['battleInfo']['avgInfo']['win'] }}%</div>
                    </div>
                    <div class="mid-item-bottom item-bottom">
                        <div class="change-avgdmg-box bottom-mini-item-left">
                            <div class="mini-item-top">侦察</div>
                            <div class="mini-item-bottom change-avgdmg">{{ '%.2f' | format(data['battleTypeInfoList']['PVP']['battleInfo']['avgInfo']['shipsSpotted']) }}</div>
                        </div>
                        <div class="change-win-box bottom-mini-item-right">
                            <div class="mini-item-top">击落</div>
                            <div class="mini-item-bottom change-win">{{ '%.2f' | format(data['battleTypeInfoList']['PVP']['battleInfo']['avgInfo']['planesKilled']) }}</div>
                        </div>
                    </div>
                </div>
                <div class="overview-change-item right-item">
                    <div class="right-item-top item-top">
                        <div class="overview-avgdmg-title item-top-top">场均</div>
                        <div class="overview-avgdmg item-top-bottom" style="color: {{ data['battleTypeInfoList']['PVP']['battleInfo']['avgInfo']['damageData']['color'] }};">{{ data['battleTypeInfoList']['PVP']['battleInfo']['avgInfo']['damage'] }}</div>
                    </div>
                    <div class="right-item-bottom item-bottom">
                        <div class="overview-kd-box bottom-mini-item-left">
                            <div class="mini-item-top">击杀</div>
                            <div class="mini-item-bottom">{{ '%.2f' | format(data['battleTypeInfoList']['PVP']['battleInfo']['avgInfo']['frags']) }}</div>
                        </div>
                        <div class="overview-hit-box bottom-mini-item-right">
                            <div class="mini-item-top">KD</div>
                            <div class="mini-item-bottom">{{ '%.2f' | format(data['battleTypeInfoList']['PVP']['battleInfo']['avgInfo']['kd']) }}</div>
                        </div>
                    </div>
                </div>
            </div>
        {% endif %}

        <div class="information-header">总体战绩</div>

        <div class="information-body">
            <div class="information-col information-table-header">
                <div class="information-col-item">类型</div>
                <div class="information-col-item">场次</div>
                <div class="information-col-item">胜率</div>
                <div class="information-col-item">PR</div>
                <div class="information-col-item">场均</div>
                <div class="information-col-item">击杀</div>
                <div class="information-col-item">命中</div>
            </div>

            {% if data['battleTypeInfoList']['PVP_SOLO']['battle'] %}
                <div class="information-col">
                    <div class="information-col-item information-type">单野</div>
                    <div class="information-col-item">{{ data['battleTypeInfoList']['PVP_SOLO']['battleInfo']['battleInfo']['battle'] }}</div>
                    <div class="information-col-item" style="color: {{ data['battleTypeInfoList']['PVP_SOLO']['battleInfo']['avgInfo']['winsData']['color'] }};">{{ data['battleTypeInfoList']['PVP_SOLO']['battleInfo']['avgInfo']['win'] }}%</div>
                    <div class="information-col-item" style="color: {{ data['battleTypeInfoList']['PVP_SOLO']['prInfo']['color'] }};">{{ data['battleTypeInfoList']['PVP_SOLO']['prInfo']['value'] }}</div>
                    <div class="information-col-item" style="color: {{ data['battleTypeInfoList']['PVP_SOLO']['battleInfo']['avgInfo']['damageData']['color'] }};">{{ data['battleTypeInfoList']['PVP_SOLO']['battleInfo']['avgInfo']['damage'] }}</div>
                    <div class="information-col-item">{{ '%.2f' | format(data['battleTypeInfoList']['PVP_SOLO']['battleInfo']['avgInfo']['frags']) }}</div>
                    <div class="information-col-item">{{ '%.2f' | format(data['battleTypeInfoList']['PVP_SOLO']['battleInfo']['hitRatioInfo']['ratioMain']) }}%</div>
                </div>
            {% endif %}

            {% if data['battleTypeInfoList']['PVP_DIV2']['battle'] %}
                <div class="information-col">
                    <div class="information-col-item information-type">自行车</div>
                    <div class="information-col-item">{{ data['battleTypeInfoList']['PVP_DIV2']['battleInfo']['battleInfo']['battle'] }}</div>
                    <div class="information-col-item" style="color: {{ data['battleTypeInfoList']['PVP_DIV2']['battleInfo']['avgInfo']['winsData']['color'] }};">{{ data['battleTypeInfoList']['PVP_DIV2']['battleInfo']['avgInfo']['win'] }}%</div>
                    <div class="information-col-item" style="color: {{ data['battleTypeInfoList']['PVP_DIV2']['prInfo']['color'] }};">{{ data['battleTypeInfoList']['PVP_DIV2']['prInfo']['value'] }}</div>
                    <div class="information-col-item" style="color: {{ data['battleTypeInfoList']['PVP_DIV2']['battleInfo']['avgInfo']['damageData']['color'] }};">{{ data['battleTypeInfoList']['PVP_DIV2']['battleInfo']['avgInfo']['damage'] }}</div>
                    <div class="information-col-item">{{ '%.2f' | format(data['battleTypeInfoList']['PVP_DIV2']['battleInfo']['avgInfo']['frags']) }}</div>
                    <div class="information-col-item">{{ '%.2f' | format(data['battleTypeInfoList']['PVP_DIV2']['battleInfo']['hitRatioInfo']['ratioMain']) }}%</div>
                </div>
            {% endif %}

            {% if data['battleTypeInfoList']['PVP_DIV3']['battle'] %}
                <div class="information-col">
                    <div class="information-col-item information-type">三轮车</div>
                    <div class="information-col-item">{{ data['battleTypeInfoList']['PVP_DIV3']['battleInfo']['battleInfo']['battle'] }}</div>
                    <div class="information-col-item" style="color: {{ data['battleTypeInfoList']['PVP_DIV3']['battleInfo']['avgInfo']['winsData']['color'] }};">{{ data['battleTypeInfoList']['PVP_DIV3']['battleInfo']['avgInfo']['win'] }}%</div>
                    <div class="information-col-item" style="color: {{ data['battleTypeInfoList']['PVP_DIV3']['prInfo']['color'] }};">{{ data['battleTypeInfoList']['PVP_DIV3']['prInfo']['value'] }}</div>
                    <div class="information-col-item" style="color: {{ data['battleTypeInfoList']['PVP_DIV3']['battleInfo']['avgInfo']['damageData']['color'] }};">{{ data['battleTypeInfoList']['PVP_DIV3']['battleInfo']['avgInfo']['damage'] }}</div>
                    <div class="information-col-item">{{ '%.2f' | format(data['battleTypeInfoList']['PVP_DIV3']['battleInfo']['avgInfo']['frags']) }}</div>
                    <div class="information-col-item">{{ '%.2f' | format(data['battleTypeInfoList']['PVP_DIV3']['battleInfo']['hitRatioInfo']['ratioMain']) }}%</div>
                </div>
            {% endif %}

            {% if data['battleTypeInfoList']['RANK_SOLO']['battle'] %}
                <div class="information-col">
                    <div class="information-col-item information-type">排位</div>
                    <div class="information-col-item">{{ data['battleTypeInfoList']['RANK_SOLO']['battleInfo']['battleInfo']['battle'] }}</div>
                    <div class="information-col-item" style="color: {{ data['battleTypeInfoList']['RANK_SOLO']['battleInfo']['avgInfo']['winsData']['color'] }};">{{ data['battleTypeInfoList']['RANK_SOLO']['battleInfo']['avgInfo']['win'] }}%</div>
                    <div class="information-col-item" style="color: {{ data['battleTypeInfoList']['RANK_SOLO']['prInfo']['color'] }};">{{ data['battleTypeInfoList']['RANK_SOLO']['prInfo']['value'] }}</div>
                    <div class="information-col-item" style="color: {{ data['battleTypeInfoList']['RANK_SOLO']['battleInfo']['avgInfo']['damageData']['color'] }};">{{ data['battleTypeInfoList']['RANK_SOLO']['battleInfo']['avgInfo']['damage'] }}</div>
                    <div class="information-col-item">{{ '%.2f' | format(data['battleTypeInfoList']['RANK_SOLO']['battleInfo']['avgInfo']['frags']) }}</div>
                    <div class="information-col-item">{{ '%.2f' | format(data['battleTypeInfoList']['RANK_SOLO']['battleInfo']['hitRatioInfo']['ratioMain']) }}%</div>
                </div>
            {% endif %}

        </div>

        <div class="day-header">每日战绩</div>

        <div class="day-body">
            <div class="day-table-header">
                <div class="day-col-item">类型</div>
                <div class="day-col-item">场次</div>
                <div class="day-col-item">胜率</div>
                <div class="day-col-item">PR</div>
                <div class="day-col-item">场均</div>
                <div class="day-col-item">击杀</div>
                <div class="day-col-item">命中</div>
            </div>


            <div class="data-item">
                {% for eachShipData in data['recentInfo'] %}
                    {% if eachShipData['battleTypeInfoList']['PVP']['battle'] or eachShipData['battleTypeInfoList']['RANK_SOLO']['battle'] %}
                        <div class="date">{{ time.strftime('%Y-%m-%d',time.localtime(int(abs(eachShipData['recordTime']/1000)))) }}</div>
                        {% for each in eachShipData['shipInfoBattleList'][0]['typeInfo'] %}
                            {% for index,value in enumerate(['PVP_SOLO','PVP_DIV2','PVP_DIV3','RANK_SOLO']) %}
                                {% if each|string == value and eachShipData['shipInfoBattleList'][0]['typeInfo'][each]['battle'] %}
                                    <div class="day-data">
                                        <div class="day-col">
                                            <div class="day-col-item" style="color: #606266;;">{{ ['单野','自行车','三轮车','排位'][index] }}</div>
                                            <div class="day-col-item">{{ eachShipData['shipInfoBattleList'][0]['typeInfo'][each]['battleInfo']['battleInfo']['battle'] }}</div>
                                            <div class="day-col-item" style="color: {{ eachShipData['shipInfoBattleList'][0]['typeInfo'][each]['battleInfo']['avgInfo']['winsData']['color'] }};">{{ eachShipData['shipInfoBattleList'][0]['typeInfo'][each]['battleInfo']['avgInfo']['win'] }}%</div>
                                            <div class="day-col-item" style="color: {{ eachShipData['shipInfoBattleList'][0]['typeInfo'][each]['prInfo']['color'] }};">{{ eachShipData['shipInfoBattleList'][0]['typeInfo'][each]['prInfo']['value'] }}</div>
                                            <div class="day-col-item" style="color: {{ eachShipData['shipInfoBattleList'][0]['typeInfo'][each]['battleInfo']['avgInfo']['damageData']['color'] }};">{{ eachShipData['shipInfoBattleList'][0]['typeInfo'][each]['battleInfo']['avgInfo']['damage'] }}</div>
                                            <div class="day-col-item">{{ '%.2f' | format(eachShipData['shipInfoBattleList'][0]['typeInfo'][each]['battleInfo']['avgInfo']['frags']) }}</div>
                                            <div class="day-col-item">{{ '%.2f' | format(eachShipData['shipInfoBattleList'][0]['typeInfo'][each]['battleInfo']['hitRatioInfo']['ratioMain']) }}</div>
                                        </div>
                                    </div>
                                {% endif %}
                            {% endfor %}
                        {% endfor %}
                    {% endif %}
                {% endfor %}
            </div>

            <div class="footer">
                <p>©西行寺雨季&nbsp;&nbsp;©本心</p>
                <p>频道搜索”yuyuko”即可使用稳定的腾讯官方机器人~</p>
                <p>Design By 冷眠 H5 Converted By C1ystal</p>
                <p>赞助鸣谢：科长、男人们的定远号、海上最速暴毙传说</p>
            </div>

        </div>



    </div>
</div>
</body>
<script>
    // PR条颜色动态变化
    let bar_bg_width = document.querySelector('.pr-bar-bg').clientWidth;
    let pr_number = document.querySelector('.pr-number').innerText;
    pr_number = parseInt(pr_number);
    if (pr_number == 0) {
        document.querySelector(".pr-bar").style.backgroundColor = "#828282";
        document.querySelector(".pr-text").innerText = "暂无数据";
    } else if (pr_number < 750) {
        document.querySelector(".pr-bar").style.backgroundColor = "#F44336";
        document.querySelector(".pr-text").innerText = "还需努力";
    } else if (pr_number < 1100) {
        document.querySelector(".pr-bar").style.backgroundColor = "#FF9800";
        document.querySelector(".pr-text").innerText = "低于平均";
    } else if (pr_number < 1350) {
        document.querySelector(".pr-bar").style.backgroundColor = "#FFC107";
        document.querySelector(".pr-text").innerText = "平均水平";
        document.querySelector(".pr-number").style.color = "#303133";
    } else if (pr_number < 1550) {
        document.querySelector(".pr-bar").style.backgroundColor = "#8BC34A";
        document.querySelector(".pr-text").innerText = "好";
    } else if (pr_number < 1750) {
        document.querySelector(".pr-bar").style.backgroundColor = "#4CAF50";
        document.querySelector(".pr-text").innerText = "很好";
    } else if (pr_number < 2100) {
        document.querySelector(".pr-bar").style.backgroundColor = "#00BCD4";
        document.querySelector(".pr-text").innerText = "非常好";
    } else if (pr_number < 2450) {
        document.querySelector(".pr-bar").style.backgroundColor = "#9C27B0";
        document.querySelector(".pr-text").innerText = "大佬水平";
    } else {
        document.querySelector(".pr-bar").style.backgroundColor = "#673AB7";
        document.querySelector(".pr-text").innerText = "神佬水平";
        pr_number = 2450; //防止pr条溢出
    }

    if (pr_number < 220 && pr_number > 0) {
        pr_number = 220; //防止pr过低导致圆角异常
    }
    // PR条动态长度
    let width = bar_bg_width * (pr_number / 2450);
    document.querySelector('.pr-bar').style.width = width + "px";
</script>

<script>
    // 服务器字体颜色自动填充
    let server_name = document.querySelector(".server").innerText;
    if (server_name == "亚服") {
        document.querySelector(".server").style.color = "#92D050";
    } else if (server_name == "国服") {
        document.querySelector(".server").style.color = "#BF9000";
    } else if (server_name == "欧服") {
        document.querySelector(".server").style.color = "#009664";
    } else if (server_name == "美服") {
        document.querySelector(".server").style.color = "#6872C4";
    } else if (server_name == "俄服") {
        document.querySelector(".server").style.color = "#FF0000";
    }
</script>

<script>
    // 数据变化动态颜色填充
    let change_avgdmg = document.querySelector(".change-avgdmg").innerText;
    change_avgdmg = parseInt(change_avgdmg);

    let change_win = document.querySelector(".change-win").innerText;
    change_win = change_win.split("%", 1);
    change_win = parseFloat(change_win);

    let change_pr = document.querySelector(".change-pr").innerText;
    change_pr = parseInt(change_pr);

    if (change_avgdmg > 0) {
        document.querySelector(".change-avgdmg").style.color = "#70AD47";
    } else {
        document.querySelector(".change-avgdmg").style.color = "#FF0000";
    }

    if (change_win > 0) {
        document.querySelector(".change-win").style.color = "#70AD47";
    } else {
        document.querySelector(".change-win").style.color = "#FF0000";
    }

    if (change_pr > 0) {
        document.querySelector(".change-pr").style.color = "#70AD47";
    } else {
        document.querySelector(".change-pr").style.color = "#FF0000";
    }
</script>

<script>
    let ship_level = document.querySelector(".ship-level").innerText;
    let level_number = ["1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11"];
    let level_roma = ["I", "II", "III", "IV", "V", "VI", "VII", "VIII", "IX", "X", "★"];
    let ship_level_roma = level_roma[level_number.indexOf(ship_level)]
    document.querySelector(".ship-level").innerText = ship_level_roma;
</script>

<script>
    let arr_information = document.getElementsByClassName('information-col');
    for (let i = 0; i < arr_information.length; i++) {
        if (i % 2 != 0 && i == (arr_information.length - 1)) {
            arr_information[i].style.backgroundColor = "#E4E4E4";
            arr_information[i].style.borderBottomLeftRadius = "16px";
            arr_information[i].style.borderBottomRightRadius = "16px";
        } else if (i % 2 != 0) {
            arr_information[i].style.backgroundColor = "#E4E4E4";
        }
    }
</script>
</html>
