/* Notice & Board Page Specifics */

.notice-hero {
    background: url('../assets/notice_hero.png') no-repeat center center/cover;
    height: 50vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.notice-hero .hero-overlay {
    background: linear-gradient(to bottom, rgba(5, 5, 5, 0.2) 0%, rgba(5, 5, 5, 1) 100%);
}

.notice-layout {
    display: grid;
    grid-template-columns: 3fr 1fr;
    gap: 40px;
    align-items: start;
}

/* Notice Card Page Style */
.notice-card-page {
    background: #1a1a1a;
    border-radius: 10px;
    overflow: hidden;
    transition: var(--transition);
    border: 1px solid #333;
}

.notice-card-page:hover {
    transform: translateY(-5px);
    border-color: var(--primary-red);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
}

.notice-img-wrap {
    height: 180px;
    overflow: hidden;
}

.notice-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.notice-card-page:hover .notice-img-wrap img {
    transform: scale(1.05);
}

.notice-content {
    padding: 20px;
}

.notice-tags {
    display: flex;
    gap: 5px;
    margin-bottom: 15px;
}

.notice-tags .tag {
    background: transparent;
    border: 1px solid #555;
    color: #ccc;
    font-size: 0.7rem;
    padding: 2px 10px;
    border-radius: 20px;
}

/* Notice Excerpt for Cards */
.notice-excerpt {
    color: #bbb;
    font-size: 0.9rem;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.5;
}

.notice-content h3 {
    font-size: 1.1rem;
    margin-bottom: 10px;
    line-height: 1.4;
    min-height: 3rem;
}

.notice-content .date {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Sidebar */
.notice-sidebar {
    background: #0f0f0f;
    padding: 30px;
    border-radius: 20px;
    border: 1px solid #333;
}

.sidebar-desc {
    color: #ccc;
    font-size: 0.95rem;
    line-height: 1.8;
}

/* Radio Button Custom Styling */
.radio-container {
    display: block;
    position: relative;
    padding-left: 35px;
    margin-bottom: 15px;
    cursor: pointer;
    font-size: 0.95rem;
    color: white;
    user-select: none;
}

.radio-container input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.checkmark {
    position: absolute;
    top: 0;
    left: 0;
    height: 20px;
    width: 20px;
    background-color: transparent;
    border: 2px solid #555;
    border-radius: 50%;
}

.radio-container:hover input~.checkmark {
    border-color: #0088cc;
}

.radio-container input:checked~.checkmark {
    border-color: #0088cc;
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.radio-container input:checked~.checkmark:after {
    display: block;
}

.radio-container .checkmark:after {
    top: 3px;
    left: 3px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #0088cc;
}

/* Search Box */
.search-box {
    position: relative;
    margin-top: 30px;
}

.search-box input {
    width: 100%;
    background: #000;
    border: 1px solid #333;
    border-radius: 30px;
    padding: 12px 20px 12px 40px;
    color: white;
    font-family: inherit;
    outline: none;
}

.search-box input:focus {
    border-color: #0088cc;
}

.search-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #777;
}

/* Responsive Notice Page */
@media (max-width: 900px) {
    .notice-layout {
        grid-template-columns: 1fr;
    }

    .notice-sidebar {
        order: -1;
        margin-bottom: 40px;
    }
}

/* --- Board Container --- */
.board-controls {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    align-items: center;
}

.search-wrap {
    display: flex;
    gap: 10px;
}

.search-wrap input {
    background: #111;
    border: 1px solid #333;
    color: white;
    padding: 10px 15px;
    border-radius: 5px;
    outline: none;
}

.search-wrap button {
    background: #222;
    border: 1px solid #333;
    color: white;
    width: 40px;
    border-radius: 5px;
    cursor: pointer;
}

/* Board Table */
.board-list-container {
    overflow-x: auto;
}

.board-table {
    width: 100%;
    border-collapse: collapse;
    background: #111;
    border-top: 2px solid var(--primary-red);
}

.board-table th,
.board-table td {
    padding: 15px;
    text-align: center;
    border-bottom: 1px solid #222;
    color: #ccc;
    font-size: 0.95rem;
}

.board-table th {
    background: #1a1a1a;
    font-weight: 700;
    color: white;
}

.board-table td.title-col {
    text-align: left;
    cursor: pointer;
    transition: color 0.2s;
}

.board-table td.title-col:hover {
    color: var(--primary-red);
}

.board-table tr:hover {
    background: #151515;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 5px;
}

.page-btn {
    background: #111;
    border: 1px solid #333;
    color: #888;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.2s;
}

.page-btn:hover,
.page-btn.active {
    border-color: var(--primary-red);
    color: white;
    background: var(--primary-red);
}

/* Modals */
.modal {
    display: none;
    position: fixed;
    z-index: 99999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    animation: fadeIn 0.3s;
}

.modal-content {
    background-color: #111;
    margin: 5% auto;
    padding: 30px;
    border: 1px solid #333;
    width: 90%;
    max-width: 800px;
    border-radius: 10px;
    position: relative;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.8);
    animation: zoomIn 0.3s;
}

.close-modal {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close-modal:hover {
    color: white;
}

.modal-header {
    border-bottom: 1px solid #333;
    padding-bottom: 15px;
    margin-bottom: 20px;
}

.modal-meta {
    font-size: 0.9rem;
    color: #777;
    margin-top: 5px;
}

.modal-body {
    min-height: 200px;
    line-height: 1.8;
    color: #ddd;
    white-space: pre-wrap;
    /* Preserves newlines */
}

.modal-footer {
    border-top: 1px solid #333;
    padding-top: 20px;
    margin-top: 20px;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* Form Styles */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #ccc;
    font-size: 0.9rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    background: #0a0a0a;
    border: 1px solid #333;
    padding: 12px;
    color: white;
    border-radius: 5px;
    font-family: inherit;
    outline: none;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--primary-red);
}

.form-actions {
    text-align: right;
    margin-top: 20px;
}

/* Responsive Board */
@media (max-width: 600px) {

    .board-table th:nth-child(1),
    .board-table td:nth-child(1),
    .board-table th:nth-child(4),
    .board-table td:nth-child(4),
    .board-table th:nth-child(5),
    .board-table td:nth-child(5) {
        display: none;
        /* Hide Number, Date, Views on very small screens */
    }

    .board-controls {
        flex-direction: column;
        gap: 10px;
    }

    .search-wrap {
        width: 100%;
    }

    .search-wrap input {
        flex: 1;
    }

    .board-table th,
    .board-table td {
        padding: 10px;
        font-size: 0.85rem;
    }
}