/* ============================================================
   P19 · 微信生态页面样式(仅本批使用,不改 app.css)
   设计令牌沿用 app.css:主色 #2563eb、圆角 8/12px、灰阶 #f5f6f8 / #e5e7eb / #4b5563
   ============================================================ */

/* 顶部子页签 */
.p19-tabs {
    display: flex;
    gap: 4px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 6px;
    margin-bottom: 14px;
    overflow-x: auto;
}

.p19-tab {
    flex: 0 0 auto;
    padding: 8px 16px;
    border-radius: 8px;
    color: #4b5563;
    text-decoration: none;
    font-size: 14px;
    white-space: nowrap;
}

.p19-tab:hover { background: #f3f4f6; color: #1f2937; }

.p19-tab.on {
    background: #2563eb;
    color: #fff;
}

/* 表单行 */
.p19-row { align-items: flex-start; }

.p19-field { flex: 1; min-width: 0; }

.p19-field input[type="text"],
.p19-field input[type="password"],
.p19-field textarea {
    width: 100%;
    box-sizing: border-box;
}

/* 密钥字段:输入框 + 查看按钮 */
.p19-secret {
    display: flex;
    gap: 8px;
    align-items: center;
}

.p19-secret input { flex: 1; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }

/* 开关 / 单选 */
.p19-switch { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }

.p19-radios { display: flex; flex-wrap: wrap; gap: 14px; }

.p19-radios label { display: inline-flex; align-items: center; gap: 5px; cursor: pointer; color: #374151; }

/* 操作按钮区 */
.p19-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }

/* 回调地址展示 */
.p19-url { display: flex; flex-direction: column; gap: 10px; margin-bottom: 8px; }

.p19-url > div { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }

.p19-url label { color: #6b7280; font-size: 13px; min-width: 140px; }

.p19-url code {
    background: #f3f4f6;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 4px 8px;
    font-size: 12.5px;
    color: #1f2937;
    word-break: break-all;
}

/* 密钥明文 / JSON 展示块 */
.p19-plain {
    background: #0f172a;
    color: #e2e8f0;
    border-radius: 8px;
    padding: 12px;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12.5px;
    line-height: 1.7;
    word-break: break-all;
    white-space: pre-wrap;
    max-height: 320px;
    overflow: auto;
    margin: 6px 0 12px;
}

/* 键值表(详情弹窗) */
.p19-kv { width: 100%; border-collapse: collapse; font-size: 13px; }

.p19-kv th {
    text-align: left;
    width: 150px;
    padding: 8px 10px;
    color: #6b7280;
    font-weight: 500;
    background: #fafafa;
    border-bottom: 1px solid #f1f2f4;
    vertical-align: top;
}

.p19-kv td {
    padding: 8px 10px;
    color: #1f2937;
    border-bottom: 1px solid #f1f2f4;
    word-break: break-all;
}

/* 弹窗里的 JSON 文本域 */
.p19-modal-json {
    width: 100%;
    box-sizing: border-box;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12.5px;
    line-height: 1.6;
}

/* 窄屏 */
@media (max-width: 720px) {
    .p19-url label { min-width: auto; }
    .p19-kv th { width: 96px; }
    .p19-tabs { padding: 4px; }
    .p19-tab { padding: 7px 12px; font-size: 13px; }
}

/* 平台统一配置提示块(SaaS:第三方平台凭据由总后台维护,商户无需填写) */
.p19-notice {
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    border-radius: 8px;
    padding: 12px 14px;
    margin-bottom: 12px;
    color: #0c4a6e;
    font-size: 13px;
    line-height: 1.7;
}
.p19-notice b { color: #075985; }
.p19-notice .hint { color: #0c4a6e; opacity: .85; }
.p19-notice .btn { margin-top: 8px; }
