Good day. I can not understand why it does not work.
The style for h1 specifically added to just check whether the file is "connected" or not. On h1 style is applied.
At the same time, if you apply the style directly in html , the style works. Tried input or input[type="text"]
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Формы</title> <link rel="stylesheet" href="/form.css" type="text/css"> </head> <body> <form action="form1.php" method="post"> <input type="text" class="test" name="test" placeholder="Введите текст" autofocus> <input type="submit" value="Добавить"> </form> <h1>Hello</h1> </body> </html> <style> input{ width: 100%; } h1{ color: green; } </style>