
.m2th-wrap{--r:#cf0614;--rd:#a9000b;--text:#171b22;--muted:#69737d;--line:#dde3e8;font-family:Arial,Helvetica,sans-serif;color:var(--text);margin:24px 0}
.m2th-head{padding:18px 20px;border:1px solid var(--line);border-left:4px solid var(--r);border-radius:7px;background:#fff}.m2th-head span{font-size:9px;font-weight:900;letter-spacing:.14em;color:var(--r)}.m2th-head h2{font-size:26px!important;margin:4px 0!important}.m2th-head p{margin:0!important;color:var(--muted);font-size:13px}
.m2th-tabs{display:flex;gap:6px;flex-wrap:wrap;margin:12px 0}.m2th-tabs button{border:1px solid var(--line);background:#fff;border-radius:5px;padding:9px 11px;font-size:11px;font-weight:800;cursor:pointer}.m2th-tabs button.is-active,.m2th-tabs button:hover{background:var(--r);border-color:var(--r);color:#fff}
.m2th-tool{padding:18px;border:1px solid var(--line);border-radius:8px;background:#fff;box-shadow:0 2px 9px rgba(20,29,39,.05)}.m2th-tool h3{font-size:21px!important;margin:0 0 5px!important}.m2th-tool>p{color:var(--muted);font-size:13px}.m2th-note{padding:10px;background:#fff7e8;border-left:3px solid #d8a52f}
.m2th-form-grid,.m2th-simya-list,.m2th-upgrade-costs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:14px 0}.m2th-upgrade-costs{grid-template-columns:repeat(3,minmax(0,1fr))}
.m2th-tool label{display:flex;flex-direction:column;gap:5px;font-size:11px;font-weight:800;color:#4f5964}.m2th-tool input,.m2th-tool select{height:40px;border:1px solid #cfd6dd;border-radius:5px;padding:0 9px;background:#fff;color:#222}
.m2th-primary,.m2th-secondary{min-height:38px;border-radius:5px;padding:0 13px;font-size:11px;font-weight:900;cursor:pointer}.m2th-primary{border:0;background:var(--r);color:#fff}.m2th-primary:hover{background:var(--rd)}.m2th-secondary{border:1px solid #cfd6dd;background:#fff;color:#303943}
.m2th-result{margin-top:12px;padding:12px;border-radius:6px;background:#f7f9fb;border:1px solid #e4e8ec;font-size:14px}.m2th-result strong{color:var(--r)}
.m2th-card-board{display:grid;grid-template-columns:repeat(8,minmax(0,1fr));gap:7px;margin:14px 0}.m2th-number-card{min-height:74px;border:1px solid #d8dee4;border-radius:7px;background:#fff;cursor:pointer}.m2th-number-card strong{display:block;font-size:23px}.m2th-number-card span{display:block;margin-top:4px;color:var(--r);font-size:10px;font-weight:900}.m2th-number-card.is-selected{border-color:var(--r);box-shadow:0 0 0 2px rgba(207,6,20,.12)}.m2th-number-card:disabled{opacity:.35}
.m2th-inline-actions,.m2th-king-controls{display:flex;gap:7px;flex-wrap:wrap}
.m2th-ai-chat{height:320px;overflow:auto;padding:10px;border:1px solid var(--line);border-radius:7px;background:#f7f9fb}.m2th-ai-msg{max-width:85%;margin:0 0 9px;padding:9px 11px;border-radius:9px;background:#fff;border:1px solid #e1e5e9;font-size:13px;line-height:1.5}.m2th-ai-msg.user{margin-left:auto;background:var(--r);color:#fff;border-color:var(--r)}.m2th-ai-form{display:grid;grid-template-columns:1fr auto;gap:7px;margin-top:9px}.m2th-ai-form input{height:42px}
@media(max-width:760px){.m2th-form-grid,.m2th-simya-list,.m2th-upgrade-costs{grid-template-columns:1fr}.m2th-card-board{grid-template-columns:repeat(4,1fr)}}
@media(max-width:480px){.m2th-card-board{grid-template-columns:repeat(4,1fr)}.m2th-tabs{display:grid;grid-template-columns:repeat(2,1fr)}.m2th-tabs button{width:100%}}


/* ==========================================================
   v2.2 EVENT GAME UI
   ========================================================== */
.m2th-game-tool{padding:0!important;overflow:hidden}
.m2th-game-title{
  display:flex;align-items:center;justify-content:space-between;gap:15px;
  padding:18px 20px;border-bottom:1px solid var(--line);
  background:linear-gradient(180deg,#fff,#fafbfc)
}
.m2th-game-title h3{margin:3px 0 0!important}
.m2th-game-kicker{font-size:9px;font-weight:900;letter-spacing:.13em;color:var(--r)}
.m2th-game-pill{padding:7px 10px;border-radius:999px;background:#fff0f1;color:var(--r);font-size:10px;font-weight:900}
.m2th-info-panel{
  margin:16px 18px;padding:13px 15px;border:1px solid #e2e7eb;border-left:4px solid var(--r);
  border-radius:6px;background:#fafbfc;font-size:12px;line-height:1.55
}
.m2th-info-panel strong{font-size:13px}.m2th-info-panel p{margin:5px 0}.m2th-info-panel ul{margin:7px 0 0 18px;padding:0}

.m2th-table-top,.m2th-zone-head{display:flex;align-items:center;justify-content:space-between;gap:12px}
.m2th-table-top strong,.m2th-zone-head strong{font-size:11px;letter-spacing:.06em}
.m2th-table-top span,.m2th-zone-head span{font-size:10px;color:#7c8792}
.m2th-counter-box{min-width:62px;padding:7px 9px;border-radius:6px;background:#171d24;color:#fff;text-align:center}
.m2th-counter-box b{display:block;font-size:20px}.m2th-counter-box small{font-size:8px;color:#b7c0c9}

/* OKEY */
.m2th-okey-layout{display:grid;grid-template-columns:minmax(0,1fr) 245px;gap:14px;padding:0 18px 18px}
.m2th-okey-table{padding:15px;border:1px solid #dde3e8;border-radius:8px;background:#fff}
.m2th-okey-board{margin:12px 0 15px}
.m2th-okey-row{display:grid;grid-template-columns:68px repeat(8,minmax(42px,1fr));gap:6px;margin-bottom:7px}
.m2th-row-name{
  display:flex;align-items:center;justify-content:center;border-radius:6px;color:#fff;
  font-size:9px;font-weight:900;letter-spacing:.04em;text-transform:uppercase
}
.m2th-row-name.is-red{background:#d80010}.m2th-row-name.is-yellow{background:#d9ad00;color:#231d00}.m2th-row-name.is-blue{background:#0877bd}
.m2th-okey-card{
  min-height:72px;border:2px solid #20252a;border-radius:7px;cursor:pointer;
  box-shadow:0 3px 0 rgba(0,0,0,.25);transition:.12s
}
.m2th-okey-card strong{display:block;font-family:Georgia,serif;font-size:31px;line-height:1}
.m2th-okey-card small{display:block;margin-top:4px;font-size:7px;font-weight:900;opacity:.72;text-transform:uppercase}
.m2th-okey-card.is-red{background:#ed1717;color:#111;border-color:#f1ca00}
.m2th-okey-card.is-yellow{background:#e8c900;color:#111;border-color:#a68d00}
.m2th-okey-card.is-blue{background:#0879bd;color:#081018;border-color:#e4c400}
.m2th-okey-card.is-out{opacity:.16;filter:grayscale(.8);transform:scale(.94)}
.m2th-okey-card.is-selected{outline:3px solid var(--r);outline-offset:2px;transform:translateY(-2px)}
.m2th-okey-zone{margin:12px 0;padding-top:12px;border-top:1px solid #edf0f2}
.m2th-okey-hand,.m2th-okey-selected{display:flex;gap:8px;flex-wrap:wrap;margin-top:9px;min-height:78px}
.m2th-okey-hand .m2th-okey-card,.m2th-okey-selected .m2th-okey-card{width:58px;min-height:72px}
.m2th-okey-empty,.m2th-empty-slot{
  min-width:58px;height:72px;display:grid;place-items:center;border:1px dashed #cbd3da;border-radius:6px;
  color:#99a2aa;font-size:9px;background:#fafbfc
}
.m2th-score-guide{padding:14px;border:1px solid #dde3e8;border-radius:8px;background:#f7f9fb}
.m2th-score-guide h4{margin:0 0 10px;font-size:14px}
.m2th-score-box{display:grid;grid-template-columns:1fr 1fr;gap:4px;margin-bottom:11px;padding-bottom:10px;border-bottom:1px solid #e0e5e9}
.m2th-score-box strong{grid-column:1/-1;font-size:10px;color:#262e36}.m2th-score-box span{font-size:9px;color:#68737d}
.m2th-reward-scale{display:grid;gap:5px;padding:9px;border-radius:6px;background:#fff}.m2th-reward-scale strong{font-size:10px}.m2th-reward-scale span{font-size:9px}
.m2th-game-result{font-weight:700}

/* KING */
.m2th-king-game{
  display:grid;grid-template-columns:120px minmax(0,1fr) 110px;gap:12px;
  margin:0 18px;padding:16px;border-radius:10px;
  background:
    linear-gradient(rgba(18,26,22,.12),rgba(18,26,22,.12)),
    repeating-linear-gradient(45deg,#6e785e,#6e785e 7px,#747e63 7px,#747e63 14px);
  box-shadow:inset 0 0 0 1px rgba(0,0,0,.28),0 5px 18px rgba(20,29,39,.12)
}
.m2th-king-stock h4{margin:0 0 9px;color:#fff;font-size:9px;text-align:center}
#m2th-king-stock{display:grid;gap:7px}
.m2th-king-card{
  min-height:45px;border:2px solid rgba(255,255,255,.55);border-radius:6px;color:#111;
  box-shadow:0 2px 4px rgba(0,0,0,.28);cursor:pointer
}
.m2th-king-card strong{font-family:Georgia,serif;font-size:22px}.m2th-king-card small{margin-left:5px;font-size:9px;font-weight:900}
.m2th-king-card.is-1{background:#8cc800}.m2th-king-card.is-2{background:#e4a12c}.m2th-king-card.is-3{background:#f1ce18}
.m2th-king-card.is-4{background:#d512c7}.m2th-king-card.is-5{background:#087fe5}.m2th-king-card.is-king{background:#b90000;color:#fff}
.m2th-king-card.is-selected{outline:3px solid #fff;outline-offset:2px}
.m2th-king-toolbar{display:flex;align-items:center;justify-content:space-between;color:#fff;margin-bottom:8px;font-size:10px;letter-spacing:.06em}
.m2th-icon-btn{width:30px;height:30px;border:1px solid rgba(255,255,255,.5);border-radius:5px;background:rgba(0,0,0,.2);color:#fff;cursor:pointer}
.m2th-king-grid{display:grid;grid-template-columns:repeat(5,1fr);gap:7px}
.m2th-king-cell{
  aspect-ratio:1/1;border:2px solid rgba(255,255,255,.55);border-radius:5px;background:#1f5548;color:#fff;
  cursor:pointer;box-shadow:0 2px 5px rgba(0,0,0,.22)
}
.m2th-king-cell.is-open{background:#fff;color:#171b22}.m2th-king-cell strong{font-size:20px}
.m2th-king-side{display:flex;flex-direction:column;gap:18px;justify-content:center}
.m2th-king-target,.m2th-king-found{text-align:center;color:#fff}.m2th-king-target span,.m2th-king-found span{display:block;font-size:8px;font-weight:900;margin-bottom:6px}
#m2th-king-target,#m2th-king-found{
  width:70px;height:62px;display:grid;place-items:center;margin:auto;border:2px solid #c40000;border-radius:6px;
  background:#78a946;color:#111;font-family:Georgia,serif;font-size:25px
}
#m2th-king-target{cursor:pointer}
.m2th-king-hand-wrap{display:flex;align-items:center;gap:12px;margin:12px 18px 0;padding:11px;border:1px solid #e0e5e9;border-radius:7px;background:#fafbfc}
.m2th-king-hand-wrap>span{font-size:9px;font-weight:900;letter-spacing:.05em}.m2th-king-hand{display:flex;gap:6px;flex-wrap:wrap}.m2th-king-hand .m2th-king-card{min-width:67px}
.m2th-game-tool>.m2th-result{margin:12px 18px 18px}

/* PROPHET */
.m2th-prophet-layout{display:grid;grid-template-columns:minmax(0,1fr) 235px;gap:14px;padding:0 18px 18px}
.m2th-prophet-panel,.m2th-prophet-remaining{padding:14px;border:1px solid #dfe4e8;border-radius:8px;background:#fff}
.m2th-prophet-own,.m2th-prophet-candidates,#m2th-prophet-remaining{display:grid;grid-template-columns:repeat(9,minmax(42px,1fr));gap:6px;margin:10px 0 14px}
.m2th-prophet-remaining #m2th-prophet-remaining{grid-template-columns:repeat(3,1fr)}
.m2th-tarot{min-height:70px;border-radius:7px;cursor:pointer;box-shadow:0 2px 5px rgba(0,0,0,.12)}
.m2th-tarot strong{display:block;font-family:Georgia,serif;font-size:27px}.m2th-tarot small{display:block;font-size:7px;font-weight:900;margin-top:3px}
.m2th-tarot.is-black{background:#171b20;border:2px solid #050607;color:#fff}.m2th-tarot.is-white{background:#fff;border:2px solid #aeb7bf;color:#111}
.m2th-tarot.is-selected,.m2th-tarot.is-candidate{outline:3px solid var(--r);outline-offset:2px}
.m2th-prophet-controls{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin:13px 0;padding:12px;border-radius:7px;background:#f7f9fb}
.m2th-prophet-controls>div{display:grid;grid-template-columns:repeat(3,1fr);gap:5px}.m2th-prophet-controls>div:last-child{grid-template-columns:1fr 1fr}
.m2th-prophet-controls span{grid-column:1/-1;font-size:9px;font-weight:900;color:#68737d}
.m2th-prophet-controls button{min-height:36px;border:1px solid #cfd6dc;border-radius:5px;background:#fff;font-size:9px;font-weight:900;cursor:pointer}
.m2th-prophet-controls button.is-active{border-color:var(--r);box-shadow:0 0 0 2px rgba(207,6,20,.10)}
.m2th-prophet-controls .is-black{background:#171b20;color:#fff}.m2th-prophet-controls .is-white{background:#fff;color:#111}
.m2th-prophet-remaining h4{margin:0 0 7px;font-size:13px}.m2th-prophet-remaining p{font-size:10px;color:#707b85;line-height:1.5}

@media(max-width:900px){
  .m2th-okey-layout,.m2th-prophet-layout{grid-template-columns:1fr}
  .m2th-okey-row{grid-template-columns:52px repeat(8,minmax(34px,1fr))}
  .m2th-king-game{grid-template-columns:95px minmax(0,1fr)}
  .m2th-king-side{grid-column:1/-1;flex-direction:row}
}
@media(max-width:650px){
  .m2th-okey-layout,.m2th-prophet-layout{padding:0 10px 12px}
  .m2th-okey-table{padding:10px}
  .m2th-okey-row{grid-template-columns:1fr repeat(4,1fr);gap:5px}
  .m2th-okey-row .m2th-row-name{grid-row:span 2}
  .m2th-okey-card{min-height:60px}.m2th-okey-card strong{font-size:25px}
  .m2th-king-game{margin:0 10px;grid-template-columns:1fr;padding:10px}
  .m2th-king-stock{order:2}.m2th-king-stock #m2th-king-stock{grid-template-columns:repeat(3,1fr)}
  .m2th-king-center{order:1}.m2th-king-side{order:3}
  .m2th-king-hand-wrap{margin:10px;display:block}.m2th-king-hand{margin-top:7px}
  .m2th-prophet-own,.m2th-prophet-candidates{grid-template-columns:repeat(5,1fr)}
  .m2th-prophet-controls{grid-template-columns:1fr}
}


/* ==========================================================
   v2.3 Costume Sets
   ========================================================== */
.m2costumes-wrap{
  --r:#cf0614;--rd:#a9000b;--text:#171b22;--muted:#6b7681;--line:#dfe4e9;
  font-family:Arial,Helvetica,sans-serif;color:var(--text);margin:24px 0
}
.m2costumes-head{
  display:flex;align-items:center;justify-content:space-between;gap:20px;
  padding:20px;border:1px solid var(--line);border-left:4px solid var(--r);
  border-radius:8px;background:#fff
}
.m2costumes-head span{font-size:9px;font-weight:900;letter-spacing:.14em;color:var(--r)}
.m2costumes-head h3{margin:4px 0!important;font-size:27px!important}
.m2costumes-head p{margin:0!important;color:var(--muted);font-size:13px}
.m2costumes-count{
  min-width:68px;height:58px;display:flex;flex-direction:column;align-items:center;justify-content:center;
  border-radius:7px;background:#171d24;color:#fff;font-size:21px;font-weight:900
}
.m2costumes-count small{font-size:8px;color:#bbc4cd;letter-spacing:.08em}
.m2costumes-toolbar{
  display:grid;grid-template-columns:1fr auto;gap:8px;margin:12px 0;padding:9px;
  border:1px solid var(--line);border-radius:7px;background:#fff
}
.m2costumes-toolbar label{
  display:flex;align-items:center;gap:7px;height:40px;padding:0 10px;border:1px solid #d3d9df;border-radius:5px
}
.m2costumes-toolbar input{width:100%;height:36px;border:0!important;box-shadow:none!important;outline:0!important;background:transparent!important}
.m2costumes-toolbar button{padding:0 15px;border:0;border-radius:5px;background:var(--r);color:#fff;font-size:10px;font-weight:900}
.m2costumes-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
.m2costume-card{overflow:hidden;border:1px solid var(--line);border-radius:8px;background:#fff;box-shadow:0 2px 9px rgba(20,29,39,.06)}
.m2costume-title{
  display:flex;align-items:center;justify-content:space-between;gap:10px;padding:14px 15px;border-bottom:1px solid #edf0f2
}
.m2costume-title span{display:block;font-size:8px;font-weight:900;color:var(--r);letter-spacing:.07em}
.m2costume-title h4{margin:3px 0 0!important;font-size:18px!important}
.m2costume-title b{padding:6px 8px;border-radius:5px;background:#fff1f2;color:var(--r);font-size:9px}
.m2costume-pieces{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;padding:13px}
.m2costume-piece{min-width:0;padding:8px;border:1px solid #e7ebee;border-radius:6px;background:#fafbfc;text-align:center}
.m2costume-piece-img{height:88px;display:flex;align-items:center;justify-content:center;margin-bottom:7px}
.m2costume-piece-img img{display:block;max-width:100%!important;max-height:88px!important;width:auto!important;height:auto!important;object-fit:contain!important}
.m2costume-piece-img span{font-size:30px;color:#b4bdc5}
.m2costume-piece strong{display:block;overflow:hidden;font-size:10px;line-height:1.3;text-overflow:ellipsis}
.m2costume-piece small{display:block;margin-top:3px;color:var(--r);font-size:8px;font-weight:900;text-transform:uppercase}
.m2costume-sim{padding:13px;border-top:1px solid #edf0f2;background:#f8fafb}
.m2costume-sim-head{display:flex;align-items:center;justify-content:space-between;gap:8px}
.m2costume-sim-head strong{font-size:10px;letter-spacing:.06em}.m2costume-sim-head span{font-size:9px;color:var(--muted)}
.m2costume-piece-buttons{display:flex;gap:6px;margin:9px 0}
.m2costume-piece-buttons button{
  width:34px;height:32px;border:1px solid #cfd6dc;border-radius:5px;background:#fff;color:#303942;font-weight:900;cursor:pointer
}
.m2costume-piece-buttons button.is-active{border-color:var(--r);background:var(--r);color:#fff}
.m2costume-bonuses{min-height:76px;padding:10px;border:1px solid #e3e8ec;border-radius:6px;background:#fff}
.m2costume-bonuses ul{margin:0;padding-left:18px}.m2costume-bonuses li{margin:4px 0;font-size:11px;line-height:1.4}
.m2costume-bonuses p{margin:0;color:var(--muted);font-size:11px}
.m2costumes-empty{grid-column:1/-1;padding:30px;border:1px dashed #ccd4da;border-radius:7px;text-align:center}
.m2costumes-empty strong,.m2costumes-empty span{display:block}.m2costumes-empty span{margin-top:5px;color:var(--muted);font-size:12px}
@media(max-width:950px){.m2costumes-grid{grid-template-columns:1fr}}
@media(max-width:560px){
  .m2costumes-head{align-items:flex-start}.m2costumes-count{display:none}
  .m2costume-pieces{grid-template-columns:repeat(2,1fr)}
  .m2costumes-toolbar{grid-template-columns:1fr}.m2costumes-toolbar button{height:38px}
}



.m2th-costume-tool{padding:0!important;overflow:hidden}
.m2th-costume-tool .m2costumes-wrap{margin:0}
.m2th-costume-tool .m2costumes-head{border:0;border-bottom:1px solid #dfe4e9;border-left:4px solid #cf0614;border-radius:0}
.m2th-costume-tool .m2costumes-toolbar{margin:12px 14px}
.m2th-costume-tool .m2costumes-grid{padding:0 14px 14px}

.m2costumes-toolbar{grid-template-columns:minmax(0,1fr) auto auto!important;align-items:center!important}
.m2costumes-search{position:relative!important;display:block!important;height:42px!important;border:1px solid #d3d9df!important;border-radius:6px!important;background:#fff!important}
.m2costumes-search>span{position:absolute!important;left:13px!important;top:50%!important;transform:translateY(-50%)!important;z-index:2!important;color:#7f8993!important;font-size:16px!important;pointer-events:none!important}
.m2costumes-search input{display:block!important;width:100%!important;height:40px!important;margin:0!important;padding:0 12px 0 39px!important;border:0!important;outline:0!important;box-shadow:none!important;background:#fff!important;color:#202831!important;font-size:13px!important;line-height:40px!important;text-align:left!important}
.m2costumes-search input::placeholder{color:#8c959e!important}
.m2costumes-simulator-open{min-width:142px!important;background:#171d24!important}.m2costumes-simulator-open:hover{background:#2b333c!important}
.m2costume-global-sim{margin:0 14px 14px;overflow:hidden;border:1px solid #dfe4e9;border-top:3px solid #cf0614;border-radius:8px;background:#fff;box-shadow:0 5px 18px rgba(20,29,39,.08)}
.m2costume-global-sim[hidden]{display:none!important}
.m2costume-global-head{display:flex;align-items:flex-start;justify-content:space-between;gap:15px;padding:14px 16px;border-bottom:1px solid #e7ebee;background:#fafbfc}
.m2costume-global-head span{display:block;color:#cf0614;font-size:8px;font-weight:900;letter-spacing:.08em}.m2costume-global-head strong{display:block;margin-top:3px;font-size:16px}.m2costume-global-head small{display:block;margin-top:3px;color:#6f7882;font-size:10px}
.m2costume-global-head button{width:32px;height:32px;border:0;border-radius:50%;background:#eef1f3;color:#333;font-size:20px;cursor:pointer}
.m2costume-global-controls{display:grid;grid-template-columns:minmax(0,1fr) 90px minmax(0,1fr) 90px auto;gap:8px;padding:14px}
.m2costume-global-controls label{display:flex!important;flex-direction:column!important;gap:5px!important;font-size:9px!important;font-weight:900!important;color:#68737d!important}
.m2costume-global-controls select{height:40px!important;border:1px solid #cfd6dc!important;border-radius:5px!important;background:#fff!important;padding:0 8px!important}
.m2costume-global-controls>button{align-self:end;height:40px}
.m2costume-global-results{display:grid;grid-template-columns:1fr 1fr;gap:10px;padding:0 14px 14px}
.m2costume-global-results>div{min-height:120px;padding:12px;border:1px solid #e2e7eb;border-radius:6px;background:#f9fafb}
.m2costume-global-results strong{display:block;font-size:13px}.m2costume-global-results small{display:block;margin:3px 0 8px;color:#cf0614;font-size:9px;font-weight:900}.m2costume-global-results ul{margin:0;padding-left:18px}.m2costume-global-results li{margin:4px 0;font-size:11px}.m2costume-global-results p{font-size:11px;color:#747e87}
@media(max-width:800px){.m2costumes-toolbar{grid-template-columns:1fr 1fr!important}.m2costumes-search{grid-column:1/-1}.m2costume-global-controls{grid-template-columns:1fr 80px}.m2costume-global-controls>button{grid-column:1/-1}.m2costume-global-results{grid-template-columns:1fr}}


/* ==========================================================
   v2.3.5 Set Simulator — Metin2Alerts-inspired layout
   ========================================================== */
.m2th-costume-simulator-tool{padding:0!important;overflow:hidden}
.m2sim-wrap{--r:#cf0614;--text:#171b22;--muted:#6f7882;--line:#dfe4e9;background:#fff}
.m2sim-head{padding:20px 22px;border-left:4px solid var(--r);border-bottom:1px solid var(--line);background:linear-gradient(#fff,#fafbfc)}
.m2sim-head>span{display:block;color:var(--r);font-size:9px;font-weight:900;letter-spacing:.13em}
.m2sim-head h3{margin:4px 0!important;font-size:27px!important}.m2sim-head p{margin:0!important;color:var(--muted);font-size:13px}
.m2sim-note{margin:14px 18px;padding:12px 14px;border:1px solid #eadca7;border-left:4px solid #d0a125;border-radius:6px;background:#fffaf0}
.m2sim-note strong{display:block;font-size:11px}.m2sim-note span{display:block;margin-top:4px;color:#5f6973;font-size:10px;line-height:1.5}

.m2sim-top{display:grid;grid-template-columns:180px minmax(0,1fr);gap:14px;padding:0 18px 15px}
.m2sim-filter{padding:13px;border:1px solid var(--line);border-radius:8px;background:#f8fafb}
.m2sim-filter strong{display:block;margin-bottom:8px;font-size:9px;letter-spacing:.06em}
.m2sim-filter select{width:100%!important;height:42px!important;border:1px solid #cfd6dc!important;border-radius:6px!important;background:#fff!important;padding:0 9px!important}

.m2sim-slot-area{display:grid;grid-template-columns:minmax(0,1fr) 48px minmax(0,1fr);gap:10px;align-items:stretch}
.m2sim-slot{padding:12px;border:1px solid var(--line);border-radius:8px;background:#fff}
.m2sim-slot-title{display:flex;align-items:center;gap:8px;margin-bottom:10px}
.m2sim-slot-title>span{flex:0 0 auto;color:var(--r);font-size:9px;font-weight:900}
.m2sim-slot-title select{width:100%!important;height:38px!important;border:1px solid #cfd6dc!important;border-radius:5px!important;background:#fff!important;padding:0 8px!important}
.m2sim-slot-preview{min-height:145px;display:flex;flex-direction:column;align-items:center;justify-content:center;padding:10px;border:1px solid #e8ecef;border-radius:7px;background:#fafbfc;text-align:center}
.m2sim-slot-preview img{max-width:96px!important;max-height:82px!important;width:auto!important;height:auto!important;object-fit:contain!important}
.m2sim-slot-preview strong{display:block;margin-top:7px;font-size:12px}.m2sim-slot-preview small{display:block;margin-top:2px;color:var(--muted);font-size:9px}
.m2sim-empty-preview,.m2sim-preview-placeholder{color:#9aa4ad;font-size:10px}
.m2sim-preview-placeholder{font-size:28px}
.m2sim-piece-count{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:10px!important;margin-top:10px!important;font-size:9px!important;font-weight:900!important;color:#68737d!important}
.m2sim-piece-count select{width:110px!important;height:34px!important;border:1px solid #cfd6dc!important;border-radius:5px!important;background:#fff!important}
.m2sim-vs{display:grid;place-items:center;font-size:24px;color:#95a0aa;font-weight:900}

.m2sim-summary-bar{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:12px 18px;border-top:1px solid var(--line);border-bottom:1px solid var(--line);background:#f8fafb}
.m2sim-summary-bar strong{display:block;font-size:10px}.m2sim-summary-bar span{display:block;margin-top:2px;color:var(--muted);font-size:9px}
.m2sim-summary-bar button{border:0;background:transparent;color:var(--r);font-size:10px;font-weight:900;cursor:pointer}

.m2sim-total-bonuses{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;padding:14px 18px}
.m2sim-total-chip{padding:9px 10px;border:1px solid #e2e7eb;border-radius:6px;background:#fff}
.m2sim-total-chip strong{display:block;font-size:10px;line-height:1.35}.m2sim-total-chip small{display:block;margin-top:3px;color:var(--r);font-size:8px;font-weight:900}
.m2sim-empty-bonus{grid-column:1/-1;padding:20px;text-align:center;color:#8c969f;font-size:10px}

.m2sim-selected-sets{display:grid;grid-template-columns:1fr 1fr;gap:12px;padding:0 18px 16px}
.m2sim-selected-sets>article{overflow:hidden;border:1px solid var(--line);border-radius:8px;background:#fff}
.m2sim-selected-sets header{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:12px;border-bottom:1px solid #edf0f2}
.m2sim-selected-sets header span{display:block;color:var(--r);font-size:8px;font-weight:900}.m2sim-selected-sets header strong{display:block;margin-top:2px;font-size:13px}.m2sim-selected-sets header b{padding:5px 7px;border-radius:5px;background:#fff1f2;color:var(--r);font-size:9px}
.m2sim-piece-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:7px;padding:10px}
.m2sim-piece-item{padding:7px;border:1px solid #e6eaed;border-radius:6px;background:#fafbfc;text-align:center}
.m2sim-piece-item img{display:block;max-width:100%!important;max-height:68px!important;width:auto!important;height:auto!important;margin:auto;object-fit:contain!important}
.m2sim-piece-ph{height:55px;display:grid;place-items:center;color:#aab2b9;font-size:22px}
.m2sim-piece-item strong{display:block;margin-top:4px;font-size:9px;line-height:1.25}.m2sim-piece-item small{display:block;margin-top:2px;color:var(--r);font-size:7px;font-weight:900}
.m2sim-card-bonuses{padding:10px 12px;border-top:1px solid #edf0f2;background:#f8fafb}.m2sim-card-bonuses small{display:block;margin-bottom:5px;color:#d17b00;font-size:8px}.m2sim-card-bonuses ul{margin:0;padding-left:17px}.m2sim-card-bonuses li{margin:4px 0;font-size:10px}.m2sim-card-bonuses p{margin:0;color:var(--muted);font-size:10px}
.m2sim-empty-card{min-height:190px;display:grid;place-items:center;color:#9aa3ab;font-size:10px}
.m2sim-footnote{margin:0 18px 18px;padding:10px 12px;border-radius:6px;background:#f4f6f8;color:#616b74;font-size:9px;line-height:1.5}.m2sim-footnote strong{color:#20262d}

@media(max-width:900px){
  .m2sim-top{grid-template-columns:1fr}
  .m2sim-slot-area{grid-template-columns:1fr}
  .m2sim-vs{height:28px}
  .m2sim-total-bonuses{grid-template-columns:repeat(2,1fr)}
}
@media(max-width:650px){
  .m2sim-selected-sets{grid-template-columns:1fr}
  .m2sim-total-bonuses{grid-template-columns:1fr}
  .m2sim-piece-grid{grid-template-columns:repeat(2,1fr)}
}


/* ==========================================================
   v2.4.0 — Full Modal Set Simulator
   ========================================================== */
html.m2sim-open,html.m2sim-open body{overflow:hidden!important}
.m2sim-launch{
  display:flex;align-items:center;justify-content:space-between;gap:16px;
  padding:18px;border-left:4px solid #cf0614;background:#fff
}
.m2sim-launch span{display:block;color:#cf0614;font-size:9px;font-weight:900;letter-spacing:.1em}
.m2sim-launch strong{display:block;margin-top:4px;font-size:18px}
.m2sim-launch small{display:block;margin-top:4px;color:#6c7680;font-size:11px}
.m2sim-launch button{
  min-height:42px;padding:0 16px;border:0;border-radius:6px;background:#cf0614;color:#fff;
  font-size:10px;font-weight:900;cursor:pointer
}

.m2sim-modal[hidden]{display:none!important}
.m2sim-modal{position:fixed;inset:0;z-index:999999;display:grid;place-items:center;padding:28px}
.m2sim-backdrop{position:absolute;inset:0;background:rgba(0,0,0,.78);backdrop-filter:blur(3px)}
.m2sim-dialog{
  position:relative;z-index:2;width:min(1120px,94vw);height:min(770px,90vh);
  display:flex;flex-direction:column;overflow:hidden;border:1px solid #41413c;border-radius:12px;
  background:#292925;color:#e9e8e1;box-shadow:0 28px 80px rgba(0,0,0,.65);outline:0
}

.m2sim-modal-head{
  display:flex;align-items:flex-start;justify-content:space-between;gap:16px;
  padding:19px 22px 12px
}
.m2sim-modal-head h3{margin:0!important;color:#f1efe8!important;font-size:19px!important}
.m2sim-modal-head p{margin:4px 0 0!important;color:#aaa99f;font-size:12px}
.m2sim-close{border:0;background:transparent;color:#aaa99f;font-size:26px;cursor:pointer}

.m2sim-toolbar{display:flex;align-items:center;gap:10px;padding:0 22px 15px}
.m2sim-gender{display:flex;border:1px solid #44443f;border-radius:7px;overflow:hidden}
.m2sim-gender button{
  min-height:39px;padding:0 16px;border:0;border-right:1px solid #44443f;background:#2f2f2a;color:#aaa99f;
  font-size:11px;font-weight:800;cursor:pointer
}
.m2sim-gender button:last-child{border-right:0}
.m2sim-gender button.is-active{background:#514838;color:#d6b978}
.m2sim-toggle{display:flex!important;align-items:center!important;gap:8px!important;min-height:39px;padding:0 13px!important;border:1px solid #44443f;border-radius:7px;background:#2f2f2a;cursor:pointer}
.m2sim-toggle input{display:none!important}
.m2sim-toggle>span{position:relative;width:34px;height:18px;border-radius:99px;background:#171714}
.m2sim-toggle>span:before{content:"";position:absolute;left:3px;top:3px;width:12px;height:12px;border-radius:50%;background:#aaa99f;transition:.15s}
.m2sim-toggle input:checked+span{background:#765f32}
.m2sim-toggle input:checked+span:before{left:19px;background:#e6c877}
.m2sim-toggle b{font-size:10px;color:#aaa99f;font-weight:700}
.m2sim-clear-all{width:39px;height:39px;border:1px solid #44443f;border-radius:7px;background:#2f2f2a;color:#aaa99f;cursor:pointer}

.m2sim-modal-body{
  min-height:0;display:grid;grid-template-columns:minmax(0,1fr) 400px;gap:16px;
  padding:0 22px 16px;overflow:hidden
}
.m2sim-catalog{min-height:0;overflow:auto;padding-right:7px}
.m2sim-catalog::-webkit-scrollbar,.m2sim-right::-webkit-scrollbar{width:7px}
.m2sim-catalog::-webkit-scrollbar-thumb,.m2sim-right::-webkit-scrollbar-thumb{background:#5a5a53;border-radius:99px}

.m2sim-category{margin-bottom:14px;padding:12px;border:1px solid #41413c;border-radius:9px;background:#272723}
.m2sim-category-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:10px}
.m2sim-category-head>strong{color:#c8aa6e;font-size:11px}
.m2sim-category-head label{position:relative!important;display:block!important;width:165px!important;height:34px!important}
.m2sim-category-head label span{position:absolute;left:10px;top:50%;transform:translateY(-50%);color:#b89e67;font-size:13px}
.m2sim-category-head input{
  width:100%!important;height:34px!important;padding:0 10px 0 30px!important;border:1px solid #42423d!important;border-radius:6px!important;
  background:#171714!important;color:#ddd!important;box-shadow:none!important;outline:0!important;font-size:10px!important
}

.m2sim-item-grid{display:grid;grid-template-columns:repeat(10,minmax(47px,1fr));gap:7px}
.m2sim-item{
  position:relative;min-width:0;aspect-ratio:1/1.08;padding:4px;border:1px solid #45453f;border-radius:6px;background:#1f1f1c;color:#ddd;cursor:pointer;
  transition:.12s;overflow:hidden
}
.m2sim-item:hover{border-color:#a88337;transform:translateY(-1px)}
.m2sim-item.is-selected{border-color:#d4a734;box-shadow:inset 0 0 0 1px #d4a734,0 0 0 1px rgba(212,167,52,.2)}
.m2sim-item-img{height:100%;display:grid;place-items:center}
.m2sim-item img{display:block;max-width:100%!important;max-height:58px!important;width:auto!important;height:auto!important;object-fit:contain!important}
.m2sim-item i{font-style:normal;color:#666;font-size:20px}
.m2sim-item small{display:none}

.m2sim-right{min-height:0;overflow:auto;padding-right:5px}
.m2sim-right h4{margin:0 0 9px;color:#c8aa6e;font-size:10px;letter-spacing:.05em}
.m2sim-combos{margin-bottom:18px}
.m2sim-combo-row{
  width:100%;display:grid;grid-template-columns:31px 55px minmax(0,1fr);align-items:center;gap:7px;
  margin-bottom:6px;padding:8px;border:1px solid transparent;border-radius:7px;background:#1f1f1c;color:#bbb;text-align:left;cursor:pointer
}
.m2sim-combo-row:hover{border-color:#9f7d36}
.m2sim-eye{width:28px;height:28px;display:grid;place-items:center;border:1px solid #474740;border-radius:6px;color:#999}
.m2sim-combo-row strong{color:#86c48c;font-size:12px}
.m2sim-combo-row small{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:#aaa;font-size:9px}

.m2sim-total,.m2sim-selected{margin-bottom:14px;padding:13px;border:1px solid #45453f;border-radius:8px;background:#171714}
.m2sim-total h4,.m2sim-selected h4{color:#e2c579}
.m2sim-total p,.m2sim-selected p{margin:0!important;color:#aaa;font-size:10px}
.m2sim-active-set-note{display:flex;gap:4px;flex-wrap:wrap;margin-bottom:8px}
.m2sim-active-set-note span{padding:4px 6px;border:1px solid #4c493d;border-radius:4px;background:#292720;color:#c9ad6f;font-size:8px}
.m2sim-total-list{display:grid;gap:5px}
.m2sim-total-list>div{display:flex;align-items:center;justify-content:space-between;gap:10px;font-size:10px}
.m2sim-total-list span{color:#bbb}.m2sim-total-list strong{color:#86c48c}

.m2sim-selected-item{display:grid;grid-template-columns:38px minmax(0,1fr) 24px;align-items:center;gap:8px;padding:5px 0;border-bottom:1px solid #30302c}
.m2sim-selected-item:last-child{border-bottom:0}
.m2sim-selected-item img,.m2sim-selected-item i{width:36px;height:36px;object-fit:contain;background:#222;border-radius:4px}
.m2sim-selected-item strong{display:block;color:#ddd;font-size:9px}.m2sim-selected-item small{display:block;margin-top:2px;color:#c8aa6e;font-size:8px}
.m2sim-selected-item button{border:0;background:transparent;color:#888;font-size:16px;cursor:pointer}

.m2sim-note{margin:0 22px 18px;padding:9px 11px;border:1px solid #403f39;border-radius:7px;background:#242420}
.m2sim-note strong{display:block;color:#c8aa6e;font-size:9px}
.m2sim-note ul{display:flex;gap:7px 18px;flex-wrap:wrap;margin:5px 0 0;padding-left:16px}
.m2sim-note li{color:#8e8d85;font-size:8px}

@media(max-width:1000px){
  .m2sim-dialog{width:96vw;height:93vh}
  .m2sim-modal-body{grid-template-columns:minmax(0,1fr) 330px}
  .m2sim-item-grid{grid-template-columns:repeat(8,1fr)}
}
@media(max-width:760px){
  .m2sim-modal{padding:0}
  .m2sim-dialog{width:100vw;height:100dvh;max-height:none;border-radius:0}
  .m2sim-toolbar{overflow-x:auto;flex-wrap:nowrap;padding-bottom:10px}
  .m2sim-gender,.m2sim-toggle{flex:0 0 auto}
  .m2sim-modal-body{display:block;overflow:auto}
  .m2sim-catalog,.m2sim-right{overflow:visible}
  .m2sim-right{margin-top:15px}
  .m2sim-item-grid{grid-template-columns:repeat(6,1fr)}
  .m2sim-note{margin-top:0}
}
@media(max-width:480px){
  .m2sim-item-grid{grid-template-columns:repeat(5,1fr)}
  .m2sim-modal-head{padding:14px}
  .m2sim-toolbar,.m2sim-modal-body{padding-left:14px;padding-right:14px}
  .m2sim-note{margin-left:14px;margin-right:14px}
}


/* ==========================================================
   v2.5.1 Costume cards: 1..N piece controls + simulator entry
   ========================================================== */
.m2costumes-sim-open{
  min-width:142px!important;
  background:#171d24!important;
  border-color:#171d24!important;
}
.m2costumes-sim-open:hover{background:#2a323a!important}
.m2costume-rings{
  margin:0 14px 14px;
  padding:10px 12px;
  border:1px solid #e0e5e9;
  border-radius:8px;
  background:#fafbfc
}
.m2costume-rings-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:8px}
.m2costume-rings-head strong{font-size:9px;color:#cf0614;letter-spacing:.06em}
.m2costume-rings-head span{font-size:9px;color:#78828c}
.m2costume-ring-row{display:flex;gap:7px;overflow-x:auto;padding-bottom:2px}
.m2costume-ring{
  flex:0 0 48px;width:48px;height:48px;display:grid;place-items:center;
  border:1px solid #dce2e7;border-radius:6px;background:#fff
}
.m2costume-ring img{max-width:40px!important;max-height:40px!important;width:auto!important;height:auto!important;object-fit:contain!important}
.m2costume-ring span{color:#a5adb4;font-size:18px}

.m2costume-title{padding-bottom:8px!important}
.m2costume-title h4{font-size:15px!important}
.m2costume-pieces-compact{
  grid-template-columns:repeat(6,minmax(0,1fr))!important;
  align-items:end;
  min-height:118px
}
.m2costume-pieces-compact .m2costume-piece{
  padding:5px!important;
  background:#fff!important
}
.m2costume-pieces-compact .m2costume-piece-img{
  height:70px!important;
  margin-bottom:4px!important
}
.m2costume-pieces-compact .m2costume-piece-img img{
  max-height:68px!important
}
.m2costume-pieces-compact .m2costume-piece>strong{display:none!important}
.m2costume-pieces-compact .m2costume-piece>small{
  margin-top:0!important;
  color:#6e7881!important;
  font-size:8px!important
}
.m2costume-inline-sim{padding-top:10px!important}
.m2costume-piece-line{
  display:flex;
  align-items:center;
  gap:8px;
  margin-bottom:9px
}
.m2costume-piece-line>span{
  color:#777f87;
  font-size:9px
}
.m2costume-piece-line .m2costume-piece-buttons{margin:0!important}
.m2costume-piece-buttons button{
  width:31px!important;
  height:30px!important;
  border-radius:5px!important;
  font-size:10px!important
}
.m2costume-piece-buttons button.is-active{
  border-color:#cf0614!important;
  background:#cf0614!important;
  color:#fff!important
}
.m2costume-bonuses{
  min-height:96px!important;
  padding:10px 12px!important
}
.m2costume-bonuses li{
  color:#2e7d4f!important;
  font-size:10px!important
}
.m2costume-threshold-note{
  display:block;
  margin-bottom:6px;
  color:#b17800;
  font-size:8px;
  font-weight:800
}

@media(max-width:700px){
  .m2costumes-toolbar{grid-template-columns:1fr 1fr!important}
  .m2costumes-search{grid-column:1/-1}
  .m2costume-pieces-compact{grid-template-columns:repeat(3,1fr)!important}
}

.m2costume-ring.is-active{border-color:#cf0614!important;box-shadow:0 0 0 2px rgba(207,6,20,.10)!important;background:#fff1f2!important}


/* ==========================================================
   v2.6.1 — Kostümler toolbar UI polish
   ========================================================== */
.m2costumes-toolbar{
  display:grid!important;
  grid-template-columns:minmax(0,1fr) 190px 118px!important;
  gap:10px!important;
  align-items:center!important;
  padding:10px!important;
  margin:14px!important;
  border:1px solid #dfe4e9!important;
  border-radius:8px!important;
  background:#fff!important;
}

.m2costumes-search{
  position:relative!important;
  display:block!important;
  height:44px!important;
  border:1px solid #d1d8de!important;
  border-radius:6px!important;
  background:#fff!important;
  overflow:hidden!important;
}

.m2costumes-search>span{
  position:absolute!important;
  left:14px!important;
  top:50%!important;
  transform:translateY(-50%)!important;
  z-index:2!important;
  color:#7b8791!important;
  font-size:15px!important;
  pointer-events:none!important;
}

.m2costumes-search input{
  display:block!important;
  width:100%!important;
  height:42px!important;
  margin:0!important;
  padding:0 14px 0 42px!important;
  border:0!important;
  border-radius:6px!important;
  background:#fff!important;
  color:#1f2933!important;
  box-shadow:none!important;
  outline:none!important;
  font-size:13px!important;
  line-height:42px!important;
  text-align:left!important;
}

.m2costumes-search input:focus{
  box-shadow:inset 0 0 0 2px rgba(207,6,20,.08)!important;
}

.m2costumes-sim-open,
.m2costumes-clear{
  height:44px!important;
  min-height:44px!important;
  border-radius:6px!important;
  font-size:10px!important;
  font-weight:900!important;
  letter-spacing:.02em!important;
  cursor:pointer!important;
  transition:all .15s ease!important;
  white-space:nowrap!important;
}

.m2costumes-sim-open{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:7px!important;
  width:100%!important;
  padding:0 14px!important;
  border:1px solid #cf0614!important;
  background:#cf0614!important;
  color:#fff!important;
  box-shadow:0 2px 6px rgba(207,6,20,.18)!important;
}

.m2costumes-sim-open:hover{
  background:#b90512!important;
  border-color:#b90512!important;
  transform:translateY(-1px)!important;
  box-shadow:0 5px 12px rgba(207,6,20,.22)!important;
}

.m2costumes-sim-icon{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  font-size:13px!important;
  line-height:1!important;
}

.m2costumes-clear{
  width:100%!important;
  padding:0 14px!important;
  border:1px solid #cf0614!important;
  background:#fff!important;
  color:#cf0614!important;
  box-shadow:none!important;
}

.m2costumes-clear:hover{
  background:#fff1f2!important;
  color:#b90512!important;
  border-color:#b90512!important;
  transform:translateY(-1px)!important;
}

@media(max-width:900px){
  .m2costumes-toolbar{
    grid-template-columns:minmax(0,1fr) 170px 110px!important;
  }
}

@media(max-width:700px){
  .m2costumes-toolbar{
    grid-template-columns:1fr 1fr!important;
  }

  .m2costumes-search{
    grid-column:1/-1!important;
  }

  .m2costumes-sim-open,
  .m2costumes-clear{
    width:100%!important;
  }
}

@media(max-width:430px){
  .m2costumes-toolbar{
    grid-template-columns:1fr!important;
  }

  .m2costumes-search,
  .m2costumes-sim-open,
  .m2costumes-clear{
    grid-column:1!important;
  }
}
