/* Reset some default browser styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
  background: #f9f9f9;
  color: #333;
  line-height: 1.6;
  min-height: 100vh;
}

/* Navigation bar */
nav {
  background-color: #2c3e50;
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

nav a {
  color: #ecf0f1;
  text-decoration: none;
  margin-right: 1.5rem;
  font-weight: 600;
  transition: color 0.3s ease;
}

nav a:hover {
  color: #1abc9c;
}

/* Container for page content */
.container {
  width: 95vw;              /* fills 95% of viewport width */
  max-width: none;
  height: 95vh;             /* fills 95% of viewport height */
  margin: auto;             /* centers horizontally & vertically (if parent allows) */
  padding: 20px;            /* internal spacing */
  background: white;        /* visible container */
  border: 1px solid #ccc;   /* subtle border */
  border-radius: 8px;       /* rounded corners */
  box-shadow: 0 2px 6px rgba(0,0,0,0.1); /* subtle shadow */
  box-sizing: border-box;   /* include padding & border in width/height */
  overflow: auto;           /* scroll if content overflows */
}

/* Headings */
h1, h2, h3 {
  margin-bottom: 1rem;
  color: #2c3e50;
}

/* Buttons */
button, input[type="submit"] {
  background-color: #1abc9c;
  border: none;
  padding: 0.6rem 1.2rem;
  color: white;
  font-weight: 600;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

button:hover, input[type="submit"]:hover {
  background-color: #16a085;
}

/* Forms */
form {
  margin-top: 1.5rem;
  max-width: 400px;
}

input[type="text"],
input[type="password"],
select {
  width: 100%;
  padding: 0.5rem;
  margin-bottom: 1rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 1rem;
}

input[type="text"]:focus,
input[type="password"]:focus,
select:focus {
  border-color: #1abc9c;
  outline: none;
}

/* File list */
ul.file-list {
  list-style: none;
  padding-left: 0;
}

ul.file-list li {
  padding: 0.4rem 0;
  border-bottom: 1px solid #ddd;
}

/* Alerts (error messages) */
.alert {
  padding: 1rem;
  background-color: #e74c3c;
  color: white;
  border-radius: 4px;
  margin-bottom: 1rem;
}

/* Footer */
footer {
  text-align: center;
  padding: 1rem 0;
  margin-top: 3rem;
  color: #aaa;
  font-size: 0.9rem;
  border-top: 1px solid #ddd;
}

/* Category grid layout */
.category-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  padding: 20px;
  justify-content: center;
}

/* Individual category card */
.category-card {
  background-color: #f7f7f7;
  border: 1px solid #ccc;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.1);
  width: 200px;
  text-align: center;
  transition: transform 0.2s ease;
}

.category-card:hover {
  transform: scale(1.05);
}

/* Link styling inside card */
.category-card a {
  text-decoration: none;
  color: #333;
  font-weight: bold;
  display: block;
}

.back-link {
  color: #1abc9c;
  text-decoration: none;
  font-weight: 600;
}

.back-link:hover {
  text-decoration: underline;
}

/* PDF viewer styling */
.pdf-frame-wrapper {
  width: 100%;
  height: calc(95vh - 150px); /* leaves room for heading and back link */
  margin-top: 1rem;
}

.pdf-frame {
  width: 100%;
  height: 100%;
  border: none;
  border-radius: 4px;
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.1);
}

/* Style links with .btn class as buttons */
.btn {
  display: inline-block;
  background-color: #1abc9c;
  color: white;
  padding: 0.6rem 1.2rem;
  border-radius: 4px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.btn:hover,
.btn:focus {
  background-color: #16a085;
  outline: none;
}

/* Back button is a <button>, so it’s already styled, but just in case */
.back-btn {
  margin-top: 20px;
}

/* Page title spacing */
.page-title {
  margin-bottom: 1rem;
}

/* File grid for question files - styled like category cards */
.file-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
  padding: 10px 0;
}

/* Individual file card */
.file-card {
  background-color: #f7f7f7;
  border: 1px solid #ccc;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.1);
  width: 200px;
  text-align: center;
  transition: transform 0.2s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.file-card:hover {
  transform: scale(1.05);
}

/* File name link styling */
.file-link {
  font-weight: bold;
  text-decoration: none;
  color: #333;
  margin-bottom: 10px;
  display: block;
  word-wrap: break-word;
}

.file-link:hover {
  color: #1abc9c;
}

/* Container for file action links/buttons */
.file-actions {
  display: flex;
  justify-content: space-around;
  align-items: center;
  font-size: 0.9rem;
  margin-top: 10px;
}

/* Inline view link */
.inline-view-link {
  color: #1abc9c;
  text-decoration: none;
  font-weight: 500;
}

.inline-view-link:hover {
  text-decoration: underline;
}

/* Delete file button styling */
.btn-delete-file {
  background: none;
  border: none;
  color: #e74c3c;
  font-size: 1.1rem;
  cursor: pointer;
  transition: color 0.3s ease;
}

.btn-delete-file:hover {
  color: #c0392b;
}

/* Inline PDF viewer styling */
.pdf-viewer {
  width: 100%;
  height: 80vh;
  border: 1px solid #ccc;
  border-radius: 8px;
  margin-top: 2rem;
}
.board-link,
.topic-link,
.question-link {
  color: #0066cc; /* default blue */
  font-weight: 600;
  text-decoration: none;
  transition: color 0.3s ease;
  display: inline-block;
  padding: 6px 8px;
  border-radius: 4px;
}

.board-link:hover,
.topic-link:hover,
.question-link:hover {
  color: #1abc9c; /* turquoise on hover */
  text-decoration: none;
  outline: none;
}
.support-section {
  background-color: #f4f4f4;
  padding: 2rem;
  border-top: 2px solid #ddd;
  text-align: center;
  border-radius: 12px;
  margin: 3rem auto 0 auto;
  max-width: 700px;
  box-shadow: 0 0 10px rgba(0,0,0,0.05);
}

.support-section h2 {
  margin-bottom: 1rem;
  font-size: 1.6rem;
}

.donation-options h3 {
  margin-top: 1.5rem;
  font-size: 1.2rem;
}

.donation-options p {
  margin-bottom: 1rem;
}


