/* ==================== 통일된 로그인 및 관리 기능 CSS ==================== */

/* 헤더 수정 */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* 로그인 버튼 */
.auth-section {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-right: 20px;
}

.login-btn, .logout-btn {
    background: rgba(255, 255, 255, 0.12);
    color: white;
    border: 1.5px solid rgba(255, 255, 255, 0.65);
    padding: 7px 16px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.9em;
    transition: var(--card-transition, all 0.3s ease);
    display: flex;
    align-items: center;
    gap: 5px;
}

.login-btn:hover, .logout-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: white;
    transform: translateY(-2px);
}

.user-info {
    color: rgba(255, 255, 255, 0.85);
    font-weight: 600;
    font-size: 0.85em;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* 로그인 모달 */
.login-modal {
    display: none;
    position: fixed;
    z-index: 1001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    animation: fadeIn 0.3s ease;
}

.login-modal-content {
    background: white;
    margin: 10% auto;
    padding: 30px;
    border-radius: 15px;
    width: 90%;
    max-width: 400px;
    position: relative;
    animation: slideIn 0.3s ease;
}

.login-form h2 {
    color: #005792;
    text-align: center;
    margin-bottom: 25px;
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #555;
    font-weight: bold;
    font-size: 14px;
    line-height: 1.2;
}

.form-group input, .form-group select, .form-group textarea {
    width: 100%;
    padding: 10px 12px;
    border: 2px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s ease;
    box-sizing: border-box;
    font-family: inherit;
    line-height: 1.4;
}

.form-group input[type="file"] {
    padding: 5px;
}

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    outline: none;
    border-color: #4facfe;
    box-shadow: 0 0 0 0.2rem rgba(79, 172, 254, 0.25);
}

.login-submit {
    width: 100%;
    background: #4facfe;
    color: white;
    border: none;
    padding: 12px;
    border-radius: 8px;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.login-submit:hover {
    background: #005792;
}

.login-close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 28px;
    color: #aaa;
    cursor: pointer;
}

.login-close:hover {
    color: #005792;
}

.login-help {
    text-align: center;
    margin-top: 15px;
    font-size: 0.9em;
    color: #666;
}

/* 관리자 패널 */
.admin-panel {
    display: none;
    background: white;
    padding: 10px 20px 20px;
    border-radius: 12px;
    margin-bottom: 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    border-top: 3px solid #24488c;
}

.admin-panel h3 {
    color: #162d55;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.1em;
    font-weight: 700;
}

.admin-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.admin-btn {
    background: linear-gradient(135deg, #162d55 0%, #24488c 100%);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9em;
    font-weight: 500;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 40px;
    white-space: nowrap;
    font-family: var(--font-kr);
}

.admin-btn:hover {
    background: linear-gradient(135deg, #0f1f3d 0%, #162d55 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(22, 45, 85, 0.35);
}

.admin-btn.delete {
    background: linear-gradient(135deg, #b91c1c 0%, #dc2626 100%);
}

.admin-btn.delete:hover {
    background: linear-gradient(135deg, #991b1b 0%, #b91c1c 100%);
    box-shadow: 0 4px 14px rgba(185, 28, 28, 0.35);
}

.admin-btn.edit {
    background: linear-gradient(135deg, #b45309 0%, #d97706 100%);
    color: white;
}

.admin-btn.edit:hover {
    background: linear-gradient(135deg, #92400e 0%, #b45309 100%);
    box-shadow: 0 4px 14px rgba(180, 83, 9, 0.35);
}

.admin-btn.edit.active {
    background: linear-gradient(135deg, #92400e 0%, #b45309 100%);
    box-shadow: 0 0 0 3px rgba(217, 119, 6, 0.3);
}

.admin-btn.delete.active {
    background: linear-gradient(135deg, #991b1b 0%, #b91c1c 100%);
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.3);
}

.admin-btn i {
    font-size: 0.9em;
    width: 16px;
    text-align: center;
}

/* 특허/수상내역 추가 폼 */
.add-patent-form, .add-award-form {
    display: none;
    background: #f8f9fa;
    padding: 25px;
    border-radius: 12px;
    margin-bottom: 25px;
    border: 2px solid #4facfe;
}

.add-patent-form h4, .add-award-form h4 {
    color: #005792;
    margin-bottom: 20px;
    font-size: 1.1em;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.add-patent-form h4 i, .add-award-form h4 i {
    color: #4facfe;
    font-size: 1em;
}

/* 수정 폼 */
.edit-item-form {
    display: none;
    background: #fff3cd;
    padding: 25px;
    border-radius: 12px;
    margin-bottom: 25px;
    border: 2px solid #ffc107;
}

.edit-item-form h4 {
    color: #856404;
    margin-bottom: 20px;
    font-size: 1.1em;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.edit-item-form h4 i {
    color: #d39e00;
    font-size: 1em;
}

.form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    align-items: flex-end;
}

.form-row .form-group {
    flex: 1;
    min-width: 0;
}

.form-group textarea {
    min-height: 100px;
    resize: vertical;
    font-family: inherit;
    line-height: 1.4;
}

.form-buttons {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #dee2e6;
}

.submit-btn, .cancel-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    min-width: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    line-height: 1;
}

.submit-btn {
    background: var(--color-primary, #005792);
    color: white;
}

.submit-btn:hover {
    background: #003d6b;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 87, 146, 0.3);
}

.cancel-btn {
    background: #f0f2f5;
    color: #555;
    border: 1px solid #dde2ea;
}

.cancel-btn:hover {
    background: #e2e6ed;
    transform: translateY(-1px);
}

.submit-btn i, .cancel-btn i {
    font-size: 0.9em;
}

/* 알림 메시지 */
.alert {
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1002;
    max-width: 400px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    animation: slideInRight 0.3s ease;
}

.alert.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.alert.warning {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

/* ==================== 기존 photo.css 내용 ==================== */

/* 활동 헤더 스타일 */
.activities-header {
    text-align: center;
    padding: 10px 15px 20px;
    margin-bottom: 25px;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.03);
}

.activities-header h1 {
    color: #005792;
    font-size: 2.2em;
    margin-bottom: 12px;
    position: relative;
    display: inline-block;
}

.activities-header h1::after {
    content: "";
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 2px;
    background-color: #4facfe;
}

.activities-header p {
    color: #555;
    font-size: 1em;
    max-width: 600px;
    margin: 15px auto 0;
}

/* 섹션 공통 */
.section {
    margin-bottom: 20px;
    padding: 16px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.04);
    position: relative;
    overflow: hidden;
}

.section::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(79, 172, 254, 0.07) 0%, rgba(0, 242, 254, 0) 70%);
    border-radius: 50%;
    z-index: 0;
}

.section h2 {
    color: #0f2044;
    font-size: 1.1em;
    font-weight: 700;
    margin-bottom: 14px;
    padding: 5px 12px 5px 14px;
    border-left: 3px solid #4facfe;
    background: linear-gradient(90deg, rgba(79, 172, 254, 0.07), transparent);
    border-radius: 0 5px 5px 0;
    border-bottom: none;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.section h2 i {
    margin-right: 8px;
    color: #4facfe;
}

/* 섹션 네비 */
.section-nav {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.section-nav-btn {
    background: white;
    color: #162d55;
    border: 1.5px solid #24488c;
    padding: 8px 18px;
    border-radius: 20px;
    font-size: 1.15em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 6px rgba(22, 45, 85, 0.1);
    display: flex;
    align-items: center;
    gap: 6px;
}

.section-nav-btn:hover {
    background: #eef2f8;
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(22, 45, 85, 0.15);
}

.section-nav-btn.active {
    background: linear-gradient(90deg, #162d55, #24488c);
    color: white;
    border-color: transparent;
    box-shadow: 0 4px 12px rgba(22, 45, 85, 0.3);
    transform: translateY(-2px);
}

/* 특허/수상 */
#patents { border-left: 3px solid #4facfe; display: block; }
#awards  { border-left: 3px solid #28a745; display: block; }

.patent-list, .award-list { list-style: none; padding: 0; }

.patent-list li, .award-list li {
    margin-bottom: 7px;
    padding: 10px 14px;
    background: #f8f9fa;
    border-radius: 8px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
    transition: all 0.3s ease;
    position: relative;
    font-size: 0.92em;
}

.patent-list li:hover, .award-list li:hover {
    background: #f0f7ff;
    transform: translateY(-2px);
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.07);
}

.award-list li { background: #f8fff8; }
.award-list li:hover { background: #f0fff0; }
.award-highlight { color: #dc3545; font-weight: bold; }

/* ==================== Photo 개편 UI ==================== */
#photos { border-left: 3px solid #ffc107; display: none; }

.photo-header {
    gap: 10px;
}

.photo-header-actions {
    display: flex;
    gap: 10px;
}

.photo-header-btn {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    color: #333;
    padding: 8px 12px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9em;
}

.photo-header-btn:hover {
    background: #eef6ff;
    border-color: #cfe7ff;
    transform: translateY(-1px);
}

.photo-hint {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #f8fbff;
    border: 1px solid #e6f2ff;
    color: #2a5d9f;
    padding: 10px 12px;
    border-radius: 12px;
    font-size: 0.92em;
}

.photo-categories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
    margin-top: 18px;
}

.photo-category-card {
    background: var(--bg-white, #fff);
    border-radius: var(--card-radius, 12px);
    overflow: hidden;
    box-shadow: var(--card-shadow, 0 2px 8px rgba(0,0,0,0.08));
    border: 1px solid rgba(0,0,0,0.04);
    cursor: pointer;
    transition: var(--card-transition, all 0.25s ease);
}

.photo-category-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--card-shadow-hover, 0 12px 28px rgba(0,0,0,0.12));
}

.photo-category-topbar {
    padding: 14px 14px 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.photo-category-name {
    font-weight: 700;
    color: #005792;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.photo-category-badge {
    background: #4facfe;
    color: #fff;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.82em;
    font-weight: 600;
}

.photo-category-thumbs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2px;
    height: 150px;
    background: #f2f2f2;
}

.photo-category-thumbs img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    display: block;
}

.photo-category-footer {
    padding: 12px 14px 14px;
    color: #666;
    font-size: 0.9em;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.photo-category-footer .cta {
    color: #2a5d9f;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* 갤러리 뷰 */
.photo-gallery-toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: space-between;
    padding: 12px 0 14px;
}

.photo-back-btn {
    border: 1px solid #e9ecef;
    background: #fff;
    padding: 8px 12px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.photo-back-btn:hover {
    background: #f8f9fa;
    transform: translateY(-1px);
}

.photo-gallery-title {
    display: flex;
    align-items: center;
    gap: 10px;
}

.pill {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
    padding: 4px 10px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.9em;
}

.count {
    color: #666;
    font-weight: 600;
    font-size: 0.95em;
}

.photo-search {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 8px 10px;
    background: #fff;
    min-width: 260px;
}

.photo-search i {
    color: #999;
}

.photo-search input {
    border: none;
    outline: none;
    width: 100%;
    font-size: 0.92em;
}

/* 게시판 그리드 */
.photo-board {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 10px;
}

/* 카드 */
.photo-item {
    background: var(--bg-white, white);
    border-radius: var(--card-radius, 12px);
    overflow: hidden;
    box-shadow: var(--card-shadow, 0 2px 8px rgba(0, 0, 0, 0.08));
    transition: var(--card-transition, all 0.3s ease);
    cursor: pointer;
}

.photo-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--card-shadow-hover, 0 10px 26px rgba(0, 0, 0, 0.14));
}

.photo-card {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.photo-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.photo-item:hover .photo-card img {
    transform: scale(1.06);
}

.photo-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    color: white;
    padding: 20px 15px 15px;
}

.photo-info h4 {
    margin: 0 0 5px 0;
    font-size: 1.05em;
    font-weight: bold;
}

.photo-info p {
    margin: 0 0 8px 0;
    font-size: 0.9em;
    opacity: 0.9;
}

.category {
    display: inline-block;
    background: #4facfe;
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.8em;
    font-weight: 500;
}

/* 섹션 전환 + 애니메이션 */
.section.visible { display: block; animation: fadeInUp 0.5s ease-out; }

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to   { opacity: 1; transform: translateY(0); }
}

.hidden {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease;
}

.visible {
    opacity: 1;
    transform: translateY(0);
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(15px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes slideIn {
    from { transform: translateY(-50px); opacity: 0; }
    to   { transform: translateY(0); opacity: 1; }
}

@keyframes slideInRight {
    from { transform: translateX(100%); opacity: 0; }
    to   { transform: translateX(0); opacity: 1; }
}

/* ==================== 모달 (기존 유지) ==================== */
.photo-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.photo-modal.show {
    display: flex;
    opacity: 1;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    cursor: pointer;
}

.modal-content {
    position: relative;
    width: 90%;
    max-width: 1200px;
    height: 90%;
    margin: auto;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.photo-modal.show .modal-content {
    transform: scale(1);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
}

.modal-title {
    color: #333;
    font-size: 1.35em;
    font-weight: 700;
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5em;
    color: #666;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
}

.modal-close:hover {
    background: #e9ecef;
    color: #333;
}

.modal-body {
    flex: 1;
    display: flex;
    overflow: hidden;
}

.modal-image-container {
    flex: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
    position: relative;
}

.modal-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 8px;
}

.modal-info {
    flex: 1;
    padding: 25px;
    background: #fff;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-width: 300px;
}

.modal-meta {
    margin-bottom: 20px;
}

.modal-date, .modal-category {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
    font-size: 0.95em;
}

.modal-date i, .modal-category i {
    margin-right: 8px;
    color: #4facfe;
    width: 16px;
}

.modal-category .category-text {
    background: #4facfe;
    color: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.85em;
    font-weight: 500;
}

.modal-description { flex: 1; margin-bottom: 20px; }
.description-text { color: #555; line-height: 1.6; font-size: 0.95em; }

.modal-navigation {
    display: flex;
    justify-content: space-between;
    padding: 15px 25px;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
}

.nav-btn {
    background: linear-gradient(135deg, #162d55 0%, #24488c 100%);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9em;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-btn:hover {
    background: linear-gradient(135deg, #0f1f3d 0%, #162d55 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(22, 45, 85, 0.3);
}

.nav-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* ==================== 반응형 ==================== */
@media (max-width: 992px) {
    .photo-board { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 15px; }
    .photo-card { height: 180px; }
    .photo-search { min-width: 220px; }
}

@media (max-width: 768px) {
    .navbar { flex-direction: column; gap: 10px; padding: 12px 3%; }
    .auth-section { margin-right: 0; }
    .container { padding-top: 140px; } /* 세로 배치 navbar 높이 보정 */

    .section { padding: 18px 15px; }
    .photo-board { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
    .photo-card { height: 160px; }

    .section-nav {
        position: sticky;
        top: 0;
        background: white;
        z-index: 100;
        padding: 10px 0;
        margin-bottom: 20px;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    }

    .photo-gallery-toolbar {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .photo-search { min-width: 100%; }

    .modal-body { flex-direction: column; }
    .modal-info { min-width: auto; padding: 20px; }
}

@media (max-width: 576px) {
    .photo-board { grid-template-columns: 1fr; gap: 15px; }
    .photo-card { height: 200px; }
    .photo-categories { grid-template-columns: 1fr; }
    .photo-category-thumbs { height: 180px; }
    .photo-category-thumbs img { height: 180px; }
}


/* ==================== (추가) Photo: Year Cards / Year Chips / Grouped View ==================== */

/* 년도 카드 그리드 */
.photo-years {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
    margin-top: 12px;
}

/* 카테고리/년도 섹션 타이틀 */
.photo-subsection {
    margin-top: 18px;
}
.photo-subsection-title {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 800;
    color: #005792;
    margin: 8px 0 6px;
    font-size: 0.98em;
    opacity: 0.95;
}

/* 갤러리 우측 버튼 */
.photo-gallery-right {
    display: flex;
    align-items: center;
    gap: 10px;
}
.photo-clear-btn {
    border: 1px solid #e9ecef;
    background: #fff;
    padding: 8px 12px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9em;
    white-space: nowrap;
}
.photo-clear-btn:hover {
    background: #f8f9fa;
    transform: translateY(-1px);
}

/* Year chips */
.photo-year-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 6px 0 14px;
    padding: 8px 0 2px;
}
.year-chip {
    border: 1px solid rgba(0,0,0,0.12);
    border-radius: 999px;
    padding: 6px 10px;
    background: #fff;
    cursor: pointer;
    font-weight: 800;
    opacity: .85;
    transition: transform .15s ease, background .15s ease, border-color .15s ease;
}
.year-chip:hover {
    transform: translateY(-1px);
    background: #f8fbff;
    border-color: #cfe7ff;
}
.year-chip.active {
    opacity: 1;
    border-color: rgba(0,0,0,0.35);
    background: #fff3cd;
}

/* 그룹핑 모드: photoBoard 자체는 블록 컨테이너로 */
.photo-board.year-grouped {
    display: block;
    gap: 0;
}

/* 연도 섹션 */
.photo-year-section {
    margin: 18px 0 22px;
}
.photo-year-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 0 0 10px;
    padding: 10px 12px;
    background: #f8fbff;
    border: 1px solid #e6f2ff;
    border-radius: 12px;
}
.photo-year-title {
    font-size: 1.05rem;
    font-weight: 900;
    color: #005792;
}
.photo-year-count {
    font-weight: 800;
    opacity: .75;
}

/* 섹션 내부 그리드 */
.photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

/* 반응형 보정 */
@media (max-width: 992px) {
    .photo-grid { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 15px; }
}
@media (max-width: 768px) {
    .photo-gallery-right { flex-direction: column; align-items: stretch; }
    .photo-clear-btn { width: 100%; justify-content: center; }
    .photo-grid { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
}
@media (max-width: 576px) {
    .photo-grid { grid-template-columns: 1fr; gap: 15px; }
    .photo-years { grid-template-columns: 1fr; }
}
