thecodezone.
The Code Zone
Short steps, at your pace · Free lessons and practice · Member video walkthroughs
Save your next small win.

Checking your account…

Responsive Web Design freeCodeCamp companion

Responsive Web Design / CSS / The Box Model

Design a Rothko PaintingBuild an abstract composition one box at a time.

Watch Rob build the project, understand what each part is for, then work through the official freeCodeCamp workshop at your own pace.

44 official steps52:22 walkthroughBeginner · Workshop · CSS

2 recordings, one workshop. Switch parts here without scrolling past several players.

ORIGINAL WALKTHROUGH · 24:29

Watch with Rob.

Pause whenever you want to try a change. You can return to the lesson at any time.

LEARN WITH THE CODE ZONE

Unlock this video walkthrough

Written lessons and coding practice are free. Video walkthroughs are included with a paid Code Zone membership or an active free trial.

Have a Code Zone website account? Use your learning account’s email to get a six-digit sign-in code, or use your existing website password.

Need a website account? Paid Skool members and active trial members can use the email from their membership questions to request a sign-in code. No invite link or Skool password needed.

Close this window to keep practicing. After signing in, you’ll return to this lesson.

Video walkthroughs are included with an active Code Zone membership. The written lesson and practice are free.

Follow the current freeCodeCamp instructions for exact requirements when the recording differs. Guide steps are explanations, not timestamped video chapters.

Finished this walkthrough?

Mark it complete to keep your place in The Code Zone. This does not submit or complete the official freeCodeCamp project.

Next: Build a Confidential Email Page

THE IDEA BEHIND THE BUILD

What this workshop teaches

This workshop uses an abstract composition to make the CSS box model visible. A frame surrounds a canvas, three color fields sit inside it and small changes to spacing and painted edges alter how the whole composition feels.

Separate layout dimensions from visual effects. Padding and borders contribute to the outer box under content-box sizing, margins separate boxes, and percentage dimensions depend on their containing block. Blur, shadows and transforms change the painted result without reserving corresponding extra layout space. Use the exercise to reason about those differences.

01

Read the layers of a box

Distinguish content, padding, border and external margin.

02

Investigate containment

Observe margin collapse and understand the effects of overflow hidden.

03

Separate layout and paint

Compare filters, shadows, radii and transforms with dimensions and spacing.

Cartoon Rob arranges original abstract color fields inside a frame, compares box-model spacing and softens their edges.
The frame, canvas and color fields are separate boxes. Their spacing and painted effects serve different roles.

44 SMALL STEPS · THREE CLEAR GOALS

Your route through the workshop

These groups are a reading guide to the workshop, rather than timestamped chapters of the video.

01Steps 1–14

Understand and frame the canvas

Review box-model diagrams, then establish canvas and frame dimensions.

Check your understanding: You can account for content width, padding, border and margin separately.

Explore step 1
02Steps 15–32

Arrange the color fields

Add three regions, inspect margin behavior and compare fixed with relative dimensions.

Check your understanding: You can identify the reference for each percentage and explain the containment change.

Explore step 15
03Steps 33–44

Soften and tilt the painted edges

Apply filters, matching shadows, corner radii and small rotations.

Check your understanding: You can distinguish visual paint effects from allocated layout space.

Explore step 33

SEE HOW THE PARTS FIT

A page with a clear structure

This original abstract-study rule uses different dimensions, color and rotation. It illustrates the distinction between a box’s geometry and its painted appearance.

example.csscss · example
.study-field {
  width: 260px;
  height: 110px;
  background: #337f91;
  border-radius: 14px 6px;
  transform: rotate(1deg);
}

Three things to pay attention to

Outer size includes more than width

With content-box sizing, padding and borders add to the declared content dimensions.

Overflow hidden has two effects

It creates a block formatting context that changes margin behavior and can also clip overflowing content.

Visual effects do not allocate extra room

A shadow or rotated edge may extend beyond the element without pushing adjacent layout boxes away.

UNDERSTAND IT HERE · PRACTICE IT THERE

Explore each step

Choose a step for a plain-English explanation, a separate code example and resources to explore. When you are ready, its button opens the official freeCodeCamp step. Your official tests and completion stay on freeCodeCamp.

Step 1Inspect the box model diagram

UNDERSTAND THE IDEA

The opening diagram introduces the layers around an element. An image source identifies the visual resource. Inspect what the image actually shows rather than treating a filename as an explanation of the underlying concept.

What you will do

Add the specified first diagram image and identify its content, padding, border and margin.

A separate example to explore
step-1-example.htmlhtml · example
<img src="box-study.png" alt="A diagram showing the content, padding and border of a box">

What to notice: The filename is illustrative and needs a real file to load. A diagram helps explain the model; it is not the completed painting.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 2Locate the content area

UNDERSTAND THE IDEA

The next diagram isolates where content occupies space. An image source identifies the visual resource. Inspect what the image actually shows rather than treating a filename as an explanation of the underlying concept.

What you will do

Update the image source as requested and identify the content box.

A separate example to explore
step-2-example.htmlhtml · example
<img src="box-study.png" alt="A diagram showing the content, padding and border of a box">

What to notice: The filename is illustrative and needs a real file to load. A diagram helps explain the model; it is not the completed painting.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 3Distinguish padding and border

UNDERSTAND THE IDEA

Interior space and a visible boundary are different layers. An image source identifies the visual resource. Inspect what the image actually shows rather than treating a filename as an explanation of the underlying concept.

What you will do

Switch to the requested diagram and compare padding with the border.

A separate example to explore
step-3-example.htmlhtml · example
<img src="box-study.png" alt="A diagram showing the content, padding and border of a box">

What to notice: The filename is illustrative and needs a real file to load. A diagram helps explain the model; it is not the completed painting.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 4Recall the external margin

UNDERSTAND THE IDEA

Margin separates an element from its surroundings. Removing an earlier declaration can reveal an inherited value, another matching rule or a browser default. CSS changes need to be understood in the surrounding cascade.

What you will do

Remove the temporary diagram image after reviewing the external margin layer.

A separate example to explore
step-4-example.csscss · example
.swatch {
  width: 180px;
  /* Color now comes from a variant rule. */
}

What to notice: This snippet retains the geometry while leaving color to another rule. Do not remove unrelated declarations when the task asks for one property.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 5Create the painting canvas

UNDERSTAND THE IDEA

An empty container becomes a visible shape once it has geometry and color. A container groups elements for presentation. A shared class can apply common geometry while another class identifies an individual visual variant.

What you will do

Add the requested canvas div.

A separate example to explore
step-5-example.htmlhtml · example
<div class="swatch-board">
  <div class="swatch warm"></div>
</div>

What to notice: This is a small swatch example with different classes. The container and child are separate boxes with different responsibilities.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 6Connect the painting stylesheet

UNDERSTAND THE IDEA

The visual rules must be loaded by the document. A stylesheet link connects a CSS file to the document. A correct rule in an unlinked file will not affect the page.

What you will do

Add the requested stylesheet link in the head.

A separate example to explore
step-6-example.htmlhtml · example
<link rel="stylesheet" href="swatches.css">

What to notice: Use the actual filename supplied by the workshop. The example file and its rules belong to a different visual study.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 7Set the canvas width

UNDERSTAND THE IDEA

Start with one dimension of the canvas content box. An empty block normally has no content height. Explicit dimensions can make an otherwise invisible colored box visible.

What you will do

Set the requested canvas width.

A separate example to explore
step-7-example.csscss · example
.swatch { width: 180px; height: 30px; }

What to notice: These dimensions differ from the marker and painting tasks. The visible outer size can also include borders and padding.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 8Set the canvas height

UNDERSTAND THE IDEA

An empty div needs a height to show a rectangular surface. A height declaration controls the content box unless another box-sizing rule changes that relationship. Consider the containing box when using percentages.

What you will do

Add the requested canvas height.

A separate example to explore
step-8-example.csscss · example
.study-area { height: 360px; }

What to notice: This separate study area has a different height. The right value depends on the box you are actually styling, not a memorized project answer.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 9Color the canvas surface

UNDERSTAND THE IDEA

The surface will sit behind all three inner color fields. A named CSS color is a predefined value. It is convenient for a simple experiment, but its name does not imply maximum intensity in a particular RGB channel.

What you will do

Set the requested canvas background color.

A separate example to explore
step-9-example.csscss · example
.warm { background-color: coral; }

What to notice: This example uses a different class and color. A color declaration still needs a visible box to show its effect.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 10Wrap the canvas in a frame

UNDERSTAND THE IDEA

A wrapper separates the frame’s border from the canvas itself. A container groups elements for presentation. A shared class can apply common geometry while another class identifies an individual visual variant.

What you will do

Place the canvas inside the requested frame div.

A separate example to explore
step-10-example.htmlhtml · example
<div class="swatch-board">
  <div class="swatch warm"></div>
</div>

What to notice: This is a small swatch example with different classes. The container and child are separate boxes with different responsibilities.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 11Draw the frame boundary

UNDERSTAND THE IDEA

A thick border adds to the outer dimensions under content-box sizing. A visible border needs an appropriate width and style. Its default color is normally currentColor, so setting color explicitly makes the intention clearer.

What you will do

Add the requested solid frame border.

A separate example to explore
step-11-example.csscss · example
.overlay { border-left: 6px solid #173c59; }

What to notice: The width, style and color here are illustrative. A border adds to a content-box element’s outer dimensions.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 12Set the frame’s content width

UNDERSTAND THE IDEA

The frame’s width describes the area inside its padding and border. An empty block normally has no content height. Explicit dimensions can make an otherwise invisible colored box visible.

What you will do

Set the requested frame width and compare it with the canvas width.

A separate example to explore
step-12-example.csscss · example
.swatch { width: 180px; height: 30px; }

What to notice: These dimensions differ from the marker and painting tasks. The visible outer size can also include borders and padding.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 13Add space inside the frame

UNDERSTAND THE IDEA

Padding separates the canvas from the frame’s border. Padding creates space inside a box’s border. With content-box sizing it adds to the declared content width and height.

What you will do

Apply the requested frame padding.

A separate example to explore
step-13-example.csscss · example
.swatch-board { padding: 16px 8px; }

What to notice: These different values show interior space. Compare padding with external margins and include it when reasoning about the outer dimensions.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 14Position the framed composition

UNDERSTAND THE IDEA

External space is independent of the frame’s interior padding. Margins separate a box from its neighbors. Automatic horizontal margins can center a constrained block when spare space is available.

What you will do

Apply the requested frame margins and inspect its centered position.

A separate example to explore
step-14-example.csscss · example
.swatch { margin: 14px auto; }

What to notice: The two-value shorthand sets vertical and horizontal margins. It does not mean all four sides receive the first value.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 15Add the first color field

UNDERSTAND THE IDEA

The first inner box will have its own size and surface. A container groups elements for presentation. A shared class can apply common geometry while another class identifies an individual visual variant.

What you will do

Create the requested first div inside the canvas.

A separate example to explore
step-15-example.htmlhtml · example
<div class="swatch-board">
  <div class="swatch warm"></div>
</div>

What to notice: This is a small swatch example with different classes. The container and child are separate boxes with different responsibilities.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 16Size the first field horizontally

UNDERSTAND THE IDEA

Its width is narrower than the canvas. An empty block normally has no content height. Explicit dimensions can make an otherwise invisible colored box visible.

What you will do

Set the requested first field width.

A separate example to explore
step-16-example.csscss · example
.swatch { width: 180px; height: 30px; }

What to notice: These dimensions differ from the marker and painting tasks. The visible outer size can also include borders and padding.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 17Size the first field vertically

UNDERSTAND THE IDEA

A height makes the empty color field visible. A height declaration controls the content box unless another box-sizing rule changes that relationship. Consider the containing box when using percentages.

What you will do

Add its requested height.

A separate example to explore
step-17-example.csscss · example
.study-area { height: 360px; }

What to notice: This separate study area has a different height. The right value depends on the box you are actually styling, not a memorized project answer.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 18Choose the first field’s color

UNDERSTAND THE IDEA

The first region should contrast with the canvas behind it. A named CSS color is a predefined value. It is convenient for a simple experiment, but its name does not imply maximum intensity in a particular RGB channel.

What you will do

Apply its requested background color.

A separate example to explore
step-18-example.csscss · example
.warm { background-color: coral; }

What to notice: This example uses a different class and color. A color declaration still needs a visible box to show its effect.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 19Space and center the first field

UNDERSTAND THE IDEA

The top margin introduces vertical separation as well as horizontal centering. Margins separate a box from its neighbors. Automatic horizontal margins can center a constrained block when spare space is available.

What you will do

Apply the requested first field margins and observe where the canvas begins.

A separate example to explore
step-19-example.csscss · example
.swatch { margin: 14px auto; }

What to notice: The two-value shorthand sets vertical and horizontal margins. It does not mean all four sides receive the first value.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 20Investigate a collapsing margin

UNDERSTAND THE IDEA

A first child’s top margin can collapse with its parent under certain conditions. Padding creates space inside a box’s border. With content-box sizing it adds to the declared content width and height.

What you will do

Add the requested temporary canvas padding and observe the boundary change.

A separate example to explore
step-20-example.csscss · example
.swatch-board { padding: 16px 8px; }

What to notice: These different values show interior space. Compare padding with external margins and include it when reasoning about the outer dimensions.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 21Create a new block formatting context

UNDERSTAND THE IDEA

Overflow hidden can contain child margins while also clipping overflow. Overflow controls content that extends beyond a box. Hidden clips overflow and creates a block formatting context, which can also affect margin-collapsing behavior.

What you will do

Replace the temporary padding with the requested overflow rule; compare the canvas dimensions and child placement.

A separate example to explore
step-21-example.csscss · example
.paint-area { overflow: hidden; }

What to notice: This rule can change both clipping and layout interactions. Do not use hidden to conceal a layout error without understanding what is being clipped.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 22Add the second color field

UNDERSTAND THE IDEA

The second region is a sibling of the first. A container groups elements for presentation. A shared class can apply common geometry while another class identifies an individual visual variant.

What you will do

Add the requested second div inside the canvas.

A separate example to explore
step-22-example.htmlhtml · example
<div class="swatch-board">
  <div class="swatch warm"></div>
</div>

What to notice: This is a small swatch example with different classes. The container and child are separate boxes with different responsibilities.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 23Set the second field’s width

UNDERSTAND THE IDEA

The composition uses different widths for its color fields. An empty block normally has no content height. Explicit dimensions can make an otherwise invisible colored box visible.

What you will do

Apply the requested second field width.

A separate example to explore
step-23-example.csscss · example
.swatch { width: 180px; height: 30px; }

What to notice: These dimensions differ from the marker and painting tasks. The visible outer size can also include borders and padding.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 24Set the second field’s height

UNDERSTAND THE IDEA

Independent heights change the visual balance. A height declaration controls the content box unless another box-sizing rule changes that relationship. Consider the containing box when using percentages.

What you will do

Apply the requested second field height.

A separate example to explore
step-24-example.csscss · example
.study-area { height: 360px; }

What to notice: This separate study area has a different height. The right value depends on the box you are actually styling, not a memorized project answer.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 25Color the second field

UNDERSTAND THE IDEA

Each field has its own surface rather than inheriting one shared background. A named CSS color is a predefined value. It is convenient for a simple experiment, but its name does not imply maximum intensity in a particular RGB channel.

What you will do

Set the requested second background color.

A separate example to explore
step-25-example.csscss · example
.warm { background-color: coral; }

What to notice: This example uses a different class and color. A color declaration still needs a visible box to show its effect.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 26Center the second field

UNDERSTAND THE IDEA

Automatic side margins distribute the remaining horizontal space. Margins separate a box from its neighbors. Automatic horizontal margins can center a constrained block when spare space is available.

What you will do

Add the requested second field margins.

A separate example to explore
step-26-example.csscss · example
.swatch { margin: 14px auto; }

What to notice: The two-value shorthand sets vertical and horizontal margins. It does not mean all four sides receive the first value.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 27Add the third color field

UNDERSTAND THE IDEA

The final field completes the three-region composition. A container groups elements for presentation. A shared class can apply common geometry while another class identifies an individual visual variant.

What you will do

Create the requested third div inside the canvas.

A separate example to explore
step-27-example.htmlhtml · example
<div class="swatch-board">
  <div class="swatch warm"></div>
</div>

What to notice: This is a small swatch example with different classes. The container and child are separate boxes with different responsibilities.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 28Use a parent-relative width

UNDERSTAND THE IDEA

A percentage width refers to the containing block’s available width. An empty block normally has no content height. Explicit dimensions can make an otherwise invisible colored box visible.

What you will do

Apply the requested percentage width to the third field.

A separate example to explore
step-28-example.csscss · example
.swatch { width: 180px; height: 30px; }

What to notice: These dimensions differ from the marker and painting tasks. The visible outer size can also include borders and padding.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 29Use a parent-relative height

UNDERSTAND THE IDEA

A percentage height relies on a definite height in the containing block. A height declaration controls the content box unless another box-sizing rule changes that relationship. Consider the containing box when using percentages.

What you will do

Set the requested percentage height and relate it to the canvas height.

A separate example to explore
step-29-example.csscss · example
.study-area { height: 360px; }

What to notice: This separate study area has a different height. The right value depends on the box you are actually styling, not a memorized project answer.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 30Color the third field

UNDERSTAND THE IDEA

The third surface should be read in the context of its neighbors. A named CSS color is a predefined value. It is convenient for a simple experiment, but its name does not imply maximum intensity in a particular RGB channel.

What you will do

Apply the requested third background color.

A separate example to explore
step-30-example.csscss · example
.warm { background-color: coral; }

What to notice: This example uses a different class and color. A color declaration still needs a visible box to show its effect.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 31Center the third field

UNDERSTAND THE IDEA

A percentage-width box can still have automatic side margins. Margins separate a box from its neighbors. Automatic horizontal margins can center a constrained block when spare space is available.

What you will do

Add the requested third field margins.

A separate example to explore
step-31-example.csscss · example
.swatch { margin: 14px auto; }

What to notice: The two-value shorthand sets vertical and horizontal margins. It does not mean all four sides receive the first value.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 32Make room between the later fields

UNDERSTAND THE IDEA

The second field’s bottom margin provides deliberate separation. Margins separate a box from its neighbors. Automatic horizontal margins can center a constrained block when spare space is available.

What you will do

Update its margin shorthand to include the requested bottom space.

A separate example to explore
step-32-example.csscss · example
.swatch { margin: 14px auto; }

What to notice: The two-value shorthand sets vertical and horizontal margins. It does not mean all four sides receive the first value.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 33Soften the canvas as a whole

UNDERSTAND THE IDEA

A filter affects the rendered element and its descendants. A blur filter softens the rendered element and its contents. A blurred edge and a box shadow are different effects, even when both suggest softness.

What you will do

Apply the requested canvas blur and inspect the entire composition.

A separate example to explore
step-33-example.csscss · example
.paint-area { filter: blur(1.5px); }

What to notice: This separate blur value is illustrative. Filters affect the rendered content; they do not change the underlying document structure.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 34Soften the first two fields further

UNDERSTAND THE IDEA

A child filter can add its own effect inside the filtered parent. A blur filter softens the rendered element and its contents. A blurred edge and a box shadow are different effects, even when both suggest softness.

What you will do

Add the requested shared blur rule for the first and second fields.

A separate example to explore
step-34-example.csscss · example
.paint-area { filter: blur(1.5px); }

What to notice: This separate blur value is illustrative. Filters affect the rendered content; they do not change the underlying document structure.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 35Give the third field its own softness

UNDERSTAND THE IDEA

The third field can use a different blur amount. A blur filter softens the rendered element and its contents. A blurred edge and a box shadow are different effects, even when both suggest softness.

What you will do

Add its requested filter and compare the visible edges.

A separate example to explore
step-35-example.csscss · example
.paint-area { filter: blur(1.5px); }

What to notice: This separate blur value is illustrative. Filters affect the rendered content; they do not change the underlying document structure.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 36Extend the first field’s color softly

UNDERSTAND THE IDEA

A shadow can extend painted color without reserving additional layout space. Box-shadow paints an effect around a box. Offsets move it, blur softens it and spread changes its reach; the painted shadow does not reserve normal layout space.

What you will do

Add the requested first field shadow, including blur and spread.

A separate example to explore
step-36-example.csscss · example
.sample { box-shadow: 4px 6px 10px 2px rgb(20 70 90 / 35%); }

What to notice: These values are different from the project. Read the lengths in order and inspect the effect before adjusting several values at once.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 37Match the second field’s shadow

UNDERSTAND THE IDEA

Matching the shadow color to the field softens its boundary. Box-shadow paints an effect around a box. Offsets move it, blur softens it and spread changes its reach; the painted shadow does not reserve normal layout space.

What you will do

Set the requested second field shadow.

A separate example to explore
step-37-example.csscss · example
.sample { box-shadow: 4px 6px 10px 2px rgb(20 70 90 / 35%); }

What to notice: These values are different from the project. Read the lengths in order and inspect the effect before adjusting several values at once.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 38Match the third field’s shadow

UNDERSTAND THE IDEA

The last field has its own shadow geometry. Box-shadow paints an effect around a box. Offsets move it, blur softens it and spread changes its reach; the painted shadow does not reserve normal layout space.

What you will do

Add the requested third field shadow and inspect the boundary.

A separate example to explore
step-38-example.csscss · example
.sample { box-shadow: 4px 6px 10px 2px rgb(20 70 90 / 35%); }

What to notice: These values are different from the project. Read the lengths in order and inspect the effect before adjusting several values at once.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 39Round the first field’s corners

UNDERSTAND THE IDEA

A radius changes the shape of the painted corners. Border-radius rounds the corners of a box. Its shorthand can set one radius or assign different radii in a defined corner order.

What you will do

Apply the requested single radius to the first field.

A separate example to explore
step-39-example.csscss · example
.paint-block { border-radius: 12px 18px 10px 24px; }

What to notice: The four values map to top-left, top-right, bottom-right and bottom-left. These sample values differ from the painting task.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 40Use two corner-radius values

UNDERSTAND THE IDEA

Two values apply to opposite pairs of corners. Border-radius rounds the corners of a box. Its shorthand can set one radius or assign different radii in a defined corner order.

What you will do

Set the requested pair of radii on the second field.

A separate example to explore
step-40-example.csscss · example
.paint-block { border-radius: 12px 18px 10px 24px; }

What to notice: The four values map to top-left, top-right, bottom-right and bottom-left. These sample values differ from the painting task.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 41Control four corners independently

UNDERSTAND THE IDEA

Four radius values proceed clockwise from the top-left corner. Border-radius rounds the corners of a box. Its shorthand can set one radius or assign different radii in a defined corner order.

What you will do

Apply the requested four-value radius to the third field.

A separate example to explore
step-41-example.csscss · example
.paint-block { border-radius: 12px 18px 10px 24px; }

What to notice: The four values map to top-left, top-right, bottom-right and bottom-left. These sample values differ from the painting task.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 42Tilt the first field slightly

UNDERSTAND THE IDEA

A transform changes visual presentation without recalculating its allocated layout box. A rotation changes the rendered orientation around the transform origin. It does not reserve a rotated outline in the normal document flow.

What you will do

Apply the requested small negative rotation to the first field.

A separate example to explore
step-42-example.csscss · example
.paint-block { transform: rotate(-1deg); }

What to notice: A negative angle rotates in the opposite direction to a positive one in the usual writing context. Inspect edges and overlaps after transforming.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 43Tilt the second field in the other direction

UNDERSTAND THE IDEA

The sign changes the direction of rotation. A rotation changes the rendered orientation around the transform origin. It does not reserve a rotated outline in the normal document flow.

What you will do

Add the requested positive rotation to the second field.

A separate example to explore
step-43-example.csscss · example
.paint-block { transform: rotate(-1deg); }

What to notice: A negative angle rotates in the opposite direction to a positive one in the usual writing context. Inspect edges and overlaps after transforming.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

Step 44Finish the third field’s tilt

UNDERSTAND THE IDEA

Small variations give the three fields different visual edges. A rotation changes the rendered orientation around the transform origin. It does not reserve a rotated outline in the normal document flow.

What you will do

Apply the requested third rotation, then inspect the complete composition and run the official checks.

A separate example to explore
step-44-example.csscss · example
.paint-block { transform: rotate(-1deg); }

What to notice: A negative angle rotates in the opposite direction to a positive one in the usual writing context. Inspect edges and overlaps after transforming.

Resources to explore

Read another explanation or experiment with examples before trying the official step.

Ready to try it? Use freeCodeCamp’s exact requirements and run its checks there. The example above is for understanding the concept.

READY TO BUILD?

Keep the instructions beside the video.

Start the official workshop in a new tab, play the walkthrough here, and pause to make each change yourself. Run freeCodeCamp’s checks before moving on. Write and check your project in the official freeCodeCamp editor.

An independent walkthrough by The Code Zone. Not affiliated with or endorsed by freeCodeCamp. The project and official tests belong to freeCodeCamp; the explanations and visual guide on this page are our companion material.