/* ALPAX Trading Arena — Empire 2.0 */
:root {
  --empire-gold: #d6b36a;
  --empire-gold-soft: rgba(214,179,106,.14);
  --empire-panel: rgba(14,15,20,.9);
  --empire-border: rgba(214,179,106,.22);
}
.page-empire .arena-page { max-width: 1500px; }
.empire-hero { display:grid; grid-template-columns:minmax(0,1.18fr) minmax(330px,.82fr); gap:22px; margin-bottom:22px; }
.empire-character-card,.empire-wealth-panel,.empire-page-hero { border:1px solid var(--empire-border); background:linear-gradient(145deg,rgba(20,20,25,.98),rgba(8,8,12,.96)); border-radius:22px; overflow:hidden; }
.empire-character-card { display:grid; grid-template-columns:minmax(280px,.95fr) minmax(250px,.8fr); min-height:320px; }
.empire-character-scene { position:relative; min-height:320px; overflow:hidden; background:radial-gradient(circle at 55% 34%,rgba(214,179,106,.16),transparent 32%),linear-gradient(180deg,#111219 0%,#08090d 68%); }
.empire-skyline { position:absolute; inset:auto 0 0; height:46%; opacity:.36; background:linear-gradient(90deg,transparent 1%,#262832 1% 9%,transparent 9% 12%,#1f222b 12% 20%,transparent 20% 23%,#2d2e36 23% 34%,transparent 34% 38%,#1c1f26 38% 49%,transparent 49% 54%,#282a33 54% 70%,transparent 70% 74%,#20232a 74% 84%,transparent 84% 88%,#292b33 88% 98%,transparent 98%); clip-path:polygon(0 42%,8% 42%,8% 18%,17% 18%,17% 55%,27% 55%,27% 0,38% 0,38% 32%,49% 32%,49% 12%,61% 12%,61% 48%,73% 48%,73% 22%,84% 22%,84% 56%,100% 56%,100% 100%,0 100%); }
.empire-character { position:absolute; left:50%; top:50%; width:150px; height:230px; transform:translate(-50%,-48%); }
.empire-character-head { position:absolute; left:45px; top:0; width:60px; height:66px; display:grid; place-items:center; border-radius:48% 48% 44% 44%; color:#15100a; background:linear-gradient(145deg,#f1d29b,#b98145); font:600 25px/1 Inter,sans-serif; box-shadow:0 0 0 5px #15151b,0 0 35px rgba(214,179,106,.23); z-index:3; }
.empire-character-head::after { content:""; position:absolute; left:-9px; top:-10px; width:78px; height:34px; border-radius:50% 50% 30% 30%; background:#171318; clip-path:polygon(0 75%,8% 18%,38% 0,71% 12%,100% 53%,90% 80%,72% 45%,50% 35%,28% 50%,10% 100%); }
.empire-character-body { position:absolute; left:18px; top:55px; width:114px; height:170px; border-radius:54px 54px 18px 18px; background:linear-gradient(90deg,#17171d,#30313a 48%,#13141a); clip-path:polygon(18% 0,82% 0,100% 25%,90% 100%,10% 100%,0 25%); box-shadow:inset 0 0 0 1px rgba(255,255,255,.08); }
.empire-character-body::before { content:""; position:absolute; left:44px; top:0; width:27px; height:98px; background:linear-gradient(#ece6dc,#b9b2a8); clip-path:polygon(0 0,100% 0,70% 100%,30% 100%); }
.empire-character-body::after { content:""; position:absolute; left:53px; top:7px; width:10px; height:72px; background:linear-gradient(#d6b36a,#76511e); clip-path:polygon(50% 0,100% 15%,70% 100%,30% 100%,0 15%); }
.empire-character-emblem { position:absolute; right:22px; top:95px; width:34px; height:34px; display:grid; place-items:center; color:var(--empire-gold); border:1px solid rgba(214,179,106,.55); border-radius:50%; background:#111116; font-style:normal; z-index:4; }
.empire-desk { position:absolute; left:9%; right:9%; bottom:20px; height:50px; border-top:5px solid #302a24; background:linear-gradient(180deg,#15141a,#0a0a0d); box-shadow:0 -8px 35px rgba(0,0,0,.55); }
.empire-desk i { position:absolute; bottom:38px; width:82px; height:55px; border:3px solid #22242c; border-bottom-width:6px; background:linear-gradient(145deg,#091018,#172332); box-shadow:inset 0 0 20px rgba(72,134,196,.15); }
.empire-desk i:nth-child(1){left:12%;transform:rotate(-4deg)}.empire-desk i:nth-child(2){left:50%;transform:translateX(-50%)}.empire-desk i:nth-child(3){right:12%;transform:rotate(4deg)}
.empire-character-copy { display:flex; flex-direction:column; justify-content:center; padding:34px; }
.empire-character-copy h1 { margin:.35rem 0 .1rem; font-size:clamp(2rem,4vw,3.8rem); font-weight:500; letter-spacing:-.045em; }
.empire-character-copy p { color:var(--muted,#999); }
.empire-level-line { height:7px; margin:25px 0 9px; border-radius:999px; overflow:hidden; background:rgba(255,255,255,.08); }
.empire-level-line span { display:block; height:100%; background:linear-gradient(90deg,#896223,var(--empire-gold)); }
.empire-character-copy small { color:#8f9099; }
.empire-wealth-panel { padding:34px; display:flex; flex-direction:column; justify-content:center; }
.empire-net-worth { display:block; margin:10px 0 8px; color:#f4e0af; font:500 clamp(2.4rem,5vw,5.2rem)/.98 "JetBrains Mono",monospace; letter-spacing:-.07em; }
.empire-wealth-panel>p { max-width:600px; color:#9899a2; }
.empire-metric-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; margin-top:28px; }
.empire-metric-grid article { padding:15px; border:1px solid rgba(255,255,255,.07); background:rgba(255,255,255,.025); border-radius:13px; }
.empire-metric-grid small,.empire-metric-grid b { display:block; }.empire-metric-grid small { color:#858690; margin-bottom:7px; }.empire-metric-grid b { font-size:1rem; }
.empire-actions-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; margin-bottom:22px; }
.empire-actions-grid>a { display:grid; grid-template-columns:42px 1fr auto; gap:13px; align-items:center; padding:18px; color:inherit; border:1px solid rgba(255,255,255,.075); border-radius:16px; background:rgba(16,17,21,.78); text-decoration:none; transition:.2s ease; }
.empire-actions-grid>a:hover { border-color:var(--empire-border); transform:translateY(-2px); background:rgba(214,179,106,.055); }
.empire-actions-grid i { width:42px;height:42px;display:grid;place-items:center;border-radius:12px;background:var(--empire-gold-soft);color:var(--empire-gold);font-style:normal;font-size:1.25rem; }
.empire-actions-grid strong,.empire-actions-grid small { display:block; }.empire-actions-grid small{margin-top:3px;color:#84858e}.empire-actions-grid>*>span{color:var(--empire-gold)}
.empire-breakdown { display:grid; gap:13px; }.empire-breakdown-row{display:grid;grid-template-columns:minmax(130px,190px) minmax(120px,1fr) 130px;align-items:center;gap:16px}.empire-breakdown-row>div{height:9px;overflow:hidden;border-radius:999px;background:rgba(255,255,255,.07)}.empire-breakdown-row i{display:block;height:100%;border-radius:inherit;background:linear-gradient(90deg,#70501e,var(--empire-gold))}.empire-breakdown-row strong{text-align:right;font-family:"JetBrains Mono",monospace}
.empire-two-columns { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;margin-bottom:18px; }.empire-two-columns>.content-section{margin:0}
.empire-flow-list { display:grid;gap:12px }.empire-flow-list>div{display:flex;justify-content:space-between;gap:20px;padding:13px 0;border-bottom:1px solid rgba(255,255,255,.065)}.empire-flow-list .is-total{padding-top:18px;border:0;font-size:1.12rem}.empire-flow-list b{font-family:"JetBrains Mono",monospace}
.empire-asset-cards,.empire-owned-grid { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px }.empire-asset-card,.empire-owned-card{padding:18px;border:1px solid rgba(255,255,255,.075);border-radius:15px;background:rgba(255,255,255,.025)}.empire-asset-card{display:grid;grid-template-columns:1fr auto auto;align-items:center;gap:15px}.empire-asset-card>div{display:flex;align-items:center;gap:12px}.asset-symbol{display:grid;place-items:center;width:42px;height:42px;border-radius:50%;background:var(--empire-gold-soft);color:var(--empire-gold);font-size:.78rem}.empire-asset-card small,.empire-asset-card strong{display:block}.empire-asset-card small{color:#858690;margin-top:3px}.empire-asset-card>b{font-family:"JetBrains Mono",monospace}
.empire-history-list { display:grid;gap:2px }.empire-history-list article{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:13px 0;border-bottom:1px solid rgba(255,255,255,.06)}.empire-history-list strong,.empire-history-list small{display:block}.empire-history-list small{color:#777984;margin-top:3px}.empire-history-list b{font-family:"JetBrains Mono",monospace;white-space:nowrap}
.empire-page-hero { display:flex;align-items:center;justify-content:space-between;gap:25px;padding:30px 32px;margin-bottom:20px }.empire-page-hero h1{margin:.3rem 0;font-size:clamp(1.8rem,4vw,3.2rem);font-weight:500;letter-spacing:-.04em}.empire-page-hero p{margin:0;max-width:760px;color:#92939d}.empire-page-balance{text-align:right;flex:none}.empire-page-balance small,.empire-page-balance strong{display:block}.empire-page-balance small{color:#8c8d96}.empire-page-balance strong{margin-top:5px;color:#f1d89e;font:500 clamp(1.45rem,3vw,2.4rem)/1 "JetBrains Mono",monospace}
.empire-shop-grid { display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin-bottom:22px }.empire-shop-card{position:relative;padding:22px;border:1px solid rgba(255,255,255,.075);border-radius:18px;background:linear-gradient(145deg,rgba(20,21,26,.92),rgba(10,10,14,.93));overflow:hidden}.empire-shop-card::after{content:"";position:absolute;right:-60px;top:-60px;width:160px;height:160px;border-radius:50%;background:radial-gradient(circle,rgba(214,179,106,.1),transparent 67%);pointer-events:none}.empire-shop-icon{display:grid;place-items:center;width:54px;height:54px;margin-bottom:16px;border:1px solid var(--empire-border);border-radius:15px;color:var(--empire-gold);font-size:1.6rem;background:var(--empire-gold-soft)}.empire-shop-card>.pill{position:absolute;right:18px;top:18px}.empire-shop-card h2{margin:0 0 8px;font-size:1.22rem}.empire-shop-card>p{min-height:44px;color:#8f909a;font-size:.91rem}.empire-shop-card dl{display:grid;gap:8px;margin:20px 0}.empire-shop-card dl>div{display:flex;justify-content:space-between;gap:12px;padding-bottom:8px;border-bottom:1px solid rgba(255,255,255,.055)}.empire-shop-card dt{color:#7e808a}.empire-shop-card dd{margin:0;text-align:right;font-family:"JetBrains Mono",monospace}.empire-buy-form{display:grid;grid-template-columns:95px 1fr;gap:8px;align-items:end}.empire-buy-form label{font-size:.77rem;color:#898a93}.empire-buy-form input{margin-top:4px}.empire-shop-card>form:not(.empire-buy-form) .btn{width:100%}
.empire-owned-card{display:flex;flex-direction:column;gap:17px}.empire-owned-head{display:flex;gap:13px;align-items:center}.empire-owned-head>span{display:grid;place-items:center;width:44px;height:44px;border-radius:12px;background:var(--empire-gold-soft);color:var(--empire-gold);font-size:1.2rem}.empire-owned-head strong,.empire-owned-head small{display:block}.empire-owned-head small{margin-top:3px;color:#858690}.empire-owned-stats{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.empire-owned-stats>div{padding:11px;border-radius:10px;background:rgba(255,255,255,.025);border:1px solid rgba(255,255,255,.055)}.empire-owned-stats small,.empire-owned-stats b{display:block}.empire-owned-stats small{color:#777984;margin-bottom:4px}.empire-owned-stats b{font-family:"JetBrains Mono",monospace;font-size:.88rem}.empire-ranking .is-current-user{background:rgba(214,179,106,.06)}

@media (max-width:1100px){.empire-hero{grid-template-columns:1fr}.empire-actions-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.empire-shop-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (max-width:720px){
  .empire-hero{gap:12px}.empire-character-card{grid-template-columns:1fr;min-height:auto}.empire-character-scene{min-height:280px}.empire-character-copy{padding:22px}.empire-wealth-panel{padding:23px}.empire-net-worth{font-size:2.45rem}.empire-metric-grid{grid-template-columns:1fr 1fr;gap:7px}.empire-metric-grid article{padding:12px}.empire-actions-grid{grid-template-columns:1fr;gap:8px}.empire-actions-grid>a{padding:14px}.empire-two-columns{grid-template-columns:1fr;gap:12px}.empire-breakdown-row{grid-template-columns:105px 1fr 105px;gap:9px;font-size:.78rem}.empire-asset-cards,.empire-owned-grid{grid-template-columns:1fr}.empire-asset-card{grid-template-columns:1fr auto}.empire-asset-card form{grid-column:1/-1}.empire-page-hero{align-items:flex-start;flex-direction:column;padding:22px}.empire-page-balance{text-align:left}.empire-shop-grid{grid-template-columns:1fr;gap:10px}.empire-shop-card{padding:18px}.empire-owned-stats{grid-template-columns:1fr 1fr}.empire-ranking th:nth-child(4),.empire-ranking td:nth-child(4),.empire-ranking th:nth-child(6),.empire-ranking td:nth-child(6){display:none}.page-empire .arena-page-context{margin-bottom:10px}
}
@media (max-width:390px){.empire-metric-grid{grid-template-columns:1fr}.empire-breakdown-row{grid-template-columns:95px 1fr}.empire-breakdown-row strong{grid-column:2;text-align:left}.empire-owned-stats{grid-template-columns:1fr}.empire-buy-form{grid-template-columns:1fr}}
.empire-breakdown-row .empire-bar-debt { background:linear-gradient(90deg,#6e2028,#d55a66); }

/* ========================================================================
   Empire V2.0.1 — corrections d'interface et garage automobile
   ======================================================================== */
.empire-character-copy { min-width: 0; overflow: hidden; }
.empire-character-copy h1 {
  max-width: 100%;
  font-size: clamp(1.85rem, 3.45vw, 3.55rem);
  line-height: 1;
  overflow-wrap: anywhere;
  word-break: normal;
  text-wrap: balance;
}
.empire-character-copy p,
.empire-character-copy small { max-width: 100%; overflow-wrap: anywhere; }

.garage-page-hero { position: relative; }
.garage-overview {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 11px;
  margin: 0 0 22px;
}
.garage-overview article {
  min-width: 0;
  padding: 17px 18px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 15px;
  background: rgba(15,16,21,.84);
}
.garage-overview small,
.garage-overview strong,
.garage-overview span { display: block; }
.garage-overview small { color: #858690; font-size: .72rem; }
.garage-overview strong {
  margin-top: 7px;
  overflow: hidden;
  color: #f1d89e;
  font: 500 1.15rem/1.15 "JetBrains Mono", monospace;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.garage-overview span { margin-top: 6px; color: #71737d; font-size: .72rem; line-height: 1.35; }

.garage-catalog-section { margin-bottom: 22px; }
.garage-catalog-heading { margin-bottom: 12px; }
.garage-catalog-count {
  flex: none;
  padding: 7px 10px;
  border: 1px solid var(--empire-border);
  border-radius: 999px;
  background: var(--empire-gold-soft);
  color: var(--empire-gold);
  font: 500 .72rem/1 "JetBrains Mono", monospace;
}
.garage-filter {
  display: flex;
  gap: 7px;
  margin: 0 0 14px;
  padding: 2px 0;
  overflow-x: auto;
  scrollbar-width: thin;
}
.garage-filter button {
  flex: 0 0 auto;
  min-height: 36px;
  padding: 8px 13px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 999px;
  background: #111218;
  color: #8e909a;
  font: 500 .74rem/1 Inter, sans-serif;
  cursor: pointer;
}
.garage-filter button:hover,
.garage-filter button.is-active {
  border-color: rgba(214,179,106,.48);
  background: rgba(214,179,106,.12);
  color: #f2dca5;
}
.garage-shop-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.garage-shop-grid > [hidden] { display: none !important; }
.vehicle-card { display: flex; min-width: 0; flex-direction: column; }
.vehicle-card-visual {
  position: relative;
  height: 112px;
  margin: -22px -22px 16px;
  overflow: hidden;
  border-bottom: 1px solid rgba(214,179,106,.16);
  background:
    radial-gradient(circle at 50% 120%, rgba(214,179,106,.28), transparent 48%),
    linear-gradient(145deg, #18191f, #0a0b0f);
}
.vehicle-card-visual::before,
.vehicle-card-visual::after,
.vehicle-card-visual i::before,
.vehicle-card-visual i::after { content: ""; position: absolute; }
.vehicle-card-visual > span {
  position: absolute;
  right: 14px;
  top: 10px;
  color: rgba(214,179,106,.2);
  font: 600 3.5rem/1 "JetBrains Mono", monospace;
}
.vehicle-card-visual i {
  position: absolute;
  left: 50%;
  bottom: 24px;
  width: 166px;
  height: 38px;
  transform: translateX(-50%);
  border: 1px solid rgba(233,210,160,.55);
  border-radius: 58% 45% 22% 22% / 70% 70% 28% 28%;
  background: linear-gradient(180deg, rgba(214,179,106,.18), rgba(214,179,106,.025));
  box-shadow: 0 12px 18px rgba(0,0,0,.45);
}
.vehicle-card-visual i::before {
  left: 30px;
  top: -19px;
  width: 94px;
  height: 27px;
  transform: skewX(-19deg);
  border: 1px solid rgba(233,210,160,.42);
  border-bottom: 0;
  border-radius: 50% 55% 0 0;
  background: rgba(9,10,14,.75);
}
.vehicle-card-visual i::after {
  left: 17px;
  bottom: -12px;
  width: 22px;
  height: 22px;
  border: 5px solid #090a0e;
  border-radius: 50%;
  background: #b99856;
  box-shadow: 105px 0 0 -5px #b99856, 105px 0 0 0 #090a0e;
}
.vehicle-visual-moto i,
.vehicle-visual-moto-sport i {
  width: 116px;
  height: 18px;
  bottom: 31px;
  border-radius: 50% 70% 30% 30%;
  transform: translateX(-50%) rotate(-4deg);
}
.vehicle-visual-moto i::before,
.vehicle-visual-moto-sport i::before {
  left: 45px;
  top: -28px;
  width: 34px;
  height: 34px;
  transform: skewX(-24deg) rotate(-6deg);
  border-radius: 60% 10% 30% 20%;
}
.vehicle-visual-moto i::after,
.vehicle-visual-moto-sport i::after {
  left: 3px;
  bottom: -17px;
  width: 28px;
  height: 28px;
  border-width: 5px;
  box-shadow: 82px 0 0 -5px #b99856, 82px 0 0 0 #090a0e;
}
.vehicle-visual-suv i,
.vehicle-visual-suv-luxe i { height: 48px; border-radius: 30% 35% 12% 12%; }
.vehicle-visual-suv i::before,
.vehicle-visual-suv-luxe i::before { top: -21px; height: 31px; transform: skewX(-8deg); }
.vehicle-visual-supercar i,
.vehicle-visual-hypercar i { height: 29px; border-radius: 68% 48% 20% 16%; }
.vehicle-visual-supercar i::before,
.vehicle-visual-hypercar i::before { left: 41px; top: -17px; width: 83px; height: 23px; }
.vehicle-card-tags { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.vehicle-card-tags .pill { position: static; }
.vehicle-tier { color: #777984; font-size: .68rem; }
.vehicle-brand {
  min-height: 0 !important;
  margin: 18px 0 4px !important;
  color: #8a8c95 !important;
  font-size: .7rem !important;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.vehicle-card h2 { margin-bottom: 2px; min-height: 2.6em; line-height: 1.3; }
.vehicle-card dl { margin-top: 16px; }
.vehicle-card form { margin-top: auto; padding-top: 6px; }
.vehicle-card form .btn { width: 100%; }
.garage-filter-empty { margin-top: 12px; }

.garage-empty-state {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr) auto;
  align-items: center;
  gap: 24px;
  min-height: 170px;
  padding: 24px;
  border: 1px dashed rgba(214,179,106,.25);
  border-radius: 16px;
  background: linear-gradient(110deg, rgba(214,179,106,.045), rgba(255,255,255,.012));
}
.garage-empty-state strong { display: block; margin-bottom: 7px; color: #e9e5da; font-size: 1.05rem; }
.garage-empty-state p { max-width: 620px; margin: 0; color: #7f818b; line-height: 1.55; }
.garage-empty-visual {
  position: relative;
  height: 105px;
  overflow: hidden;
  border: 1px solid rgba(214,179,106,.18);
  border-radius: 14px;
  background: radial-gradient(circle at 50% 115%, rgba(214,179,106,.2), transparent 50%), #0c0d12;
}
.garage-empty-visual span { position: absolute; left: 14px; top: 12px; color: rgba(214,179,106,.3); font: 500 .7rem/1 "JetBrains Mono", monospace; letter-spacing: .16em; }
.garage-empty-visual i {
  position: absolute;
  left: 50%;
  bottom: 27px;
  width: 126px;
  height: 29px;
  transform: translateX(-50%);
  border: 1px solid rgba(214,179,106,.5);
  border-radius: 58% 42% 20% 20%;
}
.garage-empty-visual i::before { content:""; position:absolute; left:31px; top:-18px; width:67px; height:23px; border:1px solid rgba(214,179,106,.38); border-bottom:0; border-radius:50% 50% 0 0; }
.garage-owned-card .empire-owned-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.garage-owned-icon { font: 600 .95rem/1 "JetBrains Mono", monospace; }
.garage-owned-card form .btn { width: 100%; }

@media (max-width: 1100px) {
  .garage-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .garage-shop-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .garage-empty-state { grid-template-columns: 145px minmax(0, 1fr); }
  .garage-empty-state .btn { grid-column: 1 / -1; width: 100%; }
}
@media (max-width: 720px) {
  .empire-character-copy h1 { font-size: clamp(1.9rem, 11vw, 3.2rem); }
  .garage-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
  .garage-overview article { padding: 13px 12px; }
  .garage-overview strong { font-size: .9rem; }
  .garage-overview span { font-size: .64rem; }
  .garage-catalog-heading { align-items: flex-start; }
  .garage-catalog-count { display: none; }
  .garage-filter { margin-right: -10px; padding-right: 10px; }
  .garage-shop-grid { grid-template-columns: 1fr; }
  .vehicle-card-visual { margin: -18px -18px 15px; }
  .vehicle-card h2 { min-height: 0; }
  .garage-empty-state { grid-template-columns: 1fr; gap: 15px; padding: 17px; text-align: left; }
  .garage-empty-visual { height: 125px; }
  .garage-owned-card .empire-owned-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 390px) {
  .garage-overview { grid-template-columns: 1fr; }
  .garage-owned-card .empire-owned-stats { grid-template-columns: 1fr; }
}
