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

.back-btn { font-size: 22px; text-decoration: none; color: var(--text); flex-shrink: 0; }

.bottom-nav { position: fixed; bottom: 0; left: 0; right: 0; background: var(--surface); border-top: 1px solid var(--border); display: flex; }

.btn.secondary { background: var(--surface2); border: 1px solid var(--border); }

.btn:active { transform: scale(0.98); }

.btn:disabled { opacity: 0.6; cursor: not-allowed; }

.btn:hover { background: var(--green-light); }

.exact-col { font-size: 13px; font-weight: 700; color: var(--gold); text-align: center; }

.field input { width: 100%; background: var(--surface2); border: 1px solid var(--border); border-radius: 10px; padding: 12px 14px; font-size: 15px; color: var(--text); outline: none; }

.field input:focus { border-color: var(--green-light); }

.field label { display: block; font-size: 12px; color: var(--text-muted); margin-bottom: 5px; text-transform: uppercase; letter-spacing: 0.04em; }

.hero-brand span { color: var(--gold); }

.hero-brand { font-size: 24px; font-weight: 800; letter-spacing: -0.5px; color: var(--text); margin-bottom: 8px; line-height: 1; }

.hero-tournament { font-size: 16px; font-weight: 600; color: var(--text); margin-bottom: 6px; }

.loading { text-align: center; padding: 3rem; color: var(--text-muted); }

.match-counter { text-align: center; font-size: 14px; color: var(--text-muted); font-weight: 500; line-height: 1; }

.me-tag { font-size: 11px; color: var(--text-muted); font-weight: 400; }

.move { font-size: 13px; font-weight: 600; text-align: center; }

.move.down { color: #e05c5c; }

.move.same { color: var(--text-muted); }

.move.up   { color: #5dd690; }

.msg { font-size: 14px; margin-top: 10px; min-height: 18px; text-align: center; }

.msg.err { color: var(--error); }

.msg.ok  { color: var(--green-light); }

.nav-btn { flex: 1; padding: 14px 0 18px; text-align: center; font-size: 14px; color: var(--text-muted); text-decoration: none; border: none; background: none; cursor: pointer; position: relative; }

.nav-btn.active { color: var(--green-light); }

.nav-dot { position: absolute; top: 10px; right: calc(50% - 14px); width: 8px; height: 8px; background: #e05c5c; border-radius: 50%; display: none; }

.nav-dot.show { display: block; }

.nav-icon { font-size: 24px; display: block; margin-bottom: 2px; }

.player-chevron { color: var(--text-muted); font-size: 13px; opacity: 0.9; text-align: right; }

.player-name { font-size: 13px; font-weight: 500; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.player-row {
    display: grid; grid-template-columns: 16px 32px 1fr 18px 120px 12px;
    align-items: center; gap: 3px;
    margin: 0 12px 6px;
    background: var(--surface); border: 1px solid var(--border);
    border-radius: 12px; padding: 4px 10px;
    cursor: pointer;
  }

.player-row.me { border-color: var(--green-light); }

.popup h2 { font-size: 19px; font-weight: 700; margin-bottom: 8px; text-align: center; }

.popup p { font-size: 14px; color: var(--text-muted); text-align: center; margin-bottom: 20px; line-height: 1.5; }

.popup { background: var(--surface); border: 1px solid var(--border); border-radius: 20px; padding: 24px 20px; width: 100%; max-width: 500px; margin: 0 auto; }

.popup-btn {
    width: 100%; padding: 14px; border-radius: 12px; font-size: 15px; font-weight: 600;
    cursor: pointer; margin-bottom: 10px; border: none; transition: background 0.15s;
  }

.popup-btn.primary { background: var(--green); color: var(--text); }

.popup-btn.primary:hover { background: var(--green-light); }

.popup-btn.secondary { background: var(--surface2); color: var(--text); border: 1px solid var(--border); }

.popup-btn.skip { background: none; color: var(--text-muted); font-size: 14px; margin-bottom: 0; }

.popup-icon { font-size: 36px; margin-bottom: 10px; text-align: center; }

.pts-col { text-align: right; cursor: pointer; line-height: 2.0; }

.pts-latest { font-size: 13px; font-weight: 600; color: var(--gold); }

.pts-total  { font-size: 13px; font-weight: 600; color: var(--gold); }

.rank { font-size: 13px; font-weight: 700; color: var(--text-muted); text-align: center; }

.rank.bronze { color: #cd7f32; }

.rank.gold   { color: var(--gold); }

.rank.silver { color: #aaa; }

.section { padding: 16px; }

.section-title { font-size: 14px; font-weight: 600; color: var(--gold); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 12px; }

.splash-name span { color: var(--gold); }

.splash-name { font-size: 50px; font-weight: 800; letter-spacing: -1px; color: var(--text); }

.splash-slogan { font-size: 15px; color: var(--text-muted); margin-top: 20px; }

.splash.hide { opacity: 0; pointer-events: none; }

.table-header .h-exact { text-align: center; }

.table-header .h-move { text-align: center; }

.table-header .h-pts { text-align: right; }

.table-header .h-rank { text-align: center; }

.toast { position: fixed; bottom: 90px; left: 50%; transform: translateX(-50%); background: var(--surface2); color: var(--text); font-size: 13px; padding: 10px 18px; border-radius: 20px; border: 1px solid var(--border); z-index: 100; opacity: 0; transition: opacity 0.3s; pointer-events: none; white-space: nowrap; }

.toast.show { opacity: 1; }

.topbar h1 { font-size: 17px; font-weight: 600; position: absolute; left: 50%; transform: translateX(-50%); }

.topbar { background: var(--surface); border-bottom: 1px solid var(--border); padding: 14px 16px; display: flex; align-items: center; position: sticky; top: 0; z-index: 10; }

/* Bottom nav */
  .bottom-nav { position: fixed; bottom: 0; left: 0; right: 0; background: var(--surface); border-top: 1px solid var(--border); display: flex; }

/* Felter */
  .field { margin-bottom: 12px; }

body { background: var(--bg); color: var(--text); font-family: 'Inter', system-ui, sans-serif; padding-bottom: 80px; }
