html, body {
  margin: 0;
  overflow: hidden;
}

.stage {
  box-sizing: border-box;
  min-height: 100vh;
  display: grid;
  place-items: center;
  margin: 0;
  background: #ffd23f;
  font-family: -apple-system, "Segoe UI", "Noto Sans KR", sans-serif;
  padding: clamp(8px, 4vw, 24px);
}

.tb {
  position: relative;
  box-sizing: border-box;
  width: min(300px, 92vw);
  border-radius: 16px;
  background: #fff7e6;
  color: #17141a;
  font-family: -apple-system, "Segoe UI", "Noto Sans KR", sans-serif;
  overflow: hidden;
}

.tb__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 12px 0;
}

.tb__title {
  margin: 0;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.3;
}

.tb__state {
  margin: 0;
  font-size: 10px;
  line-height: 1.3;
  color: rgba(23, 20, 26, 0.72);
}

.tb__view {
  box-sizing: border-box;
  height: 112px;
  margin: 8px 8px 8px;
  padding: 0 8px 0 0;
  overflow-y: auto;
  scrollbar-width: none;
}

.tb__view::-webkit-scrollbar {
  display: none;
}

.tb__view:focus-visible {
  outline: 2px solid #17141a;
  outline-offset: 2px;
}

.tb__list {
  display: grid;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.tb__row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 8px;
  border-radius: 8px;
  background: rgba(23, 20, 26, 0.05);
  font-size: 11px;
  line-height: 1.35;
}

.tb__row b {
  font-size: 10px;
  opacity: 0.72;
}

.tb__bar {
  position: absolute;
  right: 8px;
  bottom: 8px;
  display: flex;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  background: #17141a;
  box-shadow: 0 6px 12px rgba(23, 20, 26, 0.32);
  transition: transform 220ms cubic-bezier(0.2, 0.8, 0.2, 1), opacity 140ms linear;
}

.tb__fab {
  display: inline-grid;
  place-items: center;
  width: 32px;
  height: 32px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #ffd23f;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  transition: transform 140ms ease-out;
}

.tb__fab:focus-visible {
  outline: 2px solid #ffd23f;
  outline-offset: 1px;
}

.tb__fab:active {
  transform: scale(0.88);
}

.tb.is-hidden .tb__bar {
  transform: translateY(150%);
  opacity: 0;
}

@keyframes tb-flow {
  0% {
    transform: translateY(0);
  }
  34% {
    transform: translateY(-44%);
  }
  44% {
    transform: translateY(-44%);
  }
  82%, 100% {
    transform: translateY(0);
  }
}
@keyframes tb-hide {
  0%, 30% {
    transform: translateY(0);
    opacity: 1;
  }
  34% {
    opacity: 0;
  }
  34.01%, 43% {
    transform: translateY(150%);
    opacity: 0;
  }
  47% {
    opacity: 1;
  }
  47.01%, 92% {
    transform: translateY(0);
    opacity: 1;
  }
  94%, 100% {
    transform: translateY(0);
    opacity: 1;
  }
}
@keyframes tb-note {
  0%, 31% {
    opacity: 1;
  }
  32%, 90% {
    opacity: 0.35;
  }
  91%, 100% {
    opacity: 1;
  }
}
.tb.is-demo .tb__list {
  animation-name: tb-flow;
  animation-duration: 2s;
  animation-timing-function: ease-out;
  animation-iteration-count: infinite;
}
.tb.is-demo .tb__bar {
  animation-name: tb-hide;
  animation-duration: 2s;
  animation-timing-function: cubic-bezier(0.2, 0.8, 0.2, 1);
  animation-iteration-count: infinite;
}
.tb.is-demo .tb__state {
  animation-name: tb-note;
  animation-duration: 2s;
  animation-timing-function: steps(1, end);
  animation-iteration-count: infinite;
}

@media (max-width: 340px) {
  .tb__view {
    height: 96px;
  }
  .tb__row {
    font-size: 10px;
  }
  .tb__fab {
    width: 28px;
    height: 28px;
    font-size: 14px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .tb.is-demo .tb__list,
  .tb.is-demo .tb__bar,
  .tb.is-demo .tb__state {
    animation: none !important;
    transform: none !important;
  }
  .tb.is-demo .tb__bar {
    opacity: 1 !important;
  }
  .tb.is-demo .tb__state {
    opacity: 1 !important;
  }
}
