/* 语义网络注册中心共享样式 */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: 'PingFang SC', 'Microsoft YaHei', sans-serif;
    background: linear-gradient(135deg, #eef6f2 0%, #f6f7f4 100%);
    color: #1f2937;
    min-height: 100vh;
    padding-bottom: 4rem;
}
.topnav {
    background: #ffffff;
    color: #1f2937;
    border-bottom: 1px solid #e7ebe9;
    display: flex;
    align-items: center;
    gap: 1.2rem;
    padding: 0.7rem 1.6rem;
    flex-wrap: wrap;
    position: sticky;
    top: 0;
    z-index: 50;
}
.topnav .brand {
    font-size: 1.05rem;
    font-weight: 700;
    color: #0f172a;
    text-decoration: none;
    letter-spacing: 0.02em;
}
.topnav .links { display: flex; gap: 0.9rem; flex-wrap: wrap; margin-left: 0.6rem; }
.topnav a { color: #5b6b7c; text-decoration: none; font-size: 0.9rem; }
.topnav a:hover { color: #0e9f6e; }
.topnav .spacer { flex: 1; }
.topnav .who { color: #0e9f6e; font-size: 0.86rem; }
.topnav a.btn-like {
    background: #0e9f6e; color: #fff; padding: 0.3rem 0.9rem; border-radius: 8px;
}
main.container { max-width: 1500px; margin: 1.3rem auto 0; padding: 0 1.2rem; display: grid; gap: 1.2rem; }
/* 详情页双栏：主内容 + 右侧栏（次要清单，收窄让主内容占大头） */
.layout { display: grid; grid-template-columns: minmax(0, 1fr) 210px; gap: 1.2rem; align-items: start; }
.layout .maincol { display: grid; gap: 1.2rem; min-width: 0; }
aside.sidebar { display: grid; gap: 1.2rem; position: sticky; top: 1rem; }
@media (max-width: 1000px) { .layout { grid-template-columns: 1fr; } aside.sidebar { position: static; } }
section.card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(17, 24, 39, 0.07);
    padding: 1.2rem 1.4rem;
}
section.card > h2 {
    font-size: 1.08rem;
    color: #111827;
    border-left: 4px solid #0e9f6e;
    padding-left: 0.6rem;
    margin-bottom: 0.9rem;
}
section.card > h2 .hint { font-size: 0.8rem; color: #94a3b8; font-weight: normal; margin-left: 0.5rem; }
table { width: 100%; border-collapse: collapse; font-size: 0.86rem; }
th, td { padding: 0.5rem 0.6rem; border-bottom: 1px solid #f0f2f1; text-align: left; vertical-align: top; }
th { color: #64748b; font-weight: 600; white-space: nowrap; }
tr:hover td { background: #f7faf8; }
a.netlink { color: #047857; text-decoration: none; font-weight: 600; }
a.netlink:hover { text-decoration: underline; }
.tag {
    display: inline-block; padding: 0.08rem 0.5rem; border-radius: 999px;
    font-size: 0.76rem; margin-right: 0.3rem; white-space: nowrap;
}
.tag.net { background: #e7f6ef; color: #047857; }
.tag.provider { background: #fdf0e0; color: #b06a00; }
.tag.method { background: #e8f8ee; color: #1c7c3c; }
.tag.ver { background: #f0e8ff; color: #6b3fa0; }
.tag.ok { background: #e8f8ee; color: #1c7c3c; }
.tag.err { background: #fdeaea; color: #c03030; }
pre.snl {
    background: #1f2430; color: #e2e8f0; padding: 0.8rem; border-radius: 8px;
    font-size: 0.78rem; line-height: 1.5; overflow: auto; max-height: 300px;
    white-space: pre-wrap; word-break: break-all;
}
label { display: block; font-size: 0.82rem; color: #64748b; margin: 0.5rem 0 0.25rem; }
input, select, textarea {
    width: 100%; padding: 0.45rem 0.6rem; border: 1px solid #d1d5db; border-radius: 8px;
    font-size: 0.86rem; font-family: inherit; background: #fcfcfd;
}
textarea { min-height: 130px; font-family: Consolas, monospace; line-height: 1.45; }
button {
    padding: 0.5rem 1.3rem; border: none; border-radius: 8px; cursor: pointer;
    background: #0e9f6e; color: #fff; font-size: 0.88rem; margin-top: 0.7rem;
}
button:hover { background: #0b8a5c; }
button.ghost { background: #f0f2f1; color: #0e9f6e; padding: 0.25rem 0.7rem; margin-top: 0; font-size: 0.78rem; }
button.ghost:hover { background: #e2e8e4; }
button.danger { background: #fdeaea; color: #b03030; padding: 0.25rem 0.7rem; margin-top: 0; font-size: 0.78rem; }
.grid2 { display: grid; grid-template-columns: 5fr 4fr; gap: 1.4rem; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.grid4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.7rem; }
@media (max-width: 860px) { .grid2, .grid3, .grid4 { grid-template-columns: 1fr; } }
.msg { padding: 0.6rem 0.9rem; border-radius: 8px; font-size: 0.84rem; margin-top: 0.6rem; display: none; }
.msg.ok { background: #e8f8ee; color: #1c7c3c; display: block; }
.msg.err { background: #fdeaea; color: #b03030; display: block; }
.chain-line {
    font-family: Consolas, monospace; font-size: 0.8rem; color: #047857;
    background: #f0faf4; padding: 0.3rem 0.6rem; border-radius: 6px; margin: 0.3rem 0;
}
.muted { color: #94a3b8; font-size: 0.8rem; }
.kv { font-size: 0.85rem; color: #475569; }
.kv b { color: #111827; }
.tabs { display: flex; gap: 0.6rem; margin-bottom: 0.9rem; }
.tabs button.on { background: #1f2937; }
.netcard {
    border: 1px solid #e5e7eb; border-radius: 10px; padding: 0.9rem 1rem; background: #fcfcfd;
}
.netcard h3 { font-size: 0.98rem; margin-bottom: 0.3rem; }
.netcard p { font-size: 0.84rem; color: #64748b; margin-bottom: 0.4rem; }
.hop-flow { display: flex; flex-wrap: wrap; align-items: center; gap: 0.35rem; margin: 0.4rem 0; }
.hop-node { background: #e7f6ef; color: #047857; padding: 0.25rem 0.7rem; border-radius: 8px; font-weight: 600; }
.hop-arrow { color: #94a3b8; }
.hop-method { background: #e8f8ee; color: #1c7c3c; padding: 0.15rem 0.55rem; border-radius: 999px; font-size: 0.78rem; }
details summary { cursor: pointer; color: #0e9f6e; font-size: 0.82rem; margin-top: 0.4rem; }
code.curl {
    display: block; background: #1f2430; color: #9fe3b0; padding: 0.6rem 0.8rem; border-radius: 8px;
    font-size: 0.78rem; margin-top: 0.5rem; white-space: pre-wrap; word-break: break-all;
}

/* ============ 登录/注册：全屏大气版式 ============ */
body.auth {
    min-height: 100vh;
    display: flex; align-items: center; justify-content: center;
    padding: 2rem 1rem; padding-bottom: 2rem;
    background:
        radial-gradient(1100px 560px at 18% -12%, rgba(14, 159, 110, 0.55) 0%, transparent 62%),
        radial-gradient(900px 520px at 108% 112%, rgba(20, 130, 90, 0.4) 0%, transparent 58%),
        linear-gradient(165deg, #111827 0%, #1f2937 55%, #111827 100%);
}
.auth-deco { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
.auth-wrap { position: relative; z-index: 1; width: 100%; max-width: 440px; }
.auth-brand { text-align: center; color: #fff; margin-bottom: 1.7rem; }
.auth-brand .logo {
    width: 58px; height: 58px; border-radius: 16px; margin: 0 auto 1rem;
    background: linear-gradient(135deg, #0e9f6e, #0b8a5c);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.7rem; color: #fff; box-shadow: 0 10px 28px rgba(14, 159, 110, 0.5);
}
.auth-brand h1 { font-size: 1.5rem; font-weight: 700; letter-spacing: 0.06em; }
.auth-brand p { margin-top: 0.5rem; color: #cbd5e1; font-size: 0.88rem; letter-spacing: 0.02em; }
.auth-card {
    background: rgba(255, 255, 255, 0.98);
    border-radius: 18px; padding: 2.2rem 2.2rem 1.7rem;
    box-shadow: 0 26px 64px rgba(17, 24, 39, 0.5);
}
.auth-card h2 { font-size: 1.18rem; color: #111827; margin-bottom: 0.4rem; }
.auth-card .sub { font-size: 0.82rem; color: #94a3b8; margin-bottom: 1rem; }
.auth-card label { margin: 0.8rem 0 0.15rem; font-size: 0.84rem; }
.auth-card input {
    padding: 0.74rem 0.9rem; font-size: 0.95rem; border-radius: 10px;
    border: 1px solid #d1d5db; background: #fcfcfd;
}
.auth-card input:focus { outline: none; border-color: #0e9f6e; box-shadow: 0 0 0 3px rgba(14, 159, 110, 0.15); }
.auth-card button {
    width: 100%; padding: 0.82rem; margin-top: 1.4rem; font-size: 1rem; font-weight: 600;
    letter-spacing: 0.35em; text-indent: 0.35em; border-radius: 10px;
    background: linear-gradient(135deg, #0e9f6e, #0b8a5c);
    box-shadow: 0 8px 20px rgba(14, 159, 110, 0.4);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.auth-card button:hover { transform: translateY(-1px); box-shadow: 0 10px 26px rgba(14, 159, 110, 0.5); }
.auth-hint {
    margin-top: 1.1rem; padding: 0.55rem 0.8rem; background: #f0faf4;
    border-radius: 8px; font-size: 0.8rem; color: #64748b; text-align: center;
}
.auth-foot { text-align: center; margin-top: 1rem; font-size: 0.85rem; color: #64748b; }
.auth-foot a { color: #047857; font-weight: 600; text-decoration: none; }
.auth-foot a:hover { text-decoration: underline; }
.auth-back { position: fixed; top: 1.2rem; left: 1.4rem; z-index: 2; color: #cbd5e1; font-size: 0.85rem; text-decoration: none; }
.auth-back:hover { color: #fff; }

/* ===== 顶栏用户下拉菜单（用户名 hover 展开） ===== */
.user-menu { position: relative; cursor: pointer; padding: 0.35rem 0.7rem; border-radius: 8px; user-select: none; }
.user-menu:hover { background: rgba(127, 127, 127, 0.08); }
.user-drop {
    display: none; position: absolute; right: 0; top: calc(100% + 0.4rem); z-index: 30;
    min-width: 9rem; background: #fff; border: 1px solid #e5e7eb; border-radius: 10px;
    box-shadow: 0 10px 28px rgba(17, 24, 39, 0.16); padding: 0.35rem; text-align: left;
}
.user-menu:hover .user-drop { display: block; }
.user-drop a {
    display: block; padding: 0.5rem 0.8rem; border-radius: 7px;
    color: #334155; text-decoration: none; font-size: 0.92rem;
}
.user-drop a:hover { background: #f0faf4; color: #047857; }
.user-drop .sep { height: 1px; background: #f0f2f1; margin: 0.3rem 0.4rem; }

/* ===== 工作台按钮体系（与导航/卡片字号协调） ===== */
.primary-btn {
    display: inline-flex; align-items: center; gap: 0.35rem;
    background: linear-gradient(135deg, #0e9f6e, #0b8a5c); color: #fff; text-decoration: none;
    font-size: 0.95rem; line-height: 1; font-family: inherit; font-weight: 600;
    padding: 0.62rem 1.15rem; border-radius: 10px; border: none; cursor: pointer;
    box-shadow: 0 4px 12px rgba(14, 159, 110, 0.32); margin: 0;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.primary-btn:hover { color: #fff; background: linear-gradient(135deg, #0b8a5c, #0b8a5c); transform: translateY(-1px); box-shadow: 0 6px 16px rgba(14, 159, 110, 0.4); }
.primary-btn.soft {
    background: #eef6f2; color: #0b8a5c; box-shadow: none; font-weight: 500;
    font-size: 0.88rem; padding: 0.5rem 1rem;
}
.primary-btn.soft:hover { background: #dcf0e6; color: #0b8a5c; box-shadow: none; }
.btn-line { display: flex; align-items: center; gap: 0.9rem; flex-wrap: wrap; margin-top: 0.8rem; }
.btn-line .muted { align-self: center; line-height: 1.5; }
details summary { font-size: 0.88rem; padding: 0.15rem 0; }
