The design language that makes your AI harness better at design.
JavaScript
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Cramped padding, edges a reader sees</title>
<!--
The flush form of cramped-padding reports text that runs against a
visible boundary with no inset. These cases, from observations-28 row 13,
are sides where no boundary shows: text a sideways scroll or an ellipsis
cuts, a band that runs on into a sibling of the same fill, a fill laid on
a positioned layer of the same colour, and a chip a transform draws at
0.3. The flag column keeps the sides that do show an edge. Browser engine
only: the static engine has no layout, and reports some of the pass cases.
-->
<style>
body { font-family: system-ui, sans-serif; background: #fafafa; padding: 24px; margin: 0; color: #0f172a; line-height: 1.5; }
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; max-width: 1400px; margin: 0 auto; }
.col h2 { font-size: 14px; text-transform: uppercase; letter-spacing: 0.05em; margin: 0 0 16px; color: #475569; }
.case { margin-bottom: 14px; padding: 14px 16px; background: white; border: 1px solid #e2e8f0; border-radius: 10px; }
.case-label { display: block; font-size: 12px; color: #64748b; margin-bottom: 8px; font-style: italic; }
.scroller { width: 300px; overflow-x: auto; border: 1px solid #cbd5e1; border-radius: 12px; }
.scroller table { min-width: 520px; border-collapse: collapse; }
.scroller td { width: 130px; padding: 8px 12px; }
.scroller td.bare { padding: 8px 12px 8px 0; }
.ellipsis-panel { width: 250px; background: #f8f8f8; border-right: 1px solid #d4d4d4; overflow: hidden; }
.ellipsis-panel .list { padding: 12px 15px; }
.ellipsis-panel .name { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.band { background: #f5f5f5; }
.band-top { margin: 0; padding: 12px 16px 0; }
.band-next { padding: 4px 16px 12px; }
.band-next.other { background: #e0e7ff; }
.layer-host { position: relative; padding: 0 16px; }
.layer-host .layer { position: absolute; inset: 0; background: #f5f5f5; }
.layer-host .content { position: relative; }
.pass-layer-grid { background: #f5f5f5; }
.pass-layer-grid p { margin: 0; }
.scaled { transform: scale(0.3); transform-origin: 0 0; width: 600px; height: 12px; }
/* 40px of line height leaves 3px of drawn room above and below the label
whatever face sets it (a CJK fallback on Windows draws a text box near
two ems tall), and under the 4px a full-scale edge needs, so only a
measure taken at the transform's scale passes it. */
.pass-scaled-chip { display: inline-block; background: #e8e8ea; padding: 0 6px; font-size: 14px; line-height: 40px; font-style: normal; }
</style>
</head>
<body>
<div class="grid">
<div class="col" data-col="flag">
<h2>Should flag</h2>
<div class="case">
<span class="case-label">a table that scrolls sideways in its bordered box: the far side is cut by the scroll, but the first cell's text starts on the box's left edge</span>
<div class="scroller flag-scroll-start"><table><tr><td class="bare">Starter plan</td><td>Team plan</td><td>Unlimited seats included</td><td>Enterprise</td></tr></table></div>
</div>
<div class="case">
<span class="case-label">two stacked bands in different colours: the edge between them shows, and the text sits on it</span>
<div><div class="band flag-band-next-differs"><p class="band-top">The first band's text runs to its bottom edge with no padding under it at all.</p></div><div class="band band-next other">The next band is painted another colour.</div></div>
</div>
</div>
<div class="col" data-col="pass">
<h2>Should pass</h2>
<div class="case">
<span class="case-label">a table that scrolls sideways in its bordered box: the text at the far side is cut by the scroll, not crowding the border (outreign.io, onco.cc)</span>
<div class="scroller pass-scroll-table"><table><tr><td>Starter plan</td><td>Team plan</td><td>Unlimited seats included</td><td>Enterprise</td></tr></table></div>
</div>
<div class="case">
<span class="case-label">a list title an ellipsis ends inside the list's 15px inset; only the laid-out run reaches the panel's border (inven.co.kr)</span>
<div class="ellipsis-panel pass-ellipsis-panel"><div><div class="list"><div class="name"><span>A post title long enough that its ellipsis ends it well inside the panel</span></div></div></div></div>
</div>
<div class="case">
<span class="case-label">two stacked bands in one grey: the edge between them is no edge (cencora.com)</span>
<div><div class="band pass-same-band"><p class="band-top">The first band's text runs to its bottom edge with no padding under it at all.</p></div><div class="band band-next">The next band is the same grey.</div></div>
</div>
<div class="case">
<span class="case-label">a grey grid on a section whose grey is an absolutely positioned layer beside the content (hp.com)</span>
<div class="layer-host"><div class="layer"></div><div class="content"><div class="pass-layer-grid"><p>The cards start on the section's own gutter, and the grid's grey is the section's grey.</p></div></div></div>
</div>
<div class="case">
<span class="case-label">a chip in a column a transform draws at 0.3 (people.com.cn): the room around its label is measured at that scale</span>
<div class="scaled"><i class="pass-scaled-chip"><a>社会·法治</a></i></div>
</div>
</div>
</div>
</body>
</html>