/* Compact attendance entry and sticky collapse control for small screens. */
/* The source card is intentionally removed from the employee view. The full policy below is the single entry point. */
button,
a,
summary,
.card,
.section {
  -webkit-tap-highlight-color: transparent;
}

/* The temporary source-check footer is not part of the employee-facing chapter flow. */
#detail + .foot {
  display: none;
}

button:focus:not(:focus-visible),
a:focus:not(:focus-visible),
summary:focus:not(:focus-visible) {
  outline: none;
}

/* Use one triangle treatment for every SOP section instead of mixing native markers and custom markers. */
.section > summary {
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
}

.section > summary::-webkit-details-marker {
  display: none;
}

.section > summary::before {
  content: "";
  flex: 0 0 auto;
  width: 0;
  height: 0;
  border-top: 7px solid transparent;
  border-bottom: 7px solid transparent;
  border-left: 10px solid var(--ink);
  transition: transform 180ms ease;
}

.section[open] > summary::before {
  transform: rotate(90deg);
}

details.is-animating {
  overflow: hidden;
  transition: height 260ms cubic-bezier(0.22, 0.8, 0.24, 1);
}

/* Shared touch feedback keeps buttons, cards, pills and disclosure rows feeling connected. */
button,
a,
summary,
.card,
.quick-ball,
.quick-menu button,
.pills button {
  transition: transform 160ms ease, background-color 180ms ease, border-color 180ms ease, box-shadow 180ms ease, color 180ms ease;
}

button:active,
.card:active,
.quick-ball:active,
.quick-menu button:active,
.pills button:active {
  transform: scale(0.985);
}

@media (prefers-reduced-motion: no-preference) {
  .pills button.pill-activating {
    animation: sopPillActivate 360ms cubic-bezier(0.22, 0.8, 0.24, 1) both;
  }

  .pills button.on {
    animation: sopPillSelect 220ms cubic-bezier(0.22, 0.8, 0.24, 1) both;
  }

  .section[open] > .body,
  .section[open] > .sales-body,
  .people-item[open] > .people-item-body,
  .attendance-policy-details[open] > .policy-copy {
    animation: sopContentReveal 220ms cubic-bezier(0.22, 0.8, 0.24, 1) both;
    transform-origin: top center;
  }

  @keyframes sopContentReveal {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 1; transform: translateY(0); }
  }

  @keyframes sopPillSelect {
    from { transform: scale(0.96); box-shadow: 0 0 0 rgba(8, 119, 68, 0); }
    to { transform: scale(1); box-shadow: 0 4px 12px rgba(8, 119, 68, 0.16); }
  }

  @keyframes sopPillActivate {
    0% { transform: scale(0.97); box-shadow: 0 0 0 rgba(8, 119, 68, 0); }
    55% { transform: scale(1.035); box-shadow: 0 5px 16px rgba(8, 119, 68, 0.2); }
    100% { transform: scale(1); box-shadow: 0 4px 12px rgba(8, 119, 68, 0.16); }
  }
}

@media (prefers-reduced-motion: reduce) {
  button,
  a,
  summary,
  .card,
  .quick-ball,
  .quick-menu button,
  .pills button {
    transition: none !important;
  }

  button:active,
  .card:active,
  .quick-ball:active,
  .quick-menu button:active,
  .pills button:active {
    transform: none;
  }
}

.attendance-doc {
  display: none !important;
}

.people-intro {
  margin: 0 0 12px;
  color: var(--muted);
}

.people-grid {
  display: grid;
  gap: 10px;
}

.people-item {
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
}

.people-item > summary {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 54px;
  padding: 10px 14px;
  cursor: pointer;
  list-style: none;
}

.people-item > summary::-webkit-details-marker {
  display: none;
}

.people-item > summary::after {
  content: "+";
  margin-left: auto;
  color: var(--muted);
  font-size: 20px;
  font-weight: 400;
}

.people-item[open] > summary::after {
  content: "−";
}

.people-item-body {
  padding: 0 14px 13px;
  border-top: 1px solid #edf0f2;
}

.people-item-confirmed,
.people-item-redline {
  border-left: 1px solid var(--line);
}

.people-item-redline {
  background: #fffafb;
}

.people-item-head {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.people-item-head b {
  font-size: 15px;
}

/* The source-verification label is internal review metadata, not employee-facing copy. */
.people-item-head .status {
  display: none !important;
}

.people-item .status {
  margin-left: auto;
}

.people-item p,
.people-item ul {
  margin: 7px 0 0;
}

.people-item ul {
  padding-left: 20px;
}

.people-item li {
  margin: 5px 0;
}

.people-item h3 {
  margin: 12px 0 0;
  font-size: 13px;
  color: var(--green);
}

.people-group + .people-group {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid #edf0f2;
}

.people-group h3 {
  margin-top: 0;
}

.sales-section {
  margin-top: 14px;
}

.sales-section > summary {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 18px;
}

.sales-section > summary::before,
.people-item > summary::before {
  content: "";
  flex: 0 0 auto;
  width: 0;
  height: 0;
  border-top: 7px solid transparent;
  border-bottom: 7px solid transparent;
  border-left: 10px solid var(--ink);
  transition: transform 180ms ease;
}

.sales-section[open] > summary::before,
.people-item[open] > summary::before {
  transform: rotate(90deg);
}

.sales-body {
  padding: 0 12px 8px;
}

.sales-subsection {
  margin: 10px 0;
}

.sales-group + .sales-group {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid #edf0f2;
}

.sales-group h3 {
  margin: 0 0 6px;
  color: var(--green);
  font-size: 15px;
}

.sales-group ul {
  margin: 0;
  padding-left: 20px;
}

.sales-group li {
  margin: 4px 0;
}

.sales-pending {
  margin: 0;
  color: var(--muted);
  font-weight: 700;
}

.complaint-core { padding: 2px 0 4px; }
.complaint-core p { margin: 7px 0; }
.complaint-sheet { font-size: 14px; line-height: 1.7; }
.complaint-definition { margin: 7px 0 12px; }
.complaint-group + .complaint-group { margin-top: 16px; padding-top: 12px; border-top: 1px solid #edf0f2; }
.complaint-group h3 { margin: 0 0 7px; color: var(--green); font-size: 15px; }
.complaint-group p { margin: 0; }
.complaint-group ul { margin: 0; padding-left: 20px; }
.complaint-group li { margin: 6px 0; }
.complaint-group li b { color: var(--ink); }
.complaint-resources { display: grid; gap: 10px; margin-top: 14px; }
.complaint-resource {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 58px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--ink);
  text-decoration: none;
  background: #fff;
  cursor: pointer;
}
.complaint-resource:hover,
.complaint-resource:focus-visible { border-color: #9bcab4; background: #fbfefc; }
.complaint-resource-icon {
  display: grid;
  place-items: center;
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  border-radius: 9px;
  color: #fff;
  font-size: 18px;
}
.complaint-slide .complaint-resource-icon { background: #f19a3e; }
.complaint-doc .complaint-resource-icon { background: #4a8fd6; }
.complaint-resource b,
.complaint-resource small { display: block; }
.complaint-resource b { font-size: 14px; }
.complaint-resource small { margin-top: 2px; color: var(--muted); font-size: 11px; }
.complaint-resource-arrow { margin-left: auto; color: var(--green); font-size: 18px; }

.reception-section { margin-top: 10px; }
.reception-section > .reception-body { padding: 0 0 7px !important; }
.reception-section .reception-item { width: 100%; margin: 10px 0 0 !important; border: 1px solid var(--line); border-radius: 10px; background: #fff; overflow: hidden; }
#reception-section > summary,
#reception-section .reception-item > summary {
  display: grid;
  grid-template-columns: 18px 56px minmax(0, 1fr);
  column-gap: 8px;
  align-items: center;
  min-height: 44px;
  padding: 7px 9px;
  cursor: pointer;
  list-style: none;
  font-weight: 700;
  font-size: 16px;
  line-height: 1.25;
}
#reception-section > summary::-webkit-details-marker,
#reception-section .reception-item > summary::-webkit-details-marker { display: none; }
#reception-section > summary::before,
#reception-section .reception-item > summary::before {
  content: "";
  width: 0;
  height: 0;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  border-left: 9px solid var(--ink);
  transition: transform 180ms ease;
}
#reception-section[open] > summary::before,
#reception-section .reception-item[open] > summary::before { transform: rotate(90deg); }
#reception-section > summary .badge,
#reception-section .reception-item > summary .badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  min-width: 56px;
  height: 30px;
  padding: 0 4px;
  flex: 0 0 56px;
  border-radius: 8px;
  text-align: center;
  white-space: nowrap;
}

/* Keep every second-level SOP label visually distinct from its green parent module. */
.sales-subsection > summary .badge,
.people-item > summary .badge,
.reception-item > summary .badge {
  background: #edf3fb;
  color: #3f6f9f;
}

.people-item > summary .badge.red {
  background: #fff0f1;
  color: var(--red);
}
.policy-chapter {
  margin: 10px 0;
  border: 1px solid #e3e9ee;
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
}
.policy-chapter > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 42px;
  padding: 9px 12px;
  cursor: pointer;
  list-style: none;
  color: var(--ink);
  font-weight: 800;
}
.policy-chapter > summary::-webkit-details-marker { display: none; }
.policy-chapter-mark {
  color: var(--muted);
  font-size: 18px;
  font-weight: 400;
  transition: transform 180ms ease;
}
.policy-chapter[open] > summary { color: var(--green); }
.policy-chapter[open] .policy-chapter-mark { transform: rotate(45deg); color: var(--green); }
.policy-chapter-body {
  padding: 2px 12px 12px;
  border-top: 1px solid #edf0f2;
}
.policy-chapter-body > :first-child { margin-top: 9px; }
.policy-chapter-body h5 { display: none; }
.reception-item-body { padding: 0 9px 10px; border-top: 1px solid #edf0f2; font-size: 14px; line-height: 1.65; }
.reception-item-body p { margin: 9px 0 0; }
.reception-item-body ul { margin: 9px 0 0; padding-left: 20px; }
.reception-item-body li { margin: 6px 0; }
.reception-rule + .reception-rule { margin-top: 12px; padding-top: 10px; border-top: 1px solid #edf0f2; }
.reception-rule h3 { margin: 10px 0 4px; color: var(--green); font-size: 14px; }
.reception-rule p { margin: 0; }
.reception-source { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; padding: 10px 12px; border: 1px solid #b7dcca; border-radius: 9px; color: var(--green); background: #fbfefc; font-size: 13px; font-weight: 700; text-decoration: none; }
.reception-source span { font-size: 17px; }

/* 1.5.0 is the reference frame for every first-level SOP entry. */
.section > summary {
  display: grid;
  grid-template-columns: 18px 56px minmax(0, 1fr);
  column-gap: 8px;
  align-items: center;
  min-height: 52px;
  padding: 8px 9px;
  font-size: 16px;
  line-height: 1.25;
}
.section > summary .badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  min-width: 56px;
  height: 30px;
  padding: 0 4px;
  flex: 0 0 56px;
  border-radius: 8px;
  white-space: nowrap;
  text-align: center;
}
.section > summary::before,
#reception-section > summary::before,
#reception-section .reception-item > summary::before {
  justify-self: center;
  align-self: center;
  margin: 0 !important;
  border-top-width: 6px;
  border-bottom-width: 6px;
  border-left-width: 9px;
}

/* Final alignment lock: every first-level arrow uses the same grid as 1.5.0. */
#detail .section > summary,
#reception-section > summary {
  display: grid !important;
  grid-template-columns: 18px 56px minmax(0, 1fr) !important;
  column-gap: 8px !important;
  align-items: center !important;
  min-height: 52px !important;
  padding: 8px 9px !important;
  font-size: 16px !important;
  line-height: 1.25 !important;
}
#detail .section > summary::before,
#reception-section > summary::before {
  justify-self: center !important;
  align-self: center !important;
  width: 0 !important;
  height: 0 !important;
  border-top: 6px solid transparent !important;
  border-bottom: 6px solid transparent !important;
  border-left: 9px solid var(--ink) !important;
}
#detail .section > summary .badge,
#reception-section > summary .badge {
  width: 56px !important;
  min-width: 56px !important;
  height: 30px !important;
  min-height: 30px !important;
  padding: 0 4px !important;
  flex: 0 0 56px !important;
  border-radius: 8px !important;
}
#detail .appearance-body > .appearance-group {
  margin-top: 14px;
}
#detail .appearance-body > .appearance-group > h3 {
  display: flex;
  align-items: center;
  min-height: 44px;
  margin: 0 0 10px;
  padding: 8px 12px;
  border-left: 3px solid var(--green);
  border-radius: 6px;
  background: #edf7f1;
}
#detail .appearance-standalone-body {
  display: grid;
  gap: 8px;
  padding: 10px 9px !important;
}
@media (max-width: 850px) {
  #detail .section > summary,
  #reception-section > summary {
    grid-template-columns: 16px 52px minmax(0, 1fr) !important;
    column-gap: 7px !important;
  }
  #detail .section > summary .badge,
  #reception-section > summary .badge {
    width: 52px !important;
    min-width: 52px !important;
    height: 28px !important;
    min-height: 28px !important;
    flex-basis: 52px !important;
  }
  #detail .section > summary,
  #reception-section > summary {
    font-size: 14px !important;
    line-height: 1.2 !important;
  }
}

@media (max-width: 850px) {
  .complaint-sheet { font-size: 13px; line-height: 1.65; }
  .complaint-group h3 { font-size: 14px; }
  .complaint-group li { margin: 5px 0; }
  .reception-section > .reception-body { padding: 0 0 7px !important; }
  .reception-item-body { font-size: 13px; }
  #reception-section > summary,
  #reception-section .reception-item > summary {
    grid-template-columns: 16px 52px minmax(0, 1fr);
    column-gap: 7px;
    min-height: 52px;
    padding: 8px 9px;
    font-size: 14px;
    line-height: 1.2;
  }
  #reception-section > summary .badge,
  #reception-section .reception-item > summary .badge {
    width: 52px;
    min-width: 52px;
    height: 28px;
    flex-basis: 52px;
    border-radius: 8px;
  }
  .policy-chapter { margin: 8px 0; border-radius: 9px; }
  .policy-chapter > summary { min-height: 40px; padding: 8px 10px; font-size: 14px; }
  .policy-chapter-body { padding: 1px 10px 10px; }
  .section > summary {
    grid-template-columns: 16px 52px minmax(0, 1fr);
    column-gap: 7px;
    min-height: 52px;
    padding: 8px 9px;
    font-size: 14px;
    line-height: 1.2;
  }
  .section > summary .badge {
    width: 52px;
    min-width: 52px;
    height: 28px;
    flex-basis: 52px;
    border-radius: 8px;
  }
}

@media (max-width: 850px) {
  .people-item {
    border-radius: 9px;
  }

  .people-item > summary {
    min-height: 48px;
    padding: 8px 12px;
  }

  .people-item-body {
    padding: 0 12px 11px;
  }

  .people-item-head {
    gap: 6px;
  }

  .people-item-head b {
    font-size: 14px;
  }

  .people-item .status {
    width: 100%;
    margin-left: 0;
  }

  .sales-section {
    margin-top: 10px;
  }

  .sales-section > summary {
    font-size: 17px;
  }

  .sales-body {
    padding: 0 4px 6px;
  }

  .sales-subsection {
    margin: 8px 0;
  }

  .sales-subsection summary {
    padding: 12px 13px;
    font-size: 14px;
  }

  .sales-subsection .body {
    padding: 0 13px 14px;
    font-size: 13px;
    line-height: 1.55;
  }

  .sales-group + .sales-group {
    margin-top: 12px;
    padding-top: 10px;
  }

  .sales-group h3 {
    font-size: 13px;
  }

  .attendance-doc {
    min-height: 0 !important;
    height: 58px !important;
    padding: 7px 10px !important;
    gap: 9px !important;
    border-radius: 9px !important;
  }

  .attendance-doc-icon {
    width: 30px !important;
    height: 30px !important;
    border-radius: 9px !important;
    font-size: 16px !important;
  }

  .attendance-doc b {
    font-size: 13px !important;
    line-height: 1.15 !important;
  }

  .attendance-doc small {
    font-size: 10px !important;
    line-height: 1.1 !important;
  }

  .attendance-policy-details {
    margin-top: 8px !important;
    border-radius: 9px !important;
    overflow: hidden !important;
  }

  .attendance-policy-details summary {
    min-height: 48px !important;
    padding: 8px 11px !important;
    border-radius: 9px !important;
    font-size: 13px !important;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    transition: background-color 180ms ease, box-shadow 220ms ease, transform 160ms ease;
  }

  .attendance-policy-details summary:active {
    background: #f1f7f4 !important;
  }

  .attendance-policy-details[open] summary {
    position: relative !important;
    background: rgba(255, 255, 255, 0.98);
    border-radius: 9px 9px 0 0 !important;
    box-shadow: 0 3px 10px rgba(23, 32, 51, 0.08);
  }

  .attendance-policy-details[open] {
    overflow: hidden !important;
  }

  .attendance-policy-details[open] .attendance-policy-hint {
    font-size: 0;
  }

  .attendance-policy-details[open] .attendance-policy-hint::after {
    content: "收起全文";
    color: var(--muted);
    font-size: 11px;
  }

  .policy-copy {
    padding: 2px 11px 14px !important;
    font-size: 13px !important;
    line-height: 1.65 !important;
    transition: height 280ms cubic-bezier(0.22, 0.8, 0.24, 1), opacity 180ms ease-out, transform 280ms cubic-bezier(0.22, 0.8, 0.24, 1);
    animation: none !important;
    will-change: height, opacity, transform;
  }

  .attendance-policy-details[open] .policy-copy {
    animation: attendancePolicyReveal 220ms ease-out both;
    transform-origin: top center;
  }

  @keyframes attendancePolicyReveal {
    from { opacity: 0; transform: translateY(-2px); }
    to { opacity: 1; transform: translateY(0); }
  }

  @media (prefers-reduced-motion: reduce) {
    .attendance-policy-details[open] .policy-copy {
      animation-duration: 140ms;
    }
  }

  .attendance-policy-collapse {
    display: none;
    position: fixed;
    right: 14px;
    bottom: calc(24px + env(safe-area-inset-bottom));
    z-index: 85;
    min-height: 46px;
    padding: 0 15px;
    border: 1px solid #b7dcca;
    border-radius: 23px;
    background: rgba(255, 255, 255, 0.98);
    color: var(--green);
    box-shadow: 0 8px 20px rgba(23, 32, 51, 0.16);
    font: 700 13px/1 inherit;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    transition: transform 160ms ease, box-shadow 220ms ease, background-color 180ms ease;
  }

  .attendance-policy-collapse.is-visible {
    display: block;
  }

  body:has(#detail:not(.hidden) #attendance-policy-detail[open]) .attendance-policy-collapse {
    display: block;
  }

  /* Keep the draggable shortcut above the fixed header so it can always be recovered. */
  .quick-ball {
    z-index: 96 !important;
  }

  .quick-menu {
    z-index: 97 !important;
  }

  .attendance-policy-collapse:active {
    transform: scale(0.97);
    background: #f1f7f4;
  }
}

/* Compact second-level entries to the 1.5.1 reference spacing. */
.people-grid { gap: 0; }
#people-section > .body {
  padding-left: 10px !important;
  padding-right: 10px !important;
  padding-bottom: 8px !important;
}
.people-item,
.sales-subsection,
.reception-section .reception-item {
  width: 100%;
  margin: 4px 0 !important;
}
.sales-subsection > summary { height: 48px; min-height: 48px; }
.people-item > summary,
.reception-section .reception-item > summary {
  display: grid;
  grid-template-columns: 18px 56px minmax(0, 1fr);
  column-gap: 4px;
  align-items: center;
  min-height: 48px;
  padding: 8px 9px;
  font-size: 16px;
  line-height: 1.25;
  height: 48px;
}
.people-item > summary { grid-template-columns: 18px 56px minmax(0, 1fr) 20px; }
.people-item > summary::before { grid-column: 1; grid-row: 1; }
.people-item > summary .badge { grid-column: 2; grid-row: 1; align-self: center; }
.people-item > summary b { grid-column: 3; grid-row: 1; min-width: 0; line-height: 1.25; }
.people-item > summary::after { grid-column: 4; grid-row: 1; justify-self: end; margin-left: 0; }
.people-item > summary::before,
.reception-section .reception-item > summary::before {
  justify-self: center;
  margin: 0 !important;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  border-left: 9px solid var(--ink);
}
.people-item > summary .badge,
.reception-section .reception-item > summary .badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  min-width: 56px;
  height: 30px;
  min-height: 30px;
  padding: 0 4px;
  flex: 0 0 56px;
  border-radius: 8px;
  white-space: nowrap;
}
@media (max-width: 850px) {
  .people-item > summary,
  .reception-section .reception-item > summary {
    grid-template-columns: 16px 52px minmax(0, 1fr);
    column-gap: 4px;
    min-height: 48px;
    padding: 8px 9px;
    font-size: 14px;
    line-height: 1.2;
    height: 48px;
  }
  .people-item > summary { grid-template-columns: 16px 52px minmax(0, 1fr) 18px; }
  .people-item > summary::before { grid-column: 1; }
  .people-item > summary .badge { grid-column: 2; }
  .people-item > summary b { grid-column: 3; line-height: 1.2; }
  .people-item > summary .badge,
  .reception-section .reception-item > summary .badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    min-width: 52px;
    height: 28px;
    min-height: 28px;
    flex-basis: 52px;
  }
}
.people-intro { display: none !important; }

.parttime-section .parttime-item {
  display: grid;
  grid-template-columns: 18px 56px minmax(0, 1fr);
  column-gap: 4px;
  align-items: center;
  width: 100%;
  min-height: 48px;
  margin: 4px 0;
  padding: 8px 9px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  font-size: 16px;
  line-height: 1.25;
}
.parttime-item-mark {
  justify-self: center;
  width: 0;
  height: 0;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  border-left: 9px solid var(--ink);
}
.parttime-section .parttime-item .badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  min-width: 56px;
  height: 30px;
  padding: 0 4px;
  border-radius: 8px;
  background: #edf3fb;
  color: #3f6f9f;
  white-space: nowrap;
}
.parttime-section .parttime-item b { min-width: 0; }
@media (max-width: 850px) {
  .parttime-section .parttime-item {
    grid-template-columns: 16px 52px minmax(0, 1fr);
    column-gap: 4px;
    min-height: 48px;
    font-size: 14px;
    line-height: 1.2;
  }
  .parttime-section .parttime-item .badge {
    width: 52px;
    min-width: 52px;
    height: 28px;
  }
}

/* Tighten the detail-page header without changing module card proportions. */
#detail > .back { margin: 0 0 12px; }
#detail > .foot { margin: 0 0 14px; line-height: 1.35; }
#detail > h1 { margin: 0 0 10px; line-height: 1.15; }
#detail > .detail-layout { margin-top: 8px; }
#detail .detail-layout > section > .pills-helper {
  margin: 0 0 8px;
  line-height: 1.35;
}
#detail .detail-layout > section > .pills {
  margin-top: 0;
}
/* Keep the header compact even when the browser reports a wider CSS viewport. */
#detail > .back { margin-bottom: 4px !important; }
#detail > .foot { margin-top: 0 !important; margin-bottom: 6px !important; }
#detail > h1 { margin-top: 0 !important; margin-bottom: 0 !important; }
#detail > .detail-layout { margin-top: 0 !important; }
#detail .detail-layout > section > .pills-helper {
  margin: 0 !important;
  padding: 0 !important;
}
#detail .detail-layout > section > .pills { margin-top: 0 !important; }

/* Part-time subnodes are real disclosure rows, matching the 1.5.1 interaction. */
.parttime-section .parttime-item {
  display: block;
  min-height: 0;
  padding: 0;
  border: 1px solid var(--line);
}
.parttime-section .parttime-item > summary {
  display: grid;
  grid-template-columns: 18px 56px minmax(0, 1fr);
  column-gap: 4px;
  align-items: center;
  min-height: 48px;
  height: 48px;
  padding: 8px 9px;
  font-size: 16px;
  line-height: 1.25;
}
.parttime-section .parttime-item > summary .badge {
  grid-column: 2;
  grid-row: 1;
  align-self: center;
}
.parttime-section .parttime-item > summary::before {
  grid-column: 1;
  grid-row: 1;
  justify-self: center;
  margin: 0 !important;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  border-left: 9px solid var(--ink);
}
@media (max-width: 850px) {
  .parttime-section .parttime-item > summary {
    grid-template-columns: 16px 52px minmax(0, 1fr);
    min-height: 48px;
    height: 48px;
    font-size: 14px;
    line-height: 1.2;
  }
}

/* Anonymous text nodes can become a new grid item after the disclosure arrow.
   Keep the label in an explicit third column so long Chinese titles never stack vertically. */
.parttime-section > summary .parttime-title,
.parttime-section .parttime-item > summary .parttime-title {
  grid-column: 3;
  grid-row: 1;
  min-width: 0;
  display: block;
  overflow-wrap: anywhere;
  line-height: 1.25;
}
.parttime-key {
  color: inherit;
  font-weight: inherit;
}
/* The part-time reference uses the same full-width source box as 1.5.0. */
.parttime-reference-box {
  margin-top: 12px !important;
}
.parttime-section .parttime-item > summary::before {
  content: "";
  grid-column: 1;
  grid-row: 1;
  justify-self: center;
  align-self: center;
  width: 0;
  height: 0;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  border-left: 9px solid var(--ink);
  transition: transform 180ms ease;
}
.parttime-section .parttime-item[open] > summary::before {
  transform: rotate(90deg);
}

/* The extracted part-time policy is a separate disclosure row below 1.6.3. */
.parttime-section .parttime-policy-item > summary {
  grid-template-columns: 18px 56px minmax(0, 1fr);
}
.parttime-section .parttime-policy-body h3 {
  margin: 12px 0 6px;
  color: var(--green);
  font-size: 17px;
  line-height: 1.4;
  font-weight: 800;
}
.parttime-section .parttime-policy-body p {
  margin: 8px 0;
  line-height: 1.75;
}
.parttime-section .parttime-policy-body ul {
  margin: 8px 0 12px;
  padding-left: 28px;
}
.parttime-section .parttime-policy-body li {
  margin: 7px 0;
  line-height: 1.75;
}
@media (max-width: 850px) {
  .parttime-section .parttime-policy-body h3 { font-size: 16px; }
  .parttime-section .parttime-policy-body p,
  .parttime-section .parttime-policy-body li { line-height: 1.7; }
}

/* 1.7.0 follows the same first-level frame as 1.5.0. */
.discipline-section { margin-top: 10px; }
.discipline-body { padding: 0 9px 10px !important; }
.discipline-body ul {
  margin: 9px 0 0;
  padding-left: 28px;
  font-size: 16px;
  line-height: 1.75;
}
.discipline-body li {
  margin: 8px 0;
  line-height: 1.75;
}
.discipline-reference-box { margin-top: 12px !important; }
@media (max-width: 850px) {
  .discipline-body ul,
  .discipline-body li { font-size: 16px; line-height: 1.7; }
}

/* 1.8.0 and 1.9.0 use the same reading rhythm as the approved formal-copy template. */
.group-order-section,
.notice-section { margin-top: 10px; }
.group-order-body,
.notice-body { padding: 0 9px 10px !important; }
.group-order-reading + .group-order-reading {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid #edf0f2;
}
.group-order-reading h3 {
  margin: 10px 0 7px;
  color: var(--green);
  font-size: 18px;
  line-height: 1.4;
  font-weight: 800;
}
.group-order-reading ul,
.notice-body ul {
  margin: 0;
  padding-left: 28px;
  font-size: 16px;
  line-height: 1.75;
}
.group-order-reading li,
.notice-body li {
  margin: 8px 0;
  line-height: 1.75;
}
.group-order-flow { margin: 10px 0 0; }
.group-order-flow a { display: block; color: inherit; }
.group-order-flow img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid #edf0f2;
  border-radius: 6px;
  background: #fff;
}
.group-order-flow figcaption {
  margin-top: 7px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}
@media (max-width: 850px) {
  .group-order-reading h3 { font-size: 17px; }
  .group-order-reading ul,
  .notice-body ul,
  .group-order-reading li,
  .notice-body li { font-size: 16px; line-height: 1.7; }
  .group-order-flow { margin-top: 9px; }
  .group-order-flow figcaption { font-size: 12px; }
}

/* Formal SOP copy uses the same reading layout as the reference "复盘频次" block. */
#detail .attendance-rules,
#detail .reception-item-body,
#detail .people-group,
#detail .sales-group,
#detail .complaint-sheet {
  font-size: 16px;
  line-height: 1.75;
}
#detail .attendance-rules h3,
#detail .reception-rule h3,
#detail .people-group h3,
#detail .sales-group h3,
#detail .complaint-group h3 {
  margin: 0 0 8px;
  color: var(--green);
  font-size: 18px;
  line-height: 1.4;
  font-weight: 800;
}
#detail .attendance-rules ul,
#detail .attendance-alert ul,
#detail .reception-item-body ul,
#detail .people-item > ul,
#detail .people-group ul,
#detail .sales-group ul,
#detail .complaint-group ul {
  margin: 0;
  padding-left: 28px;
}
#detail .attendance-rules li,
#detail .attendance-alert li,
#detail .reception-item-body li,
#detail .people-item > ul li,
#detail .people-group li,
#detail .sales-group li,
#detail .complaint-group li {
  margin: 8px 0;
  line-height: 1.75;
}
#detail .reception-item-body p,
#detail .people-group p,
#detail .sales-group p,
#detail .complaint-sheet > p,
#detail .complaint-group > p {
  margin: 10px 0;
  line-height: 1.75;
}
@media (max-width: 850px) {
  #detail .attendance-rules,
  #detail .reception-item-body,
  #detail .people-group,
  #detail .sales-group,
  #detail .complaint-sheet {
    font-size: 16px;
    line-height: 1.7;
  }
  #detail .attendance-rules h3,
  #detail .reception-rule h3,
  #detail .people-group h3,
  #detail .sales-group h3,
  #detail .complaint-group h3 {
    font-size: 17px;
  }
  #detail .attendance-rules ul,
  #detail .attendance-alert ul,
  #detail .reception-item-body ul,
  #detail .people-item > ul,
  #detail .people-group ul,
  #detail .sales-group ul,
  #detail .complaint-group ul {
    padding-left: 25px;
  }
  #detail .attendance-rules li,
  #detail .attendance-alert li,
  #detail .reception-item-body li,
  #detail .people-item > ul li,
  #detail .people-group li,
  #detail .sales-group li,
  #detail .complaint-group li {
    margin: 7px 0;
    line-height: 1.7;
  }
}
@media (max-width: 850px) {
  #detail > .back { margin-bottom: 8px; }
  #detail > .foot { margin-bottom: 10px; font-size: 14px; }
  #detail > h1 { margin-bottom: 8px; font-size: 30px; }
  #detail > .detail-layout { margin-top: 4px; }
  #detail .detail-layout > section > .pills-helper { margin-bottom: 6px; font-size: 14px; }
}

#detail .wechat-body,
#detail .wechat-item-body {
  font-size: 16px;
  line-height: 1.75;
}
#detail .wechat-tools {
  padding: 0 4px 6px;
}
#detail .wechat-tools h3 {
  margin: 4px 0 6px;
  color: var(--green);
  font-size: 17px;
  line-height: 1.5;
}
#detail .wechat-tools ul {
  margin: 0;
  padding-left: 25px;
}
#detail .wechat-tools li {
  margin: 7px 0;
  line-height: 1.7;
}
#detail .wechat-tools .wechat-settings-link {
  margin-left: 6px;
  white-space: nowrap;
}
#detail .wechat-item {
  margin: 10px 0;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
}
#detail .wechat-item > summary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  min-height: 54px;
  padding: 10px 14px;
  cursor: pointer;
  list-style: none;
  font-weight: 700;
}
#detail .wechat-item > summary::-webkit-details-marker { display: none; }
#detail .wechat-item > summary::after {
  content: '▸';
  color: var(--green);
  transition: transform .22s ease;
}
#detail .wechat-item[open] > summary::after { transform: rotate(90deg); }
#detail .wechat-item-body {
  padding: 0 16px 16px;
}
#detail .wechat-item-body ul {
  margin: 0;
  padding-left: 25px;
}
#detail .wechat-item-body li {
  margin: 7px 0;
  line-height: 1.7;
}
#detail .wechat-item-body h3 {
  margin: 12px 0 2px;
  color: var(--green);
  font-size: 17px;
  line-height: 1.5;
}
#detail .wechat-item-body p {
  margin: 4px 0 8px;
}
#detail .wechat-settings-link {
  color: var(--green);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
#detail .wechat-settings-link:active { opacity: .72; }
#detail .training-flow {
  margin: 0;
}
#detail .training-flow a {
  display: block;
  color: inherit;
}
#detail .training-flow img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
}
#detail .training-new-hire > .wechat-item-body > p {
  margin: 8px 0;
}
#detail .training-principles {
  margin: 6px 0 10px;
  padding-left: 25px;
}
#detail .training-principles li {
  margin: 7px 0;
  line-height: 1.7;
}
#detail .training-schedule {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid #edf0f2;
}
#detail .training-schedule > h3 {
  margin: 0 0 8px;
}
#detail .training-reference-module {
  margin: 12px 4px 4px;
}
#detail .training-festival {
  margin-top: 10px;
}
#detail .training-table-group + .training-table-group {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid #edf0f2;
}
#detail .training-table-group > h3 {
  margin: 0 0 4px;
}
#detail .training-table-group > p {
  margin: 0 0 10px;
}
#detail .training-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  font-size: 14px;
  line-height: 1.65;
}
#detail .training-table th,
#detail .training-table td {
  padding: 9px 10px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  overflow-wrap: anywhere;
  word-break: break-word;
}
#detail .training-table tr > :last-child {
  border-right: 0;
}
#detail .training-table tbody tr:last-child > * {
  border-bottom: 0;
}
#detail .training-table thead th {
  background: var(--soft);
  color: var(--green);
  font-weight: 800;
}
#detail .training-table thead th:first-child,
#detail .training-table tbody th {
  width: 88px;
}
#detail .training-table tbody th {
  background: #fafcfb;
  color: var(--ink);
  font-weight: 700;
}
@media (max-width: 850px) {
  #detail .training-table {
    font-size: 13px;
    line-height: 1.6;
  }
  #detail .training-table th,
  #detail .training-table td {
    padding: 8px 9px;
  }
  #detail .training-table thead th:first-child,
  #detail .training-table tbody th {
    width: 78px;
  }
}
#detail .training-score {
  margin-top: 10px;
}
#detail .training-score-overview ul {
  margin: 6px 0 0;
}
#detail .training-score-rules,
#detail .training-check-template {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid #edf0f2;
}
#detail .training-score-rules > h3,
#detail .training-check-template > h3 {
  margin: 0 0 10px;
}
#detail .training-score-rules ol {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
#detail .training-score-rules li {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  gap: 9px;
  align-items: center;
  margin: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
#detail .training-score-index {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 7px;
  background: var(--soft);
  color: var(--green);
  font-size: 12px;
  font-weight: 800;
}
#detail .training-score-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}
#detail .training-score-copy b {
  line-height: 1.35;
}
#detail .training-score-copy small {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}
#detail .training-score-value {
  max-width: 84px;
  text-align: right;
  font-size: 13px;
  line-height: 1.4;
}
#detail .training-check-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
#detail .training-check-fields span {
  display: flex;
  align-items: center;
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fafcfb;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.4;
}
@media (max-width: 850px) {
  #detail .training-score-rules li {
    grid-template-columns: 26px minmax(0, 1fr) auto;
    gap: 7px;
    padding: 9px;
  }
  #detail .training-score-index {
    width: 26px;
    height: 26px;
  }
  #detail .training-score-copy small,
  #detail .training-score-value,
  #detail .training-check-fields span {
    font-size: 12px;
  }
}
#detail .training-day {
  margin: 8px 0;
}
#detail .training-rest-days {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  margin: 8px 0;
  padding: 8px 14px;
  border: 1px dashed #cbd8d0;
  border-radius: 10px;
  background: #f8faf9;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.4;
}
#detail .training-rest-days span {
  font-variant-numeric: tabular-nums;
}
#detail .training-rest-days b {
  color: var(--ink);
}
#detail .training-day > summary {
  align-items: start;
}
#detail .training-day-copy {
  display: grid;
  min-width: 0;
  gap: 5px;
}
#detail .training-day-copy > b {
  font-size: 15px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}
#detail .training-stage {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 12px;
  line-height: 1.45;
  font-weight: 700;
}
#detail .training-stage-entry {
  background: #f2eee5;
  color: #76521c;
}
#detail .training-stage-foundation {
  background: #e5f1e9;
  color: #245a3a;
}
#detail .training-stage-advanced {
  background: #e8f0fa;
  color: #315b84;
}
#detail .training-day-content {
  padding: 0 16px 14px;
}
#detail .training-day-content dl {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px 16px;
  margin: 0;
  padding-top: 2px;
}
#detail .training-day-content dl > div {
  display: contents;
}
#detail .training-day-content dt {
  color: var(--muted);
  font-size: 13px;
}
#detail .training-day-content dd {
  margin: 0;
  text-align: right;
  font-size: 14px;
  font-weight: 700;
}
#detail .wechat-reference-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  margin-top: 14px;
  padding: 13px 15px;
  border-radius: 10px;
  background: var(--soft);
  color: var(--green);
  font-weight: 700;
  text-decoration: none;
}
#detail .media-section { margin-top: 10px; }
#detail .media-section > .media-body { padding-bottom: 10px; }
#detail .media-item { margin: 8px 0; }
#detail .media-reference-box { margin-top: 12px; }
#detail .warehouse-section { margin-top: 10px; }
#detail .warehouse-body { padding: 0 9px 10px !important; }
#detail .warehouse-group { margin-top: 10px; }
#detail .warehouse-group + .warehouse-group { margin-top: 18px; }
#detail .warehouse-group > h3 {
  margin: 0 0 8px;
  color: var(--green);
  font-size: 17px;
  line-height: 1.45;
  font-weight: 800;
}
#detail .warehouse-group > h3 span { margin-right: 8px; }
#detail .warehouse-item {
  display: block;
  width: 100%;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
}
#detail .warehouse-item + .warehouse-item { margin-top: 8px; }
#detail .warehouse-direct-rules {
  margin: 0 0 10px;
  padding: 0 4px;
  font-size: 16px;
  line-height: 1.7;
}
#detail .warehouse-direct-rules ul {
  margin: 0;
  padding-left: 25px;
}
#detail .warehouse-direct-rules li { margin: 8px 0; }
#detail .warehouse-item > summary {
  display: grid;
  grid-template-columns: 16px 52px minmax(0, 1fr) 18px;
  column-gap: 4px;
  align-items: center;
  min-height: 48px;
  margin: 0;
  padding: 8px 9px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
  cursor: pointer;
  list-style: none;
  touch-action: manipulation;
  transition: background-color 180ms ease, border-color 180ms ease;
}
#detail .warehouse-item > summary::-webkit-details-marker { display: none; }
#detail .warehouse-item > summary::before {
  content: "";
  grid-column: 1;
  width: 0;
  height: 0;
  justify-self: center;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  border-left: 9px solid var(--ink);
}
#detail .warehouse-item > summary .badge {
  grid-column: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  min-width: 52px;
  height: 28px;
  padding: 0 4px;
  border-radius: 8px;
  background: #edf3fb;
  color: #3f6f9f;
  white-space: nowrap;
}
#detail .warehouse-item > summary span:last-child { grid-column: 3; min-width: 0; }
#detail .warehouse-item > summary::after {
  content: "▸";
  grid-column: 4;
  color: var(--green);
  justify-self: end;
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  transition: transform 180ms ease;
}
#detail .warehouse-item[open] > summary::after { transform: rotate(90deg); }
#detail .warehouse-item > summary:active {
  background: #f4f8f6;
}
#detail .warehouse-item-body {
  padding: 0 16px 16px;
  font-size: 16px;
  line-height: 1.7;
}
#detail .warehouse-item-body ul {
  margin: 0;
  padding-left: 25px;
}
#detail .warehouse-item-body li {
  margin: 8px 0;
  line-height: 1.7;
}
#detail .warehouse-item-body li p {
  margin: 8px 0 0;
}
#detail .warehouse-guide-entry {
  margin: 12px 0 0;
  line-height: 1.6;
}
#detail .warehouse-guide-entry a {
  color: var(--green);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
#detail .warehouse-reference-box {
  display: block;
  width: 100%;
  margin-top: 12px;
  padding: 13px 15px;
  border-radius: 10px;
  background: var(--soft);
  color: var(--green);
  font-weight: 700;
  line-height: 1.5;
  text-decoration: none;
}
#detail .warehouse-reference-box:active { background: #e6f1eb; }
#detail .appearance-module-reference {
  margin-top: 24px;
  padding-top: 15px;
  border-top: 1px solid #dce4ea;
}
@media (max-width: 850px) {
  #detail .appearance-module-reference .warehouse-reference-box {
    padding-right: 84px;
  }
}
#detail .appearance-reading + .appearance-reading {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid #edf0f2;
}
#detail .appearance-reading h3 {
  margin: 0 0 8px;
  color: var(--green);
  font-size: 17px;
  line-height: 1.45;
  font-weight: 800;
}
#detail .appearance-reading p {
  margin: 0 0 10px;
  line-height: 1.7;
}
#detail .appearance-reading ul {
  margin: 0;
  padding-left: 25px;
}
#detail .appearance-reading li {
  margin: 8px 0;
  line-height: 1.7;
}
#detail .cross-industry-reading + .cross-industry-reading {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid #edf0f2;
}
#detail .cross-industry-reading h3 {
  margin: 0 0 8px;
  color: var(--green);
  font-size: 17px;
  line-height: 1.45;
  font-weight: 800;
}
#detail .cross-industry-reading p {
  margin: 12px 0 4px;
  font-weight: 700;
  line-height: 1.6;
}
#detail .cross-industry-reading ul {
  margin: 0;
  padding-left: 25px;
}
#detail .cross-industry-reading li {
  margin: 7px 0;
  line-height: 1.7;
}
@media (max-width: 850px) {
  #detail .media-item { margin: 6px 0; }
  #detail .cross-industry-reading h3 { font-size: 16px; }
  #detail .warehouse-group > h3 { font-size: 16px; }
}
@media (max-width: 850px) {
  #detail .wechat-item-body { padding-left: 16px; padding-right: 16px; }
  #detail .wechat-item-body li { margin: 7px 0; }
  #detail .training-day-copy > b { font-size: 14px; }
  #detail .training-day-content dl { gap: 6px 12px; }
}
@media (min-width: 851px) {
  .mobile-bottom,
  #quickBall,
  #quickMenu,
  #searchBall,
  #searchPanel,
  #pillsDock,
  #attendance-policy-collapse {
    display: none !important;
  }
}
