/* ============================================================
   GIST BMSE 교수 게시판 - Custom Styles
   ============================================================ */

/* Red theme – override Bootstrap primary */
:root {
  --bs-primary:         #db2416;
  --bs-primary-rgb:     219, 36, 22;
  --bs-link-color:      #db2416;
  --bs-link-color-rgb:  219, 36, 22;
  --bs-link-hover-color:#b81e10;
}

.btn-primary {
  --bs-btn-bg:                #db2416;
  --bs-btn-border-color:      transparent;
  --bs-btn-hover-bg:          #b81e10;
  --bs-btn-hover-border-color:transparent;
  --bs-btn-active-bg:         #9a1a0e;
  --bs-btn-active-border-color:transparent;
  --bs-btn-focus-shadow-rgb:  219, 36, 22;
}

.bg-primary { background-color: #db2416 !important; }
.text-primary { color: #db2416 !important; }
.border-primary { border-color: transparent !important; }
.navbar-dark.bg-primary { background-color: #db2416 !important; }

/* Global */
body {
  background-color: #f8f9fa;
  font-family: 'Apple SD Gothic Neo', 'Malgun Gothic', -apple-system,
    BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main.container {
  flex: 1;
}

/* Navbar brand */
.navbar-brand {
  font-size: 1.15rem;
  letter-spacing: -0.3px;
}

/* Cards */
.card {
  border-radius: 0.6rem;
}

.card-header {
  border-radius: 0.6rem 0.6rem 0 0 !important;
}

/* ============================================================
   Board list table
   ============================================================ */
.board-table th,
.board-table td {
  padding: 0.75rem 1rem;
  vertical-align: middle;
}

.board-table .col-num   { width: 60px; }
.board-table .col-author{ width: 100px; }
.board-table .col-date  { width: 110px; }
.board-table .col-views { width: 70px; }
.board-table .col-attach{ width: 50px; }

.post-title-link {
  font-size: 1.05rem;
}
.post-title-link:hover {
  color: #db2416 !important;
  text-decoration: underline !important;
}

/* ============================================================
   Post detail
   ============================================================ */
.post-content {
  line-height: 1.8;
  font-size: 1.05rem;
  word-break: break-word;
}

.post-content img {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
  margin: 0.5em 0;
}

.file-download-link {
  font-size: 0.875rem;
  display: inline-flex;
  align-items: center;
  gap: 2px;
}
.file-download-link:hover span:first-of-type {
  text-decoration: underline;
}

/* ============================================================
   Comments
   ============================================================ */
.comment-content {
  font-size: 1rem;
  line-height: 1.7;
  white-space: pre-wrap;
  word-break: break-word;
}

/* ============================================================
   Auth forms
   ============================================================ */
.card-body .form-control {
  border-radius: 0.4rem;
}

/* ============================================================
   Admin table
   ============================================================ */
.table .badge {
  font-size: 0.75rem;
}

/* ============================================================
   Pagination
   ============================================================ */
.page-link {
  color: #db2416;
  border-radius: 0.4rem !important;
}
.page-item.active .page-link {
  background-color: #db2416;
  border-color: #db2416;
}

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  border-radius: 0.4rem;
}

/* ============================================================
   Footer
   ============================================================ */
.footer {
  font-size: 0.82rem;
}

/* ============================================================
   Mobile post meta subtext
   ============================================================ */
.post-meta-mobile {
  font-size: 0.78rem;
  line-height: 1.4;
}

/* ============================================================
   Responsive tweaks
   ============================================================ */
@media (max-width: 767px) {
  .board-table .col-num {
    width: 36px;
    font-size: 0.78rem;
    padding-left: 0.5rem;
    padding-right: 0.25rem;
  }

  .board-table td,
  .board-table th {
    padding: 0.6rem 0.5rem;
  }

  h4.fw-bold {
    font-size: 1.05rem;
  }
}
