/* 全局样式 - 沿用Ping检测系统样式 */
* {
    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; /* 电脑端最小宽度 */
}

/* 导航栏样式 - 完全保留 */
.navbar {
    background-color: #28a745;
    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;
    font-weight: 700;
}
.navbar-menu {
    display: flex;
    gap: 30px;
}
.navbar-menu a {
    color: #fff;
    text-decoration: none;
    font-size: 14px;
    transition: opacity 0.3s;
}
.navbar-menu a:hover {
    opacity: 0.8;
    text-decoration: underline;
}

/* 页脚样式 - 完全保留 */
.footer {
    background-color: #333;
    color: #ccc;
    padding: 20px 15px;
    margin-top: 40px;
}
.footer-copyright {
    text-align: center;
    font-size: 12px;
    color: #999;
    line-height: 1.6;
}

/* 容器样式 - 完全保留并适配内容 */
.container {
    width: 98%;
    max-width: 1920px;
    margin: 0 auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.05);
    padding: 30px;
    margin-top: 20px;
    margin-bottom: 20px;
}

/* ========== DNS文档专用样式（适配原有体系） ========== */
/* 页面标题 */
.doc-header {
    text-align: center;
    padding: 20px 0;
    border-bottom: 1px solid #e5e9f0;
    margin-bottom: 30px;
}
.doc-header h1 {
    font-size: 28px;
    color: #2c3e50;
    margin-bottom: 10px;
}
.doc-header p {
    color: #666;
    font-size: 16px;
}

/* 文档章节样式 */
.doc-section {
    margin-bottom: 25px;
    padding: 25px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
.doc-section h2 {
    font-size: 20px;
    color: #2c3e50;
    margin-bottom: 15px;
    padding-left: 10px;
    border-left: 4px solid #28a745; /* 适配原有绿色主题 */
}
.doc-section h3 {
    font-size: 16px;
    color: #28a745; /* 适配原有绿色主题 */
    margin: 10px 0;
}
.doc-section p {
    margin-bottom: 10px;
    color: #555;
    line-height: 1.6;
}

/* 表格样式 */
.table-box {
    overflow-x: auto;
    margin: 15px 0;
}
table {
    width: 100%;
    border-collapse: collapse;
    border: 1px solid #e5e9f0;
}
table th, table td {
    padding: 12px 15px;
    text-align: left;
    border: 1px solid #e5e9f0;
}
table th {
    background-color: #f8f9fa;
    color: #2c3e50;
    font-weight: 600;
}
table td {
    color: #555;
}

/* 代码块样式 */
.code-box {
    background-color: #f8f9fa;
    border-radius: 6px;
    padding: 15px;
    margin: 15px 0;
    font-family: "Consolas", "Monaco", monospace;
    font-size: 14px;
    overflow-x: auto;
    border: 1px solid #e5e9f0;
}
.code-box pre {
    white-space: pre-wrap;
    word-wrap: break-word;
    line-height: 1.5;
}
.code-title {
    font-size: 14px;
    color: #28a745; /* 适配原有绿色主题 */
    margin-bottom: 5px;
    font-weight: 600;
}

/* 提示框样式 */
.note {
    background-color: #f0f8ff;
    border-left: 4px solid #28a745; /* 适配原有绿色主题 */
    padding: 10px 15px;
    margin: 15px 0;
    color: #666;
    line-height: 1.6;
}

/* 表单控件样式 */
.form-group {
    margin-bottom: 15px;
}
.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #2c3e50;
    font-weight: 600;
}
.form-control {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #e5e9f0;
    border-radius: 4px;
    font-size: 14px;
    color: #333;
}
.form-control:focus {
    outline: none;
    border-color: #28a745; /* 适配原有绿色主题 */
    box-shadow: 0 0 0 2px rgba(40, 167, 69, 0.2);
}

/* 按钮样式 - 增强移动端点击 */
.btn {
    display: inline-block;
    padding: 10px 20px;
    background-color: #28a745; /* 适配原有绿色主题 */
    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;
    position: relative;
    z-index: 1;
}
.btn:hover {
    background-color: #218838; /* 适配原有绿色主题 */
}
.btn-reset {
    background-color: #6c757d;
    margin-left: 10px;
}
.btn-reset:hover {
    background-color: #5c636a;
}

/* 调试结果样式 */
.debug-result {
    margin-top: 20px;
    border: 1px solid #e5e9f0;
    border-radius: 6px;
    overflow: hidden;
}
.result-header {
    padding: 10px 15px;
    background-color: #f8f9fa;
    border-bottom: 1px solid #e5e9f0;
    font-weight: 600;
    color: #2c3e50;
}
.result-body {
    padding: 15px;
    max-height: 500px;
    overflow-y: auto;
    background-color: #fff;
}
.loading {
    text-align: center;
    padding: 20px;
    color: #28a745; /* 适配原有绿色主题 */
}

/* 状态监控卡片样式 */
.status-card {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin: 15px 0;
}
.status-item {
    flex: 1;
    min-width: 200px;
    padding: 15px;
    border-radius: 6px;
    background-color: #f8f9fa;
    border-left: 4px solid #28a745; /* 适配原有绿色主题 */
}
.status-item.success {
    border-left-color: #67c23a;
}
.status-item.error {
    border-left-color: #f56c6c;
}
.status-item .title {
    font-size: 14px;
    color: #666;
    margin-bottom: 5px;
}
.status-item .value {
    font-size: 20px;
    font-weight: 600;
    color: #2c3e50;
}
.status-item.success .value {
    color: #67c23a;
}
.status-item.error .value {
    color: #f56c6c;
}
.status-time {
    font-size: 12px;
    color: #999;
    margin-top: 5px;
}

/* 列表样式 */
.doc-section ul {
    padding-left: 20px;
    color: #555;
    margin-bottom: 10px;
    line-height: 1.6;
}
.doc-section li {
    margin-bottom: 8px;
}

/* ============ 手机端自适应样式 (768px以下) ============ */
@media only screen and (max-width: 767px) {
    /* 基础样式重置 */
    body {
        min-width: unset;
        width: 100%;
        overflow-x: hidden;
    }

    /* 容器适配 */
    .container {
        width: 100%;
        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;
    }

    /* 文档样式适配 */
    .doc-header h1 {
        font-size: 22px;
    }
    .doc-header p {
        font-size: 14px;
    }
    .doc-section {
        padding: 15px;
        margin-bottom: 15px;
    }
    .doc-section h2 {
        font-size: 18px;
    }
    .doc-section h3 {
        font-size: 15px;
    }
    .doc-section p {
        font-size: 14px;
    }

    /* 表格适配 */
    table th, table td {
        padding: 8px 10px;
        font-size: 13px;
    }

    /* 代码块适配 */
    .code-box {
        padding: 10px;
        font-size: 13px;
    }

    /* 状态卡片适配 */
    .status-card {
        flex-direction: column;
        gap: 10px;
    }
    .status-item {
        min-width: unset;
        padding: 10px;
    }
    .status-item .value {
        font-size: 18px;
    }

    /* 表单适配 */
    .form-control {
        padding: 8px 12px;
        font-size: 13px;
    }
    .btn {
        padding: 12px 20px;
        font-size: 15px;
        width: 100%;
        margin-bottom: 10px;
        display: block;
    }
    .btn-reset {
        margin-left: 0;
    }
}