@import url('https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300..800;1,300..800&display=swap');
* {
  box-sizing: border-box;
}
:root {
  --blog-bg-color: #024873;
  --blog-color: #fff;
  --git-bg-color: #D99771;
  --git-color: #401201;
  --codepen-bg-color: #4d4d4d;
  --codepen-color: #fff;
  --youtube-bg-color: #556b2f;
  --youtube-color: #ffffff
	
  --shadow: #aba3a3;
}
body {
  font-family: "Open Sans", sans-serif;
  margin: 0;
  padding: 0;
}
h2 {
  font-weight: 300;
}
/* Mobile-First Styles (Small Screens) */
.container {
  padding: 0;
  margin: 0;
}
section {
  /* max-width: 100%; */
  /* Full width on small screens */
  padding: 5px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  /* Column layout for mobile */
  flex-wrap: nowrap;
  gap: 10px;
}
.item {
  flex: 1 1 calc(100% - 24px);
  /* Full width for each item */
  height: auto;
  border: 2px solid #333;
  border-color: hsla(0, 0%, 0%, 0.5);
  border-radius: 5px;
  padding: 5px;
  background-repeat: no-repeat;
  background-position: calc(100% - 5px) 5px;
  transition: all 0.3s ease-in-out;
  transform: scale(1);
}
section div.item > a {
  text-decoration: none;
  color: inherit;
  display: block;
  position: relative;
}
section div.item:hover {
  background-color: var(--blog-bg-color) !important;
  color: var(--blog-color) !important;
}
.headerRow {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 5px;
}
.headerRow svg, .headerRow .imgContainer {
  flex: 0 0 40px;
}
.imgContainer{
	width:100%;
	height: auto;
}
.blog {
  background-color: var(--blog-bg-color);
  color: var(--blog-color);
}
.git {
  background-color: var(--git-bg-color);
  color: var(--git-color);
}
.codePen {
  background-color: var(--codepen-bg-color);
  color: var(--codepen-color);
}
.youTube {
  background-color: var(--youtube-bg-color);
  color: var(--youtube-color);
}
.grid {
  display: grid;
  grid-template-rows: 1fr;
  gap: 10px;
}
/*Backgrounds */
.pic1 {
  background-image: url(../images/type-set.webp);
  background-size: cover;
  background-position: 0 0;
  min-height: 150px;
}
.pic2 {
  background-image: url(../images/hamburg-bubbles.webp);
  background-size: cover;
  background-position: 0 0;
  min-height: 150px;
}
.pic3 {
  background-image: url(../images/leaf-car.webp);
  background-size: cover;
  background-position: 0 0;
  min-height: 150px;
}
.pic4 {
  background-image: url(../images/brutal-almaty.webp);
  background-size: cover;
  background-position: 0 0;
  min-height: 150px;
}
section div.item {
  animation-timeline: view(block 85% 0%);
  animation-name: grow;
  animation-fill-mode: both;
  animation-duration: 1ms;
  /* Firefox requires this to apply the animation */
  animation-timing-function: linear;
}
@keyframes grow {
  from {
    transform: scale(.8);
  }
  to {
    transform: scale(1);
  }
}
/* Tablet Screens (768px and above) */
@media (min-width: 481px) and (max-width: 768px) {
  section {
    flex-direction: row;
    flex-wrap: wrap;
  }
  section div.item {
    flex: 1 1 calc(50vw - 12px);
    /* Two items per row */
  }
  section div.blog:nth-child(5n+3), section div.git:nth-child(5n+4), section div.codePen:nth-child(5n+6), .big {
    flex: 1 1 100%;
    /* Full width for each item */
  }
  /*Grid */
  .grid {
    display: grid;
    grid-template-rows: 1fr;
    gap: 10px;
  }
}
/* Medium Screens (1024px and above) */
@media (min-width: 769px) and (max-width: 1024px) {
  section {
    flex-direction: row;
    flex-wrap: wrap;
  }
  section div.item {
    flex: 1 1 calc(33vw - 21px);
    /* Three items per row */
  }
  section div.blog:nth-child(5n+3), section div.git:nth-child(5n+4), section div.codePen:nth-child(5n+6), .big {
    flex: 1 1 calc(66vw - 21px);
    /* One item spanning two columns */
  }
  /*Grid */
  .grid {
    display: grid;
    grid-template-rows: 1fr 1fr;
    gap: 10px;
	flex: 1 1 100%;
  }
}
/* Desktop Screens (1025px and above) */
@media (min-width: 1025px) {
  section {
    max-width: 1200px;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 10px;
  }
  section div.item {
    flex: 1 1 calc(20% - 10px);
    /* Five items per row */
  }
  section div.blog:nth-child(5n+3), section div.git:nth-child(5n+4), section div.codePen:nth-child(5n+6), .big {
    flex: 1 1 calc(40% - 8px);
  }
  /*Grid */
  .grid {
    display: grid;
    grid-template-rows: 1fr 1fr;
    gap: 10px;
  }
}