/* 数字游戏过滤系统 - 全局样式（响应式） */
* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    font-size: 14px;
    color: #333;
    background: #f2f4f7;
    -webkit-text-size-adjust: 100%;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ---------- 顶部导航 ---------- */
.app-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #1e2a3a;
    color: #fff;
    box-shadow: 0 2px 6px rgba(0, 0, 0, .12);
}

.app-header-inner {
    max-width: 1100px;
    margin: 0 auto;
    height: 52px;
    padding: 0 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.brand {
    flex: 1;
    font-size: 16px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.app-nav {
    display: flex;
    gap: 6px;
}

.app-nav a {
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 14px;
    color: #cfd8e3;
    transition: background .2s, color .2s;
}

.app-nav a.active,
.app-nav a:hover {
    background: #4d8ef7;
    color: #fff;
}

.logout {
    font-size: 14px;
    color: #cfd8e3;
    padding: 6px 4px;
    white-space: nowrap;
}

.logout:hover {
    color: #fff;
}

/* ---------- 主体 ---------- */
.app-main {
    max-width: 1100px;
    margin: 0 auto;
    padding: 12px;
}

.page-title {
    font-size: 18px;
    font-weight: 600;
    margin: 6px 2px 12px;
}

.card {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .06);
    padding: 16px;
    margin-bottom: 14px;
}

/* ---------- 表单 ---------- */
.filter-form .layui-form-label {
    width: 96px;
    padding: 9px 8px;
    text-align: right;
}

.filter-form .layui-input-block {
    margin-left: 126px;
}

.range-row {
    display: flex;
    width: 100%;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.range-input {
    width: 110px;
    max-width: 40%;
    text-align: center;
}

.range-sep {
    color: #99a3b0;
}

.hint {
    color: #99a3b0;
    font-size: 12px;
    margin-left: 6px;
}

/* 复选框组 */
.check-group {
    padding-top: 2px;
}

.filter-form .layui-form-checkbox[lay-skin="primary"] {
    margin-bottom: 6px;
}

.form-actions {
    text-align: center;
    margin: 6px 0 2px;
}

.form-actions .layui-btn {
    min-width: 140px;
}

/* ---------- 结果 ---------- */
.result-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.total-num {
    color: #ff5722;
    font-weight: 700;
    font-size: 16px;
    margin: 0 2px;
}

.result-actions {
    display: flex;
    gap: 8px;
}

.result-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    max-height: 60vh;
    overflow: auto;
    padding: 2px;
}

.result-grid .num {
    min-width: 46px;
    padding: 6px 8px;
    text-align: center;
    background: #eef4ff;
    color: #2d6cdf;
    border-radius: 6px;
    font-family: Consolas, Monaco, monospace;
    font-size: 15px;
    letter-spacing: 1px;
}

.result-grid .num.d3 {
    min-width: 58px;
}

.result-grid .num.d4 {
    min-width: 70px;
}

.empty-tip {
    width: 100%;
    color: #99a3b0;
    text-align: center;
    padding: 28px 0;
}

/* ---------- 登录页 ---------- */
.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: linear-gradient(135deg, #1e2a3a 0%, #35507a 100%);
}

.login-box {
    width: 100%;
    max-width: 360px;
    background: #fff;
    border-radius: 12px;
    padding: 26px 22px 18px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, .25);
}

.login-title {
    font-size: 20px;
    font-weight: 600;
    text-align: center;
    margin-bottom: 4px;
}

.login-sub {
    text-align: center;
    color: #99a3b0;
    font-size: 12px;
    margin-bottom: 20px;
}

.login-box .layui-input {
    height: 44px;
}

.login-box .layui-btn {
    width: 100%;
    height: 44px;
    line-height: 44px;
    font-size: 16px;
}

/* ---------- 移动端适配 ---------- */
@media (max-width: 767px) {
    .app-main {
        padding: 8px;
    }

    .card {
        padding: 12px;
    }

    .brand {
        font-size: 15px;
    }

    .app-nav a {
        padding: 6px 10px;
    }

    /* 标签独立成行 */
    .filter-form .layui-form-label {
        float: none;
        display: block;
        width: 100%;
        text-align: left;
        padding: 4px 0 6px;
        font-weight: 600;
    }

    .filter-form .layui-input-block {
        margin-left: 0;
    }

    .range-input {
        width: 45%;
        max-width: none;
    }

    .form-actions {
        display: flex;
        flex-direction: column;
        gap: 8px;
    }

    .form-actions .layui-btn {
        min-width: 100%;
        margin: 0;
    }
}
