/* ─────────── Input / textarea ─────────── */
/* 1px line-1 hairline 作为可输入感知 affordance —— 不属于"卡片视觉边界"范畴。 */
.me-input {
  display: block;
  width: 100%;
  font: inherit;
  font-size: 15px;
  color: #1d1d1f;
  padding: 10px 14px;
  background: #ffffff;
  border: 1px solid #ececef;
  border-radius: 10px;
  -webkit-corner-shape: squircle;
  corner-shape: squircle;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
  box-sizing: border-box;
}
.me-input:focus {
  border-color: #1d1d1f;
}
/* 禁用态（如证件 OCR 识别中，锁住输入免得回填覆盖用户手打）：灰底 + 变淡，光标示意不可点。 */
.me-input:disabled {
  background: #f5f5f7;
  color: #86868b;
  cursor: not-allowed;
}
/* 校验出错的输入：红描边高亮出问题的控件（薪资 min/max 等）。双类 0,2,0 稳压
   .me-input（0,1,0）；:focus 版 0,3,0 压过 .me-input:focus（0,2,0），聚焦也保持红。 */
.me-input.me-input--err,
.me-input.me-input--err:focus {
  border-color: #e5484d;
}
.me-input::placeholder {
  color: #a1a1a6;
}
.me-textarea {
  resize: vertical;
  line-height: 1.5;
  min-height: 80px;
}
/* 原生 select 视觉 —— 跟 .me-input 同 chrome，自定义箭头不强行做（让 OS / 浏览器
   保留原生体验，跨设备一致性更好）。 */
.me-select {
  appearance: auto;
  padding-right: 32px;
}

/* 单个 checkbox 行 */
.me-checkbox-field {
  display: block;
}
.me-checkbox-row {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 14px;
  color: #1d1d1f;
}
.me-checkbox-row input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: #1d1d1f;
  cursor: pointer;
}
.me-markdown {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  font-size: 14px;
  min-height: 240px;
}
/* JD 文本域始终透明无边框（外层 .me-md-editor 已经给了边框 + 圆角）——
   去掉它自带的 .me-input 边框（与工具栏底线叠成"分割线"）和白底，去掉 resize 手柄。 */
.me-md-area {
  background: transparent;
  border: 0;
  border-radius: 0;
  resize: none;
}
.me-md-area:focus {
  border: 0;
  box-shadow: none;
}
/* 弹窗内：JD 编辑器吃满剩余高度，只在文本域内部滚动（form 撑满 body 才有空间可分配）。 */
.me-modal-body .me-jobform {
  min-height: 100%;
}
.me-md-editor {
  display: flex;
  flex-direction: column;
}
.me-modal-body .me-jobform > .me-field:has(.me-md-editor) {
  flex: 1 1 auto;
  min-height: 330px;
  display: flex;
  flex-direction: column;
}
.me-modal-body .me-jobform > .me-field:has(.me-md-editor) .me-field-body {
  flex: 1;
  min-height: 0;
  display: flex;
}
.me-modal-body .me-md-editor {
  flex: 1;
  min-height: 0;
}
.me-modal-body .me-md-area {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
}
/* 滚动条：透明轨道、无边框 / 无分割线，只留细的半透明拇指（弹窗 body + JD 文本域共用）。
   设计偏好：这些位置不要分割线和背景色填充。 */
.me-modal-body,
.me-md-area,
.me-sig-rail,
.me-sig-detail-body {
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 0, 0, 0.18) transparent;
}
.me-modal-body::-webkit-scrollbar,
.me-md-area::-webkit-scrollbar,
.me-sig-rail::-webkit-scrollbar,
.me-sig-detail-body::-webkit-scrollbar {
  width: 8px;
}
.me-modal-body::-webkit-scrollbar-track,
.me-md-area::-webkit-scrollbar-track,
.me-sig-rail::-webkit-scrollbar-track,
.me-sig-detail-body::-webkit-scrollbar-track {
  background: transparent;
  border: 0;
}
.me-modal-body::-webkit-scrollbar-thumb,
.me-md-area::-webkit-scrollbar-thumb,
.me-sig-rail::-webkit-scrollbar-thumb,
.me-sig-detail-body::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.18);
  border-radius: 999px;
  border: 0;
}

/* ─────────── 列表 ─────────── */
.me-list {
  display: grid;
  gap: 12px;
}
.me-list-empty {
  font-size: 13px;
  color: #a1a1a6;
  margin: 0;
  padding: 12px 0;
}
.me-list-item {
  background: #ffffff;
  border-radius: 14px;
  -webkit-corner-shape: squircle;
  corner-shape: squircle;
  padding: 14px 16px;
  /* 创始团队 / 融资历史 / 媒体报道 的列表卡套后台侧栏（.me-shell-side）同款观感：
     1px 淡描边 + 同一道轻阴影，边缘更清晰、跟侧栏 / 概览卡对齐。 */
  border: 1px solid rgba(0, 0, 0, 0.04);
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.03),
    0 8px 24px -12px rgba(0, 0, 0, 0.06);
}
.me-list-item-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.me-list-item-idx {
  font-size: 12px;
  color: #a1a1a6;
  letter-spacing: 0.04em;
}
.me-list-item-drag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: grab;
  user-select: none;
  touch-action: none;
}
.me-list-item-drag:active {
  cursor: grabbing;
}
.me-list-item.is-dragging {
  opacity: 0.5;
}
.me-list-item.is-drop-target {
  box-shadow: 0 0 0 2px #0071e3;
}
.me-list-item-actions {
  display: inline-flex;
  gap: 4px;
}
.me-list-item-body {
  display: grid;
  gap: 10px;
}

/* ─────────── 可折叠列表条目（创始团队 / 媒体报道用） ─────────── */
/* 可折叠条目：头部不留下方间距（展开时的间距挪进 body wrap 的 padding-top，
   跟高度一起动画）。收起态整卡上下 padding 略收紧，切换有过渡不跳。 */
.me-list-item--collapsible {
  transition: padding 0.28s ease;
}
.me-list-item--collapsible .me-list-item-head {
  margin-bottom: 0;
}
.me-list-item--collapsible.is-collapsed {
  padding-top: 10px;
  padding-bottom: 10px;
}
/* body 折叠动画：grid 行高 0fr↔1fr（现代浏览器可对 auto 高度做过渡）。
   收起时延迟切 visibility:hidden，把内容移出 tab / 无障碍树。 */
.me-list-item-bodywrap {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  visibility: hidden;
  transition:
    grid-template-rows 0.28s ease,
    opacity 0.2s ease,
    visibility 0s linear 0.28s;
}
.me-list-item-bodywrap.is-open {
  grid-template-rows: 1fr;
  opacity: 1;
  visibility: visible;
  transition:
    grid-template-rows 0.28s ease,
    opacity 0.24s ease 0.04s,
    visibility 0s;
}
.me-list-item-bodywrap > .me-list-item-body {
  overflow: hidden;
  min-height: 0;
}
/* head↔body 的间距只在展开态给 —— padding 不受 grid 0fr 行高压缩，若常驻会在
   收起态残留一条 ~12px 的空带（就是那条「奇怪的底边距」）。 */
.me-list-item-bodywrap.is-open > .me-list-item-body {
  padding-top: 12px;
}
@media (prefers-reduced-motion: reduce) {
  .me-list-item--collapsible,
  .me-list-item-bodywrap,
  .me-list-item-bodywrap.is-open,
  .me-list-chevron {
    transition: none;
  }
}
/* 摘要按钮：占满 idx 与操作区之间的空间，点击展开 / 收起。无边框无填充，
   靠 hover 变色提示可点（对齐 DS：不用背景块）。 */
.me-list-summary {
  appearance: none;
  border: 0;
  background: transparent;
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 2px 4px;
  margin: 0 4px;
  cursor: pointer;
  color: #1d1d1f;
  text-align: left;
}
.me-list-summary-main {
  flex: 1;
  min-width: 0;
}
/* 摘要文本组：primary（name）+ secondary（role），可选前置头像。创始团队 /
   媒体报道等可折叠列表共用。 */
.me-listsum {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.me-listsum-name {
  font-size: 14px;
  color: #1d1d1f;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: none;
  max-width: 55%;
}
.me-listsum-role {
  font-size: 13px;
  color: #86868b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}
.me-listsum-role::before {
  content: "·";
  margin-right: 6px;
  color: #c7c7cc;
}
/* 摘要为空（新加条目还没填）时不显示孤零零的「·」。 */
.me-listsum-role:empty::before {
  content: none;
}

/* 创始人摘要复用公开详情页的 .t4-brief-* 类，那套尺寸是给详情页排版调的、放进
   编辑器折叠行里偏小。这里按 .me-list-summary 作用域放大头像与文字，只影响编辑
   器，不动公开详情页的共享类。 */
.me-list-summary .t4-brief-av {
  width: 36px;
  height: 36px;
}
.me-list-summary .t4-brief-pmeta .nm {
  font-size: 15px;
}
.me-list-summary .t4-brief-pmeta .rl {
  font-size: 13px;
}
/* 折叠箭头：base 指下（展开态），折叠态 rotate -90 指右（对齐既有展开箭头方向约定）。 */
.me-list-chevron {
  flex: none;
  display: inline-flex;
  color: #86868b;
  transform: rotate(-90deg);
  transition: transform 0.18s ease;
}
.me-list-chevron.is-open {
  transform: rotate(0deg);
}
.me-list-summary:hover .me-list-chevron {
  color: #1d1d1f;
}

/* ─────────── Icon button ─────────── */
.me-icon-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: #86868b;
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.me-icon-btn:hover:not(:disabled) {
  background: #f5f5f5;
  color: #1d1d1f;
}
.me-icon-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}
.me-icon-btn--danger:hover:not(:disabled) {
  color: #b91c1c;
}

/* ─────────── Add 按钮（虚线轮廓） ─────────── */
.me-add-btn {
  appearance: none;
  font: inherit;
  font-size: 13px;
  color: #86868b;
  background: transparent;
  border: 1px dashed #ececef;
  border-radius: 10px;
  padding: 8px 16px;
  cursor: pointer;
  justify-self: start;
  transition: color 0.15s, border-color 0.15s;
}
.me-add-btn:hover {
  color: #1d1d1f;
  border-color: #86868b;
}

/* ─────────── String list / Social row ─────────── */
.me-stringlist {
  display: grid;
  gap: 8px;
}
.me-stringlist-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 8px;
}
.me-social-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 8px;
}
/* icon + select 融合成一个 platform 选择组件：共享 1px line-1 圆角边框，
   icon 在 select 左侧内部，看起来像一个整体。 */
.me-social-platform {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0 8px 0 8px;
  background: #ffffff;
  border: 1px solid #ececef;
  border-radius: 10px;
  -webkit-corner-shape: squircle;
  corner-shape: squircle;
  transition: border-color 0.15s;
}
.me-social-platform:focus-within {
  border-color: #1d1d1f;
}
.me-social-icon {
  width: 18px;
  height: 18px;
  border-radius: 4px;
  background: #f5f5f5;
  flex-shrink: 0;
}
.me-social-select {
  appearance: auto;
  background: transparent;
  border: 0;
  outline: none;
  padding: 8px 4px;
  font: inherit;
  font-size: 14px;
  color: #1d1d1f;
  cursor: pointer;
  flex: 1;
  min-width: 0;
}

/* 图标型类型选择器：只露图标 + 小箭头，不显示平台名。select 透明覆盖整块捕获点击/键盘。 */
.me-social-platform--icon { position: relative; gap: 5px; padding: 8px 9px; }
.me-social-caret { color: #86868b; flex-shrink: 0; }
.me-social-select--overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}

/* 拖拽图片到上传框时的高亮（虚线蓝框 + 浅蓝底）。 */
.me-image-btn.is-dragging {
  box-shadow: inset 0 0 0 2px #2e84fa;
  background: #f0f6ff;
}

/* 创始人浮窗（添加/编辑）里的头像框：用后台侧栏 / 协议阅读器同款 1px 淡描边 + 克制小阴影，
   浮起来更清晰。只限浮窗内，不动团队 logo 等其它上传框。squircle + 描边在 Chromium 四角会
   留毛刺 → 加边时切回普通圆角。拖拽高亮态仍走上面的 .is-dragging 覆盖。 */
.me-pop-body .me-image-btn:not(.is-dragging) {
  border: 1px solid rgba(0, 0, 0, 0.04);
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.03),
    0 8px 24px -12px rgba(0, 0, 0, 0.06);
  -webkit-corner-shape: round;
  corner-shape: round;
}

/* ─────────── Image upload ───────────
 * 见 components/public/me/Fields.jsx 顶部注释 + DESIGN_SYSTEM.md §1.8：
 * 客户端上传交互只暴露按钮，不要 URL 输入框。 */
.me-image-row {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}
.me-image-file {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.me-image-btn {
  /* squircle 20 跟公开站 .t4-hero-avatar 对齐 —— 让带四角装饰的 logo（Bonjour
     的手掌 + L 标）裁出来跟 hero 一样的视觉。白底承接深色 SVG logo 也清晰。 */
  appearance: none;
  border: 0;
  background: #ffffff;
  border-radius: 20px;
  -webkit-corner-shape: squircle;
  corner-shape: squircle;
  overflow: hidden;
  cursor: pointer;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  transition: box-shadow 0.15s;
  padding: 0;
}
.me-image-btn:hover:not(:disabled) {
  box-shadow:
    0 2px 4px rgba(0, 0, 0, 0.06),
    0 14px 28px -10px rgba(0, 0, 0, 0.10);
}
.me-image-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.me-image-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.me-image-empty {
  color: #a1a1a6;
}
.me-image-overlay {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: #1d1d1f;
}
/* 更新图片：文字按钮（对齐设计：白底 + 1px #e6e6e3 + 圆角8 + shadow-1），
   取代原先孤零零的 × 图标。round 圆角避免 squircle+描边的四角毛刺。 */
.me-image-action {
  appearance: none;
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  color: #1d1d1f;
  background: #ffffff;
  border: 1px solid #e6e6e3;
  border-radius: 8px;
  -webkit-corner-shape: round;
  corner-shape: round;
  padding: 10px 16px;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  transition: box-shadow 0.15s, background 0.15s;
}
.me-image-action:hover {
  box-shadow:
    0 2px 4px rgba(0, 0, 0, 0.06),
    0 14px 28px -10px rgba(0, 0, 0, 0.1);
}

/* ─────────── Chips（地址多选） ─────────── */
.me-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
/* 校验出错的 chip 组（如经验必选）：套一圈红环定位到控件。outline 不占布局。 */
.me-chips--err {
  outline: 1.5px solid #e5484d;
  outline-offset: 5px;
  border-radius: 8px;
}
.me-chips-empty {
  font-size: 13px;
  color: #a1a1a6;
}
/* 已选标签 pill（工作地点 / 社交链接 / 字符串列表共用）：灰底无边框，跟
   toggle chip 未选态同底（#f7f7f7），不用描边（§1.4 白底场景不用 border 分组）。 */
.me-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #f7f7f7;
  border: 0;
  color: #1d1d1f;
  font-size: 13px;
  padding: 5px 6px 5px 12px;
  border-radius: 999px;
}
/* 放大档：与 .me-chip-toggle（14px + 8px 纵向 padding）同高。地址多选的已选
   chip 用它，跟同排的「+ 选择地点」pill / 经验 / 薪资 chip 大小一致。 */
.me-chip.me-chip--lg {
  font-size: 14px;
  padding: 8px 6px 8px 14px;
}
/* 固定集合多选的 toggle chip（Figma 482:5053）：pill 999，前缀 16px 图标 + gap 4。
   未选 = 灰底 #f7f7f7 + 加号 + ink-2 文本；已选 = 蓝底 #3b82f6 + 白勾 + 白字。 */
.me-chip-toggle {
  appearance: none;
  font: inherit;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #f7f7f7;
  border: 0;
  color: #3c3c43;
  padding: 8px 16px 8px 14px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

/* ─────────── 投递发送至 选择器（components/shared/JobContactPicker me 皮肤） ─────────── */
.me-contact {
  display: grid;
  gap: 8px;
}
.me-contact-hint {
  margin: 0;
  font-size: 13px;
  color: #a1a1a6;
  line-height: 1.5;
}
/* 空态就地补录创始人：姓名 + 头衔 + 添加 同排（窄屏换行）。输入框复用 .me-input，
   头衔那格弹性占满剩余宽度。 */
.me-contact-add {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.me-contact-add .me-contact-add-input:first-child { width: 140px; }
.me-contact-add .me-contact-add-input:nth-child(2) { flex: 1 1 220px; min-width: 0; }
.me-contact-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
/* 头像 + 名字·角色的单选 chip —— 左侧留头像位，选中态品牌蓝（同 me-chip-toggle） */
.me-contact-chip {
  appearance: none;
  font: inherit;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #f7f7f7;
  border: 0;
  color: #3c3c43;
  padding: 5px 14px 5px 5px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.me-contact-chip:hover {
  background: #ededed;
}
.me-contact-chip.is-on {
  background: #3b82f6;
  color: #ffffff;
}
.me-contact-chip.is-on:hover {
  background: #2f74e8;
}
.me-contact-avatar {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
  border-radius: 50%;
  background-size: cover;
  background-position: center;
}
.me-contact-avatar--fb {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #e6e6e9;
  color: #5d5d5d;
  font-size: 12px;
}
.me-contact-chip.is-on .me-contact-avatar--fb {
  background: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}
.me-contact-name {
  line-height: 1.1;
}
.me-contact-role {
  opacity: 0.7;
}
.me-chip-toggle-ic {
  display: inline-flex;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}
.me-chip-toggle:hover {
  background: #ededed;
}
.me-chip-toggle.is-on {
  background: #3b82f6;
  color: #ffffff;
}
.me-chip-toggle.is-on:hover {
  background: #2f74e8;
}
.me-chip-x {
  appearance: none;
  border: 0;
  background: transparent;
  color: #86868b;
  width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.me-chip-x:hover {
  /* chip 底已是 #f7f7f7，× hover 底再深一档才看得出 */
  background: #e4e4e4;
  color: #1d1d1f;
}
.me-picker {
  margin-top: 12px;
  background: #ffffff;
  border-radius: 14px;
  -webkit-corner-shape: squircle;
  corner-shape: squircle;
  box-shadow: 0 6px 16px 0 rgba(0, 0, 0, 0.07);
  padding: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.me-picker-item {
  appearance: none;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 13px;
  color: #1d1d1f;
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s;
}
.me-picker-item:hover {
  background: #f5f5f5;
}
.me-picker-empty {
  font-size: 13px;
  color: #a1a1a6;
  margin: 0;
  padding: 8px 12px;
}

/* ─────────── Error banner ─────────── */
.me-error-banner {
  background: #ffffff;
  border-radius: 14px;
  -webkit-corner-shape: squircle;
  corner-shape: squircle;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  padding: 14px 18px;
  margin-bottom: 16px;
  color: #b91c1c;
}
.me-error-banner-head {
  margin: 0 0 4px;
  font-size: 14px;
  font-weight: 500;
}
.me-error-banner-list {
  margin: 0;
  padding-left: 18px;
  font-size: 12px;
}
.me-error-banner-list code {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
}

@media (max-width: 720px) {
  /* 窄屏：platform 选择器换行到 URL 输入框上方，第二行 input 全宽 */
  .me-social-row {
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
  }
  .me-social-platform {
    grid-column: 1 / -1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .me-section, .me-savebar, .me-form-toc-item, .me-savebar-btn,
  .me-input, .me-icon-btn, .me-add-btn, .me-chip-x, .me-image-btn,
  .me-picker-item, .me-shell-bottom-link, .me-shell-nav-item,
  .me-btn, .me-btn-arr { transition: none; }
}

