/*Fonts*/
@font-face {
  font-family: 'roboto';
  src: url('./fonts/roboto/Roboto-Regular.woff2') format('woff2'),
    url('./fonts/roboto/Roboto-Regular.woff') format('woff');
    font-weight: 400;
}

@font-face {
  font-family: 'roboto';
  src: url('./fonts/roboto/Roboto-Medium.woff2') format('woff2'),
    url('./fonts/roboto/Roboto-Medium.woff') format('woff');
    font-weight: 600;
}

@font-face {
  font-family: 'roboto';
  src: url('./fonts/roboto/Roboto-Black.woff2') format('woff2'),
    url('./fonts/roboto/Roboto-Black.woff') format('woff');
    font-weight: 900;
}

/*CSS Reset, credits Kevin Powell*/
/* makes sizing simpler */

*,
*::before,
*::after {
  box-sizing: border-box;
}

/* remove default spacing */
/* force styling of type through styling, rather than elements */

* {
  margin: 0;
  padding: 0;
  font: inherit;
}

/* dark mode user-agent-styles */

/*html {
  color-scheme: dark light;
}*/

/* min body height */

body {
  min-height: 100vh;
}

/* responsive images/videos */
img,
picture,
svg,
video {
  display: block;
  max-width: 100%;
}

/*Custom properties*/
:root {
  --sidebar-blue: #1992d4;
  --white: #ffffff;
  --black: #000000;
  --background-grey: #e2e8f0;
  --accent-orange: #f0b429;
}

/*Setting fluid typography, credit CSS tricks*/
html {
  font-size: calc(16px + (26 - 16) * ((100vw - 300px) / (2800 - 300)));
  /*font-size: calc(15px + 0.390625vw);*/
  font-family: 'roboto', sans-serif;
}

/*Main page container*/
.main-container {
  display: grid;
  height: 100vh;
  /*width: 100vw;*/ /*Was causing vertical scrolling*/
  grid-template-columns: 11rem 1fr;
  grid-template-rows: 9rem 1fr;
  grid-template-areas: 
  'sidebar header'
  'sidebar main-content';
}

/*Left Sidebard*/
.sidebar-container {
  background-color: var(--sidebar-blue);
  grid-area: sidebar;
  padding: 15px;
}

/*Logo image and text*/
.logo-container {
  display: flex;
  align-items: center;
  gap: 15px;
}

.logotype {
  display: grid;
  grid-template-columns: repeat(2, 15px);
  grid-template-rows: repeat(3, 8px);
  gap: 3px;
}

.logo-element-one {
  grid-column: 1 / 2;
  grid-row: 1 / 3;
  background-color: var(--white);
}

.logo-element-one:hover {
  background-color: var(--accent-orange);
}

.logo-element-two {
  grid-column: 2 / 3;
  grid-row: 1 / 2;
  background-color: var(--white);
}

.logo-element-two:hover {
  background-color: var(--accent-orange);
}

.logo-element-three {
  grid-column: 1 / 2;
  grid-row: 3 / 4;
  background-color: var(--white);
}

.logo-element-three:hover {
  background-color: var(--accent-orange);
}

.logo-element-four {
  grid-column: 2 / 3;
  grid-row: 2 / 4;
  background-color: var(--white);
}

.logo-element-four:hover {
  background-color: var(--accent-orange);
}

.logo-text {
  color: var(--white);
  font-weight: 900;
  font-family: 'roboto', sans-serif;
}

/*Sidebar navigation area*/
.sidebar-navigation-container {
  display: grid;
  gap: 15px;
}

[class$='-navigation'] {
  display: flex;
  align-items: center;
  gap: 15px;
}

[class$='-navigation']:first-child {
  margin-top: 50px;
}

[class$='-navigation']:nth-child(7) {
  margin-top: 50px;
}

[class$='-navigation-icon'] {
  width: 2rem;
  fill: var(--white);
}

[class$='-navigation-text'] {
  color: var(--white);
  font-weight: 400;
  text-decoration: none;
  font-family: 'roboto', sans-serif;
}

[class$='-navigation']:hover > * {
  color: var(--accent-orange);
  fill: var(--accent-orange);
}

/*Header*/
.header-container {
  grid-area: header;
  background-color: var(--white);
  display: grid;
  grid-template-rows: repeat(2, 1fr);
  padding: 0 20px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.25);
}

/*Top Header Element*/
.top-header-container {
  display: grid;
  grid-template-columns: 3fr 1fr;
}

.magnifying-glass,
.bell-icon {
  width: 1.5rem;
  height: 1.5rem;
}

.bell-icon:hover {
  fill: var(--accent-orange);
}

.profile-avatar-icon {
  width: 3rem;
  height: 3rem;
}

.search-element {
  display: flex;
  align-items: center;
  justify-self: start;
  gap: 15px;
}

input[type='search'] {
  appearance: none;
  height: 2rem;
  border: none;
  border-radius: 15px;
  background-color: var(--background-grey);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.25);
  padding-left: 20px;
}

input[type='search']:focus {
  border: 2px solid var(--sidebar-blue);
  outline: none;
}

.profile-element {
  display: flex;
  align-items: center;
  justify-self: end;
  gap: 15px;
}

.profile-element a {
  text-decoration: none;
  font-weight: 900;
  color: var(--black);
  font-family: 'roboto', sans-serif;
}

/*Bottom Header Element*/
.bottom-header-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.hello-username-container {
  display: grid;
  grid-template-columns: 4.5rem 1fr;
}

.hello-avatar-icon {
  grid-column: 1 / 2;
  align-self: center;
  width: 4rem;
  height: 4rem;
}

.hello-text-container {
  grid-column: 2 / 3;
  display: grid;
  justify-items: start;
}

.greeting-text {
  align-self: end;
  font-weight: 600;
  font-family: 'roboto', sans-serif;
}

.username-text {
  font-weight: 600;
  font-family: 'roboto', sans-serif;
}

.bottom-header-buttons {
  display: grid;
  grid-template-columns: repeat(3, 7rem);
  justify-content: space-between;
  align-items: center;
}

.bottom-header-buttons button {
  border-radius: 16px;
  height: 2rem;
  border: none;
  background-color: var(--sidebar-blue);
  color: var(--white);
  font-weight: 600;
  font-family: 'roboto', sans-serif;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.25);
}

.bottom-header-buttons button:hover {
  border-radius: 16px;
  height: 2rem;
  border: none;
  background-color: var(--sidebar-blue);
  color: var(--accent-orange);
  font-weight: 600;
  font-family: 'roboto', sans-serif;
}

.bottom-header-buttons button:active {
  box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.25);
}

/*Main Content*/
.dynamic-content-container {
  grid-area: main-content;
  display: grid;
  grid-template-columns: 3fr 1fr;
  grid-template-rows: 1fr 1fr;
  background-color: var(--background-grey);
  overflow: auto;
  padding: 25px 15px;
  gap: 15px;
}

/*Projects area*/
.projects-container {
  display: grid;
  grid-column: 1 / 2;
  grid-row: 1 / 3;
  grid-template-rows: 2rem 1fr;
  background-color: var(--background-grey);
}

.project-cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    /*grid-template-rows: repeat(auto-fit, 200px);*/
    gap: 15px;
}

.your-projects-heading {
    font-weight: 600;
    font-family: 'roboto', sans-serif;
}

/*Project cards*/
.project-card {
    background-color: var(--white);
    border-left: 5px solid var(--accent-orange);
    border-radius: 5px;
    display: grid;
    grid-template-rows: 2rem auto 2rem;
    gap: 5px;
    padding: 15px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.25);
}

.project-card h4 {
  font-weight: 600;
  font-family: 'roboto', sans-serif;
}

.card-icons-container {
  display: flex;
  justify-content: flex-end;
  gap: 15px;
}

.card-icons-container svg {
  width: 1.5rem;
  height: 1.5rem;
}

.card-icons-container svg:hover {
  fill: var(--accent-orange);
}

/*Announcements*/
.announcements-container {
    grid-column: 2 / 3;
    display: grid;
    grid-template-rows: 2rem 1fr;
}

.announcements-heading {
  font-weight: 600;
  font-family: 'roboto', sans-serif;
}

.announcements-cards-container {
  display: grid;
  /*grid-template-rows: repeat(3, fit-content(30ch));*/
  background-color: var(--white);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.25);
  border-radius: 5px;
}

.announcement-card {
  border-bottom: 1px solid var(--background-grey);
  display: grid;
  grid-template-rows: fit-content(25ch) fit-content(30ch);
  padding: 15px;
  gap: 5px;
}

.announcement-card h4 {
  font-weight: 600;
  font-family: 'roboto', sans-serif;
}

.announcement-card:last-child {
  border-bottom: none;
}

/*Trending*/
.trending-container {
  grid-column: 2 / 3;
  display: grid;
  grid-template-rows: 2rem auto;
}

.trending-cards-container {
  display: grid;
  background-color: var(--white);
  border-radius: 5px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.25);
}

.trending-heading {
  font-weight: 600;
  font-family: 'roboto', sans-serif;
}

.trending-card {
  display: grid;
  grid-template-columns: 3rem fit-content(30ch);
  padding-left: 15px;
}

.trending-card svg {
  width: 3rem;
  grid-column: 1 / 2;
}

.trending-card-text {
  display: grid;
  justify-items: start;
}

.trending-card-text a {
  text-decoration: none;
  font-weight: 600;
  font-family: 'roboto', sans-serif;
  color: var(--black);
  align-self: end;
}