/* Preserve production card sizes and positions; refine content only. */
h1,h2,h3 { text-wrap: balance; }
.order-table-head span:last-child { text-align: right; }
.order-item .delivery-date { display: flex; flex-direction: column; align-items: flex-end; justify-content: center; gap: 3px; width: 100%; white-space: nowrap; font-variant-numeric: tabular-nums; line-height: 1; }
.delivery-date .delivery-main { color: var(--ink); font-size: 13px; font-weight: 650; }
.delivery-date .delivery-year { color: var(--muted); font-size: 9px; font-weight: 400; }
.order-item { min-height: 34px; height: 34px; }
.order-table-head { font-size: 10px; }
.o-code { font-size: 10px; }
.o-cust { font-size: 11px; }
.panel-heading h2 small,.head-meta { font-variant-numeric: tabular-nums; }
.status-strip button { box-shadow: none; }
.status-strip button.is-active { box-shadow: inset 0 -2px currentColor; }
.panel-foot { font-variant-numeric: tabular-nums; }
.map-summary b,.attendance-stat b,.dept-bar b { font-variant-numeric: tabular-nums; }
.client-project-table td { vertical-align: middle; }
.notice-empty { flex: 1; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 10px; color: var(--muted); padding: 20px; text-align: center; }
.notice-empty[hidden] { display: none; }
.notice-empty b { color: var(--ink); font-size: 14px; font-weight: 500; }
.notice-empty p { font-size: 11px; margin: 0; text-wrap: pretty; }
.notice-list:empty { display: none; }
.preview-label { color: var(--accent); font-size: 9px; margin-left: 8px; }
@media (min-width:1501px) and (min-height:801px) {
 .delivery-date .delivery-main { font-size: 14px; }
 .delivery-date .delivery-year { font-size: 10px; }
 .order-table-head { font-size: 12px; }
 .o-code { font-size: 12px; } .o-cust { font-size: 13px; }
 .order-item { min-height: 38px; height: 38px; }
}
/* Keep the progress percentage readable inside the existing research card. */
.client-project-table td:last-child { position: relative; padding-bottom: 9px; text-overflow: clip; }
.client-project-table td:last-child .progress-inline { position: absolute; left: 5px; right: 5px; bottom: 5px; width: auto; height: 3px; margin: 0; }
.client-project-table th,.order-table-head { font-weight: 500; }
.notice-list b { line-height: 1.45; }
.notice-list small { line-height: 1.4; }
:root[data-theme="dark"] .sp12-card,
:root[data-theme="dark"] .sp3-card { --sp-ink: #dce8ef; --sp-muted: #9cb1c0; --sp-gray: #344b5a; --sp-gray-bar: #344b5a; }
:root[data-theme="dark"] .status-strip button.is-active { background: var(--surface); }
:root[data-theme="dark"] .icon-button { background: var(--surface); color: var(--ink); }

/* Four columns; released order-code space belongs to customer names. */
.order-table-head,.order-item { grid-template-columns: 18px minmax(0,1fr) 42px 54px; }
@media (max-width:1500px), (max-height:800px) {
 .order-table-head,.order-item { grid-template-columns: 14px minmax(0,1fr) 34px 50px; }
}

/* Five statuses fit within the existing fixed card. */
.status-strip { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
.status-strip .completed, .status-strip .completed b { color: var(--accent); }
.status.completed { color: var(--accent); background: var(--surface); }

.wecom-stage {display:flex;justify-content:space-between;font-size:10px;color:var(--muted);margin-top:10px;gap:6px}
.wecom-track {height:5px;background:var(--line);border-radius:3px;margin-top:7px;overflow:hidden}
.wecom-track i {display:block;height:100%;background:var(--accent)}
.wecom-period {font-size:9px;color:var(--muted);margin-top:7px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-variant-numeric:tabular-nums}
.wecom-empty {color:var(--muted);text-align:center;padding:12px}

.client-project-table tbody tr {height:58px}
.client-project-table td.wecom-project-cell {text-align:left;font-family:inherit;font-weight:400;color:var(--data-ink);white-space:normal}
.wecom-project-cell > b {display:block;font-size:11px;line-height:1.4;max-height:31px;overflow:hidden;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}
.wecom-row-meta {display:flex;justify-content:space-between;gap:5px;color:var(--muted);font-size:9px;line-height:1.5;margin-top:3px}
.client-project-table th:nth-child(2) {text-align:left}
.wecom-project .sp3-pct {color:var(--accent)}
.strategic-list.is-scrolling > .wecom-project {flex:none;height:var(--sp-card-h);box-sizing:border-box}
@media(min-width:1400px) {.wecom-project-cell > b {font-size:12px;max-height:34px}.wecom-row-meta {font-size:10px}}

.wecom-segments {display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;margin-top:9px}
.wecom-segment span {display:block;font-size:10px;color:var(--muted);margin-bottom:6px;white-space:nowrap}
.wecom-segment.is-current span {color:var(--accent);font-weight:700}
.wecom-segment-track {height:6px;border-radius:2px;background:var(--line);overflow:hidden}
.wecom-segment-track i {display:block;height:100%;background:var(--accent)}
.wecom-segment.is-done .wecom-segment-track i {opacity:.5}
.wecom-current-value {display:flex;align-items:baseline;gap:5px;white-space:nowrap}
.wecom-current-value small {font-size:9px;font-weight:400;color:var(--muted)}
.wecom-project .wecom-period {margin-top:5px}

/* Shared research progress design: all projects use the same three-stage language. */
.wecom-current-value {flex-direction:column;align-items:flex-end;gap:2px;line-height:1}
.wecom-current-value .sp3-pct {font-size:18px;font-weight:700;font-variant-numeric:tabular-nums;color:var(--accent)}
.wecom-current-value small {font-size:8px;line-height:1.2}
.wecom-project .sp-head {align-items:start;gap:8px}
.wecom-project .sp-name {white-space:normal;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;line-height:1.4;max-height:34px}
.wecom-segments {gap:6px;margin-top:5px}
.wecom-segment span {font-size:9px;margin-bottom:5px}
.wecom-segment-track {height:7px;border-radius:3px}
.wecom-segment.is-current .wecom-segment-track {outline:1px solid var(--accent);outline-offset:1px}
.client-project-table {width:calc(100% - 20px);margin:0 10px}
.client-project-table thead {display:none}
.client-project-table tbody tr {height:68px}
.client-project-table td.wecom-project-cell {padding:0;text-align:left;font-family:inherit;background:transparent}
.client-project-table .wecom-project {height:68px;box-sizing:border-box;padding:6px 0;gap:2px;border:0;border-bottom:1px solid var(--line);border-radius:0;display:grid;grid-template-columns:minmax(0,1fr);justify-content:stretch;align-content:start}
.client-project-table .wecom-project .sp-name {font-size:11px;color:var(--data-ink)}
.client-project-table .wecom-period {font-size:8px;line-height:1.3;margin-top:3px;font-weight:400;text-align:left}
.client-project-table .wecom-current-value .sp3-pct {font-size:16px}
.client-project-table tbody tr:nth-child(odd) {background:transparent}

/* Distinguish project groups without changing the dashboard card geometry. */
#researchMeta {display:none}
.wecom-segment-pct {display:none}
.strategic-projects {border-left:3px solid #d44952;background:var(--research-card)}
.strategic-projects .research-card-head {background:transparent;border-bottom:1px solid var(--line)}
.strategic-projects .research-card-head h3 {color:#d44952;font-weight:750}
.client-projects {border-left:3px solid var(--accent)}
.client-projects .research-card-head {background:color-mix(in srgb,var(--surface) 90%,var(--accent) 10%);border-bottom:1px solid var(--line)}
.client-projects .research-card-head h3 {color:var(--accent);font-weight:700}
.client-project-table .wecom-current-value {display:none}
.client-project-table .sp-head {grid-template-columns:minmax(0,1fr)}
.client-project-table .wecom-segment-track {height:3px;border-radius:2px}
.client-project-table .wecom-segment.is-current .wecom-segment-track {outline:0}
.client-project-table .wecom-segment > span {display:flex;align-items:baseline;justify-content:space-between;gap:2px;margin-bottom:5px}
.client-project-table .wecom-segment-pct {display:inline;font-size:12px;line-height:1;font-variant-numeric:tabular-nums;color:var(--accent)}
.client-project-table .wecom-segments {margin-top:5px}

.strategic-projects .wecom-segment-track i {background:#d44952}
.strategic-projects .wecom-segment.is-current .wecom-segment-track {outline-color:#d44952}
.strategic-projects .wecom-segment.is-current span,.strategic-projects .wecom-current-value .sp3-pct {color:#d44952}

/* Reading-first motion: grouped slides, quiet progress entrance, static reduced-motion fallback. */
.research-paged {animation:none !important;will-change:transform}
.wecom-segment-track i {transform-origin:left;animation:researchProgressReveal 420ms cubic-bezier(.22,.61,.36,1) both}
.wecom-segment:nth-child(2) .wecom-segment-track i {animation-delay:40ms}
.wecom-segment:nth-child(3) .wecom-segment-track i {animation-delay:80ms}
@keyframes researchProgressReveal {from {transform:scaleX(0)} to {transform:scaleX(1)}}
#researchToggle {transition:background-color 150ms ease,border-color 150ms ease}
#researchToggle[aria-pressed="true"] {background:color-mix(in srgb,var(--surface) 88%,var(--accent) 12%);border-color:var(--accent)}
@media(prefers-reduced-motion:reduce) {
 .research-paged {transform:none !important;will-change:auto}
 .wecom-segment-track i {animation:none}
 #researchToggle {transition:none}
 .client-project-viewport,.strategic-viewport {overflow-y:auto}
 .research-paged > [data-carousel-clone] {display:none}
}

/* Global dashboard motion: steady reading, bounded entrances, no ambient loops. */
:root {--motion-fast:150ms;--motion-update:260ms;--motion-enter:420ms;--motion-ease:cubic-bezier(.22,.61,.36,1)}
.panel {animation:dashboardEnter var(--motion-enter) var(--motion-ease) backwards}
.map-panel {animation-delay:40ms}
.project-panel {animation-delay:80ms}
.attendance-panel {animation-delay:120ms}
.people-panel {animation-delay:160ms}
.notice-panel {animation-delay:200ms}
@keyframes dashboardEnter {from {opacity:0;transform:translateY(5px)} to {opacity:1;transform:none}}
.dept-bar .bar-bg i {transform-origin:bottom;animation:dashboardBarEnter 420ms var(--motion-ease) both}
@keyframes dashboardBarEnter {from {transform:scaleY(0)} to {transform:scaleY(1)}}
.map-point .pulse {animation:none;opacity:0}
.map-point:hover .pulse,.map-point:focus-visible .pulse {animation:mapPulse 600ms ease-out 1}
.map-point .marker-content,.map-point .bubble {transition-duration:var(--motion-update);transition-timing-function:var(--motion-ease)}
.icon-button,.status-strip button,.switcher button,.map-controls button {transition:color var(--motion-fast) ease,background-color var(--motion-fast) ease,border-color var(--motion-fast) ease}
.icon-button[aria-pressed="true"] {background:color-mix(in srgb,var(--surface) 88%,var(--accent) 12%);border-color:var(--accent)}
.att-modal__panel {animation:dashboardEnter 200ms var(--motion-ease)}
#orderViewport:focus-visible,.client-project-viewport:focus-visible,.strategic-viewport:focus-visible {outline:2px solid var(--accent);outline-offset:-2px}
@media(prefers-reduced-motion:reduce) {
 *,*::before,*::after {animation:none !important;transition:none !important;scroll-behavior:auto !important}
 #orderViewport,.client-project-viewport,.strategic-viewport {overflow-y:auto}
 .research-paged > [data-carousel-clone] {display:none}
 .research-paged {transform:none !important}
}

/* Map refinement: reserve separate areas for heading, geographic labels and controls. */
.map-stage {inset:66px 12px 52px;background:transparent}
.map-stage::before {background:none}
.map-panel {background:var(--map-ocean)}
.map-panel-heading > div:first-child {background:transparent;border:0;box-shadow:none;backdrop-filter:none;padding:3px 2px}
.map-summary span {box-shadow:none;background:var(--surface);backdrop-filter:none}
.map-controls {top:auto;right:auto;left:12px;bottom:10px;width:auto;display:flex;flex-direction:row;align-items:center;gap:5px;z-index:9}
.map-controls button {flex:0 0 32px;width:32px;height:32px;box-shadow:none;backdrop-filter:none}
.map-controls output {position:static;clip-path:none;width:auto;height:32px;overflow:visible;min-width:42px;font-size:10px;color:var(--muted);font-variant-numeric:tabular-nums}
.map-note {right:12px;bottom:10px;height:32px;box-shadow:none;background:transparent;border:0;backdrop-filter:none;padding:0;font-size:9px}
.map-note .map-view-label {display:flex;color:var(--muted)}
.map-silhouette-depth {opacity:.12}
.map-point .point-card-surface {filter:none;stroke-width:1}
.map-point .point-card-title {font-weight:600}
.map-point .point-card-leader {stroke-dasharray:none;opacity:.5}
.map-point .point-ring {filter:none}
.map-point .bubble {filter:none}
@media(max-width:1200px) {.map-note .map-view-label {display:none}}
