/* ip111 —— 复刻 Bootstrap 4 card-deck 风格的精简样式表（无外部依赖，可离线运行） */

:root {
    --border: rgba(0, 0, 0, .125);
    --header-bg: rgba(0, 0, 0, .03);
    --shadow: 0 .125rem .25rem rgba(0, 0, 0, .075);
    --text: #212529;
    --muted: #6c757d;
    --blue: #007bff;
    --radius: .25rem;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
    background: #fff;
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
        "Helvetica Neue", Arial, "PingFang SC", "Hiragino Sans GB",
        "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
    font-size: 16px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

.container {
    width: 100%;
    max-width: 1140px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 15px;
    padding-right: 15px;
}

/* ---------- 顶部标题栏 ---------- */
.site-header {
    background: #fff;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow);
}
.site-header .container {
    display: flex;
    align-items: center;
    min-height: 58px;
}
.site-header h5 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 500;
    letter-spacing: .01em;
}
.site-header .header-right {
    margin-left: auto;
    font-size: .82rem;
    color: var(--muted);
}

/* ---------- 标题区留白 ---------- */
.pricing-header {
    padding: 3rem 1rem 2.25rem;
    text-align: center;
}
.pricing-header .tagline {
    margin: 0 auto;
    max-width: 42rem;
    font-size: .9rem;
    color: #8a9199;
    letter-spacing: .04em;
    overflow-wrap: anywhere;
}
.sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* ---------- 三栏卡片 ---------- */
.card-deck {
    display: flex;
    flex-flow: row wrap;
    gap: 1.875rem;
    margin-bottom: 1.75rem;
}
.card {
    position: relative;
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    transition: box-shadow .2s ease, transform .2s ease;
}
.card:hover {
    box-shadow: 0 .35rem .75rem rgba(0, 0, 0, .10);
    transform: translateY(-2px);
}
.card-header {
    padding: .75rem 1.25rem;
    background: var(--header-bg);
    border-bottom: 1px solid var(--border);
    border-top-left-radius: var(--radius);
    border-top-right-radius: var(--radius);
    text-align: center;
    font-size: 1rem;
    font-weight: 400;
    color: #343a40;
}
.card-body {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 165px;
    padding: 1.25rem;
    text-align: center;
}

/* IP 展示 */
.ip-result { width: 100%; }
.ip-value {
    font-size: 1.1rem;
    line-height: 1.5;
    color: var(--text);
    letter-spacing: .02em;
    cursor: pointer;
    display: inline-block;
    border-bottom: 1px dashed transparent;
    transition: border-color .15s, color .15s;
}
.ip-value:hover { border-bottom-color: var(--blue); color: var(--blue); }
.ip-location { font-size: 1rem; line-height: 1.5; color: #444; }
.ip-isp { font-size: .78rem; color: #9aa0a6; margin-top: .15rem; }

/* iframe 节点 */
.iframe-wrap {
    position: relative;
    width: 100%;
    min-height: 54px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.iframe-wrap iframe {
    width: 100%;
    height: 54px;
    border: 0;
    display: block;
    background: transparent;
}
.node-fallback {
    display: none;
    font-size: .85rem;
    color: #b02a37;
    line-height: 1.4;
    padding: .25rem 0;
}
.card.node-unreachable .iframe-wrap iframe { display: none; }
.card.node-unreachable .node-fallback { display: block; }

.card-hint {
    margin: auto 0 0;
    padding-top: 1rem;
    font-size: .9rem;
    color: #55595c;
    line-height: 1.5;
}
.card-note {
    margin-top: .65rem;
    font-size: .72rem;
    color: #adb5bd;
    letter-spacing: .02em;
}
.copy-toast {
    position: absolute;
    top: .4rem;
    right: .6rem;
    font-size: .72rem;
    color: #198754;
    opacity: 0;
    transition: opacity .25s;
    pointer-events: none;
}
.copy-toast.show { opacity: 1; }

/* ---------- 检测结论 ---------- */
.result-panel {
    display: flex;
    align-items: flex-start;
    gap: .65rem;
    margin: 0 0 1.25rem;
    padding: .85rem 1.1rem;
    background: #f1f6fd;
    border: 1px solid #d8e6fa;
    border-left: 3px solid var(--blue);
    border-radius: var(--radius);
    font-size: .9rem;
    line-height: 1.65;
    color: #344054;
}
.result-panel .icon { flex: 0 0 auto; font-size: 1rem; line-height: 1.5; }
.result-panel strong { font-weight: 600; }
.result-panel .detail { display: block; margin-top: .25rem; font-size: .82rem; color: var(--muted); }

/* ---------- 演示模式提示 ---------- */
.demo-notice {
    margin-bottom: 1.5rem;
    padding: .7rem 1rem;
    background: #fffaf0;
    border: 1px solid #f5e3b3;
    border-radius: var(--radius);
    font-size: .82rem;
    color: #876a22;
    line-height: 1.6;
}
.demo-notice b { font-weight: 600; }

/* ---------- 折叠工具区 ---------- */
.tools { margin-bottom: 1.75rem; }
.tools details {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: .65rem 1rem;
}
.tools summary {
    cursor: pointer;
    font-size: .88rem;
    color: var(--muted);
    outline: none;
}
.tools summary:hover { color: var(--blue); }
.tools .tools-inner { padding-top: .9rem; }
.query-form { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: .75rem; }
.query-form input {
    flex: 1 1 240px;
    min-width: 0;
    padding: .45rem .7rem;
    font-size: .9rem;
    border: 1px solid #ced4da;
    border-radius: var(--radius);
    outline: none;
}
.query-form input:focus { border-color: #80bdff; box-shadow: 0 0 0 .15rem rgba(0,123,255,.2); }
.query-form button {
    padding: .45rem 1.1rem;
    font-size: .9rem;
    color: #fff;
    background: var(--blue);
    border: 1px solid var(--blue);
    border-radius: var(--radius);
    cursor: pointer;
}
.query-form button:hover { background: #0069d9; }
.query-result {
    margin: 0 0 .75rem;
    padding: .7rem .9rem;
    background: #f8f9fa;
    border-radius: var(--radius);
    font-size: .88rem;
    line-height: 1.7;
}
.query-result .k { color: var(--muted); display: inline-block; min-width: 5.2rem; }
.tools .api-links { margin: 0; font-size: .82rem; color: var(--muted); }
.tools .api-links a { color: var(--blue); text-decoration: none; }
.tools .api-links a:hover { text-decoration: underline; }

/* ---------- 页脚 ---------- */
.site-footer {
    padding: .5rem 0 3rem;
    text-align: center;
    font-size: .85rem;
    color: #4a4f55;
    line-height: 1.9;
}
.site-footer p { margin: 0; }
.site-footer a { color: var(--blue); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }

/* ---------- 响应式 ---------- */
@media (max-width: 768px) {
    .card-deck { flex-direction: column; gap: 1rem; }
    .card-body { min-height: 140px; }
    .pricing-header { padding: 2rem 1rem 1.5rem; }
    .site-header .header-right { display: none; }
    .result-panel { font-size: .85rem; }
    .pricing-header { padding: 1.75rem 1rem 1.25rem; }
    .pricing-header .tagline { display: none; }
}
