@charset "UTF-8";

/* 2026-10 visual refresh: airy finance workspace, floating forest rail,
   muted glass surfaces and a single lime signal color. */
:root{
  --ink:#182338;
  --muted:#67748c;
  --line:rgba(28,40,64,.10);
  --surface:#f2f5fb;
  --accent:#3b5bf6;
  --accent-deep:#1c2c52;
  --lime:#d9f86f;
  --lime-deep:#c7eb54;
  --danger:#b23f39;
  --warn:#a96a15;
  --radius:22px;
  --panel:rgba(255,255,255,.80);
  --panel-strong:rgba(255,255,255,.94);
  --hairline:rgba(255,255,255,.86);
  --shadow:0 18px 48px rgba(0,0,0,.08);
  color-scheme:light;
}

html{min-height:100%;background:#eef3fb}
body{
  min-height:100vh;
  background:
    radial-gradient(900px 560px at 3% -2%,rgba(132,190,255,.68),transparent 64%),
    radial-gradient(760px 540px at 96% 0%,rgba(184,165,255,.58),transparent 60%),
    radial-gradient(720px 520px at 74% 88%,rgba(219,247,125,.20),transparent 62%),
    linear-gradient(135deg,#f8faff 0%,#eef3fb 50%,#e9eff9 100%);
  background-attachment:fixed;
  color:var(--ink);
  font-family:"Segoe UI Variable Text","Segoe UI","Microsoft YaHei",sans-serif;
  font-size:14.5px;
  -webkit-font-smoothing:antialiased;
}
body::before{
  content:"";
  position:fixed;
  inset:0;
  z-index:-1;
  pointer-events:none;
  background:linear-gradient(180deg,rgba(255,255,255,.16),transparent 30%);
}
*::-webkit-scrollbar{width:10px;height:10px}
*::-webkit-scrollbar-thumb{background:rgba(28,40,64,.20);border:3px solid transparent;background-clip:content-box;border-radius:999px}
*::-webkit-scrollbar-thumb:hover{background:rgba(28,40,64,.32);border:3px solid transparent;background-clip:content-box}
::selection{background:var(--lime);color:#141b2d}
button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible,summary:focus-visible{outline:2px solid #6f88ff;outline-offset:3px}

h1{font-size:34px;line-height:1.16;font-weight:620;letter-spacing:-.035em}
h2{font-size:18px;font-weight:620;letter-spacing:-.018em}
h3{font-size:15px;font-weight:600}
small{font-size:12.5px}
.muted{color:var(--muted)}

/* ---------- floating navigation ---------- */
.sidebar{
  width:232px;
  top:18px;
  bottom:18px;
  left:18px;
  padding:27px 16px 16px;
  border:1px solid rgba(255,255,255,.10);
  border-radius:30px;
  background:linear-gradient(160deg,#0e1728 0%,#172641 54%,#0a1220 100%);
  box-shadow:0 30px 80px rgba(0,0,0,.26);
  overflow:hidden;
}
.sidebar::before{
  content:"";
  position:absolute;
  width:230px;
  height:230px;
  right:-108px;
  bottom:76px;
  border-radius:50%;
  background:radial-gradient(circle,rgba(89,131,255,.22),transparent 66%);
  pointer-events:none;
}
.sidebar::after{
  content:"";
  position:absolute;
  left:26px;
  right:26px;
  top:98px;
  height:1px;
  background:linear-gradient(90deg,transparent,rgba(220,230,255,.13),transparent);
  pointer-events:none;
}
.brand{
  position:relative;
  z-index:1;
  margin:0 10px 23px;
  padding:0;
  color:#f2f5ff;
}
.brand-logo-img{
  width:142px;
  height:auto;
  filter:none;
  opacity:1;
  mix-blend-mode:normal;
}
.brand span{
  color:rgba(220,229,255,.54);
  font-size:11px;
  letter-spacing:.22em;
  margin-top:7px;
}
nav{
  position:relative;
  z-index:1;
  gap:6px;
  margin-top:2px;
}
nav button{
  display:flex;
  align-items:center;
  gap:11px;
  width:100%;
  min-height:47px;
  padding:0 14px;
  border:0;
  border-radius:15px;
  background:transparent;
  color:rgba(224,232,255,.66);
  font-size:13.5px;
  font-weight:520;
  text-align:left;
  transition:background .2s ease,color .2s ease,transform .2s ease;
}
nav button:hover{background:rgba(255,255,255,.07);color:#f7f9ff}
nav button.active{
  background:var(--lime);
  color:#151d2e;
  font-weight:650;
  box-shadow:0 10px 22px rgba(0,0,0,.18);
}
nav button.active:hover{background:var(--lime)}
.nav-icon{
  display:grid;
  place-items:center;
  width:20px;
  height:20px;
  flex:0 0 20px;
  opacity:.82;
}
.nav-icon svg{width:19px;height:19px}
nav button.active .nav-icon{opacity:1}
.nav-label{min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.sidebar-foot{
  position:relative;
  z-index:1;
  margin-top:auto;
  padding:16px 4px 0;
  border:0;
  border-top:1px solid rgba(255,255,255,.09);
  border-radius:0;
  background:transparent;
  display:flex;
  align-items:center;
  gap:8px;
  flex-wrap:wrap;
}
.sidebar-user{
  display:flex;
  align-items:center;
  gap:8px;
  min-width:0;
  max-width:100%;
  color:#f2f5ff;
  font-size:13px;
  font-weight:550;
  overflow:hidden;
  text-overflow:ellipsis;
}
.sidebar-user::before{
  content:"";
  width:7px;
  height:7px;
  flex:0 0 7px;
  border-radius:50%;
  background:var(--lime);
  box-shadow:none;
}
.sidebar-logout{
  margin-left:auto;
  padding:3px 2px;
  color:rgba(220,229,255,.54);
  font-size:12px;
}
.sidebar-logout:hover{color:var(--lime);text-decoration:none}
.workspace{margin-left:268px;min-height:100vh}
main{max-width:1520px;padding:34px 36px 58px;margin:0 auto}

/* ---------- page headings ---------- */
.page-heading{
  align-items:flex-end;
  gap:20px;
  margin-bottom:25px;
}
.page-heading h1{
  display:flex;
  align-items:center;
  gap:14px;
  font-size:34px;
  font-weight:620;
  letter-spacing:-.035em;
}
.page-heading h1::before{
  content:"";
  width:10px;
  height:10px;
  flex:0 0 10px;
  border-radius:50%;
  background:var(--lime-deep);
  box-shadow:none;
}
.page-actions{display:flex;align-items:center;gap:10px}
.section-meta{
  align-items:center;
  gap:8px;
  margin-bottom:14px;
  padding:0 3px;
  color:var(--muted);
  font-size:12.5px;
}
.section-meta>span:first-child{
  display:inline-flex;
  align-items:center;
  gap:8px;
  color:#48556b;
  font-weight:550;
}
.section-meta>span:first-child::before{
  content:"";
  width:6px;
  height:6px;
  border-radius:50%;
  background:#5377ff;
  box-shadow:none;
}
.meta-separator{color:#8c99ab}

/* ---------- controls ---------- */
.button{
  min-height:42px;
  padding:9px 17px;
  border:1px solid rgba(28,40,64,.13);
  border-radius:999px;
  background:rgba(255,255,255,.74);
  color:var(--ink);
  font-size:13.5px;
  font-weight:550;
  box-shadow:0 5px 16px rgba(0,0,0,.05);
  backdrop-filter:blur(10px);
  transition:background .18s ease,border-color .18s ease,transform .18s ease,box-shadow .18s ease;
}
.button:hover:not(:disabled){background:#fff;border-color:rgba(28,40,64,.22);transform:translateY(-1px);box-shadow:0 10px 24px rgba(0,0,0,.08)}
.button.primary{
  background:#2f55e8;
  border-color:#2f55e8;
  color:#f7f9ff;
  box-shadow:0 12px 24px rgba(0,0,0,.16);
}
.button.primary:hover:not(:disabled){background:#2447c8;border-color:#2447c8}
.button svg{width:16px;height:16px}
.text-button{color:var(--accent);font-size:13.5px;font-weight:550}
.text-button:hover{text-decoration:none;color:#182338;background:rgba(217,248,111,.28)}
input:not([type=checkbox]),select{
  min-height:44px;
  padding:9px 13px;
  border:1px solid rgba(28,40,64,.12);
  border-radius:14px;
  background:rgba(255,255,255,.86);
  color:var(--ink);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.55);
  transition:border-color .18s ease,box-shadow .18s ease,background .18s ease;
}
input:not([type=checkbox]):focus,select:focus{
  outline:none;
  border-color:#718bff;
  background:#fff;
  box-shadow:0 0 0 4px rgba(89,131,255,.16);
}
input::placeholder{color:#64718a;opacity:1}
select{appearance:auto}
.search-input{width:245px}

/* ---------- overview totals ---------- */
.totals-strip{
  grid-template-columns:minmax(0,1.55fr) repeat(2,minmax(0,1fr));
  gap:14px;
  border:0;
  padding:0;
  margin-bottom:25px;
}
.totals-strip>div{
  position:relative;
  min-width:0;
  padding:24px 26px;
  border:1px solid var(--hairline);
  border-left:1px solid var(--hairline);
  border-radius:24px;
  background:var(--panel);
  box-shadow:var(--shadow);
  overflow:hidden;
}
.totals-strip>div:first-child{padding-left:26px;border-left:1px solid var(--hairline)}
.totals-strip>div>span{color:#5c6a80;font-size:12px;font-weight:550;letter-spacing:.01em}
.totals-strip strong{
  margin-top:9px;
  color:var(--ink);
  font-family:"Bahnschrift","Segoe UI Variable Display","Segoe UI",sans-serif;
  font-size:36px;
  line-height:1.14;
  font-weight:500;
  letter-spacing:-.035em;
}
.totals-strip strong small{font-family:"Segoe UI","Microsoft YaHei",sans-serif;color:var(--muted);font-size:13px;font-weight:400;letter-spacing:0;margin-left:6px}
.totals-strip p{margin-top:7px;color:var(--muted);font-size:12.5px}
.totals-strip .total-main{
  color:#f5f8ff;
  background:linear-gradient(145deg,#111a2e 0%,#192845 66%,#273a62 100%);
  border-color:rgba(255,255,255,.08);
  box-shadow:0 24px 52px rgba(0,0,0,.24);
}
.total-main::after{
  content:"";
  position:absolute;
  width:210px;
  height:210px;
  right:-84px;
  top:-94px;
  border-radius:50%;
  background:radial-gradient(circle,rgba(89,131,255,.30),transparent 68%);
  pointer-events:none;
}
.total-main>span{color:rgba(237,243,255,.62)}
.total-main strong{color:#f7f9ff;font-size:44px}
.total-main strong small{color:rgba(237,243,255,.56)}
.total-main p{color:rgba(228,238,255,.60)}
.total-main .warning-text{color:#e8f49d}
.total-main em{
  display:inline-block;
  margin-left:8px;
  padding:0;
  border-radius:0;
  background:transparent;
  color:var(--lime);
  font-size:12px;
  font-style:normal;
  font-weight:600;
}
.finance-totals{grid-template-columns:repeat(2,minmax(0,1fr))}
.finance-totals-single{grid-template-columns:minmax(0,560px);max-width:560px}
.finance-totals-single>div{background:linear-gradient(135deg,rgba(255,255,255,.94),rgba(248,252,246,.72))}
.finance-totals-single strong{font-size:40px}
.finance-totals strong{font-size:32px}

/* ---------- game cards ---------- */
.section-toolbar{gap:16px;margin-bottom:16px}
.section-toolbar h2{font-size:19px;letter-spacing:-.02em}
.overview-tools{gap:9px}
.overview-name-toggle{min-height:42px}
.games-section{margin-top:2px}
.games-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}
.tone-0{--game-color:#3350c8;--game-tint:#e8edff;--game-wash:#f5f7ff}
.tone-1{--game-color:#2b6c91;--game-tint:#e4f3fb;--game-wash:#f3faff}
.tone-2{--game-color:#8a6428;--game-tint:#f7edd9;--game-wash:#fcf8ef}
.tone-3{--game-color:#6a4fb0;--game-tint:#efe9ff;--game-wash:#f8f5ff}
.tone-4{--game-color:#ad564b;--game-tint:#fbe9e3;--game-wash:#fdf6f3}
.game-card{
  min-height:232px;
  border:1px solid var(--hairline);
  border-radius:23px;
  background:rgba(255,255,255,.79);
  box-shadow:0 12px 32px rgba(0,0,0,.06);
  transition:transform .22s ease,border-color .22s ease,box-shadow .22s ease;
}
.game-card:hover{
  border-color:rgba(80,111,255,.55);
  transform:translateY(-4px);
  box-shadow:0 24px 46px rgba(0,0,0,.11);
}
.game-card-title{
  gap:12px;
  padding:18px 18px 15px;
  border-bottom:0;
  background:linear-gradient(135deg,var(--game-wash),rgba(255,255,255,.30));
}
.game-card-title h3{font-size:16px;line-height:1.45;margin-bottom:2px}
.game-mark{
  flex-basis:42px;
  width:42px;
  height:42px;
  border:1px solid rgba(255,255,255,.72);
  border-radius:11px;
  background:var(--game-tint);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.7);
}
.connection-text{color:#6f7f97;font-size:12px}
.game-card-money{padding:10px 18px 15px}
.game-card-money>span{color:#7d8aa0;font-size:12px;margin-bottom:6px}
.game-income{
  color:var(--ink);
  font-family:"Bahnschrift","Segoe UI Variable Display","Segoe UI",sans-serif;
  font-size:30px;
  font-weight:500;
  letter-spacing:-.03em;
}
.game-income small{color:var(--muted);font-size:12px}
.game-card-bottom{
  padding:11px 18px;
  border-top:1px solid rgba(28,40,64,.07);
  background:rgba(255,255,255,.28);
  color:#7b89a1;
  font-size:12px;
}
.detail-link{color:var(--game-color);font-size:12px;font-weight:600}
.page-note{margin-top:20px;color:#6f7f97;font-size:12px}

/* ---------- finance filter deck ---------- */
.finance-toolbar{
  align-items:flex-end;
  gap:16px;
  margin-bottom:20px;
  padding:0 2px 16px;
  border:0;
  border-bottom:1px solid rgba(28,40,64,.10);
  border-radius:0;
  background:transparent;
  box-shadow:none;
}
.finance-toolbar>label,.field-block,.min-amount-field{color:#64718a;font-size:12.5px}
.field-label{color:#64718a;font-size:12.5px;margin-bottom:7px}
.app-picker-input{border-radius:13px;background:#fff}
.app-picker-list{
  top:calc(100% + 8px);
  border:1px solid rgba(28,40,64,.12);
  border-radius:16px;
  background:#fff;
  box-shadow:0 22px 50px rgba(0,0,0,.16);
  padding:6px;
}
.app-picker-option{border-radius:10px;padding:10px 11px;font-size:13px}
.app-picker-option:hover,.app-picker-option.selected{background:rgba(89,131,255,.16);color:#1a2b52}
.date-shortcuts{
  gap:3px;
  padding:4px;
  border:1px solid rgba(28,40,64,.06);
  border-radius:14px;
  background:rgba(239,245,238,.76);
}
.date-shortcuts button{
  min-height:34px;
  padding:7px 12px;
  border-radius:10px;
  color:#5f6d85;
  font-size:12.5px;
  font-weight:520;
}
.date-shortcuts button:hover{background:rgba(255,255,255,.64);color:#26395f}
.date-shortcuts button.selected{
  background:var(--lime);
  color:#17223a;
  font-weight:650;
  box-shadow:0 4px 10px rgba(28,40,64,.10);
}
.date-inputs input{width:142px}
.min-amount-field{width:136px}
.finance-name-toggle{min-height:44px;border-radius:14px}

/* ---------- records ---------- */
.income-records{
  padding:18px;
  border:1px solid var(--hairline);
  border-radius:23px;
  background:rgba(255,255,255,.72);
  box-shadow:0 14px 38px rgba(0,0,0,.06);
}
.amount-legend{padding:0 4px;margin-bottom:13px;color:#73819a;font-size:12px}
.amount-swatch{border-radius:4px}
.table-container{
  border:1px solid rgba(28,40,64,.08);
  border-radius:16px;
  background:#fff;
  overflow:auto;
}
.income-records .table-container{border:0;border-radius:0;background:transparent}
table{font-size:13px}
th{
  padding:13px 16px;
  border-bottom:1px solid rgba(28,40,64,.08);
  background:#f4f6fd;
  color:#64718a;
  font-size:12px;
  font-weight:600;
  letter-spacing:.02em;
}
td{padding:15px 16px;border-bottom:1px solid rgba(28,40,64,.065);color:#33415a}
tbody tr:last-child td{border-bottom:0}
tbody tr:hover{background:#f7f9ff}
.records-table .record-time{color:#5b6980}
.record-app{font-weight:550}
.record-user{color:#707d94}
.record-value{border-radius:9px;font-weight:600}
.amount-tier-green{--amount-bg:#e8eeff;--amount-ink:#3554c4}
.amount-tier-blue{--amount-bg:#f0eaff;--amount-ink:#6947a8}
.amount-tier-white{--amount-bg:#f4f6fb;--amount-ink:#33415a}
.table-footer{padding-top:15px;color:#73819a;font-size:12px}
.query-time{color:#7a88a0;font-size:12px}
.record-notice{border-radius:13px;background:#fbf7e9;color:#72551d}
.report-heading{margin-bottom:12px}
.record-heading{font-size:16px;letter-spacing:-.01em}

/* ---------- source management ---------- */
.source-toolbar{margin-bottom:16px}
.source-tools .search-input{width:240px}
.apps-container{background:rgba(255,255,255,.78)}
.apps-table{font-size:13px}
.app-id{color:#748098}
.inline-success,.inline-error{border-radius:14px;box-shadow:0 8px 20px rgba(0,0,0,.04)}
.inline-success{border-color:rgba(153,190,93,.34);background:rgba(240,249,224,.86);color:#3c5d26}
.inline-error{border-color:rgba(190,102,90,.28);background:rgba(255,242,239,.9)}
.empty-state{
  padding:56px 26px;
  border:1px solid var(--hairline);
  border-radius:23px;
  background:rgba(255,255,255,.70);
  box-shadow:0 12px 34px rgba(0,0,0,.05);
  color:#73819a;
}
.empty-state h3{font-size:18px;color:var(--ink)}
.empty-state.error{background:rgba(255,245,242,.78)}
.empty-state .button{margin-top:18px}

/* ---------- drawer, dialogs and login ---------- */
.overlay{background:rgba(16,32,24,.36);backdrop-filter:blur(8px)}
.income-drawer{
  width:min(100%,1040px);
  border-radius:26px 0 0 26px;
  background:linear-gradient(180deg,#f8faff,#eff3fc);
  box-shadow:-30px 0 80px rgba(0,0,0,.18);
}
.drawer-header{
  padding:22px 30px;
  background:rgba(255,255,255,.68);
  border-bottom:1px solid rgba(28,40,64,.08);
  backdrop-filter:blur(16px);
}
.drawer-game h2{font-size:22px;letter-spacing:-.025em}
.drawer-game p{color:#748098;font-size:12.5px}
.close-button{
  width:38px;
  height:38px;
  border-radius:12px;
  color:#64718a;
}
.close-button:hover{background:rgba(217,248,111,.32);color:#182338}
.drawer-body{padding:24px 30px 36px}
.detail-range{color:#6d7a91;font-size:12.5px}
.detail-range span{font-size:12px;color:#7e8ca3}
.drawer-body .finance-totals{gap:0;border:0;padding:0;background:transparent}
.drawer-body .finance-totals>div{border:0;border-left:1px solid rgba(28,40,64,.10);border-radius:0;background:transparent;box-shadow:none;padding:0 18px}
.drawer-body .finance-totals>div:first-child{border-left:0;padding-left:0}
.drawer-body .totals-strip strong{font-size:30px}
.drawer-body .income-records{padding:0;border:0;border-radius:0;background:transparent;box-shadow:none}
.record-tabs button{color:#79869e;font-size:14px}
.record-tabs button.active{color:#233a68;border-bottom-color:#b9d453}
.dialog{
  width:500px;
  border:1px solid var(--hairline);
  border-radius:26px;
  background:rgba(255,255,255,.94);
  box-shadow:0 28px 90px rgba(0,0,0,.22);
  backdrop-filter:blur(18px);
}
.dialog-heading h2{font-size:21px;letter-spacing:-.02em}
.form-field{color:#5f6c83;font-size:13px}
.form-field>input,.form-field>select{border-radius:13px;min-height:44px}
.advanced-fields{border-top-color:rgba(28,40,64,.08)}
.dialog-actions{border-top-color:rgba(28,40,64,.08)}
.login-screen{
  background:
    radial-gradient(800px 500px at 12% 0%,rgba(132,190,255,.66),transparent 64%),
    radial-gradient(760px 540px at 90% 100%,rgba(183,164,255,.56),transparent 60%),
    linear-gradient(135deg,#f8faff,#e9efff 70%,#f2edff);
}
.login-card{
  border:1px solid var(--hairline);
  border-radius:28px;
  background:rgba(255,255,255,.86);
  box-shadow:0 30px 80px rgba(0,0,0,.14);
  backdrop-filter:blur(18px);
}
.login-logo{filter:none}
.login-brand span{color:#64718a}
.login-button{
  min-height:48px;
  border:0;
  border-radius:14px;
  background:#2f55e8;
  color:#f7f9ff;
  box-shadow:0 12px 24px rgba(0,0,0,.16);
}
.login-button:hover:not(:disabled){background:#2447c8;transform:translateY(-1px)}

/* ---------- responsive ---------- */
@media(max-width:1240px){
  .sidebar{width:214px}
  .workspace{margin-left:250px}
  main{padding:30px 28px 50px}
  .games-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
  .totals-strip strong{font-size:32px}
  .total-main strong{font-size:39px}
}
@media(max-width:1080px){
  .sidebar{width:206px;left:14px;top:14px;bottom:14px}
  .workspace{margin-left:234px}
  main{padding:26px 24px 46px}
  nav button{padding:0 12px}
  .games-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .finance-toolbar{gap:12px}
  .date-shortcuts{flex-basis:100%}
}
@media(max-width:900px){
  .sidebar{display:none}
  .workspace{margin-left:0;padding-bottom:96px}
  .mobile-header{
    display:flex;
    position:sticky;
    top:0;
    z-index:30;
    align-items:center;
    justify-content:space-between;
    height:58px;
    padding:0 18px;
    border-bottom:1px solid rgba(28,40,64,.07);
    background:rgba(249,251,255,.84);
    box-shadow:0 1px 0 rgba(255,255,255,.7),0 8px 24px rgba(0,0,0,.04);
    backdrop-filter:blur(18px);
  }
  .mobile-brand img{height:21px;mix-blend-mode:multiply}
  .mobile-account{color:#626f87;font-size:12px}
  .mobile-logout{color:var(--accent);font-size:12px}
  .tabbar{
    display:grid;
    grid-template-columns:repeat(4,1fr);
    position:fixed;
    left:12px;
    right:12px;
    bottom:12px;
    z-index:40;
    gap:4px;
    padding:7px 7px calc(7px + env(safe-area-inset-bottom));
    border:1px solid rgba(255,255,255,.12);
    border-radius:22px;
    background:rgba(10,18,34,.96);
    box-shadow:0 20px 46px rgba(0,0,0,.30);
    backdrop-filter:blur(18px);
  }
  .tabbar button{
    display:flex;
    flex-direction:column;
    align-items:center;
    gap:3px;
    min-height:52px;
    padding:7px 0 5px;
    border:0;
    border-radius:15px;
    background:transparent;
    color:rgba(226,234,255,.56);
    font-size:11px;
    line-height:1.2;
  }
  .tabbar button svg{width:21px;height:21px}
  .tabbar button.active{
    background:var(--lime);
    color:#151d2e;
    font-weight:650;
    box-shadow:0 8px 18px rgba(0,0,0,.22);
  }
  main{padding:23px 18px 30px;max-width:none}
  .page-heading{align-items:flex-start;flex-direction:column;gap:14px;margin-bottom:20px}
  .page-heading h1{font-size:29px;gap:11px}
  .page-actions{width:100%;justify-content:flex-start}
  .section-meta{font-size:12px;margin-bottom:12px}
  .totals-strip{grid-template-columns:1fr 1fr;gap:10px;margin-bottom:18px}
  .totals-strip .total-main{grid-column:1/-1}
  .totals-strip>div{padding:18px 18px;border-radius:20px}
  .totals-strip>div:first-child{padding-left:18px}
  .totals-strip strong{font-size:28px}
  .totals-strip .total-main strong{font-size:36px}
  .finance-totals,.finance-totals-single{grid-template-columns:1fr;max-width:none}
  .finance-totals>div,.finance-totals>div:last-child{border-radius:20px!important}
  .finance-totals>div{background:rgba(255,255,255,.82)}
  .games-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
  .game-card{border-radius:20px}
  .game-card-title{padding:15px 15px 12px}
  .game-card-money{padding:8px 15px 13px}
  .game-card-bottom{padding:10px 15px}
  .finance-toolbar{display:block;padding:0 2px 13px;border-radius:0;border-bottom:1px solid rgba(28,40,64,.10)}
  .finance-toolbar .field-block{display:block;margin-bottom:12px}
  .finance-toolbar>label{display:block;margin-bottom:12px}
  .date-filter{margin-bottom:10px}
  .date-inputs input{flex:1;width:auto;min-width:0}
  .date-shortcuts{display:grid;grid-template-columns:repeat(5,1fr);gap:3px;width:100%;flex-basis:auto}
  .date-shortcuts button{min-height:36px;padding:0 4px;font-size:12px}
  .min-amount-row{align-items:stretch;gap:8px;margin-top:2px}
  .min-amount-field{flex:1;width:auto}
  .finance-name-toggle{min-height:44px}
  .income-records{padding:12px;border-radius:20px}
  .table-container{border-radius:14px}
  .amount-legend{gap:6px 12px;font-size:12px;padding:0 2px}
  th,td{padding:11px 12px}
  .table-footer{padding:12px 4px 0;font-size:12px}
  .report-heading{flex-direction:column;align-items:flex-start;gap:5px}
  .record-notice{font-size:12.5px}
  .source-toolbar{flex-wrap:wrap;gap:10px}
  .source-tools{width:100%}
  .source-tools .search-input{flex:1;width:auto}
  .source-tools .button{min-height:40px;padding:7px 13px;font-size:12.5px}
  .empty-state{padding:44px 22px;border-radius:20px}
  .overlay{align-items:flex-end;padding:0}
  .dialog{width:100%;max-height:92dvh;border-radius:24px 24px 0 0;padding:22px 18px calc(18px + env(safe-area-inset-bottom))}
  .income-drawer{width:100%;border-radius:0}
  .drawer-header{padding:16px 17px}
  .drawer-body{padding:16px 16px 28px}
}
@media(max-width:620px){
  main{padding:19px 15px 30px}
  .page-heading h1{font-size:27px}
  .page-heading h1::before{width:8px;height:8px;flex-basis:8px;box-shadow:none}
  .page-actions .button{min-height:40px;padding:8px 14px;font-size:12.5px}
  .totals-strip strong{font-size:25px}
  .totals-strip .total-main strong,.finance-totals-single strong{font-size:32px}
  .totals-strip>div{padding:16px 15px}
  .totals-strip>div:first-child{padding-left:15px}
  .totals-strip p{font-size:12px}
  .games-grid{grid-template-columns:1fr}
  .game-card{min-height:0}
  .game-income{font-size:28px}
  .finance-toolbar{padding:0 2px 12px}
  .date-inputs input{font-size:15px;min-height:44px}
  .app-picker-input{font-size:16px}
  .min-amount-field input{font-size:16px}
  .income-records{padding:10px}
  .income-records .table-container{border:0;border-radius:0;background:transparent}
  .records-table{min-width:620px}
  .records-table .numeric{background:#fff}
  .table-footer{flex-wrap:wrap;gap:8px}
  .table-footer>div{margin-left:0;width:100%;justify-content:flex-end}
  .login-card{padding:28px 20px 24px}
  .login-button{color:#182338}
}
@media(prefers-reduced-motion:reduce){
  .game-card,.button{transition:none!important}
}









/* ---------- 广告金余额（广告变现数据开放API） ---------- */
.adfund-strip{display:flex;align-items:center;gap:28px;flex-wrap:wrap;padding:16px 20px;margin-bottom:18px;background:var(--panel-strong);border:1px solid var(--line);border-radius:var(--radius);box-shadow:0 10px 30px rgba(24,35,56,.05)}
.adfund-strip>div{display:flex;flex-direction:column;gap:3px;min-width:0}
.adfund-strip span{font-size:12px;color:var(--muted);letter-spacing:.02em}
.adfund-strip strong{font-size:22px;font-weight:650;color:var(--ink);font-variant-numeric:tabular-nums;letter-spacing:-.01em}
.adfund-strip strong small{font-size:12px;font-weight:500;color:var(--muted);margin-left:3px}
.adfund-note{margin:0;flex:1;min-width:200px;font-size:12px;line-height:1.6;color:var(--muted)}
.adfund-strip .button{margin-left:auto}
.ad-fund-cell{font-variant-numeric:tabular-nums;white-space:nowrap}
.ad-fund-cell strong{font-weight:600;color:var(--ink)}
.ad-fund-cell small{font-size:11px;color:var(--muted);margin-left:2px}
.ad-fund-error{font-size:12px;color:var(--danger)}

@media(max-width:700px){
  .adfund-strip{gap:14px;padding:14px 16px;align-items:flex-start}
  .adfund-strip strong{font-size:19px}
  .adfund-note{display:block;flex-basis:100%;min-width:0}
  .adfund-strip .button{margin-left:0;width:100%}
  .apps-table td.ad-fund-cell{font-size:13px;padding-top:4px;white-space:normal}
  .apps-table td.ad-fund-cell::before{content:"广告金 ";color:var(--muted);font-size:12.5px}
}
/* ---------- 广告指标（前一日的 PV / 分成前后收入） ---------- */
.adreport-toolbar{align-items:flex-start;gap:12px;flex-wrap:wrap}
.adreport-filters{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.adreport-date{display:inline-flex;align-items:center;gap:8px;font-size:13px;color:var(--muted);white-space:nowrap}
.adreport-date input{min-height:38px;padding:6px 10px;border:1px solid var(--line);border-radius:10px;background:#fff;font-size:13px;color:var(--ink);font-variant-numeric:tabular-nums}
.adreport-hint{font-size:12px;line-height:1.6;color:var(--muted);max-width:540px}
.adreport-totals{margin-bottom:18px}
.adreport-table{min-width:1180px}
.adreport-table th.numeric,.adreport-table td.numeric{text-align:right;white-space:nowrap;font-variant-numeric:tabular-nums}
.adreport-table .record-time{white-space:nowrap}
.pending-badge{display:inline-block;padding:2px 8px;border-radius:999px;background:rgba(169,106,21,.12);color:var(--warn);font-size:12px;font-weight:500}

@media(max-width:700px){
  .adreport-hint{display:none}
  .adreport-table{min-width:980px}
  .adreport-date input{min-height:36px}
}
/* 广告指标合计条：4 项一行 */
.adreport-totals{grid-template-columns:1.1fr 1.1fr .8fr .8fr}
@media(max-width:980px){.adreport-totals{grid-template-columns:1fr 1fr;row-gap:20px}.adreport-totals>div:nth-child(3){padding-left:0;border-left:0}}
@media(max-width:700px){.adreport-totals{grid-template-columns:1fr 1fr;padding:18px 0;margin-bottom:20px}}
/* 广告指标：移动端去掉冗余的日期/APP 列，合计条补齐行距 */
@media(max-width:700px){
  .adreport-totals{grid-template-columns:1fr 1fr;row-gap:16px;column-gap:12px}
  .adreport-totals>div{padding:0 6px;border-left:0}
  .adreport-table{min-width:760px}
  .adreport-table th:nth-child(1),.adreport-table td:nth-child(1),
  .adreport-table th:nth-child(2),.adreport-table td:nth-child(2){display:none}
  .adreport-table th:nth-child(3),.adreport-table td:nth-child(3){min-width:150px}
}
/* 广告指标：搜索框 */
.adreport-search{width:200px;min-height:38px}
@media(max-width:700px){.adreport-search{flex:1;width:auto;min-height:36px}}
.adreport-warn{margin:-8px 0 16px;font-size:12.5px;line-height:1.6;color:var(--warn)}
.adreport-source{margin:-8px 0 14px;font-size:12px;color:var(--muted)}
/* ---------- 凭据失效提示 ---------- */
.credential-dialog{max-width:620px}
.credential-note{margin:0 0 14px;font-size:13px;line-height:1.7;color:var(--muted)}
.credential-list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:10px;max-height:46vh;overflow:auto}
.credential-list li{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:12px 14px;border:1px solid var(--line);border-radius:12px;background:#fff}
.credential-app{display:flex;flex-direction:column;gap:3px;min-width:0}
.credential-app strong{font-size:14px}
.credential-app span{font-size:12px;color:var(--danger)}
.credential-actions{display:flex;align-items:center;gap:10px;flex-shrink:0}
@media(max-width:700px){
  .credential-list li{flex-direction:column;align-items:flex-start}
  .credential-actions{width:100%;justify-content:flex-end}
}
/* ---------- 子账户与额度 ---------- */
details.app-picker{margin:14px 0}
.form-field-label{margin:0 0 8px;font-size:13px;color:var(--muted)}
details.app-picker>.app-picker-list{max-height:220px;overflow:auto;border:1px solid var(--line);border-radius:12px;padding:8px;display:flex;flex-direction:column;gap:2px;background:#fff}
.app-picker-item{display:flex;align-items:center;gap:8px;padding:6px 8px;border-radius:8px;font-size:13px;cursor:pointer}
.app-picker-item:hover{background:var(--surface)}
.form-hint{margin:0 0 4px;font-size:12px;line-height:1.6;color:var(--muted)}
.quota-list li{display:block}
.quota-item{display:flex;align-items:center;gap:8px;font-size:13.5px;cursor:pointer}
.accounts-table td{vertical-align:middle}

/* 底部导航按实际项数自适应（主账户 5 项、子账户 4 项） */
.tabbar{grid-template-columns:none;grid-auto-flow:column;grid-auto-columns:1fr}
/* 子账户表单：授权列表限高，操作按钮吸底，避免保存按钮被挤出视口 */
details.app-picker>.app-picker-list{max-height:150px}
.dialog .dialog-actions{position:sticky;bottom:-2px;background:#fff;padding-top:12px;margin-top:6px}
/* 子账户表单：整体更紧凑，保证保存按钮可见 */
details.app-picker>.app-picker-list{max-height:112px}
.dialog .credential-note{margin-bottom:10px}
.dialog .form-field{margin-bottom:10px}
details.app-picker{margin:8px 0}
details.app-picker>.app-picker-list{max-height:96px}
/* 授权列表折叠，默认收起，保证表单底部按钮可见 */
details.app-picker>summary{list-style:none;cursor:pointer;padding:6px 0;color:var(--accent)}
details.app-picker>summary::-webkit-details-marker{display:none}
details.app-picker[open]>summary{margin-bottom:6px}
/* ---------- 子账户表单：整段滚动 + 底部按钮吸底 ---------- */
.dialog.account-dialog{display:flex;flex-direction:column;max-height:calc(100dvh - 48px);overflow:hidden;padding-bottom:0}
.dialog.account-dialog>form{display:flex;flex-direction:column;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding-bottom:4px}
.dialog.account-dialog .app-picker-list{max-height:none;overflow:visible}
.dialog.account-dialog .dialog-actions{position:sticky;bottom:0;z-index:3;margin-top:10px;padding:14px 0 18px;border-top:1px solid var(--line);background:linear-gradient(180deg,rgba(255,255,255,.92),#fff 34%)}
@media(max-width:700px){.dialog.account-dialog{max-height:92dvh}}
/* 子账户表单最终布局：头部固定 / 内容滚动 / 底部按钮固定，展开授权列表也不会被撑破 */
.dialog.account-dialog{display:flex;flex-direction:column;max-height:calc(100dvh - 48px);overflow:hidden;padding:26px 30px 0}
.dialog.account-dialog>form.dialog-body{flex:1 1 auto;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:2px 6px 12px 0}
.dialog.account-dialog>.dialog-actions{position:static;flex:0 0 auto;margin:0;padding:14px 0 18px;border-top:1px solid var(--line);background:#fff}
.dialog.account-dialog .app-picker-list{max-height:220px;overflow:auto}
@media(max-width:700px){
  .dialog.account-dialog{max-height:92dvh;padding:20px 18px 0}
  .dialog.account-dialog>.dialog-actions{padding:12px 0 calc(12px + env(safe-area-inset-bottom))}
}
/* 用块级布局替代 flex：表单区域限高滚动，底部按钮自然留在下面 */
.dialog.account-dialog{display:block;overflow:hidden;max-height:calc(100dvh - 48px);padding:26px 30px 0}
.dialog.account-dialog>form.dialog-body{display:block;overflow-y:auto;overscroll-behavior:contain;max-height:calc(100dvh - 250px);padding-right:6px}
.dialog.account-dialog>.dialog-actions{position:static;margin:0;padding:14px 0 18px;border-top:1px solid var(--line);background:#fff}
.dialog.account-dialog .app-picker-list{max-height:200px;overflow:auto}
@media(max-width:700px){
  .dialog.account-dialog{max-height:92dvh;padding:20px 18px 0}
  .dialog.account-dialog>form.dialog-body{max-height:calc(92dvh - 190px)}
}
/* 子账户表单：错误提示固定在按钮上方，始终可见 */
.account-form-error{margin:0;padding:10px 0 0;border-top:1px solid rgba(178,63,57,.16);color:var(--danger);font-size:13px}
/* 授权小游戏：搜索 + 计数 + 限量渲染 */
.app-picker-tools{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:2px 0 8px}
.app-picker-search{width:200px;min-height:36px;font-size:13px}
.app-picker-count{font-size:12px;color:var(--muted);margin-left:auto;white-space:nowrap}
.app-picker-id{margin-left:auto;color:var(--muted);font-size:11px;font-variant-numeric:tabular-nums}
.app-picker-item span{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.app-picker-empty{margin:8px;font-size:12px;color:var(--muted)}
@media(max-width:700px){
  .app-picker-search{flex:1;width:auto}
  .app-picker-count{margin-left:0}
  .app-picker-id{display:none}
}
/* 修复：<details> 收起时列表仍被 display:flex 撑开，导致弹窗底部出现 200px 空白 */
details.app-picker:not([open])>.app-picker-list{display:none}
details.app-picker[open]>.app-picker-list{display:flex;flex-direction:column}
details.app-picker[open]>.app-picker-tools{display:flex}
details.app-picker:not([open])>.app-picker-tools{display:none}
/* 广告指标：APP 列固定宽度不换行，避免「全部」竖排 */
.adreport-table th:nth-child(2),.adreport-table td:nth-child(2){width:64px;min-width:64px;white-space:nowrap}
/* 名称显示/隐藏按钮与搜索框对齐 */
.adreport-name-toggle{min-width:88px}
/* ---------- 启动占位：避免刷新时先闪一下登录页 ---------- */
.app-splash{position:fixed;inset:0;display:flex;align-items:center;justify-content:center;gap:10px;font-size:14px;letter-spacing:.02em;color:var(--muted);background:radial-gradient(900px 560px at 18% 8%,rgba(196,214,255,.55),transparent 60%),radial-gradient(760px 520px at 84% 6%,rgba(232,214,255,.5),transparent 62%),#eef2f8}
.splash-dot{width:8px;height:8px;border-radius:50%;background:var(--accent);animation:splashPulse 1s ease-in-out infinite}
@keyframes splashPulse{0%,100%{opacity:.35;transform:scale(.85)}50%{opacity:1;transform:scale(1)}}
/* Multiple metric columns must scroll together; the shared income table pins one amount column. */
@media(max-width:700px){.adreport-table .numeric{position:static;right:auto;box-shadow:none}}
.app-splash{color:var(--ink)}
@media(prefers-reduced-motion:reduce){.splash-dot{animation:none}}

/* 财务报表保留完整维度与金额列，表内横向滚动。 */
.dimension-report-table{min-width:1640px}
.dimension-report-table td,.dimension-report-table th{white-space:nowrap}
.report-record-status{font-size:12px;color:var(--muted)}
.report-record-status.error{color:var(--danger)}
.report-records .table-container:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
@media(max-width:700px){.dimension-report-table .numeric{position:static;right:auto;box-shadow:none}.drawer-body .dimension-report-table{min-width:1480px}}
.report-partial-label{display:block;font-size:12px;color:var(--warn)}
.finance-totals strong{overflow-wrap:anywhere}

/* ---------- 下拉选择器（财务分析等）：块级列表，选项不被压缩 ---------- */
/* 子账户表单的 flex 规则只作用于 details.app-picker，避免污染下拉框 */
.app-picker>.app-picker-list{display:block;max-height:260px;overflow:auto}
.app-picker>.app-picker-list>.app-picker-option{display:block;flex:0 0 auto;min-height:34px;line-height:1.5;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
/* 轻提示（修改密码等操作反馈） */
.app-toast{position:fixed;left:50%;bottom:34px;transform:translateX(-50%);z-index:130;padding:10px 18px;border-radius:12px;background:rgba(23,32,58,.94);color:#fff;font-size:13.5px;letter-spacing:.01em;box-shadow:0 14px 34px rgba(20,30,60,.28);pointer-events:none}
@media(max-width:700px){.app-toast{bottom:calc(86px + env(safe-area-inset-bottom))}}