/* ###########################################################################
   #  This file provides style definitions for the page layout of all themes.
   ä  By default, themes only differ in colors defined in 'theme.css' or
   #  customized logos and icons stored in the theme's 'img' directory. Since
   #  the styles are shared throughout all themes, they must not be modified.
   #  However, selected styles defined in this file can be refined or amended
   #  locally in 'theme.css' or globally in 'siteprefs.css'.
   ###########################################################################
*/


/* #############################
   #  Globals
   #############################
*/

body {
  overflow: hidden;
  display: flex;
  flex-flow: column;
  width: 100vw;         /* required to achieve a horizontal flexbox overflow */
  height: 100svh;       /* required to achieve a vertical flexbox overflow, svh required for mobile */
  margin: 0px;
  padding: 0px;
  background: var(--body-background-color);
  color: var(--body-color);
  font-size: var(--text-font-size);
  font-family: Verdana, Arial, Helvetica, sans-serif;
}

table {
  margin: 0px;
  font-size: var(--text-font-size);
  font-family: inherit;
}

tr, td {
}

form {
}

input, textarea {
  margin: 0px;
  background: var(--input-background-color);
  border: var(--input-border-width) var(--input-border-style) var(--input-border-color);
  color: var(--input-color);
  font-size: var(--text-font-size);
  font-family: inherit;
}

select {
  background: var(--input-background-color);
  border: var(--input-border-width) var(--input-border-style) var(--input-border-color);
  color: var(--input-color);
  font-size: var(--text-font-size);
  font-family: inherit;
}

input[type=radio] {
  height: var(--text-font-size);
  width: var(--text-font-size);
  accent-color: var(--input-accent-color);
}

input[type=checkbox] {
  height: var(--text-font-size);
  width: var(--text-font-size);
  accent-color: var(--input-accent-color);
}

input[type=checkbox]:checked {
  accent-color: var(--input-accent-color);
}

input.width99, textarea.width99 {
  width: 99%;
}

a {
  color: var(--body-link-color);
}

svg a:hover {
  cursor: pointer;
  opacity: 0.6;
}


img.sdhd {
  width: var(--sdhd-width, 24px);
}

img.iconic {
  width: var(--iconic-button-width, 16px);
  height: var(--iconic-button-height, 16px);
}

img.icon {
  width: var(--icon-width, 16px);
  height: var(--icon-height, 16px);
}

img.fading {
  animation: desaturating 2s alternate infinite running;
}

img.icon.button {
  cursor: default;
  background: transparent url(../img/icon_regular.svg) no-repeat top right;
  background-size: var(--icon-width, 16px) var(--icon-height, 16px);
}

img.icon.button:hover {
  background: transparent url(../img/icon_regular_hovered.svg) no-repeat top right;
  background-size: var(--icon-width, 16px) var(--icon-height, 16px);
}

img.recording_folder {
}

a {
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

a:active {
  text-decoration: underline;
}


/* #############################
   #  Global style properties
   #############################
*/

div.boxheader .caption {
  overflow: hidden;
  text-overflow: ellipsis;
}

.bold {
  font-weight: bold;
}

.options {
  /* flexbox for list of 'dotted' options */
  display: flex;
  flex-flow: row wrap;
  gap: var(--text-line-gap) var(--margin-left-right);
  margin: var(--text-line-gap) 0px;
}

.options > .first {
  /* shift flexbox item to the start of the sequence */
  order: -1;
}

.dotted {
  padding: var(--text-line-gap) var(--margin-left-right);
  background: var(--input-background-color);
  border: var(--input-accent-border-width) var(--input-accent-border-style) var(--input-border-color);
  color: var(--input-color);
}

input ~ div.selection {
  margin-left: var(--margin-left-right);
  margin-right: var(--margin-left-right);
}

div.selection {
  display: inline-block;
}

.title {
  font-weight: bold;
}

.short {
  font-weight: normal;
}

.normal-font {
  font-weight: normal;
}

.bold-font {
  font-weight: bold;
}

.margin-bottom {
  margin-bottom: var(--margin-top-bottom);
}

.more {
  font-weight: bold;
}

.withmargin {
  margin: var(--margin-top-bottom) var(--margin-left-right);
}

div.whatson_info .withmargin {
  margin: var(--margin-top-bottom) 0px;
}

.nomargin {
  margin: 0px;
}

.notpresent {
  display: none;
}

/* allow long reg-ex patterns without spaces/hyphens to break at any character */
.searchtimer {
  word-break: break-word;
}

@-moz-document url-prefix() {

  /* as Firefox also breaks at punctuation marks */
  .searchtimer {
    word-break: normal;
  }

}

.remotetimer {
}

.nowrap {
  white-space: nowrap;
}

.sep {
  font-weight: normal;
}


/* #############################
   #  Scraper styles
   #############################
*/

.scraper_list {
  margin: var(--text-block-gap) 0px;
}

div.cast_crew.tabular {
  display: grid;
  grid-template-columns: auto auto;
  width: fit-content;
  gap: var(--text-line-gap) var(--margin-left-right);
}


/* #############################
   #  Tooltip style for hints
   #############################
*/

.hint-tip {
  max-width: calc(min(var(--popup-width), 40vw));
  margin: 0px auto;
  background: var(--hint-popup-background-color);
  border: var(--popup-border-width) solid var(--hint-popup-border-color);
  border-radius: var(--popup-border-radius);
  box-shadow: var(--popup-shadow-offset) var(--popup-shadow-offset) var(--popup-shadow-blur) var(--popup-shadow-spread) var(--hint-popup-shadow-color);
  color: var(--hint-popup-color);
}

.hint-tip hr {
  color: var(--hint-popup-color);
}

.hint-title {
  display: none;
}

.hint-tip-body {
  margin: var(--popup-body-margin);
}

.hint-tip-body p {
  margin: var(--text-line-gap) 0px;
}

.hint-tip-body p.click-action:not(:first-child),
.hint-tip-body p.click-details:not(:first-child) {
  padding-top: var(--text-block-gap);
}



/* ########################################
   #  Style for positive notification popup
   ########################################
*/

.ok-info {
  max-width: calc(min(var(--popup-width), 60vw));
  margin: 0px auto;
  background: var(--ok-popup-background-color);
  border: var(--popup-border-width) solid var(--ok-popup-border-color);
  border-radius: var(--popup-border-radius);
  box-shadow: var(--popup-shadow-offset) var(--popup-shadow-offset) var(--popup-shadow-blur) var(--popup-shadow-spread) var(--ok-popup-shadow-color);
  color: var(--ok-popup-color);
}

.ok-info-title {
  display: none;
}

.ok-info-body {
  display: flex;
  column-gap: var(--icon-column-gap);
  align-items: center;
  margin: var(--popup-body-margin);
}

.ok-info-body p {
  margin: var(--text-line-gap) 0px;
}


/* ########################################
   #  Style for negative notification popup
   ########################################
*/

.err-info {
  max-width: calc(min(var(--popup-width), 60vw));
  margin: 0px auto;
  background: var(--error-popup-background-color);
  border: var(--popup-border-width) solid var(--error-popup-border-color);
  border-radius: var(--popup-border-radius);
  box-shadow: var(--popup-shadow-offset) var(--popup-shadow-offset) var(--popup-shadow-blur) var(--popup-shadow-spread) var(--error-popup-shadow-color);
  color: var(--error-popup-color);
}

.ok-info-title {
  display: none;
}

.err-info-body {
  display: flex;
  column-gap: var(--icon-column-gap);
  align-items: center;
  margin: var(--popup-body-margin);
}

.err-info-body p {
  margin: var(--text-line-gap) 0px;
}


/* ##############################
   #  General styles for EPG info
   ##############################
*/

div.epg_content {
}

span.epg_images {
  float: right;
  width: var(--epg-image-width);
  margin-left: var(--margin-left-right);
}

img.actor {
  width: var(--epg-photo-width);
}

img.artwork {
  width: var(--epg-artwork-width);
}

span.channel_id {
  width: 6ch;
  display: inline-block;
  text-align: right;
}

img.channel_logo {
  max-width: var(--logo-image-width);
  max-height: var(--logo-image-height);
  vertical-align: middle;
}


/* ##############################
   #  InfoWin styles for EPG info
   ##############################
*/

div.info-win {
  overflow: hidden;       /* to get the resize handle */
  width: calc(var(--sdhd-width) + var(--infowin-tools-border-width) + 6 * var(--margin-left-right) + max(var(--epg-image-width), 4 * var(--epg-photo-width) + 3 * var(--margin-left-right), var(--epg-artwork-width)) + 15px /* for the scrollbar */);
  min-width: calc(var(--sdhd-width) + var(--infowin-tools-border-width) + 6 * var(--margin-left-right) + max(var(--infowin-progressbar-width) + 2 * var(--infowin-progressbar-border-width), var(--epg-image-width)) + 15px /* for the scrollbar */);
  max-width: 80vw;
  min-height: calc(var(--infowin-title-height) + 5 * var(--text-line-height));
  margin: 0px auto;
  border-top-left-radius: var(--infowin-title-border-radius);
  border-top-right-radius: var(--infowin-title-border-radius);
  border-bottom: var(--infowin-border-width) solid var(--infowin-border-color);
  box-shadow: var(--infowin-shadow-offset) var(--infowin-shadow-offset) var(--infowin-shadow-blur) var(--infowin-shadow-spread) var(--infowin-shadow-color);
}

div.info-win.aboutBox {
  min-width: calc(3 * var(--margin-left-right) + 2 * var(--margin-left-right) + 2 * var(--infowin-label-width) + 15px );
}

div.info-win.rcKeys {
  width: calc(3 * var(--margin-left-right) + 2 * var(--margin-left-right) + 2 * var(--infowin-label-width) + 15px );
  min-width: calc(3 * var(--margin-left-right) + 2 * var(--margin-left-right) + 2 * var(--infowin-label-width) + 15px );
}

div.info-win {
  --confirmation-title-bar-height: calc(var(--infowin-title-height) + 2 * var(--text-line-gap));
  --confirmation-prompt-height: calc(2 * var(--infowin-border-width) + 2 * var(--margin-top-bottom) + 1lh);
  --confirmation-list-height: calc(var(--margin-top-bottom) + 2 * var(--text-line-gap) + 2lh);
  --confirmation-warning-height: calc(var(--margin-top-bottom) + 1lh);
  --confirmation-label-height: calc(var(--margin-top-bottom) + 1lh);
  --confirmation-form-height: calc(8 * var(--margin-top-bottom) + var(--infowin-border-width) + var(--button-height));
}

div.info-win.info-del,
div.info-win.info-des,
div.info-win.info-det,
div.info-win.info-pur,
div.info-win.info-res {
  min-width: calc(3 * var(--margin-left-right) + 2 * var(--infowin-body-margin) + 2 * var(--infowin-label-width) + 15px );
  min-height: calc(var(--confirmation-title-bar-height) + var(--confirmation-prompt-height) + var(--confirmation-label-height) + var(--confirmation-form-height));
}

div.info-win.info-pur {
  min-height: calc(var(--confirmation-title-bar-height) + var(--confirmation-prompt-height) + var(--confirmation-warning-height) + var(--confirmation-label-height) + var(--confirmation-form-height));
}

div.info-win.info-del:has(.object-list),
div.info-win.info-des:has(.object-list),
div.info-win.info-det:has(.object-list),
div.info-win.info-pur:has(.object-list),
div.info-win.info-res:has(.object-list) {
  min-height: calc(var(--confirmation-title-bar-height) + var(--confirmation-prompt-height) + var(--confirmation-list-height) + var(--confirmation-label-height) + var(--confirmation-form-height));
  max-height: 70svh;
}

div.info-win.info-pur:has(.object-list) {
  min-height: calc(var(--confirmation-title-bar-height) + var(--confirmation-prompt-height) + var(--confirmation-list-height) + var(--confirmation-warning-height) + var(--confirmation-label-height) + var(--confirmation-form-height));
}

div.info-win.info-del:not(:has(.label)),
div.info-win.info-des:not(:has(.label)),
div.info-win.info-det:not(:has(.label)),
div.info-win.info-pur:not(:has(.label)),
div.info-win.info-res:not(:has(.label)) {
  min-height: calc(var(--confirmation-title-bar-height) + var(--confirmation-prompt-height) + var(--confirmation-form-height));
}


.info-win .info-win-top {
  display: flex;
  justify-content: space-between;
  overflow: hidden;
  min-height: calc(var(--infowin-title-height) + 2 * var(--text-line-gap));
  background-image: linear-gradient(to bottom, var(--infowin-title-background-color-top), var(--infowin-title-background-color-middle) calc(var(--infowin-title-height) / 2), var(--infowin-title-background-color-bottom) var(--infowin-title-height));
  background-origin: border-box;
  border: var(--infowin-border-width) solid var(--infowin-title-border-color);
  border-top-left-radius: var(--infowin-title-border-radius);
  border-top-right-radius: var(--infowin-title-border-radius);
  border-bottom: none;
}

.info-win .info-win-top .info-win-title {
  display: flex;
  align-items: center;
  min-height: var(--infowin-title-height);
  padding: var(--text-line-gap) calc(calc(max(var(--icon-width) + 2 * var(--margin-left-right), var(--sdhd-width) + 2 * round(up, var(--margin-left-right) / 2, 1px)) - var(--icon-width)) / 2);
  color: var(--infowin-title-color);
  font-weight: bold;
  line-height: var(--text-line-height);
}

.info-win .info-win-top .info-win-title .caption a.inactive {
  cursor: pointer;
  color: inherit;
  list-style: inherit;
  font-weight: inherit;
}

.info-win .info-win-top .info-win-title .caption a.active {
  cursor: pointer;
  color: var(--menu-color-highlight);
  list-style: inherit;
  font-weight: inherit;
}

.info-win .info-win-top .info-win-buttons {
  display: flex;
  flex-flow: row nowrap;
  column-gap: var(--iconic-button-column-gap);
  align-items: start;
  max-width: calc(2 * var(--iconic-button-width)+ var(--iconic-button-column-gap));
  margin-top: calc(0px - min(max(round(down, max(calc(var(--text-font-size) - 22px) / 3), 1px), -3px), 0px));
  margin-right: var(--margin-left-right);
}

img.iconic.button.recording-expander, /* for the tree view */
.info-win .info-win-top img.iconic.button {
  cursor: default;
  background: transparent url(../img/icon_small.svg) no-repeat top right;
  background-size: var(--iconic-button-width, 16px) var(--iconic-button-height, 16px);
}

img.iconic.button.recording-select-all, /* for the tree view */
.info-win .info-win-top img.iconic.button {
  cursor: default;
  background: transparent url(../img/icon_small.svg) no-repeat top right;
  background-size: var(--iconic-button-width, 16px) var(--iconic-button-height, 16px);
}

img.iconic.button.recording-deselect-all, /* for the tree view */
.info-win .info-win-top img.iconic.button {
  cursor: default;
  background: transparent url(../img/icon_small.svg) no-repeat top right;
  background-size: var(--iconic-button-width, 16px) var(--iconic-button-height, 16px);
}

img.iconic.button.recording-select-all,
img.iconic.button.recording-deselect-all {
  object-position: calc(2 * var(--iconic-button-width, 16px))  calc(2 * var(--iconic-button-height, 16px));
}

img.iconic.button.recording-select-all.operational,
img.iconic.button.recording-deselect-all.operational {
  object-position: unset;
}

img.iconic.button.recording-expander:hover, /* for the tree view */
.info-win .info-win-top img.iconic.button:hover {
  background: transparent url(../img/icon_small_hovered.svg) no-repeat top right;
  background-size: var(--iconic-button-width, 16px) var(--iconic-button-height, 16px);
}

img.iconic.button.recording-select-all:hover, /* for the tree view */
img.iconic.button.recording-deselect-all:hover {
  background: transparent url(../img/icon_small.svg) no-repeat top right;
  background-size: var(--iconic-button-width, 16px) var(--iconic-button-height, 16px);
}

img.iconic.button.recording-select-all.operational:hover, /* for the tree view */
img.iconic.button.recording-deselect-all.operational:hover {
  background: transparent url(../img/icon_small_hovered.svg) no-repeat top right;
  background-size: var(--iconic-button-width, 16px) var(--iconic-button-height, 16px);
}

.info-win .info-win-body {
  display: flex;
  /* when resized, the body extends to the window height; we thus
  ** reduce the body height by the height of an unwrapped title and
  ** accept that wrapped titles won't allow scrolling down fully */
  height: calc(100% - var(--infowin-border-width) - var(--text-line-height) - 2 * var(--text-line-gap));
  min-height: calc(5 * var(--text-line-height) - var(--infowin-border-width) - 2 * var(--text-line-gap));
  max-height: inherit;  /* for enabling the scrollbar */
  border: var(--infowin-border-width) solid var(--infowin-border-color);
  border-top: none;
  border-bottom: none;
}

.info-win.info-del .info-win-body,
.info-win.info-des .info-win-body,
.info-win.info-det .info-win-body,
.info-win.info-pur .info-win-body,
.info-win.info-res .info-win-body {
  min-height: unset;    /* let the buttons control the height */
}

.info-win .info-win-resize {
  display: none;
}

@supports (resize: both) {

  div.info-win {
    resize: both;
  }

  div.info-win div.info-win-resize {
  }

}

@supports not (resize: both) {

  div.info-win {
    position: relative;
  }

  div.info-win div.info-win-resize {
    cursor: nwse-resize;
    display: block;
    position: absolute;
    right: 1px;
    bottom: 0px;
    width: var(--icon-width);
    height: var(--icon-height);
    margin-right: var(--infowin-border-width);
    margin-bottom: var(--infowin-border-width);
    background: transparent;
  }

}


/* #############################
   #  Styles for page layout
   #############################
*/

div#header {
}

div#navigation {
  margin-bottom: var(--menubar-gap);
}

div#navigation:has(div#pagemenu) {
  margin-bottom: 0px;
}

div.page_header {
  --infobox-st-header-height: calc(2 * var(--infobox-border-width) + 2 * var(--text-line-gap) + max(1lh, var(--infobox-header-height)));
  --infobox-st-content-height: calc(2 * var(--infobox-margin) + 1lh);
  --infobox-st-control-height: calc(2 * var(--infobox-margin) + var(--icon-height, 16px) + var(--infobox-border-width));
  --vdr-logo-height: calc(var(--infobox-st-header-height) + var(--infobox-st-content-height) + var(--infobox-st-control-height) + 2 * var(--margin-top-bottom));
  --vdr-logo-width: calc(var(--vdr-logo-image-width) / var(--vdr-logo-image-height) * var(--vdr-logo-height));
  --vdr-logo-small-width: calc(0.5px * var(--vdr-logo-image-width));
  display: flex;
  flex-flow: row;
  align-items: flex-start;
  gap: var(--margin-top-bottom) var(--page-header-gap);
  margin: 0px var(--body-margin);
}


/* #############################
   #  Styles for menu
   #############################
*/

div#menu {
}

div#menu div.menubar {
  display: flex;
  align-items: center;
  min-height: var(--menu-height);
  padding: 0px var(--body-margin) 2px var(--body-margin);
  background: linear-gradient(to bottom, var(--menu-background-color-top), var(--menu-background-color-middle) calc(var(--menu-height) / 2), var(--menu-background-color-bottom) var(--menu-height), var(--menu-background-color-bottom));
  border-top: var(--menu-border-width) solid var(--menu-border-color);
  border-bottom: var(--menu-border-width) solid var(--menu-border-color);
}

div#menu div.menubar div.choices {
  color: var(--menu-color);
  line-height: var(--text-line-height);
}

div#menu .inactive {
  color: var(--menu-color-inactive);
  font-weight: bold;
  white-space: nowrap;
}

div#menu a {
  color: var(--menu-color);
  font-weight: bold;
  white-space: nowrap;
}

div#menu a#login {
  color: var(--menu-color-login);
}

div#menu a.active {
  color: var(--menu-color-highlight);
  font-weight: bold;
}

div#content {
  flex-grow: 1;
  position: relative;
  overflow: auto;
  padding: 0px var(--body-margin);
}

div#content:not(:has(table.multischedule)) {
  overflow-x: inherit;  /* could also be set to 'hidden' */
}

div#content > div.spacebar {
  bottom: 0px;
  position: sticky;
  height: var(--spacebar-height);
  width: calc(100vw - 2 * var(--body-margin));
  background: transparent linear-gradient(to top, var(--body-background-color), transparent);
}

div#content > div.spacebar:first-of-type {
  top: 0px;
  position: sticky;
  height: var(--spacebar-height);
  width: calc(100vw - 2 * var(--body-margin));
  background: transparent linear-gradient(to bottom, var(--body-background-color), transparent);
}


/* #############################
   #  Styles for messagebar
   #############################
*/

div#messagebar {
  clear: both;
}

div#messagebar div.menubar {
  display: flex;
  align-items: center;
  min-height: var(--messagebar-height);
  margin-top: var(--menubar-gap);
  padding: 0px var(--body-margin);
  background: linear-gradient(to bottom, var(--messagebar-background-color-top), var(--messagebar-background-color-middle) calc(var(--messagebar-height) / 2), var(--messagebar-background-color-bottom) var(--messagebar-height), var(--messagebar-background-color-bottom));
  border-top: var(--messagebar-border-width) solid var(--messagebar-border-color);
  border-bottom: var(--messagebar-border-width) solid var(--messagebar-border-color);
}

div#messagebar div.menubar div.choices {
  color: var(--messagebar-color);
  line-height: var(--text-line-height);
}

div#messagebar a {
  color: var(--messagebar-color);
  font-weight: bold;
}

div#messagebar a.active {
  color: var(--messagebar-color-highlight);
  font-weight: bold;
}

div#messagebar span#mbmessage {
  padding: 0em 1em;
  color: var(--messagebar-color-message);
  font-weight: bold;
}


/* #############################
   #  Styles for pagemenu
   #############################
*/

div#pagemenu {
  clear: both;
}

div#pagemenu div.top {
  height: var(--menubar-gap);
  background: linear-gradient(to bottom, transparent calc(var(--menubar-gap) - var(--pagemenu-shadow-height)), var(--pagemenu-background-color));
}

div#pagemenu div.menubar {
  display: flex;
  align-items: center;
  min-height: var(--pagemenu-height);
  padding: 0px var(--body-margin);
  background: var(--pagemenu-background-color);
  border-top: var(--pagemenu-border-width) solid var(--pagemenu-border-color);
  border-bottom: var(--pagemenu-border-width) solid var(--pagemenu-border-color);
}

div#pagemenu div.menubar div.choices {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  column-gap: var(--margin-left-right);
  padding: var(--margin-top-bottom) 0px;
  color: var(--pagemenu-color);
  line-height: var(--text-line-height);
}

div#pagemenu div.menubar .inactive {
  color: var(--menu-color-inactive);
  font-weight: bold;
  white-space: nowrap;
}

div#pagemenu div.menubar .label {
  white-space: nowrap;
}

div#pagemenu div.menubar .tools,
div#pagemenu div.menubar .with-tools {
  display: inline-flex;
  align-items: center;
  column-gap: var(--margin-left-right);
}

div#pagemenu div.bottom {
  height: var(--menubar-gap);
  background: transparent linear-gradient(to bottom, var(--pagemenu-background-color), transparent var(--pagemenu-shadow-height));
}

div#pagemenu form {
  display: inline;
}

div#pagemenu form#remoteActions input {
  margin-left: var(--margin-left-right);
}

div#pagemenu span.tools {
  line-height: 0lh
}

div#pagemenu a {
  color: var(--pagemenu-color);
  font-weight: bold;
  white-space: nowrap;
}

div#pagemenu a.active {
  color: var(--pagemenu-color-highlight);
  font-weight: bold;
}


/* #############################
   #  Info box (near logo)
   #############################
*/

div#logo {
  overflow: visible;
}

div#logo img.logo {
  display: block;
  height: var(--vdr-logo-height);
}

div#infobox {
  min-width: calc(600px - 2 * var(--body-margin));
  margin: var(--margin-top-bottom) 0px;
}

div#infobox.with-logo {
  min-width: calc(600px - 2 * var(--body-margin) - var(--page-header-gap) - var(--vdr-logo-width));
  max-width: calc(100vw - 2 * var(--body-margin) - var(--page-header-gap) - var(--vdr-logo-width));
}

div#infobox div.statuscontent {
}

div#infobox div.st_header {
  display: flex;
  overflow: hidden;
  min-height: var(--infobox-header-height);
  padding: var(--text-line-gap) var(--infobox-margin);
  background: var(--infobox-header-background-color);
  border: var(--infobox-border-width) solid var(--infobox-border-color);
  border-top-left-radius: var(--infobox-border-radius);
  border-top-right-radius: var(--infobox-border-radius);
  border-bottom: var(--infobox-header-border-width) solid var(--infobox-header-border-color);
  color: var(--infobox-header-color);
}

div#infobox div.st_header div.now {
  margin: auto 0px auto auto;
}

div#infobox div.st_header div.caption {
  overflow: hidden;
  margin: auto 0px;
  padding: 0px;
  font-weight: bold;
}

div#infobox div.st_content {
  display: flex;
  justify-content: space-between;
  overflow: hidden;
  background: linear-gradient(to bottom, var(--infobox-header-background-color), var(--infobox-background-color) var(--infobox-header-background-gradient-height));
  border: var(--infobox-border-width) solid var(--infobox-border-color);
  border-top: none;
  border-bottom: none;
  color: var(--infobox-color);
}

div#infobox div.st_content div.name {
  overflow: hidden;
  padding: var(--infobox-margin);
  font-weight: bold;
}

div#infobox div.st_content div.duration {
  padding: var(--infobox-margin);
  padding-left: 2em;
}

div#infobox div.st_controls {
  display: flex;
  align-items: center;
  overflow: hidden;
  padding: var(--infobox-margin);
  background: var(--infobox-background-color);
  border: var(--infobox-border-width) solid var(--infobox-border-color);
  border-top: none;
  border-bottom-left-radius: var(--infobox-border-radius);
  border-bottom-right-radius: var(--infobox-border-radius);
}

div#infobox div.st_controls a {
  /* to avoid extra space beneath the icons */
  vertical-align: top;
  line-height: 0px;
}

div#infobox div.st_controls div.st_pbar {
  margin-left: auto;
}

div#infobox div.__progress {
  overflow: hidden;
  width: var(--infobox-progressbar-width);
  height: var(--infobox-progressbar-height);
  background: var(--infobox-progressbar-background-color);
  border: var(--infobox-progressbar-border-width) solid var(--infobox-progressbar-border-color);
}

div#infobox div.__progress_invisible {
  overflow: hidden;
  width: var(--infobox-progressbar-width);
  height: var(--infobox-progressbar-height);
  background: transparent;
  border: 0px none transparent;
}

div#infobox div.__progress div.__elapsed {
  height: var(--infobox-progressbar-height);
  background: var(--infobox-progressbar-elapsed-color);
}

div#infobox div.st_controls div.st_update {
  padding-right: var(--infobox-margin);
  border-right: var(--infobox-header-border-width) solid var(--infobox-header-border-color);
}

div#infobox div.st_controls div#infobox_recording_buttons {
  padding-left: var(--infobox-margin);
}

div#infobox div.st_controls div#infobox_channel_buttons {
  padding-left: var(--infobox-margin);
}


/* #############################
   #  Buttons
   #############################
*/

button {
  cursor: pointer;
  display: inline-flex;
  flex-flow: column;
  justify-content: center;
  align-items: center;
  height: fit-content;
  min-width: var(--button-width);
  min-height: var(--button-height);
  padding: 0.2ex 0.4ch 0.3ex 0.4ch;
  font-size: var(--text-font-size);
  text-align: center;
}

.tabular button {
  height: 100%;
}

button:hover {
  font-weight: bold;
}

button.login {
  background: linear-gradient(to bottom, var(--button-login-background-color-top) var(--button-border-gradient-top), var(--button-login-background-color-middle) var(--button-border-gradient-middle), var(--button-login-background-color-middle));
  border: var(--button-border-width) var(--button-border-style) var(--button-login-border-color);
  border-radius: var(--button-border-radius);
  color: var(--button-login-color);
}

button.green {
  background: linear-gradient(to bottom, var(--button-green-background-color-top) var(--button-border-gradient-top), var(--button-green-background-color-middle) var(--button-border-gradient-middle), var(--button-green-background-color-middle));
  border: var(--button-border-width) var(--button-border-style) var(--button-green-border-color);
  border-radius: var(--button-border-radius);
  color: var(--button-green-color);
}

button.red {
  background: linear-gradient(to bottom, var(--button-red-background-color-top) var(--button-border-gradient-top), var(--button-red-background-color-middle) var(--button-border-gradient-middle), var(--button-red-background-color-middle));
  border: var(--button-border-width) var(--button-border-style) var(--button-red-border-color);
  border-radius: var(--button-border-radius);
  color: var(--button-red-color);
}

button.blue {
  background: linear-gradient(to bottom, var(--button-blue-background-color-top) var(--button-border-gradient-top), var(--button-blue-background-color-middle) var(--button-border-gradient-middle), var(--button-blue-background-color-middle));
  border: var(--button-border-width) var(--button-border-style) var(--button-blue-border-color);
  border-radius: var(--button-border-radius);
  color: var(--button-blue-color);
}

button.yellow {
  background: linear-gradient(to bottom, var(--button-yellow-background-color-top) var(--button-border-gradient-top), var(--button-yellow-background-color-middle) var(--button-border-gradient-middle), var(--button-yellow-background-color-middle));
  border: var(--button-border-width) var(--button-border-style) var(--button-yellow-border-color);
  border-radius: var(--button-border-radius);
  color: var(--button-yellow-color);
}

#form_recordings > div.withmargin {
  margin-left: 0px;
}

#form_recordings div.button-panel div.buttons button.delete {
  min-width: calc(var(--button-width) * 2.0);
}

#form_recordings div.button-panel div.buttons button.restore,
#form_recordings div.button-panel div.buttons button.purge {
  min-width: calc(var(--button-width) * 2.5);
}


/* #############################
   #  General table-cell classes
   #############################
*/

table td.buttonpanel {
  text-align: right;
}

table td.toprow {
}

table td.bottomrow,
table.multischedule > tbody > tr:last-of-type > td.time,
table.multischedule > tbody > tr:last-of-type > td.event,
table.form > tbody > tr:last-of-type > td {
  border-bottom: var(--listing-border-width) solid var(--listing-border-color) !important;
}

table td.leftcol {
  border-left: var(--listing-border-width) solid var(--listing-border-color);
}

table td.rightcol {
  border-right: var(--listing-border-width) solid var(--listing-border-color);
}

table td.topaligned {
  vertical-align: top;
}

table td.cast_role {
  font-weight: bold;
  text-align: left;
}


/* ##############################
   #  Event (page: whats_on.html)
   ##############################
*/

table.listing.whats_on > tbody > tr > td.rightcol {
  min-width: 0px;       /* to have channel images right-aligned at the border */
}

div.event_collection {
  display: flex;
  flex-flow: row wrap;
  gap: calc(2 * var(--margin-top-bottom)) var(--margin-left-right);
}

div.event {
  width: 255px;
  height: 255px;
}

div.event div.station {
  width: 255px;
}

div.event div.title a {
  /* potentially unused */
  color: var(--listing-color);
  background: yellow;
}

div.station {
  min-width: calc(8ch + 40px);
}

div.station a, th.channel a, td.channel a {
  color: var(--infowin-title-color);
  font-weight: bold;
}

td div.station {
}

td div.station a {
  color: var(--listing-color);
  font-weight: bold;
}

div.event div.boxheader .caption {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

div.content {
  display: flex;
  overflow: hidden;
  width: 253px;
  height: 229px;
  margin: 0px;
  padding: 0px;
  border: var(--listing-border-width) solid var(--listing-border-color);
  border-top: none;
}

div.content div.tools {
  display: flex;
  flex-flow: column;
  align-items: center;
  gap: var(--icon-row-gap) var(--icon-column-gap);
  min-width: calc(var(--icon-width) + 2 * var(--margin-left-right));
  padding: var(--margin-top-bottom) 0px;
  background: var(--infowin-tools-background-color);
  border-right: var(--infowin-border-width) solid var(--infowin-tools-border-color);
  line-height: 0px;
}

div.content div.whatson_info {
  width: 100%;
  padding: var(--margin-top-bottom) var(--margin-left-right);
  background: transparent linear-gradient(to right, var(--infowin-tools-background-color), transparent 5px);
}

div.description {
  overflow: hidden;
  margin-top: var(--text-block-gap);
}

div.description p {
  margin: var(--text-line-gap) 0px 0px 0px;
}

div.description p:first-child {
  margin: 0px;
}

div.description p.epg_event_info {
  margin-top: var(--text-block-gap);
}

div.title {
  margin-top: var(--text-block-gap);
}

div.short {
  margin-top: var(--text-line-gap);
}

div.info {
  padding-bottom: var(--text-line-gap);
}

div.epg_info div.info {
  overflow: auto;
  height: 100%;
  padding-bottom: var(--text-line-gap);
}

div.epg_info div.event_details,
div.whatson_info div.epg_details {
  display: flex;
  flex-flow: row wrap;
  justify-content: space-between;
}

div.epg_info div.event_details {
  gap: 0px calc(2 * var(--margin-left-right));
}

div.whatson_info div.info {
  display: flex;
  flex-flow: row;
}

div.whatson_info div.duration {
  margin-left: auto;
}

div.epg_info div.event_details div.time_channel{
  display: flex;
  flex-flow: column;
  padding-bottom: var(--text-line-gap);
}

div.info div.duration {
  margin-left: auto;
}

div.info div.time {
}

.margin_right {
  margin-right: var(--margin-left-right);
}

div.info div.date {
  padding: 0px;
}

div.progress {
  overflow: hidden;
  padding: var(--text-line-gap) 0px;
}

div.__progress {
  overflow: hidden;
  width: var(--infowin-progressbar-width);
  height: var(--infowin-progressbar-height);
  background: var(--infowin-progressbar-background-color);
  border: var(--infowin-progressbar-border-width) solid var(--infowin-progressbar-border-color);
}

div.__progress_invisible {
  overflow: hidden;
  width: var(--infowin-progressbar-width);
  height: var(--infowin-progressbar-height);
  background: transparent;
  border: 0px none transparent;
}

div.__progress div.__elapsed {
  height: var(--infowin-progressbar-height);
  background: var(--infowin-progressbar-elapsed-color);
}


/* #############################
   #  Table listing
   # (used in list tables)
   #############################
*/

table.listing {
  margin: 0px;
  padding: 0px;
  color: var(--listing-color);
}

table.listing > tbody > tr > td {
  background: linear-gradient(to top,var(--listing-row-background-color-bottom), var(--listing-row-background-color-top) var(--listing-row-background-gradient-height), var(--listing-row-background-color-top));
  border-bottom: var(--listing-border-width) solid var(--listing-row-border-color);
}

table.listing > tbody > tr > td.message {
  padding-left: var(--margin-left-right);
  padding-right: var(--margin-left-right);
  font-weight: bold;
}

table.listing > tbody > tr > td.leftcol {
  padding: var(--margin-top-bottom) var(--margin-left-right);
}

table.users > tbody > tr > td.leftcol {
  padding: 0px;
}

table.listing.schedule div.label,
table.streaming div.label {
  overflow: hidden;
  text-overflow: ellipsis;
}

table.listing.schedule div.recording_status,
table.streaming div.recording_status {
  display: flex;
  flex-flow: row;
  align-items: center;
  gap: var(--icon-row-gap) var(--icon-column-gap);
  line-height: 0px;     /* to keep the block as small as possible */
  padding-top: var(--margin-top-bottom);
}

table.streaming td :first-child:is(.recording_status) {
  padding-top: 0px;
}

table.listing > tbody > tr > td.leftcol div.event_actions {
  display: flex;
  flex-flow: row;
  gap: var(--icon-row-gap) var(--icon-column-gap);
  line-height: 0px;     /* to keep the block as small as possible */
}

table.listing > tbody > tr > td.rightcol div.event_actions,
table.listing > tbody > tr > td.rightcol div.user_actions {
  display: flex;
  flex-flow: row;
  justify-content: flex-end;
  gap: var(--icon-row-gap) var(--icon-column-gap);
  padding-right: var(--margin-left-right);
  padding-left: var(--margin-left-right);
  line-height: 0px;     /* to keep the block as small as possible */
}

.noborder {
  border-collapse: collapse;
  padding: 0px;
  margin: 0px;
}

table.listing tr td.current {
  /* check */
  background: var(--listing-row-background-color-highlight);
  color: var(--listing-color-highlight);
  background: yellow;
}

table.listing tr td.noborder {
  background: none;
  border-style: none;
}

table.listing > tbody > tr.head > td {
  background: none;
  border-bottom: none;
  color: var(--listing-header-color);
  font-weight: bold;
}

table.listing tr.description td {
  background: var(--listing-description-background-color);
  color: var(--listing-description-color);
  font-weight: bold;
}

table.listing tr.spacer td {
  height: var(--body-margin);
  background: transparent;
  border-bottom: 0px;
}

table.listing a {
  color: var(--listing-color);
  font-weight: bold;
}

table.listing .short a {
  font-weight: normal;
}

table.listing tr.active,
table.listing tr.active a {
  color: var(--listing-color-active);
}

table.listing tr.inactive,
table.listing tr.inactive a {
  color: var(--listing-color-inactive);
}

table.listing tr.recording,
table.listing tr.recording a {
  color: var(--listing-color-highlight);
}

table.listing tr td div.state_conflict {
  line-height: 0px;     /* to keep the block as small as possible */
}

table.listing tr td div.state {
  line-height: 0px;     /* to keep the block as small as possible */
  display: none;
}

table.listing tr.conflict div.state img,
table.listing tr.recording div.state img {
  animation: fading 2s alternate infinite running;
}

table.listing tr.account td.leftcol {
  min-width: var(--infowin-label-width);
}


/* #############################
   #  Table streaming
   # (used in browser streaming)
   #############################
*/

div.player-container {
  width: 100%;
  position: relative;  /* for the player inside of it */
  padding-top: 56.25%; /* 16:9 Aspect Ratio (divide 9 by 16 = 0.5625) */
  text-align: center;
}

div.player {
  position: absolute;
  top: 0px;
  left: 0px;
  bottom: 0px;
  right: 0px;
}

table.streaming {
  width: 100%;
  max-width: 1280px;
  margin: 2ex auto 0px auto;
  color: var(--listing-color);
  text-align: center;
}

table.streaming > tbody > tr > td {
  background: inherit;
  border: var(--listing-border-width) none transparent;
  border-left: var(--listing-border-width) solid var(--listing-row-border-color);
  padding: 0px var(--margin-left-right);
  vertical-align: top;
}

table.streaming > tbody > tr > td.leftcol {
  padding-top: 0px;
  padding-bottom: 0px;
  padding-left: 0px;
  border-left: var(--listing-border-width) none transparent;
}

table.streaming > tbody > tr > td.rightcol {
  width: 0px;
}

table.streaming > tbody > tr > td div.more {
  white-space: wrap;
}

table.streaming > tbody > tr > td.short {
  white-space: normal;
}

table.streaming > tbody > tr > td .recording_day {
  white-space: nowrap;
}

table.streaming > tbody > tr > td.more {
  width: 100%;
}

table.streaming .withmargin {
  margin: 0px;
}

table.streaming .progress {
  margin: 0px;
}


/* ##############################
   #  Table schedule
   # (used for the MultiSchedule)
   ##############################
*/

table.multischedule {
  margin: 0px;
  padding: 0px;
}

table.multischedule tr {
  height: var(--text-font-size);
}

table.multischedule tr.header {
}

table.form > tbody > tr.head > td,
table.listing > tbody > tr.head > td,
table.recordings-list > tbody > tr.head > td,
table.multischedule tr.header th,
div.event_collection div.event div.station {
  top: 0px;   /* required for stickiness */
  position: sticky;
  /*! height: inherit; */
  box-sizing: border-box;
}

table.multischedule tr.header th.time,
table.multischedule tr.header th.channel,
table.form > tbody > tr.head:first-of-type > td,
table.listing > tbody > tr.head:first-of-type > td,
table.recordings-list > tbody > tr.head > td,
div.event_collection div.event div.station {
  /* to avoid fragments of column borders aside sticky headers */
  background: var(--body-background-color);
}

@-moz-document url-prefix() {

  /* as Firefox has a different flexbox-height logic */
  table.multischedule tr.header th {
    height: 100%;
  }

}

table.multischedule tr.header th.time {
  padding: 0px;
}

table.multischedule tr.header th.time div.boxheader {
  text-align: center;
  justify-content: center;
}

table.multischedule tr.header th.spacer {
}

table.multischedule tr.header th.channel {
}

table.multischedule tr.header div.flexbox {
  display: flex;
  height: 100%;
}

table.multischedule tr.header div.boxheader {
  flex-wrap: wrap;
  column-gap: var(--icon-column-gap);
  width: 100%;
  height: 100%;
  box-sizing: border-box;
}

table.multischedule tr.header th .caption {
  overflow: hidden;
}

table.multischedule tr.header th .caption {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

table.multischedule th.time, table.multischedule th.spacer,
table.multischedule td.time, table.multischedule td.spacer {
  padding: var(--margin-top-bottom) var(--margin-left-right);
  text-align: center;
}

table.multischedule tr td.event,
table.multischedule > tbody > tr:last-of-type > td.time.even {
  background: linear-gradient(to top,var(--listing-row-background-color-bottom), var(--listing-row-background-color-top) var(--listing-row-background-gradient-height), var(--listing-row-background-color-top));
  border-bottom: var(--listing-border-width) solid var(--listing-row-border-color);
  vertical-align: top;
}

table.multischedule tr td.has_timer {
  background: linear-gradient(to top,var(--listing-row-background-color-bottom), var(--listing-row-background-color-active) var(--listing-row-background-gradient-height), var(--listing-row-background-color-active));
}

table.multischedule tr td.has_inactive_timer {
  background: linear-gradient(to top,var(--listing-row-background-color-bottom), var(--listing-row-background-color-inactive) var(--listing-row-background-gradient-height), var(--listing-row-background-color-inactive));
}

table.multischedule tr td.odd {
  background: var(--listing-row-background-color-odd);
}

table.multischedule tr td.even {
  background: var(--listing-row-background-color-even);
}

table.multischedule tr td.current_row {
  background: var(--listing-row-background-color-highlight);
}

table.multischedule tr td.leftcol {
  padding-left: var(--margin-left-right);
  padding-right: var(--margin-left-right);
}

table.multischedule th.channel,
table.multischedule td.channel,
table.multischedule div.content1 {
  min-width: 15em;
  max-width: 30em;
}

table.multischedule div.content1 > div {
  margin: var(--margin-top-bottom) 0px;
}

table.multischedule tr td div.title {
  clear: both;
}

table.multischedule tr td div.short {
  clear: both;
  overflow: hidden;
}

table.multischedule tr td div.description {
  clear: both;
  overflow: hidden;
}

table.multischedule a {
}

table.multischedule tr.header a > img.icon {
  vertical-align: text-bottom;
}


/* #############################
   #  Blue background thingy
   #############################
*/

div.boxheader {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--listing-header-height);
  padding: var(--text-line-gap) var(--margin-left-right);
  background-image: linear-gradient(to bottom, var(--infowin-title-background-color-top), var(--infowin-title-background-color-middle) calc(var(--infowin-title-height) / 2), var(--infowin-title-background-color-bottom) var(--infowin-title-height));
  background-origin: border-box;
  border: var(--infowin-border-width) solid var(--infowin-title-border-color);
  border-top-left-radius: var(--listing-header-border-radius);
  border-top-right-radius: var(--listing-header-border-radius);
  border-bottom: none;
  color: var(--infowin-title-color);
  font-weight: bold;
  line-height: var(--text-line-height);
  text-align: left;
}

table.listing div.boxheader, table.multischedule div.boxheader, div.data div.boxheader {
  background-image: linear-gradient(to bottom, var(--listing-header-background-color-top), var(--listing-header-background-color-middle) calc(var(--listing-header-height) / 2), var(--listing-header-background-color-bottom) var(--listing-header-height));
  border: var(--listing-border-width) solid var(--listing-header-border-color);
  border-bottom: none;
  color: var(--listing-header-color);
}


/* #############################
   #  Recordings
   #############################
*/

table.recordings-list {
  width: 100%;
}

div.recordings {
  border: var(--listing-border-width) solid var(--listing-border-color);
  border-top: none;
}

div.recordings .recordingslist {
  display: block;
}

div.recordings ul {
  margin: 0px;
  padding: 0px;
  list-style-type: none;
}

form div.recordings ul > li:last-of-type:has(> ul:is([style*="display: none"])) > div.recording_item  {
  /* discard row bottom border if last directory is collapsed */
  border-bottom: none;
 }

form div.recordings > ul > li:last-of-type tr.recording_item:last-child {
  /* discard row bottom border of last recording */
  border-bottom: none;
 }

/* 'div.recording_item' refers to a folder */

div.recording_item {
  overflow: hidden;
  background: linear-gradient(to top,var(--listing-row-background-color-bottom), var(--listing-row-background-color-top) var(--listing-row-background-gradient-height), var(--listing-row-background-color-top));
  border-bottom: var(--listing-border-width) solid var(--listing-row-border-color);
  color: var(--listing-color);
}

div.recording_item .recording_folder_name {
  cursor: pointer;
  font-weight: bold;
}

div.recording_item .recording_folder_name_new {
  cursor: pointer;
  color: var(--listing-color-highlight);
  font-weight: bold;
}

/* 'table.recordings' refers to the recordings within a folder */

table.recordings {
  width: 100%;
  border: 0px;
  border-spacing: 0px;
  border-collapse: collapse;
}

table.recordings a {
  color: var(--listing-color);
}

/* 'tr.recording_item' refers to a recording within a folder */

tr.recording_item {
  overflow: hidden;
  background: linear-gradient(to top,var(--listing-row-background-color-bottom), var(--listing-row-background-color-top) var(--listing-row-background-gradient-height), var(--listing-row-background-color-top));
  border-bottom: 1px solid var(--listing-row-border-color);
}

div.recordings > ul > li:last-of-type tr:has(td.message) {
  /* discard row bottom border of recording message */
  border-bottom: none;
}

tr.recording_item td.message {
  padding: var(--margin-top-bottom) var(--margin-left-right);
  color: var(--listing-color-highlight);
  font-weight: bold;
}

table.timerconflicts > tbody > tr > td.rightcol,
table.searchtimers > tbody > tr > td.rightcol:not(.message),
tr.recording_item td:last-child:not(.message) {
  width: 0px;   /* to keep column as small as possible */
  text-align: right;
}

tr.recording_item div.recording_info {
  margin: 0px var(--margin-left-right);
}

tr.recording_item div.recording_size {
  text-wrap: nowrap;
}

tr.recording_item div.recording_imgs {
  /* this needs visual fine-tuning for perfect alignment */
  margin: 2px var(--margin-left-right) 2px 3px;
  margin: var(--text-line-gap) var(--margin-left-right) var(--text-line-gap) 3px;
}

tr.recording_item.recording_new {
  /* move to 'siteprefs.css' if fully colored rows are undesired */
  color: var(--listing-color-highlight);
}

tr.recording_item.still_recording, tr.recording_item.still_recording a,
tr.existing_recording.still_recording, tr.existing_recording.still_recording a,
table.streaming tr.still_recording, table.streaming tr.still_recording a {
  /* move to 'siteprefs.css' if fully animated rows are undesired */
  color: var(--listing-color-highlight);
  animation: row-highlighting 2s alternate infinite running;
}

tr.recording_item div.recording_name_new, tr.recording_item div.recording_name_new a {
  color: var(--listing-color-highlight);
}

tr.existing_recording div.still_recording, tr.existing_recording div.still_recording a,
tr.recording_item div.recording_name.still_recording, tr.recording_item div.recording_name.still_recording a,
tr.recording_item div.recording_name_new.still_recording, tr.recording_item div.recording_name_new.still_recording a {
  color: var(--listing-color-highlight);
  animation: row-highlighting 2s alternate infinite running;
}

tr.recording_item div.recording_status {
  display: flex;
  flex-flow: column;
  align-items: center;
  /* the vertical distances need visual adjustment and can thus not be calculated */
  gap: 1px var(--icon-column-gap);
  margin-top: 1px;
}

tr.recording_item div.recording_actions {
  display: flex;
  flex-flow: row;
  justify-content: flex-end;
  gap: var(--icon-row-gap) var(--icon-column-gap);
  padding-left: var(--margin-left-right);
  padding-right: var(--margin-left-right);
  line-height: 0px;     /* to keep the block as small as possible */
}

tr.existing_recording div.recording_errors img.icon,
tr.recording_item div.recording_errors img.icon {
  width: var(--icon-width);
}

tr.existing_recording div.recording_sd_hd img.icon,
tr.recording_item div.recording_sd_hd img.icon {
  width: var(--sdhd-width);
}


/* #############################
   #  Remote control screenshot
   #############################
*/

/* for the time being, we keep the discrete dimensions, but they could become
** configurable; we even could think of making the screenshot frame resizable */

div#remote {
  display: flex;
  flex-flow: row wrap;
  gap: calc(4 * var(--margin-top-bottom)) calc(4 * var(--margin-left-right));
  padding: calc(2 * var(--margin-top-bottom)) 0px;
}

div#screenshot {
  --osd-screenshot-width: calc(var(--osd-screen-width) * var(--osd-screen-scale));
  --osd-screenshot-height: calc(var(--osd-screen-height) * var(--osd-screen-scale));
  width: var(--osd-screenshot-width);
  height: var(--osd-screenshot-height);
  padding: calc(var(--osd-screen-border-height) * var(--osd-screen-scale)) calc(var(--osd-screen-border-width) * var(--osd-screen-scale));
  padding-bottom: calc(calc(var(--osd-screen-border-height) + var(--osd-screen-base-height)) * var(--osd-screen-scale));
  background-image: url(../img/tv.svg);
  background-repeat: no-repeat;
  background-size: contain;
}

div#screenshot img {
  width: var(--osd-screenshot-width);
  height: var(--osd-screenshot-height);
  object-position: top left;
  object-fit: cover;
}

div#control svg {
  width: calc(var(--remote-control-width) * var(--remote-control-scale));
  height: calc(var(--remote-control-height) * var(--remote-control-scale));
  object-position: top left;
  object-fit: scale-down;
}


/* #############################
   #  Remote page - OSD
   #############################
*/

/* for the time being, we keep the discrete dimensions, but they could become
** configurable; we even could think of making the OSD frame resizable */

div#osd {
  /* the button width should result in four evenly-spaced buttons without fractional gap sizes */
  --osd-button-width: calc(calc(var(--osd-screenshot-width) - 2 * var(--margin-left-right) - 3 * var(--osd-button-gap)) / 4);
  --osd-button-height: calc(max(1lh + 2 * var(--text-line-gap), var(--osd-button-min-height)));
  --osd-title-height: calc(1lh + var(--text-block-gap));
  /* fonts to just use half of the scale */
  --osd-font-scale: calc(calc(1 + var(--osd-screen-scale)) / 2);
  width: var(--osd-screenshot-width);
  height: var(--osd-screenshot-height);
  background: var(--osd-background-color);
  font-size: calc(var(--osd-font-size) * var(--osd-font-scale));
  color: var(--osd-color);
}

.osd {
  position:relative;
  height: calc(var(--osd-screenshot-height) - 2 * var(--margin-left-right));      /* to properly position OSD messages without items */
  padding: var(--margin-top-bottom) var(--margin-left-right);
}

.osd div {
  tab-size: 4;
  font-family: "Courier New", Courier, monospace;
}

.osdChannel {
  font-size: calc(var(--osd-title-font-size) * var(--osd-font-scale));
  font-weight: bold;
}

.osdSchedule td {
  padding-left: var(--margin-left-right);
  vertical-align: top;
}

.osdSchedule td:first-of-type {
  padding-left: 0px;
}

.osdSchedule {
  font-size: calc(var(--osd-font-size) * var(--osd-font-scale));
}

.osdSchedule.title {
  margin: initial;
  font-size: calc(var(--osd-font-size) * var(--osd-font-scale));
  font-weight: inherit;
}

.osdSchedule.subtitle {
  font-size: calc(var(--osd-subtitle-font-size) * var(--osd-font-scale));
}

.osdText, .osdItems {
  overflow-x: hidden;
  overflow-y: auto;
  height: calc(var(--osd-screenshot-height) - var(--osd-title-height) - var(--margin-top-bottom) - var(--osd-button-height) - var(--osd-button-margin));
  margin: var(--margin-top-bottom) 0px;
}

.osdItem, .osdTitle {
  white-space: pre;
}

.osdTitle {
  font-size: calc(var(--osd-title-font-size) * var(--osd-font-scale));
  font-weight: bold;
}

.osdItem {
  cursor: pointer;
}

.osdItem.notSelectable {
  cursor: default;
}

.osdItems table, .osdItems tr, .osdItems td {
  padding: 0ch;
  border-collapse: collapse;
  width: 100%;
  font-size: calc(var(--osd-font-size) * var(--osd-font-scale));
}

tr.osdItem, tr.osdItem td {
  padding: 1px;
  width: 0%;
}

tr.osdItem td:not(:first-child) {
  padding-left: 1ch;
}

tr.osdItem td:last-child {
  width: 100%;
}

tr.osdItem:hover {
  font-weight: bold;
}

tr.osdItem.selected td {
  background: var(--osd-background-color-highlight);
  color: var(--osd-color-highlight);
}

.osdMessage {
  position: absolute;
  /* use bottom to expand multi-line message to top */
  bottom: calc(var(--osd-button-height) + 2 * var(--margin-top-bottom));
  width: calc(var(--osd-screen-width) - 4 * var(--margin-left-right) - 2 * var(--osd-message-border-width));
  display: flex;
  flex-flow: column;
  overflow: hidden;
  max-height: 4lh;
  padding: var(--margin-top-bottom) var(--margin-left-right);
  background: var(--osd-message-background-color);
  border: var(--osd-message-border-width) solid var(--osd-message-border-color);
  color: var(--osd-message-color);
}

.osdMessage div {
  overflow: hidden;
  text-overflow: ellipsis;
}

.osdMessage.status {
  background: var(--osd-status-background-color);
  border: var(--osd-message-border-width) solid var(--osd-status-border-color);
  color: var(--osd-status-color);
}

.osdMessage.info {
  background: var(--osd-info-background-color);
  border: var(--osd-message-border-width) solid var(--osd-info-border-color);
  color: var(--osd-info-color);
}

.osdMessage.warning {
  background: var(--osd-warning-background-color);
  border: var(--osd-message-border-width) solid var(--osd-warning-border-color);
  color: var(--osd-warning-color);
  font-weight: bold;
}

.osdMessage.error {
  background: var(--osd-error-background-color);
  border: var(--osd-message-border-width) solid var(--osd-error-border-color);
  color: var(--osd-error-color);
  font-weight: bold;
}

.osdButtons {
  display: flex;
  flex-flow: nowrap;
  justify-content: space-between;
}

.osdButtons .osdButton {
  display: flex;
  flex-flow: row;
  justify-content: center;
  align-items: center;
  box-sizing: border-box;
  width: var(--osd-button-width);
  height: var(--osd-button-height);
  padding: var(--text-line-gap) var(--margin-left-right);
  overflow: hidden;
  white-space: nowrap;
  cursor: pointer;
}

.osdButtons .osdButton:first-child {
  margin-left: 0px;
}

.osdButtons .osdButton:hover {
  font-weight: bold;
}

.osdButton.green {
  background: var(--osd-button-green-background-color);
  color: var(--osd-button-green-color);
}

.osdButton.yellow {
  background: var(--osd-button-yellow-background-color);
  color: var(--osd-button-yellow-color);
}

.osdButton.blue {
  background: var(--osd-button-blue-background-color);
  color: var(--osd-button-blue-color);
}

.osdButton.red {
  background: var(--osd-button-red-background-color);
  color: var(--osd-button-red-color);
}

.osdButton.invisible {
  background: transparent;
  color: transparent;
  cursor: default;
}

.osdButton .label {
  overflow: hidden;
  text-overflow: ellipsis;
}


/* #############################
   #  Error widget
   #############################
*/

table.error {
  padding: 0px;
  color: var(--error-color);
}

table.error td.title {
  height: var(--error-title-height);
  padding: var(--text-line-gap) calc(2 * var(--margin-left-right));
  background-image: linear-gradient(to bottom, var(--error-title-background-color-top), var(--error-title-background-color-middle) calc(var(--error-title-height) / 2), var(--error-title-background-color-bottom) var(--error-title-height));
  background-origin: border-box;
  border-top-left-radius: var(--error-title-border-radius);
  border-top-right-radius: var(--error-title-border-radius);
  border-bottom: none;
  color: var(--error-title-color);
  font-weight: bold;
}

table.error td.message {
  padding: 5px calc(2 * var(--margin-left-right));
  background: linear-gradient(to top,var(--listing-row-background-color-bottom), var(--listing-row-background-color-top) var(--listing-row-background-gradient-height), var(--listing-row-background-color-top));
  border: var(--error-border-width) solid var(--error-border-color);
  border-top: none;
  font-weight: bold;
}

form.edit_timer + div.error {
  margin: 0px auto;
  color: var(--error-color);
}


/* ########################################
   #  Formular tables
   # (used in forms to group input elements)
   ########################################
*/

table.form {
  color: var(--listing-color);
}

table.form > tbody > tr > td,
table.dependent > tbody > tr > td,
table.dependent > tr > td {
  padding: var(--text-line-gap) 0px;
  background: linear-gradient(to top,var(--listing-row-background-color-bottom), var(--listing-row-background-color-top) var(--listing-row-background-gradient-height), var(--listing-row-background-color-top));
  border-bottom: var(--listing-border-width) solid var(--listing-row-border-color);
  vertical-align: top;
}

table > tbody > tr > td:last-child:has(table.dependent) {
  /* eliminate the padding for right-column cells hosting a dependent table,
  ** so that the borders of inner tables touch the borders of the form */
  padding-right: 0px;
}

table.form > tbody > tr > td .dotted input {
  margin-top: 0px;
}

table.form > tbody > tr > td.leftcol {
  /*! padding-left: var(--text-line-gap); */
}

table.form > tbody > tr > td.rightcol {
  padding-right: var(--margin-left-right);
}

table.form > tbody > tr.head > td {
  margin: 0px;
  padding: 0px;
  border: none;
}

table.form > tbody > tr > td.label {
  font-weight: bold;
}

table.form > tbody > tr > td div.video_content {
  font-weight: bold;
}

table.form > tbody > tr > td div.video_subcontent {
  margin-left: calc(var(--margin-left-right) * 2);
}


table.form > tbody > tr.permissions > td.rightcol {
  padding: var(--text-line-gap) 0px;
}

table.form > tbody > tr.permissions > td.rightcol > div {
  margin: var(--text-line-gap) 0px;
}

table.form div.with-tooltip,
table.form div.with-action-icon {
  display: inline-flex;
  align-items: flex-start;
  justify-content: space-between;
  column-gap: var(--margin-left-right);
}

form div.message {
  margin: var(--margin-top-bottom) 0px;
}

div.message {
  color: var(--message-color);
  font-weight: bold;
  text-align: left;
}

div.message.warning {
  color: var(--warning-color);
}

div.message.error {
  color: var(--error-color);
}

form div.button-panel {
  width: 100%;
}

div.buttons {
  display: flex;
  align-items: center;
  flex-flow: row wrap;
  gap: var(--margin-top-bottom) calc(var(--margin-left-right) * 2);
  margin: var(--margin-top-bottom) 0px;
}

table.dependent {
  width: 100%;
}

table.dependent > tbody > tr:last-child > td {
  padding-bottom: 0px;
  background: none;
  border-bottom: none;
}

table.dependent > tbody > tr > td.label {
  font-weight: bold;
}

table.dependent > tbody > tr > td.label .withmargin {
  margin-left: 0px;
}

table.dependent > tbody > tr > td > .without-label {
  margin-top: calc(var(--margin-top-bottom) - 2 * var(--text-line-gap));
  margin-bottom: calc(var(--margin-top-bottom) - var(--text-line-gap));
}

table.dependent > tbody > tr > td:last-child {
  padding-right: var(--margin-left-right);
}

table.form tbody > tr > td > input,
table.form tbody > tr > td > select,
table.form tbody > tr > td > div.with-tooltip,
table.form tbody > tr > td > div.with-action-icon,
table.form tbody > tr.permissions > td input[type=checkbox] {
  margin-top: calc(var(--margin-top-bottom) - var(--text-line-gap));      /* visual adjustment */
  margin-left: 0px;
}

table.form tbody > tr > td > div.with-tooltip,
table.form tbody > tr > td > div.with-action-icon {
  margin-bottom: calc(var(--margin-top-bottom) - var(--text-line-gap));   /* visual adjustment */
}

table.form tbody > tr > td > select[multiple=multiple] {
  margin-left: var(--margin-left-right);
  margin-top: calc(var(--margin-top-bottom) - var(--text-line-gap));  /* visual adjustment */
  padding-top: 0px;
  padding-bottom: 0px;
}

table.form tbody > tr > td > input[type=checkbox] {
  margin-top: var(--margin-top-bottom);
}

table.form tbody > tr > td > div.with-tooltip > input[type=checkbox],
table.form tbody > tr > td > div.with-action-icon > input[type=checkbox] {
  margin-top: var(--text-line-gap);     /* visual adjustment */
  margin-bottom: var(--text-line-gap);  /* visual adjustment */
}


select#channel_mode, div#channelgroup, div#blacklistmodesettings, select#useassearchtimer {
  margin: var(--text-line-gap) 0px;
}

input#directory {
  margin-top: var(--text-line-gap);
  margin-bottom: var(--text-line-gap);
}

div#channelgroup, select#recordingdirsselection {
  margin-bottom: calc(var(--text-line-gap) + 1px);
}

div#delmoderecordings, div#delmodedays {
  margin-top: var(--text-line-gap);
  margin-bottom: calc(var(--text-line-gap) + 1px);
}


/* #############################
   #  Login
   #############################
*/

div.loginwin {
  width: 350px;
  margin: calc(2 * var(--body-margin)) auto;
  text-align: center;
}

div.login_content {
  padding: calc(3 * var(--margin-top-bottom)) calc(3 * var(--margin-left-right));
  border: var(--infowin-border-width) solid var(--infowin-border-color);
  border-top: none;
}

div.login_content img.logo {
  width: 100%
}

div.login_content .message {
  margin: 0px auto;
  color: var(--listing-color-highlight);
  font-weight: bold;
}

table.login {
  margin: 0px auto;
  color: var(--infowin-color);
}

table.login tr td {
  padding: var(--margin-top-bottom) var(--margin-left-right);
}

table.login tr td:has(button) {
  padding: 0px;
}


/* #############################
   #  Styles for EPG boxes
   #############################
*/

div.epg_description {
  margin: 0px auto;
  border-top-left-radius: var(--infowin-title-border-radius);
  border-top-right-radius: var(--infowin-title-border-radius);
}

div.epg_description div.boxheader .caption a.inactive {
  cursor: pointer;
  color: inherit;
  list-style: inherit;
  font-weight: inherit;
}

div.epg_description div.boxheader .caption a.active {
  cursor: pointer;
  color: var(--menu-color-highlight);
  list-style: inherit;
  font-weight: inherit;
}

div.epg_description div.epg_content {
  border: var(--infowin-border-width) solid var(--infowin-border-color);
  border-top: none;
}

div.epg_content {
  display: flex;
  width: 100%;
  margin: 0px;
  padding: 0px;
  background: var(--infowin-background-color);
}

div.epg_content div.event_actors {
  display: flex;
  flex-flow: row wrap;
  gap: var(--margin-top-bottom) var(--margin-left-right);
}

div.epg_content div.actor {
  width: var(--epg-photo-width);
}

div.epg_content div.actor_photo img.photo {
  width: var(--epg-photo-width);
}

div.epg_content img.actor_name {
}

div.epg_content div.charactor {
}

div.epg_content img.artwork {
  width: 100%;
  max-width: var(--epg-artwork-width);
}

div.epg_content div.epg_tools {
  display: flex;
}

div.epg_content div.epg_tools div.tools {
  display: flex;
  flex-flow: column;
  align-items: center;
  gap: var(--icon-row-gap) var(--icon-column-gap);
  min-width: calc(max(var(--icon-width) + 2 * var(--margin-left-right), var(--sdhd-width) + 2 * round(up, var(--margin-left-right) / 2, 1px)));
  padding: var(--margin-top-bottom) 0px;
  background: var(--infowin-tools-background-color);
  border-right: var(--infowin-tools-border-width) solid var(--infowin-tools-border-color);
  line-height: 0px;     /* to keep the block as small as possible */
}

div.epg_content div.epg_tools div.event_status,
div.epg_content div.epg_tools div.recording_status {
  display: inherit;
  flex-flow: inherit;
  align-items: inherit;
  gap: inherit;
  margin-top: calc(2 * var(--margin-top-bottom));
}

div.epg_content div.info {
  height: 100%;    /* for vertical scrollbar */
}

div.epg_content div.epg_info {
  width: 100%;     /* for horizontal scrollbar, if any */
  padding: 0px var(--infowin-body-margin);
  background: transparent linear-gradient(to right, var(--infowin-tools-background-color), transparent var(--infowin-background-gradient-height));
  color: var(--infowin-color);
}

div.epg_info div.spacebar:first-child {
  top: 0px;
  position: sticky;
  height: var(--margin-top-bottom);
  background: transparent linear-gradient(to bottom, var(--infowin-background-color), transparent);
}

div.epg_info div.spacebar:last-child {
  bottom: 0px;
  position: sticky;
  height: var(--margin-top-bottom);
  background: transparent linear-gradient(to top, var(--infowin-background-color), transparent);
}

span.epg_images img.epg_image {
  width: 100%;
}

/* some adaptions when shown in browser window or tab */

div.epg_description div.epg_content {
  width: unset;
}

/* some adaptions when shown in info-win subwindow */

div.info-win div.boxheader {
  display: none;
}

div.info-win div.epg_content {
  width: 100%;
}

div.epg_content form {
  width: 100%;
}

div.epg_content form div.about_left,
div.epg_content form div.about_right {
  margin: var(--margin-top-bottom) var(--margin-left-right);
}


/* ##################################
   #  Style adaptations for About box
   ##################################
*/

div.epg_content div.about_content {
  width: 100%;
  min-width: inherit;
  height: inherit;
  min-height: inherit;
  overflow: auto;
}

div.epg_content div.about_content a {
}

div.epg_content div.about_head {
  padding: var(--margin-top-bottom) var(--margin-left-right);
  background: var(--infowin-section-background-color);
  border-top: var(--infowin-section-border-width) solid var(--infowin-section-border-color);
  border-bottom: var(--infowin-section-border-width) solid var(--infowin-section-border-color);
  color: var(--infowin-section-color);
  font-weight: bold;
}

div.epg_content div.about_section {
  padding: var(--margin-top-bottom) var(--infowin-body-margin);
}

div.epg_content div.about_section div.tabular {
  display: grid;
  grid-template-columns: var(--infowin-label-width) auto;
  gap: var(--margin-top-bottom) var(--margin-left-right);
  padding: var(--margin-top-bottom) var(--infowin-body-margin);
}

div.epg_content div.about_section div.about_left {
  color: var(--infowin-color);
}

div.epg_content div.about_section div.about_right {
  color: var(--infowin-color);
}

div.epg_content div.about_section div.about_right img {
  vertical-align: text-top;
}

div.epg_content div.about_line {
  padding: var(--margin-top-bottom) calc(2 * var(--margin-left-right));
  color: var(--infowin-color);
}

div.epg_content.confirmation {
  display: flex;
  flex-flow: column;
}

div.epg_content.confirmation div.about_head:has(.object-list) {
  display: flex;
  flex-flow: column;
  height: 100%;
  min-height: calc(calc(var(--margin-top-bottom) + var(--text-line-gap)) * 2 + 1lh);
}

div.epg_content.confirmation div.about_head:has(.object-list) div.prompt {
  padding-bottom: var(--margin-top-bottom);
}

div.epg_content.confirmation div.about_head div.object-list {
  display: flex;
  flex-flow: column;
  overflow-y: auto;
}

div.epg_content.confirmation div.object-list ol,
div.epg_content.confirmation div.object-list ul {
  margin: 0px;
  padding-left: 3ch;  /* set to 0ch for no marker */
}

div.epg_content.confirmation div.object-list ul > li,
div.epg_content.confirmation div.object-list ol > li {
  margin: var(--text-line-gap) 0px;
}

div.epg_content.confirmation div.label,
div.epg_content.confirmation div.message {
  padding: var(--margin-top-bottom)  var(--margin-left-right) 0px var(--margin-left-right);
}

div.thumb {
  overflow: hidden;
  max-width: var(--thumb-image-width);
  max-height: var(--thumb-image-height);
  margin-top: var(--text-line-gap);
  margin-bottom: var(--text-line-gap);
  margin-right: var(--margin-left-right);
  text-align: center;
}

a.thumb {
}

img.thumb, img.thumbpt {
  max-width: var(--thumb-image-width);
  max-height: var(--thumb-image-height);
  object-fit: contain;
}

.space {
  width: 0px;
  padding: 0px;
}


/* ###############################################
   #  @media (max-width: 600px)
   #  at end of stylesheet, as order of stylesheet
   #  matters in conflicting cases
   ###############################################
*/

.xs-nomargin {
  margin: 0px;
}

.display-xs {
  display: none;
}


@media (max-width: 600px) {

  /* rather small display */

  div#infobox {
    min-width: calc(100svw - 2 * var(--body-margin));
  }

  div#infobox.with-logo {
    min-width: calc(100svw - 2 * var(--body-margin) - var(--page-header-gap) - var(--vdr-logo-small-width));
    max-width: calc(100svw - 2 * var(--body-margin) - var(--page-header-gap) - var(--vdr-logo-small-width));
  }

  div#logo img.logo {
    width: var(--vdr-logo-small-width);
  }

  div.__progress {
    /* using 80% to avoid the progress bar being smaller than the text above */
    width: calc(var(--infowin-progressbar-width) * 0.8);
  }

  div.__progress_invisible {
    width: valc(var(--infowin-progressbar-width) * 0.8);
  }

  div.info-win {
    max-width: 90vh;
  }

  td.enlarge-image div.thumb {
    max-width: calc(var(--thumb-image-width) * 1.25);
    max-height: 100%;
  }

  td.enlarge-image img.thumb {
    max-width: calc(var(--thumb-image-width) * var(--thumb-image-enlargement-scale));
    max-height: calc(var(--thumb-image-heigth) * var(--thumb-image-enlargement-scale));
  }

  td.enlarge-image img.thumbpt {
    max-width: calc(var(--thumb-image-width) * var(--thumb-image-enlargement-scale));
    max-height: calc(var(--thumb-image-height) * var(--thumb-image-enlargement-scale));
  }

  span.epg_images {
    width: calc(max(var(--epg-image-width) * 0.625, 120px));
  }

  div.epg_content div.actor {
    width: calc(var(--epg-photo-width) * 0.6);
  }

  div.epg_content div.actor_photo img.photo {
    width: calc(var(--epg-photo-width) * 0.6);
  }

  .hint-tip {
    max-width: 200px;
  }

  img.channel_logo {
    max-width: calc(max(var(--logo-image-width) * 0.6, 90px));
    max-height: var(--logo-image-height);
  }

  .xs-nomargin {
    margin: 0px !important;
  }

  .hidden-xs {
    display: none;
  }

  div#content > div.epg_description div.epg_tools .hidden-xs {
    display: block;
  }

  .td-hidden-xs {
    width: 0px !important;
    padding: 0px !important;
  }

  .display-xs {
    display: inline;
  }

  div.display-xs {
    display: block;
  }

  div#content > table {
    /* force full with on small screens */
    width: 100%;
  }

  table.listing > tbody > tr > td.leftcol div.event_actions {
    display: flex;
    flex-flow: column wrap;
    width: var(--icon-width);
    max-height: calc(3 * var(--icon-height) + 2 * var(--icon-row-gap));
  }

  table.listing > tbody > tr.existing_recording > td.leftcol {
    max-width: 5ch;
    max-height: 3lh;
    overflow: hidden;
    text-overflow: ellipsis;
    vertical-align: middle;
   }

  table.listing.schedule div.recording_status {
    display: flex;
    flex-flow: column;
    align-items: center;
    padding-top: 0px;
  }

  table.listing.timers > tbody > tr > td.leftcol,
  table.listing.searchtimers > tbody > tr > td.leftcol {
    vertical-align: middle;
  }

  table.listing.schedule > tbody > tr > td.leftcol div.event_actions {
    display: flex;
    flex-flow: column;
    min-width: 0px;
  }

  table.listing.schedule > tbody > tr > td.leftcol div.label {
    max-height: 1lh;
  }

  table.listing.schedule > tbody > tr > td.leftcol div.recording_status {
    display: flex;
    flex-flow: column;
    align-items: flex-start;
    min-width: 0px;
  }

  table.streaming > tbody > tr > td.leftcol {
    vertical-align: top;
   }

  table.listing > tbody > tr > td.rightcol div.event_actions {
    display: flex;
    flex-flow: column;
    align-items: flex-end;
    gap: var(--icon-row-gap) var(--icon-column-gap);
    padding: var(--margin-top-bottom) var(--margin-left-right);
  }

  table.timerconflicts > tbody > tr > td.rightcol div.event_actions,
  table.listing.searchtimers > tbody > tr > td.rightcol div.event_actions,
  tr.recording_item div.recording_actions {
    display: flex;
    flex-flow: column wrap;
    justify-content: flex-start;
    gap: var(--icon-row-gap) var(--icon-column-gap);
    width: var(--icon-width);
    max-height: calc(3 * var(--icon-width) + 2 * var(--icon-row-gap));
  }

  table.listing > tbody > tr > td.leftcol div.event_actions:has(.xs-columns-2),
  table.timerconflicts > tbody > tr > td.rightcol div.event_actions:has(.xs-columns-2),
  table.searchtimers > tbody > tr > td.rightcol div.event_actions:has(.xs-columns-2),
  tr.recording_item div.recording_actions:has(.xs-columns-2) {
    width: calc(2 * var(--icon-width) + var(--icon-column-gap));
  }

  table.listing > tbody > tr > td.leftcol div.event_actions:has(.xs-visible-4),
  table.timerconflicts > tbody > tr > td.rightcol div.event_actions:has(.xs-visible-4),
  table.searchtimers > tbody > tr > td.rightcol div.event_actions:has(.xs-visible-4),
  tr.recording_item div.recording_actions:has(.xs-visible-4) {
    max-height: calc(2 * var(--icon-height) + var(--icon-row-gap));
  }

  tr.recording_item div.recording_status {
    padding-left: var(--margin-left-right);
  }

  tr.recording_item div.recording_actions {
    margin-left: auto;
    padding-top: var(--margin-top-bottom);
    padding-bottom: var(--margin-top-bottom);
  }

  tr.recording_item div.thumb {
    padding-left: var(--margin-left-right);
  }

  table.streaming > tbody > tr > td.action {
    padding-top: calc(var(--margin-top-bottom) - var(--text-line-gap));   /* visual adjustment */
  }

  table.streaming > tbody > tr > td.leftcol div.recording_status {
    display: flex;
    flex-flow: row wrap;
    max-width: calc(var(--icon-width) + var(--sdhd-width) + var(--icon-column-gap));
  }

  table.streaming > tbody > tr > td .label {
    max-height: 1lh;
  }

  table.streaming > tbody > tr > td div.more {
    white-space: wrap;
  }

}


@media (hover: none) {

  /* touch-screen display */

  .hidden-ts {
    display: none;
  }

}
