/* 全局基础设置 - 回归大气风格 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Microsoft YaHei", sans-serif;
    background: #f5f7fa;
    color: #2d3748;
    line-height: 1.5;
}

.app-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 20px;
}

/* --- 顶部区域 --- */
.search-header {
    position: relative;
    text-align: center;
    margin-bottom: 38px;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.search-header h1 {
    font-size: 36px;
    font-weight: 550;
    color: #2c3e50;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.search-bar-row {
    display: flex;
    gap: 12px;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.search-wrapper {
    height: 68px;
    flex: 0 1 800px;
    background: #fff;
    border-radius: 50px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
    display: flex;
    align-items: center;
    padding: 0 34px;
}

.search-wrapper i {
    font-size: 16px;
    color: #718096;
    margin-right: 12px;
}

.search-wrapper input {
    flex: 1;
    height: 100%;
    border: none;
    outline: none;
    font-size: 15px;
    color: #2d3748;
}

/* --- 按钮组 --- */
.header-btns {
    position: absolute;
    top: 0;
    right: 0;
    display: flex;
    gap: 10px;
}

.btn-add, .btn-backup {
    height: 46px;
    padding: 0 24px;
    border-radius: 24px;
    border: none;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-add { background: #2c6e9e; color: #fff; }
.btn-add:hover { background: #235b87; }

.btn-backup { background-color: #4CAF50; color: white; }
.btn-backup:hover { background-color: #45a049; }

/* --- 布局 --- */
.dual-pane {
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 24px;
    height: calc(100vh - 200px);
}

/* --- 左侧商品列表 --- */
.product-list-panel {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 3px 12px rgba(0,0,0,0.05);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.list-header {
    padding: 16px 20px;
    background: #ffffff;
    font-weight: 600;
    font-size: 14px;
    color: #4a5568;
    border-bottom: 1px solid #e2e8f0;
}

.list-scroll {
    flex: 1;
    overflow-y: auto;
    padding: 8px 0;
}

.list-item {
    display: flex;
    gap: 14px;
    padding: 14px 20px;
    cursor: pointer;
    border-bottom: 1px solid #f7fafc;
    position: relative;
    transition: background 0.2s;
}

.list-item:hover { background: #f7fafc; }
.list-item.active {
    background: #f0f7ff;
    border-left: 2px solid #2c6e9e;
}

.list-thumb {
    width: 55px;
    height: 55px;
    border-radius: 8px;
    object-fit: cover;

    /* 下面这两行是上下居中关键 */
    display: block;
    margin: auto 0;
}

.list-info { flex: 1; min-width: 0; }

.list-info-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}

.list-main-sku {
    font-size: 14px;
    font-weight: 600;
    color: #2c6e9e;
    background: #EEF2FC;
    padding: 2px 8px;
    border-radius: 40px;
}

.id-gray-right {
    font-size: 11px;
    color: #a0aec0;
    font-family: monospace;
}

.list-preview {
    font-size: 12px;
    color: #718096;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* --- 右侧详情面板 --- */
.detail-panel {
    background: #fff;
    border-radius: 32px;
    box-shadow: 0 3px 12px rgba(0,0,0,0.05);
    padding: 24px 30px;
    overflow-y: auto;
}

.detail-grid {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 30px;
}

.detail-img {
    width: 100%;
    aspect-ratio: 1/1;
    border-radius: 12px;
    object-fit: cover;
}

/* 货号详情 */
.detail-sku {
    font-size: 14px;
    color: #2c6e9e;
    font-weight: normal;
    background: transparent;
    padding: 0;
    display: inline-block;
    margin-bottom: 8px;
}

/* 详情文字标题 */
.detail-title {
    font-size: 22px;
    font-weight: 600;
    color: #2d3748;
}

/* 描述区域 */
.desc-block {
    background: #f7fafc;
    border-radius: 10px;
    padding: 14px 16px;
    font-size: 14px;
    color: #4a5568;
    line-height: 1.6;
}

.desc-content {
    cursor: pointer;
    transition: background 0.2s;
}

.desc-content:hover {
    background: #edf2f7;
    border-radius: 4px;
}

.copy-hint {
    font-size: 12px;
    color: #999;
    margin: 6px 0 16px;
    text-align: right;
    display: block;
}

/* --- 平台信息 --- */
.platforms-compact h4 {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #6b8bab;
    /* 关键：离顶部再下来10px */
    margin-top: 10px;
    margin-bottom: 14px;
    border-left: 3px solid #2c6e9e;
    padding-left: 10px;
    letter-spacing: 0.6px;
}

.platform-item {
    background: #fafdff;
    border-radius: 16px;
    padding: 8px 14px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.8rem;
    border: 1px solid #eef2f0;
    transition: 0.1s;
}

.platform-name { color: #2d3748; font-weight: 500; }
.platform-name i { width: 22px; color: #5282a3; }

.platform-id {
    font-family: monospace;
    font-weight: 500;
    background: white;
    padding: 2px 5px;
    border-radius: 30px;
    color: #1f5e7a;
}

.size-header {
  margin-bottom: 8px; /* 距离下面表格 5px */
}

.size-header h3 {
  font-size: 16px;    /* 文字大小 16px */
  margin: 0;          /* 清除 h3 默认的上下间距 */
  padding: 0;
  font-weight: 600;   /* 稍微加粗，更好看 */
}

/* --- 尺寸表格 --- */
.compact-size-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
}

.compact-size-table th, .compact-size-table td {
    padding: 12px 14px;
    text-align: center;
    font-size: 13px;
    border-bottom: 1px solid #e2e8f0;
}

.compact-size-table th {
    background: #f7fafc;
    color: #4a5568;
    font-weight: 600;
}

/* 交互按钮组 - 尺寸编辑按钮样式 */
.action-btns {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 20px; /* 保留原有间距 */
}

.edit-size-btn, .save-size-btn {
    height: 46px;
    padding: 0 28px;
    border-radius: 24px;
    border: none;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

/* 取消按钮样式 */
.edit-size-btn {
    background: #f8fafc;
    color: #4a5568;
    border: 1px solid #e2e8f0;
}

.edit-size-btn:hover {
    background: #f1f5f9;
    color: #2d3748;
    border-color: #cbd5e1;
}

/* 保存按钮样式（参考备份按钮的绿色系） */
.save-size-btn {
    background-color: #4CAF50;
    color: white;
}

.save-size-btn:hover {
    background-color: #45a049;
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.2);
}

/* show类控制显示（如果需要） */
.save-size-btn.show {
    display: flex;
}

.save-size-btn:not(.show) {
    display: none;
}
.edit-icon-btn {
    background: #e2e8f0;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #2d3748;
    transition: 0.2s;
}

.edit-icon-btn:hover {
    background: #cbd5e0;
    color: #2c6e9e;
}

.delete-btn {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: #e53e3e;
    opacity: 0;
    transition: opacity 0.2s;
    cursor: pointer;
}
.list-item:hover .delete-btn { opacity: 1; }

.copy-mini {
    background: transparent;
    border: none;
    color: #95adcc;
    cursor: pointer;
    font-size: 0.7rem;
}
.desc-row {
  display: flex;
  justify-content: space-between; /* 左右分开 */
  align-items: center; /* 垂直居中对齐 */
  margin: 6px 0 16px;
  font-size: 12px;
  color: #999;
}



/* --- 滚动条 --- */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-thumb { background: #cbd5e0; border-radius: 3px; }