html {
  font-size: calc(100vw / 32);

  @media (min-width: 768px) {
    font-size: calc(100vw * 16 / 768);
  }
  
  @media (min-width: 1240px) {
    font-size: calc(100vw * 18 / 1240);
  }
  
  @media (min-width: 1440px) {
    font-size: calc(100vw * 20 / 1440);
  }
}

body {
  font-family: "Helvetica Neue", "Helvetica", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Arial", "Yu Gothic", "Meiryo", sans-serif;
  width: 100%;
  color: #252525;
}

#body_div {
  width: 100%;
}

#header_div {
  width: 100%;
  border-bottom: 1px solid #7C7C7C;
  text-align: center;
}

#logo {
  height: 2.5rem;
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}

h1 {
  font-size: 1.5rem;
  font-weight: bold;
  margin-bottom: 0;
}

#main_div {
  width: 100%;
  display: flex;
  flex-flow: column;
  justify-content: space-between;
  align-items: center;
  text-align: center;
}

#main_div div {
  width: 100%;
}

h2 {
  font-size: 1.2rem;
  font-weight: bold;
  margin-bottom: 0.5rem;
  margin-top: 5rem;
}

#ring, canvas {
  width: 70%;
  height: auto;
  max-width: 70svh;
  aspect-ratio: 1;
  border: solid 1px #848484;
}

#creator {
  margin-top: 0.5rem;
}

#rings_area {
  position: relative;
  display: inline-block;
  max-width: calc(100% - 10px);
  border: solid 3px #fda67a;
  box-sizing: border-box;
  border-radius: 15px;
  margin: 20px 5px 0;
}

#rings_area:before {
  content: "";
  position: absolute;
  top: -24px;
  left: 50%;
  margin-left: -15px;
  border: 12px solid transparent;
  border-bottom: 12px solid #FFF;
  z-index: 2;
}

#rings_area:after {
  content: "";
  position: absolute;
  top: -30px;
  left: 50%;
  margin-left: -17px;
  border: 14px solid transparent;
  border-bottom: 14px solid #fda67a;
  z-index: 1;
}

#ring_list {
  display: flex;
  width: 95%;
  max-width: 95%;
  height: auto;
  overflow-x: auto;
  margin-left: auto;
  margin-right: auto;
}

.ring_container {
  width: 35svh;
  max-width: 35svw;
}

.rings {
  cursor: pointer;
  height: auto;
  width: 35svh;
  max-width: 35svw;
  aspect-ratio: 1;
  border: solid 1px #848484;
}

.rings:first-child {
  margin-left: auto;
}

.rings:last-child {
  margin-right: auto;
}

p {
  font-size: 1rem;
  font-weight: bold;
  line-height: 1.5rem;
  margin-bottom: 0.5rem;
}

.ring_name {
  padding-left: 0.3rem;
  padding-right: 0.3rem;
}

.ring_name, #ring_cmt, #out_cmt, #png_p {
  font-weight: normal;
}

#ringIpt, #iconIpt {
  color: #252525;
  cursor: pointer;
  border: 1px solid #848484;
  border-radius: 0.5rem;
  padding-right: 0.5rem;
  width: 20rem;
  height: 2rem;
  font-size: 1rem;
  margin-top: 1rem;
}

::file-selector-button,
::-webkit-file-upload-button {
  background-color: #fda67a;
  color: black;
  border: none;
  cursor: pointer;
  border-right: 1px solid #848484;
  border-radius: 0.5rem 0 0 0.5rem;
  padding: 0.5rem 1rem;
  margin-right: 1rem;
  height: 2rem;
}

#out_cvs {
  width: 95%;
  cursor: move;
}

#slider_div {
  margin-top: 4rem;
}

#zoom_slider {
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
  background: #ffc9af;
  height: 1rem;
  width: 60%;
  border-radius: 0.5rem;
  border: solid 3px #fda67a;
  outline: 0;
  margin-left: 1rem;
  margin-right: 1rem;
  &:focus {
    box-shadow: 0 0 3px #ffe1d2;
  }
  &::-webkit-slider-thumb {
    -webkit-appearance: none;
    background: #fd5500;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    box-shadow: 0px 3px 6px 0px rgba(0, 0, 0, 0.15);
  }
  &::-moz-range-thumb {
    background: #fd5500;
    width: 1rem;
    height: 1rem;
    border-radius: 50%;
    box-shadow: 0px 3px 6px 0px rgba(0, 0, 0, 0.15);
    border: none;
  }
  &::-moz-focus-outer {
    border: 0;
  }
  &:active::-webkit-slider-thumb {
    box-shadow: 0px 5px 10px -2px rgba(0, 0, 0, 0.3);
  }
}

#flipBtn, #resetBtn {
  width: 7rem;
  height: 2rem;
  border-radius: 0.5rem;
  font-size: 1rem;
  font-weight: bold;
  background-color: #cdcdcd;
  color: #252525;
  border: solid 1px #848484;
  box-shadow: none;
  padding: 0 1rem;
  cursor: pointer;
  margin: 5rem 1.6rem;
}

#pngBtn, #shareBtn {
  width: 35%;
  height: 3rem;
  border-radius: 1.5rem;
  font-size: 1.5rem;
  font-weight: bold;
  background-color: #fd5500;
  color: #ffffff;
  border: none;
  box-shadow: none;
  cursor: pointer;
  margin: 3rem 0;
}

#shareBtn {
  margin-top: 0;
}

#png {
  width: 80%;
  height: auto;
  max-width: 70svh;
  aspect-ratio: 1;
  border: solid 1px #848484;
}

#share_p {
  margin-top: 3rem;
}