/* ==========================================================================
   Gladius Magnatus – Händler (Auktionshaus-Stil), Prägungen, Publikumsentscheid
   ========================================================================== */

/* ---------- Händler ---------- */
.gm-shop{max-width:1240px!important;width:96vw!important;height:88vh;display:flex;flex-direction:column;padding:16px 18px!important;position:relative;
  background:linear-gradient(180deg,#2c1c0f,#150d07)!important}
.gm-shop-head{display:flex;justify-content:space-between;align-items:flex-end;gap:12px;border-bottom:1px solid #6f4b24;padding:0 40px 10px 0;margin-bottom:12px}
.gm-shop-head h2{margin:0;color:#f0d49a}
.gm-shop-head p{margin:4px 0 0;color:#bfa77a;font-size:13px}
.gm-shop-gold{padding:7px 12px;border:1px solid #8a6230;border-radius:4px;background:#1a1009;color:#e9c97a;white-space:nowrap}
.gm-shop-body{flex:1;min-height:0;display:grid;grid-template-columns:230px 1fr;gap:14px}
.gm-shop-side{overflow:auto;padding:10px;border:1px solid #5e4322;border-radius:5px;background:linear-gradient(180deg,#24170c,#170e07)}
.gm-shop-q{width:100%;box-sizing:border-box;padding:9px 10px;background:#0f0a06;color:#ead8b0;border:1px solid #7a5428;border-radius:4px;font-size:14px}
.gm-shop-h{margin:14px 2px 6px;color:#c9a45a;font-size:11px;letter-spacing:2px;text-transform:uppercase;border-bottom:1px solid #4a3418;padding-bottom:4px}
.gm-shop-cat{display:flex!important;justify-content:space-between;width:100%;padding:7px 9px!important;margin:2px 0;font-size:14px!important;text-align:left;min-height:0!important;
  background:transparent!important;border:1px solid transparent!important;color:#dcc596!important;border-radius:3px!important}
.gm-shop-cat b{color:#9c8660;font-weight:400}
.gm-shop-cat:hover{background:rgba(201,164,90,.08)!important}
.gm-shop-cat.active{background:linear-gradient(180deg,#5a3517,#2a170b)!important;border-color:#c9a45a!important;color:#f6dca2!important}
.gm-shop-rar{display:flex;align-items:center;gap:8px;padding:4px 4px;font-size:14px;cursor:pointer}
.gm-shop-rar i{width:10px;height:10px;border-radius:2px;display:inline-block;box-shadow:0 0 6px currentColor}
.gm-shop-rar span{flex:1}
.gm-shop-rar b{color:#9c8660;font-weight:400}
.gm-shop-opt{display:flex;flex-direction:column;gap:4px;color:#d9c08e;font-size:13px;margin:6px 2px}
.gm-shop-opt.chk{flex-direction:row;align-items:center;gap:8px}
.gm-shop-opt select{padding:6px;background:#0f0a06;color:#ead8b0;border:1px solid #7a5428;border-radius:3px}
.gm-shop-reset{width:100%;margin-top:12px;padding:7px!important;font-size:13px!important}
.gm-shop-main{min-height:0;display:flex;flex-direction:column;border:1px solid #5e4322;border-radius:5px;background:#120b06;overflow:hidden}
.gm-shop-tablewrap{flex:1;overflow:auto}
.gm-shop-table{width:100%;border-collapse:collapse;font-size:14px}
.gm-shop-table th{position:sticky;top:0;z-index:1;background:linear-gradient(180deg,#3a2614,#24170c);color:#d9b874;font-weight:700;font-size:12px;letter-spacing:1px;text-transform:uppercase;
  padding:9px 10px;text-align:left;border-bottom:1px solid #8a6230;cursor:pointer;user-select:none;white-space:nowrap}
.gm-shop-table th.num{text-align:right}
.gm-shop-table th.on{color:#ffe2a0}
.gm-shop-row td{padding:7px 10px;border-bottom:1px solid rgba(120,84,40,.35);vertical-align:middle}
.gm-shop-row:hover td{background:rgba(201,164,90,.07)}
.gm-shop-row td.item{display:flex;align-items:center;gap:10px;min-width:260px}
.gm-shop-row .ico{flex:none;width:38px;height:38px;display:flex;align-items:center;justify-content:center;font-size:20px;border-radius:4px;
  background:radial-gradient(circle at 40% 35%,#3a2a1a,#140d07);border:2px solid var(--rar);box-shadow:0 0 8px color-mix(in srgb,var(--rar) 45%,transparent)}
.gm-shop-row b{font-size:14.5px}
.gm-shop-row small{display:block;color:#9c8a6a;font-size:12px;margin-top:2px}
.gm-shop-row td.num{text-align:right;white-space:nowrap;color:#cdb48a}
.gm-shop-row td.pos{color:#8fd18a}
.gm-shop-row td.neg{color:#e07a6a}
.gm-shop-row td.zero{color:#6f6250}
.gm-shop-row td.price{color:#f0cf82;font-weight:700}
.gm-shop-row td.price.short{color:#a0705a}
.gm-shop-row td.act{text-align:right;width:96px}
.gm-shop-row td.act button{padding:6px 12px!important;font-size:13px!important}
.gm-shop-row.sold td{opacity:.42}
.gm-sold{color:#9c8660;font-style:italic;font-size:13px}
.gm-shop-empty{text-align:center;color:#9c8660;padding:30px!important}
.gm-shop-toast{position:absolute;left:50%;bottom:18px;transform:translateX(-50%);padding:10px 16px;border:1px solid #c9a45a;border-radius:5px;background:#24170c;color:#ead8b0;
  box-shadow:0 10px 30px rgba(0,0,0,.6);animation:gmToast 2.6s ease forwards;z-index:5}
@keyframes gmToast{0%{opacity:0;transform:translate(-50%,10px)}10%,80%{opacity:1;transform:translate(-50%,0)}100%{opacity:0}}
.gm-rar{font-weight:700}
@media(max-width:850px){
  .gm-shop{height:92vh;padding:12px!important}
  .gm-shop-body{grid-template-columns:1fr;grid-template-rows:auto 1fr}
  .gm-shop-side{max-height:30vh}
  .gm-shop-table th:nth-child(5),.gm-shop-row td:nth-child(5){display:none}
  .gm-shop-row td.item{min-width:180px}
}
.gm-shop>.close{position:absolute!important;top:12px;right:12px;width:auto!important;z-index:3}

/* ---------- Prägungen ---------- */
.gm-praeg{display:flex;flex-wrap:wrap;gap:5px;justify-content:center;margin:6px 0 4px}
.gm-praeg.none{color:#8f7d5c;font-size:12px;font-style:italic}
.gm-pchip{display:inline-flex;align-items:center;gap:4px;padding:3px 8px;border-radius:11px;font-size:12px;line-height:1.3;cursor:help;border:1px solid;white-space:nowrap}
.gm-pchip.good{color:#a9e3a4;border-color:#3f7a3a;background:rgba(63,122,58,.18)}
.gm-pchip.bad{color:#f0a594;border-color:#8a3a2a;background:rgba(138,58,42,.18)}
.gm-pchip.mix{color:#f0d98a;border-color:#8a7430;background:rgba(138,116,48,.18)}
.gm-pleg{display:inline-flex;align-items:center;padding:3px 9px;border-radius:11px;font-size:11px;font-weight:700;letter-spacing:1.5px;color:#2a1806;
  background:linear-gradient(180deg,#ffe08a,#e0a23a);box-shadow:0 0 12px rgba(240,180,60,.55)}
.gm149-card.legendary{border-color:#f0b43c!important;box-shadow:0 0 0 1px rgba(240,180,60,.6),0 0 26px rgba(240,180,60,.28),inset 0 0 30px rgba(240,180,60,.08)!important;position:relative}
.gm149-card.legendary:before{content:'';position:absolute;inset:0;border-radius:inherit;pointer-events:none;background:linear-gradient(120deg,transparent 30%,rgba(255,230,160,.12) 45%,transparent 60%);background-size:250% 100%;animation:gmShine 4s linear infinite}
@keyframes gmShine{from{background-position:120% 0}to{background-position:-120% 0}}
.gm-detail-name .gm-praeg{margin-top:6px}
.gm-detail-name{display:flex!important;flex-direction:column;align-items:center}

/* ---------- Publikumsentscheid ---------- */
.gm-fight-stage{position:relative}
.gm-vote-choice{position:absolute;left:50%;bottom:8%;transform:translateX(-50%);display:flex;flex-direction:column;align-items:center;gap:6px;padding:14px 22px;
  background:linear-gradient(180deg,rgba(46,29,15,.96),rgba(24,15,8,.96));border:1px solid #d8b066;border-radius:6px;box-shadow:0 12px 34px rgba(0,0,0,.65);animation:gmPanelIn .25s ease-out;z-index:4;text-align:center}
.gm-vote-choice b{color:#f0d49a;font-size:18px;letter-spacing:1px}
.gm-vote-choice small{color:#c4ab7d}
.gm-vote-choice div{display:flex;gap:12px;margin-top:6px}
.gm-vote-choice button{min-width:130px;font-size:16px!important;padding:10px 16px!important}
.gm-vote-choice button.kill{background:linear-gradient(180deg,#7a1f14,#3a0d07)!important;border-color:#c4321f!important;color:#ffd9cf!important}

/* Gladiator-Details: Titel mittig, kleinerer Pinsel mit Abstand */
.gm-detail-title{justify-content:center!important;text-align:center}
.gm-detail-name b{gap:6px}
.gm-detail-name small{margin-top:4px}
.gm-pen{width:22px!important;height:22px!important;font-size:11px!important;margin-left:2px}
.gm-vote-choice{animation:gmVoteIn .25s ease-out}
@keyframes gmVoteIn{from{opacity:0;transform:translate(-50%,12px)}to{opacity:1;transform:translate(-50%,0)}}
.gm-detail-title{padding-left:10px!important;margin-left:30px!important}

/* ---------- Breitbild ---------- */
/* Kampf: Bühne passt in die Bildschirmhöhe, Kampfbericht rechts daneben */
@media(min-width:1280px){
  .gm-fight{display:grid!important;grid-template-columns:minmax(0,1fr) clamp(260px,22vw,360px);grid-template-areas:"head head" "stage log" "ctrl log";gap:10px 14px;align-items:start}
  .gm-fight-head{grid-area:head}
  .gm-fight-stage{grid-area:stage;width:100%;max-width:calc((100vh - 250px) * 2.2);justify-self:center}
  .gm-fight-controls{grid-area:ctrl}
  .gm-fight-log{grid-area:log;align-self:stretch;display:flex;flex-direction:column;margin:0!important;min-height:0;max-height:calc(100vh - 210px)}
  .gm-fight-log .log{flex:1;height:auto!important;min-height:200px;overflow:auto}
}
/* Karten: auf großen Bildschirmen größer */
.gm-world .gm-wframe,.gm-world .gm-wlegend,.gm-world .gm-wchips{max-width:calc(76vh * 1.2547 + 18px)}
.gm-lframe{max-width:calc(80vh * 1.846 + 18px)}
.gm-city .gm-cframe{max-width:calc(80vh * 1.538 + 18px);margin-left:auto;margin-right:auto}
.gm-city .gm-cquick{justify-content:center}
@media(max-width:850px){.gm-world .gm-wframe,.gm-world .gm-wlegend,.gm-world .gm-wchips,.gm-lframe,.gm-city .gm-cframe{max-width:none}}
.gm-shop-row .mstats{display:none;font-size:12px;color:#cdb48a;margin-top:2px}
@media(max-width:850px){
  .gm-shop-table th:nth-child(2),.gm-shop-table th:nth-child(3),.gm-shop-table th:nth-child(4),
  .gm-shop-row td:nth-child(2),.gm-shop-row td:nth-child(3),.gm-shop-row td:nth-child(4){display:none}
  .gm-shop-row .mstats{display:block}
  .gm-shop-row td.item{min-width:0}
  .gm-shop-row td.act{width:auto}
  .gm-shop{top:0}
}
@media(max-width:850px){.gm-shop{height:78vh!important}}
@media(max-width:850px){.modal{z-index:200!important}.gm-shop{height:calc(100vh - 24px)!important;height:calc(100dvh - 24px)!important}}
/* Breitbild-Weltkarte: so groß, wie die Bildschirmhöhe erlaubt */
.gm-world-wide .gm-wframe,.gm-world-wide .gm-wlegend,.gm-world-wide .gm-wchips{max-width:calc((100vh - 215px) * 2.022 + 18px)!important}
.gm-world-wide .world-intro p{margin:2px 0 0}
.gm-world-wide .world-intro h1{margin-bottom:0}
.gm-world-wide .gm-wframe{margin-top:8px}
.gm149-interest{color:#f0a594}
.gm149-interest strong{color:#f0c35a!important;font-size:12.5px;line-height:1.35;text-align:right}
.gm149-since span,.gm149-since strong{font-size:12.5px!important;color:#b9a074!important;font-weight:400!important}
.gm149-warn{margin-top:4px;padding:5px 7px;border:1px solid #a3402a;border-radius:3px;background:rgba(163,64,42,.2);color:#f3c2b2;font-size:12px;line-height:1.35;text-align:center;animation:gmTuPulse 2.4s ease-in-out infinite}
.gm149-warn b{color:#ffd9a0}

/* ---------- Erklär-Tooltips ---------- */
.gm-tip{position:fixed;z-index:1000;max-width:330px;padding:10px 12px;border-radius:10px;background:#1d140c;color:#f3e6cc;border:1px solid #b8893a;box-shadow:0 8px 24px rgba(0,0,0,.45);font-size:12.5px;line-height:1.4;pointer-events:none;opacity:0;transition:opacity .12s;left:-999px;top:-999px}
.gm-tip.on{opacity:1}
.gm-tip-h{font-weight:800;font-size:14px;color:#f0c46a;margin-bottom:4px;display:flex;gap:6px;align-items:center}
.gm-tip-h em{font-style:normal;font-size:10.5px;font-weight:700;padding:1px 7px;border-radius:9px;margin-left:auto}
.gm-tip-h em.good{background:#2f6b2f;color:#dff5d8}.gm-tip-h em.bad{background:#7a2626;color:#ffdede}.gm-tip-h em.mix{background:#6b5520;color:#fff0c8}
.gm-tip-d{color:#e8dcc2}
.gm-tip-sep{margin:8px 0 3px;padding-top:6px;border-top:1px solid rgba(240,196,106,.3);font-size:11px;color:#c9a96a;text-transform:uppercase;letter-spacing:.04em}
.gm-tip-calc{width:100%;border-collapse:collapse}
.gm-tip-calc td{padding:1px 0}.gm-tip-calc td:last-child{text-align:right;font-weight:700;padding-left:12px;white-space:nowrap}
.gm-tip-calc tr.sum td{border-top:1px solid rgba(240,196,106,.35);padding-top:3px;color:#f0c46a}
.gm-tip-fx{display:flex;flex-wrap:wrap;gap:4px;margin-top:6px}
.gm-tip-fx span{padding:2px 7px;border-radius:7px;background:rgba(255,255,255,.08);font-weight:700}
.gm-tip-fx .up{color:#8fe08f}.gm-tip-fx .down{color:#ff9b8f}
.gm-tip-note{margin-top:6px;font-size:11.5px;color:#cdbb95}
.gm-tip-on{margin-top:6px;color:#8fe08f;font-weight:700}.gm-tip-off{margin-top:6px;color:#ff9b8f;font-weight:700}
[data-tipk],[data-tip]{cursor:help}
.gm-stat[data-tipk]:hover,.gm149-statline span[data-tipk]:hover,.gm-pchip:hover{outline:1px dashed rgba(184,137,58,.7);outline-offset:1px}

/* ---------- Reparatur ---------- */
.gm-rep-open{padding:7px 12px!important;font-weight:700;white-space:nowrap}
.gm-rep-open b{display:inline-block;min-width:18px;padding:0 5px;margin-left:4px;border-radius:9px;background:#9b2c22;color:#fff;font-size:11px}
.gm-shop-head .gm-rep-open{margin-left:auto;margin-right:10px}
.gm-rep{max-width:760px}
.gm-rep-all{display:flex;justify-content:space-between;align-items:center;gap:10px;margin:10px 0;padding:10px 12px;border:1px solid #6b4a24;border-radius:8px;background:rgba(0,0,0,.18);flex-wrap:wrap}
.gm-rep-list{display:flex;flex-direction:column;gap:8px;max-height:60vh;overflow:auto;padding-right:4px}
.gm-rep-row{display:grid;grid-template-columns:54px 1fr auto;gap:12px;align-items:center;padding:8px 10px;border:1px solid #5a3d1f;border-radius:8px;background:rgba(0,0,0,.15)}
.gm-rep-row.broken{border-color:#a3392c;background:rgba(120,30,20,.18)}
.gm-rep-img{width:54px;height:54px;display:flex;align-items:center;justify-content:center;overflow:hidden}
.gm-rep-img svg,.gm-rep-img img{max-width:54px;max-height:54px}
.gm-rep-info{display:flex;flex-direction:column;gap:2px;min-width:0}
.gm-rep-info span{font-size:12px;opacity:.85}
.gm-rep-dur{display:flex;align-items:center;gap:8px}
.gm-rep-bar{flex:0 0 120px;height:7px;border-radius:4px;background:#2a1a0e;overflow:hidden;border:1px solid #5a3d1f}
.gm-rep-bar i,.gm-slot-dur i{display:block;height:100%;background:#6fae4f}
.gm-rep-bar.low i,.gm-slot-dur.low i{background:#d39a2f}.gm-rep-bar.broken,.gm-slot-dur.broken{border-color:#b33}
.gm-rep-foot{display:flex;gap:8px;justify-content:flex-end;margin-top:12px;flex-wrap:wrap}
.gm-slot-dur{display:block;width:58px;height:5px;border-radius:3px;background:#2a1a0e;border:1px solid #5a3d1f;overflow:hidden}
.gm-slot-broken .gm-slot-box{border-color:#b33!important;box-shadow:inset 0 0 12px rgba(200,40,30,.6)}
.gm-rep-gl{display:flex;justify-content:space-between;align-items:center;gap:8px;margin:8px 0 0;padding:6px 10px;border:1px solid #8a6a2c;border-radius:6px;background:rgba(160,110,30,.15);font-size:13px}
.gm-rep-gl.broken{border-color:#b33;background:rgba(150,30,20,.2)}
.gm-rep-gl button{padding:5px 10px!important}
@media (max-width:640px){.gm-rep-row{grid-template-columns:44px 1fr}.gm-rep-row button{grid-column:1/-1}.gm-rep-bar{flex-basis:80px}.gm-shop-head .gm-rep-open{margin:6px 0}}
.gm-rep-item{margin-top:6px;padding:4px 10px!important;font-size:12px}
.gm-rep-img{border:2px solid #6b4a24;border-radius:3px;background:radial-gradient(circle,#2a1a0e,#120a05)}.gm-rep-img svg{width:44px;height:44px}
