{
  "id": "otp-input",
  "name": "OTP Code Input",
  "category": "forms",
  "tags": [
    "otp",
    "code",
    "verification",
    "pin",
    "2fa",
    "input"
  ],
  "description": "Boxed one-time-code inputs for verification and two-factor screens.",
  "url": "https://copy-css.com/snippets/otp-input",
  "markdown": "https://copy-css.com/snippets/otp-input.md",
  "html": "<div class=\"otp\">\n  <input type=\"text\" inputmode=\"numeric\" maxlength=\"1\" value=\"4\" aria-label=\"Digit 1\">\n  <input type=\"text\" inputmode=\"numeric\" maxlength=\"1\" value=\"2\" aria-label=\"Digit 2\">\n  <input type=\"text\" inputmode=\"numeric\" maxlength=\"1\" aria-label=\"Digit 3\">\n  <input type=\"text\" inputmode=\"numeric\" maxlength=\"1\" aria-label=\"Digit 4\">\n</div>",
  "css": ".otp {\n  display: flex;\n  gap: 10px;\n}\n\n.otp input {\n  box-sizing: border-box;\n  width: 46px;\n  height: 56px;\n  border: 1.5px solid #d1d5db;\n  border-radius: 12px;\n  background: #fff;\n  color: #111;\n  caret-color: #6366f1;\n  font: 700 22px system-ui, sans-serif;\n  text-align: center;\n  outline: none;\n  transition: border-color 0.15s ease, box-shadow 0.15s ease;\n}\n\n.otp input:focus {\n  border-color: #6366f1;\n  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.15);\n}",
  "features": [
    "transitions",
    "box shadows",
    "Flexbox"
  ],
  "customProperties": []
}
