* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background: #04040e;
    color: #ffffff;
    font-family: 'Courier New', monospace;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    overflow: hidden;
}

/* ── Stars ── */
#stars {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}
.star {
    position: absolute;
    background: #fff;
    border-radius: 50%;
    animation: twinkle var(--dur) ease-in-out infinite alternate;
    animation-delay: var(--delay);
}
@keyframes twinkle {
    from { opacity: var(--a1); }
    to   { opacity: var(--a2); }
}

/* ── Moon ── */
#moon {
    position: fixed;
    top: 36px;
    right: 60px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #cddff5;
    box-shadow:
        0 0 16px 6px rgba(200,224,255,0.12),
        0 0 32px 14px rgba(200,224,255,0.07),
        0 0 56px 28px rgba(200,224,255,0.04);
    z-index: 0;
}

/* ── City silhouette ── */
#city {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 160px;
    z-index: 0;
}

/* ── Main container ── */
#wrap {
    position: relative;
    z-index: 10;
    width: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
}

/* ── Title ── */
#title-block {
    text-align: center;
    margin-bottom: 38px;
}
#title-sub {
    font-size: 11px;
    letter-spacing: 6px;
    color: #4488cc;
    text-transform: uppercase;
    margin-bottom: 8px;
}
#title {
    font-size: 48px;
    font-weight: bold;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: #e8f4ff;
    text-shadow:
        0 0 8px #3399ff,
        0 0 20px #1166cc,
        0 0 40px #0044aa44;
    animation: titlePulse 3s ease-in-out infinite;
}
@keyframes titlePulse {
    0%,100% { text-shadow: 0 0 8px #3399ff, 0 0 20px #1166cc, 0 0 40px #0044aa44; }
    50%      { text-shadow: 0 0 14px #55bbff, 0 0 30px #2288ee, 0 0 60px #0055cc55; }
}
#title-divider {
    width: 180px;
    height: 1px;
    background: linear-gradient(to right, transparent, #4488cc, transparent);
    margin: 12px auto 0;
}

/* ── Menu buttons ── */
#menu {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.menu-btn {
    width: 100%;
    padding: 15px 28px;
    background: rgba(10, 18, 36, 0.85);
    border: 1.5px solid #1e3a6e;
    border-radius: 8px;
    color: #88bbff;
    font-family: 'Courier New', monospace;
    font-size: 15px;
    font-weight: bold;
    letter-spacing: 2px;
    text-transform: uppercase;
    cursor: pointer;
    text-align: left;
    display: flex;
    align-items: center;
    gap: 14px;
    transition: background 0.18s, border-color 0.18s, color 0.18s, transform 0.12s;
    position: relative;
    overflow: hidden;
}
.menu-btn::before {
    content: '';
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 3px;
    background: #3377cc;
    opacity: 0;
    transition: opacity 0.18s;
}
.menu-btn:hover {
    background: rgba(20, 40, 80, 0.95);
    border-color: #4488cc;
    color: #cce8ff;
    transform: translateX(4px);
}
.menu-btn:hover::before { opacity: 1; }
.menu-btn:active { transform: translateX(2px) scale(0.99); }

.menu-btn .icon {
    font-size: 20px;
    width: 28px;
    text-align: center;
    flex-shrink: 0;
}
.menu-btn .label { flex: 1; }
.menu-btn .arrow {
    color: #2255aa;
    font-size: 18px;
    transition: color 0.18s;
}
.menu-btn:hover .arrow { color: #66aaff; }

/* ── Footer ── */
#footer {
    margin-top: 32px;
    font-size: 10px;
    color: #1e3050;
    letter-spacing: 2px;
    text-align: center;
}

/* ── Modal backdrop ── */
.modal-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.78);
    z-index: 100;
    align-items: center;
    justify-content: center;
}
.modal-backdrop.open { display: flex; }

/* ── Modal panel ── */
.modal {
    width: 360px;
    background: #080c18;
    border: 1.5px solid #1e3a6e;
    border-radius: 12px;
    padding: 28px 28px 24px;
    position: relative;
    box-shadow: 0 0 40px rgba(30,80,180,0.18);
    animation: modalIn 0.18s ease;
}
@keyframes modalIn {
    from { opacity: 0; transform: translateY(12px) scale(0.97); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}
.modal-title {
    font-size: 13px;
    letter-spacing: 4px;
    color: #4488cc;
    text-transform: uppercase;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid #0e1c36;
}
.modal-close {
    position: absolute;
    top: 14px; right: 18px;
    background: none;
    border: none;
    color: #334466;
    font-size: 20px;
    cursor: pointer;
    font-family: monospace;
    line-height: 1;
    transition: color 0.15s;
}
.modal-close:hover { color: #88bbff; }

/* ── High Score modal ── */
#hs-list {
    min-height: 120px;
}
.hs-empty {
    color: #2a4060;
    font-size: 13px;
    text-align: center;
    padding: 30px 0;
}
.hs-row {
    display: flex;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #0a1428;
    font-size: 14px;
}
.hs-rank {
    width: 30px;
    color: #2a4060;
    font-size: 12px;
}
.hs-rank.gold   { color: #ffcc44; }
.hs-rank.silver { color: #aaaacc; }
.hs-rank.bronze { color: #cc7744; }
.hs-name  { flex: 1; color: #88bbff; }
.hs-score { color: #ffee88; font-weight: bold; letter-spacing: 1px; }
.hs-row.hs-me { background: rgba(68,136,204,0.1); border-radius: 4px; }
.hs-row.hs-me .hs-name { color: #aaddff; }
.hs-row.hs-my-rank { margin-top: 8px; border-top: 1px dashed #0a1a30; padding-top: 8px; }

#hs-clear-btn {
    margin-top: 16px;
    background: none;
    border: 1px solid #1e2e4e;
    border-radius: 5px;
    color: #2a4060;
    font-family: monospace;
    font-size: 11px;
    letter-spacing: 1px;
    padding: 6px 14px;
    cursor: pointer;
    transition: border-color 0.15s, color 0.15s;
}
#hs-clear-btn:hover { border-color: #cc3333; color: #cc6666; }

/* ── Enter Name modal ── */
#name-form { display: flex; flex-direction: column; gap: 14px; }
#name-input {
    background: #050912;
    border: 1.5px solid #1e3a6e;
    border-radius: 6px;
    color: #cce8ff;
    font-family: 'Courier New', monospace;
    font-size: 18px;
    letter-spacing: 3px;
    padding: 12px 16px;
    outline: none;
    text-transform: uppercase;
    transition: border-color 0.18s;
}
#name-input:focus { border-color: #4488cc; }
#name-input::placeholder { color: #1e3050; letter-spacing: 2px; }
#name-save-btn {
    background: #0a1e42;
    border: 1.5px solid #2255aa;
    border-radius: 6px;
    color: #88bbff;
    font-family: 'Courier New', monospace;
    font-size: 13px;
    font-weight: bold;
    letter-spacing: 3px;
    padding: 12px;
    cursor: pointer;
    text-transform: uppercase;
    transition: background 0.18s, border-color 0.18s, color 0.18s;
}
#name-save-btn:hover { background: #10306a; border-color: #4488cc; color: #cce8ff; }
#name-saved-msg {
    color: #44cc88;
    font-size: 12px;
    text-align: center;
    letter-spacing: 2px;
    min-height: 18px;
}
#current-name-display {
    font-size: 12px;
    color: #2a4060;
    text-align: center;
}
#current-name-display span { color: #5599cc; }

/* ── About modal ── */
#about-content {
    color: #6688aa;
    font-size: 13px;
    line-height: 1.8;
}
#about-content h3 {
    color: #4488cc;
    font-size: 12px;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin: 16px 0 6px;
}
#about-content h3:first-child { margin-top: 0; }
#about-content ul {
    list-style: none;
    padding: 0;
}
#about-content ul li::before { content: '›  '; color: #2255aa; }
#about-content .key {
    display: inline-block;
    background: #0a1428;
    border: 1px solid #1e3a6e;
    border-radius: 4px;
    padding: 1px 7px;
    color: #88bbff;
    font-size: 12px;
    letter-spacing: 1px;
}

/* ── Skubu Market menu button accent ── */
.market-menu-btn { border-color: #2a4a22 !important; }
.market-menu-btn .icon { color: #ccaa44; }
.market-menu-btn:hover { border-color: #55aa33 !important; color: #ccffaa !important; }
.market-menu-btn:hover .arrow { color: #88dd55 !important; }

/* ── Market modal overrides ── */
.market-modal {
    width: 400px;
    max-height: 88vh;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #1e3a6e #050912;
}

/* ── Balance row ── */
.market-balance {
    font-size: 13px;
    color: #6688aa;
    margin-bottom: 6px;
    letter-spacing: 1px;
}
.market-balance span { color: #ffcc44; font-weight: bold; }
.market-bal-unit { color: #886622; }

/* ── Demo badge ── */
.market-demo-badge {
    display: inline-block;
    background: #1a1200;
    border: 1px solid #443300;
    border-radius: 4px;
    color: #886622;
    font-size: 9px;
    letter-spacing: 2px;
    padding: 3px 10px;
    margin-bottom: 18px;
    text-transform: uppercase;
}

/* ── Package grid ── */
.market-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 16px;
}

/* ── Package card ── */
.market-card {
    background: #05090f;
    border: 1.5px solid #0e1e36;
    border-radius: 10px;
    padding: 16px 14px 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    transition: border-color 0.18s, background 0.18s;
    cursor: default;
    position: relative;
    overflow: hidden;
}
.market-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: var(--card-accent);
    opacity: 0.6;
}
.market-card:hover {
    background: #080e1a;
    border-color: var(--card-accent);
}

.market-card-label {
    font-size: 9px;
    letter-spacing: 3px;
    color: var(--card-accent);
    text-transform: uppercase;
    font-weight: bold;
}
.market-card-gems {
    font-size: 18px;
    letter-spacing: 2px;
    color: #ccaa44;
    margin: 2px 0;
    line-height: 1;
}
.market-card-amount {
    font-size: 28px;
    font-weight: bold;
    color: #ffdd66;
    line-height: 1;
    text-shadow: 0 0 10px #886600;
}
.market-card-unit {
    font-size: 10px;
    color: #887744;
    letter-spacing: 2px;
    margin-bottom: 4px;
}
.market-card-price {
    font-size: 15px;
    color: #99bbcc;
    font-weight: bold;
    letter-spacing: 1px;
}
.market-card-best {
    position: absolute;
    top: 8px; right: 8px;
    background: var(--card-accent);
    color: #000;
    font-size: 7px;
    font-weight: bold;
    letter-spacing: 1px;
    padding: 2px 6px;
    border-radius: 3px;
    text-transform: uppercase;
    opacity: 0.85;
}
.market-buy-btn {
    width: 100%;
    margin-top: 6px;
    padding: 8px 0;
    background: transparent;
    border: 1.5px solid var(--card-accent);
    border-radius: 6px;
    color: var(--card-accent);
    font-family: 'Courier New', monospace;
    font-size: 12px;
    font-weight: bold;
    letter-spacing: 3px;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}
.market-buy-btn:hover {
    background: var(--card-accent);
    color: #000a1a;
}
.market-buy-btn.bought {
    background: #113322;
    border-color: #44cc88;
    color: #44cc88;
    cursor: default;
}

/* ── Market footer ── */
.market-footer {
    font-size: 10px;
    color: #1e2e3e;
    text-align: center;
    letter-spacing: 1px;
    padding-top: 4px;
    border-top: 1px solid #0a1020;
}

/* ── Skubu Purchase Splash ── */
#skubu-splash {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 500;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}
#skubu-splash.active {
    display: flex;
    pointer-events: all;
}
#skubu-splash.hiding .splash-bg,
#skubu-splash.hiding .splash-content {
    animation: splashOut 0.45s ease forwards;
}
#skubu-splash.hiding #splash-coins {
    transition: opacity 0.3s;
    opacity: 0;
}

.splash-bg {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
    animation: splashBgIn 0.2s ease forwards;
}
@keyframes splashBgIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}
@keyframes splashOut {
    from { opacity: 1; transform: scale(1); }
    to   { opacity: 0; transform: scale(1.04); }
}

/* Coin rain layer */
#splash-coins {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
}
.splash-coin {
    position: absolute;
    top: -40px;
    color: #ffcc44;
    font-family: monospace;
    animation: coinFall var(--dur) var(--delay) cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
    text-shadow: 0 0 6px #ff8800;
}
@keyframes coinFall {
    0%   { transform: translateY(0)      rotate(0deg)   scale(0);   opacity: 0; }
    12%  { transform: translateY(20px)   rotate(60deg)  scale(1.1); opacity: 1; }
    80%  { opacity: 0.7; }
    100% { transform: translateY(110vh)  rotate(540deg) scale(0.6); opacity: 0; }
}

/* Central content */
.splash-content {
    position: relative;
    z-index: 1;
    text-align: center;
    animation: splashPop 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}
@keyframes splashPop {
    from { opacity: 0; transform: scale(0.4); }
    to   { opacity: 1; transform: scale(1); }
}
.splash-stars {
    font-size: 22px;
    color: #ccaa44;
    letter-spacing: 10px;
    margin-bottom: 10px;
    animation: starsPulse 0.7s ease-in-out infinite alternate;
}
@keyframes starsPulse {
    from { opacity: 0.5; letter-spacing: 8px; }
    to   { opacity: 1;   letter-spacing: 12px; }
}
.splash-title {
    font-size: 58px;
    font-weight: bold;
    font-family: 'Courier New', monospace;
    color: #ffdd33;
    letter-spacing: 5px;
    text-transform: uppercase;
    text-shadow:
        0 0 12px #ffaa00,
        0 0 28px #ff8800,
        0 0 55px #ff440055;
    animation: titleGlow 0.5s ease-in-out infinite alternate;
}
@keyframes titleGlow {
    from { text-shadow: 0 0 12px #ffaa00, 0 0 28px #ff8800; }
    to   { text-shadow: 0 0 20px #ffdd00, 0 0 45px #ffaa00, 0 0 70px #ff660066; }
}
.splash-amount {
    font-size: 38px;
    font-weight: bold;
    font-family: 'Courier New', monospace;
    color: #ffffff;
    letter-spacing: 2px;
    margin-top: 10px;
    text-shadow: 0 0 14px #88ffaa, 0 0 30px #44cc7755;
}
.splash-sub {
    font-size: 11px;
    font-family: 'Courier New', monospace;
    color: #886622;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-top: 8px;
}

/* ── Market Tabs ── */
.market-tabs {
    display: flex;
    border-bottom: 1px solid #0e1c36;
    margin-bottom: 16px;
}
.mkt-tab {
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    color: #2a4060;
    font-family: 'Courier New', monospace;
    font-size: 11px;
    font-weight: bold;
    letter-spacing: 2px;
    text-transform: uppercase;
    padding: 6px 16px 8px;
    cursor: pointer;
    transition: color 0.15s, border-color 0.15s;
    margin-bottom: -1px;
}
.mkt-tab:hover { color: #88bbff; }
.mkt-tab.active {
    color: #4488cc;
    border-bottom-color: #4488cc;
}

/* ── Wallet panel ── */
.wallet-balance-row {
    font-size: 13px;
    color: #6688aa;
    margin-bottom: 16px;
    letter-spacing: 1px;
}
.wallet-balance-row #wallet-balance { color: #ffcc44; font-weight: bold; }
.wallet-section {
    border-left: 2px solid #1a2e10;
    padding-left: 10px;
    margin-bottom: 18px;
}
.wallet-section-title {
    font-size: 9px;
    color: #446622;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 8px;
}
.amt-pills {
    display: flex;
    gap: 8px;
    margin: 10px 0;
}
.amt-pill {
    background: none;
    border: 1px solid #1e3a2e;
    border-radius: 5px;
    color: #446644;
    font-family: 'Courier New', monospace;
    font-size: 13px;
    font-weight: bold;
    padding: 5px 12px;
    cursor: pointer;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.amt-pill:hover { border-color: #44aa66; color: #88cc88; }
.amt-pill.active {
    background: #332200;
    border-color: #aa8833;
    color: #ffcc44;
}
.wallet-btn {
    width: 100%;
    padding: 9px 0;
    background: transparent;
    border: 1.5px solid #aa8833;
    border-radius: 6px;
    color: #aa8833;
    font-family: 'Courier New', monospace;
    font-size: 11px;
    font-weight: bold;
    letter-spacing: 2px;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    margin-top: 4px;
}
.wallet-btn:hover { background: #2a1a00; color: #ffcc44; }
.wallet-btn:disabled { opacity: 0.4; cursor: default; }
.wallet-link-box {
    display: none;
    background: #050912;
    border: 1px solid #0e1c36;
    border-radius: 8px;
    padding: 12px;
    margin-top: 10px;
}
.wallet-link-box .link-msg {
    font-size: 11px;
    color: #446644;
    letter-spacing: 1px;
    margin-bottom: 8px;
}
.wallet-link-box input {
    width: 100%;
    background: #020408;
    border: 1px solid #0e1c36;
    border-radius: 4px;
    color: #4488aa;
    font-family: 'Courier New', monospace;
    font-size: 10px;
    padding: 6px 8px;
    outline: none;
    letter-spacing: 0.5px;
}
.wallet-link-actions {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}
.wallet-copy-btn, .wallet-share-btn {
    background: transparent;
    border: 1px solid #1e3a2e;
    border-radius: 5px;
    color: #446644;
    font-family: 'Courier New', monospace;
    font-size: 10px;
    letter-spacing: 1px;
    padding: 5px 10px;
    cursor: pointer;
    transition: border-color 0.15s, color 0.15s;
}
.wallet-copy-btn:hover, .wallet-share-btn:hover { border-color: #44aa66; color: #88cc88; }
.wallet-error {
    display: none;
    color: #cc4444;
    font-size: 11px;
    letter-spacing: 1px;
    margin-top: 6px;
}
.wallet-request-prompt {
    display: none;
    background: #0d0900;
    border: 1px solid #443300;
    border-radius: 8px;
    padding: 14px;
    margin-top: 4px;
}
.wrp-title {
    color: #ccaa44;
    font-size: 13px;
    letter-spacing: 1px;
    margin-bottom: 6px;
}
.wrp-balance {
    font-size: 11px;
    color: #6688aa;
    letter-spacing: 1px;
    margin-bottom: 12px;
}
.wrp-actions {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
}
.wrp-actions .wallet-btn { margin-top: 0; }
.wrp-send-btn { border-color: #55aa33; color: #55aa33; }
.wrp-send-btn:hover:not(:disabled) { background: #0a1a00; color: #88ff44; }
.wrp-decline-btn { border-color: #553333; color: #884444; }
.wrp-decline-btn:hover { background: #1a0a0a; color: #cc6666; }

/* ── Toast notification ── */
#_toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: #1a0d00;
    border: 1px solid #443300;
    color: #ccaa44;
    font-family: 'Courier New', monospace;
    font-size: 12px;
    letter-spacing: 2px;
    padding: 10px 20px;
    border-radius: 6px;
    z-index: 1000;
    pointer-events: none;
    transition: opacity 0.4s;
    opacity: 0;
}
#_toast.visible { opacity: 1; }

/* ── Skubu badge — wallet-aware ── */
#skubu-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
}
.wallet-addr {
    color: #4488cc;
    font-size: 11px;
    letter-spacing: 1px;
}
.auth-connect-btn, .auth-disconnect-btn {
    font-family: 'Courier New', monospace;
    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
    cursor: pointer;
    padding: 4px 10px;
    border-radius: 4px;
    transition: background 0.18s, color 0.18s;
}
.auth-connect-btn {
    background: transparent;
    border: 1px solid #2255aa;
    color: #4488cc;
}
.auth-connect-btn:hover {
    background: #0a1530;
    color: #88ccff;
    border-color: #4488cc;
}
.auth-disconnect-btn {
    background: transparent;
    border: 1px solid #442222;
    color: #884444;
    font-size: 9px;
}
.auth-disconnect-btn:hover {
    background: #1a0808;
    color: #cc6666;
}

/* ── Auth Modal ── */
.auth-modal {
    width: 360px;
}
.auth-google-btn {
    width: 100%;
    justify-content: center;
    background: #0d1a2e;
    color: #88bbff;
    border-color: #224488;
    margin-bottom: 4px;
}
.auth-google-btn:hover {
    background: #0a1530;
    color: #bbddff;
}
.auth-divider {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 12px 0;
    color: #2a3a50;
    font-size: 11px;
    letter-spacing: 2px;
}
.auth-divider::before, .auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #1a2a40;
}
.auth-email-row {
    display: flex;
    gap: 8px;
    align-items: stretch;
}
.auth-email-row input {
    flex: 1;
    background: #080e18;
    border: 1px solid #1e3050;
    color: #aaccee;
    font-family: 'Courier New', monospace;
    font-size: 13px;
    letter-spacing: 1px;
    padding: 9px 12px;
    border-radius: 6px;
    outline: none;
    transition: border-color 0.18s;
}
.auth-email-row input:focus {
    border-color: #3366aa;
}
.auth-email-row .wallet-btn {
    margin: 0;
    white-space: nowrap;
    padding: 9px 16px;
}
.auth-otp-hint {
    font-size: 11px;
    color: #4477aa;
    letter-spacing: 1px;
    margin-bottom: 12px;
    text-align: center;
}
.auth-back-btn {
    display: block;
    margin: 14px auto 0;
    background: none;
    border: none;
    color: #334466;
    font-family: 'Courier New', monospace;
    font-size: 11px;
    letter-spacing: 1px;
    cursor: pointer;
    transition: color 0.18s;
}
.auth-back-btn:hover { color: #6699cc; }

/* Spinner */
.auth-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    padding: 24px 0 8px;
}
.auth-spinner-ring {
    width: 36px;
    height: 36px;
    border: 3px solid #1a2a40;
    border-top-color: #4488cc;
    border-radius: 50%;
    animation: authSpin 0.8s linear infinite;
}
@keyframes authSpin {
    to { transform: rotate(360deg); }
}
.auth-spinner-msg {
    font-size: 12px;
    color: #4488cc;
    letter-spacing: 2px;
}

/* ── Global Leaderboard ── */
#global-lb {
    width: 100%;
    margin-top: 20px;
    background: rgba(4, 8, 20, 0.82);
    border: 1px solid #0e1c36;
    border-radius: 10px;
    padding: 14px 18px 12px;
    position: relative;
}
#global-lb-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    padding-bottom: 9px;
    border-bottom: 1px solid #0a1428;
}
.lb-title {
    font-size: 10px;
    letter-spacing: 3px;
    color: #4488cc;
    text-transform: uppercase;
    flex: 1;
}
.lb-live {
    font-size: 8px;
    letter-spacing: 2px;
    color: #44cc88;
    border: 1px solid #1a4a30;
    border-radius: 3px;
    padding: 2px 6px;
    animation: lbLivePulse 2s ease-in-out infinite;
}
@keyframes lbLivePulse {
    0%,100% { opacity: 1; }
    50%      { opacity: 0.45; }
}
.lb-refresh-btn {
    background: none;
    border: none;
    color: #1e3a6e;
    font-size: 16px;
    cursor: pointer;
    line-height: 1;
    padding: 0 2px;
    transition: color 0.18s, transform 0.18s;
}
.lb-refresh-btn:hover { color: #4488cc; }
.lb-refresh-btn.spinning {
    animation: lbSpin 0.6s linear infinite;
    color: #4488cc;
}
@keyframes lbSpin { to { transform: rotate(360deg); } }

.lb-loading, .lb-empty {
    text-align: center;
    color: #1e3050;
    font-size: 12px;
    letter-spacing: 1px;
    padding: 14px 0;
}
.lb-row {
    display: flex;
    align-items: center;
    padding: 6px 0;
    border-bottom: 1px solid #080e1a;
    gap: 10px;
    font-size: 13px;
}
.lb-row:last-child { border-bottom: none; }
.lb-row.lb-top .lb-name { color: #cce8ff; }
.lb-row.lb-me { background: rgba(68,136,204,0.08); border-radius: 4px; }
.lb-row.lb-me .lb-name { color: #66aaee; }
.lb-row.lb-my-rank { margin-top: 6px; border-top: 1px dashed #0a1a30; padding-top: 8px; }
.lb-period {
    font-size: 8px;
    letter-spacing: 2px;
    color: #2a5a8a;
    border: 1px solid #0a2040;
    border-radius: 3px;
    padding: 2px 5px;
    margin-right: 4px;
}
.lb-rank {
    width: 30px;
    font-size: 14px;
    text-align: center;
    flex-shrink: 0;
    color: #2a4060;
}
.lb-name {
    flex: 1;
    color: #6688aa;
    letter-spacing: 1px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.lb-score {
    color: #ffee88;
    font-weight: bold;
    letter-spacing: 1px;
    flex-shrink: 0;
}

/* ── Send address input ── */
.wallet-addr-input {
    width: 100%;
    background: #050912;
    border: 1px solid #1e3a2e;
    border-radius: 5px;
    color: #4488aa;
    font-family: 'Courier New', monospace;
    font-size: 10px;
    padding: 7px 10px;
    outline: none;
    letter-spacing: 0.5px;
    transition: border-color 0.18s;
    margin-bottom: 2px;
}
.wallet-addr-input:focus { border-color: #44aa66; }
.wallet-addr-input::placeholder { color: #1e3a2e; }

/* ── Receive hint ── */
.wallet-receive-hint {
    font-size: 11px;
    color: #2a4060;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

/* ── Wallet tab address display ── */
.wallet-tab-addr {
    font-size: 10px;
    color: #2a4466;
    letter-spacing: 1px;
    margin-bottom: 8px;
    text-align: center;
    word-break: break-all;
}
