.board-hero {
  background:
    linear-gradient(135deg, #142246 0%, #10131d 58%, #0b0e16 100%);
  color: #fff;
  position: relative;
  overflow: hidden;
}

.board-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 16% 20%, rgba(63,111,224,.38), transparent 34%),
    radial-gradient(circle at 82% 34%, rgba(76,128,255,.2), transparent 28%),
    radial-gradient(rgba(255,255,255,.075) 1px, transparent 1px);
  background-size: auto, auto, 22px 22px;
  pointer-events: none;
}

.board-hero::after {
  content: "COMMUNITY";
  position: absolute;
  right: 6%;
  top: 50%;
  transform: translateY(-50%);
  font-size: clamp(56px, 8vw, 138px);
  font-weight: 900;
  letter-spacing: -5px;
  color: #fff;
  opacity: .045;
  white-space: nowrap;
  pointer-events: none;
}

.board-hero-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding-top: 70px;
  padding-bottom: 64px;
  padding-left: 30px;
}

.board-hero-inner::before {
  content: "";
  position: absolute;
  left: 0;
  top: 64px;
  width: 5px;
  height: calc(100% - 128px);
  background: linear-gradient(180deg, #4f7cff, #8fb0ff);
  box-shadow: 0 0 26px rgba(79,124,255,.55);
}

.board-hero h1 {
  font-size: clamp(34px,4vw,50px);
  font-weight: 900;
  letter-spacing: -1px;
  margin-bottom: 12px;
  text-shadow: 0 12px 30px rgba(0,0,0,.28);
}

.board-hero p {
  font-size: 15px;
  line-height: 1.7;
  color: rgba(255,255,255,.74);
  max-width: 560px;
}

.board-hero-card {
  width: 280px;
  border: 1px solid rgba(255,255,255,.16);
  background: rgba(255,255,255,.075);
  backdrop-filter: blur(10px);
  border-radius: 18px;
  padding: 22px;
  box-shadow: 0 20px 55px rgba(0,0,0,.28);
}

.board-hero-card strong {
  display: block;
  font-size: 13px;
  letter-spacing: 2px;
  margin-bottom: 8px;
  color: #fff;
}

.board-hero-card span {
  display: block;
  font-size: 13px;
  color: rgba(255,255,255,.7);
  line-height: 1.6;
}

.board-page {
  background: #fff;
}

.board-layout {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.board-panel,
.post-detail-card {
  border: 1px solid #e5eaf3;
  background: #fff;
  border-radius: 18px;
  padding: 24px;
  box-shadow: 0 18px 44px rgba(15,17,26,.07);
}

.board-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.board-panel-head h2 {
  font-size: 21px;
  font-weight: 900;
  letter-spacing: -.4px;
}

.board-panel-head p {
  font-size: 13px;
  color: var(--muted);
  margin-top: 5px;
}

.board-input,
.board-textarea,
.reply-textarea {
  width: 100%;
  border: 1px solid #dce3ef;
  background: #fafbff;
  border-radius: 12px;
  padding: 13px 14px;
  font-family: var(--font);
  font-size: 14px;
  color: var(--ink);
  outline: none;
  transition: border-color .2s, box-shadow .2s, background .2s;
}

.board-input:focus,
.board-textarea:focus,
.reply-textarea:focus {
  border-color: var(--blue);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(63,111,224,.1);
}

.board-textarea {
  min-height: 140px;
  resize: vertical;
  margin-top: 10px;
  line-height: 1.7;
}

.board-submit,
.board-refresh,
.board-back,
.board-delete,
.reply-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  font-weight: 900;
  font-size: 13px;
  padding: 11px 18px;
  transition: .18s;
}

.board-submit,
.reply-submit {
  background: var(--blue);
  color: #fff;
}

.board-submit {
  margin-top: 14px;
}

.board-submit:hover,
.reply-submit:hover {
  background: #111827;
}

.board-submit:disabled {
  opacity: .55;
  cursor: not-allowed;
}

.board-refresh,
.board-back {
  background: #fff;
  border: 1.5px solid #d7deec;
  color: var(--ink);
}

.board-refresh:hover,
.board-back:hover {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}

.board-delete {
  background: #fff0f0;
  border: 1px solid #fecaca;
  color: #dc2626;
}

.board-delete:hover {
  background: #dc2626;
  color: #fff;
}

.board-login-box {
  text-align: center;
  padding: 34px 20px;
}

.board-login-box h2 {
  font-size: 21px;
  font-weight: 900;
  margin-bottom: 8px;
}

.board-login-box p {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 4px;
}

.board-login-link {
  width: auto;
  text-decoration: none;
}

.image-upload-box {
  border: 1px dashed #c8d2ea;
  background: #f7f9ff;
  border-radius: 14px;
  padding: 14px;
  margin-top: 12px;
}

.image-upload-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--blue);
  color: var(--blue);
  background: #fff;
  border-radius: 9px;
  padding: 9px 13px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
  margin-right: 8px;
}

.image-upload-btn:hover {
  background: var(--blue);
  color: #fff;
}

.image-upload-box > span {
  font-size: 12px;
  color: var(--muted);
}

.image-preview-list {
  display: flex;
  gap: 9px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.image-preview-item {
  position: relative;
  width: 92px;
  height: 68px;
  border-radius: 8px;
  overflow: visible;
}

.image-preview-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--line);
}

.image-preview-remove {
  position: absolute;
  right: -7px;
  top: -7px;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: #ef4444;
  color: #fff;
  font-size: 12px;
}

.image-upload-progress {
  display: none;
  margin-top: 9px;
  font-size: 12px;
  color: var(--blue);
  font-weight: 800;
}

.post-list {
  display: flex;
  flex-direction: column;
  border-top: 1px solid var(--line);
}

.post-item {
  display: grid;
  grid-template-columns: 52px minmax(0,1fr) 120px 120px;
  gap: 12px;
  align-items: center;
  padding: 16px 8px;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  transition: background .18s, transform .18s;
}

.post-item:hover {
  background: #f7f9ff;
}

.post-num {
  font-size: 12px;
  font-weight: 900;
  color: #a0a5b6;
  text-align: center;
}

.post-subject {
  font-size: 14px;
  font-weight: 900;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.post-has-img,
.reply-cnt {
  margin-left: 6px;
  color: var(--blue);
  font-size: 12px;
  font-weight: 900;
}

.post-nick,
.post-date {
  font-size: 12px;
  color: var(--muted);
  text-align: right;
  white-space: nowrap;
  font-weight: 700;
}

.board-empty,
.board-loading {
  text-align: center;
  padding: 40px 12px;
  color: var(--muted);
  font-size: 13px;
}

.board-loading {
  color: var(--blue);
  font-weight: 900;
  letter-spacing: 1px;
}

.post-detail {
  display: none;
}

.post-detail.active {
  display: block;
}

.post-detail-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 16px;
}

.post-detail h2 {
  font-size: 26px;
  font-weight: 900;
  letter-spacing: -.5px;
  margin-bottom: 8px;
}

.post-detail-meta {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 18px;
}

.post-detail-body {
  min-height: 150px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 24px 0;
  font-size: 15px;
  line-height: 1.85;
  color: #333;
  white-space: pre-wrap;
}

.post-images {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.post-image-wrap {
  cursor: pointer;
}

.post-image {
  width: 180px;
  height: 135px;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid var(--line);
  transition: opacity .18s, transform .18s;
}

.post-image:hover {
  opacity: .84;
  transform: translateY(-2px);
}

.reply-section {
  margin-top: 24px;
}

.reply-title {
  font-size: 14px;
  font-weight: 900;
  margin-bottom: 12px;
}

.reply-item {
  display: grid;
  grid-template-columns: 110px minmax(0,1fr) 116px auto;
  gap: 12px;
  align-items: start;
  border: 1px solid var(--line);
  background: #fafbff;
  border-radius: 14px;
  padding: 14px;
  margin-bottom: 8px;
}

.reply-nick {
  font-size: 12px;
  font-weight: 900;
  color: var(--blue);
}

.reply-body {
  font-size: 13px;
  line-height: 1.7;
  color: #333;
  white-space: pre-wrap;
}

.reply-date {
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
}

.reply-del {
  font-size: 11px;
  color: #dc2626;
  cursor: pointer;
  font-weight: 900;
}

.reply-write {
  display: flex;
  gap: 10px;
  margin-top: 14px;
  align-items: stretch;
}

.reply-textarea {
  min-height: 62px;
  resize: vertical;
}

.reply-submit {
  min-width: 82px;
}

.reply-login {
  font-size: 13px;
  color: var(--muted);
  background: #f7f9ff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 13px;
}

.reply-login a {
  color: var(--blue);
  font-weight: 900;
}

.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0,0,0,.9);
  align-items: center;
  justify-content: center;
  padding: 22px;
}

.lightbox.open {
  display: flex;
}

.lightbox img {
  max-width: 92vw;
  max-height: 90vh;
  object-fit: contain;
}

.lightbox-close,
.lightbox-nav {
  position: absolute;
  background: rgba(255,255,255,.12);
  color: #fff;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 10px;
}

.lightbox-close {
  right: 22px;
  top: 22px;
  width: 42px;
  height: 42px;
  font-size: 20px;
}

.lightbox-nav {
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 60px;
  font-size: 34px;
}

.lightbox-prev {
  left: 18px;
}

.lightbox-next {
  right: 18px;
}

@media (max-width: 980px) {
  .board-hero-inner {
    padding-top: 48px;
    padding-bottom: 48px;
  }

  .board-hero-card {
    display: none;
  }

  .board-hero::after {
    right: 24px;
    font-size: 82px;
  }

  .post-item {
    grid-template-columns: 42px minmax(0,1fr);
    gap: 8px;
  }

  .post-nick,
  .post-date {
    display: none;
  }

  .reply-item {
    grid-template-columns: 1fr;
  }

  .reply-date {
    text-align: left;
  }

  .reply-write {
    flex-direction: column;
  }

  .post-image {
    width: 140px;
    height: 105px;
  }
}

@media (max-width: 560px) {
  .board-hero-inner {
    padding-top: 52px;
    padding-bottom: 52px;
    padding-left: 22px;
  }

  .board-hero-inner::before {
    top: 48px;
    height: calc(100% - 96px);
  }

  .board-hero::after {
    content: "BOARD";
    right: 10px;
    top: 58%;
    font-size: 60px;
    opacity: .04;
  }

  .board-panel,
  .post-detail-card {
    padding: 16px;
    border-radius: 12px;
  }

  .board-hero h1 {
    font-size: 32px;
  }

  .board-hero p {
    font-size: 13px;
  }

  .post-subject {
    font-size: 13px;
  }

  .image-upload-box > span {
    display: block;
    margin-top: 8px;
  }

  .post-image {
    width: 46vw;
    height: 34vw;
  }

  .lightbox-nav {
    display: none;
  }
}