body.bg-a { 
  background: url(../images/bg.gif);
}
body.bg-b { 
  background: #fff;
}
html { 
  /* height: 100%; */
}
body {
  margin: 0;
  padding: 0;
  overflow: hidden;
  /* height: 100%; */

  background-color: rgb(224,255,233);
  background-image: -o-linear-gradient(bottom, rgb(255,229,237) 0%, rgb(224,255,233) 100%);
  background-image: -moz-linear-gradient(bottom, rgb(255,229,237) 0%, rgb(224,255,233) 100%);
  background-image: -webkit-linear-gradient(bottom, rgb(255,229,237) 0%, rgb(224,255,233) 100%);
  background-image: -ms-linear-gradient(bottom, rgb(255,229,237) 0%, rgb(224,255,233) 100%);
  background-image: linear-gradient(bottom, rgb(255,229,237) 0%, rgb(224,255,233) 100%);

  touch-action: none;
}

canvas { 
  display: block;
}


#compat { 
  display: none;
  position: absolute;
  top: 0;
  left: 0;
  font: bold italic 150px serif;
  text-shadow: 0 3px 0 rgba(0,0,0,0.15);
  padding: 20px 40px;
  color: #fff;
  z-index: 2;
  pointer-events: none;
}

@-webkit-keyframes shake {
    0% { left: 30px; }
    50% { left: 0; }
    100% { left: 30px; }
}

@-moz-keyframes shake {
    0% { left: 30px; }
    50% { left: 0; }
    100% { left: 30px; }
}

@keyframes shake {
    0% { left: 30px; }
    50% { left: 0; }
    100% { left: 30px; }
}

#shake { 
  word-break: break-word;
  bottom: 0;
  right: 0;
  display: none;
  position: absolute;
  top: 0;
  left: 0;
  font: bold italic 110px serif;
  text-shadow: 0 3px 0 rgba(0,0,0,0.15);
  padding: 20px 40px;
  color: #fff;
  z-index: 2;
  pointer-events: none;
  -webkit-animation-direction: normal;
  -webkit-animation-duration: 0.2s;
  -webkit-animation-iteration-count: infinite;
  -webkit-animation-name: shake;
  -webkit-animation-timing-function: ease;
  -moz-animation-direction: normal;
  -moz-animation-duration: 0.2s;
  -moz-animation-iteration-count: infinite;
  -moz-animation-name: shake;
  -moz-animation-timing-function: ease;
  animation-direction: normal;
  animation-duration: 0.2s;
  animation-iteration-count: infinite;
  animation-name: shake;
  animation-timing-function: ease;
}

#warning { 
  font: bold 11px/14px sans-serif;
  width: 240px;
  border: 5px solid black;
  text-align: center;
  padding: 6px;
  padding-bottom: 8px;
  background-color: #fff;
  position: absolute;
  left: 10px;
  bottom: 10px;
  z-index: 3;
}
.english { 
  display: inline-block;
  vertical-align: middle;
  margin-top: 2px;
}
.chinese {
  font-size: 13px;
  vertical-align: middle;
  display: inline-block;
  /*margin-left: 10px;*/
}
#enquiries { 
  position: absolute;
  top: 15px;
  right: 20px;
  z-index: 3;
}
#enquiries a {
  display: inline-block;
  padding: 5px 7px;
  text-decoration: none;
  border-radius: 2px;
  font: bold 12px sans-serif;
  color: black;
  text-transform: uppercase;
}
#enquiries a:hover {
  background-color: #fff;
}

#embed { 
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 4;
  display: none;
}
#embed textarea { 
  position: absolute;
  top: 50%;
  left: 50%;
  width: 270px;
  height: 100px;
  word-break: break-word;
  margin-left: -158px;
  margin-top: -50px;
  font: 13px Monaco, monospace;
  padding: 20px;
}

#splash { 
  /* background: #fff; */
  background-image: -webkit-linear-gradient(bottom, rgb(255,229,237) 0%, rgb(224,255,233) 100%);
  z-index: 9999;
  position: fixed;
  z-index: 9999;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font: bold 12px sans-serif;
  flex-direction: column;
}
#warning-icon {
  width: 20px;
  margin: 0 auto;
  margin-bottom: 12px;
  display: block;
}
#accept { 
  display: inline-block;
  padding: 12px 20px;
  background: #000;
  color: #fff;
  text-decoration: none;
  margin-top: 15px;
  cursor: pointer;
  outline-offset: -2px;
  outline: 4px solid transparent;
}
#accept:hover { 
  outline: 4px solid #000;
  background-color: transparent;
  color: #000;
}

#about {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 4;
  display: none;
  padding: 20px;
  overflow-y: scroll;
}

.about-header h1 {
  font-size: 24px;
  text-align: center;
}

#about .about-container {
  margin: 0 auto;
  width: 60%;
  z-index: 10;
  background: #fff;
  padding: 10px;
  overflow: scroll;
}

#about .about-container h2 {
  margin: 0;
  padding: 0;
  font-size: 20px;
  border-bottom: 1px solid #cccccc59;
  padding-bottom: 8px;
}

.faq-item {
  padding: 8px;
}

.faq-item .faq-item-question {
  font-weight: bold;
}

#about-close {
    position: relative;
    float: right;
    display: inline-block;
    top: -10px;
    right: -10px;
    border: 1px solid #2a212124;
    padding: 5px 10px;
    font-size: 20px;
    cursor: pointer;
}

#share-buttons {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 4;
  display: none;
  padding: 20px;
  overflow-y: scroll; 
}

.share-container {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}

.share-buttons a, .share-buttons button {
  display: flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  padding: 8px 12px;
  border: none;
  background-color: #f0f0f0;
  color: #333;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
}

.share-buttons a:hover, .share-buttons button:hover {
  background-color: #e0e0e0;
}

.share-buttons i {
  font-size: 16px;
}

#share-container {
  width: 80%;
  margin: 0 auto;
  background: #fff;
  padding: 10px;
  min-height: 150px;
}

#share-container h2 {
  text-align: center;
  padding: 0;
  margin: 10px 0;
}

.share-buttons-list {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-content: flex-start;
  gap: 10px;
}


@media (max-width: 768px) {
  #about div.about-container {
    width: 90%;
  }
  
  div#share-container {
    width: 95%;
  }
}

/* div#splash {
  height: 200px;
  top: unset;
  padding: 0;
  box-shadow: rgba(0, 0, 0, 0.3) 0px 19px 38px, rgba(0, 0, 0, 0.22) 0px 15px 12px;
} */


#soundBtn {
  font-size: 16px;
  border: none;
  background: transparent;
  cursor: pointer;
  transition: color 0.3s;
}

#soundBtn:hover {
  color: green;
}

#ads-bottom {
    background-color: transparent;
    display: flex;
    position: fixed;
    bottom: 10px;
    right: 10px;
    max-width: 355px;
    max-height: 100px;
    background-color: #fafafa;
    box-shadow: 0 6px 8px rgba(102, 119, 136, .03), 0 1px 2px rgba(102, 119, 136, .3);
    animation: scale-up-center .4s cubic-bezier(.39,.575,.565,1) both;
    z-index: 20;
    border-radius: .5rem;
}

ins.adsbygoogle[data-ad-status="unfilled"] {
    display: none !important;
}
/* wormid info panel */
#wormid-config {
  display: none;
}

#wormid-config + canvas {
  position: relative;
}

#wormid-config {
  pointer-events: none;
}

#enquiries.wormid-top-panel {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 7px;
  max-width: min(760px, calc(100vw - 35px));
}

#enquiries.wormid-top-panel a,
#enquiries.wormid-top-panel button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-height: 30px;
  padding: 6px 9px;
  border: 2px solid rgba(0, 0, 0, 0.9);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: #000;
  text-decoration: none;
  font: 800 11px/1 sans-serif;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  box-shadow: 0 4px 0 rgba(0,0,0,0.15);
  backdrop-filter: blur(8px);
  cursor: pointer;
}

#enquiries.wormid-top-panel a:hover,
#enquiries.wormid-top-panel button:hover,
#enquiries.wormid-top-panel button.copied {
  background: #000;
  color: #fff;
}

.ca-button {
  appearance: none;
  border: 2px solid #000;
  border-radius: 14px;
  background: #fff;
  color: #000;
  cursor: pointer;
  font: 800 12px/1.15 sans-serif;
  text-transform: uppercase;
}

.ca-button small {
  font-size: 9px;
  opacity: 0.7;
  margin-left: 3px;
}

.ca-short {
  display: inline-block;
  max-width: 130px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#about .about-container {
  max-width: 760px;
  border: 4px solid #000;
  border-radius: 18px;
  box-shadow: 0 18px 60px rgba(0,0,0,0.35);
}

.about-header p {
  font: 14px/1.5 sans-serif;
}

.project-info-card {
  margin: 16px 0;
  padding: 14px;
  border: 2px solid #000;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(255,255,255,0.95), rgba(224,255,233,0.95));
}

.project-links-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.project-links-list a,
.project-links-list button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 10px 13px;
  border: 2px solid #000;
  border-radius: 12px;
  background: #fff;
  color: #000;
  text-decoration: none;
  font: 800 13px/1.15 sans-serif;
  cursor: pointer;
}

.project-links-list a:hover,
.project-links-list button:hover,
.project-links-list button.copied {
  background: #000;
  color: #fff;
}

.ca-button-wide {
  max-width: 100%;
  word-break: break-all;
  text-align: left;
  text-transform: none;
}

@media (max-width: 768px) {
  #enquiries.wormid-top-panel {
    top: 10px;
    right: 10px;
    max-width: calc(100vw - 20px);
    gap: 5px;
  }

  #enquiries.wormid-top-panel a,
  #enquiries.wormid-top-panel button {
    min-height: 26px;
    padding: 5px 7px;
    font-size: 10px;
  }

  .project-links-list {
    flex-direction: column;
  }
}
