/* 秋招工作台 · apply.css —— 「网申」页：一页瀑布流，点卡片复制，✎ 随时编辑 */
.ap-page { max-width: 1120px; margin: 0 auto; --ap-top: 0px; }

/* ---------- 粘性顶条：标题 + 分区导航 ---------- */
.ap-top {
  position: sticky; top: var(--ap-top); z-index: 6;
  display: flex; align-items: center; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap;
  padding: 12px 0 10px; margin-bottom: 4px;
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.ap-top-text h2 { margin: 0; font-family: var(--font-serif); font-size: 22px; letter-spacing: .06em; line-height: 1.2; }
.ap-top-text p { margin: 3px 0 0; font-size: 12.5px; color: var(--muted); }
.ap-top-text b { color: var(--ink); font-weight: 600; }
.ap-nav { display: flex; gap: 2px; padding: 3px; border-radius: 11px; background: var(--panel-sub); border: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; max-width: 100%; }
.ap-nav::-webkit-scrollbar { display: none; }
.ap-nav a {
  flex: none; padding: 5px 13px; border-radius: 8px; font-size: 13px; color: var(--muted);
  text-decoration: none; white-space: nowrap; transition: background .15s, color .15s;
}
.ap-nav a:hover { color: var(--ink); }
.ap-nav a.active { background: var(--panel); color: var(--ink); font-weight: 650; box-shadow: 0 1px 2px rgba(0,0,0,.08), 0 0 0 1px var(--line); }

/* ---------- 分区 ---------- */
.ap-sec { margin-top: 34px; scroll-margin-top: calc(var(--ap-top) + 74px); min-width: 0; }
.ap-sec-h { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; margin-bottom: 14px; }
.ap-sec-h h3 { margin: 0; font-family: var(--font-serif); font-size: 19px; letter-spacing: .04em; }
.ap-sec-h p { margin: 0; font-size: 12.5px; color: var(--muted); }
.ap-sec-body { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.ap-note { margin: 0; font-size: 12.5px; color: var(--muted); }
.ap-note b { color: var(--accent); font-weight: 650; }
.ap-sub { font-size: 11.5px; font-weight: 400; color: var(--faint); margin-left: 6px; }

.ap-group { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px 18px; box-shadow: var(--shadow); min-width: 0; }
.ap-group + .ap-group { margin-top: 0; }
.ap-panel { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 4px 18px; box-shadow: var(--shadow); }
.ap-panel > .ap-block-group { padding: 16px 0 18px; border-bottom: 1px solid var(--line); }
.ap-panel > .ap-block-group:last-child { border-bottom: 0; }
.ap-panel .ap-block-group > h4 { margin: 0 0 12px; font-size: 13px; font-weight: 650; color: var(--muted); letter-spacing: .04em; }
.ap-group > h4 { margin: 0 0 12px; font-size: 13px; font-weight: 650; color: var(--muted); letter-spacing: .04em; }

/* ---------- 可复制卡片 ---------- */
.ap-chips { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 10px; min-width: 0; }
.ap-chips .ap-field.is-long { grid-column: 1 / -1; }

.ap-field {
  position: relative; min-width: 0; cursor: pointer;
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 9px 12px 10px;
  transition: border-color .15s ease, box-shadow .15s ease, transform .12s ease, background .15s ease;
}
.ap-group .ap-field { background: var(--panel-sub); border-color: transparent; }
.ap-field:hover { border-color: color-mix(in srgb, var(--accent) 55%, var(--line)); box-shadow: 0 6px 18px -12px var(--accent); }
.ap-group .ap-field:hover { background: var(--panel); }
.ap-field:active { transform: scale(.997); }
.ap-field.is-edited { box-shadow: inset 3px 0 0 var(--warn); }

.ap-field-top { display: flex; align-items: center; gap: 8px; min-height: 20px; }
.ap-label { font-size: 11.5px; font-weight: 600; color: var(--muted); letter-spacing: .03em; min-width: 0; overflow-wrap: anywhere; }
.ap-edited { font-size: 10px; padding: 0 6px; line-height: 16px; border-radius: 99px; background: var(--warn-soft); color: var(--warn); font-weight: 650; flex: none; }
.ap-count { margin-left: auto; font-size: 11px; color: var(--faint); font-variant-numeric: tabular-nums; flex: none; }
.ap-count.over { color: var(--bad); font-weight: 700; }
.ap-acts { display: inline-flex; gap: 0; flex: none; opacity: 0; transition: opacity .15s; }
.ap-field:hover .ap-acts, .ap-field:focus-within .ap-acts { opacity: 1; }
@media (hover: none) { .ap-acts { opacity: 1; } }
.ap-act { border: 0; background: transparent; color: var(--faint); cursor: pointer; padding: 1px 6px; border-radius: 6px; font-size: 13px; line-height: 18px; }
.ap-act:hover { background: var(--accent-soft); color: var(--accent); }
.ap-act[hidden] { display: none; }

.ap-copy { margin-top: 3px; font-size: 13.5px; line-height: 1.75; color: var(--ink); white-space: pre-wrap; overflow-wrap: anywhere; word-break: break-word; outline: none; }
.ap-copy[hidden] { display: none; }
.ap-empty { color: var(--faint); }
.ap-flash {
  position: absolute; right: 10px; top: 8px; font-size: 11px; font-weight: 700; color: var(--on-accent);
  background: var(--ok); padding: 1px 9px; border-radius: 99px; opacity: 0; pointer-events: none;
  transform: translateY(-3px); transition: opacity .16s ease, transform .16s ease;
}
.ap-field.copied { border-color: var(--ok); background: var(--ok-soft) !important; }
.ap-field.copied .ap-flash { opacity: 1; transform: translateY(0); }
.ap-field.copied .ap-count, .ap-field.copied .ap-acts { opacity: 0; }

.ap-editbox[hidden] { display: none; }
.ap-textarea {
  width: 100%; margin-top: 4px; resize: vertical; font-size: 13.5px; line-height: 1.75;
  padding: 8px 10px; border: 1px solid var(--accent); border-radius: 10px; background: var(--panel); color: var(--ink);
}
.ap-edit-row { display: flex; align-items: center; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.ap-edit-hint { font-size: 11px; color: var(--faint); margin-left: auto; }
.ap-warn { margin-top: 8px; font-size: 12px; line-height: 1.6; color: var(--warn); background: var(--warn-soft); border-radius: 8px; padding: 5px 10px; }

/* ---------- 实习 / 项目卡片 ---------- */
.ap-stack { display: flex; flex-direction: column; gap: 16px; }
.ap-item { background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 18px 20px 20px; box-shadow: var(--shadow); min-width: 0; }
.ap-item.is-picked { border-color: color-mix(in srgb, var(--accent) 60%, var(--line)); background: linear-gradient(180deg, var(--accent-soft), var(--panel) 90px); }
.ap-item.is-backup { background: var(--panel-sub); box-shadow: none; }
.ap-item-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.ap-item-head h4 { margin: 0; font-family: var(--font-serif); font-size: 16.5px; letter-spacing: .02em; }
.ap-pick, .ap-bk { font-size: 10.5px; font-weight: 700; padding: 1px 9px; line-height: 18px; border-radius: 99px; }
.ap-pick { background: var(--accent); color: var(--on-accent); }
.ap-bk { background: var(--panel-sub); color: var(--muted); border: 1px solid var(--line); }
.ap-caution { display: flex; gap: 10px; align-items: baseline; font-size: 12px; line-height: 1.65; color: var(--warn); background: var(--warn-soft); border-radius: 10px; padding: 7px 12px; margin-bottom: 12px; }
.ap-caution b { flex: none; font-size: 10.5px; letter-spacing: .08em; }
.ap-meta { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); margin-bottom: 10px; }
.ap-item .ap-meta .ap-field { background: var(--panel-sub); border-color: transparent; }
.ap-item .ap-meta .ap-field:hover { background: var(--panel); border-color: color-mix(in srgb, var(--accent) 55%, var(--line)); }
.ap-meta .ap-field:first-child { grid-column: span 2; }
.ap-chips.ap-meta .ap-field.is-long { grid-column: 1 / -1; }
.ap-desc { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.ap-desc .ap-field { background: var(--panel-sub); border-color: transparent; }
.ap-desc .ap-field:hover { background: var(--panel); border-color: color-mix(in srgb, var(--accent) 55%, var(--line)); }
.ap-desc .ap-copy { font-size: 13px; }
.ap-backup > summary {
  list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--muted);
  padding: 6px 14px; border: 1px dashed var(--line); border-radius: 10px; margin-bottom: 14px;
}
.ap-backup > summary::-webkit-details-marker { display: none; }
.ap-backup > summary::before { content: '+'; font-weight: 700; color: var(--accent); }
.ap-backup[open] > summary::before { content: '−'; }

/* ---------- 自我评价 ---------- */
.ap-evals { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.ap-evals .ap-field { background: var(--panel); border-color: var(--line); padding: 12px 14px 14px; box-shadow: var(--shadow); }

/* ---------- JD 问答 ---------- */
.ap-qa-form { background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 18px 20px; box-shadow: var(--shadow); min-width: 0; }
.ap-qa-grid { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 18px; }
.ap-qa-left, .ap-qa-right { min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.ap-row { display: grid; gap: 10px; min-width: 0; }
.ap-row.three { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr); }
.ap-qa-form label { display: flex; flex-direction: column; gap: 5px; font-size: 12px; font-weight: 600; color: var(--muted); min-width: 0; }
.ap-qa-form input, .ap-qa-form select, .ap-qa-form textarea { font-size: 13.5px; font-weight: 400; background: var(--panel); border-color: var(--line); }
.ap-qa-form textarea { line-height: 1.7; resize: vertical; }
.ap-qa-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.ap-status { font-size: 12.5px; color: var(--muted); }

.ap-result { display: flex; flex-direction: column; gap: 16px; background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 18px 20px; box-shadow: var(--shadow); min-width: 0; }
.ap-fit { background: var(--accent-soft); border-radius: 12px; padding: 12px 16px; }
.ap-fit-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ap-fit-top b { font-family: var(--font-serif); font-size: 15px; }
.ap-fit p { margin: 8px 0 0; font-size: 13px; line-height: 1.75; }
.ap-badge { font-size: 11px; font-weight: 700; padding: 1px 10px; line-height: 18px; border-radius: 99px; background: var(--accent); color: var(--on-accent); }
.ap-link { font-size: 12px; color: var(--accent); cursor: pointer; text-decoration: none; margin-left: 4px; }
.ap-link:hover { text-decoration: underline; }
.ap-picks { margin-top: 8px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.ap-chip { font-size: 11.5px; padding: 1px 10px; line-height: 20px; border-radius: 99px; background: var(--panel); border: 1px solid var(--line); color: var(--ink); }
.ap-qa-fields { display: flex; flex-direction: column; gap: 10px; }
.ap-qa-fields .ap-field { background: var(--panel-sub); border-color: transparent; }
.ap-qa-fields .ap-field:hover { background: var(--panel); border-color: color-mix(in srgb, var(--accent) 55%, var(--line)); }
.ap-evid { margin: -4px 0 2px 4px; font-size: 12px; color: var(--muted); }
.ap-evid summary { cursor: pointer; color: var(--faint); }
.ap-evid ul { margin: 6px 0 0 18px; padding: 0; line-height: 1.7; }
.ap-gaps h3 { margin: 0 0 8px; font-size: 13px; color: var(--muted); letter-spacing: .04em; }
.ap-gap { display: flex; flex-direction: column; gap: 2px; padding: 8px 12px; background: var(--warn-soft); border-radius: 10px; margin-bottom: 8px; font-size: 12.5px; line-height: 1.65; }
.ap-gap b { color: var(--warn); }
.ap-gap span { color: var(--muted); }
.ap-result-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.ap-sets { display: flex; flex-wrap: wrap; gap: 8px; }
.ap-set { display: inline-flex; align-items: baseline; gap: 8px; border: 1px solid var(--line); background: var(--panel-sub); border-radius: 10px; padding: 6px 12px; cursor: pointer; font-size: 12.5px; color: var(--ink); max-width: 100%; }
.ap-set:hover { border-color: var(--accent); background: var(--accent-soft); }
.ap-set span { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.ap-set i { font-style: normal; color: var(--faint); font-size: 11px; }

/* ---------- 表格 / 检查清单 ---------- */
.ap-tablewrap { overflow-x: auto; }
.ap-table { border-collapse: collapse; width: 100%; font-size: 12.5px; }
.ap-table th, .ap-table td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--line); vertical-align: top; line-height: 1.65; }
.ap-table th { color: var(--muted); font-weight: 600; white-space: nowrap; font-size: 11.5px; letter-spacing: .04em; }
.ap-table tr:last-child td { border-bottom: 0; }

.ap-checks { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.ap-check { display: flex; align-items: flex-start; gap: 10px; padding: 9px 12px; border-radius: 10px; background: var(--panel-sub); cursor: pointer; font-size: 13px; line-height: 1.65; transition: background .15s; }
.ap-check:hover { background: var(--accent-soft); }
.ap-check input { flex: none; width: 17px; height: 17px; margin: 3px 0 0; }
.ap-check input:checked + span { color: var(--faint); text-decoration: line-through; text-decoration-color: color-mix(in srgb, var(--faint) 60%, transparent); }
.ap-check-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; }

/* ---------- 窄屏 ---------- */
@media (max-width: 860px) {
  .ap-qa-grid { grid-template-columns: 1fr; }
  .ap-row.three { grid-template-columns: 1fr; }
  .ap-desc, .ap-evals, .ap-checks { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .ap-top-text p { display: none; }
  .ap-top { padding: 8px 0; }
  .ap-nav { width: 100%; }
  .ap-chips { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ap-meta { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ap-item, .ap-qa-form, .ap-result { padding: 14px; }
  .ap-sec { margin-top: 26px; }
}
@media (prefers-reduced-motion: reduce) {
  .ap-field, .ap-flash, .ap-nav a, .ap-acts { transition: none; }
}

/* ---------- 自定义字段 ---------- */
.ap-add-open { margin-top: 12px; }
.ap-add-form { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; max-width: 560px; }
.ap-add-form input, .ap-add-form textarea, .ap-label-input { width: 100%; font-size: 13.5px; padding: 8px 10px; border: 1px solid var(--accent); border-radius: 10px; background: var(--panel); color: var(--ink); }
.ap-label-input { margin: 4px 0 6px; font-weight: 600; }
