:root {
  --font-main: "Roboto", system-ui, sans-serif;
  --background-nav: hsl(222, 47%, 11%);
  --light-text-color: white;
  --nav-link-text-color: #cbd5e1;
  --link-text-color: rgb(138, 43, 226);
}

::selection {
  background-color: darkorchid;
  color: white;
}

* {
  box-sizing: border-box;
}

body {
  font-family: var(--font-main);
  min-height: 100vh;
  min-height: 100dvh;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 700;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 100px auto 50px;
  padding: 0 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: fixed;
  top: 0;
  width: 100%;
  height: 64px;
  padding: 12px;
  background-color: var(--background-nav);
  color: var(--light-text-color);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
  z-index: 10;
}

.footer {
  position: relative;
  bottom: 0;
  width: 100%;
  height: 64px;
  background-color: var(--background-nav);
  color: var(--light-text-color);
}

.header__logo {
  font-size: 20px;
  font-weight: 700;
}

.header__nav {
  display: flex;
  gap: 24px;
}

.nav__link {
  text-decoration: none;
  color: var(--nav-link-text-color);
  font-size: 1rem;
  transition: color 0.2s ease;
}

.nav__link:hover {
  color: var(--light-text-color);
}

.title {
  text-align: center;
}

.paragraph {
  width: 60ch;
}

p {
  width: 100%;
  text-indent: 2em;
  font-size: 1.25rem;
  font-weight: 400;
}

.link {
  font-size: 1.2rem;
  font-weight: 600;
  text-decoration: none;
}
.link:hover {
  color: var(--link-text-color);
}

.image-wrapper {
  text-align: center;
  margin: 20px 0;
  padding: 10px;
  background-color: white;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  border-radius: 12px;
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

.image-wrapper:hover {
  transform: scale(1.03);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
}

.image {
  height: 500px;
  object-fit: cover;
}

.grid-block-wrapper {
  width: 600px;
  margin: 40px auto;
  padding: 15px;
  background-color: white;
  border: 1px solid #ccc;
}

.grid-block-title {
  text-align: center;
  margin-bottom: 15px;
}

.grid-block {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.grid-card {
  background-color: #e8f0fe;
  padding: 10px;
  border: 1px solid #bbb;
  text-align: center;
}

.grid-card h4 {
  margin: 5px 0;
}

.grid-card span {
  font-size: 14px;
  margin: 0;
}

.grid-card.big {
  grid-column: 1 / 4;
  background-color: #c5d9ff;
}

.go-to-demo {
  position: relative;
  margin-top: 25px;
  background-image: url("../assets/imgs/cat2.avif");
  background-position: center;
  background-color: white;
  width: 600px;
  height: 494px;
}

.link-to-demo {
  position: absolute;
  top: 140px;
  left: 145px;
}

.list {
  width: 300px;
  height: 110px;
  overflow: auto;
}

.cards-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 25px;
}

.card-loader {
  position: relative;
  overflow: hidden;
}

.loader {
  position: absolute;
  inset: 0;
  background-color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  animation: hideLoader 3s forwards;
}

.loader::before {
  content: "";
  width: 40px;
  height: 40px;
  border: 4px solid #b7b7b7;
  border-top: 4px solid #9d00ff;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

.card-content {
  opacity: 0;
  animation: showContent 3s forwards;
  animation-delay: 3s;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes hideLoader {
  to {
    opacity: 0;
    visibility: hidden;
  }
}

@keyframes showContent {
  to {
    opacity: 1;
  }
}

@font-face {
  font-family: "Roboto";
  src: url("../assets/fonts/Roboto-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Roboto";
  src: url("../assets/fonts/Roboto-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Roboto";
  src: url("../assets/fonts/Roboto-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
