@charset "utf-8";

/* ============================================================
   파크골프 게시판 통합 스타일시트
   테마: 페어웨이 그린 + 어스톤 + 스카이블루
   지원: 반응형, 다크모드
   ============================================================ */

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   1. 전역 변수
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
:root {
    /* 잔디 그린 계열 */
    --color-primary:        #2d6a4f;
    --color-primary-hover:  #1b4332;
    --color-primary-light:  #d8f3dc;
    --color-primary-mid:    #52b788;

    /* 어스톤 (황토·나무) */
    --color-earth:          #8b6914;
    --color-earth-light:    #fdf3dc;

    /* 하늘 파랑 */
    --color-sky:            #0077b6;
    --color-sky-light:      #e0f4fd;

    /* 상태 */
    --color-danger:         #c0392b;
    --color-warning:        #e67e22;
    --color-success:        #27ae60;

    /* 배경 */
    --bg-card:   #ffffff;
    --bg-muted:  #f4f9f6;
    --bg-white:  #ffffff;

    /* 텍스트 */
    --text:        #1a2e22;
    --text-muted:  #5a7a68;
    --text-light:  #94a3a8;

    /* 테두리 */
    --border:       #c8e6d4;
    --border-dark:  #95c4aa;

    /* 그림자 */
    --shadow-sm: 0 1px 4px rgba(45,106,79,.10);
    --shadow-md: 0 4px 14px rgba(45,106,79,.12);

    /* 형태 */
    --radius:    8px;
    --radius-lg: 12px;
    --radius-xl: 16px;

    --transition: 0.2s ease-in-out;
}

[data-theme="dark"] {
    --bg-card:      #1a2a20;
    --bg-muted:     #142019;
    --bg-white:     #0e1a13;
    --text:         #e8f5e9;
    --text-muted:   #81c995;
    --text-light:   #4a7a58;
    --border:       #2d4a38;
    --border-dark:  #3d6a4a;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   2. 폰트 크기
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
body,
#bo_list,
.td_subject .bo_tit a,
.cmt_contents p,
#bo_v_con,
.wr_content { font-size: 16px; }

@media (max-width: 768px) {
    body,
    #bo_list,
    .td_subject .bo_tit a,
    .cmt_contents p,
    #bo_v_con { font-size: 14px; }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   3. 공통 컨테이너
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
#bo_list, #bo_v, #bo_w {
    width: 100%;
    background: var(--bg-card);
    border-radius: var(--radius);
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   4. 목록 상단 (게시글수 + 검색 + 버튼)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* 버튼 그룹 */
.btn_bo_user {
    display: flex; gap: 6px;
    margin: 0; padding: 0; list-style: none;
    flex-shrink: 0;
}

.btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 8px 16px; border-radius: 30px;
    font-size: 0.8rem; font-weight: 600;
    text-decoration: none; cursor: pointer;
    transition: all var(--transition);
}

.btn_b01 {
    background: var(--bg-card);
    border: 1.5px solid var(--border-dark);
    color: var(--text-muted);
}
.btn_b01:hover {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.btn_b02 {
    background: var(--color-primary);
    border: 1.5px solid var(--color-primary);
    color: #fff;
}
.btn_b02:hover {
    background: var(--color-primary-hover);
    border-color: var(--color-primary-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

/* ★ btn_b03: 프린트·스크랩·공유 보조 버튼
   연한 그린 배경 + 진한 그린 글씨 → 가독성 확보
   hover: 그린 채움 + 흰 글씨                          */
.btn_b03 {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 7px 16px;
    background: var(--bg-card);
    border: 1.5px solid var(--border-dark) !important;
    border-radius: var(--radius);
    font-size: 0.82rem; font-weight: 600;
    color: var(--text-muted); text-decoration: none;
    transition: all var(--transition);
}
.btn_b03:hover {
    background: var(--color-primary); border-color: var(--color-primary);
    color: #fff; transform: translateY(-1px); box-shadow: var(--shadow-sm);
}
[data-theme="dark"] .btn_b03 {
    background: rgba(82,183,136,.15);
    border-color: var(--color-primary-mid);
    color: #81c995;
}
[data-theme="dark"] .btn_b03:hover {
    background: var(--color-primary);
    color: #fff;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   7. 게시글 읽기
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
#bo_v_title { padding: 24px 24px 16px; border-bottom: 1px solid var(--border); }

.bo_v_cate {
    display: inline-block;
    background: var(--color-primary-light);
    color: var(--color-primary);
    font-size: 0.75rem; font-weight: 700;
    padding: 4px 12px; border-radius: 20px;
    margin-right: 10px;
    border: 1px solid var(--border-dark);
}
.bo_v_tit {
    font-size: 1.3rem; font-weight: 700;
    color: var(--text); line-height: 1.4;
    word-break: break-word; margin-top: 8px;
}

#bo_v_info {
    display: flex; flex-wrap: wrap; align-items: center;
    gap: 16px; padding: 12px 10px;
    background: var(--bg-muted); border-bottom: 1px solid var(--border);
    font-size: 0.85rem; color: var(--text-muted);
    border-radius: var(--radius);
}
#bo_v_info h2, #bo_v_atc h2, #bo_vc h2, #bo_vc_w h2 { display: none; }
#bo_v_info strong { color: var(--text); font-weight: 600; }
#bo_v_info i { margin-right: 4px; color: var(--color-primary-mid); }

#bo_v_atc { padding: 24px; }
#bo_v_con { line-height: 1.75; color: var(--text); word-break: break-word; }
#bo_v_con img { max-width: 100%; height: auto; border-radius: var(--radius); }

/* post-toolbar */
.post-toolbar {
    display: flex; flex-wrap: wrap; align-items: center;
    justify-content: space-between; gap: 16px;
    padding: 14px 24px;
    border-bottom: 1px solid var(--border);
}
.toolbar-left  { display: flex; gap: 10px; }
.toolbar-right { display: flex; gap: 8px; flex-wrap: wrap; }

.circle-button {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 7px 16px;
    background: var(--bg-card);
    border: 1.5px solid var(--border-dark);
    border-radius: 30px;
    font-size: 0.82rem; font-weight: 600;
    color: var(--text-muted); text-decoration: none;
    transition: all var(--transition);
}
.circle-button:hover {
    background: var(--color-primary); border-color: var(--color-primary);
    color: #fff; transform: translateY(-1px); box-shadow: var(--shadow-sm);
}
.circle-button .count { font-weight: 700; color: var(--color-primary); }
.circle-button:hover .count { color: #fff; }

/* 추천/비추천 */
#bo_v_act { display: flex; justify-content: center; gap: 20px; margin-top: 30px; }
.bo_v_good, .bo_v_nogood {
    display: inline-block; width: 90px; line-height: 24px;
    padding: 10px; border-radius: var(--radius);
    text-align: center; text-decoration: none;
    transition: all var(--transition); font-weight: 700;
}
.bo_v_good  { background: var(--color-primary-light); border: 1.5px solid var(--color-primary);  color: var(--color-primary); }
.bo_v_good:hover  { background: var(--color-primary);  color: #fff; transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.bo_v_nogood{ background: #fff0ef; border: 1.5px solid var(--color-danger); color: var(--color-danger); }
.bo_v_nogood:hover{ background: var(--color-danger); color: #fff; transform: translateY(-2px); box-shadow: var(--shadow-sm); }

/* 첨부파일, 링크 */
#bo_v_file, #bo_v_link { margin: 20px 24px; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
#bo_v_file h2, #bo_v_link h2 {
    padding: 12px 20px; background: var(--bg-muted);
    border-bottom: 1px solid var(--border);
    font-size: 0.85rem; font-weight: 700; color: var(--color-primary);
    display: flex; align-items: center; gap: 8px;
}
#bo_v_file ul, #bo_v_link ul { margin: 0; padding: 0; list-style: none; }
#bo_v_file li, #bo_v_link li { padding: 11px 20px; border-bottom: 1px solid var(--border); font-size: 0.85rem; }
#bo_v_file li:last-child, #bo_v_link li:last-child { border-bottom: none; }
#bo_v_file a, #bo_v_link a { color: var(--color-sky); text-decoration: none; }
#bo_v_file a:hover, #bo_v_link a:hover { color: var(--color-primary); text-decoration: underline; }

/* 이전/다음 */
/* 1. 부모 (ul): 두 개의 li를 가로로 나열 */
.bo_v_nb { 
    display: flex; 
    list-style: none; 
    margin: 0; padding: 0; 
    border-top: 1px solid var(--border); 
    width: 100%;
}

/* 2. 각 항목 (li): 너비를 50%씩 나누어 가짐 */
.bo_v_nb li { 
    flex: 1;             /* 동일하게 50%씩 배분 */
    display: flex;       /* 내부 요소 정렬을 위해 flex 적용 */
    align-items: center;  /* 수직 중앙 정렬 (날짜 치우침 해결) */
    padding: 14px 20px; 
    border-bottom: 1px solid var(--border); 
    box-sizing: border-box;
    overflow: hidden;    /* 넘치는 텍스트 숨김 */
}

/* 이전글과 다음글 사이에 세로 구분선 (선택사항) */
.bo_v_nb li:first-child { 
    border-right: 1px solid var(--border); 
}

/* 3. 라벨 (이전글/다음글) */
.nb_tit { 
    font-size: 0.75rem; 
    font-weight: 700; 
    color: var(--color-primary); 
    margin-right: 10px; 
    flex-shrink: 0;
    white-space: nowrap;
}

/* 4. 제목 링크 */
.bo_v_nb li a { 
    flex: 1;             /* 제목이 중간 공간 차지 */
    font-size: 0.85rem; 
    color: var(--text); 
    text-decoration: none;
    white-space: nowrap; 
    overflow: hidden; 
    text-overflow: ellipsis; /* 제목 길면 ... 처리 */
}

/* 5. 날짜: 오른쪽 끝 수직 중앙 */
.nb_date { 
    font-size: 0.7rem; 
    color: var(--text-light); 
    margin-left: 10px; 
    flex-shrink: 0;
    white-space: nowrap;
}

/* 📱 모바일 대응: 화면이 좁아지면 다시 위아래로 쌓기 */
@media (max-width: 768px) {
    .bo_v_nb { flex-direction: column; }
    .bo_v_nb li:first-child { border-right: none; }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   8. 댓글 목록
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
.cmt_btn {
    width: 100%; text-align: left; border: 0;
    border-bottom: 2px solid var(--color-primary);
    background: var(--bg-card); font-weight: 700;
    margin: 30px 0 0; padding: 0 0 15px; cursor: pointer;
}
.cmt_btn span.total { position: relative; display: inline-block; margin-right: 5px; color: var(--color-primary); }
.cmt_btn span.total b { font-size: 1.2rem; color: var(--text); }
.cmt_btn span.total:after { position: absolute; bottom: -17px; left: 0; background: var(--color-primary); content: ""; width: 100%; height: 2px; }
.cmt_btn span.cmt_more { float: right; margin-top: 5px; }
.cmt_btn span.cmt_more::before { content: "\f107"; font-family: "Font Awesome 6 Free"; font-weight: 900; color: var(--text-muted); }
.cmt_btn_op span.cmt_more::before { content: "\f106"; }

#bo_vc { margin: 10px 0; }
#bo_vc_empty { padding: 60px 20px; text-align: center; background: var(--bg-muted); border-radius: var(--radius); color: var(--text-muted); font-size: 0.9rem; }

#bo_vc article {
    position: relative; display: flex; gap: 12px;
    padding: 16px; margin: 16px 0;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: box-shadow var(--transition), border-color var(--transition);
}
#bo_vc article:hover { border-color: var(--border-dark); box-shadow: var(--shadow-sm); }
#bo_vc article[style*="margin-left"] { margin-left: 40px !important; border-left: 3px solid var(--color-primary-mid); }

.pf_img { flex-shrink: 0; }
.pf_img img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; border: 2px solid var(--border-dark); }
.cm_wrap { flex: 1; position: relative; }

.info { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 10px; font-size: 0.8rem; }
.info .sv_member, .info .sv_guest { font-weight: 700; color: var(--color-primary); }
.bo_vc_hdinfo { color: var(--text-light); font-size: 0.7rem; display: inline-flex; align-items: center; gap: 4px; }

.cmt_contents {
    background: var(--bg-muted); border: 1px solid var(--border);
    border-radius: 0 var(--radius-lg) var(--radius-lg) var(--radius);
    padding: 14px 16px; position: relative; margin-top: 8px;
}
.cmt_contents::before {
    content: ""; position: absolute; top: -8px; left: 16px;
    width: 0; height: 0; border-style: solid;
    border-width: 0 8px 8px 8px;
    border-color: transparent transparent var(--border) transparent;
}
.cmt_contents::after {
    content: ""; position: absolute; top: -7px; left: 16px;
    width: 0; height: 0; border-style: solid;
    border-width: 0 8px 8px 8px;
    border-color: transparent transparent var(--bg-muted) transparent;
}
.cmt_contents p { margin: 0; line-height: 1.65; color: var(--text); word-break: break-word; }

.bo_vl_opt { position: absolute; top: 0; right: 0; }
.btn_opt { width: 32px; height: 32px; background: transparent; border: none; border-radius: var(--radius); color: var(--text-light); cursor: pointer; transition: all var(--transition); }
.btn_opt:hover { background: var(--color-primary-light); color: var(--color-primary); }

.bo_vc_act {
    display: none; position: absolute; right: 0; top: 35px;
    width: 110px; background: var(--bg-card);
    border: 1px solid var(--border); border-radius: var(--radius);
    padding: 6px 0; list-style: none; z-index: 100; box-shadow: var(--shadow-md);
}
.bo_vc_act:before, .bo_vc_act:after { content: ""; position: absolute; right: 12px; width: 0; height: 0; border-style: solid; }
.bo_vc_act:before { top: -6px; border-width: 0 6px 6px 6px; border-color: transparent transparent var(--border) transparent; }
.bo_vc_act:after  { top: -5px; border-width: 0 6px 6px 6px; border-color: transparent transparent var(--bg-card) transparent; }
.bo_vc_act li { border-bottom: 1px solid var(--border); }
.bo_vc_act li:last-child { border-bottom: none; }
.bo_vc_act li a { display: block; padding: 9px 16px; font-size: 0.78rem; color: var(--text-muted); text-decoration: none; transition: all var(--transition); }
.bo_vc_act li a:hover { background: var(--color-primary-light); color: var(--color-primary); font-weight: 600; }

.circle-badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 30px; font-size: 0.7rem; text-decoration: none; font-weight: 600; transition: all var(--transition); }
.circle-badge-good    { background: var(--color-primary-light); border: 1px solid var(--color-primary); color: var(--color-primary); }
.circle-badge-good:hover { background: var(--color-primary); color: #fff; }
.circle-badge-nogood  { background: #fff0ef; border: 1px solid var(--color-danger); color: var(--color-danger); }
.circle-badge-nogood:hover { background: var(--color-danger); color: #fff; }
.bo_cv_act { text-align: right; margin: 5px; }
.bo_cv_act li { display: inline-block; margin-left: 5px; }
.bo_cv_act li strong { font-weight: bold; }

[data-theme="dark"] .circle-badge-good   { background: rgba(82,183,136,.15); border-color: var(--color-primary-mid); color: #81c995; }
[data-theme="dark"] .circle-badge-nogood { background: rgba(192,57,43,.15);  border-color: var(--color-danger);     color: #f87171; }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   9. 댓글 쓰기 폼
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
.bo_vc_w { overflow: hidden; }
#commentEditor { width: 100%; background: var(--bg-white); }
#char_cnt { display: block; text-align: right; margin-bottom: 8px; font-size: 0.7rem; color: var(--text-muted); }
#char_count { font-weight: 700; color: var(--color-primary); }

#commentEditor textarea {
    width: 100%; min-height: 120px; padding: 12px;
    border: 1px solid var(--border); border-radius: var(--radius);
    font-family: inherit; font-size: 0.85rem; line-height: 1.5;
    background: var(--bg-white); color: var(--text); resize: vertical;
    transition: border-color var(--transition);
}
#commentEditor textarea:focus { outline: none; border-color: var(--color-primary); box-shadow: 0 0 0 3px rgba(45,106,79,.1); }
#commentEditor iframe { width: 100%; border: 1px solid var(--border) !important; border-radius: var(--radius); background: var(--bg-white); }

.bo_vc_w_wr { padding: 12px; background: var(--bg-muted); border-radius: var(--radius); border-top: 1px solid var(--border); }

.bo_vc_w_info { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 16px; }
.bo_vc_w_info .frm_input {
    flex: 1; min-width: 130px; height: 40px; padding: 0 14px;
    border: 1px solid var(--border); border-radius: var(--radius);
    font-size: 0.85rem; background: var(--bg-white); color: var(--text);
    transition: border-color var(--transition);
}
.bo_vc_w_info .frm_input:focus { outline: none; border-color: var(--color-primary); box-shadow: 0 0 0 3px rgba(45,106,79,.1); }

.btn_confirm { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.secret_cm { display: inline-flex; align-items: center; gap: 6px; }
.secret_cm input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--color-primary); }
.secret_cm label { font-size: 0.8rem; color: var(--text-muted); cursor: pointer; }

#captcha { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; border: none; padding: 0; margin: 0; }
#captcha_img { height: 40px; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; }
#captcha_key { width: 120px; height: 40px; padding: 0 12px; border: 1px solid var(--border); border-radius: var(--radius); font-size: 0.85rem; background: var(--bg-white); color: var(--text); }
#captcha_mp3, #captcha_reload { width: 40px; height: 40px; background: var(--bg-white); border: 1px solid var(--border); border-radius: var(--radius); cursor: pointer; transition: all var(--transition); color: var(--text-muted); }
#captcha_mp3:hover, #captcha_reload:hover { background: var(--color-primary); border-color: var(--color-primary); color: #fff; }
#captcha_info { font-size: 0.7rem; color: var(--text-light); }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   10. 글쓰기 폼
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
.write_div { margin-bottom: 16px; }

.bo_w_select select {
    width: 100%; max-width: 300px; height: 46px; padding: 0 16px;
    border: 1px solid var(--border); border-radius: var(--radius);
    background: var(--bg-white); color: var(--text); cursor: pointer;
    transition: border-color var(--transition);
}
.bo_w_select select:focus { outline: none; border-color: var(--color-primary); }

.bo_w_info { background: var(--bg-muted); border-radius: var(--radius); overflow: hidden; margin-bottom: 20px; border: 1px solid var(--border); }
.info-title { background: var(--color-primary); color: #fff; padding: 12px 20px; font-size: 0.9rem; font-weight: 700; }
.info-title:before { content: '\f007'; font-family: "Font Awesome 6 Free"; font-weight: 900; margin-right: 8px; opacity: .8; }
.info-fields-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 16px; padding: 20px; }
.info-field { display: flex; flex-direction: column; gap: 6px; }
.field-label { font-size: 0.8rem; font-weight: 700; color: var(--text-muted); }
.field-label.required:after { content: '*'; color: var(--color-danger); margin-left: 4px; }
.info-field .frm_input { height: 46px; padding: 0 16px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-white); color: var(--text); width: 100%; transition: border-color var(--transition); }
.info-field .frm_input:focus { outline: none; border-color: var(--color-primary); box-shadow: 0 0 0 3px rgba(45,106,79,.1); }

.bo_v_option { display: flex; flex-wrap: wrap; gap: 20px; margin: 0; padding: 0; list-style: none; }
.chk_box { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; }
.chk_box input[type="checkbox"] { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
.chk_box label { position: relative; padding-left: 28px; cursor: pointer; font-size: 0.85rem; color: var(--text-muted); transition: color var(--transition); }
.chk_box label:before { content: ''; position: absolute; left: 0; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; border: 2px solid var(--border-dark); border-radius: 4px; background: var(--bg-white); transition: all var(--transition); }
.chk_box label:after { content: '\f00c'; font-family: "Font Awesome 6 Free"; font-weight: 900; position: absolute; left: 3px; top: 50%; transform: translateY(-50%) scale(0); font-size: 11px; color: #fff; transition: all var(--transition); }
.chk_box input[type="checkbox"]:checked + label:before { background: var(--color-primary); border-color: var(--color-primary); }
.chk_box input[type="checkbox"]:checked + label:after { transform: translateY(-50%) scale(1); }
.chk_box input[type="checkbox"]:checked + label { color: var(--color-primary); }

.bo_w_tit .full_input { flex: 1; min-width: 0; width: auto; height: 50px; padding: 0 16px; border: 1px solid var(--border); border-radius: var(--radius); font-size: 1rem; background: var(--bg-white); color: var(--text); transition: border-color var(--transition); }
.bo_w_tit .full_input:focus { outline: none; border-color: var(--color-primary); box-shadow: 0 0 0 3px rgba(45,106,79,.1); }

.wr_content { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
#char_count_desc { background: var(--bg-muted); padding: 12px 16px; margin: 0; font-size: 0.8rem; border-bottom: 1px solid var(--border); color: var(--text-muted); }
#char_count_wrap { text-align: right; padding: 8px 12px; background: var(--bg-muted); border-top: 1px solid var(--border); font-size: 0.75rem; color: var(--text-muted); }

.bo_w_link { display: flex; align-items: center; gap: 10px; }
.bo_w_link label { width: 40px; height: 40px; background: var(--color-primary-light); border: 1px solid var(--border-dark); border-radius: var(--radius); display: inline-flex; align-items: center; justify-content: center; color: var(--color-primary); }
.bo_w_link .full_input { flex: 1; height: 46px; padding: 0 16px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-white); color: var(--text); }

.bo_w_flie {
    background: var(--bg-muted);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 10px 14px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}
/* bo_w_flie 안에 중첩된 write_div margin 제거 */
.bo_w_flie.write_div { margin-bottom: 12px; }
.bo_w_flie .write_div { margin-bottom: 0 !important; }
.file_wr { display: contents; } /* 자식 요소들이 bo_w_flie flex에 직접 참여 */
/* 파일설명 입력란 */
.bo_w_flie .frm_input { flex: 1; min-width: 180px; height: 38px; }
.lb_icon { width: 40px; height: 40px; background: var(--color-primary-light); border: 1px solid var(--border-dark); border-radius: var(--radius); display: inline-flex; align-items: center; justify-content: center; color: var(--color-primary); }
.frm_file::file-selector-button { padding: 6px 12px; background: var(--bg-white); border: 1px solid var(--border); border-radius: var(--radius); cursor: pointer; color: var(--text-muted); font-size: 0.82rem; transition: all var(--transition); }
.frm_file::file-selector-button:hover { background: var(--color-primary); border-color: var(--color-primary); color: #fff; }

.btn_confirm.write_div { display: flex; justify-content: center; gap: 12px; padding: 20px; background: var(--bg-muted); border-radius: var(--radius); margin-top: 20px; border: 1px solid var(--border); }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   11. 반응형 800px 이하
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 800px) {
    #bo_btn_top { flex-wrap: wrap; }
    #bo_list_total { order: 1; }
    .btn_bo_user { order: 2; margin-left: auto; }
    #bo_sch_wrap { order: 3; min-width: 100%; max-width: 100%; margin-top: 5px; }

    .likeTbl > ul { display: block; }
    .likeTbl > ul > li { display: block; padding: 12px 15px; border-bottom: 1px solid var(--border); }
    .likeTbl > ul > li > div { display: block; padding: 4px 0; border: none; }
    .likeTbl > ul > li.likeTblTh { display: none; }
    .mvInlineN { display: none; }

    .td_chk     { display: inline-block !important; width: auto; margin-right: 8px; }
    .td_num2    { display: inline-block !important; width: auto; min-width: 40px; background: var(--color-primary-light); color: var(--color-primary); padding: 2px 8px; border-radius: 20px; font-size: 0.7rem; margin-right: 8px; font-weight: 700; }
    .td_subject { display: inline-block !important; width: calc(100% - 110px); margin: 0; vertical-align: middle; }
    .td_subject .bo_tit a { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .td_name, .td_num, .td_datetime { display: inline-block !important; font-size: 0.7rem; margin-right: 12px; }

    #bo_v_title { padding: 18px; }
    .bo_v_tit   { font-size: 1.1rem; }
    #bo_v_info  { padding: 10px 18px; font-size: 0.75rem; }
    .post-toolbar { padding: 12px 18px; flex-direction: column; align-items: stretch; }
    .toolbar-left, .toolbar-right { justify-content: center; }
    #bo_v_atc   { padding: 18px; }
    #bo_v_file, #bo_v_link { margin: 16px 18px; }
    .bo_fx { padding: 16px 18px; flex-direction: column; align-items: stretch; }
    .bo_v_nb { flex-direction: column; }
    .bo_v_nb li:first-child { border-right: none; }

    #bo_vc article { padding: 12px; gap: 10px; }
    #bo_vc article[style*="margin-left"] { margin-left: 20px !important; }
    .pf_img img { width: 40px; height: 40px; }
    .bo_vc_w_info { flex-direction: column; align-items: stretch; }
    .btn_confirm { flex-direction: column; align-items: stretch; }
    .secret_cm { justify-content: center; }

    .info-fields-grid { grid-template-columns: 1fr; gap: 12px; padding: 16px; }
    .bo_w_tit .full_input { height: 46px; font-size: 0.9rem; }
    .btn_confirm.write_div { flex-direction: column-reverse; }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   12. 480px 이하
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 480px) {
    .likeTbl > ul > li { padding: 10px 12px; }
    .td_subject { width: calc(100% - 95px); }
    .td_subject .bo_tit a { white-space: normal; word-break: break-word; }
    .td_name, .td_num, .td_datetime { font-size: 0.65rem; margin-right: 8px; }
    .pf_img img { width: 36px; height: 36px; }
    .info-fields-grid { padding: 12px; gap: 10px; }
    .info-title { padding: 12px 16px; font-size: 0.85rem; }
    .write_div { padding: 0 12px; }
    .circle-button { padding: 6px 12px; font-size: 0.75rem; }
    .btn_b03 { padding: 5px 10px; font-size: 0.75rem; }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   13. 임시저장 버튼 및 팝업
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.bo_w_tit {
    position: relative;
}

#autosave_wrapper {
    position: relative;
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: nowrap;   /* 한 줄 고정 */
}

#btn_autosave {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: var(--color-primary-light);
    border: 1.5px solid var(--color-primary-mid);
    border-radius: var(--radius); 
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--color-primary);
    cursor: pointer;
    transition: all var(--transition);
    white-space: nowrap;
    flex-shrink: 0;
}

#btn_autosave:hover {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}

#autosave_count {
    font-weight: 700;
    color: var(--color-primary);
    background: rgba(45,106,79,.15);
    padding: 2px 6px;
    border-radius: 20px;
    margin-left: 4px;
}

#btn_autosave:hover #autosave_count {
    color: #fff;
    background: rgba(255,255,255,.2);
}

#autosave_pop {
    display: none;
    position: absolute;
    top: 60px;
    right: 0;
    width: 320px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    z-index: 100;
    overflow: hidden;
    animation: fadeInUp 0.2s ease;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

#autosave_pop strong {
    display: block;
    padding: 14px 18px;
    background: var(--color-primary);
    color: #fff;
    font-size: 0.85rem;
    font-weight: 600;
}

#autosave_pop strong:before {
    content: '\f0ca';
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    margin-right: 8px;
    font-size: 0.8rem;
}

#autosave_pop ul {
    max-height: 250px;
    overflow-y: auto;
    margin: 0;
    padding: 0;
    list-style: none;
}

#autosave_pop li {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background var(--transition);
}

#autosave_pop li:hover { background: var(--bg-muted); }

#autosave_pop li a {
    color: var(--text);
    text-decoration: none;
    font-size: 0.8rem;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-right: 10px;
}

#autosave_pop li a:hover { color: var(--color-primary); text-decoration: underline; }

.autosave_del {
    background: none;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    font-size: 0.7rem;
    padding: 4px 8px;
    border-radius: var(--radius);
    transition: all var(--transition);
}
.autosave_del:hover { background: var(--color-danger); color: #fff; }

#autosave_pop div:last-child {
    padding: 10px;
    background: var(--bg-muted);
    border-top: 1px solid var(--border);
    text-align: center;
}

.autosave_close {
    background: transparent;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 8px 16px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: all var(--transition);
}
.autosave_close:hover { background: var(--color-primary); border-color: var(--color-primary); color: #fff; }

#autosave_pop.show { display: block; }

@media (max-width: 768px) {
    #autosave_wrapper { flex-direction: column; align-items: stretch; }
    #btn_autosave { width: 100%; justify-content: center; }
    #autosave_pop { width: calc(100% - 20px); right: 10px; left: 10px; top: 100px; }
}

[data-theme="dark"] #autosave_pop { background: #1a2a20; border-color: #2d4a38; }
[data-theme="dark"] #autosave_pop li { border-color: #2d4a38; }
[data-theme="dark"] #autosave_pop li a { color: #e8f5e9; }
[data-theme="dark"] #autosave_pop div:last-child { background: #142019; border-color: #2d4a38; }
[data-theme="dark"] .autosave_close { border-color: #3d6a4a; color: #81c995; }
[data-theme="dark"] .autosave_close:hover { background: var(--color-primary); color: #fff; }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   14. SNS 공유
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
.bo_v_snswr {position: relative; display: inline-block; }
.share-dropdown { position: absolute; top: 100%; right: 0; min-width: 300px; background: #fff; border: 1px solid #e0e0e0; border-radius: 8px; opacity: 0; visibility: hidden; transform: translateY(-10px); transition: all 0.3s ease; z-index: 1000; margin-top: 5px; box-shadow: 0 4px 12px rgba(0,0,0,0.1); }
.share-dropdown.active { opacity: 1; visibility: visible; transform: translateY(0); }
.share-content { padding: 20px; }
.share-buttons { display: grid; grid-template-columns: repeat(3, 1fr); gap: 15px; margin-bottom: 20px; }
.share-btn { display: flex; flex-direction: column; align-items: center; background: none; border: none; cursor: pointer; padding: 15px 10px; border-radius: 8px; transition: background 0.2s ease; text-decoration: none; color: inherit; }
.share-btn:hover { background: #f5f5f5; }
.share-btn .icon { width: 58px; height: 58px; margin-bottom: 8px; display: block; }
.share-btn .text { font-size: 12px; color: #666; font-weight: 500; }
.facebook-icon { background: url('./img/sns/shareFacebook.png') center center no-repeat;}
.kakao-icon { background: url('./img/sns/shareKakao.png') center center no-repeat;}
.line-icon { background: url('./img/sns/shareLine.png') center center no-repeat;}
.blog-icon { background: url('./img/sns/shareNaver.png') center center no-repeat;}
.band-icon { background: url('./img/sns/shareNaverBand.png') center center no-repeat;}
.twitter-icon { background: url('./img/sns/shareTwitter.png') center center no-repeat;}
.copy-section { border-top: 1px solid #f0f0f0; padding-top: 20px; }
.copy-input { display: flex; border: 1px solid #ddd; border-radius: 6px; overflow: hidden; }
.copy-input .input { flex: 1; padding: 12px 15px; border: none; background: #f9f9f9; font-size: 14px; color: #666; outline: none; }
.copy-input .copy-btn { padding: 12px 20px; background: #007bff; color: white; border: none; cursor: pointer; font-size: 14px; font-weight: 500; transition: background 0.2s ease; }
.copy-input .copy-btn:hover { background: #0056b3; color:#fff;}
.copy-success { color: #28a745; font-size: 12px; margin-top: 5px; opacity: 0; transition: opacity 0.3s ease; }
.copy-success.show { opacity: 1; }
@media (max-width: 480px) { 
	.share-dropdown { min-width: 280px; } 
	.share-content { padding: 15px; } 
	.share-buttons { gap: 10px; } 
	.share-btn { padding: 12px 8px; } 
	.share-btn .icon { width: 35px; height: 35px; } 
	.share-btn .text { font-size: 11px; } 
}
.share-overlay { position: fixed; top: 0; left: 0; right: 0; bottom: 0; z-index: 999; display: none; }
.share-overlay.active { display: block; }

/* ============================================================
   파크골프 갤러리 게시판 스타일
   ============================================================ */

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   2. 카테고리 탭
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
.gallery-cate-tabs {
    display: flex;
    gap: .5rem;
    overflow-x: auto;
    margin-bottom: 1.25rem;
    padding-bottom: .25rem;
    scrollbar-width: none;
}
.gallery-cate-tabs::-webkit-scrollbar { display: none; }
.gallery-cate-tab {
    white-space: nowrap;
    padding: .42rem 1rem;
    border-radius: 50px;
    border: 1px solid var(--border);
    background: var(--bg-white);
    color: var(--text-muted);
    font-size: .83rem;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
    text-decoration: none;
    display: inline-block;
}
.gallery-cate-tab:hover { background: var(--color-primary-light); color: var(--color-primary); }
.gallery-cate-tab.active { background: var(--color-primary); border-color: var(--color-primary); color: #fff; }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   3. 액션 바 (필터/검색/버튼)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
.gallery-action-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
    gap: .75rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: .9rem 1.2rem;
}
.gallery-filter-left {
    display: flex;
    align-items: center;
    gap: .75rem;
    flex-wrap: wrap;
}
.gallery-total {
    font-size: .88rem;
    color: var(--text-muted);
}
.gallery-total strong { color: var(--color-primary); font-weight: 700; }
.gallery-filter-chips { display: flex; gap: .4rem; }
.gallery-chip {
    padding: .3rem .8rem;
    border-radius: 50px;
    border: 1px solid var(--border);
    background: var(--bg-muted);
    color: var(--text-muted);
    font-size: .8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
    text-decoration: none;
    display: inline-block;
}
.gallery-chip:hover, .gallery-chip.active {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
}

.gallery-search-bar { display: flex; gap: .5rem; align-items: center; }
.gallery-search-bar form {
    display: flex; 
    align-items: center;
    gap: 0; 
}
.gallery-search-bar input {
    height: 36px; 
    padding: 0 .75rem;
    border: 1.5px solid var(--border);
    border-radius: 20px 0 0 20px; 
    font-size: .84rem;
    background: var(--bg-white);
    color: var(--text);
    width: 150px;
    box-sizing: border-box;
    outline: none;
}
.gallery-search-bar input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: none;
}

.gallery-search-bar button {
    height: 40px; 
    padding: 0 1rem; 
    border-radius: 0 var(--radius) var(--radius) 0; 
    border: 1.5px solid var(--color-primary); 
    border-left: none; 
    background: var(--color-primary); 
    color: #fff; 
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0; 
    transition: background 0.2s;
}

.gallery-view-toggle { display: flex; gap: .35rem; }
.gallery-view-btn {
    width: 34px; height: 34px;
    border: 1px solid var(--border);
    background: var(--bg-muted);
    color: var(--text-muted);
    border-radius: var(--radius);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all .2s;
}
.gallery-view-btn.active, .gallery-view-btn:hover {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
}
.btn-write-gallery {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .5rem 1.1rem;
    background: var(--color-primary);
    color: #fff;
    border: none;
    border-radius: var(--radius);
    font-size: .85rem;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
    transition: background .2s;
}
.btn-write-gallery:hover { background: var(--color-primary-hover); color: #fff; }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   4. 갤러리 그리드
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
.gallery-grid-wrap {
    display: grid;
    gap: 1rem;
    margin-bottom: 2rem;
}
.gallery-grid-wrap.list-view { grid-template-columns: 1fr !important; gap: .75rem; }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   5. 갤러리 카드
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
.gallery-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    overflow: hidden;
    cursor: pointer;
    transition: transform .25s, box-shadow .25s, border-color .25s;
}
.gallery-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0,0,0,.15);
    border-color: var(--color-primary);
}
.gallery-thumb {
    position: relative;
    width: 100%;
    padding-bottom: 66.67%;
    overflow: hidden;
    background: var(--bg-muted);
}
.gallery-thumb img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .4s ease;
}
.gallery-card:hover .gallery-thumb img { transform: scale(1.06); }
.gallery-thumb-placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    gap: .5rem;
}
.gallery-thumb-placeholder i { font-size: 2.5rem; }
.gallery-thumb-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,.55) 0%, transparent 55%);
    opacity: 0;
    transition: opacity .25s;
    display: flex;
    align-items: flex-end;
    padding: .75rem;
    z-index: 2;
}
.gallery-card:hover .gallery-thumb-overlay { opacity: 1; }
.gallery-overlay-actions { display: flex; gap: .5rem; }
.gallery-overlay-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .2);
    backdrop-filter: blur(4px);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, .3);
    cursor: pointer;
    font-size: .85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .18s;
}
.gallery-overlay-btn:hover { background: var(--color-primary); color: #fff; }
.gallery-thumb-badges {
    position: absolute;
    top: .6rem; left: .6rem;
    display: flex;
    gap: .35rem;
    z-index: 3;
}
.gallery-card-badge {
    padding: .18rem .55rem;
    border-radius: 50px;
    font-size: .7rem;
    font-weight: 700;
    backdrop-filter: blur(4px);
}
.gallery-badge-notice { background: rgba(245,158,11,.9); color: #fff; }
.gallery-badge-hot    { background: rgba(220,38,38,.9);  color: #fff; }
.gallery-badge-cat    { background: rgba(0,0,0,.55);     color: #fff; }
.gallery-badge-new    { background:#e74c3c; color:#fff; animation:rrPulse 1.6s infinite; }
@keyframes rrPulse { 0%,100%{opacity:1} 50%{opacity:.7} }

.gallery-file-count {
    position: absolute;
    top: .6rem; right: .6rem;
    background: rgba(0,0,0,.6);
    color: #fff;
    border-radius: var(--radius);
    padding: .15rem .5rem;
    font-size: .72rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: .25rem;
    z-index: 3;
    backdrop-filter: blur(4px);
}
.gallery-card-info { padding: .85rem 1rem; }
.gallery-card-title {
    font-size: .92rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: .5rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.4;
}
.gallery-card-title .cmt-cnt { color: var(--color-primary); font-size: .82rem; }
.gallery-card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .5rem;
}
.gallery-card-author {
    display: flex;
    align-items: center;
    gap: .35rem;
    font-size: .8rem;
    color: var(--text-muted);
    min-width: 0;
    overflow: hidden;
}
.gallery-card-author span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gallery-card-stats {
    display: flex;
    gap: .6rem;
    font-size: .78rem;
    color: var(--text-light);
    flex-shrink: 0;
}
.gallery-card-stats span { display: flex; align-items: center; gap: .2rem; }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   5-1. 목록 하단 (버튼, 페이지네이션)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
.bo_fx {
    display: flex; flex-wrap: wrap; align-items: center;
    justify-content: space-between; gap: 12px;
    margin-top: 20px; padding-top: 10px;
}
.more_btn { display: flex; gap: 6px; margin: 20px 0; }

.btn_small {
    display: inline-flex; align-items: center; gap: 5px;
    padding: 7px 13px;
    background: var(--bg-muted);
    border: 1.5px solid var(--border-dark);
    border-radius: var(--radius);
    font-size: 0.75rem; font-weight: 600;
    color: var(--text-muted);
    cursor: pointer; text-decoration: none;
    transition: all var(--transition);
}
.btn_small:hover {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff; transform: translateY(-1px);
}

.pg_wrap { text-align: center; margin: 20px 0; }
.pg_wrap a, .pg_wrap strong {
    display: inline-block; padding: 7px 13px; margin: 0 2px;
    border-radius: var(--radius); font-size: 0.8rem; font-weight: 600;
    text-decoration: none; transition: all var(--transition);
}
.pg_wrap a { background: var(--bg-muted); border: 1px solid var(--border); color: var(--text-muted); }
.pg_wrap a:hover { background: var(--color-primary-light); border-color: var(--color-primary); color: var(--color-primary); }
.pg_wrap strong { background: var(--color-primary); border: 1px solid var(--color-primary); color: #fff; }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   6. 리스트 뷰
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
.gallery-grid-wrap.list-view .gallery-card {
    display: flex;
    flex-direction: row;
    border-radius: var(--radius-lg);
}
.gallery-grid-wrap.list-view .gallery-thumb {
    width: 140px;
    min-width: 140px;
    padding-bottom: 0;
    height: 100px;
}
.gallery-grid-wrap.list-view .gallery-card-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: .75rem 1rem;
}
.gallery-grid-wrap.list-view .gallery-card-title { -webkit-line-clamp: 1; margin-bottom: .35rem; }
.gallery-grid-wrap.list-view .gallery-thumb-overlay { display: none; }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   7. 빈 상태 & 로딩
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
.gallery-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 4rem 2rem;
    background: var(--bg-card);
    border: 1px dashed var(--border);
    border-radius: var(--radius-xl);
}
.gallery-empty-icon { font-size: 4rem; opacity: .3; margin-bottom: 1rem; }
.gallery-empty h3 { font-size: 1.1rem; font-weight: 700; color: var(--text); margin-bottom: .5rem; }
.gallery-empty p { color: var(--text-muted); font-size: .88rem; }
.gallery-loading {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    gap: .75rem;
    color: var(--text-muted);
}
.gallery-spinner {
    width: 24px; height: 24px;
    border: 3px solid var(--border);
    border-top-color: var(--color-primary);
    border-radius: 50%;
    animation: gallerySpinAnim .7s linear infinite;
}
@keyframes gallerySpinAnim { to { transform: rotate(360deg); } }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   8. 라이트박스 모달
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
.gallery-lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,.92);
    backdrop-filter: blur(8px);
}
.gallery-lightbox.open { display: flex; }
.lightbox-inner {
    position: relative;
    max-width: 92vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.lightbox-img-wrap {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    max-height: 80vh;
}
.lightbox-img-wrap img {
    max-width: 85vw;
    max-height: 80vh;
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 60px rgba(0,0,0,.5);
    display: block;
    object-fit: contain;
}
/* 좌우 버튼 - 화면 좌우에 고정 */
.lightbox-nav {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    width: 56px;
    height: 56px;
    background: rgba(255,255,255,.15);
    border: 1px solid rgba(255,255,255,.2);
    border-radius: var(--radius);
    color: #fff;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all .2s;
    z-index: 2001;
}
.lightbox-nav:hover { background: rgba(255,255,255,.3); transform: translateY(-50%) scale(1.05); }
.lightbox-prev { left: 2rem; }
.lightbox-next { right: 2rem; }
/* 닫기 버튼 - 우측 상단 고정 */
.lightbox-close {
    position: fixed;
    top: 1.5rem;
    right: 1.5rem;
    width: 48px;
    height: 48px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 4rem;
    font-weight: 300;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 2001;
    transition: all 0.2s ease;
    opacity: 0.7;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}
.lightbox-close:hover {
    opacity: 1;
    transform: scale(1.1);
    background: transparent;
    color: #ef4444;
}
.lightbox-counter {
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255,255,255,.7);
    font-size: .88rem;
    background: rgba(0,0,0,.5);
    padding: .3rem .8rem;
    border-radius: 50px;
    z-index: 2001;
}
.lightbox-info {
    position: fixed;
    bottom: 4rem;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: rgba(255,255,255,.9);
    max-width: 80vw;
    background: rgba(0,0,0,.5);
    padding: .5rem 1rem;
    border-radius: 50px;
    z-index: 2001;
}
.lightbox-info h3 { font-size: .9rem; font-weight: 600; margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   9. 상세 모달
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
.gallery-detail-img {
    width: 100%;
    border-radius: var(--radius-lg);
    margin-bottom: 1rem;
    max-height: 360px;
    object-fit: cover;
}
.gallery-detail-imgs {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: .5rem;
    margin-bottom: 1rem;
}
.gallery-detail-imgs img {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: var(--radius);
    cursor: pointer;
    border: 2px solid transparent;
    transition: border-color .2s;
}
.gallery-detail-imgs img.active,
.gallery-detail-imgs img:hover { border-color: var(--color-primary); }
.match-detail-section {
    background: var(--bg-muted);
    border-radius: var(--radius-lg);
    padding: 1rem;
    margin-bottom: 1rem;
}
.match-detail-section h4 {
    font-size: .85rem;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: .75rem;
    padding-bottom: .5rem;
    border-bottom: 1px solid var(--border);
}
.match-detail-info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: .75rem;
}
.match-detail-info-item .label { font-size: .7rem; color: var(--text-light); margin-bottom: .2rem; }
.match-detail-info-item .value { font-size: .85rem; font-weight: 500; color: var(--text); }
.match-detail-content { font-size: .88rem; line-height: 1.6; color: var(--text); }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   10. 반응형
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 1200px) {
    .gallery-grid-wrap { grid-template-columns: repeat(3, 1fr) !important; }
}
@media (max-width: 768px) {
    .gallery-hero { padding: 1.5rem; flex-direction: column; text-align: center; }
    .gallery-hero::before { display: none; }
    .gallery-action-bar { flex-direction: column; align-items: stretch; }
    .gallery-filter-left { flex-wrap: wrap; justify-content: space-between; }
    .gallery-search-bar { order: 2; }
    .gallery-filter-chips { order: 3; width: 100%; justify-content: center; }
    .gallery-view-toggle { order: 1; justify-content: center; }
    .gallery-grid-wrap { grid-template-columns: repeat(2, 1fr) !important; gap: .75rem; }
    .lightbox-nav { width: 44px; height: 44px; font-size: 1.2rem; }
    .lightbox-prev { left: .5rem; }
    .lightbox-next { right: .5rem; }
    .lightbox-close { top: .5rem; right: .5rem; width: 40px; height: 40px; font-size: 1.2rem; }
    .lightbox-info { bottom: 3rem; }
    .lightbox-counter { bottom: 1rem; }
    .gallery-detail-imgs { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 480px) {
    .gallery-grid-wrap { grid-template-columns: 1fr !important; }
    .gallery-filter-left { flex-direction: column; align-items: stretch; }
    .gallery-search-bar input { width: 100%; }
    .lightbox-nav { width: 36px; height: 36px; }
    .lightbox-prev { left: -40px; }
    .lightbox-next { right: -40px; }
    .match-detail-info-grid { grid-template-columns: 1fr; gap: .5rem; }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   11. 다크모드
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
[data-theme="dark"] .gallery-lightbox { background: rgba(0,0,0,.96); }
[data-theme="dark"] .gallery-badge-cat { background: rgba(255,255,255,.15); }
[data-theme="dark"] .match-detail-section { background: #1a2a20; }