diff --git a/aha.c b/aha.c
index cdffb11..bae4d2d 100644
--- a/aha.c
+++ b/aha.c
@@ -540,13 +540,6 @@ void printHeader(const struct Options *opts)
printHtml(opts->title ? opts->title : opts->filename ? opts->filename : "stdin");
printf("\n");
- if (opts->css)
- {
- printf("css);
- printf("\">\n");
- }
-
int style_tag = 0;
if (opts->stylesheet)
{
@@ -631,6 +624,14 @@ void printHeader(const struct Options *opts)
if (style_tag)
printf("\n");
+
+ if (opts->css)
+ {
+ printf("css);
+ printf("\">\n");
+ }
+
printf("\n");
if (opts->stylesheet)