body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  background: 
    linear-gradient(rgba(0,0,0,0.3), rgba(0,0,0,0.3)),
    url("images/venusian_cities.jpeg") center / cover no-repeat fixed;
  color: #333;
  display: flex;
}

header {
  background: #222;
  color: white;
  padding: 20px;
  text-align: center;
}

section {
  width: 90%;
  max-width: 700px;
  margin: 20px auto;
  padding: 20px;
  color: #eee;
  background: rgba(164, 143, 44, 0.18);
  border-radius: 10px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

h2 {
  border-bottom: 2px solid #ddd;
  padding-bottom: 5px;
}

ul {
  list-style: none;
  padding: 0;
}

li {
  margin: 8px 0;
  display: inline-block;
  background: rgba(191, 178, 116, 0.45);
  color: rgba(191, 178, 116, 0.45);
}

.counter button {
  margin: 5px;
  padding: 10px 15px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}

.like {
  background: #4CAF50;
  color: white;
}

.dislike {
  background: #f44336;
  color: white;
}

footer {
  text-align: center;
  padding: 20px;
  background: #222;
  color: white;
}

textarea {
  width: 100%;
  height: 100px;
  margin-top: 10px;
  box-sizing: border-box;
}

input, button {
  margin-top: 10px;
  padding: 10px;
  max-width: 100%;
  box-sizing: border-box;
}

.story-text {
  white-space: pre-wrap;
  line-height: 1.8;
}

/* Sidebar */
.sidebar {
  position: fixed;
  left: 0;
  top: 0;
  width: 150px;
  height: 100%;
  background: rgba(20, 20, 30, 0.9);
  color: white;
  padding: 20px;
  z-index: 100;
  transition: transform 0.3s ease;
}

.sidebar ul {
  list-style: none;
  padding: 0;
}

.sidebar li {
  margin: 10px 0;
}

.sidebar a {
  color: #ccc;
  text-decoration: none;
}

.sidebar a:hover {
  color: white;
}

/* Main content shifted right */
.content {
  margin-left: 190px;
  width: 100%;
}

.comments-section {
  margin-top: 40px;
  border-top: 1px solid rgba(255,255,255,0.2);
  padding-top: 20px;
}

.comments-section h2 {
  color: #f0d080;
  margin-bottom: 20px;
}

.comment-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 30px;
}

.comment-form input,
.comment-form textarea {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 8px;
  padding: 10px;
  color: #eee;
  font-family: Arial, sans-serif;
  font-size: 0.95rem;
  width: 100%;
  box-sizing: border-box;
  margin: 0;
}

.comment-form textarea {
  height: 90px;
  resize: vertical;
}

.comment-form button {
  align-self: flex-start;
  background: #f0d080;
  color: #222;
  border: none;
  border-radius: 8px;
  padding: 10px 20px;
  cursor: pointer;
  font-weight: bold;
  margin: 0;
}

.comment-form button:hover {
  background: #e0c060;
}

.comment {
  background: rgba(255,255,255,0.06);
  border-radius: 8px;
  padding: 15px;
  margin-bottom: 12px;
}

.comment .comment-author {
  font-weight: bold;
  color: #f0d080;
  margin-bottom: 5px;
  font-size: 0.9rem;
}

.comment .comment-date {
  font-size: 0.75rem;
  color: #888;
  margin-bottom: 8px;
}

.comment .comment-body {
  color: #ddd;
  line-height: 1.6;
}

/* Mobile */
@media (max-width: 600px) {
  .comment-form button {
    width: 100%;
  }
}

/* ── MOBILE ── */
@media (max-width: 600px) {

  body {
    flex-direction: column;
    background-attachment: scroll; /* fixed bg causes issues on mobile */
    
  }

  /* Hide sidebar off-screen on mobile */
  .sidebar {
    position: relative;
    width: 100%;
    height: auto;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 10px 15px;
    box-sizing: border-box;
  }

  .sidebar ul {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0;
  }

  .sidebar li {
    margin: 0;
  }

  /* Remove the left margin since sidebar is no longer on the side */
  .content {
    margin-left: 0;
    width: 100%;
    box-sizing: border-box;
  }

  section {
    width: 92%;
    margin: 15px auto;
    padding: 15px;
  }

  .counter button {
    width: 100%;
    margin: 5px 0;
  }
}