* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg-color: #F5F1ED;
  --text-color: #2B2B2B;
  --gold: #D4C89A;
}

@font-face {
  font-family: 'Veles';
  src: url('assets/Veles-Regular.otf') format('opentype');
  font-weight: normal;
  font-style: normal;
}

body {
  font-family: Georgia, 'Times New Roman', serif;
  background-color: var(--bg-color);
  color: var(--text-color);
  line-height: 1.6;
  max-width: 1000px;
  margin-inline: auto;
  padding-inline: 20px;
}

header {
  display: flex;
  justify-content: space-between;
  padding-top: 40px;
  gap: 20px;
}

h1 {
  font-family: 'Veles', Georgia, serif;
  font-size: 2.5rem;
  font-weight: normal;
}

.pen-decoration {
  height: 4.5rem;
  width: auto;
}

.bio {
  display: flex;
  gap: 40px;
  align-items: center;
  margin: 60px;

  img {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
  }

  p {
    font-size: 1.1rem;
  }
}

.books {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 60px 40px;
  margin-bottom: 60px;

  .book {
    display: flex;
    gap: 30px;
    align-items: center;
    width: 450px;

    img {
      width: 200px;
      height: 280px;
      object-fit: cover;
      flex-shrink: 0;
    }

    h2 {
      font-size: 1rem;
      font-weight: bold;
    }

    p {
      margin-block: 15px;
    }
  }
}

.buy-button {
  display: inline-block;
  padding: 10px 30px;
  background-color: var(--gold);
  color: var(--text-color);
  text-decoration: none;
  border-radius: 25px;
  font-size: 0.9rem;
  font-weight: bold;
  letter-spacing: 1px;
  transition: opacity 0.3s;

  &:hover {
    opacity: 0.8;
  }
}

footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 40px 20px;
  border-top: 1px solid var(--gold);
}

.social-links {
  display: flex;
  gap: 15px;

  a {
    width: 30px;
    height: 30px;
    opacity: 0.5;
    transition: opacity 0.3s;

    &:hover {
      opacity: 0.7;
    }
  }
}

.contact {
  color: var(--text-color);
  text-decoration: none;

  &:hover {
    text-decoration: underline;
  }
}


@media (max-width: 768px) {
  h1 {
    font-size: 2rem;
  }

  .pen-decoration {
    display: none;
  }

  .bio {
    flex-direction: column;
    gap: 30px;
    text-align: center;

    img {
      width: 250px;
      height: 250px;
    }
  }

  .books .book {
    width: 100%;
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  footer {
    flex-direction: column;
    gap: 20px;
  }
}