:root {
  --mono: "Libertinus Mono", monospace; /* Keeping the original font */
  --text: #eeeeee; /* Soft light gray for readability */
  --place: #6c6c6c; /* Muted gray for placeholders */

  --run: #d16a4a; /* Darker, muted orange */
  --ruh: #e07b5a; /* Slightly lighter orange for hover states */

  --err: #ff5370; /* Vibrant pinkish-red for errors */

  --bg: #121212; /* Cooler black for a sleek, modern feel */
  --border: #ffcb6b; /* Warm yellow for borders */
  --area: #1a1a1a; /* Slightly lighter black for contrast */
}

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--mono);
  display: flex;
  flex-direction: column;
  height: 97.5vh;
  box-sizing: border-box;
  padding: 1rem;
  gap: 1rem;
}

#top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

#top-bar h1 {
  margin: 0;
  font-size: 1.5rem;
}

#top-bar .button-group {
  display: flex;
  gap: 1rem;
}

#main {
  color: var(--text);
  display: flex;
  flex: 1;
  gap: 1rem;
}

#left-panel,
#right-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  max-width: 100%;
}

textarea::placeholder,
input::placeholder {
  color: var(--place);
}

button {
  background-color: var(--run);
  font-family: var(--mono);
  color: var(--text);
  border: none;
  padding: 0.5rem 1rem;
  font-size: 1rem;
  cursor: pointer;
}

button:hover {
  background-color: var(--ruh);
}

.editor-container {
  display: flex;
  width: 100%;
  height: 100%;
  position: relative;
  overflow-y: auto; /* unified vertical scrolling */
}

#line-numbers,
#code-input,
#output {
  background-color: var(--area);
  font-family: var(--mono);
  white-space: pre;
  overflow-x: auto;
  padding: 1rem;
  font-size: 1.1rem;
  overflow-y: hidden;
  resize: none;
  border: none;
  margin: 0;
}

#code-input,
#output {
  color: var(--text);
  flex: 1;
}

#output {
  white-space: pre-wrap;
  word-break: break-word;
}

a,
#line-numbers {
  color: var(--border);
  text-decoration: none;
}

a:hover {
  color: var(--ruh);
}

textarea:focus {
  outline: none;
}

/* Dropdown styling */
#example-dropdown {
  background-color: var(--area);
  color: var(--text);
  font-family: var(--mono);
  border: 1px solid var(--border);
  padding: 0.5rem;
  font-size: 1rem;
  cursor: pointer;
}

#example-dropdown:hover {
  border-color: var(--ruh); /* Slightly lighter border on hover */
}

#example-dropdown:focus {
  outline: none;
  border-color: var(--ruh); /* Highlight border when focused */
}

#example-dropdown option {
  background-color: var(--area);
  color: var(--text);
  font-family: var(--mono);
}
