/* 院校位置查询系统样式表 */

/* 重置和基础样式 */
.college-map-container * {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

.college-map-container {
    min-height: 100vh;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0e7ff 100%);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
}

/* 头部样式 */
.college-map-header {
    background: #ffffff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 1rem 0;
}

.college-map-header-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1rem;
}

.college-map-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.college-map-icon {
    color: #2563eb;
    flex-shrink: 0;
}

.college-map-title-group h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #111827;
    line-height: 1.2;
}

.college-map-title-group p {
    font-size: 0.875rem;
    color: #6b7280;
    margin-top: 0.25rem;
}

/* 搜索区域样式 */
.college-map-search-section {
    max-width: 1400px;
    margin: 1.5rem auto;
    padding: 0 1rem;
}

/* 卡片通用样式 */
.college-map-card {
    background: #ffffff;
    border-radius: 0.5rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.college-map-card-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1.25rem;
    border-bottom: 1px solid #e5e7eb;
}

.college-map-card-icon {
    color: #2563eb;
    flex-shrink: 0;
}

.college-map-card-header h2 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #111827;
}

.college-map-card-content {
    padding: 1.25rem;
}

/* 搜索框样式 */
.college-map-search-box {
    display: flex;
    gap: 0.5rem;
}

.college-map-input {
    flex: 1;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.college-map-input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.college-map-button {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    border: none;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: background-color 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
}

.college-map-button-primary {
    background: #2563eb;
    color: #ffffff;
}

.college-map-button-primary:hover {
    background: #1d4ed8;
}

.college-map-button-primary:active {
    background: #1e40af;
}

.college-map-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.college-map-hint {
    font-size: 0.875rem;
    color: #6b7280;
    margin-top: 0.75rem;
}

/* 主要内容区域 */
.college-map-main {
    max-width: 1400px;
    margin: 0 auto 1.5rem;
    padding: 0 1rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 1024px) {
    .college-map-main {
        grid-template-columns: 2fr 1fr;
    }
}

.college-map-left,
.college-map-right {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* 地图容器 */
.college-map-skeleton {
    height: 500px;
    background: linear-gradient(90deg, #f3f4f6 25%, #e5e7eb 50%, #f3f4f6 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: 0.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
}

.college-map-skeleton-line {
    height: 8px;
    background: #d1d5db;
    border-radius: 4px;
    width: 60%;
}

@keyframes skeleton-loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

.college-map-container-map {
    height: 500px;
    width: 100%;
    border-radius: 0.5rem;
    background: #e5e7eb;
}

/* 院校列表 */
.college-map-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 1rem;
    gap: 1rem;
    color: #6b7280;
}

.college-map-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #e5e7eb;
    border-top-color: #2563eb;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

.college-map-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-height: 500px;
    overflow-y: auto;
}

.college-map-item {
    padding: 0.75rem;
    border-radius: 0.5rem;
    border: 1px solid #e5e7eb;
    background: #ffffff;
    cursor: pointer;
    transition: all 0.2s;
}

.college-map-item:hover {
    border-color: #3b82f6;
    background: #f0f9ff;
}

.college-map-item.active {
    background: #eff6ff;
    border-color: #2563eb;
}

.college-map-item-title {
    font-weight: 600;
    color: #111827;
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.college-map-item-info {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 0.25rem;
    line-height: 1.5;
}

/* 空状态 */
.college-map-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 1rem;
    color: #6b7280;
}

.college-map-empty-icon {
    opacity: 0.5;
    margin-bottom: 1rem;
}

.college-map-empty-sub {
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

/* 院校详情卡片 */
.college-map-detail-card {
    border: 2px solid #2563eb;
}

.college-map-detail-name {
    font-weight: 700;
    font-size: 1.125rem;
    color: #111827;
    margin-bottom: 0.75rem;
}

.college-map-detail-info {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 0.5rem;
    line-height: 1.5;
}

.college-map-button-full {
    width: 100%;
    justify-content: center;
    margin-top: 1rem;
}

.college-map-button-icon {
    flex-shrink: 0;
}

/* 页脚 */
.college-map-footer {
    background: #ffffff;
    border-top: 1px solid #e5e7eb;
    padding: 1.5rem 0;
    margin-top: 2.5rem;
}

.college-map-footer p {
    text-align: center;
    font-size: 0.875rem;
    color: #6b7280;
}

/* 暗色模式支持 */
@media (prefers-color-scheme: dark) {
    .college-map-container {
        background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
    }

    .college-map-header {
        background: #1f2937;
    }

    .college-map-brand h1 {
        color: #f9fafb;
    }

    .college-map-brand p {
        color: #9ca3af;
    }

    .college-map-card {
        background: #1f2937;
    }

    .college-map-card-header {
        border-bottom-color: #374151;
    }

    .college-map-card-header h2 {
        color: #f9fafb;
    }

    .college-map-input {
        background: #374151;
        border-color: #4b5563;
        color: #f9fafb;
    }

    .college-map-input:focus {
        border-color: #3b82f6;
    }

    .college-map-hint {
        color: #9ca3af;
    }

    .college-map-skeleton {
        background: linear-gradient(90deg, #374151 25%, #4b5563 50%, #374151 75%);
    }

    .college-map-skeleton-line {
        background: #4b5563;
    }

    .college-map-container-map {
        background: #374151;
    }

    .college-map-item {
        background: #1f2937;
        border-color: #374151;
        color: #f9fafb;
    }

    .college-map-item:hover {
        background: #1e3a5f;
        border-color: #3b82f6;
    }

    .college-map-item.active {
        background: #1e3a5f;
        border-color: #2563eb;
    }

    .college-map-item-title {
        color: #f9fafb;
    }

    .college-map-item-info {
        color: #9ca3af;
    }

    .college-map-detail-name {
        color: #f9fafb;
    }

    .college-map-detail-info {
        color: #9ca3af;
    }

    .college-map-footer {
        background: #1f2937;
        border-top-color: #374151;
    }

    .college-map-footer p {
        color: #9ca3af;
    }
}

/* 响应式优化 */
@media (max-width: 640px) {
    .college-map-header h1 {
        font-size: 1.25rem;
    }

    .college-map-search-box {
        flex-direction: column;
    }

    .college-map-button {
        width: 100%;
        justify-content: center;
    }

    .college-map-container-map {
        height: 350px;
    }

    .college-map-list {
        max-height: 350px;
    }
}
