.btn {
    padding: 8px 24px;
}
/* 게시판 전용 스타일 */
.page-container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 40px 20px;
    background: white;
    border-radius: 8px;
}

.page-header {
    text-align: center;
    margin-bottom: 50px;
    padding-bottom: 30px;
    border-bottom: 2px solid #eee;
}

.page-header h1 {
    font-size: 2.5rem;
    color: #333;
    margin-bottom: 10px;
}

.page-subtitle {
    font-size: 1.2rem;
    color: #666;
    margin: 0;
}

/* .page-content - 페이지 콘텐츠 영역 (필요 시 스타일 추가) */

.board-tools {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 15px;
}

 .board-stats {
    color: #6c757d;
    font-size: 14px;
}

 .search-result {
    color: #007bff;
    font-weight: 500;
}

 .board-actions {
    display: flex;
    gap: 15px;
    align-items: center;
}

 .search-form {
    display: flex;
    gap: 10px;
}

 .search-input {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    width: 200px;
}

.post-table {
    width: 100%;
    border-collapse: collapse;
    overflow: hidden;
    background: white;
}

.post-table th {
    background: #f8f9fa;
    padding: 15px 10px;
    text-align: left;
    font-weight: 600;
    color: #495057;
    border-top: 2px solid #dee2e6;
    border-bottom: 2px solid #dee2e6;
}

.post-table td {
    padding: 15px 10px;
    border-bottom: 1px solid #e9ecef;
    vertical-align: middle;
}

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

.post-table .col-no {
    width: 80px;
    text-align: center;
}

.post-table .col-title {
    width: auto;
}

.post-table .col-author {
    width: 120px;
}

.post-table .col-date {
    width: 100px;
}

.post-table .col-views {
    width: 80px;
    text-align: center;
}

.post-link {
    color: #333;
    text-decoration: none;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}

.post-link:hover {
    color: #000;
}

.notice-post {
    background: #fff3cd !important;
}

.notice-post .post-link {
    font-weight: 600;
    color: #856404;
}

.secret-icon, .file-icon, .attachment-icon {
    font-size: 14px;
    opacity: 0.7;
}

.attachment-icon {
    color: #28a745;
    margin-left: 4px;
}

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

.page-link {
    display: inline-block;
    padding: 8px 12px;
    border: 1px solid #dee2e6;
    color: #666;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.3s;
}

.page-link:hover {
    background: #333;
    color: white;
    border-color: #333;
}

.page-link.active {
    background: #333;
    color: white;
    border-color: #333;
    font-weight: 600;
}

/* 갤러리 레이아웃 */
 .gallery-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)) !important;
    gap: 25px !important;
    margin-bottom: 30px !important;
}

 .gallery-item {
    background: white !important;
    border-radius: 12px !important;
    overflow: hidden !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1) !important;
    transition: all 0.3s ease !important;
}

 .gallery-item:hover {
    transform: translateY(0px) !important;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15) !important;
}

.gallery-item.notice-item {
    border: 2px solid #ffc107;
    position: relative;
}

.gallery-item.notice-item::before {
    content: "공지";
    position: absolute;
    top: 10px;
    left: 10px;
    background: #ffc107;
    color: #212529;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    z-index: 2;
}

.gallery-image-container {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.3s ease;
}

.gallery-item:hover .gallery-image {
    transform: scale(1.05);
}

.gallery-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    color: #6c757d;
    font-size: 48px;
}

.gallery-content {
    padding: 20px;
}

.gallery-title {
    font-size: 16px;
    font-family: 'GmarketSansMedium' !important;
    color: #333;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.4;
}

.gallery-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #6c757d;
    margin-bottom: 10px;
}

.gallery-excerpt {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.gallery-link {
    color: inherit;
    text-decoration: none;
}

.gallery-link:hover {
    color: inherit;
}

/* 빈 상태 */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #6c757d;
}

.empty-state .empty-icon {
    font-size: 64px;
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-state h3 {
    color: #495057;
    margin-bottom: 10px;
}

.empty-state p {
    margin-bottom: 20px;
}

/* 반응형 */
@media (max-width: 768px) {
 .board-container {
        padding: 20px;
    }

    .board-tools {
        flex-direction: column;
        align-items: stretch;
    }

 .board-actions {
        justify-content: space-between;
    }

    .search-input {
        width: 150px;
    }

    .post-table {
        font-size: 14px;
    }

    .post-table th,
    .post-table td {
        padding: 10px 8px;
    }

    .post-table .col-no {
        width: 60px;
    }

    .post-table .col-author,
    .post-table .col-views {
        display: none;
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 20px;
    }

    .gallery-image {
        height: 180px;
    }
}

@media (max-width: 480px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 15px;
    }

    .gallery-image {
        height: 150px;
    }

    .notice-badge {
        padding: 2px 8px;
        font-size: 10px;
        border-radius: 15px;
    }
}

/* 갤러리 레이아웃 스타일 */
 .gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    padding: 20px 0;
}

 .gallery-item {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    position: relative;
}

 .gallery-item:hover {
    transform: translateY(0px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

 .gallery-item.notice-item {
    border: 2px solid #dc3545;
}

 .gallery-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

 .gallery-image-container {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
}

 .gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.3s ease;
}

 .gallery-item:hover .gallery-image {
    transform: scale(1.05);
}

 .gallery-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    font-size: 48px;
    color: #adb5bd;
    background: linear-gradient(45deg, #f8f9fa 25%, transparent 25%),
                linear-gradient(-45deg, #f8f9fa 25%, transparent 25%),
                linear-gradient(45deg, transparent 75%, #f8f9fa 75%),
                linear-gradient(-45deg, transparent 75%, #f8f9fa 75%);
    background-size: 20px 20px;
    background-position: 0 0, 0 10px, 10px -10px, -10px 0px;
}

 .gallery-content {
    padding: 20px;
}

 .gallery-title {
    font-size: 16px;
    font-family: 'GmarketSansMedium' !important;
    color: #333;
    text-align: center;
    /*margin: 0 0 12px 0;*/
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

 .gallery-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: #6c757d;
    flex-wrap: wrap;
    gap: 8px;
}

 .gallery-meta .author:before {
    content: "👤";
    margin-right: 4px;
}

 .gallery-meta .date:before {
    /*content: "📅";*/
    margin-right: 4px;
}

/* 오버레이 스타일 */
 .notice-overlay,
 .secret-overlay,
 .external-link-overlay {
    position: absolute;
    top: 10px;
    z-index: 2;
}

 .notice-overlay {
    left: 10px;
}

 .secret-overlay {
    right: 10px;
}

 .external-link-overlay {
    right: 10px;
    top: 45px;
}

 .notice-badge {
    background: #dc3545;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

 .secret-icon,
 .link-icon {
    background: rgba(0,0,0,0.7);
    color: white;
    padding: 6px;
    border-radius: 50%;
    font-size: 14px;
    line-height: 1;
    display: inline-block;
}

 .external-link-overlay .link-icon {
    background: rgba(0,123,255,0.9);
}

/* 반응형 갤러리 스타일 */
@media (max-width: 870px) {
 .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

 .gallery-image-container {
        height: 180px;
    }

 .gallery-content {
        padding: 15px;
    }

 .gallery-title {
        font-size: 14px;
    }

 .gallery-meta {
        font-size: 12px;
    }
}

@media (max-width: 480px) {
 .gallery-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

 .gallery-image-container {
        height: 200px;
    }
.page-header h1 {
        font-size: 2rem;
    }
.page-subtitle {
    font-size: 1rem;
}
}

/* ============================================
   제품 게시판 전용 스타일 (board/product)
   한 줄에 5개씩 표시 (총 15개/페이지)
   ============================================ */
.gallery-grid.board-product {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 30px !important;
    margin-bottom: 30px !important;
}

.gallery-grid.board-product .gallery-image-container {
    height: 290px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.gallery-grid.board-product .gallery-image {
    object-fit: cover !important;
    object-position: center !important;
}

.gallery-grid.board-product .gallery-item {
    box-shadow: 0 2px 5px rgba(0,0,0,0.12) !important;
}

.gallery-grid.board-product .gallery-item:hover {
    box-shadow: 0 5px 10px rgba(0,0,0,0.1) !important;
}

.gallery-grid.board-product .gallery-title {
    font-size: 16px !important;
    font-weight: 600 !important;
}

.gallery-grid.board-product .gallery-title-link {
    text-decoration: none !important;
    color: inherit !important;
    display: block !important;
}

.gallery-grid.board-product .gallery-title-link:hover .gallery-title {
    color: #667eea !important;
}

.gallery-grid.board-product .gallery-subtitle {
    text-align: center;
    font-size: 1rem !important;
    color: #333 !important;
    margin-top: 0 !important;
    line-height: 1.5 !important;
}

.gallery-grid.board-product .gallery-title-link:hover .gallery-subtitle {
    color: #444 !important;
}

/* 제품 게시판 모달 스타일 */
.product-modal-title {
    color: white;
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 20px;
    text-align: center;
    padding: 0 20px;
    line-height: 1.4;
}

/* 제품 게시판 반응형 */
@media (max-width: 1200px) {
    .gallery-grid.board-product {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 30px !important;
    }

        .gallery-grid.board-product .gallery-title {
            font-size: 15px !important;
            font-weight: 600 !important;
        }

        .gallery-grid.board-product .gallery-subtitle {
            font-size: 13px !important;
            margin-top: 6px !important;
        }
}

@media (max-width: 870px) {
    .gallery-grid.board-product {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 30px !important;
    }

    .gallery-grid.board-product .gallery-image-container {
        height: 260px !important;
    }

    .gallery-grid.board-product .gallery-subtitle {
        font-size: 13px !important;
        margin-top: 6px !important;
    }

    .product-modal-title {
        font-size: 20px;
    }
}

@media (max-width: 480px) {
    .gallery-grid.board-product {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }

    .gallery-grid.board-product .gallery-image-container {
        height: 280px !important;
    }

    .gallery-grid.board-product .gallery-title {
            font-size: 16px !important;
            font-weight: 600 !important;
    }

    .gallery-grid.board-product .gallery-subtitle {
        font-size: 14px !important;
        margin-top: 5px !important;
    }

    .product-modal-title {
        font-size: 16px;
        margin-bottom: 15px;
    }
}

/* 헤더 버튼 스타일은 Header.php에서 통합 관리 */
