/* Reset and base styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
  font-family: Arial, sans-serif;
  overflow: hidden;
  background-color: #F8F9FA;
  color: #333333;
}

/* Header */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 80px;
  background-color: #003366;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 90%;
  max-width: 1200px;
  flex-wrap: wrap;
}

header h1 {
  font-size: 1.8em;
}

header nav {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

header nav a {
  color: white;
  text-decoration: none;
  font-weight: bold;
}

header nav a:hover {
  text-decoration: underline;
  color: #FFD700;
}

/* Footer */
footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 60px;
  background-color: #003366;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

/* Layout */
.main-layout {
  position: absolute;
  top: 80px;
  bottom: 60px;
  left: 0;
  right: 0;
  display: flex;
  height: calc(100vh - 140px); /* Ensure it's full height minus header and footer */
  background-color: #eaeaea;
  overflow: hidden;
}

/* Sidebar */
.sidebar {
  width: 25%;
  min-width: 200px;  /* Ensuring minimum width for the sidebar */
  max-width: 300px;
  background-color: #f4f4f4;
  border-right: 2px solid #ccc;
  padding: 1em;
  overflow-y: auto;
  word-wrap: break-word;
}

.sidebar h3 {
  margin-bottom: 1em;
  color: #003366;
}

.sidebar nav a {
  display: block;
  margin-top: 10px;
  color: #003366;
  text-decoration: none;
}

.sidebar nav a:hover {
  text-decoration: underline;
  color: #FFD700;
}

/* Content */
.content {
  width: 75%;
  padding: 2em;
  background-color: white;
  overflow-y: auto;
  height: 100%;  /* Ensure the content section occupies full height */
  display: flex;
  flex-direction: column;
  margin-right: 0; /* Fixing the gap on the right */
  flex-grow: 1; /* Ensures it takes all remaining space */
}

/* Blog Post Styling */
.post {
  margin-bottom: 2em;
  padding: 1em;
  border: 1px solid #ccc;
  border-radius: 8px;
  background: #fff;
}

.post h3 {
  font-size: 1.5em;
  margin-bottom: 0.5em;
}

.post .badge {
  margin-left: 5px;
}

/* Form Styling */
form {
  margin-bottom: 2em;
}

form label {
  margin-top: 0.5em;
  display: block;
  font-weight: bold;
}

form input,
form select {
  margin-bottom: 1em;
  width: 100%;
}

.btn-primary {
  background-color: #D9534F;
  border-color: #D9534F;
}

.btn-primary:hover {
  background-color: #c9302c;
  border-color: #ac2925;
}

/* Poll Results */
#poll-results {
  margin-top: 1em;
}

/* Responsive Design for small screens */
@media (max-width: 768px) {
  .main-layout {
    flex-direction: row;  /* Keep the layout as row (side-by-side) on smaller screens */
    height: calc(100vh - 140px);  /* Ensuring it fills the height properly */
  }

  .sidebar {
    width: 30%;  /* Sidebar takes up a bit more space on smaller screens */
    min-width: 120px;
    max-width: 250px;
    border-right: none;
    border-bottom: 2px solid #ccc;
  }

  .content {
    width: 70%;  /* Content takes up the remaining space */
    padding: 1em;
    overflow-y: auto;
    height: 100%;
  }

  header .header-container {
    flex-direction: row;
    justify-content: space-between;
    gap: 0;
  }

  header nav {
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
  }

  .sidebar nav a {
    font-size: 0.9em;
    word-break: break-word;
  }
} 
