/*
 * NELOW 원본 스타일 + OCR Gallery
 */

/* ============================================================
   기본 설정
   ============================================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Roboto', sans-serif;
    background: #1a2332;
    color: #e0e0e0;
    overflow: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ============================================================
   앱 레이아웃
   ============================================================ */
.app {
    width: 100vw;
    height: 100vh;
    overflow: hidden;
}

.page-wrapper {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.page-wrapper.toggled #sidebar {
    width: 180px;
}

/* ============================================================
   헤더 (NELOW 스타일)
   ============================================================ */
#Header {
    height: 50px;
    background: #263544;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 15px;
    border-bottom: 1px solid #3a4a5a;
    z-index: 100;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 24px;
}

.header-navbar {
    display: flex;
    align-items: center;
}

.header-navbar--nav {
    display: flex;
    align-items: center;
    list-style: none;
    gap: 10px;
}

.header-navbar--nav li a {
    color: #8a9bae;
    padding: 8px;
    display: flex;
    align-items: center;
    transition: color 0.2s;
}

.header-navbar--nav li a:hover {
    color: #fff;
}

.header-navbar--nav li a i {
    font-size: 16px;
}

.item-select {
    padding: 6px 30px 6px 12px;
    background: #1a2332;
    border: 1px solid #3a4a5a;
    border-radius: 4px;
    color: #e0e0e0;
    font-size: 13px;
    min-width: 140px;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23ffffff' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10l-5 5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
}

.item-select:focus {
    outline: none;
    border-color: #4a90d9;
}

/* ============================================================
   사이드바 (NELOW 스타일)
   ============================================================ */
#sidebar {
    position: fixed;
    left: 0;
    top: 50px;
    width: 180px;
    height: calc(100vh - 50px);
    background: #263544;
    border-right: 1px solid #3a4a5a;
    overflow-y: auto;
    z-index: 50;
}

.sidebar-menu {
    padding: 10px 0;
}

.menu_list {
    list-style: none;
}

.menu_list > li {
    margin: 2px 8px;
}

.menu_list > li > a {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    color: #8a9bae;
    font-size: 13px;
    border-radius: 4px;
    transition: all 0.2s;
}

.menu_list > li > a:hover {
    background: #2d4a5e;
    color: #fff;
}

.menu_list > li.active > a {
    background: #4a90d9;
    color: #fff;
}

/* 서브메뉴 */
.menu_list > li > ul {
    list-style: none;
    display: none;
    margin-left: 15px;
    margin-top: 5px;
}

.menu_list > li:hover > ul {
    display: block;
}

.menu_list > li > ul > li > a {
    display: block;
    padding: 6px 12px;
    color: #7a8a9a;
    font-size: 12px;
    border-radius: 3px;
}

.menu_list > li > ul > li > a:hover {
    background: #2d4a5e;
    color: #fff;
}

/* 아이콘 (사이드바 메뉴) */
.menu_list > li > a::before {
    content: '';
    width: 18px;
    height: 18px;
    margin-right: 10px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.icon_01 > a::before { content: '🗺️'; }
.icon_02 > a::before { content: '💧'; }
.icon_03 > a::before { content: '⏱️'; }
.icon_04 > a::before { content: '🌊'; }
.icon_05 > a::before { content: '🔧'; }
.icon_ocr > a::before { content: '📷'; }

/* ============================================================
   메인 콘텐츠
   ============================================================ */
#main {
    margin-left: 180px;
    margin-top: 50px;
    height: calc(100vh - 50px);
    background: #f0f2f5;
    overflow: hidden;
}

.content-wrap {
    height: 100%;
}

.page-view {
    display: none;
    height: 100%;
    flex-direction: column;
}

.page-view.active {
    display: flex;
}

/* ============================================================
   툴바 (NELOW 스타일)
   ============================================================ */
.toolbar-area {
    background: #263544;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
}

.btn-toolbar {
    display: flex;
    align-items: center;
    gap: 4px;
}

.map-button {
    width: 28px;
    height: 28px;
    padding: 0;
    border: 1px solid #3a4a5a;
    background: #1a2332;
    color: #8a9bae;
    border-radius: 3px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

.map-button:hover {
    background: #2d4a5e;
    color: #fff;
}

.icon_btn_text {
    width: auto;
    padding: 0 12px;
    font-size: 12px;
}

.btn-map-view {
    background: #4a90d9;
    border-color: #4a90d9;
    color: #fff;
}

.btn-map-view:hover {
    background: #3b7dd8;
}

.search_div {
    display: flex;
    align-items: center;
    gap: 8px;
}

.form-control {
    padding: 5px 10px;
    background: #1a2332;
    border: 1px solid #3a4a5a;
    border-radius: 3px;
    color: #e0e0e0;
    font-size: 12px;
}

.form-control:focus {
    outline: none;
    border-color: #4a90d9;
}

.form-control-sm {
    height: 28px;
}

/* ============================================================
   갤러리 영역
   ============================================================ */
.gallery-area {
    flex: 1;
    overflow-y: auto;
    padding: 15px;
    background: #f0f2f5;
}

.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 15px;
}

.photo-card {
    background: #fff;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.photo-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.photo-card img {
    width: 100%;
    height: 130px;
    object-fit: cover;
}

.photo-info {
    padding: 10px;
}

.photo-info .camera-id {
    font-size: 12px;
    color: #4a90d9;
    font-weight: 500;
}

.photo-info .date {
    font-size: 11px;
    color: #888;
}

.loading, .no-photos {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px;
    color: #888;
}

.loading i {
    font-size: 24px;
    color: #4a90d9;
    margin-bottom: 10px;
}

/* ============================================================
   페이지네이션
   ============================================================ */
.pagination-area {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    padding: 12px;
    background: #fff;
    border-top: 1px solid #e0e0e0;
}

#page-info {
    font-size: 13px;
    color: #666;
}

.btn {
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-secondary {
    background: #6c757d;
    border: none;
    color: #fff;
}

.btn-secondary:hover:not(:disabled) {
    background: #5a6268;
}

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

.btn-primary {
    background: #4a90d9;
    border: none;
    color: #fff;
}

.btn-danger {
    background: #dc3545;
    border: none;
    color: #fff;
}

/* ============================================================
   빈 페이지
   ============================================================ */
.empty-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #888;
}

.empty-page i {
    font-size: 48px;
    margin-bottom: 15px;
    color: #ccc;
}

/* ============================================================
   모달
   ============================================================ */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal-overlay.active {
    display: flex;
}

.modal-content {
    background: #fff;
    border-radius: 8px;
    max-width: 600px;
    max-height: 80vh;
    overflow: hidden;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background: #263544;
    color: #fff;
}

.modal-header h3 {
    font-size: 14px;
    font-weight: 500;
}

.modal-close {
    background: none;
    border: none;
    color: #8a9bae;
    cursor: pointer;
    font-size: 16px;
}

.modal-close:hover {
    color: #fff;
}

.modal-body {
    padding: 15px;
}

#modal-image {
    max-width: 100%;
    border-radius: 4px;
    margin-bottom: 10px;
}

.modal-info {
    background: #f5f5f5;
    padding: 10px;
    border-radius: 4px;
    font-size: 12px;
    color: #333;
}

.modal-info p {
    margin: 4px 0;
}

.modal-info strong {
    color: #4a90d9;
}

.modal-footer {
    display: flex;
    gap: 8px;
    padding: 12px 15px;
    border-top: 1px solid #eee;
    justify-content: flex-end;
}

/* ============================================================
   지도 영역
   ============================================================ */
.map-area {
    flex: 1;
    position: relative;
    overflow: hidden;
}

#map, #map-dma {
    width: 100%;
    height: 100%;
}

.map-zoom {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(0,0,0,0.6);
    color: #fff;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
    z-index: 500;
}

/* Leaflet 커스텀 */
.leaflet-container {
    font-family: 'Roboto', sans-serif;
    background: #1a1a2e;
}

/* 현재 위치 마커 (펄스 애니메이션) */
.my-location-marker {
    position: relative;
}

.pulse-core {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 16px;
    height: 16px;
    background: #00d4ff;
    border: 3px solid #fff;
    border-radius: 50%;
    box-shadow: 0 0 15px #00d4ff, 0 2px 10px rgba(0,0,0,0.5);
    z-index: 2;
}

.pulse-ring {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border: 3px solid #00d4ff;
    border-radius: 50%;
    animation: pulse-animation 2s ease-out infinite;
    z-index: 1;
}

@keyframes pulse-animation {
    0% {
        transform: translate(-50%, -50%) scale(0.5);
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -50%) scale(2);
        opacity: 0;
    }
}

.leaflet-popup-content-wrapper {
    border-radius: 8px;
    background: #263544;
    color: #fff;
}

.leaflet-popup-tip {
    background: #263544;
}

.leaflet-popup-content {
    margin: 10px 12px;
}

/* 레이어 컨트롤 스타일 */
.leaflet-control-layers {
    background: #263544;
    border-radius: 6px;
    border: 1px solid #3a4a5a;
}

.leaflet-control-layers-expanded {
    padding: 8px 12px;
    color: #e0e0e0;
}

.leaflet-control-layers label {
    margin-bottom: 5px;
}

.leaflet-control-layers-selector {
    margin-right: 8px;
}

/* ============================================================
   AI 펫 (Nelow Companion)
   ============================================================ */

/* 펫 컨테이너 */
#nelow-pet-container {
    position: fixed;
    z-index: 9999;
    pointer-events: none;
}

/* 펫 본체 */
.nelow-pet {
    position: fixed;
    cursor: pointer;
    pointer-events: auto;
    transition: transform 0.1s ease;
    z-index: 9999;
}

.nelow-pet:hover {
    transform: scale(1.05);
}

.nelow-pet-inner {
    position: relative;
}

.nelow-pet img {
    width: 100px;
    height: 100px;
    object-fit: contain;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.3));
}

/* 펫 말풍선 */
.nelow-speech {
    position: absolute;
    top: -45px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255,255,255,0.95);
    color: #333;
    padding: 8px 14px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    opacity: 0;
    transition: opacity 0.3s, transform 0.3s;
    pointer-events: none;
}

.nelow-pet:hover .nelow-speech,
.nelow-pet.speaking .nelow-speech {
    opacity: 1;
    transform: translateX(-50%) translateY(-5px);
}

/* 펫 상태 효과 */
.nelow-pet.walking img {
    animation: pet-bounce 0.5s ease infinite;
}

.nelow-pet.thinking img {
    animation: pet-pulse 1s ease infinite;
}

@keyframes pet-bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

@keyframes pet-pulse {
    0%, 100% { opacity: 1; filter: drop-shadow(0 4px 8px rgba(0,0,0,0.3)); }
    50% { opacity: 0.8; filter: drop-shadow(0 4px 20px rgba(0,212,255,0.5)); }
}

@keyframes pet-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

.nelow-pet.idle img {
    animation: pet-float 3s ease-in-out infinite;
}

/* ============================================================
   AI 채팅 모달
   ============================================================ */
.nelow-chat-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    justify-content: center;
    align-items: center;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(5px);
}

.nelow-chat-modal.active {
    display: flex;
}

.nelow-chat-content {
    width: 420px;
    max-width: 95vw;
    height: 600px;
    max-height: 85vh;
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border-radius: 16px;
    border: 1px solid #334155;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 25px 50px rgba(0,0,0,0.5);
}

/* 채팅 헤더 */
.nelow-chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    background: rgba(30,41,59,0.8);
    border-bottom: 1px solid #334155;
}

.nelow-chat-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nelow-avatar {
    font-size: 28px;
    background: #06b6d4;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nelow-chat-title h3 {
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: #f1f5f9;
    margin: 0;
}

.nelow-status {
    font-size: 11px;
    color: #94a3b8;
    display: flex;
    align-items: center;
    gap: 5px;
}

.status-dot {
    width: 6px;
    height: 6px;
    background: #22c55e;
    border-radius: 50%;
    animation: status-pulse 2s ease infinite;
}

@keyframes status-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.nelow-chat-actions {
    display: flex;
    gap: 8px;
}

.nelow-skin-btn, .nelow-close-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: rgba(51,65,85,0.5);
    color: #94a3b8;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.nelow-skin-btn:hover, .nelow-close-btn:hover {
    background: #334155;
    color: #06b6d4;
}

/* 지식베이스 상태 섹션 */
.nelow-kb-section {
    background: rgba(30,41,59,0.5);
    border-bottom: 1px solid #334155;
    padding: 10px 16px;
}

.nelow-kb-status {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #94a3b8;
    font-size: 12px;
}

.kb-badge {
    background: #334155;
    padding: 3px 8px;
    border-radius: 10px;
    font-size: 10px;
    color: #94a3b8;
}

.kb-badge.loaded {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

.kb-badge.error {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

/* 메시지 영역 */
.nelow-messages {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.nelow-messages::-webkit-scrollbar {
    width: 6px;
}

.nelow-messages::-webkit-scrollbar-track {
    background: transparent;
}

.nelow-messages::-webkit-scrollbar-thumb {
    background: #334155;
    border-radius: 3px;
}

.nelow-welcome {
    text-align: center;
    padding: 40px 20px;
    color: #94a3b8;
}

.welcome-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.nelow-welcome p {
    font-size: 16px;
    color: #f1f5f9;
    margin-bottom: 8px;
}

.nelow-welcome small {
    font-size: 13px;
}

/* 예시 질문 버튼 */
.nelow-suggestions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 20px;
    justify-content: center;
}

.nelow-suggestions button {
    background: #1e293b;
    border: 1px solid #334155;
    color: #e2e8f0;
    padding: 8px 14px;
    border-radius: 20px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}

.nelow-suggestions button:hover {
    background: #06b6d4;
    border-color: #06b6d4;
    transform: translateY(-2px);
}

/* 메시지 버블 */
.nelow-message {
    max-width: 85%;
    padding: 12px 16px;
    border-radius: 16px;
    font-size: 14px;
    line-height: 1.5;
}

.nelow-message.user {
    align-self: flex-end;
    background: #06b6d4;
    color: #fff;
    border-bottom-right-radius: 4px;
}

.nelow-message.assistant {
    align-self: flex-start;
    background: #1e293b;
    color: #e2e8f0;
    border: 1px solid #334155;
    border-bottom-left-radius: 4px;
}

.nelow-message .time {
    font-size: 10px;
    opacity: 0.7;
    margin-top: 6px;
    display: block;
    text-align: right;
}

/* 로딩 애니메이션 */
.nelow-loading {
    display: flex;
    gap: 4px;
    padding: 12px 16px;
    background: #1e293b;
    border: 1px solid #334155;
    border-radius: 16px;
    border-bottom-left-radius: 4px;
    align-self: flex-start;
}

.nelow-loading span {
    width: 8px;
    height: 8px;
    background: #06b6d4;
    border-radius: 50%;
    animation: loading-bounce 1.4s ease-in-out infinite;
}

.nelow-loading span:nth-child(1) { animation-delay: 0s; }
.nelow-loading span:nth-child(2) { animation-delay: 0.2s; }
.nelow-loading span:nth-child(3) { animation-delay: 0.4s; }

@keyframes loading-bounce {
    0%, 80%, 100% { transform: scale(0.6); opacity: 0.5; }
    40% { transform: scale(1); opacity: 1; }
}

/* 입력 폼 */
.nelow-input-form {
    display: flex;
    gap: 10px;
    padding: 16px;
    background: rgba(30,41,59,0.5);
    border-top: 1px solid #334155;
}

.nelow-input-form input {
    flex: 1;
    padding: 12px 16px;
    background: #0f172a;
    border: 1px solid #334155;
    border-radius: 12px;
    color: #f1f5f9;
    font-size: 14px;
    font-family: 'Inter', sans-serif;
}

.nelow-input-form input:focus {
    outline: none;
    border-color: #06b6d4;
}

.nelow-input-form input::placeholder {
    color: #64748b;
}

.nelow-input-form button {
    width: 44px;
    height: 44px;
    background: #06b6d4;
    border: none;
    border-radius: 12px;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.nelow-input-form button:hover {
    background: #0891b2;
}

.nelow-input-form button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ============================================================
   QGIS Viewer 페이지 (심플 버전)
   ============================================================ */
.icon_qgis > a::before {
    content: "\f5ee";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    margin-right: 10px;
    color: #10b981;
}

.qgis-simple-container {
    height: calc(100vh - 130px);
    padding: 15px;
    overflow: hidden;
}

/* 업로드 영역 */
.qgis-upload-area {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qgis-dropzone {
    width: 100%;
    max-width: 500px;
    padding: 60px 40px;
    border: 2px dashed #475569;
    border-radius: 16px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    background: #1e293b;
}

.qgis-dropzone:hover,
.qgis-dropzone.dragover {
    border-color: #10b981;
    background: #1a2e35;
}

.qgis-dropzone i {
    font-size: 48px;
    color: #10b981;
    margin-bottom: 15px;
    display: block;
}

.qgis-dropzone p {
    color: #94a3b8;
    font-size: 16px;
}

/* 결과 영역 */
.qgis-result-area {
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.qgis-info-bar {
    background: #1e293b;
    padding: 10px 15px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 14px;
    color: #e2e8f0;
}

.qgis-info-bar i {
    color: #10b981;
}

.qgis-info-bar button {
    margin-left: auto;
    background: #ef4444;
    border: none;
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 6px;
    cursor: pointer;
}

.qgis-info-bar button:hover {
    background: #dc2626;
}

/* 2열 레이아웃 */
.qgis-content-grid {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 15px;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

/* 왼쪽 패널: 레이어 */
.qgis-layers-panel {
    background: #1e293b;
    border-radius: 10px;
    padding: 15px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.qgis-layers-panel h4 {
    color: #f1f5f9;
    font-size: 15px;
    margin-bottom: 12px;
    flex-shrink: 0;
}

#qgis-layers-list {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.layer-item {
    background: #334155;
    padding: 10px 12px;
    border-radius: 6px;
    font-size: 13px;
    color: #e2e8f0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.layer-item i {
    color: #3b82f6;
}

.layer-item .count {
    margin-left: auto;
    color: #64748b;
    font-size: 12px;
}

.qgis-analyze-btn {
    margin-top: 12px;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    border: none;
    padding: 12px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    flex-shrink: 0;
}

.qgis-analyze-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}

/* 오른쪽 패널: AI 분석 */
.qgis-analysis-panel {
    background: #1e293b;
    border-radius: 10px;
    padding: 15px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.qgis-analysis-panel h4 {
    color: #f1f5f9;
    font-size: 15px;
    margin-bottom: 12px;
    flex-shrink: 0;
}

.qgis-ai-output {
    flex: 1;
    background: #0f172a;
    border-radius: 8px;
    padding: 15px;
    overflow-y: auto;
    font-size: 14px;
    line-height: 1.7;
    color: #e2e8f0;
    white-space: pre-wrap;
    word-break: break-word;
}

.qgis-ai-output .placeholder-text {
    color: #64748b;
    text-align: center;
    padding: 40px 20px;
}

.qgis-ai-output .loading {
    color: #f59e0b;
    text-align: center;
    padding: 40px 20px;
}

.qgis-ai-output .loading i {
    animation: spin 1s linear infinite;
    margin-right: 8px;
}

@keyframes spin {
    100% { transform: rotate(360deg); }
}

/* ============================================================
   반응형
   ============================================================ */
@media (max-width: 768px) {
    #sidebar {
        width: 50px;
    }
    
    #main {
        margin-left: 50px;
    }
    
    .menu_list > li > a span {
        display: none;
    }
    
    .gallery {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    }
    
    .nelow-pet img {
        width: 80px;
        height: 80px;
    }
    
    .nelow-chat-content {
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
    }
    
    .qgis-upload-box {
        padding: 40px 20px;
    }
    
    .qgis-upload-box .upload-icon {
        font-size: 48px;
    }
}
