body {
  margin: 0;
  font-family: Georgia, serif;
  background: #0f0f0f;
  color: #eaeaea;
  display: flex;
  justify-content: center;
  padding: 30px;
}

.box {
  width: 800px;
  background: #1a1a1a;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.6);
}

.logo {
  text-align: center;
  margin-bottom: 20px;
  font-size: 90px;
  font-weight: bold;
  letter-spacing: 3px;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 15px 0;
}

/* NAV BUTTONS */
.nav button {
  background: #333;
  color: white;
  border: none;
  font-size: 40px;
  padding: 10px 20px;
  border-radius: 6px;
  cursor: pointer;
  transition: 0.2s;
}

.nav button:hover {
  background: #555;
}

/* 🔴 IMPORTANT: SELECTED STATE FIXED */
.nav button.selected {
  background: rgb(0, 0, 0) !important;
  color: white !important;
  font-weight: bold;
  transform: scale(1.05);
}

/* CONTENT LINES */
.line {
  display: block;
  margin: 12px 0;
  padding: 12px 14px;
  background: #222;
  border-left: 4px solid #555;
  border-radius: 6px;
  font-size: 45px;
  line-height: 1.8;
}

/* MODAL */
#modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.85);
  justify-content: center;
  align-items: center;
}

#modalContent {
  background: #111;
  padding: 20px;
  border-radius: 10px;
  width: 500px;
  border: 1px solid #333;
}

#modal textarea {
  width: 100%;
  height: 150px;
  font-size: 18px;
  font-family: Georgia, serif;

  background: #1a1a1a;
  color: #eaeaea;

  border: 1px solid #444;
  border-radius: 6px;
  outline: none;
}

#modal button {
  margin-top: 10px;
  font-size: 20px;
  padding: 10px;

  border: none;
  border-radius: 6px;
  cursor: pointer;

  background: #333;
  color: white;
}

#modal button:hover {
  background: #555;
}

#modal button:first-of-type {
  background: #2ecc71;
  color: black;
}

/* fallback selected (if used outside nav) */
.selected {
  background: rgb(243, 185, 185) !important;
  color: white !important;
}

.editing {
  width: 100%;
  min-height: 400px;   /* 👈 gives more editing space */
  font-size: 45px;
  font-family: Georgia, serif;

  background: #000000;
  color: #eaeaea;

  border: 1px solid #444;
  padding: 14px;
  border-radius: 6px;

  outline: none;

  line-height: 1.6;    /* 👈 better readability while editing */
  resize: vertical;    /* 👈 user can drag height */
}