@charset "utf-8";

/* ==========================================================================
   Global & Variables
   ========================================================================== */
:root {
    --card-border-radius: 16px;
    --card-shadow-sm: 0 4px 20px rgb(0 0 0 / 13%);
    /* Softer, spread out shadow */
    --card-shadow-md: 0 10px 25px rgb(0 0 0 / 13%);
    --primary-color: #333;
    --accent-color: #f9267f;
    --text-color: #333;
    --text-muted: #999;
    --bg-light: #f9f9f9;
    --transition-speed: 0.3s;
    --input-height: 48px;
    /* Uniform height for inputs */
}

#bo_btn_top {
    /* margin: 10px 0; */
    display: flex;
    flex-direction: row;
    justify-content: space-between;
}

#bo_btn_top:after {
    display: block;
    visibility: hidden;
    clear: both;
    content: ""
}

/* ==========================================================================
   카드형 리스트 스타일 (Card-based List Styles)
   ========================================================================== */

.card-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 20px;
    margin-bottom: 20px;
}

.card-item-wrap {
    position: relative;
}

.card-item {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    border: none;
    border-radius: var(--card-border-radius);
    overflow: hidden;
    text-decoration: none;
    color: var(--text-color);
    background: #fff;
    box-shadow: var(--card-shadow-sm);
    transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}

.card-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--card-shadow-md);
}

.card-thumbnail {
    flex: 0 0 160px;
    position: relative;
    /* background-color: var(--bg-light); */
    overflow: hidden;
}

.card-thumbnail img,
.card-thumbnail .no-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
    border-radius: var(--card-border-radius);
    padding: 6px;
}

.card-item:hover .card-thumbnail img {
    transform: scale(1.05);
}

.card-thumbnail .no-image {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ccc;
    font-size: 0.9em;
    background: #f0f0f0;
}

/* Notice Styling */
.is-notice .card-item {
    border: 1px solid rgba(249, 38, 127, 0.3);
    background: linear-gradient(to right, #fff, #fff5f9);
}

.notice-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: linear-gradient(135deg, #f9267f, #ff6b6b);
    color: white;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75em;
    font-weight: 600;
    z-index: 10;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.card-content {
    padding: 24px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    justify-content: center;
    min-width: 0;
}

.card-content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}

.card-company-name {
    font-size: 1.4rem;
    /* Larger Title */
    color: #111;
    font-weight: 800;
    /* Extra Bold */
    padding-right: 15px;
    letter-spacing: -0.5px;
    line-height: 1.2;
}

.card-subject {
    font-size: 1rem;
    font-weight: 400;
    margin: 6px 0 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #555;
    line-height: 1.5;
}

.card-themes {
    margin-top: 12px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.theme-tag {
    background-color: var(--bg-light);
    color: #777;
    padding: 4px 10px;
    border-radius: 15px;
    font-size: 0.8em;
    font-weight: 500;
}

.card-footer {
    display: flex;
    align-items: center;
    gap: 10px;
}

.card-footer i {
    color: #ccc;
    font-size: 0.9em;
}

.card-arrow {
    opacity: 0;
    transform: translateX(-10px);
    transition: all 0.3s ease;
    color: var(--accent-color) !important;
}

.card-item:hover .card-arrow {
    opacity: 1;
    transform: translateX(0);
}

.card-date {
    font-size: 0.85em;
    color: #aaa;
    font-weight: 500;
}

.card-checkbox {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
}

.empty_list {
    padding: 80px 0;
    text-align: center;
    color: #888;
    grid-column: 1 / -1;
}

/* ==========================================================================
   Toolbar and Filter Styles (V2)
   ========================================================================== */

.board-toolbar {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
    align-items: stretch;
}

/* Theme Filter - sub-category-bar */
#theme_filter {
    flex-grow: 1; /* Allow it to take available space */
}

#theme_filter .sub-category-bar {
    display: flex;
    flex-wrap: wrap; /* Allow items to wrap on smaller screens */
    gap: 8px; /* Space between items */
    list-style: none;
    margin: 0;
    padding: 0;
    height: var(--input-height); /* Match height of other toolbar elements */
    align-items: center; /* Vertically align items */
}

#theme_filter .sub-category-bar li {
    margin: 0;
}

#theme_filter .sub-category-bar a {
    display: block; /* Make the whole area clickable */
    padding: 8px 18px;
    border-radius: 20px; /* Pill-shaped buttons */
    background-color: var(--bg-light);
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.9em;
    font-weight: 500;
    transition: all var(--transition-speed) ease;
    border: 1px solid #e0e0e0;
}

#theme_filter .sub-category-bar a:hover {
    background-color: #f0f0f0;
    border-color: #ccc;
}

#theme_filter .sub-category-bar a.active {
    background-color: var(--primary-color); /* Primary color for active state */
    color: #fff;
    border-color: var(--primary-color);
    font-weight: 700;
}

@media (max-width: 768px) {
    #theme_filter .sub-category-bar {
        height: auto; /* Allow height to adjust for wrapped items */
        justify-content: center; /* Center items on mobile */
    }

    #theme_filter .sub-category-bar a {
        padding: 6px 14px; /* Slightly smaller padding on mobile */
        font-size: 0.85em;
    }
}

/* Search Box */
.bo_sch_new {
    padding: 0;
    background: transparent;
    border: none;
    border-radius: 0;
    margin-bottom: 0;
    box-shadow: none;
    flex-grow: 1;
    /* Search takes remaining space */
}

.bo_sch_new form {
    display: flex;
    gap: 0;
    height: 100%;
}

.bo_sch_new .frm_input {
    flex-grow: 1;
    border: 1px solid #e0e0e0;
    padding: 0 20px;
    border-radius: var(--card-border-radius);
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
    height: var(--input-height);
    background: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
}

.bo_sch_new .frm_input:focus {
    border-color: #333;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    outline: none;
    z-index: 10;
}

.bo_sch_new .btn_submit {
    background: #333;
    color: #fff;
    border: none;
    padding: 0 25px;
    /* More clickable area */
    border-radius: 0;
    border-top-right-radius: var(--card-border-radius);
    border-bottom-right-radius: var(--card-border-radius);
    cursor: pointer;
    font-weight: 600;
    font-size: 1.1rem;
    transition: background 0.2s;
    height: var(--input-height);
}

.bo_sch_new .btn_submit:hover {
    background: #111;
}

/* Location Filter */
#custom_loc_filter_container {
    position: relative;
    width: 240px;
    /* Fixed width for filter */
    min-width: 180px;
    margin-bottom: 0;
    /* Clear previous margin */
}

#loc_filter_trigger {
    width: 100%;
    height: var(--input-height);
    /* Unified Height */
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: var(--card-border-radius);
    font-size: 1rem;
    color: #333;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
}

#loc_filter_trigger:hover,
#loc_filter_trigger.active {
    border-color: #333;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

#loc_filter_trigger .arrow-down {
    width: 10px;
    height: 10px;
    border-right: 2px solid #333;
    border-bottom: 2px solid #333;
    transform: rotate(45deg);
    transition: transform 0.2s ease-in-out;
    margin-top: -5px;
}

#loc_filter_trigger.active .arrow-down {
    transform: rotate(225deg);
    margin-top: 5px;
}

#loc_filter_dropdown {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    width: 480px;
    /* Widened for desktop */
    z-index: 1000;
    background-color: #fff;
    border: none;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    display: flex;
    height: 340px;
    overflow: hidden;
}

/* Custom Scrollbar for Dropdown */
#loc_filter_dropdown ::-webkit-scrollbar {
    width: 6px;
}

#loc_filter_dropdown ::-webkit-scrollbar-track {
    background: transparent;
}

#loc_filter_dropdown ::-webkit-scrollbar-thumb {
    background-color: rgba(0, 0, 0, 0.1);
    border-radius: 4px;
}

#loc_filter_dropdown ::-webkit-scrollbar-thumb:hover {
    background-color: rgba(0, 0, 0, 0.2);
}

#loc_filter_dropdown.hidden {
    display: none;
}

/* Theme Filter Dropdown */
#custom_theme_filter_container {
    position: relative;
    width: 240px;
    min-width: 180px;
}

#theme_filter_trigger {
    width: 100%;
    height: var(--input-height);
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: var(--card-border-radius);
    font-size: 1rem;
    color: #333;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
    box-shadow: 0 2px 8px rgba(0,0,0,0.03);
}

#theme_filter_trigger:hover,
#theme_filter_trigger.active {
    border-color: #333;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

#theme_filter_trigger .arrow-down {
    width: 10px;
    height: 10px;
    border-right: 2px solid #333;
    border-bottom: 2px solid #333;
    transform: rotate(45deg);
    transition: transform 0.2s ease-in-out;
    margin-top: -5px;
}

#theme_filter_trigger.active .arrow-down {
    transform: rotate(225deg);
    margin-top: 5px;
}

#theme_filter_dropdown {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: #fff;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    max-height: 340px;
    overflow-y: auto;
}

#theme_filter_dropdown.hidden {
    display: none;
}

.theme_panel {
    padding: 10px 0;
}

.theme_panel ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.theme_panel li {
    font-size: 0.95em;
    cursor: pointer;
    transition: background-color 0.2s ease;
    color: #555;
}

.theme_panel li a {
    display: block;
    padding: 14px 20px;
    text-decoration: none;
    color: inherit;
}

.theme_panel li:hover {
    background-color: #f9f9f9;
    color: #000;
}

.theme_panel li.active a {
    color: #111;
    font-weight: 700;
    background-color: #f0f0f0;
}

#theme_filter_dropdown::-webkit-scrollbar { width: 6px; }
#theme_filter_dropdown::-webkit-scrollbar-track { background: transparent; }
#theme_filter_dropdown::-webkit-scrollbar-thumb { background-color: rgba(0,0,0,0.1); border-radius: 4px; }
#theme_filter_dropdown::-webkit-scrollbar-thumb:hover { background-color: rgba(0,0,0,0.2); }

@media (max-width: 768px) {
    #custom_theme_filter_container {
        width: 100%;
        max-width: none;
    }
}


.loc_panel {
    width: 50%;
    height: 100%;
    overflow-y: auto;
    padding: 10px 0;
}

#loc1_panel {
    border-right: 1px solid #f0f0f0;
    background: #fafafa;
}

.loc_panel ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.loc_panel li {
    padding: 14px 20px;
    font-size: 0.95em;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #555;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.loc_panel li:hover {
    background-color: #fff;
    color: #000;
    padding-left: 24px;
}

.loc_panel li.active {
    background-color: #fff;
    color: #111;
    font-weight: 700;
}

#loc1_panel li.active {
    background: #fff;
    box-shadow: inset 3px 0 0 #333;
    color: #000;
}

.loc_panel li .loc-count {
    color: #bbb;
    font-size: 0.85em;
    background: #f0f0f0;
    padding: 2px 8px;
    border-radius: 10px;
    transition: all 0.2s;
}

.loc_panel li:hover .loc-count,
.loc_panel li.active .loc-count {
    background: #eee;
    color: #555;
}

/* ==========================================================================
   Responsive & Misc
   ========================================================================== */

@media (max-width: 768px) {
    #loc_filter_dropdown {
        width: 100%;
        /* Reset to full width on mobile */
    }

    .card-item {
        flex-direction: column;
    }

    .card-thumbnail {
        flex: 0 0 200px;
        width: 100%;
    }

    .card-content {
        padding: 20px;
    }

    .card-company-name {
        font-size: 1.25rem;
    }

    .board-toolbar {
        /* Stack toolbar on mobile */
        flex-direction: column;
        gap: 15px;
    }

    #custom_loc_filter_container {
        width: 100%;
        /* Full width on mobile */
        max-width: none;
    }

    .bo_sch_new .frm_input {
        border-radius: var(--card-border-radius);
        /* Rounded on mobile */
        border-bottom-right-radius: 0;
        border-top-right-radius: 0;
    }

    .bo_sch_new .btn_submit {
        width: 60px;
        /* Bigger button */
    }
}

/* Original GnuBoard Overrides */
#bo_list_total {
    float: left;
    line-height: 40px;
    font-size: 1.1em;
    /* Bigger */
    color: #222;
    /* Darker */
    font-weight: 700;
    /* Bolder */
    /* margin-bottom: 10px; */
}

.btn_bo_user {
    float: right;
    margin: 0;
    padding: 0;
    list-style: none;
    flex-grow: 1;
    display: flex;
    justify-content: flex-end;
}

.btn_bo_user li {
    float: left;
    width: 40px;
    text-align: center;
    margin-left: 5px;
}

.btn_bo_user > li {
    position: relative
}

#bo_list {
    position: relative;
    margin-bottom: 20px;
}

/* Helper Cleanups */
.sly_wrap,
#bo_cate {
    display: block;
}

/* ... Add any necessary resets ... */