* {
  box-sizing: border-box;
}

body {
  background-color: #0b0c10;
  color: #c5c6c7;
  font-family: 'Courier New', monospace;
  margin: 0;
  padding: 0;
  transition: background-color 0.3s, color 0.3s;
}

header {
  background-color: #1f2833;
  padding: 20px;
  text-align: center;
  box-shadow: 0 2px 10px rgba(0, 255, 0, 0.1);
  position: relative;
}

header h1 {
  color: #66fcf1;
  font-size: 2rem;
  margin: 0;
}

.sub {
  font-size: 1rem;
  color: #45a29e;
  margin-top: 5px;
}

#theme-toggle {
  position: absolute;
  right: 20px;
  top: 25px;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: #66fcf1;
  transition: color 0.3s;
}

#theme-toggle:hover {
  color: #45a29e;
}

nav {
  display: flex;
  flex-wrap: wrap;
  background-color: #1f2833;
  justify-content: center;
  padding: 10px;
  gap: 10px;
}

.tab-button {
  background: none;
  border: none;
  padding: 10px 20px;
  color: #c5c6c7;
  cursor: pointer;
  font-size: 1em;
  border-bottom: 2px solid transparent;
  transition: color 0.3s, border-bottom-color 0.3s;
  flex-grow: 1;
  max-width: 150px;
  text-align: center;
}

.tab-button:hover, .tab-button.active {
  color: #66fcf1;
  border-bottom: 2px solid #66fcf1;
}

main {
  padding: 20px;
  max-width: 900px;
  margin: auto;
}

input, select, button {
  width: 100%;
  padding: 10px;
  margin: 10px 0;
  background-color: #1f2833;
  color: #fff;
  border: 1px solid #45a29e;
  border-radius: 5px;
  font-size: 1em;
  transition: background-color 0.3s, border-color 0.3s;
}

button {
  background-color: #66fcf1;
  color: #0b0c10;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.3s;
}

button:hover {
  background-color: #45a29e;
}

.tab {
  display: none;
}

.tab.active {
  display: block;
}

a {
  color: #66fcf1;
  text-decoration: none;
  word-break: break-word;
}

a:hover {
  text-decoration: underline;
}

footer {
  text-align: center;
  padding: 15px 0;
  background-color: #1f2833;
  font-size: 0.9em;
  color: #45a29e;
  margin-top: 40px;
}

/* Dark/light theme */
body.light-theme {
  background-color: #f0f0f0;
  color: #222;
}

body.light-theme header {
  background-color: #c0cde6;
  box-shadow: 0 2px 10px rgba(0, 100, 255, 0.2);
}

body.light-theme nav {
  background-color: #c0cde6;
}

body.light-theme .tab-button {
  color: #222;
  border-bottom-color: transparent;
}

body.light-theme .tab-button.active,
body.light-theme .tab-button:hover {
  color: #0078d4;
  border-bottom-color: #0078d4;
}

body.light-theme input,
body.light-theme select,
body.light-theme button {
  background-color: #fff;
  color: #222;
  border-color: #0078d4;
}

body.light-theme button {
  background-color: #0078d4;
  color: #fff;
}

body.light-theme button:hover {
  background-color: #005a9e;
}

body.light-theme footer {
  background-color: #c0cde6;
  color: #0078d4;
}

@media (max-width: 600px) {
  nav {
    flex-direction: column;
  }
  
  .tab-button {
    max-width: 100%;
  }
}
