.demo-counter {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.25rem;
  padding: 1.25rem 1.5rem;
  border-radius: 1rem;
  border: 1px solid var(--border-color);
  background: var(--context-bg);
  box-shadow: 0 8px 24px #0f172a14;
  transition: transform .12s ease, box-shadow .12s ease
}

.demo-counter:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px #0f172a1f
}

.demo-counter__meta {
  display: flex;
  flex-direction: column;
  gap: .35rem;
  min-width: 7.5rem
}

.demo-counter__eyebrow {
  margin: 0;
  font-size: .75rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text-color-highlight)
}

.demo-counter__value {
  margin: 0;
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.1;
  color: var(--highlight-color)
}

.demo-counter__controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .75rem;
  margin-left: auto
}

.demo-counter__label {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font-weight: 500;
  color: var(--secondary-color)
}

.demo-counter__select {
  appearance: none;
  padding: .35rem .85rem;
  border-radius: .65rem;
  border: 1px solid var(--border-color);
  background: var(--secondary-bg);
  color: var(--main-color);
  font-weight: 500;
  cursor: pointer;
  transition: border-color .12s ease, box-shadow .12s ease
}

.demo-counter__select:focus-visible {
  outline: 2px solid transparent;
  border-color: var(--highlight-color);
  box-shadow: 0 0 0 4px #eb861d29
}

.demo-counter__buttons {
  display: inline-flex;
  gap: .5rem
}

.demo-counter__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .45rem .95rem;
  border-radius: .75rem;
  border: 1px solid var(--highlight-color);
  background: var(--highlight-color);
  color: #1c1c1c;
  font-weight: 600;
  cursor: pointer;
  transition: transform .12s ease, box-shadow .12s ease
}

.demo-counter__button:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 20px #0f172a24
}

.demo-counter__button:active {
  transform: none;
  box-shadow: none
}

.demo-counter__button--ghost {
  background: 0 0;
  color: var(--main-color)
}

.demo-counter__button--ghost:hover {
  background: #eb861d14
}

@media (max-width:640px) {
  .demo-counter {
    justify-content: center;
    text-align: center
  }

  .demo-counter__controls {
    justify-content: center;
    margin-left: 0
  }
}

html.dark-mode .demo-counter {
  background: var(--secondary-bg);
  box-shadow: 0 8px 24px #00000047
}
