:root {
    --brand-orange: #ff9800;
    --brand-green: #4caf50;
    --brand-blue: #2196f3;
    --text-dark: #2c3e50;
    --card-bg: #ffffff;
    --border-soft: #edf2f7;
    --primary-color: #2db92d;
    --bg-color: #f5f7f9;
    --text-main: #333;
    --text-muted: #666;
    --border-color: #eee;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
}
.navi-bar-item a:hover{
    text-decoration: none;
}

/* A-Z 侧边导航 */
.index-nav {
    position: fixed;
    right: 8px;
    top: 55%;
    transform: translateY(-50%);
    z-index: 101;
    display: flex;
    flex-direction: column;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    padding: 10px 4px;
    backdrop-filter: blur(4px);
}

.index-nav a {
    text-decoration: none;
    color: #888;
    font-size: 11px;
    font-weight: bold;
    width: 22px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    border-radius: 4px;
}

.index-nav a:hover, .index-nav a.active {
    color: #fff;
    background-color: var(--primary-color);
    text-decoration: none;
}

/* 主容器 */
.container {
    max-width: 1200px; /* PC端宽屏显示 */
    margin: 0 auto;
    padding: 20px;
}

anchor-point{
    position: relative;
    top: -80px;
    visibility: hidden;
    display: block;
    height: 0;
}

/* 品牌组样式 */
.brand-group {
    background: var(--card-bg);
    border-radius: 12px;
    margin-bottom: 20px; /* 代替了字母标题的间距 */
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.03);
    border: 1px solid #f0f0f0;
    /* 关键：设置跳转后的顶部偏移，避免被Header遮挡 */
    scroll-margin-top: 80px; /* 适用于现代浏览器 */
}

.brand-name {
    background: var(--card-bg);
    padding: 15px 25px;
    font-weight: 600;
    font-size: 18px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
}

/* 锚点定位元素 */
.anchor-point {
    position: relative;
    top: -80px;
    visibility: hidden;
    display: block;
    height: 0;
}

.brand-logo {
    width: 36px;
    height: 36px;
    margin-right: 15px;
    object-fit: contain;
    background: #f9f9f9;
    border-radius: 4px;
    padding: 2px;
}

/* 车型列表栅格 */
.model-list {
    padding: 20px 25px;
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* PC端一行4个 */
    gap: 15px 20px;
}

.model-item {
    text-decoration: none;
    color: var(--text-main);
    font-size: 15px;
    padding: 10px;
    background: #fcfdfc;
    border-radius: 8px;
    transition: all 0.2s ease;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: center;
    border: 1px solid #f0f5f0;
}

.model-item:hover {
    color: var(--primary-color);
    background: #f0fbf0;
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 2px 5px rgba(45, 185, 45, 0.1);
    text-decoration: none;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    .brand-group {
        scroll-margin-top: 170px; /* 适用于现代浏览器 */
    }
    .anchor-point {
        top: -170px;
    }
    .brand-name {
        padding: 12px 15px;
        font-size: 16px;
    }

    .model-list {
        grid-template-columns: 1fr; /* 移动端单列 */
        gap: 10px;
        padding: 15px;
    }

    .model-item {
        text-align: left;
        padding: 12px;
        font-size: 14px;
        background: transparent;
        border: none;
        border-bottom: 1px solid #f5f5f5;
        border-radius: 0;
    }

    .model-item:last-child {
        border-bottom: none;
    }

    .model-item:hover {
        transform: none;
        background: transparent;
        text-decoration: none;
    }
}

html {
    scroll-behavior: smooth;
}

@media (prefers-color-scheme: dark) {
    :root {
        /* 背景与基础色 */
        --bg-body: #12141a;       /* 极深蓝黑背景 */
        --card-bg: #1c1f26;       /* 卡片背景，比底色稍浅，增加浮现感 */
        --bg-gray: #252932;       /* 搜索框、输入框、表头等次级背景 */

        /* 文字色 */
        --text-dark: #e2e8f0;     /* 主文字：浅灰白 */
        --text-muted: #94a3b8;    /* 辅助文字：中灰蓝 */

        /* 边框与线 */
        --border-soft: #2d333f;   /* 线条：深灰色 */

        /* 品牌色在深色下的微调 */
        --brand-green: #4ade80;   /* 调亮一点的绿色，增加对比 */
        --brand-green-light: rgba(74, 222, 128, 0.15);
        --brand-blue: #60a5fa;
        --brand-orange: #fbbf24;
    }
    /* --- 2. 品牌与数据容器 (brand-group, data-card) --- */
    .brand-group, .data-card {
        background-color: var(--card-bg) !important;
        border-color: var(--border-soft) !important;
    }
    /* 针对品牌行的分割线 */
    .brand-group { border-bottom: 1px solid var(--border-soft) !important; }
    .brand-name {background: var(--card-bg)!important; border-bottom: 1px solid var(--border-soft);}
    .model-item {background: var(--card-bg)!important; color: var(--text-dark)!important; border: 1px solid var(--border-soft);}
    .model-item:hover{background: var(--brand-green-light)!important; color: var(--brand-green)!important; text-decoration: none;}
}