/* ============================================================
   信玺产品管理系统 - 通用样式
   版本：1.0
   依赖：LayUI 2.13.6
   ============================================================ */

/* 全局 body 样式 */
body {
    background: #f5f7fa;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    color: #333;
    margin: 0;
    padding: 0;
}

/* 登录页容器 */
.xxh-login-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #2c3e50 0%, #4a6278 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.xxh-login-box {
    width: 420px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

.xxh-login-header {
    padding: 30px 40px 10px;
    text-align: center;
}

.xxh-login-header h1 {
    font-size: 22px;
    color: #2c3e50;
    margin: 0 0 6px;
    font-weight: 500;
}

.xxh-login-header p {
    color: #999;
    font-size: 13px;
    margin: 0;
}

.xxh-login-body {
    padding: 20px 40px 40px;
}

.xxh-login-body .layui-form-item {
    margin-bottom: 16px;
}

.xxh-login-body .layui-input {
    height: 42px;
    line-height: 42px;
    border-radius: 4px;
}

.xxh-login-captcha {
    cursor: pointer;
    border: 1px solid #e6e6e6;
    border-radius: 4px;
    height: 42px;
    width: 100%;
    display: block;
}

.xxh-login-submit {
    height: 42px !important;
    line-height: 42px !important;
    font-size: 15px !important;
    letter-spacing: 2px;
}

/* 后台主框架 */
.xxh-layout {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
}

.xxh-layout-header {
    background: #23262e;
    color: #fff;
    height: 50px;
    line-height: 50px;
    padding: 0 20px;
    position: relative;
    z-index: 1000;
}

.xxh-layout-header .xxh-logo {
    font-size: 16px;
    font-weight: 500;
    color: #fff;
    display: inline-block;
    margin-right: 40px;
}

.xxh-layout-header .xxh-logo .xxh-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #5fb878;
    margin-right: 8px;
    vertical-align: middle;
}

.xxh-layout-header .xxh-user-box {
    position: absolute;
    right: 20px;
    top: 0;
    color: #d0d0d0;
    font-size: 13px;
}

.xxh-layout-header .xxh-user-box a {
    color: #d0d0d0;
    margin-left: 20px;
    text-decoration: none;
}

.xxh-layout-header .xxh-user-box a:hover {
    color: #fff;
}

.xxh-layout-body {
    position: absolute;
    top: 50px;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
}

.xxh-layout-side {
    width: 200px;
    background: #2f323a;
    overflow-y: auto;
}

.xxh-layout-side .layui-nav {
    background: transparent;
}

.xxh-layout-main {
    flex: 1;
    background: #f5f7fa;
    overflow: hidden;
    position: relative;
}

.xxh-layout-main iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

/* 内部页面容器 */
.xxh-page {
    padding: 15px 20px;
}

.xxh-page-title {
    font-size: 16px;
    font-weight: 500;
    color: #333;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

/* 搜索区域 */
.xxh-search-bar {
    background: #fff;
    padding: 15px 20px;
    border-radius: 4px;
    margin-bottom: 15px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.xxh-search-bar .layui-form-item {
    margin-bottom: 0;
}

/* 表格区域 */
.xxh-table-bar {
    background: #fff;
    padding: 15px 20px;
    border-radius: 4px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

/* LayUI 表格行高稍作调整 */
.layui-table-cell {
    height: auto;
    line-height: 22px;
    padding: 8px 10px;
}

/* 信息展示卡片（欢迎页） */
.xxh-stats {
    display: flex;
    flex-wrap: wrap;
    margin: -10px;
}

.xxh-stat-card {
    flex: 1;
    min-width: 200px;
    margin: 10px;
    background: #fff;
    padding: 20px;
    border-radius: 4px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    border-left: 4px solid #5fb878;
}

.xxh-stat-card.xxh-blue { border-left-color: #1e9fff; }
.xxh-stat-card.xxh-orange { border-left-color: #ffb800; }
.xxh-stat-card.xxh-red { border-left-color: #ff5722; }

.xxh-stat-card h4 {
    color: #999;
    font-size: 13px;
    font-weight: normal;
    margin: 0 0 8px;
}

.xxh-stat-card .xxh-stat-num {
    font-size: 28px;
    color: #333;
    font-weight: 500;
}

.xxh-stat-card .xxh-stat-sub {
    font-size: 12px;
    color: #999;
    margin-top: 6px;
}

/* 信息面板 */
.xxh-info-panel {
    background: #fff;
    padding: 20px;
    border-radius: 4px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    margin-bottom: 15px;
}

.xxh-info-panel h3 {
    font-size: 14px;
    font-weight: 500;
    color: #333;
    margin: 0 0 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid #eee;
}

.xxh-info-panel p {
    color: #666;
    font-size: 13px;
    line-height: 1.8;
    margin: 0;
}

.xxh-info-panel ul {
    margin: 8px 0 0 20px;
    padding: 0;
}

.xxh-info-panel ul li {
    color: #666;
    font-size: 13px;
    line-height: 1.8;
    list-style: disc;
}

/* 表单弹窗中的字段分组 */
.xxh-form-group {
    padding: 15px 20px;
    background: #fff;
}

.xxh-form-group .layui-form-label {
    width: 100px;
    padding: 9px 10px;
    text-align: right;
}

.xxh-form-group .layui-input-block {
    margin-left: 130px;
}

.xxh-form-actions {
    text-align: center;
    padding: 15px 20px;
    border-top: 1px solid #eee;
    margin: 0 -20px -15px;
    background: #fafafa;
}

/* 自定义 code 块（只读展示内容） */
.xxh-code {
    background: #f4f6f8;
    color: #333;
    padding: 10px 12px;
    border-radius: 4px;
    font-family: Consolas, Monaco, "Courier New", monospace;
    font-size: 12px;
    word-break: break-all;
    border: 1px solid #e8eaec;
}

/* 小设备适配 */
@media (max-width: 768px) {
    .xxh-login-box {
        width: 92%;
    }
    .xxh-layout-side {
        width: 60px;
    }
}
