Wall-clock Duration
A ClockTime is validated from 00:00:00 through 23:59:59 and converted to seconds since midnight. Time-only Calculation subtracts the two values and adds exactly 86,400 seconds only when Next-day End is active. Date-and-time Calculation adds a Civil Date day index before subtraction.
Civil Date and Day Counter
Civil Dates use the modern Gregorian 4/100/400 leap-year rule for the complete years 1 through 9999, including dates before 1582. 0001-01-01 is day index 0 and Monday. The default interval is [start, end); Included End Date adds exactly one date.
Exact and approximate output
Exact total seconds are the duration source of truth. Hours, minutes, and seconds are derived from that integer. Decimal hours and minutes use deterministic half-up rounding to two places and show ≈ only when the exact value is not representable at that precision.
Implementation boundary
Calculation functions do not read the DOM, locale, URL, local storage, current time, timezone, or network. Browser adapters read Now or Today only after an explicit action. Invalid inputs return structured errors rather than NaN, absolute values, or silent corrections.