/* 커뮤니티 페이지 전용 스타일 */

/* 네비바 텍스트 겹침 방지 */
.navbar .nav-links {
    gap: 8px;
}

.navbar .nav-link {
    padding: 8px 12px;
    white-space: nowrap;
    font-size: 14px;
}

.navbar .nav-buttons {
    gap: 8px;
    margin-left: 12px;
}

.navbar .nav-buttons .btn-outline,
.navbar .nav-buttons .btn-primary {
    padding: 6px 12px;
    font-size: 13px;
}

.navbar .language-selector {
    margin-left: 8px;
}

/* 커뮤니티 메인 컨테이너 */
.community-main {
    padding: 20px 0;
    background: #f8f9fa;
    min-height: 100vh;
}

/* 커뮤니티 툴바 */
.community-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    padding: 40px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px;
    color: white;
    position: relative;
    overflow: hidden;
}

.community-toolbar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="dots" width="20" height="20" patternUnits="userSpaceOnUse"><circle cx="10" cy="10" r="1" fill="white" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23dots)"/></svg>');
}

.toolbar-left {
    position: relative;
    z-index: 1;
    padding-left: 40px;
}

.toolbar-left h1 {
    font-size: 36px;
    font-weight: 800;
    color: white;
    margin-bottom: 8px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.toolbar-left p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 16px;
    font-weight: 500;
}

.toolbar-right {
    position: relative;
    z-index: 1;
    padding-right: 40px;
}

.btn-write {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
    padding: 15px 30px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.btn-write:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* 검색 및 필터 */
.community-filters {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    padding: 25px 30px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
    flex-wrap: wrap;
    gap: 20px;
    border: 1px solid rgba(102, 126, 234, 0.1);
}

.search-box {
    display: flex;
    gap: 12px;
    flex: 1;
    max-width: 450px;
}

.search-input {
    flex: 1;
    padding: 14px 20px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 15px;
    transition: all 0.3s ease;
    background: #f8f9fa;
}

.search-input:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.search-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 14px 25px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    font-size: 15px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.search-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

.filter-box {
    display: flex;
    gap: 15px;
}

.category-filter, .sort-filter {
    padding: 14px 20px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    background: white;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 140px;
}

.category-filter:focus, .sort-filter:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

/* 추천 검색어 */
.search-section {
    flex: 1;
}

.recommended-searches {
    margin-top: 15px;
}

.search-label {
    font-size: 13px;
    color: #718096;
    font-weight: 600;
    margin-right: 10px;
}

.search-tags {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 5px;
}

.search-tag {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    color: #4a5568;
    border: 1px solid #e2e8f0;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.search-tag:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: transparent;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

/* 페이지네이션 */
.pagination-section {
    margin-top: 40px;
    text-align: center;
}

.pagination {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: white;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.page-btn {
    padding: 8px 12px;
    border: 1px solid #e2e8f0;
    background: white;
    color: #4a5568;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.page-btn:hover {
    border-color: #667eea;
    color: #667eea;
}

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

.page-btn.prev, .page-btn.next {
    font-weight: 600;
}

.page-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* 글쓰기 모달 */
.write-modal {
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0);
    backdrop-filter: blur(0px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.write-modal.show {
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
    opacity: 1;
    visibility: visible;
}

.write-modal .modal-content {
    background: white;
    margin: 5% auto;
    padding: 0;
    border-radius: 16px;
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    transform: translateY(-50px) scale(0.9);
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.write-modal.show .modal-content {
    transform: translateY(0) scale(1);
}

/* 업로드 모달 */
.upload-modal { position: fixed; inset: 0; z-index: 1200; background: rgba(0,0,0,0.45); display: none; align-items: center; justify-content: center; }
.upload-modal.show { display: flex; }
.upload-card { width: 420px; background: #fff; border-radius: 12px; box-shadow: 0 20px 40px rgba(0,0,0,0.3); padding: 20px; }
.upload-title { font-weight: 800; color: #1f2937; margin-bottom: 12px; }
.upload-desc { color: #6b7280; font-size: 13px; margin-bottom: 14px; }
.upload-progress { height: 10px; border-radius: 8px; background: #edf2f7; overflow: hidden; position: relative; }
.upload-progress>span { display: block; height: 100%; width: 0%; background: linear-gradient(90deg,#667eea,#764ba2); transition: width .2s ease; }
.upload-stats { display: flex; justify-content: space-between; font-size: 12px; color: #4b5563; margin-top: 8px; }
.upload-actions { margin-top: 16px; display: flex; justify-content: flex-end; gap: 8px; }
.btn-cancel-upload { background: #e5e7eb; color: #374151; border: none; border-radius: 6px; padding: 8px 12px; cursor: pointer; }

.modal-header {
    padding: 20px 25px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 700;
    color: #2d3748;
}

.close-btn {
    background: none;
    border: none;
    font-size: 24px;
    color: #718096;
    cursor: pointer;
    padding: 5px;
    border-radius: 4px;
    transition: color 0.3s ease;
}

.close-btn:hover {
    color: #2d3748;
}

.modal-body {
    padding: 25px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #2d3748;
    font-size: 14px;
}

/* 별점 컴포넌트 */
.rating-row { position: relative; height: 28px; display: inline-flex; align-items: center; }

.rating-stars {
    --size: 22px;
    --gap: 6px;
    --active: #f59e0b; /* amber-500 */
    --inactive: #e5e7eb; /* gray-200 */
    --star-url: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><polygon points='12,1 15,9 23,9 17,14 19,22 12,17 5,22 7,14 1,9 9,9'/></svg>");
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: var(--gap);
    cursor: pointer;
    height: var(--size);
    z-index: 1;
}

.rating-stars::before,
.rating-stars::after { content: none; display: none; }

.rating-stars .star-shape { width: var(--size); height: var(--size); background: var(--inactive); position: relative; display: inline-block; }
.rating-stars .star-shape,
.rating-stars .star-shape::after { -webkit-mask-image: var(--star-url); mask-image: var(--star-url); -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; -webkit-mask-position: center; mask-position: center; -webkit-mask-size: contain; mask-size: contain; }
.rating-stars .star-shape::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, var(--active) var(--fill, 0%), transparent 0); }

/* 투명 슬라이더(드래그용) */
.rating-range {
    position: absolute;
    left: 0; right: 0; top: 0; bottom: 0;
    opacity: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
    -webkit-appearance: none;
    background: transparent;
    z-index: 2;
}
.rating-range::-webkit-slider-thumb { -webkit-appearance: none; }
.rating-range::-moz-range-thumb { border: none; }

.form-group input, .form-group select, .form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s ease;
    box-sizing: border-box;
}

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    outline: none;
    border-color: #667eea;
}

.form-group textarea {
    resize: vertical;
    font-family: inherit;
}

/* 이미지 미리보기 */
.image-preview {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.preview-item {
    position: relative;
    aspect-ratio: 1;
    border-radius: 6px;
    overflow: hidden;
    background: #f8f9fa;
    border: 1px solid #e2e8f0;
}

.preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.remove-image {
    position: absolute;
    top: 5px;
    right: 5px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    cursor: pointer;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 폼 액션 버튼 */
.form-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 25px;
}

.btn-cancel {
    padding: 10px 20px;
    background: #e2e8f0;
    color: #4a5568;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.3s ease;
}

.btn-cancel:hover {
    background: #cbd5e0;
}

.btn-submit {
    padding: 10px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

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

/* 상단 사진 슬라이드쇼 */
.featured-photos {
    margin-bottom: 50px;
}

.featured-photos h2 {
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 30px;
    color: #2d3748;
    text-align: center;
    position: relative;
}

.featured-photos h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 2px;
}

.photo-slideshow {
    position: relative;
    width: 100%;
    max-width: 900px;
    height: 450px;
    margin: 0 auto;
    perspective: 1000px;
    overflow: visible;
}

.slide {
    position: absolute;
    top: 50%;
    left: 50%;
    max-width: 350px;
    max-height: 400px;
    min-width: 250px;
    min-height: 300px;
    transform: translate(-50%, -50%) rotateY(0deg) scale(0.8);
    transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    opacity: 0.6;
    z-index: 1;
}

/* 가운데 활성 슬라이드 */
.slide.active {
    transform: translate(-50%, -50%) rotateY(0deg) scale(1);
    z-index: 3;
    opacity: 1;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.4);
}

/* 이전 슬라이드 (왼쪽) */
.slide.prev {
    transform: translate(-150%, -50%) rotateY(25deg) scale(0.8);
    z-index: 2;
    opacity: 0.7;
}

/* 다음 슬라이드 (오른쪽) */
.slide.next {
    transform: translate(50%, -50%) rotateY(-25deg) scale(0.8);
    z-index: 2;
    opacity: 0.7;
}

/* 숨겨진 슬라이드들 */
.slide.hidden {
    transform: translate(-50%, -50%) rotateY(0deg) scale(0.6);
    opacity: 0;
    z-index: 0;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    border-radius: 20px;
    background: #f8f9fa;
}

.slide-info {
    position: absolute;
    bottom: 25px;
    left: 25px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.9) 0%, rgba(118, 75, 162, 0.9) 100%);
    color: white;
    padding: 15px 25px;
    border-radius: 30px;
    display: flex;
    gap: 20px;
    align-items: center;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.slide-info .author {
    font-weight: 700;
    font-size: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.slide-info .author::before {
    content: '👤';
    font-size: 16px;
}

.slide-info .likes {
    font-size: 15px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.2);
    padding: 6px 12px;
    border-radius: 15px;
}

/* 슬라이드 컨트롤 */
.slide-controls {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0 50px;
    z-index: 10;
}

.prev-btn, .next-btn {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.9) 0%, rgba(118, 75, 162, 0.9) 100%);
    color: white;
    border: none;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 24px;
    font-weight: bold;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.prev-btn:hover, .next-btn:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transform: scale(1.1);
    box-shadow: 0 12px 35px rgba(102, 126, 234, 0.5);
}

/* 슬라이드 도트 */
.slide-dots {
    position: absolute;
    bottom: -50px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    z-index: 10;
    background: rgba(255, 255, 255, 0.9);
    padding: 15px 25px;
    border-radius: 30px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
}

.dot {
    height: 12px;
    width: 12px;
    background-color: #e2e8f0;
    border: 2px solid #cbd5e0;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active {
    background-color: #667eea;
    border-color: #667eea;
    transform: scale(1.4);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.dot:hover {
    background-color: #a0aec0;
    border-color: #718096;
    transform: scale(1.2);
}

/* 카테고리별 게시글 섹션 */
.community-categories {
    margin-top: 100px; /* 도트가 아래로 내려갔으므로 여백 증가 */
}

.category-section {
    margin-bottom: 60px;
    background: white;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
    border: 1px solid rgba(102, 126, 234, 0.1);
    position: relative;
    overflow: hidden;
}

.category-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.category-section h3 {
    font-size: 24px;
    font-weight: 800;
    color: #2d3748;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.category-section h3::before {
    content: '';
    width: 8px;
    height: 8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    box-shadow: 0 0 15px rgba(102, 126, 234, 0.5);
}

.more-btn {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    color: #4a5568;
    border: 2px solid #e2e8f0;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.more-btn:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: transparent;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.3);
}

/* 게시글 그리드 */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
}

/* 게시글 아이템 */
.post-item {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    transition: all 0.4s ease;
    cursor: pointer;
    border: 1px solid rgba(102, 126, 234, 0.1);
    position: relative;
}

.post-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.post-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.18);
}

.post-item:hover::before {
    opacity: 1;
}

.post-image {
    width: 100%;
    height: 180px;
    overflow: hidden;
    position: relative;
}

.post-image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.1) 100%);
}

.post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.post-item:hover .post-image img {
    transform: scale(1.08);
}

.post-info {
    padding: 20px;
    position: relative;
    z-index: 1;
}

.post-title {
    font-size: 16px;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 12px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: #718096;
}

.post-meta .author {
    font-weight: 700;
    color: #4a5568;
    display: flex;
    align-items: center;
    gap: 6px;
}

.post-meta .author::before {
    content: '👤';
    font-size: 12px;
}

.post-stats {
    display: flex;
    gap: 12px;
    align-items: center;
}

.post-stats .likes,
.post-stats .views {
    display: flex;
    align-items: center;
    gap: 4px;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
}

.post-stats .likes {
    color: #667eea;
    background: rgba(102, 126, 234, 0.1);
}

.post-stats .views {
    color: #718096;
    background: rgba(113, 128, 150, 0.1);
}

/* 네비바 텍스트 겹침 방지 - 큰 화면 */
@media (min-width: 1200px) {
    .navbar .nav-links {
        gap: 12px;
    }
    
    .navbar .nav-link {
        padding: 10px 16px;
        font-size: 15px;
    }
    
    .navbar .nav-buttons {
        gap: 12px;
        margin-left: 20px;
    }
}

/* 중간 화면에서 텍스트 겹침 방지 */
@media (max-width: 1199px) and (min-width: 769px) {
    .navbar .nav-links {
        gap: 6px;
    }
    
    .navbar .nav-link {
        padding: 6px 10px;
        font-size: 13px;
    }
    
    .navbar .nav-buttons {
        gap: 6px;
        margin-left: 10px;
    }
    
    .navbar .nav-buttons .btn-outline,
    .navbar .nav-buttons .btn-primary {
        padding: 5px 10px;
        font-size: 12px;
    }
}

/* 반응형 디자인 */
@media (max-width: 768px) {
    .community-main {
        padding: 20px 0;
    }
    
    .container {
        padding: 0 16px;
    }
    
    /* 커뮤니티 툴바 모바일 대응 */
    .community-toolbar {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
        padding: 30px 20px;
        margin-bottom: 30px;
    }
    
    .toolbar-left h1 {
        font-size: 2rem;
        margin-bottom: 8px;
    }
    
    .toolbar-left p {
        font-size: 15px;
    }
    
    .toolbar-right {
        padding-right: 0;
        align-self: stretch;
    }
    
    .btn-write {
        width: 100%;
        padding: 16px 24px;
        font-size: 16px;
        justify-content: center;
        display: flex;
        align-items: center;
        gap: 8px;
    }
    
    /* 검색 및 필터 모바일 대응 */
    .community-filters {
        flex-direction: column;
        align-items: stretch;
        padding: 20px;
        gap: 20px;
    }
    
    .search-section {
        width: 100%;
    }
    
    .search-box {
        max-width: none;
        gap: 12px;
    }
    
    .search-input {
        padding: 16px 20px;
        font-size: 16px;
    }
    
    .search-btn {
        padding: 16px 24px;
        font-size: 16px;
        white-space: nowrap;
    }
    
    .recommended-searches {
        margin-top: 16px;
    }
    
    .search-tags {
        gap: 8px;
        margin-top: 8px;
    }
    
    .search-tag {
        padding: 8px 16px;
        font-size: 13px;
    }
    
    .filter-box {
        justify-content: space-between;
        gap: 12px;
    }
    
    .category-filter, .sort-filter {
        flex: 1;
        padding: 16px 20px;
        font-size: 16px;
        text-align: center;
    }
    
    /* 슬라이드쇼 모바일 대응 */
    .photo-slideshow {
        height: 300px;
        border-radius: 16px;
    }
    
    .slide-info {
        bottom: 20px;
        left: 20px;
        padding: 12px 20px;
        font-size: 14px;
        gap: 15px;
    }
    
    .slide-info .author {
        font-size: 14px;
    }
    
    .slide-info .likes {
        font-size: 14px;
        padding: 8px 12px;
    }
    
    .slide-controls {
        padding: 0 20px;
    }
    
    .prev-btn, .next-btn {
        width: 45px;
        height: 45px;
        font-size: 18px;
    }
    
    /* 카테고리 섹션 모바일 대응 */
    .category-section {
        padding: 30px 20px;
        margin-bottom: 40px;
        border-radius: 16px;
    }
    
    .category-header {
        margin-bottom: 20px;
    }
    
    .category-section h3 {
        font-size: 20px;
    }
    
    .more-btn {
        padding: 6px 12px;
        font-size: 13px;
    }
    
    .posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 20px;
    }
    
    .post-item {
        border-radius: 12px;
    }
    
    .post-image {
        height: 160px;
    }
    
    .post-info {
        padding: 16px;
    }
    
    .post-title {
        font-size: 15px;
        margin-bottom: 10px;
    }
    
    .post-meta {
        font-size: 13px;
    }
    
    .post-stats .likes,
    .post-stats .views {
        font-size: 12px;
        padding: 6px 10px;
    }
    
    /* 페이지네이션 모바일 대응 */
    .pagination {
        padding: 12px 16px;
        gap: 6px;
    }
    
    .page-btn {
        padding: 10px 14px;
        font-size: 14px;
    }
    
    /* 글쓰기 모달 모바일 대응 */
    .write-modal .modal-content {
        width: 95%;
        margin: 10% auto;
        border-radius: 16px;
    }
    
    .modal-header {
        padding: 20px;
    }
    
    .modal-header h2 {
        font-size: 18px;
    }
    
    .modal-body {
        padding: 20px;
    }
    
    .form-group input, 
    .form-group select, 
    .form-group textarea {
        padding: 16px 20px;
        font-size: 16px;
    }
    
    .form-actions {
        flex-direction: column;
        gap: 12px;
    }
    
    .btn-cancel, 
    .btn-submit {
        padding: 16px 24px;
        font-size: 16px;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .community-main {
        padding: 15px 0;
    }
    
    .container {
        padding: 0 12px;
    }
    
    /* 툴바 초소형 화면 대응 */
    .community-toolbar {
        padding: 20px 16px;
        margin-bottom: 20px;
    }
    
    .toolbar-left h1 {
        font-size: 1.75rem;
    }
    
    .toolbar-left p {
        font-size: 14px;
    }
    
    /* 검색 및 필터 초소형 화면 대응 */
    .community-filters {
        padding: 16px;
        gap: 16px;
    }
    
    .search-input {
        padding: 14px 16px;
        font-size: 16px;
    }
    
    .search-btn {
        padding: 14px 20px;
        font-size: 15px;
    }
    
    .search-tag {
        padding: 6px 12px;
        font-size: 12px;
    }
    
    .category-filter, .sort-filter {
        padding: 14px 16px;
        font-size: 15px;
    }
    
    /* 슬라이드쇼 초소형 화면 대응 */
    .photo-slideshow {
        height: 250px;
        border-radius: 12px;
    }
    
    .slide-info {
        bottom: 15px;
        left: 15px;
        padding: 10px 16px;
        font-size: 13px;
        gap: 12px;
    }
    
    .slide-info .author {
        font-size: 13px;
    }
    
    .slide-info .likes {
        font-size: 13px;
        padding: 6px 10px;
    }
    
    .prev-btn, .next-btn {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    
    /* 카테고리 섹션 초소형 화면 대응 */
    .category-section {
        padding: 20px 16px;
        margin-bottom: 30px;
    }
    
    .category-header {
        margin-bottom: 16px;
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .category-section h3 {
        font-size: 18px;
    }
    
    .more-btn {
        padding: 8px 14px;
        font-size: 12px;
        align-self: flex-end;
    }
    
    .posts-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .post-image {
        height: 140px;
    }
    
    .post-info {
        padding: 14px;
    }
    
    .post-title {
        font-size: 14px;
        margin-bottom: 8px;
    }
    
    .post-meta {
        font-size: 12px;
    }
    
    .post-stats {
        gap: 8px;
    }
    
    .post-stats .likes,
    .post-stats .views {
        font-size: 11px;
        padding: 4px 8px;
    }
    
    /* 페이지네이션 초소형 화면 대응 */
    .pagination {
        padding: 10px 12px;
        gap: 4px;
    }
    
    .page-btn {
        padding: 8px 12px;
        font-size: 13px;
    }
    
    /* 글쓰기 모달 초소형 화면 대응 */
    .write-modal .modal-content {
        width: 98%;
        margin: 5% auto;
    }
    
    .modal-header {
        padding: 16px;
    }
    
    .modal-header h2 {
        font-size: 16px;
    }
    
    .modal-body {
        padding: 16px;
    }
    
    .form-group {
        margin-bottom: 16px;
    }
    
    .form-group label {
        font-size: 13px;
        margin-bottom: 6px;
    }
    
    .form-group input, 
    .form-group select, 
    .form-group textarea {
        padding: 14px 16px;
        font-size: 16px;
    }
    
    .image-preview {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
        gap: 8px;
    }
}