/* ===== A「图鉴风」(alternative style) · 红白粗描边贴纸卡片 · 日间 = 浅色纸面，夜间 = 深色纸面 =====
   Switches on <html data-style="a" data-scheme="light|dark">; rules scoped with :where(). */
:root[data-style="a"]{
  color-scheme:light;
  --font:"Microsoft YaHei UI","Microsoft YaHei","PingFang SC","Noto Sans SC",sans-serif;
  --title:"PB KuaiLe","Microsoft YaHei UI","Microsoft YaHei",sans-serif;
  --num:"PB Rounded","Microsoft YaHei UI","Microsoft YaHei",sans-serif;
  --bg:#F4EFE4;--ink:#23252E;--muted:#6F7180;--line:#E0D8C8;
  --card:#FFFFFF;--card-solid:#FFFFFF;--sub:#F8F4EC;--chip:#EFE9DC;--field:#FFFFFF;--btn:#FFFFFF;
  --accent:#E3402F;--accent-dark:#23252E;--accent-ink:#E3402F;--on-accent:#FFFFFF;--danger:#C7372A;--ok-ink:#2E6B21;--focus:#2367D1;
  --r:16px;--r-btn:11px;
  --stroke:#23252E;--dots:#E3DBCB;--top:#E3402F;--top-ink:#FFFFFF;--top-soft:#FFE3DE;--lens:#9FD3F5;
  --mode-bg:#FFFFFF;--on-chip:#23252E;
  --journey-bg:#FDF6E3;--journey-line:#D9CCAE;--cap-bg:#FFFFFF;--cap-line:#E5DDCC;
  --tab-on:#23252E;--tab-on-ink:#FFFFFF;--log-line:#EEE6D6;--time-ink:#E3402F;
  --pend-bg:#FFF7D1;--pend-line:#E1B800;--group-bg:#FBF8F2;--group-line:#E5DDCC;--group-dash:#E0D8C8;
  --prog-bg:#FBF6EA;--prog-line:#EDE3CF;--avatar-bg:#FFF8EC;
  --card-border:2px solid var(--stroke);--shadow:0 3px 0 var(--stroke);--shadow-pop:0 5px 0 var(--stroke),0 18px 40px rgba(35,37,46,.25);
}
:root[data-style="a"][data-scheme="dark"]{
  color-scheme:dark;
  --bg:#17191F;--ink:#EEEAE1;--muted:#A6A5B2;--line:#363A47;
  --card:#23262F;--card-solid:#23262F;--sub:#1D2028;--chip:#2C303C;--field:#1B1E26;--btn:#2B2F3B;
  --accent:#E8483A;--accent-dark:#07080B;--accent-ink:#FF8A7C;--on-accent:#FFFFFF;--danger:#FF8170;--ok-ink:#9BE38A;--focus:#7CA4F5;
  --stroke:#07080B;--dots:#262934;--top:#BF3227;--top-ink:#FFFFFF;--top-soft:#FFD3CB;--lens:#5FA6D6;
  --mode-bg:#2B2F3B;--on-chip:#17191F;
  --journey-bg:#1C1F27;--journey-line:#454A5A;--cap-bg:#272A34;--cap-line:#363A47;
  --tab-on:#EEEAE1;--tab-on-ink:#17191F;--log-line:#2E323D;--time-ink:#FF8A7C;
  --pend-bg:rgba(242,196,15,.12);--pend-line:#8F7612;--group-bg:#1E2129;--group-line:#363A47;--group-dash:#3B3F4C;
  --prog-bg:#2A2D37;--prog-line:#3A3E4B;--avatar-bg:#2E3240;
  --shadow-pop:0 5px 0 var(--stroke),0 18px 40px rgba(0,0,0,.55);
  /* brighter type colours on the dark paper */
  --ghost:#A586D6;--water:#7CA4F5;--steel:#B4B9D0;--normal:#C4C39A;
}
:where([data-style="a"]) body{background:radial-gradient(var(--dots) 1.1px,transparent 1.2px) 0 0/18px 18px,var(--bg)}
/* top bar = Pokédex lid: red band + white lens */
:where([data-style="a"]) .topbar{margin:0 -22px 16px;padding:0 22px;height:62px;background:var(--top);color:var(--top-ink);border-bottom:3px solid var(--stroke)}
:where([data-style="a"]) .topbar::after{content:"";position:absolute;left:0;right:0;bottom:-9px;height:6px;background:repeating-linear-gradient(90deg,var(--stroke) 0 24px,transparent 24px 30px);opacity:.12;pointer-events:none}
:where([data-style="a"]) .brand .logo{width:44px;height:44px;border-radius:50%;background:#fff;border:3px solid var(--stroke);box-shadow:inset 0 0 0 3px var(--lens)}
:where([data-style="a"]) .brand .logo svg{width:30px;height:30px}
:where([data-style="a"]) .brand small,:where([data-style="a"]) .topbar .badge{color:var(--top-soft)}
:where([data-style="a"]) .topbar .badge{border-color:rgba(255,255,255,.45)}
:where([data-style="a"]) .conn{background:rgba(255,255,255,.16);color:#fff}
:where([data-style="a"]) .conn span:last-child{color:var(--top-soft)}
:where([data-style="a"]) .topbar button.ghost{color:#fff;border-color:rgba(255,255,255,.55);box-shadow:none}
:where([data-style="a"]) .update-pop summary{color:#fff;background:rgba(0,0,0,.14)}
:where([data-style="a"]) .topbar .dot.on{background:#7CF08A}
/* layout: hero | 2×2 stats, then captures | log */
:where([data-style="a"]) .layout{grid-template-columns:minmax(0,1.75fr) minmax(0,1fr);grid-template-rows:auto minmax(var(--rest-min),1fr);grid-template-areas:"hero metrics" "captures log"}
:where([data-style="a"]) .layout:has(.mode-panels>:not([hidden])){grid-template-rows:auto max-content minmax(var(--rest-min),1fr);grid-template-areas:"hero metrics" "captures panels" "captures log"}
:where([data-style="a"]) .metrics{grid-template-columns:1fr 1fr;grid-template-rows:1fr 1fr;gap:12px}
:where([data-style="a"]) .metrics article{padding:14px 14px 10px}
:where([data-style="a"]) .metrics article::before{content:"";position:absolute;left:0;right:0;top:0;height:7px;background:var(--c);border-bottom:2px solid var(--stroke)}
:where([data-style="a"]) .metrics label{margin-top:4px}
:where([data-style="a"]) .metrics strong{font-size:28px}
:where([data-style="a"]) .metrics article::after{content:"";position:absolute;right:-16px;bottom:-16px;width:62px;height:62px;border-radius:50%;border:8px solid color-mix(in srgb,var(--c) 22%,transparent);pointer-events:none}
:where([data-style="a"]) .hero{padding:16px 18px 14px;display:flex;flex-direction:column;justify-content:flex-start}
:where([data-style="a"]) .hero::before{content:"TRAINER CARD";position:absolute;right:16px;top:-11px;font:800 10px/1 var(--num);letter-spacing:.18em;background:var(--stroke);color:#fff;padding:5px 9px;border-radius:6px}
:where([data-style="a"]) .status h1{font-size:25px}
:where([data-style="a"]) .hero-top{align-items:flex-start}
:where([data-style="a"]) .actions{justify-content:flex-start}
:where([data-style="a"]) button{border:2px solid var(--stroke);box-shadow:0 2px 0 var(--stroke)}
:where([data-style="a"]) button:active:not(:disabled){transform:translateY(2px);box-shadow:none}
:where([data-style="a"]) button.primary{background:var(--accent)}
:where([data-style="a"]) button.primary:disabled{opacity:.62}
:where([data-style="a"]) button.danger{border-color:var(--stroke);color:var(--danger)}
:where([data-style="a"]) .tab,:where([data-style="a"]) .theme-switch button,:where([data-style="a"]) .rename-link{box-shadow:none}
:where([data-style="a"]) .mode{border:2px solid var(--stroke);background:var(--mode-bg);padding:4px 10px}
:where([data-style="a"]) .mode[aria-checked=true]{background:var(--c);color:var(--on-chip);box-shadow:0 2px 0 var(--stroke)}
:where([data-style="a"]) .mode[aria-checked=true] svg{color:var(--on-chip)}
:where([data-style="a"]) .modes{gap:6px;margin:14px 0 12px}
:where([data-style="a"]) .modes-label{display:none}
:where([data-style="a"]) .journey{background:var(--journey-bg);border:2px dashed var(--journey-line)}
:where([data-style="a"]) .dex{background:var(--stroke);color:#fff;padding:1px 7px;border-radius:5px;font-size:11px}
:where([data-style="a"]) .pokemon-name{margin-left:-4px}
:where([data-style="a"]) .bar{border:2px solid var(--stroke);height:11px;background:var(--field)}
:where([data-style="a"]) .card-head h2{display:flex;align-items:center;gap:8px}
:where([data-style="a"]) .card-head h2::before{content:"";width:12px;height:12px;border-radius:50%;background:var(--accent);border:2px solid var(--stroke);box-shadow:inset 0 -4px 0 #fff;flex:none}
:where([data-style="a"]) .capture-row{background:var(--cap-bg);border:1.5px solid var(--cap-line);border-left:5px solid var(--electric)}
:where([data-style="a"]) .capture-row[data-kind=classic]{border-left-color:var(--steel)}
:where([data-style="a"]) .capture-row[data-kind=new]{border-left-color:var(--grass)}
:where([data-style="a"]) .capture-row[data-kind=stardust]{border-left-color:var(--psychic)}
:where([data-style="a"]) .capture-row .ico{border-radius:11px;background:var(--avatar-bg);border:2px solid var(--stroke)}
:where([data-style="a"]) .tab.on{background:var(--tab-on);color:var(--tab-on-ink)}
:where([data-style="a"]) .log-row{border-bottom:1px solid var(--log-line)}
:where([data-style="a"]) .log-row time{color:var(--time-ink)}
:where([data-style="a"]) .pending-line{border:1.5px dashed var(--pend-line);background:var(--pend-bg)}
:where([data-style="a"]) .model-route{background:var(--prog-bg);border:1.5px solid var(--prog-line)}
/* dialogs: red title band */
:where([data-style="a"]) .sheet-head{background:var(--top);color:#fff;border-bottom:3px solid var(--stroke)}
:where([data-style="a"]) .sheet-head .note{color:var(--top-soft)}
:where([data-style="a"]) .sheet-head button.ghost{color:#fff;border-color:#fff;box-shadow:none}
:where([data-style="a"]) .group{background:var(--group-bg);border:2px solid var(--group-line)}
:where([data-style="a"]) .group h3::after{content:"";flex:1;height:2px;background:repeating-linear-gradient(90deg,var(--group-dash) 0 6px,transparent 6px 10px);margin-left:6px}
:where([data-style="a"]) .group h3 svg{color:var(--accent)}
/* account manager */
:where([data-style="a"]) .license-pill form{background:rgba(255,255,255,.16);color:#fff}
:where([data-style="a"]) .license-pill .pop{color:var(--ink)}
:where([data-style="a"]) .license-pill #license-status{color:#fff}
:where([data-style="a"]) .account-card{border-left-width:2px}
:where([data-style="a"]) .account-title h2{font-family:var(--font)}
:where([data-style="a"]) .account-title::before{background:var(--stroke);color:#fff;padding:0 6px;border-radius:4px}
:where([data-style="a"]) .account-progress span{background:var(--prog-bg);border:1px solid var(--prog-line)}
:where([data-style="a"]) .account-card .avatar{border-radius:50%;background:var(--avatar-bg);border:2.5px solid var(--stroke);box-shadow:inset 0 0 0 2px var(--lens)}
:where([data-style="a"]) .account-card .avatar img{border-radius:50%}
:where([data-style="a"]) .account-card:not(.is-running) .avatar img{filter:saturate(.35) brightness(.95)}
:where([data-style="a"]) .account-card.is-running .avatar{box-shadow:inset 0 0 0 2px var(--lens),0 0 0 3px var(--grass)}
:where([data-style="a"]) .partner{background:var(--avatar-bg);border:2px solid var(--stroke);border-radius:12px;box-shadow:0 2px 0 var(--stroke)}
:where([data-style="a"]) .legend-pick button[aria-pressed=true]{background:color-mix(in srgb,var(--accent) 12%,var(--field));border-color:var(--stroke)}
:where([data-style="a"]) .species-preview{border:2px solid var(--stroke);border-radius:50%}
/* theme switch on the red band */
:where([data-style="a"]) .theme-switch{background:rgba(0,0,0,.16);border-color:rgba(255,255,255,.35)}
:where([data-style="a"]) .theme-switch button{color:#fff;border:0}
:where([data-style="a"]) .theme-switch button[aria-checked=true]{background:#fff;color:#23252E;box-shadow:0 2px 0 var(--stroke)}
:where([data-style="a"]) .page-mgr .metrics{grid-template-columns:repeat(4,1fr);grid-template-rows:auto}
@media (max-width:1100px){
  :where([data-style="a"]) .layout{grid-template-columns:minmax(0,1.35fr) minmax(0,1fr);grid-template-rows:auto auto minmax(var(--rest-min),1fr);grid-template-areas:"hero hero" "metrics metrics" "captures log"}
  :where([data-style="a"]) .layout:has(.mode-panels>:not([hidden])){grid-template-rows:auto auto max-content minmax(var(--rest-min),1fr);grid-template-areas:"hero hero" "metrics metrics" "captures panels" "captures log"}
  :where([data-style="a"]) .metrics{grid-template-columns:repeat(4,minmax(0,1fr));grid-template-rows:auto}
}
/* 0.8.1: short windows, see style.css */
@media (max-height:760px){
  :where([data-style="a"]) .hero{padding:12px 16px 10px}
  :where([data-style="a"]) .status h1{font-size:21px}
  :where([data-style="a"]) .metrics{gap:10px}
  :where([data-style="a"]) .metrics article{padding:12px 12px 6px}
  :where([data-style="a"]) .metrics strong{font-size:23px}
}
