/**
 * ParkPlay Golf App - Common Component Style
 * 공통 컴포넌트 스타일 (모든 페이지에서 사용)
 */

/* ========================================
   0. 접근성 유틸리티 (Accessibility)
   ======================================== */

/* 시각적으로 숨기되 스크린리더 접근 가능 */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ========================================
   0-1. 로딩 오버레이 (공통)
   ======================================== */

/* AJAX 페이지 전환 시 로딩 인디케이터 */

.loading-spinner {
    text-align: center;
    color: white;
}

.loading-spinner i {
    font-size: 48px;
    color: var(--primary-color);
    margin-bottom: 16px;
    display: block;
}

.loading-spinner p {
    font-size: 16px;
    font-weight: 500;
    margin: 0;
}

/* PkpAjax 공통 모듈용 로딩 오버레이 */
.pkp-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.pkp-loading-overlay.show {
    opacity: 1;
    visibility: visible;
}

.pkp-loading-spinner {
    text-align: center;
    color: white;
}

.pkp-loading-spinner i {
    font-size: 48px;
    color: var(--primary-color);
    margin-bottom: 16px;
    display: block;
}

.pkp-loading-spinner p {
    font-size: 16px;
    font-weight: 500;
    margin: 0;
}


/* ========================================
   무한 스크롤 로딩 인디케이터 (공통)
   ======================================== */
.infinite-scroll-loader {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px;
    gap: 12px;
}

.infinite-scroll-loader .spinner {
    width: 32px;
    height: 32px;
    border: 3px solid #E0E0E0;
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: infiniteSpinner 0.8s linear infinite;
}

@keyframes infiniteSpinner {
    to {
        transform: rotate(360deg);
    }
}

.infinite-scroll-loader .loader-text {
    font-size: 13px;
    color: var(--text-secondary);
}

/* ========================================
   플로팅 버튼 영역 (공통)
   ======================================== */
.floating-buttons {
    position: fixed;
    bottom: calc(var(--footer-total) + 20px);
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 90;
}

/* 맨 위로 가기 버튼 (공통) */
.btn-scroll-top {
    width: 48px;
    height: 48px;
    background: var(--card-bg);
    border: none;
    border-radius: 50%;
    color: var(--text-secondary);
    font-size: 18px;
    cursor: pointer;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-smooth);
    opacity: 0;
    visibility: hidden;
    transform: scale(0.8);
}

.btn-scroll-top.show {
    opacity: 1;
    visibility: visible;
    transform: scale(1);
}

.btn-scroll-top:hover {
    background: var(--primary-color);
    color: white;
    transform: scale(1.1);
}

.btn-scroll-top:active {
    transform: scale(0.95);
}

/* ========================================
   1. 폼 컴포넌트
   ======================================== */

/* 폼 그룹 */
.form-group {
    margin-bottom: 24px;
}

/* 폼 라벨 */
.form-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #212121;
    margin-bottom: 8px;
}

/* 필수 표시 */
.required {
    color: #D32F2F;
}

/* 폼 입력 필드 */
.form-input {
    width: 100%;
    height: 48px;
    border: 1px solid #E0E0E0;
    border-radius: 10px;
    font-size: 15px;
    padding: 0 16px;
    transition: all 0.3s ease;
    box-sizing: border-box;
    background: white;
}

.form-input:focus {
    outline: none;
    border-color: #4CAF50;
    box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.1);
}

.form-input::placeholder {
    color: #BDBDBD;
}

.form-input:read-only,
.form-input:disabled {
    background: #F5F5F5;
    color: #757575;
    cursor: not-allowed;
}

/* 도움말 텍스트 */
.form-help {
    display: block;
    font-size: 13px;
    color: #757575;
    margin-top: 6px;
    min-height: 18px;
}

.form-help i {
    margin-right: 4px;
}

.timer {
    font-weight: 600;
}

/* ========================================
   2. 버튼+입력 조합 레이아웃
   ======================================== */

.input-with-button {
    display: flex;
    gap: 8px;
}

.input-with-button .form-input {
    flex: 1;
}

/* ========================================
   3. 인라인 버튼 (입력 필드 옆 버튼)
   별칭: .btn-check, .btn-verify (기존 호환성 유지)
   ======================================== */

.btn-inline,
.btn-check,
.btn-verify {
    flex-shrink: 0;
    height: 48px;
    padding: 0 16px;
    background: white;
    border: 1px solid #4CAF50;
    color: #4CAF50;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    position: static;
}

.btn-inline:hover,
.btn-check:hover,
.btn-verify:hover {
    background: #4CAF50;
    color: white;
}

.btn-inline:disabled,
.btn-check:disabled,
.btn-verify:disabled {
    background: #F5F5F5;
    border-color: #E0E0E0;
    color: #9E9E9E;
    cursor: not-allowed;
}

/* ========================================
   4. 체크박스 컴포넌트
   ======================================== */

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    user-select: none;
    /* 동의 체크박스는 법적 필수 항목인데 커스텀 박스 22px + 텍스트 라인박스로
       실측 25px 밖에 안 돼 한 손 조작이 빗나갔다(390x844, screenOption 예약 확인 모달).
       라벨 전체가 탭 영역이므로 여기에 44px 을 준다 — .bookmark-filter-btn(44x44) 과 같은 단위. */
    min-height: 44px;
}

.checkbox-label input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

/* 네이티브 input 을 opacity:0 + 0x0 으로 숨긴 구조라(위 규칙) 포커스 링이 그려질 박스가 없다.
   display:none 이 아니라 포커스는 정상적으로 들어가므로, 링만 커스텀 박스로 옮겨
   키보드 사용자도 지금 어느 동의 항목에 있는지 볼 수 있게 한다. */
.checkbox-label input[type="checkbox"]:focus-visible+.checkbox-custom {
    outline: 2px solid #4CAF50;
    outline-offset: 2px;
}

.checkbox-custom {
    width: 22px;
    height: 22px;
    border: 2px solid #BDBDBD;
    border-radius: 6px;
    position: relative;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.checkbox-label input[type="checkbox"]:checked+.checkbox-custom {
    background: #4CAF50;
    border-color: #4CAF50;
}

.checkbox-label input[type="checkbox"]:checked+.checkbox-custom::after {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
}

.checkbox-text {
    font-size: 14px;
    color: #212121;
    display: flex;
    align-items: center;
    gap: 6px;
}

.optional-badge {
    font-size: 12px;
    font-weight: 600;
    color: #757575;
    background: #F5F5F5;
    padding: 2px 6px;
    border-radius: 4px;
}

/* ========================================
   5. 모달 컴포넌트
   ======================================== */

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    backdrop-filter: blur(4px);
}

.modal-content {
    background: white;
    border-radius: 16px;
    width: 90%;
    max-width: 400px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    animation: modalSlideUp 0.3s ease-out;
}

@keyframes modalSlideUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

.modal-header h3 {
    font-size: 18px;
    font-weight: 700;
    color: #212121;
    margin: 0;
}

.modal-close {
    width: 32px;
    height: 32px;
    background: #F5F5F5;
    border: none;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: #E0E0E0;
}

.modal-close i {
    font-size: 16px;
    color: #757575;
}

.modal-body {
    padding: 16px;
    overflow-y: auto;
    flex: 1;
}

/* ========================================
   6. 지역 선택 컴포넌트 (디자인 2234:3340 '거주지 선택' 시트)
   가입/SSO프로필/프로필수정 공용 — #locationModal 프레임 스코프 포함
   ======================================== */

.location-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.location-item {
    flex-shrink: 0;
    height: 46px;
    padding: 0 14px;
    background: var(--card-bg, #fff);
    border: 1px solid var(--border-light, #DDE4DA);
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary, #252B24);
    text-align: left;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s ease;
}

.location-item:active {
    background: var(--bg-secondary, #F5F2EC);
    border-color: var(--primary-color, #569544);
}

/* 거주지 선택 시트 프레임 — 공용 modal 골격 위 스코프 재정의 (딤 Ink 900 0.58) */
#locationModal {
    background: rgba(37, 43, 36, 0.58);
    backdrop-filter: none;
}

#locationModal .modal-content {
    width: calc(100% - 32px);
    max-width: 343px;
    max-height: 71vh;
    border-radius: 14px;
    padding: 16px;
}

#locationModal .modal-header {
    padding: 0 0 10px;
    border-bottom: none;
}

#locationModal .modal-header h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary, #252B24);
}

#locationModal .modal-close {
    width: 28px;
    height: 28px;
    background: none;
    border-radius: 0;
}

#locationModal .modal-close i {
    font-size: 20px;
    color: var(--text-primary, #252B24);
}

#locationModal .modal-body {
    padding: 0;
}

/* ========================================
   8. 공통 애니메이션
   ======================================== */

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   9. 반응형 (공통)
   ======================================== */

@media (max-width: 400px) {

    .form-input,
    .btn-inline {
        height: 44px;
        font-size: 14px;
    }
}

/* ========================================
   10. 페이지 헤더 컴포넌트
   ======================================== */

.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    /* Figma 실측(2026-08-03): 네비 밴드는 375x58 고정이다 — `기본_네비` 컴포넌트가
       뒤로가기 있는 화면(공지 목록 2215:3208)과 없는 화면(커뮤니티 목록 2205:3131)에서
       같은 58 높이다. 탭 타깃 40x40 은 접근성상 유지하고 위아래 여백만 9 로 줄여 58 을 만든다. */
    padding: calc(9px + var(--sat)) 16px 9px;
    /* in-flow sticky — 컨테이너 앞(.app-content 직계)에 두면 제 높이(58+sat)를 실제로
       차지하므로 spacer·padding 보정이 필요 없다. 스크롤할 때만 본문이 밑으로 지나간다.
       종전 fixed + .page-header-spacer 조합은 보정 누락·1px 어긋남(2026-08-19 즐겨찾기)
       부류의 결함을 반복 생산해 구역 레이아웃으로 걷어냈다(2026-08-21, LayoutStyle.css §5). */
    position: sticky;
    top: 0;
    background: var(--bg-color);
    z-index: 90;
    /* 시안의 네비 밴드는 그림자가 없고 1px 선 하나로 본문과 갈린다 (2026-08-18 실측:
       헤더/탭 경계에 1.06px #F3F4F0 단일 라인, 그라디언트 없음).
       border 가 아니라 box-shadow 로 그리는 이유: 이 요소는 명시 height 가 없어
       (padding 9*2 + 자식 40 = 58) border 를 주면 밴드가 59 로 커져 58 계약(위 :562
       주석의 Figma 375x58)이 깨진다. box-shadow 는 레이아웃을 차지하지 않는다. */
    box-shadow: 0 1px 0 var(--neutral-100);
}

.page-header h1 {
    /* Figma 실측(2026-08-03): 화면 제목은 전 화면 16/600 #252b24 다 —
       커뮤니티 목록 2205:3131 · 공지 목록 2215:3208 · 문의하기 2213:3226 · 글쓰기 2208:3373
       모두 같은 값이었고 구현만 18/700 이었다. */
    font-size: 16px;
    font-weight: 600;
}

.page-header .back-btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    /* 시안은 박스 없는 얇은 chevron 이다 — 프레임 4개(04.리스트_상세 · 04.리스트_상세_강사 ·
       07.즐겨찾기 · 02.홈_채팅리스트) 전부 흰 카드·그림자 없이 글리프만 놓인다.
       흰 40x40 카드 + --shadow-sm 이던 종전 구현은 배경(#FFFEFB) 위에서 밴드처럼 떠 보였다.
       탭 타깃 40x40 은 접근성상 유지하고 면만 걷는다. */
    border-radius: 12px;
    background: transparent;
    color: var(--text-primary);
    text-decoration: none;
    border: none;
    cursor: pointer;
    box-shadow: none;
    transition: color var(--transition-fast);
}

.page-header .back-btn:hover {
    /* 면이 없으므로 hover 도 글리프 색만 바꾼다(종전엔 초록 박스가 생겼다) */
    color: var(--primary-color);
}

/* 헤더 우측 버튼(공유 / 더보기⋯) — back-btn 과 같은 규약이다.
   2026-08-19 실측(screenDetail 6006): back-btn 은 transparent·shadow none 인데
   btn-share 는 rgb(255,255,255) + 0 2px 8px 라 한 밴드 안에서 좌우 처리가 갈렸다.
   근거는 back-btn 주석(:602)과 같다 — 배경이 #FFFEFB 가 된 뒤 흰 40x40 카드는
   헤더 안에서 밴드처럼 떠 보인다. 탭 타깃 40x40 은 유지하고 면만 걷는다.
   영향 화면: share = screenDetail·roundingDetail·lessonDetail·noticeView,
   more = communityView·joinDetail·joinChat. */
.page-header .btn-share,
.page-header .btn-header-more {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: transparent;
    color: var(--text-primary);
    border: none;
    cursor: pointer;
    box-shadow: none;
    transition: color var(--transition-fast);
}

.page-header .btn-share:hover,
.page-header .btn-header-more:hover {
    /* 면이 없으므로 hover 도 글리프 색만 바꾼다 (back-btn:hover 와 동일) */
    color: var(--primary-color);
}

.header-spacer {
    /* 뒤로가기/우측 버튼과 같은 40x40 을 차지해야 제목 중앙정렬과 밴드 높이(58)가
       버튼 유무에 상관없이 같아진다. 높이가 없으면 hideBack 화면만 밴드가 주저앉는다. */
    width: 40px;
    height: 40px;
}

/* ========================================
   11. 필터 컴포넌트
   ======================================== */


.filter-chips {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 4px;
}

.filter-chip {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    border: none;
    background: var(--card-bg);
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    white-space: nowrap;
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-fast);
}

.filter-chip:hover {
    background: var(--primary-light);
    color: white;
}

.filter-chip.active {
    background: var(--primary-color);
    color: white;
}


/* ========================================
   12. 업체 카드 컴포넌트
   ======================================== */

.store-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.store-card {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 16px;
    text-decoration: none;
    color: var(--text-primary);
    transition: all var(--transition-smooth);
}

.store-card:hover {
    transform: translateX(4px);
    box-shadow: var(--shadow-md);
}

/* 업체 이미지 */


.store-badge {
    position: absolute;
    top: -6px;
    left: -6px;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 10px;
    font-weight: 700;
    color: white;
}

.store-badge.hot {
    background: linear-gradient(135deg, #E53935, #FF5722);
}

.store-badge.new {
    background: linear-gradient(135deg, #1976D2, #42A5F5);
}

.store-badge.event {
    background: linear-gradient(135deg, #7B1FA2, #E040FB);
}

/* 태그 */

.store-tags .tag {
    padding: 4px 8px;
    background: var(--bg-color);
    border-radius: 4px;
    font-size: 10px;
    color: var(--text-secondary);
}

.store-tags .tag.highlight {
    background: #FFF3E0;
    color: #E65100;
    font-weight: 600;
}


/* ========================================
   13. 섹션 헤더 컴포넌트
   ======================================== */

.legend-item .dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.legend-item .dot.selected {
    background: var(--primary-color);
}

.original-price {
    font-size: 13px;
    color: var(--text-secondary);
    text-decoration: line-through;
    display: block;
}

/* ========================================
   19. 추가 공통 애니메이션
   ======================================== */

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

/* ========================================
   22. 검색바 컴포넌트
   ======================================== */


.search-input-wrapper {
    flex: 1;
    position: relative;
}

.search-input-wrapper i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
    font-size: 14px;
}

.search-input {
    width: 100%;
    height: 44px;
    padding: 0 14px 0 40px;
    border: 1px solid #E0E0E0;
    border-radius: 12px;
    font-size: 14px;
    background: var(--card-bg);
    color: var(--text-primary);
    transition: all var(--transition-fast);
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.1);
}

.search-input::placeholder {
    color: var(--text-secondary);
}

/* 즐겨찾기 필터 버튼 */


.bookmark-filter-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}


/* ========================================
   23. 즐겨찾기 하트 버튼
   ======================================== */

.btn-bookmark {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    cursor: pointer;
    transition: all var(--transition-fast);
    box-shadow: var(--shadow-sm);
}

.btn-bookmark i {
    font-size: 16px;
    color: #BDBDBD;
    transition: all var(--transition-fast);
}

.btn-bookmark:hover i {
    color: #E53935;
    transform: scale(1.1);
}

.btn-bookmark.active i {
    color: #E53935;
    font-weight: 900;
}

/* 하트 애니메이션 */
@keyframes bookmarkPop {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.3);
    }

    100% {
        transform: scale(1);
    }
}

.btn-bookmark.active i {
    animation: bookmarkPop 0.3s ease-out;
}

/* .empty-state 공통 스타일은 아래 'Empty State (데이터 없음 UI)' 섹션에 통합 */

/* ========================================
   27. 탭 컴포넌트 — 언더라인 탭 (Figma 2205:2485 '07. 즐겨찾기')
   즐겨찾기·내 예약이 쓰는 상단 카테고리다. 종전엔 세그먼트 알약(트랙+흰 카드+그림자)이
   정본이고 두 화면이 contents.css 에서 각자 언더라인으로 덮어쓰고 있었다 — 같은 규약이
   세 곳에 있었고 그 중 정본만 시안과 달랐다. 시안이 언더라인이므로 정본을 바꾸고 사본을 지웠다.
   실측(2026-08-18 시안 캔버스): 행 높이 44 · 언더라인 2px · 폭 = 탭 1칸 전체 ·
   활성 #569544(=--primary-color) · 비활성 라벨 #D2D2D2 · 구분선 #F1F0EF · 14px/700.
   ======================================== */

.tab-section {
    margin-bottom: 20px;
}

.tab-list {
    display: flex;
    gap: 0;
    /* 배경을 칠하지 않는다 — 시안에서 탭 행은 헤더·본문과 같은 면이고 경계는 선 두 개뿐이다.
       --card-bg(순백)를 칠하면 크림 배경(--bg-color) 위에 흰 밴드가 생겨 시안에 없는
       띠가 헤더 아래에 보인다 (2026-08-18 시안 실측: 헤더 #FFFEFB · 탭 행 #FFFEFD = 같은 면). */
    background: transparent;
    /* 헤더/탭 경계선은 .page-header 의 border-bottom 이 소유한다 — 여기도 그리면 2px 가 된다 */
    border-radius: 0;
    padding: 0;
}

.tab-item {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 44px;
    padding: 0;
    border: none;
    /* 구분선과 활성 표시가 같은 자리를 쓴다 — 두 값이 어긋나면 활성 탭에서 줄 높이가 튄다 */
    border-bottom: 2px solid var(--neutral-100);
    background: transparent;
    border-radius: 0;
    font-family: inherit;
    font-size: 14px;
    font-weight: 700;
    color: var(--neutral-300);
    cursor: pointer;
    transition: color var(--transition-fast), border-color var(--transition-fast);
}

.tab-item:hover {
    color: var(--text-secondary);
}

.tab-item.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

/* ========================================
   Empty State (데이터 없음 UI)
   ======================================== */

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 24px;
    text-align: center;
}

.empty-state-icon {
    width: 104px;
    height: 104px;
    margin: 0 auto 16px;
    background: url(/image/pkp_app/common/duck-mascot.png) center / contain no-repeat;
}

.empty-state-icon i {
    display: none;
}

.empty-state-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.empty-state-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 20px;
    max-width: 280px;
}

.empty-state-btn {
    padding: 12px 24px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: all var(--transition-fast);
}

/* 버튼을 두 개 쌓는 화면(결제 결과 2종)에서만 필요한 간격. 다른 화면은 1개라 영향 없다.
   간격이 없으면 같은 초록 pill 두 개가 맞닿아 하나가 잘린 것처럼 보인다 (2026-08-12 실측). */
.empty-state-btn + .empty-state-btn {
    margin-top: 10px;
}

.empty-state-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}


/* ========================================
   Lazy Loading 이미지
   ======================================== */

/* 이미지 로딩 중 플레이스홀더 */
img[loading="lazy"] {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

img[loading="lazy"].loaded {
    animation: none;
    background: none;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }

    100% {
        background-position: 200% 0;
    }
}

.image-container img[loading="lazy"]:not(.loaded) {
    opacity: 0.5;
}

.image-container img.loaded {
    opacity: 1;
}
/* ========================================
   공통 다이얼로그 (PkpDialog)
   - confirm/alert 대체 앱 전용 팝업
   ======================================== */

.pkp-dialog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10001;
    padding: 24px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.pkp-dialog-overlay.active {
    opacity: 1;
    visibility: visible;
}

.pkp-dialog {
    background: var(--card-bg, #fff);
    border-radius: 20px;
    width: 100%;
    max-width: 320px;
    padding: 32px 24px 24px;
    text-align: center;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.2);
    transform: scale(0.9) translateY(20px);
    transition: transform 0.25s ease;
}

.pkp-dialog-overlay.active .pkp-dialog {
    transform: scale(1) translateY(0);
}

.pkp-dialog-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-color, #F5F5F5);
    border-radius: 50%;
}

.pkp-dialog-icon i {
    font-size: 24px;
    color: var(--text-secondary, #757575);
}

/* 아이콘 색상 변형 */
.pkp-dialog-icon.icon-danger {
    background: #FFEBEE;
}

.pkp-dialog-icon.icon-danger i {
    color: #E53935;
}

.pkp-dialog-icon.icon-warning {
    background: #FFF3E0;
}

.pkp-dialog-icon.icon-warning i {
    color: #FF9800;
}

.pkp-dialog-icon.icon-success {
    background: #E8F5E9;
}

.pkp-dialog-icon.icon-success i {
    color: var(--primary-color, #4CAF50);
}

.pkp-dialog-icon.icon-info {
    background: #E3F2FD;
}

.pkp-dialog-icon.icon-info i {
    color: #1976D2;
}

.pkp-dialog-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary, #212121);
    margin: 0 0 8px;
}

.pkp-dialog-message {
    font-size: 14px;
    color: var(--text-secondary, #757575);
    line-height: 1.6;
    margin: 0 0 24px;
    word-break: keep-all;
}

.pkp-dialog-buttons {
    display: flex;
    gap: 10px;
}

.pkp-dialog-btn {
    flex: 1;
    height: 48px;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pkp-dialog-btn.cancel {
    background: var(--bg-color, #F5F5F5);
    color: var(--text-secondary, #757575);
}

.pkp-dialog-btn.cancel:hover {
    background: #E0E0E0;
}

.pkp-dialog-btn.confirm {
    background: linear-gradient(135deg, var(--primary-color, #4CAF50), var(--primary-light, #66BB6A));
    color: white;
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.3);
}

.pkp-dialog-btn.confirm:hover {
    box-shadow: 0 6px 16px rgba(76, 175, 80, 0.4);
    transform: translateY(-1px);
}

.pkp-dialog-btn.confirm:active {
    transform: translateY(0);
}
