* { margin: 0; padding: 0; box-sizing: border-box; }
html, body {
    width: 100%;
    height: 100%;
    font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
    background: #eef1f5;
    color: #333;
}

#loadingGifDiv {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.overlay {
    z-index: 100;
    background-color: rgba(0, 0, 0, 0.5);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
}

.overlay10 {
    z-index: 10;
    background-color: rgba(0, 0, 0, 0.5);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
}

.classified {
    display: none;
    position: absolute;
    font-size:0.9em;
    font-weight:bold;
    top: 0em;
    left: 20%;
    width: 60%;
    height: 300em;
    padding: 7px;
    border: 4px solid #4CAF50;
    border-radius: 10px;
    background-color: white;
    z-index:1500;
}

.responsive-button {
    padding: 8px 16px; /* 上下和左右的内边距 */
    font-size: 1em;    /* 字体大小 */
    border: none;       /* 去除边框 */
    border-radius: 5px; /* 圆角 */
    background-color: #CFCFCF; /* 背景颜色 */
    color: black;       /* 字体颜色 */
    cursor: pointer;    /* 鼠标悬浮时的指针效果 */
    transition: background-color 0.3s; /* 背景颜色过渡效果 */
}

.responsive-button:hover {
    background-color: #528B8B; /* 悬停时的背景颜色 */
}

.container {
    width: 100%;
    min-height: 100vh;
    background: #fff;
    padding: 10px 10px 30px;
}

/* ===== 查询条件区域 ===== */
.filter-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 40px;
    padding: 6px 0 7px;
    border-bottom: 1px solid #eef0f3;
}
.filter-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: bold;
}
.filter-item input[type="text"],
.filter-item select,
.filter-item input[type="date"], input[type="month"] {
    height: 34px;
    border: 1px solid #dcdfe6;
    border-radius: 12px;
    padding: 0 12px;
    font-size: 14px;
    outline: none;
    color: #333;
    background: #fff;
    transition: border-color .2s, box-shadow .2s;
}
.filter-item input[type="text"]:hover,
.filter-item select:hover,
.filter-item input[type="date"]:hover, input[type="month"]:hover {
    border-color: #b3d8ff;
}
.filter-item input[type="text"]:focus,
.filter-item select:focus,
.filter-item input[type="date"]:focus, input[type="month"]:focus {
    border-color: #1890ff;
    box-shadow: 0 0 0 2px rgba(24,144,255,0.15);
}
.filter-item input[type="text"] { width: 170px; }
.filter-item select { width: 130px; cursor: pointer; }
.filter-item input[type="date"], input[type="month"] { width: 145px; }
.date-range-sep { color: #aab2bd; }

/* 标签组：整体分割 */
.tag-group {
    display: flex;
    border: 1px solid #dcdfe6;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(0,0,0,0.02);
}
.tag {
    padding: 7px 18px;
    font-size: 13px;
    color: #606266;
    cursor: pointer;
    user-select: none;
    transition: all .2s;
    border-right: 1px solid #dcdfe6;
    white-space: nowrap;
    background: #fff;
}
.tag:last-child { border-right: none; }
.tag:hover { color: #333; background: #f0f8ff; }
.tag.active {
    background: #B0E0E6;
    color: #333;
    box-shadow: inset 0 0 0 1px #B0E0E6;
}

/* ===== 操作按钮行 ===== */
.action-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0;
}
.action-bar .left,
.action-bar .center,
.action-bar .right {
    display: flex;
    gap: 10px;
}
.action-bar .center { flex: 1; justify-content: center; }

.btn {
    height: 36px;
    padding: 0 20px;
    border-radius: 5px;
    border: 1px solid transparent;
    font-size: 14px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: all .2s;
    font-weight: 500;
}
.btn-primary {
    background: #1890ff;
    color: #fff;
    box-shadow: 0 2px 4px rgba(24,144,255,0.3);
}
.btn-primary:hover { background: #40a9ff; box-shadow: 0 2px 8px rgba(24,144,255,0.4); }
.btn-default {
    background: #fff;
    border-color: #dcdfe6;
    color: #606266;
}
.btn-default:hover { border-color: #1890ff; color: #1890ff; background: #f0f8ff; }

.btn-add {
    background: #1890ff;
    color: #fff;
    box-shadow: 0 2px 4px rgba(24,144,255,0.3);
}
.btn-add:hover { background: #40a9ff; box-shadow: 0 2px 8px rgba(24,144,255,0.4); }

/* ===== 表格 ===== */
table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed; /* 关键：固定表格布局，让宽度设置生效 */
}
thead th {
    background: #D3D3D3;
    color: #606266;
    font-weight: 600;
    padding: 13px 10px;
    text-align: center;
    border-bottom: 2px solid #e8eaed;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 13.5px;
}
tbody td {
    padding: 10px 8px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    color: #444;
    border: 1px solid #ddd;
}
tbody tr.odd-row { background: #ffffff; }
tbody tr.even-row { background: #f2f4f7; }
tbody tr {
    cursor: pointer;
    transition: background .15s;
}
tbody tr:hover { background: #dcedff !important; }
tbody tr.selected-row { background: #a8d8ff !important; }

.op-icons {
    display: flex;
    gap: 8px;                     /* 减小gap，因为下面用padding代替间距 */
    justify-content: center;
}
.op-icons, td a {
    color: #1890ff;
    text-decoration: none;
    font-size: 14px;
    cursor: pointer;
    transition: all .2s;
    padding: 1px 10px;            /* 增大点击热区：上下左右都能点到 */
    border-radius: 4px;
    display: inline-block;        /* 让padding真正撑开可点击范围 */
}
.op-icons a.danger { color: #f5222d; }
.op-icons a:hover {
    text-decoration: underline;
    background: rgba(24,144,255,0.08);   /* 悬停时有视觉反馈，间接提示可点击范围 */
}
.op-icons a.danger:hover {
    background: rgba(245,34,45,0.08);
}

/* ===== 分页 ===== */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 14px 0 0;
}
.pagination button {
    min-width: 34px;
    height: 34px;
    border: 1px solid #dcdfe6;
    background: #fff;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    color: #606266;
    transition: all .2s;
}
.pagination button:hover:not(:disabled) {
    border-color: #1890ff;
    color: #1890ff;
    background: #f0f8ff;
}
.pagination button.active {
    background: #1890ff;
    color: #fff;
    border-color: #1890ff;
    box-shadow: 0 2px 4px rgba(24,144,255,0.3);
}
.pagination button:disabled {
    cursor: not-allowed;
    color: #c0c4cc;
    background: #f5f7fa;
}
.pagination .page-info {
    margin-left: 14px;
    font-size: 13px;
    color: #909399;
}

.open-btn {
    margin: 30px;
    padding: 10px 24px;
    background: linear-gradient(135deg, #409eff, #3b8ee6);
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    box-shadow: 0 4px 10px rgba(64,158,255,0.3);
}

.open-btn:hover {
    opacity: 0.92;
}

.modal-mask {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.45);
    z-index: 999;
    align-items: center;
    justify-content: center;
}

.modal-mask.show {
    display: flex;
}

.modal-header {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 26px;
    background: linear-gradient(135deg, #f8fafc, #eef2f7);
    border-bottom: 1px solid #ebeef2;
}

.modal-title {
    font-size: 18px;
    font-weight: 600;
    color: #303133;
}

.modal-header-btns {
    display: flex;
    align-items: center;
    gap: 24px;
}

.header-btn {
    padding: 8px 22px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    user-select: none;
    border: 1px solid transparent;
    transition: all .2s;
}

.btn-save {
    background: #409eff;
    color: #fff;
    box-shadow: 0 3px 8px rgba(64,158,255,0.35);
}
.btn-save:hover {
    background: #66b1ff;
}

.btn-copy {
    background: #07c160;
    color: #fff;
    box-shadow: 0 3px 8px rgba(64,158,255,0.35);
}
.btn-copy:hover {
    background: #07c160;
}

.btn-close {
    background: #fff;
    color: #666;
    border-color: #dcdfe6;
}
.btn-close:hover {
    color: #f56c6c;
    border-color: #f56c6c;
    background: #fef0f0;
}

/* flex:1 auto + min-height:0，使得内容不超限时不出现滚动条，
   超限时会被父级 max-height 挤压从而触发滚动 */
.modal-body {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 26px;
    min-height: 0;
}

.form-row {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.form-row:last-child {
    margin-bottom: 0;
}

.form-col-left {
    flex: 1;
    display: flex;
    align-items: center;
}

.form-col-right {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.right-label {
    text-align: left;
    margin-right: 6px;
    color: #666;
    font-size: 14px;
    font-weight: bold;
    white-space: nowrap;
    flex-shrink: 0;
}

.category-display {
    font-size: 14px;
    font-weight: bold;
    color: #666;
    transition: all .2s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.category-display.selected {
    font-weight: bold;
}

.date-input {
    border: 1px solid #dcdfe6;
    border-radius: 5px;
    padding: 9px 10px;
    font-size: 14px;
    outline: none;
    transition: border-color .2s, box-shadow .2s;
    background: #fff;
}

.text-input {
    border: 1px solid #dcdfe6;
    border-radius: 5px;
    padding: 9px 12px;
    font-size: 14px;
    outline: none;
    width: 200px;
    transition: border-color .2s, box-shadow .2s;
    background: #fff;
}

input:focus,
textarea:focus {
    border-color: #67c23a !important;
    box-shadow: 0 0 0 3px rgba(103,194,58,0.12);
    outline: none;
}

.type-tag-group {
    display: inline-flex;
    border: 1px solid #dcdfe6;
    border-radius: 10px;
    overflow: hidden;
    user-select: none;
}

.type-btn {
    padding: 8px 36px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    color: #666;
    background: #fff;
    transition: all .1s;
}

.type-btn:first-child {
    border-right: 1px solid #dcdfe6;
}

.type-btn.active {
    color: #333;
    background: #B0E0E6;
}

.time-info-row {
    display: flex;
    align-items: center;
    margin-top: 20px;
    margin-bottom: 20px;
}

.time-info-left,
.time-info-right {
    flex: 1;
    font-size: 12px;
    color: #aaa;
}

.time-info-right {
    text-align: left; /* 与右侧输入框左对齐 */
}

.remark-textarea {
    width: 100%;
    min-height: 100px;
    border: 1px solid #dcdfe6;
    border-radius: 5px;
    padding: 10px 12px;
    font-size: 14px;
    resize: vertical;
    outline: none;
    transition: border-color .2s, box-shadow .2s;
}

/* ====== 图片区域：左边固定按钮位（始终显示），右边小尺寸预览位 ====== */
.image-row {
    display: flex;
    flex-wrap: nowrap;
    align-items: flex-start;
    gap: 16px;
}

/* 左侧：添加图片按钮，固定宽高，始终显示，不会被隐藏或挤压 */
.image-add-wrap {
    width: 96px;
    height: 96px;
    flex: 0 0 96px;
}

.image-add {
    width: 96px;
    height: 96px;
    border: 1px dashed #c0c4cc;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #999;
    cursor: pointer;
    font-size: 13px;
    transition: all .2s;
    background: #fafbfc;
}

.image-add:hover {
    border-color: #409eff;
    color: #409eff;
    background: #ecf5ff;
}

.image-add .plus {
    font-size: 26px;
    line-height: 1;
    margin-bottom: 4px;
}

/* 右侧：预览区域，固定小尺寸盒子（只放一张图），不占满剩余空间 */
.image-preview-wrap {
    width: 96px;
    height: 96px;
    flex: 0 0 96px;
    border: 1px solid #ebeef2;
    border-radius: 8px;
    background: #fafbfc;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.image-preview-placeholder {
    color: #c0c4cc;
    font-size: 12px;
    text-align: center;
    padding: 0 6px;
}

.image-preview-item {
    position: relative;
    width: 96px;
    height: 96px;
    border-radius: 8px;
    overflow: hidden;
}

.image-preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.image-remove {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(0,0,0,0.55);
    color: #fff;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background .2s;
}

.image-remove:hover {
    background: rgba(245,108,108,0.9);
}