@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@400;500;700&family=DM+Mono:wght@400;500&display=swap');

.construction-counter {
  font-family: 'Noto Sans JP', sans-serif;
  background: #f7f6f3;
  color: #1a1a1a;
  padding: 3rem 1rem;
}

.construction-counter *,
.construction-counter *::before,
.construction-counter *::after {
  box-sizing: border-box;
}

.construction-counter .cc-wrapper {
  width: 100%;
  max-width: 860px;
  margin: 0 auto;
}

.construction-counter .cc-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.construction-counter .cc-eyebrow {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: #00183f;
  text-transform: uppercase;
  border: 1.5px solid #00183f;
  padding: 4px 14px;
  border-radius: 2px;
  margin-bottom: 1rem;
}

.construction-counter .cc-title {
  font-size: clamp(22px, 4vw, 32px);
  font-weight: 700;
  color: #1a1a1a;
  line-height: 1.3;
  margin-bottom: 0.5rem;
}

.construction-counter .cc-period {
  font-size: 14px;
  color: #888;
  font-family: 'DM Mono', monospace;
  letter-spacing: 0.04em;
}

.construction-counter .cc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 2.5rem;
}

.construction-counter .cc-card {
  background: #ffffff;
  border: 1px solid #e0ddd6;
  border-radius: 8px;
  padding: 1.7rem 1.25rem 1.4rem;
  position: relative;
  overflow: hidden;
  text-align: center;
  opacity: 0;
  transform: translateY(12px);
  animation: cc-fadeup 0.6s ease forwards;
}

.construction-counter .cc-card:nth-child(1) {
  animation-delay: 0.1s;
}

.construction-counter .cc-card:nth-child(2) {
  animation-delay: 0.25s;
}

.construction-counter .cc-card:nth-child(3) {
  animation-delay: 0.4s;
}

@keyframes cc-fadeup {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.construction-counter .cc-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: #00183f;
  transform: scaleX(0);
  transform-origin: left;
  animation: cc-line 0.6s ease forwards;
}

.construction-counter .cc-card:nth-child(1)::after {
  animation-delay: 0.5s;
}

.construction-counter .cc-card:nth-child(2)::after {
  animation-delay: 0.65s;
}

.construction-counter .cc-card:nth-child(3)::after {
  animation-delay: 0.8s;
}

@keyframes cc-line {
  to {
    transform: scaleX(1);
  }
}

.construction-counter .cc-card-icon {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: #2d5fa6;
  text-transform: uppercase;
  margin-bottom: 0.9rem;
}

.construction-counter .cc-card-number {
  font-family: 'DM Mono', monospace;
  font-size: clamp(36px, 6vw, 52px);
  font-weight: 500;
  color: #00183f;
  line-height: 1;
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 6px;
}

.construction-counter .cc-num {
  display: inline-block;
  letter-spacing: 0.02em;
  opacity: 0;
  transform: scale(0.8);
  animation: cc-popin 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.construction-counter .cc-card:nth-child(1) .cc-num {
  animation-delay: 0.3s;
}

.construction-counter .cc-card:nth-child(2) .cc-num {
  animation-delay: 0.45s;
}

.construction-counter .cc-card:nth-child(3) .cc-num {
  animation-delay: 0.6s;
}

@keyframes cc-popin {
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.construction-counter .cc-unit {
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 17px;
  font-weight: 700;
  color: #555;
}

.construction-counter .cc-card-label {
  font-size: 13px;
  color: #777;
  margin-top: 12px;
  line-height: 1.5;
}

.construction-counter .cc-yearly {
  background: #ffffff;
  border: 1px solid #e0ddd6;
  border-radius: 8px;
  padding: 1.5rem 1.5rem 1.25rem;
}

.construction-counter .cc-yearly-title {
  font-size: 13px;
  font-weight: 700;
  color: #555;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

.construction-counter .cc-bar-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.construction-counter .cc-bar-year {
  font-family: 'DM Mono', monospace;
  font-size: 13px;
  color: #888;
  width: 40px;
  flex-shrink: 0;
}

.construction-counter .cc-bar-track {
  flex: 1;
  height: 10px;
  background: #dce6f5;
  border-radius: 2px;
  overflow: hidden;
  position: relative;
}

.construction-counter .cc-bar-track::before {
  content: "";
  display: block;
  height: 100%;
  width: 0;
  background: #00183f;
  border-radius: 2px;
}

.construction-counter.is-visible .cc-bar-track::before {
  animation: cc-bar-grow 1.2s ease forwards;
}

@keyframes cc-bar-grow {
  from {
    width: 0;
  }

  to {
    width: var(--bar-width, 0%);
  }
}

.construction-counter .cc-bar-val {
  font-family: 'DM Mono', monospace;
  font-size: 13px;
  color: #555;
  width: 64px;
  text-align: right;
  flex-shrink: 0;
}

.construction-counter .cc-updated {
  text-align: center;
  margin-top: 1.5rem;
  font-size: 12px;
  color: #888;
  font-family: 'DM Mono', monospace;
}

@media (max-width: 600px) {
  .construction-counter {
    padding: 2.25rem 1rem;
  }

  .construction-counter .cc-grid {
    grid-template-columns: 1fr;
  }

  .construction-counter .cc-yearly {
    padding: 1.25rem 1rem;
  }

  .construction-counter .cc-bar-row {
    gap: 8px;
  }

  .construction-counter .cc-bar-year {
    width: 36px;
  }

  .construction-counter .cc-bar-val {
    width: 58px;
    font-size: 12px;
  }
}