/* Home mobile — 传统移动端彩票站 H5 风格 */
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body {
    background: #f5f5f5;
    color: #333;
    font-family: "Microsoft Yahei", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 14px;
    -webkit-font-smoothing: antialiased;
}
body {
    max-width: 550px;
    margin: 0 auto;
    position: relative;
    padding-bottom: 50px;
}

/* 顶部标题栏 */
.home-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    max-width: 550px;
    margin: 0 auto;
    height: 48px;
    line-height: 48px;
    text-align: center;
    font-size: 17px;
    color: #fff;
    background: #151314;
    z-index: 100;
}
.home-header .brand {
    font-weight: 500;
    letter-spacing: 1px;
}
.home-header .service {
    position: absolute;
    right: 0;
    top: 0;
    height: 48px;
    padding: 0 16px;
    display: flex;
    align-items: center;
    color: #fff;
    font-size: 13px;
    cursor: pointer;
}
.home-header .service img {
    width: 20px;
    height: 20px;
    margin-right: 4px;
}

/* 主容器 */
.home-wrap {
    padding-top: 48px;
}
.home-section {
    margin: 12px 12px 0;
}

/* 轮播 */
.banner-swiper {
    border-radius: 5px;
    overflow: hidden;
    background: #ddd;
}
.banner-swiper img {
    display: block;
    width: 100%;
    height: auto;
}

/* 公告条 */
.notice-bar {
    background: #fff;
    border-radius: 5px;
    padding: 10px 12px;
    margin-top: 12px;
    display: flex;
    align-items: center;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.notice-label {
    color: #009c6c;
    font-size: 13px;
    font-weight: 600;
    margin-right: 10px;
    flex-shrink: 0;
}
.notice-marquee {
    flex: 1;
    height: 20px;
    overflow: hidden;
    position: relative;
}
.notice-marquee .track {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
}
.notice-marquee .item {
    height: 20px;
    line-height: 20px;
    font-size: 13px;
    color: #666;
    transition: transform 0.5s;
}

/* 会员余额卡片 */
.member-card {
    background: #fff;
    border-radius: 5px;
    padding: 18px 16px;
    margin-top: 12px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.member-card .row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}
.member-card .welcome {
    font-size: 15px;
    color: #333;
    font-weight: 500;
}
.member-card .account {
    font-size: 12px;
    color: #888;
}
.member-card .balance-label {
    font-size: 12px;
    color: #999;
    margin-bottom: 4px;
}
.member-card .balance {
    font-size: 30px;
    color: #009c6c;
    font-weight: 700;
}

/* 游戏列表 */
.game-list {
    margin-top: 12px;
}
.game-item {
    background: #fff;
    border-radius: 5px;
    margin-bottom: 12px;
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.game-item img {
    display: block;
    width: 100%;
    height: auto;
}
.game-info {
    padding: 12px 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.game-name {
    font-size: 16px;
    color: #333;
    font-weight: 500;
}
.game-btn {
    background: #009c6c;
    color: #fff;
    border: none;
    border-radius: 3px;
    padding: 7px 18px;
    font-size: 13px;
    cursor: pointer;
}
.game-btn:active {
    background: #00885f;
}

/* 底部导航 */
.home-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    max-width: 550px;
    margin: 0 auto;
    height: 50px;
    background: #fff;
    border-top: 1px solid #e5e5e5;
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 100;
}
.home-footer a {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #888;
    font-size: 11px;
}
.home-footer a.active {
    color: #009c6c;
}
.home-footer img {
    width: 22px;
    height: 22px;
    margin-bottom: 2px;
}

/* 弹窗 */
.modal-mask {
    position: fixed;
    left: 0; top: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.4);
    z-index: 9998;
    display: none;
}
.modal-wrap {
    position: fixed;
    left: 0; right: 0; top: 0; bottom: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}
.modal-content {
    background: #fff;
    border-radius: 5px;
    width: 80vw;
    max-width: 320px;
    padding: 24px 16px 16px;
    text-align: center;
}
.modal-message {
    font-size: 15px;
    color: #333;
    line-height: 1.6;
    margin-bottom: 20px;
}
.modal-btn {
    background: #009c6c;
    color: #fff;
    border: none;
    border-radius: 3px;
    padding: 9px 28px;
    font-size: 15px;
    cursor: pointer;
}
.modal-btn:active {
    background: #00885f;
}

/* 通用页面标题栏（带返回） */
.page-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    max-width: 550px;
    margin: 0 auto;
    height: 48px;
    line-height: 48px;
    text-align: center;
    font-size: 17px;
    color: #fff;
    background: #151314;
    z-index: 100;
}
.page-header .back {
    position: absolute;
    left: 0;
    top: 0;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}
.page-header .back img {
    width: 12px;
    display: block;
}

/* 页面内容区 */
.page-content {
    padding-top: 48px;
    padding-bottom: 50px;
}
.page-section {
    margin: 12px 12px 0;
}

/* 菜单列表 */
.menu-list {
    background: #fff;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.menu-item {
    display: flex;
    align-items: center;
    padding: 14px 14px;
    border-bottom: 1px solid #f0f0f0;
    color: #333;
    font-size: 15px;
    cursor: pointer;
}
.menu-item:last-child {
    border-bottom: none;
}
.menu-item .icon {
    width: 22px;
    height: 22px;
    margin-right: 10px;
    object-fit: contain;
}
.menu-item .text {
    flex: 1;
}
.menu-item .arrow {
    color: #ccc;
    font-size: 13px;
}

/* 信息卡片 */
.info-card {
    background: #fff;
    border-radius: 5px;
    padding: 4px 14px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 0;
    border-bottom: 1px solid #f0f0f0;
}
.info-row:last-child {
    border-bottom: none;
}
.info-row .label {
    color: #666;
    font-size: 14px;
}
.info-row .value {
    color: #333;
    font-size: 14px;
}

/* 表单 */
.form-group {
    background: #fff;
    border-radius: 5px;
    padding: 4px 14px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.form-row {
    display: flex;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}
.form-row:last-child {
    border-bottom: none;
}
.form-label {
    color: #666;
    font-size: 14px;
    min-width: 70px;
    margin-right: 10px;
}
.form-input {
    flex: 1;
    border: none;
    background: transparent;
    font-size: 15px;
    color: #333;
    outline: none;
    height: 28px;
}
.form-input::placeholder {
    color: #bbb;
}
.form-input:disabled,
.form-input[readonly] {
    color: #999;
}

/* 按钮 */
.btn-primary {
    background: #009c6c;
    color: #fff;
    border: none;
    border-radius: 3px;
    padding: 11px 20px;
    font-size: 15px;
    cursor: pointer;
    text-align: center;
}
.btn-primary:active {
    background: #00885f;
}
.btn-block {
    display: block;
    width: 100%;
}
.btn-danger {
    background: #e13042;
    color: #fff;
    border: none;
    border-radius: 3px;
    padding: 11px 20px;
    font-size: 15px;
    cursor: pointer;
    text-align: center;
}
.btn-danger:active {
    background: #c41f30;
}

/* 个人中心余额卡片 */
.mine-balance-card {
    background: #fff;
    border-radius: 5px;
    padding: 18px 14px;
    margin: 12px 12px 0;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.mine-balance-card .top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}
.mine-balance-card .welcome {
    font-size: 15px;
    color: #333;
    font-weight: 500;
}
.mine-balance-card .account {
    font-size: 12px;
    color: #888;
}
.mine-balance-card .balance {
    font-size: 28px;
    color: #009c6c;
    font-weight: 700;
    margin-top: 4px;
}
.mine-balance-card .stats {
    display: flex;
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid #f0f0f0;
}
.mine-balance-card .stat {
    flex: 1;
    text-align: center;
}
.mine-balance-card .stat-value {
    font-size: 16px;
    color: #333;
    font-weight: 500;
}
.mine-balance-card .stat-label {
    font-size: 12px;
    color: #999;
    margin-top: 4px;
}

/* 空状态 */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 60px 20px;
    color: #999;
    font-size: 14px;
}
.empty-state img {
    width: 80px;
    margin-bottom: 12px;
    opacity: 0.5;
}

/* 充值/提现专用 */
.amount-input {
    display: flex;
    align-items: center;
    background: #fff;
    border-radius: 5px;
    padding: 12px 14px;
    margin-bottom: 16px;
    border: 1px solid #e5e5e5;
}
.amount-input .symbol {
    color: #009c6c;
    font-size: 18px;
    margin-right: 8px;
    font-weight: 600;
}
.amount-input input {
    flex: 1;
    border: none;
    background: transparent;
    font-size: 16px;
    color: #333;
    outline: none;
}
.amount-input input::placeholder {
    color: #bbb;
}

.notice-box {
    background: #fff;
    border-radius: 5px;
    padding: 16px;
    margin-bottom: 16px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.notice-box .title {
    font-size: 15px;
    color: #333;
    font-weight: 500;
    margin-bottom: 8px;
}
.notice-box .warning {
    color: #e13042;
    font-size: 13px;
    line-height: 1.6;
}

.qrcode-wrap {
    background: #fff;
    border-radius: 5px;
    padding: 20px;
    text-align: center;
    margin-bottom: 16px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.qrcode-wrap img {
    width: 180px;
    height: 180px;
    display: block;
    margin: 0 auto 12px;
    background: #f5f5f5;
}
.qrcode-wrap .pay-name {
    font-size: 15px;
    color: #333;
    margin-bottom: 4px;
}
.qrcode-wrap .pay-account {
    font-size: 13px;
    color: #666;
}

/* 弹窗 */
.modal-mask {
    position: fixed;
    left: 0; top: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.4);
    z-index: 9998;
    display: none;
}
.modal-wrap {
    position: fixed;
    left: 0; right: 0; top: 0; bottom: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}
.modal-content {
    background: #fff;
    border-radius: 5px;
    width: 80vw;
    max-width: 320px;
    padding: 22px 16px 16px;
    text-align: center;
}
.modal-message {
    font-size: 15px;
    color: #333;
    line-height: 1.6;
    margin-bottom: 18px;
}
.modal-actions {
    display: flex;
    gap: 12px;
}
.modal-actions button {
    flex: 1;
    padding: 9px 0;
    font-size: 15px;
    border: none;
    border-radius: 3px;
    cursor: pointer;
}
.modal-actions .cancel {
    background: #f5f5f5;
    color: #666;
}
.modal-actions .confirm {
    background: #009c6c;
    color: #fff;
}

/* 记录页通用 */
.total-section {
    background: #fff;
    border-radius: 5px;
    padding: 18px 14px;
    margin: 12px 12px 0;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.total-section .label {
    font-size: 13px;
    color: #888;
    margin-bottom: 6px;
}
.total-section .amount {
    font-size: 28px;
    color: #009c6c;
    font-weight: 700;
}

.stat-bar {
    display: flex;
    background: #fff;
    border-radius: 5px;
    padding: 16px 0;
    margin: 12px 12px 0;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.stat-bar .item {
    flex: 1;
    text-align: center;
    border-right: 1px solid #f0f0f0;
}
.stat-bar .item:last-child {
    border-right: none;
}
.stat-bar .value {
    font-size: 16px;
    color: #333;
    font-weight: 600;
    margin-bottom: 4px;
}
.stat-bar .label {
    font-size: 12px;
    color: #999;
}

.date-tab-bar {
    display: flex;
    background: #fff;
    padding: 0 12px;
    margin: 12px 12px 0;
    border-radius: 5px 5px 0 0;
    overflow-x: auto;
    white-space: nowrap;
    scrollbar-width: none;
    border-bottom: 1px solid #f0f0f0;
}
.date-tab-bar::-webkit-scrollbar { display: none; }
.date-tab {
    display: inline-block;
    color: #666;
    font-size: 14px;
    padding: 12px 10px;
    margin-right: 8px;
    cursor: pointer;
    border-bottom: 2px solid transparent;
}
.date-tab.active {
    color: #009c6c;
    border-bottom-color: #009c6c;
}

.record-list {
    margin: 0 12px 12px;
}
.record-card {
    background: #fff;
    border-radius: 5px;
    padding: 14px;
    margin-bottom: 10px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.record-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}
.record-row:last-child {
    margin-bottom: 0;
}
.record-label {
    font-size: 13px;
    color: #888;
}
.record-value {
    font-size: 14px;
    color: #333;
    font-weight: 500;
}
.record-status {
    font-size: 12px;
    padding: 2px 8px;
    border-radius: 3px;
    margin-left: 8px;
}
.record-status.success { color: #009c6c; background: #e6f7f1; }
.record-status.pending { color: #ff9800; background: #fff7e6; }
.record-status.rejected { color: #e13042; background: #ffe6e8; }

.empty-record {
    text-align: center;
    padding: 60px 20px;
    color: #999;
    font-size: 14px;
}

/* 数据表格 */
.data-table {
    width: 100%;
    background: #fff;
    border-radius: 5px;
    overflow: hidden;
    margin: 12px 12px 0;
    width: calc(100% - 24px);
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
    border-collapse: collapse;
}
.data-table th,
.data-table td {
    padding: 12px 8px;
    text-align: center;
    font-size: 13px;
    border-bottom: 1px solid #f0f0f0;
}
.data-table th {
    background: #fafafa;
    color: #666;
    font-weight: 500;
}
.data-table td {
    color: #333;
}

/* 盈亏记录 */
.profit-list {
    margin: 12px 12px 0;
    background: #fff;
    border-radius: 5px;
    padding: 4px 14px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.profit-list .item {
    display: flex;
    justify-content: space-between;
    padding: 14px 0;
    border-bottom: 1px solid #f0f0f0;
}
.profit-list .item:last-child {
    border-bottom: none;
}
.profit-list .label {
    font-size: 14px;
    color: #666;
}
.profit-list .value {
    font-size: 15px;
    color: #333;
    font-weight: 500;
}
.profit-list .value.lose {
    color: #e13042;
}

/* 客服/推广页 */
.service-card {
    background: #fff;
    border-radius: 5px;
    padding: 30px 20px;
    margin: 12px 12px 0;
    text-align: center;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.service-card .title {
    font-size: 16px;
    color: #333;
    margin-bottom: 8px;
    font-weight: 500;
}
.service-card .subtitle {
    font-size: 13px;
    color: #888;
    margin-bottom: 20px;
}
.service-card .qrcode {
    width: 180px;
    height: 180px;
    display: block;
    margin: 0 auto;
    background: #f5f5f5;
}
.copy-row {
    display: flex;
    background: #f5f5f5;
    border: 1px solid #e5e5e5;
    border-radius: 3px;
    overflow: hidden;
    margin-top: 20px;
}
.copy-row input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 10px 12px;
    font-size: 14px;
    color: #333;
    outline: none;
}
.copy-row button {
    background: #009c6c;
    color: #fff;
    border: none;
    padding: 0 16px;
    font-size: 14px;
    cursor: pointer;
}
.copy-row button:active {
    background: #00885f;
}

/* 404 */
.notfound {
    text-align: center;
    padding-top: 30vh;
    color: #999;
}
.notfound h3 {
    font-size: 48px;
    color: #ccc;
    font-weight: normal;
    margin-bottom: 12px;
}
.notfound p {
    font-size: 14px;
    margin-bottom: 24px;
}

/* 邀请好友 */
.invite-card {
    background: #fff;
    border-radius: 5px;
    padding: 24px 16px;
    margin: 12px 12px 0;
    text-align: center;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.invite-card img {
    width: 200px;
    height: 200px;
    display: block;
    margin: 0 auto 16px;
    background: #f5f5f5;
}
.invite-tips {
    margin-top: 16px;
    font-size: 13px;
    color: #666;
    line-height: 1.8;
    text-align: left;
}
.invite-tips p {
    margin-bottom: 6px;
}

/* 客服入口 */
.service-entry {
    margin: 12px 12px 0;
}
.service-entry a {
    display: block;
    background: #fff;
    border-radius: 5px;
    padding: 16px 14px;
    margin-bottom: 10px;
    color: #333;
    font-size: 15px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

/* iframe 全屏 */
.iframe-page {
    padding-top: 48px;
    height: 100vh;
}
.iframe-page iframe {
    width: 100%;
    height: calc(100% - 48px);
    border: none;
    display: block;
}

/* 规则页 */
.rule-content {
    margin: 12px 12px 0;
    background: #fff;
    border-radius: 5px;
    padding: 18px 16px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
    line-height: 1.8;
    font-size: 14px;
    color: #333;
}
.rule-content h2 {
    font-size: 16px;
    color: #009c6c;
    margin-bottom: 12px;
    font-weight: 600;
}
.rule-content h3,
.rule-content h4 {
    font-size: 14px;
    color: #555;
    margin-bottom: 10px;
    font-weight: normal;
}

/* 房间选择 */
.room-select-list {
    margin: 12px 12px 0;
}
.room-select-card {
    position: relative;
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 12px;
    height: 120px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
.room-select-card img {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.room-select-info {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 50%;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: center;
    padding-right: 20px;
    background: linear-gradient(to right, transparent, rgba(0,0,0,0.4));
}
.room-select-title {
    font-size: 22px;
    color: #fff;
    font-weight: 600;
    margin-bottom: 10px;
    text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}
.room-select-btn {
    background: #009c6c;
    color: #fff;
    border: none;
    border-radius: 3px;
    padding: 6px 16px;
    font-size: 13px;
    cursor: pointer;
}
.room-select-btn:active {
    background: #00885f;
}

/* 安全区域 */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
    body { padding-bottom: calc(50px + env(safe-area-inset-bottom)); }
    .home-footer { padding-bottom: env(safe-area-inset-bottom); height: calc(50px + env(safe-area-inset-bottom)); }
}
