diff --git a/web_src/css/base.css b/web_src/css/base.css
index 6cc7fe2821..e14b1a549c 100644
--- a/web_src/css/base.css
+++ b/web_src/css/base.css
@@ -1173,10 +1173,8 @@ a.ui.card:hover,
   border-color: var(--color-secondary);
 }
 
-.ui.modal > .close.inside,
-.ui.fullscreen.modal > .close {
-  top: 11px; /* align modal close icon, for example admin notices */
-  color: var(--body-color);
+.ui.modal > .close.inside {
+  color: var(--color-text);
 }
 
 .ui.basic.table > tbody > tr {
diff --git a/web_src/css/code/linebutton.css b/web_src/css/code/linebutton.css
index a2956ffc1f..1012b38ba9 100644
--- a/web_src/css/code/linebutton.css
+++ b/web_src/css/code/linebutton.css
@@ -17,8 +17,8 @@
   left: 0;
   transform: translateX(-70%);
   cursor: pointer;
-
-  &:hover {
-    color: var(--color-primary);
-  }
+}
+
+.code-line-button:hover {
+  color: var(--color-primary);
 }