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

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

.rc {
  box-sizing: border-box;
  width: min(320px, 90vw);
  color: #17141a;
  font-family: -apple-system, "Segoe UI", "Noto Sans KR", sans-serif;
}

.rc__head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 8px;
}

.rc__ico {
  display: inline-flex;
  opacity: 0.8;
}

.rc__title {
  font-size: clamp(11px, 3.4vw, 14px);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.rc__out {
  margin-left: auto;
  padding: 0 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  font-size: clamp(9px, 2.6vw, 11px);
  font-weight: 700;
  line-height: 1.6;
  white-space: nowrap;
}

.rc__dow {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin: 0 0 4px;
  font-size: clamp(8px, 2.4vw, 10px);
  font-weight: 700;
  text-align: center;
  color: #17141a;
}

.rc__grid {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.rc__r {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.rc__c {
  box-sizing: border-box;
  height: clamp(20px, 6.4vw, 30px);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.14);
  color: #17141a;
  font-size: clamp(9px, 2.9vw, 12px);
  font-weight: 600;
  cursor: pointer;
  user-select: none;
  touch-action: none;
  transition: background 220ms cubic-bezier(0.2, 0.8, 0.2, 1), color 220ms cubic-bezier(0.2, 0.8, 0.2, 1), border-radius 220ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.rc__c.is-out {
  opacity: 0.4;
}

.rc__c.is-today {
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.7);
}

.rc__c:focus-visible {
  outline: 2px solid #fff7e6;
  outline-offset: 2px;
}

.rc__c.is-in {
  background: #fff7e6;
  color: #c93000;
  border-radius: 0;
}

.rc__c.is-start {
  border-radius: 8px 0 0 8px;
}

.rc__c.is-end {
  border-radius: 0 8px 8px 0;
}

.rc__c.is-start.is-end {
  border-radius: 8px;
}

.rc.is-demo .rc__c.d {
  animation-duration: 2s;
  animation-timing-function: ease-out;
  animation-iteration-count: infinite;
  animation-fill-mode: backwards;
}

.rc.is-demo .d1 {
  animation-name: rc-l;
  animation-delay: 0s;
}

.rc.is-demo .d2 {
  animation-name: rc-m;
  animation-delay: 0.09s;
}

.rc.is-demo .d3 {
  animation-name: rc-m;
  animation-delay: 0.18s;
}

.rc.is-demo .d4 {
  animation-name: rc-m;
  animation-delay: 0.27s;
}

.rc.is-demo .d5 {
  animation-name: rc-m;
  animation-delay: 0.36s;
}

.rc.is-demo .d6 {
  animation-name: rc-m;
  animation-delay: 0.45s;
}

.rc.is-demo .d7 {
  animation-name: rc-r;
  animation-delay: 0.54s;
}

@keyframes rc-l {
  0%, 6% {
    background: rgba(255, 255, 255, 0.14);
    color: #fff7e6;
    border-radius: 8px;
  }
  14%, 46% {
    background: #fff7e6;
    color: #ff4d1f;
    border-radius: 8px 0 0 8px;
  }
  54%, 100% {
    background: rgba(255, 255, 255, 0.14);
    color: #fff7e6;
    border-radius: 8px;
  }
}
@keyframes rc-m {
  0%, 6% {
    background: rgba(255, 255, 255, 0.14);
    color: #fff7e6;
    border-radius: 8px;
  }
  14%, 46% {
    background: #fff7e6;
    color: #ff4d1f;
    border-radius: 0;
  }
  54%, 100% {
    background: rgba(255, 255, 255, 0.14);
    color: #fff7e6;
    border-radius: 8px;
  }
}
@keyframes rc-r {
  0%, 6% {
    background: rgba(255, 255, 255, 0.14);
    color: #fff7e6;
    border-radius: 8px;
  }
  14%, 46% {
    background: #fff7e6;
    color: #ff4d1f;
    border-radius: 0 8px 8px 0;
  }
  54%, 100% {
    background: rgba(255, 255, 255, 0.14);
    color: #fff7e6;
    border-radius: 8px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .rc.is-demo .rc__c.d {
    animation: none !important;
  }
  .rc__c {
    transition: none;
  }
}
