Skip to content

Commit 2109d5a

Browse files
committed
스타일 수정: MemeQuizStart 컴포넌트의 마진 및 높이를 뷰포트 비율로 조정하여 반응형 디자인 개선
1 parent 6f74b90 commit 2109d5a

File tree

1 file changed

+19
-4
lines changed

1 file changed

+19
-4
lines changed

apps/web/src/pages/MemeQuizPage/components/MemeQuizStart/MemeQuizStart.styles.ts

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,18 @@ const Container = styled(motion.div)`
1616
`;
1717

1818
const TextSection = styled(motion.div)`
19-
margin-top: 9.875rem;
19+
margin-top: 15vh;
2020
text-align: center;
2121
width: 100%;
2222
padding: 0 24px;
23+
24+
@media screen and (max-height: 700px) {
25+
margin-top: 10vh;
26+
}
27+
28+
@media screen and (min-height: 800px) {
29+
margin-top: 20vh;
30+
}
2331
`;
2432

2533
const Title = styled.h1`
@@ -35,20 +43,27 @@ const Subtitle = styled.p`
3543
`;
3644

3745
const IconSection = styled(motion.div)`
38-
margin-top: 61px;
46+
margin-top: 5vh; // 뷰포트 높이의 5%
3947
width: 100%;
40-
height: 240px;
48+
height: 25vh; // 뷰포트 높이의 25%
49+
min-height: 160px; // 최소 높이 설정
50+
max-height: 240px; // 최대 높이 설정
4151
display: flex;
4252
justify-content: center;
4353
align-items: center;
54+
55+
@media screen and (max-height: 700px) {
56+
margin-top: 3vh;
57+
height: 20vh;
58+
}
4459
`;
4560

4661
const ButtonWrapper = styled(motion.div)`
4762
position: fixed;
4863
bottom: 0;
4964
left: 0;
5065
right: 0;
51-
padding: 0 20px 40px;
66+
padding: 0 20px min(40px, 5vh); // 하단 패딩을 뷰포트 높이의 5% 또는 40px 중 작은 값으로 설정
5267
max-width: ${({ theme }) => theme.breakpoints.mobile};
5368
margin: 0 auto;
5469
`;

0 commit comments

Comments
 (0)