@charset "utf-8";

/* TimePoint Theme - Default CSS */
/* shadcn/ui 스타일 기반 그누보드 테마 */
/* WCAG 2.1 접근성 준수 */

/* ===== 기본 리셋 및 유틸리티 ===== */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

.sound_only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* ===== 폼 요소 통일 (shadcn/ui 스타일) ===== */
input[type="text"],
input[type="password"],
input[type="email"],
input[type="tel"],
input[type="url"],
input[type="search"],
input[type="number"],
input[type="date"],
textarea,
select {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid hsl(214.3 31.8% 91.4%);
    border-radius: 0.375rem;
    background-color: hsl(0 0% 100%);
    color: hsl(222.2 84% 4.9%);
    font-size: 0.875rem;
    line-height: 1.25rem;
    transition: all 0.2s;
}

input[type="text"]:focus,
input[type="password"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
input[type="url"]:focus,
input[type="search"]:focus,
input[type="number"]:focus,
input[type="date"]:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: hsl(221.2 83.2% 53.3%);
    ring: 2px solid hsl(221.2 83.2% 53.3%);
    box-shadow: 0 0 0 2px hsl(221.2 83.2% 53.3% / 0.2);
}

input[type="text"]:disabled,
input[type="password"]:disabled,
input[type="email"]:disabled,
input[type="tel"]:disabled,
input[type="url"]:disabled,
input[type="search"]:disabled,
input[type="number"]:disabled,
input[type="date"]:disabled,
textarea:disabled,
select:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ===== 버튼 통일 (shadcn/ui 스타일) ===== */
button,
.btn,
input[type="submit"],
input[type="button"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.25rem;
    transition: all 0.2s;
    cursor: pointer;
    border: 1px solid transparent;
}

/* Primary Button */
.btn-primary,
.btn_b01,
.btn_b02,
input[type="submit"]:not(.btn_close):not(.btn_cancel) {
    background-color: hsl(221.2 83.2% 45%); /* 접근성 개선: WCAG AA 준수 */
    color: hsl(0 0% 100%); /* 순백색으로 대비 강화 */
    min-height: 44px;
}

.btn-primary:hover,
.btn_b01:hover,
.btn_b02:hover,
input[type="submit"]:not(.btn_close):not(.btn_cancel):hover {
    background-color: hsl(221.2 83.2% 35%); /* 호버 시 명확하게 더 어둡게 */
    transform: translateY(-1px);
    box-shadow: 0 2px 8px 0 rgb(0 0 0 / 0.15);
}

/* Secondary Button */
.btn-secondary {
    background-color: hsl(210 40% 96.1%);
    color: hsl(222.2 47.4% 11.2%);
}

.btn-secondary:hover {
    background-color: hsl(210 40% 92%);
}

/* Outline Button */
.btn-outline,
.btn_frmline {
    border-color: hsl(214.3 31.8% 91.4%);
    background-color: transparent;
    color: hsl(222.2 84% 4.9%);
    min-height: 44px;
}

.btn-outline:hover,
.btn_frmline:hover {
    background-color: hsl(210 40% 92%); /* 더 진한 회색으로 명확하게 */
    border-color: hsl(214.3 31.8% 85%);
}

/* 일반 버튼 */
.btn,
.btn_a01,
.btn_a02 {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s;
    cursor: pointer;
    border: 1px solid transparent;
    text-decoration: none;
    min-height: 44px;
}

.btn_a01 {
    background-color: hsl(221.2 83.2% 45%);
    color: hsl(0 0% 100%);
}

.btn_a01:hover {
    background-color: hsl(221.2 83.2% 35%); /* 더 명확한 호버 효과 */
}

.btn_a02 {
    background-color: hsl(210 40% 96.1%);
    color: hsl(222.2 47.4% 11.2%);
    border-color: hsl(214.3 31.8% 91.4%);
}

.btn_a02:hover {
    background-color: hsl(210 40% 92%);
}

/* Destructive Button */
.btn-destructive {
    background-color: hsl(0 72% 51%); /* 접근성 개선 */
    color: hsl(0 0% 100%);
}

.btn-destructive:hover {
    background-color: hsl(0 72% 40%); /* 더 명확한 호버 효과 */
    transform: translateY(-1px);
    box-shadow: 0 2px 8px 0 rgb(239 68 68 / 0.3);
}

/* ===== 카드 컴포넌트 ===== */
.card {
    background-color: hsl(0 0% 100%);
    border: 1px solid hsl(214.3 31.8% 91.4%);
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1);
}

.card-header {
    padding: 1.5rem;
    border-bottom: 1px solid hsl(214.3 31.8% 91.4%);
}

.card-body {
    padding: 1.5rem;
}

.card-footer {
    padding: 1.5rem;
    border-top: 1px solid hsl(214.3 31.8% 91.4%);
}

/* ===== 테이블 스타일 ===== */
table {
    width: 100%;
    border-collapse: collapse;
}

table th,
table td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid hsl(214.3 31.8% 91.4%);
}

table th {
    background-color: hsl(210 40% 96.1%);
    font-weight: 600;
    color: hsl(222.2 47.4% 11.2%);
}

table tbody tr:hover {
    background-color: hsl(210 40% 98%);
}

/* ===== 링크 스타일 ===== */
a {
    color: hsl(221.2 83.2% 53.3%);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: hsl(221.2 83.2% 48%);
}

/* ===== 그누보드 기본 요소 오버라이드 ===== */
/* ===== z-index 계층 구조 (체계적 관리) ===== */
/*
  Layer System (낮은 순서 -> 높은 순서):
  - 10: 기본 콘텐츠
  - 20: 상단으로 버튼
  - 30: 푸터 요소
  - 40: 헤더 (고정 헤더)
  - 45: 네비게이션
  - 50: 드롭다운 메뉴
  - 55: 전체메뉴 배경 (overlay)
  - 60: 전체메뉴 모달
  - 70: 로그인 메시지
  - 80: 스크롤 프로그레스 바
  - 90: 토스트/알림
  - 100: 팝업/모달 (최상위)
*/

#hd {
    position: relative;
    z-index: 40;
}

#gnb {
    position: relative;
    z-index: 45;
}

.gnb_2dul {
    z-index: 50;
}

#gnb_all_bg {
    z-index: 55 !important;
}

#gnb_all {
    z-index: 60 !important;
}

#hd_login_msg {
    z-index: 70;
}

#scroll_progress {
    z-index: 80;
}

#top_btn {
    z-index: 20;
}

/* 팝업 레이어 */
#hd_pop {
    z-index: 100;
}

/* ===== 네비게이션 및 헤더 추가 스타일 ===== */
/* 네비게이션 호버 효과 개선 */
#gnb {
    transition: box-shadow 0.3s ease;
}

/* 드롭다운 메뉴 그림자 강화 */
.gnb_2dul {
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.2);
}

/* 전체메뉴 모달 스크롤바 스타일링 */
#gnb_all::-webkit-scrollbar {
    width: 6px;
}

#gnb_all::-webkit-scrollbar-track {
    background: hsl(210 40% 96%);
}

#gnb_all::-webkit-scrollbar-thumb {
    background: hsl(221.2 83.2% 53.3%);
    border-radius: 3px;
}

#gnb_all::-webkit-scrollbar-thumb:hover {
    background: hsl(221.2 83.2% 45%);
}

/* 로고 호버 효과 */
#logo a {
    transition: transform 0.3s ease;
}

#logo a:hover {
    transform: scale(1.02);
}

/* 검색 입력 필드 애니메이션 */
#sch_stx {
    transition: all 0.2s ease;
}

#sch_stx:focus {
    transform: translateY(-1px);
}

/* 유틸리티 메뉴 링크 호버 효과 */
#hd_qnb a {
    position: relative;
}

#hd_qnb a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: currentColor;
    transition: width 0.2s ease;
}

#hd_qnb a:hover::after {
    width: 100%;
}

/* 성능 최적화: GPU 가속 */
#gnb,
.gnb_2dul,
#gnb_all,
#gnb_all_bg,
#logo a,
.gnb_menu_btn,
.hd_login a {
    will-change: auto;
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* ===== 네이버 뉴스 스타일 개선 ===== */
/* 텍스트 line-clamp 지원 */
.line-clamp-1 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 1;
}

.line-clamp-2 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.line-clamp-3 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

/* ===== UI/UX 개선 - 마이크로 인터랙션 ===== */
/* 부드러운 호버 효과 */
a, button, input, select, textarea {
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 포커스 상태 강화 (접근성) */
*:focus-visible {
    outline: 3px solid hsl(221.2 83.2% 53.3%);
    outline-offset: 2px;
    border-radius: 2px;
}

/* 카드 호버 효과 */
.card:hover,
.bg-white:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px 0 rgb(0 0 0 / 0.1);
}

/* 버튼 호버 애니메이션 */
button:hover:not(:disabled),
.btn:hover,
input[type="submit"]:hover,
input[type="button"]:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px 0 rgb(0 0 0 / 0.15);
}

button:active:not(:disabled),
.btn:active,
input[type="submit"]:active,
input[type="button"]:active {
    transform: translateY(0);
}

/* 링크 밑줄 애니메이션 */
a.underline-effect {
    position: relative;
    text-decoration: none;
}

a.underline-effect::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: currentColor;
    transition: width 0.3s ease;
}

a.underline-effect:hover::after {
    width: 100%;
}

/* 이미지 호버 줌 효과 */
.img-zoom-container {
    overflow: hidden;
}

.img-zoom-container img {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.img-zoom-container:hover img {
    transform: scale(1.05);
}

/* 로딩 스피너 */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid hsl(214.3 31.8% 91.4%);
    border-top-color: hsl(221.2 83.2% 53.3%);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 페이드 인 애니메이션 */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 슬라이드 인 애니메이션 */
.slide-in-right {
    animation: slideInRight 0.3s ease-out;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
    }
    to {
        transform: translateX(0);
    }
}

/* 펄스 애니메이션 (알림 등) */
.pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

/* 스크롤 바 스타일링 */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: hsl(210 40% 96.1%);
}

::-webkit-scrollbar-thumb {
    background: hsl(215.4 16.3% 46.9%);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: hsl(221.2 83.2% 53.3%);
}

/* 부드러운 스크롤 */
html {
    scroll-behavior: smooth;
}

/* 페이지네이션 */
.pagination {
    display: flex;
    gap: 0.25rem;
    justify-content: center;
    margin: 2rem 0;
}

.pagination a,
.pagination strong {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    height: 2.5rem;
    padding: 0 0.75rem;
    border: 1px solid hsl(214.3 31.8% 91.4%);
    border-radius: 0.375rem;
    background-color: hsl(0 0% 100%);
    color: hsl(222.2 84% 4.9%);
    font-size: 0.875rem;
    transition: all 0.2s;
}

.pagination a:hover {
    background-color: hsl(210 40% 92%); /* 더 진한 회색으로 명확하게 */
    border-color: hsl(221.2 83.2% 45%);
    transform: translateY(-1px);
}

.pagination strong {
    background-color: hsl(221.2 83.2% 45%);
    border-color: hsl(221.2 83.2% 45%);
    color: hsl(0 0% 100%);
}

/* 게시판 리스트 */
.board_list {
    margin: 2rem 0;
}

.board_list th {
    background-color: hsl(210 40% 96.1%);
    padding: 1rem;
    font-weight: 600;
}

.board_list td {
    padding: 1rem;
    border-bottom: 1px solid hsl(214.3 31.8% 91.4%);
}

/* 에디터 영역 */
#wr_content {
    min-height: 300px;
}

/* ===== 회원가입 폼 스타일 ===== */

/* ===== CAPTCHA 반응형 처리 강화 ===== */
.is_captcha_use,
.captcha_box,
.vc-captcha,
#captcha_box {
    max-width: 100%;
    overflow: hidden;
    margin: 1rem 0;
    padding: 1rem;
    background-color: hsl(210 40% 98%);
    border: 1px solid hsl(214.3 31.8% 91.4%);
    border-radius: 0.5rem;
}

.captcha_box img,
.is_captcha_use img,
.vc-captcha img,
#captcha_box img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
    border: 1px solid hsl(214.3 31.8% 85%);
    border-radius: 0.375rem;
}

/* 모바일에서 CAPTCHA 이미지 크기 조정 */
@media (max-width: 640px) {
    .captcha_box img,
    .is_captcha_use img,
    .vc-captcha img,
    #captcha_box img {
        max-width: 100%;
        width: 100%;
    }
}

.captcha_box input,
.is_captcha_use input[type="text"],
.vc-captcha input[type="text"],
#captcha_box input[type="text"] {
    width: 100%;
    max-width: 400px;
    padding: 0.75rem;
    border: 1px solid hsl(214.3 31.8% 91.4%);
    border-radius: 0.375rem;
    margin-top: 0.75rem;
    font-size: 0.875rem;
    transition: all 0.2s;
}

.captcha_box input:focus,
.is_captcha_use input[type="text"]:focus,
.vc-captcha input[type="text"]:focus,
#captcha_box input[type="text"]:focus {
    outline: none;
    border-color: hsl(221.2 83.2% 53.3%);
    box-shadow: 0 0 0 2px hsl(221.2 83.2% 53.3% / 0.2);
}

/* reCAPTCHA 반응형 처리 */
.g-recaptcha,
#recaptcha_widget {
    max-width: 100%;
    overflow: hidden;
    margin: 1rem 0;
}

.g-recaptcha > div,
#recaptcha_widget > div {
    max-width: 100% !important;
    transform-origin: 0 0;
}

@media (max-width: 640px) {
    .g-recaptcha > div,
    #recaptcha_widget > div {
        transform: scale(0.85);
    }
}

@media (max-width: 480px) {
    .g-recaptcha > div,
    #recaptcha_widget > div {
        transform: scale(0.75);
    }
}

/* CAPTCHA 새로고침 버튼 */
.captcha_refresh,
.captcha_reload {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    margin-top: 0.5rem;
    background-color: hsl(210 40% 96.1%);
    color: hsl(222.2 47.4% 11.2%);
    border: 1px solid hsl(214.3 31.8% 91.4%);
    border-radius: 0.375rem;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s;
    min-height: 44px;
}

.captcha_refresh:hover,
.captcha_reload:hover {
    background-color: hsl(210 40% 92%);
    border-color: hsl(214.3 31.8% 85%);
}

/* 회원가입 버튼 스타일 */
.btn_submit,
#btn_submit,
button[type="submit"].btn_submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 2rem;
    background-color: hsl(221.2 83.2% 45%);
    color: hsl(0 0% 100%);
    border-radius: 0.375rem;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    min-height: 44px;
}

.btn_submit:hover,
#btn_submit:hover {
    background-color: hsl(221.2 83.2% 35%); /* 더 명확한 호버 효과 */
    transform: translateY(-1px);
    box-shadow: 0 4px 12px 0 rgb(0 0 0 / 0.2);
}

.btn_submit:disabled,
#btn_submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* 취소 버튼 */
.btn_close,
.btn_cancel {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 2rem;
    background-color: hsl(210 40% 96.1%);
    color: hsl(222.2 47.4% 11.2%);
    border-radius: 0.375rem;
    font-size: 1rem;
    font-weight: 500;
    border: 1px solid hsl(214.3 31.8% 91.4%);
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    min-height: 44px;
}

.btn_close:hover,
.btn_cancel:hover {
    background-color: hsl(210 40% 92%);
}

/* 버튼 그룹 */
.btn_confirm {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid hsl(214.3 31.8% 91.4%);
}

/* 회원가입 폼 테이블 */
.tbl_frm01,
.register_form_inner {
    margin-bottom: 2rem;
}

.tbl_frm01 h2,
.register_form_inner h2 {
    font-size: 1.25rem;
    font-weight: 700;
    color: hsl(222.2 84% 4.9%);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid hsl(221.2 83.2% 53.3%);
}

.tbl_frm01 ul,
.register_form_inner ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tbl_frm01 li,
.register_form_inner li {
    padding: 1rem 0;
    border-bottom: 1px solid hsl(214.3 31.8% 91.4%);
}

/* 필수 표시 */
.required_text,
.sound_only + .frm_input,
.required {
    position: relative;
}

.required_text::after {
    content: '*';
    color: hsl(0 84.2% 60.2%);
    margin-left: 0.25rem;
}

/* 폼 입력 요소들 */
.frm_input,
.register_form_inner input[type="text"],
.register_form_inner input[type="password"],
.register_form_inner input[type="email"],
.register_form_inner input[type="tel"],
.register_form_inner textarea,
.register_form_inner select {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid hsl(214.3 31.8% 91.4%);
    border-radius: 0.375rem;
    background-color: hsl(0 0% 100%);
    color: hsl(222.2 84% 4.9%);
    font-size: 0.875rem;
    transition: all 0.2s;
}

.frm_input:focus {
    outline: none;
    border-color: hsl(221.2 83.2% 53.3%);
    box-shadow: 0 0 0 2px hsl(221.2 83.2% 53.3% / 0.2);
}

/* 체크박스 스타일 */
.selec_chk,
input[type="checkbox"].selec_chk {
    width: 1.25rem;
    height: 1.25rem;
    border: 2px solid hsl(214.3 31.8% 91.4%);
    border-radius: 0.25rem;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-color: white;
    position: relative;
    vertical-align: middle;
    margin-right: 0.5rem;
}

.selec_chk:checked {
    background-color: hsl(221.2 83.2% 45%);
    border-color: hsl(221.2 83.2% 45%);
}

.selec_chk:checked::after {
    content: '✓';
    position: absolute;
    color: white;
    font-size: 1rem;
    font-weight: bold;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.fregister_agree label,
.chk_all label {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    font-size: 0.875rem;
}

/* 약관 동의 영역 */
#fregister_term,
#fregister_private,
.fregister_terms {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background-color: hsl(210 40% 98%);
    border: 1px solid hsl(214.3 31.8% 91.4%);
    border-radius: 0.5rem;
}

#fregister_term h2,
#fregister_private h2,
.fregister_terms h2 {
    font-size: 1.125rem;
    font-weight: 700;
    color: hsl(222.2 84% 4.9%);
    margin-bottom: 1rem;
}

#fregister_term textarea {
    width: 100%;
    height: 200px;
    padding: 1rem;
    border: 1px solid hsl(214.3 31.8% 91.4%);
    border-radius: 0.375rem;
    background-color: white;
    font-size: 0.875rem;
    line-height: 1.6;
    margin-bottom: 1rem;
    resize: vertical;
}

/* 약관 테이블 */
#fregister_private table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1rem;
    background-color: white;
}

#fregister_private table th,
#fregister_private table td {
    padding: 0.75rem;
    border: 1px solid hsl(214.3 31.8% 91.4%);
    text-align: left;
    font-size: 0.875rem;
}

#fregister_private table th {
    background-color: hsl(210 40% 96.1%);
    font-weight: 600;
}

/* 전체 동의 */
#fregister_chkall {
    padding: 1.5rem;
    background-color: hsl(221.2 83.2% 45% / 0.1);
    border: 2px solid hsl(221.2 83.2% 45%);
    border-radius: 0.5rem;
    margin-bottom: 2rem;
}

#fregister_chkall label {
    font-size: 1rem;
    font-weight: 600;
    color: hsl(221.2 83.2% 35%); /* 접근성 개선: 더 어두운 색상 */
}

/* ===== 헤더 및 네비게이션 반응형 ===== */
@media (max-width: 1024px) {
    /* 태블릿: 네비게이션 메뉴 간격 조정 */
    #gnb_1dul .gnb_1dli .gnb_1da {
        padding-left: 1rem;
        padding-right: 1rem;
        font-size: 0.875rem;
    }
}

@media (max-width: 768px) {
    /* 모바일: 헤더 sticky 제거 (성능 최적화) */
    #hd {
        position: relative;
    }

    /* 유틸리티 메뉴 간소화 */
    #hd_qnb li a {
        font-size: 0.75rem;
        padding: 0.25rem 0.5rem;
    }

    /* 네비게이션 메뉴 숨김 (전체메뉴만 표시) */
    #gnb_1dul .gnb_1dli:not(.gnb_mnal) {
        display: none;
    }

    /* 드롭다운 메뉴 모바일 대응 */
    .gnb_2dul {
        position: fixed;
        left: 0;
        right: 0;
        top: auto;
        width: 100%;
        max-height: 80vh;
        overflow-y: auto;
    }

    /* 컨테이너 패딩 조정 */
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    /* 테이블 반응형 */
    table {
        font-size: 0.875rem;
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }

    table th,
    table td {
        padding: 0.5rem;
    }

    /* 모바일에서 버튼 크기 조정 (접근성) */
    button,
    .btn,
    input[type="submit"],
    input[type="button"],
    .btn_submit,
    .btn_close,
    .btn_cancel {
        min-height: 44px;
        padding: 0.625rem 1rem;
        font-size: 0.875rem;
    }

    /* 모바일에서 폼 요소 크기 조정 */
    input[type="text"],
    input[type="password"],
    input[type="email"],
    input[type="tel"],
    input[type="url"],
    input[type="search"],
    input[type="number"],
    input[type="date"],
    textarea,
    select {
        font-size: 16px; /* iOS 줌 방지 */
        padding: 0.625rem 0.875rem;
    }
}

@media (max-width: 640px) {
    /* 작은 모바일 화면 */

    /* 헤더 로고 크기 조정 */
    #logo a span {
        font-size: 1.25rem;
    }

    #logo a div {
        width: 2rem;
        height: 2rem;
    }

    #logo a div svg {
        width: 1.25rem;
        height: 1.25rem;
    }

    /* 유틸리티 메뉴 더 간소화 */
    #hd_define {
        display: none;
    }

    /* 버튼 확인 영역 */
    .btn_confirm {
        flex-direction: column;
    }

    .btn_confirm button,
    .btn_confirm .btn {
        width: 100%;
    }

    /* 전체메뉴 모달 너비 조정 */
    #gnb_all {
        width: 85vw;
        max-width: 320px;
    }
}

/* ===== 모바일 최적화 추가 ===== */
@media (max-width: 480px) {
    /* 초소형 모바일 */

    /* 헤더 패딩 최소화 */
    #hd_wrapper .flex {
        padding-top: 0.75rem;
        padding-bottom: 0.75rem;
    }

    /* 로그인 버튼 간격 최적화 */
    .hd_login {
        gap: 0.375rem !important;
    }

    .hd_login a {
        padding-left: 0.625rem !important;
        padding-right: 0.625rem !important;
    }

    /* 검색 버튼 최소화 */
    #sch_submit {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }
}

/* ===== 접근성 개선 ===== */
:focus-visible {
    outline: 2px solid hsl(221.2 83.2% 53.3%);
    outline-offset: 2px;
}

/* Skip to content */
#skip_to_container a {
    position: absolute;
    left: -9999px;
    padding: 1rem;
    background-color: hsl(221.2 83.2% 53.3%);
    color: hsl(210 40% 98%);
    text-decoration: none;
    z-index: 10000;
}

#skip_to_container a:focus {
    left: 0;
    top: 0;
}

/* ===== shadcn/ui 컴포넌트 스타일 통합 ===== */

/* Badge 컴포넌트 */
.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.25rem 0.625rem;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1;
    border-radius: 0.375rem;
    transition: all 0.2s;
}

.badge-primary {
    background-color: hsl(221.2 83.2% 45%);
    color: hsl(0 0% 100%);
}

.badge-secondary {
    background-color: hsl(210 40% 96.1%);
    color: hsl(222.2 47.4% 11.2%);
}

.badge-destructive {
    background-color: hsl(0 72% 51%);
    color: hsl(0 0% 100%);
}

/* Alert 컴포넌트 */
.alert {
    padding: 1rem;
    border-radius: 0.5rem;
    border: 1px solid;
    margin-bottom: 1rem;
}

.alert-info {
    background-color: hsl(199 89% 48% / 0.1);
    border-color: hsl(199 89% 48%);
    color: hsl(199 89% 48%);
}

.alert-success {
    background-color: hsl(142 76% 36% / 0.1);
    border-color: hsl(142 76% 36%);
    color: hsl(142 76% 36%);
}

.alert-warning {
    background-color: hsl(38 92% 50% / 0.1);
    border-color: hsl(38 92% 50%);
    color: hsl(38 92% 50%);
}

.alert-destructive {
    background-color: hsl(0 72% 51% / 0.1);
    border-color: hsl(0 72% 51%);
    color: hsl(0 72% 51%);
}

/* Skeleton 로딩 */
.skeleton {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
    background-color: hsl(214.3 31.8% 91.4%);
    border-radius: 0.375rem;
}

/* Tooltip 기본 스타일 */
[data-tooltip] {
    position: relative;
}

[data-tooltip]:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.5rem 0.75rem;
    background-color: hsl(222.2 84% 4.9%);
    color: hsl(0 0% 100%);
    font-size: 0.75rem;
    border-radius: 0.375rem;
    white-space: nowrap;
    z-index: 50;
    margin-bottom: 0.5rem;
}

/* 네이버 뉴스 스타일 개선 */
.main_content_area {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
}

.latest_top_wr {
    margin-bottom: 2rem;
}

.latest_wr .lt_wr {
    transition: all 0.2s;
}

.latest_wr .lt_wr:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px 0 rgb(0 0 0 / 0.1);
}

/* 게시판 스타일 통일 */
#bo_list,
#bo_v,
#bo_w {
    max-width: 100%;
}

/* 검색 폼 스타일 */
.bo_sch_wrap {
    background-color: hsl(0 0% 100%);
    border: 1px solid hsl(214.3 31.8% 91.4%);
    border-radius: 0.5rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.bo_sch_wrap input[type="text"],
.bo_sch_wrap select {
    width: 100%;
    padding: 0.625rem 0.875rem;
    border: 1px solid hsl(214.3 31.8% 91.4%);
    border-radius: 0.375rem;
    font-size: 0.875rem;
}

/* 댓글 영역 스타일 */
#bo_vc {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 2px solid hsl(214.3 31.8% 91.4%);
}

/* 파일 첨부 영역 */
.bo_v_file {
    margin-top: 1rem;
    padding: 1rem;
    background-color: hsl(210 40% 98%);
    border: 1px solid hsl(214.3 31.8% 91.4%);
    border-radius: 0.375rem;
}

.bo_v_file a {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background-color: hsl(0 0% 100%);
    border: 1px solid hsl(214.3 31.8% 91.4%);
    border-radius: 0.375rem;
    transition: all 0.2s;
}

.bo_v_file a:hover {
    background-color: hsl(210 40% 96.1%);
    border-color: hsl(221.2 83.2% 45%);
}

/* 접근성: 키보드 네비게이션 개선 */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 3px solid hsl(221.2 83.2% 53.3%);
    outline-offset: 2px;
    border-radius: 2px;
}

/* 로딩 상태 */
.loading {
    opacity: 0.6;
    pointer-events: none;
    position: relative;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 3px solid hsl(214.3 31.8% 91.4%);
    border-top-color: hsl(221.2 83.2% 53.3%);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

/* ===== 팝업 레이어 ===== */
/* 팝업이 없을 때 #hd_pop 숨기기 */
#hd_pop:not(:has(.hd_pops)) {
    display: none !important;
}

/* 팝업이 있을 때만 표시 */
#hd_pop:has(.hd_pops) {
    display: block;
}

/* 접근성: 팝업 레이어 제목 숨기기 */
#hd_pop h2 {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}
