/* ===== 목록 ===== */

.notice-search-bar {
    display: flex;
    justify-content: flex-end;
    align-items: stretch;
    gap: 10px;
    max-width: 420px;
    margin: 0 0 24px auto;
}

.notice-search-bar input {
    min-width: 0;
    border-radius: 999px;
    padding-left: 18px;
}

.notice-search-bar button {
    flex-shrink: 0;
    white-space: nowrap;
}

.notice-list-table th {
    background: #f9fafb;
    color: #6b7280;
    font-size: 12.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    border-bottom: 1px solid #e5e7eb;
    padding: 14px 16px;
}

.notice-list-table td {
    padding: 16px;
    font-size: 14.5px;
    border-color: #f1f2f4;
}

.notice-list-table tbody tr:hover {
    background: #f8fafc;
}

.notice-list-link {
    color: #111827;
    text-decoration: none;
    font-weight: 500;
}

.notice-list-link:hover {
    color: #2563eb;
}

.notice-badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 9px;
    border-radius: 999px;
    margin-right: 8px;
    vertical-align: middle;
}

.notice-badge-pin {
    background: #eff6ff;
    color: #2563eb;
}

.notice-badge-new {
    background: #fef2f2;
    color: #ef4444;
}

/* Pagination */
.notice-pagination {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 32px;
}

.notice-page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid #e5e7eb;
    color: #374151;
    text-decoration: none;
    font-size: 13.5px;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.notice-page-link.active,
.notice-page-link:hover {
    background: #2563eb;
    border-color: #2563eb;
    color: #fff;
}

.notice-page-ellipsis {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    color: #9ca3af;
}

/* ===== 상세 ===== */

.notice-detail-card {
    max-width: 900px;
    margin-inline: auto;
}

.notice-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 20px;
    margin-bottom: 30px;
}

.notice-detail-title {
    font-size: 22px;
    font-weight: 700;
    line-height: 1.5;
    margin: 0;
    flex: 1 1 auto;
    min-width: 0;
}

.notice-header span {
    flex: 0 0 auto;
    white-space: nowrap;
    padding-top: 6px;
    color: #9ca3af;
    font-size: 14px;
}

.notice-body {
    min-height: 200px;
    line-height: 1.8;
    overflow-wrap: break-word;
}

.notice-body img {
    max-width: 100%;
    height: auto;
}

.notice-attachment {
    margin-top: 40px;
    padding: 20px;
    background: #f8fafc;
    border-radius: 10px;
}

.notice-attachment h4 {
    font-size: 15px;
    font-weight: 700;
    margin-bottom: 12px;
}

.file-preview {
    max-width: 320px;
    display: block;
    margin-bottom: 12px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
}

/* 이전/다음 */
.notice-nav {
    max-width: 900px;
    margin: 24px auto 0;
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.notice-nav a {
    padding: 10px 20px;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    color: #374151;
    text-decoration: none;
    font-size: 13.5px;
    font-weight: 600;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.notice-nav a:hover {
    background: #2563eb;
    border-color: #2563eb;
    color: #fff;
}

.notice-nav a.list-btn {
    background: #111827;
    border-color: #111827;
    color: #fff;
}

.notice-nav a.list-btn:hover {
    background: #2563eb;
    border-color: #2563eb;
}

/* ===============================
   Responsive
================================ */
@media (max-width: 768px) {
    .notice-search-bar {
        max-width: none;
    }

    .notice-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .notice-list-table th:first-child,
    .notice-list-table td:first-child {
        display: none;
    }

    .notice-list-table th,
    .notice-list-table td {
        padding: 12px 10px;
        font-size: 13.5px;
    }

    .notice-nav {
        flex-wrap: wrap;
    }
}
