@media only screen and not (max-width: 1080px){
  .landscape-hide {
    display: none !important;
  }
}

@media only screen and (max-width: 1080px) {
  :root {
    --header-height: 60px;
    --header-width: 0px;
    --logo-height: 20px;
  }

  body > *:not(#header) {
    margin-left: 0;
  }

  body > *:not(#header, #footer) {
    margin-top: var(--header-height);
  }

  body.full > *:not(#header) {
    margin-top: 0;
  }

  main {
    min-height: calc(100vh - var(--header-height) - var(--footer-height));
    padding: 10px 25px;
  }

  body.full main {
    min-height: calc(100vh - var(--footer-height));
  }

  .portrait-hide, #header-real #logo-word, #search-box {
    display: none !important;
  }

  #header-real.hide {
    transform: translateY(-100%);
  }

  #header-real {
    top: 0;
    height: var(--header-height);
    width: 100vw;
    padding: 0 15px;
    flex-direction: row;
    column-gap: 10px;
    justify-content: space-around;
  }

  #header-top, #header-bottom {
    flex-direction: row;
    row-gap: 0;
    column-gap: 15px;
    width: unset;
  }

  #header-bottom #small-option-container {
    justify-items: stretch;
    grid-template-columns: repeat(4, 1fr);
  }

  #header-bottom #small-option-container > * {
    width: unset;
    height: unset;
    padding: 5px 7.5px;
  }

  .web-section {
    padding: 10px;
  }

  #header-bottom #user-info {
    gap: 5px;
  }

  #header-bottom #user-info #user-info-main {
    column-gap: 0;
  }

  #nav {
    flex-direction: row;
    width: unset;
    gap: 5px;
  }

  .tabs-container {
    flex-direction: column;
  }

  .tabs-container>.tabs-selector {
    flex-direction: row;
    overflow-x: auto;
  }

  #header-real #clock {
    column-gap: 0.175em;
  }

  #header-real .contest-clocks {
    flex-direction: row;
  }

  #logo-icon {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  #toggle-header, #toggle-header-space {
    left: 0;
    bottom: 0;
    top: unset;
    height: unset;
  }
  
  #toggle-header-space {
    transform: translateY(100%);
  }
  
  #toggle-header {
    transform: translateY(0);
  }
  
  #toggle-header-space:hover ~ #toggle-header {
    transform: translateY(100%);
  }

  #header-real.hide #toggle-header img {
    transform: scaleY(-1);
  }
}

@media only screen and (max-width: 720px) {
  main {
    padding: 10px;
  }

  #header-top {
    column-gap: 10px;
  }

  #header-bottom {
    column-gap: 5px;
  }

  #header-bottom #user-info {
    flex-direction: column;
  }

  #header-real #clock, .contest-header-info {
    display: none !important;
  }

  #header-bottom #small-option-container {
    grid-template-columns: repeat(2, 1fr);
  }
}