p {
  margin: 5px 0;
}

a {
  color: #2196f3;
  word-wrap: break-word;
}

@media only screen and (max-width:850px) {
  #header0 {
    display: none;
  }

  header {
    position: fixed;
    top: 0;
    left: 0;
    height: 60px;
    width: 100%;
    background-color: #000;
    display: flex;
    z-index: 100;
  }

  header .brand {
    color: white;
    font-size: 20px;
    margin: auto 20px;
  }

  .hs {
    padding: 10px 10px 0 10px;
    position: fixed;
    margin: 0 auto;
    left: 0;
    top: 0;
    height: 70px;
    width: calc(100vw - 20px);
    background-color: #000;
    z-index: 10000;
  }

  .hs h1 {
    margin: 0;
    width: fit-content;
    font-size: 20px;
  }

  .hs .l {
    position: fixed;
    top: 10px;
    right: 10px;
    display: flex;
    height: 60px;
    width: 60px;
    justify-content: center;
    align-items: center;
    z-index: 90;
    background-color: #ddd;
    z-index: 100;
  }

  .hs .l span,
  .hs .l span:before,
  .hs .l span:after {
    transition: 300ms;
    content: '';
    display: inline-block;
    height: 3px;
    width: 25px;
    border-radius: 3px;
    background-color: #000;
    position: absolute;
  }

  .hs .l span:before {
    bottom: 8px;
  }

  .hs .l span:after {
    top: 8px;
  }

  #hd:checked~.hs .l span {
    transition: 300ms;
    background-color: rgba(255, 255, 255, 0);
  }

  #hd:checked~.hs .l span::before {
    bottom: 0;
    transition: 300ms;
    transform: rotate(45deg);
  }

  #hd:checked~.hs .l span::after {
    top: 0;
    transition: 300ms;
    transform: rotate(-45deg);
  }

  #hd {
    display: none;
  }

  .hc {
    transition: 300ms;
    width: 100%;
    height: 100%;
    position: fixed;
    top: 0;
    left: 100%;
    z-index: 80;
    background-color: #000;
  }

  .hc ul {
    padding: 70px 10px 0;
  }

  .hc ul li {
    border-bottom: solid 1px #fff;
    list-style: none;
  }

  .hc ul li a {
    display: block;
    width: 100%;
    font-size: 15px;
    box-sizing: border-box;
    color: #fff;
    text-decoration: none;
    padding: 9px 15px 10px 0;
    position: relative;
    font-weight: 600;
  }

  .hc ul li a::before {
    content: "";
    width: 7px;
    height: 7px;
    border-top: solid 2px #fff;
    border-right: solid 2px #fff;
    transform: rotate(45deg);
    position: absolute;
    right: 11px;
    top: 16px;
  }

  #hd:checked~.hc {
    transition: 300ms;
    left: 0;
  }
}

@media only screen and (min-width:850px) {
  #header1 {
    display: none;
  }

  header {
    position: fixed;
    top: 0;
    left: 0;
    height: 60px;
    width: 100%;
    background-color: #000;
    display: flex;
    z-index: 100;
    line-height: 120%;
  }

  header .brand {
    color: white;
    font-size: 20px;
    margin: auto 20px;
  }

  header ul {
    list-style: none;
    color: white;
    margin: auto 20px;
    display: flex;
  }

  header ul li {
    margin-right: 10px;
  }

  header a {
    text-decoration: none;
    color: white;
  }

  header a:hover {
    text-decoration: underline;
    color: white;
  }

  header .user {
    color: white;
    margin: auto 20px auto auto;
  }
}

footer {
  position: sticky;
  top: 100vh;
  left: 0;
  width: 100%;
  height: 25px;
  text-align: center;
  background-color: #000;
  color: #fff;
}

@media only screen and (min-width:850px) {
  main {
    margin: 80px 10px 10px 10px;
  }
}

@media only screen and (max-width:850px) {
  main {
    margin: 100px 10px 10px 10px;
  }
}

main .main,
main .contest_main {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  padding: 0px 10px;
}

@media only screen and (min-width:1220px) {
  .item_container {
    width: calc(28% - 40px);
    min-width: 320px;
    height: fit-content;
    min-height: 600px;
    border: solid 2px #000000;
    margin: 10px;
    padding: 20px;
  }
}

@media only screen and (max-width:1220px) {
  .item_container {
    width: calc(46% - 40px);
    min-width: 320px;
    height: fit-content;
    min-height: 600px;
    border: solid 2px #000000;
    margin: 10px;
    padding: 20px;
  }
}

@media only screen and (max-width:850px) {
  .item_container {
    width: calc(100% - 40px);
    min-width: 320px;
    height: fit-content;
    min-height: 600px;
    border: solid 2px #000000;
    margin: 10px;
    padding: 20px;
  }
}

.item_container h2,
.item_container3 h2 {
  margin: 0 0 20px 0;
  font-weight: 400;
}

.item_container .item {
  margin: 20px 0;
  width: 100%;
  border-bottom: solid 1px #00000010;
}

.item_container .item .tag, .item_container3 .tag {
  padding: 2px 12px;
  margin-right: 5px;
  font-size: 13px;
  background-color: #000000;
  color: #ffffff;
}

.tag1 {
  background-color: #2196f3 !important;
  color: #fff;
}

.tag2 {
  background-color: #38c172 !important;
  color: #fff;
}

.tag3 {
  background-color: #6c757d !important;
  color: #fff;
}

.item_container .item .date, .item_container3 .date {
  color: #6c757d;
  font-size: 13px;
}

.item_container .item p {
  margin: 5px 0 0 0;
}

.item_container .item>a {
  font-size: 22px;
  display: block;
  margin: 10px 0 2px 0;
  color: #000;
  text-decoration: none;
}

.item_container .item>a:hover {
  text-decoration: underline;
}

.item_container1 {
  width: calc(15% - 40px);
  min-width: 300px;
  height: fit-content;
  border: solid 2px #000000;
  /*border-radius: 3px;*/
  /*box-shadow: #0000001a 0 0 30px;*/
  margin: 10px;
  background-color: #fff;
}

.item_container1 img,
.item_container3 img {
  width: 100%;
  display: block;
}

.item_container1 h3 {
  margin: 10px 20px;
  display: block;
}

.item_container1 .wrapper {
  margin: 10px 20px 20px 20px;
}

.item_container1 .item {
  position: relative;
  margin: 10px 0;
  width: 100%;
  margin: 5px 0px 5px 36px;
}

.item_container1 .item::before {
  content: '';
  position: absolute;
  background-image: url("data:image/svg+xml,%3Csvg fill='%23000000' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Cpolygon points='16 16, 15 12, 16 4, 17 12' stroke='%23000000' fill='%23000000' stroke-width='0'/%3E%3Cpolygon points='16 16, 20 15, 28 16, 20 17' stroke='%23000000' fill='%23000000' stroke-width='0'/%3E%3Cpolygon points='16 16, 17 20, 16 28, 15 20' stroke='%23000000' fill='%23000000' stroke-width='0'/%3E%3Cpolygon points='16 16, 12 17, 4 16, 12 15' stroke='%23000000' fill='%23000000' stroke-width='0'/%3E%3C/svg%3E%0A");
  transform-origin: 50% 50%;
  transform: rotate(45deg) scale(1.5);
  top: 4px; left: -36px;
  width: 32px; height: 32px;
}

.item_container1 .item p {
  margin: 3px 0;
}

.item_container1 .item .value {
  font-size: 16px;
  color: #000;
}

.item_container1 .item .valuel {
  font-size: 20px;
  color: #000;
}

.item_container1 .item .name {
  font-size: 14px;
  color: #666;
}

.item_container1 .join_rated {
  position: relative;
  width: 100%;
  height: 40px;
  color: #fff;
  background-color: #38c172;
  align-content: center;
  text-align: center;
}

.item_container1 .join_unrated {
  position: relative;
  width: 100%;
  height: 40px;
  color: #fff;
  background-color: #6c757d;
  align-content: center;
  text-align: center;
}

.item_container1 .join_rated a,
.item_container1 .join_unrated a {
  color: #fff;
  text-decoration: none;
}

.join_rated a,
.join_unrated a {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  align-content: center;
  text-align: center;
}

.item_container2 {
  box-sizing: border-box;
  min-width: 340px;
  height: fit-content;
  min-height: 600px;
  border: solid 2px #000000;
  margin: 10px;
  padding: 20px;
  background-color: #fff;
}

@media only screen and (min-width: 1090px) {
  .item_container2 {
    width: calc(70% - 40px);
  }
}

@media only screen and (max-width: 1090px) {
  .item_container2 {
    width: 100%;
  }
}

.item_container2 h2 {
  font-weight: 500;
}

.item_container2 h3 {
  font-weight: 500;
  margin: 10px 0;
}

.item_container2 .stitle {
  font-size: 16px;
  margin: 0;
}

.item_container2 .writer span,
.item_container2 .tester span {
  font-weight: 600;
}

.contest_tab {
  width: 100%;
  border-bottom: solid 1px #00000040;
  margin: 10px 0;
}

.contest_tab a {
  display: inline-block;
  height: 25px;
  padding: 5px 10px;
  margin: 0;
  color: #000;
  text-decoration: none;
  border-bottom: none;
}

.contest_tab a:hover {
  border-bottom: solid 2px #00000080;
}

.contest_tab .current {
  border-bottom: solid 2px #0000ff80;
}

.ca {
  display: inline-block;
  width: 50px;
  height: 30px;
  align-content: center;
  text-align: center;
  color: #000;
  background-color: #b3ffcc;
}

.wa {
  display: inline-block;
  width: 50px;
  height: 30px;
  align-content: center;
  text-align: center;
  color: #000;
  background-color: #ffa099;
}


.wj {
  display: inline-block;
  width: 50px;
  height: 30px;
  align-content: center;
  text-align: center;
  color: #fff;
  background-color: #444;
}

.item_container3 {
  width: calc(100% - 40px);
  min-width: 340px;
  box-sizing: border-box;
  height: fit-content;
  min-height: 600px;
  border: solid 2px #000000;
  margin: 10px;
  padding: 20px;
}

.rscore {
  font-family: 'Roboto Condensed';
  font-weight: 400;
  font-size: 20px;
  color: #00f;
  margin: 0;
}

.rtime {
  font-weight: 400;
  font-size: 13px;
  color: #444;
  margin: -3px 0 0 0;
}

.r_wa {
  background-color: #ffa099;
}

.problem_text p {
  /*text-indent: 1rem;*/
}

.problem_text img {
  width: 100%;
}

.answer_item {
  width: 100%;
  height: fit-content;
  border: solid 1px #00000040;
  margin: 5px;
  text-align: center;
}

.fieldbox {
  display: flex;
  flex-wrap: wrap;
}

.fieldbox p {
  width: 100%;
}

.atinfo {
  font-size: 14px;
}

.atfield {
  width: 80%;
  min-width: 280px;
  height: 30px;
  margin: 5px 5px;
  box-sizing: border-box;
  font-size: 16px;
}

.atbutton {
  width: 15%;
  min-width: 60px;
  height: 30px;
  margin: 5px 5px;
  font-size: 14px;
  border: none;
}

.atbutton:hover {
  background-color: #a2d5ff;
}

.parenlist {
  padding-left: 1rem;
}

.parenlist li {
  list-style-type: none;
  padding-left: 0;
  counter-increment: cnt;
}

.parenlist li::before {
  content: "(" counter(cnt) ") ";
}

.user_main {
  display: flex;
  justify-content: center;
  margin: 20px;
}

.info {
  width: 100%;
  height: fit-content;
  color: #000;
  background-color: #9ed3ff;
  border: solid 1px #2196f3;
  font-weight: 500;
  align-content: center;
  text-align: center;
  padding: 10px;
  box-sizing: border-box;
}

.utag {
  font-weight: 600;
}

.rate0 {
  color: #808080;
}

.rate1 {
  color: #804000;
}

.rate2 {
  color: #008000;
}

.rate3 {
  color: #00c0c0;
}

.rate4 {
  color: #0000ff;
}

.rate5 {
  color: #c0c000;
}

.rate6 {
  color: #ff8000;
}

.rate7 {
  color: #ff0000;
}

.rate8 {
  color: #7030a0;
}

.ratex {
  color: #ff1493;
}

.rmys {
  background-color: #d9edf7;
}

.genre_button {
  border-radius: 15px;
  padding: 0 15px;
  align-content: center;
  height: 30px;
  width: fit-content;
  background-color: #2196f3;
  color: #fff;
  margin-right: 5px;
}

.genre_button2 {
  border-radius: 15px;
  padding: 0 15px;
  align-content: center;
  height: 30px;
  width: fit-content;
  color: #000;
  margin-right: 5px;
}

.genre_button a {
  text-decoration: none;
  color: #fff !important;
}

.genre_button2 a {
  text-decoration: none;
  color: #000 !important;
}

.genre_button2:hover {
  background-color: #ddd;
}

.dif {
  position: absolute;
  display: block;
  top: 0;
  bottom: 0;
  left: 10px;
  height: 12px;
  width: 12px;
  border-radius: 50%;
  border: solid 1px #000;
  z-index: 3;
  margin: auto 3px auto 0;
  text-align: center;
}

.diftx {
  position: absolute;
  top: -16px;
  left: 18px;
  font-weight: 500!important;
  font-family: "Roboto Condensed";
  font-size: 14px;
}