/* ========================================
   충주 스마트 관광 시스템 - 스타일
   ======================================== */

/* 리셋 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* CSS 변수 */
:root {
    --primary: #6AB34D;
    --primary-dark: #3BA949;
    --primary-light: #dcedc8;

    --accent-orange: #FFA726;
    --accent-red: #EF5350;

    --bg: #F5F5F5;
    --card-bg: #FFFFFF;
    --text-dark: #212121;
    --text-secondary: #757575;
    --text-light: #9E9E9E;
    --border: #E0E0E0;

    --shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.15);

    --radius: 16px;
    --radius-sm: 10px;
    --radius-xs: 6px;

    --nav-height: 70px;
}

body {
    font-family: 'Noto Sans KR', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg);
    color: var(--text-dark);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* 앱 컨테이너 */
.app-container {
    max-width: 480px;
    margin: 0 auto;
    min-height: 100vh;
    position: relative;
    background: var(--bg);
}

@media (min-width: 768px) {
    .app-container {
        box-shadow: 0 0 40px rgba(0, 0, 0, 0.15);
    }
}

/* ========== 화면 전환 ========== */
.screen {
    display: none;
    padding-bottom: calc(var(--nav-height) + 16px);
    animation: fadeIn 0.3s ease;
}

.screen.active {
    display: block;
}

/* ========== 헤더 ========== */
.app-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-logo {
    font-size: 18px;
    font-weight: 800;
    color: white;
    display: flex;
    align-items: center;
    gap: 8px;
}

.header-logo i {
    font-size: 20px;
}

.header-user {
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* ========== 하단 네비게이션 ========== */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 480px;
    height: var(--nav-height);
    background: white;
    display: flex;
    align-items: center;
    justify-content: space-around;
    box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.08);
    z-index: 1000;
    border-top: 1px solid var(--border);
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 8px 16px;
    border: none;
    background: none;
    color: var(--text-light);
    font-size: 11px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}

.nav-item i {
    font-size: 20px;
    transition: all 0.2s;
}

.nav-item.active {
    color: var(--primary);
}

.nav-item.active i {
    transform: scale(1.1);
}

.nav-item .nav-badge {
    position: absolute;
    top: 4px;
    right: 8px;
    width: 8px;
    height: 8px;
    background: var(--accent-red);
    border-radius: 50%;
}

/* ========== 포인트 카드 ========== */
.points-card {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 24px;
    border-radius: var(--radius);
    color: white;
    margin: 16px;
    box-shadow: 0 4px 16px rgba(106, 179, 77, 0.3);
    position: relative;
    overflow: hidden;
}

.points-card::after {
    content: '';
    position: absolute;
    top: -30px;
    right: -30px;
    width: 120px;
    height: 120px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
}

.points-label {
    font-size: 13px;
    font-weight: 500;
    opacity: 0.9;
    margin-bottom: 4px;
}

.points-amount {
    font-size: 2.2rem;
    font-weight: 800;
    letter-spacing: -1px;
}

.points-card .level-info {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 12px;
    font-size: 13px;
    opacity: 0.9;
}

.points-card .level-progress {
    flex: 1;
    height: 4px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
    overflow: hidden;
}

.points-card .level-progress-bar {
    height: 100%;
    background: white;
    border-radius: 2px;
    transition: width 0.5s ease;
}

.points-card .card-btn {
    display: inline-block;
    margin-top: 16px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 24px;
    color: white;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    font-family: inherit;
}

.points-card .card-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* ========== 현재 위치 리워드 ========== */
.current-reward-card {
    background: white;
    margin: 0 16px 16px;
    padding: 16px 20px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.current-reward-card .location-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.current-reward-card .location-icon {
    width: 44px;
    height: 44px;
    background: var(--primary-light);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 18px;
}

.current-reward-card .location-name {
    font-size: 15px;
    font-weight: 700;
}

.current-reward-card .location-desc {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 2px;
}

.reward-percent {
    font-size: 24px;
    font-weight: 800;
    color: var(--primary);
}

/* ========== 보너스 정보 ========== */
.bonus-bar {
    display: flex;
    gap: 8px;
    margin: 0 16px 16px;
}

.bonus-item {
    flex: 1;
    background: white;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow);
    text-align: center;
}

.bonus-item .bonus-label {
    font-size: 11px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.bonus-item .bonus-value {
    font-size: 14px;
    font-weight: 700;
    color: var(--primary-dark);
}

/* ========== 섹션 타이틀 ========== */
.section-title {
    font-size: 16px;
    font-weight: 700;
    padding: 8px 20px;
    color: var(--text-dark);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.section-title .see-all {
    font-size: 13px;
    color: var(--primary);
    font-weight: 500;
    cursor: pointer;
    border: none;
    background: none;
    font-family: inherit;
}

/* ========== 홈 지도 (미니맵) ========== */
.home-map-container {
    margin: 0 16px 8px;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

#homeMap {
    width: 100%;
    height: 300px;
}

.map-legend {
    display: flex;
    justify-content: center;
    gap: 16px;
    padding: 10px 16px;
    background: white;
    margin: 0 16px 16px;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow);
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

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

.legend-dot.low { background: var(--primary); }
.legend-dot.medium { background: var(--accent-orange); }
.legend-dot.high { background: var(--accent-red); }

/* ========== 구역 리스트 ========== */
.zone-list {
    padding: 0 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}

.zone-item {
    background: white;
    padding: 16px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 14px;
    cursor: pointer;
    transition: all 0.3s;
    animation: fadeInUp 0.4s ease-out both;
}

.zone-item:nth-child(1) { animation-delay: 0s; }
.zone-item:nth-child(2) { animation-delay: 0.08s; }
.zone-item:nth-child(3) { animation-delay: 0.16s; }
.zone-item:nth-child(4) { animation-delay: 0.24s; }

.zone-item:active {
    transform: scale(0.98);
}

.zone-item.low { border-left: 4px solid var(--primary); }
.zone-item.medium { border-left: 4px solid var(--accent-orange); }
.zone-item.high { border-left: 4px solid var(--accent-red); }

.zone-item .zone-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

.zone-item.low .zone-icon {
    background: #e8f5e9;
    color: var(--primary);
}

.zone-item.medium .zone-icon {
    background: #fff3e0;
    color: var(--accent-orange);
}

.zone-item.high .zone-icon {
    background: #ffebee;
    color: var(--accent-red);
}

.zone-item .zone-info {
    flex: 1;
    min-width: 0;
}

.zone-item .zone-name {
    font-size: 15px;
    font-weight: 700;
}

.zone-item .zone-desc {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.zone-item .zone-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 4px;
}

.zone-item .zone-distance {
    font-size: 11px;
    color: var(--text-light);
}

.zone-item .zone-activity {
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 10px;
}

.zone-activity.low {
    background: #e8f5e9;
    color: #2e7d32;
}

.zone-activity.medium {
    background: #fff3e0;
    color: #e65100;
}

.zone-activity.high {
    background: #ffebee;
    color: #c62828;
}

.zone-item .zone-reward {
    font-size: 20px;
    font-weight: 800;
    color: var(--primary);
    white-space: nowrap;
}

.zone-item.medium .zone-reward { color: var(--accent-orange); }
.zone-item.high .zone-reward { color: var(--accent-red); }

/* ========== 미션 리스트 ========== */
.mission-list {
    padding: 0 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}

.mission-item {
    background: white;
    padding: 16px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 14px;
}

.mission-item.completed {
    opacity: 0.6;
}

.mission-icon {
    width: 44px;
    height: 44px;
    background: var(--primary-light);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 18px;
    flex-shrink: 0;
}

.mission-item.completed .mission-icon {
    background: #e0e0e0;
    color: var(--text-light);
}

.mission-info {
    flex: 1;
    min-width: 0;
}

.mission-title {
    font-size: 14px;
    font-weight: 700;
}

.mission-desc {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 2px;
}

.mission-progress-bar {
    height: 6px;
    background: #e0e0e0;
    border-radius: 3px;
    margin-top: 8px;
    overflow: hidden;
}

.mission-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--primary-dark));
    border-radius: 3px;
    transition: width 0.5s ease;
}

.mission-reward {
    font-size: 14px;
    font-weight: 700;
    color: var(--primary);
    white-space: nowrap;
}

.mission-progress-text {
    font-size: 11px;
    color: var(--text-light);
    margin-top: 2px;
}

/* ========== 지도 화면 ========== */
.map-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: white;
    border-bottom: 1px solid var(--border);
}

.back-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: white;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-family: inherit;
}

.map-header h2 {
    font-size: 17px;
    font-weight: 700;
}

.map-controls {
    display: flex;
    gap: 8px;
    padding: 10px 16px;
    background: white;
    border-bottom: 1px solid var(--border);
}

.map-control-btn {
    padding: 8px 14px;
    border-radius: 20px;
    border: 1px solid var(--border);
    background: white;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s;
}

.map-control-btn:hover {
    background: var(--bg);
}

#mainMap {
    width: 100%;
    height: calc(100vh - 200px);
}

.filter-buttons {
    display: flex;
    gap: 8px;
    padding: 12px 16px;
    background: white;
    border-top: 1px solid var(--border);
}

.filter-btn {
    flex: 1;
    padding: 10px;
    border-radius: 24px;
    border: 1px solid var(--border);
    background: white;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s;
    text-align: center;
}

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

.filter-btn[data-filter="low"].active {
    background: var(--primary);
    border-color: var(--primary);
}

.filter-btn[data-filter="medium"].active {
    background: var(--accent-orange);
    border-color: var(--accent-orange);
}

.filter-btn[data-filter="high"].active {
    background: var(--accent-red);
    border-color: var(--accent-red);
}

/* 지도 마커 스타일 */
.circle-percent-container {
    background: none !important;
    border: none !important;
}

.circle-percent {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    font-weight: 800;
    color: #FFFFFF;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
    pointer-events: none;
}

.zone-label-container {
    background: none !important;
    border: none !important;
}

.zone-label-name {
    padding: 3px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
    white-space: nowrap;
    text-align: center;
}

.my-location-icon {
    background: none !important;
    border: none !important;
}

.my-location-pulse {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.my-location-pulse i {
    color: #2196F3;
    font-size: 14px;
    z-index: 2;
    position: relative;
}

.my-location-pulse::before {
    content: '';
    position: absolute;
    width: 24px;
    height: 24px;
    background: rgba(33, 150, 243, 0.25);
    border-radius: 50%;
    animation: locationPulse 2s infinite;
}

/* 지도 팝업 */
.zone-popup {
    padding: 4px;
    min-width: 180px;
}

.zone-popup h4 {
    font-size: 15px;
    font-weight: 700;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.zone-popup .zone-description {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 10px;
}

.zone-popup .zone-reward {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 8px;
}

.zone-popup .reward-badge.low {
    background: #e8f5e9;
    color: #2e7d32;
}

.zone-popup .reward-badge.medium {
    background: #fff3e0;
    color: #e65100;
}

.zone-popup .reward-badge.high {
    background: #ffebee;
    color: #c62828;
}

.zone-popup .zone-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 10px;
}

.zone-popup .checkin-btn {
    width: 100%;
    padding: 10px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    transition: opacity 0.2s;
}

.zone-popup .checkin-btn:hover {
    opacity: 0.9;
}

/* ========== 알림 화면 ========== */
.screen-header {
    padding: 16px 20px;
    background: white;
    border-bottom: 1px solid var(--border);
}

.screen-header h2 {
    font-size: 20px;
    font-weight: 800;
}

.notification-tabs {
    display: flex;
    background: white;
    border-bottom: 1px solid var(--border);
    padding: 0 16px;
}

.tab-btn {
    flex: 1;
    padding: 14px;
    border: none;
    background: none;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-light);
    cursor: pointer;
    font-family: inherit;
    position: relative;
    transition: color 0.2s;
}

.tab-btn.active {
    color: var(--primary);
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 20%;
    width: 60%;
    height: 3px;
    background: var(--primary);
    border-radius: 3px 3px 0 0;
}

.notification-list {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.notification-item {
    background: white;
    padding: 16px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    display: flex;
    gap: 14px;
    animation: fadeInUp 0.3s ease-out;
}

.notification-item.read {
    opacity: 0.6;
}

.notif-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    flex-shrink: 0;
}

.notif-icon.reward {
    background: #e8f5e9;
    color: var(--primary);
}

.notif-icon.mission {
    background: #fff3e0;
    color: var(--accent-orange);
}

.notif-icon.activity {
    background: #e3f2fd;
    color: #1976D2;
}

.notif-content h4 {
    font-size: 14px;
    font-weight: 700;
}

.notif-content p {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 2px;
}

.notif-time {
    font-size: 11px;
    color: var(--text-light);
    margin-top: 4px;
    display: block;
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-light);
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.4;
}

.empty-state p {
    font-size: 14px;
}

/* ========== 프로필 화면 ========== */
.profile-card {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 32px 24px;
    text-align: center;
    color: white;
    position: relative;
    overflow: hidden;
}

.profile-card::after {
    content: '';
    position: absolute;
    top: -40px;
    right: -40px;
    width: 150px;
    height: 150px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50%;
}

.profile-avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
    font-size: 32px;
}

.profile-card h3 {
    font-size: 20px;
    font-weight: 800;
}

.profile-level {
    display: inline-block;
    padding: 4px 16px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    margin-top: 8px;
}

.profile-progress {
    margin-top: 16px;
}

.profile-progress .progress-bar-bg {
    height: 6px;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 3px;
    overflow: hidden;
}

.profile-progress .progress-bar-fill {
    height: 100%;
    background: white;
    border-radius: 3px;
    transition: width 0.5s ease;
}

.profile-progress .progress-text {
    font-size: 11px;
    opacity: 0.8;
    margin-top: 6px;
}

/* 통계 그리드 */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    padding: 16px;
}

.stat-item {
    background: white;
    padding: 16px 10px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    text-align: center;
}

.stat-value {
    font-size: 22px;
    font-weight: 800;
    color: var(--primary);
}

.stat-label {
    font-size: 11px;
    color: var(--text-secondary);
    margin-top: 4px;
    font-weight: 500;
}

/* 배지 컬렉션 */
.badge-section {
    padding: 0 16px 16px;
}

.badge-section h3 {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 12px;
    padding: 0 4px;
}

.badge-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.badge-item {
    background: white;
    padding: 16px 8px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    text-align: center;
    transition: all 0.3s;
}

.badge-item.locked {
    opacity: 0.45;
    filter: grayscale(1);
}

.badge-item .badge-icon {
    font-size: 32px;
    margin-bottom: 6px;
}

.badge-item .badge-name {
    font-size: 12px;
    font-weight: 700;
}

.badge-item .badge-desc {
    font-size: 10px;
    color: var(--text-light);
    margin-top: 2px;
}

/* 미션 진행 현황 */
.mission-section {
    padding: 0 16px 24px;
}

.mission-section h3 {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 12px;
    padding: 0 4px;
}

/* 데이터 초기화 버튼 */
.reset-section {
    padding: 16px;
    text-align: center;
}

.reset-btn {
    padding: 12px 24px;
    border: 1px solid var(--accent-red);
    border-radius: var(--radius-sm);
    background: white;
    color: var(--accent-red);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s;
}

.reset-btn:hover {
    background: #ffebee;
}

/* ========== 체크인 모달 ========== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

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

.modal-content {
    width: 100%;
    max-width: 480px;
    background: white;
    border-radius: 24px 24px 0 0;
    padding: 24px;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
}

.modal-overlay.show .modal-content {
    transform: translateY(0);
}

.modal-handle {
    width: 40px;
    height: 4px;
    background: #DDD;
    border-radius: 2px;
    margin: 0 auto 16px;
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 20px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: var(--bg);
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: inherit;
}

.modal-zone-header {
    text-align: center;
    margin-bottom: 20px;
}

.modal-zone-header .activity-badge {
    display: inline-block;
    padding: 4px 14px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 10px;
}

.modal-zone-header h2 {
    font-size: 22px;
    font-weight: 800;
}

.modal-zone-header p {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 4px;
}

.reward-breakdown {
    background: var(--bg);
    border-radius: var(--radius);
    padding: 20px;
    margin-bottom: 20px;
    text-align: center;
}

.reward-total {
    font-size: 36px;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 12px;
}

.reward-detail {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.reward-detail span {
    font-size: 13px;
    color: var(--text-secondary);
    display: flex;
    justify-content: space-between;
}

.reward-detail span strong {
    color: var(--text-dark);
}

.btn-checkin {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    border: none;
    border-radius: var(--radius);
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: opacity 0.2s;
}

.btn-checkin:hover {
    opacity: 0.9;
}

.btn-checkin:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.cooldown-text {
    text-align: center;
    font-size: 13px;
    color: var(--accent-red);
    margin-top: 8px;
}

/* ========== 토스트 알림 ========== */
#toastContainer {
    position: fixed;
    bottom: calc(var(--nav-height) + 20px);
    left: 50%;
    transform: translateX(-50%);
    z-index: 3000;
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
    pointer-events: none;
    width: 90%;
    max-width: 400px;
}

.toast {
    padding: 14px 24px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    transform: translateY(20px);
    animation: toastIn 0.3s ease forwards;
    white-space: nowrap;
    pointer-events: auto;
}

.toast-exit {
    animation: toastOut 0.3s ease forwards;
}

.toast-success {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
}

.toast-badge {
    background: linear-gradient(135deg, #FFA726, #F57C00);
    color: white;
}

.toast-info {
    background: rgba(33, 33, 33, 0.9);
    color: white;
}

.toast-error {
    background: linear-gradient(135deg, var(--accent-red), #C62828);
    color: white;
}

/* ========== 애니메이션 ========== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

@keyframes toastIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes toastOut {
    from {
        opacity: 1;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        transform: translateY(-20px);
    }
}

@keyframes locationPulse {
    0% {
        transform: scale(1);
        opacity: 0.6;
    }
    100% {
        transform: scale(2.5);
        opacity: 0;
    }
}

@keyframes pointsUp {
    0% {
        opacity: 1;
        transform: translateY(0);
    }
    100% {
        opacity: 0;
        transform: translateY(-40px);
    }
}

/* ========== Leaflet 팝업 커스터마이즈 ========== */
.leaflet-popup-content-wrapper {
    border-radius: 14px !important;
    box-shadow: var(--shadow-lg) !important;
}

.leaflet-popup-content {
    margin: 12px 14px !important;
    font-family: 'Noto Sans KR', sans-serif !important;
}

.leaflet-popup-close-button {
    top: 8px !important;
    right: 10px !important;
}

/* ========== 반응형 ========== */
@media (min-width: 768px) {
    body {
        background: #e0e0e0;
    }
}

/* 안전 영역 (노치 대응) */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
    .bottom-nav {
        padding-bottom: env(safe-area-inset-bottom);
        height: calc(var(--nav-height) + env(safe-area-inset-bottom));
    }

    .screen {
        padding-bottom: calc(var(--nav-height) + env(safe-area-inset-bottom) + 16px);
    }
}
