/* MasaLobi Tavla ecosystem v20 - salary-free solo, friendship and ranked modes. */
.tavla-entry-grid{
 display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);
 gap:9px;margin:11px 0;padding:10px;
 border:1px solid #7d663b7d;border-radius:8px;
 background:linear-gradient(120deg,#143447,#102a3a);
}
.tavla-entry-grid[hidden],#tavla-stake-wrap[hidden],#pilot-stake-wrap[hidden]{display:none!important}
.tavla-entry-grid label{
 display:flex;flex-direction:column;gap:6px;
 min-width:0;color:#e0c389;font:700 10px/1.4 system-ui;
}
.tavla-entry-grid select,.tavla-entry-grid input{
 display:block;box-sizing:border-box;width:100%;min-height:32px;
 border:1px solid #617a85;border-radius:6px;
 background:#0a2434;color:#e4eef1;
 padding:5px 8px;font:11px system-ui;
}
.tavla-entry-grid>p{
 margin:0;grid-column:1/-1;color:#b6cdd4;font:10px/1.45 system-ui;
}
.v2-profile-career{
 display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;
 padding:0 15px;border-left:1px solid #3f6473;
}
.v2-profile-career small{
 font:700 9px/1.3 system-ui;color:#a8bec6;text-align:center;
}
.v2-profile-career strong{
 font:800 19px/1.25 system-ui;color:#f2d395;
}
body.mls-tavla .mls-rank-grid .tv-eco-ranking{padding:7px 6px;flex:1;min-width:0;}
.tv-eco-list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:5px;}
.tv-eco-rank-row{
 display:grid;grid-template-columns:20px minmax(0,1fr) auto;grid-template-rows:auto auto;
 column-gap:5px;row-gap:3px;align-items:center;
 padding:6px 5px;border-radius:6px;
 border:1px solid #45627b4d;background:#12334b;
}
.tv-eco-rank-number{grid-row:1/3;font:800 10px/1 system-ui;color:#e8bf75;text-align:center;}
.tv-eco-rank-name{grid-column:2;grid-row:1/3;font:700 10px/1.2 system-ui;color:#edf0ee;
 text-overflow:ellipsis;overflow:hidden;white-space:nowrap;}
.tv-eco-rank-rating{grid-column:3;grid-row:1;font:800 10px system-ui;color:#f6d392;text-align:right;}
.tv-eco-rank-points{grid-column:3;grid-row:2;font:700 9px system-ui;color:#a7cad3;text-align:right;}
.tv-eco-rank-actions{display:flex;justify-content:flex-end;margin-top:6px;}
.tv-eco-rank-actions button,.tv-eco-all-head button{
 border:1px solid #bc965c;border-radius:5px;background:#12354a;color:#f3d08d;
 padding:5px 8px;cursor:pointer;font:700 10px system-ui;
}
.tv-eco-rank-empty{color:#b4c9d4;font:11px/1.45 system-ui;padding:15px 4px;text-align:center;}
.tv-eco-all-dialog{
 width:min(680px,calc(100vw - 26px));max-height:80vh;overflow:auto;
 margin:auto;border:1px solid #d5ac65;border-radius:11px;
 background:linear-gradient(155deg,#102e43,#081c2c);color:#e9edf2;
 padding:0 15px 15px;
 box-shadow:0 22px 75px #000c;
}
.tv-eco-all-dialog::backdrop{background:#000b;backdrop-filter:blur(5px);}
.tv-eco-all-head{
 display:flex;justify-content:space-between;align-items:center;
 gap:10px;padding:11px 0;
}
.tv-eco-all-head h2{margin:0;font:700 18px Georgia,serif;color:#f0cf93;}
.tv-eco-all-dialog .tv-eco-rank-row{
 grid-template-columns:24px minmax(0,1fr) 85px;
}
#pilot-lobby #pilot-stake-big{
 width:81px;min-height:36px;padding:5px 7px;
 background:#09283a;border:1px solid #688495;border-radius:5px;
 color:#f2d9a4;font:700 12px system-ui;
}
#tavla-economy-result{
 margin:5px 0 0;padding:6px 10px;
 border:1px solid #ac875c;border-radius:7px;
 background:#78552d21;font:700 12px/1.4 system-ui;color:#f0c68a;
}
#tavla-economy-result[hidden]{display:none!important}
#tavla-economy-result[data-result="win"]{
 color:#b3e6bd;border-color:#638a6c;background:#24613c22;
}
#tavla-economy-result[data-result="lose"]{
 color:#ffb5a5;border-color:#a65e52;background:#7a332b33;
}
@media(max-width:780px){
 .tavla-entry-grid{grid-template-columns:1fr;}
 .v2-profile-career{padding:0 6px;}
 .tv-eco-rank-row{grid-template-columns:18px minmax(0,1fr) auto;}
}

/* Tavla v21: compact MasaLobi table creation options. */
body.mls-tavla .tavla-entry-grid{
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:9px 11px;padding:10px;
  margin:8px 0 9px;
}
body.mls-tavla .tavla-entry-grid .tavla-friendship-switch{
  display:flex;flex-direction:row;align-items:center;justify-content:flex-start;
  gap:10px;min-height:37px;padding:5px 8px;
  background:#102b3b;border:1px solid #496878;border-radius:7px;
  cursor:pointer;color:#e7c988;
}
body.mls-tavla .tavla-friendship-switch input{
  width:18px;height:18px;min-height:18px;margin:0;flex:none;
  accent-color:#d4a459;
}
body.mls-tavla .tavla-friendship-switch span{
  display:flex;flex-direction:column;gap:3px;font-size:11px;line-height:1.2;
}
body.mls-tavla .tavla-friendship-switch small{
  color:#93b3c4;font:9px/1.25 system-ui;
}
body.mls-tavla #tavla-stake-wrap{justify-content:center}
body.mls-tavla #tavla-stake-big{width:100%;max-width:none}
body.mls-tavla #tavla-create-message{
  grid-column:1/-1;background:#71292357;color:#ffb8aa;
  padding:8px 9px;border:1px solid #ab655d;border-radius:7px;
  font:700 11px/1.45 system-ui;margin:0;
}
body.mls-tavla #tavla-create-message[hidden],
body.mls-tavla #tavla-spectator-wrap[hidden]{display:none!important}
body.mls-tavla #v2-create-form button[type="submit"]:disabled{
  opacity:.45;cursor:not-allowed;box-shadow:none;filter:grayscale(.25)
}
body.mls-tavla .tavla-watch-link{
  font-size:10px;min-height:29px;padding:5px 8px;
}
#pilot-lobby .pilot-friendship-switch{
  display:flex;align-items:center;gap:6px;cursor:pointer;color:#edcd95;
  border:1px solid #546e81;border-radius:6px;
  background:#0a2336;padding:7px 9px;font:700 12px/1.3 system-ui;
}
#pilot-lobby .pilot-friendship-switch input{
  accent-color:#d5a85e;width:16px;height:16px;margin:0;
}
#pilot-stake-wrap[hidden],#pilot-spectator-access[hidden]{display:none!important}
#pilot-create:disabled{opacity:.42;cursor:not-allowed;}
@media(max-width:680px){
 body.mls-tavla .tavla-entry-grid{grid-template-columns:1fr;}
 body.mls-tavla .tavla-entry-grid>p{grid-column:1}
 #pilot-lobby{gap:5px}
 #pilot-lobby .target-label{min-width:0;}
}
