/* Importing NotoSans Font from Google Fonts */
@import url("https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&family=Noto+Sans:ital,wght@0,100..900;1,100..900&family=Poppins:wght@400;500;700&display=swap");

/* Root */
* {
  padding: 0;
  margin: 0;
}

/* Variables */
:root {
  /* Neutral Colors */
  --neutral-900: hsl(227, 75%, 14%);
  --neutral-800: hsl(226, 25%, 17%);
  --neutral-700: hsl(225, 23%, 24%);
  --neutral-600: hsl(226, 11%, 37%);
  --neutral-300: hsl(0, 0%, 78%);
  --neutral-200: hsl(217, 61%, 90%);
  --neutral-100: hsl(0, 0%, 93%);
  --neutral-0: hsl(200, 60%, 99%);

  /* Red Colors */
  --red-400: hsl(3, 86%, 64%);
  --red-500: hsl(3, 71%, 56%);
  --red-700: hsl(3, 77%, 44%);

  /* Gradients */
  --gradient-light: linear-gradient(180deg, #ebf2fc 0%, #eef8f9 100%);
  --gradient-dark: linear-gradient(180deg, #040918 0%, #091540 100%);
}

/* Body */
body {
  width: 100vw;
  display: flex;
  justify-content: start;
  align-items: center;
  flex-direction: column;
  font-family: "Noto Sans", sans-serif;
  background-repeat: no-repeat;
  box-sizing: border-box;
  overflow-y: auto;
  min-height: 100vh;
}

/* Body light theme */
.light {
  background: var(--gradient-light);
}
/* Body dark theme */
.dark {
  background: var(--gradient-dark);
}

/* =========================================== */

/* TopBar */
.topbar {
  width: 80%;
  height: 50px;
  margin-top: 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 2px solid var(--neutral-200);
  padding: 15px;
  border-radius: 30px;
}

/* Topbar Light */
.topbarlight {
  background-color: var(--neutral-0);
}

/* Topbar dark */
.topbardark {
  background-color: var(--neutral-800);
  border: 2px solid var(--neutral-800);
}

/* Whole Topbar light-themed */
.topbar .themeContainer-light {
  user-select: none;
  width: 55px;
  height: 55px;
  background-color: var(--neutral-100);
  border-radius: 15px;
  display: grid;
  place-content: center;
  cursor: pointer;

  /* For not getting highlighting/selection while clicked/pressed */
  -webkit-tap-highlight-color: transparent;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  outline: none;
  -webkit-touch-callout: none;
}

.topbar .themeContainer-light:hover {
  background-color: var(--neutral-300);
}

.topbar .themeContainer-light:focus {
  outline: none;
  border: 2px solid var(--red-700);
}

/* Whole Topbar dark-themed */
.topbar .themeContainer-dark {
  user-select: none;
  width: 55px;
  height: 55px;
  background-color: var(--neutral-700);
  border-radius: 15px;
  display: grid;
  place-content: center;
  cursor: pointer;

  /* For not getting highlighting/selection while clicked/pressed */
  -webkit-tap-highlight-color: transparent;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  outline: none;
  -webkit-touch-callout: none;
}

.topbar .themeContainer-dark:hover {
  background-color: var(--neutral-600);
}

.topbar .themeContainer-dark:focus {
  outline: none;
  border: 2px solid var(--red-500);
}

/* =========================================== */

/* Filters */
.filterbar {
  width: 80%;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  box-sizing: border-box;
  gap: 20px;
  margin-top: 60px;
}

.filterbar .heading {
  font-size: 30px;
  font-weight: 700;
}

.filterbar .filters {
  user-select: none;
  display: flex;
  justify-content: end;
  margin-left: auto;
  gap: 10px;

  /* For not getting highlighting/selection while clicked/pressed */
  -webkit-tap-highlight-color: transparent;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  outline: none;
  -webkit-touch-callout: none;
}

.filterbar .filters .filter {
  font-size: 16px;
  /* height: 30px; */
  padding: 10px 25px;
  border-radius: 50px;
  font-weight: 400;
  cursor: pointer;
}

/* Filterbar light-themed */
.filterbar .heading-light {
  color: var(--neutral-900);
}

.filterbar .filters .filter-light {
  background-color: var(--neutral-0);
  border: 2px solid var(--neutral-200);
}

.filterbar .filters .filter-light:hover {
  opacity: 0.6;
}

.filterbar .filters .filter-light:focus {
  outline: none;
  border: 2px solid var(--red-700);
}

.filterbar .filters .filter-light.active {
  opacity: 1;
  background-color: var(--red-700);
  border: 2px solid var(--red-700);
  color: var(--neutral-0);
}

/* Filterbar dark-themed */
.filterbar .heading-dark {
  color: var(--neutral-0);
}

.filterbar .filters .filter-dark {
  border: 2px solid var(--neutral-600);
  background-color: var(--neutral-700);
  color: var(--neutral-0);
}

.filterbar .filters .filter-dark:hover {
  background-color: var(--neutral-600);
}

.filterbar .filters .filter-dark:focus {
  outline: none;
  border: 2px solid var(--red-500);
}

.filterbar .filters .filter-dark.active {
  background-color: var(--red-500);
  border: 2px solid var(--red-500);
  color: var(--neutral-0);
}

/* =========================================== */

/* Extensions Container */
.extensionsContainer {
  width: 80%;
  margin: 40px 0 50px 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: unset;
  grid-auto-rows: minmax(100px, auto);
  gap: 15px;
  /* background-color: grey; */
}

/* Items */
.item {
  height: 230px;
  padding: 20px;
  display: flex;
  justify-content: space-between;
  flex-direction: column;
  border-radius: 30px;
}

.item-light {
  background-color: var(--neutral-0);
  border: 2px solid var(--neutral-200);
}

.item-dark {
  border: 2px solid var(--neutral-600);
  background-color: var(--neutral-800);
}

/* Top of Extensions Container */
.item .top {
  width: 100%;
  height: 80px;
  display: flex;
  gap: 20px;
  align-items: flex-start;
}

.item .top .info {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.item .top .info h1 {
  font-size: 20px;
}

.item .top .info p {
  font-size: 17px;
}

.item .top .info-light {
  color: black;
}

.item .top .info-dark {
  color: var(--neutral-0);
}

.item .top .info-dark p {
  color: var(--neutral-300);
}

/* Bottom of Extensions Container */
.bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.bottom .removebtn {
  user-select: none;
  padding: 10px 15px;
  border: 2px solid var(--neutral-300);
  font-size: 20px;
  font-weight: 600;
  border-radius: 25px;
  cursor: pointer;

  /* For not getting highlighting/selection while clicked/pressed */
  -webkit-tap-highlight-color: transparent;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  outline: none;
  -webkit-touch-callout: none;
}

.bottom .remove-light {
  color: var(--neutral-900);
}
.bottom .remove-light:hover {
  color: var(--neutral-0);
  background-color: var(--red-700);
  border: 2px solid var(--red-700);
}

.bottom .remove-light:focus {
  border: 2px solid var(--red-700);
}

.bottom .remove-dark {
  color: var(--neutral-300);
}

.bottom .remove-dark:hover {
  color: var(--neutral-900);
  background-color: var(--red-500);
  border: 2px solid var(--red-500);
}

/* Toggle */
.switch {
  user-select: none;
  position: relative;
  width: 60px;
  height: 30px;
  background-color: #ccc;
  border-radius: 30px;
  cursor: pointer;
  transition: background-color 0.4s;

  /* For not getting highlighting/selection while clicked/pressed */
  -webkit-tap-highlight-color: transparent;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  outline: none;
  -webkit-touch-callout: none;
}

.slider {
  position: absolute;
  height: 22px;
  width: 22px;
  left: 4px;
  top: 4px;
  background-color: white;
  border-radius: 50%;
  transition: transform 0.4s;
}

.active1 {
  background-color: var(--red-700);
}
.active1:hover {
  background-color: var(--red-500);
}
.active1:focus {
  border: 2px solid var(--red-700);
}

.active1 .slider {
  transform: translateX(30px);
}

/* Toggle at dark themed */
@media (prefers-color-scheme: dark) {
  .active1 {
    background-color: var(--red-500);
  }
  .active1:hover {
    background-color: var(--red-700);
  }
  .active1:focus {
    border: 2px solid var(--red-700);
  }
}

/* Responsive */
@media only screen and (max-width: 1000px) {
  .extensionsContainer {
    width: 90%;
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: unset;
    grid-auto-rows: minmax(100px, auto);
  }
}

@media only screen and (max-width: 500px) {
  .extensionsContainer {
    width: 90%;
    grid-template-columns: repeat(1, 1fr);
    grid-template-rows: unset;
    grid-auto-rows: minmax(100px, auto);
  }
}
