:root{color-scheme:dark;--bg:#151917;--panel:#1d2320;--line:#394039;--text:#ede9dd;--muted:#aaaFA4;--gold:#d0b47c;--red:#c47c68;--green:#9aba92}*{box-sizing:border-box}body{margin:0;background:radial-gradient(ellipse at 80% 0,#30372a55,transparent 45%),var(--bg);color:var(--text);font:14px/1.5 Manrope,system-ui,sans-serif}button,input,select{font:inherit}button,.file-button{cursor:pointer;border:1px solid var(--line);border-radius:6px;background:#272e29;color:var(--text);padding:9px 13px;transition:background .15s}button:hover,.file-button:hover{background:#394338}button:disabled{opacity:.4;cursor:default}button.primary,.file-button.primary{background:var(--gold);color:#24291f;border-color:var(--gold);font-weight:700}button.primary:hover,.file-button.primary:hover{background:#e0c898}button.text-button{padding:2px;border:0;background:none;color:var(--gold)}a{color:var(--gold)}input,select{width:100%;min-width:0;border:1px solid var(--line);background:#171d19;color:var(--text);border-radius:6px;padding:10px}input:focus,select:focus,button:focus-visible,.file-button:focus-within{outline:2px solid var(--gold);outline-offset:3px}label{display:block;font-size:12px;color:#c6cbbb}label input,label select{margin-top:7px;font-size:14px}h1,h2,h3,p{margin:0}h1,h2{font-family:'Cormorant Garamond',Georgia,serif;font-weight:500}h1{font-size:48px;line-height:1.12}h2{font-size:28px;line-height:1.15}h3{font-size:15px;margin:20px 0 12px}.muted{color:var(--muted);font-size:13px;line-height:1.6}.eyebrow{font-size:10px;letter-spacing:2px;color:var(--gold);margin-bottom:9px}.prototype{display:flex;justify-content:center;gap:18px;padding:7px 20px;background:#363b2e;color:#d8d7b8;font-size:10px;letter-spacing:1.4px}.prototype span{letter-spacing:0;color:#c1c4b3}.topbar{display:flex;align-items:center;gap:35px;min-height:86px;padding:0 36px;border-bottom:1px solid var(--line);background:#191f1be8}.wordmark{font-family:Georgia,serif;color:var(--text);letter-spacing:2px;text-decoration:none;position:relative;padding-left:41px;font-size:16px}.wordmark small{display:block;font:9px/2 Manrope,sans-serif;letter-spacing:2.1px;color:var(--muted)}.sigil{position:absolute;left:0;top:-7px;color:var(--gold);font-size:38px}nav{display:flex;gap:20px;align-self:stretch;align-items:stretch;flex:1}nav button{border:0;background:none;border-radius:0;color:var(--muted);padding:0 2px}nav button.active{color:var(--gold);box-shadow:inset 0 -2px var(--gold)}#nav-count{display:inline-block;background:#343d32;border-radius:4px;font-size:11px;padding:1px 5px;margin-left:5px}main{max-width:1600px;margin:auto;padding:34px 36px 50px}.page-heading{display:flex;align-items:center;justify-content:space-between;gap:24px;margin-bottom:30px}.page-heading .muted{margin-top:10px}.collection-seals{display:flex;gap:10px}.seal{display:block;padding:11px 14px;border:1px solid var(--line);border-radius:8px;font-size:12px}.seal b{margin-left:14px}.seal.red{color:#e1a391;border-color:#754c3e;background:#5f302920}.seal.green{color:#b3cf9a;border-color:#4e6242;background:#40543130}.workbench{display:grid;grid-template-columns:186px minmax(0,1fr) 235px;gap:26px;align-items:start}.filters{padding-right:18px;border-right:1px solid var(--line)}.filter-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:18px}.filter-heading h2{font-size:23px}.filter-heading button{font-size:11px}.filters label{margin:17px 0}.origin-key{font-size:11px;color:var(--muted);line-height:1.9}.origin-key span{display:flex;justify-content:space-between}fieldset{border:0;padding:0;margin:21px 0}legend{font-size:12px;margin-bottom:10px;color:#c6cbbb}.colors{display:flex;flex-wrap:wrap;gap:6px}.colors button{width:29px;height:29px;padding:0;border-radius:50%;font-size:11px;color:#e5e5da;background:#303830}.colors button[data-color=R]{background:#6c3c30}.colors button[data-color=G]{background:#3c573d}.colors button[data-color=W]{background:#bcaf8e;color:#222}.colors button[data-color=U]{background:#365974}.colors button[data-color=B]{background:#463948}.colors button.active{outline:2px solid var(--gold);outline-offset:2px}.filter-note{font-size:11px;color:var(--muted);padding-top:20px;border-top:1px solid var(--line)}.searchbar{display:flex;align-items:center;gap:12px}.search-label{flex:1}.search-label input{margin:0;padding:12px 14px}.view-switch{display:flex}.view-switch button{font-size:21px;line-height:1;padding:10px}.view-switch button.active{background:#475039;color:var(--gold)}.results-line{display:flex;justify-content:space-between;align-items:center;margin:18px 0;color:var(--muted);font-size:11px;gap:10px}.results-line label{display:flex;align-items:center;gap:7px;font-size:11px}.results-line select{font-size:11px;margin:0;padding:5px;width:auto}#cards.gallery{display:grid;grid-template-columns:repeat(auto-fill,minmax(132px,1fr));gap:20px 14px}.card-tile{min-width:0}.art-button{padding:0;width:100%;border:0;background:none;display:block;position:relative;text-align:left}.art-button:hover{background:none}.card-tile img{display:block;width:100%;aspect-ratio:488/680;object-fit:contain;border-radius:9px;box-shadow:0 7px 16px #0006;transition:transform .16s}.art-button:hover img{transform:translateY(-3px)}.card-tile h3{font:600 12px/1.5 Manrope,sans-serif;margin:9px 0 2px;overflow-wrap:anywhere}.tile-sub{display:flex;justify-content:space-between;gap:8px;color:var(--muted);font-size:11px}.tile-kind{font-size:10px;color:#c7b17f;margin-top:3px}.card-tile .count{position:absolute;right:6px;bottom:7px;background:#121710ef;color:#f2e3bd;border:1px solid #8b7950;border-radius:5px;padding:3px 7px;font-size:12px}.pagination{display:flex;justify-content:center;align-items:center;gap:14px;margin-top:25px;font-size:12px;color:var(--muted)}.draft-rail{padding:20px 17px;background:linear-gradient(130deg,#30362955,transparent),#20271f;border:1px solid #46513c;border-radius:9px;position:sticky;top:20px}.draft-rail h2{overflow-wrap:anywhere}.draft-rail>.muted{font-size:11px;margin-top:5px}.deck-number{display:flex;align-items:baseline;gap:12px;border-bottom:1px solid #454e3e;padding:18px 0}.deck-number strong{font:42px/1 Georgia,serif;color:var(--gold)}.deck-number span{font-size:11px;color:var(--muted)}.empty-small{padding:26px 0;color:var(--muted);font-size:12px}.full{width:100%}.rail-footnote{font-size:10px;color:var(--muted);margin-top:12px}.rail-row{display:flex;justify-content:space-between;align-items:center;gap:6px;font-size:11px;padding:10px 0;border-bottom:1px solid #394231}.rail-row button{padding:0;background:none;border:0;text-align:left;font-size:11px;color:#e3dec9}.rail-row b{color:var(--gold)}#rail-cards{margin-bottom:18px}.empty-state{padding:45px 22px;border:1px dashed var(--line);border-radius:9px;grid-column:1/-1;text-align:center;color:var(--muted)}.empty-state h2{color:var(--text);margin-bottom:10px}.empty-state button{margin-top:15px}.card-list-row{display:grid;grid-template-columns:40px minmax(0,1fr) 70px 55px;gap:12px;align-items:center;width:100%;padding:9px;margin:7px 0;text-align:left}.card-list-row img{width:40px;border-radius:3px}.card-list-row small{display:block;color:var(--muted)}.deck-layout{display:grid;grid-template-columns:minmax(0,1fr) 320px;gap:25px}.panel{border:1px solid var(--line);background:var(--panel);padding:25px;border-radius:10px}.deck-summary{display:flex;flex-wrap:wrap;gap:22px;margin:25px 0;color:var(--muted)}.deck-summary b{color:var(--text);font-size:22px}.deck-row{display:grid;grid-template-columns:48px minmax(0,1fr) auto;align-items:center;gap:15px;padding:14px 0;border-bottom:1px solid var(--line)}.deck-row img{width:48px;border-radius:4px}.deck-row button.inspect-name{padding:0;background:none;border:0;text-align:left}.deck-row small{display:block;color:var(--muted);font-size:11px}.stepper{display:flex;align-items:center;gap:9px}.stepper button{padding:5px 10px}.deck-actions{display:flex;gap:12px;margin-top:24px;flex-wrap:wrap}#saved-status{margin-top:12px}#deck-origin{margin-top:18px}.origin-line{display:flex;justify-content:space-between;gap:10px;padding:8px 0;border-bottom:1px solid var(--line);font-size:12px}.mana-curve{display:flex;gap:8px;align-items:end;height:130px;padding-top:20px}.curve-bin{flex:1;text-align:center;font-size:11px;display:flex;flex-direction:column;justify-content:end;align-items:stretch;height:100%;color:var(--muted)}.curve-bin i{display:block;background:#bca471;margin:4px 0;min-height:2px;border-radius:2px 2px 0 0}dialog{background:#1d241f;color:var(--text);border:1px solid #667050;border-radius:12px;width:min(900px,calc(100% - 32px));max-height:calc(100dvh - 40px);padding:0;box-shadow:0 24px 100px #0009}dialog::backdrop{background:#080e0cd9;backdrop-filter:blur(5px)}.dialog-bar{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 24px;border-bottom:1px solid var(--line);position:sticky;top:0;background:#1d241f;z-index:2;font-size:10px;letter-spacing:1.5px;color:var(--gold)}.dialog-bar button{padding:4px 8px}.detail-layout{display:grid;grid-template-columns:270px minmax(0,1fr);gap:28px;padding:28px}.detail-art img{width:100%;border-radius:12px}.detail-art p{font-size:10px;margin-top:10px}.detail-layout h2{font-size:35px}.card-meta{font-size:12px;color:var(--muted);margin:7px 0 15px}.mana-symbols{display:inline-flex;gap:3px}.mana-symbol{display:inline-flex;align-items:center;justify-content:center;min-width:20px;height:20px;border-radius:50%;background:#cec5b3;color:#282820;font:600 11px Manrope,sans-serif}.mana-symbol.R{background:#c17965}.mana-symbol.G{background:#91ad80}.roles{display:flex;gap:6px;flex-wrap:wrap;margin:15px 0}.roles span{font-size:11px;background:#343f30;color:#b9c7a7;padding:3px 8px;border-radius:4px}.lot-row{border-top:1px solid var(--line);padding:12px 0;display:flex;align-items:center;justify-content:space-between;gap:12px}.lot-row p{font-size:12px}.lot-row small{display:block;font-size:10px;color:var(--muted)}.lot-actions{display:flex;align-items:center;gap:8px}.lot-actions b{min-width:20px;text-align:center;color:var(--gold)}.lot-actions button{font-size:11px;padding:7px 9px}.classify{background:#272f25;border-radius:7px;padding:12px;margin-top:12px}.classify summary{cursor:pointer;font-size:12px;color:var(--gold)}.classify form{display:grid;grid-template-columns:1fr 65px;gap:10px;margin-top:14px}.classify form .wide{grid-column:1/-1}.classify form button{grid-column:1/-1}.oracle{white-space:pre-wrap;font-size:12px;color:#c4c9bc;line-height:1.7}.detail-bottom{display:flex;gap:8px;margin-top:20px}.add-content{padding:28px;display:grid;grid-template-columns:1fr 1fr;gap:28px}.add-content h2{font-size:32px}.add-content .muted{margin:12px 0}.add-content label{margin-bottom:13px}.add-content h3{margin-top:0}.photo-actions{display:flex;gap:8px;flex-wrap:wrap}.file-button{display:block;font-size:12px!important;position:relative;overflow:hidden;margin-bottom:0!important}.file-button input{position:absolute;width:1px;height:1px;opacity:0;left:0;bottom:0}.photo-stage{display:flex;align-items:center;justify-content:center;min-height:220px;margin-top:16px;background:#141b16;border:1px dashed #526149;border-radius:9px;color:var(--muted);font-size:12px}.photo-stage img{max-height:300px;max-width:100%;object-fit:contain}.scan-note{border-top:1px solid var(--line);padding-top:14px;font-size:12px;color:var(--muted)}.scan-note p{margin-top:5px}#toast{position:fixed;bottom:22px;left:50%;transform:translateX(-50%);padding:12px 20px;background:#dfcea1;color:#242a1f;border-radius:8px;box-shadow:0 10px 40px #0009;z-index:20;max-width:calc(100% - 30px);font-size:13px}footer{text-align:center;padding:25px;font-size:10px;color:var(--muted);border-top:1px solid var(--line)}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}[hidden]{display:none!important}






@media(min-width:1450px){#cards.gallery{grid-template-columns:repeat(5,minmax(0,1fr))}}@media(max-width:1150px){.workbench{grid-template-columns:155px minmax(0,1fr) 190px;gap:18px}main{padding:28px 22px}.topbar{padding:0 22px;gap:25px}.collection-seals{display:none}#cards.gallery{grid-template-columns:repeat(3,minmax(0,1fr))}.draft-rail{padding:16px 12px}.draft-rail h2{font-size:25px}}@media(max-width:850px){.workbench{grid-template-columns:150px minmax(0,1fr)}.draft-rail{position:static;grid-column:1/-1;display:grid;grid-template-columns:1fr 1fr;gap:5px 20px}.draft-rail .deck-number{grid-row:1/4;grid-column:2}.draft-rail #rail-cards{grid-column:1/-1}.draft-rail .full{grid-column:1/-1}.deck-layout{grid-template-columns:1fr}.topbar{flex-wrap:wrap;gap:10px 25px;padding:18px 22px}nav{order:3;flex-basis:100%;gap:25px}nav button{padding:9px 0}.topbar>.primary{margin-left:auto}.detail-layout{grid-template-columns:210px 1fr;gap:20px;padding:20px}.detail-layout h2{font-size:29px}}@media(max-width:600px){.prototype{font-size:9px;letter-spacing:.7px;display:block;text-align:center}.prototype span{display:block;font-size:10px;margin-top:2px}.topbar{padding:14px 16px}.wordmark{font-size:13px;padding-left:32px}.wordmark small{font-size:8px}.sigil{font-size:29px;top:-3px}.topbar>.primary{padding:9px;font-size:12px}main{padding:24px 16px}h1{font-size:40px}.page-heading{margin-bottom:23px}.page-heading>.primary{font-size:12px}.eyebrow{font-size:9px}.workbench{display:block}.filters{border:0;padding:0;display:grid;grid-template-columns:1fr 1fr;gap:8px 12px;margin-bottom:23px}.filter-heading{grid-column:1/-1;margin-bottom:0}.filters label{margin:0}.filters .origin-key{grid-row:2;grid-column:2;align-self:center}.filters fieldset{margin:8px 0;grid-column:1/-1}.filters .filter-note{display:none}.filters input,.filters select{font-size:16px;padding:8px}.filters label:last-of-type{grid-column:1/-1}.searchbar input{font-size:16px}#cards.gallery{grid-template-columns:repeat(2,minmax(0,1fr));gap:20px 14px}.results-line{align-items:start}.results-line label{display:block}.results-line select{margin-top:4px;max-width:175px}.draft-rail{margin-top:25px}.detail-layout{display:block;padding:20px}.detail-art{max-width:200px;margin:0 auto 20px}.detail-layout h2{font-size:30px}.dialog-bar{padding:12px 16px}.add-content{grid-template-columns:1fr;padding:20px}.add-content input,.add-content select,.classify input,.classify select{font-size:16px}.panel{padding:18px}.deck-row{grid-template-columns:35px minmax(0,1fr) auto;gap:8px}.deck-row img{width:35px}.deck-row button.inspect-name{font-size:12px}.stepper{gap:6px}.stepper button{min-width:36px;min-height:38px}.card-list-row{grid-template-columns:32px minmax(0,1fr) 40px;gap:8px}.card-list-row img{width:32px}.card-list-row .list-type{display:none}.lot-row{gap:8px}.lot-actions{gap:4px}.lot-actions button{padding:9px 8px}.detail-bottom{flex-wrap:wrap}.file-button{min-height:42px}footer{font-size:10px}}






#toggle-filters{display:none}






@media(max-width:600px){#toggle-filters{display:block;font-size:13px}.filter-heading h2{display:none}.filters:not(.expanded)>fieldset,.filters:not(.expanded)>label:not(:first-of-type){display:none}.filters .filter-heading{margin-bottom:7px}.filters label:first-of-type{grid-column:1;grid-row:2}.filters .origin-key{grid-column:2;grid-row:2}}













.text-disclosure{margin-top:22px;cursor:pointer;color:var(--muted)}






.curve-height-0{height:0px}.curve-height-1{height:1px}.curve-height-2{height:2px}.curve-height-3{height:3px}.curve-height-4{height:4px}.curve-height-5{height:5px}.curve-height-6{height:6px}.curve-height-7{height:7px}.curve-height-8{height:8px}.curve-height-9{height:9px}.curve-height-10{height:10px}.curve-height-11{height:11px}.curve-height-12{height:12px}.curve-height-13{height:13px}.curve-height-14{height:14px}.curve-height-15{height:15px}.curve-height-16{height:16px}.curve-height-17{height:17px}.curve-height-18{height:18px}.curve-height-19{height:19px}.curve-height-20{height:20px}.curve-height-21{height:21px}.curve-height-22{height:22px}.curve-height-23{height:23px}.curve-height-24{height:24px}.curve-height-25{height:25px}.curve-height-26{height:26px}.curve-height-27{height:27px}.curve-height-28{height:28px}.curve-height-29{height:29px}.curve-height-30{height:30px}.curve-height-31{height:31px}.curve-height-32{height:32px}.curve-height-33{height:33px}.curve-height-34{height:34px}.curve-height-35{height:35px}.curve-height-36{height:36px}.curve-height-37{height:37px}.curve-height-38{height:38px}.curve-height-39{height:39px}.curve-height-40{height:40px}.curve-height-41{height:41px}.curve-height-42{height:42px}.curve-height-43{height:43px}.curve-height-44{height:44px}.curve-height-45{height:45px}.curve-height-46{height:46px}.curve-height-47{height:47px}.curve-height-48{height:48px}.curve-height-49{height:49px}.curve-height-50{height:50px}.curve-height-51{height:51px}.curve-height-52{height:52px}.curve-height-53{height:53px}.curve-height-54{height:54px}.curve-height-55{height:55px}.curve-height-56{height:56px}.curve-height-57{height:57px}.curve-height-58{height:58px}.curve-height-59{height:59px}.curve-height-60{height:60px}.curve-height-61{height:61px}.curve-height-62{height:62px}.curve-height-63{height:63px}.curve-height-64{height:64px}.curve-height-65{height:65px}.curve-height-66{height:66px}.curve-height-67{height:67px}.curve-height-68{height:68px}.curve-height-69{height:69px}.curve-height-70{height:70px}.curve-height-71{height:71px}.curve-height-72{height:72px}.curve-height-73{height:73px}.curve-height-74{height:74px}.curve-height-75{height:75px}.curve-height-76{height:76px}.curve-height-77{height:77px}.curve-height-78{height:78px}.curve-height-79{height:79px}.curve-height-80{height:80px}













.collection-catalog .workbench{grid-template-columns:186px minmax(0,1fr)}






.collection-catalog .menu-back{margin-left:auto;text-decoration:none;font-size:13px}






.collection-catalog .lot-actions button,.collection-catalog .detail-bottom,.collection-catalog #deck-page{display:none!important}






@media(max-width:850px){.collection-catalog .workbench{grid-template-columns:150px minmax(0,1fr)}}






@media(max-width:600px){.collection-catalog .workbench{display:block}.collection-catalog .menu-back{order:3;margin:4px 0 0;flex-basis:100%}}

/* ECOSYSTEM THEME — generated by tools/build_ecosystem_theme.py */
/* Dragon Table: общий визуальный язык меню, инструментов и игры. */
:root {
  --dt-bg:#101814; --dt-panel:#1b2821; --dt-raised:#29382c;
  --dt-text:#efe9d8; --dt-muted:#b8c1b1; --dt-gold:#d6bc83;
  --dt-line:#647052; --dt-focus:#f1d49a; --dt-radius:10px;
  --dt-button:linear-gradient(145deg,#344332,#233027);
  --dt-primary:linear-gradient(145deg,#e0c998,#c5a66c);
  --dt-font:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
}
body:not(.table-shell) {
  color-scheme:dark; --ink:var(--dt-text); --text:var(--dt-text);
  --muted:var(--dt-muted); --paper:var(--dt-panel); --panel:var(--dt-panel);
  --bg:var(--dt-bg); --accent:var(--dt-gold); --gold:var(--dt-gold); --line:var(--dt-line);
  color:var(--dt-text); font-family:var(--dt-font);
}
body:not(.table-shell):not(.menu-page):not(:has(.home)) {
  background:radial-gradient(ellipse at 80% 0,#38442d66,transparent 55%),var(--dt-bg);
  min-height:100svh;
}
body:not(.table-shell) :is(h1,h2) {font-family:Georgia,serif;font-weight:400;color:var(--dt-text)}
body:not(.table-shell) .eyebrow {color:var(--dt-gold)}
body:not(.table-shell) button:not(:where(.art-button,.card-list-row,.menu-card,.menu-item,.text-button,.colors button,.saved-deck-cover,.saved-deck-name,.saved-deck-results,.saved-deck-menu)),
body:not(.table-shell) .file-button,
body .dt-nav a {
  border:1px solid var(--dt-line); border-radius:var(--dt-radius);
  background:var(--dt-button); color:var(--dt-text);
  min-height:44px; padding:10px 14px; font-family:var(--dt-font); font-weight:600;
  line-height:1.3; touch-action:manipulation; cursor:pointer;
  box-shadow:inset 0 1px 0 #ffffff0a,0 3px 9px #030a0526;
  transition:background .15s,border-color .15s,box-shadow .15s;
}
body:not(.table-shell) :is(button.primary,.file-button.primary,button[aria-pressed=true],.view-switch button.active),
body:not(.table-shell) :is(#camera,#retry-card,#add,#join-submit,#open-session,#start,#solo,#book-open,#accept,#check) {
  background:var(--dt-primary); color:#19241c; border-color:var(--dt-gold);
}
@media(hover:hover) {
  body:not(.table-shell) button:not(:where(:disabled,.art-button,.card-list-row,.menu-card,.menu-item,.colors button,.saved-deck-cover,.saved-deck-name,.saved-deck-results,.saved-deck-menu)):hover,
  body .dt-nav a:hover {border-color:var(--dt-gold);box-shadow:inset 0 0 0 1px #d6bc8344,0 4px 14px #0004}
}
body:not(.table-shell) button:disabled {opacity:.45;cursor:default;box-shadow:none}
body:not(.table-shell) :is(input:not([type=checkbox]):not([type=radio]),select,textarea) {
  color-scheme:dark; background:#111c16; color:var(--dt-text); border:1px solid var(--dt-line);
  border-radius:var(--dt-radius); font-family:var(--dt-font); font-size:16px; min-height:44px;
}
body:not(.table-shell) input::placeholder {color:#99a592;opacity:1}
body:not(.table-shell) input[type=checkbox] {accent-color:var(--dt-gold)}
body:not(.table-shell) :is(button,a,input,select,textarea,summary):focus-visible {
  outline:3px solid var(--dt-focus);outline-offset:3px;
}
body:not(.table-shell) a:not(:where(.menu-card,.menu-item,.wordmark)) {color:var(--dt-gold)}
body .dt-nav {display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:0 0 24px;flex:none;align-self:auto}
body .dt-nav a {display:inline-flex;align-items:center;text-decoration:none;font-size:13px}
body .dt-nav a[aria-current=page] {border-color:var(--dt-gold);background:#514b32;color:var(--dt-text)}
body:not(.table-shell) dialog {color-scheme:dark;border-radius:16px;border-color:var(--dt-line);box-shadow:0 24px 80px #0008}
body:not(.table-shell) dialog::backdrop {background:#050b08cc}
@media(prefers-reduced-motion:reduce) {body button,body .dt-nav a {transition:none}}

/* Спокойная системная типографика; декоративный шрифт только в логотипе/меню. */
body:not(.table-shell):not(.menu-page):not(:has(.home)) {font-size:15px;line-height:1.55}
body:not(.table-shell):not(.menu-page):not(:has(.home)) :is(h1,h2,h3) {
  font-family:var(--dt-font);font-weight:600;line-height:1.25;letter-spacing:normal;
}
body:not(.table-shell) :is(button,input,select,textarea) {letter-spacing:normal}
body:not(.table-shell) button {hyphens:none;word-break:normal;overflow-wrap:normal}
body:not(.table-shell) :is(.summary-note,.price-lot small,.notice,.empty) {font-size:14px;line-height:1.55}

/* Shared green surfaces with slate buttons and gold accents. */
:root {
  --dt-bg:#101814;
  --dt-panel:#1b2821;
  --dt-raised:#29382c;
  --dt-text:#eee4cf;
  --dt-muted:#b7b6ab;
  --dt-gold:#d2ab63;
  --dt-line:#806a45;
  --dt-focus:#f2d48f;
  --dt-radius:5px;
  --dt-button:linear-gradient(180deg,#34414a,#222c35);
  --dt-primary:linear-gradient(180deg,#dfbd76,#a97837);
}

body:not(.table-shell) {
  background:
    radial-gradient(circle at 18% 0,#38442d66,transparent 34%),
    radial-gradient(circle at 100% 100%,#543b1e44,transparent 42%),
    repeating-linear-gradient(0deg,#ffffff03 0 1px,transparent 1px 4px),
    var(--dt-bg);
}

body.dt-tools {
  background:
    radial-gradient(circle at 50% -20%,#38442d44,transparent 48%),
    repeating-linear-gradient(0deg,#ffffff03 0 1px,transparent 1px 4px),
    var(--dt-bg);
}

body:not(.table-shell) :is(section,.tool-disclosure,.menu-dialog,dialog),
body.dt-tools :is(section,.tool-disclosure) {
  border-radius:var(--dt-radius);
  border-color:var(--dt-line);
  background:linear-gradient(145deg,#223127,#17251c);
  box-shadow:0 8px 24px #0006, inset 0 1px #ffffff12;
}

body.dt-tools .dt-tools-header {
  background:linear-gradient(180deg,#1b2821,#142119);
  border-bottom:1px solid var(--dt-line);
  box-shadow:0 3px 12px #0007;
}

body.dt-tools .dt-tools-brand,
body:not(.table-shell) :is(h1,h2,h3,h4) {
  text-shadow:1px 1px 0 #0008;
}

body:not(.table-shell) :is(button,.file-button,.dt-nav a):not(:where(.saved-deck-cover,.saved-deck-name,.saved-deck-results,.saved-deck-menu)),
body.dt-tools .collection-tools button {
  border-radius:var(--dt-radius);
  background:var(--dt-button);
  border-color:#8b7149;
  box-shadow:inset 0 1px #ffffff16, inset 0 -2px #0003, 0 3px 7px #0005;
}

body:not(.table-shell) :is(button.primary,.file-button.primary,button[aria-pressed=true],.view-switch button.active),
body:not(.table-shell) #play,
body:not(.table-shell) .menu-play,
body:not(.table-shell) .menu-dialog button:not(.quiet):not(.menu-close) {
  background:var(--dt-primary);
  border-color:#e3c47f;
  color:#201a12;
  text-shadow:none;
}

body:not(.table-shell) :is(input:not([type=checkbox]):not([type=radio]),select,textarea) {
  border-radius:var(--dt-radius);
  border-color:#756447;
  background:#111c16;
  box-shadow:inset 0 2px 5px #0006;
}

body.dt-tools .dt-nav a[aria-current=page] {background:#51432d;color:#f2dfb5}
body.dt-tools .badge {border-radius:var(--dt-radius);background:#3b3325;color:#e4c47e}
body:not(.table-shell) a:not(:where(.menu-card,.menu-item,.wordmark)) {color:#dfbd76}

body.dt-tools.menu-page > main.menu-shell {
  border-radius:var(--dt-radius);
  border-color:#92764a;
  box-shadow:0 10px 32px #0008, inset 0 0 0 1px #ffffff0b;
}

body.table-shell {
  --dt-bg:#101814; --dt-panel:#1b2821; --dt-raised:#29382c;
  --dt-text:#eee4cf; --dt-muted:#b7b6ab; --dt-gold:#d2ab63; --dt-line:#806a45;
  background:
    repeating-linear-gradient(0deg,#ffffff03 0 1px,transparent 1px 4px),
    var(--dt-bg);
}

body.table-shell :is(#mobile-table #m-rail,#mobile-table #m-overlay,dialog.m-mechanic-dialog) {
  border-radius:var(--dt-radius);
  box-shadow:0 12px 30px #0008, inset 0 1px #ffffff12;
}

body.collection-catalog .topbar {flex-wrap:wrap;gap:16px;padding:22px 36px;background:#16221bea;border-color:var(--dt-line)}
body.collection-catalog .topbar .dt-nav {margin:0 0 0 auto}
body.collection-catalog .wordmark {font:24px/1.2 Georgia,serif;letter-spacing:0}
body.collection-catalog .wordmark small {font-family:var(--dt-font);font-size:10px;letter-spacing:.15em;margin-top:5px}
body.collection-catalog :is(.draft-rail,.panel) {background:var(--dt-panel);border-color:var(--dt-line);border-radius:16px}
body.collection-catalog :is(.card-detail,.add-content) {background:var(--dt-panel);color:var(--dt-text)}
body.collection-catalog .colors button {width:44px;height:44px}
body.collection-catalog :is(.card-tile h3,.wordmark small) {font-family:var(--dt-font)}
body.collection-catalog .prototype {background:#202f24;color:var(--dt-muted);letter-spacing:.1em}
body.collection-catalog .filters {border-color:#46543f}
@media(max-width:650px) {
  body.collection-catalog .topbar {padding:20px 16px;gap:18px}
  body.collection-catalog .topbar .dt-nav {margin:0;width:100%}
}

body.collection-catalog .price-filter {min-width:0}
body.collection-catalog .price-bounds {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
body.collection-catalog .price-filter label {margin:0 0 12px}
body.collection-catalog .price-bounds input {padding:10px 6px;font-variant-numeric:tabular-nums}
body.collection-catalog .price-filter-note {font-size:11px;line-height:1.5;color:var(--dt-muted);margin:6px 0}
body.collection-catalog .tile-info {display:flex;align-items:center;flex-wrap:wrap;gap:4px;padding:8px 0 0;min-width:0}
body.collection-catalog .tile-meta {display:flex;align-items:center;flex:0 1 auto;flex-wrap:wrap;gap:2px 4px;min-width:0}
body.collection-catalog .copy-count {display:inline-flex;align-items:center;gap:1px;white-space:nowrap;color:var(--dt-text);font-size:12px;font-weight:650;line-height:20px;font-variant-numeric:tabular-nums}
body.collection-catalog .kind-icon {display:inline-grid;place-items:center;flex:none;width:20px;height:20px;line-height:0}
body.collection-catalog .kind-icon svg {display:block;width:20px;height:20px}
body.collection-catalog .kind-icon.kind-original {color:#e3c98e}
body.collection-catalog .kind-icon.kind-proxy {color:#b8d9ef}
body.collection-catalog .kind-icon.kind-unknown {color:#a2ada2}
body.collection-catalog .catalog-price {display:flex;flex-direction:column;gap:2px;min-width:0;color:var(--dt-gold);font-size:14px;line-height:20px;font-weight:600;margin:0;font-variant-numeric:tabular-nums}
body.collection-catalog .catalog-price-value {display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
body.collection-catalog .catalog-price.is-missing {color:var(--dt-muted)}
body.collection-catalog .catalog-price small {display:block;color:var(--dt-muted);font-size:11px;line-height:14px;font-weight:400;margin:0;overflow-wrap:anywhere}
body.collection-catalog .catalog-price small:empty {display:none}
body.collection-catalog .card-list-row .catalog-price {margin-top:5px}
body.collection-catalog .card-tile .catalog-price {flex:0 1 auto;min-width:0;max-width:100%;margin-left:auto;text-align:right}
body.collection-catalog .card-tile .catalog-price small {display:none}
body.collection-catalog .card-tile .art-button {aspect-ratio:488/680}
body.collection-catalog .card-tile .art-button :is(img,.no-art) {width:100%;height:100%;object-fit:contain}
body.collection-catalog .card-tile .no-art {display:grid;place-items:center;padding:12px;background:var(--dt-panel);border:1px solid var(--dt-line);border-radius:9px}
body.collection-catalog .card-list-row {grid-template-columns:40px minmax(0,1fr) auto}
@media(max-width:600px) {
  body.collection-catalog .price-bounds label {grid-column:auto;grid-row:auto}
  body.collection-catalog .results-line {flex-wrap:wrap}
  body.collection-catalog .results-line select {max-width:100%}
}

/* Whole-width collection with expandable filters. */
body.catalog-only .page-heading {gap:12px;margin:0 0 4px}
body.catalog-only .page-heading .muted {margin:4px 0 0}
body.catalog-only .collection-tools {margin:0;gap:6px}
body.catalog-only .storage-status {font-size:12px;color:var(--dt-muted);margin:0 0 10px}
body.catalog-only .workbench {display:block}
body.catalog-only .filters {display:grid;grid-template-columns:auto minmax(160px,220px) minmax(190px,250px) minmax(0,1fr);align-items:center;gap:8px 20px;border:1px solid #46543f;border-radius:10px;padding:8px 12px;margin-bottom:12px;background:var(--dt-panel)}
body.catalog-only .filter-heading {margin:0;gap:16px}
body.catalog-only .filter-heading h2 {display:none}
body.catalog-only #toggle-filters {display:block;font-size:13px;min-height:44px}
body.catalog-only #reset-filters {min-height:44px;font-size:12px}
body.catalog-only .filters > label {display:flex;align-items:center;gap:8px;margin:0;grid-column:auto;grid-row:auto}
body.catalog-only .filters > label select {margin:0}
body.catalog-only .origin-key {display:flex;justify-content:flex-end;flex-wrap:wrap;gap:4px 16px;grid-column:auto;grid-row:auto;line-height:1.5}
body.catalog-only .origin-key span {gap:6px;align-items:center}
body.catalog-only .filter-options {grid-column:1/-1;display:none;grid-template-columns:repeat(4,minmax(0,1fr));align-items:start;gap:10px 16px;border-top:1px solid #46543f;padding-top:12px}
body.catalog-only .filters.expanded .filter-options {display:grid}
body.catalog-only .filter-options > :is(label,fieldset) {margin:0;min-width:0}
body.catalog-only .filter-options .price-filter {grid-column:span 2;grid-row:span 3}
body.catalog-only .price-filter label {margin-bottom:6px}
body.catalog-only .price-help summary {cursor:pointer;font-size:12px;color:var(--dt-gold);min-height:44px;padding:10px 0}
body.catalog-only .filter-note {grid-column:3/-1;padding-top:8px}
body.catalog-only .searchbar {gap:8px}
body.catalog-only .results-line {margin:8px 0}
body.catalog-only .results-line select {font-size:13px;min-height:36px}
body.catalog-only #cards.gallery {grid-template-columns:repeat(auto-fill,minmax(116px,1fr));gap:12px 10px}
body.catalog-only .tile-info {gap:3px;padding-top:6px}
body.catalog-only .catalog-price {line-height:18px;font-size:13px}
body.catalog-only .catalog-price small {font-size:10px;line-height:13px}
body.catalog-only .pagination {margin-top:12px}
body.catalog-only .copy-count {font-size:11px}
body.catalog-only > footer {text-align:center}
@media(max-width:850px) {
  body.catalog-only .filters {grid-template-columns:auto minmax(0,1fr);gap:6px 12px}
  body.catalog-only .origin-key {grid-column:1/-1;justify-content:flex-start}
  body.catalog-only .filter-options {grid-template-columns:repeat(2,minmax(0,1fr))}
  body.catalog-only .filter-options .price-filter {grid-row:auto}
  body.catalog-only .filter-note {grid-column:1/-1}
}
@media(max-width:600px) {
  body.catalog-only .page-heading {flex-wrap:wrap;gap:8px}
  body.catalog-only .filters {padding:6px 8px}
  body.catalog-only .filters > label {font-size:0}
  body.catalog-only .filters > label select {font-size:14px}
  body.catalog-only .filter-heading {gap:10px}
  body.catalog-only .collection-tools button {font-size:11px;padding:8px}
  body.catalog-only .results-line {gap:4px}
  body.catalog-only .results-line label {width:100%}
  body.catalog-only .results-line select {flex:1}
  body.catalog-only #cards.gallery {grid-template-columns:repeat(auto-fill,minmax(108px,1fr));gap:12px 8px}
}

body.catalog-only .added-filter-note {margin:0 0 10px;font-size:12px;line-height:1.5;color:var(--dt-muted)}
@media(max-width:1100px) {
  body.catalog-only .filters {grid-template-columns:auto minmax(0,1fr) minmax(0,1fr)}
  body.catalog-only .origin-key {grid-column:1/-1;justify-content:flex-start}
}
@media(max-width:600px) {
  body.catalog-only .filters {grid-template-columns:minmax(0,1fr) minmax(0,1fr)}
  body.catalog-only .filter-heading {grid-column:1/-1}
  body.catalog-only .filters > label {min-width:0;display:grid;gap:2px;font-size:11px}
  body.catalog-only .filters > label select {width:100%;min-width:0;font-size:13px}
}
@media(max-width:600px) {body.catalog-only .filters:not(.expanded) > label.added-filter-label {display:grid}}

body.catalog-only .collection-total {display:flex;align-items:baseline;flex-wrap:wrap;gap:6px 18px;color:var(--dt-muted);font-size:13px}
body.catalog-only .collection-total span {display:inline-flex;align-items:baseline;gap:6px;white-space:nowrap}
body.catalog-only .collection-total strong {color:var(--dt-text);font-size:26px;line-height:1;font-variant-numeric:tabular-nums}
@media(max-width:600px) {body.catalog-only .collection-total strong {font-size:23px}}

/* The desktop collection uses the same centered canvas as statistics. */
@media(min-width:1001px) {
  body.catalog-only .page-heading {min-height:86px;padding:14px 18px;margin-bottom:12px;border:1px solid var(--dt-line);border-radius:10px;background:var(--dt-panel)}
  body.catalog-only .collection-total {display:flex;align-items:baseline;flex-wrap:wrap;gap:8px 28px;color:var(--dt-muted);font-size:13px}
  body.catalog-only .collection-total span {display:inline-flex;align-items:baseline;gap:7px;white-space:nowrap}
  body.catalog-only .collection-total strong {color:var(--dt-text);font-size:30px;line-height:1;font-variant-numeric:tabular-nums}
  body.catalog-only .collection-tools {justify-content:flex-end}
  body.catalog-only .filters {margin-bottom:12px}
  body.catalog-only #cards.gallery {grid-template-columns:repeat(auto-fill,minmax(148px,1fr));gap:16px 12px}
  body.catalog-only .tile-info {gap:4px;padding-top:8px}
  body.catalog-only .catalog-price {font-size:14px;line-height:20px}
  body.catalog-only .catalog-price small {font-size:11px;line-height:13px}
}
/* The filter panel follows three user questions: card, copies, price. */
body.catalog-only .filters {
  display:block;
  padding:0;
  overflow:hidden;
}
body.catalog-only .filter-heading {
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  align-items:center;
  gap:12px 20px;
  margin:0;
  padding:12px 18px;
}
body.catalog-only .filter-intro {min-width:0}
body.catalog-only .filter-title {display:flex;align-items:center;gap:8px}
body.catalog-only .filter-heading h2 {
  display:block;
  margin:0;
  font:600 16px/1.25 var(--dt-font);
}
body.catalog-only .filter-count {
  display:inline-grid;
  place-items:center;
  min-width:20px;
  height:20px;
  padding:0 5px;
  border:1px solid #8b7953;
  border-radius:6px;
  color:var(--dt-gold);
  font:600 11px/1 var(--dt-font);
}
body.catalog-only .filter-summary {
  margin:3px 0 0;
  overflow:hidden;
  color:var(--dt-muted);
  font-size:12px;
  line-height:1.4;
  text-overflow:ellipsis;
  white-space:nowrap;
}
body.catalog-only .filter-actions {display:flex;align-items:center;gap:12px}
body.catalog-only #reset-filters {min-height:36px;font-size:12px;white-space:nowrap}
body.catalog-only #toggle-filters {
  display:inline-flex;
  align-items:center;
  gap:9px;
  min-height:36px;
  padding:7px 12px;
  border:1px solid var(--dt-line);
  border-radius:8px;
  background:#26352a;
  color:var(--dt-text);
  font-size:13px;
  font-weight:600;
  white-space:nowrap;
}
body.catalog-only #toggle-filters::after {
  content:"";
  width:6px;
  height:6px;
  border-right:1.5px solid currentColor;
  border-bottom:1.5px solid currentColor;
  transform:rotate(45deg);
  transition:transform .15s;
}
body.catalog-only .filters.expanded #toggle-filters::after {transform:rotate(225deg)}
body.catalog-only .filter-options {
  display:none;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:0;
  padding:16px 18px 18px;
  border-top:1px solid #46543f;
}
body.catalog-only .filters.expanded .filter-options {display:grid}
body.catalog-only .filter-options .price-filter {grid-column:auto;grid-row:auto}
body.catalog-only .filter-group {min-width:0;padding:0 20px;border-left:1px solid #46543f}
body.catalog-only .filter-group:first-child {padding-left:0;border-left:0}
body.catalog-only .filter-group:last-child {padding-right:0}
body.catalog-only .filter-group-heading {margin:0 0 13px}
body.catalog-only .filter-group-heading h3 {
  margin:0;
  color:var(--dt-text);
  font:600 15px/1.25 var(--dt-font);
}
body.catalog-only .filter-group-heading p {margin:2px 0 0;color:var(--dt-muted);font-size:11px;line-height:1.35}
body.catalog-only .filter-group label,
body.catalog-only .filter-group legend {font-size:12px;line-height:1.35}
body.catalog-only .filter-group label {display:block;min-width:0;margin:0 0 12px}
body.catalog-only .filter-group :is(input,select) {
  width:100%;
  min-height:38px;
  margin-top:5px;
  padding:7px 10px;
  border-radius:8px;
  font-size:14px;
}
body.catalog-only .filter-row {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
body.catalog-only .filter-row label {grid-column:auto;grid-row:auto}
body.catalog-only .filter-color {min-width:0;margin:0 0 15px}
body.catalog-only .filter-color legend {padding:0}
body.catalog-only .colors {gap:7px;margin-top:7px}
body.catalog-only .colors button {width:36px;height:36px;min-height:36px;font-size:13px}
body.catalog-only .origin-key {
  display:flex;
  justify-content:flex-start;
  flex-wrap:wrap;
  gap:4px 12px;
  margin:-4px 0 14px;
  color:var(--dt-muted);
  font-size:11px;
  line-height:1.4;
}
body.catalog-only .origin-key span {display:inline-flex;align-items:center;justify-content:flex-start;gap:4px}
body.catalog-only .origin-key b {color:var(--dt-text);font-variant-numeric:tabular-nums}
body.catalog-only .filter-note {
  margin:0;
  padding:0;
  border:0;
  color:var(--dt-muted);
  font-size:11px;
  line-height:1.4;
}
body.catalog-only .price-filter label {margin-bottom:12px}
body.catalog-only .price-bounds {gap:10px}
body.catalog-only .price-bounds label {margin-bottom:0}
body.catalog-only .price-filter-note {margin:7px 0 2px;font-size:11px;line-height:1.4}
body.catalog-only .price-help summary {min-height:30px;padding:5px 0;font-size:12px}
@media(max-width:900px) {
  body.catalog-only .filter-options {grid-template-columns:repeat(2,minmax(0,1fr))}
  body.catalog-only .filter-group-copies {padding-right:0}
  body.catalog-only .filter-options .price-filter {
    display:grid;
    grid-column:1/-1;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:0 14px;
    margin-top:16px;
    padding:16px 0 0;
    border:0;
    border-top:1px solid #46543f;
  }
  body.catalog-only .price-filter .filter-group-heading,
  body.catalog-only .price-filter :is(#price-filter-error,#price-filter-status,.price-help) {grid-column:1/-1}
}
@media(max-width:600px) {
  body.catalog-only .filter-heading {padding:12px 14px}
  body.catalog-only .filter-options {grid-template-columns:minmax(0,1fr);padding:4px 14px 16px}
  body.catalog-only .filter-group,
  body.catalog-only .filter-group:first-child {
    padding:15px 0;
    border:0;
    border-top:1px solid #46543f;
  }
  body.catalog-only .filter-group:first-child {border-top:0}
  body.catalog-only .filter-options .price-filter {display:block;grid-column:1;margin:0;padding-bottom:0}
  body.catalog-only .filter-note {display:block}
  body.catalog-only .filter-group :is(input,select) {min-height:44px}
  body.catalog-only .colors button {width:40px;height:40px;min-height:40px}
}
@media(max-width:420px) {
  body.catalog-only .filter-heading {grid-template-columns:minmax(0,1fr);gap:9px}
  body.catalog-only .filter-actions {justify-content:space-between}
}

/* Collection actions sit below the shared overview instead of duplicating its counts. */
@media(min-width:1001px) {
  body.catalog-only .page-heading {min-height:0;padding:0;margin:0 0 12px;border:0;background:transparent}
}
body.catalog-only .page-heading {justify-content:flex-end;gap:8px;margin:0 0 12px}
body.catalog-only .collection-tools {justify-content:flex-end}

/* Mobile collection: the filter panel, results, and cards share the tools rhythm. */
body.catalog-only .results-summary {display:flex;align-items:center;gap:20px;margin:0 0 12px;padding:10px 14px;border:1px solid var(--dt-line);border-radius:10px;background:var(--dt-panel)}
body.catalog-only .result-metric {display:flex;align-items:baseline;gap:8px;min-width:0}
body.catalog-only .result-metric > span {color:var(--dt-muted);font-size:12px;line-height:1.3}
body.catalog-only .result-metric strong {color:var(--dt-text);font-size:24px;line-height:1.1;font-weight:700;font-variant-numeric:tabular-nums}
body.catalog-only .results-line {justify-content:flex-end}
body.catalog-only #search-hint.sr-only {position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
@media(max-width:700px) {
  body.catalog-only .results-summary {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0;margin:0 0 12px;padding:11px 12px}
  body.catalog-only .result-metric {display:flex;flex-direction:column;align-items:flex-start;gap:3px;padding:0 10px}
  body.catalog-only .result-metric:first-child {padding-left:0}
  body.catalog-only .result-metric + .result-metric {border-left:1px solid #ffffff1c}
  body.catalog-only .result-metric > span {font-size:12px}
  body.catalog-only .result-metric strong {font-size:29px}
  body.catalog-only .filter-heading {grid-template-columns:minmax(0,1fr) auto;gap:6px 8px;padding:11px 12px}
  body.catalog-only .filter-actions {justify-content:flex-end;gap:6px}
  body.catalog-only #reset-filters {padding:6px;font-size:12px}
  body.catalog-only #toggle-filters {min-height:44px;padding:8px 10px}
  body.catalog-only .filter-summary {white-space:normal;overflow-wrap:anywhere}
  body.catalog-only .filter-group-heading p,body.catalog-only .filter-note {display:none}
  body.catalog-only .filter-group-heading {margin-bottom:10px}
  body.catalog-only .filter-options {padding:2px 12px 14px}
  body.catalog-only .filter-group label,body.catalog-only .filter-group legend {font-size:13px}
  body.catalog-only .filter-group :is(input,select) {font-size:16px}
  body.catalog-only .results-line {margin:5px 0 10px}
  body.catalog-only .results-line label {width:auto;display:flex;align-items:center;gap:8px;font-size:12px}
  body.catalog-only .results-line select {margin:0;max-width:min(70vw,240px);min-height:44px;font-size:14px}
}
@media(max-width:350px) {
  body.catalog-only .filter-heading {padding:10px}
  body.catalog-only .filter-heading h2 {font-size:15px}
  body.catalog-only .result-metric strong {font-size:26px}
}

/* Keep filter controls beside the heading and file operations on their own row. */
body.catalog-only .filter-heading {grid-template-columns:minmax(0,1fr) auto}
body.catalog-only .filter-actions {grid-column:2;grid-row:1}
body.catalog-only .filter-heading .collection-tools {display:flex;align-items:center;justify-content:flex-end;flex-wrap:wrap;gap:8px;grid-column:1/-1;grid-row:2;min-width:0;margin:0;padding:10px 0 0;border-top:1px solid #64705280}
body.catalog-only .filter-heading .collection-tools[hidden] {display:none}
body.catalog-only .collection-tools button {display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:38px;padding:7px 12px;border:1px solid var(--dt-line);border-radius:8px;background:#26352a;color:var(--dt-text);font-size:12px;font-weight:600;line-height:1.25}
body.catalog-only .collection-tools button:hover {background:#354635;border-color:#84946c}
body.catalog-only .collection-tools .action-icon {color:var(--dt-gold);font-size:18px;font-weight:400;line-height:1}
body.catalog-only .collection-action-status {color:var(--dt-muted);font-size:11px;font-weight:400}
@media(max-width:700px) {
  body.catalog-only .filter-heading .collection-tools {gap:6px;align-items:stretch}
  body.catalog-only .collection-tools button {flex:1 1 0;min-width:0;min-height:44px;padding:7px 8px;font-size:12px;flex-wrap:wrap;gap:4px 6px}
  body.catalog-only .collection-tools .action-label-wide {white-space:normal}
}

@media(max-width:350px) {
  body.catalog-only .filter-actions {flex-wrap:wrap;justify-content:flex-end;max-width:118px}
}

/* The card detail keeps editing and valuation in one compact reading column. */
body.catalog-only #card-dialog {width:min(1060px,calc(100% - 24px));max-height:calc(100dvh - 28px);background:#1b251f;border-color:#697753}
body.catalog-only #card-dialog .dialog-bar {padding:9px 20px;background:#1b251f}
body.catalog-only #card-dialog .dialog-bar button {min-width:38px;min-height:38px}
body.catalog-only #card-detail .detail-layout {grid-template-columns:300px minmax(0,1fr);gap:26px;padding:22px}
body.catalog-only #card-detail .detail-art {min-width:0;background:radial-gradient(ellipse at 50% 34%,#a1843a22,transparent 72%)}
body.catalog-only #card-detail .detail-art img {display:block;width:100%;border:1px solid #b79c625c;border-radius:10px;box-shadow:0 16px 34px #0008,0 0 24px #ae8a4322}
body.catalog-only #card-detail .detail-art .muted {margin:8px 0 2px;font-size:11px;line-height:1.45}
body.catalog-only #card-detail .detail-art a {font-size:12px}
body.catalog-only #card-detail .detail-content {min-width:0}
body.catalog-only #card-detail .detail-heading {display:block;margin-top:16px}
body.catalog-only #card-detail .detail-heading h2 {margin:0;font:600 22px/1.2 var(--dt-font);overflow-wrap:anywhere}
body.catalog-only #card-detail .card-meta {margin:4px 0 0;color:var(--dt-muted);font-size:12px;line-height:1.4}
body.catalog-only #card-detail .detail-count {flex:none;padding:5px 9px;border:1px solid #6e795f;border-radius:999px;color:#e6cc91;font-size:12px;font-weight:700;white-space:nowrap}
body.catalog-only #card-detail .detail-section-heading {display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 10px}
body.catalog-only #card-detail .detail-section-title {margin:0;color:#d9dfd0;font-size:13px;font-weight:700}
body.catalog-only #card-detail .lot-editor {display:grid;grid-template-columns:70px minmax(110px,.85fr) minmax(120px,1fr) auto;gap:7px 8px;padding:9px;border:1px solid #485b45;border-radius:10px;margin:0 0 9px;background:#17221b}
body.catalog-only #card-detail .lot-printing-row {grid-column:1/-1;display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:stretch;gap:7px;min-width:0}
body.catalog-only #card-detail .lot-print {min-width:0;min-height:46px;padding:5px 8px;border:1px solid #78866770;border-radius:7px;background:#263329;color:var(--dt-text);text-align:left}
body.catalog-only #card-detail .lot-printing-row > .lot-print {grid-column:auto}
body.catalog-only #card-detail .lot-print.is-featured {border-color:#baab78;background:#2c392b}
body.catalog-only #card-detail .lot-print img {width:31px;max-height:43px;object-fit:contain}
body.catalog-only #card-detail .lot-print b {display:block;font-size:12px;line-height:1.35;color:var(--dt-text)}
body.catalog-only #card-detail .lot-print small {font-size:11px;color:#d0d7c5}
body.catalog-only #card-detail .lot-print em {font-size:11px}
body.catalog-only #card-detail .lot-editor.is-single .lot-print img {display:none}
body.catalog-only #card-detail .lot-print-unknown {display:flex;align-items:center}
body.catalog-only #card-detail .lot-print-unknown p {margin:0}
body.catalog-only #card-detail .lot-editor .edit-print {grid-column:auto;padding:6px 9px;color:var(--dt-gold);font-size:12px;white-space:nowrap}
body.catalog-only #card-detail .edit-print-short {display:none}
body.catalog-only #card-detail .lot-editor label {min-width:0;color:#becbb9;font-size:11px}
body.catalog-only #card-detail .lot-editor :is(input,select) {width:100%;min-height:34px;margin-top:2px;padding:5px 8px;border-color:#53664f;font-size:13px}
body.catalog-only #card-detail .lot-editor .lot-quantity {grid-column:1}
body.catalog-only #card-detail .lot-editor .lot-kind {grid-column:2}
body.catalog-only #card-detail .lot-editor .lot-location {grid-column:3}
body.catalog-only #card-detail .lot-editor .lot-save {grid-column:4;align-self:end;min-height:34px;padding:6px 10px;border-color:#a69162;background:#334431;color:#f3e6c6;font-size:12px;font-weight:700}
body.catalog-only #card-detail .lot-prices {grid-column:1/-1;min-width:0;padding-top:7px;border-top:1px solid #53664f77;color:var(--dt-muted);font-size:11px}
body.catalog-only #card-detail .classify {margin:9px 0 0;padding:0 10px;background:#253127;border:1px solid #44543f}
body.catalog-only #card-detail .classify > summary {min-height:38px;padding:9px 0;font-size:12px}
body.catalog-only #card-detail .classify form {margin:2px 0 10px}
body.catalog-only #card-detail .card-text {padding:0 10px}
body.catalog-only #card-detail .text-disclosure {min-height:38px;margin:0;padding:9px 0;font-size:12px}
body.catalog-only #card-detail .oracle {padding:0 0 10px}
body.catalog-only #card-detail .detail-prices {margin-top:5px}
body.catalog-only #card-detail .card-prices {margin:0;padding:12px;border:1px solid #596a4f;border-radius:10px;background:linear-gradient(125deg,#293927,#1e2b22)}
body.catalog-only #card-detail .price-heading {display:flex;align-items:baseline;justify-content:space-between;gap:10px;margin-bottom:9px}
body.catalog-only #card-detail .price-heading h3 {margin:0;color:#e6cc91;font-size:13px;font-weight:700}
body.catalog-only #card-detail .price-heading span {color:var(--dt-muted);font-size:11px}
body.catalog-only #card-detail .price-lot {padding:0;border:0}
body.catalog-only #card-detail .price-lot + .price-lot {padding-top:10px;margin-top:10px;border-top:1px solid #66765a77}
body.catalog-only #card-detail .price-lot-name {margin-bottom:7px;color:#dce5d2;font-size:12px;font-weight:700}
body.catalog-only #card-detail .price-quotes {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
body.catalog-only #card-detail .price-quote {display:flex;flex-wrap:wrap;align-items:baseline;justify-content:space-between;gap:1px 8px;min-width:0;padding:5px 8px;border:1px solid #53674e;border-radius:7px;background:#18251d;font-size:11px}
body.catalog-only #card-detail .price-quote a {text-decoration:none}
body.catalog-only #card-detail .price-quote strong {color:#f1e5bf;font-size:13px;font-variant-numeric:tabular-nums;white-space:nowrap}
body.catalog-only #card-detail .price-quote small {width:100%;color:#e1b889;font-size:10px;line-height:1.2}
body.catalog-only #card-detail .price-method {margin-top:5px;padding:0 10px;color:var(--dt-muted);font-size:11px;line-height:1.5}
body.catalog-only #card-detail .price-method summary {width:max-content;cursor:pointer;color:#bdcdb9}
body.catalog-only #card-detail .price-method p {margin:7px 0 0}
body.catalog-only #card-detail .price-sources {overflow-wrap:anywhere}
@media(max-width:880px) {
  body.catalog-only #card-detail .detail-layout {grid-template-columns:245px minmax(0,1fr);gap:18px;padding:18px}
  body.catalog-only #card-detail .lot-editor {grid-template-columns:78px minmax(0,1fr) auto}
  body.catalog-only #card-detail .lot-editor .lot-location {grid-column:1/3}
  body.catalog-only #card-detail .lot-editor .lot-save {grid-column:3}
}
@media(max-width:700px) {
  body.catalog-only #card-dialog {width:calc(100% - 12px);max-height:calc(100dvh - 12px)}
  body.catalog-only #card-dialog .dialog-bar {padding:7px 12px}
  body.catalog-only #card-dialog .dialog-bar span {font-size:9px;letter-spacing:.1em}
  body.catalog-only #card-detail .detail-layout {display:flex;flex-direction:column;gap:14px;padding:14px}
  body.catalog-only #card-detail .detail-art {display:flex;flex-direction:column;align-items:center;gap:4px;max-width:none;margin:0;text-align:center}
  body.catalog-only #card-detail .detail-art img,body.catalog-only #card-detail .detail-unconfirmed {width:min(58vw,226px);min-height:0}
  body.catalog-only #card-detail .detail-unconfirmed {min-height:250px;padding:14px}
  body.catalog-only #card-detail .detail-unconfirmed b {font-size:13px}
  body.catalog-only #card-detail .detail-unconfirmed span {display:none}
  body.catalog-only #card-detail .detail-art .muted {max-width:260px;margin:8px 0 0}
  body.catalog-only #card-detail .detail-heading h2 {font-size:21px}
  body.catalog-only #card-detail .detail-section-heading {margin-bottom:8px}
  body.catalog-only #card-detail .lot-editor {padding:9px;gap:8px}
  body.catalog-only #card-detail .price-quotes {gap:6px}
}
@media(max-width:400px) {
  body.catalog-only #card-detail .lot-printing-row {grid-template-columns:minmax(0,1fr) auto}
  body.catalog-only #card-detail .edit-print-full {display:none}
  body.catalog-only #card-detail .edit-print-short {display:inline}
  body.catalog-only #card-detail .lot-editor .edit-print {min-height:36px;padding:5px 7px}
  body.catalog-only #card-detail .lot-editor {grid-template-columns:76px minmax(0,1fr)}
  body.catalog-only #card-detail .lot-editor .lot-location {grid-column:1/3}
  body.catalog-only #card-detail .lot-editor .lot-save {grid-column:1/3}
  body.catalog-only #card-detail .price-quote {display:grid;gap:1px;padding:5px 6px}
}
@media(min-width:351px) and (max-width:400px) {
  body.catalog-only #card-detail .lot-editor {grid-template-columns:76px minmax(0,1fr) auto}
  body.catalog-only #card-detail .lot-editor .lot-kind {grid-column:2/4}
  body.catalog-only #card-detail .lot-editor .lot-location {grid-column:1/3}
  body.catalog-only #card-detail .lot-editor .lot-save {grid-column:3}
}

/* One locally served face for every shell screen, including Cyrillic and digits. */
@font-face {
  font-family:"Dragon Inter";
  src:url("/ui-font.woff2") format("woff2");
  font-style:normal;
  font-weight:100 900;
  font-display:swap;
}
body.dt-tools {
  --dt-font:"Dragon Inter",Arial,sans-serif;
  font-family:var(--dt-font);
  font-size:15px;
  line-height:1.5;
  font-optical-sizing:auto;
  font-variant-numeric:lining-nums tabular-nums;
}
/* Legacy components contain font shorthands; keep only their size and line height. */
body.dt-tools,body.dt-tools * {font-family:var(--dt-font)!important}
body.dt-tools :is(h1,h2,h3,h4,.dt-tools-brand,.overview-rank-top strong) {
  font-weight:600;
  line-height:1.3;
  letter-spacing:normal;
}
body.dt-tools .dt-tools-brand {font-weight:600;letter-spacing:normal}
body.dt-tools :is(button,input,select,textarea) {letter-spacing:normal}
body.dt-tools :is(input,select,textarea) {font-size:16px}
body.dt-tools :is(p,li,.notice,.empty,.muted,.summary-note) {line-height:1.5}
body.dt-tools :is(.eyebrow,.prototype,.dialog-bar span) {letter-spacing:normal}
body.dt-tools .overview-metric-primary strong {letter-spacing:normal}
body.dt-tools .overview-rank-top strong {font-size:20px}
body.dt-tools :is(.overview-metric span,.overview-rank-top span,.overview-rank-next,.overview-rank-scale,
 .summary-note,.price-coverage,.price-state,.price-grid small,.price-grid article > span,
 .kind-summary,.stat-line,.rank-progress p,.price-filter-note,.filter-group-heading p,
 .origin-key,.filter-active,.added-filter-note,.card-meta,.lot-print small,.lot-print em,
 .lot-editor label,.lot-prices,.price-heading span,.price-quote,.price-quote small,
 .price-method,.detail-art .muted,.tile-sub,.catalog-price small,.copy-count) {font-size:13px;line-height:1.45}
body.dt-tools .card-tile h3 {font-size:14px;line-height:1.4;font-weight:600}
body.dt-tools .catalog-price {font-size:14px;line-height:1.45}
body.dt-tools .overview-rank-next b {font-size:14px}
body.dt-tools .dt-tools-header .dt-nav a {font-size:14px;letter-spacing:normal}
body.dt-tools :is(.collection-tools button,#toggle-filters,#reset-filters,.text-disclosure,.edit-print,.lot-save) {font-size:13px}
@media(max-width:700px) {
  body.dt-tools .dt-tools-brand {font-size:18px}
  body.dt-tools .dt-tools-header .dt-nav a {font-size:12px;letter-spacing:normal}
  body.dt-tools .overview-rank-top strong {font-size:18px}
  body.dt-tools .menu-card {font-size:14px}
}
@media(max-width:360px) {
  body.dt-tools .dt-tools-header .dt-nav a {font-size:11px}
  body.dt-tools .menu-card {font-size:13px}
}
/* Small screens share one legible navigation size; links divide space by text width. */
@media(max-width:700px) {
  body.dt-tools .dt-tools-header .dt-nav {display:flex;flex-wrap:nowrap;gap:3px}
  body.dt-tools .dt-tools-header .dt-nav a,
  body.dt-tools:is(.has-panel-nav,.panel-page) .dt-tools-header .dt-nav a {
    flex:1 1 auto;padding:9px 2px;font-size:12px;letter-spacing:normal;
  }
}
body.dt-tools .results-line label {font-size:13px}
body.dt-tools #card-dialog .dialog-bar span {font-size:13px;letter-spacing:normal}
body.dt-tools #card-detail .lot-editor :is(input,select) {font-size:16px}
body.dt-tools #card-detail :is(.lot-editor label,.lot-print b,.lot-print small,.lot-print em,.lot-prices,.price-heading span,.price-quote small,.price-method,.detail-art .muted) {font-size:13px;line-height:1.45}
