-2

I have this weird border all around my header:

Image

It's written in html and css, the relevant source code is below: HTML:

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Killa Media</title>
    <link rel="stylesheet" href="style.css">
</head>
<body>
    <header>
        <a href="#"><img class="logo" src="https://killa-media.com/wp-content/uploads/2022/11/Killa_logo.png" alt="Killa Media icon logo"> </a>
        <nav>
            <ul class="nav-links"> 
                <li><a href="/about/" class="nav-item">ABOUT</a></li>
                <li><a href="/services/" class="nav-item">SERVICES</a></li>
                <li><a href="/contact/" class="nav-item">GET IN TOUCH</a></li>
            </ul>
        </nav>  
    </header>

CSS: Image

Any ideas? Thanks.

I've tried using -10 margins, but that didn't work properly. I thought 100% width would fix this, it didn't.

Chris Barr
  • 29,851
  • 23
  • 95
  • 135
Milo
  • 1
  • 1

2 Answers2

1

Using CSS Reset

*{
    margin: 0;
    padding: 0;
 }

This will remove padding and margin from all elements.

RKS
  • 1
  • 3
0

It seems you probably have either too much margin or padding. Here is what I recommend:

body{
margin: 0px;
}
JSman225
  • 96
  • 1
  • 16