Having issue in stying HTML Code

Tell us what’s happening:
Describe your issue in detail here.
what does this mean-" You should only use an h2 element selector to change the font." i have already used h2 in styles before setting any styles for h2 heading. Am i doing something wrong?

  **Your code so far**

<link href="https://fonts.googleapis.com/css?family=Lobster" rel="stylesheet" type="text/css">


h2 {
  color: red;
  font-family: Lobster;

p {
  font-size: 16px;
  font-family: monospace;

<h2 class="red-text">CatPhotoApp</h2>
<p class="red-text">Click here to view more <a href="#">cat photos</a>.</p>

<a href="#"><img src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg" alt="A cute orange cat lying on its back."></a>

  <p>Things cats love:</p>
    <li>cat nip</li>
    <li>laser pointers</li>
  <p>Top 3 things cats hate:</p>
    <li>flea treatment</li>
    <li>other cats</li>

<form action="https://freecatphotoapp.com/submit-cat-photo">
  <label><input type="radio" name="indoor-outdoor" checked> Indoor</label>
  <label><input type="radio" name="indoor-outdoor"> Outdoor</label><br>
  <label><input type="checkbox" name="personality" checked> Loving</label>
  <label><input type="checkbox" name="personality"> Lazy</label>
  <label><input type="checkbox" name="personality"> Energetic</label><br>
  <input type="text" placeholder="cat photo URL" required>
  <button type="submit">Submit</button>
  **Your browser information:**

User Agent is: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/99.0.4844.82 Safari/537.36

Challenge: Import a Google Font

Link to the challenge:

Hi @MohitJain,

Your code is good, the test doesn’t pass simply because you added a property they didn’t ask you to use for the h2: color: red

thanks brother… i got stuck here i didn’t thought that it never asked me to set color property. glad to talk you.

You’re welcome @MohitJain, the most important is that actually you were not wrong about what you did and it is good that you go further that what is asked. But, to validate, you must submit what they ask you. Good luck with the next challenges :slight_smile:

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.