Skip to content

Commit be2aeab

Browse files
authored
Enhance CSS for responsive design and article layout
Refactor layout for main and article sections to improve responsiveness and styling, especially to accommodate the links suggested by the reviewer
1 parent ac0496b commit be2aeab

1 file changed

Lines changed: 16 additions & 11 deletions

File tree

Wireframe/style.css

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,8 @@ header {
1919
margin-bottom: calc(var(--space) * 2);
2020
}
2121
a {
22-
padding: var(--space);
23-
border: var(--line);
2422
max-width: fit-content;
23+
text-decoration: underline;
2524
}
2625
img,
2726
svg {
@@ -45,8 +44,10 @@ footer {
4544

4645
main {
4746
display: grid;
48-
grid-template-columns: 1fr 1fr;
47+
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
4948
gap: var(--space);
49+
max-width: var(--container);
50+
margin: 0 auto;
5051
}
5152

5253
main > *:first-child {
@@ -57,14 +58,18 @@ article {
5758
border: var(--line);
5859
padding-bottom: var(--space);
5960
text-align: left;
60-
display: grid;
61-
grid-template-columns: var(--space) 1fr var(--space);
62-
article > * {
63-
grid-column: 2/3;
64-
}
65-
article > img {
66-
grid-column: 1 / -1;
67-
}
61+
display: flex;
62+
flex-direction: column;
63+
gap: var(--space);
64+
}
65+
article img {
66+
width: 100%;
67+
display: block;
68+
}
69+
70+
details p {
71+
margin: 0;
72+
padding-top: 10px;
6873
}
6974

7075
summary {

0 commit comments

Comments
 (0)