/* The table is the hero. Brass marks actions; the surrounding chrome stays quiet. */
.ms-playtest-page {
  --pt-coal:#090a0d;
  --pt-felt:#171b1e;
  --pt-pane:#18191f;
  --pt-brass:#d4b577;
  --pt-ink:#eee8df;
  --pt-muted:#a39cab;
  background:var(--pt-coal);
}
.ms-playtest-page .ms-site-header {
  background:#0d0e12;
  border-bottom-color:#25262d;
}
.ms-playtest-page .ms-brand {color:var(--pt-ink);letter-spacing:-.15px}
.ms-playtest-page .ms-dev {background:#d4b57708;border-color:#d4b57735;color:#d4bc8d}
#deck-builder.ms-workspace {color:var(--pt-ink)}
#deck-builder.ms-workspace:focus {outline:none}
#deck-builder .ms-heading {background:#111217;border-radius:5px}
#deck-builder #ms-deck-name {font-weight:750;letter-spacing:-.2px}
#deck-builder .ms-heading button,
#deck-builder .ms-toolbar button,
#deck-builder .pt-field-actions button,
#deck-builder .pt-field-head button,
#deck-builder .pt-toolbar button,
#deck-builder details#ms-settings summary,
#deck-builder #ms-pod-panel>summary {
  border-color:#36343e;
  background:linear-gradient(#23232b,#1a1a22);
  box-shadow:inset 0 1px #ffffff06,0 1px 2px #0004;
  transition:background-color 150ms,border-color 150ms,box-shadow 150ms,color 150ms;
}
#deck-builder :is(.ms-heading,.ms-toolbar,.pt-field-actions,.pt-field-head) button:hover:not(:disabled),
#deck-builder #ms-pod-panel>summary:hover {
  border-color:#b69a657a;
  color:#f0dfbc;
  box-shadow:inset 0 1px #ffffff0a,0 2px 8px #0005;
}
#deck-builder :is(.ms-heading,.pt-field-actions,.pt-field-head,.ms-toolbar) button:active:not(:disabled) {
  background:#15151c;box-shadow:inset 0 2px 5px #0006;
}
#deck-builder .pt-toolbar button {display:inline-flex;align-items:center;gap:5px}
#deck-builder .pt-toolbar button kbd {margin-left:3px}
#deck-builder kbd {white-space:nowrap}
#deck-builder .pt-toolbar [data-pt-action=draw],
#deck-builder .ms-hand [data-hand-action=keep]:not(:disabled),
#deck-builder .ms-hand [data-hand-action=bottom]:not(:disabled) {
  color:#211a0f;
  background:linear-gradient(150deg,#e6cb92,#c5a464);
  border:1px solid #e4cc9a;
  box-shadow:inset 0 1px #fff5,0 2px 8px #0005;
}
#deck-builder .pt-toolbar [data-pt-action=draw]:hover:not(:disabled) {background:linear-gradient(150deg,#f0dba9,#d1b276);color:#211a0f}
#deck-builder .pt-toolbar [data-pt-action=draw] kbd {color:#45351e;border-color:#6d50283b;background:#fff2}
#deck-builder .pt-toolbar [data-pt-action=next]:not(:disabled) {color:#e1c893;border-color:#8c735145}
#deck-builder .pt-toolbar button:disabled {opacity:.38;filter:saturate(.45)}
#deck-builder .pt-toolbar [data-pt-action=undo],
#deck-builder .pt-toolbar [data-pt-action=redo] {background:transparent;box-shadow:none}
#deck-builder .pt-control-icon {width:12px;height:12px;flex:none;opacity:.85}
#deck-builder .pt-field-actions button {justify-content:start;gap:7px}
#deck-builder .pt-field-actions kbd,#deck-builder .pt-field-actions [data-pt-count] {margin-left:auto}
#deck-builder .pt-field-actions [data-pt-count] {background:#d4b57713;color:#e2c88f;border-radius:3px;padding:1px 5px;min-width:16px;text-align:center}
#deck-builder .pt-field-actions #pt-stack {margin-top:5px;border-color:#d4b5773b}
#deck-builder .ms-toolbar select {background-color:#171820;border-color:#30313b;color:#dbd5e1}
#deck-builder .ms-status {color:#97909f}

#deck-builder .pt-battlefield {
  background:var(--pt-felt);
  border-color:#4a4343;
  border-radius:6px;
  box-shadow:inset 0 0 0 1px #d4b5770b,inset 0 0 65px #0006,0 2px 8px #0005;
}
#deck-builder .pt-battlefield::before {
  opacity:1;
  background:
    radial-gradient(ellipse at 50% 42%,#12131740 0%,#0b0d10ad 76%),
    linear-gradient(110deg,#121917d9,#10131abc),
    var(--pt-playmat-art,none) center 38%/cover;
}
#deck-builder .pt-battlefield::after {
  content:'';position:absolute;inset:6px;z-index:-1;
  border:1px solid #d4b57713;border-radius:3px;pointer-events:none;
  background:repeating-linear-gradient(45deg,#ffffff01 0 1px,transparent 1px 5px);
}
#deck-builder .pt-field-head strong {text-transform:none;letter-spacing:.2px;font-weight:650;color:#aeb0af;font-size:11px}
#deck-builder #pt-turn {display:inline-flex;align-items:center;gap:5px;padding:2px 7px;border-radius:4px;background:#d4b5770f;border:1px solid #d4b57726;color:#e0c48d;font-weight:650}
#deck-builder #pt-turn::before {content:'';width:4px;height:4px;background:#d4b577;border-radius:50%}
#deck-builder .pt-field-head button {background:#101215b8;border-color:#ffffff13;color:#c8c0ce}
#deck-builder .pt-field-empty {color:#c1b7b0;font-size:13px;line-height:1.6;text-shadow:0 2px 12px #000b}
#deck-builder .pt-field-empty span {color:#a19a9f;font-size:11px}
#deck-builder .pt-field-empty::before {content:'';display:block;width:29px;height:40px;margin:0 auto 14px;border:1px solid #d4b57760;border-radius:4px;transform:rotate(-8deg);box-shadow:5px 2px 0 -1px #171b1e,5px 2px 0 0 #d4b57738}
#deck-builder .pt-field-actions button {background:linear-gradient(#202027e8,#18191ee8);border-color:#47414b;font-size:11px}
#deck-builder .pt-trackers {background:#15151ee8;border-color:#81705475;box-shadow:0 4px 18px #0006,inset 0 1px #ffffff08;padding:5px 6px}
#deck-builder .pt-trackers button {border:1px solid #ffffff10;background:#25232c;min-height:24px}
#deck-builder #pt-life {font-weight:750;font-variant-numeric:tabular-nums;color:#eee1c8}
#deck-builder #pt-mana button {display:flex;align-items:center;gap:4px;padding:2px 5px;color:#e8e3e9}
#deck-builder #pt-mana img {width:14px;height:14px;border-radius:50%;box-shadow:0 1px 3px #0004}
#deck-builder #pt-mana b {font-size:10px;min-width:7px;font-weight:650;font-variant-numeric:tabular-nums}
#deck-builder .pt-action-status {color:#e0d1b4;background:#111217b8;border:1px solid #d4b57720;border-radius:4px;padding:4px 8px;max-width:28%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#deck-builder .pt-action-status:empty {display:none}

#deck-builder .pt-dock-zone,#deck-builder .ms-hand {
  background:linear-gradient(#19181f,#111217);
  border-color:#423c46;
  border-radius:5px;
  box-shadow:inset 0 1px #ffffff04,0 2px 5px #0004;
}
#deck-builder .pt-dock {grid-template-columns:154px minmax(0,1fr)154px 154px 154px}
#deck-builder .pt-dock-zone .pt-card,#deck-builder .pt-library-back {width:min(139px,100%)}
#deck-builder .ms-hand {--pt-hand-art-size:min(139px,calc(var(--pt-card-size)*1.13));padding:4px}
#deck-builder .ms-hand .db-hand-heading {height:auto;min-height:22px;margin:0;gap:3px}
#deck-builder .ms-hand .db-hand-controls {width:auto;flex-wrap:nowrap}
#deck-builder .ms-hand .db-hand-controls [data-hand-action=deal] {flex-basis:auto}
#deck-builder .ms-hand .db-hand-meta {line-height:10px;margin:0;min-height:10px}
#deck-builder .ms-hand .db-hand-controls button {min-height:22px;height:22px;padding:1px 5px}
#deck-builder .ms-hand .db-hand-card {position:relative;width:var(--pt-hand-art-size);margin-right:min(0px,calc((100cqw - var(--pt-hand-count)*var(--pt-hand-art-size) - (var(--pt-hand-count) - 1)*6px)/max(1,var(--pt-hand-count) - 1)))}
#deck-builder .ms-hand .db-hand-card:last-child {margin-right:0}
#deck-builder .ms-hand .db-hand-caption {position:absolute;bottom:4px;left:4px;right:4px;z-index:2;border-radius:3px;background:#100f15df;opacity:0;transition:opacity 140ms}
#deck-builder .ms-hand .db-hand-card:hover .db-hand-caption,#deck-builder .ms-hand .db-hand-card:focus-within .db-hand-caption {opacity:1}
#deck-builder .ms-hand {border-top-color:#ad915b80}
#deck-builder #pt-command {border-top-color:#8f765980}
#deck-builder .pt-zone-heading,#deck-builder .pt-dock-zone h2 {font-size:11px;color:#d2cbd4;letter-spacing:0;font-weight:650}
#deck-builder .pt-zone-heading span {display:inline-block;background:#ffffff07;border:1px solid #ffffff09;border-radius:3px;padding:0 4px;font-size:10px;font-weight:500;color:#bcb3c5;min-width:18px;font-variant-numeric:tabular-nums}
#deck-builder .pt-zone-heading:hover {color:#e6cb92;background:#d4b57706}
#deck-builder .pt-zone-empty {color:#a89cab;font-size:10px;margin-top:52px}
#deck-builder .pt-zone-empty::before {content:'';display:block;width:30px;height:42px;border:1px dashed #786a804f;border-radius:4px;margin:0 auto 9px}
#deck-builder .ms-hand h2 {font-size:12px;font-weight:750;letter-spacing:-.1px}
#deck-builder .ms-hand .db-hand-meta {color:#a89faf}
#deck-builder .ms-hand .db-hand-meta strong {color:#dac38f}
#deck-builder .ms-hand .db-hand-controls button {border-radius:4px;border-color:#49404e;transition:border-color 140ms,background-color 140ms,box-shadow 140ms}
#deck-builder .ms-hand .db-hand-art {box-shadow:0 3px 8px #0008;transition:box-shadow 160ms,filter 160ms}
#deck-builder .ms-hand .db-hand-art:hover:not(:disabled) {box-shadow:0 0 0 1px #d4b577,0 5px 16px #0009;filter:brightness(1.055)}
#deck-builder .ms-hand .db-hand-grip {color:#a69bad;opacity:.8}
#deck-builder .ms-hand .db-hand-grip:hover {color:#e6cb92;opacity:1}
#deck-builder .pt-card {box-shadow:0 5px 12px #0009,0 0 0 1px #0007;transition:translate 160ms,box-shadow 160ms,filter 160ms}
#deck-builder .pt-card:hover {outline:1px solid #d4b577;box-shadow:0 8px 20px #000a;filter:brightness(1.05);translate:0 -3px}
#deck-builder .pt-card.is-tapped {transform:rotate(90deg)}
#deck-builder .pt-card.pt-selected,#deck-builder .db-hand-card.pt-selected .db-hand-art {outline-color:#e6cb92;box-shadow:0 0 0 4px #d4b57723,0 5px 16px #0008}
#deck-builder .pt-position:has(.pt-card:hover),#deck-builder .pt-position:has(.pt-selected) {z-index:5}
#deck-builder .pt-counter {background:linear-gradient(#ead49f,#c6a76b);color:#261c10;border-color:#fae6b9;box-shadow:0 2px 6px #0008;font-weight:800}
#deck-builder .pt-drop-target {outline-color:#e6cb92;box-shadow:inset 0 0 40px #d4b57712,0 0 0 1px #d4b57730}
.pt-drag-preview {box-shadow:0 16px 36px #000a,0 0 0 1px #d4b577b8!important;filter:brightness(1.08)}
#deck-builder .pt-drag-origin {opacity:.25;filter:grayscale(.2)}

#deck-builder .pt-library-back,#deck-builder .pt-card-back {
  position:relative;background:radial-gradient(ellipse at 50% 45%,#292731,#14131b 80%);
  border:5px solid #24212a;color:#dcc18c;overflow:hidden;
}
#deck-builder .pt-library-back::before,#deck-builder .pt-card-back::before {
  content:'';position:absolute;inset:8px;border:1px solid #b99b6060;border-radius:3px;
  background:linear-gradient(135deg,transparent 48%,#d4b57709 49% 51%,transparent 52%);
  pointer-events:none;
}
#deck-builder .pt-library-back::after,#deck-builder .pt-card-back::after {
  content:'';position:absolute;width:55px;height:55px;top:34%;left:50%;transform:translateX(-50%) rotate(45deg);
  border:1px solid #d4b57738;box-shadow:inset 0 0 0 7px #d4b57705;pointer-events:none;
}
#deck-builder .pt-back-mark {width:25px;height:25px;margin:0 0 10px;z-index:1;filter:drop-shadow(0 1px 8px #d4b57720)}
#deck-builder .pt-library-back>span,#deck-builder .pt-card-back>span {position:relative;z-index:1;font-size:11px;letter-spacing:1px}
#deck-builder .pt-library-back small {font-size:9px;color:#b6a7be;margin-top:20px;letter-spacing:0}
#deck-builder .pt-token-art {position:relative;border-color:#27252d;background:radial-gradient(circle at 50% 40%,#38443a,#191d20 78%);padding:10px 7px;color:#ece5d7;box-shadow:inset 0 0 0 1px #d4b57738}
#deck-builder .pt-token-art::after {content:'';position:absolute;inset:30% 25%;border:1px solid #d4b57725;transform:rotate(45deg);pointer-events:none}
#deck-builder .pt-token-art[data-token-color=W] {background:radial-gradient(circle at 50% 40%,#5d5140,#242025 80%)}
#deck-builder .pt-token-art[data-token-color=U] {background:radial-gradient(circle at 50% 40%,#304e60,#171b29 80%)}
#deck-builder .pt-token-art[data-token-color=B] {background:radial-gradient(circle at 50% 40%,#4d3853,#1a1721 80%)}
#deck-builder .pt-token-art[data-token-color=R] {background:radial-gradient(circle at 50% 40%,#69413b,#24191c 80%)}
#deck-builder .pt-token-art small {letter-spacing:1px;font-size:8px;align-self:start;z-index:1}
#deck-builder .pt-token-art strong {z-index:1;line-height:1.4;text-shadow:0 2px 8px #0008}
#deck-builder .pt-token-art b {z-index:1;color:#f1e1bf;background:#15161bad;border-color:#d4b57770;font-size:12px;border-radius:4px;padding:2px 5px}

#deck-builder #ms-pod-panel .ms-pod,#deck-builder .ms-settings-body {background:#19171fee;border-color:#85705368;box-shadow:0 12px 40px #000b,inset 0 1px #ffffff09;backdrop-filter:blur(14px)}
#deck-builder #ms-pod-panel[open] .ms-pod {animation:pt-menu-enter 180ms cubic-bezier(.2,.75,.2,1)}
#deck-builder .ms-seat {background:#1a1921;border-color:#3c3542;border-radius:5px}
#deck-builder .ms-seat.is-player {border-color:#b99b60;background:#d4b57709}
#deck-builder .ms-seat-copy h2 {color:#eee1ca}
#deck-builder .ms-seat-head {background:#ffffff03}
#deck-builder .pt-card-menu {background:#201c27f5;border-color:#a68b606b;box-shadow:0 15px 45px #000b,inset 0 1px #ffffff0a;backdrop-filter:blur(16px)}
#deck-builder .pt-card-menu:popover-open {animation:pt-menu-enter 140ms cubic-bezier(.2,.75,.2,1);transform-origin:top left}
#deck-builder #pt-menu-name {color:#e6cb92;border-bottom:1px solid #d4b5771c;margin-bottom:3px;padding-bottom:8px}
#deck-builder .pt-card-menu button {transition:background-color 120ms,color 120ms;font-size:11px}
#deck-builder .pt-card-menu button:hover:not(:disabled) {background:#d4b57712;color:#f6e4c2}
#deck-builder dialog[id^=pt-] {background:linear-gradient(145deg,#211e29,#16151e);border-color:#9c805a70;box-shadow:0 25px 80px #000b,inset 0 1px #ffffff09}
#deck-builder dialog[id^=pt-] header {border-bottom:1px solid #d4b5771c;padding-bottom:12px}
#deck-builder dialog[id^=pt-] h2 {font-size:16px;font-weight:750;letter-spacing:-.2px;color:#eee0c5}
#deck-builder #pt-command-list button {display:flex;align-items:center;gap:8px;background:#ffffff03;border:1px solid #ffffff08;border-radius:4px;transition:background-color 140ms,border-color 140ms}
#deck-builder #pt-command-list button:hover {background:#d4b5770d;border-color:#d4b57735;color:#eedab1}
#deck-builder :is(button,summary,input,select):focus-visible {outline:2px solid #e6cb92;outline-offset:3px}
#deck-builder .ms-decision {border-bottom-color:#302d36;background:#111116}
#deck-builder .ms-decision strong {color:#e5d2a9}
#deck-builder .ms-context,#deck-builder .ms-data-notes {border-color:#292831}

.pt-motion-layer {position:fixed;inset:0;z-index:1000;pointer-events:none;perspective:1000px;overflow:hidden;contain:strict}
#deck-builder .pt-motion-card {position:absolute;pointer-events:none;border-radius:7px;background:#16151b;box-shadow:0 12px 28px #0009;transform-origin:center;overflow:hidden;will-change:transform,opacity}
#deck-builder .pt-motion-card img {display:block;width:100%;height:100%;object-fit:contain;border-radius:7px}
#deck-builder .pt-motion-card .db-hand-placeholder,#deck-builder .pt-motion-card .db-hand-selected {display:none}
#deck-builder .pt-motion-card .pt-card-caption {display:none}
#deck-builder .pt-motion-card .pt-card-back img {width:25px;height:25px}
@keyframes pt-menu-enter {from{opacity:0;transform:translateY(-4px) scale(.985)}to{opacity:1;transform:translateY(0) scale(1)}}
@media (max-width:1100px) {
  #deck-builder .pt-dock {grid-template-columns:105px minmax(0,1fr)100px 100px 100px}
  #deck-builder .ms-hand .db-hand-heading {height:auto;min-height:22px}
  #deck-builder .pt-toolbar .pt-control-icon {display:none}
  #deck-builder .pt-field-actions button {font-size:10px}
}
@media (max-width:767px) {
  #deck-builder .pt-dock {grid-template-columns:repeat(4,minmax(0,1fr))}
  #deck-builder .ms-hand {padding:6px}
  #deck-builder .ms-hand .db-hand-heading {height:auto}
  #deck-builder .ms-hand .db-hand-card {width:120px;margin-right:0}
  #deck-builder .ms-hand .db-hand-caption {position:static;opacity:1;background:transparent}
  #deck-builder .pt-dock-zone .pt-card,#deck-builder .pt-library-back {width:85px}
  #deck-builder .pt-field-empty {font-size:11px}
  #deck-builder .pt-field-empty span {font-size:10px}
  #deck-builder .pt-field-empty::before {width:23px;height:32px;margin-bottom:10px}
  #deck-builder .pt-field-actions button {font-size:9px;gap:4px}
  #deck-builder .pt-field-actions .pt-control-icon {width:10px;height:10px}
  #deck-builder .pt-zone-heading,#deck-builder .pt-dock-zone h2 {font-size:9px}
  #deck-builder .pt-zone-heading span {font-size:8px;padding:0 3px;min-width:14px}
  #deck-builder .pt-zone-empty {margin-top:20px}
  #deck-builder .pt-zone-empty::before {width:22px;height:30px}
  #deck-builder .pt-action-status {max-width:85%;padding:3px 5px}
  #deck-builder #pt-mana button {padding:2px 4px;gap:2px}
  #deck-builder #pt-mana img {width:12px;height:12px}
  #deck-builder .pt-library-back>span {font-size:8px;letter-spacing:.4px}
  #deck-builder .pt-back-mark {width:18px;height:18px;margin-bottom:6px}
  #deck-builder .pt-library-back::after {width:33px;height:33px;top:33%}
  #deck-builder .pt-library-back small {margin-top:10px;font-size:8px}
}
@media (prefers-reduced-motion:reduce) {
  #deck-builder .pt-card,#deck-builder .ms-hand .db-hand-art {translate:none;transition:none}
  #deck-builder .pt-card-menu:popover-open,#deck-builder #ms-pod-panel[open] .ms-pod {animation:none}
  #deck-builder.ms-workspace *,#deck-builder.ms-workspace *::before,#deck-builder.ms-workspace *::after {transition:none!important;animation:none!important}
  .pt-motion-layer {display:none}
}

#deck-builder .pt-card-back .pt-back-mark {width:25px;height:25px;aspect-ratio:auto;}
#deck-builder .ms-inspect-art {display:flex;flex-direction:column;gap:12px;}
#deck-builder .ms-inspect-face + .ms-inspect-face {margin-top:18px;padding-top:18px;border-top:1px solid var(--pt-edge);}
#deck-builder .ms-inspect-face h3 {font-size:14px;margin-bottom:8px;}
#deck-builder #ms-inspect-flip {min-height:36px;}
#deck-builder .ms-hand .db-hand-card:hover,#deck-builder .ms-hand .db-hand-card:focus-within {z-index:5;}
@media(min-width:768px) {#deck-builder .ms-hand {height:auto;min-height:236px;}}
