/* ========== 完全复用DNS说明书的全局样式 ========== */
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
        }

        body {
            background-color: #f5f7fa;
            padding: 0;
            min-width: 1200px; /* 电脑端最小宽度 */
        }

        /* ========== 完全复用DNS说明书的导航栏样式 ========== */
        .navbar {
            background-color: #28a745; /* DNS文档的绿色导航栏 */
            color: #fff;
            padding: 15px 20px;
            box-shadow: 0 2px 8px rgba(0,0,0,0.1);
            position: sticky;
            top: 0;
            z-index: 999;
        }
        .navbar-container {
            max-width: 1920px;
            margin: 0 auto;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }
        .navbar-logo {
            font-size: 20px; /* DNS文档的logo字体大小 */
            font-weight: 700;
        }
        .navbar-menu {
            display: flex;
            gap: 30px; /* DNS文档的菜单间距 */
        }
        .navbar-menu a {
            color: #fff;
            text-decoration: none;
            font-size: 14px; /* DNS文档的菜单字体大小 */
            transition: opacity 0.3s;
        }
        .navbar-menu a:hover {
            opacity: 0.8;
            text-decoration: underline;
        }

        /* ========== 完全复用DNS说明书的页脚样式 ========== */
        .footer {
            background-color: #333; /* DNS文档的黑色页脚 */
            color: #ccc;
            padding: 20px 15px;
            margin-top: 40px;
        }
        .footer-container {
            max-width: 1920px;
            margin: 0 auto;
        }
        .footer-copyright {
            text-align: center;
            font-size: 12px; /* DNS文档的页脚字体大小 */
            color: #999;
            line-height: 1.6;
        }

        /* ========== IP查询页面容器样式（适配DNS风格） ========== */
        .page-container {
            width: 98%;
            max-width: 1920px;
            margin: 0 auto;
            padding: 0 15px;
        }
        .container-inner {
            background: #fff;
            border-radius: 12px; /* 匹配DNS文档的容器圆角 */
            box-shadow: 0 2px 15px rgba(0,0,0,0.05);
            padding: 30px;
            margin-top: 20px;
            margin-bottom: 20px;
        }

        /* ========== 模块样式（适配DNS风格） ========== */
        .module {
            background: #fff;
            padding: 25px; /* 匹配DNS文档的内边距 */
            border-radius: 8px; /* 匹配DNS文档的模块圆角 */
            box-shadow: 0 2px 10px rgba(0,0,0,0.05);
            margin-bottom: 25px; /* 匹配DNS文档的模块间距 */
        }
        .title-btn-container {
            display: flex;
            align-items: center;
            flex-wrap: wrap;
            gap: 15px;
            margin-bottom: 20px;
        }
        .title-btn-container h2 {
            margin: 0;
            color: #2c3e50;
            font-size: 20px; /* 匹配DNS文档的标题字体大小 */
            padding-left: 10px;
            border-left: 4px solid #28a745; /* 匹配DNS文档的绿色主题 */
        }
        .api-doc-btn {
            display: inline-block;
            padding: 10px 20px; /* 匹配DNS文档的按钮内边距 */
            background: #28a745; /* 匹配DNS文档的绿色主题 */
            color: #fff;
            text-decoration: none;
            border-radius: 4px; /* 匹配DNS文档的按钮圆角 */
            font-size: 14px; /* 匹配DNS文档的按钮字体大小 */
            transition: background-color 0.2s;
        }
        .api-doc-btn:hover {
            background: #218838; /* 匹配DNS文档的按钮hover色 */
        }

        /* ========== 表单样式（适配DNS风格） ========== */
        .search-box {
            margin: 20px 0;
        }
        .form-group {
            margin-bottom: 15px;
        }
        .form-group label {
            display: block;
            margin-bottom: 5px;
            color: #2c3e50;
            font-weight: 600;
            font-size: 14px;
        }
        .form-control {
            width: 100%;
            padding: 10px 15px; /* 匹配DNS文档的输入框内边距 */
            border: 1px solid #e5e9f0; /* 匹配DNS文档的输入框边框 */
            border-radius: 4px;
            font-size: 14px;
            color: #333;
        }
        .form-control:focus {
            outline: none;
            border-color: #28a745; /* 匹配DNS文档的输入框聚焦色 */
            box-shadow: 0 0 0 2px rgba(40, 167, 69, 0.2);
        }
        .btn {
            display: inline-block;
            padding: 10px 20px; /* 匹配DNS文档的按钮内边距 */
            background-color: #28a745; /* 匹配DNS文档的绿色主题 */
            color: #fff;
            border: none;
            border-radius: 4px;
            font-size: 14px;
            cursor: pointer;
            transition: background-color 0.2s;
            -webkit-tap-highlight-color: transparent;
            touch-action: manipulation;
        }
        .btn:hover {
            background-color: #218838; /* 匹配DNS文档的按钮hover色 */
        }

        /* ========== 提示信息样式（适配DNS风格） ========== */
        .result-area {
            margin-top: 25px;
        }
        .result-area h3 {
            font-size: 16px;
            color: #28a745; /* 匹配DNS文档的绿色主题 */
            margin-bottom: 15px;
            font-weight: 600;
        }
        .ip-card {
            background: #f8f9fa; /* 匹配DNS文档的浅色背景 */
            padding: 20px;
            border-radius: 8px;
            border: 1px solid #e5e9f0;
        }
        .ip-address {
            font-size: 1.2rem;
            font-weight: 600;
            margin-bottom: 20px;
            color: #2c3e50;
        }
        .info-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
            gap: 15px;
            margin-top: 20px;
        }
        .info-item {
            padding: 10px;
            background: #fff;
            border-radius: 6px;
            border: 1px solid #e5e9f0;
        }
        .info-label {
            font-weight: 600;
            color: #2c3e50;
            margin-right: 5px;
        }
        .info-value {
            color: #555;
        }

        /* ========== 历史记录样式（关键修改：适配目标样式） ========== */
        .history-display-area {
            background: #f8f9fa; /* 匹配DNS文档的浅色背景 */
            padding: 20px;
            border-radius: 8px;
            border: 1px solid #e5e9f0;
        }
        .history-title {
            font-size: 15px;
            font-weight: 600;
            color: #333;
            margin-bottom: 10px;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }
        .history-items {
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
            max-height: 150px; /* 电脑端固定高度 */
            overflow-y: auto;   /* 电脑端垂直滚动 */
            padding-right: 5px; /* 电脑端滚动条内边距 */
        }
        .history-item {
            padding: 6px 12px;
            background: #fff;
            border: 1px solid #ddd;
            border-radius: 4px;
            font-size: 13px;
            color: #333;
            cursor: pointer;
            transition: all 0.2s;
            white-space: nowrap;
        }
        .history-item:hover {
            background: #e8f4f8;
            border-color: #28a745;
            color: #28a745;
        }
        .history-ip {
            font-weight: 600;
            color: #28a745; /* 匹配DNS文档的绿色主题 */
        }
        .history-location {
            color: #666;
            margin-left: 5px;
        }
        .history-empty {
            color: #999;
            font-size: 13px;
            padding: 10px 0;
        }

        /* ========== 响应式适配（关键修改：手机端历史记录固定高度+滚动） ========== */
        @media only screen and (max-width: 767px) {
            body {
                min-width: unset;
                width: 100%;
                overflow-x: hidden;
            }
            .page-container {
                width: 100%;
                padding: 0 10px;
            }
            .container-inner {
                padding: 15px;
                margin: 10px auto;
                border-radius: 8px;
            }
            .navbar {
                padding: 10px 15px;
            }
            .navbar-container {
                flex-direction: column;
                gap: 10px;
                align-items: flex-start;
            }
            .navbar-menu {
                gap: 10px;
                flex-wrap: wrap;
                width: 100%;
            }
            .navbar-menu a {
                font-size: 12px;
            }
            .module {
                padding: 15px;
                margin-bottom: 15px;
            }
            .title-btn-container {
                flex-direction: column;
                align-items: flex-start;
                gap: 10px;
            }
            .info-grid {
                grid-template-columns: 1fr;
            }
            .btn {
                width: 100%;
                padding: 12px 20px;
                font-size: 15px;
            }
            
            /* ========== 核心修改：手机端历史记录样式 ========== */
            .history-items {
                display: flex;
                flex-wrap: wrap;
                gap: 8px;
                max-height: 150px; /* 固定高度 */
                overflow-y: auto;   /* 垂直滚动 */
                padding-right: 5px; /* 滚动条内边距 */
                flex-direction: row; /* 保持横向排列 */
            }
            .history-item {
                padding: 6px 12px;
                background: #fff;
                border: 1px solid #ddd;
                border-radius: 4px;
                font-size: 13px;
                color: #333;
                cursor: pointer;
                transition: all 0.2s;
                white-space: nowrap;
            }
        }
                /* 核心样式：左右等高布局 */
        .equal-height-container {
            display: flex;
            flex-wrap: wrap;
            gap: 20px;
            margin: 20px 0;
        }
        .equal-height-item {
            flex: 1;
            min-width: 300px;
            display: flex;
            flex-direction: column;
        }
        /* IP信息网格样式 */
        .info-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
            gap: 12px;
            margin-top: 10px;
            flex: 1; /* 占满父容器高度 */
        }
        .info-item {
            padding: 10px 14px;
            background: #f8fafc;
            border-radius: 6px;
            font-size: 14px;
        }
        .info-label {
            color: #64748b;
            margin-right: 8px;
        }
        .info-value {
            color: #1e293b;
            font-weight: 500;
        }
        /* 地图样式：完全等高 */
        .map-container {
            flex: 1; /* 占满父容器高度，和左侧信息区域等高 */
            display: flex;
            flex-direction: column;
        }
        .map-img {
            width: 100%;
            height: 100%; /* 高度100%，和左侧等高 */
            object-fit: cover; /* 保持比例，不拉伸变形 */
            border-radius: 8px;
            border: 1px solid #eee;
        }
        .map-tip {
            margin: 0 0 8px; 
            font-size: 14px; 
            color: #333; 
            font-weight: 500;
        }
        .map-error {
            color: #999;
            font-size: 12px;
            text-align: center;
            padding: 10px;
            background: #f8f8f8;
            border-radius: 8px;
            margin-top: 8px;
            flex: 1;
            display: flex;
            align-items: center;
            justify-content: center;
        }
        /* 响应式适配 */
        @media (max-width: 768px) {
            .info-grid {
                grid-template-columns: 1fr;
            }
            .map-img {
                height: 300px; /* 手机端固定高度，避免太矮 */
            }
        }