Skip to content

Commit

Permalink
Optimise & Clean code
Browse files Browse the repository at this point in the history
  • Loading branch information
AsteroidusTv authored Oct 17, 2024
1 parent 24ceccd commit e06f02d
Showing 1 changed file with 17 additions and 45 deletions.
62 changes: 17 additions & 45 deletions styles/about.css
Original file line number Diff line number Diff line change
@@ -1,94 +1,66 @@
.about {
display: flex;
position: relative;
align-items: center;
justify-content: space-between;
height: 100vh;
padding: 3.125rem;
background-color: var(--secondary-color);
}

.about-text-content {
flex: 1;
max-width: 50%;
padding-right: 1.25rem;
text-align: left;
}

.about-title {
color: var(--primary-color);
font-size: 2.5rem;
margin-bottom: 1.25rem;
font-size: 40px;
margin-bottom: 10px;
}

.about-text {
color: var(--primary-color);
font-size: clamp(0.75rem, 1.125rem + 1vw, 1.125rem);
line-height: 1.6;
margin-bottom: 1.25rem;
}

.about-image-content {
flex: 1;
display: flex;
justify-content: center;
align-items: center;
max-width: 50%;
font-size: clamp(13.5px, 2vw, 18px);
line-height: 1.5;
}

.about-image {
border-radius: var(--border-radius);
box-shadow: 10px 10px 0 0 var(--primary-color);
height: auto;
max-width: 50%;
max-height: 50vh;
}

@media screen and (max-width: 990px) {
.about-image-content {
display: none;
@media screen and (max-height: 1200px) {
.about-image {
max-height: 45vh;
}
}

@media screen and (max-width: 1100px) {
.about-image {
display: none;
}
.about-text-content {
max-width: 100%;
}
}

@media screen and (max-width: 500px) {
.about {
padding: 1.875rem;
padding: var(--main-section-padding-mobile);
align-items: center;
justify-content: center;
}

.about-title {
margin-bottom: -0.3125rem;
margin-bottom: -5px;
}

.about-text-content {
margin-top: 5rem;
padding: 0.9375rem;
border: 0.3125rem solid var(--primary-color);
padding: 15px;
border: 5px solid var(--primary-color);
border-radius: var(--border-radius);
display: flex;
flex-direction: column;
gap: 0.625rem;
}

.about-text {
margin-bottom: 0;
}
}

@media screen and (max-height: 950px) {
.about-text {
line-height: 1.5;
}
}

@media screen and (max-height: 900px) {
.about-text {
line-height: 1.3;
font-size: 1.9vh;
gap: 10px;
}
}

0 comments on commit e06f02d

Please sign in to comment.