* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Microsoft YaHei', sans-serif;
}

body {
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

.container {
    display: flex;
    flex-direction: column;
    height: 100vh;
    max-width: 1600px;
    margin: 0 auto;
}

header {
    background: linear-gradient(135deg, #1a6dcc 0%, #0d4a9e 100%);
    color: white;
    padding: 1rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 100;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 1rem;
}

h1 {
    font-size: 1.8rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-info {
    font-size: 0.9rem;
    opacity: 0.9;
}

.main-content {
    display: flex;
    flex: 1;
    overflow: hidden;
}

.sidebar {
    width: 350px;
    background-color: #fff;
    padding: 20px;
    overflow-y: auto;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.map-container {
    flex: 1;
    position: relative;
}

#map {
    width: 100%;
    height: 100%;
}

.search-box {
    margin-bottom: 20px;
    position: relative;
}

.search-box input {
    width: 100%;
    padding: 12px 15px 12px 45px;
    border: 1px solid #ddd;
    border-radius: 30px;
    font-size: 1rem;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    transition: all 0.3s;
}

.search-box input:focus {
    outline: none;
    border-color: #1a6dcc;
    box-shadow: 0 2px 8px rgba(26, 109, 204, 0.2);
}

.search-box i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #888;
}

.stats {
    background: #f0f7ff;
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 20px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    text-align: center;
}

.stat-item {
    padding: 10px;
}

.stat-value {
    font-size: 1.8rem;
    font-weight: bold;
    color: #1a6dcc;
}

.stat-label {
    font-size: 0.85rem;
    color: #666;
}

.institution-list {
    border-top: 1px solid #e1f0ff;
    max-height: calc(100vh - 300px);
    overflow-y: auto;
}

.institution-item {
    padding: 15px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
    transition: all 0.2s;
    border-radius: 8px;
}

.institution-item:hover {
    background-color: #f0f7ff;
    transform: translateY(-2px);
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.08);
}

.institution-item h3 {
    font-size: 1.1rem;
    margin-bottom: 5px;
    color: #1a6dcc;
}

.institution-address, .institution-ytjg {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 5px;
    display: flex;
    align-items: flex-start;
    gap: 5px;
}

.institution-phone {
    font-size: 0.9rem;
    color: #e74c3c;
    display: flex;
    align-items: center;
    gap: 5px;
}

.institution-type {
    display: inline-block;
    padding: 3px 8px;
    background-color: #e1f0ff;
    color: #1a6dcc;
    border-radius: 4px;
    font-size: 0.8rem;
    margin-top: 8px;
}

.info-card {
    display: none;
    position: absolute;
    top: 20px;
    right: 20px;
    width: 320px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    overflow: hidden;
}

.card-header {
    background: linear-gradient(135deg, #1a6dcc 0%, #0d4a9e 100%);
    color: white;
    padding: 20px;
    position: relative;
}

.close-card {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(255, 255, 255, 0.2);
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
}

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

.card-body {
    padding: 20px;
}

.card-body p {
    margin-bottom: 12px;
    display: flex;
    align-items: flex-start;
}

.card-body i {
    min-width: 20px;
    color: #1a6dcc;
    margin-right: 10px;
    margin-top: 3px;
}

.navigate-btn {
    display: block;
    width: 100%;
    padding: 12px;
    background: #1a6dcc;
    color: white;
    text-align: center;
    border-radius: 5px;
    font-weight: bold;
    margin-top: 15px;
    text-decoration: none;
    transition: all 0.3s;
}

.navigate-btn:hover {
    background: #0d4a9e;
    transform: translateY(-2px);
}

.toggle-sidebar {
    position: absolute;
    top: 15px;
    left: 15px;
    background: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    z-index: 200;
    display: none;
}

.map-title {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.9);
    padding: 8px 20px;
    border-radius: 30px;
    font-weight: bold;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 100;
}

@media (max-width: 992px) {
    .sidebar {
        position: absolute;
        left: -350px;
        z-index: 200;
        height: 100%;
    }

    .sidebar.active {
        left: 0;
    }

    .toggle-sidebar {
        display: flex;
    }

    .header-content {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
}

@media (max-width: 576px) {
    .stats {
        grid-template-columns: 1fr;
    }

    .info-card {
        width: calc(100% - 40px);
    }

    h1 {
        font-size: 1.5rem;
    }
}

.bubble {
    position: absolute;
    background: rgba(26, 109, 204, 0.85);
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 14px;
    max-width: 200px;
    text-align: center;
    pointer-events: none;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s;
    z-index: 10;
}