[hidden]{display:none!important}
:root{
  --bg:#f7f8fb;--surface:#ffffff;--surface-soft:#f1f4f8;--text:#1e2e44;--muted:#667386;
  --line:#e2e6ed;--accent:#3b6cb7;--accent-2:#527fc2;--accent-rgb:59,108,183;
  --tc-blue:#3b6cb7;--tc-red:#e05a5a;--tc-gold:#e0b14b;--tc-navy:#1e2e44;--tc-cloud:#f7f8fb;
  --danger:#d14f5a;--shadow:0 18px 60px rgba(30,46,68,.09);--shadow-soft:0 8px 28px rgba(30,46,68,.075);
  --radius:24px;--radius-sm:16px;--max:1180px;
}
*{box-sizing:border-box}
html{background:var(--bg);scroll-behavior:smooth}
body{margin:0;min-height:100vh;background:radial-gradient(circle at 12% -8%,rgba(59,108,183,.12),transparent 32rem),radial-gradient(circle at 88% 2%,rgba(224,177,75,.08),transparent 26rem),var(--bg);color:var(--text);font-family:Inter,ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;-webkit-font-smoothing:antialiased}
button,input,select{font:inherit}
button{color:inherit}
button,input,select{touch-action:manipulation}
button:focus-visible,input:focus-visible,select:focus-visible{outline:3px solid rgba(var(--accent-rgb),.28);outline-offset:2px}
.app-shell{min-height:100vh;padding-bottom:88px}
.app-bar{height:74px;padding:0 max(18px,env(safe-area-inset-left));display:flex;align-items:center;justify-content:space-between;max-width:calc(var(--max) + 40px);margin:0 auto}
.brand{display:flex;align-items:center;gap:11px;border:0;background:transparent;padding:8px 0;text-align:left;cursor:pointer}
.brand-mark{width:38px;height:38px;border:3px solid var(--text);border-radius:50%;display:grid;place-items:center;position:relative;background:linear-gradient(180deg,var(--accent) 0 47%,#fff 47% 53%,var(--accent-2) 53% 100%)}
.brand-mark:before{content:"";position:absolute;width:100%;height:3px;background:var(--text)}
.brand-mark span{width:12px;height:12px;border:3px solid var(--text);border-radius:50%;background:#fff;z-index:1}
.brand-copy{display:flex;flex-direction:column;line-height:1.05}
.brand-copy strong{font-size:14px}.brand-copy small{font-size:10px;color:var(--muted);margin-top:4px}
.beta-pill{font-size:11px;font-weight:800;letter-spacing:.07em;text-transform:uppercase;padding:7px 10px;border-radius:999px;background:rgba(var(--accent-rgb),.10);color:var(--accent)}
main{max-width:var(--max);margin:0 auto;padding:8px 18px 60px}
.view{display:none;animation:fadeIn .28s ease}.view.is-active{display:block}
@keyframes fadeIn{from{opacity:.25;transform:translateY(6px)}to{opacity:1;transform:none}}
.hero{padding:44px 0 38px;max-width:840px}
.eyebrow{display:block;color:var(--accent);font-size:11px;font-weight:900;letter-spacing:.11em;text-transform:uppercase;margin-bottom:8px}
.hero h1,.builder-hero h1,.preview-head h1{font-size:clamp(36px,7vw,72px);line-height:.96;letter-spacing:-.055em;margin:0;max-width:900px}
.hero p,.builder-hero p,.preview-head p{font-size:17px;line-height:1.6;color:var(--muted);max-width:720px;margin:20px 0 0}
.section-heading{display:flex;gap:24px;justify-content:space-between;align-items:flex-end;margin:20px 0 18px}
.section-heading h2{font-size:25px;letter-spacing:-.035em;margin:0}.section-heading>p{color:var(--muted);font-size:13px;max-width:390px;margin:0;text-align:right;line-height:1.45}
.section-heading.compact{margin:0 0 18px}.section-heading.compact h2{font-size:21px}
.game-grid{display:grid;grid-template-columns:1fr;gap:14px}
.game-card{position:relative;overflow:hidden;min-height:245px;border:1px solid rgba(255,255,255,.7);border-radius:28px;padding:0;background:#242538;color:#fff;text-align:left;box-shadow:var(--shadow-soft);cursor:pointer;isolation:isolate;transition:transform .2s ease,box-shadow .2s ease}
.game-card:hover{transform:translateY(-3px);box-shadow:var(--shadow)}
.game-card:active{transform:scale(.99)}
.game-card:before{content:"";position:absolute;inset:0;background:linear-gradient(120deg,rgba(10,10,20,.82) 0 43%,rgba(10,10,20,.15) 75%);z-index:-1}
.game-card.champions{background:linear-gradient(135deg,#5751d6,#57b9ec)}
.game-copy{position:absolute;z-index:2;left:22px;right:22px;bottom:21px;max-width:65%}
.game-kicker{font-size:10px;text-transform:uppercase;letter-spacing:.12em;font-weight:900;opacity:.78}
.game-copy h3{font-size:26px;letter-spacing:-.04em;margin:5px 0 7px}.game-copy p{font-size:12px;line-height:1.45;opacity:.82;margin:0 0 14px}
.choose-link{font-size:12px;font-weight:800}.choose-link span{display:inline-block;transition:transform .2s}.game-card:hover .choose-link span{transform:translateX(4px)}
.game-art{position:absolute;right:-18px;top:0;width:58%;height:100%;z-index:0}
.game-art img{position:absolute;object-fit:contain;filter:drop-shadow(0 16px 18px rgba(0,0,0,.22));user-select:none}
.game-art .art-one{width:77%;right:19%;bottom:-7%}.game-art .art-two{width:68%;right:-14%;top:4%}
.principles{display:grid;gap:12px;margin:48px 0 12px}
.principles article{display:flex;gap:14px;align-items:flex-start;padding:18px;border:1px solid var(--line);background:rgba(255,255,255,.72);backdrop-filter:blur(12px);border-radius:18px}
.principle-icon{width:38px;height:38px;flex:0 0 38px;border-radius:12px;display:grid;place-items:center;background:rgba(var(--accent-rgb),.10);color:var(--accent);font-weight:900}
.principles h3{font-size:14px;margin:1px 0 4px}.principles p{font-size:12px;line-height:1.45;color:var(--muted);margin:0}
.builder-hero{min-height:220px;display:flex;align-items:flex-end;justify-content:space-between;padding:34px 0 26px;position:relative}
.builder-hero h1{font-size:clamp(38px,6vw,64px)}
.back-link,.text-button{border:0;background:transparent;padding:0;color:var(--muted);font-size:12px;font-weight:750;cursor:pointer;margin-bottom:16px}
.back-link:hover,.text-button:hover{color:var(--accent)}
.builder-game-art{width:180px;height:150px;background-position:center;background-repeat:no-repeat;background-size:contain;filter:drop-shadow(0 18px 18px rgba(31,34,48,.12))}
.details-card{background:rgba(255,255,255,.9);border:1px solid var(--line);border-radius:var(--radius);padding:20px;box-shadow:var(--shadow-soft);margin-bottom:28px}
.details-grid{display:grid;grid-template-columns:1fr;gap:12px}
label>span{display:block;font-size:11px;font-weight:800;color:#5e6070;margin:0 0 6px}
input,select{width:100%;min-height:48px;border:1px solid var(--line);border-radius:14px;background:#fff;padding:0 13px;color:var(--text);font-size:15px;transition:border-color .15s,box-shadow .15s}
input::placeholder{color:#aaaebb}
input:focus,select:focus{border-color:rgba(var(--accent-rgb),.55);box-shadow:0 0 0 4px rgba(var(--accent-rgb),.08);outline:none}
.team-heading{align-items:center}.completion{font-size:12px;font-weight:800;color:var(--muted);background:#e9eaf0;padding:8px 11px;border-radius:999px}
.team-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:12px}
.team-slot{position:relative;min-height:218px;border:1px solid var(--line);border-radius:22px;background:var(--surface);padding:14px;overflow:hidden;text-align:left;cursor:pointer;box-shadow:var(--shadow-soft);transition:.2s ease}
.team-slot:hover{border-color:rgba(var(--accent-rgb),.35);transform:translateY(-2px)}
.team-slot.empty{display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;border-style:dashed;background:rgba(255,255,255,.55);box-shadow:none}
.add-orb{width:48px;height:48px;border-radius:17px;display:grid;place-items:center;background:rgba(var(--accent-rgb),.09);color:var(--accent);font-size:26px;margin-bottom:10px}
.team-slot.empty strong{font-size:13px}.team-slot.empty small{color:var(--muted);font-size:10px;margin-top:4px}
.slot-number{position:absolute;left:12px;top:11px;font-size:9px;font-weight:900;letter-spacing:.08em;color:var(--muted);z-index:2}
.slot-img{height:108px;display:flex;align-items:center;justify-content:center;margin-top:4px;background:radial-gradient(circle,rgba(var(--accent-rgb),.11),transparent 62%)}
.slot-img img{width:116px;height:116px;object-fit:contain;filter:drop-shadow(0 10px 12px rgba(31,34,48,.11))}
.slot-name{font-size:15px;font-weight:900;letter-spacing:-.02em;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.slot-meta{font-size:10px;color:var(--muted);margin-top:3px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.slot-types{display:flex;gap:4px;margin-top:7px}.type-pill{font-size:8px;font-weight:900;text-transform:uppercase;letter-spacing:.04em;padding:4px 6px;border-radius:999px;background:#ececf2;color:#5d5f6d}
.builder-actions{display:flex;gap:10px;justify-content:flex-end;margin:26px 0}
.button{min-height:48px;border-radius:15px;border:1px solid transparent;padding:0 18px;font-weight:850;font-size:13px;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;gap:8px}
.button.primary{background:linear-gradient(135deg,var(--accent),var(--accent-2));color:#fff;box-shadow:0 10px 24px rgba(var(--accent-rgb),.22)}
.button.secondary{background:#fff;border-color:var(--line);color:var(--text)}.button.ghost{background:transparent}.button.danger{color:var(--danger)}
.preview-head{display:flex;flex-direction:column;gap:24px;padding:38px 0 20px}.preview-head h1{font-size:clamp(38px,6vw,62px)}
.preview-actions{display:flex;gap:8px}.segmented{display:inline-flex;background:#e8e9ef;border-radius:14px;padding:4px;margin:6px 0 18px}
.segmented button{border:0;background:transparent;border-radius:10px;padding:10px 13px;font-size:11px;font-weight:850;color:var(--muted);cursor:pointer}.segmented button.is-selected{background:#fff;color:var(--text);box-shadow:0 2px 8px rgba(0,0,0,.06)}
.preview-stage{background:#e1e2e8;border-radius:24px;padding:14px;overflow:auto}
.paper{background:#fff;width:100%;max-width:940px;min-height:640px;margin:0 auto;padding:22px;box-shadow:0 14px 45px rgba(31,34,48,.12);color:#151821}
.paper-header{display:flex;justify-content:space-between;gap:20px;border-bottom:3px solid var(--accent);padding-bottom:14px}.paper-brand h2{font-size:22px;letter-spacing:-.03em;margin:0}.paper-brand p{font-size:10px;color:#71737d;margin:4px 0 0}
.paper-meta{font-size:9px;text-align:right;line-height:1.5}.paper-meta strong{display:block;font-size:12px}
.paper-team{display:grid;grid-template-columns:1fr;gap:9px;margin-top:13px}
.paper-mon{display:grid;grid-template-columns:74px 1fr;border:1px solid #e1e2e8;border-radius:13px;overflow:hidden;min-height:128px}
.paper-mon-art{display:grid;place-items:center;background:#f5f5f8}.paper-mon-art img{width:70px;height:70px;object-fit:contain}
.paper-mon-body{padding:10px}.paper-mon-top{display:flex;justify-content:space-between;gap:10px;border-bottom:1px solid #ededf1;padding-bottom:6px;margin-bottom:6px}.paper-mon-name{font-size:13px;font-weight:900}.paper-mon-sub{font-size:8px;color:#777986;margin-top:2px}
.paper-moves{display:grid;grid-template-columns:1fr 1fr;gap:3px 9px;font-size:8px;font-weight:750}.paper-extra{font-size:8px;color:#60626e;margin-top:7px;display:flex;gap:10px;flex-wrap:wrap}
.paper-stats{display:grid;grid-template-columns:repeat(6,1fr);gap:3px;margin-top:7px}.paper-stat{background:#f4f4f7;border-radius:5px;padding:4px 2px;text-align:center}.paper-stat small{display:block;font-size:6px;color:#777986;text-transform:uppercase}.paper-stat strong{font-size:8px}
.bottom-nav{position:fixed;left:50%;bottom:max(10px,env(safe-area-inset-bottom));transform:translateX(-50%);width:min(calc(100% - 24px),430px);height:64px;padding:5px;display:grid;grid-template-columns:repeat(3,1fr);z-index:30;border:1px solid rgba(255,255,255,.8);border-radius:22px;background:rgba(255,255,255,.88);backdrop-filter:blur(18px);box-shadow:0 16px 45px rgba(31,34,48,.18)}
.bottom-nav button{border:0;background:transparent;border-radius:17px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;color:var(--muted);cursor:pointer}.bottom-nav button span{font-size:18px;line-height:1}.bottom-nav button small{font-size:9px;font-weight:800}.bottom-nav button.is-active{background:rgba(var(--accent-rgb),.10);color:var(--accent)}
.editor-backdrop{position:fixed;inset:0;z-index:100;background:rgba(15,17,28,.45);backdrop-filter:blur(7px);display:flex;align-items:flex-end;justify-content:center}
.editor-backdrop[hidden]{display:none}
.editor-sheet{width:100%;max-height:94vh;background:var(--bg);border-radius:28px 28px 0 0;display:flex;flex-direction:column;box-shadow:0 -20px 70px rgba(0,0,0,.2);animation:sheetUp .25s ease}
@keyframes sheetUp{from{transform:translateY(35px);opacity:.4}to{transform:none;opacity:1}}
.sheet-grabber{width:42px;height:5px;border-radius:999px;background:#c9cbd4;margin:9px auto 5px}
.editor-header{display:flex;justify-content:space-between;align-items:center;padding:10px 18px 12px;border-bottom:1px solid var(--line)}.editor-header h2{font-size:22px;margin:0;letter-spacing:-.03em}
.icon-button{width:40px;height:40px;border-radius:13px;border:1px solid var(--line);background:#fff;font-size:26px;line-height:1;cursor:pointer}
.editor-scroll{overflow:auto;padding:18px 18px 90px}.pokemon-picker{position:relative;background:linear-gradient(135deg,rgba(var(--accent-rgb),.12),rgba(var(--accent-rgb),.03));border:1px solid rgba(var(--accent-rgb),.14);border-radius:22px;padding:15px;margin-bottom:16px}
.selected-pokemon{display:flex;gap:14px;align-items:center;margin-bottom:13px}.pokemon-image-wrap{width:84px;height:84px;display:grid;place-items:center;border-radius:20px;background:rgba(255,255,255,.68)}.pokemon-image-wrap img{width:88px;height:88px;object-fit:contain}.empty-ball{font-size:27px;color:var(--accent)}
.selected-pokemon strong{font-size:20px;letter-spacing:-.03em}.type-row{display:flex;gap:5px;margin-top:6px}
.search-field{position:relative}.search-input-wrap{position:relative}.search-input-wrap>span{position:absolute;left:14px;top:13px;color:var(--muted);z-index:1}.search-input-wrap input{padding-left:39px}
.search-results{position:absolute;z-index:20;left:15px;right:15px;top:calc(100% - 8px);max-height:260px;overflow:auto;background:#fff;border:1px solid var(--line);border-radius:16px;box-shadow:var(--shadow);padding:6px}
.search-result{width:100%;border:0;background:#fff;padding:11px;border-radius:11px;text-align:left;font-weight:750;font-size:13px;cursor:pointer}.form-selector{display:block;margin-top:10px}.form-selector[hidden]{display:none}.search-result:hover{background:var(--surface-soft)}.search-result small{display:block;color:var(--muted);font-weight:500;margin-top:2px}
.field-hint{font-size:10px;color:var(--muted);margin:8px 2px 0}
.form-section{background:#fff;border:1px solid var(--line);border-radius:22px;padding:16px;margin-top:12px}.form-section-title{display:flex;gap:11px;align-items:flex-start;margin-bottom:15px}.form-section-title>span{width:30px;height:30px;display:grid;place-items:center;border-radius:10px;background:rgba(var(--accent-rgb),.09);color:var(--accent);font-size:9px;font-weight:900}.form-section-title h3{font-size:15px;margin:1px 0 2px}.form-section-title p{font-size:10px;color:var(--muted);margin:0}
.form-grid,.move-grid{display:grid;gap:10px}.form-grid.two{grid-template-columns:1fr 1fr}
.autocomplete-field{position:relative;min-width:0}.autocomplete-field>label{display:block;font-size:11px;font-weight:800;color:#5e6070;margin:0 0 6px}
.autocomplete-control{position:relative}.autocomplete-control input{padding-right:42px}.field-caret{position:absolute;right:5px;top:5px;width:38px;height:38px;border:0;border-radius:11px;background:transparent;color:var(--muted);font-size:18px;cursor:pointer}.field-caret:hover{background:rgba(var(--accent-rgb),.08);color:var(--accent)}
.field-results{position:absolute;z-index:45;left:0;right:0;top:calc(100% + 5px);max-height:245px;overflow:auto;background:#fff;border:1px solid var(--line);border-radius:14px;padding:5px;box-shadow:var(--shadow)}
.field-result{display:flex;width:100%;align-items:center;justify-content:space-between;gap:10px;border:0;background:#fff;border-radius:10px;padding:10px 11px;text-align:left;cursor:pointer}.field-result:hover,.field-result:focus{background:var(--surface-soft);outline:none}.field-result strong{font-size:12px}.field-result small{font-size:9px;color:var(--muted);white-space:nowrap}.field-empty{padding:11px;font-size:11px;color:var(--muted)}
.inline-toggle{display:flex;align-items:center;justify-content:space-between;gap:12px;border:1px solid var(--line);border-radius:14px;padding:10px 12px;margin-top:10px}.inline-toggle div strong{display:block;font-size:12px}.inline-toggle div small{display:block;font-size:9px;color:var(--muted);margin-top:2px}.inline-toggle input{width:20px;min-height:auto;height:20px}
.stat-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.stat-grid label span{text-align:center;font-size:9px}.stat-grid input{text-align:center;padding:0 5px;font-weight:800}
.move-grid{grid-template-columns:1fr}.move-grid .field-results{top:auto;bottom:calc(100% + 5px)}
.editor-footer{position:absolute;left:0;right:0;bottom:0;display:flex;gap:8px;justify-content:space-between;padding:10px 16px calc(10px + env(safe-area-inset-bottom));background:rgba(255,255,255,.92);backdrop-filter:blur(15px);border-top:1px solid var(--line);border-radius:0}.editor-footer .primary{min-width:150px}
.toast{position:fixed;z-index:200;left:50%;bottom:92px;transform:translate(-50%,14px);background:#20222d;color:#fff;padding:11px 15px;border-radius:13px;font-size:11px;font-weight:750;opacity:0;pointer-events:none;transition:.2s;box-shadow:var(--shadow)}.toast.show{opacity:1;transform:translate(-50%,0)}
.print-root{display:none}
@media(min-width:700px){
  main{padding-left:28px;padding-right:28px}.app-bar{padding-left:28px;padding-right:28px}
  .game-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.game-card{min-height:285px}.principles{grid-template-columns:repeat(3,1fr)}
  .details-grid{grid-template-columns:1fr 1fr}.team-grid{grid-template-columns:repeat(3,1fr)}.team-slot{min-height:235px}
  .paper-team{grid-template-columns:1fr 1fr}.preview-stage{padding:28px}.paper{padding:30px}
  .move-grid{grid-template-columns:1fr 1fr}.stat-grid{grid-template-columns:repeat(6,1fr)}
}
@media(min-width:960px){
  .bottom-nav{position:sticky;bottom:18px;margin:10px auto 0}.app-shell{padding-bottom:20px}
  .editor-backdrop{align-items:stretch;justify-content:flex-end}.editor-sheet{width:min(610px,48vw);height:100vh;max-height:none;border-radius:28px 0 0 28px;position:relative}.sheet-grabber{display:none}
  .editor-header{padding:24px 24px 16px}.editor-scroll{padding:20px 24px 110px}.editor-footer{padding:14px 24px}
  .preview-head{flex-direction:row;align-items:flex-end;justify-content:space-between}.preview-actions{flex:0 0 auto}
}
@media(max-width:520px){
  .hero{padding-top:28px}.hero h1{font-size:42px}.section-heading{display:block}.section-heading>p{text-align:left;margin-top:7px}
  .game-card{min-height:225px}.game-copy{max-width:72%}.game-copy h3{font-size:22px}.game-art{width:61%;right:-26px}
  .builder-game-art{width:120px;height:120px;position:absolute;right:0;top:38px;opacity:.8}.builder-hero>div:first-child{position:relative;z-index:1;max-width:82%}
  .builder-actions{display:grid;grid-template-columns:1fr}.preview-actions{display:grid;grid-template-columns:1fr 1fr}.paper{min-width:650px}
}
@media print{
  @page{size:A4 portrait;margin:9mm}
  body{background:#fff!important}.app-shell,.editor-backdrop,.toast{display:none!important}.print-root{display:block!important;color:#111;font-family:Arial,sans-serif}
  .print-sheet{width:100%}.print-head{display:flex;justify-content:space-between;border-bottom:2.2pt solid #333;padding-bottom:4mm;margin-bottom:4mm}
  .print-head h1{font-size:18pt;margin:0}.print-head p{font-size:7.5pt;margin:1.5mm 0 0;color:#555}.print-meta{text-align:right;font-size:7.5pt;line-height:1.45}.print-meta strong{display:block;font-size:10pt}
  .print-team{display:grid;grid-template-columns:1fr 1fr;gap:3mm}.print-mon{border:0.65pt solid #bbb;border-radius:3mm;min-height:80mm;overflow:hidden;page-break-inside:avoid}
  .print-mon-head{display:grid;grid-template-columns:27mm 1fr;background:#f3f3f5;border-bottom:.65pt solid #ccc;min-height:29mm}.print-mon-art{display:grid;place-items:center}.print-mon-art img{width:25mm;height:25mm;object-fit:contain}
  .print-mon-title{padding:4mm 3mm 2mm 0}.print-mon-title h2{font-size:11pt;margin:0}.print-mon-title p{font-size:6.5pt;color:#555;margin:1mm 0 0}
  .print-mon-body{padding:3mm}.print-row{display:grid;grid-template-columns:18mm 1fr;gap:2mm;font-size:7pt;margin-bottom:1.2mm}.print-row b{color:#555}.print-moves{display:grid;grid-template-columns:1fr 1fr;gap:1.2mm 2mm;margin-top:2mm}.print-move{font-size:7.5pt;font-weight:700;background:#f5f5f7;padding:1.4mm;border-radius:1mm}
  .print-stats{display:grid;grid-template-columns:repeat(6,1fr);gap:1mm;margin-top:2.5mm}.print-stat{text-align:center;border:.5pt solid #ddd;border-radius:1mm;padding:1.2mm .5mm}.print-stat small{display:block;font-size:5pt;text-transform:uppercase;color:#666}.print-stat strong{font-size:7pt}
  .print-foot{font-size:6pt;color:#777;margin-top:3mm;text-align:right}
}
.app-actions{display:flex;align-items:center;gap:8px}
.account-button{height:38px;display:flex;align-items:center;gap:8px;border:1px solid var(--line);background:rgba(255,255,255,.84);border-radius:14px;padding:0 11px 0 5px;font-size:11px;font-weight:850;cursor:pointer;box-shadow:var(--shadow-soft)}
.account-button:hover{border-color:rgba(var(--accent-rgb),.35)}
.account-avatar{width:28px;height:28px;border-radius:10px;display:grid;place-items:center;background:rgba(var(--accent-rgb),.1);color:var(--accent);background-position:center;background-size:cover}
.account-avatar.has-image{color:transparent}
.account-backdrop{position:fixed;inset:0;z-index:120;background:rgba(15,17,28,.45);backdrop-filter:blur(7px);display:flex;align-items:flex-end;justify-content:center}
.account-backdrop[hidden]{display:none}
.account-sheet{width:100%;max-height:94vh;background:var(--bg);border-radius:28px 28px 0 0;display:flex;flex-direction:column;box-shadow:0 -20px 70px rgba(0,0,0,.2);animation:sheetUp .25s ease;position:relative}
.account-header{display:flex;justify-content:space-between;align-items:center;padding:12px 18px;border-bottom:1px solid var(--line)}
.account-header h2{font-size:22px;margin:0;letter-spacing:-.03em}
.account-scroll{overflow:auto;padding:18px 18px calc(28px + env(safe-area-inset-bottom))}
.account-tabs{display:grid;grid-template-columns:1fr 1fr;padding:4px;background:#e8e9ef;border-radius:14px;margin-bottom:16px}
.account-tabs button{border:0;background:transparent;border-radius:10px;min-height:42px;font-size:12px;font-weight:850;color:var(--muted);cursor:pointer}
.account-tabs button.is-selected{background:#fff;color:var(--text);box-shadow:0 2px 8px rgba(0,0,0,.06)}
.account-form{display:grid;gap:12px}
.account-form .button{width:100%;margin-top:2px}
.account-link{margin:0;text-align:left}
.account-message{min-height:20px;margin-top:12px;font-size:11px;color:var(--muted);font-weight:700}
.account-message.is-error{color:var(--danger)}
.profile-hero{display:flex;align-items:center;gap:15px;background:#fff;border:1px solid var(--line);border-radius:20px;padding:14px;margin-bottom:14px}
.profile-hero>img{width:84px;height:84px;border-radius:22px;object-fit:cover;background:var(--surface-soft)}
.profile-identity{min-width:0;flex:1}.profile-identity>strong{display:block;font-size:14px;overflow:hidden;text-overflow:ellipsis}
.verified-badge{display:inline-block;margin-top:5px;padding:4px 7px;border-radius:999px;background:rgba(var(--accent-rgb),.1);color:var(--accent);font-size:9px;font-weight:900;text-transform:uppercase;letter-spacing:.05em}
.profile-avatar-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-top:10px}
.compact-button{min-height:38px;padding:0 12px;font-size:11px}
.profile-form{background:#fff;border:1px solid var(--line);border-radius:20px;padding:15px}
.cloud-section{margin-top:20px}
.cloud-save-row{display:grid;grid-template-columns:1fr;gap:8px;margin-bottom:12px}
.cloud-team-list{display:grid;gap:8px}
.cloud-empty{border:1px dashed var(--line);border-radius:16px;padding:18px;text-align:center;color:var(--muted);font-size:11px}
.cloud-team{display:grid;grid-template-columns:1fr 40px;align-items:center;background:#fff;border:1px solid var(--line);border-radius:17px;overflow:hidden}
.cloud-team.is-current{border-color:rgba(var(--accent-rgb),.45);box-shadow:0 0 0 3px rgba(var(--accent-rgb),.06)}
.cloud-team-open{border:0;background:transparent;display:grid;grid-template-columns:92px 1fr;gap:11px;align-items:center;text-align:left;padding:10px;cursor:pointer;min-width:0}
.cloud-team-open>div:last-child{min-width:0}.cloud-team-open strong{display:block;font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.cloud-team-open small{display:block;color:var(--muted);font-size:9px;margin-top:3px}
.cloud-team-images{height:44px;display:flex;align-items:center;overflow:hidden}.cloud-team-images img{width:34px;height:34px;object-fit:contain;margin-right:-11px;filter:drop-shadow(0 3px 3px rgba(0,0,0,.08))}
.cloud-team-delete{width:32px;height:32px;border:0;border-radius:10px;background:transparent;color:var(--muted);font-size:20px;cursor:pointer}.cloud-team-delete:hover{background:#fff0f2;color:var(--danger)}
.logout-button{width:100%;margin-top:20px}
@media(min-width:620px){.cloud-save-row{grid-template-columns:1fr auto}}
@media(min-width:960px){
  .account-backdrop{align-items:stretch;justify-content:flex-end}
  .account-sheet{width:min(560px,46vw);height:100vh;max-height:none;border-radius:28px 0 0 28px}
  .account-header{padding:24px 24px 16px}.account-scroll{padding:20px 24px 34px}
}
@media(max-width:520px){
  .beta-pill{display:none}.account-button{padding-right:8px}.account-button #accountLabel{max-width:72px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
}

.registration-success{padding:18px 4px 6px;text-align:center;max-width:430px;margin:0 auto}
.registration-success-icon{width:70px;height:70px;border-radius:24px;margin:2px auto 18px;display:grid;place-items:center;background:linear-gradient(135deg,var(--accent),var(--accent-2));color:#fff;font-size:34px;font-weight:900;box-shadow:0 16px 36px rgba(var(--accent-rgb),.22)}
.registration-success .eyebrow{margin-bottom:6px}
.registration-success h3{font-size:28px;letter-spacing:-.04em;margin:0 0 10px}
.registration-success p{margin:0;color:var(--muted);font-size:13px;line-height:1.55}
.registration-success p strong{color:var(--text)}
.registration-success-note{margin-top:8px!important}
.registration-success .button{width:100%;margin-top:22px}
.registration-success .account-link{display:block;margin:14px auto 0;text-align:center}

.account-teams-button{width:100%;margin-top:14px}
.account-message.is-success{margin-top:12px;padding:11px 12px;border-radius:12px;background:#eaf8ef;color:#18733a}
.teams-view{padding-top:30px}
.teams-page-head{display:flex;align-items:flex-end;justify-content:space-between;gap:18px;margin-bottom:24px}
.teams-page-head h1{font-size:clamp(38px,7vw,64px);line-height:1;letter-spacing:-.055em;margin:0}
.teams-guest-card{max-width:620px;margin:70px auto;background:#fff;border:1px solid var(--line);border-radius:26px;padding:34px;text-align:center;box-shadow:var(--shadow-soft)}
.teams-guest-icon{width:68px;height:68px;border-radius:22px;margin:0 auto 18px;display:grid;place-items:center;background:rgba(var(--accent-rgb),.1);color:var(--accent);font-size:30px}
.teams-guest-card h2{font-size:26px;margin:0 0 8px;letter-spacing:-.035em}.teams-guest-card p{color:var(--muted);line-height:1.55;margin:0 auto 22px;max-width:430px}
.team-save-panel{display:grid;gap:14px;background:linear-gradient(135deg,rgba(var(--accent-rgb),.10),rgba(var(--accent-rgb),.025));border:1px solid rgba(var(--accent-rgb),.16);border-radius:24px;padding:20px;margin-bottom:28px}
.team-save-panel h2{margin:0;font-size:22px;letter-spacing:-.03em}
.teams-library-head{display:flex;align-items:flex-end;justify-content:space-between;margin:0 0 14px}.teams-library-head h2{margin:0;font-size:24px;letter-spacing:-.035em}
.teams-library{grid-template-columns:1fr}
.teams-library .cloud-team{display:block;border-radius:20px;padding:12px;overflow:visible}
.teams-library .cloud-team-open{width:100%;grid-template-columns:110px 1fr;padding:4px;border-radius:14px}
.teams-library .cloud-team-images{height:58px}.teams-library .cloud-team-images img{width:44px;height:44px;margin-right:-14px}
.cloud-team-copy strong{font-size:14px!important}.cloud-team-copy small{font-size:10px!important;margin-top:5px!important}
.cloud-team-actions{display:flex;gap:6px;justify-content:flex-end;border-top:1px solid var(--line);margin-top:10px;padding-top:10px}
.cloud-team-actions button{border:0;background:transparent;border-radius:9px;padding:7px 9px;font-size:10px;font-weight:800;color:var(--muted);cursor:pointer}
.cloud-team-actions button:hover{background:var(--surface-soft);color:var(--text)}.cloud-team-actions .danger-link:hover{background:#fff0f2;color:var(--danger)}
.cloud-empty{display:grid;gap:4px}.cloud-empty strong{font-size:13px;color:var(--text)}.cloud-empty span{font-size:10px}
@media(min-width:700px){
  .team-save-panel{grid-template-columns:230px 1fr;align-items:end}
  .team-save-panel .account-message{grid-column:2}
  .cloud-save-row{grid-template-columns:minmax(180px,1fr) auto auto}
  .teams-library{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:620px){
  .teams-page-head{align-items:flex-start;flex-direction:column}.teams-page-head .button{width:100%}
  .bottom-nav{grid-template-columns:repeat(4,1fr)}
}

.bottom-nav{grid-template-columns:repeat(4,minmax(0,1fr));width:min(calc(100% - 24px),520px)}
.bottom-nav button{min-width:0;overflow:hidden}
.bottom-nav button small{white-space:nowrap;max-width:100%;overflow:hidden;text-overflow:ellipsis}

.profile-view{padding-top:30px}
.profile-page-head{margin-bottom:22px}
.profile-page-head h1{font-size:clamp(38px,7vw,64px);line-height:1;letter-spacing:-.055em;margin:0}
.profile-page-shell{max-width:900px}
.account-page-card{max-width:560px;background:#fff;border:1px solid var(--line);border-radius:24px;padding:20px;box-shadow:var(--shadow-soft)}
.profile-layout{display:grid;gap:16px}
.profile-summary-card,.profile-main-card{background:#fff;border:1px solid var(--line);border-radius:24px;padding:20px;box-shadow:var(--shadow-soft)}
.profile-summary-card{text-align:center}
.profile-summary-card>img{width:112px;height:112px;border-radius:28px;object-fit:cover;background:var(--surface-soft);margin-bottom:14px}
.profile-summary-card .profile-identity>strong{font-size:14px;display:block;overflow-wrap:anywhere}
.profile-summary-card .profile-avatar-actions{justify-content:center}
.profile-signout{display:block;margin:18px auto 0;text-align:center}
.profile-main-card .profile-form{border:0;padding:0;box-shadow:none}
.profile-save-success{display:flex;gap:11px;align-items:center;margin-top:14px;padding:13px 14px;border-radius:14px;background:#eaf8ef;color:#18733a}
.profile-save-success>span{width:30px;height:30px;border-radius:10px;display:grid;place-items:center;background:#fff;font-weight:900}
.profile-save-success strong{display:block;font-size:12px}
.profile-save-success small{display:block;font-size:9px;margin-top:2px;color:#367a4d}
.team-page-message{margin:0 0 10px}
.teams-library-head{margin-top:4px}

@media(min-width:760px){
  .profile-layout{grid-template-columns:260px minmax(0,1fr)}
}
@media(max-width:460px){
  .bottom-nav{height:62px;width:calc(100% - 16px);bottom:max(8px,env(safe-area-inset-bottom));padding:4px;border-radius:20px}
  .bottom-nav button{border-radius:15px}
  .bottom-nav button span{font-size:16px}
  .bottom-nav button small{font-size:8px}
}

.new-team-dialog{border:0;padding:0;background:transparent;max-width:none;max-height:none}
.new-team-dialog::backdrop{background:rgba(15,17,28,.48);backdrop-filter:blur(7px)}
.new-team-modal{width:min(calc(100vw - 28px),640px);background:var(--bg);border:1px solid rgba(255,255,255,.8);border-radius:26px;padding:18px;box-shadow:0 28px 90px rgba(20,22,34,.26)}
.new-team-modal-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:14px}
.new-team-modal-head h2{margin:0;font-size:28px;letter-spacing:-.04em}
.new-team-game-grid{display:grid;grid-template-columns:1fr;gap:10px}
.new-team-game{position:relative;overflow:hidden;border:0;border-radius:18px;padding:18px;text-align:left;color:#fff;min-height:105px;cursor:pointer;box-shadow:var(--shadow-soft);transition:transform .18s ease,box-shadow .18s ease}
.new-team-game:hover{transform:translateY(-2px);box-shadow:var(--shadow)}
.new-team-game:active{transform:scale(.99)}
.new-team-game strong{display:block;font-size:18px;letter-spacing:-.025em;margin-bottom:5px}
.new-team-game span{font-size:11px;font-weight:700;opacity:.82}
.new-team-game.champions{background:linear-gradient(135deg,#5751d6,#57b9ec)}
@media(min-width:620px){.new-team-game-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.new-team-modal{padding:22px}.new-team-game{min-height:120px}}

.new-team-game{display:flex;flex-direction:column;justify-content:space-between;gap:14px;min-height:168px}
.new-team-game-logos{height:64px;display:flex;align-items:center;justify-content:flex-start;gap:12px;position:relative;z-index:1}
.new-team-game-logos img{display:block;width:auto;max-width:100%;object-fit:contain;filter:drop-shadow(0 6px 10px rgba(0,0,0,.22))}
.new-team-game-logos.single img{max-height:58px;max-width:190px}
.new-team-game-logos.dual img{max-height:60px;max-width:46%}
.new-team-game-logos.generic img{max-height:54px;max-width:96px;filter:drop-shadow(0 5px 9px rgba(0,0,0,.16))}
.new-team-game-copy{position:relative;z-index:1}
.new-team-game-copy strong{margin-bottom:5px}
@media(max-width:619px){
  .new-team-game{min-height:145px}
  .new-team-game-logos{height:52px}
  .new-team-game-logos.single img{max-height:48px}
  .new-team-game-logos.dual img{max-height:50px}
}

/* Game logo polish */
.new-team-game{align-items:center;text-align:center}
.new-team-game-logos{justify-content:center;width:100%}
.new-team-game-copy{text-align:center;width:100%}

.home-game-logos{position:absolute;left:22px;top:18px;z-index:3;height:58px;display:flex;align-items:center;gap:8px;pointer-events:none}
.home-game-logos img{display:block;width:auto;object-fit:contain;filter:drop-shadow(0 5px 9px rgba(0,0,0,.22))}
.home-game-logos.single img{max-height:54px;max-width:170px}
.home-game-logos.dual img{max-height:50px;max-width:82px}
.home-game-logos.generic img{max-height:48px;max-width:94px}

.teams-library .cloud-team-open{grid-template-columns:110px minmax(0,1fr) 112px}
.cloud-team-copy{min-width:0}
.cloud-game-logos{height:54px;display:flex;align-items:center;justify-content:center;gap:5px;min-width:0}
.cloud-game-logos img{display:block;width:auto;max-width:100%;object-fit:contain;filter:drop-shadow(0 3px 5px rgba(0,0,0,.12))}
.cloud-game-logos.single img{max-height:44px;max-width:104px}
.cloud-game-logos.dual img{max-height:42px;max-width:49%}
.cloud-game-logos.generic img{max-height:40px;max-width:76px}

@media(max-width:619px){
  .home-game-logos{left:18px;top:16px;height:50px}
  .home-game-logos.single img{max-height:46px;max-width:145px}
  .home-game-logos.dual img{max-height:43px;max-width:70px}
  .teams-library .cloud-team-open{grid-template-columns:92px minmax(0,1fr) 82px}
  .cloud-game-logos.single img{max-width:78px}
}

.save-team-dialog{border:0;padding:0;background:transparent;max-width:none;max-height:none}
.save-team-dialog::backdrop{background:rgba(15,17,28,.48);backdrop-filter:blur(7px)}
.save-team-modal{width:min(calc(100vw - 28px),470px);background:var(--bg);border:1px solid rgba(255,255,255,.82);border-radius:26px;padding:22px;box-shadow:0 28px 90px rgba(20,22,34,.26)}
.save-team-modal-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:18px}
.save-team-modal-head h2{margin:0;font-size:28px;letter-spacing:-.04em}
.save-team-name-field{display:grid;gap:7px}
.save-team-name-field span{font-size:11px;font-weight:850;color:var(--muted)}
.save-team-name-field input{width:100%}
.save-team-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:18px}
.save-team-actions .button{width:100%}
@media(max-width:460px){.save-team-modal{padding:18px}.save-team-actions{grid-template-columns:1fr}}


/* Team sheet visual refresh */
.paper-header{background:linear-gradient(135deg,rgba(var(--accent-rgb),.07),transparent 65%);border-radius:14px 14px 0 0;padding:14px 14px 13px;border-bottom:2px solid var(--accent)}
.paper-brand>span,.print-head>div>span{display:block;font-size:7px;font-weight:950;letter-spacing:.16em;color:var(--accent);margin-bottom:3px}
.paper-team{gap:11px}
.paper-mon{grid-template-columns:96px 1fr;border-color:#dcdde5;border-radius:16px;min-height:154px;box-shadow:0 3px 10px rgba(31,34,48,.035)}
.paper-mon-art{background:radial-gradient(circle at 50% 48%,rgba(var(--accent-rgb),.10),#f7f7fa 68%)}
.paper-mon-art img{width:92px;height:92px;filter:drop-shadow(0 7px 8px rgba(31,34,48,.10))}
.paper-mon-body{padding:11px 12px}
.paper-mon-top{align-items:flex-start;margin-bottom:7px}
.paper-mon-name{font-size:15px;letter-spacing:-.02em}
.paper-level{font-size:8px;font-weight:850;color:#676a76;background:#f0f1f5;padding:5px 7px;border-radius:999px;white-space:nowrap}
.paper-mon-types,.print-mon-types{display:flex;gap:4px;flex-wrap:wrap;margin-top:4px}
.mon-type{display:inline-flex;align-items:center;border-radius:999px;padding:2px 6px;color:#fff;font-size:6px;font-weight:900;text-transform:uppercase;letter-spacing:.035em;background:#969aa3}
.paper-details{display:grid;grid-template-columns:1fr 1fr;gap:6px;margin-bottom:7px}
.paper-details>div{min-width:0;background:#f7f7f9;border-radius:7px;padding:5px 7px}
.paper-details small{display:block;font-size:6px;color:#7a7c87;text-transform:uppercase;font-weight:850}
.paper-details strong{display:block;font-size:8px;margin-top:1px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.paper-moves{gap:5px 7px}
.paper-move,.print-move{--move-type:#9da2aa;position:relative;overflow:hidden;border:1px solid #e0e1e7;background:#fff;color:#181a22}
.paper-move{min-height:28px;border-radius:7px;padding:6px 33px 5px 8px}
.paper-move-name,.print-move-name{position:relative;z-index:2;font-weight:850}
.paper-move-name{display:block;font-size:8px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.paper-move small,.print-move small{position:relative;z-index:2;display:block;color:#82848d;font-weight:650}
.paper-move small{font-size:5.5px;margin-top:1px}
.paper-move:after,.print-move:after{content:"";position:absolute;z-index:0;right:0;top:0;width:40px;height:100%;background:var(--move-type);clip-path:polygon(40% 0,100% 0,100% 100%,0 100%)}
.move-type-badge{position:absolute;z-index:2;right:5px;top:50%;transform:translateY(-50%);width:21px;height:21px;border-radius:50%;display:grid;place-items:center;background:rgba(255,255,255,.92);color:#23252e;border:1px solid rgba(0,0,0,.14);font-size:5.5px;font-weight:950;line-height:1}
.paper-extra{margin-top:6px}

.move-type-normal{--move-type:#929da3}.move-type-fire{--move-type:#ff9d55}.move-type-water{--move-type:#5090d6}
.move-type-electric{--move-type:#f4d23c}.move-type-grass{--move-type:#63bc5a}.move-type-ice{--move-type:#73cec0}
.move-type-fighting{--move-type:#ce416b}.move-type-poison{--move-type:#aa6bc8}.move-type-ground{--move-type:#d97845}
.move-type-flying{--move-type:#89aae3}.move-type-psychic{--move-type:#fa7179}.move-type-bug{--move-type:#91c12f}
.move-type-rock{--move-type:#c5b78c}.move-type-ghost{--move-type:#5269ad}.move-type-dragon{--move-type:#0b6dc3}
.move-type-dark{--move-type:#5a5465}.move-type-steel{--move-type:#5a8ea2}.move-type-fairy{--move-type:#ec8fe6}
.move-type-unknown{--move-type:#a5a8b0}

.type-normal{background:#929da3}.type-fire{background:#ff7b42}.type-water{background:#4389cf}.type-electric{background:#d8b616;color:#222}
.type-grass{background:#4fae48}.type-ice{background:#58bcae}.type-fighting{background:#c53861}.type-poison{background:#995ab9}
.type-ground{background:#c86634}.type-flying{background:#7397d5}.type-psychic{background:#e96069}.type-bug{background:#7daa21}
.type-rock{background:#a79b72}.type-ghost{background:#42599a}.type-dragon{background:#075aa5}.type-dark{background:#4a4554}
.type-steel{background:#497b8e}.type-fairy{background:#d878d2}

@media print{
  *{-webkit-print-color-adjust:exact!important;print-color-adjust:exact!important}
  .print-head{border-bottom:2pt solid var(--accent);padding:2mm 2mm 3mm;background:linear-gradient(135deg,rgba(var(--accent-rgb),.06),transparent 70%)}
  .print-mon{border:.7pt solid #c7c8cf;border-radius:3.4mm;min-height:80mm}
  .print-mon-head{grid-template-columns:29mm 1fr;background:linear-gradient(90deg,#f4f5f8,#fff);min-height:30mm}
  .print-mon-art img{width:27mm;height:27mm;filter:drop-shadow(0 2mm 2mm rgba(0,0,0,.08))}
  .print-mon-title{padding:3.5mm 3mm 2mm 0}
  .print-title-line{display:flex;align-items:flex-start;justify-content:space-between;gap:2mm}
  .print-title-line h2{min-width:0}
  .print-title-line>span{font-size:6.5pt;font-weight:700;color:#666;white-space:nowrap;padding-top:.5mm}
  .print-mon-types{margin-top:1.2mm;gap:1mm}
  .print-mon-types .mon-type{font-size:4.5pt;padding:.6mm 1.3mm}
  .print-mon-title p{margin-top:1.2mm}
  .print-moves{gap:1.3mm 1.6mm}
  .print-move{min-height:8.5mm;padding:1.45mm 9mm 1.1mm 2.2mm;border-radius:1.4mm}
  .print-move-name{display:block;font-size:7.2pt;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .print-move small{font-size:4.4pt;margin-top:.35mm}
  .print-move:after{width:10mm}
  .print-move .move-type-badge{right:1.2mm;width:5.6mm;height:5.6mm;font-size:4pt;border-width:.35pt}
  .print-stats{margin-top:2.2mm}
}

/* Use uploaded game-style type icons from /images/types */
.move-type-badge{background:transparent;border:0;width:24px;height:24px;right:4px}
.move-type-icon{display:block;width:24px;height:24px;object-fit:contain;filter:drop-shadow(0 1px 1px rgba(0,0,0,.18))}
.mon-type{gap:3px;padding:2px 6px 2px 3px}
.mon-type-icon{display:block;width:13px;height:13px;object-fit:contain;flex:0 0 13px}
.mon-type>span{line-height:1}

@media print{
  .print-move .move-type-badge{width:6mm;height:6mm;right:1mm}
  .print-move .move-type-icon{width:6mm;height:6mm}
  .print-mon-types .mon-type{display:inline-flex;align-items:center;gap:.7mm;padding:.45mm 1.2mm .45mm .6mm}
  .print-mon-types .mon-type-icon{width:3.4mm;height:3.4mm;flex-basis:3.4mm}
}

/* Compact type icons */
.move-type-badge{width:19px;height:19px;right:5px}
.move-type-icon{width:19px;height:19px}
.mon-type-icon{width:10px;height:10px;flex-basis:10px}
.paper-move:after,.print-move:after{width:33px}

@media print{
  .print-move{padding-right:7.5mm}
  .print-move:after{width:8mm}
  .print-move .move-type-badge{width:4.5mm;height:4.5mm;right:1.1mm}
  .print-move .move-type-icon{width:4.5mm;height:4.5mm}
  .print-mon-types .mon-type-icon{width:2.6mm;height:2.6mm;flex-basis:2.6mm}
}

/* Centre the new 73x73 white type glyphs inside their colour wedges */
.move-type-badge{
  top:0;
  right:0;
  transform:none;
  width:33px;
  height:100%;
  display:flex;
  align-items:center;
  justify-content:center;
}
.move-type-icon{
  width:16px;
  height:16px;
  object-fit:contain;
  object-position:center;
  margin:0;
}
.mon-type-icon{
  width:10px;
  height:10px;
  object-fit:contain;
  object-position:center;
  margin:0;
}

@media print{
  .print-move .move-type-badge{
    top:0;
    right:0;
    transform:none;
    width:8mm;
    height:100%;
    display:flex;
    align-items:center;
    justify-content:center;
  }
  .print-move .move-type-icon{
    width:4mm;
    height:4mm;
    object-fit:contain;
    object-position:center;
    margin:0;
  }
}

/* Visually centre glyphs within the clipped move wedge */
.move-type-badge{
  justify-content:flex-end;
  padding-right:6px;
}
@media print{
  .print-move .move-type-badge{
    justify-content:flex-end;
    padding-right:1.2mm;
  }
}

/* Held item artwork from PokéAPI */
.paper-item-detail,.print-item-detail{display:flex;align-items:center;min-width:0}
.paper-item-detail{gap:5px;margin-top:1px}
.paper-item-detail img{width:18px;height:18px;object-fit:contain;image-rendering:auto;flex:0 0 18px}
.paper-item-detail strong{min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

@media print{
  .print-item-detail{gap:1mm;min-width:0}
  .print-item-detail img{width:4.5mm;height:4.5mm;object-fit:contain;flex:0 0 4.5mm}
  .print-item-detail strong{font-weight:400;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
}

/* Prominent Stat Alignment / Nature and Gender */
.paper-traits,.print-traits{display:flex;gap:5px;flex-wrap:wrap;margin-top:5px}
.paper-trait-chip{display:inline-flex;align-items:center;gap:4px;min-height:22px;border-radius:7px;padding:3px 6px;background:#f0f1f5;border:1px solid #e1e2e8}
.paper-trait-chip small{font-size:5px;text-transform:uppercase;letter-spacing:.04em;color:#777a86;font-weight:850}
.paper-trait-chip strong{font-size:7px}
.nature-effects{display:inline-flex;gap:3px;margin-left:1px}
.nature-effects b{font-size:5.5px;padding:1px 3px;border-radius:4px}
.nature-up{color:#167841;background:#e5f5ea}
.nature-down{color:#ad3e49;background:#fae8ea}
.gender-chip b{font-size:10px;line-height:1}
.gender-chip.male b{color:#277bd8}
.gender-chip.female b{color:#d14f8e}
.gender-chip.neutral b{color:#767985}

@media print{
  .print-traits{gap:1mm;margin-top:1mm}
  .print-trait-chip{display:inline-flex;align-items:center;gap:.8mm;min-height:4.4mm;border-radius:1.2mm;padding:.45mm 1mm;background:#f0f1f5;border:.35pt solid #dedfe5}
  .print-trait-chip small{font-size:3.6pt;text-transform:uppercase;color:#777;font-weight:700}
  .print-trait-chip strong{font-size:5pt}
  .print-trait-chip .nature-effects{gap:.6mm}
  .print-trait-chip .nature-effects b{font-size:3.6pt;padding:.25mm .6mm}
  .print-trait-chip.gender-chip b{font-size:6pt}
}

/* Keep a full six-Pokémon team comfortably on one A4 page */
@media print{
  .print-sheet{padding:0}
  .print-head{padding:1.5mm 1.5mm 2.2mm}
  .print-team{gap:2mm 2.4mm}
  .print-mon{
    min-height:0;
    break-inside:avoid;
    page-break-inside:avoid;
  }
  .print-mon-head{
    grid-template-columns:23mm 1fr;
    min-height:23mm;
  }
  .print-mon-art{
    min-height:23mm;
  }
  .print-mon-art img{
    width:21mm;
    height:21mm;
  }
  .print-mon-title{
    padding:2.3mm 2.2mm 1.4mm 0;
  }
  .print-mon-title p{
    margin-top:.7mm;
  }
  .print-mon-body{
    padding:1.8mm 2mm 2mm;
  }
  .print-row{
    min-height:4.4mm;
  }
  .print-moves{
    margin-top:1.4mm;
    gap:1mm 1.3mm;
  }
  .print-move{
    min-height:7mm;
    padding-top:1mm;
    padding-bottom:.8mm;
  }
  .print-stats{
    margin-top:1.5mm;
  }
  .print-foot{
    margin-top:1.8mm;
  }
}

/* Rebalance A4 density: roomier than the compact pass while keeping six on one page */
@media print{
  .print-head{padding:1.8mm 1.8mm 2.6mm;margin-bottom:2.8mm}
  .print-team{gap:2.5mm 2.7mm}

  .print-mon-head{
    grid-template-columns:26mm 1fr;
    min-height:26mm;
  }
  .print-mon-art{min-height:26mm}
  .print-mon-art img{
    width:24mm;
    height:24mm;
  }
  .print-mon-title{
    padding:2.8mm 2.5mm 1.8mm 0;
  }

  .print-mon-body{
    padding:2.3mm 2.3mm 2.4mm;
  }
  .print-row{
    min-height:4.8mm;
    margin-bottom:1mm;
  }
  .print-moves{
    margin-top:1.7mm;
    gap:1.15mm 1.5mm;
  }
  .print-move{
    min-height:7.8mm;
    padding-top:1.2mm;
    padding-bottom:1mm;
  }
  .print-stats{margin-top:1.9mm}
  .print-foot{margin-top:2.2mm}
}

/* Builder page visual refresh */
.builder-hero{
  min-height:168px;
  padding:24px 0 22px;
  align-items:flex-end;
}
.builder-hero:after{
  content:"";
  position:absolute;
  right:-40px;
  bottom:5px;
  width:310px;
  height:135px;
  border-radius:50%;
  background:radial-gradient(circle,rgba(var(--accent-rgb),.12),transparent 68%);
  pointer-events:none;
}
.builder-hero h1{font-size:clamp(40px,5.4vw,62px)}
.builder-game-art{
  width:176px;
  height:142px;
  z-index:1;
}

.details-card{
  position:relative;
  overflow:hidden;
  padding:23px;
  border-color:rgba(var(--accent-rgb),.12);
  background:linear-gradient(145deg,#fff 0 68%,rgba(var(--accent-rgb),.035) 100%);
  box-shadow:0 14px 42px rgba(31,34,48,.07);
}
.details-card:before{
  content:"";
  position:absolute;
  left:0;
  top:0;
  bottom:0;
  width:4px;
  background:linear-gradient(var(--accent),var(--accent-2));
}
.details-card .section-heading.compact{padding-left:3px}
.details-grid{gap:14px}
.details-grid label>span{
  margin-left:2px;
  color:#696b7a;
}
.details-grid input{
  background:rgba(248,249,253,.82);
  border-color:#dfe1eb;
}
.details-grid input:focus{background:#fff}

.team-heading{
  margin-top:34px!important;
  margin-bottom:15px!important;
}
.team-heading h2{font-size:24px!important}
.completion{
  display:inline-flex;
  align-items:center;
  gap:5px;
  background:#e9eaf0;
  transition:.2s ease;
}
.completion.is-complete{
  color:#176e43;
  background:#e4f5eb;
  box-shadow:inset 0 0 0 1px #c9ead7;
}

.team-grid{gap:14px}
.team-slot{
  min-height:268px;
  padding:0;
  border-radius:24px;
  border-color:#e1e3ec;
  background:linear-gradient(180deg,#fff,#fcfcfe);
  box-shadow:0 11px 32px rgba(31,34,48,.065);
}
.team-slot:hover{
  border-color:rgba(var(--accent-rgb),.38);
  transform:translateY(-3px);
  box-shadow:0 16px 38px rgba(31,34,48,.10);
}
.team-slot:not(.empty):before{
  content:"";
  position:absolute;
  inset:0 0 auto 0;
  height:3px;
  background:linear-gradient(90deg,var(--accent),var(--accent-2));
  opacity:.9;
}
.team-slot.empty{
  min-height:268px;
  border:1.5px dashed #d7d9e5;
  background:linear-gradient(145deg,rgba(255,255,255,.76),rgba(var(--accent-rgb),.025));
}
.team-slot.empty:hover{
  border-color:rgba(var(--accent-rgb),.42);
  background:rgba(var(--accent-rgb),.035);
}
.add-orb{
  width:52px;
  height:52px;
  border-radius:18px;
  box-shadow:inset 0 0 0 1px rgba(var(--accent-rgb),.08);
}
.slot-number{
  left:14px;
  top:13px;
  padding:4px 7px;
  border-radius:999px;
  background:rgba(245,246,250,.9);
  color:#696c7c;
  backdrop-filter:blur(5px);
}
.slot-edit{
  position:absolute;
  right:14px;
  top:14px;
  z-index:3;
  display:flex;
  align-items:center;
  gap:3px;
  font-size:9px;
  font-weight:850;
  color:#838694;
  opacity:.75;
}
.slot-edit span{font-size:15px;line-height:.7}
.team-slot:hover .slot-edit{color:var(--accent);opacity:1}

.slot-img{
  height:142px;
  margin:0;
  padding-top:15px;
  border-bottom:1px solid #f0f1f5;
  background:
    radial-gradient(circle at 50% 52%,rgba(var(--accent-rgb),.12),transparent 42%),
    linear-gradient(180deg,rgba(var(--accent-rgb),.025),transparent);
}
.slot-img img{
  width:138px;
  height:138px;
  filter:drop-shadow(0 12px 13px rgba(31,34,48,.14));
}
.slot-copy{padding:12px 14px 14px}
.slot-name{
  font-size:17px;
  line-height:1.15;
  padding-right:2px;
}
.slot-types{
  margin-top:7px;
  gap:5px;
}
.slot-types .type-pill{
  display:inline-flex;
  align-items:center;
  gap:3px;
  padding:3px 6px 3px 4px;
  color:#fff;
  font-size:7px;
  line-height:1;
}
.slot-types .type-pill.type-electric{color:#222}
.slot-type-icon{
  width:11px;
  height:11px;
  object-fit:contain;
}
.slot-traits{
  display:flex;
  gap:5px;
  flex-wrap:wrap;
  margin-top:7px;
}
.slot-trait{
  font-size:8px;
  font-weight:800;
  color:#656877;
  background:#f0f1f5;
  border-radius:999px;
  padding:4px 6px;
}
.slot-trait.gender-male{color:#277bd8;background:#eaf2fd}
.slot-trait.gender-female{color:#c84784;background:#fbeaf2}
.slot-trait.gender-genderless{color:#6f7280}

.slot-info-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:7px;
  margin-top:10px;
  padding-top:9px;
  border-top:1px solid #eeeef3;
}
.slot-info-grid>div{min-width:0}
.slot-info-grid small{
  display:block;
  margin-bottom:2px;
  font-size:7px;
  font-weight:850;
  text-transform:uppercase;
  letter-spacing:.045em;
  color:#9a9ca8;
}
.slot-info-grid span{
  display:flex;
  align-items:center;
  min-width:0;
  font-size:9px;
  font-weight:750;
  color:#545663;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.slot-info-value{gap:4px}
.slot-item-icon{
  width:16px;
  height:16px;
  object-fit:contain;
  flex:0 0 16px;
}

.builder-actions{
  position:sticky;
  bottom:84px;
  z-index:12;
  width:max-content;
  max-width:100%;
  margin:26px 0 8px auto;
  padding:7px;
  border:1px solid rgba(255,255,255,.88);
  border-radius:19px;
  background:rgba(255,255,255,.84);
  backdrop-filter:blur(16px);
  box-shadow:0 14px 38px rgba(31,34,48,.13);
}

@media(min-width:700px){
  .team-slot{min-height:286px}
  .team-slot.empty{min-height:286px}
}

@media(max-width:699px){
  .builder-hero{min-height:150px}
  .details-card{padding:18px}
  .team-grid{grid-template-columns:1fr}
  .team-slot,.team-slot.empty{min-height:260px}
  .slot-img{height:135px}
  .slot-img img{width:132px;height:132px}
  .builder-actions{
    position:static;
    width:100%;
    margin-top:20px;
    padding:0;
    border:0;
    background:transparent;
    box-shadow:none;
    backdrop-filter:none;
  }
}

/* Keep builder actions anchored directly below the team grid */
.builder-actions{
  position:static;
  bottom:auto;
  width:100%;
  max-width:none;
  margin:22px 0 8px;
  justify-content:flex-end;
  padding:0;
  border:0;
  border-radius:0;
  background:transparent;
  backdrop-filter:none;
  box-shadow:none;
}

/* Team defensive insights */
.team-insights{
  margin-top:24px;
  padding:22px;
  border:1px solid rgba(var(--accent-rgb),.13);
  border-radius:24px;
  background:linear-gradient(145deg,rgba(255,255,255,.95),rgba(var(--accent-rgb),.035));
  box-shadow:0 10px 32px rgba(31,34,48,.055);
}
.team-insights:empty{display:none}
.team-insights-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:18px;
  margin-bottom:15px;
}
.team-insights-head h2{margin:0;font-size:22px;letter-spacing:-.035em}
.insight-summary-stats{display:flex;gap:7px;flex-wrap:wrap;justify-content:flex-end}
.insight-summary-stats span{
  display:flex;align-items:baseline;gap:4px;padding:6px 9px;border-radius:999px;
  background:#f0f1f5;color:#747684;font-size:9px;font-weight:750;
}
.insight-summary-stats strong{font-size:12px;color:var(--text)}
.team-insights-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.insight-panel{
  min-width:0;padding:15px;border-radius:18px;border:1px solid #e7e8ee;background:rgba(255,255,255,.84)
}
.weakness-panel{background:linear-gradient(145deg,#fff,rgba(210,74,87,.04))}
.answer-panel{background:linear-gradient(145deg,#fff,rgba(46,147,101,.04))}
.insight-panel-title{display:flex;gap:9px;align-items:flex-start;margin-bottom:12px}
.insight-symbol{
  width:27px;height:27px;flex:0 0 27px;display:grid;place-items:center;border-radius:9px;
  font-size:11px;font-weight:950
}
.weakness-panel .insight-symbol{color:#b54755;background:#fae9ec}
.answer-panel .insight-symbol{color:#23794d;background:#e7f5ed}
.insight-panel h3{margin:0;font-size:13px}
.insight-panel p{margin:3px 0 0;color:var(--muted);font-size:9px;line-height:1.45}
.insight-types{display:grid;grid-template-columns:1fr 1fr;gap:7px}
.insight-type{
  display:flex;align-items:center;gap:7px;min-width:0;padding:7px 8px;border-radius:11px;color:#fff
}
.insight-type.type-electric{color:#252525}
.insight-type-icon{width:18px;height:18px;flex:0 0 18px;object-fit:contain}
.insight-type>span{min-width:0}
.insight-type strong{display:block;font-size:9px;line-height:1.1}
.insight-type small{
  display:block;margin-top:2px;font-size:7px;font-weight:750;opacity:.84;white-space:nowrap;overflow:hidden;text-overflow:ellipsis
}
.insight-note{margin:11px 1px 0!important;color:#8a8c98!important;font-size:8px!important}
.team-insights-empty{display:flex;flex-direction:column;align-items:flex-start;gap:2px;color:var(--muted);font-size:11px}
.team-insights-empty .eyebrow{margin-bottom:2px}

@media(max-width:699px){
  .team-insights{padding:17px;margin-top:18px}
  .team-insights-head{align-items:flex-start;flex-direction:column}
  .insight-summary-stats{justify-content:flex-start}
  .team-insights-grid{grid-template-columns:1fr}
}
@media(max-width:420px){.insight-types{grid-template-columns:1fr}}

/* Improve Team Insights readability */
.team-insights-head h2{font-size:25px}
.insight-summary-stats span{font-size:11px;padding:7px 10px}
.insight-summary-stats strong{font-size:14px}
.insight-panel h3{font-size:15px}
.insight-panel p{font-size:11px;line-height:1.5}
.insight-type{padding:9px 10px;gap:8px}
.insight-type-icon{width:21px;height:21px;flex-basis:21px}
.insight-type strong{font-size:11px}
.insight-type small{font-size:9px;margin-top:3px}
.insight-note{font-size:10px!important;line-height:1.5!important}
.team-insights-empty{font-size:13px}

@media(max-width:699px){
  .team-insights-head h2{font-size:23px}
  .insight-panel h3{font-size:15px}
  .insight-panel p{font-size:11px}
  .insight-type strong{font-size:11px}
  .insight-type small{font-size:9px}
  .insight-note{font-size:10px!important}
}

/* Readability pass for team cards and insights */
.slot-trait{
  font-size:10px;
  padding:5px 7px;
}
.slot-info-grid small{
  font-size:9px;
  margin-bottom:3px;
}
.slot-info-grid span{
  font-size:11px;
  line-height:1.25;
}
.slot-item-icon{
  width:18px;
  height:18px;
  flex-basis:18px;
}

.team-insights-head h2{font-size:27px}
.insight-summary-stats span{font-size:12px;padding:8px 11px}
.insight-summary-stats strong{font-size:15px}
.insight-panel{padding:17px}
.insight-panel h3{font-size:17px}
.insight-panel p{font-size:13px;line-height:1.5}
.insight-symbol{
  width:30px;
  height:30px;
  flex-basis:30px;
  font-size:13px;
}
.insight-type{
  padding:10px 11px;
  gap:9px;
}
.insight-type-icon{
  width:23px;
  height:23px;
  flex-basis:23px;
}
.insight-type strong{font-size:13px}
.insight-type small{font-size:10px;margin-top:3px}
.insight-note{font-size:11px!important;line-height:1.55!important}

@media(max-width:699px){
  .slot-trait{font-size:11px;padding:5px 8px}
  .slot-info-grid small{font-size:9px}
  .slot-info-grid span{font-size:12px}
  .team-insights-head h2{font-size:25px}
  .insight-summary-stats span{font-size:11px}
  .insight-summary-stats strong{font-size:14px}
  .insight-panel h3{font-size:16px}
  .insight-panel p{font-size:12px}
  .insight-type strong{font-size:12px}
  .insight-type small{font-size:10px}
  .insight-note{font-size:11px!important}
}

/* Experimental Play! Pokémon player QR */
.play-qr-card{
  margin-top:24px;
  padding:20px;
  border:1px solid rgba(var(--accent-rgb),.16);
  border-radius:22px;
  background:linear-gradient(145deg,#fff,rgba(var(--accent-rgb),.035));
}
.play-qr-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px}
.play-qr-title-row{display:flex;align-items:center;gap:9px;flex-wrap:wrap}
.play-qr-title-row h2{margin:0;font-size:21px;letter-spacing:-.035em}
.experimental-badge{
  display:inline-flex;align-items:center;min-height:24px;padding:0 8px;border-radius:999px;
  background:#fff1d7;color:#8a5a00;border:1px solid #f1d49b;font-size:9px;font-weight:900;text-transform:uppercase;letter-spacing:.06em
}
.play-qr-intro{margin:8px 0 17px;color:var(--muted);font-size:11px;line-height:1.55;max-width:650px}
.play-qr-layout{display:grid;grid-template-columns:minmax(220px,300px) 1fr;gap:18px;align-items:center}
.play-qr-box{
  aspect-ratio:1;border-radius:18px;border:1px solid #dedfe7;background:#fff;padding:13px;
  display:grid;place-items:center;box-shadow:inset 0 0 0 5px #fafafe
}
.play-qr-box canvas{display:block;width:100%;height:auto;image-rendering:pixelated}
.play-qr-placeholder{text-align:center;color:var(--muted);padding:25px}
.play-qr-placeholder strong{display:block;color:var(--text);font-size:13px}
.play-qr-placeholder span{display:block;margin-top:5px;font-size:10px;line-height:1.45}
.play-qr-details{display:grid;grid-template-columns:1fr 1fr;gap:9px}
.play-qr-details>div{
  min-width:0;padding:11px 12px;border:1px solid #e8e9ef;border-radius:13px;background:rgba(255,255,255,.8)
}
.play-qr-details small{
  display:block;margin-bottom:3px;color:#9294a0;font-size:8px;font-weight:850;text-transform:uppercase;letter-spacing:.05em
}
.play-qr-details strong{display:block;font-size:13px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.play-qr-expiry{grid-column:1/-1}
.play-qr-warning{
  display:flex;gap:8px;align-items:flex-start;margin-top:15px;padding:11px 12px;border-radius:13px;
  background:#fff7e8;border:1px solid #f1ddb6;color:#725521;font-size:10px;line-height:1.5
}
.play-qr-warning strong{flex:0 0 auto}
@media(max-width:700px){
  .play-qr-card{padding:16px}
  .play-qr-layout{grid-template-columns:1fr}
  .play-qr-box{width:min(100%,330px);margin:0 auto}
  .play-qr-details strong{font-size:14px}
  .play-qr-intro,.play-qr-warning{font-size:11px}
}

/* Community stats */
.bottom-nav{
  grid-template-columns:repeat(5,minmax(0,1fr));
  width:min(calc(100% - 24px),620px);
}
.stats-page-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:24px;
  padding:38px 0 24px;
}
.stats-page-head h1{
  margin:0;
  font-size:clamp(42px,6vw,64px);
  line-height:.98;
  letter-spacing:-.055em;
}
.stats-page-head p{
  margin:10px 0 0;
  color:var(--muted);
  font-size:13px;
  line-height:1.5;
}
.stats-updated{
  flex:0 0 auto;
  padding:8px 11px;
  border-radius:999px;
  background:#e9eaf0;
  color:var(--muted);
  font-size:10px;
  font-weight:800;
}
.stats-overview-grid{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:12px;
  margin-bottom:14px;
}
.stats-metric{
  display:flex;
  align-items:center;
  gap:12px;
  min-width:0;
  padding:18px;
  border:1px solid var(--line);
  border-radius:20px;
  background:linear-gradient(145deg,#fff,rgba(var(--accent-rgb),.035));
  box-shadow:var(--shadow-soft);
}
.stats-metric-icon{
  width:42px;
  height:42px;
  flex:0 0 42px;
  display:grid;
  place-items:center;
  border-radius:14px;
  background:rgba(var(--accent-rgb),.10);
  color:var(--accent);
  font-size:19px;
  font-weight:900;
}
.stats-metric strong{
  display:block;
  font-size:25px;
  line-height:1;
  letter-spacing:-.04em;
}
.stats-metric small{
  display:block;
  margin-top:5px;
  color:var(--muted);
  font-size:10px;
  font-weight:750;
}
.stats-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:14px;
}
.stats-panel{
  min-width:0;
  padding:19px;
  border:1px solid var(--line);
  border-radius:22px;
  background:rgba(255,255,255,.92);
  box-shadow:var(--shadow-soft);
}
.stats-popular-pokemon{grid-row:span 2}
.stats-panel-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:15px;
  margin-bottom:14px;
}
.stats-panel-head h2{
  margin:0;
  font-size:20px;
  letter-spacing:-.035em;
}
.stats-panel-note{
  color:var(--muted);
  font-size:9px;
  font-weight:750;
  text-align:right;
}
.stats-pokemon-list{display:grid;gap:7px}
.stats-pokemon-row{
  position:relative;
  display:grid;
  grid-template-columns:26px 52px 1fr;
  align-items:center;
  gap:9px;
  min-height:61px;
  padding:6px 8px 9px;
  overflow:hidden;
  border:1px solid #ececf1;
  border-radius:14px;
  background:#fbfbfd;
}
.stats-pokemon-rank{
  display:grid;
  place-items:center;
  width:24px;
  height:24px;
  border-radius:8px;
  background:#eeeff4;
  color:#777a88;
  font-size:9px;
  font-weight:900;
}
.stats-pokemon-art{
  width:52px;
  height:48px;
  display:grid;
  place-items:center;
}
.stats-pokemon-art img{
  width:54px;
  height:54px;
  object-fit:contain;
  filter:drop-shadow(0 5px 6px rgba(31,34,48,.10));
}
.stats-pokemon-copy{min-width:0}
.stats-pokemon-copy strong{
  display:block;
  font-size:12px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.stats-pokemon-copy span{
  display:block;
  margin-top:3px;
  color:var(--muted);
  font-size:9px;
}
.stats-pokemon-bar{
  position:absolute;
  left:95px;
  right:8px;
  bottom:5px;
  height:3px;
  overflow:hidden;
  border-radius:999px;
  background:#e9eaf0;
}
.stats-pokemon-bar i{
  display:block;
  height:100%;
  border-radius:999px;
  background:linear-gradient(90deg,var(--accent),var(--accent-2));
}
.stats-bars{display:grid;gap:12px}
.stats-bar-row>div{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom:6px;
}
.stats-bar-row strong{font-size:11px}
.stats-bar-row>div span{color:var(--muted);font-size:9px}
.stats-bar-track{
  display:block;
  height:8px;
  overflow:hidden;
  border-radius:999px;
  background:#ebecef;
}
.stats-bar-track i{
  display:block;
  height:100%;
  border-radius:999px;
  background:linear-gradient(90deg,var(--accent),var(--accent-2));
}
.stats-ranked-list{display:grid;gap:7px}
.stats-ranked-row{
  display:grid;
  grid-template-columns:25px auto 1fr auto;
  align-items:center;
  gap:8px;
  min-height:42px;
  padding:6px 8px;
  border:1px solid #ededf1;
  border-radius:12px;
  background:#fbfbfd;
}
.stats-ranked-row>img{
  width:27px;
  height:27px;
  object-fit:contain;
}
.stats-rank{
  color:#8b8e99;
  font-size:9px;
  font-weight:900;
  text-align:center;
}
.stats-ranked-copy{min-width:0}
.stats-ranked-copy strong{
  display:block;
  font-size:10px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.stats-ranked-copy>span{
  display:block;
  height:3px;
  margin-top:5px;
  overflow:hidden;
  border-radius:999px;
  background:#e9eaf0;
}
.stats-ranked-copy i{
  display:block;
  height:100%;
  border-radius:999px;
  background:var(--accent);
}
.stats-ranked-value{text-align:right}
.stats-ranked-value strong{display:block;font-size:10px}
.stats-ranked-value small{display:block;margin-top:1px;color:var(--muted);font-size:7px}
.stats-growth-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
}
.stats-growth-grid>div{
  padding:18px;
  border-radius:16px;
  background:rgba(var(--accent-rgb),.06);
}
.stats-growth-grid strong{
  display:block;
  font-size:30px;
  line-height:1;
  letter-spacing:-.04em;
}
.stats-growth-grid span{
  display:block;
  margin-top:6px;
  color:var(--muted);
  font-size:10px;
  font-weight:750;
}
.stats-privacy-note{
  margin:16px 2px 0;
  color:#8b8d99;
  font-size:9px;
  line-height:1.5;
  text-align:center;
}
.stats-loading,.stats-error{
  min-height:280px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:8px;
  text-align:center;
  color:var(--muted);
}
.stats-loading strong,.stats-error strong{color:var(--text);font-size:15px}
.stats-error span{font-size:11px}
.stats-error .button{margin-top:8px}
.stats-spinner{
  width:34px;
  height:34px;
  border:3px solid #dedfe8;
  border-top-color:var(--accent);
  border-radius:50%;
  animation:statsSpin .8s linear infinite;
}
@keyframes statsSpin{to{transform:rotate(360deg)}}
.stats-empty{
  padding:20px 10px;
  color:var(--muted);
  font-size:10px;
  text-align:center;
}

@media(max-width:850px){
  .stats-overview-grid{grid-template-columns:repeat(2,1fr)}
}
@media(max-width:699px){
  .bottom-nav{width:calc(100% - 16px)}
  .bottom-nav button small{font-size:7.5px}
  .stats-page-head{align-items:flex-start;flex-direction:column;padding-top:28px}
  .stats-grid{grid-template-columns:1fr}
  .stats-popular-pokemon{grid-row:auto}
  .stats-panel{padding:16px}
  .stats-panel-head h2{font-size:19px}
}
@media(max-width:430px){
  .stats-overview-grid{grid-template-columns:1fr 1fr;gap:8px}
  .stats-metric{padding:13px;gap:9px}
  .stats-metric-icon{width:36px;height:36px;flex-basis:36px}
  .stats-metric strong{font-size:21px}
  .stats-metric small{font-size:9px}
  .stats-pokemon-row{grid-template-columns:24px 46px 1fr}
  .stats-pokemon-art,.stats-pokemon-art img{width:46px;height:46px}
  .stats-pokemon-bar{left:87px}
}

/* Stats readability pass */
.stats-page-head p{font-size:15px}
.stats-updated{font-size:12px;padding:9px 12px}
.stats-metric{padding:20px}
.stats-metric strong{font-size:30px}
.stats-metric small{font-size:12px;line-height:1.3}
.stats-panel{padding:21px}
.stats-panel-head h2{font-size:23px}
.stats-panel-note{font-size:11px}
.stats-pokemon-row{
  min-height:72px;
  grid-template-columns:30px 62px 1fr;
  gap:11px;
  padding:8px 10px 11px;
}
.stats-pokemon-rank{width:28px;height:28px;font-size:11px}
.stats-pokemon-art{width:62px;height:58px}
.stats-pokemon-art img{width:64px;height:64px}
.stats-pokemon-copy strong{font-size:14px}
.stats-pokemon-copy span{font-size:11px;margin-top:4px}
.stats-pokemon-bar{left:115px;right:10px;bottom:6px;height:4px}
.stats-bar-row strong{font-size:13px}
.stats-bar-row>div span{font-size:11px}
.stats-ranked-row{
  min-height:51px;
  grid-template-columns:28px auto 1fr auto;
  gap:10px;
  padding:8px 10px;
}
.stats-ranked-row>img{width:32px;height:32px}
.stats-rank{font-size:11px}
.stats-ranked-copy strong{font-size:13px}
.stats-ranked-copy>span{height:4px;margin-top:6px}
.stats-ranked-value strong{font-size:13px}
.stats-ranked-value small{font-size:9px;margin-top:2px}
.stats-growth-grid strong{font-size:36px}
.stats-growth-grid span{font-size:12px}
.stats-privacy-note{font-size:11px;line-height:1.55}
.stats-empty{font-size:12px}

@media(max-width:699px){
  .stats-page-head p{font-size:14px}
  .stats-updated{font-size:11px}
  .stats-metric strong{font-size:27px}
  .stats-metric small{font-size:11px}
  .stats-panel{padding:18px}
  .stats-panel-head h2{font-size:22px}
  .stats-panel-note{font-size:10px}
  .stats-pokemon-copy strong{font-size:14px}
  .stats-pokemon-copy span{font-size:11px}
  .stats-bar-row strong{font-size:13px}
  .stats-bar-row>div span{font-size:11px}
  .stats-ranked-copy strong{font-size:13px}
  .stats-ranked-value strong{font-size:13px}
  .stats-ranked-value small{font-size:9px}
  .stats-growth-grid span{font-size:11px}
  .stats-privacy-note{font-size:11px}
}
@media(max-width:430px){
  .stats-metric{padding:14px}
  .stats-metric strong{font-size:24px}
  .stats-pokemon-row{grid-template-columns:27px 52px 1fr;min-height:66px}
  .stats-pokemon-art,.stats-pokemon-art img{width:52px;height:52px}
  .stats-pokemon-bar{left:101px}
}

/* Pokémon Showdown import */
.team-heading-actions{display:flex;align-items:center;gap:9px}
.showdown-import-button{min-height:36px;padding:0 12px;border-radius:12px;font-size:11px}
.showdown-dialog{
  width:min(94vw,720px);
  max-height:90vh;
  padding:0;
  border:0;
  border-radius:24px;
  background:transparent;
  color:var(--text);
}
.showdown-dialog::backdrop{background:rgba(15,17,28,.48);backdrop-filter:blur(7px)}
.showdown-modal{
  padding:22px;
  border:1px solid rgba(255,255,255,.8);
  border-radius:24px;
  background:var(--bg);
  box-shadow:0 24px 80px rgba(0,0,0,.24);
}
.showdown-modal-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px}
.showdown-modal-head h2{margin:0;font-size:24px;letter-spacing:-.035em}
.showdown-intro{margin:9px 0 17px;color:var(--muted);font-size:12px;line-height:1.55}
.showdown-textarea-field>span{display:block;font-size:11px;font-weight:800;color:#5e6070;margin:0 0 6px}
.showdown-textarea-field textarea{
  display:block;
  width:100%;
  min-height:330px;
  resize:vertical;
  border:1px solid var(--line);
  border-radius:16px;
  background:#fff;
  padding:14px;
  color:var(--text);
  font:12px/1.5 ui-monospace,SFMono-Regular,Consolas,"Liberation Mono",monospace;
}
.showdown-textarea-field textarea:focus{outline:none;border-color:rgba(var(--accent-rgb),.55);box-shadow:0 0 0 4px rgba(var(--accent-rgb),.08)}
.showdown-note{margin:10px 2px 0;color:#858794;font-size:10px;line-height:1.5}
.showdown-import-status{min-height:20px;margin-top:9px;font-size:11px;font-weight:750;color:#27704b}
.showdown-import-status.is-error{color:var(--danger)}
.showdown-actions{display:flex;justify-content:flex-end;gap:9px;margin-top:10px}
.showdown-actions .button:disabled{opacity:.6;cursor:wait}

@media(max-width:699px){
  .team-heading{align-items:flex-start!important}
  .team-heading-actions{flex-direction:column;align-items:flex-end;gap:7px}
  .showdown-import-button{min-height:34px;font-size:10px}
  .showdown-modal{padding:17px}
  .showdown-modal-head h2{font-size:21px}
  .showdown-intro{font-size:11px}
  .showdown-textarea-field textarea{min-height:300px;font-size:11px}
  .showdown-actions{display:grid;grid-template-columns:1fr 1fr}
}

/* Legal consent, legal pages, and account deletion */
.legal-consent{
  display:flex!important;
  align-items:flex-start;
  gap:9px;
  padding:10px 11px;
  border:1px solid #e3e4eb;
  border-radius:12px;
  background:#fafafe;
}
.legal-consent input{width:17px;height:17px;flex:0 0 17px;margin-top:1px}
.legal-consent span{font-size:11px!important;line-height:1.45;color:#676977!important}
.legal-consent a{color:var(--accent);font-weight:800;text-decoration:none}
.legal-consent a:hover{text-decoration:underline}

.account-danger-zone{
  margin-top:24px;
  padding:18px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:18px;
  border:1px solid #efc9ce;
  border-radius:18px;
  background:#fff8f9;
}
.account-danger-zone h2{margin:0;font-size:18px}
.account-danger-zone p{margin:5px 0 0;color:#7c666a;font-size:11px;line-height:1.45}

.delete-account-dialog{
  width:min(92vw,540px);
  padding:0;
  border:0;
  border-radius:22px;
  background:transparent;
  color:var(--text);
}
.delete-account-dialog::backdrop{background:rgba(15,17,28,.52);backdrop-filter:blur(7px)}
.delete-account-modal{
  padding:22px;
  border-radius:22px;
  background:#fff;
  box-shadow:0 24px 80px rgba(0,0,0,.28);
}
.delete-account-modal header{display:flex;align-items:flex-start;justify-content:space-between;gap:15px}
.delete-account-modal h2{margin:0;font-size:24px;letter-spacing:-.035em}
.delete-account-modal>p{margin:10px 0 17px;color:var(--muted);font-size:12px;line-height:1.55}
.delete-account-modal label{display:block;margin-top:11px}
.delete-account-modal label>span{display:block;margin-bottom:5px;font-size:10px;font-weight:800;color:#656775}
.delete-account-modal input{width:100%}
.delete-account-actions{display:flex;justify-content:flex-end;gap:9px;margin-top:17px}
.delete-account-actions .button:disabled{opacity:.6}

.standalone-legal-shell{
  width:min(100% - 28px,980px);
  margin:0 auto;
  padding:34px 0 56px;
}
.legal-page{
  padding:32px;
  border:1px solid var(--line);
  border-radius:24px;
  background:#fff;
  box-shadow:var(--shadow-soft);
}
.legal-page h1{margin:2px 0 5px;font-size:clamp(36px,5vw,54px);letter-spacing:-.05em}
.legal-page h2{margin:25px 0 7px;font-size:18px}
.legal-page p{margin:0;color:#5f6170;font-size:13px;line-height:1.7}
.legal-updated{margin-bottom:23px!important;color:#9294a0!important;font-size:10px!important}
.legal-back{display:inline-block;margin-bottom:20px;text-decoration:none}

@media(max-width:699px){
  .legal-consent span{font-size:12px!important}
  .account-danger-zone{align-items:flex-start;flex-direction:column}
  .account-danger-zone .button{width:100%}
  .delete-account-modal{padding:18px}
  .delete-account-actions{display:grid;grid-template-columns:1fr}
  .standalone-legal-shell{padding-top:18px}
  .legal-page{padding:21px;border-radius:20px}
  .legal-page p{font-size:12px}
}

/* Mobile viewport polish: prevent page-level horizontal drift */
html,body{
  width:100%;
  max-width:100%;
  overflow-x:clip;
}
.app-shell,main,.view{
  width:100%;
  max-width:100%;
  min-width:0;
}
main>*,
.profile-layout>*,
.team-grid>*,
.stats-grid>*,
.details-grid>*{
  min-width:0;
  max-width:100%;
}
.builder-hero,
.preview-head,
.section-heading,
.team-heading,
.team-heading-actions,
.profile-page-shell,
.profile-main-card,
.profile-summary-card,
.team-insights,
.stats-panel{
  min-width:0;
  max-width:100%;
}
.builder-hero{overflow:hidden}
.builder-hero:after{right:-12px}

@media(max-width:699px){
  main{
    padding-left:max(14px,env(safe-area-inset-left));
    padding-right:max(14px,env(safe-area-inset-right));
  }
  .app-bar{
    width:100%;
    max-width:100%;
    padding-left:max(14px,env(safe-area-inset-left));
    padding-right:max(14px,env(safe-area-inset-right));
  }
  .details-card,
  .team-slot,
  .team-insights,
  .profile-summary-card,
  .profile-main-card,
  .account-page-card,
  .stats-panel{
    width:100%;
    max-width:100%;
  }
  .team-heading-actions{
    max-width:100%;
  }
  .showdown-dialog,
  .delete-account-dialog,
  .save-team-dialog,
  .new-team-dialog{
    max-width:100vw;
  }
}

/* Footer, account maintenance, sharing and shared team pages */
.site-footer{
  width:min(calc(100% - 36px),1180px);
  margin:12px auto 92px;
  padding:16px 0;
  border-top:1px solid var(--line);
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  color:var(--muted);
  font-size:10px;
}
.site-footer-links{display:flex;align-items:center;gap:8px}
.site-footer a{color:inherit;text-decoration:none;font-weight:800}
.site-footer a:hover{color:var(--accent)}
.site-footer-powered strong{color:var(--text)}
.standalone-footer{margin-bottom:24px}

.account-security-card{
  margin-top:22px;
  padding:18px;
  border:1px solid var(--line);
  border-radius:18px;
  background:#fafbff;
}
.account-update-form{margin-top:0}
.account-update-form .button{width:100%}
.account-security-divider{height:1px;background:var(--line);margin:20px 0}
.account-security-card .account-message{margin-top:8px}

.preview-actions{flex-wrap:wrap}

.shared-team-shell{
  width:min(calc(100% - 28px),1040px);
  margin:0 auto;
  padding:34px 0 20px;
}
.shared-team-head{margin-bottom:24px}
.shared-team-head h1{font-size:clamp(38px,7vw,64px);line-height:1;letter-spacing:-.055em;margin:0}
.shared-team-head p{margin:10px 0 0;color:var(--muted);font-size:14px}
.shared-team-loading{padding:30px;text-align:center;color:var(--muted);font-weight:800}
.shared-team-grid{display:grid;grid-template-columns:1fr;gap:14px}
.shared-mon-card{
  display:grid;
  grid-template-columns:120px minmax(0,1fr);
  gap:14px;
  padding:16px;
  border:1px solid var(--line);
  border-radius:22px;
  background:#fff;
  box-shadow:var(--shadow-soft);
}
.shared-mon-art{display:grid;place-items:center;border-radius:18px;background:rgba(var(--accent-rgb),.06)}
.shared-mon-art img{width:112px;height:112px;object-fit:contain}
.shared-mon-copy{min-width:0}
.shared-mon-copy h2{margin:0 0 10px;font-size:20px;letter-spacing:-.03em}
.shared-mon-details{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.shared-mon-details>div{min-width:0;padding:8px 9px;border-radius:10px;background:#f7f7fa}
.shared-mon-details small{display:block;color:var(--muted);font-size:8px;text-transform:uppercase;font-weight:850}
.shared-mon-details strong{display:block;margin-top:2px;font-size:11px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.shared-mon-moves{display:grid;grid-template-columns:1fr 1fr;gap:6px 8px;list-style:none;padding:0;margin:10px 0 0}
.shared-mon-moves li{padding:7px 9px;border:1px solid #e4e5eb;border-radius:9px;background:#fff;font-size:10px;font-weight:800}

@media(min-width:760px){
  .shared-team-grid{grid-template-columns:1fr 1fr}
}
@media(max-width:699px){
  .site-footer{
    width:calc(100% - 28px);
    margin-bottom:82px;
    flex-direction:column;
    align-items:flex-start;
    gap:8px;
  }
  .preview-actions{display:grid;grid-template-columns:1fr 1fr;width:100%}
  .preview-actions .button:last-child{grid-column:1/-1}
  .account-security-card{padding:15px}
  .shared-team-shell{padding-top:22px}
  .shared-mon-card{grid-template-columns:92px minmax(0,1fr);padding:13px}
  .shared-mon-art img{width:88px;height:88px}
  .shared-mon-details{grid-template-columns:1fr}
  .shared-mon-moves{grid-template-columns:1fr}
}

.cloud-team-actions{flex-wrap:wrap}
@media(max-width:620px){
  .cloud-team-actions{justify-content:flex-start}
}

/* Pokémon GO builder */
body[data-game="go"]{--accent:#168bd2;--accent-2:#52c878;--accent-rgb:22,139,210}
.game-card.go,.new-team-game.go{background:linear-gradient(135deg,#147ec1,#4dc672)}
.game-card.go:before{background:linear-gradient(120deg,rgba(8,31,52,.84) 0 43%,rgba(8,31,52,.12) 76%)}
.go-wordmark span{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:38px;
  padding:0 12px;
  border-radius:999px;
  background:rgba(255,255,255,.94);
  color:#147fc3;
  font-size:17px;
  font-weight:950;
  letter-spacing:-.04em;
  box-shadow:0 5px 12px rgba(0,0,0,.16);
}
.new-team-game .go-wordmark span{font-size:15px;min-height:34px}

.go-team-settings{
  margin-top:16px;
  padding:16px;
  border:1px solid rgba(var(--accent-rgb),.16);
  border-radius:18px;
  background:linear-gradient(135deg,rgba(var(--accent-rgb),.08),rgba(82,200,120,.06));
}
.go-settings-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin-bottom:12px}
.go-settings-head h3{margin:0;font-size:17px;letter-spacing:-.025em}
.go-team-settings>p{margin:10px 2px 0;color:var(--muted);font-size:9px;line-height:1.5}

.go-pokemon-fields{margin-top:10px}
.go-iv-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin-top:10px}
.go-iv-grid input{text-align:center;font-weight:800}
.go-search-result strong{display:block}
.go-search-result small{display:block;margin-top:2px;color:var(--muted);font-size:9px}

.go-team-slot .slot-img{height:128px}
.go-slot-badges{display:flex;gap:5px;flex-wrap:wrap;margin-top:8px}
.go-slot-badges>span,.go-shadow-badge{
  display:inline-flex;
  align-items:center;
  min-height:22px;
  padding:3px 7px;
  border-radius:999px;
  background:rgba(var(--accent-rgb),.09);
  color:var(--accent);
  font-size:8px;
  font-weight:900;
}
.go-shadow-badge{background:#4b405d;color:#fff}
.go-slot-info{grid-template-columns:1fr 1fr;margin-top:9px}
.go-slot-info .go-charge-row{grid-column:1/-1}
.go-slot-info span{white-space:normal!important;line-height:1.35}

.go-paper-header{background:linear-gradient(135deg,rgba(22,139,210,.10),rgba(82,200,120,.07))}
.go-paper-team{display:grid;gap:12px;margin-top:13px}
.go-paper-mon{
  display:grid;
  grid-template-columns:118px minmax(0,1fr);
  overflow:hidden;
  border:1px solid #dfe3e9;
  border-radius:16px;
  background:#fff;
  box-shadow:0 3px 10px rgba(31,34,48,.04);
}
.go-paper-art{display:grid;place-items:center;background:radial-gradient(circle,rgba(22,139,210,.12),#f7fafb 68%)}
.go-paper-art img{width:108px;height:108px;object-fit:contain;filter:drop-shadow(0 7px 8px rgba(31,34,48,.10))}
.go-paper-body{padding:12px}
.go-paper-top{display:flex;justify-content:space-between;align-items:flex-start;gap:8px}
.go-paper-top h3{margin:0;font-size:16px;letter-spacing:-.025em}
.go-paper-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;margin-top:10px}
.go-paper-stats>div{padding:7px;border-radius:8px;background:#f5f7fa}
.go-paper-stats small{display:block;font-size:6px;color:#777b86;text-transform:uppercase;font-weight:850}
.go-paper-stats strong{display:block;margin-top:2px;font-size:9px}
.go-paper-moves{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;margin-top:8px}
.go-paper-move{min-width:0;padding:7px 8px;border:1px solid #e1e4ea;border-radius:8px;background:#fff}
.go-paper-move small{display:block;font-size:5px;color:#7a7d88;font-weight:850}
.go-paper-move strong{display:block;margin-top:2px;font-size:8px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.go-data-credit{margin:10px 2px 0;color:#898c96;font-size:7px;text-align:right}

.go-cloud-mark span{
  display:grid;
  place-items:center;
  width:42px;
  height:42px;
  border-radius:50%;
  background:linear-gradient(135deg,#168bd2,#52c878);
  color:#fff;
  font-size:11px;
  font-weight:950;
}

@media(max-width:699px){
  .go-iv-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
  .go-paper-mon{grid-template-columns:92px minmax(0,1fr)}
  .go-paper-art img{width:86px;height:86px}
  .go-paper-stats{grid-template-columns:1fr 1fr 1.3fr}
  .go-paper-moves{grid-template-columns:1fr}
}

@media print{
  body[data-game="go"]{--accent:#168bd2}
  .go-print-team{display:grid;grid-template-columns:1fr;gap:4mm;margin-top:4mm}
  .go-print-mon{
    display:grid;
    grid-template-columns:35mm 1fr;
    min-height:42mm;
    border:.7pt solid #ccd4dc;
    border-radius:3mm;
    overflow:hidden;
    break-inside:avoid;
  }
  .go-print-art{display:grid;place-items:center;background:#f4f8fb}
  .go-print-art img{width:32mm;height:32mm;object-fit:contain}
  .go-print-copy{padding:5mm}
  .go-print-copy h2{margin:0;font-size:14pt}
  .go-print-copy p{margin:1.5mm 0 3mm;color:#555;font-size:8pt}
  .go-print-copy ul{display:grid;grid-template-columns:repeat(3,1fr);gap:2mm;margin:0;padding:0;list-style:none}
  .go-print-copy li{padding:2mm;border:.5pt solid #ddd;border-radius:1.5mm;font-size:8pt;font-weight:700}
}

/* Keep mobile sheet scrolling contained inside the Pokémon editor */
html.editor-open,body.editor-open{
  overscroll-behavior:none;
}
.editor-backdrop{
  overflow:hidden;
  overscroll-behavior:none;
  touch-action:none;
}
.editor-sheet{
  min-height:0;
  overscroll-behavior:contain;
  touch-action:pan-y;
}
.editor-scroll{
  min-height:0;
  flex:1 1 auto;
  overscroll-behavior:contain;
  -webkit-overflow-scrolling:touch;
  touch-action:pan-y;
}

/* Exact Pokémon GO artwork + Shadow treatment */
.go-shadow-art{
  position:relative;
  isolation:isolate;
}
.go-shadow-art::before{
  content:"";
  position:absolute;
  z-index:0;
  inset:10%;
  border-radius:50%;
  background:
    radial-gradient(circle at 42% 44%,rgba(153,92,224,.54) 0 20%,rgba(96,44,154,.34) 38%,rgba(54,23,88,.04) 70%);
  filter:blur(8px);
  transform:scale(1.08);
  pointer-events:none;
}
.go-shadow-art::after{
  content:"";
  position:absolute;
  z-index:0;
  inset:18% 14%;
  border-radius:48% 52% 46% 54%;
  background:
    conic-gradient(from 35deg,transparent 0 11%,rgba(187,119,255,.32) 14% 20%,transparent 23% 48%,rgba(109,53,173,.28) 53% 59%,transparent 63%);
  filter:blur(5px);
  pointer-events:none;
}
.go-shadow-art img{
  position:relative;
  z-index:1;
  filter:drop-shadow(0 0 6px rgba(102,45,168,.7)) drop-shadow(0 5px 8px rgba(31,20,46,.18));
}
.pokemon-image-wrap.go-shadow-art{
  background:radial-gradient(circle,rgba(116,58,174,.17),rgba(var(--accent-rgb),.05) 68%);
}
.slot-img.go-shadow-art{
  overflow:visible;
}
.shared-mon-art.go-shadow-art{
  overflow:visible;
}
@media (prefers-reduced-motion:no-preference){
  .editor-sheet .go-shadow-art::before{animation:goShadowPulse 3.8s ease-in-out infinite}
}
@keyframes goShadowPulse{
  0%,100%{opacity:.74;transform:scale(1.03)}
  50%{opacity:1;transform:scale(1.11)}
}
@media print{
  .go-shadow-art::before{filter:blur(4mm);opacity:.7}
  .go-shadow-art::after{display:none}
  .go-shadow-art img{filter:drop-shadow(0 0 2.5mm rgba(92,39,150,.65))}
}

.go-pokemon-fields .inline-toggle.is-disabled{
  opacity:.58;
}
.go-pokemon-fields .inline-toggle.is-disabled input{
  cursor:not-allowed;
}


/* Pokémon TCG deck builder */
.game-card.tcg{background:linear-gradient(145deg,#fff8e7 0%,#fff 58%,#eef4ff 100%)}
.tcg-wordmark{background:linear-gradient(135deg,#2347a3,#4870d8)!important;color:#fff!important}
.tcg-wordmark span{font-size:17px;font-weight:950;letter-spacing:-.04em}
.tcg-card-fan{position:absolute;right:-8px;top:34px;width:46%;height:72%;pointer-events:none;opacity:.95}
.tcg-card-fan span{position:absolute;right:12%;top:8%;width:92px;aspect-ratio:63/88;border-radius:9px;border:4px solid #f6c84d;background:linear-gradient(145deg,#214da8,#112d70);box-shadow:0 14px 26px rgba(24,45,100,.2)}
.tcg-card-fan span:nth-child(1){transform:rotate(-18deg) translate(-35px,14px)}
.tcg-card-fan span:nth-child(2){transform:rotate(-4deg) translate(-12px,3px)}
.tcg-card-fan span:nth-child(3){transform:rotate(12deg) translate(12px,10px)}
.tcg-view{padding-top:30px}
.tcg-page-head{display:flex;align-items:flex-end;justify-content:space-between;gap:20px;margin-bottom:24px}
.tcg-page-head h1{font-size:clamp(38px,7vw,64px);line-height:1;letter-spacing:-.055em;margin:7px 0 8px}
.tcg-page-head p{max-width:620px;color:var(--muted);font-size:13px;line-height:1.55;margin:0}
.tcg-page-head .experimental-badge{vertical-align:middle;margin-left:5px}
.tcg-total-card{flex:0 0 auto;display:flex;align-items:baseline;gap:5px;padding:15px 18px;border-radius:20px;background:linear-gradient(135deg,var(--accent),var(--accent-2));color:#fff;box-shadow:0 14px 30px rgba(var(--accent-rgb),.22)}
.tcg-total-card strong{font-size:34px;line-height:1;letter-spacing:-.05em}.tcg-total-card span{font-size:11px;font-weight:850;opacity:.86}
.tcg-details-card{margin-bottom:16px}
.tcg-format-field{min-height:54px;border:1px solid var(--line);border-radius:14px;padding:10px 12px;background:#fff}
.tcg-format-field>span{display:block;font-size:9px;font-weight:850;text-transform:uppercase;letter-spacing:.05em;color:var(--muted)}
.tcg-format-field strong{display:block;font-size:13px;margin-top:2px}.tcg-format-field small{display:block;font-size:9px;color:var(--muted);margin-top:2px}
.tcg-builder-layout{display:grid;gap:16px}.tcg-search-panel,.tcg-deck-panel{min-width:0}
.tcg-search-field>span{display:block;font-size:11px;font-weight:800;color:#5e6070;margin:0 0 6px}
.tcg-search-status{font-size:10px;color:var(--muted);min-height:18px;margin:14px 1px 8px}
.tcg-search-results{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.tcg-search-result{display:grid;grid-template-columns:54px 1fr;gap:9px;align-items:center;border:1px solid var(--line);border-radius:14px;background:#fff;padding:7px;text-align:left;cursor:pointer;min-width:0}
.tcg-search-result:hover{border-color:rgba(var(--accent-rgb),.35);background:rgba(var(--accent-rgb),.025)}
.tcg-search-result img{width:54px;height:74px;object-fit:contain;border-radius:6px;background:var(--surface-soft)}
.tcg-search-result-copy{min-width:0}.tcg-search-result strong{display:block;font-size:11px;line-height:1.25}.tcg-search-result small{display:block;font-size:8px;color:var(--muted);margin-top:4px;overflow-wrap:anywhere}
.tcg-search-empty{grid-column:1/-1;border:1px dashed var(--line);border-radius:14px;padding:18px;text-align:center;color:var(--muted);font-size:10px}
.tcg-deck-summary{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;margin-bottom:12px}
.tcg-deck-summary>div{background:var(--surface-soft);border-radius:14px;padding:10px 8px;text-align:center}
.tcg-deck-summary small{display:block;font-size:8px;text-transform:uppercase;letter-spacing:.05em;color:var(--muted);font-weight:850}.tcg-deck-summary strong{display:block;font-size:20px;margin-top:2px}
.tcg-validation{display:grid;gap:7px;margin-bottom:14px}
.tcg-validation-item{border-radius:12px;padding:9px 11px;font-size:10px;font-weight:700;line-height:1.4}
.tcg-validation-item.ok{background:#eaf8ef;color:#18733a}.tcg-validation-item.warn{background:#fff6df;color:#7b5800}.tcg-validation-item.error{background:#fff0f2;color:#9b2537}
.tcg-deck-groups{display:grid;gap:14px}.tcg-deck-group h3{display:flex;align-items:center;justify-content:space-between;font-size:14px;margin:0 0 8px}
.tcg-deck-group h3 span{font-size:9px;color:var(--muted);font-weight:800}
.tcg-deck-list{display:grid;gap:7px}.tcg-deck-empty{border:1px dashed var(--line);border-radius:14px;padding:16px;color:var(--muted);font-size:10px;text-align:center}
.tcg-deck-card{display:grid;grid-template-columns:44px minmax(0,1fr) auto;gap:9px;align-items:center;border:1px solid var(--line);border-radius:14px;padding:7px;background:#fff}
.tcg-deck-card img{width:44px;height:61px;object-fit:contain;border-radius:5px;background:var(--surface-soft)}
.tcg-deck-card-copy{min-width:0}.tcg-deck-card-copy strong{display:block;font-size:11px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.tcg-deck-card-copy small{display:block;font-size:8px;color:var(--muted);margin-top:3px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.tcg-qty{display:flex;align-items:center;gap:4px}.tcg-qty button{width:28px;height:28px;border:1px solid var(--line);background:#fff;border-radius:9px;font-size:15px;cursor:pointer}.tcg-qty button:hover{background:var(--surface-soft)}
.tcg-qty strong{min-width:22px;text-align:center;font-size:12px}.tcg-remove{color:var(--danger)!important}
.tcg-standard-flag{display:inline-block;margin-left:5px;padding:2px 5px;border-radius:999px;background:#fff0f2;color:#9b2537;font-size:7px;font-weight:900;vertical-align:middle}
@media(min-width:860px){
  .tcg-builder-layout{grid-template-columns:minmax(320px,.9fr) minmax(430px,1.1fr);align-items:start}
  .tcg-search-panel{position:sticky;top:18px}
}
@media(max-width:620px){
  .tcg-page-head{align-items:flex-start;flex-direction:column}.tcg-total-card{width:100%;justify-content:center}
  .tcg-search-results{grid-template-columns:1fr 1fr}
  .tcg-deck-card{grid-template-columns:40px minmax(0,1fr)}.tcg-qty{grid-column:1/-1;justify-content:flex-end;border-top:1px solid var(--line);padding-top:6px}
}
@media(max-width:410px){.tcg-search-results{grid-template-columns:1fr}}

.tcg-image-unavailable{display:grid;place-items:center;background:linear-gradient(145deg,#f3f4f8,#e9ebf2);border:1px dashed #cfd2dc;border-radius:6px;color:var(--muted);text-align:center;overflow:hidden}
.tcg-image-unavailable span{font-size:7px;font-weight:850;line-height:1.15;padding:4px}
.tcg-search-result>.tcg-image-unavailable{width:54px;height:74px}
.tcg-deck-card>.tcg-image-unavailable{width:44px;height:61px}


/* TCG search result and card preview refinement */
.tcg-search-results{grid-template-columns:1fr;gap:10px}
.tcg-search-result{grid-template-columns:88px minmax(0,1fr) auto;gap:14px;padding:10px;border-radius:17px;min-height:132px}
.tcg-search-result img{width:88px;height:122px;border-radius:8px}
.tcg-search-result-copy strong{font-size:14px;line-height:1.25}
.tcg-search-result-copy small{font-size:10px;line-height:1.4;margin-top:6px;color:#747787}
.tcg-search-preview-cue{display:flex;align-items:center;gap:5px;align-self:center;color:var(--accent);font-size:9px;font-weight:900;text-transform:uppercase;letter-spacing:.04em}
.tcg-search-preview-cue b{font-size:20px;line-height:1;font-weight:500}
.tcg-search-result>.tcg-image-unavailable{width:88px;height:122px}
.tcg-card-preview-dialog{width:min(820px,calc(100% - 28px));max-width:none;border:0;padding:0;background:transparent;overflow:visible}
.tcg-card-preview-dialog::backdrop{background:rgba(15,17,28,.62);backdrop-filter:blur(8px)}
.tcg-card-preview-modal{position:relative;display:grid;grid-template-columns:minmax(260px,360px) minmax(0,1fr);gap:28px;align-items:center;background:#fff;border-radius:28px;padding:26px;box-shadow:0 28px 90px rgba(16,18,31,.3)}
.tcg-preview-close{position:absolute;right:14px;top:14px;z-index:2}
.tcg-preview-art{min-height:420px;display:grid;place-items:center;border-radius:22px;background:linear-gradient(145deg,#f6f7fa,#eceef5);padding:12px;overflow:hidden}
.tcg-preview-art .tcg-card-image{display:block;width:100%;max-width:330px;height:auto;max-height:470px;object-fit:contain;border-radius:14px;filter:drop-shadow(0 15px 18px rgba(22,29,48,.18))}
.tcg-preview-art .tcg-image-unavailable,.tcg-preview-loading{width:100%;min-height:390px;display:grid;place-items:center;color:var(--muted);font-size:11px;font-weight:800;text-align:center}
.tcg-preview-copy{min-width:0;padding-right:10px}
.tcg-preview-copy h2{font-size:clamp(30px,4vw,44px);line-height:1.03;letter-spacing:-.045em;margin:7px 0 10px}
.tcg-preview-reference{font-size:14px;font-weight:850;color:var(--text);margin:0 0 8px}
.tcg-preview-details{font-size:11px;color:var(--muted);line-height:1.5;margin:0 0 16px}
.tcg-preview-legality{border-radius:13px;padding:11px 12px;background:var(--surface-soft);color:var(--muted);font-size:10px;line-height:1.45;font-weight:700}
.tcg-preview-legality.is-legal{background:#eaf8ef;color:#18733a}
.tcg-preview-legality.is-review{background:#fff6df;color:#7b5800}
.tcg-preview-actions{display:flex;gap:8px;justify-content:flex-end;margin-top:22px}
@media(max-width:620px){
  .tcg-search-result{grid-template-columns:72px minmax(0,1fr);min-height:108px;gap:11px;padding:9px}
  .tcg-search-result img,.tcg-search-result>.tcg-image-unavailable{width:72px;height:100px}
  .tcg-search-preview-cue{grid-column:2;justify-self:start;margin-top:-4px}
  .tcg-card-preview-dialog{width:min(94vw,440px)}
  .tcg-card-preview-modal{grid-template-columns:1fr;gap:16px;padding:18px;border-radius:24px;max-height:92vh;overflow:auto}
  .tcg-preview-art{min-height:0;padding:8px;margin-top:24px}
  .tcg-preview-art .tcg-card-image{max-width:260px;max-height:365px}
  .tcg-preview-art .tcg-image-unavailable,.tcg-preview-loading{min-height:310px}
  .tcg-preview-copy{padding:0}
  .tcg-preview-copy h2{font-size:30px}
  .tcg-preview-actions{position:sticky;bottom:-18px;background:#fff;padding:12px 0 2px}
  .tcg-preview-actions .button{flex:1}
}


/* TCG card browser density + full text preview */
@media(min-width:1180px){
  .tcg-search-results{grid-template-columns:repeat(2,minmax(0,1fr));gap:11px}
}
.tcg-search-result{grid-template-columns:96px minmax(0,1fr);grid-template-rows:1fr auto;column-gap:13px;row-gap:4px;align-items:center;min-height:148px;padding:10px}
.tcg-search-result img,.tcg-search-result>.tcg-image-unavailable{grid-row:1/3;width:96px;height:134px}
.tcg-search-result-copy{align-self:end}
.tcg-search-result-copy strong{font-size:14px}
.tcg-search-result-copy small{font-size:9px;line-height:1.35;margin-top:5px}
.tcg-search-result-copy em{display:block;font-size:8px;font-style:normal;color:#9a9ca7;margin-top:4px;font-weight:750}
.tcg-search-preview-cue{grid-column:2;justify-self:start;align-self:start;margin-top:2px}
.tcg-card-preview-dialog{width:min(980px,calc(100% - 28px))}
.tcg-card-preview-modal{grid-template-columns:minmax(280px,360px) minmax(0,1fr);align-items:start;max-height:92vh;overflow:auto}
.tcg-card-preview-modal.is-text-only{grid-template-columns:1fr}
.tcg-card-preview-modal.is-text-only .tcg-preview-art{min-height:0;padding:14px 16px}
.tcg-preview-no-art{width:100%;min-height:86px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;color:var(--muted);text-align:center}
.tcg-preview-no-art strong{font-size:12px;color:var(--text)}
.tcg-preview-no-art span{font-size:9px}
.tcg-preview-card-info{display:grid;gap:12px;margin:17px 0}
.tcg-card-facts{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}
.tcg-card-facts.compact{grid-template-columns:repeat(3,minmax(0,1fr))}
.tcg-card-facts>div{border:1px solid var(--line);border-radius:12px;background:#fafbfe;padding:9px 10px;min-width:0}
.tcg-card-facts small{display:block;font-size:7px;text-transform:uppercase;letter-spacing:.06em;color:var(--muted);font-weight:900;margin-bottom:3px}
.tcg-card-facts strong{display:block;font-size:10px;line-height:1.35;overflow-wrap:anywhere}
.tcg-card-info-section h3{font-size:11px;text-transform:uppercase;letter-spacing:.06em;color:#727584;margin:0 0 6px}
.tcg-card-effect{border:1px solid var(--line);border-radius:13px;background:#fff;padding:10px 11px;margin-bottom:7px}
.tcg-card-effect:last-child{margin-bottom:0}
.tcg-card-effect-head{display:flex;align-items:center;gap:7px;min-width:0}
.tcg-card-effect-head strong{font-size:12px;line-height:1.3}
.tcg-card-effect-head>span:not(.tcg-energy-cost){font-size:8px;color:var(--muted);font-weight:800;margin-left:auto}
.tcg-card-effect-head>.tcg-energy-cost{margin-left:0}
.tcg-card-effect-head>strong{margin-left:0;text-align:left}
.tcg-card-effect p{font-size:10px;line-height:1.5;color:#5f6270;margin:7px 0 0}
.tcg-attack-damage{margin-left:auto;font-size:13px;color:var(--text)}
.tcg-energy-cost{display:inline-flex;gap:3px;flex:0 0 auto}
.tcg-energy-cost b{width:23px;height:23px;display:grid;place-items:center;border-radius:999px;background:#eef0f6;border:1px solid #daddE7;font-size:7px;color:#515462}
.tcg-card-info-empty{border:1px dashed var(--line);border-radius:13px;padding:13px;text-align:center;color:var(--muted);font-size:9px}
@media(max-width:620px){
  .tcg-search-results{grid-template-columns:1fr}
  .tcg-search-result{grid-template-columns:82px minmax(0,1fr);min-height:126px}
  .tcg-search-result img,.tcg-search-result>.tcg-image-unavailable{width:82px;height:114px}
  .tcg-card-preview-modal,.tcg-card-preview-modal.is-text-only{grid-template-columns:1fr}
  .tcg-card-facts,.tcg-card-facts.compact{grid-template-columns:repeat(2,minmax(0,1fr))}
}


/* TCG energy symbols, quantity picker and modal scroll lock */
body.tcg-preview-open{position:fixed;left:0;right:0;width:100%;overflow:hidden}
.tcg-energy-cost{display:inline-flex;align-items:center;gap:4px;flex:0 0 auto}
.tcg-energy-symbol{--energy-bg:#e7e8ec;--energy-fg:#353842;display:inline-grid;place-items:center;width:24px;height:24px;border-radius:50%;background:var(--energy-bg);color:var(--energy-fg);border:1px solid rgba(20,22,30,.17);box-shadow:inset 0 1px 1px rgba(255,255,255,.65),0 1px 2px rgba(20,22,30,.08);flex:0 0 24px}
.tcg-energy-symbol svg{width:17px;height:17px;fill:currentColor}
.tcg-energy-symbol.colorless{--energy-bg:#eeeeef;--energy-fg:#555862}
.tcg-energy-symbol.grass{--energy-bg:#7ac75a;--energy-fg:#163d1a}
.tcg-energy-symbol.fire{--energy-bg:#f35a3c;--energy-fg:#fff}
.tcg-energy-symbol.water{--energy-bg:#58a9e8;--energy-fg:#fff}
.tcg-energy-symbol.lightning{--energy-bg:#f6d84c;--energy-fg:#5d4b00}
.tcg-energy-symbol.psychic{--energy-bg:#b777cb;--energy-fg:#fff}
.tcg-energy-symbol.fighting{--energy-bg:#c87a4c;--energy-fg:#fff}
.tcg-energy-symbol.darkness{--energy-bg:#585a63;--energy-fg:#fff}
.tcg-energy-symbol.metal{--energy-bg:#b7bdc2;--energy-fg:#40444a}
.tcg-energy-symbol.fairy{--energy-bg:#efa3c7;--energy-fg:#7a2850}
.tcg-energy-symbol.dragon{--energy-bg:#d2ba4d;--energy-fg:#433600}
.tcg-type-value{display:flex!important;align-items:center;gap:5px;flex-wrap:wrap}
.tcg-type-value .tcg-energy-symbol{width:22px;height:22px;flex-basis:22px}
.tcg-type-value .tcg-energy-symbol svg{width:15px;height:15px}
.tcg-type-value>span:not(.tcg-energy-symbol){font-size:11px}
.tcg-preview-qty{display:flex;align-items:center;gap:7px;height:42px;padding:5px 7px 5px 10px;border:1px solid var(--line);border-radius:12px;background:#fff}
.tcg-preview-qty span{font-size:8px;text-transform:uppercase;letter-spacing:.05em;color:var(--muted);font-weight:900}
.tcg-preview-qty input{width:54px;height:30px;border:1px solid #dfe1e9;border-radius:8px;background:#f8f9fc;text-align:center;font-size:12px;font-weight:850;padding:0 4px}
.tcg-preview-qty input:focus{outline:2px solid rgba(var(--accent-rgb),.16);border-color:var(--accent)}
.tcg-preview-qty input:disabled{opacity:.55}
@media(max-width:620px){
  .tcg-preview-actions{display:grid;grid-template-columns:1fr auto 1.35fr;gap:7px}
  .tcg-preview-actions .button{min-width:0}
  .tcg-preview-qty{height:40px}
  .tcg-preview-qty input{width:44px}
}


/* Saved TCG decks + tournament deck list preview */
.tcg-logo img{display:block;max-width:170px;max-height:62px;width:auto;height:auto;object-fit:contain}
.new-team-game .tcg-logo img{max-width:150px;max-height:54px}
.tcg-head-actions{display:grid;gap:9px;justify-items:end}
.tcg-head-buttons{display:flex;gap:7px}
.tcg-head-buttons .button{min-height:40px;padding:0 13px;font-size:10px}
.tcg-cloud-mark img{max-width:92px!important;max-height:48px!important}
.cloud-deck-images{height:58px;display:flex;align-items:center;padding-left:3px}
.cloud-deck-images img{width:38px;height:53px;object-fit:cover;border-radius:5px;border:1px solid #e0e1e7;background:#f5f6f9;box-shadow:0 3px 8px rgba(20,22,34,.08);margin-right:-12px}
.cloud-deck-placeholder{width:54px;height:54px;border-radius:15px;display:grid;place-items:center;background:linear-gradient(135deg,#214da8,#112d70);color:#fff;font-size:10px;font-weight:950;border:3px solid #f6c84d}
.tcg-deck-list-dialog{width:min(860px,calc(100% - 28px));max-width:none;border:0;padding:0;background:transparent}
.tcg-deck-list-dialog::backdrop{background:rgba(15,17,28,.62);backdrop-filter:blur(8px)}
.tcg-deck-list-modal{background:#fff;border-radius:28px;padding:24px;max-height:92vh;overflow:auto;box-shadow:0 28px 90px rgba(16,18,31,.30)}
.tcg-deck-list-head{display:flex;justify-content:space-between;gap:18px;align-items:flex-start;border-bottom:2px solid var(--accent);padding-bottom:14px}
.tcg-deck-list-head h2{font-size:30px;letter-spacing:-.04em;margin:0}
.tcg-list-player{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin:14px 0}
.tcg-list-player>div{background:#f7f8fb;border-radius:12px;padding:9px 10px}
.tcg-list-player small{display:block;font-size:7px;text-transform:uppercase;letter-spacing:.06em;color:var(--muted);font-weight:900}
.tcg-list-player strong{display:block;font-size:10px;margin-top:3px;overflow-wrap:anywhere}
.tcg-list-preview-groups{display:grid;gap:14px}
.tcg-list-preview-group{border:1px solid var(--line);border-radius:16px;overflow:hidden}
.tcg-list-preview-group h3{display:flex;justify-content:space-between;align-items:center;margin:0;padding:10px 12px;background:#f2f3f7;font-size:12px}
.tcg-list-preview-group h3 span{font-size:9px;color:var(--muted)}
.tcg-list-preview-row{display:grid;grid-template-columns:36px minmax(0,1fr) 110px;gap:8px;align-items:center;padding:8px 11px;border-top:1px solid #eef0f4}
.tcg-list-preview-row strong{font-size:10px}.tcg-list-preview-row span{font-size:10px;font-weight:750}.tcg-list-preview-row small{text-align:right;font-size:8px;color:var(--muted);font-weight:750}
.tcg-list-preview-empty{padding:12px;color:var(--muted);font-size:9px}
.tcg-list-preview-note{margin-top:14px;padding:10px 12px;border-radius:12px;background:#f7f8fb;color:var(--muted);font-size:9px;line-height:1.45}
@media(max-width:700px){
  .tcg-page-head{align-items:stretch}
  .tcg-head-actions{justify-items:stretch}
  .tcg-head-buttons{display:grid;grid-template-columns:1fr 1fr}
  .tcg-head-buttons .button{width:100%}
  .tcg-list-player{grid-template-columns:1fr 1fr}
  .tcg-list-preview-row{grid-template-columns:34px minmax(0,1fr);gap:5px 8px}
  .tcg-list-preview-row small{grid-column:2;text-align:left}
}


/* Official Pokémon GO logo asset */
.go-logo img{display:block;width:auto;height:auto;max-width:170px;max-height:64px;object-fit:contain;filter:drop-shadow(0 5px 12px rgba(0,0,0,.14))}
.new-team-game .go-logo img{max-width:150px;max-height:54px}
.go-cloud-mark img{max-width:92px!important;max-height:48px!important}


/* TCG tournament readiness validation */
.tcg-readiness{display:flex;align-items:center;gap:11px;border:1px solid var(--line);border-radius:15px;padding:11px 12px;margin-bottom:10px;background:#f7f8fb}
.tcg-readiness-icon{width:34px;height:34px;flex:0 0 34px;border-radius:11px;display:grid;place-items:center;font-size:16px;font-weight:950;background:#e7e9ef;color:#696c78}
.tcg-readiness strong{display:block;font-size:12px}
.tcg-readiness small{display:block;font-size:9px;line-height:1.4;color:var(--muted);margin-top:2px}
.tcg-readiness.is-ready{border-color:#bde7ca;background:#eefaf2}.tcg-readiness.is-ready .tcg-readiness-icon{background:#d8f3e1;color:#14733a}
.tcg-readiness.is-review{border-color:#f0d99e;background:#fff9e9}.tcg-readiness.is-review .tcg-readiness-icon{background:#fff0bf;color:#7a5900}
.tcg-readiness.is-checking{border-color:#cbd8f1;background:#f2f6ff}.tcg-readiness.is-checking .tcg-readiness-icon{background:#e0e9fb;color:#315b9e}
.tcg-readiness.is-blocked{border-color:#efc2c9;background:#fff3f5}.tcg-readiness.is-blocked .tcg-readiness-icon{background:#f9dfe4;color:#9b2537}
.tcg-validation{gap:6px}
.tcg-validation-item{display:grid;grid-template-columns:112px minmax(0,1fr);gap:10px;align-items:start}
.tcg-validation-item strong{font-size:9px;line-height:1.35}
.tcg-validation-item span{font-size:9px;line-height:1.45;font-weight:650}
.tcg-validation-item.checking{background:#f2f6ff;color:#315b9e}
.tcg-list-readiness{margin:0 0 14px;border-radius:12px;padding:10px 11px;font-size:9px;line-height:1.4;font-weight:800;background:#f7f8fb;color:var(--muted)}
.tcg-list-readiness.is-ready{background:#eefaf2;color:#14733a}
.tcg-list-readiness.is-review{background:#fff9e9;color:#7a5900}
.tcg-list-readiness.is-checking{background:#f2f6ff;color:#315b9e}
.tcg-list-readiness.is-blocked{background:#fff3f5;color:#9b2537}
@media(max-width:620px){.tcg-validation-item{grid-template-columns:1fr;gap:3px}}


/* Pokémon Champions screenshot importer */
.champions-import-button{min-height:36px;padding:0 11px;border-radius:12px;font-size:11px;gap:7px}
.champions-import-button .experimental-badge{font-size:7px;padding:3px 5px}
.champions-import-dialog{
  width:min(94vw,860px);
  max-height:92vh;
  padding:0;
  border:0;
  border-radius:26px;
  background:transparent;
  color:var(--text);
}
.champions-import-dialog::backdrop{background:rgba(15,17,28,.5);backdrop-filter:blur(7px)}
.champions-import-modal{
  max-height:92vh;
  overflow:auto;
  overscroll-behavior:contain;
  -webkit-overflow-scrolling:touch;
  padding:22px;
  border:1px solid rgba(255,255,255,.8);
  border-radius:26px;
  background:var(--bg);
  box-shadow:0 24px 80px rgba(0,0,0,.24);
}
.champions-import-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px}
.champions-import-head h2{margin:0;font-size:25px;letter-spacing:-.035em}
.champions-import-intro{margin:9px 0 17px;color:var(--muted);font-size:12px;line-height:1.55}
.champions-upload-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.champions-upload-card{
  display:block;
  min-width:0;
  border:1.5px dashed #cfd1de;
  border-radius:20px;
  background:#fff;
  padding:10px;
  cursor:pointer;
  transition:border-color .18s ease,box-shadow .18s ease,transform .18s ease;
}
.champions-upload-card:hover,.champions-upload-card.is-dragover{
  border-color:rgba(var(--accent-rgb),.7);
  box-shadow:0 0 0 4px rgba(var(--accent-rgb),.07);
}
.champions-upload-card.is-dragover{transform:translateY(-2px)}
.champions-upload-label{display:block;padding:3px 4px 9px;color:#5e6070;font-size:10px;font-weight:900;text-transform:uppercase;letter-spacing:.06em}
.champions-upload-empty{
  min-height:205px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  border-radius:14px;
  background:linear-gradient(135deg,rgba(var(--accent-rgb),.08),rgba(var(--accent-rgb),.02));
  text-align:center;
  padding:20px;
}
.champions-upload-icon{
  width:48px;height:48px;display:grid;place-items:center;
  border-radius:16px;margin-bottom:12px;
  background:rgba(var(--accent-rgb),.12);color:var(--accent);
  font-size:25px;font-weight:800;
}
.champions-upload-empty strong{font-size:13px}
.champions-upload-empty small{margin-top:5px;color:var(--muted);font-size:10px}
.champions-preview{min-width:0}
.champions-preview-frame{position:relative;overflow:hidden;border-radius:14px;background:#e9e9f0}
.champions-preview-frame img{display:block;width:100%;height:auto}
.champions-detection-layer{position:absolute;inset:0;pointer-events:none}
.champions-detection-box{position:absolute;border:2px solid #b9ef21;border-radius:4px;box-shadow:0 0 0 1px rgba(0,0,0,.2) inset}
.champions-detection-box span{
  position:absolute;left:-1px;top:-1px;
  min-width:17px;height:17px;padding:0 4px;
  display:grid;place-items:center;
  border-radius:4px 0 5px 0;
  background:#b9ef21;color:#263000;
  font-size:8px;font-weight:950;
}
.champions-file-meta{display:flex;align-items:flex-start;justify-content:space-between;gap:8px;padding:9px 3px 2px}
.champions-file-meta strong{font-size:11px}
.champions-file-meta span{font-size:9px;color:var(--muted);text-align:right}
.champions-layout-key{
  display:flex;justify-content:space-between;gap:14px;flex-wrap:wrap;
  margin:11px 2px 0;color:#858794;font-size:9px;line-height:1.45;
}
.champions-layout-key span:first-child{display:flex;align-items:center;gap:6px}
.champions-key-box{width:13px;height:9px;border:2px solid #9bcf08;border-radius:2px}
.champions-import-status{min-height:20px;margin-top:10px;font-size:11px;font-weight:750;color:#59606f}
.champions-import-status.is-error{color:var(--danger)}
.champions-import-status.is-success{color:#27704b}
.champions-import-actions{display:flex;justify-content:flex-end;gap:9px;margin-top:8px;flex-wrap:wrap}
.champions-import-actions .button:disabled{opacity:.48;cursor:not-allowed}
html.champions-import-open,body.champions-import-open{overflow:hidden;overscroll-behavior:none}
body.champions-review-edit-open .champions-import-modal{overflow:hidden}

@media(max-width:699px){
  .champions-import-dialog{width:100vw;max-width:100vw;max-height:100dvh;border-radius:0}
  .champions-import-modal{max-height:100dvh;min-height:100dvh;border-radius:0;padding:16px 14px calc(18px + env(safe-area-inset-bottom))}
  .champions-import-head h2{font-size:21px}
  .champions-import-intro{font-size:11px}
  .champions-upload-grid{grid-template-columns:1fr}
  .champions-upload-empty{min-height:145px}
  .champions-import-actions{display:grid;grid-template-columns:1fr 1fr;position:sticky;bottom:0;padding-top:10px;background:linear-gradient(180deg,rgba(245,246,251,0),var(--bg) 28%)}\n  .champions-import-actions #importChampionsTeam{grid-column:1/-1}
  .champions-import-button{min-height:34px;font-size:10px}
}


/* Champions OCR diagnostic preview */
.champions-ocr-progress{
  margin-top:12px;padding:12px 13px;border-radius:15px;
  border:1px solid rgba(var(--accent-rgb),.16);
  background:rgba(var(--accent-rgb),.055);
}
.champions-ocr-progress-copy{display:flex;align-items:center;justify-content:space-between;gap:12px;font-size:10px}
.champions-ocr-progress-copy strong{font-size:11px}
.champions-ocr-progress-copy span{font-weight:900;color:var(--accent)}
.champions-ocr-progress-track{height:7px;margin-top:8px;border-radius:999px;overflow:hidden;background:rgba(var(--accent-rgb),.11)}
.champions-ocr-progress-track i{display:block;width:0;height:100%;border-radius:inherit;background:linear-gradient(90deg,var(--accent),var(--accent-2));transition:width .15s ease}
.champions-ocr-progress small{display:block;margin-top:7px;color:var(--muted);font-size:9px;line-height:1.4}
.champions-ocr-results{margin-top:14px;padding:15px;border:1px solid var(--line);border-radius:20px;background:#fff}
.champions-ocr-results-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}
.champions-ocr-head-badges{display:flex;align-items:center;justify-content:flex-end;gap:7px;flex-wrap:wrap}
.champions-ocr-results-head h3{margin:1px 0 0;font-size:18px;letter-spacing:-.025em}
.champions-ocr-results>p{margin:7px 0 13px;color:var(--muted);font-size:11px;line-height:1.55}
.champions-ocr-grid{display:grid;grid-template-columns:1fr 1fr;gap:9px}
.champions-ocr-card{min-width:0;border:1px solid var(--line);border-radius:18px;padding:11px;background:#fafafe;box-shadow:0 10px 24px rgba(31,36,67,.035)}
.champions-ocr-card.is-resolved{border-color:#e0e4ee}
.champions-ocr-card.is-unresolved{border-color:#efd9a7;background:#fffdf7}
.champions-ocr-card-head{display:grid;grid-template-columns:58px 1fr;align-items:center;gap:10px;margin-bottom:9px}
.champions-ocr-heading{min-width:0}
.champions-ocr-heading-top{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:3px}
.champions-ocr-edit{width:30px;height:30px;display:grid;place-items:center;flex:0 0 auto;padding:0;border:1px solid #dfe1eb;border-radius:9px;background:#fff;color:#555968;cursor:pointer;transition:border-color .16s ease,color .16s ease,background .16s ease,transform .16s ease}
.champions-ocr-edit svg{width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.champions-ocr-edit:hover{border-color:rgba(var(--accent-rgb),.4);color:var(--accent);background:rgba(var(--accent-rgb),.05)}
.champions-ocr-edit:active{transform:scale(.96)}
.champions-ocr-species{min-width:0}
.champions-ocr-species strong{display:block;font-size:15px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.champions-ocr-gender{display:inline-block;margin-left:6px;font-size:.95em;font-weight:950}
.champions-ocr-gender.is-male{color:#1678d3}
.champions-ocr-gender.is-female{color:#d73855}
.champions-ocr-species small{display:block;margin-top:3px;color:var(--muted);font-size:10px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.champions-ocr-art{width:58px;height:58px;display:grid;place-items:center;border-radius:15px;background:linear-gradient(145deg,#fff,rgba(var(--accent-rgb),.07));border:1px solid #e8e9f1;overflow:hidden}
.champions-ocr-art img{display:block;width:54px;height:54px;object-fit:contain}
.champions-ocr-art-fallback{width:27px;height:27px;display:grid;place-items:center;border:5px solid rgba(var(--accent-rgb),.18);border-radius:50%;color:rgba(var(--accent-rgb),.18);font-size:7px}
.champions-ocr-types{display:flex;gap:4px;flex-wrap:wrap;margin-top:5px}
.champions-ocr-types span{display:inline-flex;align-items:center;min-height:19px;padding:0 7px;border-radius:999px;background:rgba(var(--accent-rgb),.08);color:var(--accent);font-size:8px;font-weight:850}
.champions-ocr-slot{flex:0 0 auto;display:inline-grid;place-items:center;min-width:42px;height:25px;padding:0 8px;border-radius:8px;background:rgba(var(--accent-rgb),.1);color:var(--accent);font-size:9px;font-weight:950}
.champions-ocr-unresolved{color:#9a6c11}
.champions-ocr-detail{display:grid;grid-template-columns:62px 1fr;gap:7px;align-items:center;padding:6px 0;border-top:1px solid #ececf2;font-size:10px}
.champions-ocr-detail>span:first-child{color:var(--muted);font-weight:800}
.champions-ocr-detail>strong{font-size:11px}
.champions-ocr-item{display:inline-flex;align-items:center;gap:6px;min-width:0}
.champions-ocr-item img{width:20px;height:20px;object-fit:contain;image-rendering:auto;flex:0 0 auto}
.champions-ocr-item>strong,.champions-ocr-item>.champions-ocr-raw{min-width:0}
.champions-alignment-value{display:inline-flex;align-items:baseline;gap:6px;flex-wrap:wrap}
.champions-alignment-effects{font-size:10px;font-weight:800;white-space:nowrap}
.champions-ocr-raw{color:#7b641a;font-size:10px;font-weight:750}
.champions-ocr-missing{color:#a2a4af;font-size:10px;font-style:italic}
.champions-ocr-moves{display:grid;grid-template-columns:1fr 1fr;gap:5px;margin-top:8px}
.champions-ocr-moves>span{min-width:0;display:flex;align-items:center;gap:6px;background:#fff;border:1px solid #ededf2;border-radius:9px;padding:7px;font-size:10px}
.champions-ocr-moves b{flex:0 0 auto;width:17px;height:17px;display:grid;place-items:center;border-radius:5px;background:rgba(var(--accent-rgb),.09);color:var(--accent);font-size:8px}
.champions-ocr-moves strong,.champions-ocr-moves .champions-ocr-raw{min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:10px}
.champions-ocr-stats{display:grid;grid-template-columns:repeat(6,1fr);gap:3px;margin-top:8px}
.champions-ocr-stats>span{min-width:0;text-align:center;background:#fff;border:1px solid #eeeeF3;border-radius:7px;padding:5px 2px}
.champions-ocr-stats small,.champions-ocr-stats strong,.champions-ocr-stats em{display:block}
.champions-ocr-stats small{font-size:7px;color:var(--muted);font-weight:900;text-transform:uppercase}
.champions-ocr-stats strong{font-size:11px;margin-top:2px}
.champions-ocr-stats em{font-size:7px;color:var(--accent);font-style:normal;font-weight:850;margin-top:2px}

.champions-review-edit-dialog{
  width:min(94vw,720px);
  max-height:92dvh;
  padding:0;
  border:0;
  border-radius:24px;
  background:transparent;
  color:var(--text);
}
.champions-review-edit-dialog::backdrop{background:rgba(15,17,28,.55);backdrop-filter:blur(8px)}
.champions-review-edit-modal{
  max-height:92dvh;
  overflow:auto;
  overscroll-behavior:contain;
  -webkit-overflow-scrolling:touch;
  padding:22px;
  border:1px solid rgba(255,255,255,.8);
  border-radius:24px;
  background:var(--bg);
  box-shadow:0 24px 80px rgba(0,0,0,.28);
}
.champions-review-edit-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px}
.champions-review-edit-head h2{margin:0;font-size:23px;letter-spacing:-.035em}
.champions-review-edit-intro{margin:8px 0 16px;color:var(--muted);font-size:11px;line-height:1.5}
.champions-review-edit-grid{display:grid;gap:10px}
.champions-review-edit-grid.two{grid-template-columns:1fr 1fr}
.champions-review-edit-field,.champions-review-stat-editor label{min-width:0}
.champions-review-edit-field{position:relative}
.champions-review-edit-field>label,.champions-review-edit-grid label>span,.champions-review-edit-label{display:block;margin:0 0 5px;color:#5e6070;font-size:9px;font-weight:900;text-transform:uppercase;letter-spacing:.04em}
.champions-review-input-control{position:relative}
.champions-review-edit-grid input,.champions-review-edit-grid select,.champions-review-stat-editor input{
  width:100%;
  min-width:0;
  height:40px;
  border:1px solid var(--line);
  border-radius:11px;
  background:#fff;
  padding:0 10px;
  color:var(--text);
  font-size:11px;
  font-weight:700;
}
.champions-review-input-control input{padding-right:66px}
.champions-review-edit-grid select{appearance:auto}
.champions-review-edit-grid input:focus,.champions-review-edit-grid select:focus,.champions-review-stat-editor input:focus{outline:none;border-color:rgba(var(--accent-rgb),.55);box-shadow:0 0 0 3px rgba(var(--accent-rgb),.08)}
.champions-review-clear,.champions-review-caret{position:absolute;top:50%;transform:translateY(-50%);width:28px;height:28px;display:grid;place-items:center;border:0;border-radius:8px;background:transparent;color:#6e7180;font:900 15px/1 inherit;cursor:pointer}
.champions-review-clear{right:32px}
.champions-review-caret{right:3px;font-size:14px}
.champions-review-clear:hover,.champions-review-caret:hover{background:rgba(var(--accent-rgb),.07);color:var(--accent)}
.champions-review-suggestions{position:absolute;z-index:80;left:0;right:0;top:calc(100% + 5px);max-height:240px;overflow:auto;overscroll-behavior:contain;border:1px solid #dddfea;border-radius:12px;background:#fff;box-shadow:0 14px 36px rgba(30,34,54,.18);padding:5px}
.champions-review-suggestions button{display:block;width:100%;min-height:34px;padding:7px 9px;border:0;border-radius:8px;background:transparent;color:var(--text);text-align:left;font-size:10px;font-weight:750;cursor:pointer}
.champions-review-suggestions button:hover,.champions-review-suggestions button:focus{outline:none;background:rgba(var(--accent-rgb),.08);color:var(--accent)}
.champions-review-suggestions button:disabled{color:var(--muted);cursor:default}
.champions-review-suggestions button.is-loading{font-weight:700}
.champions-review-edit-section{margin-top:15px;padding-top:14px;border-top:1px solid var(--line)}
.champions-review-stat-editor{display:grid;gap:5px}
.champions-review-stat-head,.champions-review-stat-editor label{display:grid;grid-template-columns:minmax(92px,1fr) 88px 72px;gap:7px;align-items:center}
.champions-review-stat-head{padding:0 3px;color:var(--muted);font-size:8px;font-weight:900;text-transform:uppercase}
.champions-review-stat-editor label>span{font-size:10px;font-weight:850;color:#555968}
.champions-review-stat-editor input{text-align:center}
.champions-review-edit-status{min-height:20px;margin-top:10px;color:#27704b;font-size:10px;font-weight:800}
.champions-review-edit-status.is-error{color:var(--danger)}
.champions-review-edit-actions{display:flex;justify-content:flex-end;gap:9px;margin-top:8px}
.champions-review-edit-actions .button:disabled{opacity:.55;cursor:wait}

@media(max-width:699px){
  .champions-ocr-grid{grid-template-columns:1fr}
  .champions-ocr-card{padding:10px}
  .champions-ocr-card-head{grid-template-columns:52px 1fr}
  .champions-ocr-art{width:52px;height:52px}
  .champions-ocr-art img{width:49px;height:49px}
  .champions-ocr-head-badges{justify-content:flex-start}
  .champions-review-edit-modal{padding:17px}
  .champions-review-edit-grid.two{grid-template-columns:1fr}
  .champions-review-stat-head,.champions-review-stat-editor label{grid-template-columns:minmax(82px,1fr) 78px 64px}
  .champions-review-edit-actions{display:grid;grid-template-columns:1fr 1fr;position:sticky;bottom:-17px;padding:10px 0 17px;background:linear-gradient(180deg,rgba(245,246,251,0),var(--bg) 26%)}
}


/* Champions review confidence + import verification polish */
.champions-ocr-heading-actions{display:flex;align-items:center;gap:6px;min-width:0}
.champions-review-state{display:inline-flex;align-items:center;min-height:22px;padding:0 7px;border-radius:999px;font-size:7px;font-weight:950;letter-spacing:.02em;white-space:nowrap}
.champions-review-state.is-ready{background:#e9f7ef;color:#27704b}
.champions-review-state.is-edited{background:rgba(var(--accent-rgb),.09);color:var(--accent)}
.champions-review-state.is-warning{background:#fff3d6;color:#8a5a00}
.champions-ocr-card.has-review-warning{border-color:#e0e4ee;background:#fafafe}
.champions-ocr-detail.is-review-warning,
.champions-ocr-moves>span.is-review-warning,
.champions-ocr-stats>span.is-review-warning{
  border-color:#e7c86f;
  background:#fffaf0;
  box-shadow:inset 3px 0 0 #e8b93f;
}
.champions-ocr-summary{display:inline-flex;align-items:center;min-height:24px;padding:0 9px;border-radius:999px;font-size:8px;font-weight:950;white-space:nowrap}
.champions-ocr-summary.is-ready{background:#e9f7ef;color:#27704b}
.champions-ocr-summary.is-warning{background:#fff3d6;color:#8a5a00}

@media(max-width:699px){
  .champions-review-state{min-height:20px;padding:0 6px;font-size:7px}
  .champions-ocr-summary{min-height:22px;padding:0 7px;font-size:7px}
}


.champions-review-suggestions button strong{display:block;font:inherit;font-weight:800}
.champions-review-suggestions button small{display:block;margin-top:2px;color:var(--muted);font-size:8px;font-weight:750}
.champions-review-suggestions button.is-preferred{background:rgba(var(--accent-rgb),.045)}
.champions-review-suggestions button.is-preferred small{color:var(--accent)}


/* Champions human review confirmation + editor attention */
.champions-review-state.is-confirmed{background:#e7f7ee;color:#216944}
.champions-review-confirm-row{display:flex;justify-content:flex-end;margin-top:8px}
.champions-review-confirm{
  min-height:30px;padding:6px 10px;border:1px solid #d8dde8;border-radius:10px;
  background:#fff;color:#555968;font-size:9px;font-weight:850;cursor:pointer
}
.champions-review-confirm:hover,.champions-review-confirm:focus{
  outline:none;border-color:rgba(var(--accent-rgb),.35);color:var(--accent);
  background:rgba(var(--accent-rgb),.04)
}
.champions-review-confirm.is-confirmed{
  border-color:#b9dfc8;background:#eef9f2;color:#216944
}
.champions-review-attention-note{
  margin:8px 0 12px;padding:9px 10px;border:1px solid #e7c86f;border-radius:10px;
  background:#fffaf0;color:#775600;font-size:9px;font-weight:750
}
.champions-review-edit-field.is-review-warning>label{
  color:#8a5a00
}
.champions-review-edit-field.is-review-warning input,
.champions-review-edit-field.is-review-warning select,
.champions-review-stat-editor input.is-review-warning{
  border-color:#e7c86f;background:#fffaf0;box-shadow:inset 3px 0 0 #e8b93f
}
.champions-review-stat-editor label.is-review-warning>span{color:#8a5a00}


.champions-review-confirm-check{display:flex;gap:9px;align-items:flex-start;margin:12px 0 2px;padding:10px 11px;border:1px solid #dfe4ec;border-radius:11px;background:#fff;font-size:9px;font-weight:800;color:#555968}
.champions-review-confirm-check input{margin-top:2px;accent-color:var(--accent)}


/* Champions OCR feedback opt-in */
.champions-feedback-card{
  display:grid;grid-template-columns:minmax(0,1fr) auto;gap:16px;align-items:center;
  margin-top:14px;padding:14px;border:1px solid #dfe4ee;border-radius:16px;background:#f8f9fd
}
.champions-feedback-copy h4{margin:3px 0 5px;font-size:14px;color:#202333}
.champions-feedback-copy p{margin:0;color:#606576;font-size:10px;line-height:1.5}
.champions-feedback-copy small{display:block;margin-top:5px;color:#7a7f8f;font-size:8px}
.champions-feedback-actions{display:flex;flex-direction:column;align-items:flex-end;gap:7px;min-width:180px}
.champions-feedback-actions .button{width:100%}
#championsFeedbackStatus{max-width:230px;text-align:right;color:#6d7280;font-size:8px;font-weight:750;line-height:1.35}
#championsFeedbackStatus.is-error{color:var(--danger)}
#championsFeedbackStatus.is-success{color:#27704b}
@media(max-width:699px){
  .champions-feedback-card{grid-template-columns:1fr}
  .champions-feedback-actions{align-items:stretch;min-width:0}
  #championsFeedbackStatus{max-width:none;text-align:left}
}


/* TrainerCircuit brand shell */
.app-bar{height:82px}
.brand{gap:10px;min-width:0}
.brand-logo{display:block;width:190px;height:50px;object-fit:contain;object-position:left center}
.brand-tagline{font-size:9px;font-weight:850;letter-spacing:.075em;text-transform:uppercase;color:var(--muted);white-space:nowrap}
.hero{position:relative;padding:54px 0 42px;max-width:920px}
.hero:before{content:"";position:absolute;left:-22px;top:22px;width:88px;height:5px;border-radius:999px;background:linear-gradient(90deg,var(--tc-blue) 0 38%,var(--tc-gold) 38% 64%,var(--tc-red) 64%)}
.hero h1{color:var(--tc-navy)}
.hero p{max-width:670px}
.button.primary{background:linear-gradient(135deg,var(--tc-blue),#527fc2);box-shadow:0 10px 24px rgba(59,108,183,.2)}
.game-card.champions{background:linear-gradient(135deg,#243c61,#527fc2)}
.game-card.champions:before{background:linear-gradient(120deg,rgba(20,34,54,.9) 0 43%,rgba(20,34,54,.18) 76%)}
.game-card.go,.new-team-game.go{background:linear-gradient(135deg,#315d9f,#d2a344)}
.game-card.go:before{background:linear-gradient(120deg,rgba(25,43,68,.88) 0 43%,rgba(25,43,68,.16) 76%)}
.game-card.tcg{background:linear-gradient(135deg,#a9444d,#e0b14b);color:#fff}
.game-card.tcg:before{background:linear-gradient(120deg,rgba(77,29,35,.87) 0 43%,rgba(77,29,35,.16) 76%)}
.game-card.tcg .tcg-card-fan span{border-color:#e8c66d;background:linear-gradient(145deg,#315d9f,#1e2e44)}
.tcg-wordmark{background:linear-gradient(135deg,#315d9f,#3b6cb7)!important}
body[data-game="go"]{--accent:#3b6cb7;--accent-2:#d2a344;--accent-rgb:59,108,183}
.details-card,.profile-summary-card,.profile-main-card,.account-page-card,.stats-panel{border-color:#e1e6ed}
.bottom-nav{border-color:rgba(255,255,255,.92);box-shadow:0 16px 45px rgba(30,46,68,.16)}
.site-footer{color:#748093}
.site-footer-powered strong:first-child{color:var(--tc-navy)}
.account-button{border-color:#dde3eb;background:rgba(255,255,255,.9)}
.beta-pill{background:rgba(59,108,183,.1);color:var(--tc-blue)}
@media(max-width:720px){
  .app-bar{height:72px}
  .brand-logo{width:148px;height:42px}
  .brand-tagline{display:none}
  .hero{padding-top:40px}
  .hero:before{top:18px;width:68px}
}
@media(max-width:380px){
  .brand-logo{width:132px}
  .account-button{padding-right:6px}
}

/* TrainerCircuit home signature */
.hero{isolation:isolate}
.hero:after{content:"";position:absolute;z-index:-1;right:-120px;top:4px;width:330px;height:330px;background:url("/assets/trainercircuit-mark.svg") center/contain no-repeat;opacity:.045;pointer-events:none}
.hero h1,.builder-hero h1,.preview-head h1,.tcg-page-head h1,.profile-page-head h1{font-family:"Trebuchet MS",Inter,ui-sans-serif,system-ui,sans-serif;font-weight:850}
.game-card:after{content:"";position:absolute;left:22px;top:0;width:64px;height:4px;border-radius:0 0 999px 999px;background:rgba(255,255,255,.72);z-index:4}
.game-card.go:after{background:var(--tc-gold)}
.game-card.tcg:after{background:#f3d27c}
@media(max-width:720px){.hero:after{display:none}}


/* Persistent TrainerCircuit app header */
.app-bar{
  position:sticky;
  top:0;
  z-index:70;
  width:100%;
  max-width:none;
  margin:0;
  padding-left:max(18px,calc((100vw - var(--max))/2));
  padding-right:max(18px,calc((100vw - var(--max))/2));
  background:rgba(247,248,251,.9);
  border-bottom:1px solid rgba(30,46,68,.08);
  box-shadow:0 7px 24px rgba(30,46,68,.055);
  backdrop-filter:blur(18px) saturate(1.08);
  -webkit-backdrop-filter:blur(18px) saturate(1.08);
}
@media(max-width:699px){
  .app-bar{
    padding-left:max(14px,env(safe-area-inset-left));
    padding-right:max(14px,env(safe-area-inset-right));
  }
}


/* TrainerCircuit Events */
.bottom-nav{grid-template-columns:repeat(6,minmax(0,1fr));width:min(calc(100% - 24px),700px)}
.events-view{padding-top:30px}
.events-page-head,.event-detail-head{display:flex;align-items:flex-end;justify-content:space-between;gap:20px;margin-bottom:24px}
.events-page-head h1,.event-detail-head h1{font-size:clamp(40px,7vw,68px);line-height:.96;letter-spacing:-.055em;margin:0}
.events-page-head p{max-width:650px;margin:10px 0 0;color:var(--muted);font-size:13px;line-height:1.55}
.events-guest-card{max-width:620px;margin-top:20px;padding:28px;border:1px solid var(--line);border-radius:26px;background:#fff;box-shadow:var(--shadow-soft);text-align:center}
.events-guest-icon{width:58px;height:58px;margin:0 auto 12px;border-radius:18px;display:grid;place-items:center;background:rgba(var(--accent-rgb),.1);color:var(--accent);font-size:28px;font-weight:900}
.events-guest-card h2{margin:0;font-size:24px}.events-guest-card p{margin:8px auto 18px;max-width:420px;color:var(--muted);font-size:12px;line-height:1.55}
.events-section{margin-top:28px}.past-events-section{opacity:.92}
.event-list{display:grid;gap:12px}
.event-card{border:1px solid var(--line);border-radius:20px;background:#fff;box-shadow:var(--shadow-soft);overflow:hidden}
.event-card-main{width:100%;border:0;background:#fff;padding:16px;display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:14px;align-items:center;text-align:left;cursor:pointer}
.event-card-main:hover{background:#fbfcfe}
.event-card-badge{min-width:76px;padding:8px 9px;border-radius:12px;background:#eef3fb;color:#315d9f;font-size:8px;font-weight:900;text-transform:uppercase;letter-spacing:.05em;text-align:center}
.event-card-badge.go{background:#fff6df;color:#8b6a18}.event-card-badge.tcg{background:#fff0f1;color:#a6424a}
.event-card-copy{min-width:0}.event-card-copy strong{display:block;font-size:14px}.event-card-copy span,.event-card-copy small{display:block;margin-top:4px;color:var(--muted);font-size:9px;line-height:1.35}
.event-card-side{text-align:right}.event-card-side b{display:block;font-size:18px}.event-card-side small{display:block;color:var(--muted);font-size:8px}
.event-registration-pill{display:inline-block;padding:7px 9px;border-radius:999px;background:#e9f7ef;color:#237046;font-size:9px;font-weight:850;white-space:nowrap}
.event-card-actions{display:flex;gap:4px;justify-content:flex-end;border-top:1px solid var(--line);padding:7px 10px}
.event-card-actions button,.event-attendee button{border:0;background:transparent;border-radius:9px;padding:7px 9px;color:var(--muted);font-size:9px;font-weight:800;cursor:pointer}
.event-card-actions button:hover,.event-attendee button:hover{background:var(--surface-soft);color:var(--text)}.event-card-actions .danger-link:hover{color:var(--danger);background:#fff0f2}
.events-empty{padding:22px;border:1px dashed #ccd4df;border-radius:18px;background:rgba(255,255,255,.6);text-align:center;color:var(--muted)}
.events-empty strong{display:block;color:var(--text);font-size:13px}.events-empty span{display:block;margin-top:4px;font-size:10px}.events-empty.compact{padding:14px}
.events-loading{padding:36px;text-align:center;color:var(--muted);font-weight:750}
.event-hero-card{padding:22px;border-radius:26px;background:linear-gradient(135deg,#243c61,#527fc2);color:#fff;box-shadow:var(--shadow);margin-bottom:16px}
.event-hero-card.go{background:linear-gradient(135deg,#315d9f,#d2a344)}.event-hero-card.tcg{background:linear-gradient(135deg,#a9444d,#e0b14b)}
.event-hero-top{display:flex;justify-content:space-between;gap:12px;font-size:9px;font-weight:850;text-transform:uppercase;letter-spacing:.06em;opacity:.9}
.event-hero-card h2{margin:18px 0 4px;font-size:clamp(28px,5vw,48px);letter-spacing:-.045em}.event-hero-card>p{margin:0;opacity:.85;font-size:12px;font-weight:750}
.event-facts{display:grid;grid-template-columns:repeat(4,1fr);gap:8px;margin-top:22px}.event-facts>div{padding:11px;border-radius:14px;background:rgba(255,255,255,.12);backdrop-filter:blur(6px)}
.event-facts small{display:block;font-size:8px;text-transform:uppercase;letter-spacing:.06em;opacity:.72}.event-facts strong{display:block;margin-top:3px;font-size:11px}
.event-detail-grid{display:grid;gap:16px}.event-info-row{display:flex;justify-content:space-between;gap:16px;padding:11px 0;border-bottom:1px solid var(--line);font-size:11px}.event-info-row span{color:var(--muted)}.event-info-row strong{text-align:right}
.event-description{font-size:11px;line-height:1.6;color:var(--text);margin:16px 0}.event-description.muted{color:var(--muted)}
.event-register-cta{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin-top:18px;padding-top:16px;border-top:1px solid var(--line)}.event-register-cta small{color:var(--muted);font-size:9px;max-width:380px}
.event-registered-state{display:grid;grid-template-columns:auto 1fr auto;gap:12px;align-items:center;margin-top:18px;padding:14px;border-radius:16px;background:#eef9f2;color:#216944}
.event-registered-state>span{width:34px;height:34px;border-radius:11px;background:#fff;display:grid;place-items:center;font-weight:900}.event-registered-state strong{display:block;font-size:11px}.event-registered-state small{display:block;margin-top:2px;font-size:8px}
.event-detail-action-state{margin-top:18px;padding:13px 14px;border-radius:14px;background:#f0f2f6;color:var(--muted);font-size:10px;font-weight:800}.event-detail-action-state.is-cancelled{background:#fff0f2;color:#9b2537}
.event-host-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:18px;padding-top:16px;border-top:1px solid var(--line)}.event-host-actions .button{min-height:40px;font-size:10px}
.event-attendee-list{display:grid;gap:7px}.event-attendee{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:10px;align-items:center;padding:10px 11px;border:1px solid var(--line);border-radius:13px;background:#fff}
.event-attendee.is-muted{opacity:.65}.event-attendee strong{display:block;font-size:11px}.event-attendee small{display:block;margin-top:2px;color:var(--muted);font-size:8px}
.event-attendee-status{padding:5px 7px;border-radius:999px;background:#eaf8ef;color:#247047;font-size:8px;font-weight:850;text-transform:capitalize}.event-attendee-status.cancelled,.event-attendee-status.removed{background:#f1f2f5;color:#747986}
.event-dialog{border:0;padding:0;background:transparent;max-width:none;max-height:none}.event-dialog::backdrop{background:rgba(15,17,28,.5);backdrop-filter:blur(7px)}
.event-modal{width:min(calc(100vw - 28px),760px);max-height:92vh;overflow:auto;background:var(--bg);border:1px solid rgba(255,255,255,.8);border-radius:26px;padding:20px;box-shadow:0 28px 90px rgba(20,22,34,.28)}
.event-modal-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:16px}.event-modal-head h2{margin:0;font-size:28px;letter-spacing:-.04em}
.event-form-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.event-form-wide{grid-column:1/-1}.event-form-grid textarea{width:100%;border:1px solid var(--line);border-radius:14px;background:#fff;padding:12px 13px;color:var(--text);font:inherit;resize:vertical}
.event-modal-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:16px}

.event-create-choice-modal{width:min(calc(100vw - 28px),660px)}
.event-create-choice-intro{margin:0 0 16px;color:var(--muted);font-size:11px;line-height:1.55}
.event-create-choice-grid{display:grid;gap:10px}
.event-create-choice-card{width:100%;display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:13px;align-items:center;padding:15px;border:1px solid var(--line);border-radius:17px;background:#fff;text-align:left;color:var(--text);cursor:pointer;transition:border-color .16s ease,box-shadow .16s ease,transform .16s ease}
.event-create-choice-card:hover{border-color:rgba(var(--accent-rgb),.38);box-shadow:0 8px 22px rgba(30,46,68,.08);transform:translateY(-1px)}
.event-create-choice-icon{width:42px;height:42px;border-radius:13px;display:grid;place-items:center;background:rgba(var(--accent-rgb),.09);color:var(--accent);font-size:20px;font-weight:950}
.event-create-choice-card strong{display:block;font-size:13px}.event-create-choice-card small{display:block;margin-top:3px;color:var(--muted);font-size:9px;line-height:1.45}
.event-create-choice-arrow{color:#9ba7b7;font-size:25px;font-weight:700}

.official-event-modal{width:min(calc(100vw - 28px),820px)}
.official-event-toolbar{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:10px;align-items:start}
.official-event-toolbar .pokemon-official-summary{margin:0}
.official-event-list{max-height:min(52vh,520px);overflow:auto;padding-right:2px;margin-top:12px}
.official-import-empty{display:grid;gap:7px;width:100%}
.official-import-empty strong{font-size:11px}.official-import-empty span{color:var(--muted);font-size:9px;line-height:1.45}.official-import-empty .button{justify-self:start;margin-top:3px}

.official-event-loading{position:relative;display:grid;grid-template-columns:auto minmax(0,1fr);gap:12px;align-items:center;margin:14px 0 6px;padding:17px;border:1px solid #d7e1ef;border-radius:17px;background:linear-gradient(135deg,#f7faff,#fff);overflow:hidden}
.official-event-loading[hidden]{display:none}
.official-event-spinner{width:30px;height:30px;border:3px solid rgba(var(--accent-rgb),.14);border-top-color:var(--accent);border-radius:50%;animation:official-event-spin .8s linear infinite}
.official-event-loading strong{display:block;font-size:11px}.official-event-loading div>span{display:block;margin-top:3px;color:var(--muted);font-size:8px;line-height:1.4}
.official-event-progress{grid-column:1/-1;height:4px;margin-top:2px;border-radius:999px;background:rgba(var(--accent-rgb),.10);overflow:hidden}
.official-event-progress span{display:block;width:38%;height:100%;border-radius:inherit;background:var(--accent);animation:official-event-progress 1.15s ease-in-out infinite}
#refreshOfficialEventsButton.is-loading{opacity:.7}
@keyframes official-event-spin{to{transform:rotate(360deg)}}
@keyframes official-event-progress{0%{transform:translateX(-120%)}50%{transform:translateX(110%)}100%{transform:translateX(300%)}}

@media(max-width:699px){
  .event-create-choice-card{padding:13px}
  .official-event-toolbar{grid-template-columns:1fr}
  .official-event-toolbar .button{width:100%}
  .official-event-list{max-height:48vh}
}
@media(min-width:860px){.event-detail-grid{grid-template-columns:minmax(0,1fr) minmax(360px,.8fr)}}
@media(max-width:699px){
  .bottom-nav{grid-template-columns:repeat(6,minmax(0,1fr));width:calc(100% - 12px)}
  .bottom-nav button small{font-size:7px}
  .events-page-head{align-items:flex-start;flex-direction:column}.events-page-head .button{width:100%}
  .event-card-main{grid-template-columns:auto minmax(0,1fr)}.event-card-side{grid-column:1/-1;text-align:left}
  .event-facts{grid-template-columns:1fr 1fr}.event-registered-state{grid-template-columns:auto 1fr}.event-registered-state .button{grid-column:1/-1;width:100%}
  .event-form-grid{grid-template-columns:1fr}.event-form-wide{grid-column:auto}.event-host-actions .button{flex:1 1 45%}
}


/* Opt-in event hosting */
.event-host-setting-card{
  margin-top:18px;
  padding:18px;
  border:1px solid var(--line);
  border-radius:20px;
  background:linear-gradient(145deg,#fff,#f8fafc);
}
.event-host-setting-row{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:18px;
  align-items:center;
  cursor:pointer;
}
.event-host-setting-row h2{margin:2px 0 5px;font-size:20px;letter-spacing:-.035em}
.event-host-setting-row p{margin:0;max-width:560px;color:var(--muted);font-size:10px;line-height:1.55}
.event-host-setting-note{margin:12px 0 0;padding-top:11px;border-top:1px solid var(--line);color:var(--muted);font-size:9px;line-height:1.5}
.settings-switch{position:relative;width:52px;height:30px;display:block;flex:0 0 auto}
.settings-switch input{position:absolute;inset:0;width:100%;height:100%;margin:0;opacity:0;cursor:pointer;z-index:2}
.settings-switch input+span{position:absolute;inset:0;border-radius:999px;background:#d9dee7;box-shadow:inset 0 0 0 1px rgba(30,46,68,.08);transition:background .18s ease,box-shadow .18s ease}
.settings-switch input+span:after{content:"";position:absolute;top:4px;left:4px;width:22px;height:22px;border-radius:50%;background:#fff;box-shadow:0 3px 8px rgba(30,46,68,.18);transition:transform .18s ease}
.settings-switch input:checked+span{background:var(--tc-blue);box-shadow:inset 0 0 0 1px rgba(30,46,68,.06),0 0 0 4px rgba(59,108,183,.08)}
.settings-switch input:checked+span:after{transform:translateX(22px)}
.settings-switch input:focus-visible+span{outline:3px solid rgba(59,108,183,.28);outline-offset:3px}
.settings-switch input:disabled+span{opacity:.58}
@media(max-width:520px){
  .event-host-setting-card{padding:16px}
  .event-host-setting-row{gap:12px}
}


/* Connected Play! Pokémon League */
.pokemon-league-settings{margin-top:16px;padding-top:15px;border-top:1px solid var(--line)}
.pokemon-league-settings-head h3{margin:2px 0 5px;font-size:16px;letter-spacing:-.025em}
.pokemon-league-settings-head p{margin:0;color:var(--muted);font-size:9px;line-height:1.55}
.pokemon-league-connect-form{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:9px;align-items:end;margin-top:12px}
.pokemon-league-connect-form label>span{display:block;margin-bottom:5px;color:var(--muted);font-size:8px;font-weight:900;text-transform:uppercase;letter-spacing:.05em}
.pokemon-league-connect-form input{width:100%;height:42px;border:1px solid var(--line);border-radius:12px;background:#fff;padding:0 12px;color:var(--text);font:inherit;font-size:11px;font-weight:750}
.pokemon-league-connect-form input:focus{outline:none;border-color:rgba(var(--accent-rgb),.55);box-shadow:0 0 0 3px rgba(var(--accent-rgb),.08)}
.pokemon-league-connected{display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:10px;align-items:center;margin-top:12px;padding:12px;border:1px solid #cfe4d7;border-radius:15px;background:#f0faf4}
.pokemon-league-connected-mark{width:34px;height:34px;border-radius:11px;display:grid;place-items:center;background:#fff;color:#247047;font-weight:950}
.pokemon-league-connected-copy{min-width:0}.pokemon-league-connected-copy small{display:block;color:#4f8062;font-size:7px;font-weight:900;text-transform:uppercase;letter-spacing:.05em}
.pokemon-league-connected-copy strong{display:block;margin-top:2px;font-size:11px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.pokemon-league-connected-copy span{display:block;margin-top:3px;color:#5f7468;font-size:8px;line-height:1.4}
.pokemon-league-connected .text-button{font-size:9px}

.pokemon-official-events-section{position:relative}
.pokemon-official-summary{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 10px;padding:12px 14px;border:1px solid #d9e2ef;border-radius:15px;background:linear-gradient(135deg,#f8fbff,#fff)}
.pokemon-official-summary strong{display:block;font-size:11px}.pokemon-official-summary span{display:block;margin-top:3px;color:var(--muted);font-size:8px}
.pokemon-official-card{border-color:#d7e1ef}
.pokemon-official-card-main{display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:14px;align-items:center;padding:16px;background:linear-gradient(135deg,#fff,#f9fbff)}
.pokemon-source-badge{padding:6px 8px;border-radius:999px;background:rgba(59,108,183,.09);color:var(--tc-blue);font-size:7px;font-weight:900;text-transform:uppercase;letter-spacing:.04em;white-space:nowrap}
.pokemon-official-card .event-card-actions a{display:inline-flex;align-items:center;border-radius:9px;padding:7px 9px;color:var(--muted);font-size:9px;font-weight:800;text-decoration:none}
.pokemon-official-card .event-card-actions a:hover{background:var(--surface-soft);color:var(--text)}
.pokemon-official-card .pokemon-import-action{background:rgba(59,108,183,.08);color:var(--tc-blue)}
.events-loading.compact{padding:18px}

.event-import-notice{display:flex;gap:10px;align-items:center;margin:0 0 14px;padding:11px 12px;border:1px solid #d7e1ef;border-radius:14px;background:#f5f9ff;color:var(--tc-navy)}
.event-import-notice>span{width:30px;height:30px;border-radius:10px;display:grid;place-items:center;background:#fff;color:var(--tc-blue);font-weight:950}
.event-import-notice strong{display:block;font-size:10px}.event-import-notice small{display:block;margin-top:2px;color:var(--muted);font-size:8px;line-height:1.4}
.event-info-row a{color:var(--tc-blue);text-decoration:none}.event-info-row a:hover{text-decoration:underline}

@media(max-width:699px){
  .pokemon-league-connect-form{grid-template-columns:1fr}.pokemon-league-connect-form .button{width:100%}
  .pokemon-league-connected{grid-template-columns:auto minmax(0,1fr)}.pokemon-league-connected .text-button{grid-column:1/-1;justify-self:start}
  .pokemon-official-summary{align-items:flex-start;flex-direction:column}.pokemon-official-summary .button{width:100%}
  .pokemon-official-card-main{grid-template-columns:auto minmax(0,1fr)}.pokemon-source-badge{grid-column:1/-1;justify-self:start}
}

.pokemon-summary-note{color:#8a641b!important;font-weight:800}


/* Modern Pokémon Event Locator connection */
.pokemon-locator-settings{margin-top:14px;padding-top:14px;border-top:1px dashed #d7dfeb}
.pokemon-locator-settings-head{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:14px;align-items:start}
.pokemon-locator-settings-head small{display:block;color:var(--tc-blue);font-size:7px;font-weight:900;text-transform:uppercase;letter-spacing:.06em}
.pokemon-locator-settings-head strong{display:block;margin-top:2px;font-size:11px}
.pokemon-locator-settings-head p{margin:4px 0 0;max-width:560px;color:var(--muted);font-size:8px;line-height:1.5}
.pokemon-locator-settings-head a{white-space:nowrap;color:var(--tc-blue);font-size:8px;font-weight:850;text-decoration:none}
.pokemon-locator-settings-head a:hover{text-decoration:underline}
.pokemon-locator-form{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:9px;align-items:end;margin-top:10px}
.pokemon-locator-form label>span{display:block;margin-bottom:5px;color:var(--muted);font-size:8px;font-weight:900;text-transform:uppercase;letter-spacing:.05em}
.pokemon-locator-form input{width:100%;height:42px;border:1px solid var(--line);border-radius:12px;background:#fff;padding:0 12px;color:var(--text);font:inherit;font-size:10px}
.pokemon-locator-form input:focus{outline:none;border-color:rgba(var(--accent-rgb),.55);box-shadow:0 0 0 3px rgba(var(--accent-rgb),.08)}
.pokemon-locator-connected{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:10px;align-items:center;margin-top:10px;padding:11px 12px;border:1px solid #d8e4f2;border-radius:14px;background:#f5f9ff}
.pokemon-locator-connected small{display:block;color:var(--tc-blue);font-size:7px;font-weight:900;text-transform:uppercase;letter-spacing:.05em}
.pokemon-locator-connected strong{display:block;margin-top:2px;font-size:10px}
.pokemon-locator-connected span{display:block;margin-top:2px;color:var(--muted);font-size:8px;line-height:1.4}
.pokemon-locator-connected .text-button{font-size:8px;white-space:nowrap}

@media(max-width:699px){
  .pokemon-locator-settings-head{grid-template-columns:1fr}
  .pokemon-locator-settings-head a{justify-self:start}
  .pokemon-locator-form{grid-template-columns:1fr}
  .pokemon-locator-form .button{width:100%}
  .pokemon-locator-connected{grid-template-columns:1fr}
  .pokemon-locator-connected .text-button{justify-self:start}
}
