:root {
    --primary: #2563eb;
    --primary-soft: rgba(37, 99, 235, 0.12);
    --accent: #06b6d4;
    --bg: #f3f6fb;
    --card: #ffffff;
    --text: #0f172a;
    --muted: #64748b;
    --success: #16a34a;
    --danger: #ef4444;
    --warning: #f59e0b;
    --line: rgba(148, 163, 184, 0.2);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: "PingFang SC", "Segoe UI", sans-serif;
    background: var(--bg);
    color: var(--text);
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    max-width: 420px;
    margin: 0 auto;
    padding: 16px 16px 96px;
}

.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.topbar h1 {
    font-size: 18px;
    margin: 0;
    font-weight: 700;
}

.topbar .subtitle {
    color: var(--muted);
    font-size: 12px;
}

.search {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #fff;
    border-radius: 14px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.06);
}

.search input {
    border: 0;
    outline: none;
    flex: 1;
    font-size: 13px;
    color: var(--text);
}

.primary-btn {
    background: linear-gradient(120deg, #2563eb, #06b6d4);
    color: #fff;
    border: 0;
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 600;
}

.card {
    background: var(--card);
    border-radius: 18px;
    padding: 14px;
    border: 1px solid rgba(148, 163, 184, 0.16);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
}

.card + .card {
    margin-top: 12px;
}

.section-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 8px 0 10px;
}

.section-title h2 {
    font-size: 15px;
    margin: 0;
}

.section-title span {
    color: var(--muted);
    font-size: 12px;
}

.countdown-box {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    min-width: 120px;
}

.countdown-time {
    font-size: 16px;
    font-weight: 700;
    color: #1d4ed8;
    letter-spacing: 0.5px;
}

.countdown-sub {
    font-size: 10px;
    color: var(--muted);
}

.countdown-track {
    width: 120px;
    height: 8px;
    border-radius: 999px;
    background: rgba(148, 163, 184, 0.2);
    overflow: hidden;
    position: relative;
}

.countdown-progress {
    height: 100%;
    width: calc(var(--progress) * 100%);
    background: linear-gradient(90deg, #2563eb, #38bdf8);
    border-radius: 999px;
    position: relative;
    animation: progressGlow 1.6s ease-in-out infinite;
}

.countdown-progress::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    width: 10px;
    height: 10px;
    transform: translate(30%, -50%);
    border-radius: 50%;
    background: #38bdf8;
    box-shadow: 0 0 10px rgba(56, 189, 248, 0.9);
}

@keyframes progressGlow {
    0% {
        filter: brightness(1);
    }
    50% {
        filter: brightness(1.15);
    }
    100% {
        filter: brightness(1);
    }
}





.badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}

.badge {
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    background: var(--primary-soft);
    color: var(--primary);
}

.badge-success {
    background: rgba(22, 163, 74, 0.12);
    color: var(--success);
}

.badge-danger {
    background: rgba(239, 68, 68, 0.12);
    color: var(--danger);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.12);
    color: var(--warning);
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.info-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 12px;
    color: var(--muted);
}

.info-row strong {
    color: var(--text);
}

.big-number {
    font-size: 26px;
    font-weight: 700;
}

.pill-list {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.list {
    display: grid;
    gap: 10px;
}

.recent-scroll {
    max-height: 240px;
    overflow-y: auto;
    padding-right: 6px;
}

.recent-scroll::-webkit-scrollbar {
    width: 4px;
}

.recent-scroll::-webkit-scrollbar-thumb {
    background: rgba(148, 163, 184, 0.5);
    border-radius: 999px;
}


.list-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8fafc;
    border-radius: 14px;
    padding: 10px 12px;
    border: 1px solid rgba(148, 163, 184, 0.12);
}

.list-item .meta {
    font-size: 12px;
    color: var(--muted);
}

.list-item .result {
    text-align: right;
}

.trend-grid {
    display: grid;
    gap: 10px;
}

.trend-row {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 8px;
}

.trend-dot {
    height: 28px;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    color: var(--muted);
    background: #fff;
}

.trend-dot.single {
    background: rgba(22, 163, 74, 0.12);
    color: var(--success);
    border-color: rgba(22, 163, 74, 0.4);
}

.trend-dot.double {
    background: rgba(239, 68, 68, 0.12);
    color: var(--danger);
    border-color: rgba(239, 68, 68, 0.4);
}

.navbar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2px;
    padding: 8px 12px calc(8px + env(safe-area-inset-bottom));
    background: rgba(255, 255, 255, 0.96);
    border-top: 1px solid rgba(148, 163, 184, 0.18);
    box-shadow: 0 -8px 24px rgba(15, 23, 42, 0.08);
    backdrop-filter: blur(10px);
    z-index: 40;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-height: 52px;
    color: #94a3b8;
    font-size: 11px;
    font-weight: 500;
}

.nav-item.active {
    color: var(--primary);
    font-weight: 700;
}

.nav-icon {
    width: 22px;
    height: 22px;
    display: block;
}

.nav-icon svg {
    width: 100%;
    height: 100%;
    display: block;
    fill: currentColor;
}

.nav-label {
    line-height: 1;
}


.header-card {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.12), rgba(6, 182, 212, 0.12));
    border-radius: 18px;
    padding: 14px;
    border: 1px solid rgba(37, 99, 235, 0.16);
}

.notice {
    font-size: 12px;
    color: var(--muted);
    line-height: 1.6;
}

.action-row {
    display: flex;
    gap: 8px;
    margin-top: 10px;
}

.secondary-btn {
    border: 1px solid rgba(37, 99, 235, 0.2);
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 13px;
    color: var(--primary);
    background: #fff;
    font-weight: 600;
}

.tag {
    padding: 2px 8px;
    border-radius: 10px;
    background: #eef2ff;
    color: #4f46e5;
    font-size: 11px;
    font-weight: 600;
}

.panel {
    background: #fff;
    border-radius: 16px;
    padding: 12px;
    border: 1px solid rgba(148, 163, 184, 0.18);
}

.panel-title {
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 8px;
}

.split {
    display: grid;
    gap: 10px;
}

@media (max-width: 360px) {
    .trend-row {
        grid-template-columns: repeat(3, 1fr);
    }
}

.hero {
    background: linear-gradient(180deg, rgba(59, 130, 246, 0.16), rgba(56, 189, 248, 0.08));
    border-radius: 18px;
    padding: 14px;
    border: 1px solid rgba(59, 130, 246, 0.16);
}

.hero-title {
    font-size: 18px;
    font-weight: 700;
    margin: 0;
}

.hero-subtitle {
    font-size: 12px;
    color: var(--muted);
    margin-top: 4px;
}

.wallet-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-top: 12px;
}

.wallet-card {
    background: #fff;
    border-radius: 14px;
    padding: 10px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.wallet-card .coin {
    width: 28px;
    height: 28px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, #22c55e, #16a34a);
}

.wallet-card.orange .coin {
    background: linear-gradient(135deg, #fb923c, #f97316);
}

.wallet-card .amount {
    font-weight: 700;
    font-size: 14px;
}

.banner {
    border-radius: 16px;
    padding: 14px;
    color: #fff;
    background: linear-gradient(120deg, #f97316, #ef4444);
    position: relative;
    overflow: hidden;
}

.banner::after {
    content: '';
    position: absolute;
    right: -20px;
    top: -20px;
    width: 120px;
    height: 120px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
}

.banner h3 {
    margin: 0 0 6px;
    font-size: 18px;
}

.game-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.game-card {
    border-radius: 16px;
    padding: 12px;
    background: #fff;
    border: 1px solid rgba(148, 163, 184, 0.16);
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.game-card .game-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #fff;
    background: linear-gradient(135deg, #60a5fa, #2563eb);
}

.game-card.orange .game-icon {
    background: linear-gradient(135deg, #fbbf24, #f97316);
}

.game-card.green .game-icon {
    background: linear-gradient(135deg, #34d399, #10b981);
}

.game-card .game-name {
    font-size: 14px;
    font-weight: 600;
}

.activity-list {
    display: grid;
    gap: 12px;
}

.activity-card {
    border-radius: 16px;
    padding: 14px;
    color: #fff;
    background: linear-gradient(120deg, #f97316, #ef4444);
    position: relative;
    overflow: hidden;
    min-height: 86px;
}

.activity-card.yellow {
    background: linear-gradient(120deg, #fbbf24, #f97316);
}

.activity-card.pink {
    background: linear-gradient(120deg, #fb7185, #f43f5e);
}

.activity-card .title {
    font-size: 16px;
    font-weight: 700;
}

.activity-card .desc {
    font-size: 12px;
    opacity: 0.85;
    margin-top: 4px;
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 12px;
}

.profile-avatar {
    width: 54px;
    height: 54px;
    border-radius: 16px;
    background: linear-gradient(135deg, #60a5fa, #2563eb);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
    font-size: 20px;
}

.profile-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-top: 12px;
}

.profile-stat {
    background: #f8fafc;
    border-radius: 14px;
    padding: 10px;
    text-align: center;
    border: 1px solid rgba(148, 163, 184, 0.12);
}

.setting-list {
    display: grid;
    gap: 10px;
}

.setting-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    border-radius: 14px;
    background: #fff;
    border: 1px solid rgba(148, 163, 184, 0.16);
}

.setting-item span {
    color: var(--muted);
    font-size: 12px;
}

.game-card-link {
    text-decoration: none;
    color: inherit;
}

.game-card-link:active {
    transform: scale(0.98);
}

.game-card-image {
    padding: 10px;
    gap: 10px;
}

.game-card-thumb {
    width: 100%;
    border-radius: 14px;
    overflow: hidden;
    aspect-ratio: 16 / 11;
    background: #e2e8f0;
}

.game-card-cover {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.game-card-caption {
    display: grid;
    gap: 4px;
}

.game-card-name {
    font-size: 13px;
    font-weight: 700;
    line-height: 1.4;
}

.game-card-meta {
    font-size: 11px;
    color: var(--muted);
}


.profile-name {
    font-size: 16px;
    font-weight: 700;
}

.profile-actions {
    display: grid;
    gap: 10px;
}

.action-btn {
    border: 0;
    border-radius: 14px;
    padding: 12px 14px;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.action-btn-primary {
    color: #fff;
    background: linear-gradient(120deg, #2563eb, #06b6d4);
    box-shadow: 0 10px 20px rgba(37, 99, 235, 0.2);
}

.action-btn-ghost {
    color: #1e293b;
    background: #f1f5f9;
    border: 1px solid rgba(148, 163, 184, 0.2);
}

.modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 60;
}

.modal.show {
    display: flex;
}

.modal-mask {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(2px);
}

.modal-card {
    position: relative;
    background: #fff;
    border-radius: 18px;
    padding: 18px;
    width: min(320px, 90%);
    z-index: 1;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.2);
}

.modal-title {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 6px;
}

.modal-desc {
    font-size: 12px;
    color: var(--muted);
    line-height: 1.6;
    margin-bottom: 12px;
}

.modal-input {
    width: 100%;
    border: 1px solid rgba(148, 163, 184, 0.3);
    border-radius: 12px;
    padding: 10px 12px;
    font-size: 13px;
    margin-bottom: 12px;
}

.modal-actions {
    display: flex;
    gap: 10px;
}

.activity-link {
    display: block;
    color: inherit;
}

.activity-link:active {
    transform: scale(0.995);
}

.activity-post {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.16);
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.06);
}

.activity-cover {
    height: 140px;
    background-size: cover;
    background-position: center;
}

.activity-body {
    padding: 12px 14px 14px;
}

.activity-body .title {
    font-size: 15px;
    font-weight: 700;
}

.activity-body .desc {
    font-size: 12px;
    color: var(--muted);
    margin-top: 4px;
}

.activity-body .meta {
    font-size: 11px;
    color: #94a3b8;
    margin-top: 6px;
}

.activity-detail-cover {
    height: 180px;
    border-radius: 18px;
    background-size: cover;
    background-position: center;
    box-shadow: 0 16px 30px rgba(15, 23, 42, 0.08);
}

.activity-detail-head {
    margin-top: 14px;
}

.activity-detail-title {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
}

.activity-detail-meta {
    margin-top: 8px;
    font-size: 12px;
    color: var(--muted);
}

.activity-detail-copy {
    margin-top: 10px;
    font-size: 13px;
    color: #334155;
    line-height: 1.75;
}

.activity-detail-section {
    margin-top: 12px;
}

.activity-detail-section h3 {
    margin: 0 0 8px;
    font-size: 15px;
}

.activity-detail-list {
    display: grid;
    gap: 8px;
}

.activity-detail-item {
    padding: 12px;
    background: #f8fafc;
    border: 1px solid rgba(148, 163, 184, 0.14);
    border-radius: 14px;
    font-size: 13px;
    line-height: 1.65;
    color: #334155;
}


.address-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.address-text,
.full-hash {
    margin-top: 6px;
    font-size: 14px;
    line-height: 1.5;
    color: var(--text);
    word-break: break-all;
}

.copy-btn {
    border: 0;
    border-radius: 12px;
    padding: 10px 12px;
    min-width: 84px;
    background: linear-gradient(120deg, #2563eb, #06b6d4);
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    box-shadow: 0 8px 18px rgba(37, 99, 235, 0.2);
}

.danger-note {
    margin-top: 10px;
    font-size: 12px;
    color: #dc2626;
    font-weight: 600;
}

.trend-board {
    display: grid;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 4px;
    scroll-behavior: smooth;
}

.trend-board::-webkit-scrollbar {
    height: 4px;
}

.trend-board::-webkit-scrollbar-thumb {
    background: rgba(148, 163, 184, 0.35);
    border-radius: 999px;
}

.trend-summary {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.trend-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
}

.trend-count-single {
    background: rgba(239, 68, 68, 0.1);
    color: #dc2626;
}

.trend-count-double {
    background: rgba(22, 163, 74, 0.1);
    color: #16a34a;
}

.trend-board-grid {
    display: grid;
    grid-template-rows: repeat(5, 34px);
    grid-auto-flow: column;
    grid-auto-columns: 30px;
    gap: 1px;
    width: max-content;
    background: rgba(148, 163, 184, 0.12);
    padding: 1px;
    border-radius: 12px;
    overflow: hidden;
}

.trend-cell {
    width: 30px;
    min-height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
}

.trend-ball {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 700;
    color: #fff;
}



.trend-ball.single {
    background: linear-gradient(135deg, #ef4444, #f87171);
    box-shadow: 0 8px 14px rgba(239, 68, 68, 0.22);
}

.trend-ball.double {
    background: linear-gradient(135deg, #16a34a, #22c55e);
    box-shadow: 0 8px 14px rgba(22, 163, 74, 0.22);
}

.floating-back {
    position: fixed;
    right: 12px;
    top: 56%;
    transform: translateY(-50%);
    border: 0;
    border-radius: 999px 0 0 999px;
    padding: 12px 14px;
    background: linear-gradient(120deg, #2563eb, #06b6d4);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    box-shadow: 0 12px 28px rgba(37, 99, 235, 0.28);
    z-index: 50;
    transition: right 0.3s ease, opacity 0.3s ease;
}

.floating-back.docked {
    right: -18px;
    opacity: 0.9;
}

.auth-page {
    background: linear-gradient(180deg, #eef4ff 0%, #f8fbff 100%);
}

.auth-shell {
    min-height: 100vh;
    max-width: 420px;
    margin: 0 auto;
    padding: 24px 16px 40px;
    display: flex;
    align-items: center;
}

.auth-card {
    width: 100%;
    background: #fff;
    border-radius: 22px;
    padding: 22px 18px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.08);
}

.auth-title {
    font-size: 24px;
    font-weight: 700;
    margin: 0;
}

.auth-desc {
    margin: 8px 0 18px;
    font-size: 13px;
    color: var(--muted);
    line-height: 1.6;
}

.auth-form {
    display: grid;
    gap: 12px;
}

.field-label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 6px;
}

.auth-input {
    width: 100%;
    border: 1px solid rgba(148, 163, 184, 0.24);
    border-radius: 14px;
    padding: 12px 14px;
    font-size: 14px;
    background: #f8fafc;
}

.auth-submit {
    width: 100%;
    justify-content: center;
    margin-top: 8px;
}

.auth-links {
    margin-top: 14px;
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: 13px;
    color: var(--primary);
}

.page-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.page-tab {
    padding: 6px 12px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid rgba(148, 163, 184, 0.18);
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
}

.page-tab.active {
    color: var(--primary);
    background: var(--primary-soft);
    border-color: rgba(37, 99, 235, 0.24);
}

.ui-message {
    margin-top: 12px;
    padding: 10px 12px;
    border-radius: 14px;
    font-size: 12px;
    line-height: 1.6;
}

.ui-message-success {
    background: rgba(22, 163, 74, 0.1);
    color: #166534;
    border: 1px solid rgba(22, 163, 74, 0.18);
}

.ui-message-error {
    background: rgba(239, 68, 68, 0.1);
    color: #b91c1c;
    border: 1px solid rgba(239, 68, 68, 0.16);
}

.game-access-panel {
    margin-top: 12px;
}

.game-access-title {
    font-size: 15px;
    font-weight: 700;
}

.game-access-desc {
    margin-top: 6px;
    font-size: 12px;
    line-height: 1.7;
    color: var(--muted);
}

.game-access-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.hidden {
    display: none !important;
}


.empty-state {
    padding: 18px 14px;
    text-align: center;
    font-size: 13px;
    color: var(--muted);
    background: #f8fafc;
    border-radius: 14px;
    border: 1px solid rgba(148, 163, 184, 0.14);
}

.status-panel,
.summary-item {
    background: #f8fafc;
    border-radius: 14px;
    padding: 12px;
    border: 1px solid rgba(148, 163, 184, 0.14);
}

.status-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 12px;
}

.inline-tip {
    font-size: 12px;
    color: var(--muted);
    line-height: 1.7;
}

.summary-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.hero-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
}

.copy-btn[disabled],
.primary-btn[disabled],
.action-btn[disabled] {
    opacity: 0.5;
    box-shadow: none;
}



