The goal of Homework 4 is to improve the layout from Homework 3 and organize the coffee region content into two columns.
Requirements:
- Update the design of the previous Coffee Regions page.
- Display all region blocks in two columns.
- Tables must not be used.
- The layout should be implemented using CSS positioning.
This project improves the Coffee Regions page by introducing a two-column layout for the content.
The page contains:
- A hero header with a coffee background image.
- A large centered title: The Best Coffee Regions.
- Six coffee region descriptions organized into two vertical columns.
Each region includes:
- Region name
- Description paragraph
- External link to learn more
Regions included:
- Brazil
- Colombia
- India
- Ethiopia
- Costa Rica
- Kenya
/project
├─ index.html
├─ CSS/
│ └─ style.css
└─ Images/
├─ coffee-bgnd.jpeg
└─ coffee.png
The homework focuses on practicing:
- CSS positioning
- Two-column layout without tables
- Semantic HTML structure
- Improved page styling
This assignment demonstrates how layout can be controlled using absolute positioning and container references.
The header contains:
- Coffee background image
- Large decorative title
- Fixed height (400px)
.header {
height: 400px;
background-image: url("../Images/coffee-bgnd.jpeg");
background-size: cover;
background-position: center;
}The main container uses position: relative.
Two columns are positioned inside it:
.left.right
.main {
position: relative;
}
.left,
.right {
position: absolute;
width: 49%;
top: 0;
}Left column is aligned to the left side, and right column to the right side.
Each coffee region is represented as an <article> element.
Each block contains:
<h2>– region title<p>– description<a>– external link
Example:
<article class="region">
<h2>Brazil</h2>
<p>...</p>
<a href="https://en.wikipedia.org/wiki/Brazil">Learn more about Brazil</a>
</article>The page uses Google Fonts:
Raleway– main content fontCovered By Your Grace– decorative header font
Additional styling features include:
- Uppercase region titles
- Centered headings
- Justified paragraph text
- Decorative separators between regions
- Custom link styling
-----------------------------------
| Header (coffee image) |
| The Best Coffee Regions |
-----------------------------------
| Brazil | Ethiopia |
| Colombia | Costa Rica |
| India | Kenya |
-
Open
index.htmlin a web browser. -
Ensure the following resources exist:
CSS/style.cssImages/coffee-bgnd.jpegImages/coffee.png
-
The page will display the header and coffee regions arranged in two columns.
Status: ✅ Completed
- Layout redesigned from Homework 3
- Two-column layout implemented using CSS positioning
- No tables used
- Clean and readable styling applied
MIT License
Made with ❤️ using HTML + CSS by Sam Malikin