/* 产品海报设计器 — 扩展布局与移动端 */
.pe-bottom-sheet {
  display: none;
}
.pe-toolbar-row2 {
  flex-shrink: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  padding: 6px 14px 10px;
  background: #0f2e1c;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.pe-toolbar-row2 .pe-btn,
.pe-toolbar-row2 .pe-btn-sm {
  font-size: 12px;
  padding: 5px 10px;
}
.pe-btn-sm {
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  padding: 5px 10px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
}
.pe-btn-sm:hover {
  background: rgba(255, 255, 255, 0.15);
}
.pe-canvas-wrap.pe-panning {
  cursor: grab;
}
.pe-layer-row {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 100%;
}
.pe-layer-row .pe-layer-name {
  flex: 1;
  min-width: 0;
  font-size: 12px;
  border: 1px solid #dfe8e3;
  border-radius: 6px;
  padding: 4px 6px;
}
.pe-layer-ic {
  border: none;
  background: #eef4ef;
  border-radius: 6px;
  width: 28px;
  height: 28px;
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
  flex-shrink: 0;
}
.pe-layer-ic:hover {
  background: #dfece2;
}
.pe-layer-ic.on {
  background: #c9962a;
  color: #1a2e1f;
}
.pe-tpl-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 8px;
  margin-top: 10px;
}
.pe-tpl-card {
  border: 1px solid #e0ebe3;
  border-radius: 10px;
  padding: 8px;
  font-size: 12px;
  cursor: pointer;
  background: #fff;
  text-align: center;
  line-height: 1.35;
}
.pe-tpl-card:hover {
  border-color: #2d7a4e;
  box-shadow: 0 2px 8px rgba(45, 122, 78, 0.15);
}
.pe-tpl-card .cat {
  font-size: 10px;
  color: #888;
  margin-top: 4px;
}
/* 模块 / 农业素材网格 */
.pe-mod-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(104px, 1fr));
  gap: 8px;
  margin-top: 8px;
}
.pe-mod-btn {
  display: block;
  width: 100%;
  box-sizing: border-box;
  padding: 10px 8px;
  border-radius: 10px;
  border: 1px solid #cfe0d4;
  background: #fff;
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
  color: #1a4d2e;
  text-align: left;
  line-height: 1.35;
}
.pe-mod-btn:hover {
  border-color: #2d7a4e;
  background: #f5faf7;
}
.pe-ag-btn {
  display: block;
  width: 100%;
  box-sizing: border-box;
  padding: 8px 6px;
  border-radius: 8px;
  border: 1px solid #dfe8e3;
  background: #fff;
  cursor: pointer;
  font-size: 11px;
  font-weight: 600;
  color: #2d5a3e;
  text-align: center;
}
.pe-ag-btn:hover {
  border-color: #2d7a4e;
  background: #eef6f0;
}
#peStylePresetList {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 8px;
}
.pe-style-btn {
  text-align: left;
}
.pe-product-row {
  padding: 8px 10px;
  border: 1px solid #e0ebe3;
  border-radius: 10px;
  margin-bottom: 8px;
  font-size: 13px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.pe-product-row button {
  flex-shrink: 0;
  padding: 6px 10px;
  border-radius: 8px;
  border: 1px solid #cfe0d4;
  background: #fff;
  cursor: pointer;
  font-size: 12px;
  color: #1a4d2e;
}
.pe-bottom-sheet {
  display: none;
}
@media (max-width: 900px) {
  .pe-mobile-hint {
    display: none !important;
  }
  .pe-editor-root {
    display: flex !important;
    height: 100dvh;
    min-height: 100dvh;
    overflow: hidden;
  }
  .pe-toolbar .pe-brand {
    font-size: 14px;
  }
  .pe-toolbar .pe-input,
  .pe-toolbar .pe-btn {
    font-size: 12px;
    padding: 6px 8px;
  }
  .pe-toolbar-row2 {
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    max-width: 100vw;
  }
  .pe-main {
    display: flex !important;
    flex-direction: column;
    grid-template-columns: unset !important;
    min-height: 0;
    flex: 1;
  }
  .pe-side {
    display: none !important;
  }
  .pe-canvas-wrap {
    flex: 1;
    min-height: 200px;
    max-height: none;
    overflow: auto;
    padding: 10px;
    max-width: 100vw;
    box-sizing: border-box;
  }
  #peCanvasHost {
    max-width: 100%;
    box-sizing: border-box;
  }
  .pe-bottom-sheet {
    display: flex;
    flex-direction: column;
    max-height: 42vh;
    border-top: 1px solid #d8e5dc;
    background: #f7faf8;
    flex-shrink: 0;
    min-height: 120px;
  }
  .pe-sheet-tabs {
    display: flex;
    border-bottom: 1px solid #d8e5dc;
    overflow-x: auto;
    flex-shrink: 0;
  }
  .pe-sheet-tab {
    flex: 1;
    min-width: 72px;
    text-align: center;
    padding: 10px 6px;
    font-size: 12px;
    font-weight: 700;
    color: #4a6354;
    border: none;
    background: none;
    cursor: pointer;
  }
  .pe-sheet-tab.on {
    color: #0f3d24;
    border-bottom: 2px solid #c9962a;
    background: #fff;
  }
  .pe-sheet-body {
    overflow: auto;
    padding: 10px;
    flex: 1;
  }
}
