/* Stack connection progress above the shops, keeping common desktop sizes compact. */
.portal-ui #workspace[data-view="overview"] .workspace-main { max-width: none; padding-bottom: 14px; }
.portal-ui #workspace[data-view="overview"] .context-bar { gap: 12px; padding-top: 12px; }
.portal-ui #workspace[data-view="overview"] .context-selection.is-enhanced { padding: 6px 10px; }
.portal-ui #workspace[data-view="overview"] .context-shop-trigger { min-height: 40px; padding: 4px 8px; }
.portal-ui #workspace[data-view="overview"] .workspace-scroll { padding-top: 12px; padding-bottom: 0; }
.portal-ui #workspace[data-view="overview"] .stats { gap: 10px; margin-bottom: 12px; }
.portal-ui #workspace[data-view="overview"] .stats > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 14px; border-radius: 12px; }
.portal-ui #workspace[data-view="overview"] .stats span { font-size: 13px; }
.portal-ui #workspace[data-view="overview"] .stats strong { margin-top: 0; font-size: 28px; line-height: 1.2; }
.portal-ui #workspace[data-view="overview"] .stats .text-stat { font-size: 20px; line-height: 1.4; }
.portal-ui #workspace[data-view="overview"] [data-panel="overview"] { display: grid; grid-template-columns: minmax(0,1fr); gap: 12px; align-items: start; }
.portal-ui #workspace[data-view="overview"] .stats { grid-column: 1; grid-row: 1; margin-bottom: 0; }
.portal-ui #workspace[data-view="overview"] .journey-card { grid-column: 1; grid-row: 2; padding: 14px 16px; margin-bottom: 0; border-radius: 14px; min-width: 0; }
.portal-ui #workspace[data-view="overview"] .shop-panel { grid-column: 1; grid-row: 3; min-width: 0; }
.portal-ui #workspace[data-view="overview"] .journey-details[hidden] { display: none !important; }
.portal-ui #workspace[data-view="overview"] .journey-tools { flex: none; gap: 8px; }
.portal-ui #workspace[data-view="overview"] .journey-tools button { min-height: 34px; padding: 6px 12px; font-size: 13px; white-space: nowrap; }
.portal-ui #workspace[data-view="overview"] .journey-card[data-complete="true"] { border-color: #cce7d9; }
.portal-ui #workspace[data-view="overview"] .journey-heading { gap: 10px; }
.portal-ui #workspace[data-view="overview"] .journey-heading h2 { font-size: 17px; line-height: 1.4; }
.portal-ui #workspace[data-view="overview"] .journey-status { padding: 3px 8px; font-size: 12px; }
.portal-ui #workspace[data-view="overview"] .journey-guide { margin-top: 12px; }
.portal-ui #workspace[data-view="overview"] .journey-guide h3 { font-size: 15px; }
.portal-ui #workspace[data-view="overview"] .journey-guide p { margin: 4px 0 8px; font-size: 13px; line-height: 1.55; }
.portal-ui #workspace[data-view="overview"] .journey-progress-count { font-size: 12px; }
.portal-ui #workspace[data-view="overview"] .journey-progress-count strong { font-size: 15px; }
.portal-ui #workspace[data-view="overview"] .journey-steps { gap: 8px; margin: 12px 0 10px; }
.portal-ui #workspace[data-view="overview"] .journey-steps button { min-height: 60px; padding: 8px 10px; gap: 8px; border-radius: 10px; font-size: 13px; }
.portal-ui #workspace[data-view="overview"] .journey-steps > li { display: flex; }
.portal-ui #workspace[data-view="overview"] .journey-steps b { min-width: 24px; line-height: 24px; }
.portal-ui #workspace[data-view="overview"] .journey-step-copy { gap: 2px; }
.portal-ui #workspace[data-view="overview"] .journey-current { margin-bottom: 4px; font-size: 13px; }
.portal-ui #workspace[data-view="overview"] .journey-client { gap: 8px; padding: 4px 0 8px; font-size: 13px; }
.portal-ui #workspace[data-view="overview"] .journey-client > div { gap: 10px; }
.portal-ui #workspace[data-view="overview"] .journey-client button { min-height: 32px; padding: 5px 10px; font-size: 13px; }
.portal-ui #workspace[data-view="overview"] .journey-next { gap: 12px; padding-top: 10px; }
.portal-ui #workspace[data-view="overview"] .journey-next > div { font-size: 13px; line-height: 1.55; }
.portal-ui #workspace[data-view="overview"] .journey-next .primary { min-height: 36px; padding: 7px 14px; font-size: 13px; }
.portal-ui #workspace[data-view="overview"] .section-heading { margin-bottom: 10px; }
.portal-ui #workspace[data-view="overview"] .section-heading h2 { font-size: 18px; }
.portal-ui #workspace[data-view="overview"] .shops { gap: 8px; }
.portal-ui #workspace[data-view="overview"] .shop { padding: 12px; border-radius: 14px; }
.portal-ui #workspace[data-view="overview"] .shop-heading { min-height: 32px; margin-bottom: 6px; gap: 8px; }
.portal-ui #workspace[data-view="overview"] .shop-heading strong { font-size: 16px; line-height: 22px; overflow-wrap: anywhere; }
.portal-ui #workspace[data-view="overview"] .platform-icon { width: 32px; height: 32px; }
.portal-ui #workspace[data-view="overview"] .platform-icon img { width: 28px; height: 28px; }
.portal-ui #workspace[data-view="overview"] .platform-icon.pdd img { width: 32px; height: 32px; }
.portal-ui #workspace[data-view="overview"] .status-badge { padding: 2px 8px; }
.portal-ui #workspace[data-view="overview"] .shop dl { gap: 3px 10px; margin: 8px 0; font-size: 12px; line-height: 20px; }
.portal-ui #workspace[data-view="overview"] .shop dd { overflow-wrap: anywhere; }
.portal-ui #workspace[data-view="overview"] .shop-actions { gap: 8px 16px; padding-top: 8px; }
.portal-ui #workspace[data-view="overview"] .shop-actions button { min-height: 32px; font-size: 13px; }
.portal-ui #workspace[data-view="overview"] .shop-platform-description { margin: 14px 0 24px; font-size: 14px; line-height: 1.65; }
@media (min-width: 1000px) {
  .portal-ui #workspace[data-view="overview"] .workspace-main { padding-bottom: 8px; }
  .portal-ui #workspace[data-view="overview"] .context-bar { padding-top: 8px; }
  .portal-ui #workspace[data-view="overview"] .context-selection.is-enhanced { padding-block: 4px; }
  .portal-ui #workspace[data-view="overview"] .workspace-scroll { padding-top: 10px; }
  .portal-ui #workspace[data-view="overview"] .stats > div { padding-block: 8px; }
  .portal-ui #workspace[data-view="overview"] .stats strong { font-size: 26px; }
  .portal-ui #workspace[data-view="overview"] .journey-card { padding-block: 12px; }
  .portal-ui #workspace[data-view="overview"] .journey-guide { margin-top: 8px; }
  .portal-ui #workspace[data-view="overview"] .journey-guide p { margin: 3px 0 6px; }
  .portal-ui #workspace[data-view="overview"] .journey-steps { margin: 8px 0; }
  .portal-ui #workspace[data-view="overview"] .journey-steps button { min-height: 52px; }
  .portal-ui #workspace[data-view="overview"] .journey-next { padding-top: 8px; }
  .portal-ui #workspace[data-view="overview"] .journey-next .primary { min-height: 32px; padding-block: 5px; }
  .portal-ui #workspace[data-view="overview"] .journey-details { display: grid; grid-template-columns: minmax(0,1fr) auto; }
  .portal-ui #workspace[data-view="overview"] .journey-details > :is(.journey-guide,.journey-steps,.journey-next,[data-journey-help]) { grid-column: 1 / -1; }
  .portal-ui #workspace[data-view="overview"] .journey-current { grid-column: 1; align-self: center; margin: 0 8px 8px 0; }
  .portal-ui #workspace[data-view="overview"] .journey-client { grid-column: 2; justify-self: end; padding: 0 0 8px; }
  .portal-ui #workspace[data-view="overview"] .journey-client button { min-height: 28px; padding-block: 3px; }
  .portal-ui #workspace[data-view="overview"] .section-heading { margin-bottom: 8px; }
  .portal-ui #workspace[data-view="overview"] .section-heading > button { min-height: 34px; padding: 6px 12px; font-size: 13px; }
  .portal-ui #workspace[data-view="overview"] .shop-panel .shops { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .portal-ui #workspace[data-view="overview"] .shop { padding-block: 10px; }
  .portal-ui #workspace[data-view="overview"] .shop dl { grid-template-columns: max-content minmax(0,1fr); }
  .portal-ui #workspace[data-view="overview"] .shop-heading { min-height: 28px; margin-bottom: 4px; }
  .portal-ui #workspace[data-view="overview"] .shop dl { margin-block: 6px; gap: 2px 8px; line-height: 18px; }
  .portal-ui #workspace[data-view="overview"] .shop-actions { padding-top: 6px; gap: 4px 12px; }
  .portal-ui #workspace[data-view="overview"] .shop-actions button { min-height: 28px; }
}

@media (max-width: 640px) {
  .portal-ui #workspace[data-view="overview"] .stats > div { align-items: flex-start; flex-direction: column; gap: 6px; }
  .portal-ui #workspace[data-view="overview"] .journey-steps button { min-height: 60px; }
  .portal-ui #workspace[data-view="overview"] .journey-next { align-items: flex-start; }
}
/* Use the extra space on large, tall monitors while keeping the small-screen fit. */
@media (min-width: 1600px) and (min-height: 950px) {
  .portal-ui #workspace[data-view="overview"] [data-panel="overview"]:has(.journey-card[data-complete="false"]) {
    min-height: calc(100dvh - var(--portal-header-height) - 88px);
    grid-template-rows: auto minmax(min-content,1fr) minmax(min-content,1fr);
    gap: 16px;
    align-items: stretch;
  }
  .portal-ui #workspace[data-view="overview"] .stats > div { padding: 12px 18px; }
  .portal-ui #workspace[data-view="overview"] .stats span { font-size: 14px; }
  .portal-ui #workspace[data-view="overview"] .stats strong { font-size: 32px; }
  .portal-ui #workspace[data-view="overview"] .stats .text-stat { font-size: 24px; }
  .portal-ui #workspace[data-view="overview"] .journey-card { display: flex; flex-direction: column; padding: 20px 24px; }
  .portal-ui #workspace[data-view="overview"] .journey-heading h2 { font-size: 21px; }
  .portal-ui #workspace[data-view="overview"] .journey-tools button { min-height: 40px; font-size: 14px; padding: 8px 16px; }
  .portal-ui #workspace[data-view="overview"] .journey-details { flex: 1; align-content: space-between; }
  .portal-ui #workspace[data-view="overview"] .journey-guide { margin-top: 16px; }
  .portal-ui #workspace[data-view="overview"] .journey-guide h3 { font-size: 20px; }
  .portal-ui #workspace[data-view="overview"] .journey-guide p { font-size: 16px; margin: 8px 0 14px; }
  .portal-ui #workspace[data-view="overview"] .journey-progress-count { font-size: 14px; }
  .portal-ui #workspace[data-view="overview"] .journey-progress-count strong { font-size: 18px; }
  .portal-ui #workspace[data-view="overview"] .journey-steps { gap: 12px; margin: 16px 0; }
  .portal-ui #workspace[data-view="overview"] .journey-steps button { min-height: 88px; padding: 16px 20px; gap: 12px; font-size: 17px; }
  .portal-ui #workspace[data-view="overview"] .journey-steps b { min-width: 32px; line-height: 32px; }
  .portal-ui #workspace[data-view="overview"] .journey-step-copy small { font-size: 15px; }
  .portal-ui #workspace[data-view="overview"] .journey-current,
  .portal-ui #workspace[data-view="overview"] .journey-client { font-size: 15px; }
  .portal-ui #workspace[data-view="overview"] .journey-client button { min-height: 36px; font-size: 14px; padding: 6px 12px; }
  .portal-ui #workspace[data-view="overview"] .journey-next { padding-top: 14px; }
  .portal-ui #workspace[data-view="overview"] .journey-next > div { font-size: 15px; }
  .portal-ui #workspace[data-view="overview"] .journey-next .primary { min-height: 40px; padding: 8px 18px; font-size: 15px; }
  .portal-ui #workspace[data-view="overview"] .shop-panel { display: grid; grid-template-rows: auto minmax(0,1fr); }
  .portal-ui #workspace[data-view="overview"] .section-heading { margin-bottom: 12px; }
  .portal-ui #workspace[data-view="overview"] .section-heading h2 { font-size: 22px; }
  .portal-ui #workspace[data-view="overview"] .section-heading > button { min-height: 40px; font-size: 15px; padding: 8px 16px; }
  .portal-ui #workspace[data-view="overview"] .shop-panel .shops { grid-auto-rows: minmax(240px,1fr); gap: 16px; }
  .portal-ui #workspace[data-view="overview"] .shop { padding: 20px 22px; }
  .portal-ui #workspace[data-view="overview"] .shop-heading { min-height: 44px; gap: 12px; margin-bottom: 12px; }
  .portal-ui #workspace[data-view="overview"] .shop-heading strong { font-size: 20px; line-height: 28px; }
  .portal-ui #workspace[data-view="overview"] .platform-icon,
  .portal-ui #workspace[data-view="overview"] .platform-icon img { width: 36px; height: 36px; }
  .portal-ui #workspace[data-view="overview"] .shop dl { font-size: 16px; line-height: 24px; gap: 8px 0; margin: 12px 0; }
  .portal-ui #workspace[data-view="overview"] .shop dt,
  .portal-ui #workspace[data-view="overview"] .shop dd { padding: 12px; background: #f7f8fc; }
  .portal-ui #workspace[data-view="overview"] .shop dt { border-radius: 8px 0 0 8px; font-size: 14px; }
  .portal-ui #workspace[data-view="overview"] .shop dd { border-radius: 0 8px 8px 0; font-weight: 500; }
  .portal-ui #workspace[data-view="overview"] .shop-actions { padding-top: 12px; gap: 8px 24px; }
  .portal-ui #workspace[data-view="overview"] .shop-actions button { min-height: 36px; font-size: 15px; }
}

/* Shared action component for empty platform entries and connected shop cards. */
.portal-ui #workspace[data-view="overview"] .shop-actions { gap: 8px; padding-top: 12px; }
.portal-ui #workspace[data-view="overview"] .shop-actions button.shop-action-component {
  flex: 1 1 98px; display: inline-flex; align-items: center; justify-content: center;
  gap: 6px; min-width: 0; min-height: 44px; padding: 10px 8px;
  border: 1px solid #dce1eb; border-radius: 10px; background: #f6f7fb;
  color: #334155; font-size: 14px; font-weight: 600; line-height: 1.5;
  text-decoration: none; box-shadow: 0 1px 2px rgb(15 23 42 / 3%);
  transition: background-color .16s ease, border-color .16s ease, box-shadow .16s ease;
}
.portal-ui #workspace[data-view="overview"] .shop-actions .shop-action-icon { display: flex; flex: none; color: var(--portal-primary-hover); }
.portal-ui #workspace[data-view="overview"] .shop-actions .shop-action-icon svg { width: 17px; height: 17px; }
.portal-ui #workspace[data-view="overview"] .shop-actions .shop-action-label { white-space: nowrap; }
.portal-ui #workspace[data-view="overview"] .shop-actions .shop-action-arrow { display: none; flex: none; width: 16px; height: 16px; }
.portal-ui #workspace[data-view="overview"] .shop-actions button[data-action-kind="add"] { justify-content: flex-start; padding-inline: 14px; border-color: #ded1f6; background: #f2ecff; color: var(--portal-primary-hover); }
.portal-ui #workspace[data-view="overview"] .shop-actions button[data-action-kind="add"] .shop-action-arrow { display: block; margin-left: auto; }
.portal-ui #workspace[data-view="overview"] .shop-actions button.shop-action-component:hover:not(:disabled) { border-color: #bca5e7; background: #ede5fb; color: var(--portal-primary-hover); box-shadow: 0 2px 6px rgb(92 51 158 / 8%); text-decoration: none; }
.portal-ui #workspace[data-view="overview"] .shop-actions button.shop-action-component:active:not(:disabled) { background: #e5d9f7; box-shadow: none; }
.portal-ui #workspace[data-view="overview"] .shop-actions button.shop-action-component:focus-visible { outline: 2px solid var(--portal-primary-hover); outline-offset: 3px; }
.portal-ui #workspace[data-view="overview"] .shop-actions button.shop-action-component:disabled { opacity: .5; cursor: not-allowed; box-shadow: none; }
@media (prefers-reduced-motion: reduce) {
  .portal-ui #workspace[data-view="overview"] .shop-actions button.shop-action-component { transition: none; }
}

/* Daily work stays in a short list with shop status and actions. */
.portal-ui #workspace[data-view="overview"] [data-panel="overview"] { min-height: 0; grid-template-rows: none; align-items: start; gap: 18px; }
.portal-ui #workspace[data-view="overview"] .stats { display: flex; flex-wrap: wrap; gap: 8px 24px; padding: 4px 0; }
.portal-ui #workspace[data-view="overview"] .stats > div { display: flex; flex-direction: row; align-items: baseline; justify-content: flex-start; gap: 8px; padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
.portal-ui #workspace[data-view="overview"] .stats span { font-size: 13px; color: #667085; }
.portal-ui #workspace[data-view="overview"] .stats strong,
.portal-ui #workspace[data-view="overview"] .stats .text-stat { margin: 0; font-size: 16px; font-weight: 600; line-height: 24px; }
.portal-ui #workspace[data-view="overview"] .context-id { display:none; }
.portal-ui #workspace[data-view="overview"] .journey-card { display: block; padding: 14px 18px; border-radius: 10px; box-shadow: none; }
.portal-ui #workspace[data-view="overview"] .journey-heading h2 { font-size: 15px; }
.portal-ui #workspace[data-view="overview"] .journey-guide h3 { font-size: 15px; }
.portal-ui #workspace[data-view="overview"] .journey-guide p { font-size: 13px; }
.portal-ui #workspace[data-view="overview"] .journey-steps button { min-height: 58px; padding: 10px; font-size: 14px; }
.portal-ui #workspace[data-view="overview"] .journey-step-copy small { font-size: 12px; }
.portal-ui #workspace[data-view="overview"] .journey-tools button { min-height: 32px; padding: 5px 10px; font-size: 13px; }
.portal-ui #workspace[data-view="overview"] .shop-panel { display:block; }
.portal-ui #workspace[data-view="overview"] .shop-panel .shops { display:grid; grid-template-columns:minmax(0,1fr); grid-auto-rows:auto; gap:0; border:1px solid var(--portal-border); border-radius:12px; background:#fff; overflow:hidden; }
.portal-ui #workspace[data-view="overview"] .shop { display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:start; gap:0 22px; padding:18px 20px; border:0; border-radius:0; box-shadow:none; background:#fff; }
.portal-ui #workspace[data-view="overview"] .shop + .shop { border-top:1px solid #edf0f3; }
.portal-ui #workspace[data-view="overview"] .shop-summary { display:grid; grid-template-columns:minmax(180px,1fr) 130px; align-items:center; gap:20px; min-width:0; min-height:40px; }
.portal-ui #workspace[data-view="overview"] .shop-heading { min-height:40px; margin:0; gap:12px; }
.portal-ui #workspace[data-view="overview"] .shop-heading strong { font-size:15px; line-height:22px; }
.portal-ui #workspace[data-view="overview"] .shop-heading small { display:block; font-size:12px; font-weight:400; color:#667085; }
.portal-ui #workspace[data-view="overview"] .platform-icon { width:36px; height:36px; }
.portal-ui #workspace[data-view="overview"] .status-badge { justify-self:start; width:fit-content; padding:3px 8px; font-size:12px; }
.portal-ui #workspace[data-view="overview"] .shop-actions { display:flex; align-items:center; flex-wrap:nowrap; gap:8px; margin:0; padding:2px 0; border:0; }
.portal-ui #workspace[data-view="overview"] .shop-actions button.shop-action-component { flex:none; min-height:36px; min-width:72px; padding:7px 12px; border-color:transparent; background:transparent; box-shadow:none; font-size:13px; font-weight:500; color:#475467; }
.portal-ui #workspace[data-view="overview"] .shop-actions button[data-action-kind="trial"],
.portal-ui #workspace[data-view="overview"] .shop-actions button[data-action-kind="add"] { border-color:#e4e7ec; background:#fff; color:var(--portal-primary); }
.portal-ui #workspace[data-view="overview"] .shop-actions .shop-action-icon { display:none; }
.portal-ui #workspace[data-view="overview"] .shop-platform-empty { grid-template-columns:minmax(0,1fr) 130px auto; align-items:center; }
.portal-ui #workspace[data-view="overview"] .section-heading { margin-bottom:12px; }
.portal-ui #workspace[data-view="overview"] .section-heading h2 { font-size:20px; }
@media(max-width:1000px) {
 .portal-ui #workspace[data-view="overview"] .shop { padding:16px; gap:10px; grid-template-columns:minmax(0,1fr); }
 .portal-ui #workspace[data-view="overview"] .shop-summary { grid-template-columns:minmax(0,1fr); gap:8px; }
 .portal-ui #workspace[data-view="overview"] .shop-summary .status-badge { margin-left:48px; }
 .portal-ui #workspace[data-view="overview"] .shop-actions { justify-content:flex-end; }
 .portal-ui #workspace[data-view="overview"] .shop-platform-empty { grid-template-columns:minmax(0,1fr); }
}
