{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://dtif.lapidist.net/schema/core.json",
  "title": "Design Token Interchange Format",
  "type": "object",
  "properties": {
    "$schema": {
      "type": "string",
      "title": "Schema declaration",
      "description": "Optional JSON Schema identifier that helps tooling discover compatible vocabularies.",
      "$comment": "Format and serialisation §format: documents MAY declare $schema for tooling introspection."
    },
    "$description": {
      "$ref": "#/$defs/metadata-members/properties/$description"
    },
    "$version": {
      "type": "string",
      "title": "Document version",
      "description": "Semantic Versioning identifier for the token document per Architecture and model §versioning.",
      "$comment": "Architecture and model §versioning.",
      "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-(?:0|[1-9]\\d*|[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|[a-zA-Z-][0-9a-zA-Z-]*))*)?(?:\\+[0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*)?$"
    },
    "$extensions": {
      "title": "Document extensions",
      "description": "Namespaced metadata that applies to the entire document per Format and serialisation §$extensions.",
      "$comment": "Format and serialisation §$extensions.",
      "allOf": [
        {
          "$ref": "#/$defs/extensions"
        }
      ]
    },
    "$overrides": {
      "title": "Overrides",
      "description": "Conditional overrides evaluated in order per Theming and overrides §$overrides.",
      "$comment": "Theming and overrides §$overrides.",
      "type": "array",
      "items": {
        "$ref": "#/$defs/override"
      }
    }
  },
  "allOf": [
    {
      "$ref": "#/$defs/token-members"
    }
  ],
  "unevaluatedProperties": false,
  "$defs": {
    "token-members": {
      "title": "Token member map",
      "description": "Tree of design token or collection entries keyed by names that do not begin with $.",
      "$comment": "Architecture and model §tokens-and-collections: document members other than $-prefixed metadata are tokens or nested collections.",
      "type": "object",
      "patternProperties": {
        "^(?!\\$)": {
          "$ref": "#/$defs/node"
        }
      }
    },
    "pointer": {
      "title": "DTIF pointer reference",
      "description": "JSON Pointer string optionally prefixed by a relative path or HTTP(S) URI with a fragment per Format and serialisation §$ref.",
      "type": "string",
      "allOf": [
        {
          "$comment": "RFC 6901 pointer grammar with mandatory # fragment (Format and serialisation §$ref).",
          "pattern": "^(?:#|[^#]+#)(?:\\/[^~\\/]*(?:~[01][^~\\/]*)*)*$",
          "type": "string"
        },
        {
          "$comment": "External references MUST use relative paths or HTTP(S) URIs, so absolute and network-path references are invalid (Format and serialisation §$ref).",
          "not": {
            "pattern": "^(?:\\/|\\\\|\\/\\/|\\\\\\\\)",
            "type": "string"
          }
        },
        {
          "$comment": "Directory traversal segments ../ at the start of the path are invalid (Format and serialisation §$ref step 1).",
          "not": {
            "pattern": "^\\.\\.(?:\\/|\\\\|%2[fF]|%5[cC]|\\?|#|$)",
            "type": "string"
          }
        },
        {
          "$comment": "Directory traversal segments ../ inside the path before the fragment are invalid (Format and serialisation §$ref step 1).",
          "not": {
            "pattern": "^[^#]*(?:\\/|\\\\)\\.\\.(?:\\/|\\\\|%2[fF]|%5[cC]|\\?|#|$)",
            "type": "string"
          }
        },
        {
          "$comment": "Percent-encoded or mixed-encoding .. segments such as %2e%2e/, %2e./, or .%2e/ are rejected (Format and serialisation §$ref step 1).",
          "not": {
            "pattern": "^(?:%2[eE]%2[eE]|%2[eE]\\.|\\.%2[eE])(?:\\/|\\\\|%2[fF]|%5[cC]|\\?|#|$)",
            "type": "string"
          }
        },
        {
          "$comment": "Percent-encoded or mixed-encoding .. segments after directory boundaries are rejected (Format and serialisation §$ref step 1).",
          "not": {
            "pattern": "^[^#]*(?:\\/|\\\\)(?:%2[eE]%2[eE]|%2[eE]\\.|\\.%2[eE])(?:\\/|\\\\|%2[fF]|%5[cC]|\\?|#|$)",
            "type": "string"
          }
        },
        {
          "if": {
            "pattern": "^[a-zA-Z][a-zA-Z0-9+.-]*://",
            "type": "string"
          },
          "then": {
            "pattern": "^https?://",
            "type": "string"
          }
        }
      ]
    },
    "local-pointer": {
      "title": "Local JSON Pointer reference",
      "description": "JSON Pointer fragment that targets the current document per Metadata §metadata.",
      "allOf": [
        {
          "$ref": "#/$defs/pointer"
        },
        {
          "pattern": "^#",
          "type": "string",
          "$comment": "Metadata §metadata: $deprecated.$replacement is a JSON Pointer and must target the current document."
        }
      ]
    },
    "reference": {
      "title": "Pointer alias",
      "description": "Object aliasing another token via $ref per Token types §value.",
      "$comment": "Token types §value: alias objects contain only $ref and MUST resolve to the same $type.",
      "type": "object",
      "required": ["$ref"],
      "properties": {
        "$ref": {
          "title": "Alias target",
          "description": "Pointer to the referenced token per Format and serialisation §$ref.",
          "allOf": [
            {
              "$ref": "#/$defs/pointer"
            }
          ]
        }
      },
      "additionalProperties": false
    },
    "nonEmptyArray": {
      "title": "Non-empty array",
      "description": "Array containing at least one candidate per Token types §value fallback semantics.",
      "$comment": "Token types §value: fallback arrays MUST provide at least one entry.",
      "type": "array",
      "minItems": 1
    },
    "colorReference": {
      "title": "Color literal or alias",
      "description": "Inline colour payload or $ref alias per Token types §color and Format and serialisation §$ref.",
      "$comment": "Token types §color: $value entries MAY embed literal colour objects or $ref aliases that resolve to the same $type.",
      "oneOf": [
        {
          "$ref": "#/$defs/color"
        },
        {
          "$ref": "#/$defs/reference"
        }
      ]
    },
    "dimensionReference": {
      "title": "Dimension literal or alias",
      "description": "Inline dimension measurement or $ref alias per Token types §dimension and Format and serialisation §$ref.",
      "$comment": "Token types §dimension: $value entries MAY embed literal measurements or $ref aliases that resolve to the same $type.",
      "oneOf": [
        {
          "$ref": "#/$defs/dimension"
        },
        {
          "$ref": "#/$defs/reference"
        }
      ]
    },
    "fontDimensionReference": {
      "title": "Font dimension literal or alias",
      "description": "Font-specific length measurement or $ref alias per Typography §font-dimensions and Format and serialisation §$ref.",
      "$comment": "Typography §font-dimensions and §font-face: values MAY embed inline font measurements or alias another token with the same $type.",
      "allOf": [
        {
          "$ref": "#/$defs/font-dimension"
        }
      ]
    },
    "lengthDimensionReference": {
      "title": "Length dimension literal or alias",
      "description": "Length measurement or $ref alias per Token types §dimension (length) and Format and serialisation §$ref.",
      "$comment": "Token types §dimension: length measurements MAY be serialized inline or referenced via $ref.",
      "oneOf": [
        {
          "$ref": "#/$defs/length-dimension"
        },
        {
          "$ref": "#/$defs/reference"
        }
      ]
    },
    "angleDimensionReference": {
      "title": "Angle dimension literal or alias",
      "description": "Angle measurement or $ref alias per Token types §dimension (angle) and Format and serialisation §$ref.",
      "$comment": "Token types §dimension: angle measurements MAY be serialized inline or referenced via $ref.",
      "oneOf": [
        {
          "$ref": "#/$defs/angle-dimension"
        },
        {
          "$ref": "#/$defs/reference"
        }
      ]
    },
    "css-ident": {
      "title": "CSS identifier",
      "description": "Identifier matching the CSS <ident> or <dashed-ident> grammar per CSS Values and Units §css-identifier-syntax.",
      "type": "string",
      "pattern": "^-{0,2}(?:[A-Za-z_]|[^\\x00-\\x7F]|\\\\[0-9A-Fa-f]{1,6}(?:\\r\\n|[ \\t\\n\\r\\f])?|\\\\[^\\r\\n\\f0-9A-Fa-f])(?:[A-Za-z0-9_-]|[^\\x00-\\x7F]|\\\\[0-9A-Fa-f]{1,6}(?:\\r\\n|[ \\t\\n\\r\\f])?|\\\\[^\\r\\n\\f0-9A-Fa-f])*$",
      "$comment": "MUST conform to CSS <ident> / <dashed-ident> productions including Unicode escapes (css-values-4, css-syntax-3)."
    },
    "css-family-name": {
      "title": "CSS family name",
      "description": "Font family string following the CSS <family-name> grammar per CSS Fonts Module Level 4 §font-family-names.",
      "$comment": "Typography §font and §font-face: fontFamily, family, and fallback strings MUST follow the CSS <family-name> production allowing quoted names or sequences of <ident> tokens.",
      "type": "string",
      "minLength": 1,
      "anyOf": [
        {
          "pattern": "^(?:\"(?:[^\"\\\\]|\\\\.)+\"|'(?:[^'\\\\]|\\\\.)+')$",
          "description": "Quoted CSS <string> production allowing escaped characters.",
          "title": "Quoted family name",
          "type": "string"
        },
        {
          "pattern": "^-{0,2}(?:[A-Za-z_]|[^\\x00-\\x7F]|\\\\[0-9A-Fa-f]{1,6}(?:\\r\\n|[ \\t\\n\\r\\f])?|\\\\[^\\r\\n\\f0-9A-Fa-f])(?:[A-Za-z0-9_-]|[^\\x00-\\x7F]|\\\\[0-9A-Fa-f]{1,6}(?:\\r\\n|[ \\t\\n\\r\\f])?|\\\\[^\\r\\n\\f0-9A-Fa-f])*(?:[ \\t]+-{0,2}(?:[A-Za-z_]|[^\\x00-\\x7F]|\\\\[0-9A-Fa-f]{1,6}(?:\\r\\n|[ \\t\\n\\r\\f])?|\\\\[^\\r\\n\\f0-9A-Fa-f])(?:[A-Za-z0-9_-]|[^\\x00-\\x7F]|\\\\[0-9A-Fa-f]{1,6}(?:\\r\\n|[ \\t\\n\\r\\f])?|\\\\[^\\r\\n\\f0-9A-Fa-f])*)*$",
          "description": "Unquoted sequence of one or more CSS <ident> tokens separated by ASCII whitespace.",
          "title": "Unquoted family name",
          "type": "string"
        }
      ]
    },
    "text-decoration-shorthand": {
      "title": "Text decoration shorthand",
      "description": "CSS text-decoration shorthand accepting line, style, colour, and thickness components per Typography §text-decoration and CSS Text Decoration Module Level 4.",
      "$comment": "Typography §text-decoration: serialised strings MUST follow the CSS text-decoration grammar, including named colours, system colours, calc()/var() functions, and <length-percentage> thickness values.",
      "type": "string",
      "pattern": "^(?:(?:[Ii][Nn][Hh][Ee][Rr][Ii][Tt]|[Ii][Nn][Ii][Tt][Ii][Aa][Ll]|[Uu][Nn][Ss][Ee][Tt]|[Rr][Ee][Vv][Ee][Rr][Tt](?:-[Ll][Aa][Yy][Ee][Rr])?)|(?:(?:(?:[Nn][Oo][Nn][Ee]|[Uu][Nn][Dd][Ee][Rr][Ll][Ii][Nn][Ee]|[Oo][Vv][Ee][Rr][Ll][Ii][Nn][Ee]|[Ll][Ii][Nn][Ee]-[Tt][Hh][Rr][Oo][Uu][Gg][Hh]|[Bb][Ll][Ii][Nn][Kk]|[Ss][Pp][Ee][Ll][Ll][Ii][Nn][Gg]-[Ee][Rr][Rr][Oo][Rr]|[Gg][Rr][Aa][Mm][Mm][Aa][Rr]-[Ee][Rr][Rr][Oo][Rr])|(?:[Ss][Oo][Ll][Ii][Dd]|[Dd][Oo][Uu][Bb][Ll][Ee]|[Dd][Oo][Tt][Tt][Ee][Dd]|[Dd][Aa][Ss][Hh][Ee][Dd]|[Ww][Aa][Vv][Yy])|(?:[Tt][Hh][Ii][Nn]|[Mm][Ee][Dd][Ii][Uu][Mm]|[Tt][Hh][Ii][Cc][Kk]|[Aa][Uu][Tt][Oo]|[Ff][Rr][Oo][Mm]-[Ff][Oo][Nn][Tt])|(?:[-+]?(?:\\d+(?:\\.\\d+)?|\\.\\d+)(?:[Ee][+-]?\\d+)?(?:%|[A-Za-z][A-Za-z0-9-]*))|(?:[-+]?0+(?:\\.0+)?)|(?:#(?:[0-9A-Fa-f]{3}|[0-9A-Fa-f]{4}|[0-9A-Fa-f]{6}|[0-9A-Fa-f]{8}))|(?:[A-Za-z][A-Za-z0-9-]*\\((?:[^()]|\\((?:[^()]|\\([^()]*\\))*\\))*\\))|(?:[aA][cC][cC][eE][nN][tT][cC][oO][lL][oO][rR]|[aA][cC][cC][eE][nN][tT][cC][oO][lL][oO][rR][tT][eE][xX][tT]|[aA][cC][tT][iI][vV][eE][bB][oO][rR][dD][eE][rR]|[aA][cC][tT][iI][vV][eE][cC][aA][pP][tT][iI][oO][nN]|[aA][cC][tT][iI][vV][eE][tT][eE][xX][tT]|[aA][lL][iI][cC][eE][bB][lL][uU][eE]|[aA][nN][tT][iI][qQ][uU][eE][wW][hH][iI][tT][eE]|[aA][pP][pP][wW][oO][rR][kK][sS][pP][aA][cC][eE]|[aA][qQ][uU][aA]|[aA][qQ][uU][aA][mM][aA][rR][iI][nN][eE]|[aA][zZ][uU][rR][eE]|[bB][aA][cC][kK][gG][rR][oO][uU][nN][dD]|[bB][eE][iI][gG][eE]|[bB][iI][sS][qQ][uU][eE]|[bB][lL][aA][cC][kK]|[bB][lL][aA][nN][cC][hH][eE][dD][aA][lL][mM][oO][nN][dD]|[bB][lL][uU][eE]|[bB][lL][uU][eE][vV][iI][oO][lL][eE][tT]|[bB][rR][oO][wW][nN]|[bB][uU][rR][lL][yY][wW][oO][oO][dD]|[bB][uU][tT][tT][oO][nN][bB][oO][rR][dD][eE][rR]|[bB][uU][tT][tT][oO][nN][fF][aA][cC][eE]|[bB][uU][tT][tT][oO][nN][hH][iI][gG][hH][lL][iI][gG][hH][tT]|[bB][uU][tT][tT][oO][nN][sS][hH][aA][dD][oO][wW]|[bB][uU][tT][tT][oO][nN][tT][eE][xX][tT]|[cC][aA][dD][eE][tT][bB][lL][uU][eE]|[cC][aA][nN][vV][aA][sS]|[cC][aA][nN][vV][aA][sS][tT][eE][xX][tT]|[cC][aA][pP][tT][iI][oO][nN][tT][eE][xX][tT]|[cC][hH][aA][rR][tT][rR][eE][uU][sS][eE]|[cC][hH][oO][cC][oO][lL][aA][tT][eE]|[cC][oO][rR][aA][lL]|[cC][oO][rR][nN][fF][lL][oO][wW][eE][rR][bB][lL][uU][eE]|[cC][oO][rR][nN][sS][iI][lL][kK]|[cC][rR][iI][mM][sS][oO][nN]|[cC][uU][rR][rR][eE][nN][tT][cC][oO][lL][oO][rR]|[cC][yY][aA][nN]|[dD][aA][rR][kK][bB][lL][uU][eE]|[dD][aA][rR][kK][cC][yY][aA][nN]|[dD][aA][rR][kK][gG][oO][lL][dD][eE][nN][rR][oO][dD]|[dD][aA][rR][kK][gG][rR][aA][yY]|[dD][aA][rR][kK][gG][rR][eE][eE][nN]|[dD][aA][rR][kK][gG][rR][eE][yY]|[dD][aA][rR][kK][kK][hH][aA][kK][iI]|[dD][aA][rR][kK][mM][aA][gG][eE][nN][tT][aA]|[dD][aA][rR][kK][oO][lL][iI][vV][eE][gG][rR][eE][eE][nN]|[dD][aA][rR][kK][oO][rR][aA][nN][gG][eE]|[dD][aA][rR][kK][oO][rR][cC][hH][iI][dD]|[dD][aA][rR][kK][rR][eE][dD]|[dD][aA][rR][kK][sS][aA][lL][mM][oO][nN]|[dD][aA][rR][kK][sS][eE][aA][gG][rR][eE][eE][nN]|[dD][aA][rR][kK][sS][lL][aA][tT][eE][bB][lL][uU][eE]|[dD][aA][rR][kK][sS][lL][aA][tT][eE][gG][rR][aA][yY]|[dD][aA][rR][kK][sS][lL][aA][tT][eE][gG][rR][eE][yY]|[dD][aA][rR][kK][tT][uU][rR][qQ][uU][oO][iI][sS][eE]|[dD][aA][rR][kK][vV][iI][oO][lL][eE][tT]|[dD][eE][eE][pP][pP][iI][nN][kK]|[dD][eE][eE][pP][sS][kK][yY][bB][lL][uU][eE]|[dD][iI][mM][gG][rR][aA][yY]|[dD][iI][mM][gG][rR][eE][yY]|[dD][oO][dD][gG][eE][rR][bB][lL][uU][eE]|[fF][iI][eE][lL][dD]|[fF][iI][eE][lL][dD][tT][eE][xX][tT]|[fF][iI][rR][eE][bB][rR][iI][cC][kK]|[fF][lL][oO][rR][aA][lL][wW][hH][iI][tT][eE]|[fF][oO][rR][eE][sS][tT][gG][rR][eE][eE][nN]|[fF][uU][cC][hH][sS][iI][aA]|[gG][aA][iI][nN][sS][bB][oO][rR][oO]|[gG][hH][oO][sS][tT][wW][hH][iI][tT][eE]|[gG][oO][lL][dD]|[gG][oO][lL][dD][eE][nN][rR][oO][dD]|[gG][rR][aA][yY]|[gG][rR][aA][yY][tT][eE][xX][tT]|[gG][rR][eE][eE][nN]|[gG][rR][eE][eE][nN][yY][eE][lL][lL][oO][wW]|[gG][rR][eE][yY]|[hH][iI][gG][hH][lL][iI][gG][hH][tT]|[hH][iI][gG][hH][lL][iI][gG][hH][tT][tT][eE][xX][tT]|[hH][oO][nN][eE][yY][dD][eE][wW]|[hH][oO][tT][pP][iI][nN][kK]|[iI][nN][aA][cC][tT][iI][vV][eE][bB][oO][rR][dD][eE][rR]|[iI][nN][aA][cC][tT][iI][vV][eE][cC][aA][pP][tT][iI][oO][nN]|[iI][nN][aA][cC][tT][iI][vV][eE][cC][aA][pP][tT][iI][oO][nN][tT][eE][xX][tT]|[iI][nN][dD][iI][aA][nN][rR][eE][dD]|[iI][nN][dD][iI][gG][oO]|[iI][nN][fF][oO][bB][aA][cC][kK][gG][rR][oO][uU][nN][dD]|[iI][nN][fF][oO][tT][eE][xX][tT]|[iI][vV][oO][rR][yY]|[kK][hH][aA][kK][iI]|[lL][aA][vV][eE][nN][dD][eE][rR]|[lL][aA][vV][eE][nN][dD][eE][rR][bB][lL][uU][sS][hH]|[lL][aA][wW][nN][gG][rR][eE][eE][nN]|[lL][eE][mM][oO][nN][cC][hH][iI][fF][fF][oO][nN]|[lL][iI][gG][hH][tT][bB][lL][uU][eE]|[lL][iI][gG][hH][tT][cC][oO][rR][aA][lL]|[lL][iI][gG][hH][tT][cC][yY][aA][nN]|[lL][iI][gG][hH][tT][gG][oO][lL][dD][eE][nN][rR][oO][dD][yY][eE][lL][lL][oO][wW]|[lL][iI][gG][hH][tT][gG][rR][aA][yY]|[lL][iI][gG][hH][tT][gG][rR][eE][eE][nN]|[lL][iI][gG][hH][tT][gG][rR][eE][yY]|[lL][iI][gG][hH][tT][pP][iI][nN][kK]|[lL][iI][gG][hH][tT][sS][aA][lL][mM][oO][nN]|[lL][iI][gG][hH][tT][sS][eE][aA][gG][rR][eE][eE][nN]|[lL][iI][gG][hH][tT][sS][kK][yY][bB][lL][uU][eE]|[lL][iI][gG][hH][tT][sS][lL][aA][tT][eE][gG][rR][aA][yY]|[lL][iI][gG][hH][tT][sS][lL][aA][tT][eE][gG][rR][eE][yY]|[lL][iI][gG][hH][tT][sS][tT][eE][eE][lL][bB][lL][uU][eE]|[lL][iI][gG][hH][tT][yY][eE][lL][lL][oO][wW]|[lL][iI][mM][eE]|[lL][iI][mM][eE][gG][rR][eE][eE][nN]|[lL][iI][nN][eE][nN]|[lL][iI][nN][kK][tT][eE][xX][tT]|[mM][aA][gG][eE][nN][tT][aA]|[mM][aA][rR][kK]|[mM][aA][rR][kK][tT][eE][xX][tT]|[mM][aA][rR][oO][oO][nN]|[mM][eE][dD][iI][uU][mM][aA][qQ][uU][aA][mM][aA][rR][iI][nN][eE]|[mM][eE][dD][iI][uU][mM][bB][lL][uU][eE]|[mM][eE][dD][iI][uU][mM][oO][rR][cC][hH][iI][dD]|[mM][eE][dD][iI][uU][mM][pP][uU][rR][pP][lL][eE]|[mM][eE][dD][iI][uU][mM][sS][eE][aA][gG][rR][eE][eE][nN]|[mM][eE][dD][iI][uU][mM][sS][lL][aA][tT][eE][bB][lL][uU][eE]|[mM][eE][dD][iI][uU][mM][sS][pP][rR][iI][nN][gG][gG][rR][eE][eE][nN]|[mM][eE][dD][iI][uU][mM][tT][uU][rR][qQ][uU][oO][iI][sS][eE]|[mM][eE][dD][iI][uU][mM][vV][iI][oO][lL][eE][tT][rR][eE][dD]|[mM][eE][nN][uU]|[mM][eE][nN][uU][tT][eE][xX][tT]|[mM][iI][dD][nN][iI][gG][hH][tT][bB][lL][uU][eE]|[mM][iI][nN][tT][cC][rR][eE][aA][mM]|[mM][iI][sS][tT][yY][rR][oO][sS][eE]|[mM][oO][cC][cC][aA][sS][iI][nN]|[nN][aA][vV][aA][jJ][oO][wW][hH][iI][tT][eE]|[nN][aA][vV][yY]|[nN][oO][nN][eE]|[oO][lL][dD][lL][aA][cC][eE]|[oO][lL][iI][vV][eE]|[oO][lL][iI][vV][eE][dD][rR][aA][bB]|[oO][rR][aA][nN][gG][eE]|[oO][rR][aA][nN][gG][eE][rR][eE][dD]|[oO][rR][cC][hH][iI][dD]|[pP][aA][lL][eE][gG][oO][lL][dD][eE][nN][rR][oO][dD]|[pP][aA][lL][eE][gG][rR][eE][eE][nN]|[pP][aA][lL][eE][tT][uU][rR][qQ][uU][oO][iI][sS][eE]|[pP][aA][lL][eE][vV][iI][oO][lL][eE][tT][rR][eE][dD]|[pP][aA][pP][aA][yY][aA][wW][hH][iI][pP]|[pP][eE][aA][cC][hH][pP][uU][fF][fF]|[pP][eE][rR][uU]|[pP][iI][nN][kK]|[pP][lL][uU][mM]|[pP][oO][wW][dD][eE][rR][bB][lL][uU][eE]|[pP][uU][rR][pP][lL][eE]|[rR][eE][bB][eE][cC][cC][aA][pP][uU][rR][pP][lL][eE]|[rR][eE][dD]|[rR][oO][sS][yY][bB][rR][oO][wW][nN]|[rR][oO][yY][aA][lL][bB][lL][uU][eE]|[sS][aA][dD][dD][lL][eE][bB][rR][oO][wW][nN]|[sS][aA][lL][mM][oO][nN]|[sS][aA][nN][dD][yY][bB][rR][oO][wW][nN]|[sS][cC][rR][oO][lL][lL][bB][aA][rR]|[sS][eE][aA][gG][rR][eE][eE][nN]|[sS][eE][aA][sS][hH][eE][lL][lL]|[sS][eE][lL][eE][cC][tT][eE][dD][iI][tT][eE][mM]|[sS][eE][lL][eE][cC][tT][eE][dD][iI][tT][eE][mM][tT][eE][xX][tT]|[sS][iI][eE][nN][nN][aA]|[sS][iI][lL][vV][eE][rR]|[sS][kK][yY][bB][lL][uU][eE]|[sS][lL][aA][tT][eE][bB][lL][uU][eE]|[sS][lL][aA][tT][eE][gG][rR][aA][yY]|[sS][lL][aA][tT][eE][gG][rR][eE][yY]|[sS][nN][oO][wW]|[sS][pP][rR][iI][nN][gG][gG][rR][eE][eE][nN]|[sS][rR][gG][bB]|[sS][tT][eE][eE][lL][bB][lL][uU][eE]|[tT][aA][nN]|[tT][eE][aA][lL]|[tT][hH][iI][sS][tT][lL][eE]|[tT][hH][rR][eE][eE][dD][dD][aA][rR][kK][sS][hH][aA][dD][oO][wW]|[tT][hH][rR][eE][eE][dD][fF][aA][cC][eE]|[tT][hH][rR][eE][eE][dD][hH][iI][gG][hH][lL][iI][gG][hH][tT]|[tT][hH][rR][eE][eE][dD][lL][iI][gG][hH][tT][sS][hH][aA][dD][oO][wW]|[tT][hH][rR][eE][eE][dD][sS][hH][aA][dD][oO][wW]|[tT][oO][mM][aA][tT][oO]|[tT][rR][aA][nN][sS][pP][aA][rR][eE][nN][tT]|[tT][uU][rR][qQ][uU][oO][iI][sS][eE]|[vV][iI][oO][lL][eE][tT]|[vV][iI][sS][iI][tT][eE][dD][tT][eE][xX][tT]|[wW][hH][eE][aA][tT]|[wW][hH][iI][tT][eE]|[wW][hH][iI][tT][eE][sS][mM][oO][kK][eE]|[wW][iI][nN][dD][oO][wW]|[wW][iI][nN][dD][oO][wW][fF][rR][aA][mM][eE]|[wW][iI][nN][dD][oO][wW][tT][eE][xX][tT]|[xX][yY][zZ]|[yY][eE][lL][lL][oO][wW]|[yY][eE][lL][lL][oO][wW][gG][rR][eE][eE][nN])))(?:\\s+(?:(?:[Nn][Oo][Nn][Ee]|[Uu][Nn][Dd][Ee][Rr][Ll][Ii][Nn][Ee]|[Oo][Vv][Ee][Rr][Ll][Ii][Nn][Ee]|[Ll][Ii][Nn][Ee]-[Tt][Hh][Rr][Oo][Uu][Gg][Hh]|[Bb][Ll][Ii][Nn][Kk]|[Ss][Pp][Ee][Ll][Ll][Ii][Nn][Gg]-[Ee][Rr][Rr][Oo][Rr]|[Gg][Rr][Aa][Mm][Mm][Aa][Rr]-[Ee][Rr][Rr][Oo][Rr])|(?:[Ss][Oo][Ll][Ii][Dd]|[Dd][Oo][Uu][Bb][Ll][Ee]|[Dd][Oo][Tt][Tt][Ee][Dd]|[Dd][Aa][Ss][Hh][Ee][Dd]|[Ww][Aa][Vv][Yy])|(?:[Tt][Hh][Ii][Nn]|[Mm][Ee][Dd][Ii][Uu][Mm]|[Tt][Hh][Ii][Cc][Kk]|[Aa][Uu][Tt][Oo]|[Ff][Rr][Oo][Mm]-[Ff][Oo][Nn][Tt])|(?:[-+]?(?:\\d+(?:\\.\\d+)?|\\.\\d+)(?:[Ee][+-]?\\d+)?(?:%|[A-Za-z][A-Za-z0-9-]*))|(?:[-+]?0+(?:\\.0+)?)|(?:#(?:[0-9A-Fa-f]{3}|[0-9A-Fa-f]{4}|[0-9A-Fa-f]{6}|[0-9A-Fa-f]{8}))|(?:[A-Za-z][A-Za-z0-9-]*\\((?:[^()]|\\((?:[^()]|\\([^()]*\\))*\\))*\\))|(?:[aA][cC][cC][eE][nN][tT][cC][oO][lL][oO][rR]|[aA][cC][cC][eE][nN][tT][cC][oO][lL][oO][rR][tT][eE][xX][tT]|[aA][cC][tT][iI][vV][eE][bB][oO][rR][dD][eE][rR]|[aA][cC][tT][iI][vV][eE][cC][aA][pP][tT][iI][oO][nN]|[aA][cC][tT][iI][vV][eE][tT][eE][xX][tT]|[aA][lL][iI][cC][eE][bB][lL][uU][eE]|[aA][nN][tT][iI][qQ][uU][eE][wW][hH][iI][tT][eE]|[aA][pP][pP][wW][oO][rR][kK][sS][pP][aA][cC][eE]|[aA][qQ][uU][aA]|[aA][qQ][uU][aA][mM][aA][rR][iI][nN][eE]|[aA][zZ][uU][rR][eE]|[bB][aA][cC][kK][gG][rR][oO][uU][nN][dD]|[bB][eE][iI][gG][eE]|[bB][iI][sS][qQ][uU][eE]|[bB][lL][aA][cC][kK]|[bB][lL][aA][nN][cC][hH][eE][dD][aA][lL][mM][oO][nN][dD]|[bB][lL][uU][eE]|[bB][lL][uU][eE][vV][iI][oO][lL][eE][tT]|[bB][rR][oO][wW][nN]|[bB][uU][rR][lL][yY][wW][oO][oO][dD]|[bB][uU][tT][tT][oO][nN][bB][oO][rR][dD][eE][rR]|[bB][uU][tT][tT][oO][nN][fF][aA][cC][eE]|[bB][uU][tT][tT][oO][nN][hH][iI][gG][hH][lL][iI][gG][hH][tT]|[bB][uU][tT][tT][oO][nN][sS][hH][aA][dD][oO][wW]|[bB][uU][tT][tT][oO][nN][tT][eE][xX][tT]|[cC][aA][dD][eE][tT][bB][lL][uU][eE]|[cC][aA][nN][vV][aA][sS]|[cC][aA][nN][vV][aA][sS][tT][eE][xX][tT]|[cC][aA][pP][tT][iI][oO][nN][tT][eE][xX][tT]|[cC][hH][aA][rR][tT][rR][eE][uU][sS][eE]|[cC][hH][oO][cC][oO][lL][aA][tT][eE]|[cC][oO][rR][aA][lL]|[cC][oO][rR][nN][fF][lL][oO][wW][eE][rR][bB][lL][uU][eE]|[cC][oO][rR][nN][sS][iI][lL][kK]|[cC][rR][iI][mM][sS][oO][nN]|[cC][uU][rR][rR][eE][nN][tT][cC][oO][lL][oO][rR]|[cC][yY][aA][nN]|[dD][aA][rR][kK][bB][lL][uU][eE]|[dD][aA][rR][kK][cC][yY][aA][nN]|[dD][aA][rR][kK][gG][oO][lL][dD][eE][nN][rR][oO][dD]|[dD][aA][rR][kK][gG][rR][aA][yY]|[dD][aA][rR][kK][gG][rR][eE][eE][nN]|[dD][aA][rR][kK][gG][rR][eE][yY]|[dD][aA][rR][kK][kK][hH][aA][kK][iI]|[dD][aA][rR][kK][mM][aA][gG][eE][nN][tT][aA]|[dD][aA][rR][kK][oO][lL][iI][vV][eE][gG][rR][eE][eE][nN]|[dD][aA][rR][kK][oO][rR][aA][nN][gG][eE]|[dD][aA][rR][kK][oO][rR][cC][hH][iI][dD]|[dD][aA][rR][kK][rR][eE][dD]|[dD][aA][rR][kK][sS][aA][lL][mM][oO][nN]|[dD][aA][rR][kK][sS][eE][aA][gG][rR][eE][eE][nN]|[dD][aA][rR][kK][sS][lL][aA][tT][eE][bB][lL][uU][eE]|[dD][aA][rR][kK][sS][lL][aA][tT][eE][gG][rR][aA][yY]|[dD][aA][rR][kK][sS][lL][aA][tT][eE][gG][rR][eE][yY]|[dD][aA][rR][kK][tT][uU][rR][qQ][uU][oO][iI][sS][eE]|[dD][aA][rR][kK][vV][iI][oO][lL][eE][tT]|[dD][eE][eE][pP][pP][iI][nN][kK]|[dD][eE][eE][pP][sS][kK][yY][bB][lL][uU][eE]|[dD][iI][mM][gG][rR][aA][yY]|[dD][iI][mM][gG][rR][eE][yY]|[dD][oO][dD][gG][eE][rR][bB][lL][uU][eE]|[fF][iI][eE][lL][dD]|[fF][iI][eE][lL][dD][tT][eE][xX][tT]|[fF][iI][rR][eE][bB][rR][iI][cC][kK]|[fF][lL][oO][rR][aA][lL][wW][hH][iI][tT][eE]|[fF][oO][rR][eE][sS][tT][gG][rR][eE][eE][nN]|[fF][uU][cC][hH][sS][iI][aA]|[gG][aA][iI][nN][sS][bB][oO][rR][oO]|[gG][hH][oO][sS][tT][wW][hH][iI][tT][eE]|[gG][oO][lL][dD]|[gG][oO][lL][dD][eE][nN][rR][oO][dD]|[gG][rR][aA][yY]|[gG][rR][aA][yY][tT][eE][xX][tT]|[gG][rR][eE][eE][nN]|[gG][rR][eE][eE][nN][yY][eE][lL][lL][oO][wW]|[gG][rR][eE][yY]|[hH][iI][gG][hH][lL][iI][gG][hH][tT]|[hH][iI][gG][hH][lL][iI][gG][hH][tT][tT][eE][xX][tT]|[hH][oO][nN][eE][yY][dD][eE][wW]|[hH][oO][tT][pP][iI][nN][kK]|[iI][nN][aA][cC][tT][iI][vV][eE][bB][oO][rR][dD][eE][rR]|[iI][nN][aA][cC][tT][iI][vV][eE][cC][aA][pP][tT][iI][oO][nN]|[iI][nN][aA][cC][tT][iI][vV][eE][cC][aA][pP][tT][iI][oO][nN][tT][eE][xX][tT]|[iI][nN][dD][iI][aA][nN][rR][eE][dD]|[iI][nN][dD][iI][gG][oO]|[iI][nN][fF][oO][bB][aA][cC][kK][gG][rR][oO][uU][nN][dD]|[iI][nN][fF][oO][tT][eE][xX][tT]|[iI][vV][oO][rR][yY]|[kK][hH][aA][kK][iI]|[lL][aA][vV][eE][nN][dD][eE][rR]|[lL][aA][vV][eE][nN][dD][eE][rR][bB][lL][uU][sS][hH]|[lL][aA][wW][nN][gG][rR][eE][eE][nN]|[lL][eE][mM][oO][nN][cC][hH][iI][fF][fF][oO][nN]|[lL][iI][gG][hH][tT][bB][lL][uU][eE]|[lL][iI][gG][hH][tT][cC][oO][rR][aA][lL]|[lL][iI][gG][hH][tT][cC][yY][aA][nN]|[lL][iI][gG][hH][tT][gG][oO][lL][dD][eE][nN][rR][oO][dD][yY][eE][lL][lL][oO][wW]|[lL][iI][gG][hH][tT][gG][rR][aA][yY]|[lL][iI][gG][hH][tT][gG][rR][eE][eE][nN]|[lL][iI][gG][hH][tT][gG][rR][eE][yY]|[lL][iI][gG][hH][tT][pP][iI][nN][kK]|[lL][iI][gG][hH][tT][sS][aA][lL][mM][oO][nN]|[lL][iI][gG][hH][tT][sS][eE][aA][gG][rR][eE][eE][nN]|[lL][iI][gG][hH][tT][sS][kK][yY][bB][lL][uU][eE]|[lL][iI][gG][hH][tT][sS][lL][aA][tT][eE][gG][rR][aA][yY]|[lL][iI][gG][hH][tT][sS][lL][aA][tT][eE][gG][rR][eE][yY]|[lL][iI][gG][hH][tT][sS][tT][eE][eE][lL][bB][lL][uU][eE]|[lL][iI][gG][hH][tT][yY][eE][lL][lL][oO][wW]|[lL][iI][mM][eE]|[lL][iI][mM][eE][gG][rR][eE][eE][nN]|[lL][iI][nN][eE][nN]|[lL][iI][nN][kK][tT][eE][xX][tT]|[mM][aA][gG][eE][nN][tT][aA]|[mM][aA][rR][kK]|[mM][aA][rR][kK][tT][eE][xX][tT]|[mM][aA][rR][oO][oO][nN]|[mM][eE][dD][iI][uU][mM][aA][qQ][uU][aA][mM][aA][rR][iI][nN][eE]|[mM][eE][dD][iI][uU][mM][bB][lL][uU][eE]|[mM][eE][dD][iI][uU][mM][oO][rR][cC][hH][iI][dD]|[mM][eE][dD][iI][uU][mM][pP][uU][rR][pP][lL][eE]|[mM][eE][dD][iI][uU][mM][sS][eE][aA][gG][rR][eE][eE][nN]|[mM][eE][dD][iI][uU][mM][sS][lL][aA][tT][eE][bB][lL][uU][eE]|[mM][eE][dD][iI][uU][mM][sS][pP][rR][iI][nN][gG][gG][rR][eE][eE][nN]|[mM][eE][dD][iI][uU][mM][tT][uU][rR][qQ][uU][oO][iI][sS][eE]|[mM][eE][dD][iI][uU][mM][vV][iI][oO][lL][eE][tT][rR][eE][dD]|[mM][eE][nN][uU]|[mM][eE][nN][uU][tT][eE][xX][tT]|[mM][iI][dD][nN][iI][gG][hH][tT][bB][lL][uU][eE]|[mM][iI][nN][tT][cC][rR][eE][aA][mM]|[mM][iI][sS][tT][yY][rR][oO][sS][eE]|[mM][oO][cC][cC][aA][sS][iI][nN]|[nN][aA][vV][aA][jJ][oO][wW][hH][iI][tT][eE]|[nN][aA][vV][yY]|[nN][oO][nN][eE]|[oO][lL][dD][lL][aA][cC][eE]|[oO][lL][iI][vV][eE]|[oO][lL][iI][vV][eE][dD][rR][aA][bB]|[oO][rR][aA][nN][gG][eE]|[oO][rR][aA][nN][gG][eE][rR][eE][dD]|[oO][rR][cC][hH][iI][dD]|[pP][aA][lL][eE][gG][oO][lL][dD][eE][nN][rR][oO][dD]|[pP][aA][lL][eE][gG][rR][eE][eE][nN]|[pP][aA][lL][eE][tT][uU][rR][qQ][uU][oO][iI][sS][eE]|[pP][aA][lL][eE][vV][iI][oO][lL][eE][tT][rR][eE][dD]|[pP][aA][pP][aA][yY][aA][wW][hH][iI][pP]|[pP][eE][aA][cC][hH][pP][uU][fF][fF]|[pP][eE][rR][uU]|[pP][iI][nN][kK]|[pP][lL][uU][mM]|[pP][oO][wW][dD][eE][rR][bB][lL][uU][eE]|[pP][uU][rR][pP][lL][eE]|[rR][eE][bB][eE][cC][cC][aA][pP][uU][rR][pP][lL][eE]|[rR][eE][dD]|[rR][oO][sS][yY][bB][rR][oO][wW][nN]|[rR][oO][yY][aA][lL][bB][lL][uU][eE]|[sS][aA][dD][dD][lL][eE][bB][rR][oO][wW][nN]|[sS][aA][lL][mM][oO][nN]|[sS][aA][nN][dD][yY][bB][rR][oO][wW][nN]|[sS][cC][rR][oO][lL][lL][bB][aA][rR]|[sS][eE][aA][gG][rR][eE][eE][nN]|[sS][eE][aA][sS][hH][eE][lL][lL]|[sS][eE][lL][eE][cC][tT][eE][dD][iI][tT][eE][mM]|[sS][eE][lL][eE][cC][tT][eE][dD][iI][tT][eE][mM][tT][eE][xX][tT]|[sS][iI][eE][nN][nN][aA]|[sS][iI][lL][vV][eE][rR]|[sS][kK][yY][bB][lL][uU][eE]|[sS][lL][aA][tT][eE][bB][lL][uU][eE]|[sS][lL][aA][tT][eE][gG][rR][aA][yY]|[sS][lL][aA][tT][eE][gG][rR][eE][yY]|[sS][nN][oO][wW]|[sS][pP][rR][iI][nN][gG][gG][rR][eE][eE][nN]|[sS][rR][gG][bB]|[sS][tT][eE][eE][lL][bB][lL][uU][eE]|[tT][aA][nN]|[tT][eE][aA][lL]|[tT][hH][iI][sS][tT][lL][eE]|[tT][hH][rR][eE][eE][dD][dD][aA][rR][kK][sS][hH][aA][dD][oO][wW]|[tT][hH][rR][eE][eE][dD][fF][aA][cC][eE]|[tT][hH][rR][eE][eE][dD][hH][iI][gG][hH][lL][iI][gG][hH][tT]|[tT][hH][rR][eE][eE][dD][lL][iI][gG][hH][tT][sS][hH][aA][dD][oO][wW]|[tT][hH][rR][eE][eE][dD][sS][hH][aA][dD][oO][wW]|[tT][oO][mM][aA][tT][oO]|[tT][rR][aA][nN][sS][pP][aA][rR][eE][nN][tT]|[tT][uU][rR][qQ][uU][oO][iI][sS][eE]|[vV][iI][oO][lL][eE][tT]|[vV][iI][sS][iI][tT][eE][dD][tT][eE][xX][tT]|[wW][hH][eE][aA][tT]|[wW][hH][iI][tT][eE]|[wW][hH][iI][tT][eE][sS][mM][oO][kK][eE]|[wW][iI][nN][dD][oO][wW]|[wW][iI][nN][dD][oO][wW][fF][rR][aA][mM][eE]|[wW][iI][nN][dD][oO][wW][tT][eE][xX][tT]|[xX][yY][zZ]|[yY][eE][lL][lL][oO][wW]|[yY][eE][lL][lL][oO][wW][gG][rR][eE][eE][nN])))*)$"
    },
    "text-transform-list": {
      "title": "Text transform list",
      "description": "Whitespace-separated sequence of text-transform keywords per Typography §text-transform and CSS Text Module Levels 3-4.",
      "$comment": "Typography §text-transform: values MUST be composed of recognised keywords (for example none, uppercase, full-width, full-size-kana, or math-* variants), CSS global keywords, or custom property references via var().",
      "type": "string",
      "pattern": "^(?:(?:[Ii][Nn][Hh][Ee][Rr][Ii][Tt]|[Ii][Nn][Ii][Tt][Ii][Aa][Ll]|[Uu][Nn][Ss][Ee][Tt]|[Rr][Ee][Vv][Ee][Rr][Tt](?:-[Ll][Aa][Yy][Ee][Rr])?)|(?:[Vv][Aa][Rr]|[Ee][Nn][Vv])\\((?:[^()]|\\((?:[^()]|\\([^()]*\\))*\\))*\\)|(?:(?:[Nn][Oo][Nn][Ee]|[Cc][Aa][Pp][Ii][Tt][Aa][Ll][Ii][Zz][Ee]|[Uu][Pp][Pp][Ee][Rr][Cc][Aa][Ss][Ee]|[Ll][Oo][Ww][Ee][Rr][Cc][Aa][Ss][Ee]|[Ff][Uu][Ll][Ll]-[Ww][Ii][Dd][Tt][Hh]|[Ff][Uu][Ll][Ll]-[Ss][Ii][Zz][Ee]-[Kk][Aa][Nn][Aa]|[Mm][Aa][Tt][Hh]-[Aa][Uu][Tt][Oo]|[Mm][Aa][Tt][Hh](?:-[A-Za-z]+)+))(?:\\s+(?:[Nn][Oo][Nn][Ee]|[Cc][Aa][Pp][Ii][Tt][Aa][Ll][Ii][Zz][Ee]|[Uu][Pp][Pp][Ee][Rr][Cc][Aa][Ss][Ee]|[Ll][Oo][Ww][Ee][Rr][Cc][Aa][Ss][Ee]|[Ff][Uu][Ll][Ll]-[Ww][Ii][Dd][Tt][Hh]|[Ff][Uu][Ll][Ll]-[Ss][Ii][Zz][Ee]-[Kk][Aa][Nn][Aa]|[Mm][Aa][Tt][Hh]-[Aa][Uu][Tt][Oo]|[Mm][Aa][Tt][Hh](?:-[A-Za-z]+)+))*)$"
    },
    "platform-identifier": {
      "title": "Platform-qualified identifier",
      "description": "Lower-case dot-separated identifier prefixed with css, ios, or android per platform-qualified token members.",
      "$comment": "Token types §cursor, §filter tokens, §opacity, §duration, §z-index, §motion tokens, Typography §font, and §font-face require css/ios/android-qualified identifiers for context selection.",
      "type": "string",
      "pattern": "^(?:css|ios|android)(?:\\.[a-z0-9]+(?:-[a-z0-9]+)*)+$"
    },
    "namespaced-function-identifier": {
      "title": "Function identifier",
      "description": "Lower-case identifier optionally namespaced with dot-separated segments for CSS and platform functions.",
      "$comment": "Token types §value, §filter tokens, and §easing use function identifiers aligned with CSS grammars and vendor-qualified variants.",
      "type": "string",
      "pattern": "^[a-z][a-z0-9-]*(?:\\.[a-z0-9]+(?:-[a-z0-9]+)*)*$"
    },
    "context-identifier": {
      "title": "Rendering context identifier",
      "description": "Lower-case identifier describing rendering surfaces such as css.box-shadow or ios.layer.",
      "$comment": "Token types §shadow tokens, §gradient tokens, and §elevation tokens use dotted identifiers that mirror CSS and native surface nomenclature.",
      "type": "string",
      "pattern": "^[a-z][a-z0-9-]*(?:\\.[a-z0-9-]+)*$"
    },
    "type-identifier": {
      "title": "Token type identifier",
      "description": "Registered DTIF $type or vendor-defined identifier per Format and serialisation §$type.",
      "type": "string",
      "pattern": "^(?:[A-Za-z][A-Za-z0-9_-]*)(?:\\.[A-Za-z0-9_-]+)*$",
      "$comment": "Format and serialisation §$type: registry types include border, color, component, cursor, dimension, duration, easing, elevation, filter, font, fontFace, gradient, line-height, motion, opacity, shadow, strokeStyle, typography, and z-index. Vendors MAY mint additional identifiers and SHOULD namespace them (Extensibility §extensibility) but the schema accepts any dot-separated ASCII identifier without whitespace.",
      "examples": ["color", "typography", "com.example.tokens.radius"]
    },
    "metadata-members": {
      "title": "Metadata members",
      "description": "Optional metadata fields defined in Metadata §metadata applied to tokens and collections.",
      "$comment": "Metadata §metadata table.",
      "properties": {
        "$description": {
          "type": "string",
          "title": "Description",
          "description": "Human-readable explanation preserved for design intent per Metadata §metadata.",
          "$comment": "Metadata table: $description is optional free-form text."
        },
        "$extensions": {
          "title": "Extensions",
          "description": "Namespaced metadata preserved by consumers per Format and serialisation §$extensions.",
          "$comment": "Format and serialisation §$extensions.",
          "allOf": [
            {
              "$ref": "#/$defs/extensions"
            }
          ]
        },
        "$deprecated": {
          "title": "Deprecation metadata",
          "description": "Boolean indicator or replacement pointer per Metadata §metadata.",
          "$comment": "Metadata table: $deprecated MAY be a boolean or an object with $replacement.",
          "oneOf": [
            {
              "type": "boolean"
            },
            {
              "type": "object",
              "required": ["$replacement"],
              "properties": {
                "$replacement": {
                  "title": "Replacement token pointer",
                  "description": "Pointer to the successor token that MUST resolve to the same $type per Metadata §metadata.",
                  "allOf": [
                    {
                      "$ref": "#/$defs/local-pointer"
                    }
                  ]
                }
              },
              "additionalProperties": false
            }
          ]
        },
        "$lastModified": {
          "type": "string",
          "format": "date-time",
          "title": "Last modified timestamp",
          "description": "RFC 3339 date-time recording governance actions per Metadata §metadata.",
          "$comment": "Metadata table: $lastModified establishes the lower bound for $lastUsed."
        },
        "$lastUsed": {
          "type": "string",
          "format": "date-time",
          "title": "Last used timestamp",
          "description": "RFC 3339 date-time capturing usage telemetry per Metadata §metadata.",
          "$comment": "Metadata table: $lastUsed MUST NOT precede $lastModified and requires $usageCount > 0."
        },
        "$usageCount": {
          "type": "integer",
          "minimum": 0,
          "title": "Usage count",
          "description": "Non-negative adoption counter per Metadata §metadata.",
          "$comment": "Metadata table: $usageCount records adoption and pairs with $lastUsed when greater than zero."
        },
        "$author": {
          "title": "Author",
          "description": "Contributor name without leading or trailing whitespace per Metadata §metadata.",
          "$comment": "Metadata table: $author MUST be a non-empty trimmed string.",
          "allOf": [
            {
              "$ref": "#/$defs/trimmedString"
            }
          ]
        },
        "$tags": {
          "title": "Tags",
          "description": "Unique classification strings free of surrounding whitespace per Metadata §metadata.",
          "$comment": "Metadata table: $tags MUST be an array of trimmed, unique strings.",
          "allOf": [
            {
              "$ref": "#/$defs/tags"
            }
          ]
        },
        "$hash": {
          "title": "Hash",
          "description": "Stable identifier without whitespace for change tracking per Metadata §metadata.",
          "$comment": "Metadata table: $hash MUST be non-empty and contain no whitespace.",
          "allOf": [
            {
              "$ref": "#/$defs/hashString"
            }
          ]
        }
      },
      "type": "object"
    },
    "override-core": {
      "title": "Override rule members",
      "description": "Shared override members applied to $overrides entries per Theming and overrides §$overrides.",
      "$comment": "Theming and overrides §$overrides.",
      "type": "object",
      "properties": {
        "$token": {
          "title": "Target token",
          "description": "Pointer to the token being overridden per Theming and overrides §$overrides.",
          "allOf": [
            {
              "$ref": "#/$defs/pointer"
            }
          ]
        },
        "$when": {
          "type": "object",
          "minProperties": 1,
          "title": "Override conditions",
          "description": "Context map describing when the override applies per Theming and overrides §$overrides.",
          "$comment": "Override contexts MUST declare at least one condition per Theming and overrides §$overrides.",
          "propertyNames": {
            "minLength": 1,
            "$comment": "Condition keys MUST be non-empty strings.",
            "type": "string"
          }
        },
        "$ref": {
          "title": "Override reference",
          "description": "Pointer to the replacement token per Theming and overrides §$overrides.",
          "allOf": [
            {
              "$ref": "#/$defs/pointer"
            }
          ]
        },
        "$value": {
          "title": "Inline override value",
          "description": "Direct replacement that MUST satisfy the overridden token's $type per Theming and overrides §$overrides.",
          "$comment": "Inline override values must conform to the target token's $type."
        },
        "$fallback": {
          "title": "Fallback chain",
          "description": "Single fallback object or array evaluated when primary override resolution fails per Theming and overrides §$overrides.",
          "allOf": [
            {
              "$ref": "#/$defs/fallback"
            }
          ]
        }
      },
      "required": ["$token", "$when"],
      "additionalProperties": false
    },
    "fallback-entry-core": {
      "title": "Fallback entry members",
      "description": "Shared fallback members evaluated when overrides fail per Theming and overrides §$overrides.",
      "$comment": "Theming and overrides §$overrides.",
      "type": "object",
      "properties": {
        "$ref": {
          "title": "Fallback reference",
          "description": "Pointer to an alternate token per Theming and overrides §$overrides.",
          "allOf": [
            {
              "$ref": "#/$defs/pointer"
            }
          ]
        },
        "$value": {
          "title": "Inline fallback value",
          "description": "Inline fallback that MUST conform to the overridden token's $type per Theming and overrides §$overrides.",
          "$comment": "Fallback values must conform to the overridden token's $type."
        },
        "$fallback": {
          "title": "Nested fallback",
          "description": "Optional nested fallback chain evaluated when this entry fails per Theming and overrides §$overrides.",
          "allOf": [
            {
              "$ref": "#/$defs/fallback"
            }
          ]
        }
      },
      "additionalProperties": false
    },
    "token-core": {
      "type": "object",
      "properties": {
        "$type": {
          "$ref": "#/$defs/type-identifier"
        },
        "$value": {
          "title": "Token value",
          "description": "Design decision payload whose shape depends on $type per Token types §value.",
          "$comment": "Token types §value: $value MUST follow the grammar associated with $type."
        },
        "$ref": {
          "$ref": "#/$defs/pointer"
        },
        "$description": {
          "$ref": "#/$defs/metadata-members/properties/$description"
        },
        "$extensions": {
          "$ref": "#/$defs/metadata-members/properties/$extensions"
        },
        "$deprecated": {
          "$ref": "#/$defs/metadata-members/properties/$deprecated"
        },
        "$lastModified": {
          "$ref": "#/$defs/metadata-members/properties/$lastModified"
        },
        "$lastUsed": {
          "$ref": "#/$defs/metadata-members/properties/$lastUsed"
        },
        "$usageCount": {
          "$ref": "#/$defs/metadata-members/properties/$usageCount"
        },
        "$author": {
          "$ref": "#/$defs/metadata-members/properties/$author"
        },
        "$tags": {
          "$ref": "#/$defs/metadata-members/properties/$tags"
        },
        "$hash": {
          "$ref": "#/$defs/metadata-members/properties/$hash"
        }
      },
      "unevaluatedProperties": false,
      "allOf": [
        {
          "oneOf": [
            {
              "required": ["$value"],
              "not": {
                "required": ["$ref"],
                "type": "object",
                "properties": {
                  "$ref": {}
                }
              },
              "type": "object",
              "properties": {
                "$value": {}
              }
            },
            {
              "required": ["$ref"],
              "not": {
                "required": ["$value"],
                "type": "object",
                "properties": {
                  "$value": {}
                }
              },
              "type": "object",
              "properties": {
                "$ref": {}
              }
            }
          ]
        },
        {
          "if": {
            "required": ["$ref"],
            "type": "object",
            "properties": {
              "$ref": {}
            }
          },
          "then": {
            "required": ["$type"],
            "type": "object",
            "properties": {
              "$type": {}
            }
          }
        },
        {
          "if": {
            "properties": {
              "$value": {
                "type": "array"
              }
            },
            "required": ["$value"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "title": "Non-empty $value array",
                "description": "Array values MUST provide at least one entry per Token types §value.",
                "$comment": "Token types §value: fallback arrays and composite lists MUST contain at least one item.",
                "minItems": 1,
                "type": "array"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "dimension"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/dimensionTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "color"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/colorTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "font"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/fontTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "fontFace"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/fontFaceTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "line-height"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/lineHeightTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "typography"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/typographyTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "border"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/borderTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "strokeStyle"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/strokeStyleTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "cursor"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/cursorTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "shadow"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/shadowTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "gradient"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/gradientTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "filter"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/filterTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "opacity"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/opacityTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "duration"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/durationTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "easing"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/easingTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "z-index"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/zIndexTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "motion"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/motionTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "elevation"
              }
            },
            "required": ["$type"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "$ref": "#/$defs/elevationTokenValue"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$type": {
                "const": "component"
              },
              "$value": {}
            },
            "required": ["$type", "$value"],
            "type": "object"
          },
          "then": {
            "properties": {
              "$value": {
                "type": "object",
                "required": ["$slots"],
                "properties": {
                  "$slots": {
                    "type": "object",
                    "minProperties": 1,
                    "propertyNames": {
                      "pattern": "^(?!\\$)",
                      "type": "string"
                    },
                    "patternProperties": {
                      "^(?!\\$)": {
                        "allOf": [
                          {
                            "$ref": "#/$defs/token"
                          },
                          {
                            "not": {
                              "properties": {
                                "$type": {
                                  "const": "component"
                                }
                              },
                              "required": ["$type"],
                              "type": "object"
                            }
                          }
                        ]
                      }
                    },
                    "additionalProperties": false
                  }
                },
                "propertyNames": {
                  "type": "string",
                  "pattern": "^(?:\\$slots|[^$].*)$",
                  "$comment": "Conformance §conformance-classes and Extensibility §extensibility: only the schema-defined $slots member is permitted among reserved names."
                },
                "additionalProperties": true
              }
            },
            "type": "object"
          }
        }
      ]
    },
    "override": {
      "title": "Override rule",
      "description": "Contextual substitution entry evaluated against $when conditions per Theming and overrides §$overrides.",
      "$comment": "Theming and overrides §$overrides.",
      "allOf": [
        {
          "$ref": "#/$defs/override-core"
        }
      ]
    },
    "fallback": {
      "title": "Fallback chain",
      "description": "Single fallback entry or ordered array evaluated when primary overrides fail per Theming and overrides §$overrides.",
      "$comment": "Theming and overrides §$overrides: $fallback MAY be a single entry or an array processed sequentially.",
      "oneOf": [
        {
          "$ref": "#/$defs/fallbackEntry"
        },
        {
          "type": "array",
          "minItems": 1,
          "items": {
            "$ref": "#/$defs/fallbackEntry"
          }
        }
      ]
    },
    "fallbackEntry": {
      "title": "Fallback entry",
      "description": "Single fallback candidate containing a $ref or inline $value per Theming and overrides §$overrides.",
      "$comment": "Theming and overrides §$overrides: fallback entries mirror override semantics.",
      "allOf": [
        {
          "$ref": "#/$defs/fallback-entry-core"
        },
        {
          "anyOf": [
            {
              "required": ["$ref"],
              "type": "object",
              "properties": {
                "$ref": {}
              }
            },
            {
              "required": ["$value"],
              "type": "object",
              "properties": {
                "$value": {}
              }
            }
          ],
          "$comment": "Fallback entries MUST declare either $ref or $value.",
          "title": "Fallback resolution requirement"
        },
        {
          "if": {
            "required": ["$ref"],
            "type": "object",
            "properties": {
              "$ref": {}
            }
          },
          "then": {
            "properties": {
              "$value": false
            },
            "$comment": "Fallback entries using $ref MUST NOT also declare $value.",
            "type": "object"
          }
        },
        {
          "if": {
            "required": ["$value"],
            "type": "object",
            "properties": {
              "$value": {}
            }
          },
          "then": {
            "properties": {
              "$ref": false
            },
            "$comment": "Fallback entries using inline $value MUST NOT also declare $ref.",
            "type": "object"
          }
        }
      ]
    },
    "node": {
      "title": "Token or collection node",
      "description": "Tree node that is either a token or a collection per Architecture and model §tokens-and-collections.",
      "$comment": "Architecture and model §tokens-and-collections.",
      "oneOf": [
        {
          "$ref": "#/$defs/token"
        },
        {
          "$ref": "#/$defs/collection"
        }
      ]
    },
    "collection": {
      "title": "Token collection",
      "description": "Object without $value whose non-reserved members are tokens or collections per Architecture and model §tokens-and-collections.",
      "$comment": "Architecture and model §tokens-and-collections.",
      "allOf": [
        {
          "$ref": "#/$defs/metadata-members"
        },
        {
          "type": "object",
          "properties": {
            "$description": {
              "$ref": "#/$defs/metadata-members/properties/$description"
            },
            "$extensions": {
              "$ref": "#/$defs/metadata-members/properties/$extensions"
            },
            "$deprecated": {
              "$ref": "#/$defs/metadata-members/properties/$deprecated"
            },
            "$lastModified": {
              "$ref": "#/$defs/metadata-members/properties/$lastModified"
            },
            "$lastUsed": {
              "$ref": "#/$defs/metadata-members/properties/$lastUsed"
            },
            "$usageCount": {
              "$ref": "#/$defs/metadata-members/properties/$usageCount"
            },
            "$author": {
              "$ref": "#/$defs/metadata-members/properties/$author"
            },
            "$tags": {
              "$ref": "#/$defs/metadata-members/properties/$tags"
            },
            "$hash": {
              "$ref": "#/$defs/metadata-members/properties/$hash"
            }
          },
          "patternProperties": {
            "^(?!\\$)": {
              "$ref": "#/$defs/node"
            }
          },
          "unevaluatedProperties": false,
          "allOf": [
            {
              "not": {
                "required": ["$value"],
                "type": "object",
                "properties": {
                  "$value": {}
                }
              },
              "$comment": "Collections remain valid without child tokens as long as they omit $value; metadata-only collections support migration scenarios."
            },
            {
              "not": {
                "required": ["$type"],
                "type": "object",
                "properties": {
                  "$type": {}
                }
              },
              "$comment": "Collections do not declare $type because they do not provide default typing for nested tokens."
            },
            {
              "not": {
                "required": ["$ref"],
                "type": "object",
                "properties": {
                  "$ref": {}
                }
              },
              "$comment": "Collections cannot alias other nodes; only tokens use $ref."
            }
          ]
        },
        {
          "$ref": "#/$defs/lifecycle-metadata"
        }
      ]
    },
    "token": {
      "title": "Design token",
      "description": "Object declaring either $value or $ref along with optional metadata per Terminology §token and Format and serialisation §$ref.",
      "$comment": "Terminology §token and Format and serialisation §$ref.",
      "allOf": [
        {
          "$ref": "#/$defs/metadata-members"
        },
        {
          "$ref": "#/$defs/token-core"
        },
        {
          "$ref": "#/$defs/lifecycle-metadata"
        }
      ]
    },
    "dimensionValueEntry": {
      "title": "Dimension value entry",
      "description": "Literal measurement, alias, or computed expression per Token types §dimension.",
      "$comment": "Token types §dimension and §value: dimension tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/dimensionReference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "dimensionValueFallback": {
      "title": "Dimension fallback list",
      "description": "Ordered fallback list of dimension values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/dimensionValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "dimensionTokenValue": {
      "title": "Dimension token value",
      "description": "Dimension literal, alias, or fallback list per Token types §dimension.",
      "$comment": "Token types §dimension: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/dimensionValueEntry"
        },
        {
          "$ref": "#/$defs/dimensionValueFallback"
        }
      ]
    },
    "dimension": {
      "type": "object",
      "required": ["dimensionType", "value", "unit"],
      "properties": {
        "dimensionType": {
          "type": "string",
          "enum": ["length", "angle", "resolution", "custom"]
        },
        "value": {
          "type": "number"
        },
        "unit": {
          "type": "string"
        },
        "fontScale": {
          "type": "boolean",
          "description": "Whether the value scales with the user's font settings.",
          "$comment": "When true, MUST follow Dynamic Type (IOS-DYNAMIC-TYPE) and Android scale-independent behaviour (ANDROID-DP-SP)."
        }
      },
      "additionalProperties": false,
      "allOf": [
        {
          "if": {
            "properties": {
              "dimensionType": {
                "const": "length"
              }
            },
            "required": ["dimensionType"],
            "type": "object"
          },
          "then": {
            "properties": {
              "unit": {
                "type": "string",
                "pattern": "^(?:%|[Cc][Mm]|[Mm][Mm]|[Qq]|[Ii][Nn]|[Pp][Tt]|[Pp][Cc]|[Pp][Xx]|[Ee][Mm]|[Ee][Xx]|[Cc][Aa][Pp]|[Cc][Hh]|[Ii][Cc]|[Rr][Ee][Mm]|[Rr][Ee][Xx]|[Rr][Cc][Aa][Pp]|[Rr][Cc][Hh]|[Rr][Ii][Cc]|[Ll][Hh]|[Rr][Ll][Hh]|[Vv][Ww]|[Vv][Hh]|[Vv][Ii]|[Vv][Bb]|[Vv][Mm][Ii][Nn]|[Vv][Mm][Aa][Xx]|[Ss][Vv][Ww]|[Ss][Vv][Hh]|[Ss][Vv][Ii]|[Ss][Vv][Bb]|[Ss][Vv][Mm][Ii][Nn]|[Ss][Vv][Mm][Aa][Xx]|[Ll][Vv][Ww]|[Ll][Vv][Hh]|[Ll][Vv][Ii]|[Ll][Vv][Bb]|[Ll][Vv][Mm][Ii][Nn]|[Ll][Vv][Mm][Aa][Xx]|[Dd][Vv][Ww]|[Dd][Vv][Hh]|[Dd][Vv][Ii]|[Dd][Vv][Bb]|[Dd][Vv][Mm][Ii][Nn]|[Dd][Vv][Mm][Aa][Xx]|[Cc][Qq][Ww]|[Cc][Qq][Hh]|[Cc][Qq][Ii]|[Cc][Qq][Bb]|[Cc][Qq][Mm][Ii][Nn]|[Cc][Qq][Mm][Aa][Xx]|[Dd][Pp]|[Ss][Pp])$",
                "$comment": "MUST conform to CSS <length> or <percentage> (css-values-4) or native point/density-independent units (IOS-POINTS, ANDROID-DP-SP)."
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "dimensionType": {
                "const": "angle"
              }
            },
            "required": ["dimensionType"],
            "type": "object"
          },
          "then": {
            "properties": {
              "unit": {
                "type": "string",
                "pattern": "^(?:[Dd][Ee][Gg]|[Gg][Rr][Aa][Dd]|[Rr][Aa][Dd]|[Tt][Uu][Rr][Nn])$",
                "$comment": "MUST conform to CSS <angle> production (css-values-4)."
              }
            },
            "not": {
              "required": ["fontScale"],
              "type": "object",
              "properties": {
                "fontScale": {}
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "dimensionType": {
                "const": "resolution"
              }
            },
            "required": ["dimensionType"],
            "type": "object"
          },
          "then": {
            "properties": {
              "unit": {
                "type": "string",
                "pattern": "^(?:[Dd][Pp][Ii]|[Dd][Pp][Cc][Mm]|[Dd][Pp][Pp][Xx]|[Xx])$",
                "$comment": "MUST conform to CSS <resolution> production (css-values-4)."
              }
            },
            "not": {
              "required": ["fontScale"],
              "type": "object",
              "properties": {
                "fontScale": {}
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "dimensionType": {
                "const": "custom"
              }
            },
            "required": ["dimensionType"],
            "type": "object"
          },
          "then": {
            "properties": {
              "unit": {
                "type": "string",
                "pattern": "^[a-z0-9]+(?:\\.[a-z0-9-]+)+$"
              }
            },
            "not": {
              "required": ["fontScale"],
              "type": "object",
              "properties": {
                "fontScale": {}
              }
            },
            "type": "object"
          }
        }
      ]
    },
    "font-dimension": {
      "oneOf": [
        {
          "type": "object",
          "required": ["dimensionType", "value", "unit"],
          "properties": {
            "dimensionType": {
              "const": "length"
            },
            "value": {
              "type": "number"
            },
            "unit": {
              "type": "string",
              "pattern": "^(?:%|[Cc][Mm]|[Mm][Mm]|[Qq]|[Ii][Nn]|[Pp][Tt]|[Pp][Cc]|[Pp][Xx]|[Ee][Mm]|[Ee][Xx]|[Cc][Aa][Pp]|[Cc][Hh]|[Ii][Cc]|[Rr][Ee][Mm]|[Rr][Ee][Xx]|[Rr][Cc][Aa][Pp]|[Rr][Cc][Hh]|[Rr][Ii][Cc]|[Ll][Hh]|[Rr][Ll][Hh]|[Vv][Ww]|[Vv][Hh]|[Vv][Ii]|[Vv][Bb]|[Vv][Mm][Ii][Nn]|[Vv][Mm][Aa][Xx]|[Ss][Vv][Ww]|[Ss][Vv][Hh]|[Ss][Vv][Ii]|[Ss][Vv][Bb]|[Ss][Vv][Mm][Ii][Nn]|[Ss][Vv][Mm][Aa][Xx]|[Ll][Vv][Ww]|[Ll][Vv][Hh]|[Ll][Vv][Ii]|[Ll][Vv][Bb]|[Ll][Vv][Mm][Ii][Nn]|[Ll][Vv][Mm][Aa][Xx]|[Dd][Vv][Ww]|[Dd][Vv][Hh]|[Dd][Vv][Ii]|[Dd][Vv][Bb]|[Dd][Vv][Mm][Ii][Nn]|[Dd][Vv][Mm][Aa][Xx]|[Cc][Qq][Ww]|[Cc][Qq][Hh]|[Cc][Qq][Ii]|[Cc][Qq][Bb]|[Cc][Qq][Mm][Ii][Nn]|[Cc][Qq][Mm][Aa][Xx]|[Dd][Pp]|[Ss][Pp])$",
              "$comment": "MUST conform to CSS <length> or <percentage> (css-values-4) or native point/density-independent units (IOS-POINTS, ANDROID-DP-SP)."
            },
            "fontScale": {
              "type": "boolean",
              "description": "Whether the value scales with the user's font settings.",
              "$comment": "When true, MUST follow Dynamic Type (IOS-DYNAMIC-TYPE) and Android scale-independent behaviour (ANDROID-DP-SP)."
            }
          },
          "additionalProperties": false
        },
        {
          "$ref": "#/$defs/reference"
        }
      ]
    },
    "length-dimension": {
      "type": "object",
      "required": ["dimensionType", "value", "unit"],
      "properties": {
        "dimensionType": {
          "const": "length"
        },
        "value": {
          "type": "number"
        },
        "unit": {
          "type": "string",
          "pattern": "^(?:%|[Cc][Mm]|[Mm][Mm]|[Qq]|[Ii][Nn]|[Pp][Tt]|[Pp][Cc]|[Pp][Xx]|[Ee][Mm]|[Ee][Xx]|[Cc][Aa][Pp]|[Cc][Hh]|[Ii][Cc]|[Rr][Ee][Mm]|[Rr][Ee][Xx]|[Rr][Cc][Aa][Pp]|[Rr][Cc][Hh]|[Rr][Ii][Cc]|[Ll][Hh]|[Rr][Ll][Hh]|[Vv][Ww]|[Vv][Hh]|[Vv][Ii]|[Vv][Bb]|[Vv][Mm][Ii][Nn]|[Vv][Mm][Aa][Xx]|[Ss][Vv][Ww]|[Ss][Vv][Hh]|[Ss][Vv][Ii]|[Ss][Vv][Bb]|[Ss][Vv][Mm][Ii][Nn]|[Ss][Vv][Mm][Aa][Xx]|[Ll][Vv][Ww]|[Ll][Vv][Hh]|[Ll][Vv][Ii]|[Ll][Vv][Bb]|[Ll][Vv][Mm][Ii][Nn]|[Ll][Vv][Mm][Aa][Xx]|[Dd][Vv][Ww]|[Dd][Vv][Hh]|[Dd][Vv][Ii]|[Dd][Vv][Bb]|[Dd][Vv][Mm][Ii][Nn]|[Dd][Vv][Mm][Aa][Xx]|[Cc][Qq][Ww]|[Cc][Qq][Hh]|[Cc][Qq][Ii]|[Cc][Qq][Bb]|[Cc][Qq][Mm][Ii][Nn]|[Cc][Qq][Mm][Aa][Xx]|[Dd][Pp]|[Ss][Pp])$",
          "$comment": "MUST conform to CSS <length> or <percentage> (css-values-4) or native point/density-independent units (IOS-POINTS, ANDROID-DP-SP)."
        },
        "fontScale": {
          "type": "boolean",
          "description": "Whether the value scales with the user's font settings.",
          "$comment": "When true, MUST follow Dynamic Type (IOS-DYNAMIC-TYPE) and Android scale-independent behaviour (ANDROID-DP-SP)."
        }
      },
      "additionalProperties": false
    },
    "angle-dimension": {
      "type": "object",
      "required": ["dimensionType", "value", "unit"],
      "properties": {
        "dimensionType": {
          "const": "angle"
        },
        "value": {
          "type": "number"
        },
        "unit": {
          "type": "string",
          "pattern": "^(?:[Dd][Ee][Gg]|[Gg][Rr][Aa][Dd]|[Rr][Aa][Dd]|[Tt][Uu][Rr][Nn])$",
          "$comment": "MUST conform to CSS <angle> production (css-values-4)."
        }
      },
      "additionalProperties": false
    },
    "lineHeightValueEntry": {
      "title": "Line-height value entry",
      "description": "Ratio, font-dimension, alias, or computed expression per Typography §line-height.",
      "$comment": "Typography §line-height and Token types §value: line-height tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/line-height"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "lineHeightValueFallback": {
      "title": "Line-height fallback list",
      "description": "Ordered fallback list of line-height values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/lineHeightValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "lineHeightTokenValue": {
      "title": "Line-height token value",
      "description": "Line-height literal, alias, or fallback list per Typography §line-height.",
      "$comment": "Typography §line-height: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/lineHeightValueEntry"
        },
        {
          "$ref": "#/$defs/lineHeightValueFallback"
        }
      ]
    },
    "line-height": {
      "title": "Line height value",
      "description": "Unitless ratio or font-dimension measurement describing baseline spacing per Typography §line-height.",
      "$comment": "Typography §line-height: value MUST be a non-negative ratio or font-dimension measurement.",
      "oneOf": [
        {
          "type": "number",
          "minimum": 0,
          "description": "Ratio multiplied by fontSize to compute baseline-to-baseline distance."
        },
        {
          "allOf": [
            {
              "$ref": "#/$defs/font-dimension"
            },
            {
              "if": {
                "required": ["$ref"],
                "type": "object",
                "properties": {
                  "$ref": {}
                }
              },
              "then": {},
              "else": {
                "properties": {
                  "value": {
                    "type": "number",
                    "minimum": 0,
                    "description": "Non-negative font-dimension magnitude for line height measurements."
                  }
                },
                "type": "object"
              }
            }
          ]
        }
      ]
    },
    "colorValueEntry": {
      "title": "Color value entry",
      "description": "Literal colour payload, alias, or computed expression per Token types §color.",
      "$comment": "Token types §color and §value: color tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/color"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "colorValueFallback": {
      "title": "Color fallback list",
      "description": "Ordered fallback list of colour values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/colorValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "colorTokenValue": {
      "title": "Color token value",
      "description": "Color literal, alias, or fallback list per Token types §color.",
      "$comment": "Token types §color: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/colorValueEntry"
        },
        {
          "$ref": "#/$defs/colorValueFallback"
        }
      ]
    },
    "color": {
      "type": "object",
      "required": ["colorSpace", "components"],
      "properties": {
        "colorSpace": {
          "$ref": "#/$defs/css-ident",
          "$comment": "MUST be a CSS <ident> naming a colour space defined by CSS Color 4 or registered via @color-profile (css-color-4)."
        },
        "components": {
          "type": "array",
          "minItems": 1,
          "items": {
            "type": "number"
          },
          "$comment": "Channel order, ranges, and optional alpha MUST follow CSS Color 4 for the referenced colour space (css-color-4)."
        },
        "hex": {
          "type": "string",
          "pattern": "^#(?:[0-9A-Fa-f]{3}|[0-9A-Fa-f]{4}|[0-9A-Fa-f]{6}|[0-9A-Fa-f]{8})$",
          "$comment": "Optional CSS hexadecimal colour serialization (css-color-4)."
        },
        "alpha": {
          "type": "number",
          "minimum": 0,
          "maximum": 1,
          "$comment": "Optional fallback alpha matching CSS <alpha-value> semantics (css-color-4)."
        }
      },
      "additionalProperties": false,
      "allOf": [
        {
          "if": {
            "required": ["alpha"],
            "type": "object",
            "properties": {
              "alpha": {}
            }
          },
          "then": {
            "required": ["hex"],
            "type": "object",
            "properties": {
              "hex": {}
            }
          }
        },
        {
          "if": {
            "required": ["hex"],
            "type": "object",
            "properties": {
              "hex": {}
            }
          },
          "then": {
            "properties": {
              "colorSpace": {
                "const": "srgb",
                "$comment": "Hexadecimal strings serialize sRGB colours (css-color-4)."
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "colorSpace": {
                "type": "string",
                "pattern": "^(?:[Ss][Rr][Gg][Bb]|[Ss][Rr][Gg][Bb]-[Ll][Ii][Nn][Ee][Aa][Rr]|[Dd][Ii][Ss][Pp][Ll][Aa][Yy]-[Pp]3|[Aa]98-[Rr][Gg][Bb]|[Pp][Rr][Oo][Pp][Hh][Oo][Tt][Oo]-[Rr][Gg][Bb]|[Rr][Ee][Cc]2020|[Ll][Aa][Bb]|[Oo][Kk][Ll][Aa][Bb]|[Ll][Cc][Hh]|[Oo][Kk][Ll][Cc][Hh]|[Xx][Yy][Zz]|[Xx][Yy][Zz]-[Dd]50|[Xx][Yy][Zz]-[Dd]65|[Hh][Ss][Ll]|[Hh][Ww][Bb])$"
              }
            },
            "required": ["colorSpace"],
            "type": "object"
          },
          "then": {
            "properties": {
              "components": {
                "type": "array",
                "minItems": 3,
                "maxItems": 4,
                "$comment": "Known CSS Color 4 spaces listed by DTIF require three channels with optional alpha."
              }
            },
            "type": "object"
          }
        }
      ]
    },
    "cursorValueEntry": {
      "title": "Cursor value entry",
      "description": "Literal cursor payload, alias, or computed expression per Token types §cursor.",
      "$comment": "Token types §cursor and §value: cursor tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/cursor"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "cursorValueFallback": {
      "title": "Cursor fallback list",
      "description": "Ordered fallback list of cursor values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/cursorValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "cursorTokenValue": {
      "title": "Cursor token value",
      "description": "Cursor literal, alias, or fallback list per Token types §cursor.",
      "$comment": "Token types §cursor: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/cursorValueEntry"
        },
        {
          "$ref": "#/$defs/cursorValueFallback"
        }
      ]
    },
    "cursor": {
      "type": "object",
      "required": ["cursorType", "value"],
      "properties": {
        "cursorType": {
          "title": "Cursor context identifier",
          "description": "Platform-qualified cursor context such as css.cursor, ios.uipointerstyle, or android.pointer-icon.",
          "$comment": "MUST identify pointer contexts defined by CSS cursor grammars, UIKit UIPointerStyle APIs, or Android PointerIcon classes (e.g. css.cursor, ios.uipointerstyle, android.pointer-icon).",
          "allOf": [
            {
              "$ref": "#/$defs/platform-identifier"
            }
          ]
        },
        "value": {
          "oneOf": [
            {
              "type": "string",
              "minLength": 1,
              "$comment": "String values MUST conform to the CSS <cursor> production (css-ui-4#propdef-cursor) or name native pointer styles/icons published by UIPointerStyle and PointerIcon."
            },
            {
              "type": "object",
              "minProperties": 1,
              "$comment": "Object values MAY encode structured pointer metadata (for example UIPointerStyle.shape or PointerIcon hotspots) and MUST follow the platform APIs they reference.",
              "propertyNames": {
                "type": "string",
                "pattern": "^(?!\\$)"
              },
              "additionalProperties": true
            }
          ]
        },
        "parameters": {
          "type": "object",
          "propertyNames": {
            "type": "string",
            "pattern": "^(?!\\$)"
          },
          "additionalProperties": true,
          "$comment": "Optional parameters supply reusable inputs such as hotspot coordinates or referenced tokens consumed by pointer APIs."
        }
      },
      "additionalProperties": false
    },
    "font-weight-string": {
      "type": "string",
      "pattern": "^(?:[Bb][Oo][Ll][Dd][Ee][Rr]|[Ll][Ii][Gg][Hh][Tt][Ee][Rr]|(?:[Nn][Oo][Rr][Mm][Aa][Ll]|[Bb][Oo][Ll][Dd]|\\+?(?:0*(?:[1-9]\\d{0,2})(?:\\.\\d+)?|0*1000(?:\\.0+)?))(?:\\s+(?:[Nn][Oo][Rr][Mm][Aa][Ll]|[Bb][Oo][Ll][Dd]|\\+?(?:0*(?:[1-9]\\d{0,2})(?:\\.\\d+)?|0*1000(?:\\.0+)?)))?)$",
      "$comment": "String weights MUST conform to CSS <font-weight-absolute>, <font-weight-relative>, or <font-weight-range> productions (css-fonts-4)."
    },
    "font-style-string": {
      "type": "string",
      "pattern": "^(?:[Nn][Oo][Rr][Mm][Aa][Ll]|[Ii][Tt][Aa][Ll][Ii][Cc]|[Oo][Bb][Ll][Ii][Qq][Uu][Ee](?:\\s+[-+]?(?:\\d+(?:\\.\\d+)?|\\.\\d+)(?:[Ee][+-]?\\d+)?(?:[Dd][Ee][Gg]|[Gg][Rr][Aa][Dd]|[Rr][Aa][Dd]|[Tt][Uu][Rr][Nn]))?)$",
      "$comment": "Font style keywords MUST match CSS font-style grammar, optionally supplying an oblique angle (css-fonts-4, css-values-4)."
    },
    "font-variant-string": {
      "type": "string",
      "pattern": "^(?:[Nn][Oo][Rr][Mm][Aa][Ll]|[Nn][Oo][Nn][Ee]|(?:(?:[Cc][Oo][Mm][Mm][Oo][Nn]-[Ll][Ii][Gg][Aa][Tt][Uu][Rr][Ee][Ss]|[Nn][Oo]-[Cc][Oo][Mm][Mm][Oo][Nn]-[Ll][Ii][Gg][Aa][Tt][Uu][Rr][Ee][Ss]|[Dd][Ii][Ss][Cc][Rr][Ee][Tt][Ii][Oo][Nn][Aa][Rr][Yy]-[Ll][Ii][Gg][Aa][Tt][Uu][Rr][Ee][Ss]|[Nn][Oo]-[Dd][Ii][Ss][Cc][Rr][Ee][Tt][Ii][Oo][Nn][Aa][Rr][Yy]-[Ll][Ii][Gg][Aa][Tt][Uu][Rr][Ee][Ss]|[Hh][Ii][Ss][Tt][Oo][Rr][Ii][Cc][Aa][Ll]-[Ll][Ii][Gg][Aa][Tt][Uu][Rr][Ee][Ss]|[Nn][Oo]-[Hh][Ii][Ss][Tt][Oo][Rr][Ii][Cc][Aa][Ll]-[Ll][Ii][Gg][Aa][Tt][Uu][Rr][Ee][Ss]|[Cc][Oo][Nn][Tt][Ee][Xx][Tt][Uu][Aa][Ll]|[Nn][Oo]-[Cc][Oo][Nn][Tt][Ee][Xx][Tt][Uu][Aa][Ll]|[Ss][Mm][Aa][Ll][Ll]-[Cc][Aa][Pp][Ss]|[Aa][Ll][Ll]-[Ss][Mm][Aa][Ll][Ll]-[Cc][Aa][Pp][Ss]|[Pp][Ee][Tt][Ii][Tt][Ee]-[Cc][Aa][Pp][Ss]|[Aa][Ll][Ll]-[Pp][Ee][Tt][Ii][Tt][Ee]-[Cc][Aa][Pp][Ss]|[Uu][Nn][Ii][Cc][Aa][Ss][Ee]|[Tt][Ii][Tt][Ll][Ii][Nn][Gg]-[Cc][Aa][Pp][Ss]|[Ll][Ii][Nn][Ii][Nn][Gg]-[Nn][Uu][Mm][Ss]|[Oo][Ll][Dd][Ss][Tt][Yy][Ll][Ee]-[Nn][Uu][Mm][Ss]|[Pp][Rr][Oo][Pp][Oo][Rr][Tt][Ii][Oo][Nn][Aa][Ll]-[Nn][Uu][Mm][Ss]|[Tt][Aa][Bb][Uu][Ll][Aa][Rr]-[Nn][Uu][Mm][Ss]|[Dd][Ii][Aa][Gg][Oo][Nn][Aa][Ll]-[Ff][Rr][Aa][Cc][Tt][Ii][Oo][Nn][Ss]|[Ss][Tt][Aa][Cc][Kk][Ee][Dd]-[Ff][Rr][Aa][Cc][Tt][Ii][Oo][Nn][Ss]|[Oo][Rr][Dd][Ii][Nn][Aa][Ll]|[Ss][Ll][Aa][Ss][Hh][Ee][Dd]-[Zz][Ee][Rr][Oo]|[Jj][Ii][Ss]78|[Jj][Ii][Ss]83|[Jj][Ii][Ss]90|[Jj][Ii][Ss]04|[Ss][Ii][Mm][Pp][Ll][Ii][Ff][Ii][Ee][Dd]|[Tt][Rr][Aa][Dd][Ii][Tt][Ii][Oo][Nn][Aa][Ll]|[Ff][Uu][Ll][Ll]-[Ww][Ii][Dd][Tt][Hh]|[Pp][Rr][Oo][Pp][Oo][Rr][Tt][Ii][Oo][Nn][Aa][Ll]-[Ww][Ii][Dd][Tt][Hh]|[Rr][Uu][Bb][Yy]|[Ss][Uu][Bb]|[Ss][Uu][Pp][Ee][Rr]|[Hh][Ii][Ss][Tt][Oo][Rr][Ii][Cc][Aa][Ll]-[Ff][Oo][Rr][Mm][Ss]|[Ss][Tt][Yy][Ll][Ii][Ss][Tt][Ii][Cc]\\(\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*\\s*\\)|[Ss][Tt][Yy][Ll][Ee][Ss][Ee][Tt]\\(\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*(?:\\s*,\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*)*\\s*\\)|[Cc][Hh][Aa][Rr][Aa][Cc][Tt][Ee][Rr]-[Vv][Aa][Rr][Ii][Aa][Nn][Tt]\\(\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*(?:\\s*,\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*)*\\s*\\)|[Ss][Ww][Aa][Ss][Hh]\\(\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*\\s*\\)|[Oo][Rr][Nn][Aa][Mm][Ee][Nn][Tt][Ss]\\(\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*\\s*\\)|[Aa][Nn][Nn][Oo][Tt][Aa][Tt][Ii][Oo][Nn]\\(\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*(?:\\s*,\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*)*\\s*\\))(?:\\s+(?:[Cc][Oo][Mm][Mm][Oo][Nn]-[Ll][Ii][Gg][Aa][Tt][Uu][Rr][Ee][Ss]|[Nn][Oo]-[Cc][Oo][Mm][Mm][Oo][Nn]-[Ll][Ii][Gg][Aa][Tt][Uu][Rr][Ee][Ss]|[Dd][Ii][Ss][Cc][Rr][Ee][Tt][Ii][Oo][Nn][Aa][Rr][Yy]-[Ll][Ii][Gg][Aa][Tt][Uu][Rr][Ee][Ss]|[Nn][Oo]-[Dd][Ii][Ss][Cc][Rr][Ee][Tt][Ii][Oo][Nn][Aa][Rr][Yy]-[Ll][Ii][Gg][Aa][Tt][Uu][Rr][Ee][Ss]|[Hh][Ii][Ss][Tt][Oo][Rr][Ii][Cc][Aa][Ll]-[Ll][Ii][Gg][Aa][Tt][Uu][Rr][Ee][Ss]|[Nn][Oo]-[Hh][Ii][Ss][Tt][Oo][Rr][Ii][Cc][Aa][Ll]-[Ll][Ii][Gg][Aa][Tt][Uu][Rr][Ee][Ss]|[Cc][Oo][Nn][Tt][Ee][Xx][Tt][Uu][Aa][Ll]|[Nn][Oo]-[Cc][Oo][Nn][Tt][Ee][Xx][Tt][Uu][Aa][Ll]|[Ss][Mm][Aa][Ll][Ll]-[Cc][Aa][Pp][Ss]|[Aa][Ll][Ll]-[Ss][Mm][Aa][Ll][Ll]-[Cc][Aa][Pp][Ss]|[Pp][Ee][Tt][Ii][Tt][Ee]-[Cc][Aa][Pp][Ss]|[Aa][Ll][Ll]-[Pp][Ee][Tt][Ii][Tt][Ee]-[Cc][Aa][Pp][Ss]|[Uu][Nn][Ii][Cc][Aa][Ss][Ee]|[Tt][Ii][Tt][Ll][Ii][Nn][Gg]-[Cc][Aa][Pp][Ss]|[Ll][Ii][Nn][Ii][Nn][Gg]-[Nn][Uu][Mm][Ss]|[Oo][Ll][Dd][Ss][Tt][Yy][Ll][Ee]-[Nn][Uu][Mm][Ss]|[Pp][Rr][Oo][Pp][Oo][Rr][Tt][Ii][Oo][Nn][Aa][Ll]-[Nn][Uu][Mm][Ss]|[Tt][Aa][Bb][Uu][Ll][Aa][Rr]-[Nn][Uu][Mm][Ss]|[Dd][Ii][Aa][Gg][Oo][Nn][Aa][Ll]-[Ff][Rr][Aa][Cc][Tt][Ii][Oo][Nn][Ss]|[Ss][Tt][Aa][Cc][Kk][Ee][Dd]-[Ff][Rr][Aa][Cc][Tt][Ii][Oo][Nn][Ss]|[Oo][Rr][Dd][Ii][Nn][Aa][Ll]|[Ss][Ll][Aa][Ss][Hh][Ee][Dd]-[Zz][Ee][Rr][Oo]|[Jj][Ii][Ss]78|[Jj][Ii][Ss]83|[Jj][Ii][Ss]90|[Jj][Ii][Ss]04|[Ss][Ii][Mm][Pp][Ll][Ii][Ff][Ii][Ee][Dd]|[Tt][Rr][Aa][Dd][Ii][Tt][Ii][Oo][Nn][Aa][Ll]|[Ff][Uu][Ll][Ll]-[Ww][Ii][Dd][Tt][Hh]|[Pp][Rr][Oo][Pp][Oo][Rr][Tt][Ii][Oo][Nn][Aa][Ll]-[Ww][Ii][Dd][Tt][Hh]|[Rr][Uu][Bb][Yy]|[Ss][Uu][Bb]|[Ss][Uu][Pp][Ee][Rr]|[Hh][Ii][Ss][Tt][Oo][Rr][Ii][Cc][Aa][Ll]-[Ff][Oo][Rr][Mm][Ss]|[Ss][Tt][Yy][Ll][Ii][Ss][Tt][Ii][Cc]\\(\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*\\s*\\)|[Ss][Tt][Yy][Ll][Ee][Ss][Ee][Tt]\\(\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*(?:\\s*,\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*)*\\s*\\)|[Cc][Hh][Aa][Rr][Aa][Cc][Tt][Ee][Rr]-[Vv][Aa][Rr][Ii][Aa][Nn][Tt]\\(\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*(?:\\s*,\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*)*\\s*\\)|[Ss][Ww][Aa][Ss][Hh]\\(\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*\\s*\\)|[Oo][Rr][Nn][Aa][Mm][Ee][Nn][Tt][Ss]\\(\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*\\s*\\)|[Aa][Nn][Nn][Oo][Tt][Aa][Tt][Ii][Oo][Nn]\\(\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*(?:\\s*,\\s*-{0,2}[A-Za-z_][A-Za-z0-9_-]*)*\\s*\\)))*))$",
      "$comment": "Font variant sequences MUST match CSS font-variant grammar (css-fonts-4)."
    },
    "font-stretch-string": {
      "type": "string",
      "pattern": "^(?:[Nn][Oo][Rr][Mm][Aa][Ll]|(?:[Uu][Ll][Tt][Rr][Aa]|[Ee][Xx][Tt][Rr][Aa]|[Ss][Ee][Mm][Ii])-[Cc][Oo][Nn][Dd][Ee][Nn][Ss][Ee][Dd]|[Cc][Oo][Nn][Dd][Ee][Nn][Ss][Ee][Dd]|(?:[Ss][Ee][Mm][Ii]|[Ee][Xx][Tt][Rr][Aa]|[Uu][Ll][Tt][Rr][Aa])-[Ee][Xx][Pp][Aa][Nn][Dd][Ee][Dd]|[Ee][Xx][Pp][Aa][Nn][Dd][Ee][Dd]|\\+?(?:0*(?:[1-9]\\d{0,2})(?:\\.\\d+)?|0*1000(?:\\.0+)?)%)$",
      "$comment": "Font stretch values MUST match CSS <font-stretch-absolute> grammar (css-fonts-4)."
    },
    "fontValueEntry": {
      "title": "Font value entry",
      "description": "Literal font payload, alias, or computed expression per Token types §font.",
      "$comment": "Token types §font and §value: font tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/font"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "fontValueFallback": {
      "title": "Font fallback list",
      "description": "Ordered fallback list of font values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/fontValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "fontTokenValue": {
      "title": "Font token value",
      "description": "Font literal, alias, or fallback list per Token types §font.",
      "$comment": "Token types §font: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/fontValueEntry"
        },
        {
          "$ref": "#/$defs/fontValueFallback"
        }
      ]
    },
    "font": {
      "type": "object",
      "required": ["fontType", "family"],
      "properties": {
        "fontType": {
          "title": "Font resource identifier",
          "description": "Platform-qualified font provider such as css.font-face, ios.uiFont, or android.font-resource.",
          "$comment": "MUST identify platform context and asset source using dot-separated identifiers aligned with CSS Fonts src descriptors, UIKit UIFont APIs, or Android font resource/typeface loaders.",
          "allOf": [
            {
              "$ref": "#/$defs/platform-identifier"
            }
          ]
        },
        "family": {
          "title": "Font family",
          "description": "Family name following CSS <family-name> grammar or platform catalog registrations.",
          "$comment": "CSS Fonts §font-family-names and Typography §font require CSS <family-name> strings or platform catalog identifiers.",
          "allOf": [
            {
              "$ref": "#/$defs/css-family-name"
            }
          ]
        },
        "fallbacks": {
          "type": "array",
          "minItems": 1,
          "items": {
            "$ref": "#/$defs/css-family-name"
          },
          "$comment": "Fallback stacks MUST preserve order and reuse CSS <family-name> grammar and generic family keywords (css-fonts-4) so they align with platform catalog registrations (IOS-FONT-CATALOG, ANDROID-FONT-FAMILY)."
        },
        "style": {
          "$ref": "#/$defs/font-style-string",
          "$comment": "MUST conform to CSS <font-style-absolute> grammar (css-fonts-4); angles MUST follow <angle> (css-values-4)."
        },
        "weight": {
          "oneOf": [
            {
              "type": "number",
              "minimum": 1,
              "maximum": 1000,
              "$comment": "Numeric weights MUST follow the 1..1000 range defined by CSS Fonts (css-fonts-4)."
            },
            {
              "$ref": "#/$defs/font-weight-string"
            }
          ]
        }
      },
      "additionalProperties": false
    },
    "fontFaceValueEntry": {
      "title": "Font face value entry",
      "description": "Literal font-face payload, alias, or computed expression per Typography §font-face.",
      "$comment": "Typography §font-face and Token types §value: fontFace tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/fontFace"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "fontFaceValueFallback": {
      "title": "Font face fallback list",
      "description": "Ordered fallback list of font-face values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/fontFaceValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "fontFaceTokenValue": {
      "title": "Font face token value",
      "description": "Font-face literal, alias, or fallback list per Typography §font-face.",
      "$comment": "Typography §font-face: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/fontFaceValueEntry"
        },
        {
          "$ref": "#/$defs/fontFaceValueFallback"
        }
      ]
    },
    "fontFace": {
      "type": "object",
      "required": ["src", "fontFamily"],
      "properties": {
        "src": {
          "type": "array",
          "minItems": 1,
          "$comment": "Entries MUST correspond to CSS @font-face src descriptors (css-fonts-4) and map to bundled/downloadable font resources registered through iOS font catalogs and Android font resources (IOS-FONT-CATALOG, ANDROID-FONT-FAMILY).",
          "items": {
            "oneOf": [
              {
                "type": "object",
                "required": ["url"],
                "properties": {
                  "url": {
                    "title": "Font resource URL",
                    "description": "Relative or absolute URL compatible with CSS url() and native font registration APIs.",
                    "type": "string",
                    "format": "uri-reference",
                    "$comment": "Font URLs MUST resolve to resources used by CSS url() and native registration APIs (css-fonts-4, IOS-FONT-CATALOG, ANDROID-FONT-FAMILY).",
                    "allOf": [
                      {
                        "$ref": "#/$defs/trimmedString"
                      }
                    ]
                  },
                  "format": {
                    "oneOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "array",
                        "minItems": 1,
                        "items": {
                          "type": "string"
                        }
                      }
                    ],
                    "$comment": "Font format hints MUST match CSS src format() descriptors (css-fonts-4)."
                  },
                  "tech": {
                    "type": "array",
                    "minItems": 1,
                    "items": {
                      "type": "string"
                    },
                    "$comment": "Technology hints MUST align with CSS src tech() identifiers (css-fonts-4#font-tech-values)."
                  }
                },
                "additionalProperties": false
              },
              {
                "type": "object",
                "required": ["local"],
                "properties": {
                  "local": {
                    "title": "Local font name",
                    "description": "Local font reference matching CSS src local() <family-name> grammar and platform catalogs.",
                    "$comment": "Local font references MUST match CSS src local() <family-name> grammar and platform catalog registrations (css-fonts-4, IOS-FONT-CATALOG, ANDROID-FONT-FAMILY).",
                    "allOf": [
                      {
                        "$ref": "#/$defs/css-family-name"
                      }
                    ]
                  }
                },
                "additionalProperties": false
              }
            ]
          }
        },
        "fontFamily": {
          "title": "Font family",
          "description": "Family name following CSS <family-name> grammar or platform catalog registrations.",
          "$comment": "Typography §font-face requires CSS <family-name> strings or platform catalog identifiers (css-fonts-4, IOS-FONT-CATALOG, ANDROID-FONT-FAMILY).",
          "allOf": [
            {
              "$ref": "#/$defs/css-family-name"
            }
          ]
        },
        "fontWeight": {
          "oneOf": [
            {
              "type": "number",
              "minimum": 1,
              "maximum": 1000,
              "$comment": "Numeric weights MUST follow the 1..1000 range defined by CSS Fonts (css-fonts-4)."
            },
            {
              "$ref": "#/$defs/font-weight-string"
            }
          ]
        },
        "fontStyle": {
          "$ref": "#/$defs/font-style-string",
          "$comment": "MUST conform to CSS font-style descriptor grammar (css-fonts-4); oblique angles map to the slnt variation axis per UIFontDescriptor.AttributeName.variations and Typeface.Builder#setFontVariationSettings (IOS-FONT-VARIATIONS, ANDROID-FONT-VARIATION)."
        },
        "fontStretch": {
          "$ref": "#/$defs/font-stretch-string",
          "$comment": "Stretch keywords MUST follow CSS <font-stretch-absolute> grammar (css-fonts-4)."
        },
        "unicodeRange": {
          "type": "string",
          "pattern": "^(?:U\\+[0-9A-F?]{1,6}(?:-[0-9A-F?]{1,6})?)(?:\\s*,\\s*U\\+[0-9A-F?]{1,6}(?:-[0-9A-F?]{1,6})?)*$",
          "$comment": "Ranges MUST conform to the CSS unicode-range descriptor grammar (css-fonts-4)."
        },
        "fontDisplay": {
          "type": "string",
          "pattern": "^(?:[Aa][Uu][Tt][Oo]|[Bb][Ll][Oo][Cc][Kk]|[Ss][Ww][Aa][Pp]|[Ff][Aa][Ll][Ll][Bb][Aa][Cc][Kk]|[Oo][Pp][Tt][Ii][Oo][Nn][Aa][Ll])$",
          "$comment": "Display strategy MUST use the css-fonts-4 font-display keywords; native runtimes map these hints to preload/async policies."
        }
      },
      "additionalProperties": false
    },
    "typographyValueEntry": {
      "title": "Typography value entry",
      "description": "Literal typography payload, alias, or computed expression per Typography §typography.",
      "$comment": "Typography §typography and Token types §value: typography tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/typography"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "typographyValueFallback": {
      "title": "Typography fallback list",
      "description": "Ordered fallback list of typography values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/typographyValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "typographyTokenValue": {
      "title": "Typography token value",
      "description": "Typography literal, alias, or fallback list per Typography §typography.",
      "$comment": "Typography §typography: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/typographyValueEntry"
        },
        {
          "$ref": "#/$defs/typographyValueFallback"
        }
      ]
    },
    "typography": {
      "type": "object",
      "required": ["fontFamily", "fontSize"],
      "propertyNames": {
        "type": "string",
        "pattern": "^(?!\\$)",
        "$comment": "Conformance §conformance-classes and Extensibility §extensibility: reserved members beginning with $ are invalid outside schema-defined extension payloads."
      },
      "properties": {
        "typographyType": {
          "type": "string",
          "pattern": "^[a-zA-Z][\\w-]*$",
          "description": "Canonical values such as 'body', 'heading', and 'caption' are registered. Custom values matching this pattern MAY be used; consumers MUST ignore unrecognised types to preserve compatibility."
        },
        "fontFamily": {
          "title": "Typography font family",
          "description": "Family name string or reference providing the typography font family.",
          "$comment": "Typography §typography: fontFamily strings MUST follow CSS <family-name> grammar or reference an existing font token.",
          "oneOf": [
            {
              "allOf": [
                {
                  "$ref": "#/$defs/css-family-name"
                }
              ]
            },
            {
              "$ref": "#/$defs/reference"
            }
          ]
        },
        "fontSize": {
          "$ref": "#/$defs/fontDimensionReference"
        },
        "lineHeight": {
          "description": "Baseline-to-baseline distance as a ratio or font-dimension.",
          "allOf": [
            {
              "$ref": "#/$defs/line-height"
            }
          ]
        },
        "letterSpacing": {
          "$comment": "MUST follow CSS letter-spacing grammar and reuse font-dimension unit conversions.",
          "oneOf": [
            {
              "$ref": "#/$defs/fontDimensionReference"
            },
            {
              "type": "string",
              "enum": ["normal"],
              "$comment": "MUST be the keyword 'normal' per CSS Text Module Level 3 letter-spacing grammar."
            }
          ]
        },
        "wordSpacing": {
          "$comment": "MUST conform to CSS word-spacing <length-percentage> grammar and platform unit semantics.",
          "oneOf": [
            {
              "$ref": "#/$defs/fontDimensionReference"
            },
            {
              "type": "string",
              "enum": ["normal"],
              "$comment": "MUST be the keyword 'normal' per CSS Text Module Level 3 word-spacing grammar."
            }
          ]
        },
        "fontWeight": {
          "$comment": "MUST match CSS font-weight absolute or relative productions and map to platform weight APIs.",
          "oneOf": [
            {
              "type": "number",
              "minimum": 1,
              "maximum": 1000,
              "$comment": "MUST be within the CSS absolute weight range of 1-1000 and MAY include fractional values for variable fonts."
            },
            {
              "$ref": "#/$defs/font-weight-string"
            }
          ]
        },
        "fontStyle": {
          "$ref": "#/$defs/font-style-string",
          "$comment": "MUST conform to CSS font-style grammar and map to native italic traits or the slnt variation axis (css-fonts-4, IOS-FONT-TRAITS, IOS-FONT-VARIATIONS, ANDROID-FONT-SLANT, ANDROID-FONT-VARIATION)."
        },
        "fontVariant": {
          "$ref": "#/$defs/font-variant-string",
          "$comment": "MUST match the CSS font-variant grammar when present."
        },
        "fontStretch": {
          "$ref": "#/$defs/font-stretch-string",
          "$comment": "MUST match the CSS font-stretch grammar when present."
        },
        "textDecoration": {
          "title": "Text decoration",
          "description": "CSS text-decoration shorthand including line, style, colour, and thickness components per Typography §text-decoration.",
          "$comment": "Typography §text-decoration: values MUST follow the CSS text-decoration shorthand grammar, including colour keywords and <length-percentage> thickness tokens.",
          "allOf": [
            {
              "$ref": "#/$defs/text-decoration-shorthand"
            }
          ]
        },
        "textTransform": {
          "title": "Text transform",
          "description": "Keyword list matching the CSS text-transform grammar per Typography §text-transform.",
          "$comment": "Typography §text-transform: values MUST follow the <text-transform-list> grammar and remain locale-sensitive.",
          "allOf": [
            {
              "$ref": "#/$defs/text-transform-list"
            }
          ]
        },
        "color": {
          "$ref": "#/$defs/colorReference"
        },
        "fontFeatures": {
          "type": "array",
          "$comment": "MUST contain OpenType feature tags per CSS font-feature-settings and the OpenType registry.",
          "items": {
            "type": "string",
            "pattern": "^[A-Za-z0-9]{4}$",
            "$comment": "MUST be a four-character OpenType feature tag registered by CSS font-feature-settings or documented by the font."
          }
        },
        "underlineThickness": {
          "$ref": "#/$defs/fontDimensionReference"
        },
        "underlineOffset": {
          "$ref": "#/$defs/fontDimensionReference"
        },
        "overlineThickness": {
          "$ref": "#/$defs/fontDimensionReference"
        },
        "overlineOffset": {
          "$ref": "#/$defs/fontDimensionReference"
        }
      },
      "additionalProperties": true
    },
    "borderCornerRadius": {
      "anyOf": [
        {
          "$ref": "#/$defs/dimensionReference",
          "$comment": "Single value MUST follow the <length-percentage> grammar defined for CSS border-radius."
        },
        {
          "type": "object",
          "required": ["x"],
          "properties": {
            "x": {
              "$ref": "#/$defs/dimensionReference",
              "$comment": "Horizontal radius MUST conform to CSS <length-percentage> and native point/density semantics."
            },
            "y": {
              "$ref": "#/$defs/dimensionReference",
              "$comment": "Optional vertical radius MUST conform to CSS <length-percentage>; when omitted, consumers reuse the horizontal value."
            }
          },
          "additionalProperties": false,
          "$comment": "Encodes the <length-percentage>{1,2} grammar used by border-top-left-radius and related properties."
        }
      ]
    },
    "borderValueEntry": {
      "title": "Border value entry",
      "description": "Literal border payload, alias, or computed expression per Token types §border tokens.",
      "$comment": "Token types §border tokens and §value: border tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/border"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "borderValueFallback": {
      "title": "Border fallback list",
      "description": "Ordered fallback list of border values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/borderValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "borderTokenValue": {
      "title": "Border token value",
      "description": "Border literal, alias, or fallback list per Token types §border tokens.",
      "$comment": "Token types §border tokens: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/borderValueEntry"
        },
        {
          "$ref": "#/$defs/borderValueFallback"
        }
      ]
    },
    "border": {
      "type": "object",
      "required": ["borderType", "width", "style", "color"],
      "properties": {
        "borderType": {
          "title": "Border context identifier",
          "description": "Platform-qualified border context such as css.border, ios.layer.border, or android.shape.stroke.",
          "$comment": "MUST identify CSS border/outline contexts or native stroke APIs such as CALayer and GradientDrawable.",
          "allOf": [
            {
              "$ref": "#/$defs/platform-identifier"
            }
          ]
        },
        "width": {
          "oneOf": [
            {
              "$ref": "#/$defs/dimensionReference"
            },
            {
              "type": "string",
              "enum": ["thin", "medium", "thick"]
            }
          ],
          "$comment": "Width MUST follow the <line-width> grammar, accepting CSS keywords or dimension values that respect point/density conversions for pt, dp, and sp units."
        },
        "style": {
          "title": "Border line style",
          "description": "CSS <line-style> keyword such as solid, dashed, or inset per Token types §border tokens.",
          "$comment": "Token types §border tokens: style MUST match CSS <line-style> keywords none, hidden, dotted, dashed, solid, double, groove, ridge, inset, or outset (css-backgrounds-3).",
          "type": "string",
          "enum": [
            "none",
            "hidden",
            "dotted",
            "dashed",
            "solid",
            "double",
            "groove",
            "ridge",
            "inset",
            "outset"
          ]
        },
        "strokeStyle": {
          "oneOf": [
            {
              "$ref": "#/$defs/strokeStyle"
            },
            {
              "$ref": "#/$defs/reference"
            }
          ],
          "$comment": "Optional strokeStyle metadata MUST capture dash, cap, and join semantics compatible with CSS border-image, SVG stroke, CAShapeLayer.lineDashPattern, and Android Paint#setPathEffect."
        },
        "color": {
          "$ref": "#/$defs/colorReference",
          "$comment": "Border colour MUST conform to CSS <color> values and convert to CGColor or Android colour integers."
        },
        "radius": {
          "anyOf": [
            {
              "$ref": "#/$defs/dimensionReference",
              "$comment": "Uniform radius MUST follow the border-radius <length-percentage> grammar."
            },
            {
              "type": "object",
              "minProperties": 1,
              "properties": {
                "topLeft": {
                  "$ref": "#/$defs/borderCornerRadius"
                },
                "topRight": {
                  "$ref": "#/$defs/borderCornerRadius"
                },
                "bottomRight": {
                  "$ref": "#/$defs/borderCornerRadius"
                },
                "bottomLeft": {
                  "$ref": "#/$defs/borderCornerRadius"
                },
                "topStart": {
                  "$ref": "#/$defs/borderCornerRadius"
                },
                "topEnd": {
                  "$ref": "#/$defs/borderCornerRadius"
                },
                "bottomStart": {
                  "$ref": "#/$defs/borderCornerRadius"
                },
                "bottomEnd": {
                  "$ref": "#/$defs/borderCornerRadius"
                }
              },
              "additionalProperties": false,
              "$comment": "Per-corner entries MUST follow border-radius semantics with names matching physical or logical corners."
            }
          ]
        }
      },
      "additionalProperties": false
    },
    "strokeStyleValueEntry": {
      "title": "Stroke style value entry",
      "description": "Literal stroke-style payload, alias, or computed expression per Token types §stroke-style tokens.",
      "$comment": "Token types §stroke-style tokens and §value: strokeStyle tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/strokeStyle"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "strokeStyleValueFallback": {
      "title": "Stroke style fallback list",
      "description": "Ordered fallback list of stroke-style values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/strokeStyleValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "strokeStyleTokenValue": {
      "title": "Stroke style token value",
      "description": "Stroke-style literal, alias, or fallback list per Token types §stroke-style tokens.",
      "$comment": "Token types §stroke-style tokens: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/strokeStyleValueEntry"
        },
        {
          "$ref": "#/$defs/strokeStyleValueFallback"
        }
      ]
    },
    "strokeStyle": {
      "type": "object",
      "minProperties": 1,
      "properties": {
        "dashArray": {
          "type": "array",
          "minItems": 1,
          "items": {
            "oneOf": [
              {
                "type": "number",
                "minimum": 0,
                "$comment": "Numeric dash intervals MUST follow the <number> grammar used by SVG stroke-dasharray and CanvasRenderingContext2D.setLineDash."
              },
              {
                "$ref": "#/$defs/lengthDimensionReference",
                "$comment": "Length dash intervals MUST conform to the <length> production accepted by SVG stroke-dasharray and CSS border-image repeat lengths."
              }
            ]
          },
          "$comment": "Sequence of dash and gap lengths MUST follow SVG stroke-dasharray semantics and map to CAShapeLayer.lineDashPattern and Android DashPathEffect intervals."
        },
        "dashOffset": {
          "oneOf": [
            {
              "type": "number",
              "$comment": "Numeric offsets MUST follow the <number> grammar from SVG stroke-dashoffset representing multiples of the stroke width."
            },
            {
              "$ref": "#/$defs/lengthDimensionReference",
              "$comment": "Length offsets MUST conform to CSS <length> semantics for stroke-dashoffset and native stroke APIs."
            }
          ]
        },
        "lineCap": {
          "type": "string",
          "enum": ["butt", "round", "square"],
          "$comment": "Line caps MUST match the <stroke-linecap> keywords butt, round, or square defined by SVG and Canvas 2D."
        },
        "lineJoin": {
          "type": "string",
          "enum": ["miter", "round", "bevel"],
          "$comment": "Line joins MUST match the <stroke-linejoin> keywords miter, round, or bevel defined by SVG and Canvas 2D."
        },
        "miterLimit": {
          "type": "number",
          "minimum": 1,
          "$comment": "Miter limits MUST be >= 1 following SVG stroke-miterlimit and CanvasRenderingContext2D.miterLimit semantics."
        }
      },
      "additionalProperties": false
    },
    "shadowValueEntry": {
      "title": "Shadow value entry",
      "description": "Literal shadow payload, alias, or computed expression per Token types §shadow tokens.",
      "$comment": "Token types §shadow tokens and §value: shadow tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/shadow"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "shadowValueFallback": {
      "title": "Shadow fallback list",
      "description": "Ordered fallback list of shadow values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/shadowValueEntry"
          },
          "contains": {
            "anyOf": [
              {
                "$ref": "#/$defs/reference"
              },
              {
                "$ref": "#/$defs/function"
              }
            ]
          },
          "minContains": 1,
          "type": "array"
        }
      ]
    },
    "shadowTokenValue": {
      "title": "Shadow token value",
      "description": "Shadow literal, alias, or fallback list per Token types §shadow tokens.",
      "$comment": "Token types §shadow tokens: tokens MAY specify inline values, references, or fallback arrays.",
      "allOf": [
        {
          "if": {
            "type": "array"
          },
          "then": {
            "allOf": [
              {
                "if": {
                  "contains": {
                    "anyOf": [
                      {
                        "$ref": "#/$defs/reference"
                      },
                      {
                        "$ref": "#/$defs/function"
                      }
                    ]
                  },
                  "type": "array"
                },
                "then": {
                  "$comment": "Arrays containing at least one alias or function are treated as fallback chains evaluated in order.",
                  "$ref": "#/$defs/shadowValueFallback"
                },
                "else": {
                  "title": "Shadow layer stack",
                  "description": "Non-empty array of literal shadow layers following CSS <shadow> ordering per Token types §shadow tokens.",
                  "$comment": "Token types §shadow tokens: arrays without alias or function entries represent literal multi-layer shadows.",
                  "type": "array",
                  "minItems": 1,
                  "items": {
                    "$ref": "#/$defs/shadow-layer"
                  }
                }
              }
            ]
          },
          "else": {
            "title": "Shadow literal or computed value",
            "description": "Single shadow layer, $ref alias, or function expression per Token types §shadow tokens.",
            "$comment": "Token types §shadow tokens and §value: non-array values MAY be inline layers, $ref aliases, or function objects.",
            "oneOf": [
              {
                "$ref": "#/$defs/shadow-layer"
              },
              {
                "$ref": "#/$defs/reference"
              },
              {
                "$ref": "#/$defs/function"
              }
            ]
          }
        }
      ]
    },
    "shadow": {
      "oneOf": [
        {
          "$ref": "#/$defs/shadow-layer"
        },
        {
          "type": "array",
          "minItems": 1,
          "items": {
            "$ref": "#/$defs/shadow-layer"
          }
        }
      ]
    },
    "shadow-layer": {
      "type": "object",
      "required": ["shadowType", "offsetX", "offsetY", "blur", "color"],
      "properties": {
        "shadowType": {
          "title": "Shadow context identifier",
          "description": "Rendering surface identifier such as css.box-shadow, css.text-shadow, ios.layer, or android.view.elevation.",
          "$comment": "MUST identify the rendering context defined by CSS <shadow> grammars, UIKit CALayer/NSShadow APIs, or Android View/Paint shadow documentation (e.g. css.box-shadow, css.text-shadow, css.filter.drop-shadow, ios.layer, ios.text, android.view.elevation).",
          "allOf": [
            {
              "$ref": "#/$defs/context-identifier"
            }
          ]
        },
        "offsetX": {
          "$ref": "#/$defs/lengthDimensionReference",
          "$comment": "Horizontal offset MUST conform to CSS <length> or platform-native units such as points (pt) and density-independent pixels (dp)."
        },
        "offsetY": {
          "$ref": "#/$defs/lengthDimensionReference",
          "$comment": "Vertical offset MUST conform to CSS <length> or platform-native units such as points (pt) and density-independent pixels (dp)."
        },
        "blur": {
          "title": "Shadow blur radius",
          "description": "Length measurement describing blur spread per Token types §shadow tokens.",
          "$comment": "Blur radius MUST match the <length> position in the CSS <shadow> production or equivalent CALayer.shadowRadius / Paint#setShadowLayer radius semantics.",
          "allOf": [
            {
              "$ref": "#/$defs/lengthDimensionReference"
            },
            {
              "if": {
                "type": "object",
                "required": ["dimensionType"],
                "properties": {
                  "dimensionType": {}
                }
              },
              "then": {
                "properties": {
                  "value": {
                    "type": "number",
                    "minimum": 0,
                    "title": "Non-negative blur value",
                    "description": "Shadow blur radii MUST be zero or positive per CSS <shadow> grammar.",
                    "$comment": "CSS <shadow> blur radii are non-negative lengths (css-backgrounds-3)."
                  }
                },
                "type": "object"
              }
            }
          ]
        },
        "spread": {
          "$ref": "#/$defs/lengthDimensionReference",
          "$comment": "Optional spread MUST follow the final <length> of CSS <shadow> and is realised via CALayer.shadowPath or Android outline inflation."
        },
        "color": {
          "$ref": "#/$defs/colorReference",
          "$comment": "Shadow colour MUST conform to CSS <color> values and map to CGColor / Android colour integers."
        }
      },
      "additionalProperties": false
    },
    "gradient-line-angle": {
      "title": "Gradient line orientation",
      "description": "CSS linear-gradient line syntax accepting an <angle> or to <side-or-corner> keyword per Token types §gradient tokens.",
      "$comment": "Token types §gradient tokens: string angles MUST be a CSS <angle> with units or the 'to <side-or-corner>' grammar (css-images-4).",
      "type": "string",
      "pattern": "^(?:[-+]?(?:\\d+(?:\\.\\d+)?|\\.\\d+)(?:[Ee][+-]?\\d+)?(?:[Dd][Ee][Gg]|[Gg][Rr][Aa][Dd]|[Rr][Aa][Dd]|[Tt][Uu][Rr][Nn])|[-+]?(?:0+(?:\\.0+)?|\\.0+)|[Tt][Oo]\\s+(?:(?:[Ll][Ee][Ff][Tt]|[Rr][Ii][Gg][Hh][Tt])(?:\\s+(?:[Tt][Oo][Pp]|[Bb][Oo][Tt][Tt][Oo][Mm]))?|(?:[Tt][Oo][Pp]|[Bb][Oo][Tt][Tt][Oo][Mm])(?:\\s+(?:[Ll][Ee][Ff][Tt]|[Rr][Ii][Gg][Hh][Tt]))?))$",
      "examples": ["45deg", "to top right", "0", "-0.25turn"]
    },
    "gradient-position": {
      "title": "Gradient position",
      "description": "CSS <position> tokens composed of keywords, <length-percentage>, or calc-style functions per Token types §gradient tokens.",
      "$comment": "Token types §gradient tokens: centre strings MUST follow the CSS <position> grammar used by radial-gradient() and conic-gradient() (css-images-4).",
      "type": "string",
      "pattern": "^(?:(?:(?:[Cc][Aa][Ll][Cc]|[Mm][Ii][Nn]|[Mm][Aa][Xx]|[Cc][Ll][Aa][Mm][Pp]|[Vv][Aa][Rr]|[Ee][Nn][Vv])\\((?:[^()]|\\((?:[^()]|\\((?:[^()]|\\([^()]*\\))*\\))*\\))*\\)|[-+]?(?:\\d+(?:\\.\\d+)?|\\.\\d+)(?:[Ee][+-]?\\d+)?(?:%|[A-Za-z][A-Za-z0-9-]*)|[-+]?(?:0+(?:\\.0+)?|\\.0+)|(?:[Cc][Ee][Nn][Tt][Ee][Rr]|[Ll][Ee][Ff][Tt]|[Rr][Ii][Gg][Hh][Tt]|[Tt][Oo][Pp]|[Bb][Oo][Tt][Tt][Oo][Mm])))(?:\\s+(?:(?:(?:[Cc][Aa][Ll][Cc]|[Mm][Ii][Nn]|[Mm][Aa][Xx]|[Cc][Ll][Aa][Mm][Pp]|[Vv][Aa][Rr]|[Ee][Nn][Vv])\\((?:[^()]|\\((?:[^()]|\\((?:[^()]|\\([^()]*\\))*\\))*\\))*\\)|[-+]?(?:\\d+(?:\\.\\d+)?|\\.\\d+)(?:[Ee][+-]?\\d+)?(?:%|[A-Za-z][A-Za-z0-9-]*)|[-+]?(?:0+(?:\\.0+)?|\\.0+)|(?:[Cc][Ee][Nn][Tt][Ee][Rr]|[Ll][Ee][Ff][Tt]|[Rr][Ii][Gg][Hh][Tt]|[Tt][Oo][Pp]|[Bb][Oo][Tt][Tt][Oo][Mm])))){0,3}$",
      "examples": [
        "center 25%",
        "left top",
        "calc(100% - 0.25rem) center",
        "calc(min(10%, max(5%, var(--x))) + 2em) 50%"
      ]
    },
    "gradient-ending-shape": {
      "title": "Radial gradient ending shape",
      "description": "CSS radial-gradient() ending shape keyword per Token types §gradient tokens.",
      "$comment": "Token types §gradient tokens: shape MUST be the <rg-ending-shape> keyword circle or ellipse (css-images-3).",
      "type": "string",
      "pattern": "^(?:[Cc][Ii][Rr][Cc][Ll][Ee]|[Ee][Ll][Ll][Ii][Pp][Ss][Ee])$",
      "examples": ["circle", "ellipse"]
    },
    "color-stop-length-string": {
      "title": "Color stop length string",
      "description": "CSS <color-stop-length> token composed of one or two <length-percentage> entries per Token types §gradient tokens.",
      "$comment": "Token types §gradient tokens and css-images-4: stop positions expressed as strings MUST be a single <length-percentage> or a pair separated by ASCII whitespace.",
      "type": "string",
      "pattern": "^(?:(?:[Cc][Aa][Ll][Cc]|[Mm][Ii][Nn]|[Mm][Aa][Xx]|[Cc][Ll][Aa][Mm][Pp]|[Vv][Aa][Rr]|[Ee][Nn][Vv])\\((?:[^()]|\\((?:[^()]|\\((?:[^()]|\\([^()]*\\))*\\))*\\))*\\)|[-+]?(?:\\d+(?:\\.\\d+)?|\\.\\d+)(?:[eE][+-]?\\d+)?(?:%|[A-Za-z][A-Za-z0-9-]*)|[-+]?(?:0+(?:\\.0+)?|\\.0+))(?:\\s+(?:(?:[Cc][Aa][Ll][Cc]|[Mm][Ii][Nn]|[Mm][Aa][Xx]|[Cc][Ll][Aa][Mm][Pp]|[Vv][Aa][Rr]|[Ee][Nn][Vv])\\((?:[^()]|\\((?:[^()]|\\((?:[^()]|\\([^()]*\\))*\\))*\\))*\\)|[-+]?(?:\\d+(?:\\.\\d+)?|\\.\\d+)(?:[eE][+-]?\\d+)?(?:%|[A-Za-z][A-Za-z0-9-]*)|[-+]?(?:0+(?:\\.0+)?|\\.0+)))?$",
      "examples": ["0%", "calc(50% - 10px)", "var(--stop, 25%)"]
    },
    "color-hint-length-string": {
      "title": "Color hint length string",
      "description": "CSS <color-hint> token serialized as a single <length-percentage> entry per Token types §gradient tokens.",
      "$comment": "Token types §gradient tokens and css-images-4: hint strings MUST be a solitary <length-percentage> expression without an optional second stop.",
      "type": "string",
      "pattern": "^(?:(?:[Cc][Aa][Ll][Cc]|[Mm][Ii][Nn]|[Mm][Aa][Xx]|[Cc][Ll][Aa][Mm][Pp]|[Vv][Aa][Rr]|[Ee][Nn][Vv])\\((?:[^()]|\\((?:[^()]|\\((?:[^()]|\\([^()]*\\))*\\))*\\))*\\)|[-+]?(?:\\d+(?:\\.\\d+)?|\\.\\d+)(?:[eE][+-]?\\d+)?(?:%|[A-Za-z][A-Za-z0-9-]*)|[-+]?(?:0+(?:\\.0+)?|\\.0+))$",
      "examples": ["25%", "calc(10% + 2rem)", "var(--hint)"]
    },
    "gradientValueEntry": {
      "title": "Gradient value entry",
      "description": "Literal gradient payload, alias, or computed expression per Token types §gradient tokens.",
      "$comment": "Token types §gradient tokens and §value: gradient tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/gradient"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "gradientValueFallback": {
      "title": "Gradient fallback list",
      "description": "Ordered fallback list of gradient values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/gradientValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "gradientTokenValue": {
      "title": "Gradient token value",
      "description": "Gradient literal, alias, or fallback list per Token types §gradient tokens.",
      "$comment": "Token types §gradient tokens: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/gradientValueEntry"
        },
        {
          "$ref": "#/$defs/gradientValueFallback"
        }
      ]
    },
    "gradient": {
      "type": "object",
      "required": ["gradientType", "stops"],
      "properties": {
        "gradientType": {
          "title": "Gradient function",
          "description": "Gradient function name such as linear, radial, or conic per Token types §gradient tokens.",
          "$comment": "Token types §gradient tokens: gradientType MUST be linear, radial, or conic matching CSS Images Module Level 4 gradient functions and mapping to CAGradientLayer.type or Android gradient shader constructors.",
          "type": "string",
          "enum": ["linear", "radial", "conic"]
        },
        "stops": {
          "type": "array",
          "minItems": 2,
          "items": {
            "type": "object",
            "required": ["position", "color"],
            "properties": {
              "position": {
                "anyOf": [
                  {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 1,
                    "$comment": "Normalised offsets align with CAGradientLayer.locations and Android shader stop arrays."
                  },
                  {
                    "$ref": "#/$defs/color-stop-length-string"
                  }
                ]
              },
              "hint": {
                "anyOf": [
                  {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 1,
                    "$comment": "Normalised hints map to native midpoint interpolation controls."
                  },
                  {
                    "$ref": "#/$defs/color-hint-length-string",
                    "$comment": "MUST conform to the <color-hint> production described in CSS Images Module Level 4."
                  }
                ]
              },
              "color": {
                "$ref": "#/$defs/colorReference"
              }
            },
            "additionalProperties": false
          },
          "$comment": "Represents the CSS <color-stop-list> grammar and corresponding native stop arrays."
        },
        "angle": {
          "title": "Gradient angle",
          "description": "Linear gradient line orientation expressed as a CSS <angle> string or numeric degrees per Token types §gradient tokens.",
          "anyOf": [
            {
              "$ref": "#/$defs/gradient-line-angle"
            },
            {
              "type": "number",
              "$comment": "Represents native rotation values interpreted in degrees when numeric."
            }
          ]
        },
        "center": {
          "anyOf": [
            {
              "type": "object",
              "required": ["x", "y"],
              "properties": {
                "x": {
                  "type": "number",
                  "minimum": 0,
                  "maximum": 1
                },
                "y": {
                  "type": "number",
                  "minimum": 0,
                  "maximum": 1
                }
              },
              "additionalProperties": false,
              "$comment": "Unit-square coordinates map to CAGradientLayer start/end points and Android radial or conic gradient centres."
            },
            {
              "$ref": "#/$defs/gradient-position"
            }
          ]
        },
        "shape": {
          "title": "Gradient ending shape",
          "description": "Radial gradient ending shape keyword such as circle or ellipse per Token types §gradient tokens.",
          "allOf": [
            {
              "$ref": "#/$defs/gradient-ending-shape"
            }
          ]
        }
      },
      "additionalProperties": false,
      "allOf": [
        {
          "if": {
            "properties": {
              "angle": {}
            },
            "required": ["angle"],
            "type": "object"
          },
          "then": {
            "properties": {
              "gradientType": {
                "not": {
                  "const": "radial"
                },
                "$comment": "Radial gradients do not accept an initial angle per CSS Images Module Level 4."
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "center": {}
            },
            "required": ["center"],
            "type": "object"
          },
          "then": {
            "properties": {
              "gradientType": {
                "enum": ["radial", "conic"],
                "$comment": "Only radial-gradient() and conic-gradient() accept a centre position in CSS Images Module Level 4."
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "shape": {}
            },
            "required": ["shape"],
            "type": "object"
          },
          "then": {
            "properties": {
              "gradientType": {
                "const": "radial",
                "$comment": "<rg-ending-shape> keywords are valid exclusively on radial-gradient() per CSS Images Module Level 3."
              }
            },
            "type": "object"
          }
        }
      ]
    },
    "filterValueEntry": {
      "title": "Filter value entry",
      "description": "Literal filter payload, alias, or computed expression per Token types §filter tokens.",
      "$comment": "Token types §filter tokens and §value: filter tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/filter"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "filterValueFallback": {
      "title": "Filter fallback list",
      "description": "Ordered fallback list of filter values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/filterValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "filterTokenValue": {
      "title": "Filter token value",
      "description": "Filter literal, alias, or fallback list per Token types §filter tokens.",
      "$comment": "Token types §filter tokens: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/filterValueEntry"
        },
        {
          "$ref": "#/$defs/filterValueFallback"
        }
      ]
    },
    "filter": {
      "type": "object",
      "required": ["filterType", "operations"],
      "properties": {
        "filterType": {
          "title": "Filter context identifier",
          "description": "Platform-qualified filter context such as css.filter, ios.cifilter, or android.render-effect.",
          "$comment": "MUST identify the rendering context defined by CSS filter(), Core Image CIFilter pipelines, or Android RenderEffect chains (for example css.filter, ios.cifilter, android.render-effect).",
          "allOf": [
            {
              "$ref": "#/$defs/platform-identifier"
            }
          ]
        },
        "operations": {
          "type": "array",
          "minItems": 1,
          "items": {
            "type": "object",
            "required": ["fn"],
            "properties": {
              "fn": {
                "title": "Filter function identifier",
                "description": "Function name from CSS Filter Effects or a vendor-qualified analogue such as blur, brightness, or ios.cifilter.gaussian-blur.",
                "$comment": "MUST reference a filter function from CSS Filter Effects Module Level 1 or its native analogue (for example blur, brightness, drop-shadow).",
                "allOf": [
                  {
                    "$ref": "#/$defs/namespaced-function-identifier"
                  }
                ]
              },
              "parameters": {
                "type": "array",
                "items": {
                  "$ref": "#/$defs/function-parameter"
                },
                "default": [],
                "$comment": "Arguments MUST satisfy the grammar of the referenced filter function (e.g. CSS blur() <length>, brightness() numbers, drop-shadow() <shadow>) and map to CIFilter / RenderEffect parameters."
              }
            },
            "additionalProperties": false
          },
          "$comment": "Represents the ordered <filter-function-list> grammar from CSS Filter Effects."
        }
      },
      "additionalProperties": false
    },
    "opacityValueEntry": {
      "title": "Opacity value entry",
      "description": "Numeric opacity, alias, or computed expression per Token types §opacity.",
      "$comment": "Token types §opacity and §value: opacity tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/opacity"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "opacityValueFallback": {
      "title": "Opacity fallback list",
      "description": "Ordered fallback list of opacity values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/opacityValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "opacityTokenValue": {
      "title": "Opacity token value",
      "description": "Opacity literal, alias, or fallback list per Token types §opacity.",
      "$comment": "Token types §opacity: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/opacityValueEntry"
        },
        {
          "$ref": "#/$defs/opacityValueFallback"
        }
      ]
    },
    "opacity": {
      "type": "object",
      "required": ["opacityType", "value"],
      "properties": {
        "opacityType": {
          "title": "Opacity context identifier",
          "description": "Platform-qualified opacity context such as css.opacity, ios.uiview.alpha, or android.view.alpha.",
          "$comment": "MUST name a platform opacity property such as css.opacity (css-color-4#propdef-opacity), ios.uiview.alpha (IOS-UIVIEW-ALPHA), ios.layer.opacity (IOS-CALAYER), or android.view.alpha (ANDROID-VIEW-ALPHA).",
          "allOf": [
            {
              "$ref": "#/$defs/platform-identifier"
            }
          ]
        },
        "value": {
          "oneOf": [
            {
              "type": "number",
              "minimum": 0,
              "maximum": 1,
              "$comment": "Numeric form MUST satisfy the <alpha-value> range defined by CSS Color Module Level 4 (css-color-4#typedef-alpha-value), UIView.alpha (IOS-UIVIEW-ALPHA), and View#setAlpha (ANDROID-VIEW-ALPHA)."
            },
            {
              "type": "string",
              "pattern": "^(?:[-+]?(?:\\d+(?:\\.\\d+)?|\\.\\d+)%?|[A-Za-z-]+\\(.+\\))$",
              "$comment": "String form MUST conform to the CSS <alpha-value> production (css-color-4#typedef-alpha-value)."
            }
          ]
        }
      },
      "additionalProperties": false
    },
    "durationTimeUnit": {
      "type": "string",
      "enum": ["s", "ms"],
      "$comment": "MUST use CSS <time> units serialised as s or ms for transition and animation timing APIs (css-values-4#time-value, css-transitions-2, css-animations-2, IOS-CAANIMATION, ANDROID-VALUE-ANIMATOR)."
    },
    "durationFrameCountUnit": {
      "type": "string",
      "enum": ["frames"],
      "$comment": "MUST use the frame count keyword defined by CADisplayLink and Choreographer timing APIs (IOS-CADISPLAYLINK, ANDROID-CHOREOGRAPHER)."
    },
    "durationFractionUnit": {
      "type": "string",
      "enum": ["%"],
      "$comment": "MUST use CSS <percentage> serialisation for fraction/progress timelines (css-values-4#percentages, IOS-UIVIEWPROPERTYANIMATOR, ANDROID-OBJECTANIMATOR)."
    },
    "durationValueEntry": {
      "title": "Duration value entry",
      "description": "Duration payload, alias, or computed expression per Token types §duration.",
      "$comment": "Token types §duration and §value: duration tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/duration"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "durationValueFallback": {
      "title": "Duration fallback list",
      "description": "Ordered fallback list of duration values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/durationValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "durationTokenValue": {
      "title": "Duration token value",
      "description": "Duration literal, alias, or fallback list per Token types §duration.",
      "$comment": "Token types §duration: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/durationValueEntry"
        },
        {
          "$ref": "#/$defs/durationValueFallback"
        }
      ]
    },
    "duration": {
      "type": "object",
      "required": ["durationType", "value", "unit"],
      "properties": {
        "durationType": {
          "title": "Duration context identifier",
          "description": "Platform-qualified duration context such as css.transition-duration, ios.caanimation.duration, or android.value-animator.duration.",
          "$comment": "MUST identify a duration context defined by CSS Transitions/Animations, Core Animation, UIViewPropertyAnimator, or Android animator APIs (for example css.transition-duration, ios.caanimation.duration, android.value-animator.duration, ios.cadisplaylink.frame-count).",
          "allOf": [
            {
              "$ref": "#/$defs/platform-identifier"
            }
          ]
        },
        "value": {
          "type": "number"
        },
        "unit": {
          "type": "string",
          "$comment": "MUST serialise the unit token defined by the referenced duration grammar (css-values-4#time-value, css-values-4#percentages, IOS-CADISPLAYLINK, ANDROID-CHOREOGRAPHER)."
        }
      },
      "additionalProperties": false,
      "allOf": [
        {
          "if": {
            "properties": {
              "durationType": {
                "pattern": "^(?:css\\.(?:transition|animation)-duration|ios\\.caanimation\\.duration|android\\.value-animator\\.duration)$",
                "type": "string"
              }
            },
            "required": ["durationType"],
            "type": "object"
          },
          "then": {
            "$comment": "Duration contexts MUST encode non-negative CSS <time> values as defined by CSS Values & Units, Core Animation, and Android animator APIs (css-values-4#time-value, css-transitions-2, css-animations-2, IOS-CAANIMATION, ANDROID-VALUE-ANIMATOR).",
            "properties": {
              "value": {
                "type": "number",
                "minimum": 0,
                "$comment": "Non-negative durations matching the CSS <time> production."
              },
              "unit": {
                "$ref": "#/$defs/durationTimeUnit"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "durationType": {
                "pattern": "^(?:ios\\.cadisplaylink\\.frame-count|android\\.choreographer\\.frame-count)$",
                "type": "string"
              }
            },
            "required": ["durationType"],
            "type": "object"
          },
          "then": {
            "$comment": "Frame-count durations carry platform refresh steps as described by CADisplayLink and Choreographer (IOS-CADISPLAYLINK, ANDROID-CHOREOGRAPHER).",
            "properties": {
              "value": {
                "type": "integer",
                "minimum": 0,
                "$comment": "Non-negative integer frame counts from the referenced timing API."
              },
              "unit": {
                "$ref": "#/$defs/durationFrameCountUnit"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "durationType": {
                "pattern": "^(?:css\\.timeline\\.progress|ios\\.uianimation\\.fraction|android\\.animator-set\\.fraction)$",
                "type": "string"
              }
            },
            "required": ["durationType"],
            "type": "object"
          },
          "then": {
            "$comment": "Fraction/progress contexts serialise CSS <percentage> values used by timelines and native animation fractions (css-values-4#percentages, IOS-UIVIEWPROPERTYANIMATOR, ANDROID-OBJECTANIMATOR).",
            "properties": {
              "value": {
                "type": "number",
                "$comment": "Numeric percentage matching the CSS <percentage> grammar."
              },
              "unit": {
                "$ref": "#/$defs/durationFractionUnit"
              }
            },
            "type": "object"
          }
        }
      ]
    },
    "easingValueEntry": {
      "title": "Easing value entry",
      "description": "Literal easing payload, alias, or computed expression per Token types §easing.",
      "$comment": "Token types §easing and §value: easing tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/easing"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "easingValueFallback": {
      "title": "Easing fallback list",
      "description": "Ordered fallback list of easing values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/easingValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "easingTokenValue": {
      "title": "Easing token value",
      "description": "Easing literal, alias, or fallback list per Token types §easing.",
      "$comment": "Token types §easing: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/easingValueEntry"
        },
        {
          "$ref": "#/$defs/easingValueFallback"
        }
      ]
    },
    "easing": {
      "title": "Easing payload",
      "description": "Reusable timing curve identified by easingFunction per Token types §easing.",
      "$comment": "Token types §easing: easingFunction names a CSS <single-easing-function> or native analogue and parameters follow that grammar.",
      "type": "object",
      "required": ["easingFunction"],
      "properties": {
        "easingFunction": {
          "title": "Easing function identifier",
          "description": "CSS or vendor-qualified easing identifier such as cubic-bezier, steps, ios.spring, or android.spring-force.",
          "$comment": "MUST name a CSS <single-easing-function> production or a documented native analogue.",
          "allOf": [
            {
              "$ref": "#/$defs/namespaced-function-identifier"
            }
          ]
        },
        "parameters": {
          "title": "Easing parameters",
          "description": "Ordered arguments consumed by the referenced easingFunction. Omit when the grammar takes no parameters.",
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "string"
              }
            ]
          },
          "default": [],
          "$comment": "When present, MUST satisfy the argument grammar defined for the referenced easing function in CSS Easing Functions or platform timing APIs."
        }
      },
      "additionalProperties": false,
      "allOf": [
        {
          "if": {
            "properties": {
              "easingFunction": {
                "const": "cubic-bezier"
              }
            },
            "required": ["easingFunction"],
            "type": "object"
          },
          "then": {
            "required": ["parameters"],
            "properties": {
              "parameters": {
                "title": "cubic-bezier control points",
                "description": "Four-number array [p1x, p1y, p2x, p2y] per CSS Easing Functions §cubic-bezier(). p1x and p2x MUST be within [0, 1].",
                "$comment": "Token types §easing: cubic-bezier() requires four numeric arguments with domain constraints on the x control points (css-easing-1).",
                "type": "array",
                "minItems": 4,
                "maxItems": 4,
                "items": {
                  "type": "number"
                },
                "prefixItems": [
                  {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 1,
                    "title": "p1x"
                  },
                  {
                    "type": "number",
                    "title": "p1y"
                  },
                  {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 1,
                    "title": "p2x"
                  },
                  {
                    "type": "number",
                    "title": "p2y"
                  }
                ]
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "easingFunction": {
                "const": "steps"
              }
            },
            "required": ["easingFunction"],
            "type": "object"
          },
          "then": {
            "required": ["parameters"],
            "properties": {
              "parameters": {
                "title": "steps() arguments",
                "description": "Positive integer step count with optional <step-position> keyword per CSS Easing Functions §steps().",
                "$comment": "Token types §easing: steps() requires a positive integer and optional step-position keyword (css-easing-1).",
                "type": "array",
                "oneOf": [
                  {
                    "minItems": 1,
                    "maxItems": 1,
                    "prefixItems": [
                      {
                        "type": "integer",
                        "minimum": 1,
                        "title": "Step count"
                      }
                    ],
                    "items": false
                  },
                  {
                    "minItems": 2,
                    "maxItems": 2,
                    "prefixItems": [
                      {
                        "type": "integer",
                        "minimum": 1,
                        "title": "Step count"
                      },
                      {
                        "type": "string",
                        "enum": [
                          "start",
                          "end",
                          "jump-start",
                          "jump-end",
                          "jump-none",
                          "jump-both"
                        ],
                        "title": "Step position"
                      }
                    ],
                    "items": false
                  }
                ]
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "easingFunction": {
                "pattern": "^(?:spring|(?:ios|android)\\.spring(?:[.-][a-z0-9]+)*)$",
                "type": "string"
              }
            },
            "required": ["easingFunction"],
            "type": "object"
          },
          "then": {
            "required": ["parameters"],
            "properties": {
              "parameters": {
                "title": "Spring timing parameters",
                "description": "Four-number array providing positive magnitudes followed by an initial velocity per UISpringTimingParameters and SpringForce.",
                "$comment": "Token types §easing: spring-based easings supply positive magnitude arguments and any real initial velocity (UISpringTimingParameters, SpringForce).",
                "type": "array",
                "minItems": 4,
                "maxItems": 4,
                "items": {
                  "type": "number"
                },
                "prefixItems": [
                  {
                    "type": "number",
                    "exclusiveMinimum": 0,
                    "title": "Magnitude 1"
                  },
                  {
                    "type": "number",
                    "exclusiveMinimum": 0,
                    "title": "Magnitude 2"
                  },
                  {
                    "type": "number",
                    "exclusiveMinimum": 0,
                    "title": "Magnitude 3"
                  },
                  {
                    "type": "number",
                    "title": "Initial velocity"
                  }
                ]
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "easingFunction": {
                "enum": [
                  "linear",
                  "ease",
                  "ease-in",
                  "ease-out",
                  "ease-in-out",
                  "step-start",
                  "step-end"
                ]
              }
            },
            "required": ["easingFunction"],
            "type": "object"
          },
          "then": {
            "$comment": "Token types §easing: keyword easings MUST NOT declare parameters.",
            "properties": {
              "parameters": false
            },
            "type": "object"
          }
        }
      ]
    },
    "zIndexValueEntry": {
      "title": "Z-index value entry",
      "description": "Stacking context magnitude, alias, or computed expression per Token types §z-index.",
      "$comment": "Token types §z-index and §value: z-index tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/z-index"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "zIndexValueFallback": {
      "title": "Z-index fallback list",
      "description": "Ordered fallback list of z-index values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/zIndexValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "zIndexTokenValue": {
      "title": "Z-index token value",
      "description": "Z-index literal, alias, or fallback list per Token types §z-index.",
      "$comment": "Token types §z-index: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/zIndexValueEntry"
        },
        {
          "$ref": "#/$defs/zIndexValueFallback"
        }
      ]
    },
    "z-index": {
      "type": "object",
      "required": ["zIndexType", "value"],
      "properties": {
        "zIndexType": {
          "title": "Z-index context identifier",
          "description": "Platform-qualified stacking context such as css.z-index, ios.calayer.z-position, or android.view.translationz.",
          "$comment": "MUST name a stacking context primitive such as css.z-index, ios.calayer.z-position, android.view.z, or android.view.translationz as defined by CSS Positioned Layout Module Level 3 (css-position-3#propdef-z-index), CALayer.zPosition (IOS-CALAYER), and Android View Z APIs (ANDROID-VIEW-SETZ, ANDROID-VIEW-TRANSLATIONZ).",
          "allOf": [
            {
              "$ref": "#/$defs/platform-identifier"
            }
          ]
        },
        "value": {
          "type": "number",
          "$comment": "MUST conform to CSS <integer> (css-position-3#propdef-z-index, css-values-4#integer-value), CALayer.zPosition (IOS-CALAYER), or Android View Z APIs (ANDROID-VIEW-SETZ, ANDROID-VIEW-TRANSLATIONZ) depending on the referenced platform."
        }
      },
      "additionalProperties": false,
      "allOf": [
        {
          "if": {
            "properties": {
              "zIndexType": {
                "pattern": "^css\\.",
                "type": "string"
              }
            },
            "required": ["zIndexType"],
            "type": "object"
          },
          "then": {
            "properties": {
              "value": {
                "type": "integer",
                "$comment": "CSS z-index values MUST be integers per css-position-3#propdef-z-index."
              }
            },
            "type": "object"
          }
        }
      ]
    },
    "motionValueEntry": {
      "title": "Motion value entry",
      "description": "Literal motion payload, alias, or computed expression per Token types §motion tokens.",
      "$comment": "Token types §motion tokens and §value: motion tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/motion"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "motionValueFallback": {
      "title": "Motion fallback list",
      "description": "Ordered fallback list of motion values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/motionValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "motionTokenValue": {
      "title": "Motion token value",
      "description": "Motion literal, alias, or fallback list per Token types §motion tokens.",
      "$comment": "Token types §motion tokens: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/motionValueEntry"
        },
        {
          "$ref": "#/$defs/motionValueFallback"
        }
      ]
    },
    "motion": {
      "type": "object",
      "required": ["motionType", "parameters"],
      "properties": {
        "motionType": {
          "title": "Motion transform identifier",
          "description": "Platform-qualified transform such as css.translate, ios.catransform3d.rotate, or android.viewpropertyanimator.scalex.",
          "$comment": "MUST name a platform transform such as css.translate, ios.catransform3d.rotate, or android.viewpropertyanimator.scalex as defined by CSS Transforms Module Level 2 (css-transforms-2#transform-functions), Core Animation (IOS-CGAFFINETRANSFORM, IOS-CATRANSFORM3D, IOS-CAKEYFRAMEANIMATION), and Android animation APIs (ANDROID-VIEWPROPERTYANIMATOR, ANDROID-OBJECTANIMATOR).",
          "allOf": [
            {
              "$ref": "#/$defs/platform-identifier"
            }
          ]
        },
        "parameters": {
          "type": "object",
          "$comment": "Members MUST align with the grammar of the referenced transform function."
        }
      },
      "additionalProperties": false,
      "allOf": [
        {
          "if": {
            "properties": {
              "motionType": {
                "pattern": "\\.(?:translate(?:[-a-z0-9]*)?|translation(?:[-a-z0-9]*)?)$",
                "type": "string"
              }
            },
            "required": ["motionType"],
            "type": "object"
          },
          "then": {
            "properties": {
              "parameters": {
                "$ref": "#/$defs/motion-translation"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "motionType": {
                "pattern": "\\.(?:rotate(?:[-a-z0-9]*)?|rotation(?:[-a-z0-9]*)?)$",
                "type": "string"
              }
            },
            "required": ["motionType"],
            "type": "object"
          },
          "then": {
            "properties": {
              "parameters": {
                "$ref": "#/$defs/motion-rotation"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "motionType": {
                "pattern": "\\.(?:scale(?:[-a-z0-9]*)?)$",
                "type": "string"
              }
            },
            "required": ["motionType"],
            "type": "object"
          },
          "then": {
            "properties": {
              "parameters": {
                "$ref": "#/$defs/motion-scale"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "motionType": {
                "pattern": "\\.(?:path|offset-path|motion-path)$",
                "type": "string"
              }
            },
            "required": ["motionType"],
            "type": "object"
          },
          "then": {
            "properties": {
              "parameters": {
                "$ref": "#/$defs/motion-path"
              }
            },
            "type": "object"
          }
        }
      ]
    },
    "motion-length": {
      "oneOf": [
        {
          "$ref": "#/$defs/lengthDimensionReference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ],
      "$comment": "MUST evaluate to a CSS <length-percentage> (css-values-4#typedef-length-percentage) or equivalent platform distance for translation and path coordinates."
    },
    "motion-angle": {
      "oneOf": [
        {
          "$ref": "#/$defs/angleDimensionReference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ],
      "$comment": "MUST evaluate to a CSS <angle> (css-values-4#angles) compatible with Core Animation and Android rotation APIs."
    },
    "motion-translation": {
      "type": "object",
      "properties": {
        "x": {
          "$ref": "#/$defs/motion-length"
        },
        "y": {
          "$ref": "#/$defs/motion-length"
        },
        "z": {
          "$ref": "#/$defs/motion-length"
        }
      },
      "additionalProperties": false,
      "anyOf": [
        {
          "required": ["x"],
          "type": "object",
          "properties": {
            "x": {}
          }
        },
        {
          "required": ["y"],
          "type": "object",
          "properties": {
            "y": {}
          }
        },
        {
          "required": ["z"],
          "type": "object",
          "properties": {
            "z": {}
          }
        }
      ]
    },
    "motion-origin": {
      "type": "object",
      "properties": {
        "x": {
          "type": "number",
          "minimum": 0,
          "maximum": 1
        },
        "y": {
          "type": "number",
          "minimum": 0,
          "maximum": 1
        },
        "z": {
          "type": "number",
          "minimum": 0,
          "maximum": 1
        }
      },
      "additionalProperties": false,
      "anyOf": [
        {
          "required": ["x"],
          "type": "object",
          "properties": {
            "x": {}
          }
        },
        {
          "required": ["y"],
          "type": "object",
          "properties": {
            "y": {}
          }
        },
        {
          "required": ["z"],
          "type": "object",
          "properties": {
            "z": {}
          }
        }
      ],
      "$comment": "Normalised fractions (0-1) representing transform-origin percentages, CALayer.anchorPoint, and View#setPivotX/Y."
    },
    "motion-rotation": {
      "type": "object",
      "required": ["angle"],
      "properties": {
        "angle": {
          "$ref": "#/$defs/motion-angle"
        },
        "axis": {
          "type": "object",
          "required": ["x", "y", "z"],
          "properties": {
            "x": {
              "type": "number"
            },
            "y": {
              "type": "number"
            },
            "z": {
              "type": "number"
            }
          },
          "additionalProperties": false,
          "allOf": [
            {
              "anyOf": [
                {
                  "properties": {
                    "x": {
                      "not": {
                        "const": 0
                      }
                    }
                  }
                },
                {
                  "properties": {
                    "y": {
                      "not": {
                        "const": 0
                      }
                    }
                  }
                },
                {
                  "properties": {
                    "z": {
                      "not": {
                        "const": 0
                      }
                    }
                  }
                }
              ]
            }
          ],
          "$comment": "Components describe the rotation vector consumed by rotate3d() (css-transforms-2#funcdef-rotate3d) and CATransform3DRotate."
        },
        "origin": {
          "$ref": "#/$defs/motion-origin"
        }
      },
      "additionalProperties": false
    },
    "motion-scale-factor": {
      "type": "number",
      "minimum": 0,
      "$comment": "Non-negative multiplier matching CSS scale() arguments and native scale factors; negative multipliers remain invalid."
    },
    "motion-scale": {
      "type": "object",
      "properties": {
        "x": {
          "$ref": "#/$defs/motion-scale-factor"
        },
        "y": {
          "$ref": "#/$defs/motion-scale-factor"
        },
        "z": {
          "$ref": "#/$defs/motion-scale-factor"
        },
        "uniform": {
          "$ref": "#/$defs/motion-scale-factor"
        }
      },
      "additionalProperties": false,
      "anyOf": [
        {
          "required": ["uniform"],
          "type": "object",
          "properties": {
            "uniform": {}
          }
        },
        {
          "required": ["x"],
          "type": "object",
          "properties": {
            "x": {}
          }
        },
        {
          "required": ["y"],
          "type": "object",
          "properties": {
            "y": {}
          }
        },
        {
          "required": ["z"],
          "type": "object",
          "properties": {
            "z": {}
          }
        }
      ]
    },
    "motion-path": {
      "type": "object",
      "required": ["points"],
      "properties": {
        "points": {
          "type": "array",
          "minItems": 2,
          "items": {
            "$ref": "#/$defs/motion-path-point"
          }
        }
      },
      "additionalProperties": false,
      "$comment": "Path definitions align with CSS offset-path path() geometry, CAKeyframeAnimation.path, and android.graphics.Path."
    },
    "motion-path-point": {
      "type": "object",
      "required": ["time", "position"],
      "properties": {
        "time": {
          "type": "number",
          "minimum": 0,
          "maximum": 1,
          "$comment": "Normalised progress matching CAKeyframeAnimation.keyTimes and ObjectAnimator fractions."
        },
        "position": {
          "$ref": "#/$defs/motion-path-position"
        },
        "easing": {
          "$ref": "#/$defs/pointer"
        }
      },
      "additionalProperties": false
    },
    "motion-path-position": {
      "type": "object",
      "properties": {
        "x": {
          "$ref": "#/$defs/motion-length"
        },
        "y": {
          "$ref": "#/$defs/motion-length"
        },
        "z": {
          "$ref": "#/$defs/motion-length"
        }
      },
      "additionalProperties": false,
      "anyOf": [
        {
          "required": ["x"],
          "type": "object",
          "properties": {
            "x": {}
          }
        },
        {
          "required": ["y"],
          "type": "object",
          "properties": {
            "y": {}
          }
        },
        {
          "required": ["z"],
          "type": "object",
          "properties": {
            "z": {}
          }
        }
      ],
      "$comment": "Each axis resolves to <length-percentage> coordinates evaluated along the referenced path geometry."
    },
    "elevationValueEntry": {
      "title": "Elevation value entry",
      "description": "Literal elevation payload, alias, or computed expression per Token types §elevation tokens.",
      "$comment": "Token types §elevation tokens and §value: elevation tokens MAY embed direct values, $ref aliases, or functions.",
      "oneOf": [
        {
          "$ref": "#/$defs/elevation"
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "$ref": "#/$defs/function"
        }
      ]
    },
    "elevationValueFallback": {
      "title": "Elevation fallback list",
      "description": "Ordered fallback list of elevation values evaluated per Token types §value.",
      "$comment": "Token types §value: fallback sequences evaluate candidates until one resolves.",
      "allOf": [
        {
          "$ref": "#/$defs/nonEmptyArray"
        },
        {
          "items": {
            "$ref": "#/$defs/elevationValueEntry"
          },
          "type": "array"
        }
      ]
    },
    "elevationTokenValue": {
      "title": "Elevation token value",
      "description": "Elevation literal, alias, or fallback list per Token types §elevation tokens.",
      "$comment": "Token types §elevation tokens: tokens MAY specify inline values, references, or fallback arrays.",
      "oneOf": [
        {
          "$ref": "#/$defs/elevationValueEntry"
        },
        {
          "$ref": "#/$defs/elevationValueFallback"
        }
      ]
    },
    "elevation": {
      "type": "object",
      "required": ["elevationType", "offset", "blur", "color"],
      "properties": {
        "elevationType": {
          "title": "Elevation context identifier",
          "description": "Rendering surface identifier such as css.box-shadow.surface, ios.layer.surface, or android.paint.shadow-layer.surface.",
          "$comment": "MUST identify the rendering context defined by CSS <shadow> functions, UIKit CALayer/NSShadow properties, or Android elevation/shadow APIs (for example css.box-shadow.surface, ios.layer.surface, android.paint.shadow-layer.surface).",
          "allOf": [
            {
              "$ref": "#/$defs/context-identifier"
            }
          ]
        },
        "offset": {
          "$ref": "#/$defs/lengthDimensionReference",
          "$comment": "Vertical offset MUST conform to CSS <length> grammar and map to CALayer.shadowOffset.height, Paint#setShadowLayer dy, or View#setElevation displacement."
        },
        "blur": {
          "title": "Elevation blur radius",
          "description": "Length measurement describing the ambient blur per Token types §elevation tokens.",
          "$comment": "Blur radius MUST match the <length> position in CSS <shadow> and the CALayer.shadowRadius / Paint#setShadowLayer radius semantics.",
          "allOf": [
            {
              "$ref": "#/$defs/lengthDimensionReference"
            },
            {
              "if": {
                "type": "object",
                "required": ["dimensionType"],
                "properties": {
                  "dimensionType": {}
                }
              },
              "then": {
                "properties": {
                  "value": {
                    "type": "number",
                    "minimum": 0,
                    "title": "Non-negative blur value",
                    "description": "Elevation blur radii MUST be zero or positive per CSS <shadow> grammar.",
                    "$comment": "CSS <shadow> blur radii are non-negative lengths (css-backgrounds-3)."
                  }
                },
                "type": "object"
              }
            }
          ]
        },
        "color": {
          "$ref": "#/$defs/colorReference",
          "$comment": "Shadow colour MUST conform to CSS <color> values and map to CGColor / Android colour integers used for Paint#setShadowLayer or elevation overlays."
        }
      },
      "additionalProperties": false
    },
    "lifecycle-metadata": {
      "title": "Lifecycle telemetry requirements",
      "description": "Ensures $lastUsed timestamps and $usageCount counters follow Metadata §table requirements.",
      "$comment": "Metadata table: $lastUsed requires $usageCount > 0; $usageCount = 0 forbids $lastUsed.",
      "allOf": [
        {
          "if": {
            "required": ["$lastModified", "$lastUsed"],
            "type": "object",
            "properties": {
              "$lastModified": {},
              "$lastUsed": {}
            }
          },
          "then": {
            "$comment": "$lastUsed timestamps MUST NOT precede $lastModified (Metadata table).",
            "properties": {
              "$lastUsed": {
                "type": "string",
                "format": "date-time",
                "title": "$lastUsed not before $lastModified",
                "description": "$lastUsed MUST be on or after $lastModified when both fields are present.",
                "formatMinimum": {
                  "$data": "1/$lastModified"
                }
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "required": ["$lastUsed"],
            "type": "object",
            "properties": {
              "$lastUsed": {}
            }
          },
          "then": {
            "$comment": "$lastUsed requires a recorded usage count greater than zero.",
            "required": ["$usageCount"],
            "properties": {
              "$usageCount": {
                "minimum": 1,
                "description": "$usageCount MUST be a positive integer when $lastUsed is present.",
                "title": "$usageCount for used tokens",
                "type": "number"
              }
            },
            "type": "object"
          }
        },
        {
          "if": {
            "properties": {
              "$usageCount": {
                "const": 0
              }
            },
            "required": ["$usageCount"],
            "type": "object"
          },
          "then": {
            "$comment": "$usageCount = 0 indicates no recorded usage, so $lastUsed MUST be omitted.",
            "not": {
              "required": ["$lastUsed"],
              "type": "object",
              "properties": {
                "$lastUsed": {}
              }
            }
          }
        },
        {
          "if": {
            "properties": {
              "$usageCount": {
                "minimum": 1,
                "type": "number"
              }
            },
            "required": ["$usageCount"],
            "type": "object"
          },
          "then": {
            "$comment": "Recorded usage counts greater than zero require a companion $lastUsed timestamp.",
            "required": ["$lastUsed"],
            "type": "object",
            "properties": {
              "$lastUsed": {}
            }
          }
        }
      ]
    },
    "trimmedString": {
      "title": "Trimmed string",
      "description": "Non-empty string without leading or trailing whitespace per Metadata §metadata.",
      "$comment": "Metadata table: strings such as $author MUST be trimmed.",
      "type": "string",
      "minLength": 1,
      "pattern": "^(?!\\s)(?:.*\\S)?$"
    },
    "hashString": {
      "title": "Hash string",
      "description": "Stable identifier with no whitespace per Metadata §metadata.",
      "$comment": "Metadata table: $hash MUST NOT contain whitespace.",
      "type": "string",
      "minLength": 1,
      "pattern": "^\\S+$"
    },
    "tags": {
      "title": "Tag list",
      "description": "Array of unique trimmed classification strings per Metadata §metadata.",
      "$comment": "Metadata table: $tags MUST contain unique trimmed strings.",
      "type": "array",
      "items": {
        "$ref": "#/$defs/trimmedString"
      },
      "uniqueItems": true
    },
    "function": {
      "title": "Function expression",
      "description": "Computed value wrapper with a function name and optional parameters per Token types §value.",
      "$comment": "Token types §value: $value MAY be a function object with fn and optional parameters members.",
      "type": "object",
      "required": ["fn"],
      "properties": {
        "fn": {
          "title": "Function identifier",
          "description": "Function name such as calc, clamp, or platform-specific identifiers per Token types §value.",
          "allOf": [
            {
              "$ref": "#/$defs/namespaced-function-identifier"
            }
          ]
        },
        "parameters": {
          "title": "Function parameters",
          "description": "Ordered list of literals, references, nested functions, or arrays per Token types §value. When omitted, consumers treat the list as empty per Token types §value.",
          "type": "array",
          "items": {
            "$ref": "#/$defs/function-parameter"
          },
          "default": [],
          "$comment": "Token types §value: parameters MAY be omitted when the referenced grammar takes no arguments; omitted parameters default to an empty array."
        }
      },
      "additionalProperties": false
    },
    "function-parameter": {
      "title": "Function parameter",
      "description": "Literal, reference, nested function, array, or object argument accepted by function expressions per Token types §value.",
      "$comment": "Token types §value: parameters MAY include literals, $ref aliases, nested functions, or arrays.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "number"
        },
        {
          "type": "boolean"
        },
        {
          "type": "null"
        },
        {
          "$ref": "#/$defs/function"
        },
        {
          "type": "array",
          "items": {
            "$ref": "#/$defs/function-parameter"
          }
        },
        {
          "$ref": "#/$defs/reference"
        },
        {
          "type": "object",
          "not": {
            "required": ["$ref"],
            "type": "object",
            "properties": {
              "$ref": {}
            }
          },
          "propertyNames": {
            "type": "string",
            "pattern": "^(?!\\$)"
          },
          "additionalProperties": true
        }
      ]
    },
    "extensions": {
      "title": "Extensions map",
      "description": "Namespaced metadata keyed by reverse-DNS identifiers per Format and serialisation §$extensions.",
      "$comment": "Format and serialisation §$extensions: keys MUST use lower-case reverse-DNS identifiers.",
      "type": "object",
      "propertyNames": {
        "pattern": "^[a-z0-9](?:[a-z0-9-]*[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]*[a-z0-9])?)+$",
        "$comment": "Extension identifiers MUST be lower-case reverse-DNS strings.",
        "type": "string"
      },
      "additionalProperties": true
    }
  }
}
