:root {
  --color-soft-orange: hsl(35, 77%, 62%);
	--color-soft-red: hsl(5, 85%, 63%);

	--color-off-white: rgb(255, 253, 250);
	--color-grayish-blue: hsl(233, 8%, 79%);
	--color-dark-grayish-blue: hsl(236, 13%, 42%);
	--color-very-dark-blue: hsl(240, 100%, 5%);
}

@font-face {
	font-family: "Inter";
	font-weight: 400;
	font-style: normal;
	src: url("./assets/fonts/static/Inter-Regular.ttf") format("truetype");
}

@font-face {
	font-family: "Inter";
	font-weight: 700;
	font-style: normal;
	src: url("./assets/fonts/static/Inter-Bold.ttf") format("truetype");
}

@font-face {
	font-family: "Inter";
	font-weight: 800;
	font-style: normal;
	src: url("./assets/fonts/static/Inter-ExtraBold.ttf") format("truetype");
}

* {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

body,
html {
	overflow-x: hidden;
}

body {
	font-family: "Inter", sans-serif;
	background-color: var(--color-off-white);
}

p {
	font-size: 15px;
}

button {
	outline: none;
	border: none;
	background-color: transparent;
}

img {
	max-width: 100%;
	height: auto;
}

main {
	padding: 1rem;
	position: relative;
}

ul {
	list-style: none;
}

li {
	list-style: none;
	font-size: 1.3rem;
	padding: 1.3rem 1rem;
	cursor: pointer;
	transition: all 0.2s ease;
}

li:hover {
	color: var(--color-soft-red);
}

/* Nav bar */
.nav {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 1.5rem;
}

.logo {
	display: flex;
	align-items: center;
	width: 44px;
	height: 44px;
}

.open-btn {
	display: block;
}

.hamburger-menu {
	width: 70%;
	height: 100vh;
	z-index: 1;
	position: absolute;
	top: 0;
	right: -300px;
	background-color: var(--color-off-white);
	padding: 1.5rem 1rem;
	transition: all 0.3s ease;
}

.hamburger-menu.visible {
	right: 0;
}

.close-btn-wrapper {
	display: flex;
	justify-content: flex-end;
	margin-bottom: 3rem;
}

.close-btn {
	width: 44px;
	height: 44px;
}

/* Header */
header {
	margin-bottom: 4rem;
}

.hero-text_title {
	margin-top: 1.5rem;
	font-size: 2.8rem;
	line-height: 1;
	font-weight: 800;
}

header p {
	margin-top: 1.1rem;
	color: var(--color-dark-grayish-blue);
	line-height: 1.6;
}

header button {
	color: var(--color-very-dark-blue);
	font-weight: 800;
	text-transform: uppercase;
	letter-spacing: 1.7px;
	background-color: var(--color-soft-red);
	padding: 1rem 2rem;
	margin-top: 1.5rem;
	cursor: pointer;
	transition: all 0.2s ease;
}

header button:hover,
header button:focus {
	background-color: var(--color-very-dark-blue);
	color: var(--color-off-white);
}

/* New articles */
.new-articles {
	background-color: var(--color-very-dark-blue);
	margin: 0 0 4rem;
	padding: 1.5rem;
}

.new-articles h2 {
	color: var(--color-soft-orange);
	font-size: 2rem;
	letter-spacing: 1.5px;
}

.new-article {
	border-bottom: 1px solid rgba(255, 253, 250, 0.6);;
	padding: 2rem 0;
}

.new-article:last-child {
	border: none;
	padding-bottom: 0;
}

.new-article h3 {
	color: var(--color-off-white);
	margin-bottom: 0.8rem;
	cursor: pointer;
	transition: all 0.2s ease;
}

.new-article h3:hover {
	color: var(--color-soft-orange);
}

.new-article p {
	color: var(--color-off-white);
	opacity: 0.6;
	font-weight: 400;
	line-height: 1.5;
}

/* Top articles */
.top-articles {
	margin-bottom: 4rem;
}
.top-articles article {
	flex: 1;
	display: flex;
	gap: 1.6rem;
	margin-bottom: 1.6rem;
}

.top-article_image {
	flex: 1;
}

.top-article_image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.top-article_info {
	flex: 2;
}

.top-article_num {
	color: var(--color-soft-red);
	font-size: 1.9rem;
	font-weight: 700;
	margin-bottom: 0.5rem;
}

.top-article_info h3 {
	color: var(--color-very-dark-blue);
	margin-bottom: 0.7rem;
	font-weight: 800;
	font-size: 1.1rem;
	cursor: pointer;
	transition: all 0.2s ease;
}

.top-article_info h3:hover {
	color: var(--color-soft-red);
}

.top-article_detail {
	color: var(--color-dark-grayish-blue);
	opacity: 0.8;
	line-height: 1.7;
}

@media (min-width: 768px) {
	body {
		display: flex;
		justify-content: center;
		align-items: center;
		margin: 0 auto;
		height: 100vh;
	}

	main {
		max-width: 1080px;
	}

	.content {
		display: grid;
		grid-template-columns: 1fr 1fr 1fr;
		gap: 3rem 2rem;
	}

	/* Nav bar */
	.logo {
		width: 60px;
		height: 60px;
	}

	.open-btn {
		display: none;
	}

	.hamburger-menu {
		display: flex;
		justify-content: flex-end;
		width: 100%;
		height: auto;
		z-index: 0;
		position: inherit;
		padding: 0;
	}

	.close-btn-wrapper {
		display: none;
	}

	.nav-list {
		display: flex;
		gap: 1rem;
	}

	.nav-list li {
		font-size: 1rem;
	}

	.nav-list li:last-child {
		padding-right: 0;
	}

	/* Header */
	header {
		grid-column: 1 / span 2 ;
		margin-bottom: 0;
	}

	.hero-img-mobile {
		display: none;
	}

	.hero-img-desktop {
		display: block;
		margin-bottom: 0.5rem;
	}

	.hero-text {
		display: flex;
		gap: 1rem;
	}

	.hero-text_title {
		flex: 1;
		font-size: 3.1rem;
		line-height: 1.1;
	}

	.hero-text_info {
		flex: 1;
	}

	header p {
		font-size: 0.9rem;
		line-height: 1.6;
		padding-right: 1rem;
	}

	/* New articles */
	.new-articles {
		margin-bottom: 0;
	}

	.new-article p {
		font-size: 0.8rem;
	}

	/* Top articles */
	.top-articles {
		margin-bottom: 0;
		grid-column: 1 / span 3;
		display: flex;
		gap: 1.8rem;
	}

	.top-articles article {
		gap: 1rem;
		margin-bottom: 0;
	}

	.top-article_image {
		flex: 1;
	}

	.top-article_info {
		flex: 2;
	}

	.top-article_num {
		color: var(--color-soft-red);
		font-size: 1.9rem;
		font-weight: 700;
		margin-bottom: 0.5rem;
	}

	.top-article_info h3 {
		color: var(--color-very-dark-blue);
		margin-bottom: 0.7rem;
		font-weight: 800;
		font-size: 1.1rem;
	}

	.top-article_detail {
		color: var(--color-dark-grayish-blue);
		opacity: 0.8;
		line-height: 1.7;
	}
}