/* 중간 검색창 패널 */
.search-panel {
    width: 260px;
    height: 100vh; /* 화면 전체 높이 사용 */
    background-color: white;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    position: absolute;
    left: 260px;
    top: 0;
    bottom: 0;
    z-index: 2;
    /* [수정] 기본 상태: 왼쪽으로 자기 너비만큼 밀어서 사이드바 뒤로 숨김 */
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;/* 헤더와 결과 영역을 세로로 배치 */
}

/* 활성화 상태: 보임 */
.search-panel.show {
    transform: translateX(0);
}

.search-header {
    padding: 20px;
    border-bottom: 1px solid #e5e5e5;
}

.search-input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #00c73c;
    border-radius: 5px;
    font-size: 16px;
    outline: none;
}

.search-content {
    flex: 1;/* 헤더를 제외한 나머지 모든 공간 차지 */
    overflow-y: auto;/* 내용이 길어지면 세로 스크롤 생성 */
    padding: 20px;
}

.result-item {
    padding: 15px;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
}

.result-item:hover {
    background-color: #f8f8f8;
}

/* 슬라이드 토글 버튼 */
.toggle-search-btn {
    position: absolute;
    right: -40px;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 80px;
    background-color: white;
    border: 1px solid #e5e5e5;
    border-left: none;
    border-radius: 0 10px 10px 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.1);
    transition: background-color 0.3s;
    z-index: 10;
}

.toggle-search-btn:hover {
    background-color: #f8f8f8;
}

/* 1. 기본 화살표 (패널이 닫혀 있을 때) */
.toggle-search-btn::before {
    content: '▶'; /* 닫혀 있으니 오른쪽을 가리킴 */
    font-size: 16px;
    color: #666;
}

/* 2. 패널이 열렸을 때 (show 클래스가 붙었을 때) */
.search-panel.show .toggle-search-btn::before {
    content: '◀'; /* 열렸으니 왼쪽을 가리킴 */
}

/* PC 검색 결과 내 길찾기 버튼 */
.title-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.pc-route-btn {
    padding: 4px 8px;
    background-color: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    font-size: 12px;
    color: #666;
    cursor: pointer;
    transition: all 0.2s;
}

.pc-route-btn:hover {
    background-color: #2d7ff9;
    color: white;
    border-color: #2d7ff9;
}

.pc-route-btn i {
    margin-right: 4px;
}

/* 기본 탭 버튼 스타일 */
.tab-btn {
    flex: 1;
    padding: 12px;
    background: none;
    border: none;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    color: #999; /* 기본값: 회색 */
    border-bottom: 2px solid transparent; /* 수평을 맞추기 위한 투명 선 */
    margin-bottom: -2px; /* 부모 컨테이너의 border와 겹치게 설정 */
    transition: all 0.2s;
}

/* 활성화된 탭 버튼 스타일 */
.tab-btn.active {
    color: #667eea !important;
    border-bottom: 2px solid #667eea !important;
}

.tab-btn:hover {
    background: #f5f5f5;
}