/* Global */

* {
  font-family: Roboto, Arial, sans-serif;
}

:root {
  --top-page-padding: 30px;
  --main-color: #38A883;
  --background: rgb(218, 218, 218);
  --foreground: #fff;
  --light-text: rgb(58, 58, 58)
}

ul {
  list-style: none;
  padding: 0px
}

p, li, ul, h1, h2, h3 {
  margin: 0px;
}

body {
  height: 100vh;
}

.layout-container {
  height: 100vh;
  width: 100vw;
  display: grid;
  position: relative;
  grid-template-columns: 340px 1fr;
  grid-template-rows: 1fr 4fr;
  grid-template-areas:
    "sidebar header"
    "sidebar cards";
}

img[alt^="profile"] {
  border-radius: 30px;
}

.clickable:hover {
  cursor: pointer;
}

/* Sidebar */

.sidebar {
  grid-area: sidebar;
  display: flex;
  flex-direction: column;
  position: fixed;
  height: 100vh;
  width: 300px;
  gap: 40px;
  padding-left: 40px;
  padding-top: var(--top-page-padding);
  background-color: var(--main-color);
  color: white;
}

.sidebar div:first-child, .sidebar li {
  display: flex;
  gap: 15px;
  align-items: center;
}

.sidebar h1 {
  font-size: 30px;
  margin: 0px;
}

.sidebar div:first-child img {
  height: 30px;
}

.sidebar li {
  margin-bottom: 20px;
  font-size: 18px;
  font-weight: bold;
}

.sidebar li:hover {
  text-decoration: underline 2px;
}

.sidebar li img {
  height: 18px;
}

/* Header: Global */

header {
  grid-area: header;
  display: grid;
  grid-template-columns: 2fr 1fr;
  grid-template-rows: repeat(2, 1fr);
  column-gap: 30px;
  align-items: baseline;
  padding-top: var(--top-page-padding);
  padding-right: 60px;
  padding-left: 45px;
  padding-bottom: 15px;
  background-color: var(--foreground);
  box-shadow: 0px 2.5px 2px rgba(0, 0, 0, 0.164);
}

header img {
  height: 30px;
}

.search-bar-container, .user-notifications {
  align-self: flex-start;
}

.hello-user, .buttons {
  align-self: center;
}

/* Header: Search Bar */

.search-bar-container {
  display: flex;
  gap: 15px;
  height: 30px;
}

.search-bar-container input {
  flex-grow: 1;
  border-radius: 10px;
  border: none;
  background-color: rgb(236, 236, 236);
  padding: 0px 10px;
}

.search-bar-container #search-bar:focus {
  outline: 2px solid rgb(0, 150, 209);
}

.search-bar-container input:hover {
  outline: 2px solid black;
}

/* Header: User Notifications */

.user-notifications {
  display: flex;
  justify-content: end;
  gap: 25px;
  align-items: center;
  height: 30px;
}

.user-notifications img[alt^="profile"] {
  height: 45px;
}

.user-notifications h2 {
  font-size: 1em;
}

/* Header: Hello User */

.hello-user {
  display: flex;
  gap: 20px;
  font-weight: bold;
}

.hello-user img {
  height: 60px;
}

.hello-user span {
  font-size: 0.8em;
}

.hello-user h1 {
  font-size: 1.5em;
}

/* Header: Buttons */

.buttons {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10%;
}

.buttons button {
  border: none;
  border-radius: 15px;
  height: 30px;
  flex-grow: 1;
  background-color: var(--main-color);
  color: #fff;
}

.buttons button:hover {
  opacity: 0.75;
}

/* Cards: Global */

.cards-container {
  grid-area: cards;
  display: grid;  
  grid-template-columns: 3fr 1fr;
  grid-template-rows: auto auto;
  grid-template-areas:
    "projects aside"
    "projects .";
  column-gap: 20px;
  background-color: var(--background);
  padding: 50px 40px 60px 30px;
}

.list-container {
  display: flex;
  flex-direction: column;
}

.list-container ul {
  display: grid;
  flex-grow: 1;
}

.list-container > h1 {
  font-size: 1.3em;
}

.list-container > h2 {
  margin-bottom: 12px;
}

.card {
  border-radius: 10px;
  background-color: var(--foreground);
  box-shadow: 2.5px 2.5px 2px rgba(0, 0, 0, 0.164);
}

aside {
  grid-area: aside;
  display: flex;
  flex-direction: column;
  gap: 30px
}

/* Cards: Projects */

.projects {
  grid-area: projects;
}

.projects ul {
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  grid-template-rows: repeat(3, 250px);
  gap: 30px 20px; 
}

.project-card {
  border-left: 8px solid #C93D1A;
  padding: 20px 15px;
  display: flex;
  flex-direction: column;
  gap: 15px;
  justify-content: space-between;
}

.project-card div:first-child {
  width: 80%;
}

.project-card div:first-child h3 {
  margin-bottom: 10px;
}

.project-card div:first-child p {
  color: var(--light-text);
}

.project-card div:last-child{
  display: flex;
  justify-content: flex-end;
  gap: 40px;
}

.project-card img {
  height: 25px;
}

/* Cards: Announcements */

.announcements .card {
  padding: 30px;
  border-radius: 10px;
}

.announcements h3 {
  margin-bottom: 6px;
}

.announcements p {
  font-size: 0.8em;
  color: var(--light-text);
}

.announcements hr {
  margin: 18px 0px;
}

/* Cards: Trending */

.trending .card {
  grid-template-columns: 1fr;
  grid-template-rows: repeat(4, 1fr);
  gap: 20px;
  padding: 20px;
}

.trending li {
  display: flex;
  align-items: center;
  gap: 20px;
}

.trending h3 {
  font-size: 1em;
  font-weight: 500;
  margin-bottom: 5px;
}

.trending p {
  font-size: 0.9em;
  color: var(--light-text);
}

.trending img {
  height: 50px;
}