/* 
 * board-styles.css
 * 필라코리아 2025 게시판용 스타일시트
 * 일자: 2023년
 */

/* =================== Common Board Styles =================== */
.board-container {
	background-color: #fff;
	border-radius: var(--border-radius, 10px); /* Slightly larger radius */
	padding: 1rem;
	/* Removed shadow from container, apply to table if needed */
}

/* Search Area Container - Reverted shadow removal based on user edit */
.search-container {
	background-color: #f8f9fa; /* Light background */
	border-radius: 50px; /* Pill shape */
	padding: 0.3rem; /* Inner padding */
	display: flex; /* Use flex to align items */
	border: 1px solid var(--border-color, #dee2e6);
	transition: border-color 0.3s ease, box-shadow 0.3s ease;
	box-shadow: 0 2px 5px rgba(0,0,0,0.03);
}
.search-container:focus-within { /* Highlight container when input is focused */
	border-color: var(--primary-color);
	box-shadow: 0 3px 8px rgba(0, 120, 212, 0.1);
}

/* Remove default input-group styling inside container */
.search-container .input-group {
	border: none;
	padding: 0;
	margin: 0;
	width: 100%;
	display: flex;
}

/* Input field styling */
.search-container .form-control {
	background-color: transparent;
	border: none;
	box-shadow: none !important;
	padding-left: 1.2rem;
	padding-right: 0.5rem;
	font-size: 0.95rem;
	height: auto;
	flex-grow: 1;
	border-radius: 0;
	min-width: 0;
}
.search-container .form-control:focus {
	box-shadow: none !important;
}

/* Search button styling */
.search-container .btn-search {
	background-color: transparent;
	border: none;
	color: var(--primary-color);
	padding: 0.5rem 1rem;
	border-radius: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: color 0.3s ease;
	margin-left: -1px;
	flex-shrink: 0;
	box-shadow: none !important;
}
.search-container .btn-search:hover {
	color: var(--secondary-color);
	background-color: transparent;
}

/* Clear Search Button Styling */
.search-container .btn-clear-search {
	background-color: transparent;
	border: none;
	color: #aaa; /* Lighter color for subtle appearance */
	padding: 0.5rem 0.8rem;
	border-radius: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: color 0.3s ease;
	margin-left: -1px; /* Adjust as needed */
	flex-shrink: 0;
	box-shadow: none !important;
	position: absolute; /* Position inside the input group */
	right: 50px; /* Adjust based on search button width */
	top: 50%;
	transform: translateY(-50%);
	z-index: 3; /* Ensure it's above the input field */
}
.search-container .btn-clear-search:hover {
	color: #777;
}

/* Ensure input group doesn't interfere */
.search-form .input-group > .form-control,
.search-form .input-group > .btn-search {
	height: auto;
}

/* Remove old search styles if they exist */
.search-form .btn {
	/* Remove specific styles previously applied directly to .btn if any */
}

/* =================== Notice List Styles =================== */
.notice-total-count {
	font-size: 0.9rem;
	color: var(--text-light, #6c757d);
	display: flex;
	align-items: center;
	height: 100%;
	gap: 4px;
}
.notice-total-count strong {
	color: var(--primary-color);
}
.notice-search-info {
	color: var(--text-light, #999);
	font-size: 0.85rem;
}
.notice-search-info strong {
	color: var(--text-color, #333);
}

.notice-empty {
	text-align: center;
	padding: 4rem 2rem;
	color: var(--text-light, #6c757d);
}
.notice-empty i {
	font-size: 3rem;
	color: #dee2e6;
	margin-bottom: 1rem;
	display: block;
}
.notice-empty p {
	font-size: 1.05rem;
}

.notice-list {
	display: flex;
	flex-direction: column;
	border-top: 2px solid var(--text-color, #333);
	margin-top: 1rem;
}

.notice-item {
	display: flex;
	align-items: center;
	gap: 16px;
	padding: 1.15rem 0.75rem;
	border-bottom: 1px solid #f0f0f0;
	text-decoration: none;
	color: inherit;
	transition: background-color 0.2s ease;
}
.notice-item:hover {
	background-color: #fafbfc;
	text-decoration: none;
	color: inherit;
}
.notice-item.is-pinned {
	background-color: var(--primary-color-bg, #fdf0ee);
	border-bottom-color: var(--primary-color-border, #f0c4bc);
}
.notice-item.is-pinned:hover {
	background-color: #fce8e4;
}

.notice-item-num {
	width: 48px;
	min-width: 48px;
	text-align: center;
}
.notice-num {
	font-size: 0.88rem;
	color: var(--text-light, #999);
	font-weight: 400;
}
.notice-pin {
	color: var(--primary-color);
	font-size: 0.9rem;
}

.notice-item-body {
	flex: 1;
	min-width: 0;
}
.notice-item-title {
	font-size: 0.98rem;
	font-weight: 500;
	color: var(--text-color, #333);
	margin: 0 0 4px 0;
	line-height: 1.45;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	word-break: keep-all;
}
.notice-item:hover .notice-item-title {
	color: var(--primary-color);
}
.notice-flag {
	display: inline-block;
	background: var(--primary-color);
	color: #fff;
	font-size: 0.7rem;
	font-weight: 600;
	padding: 2px 8px;
	border-radius: 3px;
	margin-right: 6px;
	vertical-align: middle;
	letter-spacing: 0.5px;
	position: relative;
	top: -1px;
}
.notice-new {
	display: inline-block;
	color: var(--primary-color);
	font-size: 0.7rem;
	font-weight: 700;
	margin-left: 5px;
	vertical-align: middle;
	position: relative;
	top: -1px;
	animation: noticePulse 2s ease-in-out infinite;
}
@keyframes noticePulse {
	0%, 100% { opacity: 1; }
	50% { opacity: 0.4; }
}
.notice-item-meta {
	display: flex;
	gap: 14px;
	font-size: 0.8rem;
	color: #adb5bd;
}
.notice-item-meta i {
	margin-right: 3px;
}

.notice-item-arrow {
	color: #ddd;
	font-size: 0.75rem;
	transition: transform 0.2s ease, color 0.2s ease;
	min-width: 16px;
}
.notice-item:hover .notice-item-arrow {
	color: var(--primary-color);
	transform: translateX(3px);
}

.notice-pagination {
	margin-top: 2.5rem;
}

/* =================== Pagination Styles =================== */
.board-container .pagination {
	gap: 4px;
}
.board-container .pagination .page-item .page-link {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	padding: 0;
	border: none;
	border-radius: 8px;
	font-size: 0.88rem;
	font-weight: 500;
	color: var(--text-light, #6c757d);
	background: transparent;
	transition: all 0.2s ease;
}
.board-container .pagination .page-item .page-link:hover {
	color: var(--primary-color);
	background: var(--primary-color-bg, #fdf0ee);
}
.board-container .pagination .page-item .page-link:focus {
	box-shadow: none;
}
.board-container .pagination .page-item.active .page-link {
	color: #fff;
	background: var(--primary-color);
	font-weight: 700;
	box-shadow: 0 2px 8px rgba(var(--primary-color-rgb, 218, 59, 35), 0.3);
}
.board-container .pagination .page-item.disabled .page-link {
	color: #d0d0d0;
	background: transparent;
	cursor: default;
}

@media (max-width: 768px) {
	.board-container .pagination .page-item .page-link {
		width: 34px;
		height: 34px;
		font-size: 0.82rem;
		border-radius: 6px;
	}
}

/* =================== Notice Responsive =================== */
@media (max-width: 768px) {
	.notice-total-count {
		margin-bottom: 0.75rem;
		justify-content: center;
	}
	.notice-item {
		padding: 1rem 0.5rem;
		gap: 10px;
	}
	.notice-item-num {
		width: 36px;
		min-width: 36px;
	}
	.notice-item-title {
		font-size: 0.9rem;
		white-space: normal;
		display: -webkit-box;
		-webkit-line-clamp: 2;
		-webkit-box-orient: vertical;
	}
	.notice-item-arrow {
		display: none;
	}
}

/* =================== Legacy Table Styles (QnA, etc.) =================== */
.table {
	border-collapse: collapse;
	width: 100%;
	margin-top: 1.5rem;
	border-radius: var(--border-radius, 8px);
	overflow: hidden;
	border: 1px solid var(--border-color, #dee2e6);
}
.table thead th {
	background-color: #f8f9fa;
	border-bottom: 2px solid var(--border-color, #dee2e6);
	color: var(--text-color, #333);
	font-weight: 600;
	padding: 1rem 1rem;
	vertical-align: middle;
	font-size: 0.9rem;
	text-align: center;
	white-space: nowrap;
}
.table tbody td {
	padding: 1rem 1rem;
	vertical-align: middle;
	border-top: 1px solid var(--border-color, #dee2e6);
	color: var(--text-light, #555);
	font-size: 0.95rem;
	background-color: #fff;
	transition: background-color 0.2s ease;
}
.table tbody tr:hover td {
	background-color: #f8f9fc;
}
.table .title {
	text-overflow: ellipsis; 
	overflow: hidden; 
	white-space: nowrap;
	max-width: 0; 
	text-align: left;
}
.table .title a {
	color: var(--text-color, #333);
	text-decoration: none;
	transition: color 0.2s ease;
	font-weight: 500;
}
.table .title a:hover {
	color: var(--primary-color);
	text-decoration: underline;
}
.table .secret-icon {
	color: #ffc107;
	margin-left: 0.4rem;
	vertical-align: middle;
}
.table .new-icon {
	color: var(--accent-color, #E95383);
	font-size: 0.8em;
	margin-left: 0.4rem;
	font-weight: bold;
	vertical-align: text-bottom;
}
.table .reply-mark {
	color: var(--primary-color);
	opacity: 0.7;
	margin-right: 0.5rem;
	transform: rotate(180deg);
	display: inline-block;
}

/* =================== FAQ Category Tabs =================== */
.faq-category-tabs {
	display: flex;
	gap: 8px;
	margin-bottom: 2rem;
	flex-wrap: wrap;
	padding-bottom: 1.5rem;
	border-bottom: 1px solid var(--border-color, #dee2e6);
}
.faq-tab {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 0.55rem 1.2rem;
	border-radius: 50px;
	font-size: 0.9rem;
	font-weight: 500;
	color: var(--text-light, #6c757d);
	background: #f8f9fa;
	border: 1px solid transparent;
	text-decoration: none;
	transition: all 0.25s ease;
	white-space: nowrap;
}
.faq-tab:hover {
	color: var(--primary-color);
	background: var(--primary-color-bg, #fdf0ee);
	border-color: var(--primary-color-border, #f0c4bc);
	text-decoration: none;
}
.faq-tab.active {
	color: #fff;
	background: var(--primary-color);
	border-color: var(--primary-color);
}
.faq-tab.active:hover {
	color: #fff;
	background: var(--secondary-color);
}
.faq-tab i {
	font-size: 0.8rem;
}
.faq-tab-count {
	background: rgba(255,255,255,0.25);
	padding: 0 7px;
	border-radius: 20px;
	font-size: 0.78rem;
	font-weight: 600;
	line-height: 1.7;
}
.faq-tab:not(.active) .faq-tab-count {
	background: #e9ecef;
	color: var(--text-light, #6c757d);
}

/* =================== FAQ Empty State =================== */
.faq-empty {
	text-align: center;
	padding: 4rem 2rem;
	color: var(--text-light, #6c757d);
}
.faq-empty i {
	font-size: 3rem;
	color: #dee2e6;
	margin-bottom: 1rem;
	display: block;
}
.faq-empty p {
	font-size: 1.1rem;
	margin-bottom: 0.5rem;
}
.faq-empty span {
	font-size: 0.9rem;
}

/* =================== FAQ List =================== */
.faq-list {
	display: flex;
	flex-direction: column;
	gap: 0;
}

/* =================== FAQ Item =================== */
.faq-item {
	border-bottom: 1px solid #f0f0f0;
}
.faq-item:last-child {
	border-bottom: none;
}

/* =================== FAQ Question Button =================== */
.faq-question {
	display: flex;
	align-items: center;
	width: 100%;
	padding: 1.25rem 0.5rem;
	background: none;
	border: none;
	cursor: pointer;
	text-align: left;
	gap: 14px;
	transition: background-color 0.2s ease;
	border-radius: 0;
}
.faq-question:hover {
	background-color: #fafafa;
}
.faq-question:focus {
	outline: none;
	box-shadow: none;
}
.faq-q-badge {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	min-width: 32px;
	border-radius: 8px;
	background: var(--primary-color);
	color: #fff;
	font-weight: 700;
	font-size: 0.85rem;
	letter-spacing: -0.5px;
}
.faq-q-text {
	flex: 1;
	font-size: 1rem;
	font-weight: 500;
	color: var(--text-color, #333);
	line-height: 1.5;
	word-break: keep-all;
}
.faq-arrow {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	min-width: 28px;
	color: #bbb;
	transition: transform 0.3s ease, color 0.3s ease;
}
.faq-question:not(.collapsed) .faq-arrow {
	transform: rotate(180deg);
	color: var(--primary-color);
}
.faq-question:not(.collapsed) .faq-q-text {
	color: var(--primary-color);
}

/* =================== FAQ Answer =================== */
.faq-answer {
	display: flex;
	gap: 14px;
	padding: 0 0.5rem 1.5rem 0.5rem;
	animation: faqFadeIn 0.3s ease;
}
@keyframes faqFadeIn {
	from { opacity: 0; transform: translateY(-6px); }
	to { opacity: 1; transform: translateY(0); }
}
.faq-a-badge {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	min-width: 32px;
	border-radius: 8px;
	background: var(--primary-color-bg, #fdf0ee);
	color: var(--primary-color);
	font-weight: 700;
	font-size: 0.85rem;
	letter-spacing: -0.5px;
}
.faq-a-text {
	flex: 1;
	font-size: 0.95rem;
	line-height: 1.75;
	color: var(--text-light, #555);
	padding-top: 4px;
	word-break: keep-all;
}
.faq-a-text img {
	max-width: 100%;
	height: auto;
	border-radius: 8px;
	margin: 0.5rem 0;
}
.faq-a-text p {
	margin-bottom: 0.5rem;
}
.faq-a-text p:last-child {
	margin-bottom: 0;
}

/* =================== FAQ Responsive =================== */
@media (max-width: 768px) {
	.faq-category-tabs {
		gap: 6px;
	}
	.faq-tab {
		padding: 0.45rem 0.9rem;
		font-size: 0.82rem;
	}
	.faq-question {
		padding: 1rem 0.25rem;
		gap: 10px;
	}
	.faq-q-badge,
	.faq-a-badge {
		width: 26px;
		height: 26px;
		min-width: 26px;
		font-size: 0.75rem;
		border-radius: 6px;
	}
	.faq-q-text {
		font-size: 0.92rem;
	}
	.faq-answer {
		padding: 0 0.25rem 1.25rem 0.25rem;
		gap: 10px;
	}
	.faq-a-text {
		font-size: 0.88rem;
	}
}

/* =================== Detail View Styles =================== */
.detail-container {
    background-color: #fff;
    border-radius: var(--border-radius, 10px);
    padding: 0;
    margin-top: 0;
}

.detail-header {
    border-bottom: 1px solid #eee;
    padding: 2rem 0 1.5rem 0;
    margin-bottom: 0;
}

.detail-header h5.detail-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 1rem;
    line-height: 1.5;
    word-break: keep-all;
}

.meta-info {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}
.meta-info span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.82rem;
    color: var(--text-light, #6c757d);
    background: #f5f6f8;
    padding: 4px 10px;
    border-radius: 20px;
    margin-right: 0;
}
.meta-info i {
    font-size: 0.75rem;
    color: #adb5bd;
    margin-right: 0;
}

/* =================== Attachment Section =================== */
.attachment-section {
    margin: 1.5rem 0;
    padding: 1.2rem 1.5rem;
    background-color: #fafbfc;
    border-radius: 8px;
    border: 1px dashed #dee2e6;
}
.attachment-section h6 {
    font-weight: 600;
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
    color: var(--text-light, #6c757d);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.attachment-list {
    margin: 0;
    padding: 0;
}
.attachment-list .list-group-item {
    background-color: transparent;
    padding: 0.4rem 0 !important;
}
.attachment-list .list-group-item a {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 0.92rem;
    font-weight: 500;
    transition: color 0.2s ease;
}
.attachment-list .list-group-item a:hover {
    color: var(--secondary-color, #e36159);
    text-decoration: underline;
}
.attachment-list .badge {
    font-size: 0.75rem;
    font-weight: 400;
}

/* =================== Content Body =================== */
.content-body {
    padding: 2rem 0;
    line-height: 1.85;
    font-size: 1rem;
    color: #444;
    min-height: 200px;
}
.content-body img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    margin: 0.75rem 0;
}
.content-body p {
    margin-bottom: 0.8rem;
}
.content-body a {
    color: var(--primary-color);
    text-decoration: underline;
}
.content-body a:hover {
    color: var(--secondary-color);
}

/* =================== Button Group =================== */
.button-group {
    border-top: 1px solid #f0f0f0;
    padding-top: 1.5rem;
    margin-top: 1rem;
    display: flex;
    justify-content: center;
    gap: 8px;
}
.button-group .btn {
    margin: 0;
    padding: 0.6rem 1.8rem;
    font-size: 0.9rem;
    border-radius: 6px;
}
.button-group .btn-secondary {
    background: #f5f6f8;
    border: 1px solid #dee2e6;
    color: var(--text-color, #333);
}
.button-group .btn-secondary:hover {
    background: #ebedf0;
    border-color: #ccc;
}

/* Q&A Password Prompt */
.password-prompt-card {
    max-width: 500px;
    margin: 3rem auto;
    border: none;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
}

/* Diary Styles */
.diary-image-container img {
    margin-bottom: 1rem;
}

/* Reply/Comment Section */
.reply-section {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color, #dee2e6);
}
.reply-section h5 {
    font-weight: 600;
    margin-bottom: 1.5rem;
}

/* =================== Detail Responsive =================== */
@media (max-width: 768px) {
    .detail-header h5.detail-title {
        font-size: 1.25rem;
    }
    .meta-info {
        gap: 4px;
    }
    .meta-info span {
        font-size: 0.78rem;
        padding: 3px 8px;
    }
    .content-body {
        padding: 1.5rem 0;
        font-size: 0.95rem;
        min-height: 120px;
    }
    .attachment-section {
        padding: 1rem;
    }
} 