/* RoiKib v3.8: stabilize native Discuz viewthread post columns, especially
   when moderator-only links or long credit totals are present. Native forms,
   permissions, DOM and moderator controls remain unchanged. */

/* A fixed table layout prevents administrator sidebar content from asking
   the browser for a wider first column and stacking the message underneath. */
body.rk-v3.pg_viewthread #postlist table.plhin {
  table-layout:fixed!important;
  width:100%!important;
  max-width:100%!important;
}
body.rk-v3.pg_viewthread #postlist table.plhin > tbody > tr > td.pls {
  box-sizing:border-box!important;
  width:190px!important;
  min-width:190px!important;
  max-width:190px!important;
  vertical-align:top;
}
body.rk-v3.pg_viewthread #postlist table.plhin > tbody > tr > td.plc {
  box-sizing:border-box!important;
  width:auto!important;
  min-width:0!important;
  vertical-align:top;
}

/* v3.7 used percentage widths on the author block. Replace those with an
   explicit border-box width so auto-layout can't resolve 100% recursively. */
body.rk-v3.pg_viewthread #postlist .pls .favatar {
  box-sizing:border-box!important;
  width:190px!important;
  min-width:0!important;
  max-width:100%!important;
  overflow-wrap:anywhere;
}
body.rk-v3.pg_viewthread #postlist .pls .favatar .avatar,
body.rk-v3.pg_viewthread #postlist .pls .favatar .tns {
  box-sizing:border-box!important;
  width:auto!important;
  min-width:0!important;
  max-width:100%!important;
}
body.rk-v3.pg_viewthread #postlist .pls .favatar .tns table {
  width:100%!important;
  table-layout:fixed!important;
}
body.rk-v3.pg_viewthread #postlist .pls .favatar .tns th,
body.rk-v3.pg_viewthread #postlist .pls .favatar .tns td {
  overflow-wrap:anywhere;
}
body.rk-v3.pg_viewthread #postlist .pls .favatar .tns a {font-size:11px!important;}
body.rk-v3.pg_viewthread #postlist .pls .favatar img {max-width:100%!important;height:auto;}

/* Prevent moderator tool links from forcing min-content sizing in the user
   column. These actions remain clickable and their markup is not altered. */
body.rk-v3.pg_viewthread #postlist .pls .favatar p,
body.rk-v3.pg_viewthread #postlist .pls .favatar li,
body.rk-v3.pg_viewthread #postlist .pls .favatar .pil {
  max-width:100%;
  overflow-wrap:anywhere;
}

@media(max-width:760px) {
  body.rk-v3.pg_viewthread #postlist table.plhin > tbody > tr > td.pls {
    width:68px!important;
    min-width:68px!important;
    max-width:68px!important;
  }
  body.rk-v3.pg_viewthread #postlist .pls .favatar {
    width:68px!important;
    max-width:68px!important;
    padding:5px 3px!important;
  }
}
