[{"data":1,"prerenderedAt":2181},["ShallowReactive",2],{"page-\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002Fforced-colors-mode-and-animations":3,"content-all-pages":1616,"live-demo:forced-colors-states":2175},{"id":4,"title":5,"body":6,"description":1599,"extension":1600,"meta":1601,"navigation":470,"path":1612,"seo":1613,"stem":1614,"__hash__":1615},"content\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002Fforced-colors-mode-and-animations\u002Findex.md","Forced Colors Mode and Animations",{"type":7,"value":8,"toc":1587},"minimark",[9,13,33,38,94,184,195,199,202,242,246,249,253,1276,1283,1287,1301,1355,1359,1403,1413,1417,1420,1464,1467,1471,1483,1487,1498,1502,1517,1536,1542,1552,1556,1584],[10,11,5],"h1",{"id":12},"forced-colors-mode-and-animations",[14,15,16,17,21,22,27,28,32],"p",{},"Some users replace every colour on the web with a small palette of their own. Windows contrast themes are the best-known example: the operating system tells the browser to render text, backgrounds, links, buttons and borders in a handful of system colours, chosen by the user for readability. The browser complies by overriding author colours — and by removing box shadows, text shadows and gradient backgrounds. Layout, transforms and opacity are untouched, so most animations still run, but any animation that ",[18,19,20],"em",{},"communicates"," through colour, shadow or gradient loses its message. This page covers what forced colors mode overrides, which common micro-interactions break, and how to restore them with a few targeted rules. It belongs to ",[23,24,26],"a",{"href":25},"\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002F","Accessibility in CSS Animations"," in the ",[23,29,31],{"href":30},"\u002Fcss-only-micro-interactions-animations\u002F","CSS-Only Micro-Interactions & Animations"," guide.",[34,35,37],"h2",{"id":36},"what-the-browser-overrides","What the browser overrides",[14,39,40,41,45,46,45,49,45,52,45,55,45,58,61,62,65,66,69,70,73,74,77,78,45,81,45,84,45,87,45,90,93],{},"In forced colors mode, a defined set of properties is replaced at computed-value time. Colours — ",[42,43,44],"code",{},"color",", ",[42,47,48],{},"background-color",[42,50,51],{},"border-color",[42,53,54],{},"outline-color",[42,56,57],{},"fill",[42,59,60],{},"stroke"," and a few more — take system colours. ",[42,63,64],{},"box-shadow"," and ",[42,67,68],{},"text-shadow"," become ",[42,71,72],{},"none",". ",[42,75,76],{},"background-image"," is removed unless it is an image loaded from a URL, so gradients disappear. Everything else keeps its author value: ",[42,79,80],{},"transform",[42,82,83],{},"translate",[42,85,86],{},"scale",[42,88,89],{},"opacity",[42,91,92],{},"clip-path",", sizes and positions all behave normally.",[95,96,102,103,102,107,102,111,102,119,102,129,102,134,102,140,102,144,102,149,102,153,102,157,102,161,102,165,102,168,102,170,102,173,102,176,102,179],"svg",{"viewBox":97,"role":98,"ariaLabel":99,"xmlns":100,"style":101},"0 0 720 300","img","Two columns: properties forced in forced colors mode, such as colors, shadows and gradient backgrounds, and properties left alone, such as transform, opacity, clip-path and layout","http:\u002F\u002Fwww.w3.org\u002F2000\u002Fsvg","width:100%;height:auto;max-width:720px;margin:2rem 0","\n  ",[104,105,106],"title",{},"Forced versus preserved properties",[108,109,110],"desc",{},"Left column titled overridden lists color and background-color, border-color and outline-color, box-shadow and text-shadow set to none, and gradient background-image removed. Right column titled preserved lists transform, translate and scale, opacity, clip-path and mask, and layout properties. Animations of preserved properties still show; animations of overridden ones do not.",[112,113,118],"text",{"textAnchor":114,"x":115,"y":116,"style":117},"middle","360","26","text-anchor:middle;fill:currentColor;font:700 17px sans-serif","Animate what survives",[120,121],"rect",{"x":122,"y":123,"width":124,"height":125,"rx":126,"fill":127,"opacity":128},"40","50","300","220","10","currentColor","0.08",[120,130],{"x":131,"y":123,"width":124,"height":125,"rx":126,"fill":132,"opacity":133},"380","#7aa2ff","0.2",[112,135,139],{"textAnchor":114,"x":136,"y":137,"style":138},"190","80","text-anchor:middle;fill:currentColor;font:600 14px sans-serif","Overridden",[112,141,143],{"textAnchor":114,"x":142,"y":137,"style":138},"530","Preserved",[112,145,148],{"textAnchor":114,"x":136,"y":146,"style":147},"116","text-anchor:middle;fill:currentColor;font:12px ui-monospace,monospace","color, background-color",[112,150,152],{"textAnchor":114,"x":136,"y":151,"style":147},"146","border-color, outline-color",[112,154,156],{"textAnchor":114,"x":136,"y":155,"style":147},"176","box-shadow → none",[112,158,160],{"textAnchor":114,"x":136,"y":159,"style":147},"206","text-shadow → none",[112,162,164],{"textAnchor":114,"x":136,"y":163,"style":147},"236","gradient backgrounds removed",[112,166,167],{"textAnchor":114,"x":142,"y":146,"style":147},"transform, translate, scale",[112,169,89],{"textAnchor":114,"x":142,"y":151,"style":147},[112,171,172],{"textAnchor":114,"x":142,"y":155,"style":147},"clip-path, mask",[112,174,175],{"textAnchor":114,"x":142,"y":159,"style":147},"outline-width, border-width",[112,177,178],{"textAnchor":114,"x":142,"y":163,"style":147},"sizes and positions",[112,180,183],{"textAnchor":114,"x":115,"y":181,"style":182},"292","text-anchor:middle;fill:currentColor;font:12px sans-serif","Widths and styles survive even where colours are replaced.",[14,185,186,187,190,191,194],{},"The key insight is in the bottom-right entry: border and outline ",[18,188,189],{},"colours"," are forced, but their ",[18,192,193],{},"widths and styles"," are not. A border that appears, thickens or changes from dashed to solid is still visible, drawn in the system's border colour. That is the main tool for restoring state indicators.",[34,196,198],{"id":197},"micro-interactions-that-break","Micro-interactions that break",[14,200,201],{},"Four patterns account for most failures:",[203,204,205,217,227,236],"ol",{},[206,207,208,212,213,216],"li",{},[209,210,211],"strong",{},"Box-shadow focus rings."," A glowing ",[42,214,215],{},"box-shadow: 0 0 0 3px"," focus ring vanishes. Keyboard users lose their place entirely — a failure of WCAG 2.4.7.",[206,218,219,222,223,226],{},[209,220,221],{},"Colour-only hover and selected states."," A card whose hover state only shifts its background, or a tab whose selected state is only a coloured underline drawn with ",[42,224,225],{},"background",", has no visible change.",[206,228,229,232,233,235],{},[209,230,231],{},"Gradient-based loaders."," Shimmer skeletons and animated gradient borders are ",[42,234,76],{}," effects; they are removed, so the loader shows as a static empty box with no sign of progress.",[206,237,238,241],{},[209,239,240],{},"Shadow-based depth."," Pressed buttons that communicate state through a collapsing shadow lose the effect, though their translation remains.",[34,243,245],{"id":244},"the-complete-implementation","The complete implementation",[14,247,248],{},"The demo shows a card with a focus ring, a selected state and a loading shimmer, each with a forced-colors fallback in the code below. Normal rendering is shown in the demo; open it with forced colors emulated in DevTools to see the fallbacks take over.",[250,251],"live-demo",{"name":252},"forced-colors-states",[254,255,260],"pre",{"className":256,"code":257,"language":258,"meta":259,"style":259},"language-html shiki shiki-themes github-light-high-contrast github-dark-high-contrast","\u003C!doctype html>\n\u003Chtml lang=\"en\">\n\u003Chead>\n\u003Cmeta charset=\"utf-8\">\n\u003Cmeta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n\u003Ctitle>Forced colors fallbacks\u003C\u002Ftitle>\n\u003Cstyle>\n  body { font: 15px\u002F1.5 system-ui, sans-serif; margin: 2rem; display: grid; gap: 1rem; max-inline-size: 26rem; }\n\n  \u002F* 1. Focus ring: shadow for style, transparent outline for forced colors. *\u002F\n  .option {\n    padding: 0.75rem 1rem;\n    border: 2px solid #e2e8f0;\n    border-radius: 10px;\n    background: #fff;\n    transition: box-shadow 150ms ease-out, border-color 150ms ease-out;\n  }\n  .option:focus-visible {\n    box-shadow: 0 0 0 4px rgb(37 99 235 \u002F 0.35);\n    outline: 2px solid transparent;   \u002F* becomes visible when colours are forced *\u002F\n    outline-offset: 2px;\n  }\n\n  \u002F* 2. Selected state: colour plus a border style change. *\u002F\n  .option[aria-pressed=\"true\"] {\n    border-color: #2563eb;\n    background: #eff6ff;\n  }\n\n  \u002F* 3. Shimmer loader with a structural fallback. *\u002F\n  .skeleton {\n    block-size: 1rem;\n    border-radius: 4px;\n    background: linear-gradient(90deg, #e2e8f0 25%, #f8fafc 50%, #e2e8f0 75%) 0 0 \u002F 200% 100%;\n    animation: shimmer 1.4s linear infinite;\n  }\n  @keyframes shimmer { to { background-position: -200% 0; } }\n\n  @media (forced-colors: active) {\n    .option[aria-pressed=\"true\"] {\n      border-style: double;\n      border-width: 4px;              \u002F* width and style survive forcing *\u002F\n    }\n    .skeleton {\n      border: 1px solid CanvasText;\n      animation: pulse 1.4s ease-in-out infinite alternate;\n    }\n    @keyframes pulse { from { opacity: 1; } to { opacity: 0.4; } }\n  }\n\n  @media (prefers-reduced-motion: reduce) {\n    .skeleton { animation: none; }\n  }\n\u003C\u002Fstyle>\n\u003C\u002Fhead>\n\u003Cbody>\n  \u003Cbutton class=\"option\" type=\"button\" aria-pressed=\"true\">Monthly billing\u003C\u002Fbutton>\n  \u003Cbutton class=\"option\" type=\"button\" aria-pressed=\"false\">Annual billing\u003C\u002Fbutton>\n  \u003Cdiv class=\"skeleton\" role=\"status\" aria-label=\"Loading\">\u003C\u002Fdiv>\n\u003C\u002Fbody>\n\u003C\u002Fhtml>\n","html","",[42,261,262,282,302,312,330,355,369,379,465,472,479,488,509,529,543,556,585,591,599,644,667,681,686,691,697,716,729,741,746,751,757,765,779,793,862,885,890,922,927,936,952,965,983,989,997,1014,1037,1042,1080,1085,1090,1098,1114,1119,1129,1138,1148,1187,1220,1258,1267],{"__ignoreMap":259},[263,264,267,271,275,279],"span",{"class":265,"line":266},"line",1,[263,268,270],{"class":269},"suds8","\u003C!",[263,272,274],{"class":273},"sne4z","doctype",[263,276,278],{"class":277},"s-5SL"," html",[263,280,281],{"class":269},">\n",[263,283,285,288,290,293,296,300],{"class":265,"line":284},2,[263,286,287],{"class":269},"\u003C",[263,289,258],{"class":273},[263,291,292],{"class":277}," lang",[263,294,295],{"class":269},"=",[263,297,299],{"class":298},"sT6z2","\"en\"",[263,301,281],{"class":269},[263,303,305,307,310],{"class":265,"line":304},3,[263,306,287],{"class":269},[263,308,309],{"class":273},"head",[263,311,281],{"class":269},[263,313,315,317,320,323,325,328],{"class":265,"line":314},4,[263,316,287],{"class":269},[263,318,319],{"class":273},"meta",[263,321,322],{"class":277}," charset",[263,324,295],{"class":269},[263,326,327],{"class":298},"\"utf-8\"",[263,329,281],{"class":269},[263,331,333,335,337,340,342,345,348,350,353],{"class":265,"line":332},5,[263,334,287],{"class":269},[263,336,319],{"class":273},[263,338,339],{"class":277}," name",[263,341,295],{"class":269},[263,343,344],{"class":298},"\"viewport\"",[263,346,347],{"class":277}," content",[263,349,295],{"class":269},[263,351,352],{"class":298},"\"width=device-width, initial-scale=1\"",[263,354,281],{"class":269},[263,356,358,360,362,365,367],{"class":265,"line":357},6,[263,359,287],{"class":269},[263,361,104],{"class":273},[263,363,364],{"class":269},">Forced colors fallbacks\u003C\u002F",[263,366,104],{"class":273},[263,368,281],{"class":269},[263,370,372,374,377],{"class":265,"line":371},7,[263,373,287],{"class":269},[263,375,376],{"class":273},"style",[263,378,281],{"class":269},[263,380,382,385,388,391,394,397,401,404,407,410,412,415,418,421,423,426,429,431,434,436,439,441,444,446,449,451,453,456,458,460,462],{"class":265,"line":381},8,[263,383,384],{"class":273},"  body",[263,386,387],{"class":269}," { ",[263,389,390],{"class":277},"font",[263,392,393],{"class":269},": ",[263,395,396],{"class":277},"15",[263,398,400],{"class":399},"sHUrx","px",[263,402,403],{"class":269},"\u002F",[263,405,406],{"class":277},"1.5",[263,408,409],{"class":277}," system-ui",[263,411,45],{"class":269},[263,413,414],{"class":277},"sans-serif",[263,416,417],{"class":269},"; ",[263,419,420],{"class":277},"margin",[263,422,393],{"class":269},[263,424,425],{"class":277},"2",[263,427,428],{"class":399},"rem",[263,430,417],{"class":269},[263,432,433],{"class":277},"display",[263,435,393],{"class":269},[263,437,438],{"class":277},"grid",[263,440,417],{"class":269},[263,442,443],{"class":277},"gap",[263,445,393],{"class":269},[263,447,448],{"class":277},"1",[263,450,428],{"class":399},[263,452,417],{"class":269},[263,454,455],{"class":277},"max-inline-size",[263,457,393],{"class":269},[263,459,116],{"class":277},[263,461,428],{"class":399},[263,463,464],{"class":269},"; }\n",[263,466,468],{"class":265,"line":467},9,[263,469,471],{"emptyLinePlaceholder":470},true,"\n",[263,473,475],{"class":265,"line":474},10,[263,476,478],{"class":477},"sLBg1","  \u002F* 1. Focus ring: shadow for style, transparent outline for forced colors. *\u002F\n",[263,480,482,485],{"class":265,"line":481},11,[263,483,484],{"class":277},"  .option",[263,486,487],{"class":269}," {\n",[263,489,491,494,496,499,501,504,506],{"class":265,"line":490},12,[263,492,493],{"class":277},"    padding",[263,495,393],{"class":269},[263,497,498],{"class":277},"0.75",[263,500,428],{"class":399},[263,502,503],{"class":277}," 1",[263,505,428],{"class":399},[263,507,508],{"class":269},";\n",[263,510,512,515,517,519,521,524,527],{"class":265,"line":511},13,[263,513,514],{"class":277},"    border",[263,516,393],{"class":269},[263,518,425],{"class":277},[263,520,400],{"class":399},[263,522,523],{"class":277}," solid",[263,525,526],{"class":277}," #e2e8f0",[263,528,508],{"class":269},[263,530,532,535,537,539,541],{"class":265,"line":531},14,[263,533,534],{"class":277},"    border-radius",[263,536,393],{"class":269},[263,538,126],{"class":277},[263,540,400],{"class":399},[263,542,508],{"class":269},[263,544,546,549,551,554],{"class":265,"line":545},15,[263,547,548],{"class":277},"    background",[263,550,393],{"class":269},[263,552,553],{"class":277},"#fff",[263,555,508],{"class":269},[263,557,559,562,565,568,571,574,577,579,581,583],{"class":265,"line":558},16,[263,560,561],{"class":277},"    transition",[263,563,564],{"class":269},": box-shadow ",[263,566,567],{"class":277},"150",[263,569,570],{"class":399},"ms",[263,572,573],{"class":277}," ease-out",[263,575,576],{"class":269},", border-color ",[263,578,567],{"class":277},[263,580,570],{"class":399},[263,582,573],{"class":277},[263,584,508],{"class":269},[263,586,588],{"class":265,"line":587},17,[263,589,590],{"class":269},"  }\n",[263,592,594,597],{"class":265,"line":593},18,[263,595,596],{"class":277},"  .option:focus-visible",[263,598,487],{"class":269},[263,600,602,605,607,610,613,615,618,620,623,626,629,632,635,638,641],{"class":265,"line":601},19,[263,603,604],{"class":277},"    box-shadow",[263,606,393],{"class":269},[263,608,609],{"class":277},"0",[263,611,612],{"class":277}," 0",[263,614,612],{"class":277},[263,616,617],{"class":277}," 4",[263,619,400],{"class":399},[263,621,622],{"class":277}," rgb",[263,624,625],{"class":269},"(",[263,627,628],{"class":277},"37",[263,630,631],{"class":277}," 99",[263,633,634],{"class":277}," 235",[263,636,637],{"class":269}," \u002F ",[263,639,640],{"class":277},"0.35",[263,642,643],{"class":269},");\n",[263,645,647,650,652,654,656,658,661,664],{"class":265,"line":646},20,[263,648,649],{"class":277},"    outline",[263,651,393],{"class":269},[263,653,425],{"class":277},[263,655,400],{"class":399},[263,657,523],{"class":277},[263,659,660],{"class":277}," transparent",[263,662,663],{"class":269},";   ",[263,665,666],{"class":477},"\u002F* becomes visible when colours are forced *\u002F\n",[263,668,670,673,675,677,679],{"class":265,"line":669},21,[263,671,672],{"class":277},"    outline-offset",[263,674,393],{"class":269},[263,676,425],{"class":277},[263,678,400],{"class":399},[263,680,508],{"class":269},[263,682,684],{"class":265,"line":683},22,[263,685,590],{"class":269},[263,687,689],{"class":265,"line":688},23,[263,690,471],{"emptyLinePlaceholder":470},[263,692,694],{"class":265,"line":693},24,[263,695,696],{"class":477},"  \u002F* 2. Selected state: colour plus a border style change. *\u002F\n",[263,698,700,702,705,708,710,713],{"class":265,"line":699},25,[263,701,484],{"class":277},[263,703,704],{"class":269},"[",[263,706,707],{"class":277},"aria-pressed",[263,709,295],{"class":399},[263,711,712],{"class":298},"\"true\"",[263,714,715],{"class":269},"] {\n",[263,717,719,722,724,727],{"class":265,"line":718},26,[263,720,721],{"class":277},"    border-color",[263,723,393],{"class":269},[263,725,726],{"class":277},"#2563eb",[263,728,508],{"class":269},[263,730,732,734,736,739],{"class":265,"line":731},27,[263,733,548],{"class":277},[263,735,393],{"class":269},[263,737,738],{"class":277},"#eff6ff",[263,740,508],{"class":269},[263,742,744],{"class":265,"line":743},28,[263,745,590],{"class":269},[263,747,749],{"class":265,"line":748},29,[263,750,471],{"emptyLinePlaceholder":470},[263,752,754],{"class":265,"line":753},30,[263,755,756],{"class":477},"  \u002F* 3. Shimmer loader with a structural fallback. *\u002F\n",[263,758,760,763],{"class":265,"line":759},31,[263,761,762],{"class":277},"  .skeleton",[263,764,487],{"class":269},[263,766,768,771,773,775,777],{"class":265,"line":767},32,[263,769,770],{"class":277},"    block-size",[263,772,393],{"class":269},[263,774,448],{"class":277},[263,776,428],{"class":399},[263,778,508],{"class":269},[263,780,782,784,786,789,791],{"class":265,"line":781},33,[263,783,534],{"class":277},[263,785,393],{"class":269},[263,787,788],{"class":277},"4",[263,790,400],{"class":399},[263,792,508],{"class":269},[263,794,796,798,800,803,805,808,811,813,816,819,822,824,827,830,832,834,836,839,841,844,846,848,850,853,855,858,860],{"class":265,"line":795},34,[263,797,548],{"class":277},[263,799,393],{"class":269},[263,801,802],{"class":277},"linear-gradient",[263,804,625],{"class":269},[263,806,807],{"class":277},"90",[263,809,810],{"class":399},"deg",[263,812,45],{"class":269},[263,814,815],{"class":277},"#e2e8f0",[263,817,818],{"class":277}," 25",[263,820,821],{"class":399},"%",[263,823,45],{"class":269},[263,825,826],{"class":277},"#f8fafc",[263,828,829],{"class":277}," 50",[263,831,821],{"class":399},[263,833,45],{"class":269},[263,835,815],{"class":277},[263,837,838],{"class":277}," 75",[263,840,821],{"class":399},[263,842,843],{"class":269},") ",[263,845,609],{"class":277},[263,847,612],{"class":277},[263,849,637],{"class":269},[263,851,852],{"class":277},"200",[263,854,821],{"class":399},[263,856,857],{"class":277}," 100",[263,859,821],{"class":399},[263,861,508],{"class":269},[263,863,865,868,871,874,877,880,883],{"class":265,"line":864},35,[263,866,867],{"class":277},"    animation",[263,869,870],{"class":269},": shimmer ",[263,872,873],{"class":277},"1.4",[263,875,876],{"class":399},"s",[263,878,879],{"class":277}," linear",[263,881,882],{"class":277}," infinite",[263,884,508],{"class":269},[263,886,888],{"class":265,"line":887},36,[263,889,590],{"class":269},[263,891,893,896,900,902,905,907,910,912,915,917,919],{"class":265,"line":892},37,[263,894,895],{"class":399},"  @keyframes",[263,897,899],{"class":898},"soyes"," shimmer",[263,901,387],{"class":269},[263,903,904],{"class":277},"to",[263,906,387],{"class":269},[263,908,909],{"class":277},"background-position",[263,911,393],{"class":269},[263,913,914],{"class":277},"-200",[263,916,821],{"class":399},[263,918,612],{"class":277},[263,920,921],{"class":269},"; } }\n",[263,923,925],{"class":265,"line":924},38,[263,926,471],{"emptyLinePlaceholder":470},[263,928,930,933],{"class":265,"line":929},39,[263,931,932],{"class":399},"  @media",[263,934,935],{"class":269}," (forced-colors: active) {\n",[263,937,939,942,944,946,948,950],{"class":265,"line":938},40,[263,940,941],{"class":277},"    .option",[263,943,704],{"class":269},[263,945,707],{"class":277},[263,947,295],{"class":399},[263,949,712],{"class":298},[263,951,715],{"class":269},[263,953,955,958,960,963],{"class":265,"line":954},41,[263,956,957],{"class":277},"      border-style",[263,959,393],{"class":269},[263,961,962],{"class":277},"double",[263,964,508],{"class":269},[263,966,968,971,973,975,977,980],{"class":265,"line":967},42,[263,969,970],{"class":277},"      border-width",[263,972,393],{"class":269},[263,974,788],{"class":277},[263,976,400],{"class":399},[263,978,979],{"class":269},";              ",[263,981,982],{"class":477},"\u002F* width and style survive forcing *\u002F\n",[263,984,986],{"class":265,"line":985},43,[263,987,988],{"class":269},"    }\n",[263,990,992,995],{"class":265,"line":991},44,[263,993,994],{"class":277},"    .skeleton",[263,996,487],{"class":269},[263,998,1000,1003,1005,1007,1009,1011],{"class":265,"line":999},45,[263,1001,1002],{"class":277},"      border",[263,1004,393],{"class":269},[263,1006,448],{"class":277},[263,1008,400],{"class":399},[263,1010,523],{"class":277},[263,1012,1013],{"class":269}," CanvasText;\n",[263,1015,1017,1020,1023,1025,1027,1030,1032,1035],{"class":265,"line":1016},46,[263,1018,1019],{"class":277},"      animation",[263,1021,1022],{"class":269},": pulse ",[263,1024,873],{"class":277},[263,1026,876],{"class":399},[263,1028,1029],{"class":277}," ease-in-out",[263,1031,882],{"class":277},[263,1033,1034],{"class":277}," alternate",[263,1036,508],{"class":269},[263,1038,1040],{"class":265,"line":1039},47,[263,1041,988],{"class":269},[263,1043,1045,1048,1051,1053,1056,1058,1060,1062,1064,1067,1069,1071,1073,1075,1078],{"class":265,"line":1044},48,[263,1046,1047],{"class":399},"    @keyframes",[263,1049,1050],{"class":898}," pulse",[263,1052,387],{"class":269},[263,1054,1055],{"class":277},"from",[263,1057,387],{"class":269},[263,1059,89],{"class":277},[263,1061,393],{"class":269},[263,1063,448],{"class":277},[263,1065,1066],{"class":269},"; } ",[263,1068,904],{"class":277},[263,1070,387],{"class":269},[263,1072,89],{"class":277},[263,1074,393],{"class":269},[263,1076,1077],{"class":277},"0.4",[263,1079,921],{"class":269},[263,1081,1083],{"class":265,"line":1082},49,[263,1084,590],{"class":269},[263,1086,1088],{"class":265,"line":1087},50,[263,1089,471],{"emptyLinePlaceholder":470},[263,1091,1093,1095],{"class":265,"line":1092},51,[263,1094,932],{"class":399},[263,1096,1097],{"class":269}," (prefers-reduced-motion: reduce) {\n",[263,1099,1101,1103,1105,1108,1110,1112],{"class":265,"line":1100},52,[263,1102,994],{"class":277},[263,1104,387],{"class":269},[263,1106,1107],{"class":277},"animation",[263,1109,393],{"class":269},[263,1111,72],{"class":277},[263,1113,464],{"class":269},[263,1115,1117],{"class":265,"line":1116},53,[263,1118,590],{"class":269},[263,1120,1122,1125,1127],{"class":265,"line":1121},54,[263,1123,1124],{"class":269},"\u003C\u002F",[263,1126,376],{"class":273},[263,1128,281],{"class":269},[263,1130,1132,1134,1136],{"class":265,"line":1131},55,[263,1133,1124],{"class":269},[263,1135,309],{"class":273},[263,1137,281],{"class":269},[263,1139,1141,1143,1146],{"class":265,"line":1140},56,[263,1142,287],{"class":269},[263,1144,1145],{"class":273},"body",[263,1147,281],{"class":269},[263,1149,1151,1154,1157,1160,1162,1165,1168,1170,1173,1176,1178,1180,1183,1185],{"class":265,"line":1150},57,[263,1152,1153],{"class":269},"  \u003C",[263,1155,1156],{"class":273},"button",[263,1158,1159],{"class":277}," class",[263,1161,295],{"class":269},[263,1163,1164],{"class":298},"\"option\"",[263,1166,1167],{"class":277}," type",[263,1169,295],{"class":269},[263,1171,1172],{"class":298},"\"button\"",[263,1174,1175],{"class":277}," aria-pressed",[263,1177,295],{"class":269},[263,1179,712],{"class":298},[263,1181,1182],{"class":269},">Monthly billing\u003C\u002F",[263,1184,1156],{"class":273},[263,1186,281],{"class":269},[263,1188,1190,1192,1194,1196,1198,1200,1202,1204,1206,1208,1210,1213,1216,1218],{"class":265,"line":1189},58,[263,1191,1153],{"class":269},[263,1193,1156],{"class":273},[263,1195,1159],{"class":277},[263,1197,295],{"class":269},[263,1199,1164],{"class":298},[263,1201,1167],{"class":277},[263,1203,295],{"class":269},[263,1205,1172],{"class":298},[263,1207,1175],{"class":277},[263,1209,295],{"class":269},[263,1211,1212],{"class":298},"\"false\"",[263,1214,1215],{"class":269},">Annual billing\u003C\u002F",[263,1217,1156],{"class":273},[263,1219,281],{"class":269},[263,1221,1223,1225,1228,1230,1232,1235,1238,1240,1243,1246,1248,1251,1254,1256],{"class":265,"line":1222},59,[263,1224,1153],{"class":269},[263,1226,1227],{"class":273},"div",[263,1229,1159],{"class":277},[263,1231,295],{"class":269},[263,1233,1234],{"class":298},"\"skeleton\"",[263,1236,1237],{"class":277}," role",[263,1239,295],{"class":269},[263,1241,1242],{"class":298},"\"status\"",[263,1244,1245],{"class":277}," aria-label",[263,1247,295],{"class":269},[263,1249,1250],{"class":298},"\"Loading\"",[263,1252,1253],{"class":269},">\u003C\u002F",[263,1255,1227],{"class":273},[263,1257,281],{"class":269},[263,1259,1261,1263,1265],{"class":265,"line":1260},60,[263,1262,1124],{"class":269},[263,1264,1145],{"class":273},[263,1266,281],{"class":269},[263,1268,1270,1272,1274],{"class":265,"line":1269},61,[263,1271,1124],{"class":269},[263,1273,258],{"class":273},[263,1275,281],{"class":269},[14,1277,1278,1279,1282],{},"Each fallback swaps a forced property for a preserved one. The focus rule draws a shadow in normal rendering and also sets a transparent outline; forced colors mode replaces ",[42,1280,1281],{},"transparent"," with a visible system colour, so the ring appears automatically, without a media query. The selected state adds a thicker, double border. The skeleton, whose gradient disappears, gains a system-coloured border and switches to an opacity pulse, which forced colors leaves alone.",[34,1284,1286],{"id":1285},"the-key-technique-the-transparent-outline","The key technique: the transparent outline",[14,1288,1289,1290,1293,1294,1296,1297,1300],{},"The transparent outline trick deserves its own emphasis because it fixes the single most harmful failure with one line. ",[42,1291,1292],{},"outline: 2px solid transparent"," is invisible in normal rendering, so it costs nothing visually. In forced colors mode, the browser replaces author colours — including ",[42,1295,1281],{}," in outlines and borders — with the appropriate system colour, and a solid 2-pixel outline appears exactly where the focus ring was. Put it in the same ",[42,1298,1299],{},":focus-visible"," rule as the shadow — never on the element's resting state, or every element would show a ring when colours are forced.",[95,1302,102,1305,102,1308,102,1311,102,1314,102,1321,102,1327,102,1333,102,1336,102,1341,102,1344,102,1348,102,1351],{"viewBox":1303,"role":98,"ariaLabel":1304,"xmlns":100,"style":101},"0 0 720 250","A button in normal rendering showing a soft shadow focus ring with an invisible outline, and the same button in forced colors mode where the shadow is gone and the outline is drawn in a system colour",[104,1306,1307],{},"One outline, two renderings",[108,1309,1310],{},"Left: normal rendering. The button has a blurred blue shadow ring; the transparent outline is not visible. Right: forced colors mode. The shadow is removed and the outline, previously transparent, is painted in a solid system colour two pixels outside the button.",[112,1312,1313],{"textAnchor":114,"x":115,"y":116,"style":117},"transparent becomes visible when colours are forced",[120,1315],{"x":1316,"y":1317,"width":155,"height":1318,"rx":1319,"fill":132,"opacity":1320},"96","82","64","16","0.25",[120,1322],{"x":1323,"y":1316,"width":1324,"height":1325,"rx":1326,"fill":72,"stroke":127,"strokeWidth":406},"110","148","36","8",[112,1328,1332],{"textAnchor":114,"x":1329,"y":1330,"style":1331},"184","119","text-anchor:middle;fill:currentColor;font:600 13px sans-serif","Monthly",[120,1334],{"x":1335,"y":1316,"width":1324,"height":1325,"rx":1326,"fill":72,"stroke":127,"strokeWidth":406},"460",[1337,1338],"path",{"d":1339,"fill":72,"stroke":127,"strokeWidth":1340},"M454 90 H614 V138 H454 Z","2.5",[112,1342,1332],{"textAnchor":114,"x":1343,"y":1330,"style":1331},"534",[112,1345,1347],{"textAnchor":114,"x":1329,"y":1329,"style":1346},"text-anchor:middle;fill:currentColor;font:600 12px sans-serif","normal: shadow ring",[112,1349,1350],{"textAnchor":114,"x":1343,"y":1329,"style":1346},"forced: outline ring",[112,1352,1354],{"textAnchor":114,"x":115,"y":1353,"style":147},"224","outline: 2px solid transparent;",[34,1356,1358],{"id":1357},"system-colours-for-custom-components","System colours for custom components",[14,1360,1361,1362,1365,1366,65,1369,1372,1373,1376,1377,65,1380,1383,1384,65,1387,1390,1391,1394,1395,1398,1399,1402],{},"Inside ",[42,1363,1364],{},"@media (forced-colors: active)",", use CSS system colour keywords rather than hex values so the component follows the user's palette: ",[42,1367,1368],{},"Canvas",[42,1370,1371],{},"CanvasText"," for surfaces and text, ",[42,1374,1375],{},"LinkText"," for links, ",[42,1378,1379],{},"ButtonFace",[42,1381,1382],{},"ButtonText"," for buttons, ",[42,1385,1386],{},"Highlight",[42,1388,1389],{},"HighlightText"," for selected items, ",[42,1392,1393],{},"GrayText"," for disabled content. A custom toggle switch whose track is drawn with a background colour, for example, needs ",[42,1396,1397],{},"border: 1px solid ButtonText"," on the track and ",[42,1400,1401],{},"background: Highlight"," on the thumb when checked. The browser already forces these properties, but naming the keyword makes the mapping deliberate rather than whatever the automatic override chooses.",[14,1404,1405,1408,1409,1412],{},[42,1406,1407],{},"forced-color-adjust: none"," opts an element out of forcing altogether. Reserve it for elements where author colour ",[18,1410,1411],{},"is"," the content — a colour picker's swatches, a chart legend key — and keep it off containers, because it applies to descendants too.",[34,1414,1416],{"id":1415},"a-testing-checklist","A testing checklist",[14,1418,1419],{},"With forced colors emulated, walk through each interactive component and check that every state change is still perceivable:",[1421,1422,1423,1432,1438,1448,1454],"ul",{},[206,1424,1425,1428,1429,1431],{},[209,1426,1427],{},"Tab through the page."," Every focusable element should show a visible ring. Missing rings almost always mean a ",[42,1430,64],{}," focus style without an outline.",[206,1433,1434,1437],{},[209,1435,1436],{},"Hover and select."," Cards, tabs, list rows and toggles should still show which item is hovered and which is selected. Where only a background changed, add a border, an outline or an underline.",[206,1439,1440,1443,1444,1447],{},[209,1441,1442],{},"Trigger loading states."," Skeletons, spinners drawn with borders and progress bars should still show activity. Spinners built from ",[42,1445,1446],{},"border-top-color"," differences become a full, uniform circle because every border side gets the same system colour; a spinner that rotates a dashed or partial border, or an SVG arc, survives.",[206,1449,1450,1453],{},[209,1451,1452],{},"Open overlays."," Dialogs and popovers that rely on a shadow to separate them from the page need a border in forced colors mode, or they blend into the content behind them.",[206,1455,1456,1459,1460,1463],{},[209,1457,1458],{},"Check icons."," Inline SVG icons using ",[42,1461,1462],{},"fill: currentColor"," follow the forced text colour and remain visible; icons with hard-coded fills are forced too, but icons delivered as background images may be removed.",[14,1465,1466],{},"Each fix is usually one or two declarations inside the media query. The effort is small compared with the cost of an interface that becomes unusable for people who depend on their contrast theme.",[34,1468,1470],{"id":1469},"motion-itself-is-unaffected","Motion itself is unaffected",[14,1472,1473,1474,1477,1478,1482],{},"Forced colors mode is about colour, not motion. Users who choose a contrast theme have not necessarily asked for reduced motion, so opacity and transform animations should keep running unless ",[42,1475,1476],{},"prefers-reduced-motion: reduce"," is also set. The two preferences combine independently, which is why the implementation has both media queries: the skeleton pulses in forced colors mode and stops entirely when motion is reduced. ",[23,1479,1481],{"href":1480},"\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002Fprefers-reduced-motion-recipes\u002F","prefers-reduced-motion Recipes"," covers that side.",[34,1484,1486],{"id":1485},"browser-support","Browser support",[14,1488,1489,1490,1493,1494,1497],{},"The ",[42,1491,1492],{},"forced-colors"," media feature is supported in Chrome 89+, Edge 79+, Firefox 89+ and Safari 16+. Forced colors mode itself is activated by the operating system: Windows contrast themes are the most common source, and Chromium DevTools can emulate it from the Rendering panel. ",[42,1495,1496],{},"prefers-reduced-motion"," is supported in Chrome 74+, Edge 79+, Firefox 63+ and Safari 10.1+.",[34,1499,1501],{"id":1500},"faq","FAQ",[14,1503,1504,1507,1508,45,1510,45,1512,65,1514,1516],{},[209,1505,1506],{},"Do CSS animations run in forced colors mode?","\nYes. Animations and transitions keep running, but the forced properties, such as ",[42,1509,44],{},[42,1511,48],{},[42,1513,51],{},[42,1515,64],{},", are overridden with the user's system colours. An animation that only changes a forced colour becomes invisible.",[14,1518,1519,1522,1523,1525,1526,1528,1529,1531,1532,1535],{},[209,1520,1521],{},"Why did my focus ring disappear in high contrast mode?","\nFocus rings drawn with ",[42,1524,64],{}," are removed, because ",[42,1527,64],{}," is forced to ",[42,1530,72],{},". Use ",[42,1533,1534],{},"outline"," instead, or add a transparent outline alongside the shadow: forced colors mode replaces the transparent colour with a visible system colour.",[14,1537,1538,1541],{},[209,1539,1540],{},"Should I use forced-color-adjust: none?","\nOnly on small, specific elements whose colours carry meaning the system palette cannot express, such as a colour swatch picker. Applying it broadly overrides the user's chosen theme, which defeats the purpose of the setting.",[14,1543,1544,1547,1548,1551],{},[209,1545,1546],{},"How do I test forced colors without Windows?","\nChromium DevTools can emulate ",[42,1549,1550],{},"forced-colors: active"," from the Rendering panel. It is close enough for development; confirm important flows with a real contrast theme on Windows before release.",[34,1553,1555],{"id":1554},"related","Related",[1421,1557,1558,1563,1570,1577],{},[206,1559,1560,1562],{},[23,1561,26],{"href":25}," — the parent guide.",[206,1564,1565,1569],{},[23,1566,1568],{"href":1567},"\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002Fcreating-accessible-focus-indicators\u002F","Creating Accessible Focus Indicators"," — outline-based focus design.",[206,1571,1572,1576],{},[23,1573,1575],{"href":1574},"\u002Fcss-only-micro-interactions-animations\u002Fkeyframe-animation-patterns\u002Fcss-only-loading-spinners-and-skeletons\u002F","CSS-Only Loading Spinners and Skeletons"," — loaders that need these fallbacks.",[206,1578,1579,1583],{},[23,1580,1582],{"href":1581},"\u002Fcss-only-micro-interactions-animations\u002Fclip-path-and-mask-animations\u002Fanimated-gradient-borders-with-property\u002F","Animated Gradient Borders With @property"," — an effect removed by forced colors.",[376,1585,1586],{},"html pre.shiki code .suds8, html code.shiki .suds8{--shiki-default:#0E1116;--shiki-dark:#F0F3F6}html pre.shiki code .sne4z, html code.shiki .sne4z{--shiki-default:#024C1A;--shiki-dark:#72F088}html pre.shiki code .s-5SL, html code.shiki .s-5SL{--shiki-default:#023B95;--shiki-dark:#91CBFF}html pre.shiki code .sT6z2, html code.shiki .sT6z2{--shiki-default:#032563;--shiki-dark:#ADDCFF}html pre.shiki code .sHUrx, html code.shiki .sHUrx{--shiki-default:#A0111F;--shiki-dark:#FF9492}html pre.shiki code .sLBg1, html code.shiki .sLBg1{--shiki-default:#66707B;--shiki-dark:#BDC4CC}html pre.shiki code .soyes, html code.shiki .soyes{--shiki-default:#702C00;--shiki-dark:#FFB757}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":259,"searchDepth":284,"depth":284,"links":1588},[1589,1590,1591,1592,1593,1594,1595,1596,1597,1598],{"id":36,"depth":284,"text":37},{"id":197,"depth":284,"text":198},{"id":244,"depth":284,"text":245},{"id":1285,"depth":284,"text":1286},{"id":1357,"depth":284,"text":1358},{"id":1415,"depth":284,"text":1416},{"id":1469,"depth":284,"text":1470},{"id":1485,"depth":284,"text":1486},{"id":1500,"depth":284,"text":1501},{"id":1554,"depth":284,"text":1555},"What happens to transitions, focus rings, shimmer loaders and gradient effects when a contrast theme forces colours, and how to keep every state change visible.","md",{"pageTitle":5,"datePublished":1602,"dateModified":1602,"faq":1603},"2026-09-18",[1604,1606,1608,1610],{"q":1506,"a":1605},"Yes. Animations and transitions keep running, but the forced properties, such as color, background-color, border-color and box-shadow, are overridden with the user's system colours. An animation that only changes a forced colour becomes invisible.",{"q":1521,"a":1607},"Focus rings drawn with box-shadow are removed, because box-shadow is forced to none. Use outline instead, or add a transparent outline alongside the shadow: forced colors mode replaces the transparent colour with a visible system colour.",{"q":1540,"a":1609},"Only on small, specific elements whose colours carry meaning the system palette cannot express, such as a colour swatch picker. Applying it broadly overrides the user's chosen theme, which defeats the purpose of the setting.",{"q":1546,"a":1611},"Chromium DevTools can emulate forced-colors: active from the Rendering panel. It is close enough for development; confirm important flows with a real contrast theme on Windows before release.","\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002Fforced-colors-mode-and-animations",{"title":5,"description":1599},"css-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002Fforced-colors-mode-and-animations\u002Findex","LFptfzxNTmiDxmRbeYVxEUePfSnt8kyAE6RLhwQR_ow",[1617,1620,1623,1624,1627,1630,1633,1636,1639,1642,1645,1648,1651,1654,1657,1660,1663,1666,1669,1672,1675,1678,1681,1684,1687,1690,1693,1696,1699,1702,1705,1708,1711,1714,1717,1720,1723,1726,1729,1732,1735,1738,1741,1744,1747,1750,1753,1756,1759,1762,1765,1768,1771,1774,1777,1780,1783,1786,1789,1792,1795,1798,1801,1804,1807,1810,1813,1816,1819,1822,1825,1828,1831,1834,1837,1840,1843,1846,1849,1852,1855,1858,1861,1864,1867,1870,1873,1876,1879,1882,1885,1888,1891,1894,1896,1899,1902,1905,1908,1911,1914,1917,1920,1923,1926,1929,1932,1935,1938,1941,1944,1947,1950,1953,1956,1959,1962,1965,1968,1971,1974,1977,1980,1983,1986,1989,1992,1995,1998,2001,2004,2007,2010,2013,2016,2019,2022,2025,2028,2031,2034,2037,2040,2043,2046,2049,2052,2055,2058,2061,2064,2067,2070,2073,2076,2079,2082,2085,2088,2091,2094,2097,2100,2103,2106,2109,2112,2115,2118,2121,2124,2127,2130,2133,2136,2139,2142,2145,2148,2151,2154,2157,2160,2163,2166,2169,2172],{"path":1618,"title":1619},"\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002Fcreating-accessible-focus-indicators","Creating Accessible Focus Indicators: Building a Ring That Survives Any Background",{"path":1621,"title":1622},"\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002Fflashing-content-and-seizure-thresholds","Flashing Content and Seizure Thresholds",{"path":1612,"title":5},{"path":1625,"title":1626},"\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations","Accessibility in CSS Animations: Patterns, Specs & Best Practices",{"path":1628,"title":1629},"\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002Fpause-controls-for-looping-animations","Pause Controls for Looping CSS Animations: Meeting WCAG 2.2.2",{"path":1631,"title":1632},"\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002Fprefers-reduced-motion-recipes","prefers-reduced-motion Recipes: A Reduction for Every Common Effect",{"path":1634,"title":1635},"\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002Freducing-motion-preferences-in-css","Reducing Motion Preferences in CSS: How the Setting Becomes a Media Feature",{"path":1637,"title":1638},"\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002Ftarget-size-and-pointer-accessibility","Target Size and Pointer Accessibility: Meeting 2.5.8 Without Redesigning",{"path":1640,"title":1641},"\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002Fvestibular-safe-animation-patterns","Vestibular-Safe Animation Patterns: Why Some Motion Makes People Sick",{"path":1643,"title":1644},"\u002Fcss-only-micro-interactions-animations\u002Faccessibility-in-css-animations\u002Fwcag-motion-success-criteria","WCAG Motion Success Criteria: What Each One Actually Requires",{"path":1646,"title":1647},"\u002Fcss-only-micro-interactions-animations\u002Fclip-path-and-mask-animations\u002Fanimated-gradient-borders-with-property","Animated Gradient Borders With @property: A Spinning Highlight Without Extra Elements",{"path":1649,"title":1650},"\u002Fcss-only-micro-interactions-animations\u002Fclip-path-and-mask-animations\u002Fclip-path-reveal-animations","Clip-Path Reveal Animations: Wipes, Irises and Corners Without Extra Markup",{"path":1652,"title":1653},"\u002Fcss-only-micro-interactions-animations\u002Fclip-path-and-mask-animations","Clip-Path & Mask Animations: Animating Visibility Instead of Position",{"path":1655,"title":1656},"\u002Fcss-only-micro-interactions-animations\u002Fclip-path-and-mask-animations\u002Fmask-image-fade-edges","Fading Edges With mask-image: Soft Boundaries That Work on Any Background",{"path":1658,"title":1659},"\u002Fcss-only-micro-interactions-animations\u002Fclip-path-and-mask-animations\u002Fmorphing-shapes-with-clip-path-polygon","Morphing Shapes With clip-path: polygon(): Point-Matched Transitions",{"path":1661,"title":1662},"\u002Fcss-only-micro-interactions-animations\u002Fcolor-and-theme-transitions\u002Fanimating-gradients","Animating CSS Gradients: Smooth Colour Motion Without Jumps",{"path":1664,"title":1665},"\u002Fcss-only-micro-interactions-animations\u002Fcolor-and-theme-transitions\u002Fcolor-mix-hover-states","Hover and Active States With color-mix(): One Token, Every Shade",{"path":1667,"title":1668},"\u002Fcss-only-micro-interactions-animations\u002Fcolor-and-theme-transitions","Color & Theme Transitions: Colour as Part of the Motion System",{"path":1670,"title":1671},"\u002Fcss-only-micro-interactions-animations\u002Fcolor-and-theme-transitions\u002Flight-dark-function-for-themes","Light and Dark Themes With light-dark(): One Declaration per Colour",{"path":1673,"title":1674},"\u002Fcss-only-micro-interactions-animations\u002Fcolor-and-theme-transitions\u002Fsmooth-theme-switching-transitions","Smooth Theme Switching: Crossfades, Circular Reveals and No Flash",{"path":1676,"title":1677},"\u002Fcss-only-micro-interactions-animations\u002Fcontainer-aware-motion\u002Fcontainer-query-hover-affordances","Container Query Hover Affordances: When Narrow Means Persistent, Not Hidden",{"path":1679,"title":1680},"\u002Fcss-only-micro-interactions-animations\u002Fcontainer-aware-motion","Container-Aware Motion: Animation Sized by the Space a Component Actually Has",{"path":1682,"title":1683},"\u002Fcss-only-micro-interactions-animations\u002Fcontainer-aware-motion\u002Flayout-change-animations-at-container-breakpoints","Animating Changes at Container Breakpoints",{"path":1685,"title":1686},"\u002Fcss-only-micro-interactions-animations\u002Fcontainer-aware-motion\u002Fmotion-driven-by-container-style-queries","Motion Driven by Container Style Queries",{"path":1688,"title":1689},"\u002Fcss-only-micro-interactions-animations\u002Fcontainer-aware-motion\u002Fmotion-that-scales-with-container-size","Motion That Scales with Container Size: cqi, cqb, and Derived Durations",{"path":1691,"title":1692},"\u002Fcss-only-micro-interactions-animations\u002Fcontainer-aware-motion\u002Fsuppressing-motion-in-small-containers","Suppressing Motion in Small Containers: Deliberately Animating Nothing",{"path":1694,"title":1695},"\u002Fcss-only-micro-interactions-animations\u002Fcss-animation-vs-web-animations-api\u002Fcontrolling-css-animations-from-javascript","Controlling CSS Animations From JavaScript",{"path":1697,"title":1698},"\u002Fcss-only-micro-interactions-animations\u002Fcss-animation-vs-web-animations-api","CSS Animation vs the Web Animations API: A Decision Guide",{"path":1700,"title":1701},"\u002Fcss-only-micro-interactions-animations\u002Fcss-animation-vs-web-animations-api\u002Fwaapi-vs-css-for-interruptible-ui","Interruptible UI: CSS Transitions vs WAAPI",{"path":1703,"title":1704},"\u002Fcss-only-micro-interactions-animations\u002Fcss-animation-vs-web-animations-api\u002Fwhen-to-use-javascript-animation","When to Use JavaScript Instead of CSS for Animation",{"path":1706,"title":1707},"\u002Fcss-only-micro-interactions-animations\u002Fcss-custom-properties-architecture\u002Fanimating-custom-properties-with-at-property","Animating Custom Properties with @property: Typed Variables That Interpolate",{"path":1709,"title":1710},"\u002Fcss-only-micro-interactions-animations\u002Fcss-custom-properties-architecture\u002Fcustom-property-fallbacks-and-invalid-values","Custom Property Fallbacks and Invalid Values",{"path":1712,"title":1713},"\u002Fcss-only-micro-interactions-animations\u002Fcss-custom-properties-architecture\u002Ffluid-spacing-tokens-driving-transition-durations","Fluid Spacing Tokens That Drive Transition Durations",{"path":1715,"title":1716},"\u002Fcss-only-micro-interactions-animations\u002Fcss-custom-properties-architecture","CSS Custom Properties Architecture: Scalable Design Systems & Dynamic UI",{"path":1718,"title":1719},"\u002Fcss-only-micro-interactions-animations\u002Fcss-custom-properties-architecture\u002Fregistered-properties-and-type-safety","Registered Properties and Type Safety: @property as a Contract for Design Tokens",{"path":1721,"title":1722},"\u002Fcss-only-micro-interactions-animations\u002Fcss-custom-properties-architecture\u002Fscoping-custom-properties-to-components","Scoping Custom Properties to Components",{"path":1724,"title":1725},"\u002Fcss-only-micro-interactions-animations\u002Fcss-transition-fundamentals\u002Fcss-transition-timing-functions","CSS Transition Timing Functions: ease, cubic-bezier(), steps() and linear()",{"path":1727,"title":1728},"\u002Fcss-only-micro-interactions-animations\u002Fcss-transition-fundamentals","CSS Transition Fundamentals: Architecture, Performance & Patterns",{"path":1730,"title":1731},"\u002Fcss-only-micro-interactions-animations\u002Fcss-transition-fundamentals\u002Finterrupted-and-reversing-transitions","Interrupted and Reversing Transitions: What Happens Mid-Flight",{"path":1733,"title":1734},"\u002Fcss-only-micro-interactions-animations\u002Fcss-transition-fundamentals\u002Fstarting-style-entry-animations","@starting-style: Animating an Element's Very First Style Change",{"path":1736,"title":1737},"\u002Fcss-only-micro-interactions-animations\u002Fcss-transition-fundamentals\u002Ftransition-delay-choreography","Choreographing Motion With transition-delay",{"path":1739,"title":1740},"\u002Fcss-only-micro-interactions-animations\u002Fcss-transition-fundamentals\u002Ftransition-shorthand-and-multiple-properties","The transition Shorthand and Multiple Properties",{"path":1742,"title":1743},"\u002Fcss-only-micro-interactions-animations\u002Fcss-transition-fundamentals\u002Ftransitioning-display-with-allow-discrete","Transitioning display with transition-behavior: allow-discrete and @starting-style",{"path":1745,"title":1746},"\u002Fcss-only-micro-interactions-animations\u002Fdialog-and-popover-animations\u002Fanimating-dialog-open-and-close","Animating \u003Cdialog> Open and Close: Both Directions, No Library",{"path":1748,"title":1749},"\u002Fcss-only-micro-interactions-animations\u002Fdialog-and-popover-animations\u002Fbackdrop-animations","Animating ::backdrop: Fades and Blurs Behind Dialogs and Popovers",{"path":1751,"title":1752},"\u002Fcss-only-micro-interactions-animations\u002Fdialog-and-popover-animations","Dialog & Popover Animations: Motion for the Top Layer",{"path":1754,"title":1755},"\u002Fcss-only-micro-interactions-animations\u002Fdialog-and-popover-animations\u002Finterpolate-size-for-height-auto-animation","Animating to height: auto With interpolate-size and calc-size()",{"path":1757,"title":1758},"\u002Fcss-only-micro-interactions-animations\u002Fdialog-and-popover-animations\u002Fpopover-entry-and-exit-transitions","Popover Menus That Animate From Their Anchor",{"path":1760,"title":1761},"\u002Fcss-only-micro-interactions-animations\u002Feasing-and-motion-design\u002Fchoosing-animation-durations","Choosing Animation Durations: How Long Motion Should Last",{"path":1763,"title":1764},"\u002Fcss-only-micro-interactions-animations\u002Feasing-and-motion-design\u002Fcubic-bezier-overshoot-and-anticipation","Overshoot and Anticipation With cubic-bezier(): Motion With Character",{"path":1766,"title":1767},"\u002Fcss-only-micro-interactions-animations\u002Feasing-and-motion-design\u002Fentry-vs-exit-easing","Entry vs Exit Easing: Different Curves for Arriving and Leaving",{"path":1769,"title":1770},"\u002Fcss-only-micro-interactions-animations\u002Feasing-and-motion-design","Easing & Motion Design: Making CSS Motion Feel Intentional",{"path":1772,"title":1773},"\u002Fcss-only-micro-interactions-animations\u002Feasing-and-motion-design\u002Flinear-easing-function-for-springs","Spring and Bounce Easing With linear(): Physical Motion Without JavaScript",{"path":1775,"title":1776},"\u002Fcss-only-micro-interactions-animations\u002Feasing-and-motion-design\u002Fsteps-easing-for-sprite-animations","steps() Easing: Sprite Sheets, Typewriters and Other Frame-by-Frame Effects",{"path":1778,"title":1779},"\u002Fcss-only-micro-interactions-animations\u002Fhover-focus-state-design\u002Faccessible-css-only-tooltips","Accessible CSS-Only Tooltips and Hover Cards With  and ",{"path":1781,"title":1782},"\u002Fcss-only-micro-interactions-animations\u002Fhover-focus-state-design\u002Fbutton-press-and-active-states","Button Press and  States",{"path":1784,"title":1785},"\u002Fcss-only-micro-interactions-animations\u002Fhover-focus-state-design\u002Ffocus-visible-vs-focus-polyfill-alternatives"," vs :focus: Why It Replaced the Focus-Ring Polyfill",{"path":1787,"title":1788},"\u002Fcss-only-micro-interactions-animations\u002Fhover-focus-state-design\u002Ffocus-within-form-patterns"," Form Patterns: Styling a Group From the Field Inside It",{"path":1790,"title":1791},"\u002Fcss-only-micro-interactions-animations\u002Fhover-focus-state-design\u002Fhover-intent-delays-with-transition-delay","Hover Intent Delays With transition-delay: Menus That Don't Flicker",{"path":1793,"title":1794},"\u002Fcss-only-micro-interactions-animations\u002Fhover-focus-state-design","Hover & Focus State Design: Spec-Compliant Patterns for Modern UIs",{"path":1796,"title":1797},"\u002Fcss-only-micro-interactions-animations\u002Fhover-focus-state-design\u002Fpointer-and-hover-media-queries","Pointer and Hover Media Queries: Gating Affordances by Input Capability",{"path":1799,"title":1800},"\u002Fcss-only-micro-interactions-animations\u002Fhover-focus-state-design\u002Fsmooth-hover-effects-without-javascript","Smooth Hover Effects Without JavaScript: CSS-Only Patterns for Modern UI",{"path":1802,"title":1803},"\u002Fcss-only-micro-interactions-animations","CSS-Only Micro-Interactions & Animations: Architecture, Performance & Implementation",{"path":1805,"title":1806},"\u002Fcss-only-micro-interactions-animations\u002Fkeyframe-animation-patterns\u002Fanimation-composition-and-stacking","Stacking Animations With animation-composition",{"path":1808,"title":1809},"\u002Fcss-only-micro-interactions-animations\u002Fkeyframe-animation-patterns\u002Fanimation-fill-mode-explained","animation-fill-mode: What an Animation Applies Before and After It Runs",{"path":1811,"title":1812},"\u002Fcss-only-micro-interactions-animations\u002Fkeyframe-animation-patterns\u002Fcontainer-query-triggered-keyframe-animations","Container-Query-Triggered Keyframe Animations: Animate Differently per Available Space",{"path":1814,"title":1815},"\u002Fcss-only-micro-interactions-animations\u002Fkeyframe-animation-patterns\u002Fcss-only-accordions-and-disclosure","CSS-Only Accordions and Disclosure Widgets with details and summary",{"path":1817,"title":1818},"\u002Fcss-only-micro-interactions-animations\u002Fkeyframe-animation-patterns\u002Fcss-only-loading-spinners-and-skeletons","CSS-Only Loading Spinners and Skeleton Shimmer Screens with @keyframes",{"path":1820,"title":1821},"\u002Fcss-only-micro-interactions-animations\u002Fkeyframe-animation-patterns\u002Fcss-only-toggle-switches-and-checkboxes","CSS-Only Toggle Switches and Checkboxes That Keep the Native Input",{"path":1823,"title":1824},"\u002Fcss-only-micro-interactions-animations\u002Fkeyframe-animation-patterns","Keyframe Animation Patterns: Spec-Compliant Architectures for Modern UIs",{"path":1826,"title":1827},"\u002Fcss-only-micro-interactions-animations\u002Fkeyframe-animation-patterns\u002Fmulti-step-keyframes-and-per-keyframe-easing","Multi-Step Keyframes and Per-Keyframe Easing",{"path":1829,"title":1830},"\u002Fcss-only-micro-interactions-animations\u002Fkeyframe-animation-patterns\u002Fstaggered-list-animations-with-custom-properties","Staggered List Animations Using --i Index Custom Properties",{"path":1832,"title":1833},"\u002Fcss-only-micro-interactions-animations\u002Fperformance-gpu-acceleration\u002Fanimating-box-shadow-and-filters-cheaply","Animating box-shadow and Filters Cheaply",{"path":1835,"title":1836},"\u002Fcss-only-micro-interactions-animations\u002Fperformance-gpu-acceleration\u002Fcontain-property-for-animation-performance","The contain Property for Animation Performance",{"path":1838,"title":1839},"\u002Fcss-only-micro-interactions-animations\u002Fperformance-gpu-acceleration\u002Fcss-triggers-layout-paint-composite","Layout, Paint and Composite: What Triggers What",{"path":1841,"title":1842},"\u002Fcss-only-micro-interactions-animations\u002Fperformance-gpu-acceleration","Performance & GPU Acceleration in CSS: A Developer’s Blueprint",{"path":1844,"title":1845},"\u002Fcss-only-micro-interactions-animations\u002Fperformance-gpu-acceleration\u002Foptimizing-css-animations-for-60fps","Optimizing CSS Animations for 60fps: Budgeting the Frame",{"path":1847,"title":1848},"\u002Fcss-only-micro-interactions-animations\u002Fperformance-gpu-acceleration\u002Fprofiling-animations-in-devtools","Profiling CSS Animations in DevTools: Finding the Frame That Costs Too Much",{"path":1850,"title":1851},"\u002Fcss-only-micro-interactions-animations\u002Fperformance-gpu-acceleration\u002Fwill-change-and-the-compositor-thread","will-change and the Compositor Thread: Layer Promotion Without the Footguns",{"path":1853,"title":1854},"\u002Fcss-only-micro-interactions-animations\u002Fscroll-driven-animations","Scroll-Driven Animations: Binding Motion to Scroll Position in Pure CSS",{"path":1856,"title":1857},"\u002Fcss-only-micro-interactions-animations\u002Fscroll-driven-animations\u002Fscroll-driven-animation-fallbacks","Shipping Scroll-Driven Animations Without Breaking Anything",{"path":1859,"title":1860},"\u002Fcss-only-micro-interactions-animations\u002Fscroll-driven-animations\u002Fscroll-driven-parallax-effects","Scroll-Driven Parallax Effects in CSS",{"path":1862,"title":1863},"\u002Fcss-only-micro-interactions-animations\u002Fscroll-driven-animations\u002Fscroll-progress-bar-without-javascript","A Reading Progress Bar Driven by scroll(root)",{"path":1865,"title":1866},"\u002Fcss-only-micro-interactions-animations\u002Fscroll-driven-animations\u002Fscroll-triggered-reveal-animations","Reveal-on-Scroll with view() and animation-range",{"path":1868,"title":1869},"\u002Fcss-only-micro-interactions-animations\u002Fscroll-driven-animations\u002Ftimeline-scope-for-cross-element-animations","timeline-scope for Cross-Element Animations",{"path":1871,"title":1872},"\u002Fcss-only-micro-interactions-animations\u002Fscroll-driven-animations\u002Fview-timeline-and-animation-range","View Timelines and animation-range",{"path":1874,"title":1875},"\u002Fcss-only-micro-interactions-animations\u002Fview-transitions-for-css-developers\u002Fcross-document-view-transitions","Cross-Document View Transitions",{"path":1877,"title":1878},"\u002Fcss-only-micro-interactions-animations\u002Fview-transitions-for-css-developers","View Transitions for CSS Developers: the Pseudo-Element Tree, Snapshots, and Named Elements",{"path":1880,"title":1881},"\u002Fcss-only-micro-interactions-animations\u002Fview-transitions-for-css-developers\u002Fsame-document-view-transitions","Writing a Same-Document View Transition: the CSS You Actually Author",{"path":1883,"title":1884},"\u002Fcss-only-micro-interactions-animations\u002Fview-transitions-for-css-developers\u002Fview-transition-names-shared-elements","view-transition-name and Shared Elements: Morphing a Thumbnail into a Hero",{"path":1886,"title":1887},"\u002Fcss-only-micro-interactions-animations\u002Fview-transitions-for-css-developers\u002Fview-transition-types-and-classes","View Transition Types and Classes",{"path":1889,"title":1890},"\u002Fcss-only-micro-interactions-animations\u002Fview-transitions-for-css-developers\u002Fview-transitions-for-list-reordering","View Transitions for List Reordering",{"path":1892,"title":1893},"\u002Fcss-only-micro-interactions-animations\u002Fview-transitions-for-css-developers\u002Fview-transitions-with-reduced-motion","Honouring prefers-reduced-motion in View Transitions",{"path":403,"title":1895},"Modern CSS Layouts & Micro-Interactions",{"path":1897,"title":1898},"\u002Fmastering-container-queries-responsive-layouts\u002Fanchor-positioning-and-overlays\u002Fanchor-positioned-tooltips","Anchor-Positioned Tooltips: Tethering, Flipping, and Getting the Semantics Right",{"path":1900,"title":1901},"\u002Fmastering-container-queries-responsive-layouts\u002Fanchor-positioning-and-overlays\u002Fanchor-positioning-fallbacks","Anchor Positioning Fallbacks: A Graceful Floor for Older Browser Versions",{"path":1903,"title":1904},"\u002Fmastering-container-queries-responsive-layouts\u002Fanchor-positioning-and-overlays\u002Fanchor-size-for-matching-widths","anchor-size(): Overlays That Match Their Trigger's Size",{"path":1906,"title":1907},"\u002Fmastering-container-queries-responsive-layouts\u002Fanchor-positioning-and-overlays","CSS Anchor Positioning and Overlays: Tethering Elements Without JavaScript",{"path":1909,"title":1910},"\u002Fmastering-container-queries-responsive-layouts\u002Fanchor-positioning-and-overlays\u002Fpopover-attribute-and-css-styling","The popover Attribute: Top-Layer Overlays With No JavaScript",{"path":1912,"title":1913},"\u002Fmastering-container-queries-responsive-layouts\u002Fanchor-positioning-and-overlays\u002Fpopover-light-dismiss-and-stacking","Popover Light Dismiss, Nesting and Stacking",{"path":1915,"title":1916},"\u002Fmastering-container-queries-responsive-layouts\u002Fanchor-positioning-and-overlays\u002Fposition-area-grid-explained","position-area: The Anchor Placement Grid",{"path":1918,"title":1919},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-fallbacks\u002Fcontainer-query-polyfill-tradeoffs","Container Query Polyfills: What They Cost and When to Skip Them",{"path":1921,"title":1922},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-fallbacks\u002Ffeature-detection-with-supports","Feature Detection with @supports: Syntax, Semantics, and the Traps",{"path":1924,"title":1925},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-fallbacks\u002Fhandling-container-query-fallbacks-for-older-browsers","Handling Container Query Fallbacks for Older Browsers",{"path":1927,"title":1928},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-fallbacks","Container Query Fallbacks: Spec-Compliant CSS Strategies for Legacy Browsers",{"path":1930,"title":1931},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-fallbacks\u002Fintrinsic-layout-fallbacks-without-queries","Intrinsic Layout Fallbacks: Baselines That Adapt Without Any Query",{"path":1933,"title":1934},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-fallbacks\u002Ftesting-fallbacks-without-old-browsers","Testing CSS Fallbacks Without an Old Browser",{"path":1936,"title":1937},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-syntax-basics\u002Fcontainer-queries-inside-css-nesting","Container Queries Inside CSS Nesting: Keeping Responses Next to the Styles They Change",{"path":1939,"title":1940},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-syntax-basics\u002Fcontainer-query-range-and-logic-operators","Container Query Range Syntax and Logic Operators",{"path":1942,"title":1943},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-syntax-basics\u002Fcontainer-query-units-cqi-cqb-explained","Container Query Units Explained: cqi, cqb, cqw, cqh, cqmin and cqmax",{"path":1945,"title":1946},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-syntax-basics\u002Fcontainer-type-size-vs-inline-size","Choosing container-type: inline-size, size, or normal",{"path":1948,"title":1949},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-syntax-basics\u002Fcontainer-vs-media-queries-comparison","Container vs Media Queries: Choosing the Right Reference Box",{"path":1951,"title":1952},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-syntax-basics\u002Fdebugging-container-queries-in-devtools","Debugging Container Queries in DevTools: Why a Rule Doesn't Match",{"path":1954,"title":1955},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-syntax-basics\u002Fhow-to-use-container-queries-in-production","How to Use Container Queries in Production Without a Rewrite",{"path":1957,"title":1958},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-syntax-basics","Container Query Syntax Basics",{"path":1960,"title":1961},"\u002Fmastering-container-queries-responsive-layouts\u002Fcontainer-query-syntax-basics\u002Fnesting-and-naming-container-queries","Nesting and Naming Container Queries: Targeting the Right Ancestor",{"path":1963,"title":1964},"\u002Fmastering-container-queries-responsive-layouts\u002Fcss-grid-and-subgrid-layouts\u002Fauto-fit-minmax-responsive-grids","Responsive Grids with repeat(auto-fit, minmax())",{"path":1966,"title":1967},"\u002Fmastering-container-queries-responsive-layouts\u002Fcss-grid-and-subgrid-layouts\u002Fbuilding-a-dashboard-with-subgrid","Building a Responsive Dashboard Where Cards Align with Subgrid",{"path":1969,"title":1970},"\u002Fmastering-container-queries-responsive-layouts\u002Fcss-grid-and-subgrid-layouts\u002Fgrid-auto-flow-dense-packing","grid-auto-flow: dense for Packed Layouts",{"path":1972,"title":1973},"\u002Fmastering-container-queries-responsive-layouts\u002Fcss-grid-and-subgrid-layouts\u002Fgrid-template-areas-responsive-layouts","Responsive Layouts With grid-template-areas: Rearranging Regions by Name",{"path":1975,"title":1976},"\u002Fmastering-container-queries-responsive-layouts\u002Fcss-grid-and-subgrid-layouts\u002Fholy-grail-layout-with-grid","The Holy-Grail Layout with CSS Grid and Container Queries",{"path":1978,"title":1979},"\u002Fmastering-container-queries-responsive-layouts\u002Fcss-grid-and-subgrid-layouts","CSS Grid and Subgrid Layouts for Responsive Interfaces",{"path":1981,"title":1982},"\u002Fmastering-container-queries-responsive-layouts\u002Fcss-grid-and-subgrid-layouts\u002Fmasonry-style-layouts-with-grid","Masonry-Style Layouts With the CSS That Ships Today",{"path":1984,"title":1985},"\u002Fmastering-container-queries-responsive-layouts\u002Fcss-grid-and-subgrid-layouts\u002Foverlapping-elements-with-grid-stacking","Overlapping Elements With Grid Stacking: Layers Without position: absolute",{"path":1987,"title":1988},"\u002Fmastering-container-queries-responsive-layouts\u002Fcss-grid-and-subgrid-layouts\u002Fsubgrid-vs-nested-grid","Subgrid vs an Independently Nested Grid",{"path":1990,"title":1991},"\u002Fmastering-container-queries-responsive-layouts\u002Fflexbox-layout-patterns\u002Fcentering-in-css-every-method","Centering in CSS: Every Modern Method and When Each One Breaks",{"path":1993,"title":1994},"\u002Fmastering-container-queries-responsive-layouts\u002Fflexbox-layout-patterns\u002Fflex-basis-vs-width","flex-basis vs width: Which Size a Flex Item Actually Starts From",{"path":1996,"title":1997},"\u002Fmastering-container-queries-responsive-layouts\u002Fflexbox-layout-patterns\u002Fflex-grow-and-flex-shrink-explained","flex-grow and flex-shrink Explained",{"path":1999,"title":2000},"\u002Fmastering-container-queries-responsive-layouts\u002Fflexbox-layout-patterns\u002Fflex-wrap-intrinsic-responsive-rows","Breakpoint-Free Responsive Rows With flex-wrap and flex-basis",{"path":2002,"title":2003},"\u002Fmastering-container-queries-responsive-layouts\u002Fflexbox-layout-patterns\u002Fflexbox-gap-and-spacing","Flexbox gap vs Margins: Spacing Items Without Edge Hacks",{"path":2005,"title":2006},"\u002Fmastering-container-queries-responsive-layouts\u002Fflexbox-layout-patterns","Flexbox Layout Patterns: One-Dimensional Layout for Real Components",{"path":2008,"title":2009},"\u002Fmastering-container-queries-responsive-layouts\u002Fflexbox-layout-patterns\u002Fsticky-footer-with-flexbox-and-grid","Sticky Footer With Flexbox or Grid: Pinning the Footer on Short Pages",{"path":2011,"title":2012},"\u002Fmastering-container-queries-responsive-layouts\u002Ffluid-typography-with-clamp\u002Fclamp-vs-media-query-typography","clamp() Fluid Type vs Media-Query Step Typography: Tradeoffs and Anatomy",{"path":2014,"title":2015},"\u002Fmastering-container-queries-responsive-layouts\u002Ffluid-typography-with-clamp\u002Fdebugging-clamp-values","Debugging clamp(): Values That Are Ignored, Stuck or Never Fluid",{"path":2017,"title":2018},"\u002Fmastering-container-queries-responsive-layouts\u002Ffluid-typography-with-clamp\u002Ffluid-line-height-and-measure","Fluid Line Height and Measure: Keeping Text Readable as It Scales",{"path":2020,"title":2021},"\u002Fmastering-container-queries-responsive-layouts\u002Ffluid-typography-with-clamp\u002Ffluid-space-scale-with-clamp","Building a Fluid Spacing Scale with clamp() and Container Units",{"path":2023,"title":2024},"\u002Fmastering-container-queries-responsive-layouts\u002Ffluid-typography-with-clamp\u002Ffluid-type-accessibility-and-zoom","Fluid Type, Accessibility and Zoom: The vw-Only Trap",{"path":2026,"title":2027},"\u002Fmastering-container-queries-responsive-layouts\u002Ffluid-typography-with-clamp\u002Ffluid-typography-without-javascript","Fluid Typography Without JavaScript: A Precision CSS Reference",{"path":2029,"title":2030},"\u002Fmastering-container-queries-responsive-layouts\u002Ffluid-typography-with-clamp","Fluid Typography with clamp(): A Practical Guide for Modern CSS",{"path":2032,"title":2033},"\u002Fmastering-container-queries-responsive-layouts\u002Ffluid-typography-with-clamp\u002Ftext-wrap-balance-and-pretty","text-wrap: balance and pretty: Better Line Breaks Without Manual Breaks",{"path":2035,"title":2036},"\u002Fmastering-container-queries-responsive-layouts","Mastering Container Queries & Responsive Layouts",{"path":2038,"title":2039},"\u002Fmastering-container-queries-responsive-layouts\u002Fintrinsic-sizing-techniques\u002Faspect-ratio-for-responsive-media","Using aspect-ratio for Responsive Media and Preventing Layout Shift",{"path":2041,"title":2042},"\u002Fmastering-container-queries-responsive-layouts\u002Fintrinsic-sizing-techniques\u002Fcontent-visibility-and-contain-intrinsic-size","content-visibility and contain-intrinsic-size: Rendering Only What Is Near the Screen",{"path":2044,"title":2045},"\u002Fmastering-container-queries-responsive-layouts\u002Fintrinsic-sizing-techniques","Intrinsic Sizing Techniques: Modern CSS Layouts for Responsive UI",{"path":2047,"title":2048},"\u002Fmastering-container-queries-responsive-layouts\u002Fintrinsic-sizing-techniques\u002Flayout-widths-with-min-max-clamp","Layout Widths With min(), max() and clamp(): Sizing Without Breakpoints",{"path":2050,"title":2051},"\u002Fmastering-container-queries-responsive-layouts\u002Fintrinsic-sizing-techniques\u002Fmin-max-fit-content-explained","min-content, max-content, and fit-content() Explained",{"path":2053,"title":2054},"\u002Fmastering-container-queries-responsive-layouts\u002Fintrinsic-sizing-techniques\u002Fobject-fit-and-object-position","object-fit and object-position: Images That Fit Any Box",{"path":2056,"title":2057},"\u002Fmastering-container-queries-responsive-layouts\u002Fintrinsic-sizing-techniques\u002Fpreventing-flex-and-grid-overflow","The min-width: auto Trap in Flex and Grid Layouts",{"path":2059,"title":2060},"\u002Fmastering-container-queries-responsive-layouts\u002Fmodern-css-reset-strategies\u002Fcascade-layers-for-reset-and-tokens","Cascade Layers for Reset and Design Tokens",{"path":2062,"title":2063},"\u002Fmastering-container-queries-responsive-layouts\u002Fmodern-css-reset-strategies\u002Fcascade-layers-vs-specificity-hacks","Cascade Layers vs Specificity Hacks: Ordering Instead of Escalating",{"path":2065,"title":2066},"\u002Fmastering-container-queries-responsive-layouts\u002Fmodern-css-reset-strategies\u002Fcss-scope-for-component-styles","@scope for Component Styles: Short Selectors That Cannot Leak",{"path":2068,"title":2069},"\u002Fmastering-container-queries-responsive-layouts\u002Fmodern-css-reset-strategies","Modern CSS Reset Strategies: A Spec-Compliant Foundation",{"path":2071,"title":2072},"\u002Fmastering-container-queries-responsive-layouts\u002Fmodern-css-reset-strategies\u002Frevert-layer-and-revert-keywords","initial, inherit, unset, revert and revert-layer: Undoing Styles Correctly",{"path":2074,"title":2075},"\u002Fmastering-container-queries-responsive-layouts\u002Fmodern-css-reset-strategies\u002Fwriting-a-minimal-modern-reset","Writing a Minimal Modern CSS Reset: Every Line Justified",{"path":2077,"title":2078},"\u002Fmastering-container-queries-responsive-layouts\u002Fparent-aware-layouts-with-has\u002Fcontent-aware-card-layouts-with-has","Content-Aware Card Layouts With :has(): One Component, Many Shapes",{"path":2080,"title":2081},"\u002Fmastering-container-queries-responsive-layouts\u002Fparent-aware-layouts-with-has\u002Fempty-and-loading-states-with-has","Empty and Loading States With ()",{"path":2083,"title":2084},"\u002Fmastering-container-queries-responsive-layouts\u002Fparent-aware-layouts-with-has\u002Fform-validation-layouts-with-has","Form Validation Layouts With :has(): Styling Groups From Field State",{"path":2086,"title":2087},"\u002Fmastering-container-queries-responsive-layouts\u002Fparent-aware-layouts-with-has\u002Fhas-selector-performance",":has() Selector Performance: What Is Cheap, What Is Not, and How to Measure",{"path":2089,"title":2090},"\u002Fmastering-container-queries-responsive-layouts\u002Fparent-aware-layouts-with-has\u002Fhas-vs-container-style-queries",":has() vs Container Style Queries: Discovered State and Published State",{"path":2092,"title":2093},"\u002Fmastering-container-queries-responsive-layouts\u002Fparent-aware-layouts-with-has","Parent-Aware Layouts With :has(): Letting Containers React to Their Contents",{"path":2095,"title":2096},"\u002Fmastering-container-queries-responsive-layouts\u002Fparent-aware-layouts-with-has\u002Fquantity-queries-with-has","Quantity Queries With :has(): Layouts That Respond to How Many Items There Are",{"path":2098,"title":2099},"\u002Fmastering-container-queries-responsive-layouts\u002Fresponsive-component-patterns\u002Fbuilding-responsive-cards-with-container-queries","Building Responsive Cards with Container Queries: A Production-Ready Guide",{"path":2101,"title":2102},"\u002Fmastering-container-queries-responsive-layouts\u002Fresponsive-component-patterns\u002Fcontainer-query-data-tables","Container Query Data Tables: Reflowing Tables to Cards",{"path":2104,"title":2105},"\u002Fmastering-container-queries-responsive-layouts\u002Fresponsive-component-patterns\u002Fcontainer-query-sidebar-layouts","Container Query Sidebar Layouts That Travel Between Contexts",{"path":2107,"title":2108},"\u002Fmastering-container-queries-responsive-layouts\u002Fresponsive-component-patterns","Responsive Component Patterns: Architecture & Implementation",{"path":2110,"title":2111},"\u002Fmastering-container-queries-responsive-layouts\u002Fresponsive-component-patterns\u002Fresponsive-forms-with-container-queries","Responsive Forms with Container Queries: Reflow Without Losing the Wiring",{"path":2113,"title":2114},"\u002Fmastering-container-queries-responsive-layouts\u002Fresponsive-component-patterns\u002Fresponsive-hero-sections-with-container-queries","Responsive Hero Sections With Container Queries",{"path":2116,"title":2117},"\u002Fmastering-container-queries-responsive-layouts\u002Fresponsive-component-patterns\u002Fresponsive-navigation-without-media-queries","Responsive Navigation Without Media Queries Using Container Queries",{"path":2119,"title":2120},"\u002Fmastering-container-queries-responsive-layouts\u002Fresponsive-component-patterns\u002Fresponsive-pricing-tables","Responsive Pricing Tables: Aligned Features, a Clear Recommendation, Any Width",{"path":2122,"title":2123},"\u002Fmastering-container-queries-responsive-layouts\u002Fresponsive-component-patterns\u002Ftabs-that-become-accordions","Tabs That Become an Accordion: One Component, Two Layouts",{"path":2125,"title":2126},"\u002Fmastering-container-queries-responsive-layouts\u002Fscroll-snap-and-overflow-layouts\u002Fcss-only-carousel-with-scroll-snap","A CSS-Only Carousel With Scroll Snap",{"path":2128,"title":2129},"\u002Fmastering-container-queries-responsive-layouts\u002Fscroll-snap-and-overflow-layouts\u002Fhorizontal-scrolling-card-rows","Horizontal Scrolling Card Rows: Swipeable Lists That Stay in Their Lane",{"path":2131,"title":2132},"\u002Fmastering-container-queries-responsive-layouts\u002Fscroll-snap-and-overflow-layouts","Scroll Snap & Overflow Layouts: Designing Components That Scroll on Purpose",{"path":2134,"title":2135},"\u002Fmastering-container-queries-responsive-layouts\u002Fscroll-snap-and-overflow-layouts\u002Foverscroll-behavior-for-nested-scrolling","overscroll-behavior: Taming Nested Scrolling, Pull-to-Refresh and Back-Swipe",{"path":2137,"title":2138},"\u002Fmastering-container-queries-responsive-layouts\u002Fscroll-snap-and-overflow-layouts\u002Fscroll-margin-and-scroll-padding-for-sticky-headers","scroll-margin and scroll-padding: Keeping Targets Clear of Sticky Headers",{"path":2140,"title":2141},"\u002Fmastering-container-queries-responsive-layouts\u002Fstyle-queries-and-container-state\u002Fcombining-size-and-style-queries","Combining Size and Style Container Queries",{"path":2143,"title":2144},"\u002Fmastering-container-queries-responsive-layouts\u002Fstyle-queries-and-container-state\u002Fcontainer-style-query-theming","Container Style Query Theming: One Token Instead of a Variant Class Matrix",{"path":2146,"title":2147},"\u002Fmastering-container-queries-responsive-layouts\u002Fstyle-queries-and-container-state","Style Queries and Container State: Token-Driven Component Variants",{"path":2149,"title":2150},"\u002Fmastering-container-queries-responsive-layouts\u002Fstyle-queries-and-container-state\u002Fstyle-queries-with-custom-properties","Style Queries With Custom Properties: Declaring, Inheriting, and Matching Tokens",{"path":2152,"title":2153},"\u002Fmastering-container-queries-responsive-layouts\u002Fstyle-queries-and-container-state\u002Fstyle-query-component-variants","Component Variants With Style Queries: One Token, Many Looks",{"path":2155,"title":2156},"\u002Fmastering-container-queries-responsive-layouts\u002Fstyle-queries-and-container-state\u002Fstyle-query-fallbacks-and-support","Style Query Fallbacks and Support: Designing for Older Browser Versions",{"path":2158,"title":2159},"\u002Fmastering-container-queries-responsive-layouts\u002Fviewport-units-and-mobile-layout\u002Fdvh-svh-lvh-mobile-viewport-units","dvh, svh and lvh: Choosing the Right Mobile Viewport Unit",{"path":2161,"title":2162},"\u002Fmastering-container-queries-responsive-layouts\u002Fviewport-units-and-mobile-layout\u002Ffull-bleed-sections-in-constrained-layouts","Full-Bleed Sections in a Constrained Layout: Breaking Out Without Breaking the Page",{"path":2164,"title":2165},"\u002Fmastering-container-queries-responsive-layouts\u002Fviewport-units-and-mobile-layout","Viewport Units & Mobile Layout: Designing for the Screen You Actually Get",{"path":2167,"title":2168},"\u002Fmastering-container-queries-responsive-layouts\u002Fviewport-units-and-mobile-layout\u002Fsafe-area-insets-for-notched-screens","Safe Area Insets: Designing Around Notches, Corners and Home Indicators",{"path":2170,"title":2171},"\u002Fmastering-container-queries-responsive-layouts\u002Fviewport-units-and-mobile-layout\u002Fviewport-units-vs-container-units","Viewport Units vs Container Units: Choosing the Right Reference Box",{"path":2173,"title":2174},"\u002Fmastering-container-queries-responsive-layouts\u002Fviewport-units-and-mobile-layout\u002Fvirtual-keyboard-and-interactive-widget","Layouts That Survive the Virtual Keyboard",{"title":2176,"caption":2177,"height":2178,"html":2179,"css":2180},"State indicators with forced-colors fallbacks","Tab to an option to see the shadow focus ring. With forced colors emulated (DevTools Rendering panel), the transparent outline appears instead, the selected option gains a double border and the shimmer becomes a bordered pulse.",220,"\n\u003Cdiv class=\"wrap\">\n  \u003Cbutton class=\"option\" type=\"button\" aria-pressed=\"true\">Monthly billing\u003C\u002Fbutton>\n  \u003Cbutton class=\"option\" type=\"button\" aria-pressed=\"false\">Annual billing\u003C\u002Fbutton>\n  \u003Cdiv class=\"skeleton\" role=\"status\" aria-label=\"Loading\">\u003C\u002Fdiv>\n\u003C\u002Fdiv>","\n.wrap { display: grid; gap: 1rem; max-inline-size: 26rem; padding: 1rem; }\n.option { font: inherit; text-align: start; padding: 0.75rem 1rem; border: 2px solid var(--demo-border); border-radius: 10px; background: var(--demo-surface); color: var(--demo-fg); transition: box-shadow 150ms ease-out, border-color 150ms ease-out; cursor: pointer; }\n.option:focus-visible { box-shadow: 0 0 0 4px color-mix(in srgb, var(--demo-accent) 40%, transparent); outline: 2px solid transparent; outline-offset: 2px; }\n.option[aria-pressed=\"true\"] { border-color: var(--demo-accent); background: color-mix(in srgb, var(--demo-accent) 12%, var(--demo-surface)); }\n.skeleton { block-size: 1rem; border-radius: 4px; background: linear-gradient(90deg, var(--demo-border) 25%, var(--demo-surface) 50%, var(--demo-border) 75%) 0 0 \u002F 200% 100%; animation: shimmer 1.4s linear infinite; }\n@keyframes shimmer { to { background-position: -200% 0; } }\n@media (forced-colors: active) {\n  .option[aria-pressed=\"true\"] { border-style: double; border-width: 4px; }\n  .skeleton { border: 1px solid CanvasText; animation: pulse 1.4s ease-in-out infinite alternate; }\n  @keyframes pulse { from { opacity: 1; } to { opacity: 0.4; } }\n}\n@media (prefers-reduced-motion: reduce) { .skeleton { animation: none; } }",1789717746765]