/* 웹 접근성 - 건너뛰기 링크 */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: #667eea;
    color: white;
    padding: 8px 16px;
    z-index: 10001;
    transition: top 0.2s;
    text-decoration: none;
    font-size: 14px;
}

.skip-link:focus {
    top: 0;
    outline: 2px solid #fff;
    outline-offset: -4px;
}

/* 포커스 표시 강화 */
a:focus, button:focus, [role="button"]:focus {
    /*outline: 2px solid #667eea;*/
    outline-offset: 2px;
}

/* 콘텐츠 내 제목 스타일 */
.content-body h1, .content-body h2, .content-body h3 {
    margin-top: 1.5em;
    margin-bottom: 0.5em;
    color: #222;
    line-height: 1.4;
}
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans KR', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: white;
    min-height: 100vh;
}

/* 헤더 스타일 */
header {
    background: white;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    padding: 0 30px;
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    gap: 0;
    flex-wrap: wrap;
}

/* 상단 헤더 (좌: 로고, 중: 제목, 우: 홈+메뉴) */
.header-top {
    display: flex;
    align-items: center;
    gap: 0;
    flex: 0 0 auto;
    padding: 15px 0;
}

/* 로고 */
.logo {
    width: 169px;
    height: 57px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.logo a {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: opacity 0.3s;
    width: 100%;
    height: 100%;
}

.logo a:hover {
    opacity: 0.8;
}

.logo img {
    width: 210px;
    height: 45px;
    display: block;
}

/* 중앙 제목 */
.tagline {
    display: none;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    margin-left: auto;
}

.home-btn {
    padding: 6px 12px;
    background: white;
    border: 1px solid #ddd;
    border-radius: 6px;
    cursor: pointer;
    font-size: 12px;
    color: #333;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-block;
}

.home-btn:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

/* 네비게이션 바 (회색 배경) */
.nav-bar {
    width: calc(100% + 60px);
    margin-left: -30px;
    margin-right: -30px;
    background-color: #6b6b6b;
    padding: 0;
    display: none;
    align-items: center;
    justify-content: center;
    height: 50px;
    order: 3;
    flex-basis: auto;
}

.nav-bar.show {
    display: flex;
}

.nav-bar-content {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 20px;
    width: 100%;
    height: 100%;
    max-width: 1500px;
    margin: 0 auto;
}

.home-icon {
    font-size: 18px;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Breadcrumb 네비게이션 */
.breadcrumb-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 0;
    font-size: 15px;
    color: white;
    height: 50px;
    flex-wrap: wrap;
}

.breadcrumb-item {
    color: white;
    display: inline-block;
}

.breadcrumb-clickable {
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
}

.breadcrumb-placeholder {
    color: #666;
    font-style: italic;
    border: 1px dashed rgba(255, 255, 255, 0.5);
}

.breadcrumb-separator {
    color: #666;
    margin: 0 2px;
}

/* Breadcrumb 드롭다운 메뉴 */
.breadcrumb-dropdown {
    background: white;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    z-index: 10000;
    display: flex;
    min-width: 200px;
}

.breadcrumb-dropdown-column {
    min-width: 200px;
    max-width: 250px;
    border-right: 1px solid #eee;
    max-height: 300px;
    overflow-y: auto;
    padding: 0;
}

.breadcrumb-dropdown-column:last-child {
    border-right: none;
}

.breadcrumb-dropdown-item {
    padding: 12px 16px;
    cursor: pointer;
    font-size: 14px;
    color: #333;
    transition: background-color 0.2s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.breadcrumb-dropdown-item:hover {
    background-color: #f0f4ff;
}

.breadcrumb-dropdown-item.active {
    background-color: #667eea;
    color: white;
    padding: 12px 16px;
}

.menu-icon {
    font-size: 22px;
    cursor: pointer;
    color: #333;
    transition: color 0.3s;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.menu-icon:hover {
    color: #667eea;
}

/* 헤더 메인 (가로 메뉴) */
.header-main {
    flex: 1;
    display: flex;
    align-items: center;
    padding: 0;
    margin: 0;
}

.top-menu {
    display: flex;
    flex: 1;
    justify-content: flex-start;
}

.menu-level-1 {
    display: flex;
    list-style: none;
    gap: 0;
    /* margin: 0; */
    margin-left:100px;
    padding: 0;
    border-bottom: none;
    width: 100%;
}
.menu-item-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.menu-link {
    display: block;
    padding: 18px 28px;
    color: #666;
    text-decoration: none;
    font-size: 22px;
    font-weight: 500;
    transition: all 0.3s;
    border-bottom: 3px solid transparent;
}
.menu-link:hover {
    color: #667eea;
    border-bottom-color: #667eea;
    background: #f9f9f9;
}

.menu-level-2 {
    display: none;
    position: absolute;
    top: calc(100% + 17px);
    left: 0;
    background: white;
    border: 1px solid #ddd;
    border-top: none;
    list-style: none;
    margin: 0;
    padding: 0;
    min-width: 200px;
    z-index: 100;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.menu-level-2.show {
    display: block;
}

.menu-level-2 li {
    position: relative;
}

.menu-level-2 a {
    display: block;
    padding: 14px 20px;
    color: #333;
    text-decoration: none;
    font-size: 14px;
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.2s;
}

.menu-level-2 a:hover {
    color: #667eea;
    background: #f9f9f9;
    padding-left: 24px;
}

.menu-level-3 {
    display: none;
    position: absolute;
    top: 0;
    left: 100%;
    background: white;
    border: 1px solid #ddd;
    border-left: none;
    list-style: none;
    margin: 0;
    padding: 0;
    min-width: 180px;
    z-index: 101;
}

.menu-level-3.show {
    display: block;
}

.menu-level-3 a {
    display: block;
    padding: 12px 18px;
    color: #333;
    text-decoration: none;
    font-size: 13px;
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.2s;
}

.menu-level-3 a:hover {
    color: #667eea;
    background: #f9f9f9;
    padding-left: 22px;
}

/* 메뉴 모달 - 드롭다운 */
.menu-modal {
    position: fixed;
    top: 65px;
    right: 30px;
    z-index: 1000;
    animation: dropDown 0.2s ease-out;
    display: none;
    gap: 3px;
    align-items: flex-start;
    justify-content: flex-end;
}

.menu-modal.show {
    display: flex;
    flex-direction: row-reverse;
}

@keyframes dropDown {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.menu-section {
    background: white;
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    overflow: hidden;
}

.menu-column {
    width: 150px;
    overflow: visible;
    padding: 0;
    display: none;
    flex-direction: column;
    flex-shrink: 0;
    align-self: flex-start;
    white-space: nowrap;
}

.menu-column.show {
    display: flex;
}

.menu-item {
    padding: 10px 12px;
    cursor: pointer;
    transition: all 0.15s;
    font-size: 13px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    line-height: 1.4;
    white-space: nowrap;
    width: 100%;
}

.menu-item:not(:last-child) {
    border-bottom: 1px solid #f0f0f0;
}

.menu-item:hover {
    background: #f5f5f5;
}

.menu-item.active {
    background: #667eea;
    color: white;
    font-weight: 600;
    width: calc(100% + 24px);
    margin: 0 -12px;
    padding: 10px 12px;
}

.menu-item.active::after {
    content: '✓';
    color: white;
    font-size: 14px;
    font-weight: bold;
    margin-left: 6px;
}

.menu-arrow {
    font-size: 16px;
    margin-left: 8px;
    font-weight: 300;
}

/* 게시판 전용 스타일 (notice.php) */
.container {
    max-width: 1500px;
    margin: 30px auto;
    padding: 0 20px;
}

.page-title {
    font-size: 28px;
    font-weight: 700;
    color: #333;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: center;
}

.card {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}

.search-box {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    align-items: center;
}

.search-box input {
    flex: 1;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    min-width: 150px;
}

.search-box input:focus {
    outline: none;
    border-color: #667eea;
}

.btn {
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.3s;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: #f0f0f0;
    color: #333;
}

.btn-secondary:hover {
    background: #e0e0e0;
}

.notice-table {
    width: 100%;
    border-collapse: collapse;
    border-top: 2px solid #333;
    table-layout: fixed;
}

.notice-table thead {
    background: #f8f9fa;
}

.notice-table th {
    padding: 15px;
    text-align: left;
    font-weight: 600;
    color: #333;
    border-bottom: 1px solid #ddd;
    font-size: 14px;
}

.notice-table th:first-child {
    width: 80px;
    text-align: center;
}

.notice-table th:nth-child(2) {
    text-align: left;
}

.notice-table th:nth-child(3),
.notice-table th:nth-child(4) {
    width: 120px;
    text-align: center;
}

.notice-table tbody tr {
    transition: background 0.2s;
    border-bottom: 1px solid #eee;
}

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

.notice-table td {
    padding: 15px;
    font-size: 14px;
    color: #333;
}

.notice-table td:first-child {
    text-align: center;
    color: #666;
}

.notice-table td:nth-child(3) {
    text-align: center;
}

.notice-title {
    color: #333;
    text-decoration: none;
    font-weight: 500;
}

.notice-title:hover {
    color: #667eea;
}

.notice-table td:last-child {
    text-align: center;
    color: #555;
    font-size: 13px;
}

.pagination {
    display: flex;
    justify-content: center;
    gap: 5px;
    margin-top: 30px;
    padding-top: 20px;
}

.pagination a,
.pagination span {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-decoration: none;
    color: #333;
    font-size: 13px;
    transition: all 0.2s;
}

.pagination a:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

.pagination .active {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

.pagination .disabled {
    color: #666;
    cursor: not-allowed;
}

.pagination .disabled:hover {
    background: transparent;
}

.empty-message {
    text-align: center;
    padding: 60px 20px;
    color: #555;
    font-size: 16px;
}

.detail-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    border-bottom: 2px solid #333;
    padding-bottom: 6px;
    margin-bottom: 10px;
    gap: 20px;
}

.detail-header[style*="border: none"] .detail-title {
    font-size: 22px;
}

.detail-title {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin: 0;
    line-height: 1.4;
    flex: 1;
}

.detail-meta {
    display: flex;
    gap: 15px;
    flex-shrink: 0;
    font-size: 14px;
    color: #666;
    align-items: center;
}

.detail-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.close-btn {
    display: inline-block;
    margin-top: 30px;
    padding: 12px 30px;
    background: #667eea;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-size: 14px;
    text-align: center;
}

.close-btn:hover {
    background: #5a6fd6;
}

.detail-content {
    min-height: 200px;
    line-height: 1.8;
    font-size: 15px;
    color: #333;
    padding: 20px 0;
}

.detail-content img {
    max-width: 100%;
    height: auto;
}

.detail-attachments {
    border-top: 1px solid #ddd;
    margin-top: 25px;
    padding-top: 20px;
}

.attachment-title {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 12px;
}

.attachment-item {
    display: flex;
    align-items: center;
    padding: 8px 0;
    gap: 8px;
}

.attachment-icon {
    font-size: 16px;
}

.attachment-link {
    font-size: 14px;
    color: #333;
    text-decoration: none;
}

.attachment-link:hover {
    color: #667eea;
}

.attachment-size {
    font-size: 13px;
    color: #555;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
    color: #667eea;
    text-decoration: none;
    font-size: 14px;
}

.back-link:hover {
    text-decoration: underline;
}

.badge {
    padding: 4px 10px;
    background: #d1ecf1;
    color: #0c5460;
    border-radius: 4px;
    font-size: 12px;
}

/* 인덱스 전용 스타일 (index.php) */
.main-banner {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 0px;
    width: 100%;
    height: 700px;
    background-image: url('/image/background.jpg?v=1');
    background-position: center;
    background-size: 1000px 700px;
    background-repeat: no-repeat;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}
.main-banner::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0);
}

.main-banner.content-mode {
    background: white !important;
    height: auto !important;
    min-height: auto;
    border-top: none !important;
}

.main-banner.content-mode::after {
    display: none;
}
/*
.banner-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: white;
}

.banner-content h2 {
    font-size: 48px;
    margin-bottom: 20px;
    font-weight: 700;
}

.banner-content p {
    font-size: 20px;
    opacity: 0.9;
}
*/

.banner {
    position: relative;
    min-height: 400px;
    background: url('/img/banner.webp?v=1') no-repeat center center;
    background-size: cover;
}

.banner::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.35); /* 어두운 오버레이 */
}

.banner-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: #fff;
}
/* 푸터 스타일 */
footer {
    background: white;
    color: #666;
    text-align: center;
    padding: 20px 30px;
    margin-top: 0;
    font-size: 13px;
    border-top: 1px solid #ddd;
}

footer .company-name {
    font-weight: 600;
    display: inline;
}

footer .copyright {
    display: inline;
    margin-left: 20px;
}

/* 모바일 헤더 스타일 */
#mobile_header {
    display: none;
}

.mobile-header-wrapper {
    display: none;
}

.mobile-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 15px;
    background: white;
}

.mobile-header-inner h1 {
    margin: 0;
    flex-grow: 1;
}

.mobile-header-inner h1 a {
    display: flex;
    align-items: center;
}

.mobile-header-inner h1 img {
    max-width: 100%;
    height: auto;
}

.mobile-menu {
    display: flex;
    align-items: center;
    gap: 10px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.menu-toggle-mobile a {
    font-size: 24px;
    cursor: pointer;
    color: #333;
    text-decoration: none;
}

/* 사이드 메뉴 스타일 */
#sideMenu {
    display: none;
    position: fixed;
    left: 0;
    top: 0;
    width: 70%;
    max-width: 300px;
    height: 100vh;
    background: white;
    z-index: 1000;
    box-shadow: 2px 0 10px rgba(0,0,0,0.2);
    overflow-y: auto;
}

#sideMenu.show {
    display: flex;
    flex-direction: column;
}

.side-menu-wrapper {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
}

.side-menu-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid #ddd;
    font-weight: 600;
    color: #333;
}

.menu-title-text {
    font-weight: 600;
}

.menu-close-icon {
    font-size: 24px;
    cursor: pointer;
    color: #555;
}

.side-menu-content {
    flex: 1;
    overflow-y: auto;
}

.side-nav {
    padding: 0;
}

.side-nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.side-nav-item {
    list-style: none;
    border-bottom: 1px solid #eee;
}

.side-nav-item > .side-nav-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
    cursor: pointer;
    color: #333;
    font-weight: 500;
}

.side-nav-item > a {
    display: block;
    padding: 12px 20px;
    color: #333;
    text-decoration: none;
    font-weight: 500;
}

.side-nav-arrow {
    font-size: 16px;
    transition: transform 0.3s;
}

.side-nav-item.active > .side-nav-title {
    background: #f5f5f5;
}

.side-nav-item.active > .side-nav-title .side-nav-arrow {
    transform: rotate(90deg);
}

.side-nav-sub {
    list-style: none;
    padding: 0;
    margin: 0;
    background: #f9f9f9;
    display: none;
}

.side-nav-item.active > .side-nav-sub {
    display: block;
}

.side-nav-sub li {
    list-style: none;
}

.side-nav-sub li a {
    display: block;
    padding: 10px 20px 10px 40px;
    color: #666;
    text-decoration: none;
    font-size: 13px;
    border-left: 3px solid transparent;
}

.side-nav-sub li a:hover {
    background: #f0f0f0;
    border-left-color: #667eea;
}

.menu-level-4 {
    display: none;
    position: absolute;
    top: 0;
    left: 100%;
    background: white;
    min-width: 180px;
    box-shadow: 2px 2px 5px rgba(0,0,0,0.1);
    list-style: none;
    padding: 0;
    margin: 0;
    z-index: 102;
}

.menu-level-3 li {
    position: relative;
}

.menu-level-3 li:hover > .menu-level-4 {
    display: block;
}

.menu-level-4 li a {
    display: block;
    padding: 8px 16px;
    color: #333;
    text-decoration: none;
    font-size: 13px;
    white-space: nowrap;
    transition: background 0.2s;
}

.menu-level-4 li a:hover {
    background: #f0f0f0;
    color: #667eea;
}

#back_cover {
    display: none;
    position: fixed;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 999;
}

#back_cover.show {
    display: block;
}

/* 모바일 반응형 */
@media (max-width: 600px) {
    #mobile_header {
        display: block;
    }

    .mobile-header-wrapper {
        display: block;
    }

    header {
        display: none;
    }

    .header-top {
        padding: 8px 0;
    }

    .header-main {
        padding: 10px 0;
    }

    .tagline {
        font-size: 24px;
        margin-bottom: 10px;
        position: static;
        transform: none;
        left: auto;
    }

    .container {
        padding: 0 15px;
        margin: 20px auto;
    }

    .page-title {
        font-size: 22px;
    }

    .card {
        padding: 15px;
    }

    .notice-item {
        flex-wrap: wrap;
        gap: 8px;
    }

    .notice-title {
        width: 100%;
        order: 3;
    }

    .detail-title {
        font-size: 20px !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 100% !important;
        flex: 0 0 100% !important;
        display: block !important;
        word-wrap: break-word !important;
        overflow-wrap: break-word !important;
        white-space: normal !important;
        margin-bottom: 10px !important;
    }

    .detail-header {
        flex-direction: column !important;
        align-items: flex-start !important;
        width: 100% !important;
    }

    .detail-meta {
        margin-top: 10px;
    }

    .menu-btn {
        padding: 10px 20px;
        font-size: 13px;
    }

    .site-btn {
        padding: 14px 28px;
        font-size: 15px;
        min-width: 120px;
    }

    .main-banner {
        height: 400px;
    }

    .banner-content h2 {
        font-size: 32px;
    }

    .banner-content p {
        font-size: 16px;
    }

    /* 공지사항 페이지 모바일 반응형 */
    .menu-info-card {
        flex-direction: column !important;
        gap: 15px !important;
    }

    .menu-info-image {
        width: 100% !important;
        height: 200px !important;
    }

    .search-box {
        display: flex !important;
        flex-direction: row !important;
        gap: 8px !important;
    }

    .search-box input[type="text"] {
        flex: 1 !important;
    }

    .search-box button {
        white-space: nowrap;
    }

    .notice-table {
        font-size: 12px;
        border-collapse: collapse;
    }

    .notice-table th:nth-child(1),
    .notice-table td:nth-child(1) {
        display: table-cell;
        width: 50px;
        text-align: center;
    }

    .notice-table th:nth-child(2) {
        text-align: center;
    }

    .notice-table th:nth-child(3),
    .notice-table td:nth-child(3) {
        display: none;
    }

    .notice-table th:nth-child(4),
    .notice-table td:nth-child(4) {
        display: none;
    }

    .notice-table th {
        padding: 8px 4px;
        font-size: 11px;
    }

    .notice-table td {
        padding: 8px 4px;
        font-size: 11px;
    }

    .detail-attachments {
        margin-top: 20px;
    }

    .attachment-item {
        padding: 8px 0;
        font-size: 12px;
    }
}
