/* === General Reset & Base Styles === */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Courier New", Courier, "Lucida Console", monospace, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  background-color: #000;
  color: #00ff66;
  padding: 1em;
  caret-color: #00ff66;
}

/* === Blinking Underscore Cursor === */
@keyframes blink {
  0%, 49% { border-right-color: #00ff66; }
  50%, 100% { border-right-color: transparent; }
}

input, textarea {
  font-family: inherit;
  color: inherit;
  background: transparent;
  border: none;
  border-bottom: 2px solid #00ff66;
  outline: none;
  caret-color: #00ff66;
  padding-right: 0.5em;
  border-right: 1px solid #00ff66;
  animation: blink 1s step-start infinite;
}

/* === Header & Navigation === */
header {
  background-color: #000;
  color: #00ff66;
  padding: 1em 0;
}

nav ul {
  display: flex;
  justify-content: center;
  list-style: none;
  gap: 1em;
}

nav a {
  color: #00ff66;
  text-decoration: none;
}

nav a:hover,
nav a.active {
  text-decoration: underline;
}

/* === Main Content === */
main {
  max-width: 800px;
  margin: 2em auto;
  padding: 0 1em;
}

section {
  margin-bottom: 2em;
}

/* === Headings === */
h1, h2, h3 {
  margin-bottom: 0.5em;
  font-weight: bold;
  font-family: inherit;
}

h1 {
  font-size: 2em;
}

h2 {
  font-size: 1.5em;
}

h3 {
  font-size: 1.2em;
}

/* === Paragraphs & Lists === */
p {
  margin-bottom: 1em;
}

ul {
  padding-left: 1.5em;
  margin-bottom: 1em;
}

/* === Footer === */
footer {
  text-align: center;
  font-size: 0.9em;
  color: #00ff66;
  padding-top: 2em;
  font-family: inherit;
}

/* === Light Mode Toggle Styles === */
.light-toggle {
  position: fixed;
  top: 1em;
  right: 1em;
  background: #00ff66;
  color: #000;
  padding: 0.4em 0.6em;
  border-radius: 0.4em;
  cursor: pointer;
  font-size: 1.2em;
  z-index: 1000;
  transition: all 0.3s ease;
}

/* === Light Mode Theme === */
#light-toggle:checked ~ * {
  background-color: #fefae0 !important; /* pastel yellow */
  color: #aa2222 !important; /* deep pinkish red */
  caret-color: #aa2222 !important;
}

#light-toggle:checked + .light-toggle {
  background-color: #aa2222;
  color: #fefae0;
}

#light-toggle:checked ~ header {
  background-color: #fbeec1;
  color: #aa2222;
}

#light-toggle:checked ~ footer {
  color: #aa4444;
}

nav ul li a.active {
  font-weight: bold;
  text-decoration: underline;
}

body {
  background-color: #111;
  color: #eee;
  transition: background-color 0.3s, color 0.3s;
}

body.light {
  background-color: #fff;
  color: #111;
}

a {
  color: #90cdf4;
}
body.light a {
  color: #0645ad;
}

body, .content, header, footer {
  transition: background-color 0.3s, color 0.3s;
}
