/* Desktop/tablet application lists use the remaining viewport height.
   Element Plus owns the internal table layout and scrollbars. */
@media (min-width: 769px) {
  :is(body.tac-page-my-applications, body.tac-page-pending-approvals) .layout > .el-container {
    height: 100dvh !important;
  }

  :is(body.tac-page-my-applications, body.tac-page-pending-approvals) .main {
    overflow: hidden;
  }

  body.tac-page-pending-approvals .main > .pending-approvals-owned {
    display: flex;
    flex: 1 1 auto;
    height: 100%;
    min-height: 0;
  }

  body.tac-page-my-applications .main > .el-card,
  body.tac-page-pending-approvals .main > .pending-approvals-owned > .el-card {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    height: 100%;
    min-height: 0;
  }

  body.tac-page-my-applications .main > .el-card > .el-card__header,
  body.tac-page-pending-approvals .main > .pending-approvals-owned > .el-card > .el-card__header {
    flex: 0 0 auto;
  }

  body.tac-page-my-applications .main > .el-card > .el-card__body,
  body.tac-page-pending-approvals .main > .pending-approvals-owned > .el-card > .el-card__body {
    display: flex;
    flex: 1 1 auto;
    min-height: 0;
    flex-direction: column;
    overflow: hidden;
  }

  body.tac-page-my-applications .main > .el-card > .el-card__body > .el-table,
  body.tac-page-pending-approvals .main > .pending-approvals-owned > .el-card > .el-card__body > .el-table {
    flex: 1 1 auto;
    height: 100% !important;
    min-height: 0;
  }
}

/* Keep the action column visible without horizontal scrolling. */
body.tac-page-my-applications .el-table__header-wrapper th:last-child,
body.tac-page-my-applications .el-table__body-wrapper td:last-child {
  position: sticky;
  right: 0;
}

body.tac-page-my-applications .el-table__header-wrapper th:last-child {
  z-index: 4;
  background: var(--el-table-header-bg-color, #f5f7fa);
  box-shadow: -7px 0 10px -10px rgba(31, 61, 91, .55);
}

body.tac-page-my-applications .el-table__body-wrapper td:last-child {
  z-index: 3;
  background: var(--el-bg-color, #fff);
  box-shadow: -7px 0 10px -10px rgba(31, 61, 91, .55);
}

body.tac-page-my-applications .el-table__body tr.el-table__row--striped td:last-child {
  background: var(--el-fill-color-lighter, #fafafa);
}

body.tac-page-my-applications .el-table__body tr:hover > td:last-child {
  background: var(--el-table-row-hover-bg-color, #f5f7fa);
}
